@cgi-learning-hub/ui 1.3.3 → 1.3.4-dev.1733911143
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/Backdrop-DqUdx8FP.cjs +1 -0
- package/dist/Backdrop-ZqzrnV2E.js +360 -0
- package/dist/Box-Be6jhcmK.cjs +1 -0
- package/dist/{Box-UE-zctbJ.js → Box-DN_2fcm9.js} +9 -9
- package/dist/Button-C6UXybBV.cjs +1 -0
- package/dist/{Button-Bjy0iPNm.js → Button-CL9rFoOY.js} +152 -118
- package/dist/{ButtonBase-CFD7NVUc.js → ButtonBase-CYkLbJ0U.js} +232 -240
- package/dist/ButtonBase-DzK1n18b.cjs +74 -0
- package/dist/Card-DO4cAmNC.js +74 -0
- package/dist/Card-DsmqVSx1.cjs +1 -0
- package/dist/Checkbox-Btg05OjV.cjs +1 -0
- package/dist/{Checkbox-Ct5E_6h7.js → Checkbox-CLM5GjuC.js} +27 -26
- package/dist/CircularProgress-BfbGcmHT.cjs +28 -0
- package/dist/{CircularProgress-By02Sdoh.js → CircularProgress-C4xtwh4E.js} +28 -27
- package/dist/DatePicker-BXTOQETi.cjs +14 -0
- package/dist/DatePicker-D9suyaUZ.js +10846 -0
- package/dist/DefaultPropsProvider-DE-Tx_ov.cjs +17 -0
- package/dist/DefaultPropsProvider-DUWovK-8.js +454 -0
- package/dist/Delete-CpADFuIX.cjs +1 -0
- package/dist/Delete-DWXEW4-c.js +8 -0
- package/dist/DialogContent-D_JmqJt6.js +603 -0
- package/dist/DialogContent-gRISmOoj.cjs +1 -0
- package/dist/DialogTitle-CID6RFNo.js +134 -0
- package/dist/DialogTitle-Dhxh1DVb.cjs +1 -0
- package/dist/Divider-BjxxEFnr.cjs +1 -0
- package/dist/Divider-HhF8ckeh.js +296 -0
- package/dist/FormControlLabel-0-cflTuo.js +262 -0
- package/dist/FormControlLabel-C-eZV5Xc.cjs +1 -0
- package/dist/FormGroup-Ck7StJ6i.cjs +1 -0
- package/dist/FormGroup-DIP4u-gv.js +95 -0
- package/dist/FormLabel-Ch103TK-.cjs +2 -0
- package/dist/{FormLabel-B4QlkhhB.js → FormLabel-X7FN1eBV.js} +39 -44
- package/dist/Grow-BgMSa0P2.js +193 -0
- package/dist/Grow-D7OAahbU.cjs +1 -0
- package/dist/{IconButton-Av8eJ5IG.js → IconButton-CMwpC2Co.js} +10 -9
- package/dist/IconButton-DbWtCGLB.cjs +2 -0
- package/dist/{InputAdornment-COPtZlSD.js → InputAdornment-B4hI0-Jz.js} +9 -8
- package/dist/InputAdornment-Cl2OaKlw.cjs +1 -0
- package/dist/InputBase-BuVAuMNp.cjs +3 -0
- package/dist/{InputBase-Bbgoz8GV.js → InputBase-DrofJ7xL.js} +60 -59
- package/dist/Link-AXhb0uJT.cjs +1 -0
- package/dist/Link-Bdupo_fW.js +267 -0
- package/dist/Menu-DR-xtxpt.js +966 -0
- package/dist/Menu-_chQG-Za.cjs +7 -0
- package/dist/{MenuItem-D7HWYhF3.js → MenuItem-C_d0Sc_L.js} +69 -74
- package/dist/MenuItem-De6eStq9.cjs +1 -0
- package/dist/Modal-C4Jb6sd1.js +750 -0
- package/dist/Modal-GXSEk85U.cjs +2 -0
- package/dist/Paper-CH4BABUB.cjs +2 -0
- package/dist/Paper-nlWPEgQh.js +185 -0
- package/dist/Popper-CjTplNLW.cjs +4 -0
- package/dist/Popper-CkAj_qw_.js +1407 -0
- package/dist/Portal-BcFwfiTx.js +86 -0
- package/dist/Portal-BruYsISj.cjs +1 -0
- package/dist/Radio-B0v6nDvz.js +313 -0
- package/dist/Radio-BbZnB74m.cjs +1 -0
- package/dist/Select-BFGwwKap.cjs +3 -0
- package/dist/Select-D9fwtA9U.js +2604 -0
- package/dist/{Stack-y1PjTHKX.js → Stack-C1i6_V9e.js} +105 -60
- package/dist/Stack-DMNZvXss.cjs +1 -0
- package/dist/SwitchBase-BpMNk4XV.cjs +1 -0
- package/dist/{SwitchBase-yCuH0Tqk.js → SwitchBase-DfbwljzN.js} +25 -24
- package/dist/{Tooltip-DO9GIhWC.js → TableSortLabel-DwnLOHOy.js} +2645 -3965
- package/dist/TableSortLabel-lnTBXy-V.cjs +98 -0
- package/dist/{Tabs-DK4Bc5xo.js → Tabs-BoFP2RHv.js} +333 -329
- package/dist/Tabs-DEvwJheI.cjs +4 -0
- package/dist/{TextField-C-B529_r.js → TextField-kwhzNVAL.js} +35 -34
- package/dist/TextField-waKWSLD4.cjs +1 -0
- package/dist/Tooltip-CFyOA9CT.cjs +4 -0
- package/dist/Tooltip-tgkiC77d.js +721 -0
- package/dist/Typography-B6KFjCtE.cjs +1 -0
- package/dist/{Typography-C_ESP41L.js → Typography-DWXYj92v.js} +13 -12
- package/dist/assets/styles.css +1 -1
- package/dist/assets/styles2.css +1 -1
- package/dist/capitalize-DASFtB-F.cjs +1 -0
- package/dist/capitalize-NmHVRYy8.js +9 -0
- package/dist/chainPropTypes-CEUi6Jb4.cjs +1 -0
- package/dist/chainPropTypes-D9lkm76m.js +8 -0
- package/dist/components/Button/Button.cjs.js +1 -1
- package/dist/components/Button/Button.es.js +28 -27
- package/dist/components/DatePicker/DatePicker.cjs.js +1 -1
- package/dist/components/DatePicker/DatePicker.es.js +2 -2
- package/dist/components/DatePicker/index.cjs.js +1 -1
- package/dist/components/DatePicker/index.es.js +1 -1
- package/dist/components/Dropzone/Dropzone.cjs.js +1 -5
- package/dist/components/Dropzone/Dropzone.es.js +24 -2162
- package/dist/components/EmptyState/EmptyState.cjs.js +1 -1
- package/dist/components/EmptyState/EmptyState.es.js +2 -2
- package/dist/components/FileList/FileList.cjs.js +1 -1
- package/dist/components/FileList/FileList.es.js +1 -1
- package/dist/components/FileList/FileListItem.cjs.js +1 -1
- package/dist/components/FileList/FileListItem.es.js +21 -22
- package/dist/components/Heading/Heading.cjs.js +1 -1
- package/dist/components/Heading/Heading.es.js +2 -2
- package/dist/components/ImagePicker/ImagePicker.cjs.js +1 -0
- package/dist/components/ImagePicker/ImagePicker.d.ts +12 -0
- package/dist/components/ImagePicker/ImagePicker.es.js +174 -0
- package/dist/components/ImagePicker/index.cjs.js +1 -0
- package/dist/components/ImagePicker/index.d.ts +2 -0
- package/dist/components/ImagePicker/index.es.js +4 -0
- package/dist/components/Loader/Loader.cjs.js +1 -1
- package/dist/components/Loader/Loader.es.js +2 -2
- package/dist/components/LoaderBackdrop/LoaderBackdrop.cjs.js +1 -1
- package/dist/components/LoaderBackdrop/LoaderBackdrop.es.js +3 -3
- package/dist/components/PasswordInput/PasswordInput.cjs.js +1 -1
- package/dist/components/PasswordInput/PasswordInput.es.js +8 -7
- package/dist/components/SearchInput/SearchInput.cjs.js +1 -1
- package/dist/components/SearchInput/SearchInput.es.js +4 -4
- package/dist/components/TextInput/TextInput.cjs.js +1 -1
- package/dist/components/TextInput/TextInput.es.js +1 -1
- package/dist/components/index.cjs.js +1 -1
- package/dist/components/index.d.ts +3 -0
- package/dist/components/index.es.js +276 -262
- package/dist/components/stories/Button.stories.cjs.js +1 -1
- package/dist/components/stories/Button.stories.es.js +1 -1
- package/dist/components/stories/Card.stories.cjs.js +1 -0
- package/dist/components/stories/Card.stories.d.ts +7 -0
- package/dist/components/stories/Card.stories.es.js +193 -0
- package/dist/components/stories/Checkbox.stories.cjs.js +1 -1
- package/dist/components/stories/Checkbox.stories.es.js +41 -12
- package/dist/components/stories/DatePicker.stories.cjs.js +1 -1
- package/dist/components/stories/DatePicker.stories.es.js +1 -1
- package/dist/components/stories/Dialog.stories.cjs.js +1 -0
- package/dist/components/stories/Dialog.stories.d.ts +7 -0
- package/dist/components/stories/Dialog.stories.es.js +53 -0
- package/dist/components/stories/Divider.stories.cjs.js +1 -0
- package/dist/components/stories/Divider.stories.d.ts +6 -0
- package/dist/components/stories/Divider.stories.es.js +41 -0
- package/dist/components/stories/FormControlLabel.stories.cjs.js +1 -0
- package/dist/components/stories/FormControlLabel.stories.d.ts +9 -0
- package/dist/components/stories/FormControlLabel.stories.es.js +379 -0
- package/dist/components/stories/Heading.stories.cjs.js +1 -1
- package/dist/components/stories/Heading.stories.es.js +2 -2
- package/dist/components/stories/IconButton.stories.cjs.js +1 -1
- package/dist/components/stories/IconButton.stories.es.js +47 -11
- package/dist/components/stories/ImagePicker.stories.cjs.js +1 -0
- package/dist/components/stories/ImagePicker.stories.d.ts +6 -0
- package/dist/components/stories/ImagePicker.stories.es.js +50 -0
- package/dist/components/stories/Link.stories.cjs.js +1 -0
- package/dist/components/stories/Link.stories.d.ts +7 -0
- package/dist/components/stories/Link.stories.es.js +43 -0
- package/dist/components/stories/Menu.stories.cjs.js +1 -0
- package/dist/components/stories/Menu.stories.d.ts +7 -0
- package/dist/components/stories/Menu.stories.es.js +51 -0
- package/dist/components/stories/Paper.stories.cjs.js +1 -0
- package/dist/components/stories/Paper.stories.d.ts +7 -0
- package/dist/components/stories/Paper.stories.es.js +28 -0
- package/dist/components/stories/RadioGroup.stories.cjs.js +1 -1
- package/dist/components/stories/RadioGroup.stories.es.js +70 -371
- package/dist/components/stories/Select.stories.cjs.js +1 -1
- package/dist/components/stories/Select.stories.es.js +3 -3
- package/dist/components/stories/TabList.stories.cjs.js +1 -1
- package/dist/components/stories/TabList.stories.es.js +140 -90
- package/dist/components/stories/TextField.stories.cjs.js +1 -1
- package/dist/components/stories/TextField.stories.es.js +1 -1
- package/dist/components/stories/Tooltip.stories.cjs.js +1 -0
- package/dist/components/stories/Tooltip.stories.d.ts +7 -0
- package/dist/components/stories/Tooltip.stories.es.js +46 -0
- package/dist/components/stories/Typography.stories.cjs.js +1 -0
- package/dist/components/stories/Typography.stories.d.ts +6 -0
- package/dist/components/stories/Typography.stories.es.js +65 -0
- package/dist/createChainedFunction-C0nujS3O.js +9 -0
- package/dist/createChainedFunction-CJmlQuW8.cjs +1 -0
- package/dist/{createSvgIcon-DxbvMQd7.js → createSvgIcon-CeuAoIMQ.js} +6 -5
- package/dist/createSvgIcon-eUfAcV0x.cjs +1 -0
- package/dist/debounce-46wSf_lW.js +15 -0
- package/dist/debounce-DpCj7ugL.cjs +1 -0
- package/dist/dividerClasses-CSD96RzX.cjs +1 -0
- package/dist/dividerClasses-DrJ5oIdP.js +9 -0
- package/dist/elementTypeAcceptingRef-Cz_FeG92.cjs +1 -0
- package/dist/elementTypeAcceptingRef-HBfwF2vD.js +23 -0
- package/dist/extendSxProp-Fr1MMO0I.cjs +1 -0
- package/dist/{extendSxProp-XQwkK0m7.js → extendSxProp-NjjUyYdB.js} +1 -1
- package/dist/formControlState-CuX6WjAX.cjs +1 -0
- package/dist/formControlState-vgaj2ksH.js +10 -0
- package/dist/fr-ChrHtTbj.cjs +1 -0
- package/dist/fr-rmVQsNbI.js +312 -0
- package/dist/{identifier-BqadgaK7.js → generateUtilityClasses--6MLb_cS.js} +990 -956
- package/dist/generateUtilityClasses-DEQ18TAF.cjs +59 -0
- package/dist/{index-BUxqDIr9.js → index-B4GmPutS.js} +6 -5
- package/dist/index-BGCIdIru.js +2152 -0
- package/dist/index-BoQHt8iN.cjs +1 -0
- package/dist/index-CRdsZkOC.cjs +17 -0
- package/dist/index-CmEzEdk2.cjs +5 -0
- package/dist/index-XYfXmNqA.js +186 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +276 -262
- package/dist/isFocusVisible-CPZqtjv2.js +12 -0
- package/dist/isFocusVisible-DlSijby6.cjs +2 -0
- package/dist/isHostComponent-PydJW4A4.cjs +1 -0
- package/dist/isHostComponent-kiaBvYVo.js +6 -0
- package/dist/{memoTheme-B6o2KVgJ.cjs → memoTheme-D99chbOP.cjs} +1 -1
- package/dist/{memoTheme-DfGVDRrB.js → memoTheme-o8RCKrNG.js} +1 -1
- package/dist/mergeSlotProps-DSv3FKLb.cjs +1 -0
- package/dist/{resolveComponentProps-CxJ2yAJn.js → mergeSlotProps-KHPCviGJ.js} +7 -7
- package/dist/ownerDocument-4MViGo3k.cjs +1 -0
- package/dist/ownerDocument-CUrv0DIK.js +6 -0
- package/dist/ownerWindow-DDHucZi0.cjs +1 -0
- package/dist/ownerWindow-niciwP7I.js +7 -0
- package/dist/useEnhancedEffect-C9MKL5N4.cjs +1 -0
- package/dist/useEnhancedEffect-DlS7O_-p.js +7 -0
- package/dist/useForkRef-CTI33h-3.cjs +1 -0
- package/dist/useForkRef-C_4o__cU.js +15 -0
- package/dist/useSlot-DsW0udy9.cjs +1 -0
- package/dist/{useSlot-Co14PUn6.js → useSlot-eWxwpnv1.js} +2 -2
- package/dist/useSlotProps--FPRW1CI.cjs +1 -0
- package/dist/{index-CRT92bm7.js → useSlotProps-C7zjg7t9.js} +26 -26
- package/dist/useTheme-B1YEBlI0.cjs +1 -0
- package/dist/useTheme-BXzyKigM.js +11 -0
- package/dist/{useTheme-oM_SFWy4.js → useTheme-D0ITn2Re.js} +1 -1
- package/dist/useTheme-DFJNv-zn.cjs +1 -0
- package/dist/useThemeProps-BwyYDczI.cjs +1 -0
- package/dist/{useThemeProps-BlQ3SLfB.js → useThemeProps-DrCROxdY.js} +2 -2
- package/dist/{useThemeProps-FiA8ivG-.js → useThemeProps-DsDeaP0E.js} +3 -3
- package/dist/{useThemeProps-HLq2mDKk.cjs → useThemeProps-j-HQOOfB.cjs} +1 -1
- package/dist/{useTimeout-D16vpBhn.js → useTimeout-FkIxJmTC.js} +4 -4
- package/dist/useTimeout-NIA-3R5R.cjs +1 -0
- package/dist/utils-70jLtOQP.js +391 -0
- package/dist/utils-BWx1W_q1.cjs +1 -0
- package/dist/utils-DWqc1kRF.js +13 -0
- package/dist/utils-DlWHEABQ.cjs +1 -0
- package/package.json +5 -5
- package/dist/Backdrop-KAJqifAq.cjs +0 -1
- package/dist/Backdrop-RBPtVAPX.js +0 -744
- package/dist/Box-H49yQEt_.cjs +0 -1
- package/dist/Button-qc45QbX6.cjs +0 -1
- package/dist/ButtonBase-UEHzzfUL.cjs +0 -75
- package/dist/Checkbox-CuYTY0gd.cjs +0 -1
- package/dist/CircularProgress-BPHINMQw.cjs +0 -28
- package/dist/DatePicker-rhgpaD-r.cjs +0 -17
- package/dist/DatePicker-u4rtXGeo.js +0 -12791
- package/dist/DefaultPropsProvider-BrX6iuA3.cjs +0 -17
- package/dist/DefaultPropsProvider-CaRoy5OV.js +0 -484
- package/dist/FormGroup-BBYEQB4C.cjs +0 -1
- package/dist/FormGroup-BVtE8Mrv.js +0 -348
- package/dist/FormLabel-D8jYibc1.cjs +0 -2
- package/dist/IconButton-CVyLtjcH.cjs +0 -2
- package/dist/InputAdornment-BJfpEQAa.cjs +0 -1
- package/dist/InputBase-Ctmib7Br.cjs +0 -3
- package/dist/MenuItem-Els-vJZW.cjs +0 -1
- package/dist/Select-BlPQngVF.js +0 -4720
- package/dist/Select-ipcMZ4iK.cjs +0 -11
- package/dist/Stack-CEjx3KHM.cjs +0 -1
- package/dist/SwitchBase-URM3X3YZ.cjs +0 -1
- package/dist/Tabs-Nvk94RTW.cjs +0 -4
- package/dist/TextField-BVAkADOb.cjs +0 -1
- package/dist/Tooltip-DvPL2M0E.cjs +0 -100
- package/dist/Typography-5OodZ94T.cjs +0 -1
- package/dist/createSvgIcon-GU7fqNnI.cjs +0 -1
- package/dist/extendSxProp-D11-pC6h.cjs +0 -1
- package/dist/formControlState-DCkDUdfO.cjs +0 -1
- package/dist/formControlState-DdQP43Uo.js +0 -21
- package/dist/fr-B8_MxRl5.js +0 -307
- package/dist/fr-Nvp7C-vS.cjs +0 -1
- package/dist/identifier-BQH88SE0.cjs +0 -59
- package/dist/index-CNv8ppur.cjs +0 -1
- package/dist/index-D7nFYLYq.cjs +0 -1
- package/dist/ownerWindow-BoRkeomM.js +0 -23
- package/dist/ownerWindow-Dk_4aaak.cjs +0 -1
- package/dist/refType-DlHf9HvO.js +0 -27
- package/dist/refType-Do7KaOvv.cjs +0 -1
- package/dist/resolveComponentProps-DTv6xPbb.cjs +0 -1
- package/dist/useForkRef-D-DyzOXj.js +0 -21
- package/dist/useForkRef-D81w5oMb.cjs +0 -1
- package/dist/useSlot-42jgZftI.cjs +0 -1
- package/dist/useTheme-CtT7O-Wk.js +0 -11
- package/dist/useTheme-cVN-YQNB.cjs +0 -1
- package/dist/useTheme-tZYpFplW.cjs +0 -1
- package/dist/useThemeProps-r0DnR8FJ.cjs +0 -1
- package/dist/useTimeout-DWEGwfTA.cjs +0 -1
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
import * as P from "react";
|
|
2
|
+
import { H as E, I as U, G as v, P as e } from "./generateUtilityClasses--6MLb_cS.js";
|
|
3
|
+
import { m as L } from "./memoTheme-o8RCKrNG.js";
|
|
4
|
+
import { f as A } from "./formControlState-vgaj2ksH.js";
|
|
5
|
+
import { u as H } from "./useSlot-eWxwpnv1.js";
|
|
6
|
+
import { jsx as I, jsxs as g } from "react/jsx-runtime";
|
|
7
|
+
import { s as R, u as z, c as B } from "./DefaultPropsProvider-DUWovK-8.js";
|
|
8
|
+
import { c as x } from "./capitalize-NmHVRYy8.js";
|
|
9
|
+
import { u as G } from "./useFormControl-CatNKXAi.js";
|
|
10
|
+
import { T } from "./Typography-DWXYj92v.js";
|
|
11
|
+
import { r as V } from "./useEnhancedEffect-DlS7O_-p.js";
|
|
12
|
+
function W(o) {
|
|
13
|
+
return E("MuiFormControlLabel", o);
|
|
14
|
+
}
|
|
15
|
+
const a = U("MuiFormControlLabel", ["root", "labelPlacementStart", "labelPlacementTop", "labelPlacementBottom", "disabled", "label", "error", "required", "asterisk"]), _ = (o) => {
|
|
16
|
+
const {
|
|
17
|
+
classes: r,
|
|
18
|
+
disabled: s,
|
|
19
|
+
labelPlacement: t,
|
|
20
|
+
error: d,
|
|
21
|
+
required: b
|
|
22
|
+
} = o, f = {
|
|
23
|
+
root: ["root", s && "disabled", `labelPlacement${x(t)}`, d && "error", b && "required"],
|
|
24
|
+
label: ["label", s && "disabled"],
|
|
25
|
+
asterisk: ["asterisk", d && "error"]
|
|
26
|
+
};
|
|
27
|
+
return B(f, W, r);
|
|
28
|
+
}, J = R("label", {
|
|
29
|
+
name: "MuiFormControlLabel",
|
|
30
|
+
slot: "Root",
|
|
31
|
+
overridesResolver: (o, r) => {
|
|
32
|
+
const {
|
|
33
|
+
ownerState: s
|
|
34
|
+
} = o;
|
|
35
|
+
return [{
|
|
36
|
+
[`& .${a.label}`]: r.label
|
|
37
|
+
}, r.root, r[`labelPlacement${x(s.labelPlacement)}`]];
|
|
38
|
+
}
|
|
39
|
+
})(L(({
|
|
40
|
+
theme: o
|
|
41
|
+
}) => ({
|
|
42
|
+
display: "inline-flex",
|
|
43
|
+
alignItems: "center",
|
|
44
|
+
cursor: "pointer",
|
|
45
|
+
// For correct alignment with the text.
|
|
46
|
+
verticalAlign: "middle",
|
|
47
|
+
WebkitTapHighlightColor: "transparent",
|
|
48
|
+
marginLeft: -11,
|
|
49
|
+
marginRight: 16,
|
|
50
|
+
// used for row presentation of radio/checkbox
|
|
51
|
+
[`&.${a.disabled}`]: {
|
|
52
|
+
cursor: "default"
|
|
53
|
+
},
|
|
54
|
+
[`& .${a.label}`]: {
|
|
55
|
+
[`&.${a.disabled}`]: {
|
|
56
|
+
color: (o.vars || o).palette.text.disabled
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
variants: [{
|
|
60
|
+
props: {
|
|
61
|
+
labelPlacement: "start"
|
|
62
|
+
},
|
|
63
|
+
style: {
|
|
64
|
+
flexDirection: "row-reverse",
|
|
65
|
+
marginRight: -11
|
|
66
|
+
}
|
|
67
|
+
}, {
|
|
68
|
+
props: {
|
|
69
|
+
labelPlacement: "top"
|
|
70
|
+
},
|
|
71
|
+
style: {
|
|
72
|
+
flexDirection: "column-reverse"
|
|
73
|
+
}
|
|
74
|
+
}, {
|
|
75
|
+
props: {
|
|
76
|
+
labelPlacement: "bottom"
|
|
77
|
+
},
|
|
78
|
+
style: {
|
|
79
|
+
flexDirection: "column"
|
|
80
|
+
}
|
|
81
|
+
}, {
|
|
82
|
+
props: ({
|
|
83
|
+
labelPlacement: r
|
|
84
|
+
}) => r === "start" || r === "top" || r === "bottom",
|
|
85
|
+
style: {
|
|
86
|
+
marginLeft: 16
|
|
87
|
+
// used for row presentation of radio/checkbox
|
|
88
|
+
}
|
|
89
|
+
}]
|
|
90
|
+
}))), K = R("span", {
|
|
91
|
+
name: "MuiFormControlLabel",
|
|
92
|
+
slot: "Asterisk",
|
|
93
|
+
overridesResolver: (o, r) => r.asterisk
|
|
94
|
+
})(L(({
|
|
95
|
+
theme: o
|
|
96
|
+
}) => ({
|
|
97
|
+
[`&.${a.error}`]: {
|
|
98
|
+
color: (o.vars || o).palette.error.main
|
|
99
|
+
}
|
|
100
|
+
}))), Q = /* @__PURE__ */ P.forwardRef(function(r, s) {
|
|
101
|
+
const t = z({
|
|
102
|
+
props: r,
|
|
103
|
+
name: "MuiFormControlLabel"
|
|
104
|
+
}), {
|
|
105
|
+
checked: d,
|
|
106
|
+
className: b,
|
|
107
|
+
componentsProps: f = {},
|
|
108
|
+
control: n,
|
|
109
|
+
disabled: F,
|
|
110
|
+
disableTypography: q,
|
|
111
|
+
inputRef: X,
|
|
112
|
+
label: k,
|
|
113
|
+
labelPlacement: N = "end",
|
|
114
|
+
name: Y,
|
|
115
|
+
onChange: Z,
|
|
116
|
+
required: j,
|
|
117
|
+
slots: w = {},
|
|
118
|
+
slotProps: S = {},
|
|
119
|
+
value: ee,
|
|
120
|
+
...$
|
|
121
|
+
} = t, i = G(), h = F ?? n.props.disabled ?? (i == null ? void 0 : i.disabled), u = j ?? n.props.required, C = {
|
|
122
|
+
disabled: h,
|
|
123
|
+
required: u
|
|
124
|
+
};
|
|
125
|
+
["checked", "name", "onChange", "value", "inputRef"].forEach((m) => {
|
|
126
|
+
typeof n.props[m] > "u" && typeof t[m] < "u" && (C[m] = t[m]);
|
|
127
|
+
});
|
|
128
|
+
const O = A({
|
|
129
|
+
props: t,
|
|
130
|
+
muiFormControl: i,
|
|
131
|
+
states: ["error"]
|
|
132
|
+
}), p = {
|
|
133
|
+
...t,
|
|
134
|
+
disabled: h,
|
|
135
|
+
labelPlacement: N,
|
|
136
|
+
required: u,
|
|
137
|
+
error: O.error
|
|
138
|
+
}, y = _(p), D = {
|
|
139
|
+
slots: w,
|
|
140
|
+
slotProps: {
|
|
141
|
+
...f,
|
|
142
|
+
...S
|
|
143
|
+
}
|
|
144
|
+
}, [M, c] = H("typography", {
|
|
145
|
+
elementType: T,
|
|
146
|
+
externalForwardedProps: D,
|
|
147
|
+
ownerState: p
|
|
148
|
+
});
|
|
149
|
+
let l = k;
|
|
150
|
+
return l != null && l.type !== T && !q && (l = /* @__PURE__ */ I(M, {
|
|
151
|
+
component: "span",
|
|
152
|
+
...c,
|
|
153
|
+
className: v(y.label, c == null ? void 0 : c.className),
|
|
154
|
+
children: l
|
|
155
|
+
})), /* @__PURE__ */ g(J, {
|
|
156
|
+
className: v(y.root, b),
|
|
157
|
+
ownerState: p,
|
|
158
|
+
ref: s,
|
|
159
|
+
...$,
|
|
160
|
+
children: [/* @__PURE__ */ P.cloneElement(n, C), u ? /* @__PURE__ */ g("div", {
|
|
161
|
+
children: [l, /* @__PURE__ */ g(K, {
|
|
162
|
+
ownerState: p,
|
|
163
|
+
"aria-hidden": !0,
|
|
164
|
+
className: y.asterisk,
|
|
165
|
+
children: [" ", "*"]
|
|
166
|
+
})]
|
|
167
|
+
}) : l]
|
|
168
|
+
});
|
|
169
|
+
});
|
|
170
|
+
process.env.NODE_ENV !== "production" && (Q.propTypes = {
|
|
171
|
+
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
172
|
+
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
173
|
+
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
174
|
+
// └─────────────────────────────────────────────────────────────────────┘
|
|
175
|
+
/**
|
|
176
|
+
* If `true`, the component appears selected.
|
|
177
|
+
*/
|
|
178
|
+
checked: e.bool,
|
|
179
|
+
/**
|
|
180
|
+
* Override or extend the styles applied to the component.
|
|
181
|
+
*/
|
|
182
|
+
classes: e.object,
|
|
183
|
+
/**
|
|
184
|
+
* @ignore
|
|
185
|
+
*/
|
|
186
|
+
className: e.string,
|
|
187
|
+
/**
|
|
188
|
+
* The props used for each slot inside.
|
|
189
|
+
* @default {}
|
|
190
|
+
* @deprecated use the `slotProps` prop instead. This prop will be removed in v7. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
191
|
+
*/
|
|
192
|
+
componentsProps: e.shape({
|
|
193
|
+
typography: e.object
|
|
194
|
+
}),
|
|
195
|
+
/**
|
|
196
|
+
* A control element. For instance, it can be a `Radio`, a `Switch` or a `Checkbox`.
|
|
197
|
+
*/
|
|
198
|
+
control: e.element.isRequired,
|
|
199
|
+
/**
|
|
200
|
+
* If `true`, the control is disabled.
|
|
201
|
+
*/
|
|
202
|
+
disabled: e.bool,
|
|
203
|
+
/**
|
|
204
|
+
* If `true`, the label is rendered as it is passed without an additional typography node.
|
|
205
|
+
*/
|
|
206
|
+
disableTypography: e.bool,
|
|
207
|
+
/**
|
|
208
|
+
* Pass a ref to the `input` element.
|
|
209
|
+
*/
|
|
210
|
+
inputRef: V,
|
|
211
|
+
/**
|
|
212
|
+
* A text or an element to be used in an enclosing label element.
|
|
213
|
+
*/
|
|
214
|
+
label: e.node,
|
|
215
|
+
/**
|
|
216
|
+
* The position of the label.
|
|
217
|
+
* @default 'end'
|
|
218
|
+
*/
|
|
219
|
+
labelPlacement: e.oneOf(["bottom", "end", "start", "top"]),
|
|
220
|
+
/**
|
|
221
|
+
* @ignore
|
|
222
|
+
*/
|
|
223
|
+
name: e.string,
|
|
224
|
+
/**
|
|
225
|
+
* Callback fired when the state is changed.
|
|
226
|
+
*
|
|
227
|
+
* @param {React.SyntheticEvent} event The event source of the callback.
|
|
228
|
+
* You can pull out the new checked state by accessing `event.target.checked` (boolean).
|
|
229
|
+
*/
|
|
230
|
+
onChange: e.func,
|
|
231
|
+
/**
|
|
232
|
+
* If `true`, the label will indicate that the `input` is required.
|
|
233
|
+
*/
|
|
234
|
+
required: e.bool,
|
|
235
|
+
/**
|
|
236
|
+
* The props used for each slot inside.
|
|
237
|
+
* @default {}
|
|
238
|
+
*/
|
|
239
|
+
slotProps: e.shape({
|
|
240
|
+
typography: e.oneOfType([e.func, e.object])
|
|
241
|
+
}),
|
|
242
|
+
/**
|
|
243
|
+
* The components used for each slot inside.
|
|
244
|
+
* @default {}
|
|
245
|
+
*/
|
|
246
|
+
slots: e.shape({
|
|
247
|
+
typography: e.elementType
|
|
248
|
+
}),
|
|
249
|
+
/**
|
|
250
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
251
|
+
*/
|
|
252
|
+
sx: e.oneOfType([e.arrayOf(e.oneOfType([e.func, e.object, e.bool])), e.func, e.object]),
|
|
253
|
+
/**
|
|
254
|
+
* The value of the component.
|
|
255
|
+
*/
|
|
256
|
+
value: e.any
|
|
257
|
+
});
|
|
258
|
+
export {
|
|
259
|
+
Q as F,
|
|
260
|
+
a as f,
|
|
261
|
+
W as g
|
|
262
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const U=require("react"),e=require("./generateUtilityClasses-DEQ18TAF.cjs"),v=require("./memoTheme-D99chbOP.cjs"),z=require("./formControlState-CuX6WjAX.cjs"),_=require("./useSlot-DsW0udy9.cjs"),u=require("react/jsx-runtime"),m=require("./DefaultPropsProvider-DE-Tx_ov.cjs"),L=require("./capitalize-DASFtB-F.cjs"),A=require("./useFormControl-haP0iPhl.cjs"),C=require("./Typography-B6KFjCtE.cjs"),B=require("./useEnhancedEffect-C9MKL5N4.cjs");function H(o){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const t in o)if(t!=="default"){const s=Object.getOwnPropertyDescriptor(o,t);Object.defineProperty(r,t,s.get?s:{enumerable:!0,get:()=>o[t]})}}return r.default=o,Object.freeze(r)}const q=H(U);function j(o){return e.generateUtilityClass("MuiFormControlLabel",o)}const a=e.generateUtilityClasses("MuiFormControlLabel",["root","labelPlacementStart","labelPlacementTop","labelPlacementBottom","disabled","label","error","required","asterisk"]),I=o=>{const{classes:r,disabled:t,labelPlacement:s,error:b,required:y}=o,P={root:["root",t&&"disabled",`labelPlacement${L.capitalize(s)}`,b&&"error",y&&"required"],label:["label",t&&"disabled"],asterisk:["asterisk",b&&"error"]};return m.composeClasses(P,j,r)},V=m.styled("label",{name:"MuiFormControlLabel",slot:"Root",overridesResolver:(o,r)=>{const{ownerState:t}=o;return[{[`& .${a.label}`]:r.label},r.root,r[`labelPlacement${L.capitalize(t.labelPlacement)}`]]}})(v.memoTheme(({theme:o})=>({display:"inline-flex",alignItems:"center",cursor:"pointer",verticalAlign:"middle",WebkitTapHighlightColor:"transparent",marginLeft:-11,marginRight:16,[`&.${a.disabled}`]:{cursor:"default"},[`& .${a.label}`]:{[`&.${a.disabled}`]:{color:(o.vars||o).palette.text.disabled}},variants:[{props:{labelPlacement:"start"},style:{flexDirection:"row-reverse",marginRight:-11}},{props:{labelPlacement:"top"},style:{flexDirection:"column-reverse"}},{props:{labelPlacement:"bottom"},style:{flexDirection:"column"}},{props:({labelPlacement:r})=>r==="start"||r==="top"||r==="bottom",style:{marginLeft:16}}]}))),W=m.styled("span",{name:"MuiFormControlLabel",slot:"Asterisk",overridesResolver:(o,r)=>r.asterisk})(v.memoTheme(({theme:o})=>({[`&.${a.error}`]:{color:(o.vars||o).palette.error.main}}))),x=q.forwardRef(function(r,t){const s=m.useDefaultProps({props:r,name:"MuiFormControlLabel"}),{checked:b,className:y,componentsProps:P={},control:n,disabled:R,disableTypography:F,inputRef:G,label:O,labelPlacement:S="end",name:J,onChange:K,required:k,slots:N={},slotProps:w={},value:Q,...D}=s,p=A.useFormControl(),g=R??n.props.disabled??(p==null?void 0:p.disabled),f=k??n.props.required,h={disabled:g,required:f};["checked","name","onChange","value","inputRef"].forEach(d=>{typeof n.props[d]>"u"&&typeof s[d]<"u"&&(h[d]=s[d])});const $=z.formControlState({props:s,muiFormControl:p,states:["error"]}),i={...s,disabled:g,labelPlacement:S,required:f,error:$.error},T=I(i),E={slots:N,slotProps:{...P,...w}},[M,c]=_.useSlot("typography",{elementType:C.Typography,externalForwardedProps:E,ownerState:i});let l=O;return l!=null&&l.type!==C.Typography&&!F&&(l=u.jsx(M,{component:"span",...c,className:e.clsx(T.label,c==null?void 0:c.className),children:l})),u.jsxs(V,{className:e.clsx(T.root,y),ownerState:i,ref:t,...D,children:[q.cloneElement(n,h),f?u.jsxs("div",{children:[l,u.jsxs(W,{ownerState:i,"aria-hidden":!0,className:T.asterisk,children:[" ","*"]})]}):l]})});process.env.NODE_ENV!=="production"&&(x.propTypes={checked:e.PropTypes.bool,classes:e.PropTypes.object,className:e.PropTypes.string,componentsProps:e.PropTypes.shape({typography:e.PropTypes.object}),control:e.PropTypes.element.isRequired,disabled:e.PropTypes.bool,disableTypography:e.PropTypes.bool,inputRef:B.refType,label:e.PropTypes.node,labelPlacement:e.PropTypes.oneOf(["bottom","end","start","top"]),name:e.PropTypes.string,onChange:e.PropTypes.func,required:e.PropTypes.bool,slotProps:e.PropTypes.shape({typography:e.PropTypes.oneOfType([e.PropTypes.func,e.PropTypes.object])}),slots:e.PropTypes.shape({typography:e.PropTypes.elementType}),sx:e.PropTypes.oneOfType([e.PropTypes.arrayOf(e.PropTypes.oneOfType([e.PropTypes.func,e.PropTypes.object,e.PropTypes.bool])),e.PropTypes.func,e.PropTypes.object]),value:e.PropTypes.any});exports.FormControlLabel=x;exports.formControlLabelClasses=a;exports.getFormControlLabelUtilityClasses=j;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const P=require("react"),o=require("./generateUtilityClasses-DEQ18TAF.cjs"),T=require("./useFormControl-haP0iPhl.cjs"),d=require("./formControlState-CuX6WjAX.cjs"),w=require("react/jsx-runtime"),p=require("./DefaultPropsProvider-DE-Tx_ov.cjs");function C(r){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const t in r)if(t!=="default"){const s=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,s.get?s:{enumerable:!0,get:()=>r[t]})}}return e.default=r,Object.freeze(e)}const F=C(P);function a(r){return o.generateUtilityClass("MuiFormGroup",r)}const G=o.generateUtilityClasses("MuiFormGroup",["root","row","error"]),b=r=>{const{classes:e,row:t,error:s}=r,n={root:["root",t&&"row",s&&"error"]};return p.composeClasses(n,a,e)},g=p.styled("div",{name:"MuiFormGroup",slot:"Root",overridesResolver:(r,e)=>{const{ownerState:t}=r;return[e.root,t.row&&e.row]}})({display:"flex",flexDirection:"column",flexWrap:"wrap",variants:[{props:{row:!0},style:{flexDirection:"row"}}]}),l=F.forwardRef(function(e,t){const s=p.useDefaultProps({props:e,name:"MuiFormGroup"}),{className:n,row:u=!1,...i}=s,f=T.useFormControl(),m=d.formControlState({props:s,muiFormControl:f,states:["error"]}),c={...s,row:u,error:m.error},y=b(c);return w.jsx(g,{className:o.clsx(y.root,n),ownerState:c,ref:t,...i})});process.env.NODE_ENV!=="production"&&(l.propTypes={children:o.PropTypes.node,classes:o.PropTypes.object,className:o.PropTypes.string,row:o.PropTypes.bool,sx:o.PropTypes.oneOfType([o.PropTypes.arrayOf(o.PropTypes.oneOfType([o.PropTypes.func,o.PropTypes.object,o.PropTypes.bool])),o.PropTypes.func,o.PropTypes.object])});exports.FormGroup=l;exports.formGroupClasses=G;exports.getFormGroupUtilityClass=a;
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import * as u from "react";
|
|
2
|
+
import { H as f, I as w, G as y, P as o } from "./generateUtilityClasses--6MLb_cS.js";
|
|
3
|
+
import { u as F } from "./useFormControl-CatNKXAi.js";
|
|
4
|
+
import { f as G } from "./formControlState-vgaj2ksH.js";
|
|
5
|
+
import { jsx as d } from "react/jsx-runtime";
|
|
6
|
+
import { s as C, u as x, c as v } from "./DefaultPropsProvider-DUWovK-8.js";
|
|
7
|
+
function b(r) {
|
|
8
|
+
return f("MuiFormGroup", r);
|
|
9
|
+
}
|
|
10
|
+
const T = w("MuiFormGroup", ["root", "row", "error"]), g = (r) => {
|
|
11
|
+
const {
|
|
12
|
+
classes: s,
|
|
13
|
+
row: e,
|
|
14
|
+
error: t
|
|
15
|
+
} = r;
|
|
16
|
+
return v({
|
|
17
|
+
root: ["root", e && "row", t && "error"]
|
|
18
|
+
}, b, s);
|
|
19
|
+
}, N = C("div", {
|
|
20
|
+
name: "MuiFormGroup",
|
|
21
|
+
slot: "Root",
|
|
22
|
+
overridesResolver: (r, s) => {
|
|
23
|
+
const {
|
|
24
|
+
ownerState: e
|
|
25
|
+
} = r;
|
|
26
|
+
return [s.root, e.row && s.row];
|
|
27
|
+
}
|
|
28
|
+
})({
|
|
29
|
+
display: "flex",
|
|
30
|
+
flexDirection: "column",
|
|
31
|
+
flexWrap: "wrap",
|
|
32
|
+
variants: [{
|
|
33
|
+
props: {
|
|
34
|
+
row: !0
|
|
35
|
+
},
|
|
36
|
+
style: {
|
|
37
|
+
flexDirection: "row"
|
|
38
|
+
}
|
|
39
|
+
}]
|
|
40
|
+
}), R = /* @__PURE__ */ u.forwardRef(function(s, e) {
|
|
41
|
+
const t = x({
|
|
42
|
+
props: s,
|
|
43
|
+
name: "MuiFormGroup"
|
|
44
|
+
}), {
|
|
45
|
+
className: a,
|
|
46
|
+
row: c = !1,
|
|
47
|
+
...l
|
|
48
|
+
} = t, p = F(), i = G({
|
|
49
|
+
props: t,
|
|
50
|
+
muiFormControl: p,
|
|
51
|
+
states: ["error"]
|
|
52
|
+
}), n = {
|
|
53
|
+
...t,
|
|
54
|
+
row: c,
|
|
55
|
+
error: i.error
|
|
56
|
+
}, m = g(n);
|
|
57
|
+
return /* @__PURE__ */ d(N, {
|
|
58
|
+
className: y(m.root, a),
|
|
59
|
+
ownerState: n,
|
|
60
|
+
ref: e,
|
|
61
|
+
...l
|
|
62
|
+
});
|
|
63
|
+
});
|
|
64
|
+
process.env.NODE_ENV !== "production" && (R.propTypes = {
|
|
65
|
+
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
66
|
+
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
67
|
+
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
68
|
+
// └─────────────────────────────────────────────────────────────────────┘
|
|
69
|
+
/**
|
|
70
|
+
* The content of the component.
|
|
71
|
+
*/
|
|
72
|
+
children: o.node,
|
|
73
|
+
/**
|
|
74
|
+
* Override or extend the styles applied to the component.
|
|
75
|
+
*/
|
|
76
|
+
classes: o.object,
|
|
77
|
+
/**
|
|
78
|
+
* @ignore
|
|
79
|
+
*/
|
|
80
|
+
className: o.string,
|
|
81
|
+
/**
|
|
82
|
+
* Display group of elements in a compact row.
|
|
83
|
+
* @default false
|
|
84
|
+
*/
|
|
85
|
+
row: o.bool,
|
|
86
|
+
/**
|
|
87
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
88
|
+
*/
|
|
89
|
+
sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
|
|
90
|
+
});
|
|
91
|
+
export {
|
|
92
|
+
R as F,
|
|
93
|
+
T as f,
|
|
94
|
+
b as g
|
|
95
|
+
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";const J=require("react"),e=require("./generateUtilityClasses-DEQ18TAF.cjs"),x=require("./utils-BWx1W_q1.cjs"),k=require("./useFormControl-haP0iPhl.cjs"),O=require("react/jsx-runtime"),u=require("./DefaultPropsProvider-DE-Tx_ov.cjs"),L=require("./capitalize-DASFtB-F.cjs"),K=require("./formControlState-CuX6WjAX.cjs"),$=require("./memoTheme-D99chbOP.cjs"),Q=require("./createSimplePaletteValueFilter-PTK3TAhW.cjs");function X(o){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const s in o)if(s!=="default"){const t=Object.getOwnPropertyDescriptor(o,s);Object.defineProperty(r,s,t.get?t:{enumerable:!0,get:()=>o[s]})}}return r.default=o,Object.freeze(r)}const i=X(J);function v(o,r){var s,t,l;return i.isValidElement(o)&&r.indexOf(o.type.muiName??((l=(t=(s=o.type)==null?void 0:s._payload)==null?void 0:t.value)==null?void 0:l.muiName))!==-1}function z(o){return e.generateUtilityClass("MuiFormControl",o)}const Y=e.generateUtilityClasses("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]),Z=o=>{const{classes:r,margin:s,fullWidth:t}=o,l={root:["root",s!=="none"&&`margin${L.capitalize(s)}`,t&&"fullWidth"]};return u.composeClasses(l,z,r)},ee=u.styled("div",{name:"MuiFormControl",slot:"Root",overridesResolver:({ownerState:o},r)=>({...r.root,...r[`margin${L.capitalize(o.margin)}`],...o.fullWidth&&r.fullWidth})})({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top",variants:[{props:{margin:"normal"},style:{marginTop:16,marginBottom:8}},{props:{margin:"dense"},style:{marginTop:8,marginBottom:4}},{props:{fullWidth:!0},style:{width:"100%"}}]}),_=i.forwardRef(function(r,s){const t=u.useDefaultProps({props:r,name:"MuiFormControl"}),{children:l,className:f,color:m="primary",component:c="div",disabled:a=!1,error:P=!1,focused:S,fullWidth:g=!1,hiddenLabel:C=!1,margin:q="none",required:y=!1,size:n="medium",variant:d="outlined",...F}=t,M={...t,color:m,component:c,disabled:a,error:P,fullWidth:g,hiddenLabel:C,margin:q,required:y,size:n,variant:d},B=Z(M),[R,H]=i.useState(()=>{let T=!1;return l&&i.Children.forEach(l,p=>{if(!v(p,["Input","Select"]))return;const W=v(p,["Select"])?p.props.input:p;W&&x.isAdornedStart(W.props)&&(T=!0)}),T}),[E,U]=i.useState(()=>{let T=!1;return l&&i.Children.forEach(l,p=>{v(p,["Input","Select"])&&(x.isFilled(p.props,!0)||x.isFilled(p.props.inputProps,!0))&&(T=!0)}),T}),[D,h]=i.useState(!1);a&&D&&h(!1);const w=S!==void 0&&!a?S:D;let N;const j=i.useRef(!1);process.env.NODE_ENV!=="production"&&(N=()=>(j.current&&console.error(["MUI: There are multiple `InputBase` components inside a FormControl.","This creates visual inconsistencies, only use one `InputBase`."].join(`
|
|
2
|
+
`)),j.current=!0,()=>{j.current=!1}));const G=i.useMemo(()=>({adornedStart:R,setAdornedStart:H,color:m,disabled:a,error:P,filled:E,focused:w,fullWidth:g,hiddenLabel:C,size:n,onBlur:()=>{h(!1)},onEmpty:()=>{U(!1)},onFilled:()=>{U(!0)},onFocus:()=>{h(!0)},registerEffect:N,required:y,variant:d}),[R,m,a,P,E,w,g,C,N,y,n,d]);return O.jsx(k.FormControlContext.Provider,{value:G,children:O.jsx(ee,{as:c,ownerState:M,className:e.clsx(B.root,f),ref:s,...F,children:l})})});process.env.NODE_ENV!=="production"&&(_.propTypes={children:e.PropTypes.node,classes:e.PropTypes.object,className:e.PropTypes.string,color:e.PropTypes.oneOfType([e.PropTypes.oneOf(["primary","secondary","error","info","success","warning"]),e.PropTypes.string]),component:e.PropTypes.elementType,disabled:e.PropTypes.bool,error:e.PropTypes.bool,focused:e.PropTypes.bool,fullWidth:e.PropTypes.bool,hiddenLabel:e.PropTypes.bool,margin:e.PropTypes.oneOf(["dense","none","normal"]),required:e.PropTypes.bool,size:e.PropTypes.oneOfType([e.PropTypes.oneOf(["medium","small"]),e.PropTypes.string]),sx:e.PropTypes.oneOfType([e.PropTypes.arrayOf(e.PropTypes.oneOfType([e.PropTypes.func,e.PropTypes.object,e.PropTypes.bool])),e.PropTypes.func,e.PropTypes.object]),variant:e.PropTypes.oneOf(["filled","outlined","standard"])});function A(o){return e.generateUtilityClass("MuiFormLabel",o)}const b=e.generateUtilityClasses("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),oe=o=>{const{classes:r,color:s,focused:t,disabled:l,error:f,filled:m,required:c}=o,a={root:["root",`color${L.capitalize(s)}`,l&&"disabled",f&&"error",m&&"filled",t&&"focused",c&&"required"],asterisk:["asterisk",f&&"error"]};return u.composeClasses(a,A,r)},I=u.styled("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:({ownerState:o},r)=>({...r.root,...o.color==="secondary"&&r.colorSecondary,...o.filled&&r.filled})})($.memoTheme(({theme:o})=>({color:(o.vars||o).palette.text.secondary,...o.typography.body1,lineHeight:"1.4375em",padding:0,position:"relative",variants:[...Object.entries(o.palette).filter(Q.createSimplePaletteValueFilter()).map(([r])=>({props:{color:r},style:{[`&.${b.focused}`]:{color:(o.vars||o).palette[r].main}}})),{props:{},style:{[`&.${b.disabled}`]:{color:(o.vars||o).palette.text.disabled},[`&.${b.error}`]:{color:(o.vars||o).palette.error.main}}}]}))),re=u.styled("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(o,r)=>r.asterisk})($.memoTheme(({theme:o})=>({[`&.${b.error}`]:{color:(o.vars||o).palette.error.main}}))),V=i.forwardRef(function(r,s){const t=u.useDefaultProps({props:r,name:"MuiFormLabel"}),{children:l,className:f,color:m,component:c="label",disabled:a,error:P,filled:S,focused:g,required:C,...q}=t,y=k.useFormControl(),n=K.formControlState({props:t,muiFormControl:y,states:["color","required","focused","disabled","error","filled"]}),d={...t,color:n.color||"primary",component:c,disabled:n.disabled,error:n.error,filled:n.filled,focused:n.focused,required:n.required},F=oe(d);return O.jsxs(I,{as:c,ownerState:d,className:e.clsx(F.root,f),ref:s,...q,children:[l,n.required&&O.jsxs(re,{ownerState:d,"aria-hidden":!0,className:F.asterisk,children:[" ","*"]})]})});process.env.NODE_ENV!=="production"&&(V.propTypes={children:e.PropTypes.node,classes:e.PropTypes.object,className:e.PropTypes.string,color:e.PropTypes.oneOfType([e.PropTypes.oneOf(["error","info","primary","secondary","success","warning"]),e.PropTypes.string]),component:e.PropTypes.elementType,disabled:e.PropTypes.bool,error:e.PropTypes.bool,filled:e.PropTypes.bool,focused:e.PropTypes.bool,required:e.PropTypes.bool,sx:e.PropTypes.oneOfType([e.PropTypes.arrayOf(e.PropTypes.oneOfType([e.PropTypes.func,e.PropTypes.object,e.PropTypes.bool])),e.PropTypes.func,e.PropTypes.object])});exports.FormControl=_;exports.FormLabel=V;exports.FormLabelRoot=I;exports.formControlClasses=Y;exports.formLabelClasses=b;exports.getFormControlUtilityClasses=z;exports.getFormLabelUtilityClasses=A;exports.isMuiElement=v;
|
|
@@ -1,36 +1,32 @@
|
|
|
1
1
|
import * as i from "react";
|
|
2
|
-
import {
|
|
3
|
-
import { a as
|
|
4
|
-
import { F as
|
|
2
|
+
import { H as A, I as D, G as P, P as e } from "./generateUtilityClasses--6MLb_cS.js";
|
|
3
|
+
import { a as J, i as k } from "./utils-DWqc1kRF.js";
|
|
4
|
+
import { F as K, u as Q } from "./useFormControl-CatNKXAi.js";
|
|
5
5
|
import { jsx as I, jsxs as U } from "react/jsx-runtime";
|
|
6
|
-
import { s as E, u as B, c as V } from "./DefaultPropsProvider-
|
|
7
|
-
import {
|
|
6
|
+
import { s as E, u as B, c as V } from "./DefaultPropsProvider-DUWovK-8.js";
|
|
7
|
+
import { c as L } from "./capitalize-NmHVRYy8.js";
|
|
8
|
+
import { f as X } from "./formControlState-vgaj2ksH.js";
|
|
9
|
+
import { m as _ } from "./memoTheme-o8RCKrNG.js";
|
|
8
10
|
import { c as Y } from "./createSimplePaletteValueFilter-B7--0ryQ.js";
|
|
9
|
-
function be(...o) {
|
|
10
|
-
return o.reduce((r, t) => t == null ? r : function(...s) {
|
|
11
|
-
r.apply(this, s), t.apply(this, s);
|
|
12
|
-
}, () => {
|
|
13
|
-
});
|
|
14
|
-
}
|
|
15
11
|
function x(o, r) {
|
|
16
|
-
var
|
|
12
|
+
var n, t, s;
|
|
17
13
|
return /* @__PURE__ */ i.isValidElement(o) && r.indexOf(
|
|
18
14
|
// For server components `muiName` is avaialble in element.type._payload.value.muiName
|
|
19
15
|
// relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45
|
|
20
16
|
// eslint-disable-next-line no-underscore-dangle
|
|
21
|
-
o.type.muiName ?? ((s = (
|
|
17
|
+
o.type.muiName ?? ((s = (t = (n = o.type) == null ? void 0 : n._payload) == null ? void 0 : t.value) == null ? void 0 : s.muiName)
|
|
22
18
|
) !== -1;
|
|
23
19
|
}
|
|
24
20
|
function Z(o) {
|
|
25
21
|
return A("MuiFormControl", o);
|
|
26
22
|
}
|
|
27
|
-
const
|
|
23
|
+
const ge = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDense", "fullWidth", "disabled"]), ee = (o) => {
|
|
28
24
|
const {
|
|
29
25
|
classes: r,
|
|
30
|
-
margin:
|
|
31
|
-
fullWidth:
|
|
26
|
+
margin: n,
|
|
27
|
+
fullWidth: t
|
|
32
28
|
} = o, s = {
|
|
33
|
-
root: ["root",
|
|
29
|
+
root: ["root", n !== "none" && `margin${L(n)}`, t && "fullWidth"]
|
|
34
30
|
};
|
|
35
31
|
return V(s, Z, r);
|
|
36
32
|
}, oe = E("div", {
|
|
@@ -78,8 +74,8 @@ const ye = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDen
|
|
|
78
74
|
width: "100%"
|
|
79
75
|
}
|
|
80
76
|
}]
|
|
81
|
-
}), re = /* @__PURE__ */ i.forwardRef(function(r,
|
|
82
|
-
const
|
|
77
|
+
}), re = /* @__PURE__ */ i.forwardRef(function(r, n) {
|
|
78
|
+
const t = B({
|
|
83
79
|
props: r,
|
|
84
80
|
name: "MuiFormControl"
|
|
85
81
|
}), {
|
|
@@ -89,23 +85,23 @@ const ye = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDen
|
|
|
89
85
|
component: c = "div",
|
|
90
86
|
disabled: a = !1,
|
|
91
87
|
error: y = !1,
|
|
92
|
-
focused:
|
|
88
|
+
focused: O,
|
|
93
89
|
fullWidth: g = !1,
|
|
94
90
|
hiddenLabel: F = !1,
|
|
95
|
-
margin:
|
|
91
|
+
margin: h = "none",
|
|
96
92
|
required: m = !1,
|
|
97
93
|
size: l = "medium",
|
|
98
94
|
variant: u = "outlined",
|
|
99
95
|
...v
|
|
100
|
-
} =
|
|
101
|
-
...
|
|
96
|
+
} = t, M = {
|
|
97
|
+
...t,
|
|
102
98
|
color: p,
|
|
103
99
|
component: c,
|
|
104
100
|
disabled: a,
|
|
105
101
|
error: y,
|
|
106
102
|
fullWidth: g,
|
|
107
103
|
hiddenLabel: F,
|
|
108
|
-
margin:
|
|
104
|
+
margin: h,
|
|
109
105
|
required: m,
|
|
110
106
|
size: l,
|
|
111
107
|
variant: u
|
|
@@ -115,7 +111,7 @@ const ye = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDen
|
|
|
115
111
|
if (!x(d, ["Input", "Select"]))
|
|
116
112
|
return;
|
|
117
113
|
const $ = x(d, ["Select"]) ? d.props.input : d;
|
|
118
|
-
$ &&
|
|
114
|
+
$ && J($.props) && (b = !0);
|
|
119
115
|
}), b;
|
|
120
116
|
}), [R, j] = i.useState(() => {
|
|
121
117
|
let b = !1;
|
|
@@ -124,14 +120,14 @@ const ye = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDen
|
|
|
124
120
|
}), b;
|
|
125
121
|
}), [W, S] = i.useState(!1);
|
|
126
122
|
a && W && S(!1);
|
|
127
|
-
const w =
|
|
123
|
+
const w = O !== void 0 && !a ? O : W;
|
|
128
124
|
let N;
|
|
129
125
|
const T = i.useRef(!1);
|
|
130
126
|
process.env.NODE_ENV !== "production" && (N = () => (T.current && console.error(["MUI: There are multiple `InputBase` components inside a FormControl.", "This creates visual inconsistencies, only use one `InputBase`."].join(`
|
|
131
127
|
`)), T.current = !0, () => {
|
|
132
128
|
T.current = !1;
|
|
133
129
|
}));
|
|
134
|
-
const
|
|
130
|
+
const G = i.useMemo(() => ({
|
|
135
131
|
adornedStart: q,
|
|
136
132
|
setAdornedStart: H,
|
|
137
133
|
color: p,
|
|
@@ -158,13 +154,13 @@ const ye = D("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDen
|
|
|
158
154
|
required: m,
|
|
159
155
|
variant: u
|
|
160
156
|
}), [q, p, a, y, R, w, g, F, N, m, l, u]);
|
|
161
|
-
return /* @__PURE__ */ I(
|
|
162
|
-
value:
|
|
157
|
+
return /* @__PURE__ */ I(K.Provider, {
|
|
158
|
+
value: G,
|
|
163
159
|
children: /* @__PURE__ */ I(oe, {
|
|
164
160
|
as: c,
|
|
165
161
|
ownerState: M,
|
|
166
162
|
className: P(z.root, f),
|
|
167
|
-
ref:
|
|
163
|
+
ref: n,
|
|
168
164
|
...v,
|
|
169
165
|
children: s
|
|
170
166
|
})
|
|
@@ -256,14 +252,14 @@ function se(o) {
|
|
|
256
252
|
const C = D("MuiFormLabel", ["root", "colorSecondary", "focused", "disabled", "error", "filled", "required", "asterisk"]), te = (o) => {
|
|
257
253
|
const {
|
|
258
254
|
classes: r,
|
|
259
|
-
color:
|
|
260
|
-
focused:
|
|
255
|
+
color: n,
|
|
256
|
+
focused: t,
|
|
261
257
|
disabled: s,
|
|
262
258
|
error: f,
|
|
263
259
|
filled: p,
|
|
264
260
|
required: c
|
|
265
261
|
} = o, a = {
|
|
266
|
-
root: ["root", `color${L(
|
|
262
|
+
root: ["root", `color${L(n)}`, s && "disabled", f && "error", p && "filled", t && "focused", c && "required"],
|
|
267
263
|
asterisk: ["asterisk", f && "error"]
|
|
268
264
|
};
|
|
269
265
|
return V(a, se, r);
|
|
@@ -315,8 +311,8 @@ const C = D("MuiFormLabel", ["root", "colorSecondary", "focused", "disabled", "e
|
|
|
315
311
|
[`&.${C.error}`]: {
|
|
316
312
|
color: (o.vars || o).palette.error.main
|
|
317
313
|
}
|
|
318
|
-
}))), ie = /* @__PURE__ */ i.forwardRef(function(r,
|
|
319
|
-
const
|
|
314
|
+
}))), ie = /* @__PURE__ */ i.forwardRef(function(r, n) {
|
|
315
|
+
const t = B({
|
|
320
316
|
props: r,
|
|
321
317
|
name: "MuiFormLabel"
|
|
322
318
|
}), {
|
|
@@ -326,16 +322,16 @@ const C = D("MuiFormLabel", ["root", "colorSecondary", "focused", "disabled", "e
|
|
|
326
322
|
component: c = "label",
|
|
327
323
|
disabled: a,
|
|
328
324
|
error: y,
|
|
329
|
-
filled:
|
|
325
|
+
filled: O,
|
|
330
326
|
focused: g,
|
|
331
327
|
required: F,
|
|
332
|
-
...
|
|
333
|
-
} =
|
|
334
|
-
props:
|
|
328
|
+
...h
|
|
329
|
+
} = t, m = Q(), l = X({
|
|
330
|
+
props: t,
|
|
335
331
|
muiFormControl: m,
|
|
336
332
|
states: ["color", "required", "focused", "disabled", "error", "filled"]
|
|
337
333
|
}), u = {
|
|
338
|
-
...
|
|
334
|
+
...t,
|
|
339
335
|
color: l.color || "primary",
|
|
340
336
|
component: c,
|
|
341
337
|
disabled: l.disabled,
|
|
@@ -348,8 +344,8 @@ const C = D("MuiFormLabel", ["root", "colorSecondary", "focused", "disabled", "e
|
|
|
348
344
|
as: c,
|
|
349
345
|
ownerState: u,
|
|
350
346
|
className: P(v.root, f),
|
|
351
|
-
ref:
|
|
352
|
-
...
|
|
347
|
+
ref: n,
|
|
348
|
+
...h,
|
|
353
349
|
children: [s, l.required && /* @__PURE__ */ U(le, {
|
|
354
350
|
ownerState: u,
|
|
355
351
|
"aria-hidden": !0,
|
|
@@ -417,8 +413,7 @@ export {
|
|
|
417
413
|
C as b,
|
|
418
414
|
ne as c,
|
|
419
415
|
se as d,
|
|
420
|
-
|
|
421
|
-
ye as f,
|
|
416
|
+
ge as f,
|
|
422
417
|
Z as g,
|
|
423
418
|
x as i
|
|
424
419
|
};
|