@eightshift/ui-components 5.0.1 → 5.0.3
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/{Button-wERNNG0T.js → Button-BpwTmkAe.js} +4 -4
- package/dist/{Collection-CKsHTyhc.js → Collection-n5d0zIgb.js} +66 -31
- package/dist/{Color-BhgbJF5x.js → Color-lVhk8V_G.js} +1 -1
- package/dist/{ColorSwatch-Bcn6oRSg.js → ColorSwatch-DntWEAC3.js} +4 -4
- package/dist/{ComboBox-D1LPUwWP.js → ComboBox-BJpTEATT.js} +31 -22
- package/dist/{Dialog-D190gMbE.js → Dialog-O9uw63D7.js} +46 -27
- package/dist/{FieldError-DeUh5Wkw.js → FieldError-DHrSdE_Q.js} +2 -2
- package/dist/{FocusScope-C-plSxbS.js → FocusScope-BEPI2m7u.js} +2 -2
- package/dist/{Group-C5iZpSAM.js → Group-DDPhPPTQ.js} +3 -3
- package/dist/{Heading-D-Pboe4p.js → Heading-ba38ScjJ.js} +1 -1
- package/dist/{Input--mF4XVE1.js → Input-BmDS8Juy.js} +6 -6
- package/dist/{Label-Fp6AwSRn.js → Label-JS_ob-kh.js} +1 -1
- package/dist/{ListBox-4oW9kh3R.js → ListBox-BTxlCGcc.js} +97 -15
- package/dist/{OverlayArrow-BpB9uB_I.js → OverlayArrow-5aDgmImj.js} +3 -3
- package/dist/{Separator-B88tj5YD.js → Separator-CaTBkETC.js} +21 -12
- package/dist/{Slider-CyJzC1bp.js → Slider-C-S1oEH9.js} +10 -10
- package/dist/{Text-DRpwWot2.js → Text-BuJgePCv.js} +1 -1
- package/dist/{VisuallyHidden-DsKYcRQ_.js → VisuallyHidden-BYi0pekx.js} +2 -2
- package/dist/assets/style-admin.css +398 -142
- package/dist/assets/style-editor.css +398 -142
- package/dist/assets/style.css +398 -142
- package/dist/assets/wp-font-enhancements.css +1 -1
- package/dist/assets/wp-ui-enhancements.css +29 -10
- package/dist/components/base-control/base-control.js +1 -1
- package/dist/components/button/button.js +18 -18
- package/dist/components/checkbox/checkbox.js +17 -14
- package/dist/components/color-pickers/color-swatch.js +4 -4
- package/dist/components/color-pickers/gradient-editor.js +3 -3
- package/dist/components/color-pickers/solid-color-picker.js +21 -21
- package/dist/components/component-toggle/component-toggle.js +0 -1
- package/dist/components/draggable/draggable.js +694 -353
- package/dist/components/expandable/expandable.js +65 -58
- package/dist/components/input-field/input-field.js +10 -10
- package/dist/components/link-input/link-input.js +22 -27
- package/dist/components/menu/menu.js +5 -5
- package/dist/components/modal/modal.js +5 -5
- package/dist/components/notice/notice.js +16 -16
- package/dist/components/number-picker/number-picker.js +10 -10
- package/dist/components/options-panel/options-panel.js +1 -1
- package/dist/components/placeholders/file-placeholder.js +13 -6
- package/dist/components/placeholders/image-placeholder.js +2 -2
- package/dist/components/placeholders/media-placeholder.js +2 -2
- package/dist/components/popover/popover.js +2 -2
- package/dist/components/radio/radio.js +19 -16
- package/dist/components/repeater/repeater-item.js +6 -5
- package/dist/components/repeater/repeater.js +8 -3
- package/dist/components/responsive/mini-responsive.js +1 -1
- package/dist/components/select/async-multi-select.js +1 -0
- package/dist/components/select/async-single-select.js +1 -0
- package/dist/components/select/multi-select.js +1 -0
- package/dist/components/select/single-select.js +1 -0
- package/dist/components/select/styles.js +1 -1
- package/dist/components/select/v2/async-select.js +9 -9
- package/dist/components/select/v2/shared.js +2 -2
- package/dist/components/select/v2/single-select.js +35 -22
- package/dist/components/slider/column-config-slider.js +3 -3
- package/dist/components/slider/slider.js +4 -4
- package/dist/components/tabs/tabs.js +22 -23
- package/dist/components/toggle/switch.js +8 -8
- package/dist/components/toggle/toggle.js +1 -1
- package/dist/components/toggle-button/toggle-button.js +18 -17
- package/dist/components/tooltip/tooltip.js +3 -3
- package/dist/{context-BYWrbm1z.js → context-BbYZoHvX.js} +1 -1
- package/dist/icons/icons.js +124 -0
- package/dist/{index-wl5606BX.js → index-BljRBEr_.js} +1 -1
- package/dist/{textSelection-CCcyjiRP.js → textSelection-8DpK8fJl.js} +1 -1
- package/dist/{useButton-BOHxkGQF.js → useButton-Bt3BffJm.js} +3 -3
- package/dist/{useEvent-D5o_CqDH.js → useEvent-ICdlokG-.js} +1 -1
- package/dist/{useFocusRing-nMG2uzxS.js → useFocusRing-Bv0UJQl8.js} +1 -1
- package/dist/{useFormReset-DlmRL87g.js → useFormReset-D2YaWRIA.js} +1 -1
- package/dist/{useFormValidation-D0_aaK-e.js → useFormValidation-Dy0PXJg5.js} +2 -2
- package/dist/{useHover-VO5tcIli.js → useHover-C2SkI1Fn.js} +7 -2
- package/dist/{useLabel-BKH4fVA4.js → useLabel-BPCd5c7-.js} +2 -2
- package/dist/{useLabels-ntF3rFY0.js → useLabels-B7-lUnAF.js} +1 -1
- package/dist/{useListState-Cq2Nvr-v.js → useListState-DkyH7elT.js} +10 -3
- package/dist/{useLocalizedStringFormatter-CGzwx1a0.js → useLocalizedStringFormatter-C9GO0IDB.js} +1 -1
- package/dist/{useNumberField-C9dmERhP.js → useNumberField-CU1_u8ze.js} +18 -10
- package/dist/{useNumberFormatter-MrRLgvhj.js → useNumberFormatter-CZ9QUnRt.js} +1 -1
- package/dist/{usePress-DjNo5790.js → usePress-BrJylgPR.js} +21 -10
- package/dist/{useSingleSelectListState--r3AAhRj.js → useSingleSelectListState-C4sorv2p.js} +2 -2
- package/dist/{useToggle-CQaXLe-O.js → useToggle-CDa3YAZI.js} +4 -4
- package/dist/{useToggleState-C3DLdez5.js → useToggleState-ibcBUHnB.js} +1 -1
- package/dist/{utils-B94NDG0v.js → utils-CZt7LCbO.js} +41 -8
- package/package.json +24 -24
|
@@ -30,7 +30,7 @@ import { RepeaterContext } from "./repeater-context.js";
|
|
|
30
30
|
*/
|
|
31
31
|
const RepeaterItem = (props) => {
|
|
32
32
|
const { children, icon, label, subtitle, "aria-label": ariaLabel, className, actions, textValue, expandDisabled, menuOptions, noMenuButton, ...rest } = props;
|
|
33
|
-
const { deleteItem, duplicateItem, isDragged, isOutOfBounds, isSelected, canDelete, canAdd, allOpen, setAllOpen } = useContext(RepeaterContext);
|
|
33
|
+
const { deleteItem, duplicateItem, isDragged, isOutOfBounds, isSelected, canDelete, canAdd, allOpen, setAllOpen, setOpenItems, id, isItemOpen } = useContext(RepeaterContext);
|
|
34
34
|
return /* @__PURE__ */ jsx(
|
|
35
35
|
Expandable,
|
|
36
36
|
{
|
|
@@ -39,20 +39,21 @@ const RepeaterItem = (props) => {
|
|
|
39
39
|
subtitle: isOutOfBounds ? null : subtitle,
|
|
40
40
|
className: clsx(
|
|
41
41
|
"es:transition",
|
|
42
|
-
isDragged && "es:border es:border-secondary-100 es:bg-white/50 es:shadow-md es:backdrop-blur-lg",
|
|
43
|
-
isOutOfBounds && "es:border es:border-red-200! es:bg-red-50 es:shadow-red-500/20 es:[&_button]:invisible es:[&_svg_path]:stroke-red-500"
|
|
42
|
+
!isItemOpen && isDragged && "es:border es:border-secondary-100 es:bg-white/50 es:shadow-md es:backdrop-blur-lg",
|
|
43
|
+
!isItemOpen && isOutOfBounds && "es:border es:border-red-200! es:bg-red-50 es:shadow-red-500/20 es:[&_button]:invisible es:[&_svg_path]:stroke-red-500"
|
|
44
44
|
),
|
|
45
|
-
labelClassName: clsx(className, isDragged
|
|
45
|
+
labelClassName: clsx(className, isDragged && "es:cursor-grabbing", !isDragged && !isItemOpen && "es:cursor-grab"),
|
|
46
46
|
headerClassName: clsx(
|
|
47
47
|
"es:transition es:rounded-lg es:border es:border-transparent",
|
|
48
48
|
isSelected && "es:bg-accent-50 es:border-accent-100",
|
|
49
|
-
"es:group-focus:outline-hidden es:group-focus:border-accent-500 es:group-focus:ring-2 es:group-focus:ring-accent-500/50"
|
|
49
|
+
!isItemOpen && "es:group-focus:outline-hidden es:group-focus:border-accent-500 es:group-focus:ring-2 es:group-focus:ring-accent-500/50"
|
|
50
50
|
),
|
|
51
51
|
open: allOpen,
|
|
52
52
|
onOpenChange: (open) => {
|
|
53
53
|
if (allOpen && !open) {
|
|
54
54
|
setAllOpen(false);
|
|
55
55
|
}
|
|
56
|
+
setOpenItems((prev) => ({ ...prev, [id]: open }));
|
|
56
57
|
},
|
|
57
58
|
customOpenButton: ({ open, toggleOpen, tooltip, disabled }) => {
|
|
58
59
|
return /* @__PURE__ */ jsxs("div", { className: "es:flex es:items-center es:gap-px", children: [
|
|
@@ -38,6 +38,7 @@ const fixIds = (items, itemIdBase) => {
|
|
|
38
38
|
* @param {JSX.Element} [props.addButton] - If provided, overrides the default add button. `(props: { addItem: (additional: Object<string, any>?) => void, disabled: Boolean }) => JSX.Element`.
|
|
39
39
|
* @param {string} [props.className] - Classes to pass to the item wrapper.
|
|
40
40
|
* @param {boolean} [props.noExpandAllButton] - If `true`, the "Expand all"/"Collapse all" button is not displayed.
|
|
41
|
+
* @param {boolean} [props.noDragToRemove] - If `true`, the "drag to remove" functionality will be disabled.
|
|
41
42
|
* @param {JSX.Element|JSX.Element[]} [props.moreOptions] - Options to add in the "More options" menu.
|
|
42
43
|
* @param {JSX.Element} [props.emptyState] - Allows overriding the default empty state.
|
|
43
44
|
*
|
|
@@ -92,10 +93,12 @@ const Repeater = (props) => {
|
|
|
92
93
|
className,
|
|
93
94
|
emptyState,
|
|
94
95
|
noExpandAllButton,
|
|
96
|
+
noDragToRemove,
|
|
95
97
|
moreOptions,
|
|
96
98
|
hidden
|
|
97
99
|
} = props;
|
|
98
100
|
const [allOpen, setAllOpen] = useState(false);
|
|
101
|
+
const [openItems, setOpenItems] = useState({});
|
|
99
102
|
if (typeof rawItems === "undefined" || rawItems === null || !Array.isArray(rawItems)) {
|
|
100
103
|
console.warn(__("Repeater: 'items' are not an array or are undefined!", "eightshift-ui-components"));
|
|
101
104
|
}
|
|
@@ -168,7 +171,7 @@ const Repeater = (props) => {
|
|
|
168
171
|
/* @__PURE__ */ jsx(
|
|
169
172
|
List,
|
|
170
173
|
{
|
|
171
|
-
values: items,
|
|
174
|
+
values: items.map((item) => ({ ...item, disabled: openItems[item.id] })),
|
|
172
175
|
onChange: ({ oldIndex, newIndex }) => onChange(newIndex === -1 ? arrayRemove(items, oldIndex) : arrayMove(items, oldIndex, newIndex)),
|
|
173
176
|
renderList: ({ children: children2, props: props2 }) => {
|
|
174
177
|
const { key, ...rest } = props2;
|
|
@@ -214,7 +217,9 @@ const Repeater = (props) => {
|
|
|
214
217
|
canDelete,
|
|
215
218
|
canAdd,
|
|
216
219
|
allOpen,
|
|
217
|
-
setAllOpen
|
|
220
|
+
setAllOpen,
|
|
221
|
+
setOpenItems,
|
|
222
|
+
isItemOpen: openItems[item.id] ?? allOpen
|
|
218
223
|
},
|
|
219
224
|
children: children({
|
|
220
225
|
...item,
|
|
@@ -236,7 +241,7 @@ const Repeater = (props) => {
|
|
|
236
241
|
(item == null ? void 0 : item.id) ?? key
|
|
237
242
|
);
|
|
238
243
|
},
|
|
239
|
-
removableByMove:
|
|
244
|
+
removableByMove: !noDragToRemove
|
|
240
245
|
}
|
|
241
246
|
),
|
|
242
247
|
/* @__PURE__ */ jsxs(AnimatedVisibility, { visible: items.length < 1, children: [
|
|
@@ -12,7 +12,7 @@ import { Spacer } from "../spacer/spacer.js";
|
|
|
12
12
|
import { BaseControl } from "../base-control/base-control.js";
|
|
13
13
|
import { TriggeredPopover } from "../popover/popover.js";
|
|
14
14
|
import { OptionSelect } from "../option-select/option-select.js";
|
|
15
|
-
import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../Text-
|
|
15
|
+
import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../Text-BuJgePCv.js";
|
|
16
16
|
/**
|
|
17
17
|
* A compact, inline version of `Responsive`. Allows the user to set different values for different breakpoints.
|
|
18
18
|
*
|
|
@@ -143,6 +143,7 @@ const AsyncMultiSelect = (props) => {
|
|
|
143
143
|
DropdownIndicator: customDropdownArrow ?? CustomSelectDefaultDropdownIndicator,
|
|
144
144
|
ClearIndicator: customClearIndicator ?? CustomSelectDefaultClearIndicator
|
|
145
145
|
},
|
|
146
|
+
menuPlacement: "auto",
|
|
146
147
|
menuPortalTarget: document.body,
|
|
147
148
|
...additionalProps
|
|
148
149
|
}
|
|
@@ -125,6 +125,7 @@ const AsyncSelect = (props) => {
|
|
|
125
125
|
DropdownIndicator: customDropdownArrow ?? CustomSelectDefaultDropdownIndicator,
|
|
126
126
|
ClearIndicator: customClearIndicator ?? CustomSelectDefaultClearIndicator
|
|
127
127
|
},
|
|
128
|
+
menuPlacement: "auto",
|
|
128
129
|
menuPortalTarget: document.body,
|
|
129
130
|
...additionalProps
|
|
130
131
|
}
|
|
@@ -137,6 +137,7 @@ const MultiSelect = (props) => {
|
|
|
137
137
|
DropdownIndicator: customDropdownArrow ?? CustomSelectDefaultDropdownIndicator,
|
|
138
138
|
ClearIndicator: customClearIndicator ?? CustomSelectDefaultClearIndicator
|
|
139
139
|
},
|
|
140
|
+
menuPlacement: "auto",
|
|
140
141
|
menuPortalTarget: document.body,
|
|
141
142
|
...additionalProps
|
|
142
143
|
}
|
|
@@ -119,6 +119,7 @@ const Select = (props) => {
|
|
|
119
119
|
DropdownIndicator: customDropdownArrow ?? CustomSelectDefaultDropdownIndicator,
|
|
120
120
|
ClearIndicator: customClearIndicator ?? CustomSelectDefaultClearIndicator
|
|
121
121
|
},
|
|
122
|
+
menuPlacement: "auto",
|
|
122
123
|
menuPortalTarget: document.body,
|
|
123
124
|
...additionalProps
|
|
124
125
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { c as clsx } from "../../lite-DVmmD_-j.js";
|
|
2
2
|
const controlStyles = {
|
|
3
|
-
base: "es:border es:border-gray-300 es:rounded-
|
|
3
|
+
base: "es:border es:border-gray-300 es:rounded-10 es:bg-white es:text-sm es:transition es:group es:shadow-sm es:min-h-10! es:inset-ring es:inset-ring-secondary-100",
|
|
4
4
|
focus: "es:ring-2 es:ring-accent-500/50 es:border-accent-500!"
|
|
5
5
|
};
|
|
6
6
|
const placeholderStyles = "es:text-gray-400 es:ml-1";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
2
|
import { _ as __ } from "../../../default-i18n-CT_oS1Fy.js";
|
|
3
|
-
import { $ as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../../Button-
|
|
4
|
-
import { $ as $f86e6c1ec7da6ebb$export$bc3384a35de93d66, a as $d01f2c01039c0eec$export$72b9695b8216309a, b as $d01f2c01039c0eec$export$c02625b26074192c } from "../../../ComboBox-
|
|
5
|
-
import { $ as $3985021b0ad6602f$export$f5b8910cec6cf069 } from "../../../Input
|
|
6
|
-
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../../Label-
|
|
7
|
-
import { $ as $eed445e0843c11d0$export$41f133550aa26f48 } from "../../../ListBox-
|
|
8
|
-
import { $ as $07b14b47974efb58$export$5b6b19405a83ff9d } from "../../../Dialog-
|
|
9
|
-
import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../../Text-
|
|
3
|
+
import { $ as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../../Button-BpwTmkAe.js";
|
|
4
|
+
import { $ as $f86e6c1ec7da6ebb$export$bc3384a35de93d66, a as $d01f2c01039c0eec$export$72b9695b8216309a, b as $d01f2c01039c0eec$export$c02625b26074192c } from "../../../ComboBox-BJpTEATT.js";
|
|
5
|
+
import { $ as $3985021b0ad6602f$export$f5b8910cec6cf069 } from "../../../Input-BmDS8Juy.js";
|
|
6
|
+
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../../Label-JS_ob-kh.js";
|
|
7
|
+
import { $ as $eed445e0843c11d0$export$41f133550aa26f48 } from "../../../ListBox-BTxlCGcc.js";
|
|
8
|
+
import { $ as $07b14b47974efb58$export$5b6b19405a83ff9d } from "../../../Dialog-O9uw63D7.js";
|
|
9
|
+
import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../../Text-BuJgePCv.js";
|
|
10
10
|
import { OptionItemBase } from "./shared.js";
|
|
11
11
|
import { RichLabel } from "../../rich-label/rich-label.js";
|
|
12
12
|
import { BaseControl } from "../../base-control/base-control.js";
|
|
@@ -14,7 +14,7 @@ import { useEffect, useRef, cloneElement, useContext } from "react";
|
|
|
14
14
|
import { icons } from "../../../icons/icons.js";
|
|
15
15
|
import "../../../react-jsx-parser.min-DZCiis5V.js";
|
|
16
16
|
import { unescapeHTML } from "../../../utilities/text-helpers.js";
|
|
17
|
-
import { c as clsx } from "../../../utils-
|
|
17
|
+
import { c as clsx } from "../../../utils-CZt7LCbO.js";
|
|
18
18
|
/**
|
|
19
19
|
* Select menu with async loading.
|
|
20
20
|
*
|
|
@@ -171,7 +171,7 @@ const __ExperimentalAsyncSelect = (props) => {
|
|
|
171
171
|
{
|
|
172
172
|
className: clsx(
|
|
173
173
|
"es:relative es:flex es:max-w-80 es:items-center es:gap-1 es:p-1 es:focus-visible:outline-hidden es:focus-visible:ring-2 es:focus-visible:ring-accent-500/50",
|
|
174
|
-
"es:h-9 es:rounded-
|
|
174
|
+
"es:h-9 es:rounded-10 es:border es:border-secondary-300 es:bg-white es:text-sm es:shadow-sm es:transition",
|
|
175
175
|
"es:any-focus:outline-hidden",
|
|
176
176
|
!inline && "es:w-full",
|
|
177
177
|
disabled && "es:select-none",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { a as $eed445e0843c11d0$export$a11e76429ed99b4 } from "../../../ListBox-
|
|
3
|
-
import { c as clsx } from "../../../utils-
|
|
2
|
+
import { a as $eed445e0843c11d0$export$a11e76429ed99b4 } from "../../../ListBox-BTxlCGcc.js";
|
|
3
|
+
import { c as clsx } from "../../../utils-CZt7LCbO.js";
|
|
4
4
|
const OptionItemBase = (props) => {
|
|
5
5
|
var _a;
|
|
6
6
|
return /* @__PURE__ */ jsx(
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { _ as __ } from "../../../default-i18n-CT_oS1Fy.js";
|
|
3
3
|
import { BaseControl } from "../../base-control/base-control.js";
|
|
4
|
-
import { a as $d2b4bc8c273e7be6$export$24d547caef80ccd1, $ as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../../Button-
|
|
5
|
-
import { a as $01b77f81d0f07f68$export$75b6ee27786ba447, $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../../Label-
|
|
6
|
-
import { b as $eed445e0843c11d0$export$7ff8f37d2d81a48d, c as $eed445e0843c11d0$export$7c5906fe4f1f2af2, $ as $eed445e0843c11d0$export$41f133550aa26f48 } from "../../../ListBox-
|
|
7
|
-
import { o as $168583247155ddda$export$dc9c12ed27dd1b49, l as $de32f1b87079253c$export$d2f961adcb0afbe, p as $07b14b47974efb58$export$9b9a0cd73afb7ca4, $ as $07b14b47974efb58$export$5b6b19405a83ff9d } from "../../../Dialog-
|
|
8
|
-
import { d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, p as $ff5963eb1fccf552$export$e08e3b67e392101e, a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e, b as $64fa3d84918910a7$export$4d86445c2cf5e3, g as $64fa3d84918910a7$export$9d4c57ee4c6ffdd8, h as $64fa3d84918910a7$export$ef03459518577ad4, i as $64fa3d84918910a7$export$2881499e37b75b9a, c as clsx } from "../../../utils-
|
|
9
|
-
import { a as $2baaea4c71418dea$export$294aa081a6c6f55d, $ as $ee014567cb39d3f0$export$ff05c3ac10437e03 } from "../../../FieldError-
|
|
4
|
+
import { a as $d2b4bc8c273e7be6$export$24d547caef80ccd1, $ as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../../Button-BpwTmkAe.js";
|
|
5
|
+
import { a as $01b77f81d0f07f68$export$75b6ee27786ba447, $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../../Label-JS_ob-kh.js";
|
|
6
|
+
import { b as $eed445e0843c11d0$export$7ff8f37d2d81a48d, c as $eed445e0843c11d0$export$7c5906fe4f1f2af2, $ as $eed445e0843c11d0$export$41f133550aa26f48 } from "../../../ListBox-BTxlCGcc.js";
|
|
7
|
+
import { o as $168583247155ddda$export$dc9c12ed27dd1b49, l as $de32f1b87079253c$export$d2f961adcb0afbe, p as $07b14b47974efb58$export$9b9a0cd73afb7ca4, $ as $07b14b47974efb58$export$5b6b19405a83ff9d } from "../../../Dialog-O9uw63D7.js";
|
|
8
|
+
import { d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, p as $ff5963eb1fccf552$export$e08e3b67e392101e, a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e, b as $64fa3d84918910a7$export$4d86445c2cf5e3, g as $64fa3d84918910a7$export$9d4c57ee4c6ffdd8, h as $64fa3d84918910a7$export$ef03459518577ad4, i as $64fa3d84918910a7$export$2881499e37b75b9a, c as clsx } from "../../../utils-CZt7LCbO.js";
|
|
9
|
+
import { a as $2baaea4c71418dea$export$294aa081a6c6f55d, $ as $ee014567cb39d3f0$export$ff05c3ac10437e03 } from "../../../FieldError-DHrSdE_Q.js";
|
|
10
10
|
import { $ as $d3e0e05bdfcf66bd$export$c24727297075ec6a } from "../../../Form-Cq3fu75_.js";
|
|
11
|
-
import { a as $514c0188e459b4c0$export$9afb8bc826b033ea } from "../../../Text-
|
|
12
|
-
import { o as $fb3050f43d946246$export$e32c88dfddc6e1d8, e as $e1995378a142960e$export$bf788dd355e3a401 } from "../../../Collection-
|
|
11
|
+
import { a as $514c0188e459b4c0$export$9afb8bc826b033ea } from "../../../Text-BuJgePCv.js";
|
|
12
|
+
import { o as $fb3050f43d946246$export$e32c88dfddc6e1d8, e as $e1995378a142960e$export$bf788dd355e3a401 } from "../../../Collection-n5d0zIgb.js";
|
|
13
13
|
import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../../filterDOMProps-EDDcM64A.js";
|
|
14
|
-
import { $ as $fc909762b330b746$export$61c6a8c84e605fb6, g as $9daab02d461809db$export$683480f191c0e3ea } from "../../../OverlayArrow-
|
|
14
|
+
import { $ as $fc909762b330b746$export$61c6a8c84e605fb6, g as $9daab02d461809db$export$683480f191c0e3ea } from "../../../OverlayArrow-5aDgmImj.js";
|
|
15
15
|
import React__default, { useMemo, useRef, useState, forwardRef, createContext, useContext, useCallback, cloneElement } from "react";
|
|
16
|
-
import { $ as $fca6afa0e843324b$export$f12b703ca79dfbb1 } from "../../../useLocalizedStringFormatter-
|
|
17
|
-
import { a as $e93e671b31057976$export$b8473d3665f3a75a, $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10 } from "../../../useFormValidation-
|
|
18
|
-
import { $ as $a0d645289fe9b86b$export$e7f05e985daf4b5f } from "../../../useSingleSelectListState
|
|
19
|
-
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../../useFocusRing-
|
|
20
|
-
import {
|
|
21
|
-
import { q as $507fabe10e71c6fb$export$8397ddfc504fdb9a } from "../../../useHover-
|
|
22
|
-
import { $ as $99facab73266f662$export$5add1d006293d136 } from "../../../useFormReset-
|
|
23
|
-
import { a as $5c3e21d68f1c4674$export$a966af930f325cab } from "../../../VisuallyHidden-
|
|
16
|
+
import { $ as $fca6afa0e843324b$export$f12b703ca79dfbb1 } from "../../../useLocalizedStringFormatter-C9GO0IDB.js";
|
|
17
|
+
import { a as $e93e671b31057976$export$b8473d3665f3a75a, $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10 } from "../../../useFormValidation-Dy0PXJg5.js";
|
|
18
|
+
import { $ as $a0d645289fe9b86b$export$e7f05e985daf4b5f } from "../../../useSingleSelectListState-C4sorv2p.js";
|
|
19
|
+
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../../useFocusRing-Bv0UJQl8.js";
|
|
20
|
+
import { f as $325a3faab7a68acd$export$a16aca283550c30d, g as $2a25aae57d74318e$export$a05409b8bb224a5a } from "../../../Separator-CaTBkETC.js";
|
|
21
|
+
import { q as $507fabe10e71c6fb$export$8397ddfc504fdb9a } from "../../../useHover-C2SkI1Fn.js";
|
|
22
|
+
import { $ as $99facab73266f662$export$5add1d006293d136 } from "../../../useFormReset-D2YaWRIA.js";
|
|
23
|
+
import { a as $5c3e21d68f1c4674$export$a966af930f325cab } from "../../../VisuallyHidden-BYi0pekx.js";
|
|
24
24
|
import { icons } from "../../../icons/icons.js";
|
|
25
25
|
import "../../../react-jsx-parser.min-DZCiis5V.js";
|
|
26
26
|
import { OptionItemBase } from "./shared.js";
|
|
@@ -237,19 +237,25 @@ function $2bc3a590c5373a4e$export$5159ec8b34d4ec12(props) {
|
|
|
237
237
|
value: listState.selectedKey
|
|
238
238
|
});
|
|
239
239
|
let [isFocused, setFocused] = useState(false);
|
|
240
|
+
let isEmpty = useMemo(() => {
|
|
241
|
+
var _listState_collection_getItem;
|
|
242
|
+
return listState.collection.size === 0 || listState.collection.size === 1 && ((_listState_collection_getItem = listState.collection.getItem(listState.collection.getFirstKey())) === null || _listState_collection_getItem === void 0 ? void 0 : _listState_collection_getItem.type) === "loader";
|
|
243
|
+
}, [
|
|
244
|
+
listState.collection
|
|
245
|
+
]);
|
|
240
246
|
return {
|
|
241
247
|
...validationState,
|
|
242
248
|
...listState,
|
|
243
249
|
...triggerState,
|
|
244
250
|
focusStrategy,
|
|
245
251
|
open(focusStrategy2 = null) {
|
|
246
|
-
if (
|
|
252
|
+
if (!isEmpty) {
|
|
247
253
|
setFocusStrategy(focusStrategy2);
|
|
248
254
|
triggerState.open();
|
|
249
255
|
}
|
|
250
256
|
},
|
|
251
257
|
toggle(focusStrategy2 = null) {
|
|
252
|
-
if (
|
|
258
|
+
if (!isEmpty) {
|
|
253
259
|
setFocusStrategy(focusStrategy2);
|
|
254
260
|
triggerState.toggle();
|
|
255
261
|
}
|
|
@@ -563,6 +569,11 @@ const $82d7e5349645de74$export$ef9b1a59e592288f = /* @__PURE__ */ forwardRef(fun
|
|
|
563
569
|
selectRef: ref
|
|
564
570
|
}));
|
|
565
571
|
});
|
|
572
|
+
const $82d7e5349645de74$var$CLEAR_CONTEXTS = [
|
|
573
|
+
$01b77f81d0f07f68$export$75b6ee27786ba447,
|
|
574
|
+
$d2b4bc8c273e7be6$export$24d547caef80ccd1,
|
|
575
|
+
$514c0188e459b4c0$export$9afb8bc826b033ea
|
|
576
|
+
];
|
|
566
577
|
function $82d7e5349645de74$var$SelectInner({ props, selectRef: ref, collection }) {
|
|
567
578
|
let { validationBehavior: formValidationBehavior } = $64fa3d84918910a7$export$fabf2dc03a41866e($d3e0e05bdfcf66bd$export$c24727297075ec6a) || {};
|
|
568
579
|
var _props_validationBehavior, _ref;
|
|
@@ -643,7 +654,8 @@ function $82d7e5349645de74$var$SelectInner({ props, selectRef: ref, collection }
|
|
|
643
654
|
{
|
|
644
655
|
...triggerProps,
|
|
645
656
|
ref: buttonRef,
|
|
646
|
-
isPressed: state.isOpen
|
|
657
|
+
isPressed: state.isOpen,
|
|
658
|
+
autoFocus: props.autoFocus
|
|
647
659
|
}
|
|
648
660
|
],
|
|
649
661
|
[
|
|
@@ -660,7 +672,8 @@ function $82d7e5349645de74$var$SelectInner({ props, selectRef: ref, collection }
|
|
|
660
672
|
style: {
|
|
661
673
|
"--trigger-width": buttonWidth
|
|
662
674
|
},
|
|
663
|
-
"aria-labelledby": menuProps["aria-labelledby"]
|
|
675
|
+
"aria-labelledby": menuProps["aria-labelledby"],
|
|
676
|
+
clearContexts: $82d7e5349645de74$var$CLEAR_CONTEXTS
|
|
664
677
|
}
|
|
665
678
|
],
|
|
666
679
|
[
|
|
@@ -860,7 +873,7 @@ const __ExperimentalSelect = (props) => {
|
|
|
860
873
|
{
|
|
861
874
|
className: clsx(
|
|
862
875
|
"es:relative es:flex es:max-w-80 es:items-center es:gap-1 es:p-1 es:focus-visible:outline-hidden es:focus-visible:ring-2 es:focus-visible:ring-accent-500/50",
|
|
863
|
-
"es:h-9 es:rounded-
|
|
876
|
+
"es:h-9 es:rounded-10 es:border es:border-secondary-300 es:bg-white es:text-sm es:shadow-sm es:transition",
|
|
864
877
|
"es:any-focus:outline-hidden",
|
|
865
878
|
!inline && "es:w-full",
|
|
866
879
|
disabled && "es:select-none",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { _ as __ } from "../../default-i18n-CT_oS1Fy.js";
|
|
3
|
-
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-
|
|
4
|
-
import { $ as $6f909507e6374d18$export$472062a354075cee, a as $6f909507e6374d18$export$105594979f116971, b as $6f909507e6374d18$export$2c1b491743890dec, c as $6f909507e6374d18$export$a590f758a961cb5b } from "../../Slider-
|
|
3
|
+
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-JS_ob-kh.js";
|
|
4
|
+
import { $ as $6f909507e6374d18$export$472062a354075cee, a as $6f909507e6374d18$export$105594979f116971, b as $6f909507e6374d18$export$2c1b491743890dec, c as $6f909507e6374d18$export$a590f758a961cb5b } from "../../Slider-C-S1oEH9.js";
|
|
5
5
|
import { BaseControl } from "../base-control/base-control.js";
|
|
6
6
|
import { icons } from "../../icons/icons.js";
|
|
7
7
|
import { getColumnConfigOutputText } from "./utils.js";
|
|
@@ -101,7 +101,7 @@ const ColumnConfigSlider = (props) => {
|
|
|
101
101
|
{
|
|
102
102
|
className: clsx(
|
|
103
103
|
"es:col-span-full es:row-span-1 es:row-start-1 es:h-full es:w-full es:grow es:rounded-lg es:border",
|
|
104
|
-
disabled ? "es:border-secondary-200 es:bg-white" : "es:border-secondary-300 es:bg-secondary-50 es:shadow-
|
|
104
|
+
disabled ? "es:border-secondary-200 es:bg-white" : "es:border-secondary-300 es:bg-secondary-50 es:shadow-sm"
|
|
105
105
|
)
|
|
106
106
|
}
|
|
107
107
|
),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { $ as $64fa3d84918910a7$export$fabf2dc03a41866e } from "../../utils-
|
|
3
|
-
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5, a as $01b77f81d0f07f68$export$75b6ee27786ba447 } from "../../Label-
|
|
4
|
-
import { $ as $6f909507e6374d18$export$472062a354075cee, a as $6f909507e6374d18$export$105594979f116971, b as $6f909507e6374d18$export$2c1b491743890dec, c as $6f909507e6374d18$export$a590f758a961cb5b, d as $6f909507e6374d18$export$1e7083018727fa60 } from "../../Slider-
|
|
2
|
+
import { $ as $64fa3d84918910a7$export$fabf2dc03a41866e } from "../../utils-CZt7LCbO.js";
|
|
3
|
+
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5, a as $01b77f81d0f07f68$export$75b6ee27786ba447 } from "../../Label-JS_ob-kh.js";
|
|
4
|
+
import { $ as $6f909507e6374d18$export$472062a354075cee, a as $6f909507e6374d18$export$105594979f116971, b as $6f909507e6374d18$export$2c1b491743890dec, c as $6f909507e6374d18$export$a590f758a961cb5b, d as $6f909507e6374d18$export$1e7083018727fa60 } from "../../Slider-C-S1oEH9.js";
|
|
5
5
|
import { BaseControl } from "../base-control/base-control.js";
|
|
6
6
|
import { c as clsx } from "../../lite-DVmmD_-j.js";
|
|
7
7
|
import { NumberPicker } from "../number-picker/number-picker.js";
|
|
@@ -194,7 +194,7 @@ const Slider = (props) => {
|
|
|
194
194
|
"es:relative es:col-start-1 es:row-start-1 es:rounded-full es:border",
|
|
195
195
|
!vertical && "es:h-1.5 es:w-full es:self-center",
|
|
196
196
|
vertical && "es:h-full es:w-1.5 es:flex-col es:justify-self-center",
|
|
197
|
-
disabled ? "es:border-secondary-200 es:bg-white" : "es:border-secondary-300 es:bg-secondary-50 es:shadow-
|
|
197
|
+
disabled ? "es:border-secondary-200 es:bg-white" : "es:border-secondary-300 es:bg-secondary-50 es:shadow-sm"
|
|
198
198
|
),
|
|
199
199
|
style: trackStyle
|
|
200
200
|
}
|
|
@@ -1,27 +1,22 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { c as $880e95eb8b93ba9a$export$ecf600387e221c37,
|
|
3
|
-
import { k as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, l as $df56164dff5785e2$export$4338b53315abf666, b as $64fa3d84918910a7$export$4d86445c2cf5e3, i as $64fa3d84918910a7$export$2881499e37b75b9a, a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e } from "../../utils-
|
|
2
|
+
import { c as $880e95eb8b93ba9a$export$ecf600387e221c37, i as $ae20dd8cbca75726$export$d6daf82dcd84e87c, d as $e1995378a142960e$export$18af5c7a9e9b3664, f as $e1995378a142960e$export$fb8073518f34e6ec, g as $7135fc7d473fd974$export$4feb769f8ddf26c5, j as $7135fc7d473fd974$export$a164736487e3f0ae, e as $e1995378a142960e$export$bf788dd355e3a401, k as $7135fc7d473fd974$export$90e00781bc59d8f9 } from "../../Collection-n5d0zIgb.js";
|
|
3
|
+
import { k as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, l as $df56164dff5785e2$export$4338b53315abf666, b as $64fa3d84918910a7$export$4d86445c2cf5e3, i as $64fa3d84918910a7$export$2881499e37b75b9a, a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e } from "../../utils-CZt7LCbO.js";
|
|
4
4
|
import { $ as $f39a9eba43920ace$export$86427a43e3e48ebb } from "../../Hidden-rE6uR-lr.js";
|
|
5
5
|
import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
|
|
6
|
-
import
|
|
7
|
-
import {
|
|
8
|
-
import { a as $
|
|
9
|
-
import { $ as $
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { $ as $
|
|
13
|
-
import { $ as $
|
|
6
|
+
import { b as $cdc5a6778b766db2$export$a9d04c5684123369 } from "../../useListState-DkyH7elT.js";
|
|
7
|
+
import React__default, { useState, useMemo, useRef, useEffect, forwardRef, useContext, createContext, isValidElement, useId, cloneElement } from "react";
|
|
8
|
+
import { a as $ea8dcbcb9ea1b556$export$7e924b3091a3bd18 } from "../../usePress-BrJylgPR.js";
|
|
9
|
+
import { a as $f645667febf57a63$export$4c014de7c8940b4c, $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../useHover-C2SkI1Fn.js";
|
|
10
|
+
import { $ as $313b98861ee5dd6c$export$d6875122194c7b44 } from "../../useLabels-B7-lUnAF.js";
|
|
11
|
+
import { a as $9bf71ea28793e738$export$2d6ec8fc375ceafa } from "../../FocusScope-BEPI2m7u.js";
|
|
12
|
+
import { $ as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7 } from "../../context-BbYZoHvX.js";
|
|
13
|
+
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-Bv0UJQl8.js";
|
|
14
|
+
import { $ as $a0d645289fe9b86b$export$e7f05e985daf4b5f } from "../../useSingleSelectListState-C4sorv2p.js";
|
|
14
15
|
import { _ as __, s as sprintf } from "../../default-i18n-CT_oS1Fy.js";
|
|
15
16
|
import { c as clsx } from "../../lite-DVmmD_-j.js";
|
|
16
|
-
import { c as cva } from "../../index-
|
|
17
|
+
import { c as cva } from "../../index-BljRBEr_.js";
|
|
17
18
|
import { Notice } from "../notice/notice.js";
|
|
18
19
|
import { RichLabel } from "../rich-label/rich-label.js";
|
|
19
|
-
function $cdc5a6778b766db2$export$a9d04c5684123369(value) {
|
|
20
|
-
const pieces = version.split(".");
|
|
21
|
-
const major = parseInt(pieces[0], 10);
|
|
22
|
-
if (major >= 19) return value;
|
|
23
|
-
return value ? "true" : void 0;
|
|
24
|
-
}
|
|
25
20
|
function $83013635b024ae3d$export$eac1895992b9f3d6(ref, options) {
|
|
26
21
|
let isDisabled = options === null || options === void 0 ? void 0 : options.isDisabled;
|
|
27
22
|
let [hasTabbableChild, setHasTabbableChild] = useState(false);
|
|
@@ -210,6 +205,10 @@ function $76f919a04c5a7d14$export$4ba071daf4e486(props) {
|
|
|
210
205
|
var _props_defaultSelectedKey, _ref;
|
|
211
206
|
let state = $a0d645289fe9b86b$export$e7f05e985daf4b5f({
|
|
212
207
|
...props,
|
|
208
|
+
onSelectionChange: props.onSelectionChange ? (key) => {
|
|
209
|
+
var _props_onSelectionChange;
|
|
210
|
+
if (key != null) (_props_onSelectionChange = props.onSelectionChange) === null || _props_onSelectionChange === void 0 ? void 0 : _props_onSelectionChange.call(props, key);
|
|
211
|
+
} : void 0,
|
|
213
212
|
suppressTextValueWarning: true,
|
|
214
213
|
defaultSelectedKey: (_ref = (_props_defaultSelectedKey = props.defaultSelectedKey) !== null && _props_defaultSelectedKey !== void 0 ? _props_defaultSelectedKey : $76f919a04c5a7d14$var$findDefaultSelectedKey(props.collection, props.disabledKeys ? new Set(props.disabledKeys) : /* @__PURE__ */ new Set())) !== null && _ref !== void 0 ? _ref : void 0
|
|
215
214
|
});
|
|
@@ -602,10 +601,10 @@ const Tab = (props) => {
|
|
|
602
601
|
variants: {
|
|
603
602
|
type: {
|
|
604
603
|
underline: "es:disabled:text-secondary-400 es:selected:text-accent-950",
|
|
605
|
-
pill: "es:font-[450] es:border es:border-transparent es:px-3 es:py-
|
|
606
|
-
pillInverse: "es:font-[450] es:border es:border-transparent es:px-3 es:py-
|
|
607
|
-
pillCompact: "es:icon:size-4 es:font-[450] es:border es:border-transparent es:px-
|
|
608
|
-
pillCompactInverse: "es:icon:size-4 es:font-[450] es:border es:border-transparent es:px-
|
|
604
|
+
pill: "es:font-[450] es:border es:border-transparent es:px-3 es:py-1.5 es:rounded-xl es:not-disabled:not-selected:hover:text-secondary-900 es:not-disabled:not-selected:hover:bg-secondary-100 es:text-secondary-500 es:selected:text-accent-900 es:selected:bg-gradient-to-br es:selected:from-accent-300/10 es:selected:to-accent-400/20 es:selected:border-accent-400/10 es:has-icon:pl-2.5 es:focus-visible:border-accent-500 es:disabled:text-secondary-400/75",
|
|
605
|
+
pillInverse: "es:font-[450] es:border es:border-transparent es:px-3 es:py-1.5 es:rounded-xl es:not-disabled:not-selected:hover:text-secondary-900 es:not-disabled:not-selected:hover:bg-secondary-100 es:text-secondary-500 es:selected:text-white es:selected:bg-gradient-to-br es:selected:from-accent-500 es:selected:to-accent-600 es:selected:border-accent-600 es:has-icon:pl-2.5 es:focus-visible:border-accent-500 es:disabled:text-secondary-400/75",
|
|
606
|
+
pillCompact: "es:icon:size-4 es:font-[450] es:border es:border-transparent es:px-2.5 es:py-1 es:rounded-10 es:not-disabled:not-selected:hover:text-secondary-900 es:not-disabled:not-selected:hover:bg-secondary-100 es:text-secondary-500 es:selected:text-accent-900 es:selected:bg-gradient-to-br es:selected:from-accent-300/10 es:selected:to-accent-400/20 es:selected:border-accent-400/10 es:has-icon:pl-1 es:focus-visible:border-accent-500 es:disabled:text-secondary-400/75",
|
|
607
|
+
pillCompactInverse: "es:icon:size-4 es:font-[450] es:border es:border-transparent es:px-2.5 es:py-1 es:rounded-10 es:not-disabled:not-selected:hover:text-secondary-900 es:not-disabled:not-selected:hover:bg-secondary-100 es:text-secondary-500 es:selected:text-white es:selected:bg-gradient-to-br es:selected:from-accent-500 es:selected:to-accent-600 es:selected:border-accent-600 es:has-icon:pl-1 es:focus-visible:border-accent-500 es:disabled:text-secondary-400/75"
|
|
609
608
|
}
|
|
610
609
|
},
|
|
611
610
|
compoundVariants: [
|
|
@@ -616,7 +615,7 @@ const Tab = (props) => {
|
|
|
616
615
|
"es:px-2 es:py-2.5 es:rounded-lg",
|
|
617
616
|
'es:after:content-[""] es:after:absolute es:after:bottom-px es:after:left-0 es:after:right-0 es:after:w-5/6 es:after:mx-auto es:after:h-0.75',
|
|
618
617
|
"es:after:bg-linear-to-b es:hover:not-selected:not-disabled:after:from-secondary-200 es:hover:not-selected:not-disabled:after:to-secondary-300 es:selected:after:from-accent-500 es:selected:after:to-accent-600",
|
|
619
|
-
"es:after:rounded-t-full es:selected:after:shadow-
|
|
618
|
+
"es:after:rounded-t-full es:selected:after:shadow-sm es:selected:after:shadow-accent-700/30 es:after:transition"
|
|
620
619
|
]
|
|
621
620
|
},
|
|
622
621
|
{
|
|
@@ -626,7 +625,7 @@ const Tab = (props) => {
|
|
|
626
625
|
"es:pl-3 es:pr-2 es:py-2.5 es:rounded-lg es:selected:bg-accent-50/50 es:selected:text-accent-950 es:transition",
|
|
627
626
|
'es:after:content-[""] es:after:absolute es:after:-left-0 es:after:top-0 es:after:bottom-0 es:after:h-5/6 es:after:my-auto es:after:w-1',
|
|
628
627
|
"es:after:bg-linear-to-r es:hover:not-selected:not-disabled:after:from-secondary-200 es:hover:not-selected:not-disabled:after:to-secondary-300 es:selected:after:from-accent-500 es:selected:after:to-accent-600",
|
|
629
|
-
"es:after:rounded-full es:selected:after:shadow-
|
|
628
|
+
"es:after:rounded-full es:selected:after:shadow-sm es:selected:after:shadow-accent-700/30 es:after:transition"
|
|
630
629
|
]
|
|
631
630
|
}
|
|
632
631
|
]
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { a as $64fa3d84918910a7$export$29f1550f4b0d4415, l as $df56164dff5785e2$export$4338b53315abf666, m as $5dc95899b306f630$export$c9058316764c140e, h as $64fa3d84918910a7$export$ef03459518577ad4, b as $64fa3d84918910a7$export$4d86445c2cf5e3, d as $3ef42575df84b30b$export$9d1611c77c2fe928 } from "../../utils-
|
|
2
|
+
import { a as $64fa3d84918910a7$export$29f1550f4b0d4415, l as $df56164dff5785e2$export$4338b53315abf666, m as $5dc95899b306f630$export$c9058316764c140e, h as $64fa3d84918910a7$export$ef03459518577ad4, b as $64fa3d84918910a7$export$4d86445c2cf5e3, d as $3ef42575df84b30b$export$9d1611c77c2fe928 } from "../../utils-CZt7LCbO.js";
|
|
3
3
|
import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
|
|
4
4
|
import React__default, { forwardRef, createContext } from "react";
|
|
5
|
-
import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-
|
|
6
|
-
import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577 } from "../../useToggle-
|
|
7
|
-
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-
|
|
8
|
-
import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../useHover-
|
|
9
|
-
import { $ as $5c3e21d68f1c4674$export$439d29a4e110a164 } from "../../VisuallyHidden-
|
|
5
|
+
import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-ibcBUHnB.js";
|
|
6
|
+
import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577 } from "../../useToggle-CDa3YAZI.js";
|
|
7
|
+
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-Bv0UJQl8.js";
|
|
8
|
+
import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../useHover-C2SkI1Fn.js";
|
|
9
|
+
import { $ as $5c3e21d68f1c4674$export$439d29a4e110a164 } from "../../VisuallyHidden-BYi0pekx.js";
|
|
10
10
|
import { c as clsx } from "../../lite-DVmmD_-j.js";
|
|
11
11
|
function $b418ec0c85c52f27$export$d853f7095ae95f88(props, state, ref) {
|
|
12
12
|
let { labelProps, inputProps, isSelected, isPressed, isDisabled, isReadOnly } = $d2c8e2b0480f3f34$export$cbe85ee05b554577(props, state, ref);
|
|
@@ -128,7 +128,7 @@ const Switch2 = (props) => {
|
|
|
128
128
|
!checked && !disabled && "es:border-secondary-400 es:inset-ring-secondary-100 es:from-white es:to-secondary-100",
|
|
129
129
|
checked && !disabled && "es:border-accent-700/75 es:inset-ring-accent-500 es:to-accent-500 es:from-accent-600 es:shadow-accent-600/30",
|
|
130
130
|
disabled && "es:cursor-default es:border-secondary-300 es:from-white es:to-secondary-50 es:inset-ring-secondary-200/30 es:inset-shadow-secondary-100",
|
|
131
|
-
!disabled && "es:shadow-
|
|
131
|
+
!disabled && "es:shadow-sm"
|
|
132
132
|
),
|
|
133
133
|
children: /* @__PURE__ */ jsx(
|
|
134
134
|
"span",
|
|
@@ -139,7 +139,7 @@ const Switch2 = (props) => {
|
|
|
139
139
|
!checked && "es:scale-95",
|
|
140
140
|
!checked && !disabled && "es:border-secondary-500 es:from-secondary-500 es:to-secondary-600",
|
|
141
141
|
checked && "es:translate-x-4",
|
|
142
|
-
checked && !disabled && "es:border-accent-600/20 es:from-white es:to-accent-500/30 es:from-40% es:bg-white es:shadow-
|
|
142
|
+
checked && !disabled && "es:border-accent-600/20 es:from-white es:to-accent-500/30 es:from-40% es:bg-white es:shadow-sm es:shadow-accent-900/60",
|
|
143
143
|
disabled && "es:border-secondary-400 es:bg-secondary-100",
|
|
144
144
|
isIndeterminate && "es:translate-x-2 es:scale-100"
|
|
145
145
|
)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-
|
|
2
|
+
import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-JS_ob-kh.js";
|
|
3
3
|
import { Switch } from "./switch.js";
|
|
4
4
|
import { RichLabel } from "../rich-label/rich-label.js";
|
|
5
5
|
/**
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { p as $ff5963eb1fccf552$export$e08e3b67e392101e, d as $3ef42575df84b30b$export$9d1611c77c2fe928, a as $64fa3d84918910a7$export$29f1550f4b0d4415, b as $64fa3d84918910a7$export$4d86445c2cf5e3 } from "../../utils-
|
|
2
|
+
import { p as $ff5963eb1fccf552$export$e08e3b67e392101e, d as $3ef42575df84b30b$export$9d1611c77c2fe928, a as $64fa3d84918910a7$export$29f1550f4b0d4415, b as $64fa3d84918910a7$export$4d86445c2cf5e3 } from "../../utils-CZt7LCbO.js";
|
|
3
3
|
import React__default, { createContext, forwardRef, useContext } from "react";
|
|
4
|
-
import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-
|
|
5
|
-
import { $ as $701a24aa0da5b062$export$ea18c227d4417cc3 } from "../../useButton-
|
|
6
|
-
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-
|
|
7
|
-
import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../useHover-
|
|
8
|
-
import { c as cva } from "../../index-
|
|
4
|
+
import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-ibcBUHnB.js";
|
|
5
|
+
import { $ as $701a24aa0da5b062$export$ea18c227d4417cc3 } from "../../useButton-Bt3BffJm.js";
|
|
6
|
+
import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-Bv0UJQl8.js";
|
|
7
|
+
import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../useHover-C2SkI1Fn.js";
|
|
8
|
+
import { c as cva } from "../../index-BljRBEr_.js";
|
|
9
9
|
import { Tooltip } from "../tooltip/tooltip.js";
|
|
10
10
|
function $55f54f7887471b58$export$51e84d46ca0bc451(props, state, ref) {
|
|
11
11
|
const { isSelected } = state;
|
|
@@ -102,8 +102,8 @@ const $efde0372d7a700fe$export$d2b052e7b4be1756 = /* @__PURE__ */ forwardRef(fun
|
|
|
102
102
|
* @component
|
|
103
103
|
* @param {Object} props - Component props.
|
|
104
104
|
* @param {JSX.Element} [props.icon] - Icon to display within the button.
|
|
105
|
-
* @param {
|
|
106
|
-
* @param {
|
|
105
|
+
* @param {ToggleButtonSize} [props.size='default'] - The size of the button.
|
|
106
|
+
* @param {ToggleButtonType} [props.type='default'] - The type of the button.
|
|
107
107
|
* @param {boolean} [props.disabled] - If `true`, the button is disabled.
|
|
108
108
|
* @param {string} [props.className] - Classes to pass to the button.
|
|
109
109
|
* @param {string|boolean} [props.tooltip] - Tooltip text to display on hover.
|
|
@@ -113,10 +113,10 @@ const $efde0372d7a700fe$export$d2b052e7b4be1756 = /* @__PURE__ */ forwardRef(fun
|
|
|
113
113
|
* @param {Object} [props.tooltipProps] - Props to pass to the tooltip.
|
|
114
114
|
* @param {boolean} [props.hidden] - If `true`, the component is not rendered.
|
|
115
115
|
*
|
|
116
|
-
* @returns {JSX.Element} The
|
|
116
|
+
* @returns {JSX.Element} The ToggleButton component.
|
|
117
117
|
*
|
|
118
|
-
* @typedef {'small' | 'default' | 'large'}
|
|
119
|
-
* @typedef {'default'
|
|
118
|
+
* @typedef {'small' | 'default' | 'large'} ToggleButtonSize
|
|
119
|
+
* @typedef {'default'| 'ghost'} ToggleButtonType
|
|
120
120
|
*
|
|
121
121
|
* @example
|
|
122
122
|
* const [selected, setSelected] = useState(false);
|
|
@@ -167,6 +167,7 @@ const ToggleButton2 = (props) => {
|
|
|
167
167
|
"es:btn-group-mid:rounded-none",
|
|
168
168
|
"es:btn-group-h-start:rounded-r-none es:btn-group-v-start:rounded-b-none",
|
|
169
169
|
"es:btn-group-h-end:rounded-l-none es:btn-group-v-end:rounded-t-none",
|
|
170
|
+
"es:enabled:hover:shadow-md es:enabled:active:shadow-sm es:enabled:pressed:shadow-sm",
|
|
170
171
|
"es:cursor-pointer",
|
|
171
172
|
icon && children ? "es:justify-start" : "es:justify-center",
|
|
172
173
|
className
|
|
@@ -174,9 +175,9 @@ const ToggleButton2 = (props) => {
|
|
|
174
175
|
{
|
|
175
176
|
variants: {
|
|
176
177
|
size: {
|
|
177
|
-
small: "es:icon:size-4.5 es:rounded-
|
|
178
|
-
default: "es:icon:size-5.5 es:rounded-
|
|
179
|
-
large: "es:icon:size-6 es:rounded-
|
|
178
|
+
small: "es:icon:size-4.5 es:rounded-7",
|
|
179
|
+
default: "es:icon:size-5.5 es:rounded-10",
|
|
180
|
+
large: "es:icon:size-6 es:rounded-xl"
|
|
180
181
|
},
|
|
181
182
|
type: {
|
|
182
183
|
default: ["es:bg-radial-[at_50%_125%]", "es:inset-ring es:inset-shadow-xs"],
|
|
@@ -194,7 +195,7 @@ const ToggleButton2 = (props) => {
|
|
|
194
195
|
"es:border-secondary-300",
|
|
195
196
|
"es:inset-ring-secondary-100",
|
|
196
197
|
"es:inset-shadow-secondary-100/50",
|
|
197
|
-
"es:shadow-
|
|
198
|
+
"es:shadow-sm",
|
|
198
199
|
"es:hover:inset-shadow-secondary-100 es:hover:to-secondary-100 es:hover:inset-ring-secondary-100",
|
|
199
200
|
"es:hover:text-accent-950",
|
|
200
201
|
"es:focus-visible:text-accent-950"
|
|
@@ -213,7 +214,7 @@ const ToggleButton2 = (props) => {
|
|
|
213
214
|
"es:focus-visible:border-accent-700",
|
|
214
215
|
"es:focus-visible:inset-ring es:focus-visible:inset-ring-accent-600",
|
|
215
216
|
"es:focus-visible:inset-shadow-xs es:focus-visible:inset-shadow-accent-400",
|
|
216
|
-
"es:shadow-
|
|
217
|
+
"es:shadow-sm es:shadow-accent-600/30"
|
|
217
218
|
]
|
|
218
219
|
},
|
|
219
220
|
{
|
|
@@ -224,7 +225,7 @@ const ToggleButton2 = (props) => {
|
|
|
224
225
|
type: "ghost",
|
|
225
226
|
disabled: false,
|
|
226
227
|
selected: true,
|
|
227
|
-
class: ["es:bg-accent-600 es:text-white es:border-accent-600 es:shadow-
|
|
228
|
+
class: ["es:bg-accent-600 es:text-white es:border-accent-600 es:shadow-sm es:shadow-accent-500/25", "es:hover:shadow-accent-600/50"]
|
|
228
229
|
},
|
|
229
230
|
// Sizes.
|
|
230
231
|
{
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { c as $96b38030c423d352$export$9fc1347d4195ccb3, $ as $fc909762b330b746$export$61c6a8c84e605fb6, a as $d3f049242431219c$export$45fda7c47f93fd48, d as $2a41e45df1593e64$export$d39e1813b3bdd0e1, b as $d3f049242431219c$export$6d3443f2c48bfc20, e as $44f671af83e7d9e0$export$2de4954e8ae13b9f, f as $44f671af83e7d9e0$export$746d02f47f4d381 } from "../../OverlayArrow-
|
|
3
|
-
import { n as $b5e257d569688ac6$export$535bd6ca7f90a273, d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, i as $64fa3d84918910a7$export$2881499e37b75b9a, a as $64fa3d84918910a7$export$29f1550f4b0d4415, k as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, b as $64fa3d84918910a7$export$4d86445c2cf5e3 } from "../../utils-
|
|
4
|
-
import { $ as $6179b936705e76d3$export$ae780daf29e6d456, a as $f645667febf57a63$export$4c014de7c8940b4c, x as $507fabe10e71c6fb$export$630ff653c5ada6a9, n as $507fabe10e71c6fb$export$b9b3dfddab17db27, y as $f645667febf57a63$export$13f3202a3e5ddd5 } from "../../useHover-
|
|
2
|
+
import { c as $96b38030c423d352$export$9fc1347d4195ccb3, $ as $fc909762b330b746$export$61c6a8c84e605fb6, a as $d3f049242431219c$export$45fda7c47f93fd48, d as $2a41e45df1593e64$export$d39e1813b3bdd0e1, b as $d3f049242431219c$export$6d3443f2c48bfc20, e as $44f671af83e7d9e0$export$2de4954e8ae13b9f, f as $44f671af83e7d9e0$export$746d02f47f4d381 } from "../../OverlayArrow-5aDgmImj.js";
|
|
3
|
+
import { n as $b5e257d569688ac6$export$535bd6ca7f90a273, d as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, i as $64fa3d84918910a7$export$2881499e37b75b9a, a as $64fa3d84918910a7$export$29f1550f4b0d4415, k as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, b as $64fa3d84918910a7$export$4d86445c2cf5e3 } from "../../utils-CZt7LCbO.js";
|
|
4
|
+
import { $ as $6179b936705e76d3$export$ae780daf29e6d456, a as $f645667febf57a63$export$4c014de7c8940b4c, x as $507fabe10e71c6fb$export$630ff653c5ada6a9, n as $507fabe10e71c6fb$export$b9b3dfddab17db27, y as $f645667febf57a63$export$13f3202a3e5ddd5 } from "../../useHover-C2SkI1Fn.js";
|
|
5
5
|
import React__default, { useContext, useState, useMemo, useRef, useEffect, forwardRef, createContext } from "react";
|
|
6
6
|
import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
|
|
7
7
|
import { $ as $dbSRa$reactdom } from "../../index-CFozsmNS.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React__default, { useState, useEffect, useContext } from "react";
|
|
2
|
-
import { n as $b5e257d569688ac6$export$535bd6ca7f90a273 } from "./utils-
|
|
2
|
+
import { n as $b5e257d569688ac6$export$535bd6ca7f90a273 } from "./utils-CZt7LCbO.js";
|
|
3
3
|
const $148a7a147e38ea7f$var$RTL_SCRIPTS = /* @__PURE__ */ new Set([
|
|
4
4
|
"Arab",
|
|
5
5
|
"Syrc",
|