@envive-ai/react-widgets-v3 0.3.13 → 0.3.15-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (143) hide show
  1. package/dist/CXIntegration/implementations/useHelpScoutUnifiedCXButton.cjs +65 -0
  2. package/dist/CXIntegration/implementations/useHelpScoutUnifiedCXButton.js +64 -0
  3. package/dist/CXIntegration/implementations/useTalkdeskUnifiedCXButton.cjs +64 -0
  4. package/dist/CXIntegration/implementations/useTalkdeskUnifiedCXButton.js +63 -0
  5. package/dist/CXIntegration/types.cjs +2 -0
  6. package/dist/CXIntegration/types.js +2 -0
  7. package/dist/CXIntegration/utils/functions.cjs +4 -0
  8. package/dist/CXIntegration/utils/functions.js +4 -0
  9. package/dist/hocs/withBaseWidget/types.d.cts +3 -3
  10. package/dist/hocs/withBaseWidget/types.d.ts +5 -3
  11. package/dist/hocs/withBaseWidget/withBaseWidget.d.cts +2 -2
  12. package/dist/hocs/withBaseWidget/withBaseWidget.d.ts +2 -2
  13. package/dist/hooks/dist/application/models/api/widgetText.d.cts +8 -0
  14. package/dist/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.cts +12 -0
  15. package/dist/hooks/dist/contexts/types.d.cts +38 -0
  16. package/dist/hooks/dist/contexts/typesV3.d.cts +239 -0
  17. package/dist/hooks/dist/services/amplitudeService/eventNames.d.cts +43 -0
  18. package/dist/hooks/dist/types/customerService.d.cts +21 -0
  19. package/dist/packages/hooks/dist/application/models/api/orgConfigResults.d.ts +1 -0
  20. package/dist/packages/hooks/dist/application/models/api/widgetText.d.ts +8 -0
  21. package/dist/packages/hooks/dist/application/models/frontendConfig.d.ts +1 -0
  22. package/dist/packages/hooks/dist/contexts/amplitudeContext/amplitudeContext.d.ts +2 -0
  23. package/dist/packages/hooks/dist/contexts/amplitudeContext/index.d.ts +2 -0
  24. package/dist/packages/hooks/dist/contexts/featureFlagServiceContext/featureFlagServiceContext.d.ts +2 -0
  25. package/dist/packages/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts +14 -0
  26. package/dist/packages/hooks/dist/contexts/hardcopyContext/index.d.ts +1 -0
  27. package/dist/packages/hooks/dist/contexts/types.d.ts +42 -0
  28. package/dist/packages/hooks/dist/contexts/typesV3.d.ts +239 -0
  29. package/dist/packages/hooks/dist/services/amplitudeService/amplitudeService.d.ts +1 -0
  30. package/dist/packages/hooks/dist/services/amplitudeService/eventNames.d.ts +43 -0
  31. package/dist/packages/hooks/dist/types/customerService.d.ts +21 -0
  32. package/dist/packages/widgets/dist/SearchResults/SearchResults.d.ts +3 -2
  33. package/dist/packages/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.ts +2 -2
  34. package/dist/packages/widgets/dist/SearchZeroState/index.d.ts +2 -1
  35. package/dist/packages/widgets/dist/SearchZeroState/types.d.ts +2 -2
  36. package/dist/packages/widgets/dist/SuggestionBar/SuggestionBar.d.ts +3 -3
  37. package/dist/packages/widgets/dist/SuggestionButtonContainer/index.d.ts +2 -0
  38. package/dist/packages/widgets/dist/SuggestionButtonContainer/types.d.ts +3 -2
  39. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/api/response.d.ts +14 -0
  40. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/api/search.d.ts +15 -0
  41. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.ts +73 -0
  42. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts +61 -0
  43. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.ts +25 -0
  44. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.ts +35 -0
  45. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.ts +32 -0
  46. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.ts +32 -0
  47. package/dist/packages/widgets/dist/packages/hooks/dist/application/models/variantInfo/variantInfo.d.ts +1 -0
  48. package/dist/packages/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts +15 -0
  49. package/dist/packages/widgets/dist/packages/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts +1 -0
  50. package/dist/packages/widgets/dist/packages/hooks/dist/contexts/types.d.ts +63 -0
  51. package/dist/packages/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts +60 -0
  52. package/dist/packages/widgets/dist/packages/hooks/dist/hooks/utils.d.ts +13 -0
  53. package/dist/packages/widgets/dist/packages/hooks/dist/types/OrgInfo.d.ts +1 -0
  54. package/dist/packages/widgets/dist/packages/hooks/dist/types/index.d.ts +1 -0
  55. package/dist/packages/widgets/dist/packages/hooks/dist/types/search-filter-types.d.ts +28 -0
  56. package/dist/packages/widgets/dist/packages/hooks/dist/types/test-types.d.ts +10 -0
  57. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.cts +3 -3
  58. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.cts +3 -3
  59. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.ts +3 -3
  60. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.cts +3 -3
  61. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +3 -3
  62. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.cjs +29 -5
  63. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.cts +2 -2
  64. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.ts +2 -2
  65. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.js +30 -6
  66. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.cts +2 -2
  67. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.ts +2 -2
  68. package/dist/widgets/ProductCardWidget/ProductCardWidget.cjs +19 -3
  69. package/dist/widgets/ProductCardWidget/ProductCardWidget.d.cts +2 -2
  70. package/dist/widgets/ProductCardWidget/ProductCardWidget.d.ts +2 -2
  71. package/dist/widgets/ProductCardWidget/ProductCardWidget.js +20 -4
  72. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.cjs +10 -0
  73. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.cts +3 -3
  74. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.ts +3 -3
  75. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +12 -2
  76. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.cjs +15 -10
  77. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.cts +2 -2
  78. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +2 -2
  79. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.js +16 -11
  80. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.cts +2 -2
  81. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.ts +2 -2
  82. package/dist/widgets/SocialProofWidget/SocialProofWidget.cjs +10 -0
  83. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.cts +3 -3
  84. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.ts +3 -3
  85. package/dist/widgets/SocialProofWidget/SocialProofWidget.js +12 -2
  86. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.cjs +11 -0
  87. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.cts +2 -2
  88. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +2 -2
  89. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +12 -1
  90. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.cts +2 -2
  91. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts +2 -2
  92. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.cjs +23 -3
  93. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.cts +3 -3
  94. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts +3 -3
  95. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.js +24 -4
  96. package/dist/widgets/dist/SearchResults/SearchResults.d.cts +3 -2
  97. package/dist/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.cts +2 -2
  98. package/dist/widgets/dist/SearchZeroState/types.d.cts +2 -2
  99. package/dist/widgets/dist/SuggestionBar/SuggestionBar.d.cts +3 -3
  100. package/dist/widgets/dist/SuggestionButtonContainer/types.d.cts +3 -2
  101. package/dist/widgets/dist/packages/hooks/dist/application/models/api/response.d.cts +14 -0
  102. package/dist/widgets/dist/packages/hooks/dist/application/models/api/search.d.cts +15 -0
  103. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.cts +73 -0
  104. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.cts +61 -0
  105. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.cts +25 -0
  106. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.cts +35 -0
  107. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.cts +32 -0
  108. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.cts +32 -0
  109. package/dist/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.cts +14 -0
  110. package/dist/widgets/dist/packages/hooks/dist/contexts/types.d.cts +61 -0
  111. package/dist/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.cts +60 -0
  112. package/dist/widgets/dist/packages/hooks/dist/hooks/utils.d.cts +12 -0
  113. package/dist/widgets/dist/packages/hooks/dist/types/search-filter-types.d.cts +28 -0
  114. package/dist/widgets/dist/packages/hooks/dist/types/test-types.d.cts +10 -0
  115. package/dist/widgets/utils/functions.cjs +9 -0
  116. package/dist/widgets/utils/functions.js +9 -1
  117. package/dist/widgets-v2/SearchZeroState/index.d.cts +2 -1
  118. package/dist/widgets-v2/SearchZeroState/index.d.ts +2 -1
  119. package/dist/widgets-v2/SuggestionButtonContainer/index.d.ts +1 -0
  120. package/package.json +1 -1
  121. package/src/CXIntegration/implementations/useHelpScoutUnifiedCXButton.ts +108 -0
  122. package/src/CXIntegration/implementations/useTalkdeskUnifiedCXButton.ts +94 -0
  123. package/src/CXIntegration/types.ts +2 -0
  124. package/src/CXIntegration/utils/functions.ts +8 -0
  125. package/src/hocs/withBaseWidget/__tests__/withBaseWidget.test.tsx +15 -3
  126. package/src/widgets/ChatPreviewWidget/__tests__/ChatPreviewWidget.test.tsx +114 -0
  127. package/src/widgets/FloatingChatWidget/FloatingChatWidget.tsx +56 -15
  128. package/src/widgets/FloatingChatWidget/__tests__/FloatingChatWidget.test.tsx +119 -0
  129. package/src/widgets/ProductCardWidget/ProductCardWidget.tsx +15 -3
  130. package/src/widgets/ProductCardWidget/__tests__/ProductCardWidget.test.tsx +144 -0
  131. package/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.tsx +12 -1
  132. package/src/widgets/PromptButtonCarouselWithImageWidget/__tests__/PromptButtonCarouselWithImageWidget.test.tsx +179 -0
  133. package/src/widgets/PromptCarouselWidget/PromptCarouselWidget.tsx +33 -23
  134. package/src/widgets/PromptCarouselWidget/__tests__/PromptCarouselWidget.test.tsx +150 -0
  135. package/src/widgets/SocialProofWidget/SocialProofWidget.tsx +12 -1
  136. package/src/widgets/SocialProofWidget/__tests__/SocialProofWidget.test.tsx +184 -0
  137. package/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.tsx +12 -0
  138. package/src/widgets/TitledPromptCarouselWidget/__tests__/TitledPromptCarouselWidget.test.tsx +150 -0
  139. package/src/widgets/TypingAnimationWidget/TypingAnimationWidget.tsx +19 -2
  140. package/src/widgets/TypingAnimationWidget/__tests__/TypingAnimationWidget.test.tsx +163 -0
  141. package/src/widgets/__tests__/testUtils.tsx +63 -0
  142. package/src/widgets/__tests__/trackEventCanary.test.ts +45 -0
  143. package/src/widgets/utils/functions.ts +16 -0
@@ -0,0 +1,65 @@
1
+ const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
+ const require_constants = require('../../widgets/FloatingChatWidget/constants.cjs');
3
+ let __envive_ai_react_hooks_application_utils = require("@envive-ai/react-hooks/application/utils");
4
+ let __envive_ai_react_hooks_hooks_ElementObserver = require("@envive-ai/react-hooks/hooks/ElementObserver");
5
+
6
+ //#region src/CXIntegration/implementations/useHelpScoutUnifiedCXButton.ts
7
+ const BEACON_CONTAINER_ID = "beacon-container";
8
+ const useHelpScoutUnifiedCXButton = ({ onSwitchToAgent, suppressMerchantButton }) => {
9
+ const beaconContainer = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id(BEACON_CONTAINER_ID));
10
+ const enviveFloatingButton = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id(require_constants.FLOATING_BUTTON_ID));
11
+ const toggle = () => {
12
+ onSwitchToAgent();
13
+ if (typeof window.Beacon !== "undefined") window.Beacon("open");
14
+ else {
15
+ const fabButton = document.getElementById(BEACON_CONTAINER_ID)?.querySelector(".BeaconFabButtonFrame");
16
+ if (fabButton) {
17
+ fabButton.style.display = "";
18
+ fabButton.click();
19
+ }
20
+ }
21
+ if (suppressMerchantButton) enviveFloatingButton.hide();
22
+ };
23
+ const isHelpScoutButtonEnabled = () => {
24
+ const beaconContainerEl = document.getElementById("beacon-container");
25
+ if (!beaconContainerEl) return false;
26
+ const fabButton = beaconContainerEl.querySelector(".BeaconFabButtonFrame");
27
+ const hasBeaconAPI = typeof window.Beacon !== "undefined";
28
+ return !!(fabButton || hasBeaconAPI);
29
+ };
30
+ const isSwitchEnabled = () => isHelpScoutButtonEnabled();
31
+ beaconContainer.onAdd(() => {
32
+ if (suppressMerchantButton) {
33
+ const fabButton = document.getElementById(BEACON_CONTAINER_ID)?.querySelector(".BeaconFabButtonFrame");
34
+ if (fabButton) fabButton.style.display = "none";
35
+ enviveFloatingButton.show();
36
+ }
37
+ });
38
+ beaconContainer.onChange((el) => {
39
+ if (el && suppressMerchantButton) {
40
+ const beaconWidget = el.querySelector(".BeaconContainer");
41
+ const fabButton = el.querySelector(".BeaconFabButtonFrame");
42
+ if (beaconWidget && fabButton) {
43
+ const { classList } = beaconWidget;
44
+ if (classList.contains("BeaconContainer-enter-done") || classList.contains("BeaconContainer-enter-active")) {
45
+ fabButton.style.display = "";
46
+ enviveFloatingButton.hide();
47
+ }
48
+ if (classList.contains("BeaconContainer-exit") || classList.contains("BeaconContainer-exit-active")) {
49
+ fabButton.style.display = "none";
50
+ enviveFloatingButton.show();
51
+ }
52
+ }
53
+ }
54
+ });
55
+ beaconContainer.onRemove(() => {
56
+ if (suppressMerchantButton) enviveFloatingButton.show();
57
+ });
58
+ return {
59
+ toggle,
60
+ isSwitchEnabled
61
+ };
62
+ };
63
+
64
+ //#endregion
65
+ exports.useHelpScoutUnifiedCXButton = useHelpScoutUnifiedCXButton;
@@ -0,0 +1,64 @@
1
+ import { FLOATING_BUTTON_ID } from "../../widgets/FloatingChatWidget/constants.js";
2
+ import { SelectorFactory } from "@envive-ai/react-hooks/application/utils";
3
+ import { useElementObserver } from "@envive-ai/react-hooks/hooks/ElementObserver";
4
+
5
+ //#region src/CXIntegration/implementations/useHelpScoutUnifiedCXButton.ts
6
+ const BEACON_CONTAINER_ID = "beacon-container";
7
+ const useHelpScoutUnifiedCXButton = ({ onSwitchToAgent, suppressMerchantButton }) => {
8
+ const beaconContainer = useElementObserver(SelectorFactory.id(BEACON_CONTAINER_ID));
9
+ const enviveFloatingButton = useElementObserver(SelectorFactory.id(FLOATING_BUTTON_ID));
10
+ const toggle = () => {
11
+ onSwitchToAgent();
12
+ if (typeof window.Beacon !== "undefined") window.Beacon("open");
13
+ else {
14
+ const fabButton = document.getElementById(BEACON_CONTAINER_ID)?.querySelector(".BeaconFabButtonFrame");
15
+ if (fabButton) {
16
+ fabButton.style.display = "";
17
+ fabButton.click();
18
+ }
19
+ }
20
+ if (suppressMerchantButton) enviveFloatingButton.hide();
21
+ };
22
+ const isHelpScoutButtonEnabled = () => {
23
+ const beaconContainerEl = document.getElementById("beacon-container");
24
+ if (!beaconContainerEl) return false;
25
+ const fabButton = beaconContainerEl.querySelector(".BeaconFabButtonFrame");
26
+ const hasBeaconAPI = typeof window.Beacon !== "undefined";
27
+ return !!(fabButton || hasBeaconAPI);
28
+ };
29
+ const isSwitchEnabled = () => isHelpScoutButtonEnabled();
30
+ beaconContainer.onAdd(() => {
31
+ if (suppressMerchantButton) {
32
+ const fabButton = document.getElementById(BEACON_CONTAINER_ID)?.querySelector(".BeaconFabButtonFrame");
33
+ if (fabButton) fabButton.style.display = "none";
34
+ enviveFloatingButton.show();
35
+ }
36
+ });
37
+ beaconContainer.onChange((el) => {
38
+ if (el && suppressMerchantButton) {
39
+ const beaconWidget = el.querySelector(".BeaconContainer");
40
+ const fabButton = el.querySelector(".BeaconFabButtonFrame");
41
+ if (beaconWidget && fabButton) {
42
+ const { classList } = beaconWidget;
43
+ if (classList.contains("BeaconContainer-enter-done") || classList.contains("BeaconContainer-enter-active")) {
44
+ fabButton.style.display = "";
45
+ enviveFloatingButton.hide();
46
+ }
47
+ if (classList.contains("BeaconContainer-exit") || classList.contains("BeaconContainer-exit-active")) {
48
+ fabButton.style.display = "none";
49
+ enviveFloatingButton.show();
50
+ }
51
+ }
52
+ }
53
+ });
54
+ beaconContainer.onRemove(() => {
55
+ if (suppressMerchantButton) enviveFloatingButton.show();
56
+ });
57
+ return {
58
+ toggle,
59
+ isSwitchEnabled
60
+ };
61
+ };
62
+
63
+ //#endregion
64
+ export { useHelpScoutUnifiedCXButton };
@@ -0,0 +1,64 @@
1
+ const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
+ const require_constants = require('../../widgets/FloatingChatWidget/constants.cjs');
3
+ let __envive_ai_react_hooks_application_utils = require("@envive-ai/react-hooks/application/utils");
4
+ let __envive_ai_react_hooks_hooks_ElementObserver = require("@envive-ai/react-hooks/hooks/ElementObserver");
5
+
6
+ //#region src/CXIntegration/implementations/useTalkdeskUnifiedCXButton.ts
7
+ const useTalkdeskUnifiedCXButton = ({ onSwitchToAgent, suppressMerchantButton }) => {
8
+ const talkdeskButton = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id("talkdesk-chat-widget-trigger"));
9
+ const talkdeskWidget = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id("talkdesk-chat-widget"));
10
+ const talkdeskContainer = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id("tdWebchat"));
11
+ const enviveFloatingButton = (0, __envive_ai_react_hooks_hooks_ElementObserver.useElementObserver)(__envive_ai_react_hooks_application_utils.SelectorFactory.id(require_constants.FLOATING_BUTTON_ID));
12
+ const toggle = () => {
13
+ onSwitchToAgent();
14
+ if (suppressMerchantButton) enviveFloatingButton.hide();
15
+ talkdeskButton.show();
16
+ talkdeskButton.fire("click");
17
+ };
18
+ const isTalkdeskButtonEnabled = () => {
19
+ if (!document.getElementById("tdWebchat")) return false;
20
+ return !!document.getElementById("talkdesk-chat-widget-trigger");
21
+ };
22
+ const isSwitchEnabled = () => isTalkdeskButtonEnabled();
23
+ talkdeskButton.onAdd(() => {
24
+ if (suppressMerchantButton) {
25
+ talkdeskButton.hide();
26
+ enviveFloatingButton.show();
27
+ }
28
+ });
29
+ talkdeskWidget.onAdd((el) => {
30
+ if (el && suppressMerchantButton) if (el.getAttribute("aria-hidden") === "false") {
31
+ talkdeskButton.show();
32
+ enviveFloatingButton.hide();
33
+ } else {
34
+ talkdeskButton.hide();
35
+ enviveFloatingButton.show();
36
+ }
37
+ });
38
+ talkdeskWidget.onChange((el) => {
39
+ if (el && suppressMerchantButton) {
40
+ const ariaHidden = el.getAttribute("aria-hidden");
41
+ if (ariaHidden === "false") {
42
+ talkdeskButton.show();
43
+ enviveFloatingButton.hide();
44
+ }
45
+ if (ariaHidden === "true") {
46
+ talkdeskButton.hide();
47
+ enviveFloatingButton.show();
48
+ }
49
+ }
50
+ });
51
+ talkdeskContainer.onRemove(() => {
52
+ if (suppressMerchantButton) {
53
+ talkdeskButton.hide();
54
+ enviveFloatingButton.show();
55
+ }
56
+ });
57
+ return {
58
+ toggle,
59
+ isSwitchEnabled
60
+ };
61
+ };
62
+
63
+ //#endregion
64
+ exports.useTalkdeskUnifiedCXButton = useTalkdeskUnifiedCXButton;
@@ -0,0 +1,63 @@
1
+ import { FLOATING_BUTTON_ID } from "../../widgets/FloatingChatWidget/constants.js";
2
+ import { SelectorFactory } from "@envive-ai/react-hooks/application/utils";
3
+ import { useElementObserver } from "@envive-ai/react-hooks/hooks/ElementObserver";
4
+
5
+ //#region src/CXIntegration/implementations/useTalkdeskUnifiedCXButton.ts
6
+ const useTalkdeskUnifiedCXButton = ({ onSwitchToAgent, suppressMerchantButton }) => {
7
+ const talkdeskButton = useElementObserver(SelectorFactory.id("talkdesk-chat-widget-trigger"));
8
+ const talkdeskWidget = useElementObserver(SelectorFactory.id("talkdesk-chat-widget"));
9
+ const talkdeskContainer = useElementObserver(SelectorFactory.id("tdWebchat"));
10
+ const enviveFloatingButton = useElementObserver(SelectorFactory.id(FLOATING_BUTTON_ID));
11
+ const toggle = () => {
12
+ onSwitchToAgent();
13
+ if (suppressMerchantButton) enviveFloatingButton.hide();
14
+ talkdeskButton.show();
15
+ talkdeskButton.fire("click");
16
+ };
17
+ const isTalkdeskButtonEnabled = () => {
18
+ if (!document.getElementById("tdWebchat")) return false;
19
+ return !!document.getElementById("talkdesk-chat-widget-trigger");
20
+ };
21
+ const isSwitchEnabled = () => isTalkdeskButtonEnabled();
22
+ talkdeskButton.onAdd(() => {
23
+ if (suppressMerchantButton) {
24
+ talkdeskButton.hide();
25
+ enviveFloatingButton.show();
26
+ }
27
+ });
28
+ talkdeskWidget.onAdd((el) => {
29
+ if (el && suppressMerchantButton) if (el.getAttribute("aria-hidden") === "false") {
30
+ talkdeskButton.show();
31
+ enviveFloatingButton.hide();
32
+ } else {
33
+ talkdeskButton.hide();
34
+ enviveFloatingButton.show();
35
+ }
36
+ });
37
+ talkdeskWidget.onChange((el) => {
38
+ if (el && suppressMerchantButton) {
39
+ const ariaHidden = el.getAttribute("aria-hidden");
40
+ if (ariaHidden === "false") {
41
+ talkdeskButton.show();
42
+ enviveFloatingButton.hide();
43
+ }
44
+ if (ariaHidden === "true") {
45
+ talkdeskButton.hide();
46
+ enviveFloatingButton.show();
47
+ }
48
+ }
49
+ });
50
+ talkdeskContainer.onRemove(() => {
51
+ if (suppressMerchantButton) {
52
+ talkdeskButton.hide();
53
+ enviveFloatingButton.show();
54
+ }
55
+ });
56
+ return {
57
+ toggle,
58
+ isSwitchEnabled
59
+ };
60
+ };
61
+
62
+ //#endregion
63
+ export { useTalkdeskUnifiedCXButton };
@@ -11,6 +11,8 @@ let CustomerServiceType = /* @__PURE__ */ function(CustomerServiceType$1) {
11
11
  CustomerServiceType$1["gladly"] = "gladly";
12
12
  CustomerServiceType$1["richpanel"] = "richpanel";
13
13
  CustomerServiceType$1["zendesk"] = "zendesk";
14
+ CustomerServiceType$1["helpscout"] = "helpscout";
15
+ CustomerServiceType$1["talkdesk"] = "talkdesk";
14
16
  CustomerServiceType$1["eightByEight"] = "8x8";
15
17
  CustomerServiceType$1["unsupported"] = "unsupported";
16
18
  return CustomerServiceType$1;
@@ -10,6 +10,8 @@ let CustomerServiceType = /* @__PURE__ */ function(CustomerServiceType$1) {
10
10
  CustomerServiceType$1["gladly"] = "gladly";
11
11
  CustomerServiceType$1["richpanel"] = "richpanel";
12
12
  CustomerServiceType$1["zendesk"] = "zendesk";
13
+ CustomerServiceType$1["helpscout"] = "helpscout";
14
+ CustomerServiceType$1["talkdesk"] = "talkdesk";
13
15
  CustomerServiceType$1["eightByEight"] = "8x8";
14
16
  CustomerServiceType$1["unsupported"] = "unsupported";
15
17
  return CustomerServiceType$1;
@@ -9,6 +9,8 @@ const require_useReDoUnifiedCXButton = require('../implementations/useReDoUnifie
9
9
  const require_useRichpanelUnifiedCXButton = require('../implementations/useRichpanelUnifiedCXButton.cjs');
10
10
  const require_useZendeskUnifiedCXButton = require('../implementations/useZendeskUnifiedCXButton.cjs');
11
11
  const require_useKustomerUnifiedCXButton = require('../implementations/useKustomerUnifiedCXButton.cjs');
12
+ const require_useHelpScoutUnifiedCXButton = require('../implementations/useHelpScoutUnifiedCXButton.cjs');
13
+ const require_useTalkdeskUnifiedCXButton = require('../implementations/useTalkdeskUnifiedCXButton.cjs');
12
14
  const require_useEightByEightUnifiedCXButton = require('../implementations/useEightByEightUnifiedCXButton.cjs');
13
15
  const require_useDefaultUnifiedCXButton = require('../implementations/useDefaultUnifiedCXButton.cjs');
14
16
 
@@ -24,6 +26,8 @@ const findCustomerServiceImpl = (provider) => {
24
26
  if (provider === require_types.CustomerServiceType.redo) return require_useReDoUnifiedCXButton.useReDoUnifiedCXButton;
25
27
  if (provider === require_types.CustomerServiceType.richpanel) return require_useRichpanelUnifiedCXButton.useRichpanelUnifiedCXButton;
26
28
  if (provider === require_types.CustomerServiceType.zendesk) return require_useZendeskUnifiedCXButton.useZendeskUnifiedCXButton;
29
+ if (provider === require_types.CustomerServiceType.helpscout) return require_useHelpScoutUnifiedCXButton.useHelpScoutUnifiedCXButton;
30
+ if (provider === require_types.CustomerServiceType.talkdesk) return require_useTalkdeskUnifiedCXButton.useTalkdeskUnifiedCXButton;
27
31
  if (provider === require_types.CustomerServiceType.eightByEight) return require_useEightByEightUnifiedCXButton.useEightByEightUnifiedCXButton;
28
32
  return require_useDefaultUnifiedCXButton.useDefaultUnifiedCXButton;
29
33
  };
@@ -9,6 +9,8 @@ import { useReDoUnifiedCXButton } from "../implementations/useReDoUnifiedCXButto
9
9
  import { useRichpanelUnifiedCXButton } from "../implementations/useRichpanelUnifiedCXButton.js";
10
10
  import { useZendeskUnifiedCXButton } from "../implementations/useZendeskUnifiedCXButton.js";
11
11
  import { useKustomerUnifiedCXButton } from "../implementations/useKustomerUnifiedCXButton.js";
12
+ import { useHelpScoutUnifiedCXButton } from "../implementations/useHelpScoutUnifiedCXButton.js";
13
+ import { useTalkdeskUnifiedCXButton } from "../implementations/useTalkdeskUnifiedCXButton.js";
12
14
  import { useEightByEightUnifiedCXButton } from "../implementations/useEightByEightUnifiedCXButton.js";
13
15
  import { useDefaultUnifiedCXButton } from "../implementations/useDefaultUnifiedCXButton.js";
14
16
 
@@ -24,6 +26,8 @@ const findCustomerServiceImpl = (provider) => {
24
26
  if (provider === CustomerServiceType.redo) return useReDoUnifiedCXButton;
25
27
  if (provider === CustomerServiceType.richpanel) return useRichpanelUnifiedCXButton;
26
28
  if (provider === CustomerServiceType.zendesk) return useZendeskUnifiedCXButton;
29
+ if (provider === CustomerServiceType.helpscout) return useHelpScoutUnifiedCXButton;
30
+ if (provider === CustomerServiceType.talkdesk) return useTalkdeskUnifiedCXButton;
27
31
  if (provider === CustomerServiceType.eightByEight) return useEightByEightUnifiedCXButton;
28
32
  return useDefaultUnifiedCXButton;
29
33
  };
@@ -1,7 +1,7 @@
1
+ import { SpiffyMetricsEventName } from "../../hooks/dist/services/amplitudeService/eventNames.cjs";
2
+ import { OrgUIConfigV3, WidgetConfigV3, WidgetTypeV3 } from "../../hooks/dist/contexts/typesV3.cjs";
3
+ import { HardcopyResponse } from "../../hooks/dist/contexts/hardcopyContext/hardcopyContext.cjs";
1
4
  import { RefObject } from "react";
2
- import { SpiffyMetricsEventName } from "@envive-ai/react-hooks/contexts/amplitudeContext";
3
- import { HardcopyResponse } from "@envive-ai/react-hooks/contexts/hardcopyContext";
4
- import { OrgUIConfigV3, WidgetConfigV3, WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
5
5
 
6
6
  //#region src/hocs/withBaseWidget/types.d.ts
7
7
  interface BaseWidgetProps {
@@ -1,7 +1,9 @@
1
+ import { SpiffyMetricsEventName } from "../../packages/hooks/dist/services/amplitudeService/eventNames.js";
2
+ import { OrgUIConfigV3, WidgetConfigV3, WidgetTypeV3 } from "../../packages/hooks/dist/contexts/typesV3.js";
3
+ import { HardcopyResponse } from "../../packages/hooks/dist/contexts/hardcopyContext/hardcopyContext.js";
4
+ import "../../packages/hooks/dist/contexts/amplitudeContext/index.js";
5
+ import "../../packages/hooks/dist/contexts/hardcopyContext/index.js";
1
6
  import { RefObject } from "react";
2
- import { SpiffyMetricsEventName } from "@envive-ai/react-hooks/contexts/amplitudeContext";
3
- import { HardcopyResponse } from "@envive-ai/react-hooks/contexts/hardcopyContext";
4
- import { OrgUIConfigV3, WidgetConfigV3, WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
5
7
 
6
8
  //#region src/hocs/withBaseWidget/types.d.ts
7
9
  interface BaseWidgetProps {
@@ -1,9 +1,9 @@
1
1
  import { BaseWidgetProps, WithBaseWidgetOptions } from "./types.cjs";
2
- import * as react_jsx_runtime17 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/hocs/withBaseWidget/withBaseWidget.d.ts
5
5
  declare function withBaseWidget<P extends BaseWidgetProps>(Widget: React.ComponentType<P>, options?: WithBaseWidgetOptions): {
6
- (props: P): react_jsx_runtime17.JSX.Element;
6
+ (props: P): react_jsx_runtime0.JSX.Element;
7
7
  displayName: string;
8
8
  };
9
9
  //#endregion
@@ -1,9 +1,9 @@
1
1
  import { BaseWidgetProps, WithBaseWidgetOptions } from "./types.js";
2
- import * as react_jsx_runtime11 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime18 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/hocs/withBaseWidget/withBaseWidget.d.ts
5
5
  declare function withBaseWidget<P extends BaseWidgetProps>(Widget: React.ComponentType<P>, options?: WithBaseWidgetOptions): {
6
- (props: P): react_jsx_runtime11.JSX.Element;
6
+ (props: P): react_jsx_runtime18.JSX.Element;
7
7
  displayName: string;
8
8
  };
9
9
  //#endregion
@@ -0,0 +1,8 @@
1
+ //#region ../hooks/dist/application/models/api/widgetText.d.ts
2
+ //#region src/application/models/api/widgetText.d.ts
3
+ type WidgetString = {
4
+ id: string;
5
+ value: string;
6
+ };
7
+ //#endregion
8
+ export { WidgetString };
@@ -0,0 +1,12 @@
1
+ import { WidgetString } from "../../application/models/api/widgetText.cjs";
2
+
3
+ //#region ../hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts
4
+
5
+ type HardcopyResponse = {
6
+ responseId: string;
7
+ language: string;
8
+ rawValues?: Record<string, WidgetString | WidgetString[]>;
9
+ values: Record<string, string | string[]>;
10
+ };
11
+ //#endregion
12
+ export { HardcopyResponse };
@@ -0,0 +1,38 @@
1
+ //#region ../hooks/dist/contexts/types.d.ts
2
+
3
+ interface AlphabeticFilterSorting {
4
+ type: 'alphabetic';
5
+ }
6
+ interface ProductCountFilterSorting {
7
+ type: 'productCount';
8
+ }
9
+ interface CustomFilterSorting {
10
+ type: 'custom';
11
+ map: Record<string, number>;
12
+ }
13
+ type FilterSorting = AlphabeticFilterSorting | ProductCountFilterSorting | CustomFilterSorting;
14
+ interface BaseFilterConfig {
15
+ filterId: string;
16
+ displayName: string;
17
+ }
18
+ interface DynamicFilterConfig extends BaseFilterConfig {
19
+ type: 'dynamic';
20
+ attribute: string;
21
+ sorting: FilterSorting;
22
+ }
23
+ interface PriceFilterConfig extends BaseFilterConfig {
24
+ type: 'price';
25
+ bucketSize: number;
26
+ }
27
+ type FilterAttribute = DynamicFilterConfig | PriceFilterConfig;
28
+ interface SearchConfig {
29
+ enableGlobalSearch: boolean;
30
+ searchFilterConfig: FilterAttribute[];
31
+ searchOverlayHeading?: string;
32
+ redirectSearchResultsUrl?: string;
33
+ additiveDynamicFilters?: boolean;
34
+ recommendedProducts?: string[];
35
+ recommendedProductsHeading?: string;
36
+ }
37
+ //#endregion
38
+ export { type SearchConfig };
@@ -0,0 +1,239 @@
1
+ import { CustomerServiceType } from "../types/customerService.cjs";
2
+ import { SearchConfig } from "./types.cjs";
3
+ import { FloatingButtonLocation } from "@envive-ai/react-toolkit-v3/FloatingButton";
4
+ import { ImageGalleryImage, ImageGalleryLayout } from "@envive-ai/react-toolkit-v3/ImageGallery";
5
+ import { PromptButtonVariant } from "@envive-ai/react-toolkit-v3/PromptButton";
6
+ import { AnimationSpeed, PromptCarouselRows } from "@envive-ai/react-toolkit-v3/PromptCarousel";
7
+ import { DynamicLayout, WidgetKind } from "@envive-ai/react-toolkit-v3/SocialProof";
8
+ import { Theme } from "@envive-ai/react-toolkit-v3/Tokens";
9
+ import { SparkleIconColor } from "@envive-ai/react-toolkit-v3/WelcomeMessage";
10
+ import { WidgetWrapperVariant } from "@envive-ai/react-toolkit-v3/WidgetWrapper";
11
+
12
+ //#region ../hooks/dist/contexts/typesV3.d.ts
13
+
14
+ type ImageAspectRatio = '1/1' | '3/4';
15
+ type ButtonColors = {
16
+ lightButtonBackgroundColor: string;
17
+ lightButtonIconColor: string;
18
+ darkButtonBackgroundColor: string;
19
+ darkButtonIconColor: string;
20
+ };
21
+ type Typography = {
22
+ titleFontFamily: string;
23
+ headerFontFamily: string;
24
+ bodyFontFamily: string;
25
+ fontSize?: {
26
+ t1: string;
27
+ t2: string;
28
+ t3: string;
29
+ h1: string;
30
+ h2: string;
31
+ h3: string;
32
+ b1: string;
33
+ b2: string;
34
+ b3: string;
35
+ b4: string;
36
+ b5: string;
37
+ l1: string;
38
+ l2: string;
39
+ };
40
+ fontWeight?: {
41
+ rg: string;
42
+ md: string;
43
+ sb: string;
44
+ };
45
+ letterSpacing?: {
46
+ '0': string;
47
+ 'wide-1': string;
48
+ };
49
+ lineHeight?: {
50
+ '124': number;
51
+ '120': number;
52
+ '118': number;
53
+ '116': number;
54
+ '114': number;
55
+ '148': number;
56
+ '140': number;
57
+ '128': number;
58
+ '130': number;
59
+ '133': number;
60
+ };
61
+ };
62
+ type LookAndFeelConfig = {
63
+ theme: Theme;
64
+ agentName: string;
65
+ chatHeaderLogoDarkSrc: string;
66
+ chatHeaderLogoLightSrc: string;
67
+ widgetLogoSrc: string;
68
+ hideWidgetLogo: boolean;
69
+ elementRadius: number;
70
+ imageAspectRatio: ImageAspectRatio;
71
+ buttonColors: ButtonColors;
72
+ typography: Typography;
73
+ };
74
+ declare enum ConfigVersionEnum {
75
+ V3 = "v3",
76
+ Deprecated = "deprecated",
77
+ }
78
+ type ConfigVersion = ConfigVersionEnum.V3 | ConfigVersionEnum.Deprecated | undefined;
79
+ type Mode = 'dark' | 'light';
80
+ type ShowOptions = 'always' | 'postInteraction' | 'none';
81
+ type Style = 'attached' | 'detached';
82
+ type FloatingButtonConfig = {
83
+ position: FloatingButtonLocation;
84
+ backgroundColor?: string;
85
+ mode: Mode;
86
+ showOption: ShowOptions;
87
+ iconSVGSrc?: string;
88
+ style: Style;
89
+ };
90
+ type ReferrerPopupTrigger = {
91
+ type: 'referrer';
92
+ referrers: string[];
93
+ };
94
+ type AutomaticPopupTrigger = {
95
+ type: 'automatic';
96
+ };
97
+ type PopupTrigger = ReferrerPopupTrigger | AutomaticPopupTrigger;
98
+ type AutoPopupTrigger = {
99
+ delay: number;
100
+ trigger: PopupTrigger;
101
+ };
102
+ interface AutoPopupConfig {
103
+ triggers: AutoPopupTrigger[];
104
+ }
105
+ type PartialViewConfig = {
106
+ /**
107
+ * When true, only full-screen mode is supported (no partial/draggable middle state).
108
+ * Useful when partial view causes usability issues on mobile.
109
+ * Default: false (undefined and false = partial view enabled).
110
+ */
111
+ disabled?: boolean;
112
+ };
113
+ type FloatingChatConfig = {
114
+ headerBackgroundColor?: string;
115
+ headerMode: Mode;
116
+ welcomeMessageIconColor: SparkleIconColor;
117
+ showVerifiedBuyer: boolean;
118
+ userQueryInputEnabled: boolean;
119
+ showEnviveLogo: boolean;
120
+ ignoreFirstModelResponse?: boolean;
121
+ neverShowSingleProductCards?: boolean;
122
+ welcomeMessageTitle: string;
123
+ welcomeMessageText: string;
124
+ chatFooterTextFieldPlaceholderText: string;
125
+ autoPopupConfig?: AutoPopupConfig;
126
+ partialViewConfig?: PartialViewConfig;
127
+ };
128
+ type CustomerServiceIntegration = {
129
+ enabled: boolean;
130
+ provider: CustomerServiceType;
131
+ suppressMerchantButton?: boolean;
132
+ };
133
+ type SPASettings = {
134
+ enabled: boolean;
135
+ refreshInterval?: number;
136
+ };
137
+ type OrgUIConfigV3 = {
138
+ id?: string;
139
+ version: ConfigVersion;
140
+ shortName: string;
141
+ lookAndFeel: LookAndFeelConfig;
142
+ floatingButton: FloatingButtonConfig;
143
+ floatingChat: FloatingChatConfig;
144
+ merchantOverrideCss?: string;
145
+ customerServiceIntegration?: CustomerServiceIntegration;
146
+ singlePageApplicationSettings?: SPASettings;
147
+ searchConfig?: SearchConfig;
148
+ };
149
+ declare enum WidgetTypeV3 {
150
+ PromptCarouselV3 = "PromptCarouselV3",
151
+ TitledPromptCarouselV3 = "TitledPromptCarouselV3",
152
+ SocialProofV3 = "SocialProofV3",
153
+ TypingAnimationV3 = "TypingAnimationV3",
154
+ ChatPreviewV3 = "ChatPreviewV3",
155
+ ChatPreviewComparisonV3 = "ChatPreviewComparisonV3",
156
+ ChatPreviewLoadingV3 = "ChatPreviewLoadingV3",
157
+ ImagePromptCardV3 = "ImagePromptCardV3",
158
+ PromptButtonCarouselWithImageV3 = "PromptButtonCarouselWithImageV3",
159
+ ImageBannerV3 = "ImageBannerV3",
160
+ SingleImagePromptV3 = "SingleImagePromptV3",
161
+ FloatingChatV3 = "FloatingChatV3",
162
+ FloatingButtonV3 = "FloatingButtonV3",
163
+ ProductCardV3 = "ProductCardV3",
164
+ FullPageSalesAgentV3 = "FullPageSalesAgentV3",
165
+ }
166
+ interface BaseWidgetConfig<T extends WidgetTypeV3> {
167
+ widgetConfigId: string;
168
+ type: T;
169
+ contentId?: string;
170
+ }
171
+ interface PromptCarouselWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.PromptCarouselV3> {
172
+ promptButtonType?: PromptButtonVariant;
173
+ boldFirstButton?: boolean;
174
+ promptCarouselRows?: PromptCarouselRows;
175
+ animationSpeed?: AnimationSpeed;
176
+ }
177
+ interface TitledPromptCarouselWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.TitledPromptCarouselV3> {
178
+ promptButtonType?: PromptButtonVariant;
179
+ boldFirstButton?: boolean;
180
+ promptCarouselRows?: PromptCarouselRows;
181
+ animationSpeed?: AnimationSpeed;
182
+ }
183
+ interface SocialProofWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.SocialProofV3> {
184
+ kind: WidgetKind;
185
+ variant: WidgetWrapperVariant;
186
+ hexCardColor?: string;
187
+ promptCarouselRows: PromptCarouselRows;
188
+ hideImage?: boolean;
189
+ imageGalleryLayout: Exclude<ImageGalleryLayout, 'TWO_SIDE'>;
190
+ hideTextField?: boolean;
191
+ primaryButtonVariant: Exclude<PromptButtonVariant, 'suggestedResponse' | 'ghost'>;
192
+ secondaryButtonVariant: Exclude<PromptButtonVariant, 'suggestedResponse' | 'ghost'>;
193
+ dynamicLayout?: DynamicLayout;
194
+ images?: ImageGalleryImage[];
195
+ }
196
+ interface TypingAnimationWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.TypingAnimationV3> {
197
+ widgetVariant?: WidgetWrapperVariant;
198
+ cardColor?: string;
199
+ promptButtonType?: PromptButtonVariant;
200
+ promptCarouselRows?: PromptCarouselRows;
201
+ showTextField?: boolean;
202
+ }
203
+ interface ChatPreviewComparisonWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.ChatPreviewComparisonV3> {
204
+ variant: WidgetWrapperVariant;
205
+ hexCardColor?: string;
206
+ hideImage?: boolean;
207
+ hideTextField?: boolean;
208
+ }
209
+ interface ChatPreviewLoadingWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.ChatPreviewLoadingV3> {
210
+ variant: WidgetWrapperVariant;
211
+ hexCardColor?: string;
212
+ hideTextField?: boolean;
213
+ }
214
+ interface ChatPreviewWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.ChatPreviewV3> {
215
+ variant: WidgetWrapperVariant;
216
+ hexCardColor?: string;
217
+ hideTextField?: boolean;
218
+ }
219
+ interface PromptButtonCarouselWithImageWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.PromptButtonCarouselWithImageV3> {
220
+ promptButtonType?: PromptButtonVariant;
221
+ image?: ImageGalleryImage;
222
+ hideTextField?: boolean;
223
+ isDynamic?: boolean;
224
+ }
225
+ interface FloatingChatWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.FloatingChatV3> {}
226
+ interface ProductCardWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.ProductCardV3> {
227
+ promptButtonType?: PromptButtonVariant;
228
+ italicizeHeadline?: boolean;
229
+ fallbackColor?: string;
230
+ imageSrc?: string;
231
+ }
232
+ interface FullPageSalesAgentWidgetV3Config extends BaseWidgetConfig<WidgetTypeV3.FullPageSalesAgentV3> {
233
+ headerContainer?: string;
234
+ autoHeight?: boolean;
235
+ }
236
+ type WidgetConfigV3 = PromptCarouselWidgetV3Config | SocialProofWidgetV3Config | TitledPromptCarouselWidgetV3Config | ChatPreviewComparisonWidgetV3Config | ChatPreviewLoadingWidgetV3Config | TypingAnimationWidgetV3Config | ChatPreviewWidgetV3Config | PromptButtonCarouselWithImageWidgetV3Config | FloatingChatWidgetV3Config | ProductCardWidgetV3Config | FullPageSalesAgentWidgetV3Config;
237
+ //#endregion
238
+ //#endregion
239
+ export { type OrgUIConfigV3, type WidgetConfigV3, WidgetTypeV3 };