@m4l/layouts 0.1.28 → 0.1.30

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.
@@ -1,14 +1,15 @@
1
- import { useEffect as y, useMemo as _, useCallback as f } from "react";
1
+ import { useEffect as y, useMemo as f, useCallback as _ } from "react";
2
2
  import { unstable_HistoryRouter as C } from "react-router-dom";
3
3
  import { ToastContainer as D, toast as H } from "react-toastify";
4
- import { HostThemeProvider as I, defaultThemeOptions as N, fnComponentsOverrides as O, FormatterProvider as B, LocalesProvider as j, getLocaleFromNetwork as S } from "@m4l/graphics";
5
- import { A as U } from "../../contexts/AuthContext/index.6f966215.js";
6
- import { DomainCountryProvider as z, EnvironmentProvider as R, HostToolsProvider as q, NetworkProvider as G, axiosOperation as J } from "@m4l/core";
7
- import { createBrowserHistory as K } from "history";
8
- import Q from "eventemitter3";
9
- import { format as V } from "date-fns";
4
+ import { HostThemeProvider as I, FormatterProvider as N, LocalesProvider as O, getLocaleFromNetwork as B } from "@m4l/graphics";
5
+ import { A as j } from "../../contexts/AuthContext/index.6f966215.js";
6
+ import { DomainCountryProvider as S, EnvironmentProvider as U, HostToolsProvider as z, NetworkProvider as R, axiosOperation as q } from "@m4l/core";
7
+ import { createBrowserHistory as G } from "history";
8
+ import J from "eventemitter3";
9
+ import { format as K } from "date-fns";
10
+ import { defaultThemeOptions as Q, fnComponentsOverrides as V } from "@m4l/styles";
10
11
  import { u as W } from "../../hooks/useAuth/index.cb6a3420.js";
11
- import { jsx as e, jsxs as X } from "react/jsx-runtime";
12
+ import { jsx as r, jsxs as X } from "react/jsx-runtime";
12
13
  import p from "nprogress";
13
14
  import { B as Y } from "../BaseModule/index.6309486a.js";
14
15
  import { AreasProvider as Z } from "@m4l/components";
@@ -21,12 +22,12 @@ function $(m) {
21
22
  isAuthenticated: s,
22
23
  isInitialized: c,
23
24
  login: u,
24
- user: r
25
+ user: e
25
26
  } = W();
26
27
  if (y(() => {
27
28
  c && s === !1 && (console.log("useEffect MFAuthApp Login"), u(d, l, !1));
28
29
  }, [c, s]), !s)
29
- return /* @__PURE__ */ e("div", {
30
+ return /* @__PURE__ */ r("div", {
30
31
  children: "Pendiente x atenticar"
31
32
  });
32
33
  const o = {
@@ -36,17 +37,17 @@ function $(m) {
36
37
  decimal_symbol: ".",
37
38
  thousands_symbol: ","
38
39
  };
39
- return r?.domain_country && (o.id = r?.domain_country.id ?? o.id, o.currency = r?.domain_country.currency ?? o.currency, o.currency_decimal_digits = r?.domain_country.currency_decimal_digits ?? o.currency_decimal_digits, o.decimal_symbol = r?.domain_country.decimal_symbol ?? o.decimal_symbol, o.thousands_symbol = r?.domain_country?.thousands_symbol ?? o.thousands_symbol), /* @__PURE__ */ X(I, {
40
- hostThemeOptions: N,
41
- fnComponentsOverrides: O,
40
+ return e?.domain_country && (o.id = e?.domain_country.id ?? o.id, o.currency = e?.domain_country.currency ?? o.currency, o.currency_decimal_digits = e?.domain_country.currency_decimal_digits ?? o.currency_decimal_digits, o.decimal_symbol = e?.domain_country.decimal_symbol ?? o.decimal_symbol, o.thousands_symbol = e?.domain_country?.thousands_symbol ?? o.thousands_symbol), /* @__PURE__ */ X(I, {
41
+ hostThemeOptions: Q,
42
+ fnComponentsOverrides: V,
42
43
  isMicroFrontEnd: !0,
43
- children: [/* @__PURE__ */ e(D, {}), /* @__PURE__ */ e(z, {
44
+ children: [/* @__PURE__ */ r(D, {}), /* @__PURE__ */ r(S, {
44
45
  ...o,
45
46
  isMicroFrontEnd: !1,
46
- children: /* @__PURE__ */ e(B, {
47
+ children: /* @__PURE__ */ r(N, {
47
48
  isMicroFrontEnd: !1,
48
49
  dateFormatter: {
49
- formatDate: V
50
+ formatDate: K
50
51
  },
51
52
  currencyFormatter: {
52
53
  code: o.currency,
@@ -57,10 +58,10 @@ function $(m) {
57
58
  })]
58
59
  });
59
60
  }
60
- const h = K({
61
+ const h = G({
61
62
  window
62
63
  });
63
- function po(m) {
64
+ function ho(m) {
64
65
  const {
65
66
  children: a,
66
67
  user: d,
@@ -68,7 +69,7 @@ function po(m) {
68
69
  host_api_local: s,
69
70
  host_api_remote: c,
70
71
  host_static_assets: u,
71
- environment_assets: r,
72
+ environment_assets: e,
72
73
  moduleId: o,
73
74
  skeletonFlags: v,
74
75
  moduleNameField: g,
@@ -76,15 +77,15 @@ function po(m) {
76
77
  componentsDictionary: P,
77
78
  onLoad: A,
78
79
  activeAreasNetwork: b = !1
79
- } = m, t = _(() => new Q(), []), E = f((i, n) => {
80
+ } = m, t = f(() => new J(), []), E = _((i, n) => {
80
81
  t.on(i, n);
81
- }, [t]), w = f((i, n) => {
82
+ }, [t]), w = _((i, n) => {
82
83
  if (n === null) {
83
84
  t.removeListener(i);
84
85
  return;
85
86
  }
86
87
  t.removeListener(i, n);
87
- }, [t]), M = f((i, n) => {
88
+ }, [t]), M = _((i, n) => {
88
89
  t.emit(i, n);
89
90
  }, [t]), L = () => {
90
91
  p.configure({
@@ -92,15 +93,15 @@ function po(m) {
92
93
  }), p.start();
93
94
  }, k = () => {
94
95
  p.done();
95
- }, T = _(() => ({
96
+ }, T = f(() => ({
96
97
  host: "",
97
98
  isLocalhost: !0,
98
99
  domain_token: "lab1",
99
100
  host_api_local: s,
100
101
  host_api_remote: c,
101
102
  host_static_assets: u,
102
- environment_assets: r
103
- }), []), x = _(() => ({
103
+ environment_assets: e
104
+ }), []), x = f(() => ({
104
105
  history: h,
105
106
  toast: H,
106
107
  startProgress: L,
@@ -111,28 +112,28 @@ function po(m) {
111
112
  }), []);
112
113
  return y(() => {
113
114
  console.log("useEffect IsolationApp");
114
- }, []), /* @__PURE__ */ e(R, {
115
+ }, []), /* @__PURE__ */ r(U, {
115
116
  ...T,
116
- children: /* @__PURE__ */ e(q, {
117
+ children: /* @__PURE__ */ r(z, {
117
118
  ...x,
118
- children: /* @__PURE__ */ e(G, {
119
- axiosOperation: J,
120
- children: /* @__PURE__ */ e(C, {
119
+ children: /* @__PURE__ */ r(R, {
120
+ axiosOperation: q,
121
+ children: /* @__PURE__ */ r(C, {
121
122
  history: h,
122
- children: /* @__PURE__ */ e(j, {
123
+ children: /* @__PURE__ */ r(O, {
123
124
  isMicroFrontEnd: !1,
124
- getLocaleFromNetwork: S,
125
- children: /* @__PURE__ */ e(U, {
126
- children: /* @__PURE__ */ e($, {
125
+ getLocaleFromNetwork: B,
126
+ children: /* @__PURE__ */ r(j, {
127
+ children: /* @__PURE__ */ r($, {
127
128
  user: d,
128
129
  pwd: l,
129
- children: /* @__PURE__ */ e(Y, {
130
+ children: /* @__PURE__ */ r(Y, {
130
131
  moduleId: o,
131
132
  privileges: F,
132
133
  skeletonFlags: v,
133
134
  componentsDictionary: P,
134
135
  moduleNameField: g,
135
- children: /* @__PURE__ */ e(Z, {
136
+ children: /* @__PURE__ */ r(Z, {
136
137
  onLoad: A,
137
138
  activeAreasNetwork: b,
138
139
  children: a
@@ -147,5 +148,5 @@ function po(m) {
147
148
  });
148
149
  }
149
150
  export {
150
- po as M
151
+ ho as M
151
152
  };
@@ -1,4 +1,4 @@
1
- import "./MFIsolationApp/index.b21e5671.js";
1
+ import "./MFIsolationApp/index.b89e6800.js";
2
2
  import "react-router-dom";
3
3
  import "@m4l/core";
4
4
  import "@m4l/graphics";
package/index.js CHANGED
@@ -1,13 +1,13 @@
1
- import { M as y } from "./components/MFIsolationApp/index.b21e5671.js";
2
- import { M as x } from "./components/MFHostApp/index.1700d13a.js";
3
- import { B as A } from "./components/BaseModule/index.6309486a.js";
4
- import { a as c, A as g } from "./contexts/AuthContext/index.6f966215.js";
5
- import { a as C, d as N, g as B } from "./layouts/ModuleLayout/index.a76397df.js";
6
- import { a as v, d as H, g as I } from "./layouts/MasterDetailLayout/index.3da0ffda.js";
7
- import { N as b, d as j, g as k } from "./layouts/NoAuthModuleLayout/index.5d1098ef.js";
8
- import { u as w } from "./hooks/useMasterDetail/index.1b024fd5.js";
9
- import { u as E } from "./hooks/useAuth/index.cb6a3420.js";
10
- import { u as J } from "./hooks/useModule/index.6ff7d08a.js";
1
+ import { M as f } from "./components/MFIsolationApp/index.b89e6800.js";
2
+ import { M as D } from "./components/MFHostApp/index.1700d13a.js";
3
+ import { B as L } from "./components/BaseModule/index.6309486a.js";
4
+ import { a as g, A as h } from "./contexts/AuthContext/index.6f966215.js";
5
+ import { a as N, d as B, g as F } from "./layouts/ModuleLayout/index.a76397df.js";
6
+ import { a as H, d as I, g as P } from "./layouts/MasterDetailLayout/index.3da0ffda.js";
7
+ import { N as j, d as k, g as q } from "./layouts/NoAuthModuleLayout/index.5d1098ef.js";
8
+ import { u as z } from "./hooks/useMasterDetail/index.1b024fd5.js";
9
+ import { u as G } from "./hooks/useAuth/index.cb6a3420.js";
10
+ import { u as K } from "./hooks/useModule/index.6ff7d08a.js";
11
11
  import "react";
12
12
  import "react-router-dom";
13
13
  import "react-toastify";
@@ -16,26 +16,27 @@ import "@m4l/core";
16
16
  import "history";
17
17
  import "eventemitter3";
18
18
  import "date-fns";
19
+ import "@m4l/styles";
19
20
  import "react/jsx-runtime";
20
21
  import "nprogress";
21
22
  import "@m4l/components";
22
23
  import "@mui/material/styles";
23
24
  export {
24
- c as AuthContext,
25
- g as AuthProvider,
26
- A as BaseModule,
27
- x as MFHostApp,
28
- y as MFIsolationApp,
29
- v as MasterDetailLayout,
30
- C as ModuleLayout,
31
- b as NoAuthModuleLayout,
32
- H as defaultMasterDetailDictionary,
33
- N as defaultModuleLayoutDictionary,
34
- j as defaultNoAuthModuleLayoutDictionary,
35
- I as getMasterDetailLayoutComponentsDictionary,
36
- B as getModuleLayoutComponentsDictionary,
37
- k as getNoAuthModuleLayoutComponentsDictionary,
38
- E as useAuth,
39
- w as useMasterDetail,
40
- J as useModule
25
+ g as AuthContext,
26
+ h as AuthProvider,
27
+ L as BaseModule,
28
+ D as MFHostApp,
29
+ f as MFIsolationApp,
30
+ H as MasterDetailLayout,
31
+ N as ModuleLayout,
32
+ j as NoAuthModuleLayout,
33
+ I as defaultMasterDetailDictionary,
34
+ B as defaultModuleLayoutDictionary,
35
+ k as defaultNoAuthModuleLayoutDictionary,
36
+ P as getMasterDetailLayoutComponentsDictionary,
37
+ F as getModuleLayoutComponentsDictionary,
38
+ q as getNoAuthModuleLayoutComponentsDictionary,
39
+ G as useAuth,
40
+ z as useMasterDetail,
41
+ K as useModule
41
42
  };
File without changes
package/package.json CHANGED
@@ -1,11 +1,12 @@
1
1
  {
2
2
  "name": "@m4l/layouts",
3
- "version": "0.1.28",
3
+ "version": "0.1.30",
4
4
  "license": "UNLICENSED",
5
5
  "dependencies": {
6
6
  "@m4l/components": "*",
7
7
  "@m4l/core": "*",
8
- "@m4l/graphics": "*"
8
+ "@m4l/graphics": "*",
9
+ "@m4l/styles": "*"
9
10
  },
10
11
  "peerDependencies": {
11
12
  "@types/react": "^17.0.0 || ^18.0.0",