@semcore/errors 3.1.2 → 3.2.0
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 +18 -0
- package/lib/cjs/AccessDenied/index.js.map +1 -1
- package/lib/cjs/Error.js +18 -14
- package/lib/cjs/Error.js.map +1 -1
- package/lib/cjs/Maintenance/index.js.map +1 -1
- package/lib/cjs/PageError/index.js.map +1 -1
- package/lib/cjs/PageNotFound/index.js.map +1 -1
- package/lib/cjs/ProjectNotFound/index.js.map +1 -1
- package/lib/cjs/index.js.map +1 -1
- package/lib/es6/AccessDenied/index.js.map +1 -1
- package/lib/es6/Error.js +18 -14
- package/lib/es6/Error.js.map +1 -1
- package/lib/es6/Maintenance/index.js.map +1 -1
- package/lib/es6/PageError/index.js.map +1 -1
- package/lib/es6/PageNotFound/index.js.map +1 -1
- package/lib/es6/ProjectNotFound/index.js.map +1 -1
- package/lib/es6/index.js.map +1 -1
- package/package.json +2 -2
- package/src/AccessDenied/index.jsx +0 -48
- package/src/AccessDenied/translations/de.json +0 -5
- package/src/AccessDenied/translations/en.json +0 -5
- package/src/AccessDenied/translations/es.json +0 -5
- package/src/AccessDenied/translations/fr.json +0 -5
- package/src/AccessDenied/translations/it.json +0 -5
- package/src/AccessDenied/translations/ja.json +0 -5
- package/src/AccessDenied/translations/ko.json +0 -5
- package/src/AccessDenied/translations/pt.json +0 -5
- package/src/AccessDenied/translations/ru.json +0 -5
- package/src/AccessDenied/translations/vi.json +0 -5
- package/src/AccessDenied/translations/zh.json +0 -5
- package/src/Error.jsx +0 -59
- package/src/Maintenance/index.jsx +0 -48
- package/src/Maintenance/translations/de.json +0 -5
- package/src/Maintenance/translations/en.json +0 -5
- package/src/Maintenance/translations/es.json +0 -5
- package/src/Maintenance/translations/fr.json +0 -5
- package/src/Maintenance/translations/it.json +0 -5
- package/src/Maintenance/translations/ja.json +0 -5
- package/src/Maintenance/translations/ko.json +0 -5
- package/src/Maintenance/translations/pt.json +0 -5
- package/src/Maintenance/translations/ru.json +0 -5
- package/src/Maintenance/translations/vi.json +0 -5
- package/src/Maintenance/translations/zh.json +0 -5
- package/src/PageError/index.jsx +0 -60
- package/src/PageError/translations/de.json +0 -5
- package/src/PageError/translations/en.json +0 -5
- package/src/PageError/translations/es.json +0 -5
- package/src/PageError/translations/fr.json +0 -5
- package/src/PageError/translations/it.json +0 -5
- package/src/PageError/translations/ja.json +0 -5
- package/src/PageError/translations/ko.json +0 -5
- package/src/PageError/translations/pt.json +0 -5
- package/src/PageError/translations/ru.json +0 -5
- package/src/PageError/translations/vi.json +0 -5
- package/src/PageError/translations/zh.json +0 -5
- package/src/PageNotFound/index.jsx +0 -48
- package/src/PageNotFound/translations/de.json +0 -5
- package/src/PageNotFound/translations/en.json +0 -5
- package/src/PageNotFound/translations/es.json +0 -5
- package/src/PageNotFound/translations/fr.json +0 -5
- package/src/PageNotFound/translations/it.json +0 -5
- package/src/PageNotFound/translations/ja.json +0 -5
- package/src/PageNotFound/translations/ko.json +0 -5
- package/src/PageNotFound/translations/pt.json +0 -5
- package/src/PageNotFound/translations/ru.json +0 -5
- package/src/PageNotFound/translations/vi.json +0 -5
- package/src/PageNotFound/translations/zh.json +0 -5
- package/src/ProjectNotFound/index.jsx +0 -54
- package/src/ProjectNotFound/translations/de.json +0 -6
- package/src/ProjectNotFound/translations/en.json +0 -6
- package/src/ProjectNotFound/translations/es.json +0 -6
- package/src/ProjectNotFound/translations/fr.json +0 -6
- package/src/ProjectNotFound/translations/it.json +0 -6
- package/src/ProjectNotFound/translations/ja.json +0 -6
- package/src/ProjectNotFound/translations/ko.json +0 -6
- package/src/ProjectNotFound/translations/pt.json +0 -6
- package/src/ProjectNotFound/translations/ru.json +0 -6
- package/src/ProjectNotFound/translations/vi.json +0 -6
- package/src/ProjectNotFound/translations/zh.json +0 -6
- package/src/index.d.ts +0 -92
- package/src/index.js +0 -7
- package/src/style/errors.shadow.css +0 -60
package/src/index.d.ts
DELETED
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Box, IFlexProps } from '@semcore/flex-box';
|
|
3
|
-
import { CProps, PropGetterFn, ReturnEl } from '@semcore/core';
|
|
4
|
-
import { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';
|
|
5
|
-
|
|
6
|
-
export type iconNamesErrors =
|
|
7
|
-
| 'access_denied'
|
|
8
|
-
| 'blocked'
|
|
9
|
-
| 'confirmation'
|
|
10
|
-
| 'connection_lost'
|
|
11
|
-
| 'deleted_account'
|
|
12
|
-
| 'dns'
|
|
13
|
-
| 'maintenance'
|
|
14
|
-
| 'no_payment'
|
|
15
|
-
| 'page_error'
|
|
16
|
-
| 'page_not_found'
|
|
17
|
-
| 'project_not_found'
|
|
18
|
-
| 'timeout';
|
|
19
|
-
|
|
20
|
-
export interface IErrorsProps extends IFlexProps {
|
|
21
|
-
/**
|
|
22
|
-
* Error icon
|
|
23
|
-
*/
|
|
24
|
-
icon?: string | React.ReactNode;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export interface IErrorsContext {
|
|
28
|
-
getTextProps: PropGetterFn;
|
|
29
|
-
getDescriptionProps: PropGetterFn;
|
|
30
|
-
getControlsProps: PropGetterFn;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export interface IProjectNotFoundProps extends IWithI18nEnhanceProps {
|
|
34
|
-
/**
|
|
35
|
-
* Link to the projects
|
|
36
|
-
* @default /projects
|
|
37
|
-
*/
|
|
38
|
-
projectsLink?: string;
|
|
39
|
-
contactsLink?: string;
|
|
40
|
-
supportTeamLink?: string;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export interface IPageNotFoundProps extends IWithI18nEnhanceProps {
|
|
44
|
-
/**
|
|
45
|
-
* href of the home link
|
|
46
|
-
* @default /
|
|
47
|
-
*/
|
|
48
|
-
homeLink?: string;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
export interface IPageErrorProps extends IWithI18nEnhanceProps {
|
|
52
|
-
/**
|
|
53
|
-
* Page reloading button click handler
|
|
54
|
-
* @default () => { if (canUseDOM()) { location.reload(); } }
|
|
55
|
-
*/
|
|
56
|
-
onClick?: (e: React.MouseEvent) => void;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface IMaintenanceProps extends IWithI18nEnhanceProps {
|
|
60
|
-
/**
|
|
61
|
-
* Tool name
|
|
62
|
-
*/
|
|
63
|
-
toolName: string;
|
|
64
|
-
/**
|
|
65
|
-
* href of the home link
|
|
66
|
-
* @default /
|
|
67
|
-
*/
|
|
68
|
-
homeLink?: string;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export interface IAccessDeniedProps extends IWithI18nEnhanceProps {
|
|
72
|
-
/**
|
|
73
|
-
* href of the home link
|
|
74
|
-
* @default /
|
|
75
|
-
*/
|
|
76
|
-
homeLink?: string;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
declare const Error: (<T>(props: CProps<IErrorsProps & T, IErrorsContext>) => ReturnEl) & {
|
|
80
|
-
Title: typeof Box;
|
|
81
|
-
Description: typeof Box;
|
|
82
|
-
Controls: typeof Box;
|
|
83
|
-
};
|
|
84
|
-
declare const ProjectNotFound: <T>(props: IProjectNotFoundProps & IErrorsProps & T) => ReturnEl;
|
|
85
|
-
declare const PageNotFound: <T>(props: IPageNotFoundProps & IErrorsProps & T) => ReturnEl;
|
|
86
|
-
declare const PageError: <T>(props: IPageErrorProps & IErrorsProps & T) => ReturnEl;
|
|
87
|
-
declare const Maintenance: <T>(props: IMaintenanceProps & IErrorsProps & T) => ReturnEl;
|
|
88
|
-
declare const AccessDenied: <T>(props: IAccessDeniedProps & IErrorsProps & T) => ReturnEl;
|
|
89
|
-
declare const getIconPath: (name: iconNamesErrors) => string;
|
|
90
|
-
|
|
91
|
-
export default Error;
|
|
92
|
-
export { ProjectNotFound, PageNotFound, PageError, Maintenance, AccessDenied, getIconPath };
|
package/src/index.js
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
export { default } from './Error';
|
|
2
|
-
export * from './Error';
|
|
3
|
-
export { default as AccessDenied } from './AccessDenied';
|
|
4
|
-
export { default as Maintenance } from './Maintenance';
|
|
5
|
-
export { default as PageError } from './PageError';
|
|
6
|
-
export { default as PageNotFound } from './PageNotFound';
|
|
7
|
-
export { default as ProjectNotFound } from './ProjectNotFound';
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
@import '@semcore/utils/style/var.css';
|
|
2
|
-
|
|
3
|
-
SError {
|
|
4
|
-
padding: 96px 0;
|
|
5
|
-
margin: 0 auto;
|
|
6
|
-
max-width: 960px;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
SInner {
|
|
10
|
-
width: 100%;
|
|
11
|
-
display: flex;
|
|
12
|
-
justify-content: flex-start;
|
|
13
|
-
flex-wrap: wrap;
|
|
14
|
-
align-items: flex-start;
|
|
15
|
-
box-sizing: border-box;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
SImageWrapper,
|
|
19
|
-
SImage {
|
|
20
|
-
width: 260px;
|
|
21
|
-
height: 260px;
|
|
22
|
-
@media (max-width: 320px) {
|
|
23
|
-
width: 200px;
|
|
24
|
-
height: 200px;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
SImageWrapper {
|
|
29
|
-
margin-right: 40px;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
SWrapper {
|
|
33
|
-
flex: 1 0 300px;
|
|
34
|
-
max-width: 100%;
|
|
35
|
-
margin-top: 32px;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
STitle {
|
|
39
|
-
font-size: var(--fs-700);
|
|
40
|
-
line-height: var(--lh-700);
|
|
41
|
-
color: var(--gray-800);
|
|
42
|
-
font-weight: 700;
|
|
43
|
-
margin: 0 0 16px 0;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
SDescription {
|
|
47
|
-
font-size: var(--fs-300);
|
|
48
|
-
line-height: var(--lh-300);
|
|
49
|
-
color: var(--gray-800);
|
|
50
|
-
margin: 0 0 24px 0;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
SControls {
|
|
54
|
-
display: flex;
|
|
55
|
-
align-items: center;
|
|
56
|
-
|
|
57
|
-
& > *:not(:last-child) {
|
|
58
|
-
margin-right: 12px;
|
|
59
|
-
}
|
|
60
|
-
}
|