@hybridcore/ui 1.1.3 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ButtonBase-BYmh3G5j.js → ButtonBase-C7CHOX3y.js} +8 -7
- package/dist/{CardContent-C8PxkJz4.js → CardContent-DDFwwGfd.js} +3 -3
- package/dist/Checkbox-DP6_qp1v.js +469 -0
- package/dist/Collapse-9egEADkh.js +296 -0
- package/dist/{DialogContent-2aPOjKE7.js → DialogContent-MMUsECN2.js} +746 -789
- package/dist/{FormControl-BiAFm76F.js → FormControl-Cj5nc-Nv.js} +151 -163
- package/dist/FormControlLabel-j_atSYQA.js +827 -0
- package/dist/{IconButton-CQJ8wZE8.js → IconButton-2FRFauye.js} +4 -4
- package/dist/{Input-Bf5G3tFN.js → Input-BY_yKOrF.js} +5 -5
- package/dist/{listItemTextClasses-BvXFz-Oc.js → List-CgBXAAKA.js} +50 -62
- package/dist/ListItem-BFDUUjHt.js +428 -0
- package/dist/MenuItem-BejUFNIP.js +233 -0
- package/dist/{OutlinedInput-BEVE8VZQ.js → OutlinedInput-CnzESIDi.js} +5 -5
- package/dist/{Paper-CaiWdndQ.js → Paper-k37cShvn.js} +4 -4
- package/dist/{Select-DxpxZbJp.js → Select-BGt6e73I.js} +804 -1025
- package/dist/{Typography-XIiVCSto.js → Typography-Bjo-B13o.js} +3 -3
- package/dist/{chainPropTypes-DtBfUj5o.js → chainPropTypes-BmidnkZm.js} +2 -2
- package/dist/components/card/index.js +5 -5
- package/dist/components/card/styled.js +1 -1
- package/dist/components/collapsible-card/index.js +34 -0
- package/dist/components/collapsible-card/style.js +575 -0
- package/dist/components/confirm/dialog.js +5 -5
- package/dist/components/container/index.js +6 -6
- package/dist/components/context-menu/index.js +191 -603
- package/dist/components/data-management/instance-form/components/composite-list/index.js +1 -1
- package/dist/components/data-management/instance-form/components/variable/index.js +7 -5
- package/dist/components/data-management/instance-form/components/variables/index.js +1 -1
- package/dist/components/geometry-picker/coordinate/index.js +1 -1
- package/dist/components/geometry-picker/edit/index.js +1 -1
- package/dist/components/geometry-picker/geometry/index.js +1 -1
- package/dist/components/geometry-picker/index.js +2 -2
- package/dist/components/geometry-picker/kml/index.js +1 -1
- package/dist/components/geometry-picker/map/index.js +1 -1
- package/dist/components/geometry-picker/map/logic.js +1 -1
- package/dist/components/icon-button/index.js +1 -1
- package/dist/components/map/helpers/ol.js +2 -2
- package/dist/components/map/index.js +2 -2
- package/dist/components/map/logic.js +1 -1
- package/dist/components/map/styled.js +89 -6
- package/dist/components/search-input/index.js +3 -3
- package/dist/components/template-property-filters/index.js +78 -0
- package/dist/components/template-property-filters/property.js +7019 -0
- package/dist/components/tree-select/index.js +14 -13
- package/dist/components/treeview-filter/index.js +263 -328
- package/dist/components/treeview-filter/item/index.js +1 -1
- package/dist/components/treeview-filter/item-label/index.js +2 -2
- package/dist/createSvgIcon-DAR6Hwv8.js +77 -0
- package/dist/createSvgIcon-R_PakhKf.js +213 -0
- package/dist/{createTheme-agWfFD64.js → createTheme-oOCi1S_n.js} +5 -5
- package/dist/debounce-46wSf_lW.js +15 -0
- package/dist/{exactProp-CI8dagM-.js → exactProp-DhXxfU8X.js} +2 -2
- package/dist/index-C7W2wuUG.js +609 -0
- package/dist/index-DHnXB0CB.js +287 -0
- package/dist/{index-IvOfmM1F.js → index-JrtqxUdI.js} +6 -6
- package/dist/listItemTextClasses-CaI8l2PD.js +16 -0
- package/dist/main.d.ts +158 -0
- package/dist/main.js +33 -29
- package/dist/{ol-DXmSLlWv.js → ol-q6vTiF_t.js} +1 -1
- package/dist/resolveComponentProps-BwtY1IP3.js +54 -0
- package/dist/styled-CHMAYxVs.js +142 -0
- package/dist/{styled-Iq9jsO4F.js → styled-Wx2vv4j8.js} +1 -1
- package/dist/unsupportedProp-BuVD30Gh.js +9 -0
- package/dist/{useTheme-C0Dky5rV.js → useTheme-BI40KZ7w.js} +2 -1
- package/dist/{useTheme-CeyGVuQP.js → useTheme-CD5DEi5n.js} +2 -2
- package/dist/useThemeProps-D4or2IlT.js +62 -0
- package/dist/{useThemeProps-CzAjOL6F.js → useThemeProps-DT5EdhcP.js} +5 -4
- package/dist/{utils-DLpkeyhZ.js → utils-BEaBPoDF.js} +10 -10
- package/package.json +1 -1
- package/dist/Checkbox-DostZSwR.js +0 -673
- package/dist/index-Bw_m9ult.js +0 -1105
- package/dist/index-wW2D1aTG.js +0 -957
- package/dist/styled-C43K9x7T.js +0 -229
|
@@ -1,358 +1,138 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import * as
|
|
3
|
-
import { P as e, n as
|
|
4
|
-
import { g as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { o as
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import { u as
|
|
20
|
-
import { u as
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
|
|
1
|
+
import { _ as G, a as u } from "./extends-C3382pL0.js";
|
|
2
|
+
import * as s from "react";
|
|
3
|
+
import { P as e, n as Be, c as xe, f as yo, d as so } from "./createTheme-oOCi1S_n.js";
|
|
4
|
+
import { g as ge, u as Me, c as pe, b as Po, a as ve } from "./chainPropTypes-BmidnkZm.js";
|
|
5
|
+
import { jsx as j, jsxs as io } from "react/jsx-runtime";
|
|
6
|
+
import { g as ye, s as H, r as we, h as Eo } from "./styled-Wx2vv4j8.js";
|
|
7
|
+
import { d as Oo, M as To, u as Se, H as Ae } from "./DialogContent-MMUsECN2.js";
|
|
8
|
+
import { P as Co, i as Ro } from "./Paper-k37cShvn.js";
|
|
9
|
+
import { b as Io, a as Pe, u as So, r as Ne, e as xo } from "./ButtonBase-C7CHOX3y.js";
|
|
10
|
+
import { o as he } from "./ownerDocument-CUrv0DIK.js";
|
|
11
|
+
import { o as Ye } from "./ownerWindow-niciwP7I.js";
|
|
12
|
+
import { d as Mo } from "./debounce-46wSf_lW.js";
|
|
13
|
+
import { i as wo } from "./isHostComponent-kiaBvYVo.js";
|
|
14
|
+
import { u as No } from "./useTheme-CD5DEi5n.js";
|
|
15
|
+
import { T as Fo, r as Do, g as Je } from "./utils-BEaBPoDF.js";
|
|
16
|
+
import { e as $o } from "./exactProp-DhXxfU8X.js";
|
|
17
|
+
import { a as jo } from "./List-CgBXAAKA.js";
|
|
18
|
+
import { g as ko, i as Lo, b as _o, r as Ao, c as Vo, d as Bo, e as Wo, f as Uo } from "./FormControl-Cj5nc-Nv.js";
|
|
19
|
+
import { u as Qe, c as zo } from "./createSvgIcon-R_PakhKf.js";
|
|
20
|
+
import { u as Ho } from "./useId-BHG98T5I.js";
|
|
21
|
+
import { u as Ko } from "./useFormControl-CatNKXAi.js";
|
|
22
|
+
import { I as qo } from "./Input-BY_yKOrF.js";
|
|
23
|
+
import { O as Go } from "./OutlinedInput-CnzESIDi.js";
|
|
24
|
+
const Xo = /* @__PURE__ */ s.createContext();
|
|
24
25
|
process.env.NODE_ENV !== "production" && (e.node, e.bool);
|
|
25
|
-
const
|
|
26
|
-
const o =
|
|
26
|
+
const Yo = () => {
|
|
27
|
+
const o = s.useContext(Xo);
|
|
27
28
|
return o ?? !1;
|
|
28
|
-
},
|
|
29
|
-
function
|
|
30
|
-
return
|
|
29
|
+
}, Jo = ["actions", "autoFocus", "autoFocusItem", "children", "className", "disabledItemsFocusable", "disableListWrap", "onKeyDown", "variant"];
|
|
30
|
+
function Le(o, n, t) {
|
|
31
|
+
return o === n ? o.firstChild : n && n.nextElementSibling ? n.nextElementSibling : t ? null : o.firstChild;
|
|
31
32
|
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
ownerState: n
|
|
35
|
-
} = o;
|
|
36
|
-
return [t.root, n.dense && t.dense, n.divider && t.divider, !n.disableGutters && t.gutters];
|
|
37
|
-
}, at = (o) => {
|
|
38
|
-
const {
|
|
39
|
-
disabled: t,
|
|
40
|
-
dense: n,
|
|
41
|
-
divider: l,
|
|
42
|
-
disableGutters: m,
|
|
43
|
-
selected: g,
|
|
44
|
-
classes: p
|
|
45
|
-
} = o, b = de({
|
|
46
|
-
root: ["root", n && "dense", t && "disabled", !m && "gutters", l && "divider", g && "selected"]
|
|
47
|
-
}, rt, p);
|
|
48
|
-
return c({}, p, b);
|
|
49
|
-
}, lt = U(wo, {
|
|
50
|
-
shouldForwardProp: (o) => Oe(o) || o === "classes",
|
|
51
|
-
name: "MuiMenuItem",
|
|
52
|
-
slot: "Root",
|
|
53
|
-
overridesResolver: it
|
|
54
|
-
})(({
|
|
55
|
-
theme: o,
|
|
56
|
-
ownerState: t
|
|
57
|
-
}) => c({}, o.typography.body1, {
|
|
58
|
-
display: "flex",
|
|
59
|
-
justifyContent: "flex-start",
|
|
60
|
-
alignItems: "center",
|
|
61
|
-
position: "relative",
|
|
62
|
-
textDecoration: "none",
|
|
63
|
-
minHeight: 48,
|
|
64
|
-
paddingTop: 6,
|
|
65
|
-
paddingBottom: 6,
|
|
66
|
-
boxSizing: "border-box",
|
|
67
|
-
whiteSpace: "nowrap"
|
|
68
|
-
}, !t.disableGutters && {
|
|
69
|
-
paddingLeft: 16,
|
|
70
|
-
paddingRight: 16
|
|
71
|
-
}, t.divider && {
|
|
72
|
-
borderBottom: `1px solid ${(o.vars || o).palette.divider}`,
|
|
73
|
-
backgroundClip: "padding-box"
|
|
74
|
-
}, {
|
|
75
|
-
"&:hover": {
|
|
76
|
-
textDecoration: "none",
|
|
77
|
-
backgroundColor: (o.vars || o).palette.action.hover,
|
|
78
|
-
// Reset on touch devices, it doesn't add specificity
|
|
79
|
-
"@media (hover: none)": {
|
|
80
|
-
backgroundColor: "transparent"
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
[`&.${he.selected}`]: {
|
|
84
|
-
backgroundColor: o.vars ? `rgba(${o.vars.palette.primary.mainChannel} / ${o.vars.palette.action.selectedOpacity})` : Me(o.palette.primary.main, o.palette.action.selectedOpacity),
|
|
85
|
-
[`&.${he.focusVisible}`]: {
|
|
86
|
-
backgroundColor: o.vars ? `rgba(${o.vars.palette.primary.mainChannel} / calc(${o.vars.palette.action.selectedOpacity} + ${o.vars.palette.action.focusOpacity}))` : Me(o.palette.primary.main, o.palette.action.selectedOpacity + o.palette.action.focusOpacity)
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
[`&.${he.selected}:hover`]: {
|
|
90
|
-
backgroundColor: o.vars ? `rgba(${o.vars.palette.primary.mainChannel} / calc(${o.vars.palette.action.selectedOpacity} + ${o.vars.palette.action.hoverOpacity}))` : Me(o.palette.primary.main, o.palette.action.selectedOpacity + o.palette.action.hoverOpacity),
|
|
91
|
-
// Reset on touch devices, it doesn't add specificity
|
|
92
|
-
"@media (hover: none)": {
|
|
93
|
-
backgroundColor: o.vars ? `rgba(${o.vars.palette.primary.mainChannel} / ${o.vars.palette.action.selectedOpacity})` : Me(o.palette.primary.main, o.palette.action.selectedOpacity)
|
|
94
|
-
}
|
|
95
|
-
},
|
|
96
|
-
[`&.${he.focusVisible}`]: {
|
|
97
|
-
backgroundColor: (o.vars || o).palette.action.focus
|
|
98
|
-
},
|
|
99
|
-
[`&.${he.disabled}`]: {
|
|
100
|
-
opacity: (o.vars || o).palette.action.disabledOpacity
|
|
101
|
-
},
|
|
102
|
-
[`& + .${ro.root}`]: {
|
|
103
|
-
marginTop: o.spacing(1),
|
|
104
|
-
marginBottom: o.spacing(1)
|
|
105
|
-
},
|
|
106
|
-
[`& + .${ro.inset}`]: {
|
|
107
|
-
marginLeft: 52
|
|
108
|
-
},
|
|
109
|
-
[`& .${Qe.root}`]: {
|
|
110
|
-
marginTop: 0,
|
|
111
|
-
marginBottom: 0
|
|
112
|
-
},
|
|
113
|
-
[`& .${Qe.inset}`]: {
|
|
114
|
-
paddingLeft: 36
|
|
115
|
-
},
|
|
116
|
-
[`& .${Ze.root}`]: {
|
|
117
|
-
minWidth: 36
|
|
118
|
-
}
|
|
119
|
-
}, !t.dense && {
|
|
120
|
-
[o.breakpoints.up("sm")]: {
|
|
121
|
-
minHeight: "auto"
|
|
122
|
-
}
|
|
123
|
-
}, t.dense && c({
|
|
124
|
-
minHeight: 32,
|
|
125
|
-
// https://m2.material.io/components/menus#specs > Dense
|
|
126
|
-
paddingTop: 4,
|
|
127
|
-
paddingBottom: 4
|
|
128
|
-
}, o.typography.body2, {
|
|
129
|
-
[`& .${Ze.root} svg`]: {
|
|
130
|
-
fontSize: "1.25rem"
|
|
131
|
-
}
|
|
132
|
-
}))), ct = /* @__PURE__ */ r.forwardRef(function(t, n) {
|
|
133
|
-
const l = Ce({
|
|
134
|
-
props: t,
|
|
135
|
-
name: "MuiMenuItem"
|
|
136
|
-
}), {
|
|
137
|
-
autoFocus: m = !1,
|
|
138
|
-
component: g = "li",
|
|
139
|
-
dense: p = !1,
|
|
140
|
-
divider: u = !1,
|
|
141
|
-
disableGutters: b = !1,
|
|
142
|
-
focusVisibleClassName: O,
|
|
143
|
-
role: x = "menuitem",
|
|
144
|
-
tabIndex: E,
|
|
145
|
-
className: M
|
|
146
|
-
} = l, I = q(l, st), F = r.useContext(eo), R = r.useMemo(() => ({
|
|
147
|
-
dense: p || F.dense || !1,
|
|
148
|
-
disableGutters: b
|
|
149
|
-
}), [F.dense, p, b]), C = r.useRef(null);
|
|
150
|
-
mo(() => {
|
|
151
|
-
m && (C.current ? C.current.focus() : process.env.NODE_ENV !== "production" && console.error("MUI: Unable to set focus to a MenuItem whose component has not been rendered."));
|
|
152
|
-
}, [m]);
|
|
153
|
-
const d = c({}, l, {
|
|
154
|
-
dense: R.dense,
|
|
155
|
-
divider: u,
|
|
156
|
-
disableGutters: b
|
|
157
|
-
}), S = at(l), i = me(C, n);
|
|
158
|
-
let a;
|
|
159
|
-
return l.disabled || (a = E !== void 0 ? E : -1), /* @__PURE__ */ $(eo.Provider, {
|
|
160
|
-
value: R,
|
|
161
|
-
children: /* @__PURE__ */ $(lt, c({
|
|
162
|
-
ref: i,
|
|
163
|
-
role: x,
|
|
164
|
-
tabIndex: a,
|
|
165
|
-
component: g,
|
|
166
|
-
focusVisibleClassName: re(S.focusVisible, O),
|
|
167
|
-
className: re(S.root, M)
|
|
168
|
-
}, I, {
|
|
169
|
-
ownerState: d,
|
|
170
|
-
classes: S
|
|
171
|
-
}))
|
|
172
|
-
});
|
|
173
|
-
});
|
|
174
|
-
process.env.NODE_ENV !== "production" && (ct.propTypes = {
|
|
175
|
-
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
176
|
-
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
177
|
-
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
178
|
-
// └─────────────────────────────────────────────────────────────────────┘
|
|
179
|
-
/**
|
|
180
|
-
* If `true`, the list item is focused during the first mount.
|
|
181
|
-
* Focus will also be triggered if the value changes from false to true.
|
|
182
|
-
* @default false
|
|
183
|
-
*/
|
|
184
|
-
autoFocus: e.bool,
|
|
185
|
-
/**
|
|
186
|
-
* The content of the component.
|
|
187
|
-
*/
|
|
188
|
-
children: e.node,
|
|
189
|
-
/**
|
|
190
|
-
* Override or extend the styles applied to the component.
|
|
191
|
-
*/
|
|
192
|
-
classes: e.object,
|
|
193
|
-
/**
|
|
194
|
-
* @ignore
|
|
195
|
-
*/
|
|
196
|
-
className: e.string,
|
|
197
|
-
/**
|
|
198
|
-
* The component used for the root node.
|
|
199
|
-
* Either a string to use a HTML element or a component.
|
|
200
|
-
*/
|
|
201
|
-
component: e.elementType,
|
|
202
|
-
/**
|
|
203
|
-
* If `true`, compact vertical padding designed for keyboard and mouse input is used.
|
|
204
|
-
* The prop defaults to the value inherited from the parent Menu component.
|
|
205
|
-
* @default false
|
|
206
|
-
*/
|
|
207
|
-
dense: e.bool,
|
|
208
|
-
/**
|
|
209
|
-
* @ignore
|
|
210
|
-
*/
|
|
211
|
-
disabled: e.bool,
|
|
212
|
-
/**
|
|
213
|
-
* If `true`, the left and right padding is removed.
|
|
214
|
-
* @default false
|
|
215
|
-
*/
|
|
216
|
-
disableGutters: e.bool,
|
|
217
|
-
/**
|
|
218
|
-
* If `true`, a 1px light border is added to the bottom of the menu item.
|
|
219
|
-
* @default false
|
|
220
|
-
*/
|
|
221
|
-
divider: e.bool,
|
|
222
|
-
/**
|
|
223
|
-
* This prop can help identify which element has keyboard focus.
|
|
224
|
-
* The class name will be applied when the element gains the focus through keyboard interaction.
|
|
225
|
-
* It's a polyfill for the [CSS :focus-visible selector](https://drafts.csswg.org/selectors-4/#the-focus-visible-pseudo).
|
|
226
|
-
* The rationale for using this feature [is explained here](https://github.com/WICG/focus-visible/blob/HEAD/explainer.md).
|
|
227
|
-
* A [polyfill can be used](https://github.com/WICG/focus-visible) to apply a `focus-visible` class to other components
|
|
228
|
-
* if needed.
|
|
229
|
-
*/
|
|
230
|
-
focusVisibleClassName: e.string,
|
|
231
|
-
/**
|
|
232
|
-
* @ignore
|
|
233
|
-
*/
|
|
234
|
-
role: e.string,
|
|
235
|
-
/**
|
|
236
|
-
* If `true`, the component is selected.
|
|
237
|
-
* @default false
|
|
238
|
-
*/
|
|
239
|
-
selected: e.bool,
|
|
240
|
-
/**
|
|
241
|
-
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
242
|
-
*/
|
|
243
|
-
sx: e.oneOfType([e.arrayOf(e.oneOfType([e.func, e.object, e.bool])), e.func, e.object]),
|
|
244
|
-
/**
|
|
245
|
-
* @default 0
|
|
246
|
-
*/
|
|
247
|
-
tabIndex: e.number
|
|
248
|
-
});
|
|
249
|
-
const pt = ["actions", "autoFocus", "autoFocusItem", "children", "className", "disabledItemsFocusable", "disableListWrap", "onKeyDown", "variant"];
|
|
250
|
-
function Ve(o, t, n) {
|
|
251
|
-
return o === t ? o.firstChild : t && t.nextElementSibling ? t.nextElementSibling : n ? null : o.firstChild;
|
|
252
|
-
}
|
|
253
|
-
function so(o, t, n) {
|
|
254
|
-
return o === t ? n ? o.firstChild : o.lastChild : t && t.previousElementSibling ? t.previousElementSibling : n ? null : o.lastChild;
|
|
33
|
+
function Ze(o, n, t) {
|
|
34
|
+
return o === n ? t ? o.firstChild : o.lastChild : n && n.previousElementSibling ? n.previousElementSibling : t ? null : o.lastChild;
|
|
255
35
|
}
|
|
256
|
-
function
|
|
257
|
-
if (
|
|
36
|
+
function ao(o, n) {
|
|
37
|
+
if (n === void 0)
|
|
258
38
|
return !0;
|
|
259
|
-
let
|
|
260
|
-
return
|
|
39
|
+
let t = o.innerText;
|
|
40
|
+
return t === void 0 && (t = o.textContent), t = t.trim().toLowerCase(), t.length === 0 ? !1 : n.repeating ? t[0] === n.keys[0] : t.indexOf(n.keys.join("")) === 0;
|
|
261
41
|
}
|
|
262
|
-
function
|
|
263
|
-
let
|
|
264
|
-
for (;
|
|
265
|
-
if (
|
|
266
|
-
if (
|
|
42
|
+
function me(o, n, t, d, b, h) {
|
|
43
|
+
let f = !1, c = b(o, n, n ? t : !1);
|
|
44
|
+
for (; c; ) {
|
|
45
|
+
if (c === o.firstChild) {
|
|
46
|
+
if (f)
|
|
267
47
|
return !1;
|
|
268
|
-
|
|
48
|
+
f = !0;
|
|
269
49
|
}
|
|
270
|
-
const
|
|
271
|
-
if (!
|
|
272
|
-
|
|
50
|
+
const y = d ? !1 : c.disabled || c.getAttribute("aria-disabled") === "true";
|
|
51
|
+
if (!c.hasAttribute("tabindex") || !ao(c, h) || y)
|
|
52
|
+
c = b(o, c, t);
|
|
273
53
|
else
|
|
274
|
-
return
|
|
54
|
+
return c.focus(), !0;
|
|
275
55
|
}
|
|
276
56
|
return !1;
|
|
277
57
|
}
|
|
278
|
-
const
|
|
58
|
+
const lo = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
279
59
|
const {
|
|
280
60
|
// private
|
|
281
61
|
// eslint-disable-next-line react/prop-types
|
|
282
|
-
actions:
|
|
283
|
-
autoFocus:
|
|
284
|
-
autoFocusItem:
|
|
285
|
-
children:
|
|
286
|
-
className:
|
|
287
|
-
disabledItemsFocusable:
|
|
62
|
+
actions: d,
|
|
63
|
+
autoFocus: b = !1,
|
|
64
|
+
autoFocusItem: h = !1,
|
|
65
|
+
children: f,
|
|
66
|
+
className: c,
|
|
67
|
+
disabledItemsFocusable: y = !1,
|
|
288
68
|
disableListWrap: O = !1,
|
|
289
|
-
onKeyDown:
|
|
290
|
-
variant:
|
|
291
|
-
} =
|
|
69
|
+
onKeyDown: I,
|
|
70
|
+
variant: T = "selectedMenu"
|
|
71
|
+
} = n, w = G(n, Jo), C = s.useRef(null), _ = s.useRef({
|
|
292
72
|
keys: [],
|
|
293
73
|
repeating: !0,
|
|
294
74
|
previousKeyMatched: !0,
|
|
295
75
|
lastTime: null
|
|
296
76
|
});
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
}, [
|
|
77
|
+
Io(() => {
|
|
78
|
+
b && C.current.focus();
|
|
79
|
+
}, [b]), s.useImperativeHandle(d, () => ({
|
|
300
80
|
adjustStyleForScrollbar: (i, {
|
|
301
81
|
direction: a
|
|
302
82
|
}) => {
|
|
303
|
-
const
|
|
304
|
-
if (i.clientHeight <
|
|
305
|
-
const
|
|
306
|
-
|
|
83
|
+
const g = !C.current.style.width;
|
|
84
|
+
if (i.clientHeight < C.current.clientHeight && g) {
|
|
85
|
+
const E = `${Oo(he(i))}px`;
|
|
86
|
+
C.current.style[a === "rtl" ? "paddingLeft" : "paddingRight"] = E, C.current.style.width = `calc(100% + ${E})`;
|
|
307
87
|
}
|
|
308
|
-
return
|
|
88
|
+
return C.current;
|
|
309
89
|
}
|
|
310
90
|
}), []);
|
|
311
|
-
const
|
|
312
|
-
const a =
|
|
313
|
-
if (
|
|
314
|
-
i.preventDefault(),
|
|
315
|
-
else if (
|
|
316
|
-
i.preventDefault(),
|
|
317
|
-
else if (
|
|
318
|
-
i.preventDefault(),
|
|
319
|
-
else if (
|
|
320
|
-
i.preventDefault(),
|
|
321
|
-
else if (
|
|
322
|
-
const
|
|
323
|
-
|
|
324
|
-
const
|
|
325
|
-
|
|
91
|
+
const x = (i) => {
|
|
92
|
+
const a = C.current, g = i.key, E = he(a).activeElement;
|
|
93
|
+
if (g === "ArrowDown")
|
|
94
|
+
i.preventDefault(), me(a, E, O, y, Le);
|
|
95
|
+
else if (g === "ArrowUp")
|
|
96
|
+
i.preventDefault(), me(a, E, O, y, Ze);
|
|
97
|
+
else if (g === "Home")
|
|
98
|
+
i.preventDefault(), me(a, null, O, y, Le);
|
|
99
|
+
else if (g === "End")
|
|
100
|
+
i.preventDefault(), me(a, null, O, y, Ze);
|
|
101
|
+
else if (g.length === 1) {
|
|
102
|
+
const m = _.current, W = g.toLowerCase(), U = performance.now();
|
|
103
|
+
m.keys.length > 0 && (U - m.lastTime > 500 ? (m.keys = [], m.repeating = !0, m.previousKeyMatched = !0) : m.repeating && W !== m.keys[0] && (m.repeating = !1)), m.lastTime = U, m.keys.push(W);
|
|
104
|
+
const z = E && !m.repeating && ao(E, m);
|
|
105
|
+
m.previousKeyMatched && (z || me(a, E, !1, y, Le, m)) ? i.preventDefault() : m.previousKeyMatched = !1;
|
|
326
106
|
}
|
|
327
|
-
|
|
328
|
-
},
|
|
329
|
-
let
|
|
330
|
-
|
|
331
|
-
if (!/* @__PURE__ */
|
|
332
|
-
|
|
107
|
+
I && I(i);
|
|
108
|
+
}, R = Pe(C, t);
|
|
109
|
+
let p = -1;
|
|
110
|
+
s.Children.forEach(f, (i, a) => {
|
|
111
|
+
if (!/* @__PURE__ */ s.isValidElement(i)) {
|
|
112
|
+
p === a && (p += 1, p >= f.length && (p = -1));
|
|
333
113
|
return;
|
|
334
114
|
}
|
|
335
|
-
process.env.NODE_ENV !== "production" &&
|
|
336
|
-
`)), i.props.disabled || (
|
|
115
|
+
process.env.NODE_ENV !== "production" && Be.isFragment(i) && console.error(["MUI: The Menu component doesn't accept a Fragment as a child.", "Consider providing an array instead."].join(`
|
|
116
|
+
`)), i.props.disabled || (T === "selectedMenu" && i.props.selected || p === -1) && (p = a), p === a && (i.props.disabled || i.props.muiSkipListHighlight || i.type.muiSkipListHighlight) && (p += 1, p >= f.length && (p = -1));
|
|
337
117
|
});
|
|
338
|
-
const
|
|
339
|
-
if (a ===
|
|
340
|
-
const
|
|
341
|
-
return
|
|
118
|
+
const N = s.Children.map(f, (i, a) => {
|
|
119
|
+
if (a === p) {
|
|
120
|
+
const g = {};
|
|
121
|
+
return h && (g.autoFocus = !0), i.props.tabIndex === void 0 && T === "selectedMenu" && (g.tabIndex = 0), /* @__PURE__ */ s.cloneElement(i, g);
|
|
342
122
|
}
|
|
343
123
|
return i;
|
|
344
124
|
});
|
|
345
|
-
return /* @__PURE__ */
|
|
125
|
+
return /* @__PURE__ */ j(jo, u({
|
|
346
126
|
role: "menu",
|
|
347
|
-
ref:
|
|
348
|
-
className:
|
|
349
|
-
onKeyDown:
|
|
350
|
-
tabIndex:
|
|
351
|
-
},
|
|
352
|
-
children:
|
|
127
|
+
ref: R,
|
|
128
|
+
className: c,
|
|
129
|
+
onKeyDown: x,
|
|
130
|
+
tabIndex: b ? 0 : -1
|
|
131
|
+
}, w, {
|
|
132
|
+
children: N
|
|
353
133
|
}));
|
|
354
134
|
});
|
|
355
|
-
process.env.NODE_ENV !== "production" && (
|
|
135
|
+
process.env.NODE_ENV !== "production" && (lo.propTypes = {
|
|
356
136
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
357
137
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
358
138
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -397,111 +177,111 @@ process.env.NODE_ENV !== "production" && (go.propTypes = {
|
|
|
397
177
|
*/
|
|
398
178
|
variant: e.oneOf(["menu", "selectedMenu"])
|
|
399
179
|
});
|
|
400
|
-
const
|
|
401
|
-
function
|
|
180
|
+
const Qo = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
|
|
181
|
+
function Ve(o) {
|
|
402
182
|
return `scale(${o}, ${o ** 2})`;
|
|
403
183
|
}
|
|
404
|
-
const
|
|
184
|
+
const Zo = {
|
|
405
185
|
entering: {
|
|
406
186
|
opacity: 1,
|
|
407
|
-
transform:
|
|
187
|
+
transform: Ve(1)
|
|
408
188
|
},
|
|
409
189
|
entered: {
|
|
410
190
|
opacity: 1,
|
|
411
191
|
transform: "none"
|
|
412
192
|
}
|
|
413
|
-
},
|
|
193
|
+
}, _e = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), We = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
414
194
|
const {
|
|
415
|
-
addEndListener:
|
|
416
|
-
appear:
|
|
417
|
-
children:
|
|
418
|
-
easing:
|
|
419
|
-
in:
|
|
420
|
-
onEnter:
|
|
195
|
+
addEndListener: d,
|
|
196
|
+
appear: b = !0,
|
|
197
|
+
children: h,
|
|
198
|
+
easing: f,
|
|
199
|
+
in: c,
|
|
200
|
+
onEnter: y,
|
|
421
201
|
onEntered: O,
|
|
422
|
-
onEntering:
|
|
423
|
-
onExit:
|
|
424
|
-
onExited:
|
|
425
|
-
onExiting:
|
|
426
|
-
style:
|
|
427
|
-
timeout:
|
|
202
|
+
onEntering: I,
|
|
203
|
+
onExit: T,
|
|
204
|
+
onExited: w,
|
|
205
|
+
onExiting: C,
|
|
206
|
+
style: _,
|
|
207
|
+
timeout: x = "auto",
|
|
428
208
|
// eslint-disable-next-line react/prop-types
|
|
429
|
-
TransitionComponent:
|
|
430
|
-
} =
|
|
209
|
+
TransitionComponent: R = Fo
|
|
210
|
+
} = n, p = G(n, Qo), N = So(), i = s.useRef(), a = No(), g = s.useRef(null), E = Pe(g, h.ref, t), m = (P) => (k) => {
|
|
431
211
|
if (P) {
|
|
432
|
-
const
|
|
433
|
-
|
|
212
|
+
const D = g.current;
|
|
213
|
+
k === void 0 ? P(D) : P(D, k);
|
|
434
214
|
}
|
|
435
|
-
}, W =
|
|
436
|
-
|
|
215
|
+
}, W = m(I), U = m((P, k) => {
|
|
216
|
+
Do(P);
|
|
437
217
|
const {
|
|
438
|
-
duration:
|
|
439
|
-
delay:
|
|
440
|
-
easing:
|
|
441
|
-
} =
|
|
442
|
-
style:
|
|
443
|
-
timeout:
|
|
444
|
-
easing:
|
|
218
|
+
duration: D,
|
|
219
|
+
delay: l,
|
|
220
|
+
easing: $
|
|
221
|
+
} = Je({
|
|
222
|
+
style: _,
|
|
223
|
+
timeout: x,
|
|
224
|
+
easing: f
|
|
445
225
|
}, {
|
|
446
226
|
mode: "enter"
|
|
447
227
|
});
|
|
448
228
|
let X;
|
|
449
|
-
|
|
229
|
+
x === "auto" ? (X = a.transitions.getAutoHeightDuration(P.clientHeight), i.current = X) : X = D, P.style.transition = [a.transitions.create("opacity", {
|
|
450
230
|
duration: X,
|
|
451
|
-
delay:
|
|
231
|
+
delay: l
|
|
452
232
|
}), a.transitions.create("transform", {
|
|
453
|
-
duration:
|
|
454
|
-
delay:
|
|
455
|
-
easing:
|
|
456
|
-
})].join(","),
|
|
457
|
-
}),
|
|
233
|
+
duration: _e ? X : X * 0.666,
|
|
234
|
+
delay: l,
|
|
235
|
+
easing: $
|
|
236
|
+
})].join(","), y && y(P, k);
|
|
237
|
+
}), z = m(O), Y = m(C), A = m((P) => {
|
|
458
238
|
const {
|
|
459
|
-
duration:
|
|
460
|
-
delay:
|
|
239
|
+
duration: k,
|
|
240
|
+
delay: D,
|
|
241
|
+
easing: l
|
|
242
|
+
} = Je({
|
|
243
|
+
style: _,
|
|
244
|
+
timeout: x,
|
|
461
245
|
easing: f
|
|
462
|
-
} = to({
|
|
463
|
-
style: F,
|
|
464
|
-
timeout: R,
|
|
465
|
-
easing: p
|
|
466
246
|
}, {
|
|
467
247
|
mode: "exit"
|
|
468
248
|
});
|
|
469
|
-
let
|
|
470
|
-
|
|
471
|
-
duration:
|
|
472
|
-
delay:
|
|
249
|
+
let $;
|
|
250
|
+
x === "auto" ? ($ = a.transitions.getAutoHeightDuration(P.clientHeight), i.current = $) : $ = k, P.style.transition = [a.transitions.create("opacity", {
|
|
251
|
+
duration: $,
|
|
252
|
+
delay: D
|
|
473
253
|
}), a.transitions.create("transform", {
|
|
474
|
-
duration:
|
|
475
|
-
delay:
|
|
476
|
-
easing:
|
|
477
|
-
})].join(","), P.style.opacity = 0, P.style.transform =
|
|
478
|
-
}),
|
|
479
|
-
return /* @__PURE__ */
|
|
480
|
-
appear:
|
|
481
|
-
in:
|
|
482
|
-
nodeRef:
|
|
483
|
-
onEnter:
|
|
484
|
-
onEntered:
|
|
254
|
+
duration: _e ? $ : $ * 0.666,
|
|
255
|
+
delay: _e ? D : D || $ * 0.333,
|
|
256
|
+
easing: l
|
|
257
|
+
})].join(","), P.style.opacity = 0, P.style.transform = Ve(0.75), T && T(P);
|
|
258
|
+
}), F = m(w);
|
|
259
|
+
return /* @__PURE__ */ j(R, u({
|
|
260
|
+
appear: b,
|
|
261
|
+
in: c,
|
|
262
|
+
nodeRef: g,
|
|
263
|
+
onEnter: U,
|
|
264
|
+
onEntered: z,
|
|
485
265
|
onEntering: W,
|
|
486
|
-
onExit:
|
|
487
|
-
onExited:
|
|
266
|
+
onExit: A,
|
|
267
|
+
onExited: F,
|
|
488
268
|
onExiting: Y,
|
|
489
269
|
addEndListener: (P) => {
|
|
490
|
-
|
|
270
|
+
x === "auto" && N.start(i.current || 0, P), d && d(g.current, P);
|
|
491
271
|
},
|
|
492
|
-
timeout:
|
|
493
|
-
},
|
|
494
|
-
children: (P,
|
|
495
|
-
style:
|
|
272
|
+
timeout: x === "auto" ? null : x
|
|
273
|
+
}, p, {
|
|
274
|
+
children: (P, k) => /* @__PURE__ */ s.cloneElement(h, u({
|
|
275
|
+
style: u({
|
|
496
276
|
opacity: 0,
|
|
497
|
-
transform:
|
|
498
|
-
visibility: P === "exited" && !
|
|
499
|
-
},
|
|
500
|
-
ref:
|
|
501
|
-
},
|
|
277
|
+
transform: Ve(0.75),
|
|
278
|
+
visibility: P === "exited" && !c ? "hidden" : void 0
|
|
279
|
+
}, Zo[P], _, h.props.style),
|
|
280
|
+
ref: E
|
|
281
|
+
}, k))
|
|
502
282
|
}));
|
|
503
283
|
});
|
|
504
|
-
process.env.NODE_ENV !== "production" && (
|
|
284
|
+
process.env.NODE_ENV !== "production" && (We.propTypes = {
|
|
505
285
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
506
286
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
507
287
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -521,7 +301,7 @@ process.env.NODE_ENV !== "production" && (ze.propTypes = {
|
|
|
521
301
|
/**
|
|
522
302
|
* A single child content element.
|
|
523
303
|
*/
|
|
524
|
-
children:
|
|
304
|
+
children: $o.isRequired,
|
|
525
305
|
/**
|
|
526
306
|
* The transition timing function.
|
|
527
307
|
* You may specify a single easing or a object containing enter and exit values.
|
|
@@ -575,42 +355,42 @@ process.env.NODE_ENV !== "production" && (ze.propTypes = {
|
|
|
575
355
|
exit: e.number
|
|
576
356
|
})])
|
|
577
357
|
});
|
|
578
|
-
|
|
579
|
-
function
|
|
580
|
-
return
|
|
358
|
+
We.muiSupportAuto = !0;
|
|
359
|
+
function en(o) {
|
|
360
|
+
return ye("MuiPopover", o);
|
|
581
361
|
}
|
|
582
|
-
|
|
583
|
-
const
|
|
584
|
-
function
|
|
585
|
-
let
|
|
586
|
-
return typeof
|
|
362
|
+
ge("MuiPopover", ["root", "paper"]);
|
|
363
|
+
const on = ["onEntering"], nn = ["action", "anchorEl", "anchorOrigin", "anchorPosition", "anchorReference", "children", "className", "container", "elevation", "marginThreshold", "open", "PaperProps", "slots", "slotProps", "transformOrigin", "TransitionComponent", "transitionDuration", "TransitionProps", "disableScrollLock"], tn = ["slotProps"];
|
|
364
|
+
function eo(o, n) {
|
|
365
|
+
let t = 0;
|
|
366
|
+
return typeof n == "number" ? t = n : n === "center" ? t = o.height / 2 : n === "bottom" && (t = o.height), t;
|
|
587
367
|
}
|
|
588
|
-
function
|
|
589
|
-
let
|
|
590
|
-
return typeof
|
|
368
|
+
function oo(o, n) {
|
|
369
|
+
let t = 0;
|
|
370
|
+
return typeof n == "number" ? t = n : n === "center" ? t = o.width / 2 : n === "right" && (t = o.width), t;
|
|
591
371
|
}
|
|
592
|
-
function
|
|
593
|
-
return [o.horizontal, o.vertical].map((
|
|
372
|
+
function no(o) {
|
|
373
|
+
return [o.horizontal, o.vertical].map((n) => typeof n == "number" ? `${n}px` : n).join(" ");
|
|
594
374
|
}
|
|
595
|
-
function
|
|
375
|
+
function Ie(o) {
|
|
596
376
|
return typeof o == "function" ? o() : o;
|
|
597
377
|
}
|
|
598
|
-
const
|
|
378
|
+
const rn = (o) => {
|
|
599
379
|
const {
|
|
600
|
-
classes:
|
|
380
|
+
classes: n
|
|
601
381
|
} = o;
|
|
602
|
-
return
|
|
382
|
+
return ve({
|
|
603
383
|
root: ["root"],
|
|
604
384
|
paper: ["paper"]
|
|
605
|
-
},
|
|
606
|
-
},
|
|
385
|
+
}, en, n);
|
|
386
|
+
}, sn = H(To, {
|
|
607
387
|
name: "MuiPopover",
|
|
608
388
|
slot: "Root",
|
|
609
|
-
overridesResolver: (o,
|
|
610
|
-
})({}),
|
|
389
|
+
overridesResolver: (o, n) => n.root
|
|
390
|
+
})({}), co = H(Co, {
|
|
611
391
|
name: "MuiPopover",
|
|
612
392
|
slot: "Paper",
|
|
613
|
-
overridesResolver: (o,
|
|
393
|
+
overridesResolver: (o, n) => n.paper
|
|
614
394
|
})({
|
|
615
395
|
position: "absolute",
|
|
616
396
|
overflowY: "auto",
|
|
@@ -623,180 +403,180 @@ const vt = (o) => {
|
|
|
623
403
|
maxHeight: "calc(100% - 32px)",
|
|
624
404
|
// We disable the focus ring for mouse, touch and keyboard users.
|
|
625
405
|
outline: 0
|
|
626
|
-
}),
|
|
627
|
-
var
|
|
628
|
-
const
|
|
629
|
-
props:
|
|
406
|
+
}), po = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
407
|
+
var d, b, h;
|
|
408
|
+
const f = Me({
|
|
409
|
+
props: n,
|
|
630
410
|
name: "MuiPopover"
|
|
631
411
|
}), {
|
|
632
|
-
action:
|
|
633
|
-
anchorEl:
|
|
412
|
+
action: c,
|
|
413
|
+
anchorEl: y,
|
|
634
414
|
anchorOrigin: O = {
|
|
635
415
|
vertical: "top",
|
|
636
416
|
horizontal: "left"
|
|
637
417
|
},
|
|
638
|
-
anchorPosition:
|
|
639
|
-
anchorReference:
|
|
640
|
-
children:
|
|
641
|
-
className:
|
|
642
|
-
container:
|
|
643
|
-
elevation:
|
|
644
|
-
marginThreshold:
|
|
645
|
-
open:
|
|
646
|
-
PaperProps:
|
|
418
|
+
anchorPosition: I,
|
|
419
|
+
anchorReference: T = "anchorEl",
|
|
420
|
+
children: w,
|
|
421
|
+
className: C,
|
|
422
|
+
container: _,
|
|
423
|
+
elevation: x = 8,
|
|
424
|
+
marginThreshold: R = 16,
|
|
425
|
+
open: p,
|
|
426
|
+
PaperProps: N = {},
|
|
647
427
|
slots: i,
|
|
648
428
|
slotProps: a,
|
|
649
|
-
transformOrigin:
|
|
429
|
+
transformOrigin: g = {
|
|
650
430
|
vertical: "top",
|
|
651
431
|
horizontal: "left"
|
|
652
432
|
},
|
|
653
|
-
TransitionComponent:
|
|
654
|
-
transitionDuration:
|
|
433
|
+
TransitionComponent: E = We,
|
|
434
|
+
transitionDuration: m = "auto",
|
|
655
435
|
TransitionProps: {
|
|
656
436
|
onEntering: W
|
|
657
437
|
} = {},
|
|
658
|
-
disableScrollLock:
|
|
659
|
-
} =
|
|
438
|
+
disableScrollLock: U = !1
|
|
439
|
+
} = f, z = G(f.TransitionProps, on), Y = G(f, nn), A = (d = a == null ? void 0 : a.paper) != null ? d : N, F = s.useRef(), K = Pe(F, A.ref), P = u({}, f, {
|
|
660
440
|
anchorOrigin: O,
|
|
661
|
-
anchorReference:
|
|
662
|
-
elevation:
|
|
663
|
-
marginThreshold:
|
|
664
|
-
externalPaperSlotProps:
|
|
665
|
-
transformOrigin:
|
|
666
|
-
TransitionComponent:
|
|
667
|
-
transitionDuration:
|
|
668
|
-
TransitionProps:
|
|
669
|
-
}),
|
|
670
|
-
if (
|
|
671
|
-
return process.env.NODE_ENV !== "production" && (
|
|
672
|
-
const
|
|
441
|
+
anchorReference: T,
|
|
442
|
+
elevation: x,
|
|
443
|
+
marginThreshold: R,
|
|
444
|
+
externalPaperSlotProps: A,
|
|
445
|
+
transformOrigin: g,
|
|
446
|
+
TransitionComponent: E,
|
|
447
|
+
transitionDuration: m,
|
|
448
|
+
TransitionProps: z
|
|
449
|
+
}), k = rn(P), D = s.useCallback(() => {
|
|
450
|
+
if (T === "anchorPosition")
|
|
451
|
+
return process.env.NODE_ENV !== "production" && (I || console.error('MUI: You need to provide a `anchorPosition` prop when using <Popover anchorReference="anchorPosition" />.')), I;
|
|
452
|
+
const S = Ie(y), M = S && S.nodeType === 1 ? S : he(F.current).body, L = M.getBoundingClientRect();
|
|
673
453
|
if (process.env.NODE_ENV !== "production") {
|
|
674
|
-
const Q =
|
|
454
|
+
const Q = M.getBoundingClientRect();
|
|
675
455
|
process.env.NODE_ENV !== "test" && Q.top === 0 && Q.left === 0 && Q.right === 0 && Q.bottom === 0 && console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(`
|
|
676
456
|
`));
|
|
677
457
|
}
|
|
678
458
|
return {
|
|
679
|
-
top:
|
|
680
|
-
left:
|
|
459
|
+
top: L.top + eo(L, O.vertical),
|
|
460
|
+
left: L.left + oo(L, O.horizontal)
|
|
681
461
|
};
|
|
682
|
-
}, [
|
|
683
|
-
vertical:
|
|
684
|
-
horizontal:
|
|
685
|
-
}), [
|
|
686
|
-
const
|
|
687
|
-
width:
|
|
688
|
-
height:
|
|
689
|
-
},
|
|
690
|
-
if (
|
|
462
|
+
}, [y, O.horizontal, O.vertical, I, T]), l = s.useCallback((S) => ({
|
|
463
|
+
vertical: eo(S, g.vertical),
|
|
464
|
+
horizontal: oo(S, g.horizontal)
|
|
465
|
+
}), [g.horizontal, g.vertical]), $ = s.useCallback((S) => {
|
|
466
|
+
const M = {
|
|
467
|
+
width: S.offsetWidth,
|
|
468
|
+
height: S.offsetHeight
|
|
469
|
+
}, L = l(M);
|
|
470
|
+
if (T === "none")
|
|
691
471
|
return {
|
|
692
472
|
top: null,
|
|
693
473
|
left: null,
|
|
694
|
-
transformOrigin:
|
|
474
|
+
transformOrigin: no(L)
|
|
695
475
|
};
|
|
696
|
-
const Q =
|
|
697
|
-
let oe = Q.top -
|
|
698
|
-
const
|
|
699
|
-
if (
|
|
700
|
-
const B = oe -
|
|
701
|
-
oe -= B,
|
|
702
|
-
} else if (
|
|
703
|
-
const B =
|
|
704
|
-
oe -= B,
|
|
476
|
+
const Q = D();
|
|
477
|
+
let oe = Q.top - L.vertical, ne = Q.left - L.horizontal;
|
|
478
|
+
const re = oe + M.height, Ce = ne + M.width, Z = Ye(Ie(y)), te = Z.innerHeight - R, se = Z.innerWidth - R;
|
|
479
|
+
if (R !== null && oe < R) {
|
|
480
|
+
const B = oe - R;
|
|
481
|
+
oe -= B, L.vertical += B;
|
|
482
|
+
} else if (R !== null && re > te) {
|
|
483
|
+
const B = re - te;
|
|
484
|
+
oe -= B, L.vertical += B;
|
|
705
485
|
}
|
|
706
|
-
if (process.env.NODE_ENV !== "production" &&
|
|
707
|
-
`)),
|
|
708
|
-
const B =
|
|
709
|
-
|
|
710
|
-
} else if (
|
|
711
|
-
const B =
|
|
712
|
-
|
|
486
|
+
if (process.env.NODE_ENV !== "production" && M.height > te && M.height && te && console.error(["MUI: The popover component is too tall.", `Some part of it can not be seen on the screen (${M.height - te}px).`, "Please consider adding a `max-height` to improve the user-experience."].join(`
|
|
487
|
+
`)), R !== null && ne < R) {
|
|
488
|
+
const B = ne - R;
|
|
489
|
+
ne -= B, L.horizontal += B;
|
|
490
|
+
} else if (Ce > se) {
|
|
491
|
+
const B = Ce - se;
|
|
492
|
+
ne -= B, L.horizontal += B;
|
|
713
493
|
}
|
|
714
494
|
return {
|
|
715
495
|
top: `${Math.round(oe)}px`,
|
|
716
|
-
left: `${Math.round(
|
|
717
|
-
transformOrigin:
|
|
496
|
+
left: `${Math.round(ne)}px`,
|
|
497
|
+
transformOrigin: no(L)
|
|
718
498
|
};
|
|
719
|
-
}, [
|
|
720
|
-
const
|
|
721
|
-
if (!
|
|
499
|
+
}, [y, T, D, l, R]), [X, Ee] = s.useState(p), q = s.useCallback(() => {
|
|
500
|
+
const S = F.current;
|
|
501
|
+
if (!S)
|
|
722
502
|
return;
|
|
723
|
-
const
|
|
724
|
-
|
|
725
|
-
}, [
|
|
726
|
-
|
|
727
|
-
const J = (
|
|
728
|
-
W && W(
|
|
503
|
+
const M = $(S);
|
|
504
|
+
M.top !== null && (S.style.top = M.top), M.left !== null && (S.style.left = M.left), S.style.transformOrigin = M.transformOrigin, Ee(!0);
|
|
505
|
+
}, [$]);
|
|
506
|
+
s.useEffect(() => (U && window.addEventListener("scroll", q), () => window.removeEventListener("scroll", q)), [y, U, q]);
|
|
507
|
+
const J = (S, M) => {
|
|
508
|
+
W && W(S, M), q();
|
|
729
509
|
}, ee = () => {
|
|
730
|
-
|
|
510
|
+
Ee(!1);
|
|
731
511
|
};
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
}),
|
|
512
|
+
s.useEffect(() => {
|
|
513
|
+
p && q();
|
|
514
|
+
}), s.useImperativeHandle(c, () => p ? {
|
|
735
515
|
updatePosition: () => {
|
|
736
|
-
|
|
516
|
+
q();
|
|
737
517
|
}
|
|
738
|
-
} : null, [
|
|
739
|
-
if (!
|
|
518
|
+
} : null, [p, q]), s.useEffect(() => {
|
|
519
|
+
if (!p)
|
|
740
520
|
return;
|
|
741
|
-
const
|
|
742
|
-
|
|
743
|
-
}),
|
|
744
|
-
return
|
|
745
|
-
|
|
521
|
+
const S = Mo(() => {
|
|
522
|
+
q();
|
|
523
|
+
}), M = Ye(y);
|
|
524
|
+
return M.addEventListener("resize", S), () => {
|
|
525
|
+
S.clear(), M.removeEventListener("resize", S);
|
|
746
526
|
};
|
|
747
|
-
}, [
|
|
748
|
-
let
|
|
749
|
-
|
|
750
|
-
const
|
|
751
|
-
elementType:
|
|
752
|
-
externalSlotProps:
|
|
753
|
-
style: X ?
|
|
527
|
+
}, [y, p, q]);
|
|
528
|
+
let Oe = m;
|
|
529
|
+
m === "auto" && !E.muiSupportAuto && (Oe = void 0);
|
|
530
|
+
const ue = _ || (y ? he(Ie(y)).body : void 0), de = (b = i == null ? void 0 : i.root) != null ? b : sn, fe = (h = i == null ? void 0 : i.paper) != null ? h : co, Fe = Se({
|
|
531
|
+
elementType: fe,
|
|
532
|
+
externalSlotProps: u({}, A, {
|
|
533
|
+
style: X ? A.style : u({}, A.style, {
|
|
754
534
|
opacity: 0
|
|
755
535
|
})
|
|
756
536
|
}),
|
|
757
537
|
additionalProps: {
|
|
758
|
-
elevation:
|
|
538
|
+
elevation: x,
|
|
759
539
|
ref: K
|
|
760
540
|
},
|
|
761
541
|
ownerState: P,
|
|
762
|
-
className:
|
|
763
|
-
}),
|
|
764
|
-
elementType:
|
|
542
|
+
className: pe(k.paper, A == null ? void 0 : A.className)
|
|
543
|
+
}), Te = Se({
|
|
544
|
+
elementType: de,
|
|
765
545
|
externalSlotProps: (a == null ? void 0 : a.root) || {},
|
|
766
546
|
externalForwardedProps: Y,
|
|
767
547
|
additionalProps: {
|
|
768
|
-
ref:
|
|
548
|
+
ref: t,
|
|
769
549
|
slotProps: {
|
|
770
550
|
backdrop: {
|
|
771
551
|
invisible: !0
|
|
772
552
|
}
|
|
773
553
|
},
|
|
774
|
-
container:
|
|
775
|
-
open:
|
|
554
|
+
container: ue,
|
|
555
|
+
open: p
|
|
776
556
|
},
|
|
777
557
|
ownerState: P,
|
|
778
|
-
className:
|
|
558
|
+
className: pe(k.root, C)
|
|
779
559
|
}), {
|
|
780
|
-
slotProps:
|
|
781
|
-
} =
|
|
782
|
-
return /* @__PURE__ */
|
|
783
|
-
slotProps:
|
|
784
|
-
disableScrollLock:
|
|
560
|
+
slotProps: ae
|
|
561
|
+
} = Te, le = G(Te, tn);
|
|
562
|
+
return /* @__PURE__ */ j(de, u({}, le, !wo(de) && {
|
|
563
|
+
slotProps: ae,
|
|
564
|
+
disableScrollLock: U
|
|
785
565
|
}, {
|
|
786
|
-
children: /* @__PURE__ */
|
|
566
|
+
children: /* @__PURE__ */ j(E, u({
|
|
787
567
|
appear: !0,
|
|
788
|
-
in:
|
|
568
|
+
in: p,
|
|
789
569
|
onEntering: J,
|
|
790
570
|
onExited: ee,
|
|
791
|
-
timeout:
|
|
792
|
-
},
|
|
793
|
-
children: /* @__PURE__ */
|
|
794
|
-
children:
|
|
571
|
+
timeout: Oe
|
|
572
|
+
}, z, {
|
|
573
|
+
children: /* @__PURE__ */ j(fe, u({}, Fe, {
|
|
574
|
+
children: w
|
|
795
575
|
}))
|
|
796
576
|
}))
|
|
797
577
|
}));
|
|
798
578
|
});
|
|
799
|
-
process.env.NODE_ENV !== "production" && (
|
|
579
|
+
process.env.NODE_ENV !== "production" && (po.propTypes = {
|
|
800
580
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
801
581
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
802
582
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -805,22 +585,22 @@ process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
|
805
585
|
* A ref for imperative actions.
|
|
806
586
|
* It currently only supports updatePosition() action.
|
|
807
587
|
*/
|
|
808
|
-
action:
|
|
588
|
+
action: Ne,
|
|
809
589
|
/**
|
|
810
590
|
* An HTML element, [PopoverVirtualElement](/material-ui/react-popover/#virtual-element),
|
|
811
591
|
* or a function that returns either.
|
|
812
592
|
* It's used to set the position of the popover.
|
|
813
593
|
*/
|
|
814
|
-
anchorEl:
|
|
594
|
+
anchorEl: Po(e.oneOfType([Ae, e.func]), (o) => {
|
|
815
595
|
if (o.open && (!o.anchorReference || o.anchorReference === "anchorEl")) {
|
|
816
|
-
const
|
|
817
|
-
if (
|
|
818
|
-
const
|
|
819
|
-
if (process.env.NODE_ENV !== "test" &&
|
|
596
|
+
const n = Ie(o.anchorEl);
|
|
597
|
+
if (n && n.nodeType === 1) {
|
|
598
|
+
const t = n.getBoundingClientRect();
|
|
599
|
+
if (process.env.NODE_ENV !== "test" && t.top === 0 && t.left === 0 && t.right === 0 && t.bottom === 0)
|
|
820
600
|
return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(`
|
|
821
601
|
`));
|
|
822
602
|
} else
|
|
823
|
-
return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", `It should be an Element or PopoverVirtualElement instance but it's \`${
|
|
603
|
+
return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", `It should be an Element or PopoverVirtualElement instance but it's \`${n}\` instead.`].join(`
|
|
824
604
|
`));
|
|
825
605
|
}
|
|
826
606
|
return null;
|
|
@@ -875,7 +655,7 @@ process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
|
875
655
|
* By default, it uses the body of the anchorEl's top-level document object,
|
|
876
656
|
* so it's simply `document.body` most of the time.
|
|
877
657
|
*/
|
|
878
|
-
container: e.oneOfType([
|
|
658
|
+
container: e.oneOfType([Ae, e.func]),
|
|
879
659
|
/**
|
|
880
660
|
* Disable the scroll lock behavior.
|
|
881
661
|
* @default false
|
|
@@ -885,7 +665,7 @@ process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
|
885
665
|
* The elevation of the popover.
|
|
886
666
|
* @default 8
|
|
887
667
|
*/
|
|
888
|
-
elevation:
|
|
668
|
+
elevation: Ro,
|
|
889
669
|
/**
|
|
890
670
|
* Specifies how close to the edge of the window the popover can appear.
|
|
891
671
|
* If null, the popover will not be constrained by the window.
|
|
@@ -910,7 +690,7 @@ process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
|
910
690
|
* @default {}
|
|
911
691
|
*/
|
|
912
692
|
PaperProps: e.shape({
|
|
913
|
-
component:
|
|
693
|
+
component: xo
|
|
914
694
|
}),
|
|
915
695
|
/**
|
|
916
696
|
* The extra props for the slot components.
|
|
@@ -973,34 +753,34 @@ process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
|
973
753
|
*/
|
|
974
754
|
TransitionProps: e.object
|
|
975
755
|
});
|
|
976
|
-
function
|
|
977
|
-
return
|
|
756
|
+
function an(o) {
|
|
757
|
+
return ye("MuiMenu", o);
|
|
978
758
|
}
|
|
979
|
-
|
|
980
|
-
const
|
|
759
|
+
ge("MuiMenu", ["root", "paper", "list"]);
|
|
760
|
+
const ln = ["onEntering"], cn = ["autoFocus", "children", "className", "disableAutoFocusItem", "MenuListProps", "onClose", "open", "PaperProps", "PopoverClasses", "transitionDuration", "TransitionProps", "variant", "slots", "slotProps"], pn = {
|
|
981
761
|
vertical: "top",
|
|
982
762
|
horizontal: "right"
|
|
983
|
-
},
|
|
763
|
+
}, un = {
|
|
984
764
|
vertical: "top",
|
|
985
765
|
horizontal: "left"
|
|
986
|
-
},
|
|
766
|
+
}, dn = (o) => {
|
|
987
767
|
const {
|
|
988
|
-
classes:
|
|
768
|
+
classes: n
|
|
989
769
|
} = o;
|
|
990
|
-
return
|
|
770
|
+
return ve({
|
|
991
771
|
root: ["root"],
|
|
992
772
|
paper: ["paper"],
|
|
993
773
|
list: ["list"]
|
|
994
|
-
},
|
|
995
|
-
},
|
|
996
|
-
shouldForwardProp: (o) =>
|
|
774
|
+
}, an, n);
|
|
775
|
+
}, fn = H(po, {
|
|
776
|
+
shouldForwardProp: (o) => we(o) || o === "classes",
|
|
997
777
|
name: "MuiMenu",
|
|
998
778
|
slot: "Root",
|
|
999
|
-
overridesResolver: (o,
|
|
1000
|
-
})({}),
|
|
779
|
+
overridesResolver: (o, n) => n.root
|
|
780
|
+
})({}), mn = H(co, {
|
|
1001
781
|
name: "MuiMenu",
|
|
1002
782
|
slot: "Paper",
|
|
1003
|
-
overridesResolver: (o,
|
|
783
|
+
overridesResolver: (o, n) => n.paper
|
|
1004
784
|
})({
|
|
1005
785
|
// specZ: The maximum height of a simple menu should be one or more rows less than the view
|
|
1006
786
|
// height. This ensures a tappable area outside of the simple menu with which to dismiss
|
|
@@ -1008,104 +788,104 @@ const Pt = ["onEntering"], Et = ["autoFocus", "children", "className", "disableA
|
|
|
1008
788
|
maxHeight: "calc(100% - 96px)",
|
|
1009
789
|
// Add iOS momentum scrolling for iOS < 13.0
|
|
1010
790
|
WebkitOverflowScrolling: "touch"
|
|
1011
|
-
}),
|
|
791
|
+
}), bn = H(lo, {
|
|
1012
792
|
name: "MuiMenu",
|
|
1013
793
|
slot: "List",
|
|
1014
|
-
overridesResolver: (o,
|
|
794
|
+
overridesResolver: (o, n) => n.list
|
|
1015
795
|
})({
|
|
1016
796
|
// We disable the focus ring for mouse, touch and keyboard users.
|
|
1017
797
|
outline: 0
|
|
1018
|
-
}),
|
|
1019
|
-
var
|
|
1020
|
-
const
|
|
1021
|
-
props:
|
|
798
|
+
}), uo = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
799
|
+
var d, b;
|
|
800
|
+
const h = Me({
|
|
801
|
+
props: n,
|
|
1022
802
|
name: "MuiMenu"
|
|
1023
803
|
}), {
|
|
1024
|
-
autoFocus:
|
|
1025
|
-
children:
|
|
1026
|
-
className:
|
|
804
|
+
autoFocus: f = !0,
|
|
805
|
+
children: c,
|
|
806
|
+
className: y,
|
|
1027
807
|
disableAutoFocusItem: O = !1,
|
|
1028
|
-
MenuListProps:
|
|
1029
|
-
onClose:
|
|
1030
|
-
open:
|
|
1031
|
-
PaperProps:
|
|
1032
|
-
PopoverClasses:
|
|
1033
|
-
transitionDuration:
|
|
808
|
+
MenuListProps: I = {},
|
|
809
|
+
onClose: T,
|
|
810
|
+
open: w,
|
|
811
|
+
PaperProps: C = {},
|
|
812
|
+
PopoverClasses: _,
|
|
813
|
+
transitionDuration: x = "auto",
|
|
1034
814
|
TransitionProps: {
|
|
1035
|
-
onEntering:
|
|
815
|
+
onEntering: R
|
|
1036
816
|
} = {},
|
|
1037
|
-
variant:
|
|
1038
|
-
slots:
|
|
817
|
+
variant: p = "selectedMenu",
|
|
818
|
+
slots: N = {},
|
|
1039
819
|
slotProps: i = {}
|
|
1040
|
-
} =
|
|
1041
|
-
autoFocus:
|
|
820
|
+
} = h, a = G(h.TransitionProps, ln), g = G(h, cn), E = Yo(), m = u({}, h, {
|
|
821
|
+
autoFocus: f,
|
|
1042
822
|
disableAutoFocusItem: O,
|
|
1043
|
-
MenuListProps:
|
|
1044
|
-
onEntering:
|
|
1045
|
-
PaperProps:
|
|
1046
|
-
transitionDuration:
|
|
823
|
+
MenuListProps: I,
|
|
824
|
+
onEntering: R,
|
|
825
|
+
PaperProps: C,
|
|
826
|
+
transitionDuration: x,
|
|
1047
827
|
TransitionProps: a,
|
|
1048
|
-
variant:
|
|
1049
|
-
}), W =
|
|
1050
|
-
|
|
1051
|
-
direction:
|
|
1052
|
-
}),
|
|
1053
|
-
},
|
|
1054
|
-
|
|
828
|
+
variant: p
|
|
829
|
+
}), W = dn(m), U = f && !O && w, z = s.useRef(null), Y = (l, $) => {
|
|
830
|
+
z.current && z.current.adjustStyleForScrollbar(l, {
|
|
831
|
+
direction: E ? "rtl" : "ltr"
|
|
832
|
+
}), R && R(l, $);
|
|
833
|
+
}, A = (l) => {
|
|
834
|
+
l.key === "Tab" && (l.preventDefault(), T && T(l, "tabKeyDown"));
|
|
1055
835
|
};
|
|
1056
|
-
let
|
|
1057
|
-
|
|
1058
|
-
/* @__PURE__ */
|
|
1059
|
-
`)),
|
|
836
|
+
let F = -1;
|
|
837
|
+
s.Children.map(c, (l, $) => {
|
|
838
|
+
/* @__PURE__ */ s.isValidElement(l) && (process.env.NODE_ENV !== "production" && Be.isFragment(l) && console.error(["MUI: The Menu component doesn't accept a Fragment as a child.", "Consider providing an array instead."].join(`
|
|
839
|
+
`)), l.props.disabled || (p === "selectedMenu" && l.props.selected || F === -1) && (F = $));
|
|
1060
840
|
});
|
|
1061
|
-
const K = (
|
|
1062
|
-
elementType:
|
|
841
|
+
const K = (d = N.paper) != null ? d : mn, P = (b = i.paper) != null ? b : C, k = Se({
|
|
842
|
+
elementType: N.root,
|
|
1063
843
|
externalSlotProps: i.root,
|
|
1064
|
-
ownerState:
|
|
1065
|
-
className: [W.root,
|
|
1066
|
-
}),
|
|
844
|
+
ownerState: m,
|
|
845
|
+
className: [W.root, y]
|
|
846
|
+
}), D = Se({
|
|
1067
847
|
elementType: K,
|
|
1068
848
|
externalSlotProps: P,
|
|
1069
|
-
ownerState:
|
|
849
|
+
ownerState: m,
|
|
1070
850
|
className: W.paper
|
|
1071
851
|
});
|
|
1072
|
-
return /* @__PURE__ */
|
|
1073
|
-
onClose:
|
|
852
|
+
return /* @__PURE__ */ j(fn, u({
|
|
853
|
+
onClose: T,
|
|
1074
854
|
anchorOrigin: {
|
|
1075
855
|
vertical: "bottom",
|
|
1076
|
-
horizontal:
|
|
856
|
+
horizontal: E ? "right" : "left"
|
|
1077
857
|
},
|
|
1078
|
-
transformOrigin:
|
|
858
|
+
transformOrigin: E ? pn : un,
|
|
1079
859
|
slots: {
|
|
1080
860
|
paper: K,
|
|
1081
|
-
root:
|
|
861
|
+
root: N.root
|
|
1082
862
|
},
|
|
1083
863
|
slotProps: {
|
|
1084
|
-
root:
|
|
1085
|
-
paper:
|
|
864
|
+
root: k,
|
|
865
|
+
paper: D
|
|
1086
866
|
},
|
|
1087
|
-
open:
|
|
1088
|
-
ref:
|
|
1089
|
-
transitionDuration:
|
|
1090
|
-
TransitionProps:
|
|
867
|
+
open: w,
|
|
868
|
+
ref: t,
|
|
869
|
+
transitionDuration: x,
|
|
870
|
+
TransitionProps: u({
|
|
1091
871
|
onEntering: Y
|
|
1092
872
|
}, a),
|
|
1093
|
-
ownerState:
|
|
1094
|
-
},
|
|
1095
|
-
classes:
|
|
1096
|
-
children: /* @__PURE__ */
|
|
1097
|
-
onKeyDown:
|
|
1098
|
-
actions:
|
|
1099
|
-
autoFocus:
|
|
1100
|
-
autoFocusItem:
|
|
1101
|
-
variant:
|
|
1102
|
-
},
|
|
1103
|
-
className:
|
|
1104
|
-
children:
|
|
873
|
+
ownerState: m
|
|
874
|
+
}, g, {
|
|
875
|
+
classes: _,
|
|
876
|
+
children: /* @__PURE__ */ j(bn, u({
|
|
877
|
+
onKeyDown: A,
|
|
878
|
+
actions: z,
|
|
879
|
+
autoFocus: f && (F === -1 || O),
|
|
880
|
+
autoFocusItem: U,
|
|
881
|
+
variant: p
|
|
882
|
+
}, I, {
|
|
883
|
+
className: pe(W.list, I.className),
|
|
884
|
+
children: c
|
|
1105
885
|
}))
|
|
1106
886
|
}));
|
|
1107
887
|
});
|
|
1108
|
-
process.env.NODE_ENV !== "production" && (
|
|
888
|
+
process.env.NODE_ENV !== "production" && (uo.propTypes = {
|
|
1109
889
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
1110
890
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
1111
891
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -1114,7 +894,7 @@ process.env.NODE_ENV !== "production" && (yo.propTypes = {
|
|
|
1114
894
|
* An HTML element, or a function that returns one.
|
|
1115
895
|
* It's used to set the position of the menu.
|
|
1116
896
|
*/
|
|
1117
|
-
anchorEl: e.oneOfType([
|
|
897
|
+
anchorEl: e.oneOfType([Ae, e.func]),
|
|
1118
898
|
/**
|
|
1119
899
|
* If `true` (Default) will focus the `[role="menu"]` if no focusable child is found. Disabled
|
|
1120
900
|
* children are not focusable. If you set this prop to `false` focus will be placed
|
|
@@ -1211,26 +991,26 @@ process.env.NODE_ENV !== "production" && (yo.propTypes = {
|
|
|
1211
991
|
*/
|
|
1212
992
|
variant: e.oneOf(["menu", "selectedMenu"])
|
|
1213
993
|
});
|
|
1214
|
-
function
|
|
1215
|
-
return
|
|
994
|
+
function hn(o) {
|
|
995
|
+
return ye("MuiNativeSelect", o);
|
|
1216
996
|
}
|
|
1217
|
-
const
|
|
997
|
+
const Ue = ge("MuiNativeSelect", ["root", "select", "multiple", "filled", "outlined", "standard", "disabled", "icon", "iconOpen", "iconFilled", "iconOutlined", "iconStandard", "nativeInput", "error"]), gn = ["className", "disabled", "error", "IconComponent", "inputRef", "variant"], vn = (o) => {
|
|
1218
998
|
const {
|
|
1219
|
-
classes:
|
|
1220
|
-
variant:
|
|
1221
|
-
disabled:
|
|
1222
|
-
multiple:
|
|
1223
|
-
open:
|
|
1224
|
-
error:
|
|
1225
|
-
} = o,
|
|
1226
|
-
select: ["select",
|
|
1227
|
-
icon: ["icon", `icon${
|
|
999
|
+
classes: n,
|
|
1000
|
+
variant: t,
|
|
1001
|
+
disabled: d,
|
|
1002
|
+
multiple: b,
|
|
1003
|
+
open: h,
|
|
1004
|
+
error: f
|
|
1005
|
+
} = o, c = {
|
|
1006
|
+
select: ["select", t, d && "disabled", b && "multiple", f && "error"],
|
|
1007
|
+
icon: ["icon", `icon${xe(t)}`, h && "iconOpen", d && "disabled"]
|
|
1228
1008
|
};
|
|
1229
|
-
return
|
|
1230
|
-
},
|
|
1009
|
+
return ve(c, hn, n);
|
|
1010
|
+
}, fo = ({
|
|
1231
1011
|
ownerState: o,
|
|
1232
|
-
theme:
|
|
1233
|
-
}) =>
|
|
1012
|
+
theme: n
|
|
1013
|
+
}) => u({
|
|
1234
1014
|
MozAppearance: "none",
|
|
1235
1015
|
// Reset
|
|
1236
1016
|
WebkitAppearance: "none",
|
|
@@ -1241,10 +1021,10 @@ const He = le("MuiNativeSelect", ["root", "select", "multiple", "filled", "outli
|
|
|
1241
1021
|
borderRadius: 0,
|
|
1242
1022
|
// Reset
|
|
1243
1023
|
cursor: "pointer",
|
|
1244
|
-
"&:focus":
|
|
1245
|
-
backgroundColor: `rgba(${
|
|
1024
|
+
"&:focus": u({}, n.vars ? {
|
|
1025
|
+
backgroundColor: `rgba(${n.vars.palette.common.onBackgroundChannel} / 0.05)`
|
|
1246
1026
|
} : {
|
|
1247
|
-
backgroundColor:
|
|
1027
|
+
backgroundColor: n.palette.mode === "light" ? "rgba(0, 0, 0, 0.05)" : "rgba(255, 255, 255, 0.05)"
|
|
1248
1028
|
}, {
|
|
1249
1029
|
borderRadius: 0
|
|
1250
1030
|
// Reset Chrome style
|
|
@@ -1253,14 +1033,14 @@ const He = le("MuiNativeSelect", ["root", "select", "multiple", "filled", "outli
|
|
|
1253
1033
|
"&::-ms-expand": {
|
|
1254
1034
|
display: "none"
|
|
1255
1035
|
},
|
|
1256
|
-
[`&.${
|
|
1036
|
+
[`&.${Ue.disabled}`]: {
|
|
1257
1037
|
cursor: "default"
|
|
1258
1038
|
},
|
|
1259
1039
|
"&[multiple]": {
|
|
1260
1040
|
height: "auto"
|
|
1261
1041
|
},
|
|
1262
1042
|
"&:not([multiple]) option, &:not([multiple]) optgroup": {
|
|
1263
|
-
backgroundColor: (
|
|
1043
|
+
backgroundColor: (n.vars || n).palette.background.paper
|
|
1264
1044
|
},
|
|
1265
1045
|
// Bump specificity to allow extending custom inputs
|
|
1266
1046
|
"&&&": {
|
|
@@ -1273,30 +1053,30 @@ const He = le("MuiNativeSelect", ["root", "select", "multiple", "filled", "outli
|
|
|
1273
1053
|
paddingRight: 32
|
|
1274
1054
|
}
|
|
1275
1055
|
}, o.variant === "outlined" && {
|
|
1276
|
-
borderRadius: (
|
|
1056
|
+
borderRadius: (n.vars || n).shape.borderRadius,
|
|
1277
1057
|
"&:focus": {
|
|
1278
|
-
borderRadius: (
|
|
1058
|
+
borderRadius: (n.vars || n).shape.borderRadius
|
|
1279
1059
|
// Reset the reset for Chrome style
|
|
1280
1060
|
},
|
|
1281
1061
|
"&&&": {
|
|
1282
1062
|
paddingRight: 32
|
|
1283
1063
|
}
|
|
1284
|
-
}),
|
|
1064
|
+
}), yn = H("select", {
|
|
1285
1065
|
name: "MuiNativeSelect",
|
|
1286
1066
|
slot: "Select",
|
|
1287
|
-
shouldForwardProp:
|
|
1288
|
-
overridesResolver: (o,
|
|
1067
|
+
shouldForwardProp: we,
|
|
1068
|
+
overridesResolver: (o, n) => {
|
|
1289
1069
|
const {
|
|
1290
|
-
ownerState:
|
|
1070
|
+
ownerState: t
|
|
1291
1071
|
} = o;
|
|
1292
|
-
return [
|
|
1293
|
-
[`&.${
|
|
1072
|
+
return [n.select, n[t.variant], t.error && n.error, {
|
|
1073
|
+
[`&.${Ue.multiple}`]: n.multiple
|
|
1294
1074
|
}];
|
|
1295
1075
|
}
|
|
1296
|
-
})(
|
|
1076
|
+
})(fo), mo = ({
|
|
1297
1077
|
ownerState: o,
|
|
1298
|
-
theme:
|
|
1299
|
-
}) =>
|
|
1078
|
+
theme: n
|
|
1079
|
+
}) => u({
|
|
1300
1080
|
// We use a position absolute over a flexbox in order to forward the pointer events
|
|
1301
1081
|
// to the input and to support wrapping tags..
|
|
1302
1082
|
position: "absolute",
|
|
@@ -1305,9 +1085,9 @@ const He = le("MuiNativeSelect", ["root", "select", "multiple", "filled", "outli
|
|
|
1305
1085
|
// Center vertically, height is 1em
|
|
1306
1086
|
pointerEvents: "none",
|
|
1307
1087
|
// Don't block pointer events on the select under the icon.
|
|
1308
|
-
color: (
|
|
1309
|
-
[`&.${
|
|
1310
|
-
color: (
|
|
1088
|
+
color: (n.vars || n).palette.action.active,
|
|
1089
|
+
[`&.${Ue.disabled}`]: {
|
|
1090
|
+
color: (n.vars || n).palette.action.disabled
|
|
1311
1091
|
}
|
|
1312
1092
|
}, o.open && {
|
|
1313
1093
|
transform: "rotate(180deg)"
|
|
@@ -1315,42 +1095,42 @@ const He = le("MuiNativeSelect", ["root", "select", "multiple", "filled", "outli
|
|
|
1315
1095
|
right: 7
|
|
1316
1096
|
}, o.variant === "outlined" && {
|
|
1317
1097
|
right: 7
|
|
1318
|
-
}),
|
|
1098
|
+
}), Pn = H("svg", {
|
|
1319
1099
|
name: "MuiNativeSelect",
|
|
1320
1100
|
slot: "Icon",
|
|
1321
|
-
overridesResolver: (o,
|
|
1101
|
+
overridesResolver: (o, n) => {
|
|
1322
1102
|
const {
|
|
1323
|
-
ownerState:
|
|
1103
|
+
ownerState: t
|
|
1324
1104
|
} = o;
|
|
1325
|
-
return [
|
|
1105
|
+
return [n.icon, t.variant && n[`icon${xe(t.variant)}`], t.open && n.iconOpen];
|
|
1326
1106
|
}
|
|
1327
|
-
})(
|
|
1107
|
+
})(mo), bo = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
1328
1108
|
const {
|
|
1329
|
-
className:
|
|
1330
|
-
disabled:
|
|
1331
|
-
error:
|
|
1332
|
-
IconComponent:
|
|
1333
|
-
inputRef:
|
|
1334
|
-
variant:
|
|
1335
|
-
} =
|
|
1336
|
-
disabled:
|
|
1337
|
-
variant:
|
|
1338
|
-
error:
|
|
1339
|
-
}),
|
|
1340
|
-
return /* @__PURE__ */
|
|
1341
|
-
children: [/* @__PURE__ */
|
|
1342
|
-
ownerState:
|
|
1343
|
-
className:
|
|
1344
|
-
disabled:
|
|
1345
|
-
ref:
|
|
1346
|
-
}, O)),
|
|
1347
|
-
as:
|
|
1348
|
-
ownerState:
|
|
1349
|
-
className:
|
|
1109
|
+
className: d,
|
|
1110
|
+
disabled: b,
|
|
1111
|
+
error: h,
|
|
1112
|
+
IconComponent: f,
|
|
1113
|
+
inputRef: c,
|
|
1114
|
+
variant: y = "standard"
|
|
1115
|
+
} = n, O = G(n, gn), I = u({}, n, {
|
|
1116
|
+
disabled: b,
|
|
1117
|
+
variant: y,
|
|
1118
|
+
error: h
|
|
1119
|
+
}), T = vn(I);
|
|
1120
|
+
return /* @__PURE__ */ io(s.Fragment, {
|
|
1121
|
+
children: [/* @__PURE__ */ j(yn, u({
|
|
1122
|
+
ownerState: I,
|
|
1123
|
+
className: pe(T.select, d),
|
|
1124
|
+
disabled: b,
|
|
1125
|
+
ref: c || t
|
|
1126
|
+
}, O)), n.multiple ? null : /* @__PURE__ */ j(Pn, {
|
|
1127
|
+
as: f,
|
|
1128
|
+
ownerState: I,
|
|
1129
|
+
className: T.icon
|
|
1350
1130
|
})]
|
|
1351
1131
|
});
|
|
1352
1132
|
});
|
|
1353
|
-
process.env.NODE_ENV !== "production" && (
|
|
1133
|
+
process.env.NODE_ENV !== "production" && (bo.propTypes = {
|
|
1354
1134
|
/**
|
|
1355
1135
|
* The option elements to populate the select with.
|
|
1356
1136
|
* Can be some `<option>` elements.
|
|
@@ -1380,7 +1160,7 @@ process.env.NODE_ENV !== "production" && (Co.propTypes = {
|
|
|
1380
1160
|
* Use that prop to pass a ref to the native select element.
|
|
1381
1161
|
* @deprecated
|
|
1382
1162
|
*/
|
|
1383
|
-
inputRef:
|
|
1163
|
+
inputRef: Ne,
|
|
1384
1164
|
/**
|
|
1385
1165
|
* @ignore
|
|
1386
1166
|
*/
|
|
@@ -1405,37 +1185,37 @@ process.env.NODE_ENV !== "production" && (Co.propTypes = {
|
|
|
1405
1185
|
*/
|
|
1406
1186
|
variant: e.oneOf(["standard", "outlined", "filled"])
|
|
1407
1187
|
});
|
|
1408
|
-
function
|
|
1409
|
-
return
|
|
1188
|
+
function En(o) {
|
|
1189
|
+
return ye("MuiSelect", o);
|
|
1410
1190
|
}
|
|
1411
|
-
const
|
|
1412
|
-
var
|
|
1413
|
-
const
|
|
1191
|
+
const be = ge("MuiSelect", ["root", "select", "multiple", "filled", "outlined", "standard", "disabled", "focused", "icon", "iconOpen", "iconFilled", "iconOutlined", "iconStandard", "nativeInput", "error"]);
|
|
1192
|
+
var to;
|
|
1193
|
+
const On = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "children", "className", "defaultOpen", "defaultValue", "disabled", "displayEmpty", "error", "IconComponent", "inputRef", "labelId", "MenuProps", "multiple", "name", "onBlur", "onChange", "onClose", "onFocus", "onOpen", "open", "readOnly", "renderValue", "SelectDisplayProps", "tabIndex", "type", "value", "variant"], Tn = H("div", {
|
|
1414
1194
|
name: "MuiSelect",
|
|
1415
1195
|
slot: "Select",
|
|
1416
|
-
overridesResolver: (o,
|
|
1196
|
+
overridesResolver: (o, n) => {
|
|
1417
1197
|
const {
|
|
1418
|
-
ownerState:
|
|
1198
|
+
ownerState: t
|
|
1419
1199
|
} = o;
|
|
1420
1200
|
return [
|
|
1421
1201
|
// Win specificity over the input base
|
|
1422
1202
|
{
|
|
1423
|
-
[`&.${
|
|
1203
|
+
[`&.${be.select}`]: n.select
|
|
1424
1204
|
},
|
|
1425
1205
|
{
|
|
1426
|
-
[`&.${
|
|
1206
|
+
[`&.${be.select}`]: n[t.variant]
|
|
1427
1207
|
},
|
|
1428
1208
|
{
|
|
1429
|
-
[`&.${
|
|
1209
|
+
[`&.${be.error}`]: n.error
|
|
1430
1210
|
},
|
|
1431
1211
|
{
|
|
1432
|
-
[`&.${
|
|
1212
|
+
[`&.${be.multiple}`]: n.multiple
|
|
1433
1213
|
}
|
|
1434
1214
|
];
|
|
1435
1215
|
}
|
|
1436
|
-
})(
|
|
1216
|
+
})(fo, {
|
|
1437
1217
|
// Win specificity over the input base
|
|
1438
|
-
[`&.${
|
|
1218
|
+
[`&.${be.select}`]: {
|
|
1439
1219
|
height: "auto",
|
|
1440
1220
|
// Resets for multiple select with chips
|
|
1441
1221
|
minHeight: "1.4375em",
|
|
@@ -1444,20 +1224,20 @@ const Dt = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "childre
|
|
|
1444
1224
|
whiteSpace: "nowrap",
|
|
1445
1225
|
overflow: "hidden"
|
|
1446
1226
|
}
|
|
1447
|
-
}),
|
|
1227
|
+
}), Cn = H("svg", {
|
|
1448
1228
|
name: "MuiSelect",
|
|
1449
1229
|
slot: "Icon",
|
|
1450
|
-
overridesResolver: (o,
|
|
1230
|
+
overridesResolver: (o, n) => {
|
|
1451
1231
|
const {
|
|
1452
|
-
ownerState:
|
|
1232
|
+
ownerState: t
|
|
1453
1233
|
} = o;
|
|
1454
|
-
return [
|
|
1234
|
+
return [n.icon, t.variant && n[`icon${xe(t.variant)}`], t.open && n.iconOpen];
|
|
1455
1235
|
}
|
|
1456
|
-
})(
|
|
1457
|
-
shouldForwardProp: (o) =>
|
|
1236
|
+
})(mo), Rn = H("input", {
|
|
1237
|
+
shouldForwardProp: (o) => Eo(o) && o !== "classes",
|
|
1458
1238
|
name: "MuiSelect",
|
|
1459
1239
|
slot: "NativeInput",
|
|
1460
|
-
overridesResolver: (o,
|
|
1240
|
+
overridesResolver: (o, n) => n.nativeInput
|
|
1461
1241
|
})({
|
|
1462
1242
|
bottom: 0,
|
|
1463
1243
|
left: 0,
|
|
@@ -1467,125 +1247,125 @@ const Dt = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "childre
|
|
|
1467
1247
|
width: "100%",
|
|
1468
1248
|
boxSizing: "border-box"
|
|
1469
1249
|
});
|
|
1470
|
-
function
|
|
1471
|
-
return typeof
|
|
1250
|
+
function ro(o, n) {
|
|
1251
|
+
return typeof n == "object" && n !== null ? o === n : String(o) === String(n);
|
|
1472
1252
|
}
|
|
1473
|
-
function
|
|
1253
|
+
function In(o) {
|
|
1474
1254
|
return o == null || typeof o == "string" && !o.trim();
|
|
1475
1255
|
}
|
|
1476
|
-
const
|
|
1256
|
+
const Sn = (o) => {
|
|
1477
1257
|
const {
|
|
1478
|
-
classes:
|
|
1479
|
-
variant:
|
|
1480
|
-
disabled:
|
|
1481
|
-
multiple:
|
|
1482
|
-
open:
|
|
1483
|
-
error:
|
|
1484
|
-
} = o,
|
|
1485
|
-
select: ["select",
|
|
1486
|
-
icon: ["icon", `icon${
|
|
1258
|
+
classes: n,
|
|
1259
|
+
variant: t,
|
|
1260
|
+
disabled: d,
|
|
1261
|
+
multiple: b,
|
|
1262
|
+
open: h,
|
|
1263
|
+
error: f
|
|
1264
|
+
} = o, c = {
|
|
1265
|
+
select: ["select", t, d && "disabled", b && "multiple", f && "error"],
|
|
1266
|
+
icon: ["icon", `icon${xe(t)}`, h && "iconOpen", d && "disabled"],
|
|
1487
1267
|
nativeInput: ["nativeInput"]
|
|
1488
1268
|
};
|
|
1489
|
-
return
|
|
1490
|
-
},
|
|
1491
|
-
var
|
|
1269
|
+
return ve(c, En, n);
|
|
1270
|
+
}, ho = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
1271
|
+
var d;
|
|
1492
1272
|
const {
|
|
1493
|
-
"aria-describedby":
|
|
1494
|
-
"aria-label":
|
|
1495
|
-
autoFocus:
|
|
1496
|
-
autoWidth:
|
|
1497
|
-
children:
|
|
1273
|
+
"aria-describedby": b,
|
|
1274
|
+
"aria-label": h,
|
|
1275
|
+
autoFocus: f,
|
|
1276
|
+
autoWidth: c,
|
|
1277
|
+
children: y,
|
|
1498
1278
|
className: O,
|
|
1499
|
-
defaultOpen:
|
|
1500
|
-
defaultValue:
|
|
1501
|
-
disabled:
|
|
1502
|
-
displayEmpty:
|
|
1503
|
-
error:
|
|
1504
|
-
IconComponent:
|
|
1505
|
-
inputRef:
|
|
1506
|
-
labelId:
|
|
1507
|
-
MenuProps:
|
|
1279
|
+
defaultOpen: I,
|
|
1280
|
+
defaultValue: T,
|
|
1281
|
+
disabled: w,
|
|
1282
|
+
displayEmpty: C,
|
|
1283
|
+
error: _ = !1,
|
|
1284
|
+
IconComponent: x,
|
|
1285
|
+
inputRef: R,
|
|
1286
|
+
labelId: p,
|
|
1287
|
+
MenuProps: N = {},
|
|
1508
1288
|
multiple: i,
|
|
1509
1289
|
name: a,
|
|
1510
|
-
onBlur:
|
|
1511
|
-
onChange:
|
|
1512
|
-
onClose:
|
|
1290
|
+
onBlur: g,
|
|
1291
|
+
onChange: E,
|
|
1292
|
+
onClose: m,
|
|
1513
1293
|
onFocus: W,
|
|
1514
|
-
onOpen:
|
|
1515
|
-
open:
|
|
1294
|
+
onOpen: U,
|
|
1295
|
+
open: z,
|
|
1516
1296
|
readOnly: Y,
|
|
1517
|
-
renderValue:
|
|
1518
|
-
SelectDisplayProps:
|
|
1297
|
+
renderValue: A,
|
|
1298
|
+
SelectDisplayProps: F = {},
|
|
1519
1299
|
tabIndex: K,
|
|
1520
1300
|
value: P,
|
|
1521
|
-
variant:
|
|
1522
|
-
} =
|
|
1301
|
+
variant: k = "standard"
|
|
1302
|
+
} = n, D = G(n, On), [l, $] = Qe({
|
|
1523
1303
|
controlled: P,
|
|
1524
|
-
default:
|
|
1304
|
+
default: T,
|
|
1525
1305
|
name: "Select"
|
|
1526
|
-
}), [X,
|
|
1527
|
-
controlled:
|
|
1528
|
-
default:
|
|
1306
|
+
}), [X, Ee] = Qe({
|
|
1307
|
+
controlled: z,
|
|
1308
|
+
default: I,
|
|
1529
1309
|
name: "Select"
|
|
1530
|
-
}),
|
|
1531
|
-
current:
|
|
1532
|
-
} =
|
|
1533
|
-
J.current =
|
|
1534
|
-
}, []),
|
|
1535
|
-
|
|
1310
|
+
}), q = s.useRef(null), J = s.useRef(null), [ee, Oe] = s.useState(null), {
|
|
1311
|
+
current: ue
|
|
1312
|
+
} = s.useRef(z != null), [de, fe] = s.useState(), Fe = Pe(t, R), Te = s.useCallback((r) => {
|
|
1313
|
+
J.current = r, r && Oe(r);
|
|
1314
|
+
}, []), ae = ee == null ? void 0 : ee.parentNode;
|
|
1315
|
+
s.useImperativeHandle(Fe, () => ({
|
|
1536
1316
|
focus: () => {
|
|
1537
1317
|
J.current.focus();
|
|
1538
1318
|
},
|
|
1539
|
-
node:
|
|
1540
|
-
value:
|
|
1541
|
-
}), [
|
|
1542
|
-
|
|
1543
|
-
}, [ee,
|
|
1544
|
-
|
|
1545
|
-
}, [
|
|
1546
|
-
if (!
|
|
1319
|
+
node: q.current,
|
|
1320
|
+
value: l
|
|
1321
|
+
}), [l]), s.useEffect(() => {
|
|
1322
|
+
I && X && ee && !ue && (fe(c ? null : ae.clientWidth), J.current.focus());
|
|
1323
|
+
}, [ee, c]), s.useEffect(() => {
|
|
1324
|
+
f && J.current.focus();
|
|
1325
|
+
}, [f]), s.useEffect(() => {
|
|
1326
|
+
if (!p)
|
|
1547
1327
|
return;
|
|
1548
|
-
const
|
|
1549
|
-
if (
|
|
1550
|
-
const
|
|
1328
|
+
const r = he(J.current).getElementById(p);
|
|
1329
|
+
if (r) {
|
|
1330
|
+
const v = () => {
|
|
1551
1331
|
getSelection().isCollapsed && J.current.focus();
|
|
1552
1332
|
};
|
|
1553
|
-
return
|
|
1554
|
-
|
|
1333
|
+
return r.addEventListener("click", v), () => {
|
|
1334
|
+
r.removeEventListener("click", v);
|
|
1555
1335
|
};
|
|
1556
1336
|
}
|
|
1557
|
-
}, [
|
|
1558
|
-
const
|
|
1559
|
-
|
|
1560
|
-
},
|
|
1561
|
-
|
|
1562
|
-
},
|
|
1563
|
-
|
|
1564
|
-
},
|
|
1565
|
-
const
|
|
1566
|
-
|
|
1567
|
-
}, oe = (
|
|
1568
|
-
let
|
|
1569
|
-
if (
|
|
1337
|
+
}, [p]);
|
|
1338
|
+
const le = (r, v) => {
|
|
1339
|
+
r ? U && U(v) : m && m(v), ue || (fe(c ? null : ae.clientWidth), Ee(r));
|
|
1340
|
+
}, S = (r) => {
|
|
1341
|
+
r.button === 0 && (r.preventDefault(), J.current.focus(), le(!0, r));
|
|
1342
|
+
}, M = (r) => {
|
|
1343
|
+
le(!1, r);
|
|
1344
|
+
}, L = s.Children.toArray(y), Q = (r) => {
|
|
1345
|
+
const v = L.find((V) => V.props.value === r.target.value);
|
|
1346
|
+
v !== void 0 && ($(v.props.value), E && E(r, v));
|
|
1347
|
+
}, oe = (r) => (v) => {
|
|
1348
|
+
let V;
|
|
1349
|
+
if (v.currentTarget.hasAttribute("tabindex")) {
|
|
1570
1350
|
if (i) {
|
|
1571
|
-
|
|
1572
|
-
const
|
|
1573
|
-
|
|
1351
|
+
V = Array.isArray(l) ? l.slice() : [];
|
|
1352
|
+
const ce = l.indexOf(r.props.value);
|
|
1353
|
+
ce === -1 ? V.push(r.props.value) : V.splice(ce, 1);
|
|
1574
1354
|
} else
|
|
1575
|
-
|
|
1576
|
-
if (
|
|
1577
|
-
const
|
|
1578
|
-
Object.defineProperty(
|
|
1355
|
+
V = r.props.value;
|
|
1356
|
+
if (r.props.onClick && r.props.onClick(v), l !== V && ($(V), E)) {
|
|
1357
|
+
const ce = v.nativeEvent || v, Xe = new ce.constructor(ce.type, ce);
|
|
1358
|
+
Object.defineProperty(Xe, "target", {
|
|
1579
1359
|
writable: !0,
|
|
1580
1360
|
value: {
|
|
1581
|
-
value:
|
|
1361
|
+
value: V,
|
|
1582
1362
|
name: a
|
|
1583
1363
|
}
|
|
1584
|
-
}),
|
|
1364
|
+
}), E(Xe, r);
|
|
1585
1365
|
}
|
|
1586
|
-
i ||
|
|
1366
|
+
i || le(!1, v);
|
|
1587
1367
|
}
|
|
1588
|
-
},
|
|
1368
|
+
}, ne = (r) => {
|
|
1589
1369
|
Y || [
|
|
1590
1370
|
" ",
|
|
1591
1371
|
"ArrowUp",
|
|
@@ -1593,114 +1373,114 @@ const Vt = (o) => {
|
|
|
1593
1373
|
// The native select doesn't respond to enter on macOS, but it's recommended by
|
|
1594
1374
|
// https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/
|
|
1595
1375
|
"Enter"
|
|
1596
|
-
].indexOf(
|
|
1597
|
-
},
|
|
1598
|
-
!
|
|
1376
|
+
].indexOf(r.key) !== -1 && (r.preventDefault(), le(!0, r));
|
|
1377
|
+
}, re = ee !== null && X, Ce = (r) => {
|
|
1378
|
+
!re && g && (Object.defineProperty(r, "target", {
|
|
1599
1379
|
writable: !0,
|
|
1600
1380
|
value: {
|
|
1601
|
-
value:
|
|
1381
|
+
value: l,
|
|
1602
1382
|
name: a
|
|
1603
1383
|
}
|
|
1604
|
-
}),
|
|
1384
|
+
}), g(r));
|
|
1605
1385
|
};
|
|
1606
|
-
delete
|
|
1607
|
-
let Z,
|
|
1608
|
-
const
|
|
1609
|
-
let B = !1,
|
|
1610
|
-
(
|
|
1611
|
-
value:
|
|
1612
|
-
}) ||
|
|
1613
|
-
const
|
|
1614
|
-
if (!/* @__PURE__ */
|
|
1386
|
+
delete D["aria-invalid"];
|
|
1387
|
+
let Z, te;
|
|
1388
|
+
const se = [];
|
|
1389
|
+
let B = !1, De = !1;
|
|
1390
|
+
(ko({
|
|
1391
|
+
value: l
|
|
1392
|
+
}) || C) && (A ? Z = A(l) : B = !0);
|
|
1393
|
+
const vo = L.map((r) => {
|
|
1394
|
+
if (!/* @__PURE__ */ s.isValidElement(r))
|
|
1615
1395
|
return null;
|
|
1616
|
-
process.env.NODE_ENV !== "production" &&
|
|
1396
|
+
process.env.NODE_ENV !== "production" && Be.isFragment(r) && console.error(["MUI: The Select component doesn't accept a Fragment as a child.", "Consider providing an array instead."].join(`
|
|
1617
1397
|
`));
|
|
1618
|
-
let
|
|
1398
|
+
let v;
|
|
1619
1399
|
if (i) {
|
|
1620
|
-
if (!Array.isArray(
|
|
1621
|
-
throw new Error(process.env.NODE_ENV !== "production" ? "MUI: The `value` prop must be an array when using the `Select` component with `multiple`." :
|
|
1622
|
-
|
|
1400
|
+
if (!Array.isArray(l))
|
|
1401
|
+
throw new Error(process.env.NODE_ENV !== "production" ? "MUI: The `value` prop must be an array when using the `Select` component with `multiple`." : yo(2));
|
|
1402
|
+
v = l.some((V) => ro(V, r.props.value)), v && B && se.push(r.props.children);
|
|
1623
1403
|
} else
|
|
1624
|
-
|
|
1625
|
-
return
|
|
1626
|
-
"aria-selected":
|
|
1627
|
-
onClick: oe(
|
|
1628
|
-
onKeyUp: (
|
|
1629
|
-
|
|
1404
|
+
v = ro(l, r.props.value), v && B && (te = r.props.children);
|
|
1405
|
+
return v && (De = !0), /* @__PURE__ */ s.cloneElement(r, {
|
|
1406
|
+
"aria-selected": v ? "true" : "false",
|
|
1407
|
+
onClick: oe(r),
|
|
1408
|
+
onKeyUp: (V) => {
|
|
1409
|
+
V.key === " " && V.preventDefault(), r.props.onKeyUp && r.props.onKeyUp(V);
|
|
1630
1410
|
},
|
|
1631
1411
|
role: "option",
|
|
1632
|
-
selected:
|
|
1412
|
+
selected: v,
|
|
1633
1413
|
value: void 0,
|
|
1634
1414
|
// The value is most likely not a valid HTML attribute.
|
|
1635
|
-
"data-value":
|
|
1415
|
+
"data-value": r.props.value
|
|
1636
1416
|
// Instead, we provide it as a data attribute.
|
|
1637
1417
|
});
|
|
1638
1418
|
});
|
|
1639
|
-
process.env.NODE_ENV !== "production" &&
|
|
1640
|
-
if (!
|
|
1641
|
-
const
|
|
1642
|
-
console.warn([`MUI: You have provided an out-of-range value \`${
|
|
1419
|
+
process.env.NODE_ENV !== "production" && s.useEffect(() => {
|
|
1420
|
+
if (!De && !i && l !== "") {
|
|
1421
|
+
const r = L.map((v) => v.props.value);
|
|
1422
|
+
console.warn([`MUI: You have provided an out-of-range value \`${l}\` for the select ${a ? `(name="${a}") ` : ""}component.`, "Consider providing a value that matches one of the available options or ''.", `The available values are ${r.filter((v) => v != null).map((v) => `\`${v}\``).join(", ") || '""'}.`].join(`
|
|
1643
1423
|
`));
|
|
1644
1424
|
}
|
|
1645
|
-
}, [
|
|
1646
|
-
let
|
|
1647
|
-
!
|
|
1648
|
-
let
|
|
1649
|
-
typeof K < "u" ?
|
|
1650
|
-
const
|
|
1651
|
-
variant:
|
|
1652
|
-
value:
|
|
1653
|
-
open:
|
|
1654
|
-
error:
|
|
1655
|
-
}),
|
|
1656
|
-
return /* @__PURE__ */
|
|
1657
|
-
children: [/* @__PURE__ */
|
|
1658
|
-
ref:
|
|
1659
|
-
tabIndex:
|
|
1425
|
+
}, [De, L, i, a, l]), B && (i ? se.length === 0 ? Z = null : Z = se.reduce((r, v, V) => (r.push(v), V < se.length - 1 && r.push(", "), r), []) : Z = te);
|
|
1426
|
+
let Ke = de;
|
|
1427
|
+
!c && ue && ee && (Ke = ae.clientWidth);
|
|
1428
|
+
let $e;
|
|
1429
|
+
typeof K < "u" ? $e = K : $e = w ? null : 0;
|
|
1430
|
+
const qe = F.id || (a ? `mui-component-select-${a}` : void 0), Re = u({}, n, {
|
|
1431
|
+
variant: k,
|
|
1432
|
+
value: l,
|
|
1433
|
+
open: re,
|
|
1434
|
+
error: _
|
|
1435
|
+
}), je = Sn(Re), ke = u({}, N.PaperProps, (d = N.slotProps) == null ? void 0 : d.paper), Ge = Ho();
|
|
1436
|
+
return /* @__PURE__ */ io(s.Fragment, {
|
|
1437
|
+
children: [/* @__PURE__ */ j(Tn, u({
|
|
1438
|
+
ref: Te,
|
|
1439
|
+
tabIndex: $e,
|
|
1660
1440
|
role: "combobox",
|
|
1661
|
-
"aria-controls":
|
|
1662
|
-
"aria-disabled":
|
|
1663
|
-
"aria-expanded":
|
|
1441
|
+
"aria-controls": Ge,
|
|
1442
|
+
"aria-disabled": w ? "true" : void 0,
|
|
1443
|
+
"aria-expanded": re ? "true" : "false",
|
|
1664
1444
|
"aria-haspopup": "listbox",
|
|
1665
|
-
"aria-label":
|
|
1666
|
-
"aria-labelledby": [
|
|
1667
|
-
"aria-describedby":
|
|
1668
|
-
onKeyDown:
|
|
1669
|
-
onMouseDown:
|
|
1670
|
-
onBlur:
|
|
1445
|
+
"aria-label": h,
|
|
1446
|
+
"aria-labelledby": [p, qe].filter(Boolean).join(" ") || void 0,
|
|
1447
|
+
"aria-describedby": b,
|
|
1448
|
+
onKeyDown: ne,
|
|
1449
|
+
onMouseDown: w || Y ? null : S,
|
|
1450
|
+
onBlur: Ce,
|
|
1671
1451
|
onFocus: W
|
|
1672
|
-
},
|
|
1673
|
-
ownerState:
|
|
1674
|
-
className:
|
|
1675
|
-
id:
|
|
1676
|
-
children:
|
|
1452
|
+
}, F, {
|
|
1453
|
+
ownerState: Re,
|
|
1454
|
+
className: pe(F.className, je.select, O),
|
|
1455
|
+
id: qe,
|
|
1456
|
+
children: In(Z) ? (
|
|
1677
1457
|
// notranslate needed while Google Translate will not fix zero-width space issue
|
|
1678
|
-
|
|
1458
|
+
to || (to = /* @__PURE__ */ j("span", {
|
|
1679
1459
|
className: "notranslate",
|
|
1680
1460
|
children: ""
|
|
1681
1461
|
}))
|
|
1682
1462
|
) : Z
|
|
1683
|
-
})), /* @__PURE__ */
|
|
1684
|
-
"aria-invalid":
|
|
1685
|
-
value: Array.isArray(
|
|
1463
|
+
})), /* @__PURE__ */ j(Rn, u({
|
|
1464
|
+
"aria-invalid": _,
|
|
1465
|
+
value: Array.isArray(l) ? l.join(",") : l,
|
|
1686
1466
|
name: a,
|
|
1687
|
-
ref:
|
|
1467
|
+
ref: q,
|
|
1688
1468
|
"aria-hidden": !0,
|
|
1689
1469
|
onChange: Q,
|
|
1690
1470
|
tabIndex: -1,
|
|
1691
|
-
disabled:
|
|
1692
|
-
className:
|
|
1693
|
-
autoFocus:
|
|
1694
|
-
ownerState:
|
|
1695
|
-
},
|
|
1696
|
-
as:
|
|
1697
|
-
className:
|
|
1698
|
-
ownerState:
|
|
1699
|
-
}), /* @__PURE__ */
|
|
1471
|
+
disabled: w,
|
|
1472
|
+
className: je.nativeInput,
|
|
1473
|
+
autoFocus: f,
|
|
1474
|
+
ownerState: Re
|
|
1475
|
+
}, D)), /* @__PURE__ */ j(Cn, {
|
|
1476
|
+
as: x,
|
|
1477
|
+
className: je.icon,
|
|
1478
|
+
ownerState: Re
|
|
1479
|
+
}), /* @__PURE__ */ j(uo, u({
|
|
1700
1480
|
id: `menu-${a || ""}`,
|
|
1701
|
-
anchorEl:
|
|
1702
|
-
open:
|
|
1703
|
-
onClose:
|
|
1481
|
+
anchorEl: ae,
|
|
1482
|
+
open: re,
|
|
1483
|
+
onClose: M,
|
|
1704
1484
|
anchorOrigin: {
|
|
1705
1485
|
vertical: "bottom",
|
|
1706
1486
|
horizontal: "center"
|
|
@@ -1709,26 +1489,26 @@ const Vt = (o) => {
|
|
|
1709
1489
|
vertical: "top",
|
|
1710
1490
|
horizontal: "center"
|
|
1711
1491
|
}
|
|
1712
|
-
},
|
|
1713
|
-
MenuListProps:
|
|
1714
|
-
"aria-labelledby":
|
|
1492
|
+
}, N, {
|
|
1493
|
+
MenuListProps: u({
|
|
1494
|
+
"aria-labelledby": p,
|
|
1715
1495
|
role: "listbox",
|
|
1716
1496
|
"aria-multiselectable": i ? "true" : void 0,
|
|
1717
1497
|
disableListWrap: !0,
|
|
1718
|
-
id:
|
|
1719
|
-
},
|
|
1720
|
-
slotProps:
|
|
1721
|
-
paper:
|
|
1722
|
-
style:
|
|
1723
|
-
minWidth:
|
|
1724
|
-
},
|
|
1498
|
+
id: Ge
|
|
1499
|
+
}, N.MenuListProps),
|
|
1500
|
+
slotProps: u({}, N.slotProps, {
|
|
1501
|
+
paper: u({}, ke, {
|
|
1502
|
+
style: u({
|
|
1503
|
+
minWidth: Ke
|
|
1504
|
+
}, ke != null ? ke.style : null)
|
|
1725
1505
|
})
|
|
1726
1506
|
}),
|
|
1727
|
-
children:
|
|
1507
|
+
children: vo
|
|
1728
1508
|
}))]
|
|
1729
1509
|
});
|
|
1730
1510
|
});
|
|
1731
|
-
process.env.NODE_ENV !== "production" && (
|
|
1511
|
+
process.env.NODE_ENV !== "production" && (ho.propTypes = {
|
|
1732
1512
|
/**
|
|
1733
1513
|
* @ignore
|
|
1734
1514
|
*/
|
|
@@ -1788,7 +1568,7 @@ process.env.NODE_ENV !== "production" && (Oo.propTypes = {
|
|
|
1788
1568
|
* Imperative handle implementing `{ value: T, node: HTMLElement, focus(): void }`
|
|
1789
1569
|
* Equivalent to `ref`
|
|
1790
1570
|
*/
|
|
1791
|
-
inputRef:
|
|
1571
|
+
inputRef: Ne,
|
|
1792
1572
|
/**
|
|
1793
1573
|
* The ID of an element that acts as an additional label. The Select will
|
|
1794
1574
|
* be labelled by the additional label and the selected value.
|
|
@@ -1872,40 +1652,40 @@ process.env.NODE_ENV !== "production" && (Oo.propTypes = {
|
|
|
1872
1652
|
*/
|
|
1873
1653
|
variant: e.oneOf(["standard", "outlined", "filled"])
|
|
1874
1654
|
});
|
|
1875
|
-
const
|
|
1655
|
+
const xn = zo(/* @__PURE__ */ j("path", {
|
|
1876
1656
|
d: "M7 10l5 5 5-5z"
|
|
1877
1657
|
}), "ArrowDropDown");
|
|
1878
|
-
function
|
|
1879
|
-
return
|
|
1658
|
+
function Mn(o) {
|
|
1659
|
+
return ye("MuiFilledInput", o);
|
|
1880
1660
|
}
|
|
1881
|
-
const
|
|
1661
|
+
const ie = u({}, Lo, ge("MuiFilledInput", ["root", "underline", "input"])), wn = ["disableUnderline", "components", "componentsProps", "fullWidth", "hiddenLabel", "inputComponent", "multiline", "slotProps", "slots", "type"], Nn = (o) => {
|
|
1882
1662
|
const {
|
|
1883
|
-
classes:
|
|
1884
|
-
disableUnderline:
|
|
1885
|
-
} = o,
|
|
1886
|
-
root: ["root", !
|
|
1663
|
+
classes: n,
|
|
1664
|
+
disableUnderline: t
|
|
1665
|
+
} = o, b = ve({
|
|
1666
|
+
root: ["root", !t && "underline"],
|
|
1887
1667
|
input: ["input"]
|
|
1888
|
-
},
|
|
1889
|
-
return
|
|
1890
|
-
},
|
|
1891
|
-
shouldForwardProp: (o) =>
|
|
1668
|
+
}, Mn, n);
|
|
1669
|
+
return u({}, n, b);
|
|
1670
|
+
}, Fn = H(_o, {
|
|
1671
|
+
shouldForwardProp: (o) => we(o) || o === "classes",
|
|
1892
1672
|
name: "MuiFilledInput",
|
|
1893
1673
|
slot: "Root",
|
|
1894
|
-
overridesResolver: (o,
|
|
1674
|
+
overridesResolver: (o, n) => {
|
|
1895
1675
|
const {
|
|
1896
|
-
ownerState:
|
|
1676
|
+
ownerState: t
|
|
1897
1677
|
} = o;
|
|
1898
|
-
return [...
|
|
1678
|
+
return [...Ao(o, n), !t.disableUnderline && n.underline];
|
|
1899
1679
|
}
|
|
1900
1680
|
})(({
|
|
1901
1681
|
theme: o,
|
|
1902
|
-
ownerState:
|
|
1682
|
+
ownerState: n
|
|
1903
1683
|
}) => {
|
|
1904
|
-
var
|
|
1905
|
-
const
|
|
1906
|
-
return
|
|
1684
|
+
var t;
|
|
1685
|
+
const d = o.palette.mode === "light", b = d ? "rgba(0, 0, 0, 0.42)" : "rgba(255, 255, 255, 0.7)", h = d ? "rgba(0, 0, 0, 0.06)" : "rgba(255, 255, 255, 0.09)", f = d ? "rgba(0, 0, 0, 0.09)" : "rgba(255, 255, 255, 0.13)", c = d ? "rgba(0, 0, 0, 0.12)" : "rgba(255, 255, 255, 0.12)";
|
|
1686
|
+
return u({
|
|
1907
1687
|
position: "relative",
|
|
1908
|
-
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg :
|
|
1688
|
+
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg : h,
|
|
1909
1689
|
borderTopLeftRadius: (o.vars || o).shape.borderRadius,
|
|
1910
1690
|
borderTopRightRadius: (o.vars || o).shape.borderRadius,
|
|
1911
1691
|
transition: o.transitions.create("background-color", {
|
|
@@ -1913,21 +1693,21 @@ const ae = c({}, Vo, le("MuiFilledInput", ["root", "underline", "input"])), Ut =
|
|
|
1913
1693
|
easing: o.transitions.easing.easeOut
|
|
1914
1694
|
}),
|
|
1915
1695
|
"&:hover": {
|
|
1916
|
-
backgroundColor: o.vars ? o.vars.palette.FilledInput.hoverBg :
|
|
1696
|
+
backgroundColor: o.vars ? o.vars.palette.FilledInput.hoverBg : f,
|
|
1917
1697
|
// Reset on touch devices, it doesn't add specificity
|
|
1918
1698
|
"@media (hover: none)": {
|
|
1919
|
-
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg :
|
|
1699
|
+
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg : h
|
|
1920
1700
|
}
|
|
1921
1701
|
},
|
|
1922
|
-
[`&.${
|
|
1923
|
-
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg :
|
|
1702
|
+
[`&.${ie.focused}`]: {
|
|
1703
|
+
backgroundColor: o.vars ? o.vars.palette.FilledInput.bg : h
|
|
1924
1704
|
},
|
|
1925
|
-
[`&.${
|
|
1926
|
-
backgroundColor: o.vars ? o.vars.palette.FilledInput.disabledBg :
|
|
1705
|
+
[`&.${ie.disabled}`]: {
|
|
1706
|
+
backgroundColor: o.vars ? o.vars.palette.FilledInput.disabledBg : c
|
|
1927
1707
|
}
|
|
1928
|
-
}, !
|
|
1708
|
+
}, !n.disableUnderline && {
|
|
1929
1709
|
"&::after": {
|
|
1930
|
-
borderBottom: `2px solid ${(
|
|
1710
|
+
borderBottom: `2px solid ${(t = (o.vars || o).palette[n.color || "primary"]) == null ? void 0 : t.main}`,
|
|
1931
1711
|
left: 0,
|
|
1932
1712
|
bottom: 0,
|
|
1933
1713
|
// Doing the other way around crash on IE11 "''" https://github.com/cssinjs/jss/issues/242
|
|
@@ -1942,18 +1722,18 @@ const ae = c({}, Vo, le("MuiFilledInput", ["root", "underline", "input"])), Ut =
|
|
|
1942
1722
|
pointerEvents: "none"
|
|
1943
1723
|
// Transparent to the hover style.
|
|
1944
1724
|
},
|
|
1945
|
-
[`&.${
|
|
1725
|
+
[`&.${ie.focused}:after`]: {
|
|
1946
1726
|
// translateX(0) is a workaround for Safari transform scale bug
|
|
1947
1727
|
// See https://github.com/mui/material-ui/issues/31766
|
|
1948
1728
|
transform: "scaleX(1) translateX(0)"
|
|
1949
1729
|
},
|
|
1950
|
-
[`&.${
|
|
1730
|
+
[`&.${ie.error}`]: {
|
|
1951
1731
|
"&::before, &::after": {
|
|
1952
1732
|
borderBottomColor: (o.vars || o).palette.error.main
|
|
1953
1733
|
}
|
|
1954
1734
|
},
|
|
1955
1735
|
"&::before": {
|
|
1956
|
-
borderBottom: `1px solid ${o.vars ? `rgba(${o.vars.palette.common.onBackgroundChannel} / ${o.vars.opacity.inputUnderline})` :
|
|
1736
|
+
borderBottom: `1px solid ${o.vars ? `rgba(${o.vars.palette.common.onBackgroundChannel} / ${o.vars.opacity.inputUnderline})` : b}`,
|
|
1957
1737
|
left: 0,
|
|
1958
1738
|
bottom: 0,
|
|
1959
1739
|
// Doing the other way around crash on IE11 "''" https://github.com/cssinjs/jss/issues/242
|
|
@@ -1966,36 +1746,36 @@ const ae = c({}, Vo, le("MuiFilledInput", ["root", "underline", "input"])), Ut =
|
|
|
1966
1746
|
pointerEvents: "none"
|
|
1967
1747
|
// Transparent to the hover style.
|
|
1968
1748
|
},
|
|
1969
|
-
[`&:hover:not(.${
|
|
1749
|
+
[`&:hover:not(.${ie.disabled}, .${ie.error}):before`]: {
|
|
1970
1750
|
borderBottom: `1px solid ${(o.vars || o).palette.text.primary}`
|
|
1971
1751
|
},
|
|
1972
|
-
[`&.${
|
|
1752
|
+
[`&.${ie.disabled}:before`]: {
|
|
1973
1753
|
borderBottomStyle: "dotted"
|
|
1974
1754
|
}
|
|
1975
|
-
},
|
|
1755
|
+
}, n.startAdornment && {
|
|
1976
1756
|
paddingLeft: 12
|
|
1977
|
-
},
|
|
1757
|
+
}, n.endAdornment && {
|
|
1978
1758
|
paddingRight: 12
|
|
1979
|
-
},
|
|
1759
|
+
}, n.multiline && u({
|
|
1980
1760
|
padding: "25px 12px 8px"
|
|
1981
|
-
},
|
|
1761
|
+
}, n.size === "small" && {
|
|
1982
1762
|
paddingTop: 21,
|
|
1983
1763
|
paddingBottom: 4
|
|
1984
|
-
},
|
|
1764
|
+
}, n.hiddenLabel && {
|
|
1985
1765
|
paddingTop: 16,
|
|
1986
1766
|
paddingBottom: 17
|
|
1987
|
-
},
|
|
1767
|
+
}, n.hiddenLabel && n.size === "small" && {
|
|
1988
1768
|
paddingTop: 8,
|
|
1989
1769
|
paddingBottom: 9
|
|
1990
1770
|
}));
|
|
1991
|
-
}),
|
|
1771
|
+
}), Dn = H(Vo, {
|
|
1992
1772
|
name: "MuiFilledInput",
|
|
1993
1773
|
slot: "Input",
|
|
1994
|
-
overridesResolver:
|
|
1774
|
+
overridesResolver: Bo
|
|
1995
1775
|
})(({
|
|
1996
1776
|
theme: o,
|
|
1997
|
-
ownerState:
|
|
1998
|
-
}) =>
|
|
1777
|
+
ownerState: n
|
|
1778
|
+
}) => u({
|
|
1999
1779
|
paddingTop: 25,
|
|
2000
1780
|
paddingRight: 12,
|
|
2001
1781
|
paddingBottom: 8,
|
|
@@ -2020,68 +1800,68 @@ const ae = c({}, Vo, le("MuiFilledInput", ["root", "underline", "input"])), Ut =
|
|
|
2020
1800
|
caretColor: "#fff"
|
|
2021
1801
|
}
|
|
2022
1802
|
}
|
|
2023
|
-
},
|
|
1803
|
+
}, n.size === "small" && {
|
|
2024
1804
|
paddingTop: 21,
|
|
2025
1805
|
paddingBottom: 4
|
|
2026
|
-
},
|
|
1806
|
+
}, n.hiddenLabel && {
|
|
2027
1807
|
paddingTop: 16,
|
|
2028
1808
|
paddingBottom: 17
|
|
2029
|
-
},
|
|
1809
|
+
}, n.startAdornment && {
|
|
2030
1810
|
paddingLeft: 0
|
|
2031
|
-
},
|
|
1811
|
+
}, n.endAdornment && {
|
|
2032
1812
|
paddingRight: 0
|
|
2033
|
-
},
|
|
1813
|
+
}, n.hiddenLabel && n.size === "small" && {
|
|
2034
1814
|
paddingTop: 8,
|
|
2035
1815
|
paddingBottom: 9
|
|
2036
|
-
},
|
|
1816
|
+
}, n.multiline && {
|
|
2037
1817
|
paddingTop: 0,
|
|
2038
1818
|
paddingBottom: 0,
|
|
2039
1819
|
paddingLeft: 0,
|
|
2040
1820
|
paddingRight: 0
|
|
2041
|
-
})),
|
|
2042
|
-
var
|
|
2043
|
-
const
|
|
2044
|
-
props:
|
|
1821
|
+
})), ze = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
1822
|
+
var d, b, h, f;
|
|
1823
|
+
const c = Me({
|
|
1824
|
+
props: n,
|
|
2045
1825
|
name: "MuiFilledInput"
|
|
2046
1826
|
}), {
|
|
2047
|
-
components:
|
|
1827
|
+
components: y = {},
|
|
2048
1828
|
componentsProps: O,
|
|
2049
|
-
fullWidth:
|
|
1829
|
+
fullWidth: I = !1,
|
|
2050
1830
|
// declare here to prevent spreading to DOM
|
|
2051
|
-
inputComponent:
|
|
2052
|
-
multiline:
|
|
2053
|
-
slotProps:
|
|
2054
|
-
slots:
|
|
2055
|
-
type:
|
|
2056
|
-
} =
|
|
2057
|
-
fullWidth:
|
|
2058
|
-
inputComponent:
|
|
2059
|
-
multiline:
|
|
2060
|
-
type:
|
|
2061
|
-
}),
|
|
1831
|
+
inputComponent: T = "input",
|
|
1832
|
+
multiline: w = !1,
|
|
1833
|
+
slotProps: C,
|
|
1834
|
+
slots: _ = {},
|
|
1835
|
+
type: x = "text"
|
|
1836
|
+
} = c, R = G(c, wn), p = u({}, c, {
|
|
1837
|
+
fullWidth: I,
|
|
1838
|
+
inputComponent: T,
|
|
1839
|
+
multiline: w,
|
|
1840
|
+
type: x
|
|
1841
|
+
}), N = Nn(c), i = {
|
|
2062
1842
|
root: {
|
|
2063
|
-
ownerState:
|
|
1843
|
+
ownerState: p
|
|
2064
1844
|
},
|
|
2065
1845
|
input: {
|
|
2066
|
-
ownerState:
|
|
1846
|
+
ownerState: p
|
|
2067
1847
|
}
|
|
2068
|
-
}, a =
|
|
2069
|
-
return /* @__PURE__ */
|
|
1848
|
+
}, a = C ?? O ? so(i, C ?? O) : i, g = (d = (b = _.root) != null ? b : y.Root) != null ? d : Fn, E = (h = (f = _.input) != null ? f : y.Input) != null ? h : Dn;
|
|
1849
|
+
return /* @__PURE__ */ j(Wo, u({
|
|
2070
1850
|
slots: {
|
|
2071
|
-
root:
|
|
2072
|
-
input:
|
|
1851
|
+
root: g,
|
|
1852
|
+
input: E
|
|
2073
1853
|
},
|
|
2074
1854
|
componentsProps: a,
|
|
2075
|
-
fullWidth:
|
|
2076
|
-
inputComponent:
|
|
2077
|
-
multiline:
|
|
2078
|
-
ref:
|
|
2079
|
-
type:
|
|
2080
|
-
},
|
|
2081
|
-
classes:
|
|
1855
|
+
fullWidth: I,
|
|
1856
|
+
inputComponent: T,
|
|
1857
|
+
multiline: w,
|
|
1858
|
+
ref: t,
|
|
1859
|
+
type: x
|
|
1860
|
+
}, R, {
|
|
1861
|
+
classes: N
|
|
2082
1862
|
}));
|
|
2083
1863
|
});
|
|
2084
|
-
process.env.NODE_ENV !== "production" && (
|
|
1864
|
+
process.env.NODE_ENV !== "production" && (ze.propTypes = {
|
|
2085
1865
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
2086
1866
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
2087
1867
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -2184,7 +1964,7 @@ process.env.NODE_ENV !== "production" && (Ke.propTypes = {
|
|
|
2184
1964
|
/**
|
|
2185
1965
|
* Pass a ref to the `input` element.
|
|
2186
1966
|
*/
|
|
2187
|
-
inputRef:
|
|
1967
|
+
inputRef: Ne,
|
|
2188
1968
|
/**
|
|
2189
1969
|
* If `dense`, will adjust vertical spacing. This is normally obtained via context from
|
|
2190
1970
|
* FormControl.
|
|
@@ -2274,104 +2054,104 @@ process.env.NODE_ENV !== "production" && (Ke.propTypes = {
|
|
|
2274
2054
|
*/
|
|
2275
2055
|
value: e.any
|
|
2276
2056
|
});
|
|
2277
|
-
|
|
2278
|
-
const
|
|
2057
|
+
ze.muiName = "Input";
|
|
2058
|
+
const $n = ["autoWidth", "children", "classes", "className", "defaultOpen", "displayEmpty", "IconComponent", "id", "input", "inputProps", "label", "labelId", "MenuProps", "multiple", "native", "onClose", "onOpen", "open", "renderValue", "SelectDisplayProps", "variant"], jn = ["root"], kn = (o) => {
|
|
2279
2059
|
const {
|
|
2280
|
-
classes:
|
|
2060
|
+
classes: n
|
|
2281
2061
|
} = o;
|
|
2282
|
-
return
|
|
2283
|
-
},
|
|
2062
|
+
return n;
|
|
2063
|
+
}, He = {
|
|
2284
2064
|
name: "MuiSelect",
|
|
2285
|
-
overridesResolver: (o,
|
|
2286
|
-
shouldForwardProp: (o) =>
|
|
2065
|
+
overridesResolver: (o, n) => n.root,
|
|
2066
|
+
shouldForwardProp: (o) => we(o) && o !== "variant",
|
|
2287
2067
|
slot: "Root"
|
|
2288
|
-
},
|
|
2289
|
-
const
|
|
2068
|
+
}, Ln = H(qo, He)(""), _n = H(Go, He)(""), An = H(ze, He)(""), go = /* @__PURE__ */ s.forwardRef(function(n, t) {
|
|
2069
|
+
const d = Me({
|
|
2290
2070
|
name: "MuiSelect",
|
|
2291
|
-
props:
|
|
2071
|
+
props: n
|
|
2292
2072
|
}), {
|
|
2293
|
-
autoWidth:
|
|
2294
|
-
children:
|
|
2295
|
-
classes:
|
|
2296
|
-
className:
|
|
2297
|
-
defaultOpen:
|
|
2073
|
+
autoWidth: b = !1,
|
|
2074
|
+
children: h,
|
|
2075
|
+
classes: f = {},
|
|
2076
|
+
className: c,
|
|
2077
|
+
defaultOpen: y = !1,
|
|
2298
2078
|
displayEmpty: O = !1,
|
|
2299
|
-
IconComponent:
|
|
2300
|
-
id:
|
|
2301
|
-
input:
|
|
2302
|
-
inputProps:
|
|
2303
|
-
label:
|
|
2304
|
-
labelId:
|
|
2305
|
-
MenuProps:
|
|
2306
|
-
multiple:
|
|
2307
|
-
native:
|
|
2079
|
+
IconComponent: I = xn,
|
|
2080
|
+
id: T,
|
|
2081
|
+
input: w,
|
|
2082
|
+
inputProps: C,
|
|
2083
|
+
label: _,
|
|
2084
|
+
labelId: x,
|
|
2085
|
+
MenuProps: R,
|
|
2086
|
+
multiple: p = !1,
|
|
2087
|
+
native: N = !1,
|
|
2308
2088
|
onClose: i,
|
|
2309
2089
|
onOpen: a,
|
|
2310
|
-
open:
|
|
2311
|
-
renderValue:
|
|
2312
|
-
SelectDisplayProps:
|
|
2090
|
+
open: g,
|
|
2091
|
+
renderValue: E,
|
|
2092
|
+
SelectDisplayProps: m,
|
|
2313
2093
|
variant: W = "outlined"
|
|
2314
|
-
} =
|
|
2315
|
-
props:
|
|
2094
|
+
} = d, U = G(d, $n), z = N ? bo : ho, Y = Ko(), A = Uo({
|
|
2095
|
+
props: d,
|
|
2316
2096
|
muiFormControl: Y,
|
|
2317
2097
|
states: ["variant", "error"]
|
|
2318
|
-
}),
|
|
2319
|
-
variant:
|
|
2320
|
-
classes:
|
|
2321
|
-
}), P =
|
|
2322
|
-
standard: /* @__PURE__ */
|
|
2098
|
+
}), F = A.variant || W, K = u({}, d, {
|
|
2099
|
+
variant: F,
|
|
2100
|
+
classes: f
|
|
2101
|
+
}), P = kn(K), k = G(P, jn), D = w || {
|
|
2102
|
+
standard: /* @__PURE__ */ j(Ln, {
|
|
2323
2103
|
ownerState: K
|
|
2324
2104
|
}),
|
|
2325
|
-
outlined: /* @__PURE__ */
|
|
2326
|
-
label:
|
|
2105
|
+
outlined: /* @__PURE__ */ j(_n, {
|
|
2106
|
+
label: _,
|
|
2327
2107
|
ownerState: K
|
|
2328
2108
|
}),
|
|
2329
|
-
filled: /* @__PURE__ */
|
|
2109
|
+
filled: /* @__PURE__ */ j(An, {
|
|
2330
2110
|
ownerState: K
|
|
2331
2111
|
})
|
|
2332
|
-
}[
|
|
2333
|
-
return /* @__PURE__ */
|
|
2334
|
-
children: /* @__PURE__ */
|
|
2112
|
+
}[F], l = Pe(t, D.ref);
|
|
2113
|
+
return /* @__PURE__ */ j(s.Fragment, {
|
|
2114
|
+
children: /* @__PURE__ */ s.cloneElement(D, u({
|
|
2335
2115
|
// Most of the logic is implemented in `SelectInput`.
|
|
2336
2116
|
// The `Select` component is a simple API wrapper to expose something better to play with.
|
|
2337
|
-
inputComponent:
|
|
2338
|
-
inputProps:
|
|
2339
|
-
children:
|
|
2340
|
-
error:
|
|
2341
|
-
IconComponent:
|
|
2342
|
-
variant:
|
|
2117
|
+
inputComponent: z,
|
|
2118
|
+
inputProps: u({
|
|
2119
|
+
children: h,
|
|
2120
|
+
error: A.error,
|
|
2121
|
+
IconComponent: I,
|
|
2122
|
+
variant: F,
|
|
2343
2123
|
type: void 0,
|
|
2344
2124
|
// We render a select. We can ignore the type provided by the `Input`.
|
|
2345
|
-
multiple:
|
|
2346
|
-
},
|
|
2347
|
-
id:
|
|
2125
|
+
multiple: p
|
|
2126
|
+
}, N ? {
|
|
2127
|
+
id: T
|
|
2348
2128
|
} : {
|
|
2349
|
-
autoWidth:
|
|
2350
|
-
defaultOpen:
|
|
2129
|
+
autoWidth: b,
|
|
2130
|
+
defaultOpen: y,
|
|
2351
2131
|
displayEmpty: O,
|
|
2352
|
-
labelId:
|
|
2353
|
-
MenuProps:
|
|
2132
|
+
labelId: x,
|
|
2133
|
+
MenuProps: R,
|
|
2354
2134
|
onClose: i,
|
|
2355
2135
|
onOpen: a,
|
|
2356
|
-
open:
|
|
2357
|
-
renderValue:
|
|
2358
|
-
SelectDisplayProps:
|
|
2359
|
-
id:
|
|
2360
|
-
},
|
|
2361
|
-
},
|
|
2362
|
-
classes:
|
|
2363
|
-
},
|
|
2364
|
-
}, (
|
|
2136
|
+
open: g,
|
|
2137
|
+
renderValue: E,
|
|
2138
|
+
SelectDisplayProps: u({
|
|
2139
|
+
id: T
|
|
2140
|
+
}, m)
|
|
2141
|
+
}, C, {
|
|
2142
|
+
classes: C ? so(k, C.classes) : k
|
|
2143
|
+
}, w ? w.props.inputProps : {})
|
|
2144
|
+
}, (p && N || O) && F === "outlined" ? {
|
|
2365
2145
|
notched: !0
|
|
2366
2146
|
} : {}, {
|
|
2367
|
-
ref:
|
|
2368
|
-
className:
|
|
2369
|
-
}, !
|
|
2370
|
-
variant:
|
|
2371
|
-
},
|
|
2147
|
+
ref: l,
|
|
2148
|
+
className: pe(D.props.className, c, P.root)
|
|
2149
|
+
}, !w && {
|
|
2150
|
+
variant: F
|
|
2151
|
+
}, U))
|
|
2372
2152
|
});
|
|
2373
2153
|
});
|
|
2374
|
-
process.env.NODE_ENV !== "production" && (
|
|
2154
|
+
process.env.NODE_ENV !== "production" && (go.propTypes = {
|
|
2375
2155
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
2376
2156
|
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
2377
2157
|
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
@@ -2518,9 +2298,8 @@ process.env.NODE_ENV !== "production" && (Io.propTypes = {
|
|
|
2518
2298
|
*/
|
|
2519
2299
|
variant: e.oneOf(["filled", "outlined", "standard"])
|
|
2520
2300
|
});
|
|
2521
|
-
|
|
2301
|
+
go.muiName = "Select";
|
|
2522
2302
|
export {
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
Io as S
|
|
2303
|
+
ze as F,
|
|
2304
|
+
go as S
|
|
2526
2305
|
};
|