wcz-layout 10.2.2 → 11.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ChatLayout-CkS9oyPp.mjs → ChatLayout-B0MBrI-Y.mjs} +839 -371
- package/dist/ChatLayout-B0MBrI-Y.mjs.map +1 -0
- package/dist/{ExtractFile-ClTc-e1H.d.mts → ExtractFile-BQUXpuBS.d.mts} +27 -3
- package/dist/FileMeta-B5VU-eCi.d.mts +55 -0
- package/dist/FileMeta-BexXC_45.mjs +35 -0
- package/dist/FileMeta-BexXC_45.mjs.map +1 -0
- package/dist/QueryClientParam-BG9Q_9XU.d.mts +6 -0
- package/dist/{Translate-BiCjnlyx.mjs → Translate-C43AmXYW.mjs} +25 -37
- package/dist/Translate-C43AmXYW.mjs.map +1 -0
- package/dist/User-CvLutatT.d.mts +10 -0
- package/dist/ai.d.mts +1 -1
- package/dist/ai.mjs +2 -2
- package/dist/ai.mjs.map +1 -1
- package/dist/auth.d.mts +6 -14
- package/dist/auth.mjs +15 -38
- package/dist/auth.mjs.map +1 -1
- package/dist/{authMiddleware-D4GSt7m9.mjs → authMiddleware-ANa9Tlmp.mjs} +10 -15
- package/dist/authMiddleware-ANa9Tlmp.mjs.map +1 -0
- package/dist/{ChatLayout-BmLySLXy.d.mts → components-2HKj8GpC.d.mts} +219 -255
- package/dist/components.d.mts +2 -126
- package/dist/components.mjs +871 -919
- package/dist/components.mjs.map +1 -1
- package/dist/data/client.d.mts +299 -57
- package/dist/data/client.mjs +5 -6
- package/dist/data/client.mjs.map +1 -1
- package/dist/data/server.d.mts +6 -5
- package/dist/data/server.mjs +3 -5
- package/dist/data/server.mjs.map +1 -1
- package/dist/env-C4WLVJMm.mjs +32 -0
- package/dist/env-C4WLVJMm.mjs.map +1 -0
- package/dist/file-DBqTibcr.mjs +176 -0
- package/dist/file-DBqTibcr.mjs.map +1 -0
- package/dist/file-hecCQszp.mjs +114 -0
- package/dist/file-hecCQszp.mjs.map +1 -0
- package/dist/hooks.d.mts +11 -91
- package/dist/hooks.mjs +152 -960
- package/dist/hooks.mjs.map +1 -1
- package/dist/i18n-ZRiIIdpb.mjs +563 -0
- package/dist/i18n-ZRiIIdpb.mjs.map +1 -0
- package/dist/index.d.mts +3 -35
- package/dist/index.mjs +409 -510
- package/dist/index.mjs.map +1 -1
- package/dist/layout-DeTB6Ai1.mjs +224 -0
- package/dist/layout-DeTB6Ai1.mjs.map +1 -0
- package/dist/middleware.d.mts +1 -1
- package/dist/middleware.mjs +2 -2
- package/dist/models.d.mts +34 -42
- package/dist/models.mjs +4 -6
- package/dist/models.mjs.map +1 -1
- package/dist/oidc--D2ox365.mjs +97 -0
- package/dist/oidc--D2ox365.mjs.map +1 -0
- package/dist/peoplesoft-DhwB8jrM.d.mts +204 -0
- package/dist/tokens-C4djIAhl.mjs +97 -0
- package/dist/tokens-C4djIAhl.mjs.map +1 -0
- package/dist/useDialogs-QER-2rVG.mjs +297 -0
- package/dist/useDialogs-QER-2rVG.mjs.map +1 -0
- package/dist/{user-Bc2nLjAG.mjs → user-DQx1BanQ.mjs} +4 -20
- package/dist/user-DQx1BanQ.mjs.map +1 -0
- package/dist/{utils-CNYCSgip.d.mts → utils-BnyAEKW7.d.mts} +7 -9
- package/dist/{utils-CgabUlDD.mjs → utils-H4BskGF8.mjs} +21 -20
- package/dist/utils-H4BskGF8.mjs.map +1 -0
- package/dist/utils.d.mts +21 -4
- package/dist/utils.mjs +5 -4
- package/dist/vite.mjs +98 -32
- package/dist/vite.mjs.map +1 -1
- package/package.json +16 -43
- package/skills/ai/SKILL.md +1 -4
- package/skills/general/SKILL.md +15 -8
- package/skills/general/references/auth.md +10 -16
- package/skills/general/references/languages.md +56 -0
- package/skills/migrations/versions/migrate-v10-to-v11.md +98 -22
- package/skills/migrations/versions/migrate-v9-to-v10.md +22 -22
- package/skills/services/SKILL.md +1 -1
- package/skills/services/docs/email.md +2 -2
- package/skills/services/docs/file.md +100 -85
- package/skills/services/docs/layout.md +2 -3
- package/skills/start/steps/02-project-name-setup.md +1 -1
- package/skills/start/steps/06-entra-setup.md +1 -1
- package/skills/start/steps/08-generate-favicon.md +1 -1
- package/skills/table/SKILL.md +18 -5
- package/src/lib/locales/cs.json +120 -0
- package/src/lib/locales/en.json +119 -0
- package/src/lib/locales/uk.json +121 -0
- package/src/lib/locales/zh-TW.json +118 -0
- package/dist/ChatLayout-CkS9oyPp.mjs.map +0 -1
- package/dist/DialogsContext-D23fJjYR.mjs +0 -6
- package/dist/DialogsContext-D23fJjYR.mjs.map +0 -1
- package/dist/FileMeta-B39e2FLC.d.mts +0 -17
- package/dist/FileMeta-CPBWI_jA.mjs +0 -18
- package/dist/FileMeta-CPBWI_jA.mjs.map +0 -1
- package/dist/QueryClientParam-CTV1vj76.d.mts +0 -8
- package/dist/RouterListItemButton-CF-8w-08.mjs +0 -62
- package/dist/RouterListItemButton-CF-8w-08.mjs.map +0 -1
- package/dist/Translate-BiCjnlyx.mjs.map +0 -1
- package/dist/User-aJksXItw.d.mts +0 -12
- package/dist/authMiddleware-D4GSt7m9.mjs.map +0 -1
- package/dist/createApi-CF4ZL82B.mjs +0 -24
- package/dist/createApi-CF4ZL82B.mjs.map +0 -1
- package/dist/env-Cddts_dn.mjs +0 -49
- package/dist/env-Cddts_dn.mjs.map +0 -1
- package/dist/file-D4kSR_lC.mjs +0 -149
- package/dist/file-D4kSR_lC.mjs.map +0 -1
- package/dist/file-DcwYjofa.mjs +0 -150
- package/dist/file-DcwYjofa.mjs.map +0 -1
- package/dist/layout-6We_KFgN.mjs +0 -107
- package/dist/layout-6We_KFgN.mjs.map +0 -1
- package/dist/peoplesoft-DH31FCMC.mjs +0 -125
- package/dist/peoplesoft-DH31FCMC.mjs.map +0 -1
- package/dist/peoplesoft-DXukeeFr.d.mts +0 -161
- package/dist/providers-DOFje2P6.mjs +0 -56
- package/dist/providers-DOFje2P6.mjs.map +0 -1
- package/dist/tokens-DNe_Qifk.mjs +0 -204
- package/dist/tokens-DNe_Qifk.mjs.map +0 -1
- package/dist/user-Bc2nLjAG.mjs.map +0 -1
- package/dist/utils-CgabUlDD.mjs.map +0 -1
|
@@ -1,386 +1,790 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { o as getFieldStatus } from "./utils-H4BskGF8.mjs";
|
|
2
|
+
import { n as useDialogs, r as useTranslation$1, s as RouterLink } from "./useDialogs-QER-2rVG.mjs";
|
|
2
3
|
import { c } from "react/compiler-runtime";
|
|
3
|
-
import { Accordion, AccordionActions, AccordionDetails, AccordionSummary, Alert, AlertTitle, Avatar, AvatarGroup, Badge, Box, Breadcrumbs, Button, ButtonGroup, Card, CardActions, CardContent, CardHeader, CardMedia, Checkbox, Chip, CircularProgress,
|
|
4
|
-
import
|
|
5
|
-
import
|
|
4
|
+
import { Accordion, AccordionActions, AccordionDetails, AccordionSummary, Alert, AlertTitle, Autocomplete, Avatar, AvatarGroup, Badge, Box, Breadcrumbs, Button, ButtonGroup, Card, CardActions, CardContent, CardHeader, CardMedia, Checkbox, Chip, CircularProgress, Divider, FormControl, FormControlLabel, FormGroup, FormHelperText, FormLabel, Grid, IconButton, ImageList, ImageListItem, ImageListItemBar, InputBase, InputLabel, LinearProgress, Link, List, ListItem, ListItemAvatar, ListItemText, ListSubheader, MenuItem, Paper, Radio, RadioGroup, Rating, Select, Skeleton, Slider, Stack, Step, StepContent, StepLabel, Stepper, Switch, Table, TableBody, TableCell, TableContainer, TableFooter, TableHead, TableRow, TextField, Tooltip, Typography } from "@mui/material";
|
|
5
|
+
import { DatePicker, DateTimePicker, TimePicker } from "@mui/x-date-pickers";
|
|
6
|
+
import { Suspense, createContext, lazy, useContext, useEffect, useId, useRef, useState } from "react";
|
|
6
7
|
import { useTranslation } from "react-i18next";
|
|
7
|
-
import { z as z$1 } from "zod";
|
|
8
8
|
import { keyframes } from "@mui/material/styles";
|
|
9
|
-
import { CatchBoundary
|
|
9
|
+
import { CatchBoundary } from "@tanstack/react-router";
|
|
10
10
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
|
+
import { z as z$1 } from "zod";
|
|
12
|
+
import dayjs from "dayjs";
|
|
11
13
|
import { useDropzone } from "react-dropzone";
|
|
12
14
|
import AttachFile from "@mui/icons-material/AttachFile";
|
|
13
15
|
import { formatForDisplay } from "@tanstack/react-hotkeys";
|
|
14
16
|
import { defaultRangeExtractor } from "@tanstack/react-virtual";
|
|
15
|
-
import {
|
|
17
|
+
import { createFormHook, createFormHookContexts } from "@tanstack/react-form";
|
|
18
|
+
import { NumericFormat } from "react-number-format";
|
|
19
|
+
import { aggregationFn_count, aggregationFn_extent, aggregationFn_first, aggregationFn_last, aggregationFn_max, aggregationFn_mean, aggregationFn_median, aggregationFn_min, aggregationFn_sum, aggregationFn_unique, aggregationFn_uniqueCount, createExpandedRowModel, createFacetedMinMaxValues, createFacetedRowModel, createFacetedUniqueValues, createFilteredRowModel, createGroupedRowModel, createPaginatedRowModel, createSortedRowModel, createTableHookContexts, metaHelper, sortFn_alphanumeric, sortFn_alphanumericCaseSensitive, sortFn_basic, sortFn_datetime, sortFn_text, sortFn_textCaseSensitive, stockFeatures, tableFeatures } from "@tanstack/react-table";
|
|
16
20
|
import Add from "@mui/icons-material/Add";
|
|
17
21
|
import ArrowUpward from "@mui/icons-material/ArrowUpward";
|
|
18
22
|
import Refresh from "@mui/icons-material/Refresh";
|
|
19
23
|
import Stop from "@mui/icons-material/Stop";
|
|
20
|
-
import { visuallyHidden } from "@mui/utils";
|
|
21
24
|
import { parsePartialJSON } from "@tanstack/ai-react";
|
|
22
25
|
import { streamingMarkdownExtension } from "@tanstack/markdown/extensions/streaming";
|
|
23
26
|
import { Markdown } from "@tanstack/markdown/react";
|
|
24
27
|
import { toolDefinition } from "@tanstack/ai/client";
|
|
25
|
-
// src/
|
|
26
|
-
|
|
27
|
-
const $ = c(
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
// src/components/form/FormAutocomplete.tsx
|
|
29
|
+
const FormAutocomplete = (t0) => {
|
|
30
|
+
const $ = c(21);
|
|
31
|
+
let autocompleteProps;
|
|
32
|
+
let textFieldProps;
|
|
33
|
+
if ($[0] !== t0) {
|
|
34
|
+
({textFieldProps, ...autocompleteProps} = t0);
|
|
35
|
+
$[0] = t0;
|
|
36
|
+
$[1] = autocompleteProps;
|
|
37
|
+
$[2] = textFieldProps;
|
|
38
|
+
} else {
|
|
39
|
+
autocompleteProps = $[1];
|
|
40
|
+
textFieldProps = $[2];
|
|
41
|
+
}
|
|
42
|
+
const field = useFieldContext();
|
|
31
43
|
let t1;
|
|
32
|
-
if ($[
|
|
33
|
-
t1 = ()
|
|
34
|
-
$[
|
|
35
|
-
$[
|
|
36
|
-
} else t1 = $[
|
|
44
|
+
if ($[3] !== field) {
|
|
45
|
+
t1 = getFieldStatus(field);
|
|
46
|
+
$[3] = field;
|
|
47
|
+
$[4] = t1;
|
|
48
|
+
} else t1 = $[4];
|
|
49
|
+
const { error, helperText } = t1;
|
|
37
50
|
let t2;
|
|
38
|
-
if ($[2] !== payload.title || $[3] !== t) {
|
|
39
|
-
t2 = payload.title ?? t("Layout.Dialog.Alert");
|
|
40
|
-
$[2] = payload.title;
|
|
41
|
-
$[3] = t;
|
|
42
|
-
$[4] = t2;
|
|
43
|
-
} else t2 = $[4];
|
|
44
51
|
let t3;
|
|
45
|
-
if ($[5] !==
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
$[
|
|
49
|
-
|
|
52
|
+
if ($[5] !== autocompleteProps.freeSolo || $[6] !== field) {
|
|
53
|
+
t2 = (_, value) => !autocompleteProps.freeSolo && field.handleChange(value);
|
|
54
|
+
t3 = (__0, value_0, reason) => reason !== "reset" && autocompleteProps.freeSolo && field.handleChange(value_0);
|
|
55
|
+
$[5] = autocompleteProps.freeSolo;
|
|
56
|
+
$[6] = field;
|
|
57
|
+
$[7] = t2;
|
|
58
|
+
$[8] = t3;
|
|
59
|
+
} else {
|
|
60
|
+
t2 = $[7];
|
|
61
|
+
t3 = $[8];
|
|
62
|
+
}
|
|
50
63
|
let t4;
|
|
51
|
-
if ($[
|
|
52
|
-
t4 = /* @__PURE__ */ jsx(
|
|
53
|
-
|
|
54
|
-
|
|
64
|
+
if ($[9] !== error || $[10] !== field.name || $[11] !== helperText || $[12] !== textFieldProps) {
|
|
65
|
+
t4 = (parameters) => /* @__PURE__ */ jsx(TextField, {
|
|
66
|
+
...parameters,
|
|
67
|
+
name: field.name,
|
|
68
|
+
error,
|
|
69
|
+
helperText,
|
|
70
|
+
...textFieldProps
|
|
55
71
|
});
|
|
56
|
-
$[
|
|
57
|
-
$[
|
|
58
|
-
$[
|
|
59
|
-
|
|
72
|
+
$[9] = error;
|
|
73
|
+
$[10] = field.name;
|
|
74
|
+
$[11] = helperText;
|
|
75
|
+
$[12] = textFieldProps;
|
|
76
|
+
$[13] = t4;
|
|
77
|
+
} else t4 = $[13];
|
|
60
78
|
let t5;
|
|
61
|
-
if ($[
|
|
62
|
-
t5 =
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
$[
|
|
71
|
-
|
|
79
|
+
if ($[14] !== autocompleteProps || $[15] !== field.handleBlur || $[16] !== field.state.value || $[17] !== t2 || $[18] !== t3 || $[19] !== t4) {
|
|
80
|
+
t5 = /* @__PURE__ */ jsx(Autocomplete, {
|
|
81
|
+
value: field.state.value,
|
|
82
|
+
onChange: t2,
|
|
83
|
+
onInputChange: t3,
|
|
84
|
+
onBlur: field.handleBlur,
|
|
85
|
+
...autocompleteProps,
|
|
86
|
+
renderInput: t4
|
|
87
|
+
});
|
|
88
|
+
$[14] = autocompleteProps;
|
|
89
|
+
$[15] = field.handleBlur;
|
|
90
|
+
$[16] = field.state.value;
|
|
91
|
+
$[17] = t2;
|
|
92
|
+
$[18] = t3;
|
|
93
|
+
$[19] = t4;
|
|
94
|
+
$[20] = t5;
|
|
95
|
+
} else t5 = $[20];
|
|
96
|
+
return t5;
|
|
97
|
+
};
|
|
98
|
+
// src/components/form/FormCheckbox.tsx
|
|
99
|
+
const FormCheckbox = (t0) => {
|
|
100
|
+
const $ = c(28);
|
|
101
|
+
let label;
|
|
102
|
+
let props;
|
|
103
|
+
if ($[0] !== t0) {
|
|
104
|
+
({label, ...props} = t0);
|
|
105
|
+
$[0] = t0;
|
|
106
|
+
$[1] = label;
|
|
107
|
+
$[2] = props;
|
|
108
|
+
} else {
|
|
109
|
+
label = $[1];
|
|
110
|
+
props = $[2];
|
|
111
|
+
}
|
|
112
|
+
const field = useFieldContext();
|
|
113
|
+
let t1;
|
|
114
|
+
if ($[3] !== field) {
|
|
115
|
+
t1 = getFieldStatus(field);
|
|
116
|
+
$[3] = field;
|
|
117
|
+
$[4] = t1;
|
|
118
|
+
} else t1 = $[4];
|
|
119
|
+
const { error, helperText } = t1;
|
|
120
|
+
const helperId = useId();
|
|
121
|
+
const t2 = field.name;
|
|
122
|
+
const t3 = Boolean(field.state.value);
|
|
123
|
+
let t4;
|
|
124
|
+
if ($[5] !== field) {
|
|
125
|
+
t4 = (event) => field.handleChange(event.target.checked);
|
|
126
|
+
$[5] = field;
|
|
127
|
+
$[6] = t4;
|
|
128
|
+
} else t4 = $[6];
|
|
129
|
+
const t5 = error || void 0;
|
|
130
|
+
const t6 = error ? helperId : void 0;
|
|
72
131
|
let t7;
|
|
73
|
-
if ($[
|
|
74
|
-
t7 =
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
$[
|
|
80
|
-
$[
|
|
81
|
-
|
|
82
|
-
} else t7 = $[16];
|
|
132
|
+
if ($[7] !== t5 || $[8] !== t6) {
|
|
133
|
+
t7 = { input: {
|
|
134
|
+
"aria-invalid": t5,
|
|
135
|
+
"aria-describedby": t6
|
|
136
|
+
} };
|
|
137
|
+
$[7] = t5;
|
|
138
|
+
$[8] = t6;
|
|
139
|
+
$[9] = t7;
|
|
140
|
+
} else t7 = $[9];
|
|
83
141
|
let t8;
|
|
84
|
-
if ($[
|
|
85
|
-
t8 = /* @__PURE__ */
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
children: [
|
|
93
|
-
t3,
|
|
94
|
-
t4,
|
|
95
|
-
t7
|
|
96
|
-
]
|
|
142
|
+
if ($[10] !== field.handleBlur || $[11] !== field.name || $[12] !== props || $[13] !== t3 || $[14] !== t4 || $[15] !== t7) {
|
|
143
|
+
t8 = /* @__PURE__ */ jsx(Checkbox, {
|
|
144
|
+
name: t2,
|
|
145
|
+
checked: t3,
|
|
146
|
+
onChange: t4,
|
|
147
|
+
onBlur: field.handleBlur,
|
|
148
|
+
slotProps: t7,
|
|
149
|
+
...props
|
|
97
150
|
});
|
|
98
|
-
$[
|
|
99
|
-
$[
|
|
100
|
-
$[
|
|
101
|
-
$[
|
|
102
|
-
$[
|
|
103
|
-
$[
|
|
104
|
-
$[
|
|
105
|
-
} else t8 = $[
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
151
|
+
$[10] = field.handleBlur;
|
|
152
|
+
$[11] = field.name;
|
|
153
|
+
$[12] = props;
|
|
154
|
+
$[13] = t3;
|
|
155
|
+
$[14] = t4;
|
|
156
|
+
$[15] = t7;
|
|
157
|
+
$[16] = t8;
|
|
158
|
+
} else t8 = $[16];
|
|
159
|
+
const t9 = label ?? "";
|
|
160
|
+
let t10;
|
|
161
|
+
if ($[17] !== t8 || $[18] !== t9) {
|
|
162
|
+
t10 = /* @__PURE__ */ jsx(FormControlLabel, {
|
|
163
|
+
control: t8,
|
|
164
|
+
label: t9
|
|
165
|
+
});
|
|
166
|
+
$[17] = t8;
|
|
167
|
+
$[18] = t9;
|
|
168
|
+
$[19] = t10;
|
|
169
|
+
} else t10 = $[19];
|
|
170
|
+
let t11;
|
|
171
|
+
if ($[20] !== error || $[21] !== helperId || $[22] !== helperText) {
|
|
172
|
+
t11 = error && /* @__PURE__ */ jsx(FormHelperText, {
|
|
173
|
+
id: helperId,
|
|
174
|
+
children: helperText
|
|
175
|
+
});
|
|
176
|
+
$[20] = error;
|
|
177
|
+
$[21] = helperId;
|
|
178
|
+
$[22] = helperText;
|
|
179
|
+
$[23] = t11;
|
|
180
|
+
} else t11 = $[23];
|
|
181
|
+
let t12;
|
|
182
|
+
if ($[24] !== error || $[25] !== t10 || $[26] !== t11) {
|
|
183
|
+
t12 = /* @__PURE__ */ jsxs(FormControl, {
|
|
184
|
+
error,
|
|
185
|
+
children: [t10, t11]
|
|
186
|
+
});
|
|
187
|
+
$[24] = error;
|
|
188
|
+
$[25] = t10;
|
|
189
|
+
$[26] = t11;
|
|
190
|
+
$[27] = t12;
|
|
191
|
+
} else t12 = $[27];
|
|
192
|
+
return t12;
|
|
193
|
+
};
|
|
194
|
+
// src/components/form/FormPickers.tsx
|
|
195
|
+
/** `Picker` bound to the form field. The app's slotProps are kept; its text field props win. */
|
|
196
|
+
function PickerField(t0) {
|
|
197
|
+
const $ = c(25);
|
|
198
|
+
let Picker;
|
|
199
|
+
let props;
|
|
200
|
+
let slotProps;
|
|
201
|
+
let textFieldProps;
|
|
202
|
+
if ($[0] !== t0) {
|
|
203
|
+
({Picker, textFieldProps, slotProps, ...props} = t0);
|
|
204
|
+
$[0] = t0;
|
|
205
|
+
$[1] = Picker;
|
|
206
|
+
$[2] = props;
|
|
207
|
+
$[3] = slotProps;
|
|
208
|
+
$[4] = textFieldProps;
|
|
209
|
+
} else {
|
|
210
|
+
Picker = $[1];
|
|
211
|
+
props = $[2];
|
|
212
|
+
slotProps = $[3];
|
|
213
|
+
textFieldProps = $[4];
|
|
214
|
+
}
|
|
215
|
+
const field = useFieldContext();
|
|
113
216
|
let t1;
|
|
114
|
-
if ($[
|
|
115
|
-
t1 = ()
|
|
116
|
-
$[
|
|
117
|
-
$[
|
|
118
|
-
} else t1 = $[
|
|
217
|
+
if ($[5] !== field) {
|
|
218
|
+
t1 = getFieldStatus(field);
|
|
219
|
+
$[5] = field;
|
|
220
|
+
$[6] = t1;
|
|
221
|
+
} else t1 = $[6];
|
|
222
|
+
const { error, helperText } = t1;
|
|
119
223
|
let t2;
|
|
120
|
-
if ($[
|
|
121
|
-
t2 =
|
|
122
|
-
$[
|
|
123
|
-
$[
|
|
124
|
-
|
|
125
|
-
|
|
224
|
+
if ($[7] !== field) {
|
|
225
|
+
t2 = (value) => field.handleChange(value);
|
|
226
|
+
$[7] = field;
|
|
227
|
+
$[8] = t2;
|
|
228
|
+
} else t2 = $[8];
|
|
229
|
+
const t3 = slotProps?.textField;
|
|
230
|
+
let t4;
|
|
231
|
+
if ($[9] !== error || $[10] !== field.handleBlur || $[11] !== helperText || $[12] !== t3 || $[13] !== textFieldProps) {
|
|
232
|
+
t4 = {
|
|
233
|
+
...t3,
|
|
234
|
+
onBlur: field.handleBlur,
|
|
235
|
+
error,
|
|
236
|
+
helperText,
|
|
237
|
+
...textFieldProps
|
|
238
|
+
};
|
|
239
|
+
$[9] = error;
|
|
240
|
+
$[10] = field.handleBlur;
|
|
241
|
+
$[11] = helperText;
|
|
242
|
+
$[12] = t3;
|
|
243
|
+
$[13] = textFieldProps;
|
|
244
|
+
$[14] = t4;
|
|
245
|
+
} else t4 = $[14];
|
|
246
|
+
let t5;
|
|
247
|
+
if ($[15] !== slotProps || $[16] !== t4) {
|
|
248
|
+
t5 = {
|
|
249
|
+
...slotProps,
|
|
250
|
+
textField: t4
|
|
251
|
+
};
|
|
252
|
+
$[15] = slotProps;
|
|
253
|
+
$[16] = t4;
|
|
254
|
+
$[17] = t5;
|
|
255
|
+
} else t5 = $[17];
|
|
256
|
+
let t6;
|
|
257
|
+
if ($[18] !== Picker || $[19] !== field.name || $[20] !== field.state.value || $[21] !== props || $[22] !== t2 || $[23] !== t5) {
|
|
258
|
+
t6 = /* @__PURE__ */ jsx(Picker, {
|
|
259
|
+
...props,
|
|
260
|
+
name: field.name,
|
|
261
|
+
value: field.state.value,
|
|
262
|
+
onChange: t2,
|
|
263
|
+
slotProps: t5
|
|
264
|
+
});
|
|
265
|
+
$[18] = Picker;
|
|
266
|
+
$[19] = field.name;
|
|
267
|
+
$[20] = field.state.value;
|
|
268
|
+
$[21] = props;
|
|
269
|
+
$[22] = t2;
|
|
270
|
+
$[23] = t5;
|
|
271
|
+
$[24] = t6;
|
|
272
|
+
} else t6 = $[24];
|
|
273
|
+
return t6;
|
|
274
|
+
}
|
|
275
|
+
const FormDatePicker = (props) => {
|
|
276
|
+
const $ = c(2);
|
|
277
|
+
let t0;
|
|
278
|
+
if ($[0] !== props) {
|
|
279
|
+
t0 = /* @__PURE__ */ jsx(PickerField, {
|
|
280
|
+
Picker: DatePicker,
|
|
281
|
+
...props
|
|
282
|
+
});
|
|
283
|
+
$[0] = props;
|
|
284
|
+
$[1] = t0;
|
|
285
|
+
} else t0 = $[1];
|
|
286
|
+
return t0;
|
|
287
|
+
};
|
|
288
|
+
const FormTimePicker = (props) => {
|
|
289
|
+
const $ = c(2);
|
|
290
|
+
let t0;
|
|
291
|
+
if ($[0] !== props) {
|
|
292
|
+
t0 = /* @__PURE__ */ jsx(PickerField, {
|
|
293
|
+
Picker: TimePicker,
|
|
294
|
+
...props
|
|
295
|
+
});
|
|
296
|
+
$[0] = props;
|
|
297
|
+
$[1] = t0;
|
|
298
|
+
} else t0 = $[1];
|
|
299
|
+
return t0;
|
|
300
|
+
};
|
|
301
|
+
const FormDateTimePicker = (props) => {
|
|
302
|
+
const $ = c(2);
|
|
303
|
+
let t0;
|
|
304
|
+
if ($[0] !== props) {
|
|
305
|
+
t0 = /* @__PURE__ */ jsx(PickerField, {
|
|
306
|
+
Picker: DateTimePicker,
|
|
307
|
+
...props
|
|
308
|
+
});
|
|
309
|
+
$[0] = props;
|
|
310
|
+
$[1] = t0;
|
|
311
|
+
} else t0 = $[1];
|
|
312
|
+
return t0;
|
|
313
|
+
};
|
|
314
|
+
// src/components/form/FormNumberField.tsx
|
|
315
|
+
const FormNumberField = (t0) => {
|
|
316
|
+
const $ = c(16);
|
|
317
|
+
let options;
|
|
318
|
+
let props;
|
|
319
|
+
if ($[0] !== t0) {
|
|
320
|
+
({options, ...props} = t0);
|
|
321
|
+
$[0] = t0;
|
|
322
|
+
$[1] = options;
|
|
323
|
+
$[2] = props;
|
|
324
|
+
} else {
|
|
325
|
+
options = $[1];
|
|
326
|
+
props = $[2];
|
|
327
|
+
}
|
|
328
|
+
const field = useFieldContext();
|
|
329
|
+
let t1;
|
|
330
|
+
if ($[3] !== field) {
|
|
331
|
+
t1 = getFieldStatus(field);
|
|
332
|
+
$[3] = field;
|
|
333
|
+
$[4] = t1;
|
|
334
|
+
} else t1 = $[4];
|
|
335
|
+
const { error, helperText } = t1;
|
|
336
|
+
const t2 = field.state.value ?? "";
|
|
126
337
|
let t3;
|
|
127
|
-
if ($[5] !==
|
|
128
|
-
t3 =
|
|
129
|
-
|
|
338
|
+
if ($[5] !== field) {
|
|
339
|
+
t3 = (t4) => {
|
|
340
|
+
const { floatValue } = t4;
|
|
341
|
+
return field.handleChange(floatValue);
|
|
342
|
+
};
|
|
343
|
+
$[5] = field;
|
|
130
344
|
$[6] = t3;
|
|
131
345
|
} else t3 = $[6];
|
|
132
346
|
let t4;
|
|
133
|
-
if ($[7] !==
|
|
134
|
-
t4 = /* @__PURE__ */ jsx(
|
|
135
|
-
|
|
136
|
-
|
|
347
|
+
if ($[7] !== error || $[8] !== field.handleBlur || $[9] !== field.name || $[10] !== helperText || $[11] !== options || $[12] !== props || $[13] !== t2 || $[14] !== t3) {
|
|
348
|
+
t4 = /* @__PURE__ */ jsx(NumericFormat, {
|
|
349
|
+
customInput: TextField,
|
|
350
|
+
name: field.name,
|
|
351
|
+
value: t2,
|
|
352
|
+
onValueChange: t3,
|
|
353
|
+
onBlur: field.handleBlur,
|
|
354
|
+
error,
|
|
355
|
+
helperText,
|
|
356
|
+
...props,
|
|
357
|
+
...options
|
|
137
358
|
});
|
|
138
|
-
$[7] =
|
|
139
|
-
$[8] =
|
|
140
|
-
$[9] =
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
$[
|
|
146
|
-
$[
|
|
147
|
-
} else
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
let
|
|
156
|
-
if ($[
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
359
|
+
$[7] = error;
|
|
360
|
+
$[8] = field.handleBlur;
|
|
361
|
+
$[9] = field.name;
|
|
362
|
+
$[10] = helperText;
|
|
363
|
+
$[11] = options;
|
|
364
|
+
$[12] = props;
|
|
365
|
+
$[13] = t2;
|
|
366
|
+
$[14] = t3;
|
|
367
|
+
$[15] = t4;
|
|
368
|
+
} else t4 = $[15];
|
|
369
|
+
return t4;
|
|
370
|
+
};
|
|
371
|
+
// src/components/form/FormRadioGroup.tsx
|
|
372
|
+
const FormRadioGroup = (t0) => {
|
|
373
|
+
const $ = c(30);
|
|
374
|
+
let label;
|
|
375
|
+
let options;
|
|
376
|
+
let props;
|
|
377
|
+
if ($[0] !== t0) {
|
|
378
|
+
({label, options, ...props} = t0);
|
|
379
|
+
$[0] = t0;
|
|
380
|
+
$[1] = label;
|
|
381
|
+
$[2] = options;
|
|
382
|
+
$[3] = props;
|
|
383
|
+
} else {
|
|
384
|
+
label = $[1];
|
|
385
|
+
options = $[2];
|
|
386
|
+
props = $[3];
|
|
387
|
+
}
|
|
388
|
+
const field = useFieldContext();
|
|
389
|
+
let t1;
|
|
390
|
+
if ($[4] !== field) {
|
|
391
|
+
t1 = getFieldStatus(field);
|
|
392
|
+
$[4] = field;
|
|
393
|
+
$[5] = t1;
|
|
394
|
+
} else t1 = $[5];
|
|
395
|
+
const { error, helperText } = t1;
|
|
396
|
+
const helperId = useId();
|
|
397
|
+
let t2;
|
|
398
|
+
if ($[6] !== label) {
|
|
399
|
+
t2 = label && /* @__PURE__ */ jsx(FormLabel, {
|
|
400
|
+
component: "legend",
|
|
401
|
+
children: label
|
|
160
402
|
});
|
|
161
|
-
$[
|
|
162
|
-
$[
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
$[
|
|
170
|
-
|
|
403
|
+
$[6] = label;
|
|
404
|
+
$[7] = t2;
|
|
405
|
+
} else t2 = $[7];
|
|
406
|
+
const t3 = field.name;
|
|
407
|
+
const t4 = field.state.value ?? "";
|
|
408
|
+
let t5;
|
|
409
|
+
if ($[8] !== field) {
|
|
410
|
+
t5 = (event) => field.handleChange(event.target.value);
|
|
411
|
+
$[8] = field;
|
|
412
|
+
$[9] = t5;
|
|
413
|
+
} else t5 = $[9];
|
|
414
|
+
const t6 = field.handleBlur;
|
|
415
|
+
const t7 = error || void 0;
|
|
416
|
+
const t8 = error ? helperId : void 0;
|
|
171
417
|
let t9;
|
|
172
|
-
if ($[
|
|
173
|
-
t9 =
|
|
174
|
-
$[
|
|
175
|
-
$[
|
|
176
|
-
|
|
177
|
-
} else t9 = $[22];
|
|
418
|
+
if ($[10] !== options) {
|
|
419
|
+
t9 = options.map(_temp$3);
|
|
420
|
+
$[10] = options;
|
|
421
|
+
$[11] = t9;
|
|
422
|
+
} else t9 = $[11];
|
|
178
423
|
let t10;
|
|
179
|
-
if ($[
|
|
180
|
-
t10 = /* @__PURE__ */ jsx(
|
|
181
|
-
|
|
182
|
-
|
|
424
|
+
if ($[12] !== field.handleBlur || $[13] !== field.name || $[14] !== props || $[15] !== t4 || $[16] !== t5 || $[17] !== t7 || $[18] !== t8 || $[19] !== t9) {
|
|
425
|
+
t10 = /* @__PURE__ */ jsx(RadioGroup, {
|
|
426
|
+
name: t3,
|
|
427
|
+
value: t4,
|
|
428
|
+
onChange: t5,
|
|
429
|
+
onBlur: t6,
|
|
430
|
+
"aria-invalid": t7,
|
|
431
|
+
"aria-describedby": t8,
|
|
432
|
+
...props,
|
|
183
433
|
children: t9
|
|
184
434
|
});
|
|
185
|
-
$[
|
|
186
|
-
$[
|
|
187
|
-
$[
|
|
188
|
-
|
|
435
|
+
$[12] = field.handleBlur;
|
|
436
|
+
$[13] = field.name;
|
|
437
|
+
$[14] = props;
|
|
438
|
+
$[15] = t4;
|
|
439
|
+
$[16] = t5;
|
|
440
|
+
$[17] = t7;
|
|
441
|
+
$[18] = t8;
|
|
442
|
+
$[19] = t9;
|
|
443
|
+
$[20] = t10;
|
|
444
|
+
} else t10 = $[20];
|
|
189
445
|
let t11;
|
|
190
|
-
if ($[
|
|
191
|
-
t11 = /* @__PURE__ */
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
446
|
+
if ($[21] !== error || $[22] !== helperId || $[23] !== helperText) {
|
|
447
|
+
t11 = error && /* @__PURE__ */ jsx(FormHelperText, {
|
|
448
|
+
id: helperId,
|
|
449
|
+
children: helperText
|
|
450
|
+
});
|
|
451
|
+
$[21] = error;
|
|
452
|
+
$[22] = helperId;
|
|
453
|
+
$[23] = helperText;
|
|
454
|
+
$[24] = t11;
|
|
455
|
+
} else t11 = $[24];
|
|
196
456
|
let t12;
|
|
197
|
-
if ($[
|
|
198
|
-
t12 = /* @__PURE__ */ jsxs(
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
open,
|
|
202
|
-
onClose: t1,
|
|
203
|
-
role: "alertdialog",
|
|
204
|
-
"aria-describedby": messageId,
|
|
457
|
+
if ($[25] !== error || $[26] !== t10 || $[27] !== t11 || $[28] !== t2) {
|
|
458
|
+
t12 = /* @__PURE__ */ jsxs(FormControl, {
|
|
459
|
+
component: "fieldset",
|
|
460
|
+
error,
|
|
205
461
|
children: [
|
|
206
|
-
|
|
207
|
-
|
|
462
|
+
t2,
|
|
463
|
+
t10,
|
|
208
464
|
t11
|
|
209
465
|
]
|
|
210
466
|
});
|
|
211
|
-
$[
|
|
212
|
-
$[
|
|
213
|
-
$[
|
|
214
|
-
$[
|
|
215
|
-
$[
|
|
216
|
-
|
|
217
|
-
$[35] = t12;
|
|
218
|
-
} else t12 = $[35];
|
|
467
|
+
$[25] = error;
|
|
468
|
+
$[26] = t10;
|
|
469
|
+
$[27] = t11;
|
|
470
|
+
$[28] = t2;
|
|
471
|
+
$[29] = t12;
|
|
472
|
+
} else t12 = $[29];
|
|
219
473
|
return t12;
|
|
474
|
+
};
|
|
475
|
+
function _temp$3(option) {
|
|
476
|
+
return /* @__PURE__ */ jsx(FormControlLabel, {
|
|
477
|
+
value: option.value,
|
|
478
|
+
control: /* @__PURE__ */ jsx(Radio, {}),
|
|
479
|
+
label: option.label
|
|
480
|
+
}, option.value);
|
|
220
481
|
}
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
const
|
|
482
|
+
// src/components/form/FormSlider.tsx
|
|
483
|
+
const FormSlider = (t0) => {
|
|
484
|
+
const $ = c(30);
|
|
485
|
+
let label;
|
|
486
|
+
let props;
|
|
487
|
+
if ($[0] !== t0) {
|
|
488
|
+
({label, ...props} = t0);
|
|
489
|
+
$[0] = t0;
|
|
490
|
+
$[1] = label;
|
|
491
|
+
$[2] = props;
|
|
492
|
+
} else {
|
|
493
|
+
label = $[1];
|
|
494
|
+
props = $[2];
|
|
495
|
+
}
|
|
496
|
+
const field = useFieldContext();
|
|
497
|
+
let t1;
|
|
498
|
+
if ($[3] !== field) {
|
|
499
|
+
t1 = getFieldStatus(field);
|
|
500
|
+
$[3] = field;
|
|
501
|
+
$[4] = t1;
|
|
502
|
+
} else t1 = $[4];
|
|
503
|
+
const { error, helperText } = t1;
|
|
504
|
+
const labelId = useId();
|
|
505
|
+
const helperId = useId();
|
|
506
|
+
let t2;
|
|
507
|
+
if ($[5] !== label || $[6] !== labelId) {
|
|
508
|
+
t2 = label && /* @__PURE__ */ jsx(FormLabel, {
|
|
509
|
+
id: labelId,
|
|
510
|
+
children: label
|
|
511
|
+
});
|
|
512
|
+
$[5] = label;
|
|
513
|
+
$[6] = labelId;
|
|
514
|
+
$[7] = t2;
|
|
515
|
+
} else t2 = $[7];
|
|
516
|
+
const t3 = field.state.value ?? 0;
|
|
517
|
+
let t4;
|
|
518
|
+
if ($[8] !== field) {
|
|
519
|
+
t4 = (_, value) => field.handleChange(Array.isArray(value) ? value[0] : value);
|
|
520
|
+
$[8] = field;
|
|
521
|
+
$[9] = t4;
|
|
522
|
+
} else t4 = $[9];
|
|
523
|
+
const t5 = label ? labelId : void 0;
|
|
524
|
+
const t6 = error || void 0;
|
|
525
|
+
const t7 = error ? helperId : void 0;
|
|
526
|
+
let t8;
|
|
527
|
+
if ($[10] !== t6 || $[11] !== t7) {
|
|
528
|
+
t8 = { input: {
|
|
529
|
+
"aria-invalid": t6,
|
|
530
|
+
"aria-describedby": t7
|
|
531
|
+
} };
|
|
532
|
+
$[10] = t6;
|
|
533
|
+
$[11] = t7;
|
|
534
|
+
$[12] = t8;
|
|
535
|
+
} else t8 = $[12];
|
|
536
|
+
let t9;
|
|
537
|
+
if ($[13] !== field.handleBlur || $[14] !== field.name || $[15] !== props || $[16] !== t3 || $[17] !== t4 || $[18] !== t5 || $[19] !== t8) {
|
|
538
|
+
t9 = /* @__PURE__ */ jsx(Slider, {
|
|
539
|
+
name: field.name,
|
|
540
|
+
value: t3,
|
|
541
|
+
onChange: t4,
|
|
542
|
+
onBlur: field.handleBlur,
|
|
543
|
+
"aria-labelledby": t5,
|
|
544
|
+
slotProps: t8,
|
|
545
|
+
...props
|
|
546
|
+
});
|
|
547
|
+
$[13] = field.handleBlur;
|
|
548
|
+
$[14] = field.name;
|
|
549
|
+
$[15] = props;
|
|
550
|
+
$[16] = t3;
|
|
551
|
+
$[17] = t4;
|
|
552
|
+
$[18] = t5;
|
|
553
|
+
$[19] = t8;
|
|
554
|
+
$[20] = t9;
|
|
555
|
+
} else t9 = $[20];
|
|
556
|
+
let t10;
|
|
557
|
+
if ($[21] !== error || $[22] !== helperId || $[23] !== helperText) {
|
|
558
|
+
t10 = error && /* @__PURE__ */ jsx(FormHelperText, {
|
|
559
|
+
id: helperId,
|
|
560
|
+
children: helperText
|
|
561
|
+
});
|
|
562
|
+
$[21] = error;
|
|
563
|
+
$[22] = helperId;
|
|
564
|
+
$[23] = helperText;
|
|
565
|
+
$[24] = t10;
|
|
566
|
+
} else t10 = $[24];
|
|
567
|
+
let t11;
|
|
568
|
+
if ($[25] !== error || $[26] !== t10 || $[27] !== t2 || $[28] !== t9) {
|
|
569
|
+
t11 = /* @__PURE__ */ jsxs(FormControl, {
|
|
570
|
+
error,
|
|
571
|
+
children: [
|
|
572
|
+
t2,
|
|
573
|
+
t9,
|
|
574
|
+
t10
|
|
575
|
+
]
|
|
576
|
+
});
|
|
577
|
+
$[25] = error;
|
|
578
|
+
$[26] = t10;
|
|
579
|
+
$[27] = t2;
|
|
580
|
+
$[28] = t9;
|
|
581
|
+
$[29] = t11;
|
|
582
|
+
} else t11 = $[29];
|
|
583
|
+
return t11;
|
|
584
|
+
};
|
|
585
|
+
// src/components/form/FormSubmitButton.tsx
|
|
586
|
+
const FormSubmitButton = (props) => {
|
|
587
|
+
const $ = c(8);
|
|
588
|
+
const form = useFormContext();
|
|
224
589
|
let t0;
|
|
225
|
-
if ($[0] !==
|
|
226
|
-
t0 = (
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
590
|
+
if ($[0] !== form) {
|
|
591
|
+
t0 = async (event) => {
|
|
592
|
+
event.preventDefault();
|
|
593
|
+
event.stopPropagation();
|
|
594
|
+
const scope = event.currentTarget.form ?? document;
|
|
595
|
+
await form.handleSubmit();
|
|
596
|
+
const fieldMeta = form.state.fieldMeta;
|
|
597
|
+
requestAnimationFrame(() => {
|
|
598
|
+
const invalid = Array.from(scope.querySelectorAll("input[name], textarea[name], select[name]")).find((element) => fieldMeta[element.getAttribute("name") ?? ""]?.errors.length);
|
|
599
|
+
(invalid?.getAttribute("aria-hidden") === "true" ? invalid.parentElement?.querySelector("[tabindex=\"0\"]") ?? invalid : invalid)?.focus();
|
|
231
600
|
});
|
|
232
601
|
};
|
|
233
|
-
$[0] =
|
|
602
|
+
$[0] = form;
|
|
234
603
|
$[1] = t0;
|
|
235
604
|
} else t0 = $[1];
|
|
236
|
-
const
|
|
605
|
+
const handleClick = t0;
|
|
237
606
|
let t1;
|
|
238
|
-
if ($[2] !==
|
|
239
|
-
t1 = (
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
$[
|
|
247
|
-
$[
|
|
248
|
-
} else t1 = $[
|
|
249
|
-
const confirm = useEventCallback(t1);
|
|
607
|
+
if ($[2] !== handleClick || $[3] !== props) {
|
|
608
|
+
t1 = (isSubmitting) => /* @__PURE__ */ jsx(Button, {
|
|
609
|
+
loading: isSubmitting,
|
|
610
|
+
onClick: handleClick,
|
|
611
|
+
type: "submit",
|
|
612
|
+
...props
|
|
613
|
+
});
|
|
614
|
+
$[2] = handleClick;
|
|
615
|
+
$[3] = props;
|
|
616
|
+
$[4] = t1;
|
|
617
|
+
} else t1 = $[4];
|
|
250
618
|
let t2;
|
|
251
|
-
if ($[
|
|
252
|
-
t2 = {
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
$[
|
|
259
|
-
|
|
260
|
-
$[6] = confirm;
|
|
261
|
-
$[7] = open;
|
|
262
|
-
$[8] = t2;
|
|
263
|
-
} else t2 = $[8];
|
|
619
|
+
if ($[5] !== form.Subscribe || $[6] !== t1) {
|
|
620
|
+
t2 = /* @__PURE__ */ jsx(form.Subscribe, {
|
|
621
|
+
selector: _temp$2,
|
|
622
|
+
children: t1
|
|
623
|
+
});
|
|
624
|
+
$[5] = form.Subscribe;
|
|
625
|
+
$[6] = t1;
|
|
626
|
+
$[7] = t2;
|
|
627
|
+
} else t2 = $[7];
|
|
264
628
|
return t2;
|
|
629
|
+
};
|
|
630
|
+
function _temp$2(state) {
|
|
631
|
+
return state.isSubmitting;
|
|
265
632
|
}
|
|
266
|
-
// src/components/
|
|
267
|
-
const
|
|
268
|
-
const $ = c(
|
|
269
|
-
let
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
633
|
+
// src/components/form/FormSwitch.tsx
|
|
634
|
+
const FormSwitch = (t0) => {
|
|
635
|
+
const $ = c(28);
|
|
636
|
+
let label;
|
|
637
|
+
let props;
|
|
638
|
+
if ($[0] !== t0) {
|
|
639
|
+
({label, ...props} = t0);
|
|
640
|
+
$[0] = t0;
|
|
641
|
+
$[1] = label;
|
|
642
|
+
$[2] = props;
|
|
643
|
+
} else {
|
|
644
|
+
label = $[1];
|
|
645
|
+
props = $[2];
|
|
646
|
+
}
|
|
647
|
+
const field = useFieldContext();
|
|
648
|
+
let t1;
|
|
649
|
+
if ($[3] !== field) {
|
|
650
|
+
t1 = getFieldStatus(field);
|
|
651
|
+
$[3] = field;
|
|
652
|
+
$[4] = t1;
|
|
653
|
+
} else t1 = $[4];
|
|
654
|
+
const { error, helperText } = t1;
|
|
655
|
+
const helperId = useId();
|
|
656
|
+
const t2 = field.name;
|
|
657
|
+
const t3 = Boolean(field.state.value);
|
|
658
|
+
let t4;
|
|
659
|
+
if ($[5] !== field) {
|
|
660
|
+
t4 = (event) => field.handleChange(event.target.checked);
|
|
661
|
+
$[5] = field;
|
|
662
|
+
$[6] = t4;
|
|
663
|
+
} else t4 = $[6];
|
|
664
|
+
const t5 = error || void 0;
|
|
665
|
+
const t6 = error ? helperId : void 0;
|
|
666
|
+
let t7;
|
|
667
|
+
if ($[7] !== t5 || $[8] !== t6) {
|
|
668
|
+
t7 = { input: {
|
|
669
|
+
"aria-invalid": t5,
|
|
670
|
+
"aria-describedby": t6
|
|
671
|
+
} };
|
|
672
|
+
$[7] = t5;
|
|
673
|
+
$[8] = t6;
|
|
674
|
+
$[9] = t7;
|
|
675
|
+
} else t7 = $[9];
|
|
676
|
+
let t8;
|
|
677
|
+
if ($[10] !== field.handleBlur || $[11] !== field.name || $[12] !== props || $[13] !== t3 || $[14] !== t4 || $[15] !== t7) {
|
|
678
|
+
t8 = /* @__PURE__ */ jsx(Switch, {
|
|
679
|
+
name: t2,
|
|
680
|
+
checked: t3,
|
|
681
|
+
onChange: t4,
|
|
682
|
+
onBlur: field.handleBlur,
|
|
683
|
+
slotProps: t7,
|
|
273
684
|
...props
|
|
274
685
|
});
|
|
275
|
-
$[
|
|
276
|
-
$[
|
|
277
|
-
$[
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
const
|
|
686
|
+
$[10] = field.handleBlur;
|
|
687
|
+
$[11] = field.name;
|
|
688
|
+
$[12] = props;
|
|
689
|
+
$[13] = t3;
|
|
690
|
+
$[14] = t4;
|
|
691
|
+
$[15] = t7;
|
|
692
|
+
$[16] = t8;
|
|
693
|
+
} else t8 = $[16];
|
|
694
|
+
const t9 = label ?? "";
|
|
695
|
+
let t10;
|
|
696
|
+
if ($[17] !== t8 || $[18] !== t9) {
|
|
697
|
+
t10 = /* @__PURE__ */ jsx(FormControlLabel, {
|
|
698
|
+
control: t8,
|
|
699
|
+
label: t9
|
|
700
|
+
});
|
|
701
|
+
$[17] = t8;
|
|
702
|
+
$[18] = t9;
|
|
703
|
+
$[19] = t10;
|
|
704
|
+
} else t10 = $[19];
|
|
705
|
+
let t11;
|
|
706
|
+
if ($[20] !== error || $[21] !== helperId || $[22] !== helperText) {
|
|
707
|
+
t11 = error && /* @__PURE__ */ jsx(FormHelperText, {
|
|
708
|
+
id: helperId,
|
|
709
|
+
children: helperText
|
|
710
|
+
});
|
|
711
|
+
$[20] = error;
|
|
712
|
+
$[21] = helperId;
|
|
713
|
+
$[22] = helperText;
|
|
714
|
+
$[23] = t11;
|
|
715
|
+
} else t11 = $[23];
|
|
716
|
+
let t12;
|
|
717
|
+
if ($[24] !== error || $[25] !== t10 || $[26] !== t11) {
|
|
718
|
+
t12 = /* @__PURE__ */ jsxs(FormControl, {
|
|
719
|
+
error,
|
|
720
|
+
children: [t10, t11]
|
|
721
|
+
});
|
|
722
|
+
$[24] = error;
|
|
723
|
+
$[25] = t10;
|
|
724
|
+
$[26] = t11;
|
|
725
|
+
$[27] = t12;
|
|
726
|
+
} else t12 = $[27];
|
|
727
|
+
return t12;
|
|
728
|
+
};
|
|
729
|
+
// src/components/form/FormTextField.tsx
|
|
730
|
+
const FormTextField = (props) => {
|
|
731
|
+
const $ = c(12);
|
|
732
|
+
const field = useFieldContext();
|
|
284
733
|
let t0;
|
|
285
|
-
if ($[0] !==
|
|
286
|
-
t0 =
|
|
287
|
-
$[0] =
|
|
734
|
+
if ($[0] !== field) {
|
|
735
|
+
t0 = getFieldStatus(field);
|
|
736
|
+
$[0] = field;
|
|
288
737
|
$[1] = t0;
|
|
289
738
|
} else t0 = $[1];
|
|
290
|
-
|
|
739
|
+
const { error, helperText } = t0;
|
|
740
|
+
const t1 = field.state.value ?? "";
|
|
741
|
+
let t2;
|
|
742
|
+
if ($[2] !== field) {
|
|
743
|
+
t2 = (event) => field.handleChange(event.target.value);
|
|
744
|
+
$[2] = field;
|
|
745
|
+
$[3] = t2;
|
|
746
|
+
} else t2 = $[3];
|
|
747
|
+
let t3;
|
|
748
|
+
if ($[4] !== error || $[5] !== field.handleBlur || $[6] !== field.name || $[7] !== helperText || $[8] !== props || $[9] !== t1 || $[10] !== t2) {
|
|
749
|
+
t3 = /* @__PURE__ */ jsx(TextField, {
|
|
750
|
+
name: field.name,
|
|
751
|
+
value: t1,
|
|
752
|
+
onChange: t2,
|
|
753
|
+
onBlur: field.handleBlur,
|
|
754
|
+
error,
|
|
755
|
+
helperText,
|
|
756
|
+
...props
|
|
757
|
+
});
|
|
758
|
+
$[4] = error;
|
|
759
|
+
$[5] = field.handleBlur;
|
|
760
|
+
$[6] = field.name;
|
|
761
|
+
$[7] = helperText;
|
|
762
|
+
$[8] = props;
|
|
763
|
+
$[9] = t1;
|
|
764
|
+
$[10] = t2;
|
|
765
|
+
$[11] = t3;
|
|
766
|
+
} else t3 = $[11];
|
|
767
|
+
return t3;
|
|
291
768
|
};
|
|
292
|
-
// src/
|
|
293
|
-
const
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
arrIncludes: filterFn_arrIncludes,
|
|
307
|
-
arrIncludesAll: filterFn_arrIncludesAll,
|
|
308
|
-
arrIncludesSome: filterFn_arrIncludesSome,
|
|
309
|
-
between: filterFn_between,
|
|
310
|
-
betweenInclusive: filterFn_betweenInclusive,
|
|
311
|
-
empty: filterFn_empty,
|
|
312
|
-
endsWith: filterFn_endsWith,
|
|
313
|
-
equals: filterFn_equals,
|
|
314
|
-
equalsString: filterFn_equalsString,
|
|
315
|
-
equalsStringSensitive: filterFn_equalsStringSensitive,
|
|
316
|
-
greaterThan: filterFn_greaterThan,
|
|
317
|
-
greaterThanOrEqualTo: filterFn_greaterThanOrEqualTo,
|
|
318
|
-
inDateRange: filterFn_inDateRange,
|
|
319
|
-
inNumberRange: filterFn_inNumberRange,
|
|
320
|
-
includesString: filterFn_includesString,
|
|
321
|
-
includesStringSensitive: filterFn_includesStringSensitive,
|
|
322
|
-
lessThan: filterFn_lessThan,
|
|
323
|
-
lessThanOrEqualTo: filterFn_lessThanOrEqualTo,
|
|
324
|
-
notEmpty: filterFn_notEmpty,
|
|
325
|
-
startsWith: filterFn_startsWith,
|
|
326
|
-
weakEquals: filterFn_weakEquals
|
|
769
|
+
// src/hooks/useForm.ts
|
|
770
|
+
const { fieldContext, useFieldContext, formContext, useFormContext } = createFormHookContexts();
|
|
771
|
+
const { useAppForm: useLayoutForm, withForm: withLayoutForm } = createFormHook({
|
|
772
|
+
fieldComponents: {
|
|
773
|
+
TextField: FormTextField,
|
|
774
|
+
NumberField: FormNumberField,
|
|
775
|
+
Autocomplete: FormAutocomplete,
|
|
776
|
+
Checkbox: FormCheckbox,
|
|
777
|
+
Switch: FormSwitch,
|
|
778
|
+
RadioGroup: FormRadioGroup,
|
|
779
|
+
Slider: FormSlider,
|
|
780
|
+
DatePicker: FormDatePicker,
|
|
781
|
+
TimePicker: FormTimePicker,
|
|
782
|
+
DateTimePicker: FormDateTimePicker
|
|
327
783
|
},
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
basic: sortFn_basic,
|
|
332
|
-
datetime: sortFn_datetime,
|
|
333
|
-
text: sortFn_text,
|
|
334
|
-
textCaseSensitive: sortFn_textCaseSensitive
|
|
335
|
-
},
|
|
336
|
-
aggregationFns: {
|
|
337
|
-
sum: aggregationFn_sum,
|
|
338
|
-
min: aggregationFn_min,
|
|
339
|
-
max: aggregationFn_max,
|
|
340
|
-
extent: aggregationFn_extent,
|
|
341
|
-
mean: aggregationFn_mean,
|
|
342
|
-
median: aggregationFn_median,
|
|
343
|
-
unique: aggregationFn_unique,
|
|
344
|
-
uniqueCount: aggregationFn_uniqueCount,
|
|
345
|
-
count: aggregationFn_count,
|
|
346
|
-
first: aggregationFn_first,
|
|
347
|
-
last: aggregationFn_last
|
|
348
|
-
}
|
|
784
|
+
formComponents: { SubmitButton: FormSubmitButton },
|
|
785
|
+
fieldContext,
|
|
786
|
+
formContext
|
|
349
787
|
});
|
|
350
|
-
const { tableContext, cellContext, headerContext, useTableContext, useCellContext, useHeaderContext } = createTableHookContexts();
|
|
351
|
-
// src/components/table/table/Pagination.tsx
|
|
352
|
-
/** A pager is for large data sets, so it offers no "All". LayoutTable starts at the lowest. */
|
|
353
|
-
const DEFAULT_PAGE_SIZE_OPTIONS = [
|
|
354
|
-
25,
|
|
355
|
-
50,
|
|
356
|
-
100
|
|
357
|
-
];
|
|
358
|
-
const Pagination = ({ pageSizeOptions = DEFAULT_PAGE_SIZE_OPTIONS, ...props }) => {
|
|
359
|
-
"use no memo";
|
|
360
|
-
const table = useTableContext();
|
|
361
|
-
const { pageIndex, pageSize } = table.state.pagination;
|
|
362
|
-
return /* @__PURE__ */ jsx(TablePagination, {
|
|
363
|
-
component: "div",
|
|
364
|
-
showFirstButton: true,
|
|
365
|
-
showLastButton: true,
|
|
366
|
-
...props,
|
|
367
|
-
sx: [{
|
|
368
|
-
flexShrink: 0,
|
|
369
|
-
minHeight: 52,
|
|
370
|
-
borderTop: 1,
|
|
371
|
-
borderColor: "divider"
|
|
372
|
-
}, ...Array.isArray(props.sx) ? props.sx : [props.sx]],
|
|
373
|
-
rowsPerPageOptions: pageSizeOptions,
|
|
374
|
-
count: table.getPageCount() === -1 ? -1 : table.getRowCount(),
|
|
375
|
-
page: pageIndex,
|
|
376
|
-
rowsPerPage: pageSize,
|
|
377
|
-
onPageChange: (_, page) => table.setPageIndex(page),
|
|
378
|
-
onRowsPerPageChange: (event) => table.setPagination({
|
|
379
|
-
pageIndex: 0,
|
|
380
|
-
pageSize: Number(event.target.value)
|
|
381
|
-
})
|
|
382
|
-
});
|
|
383
|
-
};
|
|
384
788
|
// src/components/table/utils.ts
|
|
385
789
|
/** Stable class names on every table part, for `sx` selectors like `.MuiDataGrid-*`. */
|
|
386
790
|
const layoutTableClasses = {
|
|
@@ -424,6 +828,8 @@ const layoutTableClasses = {
|
|
|
424
828
|
"cell--aggregated": "LayoutTable-cell--aggregated",
|
|
425
829
|
"cell--pinnedStart": "LayoutTable-cell--pinnedStart",
|
|
426
830
|
"cell--pinnedEnd": "LayoutTable-cell--pinnedEnd",
|
|
831
|
+
cellEditor: "LayoutTable-cellEditor",
|
|
832
|
+
editButton: "LayoutTable-editButton",
|
|
427
833
|
groupCell: "LayoutTable-groupCell",
|
|
428
834
|
expandButton: "LayoutTable-expandButton",
|
|
429
835
|
actionsCell: "LayoutTable-actionsCell",
|
|
@@ -474,8 +880,14 @@ const pinnedSx = (column, isHeader = false) => {
|
|
|
474
880
|
insetInlineEnd: pinned === "end" ? column.getAfter("end") : void 0,
|
|
475
881
|
bgcolor: "background.paper",
|
|
476
882
|
...!isHeader && {
|
|
477
|
-
".MuiTableRow-root:hover > &": { backgroundImage: (theme) =>
|
|
478
|
-
|
|
883
|
+
".MuiTableRow-root:hover > &": { backgroundImage: (theme) => {
|
|
884
|
+
const { hover } = (theme.vars ?? theme).palette.action;
|
|
885
|
+
return `linear-gradient(${hover}, ${hover})`;
|
|
886
|
+
} },
|
|
887
|
+
".MuiTableRow-root.Mui-selected > &": { backgroundImage: (theme) => {
|
|
888
|
+
const { selected } = (theme.vars ?? theme).palette.action;
|
|
889
|
+
return `linear-gradient(${selected}, ${selected})`;
|
|
890
|
+
} }
|
|
479
891
|
},
|
|
480
892
|
...pinned === "start" && column.getIsLastColumn("start") && {
|
|
481
893
|
borderInlineEnd: 1,
|
|
@@ -492,14 +904,20 @@ const pinnedSx = (column, isHeader = false) => {
|
|
|
492
904
|
const cellSelectionSx = (cell) => {
|
|
493
905
|
if (!cell.getIsSelected()) return {};
|
|
494
906
|
const edges = cell.getSelectionEdges();
|
|
495
|
-
const outline = (theme) =>
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
907
|
+
const outline = (theme) => {
|
|
908
|
+
const color = (theme.vars ?? theme).palette.primary.main;
|
|
909
|
+
return [
|
|
910
|
+
edges.top && `inset 0 2px 0 0 ${color}`,
|
|
911
|
+
edges.bottom && `inset 0 -2px 0 0 ${color}`,
|
|
912
|
+
edges.left && `inset 2px 0 0 0 ${color}`,
|
|
913
|
+
edges.right && `inset -2px 0 0 0 ${color}`
|
|
914
|
+
].filter(Boolean).join(", ") || "none";
|
|
915
|
+
};
|
|
501
916
|
return {
|
|
502
|
-
backgroundImage: (theme) =>
|
|
917
|
+
backgroundImage: (theme) => {
|
|
918
|
+
const { selected } = (theme.vars ?? theme).palette.action;
|
|
919
|
+
return `linear-gradient(${selected}, ${selected})`;
|
|
920
|
+
},
|
|
503
921
|
boxShadow: outline
|
|
504
922
|
};
|
|
505
923
|
};
|
|
@@ -529,16 +947,51 @@ const lookaheadRange = (range, direction, lookahead) => {
|
|
|
529
947
|
});
|
|
530
948
|
};
|
|
531
949
|
// src/components/table/formatValue.ts
|
|
532
|
-
const formatValue = (value, dateFormat = "L LT") => {
|
|
950
|
+
const formatValue = (value, dateFormat = "L LT", locale) => {
|
|
533
951
|
if (value === null || value === void 0) return "";
|
|
534
|
-
if (value instanceof Date) return dayjs(value).format(dateFormat);
|
|
952
|
+
if (value instanceof Date) return dayjs(value).locale(locale ?? dayjs.locale()).format(dateFormat);
|
|
535
953
|
if (typeof value === "string") return value;
|
|
536
954
|
if (typeof value === "number" || typeof value === "boolean" || typeof value === "bigint") return value.toString();
|
|
537
955
|
return JSON.stringify(value) ?? "";
|
|
538
956
|
};
|
|
957
|
+
// src/components/table/context.ts
|
|
958
|
+
const layoutTableFeatures = tableFeatures({
|
|
959
|
+
...stockFeatures,
|
|
960
|
+
columnMeta: metaHelper(),
|
|
961
|
+
filteredRowModel: createFilteredRowModel(),
|
|
962
|
+
sortedRowModel: createSortedRowModel(),
|
|
963
|
+
paginatedRowModel: createPaginatedRowModel(),
|
|
964
|
+
expandedRowModel: createExpandedRowModel(),
|
|
965
|
+
groupedRowModel: createGroupedRowModel(),
|
|
966
|
+
facetedRowModel: createFacetedRowModel(),
|
|
967
|
+
facetedUniqueValues: createFacetedUniqueValues(),
|
|
968
|
+
facetedMinMaxValues: createFacetedMinMaxValues(),
|
|
969
|
+
sortFns: {
|
|
970
|
+
alphanumeric: sortFn_alphanumeric,
|
|
971
|
+
alphanumericCaseSensitive: sortFn_alphanumericCaseSensitive,
|
|
972
|
+
basic: sortFn_basic,
|
|
973
|
+
datetime: sortFn_datetime,
|
|
974
|
+
text: sortFn_text,
|
|
975
|
+
textCaseSensitive: sortFn_textCaseSensitive
|
|
976
|
+
},
|
|
977
|
+
aggregationFns: {
|
|
978
|
+
sum: aggregationFn_sum,
|
|
979
|
+
min: aggregationFn_min,
|
|
980
|
+
max: aggregationFn_max,
|
|
981
|
+
extent: aggregationFn_extent,
|
|
982
|
+
mean: aggregationFn_mean,
|
|
983
|
+
median: aggregationFn_median,
|
|
984
|
+
unique: aggregationFn_unique,
|
|
985
|
+
uniqueCount: aggregationFn_uniqueCount,
|
|
986
|
+
count: aggregationFn_count,
|
|
987
|
+
first: aggregationFn_first,
|
|
988
|
+
last: aggregationFn_last
|
|
989
|
+
}
|
|
990
|
+
});
|
|
991
|
+
const { tableContext, cellContext, headerContext, useTableContext, useCellContext, useHeaderContext } = createTableHookContexts();
|
|
539
992
|
// src/components/table/cells/formatters/AggregatedCell.tsx
|
|
540
993
|
const AggregatedCell = (t0) => {
|
|
541
|
-
const $ = c(
|
|
994
|
+
const $ = c(31);
|
|
542
995
|
let dateFormat;
|
|
543
996
|
let options;
|
|
544
997
|
let props;
|
|
@@ -558,6 +1011,7 @@ const AggregatedCell = (t0) => {
|
|
|
558
1011
|
}
|
|
559
1012
|
const prefix = t1 === void 0 ? "" : t1;
|
|
560
1013
|
const cell = useCellContext();
|
|
1014
|
+
const { i18n } = useTranslation$1();
|
|
561
1015
|
let T0;
|
|
562
1016
|
let t2;
|
|
563
1017
|
let t3;
|
|
@@ -566,7 +1020,7 @@ const AggregatedCell = (t0) => {
|
|
|
566
1020
|
let t6;
|
|
567
1021
|
let t7;
|
|
568
1022
|
let t8;
|
|
569
|
-
if ($[5] !== cell || $[6] !== dateFormat || $[7] !==
|
|
1023
|
+
if ($[5] !== cell || $[6] !== dateFormat || $[7] !== i18n || $[8] !== options || $[9] !== prefix || $[10] !== props) {
|
|
570
1024
|
t8 = Symbol.for("react.early_return_sentinel");
|
|
571
1025
|
bb0: {
|
|
572
1026
|
const value = cell.getValue();
|
|
@@ -575,12 +1029,13 @@ const AggregatedCell = (t0) => {
|
|
|
575
1029
|
break bb0;
|
|
576
1030
|
}
|
|
577
1031
|
let t9;
|
|
578
|
-
if ($[
|
|
579
|
-
t9 = (entry) => typeof entry === "number" ? entry.toLocaleString(void 0, options) : formatValue(entry, dateFormat);
|
|
580
|
-
$[
|
|
581
|
-
$[
|
|
582
|
-
$[
|
|
583
|
-
|
|
1032
|
+
if ($[19] !== dateFormat || $[20] !== i18n || $[21] !== options) {
|
|
1033
|
+
t9 = (entry) => typeof entry === "number" ? entry.toLocaleString(void 0, options) : formatValue(entry, dateFormat, i18n.language);
|
|
1034
|
+
$[19] = dateFormat;
|
|
1035
|
+
$[20] = i18n;
|
|
1036
|
+
$[21] = options;
|
|
1037
|
+
$[22] = t9;
|
|
1038
|
+
} else t9 = $[22];
|
|
584
1039
|
const format = t9;
|
|
585
1040
|
T0 = Typography;
|
|
586
1041
|
t2 = "body2";
|
|
@@ -592,30 +1047,31 @@ const AggregatedCell = (t0) => {
|
|
|
592
1047
|
}
|
|
593
1048
|
$[5] = cell;
|
|
594
1049
|
$[6] = dateFormat;
|
|
595
|
-
$[7] =
|
|
596
|
-
$[8] =
|
|
597
|
-
$[9] =
|
|
598
|
-
$[10] =
|
|
599
|
-
$[11] =
|
|
600
|
-
$[12] =
|
|
601
|
-
$[13] =
|
|
602
|
-
$[14] =
|
|
603
|
-
$[15] =
|
|
604
|
-
$[16] =
|
|
605
|
-
$[17] =
|
|
1050
|
+
$[7] = i18n;
|
|
1051
|
+
$[8] = options;
|
|
1052
|
+
$[9] = prefix;
|
|
1053
|
+
$[10] = props;
|
|
1054
|
+
$[11] = T0;
|
|
1055
|
+
$[12] = t2;
|
|
1056
|
+
$[13] = t3;
|
|
1057
|
+
$[14] = t4;
|
|
1058
|
+
$[15] = t5;
|
|
1059
|
+
$[16] = t6;
|
|
1060
|
+
$[17] = t7;
|
|
1061
|
+
$[18] = t8;
|
|
606
1062
|
} else {
|
|
607
|
-
T0 = $[
|
|
608
|
-
t2 = $[
|
|
609
|
-
t3 = $[
|
|
610
|
-
t4 = $[
|
|
611
|
-
t5 = $[
|
|
612
|
-
t6 = $[
|
|
613
|
-
t7 = $[
|
|
614
|
-
t8 = $[
|
|
1063
|
+
T0 = $[11];
|
|
1064
|
+
t2 = $[12];
|
|
1065
|
+
t3 = $[13];
|
|
1066
|
+
t4 = $[14];
|
|
1067
|
+
t5 = $[15];
|
|
1068
|
+
t6 = $[16];
|
|
1069
|
+
t7 = $[17];
|
|
1070
|
+
t8 = $[18];
|
|
615
1071
|
}
|
|
616
1072
|
if (t8 !== Symbol.for("react.early_return_sentinel")) return t8;
|
|
617
1073
|
let t9;
|
|
618
|
-
if ($[
|
|
1074
|
+
if ($[23] !== T0 || $[24] !== t2 || $[25] !== t3 || $[26] !== t4 || $[27] !== t5 || $[28] !== t6 || $[29] !== t7) {
|
|
619
1075
|
t9 = /* @__PURE__ */ jsxs(T0, {
|
|
620
1076
|
variant: t2,
|
|
621
1077
|
color: t3,
|
|
@@ -623,15 +1079,15 @@ const AggregatedCell = (t0) => {
|
|
|
623
1079
|
...t5,
|
|
624
1080
|
children: [t6, t7]
|
|
625
1081
|
});
|
|
626
|
-
$[
|
|
627
|
-
$[
|
|
628
|
-
$[
|
|
629
|
-
$[
|
|
630
|
-
$[
|
|
631
|
-
$[
|
|
632
|
-
$[
|
|
633
|
-
$[
|
|
634
|
-
} else t9 = $[
|
|
1082
|
+
$[23] = T0;
|
|
1083
|
+
$[24] = t2;
|
|
1084
|
+
$[25] = t3;
|
|
1085
|
+
$[26] = t4;
|
|
1086
|
+
$[27] = t5;
|
|
1087
|
+
$[28] = t6;
|
|
1088
|
+
$[29] = t7;
|
|
1089
|
+
$[30] = t9;
|
|
1090
|
+
} else t9 = $[30];
|
|
635
1091
|
return t9;
|
|
636
1092
|
};
|
|
637
1093
|
// src/lib/ai/tools/ui.ts
|
|
@@ -1063,6 +1519,18 @@ async function fileToPart(file) {
|
|
|
1063
1519
|
};
|
|
1064
1520
|
}
|
|
1065
1521
|
// src/components/chat/ChatLayout.tsx
|
|
1522
|
+
/** Read by screen readers, invisible on screen (MUI's `visuallyHidden`). */
|
|
1523
|
+
const visuallyHidden = {
|
|
1524
|
+
border: 0,
|
|
1525
|
+
clipPath: "inset(50%)",
|
|
1526
|
+
height: "1px",
|
|
1527
|
+
margin: "-1px",
|
|
1528
|
+
overflow: "hidden",
|
|
1529
|
+
padding: 0,
|
|
1530
|
+
position: "absolute",
|
|
1531
|
+
whiteSpace: "nowrap",
|
|
1532
|
+
width: "1px"
|
|
1533
|
+
};
|
|
1066
1534
|
/** One centered reading column, like ChatGPT: full width on a phone, 48rem on a desktop. */
|
|
1067
1535
|
const columnSx = {
|
|
1068
1536
|
width: "100%",
|
|
@@ -1921,6 +2389,6 @@ function ChatLayout({ chat, sx }) {
|
|
|
1921
2389
|
]
|
|
1922
2390
|
});
|
|
1923
2391
|
}
|
|
1924
|
-
export {
|
|
2392
|
+
export { shortcutLabel as C, useLayoutForm as D, useFormContext as E, withLayoutForm as O, pinnedSx as S, useFieldContext as T, hasColumnLabel as _, headerContext as a, moveColumn as b, useCellContext as c, formatValue as d, cellSelectionSx as f, columnLabel as g, columnFlex as h, cellContext as i, useHeaderContext as l, columnAlign as m, createUiTools as n, layoutTableFeatures as o, classNames as p, AggregatedCell as r, tableContext as s, ChatLayout as t, useTableContext as u, layoutTableClasses as v, toClipboardText as w, pinnedClass as x, lookaheadRange as y };
|
|
1925
2393
|
|
|
1926
|
-
//# sourceMappingURL=ChatLayout-
|
|
2394
|
+
//# sourceMappingURL=ChatLayout-B0MBrI-Y.mjs.map
|