@flatbiz/pro-layout 4.0.1 → 4.0.2
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/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/index.d.ts +28 -2
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -71,10 +71,33 @@ export declare type TAdminUser = null | {
|
|
|
71
71
|
export interface TRouteItemProps {
|
|
72
72
|
path: string;
|
|
73
73
|
element: ReactElement | ComponentType | null;
|
|
74
|
-
redirect?: string
|
|
74
|
+
redirect?: string;
|
|
75
75
|
caseSensitive?: boolean;
|
|
76
76
|
}
|
|
77
77
|
export declare type BootstrapOptions = {
|
|
78
|
+
/**
|
|
79
|
+
* ```
|
|
80
|
+
* 1. 正常用法
|
|
81
|
+
* [{
|
|
82
|
+
* path: '/module/page',
|
|
83
|
+
* element: <Text />
|
|
84
|
+
* },{
|
|
85
|
+
* path: '*',
|
|
86
|
+
* redirect: '/module/page'
|
|
87
|
+
* }]
|
|
88
|
+
*
|
|
89
|
+
* 2. 懒加载用法
|
|
90
|
+
* [{
|
|
91
|
+
* path: '/module/page',
|
|
92
|
+
* element: lazy(() => import(\/* webpackChunkName: "xxx/xxx/module/chunks/page" *\/ './page')),
|
|
93
|
+
* },{
|
|
94
|
+
* path: '*',
|
|
95
|
+
* redirect: '/module/page'
|
|
96
|
+
* }]
|
|
97
|
+
*
|
|
98
|
+
* 3. 如果配置中 没有path = '*',程序会在路由中添加 <Route path="*" element={<NotFound />} />
|
|
99
|
+
* ```
|
|
100
|
+
*/
|
|
78
101
|
routeList: TRouteItemProps[];
|
|
79
102
|
breads?: BreadsData;
|
|
80
103
|
/**
|
|
@@ -208,6 +231,10 @@ export declare type BootstrapOptions = {
|
|
|
208
231
|
* 是否隐藏侧边栏中收缩按键
|
|
209
232
|
*/
|
|
210
233
|
hideSidebarShrink?: boolean;
|
|
234
|
+
/**
|
|
235
|
+
* 自定义全局风格
|
|
236
|
+
* 如果项目通过本地引入源代码的方式,此配置不生效
|
|
237
|
+
*/
|
|
211
238
|
configProviderProps?: ConfigProviderProps;
|
|
212
239
|
/**
|
|
213
240
|
* 配置theme后 sidebarThemeConfig 配置失效
|
|
@@ -268,7 +295,6 @@ export declare type IframeHandler<T = unknown> = (data: T) => void;
|
|
|
268
295
|
* @example
|
|
269
296
|
* ```tsx
|
|
270
297
|
* const iframeApi = useIframe<MessageData>((data) => {
|
|
271
|
-
* console.log('onMainMessageReceived', data.name);
|
|
272
298
|
* updateMessage(data);
|
|
273
299
|
* });
|
|
274
300
|
*
|