@webitel/ui-sdk 24.12.29 → 24.12.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (295) hide show
  1. package/CHANGELOG.md +271 -131
  2. package/README.md +6 -0
  3. package/dist/img/sprite/index.js +8 -2
  4. package/dist/img/sprite/tree-collapse.svg +4 -0
  5. package/dist/img/sprite/tree-cross.svg +5 -0
  6. package/dist/img/sprite/tree-line.svg +10 -0
  7. package/dist/ui-sdk.css +1 -1
  8. package/dist/ui-sdk.js +7736 -7442
  9. package/dist/ui-sdk.umd.cjs +17 -17
  10. package/package.json +13 -6
  11. package/src/api/axios/generateInstance.js +6 -2
  12. package/src/api/clients/agents/agentChats.js +18 -19
  13. package/src/api/clients/agents/agents.js +29 -7
  14. package/src/api/clients/buckets/buckets.js +16 -3
  15. package/src/api/clients/calendars/calendars.js +21 -3
  16. package/src/api/clients/catalog/catalog.js +1 -3
  17. package/src/api/clients/chatGateways/chatGateways.js +41 -12
  18. package/src/api/clients/communications/communications.js +25 -6
  19. package/src/api/clients/configurations/configurations.js +13 -3
  20. package/src/api/clients/flows/flow.js +20 -9
  21. package/src/api/clients/gateways/gateways.js +12 -3
  22. package/src/api/clients/lists/blacklists.js +16 -3
  23. package/src/api/clients/media/media.js +16 -3
  24. package/src/api/clients/queues/queues.js +16 -6
  25. package/src/api/clients/roles/roles.js +3 -1
  26. package/src/api/clients/skills/skills.js +16 -3
  27. package/src/api/clients/teams/teams.js +17 -7
  28. package/src/api/clients/users/__tests__/users.spec.js +3 -1
  29. package/src/api/clients/users/users.js +8 -2
  30. package/src/api/clients//321/201ontacts/contactChatMessagesHistory.js +21 -13
  31. package/src/api/clients//321/201ontacts/contacts.js +38 -15
  32. package/src/api/history/transcript/callTranscript.js +10 -2
  33. package/src/api/interceptors/request/updateToken.interceptor.js +2 -1
  34. package/src/api/transformers/applyTransform.js +5 -1
  35. package/src/api/transformers/camelToSnake/camelToSnake.transformer.js +2 -1
  36. package/src/api/transformers/snakeToCamel/snakeToCamel.transformer.js +2 -1
  37. package/src/assets/icons/sprite/index.js +8 -2
  38. package/src/assets/icons/sprite/tree-collapse.svg +4 -0
  39. package/src/assets/icons/sprite/tree-cross.svg +5 -0
  40. package/src/assets/icons/sprite/tree-line.svg +10 -0
  41. package/src/components/index.js +8 -12
  42. package/src/components/on-demand/wt-navigation-menu/components/_internals/nav-menu-lvl-1.vue +4 -2
  43. package/src/components/on-demand/wt-navigation-menu/components/_internals/nav-menu-lvl-2.vue +3 -4
  44. package/src/components/on-demand/wt-navigation-menu/components/wt-navigation-menu.vue +6 -6
  45. package/src/components/on-demand/wt-route-transition/wt-route-transition.vue +12 -12
  46. package/src/components/on-demand/wt-save-failed-popup/wt-save-failed-popup.vue +1 -3
  47. package/src/components/on-demand/wt-selection-popup/wt-selection-popup.vue +3 -3
  48. package/src/components/on-demand/wt-start-page/components/start-page-card.vue +4 -2
  49. package/src/components/on-demand/wt-start-page/components/start-page-logo.vue +1 -1
  50. package/src/components/on-demand/wt-start-page/components/wt-start-page.vue +2 -3
  51. package/src/components/on-demand/wt-table-transition/wt-table-transition.vue +7 -7
  52. package/src/components/wt-action-bar/wt-action-bar.vue +16 -12
  53. package/src/components/wt-app-header/__tests__/WtHeaderActions.spec.js +3 -1
  54. package/src/components/wt-app-header/_variables.scss +0 -1
  55. package/src/components/wt-app-header/wt-app-header.vue +4 -4
  56. package/src/components/wt-app-header/wt-app-navigator.vue +6 -7
  57. package/src/components/wt-app-header/wt-header-actions.vue +6 -8
  58. package/src/components/wt-avatar/wt-avatar.vue +4 -3
  59. package/src/components/wt-badge/wt-badge.vue +1 -2
  60. package/src/components/wt-button/wt-button.vue +3 -5
  61. package/src/components/wt-button-select/__tests__/WtButtonSelect.spec.js +6 -2
  62. package/src/components/wt-button-select/wt-button-select.vue +3 -4
  63. package/src/components/wt-checkbox/_variables.scss +1 -2
  64. package/src/components/wt-checkbox/wt-checkbox.vue +1 -2
  65. package/src/components/wt-chip/_variables.scss +0 -1
  66. package/src/components/wt-confirm-dialog/wt-confirm-dialog.vue +15 -5
  67. package/src/components/wt-context-menu/_variables.scss +3 -1
  68. package/src/components/wt-context-menu/wt-context-menu.vue +1 -3
  69. package/src/components/wt-copy-action/wt-copy-action.vue +1 -2
  70. package/src/components/wt-datepicker/_variables.scss +17 -5
  71. package/src/components/wt-datepicker/wt-datepicker.vue +2 -7
  72. package/src/components/wt-divider/_variables.scss +0 -1
  73. package/src/components/wt-divider/wt-divider.vue +5 -3
  74. package/src/components/wt-dual-panel/__tests__/WtDualPanel.js +2 -2
  75. package/src/components/wt-dual-panel/wt-dual-panel.vue +6 -5
  76. package/src/components/wt-dummy/_variables.scss +0 -1
  77. package/src/components/wt-dummy/wt-dummy.vue +1 -1
  78. package/src/components/wt-empty/wt-empty.vue +42 -34
  79. package/src/components/wt-error-page/_variables.scss +0 -1
  80. package/src/components/wt-error-page/wt-error-page.vue +2 -4
  81. package/src/components/wt-expansion-panel/_variables.scss +0 -1
  82. package/src/components/wt-expansion-panel/wt-expansion-panel.vue +3 -8
  83. package/src/components/wt-filters-panel-wrapper/__tests__/WtFiltersPanelWrapper.spec.js +12 -4
  84. package/src/components/wt-filters-panel-wrapper/wt-filters-panel-wrapper.vue +8 -7
  85. package/src/components/wt-headline/_variables.scss +0 -1
  86. package/src/components/wt-headline-nav/_variables.scss +0 -1
  87. package/src/components/wt-headline-nav/wt-headline-nav.vue +2 -1
  88. package/src/components/wt-hint/wt-hint.vue +1 -3
  89. package/src/components/wt-icon/_variables.scss +0 -1
  90. package/src/components/wt-icon-action/wt-icon-action.vue +13 -12
  91. package/src/components/wt-icon-btn/_variables.scss +0 -2
  92. package/src/components/wt-icon-btn/wt-icon-btn.vue +4 -6
  93. package/src/components/wt-image/wt-image.vue +14 -13
  94. package/src/components/wt-indicator/wt-indicator.vue +2 -7
  95. package/src/components/wt-input/_variables.scss +1 -2
  96. package/src/components/wt-input/wt-input.vue +13 -10
  97. package/src/components/wt-input-info/_variables.scss +0 -1
  98. package/src/components/wt-intersection-observer/__tests__/WtIntersectionObserver.spec.js +1 -1
  99. package/src/components/wt-intersection-observer/wt-intersection-observer.vue +9 -8
  100. package/src/components/wt-item-link/_variables.scss +0 -1
  101. package/src/components/wt-label/_variables.scss +0 -1
  102. package/src/components/wt-label/wt-label.vue +1 -4
  103. package/src/components/wt-load-bar/_variables.scss +0 -1
  104. package/src/components/wt-load-bar/wt-load-bar.vue +0 -1
  105. package/src/components/wt-loader/_variables.scss +0 -2
  106. package/src/components/wt-loader/wt-loader.vue +1 -3
  107. package/src/components/wt-logo/wt-logo.vue +1 -1
  108. package/src/components/wt-navigation-bar/__tests__/WtNavigationBar.spec.js +9 -3
  109. package/src/components/wt-navigation-bar/_variables.scss +9 -3
  110. package/src/components/wt-navigation-bar/wt-navigation-bar.vue +27 -11
  111. package/src/components/wt-notification/_variables.scss +0 -1
  112. package/src/components/wt-notifications-bar/__tests__/WtNotificationsBar.spec.js +1 -1
  113. package/src/components/wt-notifications-bar/_variables.scss +1 -2
  114. package/src/components/wt-notifications-bar/wt-notifications-bar.vue +4 -2
  115. package/src/components/wt-page-header/wt-page-header.vue +3 -2
  116. package/src/components/wt-page-wrapper/__tests__/WtPageWrapper.spec.js +3 -1
  117. package/src/components/wt-page-wrapper/_variables.scss +0 -1
  118. package/src/components/wt-page-wrapper/wt-page-wrapper.vue +0 -2
  119. package/src/components/wt-pagination/_variables.scss +1 -2
  120. package/src/components/wt-pagination/wt-pagination.vue +2 -1
  121. package/src/components/wt-player/_variables.scss +6 -2
  122. package/src/components/wt-player/wt-player.vue +52 -53
  123. package/src/components/wt-popup/_variables.scss +0 -1
  124. package/src/components/wt-popup/wt-popup.vue +2 -8
  125. package/src/components/wt-progress-bar/_variables.scss +0 -1
  126. package/src/components/wt-progress-bar/wt-progress-bar.vue +7 -6
  127. package/src/components/wt-radio/_variables.scss +1 -2
  128. package/src/components/wt-radio/wt-radio.vue +1 -2
  129. package/src/components/wt-rounded-action/_variables.scss +3 -1
  130. package/src/components/wt-search-bar/_variables.scss +4 -2
  131. package/src/components/wt-search-bar/wt-search-bar.vue +10 -4
  132. package/src/components/wt-select/_multiselect.scss +9 -15
  133. package/src/components/wt-select/_variables.scss +3 -2
  134. package/src/components/wt-select/mixins/multiselectMixin.js +2 -1
  135. package/src/components/wt-select/wt-select.vue +25 -26
  136. package/src/components/wt-slider/_variables.scss +0 -1
  137. package/src/components/wt-slider/wt-slider.vue +3 -3
  138. package/src/components/wt-status-select/_variables.scss +8 -4
  139. package/src/components/wt-stepper/_variables.scss +0 -1
  140. package/src/components/wt-stepper/wt-stepper.vue +5 -5
  141. package/src/components/wt-switcher/_variables.scss +0 -1
  142. package/src/components/wt-switcher/wt-switcher.vue +2 -3
  143. package/src/components/wt-table/__tests__/WtTable.spec.js +8 -2
  144. package/src/components/wt-table/_variables.scss +0 -1
  145. package/src/components/wt-table/types/table-header.ts +8 -0
  146. package/src/components/wt-table/wt-table.vue +111 -109
  147. package/src/components/wt-table-actions/_variables.scss +1 -2
  148. package/src/components/wt-table-actions/wt-table-actions.vue +1 -2
  149. package/src/components/wt-table-column-select/wt-table-column-select.vue +11 -8
  150. package/src/components/wt-tabs/_variables.scss +0 -1
  151. package/src/components/wt-tabs/wt-tabs.vue +6 -6
  152. package/src/components/wt-tags-input/__tests__/WtTagsInput.spec.js +6 -6
  153. package/src/components/wt-tags-input/mixin/taggableMixin.js +3 -1
  154. package/src/components/wt-tags-input/wt-tags-input.vue +8 -10
  155. package/src/components/wt-textarea/__tests__/WtTextarea.spec.js +6 -2
  156. package/src/components/wt-textarea/_variables.scss +0 -1
  157. package/src/components/wt-textarea/wt-textarea.vue +6 -7
  158. package/src/components/wt-time-input/wt-time-input.vue +1 -2
  159. package/src/components/wt-timepicker/_variables.scss +1 -2
  160. package/src/components/wt-timepicker/wt-timepicker.vue +10 -8
  161. package/src/components/wt-tooltip/_internals/useTooltipTriggerSubscriptions.js +6 -1
  162. package/src/components/wt-tooltip/_internals/wt-tooltip-floating.vue +1 -3
  163. package/src/components/wt-tooltip/_variables.scss +0 -1
  164. package/src/components/wt-tooltip/wt-tooltip.vue +13 -2
  165. package/src/components/wt-tree-table/_variables.scss +19 -0
  166. package/src/components/wt-tree-table/wt-tree-table.vue +323 -0
  167. package/src/components/wt-tree-table-row/wt-tree-table-row.vue +171 -0
  168. package/src/composables/useAccessControl/useAccessControl.js +12 -4
  169. package/src/composables/useCachedInterval/useCachedInterval.js +6 -2
  170. package/src/composables/useCachedItemInstanceName/useCachedItemInstanceName.js +4 -1
  171. package/src/composables/useCard/useCardComponent.js +10 -9
  172. package/src/composables/useCard/useCardTabs.js +6 -3
  173. package/src/composables/useRepresentableAgentPauseCause/__tests__/useRepresentableAgentPauseCause.spec.js +20 -10
  174. package/src/composables/useValidate/useValidate.js +1 -1
  175. package/src/composables/useWtTable/useWtTable.ts +25 -0
  176. package/src/css/main.scss +7 -1
  177. package/src/css/pages/table-page.scss +1 -2
  178. package/src/css/styleguide/border-radius/_border-radius.scss +1 -1
  179. package/src/css/styleguide/colors/_deprecated.scss +83 -24
  180. package/src/css/styleguide/colors/_palette.scss +1340 -251
  181. package/src/css/styleguide/colors/reusable/_text-field.scss +6 -2
  182. package/src/css/styleguide/fonts/_fonts.scss +36 -18
  183. package/src/css/styleguide/spacings/_spacings.scss +1 -1
  184. package/src/css/styleguide/transitions/_transitions.scss +1 -1
  185. package/src/css/styleguide/transitions/fade/_fade.scss +5 -4
  186. package/src/css/styleguide/viewport-breakpoints/_viewport-breakpoints.scss +0 -1
  187. package/src/enums/WebitelApplications/WebitelApplications.enum.js +7 -7
  188. package/src/enums/index.js +5 -10
  189. package/src/locale/en/en.js +5 -2
  190. package/src/locale/ru/ru.js +7 -3
  191. package/src/locale/ua/ua.js +7 -3
  192. package/src/mixins/dataFilterMixins/__tests__/apiFilterMixin.spec.js +2 -1
  193. package/src/mixins/dataFilterMixins/apiFilterMixin.js +3 -1
  194. package/src/mixins/dataFilterMixins/baseFilterMixin/baseFilterMixin.js +2 -1
  195. package/src/mixins/dataFilterMixins/enumFilterMixin.js +2 -1
  196. package/src/mixins/dataFilterMixins/paginationFilterMixin.js +4 -1
  197. package/src/mixins/dataFilterMixins/sortFilterMixin.js +2 -1
  198. package/src/mixins/validationMixin/useValidation.js +17 -7
  199. package/src/mixins/validationMixin/validationMixin.js +16 -8
  200. package/src/modules/AgentStatusSelect/api/pause-cause.js +4 -1
  201. package/src/modules/AgentStatusSelect/components/__tests__/wt-cc-agent-status-select.spec.js +18 -6
  202. package/src/modules/AgentStatusSelect/components/_internals/wt-cc-pause-cause-popup.vue +3 -2
  203. package/src/modules/AgentStatusSelect/components/wt-cc-agent-status-select.vue +5 -2
  204. package/src/modules/Appearance/components/__tests__/wt-dark-mode-switcher.spec.js +6 -2
  205. package/src/modules/AuditForm/components/__tests__/audit-form-question-write-wrapper.spec.js +12 -4
  206. package/src/modules/AuditForm/components/__tests__/audit-form.spec.js +18 -5
  207. package/src/modules/AuditForm/components/audit-form-question-read-wrapper.vue +4 -2
  208. package/src/modules/AuditForm/components/audit-form-question-write-wrapper.vue +15 -5
  209. package/src/modules/AuditForm/components/audit-form-question.vue +10 -4
  210. package/src/modules/AuditForm/components/audit-form.vue +24 -7
  211. package/src/modules/AuditForm/components/questions/options/__tests__/audit-form-question-options.spec.js +6 -2
  212. package/src/modules/AuditForm/components/questions/options/audit-form-question-options.vue +5 -5
  213. package/src/modules/AuditForm/components/questions/score/audit-form-question-score.vue +9 -4
  214. package/src/modules/CSVExport/CSVExport.js +5 -2
  215. package/src/modules/CSVExport/XLSExport.js +7 -7
  216. package/src/modules/CSVExport/__tests__/CSVExport.spec.js +4 -1
  217. package/src/modules/CSVExport/mixins/exportCSVMixin.js +3 -1
  218. package/src/modules/CSVExport/mixins/exportXLSMixin.js +3 -1
  219. package/src/modules/CardStoreModule/composables/useCardStore.js +6 -2
  220. package/src/modules/DeleteConfirmationPopup/__tests__/delete-confirmation-popup.spec.js +3 -3
  221. package/src/modules/DeleteConfirmationPopup/components/delete-confirmation-popup.vue +6 -3
  222. package/src/modules/FilesExport/__tests__/FilesExport.spec.js +6 -2
  223. package/src/modules/FilesExport/mixins/exportFilesMixin.js +6 -2
  224. package/src/modules/FilesExport/scripts/generateMediaURL.js +2 -1
  225. package/src/modules/Filters/classes/BaseFilterSchema.js +15 -6
  226. package/src/modules/Filters/components/filter-datetime.vue +7 -5
  227. package/src/modules/Filters/components/filter-pagination.vue +7 -5
  228. package/src/modules/Filters/components/filter-search.vue +4 -4
  229. package/src/modules/Filters/components/filter-select.vue +33 -24
  230. package/src/modules/Filters/components/filter-table-fields.vue +1 -3
  231. package/src/modules/Filters/composables/useTableFilters.js +3 -1
  232. package/src/modules/Filters/scripts/getters/localStorageGetter.js +6 -2
  233. package/src/modules/Filters/scripts/getters/queryGetter.js +2 -1
  234. package/src/modules/Filters/scripts/setters/localStorageSetter.js +6 -2
  235. package/src/modules/Filters/scripts/setters/querySetter.js +2 -1
  236. package/src/modules/Filters/scripts/utils/changeRouteQuery.js +2 -1
  237. package/src/modules/Filters/store/FiltersStoreModule.js +3 -3
  238. package/src/modules/Notifications/store/NotificationsStoreModule.js +14 -5
  239. package/src/modules/Notifications/store/__tests__/NotificationsStoreModule.actions.spec.js +10 -3
  240. package/src/modules/ObjectPermissions/_internals/components/permissions-role-row.vue +1 -3
  241. package/src/modules/ObjectPermissions/_internals/components/permissions-role-select.vue +1 -3
  242. package/src/modules/ObjectPermissions/_internals/components/permissions-tab-role-popup.vue +8 -5
  243. package/src/modules/ObjectPermissions/_internals/modules/filters/store/filters.store.js +3 -4
  244. package/src/modules/ObjectPermissions/_internals/store/helpers/createObjectPermissionsStoreModule.js +1 -2
  245. package/src/modules/ObjectPermissions/_internals/store/modules/objectPermissionsStoreModule.js +10 -14
  246. package/src/modules/ObjectPermissions/components/permissions-tab.vue +12 -12
  247. package/src/modules/ObjectPermissions/store/index.js +2 -6
  248. package/src/modules/QueryFilters/components/__tests__/filter-datetime.spec.js +3 -1
  249. package/src/modules/QueryFilters/components/__tests__/filter-from-to.spec.js +6 -2
  250. package/src/modules/QueryFilters/components/__tests__/filter-search.spec.js +7 -2
  251. package/src/modules/QueryFilters/components/abstract-api-filter.vue +15 -5
  252. package/src/modules/QueryFilters/components/abstract-enum-filter.vue +15 -5
  253. package/src/modules/QueryFilters/components/filter-datetime.vue +1 -3
  254. package/src/modules/QueryFilters/components/filter-from-to.vue +1 -1
  255. package/src/modules/QueryFilters/components/filter-search.vue +1 -3
  256. package/src/modules/QueryFilters/components/filter-table-fields.vue +1 -3
  257. package/src/modules/QueryFilters/mixins/__tests__/enumFilterMixin.spec.js +4 -1
  258. package/src/modules/QueryFilters/mixins/baseFilterMixin/baseFilterMixin.js +9 -3
  259. package/src/modules/QueryFilters/mixins/enumFilterMixin.js +10 -3
  260. package/src/modules/QueryFilters/mixins/paginationFilterMixin.js +4 -2
  261. package/src/modules/QueryFilters/mixins/sortFilterMixin.js +2 -1
  262. package/src/modules/QueryFilters/store/QueryFiltersStoreModule.js +2 -1
  263. package/src/modules/QueryFilters/store/__tests__/QueryFiltersStoreModule.spec.js +10 -3
  264. package/src/modules/TableComponentModule/composables/useTableEmpty.js +13 -4
  265. package/src/modules/TableStoreModule/composables/useTableStore.js +18 -6
  266. package/src/modules/TableStoreModule/store/TableStoreModule.js +36 -21
  267. package/src/modules/TableStoreModule/store/__tests__/TableStoreModule.spec.js +7 -2
  268. package/src/modules/Userinfo/api/userinfo.js +4 -1
  269. package/src/modules/Userinfo/classes/ApplicationsAccess.js +3 -1
  270. package/src/modules/Userinfo/store/UserinfoStoreModule.js +25 -9
  271. package/src/plugins/breakpoint/breakpoint.plugin.js +2 -1
  272. package/src/scripts/__tests__/caseConverters.spec.js +4 -1
  273. package/src/scripts/__tests__/updateObject.spec.js +6 -2
  274. package/src/scripts/caseConverters.js +37 -29
  275. package/src/scripts/compareSize.ts +9 -6
  276. package/src/scripts/debounce.js +2 -1
  277. package/src/scripts/index.js +2 -8
  278. package/src/scripts/logger.js +4 -4
  279. package/src/scripts/preventHiddenPageCallsDecorator.js +6 -2
  280. package/src/scripts/saveAsJSON.js +3 -1
  281. package/src/scripts/sortQueryAdapters.js +11 -0
  282. package/src/store/BaseStoreModules/ApiStoreModule.js +26 -7
  283. package/src/store/BaseStoreModules/BaseStoreModule.js +2 -1
  284. package/src/store/BaseStoreModules/__tests__/BaseStoreModule.spec.js +28 -7
  285. package/src/store/helpers/getNamespacedState.js +3 -1
  286. package/src/store/new/modules/apiStoreModule/apiStoreModule.js +19 -14
  287. package/src/store/new/modules/cardStoreModule/useCardStore.js +6 -2
  288. package/src/store/new/modules/tableStoreModule/__tests__/tableStoreModule.spec.js +6 -8
  289. package/src/store/new/modules/tableStoreModule/tableStoreModule.js +31 -28
  290. package/src/store/new/modules/tableStoreModule/useTableStore.js +18 -6
  291. package/src/validators/variableSearchValidator/__tests__/variableSearchValidator.spec.js +2 -1
  292. package/src/validators/websocketValidator/__tests__/websocketValidator.spec.js +3 -1
  293. package/src/components/wt-table/_internals/getSortOrder.js +0 -12
  294. /package/dist/img/sprite/{plus.svg → tree-expand.svg} +0 -0
  295. /package/src/assets/icons/sprite/{plus.svg → tree-expand.svg} +0 -0
@@ -29,9 +29,13 @@
29
29
  --wt-text-field-select-option-text-hover-color: var(--primary-on-color);
30
30
  --wt-text-field-select-option-text-selected-color: var(--primary-on-color);
31
31
 
32
- --wt-text-field-select-option-wrapper-border-color: var(--dp-22-surface-color);
32
+ --wt-text-field-select-option-wrapper-border-color: var(
33
+ --dp-22-surface-color
34
+ );
33
35
  --wt-text-field-select-option-background-color: var(--dp-22-surface-color);
34
- --wt-text-field-select-option-background-hover-color: var(--primary-light-color);
36
+ --wt-text-field-select-option-background-hover-color: var(
37
+ --primary-light-color
38
+ );
35
39
  --wt-text-field-select-option-background-selected-color: var(--primary-color);
36
40
  }
37
41
 
@@ -1,125 +1,143 @@
1
1
  @font-face {
2
2
  font-family: 'Montserrat';
3
- src: url('../../../assets/fonts/Montserrat/Montserrat-Thin.ttf') format('truetype');
3
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Thin.ttf')
4
+ format('truetype');
4
5
  font-weight: 100;
5
6
  font-style: normal;
6
7
  }
7
8
 
8
9
  @font-face {
9
10
  font-family: 'Montserrat';
10
- src: url('../../../assets/fonts/Montserrat/Montserrat-ThinItalic.ttf') format('truetype');
11
+ src: url('../../../assets/fonts/Montserrat/Montserrat-ThinItalic.ttf')
12
+ format('truetype');
11
13
  font-weight: 100;
12
14
  font-style: italic;
13
15
  }
14
16
 
15
17
  @font-face {
16
18
  font-family: 'Montserrat';
17
- src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraLight.ttf') format('truetype');
19
+ src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraLight.ttf')
20
+ format('truetype');
18
21
  font-weight: 200;
19
22
  font-style: normal;
20
23
  }
21
24
 
22
25
  @font-face {
23
26
  font-family: 'Montserrat';
24
- src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraLightItalic.ttf') format('truetype');
27
+ src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraLightItalic.ttf')
28
+ format('truetype');
25
29
  font-weight: 200;
26
30
  font-style: italic;
27
31
  }
28
32
 
29
33
  @font-face {
30
34
  font-family: 'Montserrat';
31
- src: url('../../../assets/fonts/Montserrat/Montserrat-Light.ttf') format('truetype');
35
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Light.ttf')
36
+ format('truetype');
32
37
  font-weight: 300;
33
38
  font-style: normal;
34
39
  }
35
40
 
36
41
  @font-face {
37
42
  font-family: 'Montserrat';
38
- src: url('../../../assets/fonts/Montserrat/Montserrat-LightItalic.ttf') format('truetype');
43
+ src: url('../../../assets/fonts/Montserrat/Montserrat-LightItalic.ttf')
44
+ format('truetype');
39
45
  font-weight: 300;
40
46
  font-style: italic;
41
47
  }
42
48
 
43
49
  @font-face {
44
50
  font-family: 'Montserrat';
45
- src: url('../../../assets/fonts/Montserrat/Montserrat-Regular.ttf') format('truetype');
51
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Regular.ttf')
52
+ format('truetype');
46
53
  font-weight: 400;
47
54
  font-style: normal;
48
55
  }
49
56
 
50
57
  @font-face {
51
58
  font-family: 'Montserrat';
52
- src: url('../../../assets/fonts/Montserrat/Montserrat-Italic.ttf') format('truetype');
59
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Italic.ttf')
60
+ format('truetype');
53
61
  font-weight: 400;
54
62
  font-style: italic;
55
63
  }
56
64
 
57
65
  @font-face {
58
66
  font-family: 'Montserrat';
59
- src: url('../../../assets/fonts/Montserrat/Montserrat-Medium.ttf') format('truetype');
67
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Medium.ttf')
68
+ format('truetype');
60
69
  font-weight: 500;
61
70
  font-style: normal;
62
71
  }
63
72
 
64
73
  @font-face {
65
74
  font-family: 'Montserrat';
66
- src: url('../../../assets/fonts/Montserrat/Montserrat-MediumItalic.ttf') format('truetype');
75
+ src: url('../../../assets/fonts/Montserrat/Montserrat-MediumItalic.ttf')
76
+ format('truetype');
67
77
  font-weight: 500;
68
78
  font-style: italic;
69
79
  }
70
80
 
71
81
  @font-face {
72
82
  font-family: 'Montserrat';
73
- src: url('../../../assets/fonts/Montserrat/Montserrat-SemiBold.ttf') format('truetype');
83
+ src: url('../../../assets/fonts/Montserrat/Montserrat-SemiBold.ttf')
84
+ format('truetype');
74
85
  font-weight: 600;
75
86
  font-style: normal;
76
87
  }
77
88
 
78
89
  @font-face {
79
90
  font-family: 'Montserrat';
80
- src: url('../../../assets/fonts/Montserrat/Montserrat-SemiBoldItalic.ttf') format('truetype');
91
+ src: url('../../../assets/fonts/Montserrat/Montserrat-SemiBoldItalic.ttf')
92
+ format('truetype');
81
93
  font-weight: 600;
82
94
  font-style: italic;
83
95
  }
84
96
 
85
97
  @font-face {
86
98
  font-family: 'Montserrat';
87
- src: url('../../../assets/fonts/Montserrat/Montserrat-Bold.ttf') format('truetype');
99
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Bold.ttf')
100
+ format('truetype');
88
101
  font-weight: 700;
89
102
  font-style: normal;
90
103
  }
91
104
 
92
105
  @font-face {
93
106
  font-family: 'Montserrat';
94
- src: url('../../../assets/fonts/Montserrat/Montserrat-BoldItalic.ttf') format('truetype');
107
+ src: url('../../../assets/fonts/Montserrat/Montserrat-BoldItalic.ttf')
108
+ format('truetype');
95
109
  font-weight: 700;
96
110
  font-style: italic;
97
111
  }
98
112
 
99
113
  @font-face {
100
114
  font-family: 'Montserrat';
101
- src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraBold.ttf') format('truetype');
115
+ src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraBold.ttf')
116
+ format('truetype');
102
117
  font-weight: 800;
103
118
  font-style: normal;
104
119
  }
105
120
 
106
121
  @font-face {
107
122
  font-family: 'Montserrat';
108
- src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraBoldItalic.ttf') format('truetype');
123
+ src: url('../../../assets/fonts/Montserrat/Montserrat-ExtraBoldItalic.ttf')
124
+ format('truetype');
109
125
  font-weight: 800;
110
126
  font-style: italic;
111
127
  }
112
128
 
113
129
  @font-face {
114
130
  font-family: 'Montserrat';
115
- src: url('../../../assets/fonts/Montserrat/Montserrat-Black.ttf') format('truetype');
131
+ src: url('../../../assets/fonts/Montserrat/Montserrat-Black.ttf')
132
+ format('truetype');
116
133
  font-weight: 900;
117
134
  font-style: normal;
118
135
  }
119
136
 
120
137
  @font-face {
121
138
  font-family: 'Montserrat';
122
- src: url('../../../assets/fonts/Montserrat/Montserrat-BlackItalic.ttf') format('truetype');
139
+ src: url('../../../assets/fonts/Montserrat/Montserrat-BlackItalic.ttf')
140
+ format('truetype');
123
141
  font-weight: 900;
124
142
  font-style: italic;
125
143
  }
@@ -12,4 +12,4 @@
12
12
  --spacing-xl: calc(var(--_spacing-multiplicator) * 5);
13
13
  --spacing-2xl: calc(var(--_spacing-multiplicator) * 6);
14
14
  --spacing-3xl: calc(var(--_spacing-multiplicator) * 7);
15
- }
15
+ }
@@ -1 +1 @@
1
- @import 'fade/fade';
1
+ @import 'fade/fade';
@@ -1,8 +1,9 @@
1
-
2
- .fade-enter-active, .fade-leave-active {
1
+ .fade-enter-active,
2
+ .fade-leave-active {
3
3
  transition: opacity var(--transition);
4
4
  }
5
5
 
6
- .fade-enter, .fade-leave-to {
6
+ .fade-enter,
7
+ .fade-leave-to {
7
8
  opacity: 0;
8
- }
9
+ }
@@ -22,4 +22,3 @@ $media-width-lg: #{'min-width: '} $viewport-lg;
22
22
  $media-width-md: #{'max-width: '} $viewport-md;
23
23
  $media-width-sm: #{'max-width: '} $viewport-sm;
24
24
  $media-width-xs: #{'max-width: '} $viewport-xs;
25
-
@@ -1,11 +1,11 @@
1
1
  const WebitelApplications = Object.freeze({
2
- ADMIN: 'admin',
3
- AGENT: 'agent',
4
- SUPERVISOR: 'supervisor',
5
- HISTORY: 'history',
6
- AUDIT: 'audit',
7
- ANALYTICS: 'grafana',
8
- CRM: 'crm',
2
+ ADMIN: 'admin',
3
+ AGENT: 'agent',
4
+ SUPERVISOR: 'supervisor',
5
+ HISTORY: 'history',
6
+ AUDIT: 'audit',
7
+ ANALYTICS: 'grafana',
8
+ CRM: 'crm',
9
9
  });
10
10
 
11
11
  export default WebitelApplications;
@@ -1,22 +1,17 @@
1
- import AbstractUserStatus
2
- from './AbstractUserStatus/AbstractUserStatus.enum.js';
1
+ import AbstractUserStatus from './AbstractUserStatus/AbstractUserStatus.enum.js';
3
2
  import AgentStatus from './AgentStatus/AgentStatus.enum.js';
4
- import ChatGatewayProvider
5
- from './ChatGatewayProvider/ChatGatewayProvider.enum.js';
3
+ import ChatGatewayProvider from './ChatGatewayProvider/ChatGatewayProvider.enum.js';
6
4
  import ComponentSize from './ComponentSize/ComponentSize.enum.js';
7
5
  import IconAction from './IconAction/IconAction.enum.js';
8
6
  import QueueType from './QueueType/QueueType.enum.js';
9
- import TypesExportedSettings
10
- from './TypesExportedSettings/TypesExportedSettings.enum.js';
7
+ import TypesExportedSettings from './TypesExportedSettings/TypesExportedSettings.enum.js';
11
8
 
12
9
  // Webitel Applications group
13
10
  import AdminSections from './WebitelApplications/AdminSections.enum.js';
14
11
  import AuditorSections from './WebitelApplications/AuditorSections.enum.js';
15
12
  import CrmSections from './WebitelApplications/CrmSections.enum.js';
16
- import SupervisorSections
17
- from './WebitelApplications/SupervisorSections.enum.js';
18
- import WebitelApplications
19
- from './WebitelApplications/WebitelApplications.enum.js';
13
+ import SupervisorSections from './WebitelApplications/SupervisorSections.enum.js';
14
+ import WebitelApplications from './WebitelApplications/WebitelApplications.enum.js';
20
15
 
21
16
  export {
22
17
  AbstractUserStatus,
@@ -71,6 +71,7 @@ export default {
71
71
  more: 'More',
72
72
  read: 'Read',
73
73
  create: 'Create',
74
+ draggable: 'Draggable',
74
75
  },
75
76
  // yak zhe ya zaebalsya povtoriaty odni i ti sami slova!!!!
76
77
  vocabulary: {
@@ -291,7 +292,8 @@ export default {
291
292
  isRegExpMatched: 'Password must match the regular expression:',
292
293
  regExpValidator: 'This regular expression is not valid',
293
294
  domainValidator: 'Incorrect domain',
294
- decimalValidator: 'Decimal precision should be no more than { count } places',
295
+ decimalValidator:
296
+ 'Decimal precision should be no more than { count } places',
295
297
  integer: 'The field should contain only whole numbers',
296
298
  },
297
299
  webitelUI: {
@@ -382,7 +384,8 @@ export default {
382
384
  },
383
385
  deleteConfirmationPopup: {
384
386
  title: 'Confirm deletion',
385
- askingAlert: 'Are you sure you want to delete {subject}? This action cannot be undone.',
387
+ askingAlert:
388
+ 'Are you sure you want to delete {subject}? This action cannot be undone.',
386
389
  tableAskingAlert:
387
390
  'Are you sure you want\n to delete {count} record? | Are you sure you want\n to delete {count} records?',
388
391
  deleteAll: 'ALL',
@@ -71,6 +71,7 @@ export default {
71
71
  more: 'Больше',
72
72
  read: 'Читать',
73
73
  create: 'Создать',
74
+ draggable: 'Перетащить',
74
75
  },
75
76
  vocabulary: {
76
77
  language: 'Язык',
@@ -289,7 +290,8 @@ export default {
289
290
  isRegExpMatched: 'Пароль должен соответствовать регулярному выражению:',
290
291
  regExpValidator: 'Не правильное регулярное выражение',
291
292
  domainValidator: 'Неправильный домен',
292
- decimalValidator: 'Количество десятичных знаков не должно быть больше { count }',
293
+ decimalValidator:
294
+ 'Количество десятичных знаков не должно быть больше { count }',
293
295
  integer: 'Поле должно содержать только целые числа',
294
296
  },
295
297
  webitelUI: {
@@ -380,7 +382,8 @@ export default {
380
382
  },
381
383
  deleteConfirmationPopup: {
382
384
  title: 'Подтвердите удаление',
383
- askingAlert: 'Вы уверены, что хотите удалить {subject}? Это действие не может быть отменено.',
385
+ askingAlert:
386
+ 'Вы уверены, что хотите удалить {subject}? Это действие не может быть отменено.',
384
387
  tableAskingAlert:
385
388
  'Вы уверенны, что хотите\n удалить {count} запись? | Вы уверенны, что хотите\n удалить {count} записей?',
386
389
  deleteAll: 'ВСЕ',
@@ -402,7 +405,8 @@ export default {
402
405
  },
403
406
  statusSelectErrorPopup: {
404
407
  title: 'Внимание',
405
- message: 'Лимит операторов в паузе превышен. Перерыв сейчас недоступен.',
408
+ message:
409
+ 'Лимит операторов в паузе превышен. Перерыв сейчас недоступен.',
406
410
  },
407
411
  },
408
412
  saveFailedPopup: {
@@ -72,6 +72,7 @@ export default {
72
72
  more: 'Більше',
73
73
  read: 'Читати',
74
74
  create: 'Створити',
75
+ draggable: 'Перетягнути',
75
76
  },
76
77
  vocabulary: {
77
78
  language: 'Мова',
@@ -289,7 +290,8 @@ export default {
289
290
  isRegExpMatched: 'Пароль має відповідати регулярному виразу:',
290
291
  regExpValidator: 'Не правильний регулярний вираз',
291
292
  domainValidator: 'Невірний домен',
292
- decimalValidator: 'Кількість десяткових знаків не повинна бути більше { count }',
293
+ decimalValidator:
294
+ 'Кількість десяткових знаків не повинна бути більше { count }',
293
295
  integer: 'Поле повинно містити лише цілі числа',
294
296
  },
295
297
  webitelUI: {
@@ -380,7 +382,8 @@ export default {
380
382
  },
381
383
  deleteConfirmationPopup: {
382
384
  title: 'Підтвердіть видалення',
383
- askingAlert: 'Ви впевнені, що хочете видалити {subject}? Ця дія не може бути скасована.',
385
+ askingAlert:
386
+ 'Ви впевнені, що хочете видалити {subject}? Ця дія не може бути скасована.',
384
387
  tableAskingAlert:
385
388
  'Ви впевнені, що хочете\n видалити {count} запис? | Ви впевнені, що хочете\n видалити {count} записів?',
386
389
  deleteAll: 'ВСІ',
@@ -402,7 +405,8 @@ export default {
402
405
  },
403
406
  statusSelectErrorPopup: {
404
407
  title: 'Увага',
405
- message: 'Ліміт операторів в паузі перевищено. Перерва наразі недоступна.',
408
+ message:
409
+ 'Ліміт операторів в паузі перевищено. Перерва наразі недоступна.',
406
410
  },
407
411
  },
408
412
  saveFailedPopup: {
@@ -19,7 +19,8 @@ describe('API filter mixin', () => {
19
19
  };
20
20
 
21
21
  beforeEach(() => {
22
- if (Object.keys(router.currentRoute.value.query).length) router.replace({ query: null });
22
+ if (Object.keys(router.currentRoute.value.query).length)
23
+ router.replace({ query: null });
23
24
  });
24
25
 
25
26
  it('Correctly sets value from $route query', async () => {
@@ -12,7 +12,9 @@ export default {
12
12
 
13
13
  methods: {
14
14
  async restoreValue(idList) {
15
- this.value = idList?.length ? await this.fetchSelected(idList) : this.defaultValue;
15
+ this.value = idList?.length
16
+ ? await this.fetchSelected(idList)
17
+ : this.defaultValue;
16
18
  },
17
19
 
18
20
  async fetchSelected(idList) {
@@ -22,7 +22,8 @@ export default {
22
22
 
23
23
  methods: {
24
24
  restore({ filterQuery }) {
25
- const value = this.getValueFromQuery({ filterQuery }) || this.defaultValue;
25
+ const value =
26
+ this.getValueFromQuery({ filterQuery }) || this.defaultValue;
26
27
  this.restoreValue(value);
27
28
  },
28
29
  },
@@ -24,7 +24,8 @@ export default {
24
24
  );
25
25
  } else {
26
26
  this.value =
27
- this.options.find((option) => option[this.storedProp] === value) || this.defaultValue;
27
+ this.options.find((option) => option[this.storedProp] === value) ||
28
+ this.defaultValue;
28
29
  }
29
30
  },
30
31
  },
@@ -18,7 +18,10 @@ export default {
18
18
  watch: {
19
19
  '$route.query': {
20
20
  handler(newValue, oldValue) {
21
- if (newValue.page !== oldValue.page || newValue.size !== oldValue.size) {
21
+ if (
22
+ newValue.page !== oldValue.page ||
23
+ newValue.size !== oldValue.size
24
+ ) {
22
25
  this.restore();
23
26
  }
24
27
  },
@@ -41,7 +41,8 @@ const queryToSortAdapter = (order) => {
41
41
  }
42
42
  };
43
43
 
44
- const encodeSortQuery = ({ column, order }) => `${sortToQueryAdapter(order)}${column.field}`;
44
+ const encodeSortQuery = ({ column, order }) =>
45
+ `${sortToQueryAdapter(order)}${column.field}`;
45
46
 
46
47
  const decodeSortQuery = ({ value }) => {
47
48
  const sort = queryToSortAdapter(value.slice(0, 1));
@@ -1,7 +1,10 @@
1
1
  import { computed, isReactive } from 'vue';
2
2
  import { useI18n } from 'vue-i18n';
3
3
 
4
- export function useValidation({ v: inputV, customValidators: inputCustomValidators }) {
4
+ export function useValidation({
5
+ v: inputV,
6
+ customValidators: inputCustomValidators,
7
+ }) {
5
8
  const { t } = useI18n();
6
9
 
7
10
  // support vue options api, where v is a reactive, not ref
@@ -14,19 +17,24 @@ export function useValidation({ v: inputV, customValidators: inputCustomValidato
14
17
  }
15
18
  // end
16
19
 
17
- const isValidation = computed(() => !!v && !!v.value && !!Object.keys(v.value).length);
20
+ const isValidation = computed(
21
+ () => !!v && !!v.value && !!Object.keys(v.value).length,
22
+ );
18
23
  const invalid = computed(() => isValidation.value && v.value.$error);
19
24
 
20
25
  const validationText = computed(() => {
21
26
  let validationText = '';
22
27
  if (isValidation.value && invalid.value) {
23
28
  if (v.value.required?.$invalid) validationText = t('validation.required');
24
- else if (v.value.numeric?.$invalid) validationText = t('validation.numeric');
29
+ else if (v.value.numeric?.$invalid)
30
+ validationText = t('validation.numeric');
25
31
  else if (v.value.email?.$invalid) validationText = t('validation.email');
26
32
  else if (v.value.gatewayHostValidator?.$invalid)
27
33
  validationText = t('validation.gatewayHostValidator');
28
- else if (v.value.ipValidator?.$invalid) validationText = t('validation.ipValidator');
29
- else if (v.value.macValidator?.$invalid) validationText = t('validation.macValidator');
34
+ else if (v.value.ipValidator?.$invalid)
35
+ validationText = t('validation.ipValidator');
36
+ else if (v.value.macValidator?.$invalid)
37
+ validationText = t('validation.macValidator');
30
38
  else if (v.value.minValue?.$invalid)
31
39
  validationText = `${t('validation.minValue')} ${v.value.minValue.$params.min}`;
32
40
  else if (v.value.maxValue?.$invalid)
@@ -38,14 +46,16 @@ export function useValidation({ v: inputV, customValidators: inputCustomValidato
38
46
  else if (v.value.url?.$invalid) validationText = `${t('validation.url')}`;
39
47
  else if (v.value.regExpValidator?.$invalid)
40
48
  validationText = `${t('validation.regExpValidator')}`;
41
- else if (v.value.sameAs?.$invalid) validationText = `${t('validation.sameAs')}`;
49
+ else if (v.value.sameAs?.$invalid)
50
+ validationText = `${t('validation.sameAs')}`;
42
51
  else if (v.value.domainValidator?.$invalid)
43
52
  validationText = `${t('validation.domainValidator')}`;
44
53
  else if (v.value.decimalValidator?.$invalid)
45
54
  validationText = `${t('validation.decimalValidator')} ${v.value.decimalValidator.$params.count}`;
46
55
  else if (v.value.websocketValidator?.$invalid)
47
56
  validationText = `${t('validation.websocketValidator')}`;
48
- else if (v.value.integer?.$invalid) validationText = `${t('validation.integer')}`;
57
+ else if (v.value.integer?.$invalid)
58
+ validationText = `${t('validation.integer')}`;
49
59
  else if (v.value.regex?.$invalid)
50
60
  validationText =
51
61
  v.value.regex?.$message ||
@@ -19,13 +19,18 @@ export default {
19
19
  validationText() {
20
20
  let validationText = '';
21
21
  if (this.isValidation && this.invalid) {
22
- if (this.v.required?.$invalid) validationText = this.$t('validation.required');
23
- else if (this.v.numeric?.$invalid) validationText = this.$t('validation.numeric');
24
- else if (this.v.email?.$invalid) validationText = this.$t('validation.email');
22
+ if (this.v.required?.$invalid)
23
+ validationText = this.$t('validation.required');
24
+ else if (this.v.numeric?.$invalid)
25
+ validationText = this.$t('validation.numeric');
26
+ else if (this.v.email?.$invalid)
27
+ validationText = this.$t('validation.email');
25
28
  else if (this.v.gatewayHostValidator?.$invalid)
26
29
  validationText = this.$t('validation.gatewayHostValidator');
27
- else if (this.v.ipValidator?.$invalid) validationText = this.$t('validation.ipValidator');
28
- else if (this.v.macValidator?.$invalid) validationText = this.$t('validation.macValidator');
30
+ else if (this.v.ipValidator?.$invalid)
31
+ validationText = this.$t('validation.ipValidator');
32
+ else if (this.v.macValidator?.$invalid)
33
+ validationText = this.$t('validation.macValidator');
29
34
  else if (this.v.minValue?.$invalid)
30
35
  validationText = `${this.$t('validation.minValue')} ${this.v.minValue.$params.min}`;
31
36
  else if (this.v.maxValue?.$invalid)
@@ -34,17 +39,20 @@ export default {
34
39
  validationText = this.$t('validation.sipAccountValidator');
35
40
  else if (this.v.minLength?.$invalid)
36
41
  validationText = `${this.$t('validation.minLength')} ${this.v.minLength.$params.min}`;
37
- else if (this.v.url?.$invalid) validationText = `${this.$t('validation.url')}`;
42
+ else if (this.v.url?.$invalid)
43
+ validationText = `${this.$t('validation.url')}`;
38
44
  else if (this.v.regExpValidator?.$invalid)
39
45
  validationText = `${this.$t('validation.regExpValidator')}`;
40
- else if (this.v.sameAs?.$invalid) validationText = `${this.$t('validation.sameAs')}`;
46
+ else if (this.v.sameAs?.$invalid)
47
+ validationText = `${this.$t('validation.sameAs')}`;
41
48
  else if (this.v.domainValidator?.$invalid)
42
49
  validationText = `${this.$t('validation.domainValidator')}`;
43
50
  else if (this.v.decimalValidator?.$invalid)
44
51
  validationText = `${this.$t('validation.decimalValidator')} ${this.v.decimalValidator.$params.count}`;
45
52
  else if (this.v.websocketValidator?.$invalid)
46
53
  validationText = `${this.$t('validation.websocketValidator')}`;
47
- else if (this.v.integer?.$invalid) validationText = `${this.$t('validation.integer')}`;
54
+ else if (this.v.integer?.$invalid)
55
+ validationText = `${this.$t('validation.integer')}`;
48
56
  else if (this.v.isRegExpMatched?.$invalid)
49
57
  validationText =
50
58
  this.v.isRegExpMatched?.$params?.errorMessage ||
@@ -19,7 +19,10 @@ const PauseCauseAPIFactory = ({ instance, OpenAPIConfig }) => {
19
19
 
20
20
  const allowChange = true;
21
21
  try {
22
- const response = await service.searchPauseCauseForAgent(agentId, allowChange);
22
+ const response = await service.searchPauseCauseForAgent(
23
+ agentId,
24
+ allowChange,
25
+ );
23
26
  const { items, next } = applyTransform(response.data, [
24
27
  snakeToCamel(),
25
28
  merge(getDefaultGetListResponse()),
@@ -14,7 +14,9 @@ vi.spyOn(PauseCauseAPIFactory, 'default').mockImplementation(() => ({
14
14
 
15
15
  const agentStatusMock = vi.fn(() => {});
16
16
  // https://stackoverflow.com/a/63727813
17
- vi.spyOn(AgentStatusAPIFactory, 'default').mockImplementation(() => ({ patch: agentStatusMock }));
17
+ vi.spyOn(AgentStatusAPIFactory, 'default').mockImplementation(() => ({
18
+ patch: agentStatusMock,
19
+ }));
18
20
 
19
21
  const agent = {
20
22
  status: '',
@@ -43,7 +45,9 @@ describe('Wt Cc Agent Status Select', () => {
43
45
  it(`at wt-status-select "change" to "online" event, triggers agent status patch
44
46
  with "online" status`, () => {
45
47
  const wrapper = shallowMount(WtCcAgentStatusSelect, mountOptions);
46
- wrapper.findComponent({ name: 'wt-status-select' }).vm.$emit('change', AgentStatus.ONLINE);
48
+ wrapper
49
+ .findComponent({ name: 'wt-status-select' })
50
+ .vm.$emit('change', AgentStatus.ONLINE);
47
51
  const reqPayload = {
48
52
  status: AgentStatus.ONLINE,
49
53
  agentId: agent.agentId,
@@ -53,18 +57,24 @@ describe('Wt Cc Agent Status Select', () => {
53
57
  });
54
58
  it('at wt-status-select "change" to "pause" event, pause causes are loaded', async () => {
55
59
  const wrapper = shallowMount(WtCcAgentStatusSelect, mountOptions);
56
- wrapper.findComponent({ name: 'wt-status-select' }).vm.$emit('change', AgentStatus.PAUSE);
60
+ wrapper
61
+ .findComponent({ name: 'wt-status-select' })
62
+ .vm.$emit('change', AgentStatus.PAUSE);
57
63
  await wrapper.vm.$nextTick();
58
64
  expect(getAgentPauseCausesMock).toHaveBeenCalled();
59
65
  });
60
66
  it(`at wt-status-select "change" to "pause" event and pause causes truthy response,
61
67
  pause-cause-popup appears`, async () => {
62
68
  const wrapper = mount(WtCcAgentStatusSelect, mountOptions);
63
- wrapper.findComponent({ name: 'wt-status-select' }).vm.$emit('change', AgentStatus.PAUSE);
69
+ wrapper
70
+ .findComponent({ name: 'wt-status-select' })
71
+ .vm.$emit('change', AgentStatus.PAUSE);
64
72
  await wrapper.vm.$nextTick(); // load pause causes
65
73
  await wrapper.vm.$nextTick();
66
74
  await wrapper.vm.$nextTick(); // render popup
67
- expect(wrapper.findComponent({ name: 'pause-cause-popup' }).isVisible()).toBe(true);
75
+ expect(
76
+ wrapper.findComponent({ name: 'pause-cause-popup' }).isVisible(),
77
+ ).toBe(true);
68
78
  });
69
79
  it(`at pause-cause-popup "change" event, triggers patch agent status
70
80
  with "pause" status and passed pauseCause`, async () => {
@@ -73,7 +83,9 @@ describe('Wt Cc Agent Status Select', () => {
73
83
  wrapper.vm.openPauseCausePopup();
74
84
  await wrapper.vm.$nextTick();
75
85
  await wrapper.vm.$nextTick();
76
- wrapper.findComponent({ name: 'pause-cause-popup' }).vm.$emit('change', pauseCause);
86
+ wrapper
87
+ .findComponent({ name: 'pause-cause-popup' })
88
+ .vm.$emit('change', pauseCause);
77
89
  const reqPayload = {
78
90
  status: AgentStatus.PAUSE,
79
91
  agentId: agent.agentId,
@@ -11,7 +11,7 @@
11
11
  <form @submit.prevent="setPause">
12
12
  <ul>
13
13
  <li
14
- v-for="(option) of pauseCause"
14
+ v-for="option of pauseCause"
15
15
  :key="option.id"
16
16
  class="wt-cc-pause-cause-popup-option"
17
17
  >
@@ -25,7 +25,8 @@
25
25
  <div class="wt-cc-pause-cause-popup-option__limits-wrapper">
26
26
  <span
27
27
  :class="{
28
- 'wt-cc-pause-cause-popup-option__duration--overflow': option.isOverflow,
28
+ 'wt-cc-pause-cause-popup-option__duration--overflow':
29
+ option.isOverflow,
29
30
  }"
30
31
  >
31
32
  {{ option.duration }}
@@ -107,8 +107,11 @@ function handleClosed(event) {
107
107
  // sometimes we want to choose 'pause' repeatedly
108
108
  // but 'change' event from wt-status-select can't give us the same value,
109
109
  // in this case we have to use value from 'closed' event to choose 'pause' status
110
- if ((event.value === chosenStatus.value || !chosenStatus.value) // if closed status the same as chosen, or chosen status is empty
111
- && event.value === AgentStatus.PAUSE) { // and only for 'pause' status
110
+ if (
111
+ (event.value === chosenStatus.value || !chosenStatus.value) && // if closed status the same as chosen, or chosen status is empty
112
+ event.value === AgentStatus.PAUSE
113
+ ) {
114
+ // and only for 'pause' status
112
115
  handleStatus(event.value);
113
116
  }
114
117
  }