@cgi-learning-hub/ui 0.0.1-dev.1717458053 → 0.0.1-dev.1718639838
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Box-w9A3CGWz.js → Box-BHWJ-D81.js} +2 -2
- package/dist/{Box-B5JvteYc.cjs → Box-DjpT-6Yv.cjs} +1 -1
- package/dist/{ButtonBase-DLRUHDp_.cjs → ButtonBase-BHN-4x4u.cjs} +1 -1
- package/dist/{ButtonBase-ClqFvN38.js → ButtonBase-BpYorbzW.js} +3 -3
- package/dist/{CircularProgress-CKU4oqMn.js → CircularProgress-C8TogtEK.js} +3 -3
- package/dist/{CircularProgress-LIVNb3Un.cjs → CircularProgress-CjET2rvP.cjs} +1 -1
- package/dist/{DefaultButton-Bk1TaeJZ.cjs → DefaultButton-BoDg7xMm.cjs} +1 -1
- package/dist/{DefaultButton-Pk7aXp0l.js → DefaultButton-y5BL9CKZ.js} +5 -5
- package/dist/{IconButton-SMmmWi-o.js → IconButton-Hsn7HKeI.js} +4 -4
- package/dist/{IconButton-djnEGxm7.cjs → IconButton-fqTVX40x.cjs} +1 -1
- package/dist/{InputBase-BnfifOOr.js → InputBase-BdOkEcEz.js} +3 -3
- package/dist/{InputBase-BPq0sWTY.cjs → InputBase-DLc7Nf1T.cjs} +1 -1
- package/dist/{LocalizationProvider-DabIC_L5.js → LocalizationProvider-B28kINsn.js} +12 -10
- package/dist/{LocalizationProvider-BqBo3ogt.cjs → LocalizationProvider-U4FHK15N.cjs} +3 -3
- package/dist/{SearchInput-CoPiN90W.cjs → SearchInput-B_Mgl-CJ.cjs} +1 -1
- package/dist/{SearchInput-BEYRgfVH.js → SearchInput-DVccMSI6.js} +5 -5
- package/dist/{Tabs-NsW3-ZTG.js → Tabs-C8ECGIYh.js} +190 -188
- package/dist/Tabs-Cij7O-J8.cjs +4 -0
- package/dist/{TextInput-DMTI0kNm.cjs → TextInput-5zTkdX7s.cjs} +1 -1
- package/dist/{TextInput-Db4gwAZh.js → TextInput-CpnUc54E.js} +7 -7
- package/dist/{TimePicker-UQHnH9uN.cjs → TimePicker-CLlQsAN4.cjs} +1 -1
- package/dist/{TimePicker-BFhOku5y.js → TimePicker-DlaMNb6D.js} +16 -16
- package/dist/{Typography-DOPsRNd4.cjs → Typography-6WB4M4zs.cjs} +1 -1
- package/dist/{Typography-dcZWbxlM.js → Typography-D9Jbc-Y5.js} +2 -2
- package/dist/components/Dropzone/Dropzone.cjs.js +1 -1
- package/dist/components/Dropzone/Dropzone.es.js +5 -5
- package/dist/components/LocalizationProvider/LocalizationProvider.cjs.js +1 -1
- package/dist/components/LocalizationProvider/LocalizationProvider.es.js +2 -2
- package/dist/components/LocalizationProvider/index.cjs.js +1 -1
- package/dist/components/LocalizationProvider/index.es.js +1 -1
- package/dist/components/buttons/DefaultButton/DefaultButton.cjs.js +1 -1
- package/dist/components/buttons/DefaultButton/DefaultButton.es.js +2 -2
- package/dist/components/buttons/DefaultButton/DefaultButtonIcon.cjs.js +1 -1
- package/dist/components/buttons/DefaultButton/DefaultButtonIcon.es.js +2 -2
- package/dist/components/buttons/DefaultButton/index.cjs.js +1 -1
- package/dist/components/buttons/DefaultButton/index.es.js +1 -1
- package/dist/components/buttons/IconButton.stories.cjs.js +1 -1
- package/dist/components/buttons/IconButton.stories.es.js +3 -3
- package/dist/components/buttons/PrimaryButton/PrimaryButton.cjs.js +1 -1
- package/dist/components/buttons/PrimaryButton/PrimaryButton.es.js +1 -1
- package/dist/components/buttons/PrimaryButton/PrimaryButton.stories.cjs.js +1 -1
- package/dist/components/buttons/PrimaryButton/PrimaryButton.stories.es.js +1 -1
- package/dist/components/buttons/SecondaryButton/SecondaryButton.cjs.js +1 -1
- package/dist/components/buttons/SecondaryButton/SecondaryButton.es.js +1 -1
- package/dist/components/buttons/SecondaryButton/SecondaryButton.stories.cjs.js +1 -1
- package/dist/components/buttons/SecondaryButton/SecondaryButton.stories.es.js +1 -1
- package/dist/components/buttons/index.cjs.js +1 -1
- package/dist/components/buttons/index.es.js +1 -1
- package/dist/components/index.cjs.js +1 -1
- package/dist/components/index.es.js +11 -11
- package/dist/components/inputs/PasswordInput/PasswordInput.cjs.js +1 -1
- package/dist/components/inputs/PasswordInput/PasswordInput.es.js +6 -6
- package/dist/components/inputs/SearchInput/SearchInput.cjs.js +1 -1
- package/dist/components/inputs/SearchInput/SearchInput.es.js +3 -3
- package/dist/components/inputs/SearchInput/SearchInput.stories.cjs.js +1 -1
- package/dist/components/inputs/SearchInput/SearchInput.stories.es.js +1 -1
- package/dist/components/inputs/SearchInput/index.cjs.js +1 -1
- package/dist/components/inputs/SearchInput/index.es.js +1 -1
- package/dist/components/inputs/TextInput/TextInput.cjs.js +1 -1
- package/dist/components/inputs/TextInput/TextInput.es.js +1 -1
- package/dist/components/inputs/TextInput/TextInput.stories.cjs.js +1 -1
- package/dist/components/inputs/TextInput/TextInput.stories.es.js +1 -1
- package/dist/components/inputs/TextInput/index.cjs.js +1 -1
- package/dist/components/inputs/TextInput/index.es.js +1 -1
- package/dist/components/inputs/index.cjs.js +1 -1
- package/dist/components/inputs/index.es.js +2 -2
- package/dist/components/lists/FileList/FileList.cjs.js +1 -1
- package/dist/components/lists/FileList/FileList.es.js +1 -1
- package/dist/components/lists/FileList/FileListItem.cjs.js +1 -1
- package/dist/components/lists/FileList/FileListItem.es.js +6 -6
- package/dist/components/lists/TabList.stories.cjs.js +1 -1
- package/dist/components/lists/TabList.stories.es.js +3 -3
- package/dist/{createSvgIcon-B7iWPHJ8.js → createSvgIcon-BpzrJYC7.js} +2 -2
- package/dist/{createSvgIcon-BI_WIb5V.js → createSvgIcon-CbXClqUM.js} +3 -3
- package/dist/{createSvgIcon-bF0lGTlg.cjs → createSvgIcon-DQmDu_xr.cjs} +1 -1
- package/dist/{createSvgIcon-DxmHHVAO.cjs → createSvgIcon-O41BSqQe.cjs} +1 -1
- package/dist/{fr-BunYFA4w.cjs → fr-LokUOTE7.cjs} +1 -1
- package/dist/{fr-CxSZx9ZV.js → fr-ndKV9IhC.js} +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +11 -11
- package/dist/{refType-BZaHOHyZ.js → refType-CD9RZ5PF.js} +1 -1
- package/dist/{refType-B2Uz1rXB.cjs → refType-DR4z34r8.cjs} +1 -1
- package/dist/{styled-C9DDL6BK.cjs → styled-D6_yEe4a.cjs} +1 -1
- package/dist/{styled-DIjdzFBV.js → styled-DSGBDqKV.js} +1 -1
- package/dist/{useControlled-jN3fqFfv.cjs → useControlled-DKpcyPsg.cjs} +1 -1
- package/dist/{useControlled-BsLcOmhe.js → useControlled-DoRrpN8o.js} +1 -1
- package/dist/{useSlotProps-B8ywiWUP.js → useSlotProps-BCdUhJUO.js} +2 -2
- package/dist/{useSlotProps-CYib4OeI.cjs → useSlotProps-CXRrw38p.cjs} +1 -1
- package/dist/{useThemeProps-zi1FRI5J.cjs → useThemeProps-BktqG0To.cjs} +1 -1
- package/dist/{useThemeProps-B20BBUTu.js → useThemeProps-DJpU2Yr7.js} +155 -154
- package/package.json +1 -1
- package/dist/Tabs-Cr7s6H3h.cjs +0 -4
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { g as me, c as Le, _ as b, u as ve, b as ae, P as
|
|
1
|
+
import { g as me, c as Le, _ as b, u as ve, b as ae, P as o } from "./useThemeProps-DJpU2Yr7.js";
|
|
2
2
|
import * as u from "react";
|
|
3
|
-
import { g as Se, s as _, c as
|
|
3
|
+
import { g as Se, s as _, c as k, a as ye, d as st } from "./styled-DSGBDqKV.js";
|
|
4
4
|
import { jsxs as Q, jsx as C } from "react/jsx-runtime";
|
|
5
|
-
import { B as ke } from "./ButtonBase-
|
|
5
|
+
import { B as ke } from "./ButtonBase-BpYorbzW.js";
|
|
6
6
|
import { u as at } from "./unsupportedProp-BuVD30Gh.js";
|
|
7
|
-
import { u as Fe, a as se, b as it } from "./useSlotProps-
|
|
7
|
+
import { u as Fe, a as se, b as it } from "./useSlotProps-BCdUhJUO.js";
|
|
8
8
|
import { u as ct } from "./useForkRef-CQ5u1_mH.js";
|
|
9
9
|
import { a as $e, d as Ae, o as dt } from "./ownerWindow-C7EH1lr6.js";
|
|
10
10
|
import { u as be } from "./useTimeout-Dokw0W_A.js";
|
|
11
|
-
import { r as ut } from "./refType-
|
|
12
|
-
import { c as je } from "./createSvgIcon-
|
|
11
|
+
import { r as ut } from "./refType-CD9RZ5PF.js";
|
|
12
|
+
import { c as je } from "./createSvgIcon-BpzrJYC7.js";
|
|
13
13
|
let X;
|
|
14
14
|
function De() {
|
|
15
15
|
if (X)
|
|
16
16
|
return X;
|
|
17
|
-
const e = document.createElement("div"),
|
|
18
|
-
return
|
|
17
|
+
const e = document.createElement("div"), t = document.createElement("div");
|
|
18
|
+
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), X = "reverse", e.scrollLeft > 0 ? X = "default" : (e.scrollLeft = 1, e.scrollLeft === 0 && (X = "negative")), document.body.removeChild(e), X;
|
|
19
19
|
}
|
|
20
|
-
function pt(e,
|
|
20
|
+
function pt(e, t) {
|
|
21
21
|
const n = e.scrollLeft;
|
|
22
|
-
if (
|
|
22
|
+
if (t !== "rtl")
|
|
23
23
|
return n;
|
|
24
24
|
switch (De()) {
|
|
25
25
|
case "negative":
|
|
@@ -33,9 +33,9 @@ function pt(e, o) {
|
|
|
33
33
|
function ft(e) {
|
|
34
34
|
return me("MuiTab", e);
|
|
35
35
|
}
|
|
36
|
-
const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrimary", "textColorSecondary", "selected", "disabled", "fullWidth", "wrapped", "iconWrapper"]),
|
|
36
|
+
const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrimary", "textColorSecondary", "selected", "disabled", "fullWidth", "wrapped", "iconWrapper"]), L = bt, ht = ["className", "disabled", "disableFocusRipple", "fullWidth", "icon", "iconPosition", "indicator", "label", "onChange", "onClick", "onFocus", "selected", "selectionFollowsFocus", "textColor", "value", "wrapped"], mt = (e) => {
|
|
37
37
|
const {
|
|
38
|
-
classes:
|
|
38
|
+
classes: t,
|
|
39
39
|
textColor: n,
|
|
40
40
|
fullWidth: c,
|
|
41
41
|
wrapped: i,
|
|
@@ -47,19 +47,21 @@ const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrim
|
|
|
47
47
|
root: ["root", d && m && "labelIcon", `textColor${Le(n)}`, c && "fullWidth", i && "wrapped", h && "selected", p && "disabled"],
|
|
48
48
|
iconWrapper: ["iconWrapper"]
|
|
49
49
|
};
|
|
50
|
-
return ye(y, ft,
|
|
50
|
+
return ye(y, ft, t);
|
|
51
51
|
}, vt = _(ke, {
|
|
52
52
|
name: "MuiTab",
|
|
53
53
|
slot: "Root",
|
|
54
|
-
overridesResolver: (e,
|
|
54
|
+
overridesResolver: (e, t) => {
|
|
55
55
|
const {
|
|
56
56
|
ownerState: n
|
|
57
57
|
} = e;
|
|
58
|
-
return [
|
|
58
|
+
return [t.root, n.label && n.icon && t.labelIcon, t[`textColor${Le(n.textColor)}`], n.fullWidth && t.fullWidth, n.wrapped && t.wrapped, {
|
|
59
|
+
[`& .${L.iconWrapper}`]: t.iconWrapper
|
|
60
|
+
}];
|
|
59
61
|
}
|
|
60
62
|
})(({
|
|
61
63
|
theme: e,
|
|
62
|
-
ownerState:
|
|
64
|
+
ownerState: t
|
|
63
65
|
}) => b({}, e.typography.button, {
|
|
64
66
|
maxWidth: 360,
|
|
65
67
|
minWidth: 90,
|
|
@@ -70,59 +72,59 @@ const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrim
|
|
|
70
72
|
overflow: "hidden",
|
|
71
73
|
whiteSpace: "normal",
|
|
72
74
|
textAlign: "center"
|
|
73
|
-
},
|
|
74
|
-
flexDirection:
|
|
75
|
+
}, t.label && {
|
|
76
|
+
flexDirection: t.iconPosition === "top" || t.iconPosition === "bottom" ? "column" : "row"
|
|
75
77
|
}, {
|
|
76
78
|
lineHeight: 1.25
|
|
77
|
-
},
|
|
79
|
+
}, t.icon && t.label && {
|
|
78
80
|
minHeight: 72,
|
|
79
81
|
paddingTop: 9,
|
|
80
82
|
paddingBottom: 9,
|
|
81
|
-
[`& > .${
|
|
83
|
+
[`& > .${L.iconWrapper}`]: b({}, t.iconPosition === "top" && {
|
|
82
84
|
marginBottom: 6
|
|
83
|
-
},
|
|
85
|
+
}, t.iconPosition === "bottom" && {
|
|
84
86
|
marginTop: 6
|
|
85
|
-
},
|
|
87
|
+
}, t.iconPosition === "start" && {
|
|
86
88
|
marginRight: e.spacing(1)
|
|
87
|
-
},
|
|
89
|
+
}, t.iconPosition === "end" && {
|
|
88
90
|
marginLeft: e.spacing(1)
|
|
89
91
|
})
|
|
90
|
-
},
|
|
92
|
+
}, t.textColor === "inherit" && {
|
|
91
93
|
color: "inherit",
|
|
92
94
|
opacity: 0.6,
|
|
93
95
|
// same opacity as theme.palette.text.secondary
|
|
94
|
-
[`&.${
|
|
96
|
+
[`&.${L.selected}`]: {
|
|
95
97
|
opacity: 1
|
|
96
98
|
},
|
|
97
|
-
[`&.${
|
|
99
|
+
[`&.${L.disabled}`]: {
|
|
98
100
|
opacity: (e.vars || e).palette.action.disabledOpacity
|
|
99
101
|
}
|
|
100
|
-
},
|
|
102
|
+
}, t.textColor === "primary" && {
|
|
101
103
|
color: (e.vars || e).palette.text.secondary,
|
|
102
|
-
[`&.${
|
|
104
|
+
[`&.${L.selected}`]: {
|
|
103
105
|
color: (e.vars || e).palette.primary.main
|
|
104
106
|
},
|
|
105
|
-
[`&.${
|
|
107
|
+
[`&.${L.disabled}`]: {
|
|
106
108
|
color: (e.vars || e).palette.text.disabled
|
|
107
109
|
}
|
|
108
|
-
},
|
|
110
|
+
}, t.textColor === "secondary" && {
|
|
109
111
|
color: (e.vars || e).palette.text.secondary,
|
|
110
|
-
[`&.${
|
|
112
|
+
[`&.${L.selected}`]: {
|
|
111
113
|
color: (e.vars || e).palette.secondary.main
|
|
112
114
|
},
|
|
113
|
-
[`&.${
|
|
115
|
+
[`&.${L.disabled}`]: {
|
|
114
116
|
color: (e.vars || e).palette.text.disabled
|
|
115
117
|
}
|
|
116
|
-
},
|
|
118
|
+
}, t.fullWidth && {
|
|
117
119
|
flexShrink: 1,
|
|
118
120
|
flexGrow: 1,
|
|
119
121
|
flexBasis: 0,
|
|
120
122
|
maxWidth: "none"
|
|
121
|
-
},
|
|
123
|
+
}, t.wrapped && {
|
|
122
124
|
fontSize: e.typography.pxToRem(12)
|
|
123
|
-
})), _e = /* @__PURE__ */ u.forwardRef(function(
|
|
125
|
+
})), _e = /* @__PURE__ */ u.forwardRef(function(t, n) {
|
|
124
126
|
const c = ve({
|
|
125
|
-
props:
|
|
127
|
+
props: t,
|
|
126
128
|
name: "MuiTab"
|
|
127
129
|
}), {
|
|
128
130
|
className: i,
|
|
@@ -137,7 +139,7 @@ const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrim
|
|
|
137
139
|
label: T,
|
|
138
140
|
onChange: v,
|
|
139
141
|
onClick: I,
|
|
140
|
-
onFocus:
|
|
142
|
+
onFocus: F,
|
|
141
143
|
// eslint-disable-next-line react/prop-types
|
|
142
144
|
selected: E,
|
|
143
145
|
// eslint-disable-next-line react/prop-types
|
|
@@ -156,16 +158,16 @@ const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrim
|
|
|
156
158
|
fullWidth: h,
|
|
157
159
|
textColor: H,
|
|
158
160
|
wrapped: ie
|
|
159
|
-
}), U = mt(Y),
|
|
160
|
-
className:
|
|
161
|
+
}), U = mt(Y), $ = p && T && /* @__PURE__ */ u.isValidElement(p) ? /* @__PURE__ */ u.cloneElement(p, {
|
|
162
|
+
className: k(U.iconWrapper, p.props.className)
|
|
161
163
|
}) : p, Z = (M) => {
|
|
162
164
|
!E && v && v(M, N), I && I(M);
|
|
163
165
|
}, P = (M) => {
|
|
164
|
-
g && !E && v && v(M, N),
|
|
166
|
+
g && !E && v && v(M, N), F && F(M);
|
|
165
167
|
};
|
|
166
168
|
return /* @__PURE__ */ Q(vt, b({
|
|
167
169
|
focusRipple: !m,
|
|
168
|
-
className:
|
|
170
|
+
className: k(U.root, i),
|
|
169
171
|
ref: n,
|
|
170
172
|
role: "tab",
|
|
171
173
|
"aria-selected": E,
|
|
@@ -176,9 +178,9 @@ const bt = Se("MuiTab", ["root", "labelIcon", "textColorInherit", "textColorPrim
|
|
|
176
178
|
tabIndex: E ? 0 : -1
|
|
177
179
|
}, V, {
|
|
178
180
|
children: [y === "top" || y === "start" ? /* @__PURE__ */ Q(u.Fragment, {
|
|
179
|
-
children: [
|
|
181
|
+
children: [$, T]
|
|
180
182
|
}) : /* @__PURE__ */ Q(u.Fragment, {
|
|
181
|
-
children: [T,
|
|
183
|
+
children: [T, $]
|
|
182
184
|
}), w]
|
|
183
185
|
}));
|
|
184
186
|
});
|
|
@@ -195,21 +197,21 @@ process.env.NODE_ENV !== "production" && (_e.propTypes = {
|
|
|
195
197
|
/**
|
|
196
198
|
* Override or extend the styles applied to the component.
|
|
197
199
|
*/
|
|
198
|
-
classes:
|
|
200
|
+
classes: o.object,
|
|
199
201
|
/**
|
|
200
202
|
* @ignore
|
|
201
203
|
*/
|
|
202
|
-
className:
|
|
204
|
+
className: o.string,
|
|
203
205
|
/**
|
|
204
206
|
* If `true`, the component is disabled.
|
|
205
207
|
* @default false
|
|
206
208
|
*/
|
|
207
|
-
disabled:
|
|
209
|
+
disabled: o.bool,
|
|
208
210
|
/**
|
|
209
211
|
* If `true`, the keyboard focus ripple is disabled.
|
|
210
212
|
* @default false
|
|
211
213
|
*/
|
|
212
|
-
disableFocusRipple:
|
|
214
|
+
disableFocusRipple: o.bool,
|
|
213
215
|
/**
|
|
214
216
|
* If `true`, the ripple effect is disabled.
|
|
215
217
|
*
|
|
@@ -217,46 +219,46 @@ process.env.NODE_ENV !== "production" && (_e.propTypes = {
|
|
|
217
219
|
* to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
|
|
218
220
|
* @default false
|
|
219
221
|
*/
|
|
220
|
-
disableRipple:
|
|
222
|
+
disableRipple: o.bool,
|
|
221
223
|
/**
|
|
222
224
|
* The icon to display.
|
|
223
225
|
*/
|
|
224
|
-
icon:
|
|
226
|
+
icon: o.oneOfType([o.element, o.string]),
|
|
225
227
|
/**
|
|
226
228
|
* The position of the icon relative to the label.
|
|
227
229
|
* @default 'top'
|
|
228
230
|
*/
|
|
229
|
-
iconPosition:
|
|
231
|
+
iconPosition: o.oneOf(["bottom", "end", "start", "top"]),
|
|
230
232
|
/**
|
|
231
233
|
* The label element.
|
|
232
234
|
*/
|
|
233
|
-
label:
|
|
235
|
+
label: o.node,
|
|
234
236
|
/**
|
|
235
237
|
* @ignore
|
|
236
238
|
*/
|
|
237
|
-
onChange:
|
|
239
|
+
onChange: o.func,
|
|
238
240
|
/**
|
|
239
241
|
* @ignore
|
|
240
242
|
*/
|
|
241
|
-
onClick:
|
|
243
|
+
onClick: o.func,
|
|
242
244
|
/**
|
|
243
245
|
* @ignore
|
|
244
246
|
*/
|
|
245
|
-
onFocus:
|
|
247
|
+
onFocus: o.func,
|
|
246
248
|
/**
|
|
247
249
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
248
250
|
*/
|
|
249
|
-
sx:
|
|
251
|
+
sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
|
|
250
252
|
/**
|
|
251
253
|
* You can provide your own value. Otherwise, we fallback to the child position index.
|
|
252
254
|
*/
|
|
253
|
-
value:
|
|
255
|
+
value: o.any,
|
|
254
256
|
/**
|
|
255
257
|
* Tab labels appear in a single row.
|
|
256
258
|
* They can use a second line if needed.
|
|
257
259
|
* @default false
|
|
258
260
|
*/
|
|
259
|
-
wrapped:
|
|
261
|
+
wrapped: o.bool
|
|
260
262
|
});
|
|
261
263
|
const qt = _e, St = je(/* @__PURE__ */ C("path", {
|
|
262
264
|
d: "M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"
|
|
@@ -266,7 +268,7 @@ const qt = _e, St = je(/* @__PURE__ */ C("path", {
|
|
|
266
268
|
function gt(e) {
|
|
267
269
|
return (1 + Math.sin(Math.PI * e - Math.PI / 2)) / 2;
|
|
268
270
|
}
|
|
269
|
-
function Tt(e,
|
|
271
|
+
function Tt(e, t, n, c = {}, i = () => {
|
|
270
272
|
}) {
|
|
271
273
|
const {
|
|
272
274
|
ease: d = gt,
|
|
@@ -274,7 +276,7 @@ function Tt(e, o, n, c = {}, i = () => {
|
|
|
274
276
|
// standard
|
|
275
277
|
} = c;
|
|
276
278
|
let h = null;
|
|
277
|
-
const p =
|
|
279
|
+
const p = t[e];
|
|
278
280
|
let y = !1;
|
|
279
281
|
const w = () => {
|
|
280
282
|
y = !0;
|
|
@@ -285,7 +287,7 @@ function Tt(e, o, n, c = {}, i = () => {
|
|
|
285
287
|
}
|
|
286
288
|
h === null && (h = v);
|
|
287
289
|
const I = Math.min(1, (v - h) / m);
|
|
288
|
-
if (
|
|
290
|
+
if (t[e] = d(I) * (n - p) + p, I >= 1) {
|
|
289
291
|
requestAnimationFrame(() => {
|
|
290
292
|
i(null);
|
|
291
293
|
});
|
|
@@ -304,48 +306,48 @@ const xt = ["onChange"], Bt = {
|
|
|
304
306
|
};
|
|
305
307
|
function He(e) {
|
|
306
308
|
const {
|
|
307
|
-
onChange:
|
|
309
|
+
onChange: t
|
|
308
310
|
} = e, n = ae(e, xt), c = u.useRef(), i = u.useRef(null), d = () => {
|
|
309
311
|
c.current = i.current.offsetHeight - i.current.clientHeight;
|
|
310
312
|
};
|
|
311
313
|
return ct(() => {
|
|
312
314
|
const m = Ae(() => {
|
|
313
315
|
const p = c.current;
|
|
314
|
-
d(), p !== c.current &&
|
|
316
|
+
d(), p !== c.current && t(c.current);
|
|
315
317
|
}), h = $e(i.current);
|
|
316
318
|
return h.addEventListener("resize", m), () => {
|
|
317
319
|
m.clear(), h.removeEventListener("resize", m);
|
|
318
320
|
};
|
|
319
|
-
}, [
|
|
320
|
-
d(),
|
|
321
|
-
}, [
|
|
321
|
+
}, [t]), u.useEffect(() => {
|
|
322
|
+
d(), t(c.current);
|
|
323
|
+
}, [t]), /* @__PURE__ */ C("div", b({
|
|
322
324
|
style: Bt,
|
|
323
325
|
ref: i
|
|
324
326
|
}, n));
|
|
325
327
|
}
|
|
326
328
|
process.env.NODE_ENV !== "production" && (He.propTypes = {
|
|
327
|
-
onChange:
|
|
329
|
+
onChange: o.func.isRequired
|
|
328
330
|
});
|
|
329
331
|
function Ct(e) {
|
|
330
332
|
return me("MuiTabScrollButton", e);
|
|
331
333
|
}
|
|
332
334
|
const wt = Se("MuiTabScrollButton", ["root", "vertical", "horizontal", "disabled"]), It = ["className", "slots", "slotProps", "direction", "orientation", "disabled"], Et = (e) => {
|
|
333
335
|
const {
|
|
334
|
-
classes:
|
|
336
|
+
classes: t,
|
|
335
337
|
orientation: n,
|
|
336
338
|
disabled: c
|
|
337
339
|
} = e;
|
|
338
340
|
return ye({
|
|
339
341
|
root: ["root", n, c && "disabled"]
|
|
340
|
-
}, Ct,
|
|
342
|
+
}, Ct, t);
|
|
341
343
|
}, Ot = _(ke, {
|
|
342
344
|
name: "MuiTabScrollButton",
|
|
343
345
|
slot: "Root",
|
|
344
|
-
overridesResolver: (e,
|
|
346
|
+
overridesResolver: (e, t) => {
|
|
345
347
|
const {
|
|
346
348
|
ownerState: n
|
|
347
349
|
} = e;
|
|
348
|
-
return [
|
|
350
|
+
return [t.root, n.orientation && t[n.orientation]];
|
|
349
351
|
}
|
|
350
352
|
})(({
|
|
351
353
|
ownerState: e
|
|
@@ -362,10 +364,10 @@ const wt = Se("MuiTabScrollButton", ["root", "vertical", "horizontal", "disabled
|
|
|
362
364
|
"& svg": {
|
|
363
365
|
transform: `rotate(${e.isRtl ? -90 : 90}deg)`
|
|
364
366
|
}
|
|
365
|
-
})), Ve = /* @__PURE__ */ u.forwardRef(function(
|
|
367
|
+
})), Ve = /* @__PURE__ */ u.forwardRef(function(t, n) {
|
|
366
368
|
var c, i;
|
|
367
369
|
const d = ve({
|
|
368
|
-
props:
|
|
370
|
+
props: t,
|
|
369
371
|
name: "MuiTabScrollButton"
|
|
370
372
|
}), {
|
|
371
373
|
className: m,
|
|
@@ -374,8 +376,8 @@ const wt = Se("MuiTabScrollButton", ["root", "vertical", "horizontal", "disabled
|
|
|
374
376
|
direction: y
|
|
375
377
|
} = d, w = ae(d, It), T = Fe(), v = b({
|
|
376
378
|
isRtl: T
|
|
377
|
-
}, d), I = Et(v),
|
|
378
|
-
elementType:
|
|
379
|
+
}, d), I = Et(v), F = (c = h.StartScrollButtonIcon) != null ? c : St, E = (i = h.EndScrollButtonIcon) != null ? i : yt, g = se({
|
|
380
|
+
elementType: F,
|
|
379
381
|
externalSlotProps: p.startScrollButtonIcon,
|
|
380
382
|
additionalProps: {
|
|
381
383
|
fontSize: "small"
|
|
@@ -391,13 +393,13 @@ const wt = Se("MuiTabScrollButton", ["root", "vertical", "horizontal", "disabled
|
|
|
391
393
|
});
|
|
392
394
|
return /* @__PURE__ */ C(Ot, b({
|
|
393
395
|
component: "div",
|
|
394
|
-
className:
|
|
396
|
+
className: k(I.root, m),
|
|
395
397
|
ref: n,
|
|
396
398
|
role: null,
|
|
397
399
|
ownerState: v,
|
|
398
400
|
tabIndex: null
|
|
399
401
|
}, w, {
|
|
400
|
-
children: y === "left" ? /* @__PURE__ */ C(
|
|
402
|
+
children: y === "left" ? /* @__PURE__ */ C(F, b({}, g)) : /* @__PURE__ */ C(E, b({}, H))
|
|
401
403
|
}));
|
|
402
404
|
});
|
|
403
405
|
process.env.NODE_ENV !== "production" && (Ve.propTypes = {
|
|
@@ -408,55 +410,55 @@ process.env.NODE_ENV !== "production" && (Ve.propTypes = {
|
|
|
408
410
|
/**
|
|
409
411
|
* The content of the component.
|
|
410
412
|
*/
|
|
411
|
-
children:
|
|
413
|
+
children: o.node,
|
|
412
414
|
/**
|
|
413
415
|
* Override or extend the styles applied to the component.
|
|
414
416
|
*/
|
|
415
|
-
classes:
|
|
417
|
+
classes: o.object,
|
|
416
418
|
/**
|
|
417
419
|
* @ignore
|
|
418
420
|
*/
|
|
419
|
-
className:
|
|
421
|
+
className: o.string,
|
|
420
422
|
/**
|
|
421
423
|
* The direction the button should indicate.
|
|
422
424
|
*/
|
|
423
|
-
direction:
|
|
425
|
+
direction: o.oneOf(["left", "right"]).isRequired,
|
|
424
426
|
/**
|
|
425
427
|
* If `true`, the component is disabled.
|
|
426
428
|
* @default false
|
|
427
429
|
*/
|
|
428
|
-
disabled:
|
|
430
|
+
disabled: o.bool,
|
|
429
431
|
/**
|
|
430
432
|
* The component orientation (layout flow direction).
|
|
431
433
|
*/
|
|
432
|
-
orientation:
|
|
434
|
+
orientation: o.oneOf(["horizontal", "vertical"]).isRequired,
|
|
433
435
|
/**
|
|
434
436
|
* The extra props for the slot components.
|
|
435
437
|
* You can override the existing props or add new ones.
|
|
436
438
|
* @default {}
|
|
437
439
|
*/
|
|
438
|
-
slotProps:
|
|
439
|
-
endScrollButtonIcon:
|
|
440
|
-
startScrollButtonIcon:
|
|
440
|
+
slotProps: o.shape({
|
|
441
|
+
endScrollButtonIcon: o.oneOfType([o.func, o.object]),
|
|
442
|
+
startScrollButtonIcon: o.oneOfType([o.func, o.object])
|
|
441
443
|
}),
|
|
442
444
|
/**
|
|
443
445
|
* The components used for each slot inside.
|
|
444
446
|
* @default {}
|
|
445
447
|
*/
|
|
446
|
-
slots:
|
|
447
|
-
EndScrollButtonIcon:
|
|
448
|
-
StartScrollButtonIcon:
|
|
448
|
+
slots: o.shape({
|
|
449
|
+
EndScrollButtonIcon: o.elementType,
|
|
450
|
+
StartScrollButtonIcon: o.elementType
|
|
449
451
|
}),
|
|
450
452
|
/**
|
|
451
453
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
452
454
|
*/
|
|
453
|
-
sx:
|
|
455
|
+
sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
|
|
454
456
|
});
|
|
455
457
|
function Nt(e) {
|
|
456
458
|
return me("MuiTabs", e);
|
|
457
459
|
}
|
|
458
|
-
const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVertical", "centered", "scroller", "fixed", "scrollableX", "scrollableY", "hideScrollbar", "scrollButtons", "scrollButtonsHideMobile", "indicator"]), he = Mt, Rt = ["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,
|
|
459
|
-
let c = !1, i = n(e,
|
|
460
|
+
const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVertical", "centered", "scroller", "fixed", "scrollableX", "scrollableY", "hideScrollbar", "scrollButtons", "scrollButtonsHideMobile", "indicator"]), he = Mt, Rt = ["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, Pe = (e, t) => e === t ? e.lastChild : t && t.previousElementSibling ? t.previousElementSibling : e.lastChild, ne = (e, t, n) => {
|
|
461
|
+
let c = !1, i = n(e, t);
|
|
460
462
|
for (; i; ) {
|
|
461
463
|
if (i === e.firstChild) {
|
|
462
464
|
if (c)
|
|
@@ -473,7 +475,7 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
473
475
|
}
|
|
474
476
|
}, Pt = (e) => {
|
|
475
477
|
const {
|
|
476
|
-
vertical:
|
|
478
|
+
vertical: t,
|
|
477
479
|
fixed: n,
|
|
478
480
|
hideScrollbar: c,
|
|
479
481
|
scrollableX: i,
|
|
@@ -483,30 +485,30 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
483
485
|
classes: p
|
|
484
486
|
} = e;
|
|
485
487
|
return ye({
|
|
486
|
-
root: ["root",
|
|
488
|
+
root: ["root", t && "vertical"],
|
|
487
489
|
scroller: ["scroller", n && "fixed", c && "hideScrollbar", i && "scrollableX", d && "scrollableY"],
|
|
488
|
-
flexContainer: ["flexContainer",
|
|
490
|
+
flexContainer: ["flexContainer", t && "flexContainerVertical", m && "centered"],
|
|
489
491
|
indicator: ["indicator"],
|
|
490
492
|
scrollButtons: ["scrollButtons", h && "scrollButtonsHideMobile"],
|
|
491
493
|
scrollableX: [i && "scrollableX"],
|
|
492
494
|
hideScrollbar: [c && "hideScrollbar"]
|
|
493
495
|
}, Nt, p);
|
|
494
|
-
},
|
|
496
|
+
}, Wt = _("div", {
|
|
495
497
|
name: "MuiTabs",
|
|
496
498
|
slot: "Root",
|
|
497
|
-
overridesResolver: (e,
|
|
499
|
+
overridesResolver: (e, t) => {
|
|
498
500
|
const {
|
|
499
501
|
ownerState: n
|
|
500
502
|
} = e;
|
|
501
503
|
return [{
|
|
502
|
-
[`& .${he.scrollButtons}`]:
|
|
504
|
+
[`& .${he.scrollButtons}`]: t.scrollButtons
|
|
503
505
|
}, {
|
|
504
|
-
[`& .${he.scrollButtons}`]: n.scrollButtonsHideMobile &&
|
|
505
|
-
},
|
|
506
|
+
[`& .${he.scrollButtons}`]: n.scrollButtonsHideMobile && t.scrollButtonsHideMobile
|
|
507
|
+
}, t.root, n.vertical && t.vertical];
|
|
506
508
|
}
|
|
507
509
|
})(({
|
|
508
510
|
ownerState: e,
|
|
509
|
-
theme:
|
|
511
|
+
theme: t
|
|
510
512
|
}) => b({
|
|
511
513
|
overflow: "hidden",
|
|
512
514
|
minHeight: 48,
|
|
@@ -517,18 +519,18 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
517
519
|
flexDirection: "column"
|
|
518
520
|
}, e.scrollButtonsHideMobile && {
|
|
519
521
|
[`& .${he.scrollButtons}`]: {
|
|
520
|
-
[
|
|
522
|
+
[t.breakpoints.down("sm")]: {
|
|
521
523
|
display: "none"
|
|
522
524
|
}
|
|
523
525
|
}
|
|
524
|
-
})),
|
|
526
|
+
})), zt = _("div", {
|
|
525
527
|
name: "MuiTabs",
|
|
526
528
|
slot: "Scroller",
|
|
527
|
-
overridesResolver: (e,
|
|
529
|
+
overridesResolver: (e, t) => {
|
|
528
530
|
const {
|
|
529
531
|
ownerState: n
|
|
530
532
|
} = e;
|
|
531
|
-
return [
|
|
533
|
+
return [t.scroller, n.fixed && t.fixed, n.hideScrollbar && t.hideScrollbar, n.scrollableX && t.scrollableX, n.scrollableY && t.scrollableY];
|
|
532
534
|
}
|
|
533
535
|
})(({
|
|
534
536
|
ownerState: e
|
|
@@ -557,11 +559,11 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
557
559
|
})), Lt = _("div", {
|
|
558
560
|
name: "MuiTabs",
|
|
559
561
|
slot: "FlexContainer",
|
|
560
|
-
overridesResolver: (e,
|
|
562
|
+
overridesResolver: (e, t) => {
|
|
561
563
|
const {
|
|
562
564
|
ownerState: n
|
|
563
565
|
} = e;
|
|
564
|
-
return [
|
|
566
|
+
return [t.flexContainer, n.vertical && t.flexContainerVertical, n.centered && t.centered];
|
|
565
567
|
}
|
|
566
568
|
})(({
|
|
567
569
|
ownerState: e
|
|
@@ -574,20 +576,20 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
574
576
|
})), kt = _("span", {
|
|
575
577
|
name: "MuiTabs",
|
|
576
578
|
slot: "Indicator",
|
|
577
|
-
overridesResolver: (e,
|
|
579
|
+
overridesResolver: (e, t) => t.indicator
|
|
578
580
|
})(({
|
|
579
581
|
ownerState: e,
|
|
580
|
-
theme:
|
|
582
|
+
theme: t
|
|
581
583
|
}) => b({
|
|
582
584
|
position: "absolute",
|
|
583
585
|
height: 2,
|
|
584
586
|
bottom: 0,
|
|
585
587
|
width: "100%",
|
|
586
|
-
transition:
|
|
588
|
+
transition: t.transitions.create()
|
|
587
589
|
}, e.indicatorColor === "primary" && {
|
|
588
|
-
backgroundColor: (
|
|
590
|
+
backgroundColor: (t.vars || t).palette.primary.main
|
|
589
591
|
}, e.indicatorColor === "secondary" && {
|
|
590
|
-
backgroundColor: (
|
|
592
|
+
backgroundColor: (t.vars || t).palette.secondary.main
|
|
591
593
|
}, e.vertical && {
|
|
592
594
|
height: "100%",
|
|
593
595
|
width: 2,
|
|
@@ -602,11 +604,11 @@ const Mt = Se("MuiTabs", ["root", "vertical", "flexContainer", "flexContainerVer
|
|
|
602
604
|
display: "none"
|
|
603
605
|
// Safari + Chrome
|
|
604
606
|
}
|
|
605
|
-
}),
|
|
606
|
-
let
|
|
607
|
-
const Ue = /* @__PURE__ */ u.forwardRef(function(
|
|
607
|
+
}), We = {};
|
|
608
|
+
let ze = !1;
|
|
609
|
+
const Ue = /* @__PURE__ */ u.forwardRef(function(t, n) {
|
|
608
610
|
const c = ve({
|
|
609
|
-
props:
|
|
611
|
+
props: t,
|
|
610
612
|
name: "MuiTabs"
|
|
611
613
|
}), i = it(), d = Fe(), {
|
|
612
614
|
"aria-label": m,
|
|
@@ -617,7 +619,7 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
617
619
|
className: T,
|
|
618
620
|
component: v = "div",
|
|
619
621
|
allowScrollButtonsMobile: I = !1,
|
|
620
|
-
indicatorColor:
|
|
622
|
+
indicatorColor: F = "primary",
|
|
621
623
|
onChange: E,
|
|
622
624
|
orientation: g = "horizontal",
|
|
623
625
|
ScrollButtonComponent: H = Ve,
|
|
@@ -626,15 +628,15 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
626
628
|
slots: V = {},
|
|
627
629
|
slotProps: Y = {},
|
|
628
630
|
TabIndicatorProps: U = {},
|
|
629
|
-
TabScrollButtonProps:
|
|
631
|
+
TabScrollButtonProps: $ = {},
|
|
630
632
|
textColor: Z = "primary",
|
|
631
633
|
value: P,
|
|
632
634
|
variant: M = "standard",
|
|
633
635
|
visibleScrollbar: ce = !1
|
|
634
|
-
} = c, Xe = ae(c, Rt), x = M === "scrollable", B = g === "vertical", K = B ? "scrollTop" : "scrollLeft", ee = B ? "top" : "left", te = B ? "bottom" : "right", de = B ? "clientHeight" : "clientWidth", q = B ? "height" : "width",
|
|
636
|
+
} = c, Xe = ae(c, Rt), x = M === "scrollable", B = g === "vertical", K = B ? "scrollTop" : "scrollLeft", ee = B ? "top" : "left", te = B ? "bottom" : "right", de = B ? "clientHeight" : "clientWidth", q = B ? "height" : "width", A = b({}, c, {
|
|
635
637
|
component: v,
|
|
636
638
|
allowScrollButtonsMobile: I,
|
|
637
|
-
indicatorColor:
|
|
639
|
+
indicatorColor: F,
|
|
638
640
|
orientation: g,
|
|
639
641
|
vertical: B,
|
|
640
642
|
scrollButtons: N,
|
|
@@ -647,20 +649,20 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
647
649
|
scrollableY: x && B,
|
|
648
650
|
centered: y && !x,
|
|
649
651
|
scrollButtonsHideMobile: !I
|
|
650
|
-
}),
|
|
652
|
+
}), W = Pt(A), Ye = se({
|
|
651
653
|
elementType: V.StartScrollButtonIcon,
|
|
652
654
|
externalSlotProps: Y.startScrollButtonIcon,
|
|
653
|
-
ownerState:
|
|
655
|
+
ownerState: A
|
|
654
656
|
}), Ke = se({
|
|
655
657
|
elementType: V.EndScrollButtonIcon,
|
|
656
658
|
externalSlotProps: Y.endScrollButtonIcon,
|
|
657
|
-
ownerState:
|
|
659
|
+
ownerState: A
|
|
658
660
|
});
|
|
659
661
|
process.env.NODE_ENV !== "production" && y && x && console.error('MUI: You can not use the `centered={true}` and `variant="scrollable"` properties at the same time on a `Tabs` component.');
|
|
660
|
-
const [ge, qe] = u.useState(!1), [
|
|
662
|
+
const [ge, qe] = u.useState(!1), [j, Te] = u.useState(We), [xe, Ge] = u.useState(!1), [Be, Je] = u.useState(!1), [Ce, Qe] = u.useState(!1), [we, Ze] = u.useState({
|
|
661
663
|
overflow: "hidden",
|
|
662
664
|
scrollbarWidth: 0
|
|
663
|
-
}), oe = /* @__PURE__ */ new Map(), R = u.useRef(null),
|
|
665
|
+
}), oe = /* @__PURE__ */ new Map(), R = u.useRef(null), D = u.useRef(null), Ie = () => {
|
|
664
666
|
const r = R.current;
|
|
665
667
|
let l;
|
|
666
668
|
if (r) {
|
|
@@ -679,13 +681,13 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
679
681
|
}
|
|
680
682
|
let s;
|
|
681
683
|
if (r && P !== !1) {
|
|
682
|
-
const a =
|
|
684
|
+
const a = D.current.children;
|
|
683
685
|
if (a.length > 0) {
|
|
684
686
|
const f = a[oe.get(P)];
|
|
685
687
|
process.env.NODE_ENV !== "production" && (f || console.error(["MUI: The `value` provided to the Tabs component is invalid.", `None of the Tabs' children match with "${P}".`, oe.keys ? `You can provide one of the following values: ${Array.from(oe.keys()).join(", ")}.` : null].join(`
|
|
686
|
-
`))), s = f ? f.getBoundingClientRect() : null, process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test" && !
|
|
688
|
+
`))), s = f ? f.getBoundingClientRect() : null, process.env.NODE_ENV !== "production" && process.env.NODE_ENV !== "test" && !ze && s && s.width === 0 && s.height === 0 && // if the whole Tabs component is hidden, don't warn
|
|
687
689
|
l.clientWidth !== 0 && (l = null, console.error(["MUI: The `value` provided to the Tabs component is invalid.", `The Tab with this \`value\` ("${P}") 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(`
|
|
688
|
-
`)),
|
|
690
|
+
`)), ze = !0);
|
|
689
691
|
}
|
|
690
692
|
}
|
|
691
693
|
return {
|
|
@@ -709,10 +711,10 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
709
711
|
// May be wrong until the font is loaded.
|
|
710
712
|
[q]: l ? l[q] : 0
|
|
711
713
|
};
|
|
712
|
-
if (isNaN(
|
|
714
|
+
if (isNaN(j[a]) || isNaN(j[q]))
|
|
713
715
|
Te(f);
|
|
714
716
|
else {
|
|
715
|
-
const S = Math.abs(
|
|
717
|
+
const S = Math.abs(j[a] - f[a]), O = Math.abs(j[q] - f[q]);
|
|
716
718
|
(S >= 1 || O >= 1) && Te(f);
|
|
717
719
|
}
|
|
718
720
|
}), ue = (r, {
|
|
@@ -727,7 +729,7 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
727
729
|
}, Oe = () => {
|
|
728
730
|
const r = R.current[de];
|
|
729
731
|
let l = 0;
|
|
730
|
-
const s = Array.from(
|
|
732
|
+
const s = Array.from(D.current.children);
|
|
731
733
|
for (let a = 0; a < s.length; a += 1) {
|
|
732
734
|
const f = s[a];
|
|
733
735
|
if (l + f[de] > r) {
|
|
@@ -750,7 +752,7 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
750
752
|
const r = {};
|
|
751
753
|
r.scrollbarSizeListener = x ? /* @__PURE__ */ C(Ft, {
|
|
752
754
|
onChange: ot,
|
|
753
|
-
className:
|
|
755
|
+
className: k(W.scrollableX, W.hideScrollbar)
|
|
754
756
|
}) : null;
|
|
755
757
|
const s = x && (N === "auto" && (xe || Be) || N === !0);
|
|
756
758
|
return r.scrollButtonStart = s ? /* @__PURE__ */ C(H, b({
|
|
@@ -764,8 +766,8 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
764
766
|
direction: d ? "right" : "left",
|
|
765
767
|
onClick: et,
|
|
766
768
|
disabled: !xe
|
|
767
|
-
},
|
|
768
|
-
className:
|
|
769
|
+
}, $, {
|
|
770
|
+
className: k(W.scrollButtons, $.className)
|
|
769
771
|
})) : null, r.scrollButtonEnd = s ? /* @__PURE__ */ C(H, b({
|
|
770
772
|
slots: {
|
|
771
773
|
EndScrollButtonIcon: V.EndScrollButtonIcon
|
|
@@ -777,8 +779,8 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
777
779
|
direction: d ? "left" : "right",
|
|
778
780
|
onClick: tt,
|
|
779
781
|
disabled: !Be
|
|
780
|
-
},
|
|
781
|
-
className:
|
|
782
|
+
}, $, {
|
|
783
|
+
className: k(W.scrollButtons, $.className)
|
|
782
784
|
})) : null, r;
|
|
783
785
|
}, Ne = be((r) => {
|
|
784
786
|
const {
|
|
@@ -809,26 +811,26 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
809
811
|
const s = (S) => {
|
|
810
812
|
S.forEach((O) => {
|
|
811
813
|
O.removedNodes.forEach((J) => {
|
|
812
|
-
var
|
|
813
|
-
(
|
|
814
|
+
var z;
|
|
815
|
+
(z = l) == null || z.unobserve(J);
|
|
814
816
|
}), O.addedNodes.forEach((J) => {
|
|
815
|
-
var
|
|
816
|
-
(
|
|
817
|
+
var z;
|
|
818
|
+
(z = l) == null || z.observe(J);
|
|
817
819
|
});
|
|
818
820
|
}), r(), re();
|
|
819
821
|
}, a = $e(R.current);
|
|
820
822
|
a.addEventListener("resize", r);
|
|
821
823
|
let f;
|
|
822
|
-
return typeof ResizeObserver < "u" && (l = new ResizeObserver(r), Array.from(
|
|
824
|
+
return typeof ResizeObserver < "u" && (l = new ResizeObserver(r), Array.from(D.current.children).forEach((S) => {
|
|
823
825
|
l.observe(S);
|
|
824
|
-
})), typeof MutationObserver < "u" && (f = new MutationObserver(s), f.observe(
|
|
826
|
+
})), typeof MutationObserver < "u" && (f = new MutationObserver(s), f.observe(D.current, {
|
|
825
827
|
childList: !0
|
|
826
828
|
})), () => {
|
|
827
829
|
var S, O;
|
|
828
830
|
r.clear(), a.removeEventListener("resize", r), (S = f) == null || S.disconnect(), (O = l) == null || O.disconnect();
|
|
829
831
|
};
|
|
830
832
|
}, [G, re]), u.useEffect(() => {
|
|
831
|
-
const r = Array.from(
|
|
833
|
+
const r = Array.from(D.current.children), l = r.length;
|
|
832
834
|
if (typeof IntersectionObserver < "u" && l > 0 && x && N !== !1) {
|
|
833
835
|
const s = r[0], a = r[l - 1], f = {
|
|
834
836
|
root: R.current,
|
|
@@ -839,9 +841,9 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
839
841
|
O.observe(s);
|
|
840
842
|
const J = (fe) => {
|
|
841
843
|
Je(!fe[0].isIntersecting);
|
|
842
|
-
},
|
|
843
|
-
return
|
|
844
|
-
O.disconnect(),
|
|
844
|
+
}, z = new IntersectionObserver(J, f);
|
|
845
|
+
return z.observe(a), () => {
|
|
846
|
+
O.disconnect(), z.disconnect();
|
|
845
847
|
};
|
|
846
848
|
}
|
|
847
849
|
}, [x, N, Ce, w == null ? void 0 : w.length]), u.useEffect(() => {
|
|
@@ -849,15 +851,15 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
849
851
|
}, []), u.useEffect(() => {
|
|
850
852
|
G();
|
|
851
853
|
}), u.useEffect(() => {
|
|
852
|
-
Ne(
|
|
853
|
-
}, [Ne,
|
|
854
|
+
Ne(We !== j);
|
|
855
|
+
}, [Ne, j]), u.useImperativeHandle(p, () => ({
|
|
854
856
|
updateIndicator: G,
|
|
855
857
|
updateScrollButtons: re
|
|
856
858
|
}), [G, re]);
|
|
857
859
|
const Me = /* @__PURE__ */ C(kt, b({}, U, {
|
|
858
|
-
className:
|
|
859
|
-
ownerState:
|
|
860
|
-
style: b({},
|
|
860
|
+
className: k(W.indicator, U.className),
|
|
861
|
+
ownerState: A,
|
|
862
|
+
style: b({}, j, U.style)
|
|
861
863
|
}));
|
|
862
864
|
let le = 0;
|
|
863
865
|
const lt = u.Children.map(w, (r) => {
|
|
@@ -880,7 +882,7 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
880
882
|
tabIndex: 0
|
|
881
883
|
} : {}));
|
|
882
884
|
}), nt = (r) => {
|
|
883
|
-
const l =
|
|
885
|
+
const l = D.current, s = dt(l).activeElement;
|
|
884
886
|
if (s.getAttribute("role") !== "tab")
|
|
885
887
|
return;
|
|
886
888
|
let f = g === "horizontal" ? "ArrowLeft" : "ArrowUp", S = g === "horizontal" ? "ArrowRight" : "ArrowDown";
|
|
@@ -899,15 +901,15 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
899
901
|
break;
|
|
900
902
|
}
|
|
901
903
|
}, pe = rt();
|
|
902
|
-
return /* @__PURE__ */ Q(
|
|
903
|
-
className:
|
|
904
|
-
ownerState:
|
|
904
|
+
return /* @__PURE__ */ Q(Wt, b({
|
|
905
|
+
className: k(W.root, T),
|
|
906
|
+
ownerState: A,
|
|
905
907
|
ref: n,
|
|
906
908
|
as: v
|
|
907
909
|
}, Xe, {
|
|
908
|
-
children: [pe.scrollButtonStart, pe.scrollbarSizeListener, /* @__PURE__ */ Q(
|
|
909
|
-
className:
|
|
910
|
-
ownerState:
|
|
910
|
+
children: [pe.scrollButtonStart, pe.scrollbarSizeListener, /* @__PURE__ */ Q(zt, {
|
|
911
|
+
className: W.scroller,
|
|
912
|
+
ownerState: A,
|
|
911
913
|
style: {
|
|
912
914
|
overflow: we.overflow,
|
|
913
915
|
[B ? `margin${d ? "Left" : "Right"}` : "marginBottom"]: ce ? void 0 : -we.scrollbarWidth
|
|
@@ -917,10 +919,10 @@ const Ue = /* @__PURE__ */ u.forwardRef(function(o, n) {
|
|
|
917
919
|
"aria-label": m,
|
|
918
920
|
"aria-labelledby": h,
|
|
919
921
|
"aria-orientation": g === "vertical" ? "vertical" : null,
|
|
920
|
-
className:
|
|
921
|
-
ownerState:
|
|
922
|
+
className: W.flexContainer,
|
|
923
|
+
ownerState: A,
|
|
922
924
|
onKeyDown: nt,
|
|
923
|
-
ref:
|
|
925
|
+
ref: D,
|
|
924
926
|
role: "tablist",
|
|
925
927
|
children: lt
|
|
926
928
|
}), ge && Me]
|
|
@@ -946,60 +948,60 @@ process.env.NODE_ENV !== "production" && (Ue.propTypes = {
|
|
|
946
948
|
* By default the scroll buttons are hidden on mobile and takes precedence over `scrollButtons`.
|
|
947
949
|
* @default false
|
|
948
950
|
*/
|
|
949
|
-
allowScrollButtonsMobile:
|
|
951
|
+
allowScrollButtonsMobile: o.bool,
|
|
950
952
|
/**
|
|
951
953
|
* The label for the Tabs as a string.
|
|
952
954
|
*/
|
|
953
|
-
"aria-label":
|
|
955
|
+
"aria-label": o.string,
|
|
954
956
|
/**
|
|
955
957
|
* An id or list of ids separated by a space that label the Tabs.
|
|
956
958
|
*/
|
|
957
|
-
"aria-labelledby":
|
|
959
|
+
"aria-labelledby": o.string,
|
|
958
960
|
/**
|
|
959
961
|
* If `true`, the tabs are centered.
|
|
960
962
|
* This prop is intended for large views.
|
|
961
963
|
* @default false
|
|
962
964
|
*/
|
|
963
|
-
centered:
|
|
965
|
+
centered: o.bool,
|
|
964
966
|
/**
|
|
965
967
|
* The content of the component.
|
|
966
968
|
*/
|
|
967
|
-
children:
|
|
969
|
+
children: o.node,
|
|
968
970
|
/**
|
|
969
971
|
* Override or extend the styles applied to the component.
|
|
970
972
|
*/
|
|
971
|
-
classes:
|
|
973
|
+
classes: o.object,
|
|
972
974
|
/**
|
|
973
975
|
* @ignore
|
|
974
976
|
*/
|
|
975
|
-
className:
|
|
977
|
+
className: o.string,
|
|
976
978
|
/**
|
|
977
979
|
* The component used for the root node.
|
|
978
980
|
* Either a string to use a HTML element or a component.
|
|
979
981
|
*/
|
|
980
|
-
component:
|
|
982
|
+
component: o.elementType,
|
|
981
983
|
/**
|
|
982
984
|
* Determines the color of the indicator.
|
|
983
985
|
* @default 'primary'
|
|
984
986
|
*/
|
|
985
|
-
indicatorColor:
|
|
987
|
+
indicatorColor: o.oneOfType([o.oneOf(["primary", "secondary"]), o.string]),
|
|
986
988
|
/**
|
|
987
989
|
* Callback fired when the value changes.
|
|
988
990
|
*
|
|
989
991
|
* @param {React.SyntheticEvent} event The event source of the callback. **Warning**: This is a generic event not a change event.
|
|
990
992
|
* @param {any} value We default to the index of the child (number)
|
|
991
993
|
*/
|
|
992
|
-
onChange:
|
|
994
|
+
onChange: o.func,
|
|
993
995
|
/**
|
|
994
996
|
* The component orientation (layout flow direction).
|
|
995
997
|
* @default 'horizontal'
|
|
996
998
|
*/
|
|
997
|
-
orientation:
|
|
999
|
+
orientation: o.oneOf(["horizontal", "vertical"]),
|
|
998
1000
|
/**
|
|
999
1001
|
* The component used to render the scroll buttons.
|
|
1000
1002
|
* @default TabScrollButton
|
|
1001
1003
|
*/
|
|
1002
|
-
ScrollButtonComponent:
|
|
1004
|
+
ScrollButtonComponent: o.elementType,
|
|
1003
1005
|
/**
|
|
1004
1006
|
* Determine behavior of scroll buttons when tabs are set to scroll:
|
|
1005
1007
|
*
|
|
@@ -1011,53 +1013,53 @@ process.env.NODE_ENV !== "production" && (Ue.propTypes = {
|
|
|
1011
1013
|
* This behavior can be disabled with `allowScrollButtonsMobile`.
|
|
1012
1014
|
* @default 'auto'
|
|
1013
1015
|
*/
|
|
1014
|
-
scrollButtons:
|
|
1016
|
+
scrollButtons: o.oneOf(["auto", !1, !0]),
|
|
1015
1017
|
/**
|
|
1016
1018
|
* If `true` the selected tab changes on focus. Otherwise it only
|
|
1017
1019
|
* changes on activation.
|
|
1018
1020
|
*/
|
|
1019
|
-
selectionFollowsFocus:
|
|
1021
|
+
selectionFollowsFocus: o.bool,
|
|
1020
1022
|
/**
|
|
1021
1023
|
* The extra props for the slot components.
|
|
1022
1024
|
* You can override the existing props or add new ones.
|
|
1023
1025
|
* @default {}
|
|
1024
1026
|
*/
|
|
1025
|
-
slotProps:
|
|
1026
|
-
endScrollButtonIcon:
|
|
1027
|
-
startScrollButtonIcon:
|
|
1027
|
+
slotProps: o.shape({
|
|
1028
|
+
endScrollButtonIcon: o.oneOfType([o.func, o.object]),
|
|
1029
|
+
startScrollButtonIcon: o.oneOfType([o.func, o.object])
|
|
1028
1030
|
}),
|
|
1029
1031
|
/**
|
|
1030
1032
|
* The components used for each slot inside.
|
|
1031
1033
|
* @default {}
|
|
1032
1034
|
*/
|
|
1033
|
-
slots:
|
|
1034
|
-
EndScrollButtonIcon:
|
|
1035
|
-
StartScrollButtonIcon:
|
|
1035
|
+
slots: o.shape({
|
|
1036
|
+
EndScrollButtonIcon: o.elementType,
|
|
1037
|
+
StartScrollButtonIcon: o.elementType
|
|
1036
1038
|
}),
|
|
1037
1039
|
/**
|
|
1038
1040
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
1039
1041
|
*/
|
|
1040
|
-
sx:
|
|
1042
|
+
sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
|
|
1041
1043
|
/**
|
|
1042
1044
|
* Props applied to the tab indicator element.
|
|
1043
1045
|
* @default {}
|
|
1044
1046
|
*/
|
|
1045
|
-
TabIndicatorProps:
|
|
1047
|
+
TabIndicatorProps: o.object,
|
|
1046
1048
|
/**
|
|
1047
1049
|
* Props applied to the [`TabScrollButton`](/material-ui/api/tab-scroll-button/) element.
|
|
1048
1050
|
* @default {}
|
|
1049
1051
|
*/
|
|
1050
|
-
TabScrollButtonProps:
|
|
1052
|
+
TabScrollButtonProps: o.object,
|
|
1051
1053
|
/**
|
|
1052
1054
|
* Determines the color of the `Tab`.
|
|
1053
1055
|
* @default 'primary'
|
|
1054
1056
|
*/
|
|
1055
|
-
textColor:
|
|
1057
|
+
textColor: o.oneOf(["inherit", "primary", "secondary"]),
|
|
1056
1058
|
/**
|
|
1057
1059
|
* The value of the currently selected `Tab`.
|
|
1058
1060
|
* If you don't want any selected `Tab`, you can set this prop to `false`.
|
|
1059
1061
|
*/
|
|
1060
|
-
value:
|
|
1062
|
+
value: o.any,
|
|
1061
1063
|
/**
|
|
1062
1064
|
* Determines additional display behavior of the tabs:
|
|
1063
1065
|
*
|
|
@@ -1068,13 +1070,13 @@ process.env.NODE_ENV !== "production" && (Ue.propTypes = {
|
|
|
1068
1070
|
* - `standard` will render the default state.
|
|
1069
1071
|
* @default 'standard'
|
|
1070
1072
|
*/
|
|
1071
|
-
variant:
|
|
1073
|
+
variant: o.oneOf(["fullWidth", "scrollable", "standard"]),
|
|
1072
1074
|
/**
|
|
1073
1075
|
* If `true`, the scrollbar is visible. It can be useful when displaying
|
|
1074
1076
|
* a long vertical list of tabs.
|
|
1075
1077
|
* @default false
|
|
1076
1078
|
*/
|
|
1077
|
-
visibleScrollbar:
|
|
1079
|
+
visibleScrollbar: o.bool
|
|
1078
1080
|
});
|
|
1079
1081
|
const Gt = Ue;
|
|
1080
1082
|
export {
|
|
@@ -1085,5 +1087,5 @@ export {
|
|
|
1085
1087
|
Nt as c,
|
|
1086
1088
|
St as d,
|
|
1087
1089
|
ft as g,
|
|
1088
|
-
|
|
1090
|
+
L as t
|
|
1089
1091
|
};
|