@carto/meridian-ds 1.4.1 → 1.4.2-alpha-forwarding-props.1
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/CHANGELOG.md +10 -1
- package/dist/{Alert-Cn0nq6aq.js → Alert-1b84B18a.js} +1 -1
- package/dist/{Alert-B2JgFj6Y.cjs → Alert-BbMbtaix.cjs} +1 -1
- package/dist/{MenuItem-vbfSlKyV.js → MenuItem-Cd34y6F3.js} +41 -15
- package/dist/MenuItem-Dbss-WG1.cjs +1 -0
- package/dist/{TablePaginationActions-EC4ynZRa.js → TablePaginationActions-EDxBCxpG.js} +1 -0
- package/dist/TablePaginationActions-V8ultBUz.cjs +9 -0
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.js +1113 -1005
- package/dist/theme/index.cjs +1 -1
- package/dist/theme/index.js +42 -36
- package/dist/types/components/atoms/Button.d.ts.map +1 -1
- package/dist/types/components/atoms/IconButton.d.ts.map +1 -1
- package/dist/types/components/atoms/Typography.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/Autocomplete.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/CreatableAutocomplete.d.ts +1 -1
- package/dist/types/components/molecules/Autocomplete/CreatableAutocomplete.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/ListBoxWithFilter.d.ts +2 -0
- package/dist/types/components/molecules/Autocomplete/ListBoxWithFilter.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/MultipleAutocomplete.d.ts +1 -1
- package/dist/types/components/molecules/Autocomplete/MultipleAutocomplete.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/useAutocompleteRenderOption.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/useMultipleAutocomplete.d.ts +2 -2
- package/dist/types/components/molecules/Autocomplete/useMultipleAutocomplete.d.ts.map +1 -1
- package/dist/types/components/molecules/Autocomplete/utils.d.ts +1 -0
- package/dist/types/components/molecules/Autocomplete/utils.d.ts.map +1 -1
- package/dist/types/components/molecules/Menu/Menu.d.ts +2 -1
- package/dist/types/components/molecules/Menu/Menu.d.ts.map +1 -1
- package/dist/types/components/molecules/Menu/MenuItem.d.ts +2 -1
- package/dist/types/components/molecules/Menu/MenuItem.d.ts.map +1 -1
- package/dist/types/components/molecules/Menu/MenuItemFilter.d.ts +9 -0
- package/dist/types/components/molecules/Menu/MenuItemFilter.d.ts.map +1 -0
- package/dist/types/components/molecules/Menu/MenuList.d.ts +2 -1
- package/dist/types/components/molecules/Menu/MenuList.d.ts.map +1 -1
- package/dist/types/components/molecules/Menu/index.d.ts +2 -2
- package/dist/types/components/molecules/Menu/index.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/DatePicker.d.ts +1 -1
- package/dist/types/components/organisms/DatePickers/DatePicker.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/DateRangePicker.d.ts +1 -1
- package/dist/types/components/organisms/DatePickers/DateRangePicker.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/DateTimePicker.d.ts +1 -1
- package/dist/types/components/organisms/DatePickers/DateTimePicker.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/PickersDay.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/TimePicker.d.ts +1 -1
- package/dist/types/components/organisms/DatePickers/TimePicker.d.ts.map +1 -1
- package/dist/types/components/organisms/DatePickers/types.d.ts +2 -0
- package/dist/types/components/organisms/DatePickers/types.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/Dialog.d.ts +1 -1
- package/dist/types/components/organisms/Dialog/Dialog.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/DialogConfirmation.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/DialogContent.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/DialogFooter.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/DialogHeader.d.ts.map +1 -1
- package/dist/types/theme/sections/components/data-display.d.ts.map +1 -1
- package/dist/types/theme/sections/components/forms.d.ts.map +1 -1
- package/dist/widgets/index.cjs +2 -2
- package/dist/widgets/index.js +3 -3
- package/package.json +1 -1
- package/dist/MenuItem-CuEx97RN.cjs +0 -1
- package/dist/TablePaginationActions-7wkkiCXh.cjs +0 -9
- package/dist/types/components/molecules/Menu/MenuFilter.d.ts +0 -8
- package/dist/types/components/molecules/Menu/MenuFilter.d.ts.map +0 -1
package/dist/components/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { jsx as i, jsxs as y, Fragment as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { styled as
|
|
4
|
-
import { T as
|
|
5
|
-
import { a as
|
|
6
|
-
import { useIntl as
|
|
7
|
-
import { VisibilityOffOutlined as
|
|
8
|
-
import { A as
|
|
1
|
+
import { jsx as i, jsxs as y, Fragment as V } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as T, useState as $, useEffect as _, useMemo as pt, useRef as Y, Fragment as Ot, useImperativeHandle as Lt, useCallback as nt } from "react";
|
|
3
|
+
import { styled as g, Box as v, Button as gt, CircularProgress as P, TextField as ft, InputAdornment as q, IconButton as W, Tooltip as H, Select as Wt, MenuItem as mt, FormControl as Et, InputLabel as Ht, FormHelperText as ht, ToggleButtonGroup as _t, Menu as Pt, MenuList as Gt, Link as jt, Checkbox as z, ListItemText as bt, Autocomplete as Z, Divider as j, ListItemIcon as Vt, createFilterOptions as Nt, Accordion as Ut, AccordionSummary as Yt, AccordionDetails as qt, Avatar as zt, Snackbar as Zt, Portal as Jt, Fade as Xt, Slide as xt, alpha as Kt, useTheme as N, Toolbar as Qt, AppBar as te, Paper as ee, Dialog as ne, DialogTitle as oe, Chip as ie, DialogContent as ae, DialogActions as re } from "@mui/material";
|
|
4
|
+
import { T as S, c as G, u as R, N as ot, A as le } from "../TablePaginationActions-EDxBCxpG.js";
|
|
5
|
+
import { a as Vo } from "../TablePaginationActions-EDxBCxpG.js";
|
|
6
|
+
import { useIntl as F } from "react-intl";
|
|
7
|
+
import { VisibilityOffOutlined as ce, VisibilityOutlined as se, Cancel as yt, AddCircleOutlineOutlined as de, CloseOutlined as Mt, MenuOutlined as ue, HelpOutline as J, TodayOutlined as pe, Check as ge } from "@mui/icons-material";
|
|
8
|
+
import { A as Ct } from "../Alert-1b84B18a.js";
|
|
9
9
|
import "cartocolor";
|
|
10
|
-
import { M as
|
|
11
|
-
import { A as
|
|
12
|
-
import { DatePicker as
|
|
13
|
-
import { PickersDay as
|
|
14
|
-
import { TimePicker as
|
|
15
|
-
import { DateTimePicker as
|
|
16
|
-
import
|
|
17
|
-
const
|
|
10
|
+
import { M as vt } from "../MenuItem-Cd34y6F3.js";
|
|
11
|
+
import { A as X } from "../ArrowDown-B1AG0MlL.js";
|
|
12
|
+
import { DatePicker as fe } from "@mui/x-date-pickers/DatePicker";
|
|
13
|
+
import { PickersDay as me } from "@mui/x-date-pickers";
|
|
14
|
+
import { TimePicker as he } from "@mui/x-date-pickers/TimePicker";
|
|
15
|
+
import { DateTimePicker as be } from "@mui/x-date-pickers/DateTimePicker";
|
|
16
|
+
import xe from "@mui/material/ClickAwayListener";
|
|
17
|
+
const ye = g(v)({
|
|
18
18
|
position: "absolute",
|
|
19
19
|
top: 0,
|
|
20
20
|
left: 0,
|
|
@@ -23,52 +23,53 @@ const be = p(v)({
|
|
|
23
23
|
display: "flex",
|
|
24
24
|
alignItems: "center",
|
|
25
25
|
justifyContent: "center"
|
|
26
|
-
}),
|
|
26
|
+
}), Me = g(v)({
|
|
27
27
|
visibility: "hidden",
|
|
28
28
|
pointerEvents: "none"
|
|
29
29
|
});
|
|
30
|
-
function
|
|
30
|
+
function Ce({
|
|
31
31
|
children: t,
|
|
32
32
|
loading: e,
|
|
33
33
|
disabled: n,
|
|
34
34
|
startIcon: o,
|
|
35
|
-
endIcon:
|
|
36
|
-
loadingPosition:
|
|
35
|
+
endIcon: a,
|
|
36
|
+
loadingPosition: r,
|
|
37
37
|
...l
|
|
38
|
-
},
|
|
39
|
-
const
|
|
40
|
-
/* @__PURE__ */ i(
|
|
41
|
-
/* @__PURE__ */ i(
|
|
42
|
-
] }) : t,
|
|
43
|
-
if (!
|
|
44
|
-
return e &&
|
|
38
|
+
}, c) {
|
|
39
|
+
const s = /* @__PURE__ */ i(P, { size: 18, color: "inherit" }), p = e && r === void 0, h = () => p ? /* @__PURE__ */ y(v, { sx: { position: "relative" }, children: [
|
|
40
|
+
/* @__PURE__ */ i(ye, { children: s }),
|
|
41
|
+
/* @__PURE__ */ i(Me, { children: t })
|
|
42
|
+
] }) : t, d = (m) => {
|
|
43
|
+
if (!p)
|
|
44
|
+
return e && r !== void 0 ? r === m ? s : void 0 : m === "start" ? o : a;
|
|
45
45
|
};
|
|
46
46
|
return /* @__PURE__ */ i(
|
|
47
|
-
|
|
47
|
+
gt,
|
|
48
48
|
{
|
|
49
49
|
disabled: e || n,
|
|
50
|
-
startIcon:
|
|
51
|
-
endIcon:
|
|
50
|
+
startIcon: d("start"),
|
|
51
|
+
endIcon: d("end"),
|
|
52
52
|
...l,
|
|
53
|
-
|
|
54
|
-
|
|
53
|
+
role: "button",
|
|
54
|
+
ref: c,
|
|
55
|
+
children: /* @__PURE__ */ i(S, { variant: "inherit", color: "inherit", noWrap: !0, component: "span", children: h() })
|
|
55
56
|
}
|
|
56
57
|
);
|
|
57
58
|
}
|
|
58
|
-
const
|
|
59
|
+
const bo = T(Ce), ve = g(v)(({ theme: t }) => ({
|
|
59
60
|
display: "flex",
|
|
60
61
|
alignItems: "center",
|
|
61
62
|
gap: t.spacing(0.5)
|
|
62
|
-
})),
|
|
63
|
+
})), ke = g(S)(({ theme: t }) => ({
|
|
63
64
|
".Mui-disabled &": {
|
|
64
65
|
color: t.palette.text.disabled
|
|
65
66
|
}
|
|
66
|
-
})),
|
|
67
|
+
})), De = g(v)(({ theme: t }) => ({
|
|
67
68
|
display: "flex",
|
|
68
69
|
svg: {
|
|
69
|
-
width:
|
|
70
|
-
height:
|
|
71
|
-
fontSize:
|
|
70
|
+
width: G,
|
|
71
|
+
height: G,
|
|
72
|
+
fontSize: G,
|
|
72
73
|
path: {
|
|
73
74
|
fill: t.palette.text.secondary,
|
|
74
75
|
".Mui-disabled &": {
|
|
@@ -77,16 +78,16 @@ const uo = O(xe), Me = p(v)(({ theme: t }) => ({
|
|
|
77
78
|
}
|
|
78
79
|
}
|
|
79
80
|
}));
|
|
80
|
-
function
|
|
81
|
+
function K({
|
|
81
82
|
label: t,
|
|
82
83
|
type: e,
|
|
83
84
|
icon: n,
|
|
84
85
|
inheritSize: o
|
|
85
86
|
}) {
|
|
86
|
-
return /* @__PURE__ */ y(
|
|
87
|
+
return /* @__PURE__ */ y(ve, { children: [
|
|
87
88
|
t,
|
|
88
89
|
e && /* @__PURE__ */ i(
|
|
89
|
-
|
|
90
|
+
ke,
|
|
90
91
|
{
|
|
91
92
|
component: "span",
|
|
92
93
|
variant: o ? "inherit" : "caption",
|
|
@@ -95,13 +96,13 @@ function X({
|
|
|
95
96
|
children: e === "required" ? "(required)" : "(optional)"
|
|
96
97
|
}
|
|
97
98
|
),
|
|
98
|
-
n && /* @__PURE__ */ i(
|
|
99
|
+
n && /* @__PURE__ */ i(De, { children: n })
|
|
99
100
|
] });
|
|
100
101
|
}
|
|
101
102
|
function Ae({ InputProps: t, size: e = "small", ...n }, o) {
|
|
102
|
-
const
|
|
103
|
+
const a = F(), r = R(a), [l, c] = $(!1);
|
|
103
104
|
return /* @__PURE__ */ i(
|
|
104
|
-
|
|
105
|
+
ft,
|
|
105
106
|
{
|
|
106
107
|
...n,
|
|
107
108
|
ref: o,
|
|
@@ -109,26 +110,26 @@ function Ae({ InputProps: t, size: e = "small", ...n }, o) {
|
|
|
109
110
|
size: e,
|
|
110
111
|
InputProps: {
|
|
111
112
|
...t,
|
|
112
|
-
endAdornment: /* @__PURE__ */ i(q, { position: "end", children: /* @__PURE__ */ i(
|
|
113
|
-
|
|
113
|
+
endAdornment: /* @__PURE__ */ i(q, { position: "end", children: /* @__PURE__ */ i(W, { size: e, onClick: () => c(!l), children: /* @__PURE__ */ i(
|
|
114
|
+
H,
|
|
114
115
|
{
|
|
115
|
-
title:
|
|
116
|
+
title: r.formatMessage({
|
|
116
117
|
id: `c4r.form.${l ? "hidePassword" : "showPassword"}`
|
|
117
118
|
}),
|
|
118
|
-
children: l ? /* @__PURE__ */ i(
|
|
119
|
+
children: l ? /* @__PURE__ */ i(ce, {}) : /* @__PURE__ */ i(se, {})
|
|
119
120
|
}
|
|
120
121
|
) }) })
|
|
121
122
|
}
|
|
122
123
|
}
|
|
123
124
|
);
|
|
124
125
|
}
|
|
125
|
-
const
|
|
126
|
-
function
|
|
127
|
-
|
|
128
|
-
const e = ++
|
|
126
|
+
const xo = T(Ae), U = {};
|
|
127
|
+
function Ie(t = "$lodash$") {
|
|
128
|
+
U[t] || (U[t] = 0);
|
|
129
|
+
const e = ++U[t];
|
|
129
130
|
return t === "$lodash$" ? `${e}` : `${t}${e}`;
|
|
130
131
|
}
|
|
131
|
-
const
|
|
132
|
+
const we = g(Wt)(({ theme: t }) => ({
|
|
132
133
|
"& .MuiInputAdornment-positionStart": {
|
|
133
134
|
paddingLeft: t.spacing(2),
|
|
134
135
|
"&.MuiInputAdornment-sizeSmall": {
|
|
@@ -144,62 +145,62 @@ const De = p(Ot)(({ theme: t }) => ({
|
|
|
144
145
|
"&.MuiInputBase-root .MuiSelect-select.MuiSelect-multiple": {
|
|
145
146
|
paddingRight: t.spacing(7)
|
|
146
147
|
}
|
|
147
|
-
})),
|
|
148
|
+
})), Be = g(mt)(() => ({
|
|
148
149
|
display: "none"
|
|
149
150
|
}));
|
|
150
|
-
function
|
|
151
|
+
function Se({
|
|
151
152
|
children: t,
|
|
152
153
|
placeholder: e,
|
|
153
154
|
size: n = "small",
|
|
154
155
|
displayEmpty: o,
|
|
155
|
-
menuProps:
|
|
156
|
-
inputProps:
|
|
156
|
+
menuProps: a,
|
|
157
|
+
inputProps: r,
|
|
157
158
|
labelId: l,
|
|
158
|
-
label:
|
|
159
|
-
labelSecondary:
|
|
160
|
-
helperText:
|
|
159
|
+
label: c,
|
|
160
|
+
labelSecondary: s,
|
|
161
|
+
helperText: p,
|
|
161
162
|
name: h,
|
|
162
|
-
error:
|
|
163
|
-
focused:
|
|
164
|
-
disabled:
|
|
165
|
-
fullWidth:
|
|
166
|
-
required:
|
|
163
|
+
error: d,
|
|
164
|
+
focused: m,
|
|
165
|
+
disabled: u,
|
|
166
|
+
fullWidth: f,
|
|
167
|
+
required: M,
|
|
167
168
|
"aria-label": b,
|
|
168
169
|
...I
|
|
169
|
-
},
|
|
170
|
-
const
|
|
170
|
+
}, k) {
|
|
171
|
+
const D = n === "small", [x] = $(() => Ie("select-label-")), C = c ? l ?? x : void 0;
|
|
171
172
|
return /* @__PURE__ */ y(
|
|
172
|
-
|
|
173
|
+
Et,
|
|
173
174
|
{
|
|
174
175
|
size: n,
|
|
175
|
-
error:
|
|
176
|
-
focused:
|
|
177
|
-
disabled:
|
|
178
|
-
fullWidth:
|
|
179
|
-
required:
|
|
176
|
+
error: d,
|
|
177
|
+
focused: m,
|
|
178
|
+
disabled: u,
|
|
179
|
+
fullWidth: f,
|
|
180
|
+
required: M,
|
|
180
181
|
children: [
|
|
181
182
|
/* @__PURE__ */ y(v, { display: "flex", alignItems: "center", justifyContent: "space-between", children: [
|
|
182
|
-
|
|
183
|
-
|
|
183
|
+
c && /* @__PURE__ */ i(Ht, { shrink: !0, id: C, children: c }),
|
|
184
|
+
s && /* @__PURE__ */ i(v, { display: "flex", alignItems: "center", ml: 2, mb: 0.5, children: s })
|
|
184
185
|
] }),
|
|
185
186
|
/* @__PURE__ */ y(
|
|
186
|
-
|
|
187
|
+
we,
|
|
187
188
|
{
|
|
188
189
|
...I,
|
|
189
|
-
labelId:
|
|
190
|
+
labelId: C,
|
|
190
191
|
name: h,
|
|
191
|
-
ref:
|
|
192
|
+
ref: k,
|
|
192
193
|
size: n,
|
|
193
|
-
fullWidth:
|
|
194
|
+
fullWidth: f,
|
|
194
195
|
displayEmpty: o ?? !!e,
|
|
195
196
|
inputProps: {
|
|
196
|
-
...
|
|
197
|
+
...r,
|
|
197
198
|
"aria-label": b
|
|
198
199
|
},
|
|
199
200
|
MenuProps: {
|
|
200
|
-
...
|
|
201
|
+
...a,
|
|
201
202
|
PopoverClasses: {
|
|
202
|
-
paper:
|
|
203
|
+
paper: D ? "MuiMenu-paper-sizeSmall" : void 0
|
|
203
204
|
},
|
|
204
205
|
anchorOrigin: {
|
|
205
206
|
vertical: "bottom",
|
|
@@ -211,10 +212,10 @@ function Be({
|
|
|
211
212
|
}
|
|
212
213
|
},
|
|
213
214
|
children: [
|
|
214
|
-
e && /* @__PURE__ */ i(
|
|
215
|
-
|
|
215
|
+
e && /* @__PURE__ */ i(Be, { disabled: !0, value: "", children: /* @__PURE__ */ i(
|
|
216
|
+
S,
|
|
216
217
|
{
|
|
217
|
-
variant:
|
|
218
|
+
variant: D ? "body2" : "body1",
|
|
218
219
|
color: "text.hint",
|
|
219
220
|
component: "span",
|
|
220
221
|
children: e
|
|
@@ -224,12 +225,12 @@ function Be({
|
|
|
224
225
|
]
|
|
225
226
|
}
|
|
226
227
|
),
|
|
227
|
-
|
|
228
|
+
p && /* @__PURE__ */ i(ht, { "aria-label": `${h}-helper`, children: p })
|
|
228
229
|
]
|
|
229
230
|
}
|
|
230
231
|
);
|
|
231
232
|
}
|
|
232
|
-
const
|
|
233
|
+
const Te = T(Se), $e = g(_t, {
|
|
233
234
|
shouldForwardProp: (t) => t !== "variant" && t !== "backgroundColor"
|
|
234
235
|
})(({ variant: t, backgroundColor: e, theme: n }) => ({
|
|
235
236
|
// Variants
|
|
@@ -301,14 +302,14 @@ const we = O(Be), Se = p(Pt, {
|
|
|
301
302
|
backgroundColor: "transparent"
|
|
302
303
|
}
|
|
303
304
|
}));
|
|
304
|
-
function
|
|
305
|
+
function yo({
|
|
305
306
|
children: t,
|
|
306
307
|
variant: e = "floating",
|
|
307
308
|
backgroundColor: n,
|
|
308
309
|
...o
|
|
309
310
|
}) {
|
|
310
311
|
return /* @__PURE__ */ i(
|
|
311
|
-
|
|
312
|
+
$e,
|
|
312
313
|
{
|
|
313
314
|
...o,
|
|
314
315
|
variant: e,
|
|
@@ -317,7 +318,7 @@ function go({
|
|
|
317
318
|
}
|
|
318
319
|
);
|
|
319
320
|
}
|
|
320
|
-
const
|
|
321
|
+
const Re = g("div")(({ theme: t }) => ({
|
|
321
322
|
position: "relative",
|
|
322
323
|
display: "inline-flex",
|
|
323
324
|
// TODO: Remove this once we have a better way to handle the spacing between icon buttons:
|
|
@@ -325,7 +326,7 @@ const Te = p("div")(({ theme: t }) => ({
|
|
|
325
326
|
"& + &, & + .optionIconButton": {
|
|
326
327
|
marginLeft: t.spacing(0.5)
|
|
327
328
|
}
|
|
328
|
-
})),
|
|
329
|
+
})), Fe = g(W, {
|
|
329
330
|
shouldForwardProp: (t) => !["active"].includes(t)
|
|
330
331
|
})(({ active: t, theme: e }) => ({
|
|
331
332
|
...t && {
|
|
@@ -336,43 +337,44 @@ const Te = p("div")(({ theme: t }) => ({
|
|
|
336
337
|
}
|
|
337
338
|
}
|
|
338
339
|
}));
|
|
339
|
-
function
|
|
340
|
+
function Oe({
|
|
340
341
|
tooltip: t,
|
|
341
342
|
tooltipPlacement: e = "top",
|
|
342
343
|
icon: n,
|
|
343
344
|
size: o = "medium",
|
|
344
|
-
variant:
|
|
345
|
-
color:
|
|
345
|
+
variant: a = "icon",
|
|
346
|
+
color: r = "default",
|
|
346
347
|
sx: l,
|
|
347
|
-
className:
|
|
348
|
-
loading:
|
|
349
|
-
disabled:
|
|
348
|
+
className: c,
|
|
349
|
+
loading: s,
|
|
350
|
+
disabled: p,
|
|
350
351
|
active: h,
|
|
351
|
-
...
|
|
352
|
-
},
|
|
353
|
-
return /* @__PURE__ */ i(
|
|
354
|
-
|
|
352
|
+
...d
|
|
353
|
+
}, m) {
|
|
354
|
+
return /* @__PURE__ */ i(H, { placement: e, title: t ?? "", children: /* @__PURE__ */ i(
|
|
355
|
+
Re,
|
|
355
356
|
{
|
|
356
|
-
className: `optionIconButton ${
|
|
357
|
+
className: `optionIconButton ${c ?? ""}`,
|
|
357
358
|
sx: l,
|
|
358
359
|
"data-testid": "icon-button",
|
|
359
360
|
children: /* @__PURE__ */ i(
|
|
360
|
-
|
|
361
|
+
Fe,
|
|
361
362
|
{
|
|
362
|
-
...
|
|
363
|
-
ref:
|
|
363
|
+
...d,
|
|
364
|
+
ref: m,
|
|
364
365
|
size: o,
|
|
365
|
-
variant:
|
|
366
|
-
color:
|
|
366
|
+
variant: a,
|
|
367
|
+
color: r,
|
|
367
368
|
active: h,
|
|
368
|
-
disabled:
|
|
369
|
-
|
|
369
|
+
disabled: p || s,
|
|
370
|
+
role: "button",
|
|
371
|
+
children: s ? /* @__PURE__ */ i(P, { size: 18, color: "inherit" }) : n
|
|
370
372
|
}
|
|
371
373
|
)
|
|
372
374
|
}
|
|
373
375
|
) });
|
|
374
376
|
}
|
|
375
|
-
const
|
|
377
|
+
const Le = T(Oe), We = g(Pt, {
|
|
376
378
|
shouldForwardProp: (t) => !["extended", "width", "height"].includes(t)
|
|
377
379
|
})(({ theme: t, extended: e, width: n, height: o }) => ({
|
|
378
380
|
...e && {
|
|
@@ -395,10 +397,26 @@ const Fe = O(Re), Oe = p(Et, {
|
|
|
395
397
|
}
|
|
396
398
|
}
|
|
397
399
|
}));
|
|
398
|
-
function
|
|
399
|
-
return /* @__PURE__ */ i(
|
|
400
|
+
function Ee({ extended: t, width: e, height: n, MenuListProps: o, ...a }, r) {
|
|
401
|
+
return /* @__PURE__ */ i(
|
|
402
|
+
We,
|
|
403
|
+
{
|
|
404
|
+
...a,
|
|
405
|
+
ref: r,
|
|
406
|
+
"data-name": "menu",
|
|
407
|
+
width: e,
|
|
408
|
+
height: n,
|
|
409
|
+
extended: t,
|
|
410
|
+
MenuListProps: {
|
|
411
|
+
...o,
|
|
412
|
+
"data-width": e,
|
|
413
|
+
"data-height": n,
|
|
414
|
+
"data-extended": t
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
);
|
|
400
418
|
}
|
|
401
|
-
const
|
|
419
|
+
const Mo = T(Ee), He = g(Gt, {
|
|
402
420
|
shouldForwardProp: (t) => !["extended", "width", "height"].includes(t)
|
|
403
421
|
})(({ theme: t, extended: e, width: n, height: o }) => ({
|
|
404
422
|
...e && {
|
|
@@ -416,12 +434,25 @@ const Le = p(Ht, {
|
|
|
416
434
|
}
|
|
417
435
|
}
|
|
418
436
|
}));
|
|
419
|
-
function
|
|
420
|
-
return /* @__PURE__ */ i(
|
|
437
|
+
function _e({ extended: t, width: e, height: n, ...o }, a) {
|
|
438
|
+
return /* @__PURE__ */ i(
|
|
439
|
+
He,
|
|
440
|
+
{
|
|
441
|
+
...o,
|
|
442
|
+
ref: a,
|
|
443
|
+
width: e,
|
|
444
|
+
height: n,
|
|
445
|
+
extended: t,
|
|
446
|
+
"data-name": "menu-list",
|
|
447
|
+
"data-width": e,
|
|
448
|
+
"data-height": n,
|
|
449
|
+
"data-extended": t
|
|
450
|
+
}
|
|
451
|
+
);
|
|
421
452
|
}
|
|
422
|
-
const
|
|
453
|
+
const Co = T(_e), Pe = g(vt)(() => ({
|
|
423
454
|
marginTop: "0 !important"
|
|
424
|
-
})),
|
|
455
|
+
})), Ge = g(jt)(
|
|
425
456
|
({ disabled: t, theme: e }) => ({
|
|
426
457
|
display: "flex",
|
|
427
458
|
alignItems: "center",
|
|
@@ -434,15 +465,16 @@ const We = p(Ct)(() => ({
|
|
|
434
465
|
}
|
|
435
466
|
})
|
|
436
467
|
);
|
|
437
|
-
function
|
|
468
|
+
function je({
|
|
438
469
|
areAllSelected: t,
|
|
439
470
|
areAnySelected: e,
|
|
440
471
|
selectAll: n,
|
|
441
|
-
selectAllDisabled: o
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
472
|
+
selectAllDisabled: o,
|
|
473
|
+
...a
|
|
474
|
+
}, r) {
|
|
475
|
+
const l = F(), c = R(l);
|
|
476
|
+
return /* @__PURE__ */ i(Pe, { ...a, ref: r, fixed: !0, "data-name": "menu-filter", children: /* @__PURE__ */ y(
|
|
477
|
+
Ge,
|
|
446
478
|
{
|
|
447
479
|
variant: "body2",
|
|
448
480
|
color: "textPrimary",
|
|
@@ -460,48 +492,49 @@ function vt({
|
|
|
460
492
|
disabled: o
|
|
461
493
|
}
|
|
462
494
|
),
|
|
463
|
-
|
|
495
|
+
c.formatMessage({ id: "c4r.form.selectAll" })
|
|
464
496
|
]
|
|
465
497
|
}
|
|
466
498
|
) });
|
|
467
499
|
}
|
|
468
|
-
|
|
500
|
+
const kt = T(je);
|
|
501
|
+
function Ve({
|
|
469
502
|
selectedOptions: t,
|
|
470
503
|
options: e,
|
|
471
504
|
onChange: n
|
|
472
505
|
}) {
|
|
473
|
-
const [o,
|
|
474
|
-
return
|
|
475
|
-
o !== t &&
|
|
506
|
+
const [o, a] = $(t ?? []), r = e.length === o.length, l = o.length > 0;
|
|
507
|
+
return _(() => {
|
|
508
|
+
o !== t && a(o);
|
|
476
509
|
}, [t]), {
|
|
477
|
-
areAllSelected:
|
|
510
|
+
areAllSelected: r,
|
|
478
511
|
areAnySelected: l,
|
|
479
512
|
currentOptions: o,
|
|
480
513
|
handleChange: (h) => {
|
|
481
514
|
const {
|
|
482
|
-
target: { value:
|
|
483
|
-
} = h,
|
|
484
|
-
|
|
515
|
+
target: { value: d }
|
|
516
|
+
} = h, m = typeof d == "string" ? d.split(",") : d.filter((u) => u !== void 0);
|
|
517
|
+
a(m), n(m);
|
|
485
518
|
},
|
|
486
519
|
selectAll: () => {
|
|
487
|
-
const h = e == null ? void 0 : e.filter(({ disabled:
|
|
520
|
+
const h = e == null ? void 0 : e.filter(({ disabled: d }) => !d).map(({ value: d }) => d);
|
|
488
521
|
h && (h.every(
|
|
489
|
-
(
|
|
490
|
-
) ? (
|
|
522
|
+
(m) => o.includes(m)
|
|
523
|
+
) ? (a([]), n([])) : (a(h), n(h)));
|
|
491
524
|
},
|
|
492
525
|
unselectAll: () => {
|
|
493
|
-
|
|
526
|
+
a([]), n([]);
|
|
494
527
|
}
|
|
495
528
|
};
|
|
496
529
|
}
|
|
497
|
-
const
|
|
530
|
+
const Ne = g(mt)(({ theme: t }) => ({
|
|
498
531
|
"&.Mui-disabled": {
|
|
499
532
|
pointerEvents: "auto",
|
|
500
533
|
"&:hover": {
|
|
501
534
|
backgroundColor: `${t.palette.background.default} !important`
|
|
502
535
|
}
|
|
503
536
|
}
|
|
504
|
-
})),
|
|
537
|
+
})), Ue = g(q, {
|
|
505
538
|
shouldForwardProp: (t) => t !== "size"
|
|
506
539
|
})(({ theme: t, size: e }) => ({
|
|
507
540
|
display: "none",
|
|
@@ -518,86 +551,86 @@ const He = p(ft)(({ theme: t }) => ({
|
|
|
518
551
|
top: t.spacing(3),
|
|
519
552
|
right: t.spacing(5)
|
|
520
553
|
}
|
|
521
|
-
})),
|
|
554
|
+
})), Ye = [], qe = () => {
|
|
522
555
|
};
|
|
523
|
-
function
|
|
524
|
-
options: t =
|
|
556
|
+
function ze({
|
|
557
|
+
options: t = Ye,
|
|
525
558
|
selectedOptions: e,
|
|
526
559
|
size: n = "small",
|
|
527
560
|
placeholder: o,
|
|
528
|
-
showCounter:
|
|
529
|
-
showFilters:
|
|
530
|
-
onChange: l =
|
|
531
|
-
selectAllDisabled:
|
|
532
|
-
tooltipPlacement:
|
|
533
|
-
variant:
|
|
561
|
+
showCounter: a,
|
|
562
|
+
showFilters: r = !0,
|
|
563
|
+
onChange: l = qe,
|
|
564
|
+
selectAllDisabled: c,
|
|
565
|
+
tooltipPlacement: s,
|
|
566
|
+
variant: p,
|
|
534
567
|
...h
|
|
535
|
-
},
|
|
568
|
+
}, d) {
|
|
536
569
|
const {
|
|
537
|
-
areAllSelected:
|
|
538
|
-
areAnySelected:
|
|
539
|
-
currentOptions:
|
|
540
|
-
handleChange:
|
|
570
|
+
areAllSelected: m,
|
|
571
|
+
areAnySelected: u,
|
|
572
|
+
currentOptions: f,
|
|
573
|
+
handleChange: M,
|
|
541
574
|
selectAll: b,
|
|
542
575
|
unselectAll: I
|
|
543
|
-
} =
|
|
576
|
+
} = Ve({
|
|
544
577
|
options: t,
|
|
545
578
|
selectedOptions: e,
|
|
546
579
|
onChange: l
|
|
547
|
-
}),
|
|
580
|
+
}), k = n === "small", D = k || p === "standard" ? 0 : 2, x = F(), C = R(x), B = `${f.length} ${C.formatMessage({
|
|
548
581
|
id: "c4r.form.selected"
|
|
549
|
-
})}`,
|
|
550
|
-
|
|
582
|
+
})}`, O = pt(() => m ? /* @__PURE__ */ i(
|
|
583
|
+
S,
|
|
551
584
|
{
|
|
552
585
|
component: "span",
|
|
553
|
-
variant:
|
|
586
|
+
variant: k ? "body2" : "body1",
|
|
554
587
|
color: "textPrimary",
|
|
555
|
-
ml:
|
|
556
|
-
children:
|
|
588
|
+
ml: D,
|
|
589
|
+
children: C.formatMessage({ id: "c4r.form.allSelected" })
|
|
557
590
|
}
|
|
558
|
-
) :
|
|
559
|
-
|
|
591
|
+
) : u ? /* @__PURE__ */ i(
|
|
592
|
+
S,
|
|
560
593
|
{
|
|
561
594
|
component: "span",
|
|
562
|
-
variant:
|
|
595
|
+
variant: k ? "body2" : "body1",
|
|
563
596
|
color: "textPrimary",
|
|
564
|
-
ml:
|
|
565
|
-
children:
|
|
597
|
+
ml: D,
|
|
598
|
+
children: a && f.length > 1 ? B : f.join(", ")
|
|
566
599
|
}
|
|
567
600
|
) : /* @__PURE__ */ i(
|
|
568
|
-
|
|
601
|
+
S,
|
|
569
602
|
{
|
|
570
603
|
component: "span",
|
|
571
|
-
variant:
|
|
604
|
+
variant: k ? "body2" : "body1",
|
|
572
605
|
color: "text.hint",
|
|
573
|
-
ml:
|
|
574
|
-
children: o ??
|
|
606
|
+
ml: D,
|
|
607
|
+
children: o ?? C.formatMessage({ id: "c4r.form.noneSelected" })
|
|
575
608
|
}
|
|
576
609
|
), [
|
|
577
|
-
g,
|
|
578
|
-
f,
|
|
579
|
-
D,
|
|
580
610
|
m,
|
|
581
|
-
|
|
611
|
+
u,
|
|
582
612
|
B,
|
|
583
|
-
|
|
613
|
+
f,
|
|
614
|
+
C,
|
|
615
|
+
k,
|
|
616
|
+
D,
|
|
584
617
|
o,
|
|
585
|
-
|
|
618
|
+
a
|
|
586
619
|
]);
|
|
587
620
|
return /* @__PURE__ */ y(
|
|
588
|
-
|
|
621
|
+
Te,
|
|
589
622
|
{
|
|
590
623
|
...h,
|
|
591
|
-
ref:
|
|
624
|
+
ref: d,
|
|
592
625
|
multiple: !0,
|
|
593
626
|
displayEmpty: !0,
|
|
594
627
|
placeholder: o,
|
|
595
|
-
value:
|
|
596
|
-
renderValue: () =>
|
|
597
|
-
onChange:
|
|
628
|
+
value: f,
|
|
629
|
+
renderValue: () => O,
|
|
630
|
+
onChange: M,
|
|
598
631
|
size: n,
|
|
599
|
-
variant:
|
|
600
|
-
endAdornment:
|
|
632
|
+
variant: p,
|
|
633
|
+
endAdornment: r && u && /* @__PURE__ */ i(Ue, { position: "end", size: n, children: /* @__PURE__ */ i(W, { onClick: I, size: n, children: /* @__PURE__ */ i(yt, {}) }) }),
|
|
601
634
|
menuProps: {
|
|
602
635
|
PaperProps: {
|
|
603
636
|
sx: {
|
|
@@ -608,50 +641,50 @@ function Ne({
|
|
|
608
641
|
}
|
|
609
642
|
},
|
|
610
643
|
children: [
|
|
611
|
-
|
|
612
|
-
|
|
644
|
+
r && /* @__PURE__ */ i(
|
|
645
|
+
kt,
|
|
613
646
|
{
|
|
614
|
-
areAllSelected:
|
|
615
|
-
areAnySelected:
|
|
647
|
+
areAllSelected: m,
|
|
648
|
+
areAnySelected: u,
|
|
616
649
|
selectAll: b,
|
|
617
|
-
selectAllDisabled:
|
|
650
|
+
selectAllDisabled: c
|
|
618
651
|
}
|
|
619
652
|
),
|
|
620
|
-
t == null ? void 0 : t.map((
|
|
621
|
-
const
|
|
622
|
-
|
|
653
|
+
t == null ? void 0 : t.map((w) => {
|
|
654
|
+
const E = /* @__PURE__ */ y(
|
|
655
|
+
Ne,
|
|
623
656
|
{
|
|
624
|
-
value:
|
|
625
|
-
disabled:
|
|
657
|
+
value: w.value,
|
|
658
|
+
disabled: w.disabled,
|
|
626
659
|
tabIndex: 0,
|
|
627
660
|
children: [
|
|
628
661
|
/* @__PURE__ */ i(
|
|
629
662
|
z,
|
|
630
663
|
{
|
|
631
|
-
disabled:
|
|
632
|
-
checked:
|
|
664
|
+
disabled: w.disabled,
|
|
665
|
+
checked: f.includes(w.value)
|
|
633
666
|
}
|
|
634
667
|
),
|
|
635
|
-
/* @__PURE__ */ i(
|
|
668
|
+
/* @__PURE__ */ i(bt, { primary: w.label })
|
|
636
669
|
]
|
|
637
670
|
},
|
|
638
|
-
|
|
671
|
+
w.value
|
|
639
672
|
);
|
|
640
|
-
return
|
|
641
|
-
|
|
673
|
+
return w.tooltip ? /* @__PURE__ */ i(
|
|
674
|
+
H,
|
|
642
675
|
{
|
|
643
|
-
title:
|
|
644
|
-
placement:
|
|
645
|
-
children:
|
|
676
|
+
title: w.tooltip,
|
|
677
|
+
placement: s,
|
|
678
|
+
children: E
|
|
646
679
|
},
|
|
647
|
-
|
|
648
|
-
) :
|
|
680
|
+
w.value
|
|
681
|
+
) : E;
|
|
649
682
|
})
|
|
650
683
|
]
|
|
651
684
|
}
|
|
652
685
|
);
|
|
653
686
|
}
|
|
654
|
-
const
|
|
687
|
+
const vo = T(ze), Ze = g(ft, {
|
|
655
688
|
shouldForwardProp: (t) => t !== "cursor"
|
|
656
689
|
})(
|
|
657
690
|
({ cursor: t, theme: e }) => ({
|
|
@@ -679,65 +712,65 @@ const mo = O(Ne), Ve = p(gt, {
|
|
|
679
712
|
}
|
|
680
713
|
})
|
|
681
714
|
);
|
|
682
|
-
function
|
|
715
|
+
function Je({
|
|
683
716
|
buttonText: t,
|
|
684
717
|
hasFiles: e,
|
|
685
718
|
size: n,
|
|
686
719
|
error: o,
|
|
687
|
-
disabled:
|
|
688
|
-
handleReset:
|
|
720
|
+
disabled: a,
|
|
721
|
+
handleReset: r,
|
|
689
722
|
handleOpen: l,
|
|
690
|
-
inProgress:
|
|
723
|
+
inProgress: c
|
|
691
724
|
}) {
|
|
692
|
-
return /* @__PURE__ */ i(q, { position: "end", children:
|
|
693
|
-
|
|
725
|
+
return /* @__PURE__ */ i(q, { position: "end", children: c ? /* @__PURE__ */ i(W, { "aria-label": "loading", disabled: !0, size: n, children: /* @__PURE__ */ i(P, { size: 18 }) }) : e ? /* @__PURE__ */ i(
|
|
726
|
+
W,
|
|
694
727
|
{
|
|
695
|
-
onClick:
|
|
728
|
+
onClick: r,
|
|
696
729
|
size: n,
|
|
697
730
|
"aria-label": "delete",
|
|
698
|
-
disabled:
|
|
731
|
+
disabled: a,
|
|
699
732
|
children: /* @__PURE__ */ i(yt, {})
|
|
700
733
|
}
|
|
701
734
|
) : /* @__PURE__ */ i(
|
|
702
|
-
|
|
735
|
+
gt,
|
|
703
736
|
{
|
|
704
737
|
onClick: l,
|
|
705
738
|
size: n,
|
|
706
739
|
variant: "text",
|
|
707
740
|
color: o ? "default" : "primary",
|
|
708
|
-
disabled:
|
|
741
|
+
disabled: a,
|
|
709
742
|
children: t
|
|
710
743
|
}
|
|
711
744
|
) });
|
|
712
745
|
}
|
|
713
|
-
function
|
|
746
|
+
function Xe({
|
|
714
747
|
name: t,
|
|
715
748
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
716
749
|
multiple: e,
|
|
717
750
|
// multiple prop defined here for compatibility with cloud-native but not used in the component
|
|
718
751
|
handleReset: n,
|
|
719
752
|
handleOpen: o,
|
|
720
|
-
dragOver:
|
|
721
|
-
error:
|
|
753
|
+
dragOver: a,
|
|
754
|
+
error: r,
|
|
722
755
|
placeholder: l,
|
|
723
|
-
focused:
|
|
724
|
-
buttonText:
|
|
725
|
-
inProgress:
|
|
756
|
+
focused: c,
|
|
757
|
+
buttonText: s = "Browse",
|
|
758
|
+
inProgress: p,
|
|
726
759
|
InputProps: h,
|
|
727
|
-
size:
|
|
728
|
-
hasFiles:
|
|
729
|
-
cursor:
|
|
730
|
-
...
|
|
760
|
+
size: d = "small",
|
|
761
|
+
hasFiles: m,
|
|
762
|
+
cursor: u = "pointer",
|
|
763
|
+
...f
|
|
731
764
|
}) {
|
|
732
765
|
return /* @__PURE__ */ i(
|
|
733
|
-
|
|
766
|
+
Ze,
|
|
734
767
|
{
|
|
735
|
-
...
|
|
736
|
-
size:
|
|
737
|
-
error:
|
|
768
|
+
...f,
|
|
769
|
+
size: d,
|
|
770
|
+
error: r,
|
|
738
771
|
placeholder: l,
|
|
739
|
-
focused:
|
|
740
|
-
cursor:
|
|
772
|
+
focused: c ?? a,
|
|
773
|
+
cursor: u,
|
|
741
774
|
InputProps: {
|
|
742
775
|
...h,
|
|
743
776
|
name: t,
|
|
@@ -745,129 +778,129 @@ function qe({
|
|
|
745
778
|
// not used for any UI logic
|
|
746
779
|
readOnly: !0,
|
|
747
780
|
endAdornment: /* @__PURE__ */ i(
|
|
748
|
-
|
|
781
|
+
Je,
|
|
749
782
|
{
|
|
750
|
-
buttonText:
|
|
751
|
-
hasFiles:
|
|
752
|
-
size:
|
|
753
|
-
error:
|
|
754
|
-
disabled: !!
|
|
783
|
+
buttonText: s,
|
|
784
|
+
hasFiles: m,
|
|
785
|
+
size: d,
|
|
786
|
+
error: r,
|
|
787
|
+
disabled: !!a,
|
|
755
788
|
handleReset: n,
|
|
756
789
|
handleOpen: o,
|
|
757
|
-
inProgress:
|
|
790
|
+
inProgress: p
|
|
758
791
|
}
|
|
759
792
|
)
|
|
760
793
|
}
|
|
761
794
|
}
|
|
762
795
|
);
|
|
763
796
|
}
|
|
764
|
-
function
|
|
797
|
+
function Ke({
|
|
765
798
|
onChange: t,
|
|
766
799
|
files: e,
|
|
767
800
|
multiple: n,
|
|
768
801
|
placeholder: o,
|
|
769
|
-
uploadInputRef:
|
|
802
|
+
uploadInputRef: a
|
|
770
803
|
}) {
|
|
771
|
-
const
|
|
772
|
-
|
|
773
|
-
!e || e.length === 0 ?
|
|
804
|
+
const r = F(), l = R(r), [c, s] = $(""), [p, h] = $(!1);
|
|
805
|
+
_(() => {
|
|
806
|
+
!e || e.length === 0 ? s("") : e.length === 1 ? s(e[0].name) : s(
|
|
774
807
|
l.formatMessage(
|
|
775
808
|
{ id: "c4r.form.filesSelected" },
|
|
776
809
|
{ count: e.length }
|
|
777
810
|
)
|
|
778
811
|
);
|
|
779
812
|
}, [e, l]);
|
|
780
|
-
const
|
|
781
|
-
var
|
|
782
|
-
(
|
|
783
|
-
},
|
|
784
|
-
|
|
785
|
-
},
|
|
786
|
-
|
|
787
|
-
},
|
|
788
|
-
|
|
789
|
-
const
|
|
790
|
-
t == null || t(
|
|
791
|
-
},
|
|
792
|
-
const
|
|
793
|
-
for (const
|
|
794
|
-
if (
|
|
795
|
-
const
|
|
796
|
-
|
|
813
|
+
const d = () => {
|
|
814
|
+
var x;
|
|
815
|
+
(x = a.current) == null || x.click();
|
|
816
|
+
}, m = (x) => {
|
|
817
|
+
x.preventDefault(), h(!0);
|
|
818
|
+
}, u = (x) => {
|
|
819
|
+
x.preventDefault(), h(!1);
|
|
820
|
+
}, f = (x) => {
|
|
821
|
+
x.preventDefault(), h(!1);
|
|
822
|
+
const C = x.dataTransfer.items, B = M(C);
|
|
823
|
+
t == null || t(B);
|
|
824
|
+
}, M = (x) => {
|
|
825
|
+
const C = [];
|
|
826
|
+
for (const B of Array.from(x))
|
|
827
|
+
if (B.kind === "file") {
|
|
828
|
+
const O = B.getAsFile();
|
|
829
|
+
C.push(O);
|
|
797
830
|
}
|
|
798
|
-
return
|
|
799
|
-
}, b = (
|
|
800
|
-
const
|
|
801
|
-
t == null || t(
|
|
802
|
-
}, I = (
|
|
803
|
-
|
|
804
|
-
},
|
|
805
|
-
const
|
|
831
|
+
return C;
|
|
832
|
+
}, b = (x) => {
|
|
833
|
+
const C = Array.from(x.target.files);
|
|
834
|
+
t == null || t(C);
|
|
835
|
+
}, I = (x) => {
|
|
836
|
+
x.stopPropagation(), s("");
|
|
837
|
+
}, k = pt(() => {
|
|
838
|
+
const x = l.formatMessage(
|
|
806
839
|
{ id: "c4r.form.dragPlaceholder" },
|
|
807
840
|
{ count: n ? 0 : 1 }
|
|
808
|
-
),
|
|
841
|
+
), C = l.formatMessage(
|
|
809
842
|
{ id: "c4r.form.dragActivePlaceholder" },
|
|
810
843
|
{ count: n ? 0 : 1 }
|
|
811
844
|
);
|
|
812
|
-
let
|
|
813
|
-
return
|
|
814
|
-
}, [
|
|
845
|
+
let B = "";
|
|
846
|
+
return p ? B = C : B = o ?? x, B;
|
|
847
|
+
}, [p, n, o, l]);
|
|
815
848
|
return {
|
|
816
|
-
filesText:
|
|
817
|
-
getPlaceholder:
|
|
818
|
-
dragOver:
|
|
849
|
+
filesText: c,
|
|
850
|
+
getPlaceholder: k,
|
|
851
|
+
dragOver: p,
|
|
819
852
|
inputEvents: {
|
|
820
|
-
onDragOver:
|
|
821
|
-
onDragLeave:
|
|
822
|
-
onDrop:
|
|
823
|
-
onClick:
|
|
853
|
+
onDragOver: m,
|
|
854
|
+
onDragLeave: u,
|
|
855
|
+
onDrop: f,
|
|
856
|
+
onClick: d
|
|
824
857
|
},
|
|
825
858
|
handleFiles: b,
|
|
826
859
|
handleReset: I
|
|
827
860
|
};
|
|
828
861
|
}
|
|
829
|
-
const
|
|
830
|
-
function
|
|
862
|
+
const Qe = ["application/JSON"];
|
|
863
|
+
function ko({
|
|
831
864
|
name: t,
|
|
832
865
|
buttonText: e,
|
|
833
866
|
accept: n,
|
|
834
867
|
files: o,
|
|
835
|
-
inProgress:
|
|
836
|
-
onChange:
|
|
868
|
+
inProgress: a,
|
|
869
|
+
onChange: r,
|
|
837
870
|
multiple: l,
|
|
838
|
-
placeholder:
|
|
839
|
-
error:
|
|
840
|
-
focused:
|
|
871
|
+
placeholder: c,
|
|
872
|
+
error: s,
|
|
873
|
+
focused: p,
|
|
841
874
|
nativeInputProps: h,
|
|
842
|
-
...
|
|
875
|
+
...d
|
|
843
876
|
}) {
|
|
844
|
-
const
|
|
845
|
-
filesText:
|
|
846
|
-
getPlaceholder:
|
|
877
|
+
const m = n ?? Qe, u = Y(null), {
|
|
878
|
+
filesText: f,
|
|
879
|
+
getPlaceholder: M,
|
|
847
880
|
dragOver: b,
|
|
848
881
|
inputEvents: I,
|
|
849
|
-
handleFiles:
|
|
850
|
-
handleReset:
|
|
851
|
-
} =
|
|
852
|
-
uploadInputRef:
|
|
882
|
+
handleFiles: k,
|
|
883
|
+
handleReset: D
|
|
884
|
+
} = Ke({
|
|
885
|
+
uploadInputRef: u,
|
|
853
886
|
files: o,
|
|
854
|
-
onChange:
|
|
887
|
+
onChange: r,
|
|
855
888
|
multiple: l,
|
|
856
|
-
placeholder:
|
|
889
|
+
placeholder: c
|
|
857
890
|
});
|
|
858
|
-
return /* @__PURE__ */ y(
|
|
891
|
+
return /* @__PURE__ */ y(V, { children: [
|
|
859
892
|
/* @__PURE__ */ i(
|
|
860
|
-
|
|
893
|
+
Xe,
|
|
861
894
|
{
|
|
862
|
-
...
|
|
863
|
-
placeholder:
|
|
864
|
-
value:
|
|
865
|
-
error:
|
|
866
|
-
focused:
|
|
867
|
-
handleReset:
|
|
895
|
+
...d,
|
|
896
|
+
placeholder: M,
|
|
897
|
+
value: f,
|
|
898
|
+
error: s,
|
|
899
|
+
focused: p ?? b,
|
|
900
|
+
handleReset: D,
|
|
868
901
|
dragOver: b,
|
|
869
|
-
inProgress:
|
|
870
|
-
hasFiles: !!
|
|
902
|
+
inProgress: a,
|
|
903
|
+
hasFiles: !!f,
|
|
871
904
|
InputProps: I,
|
|
872
905
|
buttonText: e
|
|
873
906
|
}
|
|
@@ -876,303 +909,333 @@ function bo({
|
|
|
876
909
|
"input",
|
|
877
910
|
{
|
|
878
911
|
...h,
|
|
879
|
-
ref:
|
|
912
|
+
ref: u,
|
|
880
913
|
style: { display: "none" },
|
|
881
914
|
type: "file",
|
|
882
915
|
"aria-label": t,
|
|
883
916
|
name: t,
|
|
884
|
-
accept: String(
|
|
917
|
+
accept: String(m),
|
|
885
918
|
multiple: l,
|
|
886
|
-
onChange:
|
|
919
|
+
onChange: k
|
|
887
920
|
}
|
|
888
921
|
)
|
|
889
922
|
] });
|
|
890
923
|
}
|
|
891
|
-
function
|
|
924
|
+
function tn({
|
|
892
925
|
disabled: t,
|
|
893
926
|
loading: e,
|
|
894
927
|
...n
|
|
895
928
|
}, o) {
|
|
896
929
|
return /* @__PURE__ */ i(
|
|
897
|
-
|
|
930
|
+
Z,
|
|
898
931
|
{
|
|
899
932
|
...n,
|
|
900
933
|
ref: o,
|
|
901
934
|
disabled: t || e,
|
|
902
|
-
popupIcon: e ? /* @__PURE__ */ i(
|
|
935
|
+
popupIcon: e ? /* @__PURE__ */ i(P, { size: 18, color: "inherit" }) : /* @__PURE__ */ i(X, {}),
|
|
936
|
+
"data-name": "autocomplete",
|
|
937
|
+
ListboxProps: {
|
|
938
|
+
"aria-multiselectable": !1,
|
|
939
|
+
...n.ListboxProps
|
|
940
|
+
}
|
|
903
941
|
}
|
|
904
942
|
);
|
|
905
943
|
}
|
|
906
|
-
const
|
|
907
|
-
function
|
|
908
|
-
return { renderOption: (e, n, o,
|
|
944
|
+
const Do = T(tn), Dt = (t) => t && typeof t == "object" ? t.title ?? String(t) : String(t), At = (t, e) => typeof t != "object" || t === null ? { value: t, multiple: e } : { ...t, multiple: e }, It = (t) => /* @__PURE__ */ i("span", { "data-testid": "more-options-tag", children: `+${t}` });
|
|
945
|
+
function wt() {
|
|
946
|
+
return { renderOption: (e, n, o, a, r) => {
|
|
909
947
|
const {
|
|
910
948
|
title: l,
|
|
911
|
-
inputValue:
|
|
912
|
-
divider:
|
|
913
|
-
fixed:
|
|
949
|
+
inputValue: c,
|
|
950
|
+
divider: s,
|
|
951
|
+
fixed: p,
|
|
914
952
|
extended: h,
|
|
915
|
-
dense:
|
|
916
|
-
destructive:
|
|
917
|
-
disabled:
|
|
918
|
-
subtitle:
|
|
919
|
-
iconColor:
|
|
953
|
+
dense: d,
|
|
954
|
+
destructive: m,
|
|
955
|
+
disabled: u,
|
|
956
|
+
subtitle: f,
|
|
957
|
+
iconColor: M,
|
|
920
958
|
startAdornment: b,
|
|
921
959
|
endAdornment: I,
|
|
922
|
-
alternativeTitle:
|
|
923
|
-
secondaryText:
|
|
924
|
-
multiple:
|
|
925
|
-
} = n, { key:
|
|
926
|
-
return /* @__PURE__ */ i(
|
|
927
|
-
|
|
960
|
+
alternativeTitle: k,
|
|
961
|
+
secondaryText: D,
|
|
962
|
+
multiple: x
|
|
963
|
+
} = n, { key: C, ...B } = e, O = typeof n == "string" || typeof n == "number", w = (E, A, L, et) => L || et || (A && typeof A == "object" && "value" in A ? String(A.value) : E(A));
|
|
964
|
+
return /* @__PURE__ */ i(Ot, { children: s ? /* @__PURE__ */ i(j, {}) : /* @__PURE__ */ y(V, { children: [
|
|
965
|
+
c && /* @__PURE__ */ i(j, {}),
|
|
928
966
|
/* @__PURE__ */ y(
|
|
929
|
-
|
|
967
|
+
vt,
|
|
930
968
|
{
|
|
931
|
-
...
|
|
932
|
-
...!
|
|
933
|
-
fixed:
|
|
969
|
+
...B,
|
|
970
|
+
...!O && {
|
|
971
|
+
fixed: p,
|
|
934
972
|
extended: h,
|
|
935
|
-
dense:
|
|
936
|
-
destructive:
|
|
937
|
-
disabled:
|
|
938
|
-
subtitle:
|
|
939
|
-
iconColor:
|
|
973
|
+
dense: d,
|
|
974
|
+
destructive: m,
|
|
975
|
+
disabled: u,
|
|
976
|
+
subtitle: f,
|
|
977
|
+
iconColor: M
|
|
940
978
|
},
|
|
979
|
+
"aria-disabled": f || u,
|
|
980
|
+
"aria-selected": o.selected,
|
|
941
981
|
children: [
|
|
942
|
-
!
|
|
943
|
-
|
|
982
|
+
!f && (b || x || r) && /* @__PURE__ */ y(Vt, { children: [
|
|
983
|
+
r || x && /* @__PURE__ */ i(z, { checked: o.selected }),
|
|
944
984
|
b
|
|
945
985
|
] }),
|
|
946
|
-
/* @__PURE__ */ y(
|
|
947
|
-
|
|
948
|
-
|
|
986
|
+
/* @__PURE__ */ y(bt, { children: [
|
|
987
|
+
w(
|
|
988
|
+
a ?? Dt,
|
|
949
989
|
n,
|
|
950
|
-
|
|
990
|
+
k,
|
|
951
991
|
l
|
|
952
992
|
),
|
|
953
|
-
|
|
954
|
-
|
|
993
|
+
D && /* @__PURE__ */ i(
|
|
994
|
+
S,
|
|
955
995
|
{
|
|
956
996
|
component: "p",
|
|
957
997
|
variant: "caption",
|
|
958
998
|
color: "text.secondary",
|
|
959
|
-
children:
|
|
999
|
+
children: D
|
|
960
1000
|
}
|
|
961
1001
|
)
|
|
962
1002
|
] }),
|
|
963
|
-
I
|
|
1003
|
+
!f && I
|
|
964
1004
|
]
|
|
965
1005
|
}
|
|
966
1006
|
)
|
|
967
|
-
] }) },
|
|
1007
|
+
] }) }, C);
|
|
968
1008
|
} };
|
|
969
1009
|
}
|
|
970
|
-
function
|
|
1010
|
+
function en({
|
|
971
1011
|
getOptionLabel: t,
|
|
972
1012
|
newItemLabel: e,
|
|
973
1013
|
newItemIcon: n,
|
|
974
1014
|
multiple: o
|
|
975
1015
|
}) {
|
|
976
|
-
const
|
|
1016
|
+
const a = F(), r = R(a), l = Nt(), { renderOption: c } = wt();
|
|
977
1017
|
return {
|
|
978
|
-
creatableFilterOptions: (
|
|
979
|
-
const
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
), { inputValue:
|
|
983
|
-
(b) =>
|
|
1018
|
+
creatableFilterOptions: (d, m) => {
|
|
1019
|
+
const u = l(
|
|
1020
|
+
d,
|
|
1021
|
+
m
|
|
1022
|
+
), { inputValue: f } = m, M = d.some(
|
|
1023
|
+
(b) => f === t(b)
|
|
984
1024
|
);
|
|
985
|
-
if (
|
|
1025
|
+
if (f.length > 1 && f !== "" && !M) {
|
|
986
1026
|
let b;
|
|
987
|
-
typeof e == "function" ? b = e(
|
|
988
|
-
inputValue:
|
|
1027
|
+
typeof e == "function" ? b = e(f) : e ? b = `${e} "${f}"` : b = `${r.formatMessage({ id: "c4r.form.add" })} "${f}"`, u.push({
|
|
1028
|
+
inputValue: f,
|
|
989
1029
|
title: b
|
|
990
1030
|
});
|
|
991
1031
|
}
|
|
992
|
-
return
|
|
1032
|
+
return u;
|
|
993
1033
|
},
|
|
994
|
-
creatableOptionLabel: (
|
|
995
|
-
creatableRenderOption: (
|
|
996
|
-
const
|
|
997
|
-
return
|
|
1034
|
+
creatableOptionLabel: (d) => typeof d == "string" ? d : d.inputValue ? d.inputValue : t(d),
|
|
1035
|
+
creatableRenderOption: (d, m, u) => {
|
|
1036
|
+
const f = m.inputValue ? n ?? /* @__PURE__ */ i(de, {}) : void 0, M = At(m, !!o);
|
|
1037
|
+
return c(
|
|
1038
|
+
d,
|
|
1039
|
+
M,
|
|
998
1040
|
u,
|
|
999
|
-
x,
|
|
1000
|
-
f,
|
|
1001
1041
|
t,
|
|
1002
|
-
|
|
1042
|
+
f
|
|
1003
1043
|
);
|
|
1004
1044
|
}
|
|
1005
1045
|
};
|
|
1006
1046
|
}
|
|
1007
|
-
function
|
|
1047
|
+
function Bt({
|
|
1008
1048
|
options: t,
|
|
1009
1049
|
value: e,
|
|
1010
1050
|
onChange: n,
|
|
1011
1051
|
getOptionLabel: o
|
|
1012
1052
|
}) {
|
|
1013
|
-
const [
|
|
1053
|
+
const [a, r] = $(
|
|
1014
1054
|
Array.isArray(e) ? e : e ? [e] : []
|
|
1015
|
-
), { renderOption: l } =
|
|
1016
|
-
|
|
1017
|
-
const
|
|
1018
|
-
|
|
1055
|
+
), { renderOption: l } = wt();
|
|
1056
|
+
_(() => {
|
|
1057
|
+
const m = Array.isArray(e) ? e : e ? [e] : [];
|
|
1058
|
+
r(m);
|
|
1019
1059
|
}, [e]);
|
|
1020
|
-
const
|
|
1060
|
+
const c = a.length === t.length, s = a.length > 0 && a.length < t.length;
|
|
1021
1061
|
return {
|
|
1022
|
-
multipleValue:
|
|
1023
|
-
allSelected:
|
|
1024
|
-
someSelected:
|
|
1025
|
-
handleSelectAll: () => {
|
|
1026
|
-
|
|
1062
|
+
multipleValue: a,
|
|
1063
|
+
allSelected: c,
|
|
1064
|
+
someSelected: s,
|
|
1065
|
+
handleSelectAll: (m) => {
|
|
1066
|
+
const u = c ? [] : [...t];
|
|
1067
|
+
r(u), n == null || n(
|
|
1068
|
+
m,
|
|
1069
|
+
u,
|
|
1070
|
+
"selectOption"
|
|
1071
|
+
);
|
|
1027
1072
|
},
|
|
1028
|
-
handleChange: (
|
|
1029
|
-
|
|
1073
|
+
handleChange: (m, u, f) => {
|
|
1074
|
+
r(u === null ? [] : u), n == null || n(m, u, f);
|
|
1030
1075
|
},
|
|
1031
|
-
multipleRenderOption: (
|
|
1032
|
-
const
|
|
1076
|
+
multipleRenderOption: (m, u, f) => {
|
|
1077
|
+
const M = At(u, !0);
|
|
1033
1078
|
return l(
|
|
1034
|
-
g,
|
|
1035
|
-
x,
|
|
1036
1079
|
m,
|
|
1080
|
+
M,
|
|
1081
|
+
f,
|
|
1037
1082
|
o
|
|
1038
1083
|
);
|
|
1039
1084
|
}
|
|
1040
1085
|
};
|
|
1041
1086
|
}
|
|
1042
|
-
function
|
|
1087
|
+
function nn({
|
|
1043
1088
|
children: t,
|
|
1044
1089
|
showFilters: e,
|
|
1045
1090
|
allSelected: n,
|
|
1046
1091
|
someSelected: o,
|
|
1047
|
-
handleSelectAll:
|
|
1092
|
+
handleSelectAll: a = () => {
|
|
1048
1093
|
},
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1094
|
+
multiple: r,
|
|
1095
|
+
...l
|
|
1096
|
+
}, c) {
|
|
1097
|
+
return /* @__PURE__ */ y(
|
|
1098
|
+
"ul",
|
|
1099
|
+
{
|
|
1100
|
+
ref: c,
|
|
1101
|
+
...l,
|
|
1102
|
+
role: "listbox",
|
|
1103
|
+
"aria-multiselectable": r,
|
|
1104
|
+
children: [
|
|
1105
|
+
e && r && /* @__PURE__ */ i(
|
|
1106
|
+
kt,
|
|
1107
|
+
{
|
|
1108
|
+
areAllSelected: !!n,
|
|
1109
|
+
areAnySelected: !!o,
|
|
1110
|
+
selectAll: a
|
|
1111
|
+
}
|
|
1112
|
+
),
|
|
1113
|
+
t
|
|
1114
|
+
]
|
|
1115
|
+
}
|
|
1116
|
+
);
|
|
1062
1117
|
}
|
|
1063
|
-
const
|
|
1064
|
-
function
|
|
1118
|
+
const St = T(nn);
|
|
1119
|
+
function on({
|
|
1065
1120
|
newItemLabel: t,
|
|
1066
1121
|
newItemIcon: e,
|
|
1067
|
-
getOptionLabel: n =
|
|
1122
|
+
getOptionLabel: n = Dt,
|
|
1068
1123
|
multiple: o,
|
|
1069
|
-
disableCloseOnSelect:
|
|
1070
|
-
disabled:
|
|
1124
|
+
disableCloseOnSelect: a,
|
|
1125
|
+
disabled: r,
|
|
1071
1126
|
loading: l,
|
|
1072
|
-
showFilters:
|
|
1073
|
-
options:
|
|
1074
|
-
value:
|
|
1127
|
+
showFilters: c,
|
|
1128
|
+
options: s = [],
|
|
1129
|
+
value: p,
|
|
1075
1130
|
onChange: h,
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1131
|
+
getLimitTagsText: d,
|
|
1132
|
+
...m
|
|
1133
|
+
}, u) {
|
|
1134
|
+
const { freeSolo: f = !0, ...M } = m, {
|
|
1135
|
+
multipleValue: b,
|
|
1136
|
+
allSelected: I,
|
|
1137
|
+
someSelected: k,
|
|
1138
|
+
handleSelectAll: D,
|
|
1139
|
+
handleChange: x
|
|
1140
|
+
} = Bt({
|
|
1141
|
+
options: s,
|
|
1142
|
+
value: p,
|
|
1087
1143
|
onChange: h
|
|
1088
1144
|
}), {
|
|
1089
|
-
creatableFilterOptions:
|
|
1090
|
-
creatableOptionLabel:
|
|
1091
|
-
creatableRenderOption:
|
|
1092
|
-
} =
|
|
1145
|
+
creatableFilterOptions: C,
|
|
1146
|
+
creatableOptionLabel: B,
|
|
1147
|
+
creatableRenderOption: O
|
|
1148
|
+
} = en({
|
|
1093
1149
|
getOptionLabel: n,
|
|
1094
1150
|
newItemLabel: t,
|
|
1095
1151
|
newItemIcon: e,
|
|
1096
1152
|
multiple: o
|
|
1097
1153
|
});
|
|
1098
1154
|
return /* @__PURE__ */ i(
|
|
1099
|
-
|
|
1155
|
+
Z,
|
|
1100
1156
|
{
|
|
1101
|
-
...
|
|
1102
|
-
ref:
|
|
1103
|
-
options:
|
|
1104
|
-
value: o ?
|
|
1105
|
-
onChange:
|
|
1106
|
-
filterOptions:
|
|
1107
|
-
getOptionLabel:
|
|
1108
|
-
renderOption:
|
|
1157
|
+
...M,
|
|
1158
|
+
ref: u,
|
|
1159
|
+
options: s,
|
|
1160
|
+
value: o ? b : p,
|
|
1161
|
+
onChange: x,
|
|
1162
|
+
filterOptions: C,
|
|
1163
|
+
getOptionLabel: B,
|
|
1164
|
+
renderOption: O,
|
|
1109
1165
|
freeSolo: f,
|
|
1110
1166
|
forcePopupIcon: !0,
|
|
1111
1167
|
multiple: o,
|
|
1112
|
-
disableCloseOnSelect:
|
|
1113
|
-
ListboxComponent:
|
|
1114
|
-
ListboxProps:
|
|
1115
|
-
showFilters:
|
|
1116
|
-
allSelected:
|
|
1117
|
-
someSelected:
|
|
1118
|
-
handleSelectAll:
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1168
|
+
disableCloseOnSelect: a ?? o,
|
|
1169
|
+
ListboxComponent: St,
|
|
1170
|
+
ListboxProps: {
|
|
1171
|
+
showFilters: c,
|
|
1172
|
+
allSelected: I,
|
|
1173
|
+
someSelected: k,
|
|
1174
|
+
handleSelectAll: D,
|
|
1175
|
+
multiple: o
|
|
1176
|
+
},
|
|
1177
|
+
getLimitTagsText: d ?? It,
|
|
1178
|
+
disabled: r || l,
|
|
1179
|
+
popupIcon: l ? /* @__PURE__ */ i(P, { size: 18, color: "inherit" }) : /* @__PURE__ */ i(X, {}),
|
|
1180
|
+
"data-name": "creatable-autocomplete"
|
|
1122
1181
|
}
|
|
1123
1182
|
);
|
|
1124
1183
|
}
|
|
1125
|
-
const
|
|
1126
|
-
function
|
|
1184
|
+
const Ao = T(on);
|
|
1185
|
+
function an({
|
|
1127
1186
|
renderOption: t,
|
|
1128
1187
|
disableCloseOnSelect: e = !0,
|
|
1129
1188
|
disabled: n,
|
|
1130
1189
|
loading: o,
|
|
1131
|
-
showFilters:
|
|
1132
|
-
options:
|
|
1190
|
+
showFilters: a,
|
|
1191
|
+
options: r,
|
|
1133
1192
|
value: l,
|
|
1134
|
-
onChange:
|
|
1135
|
-
getOptionLabel:
|
|
1136
|
-
|
|
1137
|
-
|
|
1193
|
+
onChange: c,
|
|
1194
|
+
getOptionLabel: s,
|
|
1195
|
+
getLimitTagsText: p,
|
|
1196
|
+
...h
|
|
1197
|
+
}, d) {
|
|
1138
1198
|
const {
|
|
1139
|
-
multipleValue:
|
|
1140
|
-
allSelected:
|
|
1199
|
+
multipleValue: m,
|
|
1200
|
+
allSelected: u,
|
|
1141
1201
|
someSelected: f,
|
|
1142
|
-
handleSelectAll:
|
|
1143
|
-
handleChange:
|
|
1144
|
-
multipleRenderOption:
|
|
1145
|
-
} =
|
|
1146
|
-
options:
|
|
1202
|
+
handleSelectAll: M,
|
|
1203
|
+
handleChange: b,
|
|
1204
|
+
multipleRenderOption: I
|
|
1205
|
+
} = Bt({
|
|
1206
|
+
options: r,
|
|
1147
1207
|
value: l,
|
|
1148
|
-
onChange:
|
|
1149
|
-
getOptionLabel:
|
|
1208
|
+
onChange: c,
|
|
1209
|
+
getOptionLabel: s
|
|
1150
1210
|
});
|
|
1151
1211
|
return /* @__PURE__ */ i(
|
|
1152
|
-
|
|
1212
|
+
Z,
|
|
1153
1213
|
{
|
|
1154
|
-
...
|
|
1155
|
-
ref:
|
|
1156
|
-
options:
|
|
1157
|
-
value:
|
|
1158
|
-
onChange:
|
|
1159
|
-
getOptionLabel:
|
|
1160
|
-
renderOption: t ??
|
|
1161
|
-
ListboxComponent:
|
|
1214
|
+
...h,
|
|
1215
|
+
ref: d,
|
|
1216
|
+
options: r,
|
|
1217
|
+
value: m,
|
|
1218
|
+
onChange: b,
|
|
1219
|
+
getOptionLabel: s,
|
|
1220
|
+
renderOption: t ?? I,
|
|
1221
|
+
ListboxComponent: St,
|
|
1162
1222
|
ListboxProps: {
|
|
1163
|
-
showFilters:
|
|
1164
|
-
allSelected:
|
|
1223
|
+
showFilters: a,
|
|
1224
|
+
allSelected: u,
|
|
1165
1225
|
someSelected: f,
|
|
1166
|
-
handleSelectAll:
|
|
1226
|
+
handleSelectAll: M,
|
|
1227
|
+
multiple: !0
|
|
1167
1228
|
},
|
|
1168
1229
|
multiple: !0,
|
|
1230
|
+
getLimitTagsText: p ?? It,
|
|
1169
1231
|
disableCloseOnSelect: e,
|
|
1170
1232
|
disabled: n || o,
|
|
1171
|
-
popupIcon: o ? /* @__PURE__ */ i(
|
|
1233
|
+
popupIcon: o ? /* @__PURE__ */ i(P, { size: 18, color: "inherit" }) : /* @__PURE__ */ i(X, {}),
|
|
1234
|
+
"data-name": "multiple-autocomplete"
|
|
1172
1235
|
}
|
|
1173
1236
|
);
|
|
1174
1237
|
}
|
|
1175
|
-
const
|
|
1238
|
+
const Io = T(an), rn = g("div", {
|
|
1176
1239
|
shouldForwardProp: (t) => t !== "variant"
|
|
1177
1240
|
})(({ variant: t, theme: e }) => ({
|
|
1178
1241
|
width: "100%",
|
|
@@ -1182,30 +1245,30 @@ const Mo = O(Qe), tn = p("div", {
|
|
|
1182
1245
|
boxShadow: `inset 0 0 0 1px ${e.palette.divider}`
|
|
1183
1246
|
}
|
|
1184
1247
|
}));
|
|
1185
|
-
function
|
|
1248
|
+
function wo({
|
|
1186
1249
|
variant: t = "standard",
|
|
1187
1250
|
items: e,
|
|
1188
1251
|
...n
|
|
1189
1252
|
}) {
|
|
1190
|
-
return /* @__PURE__ */ i(
|
|
1191
|
-
|
|
1253
|
+
return /* @__PURE__ */ i(rn, { ...n, variant: t, children: e.map((o, a) => /* @__PURE__ */ y(
|
|
1254
|
+
Ut,
|
|
1192
1255
|
{
|
|
1193
1256
|
disabled: o.disabled,
|
|
1194
1257
|
defaultExpanded: o.defaultExpanded,
|
|
1195
1258
|
onChange: o.onChange,
|
|
1196
1259
|
children: [
|
|
1197
1260
|
/* @__PURE__ */ i(
|
|
1198
|
-
|
|
1261
|
+
Yt,
|
|
1199
1262
|
{
|
|
1200
|
-
"aria-controls": `${
|
|
1201
|
-
id: `${
|
|
1263
|
+
"aria-controls": `${a}-content`,
|
|
1264
|
+
id: `${a}-header`,
|
|
1202
1265
|
children: o.summary
|
|
1203
1266
|
}
|
|
1204
1267
|
),
|
|
1205
|
-
/* @__PURE__ */ i(
|
|
1268
|
+
/* @__PURE__ */ i(qt, { children: o.content })
|
|
1206
1269
|
]
|
|
1207
1270
|
},
|
|
1208
|
-
|
|
1271
|
+
a
|
|
1209
1272
|
)) });
|
|
1210
1273
|
}
|
|
1211
1274
|
const it = {
|
|
@@ -1213,7 +1276,7 @@ const it = {
|
|
|
1213
1276
|
medium: 4,
|
|
1214
1277
|
small: 3,
|
|
1215
1278
|
xsmall: 2.25
|
|
1216
|
-
},
|
|
1279
|
+
}, ln = g(zt, {
|
|
1217
1280
|
shouldForwardProp: (t) => t !== "size" && t !== "disabled"
|
|
1218
1281
|
})(({ theme: t, size: e = "medium", disabled: n = !1 }) => ({
|
|
1219
1282
|
width: t.spacing(it[e]),
|
|
@@ -1230,18 +1293,18 @@ const it = {
|
|
|
1230
1293
|
...t.typography.caption,
|
|
1231
1294
|
fontWeight: 500,
|
|
1232
1295
|
svg: {
|
|
1233
|
-
width:
|
|
1234
|
-
height:
|
|
1296
|
+
width: G,
|
|
1297
|
+
height: G
|
|
1235
1298
|
}
|
|
1236
1299
|
},
|
|
1237
1300
|
...n && {
|
|
1238
1301
|
opacity: 0.6
|
|
1239
1302
|
}
|
|
1240
1303
|
}));
|
|
1241
|
-
function
|
|
1242
|
-
return /* @__PURE__ */ i(
|
|
1304
|
+
function Bo(t) {
|
|
1305
|
+
return /* @__PURE__ */ i(ln, { ...t });
|
|
1243
1306
|
}
|
|
1244
|
-
const
|
|
1307
|
+
const Tt = 480, cn = g(Zt)(({ theme: t }) => ({
|
|
1245
1308
|
bottom: t.spacing(2),
|
|
1246
1309
|
right: t.spacing(2),
|
|
1247
1310
|
left: t.spacing(2),
|
|
@@ -1250,13 +1313,13 @@ const wt = 480, nn = p(zt)(({ theme: t }) => ({
|
|
|
1250
1313
|
right: "auto",
|
|
1251
1314
|
left: "50%",
|
|
1252
1315
|
width: "100%",
|
|
1253
|
-
maxWidth: `${
|
|
1316
|
+
maxWidth: `${Tt}px`
|
|
1254
1317
|
}
|
|
1255
|
-
})),
|
|
1318
|
+
})), sn = g(v, {
|
|
1256
1319
|
shouldForwardProp: (t) => t !== "autoWidth"
|
|
1257
1320
|
})(({ autoWidth: t, theme: e }) => ({
|
|
1258
1321
|
minWidth: "100%",
|
|
1259
|
-
maxWidth: `${
|
|
1322
|
+
maxWidth: `${Tt}px`,
|
|
1260
1323
|
margin: e.spacing(0, 1),
|
|
1261
1324
|
...t && {
|
|
1262
1325
|
minWidth: "auto"
|
|
@@ -1267,7 +1330,7 @@ const wt = 480, nn = p(zt)(({ theme: t }) => ({
|
|
|
1267
1330
|
minWidth: "auto"
|
|
1268
1331
|
}
|
|
1269
1332
|
}
|
|
1270
|
-
})),
|
|
1333
|
+
})), dn = g(Ct, {
|
|
1271
1334
|
shouldForwardProp: (t) => !["hasActions", "closeable"].includes(t)
|
|
1272
1335
|
})(({ hasActions: t, closeable: e, icon: n, theme: o }) => ({
|
|
1273
1336
|
position: "relative",
|
|
@@ -1319,7 +1382,7 @@ const wt = 480, nn = p(zt)(({ theme: t }) => ({
|
|
|
1319
1382
|
padding: o.spacing(0.75, 0)
|
|
1320
1383
|
}
|
|
1321
1384
|
}
|
|
1322
|
-
})),
|
|
1385
|
+
})), un = g(v)(({ theme: t }) => ({
|
|
1323
1386
|
position: "absolute",
|
|
1324
1387
|
top: t.spacing(1),
|
|
1325
1388
|
right: t.spacing(1),
|
|
@@ -1330,58 +1393,58 @@ const wt = 480, nn = p(zt)(({ theme: t }) => ({
|
|
|
1330
1393
|
color: t.palette.white[60]
|
|
1331
1394
|
}
|
|
1332
1395
|
}));
|
|
1333
|
-
function
|
|
1396
|
+
function So({
|
|
1334
1397
|
severity: t = "neutral",
|
|
1335
1398
|
autoHideDuration: e = ot,
|
|
1336
1399
|
closeable: n = !0,
|
|
1337
1400
|
children: o,
|
|
1338
|
-
title:
|
|
1339
|
-
action:
|
|
1401
|
+
title: a,
|
|
1402
|
+
action: r,
|
|
1340
1403
|
open: l,
|
|
1341
|
-
onClose:
|
|
1404
|
+
onClose: c = () => {
|
|
1342
1405
|
},
|
|
1343
|
-
autoWidth:
|
|
1344
|
-
icon:
|
|
1406
|
+
autoWidth: s,
|
|
1407
|
+
icon: p,
|
|
1345
1408
|
...h
|
|
1346
1409
|
}) {
|
|
1347
|
-
const
|
|
1348
|
-
return /* @__PURE__ */ i(
|
|
1349
|
-
|
|
1410
|
+
const d = F(), m = R(d);
|
|
1411
|
+
return /* @__PURE__ */ i(Jt, { children: /* @__PURE__ */ i(
|
|
1412
|
+
cn,
|
|
1350
1413
|
{
|
|
1351
1414
|
...h,
|
|
1352
1415
|
open: l,
|
|
1353
1416
|
autoHideDuration: e === null ? null : e || ot,
|
|
1354
|
-
onClose:
|
|
1355
|
-
TransitionComponent:
|
|
1356
|
-
"data-auto-width":
|
|
1417
|
+
onClose: c,
|
|
1418
|
+
TransitionComponent: s ? Xt : xt,
|
|
1419
|
+
"data-auto-width": s,
|
|
1357
1420
|
children: /* @__PURE__ */ y(
|
|
1358
|
-
|
|
1421
|
+
sn,
|
|
1359
1422
|
{
|
|
1360
1423
|
sx: {
|
|
1361
1424
|
position: "relative"
|
|
1362
1425
|
},
|
|
1363
|
-
autoWidth:
|
|
1426
|
+
autoWidth: s,
|
|
1364
1427
|
children: [
|
|
1365
1428
|
/* @__PURE__ */ i(
|
|
1366
|
-
|
|
1429
|
+
dn,
|
|
1367
1430
|
{
|
|
1368
1431
|
severity: t,
|
|
1369
|
-
action:
|
|
1370
|
-
icon:
|
|
1432
|
+
action: r,
|
|
1433
|
+
icon: p === !1 || t === "neutral" && !p ? !1 : p,
|
|
1371
1434
|
elevation: 6,
|
|
1372
|
-
hasActions: !!
|
|
1435
|
+
hasActions: !!r,
|
|
1373
1436
|
closeable: n,
|
|
1374
|
-
title:
|
|
1437
|
+
title: a,
|
|
1375
1438
|
children: o
|
|
1376
1439
|
}
|
|
1377
1440
|
),
|
|
1378
|
-
n && /* @__PURE__ */ i(
|
|
1379
|
-
|
|
1441
|
+
n && /* @__PURE__ */ i(un, { children: /* @__PURE__ */ i(
|
|
1442
|
+
Le,
|
|
1380
1443
|
{
|
|
1381
1444
|
color: "default",
|
|
1382
|
-
onClick: (I) =>
|
|
1383
|
-
icon: /* @__PURE__ */ i(
|
|
1384
|
-
tooltip:
|
|
1445
|
+
onClick: (I) => c(I, "timeout"),
|
|
1446
|
+
icon: /* @__PURE__ */ i(Mt, {}),
|
|
1447
|
+
tooltip: m.formatMessage({
|
|
1385
1448
|
id: "c4r.button.close"
|
|
1386
1449
|
})
|
|
1387
1450
|
}
|
|
@@ -1392,20 +1455,20 @@ function Ao({
|
|
|
1392
1455
|
}
|
|
1393
1456
|
) });
|
|
1394
1457
|
}
|
|
1395
|
-
const
|
|
1458
|
+
const pn = g("div")(({ theme: t }) => ({
|
|
1396
1459
|
display: "flex",
|
|
1397
1460
|
alignItems: "center",
|
|
1398
|
-
height:
|
|
1461
|
+
height: le,
|
|
1399
1462
|
marginRight: t.spacing(1.5)
|
|
1400
|
-
})),
|
|
1463
|
+
})), gn = g(W)(({ theme: t }) => ({
|
|
1401
1464
|
marginRight: t.spacing(1),
|
|
1402
1465
|
"&.MuiButtonBase-root svg path": {
|
|
1403
1466
|
fill: t.palette.brand.appBarContrastText
|
|
1404
1467
|
}
|
|
1405
|
-
})),
|
|
1406
|
-
borderColor:
|
|
1468
|
+
})), fn = g(j)(({ theme: t }) => ({
|
|
1469
|
+
borderColor: Kt(t.palette.brand.appBarContrastText, 0.12)
|
|
1407
1470
|
}));
|
|
1408
|
-
function
|
|
1471
|
+
function mn({
|
|
1409
1472
|
onClickMenu: t
|
|
1410
1473
|
}) {
|
|
1411
1474
|
return (
|
|
@@ -1417,15 +1480,15 @@ function dn({
|
|
|
1417
1480
|
sx: {
|
|
1418
1481
|
display: { md: "none", xs: "block" }
|
|
1419
1482
|
},
|
|
1420
|
-
children: /* @__PURE__ */ y(
|
|
1421
|
-
/* @__PURE__ */ i(
|
|
1422
|
-
/* @__PURE__ */ i(
|
|
1483
|
+
children: /* @__PURE__ */ y(pn, { children: [
|
|
1484
|
+
/* @__PURE__ */ i(gn, { onClick: t, children: /* @__PURE__ */ i(ue, {}) }),
|
|
1485
|
+
/* @__PURE__ */ i(fn, { orientation: "vertical", flexItem: !0 })
|
|
1423
1486
|
] })
|
|
1424
1487
|
}
|
|
1425
1488
|
)
|
|
1426
1489
|
);
|
|
1427
1490
|
}
|
|
1428
|
-
const
|
|
1491
|
+
const hn = g("div")(({ theme: t }) => ({
|
|
1429
1492
|
display: "flex",
|
|
1430
1493
|
marginRight: t.spacing(1.5),
|
|
1431
1494
|
"& a": {
|
|
@@ -1436,18 +1499,18 @@ const un = p("div")(({ theme: t }) => ({
|
|
|
1436
1499
|
height: t.spacing(4)
|
|
1437
1500
|
}
|
|
1438
1501
|
}));
|
|
1439
|
-
function
|
|
1440
|
-
return /* @__PURE__ */ i(
|
|
1502
|
+
function bn({ logo: t }) {
|
|
1503
|
+
return /* @__PURE__ */ i(hn, { children: t });
|
|
1441
1504
|
}
|
|
1442
|
-
const
|
|
1505
|
+
const xn = g(S)({
|
|
1443
1506
|
display: "flex",
|
|
1444
1507
|
alignItems: "center",
|
|
1445
1508
|
whiteSpace: "nowrap"
|
|
1446
1509
|
});
|
|
1447
|
-
function
|
|
1510
|
+
function yn({ text: t }) {
|
|
1448
1511
|
const e = N();
|
|
1449
1512
|
return /* @__PURE__ */ i(
|
|
1450
|
-
|
|
1513
|
+
xn,
|
|
1451
1514
|
{
|
|
1452
1515
|
component: "span",
|
|
1453
1516
|
variant: "subtitle1",
|
|
@@ -1456,7 +1519,7 @@ function fn({ text: t }) {
|
|
|
1456
1519
|
}
|
|
1457
1520
|
);
|
|
1458
1521
|
}
|
|
1459
|
-
const
|
|
1522
|
+
const Mn = g(S)(({ theme: t }) => ({
|
|
1460
1523
|
display: "flex",
|
|
1461
1524
|
alignItems: "center",
|
|
1462
1525
|
"&::before": {
|
|
@@ -1466,10 +1529,10 @@ const hn = p(w)(({ theme: t }) => ({
|
|
|
1466
1529
|
color: t.palette.brand.appBarContrastText
|
|
1467
1530
|
}
|
|
1468
1531
|
}));
|
|
1469
|
-
function
|
|
1532
|
+
function Cn({ text: t }) {
|
|
1470
1533
|
const e = N();
|
|
1471
1534
|
return /* @__PURE__ */ i(
|
|
1472
|
-
|
|
1535
|
+
Mn,
|
|
1473
1536
|
{
|
|
1474
1537
|
component: "span",
|
|
1475
1538
|
variant: "body2",
|
|
@@ -1479,7 +1542,7 @@ function mn({ text: t }) {
|
|
|
1479
1542
|
}
|
|
1480
1543
|
);
|
|
1481
1544
|
}
|
|
1482
|
-
const
|
|
1545
|
+
const vn = g(te)(({ theme: t }) => ({
|
|
1483
1546
|
backgroundColor: t.palette.brand.appBarMain,
|
|
1484
1547
|
"& .MuiTypography-root": {
|
|
1485
1548
|
color: t.palette.brand.appBarContrastText
|
|
@@ -1487,7 +1550,7 @@ const bn = p(Kt)(({ theme: t }) => ({
|
|
|
1487
1550
|
"& .MuiIconButton-root path": {
|
|
1488
1551
|
fill: t.palette.brand.appBarContrastText
|
|
1489
1552
|
}
|
|
1490
|
-
})),
|
|
1553
|
+
})), kn = g("div")(({ theme: t }) => ({
|
|
1491
1554
|
display: "flex",
|
|
1492
1555
|
alignItems: "center",
|
|
1493
1556
|
maxWidth: "calc(100% - 300px)",
|
|
@@ -1495,33 +1558,33 @@ const bn = p(Kt)(({ theme: t }) => ({
|
|
|
1495
1558
|
[t.breakpoints.down("sm")]: {
|
|
1496
1559
|
minWidth: "192px"
|
|
1497
1560
|
}
|
|
1498
|
-
})),
|
|
1561
|
+
})), Dn = g("div")(({ theme: t }) => ({
|
|
1499
1562
|
display: "flex",
|
|
1500
1563
|
alignItems: "center",
|
|
1501
1564
|
justifyContent: "space-between",
|
|
1502
1565
|
flex: 1,
|
|
1503
1566
|
marginLeft: t.spacing(1)
|
|
1504
1567
|
}));
|
|
1505
|
-
function
|
|
1568
|
+
function To({
|
|
1506
1569
|
children: t,
|
|
1507
1570
|
brandLogo: e,
|
|
1508
1571
|
brandText: n,
|
|
1509
1572
|
secondaryText: o,
|
|
1510
|
-
showBurgerMenu:
|
|
1511
|
-
onClickMenu:
|
|
1573
|
+
showBurgerMenu: a = !1,
|
|
1574
|
+
onClickMenu: r,
|
|
1512
1575
|
...l
|
|
1513
1576
|
}) {
|
|
1514
|
-
return /* @__PURE__ */ i(
|
|
1515
|
-
/* @__PURE__ */ y(
|
|
1516
|
-
|
|
1517
|
-
e && /* @__PURE__ */ i(
|
|
1518
|
-
n && /* @__PURE__ */ i(
|
|
1519
|
-
o && /* @__PURE__ */ i(
|
|
1577
|
+
return /* @__PURE__ */ i(vn, { ...l, children: /* @__PURE__ */ y(Qt, { children: [
|
|
1578
|
+
/* @__PURE__ */ y(kn, { children: [
|
|
1579
|
+
a && /* @__PURE__ */ i(mn, { onClickMenu: r }),
|
|
1580
|
+
e && /* @__PURE__ */ i(bn, { logo: e }),
|
|
1581
|
+
n && /* @__PURE__ */ i(yn, { text: n }),
|
|
1582
|
+
o && /* @__PURE__ */ i(Cn, { text: o })
|
|
1520
1583
|
] }),
|
|
1521
|
-
/* @__PURE__ */ i(
|
|
1584
|
+
/* @__PURE__ */ i(Dn, { children: t })
|
|
1522
1585
|
] }) });
|
|
1523
1586
|
}
|
|
1524
|
-
const
|
|
1587
|
+
const An = g(v, {
|
|
1525
1588
|
shouldForwardProp: (t) => !["size", "variant"].includes(t)
|
|
1526
1589
|
})(({ size: t, variant: e, theme: n }) => ({
|
|
1527
1590
|
position: "absolute",
|
|
@@ -1538,24 +1601,24 @@ const Mn = p(v, {
|
|
|
1538
1601
|
}
|
|
1539
1602
|
}
|
|
1540
1603
|
}));
|
|
1541
|
-
function
|
|
1604
|
+
function Q({
|
|
1542
1605
|
size: t,
|
|
1543
1606
|
variant: e,
|
|
1544
1607
|
...n
|
|
1545
1608
|
}) {
|
|
1546
|
-
const o =
|
|
1547
|
-
return /* @__PURE__ */ i(
|
|
1548
|
-
|
|
1609
|
+
const o = F(), a = R(o);
|
|
1610
|
+
return /* @__PURE__ */ i(An, { size: t, variant: e, children: /* @__PURE__ */ i(
|
|
1611
|
+
W,
|
|
1549
1612
|
{
|
|
1550
1613
|
...n,
|
|
1551
1614
|
size: t,
|
|
1552
|
-
"aria-label":
|
|
1615
|
+
"aria-label": a.formatMessage({
|
|
1553
1616
|
id: "c4r.form.clearSelection"
|
|
1554
1617
|
})
|
|
1555
1618
|
}
|
|
1556
1619
|
) });
|
|
1557
1620
|
}
|
|
1558
|
-
const
|
|
1621
|
+
const In = g(v, {
|
|
1559
1622
|
shouldForwardProp: (t) => !["size", "variant", "readOnly"].includes(t)
|
|
1560
1623
|
})(({ size: t, variant: e, readOnly: n, theme: o }) => ({
|
|
1561
1624
|
// There is no specific slot to change TextField styles at DatePicker level, so we need to wrap our component to isolate this override. https://mui.com/x/react-date-pickers/date-picker/#customization
|
|
@@ -1588,86 +1651,99 @@ const Cn = p(v, {
|
|
|
1588
1651
|
}
|
|
1589
1652
|
}
|
|
1590
1653
|
}));
|
|
1591
|
-
function
|
|
1654
|
+
function tt({
|
|
1592
1655
|
children: t,
|
|
1593
1656
|
size: e,
|
|
1594
1657
|
variant: n,
|
|
1595
1658
|
readOnly: o,
|
|
1596
|
-
...
|
|
1659
|
+
...a
|
|
1597
1660
|
}) {
|
|
1598
|
-
return /* @__PURE__ */ i(
|
|
1661
|
+
return /* @__PURE__ */ i(In, { ...a, size: e, variant: n, readOnly: o, children: t });
|
|
1599
1662
|
}
|
|
1600
|
-
function
|
|
1663
|
+
function at({
|
|
1601
1664
|
handleClear: t,
|
|
1602
1665
|
variant: e = "outlined",
|
|
1603
1666
|
size: n = "small",
|
|
1604
1667
|
label: o,
|
|
1605
|
-
labelHelpTooltip:
|
|
1606
|
-
type:
|
|
1668
|
+
labelHelpTooltip: a,
|
|
1669
|
+
type: r,
|
|
1607
1670
|
helperText: l,
|
|
1608
|
-
placeholder:
|
|
1609
|
-
slotProps:
|
|
1610
|
-
slots:
|
|
1671
|
+
placeholder: c,
|
|
1672
|
+
slotProps: s,
|
|
1673
|
+
slots: p,
|
|
1611
1674
|
error: h,
|
|
1612
|
-
showCalendar:
|
|
1613
|
-
readOnly:
|
|
1614
|
-
|
|
1675
|
+
showCalendar: d = !0,
|
|
1676
|
+
readOnly: m,
|
|
1677
|
+
"aria-label": u,
|
|
1678
|
+
"data-testid": f,
|
|
1679
|
+
...M
|
|
1615
1680
|
}) {
|
|
1616
|
-
const
|
|
1681
|
+
const b = F(), I = R(b);
|
|
1617
1682
|
return (
|
|
1618
1683
|
// Don't remove className, it's used for styling
|
|
1619
|
-
/* @__PURE__ */ i(v, { className: "CartoDatePicker-root", "data-testid": "date-picker", children: /* @__PURE__ */ i(
|
|
1620
|
-
|
|
1684
|
+
/* @__PURE__ */ i(v, { className: "CartoDatePicker-root", "data-testid": "date-picker", children: /* @__PURE__ */ i(
|
|
1685
|
+
tt,
|
|
1621
1686
|
{
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1687
|
+
size: n,
|
|
1688
|
+
variant: e,
|
|
1689
|
+
readOnly: m,
|
|
1690
|
+
"data-name": "date-picker",
|
|
1691
|
+
"aria-label": u,
|
|
1692
|
+
"data-testid": f,
|
|
1693
|
+
children: /* @__PURE__ */ i(
|
|
1694
|
+
fe,
|
|
1625
1695
|
{
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1696
|
+
...M,
|
|
1697
|
+
label: o && /* @__PURE__ */ i(
|
|
1698
|
+
K,
|
|
1699
|
+
{
|
|
1700
|
+
label: o,
|
|
1701
|
+
type: r,
|
|
1702
|
+
icon: a && /* @__PURE__ */ i(H, { title: a, children: /* @__PURE__ */ i(J, { htmlColor: "text.secondary" }) })
|
|
1703
|
+
}
|
|
1704
|
+
),
|
|
1705
|
+
slotProps: {
|
|
1706
|
+
// https://mui.com/x/api/date-pickers/date-picker/#slots
|
|
1707
|
+
textField: {
|
|
1708
|
+
variant: e,
|
|
1709
|
+
helperText: l,
|
|
1710
|
+
placeholder: c,
|
|
1711
|
+
size: n,
|
|
1712
|
+
error: h ?? void 0,
|
|
1713
|
+
// undefined is needed to allow the component to control the error state for the default validation
|
|
1714
|
+
inputProps: {
|
|
1715
|
+
"data-testid": "date-picker-input"
|
|
1716
|
+
}
|
|
1717
|
+
},
|
|
1718
|
+
field: {
|
|
1719
|
+
clearable: !!t,
|
|
1720
|
+
onClear: t
|
|
1721
|
+
},
|
|
1722
|
+
...s
|
|
1723
|
+
},
|
|
1724
|
+
slots: {
|
|
1725
|
+
clearButton: (k) => /* @__PURE__ */ i(Q, { ...k, size: n, variant: e }),
|
|
1726
|
+
openPickerButton: (k) => /* @__PURE__ */ i(
|
|
1727
|
+
W,
|
|
1728
|
+
{
|
|
1729
|
+
...k,
|
|
1730
|
+
size: n,
|
|
1731
|
+
"aria-label": I.formatMessage({
|
|
1732
|
+
id: "c4r.form.chooseDate"
|
|
1733
|
+
})
|
|
1734
|
+
}
|
|
1735
|
+
),
|
|
1736
|
+
...p
|
|
1737
|
+
},
|
|
1738
|
+
disableOpenPicker: !d,
|
|
1739
|
+
readOnly: m
|
|
1629
1740
|
}
|
|
1630
|
-
)
|
|
1631
|
-
slotProps: {
|
|
1632
|
-
// https://mui.com/x/api/date-pickers/date-picker/#slots
|
|
1633
|
-
textField: {
|
|
1634
|
-
variant: e,
|
|
1635
|
-
helperText: l,
|
|
1636
|
-
placeholder: s,
|
|
1637
|
-
size: n,
|
|
1638
|
-
error: h ?? void 0,
|
|
1639
|
-
// undefined is needed to allow the component to control the error state for the default validation
|
|
1640
|
-
inputProps: {
|
|
1641
|
-
"data-testid": "date-picker-input"
|
|
1642
|
-
}
|
|
1643
|
-
},
|
|
1644
|
-
field: {
|
|
1645
|
-
clearable: !!t,
|
|
1646
|
-
onClear: t
|
|
1647
|
-
},
|
|
1648
|
-
...c
|
|
1649
|
-
},
|
|
1650
|
-
slots: {
|
|
1651
|
-
clearButton: (b) => /* @__PURE__ */ i(K, { ...b, size: n, variant: e }),
|
|
1652
|
-
openPickerButton: (b) => /* @__PURE__ */ i(
|
|
1653
|
-
F,
|
|
1654
|
-
{
|
|
1655
|
-
...b,
|
|
1656
|
-
size: n,
|
|
1657
|
-
"aria-label": x.formatMessage({
|
|
1658
|
-
id: "c4r.form.chooseDate"
|
|
1659
|
-
})
|
|
1660
|
-
}
|
|
1661
|
-
),
|
|
1662
|
-
...d
|
|
1663
|
-
},
|
|
1664
|
-
disableOpenPicker: !u,
|
|
1665
|
-
readOnly: g
|
|
1741
|
+
)
|
|
1666
1742
|
}
|
|
1667
|
-
) })
|
|
1743
|
+
) })
|
|
1668
1744
|
);
|
|
1669
1745
|
}
|
|
1670
|
-
const
|
|
1746
|
+
const wn = g(v, {
|
|
1671
1747
|
shouldForwardProp: (t) => ![
|
|
1672
1748
|
"isSelected",
|
|
1673
1749
|
"isStartDate",
|
|
@@ -1682,8 +1758,8 @@ const vn = p(v, {
|
|
|
1682
1758
|
isSelected: e,
|
|
1683
1759
|
isStartDate: n,
|
|
1684
1760
|
isEndDate: o,
|
|
1685
|
-
isSelectedMonth:
|
|
1686
|
-
isLastDay:
|
|
1761
|
+
isSelectedMonth: a,
|
|
1762
|
+
isLastDay: r,
|
|
1687
1763
|
isFirstDay: l
|
|
1688
1764
|
}) => ({
|
|
1689
1765
|
position: "relative",
|
|
@@ -1692,7 +1768,7 @@ const vn = p(v, {
|
|
|
1692
1768
|
margin: 0
|
|
1693
1769
|
},
|
|
1694
1770
|
// Highlight the selected date range
|
|
1695
|
-
...e &&
|
|
1771
|
+
...e && a && {
|
|
1696
1772
|
// Creates a continuous background color between start and end date
|
|
1697
1773
|
"&::before": {
|
|
1698
1774
|
content: '""',
|
|
@@ -1708,7 +1784,7 @@ const vn = p(v, {
|
|
|
1708
1784
|
borderRadius: `${t.shape.borderRadius}px 0 0 ${t.shape.borderRadius}px`
|
|
1709
1785
|
},
|
|
1710
1786
|
// Selected end date OR last day of the month
|
|
1711
|
-
...(o ||
|
|
1787
|
+
...(o || r) && {
|
|
1712
1788
|
right: 0,
|
|
1713
1789
|
borderRadius: `0 ${t.shape.borderRadius}px ${t.shape.borderRadius}px 0`
|
|
1714
1790
|
}
|
|
@@ -1732,7 +1808,7 @@ const vn = p(v, {
|
|
|
1732
1808
|
}
|
|
1733
1809
|
},
|
|
1734
1810
|
// Last day of month and first selected day in a week
|
|
1735
|
-
...
|
|
1811
|
+
...r && {
|
|
1736
1812
|
"&:first-of-type::before": {
|
|
1737
1813
|
left: 0,
|
|
1738
1814
|
right: 0,
|
|
@@ -1762,7 +1838,7 @@ const vn = p(v, {
|
|
|
1762
1838
|
}
|
|
1763
1839
|
}
|
|
1764
1840
|
})
|
|
1765
|
-
),
|
|
1841
|
+
), Bn = g(me, {
|
|
1766
1842
|
shouldForwardProp: (t) => t !== "isDateRangeLimit"
|
|
1767
1843
|
})(({ theme: t, isDateRangeLimit: e }) => ({
|
|
1768
1844
|
"&.MuiPickersDay-root": {
|
|
@@ -1782,37 +1858,38 @@ const vn = p(v, {
|
|
|
1782
1858
|
}
|
|
1783
1859
|
}
|
|
1784
1860
|
}
|
|
1785
|
-
}));
|
|
1786
|
-
function
|
|
1861
|
+
})), rt = (t, e) => !t || !e ? !1 : t.getFullYear() === e.getFullYear() && t.getMonth() === e.getMonth() && t.getDate() === e.getDate();
|
|
1862
|
+
function lt({
|
|
1787
1863
|
day: t,
|
|
1788
1864
|
startDate: e,
|
|
1789
1865
|
endDate: n,
|
|
1790
1866
|
selectedMonth: o,
|
|
1791
|
-
...
|
|
1867
|
+
...a
|
|
1792
1868
|
}) {
|
|
1793
|
-
const
|
|
1869
|
+
const r = !!(e && rt(e, t)), l = !!(n && rt(n, t)), c = !!(e && n && t.getTime() >= e.getTime() && t.getTime() <= n.getTime()), s = t.getDate() === 1, p = t.getDate() === new Date(t.getFullYear(), t.getMonth() + 1, 0).getDate(), h = !!(o && t.getMonth() === o.getMonth());
|
|
1794
1870
|
return /* @__PURE__ */ i(
|
|
1795
|
-
|
|
1871
|
+
wn,
|
|
1796
1872
|
{
|
|
1797
|
-
isSelected:
|
|
1798
|
-
isStartDate:
|
|
1873
|
+
isSelected: c,
|
|
1874
|
+
isStartDate: r,
|
|
1799
1875
|
isEndDate: l,
|
|
1800
1876
|
isSelectedMonth: h,
|
|
1801
|
-
isLastDay:
|
|
1802
|
-
isFirstDay:
|
|
1877
|
+
isLastDay: p,
|
|
1878
|
+
isFirstDay: s,
|
|
1803
1879
|
children: /* @__PURE__ */ i(
|
|
1804
|
-
|
|
1880
|
+
Bn,
|
|
1805
1881
|
{
|
|
1806
|
-
...
|
|
1882
|
+
...a,
|
|
1807
1883
|
day: t,
|
|
1808
|
-
selected:
|
|
1809
|
-
isDateRangeLimit:
|
|
1884
|
+
selected: c || r || l,
|
|
1885
|
+
isDateRangeLimit: r || l,
|
|
1886
|
+
"data-name": "pickers-day"
|
|
1810
1887
|
}
|
|
1811
1888
|
)
|
|
1812
1889
|
}
|
|
1813
1890
|
);
|
|
1814
1891
|
}
|
|
1815
|
-
const
|
|
1892
|
+
const Sn = g(v, {
|
|
1816
1893
|
shouldForwardProp: (t) => !["variant"].includes(t)
|
|
1817
1894
|
})(({ variant: t, theme: e }) => ({
|
|
1818
1895
|
display: "flex",
|
|
@@ -1862,178 +1939,197 @@ const kn = p(v, {
|
|
|
1862
1939
|
}
|
|
1863
1940
|
}
|
|
1864
1941
|
}));
|
|
1865
|
-
function
|
|
1942
|
+
function $o({
|
|
1866
1943
|
globalHelperText: t,
|
|
1867
1944
|
error: e,
|
|
1868
1945
|
variant: n = "outlined",
|
|
1869
1946
|
startProps: o,
|
|
1870
|
-
endProps:
|
|
1871
|
-
|
|
1947
|
+
endProps: a,
|
|
1948
|
+
"aria-label": r,
|
|
1949
|
+
"data-testid": l,
|
|
1950
|
+
...c
|
|
1872
1951
|
}) {
|
|
1873
|
-
const
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1952
|
+
const s = F(), p = R(s), [h, d] = $(!1), [m, u] = $(!1), [f, M] = $(
|
|
1953
|
+
(o == null ? void 0 : o.value) || null
|
|
1954
|
+
), [b, I] = $((a == null ? void 0 : a.value) || null), [k, D] = $(
|
|
1955
|
+
(a == null ? void 0 : a.value) ?? (o == null ? void 0 : o.value) ?? /* @__PURE__ */ new Date()
|
|
1956
|
+
), x = e ?? (o == null ? void 0 : o.error) ?? (a == null ? void 0 : a.error), C = (A, L) => {
|
|
1957
|
+
M(A), o != null && o.onChange && o.onChange(A, L), A && L.validationError === null && !m && L.trigger === null && (u(!1), d(!0));
|
|
1958
|
+
}, B = (A, L) => {
|
|
1959
|
+
I(A), a != null && a.onChange && a.onChange(A, L);
|
|
1960
|
+
}, O = () => {
|
|
1878
1961
|
u(!0), d(!1), setTimeout(() => {
|
|
1879
|
-
|
|
1962
|
+
D(f ?? /* @__PURE__ */ new Date());
|
|
1880
1963
|
}, 120);
|
|
1881
|
-
},
|
|
1964
|
+
}, w = () => {
|
|
1882
1965
|
u(!1), d(!0), setTimeout(() => {
|
|
1883
|
-
|
|
1966
|
+
D(b ?? f ?? /* @__PURE__ */ new Date());
|
|
1884
1967
|
}, 120);
|
|
1885
|
-
},
|
|
1968
|
+
}, E = () => {
|
|
1886
1969
|
u(!1), d(!0), setTimeout(() => {
|
|
1887
|
-
|
|
1970
|
+
D(b ?? f ?? /* @__PURE__ */ new Date());
|
|
1888
1971
|
}, 120);
|
|
1889
1972
|
};
|
|
1890
1973
|
return /* @__PURE__ */ y(v, { children: [
|
|
1891
|
-
/* @__PURE__ */ y(
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
...
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1974
|
+
/* @__PURE__ */ y(
|
|
1975
|
+
Sn,
|
|
1976
|
+
{
|
|
1977
|
+
variant: n,
|
|
1978
|
+
"data-name": "date-range-picker",
|
|
1979
|
+
"aria-label": r,
|
|
1980
|
+
"data-testid": l,
|
|
1981
|
+
children: [
|
|
1982
|
+
/* @__PURE__ */ i(
|
|
1983
|
+
at,
|
|
1984
|
+
{
|
|
1985
|
+
...c,
|
|
1986
|
+
...o,
|
|
1987
|
+
value: (o == null ? void 0 : o.value) ?? f,
|
|
1988
|
+
maxDate: b ?? void 0,
|
|
1989
|
+
label: (o == null ? void 0 : o.label) ?? p.formatMessage({ id: "c4r.form.startDate" }),
|
|
1990
|
+
slotProps: {
|
|
1991
|
+
popper: {
|
|
1992
|
+
placement: "bottom-start",
|
|
1993
|
+
"aria-label": p.formatMessage({
|
|
1994
|
+
id: "c4r.form.startDateCalendar"
|
|
1995
|
+
})
|
|
1996
|
+
},
|
|
1997
|
+
...o == null ? void 0 : o.slotProps
|
|
1998
|
+
},
|
|
1999
|
+
slots: {
|
|
2000
|
+
openPickerIcon: pe,
|
|
2001
|
+
day: (A) => /* @__PURE__ */ i(
|
|
2002
|
+
lt,
|
|
2003
|
+
{
|
|
2004
|
+
...A,
|
|
2005
|
+
startDate: f,
|
|
2006
|
+
endDate: b,
|
|
2007
|
+
selectedMonth: k
|
|
2008
|
+
}
|
|
2009
|
+
),
|
|
2010
|
+
...o == null ? void 0 : o.slots
|
|
2011
|
+
},
|
|
2012
|
+
error: (o == null ? void 0 : o.error) ?? e,
|
|
2013
|
+
open: m,
|
|
2014
|
+
onChange: C,
|
|
2015
|
+
onOpen: O,
|
|
2016
|
+
onClose: w,
|
|
2017
|
+
onMonthChange: (A) => D(A),
|
|
2018
|
+
variant: n
|
|
2019
|
+
}
|
|
2020
|
+
),
|
|
2021
|
+
/* @__PURE__ */ i(
|
|
2022
|
+
at,
|
|
2023
|
+
{
|
|
2024
|
+
...c,
|
|
2025
|
+
...a,
|
|
2026
|
+
value: (a == null ? void 0 : a.value) ?? b,
|
|
2027
|
+
minDate: f ?? void 0,
|
|
2028
|
+
slotProps: {
|
|
2029
|
+
popper: {
|
|
2030
|
+
"aria-label": p.formatMessage({
|
|
2031
|
+
id: "c4r.form.endDateCalendar"
|
|
2032
|
+
})
|
|
2033
|
+
},
|
|
2034
|
+
...a == null ? void 0 : a.slotProps
|
|
2035
|
+
},
|
|
2036
|
+
slots: {
|
|
2037
|
+
day: (A) => /* @__PURE__ */ i(
|
|
2038
|
+
lt,
|
|
2039
|
+
{
|
|
2040
|
+
...A,
|
|
2041
|
+
startDate: f,
|
|
2042
|
+
endDate: b,
|
|
2043
|
+
selectedMonth: k
|
|
2044
|
+
}
|
|
2045
|
+
),
|
|
2046
|
+
...a == null ? void 0 : a.slots
|
|
2047
|
+
},
|
|
2048
|
+
label: (a == null ? void 0 : a.label) ?? p.formatMessage({ id: "c4r.form.endDate" }),
|
|
2049
|
+
error: (a == null ? void 0 : a.error) ?? e,
|
|
2050
|
+
open: h,
|
|
2051
|
+
onOpen: E,
|
|
2052
|
+
onClose: () => d(!1),
|
|
2053
|
+
onChange: B,
|
|
2054
|
+
onMonthChange: (A) => D(A),
|
|
2055
|
+
variant: n
|
|
2056
|
+
}
|
|
2057
|
+
)
|
|
2058
|
+
]
|
|
2059
|
+
}
|
|
2060
|
+
),
|
|
2061
|
+
t && /* @__PURE__ */ i(ht, { error: x, children: t })
|
|
1970
2062
|
] });
|
|
1971
2063
|
}
|
|
1972
|
-
const
|
|
1973
|
-
const
|
|
2064
|
+
const $t = (t, e, n, o) => {
|
|
2065
|
+
const a = t == null ? void 0 : t.includes("hours"), r = t == null ? void 0 : t.includes("seconds"), l = t == null ? void 0 : t.includes("minutes"), c = (t == null ? void 0 : t.length) === 1 && t[0] === "hours";
|
|
1974
2066
|
if (o) return o;
|
|
1975
|
-
const
|
|
1976
|
-
return e &&
|
|
2067
|
+
const s = [];
|
|
2068
|
+
return e && s.push("MM/dd/yyyy "), a && s.push(n ? "hh" : "HH"), c || s.push(":"), l && s.push("mm"), r && s.push(":ss"), n && s.push(" a"), s.join("");
|
|
1977
2069
|
};
|
|
1978
|
-
function
|
|
2070
|
+
function Ro({
|
|
1979
2071
|
handleClear: t,
|
|
1980
2072
|
variant: e = "outlined",
|
|
1981
2073
|
size: n = "small",
|
|
1982
2074
|
label: o,
|
|
1983
|
-
labelHelpTooltip:
|
|
1984
|
-
type:
|
|
2075
|
+
labelHelpTooltip: a,
|
|
2076
|
+
type: r,
|
|
1985
2077
|
helperText: l,
|
|
1986
|
-
placeholder:
|
|
1987
|
-
error:
|
|
1988
|
-
showClock:
|
|
2078
|
+
placeholder: c,
|
|
2079
|
+
error: s,
|
|
2080
|
+
showClock: p = !0,
|
|
1989
2081
|
readOnly: h,
|
|
1990
|
-
slotProps:
|
|
1991
|
-
slots:
|
|
1992
|
-
ampm:
|
|
1993
|
-
views:
|
|
1994
|
-
format:
|
|
1995
|
-
|
|
2082
|
+
slotProps: d,
|
|
2083
|
+
slots: m,
|
|
2084
|
+
ampm: u = !0,
|
|
2085
|
+
views: f = ["hours", "minutes"],
|
|
2086
|
+
format: M,
|
|
2087
|
+
"data-testid": b,
|
|
2088
|
+
"aria-label": I,
|
|
2089
|
+
...k
|
|
1996
2090
|
}) {
|
|
1997
|
-
const
|
|
1998
|
-
return
|
|
1999
|
-
if (!
|
|
2000
|
-
const
|
|
2001
|
-
var
|
|
2002
|
-
const
|
|
2003
|
-
|
|
2091
|
+
const D = F(), x = R(D), C = Y(null), [B, O] = $(0);
|
|
2092
|
+
return _(() => {
|
|
2093
|
+
if (!C.current) return;
|
|
2094
|
+
const w = new ResizeObserver((E) => {
|
|
2095
|
+
var L;
|
|
2096
|
+
const A = (L = E[0]) == null ? void 0 : L.contentRect.width;
|
|
2097
|
+
A && O(A);
|
|
2004
2098
|
});
|
|
2005
|
-
return
|
|
2006
|
-
|
|
2099
|
+
return w.observe(C.current), () => {
|
|
2100
|
+
w.disconnect();
|
|
2007
2101
|
};
|
|
2008
2102
|
}, []), /* @__PURE__ */ i(
|
|
2009
|
-
|
|
2103
|
+
tt,
|
|
2010
2104
|
{
|
|
2011
2105
|
size: n,
|
|
2012
2106
|
variant: e,
|
|
2013
2107
|
readOnly: h,
|
|
2014
|
-
"data-
|
|
2108
|
+
"data-name": "time-picker",
|
|
2109
|
+
"data-testid": b ?? "time-picker",
|
|
2110
|
+
"aria-label": I,
|
|
2015
2111
|
children: /* @__PURE__ */ i(
|
|
2016
|
-
|
|
2112
|
+
he,
|
|
2017
2113
|
{
|
|
2018
|
-
...
|
|
2019
|
-
ref:
|
|
2114
|
+
...k,
|
|
2115
|
+
ref: C,
|
|
2020
2116
|
label: /* @__PURE__ */ i(
|
|
2021
|
-
|
|
2117
|
+
K,
|
|
2022
2118
|
{
|
|
2023
|
-
label: o ??
|
|
2024
|
-
type:
|
|
2025
|
-
icon:
|
|
2119
|
+
label: o ?? x.formatMessage({ id: "c4r.form.time" }),
|
|
2120
|
+
type: r,
|
|
2121
|
+
icon: a && /* @__PURE__ */ i(H, { title: a, children: /* @__PURE__ */ i(J, { htmlColor: "text.secondary" }) })
|
|
2026
2122
|
}
|
|
2027
2123
|
),
|
|
2028
2124
|
views: ["hours"],
|
|
2029
|
-
format:
|
|
2125
|
+
format: $t(f, !1, u, M),
|
|
2030
2126
|
slotProps: {
|
|
2031
2127
|
textField: {
|
|
2032
2128
|
variant: e,
|
|
2033
2129
|
helperText: l,
|
|
2034
|
-
placeholder:
|
|
2130
|
+
placeholder: c,
|
|
2035
2131
|
size: n,
|
|
2036
|
-
error:
|
|
2132
|
+
error: s ?? void 0,
|
|
2037
2133
|
// undefined is needed to allow the component to control the error state for the default validation
|
|
2038
2134
|
inputProps: {
|
|
2039
2135
|
"data-testid": "time-picker-input"
|
|
@@ -2048,81 +2144,85 @@ function Io({
|
|
|
2048
2144
|
},
|
|
2049
2145
|
layout: {
|
|
2050
2146
|
sx: {
|
|
2051
|
-
width:
|
|
2147
|
+
width: B
|
|
2052
2148
|
}
|
|
2053
2149
|
},
|
|
2054
|
-
...
|
|
2150
|
+
...d
|
|
2055
2151
|
},
|
|
2056
2152
|
slots: {
|
|
2057
|
-
clearButton: (
|
|
2058
|
-
openPickerButton: (
|
|
2059
|
-
|
|
2153
|
+
clearButton: (w) => /* @__PURE__ */ i(Q, { ...w, size: n, variant: e }),
|
|
2154
|
+
openPickerButton: (w) => /* @__PURE__ */ i(
|
|
2155
|
+
W,
|
|
2060
2156
|
{
|
|
2061
|
-
...
|
|
2157
|
+
...w,
|
|
2062
2158
|
size: n,
|
|
2063
|
-
"aria-label":
|
|
2159
|
+
"aria-label": x.formatMessage({
|
|
2064
2160
|
id: "c4r.form.chooseDate"
|
|
2065
2161
|
})
|
|
2066
2162
|
}
|
|
2067
2163
|
),
|
|
2068
|
-
...
|
|
2164
|
+
...m
|
|
2069
2165
|
},
|
|
2070
|
-
disableOpenPicker: !
|
|
2166
|
+
disableOpenPicker: !p,
|
|
2071
2167
|
readOnly: h,
|
|
2072
|
-
ampm:
|
|
2168
|
+
ampm: u
|
|
2073
2169
|
}
|
|
2074
2170
|
)
|
|
2075
2171
|
}
|
|
2076
2172
|
);
|
|
2077
2173
|
}
|
|
2078
|
-
function
|
|
2174
|
+
function Fo({
|
|
2079
2175
|
handleClear: t,
|
|
2080
2176
|
variant: e = "outlined",
|
|
2081
2177
|
size: n = "small",
|
|
2082
2178
|
label: o,
|
|
2083
|
-
labelHelpTooltip:
|
|
2084
|
-
type:
|
|
2179
|
+
labelHelpTooltip: a,
|
|
2180
|
+
type: r,
|
|
2085
2181
|
helperText: l,
|
|
2086
|
-
placeholder:
|
|
2087
|
-
error:
|
|
2088
|
-
showCalendar:
|
|
2182
|
+
placeholder: c,
|
|
2183
|
+
error: s,
|
|
2184
|
+
showCalendar: p = !0,
|
|
2089
2185
|
readOnly: h,
|
|
2090
|
-
slotProps:
|
|
2091
|
-
slots:
|
|
2092
|
-
ampm:
|
|
2093
|
-
views:
|
|
2094
|
-
format:
|
|
2095
|
-
|
|
2186
|
+
slotProps: d,
|
|
2187
|
+
slots: m,
|
|
2188
|
+
ampm: u = !0,
|
|
2189
|
+
views: f = ["hours", "minutes"],
|
|
2190
|
+
format: M,
|
|
2191
|
+
"data-testid": b,
|
|
2192
|
+
"aria-label": I,
|
|
2193
|
+
...k
|
|
2096
2194
|
}) {
|
|
2097
|
-
const
|
|
2195
|
+
const D = F(), x = R(D);
|
|
2098
2196
|
return /* @__PURE__ */ i(
|
|
2099
|
-
|
|
2197
|
+
tt,
|
|
2100
2198
|
{
|
|
2101
2199
|
size: n,
|
|
2102
2200
|
variant: e,
|
|
2103
2201
|
readOnly: h,
|
|
2104
|
-
"data-
|
|
2202
|
+
"data-name": "date-time-picker",
|
|
2203
|
+
"data-testid": b ?? "date-time-picker",
|
|
2204
|
+
"aria-label": I,
|
|
2105
2205
|
children: /* @__PURE__ */ i(
|
|
2106
|
-
|
|
2206
|
+
be,
|
|
2107
2207
|
{
|
|
2108
|
-
...
|
|
2208
|
+
...k,
|
|
2109
2209
|
label: /* @__PURE__ */ i(
|
|
2110
|
-
|
|
2210
|
+
K,
|
|
2111
2211
|
{
|
|
2112
|
-
label: o ??
|
|
2113
|
-
type:
|
|
2114
|
-
icon:
|
|
2212
|
+
label: o ?? x.formatMessage({ id: "c4r.form.time" }),
|
|
2213
|
+
type: r,
|
|
2214
|
+
icon: a && /* @__PURE__ */ i(H, { title: a, children: /* @__PURE__ */ i(J, { htmlColor: "text.secondary" }) })
|
|
2115
2215
|
}
|
|
2116
2216
|
),
|
|
2117
2217
|
views: ["year", "month", "day", "hours"],
|
|
2118
|
-
format:
|
|
2218
|
+
format: $t(f, !0, u, M),
|
|
2119
2219
|
slotProps: {
|
|
2120
2220
|
textField: {
|
|
2121
2221
|
variant: e,
|
|
2122
2222
|
helperText: l,
|
|
2123
|
-
placeholder:
|
|
2223
|
+
placeholder: c,
|
|
2124
2224
|
size: n,
|
|
2125
|
-
error:
|
|
2225
|
+
error: s ?? void 0,
|
|
2126
2226
|
// undefined is needed to allow the component to control the error state for the default validation
|
|
2127
2227
|
inputProps: {
|
|
2128
2228
|
"data-testid": "date-time-picker-input"
|
|
@@ -2132,61 +2232,61 @@ function Bo({
|
|
|
2132
2232
|
clearable: !!t,
|
|
2133
2233
|
onClear: t
|
|
2134
2234
|
},
|
|
2135
|
-
...
|
|
2235
|
+
...d
|
|
2136
2236
|
},
|
|
2137
2237
|
slots: {
|
|
2138
|
-
clearButton: (
|
|
2139
|
-
openPickerButton: (
|
|
2140
|
-
|
|
2238
|
+
clearButton: (C) => /* @__PURE__ */ i(Q, { ...C, size: n, variant: e }),
|
|
2239
|
+
openPickerButton: (C) => /* @__PURE__ */ i(
|
|
2240
|
+
W,
|
|
2141
2241
|
{
|
|
2142
|
-
...
|
|
2242
|
+
...C,
|
|
2143
2243
|
size: n,
|
|
2144
|
-
"aria-label":
|
|
2244
|
+
"aria-label": x.formatMessage({
|
|
2145
2245
|
id: "c4r.form.chooseDate"
|
|
2146
2246
|
})
|
|
2147
2247
|
}
|
|
2148
2248
|
),
|
|
2149
|
-
...
|
|
2249
|
+
...m
|
|
2150
2250
|
},
|
|
2151
|
-
disableOpenPicker: !
|
|
2251
|
+
disableOpenPicker: !p,
|
|
2152
2252
|
readOnly: h,
|
|
2153
|
-
ampm:
|
|
2253
|
+
ampm: u
|
|
2154
2254
|
}
|
|
2155
2255
|
)
|
|
2156
2256
|
}
|
|
2157
2257
|
);
|
|
2158
2258
|
}
|
|
2159
|
-
const
|
|
2259
|
+
const Tn = [{ outlinedBullet: !1, value: "" }], $n = g("ul")(({ theme: t }) => ({
|
|
2160
2260
|
listStyle: "none",
|
|
2161
2261
|
paddingLeft: 0,
|
|
2162
2262
|
margin: t.spacing(0.5, 0, 0, 0)
|
|
2163
|
-
})),
|
|
2263
|
+
})), Rn = g("li")(({ theme: t }) => ({
|
|
2164
2264
|
display: "flex",
|
|
2165
2265
|
alignItems: "center",
|
|
2166
2266
|
justifyContent: "space-between",
|
|
2167
2267
|
"&:not(:last-child)": {
|
|
2168
2268
|
marginBottom: t.spacing(0.5)
|
|
2169
2269
|
}
|
|
2170
|
-
})),
|
|
2270
|
+
})), Fn = g("span")(({ theme: t }) => ({
|
|
2171
2271
|
width: t.spacing(1),
|
|
2172
2272
|
height: t.spacing(1),
|
|
2173
2273
|
marginRight: t.spacing(0.5),
|
|
2174
2274
|
border: `2px solid ${t.palette.qualitative.bold[1]}`,
|
|
2175
2275
|
borderRadius: "50%",
|
|
2176
2276
|
backgroundColor: t.palette.qualitative.bold[1]
|
|
2177
|
-
})),
|
|
2277
|
+
})), On = g(S)(({ theme: t }) => ({
|
|
2178
2278
|
minWidth: t.spacing(10),
|
|
2179
2279
|
marginRight: t.spacing(1.5)
|
|
2180
2280
|
}));
|
|
2181
|
-
function
|
|
2182
|
-
items: t =
|
|
2281
|
+
function Oo({
|
|
2282
|
+
items: t = Tn,
|
|
2183
2283
|
title: e
|
|
2184
2284
|
}) {
|
|
2185
|
-
return /* @__PURE__ */ y(
|
|
2186
|
-
e && /* @__PURE__ */ i(
|
|
2187
|
-
/* @__PURE__ */ i(
|
|
2285
|
+
return /* @__PURE__ */ y(V, { children: [
|
|
2286
|
+
e && /* @__PURE__ */ i(S, { color: "inherit", variant: "caption", weight: "medium", children: e }),
|
|
2287
|
+
/* @__PURE__ */ i($n, { children: t.map((n, o) => /* @__PURE__ */ y(Rn, { children: [
|
|
2188
2288
|
/* @__PURE__ */ i(
|
|
2189
|
-
|
|
2289
|
+
Fn,
|
|
2190
2290
|
{
|
|
2191
2291
|
style: {
|
|
2192
2292
|
backgroundColor: `${n.outlinedBullet ? "transparent" : n.color}`,
|
|
@@ -2194,17 +2294,17 @@ function wo({
|
|
|
2194
2294
|
}
|
|
2195
2295
|
}
|
|
2196
2296
|
),
|
|
2197
|
-
n.category && /* @__PURE__ */ i(
|
|
2198
|
-
/* @__PURE__ */ i(
|
|
2297
|
+
n.category && /* @__PURE__ */ i(On, { color: "inherit", variant: "caption", children: n.category }),
|
|
2298
|
+
/* @__PURE__ */ i(S, { color: "inherit", variant: "caption", weight: "medium", children: n.value })
|
|
2199
2299
|
] }, o)) })
|
|
2200
2300
|
] });
|
|
2201
2301
|
}
|
|
2202
|
-
const
|
|
2302
|
+
const ct = {
|
|
2203
2303
|
small: "480px",
|
|
2204
2304
|
medium: "640px",
|
|
2205
2305
|
large: "640px",
|
|
2206
2306
|
xlarge: "720px"
|
|
2207
|
-
},
|
|
2307
|
+
}, st = {
|
|
2208
2308
|
small: {
|
|
2209
2309
|
width: "432px",
|
|
2210
2310
|
maxWidth: "432px"
|
|
@@ -2223,7 +2323,7 @@ const lt = {
|
|
|
2223
2323
|
height: "calc(100vh - 80px)",
|
|
2224
2324
|
maxWidth: "960px"
|
|
2225
2325
|
}
|
|
2226
|
-
},
|
|
2326
|
+
}, dt = g(ee, {
|
|
2227
2327
|
shouldForwardProp: (t) => !["fullScreen", "height", "width", "hasForm"].includes(t)
|
|
2228
2328
|
})(
|
|
2229
2329
|
({
|
|
@@ -2231,30 +2331,30 @@ const lt = {
|
|
|
2231
2331
|
height: e,
|
|
2232
2332
|
width: n,
|
|
2233
2333
|
hasForm: o,
|
|
2234
|
-
size:
|
|
2235
|
-
theme:
|
|
2334
|
+
size: a = "small",
|
|
2335
|
+
theme: r
|
|
2236
2336
|
}) => ({
|
|
2237
2337
|
"&.MuiPaper-root": {
|
|
2238
2338
|
position: "relative",
|
|
2239
2339
|
display: "flex",
|
|
2240
2340
|
flexDirection: "column",
|
|
2241
|
-
margin:
|
|
2242
|
-
borderRadius:
|
|
2243
|
-
...
|
|
2244
|
-
maxHeight:
|
|
2245
|
-
[`@media (max-height:${
|
|
2341
|
+
margin: r.spacing(5),
|
|
2342
|
+
borderRadius: r.spacing(1),
|
|
2343
|
+
...st[a],
|
|
2344
|
+
maxHeight: ct[a],
|
|
2345
|
+
[`@media (max-height:${ct[a]})`]: {
|
|
2246
2346
|
maxHeight: "calc(100vh - 80px)",
|
|
2247
|
-
...
|
|
2347
|
+
...a === "large" && {
|
|
2248
2348
|
minHeight: e !== "auto" ? "calc(100vh - 80px)" : "auto"
|
|
2249
2349
|
}
|
|
2250
2350
|
},
|
|
2251
2351
|
...t && {
|
|
2252
2352
|
width: "100vw",
|
|
2253
|
-
maxWidth: `calc(100vw - ${
|
|
2353
|
+
maxWidth: `calc(100vw - ${r.spacing(10)})`,
|
|
2254
2354
|
height: "100vh",
|
|
2255
|
-
maxHeight: `calc(100vh - ${
|
|
2256
|
-
margin:
|
|
2257
|
-
borderRadius:
|
|
2355
|
+
maxHeight: `calc(100vh - ${r.spacing(10)})`,
|
|
2356
|
+
margin: r.spacing(5),
|
|
2357
|
+
borderRadius: r.spacing(1)
|
|
2258
2358
|
},
|
|
2259
2359
|
...e && {
|
|
2260
2360
|
height: e,
|
|
@@ -2263,7 +2363,7 @@ const lt = {
|
|
|
2263
2363
|
...n && {
|
|
2264
2364
|
width: n
|
|
2265
2365
|
},
|
|
2266
|
-
[
|
|
2366
|
+
[r.breakpoints.down("sm")]: {
|
|
2267
2367
|
position: "absolute",
|
|
2268
2368
|
width: "100%",
|
|
2269
2369
|
maxWidth: "100%",
|
|
@@ -2277,21 +2377,21 @@ const lt = {
|
|
|
2277
2377
|
borderRadius: 0,
|
|
2278
2378
|
...e && {
|
|
2279
2379
|
top: "auto",
|
|
2280
|
-
borderRadius:
|
|
2380
|
+
borderRadius: r.spacing(1, 1, 0, 0),
|
|
2281
2381
|
height: e,
|
|
2282
2382
|
minHeight: e
|
|
2283
2383
|
}
|
|
2284
2384
|
},
|
|
2285
2385
|
// Special case for Dialogs wrapped in Form
|
|
2286
2386
|
...o && {
|
|
2287
|
-
maxHeight: `calc(100vh - ${
|
|
2387
|
+
maxHeight: `calc(100vh - ${r.spacing(10)})`,
|
|
2288
2388
|
form: {
|
|
2289
2389
|
flex: 1,
|
|
2290
2390
|
display: "flex",
|
|
2291
2391
|
flexDirection: "column",
|
|
2292
2392
|
justifyContent: "space-between",
|
|
2293
2393
|
overflow: "hidden",
|
|
2294
|
-
...
|
|
2394
|
+
...st[a],
|
|
2295
2395
|
maxWidth: "100%",
|
|
2296
2396
|
...t && {
|
|
2297
2397
|
width: "100%",
|
|
@@ -2306,14 +2406,14 @@ const lt = {
|
|
|
2306
2406
|
...n && {
|
|
2307
2407
|
width: n
|
|
2308
2408
|
},
|
|
2309
|
-
[
|
|
2409
|
+
[r.breakpoints.down("sm")]: {
|
|
2310
2410
|
width: "100%",
|
|
2311
2411
|
maxWidth: "100%",
|
|
2312
2412
|
height: "100vh",
|
|
2313
2413
|
maxHeight: "100vh",
|
|
2314
2414
|
...e && {
|
|
2315
2415
|
top: "auto",
|
|
2316
|
-
borderRadius:
|
|
2416
|
+
borderRadius: r.spacing(1, 1, 0, 0),
|
|
2317
2417
|
height: e,
|
|
2318
2418
|
minHeight: e
|
|
2319
2419
|
}
|
|
@@ -2323,123 +2423,128 @@ const lt = {
|
|
|
2323
2423
|
}
|
|
2324
2424
|
})
|
|
2325
2425
|
);
|
|
2326
|
-
function
|
|
2426
|
+
function Ln({
|
|
2327
2427
|
nonModal: t,
|
|
2328
2428
|
children: e,
|
|
2329
2429
|
size: n = "small",
|
|
2330
2430
|
PaperProps: o,
|
|
2331
|
-
fullScreen:
|
|
2332
|
-
height:
|
|
2431
|
+
fullScreen: a,
|
|
2432
|
+
height: r,
|
|
2333
2433
|
width: l,
|
|
2334
|
-
hasForm:
|
|
2335
|
-
"aria-label":
|
|
2336
|
-
"data-testid":
|
|
2434
|
+
hasForm: c,
|
|
2435
|
+
"aria-label": s,
|
|
2436
|
+
"data-testid": p,
|
|
2337
2437
|
...h
|
|
2338
|
-
}) {
|
|
2438
|
+
}, d) {
|
|
2339
2439
|
return t ? /* @__PURE__ */ i(
|
|
2340
|
-
|
|
2440
|
+
dt,
|
|
2341
2441
|
{
|
|
2342
2442
|
size: n,
|
|
2343
|
-
fullScreen:
|
|
2344
|
-
height:
|
|
2443
|
+
fullScreen: a,
|
|
2444
|
+
height: r,
|
|
2345
2445
|
width: l,
|
|
2346
|
-
hasForm:
|
|
2347
|
-
"aria-label":
|
|
2348
|
-
"data-testid":
|
|
2446
|
+
hasForm: c,
|
|
2447
|
+
"aria-label": s,
|
|
2448
|
+
"data-testid": p,
|
|
2449
|
+
"data-name": "dialog",
|
|
2349
2450
|
...h,
|
|
2451
|
+
ref: d,
|
|
2350
2452
|
children: e
|
|
2351
2453
|
}
|
|
2352
2454
|
) : /* @__PURE__ */ i(
|
|
2353
|
-
|
|
2455
|
+
ne,
|
|
2354
2456
|
{
|
|
2355
|
-
PaperComponent:
|
|
2457
|
+
PaperComponent: dt,
|
|
2356
2458
|
PaperProps: {
|
|
2357
2459
|
...o,
|
|
2358
2460
|
size: n,
|
|
2359
|
-
fullScreen:
|
|
2360
|
-
height:
|
|
2461
|
+
fullScreen: a,
|
|
2462
|
+
height: r,
|
|
2361
2463
|
width: l,
|
|
2362
|
-
hasForm:
|
|
2464
|
+
hasForm: c
|
|
2363
2465
|
},
|
|
2364
|
-
fullScreen:
|
|
2466
|
+
fullScreen: a,
|
|
2365
2467
|
role: "section",
|
|
2366
|
-
"aria-label":
|
|
2367
|
-
"data-testid":
|
|
2468
|
+
"aria-label": s,
|
|
2469
|
+
"data-testid": p,
|
|
2368
2470
|
"data-size": n,
|
|
2369
2471
|
"data-width": l,
|
|
2370
|
-
"data-height":
|
|
2472
|
+
"data-height": r,
|
|
2473
|
+
"data-name": "dialog",
|
|
2371
2474
|
...h,
|
|
2475
|
+
ref: d,
|
|
2372
2476
|
children: e
|
|
2373
2477
|
}
|
|
2374
2478
|
);
|
|
2375
2479
|
}
|
|
2376
|
-
const
|
|
2480
|
+
const Lo = T(Ln), Wn = g(oe)(() => ({
|
|
2377
2481
|
padding: 0,
|
|
2378
2482
|
zIndex: 10
|
|
2379
|
-
})),
|
|
2483
|
+
})), En = g(v)(({ theme: t }) => ({
|
|
2380
2484
|
display: "flex",
|
|
2381
2485
|
alignItems: "center",
|
|
2382
2486
|
justifyContent: "space-between",
|
|
2383
2487
|
padding: t.spacing(2),
|
|
2384
2488
|
minHeight: t.spacing(8)
|
|
2385
|
-
})),
|
|
2489
|
+
})), ut = g(v)(({ theme: t }) => ({
|
|
2386
2490
|
display: "flex",
|
|
2387
2491
|
alignItems: "center",
|
|
2388
2492
|
gap: t.spacing(1),
|
|
2389
2493
|
overflow: "hidden"
|
|
2390
|
-
})),
|
|
2494
|
+
})), Hn = g(Mt)(({ theme: t }) => ({
|
|
2391
2495
|
color: t.palette.text.secondary
|
|
2392
|
-
})),
|
|
2496
|
+
})), _n = g(j)(() => ({
|
|
2393
2497
|
"+ .MuiDialogContent-root": {
|
|
2394
2498
|
borderTop: "none !important"
|
|
2395
2499
|
}
|
|
2396
2500
|
}));
|
|
2397
|
-
function
|
|
2501
|
+
function Wo({
|
|
2398
2502
|
title: t,
|
|
2399
2503
|
chipLabel: e,
|
|
2400
2504
|
chipProps: n,
|
|
2401
2505
|
children: o,
|
|
2402
|
-
onClose:
|
|
2403
|
-
secondaryActions:
|
|
2506
|
+
onClose: a,
|
|
2507
|
+
secondaryActions: r,
|
|
2404
2508
|
"aria-label": l,
|
|
2405
|
-
closeIcon:
|
|
2406
|
-
...
|
|
2509
|
+
closeIcon: c,
|
|
2510
|
+
...s
|
|
2407
2511
|
}) {
|
|
2408
|
-
const
|
|
2409
|
-
return /* @__PURE__ */ y(
|
|
2410
|
-
/* @__PURE__ */ y(
|
|
2411
|
-
/* @__PURE__ */ y(
|
|
2412
|
-
/* @__PURE__ */ y(
|
|
2512
|
+
const p = F(), h = R(p);
|
|
2513
|
+
return /* @__PURE__ */ y(V, { children: [
|
|
2514
|
+
/* @__PURE__ */ y(Wn, { component: "div", "data-name": "dialog-header", ...s, children: [
|
|
2515
|
+
/* @__PURE__ */ y(En, { children: [
|
|
2516
|
+
/* @__PURE__ */ y(ut, { flex: 1, maxWidth: 0.8, children: [
|
|
2413
2517
|
/* @__PURE__ */ i(
|
|
2414
|
-
|
|
2518
|
+
S,
|
|
2415
2519
|
{
|
|
2416
2520
|
component: "h2",
|
|
2417
2521
|
variant: "inherit",
|
|
2418
2522
|
noWrap: !0,
|
|
2419
2523
|
"aria-label": l,
|
|
2524
|
+
role: "heading",
|
|
2420
2525
|
children: t
|
|
2421
2526
|
}
|
|
2422
2527
|
),
|
|
2423
|
-
e && /* @__PURE__ */ i(
|
|
2528
|
+
e && /* @__PURE__ */ i(ie, { color: "default", label: e, ...n })
|
|
2424
2529
|
] }),
|
|
2425
|
-
/* @__PURE__ */ y(
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2530
|
+
/* @__PURE__ */ y(ut, { children: [
|
|
2531
|
+
r,
|
|
2532
|
+
a && /* @__PURE__ */ i(
|
|
2533
|
+
H,
|
|
2429
2534
|
{
|
|
2430
2535
|
title: h.formatMessage({ id: "c4r.button.close" }),
|
|
2431
2536
|
placement: "left",
|
|
2432
|
-
children: /* @__PURE__ */ i(
|
|
2537
|
+
children: /* @__PURE__ */ i(W, { onClick: a, children: c || /* @__PURE__ */ i(Hn, { "data-testid": "CloseIcon" }) })
|
|
2433
2538
|
}
|
|
2434
2539
|
)
|
|
2435
2540
|
] })
|
|
2436
2541
|
] }),
|
|
2437
2542
|
o
|
|
2438
2543
|
] }),
|
|
2439
|
-
o && /* @__PURE__ */ i(
|
|
2544
|
+
o && /* @__PURE__ */ i(_n, {})
|
|
2440
2545
|
] });
|
|
2441
2546
|
}
|
|
2442
|
-
const
|
|
2547
|
+
const Pn = g(ae, {
|
|
2443
2548
|
shouldForwardProp: (t) => !["scrollableContent", "withGutter", "withBottomGutter"].includes(t)
|
|
2444
2549
|
})(({ theme: t, scrollableContent: e, withGutter: n, withBottomGutter: o }) => ({
|
|
2445
2550
|
display: "flex",
|
|
@@ -2470,62 +2575,63 @@ const On = p(oe, {
|
|
|
2470
2575
|
}
|
|
2471
2576
|
}
|
|
2472
2577
|
}));
|
|
2473
|
-
function
|
|
2578
|
+
function Gn({
|
|
2474
2579
|
children: t,
|
|
2475
2580
|
scrollableContent: e,
|
|
2476
2581
|
hasFooterAlert: n,
|
|
2477
2582
|
withGutter: o = !0,
|
|
2478
|
-
withBottomGutter:
|
|
2479
|
-
onScroll:
|
|
2583
|
+
withBottomGutter: a = !0,
|
|
2584
|
+
onScroll: r,
|
|
2480
2585
|
...l
|
|
2481
|
-
},
|
|
2482
|
-
const
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
() =>
|
|
2486
|
-
[
|
|
2586
|
+
}, c) {
|
|
2587
|
+
const s = N(), [p, h] = $(null);
|
|
2588
|
+
Lt(
|
|
2589
|
+
c,
|
|
2590
|
+
() => p,
|
|
2591
|
+
[p]
|
|
2487
2592
|
);
|
|
2488
|
-
const
|
|
2489
|
-
(
|
|
2490
|
-
const
|
|
2491
|
-
|
|
2593
|
+
const d = nt(
|
|
2594
|
+
(u) => {
|
|
2595
|
+
const f = Math.abs(u.scrollHeight - u.clientHeight - u.scrollTop) < 1, M = u.scrollTop === 0, b = `1px solid ${s.palette.divider}`;
|
|
2596
|
+
u.style.borderTop = M ? "none" : b, u.style.borderBottom = f && !n ? "none" : b;
|
|
2492
2597
|
},
|
|
2493
|
-
[
|
|
2494
|
-
),
|
|
2495
|
-
(
|
|
2496
|
-
u
|
|
2598
|
+
[s.palette.divider, n]
|
|
2599
|
+
), m = nt(
|
|
2600
|
+
(u) => {
|
|
2601
|
+
d(u.target), r == null || r(u);
|
|
2497
2602
|
},
|
|
2498
|
-
[
|
|
2603
|
+
[d, r]
|
|
2499
2604
|
);
|
|
2500
|
-
return
|
|
2501
|
-
|
|
2502
|
-
}, [
|
|
2503
|
-
if (!
|
|
2504
|
-
const
|
|
2505
|
-
|
|
2605
|
+
return _(() => {
|
|
2606
|
+
p && d(p);
|
|
2607
|
+
}, [p, d]), _(() => {
|
|
2608
|
+
if (!p || typeof ResizeObserver > "u") return;
|
|
2609
|
+
const u = new ResizeObserver(() => {
|
|
2610
|
+
d(p);
|
|
2506
2611
|
});
|
|
2507
|
-
return
|
|
2508
|
-
}, [
|
|
2509
|
-
|
|
2612
|
+
return u.observe(p), () => u.disconnect();
|
|
2613
|
+
}, [p, d]), /* @__PURE__ */ i(
|
|
2614
|
+
Pn,
|
|
2510
2615
|
{
|
|
2511
2616
|
ref: h,
|
|
2512
|
-
onScroll:
|
|
2617
|
+
onScroll: m,
|
|
2513
2618
|
scrollableContent: e,
|
|
2514
2619
|
withGutter: o,
|
|
2515
|
-
withBottomGutter:
|
|
2620
|
+
withBottomGutter: a && o,
|
|
2621
|
+
"data-name": "dialog-content",
|
|
2516
2622
|
...l,
|
|
2517
2623
|
children: t
|
|
2518
2624
|
}
|
|
2519
2625
|
);
|
|
2520
2626
|
}
|
|
2521
|
-
const
|
|
2627
|
+
const jn = T(Gn), Eo = g(jn, {
|
|
2522
2628
|
shouldForwardProp: (t) => t !== "withAlert"
|
|
2523
2629
|
})(({ withAlert: t, theme: e }) => ({
|
|
2524
2630
|
padding: `${e.spacing(0, 2)} !important`,
|
|
2525
2631
|
...t && {
|
|
2526
2632
|
paddingBottom: `${e.spacing(3)} !important`
|
|
2527
2633
|
}
|
|
2528
|
-
})),
|
|
2634
|
+
})), Vn = g(Ct)(({ theme: t }) => ({
|
|
2529
2635
|
minHeight: "auto",
|
|
2530
2636
|
padding: 0,
|
|
2531
2637
|
backgroundColor: "transparent",
|
|
@@ -2539,14 +2645,14 @@ const Wn = O(Ln), $o = p(Wn, {
|
|
|
2539
2645
|
color: t.palette.text.primary
|
|
2540
2646
|
}
|
|
2541
2647
|
}));
|
|
2542
|
-
function
|
|
2648
|
+
function Rt({
|
|
2543
2649
|
children: t,
|
|
2544
2650
|
severity: e = "neutral",
|
|
2545
2651
|
...n
|
|
2546
2652
|
}) {
|
|
2547
|
-
return /* @__PURE__ */ i(
|
|
2653
|
+
return /* @__PURE__ */ i(Vn, { severity: e, ...n, "data-name": "dialog-alert", children: t });
|
|
2548
2654
|
}
|
|
2549
|
-
const
|
|
2655
|
+
const Nn = g(v, {
|
|
2550
2656
|
shouldForwardProp: (t) => !["dark", "hasChildren"].includes(t)
|
|
2551
2657
|
})(({ dark: t, hasChildren: e, theme: n }) => ({
|
|
2552
2658
|
flex: "0 0 auto",
|
|
@@ -2568,14 +2674,14 @@ const En = p(v, {
|
|
|
2568
2674
|
}
|
|
2569
2675
|
}
|
|
2570
2676
|
}
|
|
2571
|
-
})),
|
|
2677
|
+
})), Un = g(v)(() => ({
|
|
2572
2678
|
display: "flex",
|
|
2573
2679
|
alignItems: "center",
|
|
2574
2680
|
justifyContent: "space-between",
|
|
2575
2681
|
"& > div:empty": {
|
|
2576
2682
|
padding: 0
|
|
2577
2683
|
}
|
|
2578
|
-
})),
|
|
2684
|
+
})), Yn = g(v, {
|
|
2579
2685
|
shouldForwardProp: (t) => t !== "hasAlert"
|
|
2580
2686
|
})(({ hasAlert: t, theme: e }) => ({
|
|
2581
2687
|
display: "flex",
|
|
@@ -2583,7 +2689,7 @@ const En = p(v, {
|
|
|
2583
2689
|
gap: e.spacing(1),
|
|
2584
2690
|
padding: e.spacing(2),
|
|
2585
2691
|
paddingTop: t ? 0 : e.spacing(2)
|
|
2586
|
-
})),
|
|
2692
|
+
})), Ft = g(re, {
|
|
2587
2693
|
shouldForwardProp: (t) => t !== "hasAlert"
|
|
2588
2694
|
})(({ hasAlert: t, theme: e }) => ({
|
|
2589
2695
|
gap: e.spacing(1),
|
|
@@ -2593,41 +2699,42 @@ const En = p(v, {
|
|
|
2593
2699
|
".MuiButton-root + .MuiButton-root": {
|
|
2594
2700
|
marginLeft: 0
|
|
2595
2701
|
}
|
|
2596
|
-
})),
|
|
2702
|
+
})), qn = g(j)(() => ({
|
|
2597
2703
|
// To prevent double border in the top when content is scrollable
|
|
2598
2704
|
marginTop: "-1px"
|
|
2599
2705
|
}));
|
|
2600
|
-
function
|
|
2706
|
+
function Ho({
|
|
2601
2707
|
children: t,
|
|
2602
2708
|
secondaryActions: e,
|
|
2603
2709
|
alertContent: n,
|
|
2604
2710
|
alertProps: o,
|
|
2605
|
-
dark:
|
|
2606
|
-
topContent:
|
|
2711
|
+
dark: a,
|
|
2712
|
+
topContent: r,
|
|
2607
2713
|
...l
|
|
2608
2714
|
}) {
|
|
2609
|
-
return /* @__PURE__ */ y(
|
|
2610
|
-
|
|
2611
|
-
!!n && /* @__PURE__ */ i(
|
|
2715
|
+
return /* @__PURE__ */ y(V, { children: [
|
|
2716
|
+
r,
|
|
2717
|
+
!!n && /* @__PURE__ */ i(qn, {}),
|
|
2612
2718
|
/* @__PURE__ */ y(
|
|
2613
|
-
|
|
2719
|
+
Nn,
|
|
2614
2720
|
{
|
|
2615
2721
|
...l,
|
|
2616
|
-
dark:
|
|
2617
|
-
"data-theme":
|
|
2722
|
+
dark: a,
|
|
2723
|
+
"data-theme": a ? "dark" : "light",
|
|
2724
|
+
"data-name": "dialog-footer",
|
|
2618
2725
|
hasChildren: !!t,
|
|
2619
2726
|
children: [
|
|
2620
|
-
!!n && /* @__PURE__ */ i(v, { sx: { p: 2, pt: 1.5, pb: 1 }, children: /* @__PURE__ */ i(
|
|
2621
|
-
/* @__PURE__ */ y(
|
|
2622
|
-
/* @__PURE__ */ i(
|
|
2623
|
-
/* @__PURE__ */ i(
|
|
2727
|
+
!!n && /* @__PURE__ */ i(v, { sx: { p: 2, pt: 1.5, pb: 1 }, children: /* @__PURE__ */ i(Rt, { ...o, children: n }) }),
|
|
2728
|
+
/* @__PURE__ */ y(Un, { children: [
|
|
2729
|
+
/* @__PURE__ */ i(Yn, { hasAlert: !!n, children: e }),
|
|
2730
|
+
/* @__PURE__ */ i(Ft, { hasAlert: !!n, children: t })
|
|
2624
2731
|
] })
|
|
2625
2732
|
]
|
|
2626
2733
|
}
|
|
2627
2734
|
)
|
|
2628
2735
|
] });
|
|
2629
2736
|
}
|
|
2630
|
-
const
|
|
2737
|
+
const zn = g(v)(({ theme: t }) => ({
|
|
2631
2738
|
position: "absolute",
|
|
2632
2739
|
width: "100%",
|
|
2633
2740
|
zIndex: 100,
|
|
@@ -2640,9 +2747,9 @@ const jn = p(v)(({ theme: t }) => ({
|
|
|
2640
2747
|
boxSizing: "border-box",
|
|
2641
2748
|
alignItems: "flex-end",
|
|
2642
2749
|
background: t.palette.white[60]
|
|
2643
|
-
})),
|
|
2750
|
+
})), Zn = g("div")(() => ({
|
|
2644
2751
|
width: "100%"
|
|
2645
|
-
})),
|
|
2752
|
+
})), Jn = g(v)(({ theme: t }) => ({
|
|
2646
2753
|
width: "100%",
|
|
2647
2754
|
padding: t.spacing(1.5, 2, 2),
|
|
2648
2755
|
backgroundColor: t.palette.background.paper,
|
|
@@ -2652,46 +2759,47 @@ const jn = p(v)(({ theme: t }) => ({
|
|
|
2652
2759
|
marginTop: t.spacing(1)
|
|
2653
2760
|
}
|
|
2654
2761
|
}));
|
|
2655
|
-
function
|
|
2762
|
+
function _o({
|
|
2656
2763
|
children: t,
|
|
2657
2764
|
onClickAway: e,
|
|
2658
2765
|
actions: n,
|
|
2659
2766
|
severity: o = "warning",
|
|
2660
|
-
opened:
|
|
2661
|
-
"data-testid":
|
|
2767
|
+
opened: a,
|
|
2768
|
+
"data-testid": r,
|
|
2662
2769
|
"aria-label": l,
|
|
2663
|
-
...
|
|
2770
|
+
...c
|
|
2664
2771
|
}) {
|
|
2665
|
-
const
|
|
2772
|
+
const s = Y(null), p = N();
|
|
2666
2773
|
return /* @__PURE__ */ i(
|
|
2667
|
-
|
|
2774
|
+
zn,
|
|
2668
2775
|
{
|
|
2669
|
-
ref:
|
|
2670
|
-
"data-testid":
|
|
2776
|
+
ref: s,
|
|
2777
|
+
"data-testid": r,
|
|
2671
2778
|
"aria-label": l,
|
|
2672
2779
|
role: "presentation",
|
|
2673
|
-
|
|
2780
|
+
"data-name": "dialog-confirmation",
|
|
2781
|
+
children: /* @__PURE__ */ i(xe, { onClickAway: () => {
|
|
2674
2782
|
e && e();
|
|
2675
2783
|
}, children: /* @__PURE__ */ i(
|
|
2676
|
-
|
|
2784
|
+
xt,
|
|
2677
2785
|
{
|
|
2678
2786
|
direction: "up",
|
|
2679
|
-
in:
|
|
2680
|
-
container:
|
|
2787
|
+
in: a,
|
|
2788
|
+
container: s.current,
|
|
2681
2789
|
mountOnEnter: !0,
|
|
2682
2790
|
unmountOnExit: !0,
|
|
2683
|
-
easing:
|
|
2791
|
+
easing: p.transitions.easing.easeOut,
|
|
2684
2792
|
timeout: 350,
|
|
2685
|
-
children: /* @__PURE__ */ i(
|
|
2686
|
-
/* @__PURE__ */ i(
|
|
2687
|
-
/* @__PURE__ */ i(
|
|
2793
|
+
children: /* @__PURE__ */ i(Zn, { children: /* @__PURE__ */ y(Jn, { children: [
|
|
2794
|
+
/* @__PURE__ */ i(Rt, { severity: o, ...c, children: t }),
|
|
2795
|
+
/* @__PURE__ */ i(Ft, { children: n })
|
|
2688
2796
|
] }) })
|
|
2689
2797
|
}
|
|
2690
2798
|
) })
|
|
2691
2799
|
}
|
|
2692
2800
|
);
|
|
2693
2801
|
}
|
|
2694
|
-
const
|
|
2802
|
+
const Xn = g(v)(({ theme: t }) => ({
|
|
2695
2803
|
display: "flex",
|
|
2696
2804
|
alignItems: "center",
|
|
2697
2805
|
justifyContent: "center",
|
|
@@ -2700,7 +2808,7 @@ const Un = p(v)(({ theme: t }) => ({
|
|
|
2700
2808
|
"& > div": {
|
|
2701
2809
|
flex: 1
|
|
2702
2810
|
}
|
|
2703
|
-
})),
|
|
2811
|
+
})), Kn = g(v)(({ theme: t }) => ({
|
|
2704
2812
|
display: "flex",
|
|
2705
2813
|
flex: 1,
|
|
2706
2814
|
flexDirection: "column",
|
|
@@ -2728,7 +2836,7 @@ const Un = p(v)(({ theme: t }) => ({
|
|
|
2728
2836
|
content: "none"
|
|
2729
2837
|
}
|
|
2730
2838
|
}));
|
|
2731
|
-
function
|
|
2839
|
+
function Qn({
|
|
2732
2840
|
theme: t,
|
|
2733
2841
|
completed: e,
|
|
2734
2842
|
current: n
|
|
@@ -2746,7 +2854,7 @@ function zn({
|
|
|
2746
2854
|
color: t.palette.text.secondary
|
|
2747
2855
|
};
|
|
2748
2856
|
}
|
|
2749
|
-
const
|
|
2857
|
+
const to = g("span", {
|
|
2750
2858
|
shouldForwardProp: (t) => t !== "completed" && t !== "current"
|
|
2751
2859
|
})(({ theme: t, completed: e, current: n }) => ({
|
|
2752
2860
|
display: "flex",
|
|
@@ -2758,66 +2866,66 @@ const Yn = p("span", {
|
|
|
2758
2866
|
borderRadius: "50%",
|
|
2759
2867
|
border: `${t.spacing(0.25)} solid currentColor`,
|
|
2760
2868
|
...t.typography.caption,
|
|
2761
|
-
...
|
|
2869
|
+
...Qn({ theme: t, completed: e, current: n })
|
|
2762
2870
|
}));
|
|
2763
|
-
function
|
|
2871
|
+
function Po({
|
|
2764
2872
|
currentStep: t,
|
|
2765
2873
|
stepsLabels: e,
|
|
2766
2874
|
...n
|
|
2767
2875
|
}) {
|
|
2768
|
-
return /* @__PURE__ */ i(
|
|
2769
|
-
const
|
|
2876
|
+
return /* @__PURE__ */ i(Xn, { ...n, "data-name": "dialog-stepper", children: /* @__PURE__ */ i(v, { sx: { display: "flex" }, children: e.map((o, a) => {
|
|
2877
|
+
const r = a + 1, l = r === t, c = r < t;
|
|
2770
2878
|
return /* @__PURE__ */ y(
|
|
2771
|
-
|
|
2879
|
+
Kn,
|
|
2772
2880
|
{
|
|
2773
|
-
"data-state":
|
|
2881
|
+
"data-state": c ? "completed" : l ? "current" : "uncompleted",
|
|
2774
2882
|
children: [
|
|
2775
|
-
/* @__PURE__ */ i(
|
|
2776
|
-
/* @__PURE__ */ i(
|
|
2883
|
+
/* @__PURE__ */ i(to, { completed: c, current: l, children: c ? /* @__PURE__ */ i(ge, { fontSize: "small", "aria-label": "Completed step" }) : r }),
|
|
2884
|
+
/* @__PURE__ */ i(S, { variant: "caption", component: "div", color: c ? "success.main" : l ? "textPrimary" : "textSecondary", children: o })
|
|
2777
2885
|
]
|
|
2778
2886
|
},
|
|
2779
|
-
|
|
2887
|
+
a
|
|
2780
2888
|
);
|
|
2781
2889
|
}) }) });
|
|
2782
2890
|
}
|
|
2783
2891
|
export {
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
vt as
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2892
|
+
wo as AccordionGroup,
|
|
2893
|
+
Ct as Alert,
|
|
2894
|
+
To as AppBar,
|
|
2895
|
+
Do as Autocomplete,
|
|
2896
|
+
Bo as Avatar,
|
|
2897
|
+
bo as Button,
|
|
2898
|
+
Ao as CreatableAutocomplete,
|
|
2899
|
+
at as DatePicker,
|
|
2900
|
+
$o as DateRangePicker,
|
|
2901
|
+
Fo as DateTimePicker,
|
|
2902
|
+
Lo as Dialog,
|
|
2903
|
+
Ft as DialogActions,
|
|
2904
|
+
Rt as DialogAlert,
|
|
2905
|
+
_o as DialogConfirmation,
|
|
2906
|
+
jn as DialogContent,
|
|
2907
|
+
Eo as DialogContentPadded,
|
|
2908
|
+
Ho as DialogFooter,
|
|
2909
|
+
Wo as DialogHeader,
|
|
2910
|
+
dt as DialogPaper,
|
|
2911
|
+
Po as DialogStepper,
|
|
2912
|
+
Le as IconButton,
|
|
2913
|
+
K as LabelWithIndicator,
|
|
2914
|
+
Mo as Menu,
|
|
2915
|
+
vt as MenuItem,
|
|
2916
|
+
kt as MenuItemFilter,
|
|
2917
|
+
Co as MenuList,
|
|
2918
|
+
Io as MultipleAutocomplete,
|
|
2919
|
+
vo as MultipleSelectField,
|
|
2920
|
+
xo as PasswordField,
|
|
2921
|
+
Te as SelectField,
|
|
2922
|
+
So as Snackbar,
|
|
2923
|
+
Vo as TablePaginationActions,
|
|
2924
|
+
Ro as TimePicker,
|
|
2925
|
+
yo as ToggleButtonGroup,
|
|
2926
|
+
Oo as TooltipData,
|
|
2927
|
+
S as Typography,
|
|
2928
|
+
ko as UploadField,
|
|
2929
|
+
Xe as UploadFieldBase,
|
|
2930
|
+
st as dialogDimensionsBySize
|
|
2823
2931
|
};
|