@m4l/layouts 1.0.4 → 1.0.5
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/components/BaseModule/index.8ff0193e.js +39 -0
- package/components/BaseModule/index.d.ts +4 -0
- package/components/BaseModule/types.d.ts +10 -0
- package/components/MFHostApp/index.401a303e.js +79 -0
- package/components/MFHostApp/index.d.ts +4 -0
- package/components/MFHostApp/types.d.ts +17 -0
- package/components/MFIsolationApp/index.d.ts +4 -0
- package/components/MFIsolationApp/index.e733d368.js +181 -0
- package/components/MFIsolationApp/subcomponents/MFAuthApp/index.d.ts +4 -0
- package/components/MFIsolationApp/subcomponents/MFAuthApp/types.d.ts +6 -0
- package/components/MFIsolationApp/types.d.ts +14 -0
- package/components/MFNoAuthApp/index.d.ts +4 -0
- package/components/MFNoAuthApp/types.d.ts +10 -0
- package/components/index.7006a30d.js +47 -0
- package/components/index.d.ts +6 -0
- package/contexts/AuthContext/index.6f966215.js +160 -0
- package/contexts/AuthContext/index.d.ts +5 -0
- package/contexts/AuthContext/types.d.ts +51 -0
- package/contexts/index.d.ts +1 -0
- package/contexts/index.ee173661.js +1 -0
- package/hooks/index.77acdde7.js +1 -0
- package/{dist/hooks → hooks}/index.d.ts +1 -0
- package/hooks/useAuth/index.cb6a3420.js +11 -0
- package/hooks/useAuth/index.d.ts +2 -0
- package/{dist/hooks/useMasterDetail/index.js → hooks/useMasterDetail/index.d45f2a86.js} +4 -2
- package/{dist/hooks/useModule/index.js → hooks/useModule/index.b5f598b1.js} +4 -2
- package/index.d.ts +4 -0
- package/index.js +46 -0
- package/{dist/layouts/MasterDetailLayout/index.d.ts → layouts/MasterDetailLayout/MasterDetailLayout.d.ts} +1 -1
- package/layouts/MasterDetailLayout/classes/constants.d.ts +1 -0
- package/layouts/MasterDetailLayout/classes/index.d.ts +6 -0
- package/layouts/MasterDetailLayout/classes/types.d.ts +6 -0
- package/{dist/layouts → layouts}/MasterDetailLayout/contexts/MasterDetailContext/index.d.ts +1 -1
- package/{dist/layouts → layouts}/MasterDetailLayout/contexts/MasterDetailContext/types.d.ts +2 -3
- package/layouts/MasterDetailLayout/index.748f7ada.js +155 -0
- package/layouts/MasterDetailLayout/styles.d.ts +2 -0
- package/{dist/layouts → layouts}/MasterDetailLayout/types.d.ts +0 -1
- package/layouts/ModuleLayout/classes/constants.d.ts +1 -0
- package/layouts/ModuleLayout/classes/index.d.ts +7 -0
- package/layouts/ModuleLayout/classes/types.d.ts +7 -0
- package/{dist/layouts → layouts}/ModuleLayout/contexts/ModuleContext/index.d.ts +2 -2
- package/{dist/layouts → layouts}/ModuleLayout/contexts/ModuleContext/types.d.ts +4 -9
- package/layouts/ModuleLayout/index.e7218171.js +122 -0
- package/layouts/ModuleLayout/subcomponents/InnerModule/index.d.ts +3 -0
- package/layouts/ModuleLayout/subcomponents/InnerModule/styles.d.ts +2 -0
- package/layouts/ModuleLayout/types.d.ts +16 -0
- package/layouts/NoAuthModuleLayout/dicctionary.d.ts +3 -0
- package/layouts/NoAuthModuleLayout/index.83cd3ea3.js +425 -0
- package/layouts/NoAuthModuleLayout/index.d.ts +3 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/index.d.ts +2 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/styles.d.ts +2 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/subcomponents/DesktopContent/index.d.ts +2 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/subcomponents/DesktopContent/styles.d.ts +10 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/subcomponents/MobileContent/index.d.ts +2 -0
- package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/subcomponents/MobileContent/styles.d.ts +9 -0
- package/layouts/NoAuthModuleLayout/types.d.ts +20 -0
- package/layouts/index.417b6868.js +1 -0
- package/layouts/index.d.ts +6 -0
- package/m4l_layouts/types.d.ts +0 -0
- package/package.json +22 -55
- package/dist/hooks/useResponsive.d.ts +0 -8
- package/dist/index.d.ts +0 -2
- package/dist/index.js +0 -12
- package/dist/layouts/MasterDetailLayout/components/ButtonDetail/index.d.ts +0 -3
- package/dist/layouts/MasterDetailLayout/index.js +0 -170
- package/dist/layouts/ModuleLayout/components/Header/index.d.ts +0 -2
- package/dist/layouts/ModuleLayout/components/Header/skeleton.d.ts +0 -2
- package/dist/layouts/ModuleLayout/components/Header/styles.d.ts +0 -8
- package/dist/layouts/ModuleLayout/components/Header/types.d.ts +0 -2
- package/dist/layouts/ModuleLayout/components/ModuleContent/index.d.ts +0 -3
- package/dist/layouts/ModuleLayout/components/ModuleContent/styles.d.ts +0 -3
- package/dist/layouts/ModuleLayout/index.js +0 -380
- package/dist/layouts/ModuleLayout/types.d.ts +0 -28
- package/dist/layouts/index.d.ts +0 -2
- package/dist/vendor.js +0 -35
- /package/{dist/hooks → hooks}/useMasterDetail/index.d.ts +0 -0
- /package/{dist/hooks → hooks}/useModule/index.d.ts +0 -0
- /package/{dist/layouts → layouts}/MasterDetailLayout/dicctionary.d.ts +0 -0
- /package/{dist/layouts/ModuleLayout/index.d.ts → layouts/ModuleLayout/ModuleLayout.d.ts} +0 -0
- /package/{dist/layouts → layouts}/ModuleLayout/dicctionary.d.ts +0 -0
- /package/{dist/layouts/ModuleLayout/components/ModuleContent → layouts/ModuleLayout/subcomponents/InnerModule}/types.d.ts +0 -0
- /package/{dist/vite-env.d.ts → vite-env.d.ts} +0 -0
|
@@ -0,0 +1,425 @@
|
|
|
1
|
+
import { useResponsiveDesktop, useLocales, ResponsiveContainerProvider } from "@m4l/graphics";
|
|
2
|
+
import { LanguagePopover, Image, Typography, Stack, ScrollBar, HelmetPage } from "@m4l/components";
|
|
3
|
+
import { styled } from "@mui/material";
|
|
4
|
+
import { useBase, useModuleDictionary, useDomain, useEnvironment, BaseProvider, FlagsProvider, ModuleDictionaryProvider, ModuleSkeletonProvider } from "@m4l/core";
|
|
5
|
+
import { styled as styled$1, alpha } from "@mui/material/styles";
|
|
6
|
+
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
7
|
+
const InnerModuleRoot = styled("div")(({
|
|
8
|
+
theme
|
|
9
|
+
}) => ({
|
|
10
|
+
display: "flex",
|
|
11
|
+
justifyContent: "center",
|
|
12
|
+
alignItems: "center",
|
|
13
|
+
height: "100vh",
|
|
14
|
+
padding: "20px",
|
|
15
|
+
backgroundColor: theme.vars.palette.background.background,
|
|
16
|
+
[theme.breakpoints.down("md")]: {
|
|
17
|
+
padding: "0px"
|
|
18
|
+
}
|
|
19
|
+
}));
|
|
20
|
+
const DesktopContentRoot = styled$1("div")(({ theme }) => ({
|
|
21
|
+
display: "flex",
|
|
22
|
+
borderRadius: "16px",
|
|
23
|
+
backgroundColor: theme.vars.palette.background.neutral,
|
|
24
|
+
boxShadow: theme.vars.customShadows?.z4,
|
|
25
|
+
padding: "20px 0 20px 20px",
|
|
26
|
+
width: "100%",
|
|
27
|
+
height: "100%",
|
|
28
|
+
maxWidth: "965px",
|
|
29
|
+
maxHeight: "900px",
|
|
30
|
+
position: "relative",
|
|
31
|
+
overflow: "auto",
|
|
32
|
+
"& .M4LanguagePopover-root": {
|
|
33
|
+
position: "absolute",
|
|
34
|
+
top: "20px",
|
|
35
|
+
right: "20px",
|
|
36
|
+
zIndex: 1
|
|
37
|
+
},
|
|
38
|
+
"& .M4LIconButton-root.config-icon": {
|
|
39
|
+
position: "absolute",
|
|
40
|
+
top: "25px",
|
|
41
|
+
right: "56px",
|
|
42
|
+
zIndex: 1
|
|
43
|
+
}
|
|
44
|
+
}));
|
|
45
|
+
const DesktopBanner = styled$1("div")(({ theme }) => ({
|
|
46
|
+
display: "flex",
|
|
47
|
+
flexDirection: "column",
|
|
48
|
+
justifyContent: "center",
|
|
49
|
+
alignItems: "center",
|
|
50
|
+
borderRadius: "12px",
|
|
51
|
+
width: "100%",
|
|
52
|
+
maxWidth: "400px",
|
|
53
|
+
height: "100%",
|
|
54
|
+
backgroundColor: theme.vars.palette.state?.focus,
|
|
55
|
+
boxShadow: theme.vars.customShadows?.z4,
|
|
56
|
+
padding: "0 60px",
|
|
57
|
+
gap: "40px",
|
|
58
|
+
overflow: "hidden",
|
|
59
|
+
"& .MuiTypography-root": {
|
|
60
|
+
color: theme.palette.patronus?.marbleLight[10],
|
|
61
|
+
display: "flex",
|
|
62
|
+
justifyContent: "center",
|
|
63
|
+
textAlign: "center",
|
|
64
|
+
textTransform: "uppercase"
|
|
65
|
+
},
|
|
66
|
+
"& .M4LTypography-root .MuiSkeleton-root": {
|
|
67
|
+
backgroundColor: alpha(
|
|
68
|
+
`${theme.colorSchemes.finalTheme.palette.patronus?.marbleLight[10]}`,
|
|
69
|
+
0.24
|
|
70
|
+
),
|
|
71
|
+
margin: "auto"
|
|
72
|
+
}
|
|
73
|
+
}));
|
|
74
|
+
const ContainerLogo$1 = styled$1("div")(({ theme }) => ({
|
|
75
|
+
display: "flex",
|
|
76
|
+
width: "84px",
|
|
77
|
+
height: "84px",
|
|
78
|
+
borderRadius: "6px",
|
|
79
|
+
backgroundColor: theme.vars.palette.state?.active,
|
|
80
|
+
justifyContent: "center",
|
|
81
|
+
alignItems: "center",
|
|
82
|
+
boxShadow: `0px 4px 8px ${alpha(
|
|
83
|
+
theme.colorSchemes.finalTheme.palette.patronus?.coolGrey[70] || "",
|
|
84
|
+
0.16
|
|
85
|
+
)}`,
|
|
86
|
+
"& .M4LImage-root": {
|
|
87
|
+
backgroundColor: theme.vars.palette.patronus?.marbleLight[10],
|
|
88
|
+
borderRadius: "6px"
|
|
89
|
+
}
|
|
90
|
+
}));
|
|
91
|
+
const CompanyName$1 = styled$1("div")(() => ({
|
|
92
|
+
display: "flex",
|
|
93
|
+
flexDirection: "column",
|
|
94
|
+
gap: "5px",
|
|
95
|
+
width: "100%"
|
|
96
|
+
}));
|
|
97
|
+
const CompanyLeyend = styled$1("div")(() => ({
|
|
98
|
+
display: "flex",
|
|
99
|
+
flexDirection: "column",
|
|
100
|
+
gap: "5px",
|
|
101
|
+
width: "100%"
|
|
102
|
+
}));
|
|
103
|
+
const FormContent$1 = styled$1("div")(() => ({
|
|
104
|
+
display: "flex",
|
|
105
|
+
flexDirection: "column",
|
|
106
|
+
padding: "0 60px 0 80px",
|
|
107
|
+
margin: "auto 0",
|
|
108
|
+
width: "100%",
|
|
109
|
+
height: "auto",
|
|
110
|
+
gap: "20px"
|
|
111
|
+
}));
|
|
112
|
+
const WrapperFormContent$1 = styled$1("div")(() => ({
|
|
113
|
+
display: "flex",
|
|
114
|
+
width: "100%",
|
|
115
|
+
height: "100%"
|
|
116
|
+
}));
|
|
117
|
+
const ContainerModuleName$1 = styled$1("div")(() => ({
|
|
118
|
+
display: "flex",
|
|
119
|
+
flexDirection: "column",
|
|
120
|
+
width: "100%",
|
|
121
|
+
gap: "4px"
|
|
122
|
+
}));
|
|
123
|
+
styled$1("div")(() => ({
|
|
124
|
+
display: "flex",
|
|
125
|
+
width: "100%",
|
|
126
|
+
height: "100%",
|
|
127
|
+
justifyContent: "center",
|
|
128
|
+
alignItems: "center"
|
|
129
|
+
}));
|
|
130
|
+
const DesktopContent = () => {
|
|
131
|
+
const {
|
|
132
|
+
children,
|
|
133
|
+
companyLogoSmallUrl
|
|
134
|
+
} = useBase();
|
|
135
|
+
const {
|
|
136
|
+
getLabel
|
|
137
|
+
} = useModuleDictionary();
|
|
138
|
+
const {
|
|
139
|
+
name,
|
|
140
|
+
slogan
|
|
141
|
+
} = useDomain();
|
|
142
|
+
return /* @__PURE__ */ jsxs(DesktopContentRoot, {
|
|
143
|
+
children: [/* @__PURE__ */ jsx(LanguagePopover, {}), /* @__PURE__ */ jsxs(DesktopBanner, {
|
|
144
|
+
children: [/* @__PURE__ */ jsx(ContainerLogo$1, {
|
|
145
|
+
children: /* @__PURE__ */ jsx(Image, {
|
|
146
|
+
src: companyLogoSmallUrl,
|
|
147
|
+
ratio: "1:1",
|
|
148
|
+
width: "64px",
|
|
149
|
+
height: "64px"
|
|
150
|
+
})
|
|
151
|
+
}), /* @__PURE__ */ jsxs(CompanyName$1, {
|
|
152
|
+
children: [/* @__PURE__ */ jsx(Typography, {
|
|
153
|
+
variant: "subtitleDens",
|
|
154
|
+
skeletonWidth: "70%",
|
|
155
|
+
skeletongHeight: "24px",
|
|
156
|
+
children: name
|
|
157
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
158
|
+
variant: "paragraph",
|
|
159
|
+
skeletonWidth: "40%",
|
|
160
|
+
skeletongHeight: "20px",
|
|
161
|
+
children: getLabel("company_name_subtitle")
|
|
162
|
+
})]
|
|
163
|
+
}), /* @__PURE__ */ jsxs(CompanyLeyend, {
|
|
164
|
+
children: [/* @__PURE__ */ jsx(Typography, {
|
|
165
|
+
variant: "h5",
|
|
166
|
+
skeletonWidth: "50%",
|
|
167
|
+
skeletongHeight: "36px",
|
|
168
|
+
children: getLabel("module_leyend")
|
|
169
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
170
|
+
variant: "subtitle",
|
|
171
|
+
skeletonWidth: "80%",
|
|
172
|
+
skeletongHeight: "24px",
|
|
173
|
+
children: slogan
|
|
174
|
+
})]
|
|
175
|
+
})]
|
|
176
|
+
}), /* @__PURE__ */ jsx(WrapperFormContent$1, {
|
|
177
|
+
children: /* @__PURE__ */ jsxs(FormContent$1, {
|
|
178
|
+
children: [/* @__PURE__ */ jsxs(ContainerModuleName$1, {
|
|
179
|
+
children: [/* @__PURE__ */ jsx(Typography, {
|
|
180
|
+
variant: "h5",
|
|
181
|
+
skeletonWidth: "20%",
|
|
182
|
+
skeletongHeight: "36px",
|
|
183
|
+
children: getLabel("module_name")
|
|
184
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
185
|
+
variant: "paragraph",
|
|
186
|
+
skeletonWidth: "40%",
|
|
187
|
+
skeletongHeight: "20px",
|
|
188
|
+
children: getLabel("module_description")
|
|
189
|
+
})]
|
|
190
|
+
}), /* @__PURE__ */ jsx(Stack, {
|
|
191
|
+
direction: "column",
|
|
192
|
+
height: "auto",
|
|
193
|
+
children: /* @__PURE__ */ jsx(ScrollBar, {
|
|
194
|
+
children: /* @__PURE__ */ jsx(Fragment, {
|
|
195
|
+
children
|
|
196
|
+
})
|
|
197
|
+
})
|
|
198
|
+
})]
|
|
199
|
+
})
|
|
200
|
+
})]
|
|
201
|
+
});
|
|
202
|
+
};
|
|
203
|
+
const MobileContentRoot = styled$1("div")(({ theme }) => ({
|
|
204
|
+
display: "flex",
|
|
205
|
+
flexDirection: "column",
|
|
206
|
+
width: "100%",
|
|
207
|
+
height: "100%",
|
|
208
|
+
backgroundColor: theme.vars.palette.background.neutral,
|
|
209
|
+
padding: "12px",
|
|
210
|
+
gap: "32px"
|
|
211
|
+
}));
|
|
212
|
+
const MobileBanner = styled$1("div")(({ theme }) => ({
|
|
213
|
+
display: "flex",
|
|
214
|
+
flexDirection: "column",
|
|
215
|
+
padding: "12px",
|
|
216
|
+
gap: "20px",
|
|
217
|
+
width: "100%",
|
|
218
|
+
backgroundColor: theme.vars.palette.state?.focus,
|
|
219
|
+
boxShadow: theme.customShadows?.z4,
|
|
220
|
+
position: "relative",
|
|
221
|
+
borderRadius: "8px",
|
|
222
|
+
"& .M4LanguagePopover-root": {
|
|
223
|
+
position: "absolute",
|
|
224
|
+
top: "12px",
|
|
225
|
+
right: "12px",
|
|
226
|
+
zIndex: 1
|
|
227
|
+
},
|
|
228
|
+
"& .M4LIconButton-root.config-icon": {
|
|
229
|
+
position: "absolute",
|
|
230
|
+
top: "13px",
|
|
231
|
+
right: "40px",
|
|
232
|
+
zIndex: 1,
|
|
233
|
+
"& .M4LIcon-root .M4LIcon-icon": {
|
|
234
|
+
backgroundColor: theme.vars.palette.patronus?.marbleLight[10]
|
|
235
|
+
}
|
|
236
|
+
},
|
|
237
|
+
"& .MuiTypography-root": {
|
|
238
|
+
color: theme.vars.palette.patronus?.marbleLight[10],
|
|
239
|
+
display: "flex",
|
|
240
|
+
textTransform: "uppercase"
|
|
241
|
+
},
|
|
242
|
+
"& .MuiSkeleton-root": {
|
|
243
|
+
backgroundColor: alpha(`${theme.colorSchemes.finalTheme.palette.patronus?.marbleLight[10]}`, 0.24),
|
|
244
|
+
margin: "auto"
|
|
245
|
+
}
|
|
246
|
+
}));
|
|
247
|
+
styled$1("div")(() => ({
|
|
248
|
+
display: "flex"
|
|
249
|
+
}));
|
|
250
|
+
const ContainerLogo = styled$1("div")(({ theme }) => ({
|
|
251
|
+
display: "flex",
|
|
252
|
+
width: "52px",
|
|
253
|
+
height: "52px",
|
|
254
|
+
borderRadius: "6px",
|
|
255
|
+
backgroundColor: theme.vars.palette.state?.active,
|
|
256
|
+
justifyContent: "center",
|
|
257
|
+
alignItems: "center",
|
|
258
|
+
boxShadow: `0px 4px 8px ${alpha(theme.colorSchemes.finalTheme.palette.patronus?.coolGrey[70] || "", 0.16)}`,
|
|
259
|
+
"& .M4LImage-root": {
|
|
260
|
+
backgroundColor: theme.vars.palette.patronus?.marbleLight[10],
|
|
261
|
+
borderRadius: "6px"
|
|
262
|
+
}
|
|
263
|
+
}));
|
|
264
|
+
const CompanyName = styled$1("div")(() => ({
|
|
265
|
+
display: "flex",
|
|
266
|
+
flexDirection: "column",
|
|
267
|
+
width: "100%"
|
|
268
|
+
}));
|
|
269
|
+
const FormContent = styled$1("div")(() => ({
|
|
270
|
+
display: "flex",
|
|
271
|
+
flexDirection: "column",
|
|
272
|
+
padding: "12px",
|
|
273
|
+
margin: "auto 0",
|
|
274
|
+
width: "100%",
|
|
275
|
+
gap: "20px"
|
|
276
|
+
}));
|
|
277
|
+
const WrapperFormContent = styled$1("div")(() => ({
|
|
278
|
+
display: "flex",
|
|
279
|
+
width: "100%",
|
|
280
|
+
height: "100%",
|
|
281
|
+
overflow: "hidden"
|
|
282
|
+
}));
|
|
283
|
+
const ContainerModuleName = styled$1("div")(() => ({
|
|
284
|
+
display: "flex",
|
|
285
|
+
flexDirection: "column",
|
|
286
|
+
width: "100%",
|
|
287
|
+
gap: "4px"
|
|
288
|
+
}));
|
|
289
|
+
const MobileContent = () => {
|
|
290
|
+
const {
|
|
291
|
+
children,
|
|
292
|
+
companyLogoSmallUrl
|
|
293
|
+
} = useBase();
|
|
294
|
+
const {
|
|
295
|
+
getLabel
|
|
296
|
+
} = useModuleDictionary();
|
|
297
|
+
const {
|
|
298
|
+
name
|
|
299
|
+
} = useDomain();
|
|
300
|
+
return /* @__PURE__ */ jsxs(MobileContentRoot, {
|
|
301
|
+
children: [/* @__PURE__ */ jsxs(MobileBanner, {
|
|
302
|
+
children: [/* @__PURE__ */ jsx(ContainerLogo, {
|
|
303
|
+
children: /* @__PURE__ */ jsx(Image, {
|
|
304
|
+
src: companyLogoSmallUrl,
|
|
305
|
+
ratio: "1:1",
|
|
306
|
+
width: "44px",
|
|
307
|
+
height: "44px"
|
|
308
|
+
})
|
|
309
|
+
}), /* @__PURE__ */ jsxs(CompanyName, {
|
|
310
|
+
children: [/* @__PURE__ */ jsx(Typography, {
|
|
311
|
+
variant: "subtitleDens",
|
|
312
|
+
skeletonWidth: "70%",
|
|
313
|
+
skeletongHeight: "24px",
|
|
314
|
+
children: name
|
|
315
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
316
|
+
variant: "paragraph",
|
|
317
|
+
skeletonWidth: "40%",
|
|
318
|
+
skeletongHeight: "20px",
|
|
319
|
+
children: getLabel("company_name_subtitle")
|
|
320
|
+
})]
|
|
321
|
+
}), /* @__PURE__ */ jsx(LanguagePopover, {})]
|
|
322
|
+
}), /* @__PURE__ */ jsx(WrapperFormContent, {
|
|
323
|
+
children: /* @__PURE__ */ jsx(ScrollBar, {
|
|
324
|
+
children: /* @__PURE__ */ jsxs(FormContent, {
|
|
325
|
+
children: [/* @__PURE__ */ jsxs(ContainerModuleName, {
|
|
326
|
+
children: [/* @__PURE__ */ jsx(Typography, {
|
|
327
|
+
variant: "h5",
|
|
328
|
+
skeletonWidth: "20%",
|
|
329
|
+
skeletongHeight: "36px",
|
|
330
|
+
children: getLabel("module_name")
|
|
331
|
+
}), /* @__PURE__ */ jsx(Typography, {
|
|
332
|
+
variant: "paragraph",
|
|
333
|
+
skeletonWidth: "40%",
|
|
334
|
+
skeletongHeight: "20px",
|
|
335
|
+
children: getLabel("module_description")
|
|
336
|
+
})]
|
|
337
|
+
}), children]
|
|
338
|
+
})
|
|
339
|
+
})
|
|
340
|
+
})]
|
|
341
|
+
});
|
|
342
|
+
};
|
|
343
|
+
const InnerModule = () => {
|
|
344
|
+
const {
|
|
345
|
+
getModuleLabel
|
|
346
|
+
} = useModuleDictionary();
|
|
347
|
+
const isDesktop = useResponsiveDesktop();
|
|
348
|
+
const {
|
|
349
|
+
subtitle
|
|
350
|
+
} = useBase();
|
|
351
|
+
return /* @__PURE__ */ jsx(HelmetPage, {
|
|
352
|
+
title: getModuleLabel(),
|
|
353
|
+
subtitle,
|
|
354
|
+
children: /* @__PURE__ */ jsx(Fragment, {
|
|
355
|
+
children: /* @__PURE__ */ jsx(InnerModuleRoot, {
|
|
356
|
+
id: "modulerootnouth",
|
|
357
|
+
children: isDesktop ? /* @__PURE__ */ jsx(DesktopContent, {}) : /* @__PURE__ */ jsx(MobileContent, {})
|
|
358
|
+
})
|
|
359
|
+
})
|
|
360
|
+
});
|
|
361
|
+
};
|
|
362
|
+
const NoAuthModuleLayout = (props) => {
|
|
363
|
+
const {
|
|
364
|
+
moduleId,
|
|
365
|
+
moduleNameField,
|
|
366
|
+
children,
|
|
367
|
+
componentsDictionary,
|
|
368
|
+
skeletonFlags,
|
|
369
|
+
subtitle,
|
|
370
|
+
companyLogoSmallUrl,
|
|
371
|
+
companyLogoNormalUrl,
|
|
372
|
+
moduleIlustrationUrl,
|
|
373
|
+
handleSetting,
|
|
374
|
+
observedDivRef
|
|
375
|
+
} = props;
|
|
376
|
+
const {
|
|
377
|
+
host_static_assets,
|
|
378
|
+
environment_assets
|
|
379
|
+
} = useEnvironment();
|
|
380
|
+
const localeString = useLocales().currentLocale?.localeString;
|
|
381
|
+
const finalCompanyLogoNormalUrl = companyLogoNormalUrl || `${host_static_assets}/${environment_assets}/frontend/commons/assets/icons/logotipo_m4l.svg`;
|
|
382
|
+
const finalCompanyLogoSmallUrl = companyLogoSmallUrl || `${host_static_assets}/${environment_assets}/frontend/commons/assets/icons/isotipo_m4l.svg`;
|
|
383
|
+
const finalIllustrationUrl = moduleIlustrationUrl || `${host_static_assets}/${environment_assets}/frontend/domain/host/commons/assets/img/illustration_noauth.png`;
|
|
384
|
+
const finalSkeletonFlags = skeletonFlags;
|
|
385
|
+
if (finalSkeletonFlags.findIndex((f) => f === "dictionary_loaded") < 0) {
|
|
386
|
+
finalSkeletonFlags.push("dictionary_loaded");
|
|
387
|
+
}
|
|
388
|
+
return /* @__PURE__ */ jsx(BaseProvider, {
|
|
389
|
+
value: {
|
|
390
|
+
subtitle,
|
|
391
|
+
companyLogoSmallUrl: finalCompanyLogoSmallUrl,
|
|
392
|
+
companyLogoNormalUrl: finalCompanyLogoNormalUrl,
|
|
393
|
+
moduleIlustrationUrl: finalIllustrationUrl,
|
|
394
|
+
children,
|
|
395
|
+
handleSetting
|
|
396
|
+
},
|
|
397
|
+
children: /* @__PURE__ */ jsx(FlagsProvider, {
|
|
398
|
+
children: /* @__PURE__ */ jsx(ModuleDictionaryProvider, {
|
|
399
|
+
isAuth: false,
|
|
400
|
+
moduleId,
|
|
401
|
+
moduleNameField,
|
|
402
|
+
componentsDictionary,
|
|
403
|
+
currentLang: localeString,
|
|
404
|
+
children: /* @__PURE__ */ jsx(ModuleSkeletonProvider, {
|
|
405
|
+
flags: finalSkeletonFlags,
|
|
406
|
+
children: /* @__PURE__ */ jsx(ResponsiveContainerProvider, {
|
|
407
|
+
observedDivRef,
|
|
408
|
+
children: /* @__PURE__ */ jsx(InnerModule, {})
|
|
409
|
+
})
|
|
410
|
+
})
|
|
411
|
+
})
|
|
412
|
+
})
|
|
413
|
+
});
|
|
414
|
+
};
|
|
415
|
+
function getNoAuthModuleLayoutComponentsDictionary() {
|
|
416
|
+
return ["no_auth_module_layout"];
|
|
417
|
+
}
|
|
418
|
+
const defaultNoAuthModuleLayoutDictionary = {
|
|
419
|
+
no_auth_module_layout: {}
|
|
420
|
+
};
|
|
421
|
+
export {
|
|
422
|
+
NoAuthModuleLayout as N,
|
|
423
|
+
defaultNoAuthModuleLayoutDictionary as d,
|
|
424
|
+
getNoAuthModuleLayoutComponentsDictionary as g
|
|
425
|
+
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const InnerModuleRoot: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const DesktopContentRoot: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
3
|
+
export declare const DesktopBanner: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
4
|
+
export declare const ContainerLogo: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
5
|
+
export declare const CompanyName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
6
|
+
export declare const CompanyLeyend: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
|
+
export declare const FormContent: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
8
|
+
export declare const WrapperFormContent: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
9
|
+
export declare const ContainerModuleName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
10
|
+
export declare const ContentForm: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
package/layouts/NoAuthModuleLayout/subcomponents/InnerModule/subcomponents/MobileContent/styles.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const MobileContentRoot: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
3
|
+
export declare const MobileBanner: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
4
|
+
export declare const ContainerImageLanguage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
5
|
+
export declare const ContainerLogo: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
6
|
+
export declare const CompanyName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
|
+
export declare const FormContent: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
8
|
+
export declare const WrapperFormContent: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
9
|
+
export declare const ContainerModuleName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface ContainerProps {
|
|
3
|
+
vertical: boolean;
|
|
4
|
+
}
|
|
5
|
+
export declare type MenuActionType = 'main' | 'allways' | 'normal';
|
|
6
|
+
export declare interface NoAuthBaseProviderProps {
|
|
7
|
+
subtitle?: string;
|
|
8
|
+
companyLogoSmallUrl: string;
|
|
9
|
+
companyLogoNormalUrl: string;
|
|
10
|
+
moduleIlustrationUrl?: string;
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
handleSetting?: () => void;
|
|
13
|
+
}
|
|
14
|
+
export interface NoAuthModuleLayoutProps extends NoAuthBaseProviderProps {
|
|
15
|
+
moduleId: string;
|
|
16
|
+
moduleNameField?: string;
|
|
17
|
+
componentsDictionary: string[];
|
|
18
|
+
skeletonFlags: string[];
|
|
19
|
+
observedDivRef: Element | Text | null;
|
|
20
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { ModuleLayout } from './ModuleLayout/ModuleLayout';
|
|
2
|
+
export * from './ModuleLayout/dicctionary';
|
|
3
|
+
export { MasterDetailLayout } from './MasterDetailLayout/MasterDetailLayout';
|
|
4
|
+
export * from './MasterDetailLayout/dicctionary';
|
|
5
|
+
export { NoAuthModuleLayout } from './NoAuthModuleLayout';
|
|
6
|
+
export * from './NoAuthModuleLayout/dicctionary';
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,67 +1,34 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@m4l/layouts",
|
|
3
|
-
"
|
|
4
|
-
"version": "1.0.4",
|
|
3
|
+
"version": "1.0.5",
|
|
5
4
|
"license": "UNLICENSED",
|
|
6
|
-
"
|
|
7
|
-
|
|
8
|
-
"build": "tsc && vite build",
|
|
9
|
-
"preview": "vite preview",
|
|
10
|
-
"lint": "npx eslint src",
|
|
11
|
-
"lint:fix": "npm run lint -- --fix",
|
|
12
|
-
"prettier": "npx prettier src --check",
|
|
13
|
-
"prettier:fix": "npm run prettier -- --write",
|
|
14
|
-
"format": "npm run prettier:fix && npm run lint:fix"
|
|
15
|
-
},
|
|
5
|
+
"author": "M4L Team",
|
|
6
|
+
"private": false,
|
|
16
7
|
"dependencies": {
|
|
17
|
-
"@m4l/components": "
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
"@emotion/styled": "^11.9.3",
|
|
23
|
-
"@testing-library/react": "^13.3.0",
|
|
24
|
-
"@testing-library/user-event": "^14.2.1",
|
|
25
|
-
"@types/node": "^17.0.40",
|
|
26
|
-
"@types/react": "^18.0.0",
|
|
27
|
-
"@types/react-dom": "^18.0.0",
|
|
28
|
-
"@typescript-eslint/eslint-plugin": "^5.27.1",
|
|
29
|
-
"@typescript-eslint/parser": "^5.27.1",
|
|
30
|
-
"@vitejs/plugin-react": "^1.3.0",
|
|
31
|
-
"eslint": "^8.17.0",
|
|
32
|
-
"eslint-config-prettier": "^8.5.0",
|
|
33
|
-
"eslint-import-resolver-alias": "^1.1.2",
|
|
34
|
-
"eslint-plugin-import": "^2.26.0",
|
|
35
|
-
"eslint-plugin-jsx-a11y": "^6.5.1",
|
|
36
|
-
"eslint-plugin-prettier": "^4.0.0",
|
|
37
|
-
"eslint-plugin-react": "^7.30.0",
|
|
38
|
-
"eslint-plugin-react-hooks": "^4.5.0",
|
|
39
|
-
"eslint-plugin-unused-imports": "^2.0.0",
|
|
40
|
-
"prettier": "^2.6.2",
|
|
41
|
-
"rollup-plugin-terser": "^7.0.2",
|
|
42
|
-
"typescript": "^4.6.3",
|
|
43
|
-
"vite": "^2.9.9",
|
|
44
|
-
"vite-plugin-dts": "^1.2.0",
|
|
45
|
-
"vite-plugin-mkcert": "^1.6.4",
|
|
46
|
-
"vitest": "^0.17.1"
|
|
8
|
+
"@m4l/components": "*",
|
|
9
|
+
"@m4l/core": "*",
|
|
10
|
+
"@m4l/graphics": "*",
|
|
11
|
+
"@m4l/styles": "*",
|
|
12
|
+
"@mui/material": "5.15.19"
|
|
47
13
|
},
|
|
48
14
|
"peerDependencies": {
|
|
49
|
-
"react": "^17.0.0 || 18.
|
|
50
|
-
"react-dom": "^18.0.0",
|
|
51
|
-
"
|
|
15
|
+
"@types/react": "^17.0.0 || ^18.0.0",
|
|
16
|
+
"@types/react-dom": "^17.0.0 || ^18.0.0",
|
|
17
|
+
"eventemitter3": "^4.0.7",
|
|
18
|
+
"history": "5.3.0",
|
|
19
|
+
"nprogress": "^0.2.0",
|
|
20
|
+
"react": "^17.0.0 || ^18.0.0",
|
|
21
|
+
"react-dom": "^17.0.0 || ^18.0.0",
|
|
22
|
+
"react-toastify": "9.0.5"
|
|
52
23
|
},
|
|
53
24
|
"files": [
|
|
54
|
-
"
|
|
25
|
+
"*"
|
|
55
26
|
],
|
|
56
|
-
"
|
|
57
|
-
"
|
|
58
|
-
"
|
|
27
|
+
"source": "./index.js",
|
|
28
|
+
"main": "./index.js",
|
|
29
|
+
"module": "./index.js",
|
|
59
30
|
"type": "module",
|
|
60
|
-
"
|
|
61
|
-
".": {
|
|
62
|
-
"import": "./dist/index.js"
|
|
63
|
-
}
|
|
64
|
-
},
|
|
31
|
+
"types": "./index.d.ts",
|
|
65
32
|
"sideEffects": false,
|
|
66
33
|
"publishConfig": {
|
|
67
34
|
"access": "public"
|
|
@@ -69,4 +36,4 @@
|
|
|
69
36
|
"engines": {
|
|
70
37
|
"node": ">=12.0.0"
|
|
71
38
|
}
|
|
72
|
-
}
|
|
39
|
+
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { Breakpoint } from '@mui/material';
|
|
2
|
-
declare type Query = 'up' | 'down' | 'between' | 'only';
|
|
3
|
-
declare type Key = Breakpoint | number;
|
|
4
|
-
declare type Start = Breakpoint | number;
|
|
5
|
-
declare type End = Breakpoint | number;
|
|
6
|
-
export declare function useResponsive(query: Query, key?: Key, start?: Start, end?: End): boolean | undefined;
|
|
7
|
-
export declare function useResponsiveDesktop(): boolean | undefined;
|
|
8
|
-
export {};
|
package/dist/index.d.ts
DELETED
package/dist/index.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export { a as MasterDetailLayout } from "./layouts/MasterDetailLayout/index.js";
|
|
2
|
-
export { a as ModuleLayout } from "./layouts/ModuleLayout/index.js";
|
|
3
|
-
export { u as useMasterDetail } from "./hooks/useMasterDetail/index.js";
|
|
4
|
-
export { u as useModule } from "./hooks/useModule/index.js";
|
|
5
|
-
import "react";
|
|
6
|
-
import "@m4l/core";
|
|
7
|
-
import "@m4l/components";
|
|
8
|
-
import "react/jsx-runtime";
|
|
9
|
-
import "./vendor.js";
|
|
10
|
-
import "@mui/material/styles";
|
|
11
|
-
import "@mui/material/useMediaQuery";
|
|
12
|
-
import "@mui/material";
|