@m4l/components 0.2.2 → 0.2.4
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/@types/export.d.ts +16 -4
- package/{commonjs.565e6834.js → commonjs.333e55c7.js} +5 -0
- package/components/AccountPopover/{index.37803642.js → index.2604c389.js} +2 -4
- package/components/AccountPopover/index.d.ts +1 -0
- package/components/AppBar/AppBar.d.ts +24 -0
- package/components/AppBar/classes/index.d.ts +2 -0
- package/components/AppBar/classes/types.d.ts +2 -0
- package/components/AppBar/{index.d17827eb.js → index.9522f237.js} +26 -5
- package/components/AppBar/types.d.ts +14 -0
- package/components/CommonActions/components/ActionCancel/{index.6aa59730.js → index.06539086.js} +2 -2
- package/components/CommonActions/components/ActionFormCancel/{index.e6ac3a19.js → index.33fc6c79.js} +5 -14
- package/components/CommonActions/components/ActionFormIntro/{index.ebadee33.js → index.5a719043.js} +2 -2
- package/components/CommonActions/components/ActionIntro/{index.33acdebb.js → index.3e8a2e60.js} +2 -2
- package/components/CommonActions/components/Actions/{index.f358ae72.js → index.2f6286eb.js} +1 -1
- package/components/DataGrid/formatters/columnPointsFormatter/{index.5e645334.js → index.a19b7b90.js} +1 -1
- package/components/DataGrid/{index.e93a1a31.js → index.8fbcf147.js} +8 -9
- package/components/DataGrid/subcomponents/Actions/{index.bcf7a8d7.js → index.bad681dc.js} +9 -9
- package/components/DraggableWindow/{index.ddc7327b.js → index.f9f067bd.js} +1 -1
- package/components/DynamicFilter/classes/index.d.ts +1 -1
- package/components/DynamicFilter/classes/types.d.ts +1 -0
- package/components/DynamicFilter/{index.6663cc83.js → index.cd7691e0.js} +17 -13
- package/components/GridLayout/{index.c26989d8.js → index.e8c04242.js} +2 -2
- package/components/GridLayout/subcomponents/Griditem/{index.da0a3c47.js → index.4d38f12e.js} +3 -3
- package/components/GridLayout/subcomponents/Responsive/{index.2e641db2.js → index.e25df1dc.js} +1 -1
- package/components/Icon/index.05984e7f.js +248 -0
- package/components/Icon/types.d.ts +1 -0
- package/components/Image/{index.2a2e0b27.js → index.bf37e923.js} +46 -4
- package/components/Image/types.d.ts +2 -2
- package/components/LanguagePopover/{index.ff7c862e.js → index.5ff37dbf.js} +2 -2
- package/components/LinearProgressIndeterminate/{index.7f4ed9b7.js → index.a0ad2d9e.js} +1 -1
- package/components/LoadingError/{index.0ac9e74d.js → index.fabad214.js} +3 -3
- package/components/MFLoader/{index.cd087354.js → index.7b4ee2a4.js} +1 -1
- package/components/ModalDialog/{index.8c4fde10.js → index.89e26413.js} +4 -4
- package/components/NoItemSelected/{index.afc12ed9.js → index.7db73e77.js} +1 -1
- package/components/ObjectLogs/{index.cb303905.js → index.9c353020.js} +7 -7
- package/components/PDFViewer/PDFViewer.d.ts +2 -0
- package/components/PDFViewer/classes/constants.d.ts +1 -0
- package/components/PDFViewer/classes/index.d.ts +7 -0
- package/components/PDFViewer/classes/types.d.ts +7 -0
- package/components/PDFViewer/index.5c2db67a.js +63 -0
- package/components/PDFViewer/index.d.ts +1 -0
- package/components/PDFViewer/types.d.ts +3 -0
- package/components/Page/{index.190e2356.js → index.710cb16f.js} +1 -1
- package/components/PaperForm/{index.7a206d69.js → index.7ea3883f.js} +1 -1
- package/components/Period/{index.906f1ce2.js → index.0aa8e507.js} +2 -2
- package/components/PrintingSystem/{index.bbf52442.js → index.ed3b22b7.js} +15 -43
- package/components/PrintingSystem/subcomponents/BodyNode/{index.ee81edc5.js → index.7acc6016.js} +1 -1
- package/components/PrintingSystem/subcomponents/ChartNode/{index.b56666cf.js → index.e4a23bdd.js} +4 -4
- package/components/PrintingSystem/subcomponents/DividerNode/{index.ca3332b1.js → index.16fff262.js} +1 -1
- package/components/PrintingSystem/subcomponents/FooterNode/{index.932c3e33.js → index.6c67dec0.js} +1 -1
- package/components/PrintingSystem/subcomponents/GridNode/{index.16748040.js → index.f466062b.js} +4 -4
- package/components/PrintingSystem/subcomponents/HeaderNode/{index.0ddbbbad.js → index.77d3d39a.js} +1 -1
- package/components/PrintingSystem/subcomponents/PaperNode/{index.efd9af2f.js → index.2a3d54a3.js} +4 -4
- package/components/PrintingSystem/subcomponents/PropertyValueNode/{index.75ed9752.js → index.e71ad971.js} +1 -1
- package/components/PrintingSystem/subcomponents/QRImageNode/index.d.ts +2 -0
- package/components/PrintingSystem/subcomponents/QRImageNode/types.d.ts +3 -0
- package/components/PrintingSystem/subcomponents/SectionNode/{index.68cac21a.js → index.ce4f6d16.js} +1 -1
- package/components/PrintingSystem/subcomponents/TextBoxNode/{index.91ba514f.js → index.850d20a1.js} +3 -3
- package/components/PrintingSystem/types.d.ts +10 -1
- package/components/PropertyValue/classes/index.d.ts +1 -1
- package/components/PropertyValue/classes/types.d.ts +4 -1
- package/components/PropertyValue/index.37d91d0c.js +206 -0
- package/components/PropertyValue/types.d.ts +5 -7
- package/components/Resizeable/{index.383eb1aa.js → index.6478d7d8.js} +1 -1
- package/components/ScrollBar/{index.65bb2930.js → index.010f1b9d.js} +5 -1
- package/components/SideBar/classes/index.d.ts +1 -1
- package/components/SideBar/{index.7e4a79a6.js → index.58d29b84.js} +12 -12
- package/components/SideBar/types.d.ts +3 -3
- package/components/SplitLayout/{index.9ef430f6.js → index.30fd5861.js} +1 -1
- package/components/ToastContainer/ToastContainer.d.ts +2 -0
- package/components/ToastContainer/classes/constants.d.ts +1 -0
- package/components/ToastContainer/classes/index.d.ts +8 -0
- package/components/ToastContainer/classes/types.d.ts +9 -0
- package/components/ToastContainer/index.d.ts +2 -0
- package/components/ToastContainer/index.ed440301.js +87 -0
- package/components/ToastContainer/subcomponents/ToastMessage/index.d.ts +2 -0
- package/components/ToastContainer/subcomponents/ToastMessage/types.d.ts +5 -0
- package/components/ToastContainer/types.d.ts +4 -0
- package/components/areas/components/AreasAdmin/{index.74532c2a.js → index.a14ba797.js} +12 -12
- package/components/areas/components/AreasViewer/{index.3cd1a452.js → index.c4545f2d.js} +15 -15
- package/components/areas/contexts/AreasContext/{index.55981647.js → index.54893ef7.js} +4 -4
- package/components/areas/hooks/useAreas/{index.5cbbe91c.js → index.a15b3d9c.js} +1 -1
- package/components/formatters/BooleanFormatter/{index.5379222a.js → index.4f3cbdce.js} +2 -2
- package/components/formatters/PointsFormatter/{index.80a4e414.js → index.5c94c5e8.js} +2 -2
- package/components/formatters/PointsFormatter/index.d.ts +1 -1
- package/components/formatters/{index.d0a0800d.js → index.4ca6946d.js} +1 -1
- package/components/hook-form/RHFAutocomplete/classes/types.d.ts +2 -0
- package/components/hook-form/RHFAutocomplete/{index.09ff3d84.js → index.0ce87ac3.js} +26 -35
- package/components/hook-form/RHFAutocomplete/subcomponents/RenderOption/index.d.ts +1 -1
- package/components/hook-form/RHFAutocomplete/subcomponents/Skeleton/types.d.ts +1 -2
- package/components/hook-form/RHFAutocomplete/types.d.ts +8 -3
- package/components/hook-form/RHFAutocompleteAsync/{index.54b4dca3.js → index.57789d3a.js} +1 -1
- package/components/hook-form/RHFColorPicker/classes/constants.d.ts +1 -0
- package/components/hook-form/RHFColorPicker/classes/index.d.ts +11 -0
- package/components/hook-form/RHFColorPicker/classes/types.d.ts +11 -0
- package/components/hook-form/RHFColorPicker/index.d.ts +6 -0
- package/components/hook-form/RHFColorPicker/index.d00a2b53.js +150 -0
- package/components/hook-form/RHFColorPicker/subcomponents/Skeleton/indext.d.ts +1 -0
- package/components/hook-form/RHFColorPicker/types.d.ts +5 -0
- package/components/hook-form/RHFDateTime/{index.2b76899e.js → index.ae5d3a39.js} +1 -1
- package/components/hook-form/RHFDateTime/types.d.ts +0 -1
- package/components/hook-form/RHFPeriod/{index.d6c8587a.js → index.ae9bcf41.js} +1 -1
- package/components/hook-form/RHFTextField/{index.f546c18a.js → index.80cc07e0.js} +2 -2
- package/components/hook-form/RHFUpload/{index.a5621247.js → index.587aac00.js} +4 -4
- package/components/index.d.ts +2 -0
- package/components/maps/{GpsTools.34a27c0a.js → components/GpsTools/index.889b0c39.js} +28 -27
- package/components/maps/{Map.9fc17398.js → components/Map/index.665e5c5d.js} +4 -4
- package/components/modal/{WindowBase.38d4b8e7.js → WindowBase.ea17cf20.js} +3 -3
- package/components/modal/{WindowConfirm.cd776fe5.js → WindowConfirm.19ddbd5d.js} +6 -6
- package/components/mui_extended/Accordion/{index.5b4b2075.js → index.b9b427d7.js} +3 -3
- package/components/mui_extended/Button/classes/types.d.ts +2 -0
- package/components/mui_extended/Button/{index.fc5132fa.js → index.570fd3a4.js} +3 -3
- package/components/mui_extended/IconButton/{index.df52ae90.js → index.26de70bd.js} +1 -1
- package/components/mui_extended/LoadingButton/classes/constants.d.ts +1 -1
- package/components/mui_extended/MenuActions/{index.04d87c36.js → index.8c02ff61.js} +2 -2
- package/components/mui_extended/Pager/{index.c6990cd4.js → index.5629e82b.js} +1 -1
- package/components/mui_extended/Tab/{index.53203047.js → index.724d5948.js} +1 -1
- package/components/mui_extended/ToggleButton/{index.4b7b7df0.js → index.21a1f8e5.js} +1 -1
- package/components/mui_extended/ToggleIconButton/{index.e430bed4.js → index.00f13c40.js} +1 -1
- package/contexts/ModalContext/{index.aa3bd23f.js → index.b39d303d.js} +1 -1
- package/hooks/useFormAddEdit/{index.59c74cbf.js → index.32aa4f64.js} +2 -2
- package/hooks/useModal/{index.b4b84d5d.js → index.abdc0962.js} +1 -1
- package/hooks/useTab/{index.6ab00d5a.js → index.991b13a7.js} +1 -1
- package/index.js +100 -86
- package/node_modules.8f15d11f.js +6921 -0
- package/package.json +5 -2
- package/{react-draggable.cdce362f.js → react-draggable.ee21cb7e.js} +4 -4
- package/{react-json-view.57125fcf.js → react-json-view.5636414a.js} +1 -1
- package/{react-resizable.806822ee.js → react-resizable.ee028152.js} +5 -5
- package/{react-splitter-layout.8b1655c8.js → react-splitter-layout.c5d98bf7.js} +3 -3
- package/utils/{index.b22c4c1a.js → index.de903261.js} +0 -32
- package/vendor.8f8b0ac9.js +112 -0
- package/components/Icon/index.6db034b5.js +0 -147
- package/components/PrintingSystem/utils/getEvalValue/index.d.ts +0 -1
- package/components/PropertyValue/index.a36c1223.js +0 -220
- package/components/PropertyValue/skeleton.d.ts +0 -2
- package/components/maps/index.7057e217.js +0 -1
- package/node_modules.f907e6dd.js +0 -4736
- package/vendor.caaaf054.js +0 -168
- /package/components/GridLayout/subcomponents/{Griditem → GridItem}/index.d.ts +0 -0
- /package/components/GridLayout/subcomponents/{Griditem → GridItem}/types.d.ts +0 -0
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { useState } from "react";
|
|
2
|
+
import { useFormContext, Controller } from "react-hook-form";
|
|
3
|
+
import { useModuleSkeleton, useEnvironment, useModuleDictionary } from "@m4l/core";
|
|
4
|
+
import { S as SketchPicker } from "../../../node_modules.8f15d11f.js";
|
|
5
|
+
import "lodash-es/debounce";
|
|
6
|
+
import "lodash-es/each";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
import { H as HelperText } from "../../HelperText/index.7d2afdb3.js";
|
|
9
|
+
import { generateUtilityClasses, generateUtilityClass, styled, Skeleton as Skeleton$1 } from "@mui/material";
|
|
10
|
+
import { unstable_composeClasses } from "@mui/base";
|
|
11
|
+
import { useTheme } from "@mui/material/styles";
|
|
12
|
+
import { P as Popover } from "../../mui_extended/Popover/index.b3eca6b1.js";
|
|
13
|
+
import { I as Icon } from "../../Icon/index.05984e7f.js";
|
|
14
|
+
import { B as Button } from "../../mui_extended/Button/index.570fd3a4.js";
|
|
15
|
+
const componentName = "M4LRHFColorPicker";
|
|
16
|
+
const colorPickerClasses = generateUtilityClasses(componentName, [
|
|
17
|
+
"root",
|
|
18
|
+
"popoverRoot",
|
|
19
|
+
"containerFieldColor",
|
|
20
|
+
"fieldColor",
|
|
21
|
+
"containerPicker",
|
|
22
|
+
"skeleton"
|
|
23
|
+
]);
|
|
24
|
+
function getRHFColorPickerUtilityClass(slot) {
|
|
25
|
+
return generateUtilityClass(componentName, slot);
|
|
26
|
+
}
|
|
27
|
+
const useUtilityClasses = () => {
|
|
28
|
+
const slots = {
|
|
29
|
+
root: ["root"],
|
|
30
|
+
popoverRoot: ["popoverRoot"],
|
|
31
|
+
containerFieldColor: ["containerFieldColor"],
|
|
32
|
+
fieldColor: ["boxColor"],
|
|
33
|
+
containerPicker: ["containerPicker"],
|
|
34
|
+
skeleton: ["skeleton"]
|
|
35
|
+
};
|
|
36
|
+
const composedClasses = unstable_composeClasses(slots, getRHFColorPickerUtilityClass, {});
|
|
37
|
+
return {
|
|
38
|
+
...composedClasses
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
const RHFColorPickerRoot = styled("div")(({ theme }) => ({
|
|
42
|
+
...theme.components?.M4LRHFColorPicker?.styleOverrides
|
|
43
|
+
}));
|
|
44
|
+
const Skeleton = () => {
|
|
45
|
+
return /* @__PURE__ */ jsx(Skeleton$1, {
|
|
46
|
+
className: colorPickerClasses.skeleton,
|
|
47
|
+
variant: "rectangular",
|
|
48
|
+
width: 20,
|
|
49
|
+
height: 20
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
const RHFColorPicker = (props) => {
|
|
53
|
+
const {
|
|
54
|
+
name
|
|
55
|
+
} = props;
|
|
56
|
+
const {
|
|
57
|
+
control,
|
|
58
|
+
setValue,
|
|
59
|
+
getValues
|
|
60
|
+
} = useFormContext();
|
|
61
|
+
const isSkeleton = useModuleSkeleton();
|
|
62
|
+
const {
|
|
63
|
+
host_static_assets,
|
|
64
|
+
environment_assets
|
|
65
|
+
} = useEnvironment();
|
|
66
|
+
const theme = useTheme();
|
|
67
|
+
const currentColor = getValues(name);
|
|
68
|
+
const [tempColor, setTempColor] = useState(() => currentColor || "#ffffff");
|
|
69
|
+
const [anchorEl, setAnchorEl] = useState(null);
|
|
70
|
+
const {
|
|
71
|
+
getLabel
|
|
72
|
+
} = useModuleDictionary();
|
|
73
|
+
const handleColorChange = (color) => {
|
|
74
|
+
setTempColor(color.hex);
|
|
75
|
+
};
|
|
76
|
+
const handleApprove = () => {
|
|
77
|
+
setAnchorEl(null);
|
|
78
|
+
if (tempColor !== currentColor) {
|
|
79
|
+
setValue(name, tempColor);
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
const classes = useUtilityClasses();
|
|
83
|
+
if (isSkeleton) {
|
|
84
|
+
return /* @__PURE__ */ jsx(Skeleton, {});
|
|
85
|
+
}
|
|
86
|
+
return /* @__PURE__ */ jsx(Controller, {
|
|
87
|
+
name,
|
|
88
|
+
control,
|
|
89
|
+
defaultValue: "",
|
|
90
|
+
render: ({
|
|
91
|
+
field,
|
|
92
|
+
fieldState: {
|
|
93
|
+
error
|
|
94
|
+
}
|
|
95
|
+
}) => /* @__PURE__ */ jsxs(RHFColorPickerRoot, {
|
|
96
|
+
className: classes.root,
|
|
97
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
98
|
+
className: classes.containerFieldColor,
|
|
99
|
+
onClick: (event) => setAnchorEl(event.currentTarget),
|
|
100
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
101
|
+
className: classes.fieldColor,
|
|
102
|
+
style: {
|
|
103
|
+
backgroundColor: field.value,
|
|
104
|
+
width: "20px",
|
|
105
|
+
height: "20px",
|
|
106
|
+
cursor: "pointer"
|
|
107
|
+
}
|
|
108
|
+
}), /* @__PURE__ */ jsx(Icon, {
|
|
109
|
+
src: `${host_static_assets}/${environment_assets}/frontend/components/rhfcolorpicker/assets/icons/chevron_right.svg`
|
|
110
|
+
})]
|
|
111
|
+
}), error?.message && /* @__PURE__ */ jsx(HelperText, {
|
|
112
|
+
variant: "error",
|
|
113
|
+
message: error?.message + ""
|
|
114
|
+
}), /* @__PURE__ */ jsx(Popover, {
|
|
115
|
+
open: Boolean(anchorEl),
|
|
116
|
+
arrowType: "top-center",
|
|
117
|
+
className: classes.popoverRoot,
|
|
118
|
+
anchorEl,
|
|
119
|
+
onClose: () => setAnchorEl(null),
|
|
120
|
+
anchorOrigin: {
|
|
121
|
+
vertical: "bottom",
|
|
122
|
+
horizontal: "center"
|
|
123
|
+
},
|
|
124
|
+
transformOrigin: {
|
|
125
|
+
vertical: "top",
|
|
126
|
+
horizontal: "center"
|
|
127
|
+
},
|
|
128
|
+
sx: {
|
|
129
|
+
mt: "12px",
|
|
130
|
+
...theme.components?.M4LRHFColorPickerPopoverRoot?.styleOverrides
|
|
131
|
+
},
|
|
132
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
133
|
+
className: classes.containerPicker,
|
|
134
|
+
children: [/* @__PURE__ */ jsx(SketchPicker, {
|
|
135
|
+
color: tempColor,
|
|
136
|
+
onChange: handleColorChange,
|
|
137
|
+
disableAlpha: true
|
|
138
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
139
|
+
variant: "contained",
|
|
140
|
+
onClick: handleApprove,
|
|
141
|
+
children: getLabel("rhfcolorpicker.accept")
|
|
142
|
+
})]
|
|
143
|
+
})
|
|
144
|
+
})]
|
|
145
|
+
})
|
|
146
|
+
});
|
|
147
|
+
};
|
|
148
|
+
export {
|
|
149
|
+
RHFColorPicker as R
|
|
150
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Skeleton: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -11,7 +11,7 @@ import clsx from "clsx";
|
|
|
11
11
|
import { H as HelperText } from "../../HelperText/index.7d2afdb3.js";
|
|
12
12
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
13
13
|
import { T as Typography } from "../../mui_extended/Typography/index.379dd374.js";
|
|
14
|
-
import { I as Icon } from "../../Icon/index.
|
|
14
|
+
import { I as Icon } from "../../Icon/index.05984e7f.js";
|
|
15
15
|
const SKTRHFWrapperTextField = styled("div")(({
|
|
16
16
|
theme
|
|
17
17
|
}) => ({
|
|
@@ -3,7 +3,7 @@ import { useFormContext, Controller } from "react-hook-form";
|
|
|
3
3
|
import { H as HelperText } from "../../HelperText/index.7d2afdb3.js";
|
|
4
4
|
import { unstable_composeClasses } from "@mui/base";
|
|
5
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
-
import { P as Period } from "../../Period/index.
|
|
6
|
+
import { P as Period } from "../../Period/index.0aa8e507.js";
|
|
7
7
|
const RHFPeriodRoot = styled("div")(({
|
|
8
8
|
theme
|
|
9
9
|
}) => ({
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { useModuleSkeleton, useEnvironment } from "@m4l/core";
|
|
2
2
|
import { styled, Skeleton, generateUtilityClasses, TextField, InputAdornment, generateUtilityClass } from "@mui/material";
|
|
3
3
|
import { forwardRef, useState, useEffect } from "react";
|
|
4
|
-
import { I as IconButton } from "../../mui_extended/IconButton/index.
|
|
4
|
+
import { I as IconButton } from "../../mui_extended/IconButton/index.26de70bd.js";
|
|
5
5
|
import { useFormContext, Controller } from "react-hook-form";
|
|
6
6
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
7
7
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
8
8
|
import { styled as styled$1 } from "@mui/material/styles";
|
|
9
9
|
import { unstable_composeClasses } from "@mui/base";
|
|
10
|
-
import { g as getComponentUtilityClass } from "../../../utils/index.
|
|
10
|
+
import { g as getComponentUtilityClass } from "../../../utils/index.de903261.js";
|
|
11
11
|
import { T as Typography } from "../../mui_extended/Typography/index.379dd374.js";
|
|
12
12
|
import { H as HelperText } from "../../HelperText/index.7d2afdb3.js";
|
|
13
13
|
import { useResponsiveDesktop } from "@m4l/graphics";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useCallback } from "react";
|
|
2
2
|
import { useFormContext, Controller } from "react-hook-form";
|
|
3
|
-
import
|
|
3
|
+
import require$$0 from "lodash/isString";
|
|
4
4
|
import { useDropzone } from "react-dropzone";
|
|
5
|
-
import { I as Image } from "../../Image/index.
|
|
5
|
+
import { I as Image } from "../../Image/index.bf37e923.js";
|
|
6
6
|
import { useEnvironment, useModuleDictionary, useModuleSkeleton } from "@m4l/core";
|
|
7
7
|
import { styled } from "@mui/material/styles";
|
|
8
8
|
import { Skeleton, generateUtilityClasses, generateUtilityClass, styled as styled$1 } from "@mui/material";
|
|
@@ -10,7 +10,7 @@ import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
|
10
10
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
11
11
|
import { unstable_composeClasses } from "@mui/base";
|
|
12
12
|
import { T as Typography } from "../../mui_extended/Typography/index.379dd374.js";
|
|
13
|
-
import { B as Button } from "../../mui_extended/Button/index.
|
|
13
|
+
import { B as Button } from "../../mui_extended/Button/index.570fd3a4.js";
|
|
14
14
|
import { H as HelperText } from "../../HelperText/index.7d2afdb3.js";
|
|
15
15
|
const UploadImageRoot = styled("div")(({
|
|
16
16
|
theme
|
|
@@ -140,7 +140,7 @@ function UploadImage({
|
|
|
140
140
|
} : {},
|
|
141
141
|
children: /* @__PURE__ */ jsx(Image, {
|
|
142
142
|
alt: "bgImageUploadImage",
|
|
143
|
-
src:
|
|
143
|
+
src: require$$0(file) ? file : file.preview || "",
|
|
144
144
|
ratio: "1:1"
|
|
145
145
|
})
|
|
146
146
|
}), /* @__PURE__ */ jsx("div", {
|
package/components/index.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export * from './NoItemSelected/dictionary';
|
|
|
34
34
|
export * from './ObjectLogs';
|
|
35
35
|
export * from './ObjectLogs/dictionary';
|
|
36
36
|
export * from './PaperForm/PaperForm';
|
|
37
|
+
export * from './PDFViewer';
|
|
37
38
|
export * from './Period';
|
|
38
39
|
export * from './HelmetPage';
|
|
39
40
|
export * from './PropertyValue/PropertyValue';
|
|
@@ -41,6 +42,7 @@ export * from './ResizeableWindow';
|
|
|
41
42
|
export * from './ScrollBar';
|
|
42
43
|
export { ScrollToTop } from './ScrollToTop';
|
|
43
44
|
export * from './SplitLayout/SplitLayout';
|
|
45
|
+
export * from './ToastContainer';
|
|
44
46
|
export * from './SideBar';
|
|
45
47
|
export * from './AppBar';
|
|
46
48
|
export * from './AccountPopover';
|
|
@@ -5,45 +5,45 @@ import { useResponsiveDesktop, useFirstRender } from "@m4l/graphics";
|
|
|
5
5
|
import { useModuleDictionary, useModuleSkeleton, useEnvironment, useNetwork, useModulePrivileges, useHostTools, usePaginate } from "@m4l/core";
|
|
6
6
|
import { devtools } from "zustand/middleware";
|
|
7
7
|
import { immer } from "zustand/middleware/immer";
|
|
8
|
-
import {
|
|
8
|
+
import { enableMapSet } from "immer";
|
|
9
9
|
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
10
|
-
import { D as DynamicFilter } from "
|
|
11
|
-
import { S as SelectCellFormatter } from "
|
|
12
|
-
import { e as columnDateFormatter, c as DataGrid } from "
|
|
13
|
-
import { u as useMapToolsStore, a as useMapStore, m as mapClasses, M as MAP_ZINDEX_DEFAULT, b as MAP_ZINDEX_OVER_MAP } from "
|
|
14
|
-
import { u as useModal } from "
|
|
15
|
-
import { W as WindowConfirm } from "
|
|
10
|
+
import { D as DynamicFilter } from "../../../DynamicFilter/index.cd7691e0.js";
|
|
11
|
+
import { S as SelectCellFormatter } from "../../../../react-data-grid.c5377916.js";
|
|
12
|
+
import { e as columnDateFormatter, c as DataGrid } from "../../../DataGrid/index.8fbcf147.js";
|
|
13
|
+
import { u as useMapToolsStore, a as useMapStore, m as mapClasses, M as MAP_ZINDEX_DEFAULT, b as MAP_ZINDEX_OVER_MAP } from "../Map/index.665e5c5d.js";
|
|
14
|
+
import { u as useModal } from "../../../../hooks/useModal/index.abdc0962.js";
|
|
15
|
+
import { W as WindowConfirm } from "../../../modal/WindowConfirm.19ddbd5d.js";
|
|
16
16
|
import { generateUtilityClasses } from "@mui/material";
|
|
17
17
|
import "@mui/base";
|
|
18
|
-
import { S as Stack } from "
|
|
19
|
-
import { B as Button } from "
|
|
18
|
+
import { S as Stack } from "../../../mui_extended/Stack/index.0e53197c.js";
|
|
19
|
+
import { B as Button } from "../../../mui_extended/Button/index.570fd3a4.js";
|
|
20
20
|
import { useFormContext, useWatch } from "react-hook-form";
|
|
21
|
-
import { H as HelperError } from "
|
|
22
|
-
import { A as Actions } from "
|
|
23
|
-
import { A as ActionFormIntro } from "
|
|
21
|
+
import { H as HelperError } from "../../../hook-form/HelperError/index.66bbcac3.js";
|
|
22
|
+
import { A as Actions } from "../../../CommonActions/components/Actions/index.2f6286eb.js";
|
|
23
|
+
import { A as ActionFormIntro } from "../../../CommonActions/components/ActionFormIntro/index.5a719043.js";
|
|
24
24
|
import { useMap, Polyline, Polygon, Popup, Circle } from "react-leaflet";
|
|
25
|
-
import { u as useFormReadyForUpdate } from "
|
|
25
|
+
import { u as useFormReadyForUpdate } from "../../../../hooks/useFormReadyForUpdate/index.f60f500e.js";
|
|
26
26
|
import * as L from "leaflet";
|
|
27
27
|
import L__default from "leaflet";
|
|
28
|
-
import { u as useTab } from "
|
|
29
|
-
import { P as PaperForm } from "
|
|
30
|
-
import { R as RHFAutocomplete } from "
|
|
31
|
-
import { R as RHFTextField } from "
|
|
32
|
-
import { P as PropertyValue } from "
|
|
33
|
-
import { R as RHFColorPicker } from "
|
|
28
|
+
import { u as useTab } from "../../../../hooks/useTab/index.991b13a7.js";
|
|
29
|
+
import { P as PaperForm } from "../../../PaperForm/index.7ea3883f.js";
|
|
30
|
+
import { R as RHFAutocomplete } from "../../../hook-form/RHFAutocomplete/index.0ce87ac3.js";
|
|
31
|
+
import { R as RHFTextField } from "../../../hook-form/RHFTextField/index.80cc07e0.js";
|
|
32
|
+
import { P as PropertyValue } from "../../../PropertyValue/index.37d91d0c.js";
|
|
33
|
+
import { R as RHFColorPicker } from "../../../hook-form/RHFColorPicker/index.d00a2b53.js";
|
|
34
34
|
import clsx from "clsx";
|
|
35
|
-
import { T as Tabs, a as Tab, b as TabContent, c as TabProvider } from "
|
|
36
|
-
import { T as Tooltip } from "
|
|
35
|
+
import { T as Tabs, a as Tab, b as TabContent, c as TabProvider } from "../../../mui_extended/Tab/index.724d5948.js";
|
|
36
|
+
import { T as Tooltip } from "../../../mui_extended/Tooltip/index.24a2bc3f.js";
|
|
37
37
|
import * as Yup from "yup";
|
|
38
|
-
import { u as useFormAddEdit } from "
|
|
39
|
-
import { R as RHFormProvider } from "
|
|
40
|
-
import { R as RHFAutocompleteAsync } from "
|
|
38
|
+
import { u as useFormAddEdit } from "../../../../hooks/useFormAddEdit/index.32aa4f64.js";
|
|
39
|
+
import { R as RHFormProvider } from "../../../../contexts/RHFormContext/index.7769076a.js";
|
|
40
|
+
import { R as RHFAutocompleteAsync } from "../../../hook-form/RHFAutocompleteAsync/index.57789d3a.js";
|
|
41
41
|
import "leaflet-polylinedecorator";
|
|
42
42
|
import "@geoman-io/leaflet-geoman-free/dist/leaflet-geoman.css";
|
|
43
43
|
import "@geoman-io/leaflet-geoman-free";
|
|
44
44
|
import { styled } from "@mui/material/styles";
|
|
45
45
|
import { createPortal } from "react-dom";
|
|
46
|
-
|
|
46
|
+
enableMapSet();
|
|
47
47
|
const createMapToolsStore = (initProps) => {
|
|
48
48
|
const startProps = {
|
|
49
49
|
currentTabTool: "measure",
|
|
@@ -1935,6 +1935,7 @@ function useMeasure() {
|
|
|
1935
1935
|
}, []);
|
|
1936
1936
|
return { statusEdition, magnitudFactor, value };
|
|
1937
1937
|
}
|
|
1938
|
+
const DevTool = process.env.NODE_ENV === "development" ? require("@hookform/devtools").DevTool : () => null;
|
|
1938
1939
|
function MeasureData() {
|
|
1939
1940
|
const {
|
|
1940
1941
|
getLabel
|
|
@@ -1973,9 +1974,9 @@ function MeasureData() {
|
|
|
1973
1974
|
className: mapToolsClasses.toolMeasureFormValueSymbol,
|
|
1974
1975
|
children: magnitudFactor.symbol
|
|
1975
1976
|
})]
|
|
1976
|
-
}), /* @__PURE__ */ jsx(DevTool, {
|
|
1977
|
+
}), process.env.NODE_ENV === "development" && /* @__PURE__ */ jsx(DevTool, {
|
|
1977
1978
|
control
|
|
1978
|
-
})
|
|
1979
|
+
})]
|
|
1979
1980
|
});
|
|
1980
1981
|
}
|
|
1981
1982
|
function MeasureTool() {
|
|
@@ -6,17 +6,17 @@ import React__default, { useEffect, useState, useCallback, createContext, useRef
|
|
|
6
6
|
import { jsx, Fragment, jsxs } from "react/jsx-runtime";
|
|
7
7
|
import { createStore, useStore } from "zustand";
|
|
8
8
|
import L__default from "leaflet";
|
|
9
|
-
import { T as ToggleButton } from "
|
|
10
|
-
import { T as ToggleIconButton } from "
|
|
9
|
+
import { T as ToggleButton } from "../../../mui_extended/ToggleButton/index.21a1f8e5.js";
|
|
10
|
+
import { T as ToggleIconButton } from "../../../mui_extended/ToggleIconButton/index.00f13c40.js";
|
|
11
11
|
import { useResponsiveDesktop, useFirstRender } from "@m4l/graphics";
|
|
12
12
|
import { useModuleDictionary, useModuleSkeleton } from "@m4l/core";
|
|
13
13
|
import { devtools } from "zustand/middleware";
|
|
14
14
|
import { immer } from "zustand/middleware/immer";
|
|
15
15
|
import { generateUtilityClasses } from "@mui/material";
|
|
16
16
|
import { unstable_composeClasses } from "@mui/base";
|
|
17
|
-
import { g as getComponentUtilityClass } from "
|
|
17
|
+
import { g as getComponentUtilityClass } from "../../../../utils/index.de903261.js";
|
|
18
18
|
import { cloneDeep } from "lodash";
|
|
19
|
-
import { G as GpsToolsContext } from "
|
|
19
|
+
import { G as GpsToolsContext } from "../GpsTools/index.889b0c39.js";
|
|
20
20
|
const COMPONENT_CLASS_NAME = "M4LMap";
|
|
21
21
|
const MAP_ZINDEX_DEFAULT = 0;
|
|
22
22
|
const MAP_ZINDEX_OVER_MAP = 1100;
|
|
@@ -2,9 +2,9 @@ import { m as modalUtilityClasses } from "./index.61389369.js";
|
|
|
2
2
|
import { useEnvironment } from "@m4l/core";
|
|
3
3
|
import clsx from "clsx";
|
|
4
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
5
|
-
import { I as IconButton } from "../mui_extended/IconButton/index.
|
|
6
|
-
import { I as Icon } from "../Icon/index.
|
|
7
|
-
import { u as useModal } from "../../hooks/useModal/index.
|
|
5
|
+
import { I as IconButton } from "../mui_extended/IconButton/index.26de70bd.js";
|
|
6
|
+
import { I as Icon } from "../Icon/index.05984e7f.js";
|
|
7
|
+
import { u as useModal } from "../../hooks/useModal/index.abdc0962.js";
|
|
8
8
|
const Header = (props) => {
|
|
9
9
|
const {
|
|
10
10
|
title,
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { A as Actions } from "../CommonActions/components/Actions/index.
|
|
1
|
+
import { A as Actions } from "../CommonActions/components/Actions/index.2f6286eb.js";
|
|
2
2
|
import { Typography } from "@mui/material";
|
|
3
3
|
import { useModuleDictionary, useEnvironment } from "@m4l/core";
|
|
4
|
-
import { u as useModal } from "../../hooks/useModal/index.
|
|
4
|
+
import { u as useModal } from "../../hooks/useModal/index.abdc0962.js";
|
|
5
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
-
import { I as Image } from "../Image/index.
|
|
6
|
+
import { I as Image } from "../Image/index.bf37e923.js";
|
|
7
7
|
import { m as modalUtilityClasses } from "./index.61389369.js";
|
|
8
|
-
import { W as WindowBase } from "./WindowBase.
|
|
9
|
-
import { A as ActionCancel } from "../CommonActions/components/ActionCancel/index.
|
|
10
|
-
import { A as ActionIntro } from "../CommonActions/components/ActionIntro/index.
|
|
8
|
+
import { W as WindowBase } from "./WindowBase.ea17cf20.js";
|
|
9
|
+
import { A as ActionCancel } from "../CommonActions/components/ActionCancel/index.06539086.js";
|
|
10
|
+
import { A as ActionIntro } from "../CommonActions/components/ActionIntro/index.3e8a2e60.js";
|
|
11
11
|
const dictionary = {
|
|
12
12
|
MESSAGE: "common_actions.confirm_quit_msg"
|
|
13
13
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { generateUtilityClasses, generateUtilityClass, styled, Accordion as Accordion$1, AccordionSummary, AccordionDetails } from "@mui/material";
|
|
2
|
-
import { I as IconButton } from "../IconButton/index.
|
|
2
|
+
import { I as IconButton } from "../IconButton/index.26de70bd.js";
|
|
3
3
|
import { useEnvironment } from "@m4l/core";
|
|
4
4
|
import { unstable_composeClasses } from "@mui/base";
|
|
5
5
|
import clsx from "clsx";
|
|
6
6
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
7
|
-
import { g as getNameDataTestId } from "../../../vendor.
|
|
7
|
+
import { g as getNameDataTestId } from "../../../vendor.8f8b0ac9.js";
|
|
8
8
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
|
-
import { I as Icon } from "../../Icon/index.
|
|
9
|
+
import { I as Icon } from "../../Icon/index.05984e7f.js";
|
|
10
10
|
import { T as Typography } from "../Typography/index.379dd374.js";
|
|
11
11
|
const componentName = "M4LAccordion";
|
|
12
12
|
generateUtilityClasses(componentName, [
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useUtilityClasses } from ".";
|
|
1
2
|
export interface ButtonClassesType {
|
|
2
3
|
root: string;
|
|
3
4
|
skeleton: string;
|
|
@@ -15,3 +16,4 @@ export interface ButtonClassesType {
|
|
|
15
16
|
toggleNotPressed: string;
|
|
16
17
|
}
|
|
17
18
|
export declare type ButtonClassesKey = keyof ButtonClassesType;
|
|
19
|
+
export declare type Classes = ReturnType<typeof useUtilityClasses>;
|
|
@@ -5,7 +5,7 @@ import { unstable_composeClasses } from "@mui/base";
|
|
|
5
5
|
import clsx from "clsx";
|
|
6
6
|
import { jsx } from "react/jsx-runtime";
|
|
7
7
|
import { useMemo } from "react";
|
|
8
|
-
import { I as Image } from "../../Image/index.
|
|
8
|
+
import { I as Image } from "../../Image/index.bf37e923.js";
|
|
9
9
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
10
10
|
import { LoadingButton as LoadingButton$1 } from "@mui/lab";
|
|
11
11
|
import { T as Typography } from "../Typography/index.379dd374.js";
|
|
@@ -146,7 +146,7 @@ function ImageButton({
|
|
|
146
146
|
}) : imageButton
|
|
147
147
|
});
|
|
148
148
|
}
|
|
149
|
-
const componentName = "
|
|
149
|
+
const componentName = "M4LLoadingButton";
|
|
150
150
|
generateUtilityClasses(componentName, [
|
|
151
151
|
"root",
|
|
152
152
|
"skeleton",
|
|
@@ -171,7 +171,7 @@ const useUtilityClasses = (onwerState) => {
|
|
|
171
171
|
};
|
|
172
172
|
};
|
|
173
173
|
const LoadingButtonRoot = styled("div")(({ theme }) => ({
|
|
174
|
-
...theme.components?.
|
|
174
|
+
...theme.components?.M4LLoadingButton?.styleOverrides
|
|
175
175
|
}));
|
|
176
176
|
const LOADINGBUTTON_PREFIX = "M4LoadingButton";
|
|
177
177
|
const getNameDataTestId = (KEY) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useMemo, useState } from "react";
|
|
2
2
|
import { useModuleDictionary, useModuleSkeleton } from "@m4l/core";
|
|
3
3
|
import { Skeleton, styled, generateUtilityClasses, generateUtilityClass, Tooltip, IconButton as IconButton$1 } from "@mui/material";
|
|
4
|
-
import { I as Icon } from "../../Icon/index.
|
|
4
|
+
import { I as Icon } from "../../Icon/index.05984e7f.js";
|
|
5
5
|
import { jsx, Fragment } from "react/jsx-runtime";
|
|
6
6
|
import { unstable_composeClasses } from "@mui/base";
|
|
7
7
|
import clsx from "clsx";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const componentName = "
|
|
1
|
+
export declare const componentName = "M4LLoadingButton";
|
|
@@ -3,12 +3,12 @@ import { useEnvironment, useModuleDictionary } from "@m4l/core";
|
|
|
3
3
|
import { IconButton, generateUtilityClasses, generateUtilityClass, useTheme, MenuItem } from "@mui/material";
|
|
4
4
|
import { P as Popover } from "../Popover/index.b3eca6b1.js";
|
|
5
5
|
import { styled } from "@mui/material/styles";
|
|
6
|
-
import { I as Icon } from "../../Icon/index.
|
|
6
|
+
import { I as Icon } from "../../Icon/index.05984e7f.js";
|
|
7
7
|
import clsx from "clsx";
|
|
8
8
|
import { unstable_composeClasses } from "@mui/base";
|
|
9
9
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
10
10
|
import { B as Badge } from "../Badge/index.09f5aee5.js";
|
|
11
|
-
import { I as IconButton$1 } from "../IconButton/index.
|
|
11
|
+
import { I as IconButton$1 } from "../IconButton/index.26de70bd.js";
|
|
12
12
|
styled(IconButton)(() => ({}));
|
|
13
13
|
const LabelMemuItem = styled("div")(({
|
|
14
14
|
theme
|
|
@@ -2,7 +2,7 @@ import { useMemo } from "react";
|
|
|
2
2
|
import { styled } from "@mui/material/styles";
|
|
3
3
|
import { generateUtilityClasses, generateUtilityClass, useTheme, Select, InputBase, MenuItem } from "@mui/material";
|
|
4
4
|
import { unstable_composeClasses } from "@mui/base";
|
|
5
|
-
import { I as IconButton } from "../IconButton/index.
|
|
5
|
+
import { I as IconButton } from "../IconButton/index.26de70bd.js";
|
|
6
6
|
import { useEnvironment } from "@m4l/core";
|
|
7
7
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
8
8
|
import { useResponsiveDesktop } from "@m4l/graphics";
|
|
@@ -5,7 +5,7 @@ import { jsx } from "react/jsx-runtime";
|
|
|
5
5
|
import { useModuleSkeleton } from "@m4l/core";
|
|
6
6
|
import { styled as styled$1 } from "@mui/material/styles";
|
|
7
7
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
8
|
-
import { g as getNameDataTestId } from "../../../vendor.
|
|
8
|
+
import { g as getNameDataTestId } from "../../../vendor.8f8b0ac9.js";
|
|
9
9
|
import { createContext, useState } from "react";
|
|
10
10
|
const componentName$2 = "M4LTabs";
|
|
11
11
|
generateUtilityClasses(componentName$2, [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx";
|
|
2
|
-
import { B as Button, b as buttonClasses } from "../Button/index.
|
|
2
|
+
import { B as Button, b as buttonClasses } from "../Button/index.570fd3a4.js";
|
|
3
3
|
import { w as withToggle } from "../../../hocs/withToggle/index.e44eb0da.js";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
const ToggleAbleButton = ({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx";
|
|
2
|
-
import { I as IconButton, i as iconButtonClasses } from "../IconButton/index.
|
|
2
|
+
import { I as IconButton, i as iconButtonClasses } from "../IconButton/index.26de70bd.js";
|
|
3
3
|
import { w as withToggle } from "../../../hocs/withToggle/index.e44eb0da.js";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
const ToggleAbleIconButton = ({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createContext, useState } from "react";
|
|
2
|
-
import { M as ModalDialog } from "../../components/ModalDialog/index.
|
|
2
|
+
import { M as ModalDialog } from "../../components/ModalDialog/index.89e26413.js";
|
|
3
3
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
4
4
|
const ModalContext = createContext(null);
|
|
5
5
|
function ModalProvider({
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useNetwork, useFlags, useModuleDictionary } from "@m4l/core";
|
|
2
2
|
import { useState, useEffect } from "react";
|
|
3
|
-
import { u as useModal } from "../useModal/index.
|
|
3
|
+
import { u as useModal } from "../useModal/index.abdc0962.js";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
|
-
import { W as WindowConfirm } from "../../components/modal/WindowConfirm.
|
|
5
|
+
import { W as WindowConfirm } from "../../components/modal/WindowConfirm.19ddbd5d.js";
|
|
6
6
|
function useFormAddEdit(props) {
|
|
7
7
|
const {
|
|
8
8
|
initialValues,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useContext } from "react";
|
|
2
|
-
import { M as ModalContext } from "../../contexts/ModalContext/index.
|
|
2
|
+
import { M as ModalContext } from "../../contexts/ModalContext/index.b39d303d.js";
|
|
3
3
|
function useModal() {
|
|
4
4
|
const context = useContext(ModalContext);
|
|
5
5
|
if (!context)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useContext } from "react";
|
|
2
|
-
import { d as TabContext } from "../../components/mui_extended/Tab/index.
|
|
2
|
+
import { d as TabContext } from "../../components/mui_extended/Tab/index.724d5948.js";
|
|
3
3
|
const useTab = () => {
|
|
4
4
|
const context = useContext(TabContext);
|
|
5
5
|
if (context === null) {
|