@m4l/components 9.4.12 → 9.4.13
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/SettingsLayout/SettingsLayout.js +4 -3
- package/components/SettingsLayout/constants.d.ts +1 -0
- package/components/SettingsLayout/constants.js +5 -3
- package/components/SettingsLayout/slots/SettingsLayoutSlots.js +1 -1
- package/components/SettingsLayout/subcomponents/SettingsLayoutBase/SettingsLayoutBase.js +1 -1
- package/components/SettingsLayout/types.d.ts +4 -0
- package/package.json +1 -1
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import { useEnvironment, FlagsProvider, ModuleDictionaryProvider, ModuleSkeletonProvider, CommonFlags } from "@m4l/core";
|
|
3
3
|
import { useLocales, useThemeSettingsStore } from "@m4l/graphics";
|
|
4
|
-
import { S as SETTINGS_LAYOUT_DEFAULT_WIDTH } from "./constants.js";
|
|
4
|
+
import { S as SETTINGS_LAYOUT_DEFAULT_MODULE_ID, a as SETTINGS_LAYOUT_DEFAULT_WIDTH } from "./constants.js";
|
|
5
5
|
import { useMemo } from "react";
|
|
6
6
|
import { S as SettingsLayoutBase } from "./subcomponents/SettingsLayoutBase/SettingsLayoutBase.js";
|
|
7
7
|
const SettingsLayout = (props) => {
|
|
8
8
|
const {
|
|
9
|
-
width = SETTINGS_LAYOUT_DEFAULT_WIDTH
|
|
9
|
+
width = SETTINGS_LAYOUT_DEFAULT_WIDTH,
|
|
10
|
+
moduleId = SETTINGS_LAYOUT_DEFAULT_MODULE_ID
|
|
10
11
|
} = props;
|
|
11
12
|
const currentLang = useLocales().currentLocale?.localeString;
|
|
12
13
|
const { host_static_assets, environment_assets } = useEnvironment();
|
|
@@ -22,7 +23,7 @@ const SettingsLayout = (props) => {
|
|
|
22
23
|
ModuleDictionaryProvider,
|
|
23
24
|
{
|
|
24
25
|
isAuth: false,
|
|
25
|
-
moduleId
|
|
26
|
+
moduleId,
|
|
26
27
|
componentsDictionary,
|
|
27
28
|
currentLang,
|
|
28
29
|
children: /* @__PURE__ */ jsx(ModuleSkeletonProvider, { flags: [CommonFlags.FLAG_DICTIONARY_LOADED], children: /* @__PURE__ */ jsx(SettingsLayoutBase, { prefixPathIcon, width }) })
|
|
@@ -5,3 +5,4 @@ import { SettingsLayoutSlots } from './slots/SettingsLayoutEnum';
|
|
|
5
5
|
export declare const SETTINGS_LAYOUT_COMPONENT_KEY = "M4LSettingsLayout";
|
|
6
6
|
export declare const SETTINGS_LAYOUT_CLASSES: Record<keyof typeof SettingsLayoutSlots, string>;
|
|
7
7
|
export declare const SETTINGS_LAYOUT_DEFAULT_WIDTH = 300;
|
|
8
|
+
export declare const SETTINGS_LAYOUT_DEFAULT_MODULE_ID = "theme_settings";
|
|
@@ -3,8 +3,10 @@ import { S as SettingsLayoutSlots } from "./slots/SettingsLayoutEnum.js";
|
|
|
3
3
|
const SETTINGS_LAYOUT_COMPONENT_KEY = "M4LSettingsLayout";
|
|
4
4
|
const SETTINGS_LAYOUT_CLASSES = getComponentClasses(SETTINGS_LAYOUT_COMPONENT_KEY, SettingsLayoutSlots);
|
|
5
5
|
const SETTINGS_LAYOUT_DEFAULT_WIDTH = 300;
|
|
6
|
+
const SETTINGS_LAYOUT_DEFAULT_MODULE_ID = "theme_settings";
|
|
6
7
|
export {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
SETTINGS_LAYOUT_DEFAULT_MODULE_ID as S,
|
|
9
|
+
SETTINGS_LAYOUT_DEFAULT_WIDTH as a,
|
|
10
|
+
SETTINGS_LAYOUT_COMPONENT_KEY as b,
|
|
11
|
+
SETTINGS_LAYOUT_CLASSES as c
|
|
10
12
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { styled } from "@mui/material/styles";
|
|
2
2
|
import { S as SettingsLayoutSlots } from "./SettingsLayoutEnum.js";
|
|
3
|
-
import {
|
|
3
|
+
import { b as SETTINGS_LAYOUT_COMPONENT_KEY } from "../constants.js";
|
|
4
4
|
import { s as settingsLayoutStyles } from "../SettingsLayout.styles.js";
|
|
5
5
|
import { Backdrop } from "@mui/material";
|
|
6
6
|
import { I as Icon } from "../../Icon/Icon.js";
|
|
@@ -6,7 +6,7 @@ import { B as BackdropStyled, g as SettingsLayoutRootStyled, H as HeaderContaine
|
|
|
6
6
|
import { S as SettingDirection } from "../SettingDirection/SettingDirection.js";
|
|
7
7
|
import { D as DICTIONARY } from "../../dictionary.js";
|
|
8
8
|
import { useThemeSettingsStore } from "@m4l/graphics";
|
|
9
|
-
import {
|
|
9
|
+
import { c as SETTINGS_LAYOUT_CLASSES } from "../../constants.js";
|
|
10
10
|
import { I as IconButton } from "../../../mui_extended/IconButton/IconButton.js";
|
|
11
11
|
import { S as SettingMode } from "../SettingMode/SettingMode.js";
|
|
12
12
|
import { S as SettingColorPresets } from "../SettingColorPresets/SettingColorPresets.js";
|