@envive-ai/react-widgets-v3 0.3.2 → 0.3.6

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 (135) hide show
  1. package/dist/hocs/withBaseWidget/types.d.cts +3 -3
  2. package/dist/hocs/withBaseWidget/types.d.ts +3 -5
  3. package/dist/hocs/withBaseWidget/withBaseWidget.d.cts +2 -2
  4. package/dist/hocs/withBaseWidget/withBaseWidget.d.ts +2 -2
  5. package/dist/node_modules/uuid/dist/native.js +6 -0
  6. package/dist/node_modules/uuid/dist/rng.js +13 -0
  7. package/dist/node_modules/uuid/dist/stringify.js +9 -0
  8. package/dist/node_modules/uuid/dist/v4.js +27 -0
  9. package/dist/node_modules/uuid/dist-node/native.cjs +8 -0
  10. package/dist/node_modules/uuid/dist-node/rng.cjs +16 -0
  11. package/dist/node_modules/uuid/dist-node/stringify.cjs +10 -0
  12. package/dist/node_modules/uuid/dist-node/v4.cjs +27 -0
  13. package/dist/{widgets → packages/widgets}/dist/SearchResults/SearchResults.d.ts +3 -4
  14. package/dist/{widgets → packages/widgets}/dist/SearchResults/SearchResultsWidget.d.ts +2 -2
  15. package/dist/{widgets → packages/widgets}/dist/SearchZeroState/SearchZeroStateWidget.d.ts +2 -2
  16. package/dist/packages/widgets/dist/SearchZeroState/index.d.ts +3 -0
  17. package/dist/{widgets → packages/widgets}/dist/SearchZeroState/types.d.ts +2 -2
  18. package/dist/{widgets → packages/widgets}/dist/SuggestionBar/SuggestionBar.d.ts +1 -1
  19. package/dist/{widgets → packages/widgets}/dist/SuggestionButtonContainer/types.d.ts +2 -3
  20. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.cjs +28 -11
  21. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.cts +3 -3
  22. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.ts +3 -3
  23. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js +28 -11
  24. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.cts +3 -3
  25. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.cjs +27 -10
  26. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.cts +3 -3
  27. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +3 -3
  28. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.js +27 -10
  29. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.cjs +3 -3
  30. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.cts +2 -2
  31. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.ts +2 -2
  32. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.js +3 -3
  33. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.cjs +26 -8
  34. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.cts +3 -3
  35. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.ts +3 -3
  36. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +27 -9
  37. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.cjs +14 -6
  38. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.cts +2 -2
  39. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +2 -2
  40. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.js +15 -7
  41. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.cjs +2 -2
  42. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.cts +2 -2
  43. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.ts +2 -2
  44. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.js +2 -2
  45. package/dist/widgets/SocialProofWidget/SocialProofWidget.cjs +36 -13
  46. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.cts +3 -3
  47. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.ts +3 -3
  48. package/dist/widgets/SocialProofWidget/SocialProofWidget.js +36 -13
  49. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.cjs +13 -5
  50. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.cts +2 -2
  51. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +2 -2
  52. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +14 -6
  53. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.cjs +2 -2
  54. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.cts +2 -2
  55. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.js +2 -2
  56. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.cjs +14 -7
  57. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.cts +3 -3
  58. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.js +14 -7
  59. package/dist/widgets/dist/SearchResults/SearchResults.d.cts +3 -4
  60. package/dist/widgets/dist/SearchResults/SearchResultsWidget.d.cts +2 -2
  61. package/dist/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.cts +2 -2
  62. package/dist/widgets/dist/SearchZeroState/types.d.cts +2 -2
  63. package/dist/widgets/dist/SuggestionBar/SuggestionBar.d.cts +1 -1
  64. package/dist/widgets/dist/SuggestionButtonContainer/types.d.cts +2 -3
  65. package/dist/widgets/hooks/useGetWidgetStatus.cjs +1 -1
  66. package/dist/widgets/hooks/useGetWidgetStatus.js +1 -1
  67. package/dist/widgets/utils/functions.cjs +1 -1
  68. package/dist/widgets/utils/functions.js +1 -1
  69. package/dist/widgets-v2/SearchResults/index.d.ts +3 -3
  70. package/dist/widgets-v2/SearchZeroState/index.d.cts +1 -2
  71. package/dist/widgets-v2/SearchZeroState/index.d.ts +4 -5
  72. package/dist/widgets-v2/SuggestionBar/index.d.ts +3 -3
  73. package/dist/widgets-v2/SuggestionButtonContainer/index.d.ts +2 -2
  74. package/package.json +1 -1
  75. package/src/stories/SalesAgentTest/SalesAgentTest.tsx +2 -2
  76. package/src/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.tsx +30 -8
  77. package/src/widgets/ChatPreviewWidget/ChatPreviewWidget.tsx +33 -9
  78. package/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.tsx +33 -8
  79. package/src/widgets/PromptCarouselWidget/PromptCarouselWidget.tsx +19 -5
  80. package/src/widgets/SocialProofWidget/SocialProofWidget.tsx +41 -10
  81. package/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.tsx +19 -5
  82. package/src/widgets/TypingAnimationWidget/TypingAnimationWidget.tsx +18 -5
  83. package/dist/hooks/dist/application/models/api/orgConfigResults.d.ts +0 -1
  84. package/dist/hooks/dist/application/models/frontendConfig.d.ts +0 -1
  85. package/dist/hooks/dist/contexts/amplitudeContext/amplitudeContext.d.ts +0 -2
  86. package/dist/hooks/dist/contexts/amplitudeContext/index.d.ts +0 -2
  87. package/dist/hooks/dist/contexts/featureFlagServiceContext/featureFlagServiceContext.d.ts +0 -2
  88. package/dist/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.cts +0 -8
  89. package/dist/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts +0 -11
  90. package/dist/hooks/dist/contexts/hardcopyContext/index.d.ts +0 -1
  91. package/dist/hooks/dist/contexts/types.d.cts +0 -44
  92. package/dist/hooks/dist/contexts/types.d.ts +0 -47
  93. package/dist/hooks/dist/contexts/typesV3.d.cts +0 -201
  94. package/dist/hooks/dist/contexts/typesV3.d.ts +0 -201
  95. package/dist/hooks/dist/services/amplitudeService/amplitudeService.d.cts +0 -36
  96. package/dist/hooks/dist/services/amplitudeService/amplitudeService.d.ts +0 -37
  97. package/dist/hooks/dist/types/customerService.d.cts +0 -18
  98. package/dist/hooks/dist/types/customerService.d.ts +0 -18
  99. package/dist/widgets/dist/SearchZeroState/index.d.ts +0 -4
  100. package/dist/widgets/dist/packages/hooks/dist/application/models/api/response.d.cts +0 -14
  101. package/dist/widgets/dist/packages/hooks/dist/application/models/api/response.d.ts +0 -14
  102. package/dist/widgets/dist/packages/hooks/dist/application/models/api/search.d.cts +0 -15
  103. package/dist/widgets/dist/packages/hooks/dist/application/models/api/search.d.ts +0 -15
  104. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.cts +0 -73
  105. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.ts +0 -73
  106. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.cts +0 -61
  107. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts +0 -61
  108. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.cts +0 -25
  109. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.ts +0 -25
  110. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.cts +0 -35
  111. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.ts +0 -35
  112. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.cts +0 -32
  113. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.ts +0 -32
  114. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.cts +0 -32
  115. package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.ts +0 -32
  116. package/dist/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.cts +0 -14
  117. package/dist/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts +0 -15
  118. package/dist/widgets/dist/packages/hooks/dist/contexts/types.d.cts +0 -61
  119. package/dist/widgets/dist/packages/hooks/dist/contexts/types.d.ts +0 -61
  120. package/dist/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.cts +0 -60
  121. package/dist/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts +0 -60
  122. package/dist/widgets/dist/packages/hooks/dist/hooks/utils.d.cts +0 -11
  123. package/dist/widgets/dist/packages/hooks/dist/hooks/utils.d.ts +0 -11
  124. package/dist/widgets/dist/packages/hooks/dist/types/search-filter-types.d.cts +0 -28
  125. package/dist/widgets/dist/packages/hooks/dist/types/search-filter-types.d.ts +0 -28
  126. package/dist/widgets/dist/packages/hooks/dist/types/test-types.d.cts +0 -10
  127. package/dist/widgets/dist/packages/hooks/dist/types/test-types.d.ts +0 -10
  128. /package/dist/{widgets → packages/widgets}/dist/SearchResults/index.d.ts +0 -0
  129. /package/dist/{widgets → packages/widgets}/dist/SearchResults/types.d.ts +0 -0
  130. /package/dist/{widgets → packages/widgets}/dist/SearchZeroState/SearchZeroState.d.ts +0 -0
  131. /package/dist/{widgets → packages/widgets}/dist/SuggestionBar/index.d.ts +0 -0
  132. /package/dist/{widgets → packages/widgets}/dist/SuggestionBar/types.d.ts +0 -0
  133. /package/dist/{widgets → packages/widgets}/dist/SuggestionButtonContainer/SuggestionButtonContainer.d.ts +0 -0
  134. /package/dist/{widgets → packages/widgets}/dist/config/BaseWidgetConfig.d.ts +0 -0
  135. /package/dist/{widgets → packages/widgets}/dist/config/WidgetType.d.ts +0 -0
@@ -1,14 +1,15 @@
1
1
  import { withBaseWidget } from "../../hocs/withBaseWidget/withBaseWidget.js";
2
+ import v4_default from "../../node_modules/uuid/dist/v4.js";
2
3
  import { getProductImageUrl } from "../utils/functions.js";
3
4
  import { useCallback } from "react";
4
5
  import { jsx } from "react/jsx-runtime";
5
6
  import { SocialProofWidgetKind, WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
6
- import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
7
- import { Theme } from "@envive-ai/react-toolkit-v3/Tokens";
8
- import { useChatToggle } from "@envive-ai/react-hooks/hooks/ChatToggle";
9
- import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
10
7
  import { useAtomValue, useSetAtom } from "jotai";
8
+ import { handleReplyAtom } from "@envive-ai/react-hooks/atoms/chat/replies";
9
+ import { useChatToggle } from "@envive-ai/react-hooks/hooks/ChatToggle";
11
10
  import { lastAssistantMessageAtom } from "@envive-ai/react-hooks/atoms/chat";
11
+ import { Theme } from "@envive-ai/react-toolkit-v3/Tokens";
12
+ import { ChatElementDisplayLocationV3, MessageRole, MessageType } from "@envive-ai/react-hooks/application/models";
12
13
  import { ChatPreviewLoading } from "@envive-ai/react-toolkit-v3/ChatPreviewLoading";
13
14
  import { chatPreviewLoadingDataAtom } from "@envive-ai/react-hooks/atoms/widget";
14
15
  import { SocialProof } from "@envive-ai/react-toolkit-v3/SocialProof";
@@ -16,7 +17,7 @@ import { SocialProof } from "@envive-ai/react-toolkit-v3/SocialProof";
16
17
  //#region src/widgets/SocialProofWidget/SocialProofWidget.tsx
17
18
  const SocialProofWidgetHandler = (props) => {
18
19
  const setChatPreviewLoadingData = useSetAtom(chatPreviewLoadingDataAtom);
19
- const { onTypedMessageSubmitted } = useSalesAgent();
20
+ const handleReply = useSetAtom(handleReplyAtom);
20
21
  const { openChat } = useChatToggle();
21
22
  const lastAssistantMessage = useAtomValue(lastAssistantMessageAtom);
22
23
  const { hardcopyContent, widgetConfig, uiConfig, isLoading, widgetConfigId } = props;
@@ -39,22 +40,44 @@ const SocialProofWidgetHandler = (props) => {
39
40
  alt: "Product Image"
40
41
  }];
41
42
  const handlePrimaryButtonClick = useCallback((text) => {
42
- onTypedMessageSubmitted({
43
- query: text,
43
+ handleReply({
44
+ message: {
45
+ id: v4_default(),
46
+ role: MessageRole.User,
47
+ type: MessageType.QueryTyped,
48
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
49
+ metadata: { content: text }
50
+ },
44
51
  userTyped: false
45
52
  });
46
53
  openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_PRIMARY_BUTTON);
47
- }, [onTypedMessageSubmitted, openChat]);
54
+ }, [handleReply, openChat]);
48
55
  const handleSecondaryButtonClick = useCallback((text) => {
49
- onTypedMessageSubmitted({
50
- query: text,
56
+ handleReply({
57
+ message: {
58
+ id: v4_default(),
59
+ role: MessageRole.User,
60
+ type: MessageType.QueryTyped,
61
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
62
+ metadata: { content: text }
63
+ },
51
64
  userTyped: false
52
65
  });
53
66
  openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_SECONDARY_BUTTON);
54
- }, [onTypedMessageSubmitted, openChat]);
55
- const handleTextFieldClick = useCallback(() => {
67
+ }, [handleReply, openChat]);
68
+ const handleTextFieldClick = useCallback((text) => {
69
+ handleReply({
70
+ message: {
71
+ id: v4_default(),
72
+ role: MessageRole.User,
73
+ type: MessageType.QueryTyped,
74
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
75
+ metadata: { content: text }
76
+ },
77
+ userTyped: false
78
+ });
56
79
  openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_TEXT_FIELD);
57
- }, [openChat]);
80
+ }, [handleReply, openChat]);
58
81
  if (isLoading) return /* @__PURE__ */ jsx(ChatPreviewLoading, { fullIsLoading: true });
59
82
  setChatPreviewLoadingData({
60
83
  widgetConfigId,
@@ -1,10 +1,12 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_withBaseWidget = require('../../hocs/withBaseWidget/withBaseWidget.cjs');
3
3
  require('../../hocs/withBaseWidget/index.cjs');
4
+ const require_v4 = require('../../node_modules/uuid/dist-node/v4.cjs');
4
5
  let react = require("react");
5
6
  let react_jsx_runtime = require("react/jsx-runtime");
6
7
  let __envive_ai_react_hooks_contexts_typesV3 = require("@envive-ai/react-hooks/contexts/typesV3");
7
- let __envive_ai_react_hooks_contexts_salesAgentContext = require("@envive-ai/react-hooks/contexts/salesAgentContext");
8
+ let jotai = require("jotai");
9
+ let __envive_ai_react_hooks_atoms_chat_replies = require("@envive-ai/react-hooks/atoms/chat/replies");
8
10
  let __envive_ai_react_hooks_hooks_ChatToggle = require("@envive-ai/react-hooks/hooks/ChatToggle");
9
11
  let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
10
12
  let __envive_ai_react_toolkit_v3_PromptCarousel = require("@envive-ai/react-toolkit-v3/PromptCarousel");
@@ -20,7 +22,7 @@ const mockButtonTexts = [
20
22
  ];
21
23
  const mockTitleLabel = "Loading...";
22
24
  const TitledPromptCarouselWidgetHandler = (props) => {
23
- const { onTypedMessageSubmitted } = (0, __envive_ai_react_hooks_contexts_salesAgentContext.useSalesAgent)();
25
+ const handleReply = (0, jotai.useSetAtom)(__envive_ai_react_hooks_atoms_chat_replies.handleReplyAtom);
24
26
  const { openChat } = (0, __envive_ai_react_hooks_hooks_ChatToggle.useChatToggle)();
25
27
  const { hardcopyContent, widgetConfig, isLoading } = props;
26
28
  const hardCopyTitleLabel = hardcopyContent?.values?.titleLabel;
@@ -44,12 +46,18 @@ const TitledPromptCarouselWidgetHandler = (props) => {
44
46
  promptCarouselRows,
45
47
  animationSpeed: isLoading ? __envive_ai_react_toolkit_v3_PromptCarousel.AnimationSpeed.FAST : titledPromptCarouselWidgetConfig?.animationSpeed,
46
48
  handleButtonClick: (0, react.useCallback)((text) => {
47
- onTypedMessageSubmitted({
48
- query: text,
49
+ handleReply({
50
+ message: {
51
+ id: require_v4.default(),
52
+ role: __envive_ai_react_hooks_application_models.MessageRole.User,
53
+ type: __envive_ai_react_hooks_application_models.MessageType.QueryTyped,
54
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
55
+ metadata: { content: text }
56
+ },
49
57
  userTyped: false
50
58
  });
51
59
  openChat(__envive_ai_react_hooks_application_models.ChatElementDisplayLocationV3.TITLED_PROMPT_CAROUSEL);
52
- }, [onTypedMessageSubmitted, openChat]),
60
+ }, [handleReply, openChat]),
53
61
  promptButtonTexts: buttonTexts,
54
62
  promptCarouselAriaLabel
55
63
  });
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime12 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts
4
4
  interface TitledPromptCarouselWidgetProps {
@@ -7,7 +7,7 @@ interface TitledPromptCarouselWidgetProps {
7
7
  declare const TitledPromptCarouselWidget: {
8
8
  ({
9
9
  widgetConfigId
10
- }: TitledPromptCarouselWidgetProps): react_jsx_runtime12.JSX.Element;
10
+ }: TitledPromptCarouselWidgetProps): react_jsx_runtime0.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime10 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime5 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts
4
4
  interface TitledPromptCarouselWidgetProps {
@@ -7,7 +7,7 @@ interface TitledPromptCarouselWidgetProps {
7
7
  declare const TitledPromptCarouselWidget: {
8
8
  ({
9
9
  widgetConfigId
10
- }: TitledPromptCarouselWidgetProps): react_jsx_runtime10.JSX.Element;
10
+ }: TitledPromptCarouselWidgetProps): react_jsx_runtime5.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,11 +1,13 @@
1
1
  import { withBaseWidget } from "../../hocs/withBaseWidget/withBaseWidget.js";
2
2
  import "../../hocs/withBaseWidget/index.js";
3
+ import v4_default from "../../node_modules/uuid/dist/v4.js";
3
4
  import { useCallback } from "react";
4
5
  import { jsx } from "react/jsx-runtime";
5
6
  import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
6
- import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
7
+ import { useSetAtom } from "jotai";
8
+ import { handleReplyAtom } from "@envive-ai/react-hooks/atoms/chat/replies";
7
9
  import { useChatToggle } from "@envive-ai/react-hooks/hooks/ChatToggle";
8
- import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
10
+ import { ChatElementDisplayLocationV3, MessageRole, MessageType } from "@envive-ai/react-hooks/application/models";
9
11
  import { AnimationSpeed } from "@envive-ai/react-toolkit-v3/PromptCarousel";
10
12
  import { TitledPromptCarousel } from "@envive-ai/react-toolkit-v3/TitledPromptCarousel";
11
13
 
@@ -19,7 +21,7 @@ const mockButtonTexts = [
19
21
  ];
20
22
  const mockTitleLabel = "Loading...";
21
23
  const TitledPromptCarouselWidgetHandler = (props) => {
22
- const { onTypedMessageSubmitted } = useSalesAgent();
24
+ const handleReply = useSetAtom(handleReplyAtom);
23
25
  const { openChat } = useChatToggle();
24
26
  const { hardcopyContent, widgetConfig, isLoading } = props;
25
27
  const hardCopyTitleLabel = hardcopyContent?.values?.titleLabel;
@@ -43,12 +45,18 @@ const TitledPromptCarouselWidgetHandler = (props) => {
43
45
  promptCarouselRows,
44
46
  animationSpeed: isLoading ? AnimationSpeed.FAST : titledPromptCarouselWidgetConfig?.animationSpeed,
45
47
  handleButtonClick: useCallback((text) => {
46
- onTypedMessageSubmitted({
47
- query: text,
48
+ handleReply({
49
+ message: {
50
+ id: v4_default(),
51
+ role: MessageRole.User,
52
+ type: MessageType.QueryTyped,
53
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
54
+ metadata: { content: text }
55
+ },
48
56
  userTyped: false
49
57
  });
50
58
  openChat(ChatElementDisplayLocationV3.TITLED_PROMPT_CAROUSEL);
51
- }, [onTypedMessageSubmitted, openChat]),
59
+ }, [handleReply, openChat]),
52
60
  promptButtonTexts: buttonTexts,
53
61
  promptCarouselAriaLabel
54
62
  });
@@ -1,8 +1,8 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
- const require_useGetWidgetStatus = require('../hooks/useGetWidgetStatus.cjs');
3
2
  const require_ChatPreviewLoadingWidget = require('../ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.cjs');
4
- const require_ChatPreviewWidget = require('../ChatPreviewWidget/ChatPreviewWidget.cjs');
5
3
  const require_ChatPreviewComparisonWidget = require('../ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.cjs');
4
+ const require_ChatPreviewWidget = require('../ChatPreviewWidget/ChatPreviewWidget.cjs');
5
+ const require_useGetWidgetStatus = require('../hooks/useGetWidgetStatus.cjs');
6
6
  const require_TypingAnimationWidget = require('../TypingAnimationWidget/TypingAnimationWidget.cjs');
7
7
  let react_jsx_runtime = require("react/jsx-runtime");
8
8
  let __envive_ai_react_hooks_contexts_typesV3 = require("@envive-ai/react-hooks/contexts/typesV3");
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime16 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime2 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts
4
4
  interface TypingAnimationFlowWidgetProps {
@@ -7,7 +7,7 @@ interface TypingAnimationFlowWidgetProps {
7
7
  declare const TypingAnimationFlowWidget: {
8
8
  ({
9
9
  widgetConfigId
10
- }: TypingAnimationFlowWidgetProps): react_jsx_runtime16.JSX.Element;
10
+ }: TypingAnimationFlowWidgetProps): react_jsx_runtime2.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,7 +1,7 @@
1
- import useGetWidgetStatus_default from "../hooks/useGetWidgetStatus.js";
2
1
  import { ChatPreviewLoadingWidgetWithBaseWidget } from "../ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.js";
3
- import { ChatPreviewWidgetWithBaseWidget } from "../ChatPreviewWidget/ChatPreviewWidget.js";
4
2
  import { ChatPreviewComparisonWidgetWithBaseWidget } from "../ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js";
3
+ import { ChatPreviewWidgetWithBaseWidget } from "../ChatPreviewWidget/ChatPreviewWidget.js";
4
+ import useGetWidgetStatus_default from "../hooks/useGetWidgetStatus.js";
5
5
  import { TypingAnimationWithBaseWidget } from "../TypingAnimationWidget/TypingAnimationWidget.js";
6
6
  import { jsx } from "react/jsx-runtime";
7
7
  import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
@@ -1,14 +1,15 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_withBaseWidget = require('../../hocs/withBaseWidget/withBaseWidget.cjs');
3
3
  require('../../hocs/withBaseWidget/index.cjs');
4
+ const require_v4 = require('../../node_modules/uuid/dist-node/v4.cjs');
4
5
  let react = require("react");
5
6
  let react_jsx_runtime = require("react/jsx-runtime");
6
7
  let __envive_ai_react_hooks_contexts_typesV3 = require("@envive-ai/react-hooks/contexts/typesV3");
7
- let __envive_ai_react_hooks_contexts_salesAgentContext = require("@envive-ai/react-hooks/contexts/salesAgentContext");
8
- let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
9
8
  let jotai = require("jotai");
10
- let __envive_ai_react_hooks_atoms_chat_chatState = require("@envive-ai/react-hooks/atoms/chat/chatState");
9
+ let __envive_ai_react_hooks_atoms_chat_replies = require("@envive-ai/react-hooks/atoms/chat/replies");
10
+ let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
11
11
  let __envive_ai_react_toolkit_v3_PromptCarousel = require("@envive-ai/react-toolkit-v3/PromptCarousel");
12
+ let __envive_ai_react_hooks_atoms_chat_chatState = require("@envive-ai/react-hooks/atoms/chat/chatState");
12
13
  let __envive_ai_react_toolkit_v3_PromptButton_types = require("@envive-ai/react-toolkit-v3/PromptButton/types");
13
14
  let __envive_ai_react_toolkit_v3_WidgetWrapper = require("@envive-ai/react-toolkit-v3/WidgetWrapper");
14
15
  let __envive_ai_react_toolkit_v3_TypingAnimation = require("@envive-ai/react-toolkit-v3/TypingAnimation");
@@ -25,7 +26,7 @@ const mockHeadlineText = "Loading";
25
26
  const mockAnimatedTextSequence = ["..."];
26
27
  const mockHintText = "Ask me anything";
27
28
  const TypingAnimationWidgetHandler = (props) => {
28
- const { onTypedMessageSubmitted } = (0, __envive_ai_react_hooks_contexts_salesAgentContext.useSalesAgent)();
29
+ const handleReply = (0, jotai.useSetAtom)(__envive_ai_react_hooks_atoms_chat_replies.handleReplyAtom);
29
30
  const onToggle = (0, jotai.useSetAtom)(__envive_ai_react_hooks_atoms_chat_chatState.chatOnToggleAtom);
30
31
  const { hardcopyContent, widgetConfig, isLoading } = props;
31
32
  const titleLabel = hardcopyContent?.values?.titleLabel || "";
@@ -43,12 +44,18 @@ const TypingAnimationWidgetHandler = (props) => {
43
44
  const promptCarouselRows = typingAnimationWidgetConfig?.promptCarouselRows || __envive_ai_react_toolkit_v3_PromptCarousel.PromptCarouselRows.ALWAYS_ONE;
44
45
  const showTextField = typingAnimationWidgetConfig?.showTextField !== false;
45
46
  const handleButtonClick = (0, react.useCallback)((text) => {
46
- onTypedMessageSubmitted({
47
- query: text,
47
+ handleReply({
48
+ message: {
49
+ id: require_v4.default(),
50
+ role: __envive_ai_react_hooks_application_models.MessageRole.User,
51
+ type: __envive_ai_react_hooks_application_models.MessageType.QueryTyped,
52
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
53
+ metadata: { content: text }
54
+ },
48
55
  userTyped: false
49
56
  });
50
57
  onToggle(__envive_ai_react_hooks_application_models.ChatElementDisplayLocationV3.TYPING_ANIMATION);
51
- }, [onTypedMessageSubmitted, onToggle]);
58
+ }, [handleReply, onToggle]);
52
59
  const handleTextFieldClick = (0, react.useCallback)(() => {
53
60
  onToggle(__envive_ai_react_hooks_application_models.ChatElementDisplayLocationV3.TYPING_ANIMATION);
54
61
  }, [onToggle]);
@@ -1,9 +1,9 @@
1
1
  import { BaseWidgetProps } from "../../hocs/withBaseWidget/types.cjs";
2
- import * as react_jsx_runtime0 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime13 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts
5
5
  declare const TypingAnimationWithBaseWidget: {
6
- (props: BaseWidgetProps): react_jsx_runtime0.JSX.Element;
6
+ (props: BaseWidgetProps): react_jsx_runtime13.JSX.Element;
7
7
  displayName: string;
8
8
  };
9
9
  interface TypingAnimationWidgetProps {
@@ -12,7 +12,7 @@ interface TypingAnimationWidgetProps {
12
12
  declare const TypingAnimationWidget: {
13
13
  ({
14
14
  widgetConfigId
15
- }: TypingAnimationWidgetProps): react_jsx_runtime0.JSX.Element;
15
+ }: TypingAnimationWidgetProps): react_jsx_runtime13.JSX.Element;
16
16
  displayName: string;
17
17
  };
18
18
  //#endregion
@@ -1,13 +1,14 @@
1
1
  import { withBaseWidget } from "../../hocs/withBaseWidget/withBaseWidget.js";
2
2
  import "../../hocs/withBaseWidget/index.js";
3
+ import v4_default from "../../node_modules/uuid/dist/v4.js";
3
4
  import { useCallback } from "react";
4
5
  import { jsx } from "react/jsx-runtime";
5
6
  import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
6
- import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
7
- import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
8
7
  import { useSetAtom } from "jotai";
9
- import { chatOnToggleAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
8
+ import { handleReplyAtom } from "@envive-ai/react-hooks/atoms/chat/replies";
9
+ import { ChatElementDisplayLocationV3, MessageRole, MessageType } from "@envive-ai/react-hooks/application/models";
10
10
  import { PromptCarouselRows } from "@envive-ai/react-toolkit-v3/PromptCarousel";
11
+ import { chatOnToggleAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
11
12
  import { PromptButtonVariant } from "@envive-ai/react-toolkit-v3/PromptButton/types";
12
13
  import { WidgetWrapperVariant } from "@envive-ai/react-toolkit-v3/WidgetWrapper";
13
14
  import { TypingAnimation } from "@envive-ai/react-toolkit-v3/TypingAnimation";
@@ -24,7 +25,7 @@ const mockHeadlineText = "Loading";
24
25
  const mockAnimatedTextSequence = ["..."];
25
26
  const mockHintText = "Ask me anything";
26
27
  const TypingAnimationWidgetHandler = (props) => {
27
- const { onTypedMessageSubmitted } = useSalesAgent();
28
+ const handleReply = useSetAtom(handleReplyAtom);
28
29
  const onToggle = useSetAtom(chatOnToggleAtom);
29
30
  const { hardcopyContent, widgetConfig, isLoading } = props;
30
31
  const titleLabel = hardcopyContent?.values?.titleLabel || "";
@@ -42,12 +43,18 @@ const TypingAnimationWidgetHandler = (props) => {
42
43
  const promptCarouselRows = typingAnimationWidgetConfig?.promptCarouselRows || PromptCarouselRows.ALWAYS_ONE;
43
44
  const showTextField = typingAnimationWidgetConfig?.showTextField !== false;
44
45
  const handleButtonClick = useCallback((text) => {
45
- onTypedMessageSubmitted({
46
- query: text,
46
+ handleReply({
47
+ message: {
48
+ id: v4_default(),
49
+ role: MessageRole.User,
50
+ type: MessageType.QueryTyped,
51
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
52
+ metadata: { content: text }
53
+ },
47
54
  userTyped: false
48
55
  });
49
56
  onToggle(ChatElementDisplayLocationV3.TYPING_ANIMATION);
50
- }, [onTypedMessageSubmitted, onToggle]);
57
+ }, [handleReply, onToggle]);
51
58
  const handleTextFieldClick = useCallback(() => {
52
59
  onToggle(ChatElementDisplayLocationV3.TYPING_ANIMATION);
53
60
  }, [onToggle]);
@@ -1,14 +1,13 @@
1
- import { SearchResultsHocProps } from "../packages/hooks/dist/hooks/Search/useSearch.cjs";
2
1
  import { SearchResultsEntryPointWidgetConfig } from "./types.cjs";
3
- import * as react_jsx_runtime1 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
+ import { SearchResultsHocProps } from "@envive-ai/react-hooks/hooks/Search";
4
4
 
5
5
  //#region ../widgets/dist/SearchResults/SearchResults.d.ts
6
-
7
6
  //#region src/SearchResults/SearchResults.d.ts
8
7
  interface SearchResultsProps extends SearchResultsHocProps {
9
8
  widgetConfig: SearchResultsEntryPointWidgetConfig;
10
9
  }
11
- declare const SearchResults: (props: Omit<SearchResultsProps, keyof SearchResultsHocProps>) => react_jsx_runtime1.JSX.Element;
10
+ declare const SearchResults: (props: Omit<SearchResultsProps, string | number | symbol>) => react_jsx_runtime0.JSX.Element;
12
11
  //#endregion
13
12
 
14
13
  //#endregion
@@ -1,8 +1,8 @@
1
- import * as react_jsx_runtime3 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime2 from "react/jsx-runtime";
2
2
 
3
3
  //#region ../widgets/dist/SearchResults/SearchResultsWidget.d.ts
4
4
  //#region src/SearchResults/SearchResultsWidget.d.ts
5
- declare const SearchResultsWidget: () => react_jsx_runtime3.JSX.Element;
5
+ declare const SearchResultsWidget: () => react_jsx_runtime2.JSX.Element;
6
6
  //#endregion
7
7
 
8
8
  //#endregion
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime0 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime3 from "react/jsx-runtime";
2
2
 
3
3
  //#region ../widgets/dist/SearchZeroState/SearchZeroStateWidget.d.ts
4
4
  //#region src/SearchZeroState/SearchZeroStateWidget.d.ts
@@ -11,7 +11,7 @@ declare const SearchZeroStateWidget: ({
11
11
  initialIsOpen,
12
12
  widgetConfigId,
13
13
  entryPointRef
14
- }: SearchZeroStateWidgetProps) => react_jsx_runtime0.JSX.Element;
14
+ }: SearchZeroStateWidgetProps) => react_jsx_runtime3.JSX.Element;
15
15
  //#endregion
16
16
 
17
17
  //#endregion
@@ -1,4 +1,4 @@
1
- import { SearchEntryPointWidgetConfig } from "../packages/hooks/dist/contexts/types.cjs";
1
+ import { SearchEntryPointWidgetConfig, SearchInputVariant } from "@envive-ai/react-hooks/contexts/types";
2
2
 
3
3
  //#region ../widgets/dist/SearchZeroState/types.d.ts
4
4
  //#region src/SearchZeroState/types.d.ts
@@ -10,4 +10,4 @@ interface SearchZeroStateProps {
10
10
  //#endregion
11
11
 
12
12
  //#endregion
13
- export { SearchZeroStateProps };
13
+ export { type SearchEntryPointWidgetConfig, type SearchInputVariant, SearchZeroStateProps };
@@ -1,6 +1,6 @@
1
- import { SuggestionButtonVariant } from "../packages/hooks/dist/contexts/types.cjs";
2
1
  import { SuggestionBarLocationForMetrics } from "./types.cjs";
3
2
  import * as react_jsx_runtime0 from "react/jsx-runtime";
3
+ import { SuggestionButtonVariant } from "@envive-ai/react-hooks/contexts/types";
4
4
  import { Message } from "postcss";
5
5
 
6
6
  //#region ../widgets/dist/SuggestionBar/SuggestionBar.d.ts
@@ -1,8 +1,7 @@
1
- import { TestProps } from "../packages/hooks/dist/types/test-types.cjs";
2
- import { SuggestionButtonVariant } from "../packages/hooks/dist/contexts/types.cjs";
1
+ import { SuggestionButtonVariant } from "@envive-ai/react-hooks/contexts/types";
2
+ import { TestProps } from "@envive-ai/react-hooks/types";
3
3
 
4
4
  //#region ../widgets/dist/SuggestionButtonContainer/types.d.ts
5
-
6
5
  //#region src/SuggestionButtonContainer/types.d.ts
7
6
  interface SuggestionButtonContainerProps extends TestProps {
8
7
  buttonVariation: SuggestionButtonVariant;
@@ -2,8 +2,8 @@ const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_functions = require('../utils/functions.cjs');
3
3
  let react = require("react");
4
4
  let jotai = require("jotai");
5
- let __envive_ai_react_hooks_atoms_chat_chatState = require("@envive-ai/react-hooks/atoms/chat/chatState");
6
5
  let __envive_ai_react_hooks_atoms_chat = require("@envive-ai/react-hooks/atoms/chat");
6
+ let __envive_ai_react_hooks_atoms_chat_chatState = require("@envive-ai/react-hooks/atoms/chat/chatState");
7
7
 
8
8
  //#region src/widgets/hooks/useGetWidgetStatus.tsx
9
9
  const useGetWidgetStatus = () => {
@@ -1,8 +1,8 @@
1
1
  import { isLoading, isProductComparison, userHasInteracted, userHasNotInteracted } from "../utils/functions.js";
2
2
  import { useMemo } from "react";
3
3
  import { useAtomValue } from "jotai";
4
- import { responseStreamingAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
5
4
  import { chatAtom, lastAssistantMessageAtom } from "@envive-ai/react-hooks/atoms/chat";
5
+ import { responseStreamingAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
6
6
 
7
7
  //#region src/widgets/hooks/useGetWidgetStatus.tsx
8
8
  const useGetWidgetStatus = () => {
@@ -1,6 +1,6 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
- let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
3
2
  let __envive_ai_react_hooks_atoms_chat = require("@envive-ai/react-hooks/atoms/chat");
3
+ let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
4
4
  let __envive_ai_react_hooks_atoms_atomStore = require("@envive-ai/react-hooks/atoms/atomStore");
5
5
 
6
6
  //#region src/widgets/utils/functions.ts
@@ -1,5 +1,5 @@
1
- import { MessageRole, MessageType } from "@envive-ai/react-hooks/application/models";
2
1
  import { chatAtom, lastAssistantMessageAtom } from "@envive-ai/react-hooks/atoms/chat";
2
+ import { MessageRole, MessageType } from "@envive-ai/react-hooks/application/models";
3
3
  import { getAtomStore } from "@envive-ai/react-hooks/atoms/atomStore";
4
4
 
5
5
  //#region src/widgets/utils/functions.ts
@@ -1,4 +1,4 @@
1
- import { SearchResultsWidget } from "../../widgets/dist/SearchResults/SearchResultsWidget.js";
2
- import { SearchResults } from "../../widgets/dist/SearchResults/SearchResults.js";
3
- import "../../widgets/dist/SearchResults/index.js";
1
+ import { SearchResultsWidget } from "../../packages/widgets/dist/SearchResults/SearchResultsWidget.js";
2
+ import { SearchResults } from "../../packages/widgets/dist/SearchResults/SearchResults.js";
3
+ import "../../packages/widgets/dist/SearchResults/index.js";
4
4
  export { SearchResults, SearchResultsWidget };
@@ -1,5 +1,4 @@
1
- import { SearchEntryPointWidgetConfig, SearchInputVariant } from "../../widgets/dist/packages/hooks/dist/contexts/types.cjs";
2
- import { SearchZeroStateProps } from "../../widgets/dist/SearchZeroState/types.cjs";
1
+ import { SearchEntryPointWidgetConfig, SearchInputVariant, SearchZeroStateProps } from "../../widgets/dist/SearchZeroState/types.cjs";
3
2
  import { SearchZeroState } from "../../widgets/dist/SearchZeroState/SearchZeroState.cjs";
4
3
  import { SearchZeroStateWidget } from "../../widgets/dist/SearchZeroState/SearchZeroStateWidget.cjs";
5
4
  export { SearchEntryPointWidgetConfig, SearchInputVariant, SearchZeroState, SearchZeroStateProps, SearchZeroStateWidget };
@@ -1,6 +1,5 @@
1
- import { SearchEntryPointWidgetConfig, SearchInputVariant } from "../../widgets/dist/packages/hooks/dist/contexts/types.js";
2
- import { SearchZeroStateProps } from "../../widgets/dist/SearchZeroState/types.js";
3
- import { SearchZeroState } from "../../widgets/dist/SearchZeroState/SearchZeroState.js";
4
- import { SearchZeroStateWidget } from "../../widgets/dist/SearchZeroState/SearchZeroStateWidget.js";
5
- import "../../widgets/dist/SearchZeroState/index.js";
1
+ import { SearchEntryPointWidgetConfig, SearchInputVariant, SearchZeroStateProps } from "../../packages/widgets/dist/SearchZeroState/types.js";
2
+ import { SearchZeroState } from "../../packages/widgets/dist/SearchZeroState/SearchZeroState.js";
3
+ import { SearchZeroStateWidget } from "../../packages/widgets/dist/SearchZeroState/SearchZeroStateWidget.js";
4
+ import "../../packages/widgets/dist/SearchZeroState/index.js";
6
5
  export { SearchEntryPointWidgetConfig, SearchInputVariant, SearchZeroState, SearchZeroStateProps, SearchZeroStateWidget };
@@ -1,4 +1,4 @@
1
- import { SuggestionBarLocationForMetrics } from "../../widgets/dist/SuggestionBar/types.js";
2
- import { SuggestionBar } from "../../widgets/dist/SuggestionBar/SuggestionBar.js";
3
- import "../../widgets/dist/SuggestionBar/index.js";
1
+ import { SuggestionBarLocationForMetrics } from "../../packages/widgets/dist/SuggestionBar/types.js";
2
+ import { SuggestionBar } from "../../packages/widgets/dist/SuggestionBar/SuggestionBar.js";
3
+ import "../../packages/widgets/dist/SuggestionBar/index.js";
4
4
  export { SuggestionBar, SuggestionBarLocationForMetrics };
@@ -1,3 +1,3 @@
1
- import { SuggestionButtonContainerProps } from "../../widgets/dist/SuggestionButtonContainer/types.js";
2
- import { SuggestionButtonContainer } from "../../widgets/dist/SuggestionButtonContainer/SuggestionButtonContainer.js";
1
+ import { SuggestionButtonContainerProps } from "../../packages/widgets/dist/SuggestionButtonContainer/types.js";
2
+ import { SuggestionButtonContainer } from "../../packages/widgets/dist/SuggestionButtonContainer/SuggestionButtonContainer.js";
3
3
  export { SuggestionButtonContainer, SuggestionButtonContainerProps };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@envive-ai/react-widgets-v3",
3
- "version": "0.3.2",
3
+ "version": "0.3.6",
4
4
  "description": "React widget library v3 for Envive services.",
5
5
  "keywords": [
6
6
  "react",
@@ -56,7 +56,7 @@ export const SalesAgentTest = () => {
56
56
  onChange={e => setQuery(e.target.value)}
57
57
  onKeyDown={e => {
58
58
  if (e.key === 'Enter') {
59
- onTypedMessageSubmitted({ query, userTyped: true });
59
+ onTypedMessageSubmitted({ query });
60
60
  setQuery('');
61
61
  }
62
62
  }}
@@ -65,7 +65,7 @@ export const SalesAgentTest = () => {
65
65
  <button
66
66
  type="button"
67
67
  onClick={() => {
68
- onTypedMessageSubmitted({ query, userTyped: true });
68
+ onTypedMessageSubmitted({ query });
69
69
  setQuery('');
70
70
  }}
71
71
  >