@m4l/components 0.1.51 → 0.1.52

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.
Files changed (36) hide show
  1. package/components/CommonActions/components/ActionFormCancel/{index.27e301c5.js → index.bd0d16d6.js} +10 -11
  2. package/components/CommonActions/components/Actions/{index.c06ea173.js → index.f0a3167b.js} +9 -9
  3. package/components/DataGrid/{index.eb1bdc97.js → index.85390177.js} +10 -10
  4. package/components/DynamicFilter/{index.17731fda.js → index.cddd7472.js} +13 -13
  5. package/components/ModalDialog/{index.de10969f.js → index.5a307e29.js} +2 -2
  6. package/components/ObjectLogs/{index.338656c6.js → index.1315af37.js} +12 -12
  7. package/components/Period/{index.89daad51.js → index.85fe764a.js} +10 -10
  8. package/components/areas/components/Area/subcomponents/InnerForHooks/index.d.ts +2 -0
  9. package/components/areas/components/AreasAdmin/{index.3e586e9b.js → index.dbab59f1.js} +1 -3
  10. package/components/areas/components/AreasContainer/{index.15e4628d.js → index.f3f921b9.js} +2 -7
  11. package/components/areas/components/GridLayout/{index.f38f5b74.js → index.9953146d.js} +32 -30
  12. package/components/areas/components/Window/{index.d1a59be4.js → index.e34225ae.js} +112 -36
  13. package/components/areas/components/Window/subcomponents/InnerForHooks/index.d.ts +2 -2
  14. package/components/areas/components/WindowPopUp/{index.90566fca.js → index.90eb0348.js} +18 -19
  15. package/components/areas/components/WindowsPanel/index.d.ts +2 -0
  16. package/components/areas/components/{index.29809e82.js → index.6d863764.js} +20 -15
  17. package/components/areas/contexts/AreaContext/helper.d.ts +27 -0
  18. package/components/areas/contexts/AreaContext/{index.c787aee6.js → index.f25f7180.js} +151 -23
  19. package/components/areas/contexts/AreaContext/store.d.ts +17 -1
  20. package/components/areas/contexts/AreasContext/{index.4f938baa.js → index.7406c20f.js} +1 -5
  21. package/components/areas/contexts/{index.4cfa6ea9.js → index.e80d8f0f.js} +1 -13
  22. package/components/areas/hooks/{index.b15baf14.js → index.0fd57f88.js} +1 -1
  23. package/components/areas/hooks/useArea/{index.575c2abe.js → index.7bdbbb79.js} +2 -2
  24. package/components/areas/{index.8c6f9e65.js → index.6f09d168.js} +5 -5
  25. package/components/hook-form/RHFPeriod/{index.47cf646d.js → index.5d2a2071.js} +1 -1
  26. package/components/hook-form/RHFTextField/{index.57f138f7.js → index.bef7eced.js} +0 -1
  27. package/components/index.d.ts +0 -1
  28. package/components/modal/{WindowBase.ed279350.js → WindowBase.b5e29758.js} +1 -1
  29. package/components/modal/{WindowConfirm.72de5ce8.js → WindowConfirm.cbc7720c.js} +9 -9
  30. package/components/modal/{index.7197145d.js → index.f6de895f.js} +10 -10
  31. package/contexts/ModalContext/{index.e94f0e72.js → index.3d92d9f9.js} +1 -1
  32. package/hooks/useModal/{index.56c03c00.js → index.4454145e.js} +1 -1
  33. package/index.js +29 -60
  34. package/package.json +1 -1
  35. package/components/CmpDisenoTest/index.d.ts +0 -4
  36. package/components/CmpDisenoTest/types.d.ts +0 -20
@@ -7,17 +7,17 @@ import { styled } from "@mui/material/styles";
7
7
  import "react-router-dom";
8
8
  import "../../../animate/LoadingScreen/index.1d0c4307.js";
9
9
  import "../../../animate/PropagateLoader/index.be5b02c3.js";
10
- import "../index.29809e82.js";
11
- import "../AreasAdmin/index.3e586e9b.js";
10
+ import "../index.6d863764.js";
11
+ import "../AreasAdmin/index.dbab59f1.js";
12
12
  import { useEnvironment, useModuleSkeleton, useModuleDictionary, useNetwork, useHostTools, axiosOperation } from "@m4l/core";
13
13
  import { I as IconButton } from "../../../mui_extended/IconButton/index.1318a283.js";
14
14
  import "zustand";
15
- import "../../contexts/AreasContext/index.4f938baa.js";
15
+ import "../../contexts/AreasContext/index.7406c20f.js";
16
16
  import { shallow } from "zustand/shallow";
17
- import "../AreasContainer/index.15e4628d.js";
17
+ import "../AreasContainer/index.f3f921b9.js";
18
18
  import "react-grid-layout/css/styles.css";
19
19
  import "../../../../react-resizable.bb58c8fc.js";
20
- import { W as WindowToolsMFProvider, a as WindowMFProvider } from "../../contexts/index.4cfa6ea9.js";
20
+ import { W as WindowToolsMFProvider, a as WindowMFProvider } from "../../contexts/index.e80d8f0f.js";
21
21
  import { D as DynamicMFParmsProvider } from "../../contexts/DynamicMFParmsContext/index.c19cb8cc.js";
22
22
  import "react-hook-form";
23
23
  import "../../../hook-form/RHFAutocomplete/index.74add0d0.js";
@@ -38,42 +38,40 @@ import "../../../ErrorLabel/index.78553a1e.js";
38
38
  import "@mui/x-date-pickers";
39
39
  import "../../../hook-form/RHFDateTime/index.7f1cbd85.js";
40
40
  import { useResponsiveDesktop, useHostTheme, useFormatter, useLocales, useFirstRender } from "@m4l/graphics";
41
- import "../../../hook-form/RHFTextField/index.57f138f7.js";
42
- import "../../../hook-form/RHFPeriod/index.47cf646d.js";
43
- import "../../../Period/index.89daad51.js";
44
- import "../../../CommonActions/components/Actions/index.c06ea173.js";
45
- import "../../../../contexts/ModalContext/index.e94f0e72.js";
41
+ import "../../../hook-form/RHFTextField/index.bef7eced.js";
42
+ import "../../../hook-form/RHFPeriod/index.5d2a2071.js";
43
+ import "../../../Period/index.85fe764a.js";
44
+ import "../../../CommonActions/components/Actions/index.f0a3167b.js";
45
+ import "../../../../contexts/ModalContext/index.3d92d9f9.js";
46
46
  import { c as cjs } from "../../../../react-draggable.0eef011c.js";
47
- import "../../../ModalDialog/index.de10969f.js";
47
+ import "../../../ModalDialog/index.5a307e29.js";
48
48
  import { R as ResizeableWindow } from "../../../Resizeable/index.8a442a8b.js";
49
- import "../../../modal/WindowConfirm.72de5ce8.js";
50
- import "../../../modal/WindowBase.ed279350.js";
49
+ import "../../../modal/WindowConfirm.cbc7720c.js";
50
+ import "../../../modal/WindowBase.b5e29758.js";
51
51
  import "lodash/isString";
52
52
  import "react-dropzone";
53
53
  import "../../../hook-form/RHFUpload/index.7fdff30f.js";
54
- import "../../../DataGrid/index.eb1bdc97.js";
54
+ import "../../../DataGrid/index.85390177.js";
55
55
  import "react-dnd";
56
56
  import "react-dnd-html5-backend";
57
57
  import "../../../ScrollBar/index.39eeb2de.js";
58
- import "../../../DynamicFilter/index.17731fda.js";
58
+ import "../../../DynamicFilter/index.cddd7472.js";
59
59
  import "clsx";
60
60
  import "simplebar/dist/simplebar.min.css";
61
61
  import "@hookform/resolvers/yup";
62
62
  import "../../../../contexts/RHFormContext/index.828b60ad.js";
63
63
  import "yup";
64
- import "../../../../index.js";
65
- import "@mui/base";
66
64
  import "../../../LanguagePopover/index.5047b444.js";
67
65
  import "../../../NoItemSelected/index.9636ec8a.js";
68
- import "../../../ObjectLogs/index.338656c6.js";
66
+ import "../../../ObjectLogs/index.1315af37.js";
69
67
  import "../../../../react-json-view.57125fcf.js";
70
68
  import "../../../PaperForm/index.0114aa9b.js";
71
69
  import "../../../Page/index.4237c241.js";
72
70
  import "../../../PropertyValue/index.dfcfe1ba.js";
73
71
  import "../../../../react-splitter-layout.8b1655c8.js";
74
72
  import "../../../SplitLayout/index.5a8355d8.js";
75
- import { a as useAreaStore } from "../../hooks/useArea/index.575c2abe.js";
76
- import { a as useWindow, b as useWindowStore } from "../../hooks/index.b15baf14.js";
73
+ import { a as useAreaStore } from "../../hooks/useArea/index.7bdbbb79.js";
74
+ import { a as useWindow, b as useWindowStore } from "../../hooks/index.0fd57f88.js";
77
75
  import { L as LinearProgress } from "../../../mui_extended/LinearProgress/index.c92b9ba9.js";
78
76
  import { v as varBounce } from "../../../animate/variants/bounce.784aaaaa.js";
79
77
  const WrapperWindow = styled("div", {
@@ -85,9 +83,9 @@ const WrapperWindow = styled("div", {
85
83
  width: "100%",
86
84
  overflow: "hidden",
87
85
  border: "1px solid gray",
88
- borderTop: selected ? "1px solid red" : "1px solid black",
86
+ borderTop: selected ? "1px solid red" : "1px solid gray",
89
87
  backgroundColor: theme.palette.background.paper,
90
- padding: theme.spacing(3),
88
+ padding: theme.spacing(0),
91
89
  "&.m4l_selected": {
92
90
  borderTop: "1px solid green"
93
91
  }
@@ -307,7 +305,14 @@ function getMainActions(isDesktop, moduleActions) {
307
305
  }
308
306
  function Header() {
309
307
  const [url_icon, title, moduleActions, onClose, container_id] = useWindowStore((state) => [state.url_icon, state.title, state.moduleActions, state.onClose, state.windowId], shallow);
310
- const saveModuleCookies = useWindowStore((state) => state.internalActions.saveModuleCookies);
308
+ const {
309
+ saveModuleCookies
310
+ } = useWindowStore((state) => state.internalActions);
311
+ const maximizedId = useAreaStore((state) => state.singleId);
312
+ const {
313
+ maximizeLayout,
314
+ normalizeLayouts
315
+ } = useAreaStore((state) => state.actions, shallow);
311
316
  const {
312
317
  host_static_assets,
313
318
  environment_assets
@@ -321,6 +326,13 @@ function Header() {
321
326
  const onCloseLocal = () => {
322
327
  onClose && onClose(container_id);
323
328
  };
329
+ const maxNormalize = () => {
330
+ if (maximizedId) {
331
+ normalizeLayouts();
332
+ } else {
333
+ maximizeLayout(container_id);
334
+ }
335
+ };
324
336
  if (isSkeleton) {
325
337
  return /* @__PURE__ */ jsx(SKTModuleHeader, {});
326
338
  }
@@ -373,6 +385,10 @@ function Header() {
373
385
  onClick: onCloseLocal,
374
386
  "aria-label": "click",
375
387
  src: `${host_static_assets}/${environment_assets}/frontend/components/window/assets/icons/close.svg`
388
+ }), isDesktop && /* @__PURE__ */ jsx(Button, {
389
+ onClick: maxNormalize,
390
+ "aria-label": "click",
391
+ children: maximizedId ? "Norm" : "Max"
376
392
  }), /* @__PURE__ */ jsx(Button, {
377
393
  onClick: saveModuleCookies,
378
394
  "aria-label": "click",
@@ -625,7 +641,6 @@ function MFLoader(props) {
625
641
  cleanUp(dsScript);
626
642
  };
627
643
  }, [divScript]);
628
- console.log("Render micro frontend", divScript.divContainerId, final_host);
629
644
  return /* @__PURE__ */ jsxs(Fragment, {
630
645
  children: [/* @__PURE__ */ jsx("div", {
631
646
  id: divScript.divContainerId
@@ -657,9 +672,11 @@ const InnerForHooks = (props) => {
657
672
  const {
658
673
  winType
659
674
  } = props;
660
- console.log("Render InnerForHooks", props.windowId);
661
- return /* @__PURE__ */ jsxs(WindowMFProvider, {
662
- ...props,
675
+ const status = useWindowStore((state) => state.status);
676
+ if (status !== "loaded") {
677
+ return null;
678
+ }
679
+ return /* @__PURE__ */ jsxs(Fragment, {
663
680
  children: [/* @__PURE__ */ jsx(Header, {}), /* @__PURE__ */ jsx(WrapperContent, {
664
681
  children: winType === "microfrontend" ? /* @__PURE__ */ jsx(MicroFrontend, {
665
682
  ...props.mfProps
@@ -669,7 +686,7 @@ const InnerForHooks = (props) => {
669
686
  })]
670
687
  });
671
688
  };
672
- const MemonizedInnerForHooks = React__default.memo(InnerForHooks);
689
+ React__default.memo(InnerForHooks);
673
690
  const Window = (props) => {
674
691
  const {
675
692
  emergeType
@@ -680,7 +697,6 @@ const Window = (props) => {
680
697
  selectWindowLayout
681
698
  } = useAreaStore((state) => state.actions);
682
699
  const onTouch = () => {
683
- console.log("onTouch", props.windowId);
684
700
  if (!selected) {
685
701
  if (emergeType === "popup") {
686
702
  selectWindowPopUp(props.windowId);
@@ -689,13 +705,15 @@ const Window = (props) => {
689
705
  }
690
706
  }
691
707
  };
692
- console.log("Render Window", props.windowId, selected);
693
708
  return /* @__PURE__ */ jsx(WrapperWindow, {
694
709
  id: "WrapperWindow",
695
710
  selected,
696
711
  onMouseDown: onTouch,
697
- children: /* @__PURE__ */ jsx(MemonizedInnerForHooks, {
698
- ...props
712
+ children: /* @__PURE__ */ jsx(WindowMFProvider, {
713
+ ...props,
714
+ children: /* @__PURE__ */ jsx(InnerForHooks, {
715
+ ...props
716
+ })
699
717
  })
700
718
  });
701
719
  };
@@ -751,7 +769,6 @@ const WindowModal = (props) => {
751
769
  onClose
752
770
  })
753
771
  });
754
- console.log("Render WindowModal");
755
772
  return /* @__PURE__ */ jsxs(WrapperWindowModal, {
756
773
  open: true,
757
774
  "aria-labelledby": "child-modal-title",
@@ -769,9 +786,68 @@ const WindowModal = (props) => {
769
786
  ), !isDesktop && contentComnponent]
770
787
  });
771
788
  };
772
- React__default.memo(WindowModal);
789
+ const MemonizedWindowModal = React__default.memo(WindowModal);
790
+ const WrapperWindowsPanel = styled("div", {
791
+ shouldForwardProp: (props) => props !== "isDesktop"
792
+ })(({
793
+ isDesktop
794
+ }) => ({
795
+ display: "flex",
796
+ flexDirection: isDesktop ? "column" : "row",
797
+ height: isDesktop ? "40px" : "unset",
798
+ maxWidth: isDesktop ? "40px" : "unset",
799
+ flexGrow: "1",
800
+ position: "relative"
801
+ }));
802
+ const WrapperWindowPanel = styled("div", {
803
+ shouldForwardProp: (props) => props !== "selected"
804
+ })(({
805
+ selected
806
+ }) => ({
807
+ flexDirection: "column",
808
+ flexGrow: "1",
809
+ position: "relative",
810
+ width: "40px",
811
+ height: "40px",
812
+ border: selected ? "1px solid red" : "1px solid black"
813
+ }));
814
+ const WindowsPanel = () => {
815
+ const status = useAreaStore((state) => state.status);
816
+ const mode = useAreaStore((state) => state.viewMode);
817
+ const singleId = useAreaStore((state) => state.singleId);
818
+ const gridLayouts = useAreaStore((state) => state.gridLayouts, shallow);
819
+ const hashWindowsLayouts = useAreaStore((state) => state.hashWindowsLayouts, shallow);
820
+ const {
821
+ maximizeLayout
822
+ } = useAreaStore((state) => state.actions);
823
+ const isDesktop = useAreaStore((state) => state.isDesktop);
824
+ const onTouched = (layoutId) => {
825
+ maximizeLayout(layoutId);
826
+ };
827
+ if (status === "loaded") {
828
+ if (mode !== "single" || gridLayouts.length < 2) {
829
+ return null;
830
+ }
831
+ return /* @__PURE__ */ jsx(WrapperWindowsPanel, {
832
+ isDesktop,
833
+ children: gridLayouts.map((l) => {
834
+ return /* @__PURE__ */ jsx(WrapperWindowPanel, {
835
+ onClick: () => onTouched(l.i),
836
+ selected: singleId === l.i,
837
+ children: /* @__PURE__ */ jsx(Icon, {
838
+ src: hashWindowsLayouts[l.i].url_icon,
839
+ size: "32px"
840
+ })
841
+ }, l.i);
842
+ })
843
+ });
844
+ } else {
845
+ return null;
846
+ }
847
+ };
773
848
  export {
774
849
  MemonizedWindow as M,
775
- WindowModal as W,
776
- Window as a
850
+ Window as W,
851
+ MemonizedWindowModal as a,
852
+ WindowsPanel as b
777
853
  };
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
2
  import { WindowProps } from '../../../Area/types';
3
- export declare const InnerForHooks: (props: WindowProps) => JSX.Element;
4
- export declare const MemonizedInnerForHooks: React.MemoExoticComponent<(props: WindowProps) => JSX.Element>;
3
+ export declare const InnerForHooks: (props: WindowProps) => JSX.Element | null;
4
+ export declare const MemonizedInnerForHooks: React.MemoExoticComponent<(props: WindowProps) => JSX.Element | null>;
@@ -7,17 +7,17 @@ import "@mui/material/styles";
7
7
  import "react-router-dom";
8
8
  import "../../../animate/LoadingScreen/index.1d0c4307.js";
9
9
  import "../../../animate/PropagateLoader/index.be5b02c3.js";
10
- import "../index.29809e82.js";
11
- import "../AreasAdmin/index.3e586e9b.js";
10
+ import "../index.6d863764.js";
11
+ import "../AreasAdmin/index.dbab59f1.js";
12
12
  import "@m4l/core";
13
13
  import "../../../mui_extended/IconButton/index.1318a283.js";
14
14
  import "zustand";
15
- import "../../contexts/AreasContext/index.4f938baa.js";
15
+ import "../../contexts/AreasContext/index.7406c20f.js";
16
16
  import "zustand/shallow";
17
- import "../AreasContainer/index.15e4628d.js";
17
+ import "../AreasContainer/index.f3f921b9.js";
18
18
  import "react-grid-layout/css/styles.css";
19
19
  import "../../../../react-resizable.bb58c8fc.js";
20
- import "../../contexts/index.4cfa6ea9.js";
20
+ import "../../contexts/index.e80d8f0f.js";
21
21
  import "../../contexts/DynamicMFParmsContext/index.c19cb8cc.js";
22
22
  import "react-hook-form";
23
23
  import "../../../hook-form/RHFAutocomplete/index.74add0d0.js";
@@ -38,42 +38,41 @@ import "../../../ErrorLabel/index.78553a1e.js";
38
38
  import "@mui/x-date-pickers";
39
39
  import "../../../hook-form/RHFDateTime/index.7f1cbd85.js";
40
40
  import "@m4l/graphics";
41
- import "../../../hook-form/RHFTextField/index.57f138f7.js";
42
- import "../../../hook-form/RHFPeriod/index.47cf646d.js";
43
- import "../../../Period/index.89daad51.js";
44
- import "../../../CommonActions/components/Actions/index.c06ea173.js";
45
- import "../../../../contexts/ModalContext/index.e94f0e72.js";
41
+ import "../../../hook-form/RHFTextField/index.bef7eced.js";
42
+ import "../../../hook-form/RHFPeriod/index.5d2a2071.js";
43
+ import "../../../Period/index.85fe764a.js";
44
+ import "../../../CommonActions/components/Actions/index.f0a3167b.js";
45
+ import "../../../../contexts/ModalContext/index.3d92d9f9.js";
46
46
  import "../../../../react-draggable.0eef011c.js";
47
- import "../../../ModalDialog/index.de10969f.js";
47
+ import "../../../ModalDialog/index.5a307e29.js";
48
48
  import { R as ResizeableWindow } from "../../../Resizeable/index.8a442a8b.js";
49
- import "../../../modal/WindowConfirm.72de5ce8.js";
50
- import "../../../modal/WindowBase.ed279350.js";
49
+ import "../../../modal/WindowConfirm.cbc7720c.js";
50
+ import "../../../modal/WindowBase.b5e29758.js";
51
51
  import "lodash/isString";
52
52
  import "react-dropzone";
53
53
  import "../../../hook-form/RHFUpload/index.7fdff30f.js";
54
- import "../../../DataGrid/index.eb1bdc97.js";
54
+ import "../../../DataGrid/index.85390177.js";
55
55
  import "react-dnd";
56
56
  import "react-dnd-html5-backend";
57
57
  import "../../../ScrollBar/index.39eeb2de.js";
58
- import "../../../DynamicFilter/index.17731fda.js";
58
+ import "../../../DynamicFilter/index.cddd7472.js";
59
59
  import "clsx";
60
60
  import "simplebar/dist/simplebar.min.css";
61
61
  import "@hookform/resolvers/yup";
62
62
  import "../../../../contexts/RHFormContext/index.828b60ad.js";
63
63
  import "yup";
64
64
  import { DraggableWindow } from "../../../../index.js";
65
- import "@mui/base";
66
65
  import "../../../LanguagePopover/index.5047b444.js";
67
66
  import "../../../NoItemSelected/index.9636ec8a.js";
68
- import "../../../ObjectLogs/index.338656c6.js";
67
+ import "../../../ObjectLogs/index.1315af37.js";
69
68
  import "../../../../react-json-view.57125fcf.js";
70
69
  import "../../../PaperForm/index.0114aa9b.js";
71
70
  import "../../../Page/index.4237c241.js";
72
71
  import "../../../PropertyValue/index.dfcfe1ba.js";
73
72
  import "../../../../react-splitter-layout.8b1655c8.js";
74
73
  import "../../../SplitLayout/index.5a8355d8.js";
75
- import { a as useAreaStore } from "../../hooks/useArea/index.575c2abe.js";
76
- import { a as Window } from "../Window/index.d1a59be4.js";
74
+ import { a as useAreaStore } from "../../hooks/useArea/index.7bdbbb79.js";
75
+ import { W as Window } from "../Window/index.e34225ae.js";
77
76
  const WindowPopUp = (props) => {
78
77
  const {
79
78
  windowProps,
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare const WindowsPanel: () => JSX.Element | null;
@@ -1,30 +1,35 @@
1
- import { A as AreaProvider } from "../contexts/AreaContext/index.c787aee6.js";
2
- import { G as GridLayout } from "./GridLayout/index.f38f5b74.js";
1
+ import { A as AreaProvider } from "../contexts/AreaContext/index.f25f7180.js";
3
2
  import { styled } from "@mui/material/styles";
4
- import { a as useAreaStore } from "../hooks/useArea/index.575c2abe.js";
5
- import { jsx } from "react/jsx-runtime";
6
- import "./AreasAdmin/index.3e586e9b.js";
3
+ import { G as GridLayout } from "./GridLayout/index.9953146d.js";
4
+ import { a as useAreaStore } from "../hooks/useArea/index.7bdbbb79.js";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
+ import { b as WindowsPanel } from "./Window/index.e34225ae.js";
7
+ import { useResponsiveDesktop } from "@m4l/graphics";
8
+ import "./AreasAdmin/index.dbab59f1.js";
7
9
  import "react";
8
10
  import "@m4l/core";
9
11
  import "@mui/material";
10
12
  import "../../Icon/index.f6e8d810.js";
11
13
  import "../../mui_extended/IconButton/index.1318a283.js";
12
14
  import "zustand";
13
- import "../contexts/AreasContext/index.4f938baa.js";
15
+ import "../contexts/AreasContext/index.7406c20f.js";
14
16
  import "zustand/shallow";
15
- import "./AreasContainer/index.15e4628d.js";
17
+ import "./AreasContainer/index.f3f921b9.js";
16
18
  import "react-grid-layout/css/styles.css";
17
19
  import "../../../react-resizable.bb58c8fc.js";
18
- const WrapperArea = styled("div")(() => ({
19
- flexDirection: "column",
20
+ const WrapperArea = styled("div", {
21
+ shouldForwardProp: (props) => props !== "isDesktop"
22
+ })(({
23
+ isDesktop
24
+ }) => ({
25
+ flexDirection: isDesktop ? "row" : "column-reverse",
20
26
  flexGrow: "1",
21
27
  position: "absolute",
22
28
  height: "100%",
23
29
  width: "100%",
24
- overflow: "hidden",
30
+ overflow: "hiden",
25
31
  justifyContent: "top",
26
32
  alignItems: "flex-start",
27
- border: "1px dashed black",
28
33
  visibility: "hidden",
29
34
  display: "none",
30
35
  hola: "juan",
@@ -33,7 +38,6 @@ const WrapperArea = styled("div")(() => ({
33
38
  visibility: "visible"
34
39
  },
35
40
  "& .M4L_GridLayout": {
36
- overflow: "scroll",
37
41
  minWidth: "100%",
38
42
  minHeight: "100%",
39
43
  juan: 1
@@ -57,12 +61,13 @@ const Area = (props) => {
57
61
  id,
58
62
  active
59
63
  } = props;
60
- console.log("Render Area");
64
+ const isDesktop = useResponsiveDesktop();
61
65
  return /* @__PURE__ */ jsx(WrapperArea, {
62
66
  className: `M4L_Area_wrapper_${id} ${active ? "active" : ""}`,
63
- children: /* @__PURE__ */ jsx(AreaProvider, {
67
+ isDesktop: !!isDesktop,
68
+ children: /* @__PURE__ */ jsxs(AreaProvider, {
64
69
  ...props,
65
- children: /* @__PURE__ */ jsx(InnerForHooks, {})
70
+ children: [/* @__PURE__ */ jsx(InnerForHooks, {}), /* @__PURE__ */ jsx(WindowsPanel, {})]
66
71
  })
67
72
  });
68
73
  };
@@ -1,10 +1,37 @@
1
1
  import { WritableDraft } from 'immer/dist/internal';
2
+ import { Layouts } from 'react-grid-layout';
2
3
  import { HashWindowsByLayouts } from '../../components/Area/types';
3
4
  import { AreaStateWithActions } from './store';
5
+ import { WinLayout } from './types';
6
+ export declare const ROW_HEIGTH_GRIDLAYOUT = 100;
7
+ export declare const CONTAINER_PADDING_GRIDLAYOUT = 3;
4
8
  export declare const DEBOUCED_SAVE_TIME = 500;
5
9
  export declare const COOKIE_BREAKPOINT_LAYOUTS = "layoutPros";
6
10
  export declare const COOKIE_WINDOWS = "windows";
11
+ export declare const NORMALIZED_BREAKPOINTS: {
12
+ lg: number;
13
+ md: number;
14
+ sm: number;
15
+ xs: number;
16
+ xxs: number;
17
+ };
18
+ export declare const NORMALIZED_COLS: {
19
+ lg: number;
20
+ md: number;
21
+ sm: number;
22
+ xs: number;
23
+ xxs: number;
24
+ };
25
+ export declare const MAXIMIZED_COLS: {
26
+ lg: number;
27
+ md: number;
28
+ sm: number;
29
+ xs: number;
30
+ xxs: number;
31
+ };
7
32
  export declare const getParmsFromValue: (key: string, data: []) => any;
33
+ export declare function setAddBreakPoints(state: WritableDraft<AreaStateWithActions>, newLayout: WinLayout): Layouts;
34
+ export declare function setBreakPointsMaximized(state: WritableDraft<AreaStateWithActions>, layoutId?: string): Layouts;
8
35
  export declare function getDataFromResponse(data: any, state: WritableDraft<AreaStateWithActions>): {
9
36
  newBreakPointsLayouts: any;
10
37
  newGridLayouts: any[];