@sonic-equipment/ui 0.0.43 → 0.0.44
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/index.js +3 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6413,7 +6413,9 @@ function Select({ isDisabled = false, label, onChange, options, selectedOption,
|
|
|
6413
6413
|
window.addEventListener('resize', updateWidth);
|
|
6414
6414
|
return () => window.removeEventListener('resize', updateWidth);
|
|
6415
6415
|
}, []);
|
|
6416
|
-
return (jsxs(Select$1, { ref: selectRef, "aria-label": label, className: clsx(styles$m.select, styles$m[size]), isDisabled: isDisabled, onSelectionChange: selected => onChange(selected), placeholder: label, selectedKey: String(selectedOption), children: [showLabel && jsx(Label, { children: label }), jsxs(Button$1, { className: styles$m.button, children: [jsx(SelectValue, {}), jsx(GlyphsChevronsSlimDownIcon, { "aria-hidden": "true", className: styles$m.chevron })] }), jsx(Popover, {
|
|
6416
|
+
return (jsxs(Select$1, { ref: selectRef, "aria-label": label, className: clsx(styles$m.select, styles$m[size]), isDisabled: isDisabled, onSelectionChange: selected => onChange(selected), placeholder: label, selectedKey: String(selectedOption), children: [showLabel && jsx(Label, { children: label }), jsxs(Button$1, { className: styles$m.button, children: [jsx(SelectValue, {}), jsx(GlyphsChevronsSlimDownIcon, { "aria-hidden": "true", className: styles$m.chevron })] }), jsx(Popover, { ref: ref =>
|
|
6417
|
+
// Workaround for react/react-aria #1513
|
|
6418
|
+
ref?.addEventListener('touchend', e => e.preventDefault()), className: styles$m.popover, placement: "bottom left", triggerRef: selectRef, children: jsx(ListBox, { className: styles$m.listbox, children: jsxs(Section, { children: [jsx(Header, { className: styles$m.header, children: label }), Object.entries(options).map(([key, value]) => (jsxs(ListBoxItem, { "aria-label": value, className: styles$m.item, id: key, textValue: value, children: [selectedOption === key && (jsx("span", { slot: "description", children: jsx(StrokeCheckmarkIcon, { className: styles$m.check }) })), jsx("span", { slot: "label", children: value })] }, key)))] }) }) })] }));
|
|
6417
6419
|
}
|
|
6418
6420
|
|
|
6419
6421
|
var styles$l = {"input-container":"textarea-module-C6Xr1","lg":"textarea-module-vksG-","md":"textarea-module-6JrQJ"};
|