@pismo/marola 1.0.0-beta.3 → 1.0.0-beta.30

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 (127) hide show
  1. package/dist/{Button-2b1peDFT.js → Button-BAljjMv3.js} +2 -2
  2. package/dist/{ClickAwayListener-BSW-Nd-y.js → ClickAwayListener-DbEYZpyh.js} +4 -3
  3. package/dist/Dialog.module-D9e4RsKo.js +30 -0
  4. package/dist/{Popup-B6ZSGIEI.js → Popup-Ck3XlWMq.js} +3 -3
  5. package/dist/{Portal-DIeBsWdL.js → Portal-oY3enyAm.js} +2 -2
  6. package/dist/SelectButton-BlVl6pJn.js +70 -0
  7. package/dist/{Tabs.module-jkH1Qjn7.js → Tabs.module-BGGTkDc5.js} +7 -7
  8. package/dist/Toggle-Buew6bzm.js +182 -0
  9. package/dist/assets/Adornment.css +1 -0
  10. package/dist/assets/Advice.css +1 -1
  11. package/dist/assets/Autocomplete.css +1 -0
  12. package/dist/assets/Button.css +1 -1
  13. package/dist/assets/Checkbox.css +1 -1
  14. package/dist/assets/Dialog.css +1 -1
  15. package/dist/assets/IconButton.css +1 -1
  16. package/dist/assets/Input.css +1 -1
  17. package/dist/assets/PageHeader.css +1 -1
  18. package/dist/assets/Pagination.css +1 -1
  19. package/dist/assets/ResultWithChips.css +1 -0
  20. package/dist/assets/SelectButton.css +1 -1
  21. package/dist/assets/Snackbar.css +1 -1
  22. package/dist/assets/SortTooltip.css +1 -1
  23. package/dist/assets/Stepper.css +1 -1
  24. package/dist/assets/StepperNavigator.css +1 -0
  25. package/dist/assets/Table.css +1 -1
  26. package/dist/assets/Tabs.css +1 -1
  27. package/dist/assets/TextDisplay.css +1 -1
  28. package/dist/assets/Toggle.css +1 -1
  29. package/dist/assets/Toggle2.css +1 -1
  30. package/dist/assets/Typography.css +1 -1
  31. package/dist/{combineHooksSlotProps-DVjg9PRh.js → combineHooksSlotProps-C-zYvfnF.js} +1 -1
  32. package/dist/components/Adornment/Adornment.d.ts +20 -0
  33. package/dist/components/Adornment/Adornment.js +13 -0
  34. package/dist/components/Adornment/Adornment.stories.d.ts +14 -0
  35. package/dist/components/Adornment/adornment.test.d.ts +1 -0
  36. package/dist/components/Advice/Advice.d.ts +32 -17
  37. package/dist/components/Advice/Advice.js +39 -40
  38. package/dist/components/Advice/Advice.stories.d.ts +4 -3
  39. package/dist/components/Autocomplete/Autocomplete.d.ts +20 -0
  40. package/dist/components/Autocomplete/Autocomplete.js +679 -0
  41. package/dist/components/Autocomplete/Autocomplete.stories.d.ts +23 -0
  42. package/dist/components/Button/Button.d.ts +2 -0
  43. package/dist/components/Button/Button.js +51 -49
  44. package/dist/components/Checkbox/Checkbox.js +52 -52
  45. package/dist/components/Chip/Chip.d.ts +6 -12
  46. package/dist/components/Chip/Chip.js +7 -5
  47. package/dist/components/Chip/Chip.stories.d.ts +5 -14
  48. package/dist/components/Dialog/Actions.js +1 -1
  49. package/dist/components/Dialog/Backdrop.d.ts +3 -3
  50. package/dist/components/Dialog/Backdrop.js +8 -7
  51. package/dist/components/Dialog/CloseIconButton.d.ts +1 -2
  52. package/dist/components/Dialog/CloseIconButton.js +15 -18
  53. package/dist/components/Dialog/Dialog.d.ts +9 -6
  54. package/dist/components/Dialog/Dialog.js +139 -139
  55. package/dist/components/Dialog/Dialog.stories.d.ts +50 -46
  56. package/dist/components/Dialog/DialogTitle.js +1 -1
  57. package/dist/components/EllipsisTooltip/EllipsisTooltip.js +30 -17
  58. package/dist/components/EllipsisTooltip/EllipsisTooltip.stories.d.ts +2 -1
  59. package/dist/components/Icon/Icon.js +93 -47
  60. package/dist/components/Icon/types.d.ts +1 -1
  61. package/dist/components/IconButton/IconButton.js +42 -42
  62. package/dist/components/Input/Input.d.ts +24 -5
  63. package/dist/components/Input/Input.js +297 -284
  64. package/dist/components/Input/Input.stories.d.ts +2 -21
  65. package/dist/components/InputSearch/InputSearch.stories.d.ts +1 -21
  66. package/dist/components/PageHeader/PageHeader.js +57 -57
  67. package/dist/components/Pagination/Pagination.d.ts +5 -1
  68. package/dist/components/Pagination/Pagination.js +87 -185
  69. package/dist/components/Pagination/Pagination.stories.d.ts +1 -1
  70. package/dist/components/Pagination/usePagination.d.ts +90 -0
  71. package/dist/components/Pagination/usePagination.js +79 -0
  72. package/dist/components/ResultWithChips/ResultWithChips.d.ts +12 -0
  73. package/dist/components/ResultWithChips/ResultWithChips.js +33 -0
  74. package/dist/components/RowItem/RowItem.d.ts +25 -0
  75. package/dist/components/RowItem/RowItem.js +20 -0
  76. package/dist/components/RowItem/RowItem.stories.d.ts +17 -0
  77. package/dist/components/RowItem/rowItem.test.d.ts +1 -0
  78. package/dist/components/Select/Select.d.ts +7 -0
  79. package/dist/components/Select/Select.js +409 -365
  80. package/dist/components/Select/SelectButton.d.ts +1 -0
  81. package/dist/components/Select/SelectButton.js +1 -1
  82. package/dist/components/Skeleton/Skeleton.d.ts +3 -1
  83. package/dist/components/Skeleton/Skeleton.js +18 -12
  84. package/dist/components/Skeleton/SkeletonTable.stories.d.ts +1 -1
  85. package/dist/components/Snackbar/Snackbar.js +94 -94
  86. package/dist/components/Snackbar/Snackbar.stories.d.ts +3 -3
  87. package/dist/components/SortTooltip/SortTooltip.js +46 -46
  88. package/dist/components/Stepper/Stepper.js +35 -35
  89. package/dist/components/StepperNavigator/StepperNavigator.d.ts +43 -0
  90. package/dist/components/StepperNavigator/StepperNavigator.js +56 -0
  91. package/dist/components/StepperNavigator/StepperNavigator.stories.d.ts +16 -0
  92. package/dist/components/StepperNavigator/StepperNavigator.test.d.ts +1 -0
  93. package/dist/components/Table/Table.d.ts +3 -1
  94. package/dist/components/Table/Table.js +88 -85
  95. package/dist/components/Table/Table.stories.d.ts +1 -1
  96. package/dist/components/Tabs/Tab.d.ts +5 -3
  97. package/dist/components/Tabs/Tab.js +38 -36
  98. package/dist/components/Tabs/TabPanel.d.ts +4 -2
  99. package/dist/components/Tabs/TabPanel.js +51 -40
  100. package/dist/components/Tabs/Tabs.d.ts +6 -4
  101. package/dist/components/Tabs/Tabs.js +131 -128
  102. package/dist/components/TextDisplay/TextDisplay.d.ts +9 -3
  103. package/dist/components/TextDisplay/TextDisplay.js +45 -31
  104. package/dist/components/TextDisplay/TextDisplay.stories.d.ts +2 -1
  105. package/dist/components/Toggle/Toggle.js +56 -56
  106. package/dist/components/ToggleGroup/Toggle.js +5 -4
  107. package/dist/components/ToggleGroup/ToggleGroup.js +1 -1
  108. package/dist/components/Tooltip/Tooltip.d.ts +3 -1
  109. package/dist/components/Tooltip/Tooltip.js +4 -4
  110. package/dist/components/Tooltip/Tooltip.stories.d.ts +1 -0
  111. package/dist/components/Typography/Typography.js +47 -47
  112. package/dist/{index-CjW42-M-.js → index-bQFToy-I.js} +1 -1
  113. package/dist/main.d.ts +5 -0
  114. package/dist/main.js +85 -76
  115. package/dist/ownerDocument-YGhwAnr1.js +33 -0
  116. package/dist/{useButton-DNk3wrQp.js → useButton-DcihopJG.js} +1 -1
  117. package/dist/useCompoundItem-B7Eo_qZk.js +68 -0
  118. package/dist/useEventCallback-BAQJJ3ye.js +14 -0
  119. package/dist/useId-BW-oWmul.js +19 -0
  120. package/dist/{useList-B0hog_3-.js → useList-B9C55YB7.js} +2 -2
  121. package/dist/{index-CH45lKw7.js → useSlotProps-C_I1kEHr.js} +99 -99
  122. package/package.json +9 -3
  123. package/dist/Dialog.module-DFEmFdYT.js +0 -30
  124. package/dist/SelectButton-C8JQKaf4.js +0 -61
  125. package/dist/Toggle-BCgIItCc.js +0 -142
  126. package/dist/useCompoundItem-D1iRfg8D.js +0 -84
  127. package/dist/useEventCallback-xTG9piMa.js +0 -45
@@ -1,16 +1,18 @@
1
- import { jsx as h, jsxs as Oe } from "react/jsx-runtime";
2
- import { c as _e } from "../../clsx-DB4S2d7J.js";
3
- import { Typography as Ke } from "../Typography/Typography.js";
4
- import { s as L, S as ze } from "../../SelectButton-C8JQKaf4.js";
5
- import { g as Ve, a as we, u as X, f as ne, b as g, P as l, _ as ke, c as le, d as Ie, e as Ne } from "../../index-CH45lKw7.js";
1
+ import { jsx as g, jsxs as Re } from "react/jsx-runtime";
6
2
  import * as s from "react";
7
- import { u as Je, c as se, a as ye, L as Q } from "../../combineHooksSlotProps-DVjg9PRh.js";
8
- import { u as Me } from "../../useButton-DNk3wrQp.js";
9
- import { u as Te, a as We, b as Ge, C as Qe } from "../../useCompoundItem-D1iRfg8D.js";
10
- import { P as Xe } from "../../Popup-B6ZSGIEI.js";
11
- import { m as ve, h as Ye, l as Ze, u as et } from "../../useList-B0hog_3-.js";
12
- import { u as tt } from "../../useEnhancedEffect-CJGo-L3B.js";
13
- const ot = {
3
+ import { useId as ze } from "react";
4
+ import { c as ne } from "../../clsx-DB4S2d7J.js";
5
+ import { Typography as Ve } from "../Typography/Typography.js";
6
+ import { s as w, S as We } from "../../SelectButton-BlVl6pJn.js";
7
+ import { g as we, a as Ie, u as X, f as le, b as m, P as l, _ as ke, c as se, d as Ne, e as Me } from "../../useSlotProps-C_I1kEHr.js";
8
+ import { u as Je, c as re, a as _e, L as Q } from "../../combineHooksSlotProps-C-zYvfnF.js";
9
+ import { u as Te } from "../../useButton-DcihopJG.js";
10
+ import { u as Le } from "../../useId-BW-oWmul.js";
11
+ import { u as Ge, a as Qe, C as Xe } from "../../useCompoundItem-B7Eo_qZk.js";
12
+ import { P as Ye } from "../../Popup-Ck3XlWMq.js";
13
+ import { m as ye, h as Ze, l as et, u as tt } from "../../useList-B9C55YB7.js";
14
+ import { u as ot } from "../../useEnhancedEffect-CJGo-L3B.js";
15
+ const nt = {
14
16
  border: 0,
15
17
  clip: "rect(0 0 0 0)",
16
18
  height: "1px",
@@ -21,17 +23,17 @@ const ot = {
21
23
  whiteSpace: "nowrap",
22
24
  width: "1px"
23
25
  }, Ae = "Option";
24
- function nt(n) {
25
- return Ve(Ae, n);
26
- }
27
- we(Ae, ["root", "disabled", "selected", "highlighted"]);
28
26
  function lt(n) {
27
+ return we(Ae, n);
28
+ }
29
+ Ie(Ae, ["root", "disabled", "selected", "highlighted"]);
30
+ function st(n) {
29
31
  const {
30
32
  value: o,
31
- label: i,
32
- disabled: a,
33
+ label: a,
34
+ disabled: c,
33
35
  rootRef: r,
34
- id: c
36
+ id: u
35
37
  } = n, {
36
38
  getRootProps: p,
37
39
  highlighted: f,
@@ -39,128 +41,128 @@ function lt(n) {
39
41
  } = Je({
40
42
  item: o
41
43
  }), {
42
- getRootProps: v,
43
- rootRef: I
44
- } = Me({
45
- disabled: a,
44
+ getRootProps: C,
45
+ rootRef: O
46
+ } = Te({
47
+ disabled: c,
46
48
  focusableWhenDisabled: !0
47
- }), x = Te(c), y = s.useRef(null), R = s.useMemo(() => ({
48
- disabled: a,
49
- label: i,
49
+ }), h = Le(u), P = s.useRef(null), v = s.useMemo(() => ({
50
+ disabled: c,
51
+ label: a,
50
52
  value: o,
51
- ref: y,
52
- id: x
53
- }), [a, i, o, x]), {
54
- index: N
55
- } = We(o, R), O = X(r, y, I), M = (b) => (C) => {
56
- var P;
57
- (P = b.onKeyDown) == null || P.call(b, C), !C.defaultMuiPrevented && [" ", "Enter"].includes(C.key) && (C.defaultMuiPrevented = !0);
53
+ ref: P,
54
+ id: h
55
+ }), [c, a, o, h]), {
56
+ index: y
57
+ } = Ge(o, v), R = X(r, P, O), I = (b) => (_) => {
58
+ var S;
59
+ (S = b.onKeyDown) == null || S.call(b, _), !_.defaultMuiPrevented && [" ", "Enter"].includes(_.key) && (_.defaultMuiPrevented = !0);
58
60
  }, B = (b = {}) => ({
59
- onKeyDown: M(b)
61
+ onKeyDown: I(b)
60
62
  });
61
63
  return {
62
64
  getRootProps: (b = {}) => {
63
- const C = ne(b), P = se(p, se(v, B));
64
- return g({}, b, C, P(C), {
65
- id: x,
66
- ref: O,
65
+ const _ = le(b), S = re(p, re(C, B));
66
+ return m({}, b, _, S(_), {
67
+ id: h,
68
+ ref: R,
67
69
  role: "option",
68
70
  "aria-selected": d
69
71
  });
70
72
  },
71
73
  highlighted: f,
72
- index: N,
74
+ index: y,
73
75
  selected: d,
74
- rootRef: O
76
+ rootRef: R
75
77
  };
76
78
  }
77
- function st(n) {
78
- const o = s.useContext(ye);
79
+ function rt(n) {
80
+ const o = s.useContext(_e);
79
81
  if (!o)
80
82
  throw new Error("Option: ListContext was not found.");
81
83
  const {
82
- getItemState: i,
83
- dispatch: a
84
+ getItemState: a,
85
+ dispatch: c
84
86
  } = o, {
85
87
  highlighted: r,
86
- selected: c,
88
+ selected: u,
87
89
  focusable: p
88
- } = i(n), f = s.useCallback((v) => {
89
- if (v !== n)
90
+ } = a(n), f = s.useCallback((C) => {
91
+ if (C !== n)
90
92
  throw new Error(["Base UI Option: Tried to access the state of another Option.", "This is unsupported when the Option uses the OptionContextStabilizer as a performance optimization."].join("/n"));
91
93
  return {
92
94
  highlighted: r,
93
- selected: c,
95
+ selected: u,
94
96
  focusable: p
95
97
  };
96
- }, [r, c, p, n]);
98
+ }, [r, u, p, n]);
97
99
  return {
98
100
  contextValue: s.useMemo(() => ({
99
- dispatch: a,
101
+ dispatch: c,
100
102
  getItemState: f
101
- }), [a, f])
103
+ }), [c, f])
102
104
  };
103
105
  }
104
- const rt = ["children", "disabled", "label", "slotProps", "slots", "value"];
105
- function ut(n) {
106
+ const it = ["children", "disabled", "label", "slotProps", "slots", "value"];
107
+ function at(n) {
106
108
  const {
107
109
  disabled: o,
108
- highlighted: i,
109
- selected: a
110
+ highlighted: a,
111
+ selected: c
110
112
  } = n;
111
- return Ie({
112
- root: ["root", o && "disabled", i && "highlighted", a && "selected"]
113
- }, Ne(nt));
113
+ return Ne({
114
+ root: ["root", o && "disabled", a && "highlighted", c && "selected"]
115
+ }, Me(lt));
114
116
  }
115
- const it = /* @__PURE__ */ s.memo(/* @__PURE__ */ s.forwardRef(function(o, i) {
116
- var a, r;
117
+ const ut = /* @__PURE__ */ s.memo(/* @__PURE__ */ s.forwardRef(function(o, a) {
118
+ var c, r;
117
119
  const {
118
- children: c,
120
+ children: u,
119
121
  disabled: p = !1,
120
122
  label: f,
121
123
  slotProps: d = {},
122
- slots: v = {},
123
- value: I
124
- } = o, x = ke(o, rt), y = (a = v.root) != null ? a : "li", R = s.useRef(null), N = X(R, i), O = f ?? (typeof c == "string" ? c : (r = R.current) == null || (r = r.textContent) == null ? void 0 : r.trim()), {
125
- getRootProps: M,
124
+ slots: C = {},
125
+ value: O
126
+ } = o, h = ke(o, it), P = (c = C.root) != null ? c : "li", v = s.useRef(null), y = X(v, a), R = f ?? (typeof u == "string" ? u : (r = v.current) == null || (r = r.textContent) == null ? void 0 : r.trim()), {
127
+ getRootProps: I,
126
128
  selected: B,
127
129
  highlighted: b,
128
- index: C
129
- } = lt({
130
+ index: _
131
+ } = st({
130
132
  disabled: p,
131
- label: O,
132
- rootRef: N,
133
- value: I
134
- }), P = g({}, o, {
133
+ label: R,
134
+ rootRef: y,
135
+ value: O
136
+ }), S = m({}, o, {
135
137
  disabled: p,
136
138
  highlighted: b,
137
- index: C,
139
+ index: _,
138
140
  selected: B
139
- }), j = ut(P), _ = le({
140
- getSlotProps: M,
141
- elementType: y,
141
+ }), j = at(S), k = se({
142
+ getSlotProps: I,
143
+ elementType: P,
142
144
  externalSlotProps: d.root,
143
- externalForwardedProps: x,
145
+ externalForwardedProps: h,
144
146
  className: j.root,
145
- ownerState: P
147
+ ownerState: S
146
148
  });
147
- return /* @__PURE__ */ h(y, g({}, _, {
148
- children: c
149
+ return /* @__PURE__ */ g(P, m({}, k, {
150
+ children: u
149
151
  }));
150
- })), Le = /* @__PURE__ */ s.forwardRef(function(o, i) {
152
+ })), Be = /* @__PURE__ */ s.forwardRef(function(o, a) {
151
153
  const {
152
- value: a
154
+ value: c
153
155
  } = o, {
154
156
  contextValue: r
155
- } = st(a);
156
- return /* @__PURE__ */ h(ye.Provider, {
157
+ } = rt(c);
158
+ return /* @__PURE__ */ g(_e.Provider, {
157
159
  value: r,
158
- children: /* @__PURE__ */ h(it, g({}, o, {
159
- ref: i
160
+ children: /* @__PURE__ */ g(ut, m({}, o, {
161
+ ref: a
160
162
  }))
161
163
  });
162
164
  });
163
- process.env.NODE_ENV !== "production" && (Le.propTypes = {
165
+ process.env.NODE_ENV !== "production" && (Be.propTypes = {
164
166
  // ┌────────────────────────────── Warning ──────────────────────────────┐
165
167
  // │ These PropTypes are generated from the TypeScript type definitions. │
166
168
  // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
@@ -203,444 +205,444 @@ process.env.NODE_ENV !== "production" && (Le.propTypes = {
203
205
  */
204
206
  value: l.any.isRequired
205
207
  });
206
- const re = {
208
+ const ie = {
207
209
  buttonClick: "buttonClick",
208
210
  browserAutoFill: "browserAutoFill"
209
- }, Be = (n) => {
211
+ }, Ee = (n) => {
210
212
  const {
211
213
  label: o,
212
- value: i
214
+ value: a
213
215
  } = n;
214
- return typeof o == "string" ? o : typeof i == "string" ? i : String(n);
216
+ return typeof o == "string" ? o : typeof a == "string" ? a : String(n);
215
217
  };
216
- function at(n, o) {
218
+ function ct(n, o) {
217
219
  const {
218
- open: i
220
+ open: a
219
221
  } = n, {
220
222
  context: {
221
- selectionMode: a
223
+ selectionMode: c
222
224
  }
223
225
  } = o;
224
- if (o.type === re.buttonClick) {
226
+ if (o.type === ie.buttonClick) {
225
227
  var r;
226
- const d = (r = n.selectedValues[0]) != null ? r : ve(null, "start", o.context);
227
- return g({}, n, {
228
- open: !i,
229
- highlightedValue: i ? null : d
228
+ const d = (r = n.selectedValues[0]) != null ? r : ye(null, "start", o.context);
229
+ return m({}, n, {
230
+ open: !a,
231
+ highlightedValue: a ? null : d
230
232
  });
231
233
  }
232
- if (o.type === re.browserAutoFill)
233
- return Ye(o.item, n, o.context);
234
- const c = Ze(n, o);
234
+ if (o.type === ie.browserAutoFill)
235
+ return Ze(o.item, n, o.context);
236
+ const u = et(n, o);
235
237
  switch (o.type) {
236
238
  case Q.keyDown:
237
239
  if (n.open) {
238
240
  if (o.event.key === "Escape")
239
- return g({}, c, {
241
+ return m({}, u, {
240
242
  open: !1
241
243
  });
242
244
  } else {
243
245
  if (o.event.key === "ArrowDown") {
244
246
  var p;
245
- return g({}, n, {
247
+ return m({}, n, {
246
248
  open: !0,
247
- highlightedValue: (p = n.selectedValues[0]) != null ? p : ve(null, "start", o.context)
249
+ highlightedValue: (p = n.selectedValues[0]) != null ? p : ye(null, "start", o.context)
248
250
  });
249
251
  }
250
252
  if (o.event.key === "ArrowUp") {
251
253
  var f;
252
- return g({}, n, {
254
+ return m({}, n, {
253
255
  open: !0,
254
- highlightedValue: (f = n.selectedValues[0]) != null ? f : ve(null, "end", o.context)
256
+ highlightedValue: (f = n.selectedValues[0]) != null ? f : ye(null, "end", o.context)
255
257
  });
256
258
  }
257
259
  }
258
260
  break;
259
261
  case Q.itemClick:
260
- if (a === "single")
261
- return g({}, c, {
262
+ if (c === "single")
263
+ return m({}, u, {
262
264
  open: !1
263
265
  });
264
266
  break;
265
267
  case Q.blur:
266
- return g({}, c, {
268
+ return m({}, u, {
267
269
  open: !1
268
270
  });
269
271
  default:
270
- return c;
272
+ return u;
271
273
  }
272
- return c;
274
+ return u;
273
275
  }
274
- function ct(n) {
276
+ function dt(n) {
275
277
  return Array.isArray(n) ? n.length === 0 ? "" : JSON.stringify(n.map((o) => o.value)) : (n == null ? void 0 : n.value) == null ? "" : typeof n.value == "string" || typeof n.value == "number" ? n.value : JSON.stringify(n.value);
276
278
  }
277
- function dt(n) {
279
+ function pt(n) {
278
280
  const {
279
281
  areOptionsEqual: o,
280
- buttonRef: i,
281
- defaultOpen: a = !1,
282
+ buttonRef: a,
283
+ defaultOpen: c = !1,
282
284
  defaultValue: r,
283
- disabled: c = !1,
285
+ disabled: u = !1,
284
286
  listboxId: p,
285
287
  listboxRef: f,
286
288
  multiple: d = !1,
287
- name: v,
288
- required: I,
289
- onChange: x,
290
- onHighlightChange: y,
291
- onOpenChange: R,
292
- open: N,
293
- options: O,
294
- getOptionAsString: M = Be,
295
- getSerializedValue: B = ct,
289
+ name: C,
290
+ required: O,
291
+ onChange: h,
292
+ onHighlightChange: P,
293
+ onOpenChange: v,
294
+ open: y,
295
+ options: R,
296
+ getOptionAsString: I = Ee,
297
+ getSerializedValue: B = dt,
296
298
  value: b,
297
- componentName: C = "useSelect"
298
- } = n, P = s.useRef(null), j = X(i, P), _ = s.useRef(null), $ = Te(p);
299
+ componentName: _ = "useSelect"
300
+ } = n, S = s.useRef(null), j = X(a, S), k = s.useRef(null), H = Le(p);
299
301
  let E;
300
302
  b === void 0 && r === void 0 ? E = [] : r !== void 0 && (d ? E = r : E = r == null ? [] : [r]);
301
303
  const Y = s.useMemo(() => {
302
304
  if (b !== void 0)
303
305
  return d ? b : b == null ? [] : [b];
304
306
  }, [b, d]), {
305
- subitems: T,
307
+ subitems: L,
306
308
  contextValue: F
307
- } = Ge(), V = s.useMemo(() => O != null ? new Map(O.map((e, t) => [e.value, {
309
+ } = Qe(), N = s.useMemo(() => R != null ? new Map(R.map((e, t) => [e.value, {
308
310
  value: e.value,
309
311
  label: e.label,
310
312
  disabled: e.disabled,
311
313
  ref: /* @__PURE__ */ s.createRef(),
312
- id: `${$}_${t}`
313
- }])) : T, [O, T, $]), ue = X(f, _), {
314
+ id: `${H}_${t}`
315
+ }])) : L, [R, L, H]), ae = X(f, k), {
314
316
  getRootProps: Z,
315
- active: ie,
316
- focusVisible: ae,
317
+ active: ue,
318
+ focusVisible: ce,
317
319
  rootRef: U
318
- } = Me({
319
- disabled: c,
320
+ } = Te({
321
+ disabled: u,
320
322
  rootRef: j
321
- }), q = s.useMemo(() => Array.from(V.keys()), [V]), S = s.useCallback((e) => {
323
+ }), q = s.useMemo(() => Array.from(N.keys()), [N]), V = s.useCallback((e) => {
322
324
  if (o !== void 0) {
323
- const t = q.find((u) => o(u, e));
324
- return V.get(t);
325
+ const t = q.find((i) => o(i, e));
326
+ return N.get(t);
325
327
  }
326
- return V.get(e);
327
- }, [V, o, q]), ee = s.useCallback((e) => {
328
+ return N.get(e);
329
+ }, [N, o, q]), ee = s.useCallback((e) => {
328
330
  var t;
329
- const u = S(e);
330
- return (t = u == null ? void 0 : u.disabled) != null ? t : !1;
331
- }, [S]), te = s.useCallback((e) => {
332
- const t = S(e);
333
- return t ? M(t) : "";
334
- }, [S, M]), ce = s.useMemo(() => ({
331
+ const i = V(e);
332
+ return (t = i == null ? void 0 : i.disabled) != null ? t : !1;
333
+ }, [V]), te = s.useCallback((e) => {
334
+ const t = V(e);
335
+ return t ? I(t) : "";
336
+ }, [V, I]), de = s.useMemo(() => ({
335
337
  selectedValues: Y,
336
- open: N
337
- }), [Y, N]), de = s.useCallback((e) => {
338
+ open: y
339
+ }), [Y, y]), pe = s.useCallback((e) => {
338
340
  var t;
339
- return (t = V.get(e)) == null ? void 0 : t.id;
340
- }, [V]), pe = s.useCallback((e, t) => {
341
+ return (t = N.get(e)) == null ? void 0 : t.id;
342
+ }, [N]), fe = s.useCallback((e, t) => {
341
343
  if (d)
342
- x == null || x(e, t);
344
+ h == null || h(e, t);
343
345
  else {
344
- var u;
345
- x == null || x(e, (u = t[0]) != null ? u : null);
346
+ var i;
347
+ h == null || h(e, (i = t[0]) != null ? i : null);
346
348
  }
347
- }, [d, x]), fe = s.useCallback((e, t) => {
348
- y == null || y(e, t ?? null);
349
- }, [y]), be = s.useCallback((e, t, u) => {
350
- if (t === "open" && (R == null || R(u), u === !1 && (e == null ? void 0 : e.type) !== "blur")) {
351
- var m;
352
- (m = P.current) == null || m.focus();
349
+ }, [d, h]), be = s.useCallback((e, t) => {
350
+ P == null || P(e, t ?? null);
351
+ }, [P]), me = s.useCallback((e, t, i) => {
352
+ if (t === "open" && (v == null || v(i), i === !1 && (e == null ? void 0 : e.type) !== "blur")) {
353
+ var x;
354
+ (x = S.current) == null || x.focus();
353
355
  }
354
- }, [R]), ge = s.useCallback((e) => {
355
- var t, u;
356
- return e == null ? null : (t = (u = T.get(e)) == null ? void 0 : u.ref.current) != null ? t : null;
357
- }, [T]), me = {
356
+ }, [v]), ge = s.useCallback((e) => {
357
+ var t, i;
358
+ return e == null ? null : (t = (i = L.get(e)) == null ? void 0 : i.ref.current) != null ? t : null;
359
+ }, [L]), he = {
358
360
  getInitialState: () => {
359
361
  var e;
360
362
  return {
361
363
  highlightedValue: null,
362
364
  selectedValues: (e = E) != null ? e : [],
363
- open: a
365
+ open: c
364
366
  };
365
367
  },
366
- getItemId: de,
367
- controlledProps: ce,
368
+ getItemId: pe,
369
+ controlledProps: de,
368
370
  focusManagement: "DOM",
369
371
  getItemDomElement: ge,
370
372
  itemComparer: o,
371
373
  isItemDisabled: ee,
372
- rootRef: ue,
373
- onChange: pe,
374
- onHighlightChange: fe,
375
- onStateChange: be,
374
+ rootRef: ae,
375
+ onChange: fe,
376
+ onHighlightChange: be,
377
+ onStateChange: me,
376
378
  reducerActionContext: s.useMemo(() => ({
377
379
  multiple: d
378
380
  }), [d]),
379
381
  items: q,
380
382
  getItemAsString: te,
381
383
  selectionMode: d ? "multiple" : "single",
382
- stateReducer: at,
383
- componentName: C
384
+ stateReducer: ct,
385
+ componentName: _
384
386
  }, {
385
387
  dispatch: D,
386
- getRootProps: he,
388
+ getRootProps: xe,
387
389
  contextValue: K,
388
390
  state: {
389
- open: w,
391
+ open: M,
390
392
  highlightedValue: A,
391
- selectedValues: k
393
+ selectedValues: T
392
394
  },
393
395
  rootRef: z
394
- } = et(me), xe = s.useRef(w);
395
- tt(() => {
396
- if (w && A !== null) {
396
+ } = tt(he), Ce = s.useRef(M);
397
+ ot(() => {
398
+ if (M && A !== null) {
397
399
  var e;
398
- const t = (e = S(A)) == null ? void 0 : e.ref;
399
- if (!_.current || !(t != null && t.current))
400
+ const t = (e = V(A)) == null ? void 0 : e.ref;
401
+ if (!k.current || !(t != null && t.current))
400
402
  return;
401
- xe.current || t.current.focus({
403
+ Ce.current || t.current.focus({
402
404
  preventScroll: !0
403
405
  });
404
- const u = _.current.getBoundingClientRect(), m = t.current.getBoundingClientRect();
405
- m.top < u.top ? _.current.scrollTop -= u.top - m.top : m.bottom > u.bottom && (_.current.scrollTop += m.bottom - u.bottom);
406
+ const i = k.current.getBoundingClientRect(), x = t.current.getBoundingClientRect();
407
+ x.top < i.top ? k.current.scrollTop -= i.top - x.top : x.bottom > i.bottom && (k.current.scrollTop += x.bottom - i.bottom);
406
408
  }
407
- }, [w, A, S]);
408
- const J = s.useCallback((e) => S(e), [S]), Ce = (e) => (t) => {
409
- var u;
410
- if (e == null || (u = e.onClick) == null || u.call(e, t), !t.defaultMuiPrevented) {
411
- const m = {
412
- type: re.buttonClick,
409
+ }, [M, A, V]);
410
+ const W = s.useCallback((e) => V(e), [V]), Pe = (e) => (t) => {
411
+ var i;
412
+ if (e == null || (i = e.onClick) == null || i.call(e, t), !t.defaultMuiPrevented) {
413
+ const x = {
414
+ type: ie.buttonClick,
413
415
  event: t
414
416
  };
415
- D(m);
417
+ D(x);
416
418
  }
417
- }, W = (e) => (t) => {
418
- var u;
419
- (u = e.onKeyDown) == null || u.call(e, t), !t.defaultMuiPrevented && (t.key === "ArrowDown" || t.key === "ArrowUp") && (t.preventDefault(), D({
419
+ }, J = (e) => (t) => {
420
+ var i;
421
+ (i = e.onKeyDown) == null || i.call(e, t), !t.defaultMuiPrevented && (t.key === "ArrowDown" || t.key === "ArrowUp") && (t.preventDefault(), D({
420
422
  type: Q.keyDown,
421
423
  key: t.key,
422
424
  event: t
423
425
  }));
424
426
  }, oe = (e = {}) => ({
425
- onClick: Ce(e),
426
- onKeyDown: W(e)
427
- }), H = (e = {}) => g({}, e, oe(e), {
427
+ onClick: Pe(e),
428
+ onKeyDown: J(e)
429
+ }), $ = (e = {}) => m({}, e, oe(e), {
428
430
  role: "combobox",
429
- "aria-expanded": w,
430
- "aria-controls": $
431
+ "aria-expanded": M,
432
+ "aria-controls": H
431
433
  }), He = (e = {}) => {
432
- const t = ne(e), u = se(H, Z);
433
- return g({}, e, u(t));
434
- }, $e = (e) => (t) => {
435
- var u, m;
436
- (u = e.onBlur) == null || u.call(e, t), !t.defaultMuiPrevented && ((m = _.current) != null && m.contains(t.relatedTarget) || t.relatedTarget === P.current) && (t.defaultMuiPrevented = !0);
437
- }, Fe = (e = {}) => ({
438
- onBlur: $e(e)
439
- }), qe = (e = {}) => {
440
- const t = ne(e), u = se(Fe, he);
441
- return g({
442
- id: $,
434
+ const t = le(e), i = re($, Z);
435
+ return m({}, e, i(t));
436
+ }, Fe = (e) => (t) => {
437
+ var i, x;
438
+ (i = e.onBlur) == null || i.call(e, t), !t.defaultMuiPrevented && ((x = k.current) != null && x.contains(t.relatedTarget) || t.relatedTarget === S.current) && (t.defaultMuiPrevented = !0);
439
+ }, qe = (e = {}) => ({
440
+ onBlur: Fe(e)
441
+ }), je = (e = {}) => {
442
+ const t = le(e), i = re(qe, xe);
443
+ return m({
444
+ id: H,
443
445
  role: "listbox",
444
446
  "aria-multiselectable": d ? "true" : void 0
445
- }, e, u(t));
447
+ }, e, i(t));
446
448
  };
447
449
  s.useDebugValue({
448
- selectedOptions: k,
450
+ selectedOptions: T,
449
451
  highlightedOption: A,
450
- open: w
452
+ open: M
451
453
  });
452
- const je = s.useMemo(() => g({}, K, F), [K, F]);
454
+ const Ue = s.useMemo(() => m({}, K, F), [K, F]);
453
455
  let G;
454
- n.multiple ? G = k : G = k.length > 0 ? k[0] : null;
455
- let Pe;
456
+ n.multiple ? G = T : G = T.length > 0 ? T[0] : null;
457
+ let ve;
456
458
  if (d)
457
- Pe = G.map((e) => J(e)).filter((e) => e !== void 0);
459
+ ve = G.map((e) => W(e)).filter((e) => e !== void 0);
458
460
  else {
459
- var Re;
460
- Pe = (Re = J(G)) != null ? Re : null;
461
+ var Se;
462
+ ve = (Se = W(G)) != null ? Se : null;
461
463
  }
462
- const Ue = (e) => (t) => {
463
- var u;
464
- if (e == null || (u = e.onChange) == null || u.call(e, t), t.defaultMuiPrevented)
464
+ const Ke = (e) => (t) => {
465
+ var i;
466
+ if (e == null || (i = e.onChange) == null || i.call(e, t), t.defaultMuiPrevented)
465
467
  return;
466
- const m = V.get(t.target.value);
468
+ const x = N.get(t.target.value);
467
469
  t.target.value === "" ? D({
468
470
  type: Q.clearSelection
469
- }) : m !== void 0 && D({
470
- type: re.browserAutoFill,
471
- item: m.value,
471
+ }) : x !== void 0 && D({
472
+ type: ie.browserAutoFill,
473
+ item: x.value,
472
474
  event: t
473
475
  });
474
476
  };
475
477
  return {
476
- buttonActive: ie,
477
- buttonFocusVisible: ae,
478
+ buttonActive: ue,
479
+ buttonFocusVisible: ce,
478
480
  buttonRef: U,
479
- contextValue: je,
480
- disabled: c,
481
+ contextValue: Ue,
482
+ disabled: u,
481
483
  dispatch: D,
482
484
  getButtonProps: He,
483
485
  getHiddenInputProps: (e = {}) => {
484
- const t = ne(e);
485
- return g({
486
- name: v,
486
+ const t = le(e);
487
+ return m({
488
+ name: C,
487
489
  tabIndex: -1,
488
490
  "aria-hidden": !0,
489
- required: I ? !0 : void 0,
490
- value: B(Pe),
491
- style: ot
491
+ required: O ? !0 : void 0,
492
+ value: B(ve),
493
+ style: nt
492
494
  }, e, {
493
- onChange: Ue(t)
495
+ onChange: Ke(t)
494
496
  });
495
497
  },
496
- getListboxProps: qe,
497
- getOptionMetadata: J,
498
+ getListboxProps: je,
499
+ getOptionMetadata: W,
498
500
  listboxRef: z,
499
- open: w,
501
+ open: M,
500
502
  options: q,
501
503
  value: G,
502
504
  highlightedOption: A
503
505
  };
504
506
  }
505
- function pt(n) {
507
+ function ft(n) {
506
508
  const {
507
509
  value: o,
508
- children: i
510
+ children: a
509
511
  } = n, {
510
- dispatch: a,
512
+ dispatch: c,
511
513
  getItemIndex: r,
512
- getItemState: c,
514
+ getItemState: u,
513
515
  registerItem: p,
514
516
  totalSubitemCount: f
515
517
  } = o, d = s.useMemo(() => ({
516
- dispatch: a,
517
- getItemState: c,
518
+ dispatch: c,
519
+ getItemState: u,
518
520
  getItemIndex: r
519
- }), [a, r, c]), v = s.useMemo(() => ({
521
+ }), [c, r, u]), C = s.useMemo(() => ({
520
522
  getItemIndex: r,
521
523
  registerItem: p,
522
524
  totalSubitemCount: f
523
525
  }), [p, r, f]);
524
- return /* @__PURE__ */ h(Qe.Provider, {
525
- value: v,
526
- children: /* @__PURE__ */ h(ye.Provider, {
526
+ return /* @__PURE__ */ g(Xe.Provider, {
527
+ value: C,
528
+ children: /* @__PURE__ */ g(_e.Provider, {
527
529
  value: d,
528
- children: i
530
+ children: a
529
531
  })
530
532
  });
531
533
  }
532
- const Ee = "Select";
533
- function ft(n) {
534
- return Ve(Ee, n);
534
+ const De = "Select";
535
+ function bt(n) {
536
+ return we(De, n);
535
537
  }
536
- we(Ee, ["root", "button", "listbox", "popup", "active", "expanded", "disabled", "focusVisible"]);
537
- var Se;
538
- const bt = ["areOptionsEqual", "autoComplete", "autoFocus", "children", "defaultValue", "defaultListboxOpen", "disabled", "getSerializedValue", "listboxId", "listboxOpen", "multiple", "name", "required", "onChange", "onListboxOpenChange", "getOptionAsString", "renderValue", "placeholder", "slotProps", "slots", "value"];
538
+ Ie(De, ["root", "button", "listbox", "popup", "active", "expanded", "disabled", "focusVisible"]);
539
+ var Oe;
540
+ const mt = ["areOptionsEqual", "autoComplete", "autoFocus", "children", "defaultValue", "defaultListboxOpen", "disabled", "getSerializedValue", "listboxId", "listboxOpen", "multiple", "name", "required", "onChange", "onListboxOpenChange", "getOptionAsString", "renderValue", "placeholder", "slotProps", "slots", "value"];
539
541
  function gt(n) {
540
542
  var o;
541
- return Array.isArray(n) ? /* @__PURE__ */ h(s.Fragment, {
542
- children: n.map((i) => i.label).join(", ")
543
+ return Array.isArray(n) ? /* @__PURE__ */ g(s.Fragment, {
544
+ children: n.map((a) => a.label).join(", ")
543
545
  }) : (o = n == null ? void 0 : n.label) != null ? o : null;
544
546
  }
545
- function mt(n) {
547
+ function ht(n) {
546
548
  const {
547
549
  active: o,
548
- disabled: i,
549
- open: a,
550
+ disabled: a,
551
+ open: c,
550
552
  focusVisible: r
551
553
  } = n;
552
- return Ie({
553
- root: ["root", i && "disabled", r && "focusVisible", o && "active", a && "expanded"],
554
- listbox: ["listbox", i && "disabled"],
554
+ return Ne({
555
+ root: ["root", a && "disabled", r && "focusVisible", o && "active", c && "expanded"],
556
+ listbox: ["listbox", a && "disabled"],
555
557
  popup: ["popup"]
556
- }, Ne(ft));
558
+ }, Me(bt));
557
559
  }
558
- const De = /* @__PURE__ */ s.forwardRef(function(o, i) {
559
- var a, r, c, p, f;
560
+ const $e = /* @__PURE__ */ s.forwardRef(function(o, a) {
561
+ var c, r, u, p, f;
560
562
  const {
561
563
  areOptionsEqual: d,
562
- autoComplete: v,
563
- autoFocus: I,
564
- children: x,
565
- defaultValue: y,
566
- defaultListboxOpen: R = !1,
567
- disabled: N,
568
- getSerializedValue: O,
569
- listboxId: M,
564
+ autoComplete: C,
565
+ autoFocus: O,
566
+ children: h,
567
+ defaultValue: P,
568
+ defaultListboxOpen: v = !1,
569
+ disabled: y,
570
+ getSerializedValue: R,
571
+ listboxId: I,
570
572
  listboxOpen: B,
571
573
  multiple: b = !1,
572
- name: C,
573
- required: P = !1,
574
+ name: _,
575
+ required: S = !1,
574
576
  onChange: j,
575
- onListboxOpenChange: _,
576
- getOptionAsString: $ = Be,
577
+ onListboxOpenChange: k,
578
+ getOptionAsString: H = Ee,
577
579
  renderValue: E,
578
580
  placeholder: Y,
579
- slotProps: T = {},
581
+ slotProps: L = {},
580
582
  slots: F = {},
581
- value: V
582
- } = o, ue = ke(o, bt), Z = E ?? gt, [ie, ae] = s.useState(!1), U = s.useRef(null), q = s.useRef(null), S = (a = F.root) != null ? a : "button", ee = (r = F.listbox) != null ? r : "ul", te = (c = F.popup) != null ? c : "div", ce = s.useCallback((H) => {
583
- ae(H != null);
584
- }, []), de = X(i, U, ce);
583
+ value: N
584
+ } = o, ae = ke(o, mt), Z = E ?? gt, [ue, ce] = s.useState(!1), U = s.useRef(null), q = s.useRef(null), V = (c = F.root) != null ? c : "button", ee = (r = F.listbox) != null ? r : "ul", te = (u = F.popup) != null ? u : "div", de = s.useCallback(($) => {
585
+ ce($ != null);
586
+ }, []), pe = X(a, U, de);
585
587
  s.useEffect(() => {
586
- I && U.current.focus();
587
- }, [I]);
588
+ O && U.current.focus();
589
+ }, [O]);
588
590
  const {
589
- buttonActive: pe,
590
- buttonFocusVisible: fe,
591
- contextValue: be,
591
+ buttonActive: fe,
592
+ buttonFocusVisible: be,
593
+ contextValue: me,
592
594
  disabled: ge,
593
- getButtonProps: me,
595
+ getButtonProps: he,
594
596
  getListboxProps: D,
595
- getHiddenInputProps: he,
597
+ getHiddenInputProps: xe,
596
598
  getOptionMetadata: K,
597
- value: w,
599
+ value: M,
598
600
  open: A
599
- } = dt({
600
- name: C,
601
- required: P,
602
- getSerializedValue: O,
601
+ } = pt({
602
+ name: _,
603
+ required: S,
604
+ getSerializedValue: R,
603
605
  areOptionsEqual: d,
604
- buttonRef: de,
605
- defaultOpen: R,
606
- defaultValue: y,
607
- disabled: N,
608
- listboxId: M,
606
+ buttonRef: pe,
607
+ defaultOpen: v,
608
+ defaultValue: P,
609
+ disabled: y,
610
+ listboxId: I,
609
611
  multiple: b,
610
612
  open: B,
611
613
  onChange: j,
612
- onOpenChange: _,
613
- getOptionAsString: $,
614
- value: V,
614
+ onOpenChange: k,
615
+ getOptionAsString: H,
616
+ value: N,
615
617
  componentName: "Select"
616
- }), k = g({}, o, {
617
- active: pe,
618
- defaultListboxOpen: R,
618
+ }), T = m({}, o, {
619
+ active: fe,
620
+ defaultListboxOpen: v,
619
621
  disabled: ge,
620
- focusVisible: fe,
622
+ focusVisible: be,
621
623
  open: A,
622
624
  multiple: b,
623
625
  renderValue: Z,
624
- value: w
625
- }), z = mt(k), xe = le({
626
- elementType: S,
627
- getSlotProps: me,
628
- externalSlotProps: T.root,
629
- externalForwardedProps: ue,
630
- ownerState: k,
626
+ value: M
627
+ }), z = ht(T), Ce = se({
628
+ elementType: V,
629
+ getSlotProps: he,
630
+ externalSlotProps: L.root,
631
+ externalForwardedProps: ae,
632
+ ownerState: T,
631
633
  className: z.root
632
- }), J = le({
634
+ }), W = se({
633
635
  elementType: ee,
634
636
  getSlotProps: D,
635
- externalSlotProps: T.listbox,
637
+ externalSlotProps: L.listbox,
636
638
  additionalProps: {
637
639
  ref: q
638
640
  },
639
- ownerState: k,
641
+ ownerState: T,
640
642
  className: z.listbox
641
- }), Ce = le({
643
+ }), Pe = se({
642
644
  elementType: te,
643
- externalSlotProps: T.popup,
645
+ externalSlotProps: L.popup,
644
646
  additionalProps: {
645
647
  anchor: U.current,
646
648
  keepMounted: !0,
@@ -648,43 +650,43 @@ const De = /* @__PURE__ */ s.forwardRef(function(o, i) {
648
650
  placement: "bottom-start",
649
651
  role: void 0
650
652
  },
651
- ownerState: k,
653
+ ownerState: T,
652
654
  className: z.popup
653
655
  });
654
- let W;
656
+ let J;
655
657
  if (b)
656
- W = w.map((H) => K(H)).filter((H) => H !== void 0);
658
+ J = M.map(($) => K($)).filter(($) => $ !== void 0);
657
659
  else {
658
660
  var oe;
659
- W = (oe = K(w)) != null ? oe : null;
661
+ J = (oe = K(M)) != null ? oe : null;
660
662
  }
661
- return /* @__PURE__ */ Oe(s.Fragment, {
662
- children: [/* @__PURE__ */ h(S, g({}, xe, {
663
- children: (p = (f = Z(W)) != null ? f : Y) != null ? p : (
663
+ return /* @__PURE__ */ Re(s.Fragment, {
664
+ children: [/* @__PURE__ */ g(V, m({}, Ce, {
665
+ children: (p = (f = Z(J)) != null ? f : Y) != null ? p : (
664
666
  // fall back to a zero-width space to prevent layout shift
665
667
  // from https://github.com/mui/material-ui/pull/24563
666
- Se || (Se = /* @__PURE__ */ h("span", {
668
+ Oe || (Oe = /* @__PURE__ */ g("span", {
667
669
  className: "notranslate",
668
670
  children: "​"
669
671
  }))
670
672
  )
671
- })), ie && /* @__PURE__ */ h(Xe, g({
673
+ })), ue && /* @__PURE__ */ g(Ye, m({
672
674
  slots: {
673
675
  root: te
674
676
  }
675
- }, Ce, {
676
- children: /* @__PURE__ */ h(ee, g({}, J, {
677
- children: /* @__PURE__ */ h(pt, {
678
- value: be,
679
- children: x
677
+ }, Pe, {
678
+ children: /* @__PURE__ */ g(ee, m({}, W, {
679
+ children: /* @__PURE__ */ g(ft, {
680
+ value: me,
681
+ children: h
680
682
  })
681
683
  }))
682
- })), /* @__PURE__ */ h("input", g({}, he(), {
683
- autoComplete: v
684
+ })), /* @__PURE__ */ g("input", m({}, xe(), {
685
+ autoComplete: C
684
686
  }))]
685
687
  });
686
688
  });
687
- process.env.NODE_ENV !== "production" && (De.propTypes = {
689
+ process.env.NODE_ENV !== "production" && ($e.propTypes = {
688
690
  // ┌────────────────────────────── Warning ──────────────────────────────┐
689
691
  // │ These PropTypes are generated from the TypeScript type definitions. │
690
692
  // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
@@ -811,47 +813,89 @@ process.env.NODE_ENV !== "production" && (De.propTypes = {
811
813
  */
812
814
  value: l.any
813
815
  });
814
- const ht = (n) => {
815
- const { children: o, icon: i, className: a, ...r } = n;
816
- return /* @__PURE__ */ Oe(
817
- Le,
816
+ const xt = (n) => {
817
+ const { children: o, icon: a, className: c, ...r } = n;
818
+ return /* @__PURE__ */ Re(
819
+ Be,
818
820
  {
819
821
  ...r,
820
822
  slotProps: {
821
- root: (c) => ({
822
- className: _e(L.select__listbox__option, a, {
823
- [L["select__listbox__option--disabled"]]: c.disabled,
824
- [L["select__listbox__option--selected"]]: c.selected
823
+ root: (u) => ({
824
+ className: ne(w.select__listbox__option, c, {
825
+ [w["select__listbox__option--disabled"]]: u.disabled,
826
+ [w["select__listbox__option--selected"]]: u.selected
825
827
  })
826
828
  })
827
829
  },
828
830
  children: [
829
- i ? /* @__PURE__ */ h("span", { className: L.select__listbox__option__icon, children: i }) : "",
830
- /* @__PURE__ */ h(Ke, { className: L.select__listbox__option__text, children: o })
831
+ a ? /* @__PURE__ */ g("span", { className: w.select__listbox__option__icon, children: a }) : "",
832
+ /* @__PURE__ */ g(Ve, { className: w.select__listbox__option__text, children: o })
831
833
  ]
832
834
  }
833
835
  );
834
- }, xt = (n) => {
835
- const { children: o, className: i, onChange: a, ...r } = n;
836
- return /* @__PURE__ */ h(
837
- De,
836
+ }, Ct = (n) => {
837
+ const {
838
+ children: o,
839
+ className: a,
840
+ id: c,
841
+ onChange: r,
842
+ label: u,
843
+ classNameWrapper: p,
844
+ classNameLabel: f,
845
+ testIdLabel: d,
846
+ testIdWrapper: C,
847
+ fullWidth: O = !0,
848
+ ...h
849
+ } = n, P = (R, I) => {
850
+ R && (r == null || r(I, R));
851
+ }, v = ze(), y = c || `select_${v}`;
852
+ return /* @__PURE__ */ Re(
853
+ "div",
838
854
  {
839
- ...r,
840
- onChange: (p, f) => {
841
- p && (a == null || a(f, p));
842
- },
843
- className: _e(L.select, i),
844
- slots: { root: ze },
845
- slotProps: {
846
- listbox: { className: L.select__listbox },
847
- popup: { className: L.select__popup }
848
- },
849
- children: o
855
+ className: ne(
856
+ w.select__wrapper,
857
+ !O && w["select__wrapper--fit-content-width"],
858
+ p
859
+ ),
860
+ "data-testid": C,
861
+ id: `${y}_wrapper`,
862
+ children: [
863
+ u && /* @__PURE__ */ g(
864
+ Ve,
865
+ {
866
+ element: "label",
867
+ elementProps: { htmlFor: y, id: `${y}_label` },
868
+ className: ne(w.select__label, f),
869
+ "data-testid": d,
870
+ children: u
871
+ }
872
+ ),
873
+ /* @__PURE__ */ g(
874
+ $e,
875
+ {
876
+ ...h,
877
+ id: y,
878
+ onChange: P,
879
+ className: ne(w.select, a),
880
+ slots: { root: We },
881
+ slotProps: {
882
+ root: { fullWidth: O },
883
+ listbox: { className: w.select__listbox },
884
+ popup: {
885
+ className: w.select__popup,
886
+ disablePortal: !0,
887
+ strategy: "absolute"
888
+ }
889
+ },
890
+ children: o
891
+ }
892
+ )
893
+ ]
850
894
  }
851
895
  );
852
896
  };
853
- xt.Option = ht;
897
+ Ct.Option = xt;
854
898
  export {
855
- xt as Select,
856
- ht as SelectOption
899
+ Ct as Select,
900
+ xt as SelectOption
857
901
  };