import { isString } from "../utils/assertion.js";
import { useStyleConfig } from "../core/theme.js";
import Label from "../label/label.js";
import { useSelectContext } from "./context.js";
import { jsx } from "react/jsx-runtime";

//#region src/select/selectLabel.tsx
const SelectLabel = ({ disabled, id, label, labelMarkOptional, labelTooltipText }) => {
	const styles = useStyleConfig("Select", useSelectContext());
	return isString(label) ? /* @__PURE__ */ jsx(Label, {
		"aria-disabled": disabled,
		className: "vui-input-label",
		htmlFor: id,
		markAsOptional: labelMarkOptional,
		mb: .5,
		text: label,
		tooltipText: labelTooltipText,
		...styles.label
	}) : label;
};
SelectLabel.displayName = "SelectLabel";

//#endregion
export { SelectLabel as default };
globalThis.__vuiVersion__ = "4.0.0"
//# sourceMappingURL=selectLabel.js.map