@webitel/ui-sdk 25.8.40 → 25.8.42
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/package.json +2 -2
- package/src/locale/kz/kz.js +556 -301
- package/src/modules/AgentStatusSelect/components/_internals/wt-cc-pause-cause-popup.vue +2 -0
- package/src/modules/Notifications/assets/audio/chat-end.wav +0 -0
- package/src/modules/Notifications/assets/audio/chat-new-message.wav +0 -0
- package/src/modules/Notifications/assets/audio/chat-new.wav +0 -0
- package/src/modules/Notifications/assets/audio/end-call.wav +0 -0
- package/src/modules/Notifications/assets/audio/task-end.wav +0 -0
- package/src/modules/Notifications/assets/audio/task-new.wav +0 -0
- package/src/modules/Notifications/store/NotificationsStoreModule.js +15 -9
- package/src/modules/QueryFilters/mixins/enumFilterMixin.js +2 -4
- package/types/locale/i18n.d.ts +676 -289
- package/types/locale/index.d.ts +676 -289
- package/types/locale/kz/kz.d.ts +762 -331
- package/types/modules/Notifications/store/NotificationsStoreModule.d.ts +1 -7
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,30 +1,36 @@
|
|
|
1
|
-
import { CallActions, ChatActions, JobState } from 'webitel-sdk';
|
|
1
|
+
import { CallActions, ChannelState, ChatActions, JobState } from 'webitel-sdk';
|
|
2
2
|
|
|
3
3
|
import i18n from '../../../locale/i18n.js';
|
|
4
4
|
import BaseStoreModule from '../../../store/BaseStoreModules/BaseStoreModule.js';
|
|
5
|
-
import endChatSound from '../assets/audio/end
|
|
6
|
-
import newChatSound from '../assets/audio/new
|
|
7
|
-
import newMessageSound from '../assets/audio/new-message.wav';
|
|
5
|
+
import endChatSound from '../assets/audio/chat-end.wav';
|
|
6
|
+
import newChatSound from '../assets/audio/chat-new.wav';
|
|
7
|
+
import newMessageSound from '../assets/audio/chat-new-message.wav';
|
|
8
|
+
import endCallSound from '../assets/audio/end-call.wav';
|
|
8
9
|
import ringingSound from '../assets/audio/ringing.mp3';
|
|
9
|
-
import
|
|
10
|
+
import endTask from '../assets/audio/task-end.wav';
|
|
11
|
+
import newTask from '../assets/audio/task-new.wav';
|
|
10
12
|
import notificationIcon from '../assets/img/notification-icon.png';
|
|
11
13
|
|
|
12
14
|
const NOTIFICATION_VISIBLE_INTERVAL = 2000;
|
|
13
15
|
|
|
14
16
|
const getNotificationSound = (action) => {
|
|
15
17
|
switch (action) {
|
|
16
|
-
case ChatActions.UserInvite:
|
|
17
18
|
case JobState.Distribute:
|
|
18
|
-
return new Audio(
|
|
19
|
+
return new Audio(newTask);
|
|
20
|
+
case JobState.Closed:
|
|
21
|
+
case ChannelState.WrapTime:
|
|
22
|
+
return new Audio(endTask);
|
|
19
23
|
case ChatActions.Message:
|
|
20
24
|
return new Audio(newMessageSound);
|
|
25
|
+
case ChatActions.UserInvite:
|
|
26
|
+
return new Audio(newChatSound);
|
|
21
27
|
case ChatActions.Close:
|
|
22
28
|
return new Audio(endChatSound);
|
|
23
29
|
case CallActions.Ringing:
|
|
24
30
|
// default call ringtone sound
|
|
25
31
|
return new Audio(ringingSound);
|
|
26
32
|
case CallActions.Hangup:
|
|
27
|
-
return
|
|
33
|
+
return new Audio(endCallSound);
|
|
28
34
|
default:
|
|
29
35
|
return false;
|
|
30
36
|
}
|
|
@@ -161,7 +167,7 @@ export default class NotificationsStoreModule extends BaseStoreModule {
|
|
|
161
167
|
interval = NOTIFICATION_VISIBLE_INTERVAL,
|
|
162
168
|
},
|
|
163
169
|
) => {
|
|
164
|
-
const notification = new Notification(text, { icon });
|
|
170
|
+
const notification = new Notification(text, { icon, silent: true });
|
|
165
171
|
|
|
166
172
|
notification.addEventListener(
|
|
167
173
|
'click',
|
|
@@ -26,9 +26,7 @@ export default {
|
|
|
26
26
|
return this.filterSchema?.storedProp;
|
|
27
27
|
},
|
|
28
28
|
label() {
|
|
29
|
-
return
|
|
30
|
-
? this.$tc(...this.locale.label)
|
|
31
|
-
: this.$t(this.locale.label);
|
|
29
|
+
return this.$t(this.locale.label);
|
|
32
30
|
},
|
|
33
31
|
localizedOptions() {
|
|
34
32
|
const optsHaveLocale = this.options.length && this.options[0].locale; // just check 1st el
|
|
@@ -36,7 +34,7 @@ export default {
|
|
|
36
34
|
return this.options.map((opt) => ({
|
|
37
35
|
...opt,
|
|
38
36
|
name: Array.isArray(opt.locale)
|
|
39
|
-
? this.$
|
|
37
|
+
? this.$t(...opt.locale)
|
|
40
38
|
: this.$t(opt.locale),
|
|
41
39
|
}));
|
|
42
40
|
}
|