@etsoo/react 1.3.79 → 1.3.80

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.
@@ -1,5 +1,5 @@
1
1
  import { CoreApp, createClient } from '@etsoo/appscript';
2
- import { DomUtils, WindowStorage } from '@etsoo/shared';
2
+ import { DomUtils, StorageUtils, WindowStorage } from '@etsoo/shared';
3
3
  import React from 'react';
4
4
  import { NotifierMU } from '../mu/NotifierMU';
5
5
  import { ProgressCount } from '../mu/ProgressCount';
@@ -65,8 +65,12 @@ export class ReactApp extends CoreApp {
65
65
  CoreApp.headerTokenField,
66
66
  CoreApp.serversideDeviceIdField
67
67
  ], (field, data, index) => {
68
- if (index > 0 && field === CoreApp.headerTokenField)
68
+ if (index > 0 && field === CoreApp.headerTokenField) {
69
+ // Clear passphrase to regenerate the device id
70
+ StorageUtils.setSessionData(CoreApp.devicePassphraseField, undefined);
71
+ // Clear token
69
72
  return null;
73
+ }
70
74
  return data;
71
75
  }), name);
72
76
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/react",
3
- "version": "1.3.79",
3
+ "version": "1.3.80",
4
4
  "description": "TypeScript ReactJs framework",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
@@ -50,9 +50,9 @@
50
50
  "@emotion/react": "^11.7.1",
51
51
  "@emotion/style": "^0.8.0",
52
52
  "@emotion/styled": "^11.6.0",
53
- "@etsoo/appscript": "^1.1.96",
53
+ "@etsoo/appscript": "^1.1.97",
54
54
  "@etsoo/notificationbase": "^1.0.95",
55
- "@etsoo/shared": "^1.0.88",
55
+ "@etsoo/shared": "^1.0.89",
56
56
  "@mui/icons-material": "^5.2.5",
57
57
  "@mui/material": "^5.2.5",
58
58
  "@reach/router": "^1.3.4",
@@ -7,7 +7,12 @@ import {
7
7
  IUserData
8
8
  } from '@etsoo/appscript';
9
9
  import { NotificationRenderProps } from '@etsoo/notificationbase';
10
- import { DataTypes, DomUtils, WindowStorage } from '@etsoo/shared';
10
+ import {
11
+ DataTypes,
12
+ DomUtils,
13
+ StorageUtils,
14
+ WindowStorage
15
+ } from '@etsoo/shared';
11
16
  import React from 'react';
12
17
  import { NotifierMU } from '../mu/NotifierMU';
13
18
  import { ProgressCount } from '../mu/ProgressCount';
@@ -201,8 +206,16 @@ export class ReactApp<
201
206
  CoreApp.serversideDeviceIdField
202
207
  ],
203
208
  (field, data, index) => {
204
- if (index > 0 && field === CoreApp.headerTokenField)
209
+ if (index > 0 && field === CoreApp.headerTokenField) {
210
+ // Clear passphrase to regenerate the device id
211
+ StorageUtils.setSessionData(
212
+ CoreApp.devicePassphraseField,
213
+ undefined
214
+ );
215
+
216
+ // Clear token
205
217
  return null;
218
+ }
206
219
  return data;
207
220
  }
208
221
  ),