@azure/communication-react 1.20.0-beta.1 → 1.20.0

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 (634) hide show
  1. package/README.md +2 -2
  2. package/dist/communication-react.d.ts +245 -1703
  3. package/dist/dist-cjs/communication-react/index.js +36159 -165
  4. package/dist/dist-cjs/communication-react/index.js.map +1 -1
  5. package/dist/dist-esm/acs-ui-common/src/common.d.ts +0 -13
  6. package/dist/dist-esm/acs-ui-common/src/common.js.map +1 -1
  7. package/dist/dist-esm/acs-ui-common/src/constants.d.ts +0 -5
  8. package/dist/dist-esm/acs-ui-common/src/constants.js +0 -5
  9. package/dist/dist-esm/acs-ui-common/src/constants.js.map +1 -1
  10. package/dist/dist-esm/acs-ui-common/src/index.d.ts +0 -4
  11. package/dist/dist-esm/acs-ui-common/src/index.js +0 -3
  12. package/dist/dist-esm/acs-ui-common/src/index.js.map +1 -1
  13. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
  14. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
  15. package/dist/dist-esm/acs-ui-javascript-loaders/src/callCompositeLoader.d.ts +16 -7
  16. package/dist/dist-esm/acs-ui-javascript-loaders/src/callCompositeLoader.js +10 -10
  17. package/dist/dist-esm/acs-ui-javascript-loaders/src/callCompositeLoader.js.map +1 -1
  18. package/dist/dist-esm/acs-ui-javascript-loaders/src/callWithChatCompositeLoader.d.ts +17 -7
  19. package/dist/dist-esm/acs-ui-javascript-loaders/src/callWithChatCompositeLoader.js +12 -10
  20. package/dist/dist-esm/acs-ui-javascript-loaders/src/callWithChatCompositeLoader.js.map +1 -1
  21. package/dist/dist-esm/acs-ui-javascript-loaders/src/chatCompositeLoader.d.ts +13 -7
  22. package/dist/dist-esm/acs-ui-javascript-loaders/src/chatCompositeLoader.js +10 -9
  23. package/dist/dist-esm/acs-ui-javascript-loaders/src/chatCompositeLoader.js.map +1 -1
  24. package/dist/dist-esm/acs-ui-javascript-loaders/src/outboundCallCompositeLoader.d.ts +16 -7
  25. package/dist/dist-esm/acs-ui-javascript-loaders/src/outboundCallCompositeLoader.js +10 -9
  26. package/dist/dist-esm/acs-ui-javascript-loaders/src/outboundCallCompositeLoader.js.map +1 -1
  27. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.d.ts +3 -12
  28. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js +0 -12
  29. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js.map +1 -1
  30. package/dist/dist-esm/calling-component-bindings/src/callControlSelectors.js +1 -1
  31. package/dist/dist-esm/calling-component-bindings/src/callControlSelectors.js.map +1 -1
  32. package/dist/dist-esm/calling-component-bindings/src/errorBarSelector.js +0 -2
  33. package/dist/dist-esm/calling-component-bindings/src/errorBarSelector.js.map +1 -1
  34. package/dist/dist-esm/calling-component-bindings/src/getRemoteParticipantsExcludingConsumers.js +2 -1
  35. package/dist/dist-esm/calling-component-bindings/src/getRemoteParticipantsExcludingConsumers.js.map +1 -1
  36. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.d.ts +12 -2
  37. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.js +26 -6
  38. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.js.map +1 -1
  39. package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.d.ts +6 -0
  40. package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js +1 -5
  41. package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js.map +1 -1
  42. package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.d.ts +2 -0
  43. package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js +2 -19
  44. package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js.map +1 -1
  45. package/dist/dist-esm/calling-component-bindings/src/index.d.ts +2 -2
  46. package/dist/dist-esm/calling-component-bindings/src/index.js +1 -2
  47. package/dist/dist-esm/calling-component-bindings/src/index.js.map +1 -1
  48. package/dist/dist-esm/calling-component-bindings/src/notificationStackSelector.js +1 -35
  49. package/dist/dist-esm/calling-component-bindings/src/notificationStackSelector.js.map +1 -1
  50. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.d.ts +0 -1
  51. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js +1 -3
  52. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js.map +1 -1
  53. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.d.ts +1 -2
  54. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js +3 -3
  55. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js.map +1 -1
  56. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js +0 -4
  57. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js.map +1 -1
  58. package/dist/dist-esm/calling-stateful-client/src/CallClientState.d.ts +2 -79
  59. package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
  60. package/dist/dist-esm/calling-stateful-client/src/CallContext.d.ts +0 -15
  61. package/dist/dist-esm/calling-stateful-client/src/CallContext.js +32 -107
  62. package/dist/dist-esm/calling-stateful-client/src/CallContext.js.map +1 -1
  63. package/dist/dist-esm/calling-stateful-client/src/CallDeclarativeCommon.js.map +1 -1
  64. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.d.ts +0 -5
  65. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js +4 -27
  66. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js.map +1 -1
  67. package/dist/dist-esm/calling-stateful-client/src/CaptionsSubscriber.js.map +1 -1
  68. package/dist/dist-esm/calling-stateful-client/src/Converter.js +0 -3
  69. package/dist/dist-esm/calling-stateful-client/src/Converter.js.map +1 -1
  70. package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js +58 -52
  71. package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js.map +1 -1
  72. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.d.ts +0 -1
  73. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.js +1 -7
  74. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.js.map +1 -1
  75. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js +5 -3
  76. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js.map +1 -1
  77. package/dist/dist-esm/calling-stateful-client/src/TeamsCallDeclarative.js +0 -17
  78. package/dist/dist-esm/calling-stateful-client/src/TeamsCallDeclarative.js.map +1 -1
  79. package/dist/dist-esm/calling-stateful-client/src/index-public.d.ts +0 -3
  80. package/dist/dist-esm/calling-stateful-client/src/index-public.js.map +1 -1
  81. package/dist/dist-esm/chat-component-bindings/src/handlers/createHandlers.d.ts +2 -6
  82. package/dist/dist-esm/chat-component-bindings/src/handlers/createHandlers.js +2 -35
  83. package/dist/dist-esm/chat-component-bindings/src/handlers/createHandlers.js.map +1 -1
  84. package/dist/dist-esm/chat-component-bindings/src/hooks/usePropsFor.d.ts +1 -2
  85. package/dist/dist-esm/chat-component-bindings/src/hooks/usePropsFor.js +0 -3
  86. package/dist/dist-esm/chat-component-bindings/src/hooks/usePropsFor.js.map +1 -1
  87. package/dist/dist-esm/chat-component-bindings/src/messageThreadSelector.js +2 -25
  88. package/dist/dist-esm/chat-component-bindings/src/messageThreadSelector.js.map +1 -1
  89. package/dist/dist-esm/chat-component-bindings/src/utils/updateMessagesWithAttached.js +3 -3
  90. package/dist/dist-esm/chat-component-bindings/src/utils/updateMessagesWithAttached.js.map +1 -1
  91. package/dist/dist-esm/chat-stateful-client/src/ChatClientState.d.ts +1 -15
  92. package/dist/dist-esm/chat-stateful-client/src/ChatClientState.js.map +1 -1
  93. package/dist/dist-esm/chat-stateful-client/src/EventSubscriber.js +1 -2
  94. package/dist/dist-esm/chat-stateful-client/src/EventSubscriber.js.map +1 -1
  95. package/dist/dist-esm/chat-stateful-client/src/index.d.ts +0 -1
  96. package/dist/dist-esm/chat-stateful-client/src/index.js.map +1 -1
  97. package/dist/dist-esm/communication-react/src/index.d.ts +1 -27
  98. package/dist/dist-esm/communication-react/src/index.js +0 -6
  99. package/dist/dist-esm/communication-react/src/index.js.map +1 -1
  100. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCard.js +3 -2
  101. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCard.js.map +1 -1
  102. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.d.ts +0 -2
  103. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.js +0 -2
  104. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.js.map +1 -1
  105. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.d.ts +1 -13
  106. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js +3 -9
  107. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js.map +1 -1
  108. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.d.ts +0 -11
  109. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.js +7 -34
  110. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.js.map +1 -1
  111. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.d.ts +1 -8
  112. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.js +5 -9
  113. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.js.map +1 -1
  114. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.d.ts +1 -2
  115. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.js +4 -4
  116. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.js.map +1 -1
  117. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.d.ts +1 -4
  118. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.js +6 -31
  119. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.js.map +1 -1
  120. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.d.ts +1 -15
  121. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js +0 -9
  122. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js.map +1 -1
  123. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.d.ts +2 -23
  124. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js +6 -17
  125. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js.map +1 -1
  126. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.d.ts +1 -8
  127. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.js +6 -10
  128. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.js.map +1 -1
  129. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js +5 -5
  130. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js.map +1 -1
  131. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js +6 -4
  132. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js.map +1 -1
  133. package/dist/dist-esm/react-components/src/components/GridLayout.js +3 -0
  134. package/dist/dist-esm/react-components/src/components/GridLayout.js.map +1 -1
  135. package/dist/dist-esm/react-components/src/components/HorizontalGallery.js +4 -5
  136. package/dist/dist-esm/react-components/src/components/HorizontalGallery.js.map +1 -1
  137. package/dist/dist-esm/react-components/src/components/ImageOverlay.js +0 -2
  138. package/dist/dist-esm/react-components/src/components/ImageOverlay.js.map +1 -1
  139. package/dist/dist-esm/react-components/src/components/InputBoxComponent.d.ts +0 -2
  140. package/dist/dist-esm/react-components/src/components/InputBoxComponent.js +0 -15
  141. package/dist/dist-esm/react-components/src/components/InputBoxComponent.js.map +1 -1
  142. package/dist/dist-esm/react-components/src/components/LocalVideoCameraButton.js +3 -0
  143. package/dist/dist-esm/react-components/src/components/LocalVideoCameraButton.js.map +1 -1
  144. package/dist/dist-esm/react-components/src/components/LocalVideoTile.d.ts +1 -0
  145. package/dist/dist-esm/react-components/src/components/LocalVideoTile.js +4 -4
  146. package/dist/dist-esm/react-components/src/components/LocalVideoTile.js.map +1 -1
  147. package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js +2 -1
  148. package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js.map +1 -1
  149. package/dist/dist-esm/react-components/src/components/MessageThread.d.ts +5 -81
  150. package/dist/dist-esm/react-components/src/components/MessageThread.js +6 -16
  151. package/dist/dist-esm/react-components/src/components/MessageThread.js.map +1 -1
  152. package/dist/dist-esm/react-components/src/components/MicrophoneButton.d.ts +24 -0
  153. package/dist/dist-esm/react-components/src/components/MicrophoneButton.js +25 -0
  154. package/dist/dist-esm/react-components/src/components/MicrophoneButton.js.map +1 -1
  155. package/dist/dist-esm/react-components/src/components/ModalClone/ModalClone.js +2 -1
  156. package/dist/dist-esm/react-components/src/components/ModalClone/ModalClone.js.map +1 -1
  157. package/dist/dist-esm/react-components/src/components/Notification.js +3 -1
  158. package/dist/dist-esm/react-components/src/components/Notification.js.map +1 -1
  159. package/dist/dist-esm/react-components/src/components/NotificationStack.d.ts +0 -20
  160. package/dist/dist-esm/react-components/src/components/NotificationStack.js +0 -5
  161. package/dist/dist-esm/react-components/src/components/NotificationStack.js.map +1 -1
  162. package/dist/dist-esm/react-components/src/components/ParticipantItem.js +1 -1
  163. package/dist/dist-esm/react-components/src/components/ParticipantItem.js.map +1 -1
  164. package/dist/dist-esm/react-components/src/components/ParticipantList.d.ts +0 -15
  165. package/dist/dist-esm/react-components/src/components/ParticipantList.js +3 -12
  166. package/dist/dist-esm/react-components/src/components/ParticipantList.js.map +1 -1
  167. package/dist/dist-esm/react-components/src/components/ReactionButton.js +31 -41
  168. package/dist/dist-esm/react-components/src/components/ReactionButton.js.map +1 -1
  169. package/dist/dist-esm/react-components/src/components/SendBox.d.ts +1 -47
  170. package/dist/dist-esm/react-components/src/components/SendBox.js +6 -57
  171. package/dist/dist-esm/react-components/src/components/SendBox.js.map +1 -1
  172. package/dist/dist-esm/react-components/src/components/TroubleshootingGuideErrorBar.js +7 -3
  173. package/dist/dist-esm/react-components/src/components/TroubleshootingGuideErrorBar.js.map +1 -1
  174. package/dist/dist-esm/react-components/src/components/UnsupportedBrowser.js +0 -1
  175. package/dist/dist-esm/react-components/src/components/UnsupportedBrowser.js.map +1 -1
  176. package/dist/dist-esm/react-components/src/components/UnsupportedBrowserVersion.js +0 -1
  177. package/dist/dist-esm/react-components/src/components/UnsupportedBrowserVersion.js.map +1 -1
  178. package/dist/dist-esm/react-components/src/components/UnsupportedEnvironment.js +0 -19
  179. package/dist/dist-esm/react-components/src/components/UnsupportedEnvironment.js.map +1 -1
  180. package/dist/dist-esm/react-components/src/components/UnsupportedOperatingSystem.js +0 -1
  181. package/dist/dist-esm/react-components/src/components/UnsupportedOperatingSystem.js.map +1 -1
  182. package/dist/dist-esm/react-components/src/components/VerticalGallery.js +2 -1
  183. package/dist/dist-esm/react-components/src/components/VerticalGallery.js.map +1 -1
  184. package/dist/dist-esm/react-components/src/components/VideoEffects/VideoBackgroundEffectsPicker.js +3 -3
  185. package/dist/dist-esm/react-components/src/components/VideoEffects/VideoBackgroundEffectsPicker.js.map +1 -1
  186. package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideo.js +6 -2
  187. package/dist/dist-esm/react-components/src/components/VideoGallery/FloatingLocalVideo.js.map +1 -1
  188. package/dist/dist-esm/react-components/src/components/VideoGallery/RemoteContentShareReactionOverlay.js +5 -4
  189. package/dist/dist-esm/react-components/src/components/VideoGallery/RemoteContentShareReactionOverlay.js.map +1 -1
  190. package/dist/dist-esm/react-components/src/components/VideoGallery/styles/FloatingLocalVideo.styles.js +1 -1
  191. package/dist/dist-esm/react-components/src/components/VideoGallery/styles/FloatingLocalVideo.styles.js.map +1 -1
  192. package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js +23 -17
  193. package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js.map +1 -1
  194. package/dist/dist-esm/react-components/src/components/VideoGallery.js +3 -3
  195. package/dist/dist-esm/react-components/src/components/VideoGallery.js.map +1 -1
  196. package/dist/dist-esm/react-components/src/components/VideoTile.js +3 -0
  197. package/dist/dist-esm/react-components/src/components/VideoTile.js.map +1 -1
  198. package/dist/dist-esm/react-components/src/components/index.d.ts +0 -20
  199. package/dist/dist-esm/react-components/src/components/index.js +0 -7
  200. package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
  201. package/dist/dist-esm/react-components/src/components/styles/AttachmentCard.styles.d.ts +1 -1
  202. package/dist/dist-esm/react-components/src/components/styles/AttachmentCardGroup.styles.d.ts +1 -1
  203. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.d.ts +3 -3
  204. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.js +0 -8
  205. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.js.map +1 -1
  206. package/dist/dist-esm/react-components/src/components/styles/ReactionButton.styles.d.ts +13 -6
  207. package/dist/dist-esm/react-components/src/components/styles/ReactionButton.styles.js +49 -19
  208. package/dist/dist-esm/react-components/src/components/styles/ReactionButton.styles.js.map +1 -1
  209. package/dist/dist-esm/react-components/src/components/styles/ReactionOverlay.style.d.ts +0 -6
  210. package/dist/dist-esm/react-components/src/components/styles/ReactionOverlay.style.js +6 -35
  211. package/dist/dist-esm/react-components/src/components/styles/ReactionOverlay.style.js.map +1 -1
  212. package/dist/dist-esm/react-components/src/components/styles/StreamMedia.styles.js +5 -2
  213. package/dist/dist-esm/react-components/src/components/styles/StreamMedia.styles.js.map +1 -1
  214. package/dist/dist-esm/react-components/src/components/styles/VideoTile.styles.js +2 -1
  215. package/dist/dist-esm/react-components/src/components/styles/VideoTile.styles.js.map +1 -1
  216. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.d.ts +1 -37
  217. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.js +3 -30
  218. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.js.map +1 -1
  219. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.d.ts +2 -4
  220. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.js +2 -9
  221. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.js.map +1 -1
  222. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.d.ts +1 -38
  223. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js +4 -131
  224. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js.map +1 -1
  225. package/dist/dist-esm/react-components/src/components/utils/common.js +0 -2
  226. package/dist/dist-esm/react-components/src/components/utils/common.js.map +1 -1
  227. package/dist/dist-esm/react-components/src/components/utils/getParticipantsWhoHaveReadMessage.d.ts +1 -2
  228. package/dist/dist-esm/react-components/src/components/utils/getParticipantsWhoHaveReadMessage.js.map +1 -1
  229. package/dist/dist-esm/react-components/src/components/utils/responsive.js +6 -0
  230. package/dist/dist-esm/react-components/src/components/utils/responsive.js.map +1 -1
  231. package/dist/dist-esm/react-components/src/components/utils.js +1 -6
  232. package/dist/dist-esm/react-components/src/components/utils.js.map +1 -1
  233. package/dist/dist-esm/react-components/src/gallery/dominantSpeaker.js.map +1 -1
  234. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.d.ts +0 -4
  235. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.js +1 -3
  236. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.js.map +1 -1
  237. package/dist/dist-esm/react-components/src/index.d.ts +0 -1
  238. package/dist/dist-esm/react-components/src/index.js.map +1 -1
  239. package/dist/dist-esm/react-components/src/localization/LocalizationProvider.d.ts +0 -54
  240. package/dist/dist-esm/react-components/src/localization/LocalizationProvider.js.map +1 -1
  241. package/dist/dist-esm/react-components/src/localization/locales/cy-GB/strings.json +1 -1
  242. package/dist/dist-esm/react-components/src/theming/generateTheme.js +10 -2
  243. package/dist/dist-esm/react-components/src/theming/generateTheme.js.map +1 -1
  244. package/dist/dist-esm/react-components/src/theming/icons.d.ts +0 -30
  245. package/dist/dist-esm/react-components/src/theming/icons.js +0 -91
  246. package/dist/dist-esm/react-components/src/theming/icons.js.map +1 -1
  247. package/dist/dist-esm/react-components/src/theming/themes.d.ts +0 -6
  248. package/dist/dist-esm/react-components/src/theming/themes.js +0 -9
  249. package/dist/dist-esm/react-components/src/theming/themes.js.map +1 -1
  250. package/dist/dist-esm/react-components/src/types/Attachment.d.ts +0 -13
  251. package/dist/dist-esm/react-components/src/types/Attachment.js.map +1 -1
  252. package/dist/dist-esm/react-components/src/types/ChatMessage.d.ts +1 -20
  253. package/dist/dist-esm/react-components/src/types/ChatMessage.js.map +1 -1
  254. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.d.ts +0 -72
  255. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js +13 -23
  256. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js.map +1 -1
  257. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.d.ts +4 -34
  258. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.js.map +1 -1
  259. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.d.ts +17 -47
  260. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js +68 -137
  261. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js.map +1 -1
  262. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.d.ts +26 -24
  263. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.js +1 -1
  264. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.js.map +1 -1
  265. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.d.ts +2 -2
  266. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js +6 -7
  267. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js.map +1 -1
  268. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/OnFetchProfileCallback.js +9 -4
  269. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/OnFetchProfileCallback.js.map +1 -1
  270. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/createHandlers.d.ts +2 -0
  271. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/createHandlers.js.map +1 -1
  272. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/index.d.ts +0 -2
  273. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/index.js.map +1 -1
  274. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js +21 -24
  275. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js.map +1 -1
  276. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.d.ts +0 -3
  277. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js +50 -13
  278. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js.map +1 -1
  279. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.d.ts +0 -2
  280. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.js +0 -19
  281. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.js.map +1 -1
  282. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageErrorBar.js +2 -10
  283. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageErrorBar.js.map +1 -1
  284. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.d.ts +0 -2
  285. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.js +0 -19
  286. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.js.map +1 -1
  287. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.d.ts +0 -1
  288. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js +41 -25
  289. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js.map +1 -1
  290. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/MediaGallery.js +12 -10
  291. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/MediaGallery.js.map +1 -1
  292. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +1 -1
  293. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
  294. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Prompt.d.ts +1 -0
  295. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Prompt.js +1 -1
  296. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Prompt.js.map +1 -1
  297. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/SidePane.d.ts +1 -0
  298. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/SidePane.js +1 -1
  299. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/SidePane.js.map +1 -1
  300. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js +7 -4
  301. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js.map +1 -1
  302. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/useVideoEffectsPane.js +5 -2
  303. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/useVideoEffectsPane.js.map +1 -1
  304. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Camera.js +7 -6
  305. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Camera.js.map +1 -1
  306. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Devices.js +4 -4
  307. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Devices.js.map +1 -1
  308. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.d.ts +0 -1
  309. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.js +7 -23
  310. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.js.map +1 -1
  311. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Microphone.d.ts +3 -0
  312. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Microphone.js +6 -7
  313. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/Microphone.js.map +1 -1
  314. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/ScreenShare.js +5 -5
  315. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/ScreenShare.js.map +1 -1
  316. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useAdaptedSelector.js +1 -2
  317. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useAdaptedSelector.js.map +1 -1
  318. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useHandlers.js +9 -5
  319. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useHandlers.js.map +1 -1
  320. package/dist/dist-esm/react-composites/src/composites/CallComposite/index.d.ts +0 -3
  321. package/dist/dist-esm/react-composites/src/composites/CallComposite/index.js.map +1 -1
  322. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/CallPage.js +2 -2
  323. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/CallPage.js.map +1 -1
  324. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.d.ts +0 -7
  325. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js +16 -53
  326. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js.map +1 -1
  327. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/DtmfDialpadPage.js +7 -9
  328. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/DtmfDialpadPage.js.map +1 -1
  329. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/HoldPage.js +2 -2
  330. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/HoldPage.js.map +1 -1
  331. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/LobbyPage.js +2 -2
  332. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/LobbyPage.js.map +1 -1
  333. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js +5 -2
  334. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js.map +1 -1
  335. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.d.ts +21 -25
  336. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.js +16 -16
  337. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.js.map +1 -1
  338. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/dominantRemoteParticipantSelector.js +1 -1
  339. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/dominantRemoteParticipantSelector.js.map +1 -1
  340. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localPreviewSelector.js +2 -1
  341. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localPreviewSelector.js.map +1 -1
  342. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js +10 -11
  343. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/MediaGalleryUtils.js.map +1 -1
  344. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.d.ts +2 -14
  345. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js +12 -68
  346. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js.map +1 -1
  347. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.d.ts +0 -65
  348. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.js +5 -24
  349. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.js.map +1 -1
  350. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/Strings.d.ts +0 -8
  351. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/Strings.js.map +1 -1
  352. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.d.ts +5 -22
  353. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js +14 -139
  354. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js.map +1 -1
  355. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatAdapter.d.ts +11 -28
  356. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatAdapter.js.map +1 -1
  357. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.d.ts +2 -2
  358. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.js +13 -9
  359. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.js.map +1 -1
  360. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.d.ts +4 -10
  361. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.js +2 -14
  362. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.js.map +1 -1
  363. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.d.ts +11 -11
  364. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.js +2 -2
  365. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.js.map +1 -1
  366. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/styles/CallWithChatCompositeStyles.d.ts +0 -5
  367. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/styles/CallWithChatCompositeStyles.js +0 -13
  368. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/styles/CallWithChatCompositeStyles.js.map +1 -1
  369. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.d.ts +0 -27
  370. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.js +1 -2
  371. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.js.map +1 -1
  372. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.d.ts +0 -2
  373. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js +49 -234
  374. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js.map +1 -1
  375. package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.d.ts +0 -20
  376. package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.js.map +1 -1
  377. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.d.ts +2 -6
  378. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.js +0 -36
  379. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.js.map +1 -1
  380. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/ChatAdapter.d.ts +2 -12
  381. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/ChatAdapter.js.map +1 -1
  382. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useHandlers.js +2 -13
  383. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useHandlers.js.map +1 -1
  384. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useSelector.d.ts +6 -0
  385. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useSelector.js +11 -0
  386. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useSelector.js.map +1 -0
  387. package/dist/dist-esm/react-composites/src/composites/ChatComposite/index.d.ts +0 -2
  388. package/dist/dist-esm/react-composites/src/composites/ChatComposite/index.js.map +1 -1
  389. package/dist/dist-esm/react-composites/src/composites/ChatComposite/selectors/baseSelectors.d.ts +12 -0
  390. package/dist/dist-esm/react-composites/src/composites/ChatComposite/selectors/baseSelectors.js +9 -0
  391. package/dist/dist-esm/react-composites/src/composites/ChatComposite/selectors/baseSelectors.js.map +1 -0
  392. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CommonCallControlBar.js +28 -15
  393. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CommonCallControlBar.js.map +1 -1
  394. package/dist/dist-esm/react-composites/src/composites/common/HiddenFocusStartPoint.js +4 -1
  395. package/dist/dist-esm/react-composites/src/composites/common/HiddenFocusStartPoint.js.map +1 -1
  396. package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js +1 -1
  397. package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map +1 -1
  398. package/dist/dist-esm/react-composites/src/composites/common/ModalLocalAndRemotePIP.js +5 -6
  399. package/dist/dist-esm/react-composites/src/composites/common/ModalLocalAndRemotePIP.js.map +1 -1
  400. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js +1 -2
  401. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js.map +1 -1
  402. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.d.ts +3 -0
  403. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js +4 -7
  404. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js.map +1 -1
  405. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.d.ts +2 -41
  406. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js +0 -21
  407. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js.map +1 -1
  408. package/dist/dist-esm/react-composites/src/composites/common/VideoEffectsPane.d.ts +2 -0
  409. package/dist/dist-esm/react-composites/src/composites/common/VideoEffectsPane.js +3 -4
  410. package/dist/dist-esm/react-composites/src/composites/common/VideoEffectsPane.js.map +1 -1
  411. package/dist/dist-esm/react-composites/src/composites/common/adapters.d.ts +0 -23
  412. package/dist/dist-esm/react-composites/src/composites/common/adapters.js.map +1 -1
  413. package/dist/dist-esm/react-composites/src/composites/common/constants.d.ts +0 -5
  414. package/dist/dist-esm/react-composites/src/composites/common/constants.js +0 -5
  415. package/dist/dist-esm/react-composites/src/composites/common/constants.js.map +1 -1
  416. package/dist/dist-esm/react-composites/src/composites/common/icons.d.ts +6 -32
  417. package/dist/dist-esm/react-composites/src/composites/common/icons.js +0 -2
  418. package/dist/dist-esm/react-composites/src/composites/common/icons.js.map +1 -1
  419. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependency.d.ts +8 -0
  420. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependency.js +24 -0
  421. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependency.js.map +1 -0
  422. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependencyLazy.d.ts +8 -0
  423. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependencyLazy.js +24 -0
  424. package/dist/dist-esm/react-composites/src/composites/common/resolveDeepNoiseSuppressionDependencyLazy.js.map +1 -0
  425. package/dist/dist-esm/react-composites/src/composites/common/types/CommonCallControlOptions.js.map +1 -1
  426. package/dist/dist-esm/react-composites/src/composites/common/utils.d.ts +0 -4
  427. package/dist/dist-esm/react-composites/src/composites/common/utils.js +0 -22
  428. package/dist/dist-esm/react-composites/src/composites/common/utils.js.map +1 -1
  429. package/dist/dist-esm/react-composites/src/composites/index.d.ts +2 -1
  430. package/dist/dist-esm/react-composites/src/composites/index.js +2 -0
  431. package/dist/dist-esm/react-composites/src/composites/index.js.map +1 -1
  432. package/dist/dist-esm/react-composites/src/composites/localization/locales/ar-SA/strings.json +2 -1
  433. package/dist/dist-esm/react-composites/src/composites/localization/locales/cs-CZ/strings.json +2 -1
  434. package/dist/dist-esm/react-composites/src/composites/localization/locales/cy-GB/strings.json +2 -1
  435. package/dist/dist-esm/react-composites/src/composites/localization/locales/de-DE/strings.json +2 -1
  436. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-GB/strings.json +2 -1
  437. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-US/strings.json +2 -1
  438. package/dist/dist-esm/react-composites/src/composites/localization/locales/es-ES/strings.json +2 -1
  439. package/dist/dist-esm/react-composites/src/composites/localization/locales/fi-FI/strings.json +2 -1
  440. package/dist/dist-esm/react-composites/src/composites/localization/locales/fr-FR/strings.json +2 -1
  441. package/dist/dist-esm/react-composites/src/composites/localization/locales/he-IL/strings.json +2 -1
  442. package/dist/dist-esm/react-composites/src/composites/localization/locales/it-IT/strings.json +2 -1
  443. package/dist/dist-esm/react-composites/src/composites/localization/locales/ja-JP/strings.json +2 -1
  444. package/dist/dist-esm/react-composites/src/composites/localization/locales/ko-KR/strings.json +1 -0
  445. package/dist/dist-esm/react-composites/src/composites/localization/locales/nb-NO/strings.json +2 -1
  446. package/dist/dist-esm/react-composites/src/composites/localization/locales/nl-NL/strings.json +2 -1
  447. package/dist/dist-esm/react-composites/src/composites/localization/locales/pl-PL/strings.json +2 -1
  448. package/dist/dist-esm/react-composites/src/composites/localization/locales/pt-BR/strings.json +2 -1
  449. package/dist/dist-esm/react-composites/src/composites/localization/locales/ru-RU/strings.json +2 -1
  450. package/dist/dist-esm/react-composites/src/composites/localization/locales/sv-SE/strings.json +2 -1
  451. package/dist/dist-esm/react-composites/src/composites/localization/locales/tr-TR/strings.json +2 -1
  452. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-CN/strings.json +2 -1
  453. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-TW/strings.json +2 -1
  454. package/package.json +8 -9
  455. package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-CK3wKmiQ.js +0 -202
  456. package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-CK3wKmiQ.js.map +0 -1
  457. package/dist/dist-cjs/communication-react/RichTextSendBoxWrapper-Duh89Mej.js +0 -50
  458. package/dist/dist-cjs/communication-react/RichTextSendBoxWrapper-Duh89Mej.js.map +0 -1
  459. package/dist/dist-cjs/communication-react/index-XC7Z08jO.js +0 -42425
  460. package/dist/dist-cjs/communication-react/index-XC7Z08jO.js.map +0 -1
  461. package/dist/dist-esm/acs-ui-common/src/dataConversion.d.ts +0 -6
  462. package/dist/dist-esm/acs-ui-common/src/dataConversion.js +0 -16
  463. package/dist/dist-esm/acs-ui-common/src/dataConversion.js.map +0 -1
  464. package/dist/dist-esm/acs-ui-common/src/removeImageTags.d.ts +0 -7
  465. package/dist/dist-esm/acs-ui-common/src/removeImageTags.js +0 -18
  466. package/dist/dist-esm/acs-ui-common/src/removeImageTags.js.map +0 -1
  467. package/dist/dist-esm/calling-stateful-client/src/BreakoutRoomsSubscriber.d.ts +0 -20
  468. package/dist/dist-esm/calling-stateful-client/src/BreakoutRoomsSubscriber.js +0 -118
  469. package/dist/dist-esm/calling-stateful-client/src/BreakoutRoomsSubscriber.js.map +0 -1
  470. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.d.ts +0 -17
  471. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.js +0 -33
  472. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.js.map +0 -1
  473. package/dist/dist-esm/chat-component-bindings/src/utils/getImageAttachmentsFromHTMLContent.d.ts +0 -6
  474. package/dist/dist-esm/chat-component-bindings/src/utils/getImageAttachmentsFromHTMLContent.js +0 -20
  475. package/dist/dist-esm/chat-component-bindings/src/utils/getImageAttachmentsFromHTMLContent.js.map +0 -1
  476. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.d.ts +0 -10
  477. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.js +0 -15
  478. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.js.map +0 -1
  479. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.d.ts +0 -24
  480. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js +0 -192
  481. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js.map +0 -1
  482. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.d.ts +0 -69
  483. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.js +0 -36
  484. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.js.map +0 -1
  485. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.d.ts +0 -75
  486. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.js +0 -67
  487. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.js.map +0 -1
  488. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.d.ts +0 -105
  489. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.js +0 -51
  490. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.js.map +0 -1
  491. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.d.ts +0 -86
  492. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.js +0 -39
  493. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.js.map +0 -1
  494. package/dist/dist-esm/react-components/src/components/MentionPopover.d.ts +0 -121
  495. package/dist/dist-esm/react-components/src/components/MentionPopover.js +0 -119
  496. package/dist/dist-esm/react-components/src/components/MentionPopover.js.map +0 -1
  497. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.d.ts +0 -9
  498. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.js +0 -29
  499. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.js.map +0 -1
  500. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.d.ts +0 -30
  501. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js +0 -98
  502. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js.map +0 -1
  503. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.d.ts +0 -12
  504. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.js +0 -23
  505. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.js.map +0 -1
  506. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.d.ts +0 -15
  507. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.js +0 -42
  508. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.js.map +0 -1
  509. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.d.ts +0 -24
  510. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.js +0 -64
  511. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.js.map +0 -1
  512. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.d.ts +0 -20
  513. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.js +0 -45
  514. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.js.map +0 -1
  515. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UndoRedoPlugin.d.ts +0 -14
  516. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UndoRedoPlugin.js +0 -42
  517. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UndoRedoPlugin.js.map +0 -1
  518. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.d.ts +0 -29
  519. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.js +0 -87
  520. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.js.map +0 -1
  521. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.d.ts +0 -58
  522. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js +0 -314
  523. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js.map +0 -1
  524. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.d.ts +0 -37
  525. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js +0 -78
  526. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js.map +0 -1
  527. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.d.ts +0 -211
  528. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js +0 -168
  529. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js.map +0 -1
  530. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.d.ts +0 -16
  531. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js +0 -75
  532. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js.map +0 -1
  533. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.d.ts +0 -19
  534. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js +0 -221
  535. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js.map +0 -1
  536. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.d.ts +0 -7
  537. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.js +0 -51
  538. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.js.map +0 -1
  539. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.d.ts +0 -15
  540. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.js +0 -64
  541. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.js.map +0 -1
  542. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.d.ts +0 -6
  543. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.js +0 -13
  544. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.js.map +0 -1
  545. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.d.ts +0 -56
  546. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js +0 -75
  547. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js.map +0 -1
  548. package/dist/dist-esm/react-components/src/components/SendBoxErrors.d.ts +0 -14
  549. package/dist/dist-esm/react-components/src/components/SendBoxErrors.js +0 -18
  550. package/dist/dist-esm/react-components/src/components/SendBoxErrors.js.map +0 -1
  551. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.d.ts +0 -24
  552. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.js +0 -550
  553. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.js.map +0 -1
  554. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.d.ts +0 -152
  555. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.js +0 -816
  556. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.js.map +0 -1
  557. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.d.ts +0 -58
  558. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.js +0 -144
  559. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.js.map +0 -1
  560. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.d.ts +0 -26
  561. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.js +0 -69
  562. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.js.map +0 -1
  563. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.d.ts +0 -82
  564. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js +0 -320
  565. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js.map +0 -1
  566. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.d.ts +0 -21
  567. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.js +0 -38
  568. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.js.map +0 -1
  569. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.d.ts +0 -38
  570. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.js +0 -99
  571. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.js.map +0 -1
  572. package/dist/dist-esm/react-components/src/components/styles/Stack.style.d.ts +0 -5
  573. package/dist/dist-esm/react-components/src/components/styles/Stack.style.js +0 -32
  574. package/dist/dist-esm/react-components/src/components/styles/Stack.style.js.map +0 -1
  575. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.d.ts +0 -26
  576. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.js +0 -69
  577. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.js.map +0 -1
  578. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.d.ts +0 -72
  579. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js +0 -174
  580. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js.map +0 -1
  581. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.d.ts +0 -33
  582. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.js +0 -116
  583. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.js.map +0 -1
  584. package/dist/dist-esm/react-components/src/components/utils/merge.d.ts +0 -7
  585. package/dist/dist-esm/react-components/src/components/utils/merge.js +0 -16
  586. package/dist/dist-esm/react-components/src/components/utils/merge.js.map +0 -1
  587. package/dist/dist-esm/react-components/src/theming/icons.styles.d.ts +0 -6
  588. package/dist/dist-esm/react-components/src/theming/icons.styles.js +0 -25
  589. package/dist/dist-esm/react-components/src/theming/icons.styles.js.map +0 -1
  590. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Banner.d.ts +0 -47
  591. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Banner.js +0 -48
  592. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/Banner.js.map +0 -1
  593. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/BreakoutRoomsBanner.d.ts +0 -11
  594. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/BreakoutRoomsBanner.js +0 -36
  595. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/BreakoutRoomsBanner.js.map +0 -1
  596. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.d.ts +0 -49
  597. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.js +0 -196
  598. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.js.map +0 -1
  599. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useCompositeStringsForNotificationStack.d.ts +0 -7
  600. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useCompositeStringsForNotificationStack.js +0 -14
  601. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useCompositeStringsForNotificationStack.js.map +0 -1
  602. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.d.ts +0 -15
  603. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.js +0 -41
  604. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.js.map +0 -1
  605. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.d.ts +0 -8
  606. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.js +0 -25
  607. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/parseTeamsUrl.js.map +0 -1
  608. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.d.ts +0 -15
  609. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.js +0 -23
  610. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.js.map +0 -1
  611. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.d.ts +0 -18
  612. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.js +0 -18
  613. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.js.map +0 -1
  614. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.d.ts +0 -49
  615. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.js +0 -44
  616. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.js.map +0 -1
  617. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.d.ts +0 -39
  618. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js +0 -253
  619. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js.map +0 -1
  620. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.d.ts +0 -80
  621. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.js +0 -36
  622. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.js.map +0 -1
  623. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.d.ts +0 -38
  624. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.js +0 -67
  625. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.js.map +0 -1
  626. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.d.ts +0 -5
  627. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.js +0 -5
  628. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.js.map +0 -1
  629. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/Timer.d.ts +0 -12
  630. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/Timer.js +0 -52
  631. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/Timer.js.map +0 -1
  632. package/dist/dist-esm/react-composites/src/composites/common/RichTextSendBoxWrapper.d.ts +0 -10
  633. package/dist/dist-esm/react-composites/src/composites/common/RichTextSendBoxWrapper.js +0 -16
  634. package/dist/dist-esm/react-composites/src/composites/common/RichTextSendBoxWrapper.js.map +0 -1
@@ -1,18 +0,0 @@
1
- /// <reference types="react" />
2
- import { ParticipantMenuItemsCallback } from "../../../../react-components/src";
3
- import { AvatarPersonaDataCallback } from '..';
4
- /**
5
- * Props for the chat screen people pane
6
- * @private
7
- */
8
- type ChatScreenPeoplePaneProps = {
9
- onFetchAvatarPersonaData?: AvatarPersonaDataCallback;
10
- onFetchParticipantMenuItems?: ParticipantMenuItemsCallback;
11
- isMobile?: boolean;
12
- };
13
- /**
14
- * @private
15
- */
16
- export declare const ChatScreenPeoplePane: (props: ChatScreenPeoplePaneProps) => JSX.Element;
17
- export {};
18
- //# sourceMappingURL=ChatScreenPeoplePane.d.ts.map
@@ -1,18 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { ParticipantList } from "../../../../react-components/src";
4
- import React from 'react';
5
- import { ParticipantContainer } from '../common/ParticipantContainer';
6
- import { useLocale } from '../localization';
7
- import { usePropsFor } from './hooks/usePropsFor';
8
- /**
9
- * @private
10
- */
11
- export const ChatScreenPeoplePane = (props) => {
12
- const { onFetchAvatarPersonaData, onFetchParticipantMenuItems, isMobile } = props;
13
- const locale = useLocale();
14
- const chatListHeader = locale.strings.chat.chatListHeader;
15
- const participantListProps = usePropsFor(ParticipantList);
16
- return React.createElement(ParticipantContainer, { participantListProps: participantListProps, title: chatListHeader, onFetchAvatarPersonaData: onFetchAvatarPersonaData, onFetchParticipantMenuItems: onFetchParticipantMenuItems, isMobile: isMobile });
17
- };
18
- //# sourceMappingURL=ChatScreenPeoplePane.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ChatScreenPeoplePane.js","sourceRoot":"","sources":["../../../../../../preprocess-dist/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAgC,yCAAmC;AAC3F,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAYlD;;GAEG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,KAAgC,EAAe,EAAE;IACpF,MAAM,EACJ,wBAAwB,EACxB,2BAA2B,EAC3B,QAAQ,EACT,GAAG,KAAK,CAAC;IACV,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAC3B,MAAM,cAAc,GAAG,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,cAAc,CAAC;IAC1D,MAAM,oBAAoB,GAAG,WAAW,CAAC,eAAe,CAAC,CAAC;IAC1D,OAAO,oBAAC,oBAAoB,IAAC,oBAAoB,EAAE,oBAAoB,EAAE,KAAK,EAAE,cAAc,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,2BAA2B,EAAE,2BAA2B,EAAE,QAAQ,EAAE,QAAQ,GAAI,CAAC;AACvO,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { ParticipantList, ParticipantMenuItemsCallback } from '@internal/react-components';\nimport React from 'react';\nimport { AvatarPersonaDataCallback } from '..';\nimport { ParticipantContainer } from '../common/ParticipantContainer';\nimport { useLocale } from '../localization';\nimport { usePropsFor } from './hooks/usePropsFor';\n\n/**\n * Props for the chat screen people pane\n * @private\n */\ntype ChatScreenPeoplePaneProps = {\n onFetchAvatarPersonaData?: AvatarPersonaDataCallback;\n onFetchParticipantMenuItems?: ParticipantMenuItemsCallback;\n isMobile?: boolean;\n};\n\n/**\n * @private\n */\nexport const ChatScreenPeoplePane = (props: ChatScreenPeoplePaneProps): JSX.Element => {\n const {\n onFetchAvatarPersonaData,\n onFetchParticipantMenuItems,\n isMobile\n } = props;\n const locale = useLocale();\n const chatListHeader = locale.strings.chat.chatListHeader;\n const participantListProps = usePropsFor(ParticipantList);\n return <ParticipantContainer participantListProps={participantListProps} title={chatListHeader} onFetchAvatarPersonaData={onFetchAvatarPersonaData} onFetchParticipantMenuItems={onFetchParticipantMenuItems} isMobile={isMobile} />;\n};"]}
@@ -1,49 +0,0 @@
1
- import { Action, AttachmentUpload, AttachmentUploadActionType, ProgressAction, CompleteAction, FailedAction, RemoveAction, ClearAction } from '../file-sharing/AttachmentUpload';
2
- /**
3
- * @private
4
- */
5
- export interface ImageAction {
6
- messageId: string;
7
- }
8
- /**
9
- * @private
10
- */
11
- interface ImageSetAction extends Action, ImageAction {
12
- type: AttachmentUploadActionType.Set;
13
- newUploads: AttachmentUpload[];
14
- }
15
- /**
16
- * @private
17
- */
18
- interface ImageProgressAction extends ProgressAction, ImageAction {
19
- }
20
- /**
21
- * @private
22
- */
23
- interface ImageCompleteAction extends CompleteAction, ImageAction {
24
- }
25
- /**
26
- * @private
27
- */
28
- interface ImageFailedAction extends FailedAction, ImageAction {
29
- }
30
- /**
31
- * @private
32
- */
33
- interface ImageRemoveAction extends RemoveAction, ImageAction {
34
- }
35
- /**
36
- * @private
37
- */
38
- interface ImageClearAction extends ClearAction, ImageAction {
39
- }
40
- /**
41
- * @private
42
- */
43
- export type ImageActions = ImageSetAction | ImageProgressAction | ImageCompleteAction | ImageFailedAction | ImageRemoveAction | ImageClearAction;
44
- /**
45
- * @internal
46
- */
47
- export declare const ImageUploadReducer: (state: Record<string, AttachmentUpload[]> | undefined, action: ImageActions) => Record<string, AttachmentUpload[]> | undefined;
48
- export {};
49
- //# sourceMappingURL=ImageUploadReducer.d.ts.map
@@ -1,44 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { AttachmentUploadActionType } from '../file-sharing/AttachmentUpload';
4
- /**
5
- * @internal
6
- */
7
- export const ImageUploadReducer = (state, action) => {
8
- const messageId = action.messageId;
9
- const messageState = state && state[messageId];
10
- switch (action.type) {
11
- case AttachmentUploadActionType.Set:
12
- if (!messageState || messageState.length === 0) {
13
- return Object.assign(Object.assign({}, state), { [messageId]: action.newUploads });
14
- }
15
- return Object.assign(Object.assign({}, state), { [messageId]: messageState.filter(v => !v.metadata.error).concat(action.newUploads) });
16
- case AttachmentUploadActionType.Completed:
17
- if (!messageState) {
18
- return state;
19
- }
20
- return Object.assign(Object.assign({}, state), { [messageId]: messageState.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { id: action.id, url: action.url, progress: 1 }) }) : v) });
21
- case AttachmentUploadActionType.Failed:
22
- if (!messageState) {
23
- return state;
24
- }
25
- return Object.assign(Object.assign({}, state), { [messageId]: messageState.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { error: {
26
- message: action.message
27
- } }) }) : v) });
28
- case AttachmentUploadActionType.Remove:
29
- if (!messageState) {
30
- return state;
31
- }
32
- return Object.assign(Object.assign({}, state), { [messageId]: messageState.filter(v => !v.metadata.error).filter(v => v.metadata.id !== action.id) });
33
- case AttachmentUploadActionType.Progress:
34
- if (!messageState) {
35
- return state;
36
- }
37
- return Object.assign(Object.assign({}, state), { [messageId]: messageState.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { progress: action.progress }) }) : v) });
38
- case AttachmentUploadActionType.Clear:
39
- return Object.assign(Object.assign({}, state), { [messageId]: [] });
40
- default:
41
- return state;
42
- }
43
- };
44
- //# sourceMappingURL=ImageUploadReducer.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ImageUploadReducer.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadReducer.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAA4B,0BAA0B,EAA2E,MAAM,kCAAkC,CAAC;AAsCjL;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,KAAqD,EAAE,MAAoB,EAAkD,EAAE;IAChK,MAAM,SAAS,GAAG,MAAM,CAAC,SAAS,CAAC;IACnC,MAAM,YAAY,GAAG,KAAK,IAAI,KAAK,CAAC,SAAS,CAAC,CAAC;IAC/C,QAAQ,MAAM,CAAC,IAAI,EAAE,CAAC;QACpB,KAAK,0BAA0B,CAAC,GAAG;YACjC,IAAI,CAAC,YAAY,IAAI,YAAY,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;gBAC/C,uCACK,KAAK,KACR,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC,UAAU,IAC9B;YACJ,CAAC;YACD,uCACK,KAAK,KACR,CAAC,SAAS,CAAC,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,IAClF;QACJ,KAAK,0BAA0B,CAAC,SAAS;YACvC,IAAI,CAAC,YAAY,EAAE,CAAC;gBAClB,OAAO,KAAK,CAAC;YACf,CAAC;YACD,uCACK,KAAK,KACR,CAAC,SAAS,CAAC,EAAE,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,iCAC1D,CAAC,KACJ,QAAQ,kCACH,CAAC,CAAC,QAAQ,KACb,EAAE,EAAE,MAAM,CAAC,EAAE,E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AAK,0BAA0B,CAAC,KAAK;YACnC,uCACK,KAAK,KACR,CAAC,SAAS,CAAC,EAAE,EAAE,IACf;QACJ;YACE,OAAO,KAAK,CAAC;IACjB,CAAC;AACH,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\nimport { Action, AttachmentUpload, AttachmentUploadActionType, ProgressAction, CompleteAction, FailedAction, RemoveAction, ClearAction } from '../file-sharing/AttachmentUpload';\n/**\n * @private\n */\nexport interface ImageAction {\n messageId: string;\n}\n/**\n * @private\n */\ninterface ImageSetAction extends Action, ImageAction {\n type: AttachmentUploadActionType.Set;\n newUploads: AttachmentUpload[];\n}\n/**\n * @private\n */\ninterface ImageProgressAction extends ProgressAction, ImageAction {}\n/**\n * @private\n */\ninterface ImageCompleteAction extends CompleteAction, ImageAction {}\n/**\n * @private\n */\ninterface ImageFailedAction extends FailedAction, ImageAction {}\n/**\n * @private\n */\ninterface ImageRemoveAction extends RemoveAction, ImageAction {}\n/**\n * @private\n */\ninterface ImageClearAction extends ClearAction, ImageAction {}\n/**\n * @private\n */\nexport type ImageActions = ImageSetAction | ImageProgressAction | ImageCompleteAction | ImageFailedAction | ImageRemoveAction | ImageClearAction;\n/**\n * @internal\n */\nexport const ImageUploadReducer = (state: Record<string, AttachmentUpload[]> | undefined, action: ImageActions): Record<string, AttachmentUpload[]> | undefined => {\n const messageId = action.messageId;\n const messageState = state && state[messageId];\n switch (action.type) {\n case AttachmentUploadActionType.Set:\n if (!messageState || messageState.length === 0) {\n return {\n ...state,\n [messageId]: action.newUploads\n };\n }\n return {\n ...state,\n [messageId]: messageState.filter(v => !v.metadata.error).concat(action.newUploads)\n };\n case AttachmentUploadActionType.Completed:\n if (!messageState) {\n return state;\n }\n return {\n ...state,\n [messageId]: messageState.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n id: action.id,\n url: action.url,\n progress: 1\n }\n } : v)\n };\n case AttachmentUploadActionType.Failed:\n if (!messageState) {\n return state;\n }\n return {\n ...state,\n [messageId]: messageState.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n error: {\n message: action.message\n }\n }\n } : v)\n };\n case AttachmentUploadActionType.Remove:\n if (!messageState) {\n return state;\n }\n return {\n ...state,\n [messageId]: messageState.filter(v => !v.metadata.error).filter(v => v.metadata.id !== action.id)\n };\n case AttachmentUploadActionType.Progress:\n if (!messageState) {\n return state;\n }\n return {\n ...state,\n [messageId]: messageState.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n progress: action.progress\n }\n } : v)\n };\n case AttachmentUploadActionType.Clear:\n return {\n ...state,\n [messageId]: []\n };\n default:\n return state;\n }\n};"]}
@@ -1,39 +0,0 @@
1
- import { AttachmentMetadataInProgress } from "../../../../../acs-ui-common/src";
2
- import { AttachmentUpload } from '../file-sharing/AttachmentUpload';
3
- import { ChatAdapter } from '../adapter/ChatAdapter';
4
- import { Dispatch } from 'react';
5
- import { ImageActions } from './ImageUploadReducer';
6
- import { ChatCompositeStrings } from '../Strings';
7
- /**
8
- * @private
9
- */
10
- export declare const getInlineImageData: (image: string) => Promise<Blob | undefined>;
11
- /**
12
- * @internal
13
- */
14
- export declare const getEditBoxMessagesInlineImages: (editBoxInlineImageUploads: Record<string, AttachmentUpload[]> | undefined) => Record<string, AttachmentMetadataInProgress[]> | undefined;
15
- /**
16
- * @internal
17
- */
18
- export declare const getSendBoxInlineImages: (sendBoxInlineImageUploads: Record<string, AttachmentUpload[]> | undefined) => AttachmentMetadataInProgress[] | undefined;
19
- /**
20
- * @internal
21
- */
22
- export declare const onInsertInlineImageForEditBox: (imageAttributes: Record<string, string>, fileName: string, messageId: string, adapter: ChatAdapter, handleEditBoxInlineImageUploadAction: Dispatch<ImageActions>, chatCompositeStrings: ChatCompositeStrings) => Promise<void>;
23
- /**
24
- * @internal
25
- */
26
- export declare const onInsertInlineImageForSendBox: (imageAttributes: Record<string, string>, fileName: string, adapter: ChatAdapter, handleSendBoxInlineImageUploadAction: Dispatch<ImageActions>, chatCompositeStrings: ChatCompositeStrings) => Promise<void>;
27
- /**
28
- * @internal
29
- */
30
- export declare const cancelInlineImageUpload: (imageAttributes: Record<string, string>, imageUploads: Record<string, AttachmentUpload[]> | undefined, messageId: string, inlineImageUploadActionHandler: Dispatch<ImageActions>, adapter: ChatAdapter) => void;
31
- /**
32
- * @internal
33
- */
34
- export declare const updateContentStringWithUploadedInlineImages: (content: string, imageUploads: Record<string, AttachmentUpload[]> | undefined, messageId?: string) => string;
35
- /**
36
- * @internal
37
- */
38
- export declare const getImageFileNameFromAttributes: (imageAttributes: Record<string, string>) => string;
39
- //# sourceMappingURL=ImageUploadUtils.d.ts.map
@@ -1,253 +0,0 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
- // Copyright (c) Microsoft Corporation.
11
- // Licensed under the MIT License.
12
- import { _IMAGE_ATTRIBUTE_INLINE_IMAGE_FILE_NAME_KEY } from "../../../../../acs-ui-common/src";
13
- import { AttachmentUploadActionType } from '../file-sharing/AttachmentUpload';
14
- import { _DEFAULT_INLINE_IMAGE_FILE_NAME, SEND_BOX_UPLOADS_KEY_VALUE } from '../../common/constants';
15
- import { nanoid } from 'nanoid';
16
- const MAX_INLINE_IMAGE_UPLOAD_SIZE_MB = 20;
17
- const fetchBlobData = (resource, options) => __awaiter(void 0, void 0, void 0, function* () {
18
- // default timeout is 30 seconds
19
- const { timeout = 30000, abortController } = options;
20
- const id = setTimeout(() => {
21
- abortController.abort();
22
- }, timeout);
23
- const response = yield fetch(resource, Object.assign(Object.assign({}, options), { signal: abortController.signal }));
24
- clearTimeout(id);
25
- return response;
26
- });
27
- /**
28
- * @private
29
- */
30
- export const getInlineImageData = (image) => __awaiter(void 0, void 0, void 0, function* () {
31
- if (image.startsWith('blob') || image.startsWith('http')) {
32
- try {
33
- const res = yield fetchBlobData(image, {
34
- abortController: new AbortController()
35
- });
36
- const blobImage = yield res.blob();
37
- return blobImage;
38
- }
39
- catch (error) {
40
- console.error('Error fetching image data', error);
41
- return;
42
- }
43
- }
44
- return;
45
- });
46
- /**
47
- * @internal
48
- */
49
- export const getEditBoxMessagesInlineImages = (editBoxInlineImageUploads) => {
50
- if (!editBoxInlineImageUploads) {
51
- return;
52
- }
53
- const messageIds = Object.keys(editBoxInlineImageUploads || {});
54
- const messagesInlineImagesWithProgress = {};
55
- messageIds.map(messageId => {
56
- const messageUploads = editBoxInlineImageUploads[messageId].map(upload => {
57
- return upload.metadata;
58
- });
59
- messagesInlineImagesWithProgress[messageId] = messageUploads;
60
- });
61
- return messagesInlineImagesWithProgress;
62
- };
63
- /**
64
- * @internal
65
- */
66
- export const getSendBoxInlineImages = (sendBoxInlineImageUploads) => {
67
- var _a;
68
- if (!sendBoxInlineImageUploads) {
69
- return;
70
- }
71
- return (_a = sendBoxInlineImageUploads[SEND_BOX_UPLOADS_KEY_VALUE]) === null || _a === void 0 ? void 0 : _a.map(upload => upload.metadata);
72
- };
73
- const inlineImageUploadHandler = (uploadTasks, adapter, strings) => __awaiter(void 0, void 0, void 0, function* () {
74
- var _a, _b, _c;
75
- for (const task of uploadTasks) {
76
- const uploadTask = task;
77
- const image = uploadTask.image;
78
- if (!image) {
79
- uploadTask.notifyUploadFailed(strings.uploadImageDataNotProvided);
80
- continue;
81
- }
82
- if (image && image.size > MAX_INLINE_IMAGE_UPLOAD_SIZE_MB * 1024 * 1024) {
83
- uploadTask.notifyUploadFailed(strings.uploadImageIsTooLarge.replace('{maxImageSize}', `${MAX_INLINE_IMAGE_UPLOAD_SIZE_MB}`));
84
- continue;
85
- }
86
- const SUPPORTED_FILES = ['jpg', 'jpeg', 'png', 'gif', 'heic', 'webp'];
87
- const imageExtension = (_b = (_a = task.metadata) === null || _a === void 0 ? void 0 : _a.name.split('.').pop()) !== null && _b !== void 0 ? _b : '';
88
- if (!SUPPORTED_FILES.includes(imageExtension)) {
89
- uploadTask.notifyUploadFailed(strings.uploadImageExtensionIsNotAllowed.replace('{imageExtension}', imageExtension));
90
- continue;
91
- }
92
- try {
93
- const response = yield adapter.uploadImage(image, (_c = task.metadata) === null || _c === void 0 ? void 0 : _c.name);
94
- // Use response id as the image src because we need to keep the original image id as a reference to find the image.
95
- // Also the html content we send to ChatSDK does not need image src,
96
- // it only need the response id to match the uploaded image, url is not needed.
97
- uploadTask.notifyUploadCompleted(task.metadata.id, response.id);
98
- }
99
- catch (error) {
100
- console.error(error);
101
- uploadTask.notifyUploadFailed(strings.uploadImageFailed);
102
- }
103
- }
104
- });
105
- const generateUploadTask = (imageAttributes, fileName, messageId, inlineImageUploadActionHandler) => __awaiter(void 0, void 0, void 0, function* () {
106
- const imageData = yield getInlineImageData(imageAttributes.src);
107
- if (!imageData) {
108
- return;
109
- }
110
- const taskId = nanoid();
111
- const uploadTask = {
112
- image: imageData,
113
- taskId,
114
- metadata: {
115
- id: imageAttributes.id,
116
- name: fileName,
117
- url: imageAttributes.src,
118
- progress: 0
119
- },
120
- notifyUploadProgressChanged: (value) => {
121
- inlineImageUploadActionHandler({
122
- type: AttachmentUploadActionType.Progress,
123
- taskId,
124
- progress: value,
125
- messageId
126
- });
127
- },
128
- notifyUploadCompleted: (id, url) => {
129
- inlineImageUploadActionHandler({
130
- type: AttachmentUploadActionType.Completed,
131
- taskId,
132
- id,
133
- url,
134
- messageId
135
- });
136
- },
137
- notifyUploadFailed: (message) => {
138
- inlineImageUploadActionHandler({
139
- type: AttachmentUploadActionType.Failed,
140
- taskId,
141
- message,
142
- messageId
143
- });
144
- // remove the failed upload task when error banner is auto dismissed after 10 seconds
145
- // so the banner won't be shown again on UI re-rendering.
146
- setTimeout(() => {
147
- inlineImageUploadActionHandler({
148
- type: AttachmentUploadActionType.Remove,
149
- id: taskId,
150
- messageId
151
- });
152
- }, 10 * 1000);
153
- }
154
- };
155
- return uploadTask;
156
- });
157
- /**
158
- * @internal
159
- */
160
- export const onInsertInlineImageForEditBox = (imageAttributes, fileName, messageId, adapter, handleEditBoxInlineImageUploadAction, chatCompositeStrings) => __awaiter(void 0, void 0, void 0, function* () {
161
- const uploadTask = yield generateUploadTask(imageAttributes, fileName, messageId, handleEditBoxInlineImageUploadAction);
162
- if (!uploadTask) {
163
- return;
164
- }
165
- handleEditBoxInlineImageUploadAction({
166
- type: AttachmentUploadActionType.Set,
167
- newUploads: [uploadTask],
168
- messageId
169
- });
170
- inlineImageUploadHandler([uploadTask], adapter, chatCompositeStrings);
171
- });
172
- /**
173
- * @internal
174
- */
175
- export const onInsertInlineImageForSendBox = (imageAttributes, fileName, adapter, handleSendBoxInlineImageUploadAction, chatCompositeStrings) => __awaiter(void 0, void 0, void 0, function* () {
176
- const uploadTask = yield generateUploadTask(imageAttributes, fileName, SEND_BOX_UPLOADS_KEY_VALUE, handleSendBoxInlineImageUploadAction);
177
- if (!uploadTask) {
178
- return;
179
- }
180
- handleSendBoxInlineImageUploadAction({
181
- type: AttachmentUploadActionType.Set,
182
- newUploads: [uploadTask],
183
- messageId: SEND_BOX_UPLOADS_KEY_VALUE
184
- });
185
- inlineImageUploadHandler([uploadTask], adapter, chatCompositeStrings);
186
- });
187
- /**
188
- * @internal
189
- */
190
- export const cancelInlineImageUpload = (imageAttributes, imageUploads, messageId, inlineImageUploadActionHandler, adapter) => {
191
- if (!imageUploads || !imageUploads[messageId]) {
192
- deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);
193
- return;
194
- }
195
- const imageUpload = imageUploads[messageId].find(upload => upload.metadata.id === imageAttributes.id);
196
- if (!imageUpload || !(imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id)) {
197
- deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);
198
- return;
199
- }
200
- inlineImageUploadActionHandler({
201
- type: AttachmentUploadActionType.Remove,
202
- id: imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.id,
203
- messageId
204
- });
205
- if ((imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.progress) === 1 && (imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.url)) {
206
- // The image id that we got back from the ChatSDK response is stored in the image src attribute,
207
- // while the metadata id is the internal image id that we assigned to the image when it was pasted in.
208
- deleteInlineImageFromServer(imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.metadata.url, adapter);
209
- }
210
- };
211
- const deleteInlineImageFromServer = (imageId, adapter) => {
212
- try {
213
- adapter.deleteImage(imageId);
214
- }
215
- catch (error) {
216
- console.error(error);
217
- }
218
- }; // This function is used to delete the inline image that existed before editing starts
219
- const deleteExistingInlineImageForEditBox = (imageId, messageId, adapter) => {
220
- messageId !== SEND_BOX_UPLOADS_KEY_VALUE && deleteInlineImageFromServer(imageId, adapter);
221
- };
222
- /**
223
- * @internal
224
- */
225
- export const updateContentStringWithUploadedInlineImages = (content, imageUploads, messageId = SEND_BOX_UPLOADS_KEY_VALUE) => {
226
- if (!imageUploads || !imageUploads[messageId]) {
227
- return content;
228
- }
229
- const messageUploads = imageUploads[messageId];
230
- const document = new DOMParser().parseFromString(content !== null && content !== void 0 ? content : '', 'text/html');
231
- document.querySelectorAll('img').forEach(img => {
232
- var _a;
233
- const uploadInlineImage = messageUploads.find(upload => !upload.metadata.error && upload.metadata.progress === 1 && upload.metadata.id === img.id);
234
- if (uploadInlineImage) {
235
- // ChatSDK uses the respond id provided by the upload response. We store the response id in the image src attribute previously.
236
- img.id = (_a = uploadInlineImage.metadata.url) !== null && _a !== void 0 ? _a : img.id;
237
- img.src = '';
238
- }
239
- });
240
- content = document.body.innerHTML;
241
- return content;
242
- };
243
- /**
244
- * @internal
245
- */
246
- export const getImageFileNameFromAttributes = (imageAttributes) => {
247
- const fileName = imageAttributes[_IMAGE_ATTRIBUTE_INLINE_IMAGE_FILE_NAME_KEY];
248
- if (!fileName || fileName === '' || fileName === 'undefined' || fileName === 'null') {
249
- return _DEFAULT_INLINE_IMAGE_FILE_NAME;
250
- }
251
- return fileName;
252
- };
253
- //# sourceMappingURL=ImageUploadUtils.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ImageUploadUtils.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAgC,2CAA2C,EAAE,yCAAgC;AACpH,OAAO,EAAoB,0BAA0B,EAAwB,MAAM,kCAAkC,CAAC;AACtH,OAAO,EAAE,+BAA+B,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AAIrG,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,MAAM,+BAA+B,GAAG,EAAE,CAAC;AAC3C,MAAM,aAAa,GAAG,CAAO,QAAgC,EAAE,OAI9D,EAAqB,EAAE;IACtB,gCAAgC;IAChC,MAAM,EACJ,OAAO,GAAG,KAAK,EACf,eAAe,EAChB,GAAG,OAAO,CAAC;IACZ,MAAM,EAAE,GAAG,UAAU,CAAC,GAAG,EAAE;QACzB,eAAe,CAAC,KAAK,EAAE,CAAC;IAC1B,CAAC,EAAE,OAAO,CAAC,CAAC;IACZ,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,QAAQ,kCAChC,OAAO,KACV,MAAM,EAAE,eAAe,CAAC,MAAM,IAC9B,CAAC;IACH,YAAY,CAAC,EAAE,CAAC,CAAC;IACjB,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAA,CAAC;AACF;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG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C,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,IAAI,MAAM,CAAC,QAAQ,CAAC,QAAQ,KAAK,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC;QACnJ,IAAI,iBAAiB,EAAE,CAAC;YACtB,+HAA+H;YAC/H,GAAG,CAAC,EAAE,GAAG,MAAA,iBAAiB,CAAC,QAAQ,CAAC,GAAG,mCAAI,GAAG,CAAC,EAAE,CAAC;YAClD,GAAG,CAAC,GAAG,GAAG,EAAE,CAAC;QACf,CAAC;IACH,CAAC,CAAC,CAAC;IACH,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC;IAClC,OAAO,OAAO,CAAC;AACjB,CAAC,CAAC;AACF;;GAEG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,eAAuC,EAAU,EAAE;IAChG,MAAM,QAAQ,GAAG,eAAe,CAAC,2CAA2C,CAAC,CAAC;IAC9E,IAAI,CAAC,QAAQ,IAAI,QAAQ,KAAK,EAAE,IAAI,QAAQ,KAAK,WAAW,IAAI,QAAQ,KAAK,MAAM,EAAE,CAAC;QACpF,OAAO,+BAA+B,CAAC;IACzC,CAAC;IACD,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\nimport { AttachmentMetadataInProgress, _IMAGE_ATTRIBUTE_INLINE_IMAGE_FILE_NAME_KEY } from '@internal/acs-ui-common';\nimport { AttachmentUpload, AttachmentUploadActionType, AttachmentUploadTask } from '../file-sharing/AttachmentUpload';\nimport { _DEFAULT_INLINE_IMAGE_FILE_NAME, SEND_BOX_UPLOADS_KEY_VALUE } from '../../common/constants';\nimport { ChatAdapter } from '../adapter/ChatAdapter';\nimport { Dispatch } from 'react';\nimport { ImageActions } from './ImageUploadReducer';\nimport { nanoid } from 'nanoid';\nimport { ChatCompositeStrings } from '../Strings';\nconst MAX_INLINE_IMAGE_UPLOAD_SIZE_MB = 20;\nconst fetchBlobData = async (resource: string | URL | Request, options: {\n timeout?: number;\n headers?: Headers;\n abortController: AbortController;\n}): Promise<Response> => {\n // default timeout is 30 seconds\n const {\n timeout = 30000,\n abortController\n } = options;\n const id = setTimeout(() => {\n abortController.abort();\n }, timeout);\n const response = await fetch(resource, {\n ...options,\n signal: abortController.signal\n });\n clearTimeout(id);\n return response;\n};\n/**\n * @private\n */\nexport const getInlineImageData = async (image: string): Promise<Blob | undefined> => {\n if (image.startsWith('blob') || image.startsWith('http')) {\n try {\n const res = await fetchBlobData(image, {\n abortController: new AbortController()\n });\n const blobImage = await res.blob();\n return blobImage;\n } catch (error) {\n console.error('Error fetching image data', error);\n return;\n }\n }\n return;\n};\n/**\n * @internal\n */\nexport const getEditBoxMessagesInlineImages = (editBoxInlineImageUploads: Record<string, AttachmentUpload[]> | undefined): Record<string, AttachmentMetadataInProgress[]> | undefined => {\n if (!editBoxInlineImageUploads) {\n return;\n }\n const messageIds = Object.keys(editBoxInlineImageUploads || {});\n const messagesInlineImagesWithProgress: Record<string, AttachmentMetadataInProgress[]> = {};\n messageIds.map(messageId => {\n const messageUploads = editBoxInlineImageUploads[messageId].map(upload => {\n return upload.metadata;\n });\n messagesInlineImagesWithProgress[messageId] = messageUploads;\n });\n return messagesInlineImagesWithProgress;\n};\n/**\n * @internal\n */\nexport const getSendBoxInlineImages = (sendBoxInlineImageUploads: Record<string, AttachmentUpload[]> | undefined): AttachmentMetadataInProgress[] | undefined => {\n if (!sendBoxInlineImageUploads) {\n return;\n }\n return sendBoxInlineImageUploads[SEND_BOX_UPLOADS_KEY_VALUE]?.map(upload => upload.metadata);\n};\nconst inlineImageUploadHandler = async (uploadTasks: AttachmentUpload[], adapter: ChatAdapter, strings: ChatCompositeStrings): Promise<void> => {\n for (const task of uploadTasks) {\n const uploadTask = task as AttachmentUploadTask;\n const image: Blob | undefined = uploadTask.image;\n if (!image) {\n uploadTask.notifyUploadFailed(strings.uploadImageDataNotProvided);\n continue;\n }\n if (image && image.size > MAX_INLINE_IMAGE_UPLOAD_SIZE_MB * 1024 * 1024) {\n uploadTask.notifyUploadFailed(strings.uploadImageIsTooLarge.replace('{maxImageSize}', `${MAX_INLINE_IMAGE_UPLOAD_SIZE_MB}`));\n continue;\n }\n const SUPPORTED_FILES: Array<string> = ['jpg', 'jpeg', 'png', 'gif', 'heic', 'webp'];\n const imageExtension = task.metadata?.name.split('.').pop() ?? '';\n if (!SUPPORTED_FILES.includes(imageExtension)) {\n uploadTask.notifyUploadFailed(strings.uploadImageExtensionIsNotAllowed.replace('{imageExtension}', imageExtension));\n continue;\n }\n try {\n const response = await adapter.uploadImage(image, task.metadata?.name);\n // Use response id as the image src because we need to keep the original image id as a reference to find the image.\n // Also the html content we send to ChatSDK does not need image src,\n // it only need the response id to match the uploaded image, url is not needed.\n uploadTask.notifyUploadCompleted(task.metadata.id, response.id);\n } catch (error) {\n console.error(error);\n uploadTask.notifyUploadFailed(strings.uploadImageFailed);\n }\n }\n};\nconst generateUploadTask = async (imageAttributes: Record<string, string>, fileName: string, messageId: string, inlineImageUploadActionHandler: Dispatch<ImageActions>): Promise<AttachmentUpload | undefined> => {\n const imageData = await getInlineImageData(imageAttributes.src);\n if (!imageData) {\n return;\n }\n const taskId = nanoid();\n const uploadTask: AttachmentUpload = {\n image: imageData,\n taskId,\n metadata: {\n id: imageAttributes.id,\n name: fileName,\n url: imageAttributes.src,\n progress: 0\n },\n notifyUploadProgressChanged: (value: number) => {\n inlineImageUploadActionHandler({\n type: AttachmentUploadActionType.Progress,\n taskId,\n progress: value,\n messageId\n });\n },\n notifyUploadCompleted: (id: string, url: string) => {\n inlineImageUploadActionHandler({\n type: AttachmentUploadActionType.Completed,\n taskId,\n id,\n url,\n messageId\n });\n },\n notifyUploadFailed: (message: string) => {\n inlineImageUploadActionHandler({\n type: AttachmentUploadActionType.Failed,\n taskId,\n message,\n messageId\n });\n // remove the failed upload task when error banner is auto dismissed after 10 seconds\n // so the banner won't be shown again on UI re-rendering.\n setTimeout(() => {\n inlineImageUploadActionHandler({\n type: AttachmentUploadActionType.Remove,\n id: taskId,\n messageId\n });\n }, 10 * 1000);\n }\n };\n return uploadTask;\n};\n/**\n * @internal\n */\nexport const onInsertInlineImageForEditBox = async (imageAttributes: Record<string, string>, fileName: string, messageId: string, adapter: ChatAdapter, handleEditBoxInlineImageUploadAction: Dispatch<ImageActions>, chatCompositeStrings: ChatCompositeStrings): Promise<void> => {\n const uploadTask: AttachmentUpload | undefined = await generateUploadTask(imageAttributes, fileName, messageId, handleEditBoxInlineImageUploadAction);\n if (!uploadTask) {\n return;\n }\n handleEditBoxInlineImageUploadAction({\n type: AttachmentUploadActionType.Set,\n newUploads: [uploadTask],\n messageId\n });\n inlineImageUploadHandler([uploadTask], adapter, chatCompositeStrings);\n};\n/**\n * @internal\n */\nexport const onInsertInlineImageForSendBox = async (imageAttributes: Record<string, string>, fileName: string, adapter: ChatAdapter, handleSendBoxInlineImageUploadAction: Dispatch<ImageActions>, chatCompositeStrings: ChatCompositeStrings): Promise<void> => {\n const uploadTask: AttachmentUpload | undefined = await generateUploadTask(imageAttributes, fileName, SEND_BOX_UPLOADS_KEY_VALUE, handleSendBoxInlineImageUploadAction);\n if (!uploadTask) {\n return;\n }\n handleSendBoxInlineImageUploadAction({\n type: AttachmentUploadActionType.Set,\n newUploads: [uploadTask],\n messageId: SEND_BOX_UPLOADS_KEY_VALUE\n });\n inlineImageUploadHandler([uploadTask], adapter, chatCompositeStrings);\n};\n/**\n * @internal\n */\nexport const cancelInlineImageUpload = (imageAttributes: Record<string, string>, imageUploads: Record<string, AttachmentUpload[]> | undefined, messageId: string, inlineImageUploadActionHandler: Dispatch<ImageActions>, adapter: ChatAdapter): void => {\n if (!imageUploads || !imageUploads[messageId]) {\n deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);\n return;\n }\n const imageUpload = imageUploads[messageId].find(upload => upload.metadata.id === imageAttributes.id);\n if (!imageUpload || !imageUpload?.metadata.id) {\n deleteExistingInlineImageForEditBox(imageAttributes.id, messageId, adapter);\n return;\n }\n inlineImageUploadActionHandler({\n type: AttachmentUploadActionType.Remove,\n id: imageUpload?.metadata.id,\n messageId\n });\n if (imageUpload?.metadata.progress === 1 && imageUpload?.metadata.url) {\n // The image id that we got back from the ChatSDK response is stored in the image src attribute,\n // while the metadata id is the internal image id that we assigned to the image when it was pasted in.\n deleteInlineImageFromServer(imageUpload?.metadata.url, adapter);\n }\n};\nconst deleteInlineImageFromServer = (imageId: string, adapter: ChatAdapter): void => {\n try {\n adapter.deleteImage(imageId);\n } catch (error) {\n console.error(error);\n }\n}; // This function is used to delete the inline image that existed before editing starts\nconst deleteExistingInlineImageForEditBox = (imageId: string, messageId: string, adapter: ChatAdapter): void => {\n messageId !== SEND_BOX_UPLOADS_KEY_VALUE && deleteInlineImageFromServer(imageId, adapter);\n};\n/**\n * @internal\n */\nexport const updateContentStringWithUploadedInlineImages = (content: string, imageUploads: Record<string, AttachmentUpload[]> | undefined, messageId: string = SEND_BOX_UPLOADS_KEY_VALUE): string => {\n if (!imageUploads || !imageUploads[messageId]) {\n return content;\n }\n const messageUploads = imageUploads[messageId];\n const document = new DOMParser().parseFromString(content ?? '', 'text/html');\n document.querySelectorAll('img').forEach(img => {\n const uploadInlineImage = messageUploads.find(upload => !upload.metadata.error && upload.metadata.progress === 1 && upload.metadata.id === img.id);\n if (uploadInlineImage) {\n // ChatSDK uses the respond id provided by the upload response. We store the response id in the image src attribute previously.\n img.id = uploadInlineImage.metadata.url ?? img.id;\n img.src = '';\n }\n });\n content = document.body.innerHTML;\n return content;\n};\n/**\n * @internal\n */\nexport const getImageFileNameFromAttributes = (imageAttributes: Record<string, string>): string => {\n const fileName = imageAttributes[_IMAGE_ATTRIBUTE_INLINE_IMAGE_FILE_NAME_KEY];\n if (!fileName || fileName === '' || fileName === 'undefined' || fileName === 'null') {\n return _DEFAULT_INLINE_IMAGE_FILE_NAME;\n }\n return fileName;\n};"]}
@@ -1,80 +0,0 @@
1
- import { AttachmentUploadTask, AttachmentSelectionHandler, AttachmentActionHandler } from "../../../../../react-components/src";
2
- import { AttachmentMetadata, AttachmentMetadataInProgress, AttachmentProgressError } from "../../../../../acs-ui-common/src";
3
- /**
4
- * @internal
5
- */
6
- export interface AttachmentUpload extends AttachmentUploadTask {
7
- metadata: AttachmentMetadataInProgress;
8
- }
9
- /**
10
- * @private
11
- */
12
- export declare enum AttachmentUploadActionType {
13
- Set = "set",
14
- Progress = "progress",
15
- Completed = "completed",
16
- Failed = "failed",
17
- Remove = "remove",
18
- Clear = "clear"
19
- }
20
- /**
21
- * @private
22
- */
23
- export interface Action {
24
- type: AttachmentUploadActionType;
25
- }
26
- /**
27
- * @private
28
- */
29
- interface SetAction extends Action {
30
- type: AttachmentUploadActionType.Set;
31
- newUploads: AttachmentUpload[];
32
- }
33
- /**
34
- * @private
35
- */
36
- export interface ProgressAction extends Action {
37
- type: AttachmentUploadActionType.Progress;
38
- taskId: string;
39
- progress: number;
40
- }
41
- /**
42
- * @private
43
- */
44
- export interface CompleteAction extends Action {
45
- type: AttachmentUploadActionType.Completed;
46
- taskId: string;
47
- id: string;
48
- url: string;
49
- }
50
- /**
51
- * @private
52
- */
53
- export interface FailedAction extends Action {
54
- type: AttachmentUploadActionType.Failed;
55
- taskId: string;
56
- message: string;
57
- }
58
- /**
59
- * @private
60
- */
61
- export interface RemoveAction extends Action {
62
- type: AttachmentUploadActionType.Remove;
63
- id: string;
64
- }
65
- /**
66
- * @private
67
- */
68
- export interface ClearAction extends Action {
69
- type: AttachmentUploadActionType.Clear;
70
- }
71
- /**
72
- * @private
73
- */
74
- type Actions = SetAction | ProgressAction | CompleteAction | FailedAction | RemoveAction | ClearAction;
75
- /**
76
- * @internal
77
- */
78
- export declare const AttachmentUploadReducer: (state: AttachmentUpload[], action: Actions) => AttachmentUpload[];
79
- export type { AttachmentMetadata, AttachmentSelectionHandler, AttachmentActionHandler, AttachmentUploadTask, AttachmentProgressError };
80
- //# sourceMappingURL=AttachmentUpload.d.ts.map
@@ -1,36 +0,0 @@
1
- /**
2
- * @private
3
- */
4
- export var AttachmentUploadActionType;
5
- (function (AttachmentUploadActionType) {
6
- AttachmentUploadActionType["Set"] = "set";
7
- AttachmentUploadActionType["Progress"] = "progress";
8
- AttachmentUploadActionType["Completed"] = "completed";
9
- AttachmentUploadActionType["Failed"] = "failed";
10
- AttachmentUploadActionType["Remove"] = "remove";
11
- AttachmentUploadActionType["Clear"] = "clear";
12
- })(AttachmentUploadActionType || (AttachmentUploadActionType = {}));
13
- /**
14
- * @internal
15
- */
16
- export const AttachmentUploadReducer = (state, action) => {
17
- switch (action.type) {
18
- case AttachmentUploadActionType.Set:
19
- return state.filter(v => !v.metadata.error).concat(action.newUploads);
20
- case AttachmentUploadActionType.Completed:
21
- return state.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { id: action.id, url: action.url, progress: 1 }) }) : v);
22
- case AttachmentUploadActionType.Failed:
23
- return state.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { error: {
24
- message: action.message
25
- } }) }) : v);
26
- case AttachmentUploadActionType.Remove:
27
- return state.filter(v => !v.metadata.error).filter(v => v.metadata.id !== action.id);
28
- case AttachmentUploadActionType.Progress:
29
- return state.map(v => v.taskId === action.taskId ? Object.assign(Object.assign({}, v), { metadata: Object.assign(Object.assign({}, v.metadata), { progress: action.progress }) }) : v);
30
- case AttachmentUploadActionType.Clear:
31
- return [];
32
- default:
33
- return state;
34
- }
35
- };
36
- //# sourceMappingURL=AttachmentUpload.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AttachmentUpload.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.ts"],"names":[],"mappings":"AAWA;;GAEG;AACH,MAAM,CAAN,IAAY,0BAOX;AAPD,WAAY,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Q,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,KAAK,MAAM,CAAC,EAAE,CAAC,CAAC;QACvF,KAAK,0BAA0B,CAAC,QAAQ;YACtC,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,iCAC7C,CAAC,KACJ,QAAQ,kCACH,CAAC,CAAC,QAAQ,KACb,QAAQ,EAAE,MAAM,CAAC,QAAQ,OAE3B,CAAC,CAAC,CAAC,CAAC,CAAC;QACT,KAAK,0BAA0B,CAAC,KAAK;YACnC,OAAO,EAAE,CAAC;QACZ;YACE,OAAO,KAAK,CAAC;IACjB,CAAC;AACH,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\nimport { AttachmentUploadTask, AttachmentSelectionHandler, AttachmentActionHandler } from '@internal/react-components';\nimport { AttachmentMetadata, AttachmentMetadataInProgress, AttachmentProgressError } from '@internal/acs-ui-common';\n/**\n * @internal\n */\nexport interface AttachmentUpload extends AttachmentUploadTask {\n metadata: AttachmentMetadataInProgress;\n}\n\n/**\n * @private\n */\nexport enum AttachmentUploadActionType {\n Set = 'set',\n Progress = 'progress',\n Completed = 'completed',\n Failed = 'failed',\n Remove = 'remove',\n Clear = 'clear',\n}\n/**\n * @private\n */\nexport interface Action {\n type: AttachmentUploadActionType;\n}\n/**\n * @private\n */\ninterface SetAction extends Action {\n type: AttachmentUploadActionType.Set;\n newUploads: AttachmentUpload[];\n}\n/**\n * @private\n */\nexport interface ProgressAction extends Action {\n type: AttachmentUploadActionType.Progress;\n taskId: string;\n progress: number;\n}\n/**\n * @private\n */\nexport interface CompleteAction extends Action {\n type: AttachmentUploadActionType.Completed;\n taskId: string;\n id: string;\n url: string;\n}\n/**\n * @private\n */\nexport interface FailedAction extends Action {\n type: AttachmentUploadActionType.Failed;\n taskId: string;\n message: string;\n}\n/**\n * @private\n */\nexport interface RemoveAction extends Action {\n type: AttachmentUploadActionType.Remove;\n id: string;\n}\n/**\n * @private\n */\nexport interface ClearAction extends Action {\n type: AttachmentUploadActionType.Clear;\n}\n/**\n * @private\n */\ntype Actions = SetAction | ProgressAction | CompleteAction | FailedAction | RemoveAction | ClearAction;\n/**\n * @internal\n */\nexport const AttachmentUploadReducer = (state: AttachmentUpload[], action: Actions): AttachmentUpload[] => {\n switch (action.type) {\n case AttachmentUploadActionType.Set:\n return state.filter(v => !v.metadata.error).concat(action.newUploads);\n case AttachmentUploadActionType.Completed:\n return state.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n id: action.id,\n url: action.url,\n progress: 1\n }\n } : v);\n case AttachmentUploadActionType.Failed:\n return state.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n error: {\n message: action.message\n }\n }\n } : v);\n case AttachmentUploadActionType.Remove:\n return state.filter(v => !v.metadata.error).filter(v => v.metadata.id !== action.id);\n case AttachmentUploadActionType.Progress:\n return state.map(v => v.taskId === action.taskId ? {\n ...v,\n metadata: {\n ...v.metadata,\n progress: action.progress\n }\n } : v);\n case AttachmentUploadActionType.Clear:\n return [];\n default:\n return state;\n }\n};\nexport type { AttachmentMetadata, AttachmentSelectionHandler, AttachmentActionHandler, AttachmentUploadTask, AttachmentProgressError };"]}