@abpjs/identity-pro 2.2.0 → 2.4.0
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.d.mts +27 -1
- package/dist/index.d.ts +27 -1
- package/dist/index.js +26 -0
- package/dist/index.mjs +25 -0
- package/package.json +5 -5
package/dist/index.d.mts
CHANGED
|
@@ -144,6 +144,21 @@ declare namespace Identity {
|
|
|
144
144
|
}
|
|
145
145
|
}
|
|
146
146
|
|
|
147
|
+
/**
|
|
148
|
+
* Identity Pro Component Identifiers
|
|
149
|
+
* Translated from @volo/abp.ng.identity v2.4.0
|
|
150
|
+
*/
|
|
151
|
+
/**
|
|
152
|
+
* Enum for identity component identifiers.
|
|
153
|
+
* Used for component registration and identification.
|
|
154
|
+
* @since 2.4.0
|
|
155
|
+
*/
|
|
156
|
+
declare enum eIdentityComponents {
|
|
157
|
+
Claims = "Identity.ClaimsComponent",
|
|
158
|
+
Roles = "Identity.RolesComponent",
|
|
159
|
+
Users = "Identity.UsersComponent"
|
|
160
|
+
}
|
|
161
|
+
|
|
147
162
|
/**
|
|
148
163
|
* Service for managing identity-related API operations.
|
|
149
164
|
* Handles roles, users, and claim types CRUD operations.
|
|
@@ -156,6 +171,11 @@ declare namespace Identity {
|
|
|
156
171
|
* @since 2.0.0
|
|
157
172
|
*/
|
|
158
173
|
declare class IdentityService {
|
|
174
|
+
/**
|
|
175
|
+
* The API name used for REST requests.
|
|
176
|
+
* @since 2.4.0
|
|
177
|
+
*/
|
|
178
|
+
apiName: string;
|
|
159
179
|
private rest;
|
|
160
180
|
constructor(rest: RestService);
|
|
161
181
|
/**
|
|
@@ -164,6 +184,12 @@ declare class IdentityService {
|
|
|
164
184
|
* @returns Promise with paginated role response
|
|
165
185
|
*/
|
|
166
186
|
getRoles(params?: ABP.PageQueryParams): Promise<Identity.RoleResponse>;
|
|
187
|
+
/**
|
|
188
|
+
* Get all roles without pagination
|
|
189
|
+
* @since 2.4.0
|
|
190
|
+
* @returns Promise with all roles response
|
|
191
|
+
*/
|
|
192
|
+
getAllRoles(): Promise<Identity.RoleResponse>;
|
|
167
193
|
/**
|
|
168
194
|
* Get a role by ID
|
|
169
195
|
* @param id - The role ID
|
|
@@ -1005,4 +1031,4 @@ declare const IDENTITY_POLICIES: {
|
|
|
1005
1031
|
readonly ROLES_DELETE: "AbpIdentity.Roles.Delete";
|
|
1006
1032
|
};
|
|
1007
1033
|
|
|
1008
|
-
export { ClaimModal, type ClaimModalProps, type ClaimOperationResult, ClaimsComponent, type ClaimsComponentProps, IDENTITY_POLICIES, IDENTITY_ROUTES, IDENTITY_ROUTE_PATHS, Identity, IdentityService, IdentityStateService, type RoleOperationResult, RolesComponent, type RolesComponentProps, type SortOrder, type UseClaimsReturn, type UseIdentityReturn, type UseRolesReturn, type UseUsersReturn, type UserOperationResult, UsersComponent, type UsersComponentProps, useClaims, useIdentity, useRoles, useUsers };
|
|
1034
|
+
export { ClaimModal, type ClaimModalProps, type ClaimOperationResult, ClaimsComponent, type ClaimsComponentProps, IDENTITY_POLICIES, IDENTITY_ROUTES, IDENTITY_ROUTE_PATHS, Identity, IdentityService, IdentityStateService, type RoleOperationResult, RolesComponent, type RolesComponentProps, type SortOrder, type UseClaimsReturn, type UseIdentityReturn, type UseRolesReturn, type UseUsersReturn, type UserOperationResult, UsersComponent, type UsersComponentProps, eIdentityComponents, useClaims, useIdentity, useRoles, useUsers };
|
package/dist/index.d.ts
CHANGED
|
@@ -144,6 +144,21 @@ declare namespace Identity {
|
|
|
144
144
|
}
|
|
145
145
|
}
|
|
146
146
|
|
|
147
|
+
/**
|
|
148
|
+
* Identity Pro Component Identifiers
|
|
149
|
+
* Translated from @volo/abp.ng.identity v2.4.0
|
|
150
|
+
*/
|
|
151
|
+
/**
|
|
152
|
+
* Enum for identity component identifiers.
|
|
153
|
+
* Used for component registration and identification.
|
|
154
|
+
* @since 2.4.0
|
|
155
|
+
*/
|
|
156
|
+
declare enum eIdentityComponents {
|
|
157
|
+
Claims = "Identity.ClaimsComponent",
|
|
158
|
+
Roles = "Identity.RolesComponent",
|
|
159
|
+
Users = "Identity.UsersComponent"
|
|
160
|
+
}
|
|
161
|
+
|
|
147
162
|
/**
|
|
148
163
|
* Service for managing identity-related API operations.
|
|
149
164
|
* Handles roles, users, and claim types CRUD operations.
|
|
@@ -156,6 +171,11 @@ declare namespace Identity {
|
|
|
156
171
|
* @since 2.0.0
|
|
157
172
|
*/
|
|
158
173
|
declare class IdentityService {
|
|
174
|
+
/**
|
|
175
|
+
* The API name used for REST requests.
|
|
176
|
+
* @since 2.4.0
|
|
177
|
+
*/
|
|
178
|
+
apiName: string;
|
|
159
179
|
private rest;
|
|
160
180
|
constructor(rest: RestService);
|
|
161
181
|
/**
|
|
@@ -164,6 +184,12 @@ declare class IdentityService {
|
|
|
164
184
|
* @returns Promise with paginated role response
|
|
165
185
|
*/
|
|
166
186
|
getRoles(params?: ABP.PageQueryParams): Promise<Identity.RoleResponse>;
|
|
187
|
+
/**
|
|
188
|
+
* Get all roles without pagination
|
|
189
|
+
* @since 2.4.0
|
|
190
|
+
* @returns Promise with all roles response
|
|
191
|
+
*/
|
|
192
|
+
getAllRoles(): Promise<Identity.RoleResponse>;
|
|
167
193
|
/**
|
|
168
194
|
* Get a role by ID
|
|
169
195
|
* @param id - The role ID
|
|
@@ -1005,4 +1031,4 @@ declare const IDENTITY_POLICIES: {
|
|
|
1005
1031
|
readonly ROLES_DELETE: "AbpIdentity.Roles.Delete";
|
|
1006
1032
|
};
|
|
1007
1033
|
|
|
1008
|
-
export { ClaimModal, type ClaimModalProps, type ClaimOperationResult, ClaimsComponent, type ClaimsComponentProps, IDENTITY_POLICIES, IDENTITY_ROUTES, IDENTITY_ROUTE_PATHS, Identity, IdentityService, IdentityStateService, type RoleOperationResult, RolesComponent, type RolesComponentProps, type SortOrder, type UseClaimsReturn, type UseIdentityReturn, type UseRolesReturn, type UseUsersReturn, type UserOperationResult, UsersComponent, type UsersComponentProps, useClaims, useIdentity, useRoles, useUsers };
|
|
1034
|
+
export { ClaimModal, type ClaimModalProps, type ClaimOperationResult, ClaimsComponent, type ClaimsComponentProps, IDENTITY_POLICIES, IDENTITY_ROUTES, IDENTITY_ROUTE_PATHS, Identity, IdentityService, IdentityStateService, type RoleOperationResult, RolesComponent, type RolesComponentProps, type SortOrder, type UseClaimsReturn, type UseIdentityReturn, type UseRolesReturn, type UseUsersReturn, type UserOperationResult, UsersComponent, type UsersComponentProps, eIdentityComponents, useClaims, useIdentity, useRoles, useUsers };
|
package/dist/index.js
CHANGED
|
@@ -30,6 +30,7 @@ __export(index_exports, {
|
|
|
30
30
|
IdentityStateService: () => IdentityStateService,
|
|
31
31
|
RolesComponent: () => RolesComponent,
|
|
32
32
|
UsersComponent: () => UsersComponent,
|
|
33
|
+
eIdentityComponents: () => eIdentityComponents,
|
|
33
34
|
useClaims: () => useClaims,
|
|
34
35
|
useIdentity: () => useIdentity,
|
|
35
36
|
useRoles: () => useRoles,
|
|
@@ -49,9 +50,22 @@ var Identity;
|
|
|
49
50
|
})(ClaimValueType = Identity2.ClaimValueType || (Identity2.ClaimValueType = {}));
|
|
50
51
|
})(Identity || (Identity = {}));
|
|
51
52
|
|
|
53
|
+
// src/enums/components.ts
|
|
54
|
+
var eIdentityComponents = /* @__PURE__ */ ((eIdentityComponents2) => {
|
|
55
|
+
eIdentityComponents2["Claims"] = "Identity.ClaimsComponent";
|
|
56
|
+
eIdentityComponents2["Roles"] = "Identity.RolesComponent";
|
|
57
|
+
eIdentityComponents2["Users"] = "Identity.UsersComponent";
|
|
58
|
+
return eIdentityComponents2;
|
|
59
|
+
})(eIdentityComponents || {});
|
|
60
|
+
|
|
52
61
|
// src/services/identity.service.ts
|
|
53
62
|
var IdentityService = class {
|
|
54
63
|
constructor(rest) {
|
|
64
|
+
/**
|
|
65
|
+
* The API name used for REST requests.
|
|
66
|
+
* @since 2.4.0
|
|
67
|
+
*/
|
|
68
|
+
this.apiName = "default";
|
|
55
69
|
this.rest = rest;
|
|
56
70
|
}
|
|
57
71
|
// ========================
|
|
@@ -69,6 +83,17 @@ var IdentityService = class {
|
|
|
69
83
|
params
|
|
70
84
|
});
|
|
71
85
|
}
|
|
86
|
+
/**
|
|
87
|
+
* Get all roles without pagination
|
|
88
|
+
* @since 2.4.0
|
|
89
|
+
* @returns Promise with all roles response
|
|
90
|
+
*/
|
|
91
|
+
getAllRoles() {
|
|
92
|
+
return this.rest.request({
|
|
93
|
+
method: "GET",
|
|
94
|
+
url: "/api/identity/roles/all"
|
|
95
|
+
});
|
|
96
|
+
}
|
|
72
97
|
/**
|
|
73
98
|
* Get a role by ID
|
|
74
99
|
* @param id - The role ID
|
|
@@ -2222,6 +2247,7 @@ var IDENTITY_POLICIES = {
|
|
|
2222
2247
|
IdentityStateService,
|
|
2223
2248
|
RolesComponent,
|
|
2224
2249
|
UsersComponent,
|
|
2250
|
+
eIdentityComponents,
|
|
2225
2251
|
useClaims,
|
|
2226
2252
|
useIdentity,
|
|
2227
2253
|
useRoles,
|
package/dist/index.mjs
CHANGED
|
@@ -10,9 +10,22 @@ var Identity;
|
|
|
10
10
|
})(ClaimValueType = Identity2.ClaimValueType || (Identity2.ClaimValueType = {}));
|
|
11
11
|
})(Identity || (Identity = {}));
|
|
12
12
|
|
|
13
|
+
// src/enums/components.ts
|
|
14
|
+
var eIdentityComponents = /* @__PURE__ */ ((eIdentityComponents2) => {
|
|
15
|
+
eIdentityComponents2["Claims"] = "Identity.ClaimsComponent";
|
|
16
|
+
eIdentityComponents2["Roles"] = "Identity.RolesComponent";
|
|
17
|
+
eIdentityComponents2["Users"] = "Identity.UsersComponent";
|
|
18
|
+
return eIdentityComponents2;
|
|
19
|
+
})(eIdentityComponents || {});
|
|
20
|
+
|
|
13
21
|
// src/services/identity.service.ts
|
|
14
22
|
var IdentityService = class {
|
|
15
23
|
constructor(rest) {
|
|
24
|
+
/**
|
|
25
|
+
* The API name used for REST requests.
|
|
26
|
+
* @since 2.4.0
|
|
27
|
+
*/
|
|
28
|
+
this.apiName = "default";
|
|
16
29
|
this.rest = rest;
|
|
17
30
|
}
|
|
18
31
|
// ========================
|
|
@@ -30,6 +43,17 @@ var IdentityService = class {
|
|
|
30
43
|
params
|
|
31
44
|
});
|
|
32
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* Get all roles without pagination
|
|
48
|
+
* @since 2.4.0
|
|
49
|
+
* @returns Promise with all roles response
|
|
50
|
+
*/
|
|
51
|
+
getAllRoles() {
|
|
52
|
+
return this.rest.request({
|
|
53
|
+
method: "GET",
|
|
54
|
+
url: "/api/identity/roles/all"
|
|
55
|
+
});
|
|
56
|
+
}
|
|
33
57
|
/**
|
|
34
58
|
* Get a role by ID
|
|
35
59
|
* @param id - The role ID
|
|
@@ -2220,6 +2244,7 @@ export {
|
|
|
2220
2244
|
IdentityStateService,
|
|
2221
2245
|
RolesComponent,
|
|
2222
2246
|
UsersComponent,
|
|
2247
|
+
eIdentityComponents,
|
|
2223
2248
|
useClaims,
|
|
2224
2249
|
useIdentity,
|
|
2225
2250
|
useRoles,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abpjs/identity-pro",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.4.0",
|
|
4
4
|
"description": "ABP Framework identity pro components for React - translated from @volo/abp.ng.identity",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -27,12 +27,12 @@
|
|
|
27
27
|
"@chakra-ui/react": "^3.2.0",
|
|
28
28
|
"@emotion/react": "^11.11.0",
|
|
29
29
|
"react-icons": "^5.3.0",
|
|
30
|
-
"@abpjs/
|
|
31
|
-
"@abpjs/
|
|
32
|
-
"@abpjs/permission-management": "2.
|
|
30
|
+
"@abpjs/core": "2.4.0",
|
|
31
|
+
"@abpjs/theme-shared": "2.4.0",
|
|
32
|
+
"@abpjs/permission-management": "2.4.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@volo/abp.ng.identity": "2.
|
|
35
|
+
"@volo/abp.ng.identity": "2.4.0",
|
|
36
36
|
"@testing-library/jest-dom": "^6.9.1",
|
|
37
37
|
"@testing-library/react": "^14.0.0",
|
|
38
38
|
"@testing-library/user-event": "^14.6.1",
|