@m4l/components 0.1.78 → 0.1.80
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 +31 -1
- package/components/AccountPopover/{index.7e76dbb7.js → index.00d1d15f.js} +10 -6
- package/components/AppBar/{index.06858422.js → index.c85b100d.js} +5 -4
- package/components/CommonActions/components/ActionCancel/{index.d536ccfa.js → index.1051a117.js} +1 -1
- package/components/CommonActions/components/ActionFormCancel/{index.a915b105.js → index.a0d727b2.js} +18 -13
- package/components/CommonActions/components/ActionFormIntro/{index.14e65d6c.js → index.a20dc88d.js} +1 -1
- package/components/CommonActions/components/ActionIntro/{index.aa1648eb.js → index.bfe3256c.js} +1 -1
- package/components/CommonActions/components/Actions/{index.52125041.js → index.19d67bc6.js} +10 -9
- package/components/DataGrid/classes/constants.d.ts +1 -0
- package/components/DataGrid/classes/index.d.ts +27 -0
- package/components/DataGrid/classes/types.d.ts +27 -0
- package/components/DataGrid/contexts/DataGridContext/types.d.ts +3 -1
- package/components/DataGrid/{index.9fb3e6a1.js → index.2f175eba.js} +173 -316
- package/components/DataGrid/subcomponents/Actions/subcomponents/Settings/subcomponents/ColumnsConfig/subcomponents/FormatterColumn/index.d.ts +2 -2
- package/components/DataGrid/subcomponents/Actions/subcomponents/Settings/subcomponents/ColumnsConfig/subcomponents/FormatterColumn/types.d.ts +3 -0
- package/components/DataGrid/subcomponents/Actions/subcomponents/Settings/subcomponents/ColumnsConfig/types.d.ts +2 -0
- package/components/DataGrid/types.d.ts +7 -0
- package/components/DynamicFilter/{index.d1a2e2d1.js → index.c1f9d560.js} +23 -22
- package/components/GridLayout/Responsive/{index.0905a698.js → index.1671380a.js} +1 -1
- package/components/GridLayout/{index.da6fd387.js → index.a792aacb.js} +2 -2
- package/components/HelperText/{index.a019742c.js → index.6ef76993.js} +5 -4
- package/components/LanguagePopover/{index.98b63dcb.js → index.1564bd08.js} +5 -4
- package/components/ModalDialog/{index.d9937d46.js → index.fbc4cd71.js} +3 -3
- package/components/NavLink/{index.a5dea6d3.js → index.6c9c2588.js} +5 -4
- package/components/ObjectLogs/{index.d9d20b9d.js → index.eab1c15f.js} +14 -13
- package/components/Period/{index.7b94c418.js → index.26071a16.js} +16 -15
- package/components/PropertyValue/{index.45c73161.js → index.18d3c0fd.js} +1 -1
- package/components/areas/components/AreasAdmin/{index.43ecd998.js → index.7a0dabbe.js} +23 -22
- package/components/areas/components/AreasViewer/{index.14e62059.js → index.fd49f06c.js} +41 -34
- package/components/areas/components/{index.a87653a9.js → index.7756928a.js} +8 -7
- package/components/areas/contexts/AreasContext/{index.02c4e7be.js → index.0a08a08b.js} +9 -4
- package/components/areas/contexts/AreasContext/types.d.ts +1 -0
- package/components/areas/contexts/WindowToolsMFContext/types.d.ts +1 -0
- package/components/areas/contexts/{index.1ff9b360.js → index.b303b664.js} +1 -1
- package/components/areas/hooks/useAreas/{index.85e4b2e2.js → index.c6eb2569.js} +1 -1
- package/components/areas/{index.d1dcccf5.js → index.6e67d89a.js} +8 -7
- package/components/areas/types.d.ts +5 -0
- package/components/hook-form/RHFAutocomplete/classes/index.d.ts +4 -0
- package/components/hook-form/RHFAutocomplete/classes/types.d.ts +6 -0
- package/components/hook-form/RHFAutocomplete/{index.6aa51705.js → index.d1bbb015.js} +34 -51
- package/components/hook-form/RHFAutocomplete/subcomponents/Skeleton/types.d.ts +2 -1
- package/components/hook-form/RHFAutocompleteAsync/{index.1a3dfe5f.js → index.f9a9ef48.js} +1 -1
- package/components/hook-form/RHFCheckbox/{index.a08a65b3.js → index.7b4a21d7.js} +42 -67
- package/components/hook-form/RHFCheckbox/types.d.ts +2 -1
- package/components/hook-form/RHFDateTime/{index.4d671108.js → index.46cf616e.js} +9 -7
- package/components/hook-form/RHFPeriod/{index.39b4be49.js → index.ce513149.js} +2 -2
- package/components/hook-form/RHFTextField/{index.9004e898.js → index.f7ee202c.js} +4 -3
- package/components/hook-form/RHFUpload/{index.bed8573e.js → index.1befd5bb.js} +6 -5
- package/components/modal/{WindowBase.a0c0b322.js → WindowBase.7e19843e.js} +8 -6
- package/components/modal/{WindowConfirm.6c063f2d.js → WindowConfirm.12a9608a.js} +13 -12
- package/components/modal/{index.00efea85.js → index.b0a7236c.js} +10 -9
- package/components/mui_extended/Accordion/{index.9877f7bf.js → index.a6447bf8.js} +1 -1
- package/components/mui_extended/Badge/classes/constants.d.ts +1 -1
- package/components/mui_extended/Badge/{index.8c2b8b66.js → index.cad260fe.js} +1 -1
- package/components/mui_extended/CheckBox/CheckBox.d.ts +3 -0
- package/components/mui_extended/CheckBox/classes/constants.d.ts +1 -0
- package/components/mui_extended/CheckBox/classes/index.d.ts +8 -0
- package/components/mui_extended/CheckBox/classes/types.d.ts +10 -0
- package/components/mui_extended/CheckBox/index.d.ts +1 -0
- package/components/mui_extended/CheckBox/subcomponents/Skeleton/index.d.ts +3 -0
- package/components/mui_extended/CheckBox/subcomponents/Skeleton/types.d.ts +4 -0
- package/components/mui_extended/CheckBox/types.d.ts +5 -0
- package/components/mui_extended/CheckBox.5f6c78b0.js +86 -0
- package/components/mui_extended/Pager/classes/constants.d.ts +1 -0
- package/components/mui_extended/Pager/classes/index.d.ts +10 -0
- package/components/mui_extended/Pager/classes/types.d.ts +10 -0
- package/components/mui_extended/Pager/{index.2f6d6d7d.js → index.82e89328.js} +67 -31
- package/components/mui_extended/Tab/{index.7c82e43d.js → index.c39a6681.js} +1 -1
- package/components/mui_extended/index.d.ts +1 -0
- package/components/mui_extended/{index.0e2ff642.js → index.d78bde19.js} +5 -4
- package/contexts/ModalContext/{index.e9a7ba4a.js → index.89805978.js} +1 -1
- package/hooks/useModal/{index.8e85f7ae.js → index.e1c5c31e.js} +1 -1
- package/index.js +46 -44
- package/package.json +1 -1
- package/{vendor.e353394b.js → vendor.f57d47a7.js} +38 -37
- package/components/hook-form/RHFCheckbox/subcomponents/Skeleton/index.d.ts +0 -3
- package/components/hook-form/RHFCheckbox/subcomponents/Skeleton/types.d.ts +0 -5
|
@@ -13,10 +13,10 @@ import { a as AREAS_VIEWER_CLASS_NAME } from "../../constants.66529246.js";
|
|
|
13
13
|
import { shallow } from "zustand/shallow";
|
|
14
14
|
import React__default, { useMemo, useState, useCallback, useEffect } from "react";
|
|
15
15
|
import clsx from "clsx";
|
|
16
|
-
import { u as useAreasStore } from "../../hooks/useAreas/index.
|
|
16
|
+
import { u as useAreasStore } from "../../hooks/useAreas/index.c6eb2569.js";
|
|
17
17
|
import { useModuleDictionary, useEnvironment, useModuleSkeleton, useNetwork, useHostTools, axiosOperation } from "@m4l/core";
|
|
18
18
|
import { I as IconButton } from "../../../mui_extended/IconButton/index.12f1a3c3.js";
|
|
19
|
-
import "../../../mui_extended/Accordion/index.
|
|
19
|
+
import "../../../mui_extended/Accordion/index.a6447bf8.js";
|
|
20
20
|
import { I as Icon } from "../../../Icon/index.9fcd1476.js";
|
|
21
21
|
import { T as Typography } from "../../../mui_extended/Typography/index.443590d6.js";
|
|
22
22
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
@@ -24,15 +24,16 @@ import "../../../mui_extended/Avatar/index.75e6ed57.js";
|
|
|
24
24
|
import "react-router-dom";
|
|
25
25
|
import "@mui/material/Button";
|
|
26
26
|
import { B as Button } from "../../../mui_extended/Button/index.4288f9fc.js";
|
|
27
|
-
import "
|
|
27
|
+
import { useResponsiveDesktop, useHostTheme, useFormatter, useLocales, useFirstRender } from "@m4l/graphics";
|
|
28
|
+
import "../../../mui_extended/CheckBox.5f6c78b0.js";
|
|
29
|
+
import "../../../mui_extended/Badge/index.cad260fe.js";
|
|
28
30
|
import "../../../Image/index.c18ebf5a.js";
|
|
29
31
|
import "@mui/lab";
|
|
30
32
|
import { M as MenuActions, a as MemonizedMenuActions } from "../../../mui_extended/MenuActions/index.43a2e1ae.js";
|
|
31
33
|
import "../../../mui_extended/Popover/index.9f35d0eb.js";
|
|
32
|
-
import "../../../mui_extended/Pager/index.
|
|
33
|
-
import "../../../mui_extended/Tab/index.
|
|
34
|
+
import "../../../mui_extended/Pager/index.82e89328.js";
|
|
35
|
+
import "../../../mui_extended/Tab/index.c39a6681.js";
|
|
34
36
|
import "../../../mui_extended/Tooltip/index.5a795dcd.js";
|
|
35
|
-
import { useResponsiveDesktop, useHostTheme, useFormatter, useLocales, useFirstRender } from "@m4l/graphics";
|
|
36
37
|
import { I as ICONS } from "../../icons.8266ccc8.js";
|
|
37
38
|
import { g as getAreasDictionary, D as DICCTIONARY } from "../../dictionary.afb7e3d9.js";
|
|
38
39
|
import { L as LinearProgressIndeterminate } from "../../../LinearProgressIndeterminate/index.60dabc06.js";
|
|
@@ -40,55 +41,55 @@ import debounce from "lodash/debounce";
|
|
|
40
41
|
import { L as LinearProgress } from "../../../mui_extended/LinearProgress/index.c92b9ba9.js";
|
|
41
42
|
import { W as WindowToolsMFProvider } from "../../contexts/WindowToolsMFContext/index.8f3e2a04.js";
|
|
42
43
|
import { D as DynamicMFParmsProvider } from "../../contexts/DynamicMFParmsContext/index.1607c78e.js";
|
|
43
|
-
import "../../../../contexts/ModalContext/index.
|
|
44
|
+
import "../../../../contexts/ModalContext/index.89805978.js";
|
|
44
45
|
import "../../../../contexts/RHFormContext/index.fe175bab.js";
|
|
45
|
-
import "../../../GridLayout/index.
|
|
46
|
-
import { R as Responsive } from "../../../GridLayout/Responsive/index.
|
|
46
|
+
import "../../../GridLayout/index.a792aacb.js";
|
|
47
|
+
import { R as Responsive } from "../../../GridLayout/Responsive/index.1671380a.js";
|
|
47
48
|
import { W as WidthProvider } from "../../../GridLayout/WidthProvider/index.9a26dfe4.js";
|
|
48
|
-
import { R as ROW_HEIGTH_GRIDLAYOUT, M as MARGIN_GRIDLAYOUT, P as PADDING_GRIDLAYOUT } from "../../contexts/AreasContext/index.
|
|
49
|
+
import { R as ROW_HEIGTH_GRIDLAYOUT, M as MARGIN_GRIDLAYOUT, P as PADDING_GRIDLAYOUT } from "../../contexts/AreasContext/index.0a08a08b.js";
|
|
49
50
|
import "../../../animate/index.1f8eadd4.js";
|
|
50
51
|
import "framer-motion";
|
|
51
52
|
import "../../../animate/LoadingScreen/index.1d0c4307.js";
|
|
52
53
|
import "../../../animate/PropagateLoader/index.7fab43c8.js";
|
|
53
|
-
import "../AreasAdmin/index.
|
|
54
|
+
import "../AreasAdmin/index.7a0dabbe.js";
|
|
54
55
|
import "../../../ScrollBar/index.bbe48f4d.js";
|
|
55
56
|
import "zustand";
|
|
56
57
|
import "react-hook-form";
|
|
57
|
-
import "../../../hook-form/RHFAutocomplete/index.
|
|
58
|
-
import "../../../HelperText/index.
|
|
59
|
-
import "../../../hook-form/RHFAutocompleteAsync/index.
|
|
60
|
-
import "../../../hook-form/RHFCheckbox/index.
|
|
58
|
+
import "../../../hook-form/RHFAutocomplete/index.d1bbb015.js";
|
|
59
|
+
import "../../../HelperText/index.6ef76993.js";
|
|
60
|
+
import "../../../hook-form/RHFAutocompleteAsync/index.f9a9ef48.js";
|
|
61
|
+
import "../../../hook-form/RHFCheckbox/index.7b4a21d7.js";
|
|
61
62
|
import "@mui/x-date-pickers";
|
|
62
|
-
import "../../../hook-form/RHFDateTime/index.
|
|
63
|
-
import "../../../hook-form/RHFTextField/index.
|
|
64
|
-
import "../../../hook-form/RHFPeriod/index.
|
|
65
|
-
import "../../../Period/index.
|
|
66
|
-
import "../../../CommonActions/components/Actions/index.
|
|
63
|
+
import "../../../hook-form/RHFDateTime/index.46cf616e.js";
|
|
64
|
+
import "../../../hook-form/RHFTextField/index.f7ee202c.js";
|
|
65
|
+
import "../../../hook-form/RHFPeriod/index.ce513149.js";
|
|
66
|
+
import "../../../Period/index.26071a16.js";
|
|
67
|
+
import "../../../CommonActions/components/Actions/index.19d67bc6.js";
|
|
67
68
|
import { c as cjs } from "../../../../react-draggable.7abb5d0a.js";
|
|
68
69
|
import { R as ResizeableWindow } from "../../../Resizeable/index.9a9c79a4.js";
|
|
69
|
-
import "../../../modal/index.
|
|
70
|
+
import "../../../modal/index.b0a7236c.js";
|
|
70
71
|
import "lodash/isString";
|
|
71
72
|
import "react-dropzone";
|
|
72
|
-
import "../../../hook-form/RHFUpload/index.
|
|
73
|
-
import "../../../DataGrid/index.
|
|
73
|
+
import "../../../hook-form/RHFUpload/index.1befd5bb.js";
|
|
74
|
+
import "../../../DataGrid/index.2f175eba.js";
|
|
74
75
|
import "react-dnd";
|
|
75
76
|
import "react-dnd-html5-backend";
|
|
76
|
-
import "../../../DynamicFilter/index.
|
|
77
|
+
import "../../../DynamicFilter/index.c1f9d560.js";
|
|
77
78
|
import "yup";
|
|
78
79
|
import "lodash";
|
|
79
|
-
import "../../../LanguagePopover/index.
|
|
80
|
-
import "../../../NavLink/index.
|
|
80
|
+
import "../../../LanguagePopover/index.1564bd08.js";
|
|
81
|
+
import "../../../NavLink/index.6c9c2588.js";
|
|
81
82
|
import "../../../NoItemSelected/index.23dfc897.js";
|
|
82
|
-
import "../../../ObjectLogs/index.
|
|
83
|
+
import "../../../ObjectLogs/index.eab1c15f.js";
|
|
83
84
|
import "../../../../react-json-view.57125fcf.js";
|
|
84
85
|
import "../../../PaperForm/index.ba38a0bd.js";
|
|
85
86
|
import "../../../Page/index.4237c241.js";
|
|
86
|
-
import "../../../PropertyValue/index.
|
|
87
|
+
import "../../../PropertyValue/index.18d3c0fd.js";
|
|
87
88
|
import "../../../SplitLayout/index.9ef430f6.js";
|
|
88
89
|
import "../../../../react-splitter-layout.8b1655c8.js";
|
|
89
90
|
import "../../../SideBar/index.2f497e6c.js";
|
|
90
|
-
import "../../../AppBar/index.
|
|
91
|
-
import "../../../AccountPopover/index.
|
|
91
|
+
import "../../../AppBar/index.c85b100d.js";
|
|
92
|
+
import "../../../AccountPopover/index.00d1d15f.js";
|
|
92
93
|
const areasViewerClasses = generateUtilityClasses(AREAS_VIEWER_CLASS_NAME, [
|
|
93
94
|
"root",
|
|
94
95
|
"areaRoot",
|
|
@@ -719,7 +720,7 @@ function Header(props) {
|
|
|
719
720
|
windowId,
|
|
720
721
|
emergeType
|
|
721
722
|
} = props;
|
|
722
|
-
const [url_icon, title, moduleActions, onClose, version, windowOptions] = useAreasStore((state) => {
|
|
723
|
+
const [url_icon, title, moduleActions, onClose, version, windowOptions, fnQueryClose] = useAreasStore((state) => {
|
|
723
724
|
const window2 = state.hashWindows[windowId];
|
|
724
725
|
return [
|
|
725
726
|
window2.url_icon,
|
|
@@ -727,7 +728,8 @@ function Header(props) {
|
|
|
727
728
|
window2.moduleActions,
|
|
728
729
|
window2.onClose,
|
|
729
730
|
window2.version,
|
|
730
|
-
window2.windowOptions
|
|
731
|
+
window2.windowOptions,
|
|
732
|
+
window2.fnQueryClose
|
|
731
733
|
];
|
|
732
734
|
}, shallow);
|
|
733
735
|
const {
|
|
@@ -768,7 +770,8 @@ function Header(props) {
|
|
|
768
770
|
});
|
|
769
771
|
}, [moduleActions, isDesktop]);
|
|
770
772
|
const onCloseLocal = () => {
|
|
771
|
-
|
|
773
|
+
const fnClose = fnQueryClose || onClose;
|
|
774
|
+
fnClose && fnClose(windowId);
|
|
772
775
|
};
|
|
773
776
|
const maxNormalize = (e) => {
|
|
774
777
|
if (maximizedId === windowId) {
|
|
@@ -1348,7 +1351,8 @@ const Window = (props) => {
|
|
|
1348
1351
|
close,
|
|
1349
1352
|
startProgress,
|
|
1350
1353
|
stopProgress,
|
|
1351
|
-
toast
|
|
1354
|
+
toast,
|
|
1355
|
+
setFnQueryClose
|
|
1352
1356
|
} = useAreasStore((state) => state.windowActions, shallow);
|
|
1353
1357
|
const {
|
|
1354
1358
|
selectLayout
|
|
@@ -1374,6 +1378,9 @@ const Window = (props) => {
|
|
|
1374
1378
|
close: () => close(windowId),
|
|
1375
1379
|
startProgress: () => startProgress(windowId),
|
|
1376
1380
|
stopProgress: () => stopProgress(windowId),
|
|
1381
|
+
setFnQueryClose: (fnQueryClose) => {
|
|
1382
|
+
setFnQueryClose(windowId, fnQueryClose);
|
|
1383
|
+
},
|
|
1377
1384
|
toast: (toastyOptions) => {
|
|
1378
1385
|
toast(windowId, toastyOptions);
|
|
1379
1386
|
}
|
|
@@ -7,23 +7,24 @@ import "react/jsx-runtime";
|
|
|
7
7
|
import "../../mui_extended/IconButton/index.12f1a3c3.js";
|
|
8
8
|
import "@m4l/graphics";
|
|
9
9
|
import "zustand";
|
|
10
|
-
import "../contexts/AreasContext/index.
|
|
11
|
-
import "./AreasAdmin/index.
|
|
10
|
+
import "../contexts/AreasContext/index.0a08a08b.js";
|
|
11
|
+
import "./AreasAdmin/index.7a0dabbe.js";
|
|
12
12
|
import "zustand/shallow";
|
|
13
13
|
import "../../ScrollBar/index.bbe48f4d.js";
|
|
14
|
-
import "../../mui_extended/Accordion/index.
|
|
14
|
+
import "../../mui_extended/Accordion/index.a6447bf8.js";
|
|
15
15
|
import "../../mui_extended/Typography/index.443590d6.js";
|
|
16
16
|
import "../../mui_extended/Avatar/index.75e6ed57.js";
|
|
17
17
|
import "react-router-dom";
|
|
18
18
|
import "@mui/material/Button";
|
|
19
19
|
import "../../mui_extended/Button/index.4288f9fc.js";
|
|
20
|
-
import "../../mui_extended/
|
|
20
|
+
import "../../mui_extended/CheckBox.5f6c78b0.js";
|
|
21
|
+
import "../../mui_extended/Badge/index.cad260fe.js";
|
|
21
22
|
import "../../Image/index.c18ebf5a.js";
|
|
22
23
|
import "@mui/lab";
|
|
23
24
|
import "../../mui_extended/MenuActions/index.43a2e1ae.js";
|
|
24
25
|
import "../../mui_extended/Popover/index.9f35d0eb.js";
|
|
25
|
-
import "../../mui_extended/Pager/index.
|
|
26
|
-
import "../../mui_extended/Tab/index.
|
|
26
|
+
import "../../mui_extended/Pager/index.82e89328.js";
|
|
27
|
+
import "../../mui_extended/Tab/index.c39a6681.js";
|
|
27
28
|
import "../../mui_extended/Tooltip/index.5a795dcd.js";
|
|
28
|
-
import "./AreasViewer/index.
|
|
29
|
+
import "./AreasViewer/index.fd49f06c.js";
|
|
29
30
|
import "../../LinearProgressIndeterminate/index.60dabc06.js";
|
|
@@ -5,13 +5,13 @@ import { useResponsiveDesktop, useFirstRender } from "@m4l/graphics";
|
|
|
5
5
|
import { useHostTools, useModuleDictionary, useNetwork, useModuleSkeleton, EmitEvents } from "@m4l/core";
|
|
6
6
|
import { devtools } from "zustand/middleware";
|
|
7
7
|
import { immer } from "zustand/middleware/immer";
|
|
8
|
-
import { u as useAreasViewerUtilityClasses } from "../../components/AreasViewer/index.
|
|
9
|
-
import { u as useAreasAdminUtilityClasses } from "../../components/AreasAdmin/index.
|
|
8
|
+
import { u as useAreasViewerUtilityClasses } from "../../components/AreasViewer/index.fd49f06c.js";
|
|
9
|
+
import { u as useAreasAdminUtilityClasses } from "../../components/AreasAdmin/index.7a0dabbe.js";
|
|
10
10
|
import { c as createDynamicMFStore } from "../DynamicMFParmsContext/index.1607c78e.js";
|
|
11
11
|
import { g as getAreasDictionary, D as DICCTIONARY } from "../../dictionary.afb7e3d9.js";
|
|
12
12
|
import "clsx";
|
|
13
|
-
import "../../../GridLayout/index.
|
|
14
|
-
import { a as addLayoutItemToBreakPointIfNoExists, b as addLayoutItemToBreakPoints, c as isEqualLayouts } from "../../../GridLayout/Responsive/index.
|
|
13
|
+
import "../../../GridLayout/index.a792aacb.js";
|
|
14
|
+
import { a as addLayoutItemToBreakPointIfNoExists, b as addLayoutItemToBreakPoints, c as isEqualLayouts } from "../../../GridLayout/Responsive/index.1671380a.js";
|
|
15
15
|
import { jsx } from "react/jsx-runtime";
|
|
16
16
|
import { debounce, cloneDeep } from "lodash";
|
|
17
17
|
const ROW_HEIGTH_GRIDLAYOUT = 20;
|
|
@@ -966,6 +966,11 @@ const createAreasStore = (initProps) => {
|
|
|
966
966
|
verifyRemoveToasty(state.hashWindows[windowId], toastyId, true);
|
|
967
967
|
});
|
|
968
968
|
},
|
|
969
|
+
setFnQueryClose: (windowId, fnQueryClose) => {
|
|
970
|
+
set((state) => {
|
|
971
|
+
state.hashWindows[windowId].fnQueryClose = fnQueryClose;
|
|
972
|
+
});
|
|
973
|
+
},
|
|
969
974
|
pinToast: (windowId, toastyId) => {
|
|
970
975
|
set((state) => {
|
|
971
976
|
const t = state.hashWindows[windowId].hashToasties[toastyId];
|
|
@@ -195,6 +195,7 @@ export interface AreasStateWithActions extends AreasState {
|
|
|
195
195
|
toast: (windowId: string, options: ToastyOptions) => void;
|
|
196
196
|
closeToast: (windowId: string, toastyId: number) => void;
|
|
197
197
|
pinToast: (windowId: string, toastyId: number) => void;
|
|
198
|
+
setFnQueryClose: (windowId: string, fnQueryClose: () => void) => void;
|
|
198
199
|
};
|
|
199
200
|
}
|
|
200
201
|
export declare type DefaultAreasStoreProps = Omit<AreasState, 'currentArea'>;
|
|
@@ -10,6 +10,7 @@ export interface WindowToolsMF {
|
|
|
10
10
|
stopProgress: () => void;
|
|
11
11
|
toast: (options: ToastyOptions) => void;
|
|
12
12
|
close: () => void;
|
|
13
|
+
setFnQueryClose: (fnQueryClose: () => void) => void;
|
|
13
14
|
}
|
|
14
15
|
export interface WindowToolsMFProviderProps extends WindowToolsMF {
|
|
15
16
|
children: ReactNode;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import "./AreasContext/index.
|
|
1
|
+
import "./AreasContext/index.0a08a08b.js";
|
|
2
2
|
import "./WindowToolsMFContext/index.8f3e2a04.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useContext } from "react";
|
|
2
2
|
import { useStore } from "zustand";
|
|
3
|
-
import { A as AreasContext } from "../../contexts/AreasContext/index.
|
|
3
|
+
import { A as AreasContext } from "../../contexts/AreasContext/index.0a08a08b.js";
|
|
4
4
|
function useAreasStore(selector, equalityFn) {
|
|
5
5
|
const context = useContext(AreasContext);
|
|
6
6
|
if (!context)
|
|
@@ -7,25 +7,26 @@ import "react/jsx-runtime";
|
|
|
7
7
|
import "../mui_extended/IconButton/index.12f1a3c3.js";
|
|
8
8
|
import "@m4l/graphics";
|
|
9
9
|
import "zustand";
|
|
10
|
-
import "./contexts/AreasContext/index.
|
|
11
|
-
import "./components/AreasAdmin/index.
|
|
10
|
+
import "./contexts/AreasContext/index.0a08a08b.js";
|
|
11
|
+
import "./components/AreasAdmin/index.7a0dabbe.js";
|
|
12
12
|
import "zustand/shallow";
|
|
13
13
|
import "../ScrollBar/index.bbe48f4d.js";
|
|
14
|
-
import "../mui_extended/Accordion/index.
|
|
14
|
+
import "../mui_extended/Accordion/index.a6447bf8.js";
|
|
15
15
|
import "../mui_extended/Typography/index.443590d6.js";
|
|
16
16
|
import "../mui_extended/Avatar/index.75e6ed57.js";
|
|
17
17
|
import "react-router-dom";
|
|
18
18
|
import "@mui/material/Button";
|
|
19
19
|
import "../mui_extended/Button/index.4288f9fc.js";
|
|
20
|
-
import "../mui_extended/
|
|
20
|
+
import "../mui_extended/CheckBox.5f6c78b0.js";
|
|
21
|
+
import "../mui_extended/Badge/index.cad260fe.js";
|
|
21
22
|
import "../Image/index.c18ebf5a.js";
|
|
22
23
|
import "@mui/lab";
|
|
23
24
|
import "../mui_extended/MenuActions/index.43a2e1ae.js";
|
|
24
25
|
import "../mui_extended/Popover/index.9f35d0eb.js";
|
|
25
|
-
import "../mui_extended/Pager/index.
|
|
26
|
-
import "../mui_extended/Tab/index.
|
|
26
|
+
import "../mui_extended/Pager/index.82e89328.js";
|
|
27
|
+
import "../mui_extended/Tab/index.c39a6681.js";
|
|
27
28
|
import "../mui_extended/Tooltip/index.5a795dcd.js";
|
|
28
|
-
import "./components/AreasViewer/index.
|
|
29
|
+
import "./components/AreasViewer/index.fd49f06c.js";
|
|
29
30
|
import "../LinearProgressIndeterminate/index.60dabc06.js";
|
|
30
31
|
import "./contexts/WindowToolsMFContext/index.8f3e2a04.js";
|
|
31
32
|
import "./contexts/DynamicMFParmsContext/index.1607c78e.js";
|
|
@@ -55,6 +55,11 @@ export declare type WindowState = {
|
|
|
55
55
|
toasties: Toasty[];
|
|
56
56
|
hashToasties: Record<number, Toasty>;
|
|
57
57
|
toastyCount: number;
|
|
58
|
+
/**
|
|
59
|
+
* "fnQueryClose" función que reemplaza la opción de cerrado normal de la ventana
|
|
60
|
+
* @returns void
|
|
61
|
+
*/
|
|
62
|
+
fnQueryClose?: () => void;
|
|
58
63
|
};
|
|
59
64
|
export declare type WindowOptions = {
|
|
60
65
|
allowPersistCookies: boolean;
|
|
@@ -1,8 +1,13 @@
|
|
|
1
|
+
import { useUtilityClasses } from ".";
|
|
1
2
|
export interface RHFAutocompleteClassesType {
|
|
2
3
|
root: string;
|
|
3
4
|
withImage: string;
|
|
4
5
|
skeleton: string;
|
|
5
6
|
label: string;
|
|
7
|
+
popper: string;
|
|
8
|
+
skeletonRoot: string;
|
|
9
|
+
skeletonContainerText: string;
|
|
10
|
+
iconDown: string;
|
|
6
11
|
variantInfo: string;
|
|
7
12
|
isDisabled: string;
|
|
8
13
|
variantSuccess: string;
|
|
@@ -13,3 +18,4 @@ export interface RHFAutocompleteClassesType {
|
|
|
13
18
|
isFocus: string;
|
|
14
19
|
}
|
|
15
20
|
export declare type RHFAutocompleteClassesKey = keyof RHFAutocompleteClassesType;
|
|
21
|
+
export declare type Classes = ReturnType<typeof useUtilityClasses>;
|
|
@@ -1,29 +1,30 @@
|
|
|
1
1
|
import { useModuleDictionary, useModuleSkeleton, useEnvironment } from "@m4l/core";
|
|
2
2
|
import { useFormContext, Controller } from "react-hook-form";
|
|
3
|
-
import {
|
|
3
|
+
import { Skeleton, generateUtilityClasses, generateUtilityClass, useTheme, Autocomplete, Popper, TextField, CircularProgress } from "@mui/material";
|
|
4
4
|
import { I as Image } from "../../Image/index.c18ebf5a.js";
|
|
5
5
|
import { useMemo, useRef, useState, useEffect } from "react";
|
|
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 { T as Typography } from "../../mui_extended/Typography/index.443590d6.js";
|
|
9
|
-
import { H as HelperText } from "../../HelperText/index.
|
|
9
|
+
import { H as HelperText } from "../../HelperText/index.6ef76993.js";
|
|
10
10
|
import { I as IconButton } from "../../mui_extended/IconButton/index.12f1a3c3.js";
|
|
11
|
+
import { useResponsiveDesktop } from "@m4l/graphics";
|
|
11
12
|
import { styled } from "@mui/material/styles";
|
|
12
13
|
import "clsx";
|
|
13
14
|
import { unstable_composeClasses } from "@mui/base";
|
|
14
15
|
import "../../Icon/index.9fcd1476.js";
|
|
15
|
-
import "
|
|
16
|
-
import "../../mui_extended/Accordion/index.9877f7bf.js";
|
|
16
|
+
import "../../mui_extended/Accordion/index.a6447bf8.js";
|
|
17
17
|
import "../../mui_extended/Avatar/index.75e6ed57.js";
|
|
18
18
|
import "react-router-dom";
|
|
19
19
|
import "@mui/material/Button";
|
|
20
20
|
import "../../mui_extended/Button/index.4288f9fc.js";
|
|
21
|
-
import "../../mui_extended/
|
|
21
|
+
import "../../mui_extended/CheckBox.5f6c78b0.js";
|
|
22
|
+
import "../../mui_extended/Badge/index.cad260fe.js";
|
|
22
23
|
import "@mui/lab";
|
|
23
24
|
import "../../mui_extended/MenuActions/index.43a2e1ae.js";
|
|
24
25
|
import "../../mui_extended/Popover/index.9f35d0eb.js";
|
|
25
|
-
import "../../mui_extended/Pager/index.
|
|
26
|
-
import "../../mui_extended/Tab/index.
|
|
26
|
+
import "../../mui_extended/Pager/index.82e89328.js";
|
|
27
|
+
import "../../mui_extended/Tab/index.c39a6681.js";
|
|
27
28
|
import "../../mui_extended/Tooltip/index.5a795dcd.js";
|
|
28
29
|
const AutocompleteRoot = styled("div")(({
|
|
29
30
|
theme
|
|
@@ -56,36 +57,6 @@ function withRenderOption(getUrlImage, classes) {
|
|
|
56
57
|
});
|
|
57
58
|
};
|
|
58
59
|
}
|
|
59
|
-
const WrapperSkeletonRHFAutocomplete = styled$1("div")(({
|
|
60
|
-
theme
|
|
61
|
-
}) => ({
|
|
62
|
-
width: "100%",
|
|
63
|
-
display: "flex",
|
|
64
|
-
justifyContent: "space-between",
|
|
65
|
-
alignItems: "center",
|
|
66
|
-
height: `${theme.spacing(4.5)}`,
|
|
67
|
-
border: `1px solid ${theme.palette.divider}`,
|
|
68
|
-
borderRadius: `${theme.spacing(1)}`,
|
|
69
|
-
padding: `0 ${theme.spacing(2)}`,
|
|
70
|
-
overflow: "hidden",
|
|
71
|
-
[theme.breakpoints.down("md")]: {
|
|
72
|
-
width: "100%"
|
|
73
|
-
}
|
|
74
|
-
}));
|
|
75
|
-
const SkeletonContainerText = styled$1("div")(({
|
|
76
|
-
theme
|
|
77
|
-
}) => ({
|
|
78
|
-
width: "100%",
|
|
79
|
-
height: "auto",
|
|
80
|
-
overflow: "hidden",
|
|
81
|
-
margin: theme.spacing(1.5)
|
|
82
|
-
}));
|
|
83
|
-
const SkeletonRHFAutocompleteRoot = styled$1("div")(() => ({
|
|
84
|
-
display: "flex",
|
|
85
|
-
flexDirection: "column",
|
|
86
|
-
gap: "4px",
|
|
87
|
-
width: "100%"
|
|
88
|
-
}));
|
|
89
60
|
const SkeletonRHFAutocomplete = (props) => {
|
|
90
61
|
const {
|
|
91
62
|
withImage,
|
|
@@ -96,21 +67,20 @@ const SkeletonRHFAutocomplete = (props) => {
|
|
|
96
67
|
classes,
|
|
97
68
|
hasLabel
|
|
98
69
|
} = props;
|
|
99
|
-
return /* @__PURE__ */ jsxs(
|
|
70
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
71
|
+
className: classes.skeletonRoot,
|
|
100
72
|
children: [(hasLabel || hasLabel?.length === 0) && /* @__PURE__ */ jsx(Skeleton, {
|
|
101
73
|
variant: "text",
|
|
102
74
|
width: "30%",
|
|
103
75
|
height: "16px"
|
|
104
|
-
}), /* @__PURE__ */ jsx(
|
|
76
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
105
77
|
className: classes.skeleton,
|
|
106
78
|
...process.env.NODE_ENV !== "production" ? {
|
|
107
79
|
[TEST_PROP_ID]: getNameDataTestId("skeleton")
|
|
108
80
|
} : {},
|
|
109
81
|
children: !withImage ? /* @__PURE__ */ jsxs(Fragment, {
|
|
110
|
-
children: [/* @__PURE__ */ jsx(
|
|
111
|
-
|
|
112
|
-
marginLeft: "0px"
|
|
113
|
-
},
|
|
82
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
83
|
+
className: classes.skeletonContainerText,
|
|
114
84
|
children: /* @__PURE__ */ jsx(Skeleton, {
|
|
115
85
|
variant: "text",
|
|
116
86
|
width: skeletonWidth,
|
|
@@ -132,7 +102,8 @@ const SkeletonRHFAutocomplete = (props) => {
|
|
|
132
102
|
sx: {
|
|
133
103
|
minWidth: imageWidth
|
|
134
104
|
}
|
|
135
|
-
}), /* @__PURE__ */ jsx(
|
|
105
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
106
|
+
className: classes.skeletonContainerText,
|
|
136
107
|
children: /* @__PURE__ */ jsx(Skeleton, {
|
|
137
108
|
variant: "text",
|
|
138
109
|
width: skeletonWidth,
|
|
@@ -156,6 +127,10 @@ generateUtilityClasses(componentName, [
|
|
|
156
127
|
"withImage",
|
|
157
128
|
"skeleton",
|
|
158
129
|
"label",
|
|
130
|
+
"popper",
|
|
131
|
+
"skeletonRoot",
|
|
132
|
+
"skeletonContainerText",
|
|
133
|
+
"iconDown",
|
|
159
134
|
"variantInfo",
|
|
160
135
|
"isDisabled",
|
|
161
136
|
"variantSuccess",
|
|
@@ -173,7 +148,11 @@ const useUtilityClasses = (ownerState) => {
|
|
|
173
148
|
root: ["root", ownerState.size === "small" && "sizeSmall", ownerState.size === "medium" && "sizeMedium", ownerState.focus && "isFocus", ownerState.disabled && "isDisabled", ownerState.variant === "info" && "variantInfo", ownerState.variant === "success" && "variantSuccess", ownerState.variant === "warning" && "variantWarning", ownerState.variant === "error" && "variantError"],
|
|
174
149
|
withImage: ["withImage"],
|
|
175
150
|
skeleton: ["skeleton"],
|
|
176
|
-
label: ["label"]
|
|
151
|
+
label: ["label"],
|
|
152
|
+
popper: ["popper"],
|
|
153
|
+
skeletonRoot: ["skeletonRoot"],
|
|
154
|
+
skeletonContainerText: ["SkeletonContainerText"],
|
|
155
|
+
iconDown: ["iconDown"]
|
|
177
156
|
};
|
|
178
157
|
const composedClasses = unstable_composeClasses(slots, getRHFAutocompleteClassesUtilityClass, {});
|
|
179
158
|
return {
|
|
@@ -213,6 +192,7 @@ function RHFAutocomplete(props) {
|
|
|
213
192
|
} = useEnvironment();
|
|
214
193
|
const autocompleteRef = useRef(null);
|
|
215
194
|
const [open, setOpen] = useState(false);
|
|
195
|
+
const isDesktop = useResponsiveDesktop();
|
|
216
196
|
const onCloseLocal = (event, reason) => {
|
|
217
197
|
setOpen(false);
|
|
218
198
|
if (onClose)
|
|
@@ -265,12 +245,13 @@ function RHFAutocomplete(props) {
|
|
|
265
245
|
setIsFocus(false);
|
|
266
246
|
};
|
|
267
247
|
const ownerState = {
|
|
268
|
-
size,
|
|
248
|
+
size: !isDesktop ? "medium" : size,
|
|
269
249
|
focus: isFocus,
|
|
270
250
|
variant: currentVariant,
|
|
271
251
|
disabled
|
|
272
252
|
};
|
|
273
253
|
const classes = useUtilityClasses(ownerState);
|
|
254
|
+
const theme = useTheme();
|
|
274
255
|
return /* @__PURE__ */ jsx(AutocompleteRoot, {
|
|
275
256
|
className: classes.root,
|
|
276
257
|
...process.env.NODE_ENV !== "production" ? {
|
|
@@ -309,6 +290,7 @@ function RHFAutocomplete(props) {
|
|
|
309
290
|
}), /* @__PURE__ */ jsx(Autocomplete, {
|
|
310
291
|
onKeyDown: checkKeyDown,
|
|
311
292
|
autoComplete: true,
|
|
293
|
+
size,
|
|
312
294
|
ref: autocompleteRef,
|
|
313
295
|
onFocus: handleFocus,
|
|
314
296
|
onBlur: handleBlur,
|
|
@@ -320,11 +302,10 @@ function RHFAutocomplete(props) {
|
|
|
320
302
|
PopperComponent: (props2) => {
|
|
321
303
|
return /* @__PURE__ */ jsx(Popper, {
|
|
322
304
|
...props2,
|
|
305
|
+
className: classes.popper,
|
|
323
306
|
placement: "bottom-start",
|
|
324
307
|
sx: {
|
|
325
|
-
|
|
326
|
-
top: "50px"
|
|
327
|
-
}
|
|
308
|
+
...theme.components?.M4LRHFAutocompletePopover?.styleOverrides
|
|
328
309
|
}
|
|
329
310
|
});
|
|
330
311
|
},
|
|
@@ -363,6 +344,7 @@ function RHFAutocomplete(props) {
|
|
|
363
344
|
shrink: true
|
|
364
345
|
},
|
|
365
346
|
fullWidth: true,
|
|
347
|
+
size,
|
|
366
348
|
SelectProps: {
|
|
367
349
|
native: true
|
|
368
350
|
},
|
|
@@ -378,9 +360,10 @@ function RHFAutocomplete(props) {
|
|
|
378
360
|
color: "inherit",
|
|
379
361
|
size: 20
|
|
380
362
|
}) : /* @__PURE__ */ jsx(IconButton, {
|
|
381
|
-
|
|
363
|
+
className: classes.iconDown,
|
|
364
|
+
src: `${host_static_assets}/${environment_assets}/frontend/components/RHFAutocompletarAsync/assets/icons/chevronDown.svg`,
|
|
382
365
|
onClick: (event) => onOpenLocal(event),
|
|
383
|
-
size
|
|
366
|
+
size
|
|
384
367
|
})
|
|
385
368
|
})
|
|
386
369
|
},
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { Classes } from '../../classes/types';
|
|
1
2
|
import { RHFAutocompleteProps } from '../../types';
|
|
2
3
|
export interface SkeletonRHFAutocompleteProps extends Pick<RHFAutocompleteProps<any>, 'skeletonWidth' | 'skeletonHeight' | 'imageWidth' | 'imageHeight'> {
|
|
3
4
|
withImage: boolean;
|
|
4
|
-
classes:
|
|
5
|
+
classes: Classes;
|
|
5
6
|
hasLabel?: string;
|
|
6
7
|
}
|
|
@@ -5,7 +5,7 @@ import { styled } from "@mui/material/styles";
|
|
|
5
5
|
import { generateUtilityClasses, generateUtilityClass } from "@mui/material";
|
|
6
6
|
import { unstable_composeClasses } from "@mui/base";
|
|
7
7
|
import { T as TEST_PROP_ID } from "../../../test/constants_no_mock.86c553a9.js";
|
|
8
|
-
import { R as RHFAutocomplete, g as getRHFAutocompleteComponentsDictionary } from "../RHFAutocomplete/index.
|
|
8
|
+
import { R as RHFAutocomplete, g as getRHFAutocompleteComponentsDictionary } from "../RHFAutocomplete/index.d1bbb015.js";
|
|
9
9
|
import { jsx } from "react/jsx-runtime";
|
|
10
10
|
styled("div")(() => ({
|
|
11
11
|
display: "flex",
|