@cgi-learning-hub/ui 0.0.1-dev.1709567324 → 0.0.1-dev.1709568003

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/Box-CjHm9A9L.cjs +1 -0
  2. package/dist/{Box-C0qXdJzV.js → Box-erN4AuKs.js} +8 -8
  3. package/dist/ButtonBase-BybMkBUd.cjs +75 -0
  4. package/dist/ButtonBase-CGcs8Gbj.cjs +75 -0
  5. package/dist/ButtonBase-V1pwsMMs.js +649 -0
  6. package/dist/ButtonBase-aujiNoUb.js +649 -0
  7. package/dist/DefaultButton-Cg4tPCgf.cjs +28 -0
  8. package/dist/{DefaultButton-B-2UppUm.js → DefaultButton-DbpZOb47.js} +355 -146
  9. package/dist/FileListItem-ChKTjDnV.js +254 -0
  10. package/dist/FileListItem-CjFIZgYg.cjs +28 -0
  11. package/dist/IconButton-CHXclgOn.cjs +2 -0
  12. package/dist/{IconButton-1URziYlU.js → IconButton-DE5JOshS.js} +8 -8
  13. package/dist/{InputBase-Dc0v-Ihf.js → InputBase-C8AzQJJ9.js} +161 -174
  14. package/dist/InputBase-D6eXzDaz.cjs +4 -0
  15. package/dist/LocalizationProvider-42pD7VmS.cjs +5 -0
  16. package/dist/{LocalizationProvider-BD64DNxF.js → LocalizationProvider-Cov62Xe0.js} +4 -3
  17. package/dist/Tabs-DiWeNGD4.js +1167 -0
  18. package/dist/Tabs-DoxP7EMA.cjs +4 -0
  19. package/dist/TextInput-BbSyyuvO.cjs +12 -0
  20. package/dist/{TextInput-DsSFDlNR.js → TextInput-DmMk4i-V.js} +1892 -1650
  21. package/dist/TimePicker-B5MjZCK0.cjs +89 -0
  22. package/dist/TimePicker-BmxG3a2D.js +28354 -0
  23. package/dist/TransitionGroup-COuDopJ-.js +188 -0
  24. package/dist/TransitionGroup-X90dkobW.cjs +1 -0
  25. package/dist/Typography-B90UzlQW.js +179 -0
  26. package/dist/Typography-KFjBz5Hm.cjs +1 -0
  27. package/dist/clamp-0LjYbpE_.cjs +23 -0
  28. package/dist/clamp-BGJvJ0FN.js +1641 -0
  29. package/dist/components/Dropzone/Dropzone.cjs.js +5 -5
  30. package/dist/components/Dropzone/Dropzone.es.js +12 -11
  31. package/dist/components/LocalizationProvider/LocalizationProvider.cjs.js +1 -1
  32. package/dist/components/LocalizationProvider/LocalizationProvider.es.js +1 -1
  33. package/dist/components/LocalizationProvider/index.cjs.js +1 -1
  34. package/dist/components/LocalizationProvider/index.es.js +1 -1
  35. package/dist/components/buttons/DefaultButton/DefaultButton.cjs.js +1 -1
  36. package/dist/components/buttons/DefaultButton/DefaultButton.es.js +3 -3
  37. package/dist/components/buttons/DefaultButton/DefaultButtonIcon.cjs.js +1 -1
  38. package/dist/components/buttons/DefaultButton/DefaultButtonIcon.es.js +6 -6
  39. package/dist/components/buttons/DefaultButton/index.cjs.js +1 -1
  40. package/dist/components/buttons/DefaultButton/index.es.js +1 -1
  41. package/dist/components/buttons/IconButton.stories.cjs.js +1 -1
  42. package/dist/components/buttons/IconButton.stories.es.js +10 -9
  43. package/dist/components/buttons/PrimaryButton/PrimaryButton.cjs.js +1 -1
  44. package/dist/components/buttons/PrimaryButton/PrimaryButton.es.js +2 -2
  45. package/dist/components/buttons/PrimaryButton/PrimaryButton.stories.cjs.js +1 -1
  46. package/dist/components/buttons/PrimaryButton/PrimaryButton.stories.es.js +1 -1
  47. package/dist/components/buttons/SecondaryButton/SecondaryButton.cjs.js +1 -1
  48. package/dist/components/buttons/SecondaryButton/SecondaryButton.es.js +2 -2
  49. package/dist/components/buttons/SecondaryButton/SecondaryButton.stories.cjs.js +1 -1
  50. package/dist/components/buttons/SecondaryButton/SecondaryButton.stories.es.js +1 -1
  51. package/dist/components/buttons/index.cjs.js +1 -1
  52. package/dist/components/buttons/index.es.js +1 -1
  53. package/dist/components/index.cjs.js +1 -1
  54. package/dist/components/index.es.js +90 -91
  55. package/dist/components/inputs/SearchInput/SearchInput.cjs.js +1 -1
  56. package/dist/components/inputs/SearchInput/SearchInput.es.js +174 -6
  57. package/dist/components/inputs/SearchInput/SearchInput.stories.cjs.js +1 -1
  58. package/dist/components/inputs/SearchInput/SearchInput.stories.es.js +4 -4
  59. package/dist/components/inputs/SearchInput/index.cjs.js +1 -1
  60. package/dist/components/inputs/SearchInput/index.es.js +2 -2
  61. package/dist/components/inputs/TextInput/TextInput.cjs.js +1 -1
  62. package/dist/components/inputs/TextInput/TextInput.es.js +2 -2
  63. package/dist/components/inputs/TextInput/TextInput.stories.cjs.js +1 -1
  64. package/dist/components/inputs/TextInput/TextInput.stories.es.js +1 -1
  65. package/dist/components/inputs/TextInput/index.cjs.js +1 -1
  66. package/dist/components/inputs/TextInput/index.es.js +1 -1
  67. package/dist/components/inputs/index.cjs.js +1 -1
  68. package/dist/components/inputs/index.es.js +4 -4
  69. package/dist/components/lists/FileList/FileList.cjs.js +1 -1
  70. package/dist/components/lists/FileList/FileList.es.js +2 -2
  71. package/dist/components/lists/FileList/FileListItem.cjs.js +1 -1
  72. package/dist/components/lists/FileList/FileListItem.es.js +7 -39
  73. package/dist/components/lists/FileList/index.cjs.js +1 -1
  74. package/dist/components/lists/FileList/index.es.js +4 -4
  75. package/dist/components/lists/TabList.stories.cjs.js +1 -1
  76. package/dist/components/lists/TabList.stories.es.js +18 -16
  77. package/dist/components/lists/index.cjs.js +1 -1
  78. package/dist/components/lists/index.es.js +4 -4
  79. package/dist/createSvgIcon-BSYat4nx.js +74 -0
  80. package/dist/createSvgIcon-BqRWmIPG.cjs +1 -0
  81. package/dist/{createSvgIcon-Dspfpz-l.js → createSvgIcon-DeRU4e-L.js} +20 -18
  82. package/dist/createSvgIcon-doNQ5emq.cjs +2 -0
  83. package/dist/index.cjs.js +1 -1
  84. package/dist/index.es.js +93 -94
  85. package/dist/refType-Bt58K9Sk.cjs +1 -0
  86. package/dist/{refType-BBFUe6fu.js → refType-CoCfCK--.js} +1 -1
  87. package/dist/styled-BU8dAebc.js +1751 -0
  88. package/dist/styled-DGjsLYEN.cjs +45 -0
  89. package/dist/styled-DP6LeBLQ.js +261 -0
  90. package/dist/styled-Dkd1VGM-.cjs +1 -0
  91. package/dist/useTheme-C132tQV-.js +10 -0
  92. package/dist/useTheme-CliHZTkE.cjs +1 -0
  93. package/dist/useThemeProps-63SNG58r.js +753 -0
  94. package/dist/useThemeProps-CVatCXfo.cjs +20 -0
  95. package/package.json +6 -7
  96. package/dist/Box-DjRIKMD0.cjs +0 -1
  97. package/dist/ButtonBase-BvllyU4w.cjs +0 -75
  98. package/dist/ButtonBase-C14ZYs6z.js +0 -833
  99. package/dist/CircularProgress-Bf46-VRs.js +0 -217
  100. package/dist/CircularProgress-DjSMBYnK.cjs +0 -28
  101. package/dist/DefaultButton-DPZOltN5.cjs +0 -1
  102. package/dist/IconButton-X6l-U-im.cjs +0 -2
  103. package/dist/InputBase-CzupOzjh.cjs +0 -4
  104. package/dist/LocalizationProvider-DqwEOZOd.cjs +0 -5
  105. package/dist/SearchInput-Bb3sCx3k.cjs +0 -1
  106. package/dist/SearchInput-DRjmNW6W.js +0 -177
  107. package/dist/Tabs-B9BPJaDx.js +0 -1090
  108. package/dist/Tabs-Dx8YJT4c.cjs +0 -4
  109. package/dist/TextInput-BFguMDSu.cjs +0 -12
  110. package/dist/TimePicker-B0HOzxHh.cjs +0 -69
  111. package/dist/TimePicker-OBZs04Z8.js +0 -19694
  112. package/dist/Typography-CRt6WSxo.js +0 -204
  113. package/dist/Typography-DsPQABF2.cjs +0 -1
  114. package/dist/createSvgIcon-BOQCM03y.cjs +0 -2
  115. package/dist/createSvgIcon-C2VxBqzG.cjs +0 -1
  116. package/dist/createSvgIcon-xJp3_zwo.js +0 -84
  117. package/dist/isHostComponent-PydJW4A4.cjs +0 -1
  118. package/dist/isHostComponent-kiaBvYVo.js +0 -6
  119. package/dist/refType-5EEBZL5_.cjs +0 -1
  120. package/dist/styled-D8lXwcQy.js +0 -423
  121. package/dist/styled-DFoJwRxe.cjs +0 -24
  122. package/dist/useSlotProps-BoMYRJkF.js +0 -72
  123. package/dist/useSlotProps-EKKRQjEn.cjs +0 -1
  124. package/dist/useTheme-BkW5nNsn.cjs +0 -1
  125. package/dist/useTheme-Bo1inEHN.js +0 -9
  126. package/dist/useThemeProps-BRWSvuZw.cjs +0 -42
  127. package/dist/useThemeProps-CZzcR_pm.js +0 -2288
@@ -0,0 +1,1167 @@
1
+ import { u as st, g as me, c as ke, _ as u, a as Q, P as o } from "./clamp-BGJvJ0FN.js";
2
+ import * as f from "react";
3
+ import { g as ve, s as at, u as it, c as P, b as Se, r as ct } from "./styled-BU8dAebc.js";
4
+ import { jsxs as J, jsx as N } from "react/jsx-runtime";
5
+ import { B as dt } from "./ButtonBase-V1pwsMMs.js";
6
+ import { u as ut } from "./unsupportedProp-BuVD30Gh.js";
7
+ import { s as X } from "./styled-DP6LeBLQ.js";
8
+ import { T as ft, d as pt, u as $e } from "./useThemeProps-63SNG58r.js";
9
+ import { a as bt, u as ht } from "./useForkRef-CQ5u1_mH.js";
10
+ import { d as Fe, a as Le, o as mt } from "./ownerWindow-C7EH1lr6.js";
11
+ import { a as be } from "./useTimeout-C7IkLqZ9.js";
12
+ import { r as vt } from "./refType-CoCfCK--.js";
13
+ import { c as Ae } from "./createSvgIcon-DeRU4e-L.js";
14
+ import { B as St } from "./ButtonBase-aujiNoUb.js";
15
+ let U;
16
+ function De() {
17
+ if (U)
18
+ return U;
19
+ const e = document.createElement("div"), t = document.createElement("div");
20
+ return t.style.width = "10px", t.style.height = "1px", e.appendChild(t), e.dir = "rtl", e.style.fontSize = "14px", e.style.width = "4px", e.style.height = "1px", e.style.position = "absolute", e.style.top = "-1000px", e.style.overflow = "scroll", document.body.appendChild(e), U = "reverse", e.scrollLeft > 0 ? U = "default" : (e.scrollLeft = 1, e.scrollLeft === 0 && (U = "negative")), document.body.removeChild(e), U;
21
+ }
22
+ function yt(e, t) {
23
+ const n = e.scrollLeft;
24
+ if (t !== "rtl")
25
+ return n;
26
+ switch (De()) {
27
+ case "negative":
28
+ return e.scrollWidth - e.clientWidth + n;
29
+ case "reverse":
30
+ return e.scrollWidth - e.clientWidth - n;
31
+ default:
32
+ return n;
33
+ }
34
+ }
35
+ function _e() {
36
+ const e = st(pt);
37
+ return process.env.NODE_ENV !== "production" && f.useDebugValue(e), e[ft] || e;
38
+ }
39
+ function gt(e) {
40
+ return me("MuiTab", e);
41
+ }
42
+ const Tt = ve("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrimary", "textColorSecondary", "selected", "disabled", "fullWidth", "wrapped", "iconWrapper"]), _ = Tt, xt = ["className", "disabled", "disableFocusRipple", "fullWidth", "icon", "iconPosition", "indicator", "label", "onChange", "onClick", "onFocus", "selected", "selectionFollowsFocus", "textColor", "value", "wrapped"], Bt = (e) => {
43
+ const {
44
+ classes: t,
45
+ textColor: n,
46
+ fullWidth: s,
47
+ wrapped: a,
48
+ icon: i,
49
+ label: v,
50
+ selected: b,
51
+ disabled: p
52
+ } = e, h = {
53
+ root: ["root", i && v && "labelIcon", `textColor${ke(n)}`, s && "fullWidth", a && "wrapped", b && "selected", p && "disabled"],
54
+ iconWrapper: ["iconWrapper"]
55
+ };
56
+ return Se(h, gt, t);
57
+ }, Ct = at(dt, {
58
+ name: "MuiTab",
59
+ slot: "Root",
60
+ overridesResolver: (e, t) => {
61
+ const {
62
+ ownerState: n
63
+ } = e;
64
+ return [t.root, n.label && n.icon && t.labelIcon, t[`textColor${ke(n.textColor)}`], n.fullWidth && t.fullWidth, n.wrapped && t.wrapped];
65
+ }
66
+ })(({
67
+ theme: e,
68
+ ownerState: t
69
+ }) => u({}, e.typography.button, {
70
+ maxWidth: 360,
71
+ minWidth: 90,
72
+ position: "relative",
73
+ minHeight: 48,
74
+ flexShrink: 0,
75
+ padding: "12px 16px",
76
+ overflow: "hidden",
77
+ whiteSpace: "normal",
78
+ textAlign: "center"
79
+ }, t.label && {
80
+ flexDirection: t.iconPosition === "top" || t.iconPosition === "bottom" ? "column" : "row"
81
+ }, {
82
+ lineHeight: 1.25
83
+ }, t.icon && t.label && {
84
+ minHeight: 72,
85
+ paddingTop: 9,
86
+ paddingBottom: 9,
87
+ [`& > .${_.iconWrapper}`]: u({}, t.iconPosition === "top" && {
88
+ marginBottom: 6
89
+ }, t.iconPosition === "bottom" && {
90
+ marginTop: 6
91
+ }, t.iconPosition === "start" && {
92
+ marginRight: e.spacing(1)
93
+ }, t.iconPosition === "end" && {
94
+ marginLeft: e.spacing(1)
95
+ })
96
+ }, t.textColor === "inherit" && {
97
+ color: "inherit",
98
+ opacity: 0.6,
99
+ // same opacity as theme.palette.text.secondary
100
+ [`&.${_.selected}`]: {
101
+ opacity: 1
102
+ },
103
+ [`&.${_.disabled}`]: {
104
+ opacity: (e.vars || e).palette.action.disabledOpacity
105
+ }
106
+ }, t.textColor === "primary" && {
107
+ color: (e.vars || e).palette.text.secondary,
108
+ [`&.${_.selected}`]: {
109
+ color: (e.vars || e).palette.primary.main
110
+ },
111
+ [`&.${_.disabled}`]: {
112
+ color: (e.vars || e).palette.text.disabled
113
+ }
114
+ }, t.textColor === "secondary" && {
115
+ color: (e.vars || e).palette.text.secondary,
116
+ [`&.${_.selected}`]: {
117
+ color: (e.vars || e).palette.secondary.main
118
+ },
119
+ [`&.${_.disabled}`]: {
120
+ color: (e.vars || e).palette.text.disabled
121
+ }
122
+ }, t.fullWidth && {
123
+ flexShrink: 1,
124
+ flexGrow: 1,
125
+ flexBasis: 0,
126
+ maxWidth: "none"
127
+ }, t.wrapped && {
128
+ fontSize: e.typography.pxToRem(12)
129
+ })), He = /* @__PURE__ */ f.forwardRef(function(t, n) {
130
+ const s = it({
131
+ props: t,
132
+ name: "MuiTab"
133
+ }), {
134
+ className: a,
135
+ disabled: i = !1,
136
+ disableFocusRipple: v = !1,
137
+ // eslint-disable-next-line react/prop-types
138
+ fullWidth: b,
139
+ icon: p,
140
+ iconPosition: h = "top",
141
+ // eslint-disable-next-line react/prop-types
142
+ indicator: g,
143
+ label: x,
144
+ onChange: S,
145
+ onClick: y,
146
+ onFocus: R,
147
+ // eslint-disable-next-line react/prop-types
148
+ selected: B,
149
+ // eslint-disable-next-line react/prop-types
150
+ selectionFollowsFocus: C,
151
+ // eslint-disable-next-line react/prop-types
152
+ textColor: H = "inherit",
153
+ value: w,
154
+ wrapped: ie = !1
155
+ } = s, j = Q(s, xt), Y = u({}, s, {
156
+ disabled: i,
157
+ disableFocusRipple: v,
158
+ selected: B,
159
+ icon: !!p,
160
+ iconPosition: h,
161
+ label: !!x,
162
+ fullWidth: b,
163
+ textColor: H,
164
+ wrapped: ie
165
+ }), V = Bt(Y), F = p && x && /* @__PURE__ */ f.isValidElement(p) ? /* @__PURE__ */ f.cloneElement(p, {
166
+ className: P(V.iconWrapper, p.props.className)
167
+ }) : p, ee = (M) => {
168
+ !B && S && S(M, w), y && y(M);
169
+ }, z = (M) => {
170
+ C && !B && S && S(M, w), R && R(M);
171
+ };
172
+ return /* @__PURE__ */ J(Ct, u({
173
+ focusRipple: !v,
174
+ className: P(V.root, a),
175
+ ref: n,
176
+ role: "tab",
177
+ "aria-selected": B,
178
+ disabled: i,
179
+ onClick: ee,
180
+ onFocus: z,
181
+ ownerState: Y,
182
+ tabIndex: B ? 0 : -1
183
+ }, j, {
184
+ children: [h === "top" || h === "start" ? /* @__PURE__ */ J(f.Fragment, {
185
+ children: [F, x]
186
+ }) : /* @__PURE__ */ J(f.Fragment, {
187
+ children: [x, F]
188
+ }), g]
189
+ }));
190
+ });
191
+ process.env.NODE_ENV !== "production" && (He.propTypes = {
192
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
193
+ // │ These PropTypes are generated from the TypeScript type definitions. │
194
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
195
+ // └─────────────────────────────────────────────────────────────────────┘
196
+ /**
197
+ * This prop isn't supported.
198
+ * Use the `component` prop if you need to change the children structure.
199
+ */
200
+ children: ut,
201
+ /**
202
+ * Override or extend the styles applied to the component.
203
+ */
204
+ classes: o.object,
205
+ /**
206
+ * @ignore
207
+ */
208
+ className: o.string,
209
+ /**
210
+ * If `true`, the component is disabled.
211
+ * @default false
212
+ */
213
+ disabled: o.bool,
214
+ /**
215
+ * If `true`, the keyboard focus ripple is disabled.
216
+ * @default false
217
+ */
218
+ disableFocusRipple: o.bool,
219
+ /**
220
+ * If `true`, the ripple effect is disabled.
221
+ *
222
+ * ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure
223
+ * to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
224
+ * @default false
225
+ */
226
+ disableRipple: o.bool,
227
+ /**
228
+ * The icon to display.
229
+ */
230
+ icon: o.oneOfType([o.element, o.string]),
231
+ /**
232
+ * The position of the icon relative to the label.
233
+ * @default 'top'
234
+ */
235
+ iconPosition: o.oneOf(["bottom", "end", "start", "top"]),
236
+ /**
237
+ * The label element.
238
+ */
239
+ label: o.node,
240
+ /**
241
+ * @ignore
242
+ */
243
+ onChange: o.func,
244
+ /**
245
+ * @ignore
246
+ */
247
+ onClick: o.func,
248
+ /**
249
+ * @ignore
250
+ */
251
+ onFocus: o.func,
252
+ /**
253
+ * The system prop that allows defining system overrides as well as additional CSS styles.
254
+ */
255
+ sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
256
+ /**
257
+ * You can provide your own value. Otherwise, we fallback to the child position index.
258
+ */
259
+ value: o.any,
260
+ /**
261
+ * Tab labels appear in a single row.
262
+ * They can use a second line if needed.
263
+ * @default false
264
+ */
265
+ wrapped: o.bool
266
+ });
267
+ const po = He;
268
+ function wt(e) {
269
+ return typeof e == "string";
270
+ }
271
+ function Et(e, t, n) {
272
+ return e === void 0 || wt(e) ? t : u({}, t, {
273
+ ownerState: u({}, t.ownerState, n)
274
+ });
275
+ }
276
+ function It(e, t = []) {
277
+ if (e === void 0)
278
+ return {};
279
+ const n = {};
280
+ return Object.keys(e).filter((s) => s.match(/^on[A-Z]/) && typeof e[s] == "function" && !t.includes(s)).forEach((s) => {
281
+ n[s] = e[s];
282
+ }), n;
283
+ }
284
+ function Nt(e, t, n) {
285
+ return typeof e == "function" ? e(t, n) : e;
286
+ }
287
+ function Pe(e) {
288
+ if (e === void 0)
289
+ return {};
290
+ const t = {};
291
+ return Object.keys(e).filter((n) => !(n.match(/^on[A-Z]/) && typeof e[n] == "function")).forEach((n) => {
292
+ t[n] = e[n];
293
+ }), t;
294
+ }
295
+ function Ot(e) {
296
+ const {
297
+ getSlotProps: t,
298
+ additionalProps: n,
299
+ externalSlotProps: s,
300
+ externalForwardedProps: a,
301
+ className: i
302
+ } = e;
303
+ if (!t) {
304
+ const y = P(n == null ? void 0 : n.className, i, a == null ? void 0 : a.className, s == null ? void 0 : s.className), R = u({}, n == null ? void 0 : n.style, a == null ? void 0 : a.style, s == null ? void 0 : s.style), B = u({}, n, a, s);
305
+ return y.length > 0 && (B.className = y), Object.keys(R).length > 0 && (B.style = R), {
306
+ props: B,
307
+ internalRef: void 0
308
+ };
309
+ }
310
+ const v = It(u({}, a, s)), b = Pe(s), p = Pe(a), h = t(v), g = P(h == null ? void 0 : h.className, n == null ? void 0 : n.className, i, a == null ? void 0 : a.className, s == null ? void 0 : s.className), x = u({}, h == null ? void 0 : h.style, n == null ? void 0 : n.style, a == null ? void 0 : a.style, s == null ? void 0 : s.style), S = u({}, h, n, p, b);
311
+ return g.length > 0 && (S.className = g), Object.keys(x).length > 0 && (S.style = x), {
312
+ props: S,
313
+ internalRef: h.ref
314
+ };
315
+ }
316
+ const Pt = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"];
317
+ function ae(e) {
318
+ var t;
319
+ const {
320
+ elementType: n,
321
+ externalSlotProps: s,
322
+ ownerState: a,
323
+ skipResolvingSlotProps: i = !1
324
+ } = e, v = Q(e, Pt), b = i ? {} : Nt(s, a), {
325
+ props: p,
326
+ internalRef: h
327
+ } = Ot(u({}, v, {
328
+ externalSlotProps: b
329
+ })), g = bt(h, b == null ? void 0 : b.ref, (t = e.additionalProps) == null ? void 0 : t.ref);
330
+ return Et(n, u({}, p, {
331
+ ref: g
332
+ }), a);
333
+ }
334
+ function Rt(e) {
335
+ return (1 + Math.sin(Math.PI * e - Math.PI / 2)) / 2;
336
+ }
337
+ function Mt(e, t, n, s = {}, a = () => {
338
+ }) {
339
+ const {
340
+ ease: i = Rt,
341
+ duration: v = 300
342
+ // standard
343
+ } = s;
344
+ let b = null;
345
+ const p = t[e];
346
+ let h = !1;
347
+ const g = () => {
348
+ h = !0;
349
+ }, x = (S) => {
350
+ if (h) {
351
+ a(new Error("Animation cancelled"));
352
+ return;
353
+ }
354
+ b === null && (b = S);
355
+ const y = Math.min(1, (S - b) / v);
356
+ if (t[e] = i(y) * (n - p) + p, y >= 1) {
357
+ requestAnimationFrame(() => {
358
+ a(null);
359
+ });
360
+ return;
361
+ }
362
+ requestAnimationFrame(x);
363
+ };
364
+ return p === n ? (a(new Error("Element already at target position")), g) : (requestAnimationFrame(x), g);
365
+ }
366
+ const Wt = ["onChange"], zt = {
367
+ width: 99,
368
+ height: 99,
369
+ position: "absolute",
370
+ top: -9999,
371
+ overflow: "scroll"
372
+ };
373
+ function je(e) {
374
+ const {
375
+ onChange: t
376
+ } = e, n = Q(e, Wt), s = f.useRef(), a = f.useRef(null), i = () => {
377
+ s.current = a.current.offsetHeight - a.current.clientHeight;
378
+ };
379
+ return ht(() => {
380
+ const v = Fe(() => {
381
+ const p = s.current;
382
+ i(), p !== s.current && t(s.current);
383
+ }), b = Le(a.current);
384
+ return b.addEventListener("resize", v), () => {
385
+ v.clear(), b.removeEventListener("resize", v);
386
+ };
387
+ }, [t]), f.useEffect(() => {
388
+ i(), t(s.current);
389
+ }, [t]), /* @__PURE__ */ N("div", u({
390
+ style: zt,
391
+ ref: a
392
+ }, n));
393
+ }
394
+ process.env.NODE_ENV !== "production" && (je.propTypes = {
395
+ onChange: o.func.isRequired
396
+ });
397
+ const kt = Ae(/* @__PURE__ */ N("path", {
398
+ d: "M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"
399
+ }), "KeyboardArrowLeft"), $t = Ae(/* @__PURE__ */ N("path", {
400
+ d: "M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"
401
+ }), "KeyboardArrowRight");
402
+ function Ft(e) {
403
+ return me("MuiTabScrollButton", e);
404
+ }
405
+ const Lt = ve("MuiTabScrollButton", ["root", "vertical", "horizontal", "disabled"]), At = Lt, Dt = ["className", "slots", "slotProps", "direction", "orientation", "disabled"], _t = (e) => {
406
+ const {
407
+ classes: t,
408
+ orientation: n,
409
+ disabled: s
410
+ } = e;
411
+ return Se({
412
+ root: ["root", n, s && "disabled"]
413
+ }, Ft, t);
414
+ }, Ht = X(St, {
415
+ name: "MuiTabScrollButton",
416
+ slot: "Root",
417
+ overridesResolver: (e, t) => {
418
+ const {
419
+ ownerState: n
420
+ } = e;
421
+ return [t.root, n.orientation && t[n.orientation]];
422
+ }
423
+ })(({
424
+ ownerState: e
425
+ }) => u({
426
+ width: 40,
427
+ flexShrink: 0,
428
+ opacity: 0.8,
429
+ [`&.${At.disabled}`]: {
430
+ opacity: 0
431
+ }
432
+ }, e.orientation === "vertical" && {
433
+ width: "100%",
434
+ height: 40,
435
+ "& svg": {
436
+ transform: `rotate(${e.isRtl ? -90 : 90}deg)`
437
+ }
438
+ })), Ve = /* @__PURE__ */ f.forwardRef(function(t, n) {
439
+ var s, a;
440
+ const i = $e({
441
+ props: t,
442
+ name: "MuiTabScrollButton"
443
+ }), {
444
+ className: v,
445
+ slots: b = {},
446
+ slotProps: p = {},
447
+ direction: h
448
+ } = i, g = Q(i, Dt), S = _e().direction === "rtl", y = u({
449
+ isRtl: S
450
+ }, i), R = _t(y), B = (s = b.StartScrollButtonIcon) != null ? s : kt, C = (a = b.EndScrollButtonIcon) != null ? a : $t, H = ae({
451
+ elementType: B,
452
+ externalSlotProps: p.startScrollButtonIcon,
453
+ additionalProps: {
454
+ fontSize: "small"
455
+ },
456
+ ownerState: y
457
+ }), w = ae({
458
+ elementType: C,
459
+ externalSlotProps: p.endScrollButtonIcon,
460
+ additionalProps: {
461
+ fontSize: "small"
462
+ },
463
+ ownerState: y
464
+ });
465
+ return /* @__PURE__ */ N(Ht, u({
466
+ component: "div",
467
+ className: P(R.root, v),
468
+ ref: n,
469
+ role: null,
470
+ ownerState: y,
471
+ tabIndex: null
472
+ }, g, {
473
+ children: h === "left" ? /* @__PURE__ */ N(B, u({}, H)) : /* @__PURE__ */ N(C, u({}, w))
474
+ }));
475
+ });
476
+ process.env.NODE_ENV !== "production" && (Ve.propTypes = {
477
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
478
+ // │ These PropTypes are generated from the TypeScript type definitions. │
479
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
480
+ // └─────────────────────────────────────────────────────────────────────┘
481
+ /**
482
+ * The content of the component.
483
+ */
484
+ children: o.node,
485
+ /**
486
+ * Override or extend the styles applied to the component.
487
+ */
488
+ classes: o.object,
489
+ /**
490
+ * @ignore
491
+ */
492
+ className: o.string,
493
+ /**
494
+ * The direction the button should indicate.
495
+ */
496
+ direction: o.oneOf(["left", "right"]).isRequired,
497
+ /**
498
+ * If `true`, the component is disabled.
499
+ * @default false
500
+ */
501
+ disabled: o.bool,
502
+ /**
503
+ * The component orientation (layout flow direction).
504
+ */
505
+ orientation: o.oneOf(["horizontal", "vertical"]).isRequired,
506
+ /**
507
+ * The extra props for the slot components.
508
+ * You can override the existing props or add new ones.
509
+ * @default {}
510
+ */
511
+ slotProps: o.shape({
512
+ endScrollButtonIcon: o.oneOfType([o.func, o.object]),
513
+ startScrollButtonIcon: o.oneOfType([o.func, o.object])
514
+ }),
515
+ /**
516
+ * The components used for each slot inside.
517
+ * @default {}
518
+ */
519
+ slots: o.shape({
520
+ EndScrollButtonIcon: o.elementType,
521
+ StartScrollButtonIcon: o.elementType
522
+ }),
523
+ /**
524
+ * The system prop that allows defining system overrides as well as additional CSS styles.
525
+ */
526
+ sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
527
+ });
528
+ const jt = Ve;
529
+ function Vt(e) {
530
+ return me("MuiTabs", e);
531
+ }
532
+ const Ut = ve("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVertical", "centered", "scroller", "fixed", "scrollableX", "scrollableY", "hideScrollbar", "scrollButtons", "scrollButtonsHideMobile", "indicator"]), he = Ut, Xt = ["aria-label", "aria-labelledby", "action", "centered", "children", "className", "component", "allowScrollButtonsMobile", "indicatorColor", "onChange", "orientation", "ScrollButtonComponent", "scrollButtons", "selectionFollowsFocus", "slots", "slotProps", "TabIndicatorProps", "TabScrollButtonProps", "textColor", "value", "variant", "visibleScrollbar"], Re = (e, t) => e === t ? e.firstChild : t && t.nextElementSibling ? t.nextElementSibling : e.firstChild, Me = (e, t) => e === t ? e.lastChild : t && t.previousElementSibling ? t.previousElementSibling : e.lastChild, se = (e, t, n) => {
533
+ let s = !1, a = n(e, t);
534
+ for (; a; ) {
535
+ if (a === e.firstChild) {
536
+ if (s)
537
+ return;
538
+ s = !0;
539
+ }
540
+ const i = a.disabled || a.getAttribute("aria-disabled") === "true";
541
+ if (!a.hasAttribute("tabindex") || i)
542
+ a = n(e, a);
543
+ else {
544
+ a.focus();
545
+ return;
546
+ }
547
+ }
548
+ }, Yt = (e) => {
549
+ const {
550
+ vertical: t,
551
+ fixed: n,
552
+ hideScrollbar: s,
553
+ scrollableX: a,
554
+ scrollableY: i,
555
+ centered: v,
556
+ scrollButtonsHideMobile: b,
557
+ classes: p
558
+ } = e;
559
+ return Se({
560
+ root: ["root", t && "vertical"],
561
+ scroller: ["scroller", n && "fixed", s && "hideScrollbar", a && "scrollableX", i && "scrollableY"],
562
+ flexContainer: ["flexContainer", t && "flexContainerVertical", v && "centered"],
563
+ indicator: ["indicator"],
564
+ scrollButtons: ["scrollButtons", b && "scrollButtonsHideMobile"],
565
+ scrollableX: [a && "scrollableX"],
566
+ hideScrollbar: [s && "hideScrollbar"]
567
+ }, Vt, p);
568
+ }, Kt = X("div", {
569
+ name: "MuiTabs",
570
+ slot: "Root",
571
+ overridesResolver: (e, t) => {
572
+ const {
573
+ ownerState: n
574
+ } = e;
575
+ return [{
576
+ [`& .${he.scrollButtons}`]: t.scrollButtons
577
+ }, {
578
+ [`& .${he.scrollButtons}`]: n.scrollButtonsHideMobile && t.scrollButtonsHideMobile
579
+ }, t.root, n.vertical && t.vertical];
580
+ }
581
+ })(({
582
+ ownerState: e,
583
+ theme: t
584
+ }) => u({
585
+ overflow: "hidden",
586
+ minHeight: 48,
587
+ // Add iOS momentum scrolling for iOS < 13.0
588
+ WebkitOverflowScrolling: "touch",
589
+ display: "flex"
590
+ }, e.vertical && {
591
+ flexDirection: "column"
592
+ }, e.scrollButtonsHideMobile && {
593
+ [`& .${he.scrollButtons}`]: {
594
+ [t.breakpoints.down("sm")]: {
595
+ display: "none"
596
+ }
597
+ }
598
+ })), qt = X("div", {
599
+ name: "MuiTabs",
600
+ slot: "Scroller",
601
+ overridesResolver: (e, t) => {
602
+ const {
603
+ ownerState: n
604
+ } = e;
605
+ return [t.scroller, n.fixed && t.fixed, n.hideScrollbar && t.hideScrollbar, n.scrollableX && t.scrollableX, n.scrollableY && t.scrollableY];
606
+ }
607
+ })(({
608
+ ownerState: e
609
+ }) => u({
610
+ position: "relative",
611
+ display: "inline-block",
612
+ flex: "1 1 auto",
613
+ whiteSpace: "nowrap"
614
+ }, e.fixed && {
615
+ overflowX: "hidden",
616
+ width: "100%"
617
+ }, e.hideScrollbar && {
618
+ // Hide dimensionless scrollbar on macOS
619
+ scrollbarWidth: "none",
620
+ // Firefox
621
+ "&::-webkit-scrollbar": {
622
+ display: "none"
623
+ // Safari + Chrome
624
+ }
625
+ }, e.scrollableX && {
626
+ overflowX: "auto",
627
+ overflowY: "hidden"
628
+ }, e.scrollableY && {
629
+ overflowY: "auto",
630
+ overflowX: "hidden"
631
+ })), Zt = X("div", {
632
+ name: "MuiTabs",
633
+ slot: "FlexContainer",
634
+ overridesResolver: (e, t) => {
635
+ const {
636
+ ownerState: n
637
+ } = e;
638
+ return [t.flexContainer, n.vertical && t.flexContainerVertical, n.centered && t.centered];
639
+ }
640
+ })(({
641
+ ownerState: e
642
+ }) => u({
643
+ display: "flex"
644
+ }, e.vertical && {
645
+ flexDirection: "column"
646
+ }, e.centered && {
647
+ justifyContent: "center"
648
+ })), Gt = X("span", {
649
+ name: "MuiTabs",
650
+ slot: "Indicator",
651
+ overridesResolver: (e, t) => t.indicator
652
+ })(({
653
+ ownerState: e,
654
+ theme: t
655
+ }) => u({
656
+ position: "absolute",
657
+ height: 2,
658
+ bottom: 0,
659
+ width: "100%",
660
+ transition: t.transitions.create()
661
+ }, e.indicatorColor === "primary" && {
662
+ backgroundColor: (t.vars || t).palette.primary.main
663
+ }, e.indicatorColor === "secondary" && {
664
+ backgroundColor: (t.vars || t).palette.secondary.main
665
+ }, e.vertical && {
666
+ height: "100%",
667
+ width: 2,
668
+ right: 0
669
+ })), Jt = X(je)({
670
+ overflowX: "auto",
671
+ overflowY: "hidden",
672
+ // Hide dimensionless scrollbar on macOS
673
+ scrollbarWidth: "none",
674
+ // Firefox
675
+ "&::-webkit-scrollbar": {
676
+ display: "none"
677
+ // Safari + Chrome
678
+ }
679
+ }), We = {};
680
+ let ze = !1;
681
+ const Ue = /* @__PURE__ */ f.forwardRef(function(t, n) {
682
+ const s = $e({
683
+ props: t,
684
+ name: "MuiTabs"
685
+ }), a = _e(), i = a.direction === "rtl", {
686
+ "aria-label": v,
687
+ "aria-labelledby": b,
688
+ action: p,
689
+ centered: h = !1,
690
+ children: g,
691
+ className: x,
692
+ component: S = "div",
693
+ allowScrollButtonsMobile: y = !1,
694
+ indicatorColor: R = "primary",
695
+ onChange: B,
696
+ orientation: C = "horizontal",
697
+ ScrollButtonComponent: H = jt,
698
+ scrollButtons: w = "auto",
699
+ selectionFollowsFocus: ie,
700
+ slots: j = {},
701
+ slotProps: Y = {},
702
+ TabIndicatorProps: V = {},
703
+ TabScrollButtonProps: F = {},
704
+ textColor: ee = "primary",
705
+ value: z,
706
+ variant: M = "standard",
707
+ visibleScrollbar: ce = !1
708
+ } = s, Xe = Q(s, Xt), E = M === "scrollable", I = C === "vertical", K = I ? "scrollTop" : "scrollLeft", te = I ? "top" : "left", oe = I ? "bottom" : "right", de = I ? "clientHeight" : "clientWidth", q = I ? "height" : "width", L = u({}, s, {
709
+ component: S,
710
+ allowScrollButtonsMobile: y,
711
+ indicatorColor: R,
712
+ orientation: C,
713
+ vertical: I,
714
+ scrollButtons: w,
715
+ textColor: ee,
716
+ variant: M,
717
+ visibleScrollbar: ce,
718
+ fixed: !E,
719
+ hideScrollbar: E && !ce,
720
+ scrollableX: E && !I,
721
+ scrollableY: E && I,
722
+ centered: h && !E,
723
+ scrollButtonsHideMobile: !y
724
+ }), k = Yt(L), Ye = ae({
725
+ elementType: j.StartScrollButtonIcon,
726
+ externalSlotProps: Y.startScrollButtonIcon,
727
+ ownerState: L
728
+ }), Ke = ae({
729
+ elementType: j.EndScrollButtonIcon,
730
+ externalSlotProps: Y.endScrollButtonIcon,
731
+ ownerState: L
732
+ });
733
+ process.env.NODE_ENV !== "production" && h && E && console.error('MUI: You can not use the `centered={true}` and `variant="scrollable"` properties at the same time on a `Tabs` component.');
734
+ const [ye, qe] = f.useState(!1), [A, ge] = f.useState(We), [Te, Ze] = f.useState(!1), [xe, Ge] = f.useState(!1), [Be, Je] = f.useState(!1), [Ce, Qe] = f.useState({
735
+ overflow: "hidden",
736
+ scrollbarWidth: 0
737
+ }), ne = /* @__PURE__ */ new Map(), W = f.useRef(null), D = f.useRef(null), we = () => {
738
+ const l = W.current;
739
+ let r;
740
+ if (l) {
741
+ const d = l.getBoundingClientRect();
742
+ r = {
743
+ clientWidth: l.clientWidth,
744
+ scrollLeft: l.scrollLeft,
745
+ scrollTop: l.scrollTop,
746
+ scrollLeftNormalized: yt(l, a.direction),
747
+ scrollWidth: l.scrollWidth,
748
+ top: d.top,
749
+ bottom: d.bottom,
750
+ left: d.left,
751
+ right: d.right
752
+ };
753
+ }
754
+ let c;
755
+ if (l && z !== !1) {
756
+ const d = D.current.children;
757
+ if (d.length > 0) {
758
+ const m = d[ne.get(z)];
759
+ process.env.NODE_ENV !== "production" && (m || console.error(["MUI: The `value` provided to the Tabs component is invalid.", `None of the Tabs' children match with "${z}".`, ne.keys ? `You can provide one of the following values: ${Array.from(ne.keys()).join(", ")}.` : null].join(`
760
+ `))), c = m ? m.getBoundingClientRect() : null, process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test" && !ze && c && c.width === 0 && c.height === 0 && // if the whole Tabs component is hidden, don't warn
761
+ r.clientWidth !== 0 && (r = null, console.error(["MUI: The `value` provided to the Tabs component is invalid.", `The Tab with this \`value\` ("${z}") is not part of the document layout.`, "Make sure the tab item is present in the document or that it's not `display: none`."].join(`
762
+ `)), ze = !0);
763
+ }
764
+ }
765
+ return {
766
+ tabsMeta: r,
767
+ tabMeta: c
768
+ };
769
+ }, Z = be(() => {
770
+ const {
771
+ tabsMeta: l,
772
+ tabMeta: r
773
+ } = we();
774
+ let c = 0, d;
775
+ if (I)
776
+ d = "top", r && l && (c = r.top - l.top + l.scrollTop);
777
+ else if (d = i ? "right" : "left", r && l) {
778
+ const T = i ? l.scrollLeftNormalized + l.clientWidth - l.scrollWidth : l.scrollLeft;
779
+ c = (i ? -1 : 1) * (r[d] - l[d] + T);
780
+ }
781
+ const m = {
782
+ [d]: c,
783
+ // May be wrong until the font is loaded.
784
+ [q]: r ? r[q] : 0
785
+ };
786
+ if (isNaN(A[d]) || isNaN(A[q]))
787
+ ge(m);
788
+ else {
789
+ const T = Math.abs(A[d] - m[d]), O = Math.abs(A[q] - m[q]);
790
+ (T >= 1 || O >= 1) && ge(m);
791
+ }
792
+ }), ue = (l, {
793
+ animation: r = !0
794
+ } = {}) => {
795
+ r ? Mt(K, W.current, l, {
796
+ duration: a.transitions.duration.standard
797
+ }) : W.current[K] = l;
798
+ }, Ee = (l) => {
799
+ let r = W.current[K];
800
+ I ? r += l : (r += l * (i ? -1 : 1), r *= i && De() === "reverse" ? -1 : 1), ue(r);
801
+ }, Ie = () => {
802
+ const l = W.current[de];
803
+ let r = 0;
804
+ const c = Array.from(D.current.children);
805
+ for (let d = 0; d < c.length; d += 1) {
806
+ const m = c[d];
807
+ if (r + m[de] > l) {
808
+ d === 0 && (r = l);
809
+ break;
810
+ }
811
+ r += m[de];
812
+ }
813
+ return r;
814
+ }, et = () => {
815
+ Ee(-1 * Ie());
816
+ }, tt = () => {
817
+ Ee(Ie());
818
+ }, ot = f.useCallback((l) => {
819
+ Qe({
820
+ overflow: null,
821
+ scrollbarWidth: l
822
+ });
823
+ }, []), nt = () => {
824
+ const l = {};
825
+ l.scrollbarSizeListener = E ? /* @__PURE__ */ N(Jt, {
826
+ onChange: ot,
827
+ className: P(k.scrollableX, k.hideScrollbar)
828
+ }) : null;
829
+ const c = E && (w === "auto" && (Te || xe) || w === !0);
830
+ return l.scrollButtonStart = c ? /* @__PURE__ */ N(H, u({
831
+ slots: {
832
+ StartScrollButtonIcon: j.StartScrollButtonIcon
833
+ },
834
+ slotProps: {
835
+ startScrollButtonIcon: Ye
836
+ },
837
+ orientation: C,
838
+ direction: i ? "right" : "left",
839
+ onClick: et,
840
+ disabled: !Te
841
+ }, F, {
842
+ className: P(k.scrollButtons, F.className)
843
+ })) : null, l.scrollButtonEnd = c ? /* @__PURE__ */ N(H, u({
844
+ slots: {
845
+ EndScrollButtonIcon: j.EndScrollButtonIcon
846
+ },
847
+ slotProps: {
848
+ endScrollButtonIcon: Ke
849
+ },
850
+ orientation: C,
851
+ direction: i ? "left" : "right",
852
+ onClick: tt,
853
+ disabled: !xe
854
+ }, F, {
855
+ className: P(k.scrollButtons, F.className)
856
+ })) : null, l;
857
+ }, Ne = be((l) => {
858
+ const {
859
+ tabsMeta: r,
860
+ tabMeta: c
861
+ } = we();
862
+ if (!(!c || !r)) {
863
+ if (c[te] < r[te]) {
864
+ const d = r[K] + (c[te] - r[te]);
865
+ ue(d, {
866
+ animation: l
867
+ });
868
+ } else if (c[oe] > r[oe]) {
869
+ const d = r[K] + (c[oe] - r[oe]);
870
+ ue(d, {
871
+ animation: l
872
+ });
873
+ }
874
+ }
875
+ }), le = be(() => {
876
+ E && w !== !1 && Je(!Be);
877
+ });
878
+ f.useEffect(() => {
879
+ const l = Fe(() => {
880
+ W.current && Z();
881
+ });
882
+ let r;
883
+ const c = (T) => {
884
+ T.forEach((O) => {
885
+ O.removedNodes.forEach((G) => {
886
+ var $;
887
+ ($ = r) == null || $.unobserve(G);
888
+ }), O.addedNodes.forEach((G) => {
889
+ var $;
890
+ ($ = r) == null || $.observe(G);
891
+ });
892
+ }), l(), le();
893
+ }, d = Le(W.current);
894
+ d.addEventListener("resize", l);
895
+ let m;
896
+ return typeof ResizeObserver < "u" && (r = new ResizeObserver(l), Array.from(D.current.children).forEach((T) => {
897
+ r.observe(T);
898
+ })), typeof MutationObserver < "u" && (m = new MutationObserver(c), m.observe(D.current, {
899
+ childList: !0
900
+ })), () => {
901
+ var T, O;
902
+ l.clear(), d.removeEventListener("resize", l), (T = m) == null || T.disconnect(), (O = r) == null || O.disconnect();
903
+ };
904
+ }, [Z, le]), f.useEffect(() => {
905
+ const l = Array.from(D.current.children), r = l.length;
906
+ if (typeof IntersectionObserver < "u" && r > 0 && E && w !== !1) {
907
+ const c = l[0], d = l[r - 1], m = {
908
+ root: W.current,
909
+ threshold: 0.99
910
+ }, T = (pe) => {
911
+ Ze(!pe[0].isIntersecting);
912
+ }, O = new IntersectionObserver(T, m);
913
+ O.observe(c);
914
+ const G = (pe) => {
915
+ Ge(!pe[0].isIntersecting);
916
+ }, $ = new IntersectionObserver(G, m);
917
+ return $.observe(d), () => {
918
+ O.disconnect(), $.disconnect();
919
+ };
920
+ }
921
+ }, [E, w, Be, g == null ? void 0 : g.length]), f.useEffect(() => {
922
+ qe(!0);
923
+ }, []), f.useEffect(() => {
924
+ Z();
925
+ }), f.useEffect(() => {
926
+ Ne(We !== A);
927
+ }, [Ne, A]), f.useImperativeHandle(p, () => ({
928
+ updateIndicator: Z,
929
+ updateScrollButtons: le
930
+ }), [Z, le]);
931
+ const Oe = /* @__PURE__ */ N(Gt, u({}, V, {
932
+ className: P(k.indicator, V.className),
933
+ ownerState: L,
934
+ style: u({}, A, V.style)
935
+ }));
936
+ let re = 0;
937
+ const lt = f.Children.map(g, (l) => {
938
+ if (!/* @__PURE__ */ f.isValidElement(l))
939
+ return null;
940
+ process.env.NODE_ENV !== "production" && ct.isFragment(l) && console.error(["MUI: The Tabs component doesn't accept a Fragment as a child.", "Consider providing an array instead."].join(`
941
+ `));
942
+ const r = l.props.value === void 0 ? re : l.props.value;
943
+ ne.set(r, re);
944
+ const c = r === z;
945
+ return re += 1, /* @__PURE__ */ f.cloneElement(l, u({
946
+ fullWidth: M === "fullWidth",
947
+ indicator: c && !ye && Oe,
948
+ selected: c,
949
+ selectionFollowsFocus: ie,
950
+ onChange: B,
951
+ textColor: ee,
952
+ value: r
953
+ }, re === 1 && z === !1 && !l.props.tabIndex ? {
954
+ tabIndex: 0
955
+ } : {}));
956
+ }), rt = (l) => {
957
+ const r = D.current, c = mt(r).activeElement;
958
+ if (c.getAttribute("role") !== "tab")
959
+ return;
960
+ let m = C === "horizontal" ? "ArrowLeft" : "ArrowUp", T = C === "horizontal" ? "ArrowRight" : "ArrowDown";
961
+ switch (C === "horizontal" && i && (m = "ArrowRight", T = "ArrowLeft"), l.key) {
962
+ case m:
963
+ l.preventDefault(), se(r, c, Me);
964
+ break;
965
+ case T:
966
+ l.preventDefault(), se(r, c, Re);
967
+ break;
968
+ case "Home":
969
+ l.preventDefault(), se(r, null, Re);
970
+ break;
971
+ case "End":
972
+ l.preventDefault(), se(r, null, Me);
973
+ break;
974
+ }
975
+ }, fe = nt();
976
+ return /* @__PURE__ */ J(Kt, u({
977
+ className: P(k.root, x),
978
+ ownerState: L,
979
+ ref: n,
980
+ as: S
981
+ }, Xe, {
982
+ children: [fe.scrollButtonStart, fe.scrollbarSizeListener, /* @__PURE__ */ J(qt, {
983
+ className: k.scroller,
984
+ ownerState: L,
985
+ style: {
986
+ overflow: Ce.overflow,
987
+ [I ? `margin${i ? "Left" : "Right"}` : "marginBottom"]: ce ? void 0 : -Ce.scrollbarWidth
988
+ },
989
+ ref: W,
990
+ children: [/* @__PURE__ */ N(Zt, {
991
+ "aria-label": v,
992
+ "aria-labelledby": b,
993
+ "aria-orientation": C === "vertical" ? "vertical" : null,
994
+ className: k.flexContainer,
995
+ ownerState: L,
996
+ onKeyDown: rt,
997
+ ref: D,
998
+ role: "tablist",
999
+ children: lt
1000
+ }), ye && Oe]
1001
+ }), fe.scrollButtonEnd]
1002
+ }));
1003
+ });
1004
+ process.env.NODE_ENV !== "production" && (Ue.propTypes = {
1005
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
1006
+ // │ These PropTypes are generated from the TypeScript type definitions. │
1007
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
1008
+ // └─────────────────────────────────────────────────────────────────────┘
1009
+ /**
1010
+ * Callback fired when the component mounts.
1011
+ * This is useful when you want to trigger an action programmatically.
1012
+ * It supports two actions: `updateIndicator()` and `updateScrollButtons()`
1013
+ *
1014
+ * @param {object} actions This object contains all possible actions
1015
+ * that can be triggered programmatically.
1016
+ */
1017
+ action: vt,
1018
+ /**
1019
+ * If `true`, the scroll buttons aren't forced hidden on mobile.
1020
+ * By default the scroll buttons are hidden on mobile and takes precedence over `scrollButtons`.
1021
+ * @default false
1022
+ */
1023
+ allowScrollButtonsMobile: o.bool,
1024
+ /**
1025
+ * The label for the Tabs as a string.
1026
+ */
1027
+ "aria-label": o.string,
1028
+ /**
1029
+ * An id or list of ids separated by a space that label the Tabs.
1030
+ */
1031
+ "aria-labelledby": o.string,
1032
+ /**
1033
+ * If `true`, the tabs are centered.
1034
+ * This prop is intended for large views.
1035
+ * @default false
1036
+ */
1037
+ centered: o.bool,
1038
+ /**
1039
+ * The content of the component.
1040
+ */
1041
+ children: o.node,
1042
+ /**
1043
+ * Override or extend the styles applied to the component.
1044
+ */
1045
+ classes: o.object,
1046
+ /**
1047
+ * @ignore
1048
+ */
1049
+ className: o.string,
1050
+ /**
1051
+ * The component used for the root node.
1052
+ * Either a string to use a HTML element or a component.
1053
+ */
1054
+ component: o.elementType,
1055
+ /**
1056
+ * Determines the color of the indicator.
1057
+ * @default 'primary'
1058
+ */
1059
+ indicatorColor: o.oneOfType([o.oneOf(["primary", "secondary"]), o.string]),
1060
+ /**
1061
+ * Callback fired when the value changes.
1062
+ *
1063
+ * @param {React.SyntheticEvent} event The event source of the callback. **Warning**: This is a generic event not a change event.
1064
+ * @param {any} value We default to the index of the child (number)
1065
+ */
1066
+ onChange: o.func,
1067
+ /**
1068
+ * The component orientation (layout flow direction).
1069
+ * @default 'horizontal'
1070
+ */
1071
+ orientation: o.oneOf(["horizontal", "vertical"]),
1072
+ /**
1073
+ * The component used to render the scroll buttons.
1074
+ * @default TabScrollButton
1075
+ */
1076
+ ScrollButtonComponent: o.elementType,
1077
+ /**
1078
+ * Determine behavior of scroll buttons when tabs are set to scroll:
1079
+ *
1080
+ * - `auto` will only present them when not all the items are visible.
1081
+ * - `true` will always present them.
1082
+ * - `false` will never present them.
1083
+ *
1084
+ * By default the scroll buttons are hidden on mobile.
1085
+ * This behavior can be disabled with `allowScrollButtonsMobile`.
1086
+ * @default 'auto'
1087
+ */
1088
+ scrollButtons: o.oneOf(["auto", !1, !0]),
1089
+ /**
1090
+ * If `true` the selected tab changes on focus. Otherwise it only
1091
+ * changes on activation.
1092
+ */
1093
+ selectionFollowsFocus: o.bool,
1094
+ /**
1095
+ * The extra props for the slot components.
1096
+ * You can override the existing props or add new ones.
1097
+ * @default {}
1098
+ */
1099
+ slotProps: o.shape({
1100
+ endScrollButtonIcon: o.oneOfType([o.func, o.object]),
1101
+ startScrollButtonIcon: o.oneOfType([o.func, o.object])
1102
+ }),
1103
+ /**
1104
+ * The components used for each slot inside.
1105
+ * @default {}
1106
+ */
1107
+ slots: o.shape({
1108
+ EndScrollButtonIcon: o.elementType,
1109
+ StartScrollButtonIcon: o.elementType
1110
+ }),
1111
+ /**
1112
+ * The system prop that allows defining system overrides as well as additional CSS styles.
1113
+ */
1114
+ sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
1115
+ /**
1116
+ * Props applied to the tab indicator element.
1117
+ * @default {}
1118
+ */
1119
+ TabIndicatorProps: o.object,
1120
+ /**
1121
+ * Props applied to the [`TabScrollButton`](/material-ui/api/tab-scroll-button/) element.
1122
+ * @default {}
1123
+ */
1124
+ TabScrollButtonProps: o.object,
1125
+ /**
1126
+ * Determines the color of the `Tab`.
1127
+ * @default 'primary'
1128
+ */
1129
+ textColor: o.oneOf(["inherit", "primary", "secondary"]),
1130
+ /**
1131
+ * The value of the currently selected `Tab`.
1132
+ * If you don't want any selected `Tab`, you can set this prop to `false`.
1133
+ */
1134
+ value: o.any,
1135
+ /**
1136
+ * Determines additional display behavior of the tabs:
1137
+ *
1138
+ * - `scrollable` will invoke scrolling properties and allow for horizontally
1139
+ * scrolling (or swiping) of the tab bar.
1140
+ * - `fullWidth` will make the tabs grow to use all the available space,
1141
+ * which should be used for small views, like on mobile.
1142
+ * - `standard` will render the default state.
1143
+ * @default 'standard'
1144
+ */
1145
+ variant: o.oneOf(["fullWidth", "scrollable", "standard"]),
1146
+ /**
1147
+ * If `true`, the scrollbar is visible. It can be useful when displaying
1148
+ * a long vertical list of tabs.
1149
+ * @default false
1150
+ */
1151
+ visibleScrollbar: o.bool
1152
+ });
1153
+ const bo = Ue;
1154
+ export {
1155
+ po as T,
1156
+ bo as a,
1157
+ yt as b,
1158
+ ae as c,
1159
+ De as d,
1160
+ It as e,
1161
+ he as f,
1162
+ gt as g,
1163
+ wt as i,
1164
+ Nt as r,
1165
+ _ as t,
1166
+ _e as u
1167
+ };