@common-stack/client-react 7.1.1-alpha.52 → 7.1.1-alpha.62
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/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ClientTypes}from'@common-stack/client-core';export{Feature}from'./connector/connector.js';export{FeatureWithRouterFactory}from'./router-factory/index.js';export{default as resolveRootRoute}from'./route/react-navigation/react-navigation-render.js';export{getNavigation,getSortedNavigations}from'./route/react-navigation/get-navigation-utils.js';export{navigate,navigationRef}from'./route/root-navigation.js';export{sortByPaths,sortKeys}from'./utils/sort-keys.js';export{formatSlash}from'./utils/utils.js';export{combine}from'./utils/combine.js';export{hydrate}from'./utils/hydrate.js';export{beforeSSR}from'./utils/before-ssr.js';export{getFilteredMenus,getFilteredRoutes,getFilteredTabs}from'./utils/filteredRoutes.js';export{IMenuPosition}from'@common-stack/core/lib/component/interfaces/menu.js';export{PluginArea}from'./plugin-area/index.js';export{RouteBasedPluginArea}from'./route-based-plugin-area/route-based-plugin-area.js';export{getRouteBasePlugin,getRouteBasePlugins,registerRouteBasePlugin,unregisterRouteBasePlugin}from'./route-based-plugin-area/plugin-api.js';export{InversifyContext,InversifyProvider,useInjection}from'./inversify/InversifyContext.js';export{getPlugin,getPlugins,registerPlugin,unregisterPlugin}from'./plugin-area/plugin-api.js';//# sourceMappingURL=index.js.map
|
|
1
|
+
export{ClientTypes}from'@common-stack/client-core';export{Feature}from'./connector/connector.js';export{FeatureWithRouterFactory}from'./router-factory/index.js';export{default as resolveRootRoute}from'./route/react-navigation/react-navigation-render.js';export{getNavigation,getSortedNavigations}from'./route/react-navigation/get-navigation-utils.js';export{navigate,navigationRef}from'./route/root-navigation.js';export{sortByPaths,sortKeys}from'./utils/sort-keys.js';export{formatSlash}from'./utils/utils.js';export{combine}from'./utils/combine.js';export{hydrate}from'./utils/hydrate.js';export{beforeSSR}from'./utils/before-ssr.js';export{getAvailableCategories,getAvailableSubCategories,getFilteredMenus,getFilteredRoutes,getFilteredTabs,getMenusByAdvancedFilter,getMenusByCategory,getMenusByCategoryAndSubCategory,getMenusBySubCategory,getMenusBySystemType,getMenusByUserRole,getRoutesByAdvancedFilter,getRoutesByCategory,getRoutesByCategoryAndSubCategory,getRoutesBySubCategory,getRoutesBySystemType,getRoutesByUserRole,getTabsBySystemType,groupRoutesByCategory,groupRoutesByCategoryAndSubCategory}from'./utils/filteredRoutes.js';export{IMenuPosition}from'@common-stack/core/lib/component/interfaces/menu.js';export{PluginArea}from'./plugin-area/index.js';export{RouteBasedPluginArea}from'./route-based-plugin-area/route-based-plugin-area.js';export{getRouteBasePlugin,getRouteBasePlugins,registerRouteBasePlugin,unregisterRouteBasePlugin}from'./route-based-plugin-area/plugin-api.js';export{InversifyContext,InversifyProvider,useInjection}from'./inversify/InversifyContext.js';export{getPlugin,getPlugins,registerPlugin,unregisterPlugin}from'./plugin-area/plugin-api.js';//# sourceMappingURL=index.js.map
|
package/lib/index.native.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ClientTypes}from'@common-stack/client-core';export{Feature}from'./connector/connector.native.js';export{FeatureWithRouterFactory}from'./router-factory/index.native.js';export{navigate,navigationRef}from'./route/react-navigation/root-navigation.js';export{sortByPaths,sortKeys}from'./utils/sort-keys.js';export{formatSlash}from'./utils/utils.js';export{combine}from'./utils/combine.js';export{hydrate}from'./utils/hydrate.js';export{beforeSSR}from'./utils/before-ssr.js';export{getFilteredMenus,getFilteredRoutes,getFilteredTabs}from'./utils/filteredRoutes.js';export{IMenuPosition}from'@common-stack/core/lib/component/interfaces/menu.js';export{PluginArea}from'./plugin-area/index.native.js';export{RouteBasedPluginArea}from'./route-based-plugin-area/route-based-plugin-area.js';export{getRouteBasePlugin,getRouteBasePlugins,registerRouteBasePlugin,unregisterRouteBasePlugin}from'./route-based-plugin-area/plugin-api.js';export{InversifyContext,InversifyProvider,useInjection}from'./inversify/InversifyContext.js';export{getPlugin,getPlugins,registerPlugin,unregisterPlugin}from'./plugin-area/plugin-api.js';//# sourceMappingURL=index.native.js.map
|
|
1
|
+
export{ClientTypes}from'@common-stack/client-core';export{Feature}from'./connector/connector.native.js';export{FeatureWithRouterFactory}from'./router-factory/index.native.js';export{navigate,navigationRef}from'./route/react-navigation/root-navigation.js';export{sortByPaths,sortKeys}from'./utils/sort-keys.js';export{formatSlash}from'./utils/utils.js';export{combine}from'./utils/combine.js';export{hydrate}from'./utils/hydrate.js';export{beforeSSR}from'./utils/before-ssr.js';export{getAvailableCategories,getAvailableSubCategories,getFilteredMenus,getFilteredRoutes,getFilteredTabs,getMenusByAdvancedFilter,getMenusByCategory,getMenusByCategoryAndSubCategory,getMenusBySubCategory,getMenusBySystemType,getMenusByUserRole,getRoutesByAdvancedFilter,getRoutesByCategory,getRoutesByCategoryAndSubCategory,getRoutesBySubCategory,getRoutesBySystemType,getRoutesByUserRole,getTabsBySystemType,groupRoutesByCategory,groupRoutesByCategoryAndSubCategory}from'./utils/filteredRoutes.js';export{IMenuPosition}from'@common-stack/core/lib/component/interfaces/menu.js';export{PluginArea}from'./plugin-area/index.native.js';export{RouteBasedPluginArea}from'./route-based-plugin-area/route-based-plugin-area.js';export{getRouteBasePlugin,getRouteBasePlugins,registerRouteBasePlugin,unregisterRouteBasePlugin}from'./route-based-plugin-area/plugin-api.js';export{InversifyContext,InversifyProvider,useInjection}from'./inversify/InversifyContext.js';export{getPlugin,getPlugins,registerPlugin,unregisterPlugin}from'./plugin-area/plugin-api.js';//# sourceMappingURL=index.native.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -3,4 +3,132 @@ type SelectedType = '*' | string[];
|
|
|
3
3
|
export declare const getFilteredMenus: (accountPageStore: IRouteModule[], selectedMenu?: SelectedType) => IRouteMap[];
|
|
4
4
|
export declare const getFilteredRoutes: (accountPageStore: IRouteModule[], selectedRoutes?: SelectedType) => IRouteMap[];
|
|
5
5
|
export declare const getFilteredTabs: (accountPageStore: IRouteModule[], selectedTabs?: SelectedType) => Omit<IRouteModule, "component">[];
|
|
6
|
+
/**
|
|
7
|
+
* Filter routes by system type (admin vs user visibility)
|
|
8
|
+
* @param accountPageStore - Array of route modules
|
|
9
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
10
|
+
* @returns Filtered routes based on system type
|
|
11
|
+
*/
|
|
12
|
+
export declare const getRoutesBySystemType: (accountPageStore: IRouteModule[], systemType: "system" | "user") => IRouteMap[];
|
|
13
|
+
/**
|
|
14
|
+
* Filter menus by system type (admin vs user visibility)
|
|
15
|
+
* @param accountPageStore - Array of route modules
|
|
16
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
17
|
+
* @returns Filtered menus based on system type
|
|
18
|
+
*/
|
|
19
|
+
export declare const getMenusBySystemType: (accountPageStore: IRouteModule[], systemType: "system" | "user") => IRouteMap[];
|
|
20
|
+
/**
|
|
21
|
+
* Filter tabs by system type (admin vs user visibility)
|
|
22
|
+
* @param accountPageStore - Array of route modules
|
|
23
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
24
|
+
* @returns Filtered tabs based on system type
|
|
25
|
+
*/
|
|
26
|
+
export declare const getTabsBySystemType: (accountPageStore: IRouteModule[], systemType: "system" | "user") => Omit<IRouteModule, "component">[];
|
|
27
|
+
/**
|
|
28
|
+
* Get routes that are accessible by user role (combines system and user types)
|
|
29
|
+
* @param accountPageStore - Array of route modules
|
|
30
|
+
* @param userRole - User role ('admin' sees all, 'user' sees only user type)
|
|
31
|
+
* @returns Routes accessible by the user role
|
|
32
|
+
*/
|
|
33
|
+
export declare const getRoutesByUserRole: (accountPageStore: IRouteModule[], userRole: "admin" | "user") => IRouteMap[];
|
|
34
|
+
/**
|
|
35
|
+
* Get menus that are accessible by user role (combines system and user types)
|
|
36
|
+
* @param accountPageStore - Array of route modules
|
|
37
|
+
* @param userRole - User role ('admin' sees all, 'user' sees only user type)
|
|
38
|
+
* @returns Menus accessible by the user role
|
|
39
|
+
*/
|
|
40
|
+
export declare const getMenusByUserRole: (accountPageStore: IRouteModule[], userRole: "admin" | "user") => IRouteMap[];
|
|
41
|
+
/**
|
|
42
|
+
* Filter routes by category
|
|
43
|
+
* @param accountPageStore - Array of route modules
|
|
44
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
45
|
+
* @returns Filtered routes by category
|
|
46
|
+
*/
|
|
47
|
+
export declare const getRoutesByCategory: (accountPageStore: IRouteModule[], categories?: SelectedType) => IRouteMap[];
|
|
48
|
+
/**
|
|
49
|
+
* Filter routes by sub-category
|
|
50
|
+
* @param accountPageStore - Array of route modules
|
|
51
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
52
|
+
* @returns Filtered routes by sub-category
|
|
53
|
+
*/
|
|
54
|
+
export declare const getRoutesBySubCategory: (accountPageStore: IRouteModule[], subCategories?: SelectedType) => IRouteMap[];
|
|
55
|
+
/**
|
|
56
|
+
* Filter routes by both category and sub-category
|
|
57
|
+
* @param accountPageStore - Array of route modules
|
|
58
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
59
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
60
|
+
* @returns Filtered routes by both category and sub-category
|
|
61
|
+
*/
|
|
62
|
+
export declare const getRoutesByCategoryAndSubCategory: (accountPageStore: IRouteModule[], categories?: SelectedType, subCategories?: SelectedType) => IRouteMap[];
|
|
63
|
+
/**
|
|
64
|
+
* Filter menus by category
|
|
65
|
+
* @param accountPageStore - Array of route modules
|
|
66
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
67
|
+
* @returns Filtered menus by category
|
|
68
|
+
*/
|
|
69
|
+
export declare const getMenusByCategory: (accountPageStore: IRouteModule[], categories?: SelectedType) => IRouteMap[];
|
|
70
|
+
/**
|
|
71
|
+
* Filter menus by sub-category
|
|
72
|
+
* @param accountPageStore - Array of route modules
|
|
73
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
74
|
+
* @returns Filtered menus by sub-category
|
|
75
|
+
*/
|
|
76
|
+
export declare const getMenusBySubCategory: (accountPageStore: IRouteModule[], subCategories?: SelectedType) => IRouteMap[];
|
|
77
|
+
/**
|
|
78
|
+
* Filter menus by both category and sub-category
|
|
79
|
+
* @param accountPageStore - Array of route modules
|
|
80
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
81
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
82
|
+
* @returns Filtered menus by both category and sub-category
|
|
83
|
+
*/
|
|
84
|
+
export declare const getMenusByCategoryAndSubCategory: (accountPageStore: IRouteModule[], categories?: SelectedType, subCategories?: SelectedType) => IRouteMap[];
|
|
85
|
+
/**
|
|
86
|
+
* Get all unique category names from routes
|
|
87
|
+
* @param accountPageStore - Array of route modules
|
|
88
|
+
* @returns Array of unique category names
|
|
89
|
+
*/
|
|
90
|
+
export declare const getAvailableCategories: (accountPageStore: IRouteModule[]) => string[];
|
|
91
|
+
/**
|
|
92
|
+
* Get all unique sub-category names from routes
|
|
93
|
+
* @param accountPageStore - Array of route modules
|
|
94
|
+
* @param filterByCategory - Optional category to filter sub-categories by
|
|
95
|
+
* @returns Array of unique sub-category names
|
|
96
|
+
*/
|
|
97
|
+
export declare const getAvailableSubCategories: (accountPageStore: IRouteModule[], filterByCategory?: string) => string[];
|
|
98
|
+
/**
|
|
99
|
+
* Group routes by category
|
|
100
|
+
* @param accountPageStore - Array of route modules
|
|
101
|
+
* @returns Object with category names as keys and arrays of routes as values
|
|
102
|
+
*/
|
|
103
|
+
export declare const groupRoutesByCategory: (accountPageStore: IRouteModule[]) => Record<string, IRouteModule[]>;
|
|
104
|
+
/**
|
|
105
|
+
* Group routes by sub-category within categories
|
|
106
|
+
* @param accountPageStore - Array of route modules
|
|
107
|
+
* @returns Nested object with category -> sub-category -> routes structure
|
|
108
|
+
*/
|
|
109
|
+
export declare const groupRoutesByCategoryAndSubCategory: (accountPageStore: IRouteModule[]) => Record<string, Record<string, IRouteModule[]>>;
|
|
110
|
+
/**
|
|
111
|
+
* Advanced filtering combining systemType, category, and subCategory
|
|
112
|
+
* @param accountPageStore - Array of route modules
|
|
113
|
+
* @param filters - Object containing all filter criteria
|
|
114
|
+
* @returns Filtered routes matching all specified criteria
|
|
115
|
+
*/
|
|
116
|
+
export declare const getRoutesByAdvancedFilter: (accountPageStore: IRouteModule[], filters: {
|
|
117
|
+
systemType?: "system" | "user";
|
|
118
|
+
categories?: "*" | string[];
|
|
119
|
+
subCategories?: "*" | string[];
|
|
120
|
+
userRole?: "admin" | "user";
|
|
121
|
+
}) => IRouteMap[];
|
|
122
|
+
/**
|
|
123
|
+
* Advanced menu filtering combining systemType, category, and subCategory
|
|
124
|
+
* @param accountPageStore - Array of route modules
|
|
125
|
+
* @param filters - Object containing all filter criteria
|
|
126
|
+
* @returns Filtered menus matching all specified criteria
|
|
127
|
+
*/
|
|
128
|
+
export declare const getMenusByAdvancedFilter: (accountPageStore: IRouteModule[], filters: {
|
|
129
|
+
systemType?: "system" | "user";
|
|
130
|
+
categories?: "*" | string[];
|
|
131
|
+
subCategories?: "*" | string[];
|
|
132
|
+
userRole?: "admin" | "user";
|
|
133
|
+
}) => IRouteMap[];
|
|
6
134
|
export {};
|
|
@@ -28,4 +28,330 @@ const getFilteredTabs = (accountPageStore, selectedTabs = '*') => accountPageSto
|
|
|
28
28
|
}
|
|
29
29
|
return null;
|
|
30
30
|
})
|
|
31
|
-
.filter((valid) => valid);
|
|
31
|
+
.filter((valid) => valid);
|
|
32
|
+
/**
|
|
33
|
+
* Filter routes by system type (admin vs user visibility)
|
|
34
|
+
* @param accountPageStore - Array of route modules
|
|
35
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
36
|
+
* @returns Filtered routes based on system type
|
|
37
|
+
*/
|
|
38
|
+
const getRoutesBySystemType = (accountPageStore, systemType) => accountPageStore
|
|
39
|
+
.map((item) => {
|
|
40
|
+
// If no systemType is specified, treat as 'user' (default visibility)
|
|
41
|
+
const itemSystemType = item.systemType || 'user';
|
|
42
|
+
if (itemSystemType === systemType) {
|
|
43
|
+
const { path } = item;
|
|
44
|
+
return {
|
|
45
|
+
[path]: item,
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
return null;
|
|
49
|
+
})
|
|
50
|
+
.filter((valid) => valid);
|
|
51
|
+
/**
|
|
52
|
+
* Filter menus by system type (admin vs user visibility)
|
|
53
|
+
* @param accountPageStore - Array of route modules
|
|
54
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
55
|
+
* @returns Filtered menus based on system type
|
|
56
|
+
*/
|
|
57
|
+
const getMenusBySystemType = (accountPageStore, systemType) => accountPageStore
|
|
58
|
+
.map((item) => {
|
|
59
|
+
// If no systemType is specified, treat as 'user' (default visibility)
|
|
60
|
+
const itemSystemType = item.systemType || 'user';
|
|
61
|
+
if (itemSystemType === systemType) {
|
|
62
|
+
const { path, component, ...rest } = item;
|
|
63
|
+
return {
|
|
64
|
+
[path]: { name: rest.tab, ...rest },
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
return null;
|
|
68
|
+
})
|
|
69
|
+
.filter((valid) => valid);
|
|
70
|
+
/**
|
|
71
|
+
* Filter tabs by system type (admin vs user visibility)
|
|
72
|
+
* @param accountPageStore - Array of route modules
|
|
73
|
+
* @param systemType - System type to filter by ('system' for admin only, 'user' for common users/owners)
|
|
74
|
+
* @returns Filtered tabs based on system type
|
|
75
|
+
*/
|
|
76
|
+
const getTabsBySystemType = (accountPageStore, systemType) => accountPageStore
|
|
77
|
+
.map((item) => {
|
|
78
|
+
// If no systemType is specified, treat as 'user' (default visibility)
|
|
79
|
+
const itemSystemType = item.systemType || 'user';
|
|
80
|
+
if (itemSystemType === systemType) {
|
|
81
|
+
const { component, ...rest } = item;
|
|
82
|
+
return rest;
|
|
83
|
+
}
|
|
84
|
+
return null;
|
|
85
|
+
})
|
|
86
|
+
.filter((valid) => valid);
|
|
87
|
+
/**
|
|
88
|
+
* Get routes that are accessible by user role (combines system and user types)
|
|
89
|
+
* @param accountPageStore - Array of route modules
|
|
90
|
+
* @param userRole - User role ('admin' sees all, 'user' sees only user type)
|
|
91
|
+
* @returns Routes accessible by the user role
|
|
92
|
+
*/
|
|
93
|
+
const getRoutesByUserRole = (accountPageStore, userRole) => {
|
|
94
|
+
if (userRole === 'admin') {
|
|
95
|
+
// Admin can see all routes (both system and user)
|
|
96
|
+
return getFilteredRoutes(accountPageStore);
|
|
97
|
+
}
|
|
98
|
+
else {
|
|
99
|
+
// Regular users can only see 'user' type routes
|
|
100
|
+
return getRoutesBySystemType(accountPageStore, 'user');
|
|
101
|
+
}
|
|
102
|
+
};
|
|
103
|
+
/**
|
|
104
|
+
* Get menus that are accessible by user role (combines system and user types)
|
|
105
|
+
* @param accountPageStore - Array of route modules
|
|
106
|
+
* @param userRole - User role ('admin' sees all, 'user' sees only user type)
|
|
107
|
+
* @returns Menus accessible by the user role
|
|
108
|
+
*/
|
|
109
|
+
const getMenusByUserRole = (accountPageStore, userRole) => {
|
|
110
|
+
if (userRole === 'admin') {
|
|
111
|
+
// Admin can see all menus (both system and user)
|
|
112
|
+
return getFilteredMenus(accountPageStore);
|
|
113
|
+
}
|
|
114
|
+
else {
|
|
115
|
+
// Regular users can only see 'user' type menus
|
|
116
|
+
return getMenusBySystemType(accountPageStore, 'user');
|
|
117
|
+
}
|
|
118
|
+
};
|
|
119
|
+
/**
|
|
120
|
+
* Filter routes by category
|
|
121
|
+
* @param accountPageStore - Array of route modules
|
|
122
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
123
|
+
* @returns Filtered routes by category
|
|
124
|
+
*/
|
|
125
|
+
const getRoutesByCategory = (accountPageStore, categories = '*') => accountPageStore
|
|
126
|
+
.map((item) => {
|
|
127
|
+
if (categories === '*' || (item.category && categories.includes(item.category))) {
|
|
128
|
+
const { path } = item;
|
|
129
|
+
return {
|
|
130
|
+
[path]: item,
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
return null;
|
|
134
|
+
})
|
|
135
|
+
.filter((valid) => valid);
|
|
136
|
+
/**
|
|
137
|
+
* Filter routes by sub-category
|
|
138
|
+
* @param accountPageStore - Array of route modules
|
|
139
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
140
|
+
* @returns Filtered routes by sub-category
|
|
141
|
+
*/
|
|
142
|
+
const getRoutesBySubCategory = (accountPageStore, subCategories = '*') => accountPageStore
|
|
143
|
+
.map((item) => {
|
|
144
|
+
if (subCategories === '*' || (item.subCategory && subCategories.includes(item.subCategory))) {
|
|
145
|
+
const { path } = item;
|
|
146
|
+
return {
|
|
147
|
+
[path]: item,
|
|
148
|
+
};
|
|
149
|
+
}
|
|
150
|
+
return null;
|
|
151
|
+
})
|
|
152
|
+
.filter((valid) => valid);
|
|
153
|
+
/**
|
|
154
|
+
* Filter routes by both category and sub-category
|
|
155
|
+
* @param accountPageStore - Array of route modules
|
|
156
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
157
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
158
|
+
* @returns Filtered routes by both category and sub-category
|
|
159
|
+
*/
|
|
160
|
+
const getRoutesByCategoryAndSubCategory = (accountPageStore, categories = '*', subCategories = '*') => accountPageStore
|
|
161
|
+
.map((item) => {
|
|
162
|
+
const categoryMatch = categories === '*' || (item.category && categories.includes(item.category));
|
|
163
|
+
const subCategoryMatch = subCategories === '*' || (item.subCategory && subCategories.includes(item.subCategory));
|
|
164
|
+
if (categoryMatch && subCategoryMatch) {
|
|
165
|
+
const { path } = item;
|
|
166
|
+
return {
|
|
167
|
+
[path]: item,
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
return null;
|
|
171
|
+
})
|
|
172
|
+
.filter((valid) => valid);
|
|
173
|
+
/**
|
|
174
|
+
* Filter menus by category
|
|
175
|
+
* @param accountPageStore - Array of route modules
|
|
176
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
177
|
+
* @returns Filtered menus by category
|
|
178
|
+
*/
|
|
179
|
+
const getMenusByCategory = (accountPageStore, categories = '*') => accountPageStore
|
|
180
|
+
.map((item) => {
|
|
181
|
+
if (categories === '*' || (item.category && categories.includes(item.category))) {
|
|
182
|
+
const { path, component, ...rest } = item;
|
|
183
|
+
return {
|
|
184
|
+
[path]: { name: rest.tab, ...rest },
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
return null;
|
|
188
|
+
})
|
|
189
|
+
.filter((valid) => valid);
|
|
190
|
+
/**
|
|
191
|
+
* Filter menus by sub-category
|
|
192
|
+
* @param accountPageStore - Array of route modules
|
|
193
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
194
|
+
* @returns Filtered menus by sub-category
|
|
195
|
+
*/
|
|
196
|
+
const getMenusBySubCategory = (accountPageStore, subCategories = '*') => accountPageStore
|
|
197
|
+
.map((item) => {
|
|
198
|
+
if (subCategories === '*' || (item.subCategory && subCategories.includes(item.subCategory))) {
|
|
199
|
+
const { path, component, ...rest } = item;
|
|
200
|
+
return {
|
|
201
|
+
[path]: { name: rest.tab, ...rest },
|
|
202
|
+
};
|
|
203
|
+
}
|
|
204
|
+
return null;
|
|
205
|
+
})
|
|
206
|
+
.filter((valid) => valid);
|
|
207
|
+
/**
|
|
208
|
+
* Filter menus by both category and sub-category
|
|
209
|
+
* @param accountPageStore - Array of route modules
|
|
210
|
+
* @param categories - Category name(s) to filter by. Use '*' for all categories or array of category names
|
|
211
|
+
* @param subCategories - Sub-category name(s) to filter by. Use '*' for all sub-categories or array of sub-category names
|
|
212
|
+
* @returns Filtered menus by both category and sub-category
|
|
213
|
+
*/
|
|
214
|
+
const getMenusByCategoryAndSubCategory = (accountPageStore, categories = '*', subCategories = '*') => accountPageStore
|
|
215
|
+
.map((item) => {
|
|
216
|
+
const categoryMatch = categories === '*' || (item.category && categories.includes(item.category));
|
|
217
|
+
const subCategoryMatch = subCategories === '*' || (item.subCategory && subCategories.includes(item.subCategory));
|
|
218
|
+
if (categoryMatch && subCategoryMatch) {
|
|
219
|
+
const { path, component, ...rest } = item;
|
|
220
|
+
return {
|
|
221
|
+
[path]: { name: rest.tab, ...rest },
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
return null;
|
|
225
|
+
})
|
|
226
|
+
.filter((valid) => valid);
|
|
227
|
+
/**
|
|
228
|
+
* Get all unique category names from routes
|
|
229
|
+
* @param accountPageStore - Array of route modules
|
|
230
|
+
* @returns Array of unique category names
|
|
231
|
+
*/
|
|
232
|
+
const getAvailableCategories = (accountPageStore) => {
|
|
233
|
+
const categories = accountPageStore
|
|
234
|
+
.map((item) => item.category)
|
|
235
|
+
.filter((category) => Boolean(category));
|
|
236
|
+
return [...new Set(categories)].sort();
|
|
237
|
+
};
|
|
238
|
+
/**
|
|
239
|
+
* Get all unique sub-category names from routes
|
|
240
|
+
* @param accountPageStore - Array of route modules
|
|
241
|
+
* @param filterByCategory - Optional category to filter sub-categories by
|
|
242
|
+
* @returns Array of unique sub-category names
|
|
243
|
+
*/
|
|
244
|
+
const getAvailableSubCategories = (accountPageStore, filterByCategory) => {
|
|
245
|
+
let filteredRoutes = accountPageStore;
|
|
246
|
+
if (filterByCategory) {
|
|
247
|
+
filteredRoutes = accountPageStore.filter((item) => item.category === filterByCategory);
|
|
248
|
+
}
|
|
249
|
+
const subCategories = filteredRoutes
|
|
250
|
+
.map((item) => item.subCategory)
|
|
251
|
+
.filter((subCategory) => Boolean(subCategory));
|
|
252
|
+
return [...new Set(subCategories)].sort();
|
|
253
|
+
};
|
|
254
|
+
/**
|
|
255
|
+
* Group routes by category
|
|
256
|
+
* @param accountPageStore - Array of route modules
|
|
257
|
+
* @returns Object with category names as keys and arrays of routes as values
|
|
258
|
+
*/
|
|
259
|
+
const groupRoutesByCategory = (accountPageStore) => {
|
|
260
|
+
const grouped = {};
|
|
261
|
+
accountPageStore.forEach((item) => {
|
|
262
|
+
const category = item.category || 'default';
|
|
263
|
+
if (!grouped[category]) {
|
|
264
|
+
grouped[category] = [];
|
|
265
|
+
}
|
|
266
|
+
grouped[category].push(item);
|
|
267
|
+
});
|
|
268
|
+
return grouped;
|
|
269
|
+
};
|
|
270
|
+
/**
|
|
271
|
+
* Group routes by sub-category within categories
|
|
272
|
+
* @param accountPageStore - Array of route modules
|
|
273
|
+
* @returns Nested object with category -> sub-category -> routes structure
|
|
274
|
+
*/
|
|
275
|
+
const groupRoutesByCategoryAndSubCategory = (accountPageStore) => {
|
|
276
|
+
const grouped = {};
|
|
277
|
+
accountPageStore.forEach((item) => {
|
|
278
|
+
const category = item.category || 'default';
|
|
279
|
+
const subCategory = item.subCategory || 'default';
|
|
280
|
+
if (!grouped[category]) {
|
|
281
|
+
grouped[category] = {};
|
|
282
|
+
}
|
|
283
|
+
if (!grouped[category][subCategory]) {
|
|
284
|
+
grouped[category][subCategory] = [];
|
|
285
|
+
}
|
|
286
|
+
grouped[category][subCategory].push(item);
|
|
287
|
+
});
|
|
288
|
+
return grouped;
|
|
289
|
+
};
|
|
290
|
+
/**
|
|
291
|
+
* Advanced filtering combining systemType, category, and subCategory
|
|
292
|
+
* @param accountPageStore - Array of route modules
|
|
293
|
+
* @param filters - Object containing all filter criteria
|
|
294
|
+
* @returns Filtered routes matching all specified criteria
|
|
295
|
+
*/
|
|
296
|
+
const getRoutesByAdvancedFilter = (accountPageStore, filters) => {
|
|
297
|
+
return accountPageStore
|
|
298
|
+
.map((item) => {
|
|
299
|
+
const itemSystemType = item.systemType || 'user';
|
|
300
|
+
// System type filter
|
|
301
|
+
const systemTypeMatch = !filters.systemType || itemSystemType === filters.systemType;
|
|
302
|
+
// User role filter (overrides systemType)
|
|
303
|
+
const userRoleMatch = !filters.userRole ||
|
|
304
|
+
filters.userRole === 'admin' ||
|
|
305
|
+
(filters.userRole === 'user' && itemSystemType === 'user');
|
|
306
|
+
// Category filter
|
|
307
|
+
const categoryMatch = !filters.categories ||
|
|
308
|
+
filters.categories === '*' ||
|
|
309
|
+
(item.category && filters.categories.includes(item.category));
|
|
310
|
+
// Sub-category filter
|
|
311
|
+
const subCategoryMatch = !filters.subCategories ||
|
|
312
|
+
filters.subCategories === '*' ||
|
|
313
|
+
(item.subCategory && filters.subCategories.includes(item.subCategory));
|
|
314
|
+
if (systemTypeMatch && userRoleMatch && categoryMatch && subCategoryMatch) {
|
|
315
|
+
const { path } = item;
|
|
316
|
+
return {
|
|
317
|
+
[path]: item,
|
|
318
|
+
};
|
|
319
|
+
}
|
|
320
|
+
return null;
|
|
321
|
+
})
|
|
322
|
+
.filter((valid) => valid);
|
|
323
|
+
};
|
|
324
|
+
/**
|
|
325
|
+
* Advanced menu filtering combining systemType, category, and subCategory
|
|
326
|
+
* @param accountPageStore - Array of route modules
|
|
327
|
+
* @param filters - Object containing all filter criteria
|
|
328
|
+
* @returns Filtered menus matching all specified criteria
|
|
329
|
+
*/
|
|
330
|
+
const getMenusByAdvancedFilter = (accountPageStore, filters) => {
|
|
331
|
+
return accountPageStore
|
|
332
|
+
.map((item) => {
|
|
333
|
+
const itemSystemType = item.systemType || 'user';
|
|
334
|
+
// System type filter
|
|
335
|
+
const systemTypeMatch = !filters.systemType || itemSystemType === filters.systemType;
|
|
336
|
+
// User role filter (overrides systemType)
|
|
337
|
+
const userRoleMatch = !filters.userRole ||
|
|
338
|
+
filters.userRole === 'admin' ||
|
|
339
|
+
(filters.userRole === 'user' && itemSystemType === 'user');
|
|
340
|
+
// Category filter
|
|
341
|
+
const categoryMatch = !filters.categories ||
|
|
342
|
+
filters.categories === '*' ||
|
|
343
|
+
(item.category && filters.categories.includes(item.category));
|
|
344
|
+
// Sub-category filter
|
|
345
|
+
const subCategoryMatch = !filters.subCategories ||
|
|
346
|
+
filters.subCategories === '*' ||
|
|
347
|
+
(item.subCategory && filters.subCategories.includes(item.subCategory));
|
|
348
|
+
if (systemTypeMatch && userRoleMatch && categoryMatch && subCategoryMatch) {
|
|
349
|
+
const { path, component, ...rest } = item;
|
|
350
|
+
return {
|
|
351
|
+
[path]: { name: rest.tab, ...rest },
|
|
352
|
+
};
|
|
353
|
+
}
|
|
354
|
+
return null;
|
|
355
|
+
})
|
|
356
|
+
.filter((valid) => valid);
|
|
357
|
+
};export{getAvailableCategories,getAvailableSubCategories,getFilteredMenus,getFilteredRoutes,getFilteredTabs,getMenusByAdvancedFilter,getMenusByCategory,getMenusByCategoryAndSubCategory,getMenusBySubCategory,getMenusBySystemType,getMenusByUserRole,getRoutesByAdvancedFilter,getRoutesByCategory,getRoutesByCategoryAndSubCategory,getRoutesBySubCategory,getRoutesBySystemType,getRoutesByUserRole,getTabsBySystemType,groupRoutesByCategory,groupRoutesByCategoryAndSubCategory};//# sourceMappingURL=filteredRoutes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filteredRoutes.js","sources":["../../src/utils/filteredRoutes.ts"],"sourcesContent":[null],"names":[],"mappings":"AAKO,MAAM,gBAAgB,GAAG,CAAC,gBAAgC,EAAE,YAAA,GAAe,GAAmB,KACjG,gBAAgB;AACX,KAAA,GAAG,CAAC,CAAC,IAAI,KAAI;AACV,IAAA,IAAI,YAAY,KAAK,GAAG,IAAI,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE;QACzD,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,GAAG,IAAI,CAAC;QAC1C,OAAO;AACH,YAAA,CAAC,IAAI,GAAG,EAAE,IAAI,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,EAAE;SACtC,CAAC;KACL;AACD,IAAA,OAAO,IAAI,CAAC;AAChB,CAAC,CAAC;KACD,MAAM,CAAC,C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1-alpha.
|
|
3
|
+
"version": "7.1.1-alpha.62",
|
|
4
4
|
"description": "Client Module for react app",
|
|
5
5
|
"homepage": "https://github.com/cdmbase/fullstack-pro#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"watch": "npm run build:lib:watch"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@common-stack/client-core": "7.1.1-alpha.
|
|
35
|
-
"@common-stack/core": "7.1.1-alpha.
|
|
34
|
+
"@common-stack/client-core": "7.1.1-alpha.62",
|
|
35
|
+
"@common-stack/core": "7.1.1-alpha.62",
|
|
36
36
|
"@wordpress/hooks": "^3.53.0",
|
|
37
37
|
"browser-bunyan": "^1.6.3",
|
|
38
38
|
"history-with-query": "^4.10.4",
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"publishConfig": {
|
|
58
58
|
"access": "public"
|
|
59
59
|
},
|
|
60
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "b66c8fc2489ff21628b1b0b0ad2ab9ab27f67d59",
|
|
61
61
|
"typescript": {
|
|
62
62
|
"definition": "lib/index.d.ts"
|
|
63
63
|
}
|