@vtj/renderer 0.8.168 → 0.8.170
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +5 -5
- package/dist/index.mjs +275 -248
- package/package.json +5 -5
- package/types/plugins/access.d.ts +11 -2
- package/types/version.d.ts +2 -2
package/package.json
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
{
|
2
2
|
"name": "@vtj/renderer",
|
3
3
|
"private": false,
|
4
|
-
"version": "0.8.
|
4
|
+
"version": "0.8.170",
|
5
5
|
"type": "module",
|
6
6
|
"dependencies": {
|
7
7
|
"mockjs": "~1.1.0",
|
8
|
-
"@vtj/core": "~0.8.
|
9
|
-
"@vtj/
|
10
|
-
"@vtj/
|
11
|
-
"@vtj/
|
8
|
+
"@vtj/core": "~0.8.170",
|
9
|
+
"@vtj/icons": "~0.8.170",
|
10
|
+
"@vtj/utils": "~0.8.170",
|
11
|
+
"@vtj/ui": "~0.8.170"
|
12
12
|
},
|
13
13
|
"devDependencies": {
|
14
14
|
"vue": "~3.5.5",
|
@@ -51,7 +51,14 @@ export interface AccessOptions {
|
|
51
51
|
* @returns
|
52
52
|
*/
|
53
53
|
alert?: (message: string, options: Record<string, any>) => Promise<any>;
|
54
|
+
/**
|
55
|
+
* 未登录提示文本
|
56
|
+
*/
|
54
57
|
unauthorizedMessage?: string;
|
58
|
+
/**
|
59
|
+
* 密钥
|
60
|
+
*/
|
61
|
+
crypto?: string;
|
55
62
|
}
|
56
63
|
export interface AccessData {
|
57
64
|
token: string;
|
@@ -79,17 +86,19 @@ export declare class Access {
|
|
79
86
|
private mode?;
|
80
87
|
constructor(options: Partial<AccessOptions>);
|
81
88
|
connect(params: AccessConnectParams): void;
|
82
|
-
login(data: AccessData): void;
|
89
|
+
login(data: AccessData | string): void;
|
83
90
|
clear(): void;
|
84
91
|
logout(): void;
|
85
92
|
getData(): AccessData | null;
|
86
|
-
can(code: string | string[]): boolean;
|
93
|
+
can(code: string | string[] | ((p: Record<string, boolean>) => boolean)): boolean;
|
87
94
|
some(code: string | string[]): boolean;
|
88
95
|
install(app: App): void;
|
89
96
|
private isAuthPath;
|
90
97
|
private toLogin;
|
98
|
+
private setData;
|
91
99
|
private loadData;
|
92
100
|
private isLogined;
|
101
|
+
private hasRoutePermission;
|
93
102
|
private setGuard;
|
94
103
|
private guard;
|
95
104
|
private isWhiteList;
|
package/types/version.d.ts
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
* Copyright (c) 2024, VTJ.PRO All rights reserved.
|
3
3
|
* @name @vtj/renderer
|
4
4
|
* @author CHC chenhuachun1549@dingtalk.com
|
5
|
-
* @version 0.8.
|
5
|
+
* @version 0.8.169
|
6
6
|
* @license <a href="https://vtj.pro/license.html">MIT License</a>
|
7
7
|
*/
|
8
|
-
export declare const version = "0.8.
|
8
|
+
export declare const version = "0.8.169";
|