@luscii-healthtech/web-ui 60.1.0 → 60.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/components/Checkbox/LabeledCheckboxCardGroup.js +2 -2
- package/dist/esm/components/Checkbox/LabeledCheckboxCardGroup.js.map +1 -1
- package/dist/esm/components/Checkbox/LabeledCheckboxGroup.js +2 -2
- package/dist/esm/components/Checkbox/LabeledCheckboxGroup.js.map +1 -1
- package/dist/esm/components/DatePicker/LabeledDatePicker.js +1 -1
- package/dist/esm/components/DatePicker/LabeledDatePicker.js.map +1 -1
- package/dist/esm/components/Input/Input.js.map +1 -1
- package/dist/esm/components/Input/LabeledInput.js +4 -2
- package/dist/esm/components/Input/LabeledInput.js.map +1 -1
- package/dist/esm/components/Input/SearchInput.js +1 -1
- package/dist/esm/components/Input/SearchInput.js.map +1 -1
- package/dist/esm/components/Input/StyledInput.js +71 -28
- package/dist/esm/components/Input/StyledInput.js.map +1 -1
- package/dist/esm/components/Radio/LabeledRadioCardGroup.js +2 -2
- package/dist/esm/components/Radio/LabeledRadioCardGroup.js.map +1 -1
- package/dist/esm/components/Radio/LabeledRadioGroup.js +2 -2
- package/dist/esm/components/Radio/LabeledRadioGroup.js.map +1 -1
- package/dist/esm/components/Select/LabeledSelect.js +1 -1
- package/dist/esm/components/Select/LabeledSelect.js.map +1 -1
- package/dist/esm/components/Select/LabeledSelectSearchable.js +2 -1
- package/dist/esm/components/Select/LabeledSelectSearchable.js.map +1 -1
- package/dist/esm/components/forms/shared/FieldsetLegend.js +17 -0
- package/dist/esm/components/forms/shared/FieldsetLegend.js.map +1 -0
- package/dist/esm/components/forms/shared/HelperAndErrorText.js +1 -1
- package/dist/esm/components/forms/shared/HelperAndErrorText.js.map +1 -1
- package/dist/index.development.js +95 -39
- package/dist/index.development.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/src/components/Checkbox/LabeledCheckboxCardGroup.d.ts +10 -2
- package/dist/src/components/Checkbox/LabeledCheckboxGroup.d.ts +9 -1
- package/dist/src/components/DatePicker/LabeledDatePicker.d.ts +9 -1
- package/dist/src/components/Input/Input.d.ts +2 -0
- package/dist/src/components/Input/LabeledInput.d.ts +11 -1
- package/dist/src/components/Input/StyledInput.d.ts +2 -0
- package/dist/src/components/InputSelect/InputSelect.d.ts +1 -0
- package/dist/src/components/InputSelect/InputSelectInput.d.ts +1 -0
- package/dist/src/components/NaturalLanguageForm/NaturalLanguageForm.d.ts +2 -0
- package/dist/src/components/NaturalLanguageForm/NaturalLanguageFormInput.d.ts +1 -0
- package/dist/src/components/NaturalLanguageForm/NaturalLanguageFormInputSelect.d.ts +1 -0
- package/dist/src/components/Radio/LabeledRadioCardGroup.d.ts +10 -2
- package/dist/src/components/Radio/LabeledRadioGroup.d.ts +9 -1
- package/dist/src/components/Select/LabeledSelect.d.ts +9 -1
- package/dist/src/components/Select/LabeledSelectSearchable.d.ts +8 -1
- package/dist/src/components/forms/shared/FieldsetLegend.d.ts +22 -0
- package/dist/src/generated/components/Checkbox/LabeledCheckboxCardGroup.d.ts +10 -2
- package/dist/src/generated/components/Checkbox/LabeledCheckboxGroup.d.ts +9 -1
- package/dist/src/generated/components/DatePicker/LabeledDatePicker.d.ts +9 -1
- package/dist/src/generated/components/Input/Input.d.ts +2 -0
- package/dist/src/generated/components/Input/LabeledInput.d.ts +11 -1
- package/dist/src/generated/components/Input/StyledInput.d.ts +2 -0
- package/dist/src/generated/components/InputSelect/InputSelect.d.ts +1 -0
- package/dist/src/generated/components/InputSelect/InputSelectInput.d.ts +1 -0
- package/dist/src/generated/components/NaturalLanguageForm/NaturalLanguageForm.d.ts +2 -0
- package/dist/src/generated/components/NaturalLanguageForm/NaturalLanguageFormInput.d.ts +1 -0
- package/dist/src/generated/components/NaturalLanguageForm/NaturalLanguageFormInputSelect.d.ts +1 -0
- package/dist/src/generated/components/Radio/LabeledRadioCardGroup.d.ts +10 -2
- package/dist/src/generated/components/Radio/LabeledRadioGroup.d.ts +9 -1
- package/dist/src/generated/components/Select/LabeledSelect.d.ts +9 -1
- package/dist/src/generated/components/Select/LabeledSelectSearchable.d.ts +8 -1
- package/dist/src/generated/components/forms/shared/FieldsetLegend.d.ts +22 -0
- package/dist/stories/InputSelect.stories.d.ts +1 -0
- package/dist/stories/LabeledCheckbox.stories.d.ts +5 -0
- package/dist/stories/LabeledDatePicker.stories.d.ts +6 -1
- package/dist/stories/LabeledInput.stories.d.ts +14 -1
- package/dist/stories/LabeledRadio.stories.d.ts +10 -0
- package/dist/stories/LabeledSelectSearchable.stories.d.ts +6 -1
- package/dist/stories/NaturalLanguageForm.stories.d.ts +2 -0
- package/dist/stories/SearchInput.stories.d.ts +1 -0
- package/dist/stories/Select.stories.d.ts +5 -0
- package/dist/web-ui-tailwind.css +32 -0
- package/package.json +1 -1
|
@@ -2030,7 +2030,7 @@ const HelperAndErrorText = (props) => {
|
|
|
2030
2030
|
if (showHelperText) {
|
|
2031
2031
|
return jsxRuntime.jsx(Box, { id: props.describingId, children: jsxRuntime.jsx(Text, { variant: "sm", color: "slate-500", containsDangerousHtml: typeof props.helperText === "string", className: linkClasses, children: props.helperText }) });
|
|
2032
2032
|
}
|
|
2033
|
-
return jsxRuntime.jsx(Box, { id: props.describingId, children: props.errorText && jsxRuntime.jsx(Text, { variant: "sm", color: "red", children: props.errorText }) });
|
|
2033
|
+
return jsxRuntime.jsx(Box, { id: props.describingId, className: "ui:empty:hidden", children: props.errorText && jsxRuntime.jsx(Text, { variant: "sm", color: "red", children: props.errorText }) });
|
|
2034
2034
|
};
|
|
2035
2035
|
|
|
2036
2036
|
const LabelText = (props) => {
|
|
@@ -2131,16 +2131,27 @@ const LabeledCheckboxCard = React__namespace.default.forwardRef((props, ref) =>
|
|
|
2131
2131
|
return jsxRuntime.jsx(LabeledCheckboxBase, Object.assign({}, props, { ref, variant: "card" }));
|
|
2132
2132
|
});
|
|
2133
2133
|
|
|
2134
|
+
const FieldsetLegend = ({ children }) => jsxRuntime.jsx("legend", { className: "ui:contents", children: renderLegendContent(children) });
|
|
2135
|
+
const renderLegendContent = (children) => {
|
|
2136
|
+
if (typeof children === "string") {
|
|
2137
|
+
return jsxRuntime.jsx(Text, { as: "span", className: "ui:block", children });
|
|
2138
|
+
}
|
|
2139
|
+
if (React__namespace.default.isValidElement(children) && children.type !== React__namespace.default.Fragment) {
|
|
2140
|
+
return children;
|
|
2141
|
+
}
|
|
2142
|
+
return jsxRuntime.jsx("span", { className: "ui:block", children });
|
|
2143
|
+
};
|
|
2144
|
+
|
|
2134
2145
|
const LabeledCheckboxGroup = (props) => {
|
|
2135
2146
|
const { children, title, className } = props;
|
|
2136
2147
|
const semanticId = React__namespace.default.useId();
|
|
2137
|
-
return jsxRuntime.jsxs(Stack, { as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default(className), _gap: "base", children: [title && jsxRuntime.jsx(
|
|
2148
|
+
return jsxRuntime.jsxs(Stack, { as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default(className), _gap: "base", children: [title && jsxRuntime.jsx(FieldsetLegend, { children: title }), jsxRuntime.jsx(Stack, { _gap: "l", children }), jsxRuntime.jsx(HelperAndErrorText, { helperText: props.helperText, errorText: props.errorText, describingId: semanticId })] });
|
|
2138
2149
|
};
|
|
2139
2150
|
|
|
2140
2151
|
const LabeledCheckboxCardGroup = (props) => {
|
|
2141
2152
|
const { children, title, className, columns = 2, stretch = false, helperText, errorText } = props, attributes = __rest(props, ["children", "title", "className", "columns", "stretch", "helperText", "errorText"]);
|
|
2142
2153
|
const semanticId = React__namespace.default.useId();
|
|
2143
|
-
return jsxRuntime.jsxs(Stack, Object.assign({ as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default({ "ui:w-full": stretch }, className), _gap: "base", align: stretch ? "stretch" : "start" }, attributes, { children: [title && jsxRuntime.jsx(
|
|
2154
|
+
return jsxRuntime.jsxs(Stack, Object.assign({ as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default({ "ui:w-full": stretch }, className), _gap: "base", align: stretch ? "stretch" : "start" }, attributes, { children: [title && jsxRuntime.jsx(FieldsetLegend, { children: title }), jsxRuntime.jsx("div", { className: classNames__default.default("ui:grid ui:gap-x-m ui:gap-y-xs ui:items-start", {
|
|
2144
2155
|
"ui:grid-cols-1": columns === 1,
|
|
2145
2156
|
"ui:grid-cols-2": columns === 2,
|
|
2146
2157
|
"ui:grid-cols-3": columns === 3,
|
|
@@ -2206,7 +2217,7 @@ LabeledRadioCard.displayName = "LabeledRadioCard";
|
|
|
2206
2217
|
const LabeledRadioCardGroup = (props) => {
|
|
2207
2218
|
const { children, title, className, columns = 2, helperText, errorText } = props, attributes = __rest(props, ["children", "title", "className", "columns", "helperText", "errorText"]);
|
|
2208
2219
|
const semanticId = React__namespace.default.useId();
|
|
2209
|
-
return jsxRuntime.jsxs(Stack, Object.assign({ as: "fieldset", "aria-describedby": semanticId, className, _gap: "
|
|
2220
|
+
return jsxRuntime.jsxs(Stack, Object.assign({ as: "fieldset", "aria-describedby": semanticId, className, _gap: "base", width: "full" }, attributes, { children: [title && jsxRuntime.jsx(FieldsetLegend, { children: title }), jsxRuntime.jsx("div", { className: classNames__default.default("ui:grid ui:gap-x-m ui:gap-y-xs ui:items-start ui:w-full", {
|
|
2210
2221
|
"ui:grid-cols-1": columns === 1,
|
|
2211
2222
|
"ui:grid-cols-2": columns === 2,
|
|
2212
2223
|
"ui:grid-cols-3": columns === 3,
|
|
@@ -2319,7 +2330,7 @@ const LabeledRadioGroup = (props) => {
|
|
|
2319
2330
|
axis: "y",
|
|
2320
2331
|
_gap: "base"
|
|
2321
2332
|
};
|
|
2322
|
-
return jsxRuntime.jsxs(Stack, { as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default(className), _gap: "
|
|
2333
|
+
return jsxRuntime.jsxs(Stack, { as: "fieldset", "aria-describedby": semanticId, className: classNames__default.default(className), _gap: "base", children: [title && jsxRuntime.jsx(FieldsetLegend, { children: title }), jsxRuntime.jsx(Stack, Object.assign({}, orientationProps, { children })), jsxRuntime.jsx(HelperAndErrorText, { helperText: props.helperText, errorText: props.errorText, describingId: semanticId })] });
|
|
2323
2334
|
};
|
|
2324
2335
|
|
|
2325
2336
|
const ConfirmationDialogChoices = (props) => {
|
|
@@ -2500,10 +2511,25 @@ const calculateResponsiveGrowClasses = (size) => {
|
|
|
2500
2511
|
};
|
|
2501
2512
|
|
|
2502
2513
|
const StyledInput = React__namespace.default.forwardRef((_a, ref) => {
|
|
2503
|
-
var { suffix, prefix, className, width = "full", height = "lg", icon, isError, isClearIconVisible, onClickClearField } = _a, attributes = __rest(_a, ["suffix", "prefix", "className", "width", "height", "icon", "isError", "isClearIconVisible", "onClickClearField"]);
|
|
2514
|
+
var { suffix, prefix, className, width = "full", height = "lg", icon, isError, isClearIconVisible, onClickClearField, clearButtonLabel = "Clear" } = _a, attributes = __rest(_a, ["suffix", "prefix", "className", "width", "height", "icon", "isError", "isClearIconVisible", "onClickClearField", "clearButtonLabel"]);
|
|
2515
|
+
const inputRef = React__namespace.default.useRef(null);
|
|
2516
|
+
React__namespace.default.useImperativeHandle(ref, () => inputRef.current);
|
|
2517
|
+
const handleClearClick = () => {
|
|
2518
|
+
var _a2;
|
|
2519
|
+
onClickClearField === null || onClickClearField === void 0 ? void 0 : onClickClearField();
|
|
2520
|
+
(_a2 = inputRef.current) === null || _a2 === void 0 ? void 0 : _a2.focus();
|
|
2521
|
+
};
|
|
2504
2522
|
const hasPrefix = !!prefix;
|
|
2505
2523
|
const hasSuffix = !!suffix;
|
|
2506
2524
|
const hasNoExtraContent = !hasPrefix && !hasSuffix;
|
|
2525
|
+
const focusInput = (event) => {
|
|
2526
|
+
var _a2;
|
|
2527
|
+
if (attributes.disabled) {
|
|
2528
|
+
return;
|
|
2529
|
+
}
|
|
2530
|
+
event.preventDefault();
|
|
2531
|
+
(_a2 = inputRef.current) === null || _a2 === void 0 ? void 0 : _a2.focus();
|
|
2532
|
+
};
|
|
2507
2533
|
const heightClasses = {
|
|
2508
2534
|
md: "ui:h-form-md",
|
|
2509
2535
|
lg: "ui:h-form-lg"
|
|
@@ -2517,35 +2543,63 @@ const StyledInput = React__namespace.default.forwardRef((_a, ref) => {
|
|
|
2517
2543
|
"ui:order-1": hasSuffix,
|
|
2518
2544
|
"ui:rounded-l ui:border-l": hasPrefix,
|
|
2519
2545
|
"ui:rounded-r ui:border-r": hasSuffix
|
|
2520
|
-
}, "ui:flex ui:flex-col ui:items-center", "ui:text-sm", "ui:text-slate-500", "ui:bg-main-background"), children: suffix || prefix }), jsxRuntime.jsxs("div", { className: classNames__default.default("ui:relative", calculateResponsiveGrowClasses(width)), children: [icon && jsxRuntime.jsx("div", { className: classNames__default.default(
|
|
2521
|
-
|
|
2522
|
-
|
|
2546
|
+
}, "ui:flex ui:flex-col ui:items-center", "ui:text-sm", "ui:text-slate-500", "ui:bg-main-background"), onMouseDown: focusInput, children: suffix || prefix }), jsxRuntime.jsxs("div", { className: classNames__default.default("ui:relative", calculateResponsiveGrowClasses(width)), children: [icon && jsxRuntime.jsx("div", { className: classNames__default.default(
|
|
2547
|
+
// Let clicks on the icon fall through to the input underneath
|
|
2548
|
+
"ui:pointer-events-none ui:absolute ui:left-4 ui:top-1/2",
|
|
2549
|
+
{
|
|
2550
|
+
"ui:grow": width === "full"
|
|
2551
|
+
}
|
|
2552
|
+
), style: {
|
|
2523
2553
|
transform: "translateY(-50%)",
|
|
2524
2554
|
zIndex: 20
|
|
2525
|
-
}, children: jsxRuntime.jsx(IconComponentOrKey, { name: icon, className: "ui:h-6 ui:w-6 ui:text-slate-300" }) }), jsxRuntime.jsx("input", Object.assign({ ref, className: classNames__default.default(
|
|
2526
|
-
"ui:
|
|
2527
|
-
|
|
2528
|
-
"ui:
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
"ui:
|
|
2542
|
-
"ui:
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
"ui:
|
|
2547
|
-
"ui:
|
|
2548
|
-
|
|
2555
|
+
}, children: jsxRuntime.jsx(IconComponentOrKey, { name: icon, className: "ui:h-6 ui:w-6 ui:text-slate-300" }) }), jsxRuntime.jsx("input", Object.assign({ ref: inputRef, className: classNames__default.default(
|
|
2556
|
+
"ui:block",
|
|
2557
|
+
calculateResponsiveWidthClasses(width),
|
|
2558
|
+
{ "ui:pl-12": icon },
|
|
2559
|
+
{
|
|
2560
|
+
"ui:bg-slate-50 ui:text-slate-400": attributes.disabled,
|
|
2561
|
+
"ui:text-slate-800": !attributes.disabled,
|
|
2562
|
+
"ui:border-input-border": !attributes.disabled && !isError,
|
|
2563
|
+
"ui:hover:border-input-border-dark": !attributes.disabled,
|
|
2564
|
+
"ui:border-red-700": isError,
|
|
2565
|
+
"ui:focus:outline-negative": isError,
|
|
2566
|
+
"ui:focus:border-primary": !isError,
|
|
2567
|
+
"ui:focus:outline-primary": !isError,
|
|
2568
|
+
"ui:bg-white": !attributes.disabled
|
|
2569
|
+
},
|
|
2570
|
+
heightClasses[height],
|
|
2571
|
+
"ui:p-2",
|
|
2572
|
+
"ui:border",
|
|
2573
|
+
"ui:text-base ui:sm:text-sm",
|
|
2574
|
+
"ui:placeholder-slate-500",
|
|
2575
|
+
"ui:border-solid",
|
|
2576
|
+
"ui:transition-colors",
|
|
2577
|
+
"ui:duration-300",
|
|
2578
|
+
{
|
|
2579
|
+
"ui:z-10": hasSuffix || hasPrefix,
|
|
2580
|
+
// to make sure the ui:outline is displayed completely
|
|
2581
|
+
"ui:rounded": hasNoExtraContent,
|
|
2582
|
+
"ui:rounded-l": hasSuffix,
|
|
2583
|
+
"ui:rounded-r": hasPrefix,
|
|
2584
|
+
"ui:order-2": hasPrefix,
|
|
2585
|
+
"ui:order-1": hasSuffix
|
|
2586
|
+
},
|
|
2587
|
+
"ui:shadow-default",
|
|
2588
|
+
// Safari keeps its native searchfield look for type="search" unless appearance is reset.
|
|
2589
|
+
"ui:[&[type=search]]:appearance-none",
|
|
2590
|
+
"ui:[&::-webkit-search-cancel-button]:appearance-none",
|
|
2591
|
+
className
|
|
2592
|
+
) }, attributes)), jsxRuntime.jsx("button", {
|
|
2593
|
+
type: "button",
|
|
2594
|
+
"aria-label": clearButtonLabel,
|
|
2595
|
+
onClick: handleClearClick,
|
|
2596
|
+
// `display: none` keeps the hidden button out of the tab order and the accessibility tree.
|
|
2597
|
+
className: classNames__default.default("ui:absolute ui:right-0 ui:top-1/2 ui:mr-3 ui:cursor-pointer ui:rounded ui:focus-visible:outline-primary", { "ui:hidden": !isClearIconVisible }),
|
|
2598
|
+
style: {
|
|
2599
|
+
transform: "translateY(-50%)"
|
|
2600
|
+
},
|
|
2601
|
+
children: jsxRuntime.jsx(CrossIcon, { className: "ui:block ui:h-6 ui:w-6 ui:text-slate-300" })
|
|
2602
|
+
})] })] });
|
|
2549
2603
|
});
|
|
2550
2604
|
|
|
2551
2605
|
const Input = React__namespace.default.forwardRef((_a, ref) => {
|
|
@@ -2669,14 +2723,16 @@ const LabeledDatePicker = (_a) => {
|
|
|
2669
2723
|
"ui:!border-negative-border": isError,
|
|
2670
2724
|
"ui:!focus:outline-negative": isError
|
|
2671
2725
|
}, classNameFromProps);
|
|
2672
|
-
return jsxRuntime.jsxs(Stack, { as: "label", _gap: "
|
|
2726
|
+
return jsxRuntime.jsxs(Stack, { as: "label", _gap: "base", align: fullWidth ? "stretch" : void 0, children: [label && jsxRuntime.jsx(LabelText, { as: "span", className: "ui:block", children: label }), jsxRuntime.jsx(DatePicker, Object.assign({}, props, { className: datePickerClassNames, "aria-describedby": helperErrorTextId })), jsxRuntime.jsx(HelperAndErrorText, { helperText, errorText, describingId: helperErrorTextId })] });
|
|
2673
2727
|
};
|
|
2674
2728
|
|
|
2675
2729
|
const LabeledInput = React__namespace.default.forwardRef((props, ref) => {
|
|
2676
|
-
const { className, helperText, errorText, label, width, fullWidth, "aria-describedby": ariaDescribedBy } = props, rest = __rest(props, ["className", "helperText", "errorText", "label", "width", "fullWidth", "aria-describedby"]);
|
|
2730
|
+
const { className, helperText, errorText, label, width, fullWidth, id, "aria-describedby": ariaDescribedBy } = props, rest = __rest(props, ["className", "helperText", "errorText", "label", "width", "fullWidth", "id", "aria-describedby"]);
|
|
2731
|
+
const generatedInputId = React__namespace.default.useId();
|
|
2732
|
+
const inputId = id || generatedInputId;
|
|
2677
2733
|
const helperErrorTextId = React__namespace.default.useId();
|
|
2678
2734
|
const fieldWidth = width !== null && width !== void 0 ? width : fullWidth ? "full" : void 0;
|
|
2679
|
-
return jsxRuntime.jsxs(Stack, {
|
|
2735
|
+
return jsxRuntime.jsxs(Stack, { _gap: "base", align: fieldWidth ? "stretch" : void 0, className: classNames__default.default(fieldWidth && calculateResponsiveWidthClasses(fieldWidth), className), children: [label && jsxRuntime.jsx(LabelText, { as: "label", htmlFor: inputId, children: label }), jsxRuntime.jsx(StyledInput, Object.assign({}, rest, { id: inputId, ref, isError: Boolean(errorText), "aria-describedby": [ariaDescribedBy, helperErrorTextId].filter(Boolean).join(" ") })), jsxRuntime.jsx(HelperAndErrorText, { helperText, errorText, describingId: helperErrorTextId })] });
|
|
2680
2736
|
});
|
|
2681
2737
|
|
|
2682
2738
|
const Actions$1 = (props) => {
|
|
@@ -4518,7 +4574,7 @@ const Select = React__namespace.default.forwardRef((_a, innerRef) => {
|
|
|
4518
4574
|
const LabeledSelect = React__namespace.default.forwardRef((props, ref) => {
|
|
4519
4575
|
const { className, helperText, errorText, label, fullWidth, "aria-describedby": ariaDescribedBy } = props, rest = __rest(props, ["className", "helperText", "errorText", "label", "fullWidth", "aria-describedby"]);
|
|
4520
4576
|
const helperErrorTextId = React__namespace.default.useId();
|
|
4521
|
-
return jsxRuntime.jsxs(Stack, { as: "label", _gap: "
|
|
4577
|
+
return jsxRuntime.jsxs(Stack, { as: "label", _gap: "base", align: fullWidth ? "stretch" : void 0, className, children: [label && jsxRuntime.jsx(LabelText, { as: "span", className: "ui:block", children: props.label }), jsxRuntime.jsx(StyledSelect, Object.assign({}, rest, { ref, isError: Boolean(errorText), "aria-describedby": [ariaDescribedBy, helperErrorTextId].join(" ") })), jsxRuntime.jsx(HelperAndErrorText, { helperText, errorText, describingId: helperErrorTextId })] });
|
|
4522
4578
|
});
|
|
4523
4579
|
|
|
4524
4580
|
const LabeledSelectSearchable = React__namespace.default.forwardRef((props, ref) => {
|
|
@@ -4528,7 +4584,7 @@ const LabeledSelectSearchable = React__namespace.default.forwardRef((props, ref)
|
|
|
4528
4584
|
const errorMessageId = React__namespace.default.useId();
|
|
4529
4585
|
const hasError = Boolean(errorText);
|
|
4530
4586
|
const labelledBy = [ariaLabelledBy, label ? labelId : void 0].filter(Boolean).join(" ") || void 0;
|
|
4531
|
-
return jsxRuntime.jsxs(Stack, { _gap: "
|
|
4587
|
+
return jsxRuntime.jsxs(Stack, { _gap: "base", align: fullWidth ? "stretch" : void 0, className, children: [label && jsxRuntime.jsx(Box, { id: labelId, children: jsxRuntime.jsx(LabelText, { as: "span", className: "ui:block", children: label }) }), jsxRuntime.jsx(Select, Object.assign({}, rest, { ref, isError: hasError, "aria-labelledby": labelledBy, "aria-invalid": hasError || void 0, "aria-errormessage": hasError ? errorMessageId : void 0 })), jsxRuntime.jsx("div", { id: errorMessageId, "aria-live": "polite", className: classNames__default.default({ "ui:sr-only": !helperText && !errorText }), children: jsxRuntime.jsx(HelperAndErrorText, { helperText, errorText, describingId: helperErrorTextId }) })] });
|
|
4532
4588
|
});
|
|
4533
4589
|
|
|
4534
4590
|
const useOutsideClick = (ref, callback) => {
|
|
@@ -4809,7 +4865,7 @@ ModalDialog.useModalDialog = useModalDialog;
|
|
|
4809
4865
|
|
|
4810
4866
|
const SearchInput = React__namespace.default.forwardRef((props, ref) => {
|
|
4811
4867
|
var _a;
|
|
4812
|
-
return jsxRuntime.jsx(Input, Object.assign({}, props, { icon: "SearchIcon", type: "
|
|
4868
|
+
return jsxRuntime.jsx(Input, Object.assign({}, props, { icon: "SearchIcon", type: "search", width: (_a = props.width) !== null && _a !== void 0 ? _a : "xl", clearable: true, ref }));
|
|
4813
4869
|
});
|
|
4814
4870
|
|
|
4815
4871
|
const ImageCategory = (props) => {
|