datastake-daf 0.6.528 → 0.6.530
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/dist/layouts/index.js +26 -15
- package/package.json +1 -1
- package/src/@daf/layouts/AppLayout/index.jsx +26 -15
- package/src/constants/theme.js +1 -0
package/dist/layouts/index.js
CHANGED
|
@@ -7074,22 +7074,33 @@ function AppLayout({
|
|
|
7074
7074
|
});
|
|
7075
7075
|
};
|
|
7076
7076
|
|
|
7077
|
-
// Apply theme CSS custom properties
|
|
7078
|
-
|
|
7079
|
-
|
|
7080
|
-
|
|
7081
|
-
|
|
7082
|
-
|
|
7083
|
-
|
|
7084
|
-
'--layout-
|
|
7085
|
-
|
|
7086
|
-
|
|
7087
|
-
|
|
7088
|
-
|
|
7089
|
-
|
|
7090
|
-
|
|
7077
|
+
// Apply theme CSS custom properties to document root
|
|
7078
|
+
o.useEffect(() => {
|
|
7079
|
+
if (theme.layoutPrimaryBg) document.documentElement.style.setProperty('--layout-primary-bg', theme.layoutPrimaryBg);
|
|
7080
|
+
if (theme.layoutSecondaryBg) document.documentElement.style.setProperty('--layout-secondary-bg', theme.layoutSecondaryBg);
|
|
7081
|
+
if (theme.layoutBorderColor) document.documentElement.style.setProperty('--layout-border-color', theme.layoutBorderColor);
|
|
7082
|
+
if (theme.layoutTextPrimary) document.documentElement.style.setProperty('--layout-text-primary', theme.layoutTextPrimary);
|
|
7083
|
+
if (theme.layoutTextSecondary) document.documentElement.style.setProperty('--layout-text-secondary', theme.layoutTextSecondary);
|
|
7084
|
+
if (theme.layoutHoverBg) document.documentElement.style.setProperty('--layout-hover-bg', theme.layoutHoverBg);
|
|
7085
|
+
|
|
7086
|
+
// Cleanup on unmount
|
|
7087
|
+
return () => {
|
|
7088
|
+
document.documentElement.style.removeProperty('--layout-primary-bg');
|
|
7089
|
+
document.documentElement.style.removeProperty('--layout-secondary-bg');
|
|
7090
|
+
document.documentElement.style.removeProperty('--layout-border-color');
|
|
7091
|
+
document.documentElement.style.removeProperty('--layout-text-primary');
|
|
7092
|
+
document.documentElement.style.removeProperty('--layout-text-secondary');
|
|
7093
|
+
document.documentElement.style.removeProperty('--layout-hover-bg');
|
|
7094
|
+
};
|
|
7095
|
+
}, [theme]);
|
|
7091
7096
|
return /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
7092
|
-
style:
|
|
7097
|
+
style: {
|
|
7098
|
+
display: 'flex',
|
|
7099
|
+
flexDirection: 'row',
|
|
7100
|
+
width: '100vw',
|
|
7101
|
+
height: '100dvh',
|
|
7102
|
+
maxHeight: '100dvh'
|
|
7103
|
+
},
|
|
7093
7104
|
className: "components-layout",
|
|
7094
7105
|
children: [!isAppNavigation ? /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
7095
7106
|
className: formatClassname([isCollapsed ? 'sidenav-sider-collapsed sidenav-sider desktop-sider' : 'sidenav-sider sidenav-sider-opened desktop-sider', appName]),
|
package/package.json
CHANGED
|
@@ -218,24 +218,35 @@ function AppLayout({
|
|
|
218
218
|
changeNotificationState({ onYes: () => goTo(getRedirectLink('/app')) });
|
|
219
219
|
};
|
|
220
220
|
|
|
221
|
-
// Apply theme CSS custom properties
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
'--layout-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
221
|
+
// Apply theme CSS custom properties to document root
|
|
222
|
+
useEffect(() => {
|
|
223
|
+
if (theme.layoutPrimaryBg) document.documentElement.style.setProperty('--layout-primary-bg', theme.layoutPrimaryBg);
|
|
224
|
+
if (theme.layoutSecondaryBg) document.documentElement.style.setProperty('--layout-secondary-bg', theme.layoutSecondaryBg);
|
|
225
|
+
if (theme.layoutBorderColor) document.documentElement.style.setProperty('--layout-border-color', theme.layoutBorderColor);
|
|
226
|
+
if (theme.layoutTextPrimary) document.documentElement.style.setProperty('--layout-text-primary', theme.layoutTextPrimary);
|
|
227
|
+
if (theme.layoutTextSecondary) document.documentElement.style.setProperty('--layout-text-secondary', theme.layoutTextSecondary);
|
|
228
|
+
if (theme.layoutHoverBg) document.documentElement.style.setProperty('--layout-hover-bg', theme.layoutHoverBg);
|
|
229
|
+
|
|
230
|
+
// Cleanup on unmount
|
|
231
|
+
return () => {
|
|
232
|
+
document.documentElement.style.removeProperty('--layout-primary-bg');
|
|
233
|
+
document.documentElement.style.removeProperty('--layout-secondary-bg');
|
|
234
|
+
document.documentElement.style.removeProperty('--layout-border-color');
|
|
235
|
+
document.documentElement.style.removeProperty('--layout-text-primary');
|
|
236
|
+
document.documentElement.style.removeProperty('--layout-text-secondary');
|
|
237
|
+
document.documentElement.style.removeProperty('--layout-hover-bg');
|
|
238
|
+
};
|
|
239
|
+
}, [theme]);
|
|
235
240
|
|
|
236
241
|
return (
|
|
237
242
|
<div
|
|
238
|
-
style={
|
|
243
|
+
style={{
|
|
244
|
+
display: 'flex',
|
|
245
|
+
flexDirection: 'row',
|
|
246
|
+
width: '100vw',
|
|
247
|
+
height: '100dvh',
|
|
248
|
+
maxHeight: '100dvh'
|
|
249
|
+
}}
|
|
239
250
|
className="components-layout"
|
|
240
251
|
>
|
|
241
252
|
{!isAppNavigation ? (
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|