@bookjane2/bookjane-design-library 8.0.21 → 8.0.22
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 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GenericErrorMessage.d.ts","sourceRoot":"","sources":["../../../src/components/GenericErrorMessage/GenericErrorMessage.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"GenericErrorMessage.d.ts","sourceRoot":"","sources":["../../../src/components/GenericErrorMessage/GenericErrorMessage.tsx"],"names":[],"mappings":"AAKA,UAAU,oBAAoB;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,QAAQ,GAAG,KAAK,CAAC;IAC7B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,eAAe,CAAC,EAAE,OAAO,CAAC;CACpC;AAED,eAAO,MAAM,gBAAgB,EAAE,OAekC,CAAC;AAElE,wBAAgB,mBAAmB,CAAC,EAClC,YAAY,EACZ,IAAc,EACd,KAAc,EACd,MAAe,EACf,SAAoB,EACpB,eAAuB,EACvB,QAAgB,EAChB,QAAe,EACf,GAAG,IAAI,EACR,EAAE,oBAAoB,eAoCtB"}
|
|
@@ -2,6 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { Fragment } from 'react';
|
|
3
3
|
import { SadJaneIcon } from '../../assets/SadJaneIcon.js';
|
|
4
4
|
import { GenericErrorMessageText, GenericErrorMessageWrapper } from './GenericErrorMessage.styled.js';
|
|
5
|
+
import { BKJButton } from '../index.js';
|
|
5
6
|
export const isEnvDevelopment = [
|
|
6
7
|
'development',
|
|
7
8
|
'sandbox1',
|
|
@@ -19,6 +20,6 @@ export const isEnvDevelopment = [
|
|
|
19
20
|
'tobox3',
|
|
20
21
|
].includes(process.env['REACT_APP_BKJ_ENVIRONMENT'] || 'default');
|
|
21
22
|
export function GenericErrorMessage({ errorMessage, size = 'Small', width = '100%', height = '100%', direction = 'column', suppressMessage = false, isStyled = false, showLogo = true, ...rest }) {
|
|
22
|
-
return (_jsx(GenericErrorMessageWrapper, { isStyled: isStyled, size: size, width: width, height: height, direction: direction, ...rest, children: !suppressMessage && (_jsxs(Fragment, { children: [showLogo && _jsx(SadJaneIcon, { size: size, direction: direction }), (process.env['NODE_ENV'] === 'development' || isEnvDevelopment) && errorMessage && (_jsx(GenericErrorMessageText, { size: size, direction: direction, children: errorMessage })), process.env['NODE_ENV'] === 'production' && errorMessage && (_jsxs(Fragment, { children: [_jsx(GenericErrorMessageText, { size: size, direction: direction, children: "Oops! Something went wrong" }), _jsx(GenericErrorMessageText, { size: size, direction: direction, children: "Try refreshing the browser" })] }))] })) }));
|
|
23
|
+
return (_jsx(GenericErrorMessageWrapper, { isStyled: isStyled, size: size, width: width, height: height, direction: direction, ...rest, children: !suppressMessage && (_jsxs(Fragment, { children: [showLogo && _jsx(SadJaneIcon, { size: size, direction: direction }), (process.env['NODE_ENV'] === 'development' || isEnvDevelopment) && errorMessage && (_jsx(GenericErrorMessageText, { size: size, direction: direction, children: errorMessage })), process.env['NODE_ENV'] === 'production' && errorMessage && (_jsxs(Fragment, { children: [_jsx(GenericErrorMessageText, { size: size, direction: direction, children: "Oops! Something went wrong" }), _jsx(GenericErrorMessageText, { size: size, direction: direction, children: "Try refreshing the browser" })] })), _jsx(BKJButton, { variant: "PurpleSolid", onClick: () => window.postMessage({ action: 'logout' }), width: "180px", children: "Logout" })] })) }));
|
|
23
24
|
}
|
|
24
25
|
//# sourceMappingURL=GenericErrorMessage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GenericErrorMessage.js","sourceRoot":"","sources":["../../../src/components/GenericErrorMessage/GenericErrorMessage.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,uBAAuB,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"GenericErrorMessage.js","sourceRoot":"","sources":["../../../src/components/GenericErrorMessage/GenericErrorMessage.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,uBAAuB,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;AACnG,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAavC,MAAM,CAAC,MAAM,gBAAgB,GAAY;IACvC,aAAa;IACb,UAAU;IACV,SAAS;IACT,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,OAAO;IACP,QAAQ;IACR,QAAQ;CACT,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,CAAC,IAAI,SAAS,CAAC,CAAC;AAElE,MAAM,UAAU,mBAAmB,CAAC,EAClC,YAAY,EACZ,IAAI,GAAG,OAAO,EACd,KAAK,GAAG,MAAM,EACd,MAAM,GAAG,MAAM,EACf,SAAS,GAAG,QAAQ,EACpB,eAAe,GAAG,KAAK,EACvB,QAAQ,GAAG,KAAK,EAChB,QAAQ,GAAG,IAAI,EACf,GAAG,IAAI,EACc;IACrB,OAAO,CACL,KAAC,0BAA0B,IACzB,QAAQ,EAAE,QAAQ,EAClB,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK,EACZ,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,SAAS,KAChB,IAAI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