@webitel/ui-sdk 26.8.53 → 26.8.54

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webitel/ui-sdk",
3
- "version": "26.8.53",
3
+ "version": "26.8.54",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "dev": "npm run docs:dev",
@@ -7,12 +7,16 @@ import newChatSound from '../assets/audio/chat-new.wav';
7
7
  import newMessageSound from '../assets/audio/chat-new-message.wav';
8
8
  import endCallSound from '../assets/audio/end-call.wav';
9
9
  import ringingSound from '../assets/audio/ringing.mp3';
10
+ import selfAssignedCallSound from '../assets/audio/self-assigned-call.wav';
10
11
  import endTask from '../assets/audio/task-end.wav';
11
12
  import newTask from '../assets/audio/task-new.wav';
12
13
  import notificationIcon from '../assets/img/notification-icon.png';
13
14
 
14
15
  const NOTIFICATION_VISIBLE_INTERVAL = 2000;
15
16
 
17
+ // no CallActions member represents this - it is a client-only notification, not a CTI transport event
18
+ export const SELF_ASSIGNED_CALL_ACTION = 'self_assigned_call';
19
+
16
20
  const getNotificationSound = (action) => {
17
21
  switch (action) {
18
22
  case JobState.Distribute:
@@ -31,6 +35,8 @@ const getNotificationSound = (action) => {
31
35
  return new Audio(ringingSound);
32
36
  case CallActions.Hangup:
33
37
  return new Audio(endCallSound);
38
+ case SELF_ASSIGNED_CALL_ACTION:
39
+ return new Audio(selfAssignedCallSound);
34
40
  default:
35
41
  return false;
36
42
  }