dce-reactkit 3.6.5 → 3.6.6
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/cjs/index.js +8 -3
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +8 -3
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/AppWrapper.tsx +11 -5
package/dist/esm/index.js
CHANGED
|
@@ -1122,6 +1122,13 @@ const AppWrapper = (props) => {
|
|
|
1122
1122
|
const error = (sessionHasExpired
|
|
1123
1123
|
? new ErrorWithCode(getSessionExpiredMessage(), ReactKitErrorCode$1.SessionExpired)
|
|
1124
1124
|
: new ErrorWithCode((fatalErrorMessage !== null && fatalErrorMessage !== void 0 ? fatalErrorMessage : 'An unknown error has occurred. Please contact support.'), (fatalErrorCode !== null && fatalErrorCode !== void 0 ? fatalErrorCode : ReactKitErrorCode$1.NoCode)));
|
|
1125
|
+
// Choose error box variant
|
|
1126
|
+
let errorBoxVariant = Variant$1.Danger;
|
|
1127
|
+
if (sessionHasExpired) {
|
|
1128
|
+
errorBoxVariant = (isDarkModeOn()
|
|
1129
|
+
? Variant$1.Light
|
|
1130
|
+
: Variant$1.Secondary);
|
|
1131
|
+
}
|
|
1125
1132
|
// Build error screen
|
|
1126
1133
|
body = (React__default.createElement("div", { style: {
|
|
1127
1134
|
display: 'block',
|
|
@@ -1134,9 +1141,7 @@ const AppWrapper = (props) => {
|
|
|
1134
1141
|
} },
|
|
1135
1142
|
React__default.createElement(ErrorBox, { title: (sessionHasExpired
|
|
1136
1143
|
? 'Session Expired'
|
|
1137
|
-
: fatalErrorTitle), error: error, variant:
|
|
1138
|
-
? Variant$1.Light
|
|
1139
|
-
: Variant$1.Secondary), icon: faHourglassEnd })));
|
|
1144
|
+
: fatalErrorTitle), error: error, variant: errorBoxVariant, icon: faHourglassEnd })));
|
|
1140
1145
|
}
|
|
1141
1146
|
/* --------------- App -------------- */
|
|
1142
1147
|
if (!body) {
|