@admin-layout/tailwind-design-pro 12.0.16-alpha.9 → 12.0.16-alpha.91
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/lib/cdm-locales/en/menu.json +2 -1
- package/lib/cdm-locales/es/menu.json +2 -1
- package/lib/cdm-locales/index.d.ts +2 -0
- package/lib/cdm-locales/index.d.ts.map +1 -0
- package/lib/cdm-locales/index.ts +1 -0
- package/lib/components/LanguageMenu/LanguageMenu.d.ts.map +1 -1
- package/lib/components/LanguageMenu/LanguageMenu.js +16 -20
- package/lib/components/LanguageMenu/LanguageMenu.js.map +1 -1
- package/lib/components/Layout/BasicLayout/index.d.ts +6 -5
- package/lib/components/Layout/BasicLayout/index.d.ts.map +1 -1
- package/lib/components/Layout/BasicLayout/index.js +220 -124
- package/lib/components/Layout/BasicLayout/index.js.map +1 -1
- package/lib/components/Layout/BasicLayout/utils.d.ts +2 -0
- package/lib/components/Layout/BasicLayout/utils.d.ts.map +1 -1
- package/lib/components/Layout/BasicLayout/utils.js +16 -13
- package/lib/components/Layout/BasicLayout/utils.js.map +1 -1
- package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.d.ts.map +1 -1
- package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.js +9 -14
- package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/Header.d.ts +0 -1
- package/lib/components/Layout/GlobalHeader/Header.d.ts.map +1 -1
- package/lib/components/Layout/GlobalHeader/Header.js +38 -10
- package/lib/components/Layout/GlobalHeader/Header.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/MainHeader.d.ts +0 -2
- package/lib/components/Layout/GlobalHeader/MainHeader.d.ts.map +1 -1
- package/lib/components/Layout/GlobalHeader/MainHeader.js +54 -85
- package/lib/components/Layout/GlobalHeader/MainHeader.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/OrganizationDropdown.js +1 -1
- package/lib/components/Layout/GlobalHeader/OrganizationDropdown.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/RightContent.d.ts +1 -0
- package/lib/components/Layout/GlobalHeader/RightContent.d.ts.map +1 -1
- package/lib/components/Layout/GlobalHeader/RightContent.js +73 -6
- package/lib/components/Layout/GlobalHeader/RightContent.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/RightMenu.d.ts.map +1 -1
- package/lib/components/Layout/GlobalHeader/RightMenu.js +2 -4
- package/lib/components/Layout/GlobalHeader/RightMenu.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/SearchBar.js.map +1 -1
- package/lib/components/Layout/GlobalHeader/index.d.ts +0 -1
- package/lib/components/Layout/GlobalHeader/index.d.ts.map +1 -1
- package/lib/components/Layout/ProTailwindLayout.d.ts +2 -2
- package/lib/components/Layout/ProTailwindLayout.d.ts.map +1 -1
- package/lib/components/Layout/ProTailwindLayout.js +69 -7
- package/lib/components/Layout/ProTailwindLayout.js.map +1 -1
- package/lib/components/Layout/Sidebar/BottomMenu.d.ts +4 -0
- package/lib/components/Layout/Sidebar/BottomMenu.d.ts.map +1 -0
- package/lib/components/Layout/Sidebar/BottomMenu.js +330 -0
- package/lib/components/Layout/Sidebar/BottomMenu.js.map +1 -0
- package/lib/components/Layout/Sidebar/Divider.js.map +1 -1
- package/lib/components/Layout/Sidebar/DynamicIcon.js.map +1 -1
- package/lib/components/Layout/Sidebar/MainSidebar.d.ts +5 -0
- package/lib/components/Layout/Sidebar/MainSidebar.d.ts.map +1 -0
- package/lib/components/Layout/Sidebar/MainSidebar.js +246 -0
- package/lib/components/Layout/Sidebar/MainSidebar.js.map +1 -0
- package/lib/components/Layout/Sidebar/MainSidebarMenu.d.ts +6 -0
- package/lib/components/Layout/Sidebar/MainSidebarMenu.d.ts.map +1 -0
- package/lib/components/Layout/Sidebar/MainSidebarMenu.js +467 -0
- package/lib/components/Layout/Sidebar/MainSidebarMenu.js.map +1 -0
- package/lib/components/Layout/Sidebar/PerplexSidebar.d.ts +4 -0
- package/lib/components/Layout/Sidebar/PerplexSidebar.d.ts.map +1 -0
- package/lib/components/Layout/Sidebar/PerplexSidebar.js +279 -0
- package/lib/components/Layout/Sidebar/PerplexSidebar.js.map +1 -0
- package/lib/components/Layout/Sidebar/PerplexSidebarMenu.d.ts +4 -0
- package/lib/components/Layout/Sidebar/PerplexSidebarMenu.d.ts.map +1 -0
- package/lib/components/Layout/Sidebar/PerplexSidebarMenu.js +332 -0
- package/lib/components/Layout/Sidebar/PerplexSidebarMenu.js.map +1 -0
- package/lib/components/Layout/TailwindLayout.d.ts.map +1 -1
- package/lib/components/Layout/TailwindLayout.js +29 -10
- package/lib/components/Layout/TailwindLayout.js.map +1 -1
- package/lib/components/Layout/getPageTitle.js.map +1 -1
- package/lib/components/Layout/slot-fill/AdditionalSettings.js.map +1 -1
- package/lib/components/Layout/slot-fill/Footer.js.map +1 -1
- package/lib/components/Layout/slot-fill/HeaderNotice.js +7 -0
- package/lib/components/Layout/slot-fill/HeaderNotice.js.map +1 -0
- package/lib/components/Layout/slot-fill/HeaderSearchBar.js.map +1 -1
- package/lib/components/Layout/slot-fill/HeaderSearchButton.js.map +1 -1
- package/lib/components/Layout/slot-fill/Logo.d.ts +4 -0
- package/lib/components/Layout/slot-fill/Logo.d.ts.map +1 -0
- package/lib/components/Layout/slot-fill/Logo.js +7 -0
- package/lib/components/Layout/slot-fill/Logo.js.map +1 -0
- package/lib/components/Layout/slot-fill/RightContent.js.map +1 -1
- package/lib/components/Layout/slot-fill/SideMenuLogo.d.ts +4 -0
- package/lib/components/Layout/slot-fill/SideMenuLogo.d.ts.map +1 -0
- package/lib/components/Layout/slot-fill/SideMenuLogo.js +7 -0
- package/lib/components/Layout/slot-fill/SideMenuLogo.js.map +1 -0
- package/lib/components/Layout/slot-fill/index.d.ts +2 -0
- package/lib/components/Layout/slot-fill/index.d.ts.map +1 -1
- package/lib/components/Layout/util.js +1 -1
- package/lib/components/Layout/util.js.map +1 -1
- package/lib/components/SettingDrawer/SettingDrawer.d.ts +2 -3
- package/lib/components/SettingDrawer/SettingDrawer.d.ts.map +1 -1
- package/lib/components/SettingDrawer/SettingDrawer.js +166 -416
- package/lib/components/SettingDrawer/SettingDrawer.js.map +1 -1
- package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.d.ts +7 -0
- package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.js +30 -0
- package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.js.map +1 -0
- package/lib/components/SettingDrawer/components/CheckBoxTheme.d.ts +3 -0
- package/lib/components/SettingDrawer/components/CheckBoxTheme.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{CheckBoxTheme.js → components/CheckBoxTheme.js} +14 -5
- package/lib/components/SettingDrawer/components/CheckBoxTheme.js.map +1 -0
- package/lib/components/SettingDrawer/components/DeviceTabs.d.ts +7 -0
- package/lib/components/SettingDrawer/components/DeviceTabs.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/DeviceTabs.js +82 -0
- package/lib/components/SettingDrawer/components/DeviceTabs.js.map +1 -0
- package/lib/components/SettingDrawer/components/InvitationSettings.d.ts +3 -0
- package/lib/components/SettingDrawer/components/InvitationSettings.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{InvitationSettings.js → components/InvitationSettings.js} +11 -7
- package/lib/components/SettingDrawer/components/InvitationSettings.js.map +1 -0
- package/lib/components/SettingDrawer/components/LayoutChange.d.ts +3 -0
- package/lib/components/SettingDrawer/components/LayoutChange.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{LayoutChange.js → components/LayoutChange.js} +24 -17
- package/lib/components/SettingDrawer/components/LayoutChange.js.map +1 -0
- package/lib/components/SettingDrawer/components/MenuVisibilitySettings.d.ts +20 -0
- package/lib/components/SettingDrawer/components/MenuVisibilitySettings.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/MenuVisibilitySettings.js +119 -0
- package/lib/components/SettingDrawer/components/MenuVisibilitySettings.js.map +1 -0
- package/lib/components/SettingDrawer/components/NavigationsModes.d.ts +3 -0
- package/lib/components/SettingDrawer/components/NavigationsModes.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{NavigationsModes.js → components/NavigationsModes.js} +91 -40
- package/lib/components/SettingDrawer/components/NavigationsModes.js.map +1 -0
- package/lib/components/SettingDrawer/components/RegionalSettings.d.ts +3 -0
- package/lib/components/SettingDrawer/components/RegionalSettings.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{RegionalSettings.js → components/RegionalSettings.js} +55 -178
- package/lib/components/SettingDrawer/components/RegionalSettings.js.map +1 -0
- package/lib/components/SettingDrawer/components/SettingsActions.d.ts +12 -0
- package/lib/components/SettingDrawer/components/SettingsActions.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/SettingsActions.js +69 -0
- package/lib/components/SettingDrawer/components/SettingsActions.js.map +1 -0
- package/lib/components/SettingDrawer/components/SettingsDrawerHeader.d.ts +4 -0
- package/lib/components/SettingDrawer/components/SettingsDrawerHeader.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/SettingsDrawerHeader.js +25 -0
- package/lib/components/SettingDrawer/components/SettingsDrawerHeader.js.map +1 -0
- package/lib/components/SettingDrawer/{Switch/index.d.ts → components/Switch.d.ts} +2 -2
- package/lib/components/SettingDrawer/components/Switch.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{Switch/index.js → components/Switch.js} +1 -1
- package/lib/components/SettingDrawer/components/Switch.js.map +1 -0
- package/lib/components/SettingDrawer/components/ThemeColor.d.ts +3 -0
- package/lib/components/SettingDrawer/components/ThemeColor.d.ts.map +1 -0
- package/lib/components/SettingDrawer/{ThemeColor.js → components/ThemeColor.js} +16 -4
- package/lib/components/SettingDrawer/components/ThemeColor.js.map +1 -0
- package/lib/components/SettingDrawer/{ThemeSelector.d.ts → components/ThemeSelector.d.ts} +1 -1
- package/lib/components/SettingDrawer/components/ThemeSelector.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/ThemeSelector.js.map +1 -0
- package/lib/components/SettingDrawer/components/WebFontsSelector.d.ts +3 -0
- package/lib/components/SettingDrawer/components/WebFontsSelector.d.ts.map +1 -0
- package/lib/components/SettingDrawer/components/WebFontsSelector.js.map +1 -0
- package/lib/components/SettingDrawer/hooks/useSettingsOperations.d.ts +18 -0
- package/lib/components/SettingDrawer/hooks/useSettingsOperations.d.ts.map +1 -0
- package/lib/components/SettingDrawer/hooks/useSettingsOperations.js +119 -0
- package/lib/components/SettingDrawer/hooks/useSettingsOperations.js.map +1 -0
- package/lib/components/SettingDrawer/utils/constants.d.ts +11 -0
- package/lib/components/SettingDrawer/utils/constants.d.ts.map +1 -0
- package/lib/components/SettingDrawer/utils/constants.js +77 -0
- package/lib/components/SettingDrawer/utils/constants.js.map +1 -0
- package/lib/components/SettingDrawer/utils/helper.d.ts +37 -0
- package/lib/components/SettingDrawer/utils/helper.d.ts.map +1 -0
- package/lib/components/SettingDrawer/utils/helper.js +243 -0
- package/lib/components/SettingDrawer/utils/helper.js.map +1 -0
- package/lib/components/SettingDrawer/utils/transformers.d.ts +15 -0
- package/lib/components/SettingDrawer/utils/transformers.d.ts.map +1 -0
- package/lib/components/SettingDrawer/utils/transformers.js +76 -0
- package/lib/components/SettingDrawer/utils/transformers.js.map +1 -0
- package/lib/components/SettingDrawer/{types.d.ts → utils/types.d.ts} +14 -0
- package/lib/components/SettingDrawer/utils/types.d.ts.map +1 -0
- package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.d.ts +10 -5
- package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.d.ts.map +1 -1
- package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.js +97 -4
- package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.js.map +1 -1
- package/lib/components/index.js +1 -1
- package/lib/components/typings.d.ts +20 -1
- package/lib/components/typings.d.ts.map +1 -1
- package/lib/compute.d.ts.map +1 -1
- package/lib/compute.js +10 -2
- package/lib/compute.js.map +1 -1
- package/lib/config/constants.js.map +1 -1
- package/lib/config/env-config.d.ts +3 -0
- package/lib/config/env-config.d.ts.map +1 -1
- package/lib/config/env-config.js +10 -0
- package/lib/config/env-config.js.map +1 -1
- package/lib/helpers/DynamicIcon.js.map +1 -1
- package/lib/hooks/useMediaQuery.js.map +1 -1
- package/lib/hooks/useScrollThreshold.js.map +1 -1
- package/lib/hooks/useTailwindTheme.js +82 -0
- package/lib/hooks/useTailwindTheme.js.map +1 -0
- package/lib/icons.d.ts +2 -0
- package/lib/icons.d.ts.map +1 -1
- package/lib/icons.js +4 -2
- package/lib/icons.js.map +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/machines/selectors.d.ts +118 -0
- package/lib/machines/selectors.d.ts.map +1 -0
- package/lib/machines/settingsMachine.d.ts +25 -2
- package/lib/machines/settingsMachine.d.ts.map +1 -1
- package/lib/machines/settingsMachine.js +139 -168
- package/lib/machines/settingsMachine.js.map +1 -1
- package/lib/machines/settingsMachine.test.d.ts +2 -0
- package/lib/machines/settingsMachine.test.d.ts.map +1 -0
- package/lib/machines/types.d.ts +107 -9
- package/lib/machines/types.d.ts.map +1 -1
- package/lib/machines/types.js.map +1 -1
- package/lib/module.js.map +1 -1
- package/lib/redux/searchReducer.js.map +1 -1
- package/lib/routes.json +9 -1
- package/lib/tailwindConfig.js.map +1 -1
- package/lib/utils/__tests__/configOverrides.test.d.ts +2 -0
- package/lib/utils/__tests__/configOverrides.test.d.ts.map +1 -0
- package/lib/utils/configOverrides.d.ts +213 -0
- package/lib/utils/configOverrides.d.ts.map +1 -0
- package/lib/utils/configOverrides.js +91 -0
- package/lib/utils/configOverrides.js.map +1 -0
- package/lib/utils/isBrowser/index.js.map +1 -1
- package/lib/utils/settingsUtils.d.ts +20 -0
- package/lib/utils/settingsUtils.d.ts.map +1 -0
- package/lib/utils/settingsUtils.js +74 -0
- package/lib/utils/settingsUtils.js.map +1 -0
- package/lib/utils/utils/index.js.map +1 -1
- package/package.json +6 -6
- package/lib/components/Layout/GlobalHeader/Logo.d.ts +0 -4
- package/lib/components/Layout/GlobalHeader/Logo.d.ts.map +0 -1
- package/lib/components/Layout/GlobalHeader/Logo.js +0 -141
- package/lib/components/Layout/GlobalHeader/Logo.js.map +0 -1
- package/lib/components/Layout/Sidebar/Sidebar.d.ts +0 -5
- package/lib/components/Layout/Sidebar/Sidebar.d.ts.map +0 -1
- package/lib/components/Layout/Sidebar/Sidebar.js +0 -180
- package/lib/components/Layout/Sidebar/Sidebar.js.map +0 -1
- package/lib/components/Layout/Sidebar/SidebarMenu.d.ts +0 -4
- package/lib/components/Layout/Sidebar/SidebarMenu.d.ts.map +0 -1
- package/lib/components/Layout/Sidebar/SidebarMenu.js +0 -176
- package/lib/components/Layout/Sidebar/SidebarMenu.js.map +0 -1
- package/lib/components/SettingDrawer/CheckBoxTheme.d.ts +0 -3
- package/lib/components/SettingDrawer/CheckBoxTheme.d.ts.map +0 -1
- package/lib/components/SettingDrawer/CheckBoxTheme.js.map +0 -1
- package/lib/components/SettingDrawer/InvitationSettings.d.ts +0 -3
- package/lib/components/SettingDrawer/InvitationSettings.d.ts.map +0 -1
- package/lib/components/SettingDrawer/InvitationSettings.js.map +0 -1
- package/lib/components/SettingDrawer/LayoutChange.d.ts +0 -3
- package/lib/components/SettingDrawer/LayoutChange.d.ts.map +0 -1
- package/lib/components/SettingDrawer/LayoutChange.js.map +0 -1
- package/lib/components/SettingDrawer/NavigationsModes.d.ts +0 -3
- package/lib/components/SettingDrawer/NavigationsModes.d.ts.map +0 -1
- package/lib/components/SettingDrawer/NavigationsModes.js.map +0 -1
- package/lib/components/SettingDrawer/RegionalSettings.d.ts +0 -3
- package/lib/components/SettingDrawer/RegionalSettings.d.ts.map +0 -1
- package/lib/components/SettingDrawer/RegionalSettings.js.map +0 -1
- package/lib/components/SettingDrawer/Switch/index.d.ts.map +0 -1
- package/lib/components/SettingDrawer/Switch/index.js.map +0 -1
- package/lib/components/SettingDrawer/ThemeColor.d.ts +0 -3
- package/lib/components/SettingDrawer/ThemeColor.d.ts.map +0 -1
- package/lib/components/SettingDrawer/ThemeColor.js.map +0 -1
- package/lib/components/SettingDrawer/ThemeSelector.d.ts.map +0 -1
- package/lib/components/SettingDrawer/ThemeSelector.js.map +0 -1
- package/lib/components/SettingDrawer/WebFontsSelector.d.ts +0 -3
- package/lib/components/SettingDrawer/WebFontsSelector.d.ts.map +0 -1
- package/lib/components/SettingDrawer/WebFontsSelector.js.map +0 -1
- package/lib/components/SettingDrawer/types.d.ts.map +0 -1
- /package/lib/components/SettingDrawer/{ThemeSelector.js → components/ThemeSelector.js} +0 -0
- /package/lib/components/SettingDrawer/{WebFontsSelector.js → components/WebFontsSelector.js} +0 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transform changed settings to wrap in uilayout structure for backend API
|
|
3
|
+
* Converts keys like "[desktop].theme" to "[desktop].uilayout.theme"
|
|
4
|
+
*/
|
|
5
|
+
export declare function transformSettingsForBackend(changedSettings: Record<string, any>): Record<string, any>;
|
|
6
|
+
/**
|
|
7
|
+
* Extract and parse settings from browser cookies
|
|
8
|
+
* Returns null if cookie not found or parsing fails
|
|
9
|
+
*/
|
|
10
|
+
export declare function getCookieSettings(): Record<string, any> | null;
|
|
11
|
+
/**
|
|
12
|
+
* Clear settings cookies by sending DELETE request to server
|
|
13
|
+
*/
|
|
14
|
+
export declare function clearSettingsCookies(): Promise<boolean>;
|
|
15
|
+
//# sourceMappingURL=transformers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transformers.d.ts","sourceRoot":"","sources":["../../../../src/components/SettingDrawer/utils/transformers.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,wBAAgB,2BAA2B,CAAC,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAmCrG;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,IAAI,CAqB9D;AAED;;GAEG;AACH,wBAAsB,oBAAoB,IAAI,OAAO,CAAC,OAAO,CAAC,CAkB7D"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import isBrowser from'../../../utils/isBrowser/index.js';/**
|
|
2
|
+
* Transform changed settings to wrap in uilayout structure for backend API
|
|
3
|
+
* Converts keys like "[desktop].theme" to "[desktop].uilayout.theme"
|
|
4
|
+
*/
|
|
5
|
+
function transformSettingsForBackend(changedSettings) {
|
|
6
|
+
console.log('change ', changedSettings);
|
|
7
|
+
const wrappedSettings = {};
|
|
8
|
+
function flattenAndWrap(obj, prefix = '') {
|
|
9
|
+
Object.keys(obj).forEach(key => {
|
|
10
|
+
const value = obj[key];
|
|
11
|
+
const fullKey = prefix ? `${prefix}.${key}` : key;
|
|
12
|
+
if (typeof value === 'object' && value !== null && !Array.isArray(value)) {
|
|
13
|
+
// Recursively flatten nested objects
|
|
14
|
+
flattenAndWrap(value, fullKey);
|
|
15
|
+
} else {
|
|
16
|
+
// For leaf values, insert .uilayout after the bracket prefix
|
|
17
|
+
const bracketPrefix = prefix.split('.')[0]; // Extract bracket part like "[/route][desktop]"
|
|
18
|
+
const settingPath = fullKey.replace(`${bracketPrefix}.`, ''); // Get the setting path after bracket
|
|
19
|
+
wrappedSettings[`${bracketPrefix}.uilayout.${settingPath}`] = value;
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
Object.keys(changedSettings || {}).forEach(routeDeviceKey => {
|
|
24
|
+
const settingsObj = changedSettings[routeDeviceKey];
|
|
25
|
+
// Skip if not an object or if it's a route path
|
|
26
|
+
if (typeof settingsObj !== 'object' || settingsObj === null || routeDeviceKey.startsWith('/')) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
// Flatten the nested settings object with the route-device prefix
|
|
30
|
+
flattenAndWrap(settingsObj, routeDeviceKey);
|
|
31
|
+
});
|
|
32
|
+
console.log('change 2', wrappedSettings);
|
|
33
|
+
return wrappedSettings;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Extract and parse settings from browser cookies
|
|
37
|
+
* Returns null if cookie not found or parsing fails
|
|
38
|
+
*/
|
|
39
|
+
function getCookieSettings() {
|
|
40
|
+
if (!isBrowser()) return null;
|
|
41
|
+
try {
|
|
42
|
+
const settingsCookie = document.cookie.split(';').find(cookie => cookie.startsWith(' settings='));
|
|
43
|
+
if (!settingsCookie) {
|
|
44
|
+
console.log('settings Cookie not found');
|
|
45
|
+
return null;
|
|
46
|
+
}
|
|
47
|
+
const settingsValue = settingsCookie.split('=')[1];
|
|
48
|
+
const decodedComponent = decodeURIComponent(settingsValue);
|
|
49
|
+
const parsedSettings = JSON.parse(atob(decodedComponent));
|
|
50
|
+
console.log('Settings in cookies:', parsedSettings);
|
|
51
|
+
return parsedSettings;
|
|
52
|
+
} catch (err) {
|
|
53
|
+
console.error('Failed to get cookie settings:', err);
|
|
54
|
+
return null;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Clear settings cookies by sending DELETE request to server
|
|
59
|
+
*/
|
|
60
|
+
async function clearSettingsCookies() {
|
|
61
|
+
if (!isBrowser()) return false;
|
|
62
|
+
try {
|
|
63
|
+
const response = await fetch('/resources/settings', {
|
|
64
|
+
method: 'DELETE',
|
|
65
|
+
headers: {
|
|
66
|
+
'Content-Type': 'application/json'
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
const result = await response.json();
|
|
70
|
+
console.log('✅ Settings cookies cleared');
|
|
71
|
+
return true;
|
|
72
|
+
} catch (err) {
|
|
73
|
+
console.error('⚠️ Failed to clear cookies:', err);
|
|
74
|
+
return false;
|
|
75
|
+
}
|
|
76
|
+
}export{clearSettingsCookies,getCookieSettings,transformSettingsForBackend};//# sourceMappingURL=transformers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transformers.js","sources":["../../../../src/components/SettingDrawer/utils/transformers.ts"],"sourcesContent":[null],"names":[],"mappings":"yDAEA;;;AAGG;AACG,SAAU,2BAA2B,CAAC,eAAoC,EAAA;AAC5E,EAAA,OAAA,CAAA,GAAQ,CAAA,WAAa,eAAE,CAAA;QACvB,eAAM,GAAe,EAAwB;AAE7C,EAAA,SAAA,cAAS,CAAA,GAAe,EAAwB,WAAmB,EAAE;UACjE,CAAA,IAAO,CAAA,GAAI,CAAC,CAAA,OAAK,CAAA,GAAO,IAAE;AACtB,MAAA,MAAA,KAAA,MAAW,CAAA,GAAG,CAAA;AACd,MAAA,MAAA,OAAM,GAAA,MAAU,GAAA,CAAA,EAAM,MAAM,CAAA,CAAA,EAAA,GAAM,CAAA,CAAA,MAAS;AAE3C,MAAA,IAAA,iBAAW,QAAU,IAAA,KAAQ,SAAS,IAAK,CAAA,KAAQ,CAAC,OAAM,CAAA,KAAO,CAAC,EAAA;;AAE9D,QAAA,cAAA,CAAA,KAAA,EAAc,OAAM,CAAE;aACzB;;2BACG,GAAA,MAAA,CAAA,KAAA,CAAA,GAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AACA,QAAA,MAAA,WAAM,GAAA,OAAa,CAAA,OAAG,CAAM,CAAC,EAAA,aAAe,CAAA,CAAA,CAAA,EAAA,EAAA,CAAA,CAAA;AAC5C,QAAA,eAAM,CAAA,CAAA,EAAA,aAAc,CAAA,UAAe,EAAC,WAAG,CAAA,CAAA,CAAA,GAAa,KAAO;;;AAGnE,EAAA;QACH,CAAA,IAAA,CAAA,eAAA,IAAA,EAAA,CAAA,CAAA,OAAA,CAAA,cAAA,IAAA;AAED,IAAA,MAAM,WAAM,GAAA,eAAuB,CAAA,cAAS,CAAA;AACxC;QAEA,OAAA,WAAA,KAAA,QAAA,IAAA,WAAA,KAAgD,IAAA,IAAA,cAAA,CAAA,UAAA,CAAA,GAAA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ACJ,EAAA,CAAA,CAAA,OAAE,GAAA,EAAA;AAEH,IAAA,OAAA,CAAA,mCAAqC,EAAA,GAAA,CAAA;AACrC,IAAA,OAAA,KAAQ;AACR,EAAA;"}
|
|
@@ -9,21 +9,29 @@ export type ICheckboxThemeProps = {
|
|
|
9
9
|
changeSetting?: (key: string, value: string | boolean | any) => void;
|
|
10
10
|
settings?: any;
|
|
11
11
|
location?: any;
|
|
12
|
+
routePattern?: string;
|
|
13
|
+
applyToAllRoutes?: boolean;
|
|
12
14
|
};
|
|
13
15
|
export type ILayoutSettingsProps = {
|
|
14
16
|
settings?: Partial<ProSettings>;
|
|
15
17
|
changeSetting?: (key: string, value: string | boolean) => void;
|
|
16
18
|
location?: any;
|
|
19
|
+
routePattern?: string;
|
|
20
|
+
applyToAllRoutes?: boolean;
|
|
17
21
|
};
|
|
18
22
|
export type NavMenuSelectorProps = {
|
|
19
23
|
changeSetting?: (key: string, value: string | boolean | any) => void;
|
|
20
24
|
settings?: any;
|
|
21
25
|
location?: any;
|
|
26
|
+
routePattern?: string;
|
|
27
|
+
applyToAllRoutes?: boolean;
|
|
22
28
|
};
|
|
23
29
|
export type IRegionalSettingsProps = {
|
|
24
30
|
settings?: Partial<ProSettings | any>;
|
|
25
31
|
changeSetting?: (key: string, value: string | boolean | any) => void;
|
|
26
32
|
location?: any;
|
|
33
|
+
routePattern?: string;
|
|
34
|
+
applyToAllRoutes?: boolean;
|
|
27
35
|
};
|
|
28
36
|
export type MergerSettingsType<T> = Partial<T> & {
|
|
29
37
|
primaryColor?: string;
|
|
@@ -48,6 +56,7 @@ export interface SettingDrawerProps {
|
|
|
48
56
|
navTheme?: string;
|
|
49
57
|
primaryColor?: string;
|
|
50
58
|
pathname?: string;
|
|
59
|
+
routePattern?: string;
|
|
51
60
|
onCollapseChange?: (collapse: boolean) => void;
|
|
52
61
|
onSettingChange?: (settings: MergerSettingsType<ProSettings>) => void;
|
|
53
62
|
actor?: any;
|
|
@@ -62,6 +71,8 @@ export interface SettingDrawerProps {
|
|
|
62
71
|
onChangeAllPages?: () => void;
|
|
63
72
|
isOpen?: boolean;
|
|
64
73
|
setOpen?: (open: boolean) => void;
|
|
74
|
+
fullMenuData?: any;
|
|
75
|
+
location?: any;
|
|
65
76
|
}
|
|
66
77
|
export type IThemeColorProps = {
|
|
67
78
|
color?: Array<{
|
|
@@ -71,6 +82,9 @@ export type IThemeColorProps = {
|
|
|
71
82
|
}>;
|
|
72
83
|
changeSetting?: (key: string, value: string | boolean | any) => void;
|
|
73
84
|
settings?: any;
|
|
85
|
+
location?: any;
|
|
86
|
+
routePattern?: string;
|
|
87
|
+
applyToAllRoutes?: boolean;
|
|
74
88
|
};
|
|
75
89
|
export interface ThemeSelectorProps {
|
|
76
90
|
value: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/SettingDrawer/utils/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,MAAM,WAAW,WAAW;IACxB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IACtC,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,MAAM,mBAAmB,GAAG;IAC9B,IAAI,CAAC,EAAE,GAAG,EAAE,CAAC;IACb,aAAa,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,GAAG,GAAG,KAAK,IAAI,CAAC;IACrE,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC9B,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IAC/B,QAAQ,CAAC,EAAE,OAAO,CAAC,WAA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AAM,gBAAgB,GAAG;IAC3B,KAAK,CAAC,EAAE,KAAK,CAAC;QACV,GAAG,EAAE,MAAM,CAAC;QACZ,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,CAAC,EAAE,MAAM,CAAC;KAClB,CAAC,CAAC;IACH,aAAa,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,GAAG,GAAG,KAAK,IAAI,CAAC;IACrE,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC9B,CAAC;AAEF,MAAM,WAAW,kBAAkB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,EAAE,KAAK,CAAC;QACX,GAAG,EAAE,MAAM,CAAC;QACZ,KAAK,EAAE,MAAM,CAAC;KACjB,CAAC,CAAC;CACN;AAED,MAAM,WAAW,qBAAqB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,OAAO,EAAE,KAAK,CAAC;QACX,GAAG,EAAE,MAAM,CAAC;QACZ,KAAK,EAAE,MAAM,CAAC;KACjB,CAAC,CAAC;CACN"}
|
|
@@ -1,12 +1,17 @@
|
|
|
1
|
+
import { IAppLoadContext } from '@common-stack/client-core';
|
|
2
|
+
import { IResourceParams } from '@common-stack/core';
|
|
1
3
|
export declare const action: ({ request, context, params, }: {
|
|
2
4
|
request: Request;
|
|
3
|
-
context?:
|
|
4
|
-
params?:
|
|
5
|
-
}) => Promise<import("@remix-run/server-runtime").TypedResponse<any
|
|
5
|
+
context?: IAppLoadContext;
|
|
6
|
+
params?: IResourceParams;
|
|
7
|
+
}) => Promise<import("@remix-run/server-runtime").TypedResponse<any>>;
|
|
8
|
+
export declare const loader: ({ request, context, params, }: {
|
|
6
9
|
request: Request;
|
|
7
|
-
context?:
|
|
8
|
-
params?:
|
|
10
|
+
context?: IAppLoadContext;
|
|
11
|
+
params?: IResourceParams;
|
|
9
12
|
}) => Promise<import("@remix-run/server-runtime").TypedResponse<{
|
|
10
13
|
settings: any;
|
|
14
|
+
}> | import("@remix-run/server-runtime").TypedResponse<{
|
|
15
|
+
error: string;
|
|
11
16
|
}>>;
|
|
12
17
|
//# sourceMappingURL=UpdateSettingsResource.server.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UpdateSettingsResource.server.d.ts","sourceRoot":"","sources":["../../../src/components/UpdateSettingsResource/UpdateSettingsResource.server.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"UpdateSettingsResource.server.d.ts","sourceRoot":"","sources":["../../../src/components/UpdateSettingsResource/UpdateSettingsResource.server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAOrD,eAAO,MAAM,MAAM,GAAU,+BAI1B;IACC,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,MAAM,CAAC,EAAE,eAAe,CAAC;CAC5B,oEAyCA,CAAC;AAEF,eAAO,MAAM,MAAM,GAAU,+BAI1B;IACC,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,MAAM,CAAC,EAAE,eAAe,CAAC;CAC5B;;;;GAmBA,CAAC"}
|
|
@@ -1,4 +1,97 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { json } from '@remix-run/node';
|
|
2
|
+
import { settingsCookie, settingsLoaderUtil } from '@admin-layout/client/lib/components/UpdateSettings/UpdateSettings.server';
|
|
3
|
+
const action = async ({
|
|
4
|
+
request,
|
|
5
|
+
context,
|
|
6
|
+
params
|
|
7
|
+
}) => {
|
|
8
|
+
try {
|
|
9
|
+
// Handle DELETE request - Clear settings cookies
|
|
10
|
+
// Note: Database deletion is handled by resetApplicationSettings mutation on the client
|
|
11
|
+
if (request.method === 'DELETE') {
|
|
12
|
+
try {
|
|
13
|
+
// Clear the settings cookie by setting it to empty with maxAge 0
|
|
14
|
+
const cookie = await settingsCookie.serialize({}, {
|
|
15
|
+
maxAge: 0
|
|
16
|
+
});
|
|
17
|
+
return json({
|
|
18
|
+
success: true,
|
|
19
|
+
message: 'Settings cookies cleared successfully'
|
|
20
|
+
}, {
|
|
21
|
+
headers: {
|
|
22
|
+
'Set-Cookie': cookie
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
} catch (error) {
|
|
26
|
+
console.error('❌ Error clearing cookies:', error);
|
|
27
|
+
return json({
|
|
28
|
+
success: false,
|
|
29
|
+
error: 'Failed to clear cookies'
|
|
30
|
+
}, {
|
|
31
|
+
status: 500
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
// Handle POST request - Update settings using the utility
|
|
36
|
+
const {
|
|
37
|
+
settings,
|
|
38
|
+
setCookie
|
|
39
|
+
} = await settingsLoaderUtil({
|
|
40
|
+
request,
|
|
41
|
+
context,
|
|
42
|
+
params
|
|
43
|
+
});
|
|
44
|
+
// Return the full settings as JSON, and set the new cookie in the response headers
|
|
45
|
+
return json(settings, {
|
|
46
|
+
headers: {
|
|
47
|
+
'Set-Cookie': setCookie
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
} catch (error) {
|
|
51
|
+
// If anything fails, log the error and return a 500 error response
|
|
52
|
+
console.error('Error in action:', error);
|
|
53
|
+
return json({
|
|
54
|
+
error: 'Failed to update settings'
|
|
55
|
+
}, {
|
|
56
|
+
status: 500
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
const loader = async ({
|
|
61
|
+
request,
|
|
62
|
+
context,
|
|
63
|
+
params
|
|
64
|
+
}) => {
|
|
65
|
+
try {
|
|
66
|
+
const {
|
|
67
|
+
settings,
|
|
68
|
+
setCookie
|
|
69
|
+
} = await settingsLoaderUtil({
|
|
70
|
+
request,
|
|
71
|
+
context,
|
|
72
|
+
params
|
|
73
|
+
});
|
|
74
|
+
// Always include headers, but only set cookie if provided
|
|
75
|
+
const headers = {};
|
|
76
|
+
if (setCookie) {
|
|
77
|
+
headers['Set-Cookie'] = setCookie;
|
|
78
|
+
}
|
|
79
|
+
// returnInfo: {"returnType":"json","keys":["settings"],"hasOptions":true}
|
|
80
|
+
return {
|
|
81
|
+
data: [settings],
|
|
82
|
+
options: {
|
|
83
|
+
headers
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
} catch (error) {
|
|
87
|
+
console.error('Error in settings loader:', error);
|
|
88
|
+
// returnInfo: {"returnType":"json","keys":["settings","error"],"hasOptions":true}
|
|
89
|
+
return {
|
|
90
|
+
data: ['Failed to load settings'],
|
|
91
|
+
options: {
|
|
92
|
+
status: 500
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
};
|
|
97
|
+
export { action, loader }; //# sourceMappingURL=UpdateSettingsResource.server.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UpdateSettingsResource.server.js","sources":["../../../src/components/UpdateSettingsResource/UpdateSettingsResource.server.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"UpdateSettingsResource.server.js","sources":["../../../src/components/UpdateSettingsResource/UpdateSettingsResource.server.ts"],"sourcesContent":[null],"names":[],"mappings":"4JAQO,MAAM,MAAM,GAAG,OAAO;AASzB,EAAA,OAAK;SACD;;AAEA,CAAA,KAAA;AACI,EAAA,IAAA;;AAEI;gBAEA,MAAA,KAAW,QACL,EAAO;AAEL,MAAA,IAAA;AACI;AACH,QAAA,MAAA,MAAA,GAAA,MAAA,cAAA,CAAA,SAAA,CAAA,EAAA,EAAA;AACJ,UAAA,MAAA,EACJ;;eACH,IAAO,CAAA;AACL,UAAA,OAAA,EAAA,IAAO;AACP,UAAA,OAAA,EAAA;;UAEP,OAAA,EAAA;YAED,YAAA,EAAA;;;eAGI,KAAO,EAAA;eACP,CAAA,KAAM,CAAA,2BAAA,EAAA,KAAA,CAAA;AACT,QAAA,OAAE,IAAA,CAAA;UAEH,OAAA,EAAA,KAAA;UACA,KAAO,EAAA;AACH,SAAA,EAAA;AACI,UAAA,MAAA,EAAA;AACH,SAAA,CAAA;AACJ,MAAA;IACL;;UACI;AACA,MAAA,QAAA;AACA,MAAA;KACH,GAAA,MAAA,kBAAA,CAAA;AACL,MAAE,OAAA;AAEF,MAAM,OAAO;AAST,MAAA;;;eAGQ,CAAA,QAAO,EAAA;aACP,EAAA;AACH,QAAA,YAAE,EAAA;;;WAIH,KAAI,EAAA;AACA;WACH,CAAA,KAAA,CAAA,kBAAA,EAAA,KAAA,CAAA;WAED,IAAO,CAAA;MACV,KAAA,EAAA;KAAC,EAAA;AACE,MAAA,MAAA,EAAA;AACA,KAAA,CAAA;;AAER;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/lib/components/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MainHeader
|
|
1
|
+
export{MainHeader}from'./Layout/GlobalHeader/MainHeader.js';export{RightMenu}from'./Layout/GlobalHeader/RightMenu.js';//# sourceMappingURL=index.js.map
|
|
@@ -34,7 +34,11 @@ export interface SidebarMenuProps {
|
|
|
34
34
|
settings: {
|
|
35
35
|
primaryColor: string;
|
|
36
36
|
};
|
|
37
|
-
collapsed
|
|
37
|
+
collapsed?: boolean;
|
|
38
|
+
siderPinned?: boolean;
|
|
39
|
+
setSiderPinned?: (siderPinned: boolean) => void;
|
|
40
|
+
actor?: any;
|
|
41
|
+
deviceSettings?: any;
|
|
38
42
|
}
|
|
39
43
|
export interface SidebarProps {
|
|
40
44
|
isSideMenuOpen: boolean;
|
|
@@ -47,10 +51,21 @@ export interface SidebarProps {
|
|
|
47
51
|
[key: string]: string;
|
|
48
52
|
};
|
|
49
53
|
settings?: any;
|
|
54
|
+
sideBarMarginTop?: string;
|
|
55
|
+
showHeader?: boolean;
|
|
50
56
|
upperMenuDividerName?: string;
|
|
51
57
|
middleMenuDividerName?: string;
|
|
52
58
|
lowerMenuDividerName?: string;
|
|
53
59
|
location?: any;
|
|
60
|
+
siderPinned?: boolean;
|
|
61
|
+
setSiderPinned?: (siderPinned: boolean) => void;
|
|
62
|
+
layoutSettings?: any;
|
|
63
|
+
deviceSettings?: any;
|
|
64
|
+
menuHeaderRender?: any;
|
|
65
|
+
isSideMenuLayout?: boolean;
|
|
66
|
+
actor?: any;
|
|
67
|
+
authorities?: Record<string, PermissionType>;
|
|
68
|
+
picture?: string;
|
|
54
69
|
}
|
|
55
70
|
export interface BottomMenuDropDownProps {
|
|
56
71
|
menus: any;
|
|
@@ -59,6 +74,7 @@ export interface BottomMenuDropDownProps {
|
|
|
59
74
|
orgName?: string;
|
|
60
75
|
[key: string]: string;
|
|
61
76
|
};
|
|
77
|
+
layoutSettings?: any;
|
|
62
78
|
}
|
|
63
79
|
export interface GlobalHeaderRightProps {
|
|
64
80
|
theme?: string;
|
|
@@ -105,6 +121,8 @@ export type PrivateHeaderProps = {
|
|
|
105
121
|
export interface MainHeaderProps extends Partial<GlobalHeaderProps> {
|
|
106
122
|
rightContentRender?: WithFalse<(props: any) => React.ReactNode>;
|
|
107
123
|
showSettings?: boolean;
|
|
124
|
+
showMenu?: boolean;
|
|
125
|
+
toggleSideMenu?: () => void;
|
|
108
126
|
}
|
|
109
127
|
export type IRightMenuProps = {
|
|
110
128
|
match?: any;
|
|
@@ -118,6 +136,7 @@ export type IRightMenuProps = {
|
|
|
118
136
|
settings?: Partial<ProSettings>;
|
|
119
137
|
authorities: Record<string, PermissionType>;
|
|
120
138
|
picture?: string;
|
|
139
|
+
isMobile?: boolean;
|
|
121
140
|
};
|
|
122
141
|
export interface DividerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
123
142
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typings.d.ts","sourceRoot":"","sources":["../../src/components/typings.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAC;AAC7B,OAAO,EAAE,WAAW,IAAI,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAClE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,iBAAiB,EAAE,YAAY,EAAE,WAAW,EAAgB,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACtH,OAAO,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAExC,MAAM,WAAW,SAAU,SAAQ,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC;IAC5E,EAAE,EAAE,CAAC,CAAC,QAAQ,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;CAC3C;AAED,MAAM,MAAM,kBAAkB,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,GAAG;IAC7C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;CACvB,CAAC;AAEF,MAAM,WAAW,MAAO,SAAQ,YAAY;IACxC,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACrB;AACD,MAAM,MAAM,SAAS,CAAC,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC;AAErC,MAAM,WAAW,WAAW,CAAC,CAAC,CAAE,SAAQ,IAAI,CAAC,eAAe,EAAE,UAAU,CAAC;IACrE,aAAa,CAAC,EAAE,GAAG,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,eAAe,CAAC,UAAU,CAAC,GAAG;QAAE,QAA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ACV,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,CAAC,CAAC,EAAE,GAAG,CAAC;IACR,CAAC,CAAC,EAAE,GAAG,CAAC;IACR,SAAS,CAAC,EAAE,GAAG,CAAC;CACnB"}
|
package/lib/compute.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compute.d.ts","sourceRoot":"","sources":["../src/compute.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"compute.d.ts","sourceRoot":"","sources":["../src/compute.ts"],"names":[],"mappings":"AA8BA,QAAA,MAAM,aAAa,0CAA0C,CAAC;AAG9D,QAAA,MAAM,cAAc,0CAA2C,CAAC;AAEhE,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,CAAC"}
|
package/lib/compute.js
CHANGED
|
@@ -25,11 +25,19 @@ const tailwindDesignProPage = [{
|
|
|
25
25
|
hasServerCode: true,
|
|
26
26
|
name: 'UpdateSettingsResource',
|
|
27
27
|
isResourceRoute: true,
|
|
28
|
-
auth: false
|
|
28
|
+
auth: false
|
|
29
|
+
// @ts-ignore
|
|
30
|
+
,
|
|
31
|
+
|
|
29
32
|
path: '/resources/settings',
|
|
30
33
|
componentPath: "@admin-layout/tailwind-design-pro/lib/components/UpdateSettingsResource/UpdateSettingsResource.js",
|
|
31
34
|
hasLoader: true,
|
|
32
|
-
hasAction: true
|
|
35
|
+
hasAction: true,
|
|
36
|
+
loaderReturnInfo: {
|
|
37
|
+
returnType: "json",
|
|
38
|
+
hasOptions: true,
|
|
39
|
+
keys: ["settings", "error"]
|
|
40
|
+
}
|
|
33
41
|
}];
|
|
34
42
|
// get menus
|
|
35
43
|
getFilteredMenus(tailwindDesignProPage);
|
package/lib/compute.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compute.js","sources":["../src/compute.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"compute.js","sources":["../src/compute.ts"],"sourcesContent":[null],"names":[],"mappings":"oJAIA,MAAM,GAAG,GAAG,aAAa;AAEzB,MAAM,qBAAqB,GAAmB,CAAA;AAC1C,EAAA,GAAA,EAAA,GAAA;AACI,EAAA,IAAA,EAAA,aAAQ;AACR,EAAA,IAAA,EAAA,MAAM,CAAA,WAAA;QACN,UAAM;AACN,EAAA,gBAAM,EAAA,CAAA,GAAU,CAAA;SAChB,KAAA;AACA,EAAA,SAAA,EAAK,MAAE,OAAK,0CAAA;AAEZ,CAAA,EAAA;AACH,EAAA,GAAA,EAAA,0BAAA;AACD,EAAA,aAAA,EAAA,IAAA;AACI,EAAA,IAAA,EAAA,wBAAK;AACL,EAAA,eAAA,EAAA,IAAe;AACf,EAAA,IAAA,EAAA;AACA;AACA,EAAA,SAAA,QAAW,OAAA,+DAAA,CAAA;QACX;AACA,CAAA,CAAA;AACA;AACH,gBAAA,CAAA,qBAAA;;AAGL,MAAA,cAAY,GAAA,iBAAA,CAAA,qBAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sources":["../../src/config/constants.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../src/config/constants.ts"],"sourcesContent":[null],"names":[],"mappings":"AAAO,MAAM,gBAAgB,GAAG;AAC5B,EAAA,GAAA,EAAG;AACH,EAAA,GAAA,EAAG,IAAE;AACL,EAAA,IAAA,EAAI,EAAE;AACN,EAAA,OAAA,EAAO;;AAGJ,MAAM,eAAe,GAAG;AAC3B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;"}
|
|
@@ -6,6 +6,7 @@ export declare const config: Readonly<{
|
|
|
6
6
|
BOOKING_CAR_RENTAL_API_KEY: string;
|
|
7
7
|
AIRBNB_API_KEY: string;
|
|
8
8
|
BOOKING_COM_API_KEY: string;
|
|
9
|
+
APP_DOMAIN: string;
|
|
9
10
|
SEARCH_LAYOUT: string;
|
|
10
11
|
GOOGLE_MAPS_API_KEY: string;
|
|
11
12
|
PROPERTY_SEARCH_DEFAULT_PAGE_SIZE: number;
|
|
@@ -18,5 +19,7 @@ export declare const config: Readonly<{
|
|
|
18
19
|
ENABLE_SETTING_DRAWER: boolean;
|
|
19
20
|
GOOGLE_ANALYTICS_ID: string;
|
|
20
21
|
RAPID_API_KEY: string;
|
|
22
|
+
APPLICATION_ID: string;
|
|
23
|
+
USE_FETCH_SETTINGS: string;
|
|
21
24
|
} & import("envalid").CleanedEnvAccessors>;
|
|
22
25
|
//# sourceMappingURL=env-config.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"env-config.d.ts","sourceRoot":"","sources":["../../src/config/env-config.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,MAAM
|
|
1
|
+
{"version":3,"file":"env-config.d.ts","sourceRoot":"","sources":["../../src/config/env-config.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;0CA4CjB,CAAC"}
|
package/lib/config/env-config.js
CHANGED
|
@@ -34,6 +34,9 @@ const config = cleanEnv(env, {
|
|
|
34
34
|
default: '',
|
|
35
35
|
desc: 'Booking com API key'
|
|
36
36
|
}),
|
|
37
|
+
APP_DOMAIN: str({
|
|
38
|
+
default: 'cdebase.dev'
|
|
39
|
+
}),
|
|
37
40
|
SEARCH_LAYOUT: str({
|
|
38
41
|
default: '/search',
|
|
39
42
|
desc: 'Layout Search route'
|
|
@@ -78,5 +81,12 @@ const config = cleanEnv(env, {
|
|
|
78
81
|
}),
|
|
79
82
|
RAPID_API_KEY: str({
|
|
80
83
|
default: '7c2d15ba29msh468be2f129d847cp183e95jsnc7c279116f6e'
|
|
84
|
+
}),
|
|
85
|
+
APPLICATION_ID: str({
|
|
86
|
+
default: '660e8400-e29b-41d4-a716-446655440001',
|
|
87
|
+
desc: 'Matches the Application ID exist already'
|
|
88
|
+
}),
|
|
89
|
+
USE_FETCH_SETTINGS: str({
|
|
90
|
+
default: ''
|
|
81
91
|
})
|
|
82
92
|
});export{config};//# sourceMappingURL=env-config.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"env-config.js","sources":["../../src/config/env-config.ts"],"sourcesContent":[null],"names":[],"mappings":"0JAIA,MAAM,GAAG,GAAG,cAAc,EAAE;AAE5B,MAAM,sBAAsB,GAAG,IAAI,CAAC,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"env-config.js","sources":["../../src/config/env-config.ts"],"sourcesContent":[null],"names":[],"mappings":"0JAIA,MAAM,GAAG,GAAG,cAAc,EAAE;AAE5B,MAAM,sBAAsB,GAAG,IAAI,CAAC,SAAS,CAAC;KAC1C,EAAG,gBAAE,CAAA,GAAiB;KACtB,EAAG,gBAAE,CAAA,GAAiB;MACtB,EAAI,gBAAE,CAAA,IAAiB;SACvB,EAAO,gBAAE,CAAA;AACZ,CAAA,CAAC;AAEK,MAAM,MAAM,GAAG,QAAQ,CAAC,GAAG,EAAE;AAChC,EAAA,WAAA,EAAW,GAAE,CAAA;AACb,IAAA,OAAA,EAAA,aAAA;AACA,IAAA,IAAA,EAAA;AACA,GAAA,CAAA;AACA,EAAA,gCAA4B,EAAI,IAAE,CAAA;AAClC,IAAA,OAAA,EAAA,KAAc;AACd,IAAA,IAAA,EAAA;IACA;AACA,EAAA,gBAAa,EAAE,GAAI,CAAA;IACnB,OAAA,EAAA;IACA,IAAA,EAAA;AACI,GAAA,CAAA;AACA,EAAA,eAAM,EAAA,GAAA,CAAA;WACR,EAAA,IAAA,CAAA,SAAA,CAAA,eAAA,CAAA;IACF,IAAA,EAAA;AACI,GAAA,CAAA;AACA,EAAA,0BAAM,EAAA,GAAA,CAAA;WACR,EAAA,EAAA;IACF,IAAA,EAAA;;AAEI,EAAA,cAAM,EAAA,GAAA,CAAA;WACR,EAAA,EAAA;IACF,IAAA,EAAA;AACI,GAAA,CAAA;AACA,EAAA,mBAAM,EAAA,GAAA,CAAA;WACR,EAAA,EAAA;IACF,IAAA,EAAA;AACI,GAAA,CAAA;AACA,EAAA,UAAI,EAAE,GAAA,CAAA;WACR,EAAA;IACF;eACA,EAAA,GAAA,CAAA;AACI,IAAA,OAAA,EAAA,SAAS;AACT,IAAA,IAAA,EAAA;;AAEJ,EAAA,mBAAA,EAAA,GAAqB,CAAE;IACvB,OAAA,EAAA;IACA;mCACoB,EAAA,GAAA,CAAA;AAChB,IAAA,OAAA,EAAA,EAAO;AACP,IAAA,IAAA,EAAA;;sCAE6B,GAAI;AACxC,IAAE,OAAA,EAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DynamicIcon.js","sources":["../../src/helpers/DynamicIcon.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":"
|
|
1
|
+
{"version":3,"file":"DynamicIcon.js","sources":["../../src/helpers/DynamicIcon.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":"uJAgBO,MAAM,WAAW,GAAoC,KAAK,CAAC,IAAI,CAClE,CAAC;MACG;WACA;;AAEQ,CAAA,KAAA;sBACA,EAAY,gBAAA,CAAA,GAAA,QAAA,CAAA,IAAA,CAAA;AACP,EAAA,SAAA,CAAA,MAAA;AACG,IAAA,MAAA,QAAA,SAAW;wBACP,GAAA,cAAoB,CAAE,IAAC,CAAA;kBAC1B,CAAA,IAAA,CAAA,MAAA,IAAA;yBAAO,CAAA,OAAA,KAAA,QAAA,EAAA;0BACJ,CAAA,MAAA,OAAoB,YAAU,CAAA,CAAA;;AAEtC,UAAA,gBAAE,CAAA,MAAA,MAAA,CAAA,OAAA,CAAA;AACD,QAAA;kBACG,IAAA;AACJ,QAAA,gBAAG,CAAA,IAAA,CAAA;AACX,MAAA,CAAA,CAAA;AACA,IAAA,CAAA;AACJ,IAAA,QAAQ,EAAE;AAEV,EAAA,CAAA,EAAA,CAAA,IAAK,CAAA,CAAA;AAAe,EAAA,IAAA,CAAA,aAAY,EAAA,OAAA,IAAA;AAEhC,EAAA,OAAAA,GACI,CAAA,KAAA,EAAA;yBAImB;iBACP,CAAA,aAAQ,EAAS;AACjB,MAAA,SAAA,EAAA,aAAO;AACP,MAAA,KAAA,EAAA;wBACQ,EAAC,SAAK;AACjB,QAAA,MAAA,EAAA,SACQ,EACX,SAER;AACN,QACC,KAAS,EAAE,SAAS,EAAE,CAAA,IACnB,MAAA;AAGR,QAAO,MAAM,EAAA,SAAA,EAAA,CAAA,UAAyB;AAClC,QAAI,GAAA,KAAO,CAAA;AACP,OAAA;MACH,GAAA;AAAM,KAAA;AACH,GAAA,CAAA;IACJ,SAAC,EAAA,SAAA,KAAA,SAAA,CAAA,IAAA,KAAA,SAAA,CAAA,IAAA,IAAA,SAAA,CAAA,SAAA,EAAA,SAAA,KAAA,SAAA,CAAA,SAAA,EAAA,SAAA;AAAO,MAAA,iBAAA,GAAA,IAAA,IAAA;AACJ,EAAA,IAAA,OAAA,SAAY,QAAA,EAAA;IAChB,OAACA,GAAA,CAAA,WAAA,EAAA;AACL,MAAE,IAAA,EAAA,IAAA,CAAA,IAAA;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useMediaQuery.js","sources":["../../src/hooks/useMediaQuery.ts"],"sourcesContent":[null],"names":[],"mappings":"uCAcA,MAAM,WAAW,GAAG;AAChB,EACA,EAAA,EAAE,
|
|
1
|
+
{"version":3,"file":"useMediaQuery.js","sources":["../../src/hooks/useMediaQuery.ts"],"sourcesContent":[null],"names":[],"mappings":"uCAcA,MAAM,WAAW,GAAG;AAChB,EACA,EAAA,EAAE,GAAE;AACJ,EAAA,EAAA,EAAE,GAAE;AACJ,EAAA,EAAA,EAAE,IAAE;AACJ,EAAA,EAAA,EAAE,IAAE;AACJ,EAAA,KAAA,EAAK;CACR;AAED,MAAM,QAAQ,GAAG,UAA2E;AACxF,EAAA,EAAA,E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;AAC9B,IAAA,OAAE,MAAA,MAAA,CAAA,mBAAA,CAAA,QAAA,EAAA,YAAA,CAAA;AAEF,EAAA,CAAA,EAAA,EAAA,CAAA;SACA,KAAA;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useScrollThreshold.js","sources":["../../src/hooks/useScrollThreshold.ts"],"sourcesContent":[null],"names":[],"mappings":"0DAQA,MAAM,QAAQ,GAAG,CAAC,EAAY,EAAE,
|
|
1
|
+
{"version":3,"file":"useScrollThreshold.js","sources":["../../src/hooks/useScrollThreshold.ts"],"sourcesContent":[null],"names":[],"mappings":"0DAQA,MAAM,QAAQ,GAAG,CAAC,EAAY,EAAE,IAAA,GAAe,GAAG,KAAI;AAClD,EAAA,IAAA,OAAQ,IAAG,CAAA,GAAK,EAAG;SACnB,UAAO,OAAa,EAAW;QAC3B,IAAI,GAAA,IAAO,GAAA,IAAO,CAAA,GAAI,EAAC,GAAG,CAAE,EAAA;AACxB,MAAA,EAAA,CAAA,GAAA,IAAG,CAAA;AACH,MAAA,IAAA,GAAA,IAAI,CAAA,GAAG,EAAI;;AAEnB,EAAA,CAAA;AACJ,CAAC;AAEM,MAAM,kBAAkB,GAAG,OAAC,IAAkC;QACjE,CAAA,mBAAO,EAAmB,sBAAE,CAAA,WAA0B,CAAA,EAAkC,CAAA;AACxF,EAAA,MAAA,eAAkB,MAAG,CAAA,IAAuB,CAAA;AAC5C,EAAA,MAAA,gBAAmB,MAAG,CAAA,EAAgC,CAAA;AAEtD,EAAA,MAAA,mBAAsB,WAAG,CAAA,cACpB;UACG,aAAM,GAAA,EAAa;QACnB,UAAI,GAAA,KAAa;WAEjB,CAAA,OAAQ,CAAA,CAAA;AACJ,MAAA,SAAA;;;YAGA,SAAC,GAAA,cAAA,IAAA,SAAA;AACD,MAAA,IAAA,aAAA,CAAA,OAAiB,CAAG,iBAAU,EAAA;AAClC,QAAA,UAAG,GAAA,IAAA;;AAGC,MAAA,aAAA,CAAA,EAAA,CAAA,GAAc,SAAO;;QAEzB,UAAC,EAAA;AACL,MAAC,aAEH,CAAA,OAAA,GAAA,aAAA;MAEF,sBAAe,CAAA,aAAA,CAAA;;AAEX,EAAA,CAAA,EAAA,CAAA,OAAA,CAAM;AAEN,EAAA,SAAA,CAAA,MAAM;AACF,IAAA,MAAA,MAAA;yBACA,GAAgB,MAAC,EAAA,eAAgB,IAAA,KAAA;UACpC,eAAM,GAAA,QAAA,CAAA,MAAA;YAEP,cAAkB,GAAG,eAAK,GAAA,MAAA,CAAA,OAAA,GAAA,YAAA,CAAA,OAAA,EAAA,SAAA,IAAA,CAAA;AACtB,MAAA,gBAAA,CAAA,cAAkB,CAAA;AACtB,IAAA,CAAA,EAAA,EAAC,CAAC;UAEF,YAAI,GAAA,MAAkB;AAClB,MAAA,eAAO,EAAA;;AACJ,IAAA,IAAA,eAAI,EAAA;YACP,CAAA,yBAAqB,EAAA,YAAiB,CAAA;WACzC,IAAA,YAAA,CAAA,OAAA,EAAA;AAED,MAAA,YAAA,CAAA,OAAiB,CAAA,gBAAkB,CAAA,QAAO,EAAA,YAAU,CAAA;AAEpD,IAAA;oBACQ,CAAA,eAAkB,GAAA,MAAA,CAAA,OAAA,GAAA,YAAA,CAAA,OAAA,EAAA,SAAA,IAAA,CAAA,CAAA;AAClB,IAAA,OAAA,MAAA;yBACH,EAAA;AAAM,QAAA,MAAA,CAAA,mBAAiB,CAAA,QAAS,EAAC,YAAA,CAAA;iBAC9B,YAAa,QAAQ,EAAA;oBACxB,CAAA,OAAA,CAAA,mBAAA,CAAA,QAAA,EAAA,YAAA,CAAA;AACL,MAAA;AACJ,IAAA,CAAC;KAED,CAAA,OAAO,EAAA,gBAAA,CAAA,CAAA;SACH;gBACA;;AAER,GAAE;"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import {useState,useEffect}from'react';import {FaMoon}from'@react-icons/all-files/fa/FaMoon.js';import {FaSun}from'@react-icons/all-files/fa/FaSun.js';const useTailwindTheme = () => {
|
|
2
|
+
// Check if dark mode is preferred by user or system
|
|
3
|
+
const [isDark, setIsDark] = useState(() => {
|
|
4
|
+
if (typeof window !== 'undefined') {
|
|
5
|
+
// Check local storage first, then system preference
|
|
6
|
+
const storedTheme = localStorage.getItem('color-theme');
|
|
7
|
+
if (storedTheme === 'dark') return true;
|
|
8
|
+
if (storedTheme === 'light') return false;
|
|
9
|
+
return window.matchMedia('(prefers-color-scheme: dark)').matches;
|
|
10
|
+
}
|
|
11
|
+
return false;
|
|
12
|
+
});
|
|
13
|
+
// Set dark mode class on body when theme changes
|
|
14
|
+
useEffect(() => {
|
|
15
|
+
document.documentElement.classList.toggle('dark', isDark);
|
|
16
|
+
localStorage.setItem('color-theme', isDark ? 'dark' : 'light');
|
|
17
|
+
}, [isDark]);
|
|
18
|
+
const toggleColorMode = () => setIsDark(!isDark);
|
|
19
|
+
const colorModeLabel = isDark ? 'light' : 'dark';
|
|
20
|
+
const ColorModeIcon = isDark ? FaSun : FaMoon;
|
|
21
|
+
// Define colors for both light and dark modes
|
|
22
|
+
const bgColor = isDark ? '#1A202C' : 'white'; // gray-800 or white
|
|
23
|
+
const color = isDark ? 'white' : '#2d3748'; // white or gray-800
|
|
24
|
+
const grayColor = isDark ? '#A0AEC0' : '#4A5568'; // gray-400 or gray-600
|
|
25
|
+
const greenColor = '#38A169'; // green-500 in both modes
|
|
26
|
+
const passiveColor = isDark ? '#4A5568' : '#E2E8F0'; // gray-600 or gray-200
|
|
27
|
+
const borderColor = isDark ? '#4A5568' : '#E2E8F0'; // gray-600 or gray-200
|
|
28
|
+
const checkBgColor = isDark ? '#1A202C' : '#CBD5E0'; // gray-800 or gray-300
|
|
29
|
+
const radioActiveBgColor = isDark ? 'rgb(0 31 71)' : '#EBF8FF'; // custom dark blue or blue-50
|
|
30
|
+
const checkInactiveColor = isDark ? 'rgba(255, 255, 255, 0.4)' : '#CBD5E0'; // whiteAlpha-400 or gray-300
|
|
31
|
+
const blueColor = '#2869E0'; // same in both modes
|
|
32
|
+
const yellowColor = '#F5BC00'; // same in both modes
|
|
33
|
+
const blackColor = '#000'; // same in both modes
|
|
34
|
+
const becomeHostColor = isDark ? '#4299E1' : '#9DECF9'; // blue-400 or cyan-200
|
|
35
|
+
const activeMenuBgColor = isDark ? '#2D3748' : '#EDF2F7'; // gray-700 or gray-100
|
|
36
|
+
const shadowColor = isDark ? 'rgba(205, 205, 162, 0.25) 0px 6px 12px -2px, rgba(255,255,255, 0.3) 0px 3px 7px -3px' : 'rgba(50, 50, 93, 0.25) 0px 6px 12px -2px, rgba(0, 0, 0, 0.3) 0px 3px 7px -3px';
|
|
37
|
+
const calendarAvailableColor = '#3e9f31'; // same in both modes
|
|
38
|
+
const calendarPartialColor = '#31679f'; // same in both modes
|
|
39
|
+
const calendarBlockColor = isDark ? '#2d3748' : '#e2e8f0'; // gray-800 or gray-300
|
|
40
|
+
const discountColor = '#3182CE'; // blue-500 in both modes
|
|
41
|
+
const cancelColor = '#E53E3E'; // red-500 in both modes
|
|
42
|
+
const errorColor = '#C53030'; // red-600 in both modes
|
|
43
|
+
// Tailwind-specific class helpers
|
|
44
|
+
const textColorClass = isDark ? 'text-white' : 'text-gray-800';
|
|
45
|
+
const borderColorClass = isDark ? 'border-gray-600' : 'border-gray-200';
|
|
46
|
+
const bgColorClass = isDark ? 'bg-gray-800' : 'bg-white';
|
|
47
|
+
const textColor = isDark ? 'white' : 'gray-800';
|
|
48
|
+
const shadowClass = isDark ? 'shadow-dark' : 'shadow-light';
|
|
49
|
+
return {
|
|
50
|
+
toggleColorMode,
|
|
51
|
+
colorModeLabel,
|
|
52
|
+
ColorModeIcon,
|
|
53
|
+
color,
|
|
54
|
+
bgColor,
|
|
55
|
+
blackColor,
|
|
56
|
+
borderColor,
|
|
57
|
+
checkBgColor,
|
|
58
|
+
radioActiveBgColor,
|
|
59
|
+
checkInactiveColor,
|
|
60
|
+
grayColor,
|
|
61
|
+
greenColor,
|
|
62
|
+
passiveColor,
|
|
63
|
+
blueColor,
|
|
64
|
+
yellowColor,
|
|
65
|
+
becomeHostColor,
|
|
66
|
+
activeMenuBgColor,
|
|
67
|
+
shadowColor,
|
|
68
|
+
calendarAvailableColor,
|
|
69
|
+
calendarPartialColor,
|
|
70
|
+
calendarBlockColor,
|
|
71
|
+
discountColor,
|
|
72
|
+
cancelColor,
|
|
73
|
+
errorColor,
|
|
74
|
+
isDark,
|
|
75
|
+
// Tailwind specific
|
|
76
|
+
textColor,
|
|
77
|
+
borderColorClass,
|
|
78
|
+
bgColorClass,
|
|
79
|
+
textColorClass,
|
|
80
|
+
shadowClass
|
|
81
|
+
};
|
|
82
|
+
};export{useTailwindTheme};//# sourceMappingURL=useTailwindTheme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useTailwindTheme.js","sources":["../../src/hooks/useTailwindTheme.tsx"],"sourcesContent":[null],"names":[],"mappings":"uJAsCO,MAAM,gBAAgB,GAAG,MAAkC;;QAE9D,CAAA,QAAa,SAAE,CAAA,GAAU,QAAG,CAAA,MAAY;AACpC,IAAA,IAAA,OAAI,MAAO,KAAM,WAAK,EAAA;;YAElB,WAAM,GAAA,YAAc,CAAA,qBAAqB,CAAA;qBACrC,KAAA,MAAgB,EAAA,OAAM,IAAA;AAAE,MAAA,IAAA,WAAA,YAAY,EAAA,OAAA,KAAA;aACxC,MAAI,CAAA,yCAAuB,CAAA,CAAA,OAAA;AAAE,IAAA;gBAC7B;;AAEJ;AACJ,EAAA,SAAG,CAAA,MAAA;IAEH,QAAA,CAAA,eAAA,CAAA,SAAA,CAAA,MAAA,CAAA,MAAA,EAAiD,MAAA,CAAA;IACjD,aAAa,OAAE,CAAA,aAAA,EAAA,MAAA,GAAA,MAAA,GAAA,OAAA,CAAA;YACX,CAAA,CAAA;AACA,EAAA,MAAA,eAAa,GAAA,MAAQ,SAAA,CAAa,OAAE,CAAM;AAC9C,EAAA,MAAI,cAAS,GAAA,MAAA,GAAA,OAAA,GAAA,MAAA;QAEb,aAAM,GAAA,MAA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MAAA,gBAAoB,GAAA,MAAS,GAAE,iBAAA,GAAA,iBAAwB;AACvD,EAAA,MAAA,YAAgB,GAAG,MAAA,GAAS,aAAE,GAAA,UAAwB;QAEtD,SAAA,GAAA,MAAA,GAAA,OAAA,GAAkC,UAAA;QAClC,WAAM,GAAA,MAAiB,GAAA,aAAS,GAAA,cAAe;SAC/C;IACA,eAAM;IACN,cAAM;IACN,aAAM;IAEN,KAAA;WACI;cACA;eACA;gBACK;sBACE;sBACG;aACV;cACA;gBACA;aACA;eACA;mBACU;qBACE;eACZ;0BACW;wBACI;sBACf;iBACA;eACA;cACA;UACA;;aAEA;oBACU;gBACJ;kBACN;;;"}
|
package/lib/icons.d.ts
CHANGED
|
@@ -12,5 +12,7 @@ export declare const icons: {
|
|
|
12
12
|
ChevronForwardCircleIcon: import("@react-icons/all-files/lib").IconType;
|
|
13
13
|
ChevronUpIcon: import("@react-icons/all-files/lib").IconType;
|
|
14
14
|
ChevronLeftIcon: import("@react-icons/all-files/lib").IconType;
|
|
15
|
+
PushpinLineIcon: import("@react-icons/all-files/lib").IconType;
|
|
16
|
+
PushpinFillIcon: import("@react-icons/all-files/lib").IconType;
|
|
15
17
|
};
|
|
16
18
|
//# sourceMappingURL=icons.d.ts.map
|