dgrcorrientes-modulos 1.0.2 → 1.0.4

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.
Files changed (258) hide show
  1. package/README.md +12 -21
  2. package/components.js +31576 -0
  3. package/components.umd.cjs +311 -0
  4. package/index.d.ts +1 -0
  5. package/package.json +1 -60
  6. package/style.css +5 -0
  7. package/.nvmrc +0 -1
  8. package/.prettierrc.cjs +0 -8
  9. package/.storybook/main.cjs +0 -11
  10. package/.storybook/manager-head.html +0 -2
  11. package/.storybook/manager.cjs +0 -6
  12. package/.storybook/preview-head.html +0 -3
  13. package/.storybook/preview.cjs +0 -11
  14. package/.storybook/themes.cjs +0 -14
  15. package/StoryBook.txt +0 -19
  16. package/dist-config.cjs +0 -57
  17. package/index.html +0 -13
  18. package/src/App.scss +0 -36
  19. package/src/App.tsx +0 -34
  20. package/src/assets/react.svg +0 -1
  21. package/src/index.js +0 -70
  22. package/src/index.scss +0 -63
  23. package/src/index.ts +0 -108
  24. package/src/main.tsx +0 -11
  25. package/src/sass/base/_base.scss +0 -50
  26. package/src/sass/base/_controls.scss +0 -90
  27. package/src/sass/base/_datepicker.scss +0 -114
  28. package/src/sass/base/_typo.scss +0 -71
  29. package/src/sass/base/fonts/SFUIText-Bold.ttf +0 -0
  30. package/src/sass/base/fonts/SFUIText-BoldItalic.ttf +0 -0
  31. package/src/sass/base/fonts/SFUIText-Heavy.ttf +0 -0
  32. package/src/sass/base/fonts/SFUIText-HeavyItalic.ttf +0 -0
  33. package/src/sass/base/fonts/SFUIText-Light.ttf +0 -0
  34. package/src/sass/base/fonts/SFUIText-LightItalic.ttf +0 -0
  35. package/src/sass/base/fonts/SFUIText-Medium.ttf +0 -0
  36. package/src/sass/base/fonts/SFUIText-MediumItalic.ttf +0 -0
  37. package/src/sass/base/fonts/SFUIText-Regular.ttf +0 -0
  38. package/src/sass/base/fonts/SFUIText-RegularItalic.ttf +0 -0
  39. package/src/sass/base/fonts/SFUIText-Semibold.ttf +0 -0
  40. package/src/sass/base/fonts/SFUIText-SemiboldItalic.ttf +0 -0
  41. package/src/sass/bulma/bulma-changes.scss +0 -19
  42. package/src/sass/bulma/extensions/extensions.sass +0 -1
  43. package/src/sass/bulma/extensions/steps/bulma-steps.sass +0 -3
  44. package/src/sass/bulma/extensions/steps/index.sass +0 -421
  45. package/src/sass/bulma/variables/_variables-bulma.sass +0 -16
  46. package/src/sass/bulma/variables/components/card.sass +0 -20
  47. package/src/sass/bulma/variables/components/navbar.sass +0 -50
  48. package/src/sass/bulma/variables/components/tabs.sass +0 -28
  49. package/src/sass/bulma/variables/elements/button.sass +0 -46
  50. package/src/sass/bulma/variables/elements/notification.sass +0 -8
  51. package/src/sass/bulma/variables/elements/title.sass +0 -20
  52. package/src/sass/bulma/variables/grid/column.sass +0 -2
  53. package/src/sass/main.sass +0 -16
  54. package/src/sass/utilities/_bulma-variables.sass +0 -20
  55. package/src/sass/utilities/_derived-variables.scss +0 -68
  56. package/src/sass/utilities/_helpers.scss +0 -70
  57. package/src/sass/utilities/_variables.scss +0 -147
  58. package/src/stories/Changelog.stories.tsx +0 -73
  59. package/src/stories/Components/AssistanceDiary/AssistanceDiary.scss +0 -19
  60. package/src/stories/Components/AssistanceDiary/AssistanceDiary.stories.tsx +0 -25
  61. package/src/stories/Components/AssistanceDiary/AssistanceDiary.tsx +0 -57
  62. package/src/stories/Components/AverageAttended/AverageAttended.scss +0 -39
  63. package/src/stories/Components/AverageAttended/AverageAttended.stories.tsx +0 -71
  64. package/src/stories/Components/AverageAttended/AverageAttended.tsx +0 -311
  65. package/src/stories/Components/Breadcrumb/Breadcrumb.stories.tsx +0 -45
  66. package/src/stories/Components/Breadcrumb/Breadcrumb.tsx +0 -68
  67. package/src/stories/Components/Breadcrumb/breadcrumb.scss +0 -82
  68. package/src/stories/Components/CTA/CTA.scss +0 -76
  69. package/src/stories/Components/CTA/CTA.stories.tsx +0 -46
  70. package/src/stories/Components/CTA/CTA.tsx +0 -70
  71. package/src/stories/Components/Cards/Card CTA/CardCta.stories.tsx +0 -34
  72. package/src/stories/Components/Cards/Card CTA/CardCta.tsx +0 -81
  73. package/src/stories/Components/Cards/Card CTA/cardCta.scss +0 -71
  74. package/src/stories/Components/Cards/Card Expiration/cardExpiration.scss +0 -105
  75. package/src/stories/Components/Cards/Card Expiration/cardExpiration.stories.tsx +0 -40
  76. package/src/stories/Components/Cards/Card Expiration/cardExpiration.tsx +0 -95
  77. package/src/stories/Components/Cards/Card Vertical/CardVertical.stories.tsx +0 -43
  78. package/src/stories/Components/Cards/Card Vertical/CardVertical.tsx +0 -106
  79. package/src/stories/Components/Cards/Card Vertical/cardVertical.scss +0 -130
  80. package/src/stories/Components/Cards/CardActivity/cardActivity.scss +0 -31
  81. package/src/stories/Components/Cards/CardActivity/cardActivity.stories.tsx +0 -20
  82. package/src/stories/Components/Cards/CardActivity/cardActivity.tsx +0 -48
  83. package/src/stories/Components/Cards/CardHorizontal/CardHorizontal.stories.tsx +0 -96
  84. package/src/stories/Components/Cards/CardHorizontal/CardHorizontal.tsx +0 -94
  85. package/src/stories/Components/Cards/CardHorizontal/cardHorizontal.scss +0 -65
  86. package/src/stories/Components/Cards/CardUser/CardUser.stories.tsx +0 -135
  87. package/src/stories/Components/Cards/CardUser/CardUser.tsx +0 -122
  88. package/src/stories/Components/Cards/CardUser/cardUser.scss +0 -115
  89. package/src/stories/Components/Cart/Cart.scss +0 -279
  90. package/src/stories/Components/Cart/Cart.stories.tsx +0 -350
  91. package/src/stories/Components/Cart/Cart.tsx +0 -277
  92. package/src/stories/Components/Collapse/Collapse.scss +0 -339
  93. package/src/stories/Components/Collapse/Collapse.stories.tsx +0 -766
  94. package/src/stories/Components/Collapse/Collapse.tsx +0 -451
  95. package/src/stories/Components/CollapseEdit/CollapseEdit.scss +0 -128
  96. package/src/stories/Components/CollapseEdit/CollapseEdit.stories.tsx +0 -29
  97. package/src/stories/Components/CollapseEdit/CollapseEdit.tsx +0 -185
  98. package/src/stories/Components/CompleteDiary/CompleteDiary.scss +0 -165
  99. package/src/stories/Components/CompleteDiary/CompleteDiary.stories.tsx +0 -219
  100. package/src/stories/Components/CompleteDiary/CompleteDiary.tsx +0 -394
  101. package/src/stories/Components/Dropdown/Dropdown.scss +0 -60
  102. package/src/stories/Components/Dropdown/Dropdown.stories.tsx +0 -19
  103. package/src/stories/Components/Dropdown/Dropdown.tsx +0 -99
  104. package/src/stories/Components/EmptyState/EmptyState.stories.tsx +0 -46
  105. package/src/stories/Components/EmptyState/EmptyState.tsx +0 -44
  106. package/src/stories/Components/EmptyState/emptyState.scss +0 -75
  107. package/src/stories/Components/ErrorPage/ErrorPage.scss +0 -65
  108. package/src/stories/Components/ErrorPage/ErrorPage.stories.tsx +0 -164
  109. package/src/stories/Components/ErrorPage/ErrorPage.tsx +0 -107
  110. package/src/stories/Components/IncomingCall/IncomingCall.scss +0 -27
  111. package/src/stories/Components/IncomingCall/IncomingCall.stories.tsx +0 -43
  112. package/src/stories/Components/IncomingCall/IncomingCall.tsx +0 -76
  113. package/src/stories/Components/ModalConfirm/ModalConfirm.scss +0 -30
  114. package/src/stories/Components/ModalConfirm/ModalConfirm.stories.tsx +0 -21
  115. package/src/stories/Components/ModalConfirm/ModalConfirm.tsx +0 -118
  116. package/src/stories/Components/Pagination/Pagination.scss +0 -42
  117. package/src/stories/Components/Pagination/Pagination.stories.tsx +0 -25
  118. package/src/stories/Components/Pagination/Pagination.tsx +0 -143
  119. package/src/stories/Components/PerformanceAssessment/PerformanceAssessment.scss +0 -26
  120. package/src/stories/Components/PerformanceAssessment/PerformanceAssessment.stories.tsx +0 -27
  121. package/src/stories/Components/PerformanceAssessment/PerformanceAssessment.tsx +0 -108
  122. package/src/stories/Components/ShiftDiary/ShiftDiary.scss +0 -45
  123. package/src/stories/Components/ShiftDiary/ShiftDiary.stories.tsx +0 -32
  124. package/src/stories/Components/ShiftDiary/ShiftDiary.tsx +0 -92
  125. package/src/stories/Components/Stepper/Stepper.stories.tsx +0 -26
  126. package/src/stories/Components/Stepper/Stepper.tsx +0 -102
  127. package/src/stories/Components/Stepper/stepper.scss +0 -59
  128. package/src/stories/Components/Tabs/Tabs.stories.tsx +0 -76
  129. package/src/stories/Components/Tabs/Tabs.tsx +0 -111
  130. package/src/stories/Components/Tabs/tabs.scss +0 -118
  131. package/src/stories/Components/Tooltip/Tooltip.scss +0 -235
  132. package/src/stories/Components/Tooltip/Tooltip.stories.tsx +0 -125
  133. package/src/stories/Components/Tooltip/Tooltip.tsx +0 -222
  134. package/src/stories/Elements/Alert/Alert.stories.tsx +0 -65
  135. package/src/stories/Elements/Alert/Alert.tsx +0 -49
  136. package/src/stories/Elements/Alert/alert.scss +0 -189
  137. package/src/stories/Elements/Badge/Badge.stories.tsx +0 -15
  138. package/src/stories/Elements/Badge/Badge.tsx +0 -21
  139. package/src/stories/Elements/Badge/badge.scss +0 -24
  140. package/src/stories/Elements/Button/Button.stories.tsx +0 -54
  141. package/src/stories/Elements/Button/Button.tsx +0 -118
  142. package/src/stories/Elements/Button/button.scss +0 -102
  143. package/src/stories/Elements/Icon/Icon.stories.tsx +0 -33
  144. package/src/stories/Elements/Icon/Icon.tsx +0 -57
  145. package/src/stories/Elements/Icon/icon.scss +0 -15
  146. package/src/stories/Elements/Icon/icono.svg +0 -1
  147. package/src/stories/Elements/ProgressBar/ProgressBar.scss +0 -26
  148. package/src/stories/Elements/ProgressBar/ProgressBar.stories.tsx +0 -19
  149. package/src/stories/Elements/ProgressBar/ProgressBar.tsx +0 -35
  150. package/src/stories/Form/Autocomplete/Autocomplete.stories.tsx +0 -55
  151. package/src/stories/Form/Autocomplete/Autocomplete.tsx +0 -160
  152. package/src/stories/Form/Autocomplete/autocomplete.scss +0 -311
  153. package/src/stories/Form/Autocomplete-Prueba/Autocomplete.stories.tsx +0 -50
  154. package/src/stories/Form/Autocomplete-Prueba/AutocompletePrueba.tsx +0 -83
  155. package/src/stories/Form/Checkbox/Checkbox.stories.tsx +0 -26
  156. package/src/stories/Form/Checkbox/Checkbox.tsx +0 -89
  157. package/src/stories/Form/Checkbox/checkbox.scss +0 -41
  158. package/src/stories/Form/DatePicker/DatePickerExample.stories.tsx +0 -27
  159. package/src/stories/Form/DatePicker/DatePickerExample.tsx +0 -65
  160. package/src/stories/Form/DatePickerComponent/DatePickerComponent.scss +0 -116
  161. package/src/stories/Form/DatePickerComponent/DatePickerComponent.stories.tsx +0 -37
  162. package/src/stories/Form/DatePickerComponent/DatePickerComponent.tsx +0 -97
  163. package/src/stories/Form/Filters/Filters.stories.tsx +0 -84
  164. package/src/stories/Form/Filters/Filters.tsx +0 -230
  165. package/src/stories/Form/Filters/filters.scss +0 -261
  166. package/src/stories/Form/Input/Input.stories.tsx +0 -25
  167. package/src/stories/Form/Input/Input.tsx +0 -86
  168. package/src/stories/Form/Input/InputVar.sass +0 -26
  169. package/src/stories/Form/Input/input.scss +0 -19
  170. package/src/stories/Form/InputFormControl/Input-form-control.stories.tsx +0 -26
  171. package/src/stories/Form/InputFormControl/Input-form-control.tsx +0 -48
  172. package/src/stories/Form/InputFormControl/input-form-control.scss +0 -34
  173. package/src/stories/Form/Radio/Radio.stories.tsx +0 -19
  174. package/src/stories/Form/Radio/Radio.tsx +0 -84
  175. package/src/stories/Form/Radio/radio.scss +0 -19
  176. package/src/stories/Form/Search/Search.scss +0 -50
  177. package/src/stories/Form/Search/Search.stories.tsx +0 -26
  178. package/src/stories/Form/Search/Search.tsx +0 -84
  179. package/src/stories/Form/Select/Select.stories.tsx +0 -55
  180. package/src/stories/Form/Select/Select.tsx +0 -121
  181. package/src/stories/Form/Select/select.scss +0 -303
  182. package/src/stories/Form/Switch/Switch.stories.tsx +0 -17
  183. package/src/stories/Form/Switch/Switch.tsx +0 -36
  184. package/src/stories/Form/Switch/switch.scss +0 -123
  185. package/src/stories/Form/Textarea/Textarea.stories.tsx +0 -19
  186. package/src/stories/Form/Textarea/Textarea.tsx +0 -52
  187. package/src/stories/Form/Textarea/textarea.scss +0 -25
  188. package/src/stories/Form/UploadFileItem/UploadFileItem.scss +0 -49
  189. package/src/stories/Form/UploadFileItem/UploadFileItem.stories.tsx +0 -18
  190. package/src/stories/Form/UploadFileItem/UploadFileItem.tsx +0 -89
  191. package/src/stories/Form/UploadFiles/UploadFiles.scss +0 -17
  192. package/src/stories/Form/UploadFiles/UploadFiles.stories.tsx +0 -32
  193. package/src/stories/Form/UploadFiles/UploadFiles.tsx +0 -177
  194. package/src/stories/Layout/Footer/Footer.scss +0 -129
  195. package/src/stories/Layout/Footer/Footer.stories.tsx +0 -101
  196. package/src/stories/Layout/Footer/Footer.tsx +0 -81
  197. package/src/stories/Layout/Header/Header.scss +0 -190
  198. package/src/stories/Layout/Header/Header.stories.tsx +0 -223
  199. package/src/stories/Layout/Header/Header.tsx +0 -278
  200. package/src/stories/Layout/HeaderTable/HeaderTable.scss +0 -21
  201. package/src/stories/Layout/HeaderTable/HeaderTable.stories.tsx +0 -112
  202. package/src/stories/Layout/HeaderTable/HeaderTable.tsx +0 -72
  203. package/src/stories/Layout/Sidebar/Sidebar.scss +0 -50
  204. package/src/stories/Layout/Sidebar/Sidebar.stories.tsx +0 -744
  205. package/src/stories/Layout/Sidebar/Sidebar.tsx +0 -129
  206. package/src/stories/Layout/SidebarEmpty/SidebarEmpty.scss +0 -64
  207. package/src/stories/Layout/SidebarEmpty/SidebarEmpty.stories.tsx +0 -26
  208. package/src/stories/Layout/SidebarEmpty/SidebarEmpty.tsx +0 -100
  209. package/src/stories/Layout/Subtitle/Subtitle.scss +0 -88
  210. package/src/stories/Layout/Subtitle/Subtitle.stories.tsx +0 -46
  211. package/src/stories/Layout/Subtitle/Subtitle.tsx +0 -108
  212. package/src/stories/Layout/Title/Title.scss +0 -79
  213. package/src/stories/Layout/Title/Title.stories.tsx +0 -86
  214. package/src/stories/Layout/Title/Title.tsx +0 -96
  215. package/src/stories/Welcome.stories.tsx +0 -111
  216. package/src/stories/assets/404 Page Not Found _Two Color (1).png +0 -0
  217. package/src/stories/assets/404 Page Not Found _Two Color.png +0 -0
  218. package/src/stories/assets/Empty Inbox _Two Color.png +0 -0
  219. package/src/stories/assets/Loading _Two Color.png +0 -0
  220. package/src/stories/assets/Notifications_Two Color 1.png +0 -0
  221. package/src/stories/assets/Online protection_Two Color.png +0 -0
  222. package/src/stories/assets/Under Constructions _Two Color.png +0 -0
  223. package/src/stories/assets/bulma.png +0 -0
  224. package/src/stories/assets/burger.svg +0 -5
  225. package/src/stories/assets/code-brackets.svg +0 -1
  226. package/src/stories/assets/colors.svg +0 -1
  227. package/src/stories/assets/comments.svg +0 -1
  228. package/src/stories/assets/decor-bg.png +0 -0
  229. package/src/stories/assets/direction.svg +0 -1
  230. package/src/stories/assets/e-isologo.svg +0 -4
  231. package/src/stories/assets/e-isotype.svg +0 -4
  232. package/src/stories/assets/e-logo_negative.svg +0 -14
  233. package/src/stories/assets/e-logotype.svg +0 -14
  234. package/src/stories/assets/flow.svg +0 -1
  235. package/src/stories/assets/logo_gobierno_corrientes.svg +0 -9
  236. package/src/stories/assets/logo_rentas_corrientes.svg +0 -10
  237. package/src/stories/assets/logo_rentas_corrientes_compacto.svg +0 -10
  238. package/src/stories/assets/plugin.svg +0 -1
  239. package/src/stories/assets/repo.svg +0 -1
  240. package/src/stories/assets/stackalt.svg +0 -1
  241. package/src/stories/assets/storybook.svg +0 -13
  242. package/src/stories/assets/thumbnail-black.jpg +0 -0
  243. package/src/stories/assets/thumbnail-black[2].jpg +0 -0
  244. package/src/stories/assets/thumbnail.jpg +0 -0
  245. package/src/stories/assets/thumbnail[2].jpg +0 -0
  246. package/src/stories/changelog.ts +0 -389
  247. package/src/utils/functions.ts +0 -57
  248. package/src/vite-env.d.ts +0 -2
  249. package/static/e-isologo-192.jpg +0 -0
  250. package/static/e-isologo.svg +0 -4
  251. package/static/e-logotype.svg +0 -14
  252. package/static/favicon.ico +0 -0
  253. package/tsconfig.json +0 -22
  254. package/tsconfig.node.json +0 -9
  255. package/vite.config.ts +0 -22
  256. /package/{public/elevation.ico → elevation.ico} +0 -0
  257. /package/{public/elevationImage.png → elevationImage.png} +0 -0
  258. /package/{public/vite.svg → vite.svg} +0 -0
@@ -1,39 +0,0 @@
1
- @import '/src/sass/utilities/variables';
2
-
3
- .elv-averageAttended{
4
- .averageAttended{
5
- flex-wrap: wrap;
6
- padding: 20px;
7
- border-radius: 16px;
8
-
9
- @media (max-width: 640px){
10
- padding: 10px;
11
- gap: 24px !important;
12
- }
13
-
14
- &__option{
15
- width: calc(33.33% - 16px);
16
- gap: 30px;
17
- @media (max-width: 920px){
18
- width: calc(50% - 16px);
19
- }
20
- @media (max-width: 640px){
21
- width: 100%;
22
-
23
- }
24
- }
25
-
26
- &__colorDark{
27
- color: $darkText;
28
- }
29
-
30
- .badge{
31
-
32
- padding: 4px 8px;
33
- @media (max-width: 950px){
34
- max-width: 20px !important;
35
- padding: 4px 4px;
36
- }
37
- }
38
- }
39
- }
@@ -1,71 +0,0 @@
1
- import {ComponentStory, ComponentMeta} from '@storybook/react';
2
- import {AverageAttended} from './AverageAttended';
3
-
4
- export default {
5
- title: 'Components/AverageAttended',
6
- component: AverageAttended,
7
- args: {
8
- Call: [
9
- //{id: 2, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 15, 18, 0), serviceStartTime: new Date(2023, 11, 18, 14, 0)},
10
- //{id: 3, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 15, 18, 0), serviceStartTime: new Date(2023, 11, 18, 14, 0)},
11
- //{id: 4, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 18, 0), serviceStartTime: new Date(2023, 11, 18, 14, 0)},
12
- {id: 1, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 12, 30), serviceStartTime: new Date(2023, 11, 18, 12, 30)},
13
- {id: 2, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 12, 0), serviceStartTime: new Date(2023, 11, 18, 12, 0)},
14
- {id: 3, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 12, 0), serviceStartTime: new Date(2023, 11, 18, 12, 0)},
15
- {id: 4, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 12, 30), serviceStartTime: new Date(2023, 11, 18, 12, 30)},
16
- {id: 5, date: new Date(2023, 11, 18), arrivalTime: new Date(2023, 11, 18, 13, 0), serviceStartTime: new Date(2023, 11, 18, 13, 30)},
17
- {id: 6, date: new Date(2023, 11, 29), arrivalTime: new Date(2023, 11, 29, 13, 0), serviceStartTime: new Date(2023, 11, 29, 13, 0)},
18
- {id: 7, date: new Date(2023, 11, 29), arrivalTime: new Date(2023, 11, 29, 13, 0), serviceStartTime: new Date(2023, 11, 29, 13, 0)},
19
- {id: 8, date: new Date(2023, 11, 29), arrivalTime: new Date(2023, 11, 29, 13, 0), serviceStartTime: new Date(2023, 11, 29, 13, 0)},
20
- {id: 9, date: new Date(2023, 11, 29), arrivalTime: new Date(2023, 11, 29, 13, 0), serviceStartTime: new Date(2023, 11, 29, 13, 0)},
21
- {id: 10, date: new Date(2023, 11, 29), arrivalTime: new Date(2023, 11, 29, 13, 0), serviceStartTime: new Date(2023, 11, 29, 13, 0)},
22
- ],
23
- option: [
24
- {
25
- status: 'Atendidos',
26
- icon: 'fa-solid fa-users',
27
- iconColor: '#124596',
28
- amountCall: 0,
29
- labelButtom: '▾',
30
- labelTop: '▴+',
31
- color: '#D4D4D4',
32
- colorText: '#DC2626',
33
- colorTextPositive: '#16A34A',
34
- description: 'esta semana',
35
- },
36
- ],
37
- option2: [
38
- {
39
- status: 'Promedio de espera',
40
- icon: 'fa-regular fa-clock',
41
- iconColor: '#124596',
42
- amountCall: 'min',
43
- labelTop: '▴+',
44
- labelButtom: '▾',
45
- color: '#D4D4D4',
46
- colorText: '#DC2626',
47
- colorTextPositive: '#16A34A',
48
- description: 'esta semana',
49
- },
50
- ],
51
- option3: [
52
- {
53
- status: 'Promedio de atención',
54
- icon: 'fa-solid fa-stopwatch',
55
- iconColor: '#124596',
56
- amountCall: 'min',
57
- labelTop: '▴+',
58
- labelButtom: '▾',
59
- color: '#D4D4D4',
60
- colorText: '#DC2626',
61
- description: 'esta semana',
62
- colorTextPositive: '#16A34A',
63
- },
64
- ],
65
- },
66
- } as ComponentMeta<typeof AverageAttended>;
67
-
68
- const Template: ComponentStory<typeof AverageAttended> = args => <AverageAttended {...args} />;
69
-
70
- export const Standard = Template.bind({});
71
- Standard.args = {};
@@ -1,311 +0,0 @@
1
- import {useCallback, useEffect, useState} from 'react';
2
- import {Badge} from '../../Elements/Badge/Badge';
3
- import {Icon} from '../../Elements/Icon/Icon';
4
- import './AverageAttended.scss';
5
-
6
- export interface IAverageAttended {
7
- // BASE
8
- option?: IOptions[];
9
- option2?: IOptions2[];
10
- option3?: IOptions3[];
11
- Call: ICall[];
12
-
13
- // IS-OPTIONS
14
-
15
- // EVENTS
16
-
17
- // GENERIC
18
- className?: string;
19
- }
20
- export interface IOptions {
21
- status?: string;
22
- icon: string;
23
- iconColor?: string;
24
- amountCall?: number | string;
25
- minutes?: string;
26
- description?: string;
27
- labelTop: string;
28
- labelButtom: string;
29
- color: string;
30
- colorText: string;
31
- colorTextPositive: string;
32
- }
33
- export interface IOptions2 {
34
- status?: string;
35
- icon: string;
36
- iconColor?: string;
37
- amountCall?: number | string;
38
- minutes?: string;
39
- description?: string;
40
- labelTop: string;
41
- labelButtom: string;
42
- color: string;
43
- colorText: string;
44
- colorTextPositive: string;
45
- }
46
-
47
- export interface IOptions3 {
48
- status?: string;
49
- icon: string;
50
- iconColor?: string;
51
- amountCall?: number | string;
52
- minutes?: string;
53
- description?: string;
54
- labelTop: string;
55
- labelButtom: string;
56
- color: string;
57
- colorText: string;
58
- colorTextPositive: string;
59
- }
60
- interface ICall {
61
- id: number;
62
- date: Date;
63
- arrivalTime: Date;
64
- serviceStartTime?: Date;
65
- }
66
- declare global {
67
- interface Date {
68
- getWeek(): number;
69
- }
70
- }
71
-
72
- export const AverageAttended = ({option, option2, option3, Call, className}: IAverageAttended) => {
73
- const [CallThisWeek, setCallThisWeek] = useState<number>(0);
74
- const [CallLastWeek, setCallLastWeek] = useState<number>(0);
75
- const [averageCall, setAverageCall] = useState<number>(0);
76
- const [currentCallWaitingTime, setCurrentCallWaitingTime] = useState<number | null>(null);
77
- const [currentCallerviceTime, setCurrentCallerviceTime] = useState<number | null>(null);
78
- const [averageWaitTime, setAverageWaitTime] = useState<number | null>(null);
79
- const [averageServiceTime, setAverageServiceTime] = useState<number | null>(null);
80
-
81
- useEffect(() => {
82
- const currentDate = new Date();
83
- const currentWeek = currentDate.getWeek();
84
- const lastWeek = currentWeek - 1;
85
-
86
- const CallInCurrentWeek = Call.filter(Call => Call.date.getWeek() === currentWeek);
87
- const CallInLastWeek = Call.filter(Call => Call.date.getWeek() === lastWeek);
88
-
89
- setCallThisWeek(CallInCurrentWeek.length);
90
- setCallLastWeek(CallInLastWeek.length);
91
-
92
- const avgCall = CallInLastWeek.length !== 0 ? (CallInCurrentWeek.length - CallInLastWeek.length) / CallInLastWeek.length : 0;
93
- const roundedAvgCall = parseFloat(avgCall.toFixed(2));
94
-
95
- setAverageCall(roundedAvgCall);
96
-
97
- // Calcular el tiempo de espera y tiempo de servicio de la llamada actual
98
- const currentCall = Call[Call.length - 1]; // Suponiendo que la última llamada es la actual
99
- if (currentCall) {
100
- const now = new Date();
101
- const arrivalTime = currentCall.arrivalTime;
102
- const serviceStartTime = currentCall.serviceStartTime || arrivalTime;
103
-
104
- // Calcular el tiempo de espera
105
- const waitingTime = (serviceStartTime || now).getTime() - arrivalTime.getTime();
106
- setCurrentCallWaitingTime(waitingTime / (1000 * 60)); // Convertir a minutos
107
-
108
- // Calcular el tiempo de servicio
109
- const serviceTime = now.getTime() - (serviceStartTime || arrivalTime).getTime();
110
- const totalMinutes = Math.floor(serviceTime / (1000 * 60));
111
- setCurrentCallerviceTime(totalMinutes); // Convertir a minutos
112
- const hours = Math.floor(totalMinutes / 60);
113
- const minutes = totalMinutes % 60;
114
-
115
- // Calcular el tiempo de servicio y promedio de tiempo de servicio
116
- const currentWeekServiceTime = calculateServiceTime(CallInCurrentWeek);
117
- const lastWeekServiceTime = calculateServiceTime(CallInLastWeek);
118
- const avgServiceTime = calculateAverageServiceTime(
119
- currentWeekServiceTime,
120
- lastWeekServiceTime,
121
- CallInCurrentWeek.length,
122
- CallInLastWeek.length,
123
- );
124
- setAverageServiceTime(avgServiceTime);
125
-
126
- // Verificar si hay horas para decidir cómo formatear
127
- } else {
128
- setCurrentCallWaitingTime(null);
129
- setCurrentCallerviceTime(null);
130
- }
131
-
132
- // Calcular el promedio de minutos de espera respecto a la semana anterior
133
- const currentWeekWaitTime = calculateWaitTime(CallInCurrentWeek);
134
- const lastWeekWaitTime = calculateWaitTime(CallInLastWeek);
135
- const avgWaitTime = calculateAverageWaitTime(currentWeekWaitTime, lastWeekWaitTime, CallInCurrentWeek.length, CallInLastWeek.length);
136
- setAverageWaitTime(avgWaitTime);
137
- }, [Call]);
138
-
139
- useEffect(() => {
140
- const intervalId = setInterval(() => {
141
- const currentCall = Call[Call.length - 1];
142
- if (currentCall && currentCall.serviceStartTime) {
143
- const now = new Date();
144
- const serviceTime = now.getTime() - currentCall.serviceStartTime.getTime();
145
-
146
- setCurrentCallerviceTime(serviceTime / (1000 * 60));
147
- } else {
148
- setCurrentCallerviceTime(null);
149
- }
150
- }, 1000); // Actualizar cada 1000 ms (1 segundo)
151
-
152
- return () => clearInterval(intervalId); // Limpiar el intervalo al desmontar el componente
153
- }, [Call]);
154
-
155
- const formattedServiceTime =
156
- currentCallerviceTime !== null
157
- ? `${Math.floor(currentCallerviceTime / 60)}:${(currentCallerviceTime % 60).toFixed(0).padStart(2, '0')}`
158
- : 'N/A';
159
-
160
- const formattedWaitingTime =
161
- currentCallWaitingTime !== null
162
- ? `${Math.floor(currentCallWaitingTime / 60)}:${(currentCallWaitingTime % 60).toFixed(0).padStart(2, '0')}`
163
- : 'N/A';
164
-
165
- const formattedAvgWaitTime =
166
- averageWaitTime !== null ? `${Math.floor(averageWaitTime / 60)}:${(averageWaitTime % 60).toFixed(0).padStart(2, '0')}` : 'N/A';
167
-
168
- const calculateAverageServiceTime = (
169
- currentWeekServiceTime: number,
170
- lastWeekServiceTime: number,
171
- currentWeekCalls: number,
172
- lastWeekCalls: number,
173
- ) => {
174
- const currentWeekDenominator = currentWeekCalls > 0 ? currentWeekCalls : 1;
175
- const lastWeekDenominator = lastWeekCalls > 0 ? lastWeekCalls : 1;
176
- // Calcula el promedio en minutos directamente
177
- const avgServiceTime = (currentWeekServiceTime / currentWeekDenominator - lastWeekServiceTime / lastWeekDenominator) / (1000 * 60);
178
- const percentage = avgServiceTime / 100;
179
-
180
- // Redondea avgServiceTime a dos decimales
181
- const roundedAvgServiceTime = parseFloat(avgServiceTime.toFixed(2));
182
-
183
- return roundedAvgServiceTime / 100;
184
- };
185
-
186
- const calculateServiceTime = (calls: ICall[]) => {
187
- return calls.reduce((acc, call) => {
188
- if (call.serviceStartTime && call.arrivalTime) {
189
- const serviceTime = new Date().getTime() - call.serviceStartTime.getTime();
190
- return acc + serviceTime;
191
- }
192
- return acc;
193
- }, 0);
194
- };
195
-
196
- const calculateWaitTime = (calls: ICall[]) => {
197
- return calls.reduce((acc, call) => {
198
- if (call.serviceStartTime && call.arrivalTime) {
199
- const waitTime = call.serviceStartTime.getTime() - call.arrivalTime.getTime();
200
- return acc + waitTime;
201
- }
202
- return acc;
203
- }, 0);
204
- };
205
- const calculateAverageWaitTime = (
206
- currentWeekWaitTime: number,
207
- lastWeekWaitTime: number,
208
- currentWeekCalls: number,
209
- lastWeekCalls: number,
210
- ) => {
211
- const currentWeekDenominator = currentWeekCalls > 0 ? currentWeekCalls : 1;
212
- const lastWeekDenominator = lastWeekCalls > 0 ? lastWeekCalls : 1;
213
- // Calcula el promedio en minutos directamente
214
- const avgWaitTime = (currentWeekWaitTime / currentWeekDenominator - lastWeekWaitTime / lastWeekDenominator) / (1000 * 60);
215
-
216
- // Redondea avgWaitTime a dos decimales
217
- const roundedAvgWaitTime = parseFloat(avgWaitTime.toFixed(2));
218
-
219
- return roundedAvgWaitTime;
220
- };
221
-
222
- Date.prototype.getWeek = function () {
223
- var date = new Date(this.getTime());
224
- date.setHours(0, 0, 0, 0);
225
- date.setDate(date.getDate() + 4 - (date.getDay() || 7));
226
- var yearStart = new Date(date.getFullYear(), 0, 1);
227
- var weekNo = Math.ceil(((date.getTime() - yearStart.getTime()) / 86400000 + 1) / 7);
228
- return weekNo;
229
- };
230
- return (
231
- <div className="elv-component elv-averageAttended">
232
- <div
233
- className={['averageAttended box is-flex is-gap-4 is-justify-content-space-between', `${className ? ' ' + className : ''}`].join(
234
- '',
235
- )}
236
- >
237
- {option?.map(item => (
238
- <div className="averageAttended__option is-flex is-align-items-center is-fullw">
239
- <div>
240
- <Icon icon={item.icon} color={item.iconColor} className="is-size-1" />
241
- </div>
242
- <div className="is-flex is-flex-direction-column is-gap-4">
243
- <div className="averageAttended__colorDark has-text-weight-semibold">{item.status}</div>
244
- <div className="averageAttended__colorDark has-text-weight-bold is-size-3">{CallThisWeek}</div>
245
- <div className="is-flex is-align-items-center">
246
- <Badge
247
- text={`${averageCall < 0 ? item.labelButtom : item.labelTop}${averageCall.toString()}%`}
248
- color={item.color}
249
- colorText={`${averageCall < 0 ? item.colorText : item.colorTextPositive}`}
250
- className="badge"
251
- />
252
- <p className="ml-3 is-size-14px has-text-grey">{item.description}</p>
253
- </div>
254
- </div>
255
- </div>
256
- ))}
257
-
258
- {option2?.map(item => (
259
- <div className="averageAttended__option is-flex is-align-items-center is-fullw">
260
- <div>
261
- <Icon icon={item.icon} color={item.iconColor} className="is-size-1" />
262
- </div>
263
- <div className="is-flex is-flex-direction-column is-gap-4">
264
- <div className="averageAttended__colorDark has-text-weight-semibold">{item.status}</div>
265
- {formattedWaitingTime !== null && (
266
- <div className="averageAttended__colorDark has-text-weight-bold is-size-3">{`${formattedWaitingTime}${item.amountCall}`}</div>
267
- )}
268
-
269
- <div className="is-flex is-align-items-center">
270
- <Badge
271
- text={`${averageWaitTime !== null && averageWaitTime < 0 ? item.labelButtom : item.labelTop}${
272
- averageWaitTime !== null && averageWaitTime.toFixed(1)
273
- }%`}
274
- color={item.color}
275
- colorText={averageWaitTime != null && averageWaitTime < 0 ? item.colorText : item.colorTextPositive}
276
- className="badge"
277
- />
278
- <p className="ml-3 is-size-14px has-text-grey">{item.description}</p>
279
- </div>
280
- </div>
281
- </div>
282
- ))}
283
-
284
- {option3?.map(item => (
285
- <div className="averageAttended__option is-flex is-align-items-center is-fullw">
286
- <div>
287
- <Icon icon={item.icon} color={item.iconColor} className="is-size-1" />
288
- </div>
289
- <div className="is-flex is-flex-direction-column is-gap-4">
290
- <div className="averageAttended__colorDark has-text-weight-semibold">{item.status}</div>
291
- {formattedServiceTime !== null && (
292
- <div className="averageAttended__colorDark has-text-weight-bold is-size-3">{`${formattedServiceTime}${item.amountCall}`}</div>
293
- )}
294
- <div className="is-flex is-align-items-center">
295
- <Badge
296
- text={`${averageServiceTime != null && averageServiceTime < 0 ? item.labelButtom : item.labelTop}${
297
- averageServiceTime != null && averageServiceTime.toFixed(1)
298
- }%`}
299
- color={item.color}
300
- colorText={`${averageServiceTime != null && averageServiceTime < 0 ? item.colorText : item.colorTextPositive}`}
301
- className="badge"
302
- />
303
- <p className="ml-3 is-size-14px has-text-grey">{item.description}</p>
304
- </div>
305
- </div>
306
- </div>
307
- ))}
308
- </div>
309
- </div>
310
- );
311
- };
@@ -1,45 +0,0 @@
1
- import {ComponentStory, ComponentMeta} from '@storybook/react';
2
- import {Breadcrumb} from './Breadcrumb';
3
-
4
- export default {
5
- title: 'Components/Breadcrumb',
6
- component: Breadcrumb,
7
- args: {
8
- defaultActiveLabel: 'Label 2',
9
- items: [
10
- {label: '', icon: 'fa-solid fa-house', onClick: () => console.log('1er Label Presionado')},
11
- {label: 'Label 2', onClick: () => console.log('2do Label Presionado')},
12
- {label: 'Label 3', onClick: () => console.log('3er Label Presionado')},
13
- {label: 'Label 4', icon: 'fas fa-coffee', onClick: () => console.log('4to Label Presionado')},
14
- {label: 'Label 5', onClick: () => console.log('5to Label Presionado')},
15
- ],
16
- },
17
- argTypes: {type: {control: 'radio', options: ['not-lined', 'updown-lined', 'outlined', 'outlined-border', 'outlined-border-color']}},
18
- } as ComponentMeta<typeof Breadcrumb>;
19
-
20
- const Template: ComponentStory<typeof Breadcrumb> = args => <Breadcrumb {...args} />;
21
-
22
- export const NotLine = Template.bind({});
23
- NotLine.args = {
24
- type: 'not-lined',
25
- };
26
-
27
- export const UpDownLine = Template.bind({});
28
- UpDownLine.args = {
29
- type: 'updown-lined',
30
- };
31
-
32
- export const Outlined = Template.bind({});
33
- Outlined.args = {
34
- type: 'outlined',
35
- };
36
-
37
- export const OutlinedBorder = Template.bind({});
38
- OutlinedBorder.args = {
39
- type: 'outlined-border',
40
- };
41
-
42
- export const OutlinedBorderColor = Template.bind({});
43
- OutlinedBorderColor.args = {
44
- type: 'outlined-border-color',
45
- };
@@ -1,68 +0,0 @@
1
- import {useState} from 'react';
2
- import './breadcrumb.scss';
3
- import {shortenText} from '../../../utils/functions';
4
-
5
- export interface IBreadcrumb extends React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement> {
6
- // base
7
- type: string;
8
- defaultActiveLabel?: string;
9
- items: {
10
- label?: string;
11
- icon?: any;
12
- onClick?: () => void;
13
- }[];
14
-
15
- // events
16
- handleActive?: (itemActive: ItemValue) => void;
17
-
18
- // react
19
- className?: string;
20
- }
21
-
22
- export interface ItemValue {
23
- label?: string;
24
- icon?: any;
25
- onClick?: () => void;
26
- }
27
-
28
- export const Breadcrumb = ({type, defaultActiveLabel, items, handleActive, className, ...props}: IBreadcrumb) => {
29
- const itemActive = items.find(item => item.label === defaultActiveLabel);
30
- const [activeStep, setActiveStep] = useState(itemActive);
31
-
32
- const handleClick = (item: ItemValue) => {
33
- setActiveStep(item);
34
-
35
- if (handleActive) {
36
- handleActive(item);
37
- }
38
-
39
- if (item.onClick) {
40
- item.onClick();
41
- }
42
- };
43
-
44
- return (
45
- <div className="elv-component elv-nav_bc" {...props}>
46
- <nav aria-label="nav_bc" className={`nav_bc nav_bc--${type} ${className ? className : ''}`}>
47
- <ol className="bc-list">
48
- {items.map((item, index) => (
49
- <li key={item.label} className={`bc-item ${item === activeStep ? 'bc-item--active' : ''}`}>
50
- <p
51
- className="bc-item__bc-link"
52
- onClick={() => {
53
- handleClick(item);
54
- }}
55
- >
56
- {item.icon && item.icon !== '' && (
57
- <i className={`${item.icon} item-icon ${item.label && item.label !== '' ? '--and-label' : ''}`}></i>
58
- )}
59
- {item.label && item.label !== '' && shortenText(item.label, 25)}
60
- </p>
61
- {index < items.length - 1 && <i className="fa-solid fa-chevron-right bc-item__chebron"></i>}
62
- </li>
63
- ))}
64
- </ol>
65
- </nav>
66
- </div>
67
- );
68
- };
@@ -1,82 +0,0 @@
1
- @import '/src/sass/utilities/variables';
2
-
3
- /* =========================================== NAV (father div & types) ============================================== */
4
- .nav_bc {
5
- display: inline-block;
6
- min-width: 430px;
7
- padding-right: 10px;
8
- padding-left: 5px;
9
-
10
- &--updown-lined {
11
- border-top: 1px solid $primary-600;
12
- border-bottom: 1px solid $primary-600;
13
- }
14
-
15
- &--outlined {
16
- border: 1px solid $primary-600;
17
- border-radius: 10px;
18
- }
19
-
20
- &--outlined-border {
21
- border: 1px solid $primary-600;
22
- border-radius: 25px;
23
- }
24
-
25
- &--outlined-border-color {
26
- background-color: #e7f0ff;
27
- border: 1px solid $primary-600;
28
- border-radius: 25px;
29
- }
30
-
31
- /* =========================================== OL (items list) ============================================== */
32
- .bc-list {
33
- display: flex;
34
- list-style: none;
35
- flex-wrap: wrap;
36
- padding-left: 0px;
37
- margin: 15px;
38
- }
39
-
40
- /* =========================================== LI (items) ============================================== */
41
- .bc-item {
42
- display: flex;
43
- justify-content: center;
44
- text-align: center;
45
- align-items: center;
46
- color: #737373;
47
- cursor: pointer;
48
-
49
- font-size: 14px;
50
- line-height: 150%;
51
-
52
- &--active {
53
- color: $primary-600;
54
- }
55
-
56
- /* =========================================== LINK ============================================== */
57
- &__bc-link {
58
- align-items: center;
59
- text-decoration: none;
60
- text-align: center;
61
-
62
- &:hover {
63
- color: $primary-600;
64
- }
65
-
66
- .item-icon {
67
- font-size: 16px;
68
-
69
- &.--and-label {
70
- margin-right: 10px;
71
- }
72
- }
73
- }
74
-
75
- /* =========================================== CHEBRÓN ============================================== */
76
- &__chebron {
77
- color: $text-500;
78
- margin-left: 15px;
79
- margin-right: 15px;
80
- }
81
- }
82
- }
@@ -1,76 +0,0 @@
1
- @import '/src/sass/utilities/variables';
2
-
3
- .elv-cta {
4
- .cta {
5
- min-height: 290px;
6
- min-width: 320px;
7
-
8
- background-color: $white;
9
- border: 1px solid $text-300;
10
- box-shadow: 0px 4px 8px rgba(14, 31, 53, 0.1), 0px 8px 16px rgba(14, 31, 53, 0.16), 0px 16px 28px -1px rgba(14, 31, 53, 0.1);
11
- border-radius: 22px;
12
- overflow: hidden;
13
-
14
- &__principal {
15
- max-width: 265px;
16
- margin: 53px 48px;
17
-
18
- .title {
19
- font-size: 36px;
20
- min-width: 230px;
21
- }
22
- }
23
-
24
- &__items {
25
- margin: 48px;
26
- margin-left: 0px;
27
- padding: 30px;
28
-
29
- @media screen and (max-width: $mobile) {
30
- margin: 0px;
31
- }
32
-
33
- .columns {
34
- gap: 40px;
35
-
36
- @media screen and (max-width: 1100px) {
37
- flex-direction: column;
38
- }
39
-
40
- .item {
41
- &__icon {
42
- min-width: 48px;
43
- height: 48px;
44
- border-radius: 8px;
45
- background-color: $primary-100;
46
-
47
- .fa_icon {
48
- font-size: 25px;
49
- color: $text-800;
50
- }
51
-
52
- .svg_icon {
53
- width: 25px;
54
- fill: $text-800;
55
- }
56
- }
57
-
58
- &__description {
59
- margin-left: 24px;
60
- color: $primary-600;
61
- // max-width: 178px;
62
-
63
- .title {
64
- margin: 0;
65
- color: $primary-600;
66
- }
67
-
68
- p {
69
- max-width: 100%;
70
- }
71
- }
72
- }
73
- }
74
- }
75
- }
76
- }