@etsoo/materialui 1.2.85 → 1.2.86
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/app/ReactApp.d.ts +2 -1
- package/lib/app/ReactApp.js +3 -2
- package/package.json +3 -3
- package/src/app/ReactApp.ts +6 -2
package/lib/app/ReactApp.d.ts
CHANGED
|
@@ -216,8 +216,9 @@ export declare class ReactApp<S extends IAppSettings, D extends IUser, P extends
|
|
|
216
216
|
/**
|
|
217
217
|
* User logout
|
|
218
218
|
* @param clearToken Clear refresh token or not
|
|
219
|
+
* @param noTrigger No trigger for state change
|
|
219
220
|
*/
|
|
220
|
-
userLogout(clearToken?: boolean): void;
|
|
221
|
+
userLogout(clearToken?: boolean, noTrigger?: boolean): void;
|
|
221
222
|
/**
|
|
222
223
|
* User unauthorized
|
|
223
224
|
*/
|
package/lib/app/ReactApp.js
CHANGED
|
@@ -271,12 +271,13 @@ export class ReactApp extends CoreApp {
|
|
|
271
271
|
/**
|
|
272
272
|
* User logout
|
|
273
273
|
* @param clearToken Clear refresh token or not
|
|
274
|
+
* @param noTrigger No trigger for state change
|
|
274
275
|
*/
|
|
275
|
-
userLogout(clearToken = true) {
|
|
276
|
+
userLogout(clearToken = true, noTrigger = false) {
|
|
276
277
|
// Super call
|
|
277
278
|
super.userLogout(clearToken);
|
|
278
279
|
// Dispatch action
|
|
279
|
-
if (this.userStateDispatch != null)
|
|
280
|
+
if (!noTrigger && this.userStateDispatch != null)
|
|
280
281
|
this.userStateDispatch({
|
|
281
282
|
type: UserActionType.Logout
|
|
282
283
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@etsoo/materialui",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.86",
|
|
4
4
|
"description": "TypeScript Material-UI Implementation",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -50,9 +50,9 @@
|
|
|
50
50
|
"@emotion/css": "^11.11.2",
|
|
51
51
|
"@emotion/react": "^11.11.1",
|
|
52
52
|
"@emotion/styled": "^11.11.0",
|
|
53
|
-
"@etsoo/appscript": "^1.4.
|
|
53
|
+
"@etsoo/appscript": "^1.4.32",
|
|
54
54
|
"@etsoo/notificationbase": "^1.1.26",
|
|
55
|
-
"@etsoo/react": "^1.7.
|
|
55
|
+
"@etsoo/react": "^1.7.3",
|
|
56
56
|
"@etsoo/shared": "^1.2.8",
|
|
57
57
|
"@mui/icons-material": "^5.14.3",
|
|
58
58
|
"@mui/material": "^5.14.5",
|
package/src/app/ReactApp.ts
CHANGED
|
@@ -512,13 +512,17 @@ export class ReactApp<
|
|
|
512
512
|
/**
|
|
513
513
|
* User logout
|
|
514
514
|
* @param clearToken Clear refresh token or not
|
|
515
|
+
* @param noTrigger No trigger for state change
|
|
515
516
|
*/
|
|
516
|
-
override userLogout(
|
|
517
|
+
override userLogout(
|
|
518
|
+
clearToken: boolean = true,
|
|
519
|
+
noTrigger: boolean = false
|
|
520
|
+
): void {
|
|
517
521
|
// Super call
|
|
518
522
|
super.userLogout(clearToken);
|
|
519
523
|
|
|
520
524
|
// Dispatch action
|
|
521
|
-
if (this.userStateDispatch != null)
|
|
525
|
+
if (!noTrigger && this.userStateDispatch != null)
|
|
522
526
|
this.userStateDispatch({
|
|
523
527
|
type: UserActionType.Logout
|
|
524
528
|
});
|