@nocobase/client-v2 3.0.0-alpha.3 → 3.0.0-alpha.5
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/es/acl/aclCheckReadiness.d.ts +11 -0
- package/es/authRedirect.d.ts +6 -2
- package/es/index.d.ts +2 -1
- package/es/index.mjs +60 -60
- package/es/nocobase-buildin-plugin/index.d.ts +1 -0
- package/es/settings-app/SettingsGroupNav.d.ts +3 -2
- package/es/settings-app/SettingsSearch.d.ts +1 -1
- package/es/ui-operation/index.d.ts +15 -0
- package/es/ui-operation/ui-operation-codec.d.ts +10 -0
- package/lib/index.js +65 -65
- package/package.json +7 -7
- package/src/__tests__/authRedirect.test.ts +17 -0
- package/src/__tests__/browserChecker.test.ts +44 -33
- package/src/__tests__/nocobase-buildin-plugin-auth.test.tsx +37 -0
- package/src/__tests__/settings-center.test.tsx +110 -10
- package/src/__tests__/settings-layout-root.test.tsx +346 -6
- package/src/__tests__/settings-runtime-paths.test.ts +1 -1
- package/src/__tests__/settings-search-shortcut.test.tsx +321 -0
- package/src/__tests__/settings-shell.test.tsx +35 -0
- package/src/acl/ACLProvider.tsx +32 -3
- package/src/acl/aclCheckReadiness.ts +44 -0
- package/src/authRedirect.ts +13 -5
- package/src/flow/models/base/CollectionBlockModel.tsx +9 -0
- package/src/flow/models/base/__tests__/CollectionBlockModel.initialBeforeRenderRefresh.test.ts +60 -0
- package/src/index.ts +2 -0
- package/src/layout-manager/LayoutContentRoute.tsx +2 -1
- package/src/layout-manager/LayoutRoute.tsx +2 -1
- package/src/layout-manager/__tests__/LayoutRoute.test.tsx +87 -1
- package/src/nocobase-buildin-plugin/index.tsx +14 -1
- package/src/settings-app/SettingsGroupNav.tsx +11 -11
- package/src/settings-app/SettingsSearch.tsx +115 -10
- package/src/settings-app/SettingsShell.tsx +4 -2
- package/src/settings-app/runtimePaths.ts +0 -1
- package/src/settings-app/settingsTheme.ts +82 -14
- package/src/settings-center/AdminSettingsLayout.tsx +96 -106
- package/src/ui-operation/index.ts +33 -0
- package/src/ui-operation/ui-operation-codec.ts +54 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
export declare function getACLCheckReady(app: object): boolean;
|
|
10
|
+
export declare function setACLCheckReady(app: object, ready: boolean): void;
|
|
11
|
+
export declare function useACLCheckReady(app: object): boolean;
|
package/es/authRedirect.d.ts
CHANGED
|
@@ -50,18 +50,22 @@ export declare function getCurrentV2RedirectPath(app: AppLike, locationLike: Loc
|
|
|
50
50
|
*
|
|
51
51
|
* @param app 当前 v2 应用实例
|
|
52
52
|
* @param targetPath 登录后回跳地址
|
|
53
|
+
* @param options 可选的登录路由配置
|
|
53
54
|
* @returns 指向 v2 登录页的 href
|
|
54
55
|
*/
|
|
55
|
-
export declare function buildV2SigninHref(app: AppLike, targetPath: string
|
|
56
|
+
export declare function buildV2SigninHref(app: AppLike, targetPath: string, options?: {
|
|
57
|
+
signInRoutePath?: string;
|
|
58
|
+
}): string;
|
|
56
59
|
/**
|
|
57
60
|
* 通过整页跳转进入 v2 登录页。
|
|
58
61
|
*
|
|
59
62
|
* @param app 当前 v2 应用实例
|
|
60
63
|
* @param targetPath 登录后回跳地址
|
|
61
|
-
* @param options
|
|
64
|
+
* @param options 跳转和登录路由选项
|
|
62
65
|
*/
|
|
63
66
|
export declare function redirectToV2Signin(app: AppLike, targetPath: string, options?: {
|
|
64
67
|
replace?: boolean;
|
|
68
|
+
signInRoutePath?: string;
|
|
65
69
|
}): void;
|
|
66
70
|
/**
|
|
67
71
|
* 解析并校验服务端返回的 v2 登录页地址。
|
package/es/index.d.ts
CHANGED
|
@@ -27,7 +27,7 @@ export * from './PluginSettingsManager';
|
|
|
27
27
|
export * from './layout-manager';
|
|
28
28
|
export * from './hooks';
|
|
29
29
|
export { default as languageCodes } from './locale/languageCodes';
|
|
30
|
-
export { CurrentUserContext, NocoBaseBuildInPlugin, NocoBaseBuildInPluginV2, useCurrentRoles, useCurrentUserContext, } from './nocobase-buildin-plugin';
|
|
30
|
+
export { CurrentUserContext, NocoBaseBuildInPlugin, NocoBaseBuildInPluginV2, resolveUnauthenticatedSignInRoute, useCurrentRoles, useCurrentUserContext, } from './nocobase-buildin-plugin';
|
|
31
31
|
export type { CurrentRoleOption, CurrentUserState } from './nocobase-buildin-plugin';
|
|
32
32
|
export { getRouteRuntimeVersion } from './utils/getRouteRuntimeVersion';
|
|
33
33
|
export type { RouteRuntimeVersion } from './utils/getRouteRuntimeVersion';
|
|
@@ -46,6 +46,7 @@ export type { CodeEditorExtra, CodeEditorExtraRegistry, EditorRef } from './flow
|
|
|
46
46
|
export { DEFAULT_DATA_SOURCE_KEY, IconPicker, isTitleField, isTitleFieldInterface, NocoBaseDesktopRouteType, } from './flow-compat';
|
|
47
47
|
export type { NocoBaseDesktopRoute } from './flow-compat';
|
|
48
48
|
export * from './utils/markdownSanitize';
|
|
49
|
+
export * from './ui-operation';
|
|
49
50
|
export { default as AntdAppProvider } from './theme/AntdAppProvider';
|
|
50
51
|
export { isSettingsApp } from './settings-app/isSettingsApp';
|
|
51
52
|
export { MINIMAL_THEME_UID, useSettingsThemeConfig } from './settings-app/useSettingsThemeConfig';
|