aquasis-fe-components 1.0.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/README.md +30 -0
- package/dist/aquasis-fe-components.js +57456 -0
- package/dist/aquasis-fe-components.umd.cjs +1221 -0
- package/dist/components/FormField/Props.d.ts +60 -0
- package/dist/components/FormField/index.d.ts +15 -0
- package/dist/components/ThemeProvider/index.d.ts +6 -0
- package/dist/enums/app.d.ts +22 -0
- package/dist/enums/helpdesk.d.ts +7 -0
- package/dist/helpers/formFields.d.ts +6 -0
- package/dist/helpers/index.d.ts +5 -0
- package/dist/hooks/index.d.ts +19 -0
- package/dist/i18n/index.d.ts +2 -0
- package/dist/i18n/locales/br.json.d.ts +37 -0
- package/dist/i18n/locales/en.json.d.ts +37 -0
- package/dist/i18n/locales/es.json.d.ts +37 -0
- package/dist/i18n/locales/jp.json.d.ts +816 -0
- package/dist/i18n/locales/pt.json.d.ts +37 -0
- package/dist/i18n/locales/ro.json.d.ts +37 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/lib/Helpdesk/HelpdeskConnector.d.ts +7 -0
- package/dist/lib/Helpdesk/HelpdeskContent/index.d.ts +5 -0
- package/dist/lib/Helpdesk/index.d.ts +6 -0
- package/dist/services/HelpdeskServices.d.ts +2 -0
- package/dist/services/HttpClient.d.ts +3 -0
- package/dist/store/index.d.ts +5 -0
- package/dist/store/reducers/index.d.ts +2 -0
- package/dist/store/selectors/index.d.ts +0 -0
- package/dist/store/storage.d.ts +5 -0
- package/dist/themes/dark.data.d.ts +20 -0
- package/dist/themes/index.d.ts +5 -0
- package/dist/themes/light.data.d.ts +20 -0
- package/dist/types/app.d.ts +10 -0
- package/dist/types/helpdesk.d.ts +43 -0
- package/dist/utils/app.d.ts +0 -0
- package/package.json +112 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
"translation": {
|
|
3
|
+
"HELPDESK": {
|
|
4
|
+
"ERRORS_CODE": {
|
|
5
|
+
"DATATYPE_MISMATCH": "Deve conter apenas elementos do tipo de formato de arquivo válido.",
|
|
6
|
+
"INVALID_VALUE": "Valor inválido"
|
|
7
|
+
},
|
|
8
|
+
"FORM": {
|
|
9
|
+
"BUTTONS": {
|
|
10
|
+
"SEND": "Enviar"
|
|
11
|
+
},
|
|
12
|
+
"FIELDS": {
|
|
13
|
+
"ATTACHMENTS": "Anexos",
|
|
14
|
+
"DESCRIPTION": "Descrição",
|
|
15
|
+
"DESCRIPTION_PLACEHOLDER": "Insira a descrição...",
|
|
16
|
+
"EMAIL": "Email",
|
|
17
|
+
"EMAIL_PLACEHOLDER": "Insira o seu email…",
|
|
18
|
+
"NAME": "$t(Name)",
|
|
19
|
+
"NAME_PLACEHOLDER": "Insira seu nome...",
|
|
20
|
+
"SUBJECT": "Assunto",
|
|
21
|
+
"SUBJECT_PLACEHOLDER": "Insira o assunto...",
|
|
22
|
+
"TITLE": "Contacte-nos",
|
|
23
|
+
"UPLOAD_FILES": "<strong>Carregar ficheiro(s) (max. 5)</strong><br/><small>Clique para adicionar ou arraste e solte os ficheiros.</small>"
|
|
24
|
+
},
|
|
25
|
+
"TITLE": "Bem-vindo ao apoio"
|
|
26
|
+
},
|
|
27
|
+
"SUPPORT": "Apoio",
|
|
28
|
+
"TABLE": {
|
|
29
|
+
"CODE": "Mensagem",
|
|
30
|
+
"FIELD": "Campo"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
;
|
|
36
|
+
|
|
37
|
+
export default _default;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
"translation": {
|
|
3
|
+
"HELPDESK": {
|
|
4
|
+
"ERRORS_CODE": {
|
|
5
|
+
"DATATYPE_MISMATCH": "Ar trebui să conțină doar elemente de tip format de fișier valid",
|
|
6
|
+
"INVALID_VALUE": "Valoare invalida"
|
|
7
|
+
},
|
|
8
|
+
"FORM": {
|
|
9
|
+
"BUTTONS": {
|
|
10
|
+
"SEND": "Trimite"
|
|
11
|
+
},
|
|
12
|
+
"FIELDS": {
|
|
13
|
+
"ATTACHMENTS": "Atașamente",
|
|
14
|
+
"DESCRIPTION": "Descriere",
|
|
15
|
+
"DESCRIPTION_PLACEHOLDER": "Introduceți descrierea...",
|
|
16
|
+
"EMAIL": "Email",
|
|
17
|
+
"EMAIL_PLACEHOLDER": "Introduceți e-mailul dvs...",
|
|
18
|
+
"NAME": "$t(Name)",
|
|
19
|
+
"NAME_PLACEHOLDER": "Introduceți numele dvs...",
|
|
20
|
+
"SUBJECT": "Subiect",
|
|
21
|
+
"SUBJECT_PLACEHOLDER": "Introduceți subiectul...",
|
|
22
|
+
"TITLE": "Contactaţi-ne",
|
|
23
|
+
"UPLOAD_FILES": "<strong>Încărcați fișiere (max. 5)</strong><br/><small>Faceți clic pentru a adăuga sau trage și plasați fișiere.</small>"
|
|
24
|
+
},
|
|
25
|
+
"TITLE": "Bun venit la sprijin"
|
|
26
|
+
},
|
|
27
|
+
"SUPPORT": "A sustine",
|
|
28
|
+
"TABLE": {
|
|
29
|
+
"CODE": "Mesaj",
|
|
30
|
+
"FIELD": "Camp"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
;
|
|
36
|
+
|
|
37
|
+
export default _default;
|
package/dist/index.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.helpdesk__container .ant-card .ant-card-body{height:100%;max-height:80dvh;overflow-y:auto}.helpdesk__content{border-radius:10px;padding:10px;max-width:400px;background-color:#f7f7f7}.helpdesk__title{padding:10px 16px}.helpdesk__title.ant-typography{color:#60c5cf}.helpdesk__fields-files{flex-direction:column;margin-top:10px;width:100%}.helpdesk__fields-files .ant-upload-list{margin-top:5px;width:100%}body.dark .helpdesk__content{background-color:#333}.form__item-multiTable .ant-transfer-list-body-customize-wrapper{overflow-y:auto}*{padding:0;margin:0;box-sizing:border-box}body{height:100vh;width:100vw;overflow:hidden;background-color:#fff}body #root{height:100%}body ::placeholder{color:#919191}body .map-container{height:90dvh;width:100%}body .map-container canvas{border-radius:8px}body .map-widgets-wrapper{padding:0;min-width:400px;max-height:540px;overflow-y:auto}body .page__title-container{margin:0;padding:10px 20px;height:auto;border-bottom:1px solid rgba(5,5,5,.06)}body .page__title-container h1,body .page__title-container h2,body .page__title-container h3,body .page__title-container h4,body .page__title-container h5{color:#60c5cf;margin:0}body .recaptcha{display:flex;justify-content:center;width:100%;margin-bottom:24px}body .ant-layout-sider-trigger{border-right:1px solid rgba(5,5,5,.06)}body .ant-skeleton.ant-skeleton-element,body .ant-skeleton.ant-skeleton-element .ant-skeleton-image{width:100%;height:100%}body .filter__buttons{display:flex;align-items:center;justify-content:center;width:100%;gap:10px}body .ant-form-item .ant-form-item-control-input{min-height:32px}body .ant-form-item .ant-form-item-control-input .ant-form-item-control-input-content{display:flex}body .ant-form-item .ant-form-item-control-input .ant-form-item-control-input-content .ant-upload-wrapper{display:flex;align-items:center}body .ant-form-item .ant-form-item-control-input .ant-form-item-control-input-content .ant-upload-wrapper .ant-upload-list-item{margin:0 0 0 10px}body .avatar-uploader.ant-upload-wrapper.ant-upload-picture-circle-wrapper .ant-upload,body .avatar-uploader.ant-upload-wrapper.ant-upload-picture-circle-wrapper .ant-upload-select{margin-inline-end:0;margin-bottom:0}body .avatar-uploader .float-btn{opacity:0;position:absolute;bottom:3px;left:40%;transition:opacity .5s ease;display:flex;justify-content:center;align-items:center}body .avatar-uploader .float-btn-container{width:100%;height:100%;display:flex;justify-content:center}body .avatar-uploader .float-btn-container:hover .float-btn{opacity:1}body .rule-form-badge{margin-right:5px}body .rule-form-badge.ant-badge.ant-badge-status .ant-badge-status-dot{width:20px;height:20px}body .skeleton__loading{height:100%}body .ant-list-items .ant-list-item .ant-list-item-action{margin-inline-start:12px}body .ant-notification .ant-notification-notice.table-notification{min-width:500px}body .ant-notification .ant-notification-notice.notification-error{width:250px;padding:14px 16px}body .ant-notification .ant-notification-notice.notification-error .ant-notification-notice-icon{font-size:20px}body .ant-notification .ant-notification-notice.notification-error .ant-notification-notice-close{top:14px;right:14px}body .ant-notification .ant-notification-notice.notification-error .ant-notification-notice-message{font-size:14px;margin-inline-start:30px}body .ant-notification .ant-notification-notice.notification-error .ant-notification-notice-description{font-size:12px;margin-inline-start:30px}body .ant-spin-nested-loading,body .ant-spin-nested-loading .ant-spin-container{height:100%;width:100%}body .ant-skeleton.ant-skeleton-element.custom-skeleton{display:flex}body .esri-attribution{display:none}body.dark{background-color:#333}body.dark .ant-layout-sider-trigger{border-right:1px solid rgba(253,253,253,.12)}body.dark .page__title-container{border-bottom:1px solid rgba(253,253,253,.12)}body.dark .ant-popover .ant-popover-arrow{--antd-arrow-background-color: #3b3b3b}body.dark .ant-popover .ant-popover-content .ant-popover-inner{background-color:#3b3b3b}body.dark .ant-badge .ant-badge-count{color:#fff;box-shadow:0 0 0 1px #3b3b3b}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const ConnectedHelpdesk: import("react-redux").ConnectedComponent<import("react").FC<import("./index").HelpdeskProps>, {
|
|
3
|
+
size?: import("antd/es/button").ButtonSize;
|
|
4
|
+
context?: import("react").Context<import("react-redux").ReactReduxContextValue<any, import("redux").UnknownAction> | null> | undefined;
|
|
5
|
+
store?: import("redux").Store<any, import("redux").UnknownAction, unknown> | undefined;
|
|
6
|
+
}>;
|
|
7
|
+
export { ConnectedHelpdesk };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const store: import("@reduxjs/toolkit").EnhancedStore<{}, never, import("@reduxjs/toolkit").Tuple<[import("redux").StoreEnhancer<{
|
|
2
|
+
dispatch: import("redux-thunk").ThunkDispatch<{}, undefined, import("redux").UnknownAction>;
|
|
3
|
+
}>, import("redux").StoreEnhancer]>>;
|
|
4
|
+
export type RootState = ReturnType<typeof store.getState>;
|
|
5
|
+
export type AppDispatch = typeof store.dispatch;
|
|
File without changes
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export declare const Dark: {
|
|
2
|
+
ColorPrimary: string;
|
|
3
|
+
PrimaryColorText: string;
|
|
4
|
+
ColorTextQuaternary: string;
|
|
5
|
+
PrimaryColorBgContainer: string;
|
|
6
|
+
SecondaryBorderColor: string;
|
|
7
|
+
ColorBgHeader: string;
|
|
8
|
+
ColorBgContent: string;
|
|
9
|
+
ColorBgActive: string;
|
|
10
|
+
ColorBgChartBtn: string;
|
|
11
|
+
DisabledColor: string;
|
|
12
|
+
ChartDefColor: string;
|
|
13
|
+
ChartSecColor: string;
|
|
14
|
+
NeutralColor1: string;
|
|
15
|
+
NeutralColor2: string;
|
|
16
|
+
NeutralColor3: string;
|
|
17
|
+
ColorBgTrigger: string;
|
|
18
|
+
ColorWhite: string;
|
|
19
|
+
ColorLinkHover: string;
|
|
20
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export declare const Light: {
|
|
2
|
+
ColorPrimary: string;
|
|
3
|
+
PrimaryColorText: string;
|
|
4
|
+
ColorTextQuaternary: string;
|
|
5
|
+
PrimaryColorBgContainer: string;
|
|
6
|
+
SecondaryBorderColor: string;
|
|
7
|
+
ColorBgHeader: string;
|
|
8
|
+
ColorBgContent: string;
|
|
9
|
+
ColorBgActive: string;
|
|
10
|
+
ColorBgChartBtn: string;
|
|
11
|
+
DisabledColor: string;
|
|
12
|
+
ChartDefColor: string;
|
|
13
|
+
ChartSecColor: string;
|
|
14
|
+
NeutralColor1: string;
|
|
15
|
+
NeutralColor2: string;
|
|
16
|
+
NeutralColor3: string;
|
|
17
|
+
ColorBgTrigger: string;
|
|
18
|
+
ColorWhite: string;
|
|
19
|
+
ColorLinkHover: string;
|
|
20
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export type FlagType = "EN" | "ES" | "PT" | "RO" | "JP" | "BR";
|
|
2
|
+
declare global {
|
|
3
|
+
interface Window {
|
|
4
|
+
baseUrl: string;
|
|
5
|
+
}
|
|
6
|
+
}
|
|
7
|
+
export type AppIdsType = {
|
|
8
|
+
"426E659E-F4EF-496A-9DC8-97C6580382E8": "flowise";
|
|
9
|
+
"26EE36AF-E3AB-41B0-9AB6-BE8BC95CAC33": "meterwise";
|
|
10
|
+
};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { HelpdeskFields } from '../enums/helpdesk';
|
|
2
|
+
import { RcFile } from "antd/es/upload";
|
|
3
|
+
export interface HelpdeskFormValues {
|
|
4
|
+
[HelpdeskFields.Name]: string;
|
|
5
|
+
[HelpdeskFields.Email]: string;
|
|
6
|
+
[HelpdeskFields.Subject]: string;
|
|
7
|
+
[HelpdeskFields.Description]: string;
|
|
8
|
+
[HelpdeskFields.Attachments]: RcFile[];
|
|
9
|
+
}
|
|
10
|
+
export interface TicketField {
|
|
11
|
+
name: string;
|
|
12
|
+
position: number;
|
|
13
|
+
required_for_closure: boolean;
|
|
14
|
+
required_for_agents: boolean;
|
|
15
|
+
type: string;
|
|
16
|
+
default: boolean;
|
|
17
|
+
customers_can_edit: boolean;
|
|
18
|
+
customers_can_filter: boolean;
|
|
19
|
+
label_for_customers: string;
|
|
20
|
+
required_for_customers: boolean;
|
|
21
|
+
displayed_to_customers: boolean;
|
|
22
|
+
belongs_to_section: boolean;
|
|
23
|
+
id: number;
|
|
24
|
+
label: string;
|
|
25
|
+
description?: string;
|
|
26
|
+
created_at: string;
|
|
27
|
+
updated_at: string;
|
|
28
|
+
portal_cc?: boolean;
|
|
29
|
+
portal_cc_to?: string;
|
|
30
|
+
choices?: string[];
|
|
31
|
+
}
|
|
32
|
+
export interface CreateTicketPayload extends HelpdeskFormValues {
|
|
33
|
+
appName: string;
|
|
34
|
+
}
|
|
35
|
+
export interface HelpdeskError {
|
|
36
|
+
description: string;
|
|
37
|
+
errors: HelpdeskErrorDetail[];
|
|
38
|
+
}
|
|
39
|
+
export interface HelpdeskErrorDetail {
|
|
40
|
+
field: string;
|
|
41
|
+
message: string;
|
|
42
|
+
code: string;
|
|
43
|
+
}
|
|
File without changes
|
package/package.json
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "aquasis-fe-components",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "1.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "ISC",
|
|
7
|
+
"author": "Ewerton Souza",
|
|
8
|
+
"scripts": {
|
|
9
|
+
"dev": "vite",
|
|
10
|
+
"build": "tsc && vite build",
|
|
11
|
+
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
|
|
12
|
+
"preview": "vite preview",
|
|
13
|
+
"updPatchVersion": "npm version patch --no-git-tag-version",
|
|
14
|
+
"prepublish": "yarn build && git push && git push --tags && npm publish"
|
|
15
|
+
},
|
|
16
|
+
"peerDependencies": {
|
|
17
|
+
"react": "18.x",
|
|
18
|
+
"react-dom": "18.x"
|
|
19
|
+
},
|
|
20
|
+
"files": [
|
|
21
|
+
"dist"
|
|
22
|
+
],
|
|
23
|
+
"main": "dist/aquasis-fe-components.umd.cjs",
|
|
24
|
+
"module": "dist/aquasis-fe-components.js",
|
|
25
|
+
"types": "dist/index.d.ts",
|
|
26
|
+
"exports": {
|
|
27
|
+
".": {
|
|
28
|
+
"import": {
|
|
29
|
+
"default": "./dist/aquasis-fe-components.js",
|
|
30
|
+
"types": "./dist/index.d.ts"
|
|
31
|
+
},
|
|
32
|
+
"require": {
|
|
33
|
+
"default": "./dist/aquasis-fe-components.umd.cjs",
|
|
34
|
+
"types": "./dist/index.d.ts"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"repository": {
|
|
39
|
+
"type": "git",
|
|
40
|
+
"url": "git+https://github.com/AQUASISPT/FrontendComponents.git"
|
|
41
|
+
},
|
|
42
|
+
"keywords": [
|
|
43
|
+
"react"
|
|
44
|
+
],
|
|
45
|
+
"homepage": "https://github.com/AQUASISPT/FrontendComponents",
|
|
46
|
+
"browserslist": {
|
|
47
|
+
"production": [
|
|
48
|
+
">0.2%",
|
|
49
|
+
"not dead",
|
|
50
|
+
"not op_mini all"
|
|
51
|
+
],
|
|
52
|
+
"development": [
|
|
53
|
+
"last 1 chrome version",
|
|
54
|
+
"last 1 firefox version",
|
|
55
|
+
"last 1 safari version"
|
|
56
|
+
],
|
|
57
|
+
"eslintConfig": {
|
|
58
|
+
"env": {
|
|
59
|
+
"browser": true,
|
|
60
|
+
"node": true,
|
|
61
|
+
"es2020": true
|
|
62
|
+
},
|
|
63
|
+
"extends": [
|
|
64
|
+
"eslint:recommended",
|
|
65
|
+
"plugin:react/recommended"
|
|
66
|
+
],
|
|
67
|
+
"parserOptions": {
|
|
68
|
+
"sourceType": "module"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"devDependencies": {
|
|
73
|
+
"@types/node": "^20.11.16",
|
|
74
|
+
"@types/react": "^18.2.43",
|
|
75
|
+
"@types/react-dom": "^18.2.17",
|
|
76
|
+
"@typescript-eslint/eslint-plugin": "^6.14.0",
|
|
77
|
+
"@typescript-eslint/parser": "^6.14.0",
|
|
78
|
+
"@vitejs/plugin-react": "^4.2.1",
|
|
79
|
+
"eslint": "^8.55.0",
|
|
80
|
+
"eslint-plugin-react-hooks": "^4.6.0",
|
|
81
|
+
"eslint-plugin-react-refresh": "^0.4.5",
|
|
82
|
+
"json": "^11.0.0",
|
|
83
|
+
"sass": "^1.70.0",
|
|
84
|
+
"typescript": "^5.2.2",
|
|
85
|
+
"vite": "^5.0.8"
|
|
86
|
+
},
|
|
87
|
+
"dependencies": {
|
|
88
|
+
"@ant-design/icons": "^5.3.0",
|
|
89
|
+
"@fortawesome/fontawesome-svg-core": "^6.5.2",
|
|
90
|
+
"@fortawesome/free-regular-svg-icons": "^6.5.2",
|
|
91
|
+
"@fortawesome/free-solid-svg-icons": "^6.5.2",
|
|
92
|
+
"@fortawesome/react-fontawesome": "^0.2.1",
|
|
93
|
+
"@reduxjs/toolkit": "^2.2.5",
|
|
94
|
+
"@types/hoist-non-react-statics": "^3.3.5",
|
|
95
|
+
"@uidotdev/usehooks": "^2.4.1",
|
|
96
|
+
"antd": "^5.13.3",
|
|
97
|
+
"axios": "^1.7.0",
|
|
98
|
+
"dayjs": "^1.11.11",
|
|
99
|
+
"hoist-non-react-statics": "^3.3.2",
|
|
100
|
+
"i18next": "^23.11.4",
|
|
101
|
+
"i18next-browser-languagedetector": "^8.0.0",
|
|
102
|
+
"react": "^18.2.0",
|
|
103
|
+
"react-dom": "^18.2.0",
|
|
104
|
+
"react-i18next": "^14.1.1",
|
|
105
|
+
"react-redux": "^9.1.2",
|
|
106
|
+
"redux": "^5.0.1",
|
|
107
|
+
"scss": "^0.2.4",
|
|
108
|
+
"universal-cookie": "^7.1.4",
|
|
109
|
+
"vite-plugin-dts": "^3.7.2",
|
|
110
|
+
"vite-plugin-lib-inject-css": "^2.1.1"
|
|
111
|
+
}
|
|
112
|
+
}
|