@microsoft/omnichannel-chat-components 0.1.0-main.edd8c2a → 0.1.0-main.edfd7fe

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 (193) hide show
  1. package/README.md +1 -0
  2. package/lib/cjs/assets/Icons.js +48 -0
  3. package/lib/cjs/common/Constants.js +12 -7
  4. package/lib/cjs/common/utils.js +21 -2
  5. package/lib/cjs/components/callingcontainer/subcomponents/CurrentCall/CurrentCall.js +31 -1
  6. package/lib/cjs/components/callingcontainer/subcomponents/CurrentCall/common/defaultProps/defaultCurrentCallControlPropsRtl.js +6 -16
  7. package/lib/cjs/components/callingcontainer/subcomponents/CurrentCall/common/defaultStyles/customizedCurrentCallStyleProps.js +0 -12
  8. package/lib/cjs/components/callingcontainer/subcomponents/CurrentCall/common/defaultStyles/defaultCurrentCallStyleProps.js +0 -12
  9. package/lib/cjs/components/callingcontainer/subcomponents/IncomingCall/IncomingCall.js +45 -2
  10. package/lib/cjs/components/callingcontainer/subcomponents/IncomingCall/common/defaultProps/componentOverrideProps.js +2 -4
  11. package/lib/cjs/components/callingcontainer/subcomponents/IncomingCall/common/defaultProps/defaultIncomingCallControlPropsRtl.js +4 -10
  12. package/lib/cjs/components/chatbutton/ChatButton.js +37 -26
  13. package/lib/cjs/components/chatbutton/common/defaultProps/defaultChatButtonControlProps.js +5 -2
  14. package/lib/cjs/components/chatbutton/common/defaultStyles/defaultChatButtonIconContainerStyles.js +2 -4
  15. package/lib/cjs/components/chatbutton/common/defaultStyles/defaultChatButtonSubTitleStyles.js +3 -1
  16. package/lib/cjs/components/chatbutton/common/defaultStyles/defaultChatButtonTitleStyles.js +1 -0
  17. package/lib/cjs/components/common/commandbutton/CommandButton.js +36 -10
  18. package/lib/cjs/components/{header → common}/subcomponents/CloseButton.js +4 -3
  19. package/lib/cjs/components/confirmationpane/ConfirmationPane.js +19 -10
  20. package/lib/cjs/components/confirmationpane/common/defaultStyles/defaultConfirmationPaneButtonGroupStyles.js +5 -1
  21. package/lib/cjs/components/confirmationpane/common/defaultStyles/defaultConfirmationPaneGeneralStyles.js +7 -4
  22. package/lib/cjs/components/footer/Footer.js +2 -2
  23. package/lib/cjs/components/footer/common/defaultProps/customFooterControlProps.js +5 -13
  24. package/lib/cjs/components/footer/common/defaultProps/defaultFooterControlProps.js +1 -0
  25. package/lib/cjs/components/footer/common/defaultStyles/defaultFooterStyleProps.js +12 -6
  26. package/lib/cjs/components/footer/subcomponents/AudioNotificationButton.js +29 -11
  27. package/lib/cjs/components/header/Header.js +2 -2
  28. package/lib/cjs/components/header/common/defaultProps/azureHeaderControlProps.js +2 -4
  29. package/lib/cjs/components/header/common/defaultProps/customHeaderControlProps.js +4 -10
  30. package/lib/cjs/components/header/common/defaultProps/defaultHeaderControlProps.js +2 -4
  31. package/lib/cjs/components/inputvalidationpane/InputValidationPane.js +76 -46
  32. package/lib/cjs/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneCancelButtonStyles.js +2 -1
  33. package/lib/cjs/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneGeneralStyles.js +1 -1
  34. package/lib/cjs/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneInvalidInputErrorMessageStyles.js +1 -1
  35. package/lib/cjs/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneSendButtonStyles.js +2 -1
  36. package/lib/cjs/components/loadingpane/LoadingPane.js +2 -1
  37. package/lib/cjs/components/loadingpane/common/defaultProps/defaultStyles/defaultLoadingPaneIconImageProps.js +2 -4
  38. package/lib/cjs/components/loadingpane/common/defaultProps/defaultStyles/defaultLoadingPaneIconStyles.js +3 -2
  39. package/lib/cjs/components/loadingpane/common/presetThreeProps/presetThreeStyles/presetThreeLoadingPaneIconImageProps.js +2 -4
  40. package/lib/cjs/components/loadingpane/common/presetTwoProps/presetTwoStyles/presetTwoLoadingPaneGeneralStyles.js +2 -4
  41. package/lib/cjs/components/outofofficehourspane/OOOHPane.js +13 -6
  42. package/lib/cjs/components/outofofficehourspane/common/defaultProps/defaultOOOHPaneControlProps.js +3 -1
  43. package/lib/cjs/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneControlProps.js +15 -0
  44. package/lib/cjs/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneProps.js +16 -0
  45. package/lib/cjs/components/outofofficehourspane/common/presetTwoProps/presetTwoStyles/presetTwoOOOHPaneGeneralStyles.js +2 -4
  46. package/lib/cjs/components/postchatsurveypane/PostChatSurveyPane.js +3 -2
  47. package/lib/cjs/components/prechatsurveypane/PreChatSurveyPane.js +24 -9
  48. package/lib/cjs/components/prechatsurveypane/common/defaultProps/defaultPreChatSurveyPaneControlProps.js +1 -0
  49. package/lib/cjs/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneButtonStyles.js +5 -1
  50. package/lib/cjs/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneMultilineTextInputStyles.js +10 -0
  51. package/lib/cjs/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneStyles.js +7 -1
  52. package/lib/cjs/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneTextInputStyles.js +10 -0
  53. package/lib/cjs/components/proactivechatpane/ProactiveChatPane.js +33 -30
  54. package/lib/cjs/components/proactivechatpane/common/default/defaultProps/defaultProactiveChatPaneControlProps.js +5 -1
  55. package/lib/cjs/components/proactivechatpane/common/default/defaultStyles/defaultProactiveChatPaneCloseButtonStyles.js +2 -15
  56. package/lib/cjs/components/proactivechatpane/common/default/defaultStyles/defaultProactiveChatPaneHeaderContainerStyles.js +2 -4
  57. package/lib/cjs/components/proactivechatpane/common/presetOne/presetOneProps/presetOneProactiveChatPaneControlProps.js +5 -1
  58. package/lib/cjs/components/proactivechatpane/common/presetThree/presetThreeProps/presetThreeProactiveChatPaneControlProps.js +5 -1
  59. package/lib/cjs/components/reconnectchatpane/ReconnectChatPane.js +14 -12
  60. package/lib/cjs/components/reconnectchatpane/common/default/defaultStyles/defaultReconnectChatPaneIconStyles.js +2 -4
  61. package/lib/cjs/index.js +134 -0
  62. package/lib/cjs/services/BroadcastService.js +36 -8
  63. package/lib/esm/assets/Icons.js +21 -0
  64. package/lib/esm/common/Constants.js +10 -5
  65. package/lib/esm/common/utils.js +16 -0
  66. package/lib/esm/components/callingcontainer/subcomponents/CurrentCall/CurrentCall.js +33 -3
  67. package/lib/esm/components/callingcontainer/subcomponents/CurrentCall/common/defaultProps/defaultCurrentCallControlPropsRtl.js +6 -10
  68. package/lib/esm/components/callingcontainer/subcomponents/CurrentCall/common/defaultStyles/customizedCurrentCallStyleProps.js +0 -12
  69. package/lib/esm/components/callingcontainer/subcomponents/CurrentCall/common/defaultStyles/defaultCurrentCallStyleProps.js +0 -12
  70. package/lib/esm/components/callingcontainer/subcomponents/IncomingCall/IncomingCall.js +47 -4
  71. package/lib/esm/components/callingcontainer/subcomponents/IncomingCall/common/defaultProps/componentOverrideProps.js +2 -2
  72. package/lib/esm/components/callingcontainer/subcomponents/IncomingCall/common/defaultProps/defaultIncomingCallControlPropsRtl.js +4 -6
  73. package/lib/esm/components/chatbutton/ChatButton.js +37 -26
  74. package/lib/esm/components/chatbutton/common/defaultProps/defaultChatButtonControlProps.js +5 -2
  75. package/lib/esm/components/chatbutton/common/defaultStyles/defaultChatButtonIconContainerStyles.js +2 -2
  76. package/lib/esm/components/chatbutton/common/defaultStyles/defaultChatButtonSubTitleStyles.js +3 -1
  77. package/lib/esm/components/chatbutton/common/defaultStyles/defaultChatButtonTitleStyles.js +1 -0
  78. package/lib/esm/components/common/commandbutton/CommandButton.js +36 -10
  79. package/lib/esm/components/{header → common}/subcomponents/CloseButton.js +4 -3
  80. package/lib/esm/components/confirmationpane/ConfirmationPane.js +20 -11
  81. package/lib/esm/components/confirmationpane/common/defaultStyles/defaultConfirmationPaneButtonGroupStyles.js +5 -1
  82. package/lib/esm/components/confirmationpane/common/defaultStyles/defaultConfirmationPaneGeneralStyles.js +7 -4
  83. package/lib/esm/components/footer/Footer.js +2 -2
  84. package/lib/esm/components/footer/common/defaultProps/customFooterControlProps.js +5 -8
  85. package/lib/esm/components/footer/common/defaultProps/defaultFooterControlProps.js +1 -0
  86. package/lib/esm/components/footer/common/defaultStyles/defaultFooterStyleProps.js +12 -6
  87. package/lib/esm/components/footer/subcomponents/AudioNotificationButton.js +29 -11
  88. package/lib/esm/components/header/Header.js +2 -2
  89. package/lib/esm/components/header/common/defaultProps/azureHeaderControlProps.js +2 -2
  90. package/lib/esm/components/header/common/defaultProps/customHeaderControlProps.js +4 -6
  91. package/lib/esm/components/header/common/defaultProps/defaultHeaderControlProps.js +2 -2
  92. package/lib/esm/components/inputvalidationpane/InputValidationPane.js +77 -47
  93. package/lib/esm/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneCancelButtonStyles.js +2 -1
  94. package/lib/esm/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneGeneralStyles.js +1 -1
  95. package/lib/esm/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneInvalidInputErrorMessageStyles.js +1 -1
  96. package/lib/esm/components/inputvalidationpane/common/default/defaultStyles/defaultInputValidationPaneSendButtonStyles.js +2 -1
  97. package/lib/esm/components/loadingpane/LoadingPane.js +2 -1
  98. package/lib/esm/components/loadingpane/common/defaultProps/defaultStyles/defaultLoadingPaneIconImageProps.js +2 -2
  99. package/lib/esm/components/loadingpane/common/defaultProps/defaultStyles/defaultLoadingPaneIconStyles.js +3 -2
  100. package/lib/esm/components/loadingpane/common/presetThreeProps/presetThreeStyles/presetThreeLoadingPaneIconImageProps.js +2 -2
  101. package/lib/esm/components/loadingpane/common/presetTwoProps/presetTwoStyles/presetTwoLoadingPaneGeneralStyles.js +2 -2
  102. package/lib/esm/components/outofofficehourspane/OOOHPane.js +13 -7
  103. package/lib/esm/components/outofofficehourspane/common/defaultProps/defaultOOOHPaneControlProps.js +3 -1
  104. package/lib/esm/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneControlProps.js +6 -0
  105. package/lib/esm/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneProps.js +6 -0
  106. package/lib/esm/components/outofofficehourspane/common/presetTwoProps/presetTwoStyles/presetTwoOOOHPaneGeneralStyles.js +2 -2
  107. package/lib/esm/components/postchatsurveypane/PostChatSurveyPane.js +3 -2
  108. package/lib/esm/components/prechatsurveypane/PreChatSurveyPane.js +24 -9
  109. package/lib/esm/components/prechatsurveypane/common/defaultProps/defaultPreChatSurveyPaneControlProps.js +1 -0
  110. package/lib/esm/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneButtonStyles.js +5 -1
  111. package/lib/esm/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneMultilineTextInputStyles.js +3 -0
  112. package/lib/esm/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneStyles.js +5 -1
  113. package/lib/esm/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneTextInputStyles.js +3 -0
  114. package/lib/esm/components/prechatsurveypane/interfaces/IPreChatSurveyPaneElementStyles.js +1 -0
  115. package/lib/esm/components/proactivechatpane/ProactiveChatPane.js +30 -29
  116. package/lib/esm/components/proactivechatpane/common/default/defaultProps/defaultProactiveChatPaneControlProps.js +5 -1
  117. package/lib/esm/components/proactivechatpane/common/default/defaultStyles/defaultProactiveChatPaneCloseButtonStyles.js +2 -11
  118. package/lib/esm/components/proactivechatpane/common/default/defaultStyles/defaultProactiveChatPaneHeaderContainerStyles.js +2 -2
  119. package/lib/esm/components/proactivechatpane/common/presetOne/presetOneProps/presetOneProactiveChatPaneControlProps.js +5 -1
  120. package/lib/esm/components/proactivechatpane/common/presetThree/presetThreeProps/presetThreeProactiveChatPaneControlProps.js +5 -1
  121. package/lib/esm/components/reconnectchatpane/ReconnectChatPane.js +14 -12
  122. package/lib/esm/components/reconnectchatpane/common/default/defaultStyles/defaultReconnectChatPaneIconStyles.js +2 -2
  123. package/lib/esm/index.js +3 -1
  124. package/lib/esm/services/BroadcastService.js +34 -8
  125. package/lib/types/assets/Icons.d.ts +21 -0
  126. package/lib/types/common/Constants.d.ts +8 -2
  127. package/lib/types/common/utils.d.ts +1 -0
  128. package/lib/types/components/callingcontainer/subcomponents/CurrentCall/interfaces/ICurrentCallStyleProps.d.ts +0 -4
  129. package/lib/types/components/chatbutton/interfaces/IChatButtonControlProps.d.ts +3 -0
  130. package/lib/types/components/common/interfaces/ICommandButtonControlProps.d.ts +1 -0
  131. package/lib/types/components/common/interfaces/ICommandButtonProps.d.ts +1 -0
  132. package/lib/types/components/{header → common}/subcomponents/CloseButton.d.ts +1 -1
  133. package/lib/types/components/confirmationpane/interfaces/IConfirmationPaneControlProps.d.ts +0 -1
  134. package/lib/types/components/inputvalidationpane/interfaces/IInputValidationPaneControlProps.d.ts +0 -1
  135. package/lib/types/components/loadingpane/interfaces/ILoadingPaneProps.d.ts +2 -0
  136. package/lib/types/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneControlProps.d.ts +2 -0
  137. package/lib/types/components/outofofficehourspane/common/presetFourProps/presetFourOOOHPaneProps.d.ts +2 -0
  138. package/lib/types/components/outofofficehourspane/interfaces/IOOOHPaneControlProps.d.ts +1 -0
  139. package/lib/types/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneMultilineTextInputStyles.d.ts +2 -0
  140. package/lib/types/components/prechatsurveypane/common/defaultProps/defaultStyles/defaultPreChatSurveyPaneTextInputStyles.d.ts +2 -0
  141. package/lib/types/components/prechatsurveypane/interfaces/IPreChatSurveyPaneButtonStyles.d.ts +4 -0
  142. package/lib/types/components/prechatsurveypane/interfaces/IPreChatSurveyPaneElementStyles.d.ts +5 -0
  143. package/lib/types/components/prechatsurveypane/interfaces/IPreChatSurveyPaneStyleProps.d.ts +5 -0
  144. package/lib/types/components/proactivechatpane/interfaces/IProactiveChatPaneControlProps.d.ts +2 -1
  145. package/lib/types/index.d.ts +2 -0
  146. package/lib/types/services/BroadcastService.d.ts +1 -0
  147. package/package.json +5 -10
  148. package/lib/cjs/assets/imgs/ChatBubble.svg +0 -28
  149. package/lib/cjs/assets/imgs/ChatReconnectPopupIcon.png +0 -0
  150. package/lib/cjs/assets/imgs/Proactive_banner.png +0 -0
  151. package/lib/cjs/assets/imgs/agent.png +0 -0
  152. package/lib/cjs/assets/imgs/callacceptbutton.svg +0 -3
  153. package/lib/cjs/assets/imgs/callrejectbutton.svg +0 -3
  154. package/lib/cjs/assets/imgs/chat.svg +0 -47
  155. package/lib/cjs/assets/imgs/chatIcon.svg +0 -16
  156. package/lib/cjs/assets/imgs/closeButton.svg +0 -3
  157. package/lib/cjs/assets/imgs/closeChatButton.svg +0 -3
  158. package/lib/cjs/assets/imgs/error.svg +0 -3
  159. package/lib/cjs/assets/imgs/lcwAudioOff.svg +0 -3
  160. package/lib/cjs/assets/imgs/lcwAudioOn.svg +0 -3
  161. package/lib/cjs/assets/imgs/loading.gif +0 -0
  162. package/lib/cjs/assets/imgs/minimizeChatButton.svg +0 -3
  163. package/lib/cjs/assets/imgs/transcriptDownloadIcon.svg +0 -4
  164. package/lib/cjs/assets/imgs/transcriptEmailIcon.svg +0 -5
  165. package/lib/cjs/assets/imgs/videocallacceptbutton.svg +0 -3
  166. package/lib/cjs/assets/imgs/videooff.svg +0 -3
  167. package/lib/cjs/assets/imgs/videoon.svg +0 -3
  168. package/lib/cjs/assets/imgs/voiceoff.svg +0 -3
  169. package/lib/cjs/assets/imgs/voiceon.svg +0 -3
  170. package/lib/esm/assets/assets.d.js +0 -0
  171. package/lib/esm/assets/imgs/ChatBubble.svg +0 -28
  172. package/lib/esm/assets/imgs/ChatReconnectPopupIcon.png +0 -0
  173. package/lib/esm/assets/imgs/Proactive_banner.png +0 -0
  174. package/lib/esm/assets/imgs/agent.png +0 -0
  175. package/lib/esm/assets/imgs/callacceptbutton.svg +0 -3
  176. package/lib/esm/assets/imgs/callrejectbutton.svg +0 -3
  177. package/lib/esm/assets/imgs/chat.svg +0 -47
  178. package/lib/esm/assets/imgs/chatIcon.svg +0 -16
  179. package/lib/esm/assets/imgs/closeButton.svg +0 -3
  180. package/lib/esm/assets/imgs/closeChatButton.svg +0 -3
  181. package/lib/esm/assets/imgs/error.svg +0 -3
  182. package/lib/esm/assets/imgs/lcwAudioOff.svg +0 -3
  183. package/lib/esm/assets/imgs/lcwAudioOn.svg +0 -3
  184. package/lib/esm/assets/imgs/loading.gif +0 -0
  185. package/lib/esm/assets/imgs/minimizeChatButton.svg +0 -3
  186. package/lib/esm/assets/imgs/transcriptDownloadIcon.svg +0 -4
  187. package/lib/esm/assets/imgs/transcriptEmailIcon.svg +0 -5
  188. package/lib/esm/assets/imgs/videocallacceptbutton.svg +0 -3
  189. package/lib/esm/assets/imgs/videooff.svg +0 -3
  190. package/lib/esm/assets/imgs/videoon.svg +0 -3
  191. package/lib/esm/assets/imgs/voiceoff.svg +0 -3
  192. package/lib/esm/assets/imgs/voiceon.svg +0 -3
  193. /package/lib/cjs/{assets/assets.d.js → components/prechatsurveypane/interfaces/IPreChatSurveyPaneElementStyles.js} +0 -0
@@ -1,11 +1,11 @@
1
- import errorImg from "../../../../../assets/imgs/error.svg";
1
+ import { ErrorIconBase64 } from "../../../../../assets/Icons";
2
2
  export const presetTwoOOOHPaneGeneralStyles = {
3
3
  borderStyle: "dotted solid double dashed",
4
4
  borderRadius: "40%",
5
5
  borderWidth: "5px",
6
6
  backgroundColor: "#FFFFFF",
7
7
  backgroundSize: "200px",
8
- backgroundImage: `url(${errorImg})`,
8
+ backgroundImage: `url(${ErrorIconBase64})`,
9
9
  backgroundRepeat: "no-repeat",
10
10
  backgroundPosition: "center",
11
11
  borderColor: "#F2FFF1",
@@ -14,8 +14,9 @@ function PostChatSurveyPane(props) {
14
14
  };
15
15
  const iframeStyles = {
16
16
  height: "100vh",
17
- width: "100vw",
18
- maxWidth: "100%"
17
+ width: "100%",
18
+ display: "block",
19
+ maxHeight: "100%"
19
20
  };
20
21
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Stack, {
21
22
  id: elementId,
@@ -10,7 +10,7 @@ import { defaultPreChatSurveyPaneGeneralStyles } from "./common/defaultProps/def
10
10
  import { defaultPreChatSurveyPaneStyles } from "./common/defaultProps/defaultStyles/defaultPreChatSurveyPaneStyles";
11
11
 
12
12
  function PreChatSurveyPane(props) {
13
- var _props$controlProps, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps3$cu, _defaultPreChatSurvey, _props$styleProps4, _props$styleProps4$cu, _defaultPreChatSurvey2, _props$controlProps6, _props$controlProps7, _props$controlProps8;
13
+ var _props$controlProps, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps3$cu, _props$styleProps4, _props$styleProps4$cu, _props$styleProps5, _props$styleProps5$cu, _props$styleProps6, _props$styleProps6$cu, _props$styleProps7, _props$styleProps7$cu, _props$styleProps8, _props$styleProps8$cu, _props$styleProps9, _props$styleProps9$cu, _defaultPreChatSurvey, _props$styleProps10, _props$styleProps10$c, _props$styleProps11, _props$styleProps11$c, _defaultPreChatSurvey2, _props$styleProps12, _props$styleProps12$c, _props$styleProps13, _props$styleProps13$c, _defaultPreChatSurvey3, _props$styleProps14, _props$styleProps14$c, _defaultPreChatSurvey4, _props$styleProps15, _props$styleProps15$c, _defaultPreChatSurvey5, _props$styleProps16, _props$styleProps16$c, _defaultPreChatSurvey6, _props$styleProps17, _props$styleProps17$c, _defaultPreChatSurvey7, _props$styleProps18, _props$styleProps18$c, _defaultPreChatSurvey8, _props$controlProps6, _props$controlProps7, _props$controlProps8;
14
14
 
15
15
  const elementId = ((_props$controlProps = props.controlProps) === null || _props$controlProps === void 0 ? void 0 : _props$controlProps.id) ?? "lcw-components-prechatsurvey-pane";
16
16
  let adpativeCardPayload;
@@ -60,6 +60,7 @@ function PreChatSurveyPane(props) {
60
60
  }
61
61
  }, []); //Adaptive Card Initilializations
62
62
 
63
+ AdaptiveCards.GlobalSettings.setTabIndexAtCardRoot = false;
63
64
  const adaptiveCard = new AdaptiveCards.AdaptiveCard();
64
65
  adaptiveCard.hostConfig = new AdaptiveCards.HostConfig(adaptiveCardHostConfig);
65
66
  adaptiveCard.parse(adpativeCardPayload);
@@ -68,18 +69,30 @@ function PreChatSurveyPane(props) {
68
69
  const renderedCard = adaptiveCard.render();
69
70
  addNoreferrerNoopenerTag(renderedCard);
70
71
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("style", null, `
72
+ .ac-textBlock {
73
+ font-size: ${(_props$styleProps3 = props.styleProps) === null || _props$styleProps3 === void 0 ? void 0 : (_props$styleProps3$cu = _props$styleProps3.customTextStyleProps) === null || _props$styleProps3$cu === void 0 ? void 0 : _props$styleProps3$cu.fontSize} !important;
74
+ height: ${(_props$styleProps4 = props.styleProps) === null || _props$styleProps4 === void 0 ? void 0 : (_props$styleProps4$cu = _props$styleProps4.customTextStyleProps) === null || _props$styleProps4$cu === void 0 ? void 0 : _props$styleProps4$cu.height};
75
+ padding-top: ${(_props$styleProps5 = props.styleProps) === null || _props$styleProps5 === void 0 ? void 0 : (_props$styleProps5$cu = _props$styleProps5.customTextStyleProps) === null || _props$styleProps5$cu === void 0 ? void 0 : _props$styleProps5$cu.paddingTop};
76
+ }
77
+ .ac-textRun {
78
+ font-size: ${(_props$styleProps6 = props.styleProps) === null || _props$styleProps6 === void 0 ? void 0 : (_props$styleProps6$cu = _props$styleProps6.customTextStyleProps) === null || _props$styleProps6$cu === void 0 ? void 0 : _props$styleProps6$cu.fontSize} !important;
79
+ padding-top: ${(_props$styleProps7 = props.styleProps) === null || _props$styleProps7 === void 0 ? void 0 : (_props$styleProps7$cu = _props$styleProps7.customTextStyleProps) === null || _props$styleProps7$cu === void 0 ? void 0 : _props$styleProps7$cu.paddingTop};
80
+ }
71
81
  .ac-input {
72
82
  margin-bottom: 6px;
73
83
  }
74
84
  .ac-input.ac-textInput {
75
- height: 20px;
85
+ font-size: ${(_props$styleProps8 = props.styleProps) === null || _props$styleProps8 === void 0 ? void 0 : (_props$styleProps8$cu = _props$styleProps8.customTextInputStyleProps) === null || _props$styleProps8$cu === void 0 ? void 0 : _props$styleProps8$cu.fontSize};
86
+ height: ${((_props$styleProps9 = props.styleProps) === null || _props$styleProps9 === void 0 ? void 0 : (_props$styleProps9$cu = _props$styleProps9.customTextInputStyleProps) === null || _props$styleProps9$cu === void 0 ? void 0 : _props$styleProps9$cu.height) ?? ((_defaultPreChatSurvey = defaultPreChatSurveyPaneStyles.customTextInputStyleProps) === null || _defaultPreChatSurvey === void 0 ? void 0 : _defaultPreChatSurvey.height)};
76
87
  padding: 8px;
77
88
  }
78
89
  .ac-input.ac-textInput.ac-multiline {
79
- height: 52px;
90
+ font-size: ${(_props$styleProps10 = props.styleProps) === null || _props$styleProps10 === void 0 ? void 0 : (_props$styleProps10$c = _props$styleProps10.customMultilineTextInputStyleProps) === null || _props$styleProps10$c === void 0 ? void 0 : _props$styleProps10$c.fontSize};
91
+ height: ${((_props$styleProps11 = props.styleProps) === null || _props$styleProps11 === void 0 ? void 0 : (_props$styleProps11$c = _props$styleProps11.customMultilineTextInputStyleProps) === null || _props$styleProps11$c === void 0 ? void 0 : _props$styleProps11$c.height) ?? ((_defaultPreChatSurvey2 = defaultPreChatSurveyPaneStyles.customMultilineTextInputStyleProps) === null || _defaultPreChatSurvey2 === void 0 ? void 0 : _defaultPreChatSurvey2.height)};
80
92
  resize: none;
81
93
  }
82
94
  .ac-input.ac-multichoiceInput {
95
+ font-size: ${(_props$styleProps12 = props.styleProps) === null || _props$styleProps12 === void 0 ? void 0 : (_props$styleProps12$c = _props$styleProps12.customMultichoiceInputStyleProps) === null || _props$styleProps12$c === void 0 ? void 0 : _props$styleProps12$c.fontSize};
83
96
  padding: 3px;
84
97
  padding-top: 7px;
85
98
  padding-bottom: 7px;
@@ -87,17 +100,19 @@ function PreChatSurveyPane(props) {
87
100
  .ac-pushButton {
88
101
  border: 1px solid #00000000;
89
102
  margin: 2px;
90
- height: 48px;
103
+ height: ${((_props$styleProps13 = props.styleProps) === null || _props$styleProps13 === void 0 ? void 0 : (_props$styleProps13$c = _props$styleProps13.customButtonStyleProps) === null || _props$styleProps13$c === void 0 ? void 0 : _props$styleProps13$c.height) ?? ((_defaultPreChatSurvey3 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey3 === void 0 ? void 0 : _defaultPreChatSurvey3.height)};
104
+ width: ${((_props$styleProps14 = props.styleProps) === null || _props$styleProps14 === void 0 ? void 0 : (_props$styleProps14$c = _props$styleProps14.customButtonStyleProps) === null || _props$styleProps14$c === void 0 ? void 0 : _props$styleProps14$c.width) ?? ((_defaultPreChatSurvey4 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey4 === void 0 ? void 0 : _defaultPreChatSurvey4.width)};
91
105
  border-radius: 5px;
92
- font-weight: bold;
93
- font-size: 15px;
94
106
  cursor: pointer;
95
- color: ${((_props$styleProps3 = props.styleProps) === null || _props$styleProps3 === void 0 ? void 0 : (_props$styleProps3$cu = _props$styleProps3.customButtonStyleProps) === null || _props$styleProps3$cu === void 0 ? void 0 : _props$styleProps3$cu.color) ?? ((_defaultPreChatSurvey = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey === void 0 ? void 0 : _defaultPreChatSurvey.color)};
96
- background-color: ${((_props$styleProps4 = props.styleProps) === null || _props$styleProps4 === void 0 ? void 0 : (_props$styleProps4$cu = _props$styleProps4.customButtonStyleProps) === null || _props$styleProps4$cu === void 0 ? void 0 : _props$styleProps4$cu.backgroundColor) ?? ((_defaultPreChatSurvey2 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey2 === void 0 ? void 0 : _defaultPreChatSurvey2.backgroundColor)};
107
+ font-weight: bold;
108
+ font-size: ${((_props$styleProps15 = props.styleProps) === null || _props$styleProps15 === void 0 ? void 0 : (_props$styleProps15$c = _props$styleProps15.customButtonStyleProps) === null || _props$styleProps15$c === void 0 ? void 0 : _props$styleProps15$c.fontSize) ?? ((_defaultPreChatSurvey5 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey5 === void 0 ? void 0 : _defaultPreChatSurvey5.fontSize)};
109
+ font-family: ${((_props$styleProps16 = props.styleProps) === null || _props$styleProps16 === void 0 ? void 0 : (_props$styleProps16$c = _props$styleProps16.customButtonStyleProps) === null || _props$styleProps16$c === void 0 ? void 0 : _props$styleProps16$c.fontFamily) ?? ((_defaultPreChatSurvey6 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey6 === void 0 ? void 0 : _defaultPreChatSurvey6.fontFamily)};
110
+ color: ${((_props$styleProps17 = props.styleProps) === null || _props$styleProps17 === void 0 ? void 0 : (_props$styleProps17$c = _props$styleProps17.customButtonStyleProps) === null || _props$styleProps17$c === void 0 ? void 0 : _props$styleProps17$c.color) ?? ((_defaultPreChatSurvey7 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey7 === void 0 ? void 0 : _defaultPreChatSurvey7.color)};
111
+ background-color: ${((_props$styleProps18 = props.styleProps) === null || _props$styleProps18 === void 0 ? void 0 : (_props$styleProps18$c = _props$styleProps18.customButtonStyleProps) === null || _props$styleProps18$c === void 0 ? void 0 : _props$styleProps18$c.backgroundColor) ?? ((_defaultPreChatSurvey8 = defaultPreChatSurveyPaneStyles.customButtonStyleProps) === null || _defaultPreChatSurvey8 === void 0 ? void 0 : _defaultPreChatSurvey8.backgroundColor)};
97
112
  }`), !((_props$controlProps6 = props.controlProps) !== null && _props$controlProps6 !== void 0 && _props$controlProps6.hidePreChatSurveyPane) && /*#__PURE__*/React.createElement(Stack, {
98
113
  id: elementId,
99
114
  tabIndex: -1,
100
- role: (_props$controlProps7 = props.controlProps) === null || _props$controlProps7 === void 0 ? void 0 : _props$controlProps7.role,
115
+ role: ((_props$controlProps7 = props.controlProps) === null || _props$controlProps7 === void 0 ? void 0 : _props$controlProps7.role) ?? defaultPreChatSurveyPaneControlProps.role,
101
116
  dir: ((_props$controlProps8 = props.controlProps) === null || _props$controlProps8 === void 0 ? void 0 : _props$controlProps8.dir) ?? defaultPreChatSurveyPaneControlProps.dir,
102
117
  styles: containerStyles
103
118
  }, /*#__PURE__*/React.createElement(Stack, {
@@ -1,6 +1,7 @@
1
1
  export const defaultPreChatSurveyPaneControlProps = {
2
2
  id: "oc-lcw-prechatsurveypane-default",
3
3
  dir: "auto",
4
+ role: "alert",
4
5
  hidePreChatSurveyPane: false,
5
6
  adaptiveCardHostConfig: "{\"fontFamily\":\"Segoe UI, Helvetica Neue, sans-serif\",\"containerStyles\":{\"default\":{\"foregroundColors\":{\"default\":{\"default\":\"#000000\"}},\"backgroundColor\":\"#FFFFFF\"}},\"actions\":{\"actionsOrientation\":\"Vertical\",\"actionAlignment\":\"stretch\"}}",
6
7
  payload: "{\"$schema\":\"http://adaptivecards.io/schemas/adaptive-card.json\",\"type\":\"AdaptiveCard\",\"version\":\"1.1\",\"body\":[{\"type\":\"TextBlock\",\"weight\":\"bolder\",\"text\":\"Please answer below questions.\"},{\"type\":\"Input.Text\",\"id\":\"1e5e4e7a-8f0b-ec11-b6e6-000d3a305d38\",\"label\":\"name pls?\",\"maxLength\":100,\"isRequired\":true,\"errorMessage\":\"Name is required\"},{\"type\":\"Input.Text\",\"id\":\"7f8f5d6d-995e-ec11-8f8f-000d3a31376e\",\"label\":\"multi\\nmulti\\nmulti\",\"style\":\"text\",\"isMultiline\":true,\"maxLength\":250},{\"type\":\"Input.ChoiceSet\",\"id\":\"e4bdf7cb-995e-ec11-8f8f-000d3a31376e\",\"label\":\"options\",\"isMultiSelect\":false,\"value\":\"1\",\"style\":\"compact\",\"choices\":[{\"title\":\"one\",\"value\":\"1\"},{\"title\":\"two\",\"value\":\"2\"},{\"title\":\"three\",\"value\":\"3\"}]},{\"type\":\"Input.Toggle\",\"id\":\"b26011d2-995e-ec11-8f8f-000d3a31376e\",\"title\":\"consent\",\"valueOn\":\"True\",\"valueOff\":\"False\",\"value\":\"false\"},{\"type\":\"TextBlock\",\"isSubtle\":true,\"text\":\"Fields marked with * are mandatory.\",\"wrap\":true}],\"actions\":[{\"type\":\"Action.Submit\",\"title\":\"Submit\",\"data\":{\"Type\":\"InputSubmit\"}}]}",
@@ -1,4 +1,8 @@
1
1
  export const defaultPreChatSurveyPaneButtonStyles = {
2
2
  backgroundColor: "rgb(49, 95, 162)",
3
- color: "#FFFFFF"
3
+ color: "#FFFFFF",
4
+ fontFamily: "Segoe UI, Arial, sans-serif",
5
+ fontSize: "15px",
6
+ height: "48px",
7
+ width: "auto"
4
8
  };
@@ -0,0 +1,3 @@
1
+ export const defaultPreChatSurveyPaneMultilineTextInputStyles = {
2
+ height: "52px"
3
+ };
@@ -1,8 +1,12 @@
1
1
  import { defaultPreChatSurveyPaneACContainerStyles } from "./defaultPreChatSurveyPaneACContainerStyles";
2
2
  import { defaultPreChatSurveyPaneButtonStyles } from "./defaultPreChatSurveyPaneButtonStyles";
3
3
  import { defaultPreChatSurveyPaneGeneralStyles } from "./defaultPreChatSurveyPaneGeneralStyles";
4
+ import { defaultPreChatSurveyPaneMultilineTextInputStyles } from "./defaultPreChatSurveyPaneMultilineTextInputStyles";
5
+ import { defaultPreChatSurveyPaneTextInputStyles } from "./defaultPreChatSurveyPaneTextInputStyles";
4
6
  export const defaultPreChatSurveyPaneStyles = {
5
7
  generalStyleProps: defaultPreChatSurveyPaneGeneralStyles,
6
8
  customButtonStyleProps: defaultPreChatSurveyPaneButtonStyles,
7
- adaptiveCardContainerStyleProps: defaultPreChatSurveyPaneACContainerStyles
9
+ adaptiveCardContainerStyleProps: defaultPreChatSurveyPaneACContainerStyles,
10
+ customTextInputStyleProps: defaultPreChatSurveyPaneTextInputStyles,
11
+ customMultilineTextInputStyleProps: defaultPreChatSurveyPaneMultilineTextInputStyles
8
12
  };
@@ -0,0 +1,3 @@
1
+ export const defaultPreChatSurveyPaneTextInputStyles = {
2
+ height: "20px"
3
+ };
@@ -1,13 +1,14 @@
1
- import { IconButton, Label, Stack } from "@fluentui/react";
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+
3
+ import { Label, Stack } from "@fluentui/react";
2
4
  import React, { useCallback } from "react";
3
5
  import { BroadcastService } from "../../services/BroadcastService";
4
6
  import { DefaultButton } from "@fluentui/react/lib/Button";
7
+ import CloseButton from "../common/subcomponents/CloseButton";
5
8
  import { KeyCodes } from "../../common/Constants";
6
9
  import { decodeComponentString } from "../../common/decodeComponentString";
7
10
  import { defaultProactiveChatPaneBodyContainerStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneBodyContainerStyles";
8
11
  import { defaultProactiveChatPaneBodyTitleStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneBodyTitleStyles";
9
- import { defaultProactiveChatPaneCloseButtonHoveredStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneCloseButtonHoveredStyles";
10
- import { defaultProactiveChatPaneCloseButtonStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneCloseButtonStyles";
11
12
  import { defaultProactiveChatPaneControlProps } from "./common/default/defaultProps/defaultProactiveChatPaneControlProps";
12
13
  import { defaultProactiveChatPaneGeneralStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneGeneralStyles";
13
14
  import { defaultProactiveChatPaneHeaderContainerStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneHeaderContainerStyles";
@@ -17,9 +18,10 @@ import { defaultProactiveChatPaneSubtitleStyles } from "./common/default/default
17
18
  import { defaultProactiveChatPaneTextContainerStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneTextContainerStyles";
18
19
  import { defaultProactiveChatPaneTitleStyles } from "./common/default/defaultStyles/defaultProactiveChatPaneTitleStyles";
19
20
  import { generateEventName } from "../../common/utils";
21
+ import { defaultProactiveChatPaneProps } from "./common/default/defaultProps/defaultProactiveChatPaneProps";
20
22
 
21
23
  function ProactiveChatPane(props) {
22
- var _props$controlProps, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps4, _props$styleProps5, _props$styleProps6, _props$styleProps7, _props$styleProps8, _props$styleProps9, _props$styleProps10, _props$styleProps11, _props$controlProps6, _props$styleProps12, _props$styleProps12$c, _props$controlProps7, _props$controlProps8, _props$styleProps13, _props$styleProps13$c, _props$styleProps14, _props$styleProps14$c, _props$controlProps9, _props$componentOverr, _props$styleProps15, _props$styleProps15$c, _props$controlProps10, _props$controlProps11, _props$componentOverr2, _props$styleProps16, _props$styleProps16$c, _props$controlProps12, _props$controlProps13, _props$componentOverr3, _props$styleProps17, _props$styleProps17$c, _props$controlProps14, _props$controlProps15, _props$styleProps18, _props$styleProps18$c, _props$controlProps16, _props$componentOverr4, _props$styleProps19, _props$styleProps19$c, _props$controlProps17, _props$controlProps18, _props$componentOverr5, _props$styleProps20, _props$styleProps20$c, _props$controlProps19, _props$controlProps20;
24
+ var _props$controlProps, _defaultProactiveChat, _props$controlProps6, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps4, _props$styleProps5, _defaultProactiveChat2, _props$styleProps6, _defaultProactiveChat3, _props$styleProps7, _props$styleProps8, _props$styleProps9, _props$styleProps10, _props$styleProps11, _props$styleProps12, _props$controlProps7, _props$styleProps13, _props$styleProps13$c, _props$controlProps8, _props$controlProps9, _props$styleProps14, _props$styleProps14$c, _props$styleProps15, _props$styleProps15$c, _props$controlProps10, _props$componentOverr, _props$styleProps16, _props$styleProps16$c, _props$controlProps11, _props$controlProps12, _props$componentOverr2, _props$styleProps17, _props$styleProps17$c, _props$controlProps13, _props$controlProps14, _props$componentOverr3, _props$styleProps18, _props$styleProps18$c, _props$controlProps15, _props$styleProps19, _props$styleProps19$c, _props$controlProps16, _props$componentOverr4, _props$styleProps20, _props$styleProps20$c, _props$controlProps17, _props$controlProps18, _props$componentOverr5, _props$styleProps21, _props$styleProps21$c, _props$controlProps19, _props$controlProps20;
23
25
 
24
26
  const elementId = ((_props$controlProps = props.controlProps) === null || _props$controlProps === void 0 ? void 0 : _props$controlProps.id) ?? defaultProactiveChatPaneControlProps.id;
25
27
 
@@ -68,6 +70,7 @@ function ProactiveChatPane(props) {
68
70
  (_props$controlProps5 = props.controlProps) === null || _props$controlProps5 === void 0 ? void 0 : _props$controlProps5.onStart();
69
71
  }
70
72
  }, []);
73
+ const closeButtonProps = Object.assign({}, (_defaultProactiveChat = defaultProactiveChatPaneProps.controlProps) === null || _defaultProactiveChat === void 0 ? void 0 : _defaultProactiveChat.closeButtonProps, (_props$controlProps6 = props.controlProps) === null || _props$controlProps6 === void 0 ? void 0 : _props$controlProps6.closeButtonProps);
71
74
  const containerStyles = {
72
75
  root: Object.assign({}, defaultProactiveChatPaneGeneralStyles, (_props$styleProps = props.styleProps) === null || _props$styleProps === void 0 ? void 0 : _props$styleProps.generalStyleProps)
73
76
  };
@@ -83,10 +86,8 @@ function ProactiveChatPane(props) {
83
86
  const subtitleStyles = {
84
87
  root: Object.assign({}, defaultProactiveChatPaneSubtitleStyles, (_props$styleProps5 = props.styleProps) === null || _props$styleProps5 === void 0 ? void 0 : _props$styleProps5.subtitleStyleProps)
85
88
  };
86
- const closeButtonStyles = {
87
- root: Object.assign({}, defaultProactiveChatPaneCloseButtonStyles, (_props$styleProps6 = props.styleProps) === null || _props$styleProps6 === void 0 ? void 0 : _props$styleProps6.closeButtonStyleProps),
88
- rootHovered: Object.assign({}, defaultProactiveChatPaneCloseButtonHoveredStyles, (_props$styleProps7 = props.styleProps) === null || _props$styleProps7 === void 0 ? void 0 : _props$styleProps7.closeButtonHoveredStyleProps)
89
- };
89
+ const closeButtonStyles = Object.assign({}, (_defaultProactiveChat2 = defaultProactiveChatPaneProps.styleProps) === null || _defaultProactiveChat2 === void 0 ? void 0 : _defaultProactiveChat2.closeButtonStyleProps, (_props$styleProps6 = props.styleProps) === null || _props$styleProps6 === void 0 ? void 0 : _props$styleProps6.closeButtonStyleProps);
90
+ const closeButtonHoverStyles = Object.assign({}, (_defaultProactiveChat3 = defaultProactiveChatPaneProps.styleProps) === null || _defaultProactiveChat3 === void 0 ? void 0 : _defaultProactiveChat3.closeButtonHoveredStyleProps, (_props$styleProps7 = props.styleProps) === null || _props$styleProps7 === void 0 ? void 0 : _props$styleProps7.closeButtonHoveredStyleProps);
90
91
  const bodyContainerStyles = {
91
92
  root: Object.assign({}, defaultProactiveChatPaneBodyContainerStyles, (_props$styleProps8 = props.styleProps) === null || _props$styleProps8 === void 0 ? void 0 : _props$styleProps8.bodyContainerStyleProps)
92
93
  };
@@ -95,57 +96,57 @@ function ProactiveChatPane(props) {
95
96
  };
96
97
  const startButtonStyles = {
97
98
  root: Object.assign({}, defaultProactiveChatPaneStartButtonStyles, (_props$styleProps10 = props.styleProps) === null || _props$styleProps10 === void 0 ? void 0 : _props$styleProps10.startButtonStyleProps),
98
- rootHovered: Object.assign({}, defaultProactiveChatPaneStartButtonHoveredStyles, (_props$styleProps11 = props.styleProps) === null || _props$styleProps11 === void 0 ? void 0 : _props$styleProps11.startButtonHoveredStyleProps)
99
+ rootHovered: Object.assign({}, defaultProactiveChatPaneStartButtonHoveredStyles, (_props$styleProps11 = props.styleProps) === null || _props$styleProps11 === void 0 ? void 0 : _props$styleProps11.startButtonHoveredStyleProps),
100
+ rootPressed: Object.assign({}, defaultProactiveChatPaneStartButtonHoveredStyles, (_props$styleProps12 = props.styleProps) === null || _props$styleProps12 === void 0 ? void 0 : _props$styleProps12.startButtonHoveredStyleProps)
99
101
  };
100
- return /*#__PURE__*/React.createElement(React.Fragment, null, !((_props$controlProps6 = props.controlProps) !== null && _props$controlProps6 !== void 0 && _props$controlProps6.hideProactiveChatPane) && /*#__PURE__*/React.createElement(Stack, {
101
- className: (_props$styleProps12 = props.styleProps) === null || _props$styleProps12 === void 0 ? void 0 : (_props$styleProps12$c = _props$styleProps12.classNames) === null || _props$styleProps12$c === void 0 ? void 0 : _props$styleProps12$c.containerClassName,
102
+ return /*#__PURE__*/React.createElement(React.Fragment, null, !((_props$controlProps7 = props.controlProps) !== null && _props$controlProps7 !== void 0 && _props$controlProps7.hideProactiveChatPane) && /*#__PURE__*/React.createElement(Stack, {
103
+ className: (_props$styleProps13 = props.styleProps) === null || _props$styleProps13 === void 0 ? void 0 : (_props$styleProps13$c = _props$styleProps13.classNames) === null || _props$styleProps13$c === void 0 ? void 0 : _props$styleProps13$c.containerClassName,
102
104
  id: elementId,
103
105
  tabIndex: -1,
104
106
  onKeyDown: handleEscKeyDown,
105
- dir: ((_props$controlProps7 = props.controlProps) === null || _props$controlProps7 === void 0 ? void 0 : _props$controlProps7.dir) || defaultProactiveChatPaneControlProps.dir,
106
- "aria-label": ((_props$controlProps8 = props.controlProps) === null || _props$controlProps8 === void 0 ? void 0 : _props$controlProps8.proactiveChatPaneAriaLabel) || defaultProactiveChatPaneControlProps.proactiveChatPaneAriaLabel,
107
+ dir: ((_props$controlProps8 = props.controlProps) === null || _props$controlProps8 === void 0 ? void 0 : _props$controlProps8.dir) || defaultProactiveChatPaneControlProps.dir,
108
+ "aria-label": ((_props$controlProps9 = props.controlProps) === null || _props$controlProps9 === void 0 ? void 0 : _props$controlProps9.proactiveChatPaneAriaLabel) || defaultProactiveChatPaneControlProps.proactiveChatPaneAriaLabel,
107
109
  styles: containerStyles
108
110
  }, /*#__PURE__*/React.createElement(Stack, {
109
111
  horizontal: true,
110
- className: (_props$styleProps13 = props.styleProps) === null || _props$styleProps13 === void 0 ? void 0 : (_props$styleProps13$c = _props$styleProps13.classNames) === null || _props$styleProps13$c === void 0 ? void 0 : _props$styleProps13$c.headerContainerClassName,
112
+ className: (_props$styleProps14 = props.styleProps) === null || _props$styleProps14 === void 0 ? void 0 : (_props$styleProps14$c = _props$styleProps14.classNames) === null || _props$styleProps14$c === void 0 ? void 0 : _props$styleProps14$c.headerContainerClassName,
111
113
  styles: headerContainerStyles,
112
114
  tabIndex: -1,
113
115
  id: elementId + "-headercontainer"
114
116
  }, /*#__PURE__*/React.createElement(Stack, {
115
- className: (_props$styleProps14 = props.styleProps) === null || _props$styleProps14 === void 0 ? void 0 : (_props$styleProps14$c = _props$styleProps14.classNames) === null || _props$styleProps14$c === void 0 ? void 0 : _props$styleProps14$c.textContainerClassName,
117
+ className: (_props$styleProps15 = props.styleProps) === null || _props$styleProps15 === void 0 ? void 0 : (_props$styleProps15$c = _props$styleProps15.classNames) === null || _props$styleProps15$c === void 0 ? void 0 : _props$styleProps15$c.textContainerClassName,
116
118
  styles: textContainerStyles,
117
119
  tabIndex: -1,
118
120
  id: elementId + "-textcontainer"
119
- }, !((_props$controlProps9 = props.controlProps) !== null && _props$controlProps9 !== void 0 && _props$controlProps9.hideTitle) && (decodeComponentString((_props$componentOverr = props.componentOverrides) === null || _props$componentOverr === void 0 ? void 0 : _props$componentOverr.title) || /*#__PURE__*/React.createElement(Label, {
120
- className: (_props$styleProps15 = props.styleProps) === null || _props$styleProps15 === void 0 ? void 0 : (_props$styleProps15$c = _props$styleProps15.classNames) === null || _props$styleProps15$c === void 0 ? void 0 : _props$styleProps15$c.titleClassName,
121
+ }, !((_props$controlProps10 = props.controlProps) !== null && _props$controlProps10 !== void 0 && _props$controlProps10.hideTitle) && (decodeComponentString((_props$componentOverr = props.componentOverrides) === null || _props$componentOverr === void 0 ? void 0 : _props$componentOverr.title) || /*#__PURE__*/React.createElement(Label, {
122
+ className: (_props$styleProps16 = props.styleProps) === null || _props$styleProps16 === void 0 ? void 0 : (_props$styleProps16$c = _props$styleProps16.classNames) === null || _props$styleProps16$c === void 0 ? void 0 : _props$styleProps16$c.titleClassName,
121
123
  styles: titleStyles,
122
124
  tabIndex: -1,
123
125
  id: elementId + "-title"
124
- }, ((_props$controlProps10 = props.controlProps) === null || _props$controlProps10 === void 0 ? void 0 : _props$controlProps10.titleText) || defaultProactiveChatPaneControlProps.titleText)), !((_props$controlProps11 = props.controlProps) !== null && _props$controlProps11 !== void 0 && _props$controlProps11.hideSubtitle) && (decodeComponentString((_props$componentOverr2 = props.componentOverrides) === null || _props$componentOverr2 === void 0 ? void 0 : _props$componentOverr2.subtitle) || /*#__PURE__*/React.createElement(Label, {
125
- className: (_props$styleProps16 = props.styleProps) === null || _props$styleProps16 === void 0 ? void 0 : (_props$styleProps16$c = _props$styleProps16.classNames) === null || _props$styleProps16$c === void 0 ? void 0 : _props$styleProps16$c.subtitleClassName,
126
+ }, ((_props$controlProps11 = props.controlProps) === null || _props$controlProps11 === void 0 ? void 0 : _props$controlProps11.titleText) || defaultProactiveChatPaneControlProps.titleText)), !((_props$controlProps12 = props.controlProps) !== null && _props$controlProps12 !== void 0 && _props$controlProps12.hideSubtitle) && (decodeComponentString((_props$componentOverr2 = props.componentOverrides) === null || _props$componentOverr2 === void 0 ? void 0 : _props$componentOverr2.subtitle) || /*#__PURE__*/React.createElement(Label, {
127
+ className: (_props$styleProps17 = props.styleProps) === null || _props$styleProps17 === void 0 ? void 0 : (_props$styleProps17$c = _props$styleProps17.classNames) === null || _props$styleProps17$c === void 0 ? void 0 : _props$styleProps17$c.subtitleClassName,
126
128
  styles: subtitleStyles,
127
129
  tabIndex: -1,
128
130
  id: elementId + "-subtitle"
129
- }, ((_props$controlProps12 = props.controlProps) === null || _props$controlProps12 === void 0 ? void 0 : _props$controlProps12.subtitleText) || defaultProactiveChatPaneControlProps.subtitleText))), !((_props$controlProps13 = props.controlProps) !== null && _props$controlProps13 !== void 0 && _props$controlProps13.hideCloseButton) && (decodeComponentString((_props$componentOverr3 = props.componentOverrides) === null || _props$componentOverr3 === void 0 ? void 0 : _props$componentOverr3.closeButton) || /*#__PURE__*/React.createElement(IconButton, {
130
- className: (_props$styleProps17 = props.styleProps) === null || _props$styleProps17 === void 0 ? void 0 : (_props$styleProps17$c = _props$styleProps17.classNames) === null || _props$styleProps17$c === void 0 ? void 0 : _props$styleProps17$c.closeButtonClassName,
131
- styles: closeButtonStyles,
132
- tabIndex: 0,
131
+ }, ((_props$controlProps13 = props.controlProps) === null || _props$controlProps13 === void 0 ? void 0 : _props$controlProps13.subtitleText) || defaultProactiveChatPaneControlProps.subtitleText))), !((_props$controlProps14 = props.controlProps) !== null && _props$controlProps14 !== void 0 && _props$controlProps14.hideCloseButton) && (decodeComponentString((_props$componentOverr3 = props.componentOverrides) === null || _props$componentOverr3 === void 0 ? void 0 : _props$componentOverr3.closeButton) || /*#__PURE__*/React.createElement(CloseButton, _extends({}, closeButtonProps, {
132
+ className: (_props$styleProps18 = props.styleProps) === null || _props$styleProps18 === void 0 ? void 0 : (_props$styleProps18$c = _props$styleProps18.classNames) === null || _props$styleProps18$c === void 0 ? void 0 : _props$styleProps18$c.closeButtonClassName,
133
133
  onClick: handleCloseClick,
134
- id: elementId + "-closebutton",
135
- "aria-label": ((_props$controlProps14 = props.controlProps) === null || _props$controlProps14 === void 0 ? void 0 : _props$controlProps14.closeButtonAriaLabel) || defaultProactiveChatPaneControlProps.closeButtonAriaLabel
136
- }))), /*#__PURE__*/React.createElement(Stack, {
134
+ styles: closeButtonStyles,
135
+ hoverStyles: closeButtonHoverStyles,
136
+ id: elementId + "-closebutton"
137
+ })))), /*#__PURE__*/React.createElement(Stack, {
137
138
  horizontal: ((_props$controlProps15 = props.controlProps) === null || _props$controlProps15 === void 0 ? void 0 : _props$controlProps15.isBodyContainerHorizantal) || defaultProactiveChatPaneControlProps.isBodyContainerHorizantal,
138
- className: (_props$styleProps18 = props.styleProps) === null || _props$styleProps18 === void 0 ? void 0 : (_props$styleProps18$c = _props$styleProps18.classNames) === null || _props$styleProps18$c === void 0 ? void 0 : _props$styleProps18$c.bodyContainerClassName,
139
+ className: (_props$styleProps19 = props.styleProps) === null || _props$styleProps19 === void 0 ? void 0 : (_props$styleProps19$c = _props$styleProps19.classNames) === null || _props$styleProps19$c === void 0 ? void 0 : _props$styleProps19$c.bodyContainerClassName,
139
140
  styles: bodyContainerStyles,
140
141
  tabIndex: -1,
141
142
  id: elementId + "-bodycontainer"
142
143
  }, !((_props$controlProps16 = props.controlProps) !== null && _props$controlProps16 !== void 0 && _props$controlProps16.hideBodyTitle) && (decodeComponentString((_props$componentOverr4 = props.componentOverrides) === null || _props$componentOverr4 === void 0 ? void 0 : _props$componentOverr4.bodyTitle) || /*#__PURE__*/React.createElement(Label, {
143
- className: (_props$styleProps19 = props.styleProps) === null || _props$styleProps19 === void 0 ? void 0 : (_props$styleProps19$c = _props$styleProps19.classNames) === null || _props$styleProps19$c === void 0 ? void 0 : _props$styleProps19$c.bodyTitleClassName,
144
+ className: (_props$styleProps20 = props.styleProps) === null || _props$styleProps20 === void 0 ? void 0 : (_props$styleProps20$c = _props$styleProps20.classNames) === null || _props$styleProps20$c === void 0 ? void 0 : _props$styleProps20$c.bodyTitleClassName,
144
145
  styles: bodyTitleStyles,
145
146
  tabIndex: -1,
146
147
  id: elementId + "-bodytitle"
147
148
  }, ((_props$controlProps17 = props.controlProps) === null || _props$controlProps17 === void 0 ? void 0 : _props$controlProps17.bodyTitleText) || defaultProactiveChatPaneControlProps.bodyTitleText)), !((_props$controlProps18 = props.controlProps) !== null && _props$controlProps18 !== void 0 && _props$controlProps18.hideStartButton) && (decodeComponentString((_props$componentOverr5 = props.componentOverrides) === null || _props$componentOverr5 === void 0 ? void 0 : _props$componentOverr5.startButton) || /*#__PURE__*/React.createElement(DefaultButton, {
148
- className: (_props$styleProps20 = props.styleProps) === null || _props$styleProps20 === void 0 ? void 0 : (_props$styleProps20$c = _props$styleProps20.classNames) === null || _props$styleProps20$c === void 0 ? void 0 : _props$styleProps20$c.startButtonClassName,
149
+ className: (_props$styleProps21 = props.styleProps) === null || _props$styleProps21 === void 0 ? void 0 : (_props$styleProps21$c = _props$styleProps21.classNames) === null || _props$styleProps21$c === void 0 ? void 0 : _props$styleProps21$c.startButtonClassName,
149
150
  styles: startButtonStyles,
150
151
  tabIndex: 0,
151
152
  text: ((_props$controlProps19 = props.controlProps) === null || _props$controlProps19 === void 0 ? void 0 : _props$controlProps19.startButtonText) || defaultProactiveChatPaneControlProps.startButtonText,
@@ -8,7 +8,11 @@ export const defaultProactiveChatPaneControlProps = {
8
8
  hideSubtitle: false,
9
9
  subtitleText: "Live chat support!",
10
10
  hideCloseButton: false,
11
- closeButtonAriaLabel: "Close Button",
11
+ closeButtonProps: {
12
+ type: "icon",
13
+ iconName: "ChromeClose",
14
+ hideButtonTitle: true
15
+ },
12
16
  isBodyContainerHorizantal: false,
13
17
  hideBodyTitle: false,
14
18
  bodyTitleText: "Hi! Have any questions? I am here to help.",
@@ -1,13 +1,4 @@
1
- import closeImage from "../../../../../assets/imgs/closeChatButton.svg";
2
1
  export const defaultProactiveChatPaneCloseButtonStyles = {
3
- backgroundImage: "url(" + closeImage + ")",
4
- backgroundPosition: "center",
5
- backgroundRepeat: "no-repeat",
6
- color: "#605e5c",
7
- cursor: "pointer",
8
- height: "14px",
9
- lineHeight: "14px",
10
- textAlign: "center",
11
- width: "14px",
12
- zIndex: "inherit"
2
+ color: "white",
3
+ fontSize: "12px"
13
4
  };
@@ -1,7 +1,7 @@
1
- import proactiveBanner from "../../../../../assets/imgs/Proactive_banner.png";
1
+ import { ProactiveChatBannerBase64 } from "../../../../../assets/Icons";
2
2
  export const defaultProactiveChatPaneHeaderContainerStyles = {
3
3
  backgroundColor: "rgb(49, 95, 162)",
4
- backgroundImage: "url(" + proactiveBanner + ")",
4
+ backgroundImage: `url(${ProactiveChatBannerBase64})`,
5
5
  backgroundPosition: "initial",
6
6
  backgroundRepeat: "no-repeat",
7
7
  borderTopLeftRadius: "inherit",
@@ -8,7 +8,11 @@ export const presetOneProactiveChatPaneControlProps = {
8
8
  hideSubtitle: false,
9
9
  subtitleText: "Live chat support!",
10
10
  hideCloseButton: false,
11
- closeButtonAriaLabel: "Close Button",
11
+ closeButtonProps: {
12
+ type: "icon",
13
+ iconName: "ChromeClose",
14
+ hideButtonTitle: true
15
+ },
12
16
  isBodyContainerHorizantal: true,
13
17
  hideBodyTitle: false,
14
18
  bodyTitleText: "Hi! Have any questions? I am here to help.",
@@ -8,7 +8,11 @@ export const presetThreeProactiveChatPaneControlProps = {
8
8
  hideSubtitle: false,
9
9
  subtitleText: "Live chat support!",
10
10
  hideCloseButton: false,
11
- closeButtonAriaLabel: "Close Button",
11
+ closeButtonProps: {
12
+ type: "icon",
13
+ iconName: "ChromeClose",
14
+ hideButtonTitle: true
15
+ },
12
16
  isBodyContainerHorizantal: false,
13
17
  hideBodyTitle: false,
14
18
  bodyTitleText: "Hi! Have any questions? I am here to help.",
@@ -17,7 +17,7 @@ import { defaultReconnectChatPaneTitleStyles } from "./common/default/defaultSty
17
17
  import { defaultReconnectChatPaneWrapperStyles } from "./common/default/defaultStyles/defaultReconnectChatPaneWrapperStyles";
18
18
 
19
19
  function ReconnectChatPane(props) {
20
- var _props$controlProps, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps4, _props$styleProps5, _props$styleProps6, _props$styleProps7, _props$styleProps8, _props$styleProps9, _props$styleProps10, _props$controlProps8, _props$styleProps11, _props$styleProps11$c, _props$controlProps9, _props$controlProps10, _props$styleProps12, _props$styleProps12$c, _props$controlProps11, _props$componentOverr, _props$styleProps13, _props$styleProps13$c, _props$controlProps12, _props$controlProps13, _props$componentOverr2, _props$styleProps14, _props$styleProps14$c, _props$controlProps14, _props$controlProps15, _props$componentOverr3, _props$styleProps15, _props$styleProps15$c, _props$controlProps16, _props$controlProps17, _props$styleProps16, _props$styleProps16$c, _props$controlProps18, _props$componentOverr4, _props$styleProps17, _props$styleProps17$c, _props$controlProps19, _props$controlProps20, _props$controlProps21, _props$componentOverr5, _props$styleProps18, _props$styleProps18$c, _props$controlProps22, _props$controlProps23;
20
+ var _props$controlProps, _props$styleProps, _props$styleProps2, _props$styleProps3, _props$styleProps4, _props$styleProps5, _props$styleProps6, _props$styleProps7, _props$styleProps8, _props$styleProps9, _props$styleProps10, _props$styleProps11, _props$styleProps12, _props$controlProps8, _props$styleProps13, _props$styleProps13$c, _props$controlProps9, _props$controlProps10, _props$styleProps14, _props$styleProps14$c, _props$controlProps11, _props$componentOverr, _props$styleProps15, _props$styleProps15$c, _props$controlProps12, _props$controlProps13, _props$componentOverr2, _props$styleProps16, _props$styleProps16$c, _props$controlProps14, _props$controlProps15, _props$componentOverr3, _props$styleProps17, _props$styleProps17$c, _props$controlProps16, _props$controlProps17, _props$styleProps18, _props$styleProps18$c, _props$controlProps18, _props$componentOverr4, _props$styleProps19, _props$styleProps19$c, _props$controlProps19, _props$controlProps20, _props$controlProps21, _props$componentOverr5, _props$styleProps20, _props$styleProps20$c, _props$controlProps22, _props$controlProps23;
21
21
 
22
22
  const elementId = ((_props$controlProps = props.controlProps) === null || _props$controlProps === void 0 ? void 0 : _props$controlProps.id) ?? defaultReconnectChatPaneControlProps.id;
23
23
  const handleContinueChatClick = useCallback(() => {
@@ -86,14 +86,16 @@ function ReconnectChatPane(props) {
86
86
  };
87
87
  const continueChatButtonStyles = {
88
88
  root: Object.assign({}, defaultReconnectChatPaneContinueChatButtonStyles, (_props$styleProps7 = props.styleProps) === null || _props$styleProps7 === void 0 ? void 0 : _props$styleProps7.continueChatButtonStyleProps),
89
- rootHovered: Object.assign({}, defaultReconnectChatPaneContinueChatButtonHoveredStyles, (_props$styleProps8 = props.styleProps) === null || _props$styleProps8 === void 0 ? void 0 : _props$styleProps8.continueChatButtonHoveredStyleProps)
89
+ rootHovered: Object.assign({}, defaultReconnectChatPaneContinueChatButtonHoveredStyles, (_props$styleProps8 = props.styleProps) === null || _props$styleProps8 === void 0 ? void 0 : _props$styleProps8.continueChatButtonHoveredStyleProps),
90
+ rootPressed: Object.assign({}, defaultReconnectChatPaneContinueChatButtonHoveredStyles, (_props$styleProps9 = props.styleProps) === null || _props$styleProps9 === void 0 ? void 0 : _props$styleProps9.continueChatButtonHoveredStyleProps)
90
91
  };
91
92
  const startNewChatButtonStyles = {
92
- root: Object.assign({}, defaultReconnectChatPaneStartNewChatButtonStyles, (_props$styleProps9 = props.styleProps) === null || _props$styleProps9 === void 0 ? void 0 : _props$styleProps9.startNewChatButtonStyleProps),
93
- rootHovered: Object.assign({}, defaultReconnectChatPaneStartNewChatButtonHoveredStyles, (_props$styleProps10 = props.styleProps) === null || _props$styleProps10 === void 0 ? void 0 : _props$styleProps10.startNewChatButtonHoveredStyleProps)
93
+ root: Object.assign({}, defaultReconnectChatPaneStartNewChatButtonStyles, (_props$styleProps10 = props.styleProps) === null || _props$styleProps10 === void 0 ? void 0 : _props$styleProps10.startNewChatButtonStyleProps),
94
+ rootHovered: Object.assign({}, defaultReconnectChatPaneStartNewChatButtonHoveredStyles, (_props$styleProps11 = props.styleProps) === null || _props$styleProps11 === void 0 ? void 0 : _props$styleProps11.startNewChatButtonHoveredStyleProps),
95
+ rootPressed: Object.assign({}, defaultReconnectChatPaneStartNewChatButtonHoveredStyles, (_props$styleProps12 = props.styleProps) === null || _props$styleProps12 === void 0 ? void 0 : _props$styleProps12.startNewChatButtonHoveredStyleProps)
94
96
  };
95
97
  return /*#__PURE__*/React.createElement(React.Fragment, null, !((_props$controlProps8 = props.controlProps) !== null && _props$controlProps8 !== void 0 && _props$controlProps8.hideReconnectChatPane) && /*#__PURE__*/React.createElement(Stack, {
96
- className: (_props$styleProps11 = props.styleProps) === null || _props$styleProps11 === void 0 ? void 0 : (_props$styleProps11$c = _props$styleProps11.classNames) === null || _props$styleProps11$c === void 0 ? void 0 : _props$styleProps11$c.containerClassName,
98
+ className: (_props$styleProps13 = props.styleProps) === null || _props$styleProps13 === void 0 ? void 0 : (_props$styleProps13$c = _props$styleProps13.classNames) === null || _props$styleProps13$c === void 0 ? void 0 : _props$styleProps13$c.containerClassName,
97
99
  id: elementId,
98
100
  tabIndex: -1,
99
101
  onKeyDown: handleEscKeyDown,
@@ -101,22 +103,22 @@ function ReconnectChatPane(props) {
101
103
  "aria-label": ((_props$controlProps10 = props.controlProps) === null || _props$controlProps10 === void 0 ? void 0 : _props$controlProps10.reconnectChatPaneAriaLabel) || defaultReconnectChatPaneControlProps.reconnectChatPaneAriaLabel,
102
104
  styles: containerStyles
103
105
  }, /*#__PURE__*/React.createElement(Stack, {
104
- className: (_props$styleProps12 = props.styleProps) === null || _props$styleProps12 === void 0 ? void 0 : (_props$styleProps12$c = _props$styleProps12.classNames) === null || _props$styleProps12$c === void 0 ? void 0 : _props$styleProps12$c.wrapperClassName,
106
+ className: (_props$styleProps14 = props.styleProps) === null || _props$styleProps14 === void 0 ? void 0 : (_props$styleProps14$c = _props$styleProps14.classNames) === null || _props$styleProps14$c === void 0 ? void 0 : _props$styleProps14$c.wrapperClassName,
105
107
  styles: wrapperStyles,
106
108
  tabIndex: -1,
107
109
  id: elementId + "-wrapper"
108
110
  }, !((_props$controlProps11 = props.controlProps) !== null && _props$controlProps11 !== void 0 && _props$controlProps11.hideTitle) && (decodeComponentString((_props$componentOverr = props.componentOverrides) === null || _props$componentOverr === void 0 ? void 0 : _props$componentOverr.title) || /*#__PURE__*/React.createElement(Label, {
109
- className: (_props$styleProps13 = props.styleProps) === null || _props$styleProps13 === void 0 ? void 0 : (_props$styleProps13$c = _props$styleProps13.classNames) === null || _props$styleProps13$c === void 0 ? void 0 : _props$styleProps13$c.titleClassName,
111
+ className: (_props$styleProps15 = props.styleProps) === null || _props$styleProps15 === void 0 ? void 0 : (_props$styleProps15$c = _props$styleProps15.classNames) === null || _props$styleProps15$c === void 0 ? void 0 : _props$styleProps15$c.titleClassName,
110
112
  styles: titleStyles,
111
113
  tabIndex: -1,
112
114
  id: elementId + "-title"
113
115
  }, ((_props$controlProps12 = props.controlProps) === null || _props$controlProps12 === void 0 ? void 0 : _props$controlProps12.titleText) || defaultReconnectChatPaneControlProps.titleText)), !((_props$controlProps13 = props.controlProps) !== null && _props$controlProps13 !== void 0 && _props$controlProps13.hideSubtitle) && (decodeComponentString((_props$componentOverr2 = props.componentOverrides) === null || _props$componentOverr2 === void 0 ? void 0 : _props$componentOverr2.subtitle) || /*#__PURE__*/React.createElement(Label, {
114
- className: (_props$styleProps14 = props.styleProps) === null || _props$styleProps14 === void 0 ? void 0 : (_props$styleProps14$c = _props$styleProps14.classNames) === null || _props$styleProps14$c === void 0 ? void 0 : _props$styleProps14$c.subtitleClassName,
116
+ className: (_props$styleProps16 = props.styleProps) === null || _props$styleProps16 === void 0 ? void 0 : (_props$styleProps16$c = _props$styleProps16.classNames) === null || _props$styleProps16$c === void 0 ? void 0 : _props$styleProps16$c.subtitleClassName,
115
117
  styles: subtitleStyles,
116
118
  tabIndex: -1,
117
119
  id: elementId + "-subtitle"
118
120
  }, ((_props$controlProps14 = props.controlProps) === null || _props$controlProps14 === void 0 ? void 0 : _props$controlProps14.subtitleText) || defaultReconnectChatPaneControlProps.subtitleText)), !((_props$controlProps15 = props.controlProps) !== null && _props$controlProps15 !== void 0 && _props$controlProps15.hideIcon) && (decodeComponentString((_props$componentOverr3 = props.componentOverrides) === null || _props$componentOverr3 === void 0 ? void 0 : _props$componentOverr3.icon) || /*#__PURE__*/React.createElement(Icon, {
119
- className: (_props$styleProps15 = props.styleProps) === null || _props$styleProps15 === void 0 ? void 0 : (_props$styleProps15$c = _props$styleProps15.classNames) === null || _props$styleProps15$c === void 0 ? void 0 : _props$styleProps15$c.iconClassName,
121
+ className: (_props$styleProps17 = props.styleProps) === null || _props$styleProps17 === void 0 ? void 0 : (_props$styleProps17$c = _props$styleProps17.classNames) === null || _props$styleProps17$c === void 0 ? void 0 : _props$styleProps17$c.iconClassName,
120
122
  styles: iconStyles,
121
123
  tabIndex: -1,
122
124
  role: "img",
@@ -124,12 +126,12 @@ function ReconnectChatPane(props) {
124
126
  "aria-label": ((_props$controlProps16 = props.controlProps) === null || _props$controlProps16 === void 0 ? void 0 : _props$controlProps16.iconAriaLabel) || defaultReconnectChatPaneControlProps.iconAriaLabel
125
127
  })), /*#__PURE__*/React.createElement(Stack, {
126
128
  horizontal: ((_props$controlProps17 = props.controlProps) === null || _props$controlProps17 === void 0 ? void 0 : _props$controlProps17.isButtonGroupHorizontal) || defaultReconnectChatPaneControlProps.isButtonGroupHorizontal,
127
- className: (_props$styleProps16 = props.styleProps) === null || _props$styleProps16 === void 0 ? void 0 : (_props$styleProps16$c = _props$styleProps16.classNames) === null || _props$styleProps16$c === void 0 ? void 0 : _props$styleProps16$c.buttonGroupClassName,
129
+ className: (_props$styleProps18 = props.styleProps) === null || _props$styleProps18 === void 0 ? void 0 : (_props$styleProps18$c = _props$styleProps18.classNames) === null || _props$styleProps18$c === void 0 ? void 0 : _props$styleProps18$c.buttonGroupClassName,
128
130
  styles: buttonGroupStyles,
129
131
  tabIndex: -1,
130
132
  id: elementId + "-buttongroup"
131
133
  }, !((_props$controlProps18 = props.controlProps) !== null && _props$controlProps18 !== void 0 && _props$controlProps18.hideContinueChatButton) && (decodeComponentString((_props$componentOverr4 = props.componentOverrides) === null || _props$componentOverr4 === void 0 ? void 0 : _props$componentOverr4.continueChatButton) || /*#__PURE__*/React.createElement(DefaultButton, {
132
- className: (_props$styleProps17 = props.styleProps) === null || _props$styleProps17 === void 0 ? void 0 : (_props$styleProps17$c = _props$styleProps17.classNames) === null || _props$styleProps17$c === void 0 ? void 0 : _props$styleProps17$c.continueChatButtonClassName,
134
+ className: (_props$styleProps19 = props.styleProps) === null || _props$styleProps19 === void 0 ? void 0 : (_props$styleProps19$c = _props$styleProps19.classNames) === null || _props$styleProps19$c === void 0 ? void 0 : _props$styleProps19$c.continueChatButtonClassName,
133
135
  styles: continueChatButtonStyles,
134
136
  tabIndex: 0,
135
137
  text: ((_props$controlProps19 = props.controlProps) === null || _props$controlProps19 === void 0 ? void 0 : _props$controlProps19.continueChatButtonText) || defaultReconnectChatPaneControlProps.continueChatButtonText,
@@ -137,7 +139,7 @@ function ReconnectChatPane(props) {
137
139
  id: elementId + "-continueconversationbutton",
138
140
  "aria-label": ((_props$controlProps20 = props.controlProps) === null || _props$controlProps20 === void 0 ? void 0 : _props$controlProps20.continueChatButtonAriaLabel) || defaultReconnectChatPaneControlProps.continueChatButtonAriaLabel
139
141
  })), !((_props$controlProps21 = props.controlProps) !== null && _props$controlProps21 !== void 0 && _props$controlProps21.hideStartNewChatButton) && (decodeComponentString((_props$componentOverr5 = props.componentOverrides) === null || _props$componentOverr5 === void 0 ? void 0 : _props$componentOverr5.startNewChatButton) || /*#__PURE__*/React.createElement(DefaultButton, {
140
- className: (_props$styleProps18 = props.styleProps) === null || _props$styleProps18 === void 0 ? void 0 : (_props$styleProps18$c = _props$styleProps18.classNames) === null || _props$styleProps18$c === void 0 ? void 0 : _props$styleProps18$c.startNewChatButtonClassName,
142
+ className: (_props$styleProps20 = props.styleProps) === null || _props$styleProps20 === void 0 ? void 0 : (_props$styleProps20$c = _props$styleProps20.classNames) === null || _props$styleProps20$c === void 0 ? void 0 : _props$styleProps20$c.startNewChatButtonClassName,
141
143
  styles: startNewChatButtonStyles,
142
144
  tabIndex: 0,
143
145
  text: ((_props$controlProps22 = props.controlProps) === null || _props$controlProps22 === void 0 ? void 0 : _props$controlProps22.startNewChatButtonText) || defaultReconnectChatPaneControlProps.startNewChatButtonText,
@@ -1,6 +1,6 @@
1
- import chatReconnectPopupIcon from "../../../../../assets/imgs/ChatReconnectPopupIcon.png";
1
+ import { ChatReconnectIconBase64 } from "../../../../../assets/Icons";
2
2
  export const defaultReconnectChatPaneIconStyles = {
3
- backgroundImage: "url(" + chatReconnectPopupIcon + ")",
3
+ backgroundImage: `url(${ChatReconnectIconBase64})`,
4
4
  backgroundPosition: "center",
5
5
  backgroundRepeat: "no-repeat",
6
6
  backgroundSize: "200px",
package/lib/esm/index.js CHANGED
@@ -12,8 +12,10 @@ export { default as PostChatSurveyPane } from "./components/postchatsurveypane/P
12
12
  export { encodeComponentString } from "./common/encodeComponentString";
13
13
  export { decodeComponentString } from "./common/decodeComponentString";
14
14
  export { BroadcastService } from "./services/BroadcastService";
15
+ export { BroadcastServiceInitialize } from "./services/BroadcastService";
15
16
  export { ElementType } from "./common/Constants";
16
17
  export { default as CallingContainer } from "./components/callingcontainer/CallingContainer";
17
18
  export { default as CurrentCall } from "./components/callingcontainer/subcomponents/CurrentCall/CurrentCall";
18
19
  export { default as IncomingCall } from "./components/callingcontainer/subcomponents/IncomingCall/IncomingCall";
19
- export { default as Timer } from "./components/callingcontainer/subcomponents/Timer/Timer";
20
+ export { default as Timer } from "./components/callingcontainer/subcomponents/Timer/Timer";
21
+ export { ModernChatIconBase64, LegacyChatIconBase64, CustomChatIconBase64, LoadingSpinnerBase64, AgentIconBase64, ChatReconnectIconBase64, CloseChatButtonIconBase64, MinimizeChatButtonIconBase64, ErrorIconBase64, AudioNotificationOffIconBase64, AudioNotificationOnIconBase64, ProactiveChatBannerBase64, TranscriptDownloadIconBase64, TranscriptEmailIconBase64, CallAcceptButtonBase64, CallRejectButtonBase64, VideoCallAcceptButtonIconBase64, VideoOffIconBase64, VideoOnIconBase64, VoiceOffIconBase64, VoiceOnIconBase64 } from "./assets/Icons";
@@ -1,19 +1,45 @@
1
1
  import { Subject } from "rxjs";
2
2
  import { filter } from "rxjs/operators";
3
3
  import { BroadcastChannel } from "broadcast-channel";
4
- import { BROADCAST_CHANNEL_NAME } from "../common/Constants";
5
- const newMessage = new Subject();
6
- const pubChannel = new BroadcastChannel(BROADCAST_CHANNEL_NAME);
7
- const subChannel = new BroadcastChannel(BROADCAST_CHANNEL_NAME); // eslint-disable-next-line @typescript-eslint/no-explicit-any
4
+ const newMessage = new Subject(); // eslint-disable-next-line @typescript-eslint/no-explicit-any
8
5
 
9
- subChannel.onmessage = message => {
10
- newMessage.next(message);
11
- };
6
+ const broadcastServicePubList = {}; // eslint-disable-next-line @typescript-eslint/no-explicit-any
7
+
8
+ const broadcastServiceSubList = {}; // eslint-disable-next-line @typescript-eslint/no-explicit-any
9
+
10
+ let pubChannel; // eslint-disable-next-line @typescript-eslint/no-explicit-any
11
+
12
+ let subChannel;
13
+ export const BroadcastServiceInitialize = channelName => {
14
+ if (broadcastServicePubList[channelName]) {
15
+ pubChannel = broadcastServicePubList[channelName];
16
+ } else {
17
+ const newPubChannel = new BroadcastChannel(channelName);
18
+ broadcastServicePubList[channelName] = newPubChannel;
19
+ pubChannel = newPubChannel;
20
+ }
21
+
22
+ if (broadcastServiceSubList[channelName]) {
23
+ subChannel = broadcastServiceSubList[channelName];
24
+ } else {
25
+ const newSubChannel = new BroadcastChannel(channelName);
26
+ broadcastServiceSubList[channelName] = newSubChannel;
27
+ subChannel = newSubChannel;
28
+ } // eslint-disable-next-line @typescript-eslint/no-explicit-any
12
29
 
30
+
31
+ subChannel.onmessage = message => {
32
+ newMessage.next(message);
33
+ };
34
+ };
13
35
  export const BroadcastService = {
14
36
  //broadcast a message
15
37
  postMessage: message => {
16
- pubChannel.postMessage(message);
38
+ /**
39
+ * Omit copying methods to prevent 'DataCloneError' in older browsers when passing an object with functions
40
+ * This exception occurs when an object can't be clone with the 'structured clone algorithm' (used by postMessage)
41
+ */
42
+ pubChannel.postMessage(JSON.parse(JSON.stringify(message)));
17
43
  },
18
44
  getMessage: message => {
19
45
  return newMessage.pipe(filter(msg => msg.elementId == message.elementId && msg.elementType == message.elementType && msg.eventName == message.eventName));