@m4l/components 9.3.4 → 9.3.6

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 (80) hide show
  1. package/@types/types.d.ts +15 -0
  2. package/components/ObjectLogs/subcomponents/DetailDialog/index.js +3 -8
  3. package/components/ObjectLogs/types.d.ts +0 -2
  4. package/components/SettingsLayout/SettingsLayout.d.ts +5 -0
  5. package/components/SettingsLayout/SettingsLayout.js +34 -0
  6. package/components/SettingsLayout/SettingsLayout.styles.d.ts +2 -0
  7. package/components/SettingsLayout/SettingsLayout.styles.js +270 -0
  8. package/components/SettingsLayout/constants.d.ts +7 -0
  9. package/components/SettingsLayout/constants.js +10 -0
  10. package/components/SettingsLayout/dictionary.d.ts +8 -0
  11. package/components/SettingsLayout/dictionary.js +11 -0
  12. package/components/SettingsLayout/icons.d.ts +14 -0
  13. package/components/SettingsLayout/icons.js +17 -0
  14. package/components/SettingsLayout/index.d.ts +2 -0
  15. package/components/SettingsLayout/index.js +1 -0
  16. package/components/SettingsLayout/slots/SettingsLayoutEnum.d.ts +17 -0
  17. package/components/SettingsLayout/slots/SettingsLayoutEnum.js +21 -0
  18. package/components/SettingsLayout/slots/SettingsLayoutSlots.d.ts +47 -0
  19. package/components/SettingsLayout/slots/SettingsLayoutSlots.js +83 -0
  20. package/components/SettingsLayout/subcomponents/SettingColorPresets/SettingColorPresets.d.ts +5 -0
  21. package/components/SettingsLayout/subcomponents/SettingColorPresets/SettingColorPresets.js +37 -0
  22. package/components/SettingsLayout/subcomponents/SettingColorPresets/index.d.ts +1 -0
  23. package/components/SettingsLayout/subcomponents/SettingColorPresets/index.js +1 -0
  24. package/components/SettingsLayout/subcomponents/SettingColorPresets/types.d.ts +3 -0
  25. package/components/SettingsLayout/subcomponents/SettingDirection/SettingDirection.d.ts +5 -0
  26. package/components/SettingsLayout/subcomponents/SettingDirection/SettingDirection.js +37 -0
  27. package/components/SettingsLayout/subcomponents/SettingDirection/index.d.ts +1 -0
  28. package/components/SettingsLayout/subcomponents/SettingDirection/types.d.ts +3 -0
  29. package/components/SettingsLayout/subcomponents/SettingFullscreen/SettingFullscreen.d.ts +5 -0
  30. package/components/SettingsLayout/subcomponents/SettingFullscreen/SettingFullscreen.js +40 -0
  31. package/components/SettingsLayout/subcomponents/SettingFullscreen/index.d.ts +1 -0
  32. package/components/SettingsLayout/subcomponents/SettingFullscreen/index.js +1 -0
  33. package/components/SettingsLayout/subcomponents/SettingFullscreen/types.d.ts +3 -0
  34. package/components/SettingsLayout/subcomponents/SettingItem/SettingItem.d.ts +8 -0
  35. package/components/SettingsLayout/subcomponents/SettingItem/SettingItem.js +23 -0
  36. package/components/SettingsLayout/subcomponents/SettingItem/index.d.ts +1 -0
  37. package/components/SettingsLayout/subcomponents/SettingItem/index.js +1 -0
  38. package/components/SettingsLayout/subcomponents/SettingItem/types.d.ts +5 -0
  39. package/components/SettingsLayout/subcomponents/SettingItemColor/SettingItemColor.d.ts +8 -0
  40. package/components/SettingsLayout/subcomponents/SettingItemColor/SettingItemColor.js +24 -0
  41. package/components/SettingsLayout/subcomponents/SettingItemColor/index.d.ts +1 -0
  42. package/components/SettingsLayout/subcomponents/SettingItemColor/index.js +1 -0
  43. package/components/SettingsLayout/subcomponents/SettingItemColor/types.d.ts +6 -0
  44. package/components/SettingsLayout/subcomponents/SettingMode/SettingMode.d.ts +5 -0
  45. package/components/SettingsLayout/subcomponents/SettingMode/SettingMode.js +36 -0
  46. package/components/SettingsLayout/subcomponents/SettingMode/index.d.ts +1 -0
  47. package/components/SettingsLayout/subcomponents/SettingMode/index.js +1 -0
  48. package/components/SettingsLayout/subcomponents/SettingMode/types.d.ts +3 -0
  49. package/components/SettingsLayout/subcomponents/SettingsLayoutBase/SettingsLayoutBase.d.ts +5 -0
  50. package/components/SettingsLayout/subcomponents/SettingsLayoutBase/SettingsLayoutBase.js +76 -0
  51. package/components/SettingsLayout/subcomponents/SettingsLayoutBase/index.d.ts +1 -0
  52. package/components/SettingsLayout/subcomponents/SettingsLayoutBase/index.js +1 -0
  53. package/components/SettingsLayout/subcomponents/SettingsLayoutBase/types.d.ts +5 -0
  54. package/components/SettingsLayout/test/SettingsLayout.test.d.ts +18 -0
  55. package/components/SettingsLayout/types.d.ts +47 -0
  56. package/components/extended/React-Json-Viewer/ReactJsonViewer.d.ts +7 -0
  57. package/components/extended/React-Json-Viewer/ReactJsonViewer.js +31 -0
  58. package/components/extended/React-Json-Viewer/ReactJsonViewer.styles.d.ts +2 -0
  59. package/components/extended/React-Json-Viewer/ReactJsonViewer.styles.js +12 -0
  60. package/components/extended/React-Json-Viewer/constants.d.ts +2 -0
  61. package/components/extended/React-Json-Viewer/constants.js +8 -0
  62. package/components/extended/React-Json-Viewer/helpers/getReactJsonViewerTheme/getReactJsonViewerTheme.d.ts +8 -0
  63. package/components/extended/React-Json-Viewer/helpers/getReactJsonViewerTheme/getReactJsonViewerTheme.js +23 -0
  64. package/components/extended/React-Json-Viewer/helpers/getReactJsonViewerTheme/index.d.ts +1 -0
  65. package/components/extended/React-Json-Viewer/index.d.ts +1 -0
  66. package/components/extended/React-Json-Viewer/index.js +1 -0
  67. package/components/extended/React-Json-Viewer/slots/ReactJsonViewerEnum.d.ts +3 -0
  68. package/components/extended/React-Json-Viewer/slots/ReactJsonViewerEnum.js +7 -0
  69. package/components/extended/React-Json-Viewer/slots/ReactJsonViewerSlots.d.ts +1 -0
  70. package/components/extended/React-Json-Viewer/slots/ReactJsonViewerSlots.js +11 -0
  71. package/components/extended/React-Json-Viewer/test/ReactJsonViewer.test.d.ts +1 -0
  72. package/components/extended/React-Json-Viewer/types.d.ts +12 -0
  73. package/components/extended/index.d.ts +1 -0
  74. package/components/index.d.ts +1 -0
  75. package/index.js +46 -42
  76. package/package.json +1 -1
  77. package/storybook/components/SettingsLayout/SettingsLayout.stories.d.ts +6 -0
  78. package/storybook/components/SettingsLayout/subcomponents/SettingsLayoutRender/SettingsLayoutsRender.d.ts +5 -0
  79. package/storybook/components/SettingsLayout/subcomponents/SettingsLayoutRender/index.d.ts +1 -0
  80. package/storybook/components/extended/React-Json-Viewer/ReactJsonViewer.stories.d.ts +9 -0
package/@types/types.d.ts CHANGED
@@ -144,6 +144,7 @@ import { RHFUploadSingleFileOwnerState, RHFUploadSingleFileSlotsType } from '../
144
144
  import { ChipStatusFormatterSlotsType } from '../components/formatters/ChipStatusFormatter/types';
145
145
  import { RHFUploadImageOwnerState, RHFUploadImageSlotsType } from '../components/hook-form/RHFUpload/RHFUploadImage/types';
146
146
  import { PrintingSystemOwnerState, PrintingSystemSlotsType } from '../components/PrintingSystem/types';
147
+ import { SettingsLayoutOwnerState, SettingsLayoutSlotsType } from '../components/SettingsLayout/types';
147
148
  import { ScrollBarOwnerState, ScrollBarSlotsType } from '../components/ScrollBar/types';
148
149
  import { SplitLayoutOwnerState } from '../components/extended/React-resizable-panels/types';
149
150
  import { ObjectLogsOwnerState, ObjectLogsSlotsType } from '../components/ObjectLogs/types';
@@ -225,12 +226,14 @@ declare module '@mui/material/styles' {
225
226
  M4LChipStatusFormatter: ChipStatusFormatterSlotsType;
226
227
  M4LRHFUploadImage: RHFUploadImageSlotsType;
227
228
  M4LPrintingSystem: PrintingSystemSlotsType;
229
+ M4LSettingsLayout: SettingsLayoutSlotsType;
228
230
  M4LScrollbar: ScrollBarSlotsType;
229
231
  M4LSplitLayout: SplitLayoutOwnerState;
230
232
  M4LObjectLogs: ObjectLogsSlotsType;
231
233
  M4LLanguagePopover: LanguagePopoverSlotsType;
232
234
  M4LCard: CardSlotsType;
233
235
  M4LContainerFlow: ContainerFlowSlotsType;
236
+ M4LSettingsLayoutBase: SettingsLayoutSlotsType;
234
237
  }
235
238
  interface ComponentsPropsList {
236
239
  // Extend ComponentsProps or ComponentsOwnerState(this extend ComponentProps)
@@ -306,12 +309,14 @@ declare module '@mui/material/styles' {
306
309
  M4LChipStatusFormatter: Partial<ChipStatusFormatterOwnerState>;
307
310
  M4LRHFUploadImage: Partial<RHFUploadImageOwnerState>;
308
311
  M4LPrintingSystem: Partial<PrintingSystemOwnerState>;
312
+ M4LSettingsLayout: Partial<SettingsLayoutOwnerState>;
309
313
  M4LScrollBar: Partial<ScrollBarOwnerState>;
310
314
  M4LSplitLayout: Partial<SplitLayoutOwnerState>;
311
315
  M4LObjectLogs: Partial<ObjectLogsOwnerState>;
312
316
  M4LLanguagePopover: Partial<LanguagePopoverOwnerState>;
313
317
  M4LCard: Partial<CardOwnerState>;
314
318
  M4LContainerFlow: Partial<ContainerFlowOwnerState>;
319
+ M4LSettingsLayoutBase: Partial<SettingsLayoutOwnerState>;
315
320
  }
316
321
  interface Components {
317
322
  M4LDynamicFilter?: {
@@ -684,6 +689,11 @@ declare module '@mui/material/styles' {
684
689
  styleOverrides?: ComponentsOverrides<Theme>['M4LPrintingSystem'];
685
690
  variants?: ComponentsVariants['M4LPrintingSystem'];
686
691
  };
692
+ M4LSettingsLayout?: {
693
+ defaultProps?: ComponentsPropsList['M4LSettingsLayout'];
694
+ styleOverrides?: ComponentsOverrides<Theme>['M4LSettingsLayout'];
695
+ variants?: ComponentsVariants['M4LSettingsLayout'];
696
+ };
687
697
  M4LScrollBar?: {
688
698
  defaultProps?: ComponentsPropsList['M4LScrollBar'];
689
699
  styleOverrides?: ComponentsOverrides<Theme>['M4LScrollBar'];
@@ -714,5 +724,10 @@ declare module '@mui/material/styles' {
714
724
  styleOverrides?: ComponentsOverrides<Theme>['M4LContainerFlow'];
715
725
  variants?: ComponentsVariants['M4LContainerFlow'];
716
726
  };
727
+ M4LSettingsLayoutBase?: {
728
+ defaultProps?: ComponentsPropsList['M4LSettingsLayoutBase'];
729
+ styleOverrides?: ComponentsOverrides<Theme>['M4LSettingsLayoutBase'];
730
+ variants?: ComponentsVariants['M4LSettingsLayoutBase'];
731
+ };
717
732
  }
718
733
  }
@@ -1,13 +1,11 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useState, useEffect } from "react";
3
3
  import { useNetwork } from "@m4l/core";
4
- import { useHostTheme } from "@m4l/graphics";
5
- import ReactJson from "@microlink/react-json-view";
6
4
  import { a as OBJECT_LOGS_M4L_END_POINT, b as OBJECT_LOGS_OTHERS_END_POINT } from "../../constants.js";
5
+ import { R as ReactJsonViewer } from "../../../extended/React-Json-Viewer/ReactJsonViewer.js";
7
6
  function DetailDialog(props) {
8
- const { logId, theme, type } = props;
7
+ const { logId, type } = props;
9
8
  const { networkOperation } = useNetwork();
10
- const { hostThemeOptions } = useHostTheme();
11
9
  const [detail, setDetail] = useState({});
12
10
  useEffect(() => {
13
11
  let mounted = true;
@@ -27,12 +25,9 @@ function DetailDialog(props) {
27
25
  mounted = false;
28
26
  };
29
27
  }, []);
30
- const modeTheme = hostThemeOptions.palette?.mode;
31
- const appliedTheme = theme || (modeTheme === "dark" ? "summerfruit" : "rjv-default");
32
28
  return /* @__PURE__ */ jsx(
33
- ReactJson,
29
+ ReactJsonViewer,
34
30
  {
35
- theme: appliedTheme,
36
31
  name: null,
37
32
  sortKeys: true,
38
33
  displayDataTypes: false,
@@ -1,5 +1,4 @@
1
1
  import { Maybe } from '@m4l/core';
2
- import { ThemeKeys, ThemeObject } from '@microlink/react-json-view';
3
2
  import { Theme } from '@mui/material';
4
3
  import { ObjectLogsSlots } from './slots/ObjectLogsEnum';
5
4
  import { OBJECT_LOGS_KEY_COMPONENT } from './constants';
@@ -35,7 +34,6 @@ export interface ObjectLogsQueryParams {
35
34
  export interface DetailDialogProps {
36
35
  type: 'm4l' | 'other';
37
36
  logId: number | string;
38
- theme?: ThemeKeys | ThemeObject;
39
37
  }
40
38
  export type ObjectLogsSlotsType = keyof typeof ObjectLogsSlots;
41
39
  export type ObjectLogsOwnerState = {};
@@ -0,0 +1,5 @@
1
+ import { SettingsLayoutProps } from './types';
2
+ /**
3
+ * todo
4
+ */
5
+ export declare const SettingsLayout: (props: SettingsLayoutProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,34 @@
1
+ import { jsx } from "react/jsx-runtime";
2
+ import { useEnvironment, FlagsProvider, ModuleDictionaryProvider, ModuleSkeletonProvider, CommonFlags } from "@m4l/core";
3
+ import { useLocales, useThemeSettingsStore } from "@m4l/graphics";
4
+ import { S as SETTINGS_LAYOUT_DEFAULT_WIDTH } from "./constants.js";
5
+ import { useMemo } from "react";
6
+ import { S as SettingsLayoutBase } from "./subcomponents/SettingsLayoutBase/SettingsLayoutBase.js";
7
+ const SettingsLayout = (props) => {
8
+ const {
9
+ width = SETTINGS_LAYOUT_DEFAULT_WIDTH
10
+ } = props;
11
+ const currentLang = useLocales().currentLocale?.localeString;
12
+ const { host_static_assets, environment_assets } = useEnvironment();
13
+ const { open } = useThemeSettingsStore((state) => state);
14
+ const prefixPathIcon = `${host_static_assets}/${environment_assets}`;
15
+ const componentsDictionary = useMemo(() => {
16
+ return [];
17
+ }, []);
18
+ if (!open) {
19
+ return null;
20
+ }
21
+ return /* @__PURE__ */ jsx(FlagsProvider, { children: /* @__PURE__ */ jsx(
22
+ ModuleDictionaryProvider,
23
+ {
24
+ isAuth: false,
25
+ moduleId: "theme_settings",
26
+ componentsDictionary,
27
+ currentLang,
28
+ children: /* @__PURE__ */ jsx(ModuleSkeletonProvider, { flags: [CommonFlags.FLAG_DICTIONARY_LOADED], children: /* @__PURE__ */ jsx(SettingsLayoutBase, { prefixPathIcon, width }) })
29
+ }
30
+ ) });
31
+ };
32
+ export {
33
+ SettingsLayout as S
34
+ };
@@ -0,0 +1,2 @@
1
+ import { SettingsLayoutstyles } from './types';
2
+ export declare const settingsLayoutStyles: SettingsLayoutstyles;
@@ -0,0 +1,270 @@
1
+ import { PRIMARY_COLORS_LIGHT, PRIMARY_COLORS_DARK } from "@m4l/styles";
2
+ import { g as getTypographyStyles } from "../../utils/getTypographyStyles.js";
3
+ import { v as varFade } from "../animate/variants/fade.js";
4
+ import { g as getSizeStyles } from "../../utils/getSizeStyles/getSizeStyles.js";
5
+ const settingsLayoutStyles = {
6
+ /**
7
+ * Estilos css de la ranura root
8
+ */
9
+ root: ({ theme, ownerState }) => ({
10
+ top: 0,
11
+ right: 0,
12
+ bottom: 0,
13
+ transform: "unset!important",
14
+ padding: theme.vars.size.baseSpacings.sp6,
15
+ opacity: "1!important",
16
+ display: "flex",
17
+ position: "fixed",
18
+ width: ownerState?.width,
19
+ flexDirection: "column",
20
+ gap: theme.vars.size.baseSpacings.sp6,
21
+ boxShadow: theme.vars.customShadows?.z4,
22
+ overflowY: "auto",
23
+ zIndex: theme.zIndex.drawer + 3,
24
+ ...ownerState?.themeDirection === "ltr" && {
25
+ borderTopLeftRadius: theme.vars.size.borderRadius.r3,
26
+ borderBottomLeftRadius: theme.vars.size.borderRadius.r3
27
+ },
28
+ ...ownerState?.themeDirection === "rtl" && {
29
+ borderTopRightRadius: theme.vars.size.borderRadius.r3,
30
+ borderBottomRightRadius: theme.vars.size.borderRadius.r3
31
+ },
32
+ border: theme.vars.size.borderStroke.container,
33
+ borderColor: theme.vars.palette.border.secondary,
34
+ backgroundColor: theme.vars.palette.background.base,
35
+ ...ownerState?.themeDirection !== "rtl" ? varFade({
36
+ distance: ownerState?.width,
37
+ durationIn: 0.32,
38
+ durationOut: 0.32
39
+ }).inRight : varFade({
40
+ distance: ownerState?.width,
41
+ durationIn: 0.32,
42
+ durationOut: 0.32
43
+ }).inLeft
44
+ }),
45
+ /**
46
+ * Estilos css de la ranura backdrop
47
+ */
48
+ backdrop: ({ theme }) => ({
49
+ background: "transparent",
50
+ zIndex: theme.zIndex.drawer + 1,
51
+ transform: "unset",
52
+ opacity: 1
53
+ }),
54
+ /**
55
+ * Estilos css de la ranura header
56
+ */
57
+ headerContainer: () => ({
58
+ width: "100%",
59
+ display: "flex",
60
+ flexDirection: "row",
61
+ alignItems: "center",
62
+ justifyContent: "space-between"
63
+ }),
64
+ /**
65
+ * Estilos css de la ranura headerActions
66
+ */
67
+ headerActions: ({ theme }) => ({
68
+ display: "flex",
69
+ flexDirection: "row",
70
+ width: "fit-content",
71
+ alignItems: "center",
72
+ padding: theme.vars.size.baseSpacings["sp0-5"],
73
+ gap: theme.vars.size.baseSpacings["sp0-5"],
74
+ borderRadius: theme.vars.size.borderRadius.r2,
75
+ border: theme.vars.size.borderStroke.container,
76
+ borderColor: theme.vars.palette.border.disabled,
77
+ backgroundColor: theme.vars.palette.background.default
78
+ }),
79
+ /**
80
+ * Estilos css de la ranura content
81
+ */
82
+ bodyContent: ({ theme }) => ({
83
+ display: "flex",
84
+ flexDirection: "column",
85
+ position: "relative",
86
+ overflowY: "auto",
87
+ width: "100%",
88
+ gap: theme.vars.size.baseSpacings.sp6
89
+ }),
90
+ /**
91
+ * Estilos css de la ranura settingContainer
92
+ */
93
+ settingContainer: ({ theme }) => ({
94
+ display: "flex",
95
+ flexDirection: "column",
96
+ padding: theme.vars.size.baseSpacings.sp4,
97
+ gap: theme.vars.size.baseSpacings.sp4,
98
+ borderRadius: theme.vars.size.borderRadius.r2,
99
+ backgroundColor: theme.vars.palette.background.default
100
+ }),
101
+ /**
102
+ * Estilos css de la ranura settingIconTitle
103
+ */
104
+ settingIconTitle: ({ theme }) => ({
105
+ display: "flex",
106
+ flexDirection: "row",
107
+ gap: theme.vars.size.baseSpacings["sp2-5"],
108
+ justifyContent: "flex-start",
109
+ alignItems: "center"
110
+ }),
111
+ /**
112
+ * Estilos css de la ranura settingItemContent
113
+ */
114
+ settingItemContent: ({ theme }) => ({
115
+ display: "flex",
116
+ flexDirection: "row",
117
+ gap: theme.vars.size.baseSpacings.sp4,
118
+ justifyContent: "space-between"
119
+ }),
120
+ /**
121
+ * Estilos css de la ranura settingItem
122
+ */
123
+ settingItem: ({ theme, ownerState }) => ({
124
+ display: "flex",
125
+ flexDirection: "row",
126
+ justifyContent: "center",
127
+ alignItems: "center",
128
+ width: "100%",
129
+ height: "100%",
130
+ borderRadius: theme.vars.size.borderRadius.r2,
131
+ border: theme.vars.size.borderStroke.container,
132
+ borderColor: theme.vars.palette.border.disabled,
133
+ padding: theme.vars.size.baseSpacings.sp2,
134
+ outline: "unset",
135
+ "& .M4LIcon-root": {
136
+ width: theme.vars.size.baseSpacings.sp5,
137
+ height: theme.vars.size.baseSpacings.sp5
138
+ },
139
+ ...ownerState?.onChange ? {
140
+ transition: "all 0.3s ease",
141
+ cursor: "pointer",
142
+ "&:hover": {
143
+ backgroundColor: theme.vars.palette.default.hoverOpacity
144
+ },
145
+ "&:active": {
146
+ backgroundColor: theme.vars.palette.default.activeOpacity
147
+ },
148
+ "&:focus-visible": {
149
+ borderColor: theme.vars.palette.border.main,
150
+ boxShadow: theme.vars.customShadows?.primary
151
+ },
152
+ ...ownerState?.selected ? {
153
+ borderColor: theme.vars.palette.border.main,
154
+ backgroundColor: theme.vars.palette.primary.enabledOpacity,
155
+ "&:hover": {
156
+ backgroundColor: theme.vars.palette.primary.hoverOpacity
157
+ },
158
+ "&:active": {
159
+ backgroundColor: theme.vars.palette.primary.activeOpacity
160
+ }
161
+ } : {}
162
+ } : {}
163
+ }),
164
+ /**
165
+ * Estilos css de la ranura settingItemColorContainer
166
+ */
167
+ settingItemColorContainer: () => ({
168
+ display: "flex",
169
+ flexDirection: "row",
170
+ width: "auto",
171
+ height: "auto",
172
+ position: "relative"
173
+ }),
174
+ /**
175
+ * Estilos css de la ranura settingItemColor
176
+ */
177
+ settingItemColor: ({ theme, ownerState }) => {
178
+ const presetColor = ownerState?.color ?? "patronus";
179
+ const presetPalette = ownerState?.mode === "light" ? PRIMARY_COLORS_LIGHT[presetColor] : PRIMARY_COLORS_DARK[presetColor];
180
+ return {
181
+ ...getSizeStyles(
182
+ theme,
183
+ ownerState?.size || "medium",
184
+ "box",
185
+ (size) => ({
186
+ width: size,
187
+ height: size
188
+ })
189
+ ),
190
+ "&:focus-visible": {
191
+ borderColor: theme.vars.palette.border.main,
192
+ boxShadow: theme.vars.customShadows?.primary,
193
+ "&:after": {
194
+ content: '""',
195
+ position: "absolute",
196
+ inset: "-4px",
197
+ borderRadius: "40% / 45%",
198
+ boxShadow: `0 0 0 1px ${presetPalette.focus}`,
199
+ zIndex: 1
200
+ }
201
+ },
202
+ ...ownerState?.selected ? {
203
+ "&:before": {
204
+ content: '""',
205
+ position: "absolute",
206
+ inset: "0",
207
+ borderRadius: theme.vars.size.borderRadius.r3,
208
+ boxShadow: `0 0 0 1px ${presetPalette.enabled}`,
209
+ backgroundColor: presetPalette.enabledOpacity,
210
+ zIndex: 1
211
+ }
212
+ } : {},
213
+ "& .M4LIcon-icon": {
214
+ display: "flex",
215
+ flexDirection: "row",
216
+ backgroundColor: presetPalette.enabled,
217
+ outline: "unset",
218
+ position: "relative",
219
+ overflow: "visible",
220
+ transition: "all 0.3s ease",
221
+ ...ownerState?.onChange ? {
222
+ cursor: "pointer",
223
+ transition: "all 0.3s ease",
224
+ "&:hover": {
225
+ backgroundColor: presetPalette.hover
226
+ },
227
+ "&:active": {
228
+ backgroundColor: presetPalette.active
229
+ }
230
+ } : {}
231
+ }
232
+ };
233
+ },
234
+ /**
235
+ * Estilos css de la ranura settingFullscreen
236
+ */
237
+ settingFullscreen: ({ theme, ownerState }) => ({
238
+ /* borderRadius: theme.vars.size.borderRadius['r1-5'],
239
+ border: 'unset',
240
+ outline: 'unset', */
241
+ display: "flex",
242
+ flexDirection: "row",
243
+ alignItems: "center",
244
+ justifyContent: "center",
245
+ borderRadius: theme.vars.size.borderRadius["r1-5"],
246
+ "& .MuiTypography-root": {
247
+ width: "fit-content",
248
+ ...getTypographyStyles(
249
+ theme.generalSettings.isMobile,
250
+ ownerState?.size || "medium",
251
+ "bodyDens"
252
+ )
253
+ }
254
+ }),
255
+ /**
256
+ * Estilos css de la ranura icon
257
+ */
258
+ icon: {},
259
+ /**
260
+ * Estilos css de la ranura typography
261
+ */
262
+ typography: {},
263
+ /**
264
+ * Estilos css de la ranura divider
265
+ */
266
+ divider: {}
267
+ };
268
+ export {
269
+ settingsLayoutStyles as s
270
+ };
@@ -0,0 +1,7 @@
1
+ import { SettingsLayoutSlots } from './slots/SettingsLayoutEnum';
2
+ /**
3
+ * Nombre de clase del componente.
4
+ */
5
+ export declare const SETTINGS_LAYOUT_COMPONENT_KEY = "M4LSettingsLayout";
6
+ export declare const SETTINGS_LAYOUT_CLASSES: Record<keyof typeof SettingsLayoutSlots, string>;
7
+ export declare const SETTINGS_LAYOUT_DEFAULT_WIDTH = 300;
@@ -0,0 +1,10 @@
1
+ import { g as getComponentClasses } from "../../utils/getComponentSlotRoot.js";
2
+ import { S as SettingsLayoutSlots } from "./slots/SettingsLayoutEnum.js";
3
+ const SETTINGS_LAYOUT_COMPONENT_KEY = "M4LSettingsLayout";
4
+ const SETTINGS_LAYOUT_CLASSES = getComponentClasses(SETTINGS_LAYOUT_COMPONENT_KEY, SettingsLayoutSlots);
5
+ const SETTINGS_LAYOUT_DEFAULT_WIDTH = 300;
6
+ export {
7
+ SETTINGS_LAYOUT_DEFAULT_WIDTH as S,
8
+ SETTINGS_LAYOUT_COMPONENT_KEY as a,
9
+ SETTINGS_LAYOUT_CLASSES as b
10
+ };
@@ -0,0 +1,8 @@
1
+ export declare const DICTIONARY: {
2
+ MODE: string;
3
+ DIRECTION: string;
4
+ PRESETS: string;
5
+ EXIT_FULLSCREEN: string;
6
+ FULLSCREEN: string;
7
+ MODULE_NAME: string;
8
+ };
@@ -0,0 +1,11 @@
1
+ const DICTIONARY = {
2
+ MODE: "mode",
3
+ DIRECTION: "direction",
4
+ PRESETS: "presets",
5
+ EXIT_FULLSCREEN: "exit_fullscreen",
6
+ FULLSCREEN: "fullscreen",
7
+ MODULE_NAME: "module_name"
8
+ };
9
+ export {
10
+ DICTIONARY as D
11
+ };
@@ -0,0 +1,14 @@
1
+ export declare const PATH_ICONS: {
2
+ REFRESH: string;
3
+ CLOSE: string;
4
+ MOON: string;
5
+ SUN: string;
6
+ MODE: string;
7
+ PALETTE: string;
8
+ DIRECTION: string;
9
+ ALIGN_LEFT: string;
10
+ ALIGN_RIGHT: string;
11
+ FULLSCREEN: string;
12
+ FULLSCREEN_EXIT: string;
13
+ COLOR: string;
14
+ };
@@ -0,0 +1,17 @@
1
+ const PATH_ICONS = {
2
+ REFRESH: "frontend/components/setting_layout/assets/icons/refresh.svg",
3
+ CLOSE: "frontend/components/setting_layout/assets/icons/closeSmall.svg",
4
+ MOON: "frontend/components/setting_layout/assets/icons/CloudMoon.svg",
5
+ SUN: "frontend/components/setting_layout/assets/icons/Sun.svg",
6
+ MODE: "frontend/components/setting_layout/assets/icons/eclipse.svg",
7
+ PALETTE: "frontend/components/setting_layout/assets/icons/palette.svg",
8
+ DIRECTION: "frontend/components/setting_layout/assets/icons/signpost.svg",
9
+ ALIGN_LEFT: "frontend/components/setting_layout/assets/icons/align-start-vertical.svg",
10
+ ALIGN_RIGHT: "frontend/components/setting_layout/assets/icons/align-end-vertical.svg",
11
+ FULLSCREEN: "frontend/components/setting_layout/assets/icons/FrameCorners.svg",
12
+ FULLSCREEN_EXIT: "frontend/components/setting_layout/assets/icons/exit_fullscreen.svg",
13
+ COLOR: "frontend/components/setting_layout/assets/icons/color_preset.svg"
14
+ };
15
+ export {
16
+ PATH_ICONS as P
17
+ };
@@ -0,0 +1,2 @@
1
+ export { SettingsLayout } from './SettingsLayout';
2
+ export type { SettingsLayoutProps } from './types';
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,17 @@
1
+ export declare enum SettingsLayoutSlots {
2
+ root = "root",
3
+ backdrop = "backdrop",
4
+ icon = "icon",
5
+ typography = "typography",
6
+ divider = "divider",
7
+ headerContainer = "headerContainer",
8
+ headerActions = "headerActions",
9
+ bodyContent = "bodyContent",
10
+ settingContainer = "settingContainer",
11
+ settingIconTitle = "settingIconTitle",
12
+ settingItem = "settingItem",
13
+ settingItemColor = "settingItemColor",
14
+ settingItemColorContainer = "settingItemColorContainer",
15
+ settingItemContent = "settingItemContent",
16
+ settingFullscreen = "settingFullscreen"
17
+ }
@@ -0,0 +1,21 @@
1
+ var SettingsLayoutSlots = /* @__PURE__ */ ((SettingsLayoutSlots2) => {
2
+ SettingsLayoutSlots2["root"] = "root";
3
+ SettingsLayoutSlots2["backdrop"] = "backdrop";
4
+ SettingsLayoutSlots2["icon"] = "icon";
5
+ SettingsLayoutSlots2["typography"] = "typography";
6
+ SettingsLayoutSlots2["divider"] = "divider";
7
+ SettingsLayoutSlots2["headerContainer"] = "headerContainer";
8
+ SettingsLayoutSlots2["headerActions"] = "headerActions";
9
+ SettingsLayoutSlots2["bodyContent"] = "bodyContent";
10
+ SettingsLayoutSlots2["settingContainer"] = "settingContainer";
11
+ SettingsLayoutSlots2["settingIconTitle"] = "settingIconTitle";
12
+ SettingsLayoutSlots2["settingItem"] = "settingItem";
13
+ SettingsLayoutSlots2["settingItemColor"] = "settingItemColor";
14
+ SettingsLayoutSlots2["settingItemColorContainer"] = "settingItemColorContainer";
15
+ SettingsLayoutSlots2["settingItemContent"] = "settingItemContent";
16
+ SettingsLayoutSlots2["settingFullscreen"] = "settingFullscreen";
17
+ return SettingsLayoutSlots2;
18
+ })(SettingsLayoutSlots || {});
19
+ export {
20
+ SettingsLayoutSlots as S
21
+ };