@clearstory/drywall-react 5.2.2 → 5.3.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 (89) hide show
  1. package/dist/{Accordion-m2AFrwDc.js → Accordion-DsTwQkV4.js} +68 -78
  2. package/dist/{AccordionSummary-Db2tRAW5.js → AccordionSummary-CmaoAjhY.js} +1 -1
  3. package/dist/{AdapterDayjs-BeNOjkDj.js → AdapterDayjs-CROwpFLu.js} +1 -1
  4. package/dist/{Alert-CUOGimrv.js → Alert-CMRw5H2i.js} +81 -81
  5. package/dist/{ArrowDropDown-CJcUO7Km.js → ArrowDropDown-CpR6Sb-x.js} +1 -1
  6. package/dist/{Autocomplete-BG3jpE2X.js → Autocomplete-ByiENcHd.js} +337 -328
  7. package/dist/{Backdrop-CfSoI3NV.js → Backdrop-CvXmU9nP.js} +32 -33
  8. package/dist/{Breadcrumbs-DCnGkMd5.js → Breadcrumbs-C6IvNkJk.js} +1 -1
  9. package/dist/{Button-CdA9C690.js → Button-CUl6Z1bM.js} +1 -1
  10. package/dist/{ButtonBase-es4rY3j-.js → ButtonBase-sOMllYPF.js} +1 -1
  11. package/dist/{ButtonGroup-Btb5I3qo.js → ButtonGroup-BCAFY0lq.js} +15 -18
  12. package/dist/{CardActionArea-DFoDWYk5.js → CardActionArea-BOqtC3NS.js} +13 -14
  13. package/dist/{Checkbox-l14tfKVr.js → Checkbox-0V6Yy2lG.js} +1 -1
  14. package/dist/{Chip-Dvsr-37n.js → Chip-DAwDUQgy.js} +1 -1
  15. package/dist/{Collapse-BorUfOHf.js → Collapse-C2AFUmVW.js} +1 -1
  16. package/dist/{Datepicker-D3cWtwmS.js → Datepicker-BbdXCdvk.js} +27 -16
  17. package/dist/{Dialog-Cn2dsmZm.js → Dialog-oPKzro59.js} +24 -23
  18. package/dist/{Drawer-BVvVj14Z.js → Drawer-C5QtOOvf.js} +1 -1
  19. package/dist/{IconButton-C233MDPx.js → IconButton-CxPeGp7M.js} +1 -1
  20. package/dist/{InputBase-BM3Auzz5.js → InputBase-C6Ryue4Q.js} +1 -1
  21. package/dist/{KeyboardArrowRight-Cm6Izw7f.js → KeyboardArrowRight-Blb72ZVb.js} +2 -2
  22. package/dist/{Link-B6cIxbWI.js → Link-CaDghPux.js} +1 -1
  23. package/dist/{ListItem-ZE8vLL1k.js → ListItem-Cy6ddrqC.js} +1 -1
  24. package/dist/{ListItemButton-DQtMbD5o.js → ListItemButton-D17P7zbm.js} +1 -1
  25. package/dist/{Menu-BExv75wS.js → Menu-CCiom50Z.js} +1 -1
  26. package/dist/{MenuItem-D15dnYfh.js → MenuItem-DHXbU6OE.js} +1 -1
  27. package/dist/{Modal-DWjk-ELn.js → Modal-BC16DZHY.js} +136 -134
  28. package/dist/{Popover-CsFfsZ3j.js → Popover-BV7s_KXx.js} +2 -2
  29. package/dist/{Radio-Bd2tUvwi.js → Radio-BVPgbnjg.js} +1 -1
  30. package/dist/{Select-De55ndN6.js → Select-NMI0Dg3g.js} +281 -270
  31. package/dist/{StepButton-BGCwBo-2.js → StepButton-yiMA6Gky.js} +1 -1
  32. package/dist/{StepContent-DP-2AduZ.js → StepContent-DoTaN9XK.js} +1 -1
  33. package/dist/{Switch-UrF12x0u.js → Switch-9nD-9uqh.js} +1 -1
  34. package/dist/{SwitchBase-CbbeqU9c.js → SwitchBase-D6IsSQaW.js} +34 -34
  35. package/dist/{Tab-CfdValV7.js → Tab-mGJoNbh1.js} +1 -1
  36. package/dist/{TablePagination-DfEbbPT0.js → TablePagination-CmvSEXbm.js} +5 -5
  37. package/dist/{Tabs-b6WnXeJW.js → Tabs-CLLc_rdV.js} +3 -3
  38. package/dist/{ToggleButton-DktXGko4.js → ToggleButton-ChGvFY9f.js} +1 -1
  39. package/dist/components/Accordion/index.js +1 -1
  40. package/dist/components/AccordionSummary/index.js +1 -1
  41. package/dist/components/Alert/index.js +1 -1
  42. package/dist/components/Autocomplete/Autocomplete.js +4 -3
  43. package/dist/components/Autocomplete/index.js +1 -1
  44. package/dist/components/AutocompleteControl/AutocompleteControl.js +7 -6
  45. package/dist/components/Backdrop/index.js +1 -1
  46. package/dist/components/Breadcrumbs/index.js +1 -1
  47. package/dist/components/Button/index.js +1 -1
  48. package/dist/components/ButtonBase/index.js +1 -1
  49. package/dist/components/ButtonGroup/index.js +1 -1
  50. package/dist/components/CardActionArea/index.js +1 -1
  51. package/dist/components/Checkbox/index.js +1 -1
  52. package/dist/components/Chip/index.js +1 -1
  53. package/dist/components/Collapse/index.js +1 -1
  54. package/dist/components/Datepicker/Datepicker.js +2 -2
  55. package/dist/components/Datepicker/index.js +2 -2
  56. package/dist/components/DatepickerControl/DatepickerControl.js +2 -1
  57. package/dist/components/Dialog/index.js +1 -1
  58. package/dist/components/DialogClose/DialogClose.js +4 -3
  59. package/dist/components/Drawer/index.js +1 -1
  60. package/dist/components/IconButton/index.js +1 -1
  61. package/dist/components/Input/Input.js +1 -1
  62. package/dist/components/InputControl/InputControl.js +6 -5
  63. package/dist/components/Link/index.js +1 -1
  64. package/dist/components/ListItem/index.js +1 -1
  65. package/dist/components/ListItemButton/index.js +1 -1
  66. package/dist/components/Menu/index.js +1 -1
  67. package/dist/components/MenuItem/index.js +1 -1
  68. package/dist/components/NumberInputControl/NumberInputControl.js +1 -0
  69. package/dist/components/Popover/index.js +1 -1
  70. package/dist/components/Radio/index.js +1 -1
  71. package/dist/components/Select/Select.js +1 -1
  72. package/dist/components/Select/index.js +1 -1
  73. package/dist/components/SelectControl/SelectControl.js +1 -0
  74. package/dist/components/StepButton/index.js +1 -1
  75. package/dist/components/StepContent/index.js +1 -1
  76. package/dist/components/Switch/index.js +1 -1
  77. package/dist/components/Tab/index.js +1 -1
  78. package/dist/components/TablePagination/index.js +1 -1
  79. package/dist/components/Tabs/index.js +1 -1
  80. package/dist/components/ToastContainer/useToast.js +5 -4
  81. package/dist/components/ToggleButton/index.js +1 -1
  82. package/dist/elementTypeAcceptingRef-xVpq_4jW.js +24 -0
  83. package/dist/icons/SparkleIcon.d.ts +5 -0
  84. package/dist/icons/SparkleIcon.js +9 -0
  85. package/dist/icons/index.d.ts +1 -0
  86. package/dist/icons/index.js +128 -126
  87. package/dist/main.js +579 -577
  88. package/package.json +6 -6
  89. package/dist/elementTypeAcceptingRef-I_eZHB1B.js +0 -23
@@ -1,4 +1,4 @@
1
- import { jsx as $, jsxs as Ue } from "react/jsx-runtime";
1
+ import { jsx as $, jsxs as Be } from "react/jsx-runtime";
2
2
  import * as y from "react";
3
3
  import { forwardRef as Vt } from "react";
4
4
  import { Input as Ft } from "./components/Input/Input.js";
@@ -6,12 +6,13 @@ import "./icons/ClearstoryIcon.js";
6
6
  import "./icons/InternalOnlyIcon.js";
7
7
  import "./icons/MoneyBucketIcon.js";
8
8
  import "./icons/MoreCircleOutlineIcon.js";
9
+ import "./icons/SparkleIcon.js";
9
10
  import { A as Ht, C as zt } from "./Clear-BX3xsbCY.js";
10
11
  import { g as kt } from "./generateUtilityClass-BhfUaMgk.js";
11
12
  import { P as o } from "./index-B5q5ym9h.js";
12
- import { c as it } from "./clsx-OuTLNxxd.js";
13
- import { A as jt, f as xe, o as Ct, i as st } from "./ArrowDropDown-CJcUO7Km.js";
14
- import { i as ue } from "./InputBase-BM3Auzz5.js";
13
+ import { c as lt } from "./clsx-OuTLNxxd.js";
14
+ import { A as jt, f as xe, o as Ct, i as st } from "./ArrowDropDown-CpR6Sb-x.js";
15
+ import { i as ce } from "./InputBase-C6Ryue4Q.js";
15
16
  import { C as Bt } from "./Close-C2_eLkhZ.js";
16
17
  import { m as ye } from "./memoTheme-D7rECXXN.js";
17
18
  import { g as Ut } from "./generateUtilityClasses-E9gROIFd.js";
@@ -20,15 +21,15 @@ import { u as Wt } from "./DefaultPropsProvider-CE6KNOqW.js";
20
21
  import { u as Gt } from "./useId-CK6Kn3Tn.js";
21
22
  import { u as ut } from "./useControlled-D1L5tREc.js";
22
23
  import { u as Kt } from "./usePreviousProps-7NDRTUOj.js";
23
- import { u as We } from "./useEventCallback-BAQJJ3ye.js";
24
+ import { u as Ue } from "./useEventCallback-BAQJJ3ye.js";
24
25
  import { s as qt } from "./Portal-DdS5LtfN.js";
25
- import { s as B } from "./styled-BKpRY52y.js";
26
+ import { s as U } from "./styled-BKpRY52y.js";
26
27
  import { P as Dt } from "./Paper-COvzoSpI.js";
27
28
  import { P as Rt } from "./Popper-JL6hDc7M.js";
28
- import { C as _t } from "./Chip-Dvsr-37n.js";
29
+ import { C as _t } from "./Chip-DAwDUQgy.js";
29
30
  import { h as Et } from "./createTheme-Cr8frjQ0.js";
30
31
  import { c as Jt } from "./composeClasses-2Ou-RZJr.js";
31
- import { I as Nt } from "./IconButton-C233MDPx.js";
32
+ import { I as Nt } from "./IconButton-CxPeGp7M.js";
32
33
  import { L as Xt } from "./ListSubheader-Dr443Sr5.js";
33
34
  import { c as $t } from "./chainPropTypes-D9lkm76m.js";
34
35
  import { i as Yt } from "./integerPropType-BihGt2aU.js";
@@ -52,13 +53,13 @@ function Qt(n = {}) {
52
53
  trim: N = !1
53
54
  } = n;
54
55
  return (R, {
55
- inputValue: U,
56
+ inputValue: W,
56
57
  getOptionLabel: O
57
58
  }) => {
58
- let A = N ? U.trim() : U;
59
+ let A = N ? W.trim() : W;
59
60
  g && (A = A.toLowerCase()), p && (A = Tt(A));
60
- const H = A ? R.filter((ce) => {
61
- let v = (F || O)(ce);
61
+ const H = A ? R.filter((de) => {
62
+ let v = (F || O)(de);
62
63
  return g && (v = v.toLowerCase()), p && (v = Tt(v)), S === "start" ? v.startsWith(A) : v.includes(A);
63
64
  }) : R;
64
65
  return typeof f == "number" ? H.slice(0, f) : H;
@@ -82,43 +83,43 @@ function oo(n) {
82
83
  autoSelect: F = !1,
83
84
  blurOnSelect: N = !1,
84
85
  clearOnBlur: R = !n.freeSolo,
85
- clearOnEscape: U = !1,
86
+ clearOnEscape: W = !1,
86
87
  componentName: O = "useAutocomplete",
87
88
  defaultValue: A = n.multiple ? to : null,
88
89
  disableClearable: H = !1,
89
- disableCloseOnSelect: ce = !1,
90
+ disableCloseOnSelect: de = !1,
90
91
  disabled: v,
91
- disabledItemsFocusable: ke = !1,
92
- disableListWrap: De = !1,
92
+ disabledItemsFocusable: Le = !1,
93
+ disableListWrap: ke = !1,
93
94
  filterOptions: ct = Zt,
94
- filterSelectedOptions: Ge = !1,
95
- freeSolo: de = !1,
96
- getOptionDisabled: W,
95
+ filterSelectedOptions: We = !1,
96
+ freeSolo: Z = !1,
97
+ getOptionDisabled: G,
97
98
  getOptionKey: dt,
98
- getOptionLabel: Ke = (t) => t.label ?? t,
99
- groupBy: ae,
100
- handleHomeEndKeys: qe = !n.freeSolo,
99
+ getOptionLabel: Ge = (t) => t.label ?? t,
100
+ groupBy: ie,
101
+ handleHomeEndKeys: Ke = !n.freeSolo,
101
102
  id: ft,
102
103
  includeInputInList: Oe = !1,
103
- inputValue: Re,
104
- isOptionEqualToValue: Q = (t, e) => t === e,
104
+ inputValue: De,
105
+ isOptionEqualToValue: ee = (t, e) => t === e,
105
106
  multiple: u = !1,
106
- onChange: _e,
107
- onClose: Je,
108
- onHighlightChange: Ee,
109
- onInputChange: Z,
110
- onOpen: Ne,
107
+ onChange: qe,
108
+ onClose: _e,
109
+ onHighlightChange: Re,
110
+ onInputChange: M,
111
+ onOpen: Ee,
111
112
  open: gt,
112
113
  openOnFocus: mt = !1,
113
114
  options: ht,
114
- readOnly: G = !1,
115
+ readOnly: q = !1,
115
116
  renderValue: L,
116
- selectOnFocus: Xe = !n.freeSolo,
117
- value: Me
117
+ selectOnFocus: Je = !n.freeSolo,
118
+ value: Ne
118
119
  } = n, E = Gt(ft);
119
- let P = Ke;
120
+ let P = Ge;
120
121
  P = (t) => {
121
- const e = Ke(t);
122
+ const e = Ge(t);
122
123
  if (typeof e != "string") {
123
124
  if (process.env.NODE_ENV !== "production") {
124
125
  const r = e === void 0 ? "undefined" : `${typeof e} (${e})`;
@@ -128,43 +129,43 @@ function oo(n) {
128
129
  }
129
130
  return e;
130
131
  };
131
- const Pe = y.useRef(!1), Ce = y.useRef(!0), b = y.useRef(null), M = y.useRef(null), [$e, bt] = y.useState(null), [k, K] = y.useState(-1), Ye = S ? 0 : -1, T = y.useRef(Ye), It = y.useRef(St(A ?? Me, u, P)).current, [l, Ae] = ut({
132
- controlled: Me,
132
+ const Pe = y.useRef(!1), Ce = y.useRef(!0), b = y.useRef(null), V = y.useRef(null), [$e, bt] = y.useState(null), [k, le] = y.useState(-1), Xe = S ? 0 : -1, T = y.useRef(Xe), It = y.useRef(St(A ?? Ne, u, P)).current, [i, Ye] = ut({
133
+ controlled: Ne,
133
134
  default: A,
134
135
  name: O
135
- }), [d, le] = ut({
136
- controlled: Re,
136
+ }), [d, _] = ut({
137
+ controlled: De,
137
138
  default: It,
138
139
  name: O,
139
140
  state: "inputValue"
140
- }), [fe, Ve] = y.useState(!1), ge = y.useCallback((t, e, r) => {
141
- if (!(u ? l.length < e.length : e !== null) && !R)
141
+ }), [fe, Me] = y.useState(!1), ge = y.useCallback((t, e, r) => {
142
+ if (!(u ? i.length < e.length : e !== null) && !R)
142
143
  return;
143
- const i = St(e, u, P, L);
144
- d !== i && (le(i), Z && Z(t, i, r));
145
- }, [P, d, u, Z, le, R, l, L]), [q, ie] = ut({
144
+ const l = St(e, u, P, L);
145
+ d !== l && (_(l), M && M(t, l, r));
146
+ }, [P, d, u, M, _, R, i, L]), [J, se] = ut({
146
147
  controlled: gt,
147
148
  default: !1,
148
149
  name: O,
149
150
  state: "open"
150
- }), [xt, me] = y.useState(!0), Fe = !u && l != null && d === P(l), w = q && !G, m = w ? ct(
151
- ht.filter((t) => !(Ge && (u ? l : [l]).some((e) => e !== null && Q(t, e)))),
151
+ }), [xt, me] = y.useState(!0), Ve = !u && i != null && d === P(i), w = J && !q, m = w ? ct(
152
+ ht.filter((t) => !(We && (u ? i : [i]).some((e) => e !== null && ee(t, e)))),
152
153
  // we use the empty string to manipulate `filterOptions` to not filter any options
153
154
  // i.e. the filter predicate always returns true
154
155
  {
155
- inputValue: Fe && xt ? "" : d,
156
+ inputValue: Ve && xt ? "" : d,
156
157
  getOptionLabel: P
157
158
  }
158
159
  ) : [], z = Kt({
159
160
  filteredOptions: m,
160
- value: l,
161
+ value: i,
161
162
  inputValue: d
162
163
  });
163
164
  y.useEffect(() => {
164
- const t = l !== z.value;
165
- fe && !t || de && !t || ge(null, l, "reset");
166
- }, [l, ge, fe, z.value, de]);
167
- const He = q && m.length > 0 && !G, V = We((t) => {
165
+ const t = i !== z.value;
166
+ fe && !t || Z && !t || ge(null, i, "reset");
167
+ }, [i, ge, fe, z.value, Z]);
168
+ const Fe = J && m.length > 0 && !q, K = Ue((t) => {
168
169
  if (t === -1)
169
170
  b.current.focus();
170
171
  else {
@@ -173,42 +174,42 @@ function oo(n) {
173
174
  }
174
175
  });
175
176
  y.useEffect(() => {
176
- u && k > l.length - 1 && (K(-1), V(-1));
177
- }, [l, u, k, V]);
177
+ u && k > i.length - 1 && (le(-1), K(-1));
178
+ }, [i, u, k, K]);
178
179
  function Qe(t, e) {
179
- if (!M.current || t < 0 || t >= m.length)
180
+ if (!V.current || t < 0 || t >= m.length)
180
181
  return -1;
181
182
  let r = t;
182
183
  for (; ; ) {
183
- const a = M.current.querySelector(`[data-option-index="${r}"]`), i = ke ? !1 : !a || a.disabled || a.getAttribute("aria-disabled") === "true";
184
- if (a && a.hasAttribute("tabindex") && !i)
184
+ const a = V.current.querySelector(`[data-option-index="${r}"]`), l = Le ? !1 : !a || a.disabled || a.getAttribute("aria-disabled") === "true";
185
+ if (a && a.hasAttribute("tabindex") && !l)
185
186
  return r;
186
187
  if (e === "next" ? r = (r + 1) % m.length : r = (r - 1 + m.length) % m.length, r === t)
187
188
  return -1;
188
189
  }
189
190
  }
190
- const _ = We(({
191
+ const X = Ue(({
191
192
  event: t,
192
193
  index: e,
193
194
  reason: r
194
195
  }) => {
195
- if (T.current = e, e === -1 ? b.current.removeAttribute("aria-activedescendant") : b.current.setAttribute("aria-activedescendant", `${E}-option-${e}`), Ee && ["mouse", "keyboard", "touch"].includes(r) && Ee(t, e === -1 ? null : m[e], r), !M.current)
196
+ if (T.current = e, e === -1 ? b.current.removeAttribute("aria-activedescendant") : b.current.setAttribute("aria-activedescendant", `${E}-option-${e}`), Re && ["mouse", "keyboard", "touch"].includes(r) && Re(t, e === -1 ? null : m[e], r), !V.current)
196
197
  return;
197
- const a = M.current.querySelector(`[role="option"].${g}-focused`);
198
+ const a = V.current.querySelector(`[role="option"].${g}-focused`);
198
199
  a && (a.classList.remove(`${g}-focused`), a.classList.remove(`${g}-focusVisible`));
199
- let i = M.current;
200
- if (M.current.getAttribute("role") !== "listbox" && (i = M.current.parentElement.querySelector('[role="listbox"]')), !i)
200
+ let l = V.current;
201
+ if (V.current.getAttribute("role") !== "listbox" && (l = V.current.parentElement.querySelector('[role="listbox"]')), !l)
201
202
  return;
202
203
  if (e === -1) {
203
- i.scrollTop = 0;
204
+ l.scrollTop = 0;
204
205
  return;
205
206
  }
206
- const h = M.current.querySelector(`[data-option-index="${e}"]`);
207
- if (h && (h.classList.add(`${g}-focused`), r === "keyboard" && h.classList.add(`${g}-focusVisible`), i.scrollHeight > i.clientHeight && r !== "mouse" && r !== "touch")) {
208
- const I = h, D = i.clientHeight + i.scrollTop, Ie = I.offsetTop + I.offsetHeight;
209
- Ie > D ? i.scrollTop = Ie - i.clientHeight : I.offsetTop - I.offsetHeight * (ae ? 1.3 : 0) < i.scrollTop && (i.scrollTop = I.offsetTop - I.offsetHeight * (ae ? 1.3 : 0));
207
+ const h = V.current.querySelector(`[data-option-index="${e}"]`);
208
+ if (h && (h.classList.add(`${g}-focused`), r === "keyboard" && h.classList.add(`${g}-focusVisible`), l.scrollHeight > l.clientHeight && r !== "mouse" && r !== "touch")) {
209
+ const I = h, D = l.clientHeight + l.scrollTop, Ie = I.offsetTop + I.offsetHeight;
210
+ Ie > D ? l.scrollTop = Ie - l.clientHeight : I.offsetTop - I.offsetHeight * (ie ? 1.3 : 0) < l.scrollTop && (l.scrollTop = I.offsetTop - I.offsetHeight * (ie ? 1.3 : 0));
210
211
  }
211
- }), j = We(({
212
+ }), j = Ue(({
212
213
  event: t,
213
214
  diff: e,
214
215
  direction: r = "next",
@@ -219,15 +220,15 @@ function oo(n) {
219
220
  const h = Qe((() => {
220
221
  const I = m.length - 1;
221
222
  if (e === "reset")
222
- return Ye;
223
+ return Xe;
223
224
  if (e === "start")
224
225
  return 0;
225
226
  if (e === "end")
226
227
  return I;
227
228
  const D = T.current + e;
228
- return D < 0 ? D === -1 && Oe ? -1 : De && T.current !== -1 || Math.abs(e) > 1 ? 0 : I : D > I ? D === I + 1 && Oe ? -1 : De || Math.abs(e) > 1 ? I : 0 : D;
229
+ return D < 0 ? D === -1 && Oe ? -1 : ke && T.current !== -1 || Math.abs(e) > 1 ? 0 : I : D > I ? D === I + 1 && Oe ? -1 : ke || Math.abs(e) > 1 ? I : 0 : D;
229
230
  })(), r);
230
- if (_({
231
+ if (X({
231
232
  index: h,
232
233
  reason: a,
233
234
  event: t
@@ -238,26 +239,26 @@ function oo(n) {
238
239
  const I = P(m[h]);
239
240
  b.current.value = I, I.toLowerCase().indexOf(d.toLowerCase()) === 0 && d.length > 0 && b.current.setSelectionRange(d.length, I.length);
240
241
  }
241
- }), ze = !At({
242
+ }), He = !At({
242
243
  array1: z.filteredOptions,
243
244
  array2: m,
244
245
  parser: P
245
246
  }), Ze = () => {
246
247
  const t = (e, r) => {
247
- const a = e ? P(e) : "", i = r ? P(r) : "";
248
- return a === i;
248
+ const a = e ? P(e) : "", l = r ? P(r) : "";
249
+ return a === l;
249
250
  };
250
251
  if (T.current !== -1 && !At({
251
252
  array1: z.filteredOptions,
252
253
  array2: m,
253
254
  parser: P
254
- }) && z.inputValue === d && (u ? l.length === z.value.length && z.value.every((e, r) => P(l[r]) === P(e)) : t(z.value, l))) {
255
+ }) && z.inputValue === d && (u ? i.length === z.value.length && z.value.every((e, r) => P(i[r]) === P(e)) : t(z.value, i))) {
255
256
  const e = z.filteredOptions[T.current];
256
257
  if (e)
257
258
  return m.findIndex((r) => P(r) === P(e));
258
259
  }
259
260
  return -1;
260
- }, Te = y.useCallback(() => {
261
+ }, Ae = y.useCallback(() => {
261
262
  if (!w)
262
263
  return;
263
264
  const t = Ze();
@@ -265,33 +266,33 @@ function oo(n) {
265
266
  T.current = t;
266
267
  return;
267
268
  }
268
- const e = u ? l[0] : l;
269
+ const e = u ? i[0] : i;
269
270
  if (m.length === 0 || e == null) {
270
271
  j({
271
272
  diff: "reset"
272
273
  });
273
274
  return;
274
275
  }
275
- if (M.current) {
276
+ if (V.current) {
276
277
  if (e != null) {
277
278
  const r = m[T.current];
278
- if (u && r && l.findIndex((i) => Q(r, i)) !== -1)
279
+ if (u && r && i.findIndex((l) => ee(r, l)) !== -1)
279
280
  return;
280
- const a = m.findIndex((i) => Q(i, e));
281
+ const a = m.findIndex((l) => ee(l, e));
281
282
  a === -1 ? j({
282
283
  diff: "reset"
283
- }) : _({
284
+ }) : X({
284
285
  index: a
285
286
  });
286
287
  return;
287
288
  }
288
289
  if (T.current >= m.length - 1) {
289
- _({
290
+ X({
290
291
  index: m.length - 1
291
292
  });
292
293
  return;
293
294
  }
294
- _({
295
+ X({
295
296
  index: T.current
296
297
  });
297
298
  }
@@ -300,75 +301,75 @@ function oo(n) {
300
301
  m.length,
301
302
  // Don't sync the highlighted index with the value when multiple
302
303
  // eslint-disable-next-line react-hooks/exhaustive-deps
303
- u ? !1 : l,
304
+ u ? !1 : i,
304
305
  j,
305
- _,
306
+ X,
306
307
  w,
307
308
  d,
308
309
  u
309
- ]), ee = We((t) => {
310
- qt(M, t), t && Te();
310
+ ]), te = Ue((t) => {
311
+ qt(V, t), t && Ae();
311
312
  });
312
313
  process.env.NODE_ENV !== "production" && y.useEffect(() => {
313
314
  (!b.current || b.current.nodeName !== "INPUT") && (b.current && b.current.nodeName === "TEXTAREA" ? console.warn([`A textarea element was provided to ${O} where input was expected.`, "This is not a supported scenario but it may work under certain conditions.", "A textarea keyboard navigation may conflict with Autocomplete controls (for example enter and arrow keys).", "Make sure to test keyboard navigation and add custom event handlers if necessary."].join(`
314
315
  `)) : console.error([`MUI: Unable to find the input element. It was resolved to ${b.current} while an HTMLInputElement was expected.`, `Instead, ${O} expects an input element.`, "", O === "useAutocomplete" ? "Make sure you have bound getInputProps correctly and that the normal ref/effect resolutions order is guaranteed." : "Make sure you have customized the input component correctly."].join(`
315
316
  `)));
316
317
  }, [O]), y.useEffect(() => {
317
- (ze || w) && Te();
318
- }, [Te, ze, w]);
319
- const J = (t) => {
320
- q || (ie(!0), me(!0), Ne && Ne(t));
321
- }, se = (t, e) => {
322
- q && (ie(!1), Je && Je(t, e));
323
- }, X = (t, e, r, a) => {
318
+ (He || w) && Ae();
319
+ }, [Ae, He, w]);
320
+ const Y = (t) => {
321
+ J || (se(!0), me(!0), Ee && Ee(t));
322
+ }, pe = (t, e) => {
323
+ J && (se(!1), _e && _e(t, e));
324
+ }, B = (t, e, r, a) => {
324
325
  if (u) {
325
- if (l.length === e.length && l.every((i, h) => i === e[h]))
326
+ if (i.length === e.length && i.every((l, h) => l === e[h]))
326
327
  return;
327
- } else if (l === e)
328
+ } else if (i === e)
328
329
  return;
329
- _e && _e(t, e, r, a), Ae(e);
330
- }, Y = y.useRef(!1), te = (t, e, r = "selectOption", a = "options") => {
331
- let i = r, h = e;
330
+ qe && qe(t, e, r, a), Ye(e);
331
+ }, Q = y.useRef(!1), oe = (t, e, r = "selectOption", a = "options") => {
332
+ let l = r, h = e;
332
333
  if (u) {
333
- if (h = Array.isArray(l) ? l.slice() : [], process.env.NODE_ENV !== "production") {
334
- const D = h.filter((Ie) => Q(e, Ie));
334
+ if (h = Array.isArray(i) ? i.slice() : [], process.env.NODE_ENV !== "production") {
335
+ const D = h.filter((Ie) => ee(e, Ie));
335
336
  D.length > 1 && console.error([`MUI: The \`isOptionEqualToValue\` method of ${O} does not handle the arguments correctly.`, `The component expects a single value to match a given option but found ${D.length} matches.`].join(`
336
337
  `));
337
338
  }
338
- const I = h.findIndex((D) => Q(e, D));
339
- I === -1 ? h.push(e) : a !== "freeSolo" && (h.splice(I, 1), i = "removeOption");
339
+ const I = h.findIndex((D) => ee(e, D));
340
+ I === -1 ? h.push(e) : a !== "freeSolo" && (h.splice(I, 1), l = "removeOption");
340
341
  }
341
- ge(t, h, i), X(t, h, i, {
342
+ ge(t, h, l), B(t, h, l, {
342
343
  option: e
343
- }), !ce && (!t || !t.ctrlKey && !t.metaKey) && se(t, i), (N === !0 || N === "touch" && Y.current || N === "mouse" && !Y.current) && b.current.blur();
344
+ }), !de && (!t || !t.ctrlKey && !t.metaKey) && pe(t, l), (N === !0 || N === "touch" && Q.current || N === "mouse" && !Q.current) && b.current.blur();
344
345
  };
345
346
  function et(t, e) {
346
347
  if (t === -1)
347
348
  return -1;
348
349
  let r = t;
349
350
  for (; ; ) {
350
- if (e === "next" && r === l.length || e === "previous" && r === -1)
351
+ if (e === "next" && r === i.length || e === "previous" && r === -1)
351
352
  return -1;
352
- const a = L ? "data-item-index" : "data-tag-index", i = $e.querySelector(`[${a}="${r}"]`);
353
- if (!i || !i.hasAttribute("tabindex") || i.disabled || i.getAttribute("aria-disabled") === "true")
353
+ const a = L ? "data-item-index" : "data-tag-index", l = $e.querySelector(`[${a}="${r}"]`);
354
+ if (!l || !l.hasAttribute("tabindex") || l.disabled || l.getAttribute("aria-disabled") === "true")
354
355
  r += e === "next" ? 1 : -1;
355
356
  else
356
357
  return r;
357
358
  }
358
359
  }
359
- const pe = (t, e) => {
360
+ const ue = (t, e) => {
360
361
  if (!u)
361
362
  return;
362
- d === "" && se(t, "toggleInput");
363
+ d === "" && pe(t, "toggleInput");
363
364
  let r = k;
364
- k === -1 ? d === "" && e === "previous" && (r = l.length - 1) : (r += e === "next" ? 1 : -1, r < 0 && (r = 0), r === l.length && (r = -1)), r = et(r, e), K(r), V(r);
365
- }, je = (t) => {
366
- Pe.current = !0, le(""), Z && Z(t, "", "clear"), X(t, u ? [] : null, "clear");
365
+ k === -1 && e === "previous" ? (r = i.length - 1, Z && d !== "" && (_(""), M && M(t, "", "reset"))) : (r += e === "next" ? 1 : -1, r < 0 && (r = 0), r === i.length && (r = -1)), r = et(r, e), le(r), K(r);
366
+ }, ze = (t) => {
367
+ Pe.current = !0, _(""), M && M(t, "", "clear"), B(t, u ? [] : null, "clear");
367
368
  }, tt = (t) => (e) => {
368
- if (t.onKeyDown && t.onKeyDown(e), !e.defaultMuiPrevented && (k !== -1 && !["ArrowLeft", "ArrowRight"].includes(e.key) && (K(-1), V(-1)), e.which !== 229))
369
+ if (t.onKeyDown && t.onKeyDown(e), !e.defaultMuiPrevented && (k !== -1 && !["ArrowLeft", "ArrowRight"].includes(e.key) && (le(-1), K(-1)), e.which !== 229))
369
370
  switch (e.key) {
370
371
  case "Home":
371
- w && qe && (e.preventDefault(), j({
372
+ w && Ke && (e.preventDefault(), j({
372
373
  diff: "start",
373
374
  direction: "next",
374
375
  reason: "keyboard",
@@ -376,7 +377,7 @@ function oo(n) {
376
377
  }));
377
378
  break;
378
379
  case "End":
379
- w && qe && (e.preventDefault(), j({
380
+ w && Ke && (e.preventDefault(), j({
380
381
  diff: "end",
381
382
  direction: "previous",
382
383
  reason: "keyboard",
@@ -389,7 +390,7 @@ function oo(n) {
389
390
  direction: "previous",
390
391
  reason: "keyboard",
391
392
  event: e
392
- }), J(e);
393
+ }), Y(e);
393
394
  break;
394
395
  case "PageDown":
395
396
  e.preventDefault(), j({
@@ -397,7 +398,7 @@ function oo(n) {
397
398
  direction: "next",
398
399
  reason: "keyboard",
399
400
  event: e
400
- }), J(e);
401
+ }), Y(e);
401
402
  break;
402
403
  case "ArrowDown":
403
404
  e.preventDefault(), j({
@@ -405,7 +406,7 @@ function oo(n) {
405
406
  direction: "next",
406
407
  reason: "keyboard",
407
408
  event: e
408
- }), J(e);
409
+ }), Y(e);
409
410
  break;
410
411
  case "ArrowUp":
411
412
  e.preventDefault(), j({
@@ -413,100 +414,108 @@ function oo(n) {
413
414
  direction: "previous",
414
415
  reason: "keyboard",
415
416
  event: e
416
- }), J(e);
417
+ }), Y(e);
417
418
  break;
418
- case "ArrowLeft":
419
- !u && L && l != null ? (K(0), V(0)) : pe(e, "previous");
419
+ case "ArrowLeft": {
420
+ const r = b.current;
421
+ if (!(r && r.selectionStart === 0 && r.selectionEnd === 0))
422
+ return;
423
+ !u && L && i != null ? (Z && d !== "" && (_(""), M && M(e, "", "reset")), le(0), K(0)) : ue(e, "previous");
420
424
  break;
425
+ }
421
426
  case "ArrowRight":
422
- !u && L ? (K(-1), V(-1)) : pe(e, "next");
427
+ !u && L ? (le(-1), K(-1)) : ue(e, "next");
423
428
  break;
424
429
  case "Enter":
425
430
  if (T.current !== -1 && w) {
426
- const r = m[T.current], a = W ? W(r) : !1;
431
+ const r = m[T.current], a = G ? G(r) : !1;
427
432
  if (e.preventDefault(), a)
428
433
  return;
429
- te(e, r, "selectOption"), f && b.current.setSelectionRange(b.current.value.length, b.current.value.length);
430
- } else de && d !== "" && Fe === !1 && (u && e.preventDefault(), te(e, d, "createOption", "freeSolo"));
434
+ oe(e, r, "selectOption"), f && b.current.setSelectionRange(b.current.value.length, b.current.value.length);
435
+ } else Z && d !== "" && Ve === !1 && (u && e.preventDefault(), oe(e, d, "createOption", "freeSolo"));
431
436
  break;
432
437
  case "Escape":
433
- w ? (e.preventDefault(), e.stopPropagation(), se(e, "escape")) : U && (d !== "" || u && l.length > 0 || L) && (e.preventDefault(), e.stopPropagation(), je(e));
438
+ w ? (e.preventDefault(), e.stopPropagation(), pe(e, "escape")) : W && (d !== "" || u && i.length > 0 || L) && (e.preventDefault(), e.stopPropagation(), ze(e));
434
439
  break;
435
440
  case "Backspace":
436
- if (u && !G && d === "" && l.length > 0) {
437
- const r = k === -1 ? l.length - 1 : k, a = l.slice();
438
- a.splice(r, 1), X(e, a, "removeOption", {
439
- option: l[r]
441
+ if (u && !q && d === "" && i.length > 0) {
442
+ const r = k === -1 ? i.length - 1 : k, a = i.slice();
443
+ a.splice(r, 1), B(e, a, "removeOption", {
444
+ option: i[r]
440
445
  });
441
446
  }
442
- !u && L && !G && (Ae(null), K(-1), V(-1));
447
+ !u && L && !q && d === "" && B(e, null, "removeOption", {
448
+ option: i
449
+ });
443
450
  break;
444
451
  case "Delete":
445
- if (u && !G && d === "" && l.length > 0 && k !== -1) {
446
- const r = k, a = l.slice();
447
- a.splice(r, 1), X(e, a, "removeOption", {
448
- option: l[r]
452
+ if (u && !q && d === "" && i.length > 0 && k !== -1) {
453
+ const r = k, a = i.slice();
454
+ a.splice(r, 1), B(e, a, "removeOption", {
455
+ option: i[r]
449
456
  });
450
457
  }
451
- !u && L && !G && (Ae(null), K(-1), V(-1));
458
+ !u && L && !q && d === "" && B(e, null, "removeOption", {
459
+ option: i
460
+ });
452
461
  break;
453
462
  }
454
463
  }, he = (t) => {
455
- Ve(!0), k !== -1 && (K(-1), V(-1)), mt && !Pe.current && J(t);
464
+ Me(!0), k !== -1 && (le(-1), K(-1)), mt && !Pe.current && Y(t);
456
465
  }, be = (t) => {
457
- if (p(M)) {
466
+ if (p(V)) {
458
467
  b.current.focus();
459
468
  return;
460
469
  }
461
- Ve(!1), Ce.current = !0, Pe.current = !1, F && T.current !== -1 && w ? te(t, m[T.current], "blur") : F && de && d !== "" ? te(t, d, "blur", "freeSolo") : R && ge(t, l, "blur"), se(t, "blur");
462
- }, we = (t) => {
470
+ Me(!1), Ce.current = !0, Pe.current = !1, F && T.current !== -1 && w ? oe(t, m[T.current], "blur") : F && Z && d !== "" ? oe(t, d, "blur", "freeSolo") : R && ge(t, i, "blur"), pe(t, "blur");
471
+ }, Te = (t) => {
463
472
  const e = t.target.value;
464
- d !== e && (le(e), me(!1), Z && Z(t, e, "input")), e === "" ? !H && !u && X(t, null, "clear") : J(t);
473
+ d !== e && (_(e), me(!1), M && M(t, e, "input")), e === "" ? !H && !u && !L && B(t, null, "clear") : Y(t);
465
474
  }, ot = (t) => {
466
475
  const e = Number(t.currentTarget.getAttribute("data-option-index"));
467
- T.current !== e && _({
476
+ T.current !== e && X({
468
477
  event: t,
469
478
  index: e,
470
479
  reason: "mouse"
471
480
  });
472
481
  }, nt = (t) => {
473
- _({
482
+ X({
474
483
  event: t,
475
484
  index: Number(t.currentTarget.getAttribute("data-option-index")),
476
485
  reason: "touch"
477
- }), Y.current = !0;
486
+ }), Q.current = !0;
478
487
  }, rt = (t) => {
479
488
  const e = Number(t.currentTarget.getAttribute("data-option-index"));
480
- te(t, m[e], "selectOption"), Y.current = !1;
489
+ oe(t, m[e], "selectOption"), Q.current = !1;
481
490
  }, at = (t) => (e) => {
482
- const r = l.slice();
483
- r.splice(t, 1), X(e, r, "removeOption", {
484
- option: l[t]
491
+ const r = i.slice();
492
+ r.splice(t, 1), B(e, r, "removeOption", {
493
+ option: i[t]
485
494
  });
486
- }, Se = (t) => {
487
- X(t, null, "removeOption", {
488
- option: l
495
+ }, we = (t) => {
496
+ B(t, null, "removeOption", {
497
+ option: i
489
498
  });
490
499
  }, x = (t) => {
491
- q ? se(t, "toggleInput") : J(t);
500
+ J ? pe(t, "toggleInput") : Y(t);
492
501
  }, C = (t) => {
493
502
  t.currentTarget.contains(t.target) && t.target.getAttribute("id") !== E && t.preventDefault();
494
- }, oe = (t) => {
495
- t.currentTarget.contains(t.target) && (b.current.focus(), Xe && Ce.current && b.current.selectionEnd - b.current.selectionStart === 0 && b.current.select(), Ce.current = !1);
496
- }, lt = (t) => {
497
- !v && (d === "" || !q) && x(t);
503
+ }, ne = (t) => {
504
+ t.currentTarget.contains(t.target) && (b.current.focus(), Je && Ce.current && b.current.selectionEnd - b.current.selectionStart === 0 && b.current.select(), Ce.current = !1);
505
+ }, it = (t) => {
506
+ !v && (d === "" || !J) && x(t);
498
507
  };
499
- let ve = de && d.length > 0;
500
- ve = ve || (u ? l.length > 0 : l !== null);
501
- let Be = m;
502
- if (ae) {
508
+ let Se = Z && d.length > 0;
509
+ Se = Se || (u ? i.length > 0 : i !== null);
510
+ let je = m;
511
+ if (ie) {
503
512
  const t = /* @__PURE__ */ new Map();
504
513
  let e = !1;
505
- Be = m.reduce((r, a, i) => {
506
- const h = ae(a);
514
+ je = m.reduce((r, a, l) => {
515
+ const h = ie(a);
507
516
  return r.length > 0 && r[r.length - 1].group === h ? r[r.length - 1].options.push(a) : (process.env.NODE_ENV !== "production" && (t.get(h) && !e && (console.warn(`MUI: The options provided combined with the \`groupBy\` method of ${O} returns duplicated headers.`, "You can solve the issue by sorting the options with the output of `groupBy`."), e = !0), t.set(h, !0)), r.push({
508
- key: i,
509
- index: i,
517
+ key: l,
518
+ index: l,
510
519
  group: h,
511
520
  options: [a]
512
521
  })), r;
@@ -517,7 +526,7 @@ function oo(n) {
517
526
  ...t,
518
527
  onKeyDown: tt(t),
519
528
  onMouseDown: C,
520
- onClick: oe
529
+ onClick: ne
521
530
  }),
522
531
  getInputLabelProps: () => ({
523
532
  id: `${E}-label`,
@@ -528,14 +537,14 @@ function oo(n) {
528
537
  value: d,
529
538
  onBlur: be,
530
539
  onFocus: he,
531
- onChange: we,
532
- onMouseDown: lt,
540
+ onChange: Te,
541
+ onMouseDown: it,
533
542
  // if open then this is handled imperatively so don't let react override
534
543
  // only have an opinion about this when closed
535
544
  "aria-activedescendant": w ? "" : null,
536
545
  "aria-autocomplete": f ? "both" : "list",
537
- "aria-controls": He ? `${E}-listbox` : void 0,
538
- "aria-expanded": He,
546
+ "aria-controls": Fe ? `${E}-listbox` : void 0,
547
+ "aria-expanded": Fe,
539
548
  // Disable browser's suggestion that might overlap with the popup.
540
549
  // Handle autocomplete but not autofill.
541
550
  autoComplete: "off",
@@ -548,7 +557,7 @@ function oo(n) {
548
557
  getClearProps: () => ({
549
558
  tabIndex: -1,
550
559
  type: "button",
551
- onClick: je
560
+ onClick: ze
552
561
  }),
553
562
  getItemProps: ({
554
563
  index: t = 0
@@ -562,8 +571,8 @@ function oo(n) {
562
571
  "data-tag-index": t
563
572
  },
564
573
  tabIndex: -1,
565
- ...!G && {
566
- onDelete: u ? at(t) : Se
574
+ ...!q && {
575
+ onDelete: u ? at(t) : we
567
576
  }
568
577
  }),
569
578
  getPopupIndicatorProps: () => ({
@@ -578,7 +587,7 @@ function oo(n) {
578
587
  key: t,
579
588
  "data-tag-index": t,
580
589
  tabIndex: -1,
581
- ...!G && {
590
+ ...!q && {
582
591
  onDelete: at(t)
583
592
  }
584
593
  }),
@@ -586,7 +595,7 @@ function oo(n) {
586
595
  role: "listbox",
587
596
  id: `${E}-listbox`,
588
597
  "aria-labelledby": `${E}-label`,
589
- ref: ee,
598
+ ref: te,
590
599
  onMouseDown: (t) => {
591
600
  t.preventDefault();
592
601
  }
@@ -595,7 +604,7 @@ function oo(n) {
595
604
  index: t,
596
605
  option: e
597
606
  }) => {
598
- const r = (u ? l : [l]).some((i) => i != null && Q(e, i)), a = W ? W(e) : !1;
607
+ const r = (u ? i : [i]).some((l) => l != null && ee(e, l)), a = G ? G(e) : !1;
599
608
  return {
600
609
  key: dt?.(e) ?? P(e),
601
610
  tabIndex: -1,
@@ -611,8 +620,8 @@ function oo(n) {
611
620
  },
612
621
  id: E,
613
622
  inputValue: d,
614
- value: l,
615
- dirty: ve,
623
+ value: i,
624
+ dirty: Se,
616
625
  expanded: w && $e,
617
626
  popupOpen: w,
618
627
  focused: fe || k !== -1,
@@ -621,7 +630,7 @@ function oo(n) {
621
630
  focusedItem: k,
622
631
  // deprecated
623
632
  focusedTag: k,
624
- groupedOptions: Be
633
+ groupedOptions: je
625
634
  };
626
635
  }
627
636
  function no(n) {
@@ -638,13 +647,13 @@ const ro = (n) => {
638
647
  fullWidth: F,
639
648
  hasClearIcon: N,
640
649
  hasPopupIcon: R,
641
- inputFocused: U,
650
+ inputFocused: W,
642
651
  popupOpen: O,
643
652
  size: A
644
653
  } = n, H = {
645
654
  root: ["root", f && "expanded", S && "focused", F && "fullWidth", N && "hasClearIcon", R && "hasPopupIcon"],
646
655
  inputRoot: ["inputRoot"],
647
- input: ["input", U && "inputFocused"],
656
+ input: ["input", W && "inputFocused"],
648
657
  tag: ["tag", `tagSize${Et(A)}`],
649
658
  endAdornment: ["endAdornment"],
650
659
  clearIndicator: ["clearIndicator"],
@@ -659,7 +668,7 @@ const ro = (n) => {
659
668
  groupUl: ["groupUl"]
660
669
  };
661
670
  return Jt(H, no, p);
662
- }, ao = B("div", {
671
+ }, ao = U("div", {
663
672
  name: "MuiAutocomplete",
664
673
  slot: "Root",
665
674
  overridesResolver: (n, p) => {
@@ -716,7 +725,7 @@ const ro = (n) => {
716
725
  padding: "4px 4px 4px 0px"
717
726
  }
718
727
  },
719
- [`& .${st.root}.${ue.sizeSmall}`]: {
728
+ [`& .${st.root}.${ce.sizeSmall}`]: {
720
729
  [`& .${st.input}`]: {
721
730
  padding: "2px 4px 3px 0"
722
731
  }
@@ -736,7 +745,7 @@ const ro = (n) => {
736
745
  right: 9
737
746
  }
738
747
  },
739
- [`& .${Ct.root}.${ue.sizeSmall}`]: {
748
+ [`& .${Ct.root}.${ce.sizeSmall}`]: {
740
749
  // Don't specify paddingRight, as it overrides the default value set when there is only
741
750
  // one of the popup or clear icon as the specificity is equal so the latter one wins
742
751
  paddingTop: 6,
@@ -762,16 +771,16 @@ const ro = (n) => {
762
771
  right: 9
763
772
  }
764
773
  },
765
- [`& .${xe.root}.${ue.sizeSmall}`]: {
774
+ [`& .${xe.root}.${ce.sizeSmall}`]: {
766
775
  paddingBottom: 1,
767
776
  [`& .${xe.input}`]: {
768
777
  padding: "2.5px 4px"
769
778
  }
770
779
  },
771
- [`& .${ue.hiddenLabel}`]: {
780
+ [`& .${ce.hiddenLabel}`]: {
772
781
  paddingTop: 8
773
782
  },
774
- [`& .${xe.root}.${ue.hiddenLabel}`]: {
783
+ [`& .${xe.root}.${ce.hiddenLabel}`]: {
775
784
  paddingTop: 0,
776
785
  paddingBottom: 0,
777
786
  [`& .${s.input}`]: {
@@ -779,7 +788,7 @@ const ro = (n) => {
779
788
  paddingBottom: 17
780
789
  }
781
790
  },
782
- [`& .${xe.root}.${ue.hiddenLabel}.${ue.sizeSmall}`]: {
791
+ [`& .${xe.root}.${ce.hiddenLabel}.${ce.sizeSmall}`]: {
783
792
  [`& .${s.input}`]: {
784
793
  paddingTop: 8,
785
794
  paddingBottom: 9
@@ -826,7 +835,7 @@ const ro = (n) => {
826
835
  }
827
836
  }
828
837
  }]
829
- }), lo = B("div", {
838
+ }), io = U("div", {
830
839
  name: "MuiAutocomplete",
831
840
  slot: "EndAdornment"
832
841
  })({
@@ -835,14 +844,14 @@ const ro = (n) => {
835
844
  right: 0,
836
845
  top: "50%",
837
846
  transform: "translate(0, -50%)"
838
- }), io = B(Nt, {
847
+ }), lo = U(Nt, {
839
848
  name: "MuiAutocomplete",
840
849
  slot: "ClearIndicator"
841
850
  })({
842
851
  marginRight: -2,
843
852
  padding: 4,
844
853
  visibility: "hidden"
845
- }), so = B(Nt, {
854
+ }), so = U(Nt, {
846
855
  name: "MuiAutocomplete",
847
856
  slot: "PopupIndicator",
848
857
  overridesResolver: (n, p) => {
@@ -862,7 +871,7 @@ const ro = (n) => {
862
871
  transform: "rotate(180deg)"
863
872
  }
864
873
  }]
865
- }), po = B(Rt, {
874
+ }), po = U(Rt, {
866
875
  name: "MuiAutocomplete",
867
876
  slot: "Popper",
868
877
  overridesResolver: (n, p) => {
@@ -885,7 +894,7 @@ const ro = (n) => {
885
894
  position: "absolute"
886
895
  }
887
896
  }]
888
- }))), uo = B(Dt, {
897
+ }))), uo = U(Dt, {
889
898
  name: "MuiAutocomplete",
890
899
  slot: "Paper"
891
900
  })(ye(({
@@ -893,7 +902,7 @@ const ro = (n) => {
893
902
  }) => ({
894
903
  ...n.typography.body1,
895
904
  overflow: "auto"
896
- }))), co = B("div", {
905
+ }))), co = U("div", {
897
906
  name: "MuiAutocomplete",
898
907
  slot: "Loading"
899
908
  })(ye(({
@@ -901,7 +910,7 @@ const ro = (n) => {
901
910
  }) => ({
902
911
  color: (n.vars || n).palette.text.secondary,
903
912
  padding: "14px 16px"
904
- }))), fo = B("div", {
913
+ }))), fo = U("div", {
905
914
  name: "MuiAutocomplete",
906
915
  slot: "NoOptions"
907
916
  })(ye(({
@@ -909,7 +918,7 @@ const ro = (n) => {
909
918
  }) => ({
910
919
  color: (n.vars || n).palette.text.secondary,
911
920
  padding: "14px 16px"
912
- }))), go = B("ul", {
921
+ }))), go = U("ul", {
913
922
  name: "MuiAutocomplete",
914
923
  slot: "Listbox"
915
924
  })(ye(({
@@ -966,7 +975,7 @@ const ro = (n) => {
966
975
  }
967
976
  }
968
977
  }
969
- }))), mo = B(Xt, {
978
+ }))), mo = U(Xt, {
970
979
  name: "MuiAutocomplete",
971
980
  slot: "GroupLabel"
972
981
  })(ye(({
@@ -974,7 +983,7 @@ const ro = (n) => {
974
983
  }) => ({
975
984
  backgroundColor: (n.vars || n).palette.background.paper,
976
985
  top: -8
977
- }))), ho = B("ul", {
986
+ }))), ho = U("ul", {
978
987
  name: "MuiAutocomplete",
979
988
  slot: "GroupUl"
980
989
  })({
@@ -991,175 +1000,175 @@ const ro = (n) => {
991
1000
  autoHighlight: F = !1,
992
1001
  autoSelect: N = !1,
993
1002
  blurOnSelect: R = !1,
994
- ChipProps: U,
1003
+ ChipProps: W,
995
1004
  className: O,
996
1005
  clearIcon: A = vt || (vt = /* @__PURE__ */ $(Bt, {
997
1006
  fontSize: "small"
998
1007
  })),
999
1008
  clearOnBlur: H = !f.freeSolo,
1000
- clearOnEscape: ce = !1,
1009
+ clearOnEscape: de = !1,
1001
1010
  clearText: v = "Clear",
1002
- closeText: ke = "Close",
1003
- componentsProps: De,
1011
+ closeText: Le = "Close",
1012
+ componentsProps: ke,
1004
1013
  defaultValue: ct = f.multiple ? [] : null,
1005
- disableClearable: Ge = !1,
1006
- disableCloseOnSelect: de = !1,
1007
- disabled: W = !1,
1014
+ disableClearable: We = !1,
1015
+ disableCloseOnSelect: Z = !1,
1016
+ disabled: G = !1,
1008
1017
  disabledItemsFocusable: dt = !1,
1009
- disableListWrap: Ke = !1,
1010
- disablePortal: ae = !1,
1011
- filterOptions: qe,
1018
+ disableListWrap: Ge = !1,
1019
+ disablePortal: ie = !1,
1020
+ filterOptions: Ke,
1012
1021
  filterSelectedOptions: ft = !1,
1013
1022
  forcePopupIcon: Oe = "auto",
1014
- freeSolo: Re = !1,
1015
- fullWidth: Q = !1,
1023
+ freeSolo: De = !1,
1024
+ fullWidth: ee = !1,
1016
1025
  getLimitTagsText: u = (c) => `+${c}`,
1017
- getOptionDisabled: _e,
1018
- getOptionKey: Je,
1019
- getOptionLabel: Ee,
1020
- isOptionEqualToValue: Z,
1021
- groupBy: Ne,
1026
+ getOptionDisabled: qe,
1027
+ getOptionKey: _e,
1028
+ getOptionLabel: Re,
1029
+ isOptionEqualToValue: M,
1030
+ groupBy: Ee,
1022
1031
  handleHomeEndKeys: gt = !f.freeSolo,
1023
1032
  id: mt,
1024
1033
  includeInputInList: ht = !1,
1025
- inputValue: G,
1034
+ inputValue: q,
1026
1035
  limitTags: L = -1,
1027
- ListboxComponent: Xe,
1028
- ListboxProps: Me,
1036
+ ListboxComponent: Je,
1037
+ ListboxProps: Ne,
1029
1038
  loading: E = !1,
1030
1039
  loadingText: P = "Loading…",
1031
1040
  multiple: Pe = !1,
1032
1041
  noOptionsText: Ce = "No options",
1033
1042
  onChange: b,
1034
- onClose: M,
1043
+ onClose: V,
1035
1044
  onHighlightChange: $e,
1036
1045
  onInputChange: bt,
1037
1046
  onOpen: k,
1038
- open: K,
1039
- openOnFocus: Ye = !1,
1047
+ open: le,
1048
+ openOnFocus: Xe = !1,
1040
1049
  openText: T = "Open",
1041
1050
  options: It,
1042
- PaperComponent: l,
1043
- PopperComponent: Ae,
1051
+ PaperComponent: i,
1052
+ PopperComponent: Ye,
1044
1053
  popupIcon: d = Lt || (Lt = /* @__PURE__ */ $(jt, {})),
1045
- readOnly: le = !1,
1054
+ readOnly: _ = !1,
1046
1055
  renderGroup: fe,
1047
- renderInput: Ve,
1056
+ renderInput: Me,
1048
1057
  renderOption: ge,
1049
- renderTags: q,
1050
- renderValue: ie,
1058
+ renderTags: J,
1059
+ renderValue: se,
1051
1060
  selectOnFocus: xt = !f.freeSolo,
1052
1061
  size: me = "medium",
1053
- slots: Fe = {},
1062
+ slots: Ve = {},
1054
1063
  slotProps: w = {},
1055
1064
  value: m,
1056
1065
  ...z
1057
1066
  } = f, {
1058
- getRootProps: He,
1059
- getInputProps: V,
1067
+ getRootProps: Fe,
1068
+ getInputProps: K,
1060
1069
  getInputLabelProps: Qe,
1061
- getPopupIndicatorProps: _,
1070
+ getPopupIndicatorProps: X,
1062
1071
  getClearProps: j,
1063
- getItemProps: ze,
1072
+ getItemProps: He,
1064
1073
  getListboxProps: Ze,
1065
- getOptionProps: Te,
1066
- value: ee,
1067
- dirty: J,
1068
- expanded: se,
1069
- id: X,
1070
- popupOpen: Y,
1071
- focused: te,
1074
+ getOptionProps: Ae,
1075
+ value: te,
1076
+ dirty: Y,
1077
+ expanded: pe,
1078
+ id: B,
1079
+ popupOpen: Q,
1080
+ focused: oe,
1072
1081
  focusedItem: et,
1073
- anchorEl: pe,
1074
- setAnchorEl: je,
1082
+ anchorEl: ue,
1083
+ setAnchorEl: ze,
1075
1084
  inputValue: tt,
1076
1085
  groupedOptions: he
1077
1086
  } = oo({
1078
1087
  ...f,
1079
1088
  componentName: "Autocomplete"
1080
- }), be = !Ge && !W && J && !le, we = (!Re || Oe === !0) && Oe !== !1, {
1089
+ }), be = !We && !G && Y && !_, Te = (!De || Oe === !0) && Oe !== !1, {
1081
1090
  onMouseDown: ot
1082
- } = V(), {
1091
+ } = K(), {
1083
1092
  ref: nt,
1084
1093
  ...rt
1085
- } = Ze(), Se = Ee || ((c) => c.label ?? c), x = {
1094
+ } = Ze(), we = Re || ((c) => c.label ?? c), x = {
1086
1095
  ...f,
1087
- disablePortal: ae,
1088
- expanded: se,
1089
- focused: te,
1090
- fullWidth: Q,
1091
- getOptionLabel: Se,
1096
+ disablePortal: ie,
1097
+ expanded: pe,
1098
+ focused: oe,
1099
+ fullWidth: ee,
1100
+ getOptionLabel: we,
1092
1101
  hasClearIcon: be,
1093
- hasPopupIcon: we,
1102
+ hasPopupIcon: Te,
1094
1103
  inputFocused: et === -1,
1095
- popupOpen: Y,
1104
+ popupOpen: Q,
1096
1105
  size: me
1097
- }, C = ro(x), oe = {
1106
+ }, C = ro(x), ne = {
1098
1107
  slots: {
1099
- paper: l,
1100
- popper: Ae,
1101
- ...Fe
1108
+ paper: i,
1109
+ popper: Ye,
1110
+ ...Ve
1102
1111
  },
1103
1112
  slotProps: {
1104
- chip: U,
1105
- listbox: Me,
1106
- ...De,
1113
+ chip: W,
1114
+ listbox: Ne,
1115
+ ...ke,
1107
1116
  ...w
1108
1117
  }
1109
- }, [lt, ve] = pt("listbox", {
1118
+ }, [it, Se] = pt("listbox", {
1110
1119
  elementType: go,
1111
- externalForwardedProps: oe,
1120
+ externalForwardedProps: ne,
1112
1121
  ownerState: x,
1113
1122
  className: C.listbox,
1114
1123
  additionalProps: rt,
1115
1124
  ref: nt
1116
- }), [Be, t] = pt("paper", {
1125
+ }), [je, t] = pt("paper", {
1117
1126
  elementType: Dt,
1118
- externalForwardedProps: oe,
1127
+ externalForwardedProps: ne,
1119
1128
  ownerState: x,
1120
1129
  className: C.paper
1121
1130
  }), [e, r] = pt("popper", {
1122
1131
  elementType: Rt,
1123
- externalForwardedProps: oe,
1132
+ externalForwardedProps: ne,
1124
1133
  ownerState: x,
1125
1134
  className: C.popper,
1126
1135
  additionalProps: {
1127
- disablePortal: ae,
1136
+ disablePortal: ie,
1128
1137
  style: {
1129
- width: pe ? pe.clientWidth : null
1138
+ width: ue ? ue.clientWidth : null
1130
1139
  },
1131
1140
  role: "presentation",
1132
- anchorEl: pe,
1133
- open: Y
1141
+ anchorEl: ue,
1142
+ open: Q
1134
1143
  }
1135
1144
  });
1136
1145
  let a;
1137
- const i = (c) => ({
1146
+ const l = (c) => ({
1138
1147
  className: C.tag,
1139
- disabled: W,
1140
- ...ze(c)
1148
+ disabled: G,
1149
+ ...He(c)
1141
1150
  });
1142
- if (Pe ? ee.length > 0 && (q ? a = q(ee, i, x) : ie ? a = ie(ee, i, x) : a = ee.map((c, ne) => {
1151
+ if (Pe ? te.length > 0 && (J ? a = J(te, l, x) : se ? a = se(te, l, x) : a = te.map((c, re) => {
1143
1152
  const {
1144
- key: re,
1145
- ...Le
1146
- } = i({
1147
- index: ne
1153
+ key: ae,
1154
+ ...ve
1155
+ } = l({
1156
+ index: re
1148
1157
  });
1149
1158
  return /* @__PURE__ */ $(_t, {
1150
- label: Se(c),
1159
+ label: we(c),
1151
1160
  size: me,
1152
- ...Le,
1153
- ...oe.slotProps.chip
1154
- }, re);
1155
- })) : ie && ee != null && (a = ie(ee, i, x)), L > -1 && Array.isArray(a)) {
1161
+ ...ve,
1162
+ ...ne.slotProps.chip
1163
+ }, ae);
1164
+ })) : se && te != null && (a = se(te, l, x)), L > -1 && Array.isArray(a)) {
1156
1165
  const c = a.length - L;
1157
- !te && c > 0 && (a = a.splice(0, L), a.push(/* @__PURE__ */ $("span", {
1166
+ !oe && c > 0 && (a = a.splice(0, L), a.push(/* @__PURE__ */ $("span", {
1158
1167
  className: C.tag,
1159
1168
  children: u(c)
1160
1169
  }, a.length)));
1161
1170
  }
1162
- const I = fe || ((c) => /* @__PURE__ */ Ue("li", {
1171
+ const I = fe || ((c) => /* @__PURE__ */ Be("li", {
1163
1172
  children: [/* @__PURE__ */ $(mo, {
1164
1173
  className: C.groupLabel,
1165
1174
  ownerState: x,
@@ -1170,68 +1179,68 @@ const ro = (n) => {
1170
1179
  ownerState: x,
1171
1180
  children: c.children
1172
1181
  })]
1173
- }, c.key)), Ie = ge || ((c, ne) => {
1182
+ }, c.key)), Ie = ge || ((c, re) => {
1174
1183
  const {
1175
- key: re,
1176
- ...Le
1184
+ key: ae,
1185
+ ...ve
1177
1186
  } = c;
1178
1187
  return /* @__PURE__ */ $("li", {
1179
- ...Le,
1180
- children: Se(ne)
1181
- }, re);
1182
- }), yt = (c, ne) => {
1183
- const re = Te({
1188
+ ...ve,
1189
+ children: we(re)
1190
+ }, ae);
1191
+ }), yt = (c, re) => {
1192
+ const ae = Ae({
1184
1193
  option: c,
1185
- index: ne
1194
+ index: re
1186
1195
  });
1187
1196
  return Ie({
1188
- ...re,
1197
+ ...ae,
1189
1198
  className: C.option
1190
1199
  }, c, {
1191
- selected: re["aria-selected"],
1192
- index: ne,
1200
+ selected: ae["aria-selected"],
1201
+ index: re,
1193
1202
  inputValue: tt
1194
1203
  }, x);
1195
- }, Ot = oe.slotProps.clearIndicator, Pt = oe.slotProps.popupIndicator;
1196
- return /* @__PURE__ */ Ue(y.Fragment, {
1204
+ }, Ot = ne.slotProps.clearIndicator, Pt = ne.slotProps.popupIndicator;
1205
+ return /* @__PURE__ */ Be(y.Fragment, {
1197
1206
  children: [/* @__PURE__ */ $(ao, {
1198
1207
  ref: g,
1199
- className: it(C.root, O),
1208
+ className: lt(C.root, O),
1200
1209
  ownerState: x,
1201
- ...He(z),
1202
- children: Ve({
1203
- id: X,
1204
- disabled: W,
1210
+ ...Fe(z),
1211
+ children: Me({
1212
+ id: B,
1213
+ disabled: G,
1205
1214
  fullWidth: !0,
1206
1215
  size: me === "small" ? "small" : void 0,
1207
1216
  InputLabelProps: Qe(),
1208
1217
  InputProps: {
1209
- ref: je,
1218
+ ref: ze,
1210
1219
  className: C.inputRoot,
1211
1220
  startAdornment: a,
1212
1221
  onMouseDown: (c) => {
1213
1222
  c.target === c.currentTarget && ot(c);
1214
1223
  },
1215
- ...(be || we) && {
1216
- endAdornment: /* @__PURE__ */ Ue(lo, {
1224
+ ...(be || Te) && {
1225
+ endAdornment: /* @__PURE__ */ Be(io, {
1217
1226
  className: C.endAdornment,
1218
1227
  ownerState: x,
1219
- children: [be ? /* @__PURE__ */ $(io, {
1228
+ children: [be ? /* @__PURE__ */ $(lo, {
1220
1229
  ...j(),
1221
1230
  "aria-label": v,
1222
1231
  title: v,
1223
1232
  ownerState: x,
1224
1233
  ...Ot,
1225
- className: it(C.clearIndicator, Ot?.className),
1234
+ className: lt(C.clearIndicator, Ot?.className),
1226
1235
  children: A
1227
- }) : null, we ? /* @__PURE__ */ $(so, {
1228
- ..._(),
1229
- disabled: W,
1230
- "aria-label": Y ? ke : T,
1231
- title: Y ? ke : T,
1236
+ }) : null, Te ? /* @__PURE__ */ $(so, {
1237
+ ...X(),
1238
+ disabled: G,
1239
+ "aria-label": Q ? Le : T,
1240
+ title: Q ? Le : T,
1232
1241
  ownerState: x,
1233
1242
  ...Pt,
1234
- className: it(C.popupIndicator, Pt?.className),
1243
+ className: lt(C.popupIndicator, Pt?.className),
1235
1244
  children: d
1236
1245
  }) : null]
1237
1246
  })
@@ -1239,22 +1248,22 @@ const ro = (n) => {
1239
1248
  },
1240
1249
  inputProps: {
1241
1250
  className: C.input,
1242
- disabled: W,
1243
- readOnly: le,
1244
- ...V()
1251
+ disabled: G,
1252
+ readOnly: _,
1253
+ ...K()
1245
1254
  }
1246
1255
  })
1247
- }), pe ? /* @__PURE__ */ $(po, {
1256
+ }), ue ? /* @__PURE__ */ $(po, {
1248
1257
  as: e,
1249
1258
  ...r,
1250
- children: /* @__PURE__ */ Ue(uo, {
1251
- as: Be,
1259
+ children: /* @__PURE__ */ Be(uo, {
1260
+ as: je,
1252
1261
  ...t,
1253
1262
  children: [E && he.length === 0 ? /* @__PURE__ */ $(co, {
1254
1263
  className: C.loading,
1255
1264
  ownerState: x,
1256
1265
  children: P
1257
- }) : null, he.length === 0 && !Re && !E ? /* @__PURE__ */ $(fo, {
1266
+ }) : null, he.length === 0 && !De && !E ? /* @__PURE__ */ $(fo, {
1258
1267
  className: C.noOptions,
1259
1268
  ownerState: x,
1260
1269
  role: "presentation",
@@ -1262,14 +1271,14 @@ const ro = (n) => {
1262
1271
  c.preventDefault();
1263
1272
  },
1264
1273
  children: Ce
1265
- }) : null, he.length > 0 ? /* @__PURE__ */ $(lt, {
1266
- as: Xe,
1267
- ...ve,
1268
- children: he.map((c, ne) => Ne ? I({
1274
+ }) : null, he.length > 0 ? /* @__PURE__ */ $(it, {
1275
+ as: Je,
1276
+ ...Se,
1277
+ children: he.map((c, re) => Ee ? I({
1269
1278
  key: c.key,
1270
1279
  group: c.group,
1271
- children: c.options.map((re, Le) => yt(re, c.index + Le))
1272
- }) : yt(c, ne))
1280
+ children: c.options.map((ae, ve) => yt(ae, c.index + ve))
1281
+ }) : yt(c, re))
1273
1282
  }) : null]
1274
1283
  })
1275
1284
  }) : null]
@@ -1740,11 +1749,11 @@ function Io(n, p) {
1740
1749
  error: F,
1741
1750
  name: N,
1742
1751
  renderInput: R = (H) => {
1743
- const { ref: ce, ...v } = H.InputProps;
1752
+ const { ref: de, ...v } = H.InputProps;
1744
1753
  return /* @__PURE__ */ $(
1745
1754
  Ft,
1746
1755
  {
1747
- ref: ce,
1756
+ ref: de,
1748
1757
  ...v,
1749
1758
  inputProps: H.inputProps,
1750
1759
  inputRef: H.inputProps.ref,
@@ -1768,7 +1777,7 @@ function Io(n, p) {
1768
1777
  }
1769
1778
  );
1770
1779
  },
1771
- popupIcon: U = /* @__PURE__ */ $(Ht, {}),
1780
+ popupIcon: W = /* @__PURE__ */ $(Ht, {}),
1772
1781
  clearIcon: O = /* @__PURE__ */ $(zt, {}),
1773
1782
  ...A
1774
1783
  } = n;
@@ -1778,7 +1787,7 @@ function Io(n, p) {
1778
1787
  ref: p,
1779
1788
  ...A,
1780
1789
  renderInput: R,
1781
- popupIcon: U,
1790
+ popupIcon: W,
1782
1791
  clearIcon: O
1783
1792
  }
1784
1793
  );