@azure/communication-react 1.5.1-alpha-202302230015 → 1.5.1-beta.1

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 (93) hide show
  1. package/CHANGELOG.beta.md +86 -1
  2. package/CHANGELOG.json +686 -0
  3. package/dist/communication-react.d.ts +1 -32
  4. package/dist/dist-cjs/communication-react/index.js +174 -375
  5. package/dist/dist-cjs/communication-react/index.js.map +1 -1
  6. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
  7. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
  8. package/dist/dist-esm/calling-stateful-client/src/CallClientState.d.ts +1 -22
  9. package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
  10. package/dist/dist-esm/calling-stateful-client/src/CallContext.d.ts +0 -14
  11. package/dist/dist-esm/calling-stateful-client/src/CallContext.js +0 -44
  12. package/dist/dist-esm/calling-stateful-client/src/CallContext.js.map +1 -1
  13. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.d.ts +0 -1
  14. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js +0 -21
  15. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js.map +1 -1
  16. package/dist/dist-esm/calling-stateful-client/src/Converter.js +0 -1
  17. package/dist/dist-esm/calling-stateful-client/src/Converter.js.map +1 -1
  18. package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.d.ts +1 -13
  19. package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js +1 -8
  20. package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js.map +1 -1
  21. package/dist/dist-esm/calling-stateful-client/src/InternalCallContext.d.ts +0 -4
  22. package/dist/dist-esm/calling-stateful-client/src/InternalCallContext.js +0 -28
  23. package/dist/dist-esm/calling-stateful-client/src/InternalCallContext.js.map +1 -1
  24. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js +1 -1
  25. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js.map +1 -1
  26. package/dist/dist-esm/calling-stateful-client/src/StreamUtils.js +30 -50
  27. package/dist/dist-esm/calling-stateful-client/src/StreamUtils.js.map +1 -1
  28. package/dist/dist-esm/calling-stateful-client/src/index-public.d.ts +0 -1
  29. package/dist/dist-esm/calling-stateful-client/src/index-public.js.map +1 -1
  30. package/dist/dist-esm/react-components/src/components/ControlBarButton.js +1 -1
  31. package/dist/dist-esm/react-components/src/components/ControlBarButton.js.map +1 -1
  32. package/dist/dist-esm/react-components/src/components/RemoteVideoTile.js +1 -1
  33. package/dist/dist-esm/react-components/src/components/RemoteVideoTile.js.map +1 -1
  34. package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideoLayout.js +3 -3
  35. package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideoLayout.js.map +1 -1
  36. package/dist/dist-esm/react-components/src/components/VideoGallery.js +0 -13
  37. package/dist/dist-esm/react-components/src/components/VideoGallery.js.map +1 -1
  38. package/dist/dist-esm/react-components/src/components/VideoTile.js +12 -9
  39. package/dist/dist-esm/react-components/src/components/VideoTile.js.map +1 -1
  40. package/dist/dist-esm/react-components/src/localization/locales/de-DE/strings.json +103 -9
  41. package/dist/dist-esm/react-components/src/localization/locales/en-GB/strings.json +102 -8
  42. package/dist/dist-esm/react-components/src/localization/locales/es-ES/strings.json +102 -8
  43. package/dist/dist-esm/react-components/src/localization/locales/fr-FR/strings.json +103 -9
  44. package/dist/dist-esm/react-components/src/localization/locales/it-IT/strings.json +102 -8
  45. package/dist/dist-esm/react-components/src/localization/locales/ja-JP/strings.json +102 -8
  46. package/dist/dist-esm/react-components/src/localization/locales/ko-KR/strings.json +102 -8
  47. package/dist/dist-esm/react-components/src/localization/locales/nl-NL/strings.json +102 -8
  48. package/dist/dist-esm/react-components/src/localization/locales/pt-BR/strings.json +103 -9
  49. package/dist/dist-esm/react-components/src/localization/locales/ru-RU/strings.json +102 -8
  50. package/dist/dist-esm/react-components/src/localization/locales/tr-TR/strings.json +103 -9
  51. package/dist/dist-esm/react-components/src/localization/locales/zh-CN/strings.json +102 -8
  52. package/dist/dist-esm/react-components/src/localization/locales/zh-TW/strings.json +102 -8
  53. package/dist/dist-esm/react-components/src/theming/icons.js +6 -6
  54. package/dist/dist-esm/react-components/src/theming/icons.js.map +1 -1
  55. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +1 -1
  56. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
  57. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Custom.d.ts +5 -0
  58. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Custom.js +31 -1
  59. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Custom.js.map +1 -1
  60. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.d.ts +1 -1
  61. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js +3 -3
  62. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js.map +1 -1
  63. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatControlBar.js +6 -8
  64. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatControlBar.js.map +1 -1
  65. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CustomButton.d.ts +3 -16
  66. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CustomButton.js +43 -49
  67. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CustomButton.js.map +1 -1
  68. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/DesktopMoreButton.d.ts +0 -2
  69. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/DesktopMoreButton.js +26 -47
  70. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/DesktopMoreButton.js.map +1 -1
  71. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/MoreDrawer.js +4 -4
  72. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/components/MoreDrawer.js.map +1 -1
  73. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js +1 -1
  74. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js.map +1 -1
  75. package/dist/dist-esm/react-composites/src/composites/common/icons.js +4 -4
  76. package/dist/dist-esm/react-composites/src/composites/common/icons.js.map +1 -1
  77. package/dist/dist-esm/react-composites/src/composites/localization/locales/de-DE/strings.json +17 -3
  78. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-GB/strings.json +17 -3
  79. package/dist/dist-esm/react-composites/src/composites/localization/locales/es-ES/strings.json +17 -3
  80. package/dist/dist-esm/react-composites/src/composites/localization/locales/fr-FR/strings.json +17 -3
  81. package/dist/dist-esm/react-composites/src/composites/localization/locales/it-IT/strings.json +17 -3
  82. package/dist/dist-esm/react-composites/src/composites/localization/locales/ja-JP/strings.json +17 -3
  83. package/dist/dist-esm/react-composites/src/composites/localization/locales/ko-KR/strings.json +17 -3
  84. package/dist/dist-esm/react-composites/src/composites/localization/locales/nl-NL/strings.json +17 -3
  85. package/dist/dist-esm/react-composites/src/composites/localization/locales/pt-BR/strings.json +17 -3
  86. package/dist/dist-esm/react-composites/src/composites/localization/locales/ru-RU/strings.json +17 -3
  87. package/dist/dist-esm/react-composites/src/composites/localization/locales/tr-TR/strings.json +17 -3
  88. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-CN/strings.json +17 -3
  89. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-TW/strings.json +17 -3
  90. package/package.json +12 -12
  91. package/dist/dist-esm/calling-stateful-client/src/LocalVideoStreamVideoEffectsSubscriber.d.ts +0 -29
  92. package/dist/dist-esm/calling-stateful-client/src/LocalVideoStreamVideoEffectsSubscriber.js +0 -54
  93. package/dist/dist-esm/calling-stateful-client/src/LocalVideoStreamVideoEffectsSubscriber.js.map +0 -1
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "call": {
3
3
  "cameraLabel": "Kamera",
4
+ "noCamerasLabel": "Kamera bulunamadı",
4
5
  "cameraPermissionDenied": "Tarayıcınız kameranıza erişimi engelliyor",
5
6
  "cameraTurnedOff": "Kameranız kapatıldı",
6
7
  "chatButtonLabel": "Sohbet",
@@ -53,6 +54,8 @@
53
54
  "roomNotFoundDetails": "Sağlanan oda kimliği geçerli değil.",
54
55
  "roomNotFoundTitle": "Oda bulunamadı",
55
56
  "soundLabel": "Ses",
57
+ "noMicrophonesLabel": "Mikrofon bulunamadı",
58
+ "noSpeakersLabel": "Hoparlör bulunamadı",
56
59
  "startCallButtonLabel": "Arama başlat",
57
60
  "openDialpadButtonLabel": "Telefon numarasını çevir",
58
61
  "peoplePaneAddPeopleButtonLabel": "Kişi Ekle",
@@ -67,8 +70,19 @@
67
70
  "resumingCallButtonAriaLabel": "Görüşmeye devam edin",
68
71
  "holdScreenLabel": "Beklemeye alındınız",
69
72
  "openDtmfDialpadLabel": "Tuş takımını göster",
70
- "dtmfDialpadPlaceHolderText": "Numara girin",
71
- "outboundCallingNoticeString": "Aranıyor..."
73
+ "dtmfDialpadPlaceholderText": "Numara girin",
74
+ "outboundCallingNoticeString": "Aranıyor...",
75
+ "participantJoinedNoticeString": "{displayName} katıldı",
76
+ "twoParticipantJoinedNoticeString": "{displayName1} ve {displayName2} katıldı",
77
+ "threeParticipantJoinedNoticeString": "{displayName1}, {displayName2} ve {displayName3} katıldı",
78
+ "participantLeftNoticeString": "{displayName} ayrıldı",
79
+ "twoParticipantLeftNoticeString": "{displayName1} ve {displayName2} ayrıldı",
80
+ "threeParticipantLeftNoticeString": "{displayName1}, {displayName2} ve {displayName3} ayrıldı",
81
+ "unnamedParticipantString": "adsız katılımcı",
82
+ "manyUnnamedParticipantsJoined": "adsız katılımcı ve {numOfParticipants} katılımcı katıldı",
83
+ "manyUnnamedParticipantsLeft": "adsız katılımcı ve {numOfParticipants} katılımcı ayrıldı",
84
+ "manyParticipantsJoined": "{displayName1}, {displayName2}, {displayName3} ve {numOfParticipants} katılımcı katıldı",
85
+ "manyParticipantsLeft": "{displayName1}, {displayName2}, {displayName3} ve {numOfParticipants} katılımcı kaldı"
72
86
  },
73
87
  "chat": {
74
88
  "chatListHeader": "Bu sohbette",
@@ -105,6 +119,6 @@
105
119
  "dialpadModalAriaLabel": "Tuş takımı",
106
120
  "dialpadCloseModalButtonAriaLabel": "Tuş takımını kapat",
107
121
  "openDtmfDialpadLabel": "Tuş takımını göster",
108
- "dtmfDialpadPlaceHolderText": "Numara girin"
122
+ "dtmfDialpadPlaceholderText": "Numara girin"
109
123
  }
110
124
  }
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "call": {
3
3
  "cameraLabel": "照相机",
4
+ "noCamerasLabel": "未找到摄像头",
4
5
  "cameraPermissionDenied": "你的浏览器正在阻止对相机的访问",
5
6
  "cameraTurnedOff": "你的相机已关闭",
6
7
  "chatButtonLabel": "聊天",
@@ -53,6 +54,8 @@
53
54
  "roomNotFoundDetails": "提供的会议室 ID 无效。",
54
55
  "roomNotFoundTitle": "未找到会议室。",
55
56
  "soundLabel": "声音",
57
+ "noMicrophonesLabel": "未找到麦克风",
58
+ "noSpeakersLabel": "未找到扬声器",
56
59
  "startCallButtonLabel": "开始通话",
57
60
  "openDialpadButtonLabel": "拨打电话号码",
58
61
  "peoplePaneAddPeopleButtonLabel": "添加人员",
@@ -67,8 +70,19 @@
67
70
  "resumingCallButtonAriaLabel": "继续通话",
68
71
  "holdScreenLabel": "你的通话处于保留状态",
69
72
  "openDtmfDialpadLabel": "显示拨号盘",
70
- "dtmfDialpadPlaceHolderText": "输入号码",
71
- "outboundCallingNoticeString": "正在呼叫..."
73
+ "dtmfDialpadPlaceholderText": "输入号码",
74
+ "outboundCallingNoticeString": "正在呼叫...",
75
+ "participantJoinedNoticeString": "{displayName} 已加入",
76
+ "twoParticipantJoinedNoticeString": "{displayName1} 和 {displayName2} 已加入",
77
+ "threeParticipantJoinedNoticeString": "{displayName1}、{displayName2} 和 {displayName3} 已加入",
78
+ "participantLeftNoticeString": "{displayName} 已离开",
79
+ "twoParticipantLeftNoticeString": "{displayName1} 和 {displayName2} 已离开",
80
+ "threeParticipantLeftNoticeString": "{displayName1}、{displayName2} 和 {displayName3} 已离开",
81
+ "unnamedParticipantString": "未命名的参与者",
82
+ "manyUnnamedParticipantsJoined": "未命名的参与者和其他 {numOfParticipants} 名参与者已加入",
83
+ "manyUnnamedParticipantsLeft": "未命名的参与者和其他 {numOfParticipants} 名参与者已离开",
84
+ "manyParticipantsJoined": "{displayName1}、{displayName2}、{displayName3}和其他{numOfParticipants}位参与者已加入",
85
+ "manyParticipantsLeft": "{displayName1}、{displayName2}、{displayName3}和其他{numOfParticipants}位参与者已离开"
72
86
  },
73
87
  "chat": {
74
88
  "chatListHeader": "在此聊天中",
@@ -105,6 +119,6 @@
105
119
  "dialpadModalAriaLabel": "拨号盘",
106
120
  "dialpadCloseModalButtonAriaLabel": "关闭拨号盘",
107
121
  "openDtmfDialpadLabel": "显示拨号盘",
108
- "dtmfDialpadPlaceHolderText": "输入号码"
122
+ "dtmfDialpadPlaceholderText": "输入号码"
109
123
  }
110
124
  }
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "call": {
3
3
  "cameraLabel": "相機",
4
+ "noCamerasLabel": "找不到相機",
4
5
  "cameraPermissionDenied": "您的瀏覽器禁止存取您的相機",
5
6
  "cameraTurnedOff": "您的相機已關閉",
6
7
  "chatButtonLabel": "聊天",
@@ -53,6 +54,8 @@
53
54
  "roomNotFoundDetails": "提供的會議室識別碼無效。",
54
55
  "roomNotFoundTitle": "找不到會議室",
55
56
  "soundLabel": "音效",
57
+ "noMicrophonesLabel": "找不到麥克風",
58
+ "noSpeakersLabel": "找不到喇叭",
56
59
  "startCallButtonLabel": "開始通話",
57
60
  "openDialpadButtonLabel": "撥打電話號碼",
58
61
  "peoplePaneAddPeopleButtonLabel": "新增人員",
@@ -67,8 +70,19 @@
67
70
  "resumingCallButtonAriaLabel": "繼續通話",
68
71
  "holdScreenLabel": "您的通話已保留",
69
72
  "openDtmfDialpadLabel": "顯示撥號盤",
70
- "dtmfDialpadPlaceHolderText": "輸入號碼",
71
- "outboundCallingNoticeString": "撥號中..."
73
+ "dtmfDialpadPlaceholderText": "輸入號碼",
74
+ "outboundCallingNoticeString": "撥號中...",
75
+ "participantJoinedNoticeString": "{displayName} 已加入",
76
+ "twoParticipantJoinedNoticeString": "{displayName1} 和 {displayName2} 已加入",
77
+ "threeParticipantJoinedNoticeString": "{displayName1}、{displayName2} 和 {displayName3} 已加入",
78
+ "participantLeftNoticeString": "{displayName} 已離開",
79
+ "twoParticipantLeftNoticeString": "{displayName1} 和 {displayName2} 已離開",
80
+ "threeParticipantLeftNoticeString": "{displayName1}、{displayName2} 和 {displayName3} 已離開",
81
+ "unnamedParticipantString": "未命名的參與者",
82
+ "manyUnnamedParticipantsJoined": "未命名的參與者和 {numOfParticipants} 個其他參與者已加入",
83
+ "manyUnnamedParticipantsLeft": "未命名的參與者和 {numOfParticipants} 個其他參與者已離開",
84
+ "manyParticipantsJoined": "{displayName1}、{displayName2}、{displayName3}和其他{numOfParticipants}位參與者已加入",
85
+ "manyParticipantsLeft": "{displayName1}、{displayName2}、{displayName3}和其他{numOfParticipants}位參與者"
72
86
  },
73
87
  "chat": {
74
88
  "chatListHeader": "在此聊天中",
@@ -105,6 +119,6 @@
105
119
  "dialpadModalAriaLabel": "撥號鍵台",
106
120
  "dialpadCloseModalButtonAriaLabel": "關閉撥號鍵台",
107
121
  "openDtmfDialpadLabel": "顯示撥號盤",
108
- "dtmfDialpadPlaceHolderText": "輸入號碼"
122
+ "dtmfDialpadPlaceholderText": "輸入號碼"
109
123
  }
110
124
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@azure/communication-react",
3
- "version": "1.5.1-alpha-202302230015",
3
+ "version": "1.5.1-beta.1",
4
4
  "sideEffects": false,
5
5
  "description": "React library for building modern communication user experiences utilizing Azure Communication Services",
6
6
  "keywords": [
@@ -30,7 +30,7 @@
30
30
  "@azure/logger": "1.0.3",
31
31
  "@fluentui/react-file-type-icons": "~8.5.8",
32
32
  "@fluentui/react-hooks": "~8.6.12",
33
- "@fluentui/react-icons": "~2.0.194",
33
+ "@fluentui/react-icons": "~1.1.145",
34
34
  "@fluentui/react-northstar": "0.61.0",
35
35
  "@fluentui/react-window-provider": "~2.2.3",
36
36
  "@fluentui/react": "~8.98.3",
@@ -47,9 +47,9 @@
47
47
  "uuid": "^8.1.0"
48
48
  },
49
49
  "peerDependencies": {
50
- "@azure/communication-calling": "1.10.0-beta.1 || >=1.4.4",
50
+ "@azure/communication-calling": "1.10.0-beta.1",
51
51
  "@azure/communication-calling-effects": "1.0.0-beta.2",
52
- "@azure/communication-chat": ">=1.2.0",
52
+ "@azure/communication-chat": "1.2.0",
53
53
  "@types/react": ">=16.8.0 <18.0.0",
54
54
  "@types/react-dom": ">=16.8.0 <18.0.0",
55
55
  "react": ">=16.8.0 <18.0.0",
@@ -83,19 +83,19 @@
83
83
  "_by-flavor": "rushx _current-flavor && env-cmd -f ../../common/config/env/.env --use-shell"
84
84
  },
85
85
  "devDependencies": {
86
- "@azure/communication-calling": "1.10.0-beta.1 || >=1.4.4",
86
+ "@azure/communication-calling": "1.10.0-beta.1",
87
87
  "@azure/communication-calling-effects": "1.0.0-beta.2",
88
88
  "@azure/communication-chat": ">=1.2.0",
89
89
  "@azure/core-auth": "1.3.2",
90
90
  "@babel/cli": "~7.16.0",
91
91
  "@babel/core": "~7.16.0",
92
- "@internal/calling-component-bindings": "1.5.1-alpha-202302230015",
93
- "@internal/calling-stateful-client": "1.5.1-alpha-202302230015",
94
- "@internal/chat-component-bindings": "1.5.1-alpha-202302230015",
95
- "@internal/chat-stateful-client": "1.5.1-alpha-202302230015",
96
- "@internal/fake-backends": "1.5.1-alpha-202302230015",
97
- "@internal/react-components": "1.5.1-alpha-202302230015",
98
- "@internal/react-composites": "1.5.1-alpha-202302230015",
92
+ "@internal/calling-component-bindings": "1.5.1-beta.1",
93
+ "@internal/calling-stateful-client": "1.5.1-beta.1",
94
+ "@internal/chat-component-bindings": "1.5.1-beta.1",
95
+ "@internal/chat-stateful-client": "1.5.1-beta.1",
96
+ "@internal/fake-backends": "1.5.1-beta.1",
97
+ "@internal/react-components": "1.5.1-beta.1",
98
+ "@internal/react-composites": "1.5.1-beta.1",
99
99
  "@microsoft/api-documenter": "~7.12.11",
100
100
  "@microsoft/api-extractor": "~7.18.0",
101
101
  "@rollup/plugin-json": "~4.1.0",
@@ -1,29 +0,0 @@
1
- import { VideoEffectsFeature } from '@azure/communication-calling';
2
- import { LocalVideoStreamState } from './CallClientState';
3
- import { CallContext } from './CallContext';
4
- import { CallIdRef } from './CallIdRef';
5
- /**
6
- * Subscribes to a LocalVideoStream's video effects events and updates the call context appropriately.
7
- * @private
8
- */
9
- export declare class LocalVideoStreamVideoEffectsSubscriber {
10
- private _parent;
11
- private _context;
12
- private _localVideoStream;
13
- private _localVideoStreamEffectsAPI;
14
- constructor(args: {
15
- /** Owner of the local video stream. This is either the Call (referenced by CallIdRef) or is the device manager's unparented view (referenced by 'unparented') */
16
- parent: CallIdRef | 'unparented';
17
- context: CallContext;
18
- localVideoStream: LocalVideoStreamState;
19
- localVideoStreamEffectsAPI: VideoEffectsFeature;
20
- });
21
- private subscribe;
22
- unsubscribe: () => void;
23
- private effectsStarted;
24
- private effectsStopped;
25
- private effectsError;
26
- private updateEffectsState;
27
- }
28
- export {};
29
- //# sourceMappingURL=LocalVideoStreamVideoEffectsSubscriber.d.ts.map
@@ -1,54 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
3
- /* @conditional-compile-remove(video-background-effects) */
4
- /**
5
- * Subscribes to a LocalVideoStream's video effects events and updates the call context appropriately.
6
- * @private
7
- */
8
- export class LocalVideoStreamVideoEffectsSubscriber {
9
- constructor(args) {
10
- this.subscribe = () => {
11
- this._localVideoStreamEffectsAPI.on('effectsStarted', this.effectsStarted);
12
- this._localVideoStreamEffectsAPI.on('effectsStopped', this.effectsStopped);
13
- this._localVideoStreamEffectsAPI.on('effectsError', this.effectsError);
14
- };
15
- this.unsubscribe = () => {
16
- this._localVideoStreamEffectsAPI.off('effectsStarted', this.effectsStarted);
17
- this._localVideoStreamEffectsAPI.off('effectsStopped', this.effectsStopped);
18
- this._localVideoStreamEffectsAPI.off('effectsError', this.effectsError);
19
- };
20
- this.effectsStarted = (effectName) => {
21
- this.updateEffectsState({
22
- isActive: true,
23
- effectName: effectName
24
- });
25
- };
26
- this.effectsStopped = (effectName) => {
27
- this.updateEffectsState({
28
- isActive: false,
29
- effectName: effectName
30
- });
31
- };
32
- this.effectsError = (error) => {
33
- // When there is an error the effects have stopped. Update the state to reflect this.
34
- this.updateEffectsState({
35
- isActive: false
36
- });
37
- this._context.teeErrorToState(new Error(error.message), 'VideoEffectsFeature.startEffects');
38
- };
39
- this.updateEffectsState = (newEffectsState) => {
40
- if (this._parent === 'unparented') {
41
- this._context.setDeviceManagerUnparentedViewVideoEffects(this._localVideoStream, newEffectsState);
42
- }
43
- else {
44
- this._context.setCallLocalVideoStreamVideoEffects(this._parent.callId, newEffectsState);
45
- }
46
- };
47
- this._parent = args.parent;
48
- this._context = args.context;
49
- this._localVideoStream = args.localVideoStream;
50
- this._localVideoStreamEffectsAPI = args.localVideoStreamEffectsAPI;
51
- this.subscribe();
52
- }
53
- }
54
- //# sourceMappingURL=LocalVideoStreamVideoEffectsSubscriber.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LocalVideoStreamVideoEffectsSubscriber.js","sourceRoot":"","sources":["../../../../../calling-stateful-client/src/LocalVideoStreamVideoEffectsSubscriber.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAWlC,2DAA2D;AAC3D;;;GAGG;AACH,MAAM,OAAO,sCAAsC;IAMjD,YAAY,IAMX;QASO,cAAS,GAAG,GAAS,EAAE;YAC7B,IAAI,CAAC,2BAA2B,CAAC,EAAE,CAAC,gBAAgB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;YAC3E,IAAI,CAAC,2BAA2B,CAAC,EAAE,CAAC,gBAAgB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;YAC3E,IAAI,CAAC,2BAA2B,CAAC,EAAE,CAAC,cAAc,EAAE,IAAI,CAAC,YAAY,CAAC,CAAC;QACzE,CAAC,CAAC;QAEK,gBAAW,GAAG,GAAS,EAAE;YAC9B,IAAI,CAAC,2BAA2B,CAAC,GAAG,CAAC,gBAAgB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;YAC5E,IAAI,CAAC,2BAA2B,CAAC,GAAG,CAAC,gBAAgB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;YAC5E,IAAI,CAAC,2BAA2B,CAAC,GAAG,CAAC,cAAc,EAAE,IAAI,CAAC,YAAY,CAAC,CAAC;QAC1E,CAAC,CAAC;QAEM,mBAAc,GAAG,CAAC,UAA2B,EAAQ,EAAE;YAC7D,IAAI,CAAC,kBAAkB,CAAC;gBACtB,QAAQ,EAAE,IAAI;gBACd,UAAU,EAAE,UAAU;aACvB,CAAC,CAAC;QACL,CAAC,CAAC;QAEM,mBAAc,GAAG,CAAC,UAA2B,EAAQ,EAAE;YAC7D,IAAI,CAAC,kBAAkB,CAAC;gBACtB,QAAQ,EAAE,KAAK;gBACf,UAAU,EAAE,UAAU;aACvB,CAAC,CAAC;QACL,CAAC,CAAC;QAEM,iBAAY,GAAG,CAAC,KAA8B,EAAQ,EAAE;YAC9D,qFAAqF;YACrF,IAAI,CAAC,kBAAkB,CAAC;gBACtB,QAAQ,EAAE,KAAK;aAChB,CAAC,CAAC;YACH,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,EAAE,kCAAkC,CAAC,CAAC;QAC9F,CAAC,CAAC;QAEM,uBAAkB,GAAG,CAAC,eAAkD,EAAQ,EAAE;YACxF,IAAI,IAAI,CAAC,OAAO,KAAK,YAAY,EAAE;gBACjC,IAAI,CAAC,QAAQ,CAAC,0CAA0C,CAAC,IAAI,CAAC,iBAAiB,EAAE,eAAe,CAAC,CAAC;aACnG;iBAAM;gBACL,IAAI,CAAC,QAAQ,CAAC,mCAAmC,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC;aACzF;QACH,CAAC,CAAC;QAhDA,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC;QAC3B,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC;QAC7B,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,gBAAgB,CAAC;QAC/C,IAAI,CAAC,2BAA2B,GAAG,IAAI,CAAC,0BAA0B,CAAC;QAEnE,IAAI,CAAC,SAAS,EAAE,CAAC;IACnB,CAAC;CA2CF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\n/* @conditional-compile-remove(video-background-effects) */\nimport { VideoEffectErrorPayload, VideoEffectName, VideoEffectsFeature } from '@azure/communication-calling';\n/* @conditional-compile-remove(video-background-effects) */\nimport { LocalVideoStreamState, LocalVideoStreamVideoEffectsState } from './CallClientState';\n/* @conditional-compile-remove(video-background-effects) */\nimport { CallContext } from './CallContext';\n/* @conditional-compile-remove(video-background-effects) */\nimport { CallIdRef } from './CallIdRef';\n\n/* @conditional-compile-remove(video-background-effects) */\n/**\n * Subscribes to a LocalVideoStream's video effects events and updates the call context appropriately.\n * @private\n */\nexport class LocalVideoStreamVideoEffectsSubscriber {\n private _parent: CallIdRef | 'unparented';\n private _context: CallContext;\n private _localVideoStream: LocalVideoStreamState;\n private _localVideoStreamEffectsAPI: VideoEffectsFeature;\n\n constructor(args: {\n /** Owner of the local video stream. This is either the Call (referenced by CallIdRef) or is the device manager's unparented view (referenced by 'unparented') */\n parent: CallIdRef | 'unparented';\n context: CallContext;\n localVideoStream: LocalVideoStreamState;\n localVideoStreamEffectsAPI: VideoEffectsFeature;\n }) {\n this._parent = args.parent;\n this._context = args.context;\n this._localVideoStream = args.localVideoStream;\n this._localVideoStreamEffectsAPI = args.localVideoStreamEffectsAPI;\n\n this.subscribe();\n }\n\n private subscribe = (): void => {\n this._localVideoStreamEffectsAPI.on('effectsStarted', this.effectsStarted);\n this._localVideoStreamEffectsAPI.on('effectsStopped', this.effectsStopped);\n this._localVideoStreamEffectsAPI.on('effectsError', this.effectsError);\n };\n\n public unsubscribe = (): void => {\n this._localVideoStreamEffectsAPI.off('effectsStarted', this.effectsStarted);\n this._localVideoStreamEffectsAPI.off('effectsStopped', this.effectsStopped);\n this._localVideoStreamEffectsAPI.off('effectsError', this.effectsError);\n };\n\n private effectsStarted = (effectName: VideoEffectName): void => {\n this.updateEffectsState({\n isActive: true,\n effectName: effectName\n });\n };\n\n private effectsStopped = (effectName: VideoEffectName): void => {\n this.updateEffectsState({\n isActive: false,\n effectName: effectName\n });\n };\n\n private effectsError = (error: VideoEffectErrorPayload): void => {\n // When there is an error the effects have stopped. Update the state to reflect this.\n this.updateEffectsState({\n isActive: false\n });\n this._context.teeErrorToState(new Error(error.message), 'VideoEffectsFeature.startEffects');\n };\n\n private updateEffectsState = (newEffectsState: LocalVideoStreamVideoEffectsState): void => {\n if (this._parent === 'unparented') {\n this._context.setDeviceManagerUnparentedViewVideoEffects(this._localVideoStream, newEffectsState);\n } else {\n this._context.setCallLocalVideoStreamVideoEffects(this._parent.callId, newEffectsState);\n }\n };\n}\n\nexport {};\n"]}