@webitel/ui-sdk 26.6.95 → 26.6.97
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/{clients-Bj07uFky.js → clients-Ban2DI-G.js} +8 -7
- package/dist/{components-l3RJbNmv.js → components-CSWXogKF.js} +13 -8
- package/dist/{composables-vmCh4eqT.js → composables-CeAM_2lo.js} +12 -14
- package/dist/ui-sdk.css +1 -1
- package/dist/ui-sdk.js +605 -605
- package/dist/ui-sdk.umd.cjs +382 -382
- package/dist/useValidation-lRiKF7xV.js +39 -0
- package/dist/{useVidstackSrc-epUQZhkL.js → useVidstackSrc-B4mUti_c.js} +1 -1
- package/dist/{vidstack-C6nBVWwn-BlZqtkYB.js → vidstack-C6nBVWwn-cKiWT0KJ.js} +2 -2
- package/dist/{vidstack-CI5oafcm-DAV7Lilr.js → vidstack-CI5oafcm-DfWpvayJ.js} +1 -1
- package/dist/{vidstack-DUnfBERX2-Cl6yTfB3.js → vidstack-DUnfBERX2-BJtKHFxc.js} +1 -1
- package/dist/{vidstack-audio-CH4wIf0F.js → vidstack-audio-BCPraiiR.js} +1 -1
- package/dist/{vidstack-dash-CmlmZIFT.js → vidstack-dash-MBx5aEEA.js} +2 -2
- package/dist/{vidstack-hls-D1sxUvBd.js → vidstack-hls-BbZsbfaO.js} +2 -2
- package/dist/vidstack-video-DwlbGwN7.js +2 -0
- package/dist/{wt-chat-emoji-CGf8vRlv.js → wt-chat-emoji-Zfe96hoz.js} +1 -1
- package/dist/{wt-datepicker-D2GjAUWU.js → wt-datepicker-BtjegGDk.js} +175 -92
- package/dist/{wt-display-chip-items-C3TZt4Gn.js → wt-display-chip-items-YauywYzZ.js} +1 -1
- package/dist/{wt-expansion-card-DvLD-TP4.js → wt-expansion-card-DET-o0Jq.js} +1 -1
- package/dist/{wt-galleria-DT0SOjXk.js → wt-galleria-B6kMr_xS.js} +1 -1
- package/dist/{wt-icon-btn-BIU9YjS8.js → wt-icon-btn-DYjjSl-C.js} +5 -2
- package/dist/{wt-player-_mTlxsCu.js → wt-player-Bbirdlj9.js} +1 -1
- package/dist/{wt-search-bar-CUxiGcoz.js → wt-search-bar-D50lqCd8.js} +1 -1
- package/dist/{wt-send-message-popup-CCSOL-wH.js → wt-send-message-popup-DV1i1Q52.js} +2 -2
- package/dist/{wt-table-DS_2J5zF.js → wt-table-C39WpJH8.js} +1 -1
- package/dist/{wt-timepicker-Bxdc4s3_.js → wt-timepicker-CYNrvbWf.js} +1 -1
- package/dist/{wt-tree-table-2K7cdct7.js → wt-tree-table-umRsVKWt.js} +1 -1
- package/dist/{wt-type-extension-value-input-Bl8jpyTn.js → wt-type-extension-value-input-CpYbzjDU.js} +2 -2
- package/dist/{wt-vidstack-player-BaH2oaMr.js → wt-vidstack-player-CC6dwrnv.js} +10 -10
- package/package.json +3 -2
- package/src/api/clients/wtTypes/_shared/utils/sortDynamicFields.ts +18 -4
- package/src/api/types/ApiModule.d.ts +28 -9
- package/src/components/_internals/composables/useGalleriaFullscreen/useGalleriaFullscreen.ts +25 -9
- package/src/components/_internals/composables/useSelect/useSelect.ts +3 -5
- package/src/components/_internals/composables/useSelect/useSelectCustomValues.ts +0 -3
- package/src/components/_internals/composables/useSelect/useSelectOptions.ts +7 -2
- package/src/components/_internals/composables/useWtTable/useWtTable.ts +1 -1
- package/src/components/wt-badge-new/types/WtBadge.d.ts +12 -0
- package/src/components/wt-badge-new/wt-badge.vue +2 -12
- package/src/components/wt-button/wt-button.vue +2 -1
- package/src/components/wt-datepicker/_internals/composables/useAutoSeparator.ts +96 -0
- package/src/components/wt-datepicker/_internals/composables/useDatepicker.ts +78 -0
- package/src/components/wt-datepicker/_internals/composables/usePreventZeroPad.ts +10 -24
- package/src/components/wt-datepicker/_internals/composables/useStrictInput.ts +61 -0
- package/src/components/wt-datepicker/wt-datepicker.vue +4 -8
- package/src/components/wt-icon-btn/wt-icon-btn.vue +1 -1
- package/src/components/wt-popup/wt-popup.vue +3 -1
- package/src/components/wt-slider/wt-slider.vue +1 -1
- package/src/components/wt-table/types/WtTable.d.ts +5 -1
- package/src/components/wt-vidstack-player/components/panels/playback-controls-panel/components/time-group.vue +0 -2
- package/src/components/wt-vidstack-player/components/panels/playback-controls-panel/playback-controls-panel.vue +0 -1
- package/src/components/wt-vidstack-player/components/panels/screen-sharing-controls-panel/screen-sharing-controls-panel.vue +1 -2
- package/src/components/wt-vidstack-player/components/panels/video-display-panel/video-display-panel.vue +1 -9
- package/src/composables/index.d.ts +9 -0
- package/src/composables/index.ts +1 -0
- package/src/composables/useEventBus/useEventBus.d.ts +11 -0
- package/src/composables/useEventBus/useEventBus.ts +16 -0
- package/src/enums/BroadcastChannelName/BroadcastChannelName.d.ts +5 -0
- package/src/enums/BroadcastChannelName/UserSettingsBroadcastMessage.d.ts +12 -0
- package/src/enums/ButtonColor/ButtonColor.d.ts +11 -0
- package/src/enums/ButtonVariant/ButtonVariant.d.ts +6 -0
- package/src/enums/ChipColor/ChipColor.d.ts +11 -0
- package/src/enums/ComponentSize/ComponentSize.d.ts +17 -0
- package/src/enums/ConnectionQualityLevel/ConnectionQualityLevel.enum.d.ts +7 -0
- package/src/enums/CrudAction/CrudAction.d.ts +7 -0
- package/src/enums/DefaultWorkspaceTabSettings/DefaultWorkspaceTabSettings.d.ts +10 -0
- package/src/enums/EmptyCause/EmptyCause.d.ts +6 -0
- package/src/enums/FormatDateMode/FormatDateMode.d.ts +9 -0
- package/src/enums/IconColor/IconColor.d.ts +17 -0
- package/src/enums/LoginOptions/LoginOptions.d.ts +6 -0
- package/src/enums/MessageColor/MessageColor.d.ts +9 -0
- package/src/enums/MessageVariant/MessageVariant.d.ts +6 -0
- package/src/enums/MimeTypes/MimeTypes.enum.d.ts +17 -0
- package/src/enums/ProcessingTableColumnType/ProcessingTableColumnType.d.ts +9 -0
- package/src/enums/QueueType/QueueType.enum.d.ts +28 -0
- package/src/enums/RelativeDatetimeValue/RelativeDatetimeValue.d.ts +8 -0
- package/src/enums/RingtoneType/RingtoneType.d.ts +6 -0
- package/src/enums/SingleSignOnProvider/SingleSignOnProvider.d.ts +8 -0
- package/src/enums/SingleSignOnProviderIconMappings/SingleSignOnProviderIconMappings.d.ts +7 -0
- package/src/enums/WebitelApplications/AdminSections.d.ts +46 -0
- package/src/enums/WebitelApplications/AuditorSections.d.ts +5 -0
- package/src/enums/WebitelApplications/CrmSections.d.ts +16 -0
- package/src/enums/WebitelApplications/SupervisorSections.d.ts +7 -0
- package/src/enums/WebitelApplications/WfmSections.d.ts +6 -0
- package/src/enums/WebitelApplications/WtApplication.d.ts +12 -0
- package/src/enums/WtObject/WtObject.d.ts +63 -0
- package/src/enums/WtTypeExtensionFieldKind/WtTypeExtensionFieldKind.d.ts +14 -0
- package/src/enums/index.d.ts +88 -0
- package/src/install.ts +2 -1
- package/src/mixins/validationMixin/regle/useRegleValidation.ts +4 -4
- package/src/mixins/validationMixin/useValidation.ts +8 -3
- package/src/mixins/validationMixin/vuelidate/useVuelidateValidation.ts +63 -40
- package/src/modules/CSVExport/composables/useCSVExport.ts +1 -1
- package/src/modules/CallSession/modules/ScreenSharing/screen-sharing.vue +1 -2
- package/src/modules/CallSession/modules/VideoCall/composables/useDocumentPiP/domTraversal.ts +2 -2
- package/src/modules/CallSession/modules/VideoCall/video-call.vue +1 -1
- package/src/modules/CallSession/types/index.ts +3 -3
- package/src/modules/UploadCsvPopup/composable/useUploadCsv.ts +1 -1
- package/src/modules/UploadCsvPopup/scripts/parseCSV.ts +1 -1
- package/src/modules/UserNotifications/maps/userNotificationConfigsMap.ts +10 -7
- package/src/modules/UserNotifications/stores/userNotificationsStore.ts +1 -0
- package/src/modules/UserNotifications/types/UserNotifications.ts +2 -1
- package/src/modules/Userinfo/constants/UserSettingsConstants.d.ts +1 -0
- package/src/scripts/__tests__/isEmpty.spec.js +1 -1
- package/src/scripts/downloadFile/types/downloadFile.types.ts +7 -1
- package/src/scripts/index.js +1 -1
- package/src/scripts/{isEmpty.js → isEmpty.ts} +10 -1
- package/src/scripts/normalizeDatetime.ts +4 -2
- package/src/utils/displayText.d.ts +2 -0
- package/src/utils/formatDate.d.ts +10 -0
- package/src/utils/index.d.ts +2 -0
- package/src/validations/config/errors/customZodErrorsHandler.ts +8 -4
- package/types/api/defaults/getDefaultInstance/getDefaultInstance.d.ts +1 -1
- package/types/components/_internals/composables/useSelect/useSelect.d.ts +2 -2
- package/types/components/_internals/composables/useSelect/useSelectCustomValues.d.ts +1 -4
- package/types/components/_internals/composables/useWtTable/useWtTable.d.ts +1 -0
- package/types/components/on-demand/wt-call-media-action/wt-call-media-action.vue.d.ts +2 -2
- package/types/components/on-demand/wt-selection-popup/wt-selection-popup.vue.d.ts +4 -4
- package/types/components/wt-action-bar/WtActionBarActionsOrder.d.ts +2 -2
- package/types/components/wt-action-bar/wt-action-bar.vue.d.ts +17 -17
- package/types/components/wt-badge-new/wt-badge.vue.d.ts +3 -2
- package/types/components/wt-button/wt-button.vue.d.ts +2 -1
- package/types/components/wt-datepicker/_internals/composables/useAutoSeparator.d.ts +17 -0
- package/types/components/wt-datepicker/_internals/composables/useDatepicker.d.ts +19 -0
- package/types/components/wt-datepicker/_internals/composables/usePreventZeroPad.d.ts +9 -5
- package/types/components/wt-datepicker/_internals/composables/useStrictInput.d.ts +17 -0
- package/types/components/wt-inline-add-panel/wt-inline-add-panel.vue.d.ts +3 -3
- package/types/components/wt-popup/wt-popup.vue.d.ts +2 -0
- package/types/components/wt-search-bar/wt-search-bar.vue.d.ts +2 -2
- package/types/components/wt-status-select/wt-status-select.vue.d.ts +2 -2
- package/types/components/wt-tree-table/wt-tree-table.vue.d.ts +1 -1
- package/types/composables/index.d.ts +1 -0
- package/types/composables/useEventBus/useEventBus.d.ts +11 -0
- package/types/mixins/validationMixin/regle/useRegleValidation.d.ts +2 -2
- package/types/mixins/validationMixin/useValidation.d.ts +9 -4
- package/types/mixins/validationMixin/validationMixin.d.ts +1 -1
- package/types/mixins/validationMixin/vuelidate/useVuelidateValidation.d.ts +14 -9
- package/types/modules/AgentPdfs/components/agent-pdfs-tab.vue.d.ts +4 -1
- package/types/modules/AgentStatusSelect/components/_internals/wt-cc-pause-cause-popup.vue.d.ts +2 -2
- package/types/modules/CallSession/types/index.d.ts +3 -3
- package/types/modules/TableComponentModule/composables/useTableEmpty.d.ts +1 -1
- package/types/modules/UploadCsvPopup/composable/useUploadCsv.d.ts +1 -1
- package/types/modules/UploadCsvPopup/scripts/parseCSV.d.ts +1 -1
- package/types/modules/UserNotifications/maps/userNotificationConfigsMap.d.ts +2 -2
- package/types/modules/UserNotifications/types/UserNotifications.d.ts +2 -1
- package/types/scripts/caseConverters.d.ts +1 -1
- package/types/scripts/downloadFile/types/downloadFile.types.d.ts +6 -1
- package/types/scripts/index.d.ts +1 -1
- package/types/scripts/isEmpty.d.ts +2 -1
- package/types/scripts/normalizeDatetime.d.ts +1 -1
- package/types/validations/config/errors/customZodErrorsHandler.d.ts +1 -1
- package/dist/useValidation-BedhHNX5.js +0 -37
- package/dist/vidstack-video-iy3-Vo1A.js +0 -2
- package/types/install.d.ts +0 -15
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents existing Webitel entities
|
|
3
|
+
*/
|
|
4
|
+
export declare const WtObject: {
|
|
5
|
+
readonly Agent: 'agent';
|
|
6
|
+
readonly Queue: 'queue';
|
|
7
|
+
readonly Contact: 'contact';
|
|
8
|
+
readonly Region: 'region';
|
|
9
|
+
readonly User: 'user';
|
|
10
|
+
readonly Resource: 'resource';
|
|
11
|
+
readonly Device: 'device';
|
|
12
|
+
readonly License: 'license';
|
|
13
|
+
readonly Flow: 'flow';
|
|
14
|
+
readonly Dialplan: 'dialplan';
|
|
15
|
+
readonly Gateway: 'gateway';
|
|
16
|
+
readonly Chatplan: 'chatplan';
|
|
17
|
+
readonly ChatGateway: 'chatGateway';
|
|
18
|
+
readonly Blacklist: 'blacklist';
|
|
19
|
+
readonly Calendar: 'calendar';
|
|
20
|
+
readonly Communication: 'communication';
|
|
21
|
+
readonly PauseCause: 'pauseCause';
|
|
22
|
+
readonly Media: 'media';
|
|
23
|
+
readonly ShiftTemplate: 'shiftTemplate';
|
|
24
|
+
readonly PauseTemplate: 'pauseTemplate';
|
|
25
|
+
readonly WorkingCondition: 'workingCondition';
|
|
26
|
+
readonly Skill: 'skill';
|
|
27
|
+
readonly Bucket: 'bucket';
|
|
28
|
+
readonly Member: 'member';
|
|
29
|
+
readonly ResourceGroup: 'resourceGroup';
|
|
30
|
+
readonly Team: 'team';
|
|
31
|
+
readonly Storage: 'storage';
|
|
32
|
+
readonly CognitiveProfile: 'cognitiveProfile';
|
|
33
|
+
readonly EmailProfile: 'emailProfile';
|
|
34
|
+
readonly SingleSignOn: 'singleSignOn';
|
|
35
|
+
readonly ImportCsv: 'importCsv';
|
|
36
|
+
readonly Trigger: 'trigger';
|
|
37
|
+
readonly Role: 'role';
|
|
38
|
+
readonly Object: 'object';
|
|
39
|
+
readonly ChangeLog: 'changelog';
|
|
40
|
+
readonly Configuration: 'configuration';
|
|
41
|
+
readonly GlobalVariable: 'globalVariable';
|
|
42
|
+
readonly Call: 'call';
|
|
43
|
+
readonly RecordFile: 'recordFile';
|
|
44
|
+
readonly ContactGroup: 'contactGroup';
|
|
45
|
+
readonly Case: 'case';
|
|
46
|
+
readonly CaseComment: 'caseComment';
|
|
47
|
+
readonly Slas: 'slas';
|
|
48
|
+
readonly ServiceCatalog: 'serviceCatalog';
|
|
49
|
+
readonly CaseSource: 'caseSource';
|
|
50
|
+
readonly CloseReasonGroup: 'closeReasonGroup';
|
|
51
|
+
readonly Priorities: 'priorities';
|
|
52
|
+
readonly Status: 'status';
|
|
53
|
+
readonly Source: 'source';
|
|
54
|
+
readonly CustomLookup: 'customLookup';
|
|
55
|
+
readonly AuditForm: 'auditForm';
|
|
56
|
+
readonly AuditRating: 'auditRating';
|
|
57
|
+
readonly QuickReply: 'quickReply';
|
|
58
|
+
readonly ListNumber: 'listNumber';
|
|
59
|
+
readonly AgentWorkingCondition: 'agentWorkingCondition';
|
|
60
|
+
readonly FilePolicy: 'filePolicy';
|
|
61
|
+
readonly PortalUser: 'portalUser';
|
|
62
|
+
};
|
|
63
|
+
export type WtObject = (typeof WtObject)[keyof typeof WtObject];
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @name FieldType
|
|
3
|
+
* @description Enumerates (ONLY!) the types of field type.
|
|
4
|
+
*/
|
|
5
|
+
export declare const WtTypeExtensionFieldKind: {
|
|
6
|
+
readonly Text: 'string';
|
|
7
|
+
readonly Number: 'int32';
|
|
8
|
+
readonly Select: 'lookup';
|
|
9
|
+
readonly Multiselect: 'list';
|
|
10
|
+
readonly Calendar: 'datetime';
|
|
11
|
+
readonly Boolean: 'bool';
|
|
12
|
+
};
|
|
13
|
+
export type ExtensionFieldType =
|
|
14
|
+
(typeof WtTypeExtensionFieldKind)[keyof typeof WtTypeExtensionFieldKind];
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import AbstractUserStatus from './AbstractUserStatus/AbstractUserStatus.enum.js';
|
|
2
|
+
import AgentStatus from './AgentStatus/AgentStatus.enum.js';
|
|
3
|
+
import { BroadcastChannelName } from './BroadcastChannelName/BroadcastChannelName';
|
|
4
|
+
import type {
|
|
5
|
+
UserSettingsBroadcastMessage,
|
|
6
|
+
WebphoneBroadcastMessage,
|
|
7
|
+
WebphoneBroadcastPayload,
|
|
8
|
+
} from './BroadcastChannelName/UserSettingsBroadcastMessage';
|
|
9
|
+
import { ButtonColor } from './ButtonColor/ButtonColor';
|
|
10
|
+
import { ButtonVariant } from './ButtonVariant/ButtonVariant';
|
|
11
|
+
import ChatGatewayProvider from './ChatGatewayProvider/ChatGatewayProvider.enum.js';
|
|
12
|
+
import ProviderIconType from './ChatGatewayProvider/ProviderIconType.enum';
|
|
13
|
+
import { ChipColor } from './ChipColor/ChipColor';
|
|
14
|
+
import { ComponentSize } from './ComponentSize/ComponentSize';
|
|
15
|
+
import {
|
|
16
|
+
ConnectionQualityLevels,
|
|
17
|
+
type ConnectionQualityLevelsType,
|
|
18
|
+
} from './ConnectionQualityLevel/ConnectionQualityLevel.enum';
|
|
19
|
+
import { CrudAction } from './CrudAction/CrudAction';
|
|
20
|
+
import { DefaultWorkspaceTabSettings } from './DefaultWorkspaceTabSettings/DefaultWorkspaceTabSettings';
|
|
21
|
+
import { EmptyCause } from './EmptyCause/EmptyCause';
|
|
22
|
+
import { FormatDateMode } from './FormatDateMode/FormatDateMode';
|
|
23
|
+
import IconAction from './IconAction/IconAction.enum.js';
|
|
24
|
+
import { IconColor } from './IconColor/IconColor';
|
|
25
|
+
import { LoginOptions } from './LoginOptions/LoginOptions';
|
|
26
|
+
import { MessageColor } from './MessageColor/MessageColor';
|
|
27
|
+
import { MessageVariant } from './MessageVariant/MessageVariant';
|
|
28
|
+
import { MimeTypes } from './MimeTypes/MimeTypes.enum';
|
|
29
|
+
import { ProcessingTableColumnType } from './ProcessingTableColumnType/ProcessingTableColumnType';
|
|
30
|
+
import { QueueType, QueueTypeName } from './QueueType/QueueType.enum';
|
|
31
|
+
import { RelativeDatetimeValue } from './RelativeDatetimeValue/RelativeDatetimeValue';
|
|
32
|
+
import { RingtoneType } from './RingtoneType/RingtoneType.js';
|
|
33
|
+
import { SingleSignOnProvider } from './SingleSignOnProvider/SingleSignOnProvider';
|
|
34
|
+
import { SingleSignOnProviderIconMappings } from './SingleSignOnProviderIconMappings/SingleSignOnProviderIconMappings';
|
|
35
|
+
import TypesExportedSettings from './TypesExportedSettings/TypesExportedSettings.enum.js';
|
|
36
|
+
import { AdminSections } from './WebitelApplications/AdminSections';
|
|
37
|
+
import { AuditorSections } from './WebitelApplications/AuditorSections';
|
|
38
|
+
import { CrmSections } from './WebitelApplications/CrmSections';
|
|
39
|
+
import { SupervisorSections } from './WebitelApplications/SupervisorSections';
|
|
40
|
+
import { WfmSections } from './WebitelApplications/WfmSections';
|
|
41
|
+
import { WtApplication } from './WebitelApplications/WtApplication';
|
|
42
|
+
import { WtObject } from './WtObject/WtObject';
|
|
43
|
+
import { WtTypeExtensionFieldKind } from './WtTypeExtensionFieldKind/WtTypeExtensionFieldKind';
|
|
44
|
+
|
|
45
|
+
export type {
|
|
46
|
+
ConnectionQualityLevelsType,
|
|
47
|
+
UserSettingsBroadcastMessage,
|
|
48
|
+
WebphoneBroadcastMessage,
|
|
49
|
+
WebphoneBroadcastPayload,
|
|
50
|
+
};
|
|
51
|
+
export {
|
|
52
|
+
AbstractUserStatus,
|
|
53
|
+
AdminSections,
|
|
54
|
+
AgentStatus,
|
|
55
|
+
AuditorSections,
|
|
56
|
+
BroadcastChannelName,
|
|
57
|
+
ButtonColor,
|
|
58
|
+
ButtonVariant,
|
|
59
|
+
ChatGatewayProvider,
|
|
60
|
+
ChipColor,
|
|
61
|
+
ComponentSize,
|
|
62
|
+
ConnectionQualityLevels,
|
|
63
|
+
CrmSections,
|
|
64
|
+
CrudAction,
|
|
65
|
+
DefaultWorkspaceTabSettings,
|
|
66
|
+
EmptyCause,
|
|
67
|
+
FormatDateMode,
|
|
68
|
+
IconAction,
|
|
69
|
+
IconColor,
|
|
70
|
+
LoginOptions,
|
|
71
|
+
MessageColor,
|
|
72
|
+
MessageVariant,
|
|
73
|
+
MimeTypes,
|
|
74
|
+
ProcessingTableColumnType,
|
|
75
|
+
ProviderIconType,
|
|
76
|
+
QueueType,
|
|
77
|
+
QueueTypeName,
|
|
78
|
+
RelativeDatetimeValue,
|
|
79
|
+
RingtoneType,
|
|
80
|
+
SingleSignOnProvider,
|
|
81
|
+
SingleSignOnProviderIconMappings,
|
|
82
|
+
SupervisorSections,
|
|
83
|
+
TypesExportedSettings,
|
|
84
|
+
WfmSections,
|
|
85
|
+
WtApplication,
|
|
86
|
+
WtObject,
|
|
87
|
+
WtTypeExtensionFieldKind,
|
|
88
|
+
};
|
package/src/install.ts
CHANGED
|
@@ -7,6 +7,7 @@ import './css/tailwind.css';
|
|
|
7
7
|
import { generateInstance } from '@webitel/api-services/api/axios';
|
|
8
8
|
import { fillIconsRepository } from './assets/icons';
|
|
9
9
|
import Components from './components'; // init all components
|
|
10
|
+
import { EVENT_BUS_INJECTION_KEY } from './composables/useEventBus/useEventBus';
|
|
10
11
|
import Directives from './directives'; // init all directives
|
|
11
12
|
import initPrimevue from './plugins/primevue/primevue.plugin';
|
|
12
13
|
|
|
@@ -23,7 +24,7 @@ export default {
|
|
|
23
24
|
Object.keys(globals).forEach((globalKey) => {
|
|
24
25
|
app.provide(globalKey, globals[globalKey]);
|
|
25
26
|
});
|
|
26
|
-
app.provide(
|
|
27
|
+
app.provide(EVENT_BUS_INJECTION_KEY, eventBus);
|
|
27
28
|
initPrimevue(app);
|
|
28
29
|
},
|
|
29
30
|
generateInstance,
|
|
@@ -2,23 +2,23 @@ import type { RegleFieldStatus } from '@regle/core';
|
|
|
2
2
|
import { type ComputedRef, computed, type Ref } from 'vue';
|
|
3
3
|
|
|
4
4
|
export type UseFieldValidationParams = {
|
|
5
|
-
field
|
|
5
|
+
field?: Ref<RegleFieldStatus<string>>;
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
export type UseFieldValidationReturn = {
|
|
9
9
|
invalid: ComputedRef<boolean | null>; // null if is not validated
|
|
10
|
-
validationText?: ComputedRef<string>;
|
|
10
|
+
validationText?: ComputedRef<string | undefined>;
|
|
11
11
|
};
|
|
12
12
|
|
|
13
13
|
export const useFieldValidation = ({
|
|
14
14
|
field: fieldRef,
|
|
15
15
|
}: UseFieldValidationParams): UseFieldValidationReturn => {
|
|
16
16
|
const invalid = computed(() => {
|
|
17
|
-
return fieldRef
|
|
17
|
+
return fieldRef?.value.$error ?? null;
|
|
18
18
|
});
|
|
19
19
|
|
|
20
20
|
const validationText = computed(() => {
|
|
21
|
-
return fieldRef
|
|
21
|
+
return fieldRef?.value?.$errors?.at(0);
|
|
22
22
|
});
|
|
23
23
|
|
|
24
24
|
return {
|
|
@@ -10,15 +10,20 @@ import {
|
|
|
10
10
|
useFieldValidation as useVuelidateValidation,
|
|
11
11
|
} from './vuelidate/useVuelidateValidation';
|
|
12
12
|
|
|
13
|
-
type
|
|
14
|
-
|
|
13
|
+
type UseValidationParams = {
|
|
14
|
+
/** vuelidate field validation (compat) */
|
|
15
|
+
v?: UseVuelidateFieldValidationParams['field'];
|
|
16
|
+
/** vuelidate custom validations (compat) */
|
|
17
|
+
customValidators?: UseVuelidateFieldValidationParams['customValidators'];
|
|
18
|
+
/** regle field validation */
|
|
19
|
+
regleValidation?: UseRegleFieldValidationParams['field'];
|
|
15
20
|
};
|
|
16
21
|
|
|
17
22
|
export const useValidation = ({
|
|
18
23
|
v: vuelidateValidation,
|
|
19
24
|
customValidators: inputCustomValidators, // vuelidate custom validations, compat
|
|
20
25
|
regleValidation,
|
|
21
|
-
}:
|
|
26
|
+
}: UseValidationParams) => {
|
|
22
27
|
const {
|
|
23
28
|
isValidation: isVuelidateValidation,
|
|
24
29
|
invalid: vuelidateInvalid,
|
|
@@ -1,10 +1,22 @@
|
|
|
1
1
|
import type { Validation } from '@vuelidate/core';
|
|
2
|
-
import {
|
|
2
|
+
import {
|
|
3
|
+
type ComputedRef,
|
|
4
|
+
computed,
|
|
5
|
+
isReactive,
|
|
6
|
+
isRef,
|
|
7
|
+
type Ref,
|
|
8
|
+
unref,
|
|
9
|
+
} from 'vue';
|
|
3
10
|
import { useI18n } from 'vue-i18n';
|
|
4
11
|
|
|
12
|
+
type CompatCustomValidator = {
|
|
13
|
+
name: string;
|
|
14
|
+
text: string;
|
|
15
|
+
};
|
|
16
|
+
|
|
5
17
|
export type UseFieldValidationParams = {
|
|
6
|
-
field
|
|
7
|
-
customValidators?:
|
|
18
|
+
field?: Ref<Validation>;
|
|
19
|
+
customValidators?: CompatCustomValidator[];
|
|
8
20
|
};
|
|
9
21
|
|
|
10
22
|
export const useFieldValidation = ({
|
|
@@ -14,11 +26,15 @@ export const useFieldValidation = ({
|
|
|
14
26
|
const { t } = useI18n();
|
|
15
27
|
|
|
16
28
|
// support vue options api, where v is a reactive, not ref
|
|
17
|
-
let v =
|
|
18
|
-
|
|
29
|
+
let v: Ref<Validation> | ComputedRef<Validation | undefined> | undefined =
|
|
30
|
+
inputV;
|
|
31
|
+
let customValidators:
|
|
32
|
+
| CompatCustomValidator[]
|
|
33
|
+
| ComputedRef<CompatCustomValidator[] | undefined>
|
|
34
|
+
| undefined = inputCustomValidators;
|
|
19
35
|
|
|
20
|
-
if (isReactive(
|
|
21
|
-
v = computed(() => inputV);
|
|
36
|
+
if (isReactive(inputV)) {
|
|
37
|
+
v = computed(() => unref(inputV));
|
|
22
38
|
customValidators = computed(() => inputCustomValidators);
|
|
23
39
|
}
|
|
24
40
|
// end
|
|
@@ -26,66 +42,73 @@ export const useFieldValidation = ({
|
|
|
26
42
|
const isValidation = computed(
|
|
27
43
|
() => !!v && !!v.value && !!Object.keys(v.value).length,
|
|
28
44
|
);
|
|
29
|
-
const invalid = computed(() => isValidation.value && v
|
|
45
|
+
const invalid = computed(() => isValidation.value && v?.value?.$error);
|
|
30
46
|
|
|
31
47
|
const validationText = computed(() => {
|
|
32
48
|
let validationText = '';
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
49
|
+
const validation = v?.value;
|
|
50
|
+
if (validation && isValidation.value && invalid.value) {
|
|
51
|
+
if (validation.required?.$invalid)
|
|
52
|
+
validationText = t('validation.required');
|
|
53
|
+
else if (validation.numeric?.$invalid)
|
|
36
54
|
validationText = t('validation.numeric');
|
|
37
|
-
else if (
|
|
38
|
-
|
|
55
|
+
else if (validation.email?.$invalid)
|
|
56
|
+
validationText = t('validation.email');
|
|
57
|
+
else if (validation.gatewayHostValidator?.$invalid)
|
|
39
58
|
validationText = t('validation.gatewayHostValidator');
|
|
40
|
-
else if (
|
|
59
|
+
else if (validation.ipValidator?.$invalid)
|
|
41
60
|
validationText = t('validation.ipValidator');
|
|
42
|
-
else if (
|
|
61
|
+
else if (validation.macValidator?.$invalid)
|
|
43
62
|
validationText = t('validation.macValidator');
|
|
44
|
-
else if (
|
|
63
|
+
else if (validation.minValue?.$invalid)
|
|
45
64
|
validationText = t('validation.minValue', {
|
|
46
|
-
min:
|
|
65
|
+
min: validation.minValue.$params.min,
|
|
47
66
|
});
|
|
48
|
-
else if (
|
|
67
|
+
else if (validation.maxValue?.$invalid)
|
|
49
68
|
validationText = t('validation.maxValue', {
|
|
50
|
-
max:
|
|
69
|
+
max: validation.maxValue.$params.max,
|
|
51
70
|
});
|
|
52
|
-
else if (
|
|
71
|
+
else if (validation.maxLength?.$invalid)
|
|
53
72
|
validationText = t('validation.maxLength', {
|
|
54
|
-
max:
|
|
73
|
+
max: validation.maxLength.$params.max,
|
|
55
74
|
});
|
|
56
|
-
else if (
|
|
75
|
+
else if (validation.sipAccountValidator?.$invalid)
|
|
57
76
|
validationText = t('validation.sipAccountValidator');
|
|
58
|
-
else if (
|
|
77
|
+
else if (validation.minLength?.$invalid)
|
|
59
78
|
validationText = t('validation.minLength', {
|
|
60
|
-
min:
|
|
79
|
+
min: validation.minLength.$params.min,
|
|
61
80
|
});
|
|
62
|
-
else if (
|
|
63
|
-
|
|
81
|
+
else if (validation.url?.$invalid)
|
|
82
|
+
validationText = `${t('validation.url')}`;
|
|
83
|
+
else if (validation.regExpValidator?.$invalid)
|
|
64
84
|
validationText = `${t('validation.regExpValidator')}`;
|
|
65
|
-
else if (
|
|
85
|
+
else if (validation.sameAs?.$invalid)
|
|
66
86
|
validationText = `${t('validation.sameAs')}`;
|
|
67
|
-
else if (
|
|
87
|
+
else if (validation.domainValidator?.$invalid)
|
|
68
88
|
validationText = `${t('validation.domainValidator')}`;
|
|
69
|
-
else if (
|
|
70
|
-
validationText = `${t('validation.decimalValidator')} ${
|
|
71
|
-
else if (
|
|
89
|
+
else if (validation.decimalValidator?.$invalid)
|
|
90
|
+
validationText = `${t('validation.decimalValidator')} ${validation.decimalValidator.$params.count}`;
|
|
91
|
+
else if (validation.websocketValidator?.$invalid)
|
|
72
92
|
validationText = `${t('validation.websocketValidator')}`;
|
|
73
|
-
else if (
|
|
93
|
+
else if (validation.integer?.$invalid)
|
|
74
94
|
validationText = `${t('validation.integer')}`;
|
|
75
|
-
else if (
|
|
95
|
+
else if (validation.regex?.$invalid)
|
|
76
96
|
validationText =
|
|
77
|
-
|
|
78
|
-
`${t('validation.isRegExpMatched')} ${
|
|
79
|
-
else if (
|
|
97
|
+
validation.regex?.$message ||
|
|
98
|
+
`${t('validation.isRegExpMatched')} ${validation.regex?.$params?.regex}`;
|
|
99
|
+
else if (validation.nameAlreadyInUse?.$invalid) {
|
|
80
100
|
validationText = t('validation.nameAlreadyInUse');
|
|
81
|
-
} else if (
|
|
101
|
+
} else if (validation.phoneNumberSymbolsValidator?.$invalid) {
|
|
82
102
|
validationText = t('validation.phoneNumberSymbolsValidator');
|
|
83
103
|
}
|
|
84
104
|
}
|
|
85
105
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
106
|
+
const resolvedCustomValidators = isRef(customValidators)
|
|
107
|
+
? customValidators.value
|
|
108
|
+
: undefined;
|
|
109
|
+
if (resolvedCustomValidators) {
|
|
110
|
+
for (const { name, text } of resolvedCustomValidators) {
|
|
111
|
+
if (validation?.[name]?.$invalid) validationText = text;
|
|
89
112
|
}
|
|
90
113
|
return validationText;
|
|
91
114
|
}
|
|
@@ -41,7 +41,7 @@ export function useCSVExport({ selected }: { selected: Ref<number[]> }) {
|
|
|
41
41
|
|
|
42
42
|
async function exportCSV(exportParams?: Record<string, unknown>) {
|
|
43
43
|
const routeQuery = route.query;
|
|
44
|
-
const params = {
|
|
44
|
+
const params: Record<string, unknown> = {
|
|
45
45
|
...(exportParams || routeQuery),
|
|
46
46
|
size: CSV_EXPORT_BATCH_SIZE,
|
|
47
47
|
};
|
package/src/modules/CallSession/modules/VideoCall/composables/useDocumentPiP/domTraversal.ts
CHANGED
|
@@ -5,12 +5,12 @@ export const domTraversal = (
|
|
|
5
5
|
if (root instanceof Element) {
|
|
6
6
|
visit(root);
|
|
7
7
|
if (root.shadowRoot) {
|
|
8
|
-
for (const child of root.shadowRoot.children) {
|
|
8
|
+
for (const child of Array.from(root.shadowRoot.children)) {
|
|
9
9
|
domTraversal(child, visit);
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
|
-
for (const child of root.children) {
|
|
13
|
+
for (const child of Array.from(root.children)) {
|
|
14
14
|
domTraversal(child, visit);
|
|
15
15
|
}
|
|
16
16
|
};
|
|
@@ -274,7 +274,7 @@ const emitKeys = {
|
|
|
274
274
|
[VideoCallAction.Settings]: `action:${VideoCallAction.Settings}`,
|
|
275
275
|
[VideoCallAction.Chat]: `action:${VideoCallAction.Chat}`,
|
|
276
276
|
[VideoCallAction.Hangup]: `action:${VideoCallAction.Hangup}`,
|
|
277
|
-
};
|
|
277
|
+
} as const;
|
|
278
278
|
|
|
279
279
|
const { t } = useI18n();
|
|
280
280
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ScreenSharingSession } from './ScreenSharingSession';
|
|
2
|
-
import { ScreenshotStatus } from './ScreenshotStatus';
|
|
1
|
+
import type { ScreenSharingSession } from './ScreenSharingSession';
|
|
2
|
+
import type { ScreenshotStatus } from './ScreenshotStatus';
|
|
3
3
|
|
|
4
|
-
export { ScreenSharingSession, ScreenshotStatus };
|
|
4
|
+
export type { ScreenSharingSession, ScreenshotStatus };
|
|
@@ -20,7 +20,7 @@ const useUploadCsv = ({ props, emit, skipHeaders, separator }) => {
|
|
|
20
20
|
const parsedFile = ref(null);
|
|
21
21
|
const isParsingPreview = ref(false);
|
|
22
22
|
const parseErrorStackTrace = ref('');
|
|
23
|
-
const csvPreview = ref([
|
|
23
|
+
const csvPreview = ref<unknown[]>([
|
|
24
24
|
[],
|
|
25
25
|
]);
|
|
26
26
|
|
|
@@ -1,21 +1,24 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
type ApiUserWarning,
|
|
3
|
+
ApiUserWarningId,
|
|
4
|
+
} from '@webitel/api-services/gen/models';
|
|
2
5
|
import type { NotificationsType } from '../types/UserNotifications';
|
|
3
6
|
|
|
4
7
|
const HOURS_IN_DAY = 24;
|
|
5
8
|
|
|
6
9
|
export const USER_NOTIFICATION_CONFIGS_MAP = new Map<
|
|
7
10
|
ApiUserWarningId,
|
|
8
|
-
(
|
|
11
|
+
(warning: ApiUserWarning) => NotificationsType
|
|
9
12
|
>([
|
|
10
13
|
[
|
|
11
14
|
ApiUserWarningId.PasswordExpiresSoon,
|
|
12
15
|
({ warningData: data }) => ({
|
|
13
16
|
type: 'info',
|
|
14
|
-
localeKey: data
|
|
17
|
+
localeKey: data?.passwordExpiry?.daysRemaining
|
|
15
18
|
? 'passwordExpirationMessageDays'
|
|
16
19
|
: 'passwordExpirationMessageHours',
|
|
17
20
|
params: {
|
|
18
|
-
amount: data
|
|
21
|
+
amount: data?.passwordExpiry?.daysRemaining || HOURS_IN_DAY,
|
|
19
22
|
},
|
|
20
23
|
}),
|
|
21
24
|
],
|
|
@@ -25,8 +28,8 @@ export const USER_NOTIFICATION_CONFIGS_MAP = new Map<
|
|
|
25
28
|
type: 'info',
|
|
26
29
|
localeKey: 'licenseExpirationSoonMessage',
|
|
27
30
|
params: {
|
|
28
|
-
amount: data
|
|
29
|
-
name: data
|
|
31
|
+
amount: data?.licenseExpiry?.daysRemaining,
|
|
32
|
+
name: data?.licenseExpiry?.licenseName,
|
|
30
33
|
},
|
|
31
34
|
}),
|
|
32
35
|
],
|
|
@@ -36,7 +39,7 @@ export const USER_NOTIFICATION_CONFIGS_MAP = new Map<
|
|
|
36
39
|
type: 'info',
|
|
37
40
|
localeKey: 'licenseExpirationMessage',
|
|
38
41
|
params: {
|
|
39
|
-
name: data
|
|
42
|
+
name: data?.licenseExpiry?.licenseName,
|
|
40
43
|
},
|
|
41
44
|
}),
|
|
42
45
|
],
|
|
@@ -59,6 +59,7 @@ export const createUserNotificationsStore = () => {
|
|
|
59
59
|
const mapNotifications = (array: ApiUserWarning[]) => {
|
|
60
60
|
return array
|
|
61
61
|
.map((warning) => {
|
|
62
|
+
if (!warning.id) return null;
|
|
62
63
|
const map = USER_NOTIFICATION_CONFIGS_MAP.get(warning.id);
|
|
63
64
|
if (!map) return null;
|
|
64
65
|
return map(warning);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const TIMEZONE_STORAGE_KEY = 'user-timezone-setting';
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
import type { FileFormat } from './fileFormat.types';
|
|
2
2
|
|
|
3
|
+
/** Minimal shape of the (axios-style) HTTP response consumed by `downloadFile`. */
|
|
4
|
+
export interface DownloadFileResponse {
|
|
5
|
+
data: BlobPart;
|
|
6
|
+
headers?: Record<string, string | undefined>;
|
|
7
|
+
}
|
|
8
|
+
|
|
3
9
|
export interface DownloadFileOptions {
|
|
4
|
-
response:
|
|
10
|
+
response: DownloadFileResponse;
|
|
5
11
|
fileFormat: FileFormat;
|
|
6
12
|
filename?: string;
|
|
7
13
|
mimetype?: string;
|
package/src/scripts/index.js
CHANGED
|
@@ -22,7 +22,7 @@ import downloadFile from './downloadFile/downloadFile';
|
|
|
22
22
|
import eventBus from './eventBus.js';
|
|
23
23
|
import { getConnectionQuality } from './getConnectionQuality.ts';
|
|
24
24
|
import { getEndOfDay, getStartOfDay } from './getDefaultFilterDate.js';
|
|
25
|
-
import isEmpty from './isEmpty
|
|
25
|
+
import isEmpty from './isEmpty';
|
|
26
26
|
import { wtlog } from './logger.js';
|
|
27
27
|
import {
|
|
28
28
|
isRelativeDatetimeValue,
|
|
@@ -1,6 +1,15 @@
|
|
|
1
|
+
type EmptyValue =
|
|
2
|
+
| undefined
|
|
3
|
+
| null
|
|
4
|
+
| ''
|
|
5
|
+
| 0
|
|
6
|
+
| false
|
|
7
|
+
| never[]
|
|
8
|
+
| Record<PropertyKey, never>;
|
|
9
|
+
|
|
1
10
|
// checks if value is Falsy,
|
|
2
11
|
// including empty arrays or objects
|
|
3
|
-
const isEmpty = (value) => {
|
|
12
|
+
const isEmpty = <T>(value: T): value is Extract<T, EmptyValue> => {
|
|
4
13
|
if (Array.isArray(value)) return !value.length;
|
|
5
14
|
if (typeof value === 'object') return !value || !Object.keys(value).length;
|
|
6
15
|
return !value;
|
|
@@ -24,8 +24,10 @@ export type NormalizeDatetimeOptions = {
|
|
|
24
24
|
round?: RelativeDatetimeRoundOption;
|
|
25
25
|
};
|
|
26
26
|
|
|
27
|
-
export const isRelativeDatetimeValue = (
|
|
28
|
-
|
|
27
|
+
export const isRelativeDatetimeValue = (
|
|
28
|
+
value: string,
|
|
29
|
+
): value is RelativeDatetimeValue => {
|
|
30
|
+
return (Object.values(RelativeDatetimeValue) as string[]).includes(value);
|
|
29
31
|
};
|
|
30
32
|
|
|
31
33
|
const convertRelativeDatetimeToTimestamp = (
|