@envive-ai/react-toolkit-v3 0.3.19 → 0.3.20

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 (277) hide show
  1. package/dist/AnimatedText/AnimatedText.d.cts +3 -3
  2. package/dist/AnimatedText/AnimatedText.d.ts +3 -3
  3. package/dist/CSSVariablesEditor/CssVariablesEditorComponent.d.cts +2 -2
  4. package/dist/CSSVariablesEditor/CssVariablesEditorComponent.d.ts +2 -2
  5. package/dist/CSSVariablesEditor/hooks/useGetCssVariablesOptions.cjs +1 -1
  6. package/dist/CSSVariablesEditor/hooks/useGetCssVariablesOptions.js +1 -1
  7. package/dist/CSSVariablesEditor/hooks/useGetCurrentMerchantColors.cjs +1 -1
  8. package/dist/CSSVariablesEditor/hooks/useGetCurrentMerchantColors.js +1 -1
  9. package/dist/CSSVariablesEditor/hooks/useGetDefaultCssVariables.cjs +1 -1
  10. package/dist/CSSVariablesEditor/hooks/useGetDefaultCssVariables.js +1 -1
  11. package/dist/CSSVariablesEditor/hooks/useHandleUpdateCssVars.cjs +1 -1
  12. package/dist/CSSVariablesEditor/hooks/useHandleUpdateCssVars.js +1 -1
  13. package/dist/Carousel/Carousel.cjs +1 -1
  14. package/dist/Carousel/Carousel.d.cts +2 -2
  15. package/dist/Carousel/Carousel.js +1 -1
  16. package/dist/Carousel/components/Badge.cjs +1 -1
  17. package/dist/Carousel/components/Badge.js +1 -1
  18. package/dist/Carousel/components/Container.cjs +3 -3
  19. package/dist/Carousel/components/Container.js +3 -3
  20. package/dist/ChatFooter/ChatFooter.cjs +2 -2
  21. package/dist/ChatFooter/ChatFooter.d.cts +2 -2
  22. package/dist/ChatFooter/ChatFooter.d.ts +2 -2
  23. package/dist/ChatFooter/ChatFooter.js +2 -2
  24. package/dist/ChatFooter/components/Layout.cjs +3 -3
  25. package/dist/ChatFooter/components/Layout.js +3 -3
  26. package/dist/ChatFooter/components/index.d.cts +5 -5
  27. package/dist/ChatFooter/components/index.d.ts +5 -5
  28. package/dist/ChatHeader/ChatHeader.d.cts +2 -2
  29. package/dist/ChatHeader/components/Handle.cjs +2 -2
  30. package/dist/ChatHeader/components/Handle.js +2 -2
  31. package/dist/ChatHeader/components/Toggle.cjs +3 -3
  32. package/dist/ChatHeader/components/Toggle.js +3 -3
  33. package/dist/ChatHeader/hooks/useGetLayoutProperties.cjs +1 -1
  34. package/dist/ChatHeader/hooks/useGetLayoutProperties.js +1 -1
  35. package/dist/ChatPreview/ChatPreview.cjs +1 -1
  36. package/dist/ChatPreview/ChatPreview.d.ts +2 -2
  37. package/dist/ChatPreview/ChatPreview.js +1 -1
  38. package/dist/ChatPreviewComparison/ChatPreviewComparison.cjs +1 -1
  39. package/dist/ChatPreviewComparison/ChatPreviewComparison.d.ts +2 -2
  40. package/dist/ChatPreviewComparison/ChatPreviewComparison.js +1 -1
  41. package/dist/ChatPreviewComparison/components/Headline.cjs +2 -2
  42. package/dist/ChatPreviewComparison/components/Headline.js +2 -2
  43. package/dist/ChatPreviewComparison/components/Layout.cjs +8 -8
  44. package/dist/ChatPreviewComparison/components/Layout.js +6 -6
  45. package/dist/ChatPreviewComparison/components/Message.cjs +4 -4
  46. package/dist/ChatPreviewComparison/components/Message.js +2 -2
  47. package/dist/ChatPreviewLoading/ChatPreviewLoading.d.cts +2 -2
  48. package/dist/ChatPreviewLoading/ChatPreviewLoading.d.ts +2 -2
  49. package/dist/Container/Container.d.cts +8 -8
  50. package/dist/Container/Container.d.ts +173 -173
  51. package/dist/DesignTokens/DesignTokensComponent.d.cts +2 -2
  52. package/dist/DesignTokens/DesignTokensComponent.d.ts +2 -2
  53. package/dist/DesignTokens/components/FontFamily.cjs +1 -1
  54. package/dist/DesignTokens/components/FontFamily.js +1 -1
  55. package/dist/DesignTokens/components/FontSize.cjs +1 -1
  56. package/dist/DesignTokens/components/FontSize.js +1 -1
  57. package/dist/DesignTokens/components/FontWeight.cjs +1 -1
  58. package/dist/DesignTokens/components/FontWeight.js +1 -1
  59. package/dist/DesignTokens/components/LetterSpacing.cjs +1 -1
  60. package/dist/DesignTokens/components/LetterSpacing.js +1 -1
  61. package/dist/DesignTokens/components/LineHeight.cjs +1 -1
  62. package/dist/DesignTokens/components/LineHeight.js +1 -1
  63. package/dist/DesignTokens/components/Typography.cjs +1 -1
  64. package/dist/DesignTokens/components/Typography.js +1 -1
  65. package/dist/Disclaimer/components/Container.cjs +3 -3
  66. package/dist/Disclaimer/components/Container.js +3 -3
  67. package/dist/DocumentRetrievalCard/DocumentRetrievalCard.d.cts +2 -2
  68. package/dist/DocumentRetrievalCard/DocumentRetrievalCard.d.ts +2 -2
  69. package/dist/DocumentRetrievalCard/components/Image.cjs +1 -1
  70. package/dist/DocumentRetrievalCard/components/Image.js +1 -1
  71. package/dist/DocumentRetrievalCard/components/Layout.cjs +3 -3
  72. package/dist/DocumentRetrievalCard/components/Layout.js +3 -3
  73. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Icon.cjs +2 -2
  74. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Icon.js +2 -2
  75. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Label.cjs +1 -1
  76. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Label.js +1 -1
  77. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Layout.cjs +1 -1
  78. package/dist/DocumentRetrievalCard/components/ViewArticleButton/components/Layout.js +1 -1
  79. package/dist/FloatingButton/FloatingButton.d.cts +2 -2
  80. package/dist/FloatingButton/FloatingButton.d.ts +2 -2
  81. package/dist/FloatingButton/components/Button.cjs +1 -1
  82. package/dist/FloatingButton/components/Button.js +1 -1
  83. package/dist/FloatingButton/components/Container.cjs +1 -1
  84. package/dist/FloatingButton/components/Container.js +1 -1
  85. package/dist/FloatingButton/components/Wrapper.cjs +1 -1
  86. package/dist/FloatingButton/components/Wrapper.js +1 -1
  87. package/dist/FloatingChat/FloatingChat.cjs +25 -22
  88. package/dist/FloatingChat/FloatingChat.d.cts +4 -3
  89. package/dist/FloatingChat/FloatingChat.d.ts +4 -3
  90. package/dist/FloatingChat/FloatingChat.js +26 -23
  91. package/dist/FloatingChat/components/AgentMessage.cjs +2 -8
  92. package/dist/FloatingChat/components/AgentMessage.js +2 -8
  93. package/dist/FloatingChat/components/ChatMessages.cjs +2 -2
  94. package/dist/FloatingChat/components/ChatMessages.js +2 -2
  95. package/dist/FloatingChat/components/Layout.cjs +4 -4
  96. package/dist/FloatingChat/components/Layout.js +4 -4
  97. package/dist/FloatingChat/components/ProductResultsModal.cjs +62 -0
  98. package/dist/FloatingChat/components/ProductResultsModal.js +60 -0
  99. package/dist/FloatingChat/components/ResultsGridView.cjs +18 -4
  100. package/dist/FloatingChat/components/ResultsGridView.js +16 -5
  101. package/dist/FloatingChat/components/SalesAgentBadgeContent.cjs +2 -2
  102. package/dist/FloatingChat/components/SalesAgentBadgeContent.js +2 -2
  103. package/dist/FloatingChat/components/SlideChatContent.cjs +3 -2
  104. package/dist/FloatingChat/components/SlideChatContent.js +4 -3
  105. package/dist/FloatingChat/components/index.cjs +2 -0
  106. package/dist/FloatingChat/components/index.js +2 -0
  107. package/dist/FloatingChat/hooks/useProductResultsView.cjs +14 -1
  108. package/dist/FloatingChat/hooks/useProductResultsView.js +15 -2
  109. package/dist/FloatingChat/hooks/useSnapSetup.cjs +2 -2
  110. package/dist/FloatingChat/types/types.d.cts +4 -0
  111. package/dist/FloatingChat/types/types.d.ts +4 -0
  112. package/dist/FloatingChat/utils/functions.cjs +24 -16
  113. package/dist/FloatingChat/utils/functions.js +24 -17
  114. package/dist/FloatingChat/utils/trackProductCardInteraction.cjs +18 -0
  115. package/dist/FloatingChat/utils/trackProductCardInteraction.js +17 -0
  116. package/dist/Form/Form.cjs +1 -1
  117. package/dist/Form/Form.js +1 -1
  118. package/dist/Form/components/Layout.cjs +1 -1
  119. package/dist/Form/components/Layout.js +1 -1
  120. package/dist/Form/components/SubmitButtonItem.cjs +1 -1
  121. package/dist/Form/components/SubmitButtonItem.js +1 -1
  122. package/dist/Form/components/TextFieldItem.cjs +1 -1
  123. package/dist/Form/components/TextFieldItem.js +1 -1
  124. package/dist/FullPageSalesAgent/FullPageSalesAgent.cjs +30 -8
  125. package/dist/FullPageSalesAgent/FullPageSalesAgent.d.cts +2 -2
  126. package/dist/FullPageSalesAgent/FullPageSalesAgent.d.ts +2 -2
  127. package/dist/FullPageSalesAgent/FullPageSalesAgent.js +30 -8
  128. package/dist/FullPageSalesAgent/components/Layout.cjs +3 -2
  129. package/dist/FullPageSalesAgent/components/Layout.js +3 -2
  130. package/dist/FullPageSalesAgent/hooks/useIsMobile.cjs +2 -2
  131. package/dist/Image/Image.cjs +1 -1
  132. package/dist/Image/Image.d.cts +2 -2
  133. package/dist/Image/Image.d.ts +2 -2
  134. package/dist/Image/Image.js +1 -1
  135. package/dist/ImageGallery/ImageGallery.d.cts +2 -2
  136. package/dist/ImageGallery/ImageGallery.d.ts +2 -2
  137. package/dist/ImageGallery/components/Layout.cjs +4 -4
  138. package/dist/ImageGallery/components/Layout.js +2 -2
  139. package/dist/ImageGallery/utils/functions.cjs +1 -1
  140. package/dist/ImageGallery/utils/functions.js +1 -1
  141. package/dist/MarkdownProcessor/MarkdownProcessor.d.cts +2 -2
  142. package/dist/MarkdownProcessor/MarkdownProcessor.d.ts +2 -2
  143. package/dist/Message/components/Layout.cjs +1 -1
  144. package/dist/Message/components/Layout.js +1 -1
  145. package/dist/Message/components/LinkButton.cjs +1 -1
  146. package/dist/Message/components/LinkButton.js +1 -1
  147. package/dist/OrderLookupCard/OrderLookupCard.cjs +2 -2
  148. package/dist/OrderLookupCard/OrderLookupCard.js +2 -2
  149. package/dist/OrderLookupCard/components/Layout.cjs +1 -1
  150. package/dist/OrderLookupCard/components/Layout.js +1 -1
  151. package/dist/OrderLookupCard/components/MoreProductsOverlay.cjs +1 -1
  152. package/dist/OrderLookupCard/components/MoreProductsOverlay.js +1 -1
  153. package/dist/OrderLookupCard/components/ProductImageGridItem.cjs +1 -1
  154. package/dist/OrderLookupCard/components/ProductImageGridItem.js +1 -1
  155. package/dist/OrderLookupCard/components/ProductImageItem.cjs +1 -1
  156. package/dist/OrderLookupCard/components/ProductImageItem.js +1 -1
  157. package/dist/OrderLookupCard/components/ProductImagesGrid.cjs +1 -1
  158. package/dist/OrderLookupCard/components/ProductImagesGrid.js +1 -1
  159. package/dist/OrderLookupCard/components/StatusLabel.cjs +1 -1
  160. package/dist/OrderLookupCard/components/StatusLabel.js +1 -1
  161. package/dist/OrderLookupCard/components/TrackOrderLink.cjs +1 -1
  162. package/dist/OrderLookupCard/components/TrackOrderLink.js +1 -1
  163. package/dist/ProductCard/ProductCard.cjs +3 -3
  164. package/dist/ProductCard/ProductCard.d.cts +2 -2
  165. package/dist/ProductCard/ProductCard.d.ts +2 -2
  166. package/dist/ProductCard/ProductCard.js +3 -3
  167. package/dist/PromptButton/PromptButton.cjs +1 -1
  168. package/dist/PromptButton/PromptButton.d.cts +2 -2
  169. package/dist/PromptButton/PromptButton.d.ts +2 -2
  170. package/dist/PromptButton/PromptButton.js +1 -1
  171. package/dist/PromptButton/components/Layout.cjs +1 -1
  172. package/dist/PromptButton/components/Layout.js +1 -1
  173. package/dist/PromptButton/components/Loading.cjs +1 -1
  174. package/dist/PromptButton/components/Loading.js +1 -1
  175. package/dist/PromptButtonCarouselWithImage/PromptButtonCarouselWithImage.d.cts +2 -2
  176. package/dist/PromptButtonCarouselWithImage/PromptButtonCarouselWithImage.d.ts +2 -2
  177. package/dist/PromptButtonCarouselWithImage/components/Layout.cjs +3 -3
  178. package/dist/PromptButtonCarouselWithImage/components/Layout.js +1 -1
  179. package/dist/PromptButtonCarouselWithImage/components/PromptButtonsCarousel.cjs +3 -3
  180. package/dist/PromptButtonCarouselWithImage/components/PromptButtonsCarousel.js +1 -1
  181. package/dist/PromptButtonCarouselWithImage/components/Skeleton.cjs +1 -1
  182. package/dist/PromptButtonCarouselWithImage/components/Skeleton.js +1 -1
  183. package/dist/PromptCarousel/PromptCarousel.cjs +6 -6
  184. package/dist/PromptCarousel/PromptCarousel.d.cts +2 -2
  185. package/dist/PromptCarousel/PromptCarousel.js +4 -4
  186. package/dist/ReviewCard/ReviewCard.d.cts +2 -2
  187. package/dist/ReviewCard/ReviewCard.d.ts +2 -2
  188. package/dist/ReviewCard/components/Container.cjs +3 -3
  189. package/dist/ReviewCard/components/Container.js +3 -3
  190. package/dist/ReviewCard/components/Rating.cjs +1 -1
  191. package/dist/ReviewCard/components/Rating.js +1 -1
  192. package/dist/ReviewCard/components/ReadMoreButton.cjs +2 -2
  193. package/dist/ReviewCard/components/ReadMoreButton.js +2 -2
  194. package/dist/ReviewCard/components/index.d.cts +6 -6
  195. package/dist/ReviewCard/components/index.d.ts +4 -4
  196. package/dist/SalesAgentProductCard/SalesAgentProductCard.d.cts +2 -2
  197. package/dist/SalesAgentProductCard/components/Container.cjs +3 -3
  198. package/dist/SalesAgentProductCard/components/Container.js +3 -3
  199. package/dist/SalesAgentProductCard/components/ProductImage.cjs +1 -1
  200. package/dist/SalesAgentProductCard/components/ProductImage.js +1 -1
  201. package/dist/SalesAgentProductCard/components/ProductName.cjs +1 -1
  202. package/dist/SalesAgentProductCard/components/ProductName.js +1 -1
  203. package/dist/SalesAgentProductCard/components/index.d.cts +8 -8
  204. package/dist/SalesAgentProductCard/components/index.d.ts +2 -2
  205. package/dist/SocialProof/SocialProof.cjs +3 -3
  206. package/dist/SocialProof/SocialProof.d.cts +2 -2
  207. package/dist/SocialProof/SocialProof.d.ts +2 -2
  208. package/dist/SocialProof/SocialProof.js +1 -1
  209. package/dist/SocialProof/components/Headline.cjs +4 -4
  210. package/dist/SocialProof/components/Headline.js +4 -4
  211. package/dist/SocialProof/components/LayoutFourHorizontal.cjs +4 -4
  212. package/dist/SocialProof/components/LayoutFourHorizontal.js +2 -2
  213. package/dist/SocialProof/components/LayoutSingle.cjs +2 -2
  214. package/dist/SocialProof/components/Subheadline.cjs +1 -1
  215. package/dist/SocialProof/components/Subheadline.js +1 -1
  216. package/dist/SparkleAnimation/SparkleAnimation.d.cts +2 -2
  217. package/dist/SparkleAnimation/SparkleAnimation.d.ts +2 -2
  218. package/dist/Stack/Stack.d.cts +2 -2
  219. package/dist/TextField/TextField.cjs +1 -1
  220. package/dist/TextField/TextField.js +1 -1
  221. package/dist/TextField/components/Input.cjs +1 -1
  222. package/dist/TextField/components/Input.js +1 -1
  223. package/dist/TextField/components/Layout.cjs +1 -1
  224. package/dist/TextField/components/Layout.js +1 -1
  225. package/dist/TextField/components/SendIcon.cjs +1 -1
  226. package/dist/TextField/components/SendIcon.js +1 -1
  227. package/dist/Title/Title.cjs +1 -1
  228. package/dist/Title/Title.js +1 -1
  229. package/dist/Title/components/Layout.cjs +1 -1
  230. package/dist/Title/components/Layout.js +1 -1
  231. package/dist/TitledPromptCarousel/TitledPromptCarousel.cjs +2 -2
  232. package/dist/TitledPromptCarousel/TitledPromptCarousel.d.cts +2 -2
  233. package/dist/TitledPromptCarousel/TitledPromptCarousel.d.ts +2 -2
  234. package/dist/TitledPromptCarousel/TitledPromptCarousel.js +2 -2
  235. package/dist/Tokens/index.cjs +2 -2
  236. package/dist/Tokens/index.js +2 -2
  237. package/dist/TypingAnimation/TypingAnimation.cjs +1 -1
  238. package/dist/TypingAnimation/TypingAnimation.d.cts +2 -2
  239. package/dist/TypingAnimation/TypingAnimation.d.ts +2 -2
  240. package/dist/TypingAnimation/TypingAnimation.js +1 -1
  241. package/dist/TypingAnimation/hooks/useGetTypographyVariant.cjs +1 -1
  242. package/dist/TypingAnimation/hooks/useGetTypographyVariant.js +1 -1
  243. package/dist/Typography/Typography.d.cts +4 -4
  244. package/dist/Typography/Typography.d.ts +4 -4
  245. package/dist/WelcomeMessage/components/Container.cjs +3 -3
  246. package/dist/WelcomeMessage/components/Container.js +3 -3
  247. package/dist/WidgetTextField/WidgetTextField.cjs +1 -1
  248. package/dist/WidgetTextField/WidgetTextField.js +1 -1
  249. package/dist/WidgetTextField/components/Container.cjs +3 -3
  250. package/dist/WidgetTextField/components/Container.js +3 -3
  251. package/dist/WidgetTextField/components/Icon.cjs +1 -1
  252. package/dist/WidgetTextField/components/Icon.js +1 -1
  253. package/dist/WidgetTextField/components/Skeleton.cjs +1 -1
  254. package/dist/WidgetTextField/components/Skeleton.js +1 -1
  255. package/dist/WidgetWrapper/WidgetWrapper.cjs +1 -1
  256. package/dist/WidgetWrapper/WidgetWrapper.d.cts +2 -2
  257. package/dist/WidgetWrapper/WidgetWrapper.d.ts +2 -2
  258. package/dist/WidgetWrapper/WidgetWrapper.js +1 -1
  259. package/dist/WidgetWrapperWithTitle/WidgetWrapperWithTitle.d.cts +2 -2
  260. package/dist/styles.css +1 -1
  261. package/dist/utils/resolveTheme.cjs +1 -1
  262. package/dist/utils/resolveTheme.js +1 -1
  263. package/dist/utils/useCheckIsMobile.d.cts +9 -0
  264. package/dist/utils/useCheckIsMobile.d.ts +9 -0
  265. package/package.json +5 -1
  266. package/src/components/FloatingChat/FloatingChat.tsx +35 -34
  267. package/src/components/FloatingChat/components/AgentMessage.tsx +2 -12
  268. package/src/components/FloatingChat/components/ProductResultsModal.tsx +87 -0
  269. package/src/components/FloatingChat/components/ResultsGridView.tsx +26 -2
  270. package/src/components/FloatingChat/components/SlideChatContent.tsx +9 -1
  271. package/src/components/FloatingChat/components/index.ts +2 -0
  272. package/src/components/FloatingChat/hooks/useProductResultsView.ts +26 -2
  273. package/src/components/FloatingChat/types/types.ts +4 -0
  274. package/src/components/FloatingChat/utils/functions.ts +34 -19
  275. package/src/components/FloatingChat/utils/trackProductCardInteraction.ts +26 -0
  276. package/src/components/FullPageSalesAgent/FullPageSalesAgent.tsx +54 -5
  277. package/src/components/FullPageSalesAgent/components/Layout.tsx +7 -1
@@ -1,6 +1,6 @@
1
1
  import { getComputedCSSVariable } from "./utils.js";
2
- import { jsx, jsxs } from "react/jsx-runtime";
3
2
  import classNames from "classnames";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/DesignTokens/components/FontSize.tsx
6
6
  const FontSize = ({ fontSizeTokens }) => {
@@ -1,8 +1,8 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_utils = require('./utils.cjs');
3
- let react_jsx_runtime = require("react/jsx-runtime");
4
3
  let classnames = require("classnames");
5
4
  classnames = require_rolldown_runtime.__toESM(classnames);
5
+ let react_jsx_runtime = require("react/jsx-runtime");
6
6
 
7
7
  //#region src/components/DesignTokens/components/FontWeight.tsx
8
8
  const FontWeight = ({ fontWeightTokens }) => {
@@ -1,6 +1,6 @@
1
1
  import { getComputedCSSVariable } from "./utils.js";
2
- import { jsx, jsxs } from "react/jsx-runtime";
3
2
  import classNames from "classnames";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/DesignTokens/components/FontWeight.tsx
6
6
  const FontWeight = ({ fontWeightTokens }) => {
@@ -1,8 +1,8 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_utils = require('./utils.cjs');
3
- let react_jsx_runtime = require("react/jsx-runtime");
4
3
  let classnames = require("classnames");
5
4
  classnames = require_rolldown_runtime.__toESM(classnames);
5
+ let react_jsx_runtime = require("react/jsx-runtime");
6
6
 
7
7
  //#region src/components/DesignTokens/components/LetterSpacing.tsx
8
8
  const LetterSpacing = ({ letterSpacingTokens }) => {
@@ -1,6 +1,6 @@
1
1
  import { getComputedCSSVariable } from "./utils.js";
2
- import { jsx, jsxs } from "react/jsx-runtime";
3
2
  import classNames from "classnames";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/DesignTokens/components/LetterSpacing.tsx
6
6
  const LetterSpacing = ({ letterSpacingTokens }) => {
@@ -1,8 +1,8 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_utils = require('./utils.cjs');
3
- let react_jsx_runtime = require("react/jsx-runtime");
4
3
  let classnames = require("classnames");
5
4
  classnames = require_rolldown_runtime.__toESM(classnames);
5
+ let react_jsx_runtime = require("react/jsx-runtime");
6
6
 
7
7
  //#region src/components/DesignTokens/components/LineHeight.tsx
8
8
  const LineHeight = ({ lineHeightTokens }) => {
@@ -1,6 +1,6 @@
1
1
  import { getComputedCSSVariable } from "./utils.js";
2
- import { jsx, jsxs } from "react/jsx-runtime";
3
2
  import classNames from "classnames";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/DesignTokens/components/LineHeight.tsx
6
6
  const LineHeight = ({ lineHeightTokens }) => {
@@ -1,7 +1,7 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
- let react_jsx_runtime = require("react/jsx-runtime");
3
2
  let classnames = require("classnames");
4
3
  classnames = require_rolldown_runtime.__toESM(classnames);
4
+ let react_jsx_runtime = require("react/jsx-runtime");
5
5
 
6
6
  //#region src/components/DesignTokens/components/Typography.tsx
7
7
  const Typography = () => {
@@ -1,5 +1,5 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
2
1
  import classNames from "classnames";
2
+ import { jsx, jsxs } from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/DesignTokens/components/Typography.tsx
5
5
  const Typography = () => {
@@ -1,11 +1,11 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
- const require_Container = require('../../Container/Container.cjs');
3
- require('../../Container/index.cjs');
4
2
  const require_Stack = require('../../Stack/Stack.cjs');
5
3
  require('../../Stack/index.cjs');
6
- let react_jsx_runtime = require("react/jsx-runtime");
4
+ const require_Container = require('../../Container/Container.cjs');
5
+ require('../../Container/index.cjs');
7
6
  let classnames = require("classnames");
8
7
  classnames = require_rolldown_runtime.__toESM(classnames);
8
+ let react_jsx_runtime = require("react/jsx-runtime");
9
9
 
10
10
  //#region src/components/Disclaimer/components/Container.tsx
11
11
  const Container$1 = ({ markdownNode, id, testId, className, style }) => {
@@ -1,9 +1,9 @@
1
- import { Container } from "../../Container/Container.js";
2
- import "../../Container/index.js";
3
1
  import { Stack } from "../../Stack/Stack.js";
4
2
  import "../../Stack/index.js";
5
- import { jsx } from "react/jsx-runtime";
3
+ import { Container } from "../../Container/Container.js";
4
+ import "../../Container/index.js";
6
5
  import classNames from "classnames";
6
+ import { jsx } from "react/jsx-runtime";
7
7
 
8
8
  //#region src/components/Disclaimer/components/Container.tsx
9
9
  const Container$1 = ({ markdownNode, id, testId, className, style }) => {
@@ -1,5 +1,5 @@
1
1
  import { DocumentRetrievalCardProps } from "./types/index.cjs";
2
- import * as react_jsx_runtime28 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime26 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/DocumentRetrievalCard/DocumentRetrievalCard.d.ts
5
5
  declare const DocumentRetrievalCard: ({
@@ -16,6 +16,6 @@ declare const DocumentRetrievalCard: ({
16
16
  onViewArticle,
17
17
  ariaLabel,
18
18
  viewArticleLabel
19
- }: DocumentRetrievalCardProps) => react_jsx_runtime28.JSX.Element;
19
+ }: DocumentRetrievalCardProps) => react_jsx_runtime26.JSX.Element;
20
20
  //#endregion
21
21
  export { DocumentRetrievalCard };
@@ -1,5 +1,5 @@
1
1
  import { DocumentRetrievalCardProps } from "./types/index.js";
2
- import * as react_jsx_runtime26 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime24 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/DocumentRetrievalCard/DocumentRetrievalCard.d.ts
5
5
  declare const DocumentRetrievalCard: ({
@@ -16,6 +16,6 @@ declare const DocumentRetrievalCard: ({
16
16
  onViewArticle,
17
17
  ariaLabel,
18
18
  viewArticleLabel
19
- }: DocumentRetrievalCardProps) => react_jsx_runtime26.JSX.Element;
19
+ }: DocumentRetrievalCardProps) => react_jsx_runtime24.JSX.Element;
20
20
  //#endregion
21
21
  export { DocumentRetrievalCard };
@@ -2,9 +2,9 @@ const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_index = require('../../Image/types/index.cjs');
3
3
  const require_Image = require('../../Image/Image.cjs');
4
4
  require('../../Image/index.cjs');
5
- let react_jsx_runtime = require("react/jsx-runtime");
6
5
  let classnames = require("classnames");
7
6
  classnames = require_rolldown_runtime.__toESM(classnames);
7
+ let react_jsx_runtime = require("react/jsx-runtime");
8
8
 
9
9
  //#region src/components/DocumentRetrievalCard/components/Image.tsx
10
10
  const Image$1 = ({ imageUrl, imageAlt, className }) => {
@@ -1,8 +1,8 @@
1
1
  import { ImageAspectRatio } from "../../Image/types/index.js";
2
2
  import { Image } from "../../Image/Image.js";
3
3
  import "../../Image/index.js";
4
- import { jsx } from "react/jsx-runtime";
5
4
  import classNames from "classnames";
5
+ import { jsx } from "react/jsx-runtime";
6
6
 
7
7
  //#region src/components/DocumentRetrievalCard/components/Image.tsx
8
8
  const Image$1 = ({ imageUrl, imageAlt, className }) => {
@@ -1,15 +1,15 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
- const require_Container = require('../../Container/Container.cjs');
3
- require('../../Container/index.cjs');
4
2
  const require_Stack = require('../../Stack/Stack.cjs');
5
3
  require('../../Stack/index.cjs');
4
+ const require_Container = require('../../Container/Container.cjs');
5
+ require('../../Container/index.cjs');
6
6
  const require_useGetThemeProperties = require('../hooks/useGetThemeProperties.cjs');
7
7
  const require_useGetStackLayoutProperties = require('../hooks/useGetStackLayoutProperties.cjs');
8
8
  const require_useGetCardWidthProperties = require('../hooks/useGetCardWidthProperties.cjs');
9
9
  const require_useGetPaddingProperties = require('../hooks/useGetPaddingProperties.cjs');
10
- let react_jsx_runtime = require("react/jsx-runtime");
11
10
  let classnames = require("classnames");
12
11
  classnames = require_rolldown_runtime.__toESM(classnames);
12
+ let react_jsx_runtime = require("react/jsx-runtime");
13
13
 
14
14
  //#region src/components/DocumentRetrievalCard/components/Layout.tsx
15
15
  const Layout = ({ content, image, viewArticleButton, id, testId, className, style, theme, ariaLabel }) => {
@@ -1,13 +1,13 @@
1
- import { Container } from "../../Container/Container.js";
2
- import "../../Container/index.js";
3
1
  import { Stack } from "../../Stack/Stack.js";
4
2
  import "../../Stack/index.js";
3
+ import { Container } from "../../Container/Container.js";
4
+ import "../../Container/index.js";
5
5
  import { useGetThemeProperties } from "../hooks/useGetThemeProperties.js";
6
6
  import { useGetStackLayoutProperties } from "../hooks/useGetStackLayoutProperties.js";
7
7
  import { useGetCardWidthProperties } from "../hooks/useGetCardWidthProperties.js";
8
8
  import { useGetPaddingProperties } from "../hooks/useGetPaddingProperties.js";
9
- import { jsx, jsxs } from "react/jsx-runtime";
10
9
  import classNames from "classnames";
10
+ import { jsx, jsxs } from "react/jsx-runtime";
11
11
 
12
12
  //#region src/components/DocumentRetrievalCard/components/Layout.tsx
13
13
  const Layout = ({ content, image, viewArticleButton, id, testId, className, style, theme, ariaLabel }) => {
@@ -1,10 +1,10 @@
1
1
  const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
- const require_CustomIcon = require('../../../../utils/CustomIcon.cjs');
3
2
  const require_Stack = require('../../../../Stack/Stack.cjs');
4
3
  require('../../../../Stack/index.cjs');
5
- let react_jsx_runtime = require("react/jsx-runtime");
4
+ const require_CustomIcon = require('../../../../utils/CustomIcon.cjs');
6
5
  let classnames = require("classnames");
7
6
  classnames = require_rolldown_runtime.__toESM(classnames);
7
+ let react_jsx_runtime = require("react/jsx-runtime");
8
8
  let __envive_ai_react_icons_Document = require("@envive-ai/react-icons/Document");
9
9
  __envive_ai_react_icons_Document = require_rolldown_runtime.__toESM(__envive_ai_react_icons_Document);
10
10
 
@@ -1,8 +1,8 @@
1
- import { CustomIcon } from "../../../../utils/CustomIcon.js";
2
1
  import { Stack } from "../../../../Stack/Stack.js";
3
2
  import "../../../../Stack/index.js";
4
- import { jsx } from "react/jsx-runtime";
3
+ import { CustomIcon } from "../../../../utils/CustomIcon.js";
5
4
  import classNames from "classnames";
5
+ import { jsx } from "react/jsx-runtime";
6
6
  import Document from "@envive-ai/react-icons/Document";
7
7
 
8
8
  //#region src/components/DocumentRetrievalCard/components/ViewArticleButton/components/Icon.tsx
@@ -5,9 +5,9 @@ const require_index = require('../../../../Typography/types/index.cjs');
5
5
  const require_Typography = require('../../../../Typography/Typography.cjs');
6
6
  require('../../../../Typography/index.cjs');
7
7
  const require_useGetLabelUnderlineProperties = require('../../../hooks/useGetLabelUnderlineProperties.cjs');
8
- let react_jsx_runtime = require("react/jsx-runtime");
9
8
  let classnames = require("classnames");
10
9
  classnames = require_rolldown_runtime.__toESM(classnames);
10
+ let react_jsx_runtime = require("react/jsx-runtime");
11
11
 
12
12
  //#region src/components/DocumentRetrievalCard/components/ViewArticleButton/components/Label.tsx
13
13
  const Label = ({ viewArticleLabel, typographyVariant, shouldUnderline = false, textCaseClassName }) => {
@@ -4,8 +4,8 @@ import { TypographyColor } from "../../../../Typography/types/index.js";
4
4
  import { Typography } from "../../../../Typography/Typography.js";
5
5
  import "../../../../Typography/index.js";
6
6
  import { useGetLabelUnderlineProperties } from "../../../hooks/useGetLabelUnderlineProperties.js";
7
- import { jsx } from "react/jsx-runtime";
8
7
  import classNames from "classnames";
8
+ import { jsx } from "react/jsx-runtime";
9
9
 
10
10
  //#region src/components/DocumentRetrievalCard/components/ViewArticleButton/components/Label.tsx
11
11
  const Label = ({ viewArticleLabel, typographyVariant, shouldUnderline = false, textCaseClassName }) => {
@@ -1,9 +1,9 @@
1
1
  const require_rolldown_runtime = require('../../../../_virtual/rolldown_runtime.cjs');
2
2
  const require_Stack = require('../../../../Stack/Stack.cjs');
3
3
  require('../../../../Stack/index.cjs');
4
- let react_jsx_runtime = require("react/jsx-runtime");
5
4
  let classnames = require("classnames");
6
5
  classnames = require_rolldown_runtime.__toESM(classnames);
6
+ let react_jsx_runtime = require("react/jsx-runtime");
7
7
 
8
8
  //#region src/components/DocumentRetrievalCard/components/ViewArticleButton/components/Layout.tsx
9
9
  const Layout = ({ icon, label, onClick, className, ariaLabel }) => {
@@ -1,7 +1,7 @@
1
1
  import { Stack } from "../../../../Stack/Stack.js";
2
2
  import "../../../../Stack/index.js";
3
- import { jsx, jsxs } from "react/jsx-runtime";
4
3
  import classNames from "classnames";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
5
 
6
6
  //#region src/components/DocumentRetrievalCard/components/ViewArticleButton/components/Layout.tsx
7
7
  const Layout = ({ icon, label, onClick, className, ariaLabel }) => {
@@ -1,5 +1,5 @@
1
1
  import { FloatingButtonProps } from "./types/types.cjs";
2
- import * as react_jsx_runtime17 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime24 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/FloatingButton/FloatingButton.d.ts
5
5
  declare const FloatingButton: ({
@@ -18,6 +18,6 @@ declare const FloatingButton: ({
18
18
  onMouseOver,
19
19
  ariaLabel,
20
20
  previewMode
21
- }: FloatingButtonProps) => react_jsx_runtime17.JSX.Element;
21
+ }: FloatingButtonProps) => react_jsx_runtime24.JSX.Element;
22
22
  //#endregion
23
23
  export { FloatingButton };
@@ -1,5 +1,5 @@
1
1
  import { FloatingButtonProps } from "./types/types.js";
2
- import * as react_jsx_runtime35 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime31 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/FloatingButton/FloatingButton.d.ts
5
5
  declare const FloatingButton: ({
@@ -18,6 +18,6 @@ declare const FloatingButton: ({
18
18
  onMouseOver,
19
19
  ariaLabel,
20
20
  previewMode
21
- }: FloatingButtonProps) => react_jsx_runtime35.JSX.Element;
21
+ }: FloatingButtonProps) => react_jsx_runtime31.JSX.Element;
22
22
  //#endregion
23
23
  export { FloatingButton };
@@ -2,9 +2,9 @@ const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_types = require('../types/types.cjs');
3
3
  const require_useGetButtonHoverProperties = require('../hooks/useGetButtonHoverProperties.cjs');
4
4
  const require_useGetButtonProperties = require('../hooks/useGetButtonProperties.cjs');
5
- let react_jsx_runtime = require("react/jsx-runtime");
6
5
  let classnames = require("classnames");
7
6
  classnames = require_rolldown_runtime.__toESM(classnames);
7
+ let react_jsx_runtime = require("react/jsx-runtime");
8
8
 
9
9
  //#region src/components/FloatingButton/components/Button.tsx
10
10
  const Button = ({ variant = require_types.FloatingButtonVariant.ATTACHED, mode = require_types.FloatingButtonMode.LIGHT, backgroundColor, onClick, onMouseOver, onFocus, children, className = "", ariaLabel }) => {
@@ -1,8 +1,8 @@
1
1
  import { FloatingButtonMode, FloatingButtonVariant } from "../types/types.js";
2
2
  import { useGetButtonHoverProperties } from "../hooks/useGetButtonHoverProperties.js";
3
3
  import { useGetButtonProperties } from "../hooks/useGetButtonProperties.js";
4
- import { jsx } from "react/jsx-runtime";
5
4
  import classNames from "classnames";
5
+ import { jsx } from "react/jsx-runtime";
6
6
 
7
7
  //#region src/components/FloatingButton/components/Button.tsx
8
8
  const Button = ({ variant = FloatingButtonVariant.ATTACHED, mode = FloatingButtonMode.LIGHT, backgroundColor, onClick, onMouseOver, onFocus, children, className = "", ariaLabel }) => {
@@ -1,9 +1,9 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_types = require('../types/types.cjs');
3
3
  const require_useGetContainerProperties = require('../hooks/useGetContainerProperties.cjs');
4
- let react_jsx_runtime = require("react/jsx-runtime");
5
4
  let classnames = require("classnames");
6
5
  classnames = require_rolldown_runtime.__toESM(classnames);
6
+ let react_jsx_runtime = require("react/jsx-runtime");
7
7
 
8
8
  //#region src/components/FloatingButton/components/Container.tsx
9
9
  const Container = ({ location = require_types.FloatingButtonLocation.BOTTOM_RIGHT, show = require_types.FloatingButtonShow.ALWAYS, variant = require_types.FloatingButtonVariant.ATTACHED, hasInteractionHappened = false, children, id, testId, className = "", style, previewMode = false }) => {
@@ -1,7 +1,7 @@
1
1
  import { FloatingButtonLocation, FloatingButtonShow, FloatingButtonVariant } from "../types/types.js";
2
2
  import { useGetContainerProperties } from "../hooks/useGetContainerProperties.js";
3
- import { jsx } from "react/jsx-runtime";
4
3
  import classNames from "classnames";
4
+ import { jsx } from "react/jsx-runtime";
5
5
 
6
6
  //#region src/components/FloatingButton/components/Container.tsx
7
7
  const Container = ({ location = FloatingButtonLocation.BOTTOM_RIGHT, show = FloatingButtonShow.ALWAYS, variant = FloatingButtonVariant.ATTACHED, hasInteractionHappened = false, children, id, testId, className = "", style, previewMode = false }) => {
@@ -1,9 +1,9 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_types = require('../types/types.cjs');
3
3
  const require_useGetWrapperProperties = require('../hooks/useGetWrapperProperties.cjs');
4
- let react_jsx_runtime = require("react/jsx-runtime");
5
4
  let classnames = require("classnames");
6
5
  classnames = require_rolldown_runtime.__toESM(classnames);
6
+ let react_jsx_runtime = require("react/jsx-runtime");
7
7
 
8
8
  //#region src/components/FloatingButton/components/Wrapper.tsx
9
9
  const Wrapper = ({ location = require_types.FloatingButtonLocation.BOTTOM_RIGHT, children, className = "" }) => {
@@ -1,7 +1,7 @@
1
1
  import { FloatingButtonLocation } from "../types/types.js";
2
2
  import { useGetWrapperProperties } from "../hooks/useGetWrapperProperties.js";
3
- import { jsx } from "react/jsx-runtime";
4
3
  import classNames from "classnames";
4
+ import { jsx } from "react/jsx-runtime";
5
5
 
6
6
  //#region src/components/FloatingButton/components/Wrapper.tsx
7
7
  const Wrapper = ({ location = FloatingButtonLocation.BOTTOM_RIGHT, children, className = "" }) => {
@@ -21,7 +21,7 @@ const require_useScrollToBottom = require('./hooks/useScrollToBottom.cjs');
21
21
  const require_useSnapSetup = require('./hooks/useSnapSetup.cjs');
22
22
  const require_useFilteredChatMessages = require('./hooks/useFilteredChatMessages.cjs');
23
23
  const require_useSnapCalculator = require('./hooks/useSnapCalculator.cjs');
24
- const require_functions = require('./utils/functions.cjs');
24
+ const require_trackProductCardInteraction = require('./utils/trackProductCardInteraction.cjs');
25
25
  const require_ModalSheet = require('./components/ModalSheet.cjs');
26
26
  const require_index$1 = require('./components/index.cjs');
27
27
  let react = require("react");
@@ -33,7 +33,7 @@ let framer_motion = require("framer-motion");
33
33
  let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
34
34
 
35
35
  //#region src/components/FloatingChat/FloatingChat.tsx
36
- const FloatingChat = ({ id, className, style, testId, theme = require_theme.Theme.GLOBAL_CUSTOM, salesAgentData, floatingChatConfig, hardcopyContent, lookAndFeelConfig, isCXButtonSwitchEnabled, isFloatingChatOpen, debugBar, onClose, onSwipeClose, onToggleCXButton }) => {
36
+ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Theme.GLOBAL_CUSTOM, salesAgentData, floatingChatConfig, hardcopyContent, lookAndFeelConfig, isCXButtonSwitchEnabled, isFloatingChatOpen, debugBar, onClose, onSwipeClose, onToggleCXButton, setIsResultsModalOpen }) => {
37
37
  const finalTheme = require_resolveTheme.resolveTheme(theme);
38
38
  const { trackWidgetInteraction } = (0, __envive_ai_react_hooks_hooks_WidgetInteraction.useWidgetInteraction)();
39
39
  const { onDrag, onHover, onMouseDown, onMouseUp, onTouchStart, onTouchEnd } = require_usePromptCarouselAnalytics.usePromptCarouselAnalytics(__envive_ai_react_hooks_hooks_WidgetInteraction_types.WidgetInteractionComponent.FLOATING_CHAT, (text) => text);
@@ -76,7 +76,15 @@ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Them
76
76
  footerHeight: 160,
77
77
  isOpen: isFloatingChatOpen
78
78
  });
79
- const { resultsViewData, setResultsViewData, isResultsView, scrollContainerRef, isResultsViewRef, handleBackToChat } = require_useProductResultsView.useProductResultsView({ scrollToBottom });
79
+ const { resultsViewData, isResultsView, scrollContainerRef, isResultsViewRef, handleBackToChat, handleExploreAllResults } = require_useProductResultsView.useProductResultsView({ scrollToBottom });
80
+ (0, react.useEffect)(() => {
81
+ setIsResultsModalOpen?.(!isMobile && isResultsView && resultsViewData !== null);
82
+ }, [
83
+ isMobile,
84
+ isResultsView,
85
+ resultsViewData,
86
+ setIsResultsModalOpen
87
+ ]);
80
88
  (0, react.useEffect)(() => {
81
89
  if (isFloatingChatOpen) trackWidgetInteraction({
82
90
  eventName: __envive_ai_react_hooks_contexts_amplitudeContext.EnviveMetricsEventName.WidgetInteraction,
@@ -112,14 +120,7 @@ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Them
112
120
  modalSheetControl
113
121
  });
114
122
  const handleProductCardClick = (product) => {
115
- trackWidgetInteraction({
116
- eventName: __envive_ai_react_hooks_contexts_amplitudeContext.EnviveMetricsEventName.WidgetInteraction,
117
- trigger: {
118
- widget: __envive_ai_react_hooks_hooks_WidgetInteraction_types.WidgetInteractionComponent.FLOATING_CHAT,
119
- widget_interaction: __envive_ai_react_hooks_hooks_WidgetInteraction_types.WidgetInteractionType.PRODUCT_CARD_CLICKED,
120
- widget_interaction_data: { product_card_clicked: { product_id: product.id } }
121
- }
122
- });
123
+ require_trackProductCardInteraction.trackProductCardClicked(trackWidgetInteraction, __envive_ai_react_hooks_hooks_WidgetInteraction_types.WidgetInteractionComponent.FLOATING_CHAT, product);
123
124
  };
124
125
  const header = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ChatHeader.ChatHeader, {
125
126
  logoDark: chatHeaderLogoDarkSrc,
@@ -206,16 +207,6 @@ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Them
206
207
  text: welcomeMessageText,
207
208
  theme: finalTheme
208
209
  });
209
- const handleExploreAllResults = (firstProductMessageId) => {
210
- const blockIndex = messages.findIndex((block) => block.some((msg) => msg.type === __envive_ai_react_hooks_application_models.MessageType.Product && msg.id === firstProductMessageId));
211
- if (blockIndex < 0) return;
212
- const products = require_functions.getCleanProducts(messages[blockIndex].filter((msg) => msg.type === __envive_ai_react_hooks_application_models.MessageType.Product));
213
- if (products.length === 0) return;
214
- setResultsViewData({
215
- products,
216
- searchQuery: require_functions.getSearchQueryFromMessageBlock(messages, blockIndex)
217
- });
218
- };
219
210
  const chatMessages = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index$1.FloatingChatComponents.ChatMessages, {
220
211
  theme: finalTheme,
221
212
  ref: chatMessagesRef,
@@ -230,7 +221,7 @@ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Them
230
221
  showVerifiedBuyer,
231
222
  onFormResponseSubmitted,
232
223
  parentWidget: __envive_ai_react_hooks_hooks_WidgetInteraction_types.WidgetInteractionComponent.FLOATING_CHAT,
233
- onExploreAllResults: handleExploreAllResults
224
+ onExploreAllResults: (firstProductMessageId) => handleExploreAllResults(firstProductMessageId, filteredMessages)
234
225
  });
235
226
  const middleContent = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index$1.FloatingChatComponents.SlideChatContent, {
236
227
  isResultsView,
@@ -293,6 +284,18 @@ const FloatingChat = ({ id, className, style, testId, theme = require_theme.Them
293
284
  isFloatingFooterLayout: isFloatingLayout,
294
285
  scrollContainerRef
295
286
  });
287
+ if (!isMobile && isResultsView && resultsViewData) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index$1.FloatingChatComponents.ProductResultsModal, {
288
+ theme: finalTheme,
289
+ resultsViewData,
290
+ onBackToChat: handleBackToChat,
291
+ onProductCardClick: handleProductCardClick,
292
+ onClose,
293
+ logoDark: chatHeaderLogoDarkSrc,
294
+ logoLight: chatHeaderLogoLightSrc,
295
+ headerBgColor: headerBackgroundColor,
296
+ headerMode,
297
+ footer
298
+ });
296
299
  return isMobile ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ModalSheet.ModalSheet, {
297
300
  animationKey,
298
301
  open: isOpen,
@@ -1,5 +1,5 @@
1
1
  import { FloatingChatProps } from "./types/types.cjs";
2
- import * as react_jsx_runtime29 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime21 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/FloatingChat/FloatingChat.d.ts
5
5
  declare const FloatingChat: ({
@@ -17,7 +17,8 @@ declare const FloatingChat: ({
17
17
  debugBar,
18
18
  onClose,
19
19
  onSwipeClose,
20
- onToggleCXButton
21
- }: FloatingChatProps) => react_jsx_runtime29.JSX.Element;
20
+ onToggleCXButton,
21
+ setIsResultsModalOpen
22
+ }: FloatingChatProps) => react_jsx_runtime21.JSX.Element;
22
23
  //#endregion
23
24
  export { FloatingChat };
@@ -1,5 +1,5 @@
1
1
  import { FloatingChatProps } from "./types/types.js";
2
- import * as react_jsx_runtime25 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime22 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/FloatingChat/FloatingChat.d.ts
5
5
  declare const FloatingChat: ({
@@ -17,7 +17,8 @@ declare const FloatingChat: ({
17
17
  debugBar,
18
18
  onClose,
19
19
  onSwipeClose,
20
- onToggleCXButton
21
- }: FloatingChatProps) => react_jsx_runtime25.JSX.Element;
20
+ onToggleCXButton,
21
+ setIsResultsModalOpen
22
+ }: FloatingChatProps) => react_jsx_runtime22.JSX.Element;
22
23
  //#endregion
23
24
  export { FloatingChat };
@@ -20,7 +20,7 @@ import { useScrollToBottom } from "./hooks/useScrollToBottom.js";
20
20
  import { useSnapSetup } from "./hooks/useSnapSetup.js";
21
21
  import { useFilteredChatMessages } from "./hooks/useFilteredChatMessages.js";
22
22
  import { Unit } from "./hooks/useSnapCalculator.js";
23
- import { getCleanProducts, getSearchQueryFromMessageBlock } from "./utils/functions.js";
23
+ import { trackProductCardClicked } from "./utils/trackProductCardInteraction.js";
24
24
  import { ModalSheet } from "./components/ModalSheet.js";
25
25
  import { FloatingChatComponents } from "./components/index.js";
26
26
  import { useEffect, useMemo, useRef, useState } from "react";
@@ -29,10 +29,10 @@ import { EnviveMetricsEventName } from "@envive-ai/react-hooks/contexts/amplitud
29
29
  import { useWidgetInteraction } from "@envive-ai/react-hooks/hooks/WidgetInteraction";
30
30
  import { WidgetInteractionComponent, WidgetInteractionType } from "@envive-ai/react-hooks/hooks/WidgetInteraction/types";
31
31
  import { motion } from "framer-motion";
32
- import { ChatElementDisplayLocationV3, MessageType } from "@envive-ai/react-hooks/application/models";
32
+ import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
33
33
 
34
34
  //#region src/components/FloatingChat/FloatingChat.tsx
35
- const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTOM, salesAgentData, floatingChatConfig, hardcopyContent, lookAndFeelConfig, isCXButtonSwitchEnabled, isFloatingChatOpen, debugBar, onClose, onSwipeClose, onToggleCXButton }) => {
35
+ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTOM, salesAgentData, floatingChatConfig, hardcopyContent, lookAndFeelConfig, isCXButtonSwitchEnabled, isFloatingChatOpen, debugBar, onClose, onSwipeClose, onToggleCXButton, setIsResultsModalOpen }) => {
36
36
  const finalTheme = resolveTheme(theme);
37
37
  const { trackWidgetInteraction } = useWidgetInteraction();
38
38
  const { onDrag, onHover, onMouseDown, onMouseUp, onTouchStart, onTouchEnd } = usePromptCarouselAnalytics(WidgetInteractionComponent.FLOATING_CHAT, (text) => text);
@@ -75,7 +75,15 @@ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTO
75
75
  footerHeight: 160,
76
76
  isOpen: isFloatingChatOpen
77
77
  });
78
- const { resultsViewData, setResultsViewData, isResultsView, scrollContainerRef, isResultsViewRef, handleBackToChat } = useProductResultsView({ scrollToBottom });
78
+ const { resultsViewData, isResultsView, scrollContainerRef, isResultsViewRef, handleBackToChat, handleExploreAllResults } = useProductResultsView({ scrollToBottom });
79
+ useEffect(() => {
80
+ setIsResultsModalOpen?.(!isMobile && isResultsView && resultsViewData !== null);
81
+ }, [
82
+ isMobile,
83
+ isResultsView,
84
+ resultsViewData,
85
+ setIsResultsModalOpen
86
+ ]);
79
87
  useEffect(() => {
80
88
  if (isFloatingChatOpen) trackWidgetInteraction({
81
89
  eventName: EnviveMetricsEventName.WidgetInteraction,
@@ -111,14 +119,7 @@ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTO
111
119
  modalSheetControl
112
120
  });
113
121
  const handleProductCardClick = (product) => {
114
- trackWidgetInteraction({
115
- eventName: EnviveMetricsEventName.WidgetInteraction,
116
- trigger: {
117
- widget: WidgetInteractionComponent.FLOATING_CHAT,
118
- widget_interaction: WidgetInteractionType.PRODUCT_CARD_CLICKED,
119
- widget_interaction_data: { product_card_clicked: { product_id: product.id } }
120
- }
121
- });
122
+ trackProductCardClicked(trackWidgetInteraction, WidgetInteractionComponent.FLOATING_CHAT, product);
122
123
  };
123
124
  const header = /* @__PURE__ */ jsx(ChatHeader, {
124
125
  logoDark: chatHeaderLogoDarkSrc,
@@ -205,16 +206,6 @@ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTO
205
206
  text: welcomeMessageText,
206
207
  theme: finalTheme
207
208
  });
208
- const handleExploreAllResults = (firstProductMessageId) => {
209
- const blockIndex = messages.findIndex((block) => block.some((msg) => msg.type === MessageType.Product && msg.id === firstProductMessageId));
210
- if (blockIndex < 0) return;
211
- const products = getCleanProducts(messages[blockIndex].filter((msg) => msg.type === MessageType.Product));
212
- if (products.length === 0) return;
213
- setResultsViewData({
214
- products,
215
- searchQuery: getSearchQueryFromMessageBlock(messages, blockIndex)
216
- });
217
- };
218
209
  const chatMessages = /* @__PURE__ */ jsx(FloatingChatComponents.ChatMessages, {
219
210
  theme: finalTheme,
220
211
  ref: chatMessagesRef,
@@ -229,7 +220,7 @@ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTO
229
220
  showVerifiedBuyer,
230
221
  onFormResponseSubmitted,
231
222
  parentWidget: WidgetInteractionComponent.FLOATING_CHAT,
232
- onExploreAllResults: handleExploreAllResults
223
+ onExploreAllResults: (firstProductMessageId) => handleExploreAllResults(firstProductMessageId, filteredMessages)
233
224
  });
234
225
  const middleContent = /* @__PURE__ */ jsx(FloatingChatComponents.SlideChatContent, {
235
226
  isResultsView,
@@ -292,6 +283,18 @@ const FloatingChat = ({ id, className, style, testId, theme = Theme.GLOBAL_CUSTO
292
283
  isFloatingFooterLayout: isFloatingLayout,
293
284
  scrollContainerRef
294
285
  });
286
+ if (!isMobile && isResultsView && resultsViewData) return /* @__PURE__ */ jsx(FloatingChatComponents.ProductResultsModal, {
287
+ theme: finalTheme,
288
+ resultsViewData,
289
+ onBackToChat: handleBackToChat,
290
+ onProductCardClick: handleProductCardClick,
291
+ onClose,
292
+ logoDark: chatHeaderLogoDarkSrc,
293
+ logoLight: chatHeaderLogoLightSrc,
294
+ headerBgColor: headerBackgroundColor,
295
+ headerMode,
296
+ footer
297
+ });
295
298
  return isMobile ? /* @__PURE__ */ jsx(ModalSheet, {
296
299
  animationKey,
297
300
  open: isOpen,