@eightshift/ui-components 1.7.2 → 1.9.0

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.
Files changed (113) hide show
  1. package/dist/{Button-VbCAu4hd.js → Button-BMFbEXg1.js} +7 -7
  2. package/dist/{Color-BpLubxWI.js → Color-B-cqXgPz.js} +5 -17
  3. package/dist/{ColorSwatch-CinC14s3.js → ColorSwatch-B6s54Jb3.js} +4 -4
  4. package/dist/ComboBox-VR9-vNZv.js +1886 -0
  5. package/dist/Dialog-BlYTPzgB.js +2177 -0
  6. package/dist/{FieldError-BttM1Nxd.js → FieldError-DKicm3R0.js} +2 -2
  7. package/dist/{FocusScope-CtCX0OGo.js → FocusScope-EoLYfbMp.js} +11 -12
  8. package/dist/{Group-XzWUooix.js → Group-D96edUPC.js} +5 -5
  9. package/dist/{Heading-DZelepHV.js → Heading-GytTjUsy.js} +1 -1
  10. package/dist/{Hidden-CcFqOzrp.js → Hidden-D3hHnmPI.js} +2 -2
  11. package/dist/{Input-CV1qVS6t.js → Input-BXSxJ_44.js} +10 -10
  12. package/dist/{Label-BwqMVkuV.js → Label-BtoiUpt8.js} +2 -2
  13. package/dist/{List-Bx2anbX-.js → List-Ct3nzFZG.js} +1 -1
  14. package/dist/{ListBox-DuZPdnkk.js → ListBox-BMpo-Cem.js} +19 -18
  15. package/dist/{NumberFormatter-U_Gx0UDq.js → NumberFormatter-DA8u1Ot7.js} +4 -6
  16. package/dist/OverlayArrow-4epQ99-E.js +567 -0
  17. package/dist/{Select-c7902d94.esm-DtzFQzf-.js → Select-aab027f3.esm-C7BxKjSc.js} +4 -4
  18. package/dist/{SelectionManager-x27KqnAT.js → SelectionManager-D-89MUJW.js} +276 -291
  19. package/dist/{Separator-BM58t3PP.js → Separator-DUhFmbD-.js} +62 -52
  20. package/dist/{Slider-D9Cs6yKr.js → Slider-QNPrj4N9.js} +16 -14
  21. package/dist/{Text-BVIXT8qq.js → Text-DNDWaukZ.js} +1 -1
  22. package/dist/{VisuallyHidden-WhC7vZaL.js → VisuallyHidden-BHNhi-ls.js} +2 -2
  23. package/dist/assets/style.css +1 -1
  24. package/dist/assets/wp-ui-enhancements.css +1 -1
  25. package/dist/components/animated-visibility/animated-visibility.js +67 -7245
  26. package/dist/components/base-control/base-control.js +1 -1
  27. package/dist/components/button/button.js +10 -7
  28. package/dist/components/checkbox/checkbox.js +22 -13
  29. package/dist/components/color-pickers/color-picker.js +1 -1
  30. package/dist/components/color-pickers/color-swatch.js +3 -3
  31. package/dist/components/color-pickers/gradient-editor.js +2 -2
  32. package/dist/components/color-pickers/solid-color-picker.js +21 -21
  33. package/dist/components/component-toggle/component-toggle.js +1 -1
  34. package/dist/components/container-panel/container-panel.js +6 -4
  35. package/dist/components/draggable/draggable-handle.js +2 -2
  36. package/dist/components/draggable/draggable.js +2 -2
  37. package/dist/components/draggable-list/draggable-list-item.js +2 -2
  38. package/dist/components/draggable-list/draggable-list.js +2 -2
  39. package/dist/components/expandable/expandable.js +221 -26
  40. package/dist/components/index.js +8 -4
  41. package/dist/components/input-field/input-field.js +7 -7
  42. package/dist/components/item-collection/item-collection.js +1 -1
  43. package/dist/components/link-input/link-input.js +10 -1872
  44. package/dist/components/list-box/list-box.js +2 -2
  45. package/dist/components/matrix-align/matrix-align.js +2 -2
  46. package/dist/components/menu/menu.js +7 -974
  47. package/dist/components/modal/modal.js +7 -7
  48. package/dist/components/number-picker/number-picker.js +10 -10
  49. package/dist/components/option-select/option-select.js +1 -1
  50. package/dist/components/options-panel/options-panel.js +1 -1
  51. package/dist/components/placeholders/file-placeholder.js +1 -1
  52. package/dist/components/popover/popover.js +2 -2
  53. package/dist/components/radio/radio.js +13 -13
  54. package/dist/components/repeater/repeater-item.js +1 -1
  55. package/dist/components/repeater/repeater.js +2 -2
  56. package/dist/components/responsive/mini-responsive.js +3 -3
  57. package/dist/components/responsive/responsive-legacy.js +2 -2
  58. package/dist/components/responsive/responsive.js +2 -2
  59. package/dist/components/responsive-preview/responsive-preview.js +1 -1
  60. package/dist/components/select/async-multi-select.js +3 -3
  61. package/dist/components/select/async-single-select.js +2 -2
  62. package/dist/components/select/custom-select-default-components.js +1 -1
  63. package/dist/components/select/multi-select-components.js +1 -1
  64. package/dist/components/select/multi-select.js +3 -3
  65. package/dist/components/select/react-select-component-wrappers.js +1 -1
  66. package/dist/components/select/single-select.js +2 -2
  67. package/dist/components/select/v2/async-select.js +307 -0
  68. package/dist/components/select/v2/shared.js +24 -0
  69. package/dist/components/select/v2/single-select.js +993 -0
  70. package/dist/components/slider/column-config-slider.js +3 -3
  71. package/dist/components/slider/slider.js +3 -3
  72. package/dist/components/slider/utils.js +1 -1
  73. package/dist/components/tabs/tabs.js +16 -16
  74. package/dist/components/toggle/switch.js +6 -6
  75. package/dist/components/toggle/toggle.js +1 -1
  76. package/dist/components/toggle-button/toggle-button.js +55 -12
  77. package/dist/components/tooltip/tooltip.js +532 -8
  78. package/dist/{context-Cs-ZD1nu.js → context-KeRYAbEi.js} +2 -2
  79. package/dist/{default-i18n-DRnM8y4w.js → default-i18n-CM1-Xvzf.js} +183 -176
  80. package/dist/{focusSafely-CgFLw4FA.js → focusSafely-CZY36ssv.js} +14 -14
  81. package/dist/icons/icons.js +131 -0
  82. package/dist/icons/jsx-svg.js +16 -3
  83. package/dist/{index-a301f526.esm-BMg114iK.js → index-641ee5b8.esm-DEB-c58F.js} +226 -75
  84. package/dist/index-BYHhzLf-.js +444 -0
  85. package/dist/index.js +7 -3
  86. package/dist/{multi-select-components-DTvEidE3.js → multi-select-components-DM3GsNfb.js} +112 -45
  87. package/dist/{react-jsx-parser.min-B5HVwW_W.js → react-jsx-parser.min-CVit0rZn.js} +5620 -7409
  88. package/dist/{react-select-async.esm-CxA8wpeT.js → react-select-async.esm-Bq3N1-Wi.js} +3 -3
  89. package/dist/{react-select.esm-CeE7o5M9.js → react-select.esm-B38nY7_U.js} +3 -3
  90. package/dist/{textSelection-CvK0YHTZ.js → textSelection-G2G-nukT.js} +1 -1
  91. package/dist/{useButton-Cy9eEev7.js → useButton-CFtcz1T6.js} +4 -4
  92. package/dist/{useEvent-LZebwyrb.js → useEvent-B0yfN_Zu.js} +1 -1
  93. package/dist/{useFocusRing-BMOTWmOx.js → useFocusRing-DMAlRYjX.js} +1 -1
  94. package/dist/{useFocusable-ByyKSVQv.js → useFocusable-BlkOMLma.js} +4 -4
  95. package/dist/{useFormReset-B8m1uz1J.js → useFormReset-BAEM0o25.js} +1 -1
  96. package/dist/{useFormValidationState-BjMhz_VI.js → useFormValidation-BNzOc2t9.js} +92 -88
  97. package/dist/{useLabel-B6uO0wVK.js → useLabel-D6FSp5_M.js} +2 -2
  98. package/dist/{useLabels-5dFkeiXx.js → useLabels-CraZ2Sej.js} +1 -1
  99. package/dist/{useListState-eKxv7HPC.js → useListState-C3dnPq2F.js} +1 -1
  100. package/dist/{useLocalizedStringFormatter-BaKmjFNp.js → useLocalizedStringFormatter-B73fhEA7.js} +1 -1
  101. package/dist/{useNumberField-DMMUTZ-h.js → useNumberField-CQP9-nH5.js} +27 -20
  102. package/dist/{useNumberFormatter-Cyx5Dxkf.js → useNumberFormatter-Cdctl6fg.js} +2 -2
  103. package/dist/{usePress-D8nPoIQm.js → usePress-xTkcGUkt.js} +4 -4
  104. package/dist/{useSingleSelectListState-CABciySJ.js → useSingleSelectListState-BGXQSTy7.js} +2 -2
  105. package/dist/{useToggle-BmltE9Zr.js → useToggle-Dpw3WpSw.js} +4 -4
  106. package/dist/{useToggleState-DZXLEnA_.js → useToggleState-BSKwCUIW.js} +1 -1
  107. package/dist/{utils-BCJajCwh.js → utils-BSLBwuuO.js} +16 -15
  108. package/package.json +30 -31
  109. package/dist/Dialog-BN5EE7UH.js +0 -934
  110. package/dist/index-BTCzc3zb.js +0 -28261
  111. package/dist/isScrollable-Dh9D9IOd.js +0 -9
  112. package/dist/tooltip-eKaARDoV.js +0 -1084
  113. package/dist/useMenuTrigger-4fwEmto8.js +0 -246
@@ -1,5 +1,5 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../Text-BVIXT8qq.js";
2
+ import { $ as $514c0188e459b4c0$export$5f1af8db9871e1d6 } from "../../Text-DNDWaukZ.js";
3
3
  import { c as clsx } from "../../lite-DVmmD_-j.js";
4
4
  import { RichLabel } from "../rich-label/rich-label.js";
5
5
  /**
@@ -1,13 +1,13 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import { a as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../Button-VbCAu4hd.js";
3
- import { j as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, a as $64fa3d84918910a7$export$29f1550f4b0d4415, b as $64fa3d84918910a7$export$4d86445c2cf5e3, c as $3ef42575df84b30b$export$9d1611c77c2fe928, l as $df56164dff5785e2$export$4338b53315abf666 } from "../../utils-BCJajCwh.js";
4
- import { a as $9bf71ea28793e738$export$c5251b9e124bf29 } from "../../FocusScope-CtCX0OGo.js";
5
- import React__default, { useState, useRef, forwardRef, createContext } from "react";
6
- import { $ as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7 } from "../../context-Cs-ZD1nu.js";
2
+ import { $ as $d2b4bc8c273e7be6$export$353f5b6fc5456de1 } from "../../Button-BMFbEXg1.js";
3
+ import { l as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, a as $64fa3d84918910a7$export$29f1550f4b0d4415, b as $64fa3d84918910a7$export$4d86445c2cf5e3, d as $3ef42575df84b30b$export$9d1611c77c2fe928, m as $df56164dff5785e2$export$4338b53315abf666 } from "../../utils-BSLBwuuO.js";
4
+ import { $ as $9bf71ea28793e738$export$c5251b9e124bf29 } from "../../FocusScope-EoLYfbMp.js";
7
5
  import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
6
+ import React__default, { useState, useRef, forwardRef, createContext } from "react";
7
+ import { $ as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7 } from "../../context-KeRYAbEi.js";
8
8
  import { c as clsx } from "../../lite-DVmmD_-j.js";
9
- import { T as Tooltip } from "../../tooltip-eKaARDoV.js";
10
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
9
+ import { Tooltip } from "../tooltip/tooltip.js";
10
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
11
11
  function $2680b1829e803644$export$fa142eb1681c520(props, ref) {
12
12
  const { "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, orientation = "horizontal" } = props;
13
13
  let [isInToolbar, setInToolbar] = useState(false);
@@ -51,6 +51,9 @@ function $2680b1829e803644$export$fa142eb1681c520(props, ref) {
51
51
  };
52
52
  return {
53
53
  toolbarProps: {
54
+ ...$65484d02dcb7eb3e$export$457c3d6518dd4c6f(props, {
55
+ labelable: true
56
+ }),
54
57
  role: !isInToolbar ? "toolbar" : "group",
55
58
  "aria-orientation": orientation,
56
59
  "aria-label": ariaLabel,
@@ -1,15 +1,16 @@
1
1
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
2
  import { a as $4e85f108e88277b8$export$b085522c77523c51 } from "../../RSPContexts-2lR5GG9p.js";
3
- import { a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e, l as $df56164dff5785e2$export$4338b53315abf666, m as $5dc95899b306f630$export$c9058316764c140e, b as $64fa3d84918910a7$export$4d86445c2cf5e3, c as $3ef42575df84b30b$export$9d1611c77c2fe928 } from "../../utils-BCJajCwh.js";
3
+ import { d as $3ef42575df84b30b$export$9d1611c77c2fe928, a as $64fa3d84918910a7$export$29f1550f4b0d4415, $ as $64fa3d84918910a7$export$fabf2dc03a41866e, m as $df56164dff5785e2$export$4338b53315abf666, n as $5dc95899b306f630$export$c9058316764c140e, i as $64fa3d84918910a7$export$ef03459518577ad4, b as $64fa3d84918910a7$export$4d86445c2cf5e3 } from "../../utils-BSLBwuuO.js";
4
4
  import { $ as $d3e0e05bdfcf66bd$export$c24727297075ec6a } from "../../Form-Cq3fu75_.js";
5
5
  import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
6
6
  import React__default, { useEffect, useRef, forwardRef, useContext, createContext } from "react";
7
- import { $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10, a as $e93e671b31057976$export$b8473d3665f3a75a, b as $e5be200c675c3b3a$export$dad6ae84456c676a, c as $e5be200c675c3b3a$export$a763b9476acd3eb } from "../../useFormValidationState-BjMhz_VI.js";
8
- import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577 } from "../../useToggle-BmltE9Zr.js";
9
- import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-DZXLEnA_.js";
10
- import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-BMOTWmOx.js";
11
- import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../focusSafely-CgFLw4FA.js";
12
- import { $ as $5c3e21d68f1c4674$export$439d29a4e110a164 } from "../../VisuallyHidden-WhC7vZaL.js";
7
+ import { $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10, a as $e93e671b31057976$export$b8473d3665f3a75a, b as $e5be200c675c3b3a$export$a763b9476acd3eb, c as $e5be200c675c3b3a$export$dad6ae84456c676a } from "../../useFormValidation-BNzOc2t9.js";
8
+ import { $ as $f6c31cce2adf654f$export$45712eceda6fad21 } from "../../usePress-xTkcGUkt.js";
9
+ import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577 } from "../../useToggle-Dpw3WpSw.js";
10
+ import { $ as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../../useToggleState-BSKwCUIW.js";
11
+ import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-DMAlRYjX.js";
12
+ import { $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../focusSafely-CZY36ssv.js";
13
+ import { $ as $5c3e21d68f1c4674$export$439d29a4e110a164 } from "../../VisuallyHidden-BHNhi-ls.js";
13
14
  import { c as clsx } from "../../lite-DVmmD_-j.js";
14
15
  import { AnimatedVisibility } from "../animated-visibility/animated-visibility.js";
15
16
  import { icons } from "../../icons/icons.js";
@@ -29,8 +30,16 @@ function $406796ff087fe49b$export$e375f10ce42261c5(props, state, inputRef) {
29
30
  useEffect(() => {
30
31
  if (inputRef.current) inputRef.current.indeterminate = !!isIndeterminate;
31
32
  });
33
+ let { pressProps } = $f6c31cce2adf654f$export$45712eceda6fad21({
34
+ isDisabled: isDisabled || isReadOnly,
35
+ onPress() {
36
+ let { [$e5be200c675c3b3a$export$a763b9476acd3eb]: groupValidationState } = props;
37
+ let { commitValidation } = groupValidationState ? groupValidationState : validationState;
38
+ commitValidation();
39
+ }
40
+ });
32
41
  return {
33
- labelProps,
42
+ labelProps: $3ef42575df84b30b$export$9d1611c77c2fe928(labelProps, pressProps),
34
43
  inputProps: {
35
44
  ...inputProps,
36
45
  checked: isSelected,
@@ -115,7 +124,7 @@ function $bc237834342dbd75$var$Checkbox(props, ref) {
115
124
  let groupState = useContext($bc237834342dbd75$export$139c5b8563afc1fc);
116
125
  let inputRef = $df56164dff5785e2$export$4338b53315abf666($5dc95899b306f630$export$c9058316764c140e(userProvidedInputRef, props.inputRef !== void 0 ? props.inputRef : null));
117
126
  let { labelProps, inputProps, isSelected, isDisabled, isReadOnly, isPressed, isInvalid } = groupState ? $fba3e38d5ca8983f$export$353b32fc6898d37d({
118
- ...props,
127
+ ...$64fa3d84918910a7$export$ef03459518577ad4(props),
119
128
  // Value is optional for standalone checkboxes, but required for CheckboxGroup items;
120
129
  // it's passed explicitly here to avoid typescript error (requires ignore).
121
130
  // @ts-ignore
@@ -123,7 +132,7 @@ function $bc237834342dbd75$var$Checkbox(props, ref) {
123
132
  // ReactNode type doesn't allow function children.
124
133
  children: typeof props.children === "function" ? true : props.children
125
134
  }, groupState, inputRef) : $406796ff087fe49b$export$e375f10ce42261c5({
126
- ...props,
135
+ ...$64fa3d84918910a7$export$ef03459518577ad4(props),
127
136
  children: typeof props.children === "function" ? true : props.children,
128
137
  validationBehavior
129
138
  }, $3017fa7ffdddec74$export$8042c6c013fd5226(props), inputRef);
@@ -134,7 +143,6 @@ function $bc237834342dbd75$var$Checkbox(props, ref) {
134
143
  isDisabled: isInteractionDisabled
135
144
  });
136
145
  let renderProps = $64fa3d84918910a7$export$4d86445c2cf5e3({
137
- // TODO: should data attrs go on the label or on the <input>? useCheckbox passes them to the input...
138
146
  ...props,
139
147
  defaultClassName: "react-aria-Checkbox",
140
148
  values: {
@@ -257,7 +265,8 @@ const Checkbox = (props) => {
257
265
  {
258
266
  transition: "scaleFade",
259
267
  visible: isIndeterminate,
260
- children: /* @__PURE__ */ jsx("div", { className: "es-uic-h-[1.5px] es-uic-w-3 es-uic-rounded es-uic-bg-white" })
268
+ className: "es-uic-transition-none",
269
+ children: /* @__PURE__ */ jsx("div", { className: "es-uic-h-0.5 es-uic-w-3 es-uic-rounded es-uic-bg-white" })
261
270
  }
262
271
  ),
263
272
  /* @__PURE__ */ jsx(
@@ -265,7 +274,7 @@ const Checkbox = (props) => {
265
274
  {
266
275
  transition: "scaleRotateFade",
267
276
  visible: !isIndeterminate && isSelected,
268
- className: "[&>svg]:es-uic-size-3 [&>svg]:es-uic-stroke-2",
277
+ className: "es-uic-transition-none [&>svg]:es-uic-size-3 [&>svg]:es-uic-stroke-[3]",
269
278
  noInitial: true,
270
279
  children: icons.check
271
280
  }
@@ -1,5 +1,5 @@
1
1
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
2
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
3
3
  import { Menu, MenuItem, MenuSeparator, MenuSection } from "../menu/menu.js";
4
4
  import { ColorSwatch } from "./color-swatch.js";
5
5
  import { RichLabel } from "../rich-label/rich-label.js";
@@ -1,8 +1,8 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
- import { $ as $251c695a52d94a8d$export$cae13e90592f246a } from "../../ColorSwatch-CinC14s3.js";
3
- import { $ as $799cddbef784668f$export$6e865ea70d7724f } from "../../Color-BpLubxWI.js";
2
+ import { $ as $251c695a52d94a8d$export$cae13e90592f246a } from "../../ColorSwatch-B6s54Jb3.js";
3
+ import { $ as $799cddbef784668f$export$6e865ea70d7724f } from "../../Color-B-cqXgPz.js";
4
4
  import { c as clsx } from "../../lite-DVmmD_-j.js";
5
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
5
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
6
6
  /**
7
7
  * A simple color/gradient swatch.
8
8
  *
@@ -1,12 +1,12 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { _ as __, s as sprintf } from "../../default-i18n-DRnM8y4w.js";
2
+ import { _ as __, s as sprintf } from "../../default-i18n-CM1-Xvzf.js";
3
3
  import { useMemo, useState } from "react";
4
4
  import { Button, ButtonGroup } from "../button/button.js";
5
5
  import { icons } from "../../icons/icons.js";
6
6
  import { SolidColorPicker } from "./solid-color-picker.js";
7
7
  import { Slider } from "../slider/slider.js";
8
8
  import { NumberPicker } from "../number-picker/number-picker.js";
9
- import { $ as $251c695a52d94a8d$export$cae13e90592f246a } from "../../ColorSwatch-CinC14s3.js";
9
+ import { $ as $251c695a52d94a8d$export$cae13e90592f246a } from "../../ColorSwatch-B6s54Jb3.js";
10
10
  import { Menu, MenuItem } from "../menu/menu.js";
11
11
  import { MatrixAlign } from "../matrix-align/matrix-align.js";
12
12
  import { Spacer } from "../spacer/spacer.js";
@@ -1,29 +1,29 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import React__default, { useMemo, useRef, useState, useCallback, forwardRef, useContext, createContext } from "react";
3
3
  import { b as $4e85f108e88277b8$export$ebe63fadcdce34ed, c as $4e85f108e88277b8$export$44644b8a16031b5b, d as $4e85f108e88277b8$export$717b2c0a523a0b53 } from "../../RSPContexts-2lR5GG9p.js";
4
- import { c as $3ef42575df84b30b$export$9d1611c77c2fe928, e as $bdb11010cef70236$export$f680877a34711e37, b as $64fa3d84918910a7$export$4d86445c2cf5e3, a as $64fa3d84918910a7$export$29f1550f4b0d4415, i as $64fa3d84918910a7$export$2881499e37b75b9a, g as $64fa3d84918910a7$export$9d4c57ee4c6ffdd8, h as $64fa3d84918910a7$export$ef03459518577ad4 } from "../../utils-BCJajCwh.js";
4
+ import { d as $3ef42575df84b30b$export$9d1611c77c2fe928, f as $bdb11010cef70236$export$f680877a34711e37, b as $64fa3d84918910a7$export$4d86445c2cf5e3, a as $64fa3d84918910a7$export$29f1550f4b0d4415, j as $64fa3d84918910a7$export$2881499e37b75b9a, h as $64fa3d84918910a7$export$9d4c57ee4c6ffdd8, i as $64fa3d84918910a7$export$ef03459518577ad4 } from "../../utils-BSLBwuuO.js";
5
5
  import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
6
- import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-BMOTWmOx.js";
7
- import { e as $458b0a5536c1a7cf$export$40bfa8c7b0832715, m as $7215afc6de606d6b$export$de79e2c695e052f3, d as $9ab94262bd0047c7$export$420e68273165f4ec, c as $a1ea59d68270f0dd$export$f8168d8dd8fd66e6, j as $c87311424ea30a05$export$fedb369cb70207f1, v as $c87311424ea30a05$export$a11b0059900ceec8, $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../focusSafely-CgFLw4FA.js";
8
- import { $ as $799cddbef784668f$export$6e865ea70d7724f, b as $799cddbef784668f$export$4cde5df63f53f473, a as $3493a52097159720$exports } from "../../Color-BpLubxWI.js";
6
+ import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-DMAlRYjX.js";
7
+ import { e as $458b0a5536c1a7cf$export$40bfa8c7b0832715, n as $7215afc6de606d6b$export$de79e2c695e052f3, d as $9ab94262bd0047c7$export$420e68273165f4ec, c as $a1ea59d68270f0dd$export$f8168d8dd8fd66e6, j as $c87311424ea30a05$export$fedb369cb70207f1, u as $c87311424ea30a05$export$a11b0059900ceec8, $ as $6179b936705e76d3$export$ae780daf29e6d456 } from "../../focusSafely-CZY36ssv.js";
8
+ import { $ as $799cddbef784668f$export$6e865ea70d7724f, b as $799cddbef784668f$export$4cde5df63f53f473, a as $3493a52097159720$exports } from "../../Color-B-cqXgPz.js";
9
9
  import { $ as $9446cca9a3875146$export$cb6e0bb50bc19463, a as $9446cca9a3875146$export$7d15b64cf5a3a4c4 } from "../../number-GajL10e1.js";
10
- import { $ as $03deb23ff14920c4$export$4eaf04e54aa8eed6 } from "../../textSelection-CvK0YHTZ.js";
11
- import { $ as $313b98861ee5dd6c$export$d6875122194c7b44 } from "../../useLabels-5dFkeiXx.js";
12
- import { $ as $99facab73266f662$export$5add1d006293d136 } from "../../useFormReset-B8m1uz1J.js";
13
- import { a as $46d819fcbaf35654$export$8f71654801c2f7cd } from "../../useFocusable-ByyKSVQv.js";
14
- import { e as $28f99e3e86e6ec45$export$e5fda3247f5d67f9, f as $e8a7022cf87cba2a$export$36da96379f79f245, g as $bcca50147b47f54d$export$56b2c08e277f365, h as $47b897dc8cdb026b$export$8d15029008292ae, d as $6f909507e6374d18$export$1e7083018727fa60, i as $6f909507e6374d18$export$f1fce0420cc6d8ee, j as $6f909507e6374d18$export$6189c2744041d8f8, a as $6f909507e6374d18$export$105594979f116971 } from "../../Slider-D9Cs6yKr.js";
15
- import { $ as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7 } from "../../context-Cs-ZD1nu.js";
16
- import { $ as $fca6afa0e843324b$export$f12b703ca79dfbb1 } from "../../useLocalizedStringFormatter-BaKmjFNp.js";
17
- import { a as $5c3e21d68f1c4674$export$a966af930f325cab } from "../../VisuallyHidden-WhC7vZaL.js";
18
- import { $ as $ee014567cb39d3f0$export$ff05c3ac10437e03 } from "../../FieldError-BttM1Nxd.js";
19
- import { $ as $3985021b0ad6602f$export$37fb8590cf2c088c, a as $3985021b0ad6602f$export$f5b8910cec6cf069 } from "../../Input-CV1qVS6t.js";
20
- import { a as $01b77f81d0f07f68$export$75b6ee27786ba447, $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-BwqMVkuV.js";
21
- import { a as $514c0188e459b4c0$export$9afb8bc826b033ea } from "../../Text-BVIXT8qq.js";
22
- import { $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10, c as $e5be200c675c3b3a$export$a763b9476acd3eb } from "../../useFormValidationState-BjMhz_VI.js";
23
- import { $ as $de67e98908f0c6ee$export$7f629e9dc1ecf37c, b as $d2e8511e6f209edf$export$e908e06f4b8e3402, c as $7d0a636d7a4dcefd$export$2123ff2b87c81ca, d as $d841c8010a73d545$export$4f384c9210e583c3, a as $81397a9303501bda$export$23f548e970bdf099 } from "../../useNumberField-DMMUTZ-h.js";
10
+ import { $ as $03deb23ff14920c4$export$4eaf04e54aa8eed6 } from "../../textSelection-G2G-nukT.js";
11
+ import { $ as $313b98861ee5dd6c$export$d6875122194c7b44 } from "../../useLabels-CraZ2Sej.js";
12
+ import { $ as $99facab73266f662$export$5add1d006293d136 } from "../../useFormReset-BAEM0o25.js";
13
+ import { b as $46d819fcbaf35654$export$8f71654801c2f7cd } from "../../useFocusable-BlkOMLma.js";
14
+ import { e as $28f99e3e86e6ec45$export$e5fda3247f5d67f9, f as $e8a7022cf87cba2a$export$36da96379f79f245, g as $bcca50147b47f54d$export$56b2c08e277f365, h as $47b897dc8cdb026b$export$8d15029008292ae, d as $6f909507e6374d18$export$1e7083018727fa60, i as $6f909507e6374d18$export$f1fce0420cc6d8ee, j as $6f909507e6374d18$export$6189c2744041d8f8, a as $6f909507e6374d18$export$105594979f116971 } from "../../Slider-QNPrj4N9.js";
15
+ import { $ as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7 } from "../../context-KeRYAbEi.js";
16
+ import { $ as $fca6afa0e843324b$export$f12b703ca79dfbb1 } from "../../useLocalizedStringFormatter-B73fhEA7.js";
17
+ import { a as $5c3e21d68f1c4674$export$a966af930f325cab } from "../../VisuallyHidden-BHNhi-ls.js";
18
+ import { $ as $ee014567cb39d3f0$export$ff05c3ac10437e03 } from "../../FieldError-DKicm3R0.js";
19
+ import { a as $3985021b0ad6602f$export$37fb8590cf2c088c, $ as $3985021b0ad6602f$export$f5b8910cec6cf069 } from "../../Input-BXSxJ_44.js";
20
+ import { a as $01b77f81d0f07f68$export$75b6ee27786ba447, $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-BtoiUpt8.js";
21
+ import { a as $514c0188e459b4c0$export$9afb8bc826b033ea } from "../../Text-DNDWaukZ.js";
22
+ import { $ as $e5be200c675c3b3a$export$fc1a364ae1f3ff10, b as $e5be200c675c3b3a$export$a763b9476acd3eb } from "../../useFormValidation-BNzOc2t9.js";
23
+ import { $ as $de67e98908f0c6ee$export$7f629e9dc1ecf37c, b as $d2e8511e6f209edf$export$e908e06f4b8e3402, c as $7d0a636d7a4dcefd$export$2123ff2b87c81ca, d as $d841c8010a73d545$export$4f384c9210e583c3, a as $81397a9303501bda$export$23f548e970bdf099 } from "../../useNumberField-CQP9-nH5.js";
24
24
  import { c as clsx } from "../../lite-DVmmD_-j.js";
25
25
  import { BaseControl } from "../base-control/base-control.js";
26
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
26
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
27
27
  import { TriggeredPopover } from "../popover/popover.js";
28
28
  import { icons } from "../../icons/icons.js";
29
29
  import { Spacer } from "../spacer/spacer.js";
@@ -189,7 +189,7 @@ function $aa90ad8b2b1d015f$export$5aadd9c0606af5c2(value) {
189
189
  return useMemo(() => {
190
190
  if (typeof value === "string") try {
191
191
  return (0, $799cddbef784668f$export$6e865ea70d7724f)(value);
192
- } catch (err) {
192
+ } catch {
193
193
  return void 0;
194
194
  }
195
195
  return value;
@@ -231,7 +231,7 @@ function $b335ada08155d9c0$export$d52a01683abdfcd6(props) {
231
231
  let color;
232
232
  try {
233
233
  color = (0, $799cddbef784668f$export$6e865ea70d7724f)(inputValue.startsWith("#") ? inputValue : `#${inputValue}`);
234
- } catch (err) {
234
+ } catch {
235
235
  color = null;
236
236
  }
237
237
  return color;
@@ -1,5 +1,5 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import { s as sprintf, _ as __ } from "../../default-i18n-DRnM8y4w.js";
2
+ import { s as sprintf, _ as __ } from "../../default-i18n-CM1-Xvzf.js";
3
3
  import { Expandable } from "../expandable/expandable.js";
4
4
  import { icons } from "../../icons/icons.js";
5
5
  import { Switch } from "../toggle/switch.js";
@@ -84,8 +84,8 @@ const ContainerPanel = (props) => {
84
84
  )
85
85
  ] }),
86
86
  className: clsx(
87
- "es-uic-space-y-2 es-uic-border-t es-uic-border-t-gray-200",
88
- closable && open && "es-uic-space-y-0",
87
+ "es-uic-border-t es-uic-border-t-gray-200",
88
+ !closable && typeof use === "undefined" && "es-uic-space-y-2",
89
89
  justClosable && open && "es-uic-pb-4",
90
90
  justUse && use && "es-uic-pb-4",
91
91
  useAndClosable && use && open && "es-uic-pb-4",
@@ -102,7 +102,8 @@ const ContainerPanel = (props) => {
102
102
  AnimatedVisibility,
103
103
  {
104
104
  visible: open,
105
- className: clsx(open && "es-uic-space-y-2 es-uic-px-4"),
105
+ className: "es-uic-space-y-2 es-uic-px-4",
106
+ transition: "scaleSlideFade",
106
107
  children
107
108
  }
108
109
  ),
@@ -110,7 +111,8 @@ const ContainerPanel = (props) => {
110
111
  AnimatedVisibility,
111
112
  {
112
113
  visible: closable ? use && open : use,
113
- className: clsx((closable ? use && open : use) && "es-uic-space-y-2 es-uic-px-4"),
114
+ className: "es-uic-space-y-2 es-uic-px-4",
115
+ transition: "scaleSlideFade",
114
116
  children
115
117
  }
116
118
  )
@@ -1,10 +1,10 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { c as clsx } from "../../lite-DVmmD_-j.js";
3
- import "../../default-i18n-DRnM8y4w.js";
3
+ import "../../default-i18n-CM1-Xvzf.js";
4
4
  import { DraggableContext } from "./draggable-context.js";
5
5
  import { useContext } from "react";
6
6
  import { icons } from "../../icons/icons.js";
7
- import "../../react-jsx-parser.min-B5HVwW_W.js";
7
+ import "../../react-jsx-parser.min-CVit0rZn.js";
8
8
  /**
9
9
  * A Draggable item handle.
10
10
  *
@@ -1,8 +1,8 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useRef, useEffect, useLayoutEffect, useState, createContext, startTransition, useTransition, useContext, useCallback, useId } from "react";
3
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
3
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
4
4
  import { DraggableContext } from "./draggable-context.js";
5
- import { r as reactDomExports } from "../../index-BTCzc3zb.js";
5
+ import { r as reactDomExports } from "../../index-BYHhzLf-.js";
6
6
  var i = Symbol.for("preact-signals");
7
7
  function t() {
8
8
  if (!(s > 1)) {
@@ -1,10 +1,10 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { c as clsx } from "../../lite-DVmmD_-j.js";
3
- import "../../default-i18n-DRnM8y4w.js";
3
+ import "../../default-i18n-CM1-Xvzf.js";
4
4
  import { BaseControl } from "../base-control/base-control.js";
5
5
  import { icons } from "../../icons/icons.js";
6
6
  import { cloneElement } from "react";
7
- import "../../react-jsx-parser.min-B5HVwW_W.js";
7
+ import "../../react-jsx-parser.min-CVit0rZn.js";
8
8
  /**
9
9
  * A DraggableList item.
10
10
  *
@@ -1,9 +1,9 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useId } from "react";
3
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
3
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
4
4
  import { BaseControl } from "../base-control/base-control.js";
5
5
  import { c as clsx } from "../../lite-DVmmD_-j.js";
6
- import { L as List, a as arrayRemove, b as arrayMove } from "../../List-Bx2anbX-.js";
6
+ import { L as List, a as arrayRemove, b as arrayMove } from "../../List-Ct3nzFZG.js";
7
7
  const fixIds = (items, itemIdBase) => {
8
8
  return items == null ? void 0 : items.map((item, i) => ({
9
9
  ...item,
@@ -1,13 +1,211 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import React__default from "react";
2
+ import React__default, { useRef, useCallback, useEffect, forwardRef, useContext, createContext } from "react";
3
3
  import { RichLabel } from "../rich-label/rich-label.js";
4
4
  import { AnimatedVisibility } from "../animated-visibility/animated-visibility.js";
5
5
  import { Button } from "../button/button.js";
6
6
  import { icons } from "../../icons/icons.js";
7
7
  import { c as clsx } from "../../lite-DVmmD_-j.js";
8
- import { _ as __ } from "../../default-i18n-DRnM8y4w.js";
9
- import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-BwqMVkuV.js";
10
- import { $ as $9bf71ea28793e738$export$20e40289641fbbb6 } from "../../FocusScope-CtCX0OGo.js";
8
+ import { _ as __ } from "../../default-i18n-CM1-Xvzf.js";
9
+ import { a as $d2b4bc8c273e7be6$export$24d547caef80ccd1 } from "../../Button-BMFbEXg1.js";
10
+ import { f as $bdb11010cef70236$export$f680877a34711e37, e as $b5e257d569688ac6$export$535bd6ca7f90a273, l as $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c, a as $64fa3d84918910a7$export$29f1550f4b0d4415, b as $64fa3d84918910a7$export$4d86445c2cf5e3, j as $64fa3d84918910a7$export$2881499e37b75b9a, o as $64fa3d84918910a7$export$c62b8e45d58ddad9, n as $5dc95899b306f630$export$c9058316764c140e, d as $3ef42575df84b30b$export$9d1611c77c2fe928 } from "../../utils-BSLBwuuO.js";
11
+ import { r as reactDomExports } from "../../index-BYHhzLf-.js";
12
+ import { $ as $e9faafb641e167db$export$90fc3a17d93f704c } from "../../useEvent-B0yfN_Zu.js";
13
+ import { e as $458b0a5536c1a7cf$export$40bfa8c7b0832715 } from "../../focusSafely-CZY36ssv.js";
14
+ import { $ as $65484d02dcb7eb3e$export$457c3d6518dd4c6f } from "../../filterDOMProps-EDDcM64A.js";
15
+ import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f } from "../../useFocusRing-DMAlRYjX.js";
16
+ import { $ as $01b77f81d0f07f68$export$b04be29aa201d4f5 } from "../../Label-BtoiUpt8.js";
17
+ function $5e910fae8e128ead$export$6e3e27031a30522f(props, state, ref) {
18
+ let { isDisabled } = props;
19
+ let triggerId = $bdb11010cef70236$export$f680877a34711e37();
20
+ let panelId = $bdb11010cef70236$export$f680877a34711e37();
21
+ let isSSR = $b5e257d569688ac6$export$535bd6ca7f90a273();
22
+ let supportsBeforeMatch = !isSSR && "onbeforematch" in document.body;
23
+ let raf = useRef(null);
24
+ let handleBeforeMatch = useCallback(() => {
25
+ raf.current = requestAnimationFrame(() => {
26
+ if (ref.current) ref.current.setAttribute("hidden", "until-found");
27
+ });
28
+ reactDomExports.flushSync(() => {
29
+ state.toggle();
30
+ });
31
+ }, [
32
+ ref,
33
+ state
34
+ ]);
35
+ $e9faafb641e167db$export$90fc3a17d93f704c(ref, "beforematch", supportsBeforeMatch ? handleBeforeMatch : null);
36
+ $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c(() => {
37
+ if (raf.current) cancelAnimationFrame(raf.current);
38
+ if (supportsBeforeMatch && ref.current && !isDisabled) {
39
+ if (state.isExpanded) ref.current.removeAttribute("hidden");
40
+ else ref.current.setAttribute("hidden", "until-found");
41
+ }
42
+ }, [
43
+ isDisabled,
44
+ ref,
45
+ state.isExpanded,
46
+ supportsBeforeMatch
47
+ ]);
48
+ useEffect(() => {
49
+ return () => {
50
+ if (raf.current) cancelAnimationFrame(raf.current);
51
+ };
52
+ }, []);
53
+ return {
54
+ buttonProps: {
55
+ id: triggerId,
56
+ "aria-expanded": state.isExpanded,
57
+ "aria-controls": panelId,
58
+ onPress: (e) => {
59
+ if (!isDisabled && e.pointerType !== "keyboard") state.toggle();
60
+ },
61
+ isDisabled,
62
+ onPressStart(e) {
63
+ if (e.pointerType === "keyboard" && !isDisabled) state.toggle();
64
+ }
65
+ },
66
+ panelProps: {
67
+ id: panelId,
68
+ // This can be overridden at the panel element level.
69
+ role: "group",
70
+ "aria-labelledby": triggerId,
71
+ "aria-hidden": !state.isExpanded,
72
+ hidden: supportsBeforeMatch ? true : !state.isExpanded
73
+ }
74
+ };
75
+ }
76
+ function $bf996d45f4a36925$export$3fcbf6e4407997e0(props) {
77
+ let [isExpanded, setExpanded] = $458b0a5536c1a7cf$export$40bfa8c7b0832715(props.isExpanded, props.defaultExpanded || false, props.onExpandedChange);
78
+ const expand = useCallback(() => {
79
+ setExpanded(true);
80
+ }, [
81
+ setExpanded
82
+ ]);
83
+ const collapse = useCallback(() => {
84
+ setExpanded(false);
85
+ }, [
86
+ setExpanded
87
+ ]);
88
+ const toggle = useCallback(() => {
89
+ setExpanded(!isExpanded);
90
+ }, [
91
+ setExpanded,
92
+ isExpanded
93
+ ]);
94
+ return {
95
+ isExpanded,
96
+ setExpanded,
97
+ expand,
98
+ collapse,
99
+ toggle
100
+ };
101
+ }
102
+ const $28f4fd908f0de97f$export$1d40e3e0cc4d5de = /* @__PURE__ */ createContext(null);
103
+ const $28f4fd908f0de97f$export$d665dd135a51b28a = /* @__PURE__ */ createContext(null);
104
+ const $28f4fd908f0de97f$export$dab3ea4a6ef094da = /* @__PURE__ */ createContext(null);
105
+ const $28f4fd908f0de97f$var$InternalDisclosureContext = /* @__PURE__ */ createContext(null);
106
+ function $28f4fd908f0de97f$var$Disclosure(props, ref) {
107
+ [props, ref] = $64fa3d84918910a7$export$29f1550f4b0d4415(props, ref, $28f4fd908f0de97f$export$d665dd135a51b28a);
108
+ let groupState = useContext($28f4fd908f0de97f$export$1d40e3e0cc4d5de);
109
+ let { id, ...otherProps } = props;
110
+ let defaultId = $bdb11010cef70236$export$f680877a34711e37();
111
+ id || (id = defaultId);
112
+ let isExpanded = groupState ? groupState.expandedKeys.has(id) : props.isExpanded;
113
+ let state = $bf996d45f4a36925$export$3fcbf6e4407997e0({
114
+ ...props,
115
+ isExpanded,
116
+ onExpandedChange(isExpanded2) {
117
+ var _props_onExpandedChange;
118
+ if (groupState) groupState.toggleKey(id);
119
+ (_props_onExpandedChange = props.onExpandedChange) === null || _props_onExpandedChange === void 0 ? void 0 : _props_onExpandedChange.call(props, isExpanded2);
120
+ }
121
+ });
122
+ let panelRef = React__default.useRef(null);
123
+ let isDisabled = props.isDisabled || (groupState === null || groupState === void 0 ? void 0 : groupState.isDisabled) || false;
124
+ let { buttonProps, panelProps } = $5e910fae8e128ead$export$6e3e27031a30522f({
125
+ ...props,
126
+ isExpanded,
127
+ isDisabled
128
+ }, state, panelRef);
129
+ let { isFocusVisible: isFocusVisibleWithin, focusProps: focusWithinProps } = $f7dceffc5ad7768b$export$4e328f61c538687f({
130
+ within: true
131
+ });
132
+ let renderProps = $64fa3d84918910a7$export$4d86445c2cf5e3({
133
+ ...props,
134
+ id: void 0,
135
+ defaultClassName: "react-aria-Disclosure",
136
+ values: {
137
+ isExpanded: state.isExpanded,
138
+ isDisabled,
139
+ isFocusVisibleWithin,
140
+ state
141
+ }
142
+ });
143
+ let domProps = $65484d02dcb7eb3e$export$457c3d6518dd4c6f(otherProps);
144
+ return /* @__PURE__ */ React__default.createElement($64fa3d84918910a7$export$2881499e37b75b9a, {
145
+ values: [
146
+ [
147
+ $d2b4bc8c273e7be6$export$24d547caef80ccd1,
148
+ {
149
+ slots: {
150
+ [$64fa3d84918910a7$export$c62b8e45d58ddad9]: {},
151
+ trigger: buttonProps
152
+ }
153
+ }
154
+ ],
155
+ [
156
+ $28f4fd908f0de97f$var$InternalDisclosureContext,
157
+ {
158
+ panelProps,
159
+ panelRef
160
+ }
161
+ ],
162
+ [
163
+ $28f4fd908f0de97f$export$dab3ea4a6ef094da,
164
+ state
165
+ ]
166
+ ]
167
+ }, /* @__PURE__ */ React__default.createElement("div", {
168
+ ref,
169
+ "data-expanded": state.isExpanded || void 0,
170
+ "data-disabled": isDisabled || void 0,
171
+ "data-focus-visible-within": isFocusVisibleWithin || void 0,
172
+ ...domProps,
173
+ ...focusWithinProps,
174
+ ...renderProps
175
+ }, renderProps.children));
176
+ }
177
+ function $28f4fd908f0de97f$var$DisclosurePanel(props, ref) {
178
+ let { role = "group" } = props;
179
+ let { panelProps, panelRef } = useContext($28f4fd908f0de97f$var$InternalDisclosureContext);
180
+ let { isFocusVisible: isFocusVisibleWithin, focusProps: focusWithinProps } = $f7dceffc5ad7768b$export$4e328f61c538687f({
181
+ within: true
182
+ });
183
+ let renderProps = $64fa3d84918910a7$export$4d86445c2cf5e3({
184
+ ...props,
185
+ defaultClassName: "react-aria-DisclosurePanel",
186
+ values: {
187
+ isFocusVisibleWithin
188
+ }
189
+ });
190
+ let DOMProps = $65484d02dcb7eb3e$export$457c3d6518dd4c6f(props);
191
+ return /* @__PURE__ */ React__default.createElement("div", {
192
+ ...DOMProps,
193
+ ref: $5dc95899b306f630$export$c9058316764c140e(ref, panelRef),
194
+ ...$3ef42575df84b30b$export$9d1611c77c2fe928(panelProps, focusWithinProps),
195
+ ...renderProps,
196
+ role,
197
+ "data-focus-visible-within": isFocusVisibleWithin || void 0
198
+ }, /* @__PURE__ */ React__default.createElement($64fa3d84918910a7$export$2881499e37b75b9a, {
199
+ values: [
200
+ [
201
+ $d2b4bc8c273e7be6$export$24d547caef80ccd1,
202
+ null
203
+ ]
204
+ ]
205
+ }, props.children));
206
+ }
207
+ const $28f4fd908f0de97f$export$74a362b31437ec83 = /* @__PURE__ */ forwardRef($28f4fd908f0de97f$var$Disclosure);
208
+ const $28f4fd908f0de97f$export$feabaa331e1d464c = /* @__PURE__ */ forwardRef($28f4fd908f0de97f$var$DisclosurePanel);
11
209
  /**
12
210
  * A component that allows hiding content in an expandable panel, to declutter the UI.
13
211
  *
@@ -23,10 +221,10 @@ import { $ as $9bf71ea28793e738$export$20e40289641fbbb6 } from "../../FocusScope
23
221
  * @param {JSX.Element|JSX.Element[]} [props.actions] - Actions to display in the panel header, left of the expand button.
24
222
  * @param {boolean} [props.keepActionsOnExpand=false] - If `true`, the actions are not hidden when the panel is expanded.
25
223
  * @param {boolean} [props.disabled] - If `true`, the expand button is disabled.
26
- * @param {boolean} [props.noFocusHandling] - If `true`, the focus trapping when the item is expanded is disabled. Useful when part of another component that manages focus itself.
27
224
  * @param {boolean} [props.open] - Whether the expandable is open.
28
225
  * @param {Function} [props.onOpenChange] - Function is called when the panel is opened or closed.
29
226
  * @param {object} [props.headerProps] - Props to pass to the header (label + trigger).
227
+ * @param {JSX.Element} [props.customOpenButton] - Allows adding a custom open button. **IMPORTANT**: make sure to set `slot='trigger'` on the passed element!
30
228
  * @param {boolean} [props.hidden] - If `true`, the component is not rendered.
31
229
  *
32
230
  * @returns {JSX.Element} The Expandable component.
@@ -66,12 +264,19 @@ const Expandable = (props) => {
66
264
  if (hidden) {
67
265
  return null;
68
266
  }
69
- const component = /* @__PURE__ */ jsxs(
70
- "div",
267
+ return /* @__PURE__ */ jsxs(
268
+ $28f4fd908f0de97f$export$74a362b31437ec83,
71
269
  {
270
+ isExpanded: isOpen,
271
+ onExpandedChange: (value) => {
272
+ setIsOpen(value);
273
+ if (onOpenChange) {
274
+ onOpenChange(!isOpen);
275
+ }
276
+ },
72
277
  className: clsx(
73
- "es-uic-w-full es-uic-rounded-lg es-uic-border es-uic-border-gray-300 es-uic-border-opacity-0 es-uic-text-sm es-uic-transition focus:es-uic-outline-none",
74
- isOpen && "es-uic-border-opacity-100 es-uic-shadow-lg",
278
+ "es-uic-w-full es-uic-rounded-lg es-uic-border es-uic-border-gray-300/0 es-uic-text-sm es-uic-transition",
279
+ isOpen && "es-uic-border-gray-300/100 es-uic-shadow-lg",
75
280
  className
76
281
  ),
77
282
  ...other,
@@ -80,7 +285,6 @@ const Expandable = (props) => {
80
285
  "div",
81
286
  {
82
287
  className: clsx("es-uic-flex es-uic-h-10 es-uic-items-center es-uic-gap-1 es-uic-transition-[padding]", isOpen && "es-uic-py-1 es-uic-pl-2 es-uic-pr-1", headerClassName),
83
- ...headerProps,
84
288
  children: [
85
289
  /* @__PURE__ */ jsx(
86
290
  RichLabel,
@@ -118,6 +322,7 @@ const Expandable = (props) => {
118
322
  !customOpenButton && /* @__PURE__ */ jsx(
119
323
  Button,
120
324
  {
325
+ slot: "trigger",
121
326
  type: "ghost",
122
327
  icon: isOpen ? icons.caretDownFill : icons.caretDown,
123
328
  onPress: () => {
@@ -136,29 +341,19 @@ const Expandable = (props) => {
136
341
  }
137
342
  ),
138
343
  /* @__PURE__ */ jsx(
139
- AnimatedVisibility,
344
+ $28f4fd908f0de97f$export$feabaa331e1d464c,
140
345
  {
141
- visible: isOpen,
142
- className: clsx("es-uic-space-y-2.5 es-uic-border-t es-uic-border-t-gray-200 es-uic-p-2", contentClassName),
143
- transition: "slideFade",
144
- noInitial: true,
346
+ className: clsx(
347
+ isOpen && "es-uic-space-y-2.5 es-uic-border-t es-uic-border-t-gray-200 es-uic-p-2",
348
+ isOpen && "es-uic-animate-in es-uic-fade-in-0 es-uic-slide-in-from-top-3 es-uic-fill-mode-forwards",
349
+ contentClassName
350
+ ),
145
351
  children
146
352
  }
147
353
  )
148
354
  ]
149
355
  }
150
356
  );
151
- if (noFocusHandling) {
152
- return component;
153
- }
154
- return /* @__PURE__ */ jsx(
155
- $9bf71ea28793e738$export$20e40289641fbbb6,
156
- {
157
- contain: isOpen,
158
- autoFocus: isOpen,
159
- children: component
160
- }
161
- );
162
357
  };
163
358
  export {
164
359
  Expandable