@azure/communication-react 1.18.0-beta.1 → 1.18.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (643) hide show
  1. package/dist/communication-react.d.ts +508 -1758
  2. package/dist/dist-cjs/communication-react/index.js +34347 -159
  3. package/dist/dist-cjs/communication-react/index.js.map +1 -1
  4. package/dist/dist-esm/acs-ui-common/src/common.js +10 -2
  5. package/dist/dist-esm/acs-ui-common/src/common.js.map +1 -1
  6. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
  7. package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
  8. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.d.ts +4 -5
  9. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js +6 -11
  10. package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js.map +1 -1
  11. package/dist/dist-esm/calling-component-bindings/src/callControlSelectors.d.ts +0 -12
  12. package/dist/dist-esm/calling-component-bindings/src/callControlSelectors.js +1 -13
  13. package/dist/dist-esm/calling-component-bindings/src/callControlSelectors.js.map +1 -1
  14. package/dist/dist-esm/calling-component-bindings/src/errorBarSelector.js +0 -5
  15. package/dist/dist-esm/calling-component-bindings/src/errorBarSelector.js.map +1 -1
  16. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.d.ts +0 -8
  17. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.js +0 -14
  18. package/dist/dist-esm/calling-component-bindings/src/handlers/createCommonHandlers.js.map +1 -1
  19. package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js +1 -15
  20. package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js.map +1 -1
  21. package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js +1 -27
  22. package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js.map +1 -1
  23. package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.d.ts +3 -3
  24. package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.js +11 -11
  25. package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.js.map +1 -1
  26. package/dist/dist-esm/calling-component-bindings/src/index.d.ts +2 -2
  27. package/dist/dist-esm/calling-component-bindings/src/index.js +2 -2
  28. package/dist/dist-esm/calling-component-bindings/src/index.js.map +1 -1
  29. package/dist/dist-esm/calling-component-bindings/src/notificationStackSelector.d.ts +23 -0
  30. package/dist/dist-esm/calling-component-bindings/src/notificationStackSelector.js +201 -0
  31. package/dist/dist-esm/calling-component-bindings/src/notificationStackSelector.js.map +1 -0
  32. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.d.ts +0 -1
  33. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js +2 -8
  34. package/dist/dist-esm/calling-component-bindings/src/participantListSelector.js.map +1 -1
  35. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.d.ts +0 -7
  36. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js +0 -12
  37. package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js.map +1 -1
  38. package/dist/dist-esm/calling-component-bindings/src/utils/videoGalleryUtils.js +0 -3
  39. package/dist/dist-esm/calling-component-bindings/src/utils/videoGalleryUtils.js.map +1 -1
  40. package/dist/dist-esm/calling-component-bindings/src/videoGallerySelector.js +0 -3
  41. package/dist/dist-esm/calling-component-bindings/src/videoGallerySelector.js.map +1 -1
  42. package/dist/dist-esm/calling-stateful-client/src/BetaToStableTypes.d.ts +1 -5
  43. package/dist/dist-esm/calling-stateful-client/src/BetaToStableTypes.js.map +1 -1
  44. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarative.d.ts +1 -15
  45. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarative.js.map +1 -1
  46. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js +0 -5
  47. package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js.map +1 -1
  48. package/dist/dist-esm/calling-stateful-client/src/CallClientState.d.ts +23 -58
  49. package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
  50. package/dist/dist-esm/calling-stateful-client/src/CallContext.d.ts +3 -12
  51. package/dist/dist-esm/calling-stateful-client/src/CallContext.js +16 -69
  52. package/dist/dist-esm/calling-stateful-client/src/CallContext.js.map +1 -1
  53. package/dist/dist-esm/calling-stateful-client/src/CallDeclarativeCommon.js +0 -68
  54. package/dist/dist-esm/calling-stateful-client/src/CallDeclarativeCommon.js.map +1 -1
  55. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.d.ts +1 -3
  56. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js +16 -28
  57. package/dist/dist-esm/calling-stateful-client/src/CallSubscriber.js.map +1 -1
  58. package/dist/dist-esm/calling-stateful-client/src/CaptionsSubscriber.d.ts +0 -17
  59. package/dist/dist-esm/calling-stateful-client/src/CaptionsSubscriber.js +3 -61
  60. package/dist/dist-esm/calling-stateful-client/src/CaptionsSubscriber.js.map +1 -1
  61. package/dist/dist-esm/calling-stateful-client/src/Converter.d.ts +0 -5
  62. package/dist/dist-esm/calling-stateful-client/src/Converter.js +6 -17
  63. package/dist/dist-esm/calling-stateful-client/src/Converter.js.map +1 -1
  64. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.d.ts +0 -1
  65. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.js +0 -11
  66. package/dist/dist-esm/calling-stateful-client/src/RecordingSubscriber.js.map +1 -1
  67. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.d.ts +9 -19
  68. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js +2 -20
  69. package/dist/dist-esm/calling-stateful-client/src/StatefulCallClient.js.map +1 -1
  70. package/dist/dist-esm/calling-stateful-client/src/TeamsCallAgentDeclarative.d.ts +3 -4
  71. package/dist/dist-esm/calling-stateful-client/src/TeamsCallAgentDeclarative.js +2 -0
  72. package/dist/dist-esm/calling-stateful-client/src/TeamsCallAgentDeclarative.js.map +1 -1
  73. package/dist/dist-esm/calling-stateful-client/src/TeamsCallDeclarative.js +0 -18
  74. package/dist/dist-esm/calling-stateful-client/src/TeamsCallDeclarative.js.map +1 -1
  75. package/dist/dist-esm/calling-stateful-client/src/TypeGuards.d.ts +2 -2
  76. package/dist/dist-esm/calling-stateful-client/src/TypeGuards.js.map +1 -1
  77. package/dist/dist-esm/calling-stateful-client/src/index-public.d.ts +2 -3
  78. package/dist/dist-esm/calling-stateful-client/src/index-public.js.map +1 -1
  79. package/dist/dist-esm/calling-stateful-client/src/index.d.ts +1 -1
  80. package/dist/dist-esm/calling-stateful-client/src/index.js.map +1 -1
  81. package/dist/dist-esm/chat-component-bindings/src/handlers/createHandlers.d.ts +2 -3
  82. package/dist/dist-esm/chat-component-bindings/src/handlers/createHandlers.js +2 -12
  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 -5
  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 +36 -37
  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 -1
  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 -3
  94. package/dist/dist-esm/chat-stateful-client/src/EventSubscriber.js.map +1 -1
  95. package/dist/dist-esm/chat-stateful-client/src/ResourceDownloadQueue.js +3 -0
  96. package/dist/dist-esm/chat-stateful-client/src/ResourceDownloadQueue.js.map +1 -1
  97. package/dist/dist-esm/communication-react/src/index.d.ts +4 -28
  98. package/dist/dist-esm/communication-react/src/index.js +2 -14
  99. package/dist/dist-esm/communication-react/src/index.js.map +1 -1
  100. package/dist/dist-esm/react-components/src/components/Announcer/AnnouncerMessage.js +1 -1
  101. package/dist/dist-esm/react-components/src/components/Announcer/AnnouncerMessage.js.map +1 -1
  102. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCard.js +5 -4
  103. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCard.js.map +1 -1
  104. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCardGroup.d.ts +1 -0
  105. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCardGroup.js +3 -3
  106. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentCardGroup.js.map +1 -1
  107. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.d.ts +0 -2
  108. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.js +1 -14
  109. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentDownloadCards.js.map +1 -1
  110. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentUploadCards.d.ts +4 -0
  111. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentUploadCards.js +16 -19
  112. package/dist/dist-esm/react-components/src/components/Attachment/AttachmentUploadCards.js.map +1 -1
  113. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.d.ts +1 -7
  114. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js +2 -10
  115. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js.map +1 -1
  116. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.d.ts +0 -11
  117. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.js +2 -35
  118. package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageContent.js.map +1 -1
  119. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.d.ts +1 -8
  120. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.js +5 -13
  121. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/ChatMessageComponentAsMessageBubble.js.map +1 -1
  122. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.d.ts +1 -2
  123. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.js +7 -15
  124. package/dist/dist-esm/react-components/src/components/ChatMessage/MessageComponents/FluentChatMessageComponent.js.map +1 -1
  125. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.d.ts +1 -4
  126. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.js +6 -40
  127. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBox.js.map +1 -1
  128. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.d.ts +1 -16
  129. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js +0 -22
  130. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js.map +1 -1
  131. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.d.ts +2 -21
  132. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js +6 -21
  133. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js.map +1 -1
  134. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.d.ts +1 -8
  135. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.js +6 -14
  136. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponentAsMessageBubble.js.map +1 -1
  137. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js +6 -19
  138. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js.map +1 -1
  139. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js +2 -2
  140. package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js.map +1 -1
  141. package/dist/dist-esm/react-components/src/components/ErrorBar.d.ts +4 -0
  142. package/dist/dist-esm/react-components/src/components/ErrorBar.js +3 -3
  143. package/dist/dist-esm/react-components/src/components/ErrorBar.js.map +1 -1
  144. package/dist/dist-esm/react-components/src/components/ImageOverlay.js +3 -7
  145. package/dist/dist-esm/react-components/src/components/ImageOverlay.js.map +1 -1
  146. package/dist/dist-esm/react-components/src/components/InputBoxButton.d.ts +1 -0
  147. package/dist/dist-esm/react-components/src/components/InputBoxButton.js +2 -2
  148. package/dist/dist-esm/react-components/src/components/InputBoxButton.js.map +1 -1
  149. package/dist/dist-esm/react-components/src/components/InputBoxComponent.d.ts +0 -2
  150. package/dist/dist-esm/react-components/src/components/InputBoxComponent.js +0 -18
  151. package/dist/dist-esm/react-components/src/components/InputBoxComponent.js.map +1 -1
  152. package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.d.ts +80 -0
  153. package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js +115 -0
  154. package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js.map +1 -0
  155. package/dist/dist-esm/react-components/src/components/MessageStatusIndicatorInternal.js +1 -1
  156. package/dist/dist-esm/react-components/src/components/MessageStatusIndicatorInternal.js.map +1 -1
  157. package/dist/dist-esm/react-components/src/components/MessageThread.d.ts +5 -50
  158. package/dist/dist-esm/react-components/src/components/MessageThread.js +3 -30
  159. package/dist/dist-esm/react-components/src/components/MessageThread.js.map +1 -1
  160. package/dist/dist-esm/react-components/src/components/{NotificationBar.d.ts → Notification.d.ts} +13 -13
  161. package/dist/dist-esm/react-components/src/components/{NotificationBar.js → Notification.js} +7 -7
  162. package/dist/dist-esm/react-components/src/components/Notification.js.map +1 -0
  163. package/dist/dist-esm/react-components/src/components/{Notifications.d.ts → NotificationStack.d.ts} +109 -73
  164. package/dist/dist-esm/react-components/src/components/NotificationStack.js +57 -0
  165. package/dist/dist-esm/react-components/src/components/NotificationStack.js.map +1 -0
  166. package/dist/dist-esm/react-components/src/components/ParticipantItem.d.ts +0 -13
  167. package/dist/dist-esm/react-components/src/components/ParticipantItem.js +0 -3
  168. package/dist/dist-esm/react-components/src/components/ParticipantItem.js.map +1 -1
  169. package/dist/dist-esm/react-components/src/components/ParticipantList.d.ts +0 -15
  170. package/dist/dist-esm/react-components/src/components/ParticipantList.js +4 -21
  171. package/dist/dist-esm/react-components/src/components/ParticipantList.js.map +1 -1
  172. package/dist/dist-esm/react-components/src/components/RemoteVideoTile.js +1 -3
  173. package/dist/dist-esm/react-components/src/components/RemoteVideoTile.js.map +1 -1
  174. package/dist/dist-esm/react-components/src/components/ResponsiveHorizontalGallery.js +5 -1
  175. package/dist/dist-esm/react-components/src/components/ResponsiveHorizontalGallery.js.map +1 -1
  176. package/dist/dist-esm/react-components/src/components/ResponsiveVerticalGallery.js +5 -1
  177. package/dist/dist-esm/react-components/src/components/ResponsiveVerticalGallery.js.map +1 -1
  178. package/dist/dist-esm/react-components/src/components/SendBox.d.ts +1 -47
  179. package/dist/dist-esm/react-components/src/components/SendBox.js +8 -90
  180. package/dist/dist-esm/react-components/src/components/SendBox.js.map +1 -1
  181. package/dist/dist-esm/react-components/src/components/TroubleshootingGuideErrorBar.js +1 -1
  182. package/dist/dist-esm/react-components/src/components/TroubleshootingGuideErrorBar.js.map +1 -1
  183. package/dist/dist-esm/react-components/src/components/UnsupportedBrowser.js +0 -2
  184. package/dist/dist-esm/react-components/src/components/UnsupportedBrowser.js.map +1 -1
  185. package/dist/dist-esm/react-components/src/components/UnsupportedBrowserVersion.js +0 -2
  186. package/dist/dist-esm/react-components/src/components/UnsupportedBrowserVersion.js.map +1 -1
  187. package/dist/dist-esm/react-components/src/components/UnsupportedEnvironment.js +0 -24
  188. package/dist/dist-esm/react-components/src/components/UnsupportedEnvironment.js.map +1 -1
  189. package/dist/dist-esm/react-components/src/components/UnsupportedOperatingSystem.js +0 -2
  190. package/dist/dist-esm/react-components/src/components/UnsupportedOperatingSystem.js.map +1 -1
  191. package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js +3 -15
  192. package/dist/dist-esm/react-components/src/components/VideoGallery/utils/videoGalleryLayoutUtils.js.map +1 -1
  193. package/dist/dist-esm/react-components/src/components/VideoGallery.js +1 -2
  194. package/dist/dist-esm/react-components/src/components/VideoGallery.js.map +1 -1
  195. package/dist/dist-esm/react-components/src/components/VideoTile.d.ts +0 -8
  196. package/dist/dist-esm/react-components/src/components/VideoTile.js +1 -7
  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 +4 -20
  199. package/dist/dist-esm/react-components/src/components/index.js +8 -15
  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/AttachmentCard.styles.js +10 -0
  203. package/dist/dist-esm/react-components/src/components/styles/AttachmentCard.styles.js.map +1 -1
  204. package/dist/dist-esm/react-components/src/components/styles/AttachmentCardGroup.styles.d.ts +5 -1
  205. package/dist/dist-esm/react-components/src/components/styles/AttachmentCardGroup.styles.js +8 -0
  206. package/dist/dist-esm/react-components/src/components/styles/AttachmentCardGroup.styles.js.map +1 -1
  207. package/dist/dist-esm/react-components/src/components/styles/Common.style.d.ts +4 -0
  208. package/dist/dist-esm/react-components/src/components/styles/Common.style.js +4 -0
  209. package/dist/dist-esm/react-components/src/components/styles/Common.style.js.map +1 -1
  210. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.d.ts +5 -3
  211. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.js +40 -20
  212. package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.js.map +1 -1
  213. package/dist/dist-esm/react-components/src/components/styles/{NotificationBar.styles.d.ts → Notification.styles.d.ts} +1 -1
  214. package/dist/dist-esm/react-components/src/components/styles/{NotificationBar.styles.js → Notification.styles.js} +1 -1
  215. package/dist/dist-esm/react-components/src/components/styles/Notification.styles.js.map +1 -0
  216. package/dist/dist-esm/react-components/src/components/styles/SendBox.styles.d.ts +4 -1
  217. package/dist/dist-esm/react-components/src/components/styles/SendBox.styles.js +11 -3
  218. package/dist/dist-esm/react-components/src/components/styles/SendBox.styles.js.map +1 -1
  219. package/dist/dist-esm/react-components/src/components/styles/TeamsMeetingConferenceInfo.d.ts +42 -0
  220. package/dist/dist-esm/react-components/src/components/styles/TeamsMeetingConferenceInfo.js +93 -0
  221. package/dist/dist-esm/react-components/src/components/styles/TeamsMeetingConferenceInfo.js.map +1 -0
  222. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.d.ts +1 -37
  223. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.js +3 -34
  224. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentAsEditBoxUtils.js.map +1 -1
  225. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.d.ts +2 -4
  226. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.js +2 -14
  227. package/dist/dist-esm/react-components/src/components/utils/ChatMessageComponentUtils.js.map +1 -1
  228. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.d.ts +1 -11
  229. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js +2 -18
  230. package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js.map +1 -1
  231. package/dist/dist-esm/react-components/src/components/utils/common.js +0 -4
  232. package/dist/dist-esm/react-components/src/components/utils/common.js.map +1 -1
  233. package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.d.ts +2 -2
  234. package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js +6 -2
  235. package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js.map +1 -1
  236. package/dist/dist-esm/react-components/src/components/utils/getParticipantsWhoHaveReadMessage.d.ts +1 -2
  237. package/dist/dist-esm/react-components/src/components/utils/getParticipantsWhoHaveReadMessage.js.map +1 -1
  238. package/dist/dist-esm/react-components/src/components/utils/responsive.js +12 -2
  239. package/dist/dist-esm/react-components/src/components/utils/responsive.js.map +1 -1
  240. package/dist/dist-esm/react-components/src/components/utils.d.ts +32 -1
  241. package/dist/dist-esm/react-components/src/components/utils.js +101 -1
  242. package/dist/dist-esm/react-components/src/components/utils.js.map +1 -1
  243. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.d.ts +0 -4
  244. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.js +1 -5
  245. package/dist/dist-esm/react-components/src/identifiers/IdentifierProvider.js.map +1 -1
  246. package/dist/dist-esm/react-components/src/index.d.ts +0 -1
  247. package/dist/dist-esm/react-components/src/index.js.map +1 -1
  248. package/dist/dist-esm/react-components/src/localization/LocalizationProvider.d.ts +7 -58
  249. package/dist/dist-esm/react-components/src/localization/LocalizationProvider.js.map +1 -1
  250. package/dist/dist-esm/react-components/src/localization/locales/ar-SA/strings.json +102 -64
  251. package/dist/dist-esm/react-components/src/localization/locales/cs-CZ/strings.json +100 -62
  252. package/dist/dist-esm/react-components/src/localization/locales/de-DE/strings.json +100 -62
  253. package/dist/dist-esm/react-components/src/localization/locales/en-GB/strings.json +100 -62
  254. package/dist/dist-esm/react-components/src/localization/locales/en-US/strings.json +98 -60
  255. package/dist/dist-esm/react-components/src/localization/locales/es-ES/strings.json +100 -62
  256. package/dist/dist-esm/react-components/src/localization/locales/fi-FI/strings.json +100 -62
  257. package/dist/dist-esm/react-components/src/localization/locales/fr-FR/strings.json +103 -65
  258. package/dist/dist-esm/react-components/src/localization/locales/he-IL/strings.json +100 -62
  259. package/dist/dist-esm/react-components/src/localization/locales/it-IT/strings.json +100 -62
  260. package/dist/dist-esm/react-components/src/localization/locales/ja-JP/strings.json +102 -64
  261. package/dist/dist-esm/react-components/src/localization/locales/ko-KR/strings.json +107 -69
  262. package/dist/dist-esm/react-components/src/localization/locales/nb-NO/strings.json +100 -62
  263. package/dist/dist-esm/react-components/src/localization/locales/nl-NL/strings.json +106 -68
  264. package/dist/dist-esm/react-components/src/localization/locales/pl-PL/strings.json +105 -67
  265. package/dist/dist-esm/react-components/src/localization/locales/pt-BR/strings.json +103 -65
  266. package/dist/dist-esm/react-components/src/localization/locales/ru-RU/strings.json +101 -63
  267. package/dist/dist-esm/react-components/src/localization/locales/sv-SE/strings.json +100 -62
  268. package/dist/dist-esm/react-components/src/localization/locales/tr-TR/strings.json +101 -63
  269. package/dist/dist-esm/react-components/src/localization/locales/zh-CN/strings.json +102 -64
  270. package/dist/dist-esm/react-components/src/localization/locales/zh-TW/strings.json +101 -63
  271. package/dist/dist-esm/react-components/src/theming/FluentV9ThemeProvider.d.ts +1 -0
  272. package/dist/dist-esm/react-components/src/theming/FluentV9ThemeProvider.js +4 -4
  273. package/dist/dist-esm/react-components/src/theming/FluentV9ThemeProvider.js.map +1 -1
  274. package/dist/dist-esm/react-components/src/theming/icons.d.ts +1 -28
  275. package/dist/dist-esm/react-components/src/theming/icons.js +7 -136
  276. package/dist/dist-esm/react-components/src/theming/icons.js.map +1 -1
  277. package/dist/dist-esm/react-components/src/theming/themes.d.ts +0 -6
  278. package/dist/dist-esm/react-components/src/theming/themes.js +11 -20
  279. package/dist/dist-esm/react-components/src/theming/themes.js.map +1 -1
  280. package/dist/dist-esm/react-components/src/theming/v9ThemeShim.js +1 -1
  281. package/dist/dist-esm/react-components/src/theming/v9ThemeShim.js.map +1 -1
  282. package/dist/dist-esm/react-components/src/types/Attachment.d.ts +0 -9
  283. package/dist/dist-esm/react-components/src/types/Attachment.js.map +1 -1
  284. package/dist/dist-esm/react-components/src/types/ChatMessage.d.ts +1 -20
  285. package/dist/dist-esm/react-components/src/types/ChatMessage.js.map +1 -1
  286. package/dist/dist-esm/react-components/src/types/OnRender.d.ts +0 -8
  287. package/dist/dist-esm/react-components/src/types/OnRender.js.map +1 -1
  288. package/dist/dist-esm/react-components/src/types/VideoGalleryParticipant.d.ts +0 -6
  289. package/dist/dist-esm/react-components/src/types/VideoGalleryParticipant.js +0 -2
  290. package/dist/dist-esm/react-components/src/types/VideoGalleryParticipant.js.map +1 -1
  291. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.d.ts +0 -72
  292. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js +86 -37
  293. package/dist/dist-esm/react-composites/src/composites/CallComposite/CallComposite.js.map +1 -1
  294. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.d.ts +4 -108
  295. package/dist/dist-esm/react-composites/src/composites/CallComposite/Strings.js.map +1 -1
  296. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.d.ts +12 -64
  297. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js +15 -150
  298. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/AzureCommunicationCallAdapter.js.map +1 -1
  299. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.d.ts +3 -51
  300. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.js +1 -1
  301. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallAdapter.js.map +1 -1
  302. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.d.ts +2 -0
  303. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js +20 -0
  304. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/CallingSoundSubscriber.js.map +1 -1
  305. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/createHandlers.d.ts +2 -2
  306. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/createHandlers.js.map +1 -1
  307. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/index.d.ts +0 -2
  308. package/dist/dist-esm/react-composites/src/composites/CallComposite/adapter/index.js.map +1 -1
  309. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.d.ts +6 -2
  310. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js +83 -32
  311. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallArrangement.js.map +1 -1
  312. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.d.ts +0 -1
  313. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js +2 -38
  314. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallControls.js.map +1 -1
  315. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.d.ts +0 -2
  316. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.js +0 -27
  317. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageCameraDropdown.js.map +1 -1
  318. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageErrorBar.js +2 -20
  319. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageErrorBar.js.map +1 -1
  320. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.d.ts +0 -2
  321. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.js +0 -27
  322. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/ConfigurationPageMicDropdown.js.map +1 -1
  323. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.d.ts +0 -1
  324. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js +5 -19
  325. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/LocalDeviceSettings.js.map +1 -1
  326. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.d.ts +1 -0
  327. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +65 -1
  328. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
  329. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/useMeetingPhoneInfo.d.ts +13 -0
  330. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/useMeetingPhoneInfo.js +49 -0
  331. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/useMeetingPhoneInfo.js.map +1 -0
  332. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js +2 -1
  333. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js.map +1 -1
  334. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.d.ts +1 -0
  335. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.js +1 -1
  336. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/EndCall.js.map +1 -1
  337. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useAdaptedSelector.js +2 -6
  338. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useAdaptedSelector.js.map +1 -1
  339. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useHandlers.js +7 -30
  340. package/dist/dist-esm/react-composites/src/composites/CallComposite/hooks/useHandlers.js.map +1 -1
  341. package/dist/dist-esm/react-composites/src/composites/CallComposite/index.d.ts +0 -3
  342. package/dist/dist-esm/react-composites/src/composites/CallComposite/index.js.map +1 -1
  343. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/CallPage.d.ts +5 -2
  344. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/CallPage.js +12 -4
  345. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/CallPage.js.map +1 -1
  346. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.d.ts +0 -7
  347. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js +7 -80
  348. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/ConfigurationPage.js.map +1 -1
  349. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/LobbyPage.d.ts +5 -2
  350. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/LobbyPage.js +6 -3
  351. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/LobbyPage.js.map +1 -1
  352. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js +6 -3
  353. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/TransferPage.js.map +1 -1
  354. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.d.ts +5 -8
  355. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.js +5 -11
  356. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/baseSelectors.js.map +1 -1
  357. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/dominantRemoteParticipantSelector.js.map +1 -1
  358. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localAndRemotePIPSelector.js +0 -4
  359. package/dist/dist-esm/react-composites/src/composites/CallComposite/selectors/localAndRemotePIPSelector.js.map +1 -1
  360. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/CallPage.styles.d.ts +4 -0
  361. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/CallPage.styles.js +11 -0
  362. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/CallPage.styles.js.map +1 -1
  363. package/dist/dist-esm/react-composites/src/composites/CallComposite/types/CallControlOptions.d.ts +2 -2
  364. package/dist/dist-esm/react-composites/src/composites/CallComposite/types/CallControlOptions.js.map +1 -1
  365. package/dist/dist-esm/react-composites/src/composites/CallComposite/types/ErrorTracking.d.ts +6 -2
  366. package/dist/dist-esm/react-composites/src/composites/CallComposite/types/ErrorTracking.js.map +1 -1
  367. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/TrackErrors.d.ts +8 -7
  368. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/TrackErrors.js +20 -20
  369. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/TrackErrors.js.map +1 -1
  370. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.d.ts +49 -14
  371. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js +104 -98
  372. package/dist/dist-esm/react-composites/src/composites/CallComposite/utils/Utils.js.map +1 -1
  373. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.d.ts +1 -61
  374. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.js +6 -27
  375. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/CallWithChatComposite.js.map +1 -1
  376. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/Strings.d.ts +0 -32
  377. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/Strings.js.map +1 -1
  378. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.d.ts +5 -15
  379. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js +5 -49
  380. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/AzureCommunicationCallWithChatAdapter.js.map +1 -1
  381. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatAdapter.d.ts +3 -38
  382. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatAdapter.js.map +1 -1
  383. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.d.ts +1 -9
  384. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.js +0 -32
  385. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedCallAdapter.js.map +1 -1
  386. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.d.ts +4 -5
  387. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.js +2 -2
  388. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/adapter/CallWithChatBackedChatAdapter.js.map +1 -1
  389. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.d.ts +0 -13
  390. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.js +0 -4
  391. package/dist/dist-esm/react-composites/src/composites/CallWithChatComposite/state/CallWithChatAdapterState.js.map +1 -1
  392. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.d.ts +0 -20
  393. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.js +1 -6
  394. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatComposite.js.map +1 -1
  395. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.d.ts +0 -2
  396. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js +10 -131
  397. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js.map +1 -1
  398. package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.d.ts +0 -4
  399. package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.js.map +1 -1
  400. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.d.ts +2 -3
  401. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.js +0 -27
  402. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/AzureCommunicationChatAdapter.js.map +1 -1
  403. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/ChatAdapter.d.ts +2 -3
  404. package/dist/dist-esm/react-composites/src/composites/ChatComposite/adapter/ChatAdapter.js.map +1 -1
  405. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useHandlers.js +2 -13
  406. package/dist/dist-esm/react-composites/src/composites/ChatComposite/hooks/useHandlers.js.map +1 -1
  407. package/dist/dist-esm/react-composites/src/composites/ChatComposite/index.d.ts +0 -2
  408. package/dist/dist-esm/react-composites/src/composites/ChatComposite/index.js.map +1 -1
  409. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleButton.d.ts +1 -5
  410. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleButton.js +0 -15
  411. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleButton.js.map +1 -1
  412. package/dist/dist-esm/react-composites/src/composites/common/AvatarPersona.d.ts +0 -5
  413. package/dist/dist-esm/react-composites/src/composites/common/AvatarPersona.js +2 -3
  414. package/dist/dist-esm/react-composites/src/composites/common/AvatarPersona.js.map +1 -1
  415. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CommonCallControlBar.d.ts +2 -1
  416. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CommonCallControlBar.js +25 -19
  417. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CommonCallControlBar.js.map +1 -1
  418. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CustomButton.d.ts +1 -1
  419. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/CustomButton.js.map +1 -1
  420. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/DesktopMoreButton.d.ts +2 -0
  421. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/DesktopMoreButton.js +29 -26
  422. package/dist/dist-esm/react-composites/src/composites/common/ControlBar/DesktopMoreButton.js.map +1 -1
  423. package/dist/dist-esm/react-composites/src/composites/common/Drawer/MoreDrawer.d.ts +1 -0
  424. package/dist/dist-esm/react-composites/src/composites/common/Drawer/MoreDrawer.js +26 -23
  425. package/dist/dist-esm/react-composites/src/composites/common/Drawer/MoreDrawer.js.map +1 -1
  426. package/dist/dist-esm/react-composites/src/composites/common/Drawer/PreparedMoreDrawer.d.ts +1 -1
  427. package/dist/dist-esm/react-composites/src/composites/common/Drawer/PreparedMoreDrawer.js.map +1 -1
  428. package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.d.ts +10 -0
  429. package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js +63 -0
  430. package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map +1 -0
  431. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js +9 -7
  432. package/dist/dist-esm/react-composites/src/composites/common/ParticipantContainer.js.map +1 -1
  433. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js +2 -14
  434. package/dist/dist-esm/react-composites/src/composites/common/PeoplePaneContent.js.map +1 -1
  435. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.d.ts +1 -4
  436. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js +0 -1
  437. package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js.map +1 -1
  438. package/dist/dist-esm/react-composites/src/composites/common/icons.d.ts +10 -39
  439. package/dist/dist-esm/react-composites/src/composites/common/icons.js +10 -12
  440. package/dist/dist-esm/react-composites/src/composites/common/icons.js.map +1 -1
  441. package/dist/dist-esm/react-composites/src/composites/common/styles/ModalLocalAndRemotePIP.styles.d.ts +1 -1
  442. package/dist/dist-esm/react-composites/src/composites/common/styles/ModalLocalAndRemotePIP.styles.js +2 -2
  443. package/dist/dist-esm/react-composites/src/composites/common/styles/ModalLocalAndRemotePIP.styles.js.map +1 -1
  444. package/dist/dist-esm/react-composites/src/composites/common/styles/TeamsMeetingConferenceInfo.style.d.ts +50 -0
  445. package/dist/dist-esm/react-composites/src/composites/common/styles/TeamsMeetingConferenceInfo.style.js +110 -0
  446. package/dist/dist-esm/react-composites/src/composites/common/styles/TeamsMeetingConferenceInfo.style.js.map +1 -0
  447. package/dist/dist-esm/react-composites/src/composites/common/types/CommonCallControlOptions.d.ts +10 -17
  448. package/dist/dist-esm/react-composites/src/composites/common/types/CommonCallControlOptions.js.map +1 -1
  449. package/dist/dist-esm/react-composites/src/composites/common/utils.js +6 -6
  450. package/dist/dist-esm/react-composites/src/composites/common/utils.js.map +1 -1
  451. package/dist/dist-esm/react-composites/src/composites/localization/locales/ar-SA/strings.json +10 -5
  452. package/dist/dist-esm/react-composites/src/composites/localization/locales/cs-CZ/strings.json +6 -1
  453. package/dist/dist-esm/react-composites/src/composites/localization/locales/de-DE/strings.json +6 -1
  454. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-GB/strings.json +6 -1
  455. package/dist/dist-esm/react-composites/src/composites/localization/locales/en-US/strings.json +6 -1
  456. package/dist/dist-esm/react-composites/src/composites/localization/locales/es-ES/strings.json +6 -1
  457. package/dist/dist-esm/react-composites/src/composites/localization/locales/fi-FI/strings.json +10 -5
  458. package/dist/dist-esm/react-composites/src/composites/localization/locales/fr-FR/strings.json +10 -5
  459. package/dist/dist-esm/react-composites/src/composites/localization/locales/he-IL/strings.json +10 -5
  460. package/dist/dist-esm/react-composites/src/composites/localization/locales/it-IT/strings.json +10 -5
  461. package/dist/dist-esm/react-composites/src/composites/localization/locales/ja-JP/strings.json +6 -1
  462. package/dist/dist-esm/react-composites/src/composites/localization/locales/ko-KR/strings.json +10 -5
  463. package/dist/dist-esm/react-composites/src/composites/localization/locales/nb-NO/strings.json +6 -1
  464. package/dist/dist-esm/react-composites/src/composites/localization/locales/nl-NL/strings.json +6 -1
  465. package/dist/dist-esm/react-composites/src/composites/localization/locales/pl-PL/strings.json +6 -1
  466. package/dist/dist-esm/react-composites/src/composites/localization/locales/pt-BR/strings.json +10 -5
  467. package/dist/dist-esm/react-composites/src/composites/localization/locales/ru-RU/strings.json +6 -1
  468. package/dist/dist-esm/react-composites/src/composites/localization/locales/sv-SE/strings.json +10 -5
  469. package/dist/dist-esm/react-composites/src/composites/localization/locales/tr-TR/strings.json +6 -1
  470. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-CN/strings.json +10 -5
  471. package/dist/dist-esm/react-composites/src/composites/localization/locales/zh-TW/strings.json +10 -5
  472. package/dist/tsdoc-metadata.json +1 -1
  473. package/package.json +15 -16
  474. package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-BWStTUhO.js +0 -136
  475. package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-BWStTUhO.js.map +0 -1
  476. package/dist/dist-cjs/communication-react/index-Di3ptk8o.js +0 -39650
  477. package/dist/dist-cjs/communication-react/index-Di3ptk8o.js.map +0 -1
  478. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.d.ts +0 -17
  479. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.js +0 -36
  480. package/dist/dist-esm/calling-stateful-client/src/LocalRecordingSubscriber.js.map +0 -1
  481. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.d.ts +0 -10
  482. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.js +0 -15
  483. package/dist/dist-esm/react-components/src/components/ChatMessage/MentionRenderer.js.map +0 -1
  484. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.d.ts +0 -17
  485. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js +0 -125
  486. package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js.map +0 -1
  487. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.d.ts +0 -69
  488. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.js +0 -43
  489. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDenied.js.map +0 -1
  490. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.d.ts +0 -75
  491. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.js +0 -75
  492. package/dist/dist-esm/react-components/src/components/DevicePermissions/BrowserPermissionDeniedIOS.js.map +0 -1
  493. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.d.ts +0 -105
  494. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.js +0 -68
  495. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissions.js.map +0 -1
  496. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.d.ts +0 -86
  497. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.js +0 -39
  498. package/dist/dist-esm/react-components/src/components/DevicePermissions/SitePermissionsScaffolding.js.map +0 -1
  499. package/dist/dist-esm/react-components/src/components/HoldButton.d.ts +0 -49
  500. package/dist/dist-esm/react-components/src/components/HoldButton.js +0 -25
  501. package/dist/dist-esm/react-components/src/components/HoldButton.js.map +0 -1
  502. package/dist/dist-esm/react-components/src/components/MentionPopover.d.ts +0 -121
  503. package/dist/dist-esm/react-components/src/components/MentionPopover.js +0 -123
  504. package/dist/dist-esm/react-components/src/components/MentionPopover.js.map +0 -1
  505. package/dist/dist-esm/react-components/src/components/NotificationBar.js.map +0 -1
  506. package/dist/dist-esm/react-components/src/components/Notifications.js +0 -46
  507. package/dist/dist-esm/react-components/src/components/Notifications.js.map +0 -1
  508. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.d.ts +0 -9
  509. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.js +0 -29
  510. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.js.map +0 -1
  511. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.d.ts +0 -22
  512. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js +0 -89
  513. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js.map +0 -1
  514. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.d.ts +0 -12
  515. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.js +0 -23
  516. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.js.map +0 -1
  517. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.d.ts +0 -15
  518. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.js +0 -39
  519. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.js.map +0 -1
  520. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.d.ts +0 -24
  521. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.js +0 -64
  522. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/RichTextToolbarPlugin.js.map +0 -1
  523. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.d.ts +0 -20
  524. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.js +0 -46
  525. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/TableEditContextMenuProvider.js.map +0 -1
  526. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.d.ts +0 -29
  527. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.js +0 -73
  528. package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/UpdateContentPlugin.js.map +0 -1
  529. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.d.ts +0 -54
  530. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js +0 -226
  531. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js.map +0 -1
  532. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.d.ts +0 -33
  533. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js +0 -82
  534. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js.map +0 -1
  535. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.d.ts +0 -149
  536. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js +0 -182
  537. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js.map +0 -1
  538. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.d.ts +0 -16
  539. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js +0 -73
  540. package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js.map +0 -1
  541. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.d.ts +0 -19
  542. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js +0 -191
  543. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/RichTextToolbar.js.map +0 -1
  544. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.d.ts +0 -7
  545. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.js +0 -51
  546. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTableCommandBarItem.js.map +0 -1
  547. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.d.ts +0 -15
  548. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.js +0 -64
  549. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextInsertTablePane.js.map +0 -1
  550. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.d.ts +0 -6
  551. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.js +0 -13
  552. package/dist/dist-esm/react-components/src/components/RichTextEditor/Toolbar/Table/RichTextToolbarTableIcon.js.map +0 -1
  553. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.d.ts +0 -34
  554. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js +0 -39
  555. package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js.map +0 -1
  556. package/dist/dist-esm/react-components/src/components/SendBoxErrors.d.ts +0 -14
  557. package/dist/dist-esm/react-components/src/components/SendBoxErrors.js +0 -18
  558. package/dist/dist-esm/react-components/src/components/SendBoxErrors.js.map +0 -1
  559. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.d.ts +0 -24
  560. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.js +0 -550
  561. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/TextFieldWithMention.js.map +0 -1
  562. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.d.ts +0 -152
  563. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.js +0 -816
  564. package/dist/dist-esm/react-components/src/components/TextFieldWithMention/mentionTagUtils.js.map +0 -1
  565. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.d.ts +0 -58
  566. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.js +0 -144
  567. package/dist/dist-esm/react-components/src/components/styles/BrowserPermissionDenied.styles.js.map +0 -1
  568. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.d.ts +0 -26
  569. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.js +0 -69
  570. package/dist/dist-esm/react-components/src/components/styles/MentionPopover.style.js.map +0 -1
  571. package/dist/dist-esm/react-components/src/components/styles/NotificationBar.styles.js.map +0 -1
  572. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.d.ts +0 -82
  573. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js +0 -305
  574. package/dist/dist-esm/react-components/src/components/styles/RichTextEditor.styles.js.map +0 -1
  575. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.d.ts +0 -21
  576. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.js +0 -38
  577. package/dist/dist-esm/react-components/src/components/styles/RichTextInputBoxComponent.styles.js.map +0 -1
  578. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.d.ts +0 -38
  579. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.js +0 -92
  580. package/dist/dist-esm/react-components/src/components/styles/SitePermissions.styles.js.map +0 -1
  581. package/dist/dist-esm/react-components/src/components/styles/Stack.style.d.ts +0 -5
  582. package/dist/dist-esm/react-components/src/components/styles/Stack.style.js +0 -32
  583. package/dist/dist-esm/react-components/src/components/styles/Stack.style.js.map +0 -1
  584. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.d.ts +0 -26
  585. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.js +0 -67
  586. package/dist/dist-esm/react-components/src/components/styles/UnsupportedEnvironment.styles.js.map +0 -1
  587. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.d.ts +0 -37
  588. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js +0 -60
  589. package/dist/dist-esm/react-components/src/components/utils/RichTextEditorUtils.js.map +0 -1
  590. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.d.ts +0 -33
  591. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.js +0 -116
  592. package/dist/dist-esm/react-components/src/components/utils/RichTextTableUtils.js.map +0 -1
  593. package/dist/dist-esm/react-components/src/components/utils/merge.d.ts +0 -7
  594. package/dist/dist-esm/react-components/src/components/utils/merge.js +0 -16
  595. package/dist/dist-esm/react-components/src/components/utils/merge.js.map +0 -1
  596. package/dist/dist-esm/react-components/src/theming/icons.styles.d.ts +0 -6
  597. package/dist/dist-esm/react-components/src/theming/icons.styles.js +0 -25
  598. package/dist/dist-esm/react-components/src/theming/icons.styles.js.map +0 -1
  599. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.d.ts +0 -48
  600. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.js +0 -218
  601. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/CallReadinessModal.js.map +0 -1
  602. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/HoldPane.d.ts +0 -12
  603. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/HoldPane.js +0 -93
  604. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/HoldPane.js.map +0 -1
  605. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/People.d.ts +0 -8
  606. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/People.js +0 -26
  607. package/dist/dist-esm/react-composites/src/composites/CallComposite/components/buttons/People.js.map +0 -1
  608. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/HoldPage.d.ts +0 -24
  609. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/HoldPage.js +0 -28
  610. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/HoldPage.js.map +0 -1
  611. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.d.ts +0 -15
  612. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.js +0 -54
  613. package/dist/dist-esm/react-composites/src/composites/CallComposite/pages/UnsupportedBrowser.js.map +0 -1
  614. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/HoldPane.styles.d.ts +0 -32
  615. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/HoldPane.styles.js +0 -81
  616. package/dist/dist-esm/react-composites/src/composites/CallComposite/styles/HoldPane.styles.js.map +0 -1
  617. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.d.ts +0 -15
  618. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.js +0 -23
  619. package/dist/dist-esm/react-composites/src/composites/ChatComposite/AttachmentDownloadErrorBar.js.map +0 -1
  620. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.d.ts +0 -18
  621. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.js +0 -18
  622. package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreenPeoplePane.js.map +0 -1
  623. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.d.ts +0 -80
  624. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.js +0 -39
  625. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUpload.js.map +0 -1
  626. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.d.ts +0 -38
  627. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.js +0 -76
  628. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/AttachmentUploadButton.js.map +0 -1
  629. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.d.ts +0 -5
  630. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.js +0 -5
  631. package/dist/dist-esm/react-composites/src/composites/ChatComposite/file-sharing/index.js.map +0 -1
  632. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.d.ts +0 -25
  633. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.js +0 -113
  634. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.js.map +0 -1
  635. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.styles.d.ts +0 -17
  636. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.styles.js +0 -32
  637. package/dist/dist-esm/react-composites/src/composites/common/AddPeopleDropdown.styles.js.map +0 -1
  638. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.d.ts +0 -22
  639. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.js +0 -74
  640. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.js.map +0 -1
  641. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.styles.d.ts +0 -15
  642. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.styles.js +0 -61
  643. package/dist/dist-esm/react-composites/src/composites/common/CallingDialpad.styles.js.map +0 -1
@@ -1,123 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import React, { useEffect, useRef, useState, useCallback } from 'react';
4
- import { Persona, PersonaSize, Stack, mergeStyles, useTheme } from '@fluentui/react';
5
- import { mergeClasses } from '@fluentui/react-components';
6
- import { mentionPopoverContainerStyle, headerStyleThemed, suggestionItemStackStyle, suggestionItemWrapperStyle, useSuggestionListStyle } from './styles/MentionPopover.style';
7
- /* @conditional-compile-remove(mention) */
8
- import { useIdentifiers } from '../identifiers';
9
- import { useLocale } from '../localization';
10
- import { useDefaultStackStyles } from './styles/Stack.style';
11
- /**
12
- * Component to render a pop-up of mention suggestions.
13
- *
14
- * @internal
15
- */
16
- export const _MentionPopover = (props) => {
17
- const { suggestions, activeSuggestionIndex, title, target, targetPositionOffset, onRenderSuggestionItem, onSuggestionSelected, onDismiss, location } = props;
18
- const theme = useTheme();
19
- /* @conditional-compile-remove(mention) */
20
- const ids = useIdentifiers();
21
- const localeStrings = useLocale().strings;
22
- const popoverRef = useRef();
23
- const suggestionsListRef = useRef(null);
24
- const [position, setPosition] = useState();
25
- const [hoveredSuggestion, setHoveredSuggestion] = useState(undefined);
26
- const suggestionListStyle = useSuggestionListStyle();
27
- const defaultStackStyles = useDefaultStackStyles();
28
- const dismissPopoverWhenClickingOutside = useCallback((e) => {
29
- const target = e.target;
30
- if (popoverRef.current && !popoverRef.current.contains(target)) {
31
- onDismiss && onDismiss();
32
- }
33
- }, [onDismiss]);
34
- useEffect(() => {
35
- if (suggestionsListRef.current && activeSuggestionIndex !== undefined && activeSuggestionIndex >= 0) {
36
- const selectedItem = suggestionsListRef.current.children[activeSuggestionIndex];
37
- if (selectedItem) {
38
- selectedItem.scrollIntoView({
39
- behavior: 'smooth',
40
- block: 'nearest'
41
- });
42
- }
43
- }
44
- }, [activeSuggestionIndex]);
45
- useEffect(() => {
46
- window && window.addEventListener('click', dismissPopoverWhenClickingOutside);
47
- return () => {
48
- window && window.removeEventListener('click', dismissPopoverWhenClickingOutside);
49
- };
50
- }, [dismissPopoverWhenClickingOutside]);
51
- // Determine popover position
52
- useEffect(() => {
53
- var _a, _b, _c, _d, _e, _f, _g, _h;
54
- const rect = (_a = target === null || target === void 0 ? void 0 : target.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
55
- const maxWidth = 200;
56
- const finalPosition = {
57
- maxWidth
58
- };
59
- // Figure out whether it will fit horizontally
60
- const leftOffset = (_b = targetPositionOffset === null || targetPositionOffset === void 0 ? void 0 : targetPositionOffset.left) !== null && _b !== void 0 ? _b : 0;
61
- if (leftOffset + maxWidth > ((_c = rect === null || rect === void 0 ? void 0 : rect.width) !== null && _c !== void 0 ? _c : 0)) {
62
- finalPosition.right = ((_d = rect === null || rect === void 0 ? void 0 : rect.width) !== null && _d !== void 0 ? _d : 0) - leftOffset;
63
- }
64
- else {
65
- finalPosition.left = leftOffset;
66
- }
67
- // Offset between cursor and mention popover
68
- const verticalOffset = 4;
69
- if (location === 'below') {
70
- finalPosition.top = ((_e = rect === null || rect === void 0 ? void 0 : rect.height) !== null && _e !== void 0 ? _e : 0) + ((_f = targetPositionOffset === null || targetPositionOffset === void 0 ? void 0 : targetPositionOffset.top) !== null && _f !== void 0 ? _f : 0) + verticalOffset;
71
- }
72
- else {
73
- // (location === 'above')
74
- finalPosition.bottom = ((_g = rect === null || rect === void 0 ? void 0 : rect.height) !== null && _g !== void 0 ? _g : 0) - ((_h = targetPositionOffset === null || targetPositionOffset === void 0 ? void 0 : targetPositionOffset.top) !== null && _h !== void 0 ? _h : 0) + verticalOffset;
75
- }
76
- setPosition(finalPosition);
77
- }, [location, target, targetPositionOffset]);
78
- const handleOnKeyDown = useCallback((e) => {
79
- switch (e.key) {
80
- case 'Escape':
81
- onDismiss && onDismiss();
82
- break;
83
- default:
84
- break;
85
- }
86
- }, [onDismiss]);
87
- const personaRenderer = useCallback((displayName) => {
88
- const avatarOptions = {
89
- text: displayName.trim(),
90
- size: PersonaSize.size24,
91
- initialsColor: theme.palette.neutralLight,
92
- initialsTextColor: theme.palette.neutralSecondary,
93
- showOverflowTooltip: false,
94
- showUnknownPersonaCoin: false
95
- };
96
- return React.createElement(Persona, Object.assign({}, avatarOptions));
97
- }, [theme]);
98
- const defaultOnRenderSuggestionItem = useCallback((suggestion, onSuggestionSelected, active) => {
99
- return React.createElement("div", { "data-is-focusable": true, "data-ui-id": ids.mentionSuggestionItem, key: suggestion.id, onClick: () => onSuggestionSelected(suggestion), onMouseEnter: () => setHoveredSuggestion(suggestion), onMouseLeave: () => setHoveredSuggestion(undefined), onKeyDown: e => {
100
- handleOnKeyDown(e);
101
- }, className: suggestionItemWrapperStyle(theme) },
102
- React.createElement(Stack, { horizontal: true, className: suggestionItemStackStyle(theme, (hoveredSuggestion === null || hoveredSuggestion === void 0 ? void 0 : hoveredSuggestion.id) === suggestion.id, active) }, personaRenderer(suggestion.displayText)));
103
- }, [handleOnKeyDown, theme, /* @conditional-compile-remove(mention) */
104
- ids, hoveredSuggestion, personaRenderer]);
105
- const getHeaderTitle = useCallback(() => {
106
- if (title) {
107
- return title;
108
- }
109
- /* @conditional-compile-remove(mention) */
110
- return localeStrings.mentionPopover.mentionPopoverHeader;
111
- return '';
112
- }, [localeStrings, title]);
113
- return React.createElement("div", { ref: popoverRef }, position && React.createElement(Stack, { "data-testid": 'mention-suggestion-list-container', className: mergeStyles({
114
- maxHeight: 212,
115
- maxWidth: position.maxWidth
116
- }, mentionPopoverContainerStyle(theme), Object.assign(Object.assign({}, position), { position: 'absolute' })) },
117
- React.createElement(Stack.Item, { styles: headerStyleThemed(theme), "aria-label": title }, getHeaderTitle()),
118
- React.createElement("div", { className: mergeClasses(defaultStackStyles.root, suggestionListStyle.root), "data-ui-id": ids.mentionSuggestionList, ref: suggestionsListRef }, suggestions.map((suggestion, index) => {
119
- const active = index === activeSuggestionIndex;
120
- return onRenderSuggestionItem ? onRenderSuggestionItem(suggestion, onSuggestionSelected, active) : defaultOnRenderSuggestionItem(suggestion, onSuggestionSelected, active);
121
- }))));
122
- };
123
- //# sourceMappingURL=MentionPopover.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"MentionPopover.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/src/components/MentionPopover.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACxE,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AACrF,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,4BAA4B,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,0BAA0B,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AAC9K,0CAA0C;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAyH7D;;;;GAIG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG,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mC,EAAE,SAAS,EAAE,WAAW,CAAC;YAC7F,SAAS,EAAE,GAAG;YACd,QAAQ,EAAE,QAAQ,CAAC,QAAQ;SAC5B,EAAE,4BAA4B,CAAC,KAAK,CAAC,kCACjC,QAAQ,KACX,QAAQ,EAAE,UAAU,IACpB;QACI,oBAAC,KAAK,CAAC,IAAI,IAAC,MAAM,EAAE,iBAAiB,CAAC,KAAK,CAAC,gBAAc,KAAK,IAC5D,cAAc,EAAE,CACN;QAEb,6BAAK,SAAS,EAAE,YAAY,CAAC,kBAAkB,CAAC,IAAI,EAAE,mBAAmB,CAAC,IAAI,CAAC,gBAC5B,GAAG,CAAC,qBAAqB,EAAE,GAAG,EAAE,kBAAkB,IAClG,WAAW,CAAC,GAAG,CAAC,CAAC,UAAU,EAAE,KAAK,EAAE,EAAE;YACzC,MAAM,MAAM,GAAG,KAAK,KAAK,qBAAqB,CAAC;YAC/C,OAAO,sBAAsB,CAAC,CAAC,CAAC,sBAAsB,CAAC,UAAU,EAAE,oBAAoB,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,6BAA6B,CAAC,UAAU,EAAE,oBAAoB,EAAE,MAAM,CAAC,CAAC;QAC7K,CAAC,CAAC,CACM,CACA,CACN,CAAC;AACX,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React, { useEffect, useRef, useState, useCallback } from 'react';\nimport { Persona, PersonaSize, Stack, mergeStyles, useTheme } from '@fluentui/react';\nimport { mergeClasses } from '@fluentui/react-components';\nimport { mentionPopoverContainerStyle, headerStyleThemed, suggestionItemStackStyle, suggestionItemWrapperStyle, useSuggestionListStyle } from './styles/MentionPopover.style';\n/* @conditional-compile-remove(mention) */\nimport { useIdentifiers } from '../identifiers';\nimport { useLocale } from '../localization';\nimport { useDefaultStackStyles } from './styles/Stack.style';\n\n/**\n * Props for {@link _MentionPopover}.\n *\n * @internal\n */\nexport interface _MentionPopoverProps {\n /**\n * Array of mention suggestions used to populate the suggestion list\n */\n suggestions: Mention[];\n /**\n * Index of the currently focused suggestion, if any\n */\n activeSuggestionIndex?: number;\n /**\n * Optional string used as mention popover's title.\n * @defaultValue `Suggestions`\n */\n title?: string;\n /**\n * Element to anchor the popover to.\n */\n target: React.RefObject<Element>;\n /**\n * When rendering the popover, where to position it relative to the target.\n */\n targetPositionOffset?: {\n top: number;\n left: number;\n };\n /**\n * Where to display the suggestions relative to the target.\n * @defaultValue `above`\n */\n location?: 'above' | 'below';\n /**\n * Callback called when a mention suggestion is selected.\n */\n onSuggestionSelected: (suggestion: Mention) => void;\n /**\n * Callback to invoke when the popover is dismissed\n */\n onDismiss?: () => void;\n /**\n * Optional callback to render an item of the mention suggestions list.\n */\n onRenderSuggestionItem?: (suggestion: Mention, onSuggestionSelected: (suggestion: Mention) => void, isActive: boolean) => JSX.Element;\n}\n\n/**\n * Options to lookup suggestions in the mention scenario.\n *\n * @beta\n */\nexport interface MentionLookupOptions {\n /**\n * Optional string to set trigger keyword for mention a specific participant.\n *\n * @defaultValue `@`\n */\n trigger?: string;\n /**\n * Optional callback to fetch a list of mention suggestions base on the query.\n */\n onQueryUpdated: (query: string) => Promise<Mention[]>;\n /**\n * Optional callback to render an item of the mention suggestions list.\n */\n onRenderSuggestionItem?: (suggestion: Mention, onSuggestionSelected: (suggestion: Mention) => void, isActive: boolean) => JSX.Element;\n}\n\n/**\n * Options to display suggestions in the mention scenario.\n *\n * @beta\n */\nexport interface MentionDisplayOptions {\n /**\n * Optional callback for customizing the mention renderer in a message thread.\n */\n onRenderMention?: (mention: Mention, defaultOnRender: (mention: Mention) => JSX.Element) => JSX.Element;\n}\n\n/**\n * Options to lookup suggestions and display mentions in the mention scenario.\n *\n * @beta\n */\nexport type MentionOptions = {\n lookupOptions?: MentionLookupOptions;\n displayOptions?: MentionDisplayOptions;\n};\n\n/**\n * Mention's state, as reflected in the UI.\n *\n * @beta\n */\nexport interface Mention {\n /** ID of a mention */\n id: string;\n /** Display text of a mention */\n displayText: string;\n /** Optional React element to render an item icon of a mention suggestion */\n icon?: JSX.Element;\n}\n\n/**\n * Strings of {@link _MentionPopover} that can be overridden.\n *\n * @beta\n */\nexport interface MentionPopoverStrings {\n /**\n * Header text for MentionPopover\n */\n mentionPopoverHeader: string;\n}\n\n/**\n * Component to render a pop-up of mention suggestions.\n *\n * @internal\n */\nexport const _MentionPopover = (props: _MentionPopoverProps): JSX.Element => {\n interface Position {\n left?: number;\n right?: number;\n top?: number;\n bottom?: number;\n maxWidth?: number;\n }\n const {\n suggestions,\n activeSuggestionIndex,\n title,\n target,\n targetPositionOffset,\n onRenderSuggestionItem,\n onSuggestionSelected,\n onDismiss,\n location\n } = props;\n const theme = useTheme();\n /* @conditional-compile-remove(mention) */\n const ids = useIdentifiers();\n const localeStrings = useLocale().strings;\n const popoverRef = (useRef() as React.MutableRefObject<HTMLDivElement>);\n const suggestionsListRef = useRef<HTMLDivElement>(null);\n const [position, setPosition] = useState<Position | undefined>();\n const [hoveredSuggestion, setHoveredSuggestion] = useState<Mention | undefined>(undefined);\n const suggestionListStyle = useSuggestionListStyle();\n const defaultStackStyles = useDefaultStackStyles();\n const dismissPopoverWhenClickingOutside = useCallback((e: MouseEvent) => {\n const target = (e.target as HTMLElement);\n if (popoverRef.current && !popoverRef.current.contains(target)) {\n onDismiss && onDismiss();\n }\n }, [onDismiss]);\n useEffect(() => {\n if (suggestionsListRef.current && activeSuggestionIndex !== undefined && activeSuggestionIndex >= 0) {\n const selectedItem = suggestionsListRef.current.children[activeSuggestionIndex];\n if (selectedItem) {\n selectedItem.scrollIntoView({\n behavior: 'smooth',\n block: 'nearest'\n });\n }\n }\n }, [activeSuggestionIndex]);\n useEffect(() => {\n window && window.addEventListener('click', dismissPopoverWhenClickingOutside);\n return () => {\n window && window.removeEventListener('click', dismissPopoverWhenClickingOutside);\n };\n }, [dismissPopoverWhenClickingOutside]);\n\n // Determine popover position\n useEffect(() => {\n const rect = target?.current?.getBoundingClientRect();\n const maxWidth = 200;\n const finalPosition: Position = {\n maxWidth\n };\n\n // Figure out whether it will fit horizontally\n const leftOffset = targetPositionOffset?.left ?? 0;\n if (leftOffset + maxWidth > (rect?.width ?? 0)) {\n finalPosition.right = (rect?.width ?? 0) - leftOffset;\n } else {\n finalPosition.left = leftOffset;\n }\n // Offset between cursor and mention popover\n const verticalOffset = 4;\n if (location === 'below') {\n finalPosition.top = (rect?.height ?? 0) + (targetPositionOffset?.top ?? 0) + verticalOffset;\n } else {\n // (location === 'above')\n finalPosition.bottom = (rect?.height ?? 0) - (targetPositionOffset?.top ?? 0) + verticalOffset;\n }\n setPosition(finalPosition);\n }, [location, target, targetPositionOffset]);\n const handleOnKeyDown = useCallback((e: React.KeyboardEvent<HTMLDivElement>) => {\n switch (e.key) {\n case 'Escape':\n onDismiss && onDismiss();\n break;\n default:\n break;\n }\n }, [onDismiss]);\n const personaRenderer = useCallback((displayName: string): JSX.Element => {\n const avatarOptions = {\n text: displayName.trim(),\n size: PersonaSize.size24,\n initialsColor: theme.palette.neutralLight,\n initialsTextColor: theme.palette.neutralSecondary,\n showOverflowTooltip: false,\n showUnknownPersonaCoin: false\n };\n return <Persona {...avatarOptions} />;\n }, [theme]);\n const defaultOnRenderSuggestionItem = useCallback((suggestion: Mention, onSuggestionSelected: (suggestion: Mention) => void, active: boolean): JSX.Element => {\n return <div data-is-focusable={true}\n /* @conditional-compile-remove(mention) */ data-ui-id={ids.mentionSuggestionItem} key={suggestion.id} onClick={() => onSuggestionSelected(suggestion)} onMouseEnter={() => setHoveredSuggestion(suggestion)} onMouseLeave={() => setHoveredSuggestion(undefined)} onKeyDown={e => {\n handleOnKeyDown(e);\n }} className={suggestionItemWrapperStyle(theme)}>\n <Stack horizontal className={suggestionItemStackStyle(theme, hoveredSuggestion?.id === suggestion.id, active)}>\n {personaRenderer(suggestion.displayText)}\n </Stack>\n </div>;\n }, [handleOnKeyDown, theme, /* @conditional-compile-remove(mention) */\n ids, hoveredSuggestion, personaRenderer]);\n const getHeaderTitle = useCallback((): string => {\n if (title) {\n return title;\n }\n /* @conditional-compile-remove(mention) */\n return localeStrings.mentionPopover.mentionPopoverHeader;\n return '';\n }, [localeStrings, title]);\n return <div ref={popoverRef}>\n {position && <Stack data-testid={'mention-suggestion-list-container'} className={mergeStyles({\n maxHeight: 212,\n maxWidth: position.maxWidth\n }, mentionPopoverContainerStyle(theme), {\n ...position,\n position: 'absolute'\n })}>\n <Stack.Item styles={headerStyleThemed(theme)} aria-label={title}>\n {getHeaderTitle()}\n </Stack.Item>\n {/* FluentUI v9 approach is used here instead of Stack because Stack doesn't have ref prop */}\n <div className={mergeClasses(defaultStackStyles.root, suggestionListStyle.root)}\n /* @conditional-compile-remove(mention) */ data-ui-id={ids.mentionSuggestionList} ref={suggestionsListRef}>\n {suggestions.map((suggestion, index) => {\n const active = index === activeSuggestionIndex;\n return onRenderSuggestionItem ? onRenderSuggestionItem(suggestion, onSuggestionSelected, active) : defaultOnRenderSuggestionItem(suggestion, onSuggestionSelected, active);\n })}\n </div>\n </Stack>}\n </div>;\n};"]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"NotificationBar.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/src/components/NotificationBar.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,aAAa,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAc,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACpH,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAAE,eAAe,EAAE,qBAAqB,EAAE,gBAAgB,EAAE,yBAAyB,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AA0E1J;;;;GAIG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,KAA2B,EAAe,EAAE;;IAC1E,MAAM,OAAO,GAAG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AAC,KAAK,IAAC,UAAU,QAAC,eAAe,EAAC,cAAc;gBAC7C,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,oBAAoB,KAAI,oBAAC,aAAa,IAAC,OAAO,EAAE,KAAK,CAAC,sBAAsB,EAAE,KAAK,EAAE;wBAC/F,SAAS,EAAE,MAAM;qBAClB,IACM,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,oBAAoB,CAChB;gBACjB,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,kBAAkB,KAAI,oBAAC,aAAa,IAAC,OAAO,EAAE,KAAK,CAAC,oBAAoB,EAAE,KAAK,EAAE;wBAC3F,SAAS,EAAE,MAAM;qBAClB,IACM,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,kBAAkB,CACd,CACZ,CACF;QACP,KAAK,CAAC,iBAAiB,IAAI,oBAAC,KAAK,IAAC,SAAS,EAAE,qBAAqB,CAAC,KAAK,CAAC,GAAU,CAC9E,CAAC;AACb,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React, { useState } from 'react';\nimport { Icon, IconButton, PrimaryButton, Stack, useTheme, Text, IIconProps, DefaultButton } from '@fluentui/react';\nimport { cancelIcon } from './styles/ImageOverlay.style';\nimport { containerStyles, hiddenContainerStyles, messageTextStyle, notificationIconClassName, titleTextClassName } from './styles/NotificationBar.styles';\n\n/**\n * Props for {@link NotificationBar}.\n *\n * @beta\n */\nexport interface NotificationBarProps {\n /**\n * Notification bar strings;\n */\n notificationBarStrings?: NotificationBarStrings;\n\n /**\n * Notification bar icon;\n */\n notificationBarIconProps?: IIconProps;\n\n /**\n * If set, notifications will automatically dismiss after 5 seconds\n * @defaultValue false\n */\n autoDismiss?: boolean;\n\n /**\n * If set, notifications will be shown in a stacked effect\n * @defaultValue false\n */\n showStackedEffect?: boolean;\n\n /**\n * Callback called when the primary button inside notification bar is clicked.\n */\n onClickPrimaryButton?: () => void;\n\n /**\n * Callback called when the secondary button inside notification bar is clicked.\n */\n onClickSecondaryButton?: () => void;\n\n /**\n * Callback called when the notification is dismissed.\n */\n onDismiss?: () => void;\n}\n\n/**\n * All strings that may be shown on the UI in the {@link NotificationBar}.\n *\n * @beta\n */\nexport interface NotificationBarStrings {\n /**\n * Notification bar title.\n */\n title: string;\n /**\n * Notification bar close button aria label\n */\n closeButtonAriaLabel: string;\n /**\n * Notification bar message.\n */\n message?: string;\n /**\n * Notification bar primary button label\n */\n primaryButtonLabel?: string;\n /**\n * Notification bar secondary button label\n */\n secondaryButtonLabel?: string;\n}\n\n/**\n * A component to show notification messages on the UI.\n *\n * @beta\n */\nexport const NotificationBar = (props: NotificationBarProps): JSX.Element => {\n const strings = props.notificationBarStrings;\n const theme = useTheme();\n const [show, setShow] = useState(true);\n if (props.autoDismiss) {\n setTimeout(() => {\n // After 5 seconds set the show value to false\n setShow(false);\n }, 5000);\n if (!show) {\n props.onDismiss && props.onDismiss();\n return <></>;\n }\n }\n return <Stack horizontalAlign=\"center\">\n <Stack data-ui-id=\"notification-bar\" className={containerStyles(theme)}>\n <Stack horizontal horizontalAlign=\"space-between\">\n <Stack horizontal>\n <Icon className={notificationIconClassName} iconName={props.notificationBarIconProps?.iconName ?? 'ErrorBadge'} {...props.notificationBarIconProps} />\n <Text className={titleTextClassName}>{strings?.title}</Text>\n </Stack>\n\n <IconButton iconProps={cancelIcon} ariaLabel={strings?.closeButtonAriaLabel} aria-live={'polite'} onClick={props.onDismiss} />\n </Stack>\n <Text className={messageTextStyle(theme)}>{strings?.message}</Text>\n <Stack horizontal horizontalAlign=\"space-evenly\">\n {strings?.secondaryButtonLabel && <DefaultButton onClick={props.onClickSecondaryButton} style={{\n marginTop: '1rem'\n }}>\n {strings?.secondaryButtonLabel}\n </DefaultButton>}\n {strings?.primaryButtonLabel && <PrimaryButton onClick={props.onClickPrimaryButton} style={{\n marginTop: '1rem'\n }}>\n {strings?.primaryButtonLabel}\n </PrimaryButton>}\n </Stack>\n </Stack>\n {props.showStackedEffect && <Stack className={hiddenContainerStyles(theme)}></Stack>}\n </Stack>;\n};"]}
@@ -1,46 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import React, { useEffect, useState } from 'react';
4
- import { Stack } from '@fluentui/react';
5
- import { NotificationIconProps } from './utils';
6
- import { NotificationBar } from './NotificationBar';
7
- /**
8
- * A component to show notifications on the UI.
9
- * All strings that can be shown are accepted as the {@link NotificationsProps.strings} so that they can be localized.
10
- * Active notifications are selected by {@link NotificationsProps.activeNotifications}.
11
- *
12
- * This component internally tracks dismissed by the user.
13
- * * Notifications that have an associated timestamp: The notification is shown on the UI again if it occurs after being dismissed.
14
- * * Notifications that do not have a timestamp: The notification is dismissed until it disappears from the props.
15
- * If the notification recurs, it is shown in the UI.
16
- *
17
- *
18
- * @beta
19
- */
20
- export const Notifications = (props) => {
21
- var _a;
22
- const strings = props.strings;
23
- const maxNotificationsToShow = (_a = props.maxNotificationsToShow) !== null && _a !== void 0 ? _a : 2;
24
- const [activeNotifications, setActiveNotifications] = useState(props.activeNotifications);
25
- useEffect(() => {
26
- setActiveNotifications(props.activeNotifications);
27
- }, [props.activeNotifications]);
28
- return React.createElement(Stack, { "data-ui-id": "notifications-stack", style: {
29
- width: 'fit-content'
30
- } }, activeNotifications.map((notification, index) => {
31
- if (index < maxNotificationsToShow) {
32
- return React.createElement("div", { key: index, style: {
33
- marginBottom: `${index === maxNotificationsToShow - 1 ? 0 : '0.25rem'}`
34
- } },
35
- React.createElement(NotificationBar, { notificationBarStrings: strings ? strings[notification.type] : undefined, notificationBarIconProps: NotificationIconProps(notification.type), onClickPrimaryButton: () => { var _a; return (_a = notification.onClickPrimaryButton) === null || _a === void 0 ? void 0 : _a.call(notification); }, onClickSecondaryButton: () => { var _a; return (_a = notification.onClickSecondaryButton) === null || _a === void 0 ? void 0 : _a.call(notification); }, onDismiss: () => {
36
- activeNotifications.splice(index, 1);
37
- setActiveNotifications([...activeNotifications]);
38
- notification.onDismiss && notification.onDismiss();
39
- }, showStackedEffect: index === maxNotificationsToShow - 1 && activeNotifications.length > maxNotificationsToShow, autoDismiss: notification.autoDismiss }));
40
- }
41
- else {
42
- return React.createElement(React.Fragment, null);
43
- }
44
- }));
45
- };
46
- //# sourceMappingURL=Notifications.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Notifications.js","sourceRoot":"","sources":["../../../../../preprocess-dist/react-components/src/components/Notifications.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,EAAE,eAAe,EAA0B,MAAM,mBAAmB,CAAC;AAmP5E;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,KAAyB,EAAe,EAAE;;IACtE,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC;IAC9B,MAAM,sBAAsB,GAAG,MAAA,KAAK,CAAC,sBAAsB,mCAAI,CAAC,CAAC;IACjE,MAAM,CAAC,mBAAmB,EAAE,sBAAsB,CAAC,GAAG,QAAQ,CAAuB,KAAK,CAAC,mBAAmB,CAAC,CAAC;IAChH,SAAS,CAAC,GAAG,EAAE;QACb,sBAAsB,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC;IACpD,CAAC,EAAE,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC,CAAC;IAChC,OAAO,oBAAC,KAAK,kBAAY,qBAAqB,EAAC,KAAK,EAAE;YACpD,KAAK,EAAE,aAAa;SACrB,IACI,mBAAmB,CAAC,GAAG,CAAC,CAAC,YAAY,EAAE,KAAK,EAAE,EAAE;QACjD,IAAI,KAAK,GAAG,sBAAsB,EAAE,CAAC;YACnC,OAAO,6BAAK,GAAG,EAAE,KAAK,EAAE,KAAK,EAAE;oBAC7B,YAAY,EAAE,GAAG,KAAK,KAAK,sBAAsB,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,EAAE;iBACxE;gBACK,oBAAC,eAAe,IAAC,sBAAsB,EAAE,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,EAAE,wBAAwB,EAAE,qBAAqB,CAAC,YAAY,CAAC,IAAI,CAAC,EAAE,oBAAoB,EAAE,GAAG,EAAE,WAAC,OAAA,MAAA,YAAY,CAAC,oBAAoB,4DAAI,CAAA,EAAA,EAAE,sBAAsB,EAAE,GAAG,EAAE,WAAC,OAAA,MAAA,YAAY,CAAC,sBAAsB,4DAAI,CAAA,EAAA,EAAE,SAAS,EAAE,GAAG,EAAE;wBAC3T,mBAAmB,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC;wBACrC,sBAAsB,CAAC,CAAC,GAAG,mBAAmB,CAAC,CAAC,CAAC;wBACjD,YAAY,CAAC,SAAS,IAAI,YAAY,CAAC,SAAS,EAAE,CAAC;oBACrD,CAAC,EAAE,iBAAiB,EAAE,KAAK,KAAK,sBAAsB,GAAG,CAAC,IAAI,mBAAmB,CAAC,MAAM,GAAG,sBAAsB,EAAE,WAAW,EAAE,YAAY,CAAC,WAAW,GAAI,CACpJ,CAAC;QACb,CAAC;aAAM,CAAC;YACN,OAAO,yCAAK,CAAC;QACf,CAAC;IACH,CAAC,CAAC,CACM,CAAC;AACb,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport React, { useEffect, useState } from 'react';\nimport { Stack } from '@fluentui/react';\nimport { NotificationIconProps } from './utils';\nimport { NotificationBar, NotificationBarStrings } from './NotificationBar';\n\n/**\n * Props for {@link Notifications}.\n * @beta\n */\nexport interface NotificationsProps {\n /**\n * Strings shown on the UI on errors.\n */\n strings?: NotificationsStrings;\n\n /**\n * Currently active notifications.\n */\n activeNotifications: ActiveNotification[];\n\n /**\n * Max notifications to show at a time.\n * @defaultValue 2\n */\n maxNotificationsToShow?: number;\n}\n\n/**\n * All strings that may be shown on the UI in the {@link Notifications}.\n *\n * @beta\n */\nexport interface NotificationsStrings {\n /**\n * Unable to reach Chat service.\n *\n * This can mean:\n * - Incorrect Azure Communication Services endpoint was provided.\n * - User's network connection is down.\n */\n unableToReachChatService: NotificationBarStrings;\n\n /**\n * User does not have access to the Chat service.\n * This usually means that either the Azure Communication Services endpiont or the token provided are incorrect.\n */\n accessDenied: NotificationBarStrings;\n\n /**\n * User is no longer on the thread.\n *\n * See also: {@link NotificationsStrings.sendMessageNotInChatThread} for a more specific error.\n */\n userNotInChatThread: NotificationBarStrings;\n\n /**\n * Sending message failed because user is no longer on the thread.\n */\n sendMessageNotInChatThread: NotificationBarStrings;\n\n /**\n * A generic message when sending message fails.\n * Prefer more specific error strings when possible.\n */\n sendMessageGeneric: NotificationBarStrings;\n\n /**\n * A generic message when starting video fails.\n */\n startVideoGeneric: NotificationBarStrings;\n\n /**\n * A generic message when starting video fails.\n */\n stopVideoGeneric: NotificationBarStrings;\n\n /**\n * A generic message when muting microphone fails.\n */\n muteGeneric: NotificationBarStrings;\n\n /**\n * A generic message when unmuting microphone fails.\n */\n unmuteGeneric: NotificationBarStrings;\n\n /**\n * A generic message when starting screenshare fails.\n */\n startScreenShareGeneric: NotificationBarStrings;\n\n /**\n * A generic message when stopping screenshare fails.\n */\n stopScreenShareGeneric: NotificationBarStrings;\n\n /**\n * Message shown when poor network quality is detected during a call.\n */\n callNetworkQualityLow: NotificationBarStrings;\n\n /**\n * Message shown on failure to detect audio output devices.\n */\n callNoSpeakerFound: NotificationBarStrings;\n\n /**\n * Message shown on failure to detect audio input devices.\n */\n callNoMicrophoneFound: NotificationBarStrings;\n\n /**\n * Message shown when microphone can be enumerated but access is blocked by the system.\n */\n callMicrophoneAccessDenied: NotificationBarStrings;\n\n /**\n * Message shown when microphone can be enumerated but access is blocked by the system, for safari browsers\n */\n callMicrophoneAccessDeniedSafari: NotificationBarStrings;\n\n /**\n * Message shown when microphone is muted by the system (not by local or remote participants)\n */\n callMicrophoneMutedBySystem: NotificationBarStrings;\n\n /**\n * Message shown when microphone is unmuted by the system (not by local or remote participants).\n * This typically occurs if the system recovers from an unexpected mute.\n */\n callMicrophoneUnmutedBySystem: NotificationBarStrings;\n\n /**\n * Mac OS specific message shown when microphone can be enumerated but access is\n * blocked by the system.\n */\n callMacOsMicrophoneAccessDenied: NotificationBarStrings;\n\n /**\n * Message shown when poor network causes local video stream to be frozen.\n */\n callLocalVideoFreeze: NotificationBarStrings;\n\n /**\n * Message shown when camera can be enumerated but access is blocked by the system.\n */\n callCameraAccessDenied: NotificationBarStrings;\n\n /**\n * Message shown when camera can be enumerated but access is blocked by the system, for safari browsers\n */\n callCameraAccessDeniedSafari: NotificationBarStrings;\n\n /**\n * Message shown when local video fails to start because camera is already in use by\n * another applciation.\n */\n callCameraAlreadyInUse: NotificationBarStrings;\n\n /**\n * Message shown when local video is stopped by the system (not by local or remote participants)\n */\n callVideoStoppedBySystem: NotificationBarStrings;\n\n /**\n * Message shown when local video was recovered by the system (not by the local participant)\n */\n callVideoRecoveredBySystem: NotificationBarStrings;\n\n /**\n * Mac OS specific message shown when system denies access to camera.\n */\n callMacOsCameraAccessDenied: NotificationBarStrings;\n\n /**\n * Mac OS specific message shown when system denies sharing local screen on a call.\n */\n callMacOsScreenShareAccessDenied: NotificationBarStrings;\n\n /**\n * Dimiss Notifications button aria label read by screen reader accessibility tools\n */\n dismissButtonAriaLabel?: NotificationBarStrings;\n\n /**\n * An error message when joining a call fails.\n */\n failedToJoinCallGeneric?: NotificationBarStrings;\n\n /**\n * An error message when joining a call fails specifically due to an invalid meeting link.\n */\n failedToJoinCallInvalidMeetingLink?: NotificationBarStrings;\n /**\n * Error string letting you know remote participants see a frozen stream for you.\n */\n cameraFrozenForRemoteParticipants?: NotificationBarStrings;\n\n /**\n * Unable to start effect\n */\n unableToStartVideoEffect?: NotificationBarStrings;\n /**\n * An error message when starting spotlight while max participants are spotlighted\n */\n startSpotlightWhileMaxParticipantsAreSpotlighted: NotificationBarStrings;\n}\n\n/**\n * All notifications that can be shown in the {@link Notifications}.\n *\n * @beta\n */\nexport type NotificationType = keyof NotificationsStrings;\n\n/**\n * Active notifications to be shown via {@link Notifications}.\n *\n * @beta\n */\nexport interface ActiveNotification {\n /**\n * Type of error that is active.\n */\n type: NotificationType;\n /**\n * Callback called when the primary button inside notification bar is clicked.\n */\n onClickPrimaryButton?: () => void;\n\n /**\n * Callback called when the primary button inside notification bar is clicked.\n */\n onClickSecondaryButton?: () => void;\n\n /**\n * Callback called when the notification is dismissed.\n */\n onDismiss?: () => void;\n\n /**\n * If set, notification will automatically dismiss after 5 seconds\n */\n autoDismiss?: boolean;\n}\n\n/**\n * A component to show notifications on the UI.\n * All strings that can be shown are accepted as the {@link NotificationsProps.strings} so that they can be localized.\n * Active notifications are selected by {@link NotificationsProps.activeNotifications}.\n *\n * This component internally tracks dismissed by the user.\n * * Notifications that have an associated timestamp: The notification is shown on the UI again if it occurs after being dismissed.\n * * Notifications that do not have a timestamp: The notification is dismissed until it disappears from the props.\n * If the notification recurs, it is shown in the UI.\n *\n *\n * @beta\n */\nexport const Notifications = (props: NotificationsProps): JSX.Element => {\n const strings = props.strings;\n const maxNotificationsToShow = props.maxNotificationsToShow ?? 2;\n const [activeNotifications, setActiveNotifications] = useState<ActiveNotification[]>(props.activeNotifications);\n useEffect(() => {\n setActiveNotifications(props.activeNotifications);\n }, [props.activeNotifications]);\n return <Stack data-ui-id=\"notifications-stack\" style={{\n width: 'fit-content'\n }}>\n {activeNotifications.map((notification, index) => {\n if (index < maxNotificationsToShow) {\n return <div key={index} style={{\n marginBottom: `${index === maxNotificationsToShow - 1 ? 0 : '0.25rem'}`\n }}>\n <NotificationBar notificationBarStrings={strings ? strings[notification.type] : undefined} notificationBarIconProps={NotificationIconProps(notification.type)} onClickPrimaryButton={() => notification.onClickPrimaryButton?.()} onClickSecondaryButton={() => notification.onClickSecondaryButton?.()} onDismiss={() => {\n activeNotifications.splice(index, 1);\n setActiveNotifications([...activeNotifications]);\n notification.onDismiss && notification.onDismiss();\n }} showStackedEffect={index === maxNotificationsToShow - 1 && activeNotifications.length > maxNotificationsToShow} autoDismiss={notification.autoDismiss} />\n </div>;\n } else {\n return <></>;\n }\n })}\n </Stack>;\n};"]}
@@ -1,9 +0,0 @@
1
- import { ContextMenuPluginBase } from 'roosterjs-content-model-plugins';
2
- import type { IContextualMenuItem } from '@fluentui/react/';
3
- /**
4
- * Represents a plugin that adds a context menu to the rich text editor.
5
- */
6
- export declare class ContextMenuPlugin extends ContextMenuPluginBase<IContextualMenuItem> {
7
- constructor(onRender: (container: HTMLElement, items: IContextualMenuItem[], onDismiss: () => void) => void, onDismiss: () => void);
8
- }
9
- //# sourceMappingURL=ContextMenuPlugin.d.ts.map
@@ -1,29 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { ContextMenuPluginBase } from 'roosterjs-content-model-plugins';
4
- /**
5
- * Represents a plugin that adds a context menu to the rich text editor.
6
- */
7
- export class ContextMenuPlugin extends ContextMenuPluginBase {
8
- constructor(onRender, onDismiss) {
9
- super({
10
- /**
11
- * Renders the context menu in the specified container with the provided items.
12
- * @param container - The container element where the context menu should be rendered.
13
- * @param items - The items to be displayed in the context menu.
14
- * @param onDismiss - Callback function to be called when the context menu is dismissed. It will call `dismiss` method.
15
- */
16
- render: (container, items, onDismissCallback) => {
17
- const filteredItems = items.filter((item) => item !== null);
18
- onRender(container, filteredItems, onDismissCallback);
19
- },
20
- /**
21
- * Dismisses the context menu.
22
- */
23
- dismiss: () => {
24
- onDismiss();
25
- }
26
- });
27
- }
28
- }
29
- //# sourceMappingURL=ContextMenuPlugin.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ContextMenuPlugin.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-components/src/components/RichTextEditor/Plugins/ContextMenuPlugin.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AAGxE;;GAEG;AACH,MAAM,OAAO,iBAAkB,SAAQ,qBAA0C;IAC/E,YAAY,QAA+F,EAAE,SAAqB;QAChI,KAAK,CAAC;YACJ;;;;;eAKG;YACH,MAAM,EAAE,CAAC,SAAS,EAAE,KAAK,EAAE,iBAAiB,EAAE,EAAE;gBAC9C,MAAM,aAAa,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAA+B,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC;gBACzF,QAAQ,CAAC,SAAS,EAAE,aAAa,EAAE,iBAAiB,CAAC,CAAC;YACxD,CAAC;YACD;;eAEG;YACH,OAAO,EAAE,GAAG,EAAE;gBACZ,SAAS,EAAE,CAAC;YACd,CAAC;SACF,CAAC,CAAC;IACL,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { ContextMenuPluginBase } from 'roosterjs-content-model-plugins';\nimport type { IContextualMenuItem } from '@fluentui/react/';\n\n/**\n * Represents a plugin that adds a context menu to the rich text editor.\n */\nexport class ContextMenuPlugin extends ContextMenuPluginBase<IContextualMenuItem> {\n constructor(onRender: (container: HTMLElement, items: IContextualMenuItem[], onDismiss: () => void) => void, onDismiss: () => void) {\n super({\n /**\n * Renders the context menu in the specified container with the provided items.\n * @param container - The container element where the context menu should be rendered.\n * @param items - The items to be displayed in the context menu.\n * @param onDismiss - Callback function to be called when the context menu is dismissed. It will call `dismiss` method.\n */\n render: (container, items, onDismissCallback) => {\n const filteredItems = items.filter((item): item is IContextualMenuItem => item !== null);\n onRender(container, filteredItems, onDismissCallback);\n },\n /**\n * Dismisses the context menu.\n */\n dismiss: () => {\n onDismiss();\n }\n });\n }\n}"]}
@@ -1,22 +0,0 @@
1
- import type { PluginEvent, EditorPlugin, IEditor, BeforePasteEvent } from 'roosterjs-content-model-types';
2
- /**
3
- * CopyPastePlugin is a plugin for handling copy and paste events in the editor.
4
- */
5
- export default class CopyPastePlugin implements EditorPlugin {
6
- private editor;
7
- getName(): string;
8
- initialize(editor: IEditor): void;
9
- dispose(): void;
10
- onPluginEvent(event: PluginEvent): void;
11
- }
12
- /**
13
- * @internal
14
- * Exported only for unit testing
15
- */
16
- export declare const removeImageElement: (event: BeforePasteEvent) => void;
17
- /**
18
- * Update the scroll position of the editor after pasting content to ensure the content is visible.
19
- * @param event - The plugin event.
20
- */
21
- export declare const scrollToBottomAfterContentPaste: (event: PluginEvent) => void;
22
- //# sourceMappingURL=CopyPastePlugin.d.ts.map
@@ -1,89 +0,0 @@
1
- import { ContentChangedEventSource, PluginEventType } from '../../utils/RichTextEditorUtils';
2
- /**
3
- * CopyPastePlugin is a plugin for handling copy and paste events in the editor.
4
- */
5
- export default class CopyPastePlugin {
6
- constructor() {
7
- this.editor = null;
8
- }
9
- // don't set value in constructor to be able to update it without plugin recreation
10
- getName() {
11
- return 'CopyPastePlugin';
12
- }
13
- initialize(editor) {
14
- this.editor = editor;
15
- }
16
- dispose() { }
17
- onPluginEvent(event) {
18
- handleBeforePasteEvent(event);
19
- if (this.editor !== null && !this.editor.isDisposed()) {
20
- // scroll the editor to the correct position after pasting content
21
- scrollToBottomAfterContentPaste(event);
22
- }
23
- }
24
- }
25
- const handleBeforePasteEvent = (event, onPaste) => {
26
- if (event.eventType === PluginEventType.BeforePaste && event.pasteType === 'normal') {
27
- // the initial behavior
28
- // removes inline image elements from the pasted content when rich-text-editor-image-upload not available
29
- removeImageElement(event);
30
- }
31
- };
32
- /**
33
- * @internal
34
- * Exported only for unit testing
35
- */
36
- export const removeImageElement = (event) => {
37
- // We don't support the pasting options such as paste as image yet.
38
- if (event.pasteType === 'normal') {
39
- event.fragment.querySelectorAll('img').forEach(image => {
40
- // If the image is the only child of its parent, remove all the parents of this img element.
41
- let parentNode = image.parentElement;
42
- let currentNode = image;
43
- while ((parentNode === null || parentNode === void 0 ? void 0 : parentNode.childNodes.length) === 1) {
44
- currentNode = parentNode;
45
- parentNode = parentNode.parentElement;
46
- }
47
- currentNode === null || currentNode === void 0 ? void 0 : currentNode.remove();
48
- });
49
- }
50
- };
51
- /**
52
- * Update the scroll position of the editor after pasting content to ensure the content is visible.
53
- * @param event - The plugin event.
54
- */
55
- export const scrollToBottomAfterContentPaste = (event) => {
56
- if (event.eventType === PluginEventType.ContentChanged && event.source === ContentChangedEventSource.Paste) {
57
- // Get the current selection in the document
58
- const selection = document.getSelection();
59
- // Check if a selection exists and it has at least one range
60
- if (!selection || selection.rangeCount <= 0) {
61
- // If no selection or range, exit the function
62
- return;
63
- }
64
- // Get the first range of the selection
65
- // A user can normally only select one range at a time, so the rangeCount will usually be 1
66
- const range = selection.getRangeAt(0);
67
- // If the common ancestor container of the range is the document itself,
68
- // it might mean that the editable element is getting removed from the DOM
69
- // In such cases, especially in Safari, trying to modify the range might throw a HierarchyRequest error
70
- if (range.commonAncestorContainer === document) {
71
- return;
72
- }
73
- // Create a temporary span element to use as an anchor for scrolling
74
- // We can't use the anchor node directly because if it's a Text node, calling scrollIntoView() on it will throw an error
75
- const tempElement = document.createElement('span');
76
- // Collapse the range to its end point
77
- // This means the start and end points of the range will be the same, and it will not contain any content
78
- range.collapse(false);
79
- // Insert the temporary element at the cursor's position at the end of the range
80
- range.insertNode(tempElement);
81
- // Scroll the temporary element into view
82
- // the element will be aligned at the center of the scroll container, otherwise, text and images may be positioned incorrectly
83
- tempElement.scrollIntoView({
84
- block: 'center'
85
- });
86
- tempElement.remove();
87
- }
88
- };
89
- //# sourceMappingURL=CopyPastePlugin.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CopyPastePlugin.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.tsx"],"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AAW,CAAC,MAAM,EAAE,CAAC;IACvB,CAAC;AACH,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\nimport type { PluginEvent, EditorPlugin, IEditor, BeforePasteEvent } from 'roosterjs-content-model-types';\nimport { ContentChangedEventSource, PluginEventType } from '../../utils/RichTextEditorUtils';\n\n/**\n * CopyPastePlugin is a plugin for handling copy and paste events in the editor.\n */\nexport default class CopyPastePlugin implements EditorPlugin {\n private editor: IEditor | null = null;\n // don't set value in constructor to be able to update it without plugin recreation\n getName(): string {\n return 'CopyPastePlugin';\n }\n initialize(editor: IEditor): void {\n this.editor = editor;\n }\n dispose(): void {}\n onPluginEvent(event: PluginEvent): void {\n handleBeforePasteEvent(event);\n if (this.editor !== null && !this.editor.isDisposed()) {\n // scroll the editor to the correct position after pasting content\n scrollToBottomAfterContentPaste(event);\n }\n }\n}\nconst handleBeforePasteEvent = (event: PluginEvent, onPaste?: (event: {\n content: DocumentFragment;\n}) => void): void => {\n if (event.eventType === PluginEventType.BeforePaste && event.pasteType === 'normal') {\n // the initial behavior\n // removes inline image elements from the pasted content when rich-text-editor-image-upload not available\n removeImageElement((event as BeforePasteEvent));\n }\n};\n\n/**\n * @internal\n * Exported only for unit testing\n */\nexport const removeImageElement = (event: BeforePasteEvent): void => {\n // We don't support the pasting options such as paste as image yet.\n if (event.pasteType === 'normal') {\n event.fragment.querySelectorAll('img').forEach(image => {\n // If the image is the only child of its parent, remove all the parents of this img element.\n let parentNode: HTMLElement | null = image.parentElement;\n let currentNode: HTMLElement = image;\n while (parentNode?.childNodes.length === 1) {\n currentNode = parentNode;\n parentNode = parentNode.parentElement;\n }\n currentNode?.remove();\n });\n }\n};\n\n/**\n * Update the scroll position of the editor after pasting content to ensure the content is visible.\n * @param event - The plugin event.\n */\nexport const scrollToBottomAfterContentPaste = (event: PluginEvent): void => {\n if (event.eventType === PluginEventType.ContentChanged && event.source === ContentChangedEventSource.Paste) {\n // Get the current selection in the document\n const selection = document.getSelection();\n\n // Check if a selection exists and it has at least one range\n if (!selection || selection.rangeCount <= 0) {\n // If no selection or range, exit the function\n return;\n }\n\n // Get the first range of the selection\n // A user can normally only select one range at a time, so the rangeCount will usually be 1\n const range = selection.getRangeAt(0);\n\n // If the common ancestor container of the range is the document itself,\n // it might mean that the editable element is getting removed from the DOM\n // In such cases, especially in Safari, trying to modify the range might throw a HierarchyRequest error\n if (range.commonAncestorContainer === document) {\n return;\n }\n\n // Create a temporary span element to use as an anchor for scrolling\n // We can't use the anchor node directly because if it's a Text node, calling scrollIntoView() on it will throw an error\n const tempElement = document.createElement('span');\n // Collapse the range to its end point\n // This means the start and end points of the range will be the same, and it will not contain any content\n range.collapse(false);\n // Insert the temporary element at the cursor's position at the end of the range\n range.insertNode(tempElement);\n\n // Scroll the temporary element into view\n // the element will be aligned at the center of the scroll container, otherwise, text and images may be positioned incorrectly\n tempElement.scrollIntoView({\n block: 'center'\n });\n tempElement.remove();\n }\n};"]}
@@ -1,12 +0,0 @@
1
- import type { PluginEvent, EditorPlugin } from 'roosterjs-content-model-types';
2
- /**
3
- * KeyboardInputPlugin is a plugin for handling keyboard events in the editor.
4
- */
5
- export declare class KeyboardInputPlugin implements EditorPlugin {
6
- onKeyDown?: ((event: KeyboardEvent) => void) | null;
7
- getName(): string;
8
- initialize(): void;
9
- dispose(): void;
10
- onPluginEvent(event: PluginEvent): void;
11
- }
12
- //# sourceMappingURL=KeyboardInputPlugin.d.ts.map
@@ -1,23 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { PluginEventType } from '../../utils/RichTextEditorUtils';
4
- /**
5
- * KeyboardInputPlugin is a plugin for handling keyboard events in the editor.
6
- */
7
- export class KeyboardInputPlugin {
8
- constructor() {
9
- // don't set callback in constructor to be able to update callback without plugin recreation
10
- this.onKeyDown = null;
11
- }
12
- getName() {
13
- return 'KeyboardInputPlugin';
14
- }
15
- initialize() { }
16
- dispose() { }
17
- onPluginEvent(event) {
18
- if (this.onKeyDown && event.eventType === PluginEventType.KeyDown && event.rawEvent instanceof KeyboardEvent) {
19
- this.onKeyDown(event.rawEvent);
20
- }
21
- }
22
- }
23
- //# sourceMappingURL=KeyboardInputPlugin.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"KeyboardInputPlugin.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-components/src/components/RichTextEditor/Plugins/KeyboardInputPlugin.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAGlC,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAElE;;GAEG;AACH,MAAM,OAAO,mBAAmB;IAAhC;QACE,4FAA4F;QAC5F,cAAS,GAA6C,IAAI,CAAC;IAW7D,CAAC;IAVC,OAAO;QACL,OAAO,qBAAqB,CAAC;IAC/B,CAAC;IACD,UAAU,KAAU,CAAC;IACrB,OAAO,KAAU,CAAC;IAClB,aAAa,CAAC,KAAkB;QAC9B,IAAI,IAAI,CAAC,SAAS,IAAI,KAAK,CAAC,SAAS,KAAK,eAAe,CAAC,OAAO,IAAI,KAAK,CAAC,QAAQ,YAAY,aAAa,EAAE,CAAC;YAC7G,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;QACjC,CAAC;IACH,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport type { PluginEvent, EditorPlugin } from 'roosterjs-content-model-types';\nimport { PluginEventType } from '../../utils/RichTextEditorUtils';\n\n/**\n * KeyboardInputPlugin is a plugin for handling keyboard events in the editor.\n */\nexport class KeyboardInputPlugin implements EditorPlugin {\n // don't set callback in constructor to be able to update callback without plugin recreation\n onKeyDown?: ((event: KeyboardEvent) => void) | null = null;\n getName(): string {\n return 'KeyboardInputPlugin';\n }\n initialize(): void {}\n dispose(): void {}\n onPluginEvent(event: PluginEvent): void {\n if (this.onKeyDown && event.eventType === PluginEventType.KeyDown && event.rawEvent instanceof KeyboardEvent) {\n this.onKeyDown(event.rawEvent);\n }\n }\n}"]}
@@ -1,15 +0,0 @@
1
- import { WatermarkPlugin } from 'roosterjs-content-model-plugins';
2
- import type { /*PluginEvent, EditorPlugin,*/ IEditor } from 'roosterjs-content-model-types';
3
- /**
4
- * PlaceholderPlugin is a plugin for displaying placeholder and handle localization for it in the editor.
5
- */
6
- export default class PlaceholderPlugin extends WatermarkPlugin {
7
- private isPlaceholderShown;
8
- private editorValue;
9
- updatePlaceholder(placeholder: string): void;
10
- initialize(editor: IEditor): void;
11
- dispose(): void;
12
- protected show(editor: IEditor): void;
13
- protected hide(editor: IEditor): void;
14
- }
15
- //# sourceMappingURL=PlaceholderPlugin.d.ts.map
@@ -1,39 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { WatermarkPlugin } from 'roosterjs-content-model-plugins';
4
- /**
5
- * PlaceholderPlugin is a plugin for displaying placeholder and handle localization for it in the editor.
6
- */
7
- export default class PlaceholderPlugin extends WatermarkPlugin {
8
- constructor() {
9
- super(...arguments);
10
- this.isPlaceholderShown = false;
11
- this.editorValue = null;
12
- }
13
- updatePlaceholder(placeholder) {
14
- this.watermark = placeholder;
15
- // hide and show the placeholder to show the latest one
16
- // this needs to be done only if the placeholder is currently shown
17
- if (this.editorValue && this.isPlaceholderShown) {
18
- this.hide(this.editorValue);
19
- this.show(this.editorValue);
20
- }
21
- }
22
- initialize(editor) {
23
- this.editorValue = editor;
24
- super.initialize(editor);
25
- }
26
- dispose() {
27
- this.editorValue = null;
28
- super.dispose();
29
- }
30
- show(editor) {
31
- super.show(editor);
32
- this.isPlaceholderShown = true;
33
- }
34
- hide(editor) {
35
- super.hide(editor);
36
- this.isPlaceholderShown = false;
37
- }
38
- }
39
- //# sourceMappingURL=PlaceholderPlugin.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PlaceholderPlugin.js","sourceRoot":"","sources":["../../../../../../../preprocess-dist/react-components/src/components/RichTextEditor/Plugins/PlaceholderPlugin.tsx"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAGlE;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,iBAAkB,SAAQ,eAAe;IAA9D;;QACU,uBAAkB,GAAY,KAAK,CAAC;QACpC,gBAAW,GAAmB,IAAI,CAAC;IA0B7C,CAAC;IAzBC,iBAAiB,CAAC,WAAmB;QACnC,IAAI,CAAC,SAAS,GAAG,WAAW,CAAC;QAC7B,uDAAuD;QACvD,mEAAmE;QACnE,IAAI,IAAI,CAAC,WAAW,IAAI,IAAI,CAAC,kBAAkB,EAAE,CAAC;YAChD,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;YAC5B,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;QAC9B,CAAC;IACH,CAAC;IACD,UAAU,CAAC,MAAe;QACxB,IAAI,CAAC,WAAW,GAAG,MAAM,CAAC;QAC1B,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;IAC3B,CAAC;IACD,OAAO;QACL,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;QACxB,KAAK,CAAC,OAAO,EAAE,CAAC;IAClB,CAAC;IACS,IAAI,CAAC,MAAe;QAC5B,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACnB,IAAI,CAAC,kBAAkB,GAAG,IAAI,CAAC;IACjC,CAAC;IACS,IAAI,CAAC,MAAe;QAC5B,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACnB,IAAI,CAAC,kBAAkB,GAAG,KAAK,CAAC;IAClC,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\nimport { WatermarkPlugin } from 'roosterjs-content-model-plugins';\nimport type { /*PluginEvent, EditorPlugin,*/IEditor } from 'roosterjs-content-model-types';\n\n/**\n * PlaceholderPlugin is a plugin for displaying placeholder and handle localization for it in the editor.\n */\nexport default class PlaceholderPlugin extends WatermarkPlugin {\n private isPlaceholderShown: boolean = false;\n private editorValue: IEditor | null = null;\n updatePlaceholder(placeholder: string): void {\n this.watermark = placeholder;\n // hide and show the placeholder to show the latest one\n // this needs to be done only if the placeholder is currently shown\n if (this.editorValue && this.isPlaceholderShown) {\n this.hide(this.editorValue);\n this.show(this.editorValue);\n }\n }\n initialize(editor: IEditor): void {\n this.editorValue = editor;\n super.initialize(editor);\n }\n dispose(): void {\n this.editorValue = null;\n super.dispose();\n }\n protected show(editor: IEditor): void {\n super.show(editor);\n this.isPlaceholderShown = true;\n }\n protected hide(editor: IEditor): void {\n super.hide(editor);\n this.isPlaceholderShown = false;\n }\n}"]}
@@ -1,24 +0,0 @@
1
- import type { ContentModelFormatState, EditorPlugin, IEditor, PluginEvent } from 'roosterjs-content-model-types';
2
- /**
3
- * KeyboardInputPlugin is a plugin for handling keyboard events in the editor.
4
- */
5
- export declare class RichTextToolbarPlugin implements EditorPlugin {
6
- private formatState;
7
- private editor;
8
- onFormatChanged: ((formatState: ContentModelFormatState) => void) | null;
9
- getName(): string;
10
- initialize(editor: IEditor): void;
11
- dispose(): void;
12
- onPluginEvent(event: PluginEvent): void;
13
- /**
14
- * Handles the click event of a toolbar button.
15
- * @param buttonAction - The action to be performed when the button is clicked.
16
- */
17
- onToolbarButtonClick(buttonAction: (editor: IEditor) => void): void;
18
- /**
19
- * Updates the format state of the rich text editor and triggers the `onFormatChanged` callback
20
- * if there is any difference between the new and the current format states.
21
- */
22
- private updateFormat;
23
- }
24
- //# sourceMappingURL=RichTextToolbarPlugin.d.ts.map
@@ -1,64 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- import { getFormatState } from 'roosterjs-content-model-api';
4
- import { getObjectKeys } from 'roosterjs-content-model-dom';
5
- import { PluginEventType } from '../../utils/RichTextEditorUtils';
6
- /**
7
- * KeyboardInputPlugin is a plugin for handling keyboard events in the editor.
8
- */
9
- export class RichTextToolbarPlugin {
10
- constructor() {
11
- this.formatState = null;
12
- this.editor = null;
13
- this.onFormatChanged = null;
14
- }
15
- getName() {
16
- return 'RichTextToolbarPlugin';
17
- }
18
- initialize(editor) {
19
- this.editor = editor;
20
- }
21
- dispose() {
22
- this.editor = null;
23
- }
24
- onPluginEvent(event) {
25
- switch (event.eventType) {
26
- // KeyDown and MouseUp are used to update the state when the editor is already shown and focused by the user
27
- case PluginEventType.EditorReady:
28
- case PluginEventType.ContentChanged:
29
- case PluginEventType.ZoomChanged:
30
- case PluginEventType.KeyDown:
31
- case PluginEventType.MouseUp:
32
- this.updateFormat();
33
- break;
34
- }
35
- }
36
- /**
37
- * Handles the click event of a toolbar button.
38
- * @param buttonAction - The action to be performed when the button is clicked.
39
- */
40
- onToolbarButtonClick(buttonAction) {
41
- if (this.editor && !this.editor.isDisposed()) {
42
- buttonAction(this.editor);
43
- this.updateFormat();
44
- }
45
- }
46
- /**
47
- * Updates the format state of the rich text editor and triggers the `onFormatChanged` callback
48
- * if there is any difference between the new and the current format states.
49
- */
50
- updateFormat() {
51
- if (this.editor && this.onFormatChanged) {
52
- const newFormatState = getFormatState(this.editor);
53
- // use keys from the format that has more keys or the new format state if there is no current format state
54
- const keys = !this.formatState || getObjectKeys(newFormatState).length > getObjectKeys(this.formatState).length ? getObjectKeys(newFormatState) : getObjectKeys(this.formatState);
55
- // check if there is any difference between the new format state and the current format state
56
- // otherwise the states will produce new objects every time even when the format state is the same
57
- if (!this.formatState || keys.some(key => { var _a; return newFormatState[key] !== ((_a = this.formatState) === null || _a === void 0 ? void 0 : _a[key]); })) {
58
- this.formatState = newFormatState;
59
- this.onFormatChanged(newFormatState);
60
- }
61
- }
62
- }
63
- }
64
- //# sourceMappingURL=RichTextToolbarPlugin.js.map