@omniumretail/component-library 1.2.70 → 1.2.72
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/component-library.umd.js +1154 -0
- package/dist/{types/components → components}/AnalyticsBar/helpers/codeMutation.d.ts +2 -2
- package/dist/{types/components → components}/AnalyticsBar/index.d.ts +2 -1
- package/dist/{types/components → components}/Button/index.d.ts +2 -1
- package/dist/{types/components → components}/Category/index.d.ts +2 -1
- package/dist/{types/components → components}/CategoryReadOnly/index.d.ts +2 -1
- package/dist/{types/components → components}/CategoryResponse/index.d.ts +3 -2
- package/dist/{types/components → components}/DatePicker/index.d.ts +2 -1
- package/dist/{types/components → components}/DatePickerTag/index.d.ts +2 -1
- package/dist/{types/components → components}/DropdownButton/index.d.ts +3 -2
- package/dist/{types/components → components}/Footer2/index.d.ts +2 -1
- package/dist/{types/components → components}/Header/Header.data.d.ts +2 -1
- package/dist/{types/components → components}/Header/Header.types.d.ts +2 -1
- package/dist/{types/components → components}/Header/index.d.ts +2 -1
- package/dist/{types/components → components}/Input/index.d.ts +2 -1
- package/dist/{types/components → components}/InputCountryCode/index.d.ts +2 -1
- package/dist/{types/components → components}/Link/index.d.ts +2 -1
- package/dist/{types/components → components}/Menu/helpers/codeMutation.d.ts +2 -2
- package/dist/{types/components → components}/Menu/index.d.ts +2 -1
- package/dist/{types/components → components}/MobileTable/index.d.ts +2 -1
- package/dist/{types/components → components}/ModalWithTable/index.d.ts +2 -1
- package/dist/{types/components → components}/Notification/index.d.ts +2 -1
- package/dist/{types/components → components}/Radio/index.d.ts +3 -2
- package/dist/{types/components → components}/ResponsiveTable/index.d.ts +2 -1
- package/dist/{types/components → components}/Select/index.d.ts +2 -1
- package/dist/{types/components → components}/Switch/index.d.ts +2 -1
- package/dist/{types/components → components}/Table/index.d.ts +2 -1
- package/dist/{types/components → components}/Tag/index.d.ts +3 -2
- package/dist/{types/components → components}/Upload/index.d.ts +3 -2
- package/dist/{types/components → components}/WebCam/index.d.ts +2 -1
- package/{src/locales/en.json → dist/locales/en.json.d.ts} +4 -2
- package/{src/locales/es.json → dist/locales/es.json.d.ts} +4 -2
- package/{src/locales/pt.json → dist/locales/pt.json.d.ts} +4 -1
- package/package.json +98 -183
- package/NPMPUBLISH.md +0 -29
- package/bitbucket-pipelines.yml +0 -95
- package/dist/780.bundle.js +0 -1
- package/dist/838.bundle.js +0 -2
- package/dist/838.bundle.js.LICENSE.txt +0 -1
- package/dist/bundle.js +0 -2
- package/dist/bundle.js.LICENSE.txt +0 -451
- package/dist/main.css +0 -36
- package/dist/types/components/AnalyticsBar/AnalyticsBar.stories.d.ts +0 -4
- package/dist/types/components/BellNotifications/BellNotifications.stories.d.ts +0 -4
- package/dist/types/components/Button/Button.stories.d.ts +0 -5
- package/dist/types/components/Category/Category.stories.d.ts +0 -3
- package/dist/types/components/CategoryReadOnly/CategoryReadOnly.stories.d.ts +0 -3
- package/dist/types/components/CategoryResponse/CategoryResponse.stories.d.ts +0 -3
- package/dist/types/components/DatePicker/DatePicker.stories.d.ts +0 -4
- package/dist/types/components/DatePickerTag/DatePickerTag.stories.d.ts +0 -4
- package/dist/types/components/DropdownButton/DropdownButton.stories.d.ts +0 -4
- package/dist/types/components/ExportTableData/ExportTableData.stories.d.ts +0 -3
- package/dist/types/components/Footer/Footer.stories.d.ts +0 -4
- package/dist/types/components/Footer2/Footer.stories.d.ts +0 -5
- package/dist/types/components/Header/Header.stories.d.ts +0 -4
- package/dist/types/components/Input/Input.stories.d.ts +0 -4
- package/dist/types/components/InputCountryCode/inputCountryCode.stories.d.ts +0 -4
- package/dist/types/components/Label/Label.stories.d.ts +0 -5
- package/dist/types/components/Link/Link.stories.d.ts +0 -6
- package/dist/types/components/Menu/Menu.stories.d.ts +0 -4
- package/dist/types/components/MobileTable/MobileTable.stories.d.ts +0 -4
- package/dist/types/components/ModalConfirmation/ModalConfirmation.stories.d.ts +0 -4
- package/dist/types/components/ModalWithTable/ModalWithTable.stories.d.ts +0 -4
- package/dist/types/components/Navigation/Navigation.stories.d.ts +0 -4
- package/dist/types/components/Notification/Notification.stories.d.ts +0 -4
- package/dist/types/components/Questions/Questions.stories.d.ts +0 -3
- package/dist/types/components/Radio/Radio.stories.d.ts +0 -4
- package/dist/types/components/ResponseType/ResponseType.stories.d.ts +0 -3
- package/dist/types/components/ResponsiveTable/ResponsiveTable.stories.d.ts +0 -8
- package/dist/types/components/Select/Select.stories.d.ts +0 -5
- package/dist/types/components/Separator/Separator.stories.d.ts +0 -5
- package/dist/types/components/Sidebar/Sidebar.stories.d.ts +0 -5
- package/dist/types/components/Switch/Switch.stories.d.ts +0 -4
- package/dist/types/components/Table/Table.stories.d.ts +0 -8
- package/dist/types/components/Tag/Tag.stories.d.ts +0 -4
- package/dist/types/components/Upload/Upload.stories.d.ts +0 -3
- package/dist/types/components/UserInfo/UserInfo.stories.d.ts +0 -3
- package/dist/types/components/WebCam/WebCam.stories.d.ts +0 -3
- package/src/assets/code-brackets.svg +0 -1
- package/src/assets/colors.svg +0 -1
- package/src/assets/comments.svg +0 -1
- package/src/assets/direction.svg +0 -1
- package/src/assets/flow.svg +0 -1
- package/src/assets/fonts/Silka-Bold.woff2 +0 -0
- package/src/assets/fonts/Silka-Regular.woff2 +0 -0
- package/src/assets/images/A2AI-logo.png +0 -0
- package/src/assets/images/omnium-retail-logo-white.png +0 -0
- package/src/assets/images/omnium-retail-logo.png +0 -0
- package/src/assets/images/omnium-retail_icon.png +0 -0
- package/src/assets/plugin.svg +0 -1
- package/src/assets/repo.svg +0 -1
- package/src/assets/scss/_combinations.scss +0 -0
- package/src/assets/scss/_global.scss +0 -89
- package/src/assets/scss/index.scss +0 -2
- package/src/assets/stackalt.svg +0 -1
- package/src/components/AnalyticsBar/AnalyticsBar.stories.tsx +0 -236
- package/src/components/AnalyticsBar/helpers/codeMutation.tsx +0 -19
- package/src/components/AnalyticsBar/index.tsx +0 -76
- package/src/components/AnalyticsBar/interfaces/analyticsBar.tsx +0 -13
- package/src/components/AnalyticsBar/styles.module.scss +0 -137
- package/src/components/BellNotifications/BellNotifications.stories.tsx +0 -200
- package/src/components/BellNotifications/index.tsx +0 -154
- package/src/components/BellNotifications/styles.module.scss +0 -239
- package/src/components/Button/Button.stories.tsx +0 -26
- package/src/components/Button/index.tsx +0 -24
- package/src/components/Button/styles.module.scss +0 -70
- package/src/components/Category/Category.stories.tsx +0 -371
- package/src/components/Category/CategoryContent/index.tsx +0 -255
- package/src/components/Category/CategoryContent/styles.module.scss +0 -69
- package/src/components/Category/CategorySidebar/index.tsx +0 -344
- package/src/components/Category/CategorySidebar/styles.module.scss +0 -28
- package/src/components/Category/index.tsx +0 -58
- package/src/components/Category/styles.module.scss +0 -13
- package/src/components/CategoryReadOnly/CategoryReadOnly.stories.tsx +0 -274
- package/src/components/CategoryReadOnly/evaluationOptions.tsx +0 -81
- package/src/components/CategoryReadOnly/index.tsx +0 -328
- package/src/components/CategoryReadOnly/styles.module.scss +0 -214
- package/src/components/CategoryResponse/CategoryResponse.stories.tsx +0 -312
- package/src/components/CategoryResponse/evaluationOptions.tsx +0 -81
- package/src/components/CategoryResponse/index.tsx +0 -502
- package/src/components/CategoryResponse/styles.module.scss +0 -365
- package/src/components/DatePicker/DatePicker.stories.tsx +0 -16
- package/src/components/DatePicker/index.tsx +0 -38
- package/src/components/DatePicker/styles.module.scss +0 -3
- package/src/components/DatePickerTag/DatePickerTag.stories.tsx +0 -19
- package/src/components/DatePickerTag/index.tsx +0 -91
- package/src/components/DatePickerTag/styles.module.scss +0 -32
- package/src/components/DropdownButton/DropdownButton.stories.tsx +0 -24
- package/src/components/DropdownButton/index.tsx +0 -36
- package/src/components/DropdownButton/styles.module.scss +0 -9
- package/src/components/ExportTableData/ExportTableData.stories.tsx +0 -43
- package/src/components/ExportTableData/index.tsx +0 -37
- package/src/components/ExportTableData/styles.module.scss +0 -4
- package/src/components/Footer/Footer.stories.tsx +0 -15
- package/src/components/Footer/index.tsx +0 -45
- package/src/components/Footer/styles.module.scss +0 -38
- package/src/components/Footer2/Footer.stories.tsx +0 -184
- package/src/components/Footer2/index.tsx +0 -322
- package/src/components/Footer2/styles.module.scss +0 -292
- package/src/components/Header/Header.data.ts +0 -26
- package/src/components/Header/Header.stories.tsx +0 -236
- package/src/components/Header/Header.types.ts +0 -32
- package/src/components/Header/README.md +0 -38
- package/src/components/Header/index.tsx +0 -200
- package/src/components/Header/styles.module.scss +0 -216
- package/src/components/Input/Input.stories.tsx +0 -13
- package/src/components/Input/index.tsx +0 -31
- package/src/components/Input/styles.module.scss +0 -8
- package/src/components/InputCountryCode/index.tsx +0 -79
- package/src/components/InputCountryCode/inputCountryCode.stories.tsx +0 -55
- package/src/components/InputCountryCode/styles.module.scss +0 -3
- package/src/components/Label/Label.stories.tsx +0 -21
- package/src/components/Label/index.tsx +0 -19
- package/src/components/Label/styles.module.scss +0 -17
- package/src/components/Link/Link.stories.tsx +0 -30
- package/src/components/Link/index.tsx +0 -21
- package/src/components/Link/styles.module.scss +0 -24
- package/src/components/Menu/Menu.stories.tsx +0 -178
- package/src/components/Menu/helpers/codeMutation.tsx +0 -19
- package/src/components/Menu/index.tsx +0 -24
- package/src/components/Menu/styles.module.scss +0 -0
- package/src/components/MobileTable/MobileTable.stories.tsx +0 -27
- package/src/components/MobileTable/index.tsx +0 -102
- package/src/components/MobileTable/styles.module.scss +0 -75
- package/src/components/ModalConfirmation/ModalConfirmation.stories.tsx +0 -40
- package/src/components/ModalConfirmation/ModalStatusList.tsx +0 -5
- package/src/components/ModalConfirmation/index.tsx +0 -71
- package/src/components/ModalConfirmation/styles.module.scss +0 -62
- package/src/components/ModalWithTable/ModalWithTable.stories.tsx +0 -99
- package/src/components/ModalWithTable/index.tsx +0 -238
- package/src/components/ModalWithTable/styles.module.scss +0 -77
- package/src/components/Navigation/Navigation.stories.tsx +0 -21
- package/src/components/Navigation/index.tsx +0 -91
- package/src/components/Navigation/styles.module.scss +0 -91
- package/src/components/Notification/Notification.stories.tsx +0 -32
- package/src/components/Notification/index.tsx +0 -28
- package/src/components/Questions/Questions.stories.tsx +0 -37
- package/src/components/Questions/SingleQuestion/index.tsx +0 -337
- package/src/components/Questions/SingleQuestion/styles.module.scss +0 -142
- package/src/components/Questions/index.tsx +0 -124
- package/src/components/Questions/styles.modules.scss +0 -0
- package/src/components/Radio/Radio.stories.tsx +0 -43
- package/src/components/Radio/index.tsx +0 -26
- package/src/components/Radio/styles.module.scss +0 -24
- package/src/components/ResponseType/ResponseType.stories.tsx +0 -393
- package/src/components/ResponseType/index.tsx +0 -100
- package/src/components/ResponseType/styles.module.scss +0 -31
- package/src/components/ResponsiveTable/ResponsiveTable.stories.tsx +0 -386
- package/src/components/ResponsiveTable/index.tsx +0 -389
- package/src/components/ResponsiveTable/styles.module.scss +0 -153
- package/src/components/Select/Select.stories.tsx +0 -39
- package/src/components/Select/index.tsx +0 -27
- package/src/components/Select/styles.module.scss +0 -19
- package/src/components/Separator/Separator.stories.tsx +0 -22
- package/src/components/Separator/index.tsx +0 -27
- package/src/components/Separator/styles.module.scss +0 -25
- package/src/components/Sidebar/Sidebar.stories.tsx +0 -85
- package/src/components/Sidebar/index.tsx +0 -127
- package/src/components/Sidebar/styles.module.scss +0 -141
- package/src/components/Switch/Switch.stories.tsx +0 -14
- package/src/components/Switch/index.tsx +0 -18
- package/src/components/Switch/styles.module.scss +0 -7
- package/src/components/Table/Table.stories.tsx +0 -337
- package/src/components/Table/index.tsx +0 -313
- package/src/components/Table/styles.module.scss +0 -97
- package/src/components/Tag/Tag.stories.tsx +0 -32
- package/src/components/Tag/index.tsx +0 -295
- package/src/components/Tag/styles.module.scss +0 -104
- package/src/components/Upload/Upload.stories.tsx +0 -45
- package/src/components/Upload/index.tsx +0 -112
- package/src/components/Upload/styles.module.scss +0 -29
- package/src/components/UserInfo/UserInfo.stories.tsx +0 -38
- package/src/components/UserInfo/index.tsx +0 -77
- package/src/components/UserInfo/styles.module.scss +0 -35
- package/src/components/WebCam/WebCam.stories.tsx +0 -24
- package/src/components/WebCam/index.tsx +0 -73
- package/src/components/WebCam/styles.module.scss +0 -37
- package/src/components/index.tsx +0 -34
- package/src/constants/i18n.ts +0 -25
- package/src/constants/logoCompanyHelper.ts +0 -52
- package/src/constants/translationHelper.ts +0 -7
- package/src/index.ts +0 -3
- package/src/types/Global.d.ts +0 -4
- package/tsconfig.json +0 -29
- package/webpack.config.js +0 -51
- /package/dist/{types/components → components}/AnalyticsBar/interfaces/analyticsBar.d.ts +0 -0
- /package/dist/{types/components → components}/BellNotifications/index.d.ts +0 -0
- /package/dist/{types/components → components}/Category/CategoryContent/index.d.ts +0 -0
- /package/dist/{types/components → components}/Category/CategorySidebar/index.d.ts +0 -0
- /package/dist/{types/components → components}/CategoryReadOnly/evaluationOptions.d.ts +0 -0
- /package/dist/{types/components → components}/CategoryResponse/evaluationOptions.d.ts +0 -0
- /package/dist/{types/components → components}/ExportTableData/index.d.ts +0 -0
- /package/dist/{types/components → components}/Footer/index.d.ts +0 -0
- /package/dist/{types/components → components}/Label/index.d.ts +0 -0
- /package/dist/{types/components → components}/ModalConfirmation/ModalStatusList.d.ts +0 -0
- /package/dist/{types/components → components}/ModalConfirmation/index.d.ts +0 -0
- /package/dist/{types/components → components}/Navigation/index.d.ts +0 -0
- /package/dist/{types/components → components}/Questions/SingleQuestion/index.d.ts +0 -0
- /package/dist/{types/components → components}/Questions/index.d.ts +0 -0
- /package/dist/{types/components → components}/ResponseType/index.d.ts +0 -0
- /package/dist/{types/components → components}/Separator/index.d.ts +0 -0
- /package/dist/{types/components → components}/Sidebar/index.d.ts +0 -0
- /package/dist/{types/components → components}/UserInfo/index.d.ts +0 -0
- /package/dist/{types/components → components}/index.d.ts +0 -0
- /package/dist/{types/constants → constants}/i18n.d.ts +0 -0
- /package/dist/{types/constants → constants}/logoCompanyHelper.d.ts +0 -0
- /package/dist/{types/constants → constants}/translationHelper.d.ts +0 -0
- /package/dist/{types/index.d.ts → index.d.ts} +0 -0
- /package/{public → dist}/index.ts +0 -0
|
@@ -1,292 +0,0 @@
|
|
|
1
|
-
.footer {
|
|
2
|
-
display: flex;
|
|
3
|
-
justify-content: space-between;
|
|
4
|
-
align-items: center;
|
|
5
|
-
position: fixed;
|
|
6
|
-
bottom: 0px;
|
|
7
|
-
width: 100%;
|
|
8
|
-
height: 70px;
|
|
9
|
-
padding: 0 10px;
|
|
10
|
-
box-sizing: border-box;
|
|
11
|
-
z-index: 10;
|
|
12
|
-
padding-bottom: 2px;
|
|
13
|
-
background-color: white;
|
|
14
|
-
|
|
15
|
-
&::before {
|
|
16
|
-
content: '';
|
|
17
|
-
position: absolute;
|
|
18
|
-
top: 0;
|
|
19
|
-
left: 0;
|
|
20
|
-
right: 0;
|
|
21
|
-
height: 1px;
|
|
22
|
-
background-color: #e5e7eb;
|
|
23
|
-
width: 100%;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
@media (min-width: 767px) {
|
|
27
|
-
background-color: var(--color-black) !important;
|
|
28
|
-
padding-bottom: 0px;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.navigation {
|
|
32
|
-
display: flex;
|
|
33
|
-
justify-content: space-between;
|
|
34
|
-
width: 100%;
|
|
35
|
-
|
|
36
|
-
@media (min-width: 767px) {
|
|
37
|
-
width: fit-content;
|
|
38
|
-
gap: 100px;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.content {
|
|
43
|
-
font-size: var(--font-size-body-1);
|
|
44
|
-
color: var(--color-grey-light);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
.brand {
|
|
48
|
-
width: 100%;
|
|
49
|
-
margin-bottom: 4px;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.time {
|
|
53
|
-
margin-left: 8px;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.date,
|
|
57
|
-
.time {
|
|
58
|
-
display: inline-block;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.a2aiLogoImg {
|
|
62
|
-
max-width: 160px;
|
|
63
|
-
max-height: 40px;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
.omniumLogoImg {
|
|
67
|
-
height: 25px;
|
|
68
|
-
width: 100px;
|
|
69
|
-
align-self: flex-end;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.navItem {
|
|
73
|
-
display: flex;
|
|
74
|
-
flex-direction: column;
|
|
75
|
-
align-items: center;
|
|
76
|
-
justify-content: center;
|
|
77
|
-
flex: 1;
|
|
78
|
-
|
|
79
|
-
@media (min-width: 767px) {
|
|
80
|
-
flex-direction: row;
|
|
81
|
-
gap: 12px;
|
|
82
|
-
flex: unset;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.navIcon {
|
|
86
|
-
font-size: 26px;
|
|
87
|
-
color: #0033a0;
|
|
88
|
-
cursor: pointer;
|
|
89
|
-
|
|
90
|
-
@media (min-width: 767px) {
|
|
91
|
-
color: var(--color-grey-light);
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.navText {
|
|
96
|
-
font-size: 12px;
|
|
97
|
-
margin-top: 4px;
|
|
98
|
-
color: #0033a0;
|
|
99
|
-
|
|
100
|
-
@media (min-width: 767px) {
|
|
101
|
-
color: var(--color-grey-light);
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
.addButtonContainer {
|
|
107
|
-
display: flex;
|
|
108
|
-
justify-content: center;
|
|
109
|
-
flex: 1;
|
|
110
|
-
|
|
111
|
-
@media (min-width: 767px) {
|
|
112
|
-
flex: unset;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
.addButton {
|
|
116
|
-
display: flex;
|
|
117
|
-
justify-content: center;
|
|
118
|
-
align-items: center;
|
|
119
|
-
width: 50px;
|
|
120
|
-
height: 50px;
|
|
121
|
-
background-color: #0033a0;
|
|
122
|
-
border-radius: 8px;
|
|
123
|
-
cursor: pointer;
|
|
124
|
-
|
|
125
|
-
@media (min-width: 767px) {
|
|
126
|
-
background-color: var(--color-grey-light);
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
.addIcon {
|
|
130
|
-
font-size: 20px;
|
|
131
|
-
color: white;
|
|
132
|
-
|
|
133
|
-
@media (min-width: 767px) {
|
|
134
|
-
color: #2c2d2e;
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.notificationContainer {
|
|
141
|
-
position: relative;
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.disabled {
|
|
146
|
-
opacity: 0.5;
|
|
147
|
-
cursor: not-allowed !important;
|
|
148
|
-
pointer-events: none;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.rotateIcon {
|
|
152
|
-
transform: rotate(45deg);
|
|
153
|
-
transition: transform 0.3s ease;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.circularMenu {
|
|
157
|
-
position: absolute;
|
|
158
|
-
bottom: 70px;
|
|
159
|
-
width: 250px;
|
|
160
|
-
left: 50%;
|
|
161
|
-
transform: translateX(-52%);
|
|
162
|
-
display: flex;
|
|
163
|
-
flex-direction: column;
|
|
164
|
-
align-items: center;
|
|
165
|
-
gap: 12px;
|
|
166
|
-
z-index: 999;
|
|
167
|
-
|
|
168
|
-
@media (min-width: 767px) {
|
|
169
|
-
transform: translateX(-67%);
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
.circleMenuItem {
|
|
174
|
-
display: flex;
|
|
175
|
-
align-items: center;
|
|
176
|
-
background-color: white;
|
|
177
|
-
padding: 8px 16px;
|
|
178
|
-
border-radius: 20px;
|
|
179
|
-
box-shadow: 0 4px 12px rgba(0, 51, 160, 0.5);
|
|
180
|
-
cursor: pointer;
|
|
181
|
-
transition: all 0.2s ease;
|
|
182
|
-
animation: popIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
|
|
183
|
-
|
|
184
|
-
&:hover {
|
|
185
|
-
transform: translateY(-2px);
|
|
186
|
-
box-shadow: 0 6px 16px rgba(0, 51, 160, 0.25);
|
|
187
|
-
background-color: #f8fafc;
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
&:active {
|
|
191
|
-
transform: translateY(0);
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
&.disabled {
|
|
195
|
-
&:hover {
|
|
196
|
-
transform: none;
|
|
197
|
-
box-shadow: 0 4px 12px rgba(0, 51, 160, 0.15);
|
|
198
|
-
background-color: white;
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
.circleMenuIcon {
|
|
204
|
-
width: 28px;
|
|
205
|
-
height: 28px;
|
|
206
|
-
border-radius: 50%;
|
|
207
|
-
background-color: #f3f4f6;
|
|
208
|
-
display: flex;
|
|
209
|
-
align-items: center;
|
|
210
|
-
justify-content: center;
|
|
211
|
-
margin-right: 10px;
|
|
212
|
-
color: #4b5563;
|
|
213
|
-
|
|
214
|
-
.circleMenuItem:hover & {
|
|
215
|
-
transform: scale(1.1);
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
.circleMenuLabel {
|
|
220
|
-
font-size: 14px;
|
|
221
|
-
font-weight: 500;
|
|
222
|
-
color: #374151;
|
|
223
|
-
|
|
224
|
-
.circleMenuItem:hover & {
|
|
225
|
-
color: #1f2937;
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
.backButton {
|
|
230
|
-
display: flex;
|
|
231
|
-
align-items: center;
|
|
232
|
-
background: linear-gradient(135deg, #0033a0 0%, #0052cc 100%);
|
|
233
|
-
color: white;
|
|
234
|
-
padding: 0px 2px;
|
|
235
|
-
border-radius: 25px;
|
|
236
|
-
cursor: pointer;
|
|
237
|
-
transition: all 0.2s ease;
|
|
238
|
-
animation: slideDown 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
|
|
239
|
-
box-shadow: 0 4px 12px rgba(0, 51, 160, 0.3);
|
|
240
|
-
width: 20px;
|
|
241
|
-
justify-content: center;
|
|
242
|
-
margin-bottom: 8px;
|
|
243
|
-
|
|
244
|
-
&:hover {
|
|
245
|
-
transform: translateY(-2px);
|
|
246
|
-
box-shadow: 0 6px 16px rgba(0, 51, 160, 0.4);
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
.backIcon {
|
|
250
|
-
width: 30px;
|
|
251
|
-
height: 30px;
|
|
252
|
-
display: flex;
|
|
253
|
-
align-items: center;
|
|
254
|
-
justify-content: center;
|
|
255
|
-
font-size: 32px;
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
.submenuIndicator {
|
|
260
|
-
color: #9ca3af;
|
|
261
|
-
font-size: 12px;
|
|
262
|
-
margin-left: 4px;
|
|
263
|
-
|
|
264
|
-
.circleMenuItem:hover & {
|
|
265
|
-
color: #0033a0;
|
|
266
|
-
transform: translateX(2px);
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
@keyframes popIn {
|
|
271
|
-
from {
|
|
272
|
-
opacity: 0;
|
|
273
|
-
transform: scale(0.8) translateY(10px);
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
to {
|
|
277
|
-
opacity: 1;
|
|
278
|
-
transform: scale(1) translateY(0);
|
|
279
|
-
}
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
@keyframes slideDown {
|
|
283
|
-
from {
|
|
284
|
-
opacity: 0;
|
|
285
|
-
transform: translateY(-10px);
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
to {
|
|
289
|
-
opacity: 1;
|
|
290
|
-
transform: translateY(0);
|
|
291
|
-
}
|
|
292
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { t } from 'i18next';
|
|
2
|
-
import { MenuItem } from './Header.types';
|
|
3
|
-
|
|
4
|
-
export const getMenuTopList = (
|
|
5
|
-
onHome: () => void,
|
|
6
|
-
): MenuItem[] => [
|
|
7
|
-
{
|
|
8
|
-
name: t('navigation.home'),
|
|
9
|
-
action: onHome,
|
|
10
|
-
},
|
|
11
|
-
];
|
|
12
|
-
|
|
13
|
-
export const getMenuBottomList= (
|
|
14
|
-
onProfile: () => void,
|
|
15
|
-
onLogout: () => void,
|
|
16
|
-
userName?: string,
|
|
17
|
-
): MenuItem[] => [
|
|
18
|
-
{
|
|
19
|
-
name: `${t('navigation.profile')}${userName ? ` <span>(${userName})</span>` : ''}`,
|
|
20
|
-
action: onProfile,
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
name: t('navigation.logout'),
|
|
24
|
-
action: onLogout,
|
|
25
|
-
}
|
|
26
|
-
];
|
|
@@ -1,236 +0,0 @@
|
|
|
1
|
-
import { Meta, StoryFn } from "@storybook/react-webpack5";
|
|
2
|
-
import { Header } from '.';
|
|
3
|
-
import { HeaderProps } from './Header.types';
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
title: 'Header',
|
|
7
|
-
component: Header,
|
|
8
|
-
} as Meta;
|
|
9
|
-
|
|
10
|
-
const Template: StoryFn<HeaderProps> = (args: any) => <Header {...args}></Header>;
|
|
11
|
-
|
|
12
|
-
const mockAction = () => {
|
|
13
|
-
console.log('action');
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
const homeUrl = 'http://www.google.com';
|
|
17
|
-
const profileUrl = 'http://www.google.pt';
|
|
18
|
-
|
|
19
|
-
const mockMenu = [
|
|
20
|
-
{
|
|
21
|
-
name: "Ciclos de Avaliação",
|
|
22
|
-
action: () => mockAction(),
|
|
23
|
-
targetRoute: "cycleslist",
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
name: "Questionários",
|
|
27
|
-
action: () => mockAction(),
|
|
28
|
-
targetRoute: "questionanaire",
|
|
29
|
-
},
|
|
30
|
-
{
|
|
31
|
-
name: "Análises",
|
|
32
|
-
action: () => mockAction(),
|
|
33
|
-
targetRoute: "analyse",
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
name: "Relatórios",
|
|
37
|
-
action: () => mockAction(),
|
|
38
|
-
targetRoute: "reports",
|
|
39
|
-
dropdownMenu: [
|
|
40
|
-
{
|
|
41
|
-
name: "Análises",
|
|
42
|
-
action: () => mockAction(),
|
|
43
|
-
targetRoute: "analyse",
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
name: "Análises2",
|
|
47
|
-
action: () => mockAction(),
|
|
48
|
-
targetRoute: "analyse2",
|
|
49
|
-
}
|
|
50
|
-
]
|
|
51
|
-
}
|
|
52
|
-
];
|
|
53
|
-
|
|
54
|
-
const notifications = [
|
|
55
|
-
{
|
|
56
|
-
"Id": "662C390B-A38F-45AB-B97C-2D00F0A8ACAD",
|
|
57
|
-
"Title": "Creation of an Evaluation Cycle",
|
|
58
|
-
"Description": "A new evaluation cycle was created. You must answer it.",
|
|
59
|
-
"RedirectURL": "https://www.google.pt",
|
|
60
|
-
"Icon": "https://omniumfont.s3.eu-west-1.amazonaws.com/Assets/images/aacp-image.png",
|
|
61
|
-
"ExpirationDate": 1736899200,
|
|
62
|
-
"Criticality": {
|
|
63
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
64
|
-
"Name": "High",
|
|
65
|
-
"ColorHex": "#E05151"
|
|
66
|
-
},
|
|
67
|
-
"IsRead": true
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
"Id": "0AF18720-1C94-48CD-8DF3-D254077E8363",
|
|
71
|
-
"Title": "Creation of an Evaluation Cycle",
|
|
72
|
-
"Description": "A new evaluation cycle was created. You must answer it.",
|
|
73
|
-
"RedirectURL": "https://www.google.pt",
|
|
74
|
-
"Icon": "https://omniumfont.s3.eu-west-1.amazonaws.com/Assets/images/aacp-image.png",
|
|
75
|
-
"ExpirationDate": 1736899200,
|
|
76
|
-
"Criticality": {
|
|
77
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
78
|
-
"Name": "High",
|
|
79
|
-
"ColorHex": "#E05151"
|
|
80
|
-
},
|
|
81
|
-
"IsRead": true
|
|
82
|
-
},
|
|
83
|
-
{
|
|
84
|
-
"Id": "0419654F-66FE-41EA-BBA4-D8BB6E3D6B33",
|
|
85
|
-
"Title": "Creation of an Evaluation Cycle",
|
|
86
|
-
"Description": "A new evaluation cycle was created. You must answer it.",
|
|
87
|
-
"RedirectURL": "https://www.google.pt",
|
|
88
|
-
"Icon": "https://omniumfont.s3.eu-west-1.amazonaws.com/Assets/images/aacp-image.png",
|
|
89
|
-
"ExpirationDate": 1736899200,
|
|
90
|
-
"Criticality": {
|
|
91
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
92
|
-
"Name": "High",
|
|
93
|
-
"ColorHex": "#E05151"
|
|
94
|
-
},
|
|
95
|
-
"IsRead": true
|
|
96
|
-
},
|
|
97
|
-
{
|
|
98
|
-
"Id": "CC98EDA1-0461-4D08-982E-8424EF4AFB3B",
|
|
99
|
-
"Title": "Creation of an Evaluation Cycle",
|
|
100
|
-
"Description": "A new evaluation cycle was created. You must answer it.",
|
|
101
|
-
"RedirectURL": "https://www.google.pt",
|
|
102
|
-
"Icon": "https://omniumfont.s3.eu-west-1.amazonaws.com/Assets/images/aacp-image.png",
|
|
103
|
-
"ExpirationDate": 1736899200,
|
|
104
|
-
"Criticality": {
|
|
105
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
106
|
-
"Name": "High",
|
|
107
|
-
"ColorHex": "#E05151"
|
|
108
|
-
},
|
|
109
|
-
"IsRead": false
|
|
110
|
-
},
|
|
111
|
-
{
|
|
112
|
-
"Id": "3DB9310A-4BF8-4B90-8D5A-7583473664BB",
|
|
113
|
-
"Title": "Creation of an Evaluation Cycle",
|
|
114
|
-
"Description": "A new evaluation cycle was created. You must answer it.",
|
|
115
|
-
"RedirectURL": "https://www.google.pt",
|
|
116
|
-
"Icon": "https://omniumfont.s3.eu-west-1.amazonaws.com/Assets/images/aacp-image.png",
|
|
117
|
-
"ExpirationDate": 1736899200,
|
|
118
|
-
"Criticality": {
|
|
119
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
120
|
-
"Name": "High",
|
|
121
|
-
"ColorHex": "#E05151"
|
|
122
|
-
},
|
|
123
|
-
"IsRead": false
|
|
124
|
-
},
|
|
125
|
-
{
|
|
126
|
-
"Id": "D6FB93EE-3255-42B2-8EC1-27E7AC3F5249",
|
|
127
|
-
"Title": "Creation of a new user",
|
|
128
|
-
"Description": "A new user was created in the platform with the mecanographic number 8111.",
|
|
129
|
-
"RedirectURL": "https://www.google.pt",
|
|
130
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
131
|
-
"ExpirationDate": 1736985600,
|
|
132
|
-
"Criticality": {
|
|
133
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
134
|
-
"Name": "High",
|
|
135
|
-
"ColorHex": "#E05151"
|
|
136
|
-
},
|
|
137
|
-
"IsRead": false
|
|
138
|
-
},
|
|
139
|
-
{
|
|
140
|
-
"Id": "D6FB96EE-3255-42B2-8EC1-27E7AC3F5249",
|
|
141
|
-
"Title": "Creation of a new action of inspection",
|
|
142
|
-
"Description": "A new inspection action was created.",
|
|
143
|
-
"RedirectURL": "https://www.google.pt",
|
|
144
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
145
|
-
"ExpirationDate": 1736985600,
|
|
146
|
-
"Criticality": {
|
|
147
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
148
|
-
"Name": "High",
|
|
149
|
-
"ColorHex": "#E05151"
|
|
150
|
-
},
|
|
151
|
-
"IsRead": false
|
|
152
|
-
},
|
|
153
|
-
{
|
|
154
|
-
"Id": "D6FB96EE-3655-42B2-8EC1-27E7AC3F5249",
|
|
155
|
-
"Title": "Creation of a new action of inspection",
|
|
156
|
-
"Description": "A new inspection action was created.",
|
|
157
|
-
"RedirectURL": "https://www.google.pt",
|
|
158
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
159
|
-
"ExpirationDate": 1736985600,
|
|
160
|
-
"Criticality": {
|
|
161
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
162
|
-
"Name": "High",
|
|
163
|
-
"ColorHex": "#E05151"
|
|
164
|
-
},
|
|
165
|
-
"IsRead": false
|
|
166
|
-
},
|
|
167
|
-
{
|
|
168
|
-
"Id": "D6FB96EE-3255-46B2-8EC1-27E7AC3F5249",
|
|
169
|
-
"Title": "Creation of a new action of inspection",
|
|
170
|
-
"Description": "A new inspection action was created.",
|
|
171
|
-
"RedirectURL": "https://www.google.pt",
|
|
172
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
173
|
-
"ExpirationDate": 1736985600,
|
|
174
|
-
"Criticality": {
|
|
175
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
176
|
-
"Name": "High",
|
|
177
|
-
"ColorHex": "#E05151"
|
|
178
|
-
},
|
|
179
|
-
"IsRead": false
|
|
180
|
-
},
|
|
181
|
-
{
|
|
182
|
-
"Id": "D9FB96EE-3255-42B2-8EC1-27E7AC3F5249",
|
|
183
|
-
"Title": "Creation of a new action of inspection",
|
|
184
|
-
"Description": "A new inspection action was created.",
|
|
185
|
-
"RedirectURL": "https://www.google.pt",
|
|
186
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
187
|
-
"ExpirationDate": 1736985600,
|
|
188
|
-
"Criticality": {
|
|
189
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
190
|
-
"Name": "High",
|
|
191
|
-
"ColorHex": "#E05151"
|
|
192
|
-
},
|
|
193
|
-
"IsRead": false
|
|
194
|
-
},
|
|
195
|
-
{
|
|
196
|
-
"Id": "D6FB96EE-5955-42B2-8EC1-27E7AC3F5249",
|
|
197
|
-
"Title": "Creation of a new action of inspection",
|
|
198
|
-
"Description": "A new inspection action was created.",
|
|
199
|
-
"RedirectURL": "https://www.google.pt",
|
|
200
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
201
|
-
"ExpirationDate": 1736985600,
|
|
202
|
-
"Criticality": {
|
|
203
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
204
|
-
"Name": "High",
|
|
205
|
-
"ColorHex": "#E05151"
|
|
206
|
-
},
|
|
207
|
-
"IsRead": false
|
|
208
|
-
},
|
|
209
|
-
{
|
|
210
|
-
"Id": "D6FB96EE-3255-42B7-8EC1-27E7AC3F5249",
|
|
211
|
-
"Title": "Creation of a new action of inspection",
|
|
212
|
-
"Description": "A new inspection action was created.",
|
|
213
|
-
"RedirectURL": "https://www.google.pt",
|
|
214
|
-
"Icon": "https://omnium-user-images.s3.eu-west-1.amazonaws.com/omniumretail-bigwingame-logotipo-vermelho.svg",
|
|
215
|
-
"ExpirationDate": 1736985600,
|
|
216
|
-
"Criticality": {
|
|
217
|
-
"Id": "F133ED4C-6C72-4CDC-86A1-27A76E6BDE7F",
|
|
218
|
-
"Name": "High",
|
|
219
|
-
"ColorHex": "#E05151"
|
|
220
|
-
},
|
|
221
|
-
"IsRead": false
|
|
222
|
-
}
|
|
223
|
-
];
|
|
224
|
-
|
|
225
|
-
export const Primary = Template.bind({});
|
|
226
|
-
Primary.args = {
|
|
227
|
-
menuList: mockMenu,
|
|
228
|
-
logout: () => console.log('Logout'), // in here logout from auth0 should be passed
|
|
229
|
-
homeUrl: homeUrl,
|
|
230
|
-
profileUrl: profileUrl,
|
|
231
|
-
userName: 'Diogo Carvalho',
|
|
232
|
-
pageTitle: 'Page Title',
|
|
233
|
-
notifications: notifications,
|
|
234
|
-
companyName: 'a2ai',
|
|
235
|
-
};
|
|
236
|
-
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { BellNotification } from "components/BellNotifications";
|
|
2
|
-
|
|
3
|
-
export interface MenuItem {
|
|
4
|
-
name: string;
|
|
5
|
-
action: () => void;
|
|
6
|
-
targetRoute?: string;
|
|
7
|
-
dropdownMenu?: MenuItem[];
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export interface actionButton {
|
|
11
|
-
element?: any; // the client wants to be able to get a icon here
|
|
12
|
-
action?: () => void;
|
|
13
|
-
visibility?: boolean;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export interface HeaderProps {
|
|
17
|
-
actionButton?: actionButton;
|
|
18
|
-
menuList?: MenuItem[];
|
|
19
|
-
logout?: () => void;
|
|
20
|
-
homeUrl: string;
|
|
21
|
-
profileUrl: string;
|
|
22
|
-
onLeavingPage?: (targetRoute: string) => void;
|
|
23
|
-
userName?: string;
|
|
24
|
-
pageTitle?: string;
|
|
25
|
-
onFilterChange?: (filter: 'all' | 'unread') => void;
|
|
26
|
-
onNotificationClick?: (id: string, url: string) => void;
|
|
27
|
-
handleMarkAllAsRead?: () => void;
|
|
28
|
-
notifications?: BellNotification[];
|
|
29
|
-
shouldConfirmNavigation?: boolean;
|
|
30
|
-
companyName?: string;
|
|
31
|
-
customLogoClass?: string;
|
|
32
|
-
}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
# Header Component
|
|
2
|
-
|
|
3
|
-
The `Header` component renders a navigation header with support for dropdown menus, dynamic routing, and an action button. It also supports conditional rendering based on user login and profile URL.
|
|
4
|
-
|
|
5
|
-
## Props
|
|
6
|
-
|
|
7
|
-
### `HeaderProps`
|
|
8
|
-
|
|
9
|
-
- `actionButton` (optional): An object with the following properties:
|
|
10
|
-
- `element`: A React component to be rendered as the action button (e.g., an icon).
|
|
11
|
-
- `action`: A function to be called when the action button is clicked.
|
|
12
|
-
- `visibility`: A boolean indicating whether the action button should be visible.
|
|
13
|
-
- `menuList` (optional): An array of menu items, where each item is an object with the following properties:
|
|
14
|
-
- `name`: The name of the menu item, which can include HTML content.
|
|
15
|
-
- `action`: A function to be called when the menu item is clicked.
|
|
16
|
-
- `targetRoute` (optional): The target route for the menu item.
|
|
17
|
-
- `dropdownMenu` (optional): An array of sub-menu items with the same structure.
|
|
18
|
-
- `logout` (optional): A function to be called when the user logs out.
|
|
19
|
-
- `homeUrl`: A string representing the URL for the home page.
|
|
20
|
-
- `profileUrl`: A string representing the URL for the profile page.
|
|
21
|
-
- `onLeavingPage` (optional): A function to be called before navigating away from the current page, with the target route as an argument. that is an example here: [APE Example](https://bitbucket.org/product_admin/staffperformanceevaluationcycle-restapi-omnium/src/master/frontend/src/Layout/index.tsx).
|
|
22
|
-
- `userName` (optional): A string representing the user's name, displayed next to the "Profile" menu item.
|
|
23
|
-
- `pageTitle` (optional): A string representing the page title, displayed in the header.
|
|
24
|
-
|
|
25
|
-
### Explanation of Code
|
|
26
|
-
|
|
27
|
-
#### State and Refs:
|
|
28
|
-
- `isMenuOpen`: Manages the state of the menu (open/closed).
|
|
29
|
-
- `activeDropdown`: Manages the state of the active dropdown menu.
|
|
30
|
-
- `headerRef` and `overlayRef`: Used for referencing the header and overlay elements.
|
|
31
|
-
|
|
32
|
-
#### Helper Functions:
|
|
33
|
-
- `onLogout`: Handles the logout functionality. If a logout function is provided, it is called; otherwise, it navigates to the home page.
|
|
34
|
-
- `onProfile`: Navigates to the profile URL.
|
|
35
|
-
- `onHome`: Navigates to the home URL.
|
|
36
|
-
- `onToggleMenu`: Toggles the menu open and closed state.
|
|
37
|
-
- `handleDropdownClick`: Toggles the active state of the dropdown menus.
|
|
38
|
-
- `renderMenu`: Renders the menu items, including handling clicks for navigation and dropdown menus.
|