@m4l/layouts 9.8.1 → 9.9.0

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 +1 @@
1
- {"version":3,"file":"MFHostApp.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFHostApp/MFHostApp.tsx"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAG9C;;GAEG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,oDA0F9C;AAED,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"MFHostApp.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFHostApp/MFHostApp.tsx"],"names":[],"mappings":"AAwBA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAG9C;;GAEG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,oDA8F9C;AAED,eAAe,SAAS,CAAC"}
@@ -1,59 +1,66 @@
1
1
  import { jsx as r } from "@emotion/react/jsx-runtime";
2
- import { unstable_HistoryRouter as T } from "react-router-dom";
3
- import { EnvironmentProvider as H, HostToolsProvider as g, NetworkProvider as E, AuthProvider as A, DomainCountryProvider as D } from "@m4l/core";
4
- import { DeviceTypeProvider as R, LocalesProvider as _, HostThemeProvider as w, FormatterProvider as S, AppearanceComponentProvider as x } from "@m4l/graphics";
5
- import { projectMFHostRuntimeTools as j, BaseModule as k, WindowToolsMFProvider as B, MFHostRuntimeToolsProvider as C, MFObservabilityProvider as L, DynamicMFParmsProvider as N } from "@m4l/components";
6
- import { MFHostAppErrorBoundary as O } from "./MFHostAppErrorBoundary.js";
7
- function G(n) {
2
+ import { unstable_HistoryRouter as g } from "react-router-dom";
3
+ import { normalizeUserPreferences as E, EnvironmentProvider as D, HostToolsProvider as S, NetworkProvider as w, AuthProvider as A, UserPreferencesProvider as R } from "@m4l/core";
4
+ import { DeviceTypeProvider as U, LocalesProvider as x, HostThemeProvider as j, FormatterProvider as k, AppearanceComponentProvider as B } from "@m4l/graphics";
5
+ import { projectMFHostRuntimeTools as L, BaseModule as N, WindowToolsMFProvider as O, MFHostRuntimeToolsProvider as z, MFObservabilityProvider as C, DynamicMFParmsProvider as I } from "@m4l/components";
6
+ import { MFHostAppErrorBoundary as V } from "./MFHostAppErrorBoundary.js";
7
+ function Q(n) {
8
8
  const {
9
- children: d,
10
- currentLocale: s,
11
- hostTheme: l,
9
+ children: s,
10
+ currentLocale: o,
11
+ hostTheme: d,
12
12
  environment: c,
13
- hostTools: e,
14
- axiosOperation: m,
15
- formatters: o,
13
+ hostTools: t,
14
+ axiosOperation: l,
15
+ formatters: e,
16
+ userPreferences: m,
16
17
  isAuth: a = !0,
17
18
  moduleId: i,
18
19
  moduleNameField: u,
19
20
  skeletonFlags: h,
20
- privileges: v,
21
- componentsDictionary: F,
22
- dynamicMFStore: t,
23
- windowTools: y,
24
- hostRuntime: p,
25
- observability: P,
21
+ privileges: F,
22
+ componentsDictionary: v,
23
+ dynamicMFStore: P,
24
+ windowTools: p,
25
+ hostRuntime: y,
26
+ observability: f,
26
27
  // overrideContainerStyles,
27
28
  loggedUser: M,
28
29
  moduleVersion: b
29
- } = n, f = j(p);
30
- return /* @__PURE__ */ r(H, { ...c, children: /* @__PURE__ */ r(O, { moduleId: i, moduleVersion: b, children: /* @__PURE__ */ r(g, { ...e, children: /* @__PURE__ */ r(E, { axiosOperation: m, children: /* @__PURE__ */ r(R, { children: /* @__PURE__ */ r(A, { isMicroFrontEnd: !0, loggedUser: M, children: /* @__PURE__ */ r(_, { isMicroFrontEnd: !0, localeHost: s, children: /* @__PURE__ */ r(w, { isMicroFrontEnd: !0, ...l, children: /* @__PURE__ */ r(
31
- T,
30
+ } = n, T = L(y), H = E(
31
+ m ?? {
32
+ currency: e.currencyFormatter.code,
33
+ currencyDecimalDigits: e.currencyFormatter.decimalDigits,
34
+ decimalSymbol: e.numberFormatter.decimalSymbol,
35
+ thousandsSymbol: e.numberFormatter.thousandsSymbol,
36
+ locale: o.localeString,
37
+ dateFormat: e.dateFormatter.dateFormat,
38
+ timeFormat: e.dateFormatter.timeFormat
39
+ }
40
+ );
41
+ return /* @__PURE__ */ r(D, { ...c, children: /* @__PURE__ */ r(V, { moduleId: i, moduleVersion: b, children: /* @__PURE__ */ r(S, { ...t, children: /* @__PURE__ */ r(w, { axiosOperation: l, children: /* @__PURE__ */ r(U, { children: /* @__PURE__ */ r(A, { isMicroFrontEnd: !0, loggedUser: M, children: /* @__PURE__ */ r(x, { isMicroFrontEnd: !0, localeHost: o, children: /* @__PURE__ */ r(j, { isMicroFrontEnd: !0, ...d, children: /* @__PURE__ */ r(
42
+ g,
32
43
  {
33
- history: e.history,
44
+ history: t.history,
34
45
  children: /* @__PURE__ */ r(
35
- D,
46
+ R,
36
47
  {
37
48
  isMicroFrontEnd: !0,
38
- id: t?.getState().dynamicMFParameters?.id || 1,
39
- currency: o.currencyFormatter.code,
40
- currency_decimal_digits: o.currencyFormatter.decimalDigits,
41
- decimal_symbol: o.numberFormatter.decimalSymbol,
42
- thousands_symbol: o.numberFormatter.thousandsSymbol,
49
+ ...H,
43
50
  children: /* @__PURE__ */ r(
44
- k,
51
+ N,
45
52
  {
46
53
  isAuth: a,
47
54
  moduleId: i,
48
55
  moduleNameField: u,
49
- componentsDictionary: F,
56
+ componentsDictionary: v,
50
57
  skeletonFlags: h,
51
- privileges: v,
52
- children: /* @__PURE__ */ r(S, { isMicroFrontEnd: !0, ...o, children: /* @__PURE__ */ r(B, { ...y, children: /* @__PURE__ */ r(
53
- C,
58
+ privileges: F,
59
+ children: /* @__PURE__ */ r(k, { isMicroFrontEnd: !0, ...e, children: /* @__PURE__ */ r(O, { ...p, children: /* @__PURE__ */ r(
60
+ z,
54
61
  {
55
- value: f,
56
- children: /* @__PURE__ */ r(L, { value: P, children: /* @__PURE__ */ r(N, { store: t, children: /* @__PURE__ */ r(x, { children: d }) }) })
62
+ value: T,
63
+ children: /* @__PURE__ */ r(C, { value: f, children: /* @__PURE__ */ r(I, { store: P, children: /* @__PURE__ */ r(B, { children: s }) }) })
57
64
  }
58
65
  ) }) })
59
66
  }
@@ -64,6 +71,6 @@ function G(n) {
64
71
  ) }) }) }) }) }) }) }) });
65
72
  }
66
73
  export {
67
- G as MFHostApp,
68
- G as default
74
+ Q as MFHostApp,
75
+ Q as default
69
76
  };
@@ -1,4 +1,4 @@
1
- import { AuthUserType, AxiosOperation, EnvironmentType, HostToolsType } from '@m4l/core';
1
+ import { AuthUserType, AxiosOperation, EnvironmentType, HostToolsType, UserPreferences } from '@m4l/core';
2
2
  import { BaseModuleProps, DynamicMFStore, EmergeType, M4LOverridesStyleRules, MFHostRuntime, WindowToolsMF } from '@m4l/components';
3
3
  import { MFObservabilityService } from '../../../../../out-tsc/libs/observability/mf/index.d.ts';
4
4
  import { Formatters, HostThemeType, LocaleType } from '@m4l/graphics';
@@ -12,6 +12,7 @@ export interface ByHostProps {
12
12
  currentLocale: LocaleType;
13
13
  axiosOperation: AxiosOperation;
14
14
  formatters: Formatters;
15
+ userPreferences?: UserPreferences;
15
16
  dynamicMFStore: DynamicMFStore;
16
17
  windowTools: WindowToolsMF;
17
18
  hostRuntime?: MFHostRuntime;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFHostApp/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC9F,OAAO,EACL,eAAe,EACf,cAAc,EACd,UAAU,EACV,sBAAsB,EACtB,aAAa,EACb,aAAa,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AACtE,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAE9C,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,eAAe,CAAC;IAC7B,SAAS,EAAE,aAAa,CAAC;IACzB,SAAS,EAAE,aAAa,CAAC;IACzB,aAAa,EAAE,UAAU,CAAC;IAC1B,cAAc,EAAE,cAAc,CAAC;IAC/B,UAAU,EAAE,UAAU,CAAC;IACvB,cAAc,EAAE,cAAc,CAAC;IAC/B,WAAW,EAAE,aAAa,CAAC;IAC3B,WAAW,CAAC,EAAE,aAAa,CAAC;IAC5B,aAAa,CAAC,EAAE,sBAAsB,CAAC;IAEvC;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC;IACvC;;OAEG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;OAEG;IACH,UAAU,CAAC,EAAE,YAAY,CAAC;IAE1B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AACD,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG,eAAe,CAAC;AAE3D,MAAM,MAAM,mBAAmB,GAAG;IAChC,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG,MAAM,OAAO,cAAc,CAAC;AAE7D,MAAM,MAAM,eAAe,GAAG,sBAAsB,CAAC,kBAAkB,EAAE,OAAO,eAAe,EAAE,KAAK,CAAC,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFHostApp/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,YAAY,EACZ,cAAc,EACd,eAAe,EACf,aAAa,EACb,eAAe,EAChB,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,eAAe,EACf,cAAc,EACd,UAAU,EACV,sBAAsB,EACtB,aAAa,EACb,aAAa,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AACtE,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAE9C,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,eAAe,CAAC;IAC7B,SAAS,EAAE,aAAa,CAAC;IACzB,SAAS,EAAE,aAAa,CAAC;IACzB,aAAa,EAAE,UAAU,CAAC;IAC1B,cAAc,EAAE,cAAc,CAAC;IAC/B,UAAU,EAAE,UAAU,CAAC;IACvB,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,cAAc,EAAE,cAAc,CAAC;IAC/B,WAAW,EAAE,aAAa,CAAC;IAC3B,WAAW,CAAC,EAAE,aAAa,CAAC;IAC5B,aAAa,CAAC,EAAE,sBAAsB,CAAC;IAEvC;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC;IACvC;;OAEG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;OAEG;IACH,UAAU,CAAC,EAAE,YAAY,CAAC;IAE1B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AACD,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG,eAAe,CAAC;AAE3D,MAAM,MAAM,mBAAmB,GAAG;IAChC,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG,MAAM,OAAO,cAAc,CAAC;AAE7D,MAAM,MAAM,eAAe,GAAG,sBAAsB,CAAC,kBAAkB,EAAE,OAAO,eAAe,EAAE,KAAK,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFNoAuthApp/index.tsx"],"names":[],"mappings":"AASA,OAAO,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAI3C;;GAEG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,oDA4ClD;AAED,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFNoAuthApp/index.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAIhD;;GAEG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,oDAuClD;AAED,eAAe,WAAW,CAAC"}
@@ -1,41 +1,36 @@
1
1
  import { jsx as r } from "@emotion/react/jsx-runtime";
2
- import { DomainCountryProvider as a } from "@m4l/core";
3
- import { DeviceTypeProvider as p, FormatterProvider as h } from "@m4l/graphics";
4
- import { useShellObservability as y, HostRuntimeProvider as v, BaseModule as f, MFObservabilityProvider as F } from "@m4l/components";
2
+ import { UserPreferencesProvider as p } from "@m4l/core";
3
+ import { DeviceTypeProvider as h, FormatterProvider as f } from "@m4l/graphics";
4
+ import { useShellObservability as v, HostRuntimeProvider as F, BaseModule as M, MFObservabilityProvider as P } from "@m4l/components";
5
5
  import { useMemo as b } from "react";
6
- import { createMFNoAuthHostRuntime as M } from "./createMFNoAuthHostRuntime.js";
6
+ import { createMFNoAuthHostRuntime as y } from "./createMFNoAuthHostRuntime.js";
7
7
  import { MFHostAppErrorBoundary as A } from "../MFHostApp/MFHostAppErrorBoundary.js";
8
- function O(e) {
8
+ function B(o) {
9
9
  const {
10
10
  children: i,
11
11
  formatters: t,
12
- moduleId: o,
13
- moduleNameField: n,
14
- skeletonFlags: m,
15
- privileges: s,
16
- componentsDictionary: d,
17
- isAuth: l
18
- } = e, u = b(() => M(), []), c = y();
19
- return /* @__PURE__ */ r(v, { value: u, children: /* @__PURE__ */ r(p, { children: /* @__PURE__ */ r(a, { isMicroFrontEnd: !0, ...{
20
- id: 1,
21
- currency: "USD",
22
- currency_decimal_digits: 2,
23
- decimal_symbol: ".",
24
- thousands_symbol: ","
25
- }, children: /* @__PURE__ */ r(A, { moduleId: o, children: /* @__PURE__ */ r(
26
- f,
12
+ userPreferences: s,
13
+ isAuth: n,
14
+ componentsDictionary: l,
15
+ moduleId: e,
16
+ moduleNameField: m,
17
+ privileges: d,
18
+ skeletonFlags: u
19
+ } = o, c = b(() => y(), []), a = v();
20
+ return /* @__PURE__ */ r(F, { value: c, children: /* @__PURE__ */ r(h, { children: /* @__PURE__ */ r(p, { isMicroFrontEnd: !0, ...s, children: /* @__PURE__ */ r(A, { moduleId: e, children: /* @__PURE__ */ r(
21
+ M,
27
22
  {
28
- isAuth: l,
29
- moduleId: o,
30
- moduleNameField: n,
31
- componentsDictionary: d,
32
- skeletonFlags: m,
33
- privileges: s,
34
- children: /* @__PURE__ */ r(h, { isMicroFrontEnd: !0, ...t, children: /* @__PURE__ */ r(F, { value: c, children: i }) })
23
+ isAuth: n,
24
+ moduleId: e,
25
+ moduleNameField: m,
26
+ componentsDictionary: l,
27
+ skeletonFlags: u,
28
+ privileges: d,
29
+ children: /* @__PURE__ */ r(f, { isMicroFrontEnd: !0, ...t, children: /* @__PURE__ */ r(P, { value: a, children: i }) })
35
30
  }
36
31
  ) }) }) }) });
37
32
  }
38
33
  export {
39
- O as MFNoAuthApp,
40
- O as default
34
+ B as MFNoAuthApp,
35
+ B as default
41
36
  };
@@ -1,7 +1,9 @@
1
+ import { UserPreferences } from '@m4l/core';
1
2
  import { Formatters } from '@m4l/graphics';
2
- import { WindowToolsMF, BaseModuleProps } from '@m4l/components';
3
+ import { BaseModuleProps, WindowToolsMF } from '@m4l/components';
3
4
  export interface ByHostProps {
4
5
  formatters: Formatters;
6
+ userPreferences: UserPreferences;
5
7
  windowTools: WindowToolsMF;
6
8
  }
7
9
  export interface MFNoAuthAppProps extends ByHostProps, BaseModuleProps {
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFNoAuthApp/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AACjE,MAAM,WAAW,WAAW;IAC1B,UAAU,EAAE,UAAU,CAAC;IACvB,WAAW,EAAE,aAAa,CAAC;CAC5B;AACD,MAAM,WAAW,gBAAiB,SAAQ,WAAW,EAAE,eAAe;IACpE;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC;CACxC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../packages/layouts/src/components/MFNoAuthApp/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,KAAK,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEtE,MAAM,WAAW,WAAW;IAC1B,UAAU,EAAE,UAAU,CAAC;IACvB,eAAe,EAAE,eAAe,CAAC;IACjC,WAAW,EAAE,aAAa,CAAC;CAC5B;AAED,MAAM,WAAW,gBAAiB,SAAQ,WAAW,EAAE,eAAe;IACpE;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC;CACxC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@m4l/layouts",
3
- "version": "9.8.1",
3
+ "version": "9.9.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
package/test/mocks.d.ts CHANGED
@@ -1,7 +1,6 @@
1
1
  import { Mock } from 'vitest';
2
2
  import { Formatters } from '@m4l/graphics';
3
3
  import * as core from '@m4l/core';
4
- import * as graphics from '@m4l/graphics';
5
4
  export declare const mock_addFlag: Mock;
6
5
  export declare const mock_networkOperation: Mock;
7
6
  export declare const mock_useFormatter: Mock;
@@ -21,11 +20,11 @@ export declare const mock_useEnvironment: {
21
20
  };
22
21
  export declare const formatterValues: Formatters;
23
22
  export declare const mockedGraphics: {
24
- useFormatter: Mock<() => import('@m4l/graphics').Formatters>;
23
+ useFormatter: Mock<() => import('../../../../dist/packages/@m4l/graphics/contexts/FormatterContext/types').FormatterContextProps>;
25
24
  };
26
25
  export declare function restoreGraphicsMocked(): void;
27
26
  export declare const coreImplementation: typeof core;
28
27
  export declare const graphicsImplementation: {
29
- useFormatter: Mock<() => import('@m4l/graphics').Formatters>;
28
+ useFormatter: Mock<() => import('../../../../dist/packages/@m4l/graphics/contexts/FormatterContext/types').FormatterContextProps>;
30
29
  };
31
30
  //# sourceMappingURL=mocks.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"mocks.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/test/mocks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAM,MAAM,QAAQ,CAAC;AAClC,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAE1C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,eAAO,MAAM,YAAY,EAAC,IAAc,CAAC;AACzC,eAAO,MAAM,qBAAqB,EAAC,IAAc,CAAC;AAClD,eAAO,MAAM,iBAAiB,EAAC,IAAc,CAAC;AAC9C,eAAO,MAAM,wBAAwB,EAAC,IAAc,CAAC;AACrD,eAAO,MAAM,2BAA2B,EAAC,IAAc,CAAC;AACxD,eAAO,MAAM,gBAAgB,EAAC,IAAc,CAAC;AAC7C,eAAO,MAAM,kBAAkB,EAAC,IAAc,CAAC;AAC/C,eAAO,MAAM,iBAAiB,EAAC,IAAc,CAAC;AAC9C,eAAO,MAAM,wBAAwB,EAAC,IAAc,CAAC;AACrD,eAAO,MAAM,mBAAmB;;;;;;;CAO/B,CAAC;AACF,eAAO,MAAM,eAAe,EAAE,UAY7B,CAAC;AAGF,eAAO,MAAM,cAAc;;CAE1B,CAAC;AACF,wBAAgB,qBAAqB,SAEpC;AACD,eAAO,MAAM,kBAAkB,aAAO,CAAC;AACvC,eAAO,MAAM,sBAAsB;;CAAiB,CAAC"}
1
+ {"version":3,"file":"mocks.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/test/mocks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAM,MAAM,QAAQ,CAAC;AAClC,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAIlC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,eAAO,MAAM,YAAY,EAAC,IAAc,CAAC;AACzC,eAAO,MAAM,qBAAqB,EAAC,IAAc,CAAC;AAClD,eAAO,MAAM,iBAAiB,EAAC,IAAc,CAAC;AAC9C,eAAO,MAAM,wBAAwB,EAAC,IAAc,CAAC;AACrD,eAAO,MAAM,2BAA2B,EAAC,IAAc,CAAC;AACxD,eAAO,MAAM,gBAAgB,EAAC,IAAc,CAAC;AAC7C,eAAO,MAAM,kBAAkB,EAAC,IAAc,CAAC;AAC/C,eAAO,MAAM,iBAAiB,EAAC,IAAc,CAAC;AAC9C,eAAO,MAAM,wBAAwB,EAAC,IAAc,CAAC;AACrD,eAAO,MAAM,mBAAmB;;;;;;;CAO/B,CAAC;AACF,eAAO,MAAM,eAAe,EAAE,UAY7B,CAAC;AAyBF,eAAO,MAAM,cAAc;;CAE1B,CAAC;AACF,wBAAgB,qBAAqB,SAEpC;AACD,eAAO,MAAM,kBAAkB,aAAO,CAAC;AACvC,eAAO,MAAM,sBAAsB;;CAAiB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"createAppMF.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/utils/createAppMF.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAS7C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,CAAC,KAAK,EAAE;QAAE,UAAU,CAAC,EAAE,UAAU,CAAA;KAAE,KAAK,GAAG,CAAC,OAAO,CAAC;IACzD,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,oBAAoB,EAAE,MAAM,EAAE,CAAC;IAC/B,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB,CAAC;AA6BF;;GAEG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,QAkFlD"}
1
+ {"version":3,"file":"createAppMF.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/utils/createAppMF.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAS7C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,CAAC,KAAK,EAAE;QAAE,UAAU,CAAC,EAAE,UAAU,CAAA;KAAE,KAAK,GAAG,CAAC,OAAO,CAAC;IACzD,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,oBAAoB,EAAE,MAAM,EAAE,CAAC;IAC/B,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB,CAAC;AA6BF;;GAEG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,gBAAgB,QAmFlD"}
@@ -1,34 +1,34 @@
1
- import { jsx as l } from "@emotion/react/jsx-runtime";
1
+ import { jsx as u } from "@emotion/react/jsx-runtime";
2
2
  import { MFHostApp as w } from "../components/MFHostApp/MFHostApp.js";
3
3
  import { createRoot as R } from "react-dom/client";
4
- function s(n, o) {
4
+ function t(n, o) {
5
5
  return `__root_${n}_${o}`;
6
6
  }
7
7
  function v(n, o) {
8
- return window[s(n, o)];
8
+ return window[t(n, o)];
9
9
  }
10
- function $(n, o, i) {
11
- window[s(n, o)] = i;
10
+ function $(n, o, r) {
11
+ window[t(n, o)] = r;
12
12
  }
13
13
  function h(n, o) {
14
- delete window[s(n, o)];
14
+ delete window[t(n, o)];
15
15
  }
16
- function a(n) {
16
+ function F(n) {
17
17
  const {
18
18
  prefixMF: o,
19
- moduleId: i,
20
- App: u,
19
+ moduleId: r,
20
+ App: l,
21
21
  privileges: p,
22
- appVersion: t,
22
+ appVersion: s,
23
23
  componentsDictionary: g,
24
24
  skeletonFlags: f
25
25
  } = n;
26
26
  function _(e) {
27
- const r = document.getElementById(e.containerId);
28
- if (r) {
29
- const m = R(r);
27
+ const i = document.getElementById(e.containerId);
28
+ if (i) {
29
+ const m = R(i);
30
30
  $(o, e.containerId, m), m.render(
31
- /* @__PURE__ */ l(
31
+ /* @__PURE__ */ u(
32
32
  w,
33
33
  {
34
34
  environment: e.environment,
@@ -37,9 +37,10 @@ function a(n) {
37
37
  currentLocale: e.currentLocale,
38
38
  hostTheme: e.hostTheme,
39
39
  formatters: e.formatter,
40
+ userPreferences: e.userPreferences,
40
41
  dynamicMFStore: e.dynamicMFStore,
41
- moduleId: i,
42
- moduleVersion: t,
42
+ moduleId: r,
43
+ moduleVersion: s,
43
44
  privileges: p,
44
45
  skeletonFlags: f,
45
46
  componentsDictionary: g,
@@ -47,7 +48,7 @@ function a(n) {
47
48
  hostRuntime: e.hostRuntime,
48
49
  observability: e.observability,
49
50
  loggedUser: e.loggedUser,
50
- children: /* @__PURE__ */ l(u, { emergeType: e.emergeType })
51
+ children: /* @__PURE__ */ u(l, { emergeType: e.emergeType })
51
52
  }
52
53
  )
53
54
  );
@@ -56,13 +57,13 @@ function a(n) {
56
57
  const d = ((e) => {
57
58
  _(e);
58
59
  });
59
- d.__version = t, window[`render_v2_${o}_${i}`] = d, window[`unmount_${o}_${i}`] = (e) => {
60
- const r = v(o, e);
61
- r && (r.unmount(), process.env.NODE_ENV === "development" && console.debug(`unmount_${o}_${i}`, e), h(o, e));
60
+ d.__version = s, window[`render_v2_${o}_${r}`] = d, window[`unmount_${o}_${r}`] = (e) => {
61
+ const i = v(o, e);
62
+ i && (i.unmount(), process.env.NODE_ENV === "development" && console.debug(`unmount_${o}_${r}`, e), h(o, e));
62
63
  }, process.env.NODE_ENV === "development" && console.debug(
63
- `******* Module ESM: ${o}_${i} - Version ${t} loaded ******* `
64
+ `******* Module ESM: ${o}_${r} - Version ${s} loaded ******* `
64
65
  );
65
66
  }
66
67
  export {
67
- a as createAppMF
68
+ F as createAppMF
68
69
  };
@@ -1 +1 @@
1
- {"version":3,"file":"mfRuntimeErrors.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/utils/mfRuntimeErrors.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,EAAE,KAAK,CAAC;IACb,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,MAAM,qBAAqB,GAAG,CAAC,KAAK,EAAE,mBAAmB,KAAK,IAAI,CAAC;AAIzE;;GAEG;AACH,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,qBAAqB,GAC7B,IAAI,CAEN;AAED;;GAEG;AACH,wBAAgB,+BAA+B,IAAI,IAAI,CAEtD;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI,CAMrE"}
1
+ {"version":3,"file":"mfRuntimeErrors.d.ts","sourceRoot":"","sources":["../../../../../packages/layouts/src/utils/mfRuntimeErrors.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,EAAE,KAAK,CAAC;IACb,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,MAAM,qBAAqB,GAAG,CAAC,KAAK,EAAE,mBAAmB,KAAK,IAAI,CAAC;AAgEzE;;GAEG;AACH,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,qBAAqB,GAC7B,IAAI,CAEN;AAED;;GAEG;AACH,wBAAgB,+BAA+B,IAAI,IAAI,CAEtD;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI,CAarE"}
@@ -1,18 +1,57 @@
1
- let e;
2
- function n(r) {
3
- e = r;
1
+ const o = /* @__PURE__ */ Symbol.for(
2
+ "m4l.layouts.mfRuntimeErrors"
3
+ );
4
+ function i(r) {
5
+ console.warn(
6
+ "MF runtime boundary crash was captured locally, but no host observability handler is registered.",
7
+ {
8
+ componentStack: r.componentStack,
9
+ instrumentationStatus: "missing-host-handler",
10
+ moduleId: r.moduleId,
11
+ moduleVersion: r.moduleVersion
12
+ },
13
+ r.error
14
+ );
15
+ }
16
+ function a(r, n) {
17
+ console.warn(
18
+ "MF runtime boundary crash was captured locally, but the host observability handler failed.",
19
+ {
20
+ componentStack: r.componentStack,
21
+ instrumentationStatus: "host-handler-failed",
22
+ moduleId: r.moduleId,
23
+ moduleVersion: r.moduleVersion
24
+ },
25
+ n
26
+ );
4
27
  }
5
28
  function t() {
6
- e = void 0;
29
+ const r = globalThis;
30
+ if (r[o])
31
+ return r[o];
32
+ const n = {};
33
+ return r[o] = n, n;
7
34
  }
8
- function i(r) {
35
+ function l(r) {
36
+ t().handler = r;
37
+ }
38
+ function u() {
39
+ t().handler = void 0;
40
+ }
41
+ function s(r) {
42
+ const n = t().handler;
43
+ if (!n) {
44
+ i(r);
45
+ return;
46
+ }
9
47
  try {
10
- e?.(r);
11
- } catch {
48
+ n(r);
49
+ } catch (e) {
50
+ a(r, e);
12
51
  }
13
52
  }
14
53
  export {
15
- n as registerMFRuntimeErrorHandler,
16
- i as reportMFRuntimeError,
17
- t as unregisterMFRuntimeErrorHandler
54
+ l as registerMFRuntimeErrorHandler,
55
+ s as reportMFRuntimeError,
56
+ u as unregisterMFRuntimeErrorHandler
18
57
  };