@semcore/errors 17.0.0-prerelease.30 → 17.0.0-prerelease.34
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/CHANGELOG.md +5 -1
- package/lib/cjs/AccessDenied/{index.js → AccessDenied.js} +1 -1
- package/lib/cjs/AccessDenied/AccessDenied.js.map +1 -0
- package/lib/cjs/AccessDenied/AccessDenied.type.js +2 -0
- package/lib/cjs/AccessDenied/AccessDenied.type.js.map +1 -0
- package/lib/cjs/Error.js +2 -1
- package/lib/cjs/Error.js.map +1 -1
- package/lib/cjs/Error.type.js +2 -0
- package/lib/cjs/Error.type.js.map +1 -0
- package/lib/cjs/Maintenance/{index.js → Maintenance.js} +1 -1
- package/lib/cjs/Maintenance/Maintenance.js.map +1 -0
- package/lib/cjs/Maintenance/Maintenance.type.js +2 -0
- package/lib/cjs/Maintenance/Maintenance.type.js.map +1 -0
- package/lib/cjs/PageError/{index.js → PageError.js} +9 -7
- package/lib/cjs/PageError/PageError.js.map +1 -0
- package/lib/cjs/PageError/PageError.type.js +2 -0
- package/lib/cjs/PageError/PageError.type.js.map +1 -0
- package/lib/cjs/PageNotFound/{index.js → PageNotFound.js} +3 -2
- package/lib/cjs/PageNotFound/PageNotFound.js.map +1 -0
- package/lib/cjs/PageNotFound/PageNotFound.type.js +2 -0
- package/lib/cjs/PageNotFound/PageNotFound.type.js.map +1 -0
- package/lib/cjs/ProjectNotFound/{index.js → ProjectNotFound.js} +3 -3
- package/lib/cjs/ProjectNotFound/ProjectNotFound.js.map +1 -0
- package/lib/cjs/ProjectNotFound/ProjectNotFound.type.js +2 -0
- package/lib/cjs/ProjectNotFound/ProjectNotFound.type.js.map +1 -0
- package/lib/cjs/index.js +76 -8
- package/lib/cjs/index.js.map +1 -1
- package/lib/es6/AccessDenied/{index.js → AccessDenied.js} +1 -1
- package/lib/es6/AccessDenied/AccessDenied.js.map +1 -0
- package/lib/es6/AccessDenied/AccessDenied.type.js +2 -0
- package/lib/es6/AccessDenied/AccessDenied.type.js.map +1 -0
- package/lib/es6/Error.js +2 -1
- package/lib/es6/Error.js.map +1 -1
- package/lib/es6/Error.type.js +2 -0
- package/lib/es6/Error.type.js.map +1 -0
- package/lib/es6/Maintenance/{index.js → Maintenance.js} +1 -1
- package/lib/es6/Maintenance/Maintenance.js.map +1 -0
- package/lib/es6/Maintenance/Maintenance.type.js +2 -0
- package/lib/es6/Maintenance/Maintenance.type.js.map +1 -0
- package/lib/es6/PageError/{index.js → PageError.js} +8 -5
- package/lib/es6/PageError/PageError.js.map +1 -0
- package/lib/es6/PageError/PageError.type.js +2 -0
- package/lib/es6/PageError/PageError.type.js.map +1 -0
- package/lib/es6/PageNotFound/{index.js → PageNotFound.js} +3 -2
- package/lib/es6/PageNotFound/PageNotFound.js.map +1 -0
- package/lib/es6/PageNotFound/PageNotFound.type.js +2 -0
- package/lib/es6/PageNotFound/PageNotFound.type.js.map +1 -0
- package/lib/es6/ProjectNotFound/{index.js → ProjectNotFound.js} +3 -3
- package/lib/es6/ProjectNotFound/ProjectNotFound.js.map +1 -0
- package/lib/es6/ProjectNotFound/ProjectNotFound.type.js +2 -0
- package/lib/es6/ProjectNotFound/ProjectNotFound.type.js.map +1 -0
- package/lib/es6/index.js +12 -7
- package/lib/es6/index.js.map +1 -1
- package/lib/esm/AccessDenied/{index.mjs → AccessDenied.mjs} +2 -2
- package/lib/esm/Error.mjs +1 -1
- package/lib/esm/Maintenance/{index.mjs → Maintenance.mjs} +2 -2
- package/lib/esm/PageError/{index.mjs → PageError.mjs} +8 -6
- package/lib/esm/PageNotFound/{index.mjs → PageNotFound.mjs} +3 -3
- package/lib/esm/ProjectNotFound/{index.mjs → ProjectNotFound.mjs} +4 -4
- package/lib/esm/index.mjs +5 -5
- package/lib/types/AccessDenied/AccessDenied.d.ts +3 -0
- package/lib/types/AccessDenied/AccessDenied.type.d.ts +16 -0
- package/lib/types/AccessDenied/translations/__intergalactic-dynamic-locales.d.ts +77 -0
- package/lib/types/Error.d.ts +4 -0
- package/lib/types/Error.type.d.ts +26 -0
- package/lib/types/Maintenance/Maintenance.d.ts +3 -0
- package/lib/types/Maintenance/Maintenance.type.d.ts +20 -0
- package/lib/types/Maintenance/translations/__intergalactic-dynamic-locales.d.ts +77 -0
- package/lib/types/PageError/PageError.d.ts +3 -0
- package/lib/types/PageError/PageError.type.d.ts +16 -0
- package/lib/types/PageError/translations/__intergalactic-dynamic-locales.d.ts +77 -0
- package/lib/types/PageNotFound/PageNotFound.d.ts +3 -0
- package/lib/types/PageNotFound/PageNotFound.type.d.ts +16 -0
- package/lib/types/PageNotFound/translations/__intergalactic-dynamic-locales.d.ts +77 -0
- package/lib/types/ProjectNotFound/ProjectNotFound.d.ts +3 -0
- package/lib/types/ProjectNotFound/ProjectNotFound.type.d.ts +26 -0
- package/lib/types/ProjectNotFound/translations/__intergalactic-dynamic-locales.d.ts +92 -0
- package/lib/types/index.d.ts +12 -114
- package/package.json +7 -7
- package/vite.config.ts +1 -1
- package/lib/cjs/AccessDenied/index.js.map +0 -1
- package/lib/cjs/Maintenance/index.js.map +0 -1
- package/lib/cjs/PageError/index.js.map +0 -1
- package/lib/cjs/PageNotFound/index.js.map +0 -1
- package/lib/cjs/ProjectNotFound/index.js.map +0 -1
- package/lib/cjs/index.d.js +0 -8
- package/lib/cjs/index.d.js.map +0 -1
- package/lib/es6/AccessDenied/index.js.map +0 -1
- package/lib/es6/Maintenance/index.js.map +0 -1
- package/lib/es6/PageError/index.js.map +0 -1
- package/lib/es6/PageNotFound/index.js.map +0 -1
- package/lib/es6/ProjectNotFound/index.js.map +0 -1
- package/lib/es6/index.d.js +0 -2
- package/lib/es6/index.d.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PageNotFound.js","names":["Button","createComponent","Component","Root","i18nEnhance","React","Error","getIconPath","localizedMessages","RootPageNotFound","render","_ref","asProps","Children","getI18nText","homeLink","titleTag","createElement","_assignProps","Title","tag","Description","Controls","type","size","use","theme","href","_defineProperty","i18n","locale","icon"],"sources":["../../../src/PageNotFound/PageNotFound.tsx"],"sourcesContent":["import Button from '@semcore/button';\nimport type { Intergalactic } from '@semcore/core';\nimport { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport React from 'react';\n\nimport Error, { getIconPath } from '../Error';\nimport type { PageNotFoundComponent, PageNotFoundProps } from './PageNotFound.type';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass RootPageNotFound extends Component<\n Intergalactic.InternalTypings.InferComponentProps<PageNotFoundComponent>,\n typeof RootPageNotFound.enhance\n> {\n static displayName = 'PageNotFound';\n static enhance = [i18nEnhance(localizedMessages)] as const;\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n icon: getIconPath('page_not_found'),\n homeLink: '/',\n titleTag: 'h2',\n };\n\n render() {\n const { Children, getI18nText, homeLink, titleTag } = this.asProps;\n\n return (\n <Root render={Error}>\n <Error.Title tag={titleTag}>{getI18nText('title')}</Error.Title>\n <Error.Description>{getI18nText('text')}</Error.Description>\n <Children />\n <Error.Controls>\n <Button tag='a' type='none' size='l' use='primary' theme='info' href={homeLink}>\n {getI18nText('btnHome')}\n </Button>\n </Error.Controls>\n </Root>\n );\n }\n}\n\nexport default createComponent(RootPageNotFound) as PageNotFoundComponent; ;\n"],"mappings":";;AAAA,OAAOA,MAAM,MAAM,iBAAiB;AAEpC,SAASC,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,KAAK,IAAIC,WAAW,QAAQ,UAAU;AAE7C,SAASC,iBAAiB,QAAQ,gDAAgD;AAElF,MAAMC,gBAAgB,SAASP,SAAS,CAGtC;EAWAQ,MAAMA,CAAA,EAAG;IAAA,IAAAC,IAAA,QAAAC,OAAA;IACP,MAAM;MAAEC,QAAQ;MAAEC,WAAW;MAAEC,QAAQ;MAAEC;IAAS,CAAC,GAAG,IAAI,CAACJ,OAAO;IAElE,oBACEP,KAAA,CAAAY,aAAA,CAAcX,KAAK,EAAAY,YAAA,KAAAP,IAAA,gBACjBN,KAAA,CAAAY,aAAA,CAACX,KAAK,CAACa,KAAK;MAACC,GAAG,EAAEJ;IAAS,GAAEF,WAAW,CAAC,OAAO,CAAe,CAAC,eAChET,KAAA,CAAAY,aAAA,CAACX,KAAK,CAACe,WAAW,QAAEP,WAAW,CAAC,MAAM,CAAqB,CAAC,eAC5DT,KAAA,CAAAY,aAAA,CAACJ,QAAQ,MAAE,CAAC,eACZR,KAAA,CAAAY,aAAA,CAACX,KAAK,CAACgB,QAAQ,qBACbjB,KAAA,CAAAY,aAAA,CAACjB,MAAM;MAACoB,GAAG,EAAC,GAAG;MAACG,IAAI,EAAC,MAAM;MAACC,IAAI,EAAC,GAAG;MAACC,GAAG,EAAC,SAAS;MAACC,KAAK,EAAC,MAAM;MAACC,IAAI,EAAEZ;IAAS,GAC5ED,WAAW,CAAC,SAAS,CAChB,CACM,CACZ,CAAC;EAEX;AACF;AAACc,eAAA,CA9BKnB,gBAAgB,iBAIC,cAAc;AAAAmB,eAAA,CAJ/BnB,gBAAgB,aAKH,CAACL,WAAW,CAACI,iBAAiB,CAAC,CAAC;AAAAoB,eAAA,CAL7CnB,gBAAgB,kBAME;EACpBoB,IAAI,EAAErB,iBAAiB;EACvBsB,MAAM,EAAE,IAAI;EACZC,IAAI,EAAExB,WAAW,CAAC,gBAAgB,CAAC;EACnCQ,QAAQ,EAAE,GAAG;EACbC,QAAQ,EAAE;AACZ,CAAC;AAoBH,eAAef,eAAe,CAACQ,gBAAgB,CAAC;AAA2B","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PageNotFound.type.js","names":[],"sources":["../../../src/PageNotFound/PageNotFound.type.ts"],"sourcesContent":["import type { Intergalactic } from '@semcore/core';\nimport type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';\n\nimport type { ErrorsProps } from '../Error.type';\n\nexport type PageNotFoundProps = WithI18nEnhanceProps & {\n /**\n * href of the home link\n * @default /\n */\n homeLink?: string;\n /**\n * HTML tag of the error title\n * @default h2\n */\n titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';\n};\n\nexport type PageNotFoundComponent = Intergalactic.Component<'div', PageNotFoundProps & ErrorsProps>;\n"],"mappings":"","ignoreList":[]}
|
|
@@ -31,7 +31,7 @@ class RootProjectNotFound extends Component {
|
|
|
31
31
|
}, getI18nText('title')), /*#__PURE__*/React.createElement(Error.Description, {
|
|
32
32
|
tag: Text,
|
|
33
33
|
formatTags: true,
|
|
34
|
-
size:
|
|
34
|
+
size: 300
|
|
35
35
|
}, text), /*#__PURE__*/React.createElement(Children, null), /*#__PURE__*/React.createElement(Error.Controls, null, /*#__PURE__*/React.createElement(Button, {
|
|
36
36
|
tag: "a",
|
|
37
37
|
type: "none",
|
|
@@ -47,7 +47,7 @@ class RootProjectNotFound extends Component {
|
|
|
47
47
|
}, getI18nText('btnContacts'))));
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
|
-
_defineProperty(RootProjectNotFound, "displayName", '
|
|
50
|
+
_defineProperty(RootProjectNotFound, "displayName", 'ProjectNotFound');
|
|
51
51
|
_defineProperty(RootProjectNotFound, "enhance", [i18nEnhance(localizedMessages)]);
|
|
52
52
|
_defineProperty(RootProjectNotFound, "defaultProps", {
|
|
53
53
|
i18n: localizedMessages,
|
|
@@ -59,4 +59,4 @@ _defineProperty(RootProjectNotFound, "defaultProps", {
|
|
|
59
59
|
titleTag: 'h2'
|
|
60
60
|
});
|
|
61
61
|
export default createComponent(RootProjectNotFound);
|
|
62
|
-
//# sourceMappingURL=
|
|
62
|
+
//# sourceMappingURL=ProjectNotFound.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProjectNotFound.js","names":["Button","createComponent","Component","Root","i18nEnhance","Text","React","Error","getIconPath","localizedMessages","RootProjectNotFound","render","_ref","asProps","Children","getI18nText","projectsLink","contactsLink","supportTeamLink","titleTag","text","p","chunk","createElement","ul","li","supportLink","href","_assignProps","Title","tag","Description","formatTags","size","Controls","type","use","theme","_defineProperty","i18n","locale","icon"],"sources":["../../../src/ProjectNotFound/ProjectNotFound.tsx"],"sourcesContent":["import Button from '@semcore/button';\nimport type { Intergalactic } from '@semcore/core';\nimport { createComponent, Component, Root } from '@semcore/core';\nimport i18nEnhance from '@semcore/core/lib/utils/enhances/i18nEnhance';\nimport { Text } from '@semcore/typography';\nimport React from 'react';\n\nimport Error, { getIconPath } from '../Error';\nimport type { ProjectNotFoundComponent } from './ProjectNotFound.type';\nimport { localizedMessages } from './translations/__intergalactic-dynamic-locales';\n\nclass RootProjectNotFound extends Component<\n Intergalactic.InternalTypings.InferComponentProps<ProjectNotFoundComponent>,\n typeof RootProjectNotFound.enhance\n> {\n static displayName = 'ProjectNotFound';\n static enhance = [i18nEnhance(localizedMessages)] as const;\n static defaultProps = {\n i18n: localizedMessages,\n locale: 'en',\n icon: getIconPath('project_not_found'),\n projectsLink: '/projects',\n contactsLink: '/company/contacts',\n supportTeamLink: '/company/contacts',\n titleTag: 'h2',\n };\n\n render() {\n const { Children, getI18nText, projectsLink, contactsLink, supportTeamLink, titleTag } = this.asProps;\n const text = getI18nText('text', {\n p: (chunk: string) => <p>{chunk}</p>,\n ul: (chunk: string) => <ul>{chunk}</ul>,\n li: (chunk: string) => <li>{chunk}</li>,\n supportLink: (chunk: string) => <a href={supportTeamLink}>{chunk}</a>,\n });\n return (\n <Root render={Error}>\n <Error.Title tag={titleTag}>{getI18nText('title')}</Error.Title>\n <Error.Description tag={Text} formatTags={true} size={300}>\n {text}\n </Error.Description>\n <Children />\n <Error.Controls>\n <Button tag='a' type='none' size='l' use='primary' theme='info' href={projectsLink}>\n {getI18nText('btnProjects')}\n </Button>\n <Button size='l' tag='a' type='none' href={contactsLink}>\n {getI18nText('btnContacts')}\n </Button>\n </Error.Controls>\n </Root>\n );\n }\n}\n\nexport default createComponent(RootProjectNotFound) as ProjectNotFoundComponent;\n"],"mappings":";;AAAA,OAAOA,MAAM,MAAM,iBAAiB;AAEpC,SAASC,eAAe,EAAEC,SAAS,EAAEC,IAAI,QAAQ,eAAe;AAChE,OAAOC,WAAW,MAAM,8CAA8C;AACtE,SAASC,IAAI,QAAQ,qBAAqB;AAC1C,OAAOC,KAAK,MAAM,OAAO;AAEzB,OAAOC,KAAK,IAAIC,WAAW,QAAQ,UAAU;AAE7C,SAASC,iBAAiB,QAAQ,gDAAgD;AAElF,MAAMC,mBAAmB,SAASR,SAAS,CAGzC;EAaAS,MAAMA,CAAA,EAAG;IAAA,IAAAC,IAAA,QAAAC,OAAA;IACP,MAAM;MAAEC,QAAQ;MAAEC,WAAW;MAAEC,YAAY;MAAEC,YAAY;MAAEC,eAAe;MAAEC;IAAS,CAAC,GAAG,IAAI,CAACN,OAAO;IACrG,MAAMO,IAAI,GAAGL,WAAW,CAAC,MAAM,EAAE;MAC/BM,CAAC,EAAGC,KAAa,iBAAKhB,KAAA,CAAAiB,aAAA,YAAID,KAAS,CAAC;MACpCE,EAAE,EAAGF,KAAa,iBAAKhB,KAAA,CAAAiB,aAAA,aAAKD,KAAU,CAAC;MACvCG,EAAE,EAAGH,KAAa,iBAAKhB,KAAA,CAAAiB,aAAA,aAAKD,KAAU,CAAC;MACvCI,WAAW,EAAGJ,KAAa,iBAAKhB,KAAA,CAAAiB,aAAA;QAAGI,IAAI,EAAET;MAAgB,GAAEI,KAAS;IACtE,CAAC,CAAC;IACF,oBACEhB,KAAA,CAAAiB,aAAA,CAAchB,KAAK,EAAAqB,YAAA,KAAAhB,IAAA,gBACjBN,KAAA,CAAAiB,aAAA,CAAChB,KAAK,CAACsB,KAAK;MAACC,GAAG,EAAEX;IAAS,GAAEJ,WAAW,CAAC,OAAO,CAAe,CAAC,eAChET,KAAA,CAAAiB,aAAA,CAAChB,KAAK,CAACwB,WAAW;MAACD,GAAG,EAAEzB,IAAK;MAAC2B,UAAU,EAAE,IAAK;MAACC,IAAI,EAAE;IAAI,GACvDb,IACgB,CAAC,eACpBd,KAAA,CAAAiB,aAAA,CAACT,QAAQ,MAAE,CAAC,eACZR,KAAA,CAAAiB,aAAA,CAAChB,KAAK,CAAC2B,QAAQ,qBACb5B,KAAA,CAAAiB,aAAA,CAACvB,MAAM;MAAC8B,GAAG,EAAC,GAAG;MAACK,IAAI,EAAC,MAAM;MAACF,IAAI,EAAC,GAAG;MAACG,GAAG,EAAC,SAAS;MAACC,KAAK,EAAC,MAAM;MAACV,IAAI,EAAEX;IAAa,GAChFD,WAAW,CAAC,aAAa,CACpB,CAAC,eACTT,KAAA,CAAAiB,aAAA,CAACvB,MAAM;MAACiC,IAAI,EAAC,GAAG;MAACH,GAAG,EAAC,GAAG;MAACK,IAAI,EAAC,MAAM;MAACR,IAAI,EAAEV;IAAa,GACrDF,WAAW,CAAC,aAAa,CACpB,CACM,CACZ,CAAC;EAEX;AACF;AAACuB,eAAA,CA1CK5B,mBAAmB,iBAIF,iBAAiB;AAAA4B,eAAA,CAJlC5B,mBAAmB,aAKN,CAACN,WAAW,CAACK,iBAAiB,CAAC,CAAC;AAAA6B,eAAA,CAL7C5B,mBAAmB,kBAMD;EACpB6B,IAAI,EAAE9B,iBAAiB;EACvB+B,MAAM,EAAE,IAAI;EACZC,IAAI,EAAEjC,WAAW,CAAC,mBAAmB,CAAC;EACtCQ,YAAY,EAAE,WAAW;EACzBC,YAAY,EAAE,mBAAmB;EACjCC,eAAe,EAAE,mBAAmB;EACpCC,QAAQ,EAAE;AACZ,CAAC;AA8BH,eAAelB,eAAe,CAACS,mBAAmB,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProjectNotFound.type.js","names":[],"sources":["../../../src/ProjectNotFound/ProjectNotFound.type.ts"],"sourcesContent":["import type { Intergalactic } from '@semcore/core';\nimport type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';\n\nimport type { ErrorsProps } from '../Error.type';\n\nexport type ProjectNotFoundProps = WithI18nEnhanceProps & {\n /**\n * URL for the \"Go to Projects\" button\n * @default /projects\n */\n projectsLink?: string;\n /**\n * URL for the \"Contact us\" button\n * @default /company/contacts\n */\n contactsLink?: string;\n /**\n * URL for the \"Support Team\" link\n * @default /company/contacts\n */\n supportTeamLink?: string;\n /**\n * HTML tag of the error title\n * @default h2\n */\n titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';\n};\n\nexport type ProjectNotFoundComponent = Intergalactic.Component<'div', ProjectNotFoundProps & ErrorsProps>;\n"],"mappings":"","ignoreList":[]}
|
package/lib/es6/index.js
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
export { default } from './Error';
|
|
2
|
-
export * from './Error';
|
|
3
|
-
export { default as AccessDenied } from './AccessDenied';
|
|
4
|
-
export
|
|
5
|
-
export { default as
|
|
6
|
-
export
|
|
7
|
-
export { default as
|
|
1
|
+
export { default, getIconPath } from './Error';
|
|
2
|
+
export * from './Error.type';
|
|
3
|
+
export { default as AccessDenied } from './AccessDenied/AccessDenied';
|
|
4
|
+
export * from './AccessDenied/AccessDenied.type';
|
|
5
|
+
export { default as Maintenance } from './Maintenance/Maintenance';
|
|
6
|
+
export * from './Maintenance/Maintenance.type';
|
|
7
|
+
export { default as PageError } from './PageError/PageError';
|
|
8
|
+
export * from './PageError/PageError.type';
|
|
9
|
+
export { default as PageNotFound } from './PageNotFound/PageNotFound';
|
|
10
|
+
export * from './PageNotFound/PageNotFound.type';
|
|
11
|
+
export { default as ProjectNotFound } from './ProjectNotFound/ProjectNotFound';
|
|
12
|
+
export * from './ProjectNotFound/ProjectNotFound.type';
|
|
8
13
|
//# sourceMappingURL=index.js.map
|
package/lib/es6/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["default","AccessDenied","Maintenance","PageError","PageNotFound","ProjectNotFound"],"sources":["../../src/index.
|
|
1
|
+
{"version":3,"file":"index.js","names":["default","getIconPath","AccessDenied","Maintenance","PageError","PageNotFound","ProjectNotFound"],"sources":["../../src/index.ts"],"sourcesContent":["export { default, getIconPath } from './Error';\nexport * from './Error.type';\n\nexport { default as AccessDenied } from './AccessDenied/AccessDenied';\nexport * from './AccessDenied/AccessDenied.type';\nexport { default as Maintenance } from './Maintenance/Maintenance';\nexport * from './Maintenance/Maintenance.type';\nexport { default as PageError } from './PageError/PageError';\nexport * from './PageError/PageError.type';\nexport { default as PageNotFound } from './PageNotFound/PageNotFound';\nexport * from './PageNotFound/PageNotFound.type';\nexport { default as ProjectNotFound } from './ProjectNotFound/ProjectNotFound';\nexport * from './ProjectNotFound/ProjectNotFound.type';\n"],"mappings":"AAAA,SAASA,OAAO,EAAEC,WAAW,QAAQ,SAAS;AAC9C,cAAc,cAAc;AAE5B,SAASD,OAAO,IAAIE,YAAY,QAAQ,6BAA6B;AACrE,cAAc,kCAAkC;AAChD,SAASF,OAAO,IAAIG,WAAW,QAAQ,2BAA2B;AAClE,cAAc,gCAAgC;AAC9C,SAASH,OAAO,IAAII,SAAS,QAAQ,uBAAuB;AAC5D,cAAc,4BAA4B;AAC1C,SAASJ,OAAO,IAAIK,YAAY,QAAQ,6BAA6B;AACrE,cAAc,kCAAkC;AAChD,SAASL,OAAO,IAAIM,eAAe,QAAQ,mCAAmC;AAC9E,cAAc,wCAAwC","ignoreList":[]}
|
|
@@ -37,7 +37,7 @@ _defineProperty(RootAccessDenied, "defaultProps", {
|
|
|
37
37
|
icon: getIconPath("access_denied"),
|
|
38
38
|
titleTag: "h2"
|
|
39
39
|
});
|
|
40
|
-
const
|
|
40
|
+
const AccessDenied = createComponent(RootAccessDenied);
|
|
41
41
|
export {
|
|
42
|
-
|
|
42
|
+
AccessDenied as default
|
|
43
43
|
};
|
package/lib/esm/Error.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
2
|
-
import {
|
|
2
|
+
import { sstyled, createComponent, Component, assignProps } from "@semcore/core";
|
|
3
3
|
import { Flex, Box } from "@semcore/base-components";
|
|
4
4
|
import { getIllustrationPath } from "@semcore/illustration";
|
|
5
5
|
import React from "react";
|
|
@@ -36,7 +36,7 @@ _defineProperty(RootMaintenance, "defaultProps", {
|
|
|
36
36
|
icon: getIconPath("maintenance"),
|
|
37
37
|
titleTag: "h2"
|
|
38
38
|
});
|
|
39
|
-
const
|
|
39
|
+
const Maintenance = createComponent(RootMaintenance);
|
|
40
40
|
export {
|
|
41
|
-
|
|
41
|
+
Maintenance as default
|
|
42
42
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
2
|
+
import { createComponent, Component, assignProps } from "@semcore/core";
|
|
2
3
|
import Button from "@semcore/button";
|
|
3
|
-
import { createComponent, Component } from "@semcore/core";
|
|
4
4
|
import { callAllEventHandlers } from "@semcore/core/lib/utils/assignProps";
|
|
5
5
|
import canUseDOM from "@semcore/core/lib/utils/canUseDOM";
|
|
6
6
|
import i18nEnhance from "@semcore/core/lib/utils/enhances/i18nEnhance";
|
|
@@ -17,14 +17,16 @@ class RootPageError extends Component {
|
|
|
17
17
|
});
|
|
18
18
|
}
|
|
19
19
|
render() {
|
|
20
|
+
var _ref = this.asProps;
|
|
20
21
|
const {
|
|
21
22
|
Children,
|
|
22
23
|
getI18nText,
|
|
23
24
|
onClick,
|
|
24
|
-
titleTag
|
|
25
|
-
...other
|
|
25
|
+
titleTag
|
|
26
26
|
} = this.asProps;
|
|
27
|
-
return /* @__PURE__ */ React.createElement(Error,
|
|
27
|
+
return /* @__PURE__ */ React.createElement(Error, assignProps({
|
|
28
|
+
"__excludeProps": ["Children", "getI18nText", "onClick", "titleTag"]
|
|
29
|
+
}, _ref), /* @__PURE__ */ React.createElement(Error.Title, {
|
|
28
30
|
tag: titleTag
|
|
29
31
|
}, getI18nText("title")), /* @__PURE__ */ React.createElement(Error.Description, null, getI18nText("text")), /* @__PURE__ */ React.createElement(Children, null), /* @__PURE__ */ React.createElement(Error.Controls, null, /* @__PURE__ */ React.createElement(Button, {
|
|
30
32
|
onClick: callAllEventHandlers(onClick, this.handleReload),
|
|
@@ -42,7 +44,7 @@ _defineProperty(RootPageError, "defaultProps", {
|
|
|
42
44
|
icon: getIconPath("page_error"),
|
|
43
45
|
titleTag: "h2"
|
|
44
46
|
});
|
|
45
|
-
const
|
|
47
|
+
const PageError = createComponent(RootPageError);
|
|
46
48
|
export {
|
|
47
|
-
|
|
49
|
+
PageError as default
|
|
48
50
|
};
|
|
@@ -26,7 +26,7 @@ class RootPageNotFound extends Component {
|
|
|
26
26
|
}, getI18nText("btnHome"))));
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
_defineProperty(RootPageNotFound, "displayName", "
|
|
29
|
+
_defineProperty(RootPageNotFound, "displayName", "PageNotFound");
|
|
30
30
|
_defineProperty(RootPageNotFound, "enhance", [i18nEnhance(localizedMessages)]);
|
|
31
31
|
_defineProperty(RootPageNotFound, "defaultProps", {
|
|
32
32
|
i18n: localizedMessages,
|
|
@@ -35,7 +35,7 @@ _defineProperty(RootPageNotFound, "defaultProps", {
|
|
|
35
35
|
homeLink: "/",
|
|
36
36
|
titleTag: "h2"
|
|
37
37
|
});
|
|
38
|
-
const
|
|
38
|
+
const PageNotFound = createComponent(RootPageNotFound);
|
|
39
39
|
export {
|
|
40
|
-
|
|
40
|
+
PageNotFound as default
|
|
41
41
|
};
|
|
@@ -30,7 +30,7 @@ class RootProjectNotFound extends Component {
|
|
|
30
30
|
}, getI18nText("title")), /* @__PURE__ */ React.createElement(Error.Description, {
|
|
31
31
|
tag: Text,
|
|
32
32
|
formatTags: true,
|
|
33
|
-
size:
|
|
33
|
+
size: 300
|
|
34
34
|
}, text), /* @__PURE__ */ React.createElement(Children, null), /* @__PURE__ */ React.createElement(Error.Controls, null, /* @__PURE__ */ React.createElement(Button, {
|
|
35
35
|
tag: "a",
|
|
36
36
|
type: "none",
|
|
@@ -46,7 +46,7 @@ class RootProjectNotFound extends Component {
|
|
|
46
46
|
}, getI18nText("btnContacts"))));
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
|
-
_defineProperty(RootProjectNotFound, "displayName", "
|
|
49
|
+
_defineProperty(RootProjectNotFound, "displayName", "ProjectNotFound");
|
|
50
50
|
_defineProperty(RootProjectNotFound, "enhance", [i18nEnhance(localizedMessages)]);
|
|
51
51
|
_defineProperty(RootProjectNotFound, "defaultProps", {
|
|
52
52
|
i18n: localizedMessages,
|
|
@@ -57,7 +57,7 @@ _defineProperty(RootProjectNotFound, "defaultProps", {
|
|
|
57
57
|
supportTeamLink: "/company/contacts",
|
|
58
58
|
titleTag: "h2"
|
|
59
59
|
});
|
|
60
|
-
const
|
|
60
|
+
const ProjectNotFound = createComponent(RootProjectNotFound);
|
|
61
61
|
export {
|
|
62
|
-
|
|
62
|
+
ProjectNotFound as default
|
|
63
63
|
};
|
package/lib/esm/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { default as default2, getIconPath } from "./Error.mjs";
|
|
2
|
-
import { default as default3 } from "./AccessDenied/
|
|
3
|
-
import { default as default4 } from "./Maintenance/
|
|
4
|
-
import { default as default5 } from "./PageError/
|
|
5
|
-
import { default as default6 } from "./PageNotFound/
|
|
6
|
-
import { default as default7 } from "./ProjectNotFound/
|
|
2
|
+
import { default as default3 } from "./AccessDenied/AccessDenied.mjs";
|
|
3
|
+
import { default as default4 } from "./Maintenance/Maintenance.mjs";
|
|
4
|
+
import { default as default5 } from "./PageError/PageError.mjs";
|
|
5
|
+
import { default as default6 } from "./PageNotFound/PageNotFound.mjs";
|
|
6
|
+
import { default as default7 } from "./ProjectNotFound/ProjectNotFound.mjs";
|
|
7
7
|
export {
|
|
8
8
|
default3 as AccessDenied,
|
|
9
9
|
default4 as Maintenance,
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Intergalactic } from '@semcore/core';
|
|
2
|
+
import type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';
|
|
3
|
+
import type { ErrorsProps } from '../Error.type';
|
|
4
|
+
export type AccessDeniedProps = WithI18nEnhanceProps & {
|
|
5
|
+
/**
|
|
6
|
+
* href of the home link
|
|
7
|
+
* @default /
|
|
8
|
+
*/
|
|
9
|
+
homeLink?: string;
|
|
10
|
+
/**
|
|
11
|
+
* HTML tag of the error title
|
|
12
|
+
* @default h2
|
|
13
|
+
*/
|
|
14
|
+
titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';
|
|
15
|
+
};
|
|
16
|
+
export type AccessDeniedComponent = Intergalactic.Component<'div', AccessDeniedProps & ErrorsProps>;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
export declare const localizedMessages: {
|
|
2
|
+
de: {
|
|
3
|
+
title: string;
|
|
4
|
+
text: string;
|
|
5
|
+
btnHome: string;
|
|
6
|
+
};
|
|
7
|
+
en: {
|
|
8
|
+
title: string;
|
|
9
|
+
text: string;
|
|
10
|
+
btnHome: string;
|
|
11
|
+
};
|
|
12
|
+
es: {
|
|
13
|
+
title: string;
|
|
14
|
+
text: string;
|
|
15
|
+
btnHome: string;
|
|
16
|
+
};
|
|
17
|
+
fr: {
|
|
18
|
+
title: string;
|
|
19
|
+
text: string;
|
|
20
|
+
btnHome: string;
|
|
21
|
+
};
|
|
22
|
+
it: {
|
|
23
|
+
title: string;
|
|
24
|
+
text: string;
|
|
25
|
+
btnHome: string;
|
|
26
|
+
};
|
|
27
|
+
ja: {
|
|
28
|
+
title: string;
|
|
29
|
+
text: string;
|
|
30
|
+
btnHome: string;
|
|
31
|
+
};
|
|
32
|
+
ko: {
|
|
33
|
+
title: string;
|
|
34
|
+
text: string;
|
|
35
|
+
btnHome: string;
|
|
36
|
+
};
|
|
37
|
+
nl: {
|
|
38
|
+
title: string;
|
|
39
|
+
text: string;
|
|
40
|
+
btnHome: string;
|
|
41
|
+
};
|
|
42
|
+
pt: {
|
|
43
|
+
title: string;
|
|
44
|
+
text: string;
|
|
45
|
+
btnHome: string;
|
|
46
|
+
};
|
|
47
|
+
ru: {
|
|
48
|
+
title: string;
|
|
49
|
+
text: string;
|
|
50
|
+
btnHome: string;
|
|
51
|
+
};
|
|
52
|
+
tr: {
|
|
53
|
+
title: string;
|
|
54
|
+
text: string;
|
|
55
|
+
btnHome: string;
|
|
56
|
+
};
|
|
57
|
+
vi: {
|
|
58
|
+
title: string;
|
|
59
|
+
text: string;
|
|
60
|
+
btnHome: string;
|
|
61
|
+
};
|
|
62
|
+
zh: {
|
|
63
|
+
title: string;
|
|
64
|
+
text: string;
|
|
65
|
+
btnHome: string;
|
|
66
|
+
};
|
|
67
|
+
pl: {
|
|
68
|
+
title: string;
|
|
69
|
+
text: string;
|
|
70
|
+
btnHome: string;
|
|
71
|
+
};
|
|
72
|
+
sv: {
|
|
73
|
+
title: string;
|
|
74
|
+
text: string;
|
|
75
|
+
btnHome: string;
|
|
76
|
+
};
|
|
77
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { Box, FlexProps } from '@semcore/base-components';
|
|
2
|
+
import type { Intergalactic, PropGetterFn } from '@semcore/core';
|
|
3
|
+
import type { TIllustrationNamesErrors } from '@semcore/illustration';
|
|
4
|
+
import type React from 'react';
|
|
5
|
+
export type IconNamesErrors = TIllustrationNamesErrors;
|
|
6
|
+
export type ErrorsProps = FlexProps & {
|
|
7
|
+
/**
|
|
8
|
+
* Error icon
|
|
9
|
+
* Icon as a string is a URL to an image.
|
|
10
|
+
*/
|
|
11
|
+
icon?: string | React.ReactNode;
|
|
12
|
+
};
|
|
13
|
+
export type ErrorsContext = {
|
|
14
|
+
getTextProps: PropGetterFn;
|
|
15
|
+
getDescriptionProps: PropGetterFn;
|
|
16
|
+
getControlsProps: PropGetterFn;
|
|
17
|
+
};
|
|
18
|
+
export type ErrorRootComponent = Intergalactic.Component<'div', ErrorsProps, ErrorsContext>;
|
|
19
|
+
export type ErrorTitleComponent = typeof Box;
|
|
20
|
+
export type ErrorDescriptionComponent = typeof Box;
|
|
21
|
+
export type ErrorControlsComponent = typeof Box;
|
|
22
|
+
export type ErrorComponent = ErrorRootComponent & {
|
|
23
|
+
Title: ErrorTitleComponent;
|
|
24
|
+
Description: ErrorDescriptionComponent;
|
|
25
|
+
Controls: ErrorControlsComponent;
|
|
26
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { Intergalactic } from '@semcore/core';
|
|
2
|
+
import type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';
|
|
3
|
+
import type { ErrorsProps } from '../Error.type';
|
|
4
|
+
export type MaintenanceProps = WithI18nEnhanceProps & {
|
|
5
|
+
/**
|
|
6
|
+
* Tool name
|
|
7
|
+
*/
|
|
8
|
+
toolName: string;
|
|
9
|
+
/**
|
|
10
|
+
* href of the home link
|
|
11
|
+
* @default /
|
|
12
|
+
*/
|
|
13
|
+
homeLink?: string;
|
|
14
|
+
/**
|
|
15
|
+
* HTML tag of the error title
|
|
16
|
+
* @default h2
|
|
17
|
+
*/
|
|
18
|
+
titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';
|
|
19
|
+
};
|
|
20
|
+
export type MaintenanceComponent = Intergalactic.Component<'div', MaintenanceProps & ErrorsProps>;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
export declare const localizedMessages: {
|
|
2
|
+
de: {
|
|
3
|
+
title: string;
|
|
4
|
+
text: string;
|
|
5
|
+
btnHome: string;
|
|
6
|
+
};
|
|
7
|
+
en: {
|
|
8
|
+
title: string;
|
|
9
|
+
text: string;
|
|
10
|
+
btnHome: string;
|
|
11
|
+
};
|
|
12
|
+
es: {
|
|
13
|
+
title: string;
|
|
14
|
+
text: string;
|
|
15
|
+
btnHome: string;
|
|
16
|
+
};
|
|
17
|
+
fr: {
|
|
18
|
+
title: string;
|
|
19
|
+
text: string;
|
|
20
|
+
btnHome: string;
|
|
21
|
+
};
|
|
22
|
+
it: {
|
|
23
|
+
title: string;
|
|
24
|
+
text: string;
|
|
25
|
+
btnHome: string;
|
|
26
|
+
};
|
|
27
|
+
ja: {
|
|
28
|
+
title: string;
|
|
29
|
+
text: string;
|
|
30
|
+
btnHome: string;
|
|
31
|
+
};
|
|
32
|
+
ko: {
|
|
33
|
+
title: string;
|
|
34
|
+
text: string;
|
|
35
|
+
btnHome: string;
|
|
36
|
+
};
|
|
37
|
+
nl: {
|
|
38
|
+
title: string;
|
|
39
|
+
text: string;
|
|
40
|
+
btnHome: string;
|
|
41
|
+
};
|
|
42
|
+
pt: {
|
|
43
|
+
title: string;
|
|
44
|
+
text: string;
|
|
45
|
+
btnHome: string;
|
|
46
|
+
};
|
|
47
|
+
ru: {
|
|
48
|
+
title: string;
|
|
49
|
+
text: string;
|
|
50
|
+
btnHome: string;
|
|
51
|
+
};
|
|
52
|
+
tr: {
|
|
53
|
+
title: string;
|
|
54
|
+
text: string;
|
|
55
|
+
btnHome: string;
|
|
56
|
+
};
|
|
57
|
+
vi: {
|
|
58
|
+
title: string;
|
|
59
|
+
text: string;
|
|
60
|
+
btnHome: string;
|
|
61
|
+
};
|
|
62
|
+
zh: {
|
|
63
|
+
title: string;
|
|
64
|
+
text: string;
|
|
65
|
+
btnHome: string;
|
|
66
|
+
};
|
|
67
|
+
pl: {
|
|
68
|
+
title: string;
|
|
69
|
+
text: string;
|
|
70
|
+
btnHome: string;
|
|
71
|
+
};
|
|
72
|
+
sv: {
|
|
73
|
+
title: string;
|
|
74
|
+
text: string;
|
|
75
|
+
btnHome: string;
|
|
76
|
+
};
|
|
77
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Intergalactic } from '@semcore/core';
|
|
2
|
+
import type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';
|
|
3
|
+
import type { ErrorsProps } from '../Error.type';
|
|
4
|
+
export type PageErrorProps = WithI18nEnhanceProps & {
|
|
5
|
+
/**
|
|
6
|
+
* Page reloading button click handler
|
|
7
|
+
* @default () => { if (canUseDOM()) { location.reload(); } }
|
|
8
|
+
*/
|
|
9
|
+
onClick?: (e: React.MouseEvent) => void;
|
|
10
|
+
/**
|
|
11
|
+
* HTML tag of the error title
|
|
12
|
+
* @default h2
|
|
13
|
+
*/
|
|
14
|
+
titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';
|
|
15
|
+
};
|
|
16
|
+
export type PageErrorComponent = Intergalactic.Component<'div', PageErrorProps & ErrorsProps>;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
export declare const localizedMessages: {
|
|
2
|
+
de: {
|
|
3
|
+
title: string;
|
|
4
|
+
text: string;
|
|
5
|
+
btnRetry: string;
|
|
6
|
+
};
|
|
7
|
+
en: {
|
|
8
|
+
title: string;
|
|
9
|
+
text: string;
|
|
10
|
+
btnRetry: string;
|
|
11
|
+
};
|
|
12
|
+
es: {
|
|
13
|
+
title: string;
|
|
14
|
+
text: string;
|
|
15
|
+
btnRetry: string;
|
|
16
|
+
};
|
|
17
|
+
fr: {
|
|
18
|
+
title: string;
|
|
19
|
+
text: string;
|
|
20
|
+
btnRetry: string;
|
|
21
|
+
};
|
|
22
|
+
it: {
|
|
23
|
+
title: string;
|
|
24
|
+
text: string;
|
|
25
|
+
btnRetry: string;
|
|
26
|
+
};
|
|
27
|
+
ja: {
|
|
28
|
+
title: string;
|
|
29
|
+
text: string;
|
|
30
|
+
btnRetry: string;
|
|
31
|
+
};
|
|
32
|
+
ko: {
|
|
33
|
+
title: string;
|
|
34
|
+
text: string;
|
|
35
|
+
btnRetry: string;
|
|
36
|
+
};
|
|
37
|
+
nl: {
|
|
38
|
+
title: string;
|
|
39
|
+
text: string;
|
|
40
|
+
btnRetry: string;
|
|
41
|
+
};
|
|
42
|
+
pt: {
|
|
43
|
+
title: string;
|
|
44
|
+
text: string;
|
|
45
|
+
btnRetry: string;
|
|
46
|
+
};
|
|
47
|
+
ru: {
|
|
48
|
+
title: string;
|
|
49
|
+
text: string;
|
|
50
|
+
btnRetry: string;
|
|
51
|
+
};
|
|
52
|
+
tr: {
|
|
53
|
+
title: string;
|
|
54
|
+
text: string;
|
|
55
|
+
btnRetry: string;
|
|
56
|
+
};
|
|
57
|
+
vi: {
|
|
58
|
+
title: string;
|
|
59
|
+
text: string;
|
|
60
|
+
btnRetry: string;
|
|
61
|
+
};
|
|
62
|
+
zh: {
|
|
63
|
+
title: string;
|
|
64
|
+
text: string;
|
|
65
|
+
btnRetry: string;
|
|
66
|
+
};
|
|
67
|
+
pl: {
|
|
68
|
+
title: string;
|
|
69
|
+
text: string;
|
|
70
|
+
btnRetry: string;
|
|
71
|
+
};
|
|
72
|
+
sv: {
|
|
73
|
+
title: string;
|
|
74
|
+
text: string;
|
|
75
|
+
btnRetry: string;
|
|
76
|
+
};
|
|
77
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Intergalactic } from '@semcore/core';
|
|
2
|
+
import type { WithI18nEnhanceProps } from '@semcore/core/lib/utils/enhances/i18nEnhance';
|
|
3
|
+
import type { ErrorsProps } from '../Error.type';
|
|
4
|
+
export type PageNotFoundProps = WithI18nEnhanceProps & {
|
|
5
|
+
/**
|
|
6
|
+
* href of the home link
|
|
7
|
+
* @default /
|
|
8
|
+
*/
|
|
9
|
+
homeLink?: string;
|
|
10
|
+
/**
|
|
11
|
+
* HTML tag of the error title
|
|
12
|
+
* @default h2
|
|
13
|
+
*/
|
|
14
|
+
titleTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'p';
|
|
15
|
+
};
|
|
16
|
+
export type PageNotFoundComponent = Intergalactic.Component<'div', PageNotFoundProps & ErrorsProps>;
|