asab_webui_shell 27.8.4 → 28.0.0-alpha.1
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/actions.js +15 -15
- package/dist/components/branding/BrandImage.js +3 -5
- package/dist/components/locationReplace.js +5 -11
- package/dist/config/ConfigReducer.js +2 -4
- package/dist/config/ConfigService.js +7 -10
- package/dist/containers/Alerts/index.js +34 -45
- package/dist/containers/Alerts/reducer.js +19 -20
- package/dist/containers/Application.js +200 -207
- package/dist/containers/FullscreenMode/reducer.js +5 -10
- package/dist/containers/Header/ApplicationScreenTitle/ApplicationScreenTitle.js +27 -32
- package/dist/containers/Header/ApplicationScreenTitle/index.js +8 -10
- package/dist/containers/Header/Help/HelpButton.js +58 -55
- package/dist/containers/Header/Help/HelpService.js +3 -4
- package/dist/containers/Header/index.js +23 -23
- package/dist/containers/Header/reducer.js +13 -15
- package/dist/containers/Navigation/index.js +4 -6
- package/dist/containers/Navigation/reducer.js +7 -11
- package/dist/containers/RouteErrorHandler/ErrorContainer.js +47 -31
- package/dist/containers/RouteErrorHandler/index.js +26 -27
- package/dist/containers/Router/ApplicationHashRouter.js +7 -8
- package/dist/containers/Router/ApplicationRouter.js +38 -38
- package/dist/containers/Router/index.js +2 -4
- package/dist/containers/Router/reducer.js +7 -11
- package/dist/containers/Sidebar/NavbarBrand.js +30 -38
- package/dist/containers/Sidebar/SidebarBottomItem.js +42 -36
- package/dist/containers/Sidebar/SidebarIcon.js +12 -9
- package/dist/containers/Sidebar/SidebarItem.js +161 -148
- package/dist/containers/Sidebar/SidebarItemRenderer.js +25 -26
- package/dist/containers/Sidebar/index.js +55 -70
- package/dist/containers/Sidebar/reducer.js +7 -11
- package/dist/containers/Sidebar/utils/sidebarRouteMatch.js +13 -16
- package/dist/containers/Sidebar/utils/sidebarRouteMatch.jsx +4 -1
- package/dist/containers/Sidepanel/Sidepanel.js +35 -40
- package/dist/containers/Toast/ToastComponent.js +21 -15
- package/dist/containers/Toast/ToastContainer.js +23 -32
- package/dist/containers/Toast/reducer.js +14 -16
- package/dist/index.js +10 -10
- package/dist/modules/about/AboutScreen.js +80 -65
- package/dist/modules/about/index.js +3 -3
- package/dist/modules/attentionrequired/attentionRequiredReducer.js +5 -10
- package/dist/modules/attentionrequired/components/OfflineIndication.js +9 -7
- package/dist/modules/attentionrequired/connectivityReducer.js +5 -10
- package/dist/modules/attentionrequired/index.js +2 -3
- package/dist/modules/attentionrequired/service.js +21 -24
- package/dist/modules/auth/actions.js +1 -1
- package/dist/modules/auth/api.js +53 -61
- package/dist/modules/auth/components/LoginLoopCard.js +24 -15
- package/dist/modules/auth/components/SessionExpirationAlert.js +26 -18
- package/dist/modules/auth/header.js +69 -62
- package/dist/modules/auth/index.js +418 -458
- package/dist/modules/auth/reducer.js +11 -14
- package/dist/modules/auth/screens/AccessControlScreen.js +71 -50
- package/dist/modules/i18n/actions.js +1 -1
- package/dist/modules/i18n/dropdown.js +52 -46
- package/dist/modules/i18n/escapeHtmlMinimal.js +2 -2
- package/dist/modules/i18n/index.js +2 -2
- package/dist/modules/i18n/reducer.js +5 -10
- package/dist/modules/i18n/service.js +52 -73
- package/dist/modules/invite/InvitationScreen.js +162 -138
- package/dist/modules/invite/index.js +5 -4
- package/dist/modules/tenant/TenantDropdown.js +52 -58
- package/dist/modules/tenant/access/AccessDeniedCard.js +52 -52
- package/dist/modules/tenant/actions.js +1 -1
- package/dist/modules/tenant/index.js +2 -2
- package/dist/modules/tenant/reducer.js +2 -4
- package/dist/modules/tenant/service.js +74 -91
- package/dist/screens/InvalidRouteScreen.js +30 -20
- package/dist/screens/SuspenseScreen.js +26 -24
- package/dist/screens/UnauthorizedAccessScreen.js +44 -33
- package/dist/screens/UnsupportedBrowserScreen.js +44 -38
- package/dist/services/BrandingService.js +16 -24
- package/dist/services/HeaderService.js +4 -7
- package/dist/services/TitleService.js +19 -20
- package/dist/theme/ThemeButton.js +18 -14
- package/dist/theme/ThemeReducer.js +3 -5
- package/dist/theme/ThemeService.js +6 -8
- package/dist/theme/actions.js +1 -1
- package/dist/utils/browserSupport.js +18 -23
- package/dist/utils/extractTenantFromUrl.js +3 -3
- package/dist/utils/jsonParseWithBigInt.js +10 -9
- package/dist/utils/pageLifecycle.js +5 -5
- package/dist/utils/statusAlerts.js +1 -1
- package/package.json +12 -12
package/dist/actions.js
CHANGED
|
@@ -4,18 +4,18 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.SET_SUBTITLE = exports.SET_ROUTES = exports.SET_NAVIGATION_ITEMS = exports.SET_HELP_PATH = exports.SET_HEADER_NAVIGATION_ITEMS = exports.SET_FULLSCREEN_MODE = exports.SET_CONNECTIVITY_STATUS = exports.SET_ATTENTION_REQUIRED_BEACON = exports.DEL_TOAST = exports.DEL_ALERT = exports.COLLAPSE_SIDEBAR = exports.CHANGE_CONFIG = exports.ADD_TOAST = exports.ADD_ALERT = exports.ACK_ALERT = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
7
|
+
const ADD_ALERT = exports.ADD_ALERT = "asab/addAlert";
|
|
8
|
+
const ACK_ALERT = exports.ACK_ALERT = "asab/ackAlert";
|
|
9
|
+
const DEL_ALERT = exports.DEL_ALERT = "asab/delAlert";
|
|
10
|
+
const ADD_TOAST = exports.ADD_TOAST = "asab/addToast";
|
|
11
|
+
const DEL_TOAST = exports.DEL_TOAST = "asab/delToast";
|
|
12
|
+
const SET_HELP_PATH = exports.SET_HELP_PATH = "asab/setHelpContent";
|
|
13
|
+
const SET_SUBTITLE = exports.SET_SUBTITLE = "asab/setSubtitle";
|
|
14
|
+
const SET_FULLSCREEN_MODE = exports.SET_FULLSCREEN_MODE = "asab/setFullscreenMode";
|
|
15
|
+
const CHANGE_CONFIG = exports.CHANGE_CONFIG = "asab/changeConfig";
|
|
16
|
+
const COLLAPSE_SIDEBAR = exports.COLLAPSE_SIDEBAR = "asab/collapseSidebar";
|
|
17
|
+
const SET_NAVIGATION_ITEMS = exports.SET_NAVIGATION_ITEMS = "asab/setNavigationItems";
|
|
18
|
+
const SET_ROUTES = exports.SET_ROUTES = "asab/setRoutes";
|
|
19
|
+
const SET_HEADER_NAVIGATION_ITEMS = exports.SET_HEADER_NAVIGATION_ITEMS = "asab/setHeaderNavigationItems";
|
|
20
|
+
const SET_CONNECTIVITY_STATUS = exports.SET_CONNECTIVITY_STATUS = "asab/setConnectivityStatus";
|
|
21
|
+
const SET_ATTENTION_REQUIRED_BEACON = exports.SET_ATTENTION_REQUIRED_BEACON = "asab/setAttentionRequiredBeacon";
|
|
@@ -59,11 +59,9 @@ Then, if selected configuration's brand image is not complete (e.g. minimized va
|
|
|
59
59
|
```
|
|
60
60
|
*/
|
|
61
61
|
|
|
62
|
-
function getBrandImage(props) {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
var BrandingService = props.app.Services.BrandingService;
|
|
66
|
-
var brandImage;
|
|
62
|
+
function getBrandImage(props, theme = 'light', type = "brandImage") {
|
|
63
|
+
const BrandingService = props.app.Services.BrandingService;
|
|
64
|
+
let brandImage;
|
|
67
65
|
if (BrandingService && theme) {
|
|
68
66
|
brandImage = BrandingService.getLogo(theme, type);
|
|
69
67
|
}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.locationReplace = void 0;
|
|
8
|
-
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
9
7
|
/*
|
|
10
8
|
|
|
11
9
|
Use only within async functions as per example below.
|
|
@@ -28,12 +26,8 @@ const myFunc = async () => {
|
|
|
28
26
|
|
|
29
27
|
*/
|
|
30
28
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
return function locationReplace(_x) {
|
|
37
|
-
return _ref.apply(this, arguments);
|
|
38
|
-
};
|
|
39
|
-
}();
|
|
29
|
+
const locationReplace = async url => {
|
|
30
|
+
window.location.replace(url.toString());
|
|
31
|
+
await new Promise(r => setTimeout(r, 3600 * 1000)); // Basically wait forever, this the app is going to be reloaded
|
|
32
|
+
};
|
|
33
|
+
exports.locationReplace = locationReplace;
|
|
@@ -7,10 +7,8 @@ exports.default = ConfigReducer;
|
|
|
7
7
|
var _actions = require("../actions");
|
|
8
8
|
// Actions
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
function ConfigReducer() {
|
|
12
|
-
var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : initialState;
|
|
13
|
-
var action = arguments.length > 1 ? arguments[1] : undefined;
|
|
10
|
+
const initialState = {};
|
|
11
|
+
function ConfigReducer(state = initialState, action) {
|
|
14
12
|
switch (action.type) {
|
|
15
13
|
case _actions.CHANGE_CONFIG:
|
|
16
14
|
{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
@@ -9,14 +9,12 @@ var _asab_webui_components = require("asab_webui_components");
|
|
|
9
9
|
var _ConfigReducer = _interopRequireDefault(require("./ConfigReducer"));
|
|
10
10
|
var _actions = require("../actions");
|
|
11
11
|
class ConfigService extends _asab_webui_components.Service {
|
|
12
|
-
constructor(app) {
|
|
13
|
-
var serviceName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "ConfigService";
|
|
12
|
+
constructor(app, serviceName = "ConfigService") {
|
|
14
13
|
super(app, serviceName);
|
|
15
14
|
app.ReduxService.addReducer("config", _ConfigReducer.default);
|
|
16
15
|
this.Config = new Config();
|
|
17
16
|
}
|
|
18
17
|
initialize() {
|
|
19
|
-
var _document$getElements, _document$getElements2;
|
|
20
18
|
/*
|
|
21
19
|
Initialization of dynamic configuration
|
|
22
20
|
Dynamic branding of the header logo can be done via nginx location configuration.
|
|
@@ -32,9 +30,9 @@ class ConfigService extends _asab_webui_components.Service {
|
|
|
32
30
|
}
|
|
33
31
|
...
|
|
34
32
|
*/
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
33
|
+
const title = document.getElementsByName('title')[0]?.content;
|
|
34
|
+
const customCSS = document.getElementsByName('custom-css-file')[0]?.content;
|
|
35
|
+
let dynamicConfig = {};
|
|
38
36
|
|
|
39
37
|
// Add custom title
|
|
40
38
|
if (title != undefined && title != "") {
|
|
@@ -42,7 +40,7 @@ class ConfigService extends _asab_webui_components.Service {
|
|
|
42
40
|
}
|
|
43
41
|
// Add custom CSS
|
|
44
42
|
if (customCSS != undefined && customCSS != "") {
|
|
45
|
-
|
|
43
|
+
const link = document.createElement('link');
|
|
46
44
|
link.setAttribute('rel', 'stylesheet');
|
|
47
45
|
link.setAttribute('href', customCSS);
|
|
48
46
|
// Append to the `head` element
|
|
@@ -112,9 +110,8 @@ class Config {
|
|
|
112
110
|
return undefined;
|
|
113
111
|
}
|
|
114
112
|
dispatch(store) {
|
|
115
|
-
var _store$dispatch;
|
|
116
113
|
var config = Object.assign({}, this._defaults, this._local_config, this._dynamic_config);
|
|
117
|
-
store
|
|
114
|
+
store?.dispatch?.({
|
|
118
115
|
type: _actions.CHANGE_CONFIG,
|
|
119
116
|
config: config
|
|
120
117
|
});
|
|
@@ -1,52 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports.default = AlertsComponent;
|
|
8
|
-
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
9
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
10
9
|
var _asab_webui_components = require("asab_webui_components");
|
|
11
10
|
var _reactstrap = require("reactstrap");
|
|
12
11
|
var _actions = require("../../actions");
|
|
13
12
|
var _reactI18next = require("react-i18next");
|
|
14
13
|
require("./alerts.scss");
|
|
15
|
-
var
|
|
16
|
-
function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var r, c, a = Object.defineProperty, n = { __proto__: null, default: e }; if (Object(e) !== e) return n; if (cache || "function" != typeof WeakMap || (cache = new WeakMap()), cache) { if (cache.has(e)) return cache.get(e); cache.set(e, n); } for (c in e) "default" !== c && {}.hasOwnProperty.call(e, c) && ((r = a && Object.getOwnPropertyDescriptor(e, c)) && (r.get || r.set) ? a(n, c, r) : n[c] = e[c]); return n; }
|
|
14
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
15
|
function AlertsComponent(props) {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
var _state$auth;
|
|
26
|
-
return (_state$auth = state.auth) === null || _state$auth === void 0 ? void 0 : _state$auth.sessionExpired;
|
|
27
|
-
});
|
|
28
|
-
var _useTranslation = (0, _reactI18next.useTranslation)(),
|
|
29
|
-
t = _useTranslation.t;
|
|
16
|
+
const [seconds, setSeconds] = (0, _react.useState)(0);
|
|
17
|
+
const store = props.app.AppStore;
|
|
18
|
+
const alerts = (0, _asab_webui_components.useAppSelector)(state => state.alerts.alerts);
|
|
19
|
+
const sessionExpired = (0, _asab_webui_components.useAppSelector)(state => state.auth?.sessionExpired);
|
|
20
|
+
const {
|
|
21
|
+
t
|
|
22
|
+
} = (0, _reactI18next.useTranslation)();
|
|
30
23
|
|
|
31
24
|
// Expire old alerts
|
|
32
25
|
(0, _react.useEffect)(() => {
|
|
33
26
|
// There is probably smarter way how to set interval to avoid speculative ticking
|
|
34
|
-
|
|
35
|
-
|
|
27
|
+
const interval = 1000;
|
|
28
|
+
const intervalId = setTimeout(() => {
|
|
36
29
|
setSeconds(seconds => seconds + 1);
|
|
37
|
-
|
|
38
|
-
for (
|
|
39
|
-
|
|
30
|
+
const now = new Date();
|
|
31
|
+
for (const i in alerts) {
|
|
32
|
+
let alert = alerts[i];
|
|
40
33
|
if (alert.expire < now) {
|
|
41
34
|
if (alert.acked) {
|
|
42
|
-
|
|
43
|
-
store === null || store === void 0 || (_store$dispatch = store.dispatch) === null || _store$dispatch === void 0 || _store$dispatch.call(store, {
|
|
35
|
+
store?.dispatch?.({
|
|
44
36
|
type: _actions.DEL_ALERT,
|
|
45
37
|
key: alert.key
|
|
46
38
|
});
|
|
47
39
|
} else {
|
|
48
|
-
|
|
49
|
-
store === null || store === void 0 || (_store$dispatch2 = store.dispatch) === null || _store$dispatch2 === void 0 || _store$dispatch2.call(store, {
|
|
40
|
+
store?.dispatch?.({
|
|
50
41
|
type: _actions.ACK_ALERT,
|
|
51
42
|
key: alert.key
|
|
52
43
|
});
|
|
@@ -58,27 +49,25 @@ function AlertsComponent(props) {
|
|
|
58
49
|
clearInterval(intervalId);
|
|
59
50
|
};
|
|
60
51
|
}, [seconds]);
|
|
61
|
-
return /*#__PURE__*/
|
|
52
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
62
53
|
id: "alerts",
|
|
63
|
-
className: sessionExpired ? 'session-expired' : undefined
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
toggle: () => {
|
|
73
|
-
var _store$dispatch3;
|
|
74
|
-
return store === null || store === void 0 || (_store$dispatch3 = store.dispatch) === null || _store$dispatch3 === void 0 ? void 0 : _store$dispatch3.call(store, {
|
|
54
|
+
className: sessionExpired ? 'session-expired' : undefined,
|
|
55
|
+
children: alerts.map(alert => {
|
|
56
|
+
if (alert.component === null) {
|
|
57
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactstrap.Alert, {
|
|
58
|
+
color: alert.level,
|
|
59
|
+
className: `shadow alerts-style d-print-none`,
|
|
60
|
+
fade: true,
|
|
61
|
+
isOpen: !alert.acked,
|
|
62
|
+
toggle: () => store?.dispatch?.({
|
|
75
63
|
type: _actions.ACK_ALERT,
|
|
76
64
|
key: alert.key
|
|
77
|
-
})
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
65
|
+
}),
|
|
66
|
+
children: alert.shouldBeTranslated ? t(alert.message) : alert.message
|
|
67
|
+
}, alert.key);
|
|
68
|
+
} else {
|
|
69
|
+
return alert.component(alert, store);
|
|
70
|
+
}
|
|
71
|
+
})
|
|
72
|
+
});
|
|
84
73
|
}
|
|
@@ -1,26 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.default = alertsReducer;
|
|
8
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
7
|
var _actions = require("../../actions");
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
// Actions
|
|
9
|
+
|
|
10
|
+
const initialState = {
|
|
13
11
|
alerts: []
|
|
14
12
|
};
|
|
15
|
-
function alertsReducer() {
|
|
16
|
-
var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : initialState;
|
|
17
|
-
var action = arguments.length > 1 ? arguments[1] : undefined;
|
|
13
|
+
function alertsReducer(state = initialState, action) {
|
|
18
14
|
switch (action.type) {
|
|
19
15
|
case _actions.ADD_ALERT:
|
|
20
16
|
{
|
|
21
17
|
var expire = new Date();
|
|
22
18
|
expire.setSeconds(expire.getSeconds() + action.expire);
|
|
23
|
-
|
|
19
|
+
const newAlert = {
|
|
24
20
|
key: Math.floor(Math.random() * 65536),
|
|
25
21
|
message: action.message,
|
|
26
22
|
level: action.level,
|
|
@@ -29,27 +25,29 @@ function alertsReducer() {
|
|
|
29
25
|
shouldBeTranslated: action.shouldBeTranslated,
|
|
30
26
|
component: action.component
|
|
31
27
|
};
|
|
32
|
-
return
|
|
28
|
+
return {
|
|
29
|
+
...state,
|
|
33
30
|
alerts: [...state.alerts, newAlert]
|
|
34
|
-
}
|
|
31
|
+
};
|
|
35
32
|
}
|
|
36
33
|
case _actions.DEL_ALERT:
|
|
37
34
|
{
|
|
38
|
-
|
|
35
|
+
const newAlerts = [...state.alerts];
|
|
39
36
|
for (var i = newAlerts.length - 1; i >= 0; i--) {
|
|
40
37
|
if (newAlerts[i].key === action.key) {
|
|
41
38
|
newAlerts.splice(i, 1);
|
|
42
39
|
}
|
|
43
40
|
}
|
|
44
|
-
return
|
|
41
|
+
return {
|
|
42
|
+
...state,
|
|
45
43
|
alerts: newAlerts
|
|
46
|
-
}
|
|
44
|
+
};
|
|
47
45
|
}
|
|
48
46
|
case _actions.ACK_ALERT:
|
|
49
47
|
{
|
|
50
|
-
|
|
51
|
-
for (var i in
|
|
52
|
-
var alert =
|
|
48
|
+
const newAlerts = [...state.alerts];
|
|
49
|
+
for (var i in newAlerts) {
|
|
50
|
+
var alert = newAlerts[i];
|
|
53
51
|
if (alert.key === action.key) {
|
|
54
52
|
// Prolong the longevity of acked alarm a little bit
|
|
55
53
|
alert.expire.setSeconds(alert.expire.getSeconds() + 3);
|
|
@@ -57,9 +55,10 @@ function alertsReducer() {
|
|
|
57
55
|
break;
|
|
58
56
|
}
|
|
59
57
|
}
|
|
60
|
-
return
|
|
61
|
-
|
|
62
|
-
|
|
58
|
+
return {
|
|
59
|
+
...state,
|
|
60
|
+
alerts: newAlerts
|
|
61
|
+
};
|
|
63
62
|
}
|
|
64
63
|
default:
|
|
65
64
|
return state;
|