@envive-ai/react-widgets-v3 0.3.23 → 0.3.24

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 (77) hide show
  1. package/dist/CXIntegration/hooks/useUnifiedCXButton.cjs +1 -1
  2. package/dist/CXIntegration/hooks/useUnifiedCXButton.js +1 -1
  3. package/dist/debug/MessageContent.cjs +1 -1
  4. package/dist/debug/MessageContent.js +1 -1
  5. package/dist/debug/chatEmbed.cjs +4 -4
  6. package/dist/debug/chatEmbed.js +3 -3
  7. package/dist/debug/reportIssue.cjs +3 -3
  8. package/dist/debug/reportIssue.js +3 -3
  9. package/dist/hocs/withBaseWidget/types.d.ts +1 -1
  10. package/dist/hocs/withBaseWidget/withBaseWidget.cjs +1 -1
  11. package/dist/hocs/withBaseWidget/withBaseWidget.d.cts +2 -2
  12. package/dist/hocs/withBaseWidget/withBaseWidget.d.ts +2 -2
  13. package/dist/hocs/withBaseWidget/withBaseWidget.js +1 -1
  14. package/dist/packages/widgets/dist/SearchResults/SearchResultsWidget.d.ts +2 -2
  15. package/dist/packages/widgets/dist/SuggestionBar/SuggestionBar.d.ts +2 -2
  16. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.cjs +9 -9
  17. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.cts +3 -3
  18. package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js +9 -9
  19. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.cjs +1 -1
  20. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.cts +3 -3
  21. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.ts +3 -3
  22. package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.js +1 -1
  23. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.cjs +7 -7
  24. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.cts +3 -3
  25. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +3 -3
  26. package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.js +7 -7
  27. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.cjs +13 -11
  28. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.cts +7 -3
  29. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.ts +7 -3
  30. package/dist/widgets/FloatingChatWidget/FloatingChatWidget.js +13 -11
  31. package/dist/widgets/FloatingChatWidget/hooks/useAutoPopup.cjs +2 -2
  32. package/dist/widgets/FloatingChatWidget/hooks/useAutoPopup.js +2 -2
  33. package/dist/widgets/FloatingChatWidget/hooks/useFloatingButtonVisibility.cjs +2 -3
  34. package/dist/widgets/FloatingChatWidget/hooks/useFloatingButtonVisibility.js +3 -4
  35. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.cjs +1 -1
  36. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.cts +2 -2
  37. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.ts +2 -2
  38. package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.js +1 -1
  39. package/dist/widgets/ProductCardWidget/ProductCardWidget.cjs +6 -6
  40. package/dist/widgets/ProductCardWidget/ProductCardWidget.d.cts +2 -2
  41. package/dist/widgets/ProductCardWidget/ProductCardWidget.js +6 -6
  42. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.cjs +8 -8
  43. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.cts +3 -3
  44. package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +8 -8
  45. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.cjs +6 -6
  46. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.cts +2 -2
  47. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +2 -2
  48. package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.js +6 -6
  49. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.cjs +1 -1
  50. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.cts +2 -2
  51. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.ts +2 -2
  52. package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.js +1 -1
  53. package/dist/widgets/SocialProofWidget/SocialProofWidget.cjs +9 -9
  54. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.cts +3 -3
  55. package/dist/widgets/SocialProofWidget/SocialProofWidget.d.ts +3 -3
  56. package/dist/widgets/SocialProofWidget/SocialProofWidget.js +9 -9
  57. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.cjs +5 -5
  58. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.cts +2 -2
  59. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +2 -2
  60. package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +5 -5
  61. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.cjs +1 -1
  62. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.cts +2 -2
  63. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts +2 -2
  64. package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.js +1 -1
  65. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.cjs +5 -5
  66. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.cts +3 -3
  67. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts +3 -3
  68. package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.js +5 -5
  69. package/dist/widgets/dist/SearchResults/SearchResultsWidget.d.cts +2 -2
  70. package/dist/widgets/dist/SuggestionBar/SuggestionBar.d.cts +2 -2
  71. package/dist/widgets/hooks/useGetWidgetStatus.cjs +2 -2
  72. package/dist/widgets/hooks/useGetWidgetStatus.js +2 -2
  73. package/dist/widgets/utils/functions.cjs +1 -1
  74. package/dist/widgets/utils/functions.js +1 -1
  75. package/package.json +1 -1
  76. package/src/widgets/FloatingChatWidget/FloatingChatWidget.tsx +11 -2
  77. package/src/widgets/FloatingChatWidget/hooks/useFloatingButtonVisibility.ts +2 -2
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime19 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime4 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_runtime19.JSX.Element;
10
+ }: TitledPromptCarouselWidgetProps): react_jsx_runtime4.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime7 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime15 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_runtime7.JSX.Element;
10
+ }: TitledPromptCarouselWidgetProps): react_jsx_runtime15.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,15 +1,15 @@
1
1
  import { withBaseWidget } from "../../hocs/withBaseWidget/withBaseWidget.js";
2
2
  import "../../hocs/withBaseWidget/index.js";
3
3
  import { getStringIdForText } from "../utils/functions.js";
4
- import { useCallback } from "react";
5
- import { EnviveMetricsEventName, useAmplitude } from "@envive-ai/react-hooks/contexts/amplitudeContext";
6
- import { jsx } from "react/jsx-runtime";
7
- import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
8
- import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
9
4
  import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
5
+ import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
10
6
  import { useChatToggle } from "@envive-ai/react-hooks/hooks/ChatToggle";
7
+ import { ChatElementDisplayLocationV3 } from "@envive-ai/react-hooks/application/models";
8
+ import { EnviveMetricsEventName, useAmplitude } from "@envive-ai/react-hooks/contexts/amplitudeContext";
11
9
  import { WidgetInteractionComponent } from "@envive-ai/react-hooks/hooks/WidgetInteraction/types";
12
10
  import { AnimationSpeed, usePromptCarouselAnalytics } from "@envive-ai/react-toolkit-v3/PromptCarousel";
11
+ import { useCallback } from "react";
12
+ import { jsx } from "react/jsx-runtime";
13
13
  import { TitledPromptCarousel } from "@envive-ai/react-toolkit-v3/TitledPromptCarousel";
14
14
 
15
15
  //#region src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.tsx
@@ -4,8 +4,8 @@ const require_ChatPreviewComparisonWidget = require('../ChatPreviewComparisonWid
4
4
  const require_ChatPreviewWidget = require('../ChatPreviewWidget/ChatPreviewWidget.cjs');
5
5
  const require_useGetWidgetStatus = require('../hooks/useGetWidgetStatus.cjs');
6
6
  const require_TypingAnimationWidget = require('../TypingAnimationWidget/TypingAnimationWidget.cjs');
7
- let react_jsx_runtime = require("react/jsx-runtime");
8
7
  let __envive_ai_react_hooks_contexts_typesV3 = require("@envive-ai/react-hooks/contexts/typesV3");
8
+ let react_jsx_runtime = require("react/jsx-runtime");
9
9
  let __envive_ai_react_toolkit_v3_ChatPreviewLoading = require("@envive-ai/react-toolkit-v3/ChatPreviewLoading");
10
10
 
11
11
  //#region src/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.tsx
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime5 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime19 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_runtime5.JSX.Element;
10
+ }: TypingAnimationFlowWidgetProps): react_jsx_runtime19.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime3 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime14 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_runtime3.JSX.Element;
10
+ }: TypingAnimationFlowWidgetProps): react_jsx_runtime14.JSX.Element;
11
11
  displayName: string;
12
12
  };
13
13
  //#endregion
@@ -3,8 +3,8 @@ import { ChatPreviewComparisonWidgetWithBaseWidget } from "../ChatPreviewCompari
3
3
  import { ChatPreviewWidgetWithBaseWidget } from "../ChatPreviewWidget/ChatPreviewWidget.js";
4
4
  import useGetWidgetStatus_default from "../hooks/useGetWidgetStatus.js";
5
5
  import { TypingAnimationWithBaseWidget } from "../TypingAnimationWidget/TypingAnimationWidget.js";
6
- import { jsx } from "react/jsx-runtime";
7
6
  import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
7
+ import { jsx } from "react/jsx-runtime";
8
8
  import { ChatPreviewLoading } from "@envive-ai/react-toolkit-v3/ChatPreviewLoading";
9
9
 
10
10
  //#region src/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.tsx
@@ -2,17 +2,17 @@ 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
4
  const require_functions = require('../utils/functions.cjs');
5
- let react = require("react");
6
- let __envive_ai_react_hooks_contexts_amplitudeContext = require("@envive-ai/react-hooks/contexts/amplitudeContext");
7
- let react_jsx_runtime = require("react/jsx-runtime");
5
+ let __envive_ai_react_hooks_contexts_salesAgentContext = require("@envive-ai/react-hooks/contexts/salesAgentContext");
8
6
  let __envive_ai_react_hooks_contexts_typesV3 = require("@envive-ai/react-hooks/contexts/typesV3");
9
7
  let jotai = require("jotai");
10
8
  let __envive_ai_react_hooks_contexts_featureFlagServiceContext = require("@envive-ai/react-hooks/contexts/featureFlagServiceContext");
11
9
  let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks/application/models");
12
- let __envive_ai_react_hooks_contexts_salesAgentContext = require("@envive-ai/react-hooks/contexts/salesAgentContext");
10
+ let __envive_ai_react_hooks_contexts_amplitudeContext = require("@envive-ai/react-hooks/contexts/amplitudeContext");
11
+ let __envive_ai_react_hooks_hooks_WidgetInteraction = require("@envive-ai/react-hooks/hooks/WidgetInteraction");
13
12
  let __envive_ai_react_hooks_hooks_WidgetInteraction_types = require("@envive-ai/react-hooks/hooks/WidgetInteraction/types");
14
13
  let __envive_ai_react_toolkit_v3_PromptCarousel = require("@envive-ai/react-toolkit-v3/PromptCarousel");
15
- let __envive_ai_react_hooks_hooks_WidgetInteraction = require("@envive-ai/react-hooks/hooks/WidgetInteraction");
14
+ let react = require("react");
15
+ let react_jsx_runtime = require("react/jsx-runtime");
16
16
  let __envive_ai_react_hooks_atoms_chat_chatState = require("@envive-ai/react-hooks/atoms/chat/chatState");
17
17
  let __envive_ai_react_toolkit_v3_PromptButton_types = require("@envive-ai/react-toolkit-v3/PromptButton/types");
18
18
  let __envive_ai_react_toolkit_v3_TypingAnimation = require("@envive-ai/react-toolkit-v3/TypingAnimation");
@@ -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_runtime12 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_runtime12.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_runtime12.JSX.Element;
16
16
  displayName: string;
17
17
  };
18
18
  //#endregion
@@ -1,9 +1,9 @@
1
1
  import { BaseWidgetProps } from "../../hocs/withBaseWidget/types.js";
2
- import * as react_jsx_runtime1 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime12 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_runtime1.JSX.Element;
6
+ (props: BaseWidgetProps): react_jsx_runtime12.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_runtime1.JSX.Element;
15
+ }: TypingAnimationWidgetProps): react_jsx_runtime12.JSX.Element;
16
16
  displayName: string;
17
17
  };
18
18
  //#endregion
@@ -1,17 +1,17 @@
1
1
  import { withBaseWidget } from "../../hocs/withBaseWidget/withBaseWidget.js";
2
2
  import "../../hocs/withBaseWidget/index.js";
3
3
  import { getStringIdForText } from "../utils/functions.js";
4
- import { useCallback } from "react";
5
- import { EnviveMetricsEventName, useAmplitude } from "@envive-ai/react-hooks/contexts/amplitudeContext";
6
- import { jsx } from "react/jsx-runtime";
4
+ import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
7
5
  import { WidgetTypeV3 } from "@envive-ai/react-hooks/contexts/typesV3";
8
6
  import { useSetAtom } from "jotai";
9
7
  import { useFeatureFlagService } from "@envive-ai/react-hooks/contexts/featureFlagServiceContext";
10
8
  import { ChatElementDisplayLocationV3, FeatureGates } from "@envive-ai/react-hooks/application/models";
11
- import { useSalesAgent } from "@envive-ai/react-hooks/contexts/salesAgentContext";
9
+ import { EnviveMetricsEventName, useAmplitude } from "@envive-ai/react-hooks/contexts/amplitudeContext";
10
+ import { useWidgetInteraction } from "@envive-ai/react-hooks/hooks/WidgetInteraction";
12
11
  import { WidgetInteractionComponent, WidgetInteractionType } from "@envive-ai/react-hooks/hooks/WidgetInteraction/types";
13
12
  import { PromptCarouselRows, usePromptCarouselAnalytics } from "@envive-ai/react-toolkit-v3/PromptCarousel";
14
- import { useWidgetInteraction } from "@envive-ai/react-hooks/hooks/WidgetInteraction";
13
+ import { useCallback } from "react";
14
+ import { jsx } from "react/jsx-runtime";
15
15
  import { chatOnToggleAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
16
16
  import { PromptButtonVariant } from "@envive-ai/react-toolkit-v3/PromptButton/types";
17
17
  import { TypingAnimation } from "@envive-ai/react-toolkit-v3/TypingAnimation";
@@ -1,8 +1,8 @@
1
- import * as react_jsx_runtime1 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_runtime1.JSX.Element;
5
+ declare const SearchResultsWidget: () => react_jsx_runtime2.JSX.Element;
6
6
  //#endregion
7
7
 
8
8
  //#endregion
@@ -1,5 +1,5 @@
1
1
  import { SuggestionBarLocationForMetrics } from "./types.cjs";
2
- import * as react_jsx_runtime2 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import { SuggestionButtonVariant } from "@envive-ai/react-hooks/contexts/types";
4
4
  import { Message } from "postcss";
5
5
 
@@ -30,7 +30,7 @@ declare function SuggestionBar({
30
30
  buttonBorderRadius,
31
31
  handleReply,
32
32
  dataTestId
33
- }: Readonly<SuggestionBarProps>): react_jsx_runtime2.JSX.Element;
33
+ }: Readonly<SuggestionBarProps>): react_jsx_runtime0.JSX.Element;
34
34
  //#endregion
35
35
  //#endregion
36
36
  export { SuggestionBar };
@@ -1,8 +1,8 @@
1
1
  const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
2
2
  const require_functions = require('../utils/functions.cjs');
3
- let react = require("react");
4
- let jotai = require("jotai");
5
3
  let __envive_ai_react_hooks_atoms_chat = require("@envive-ai/react-hooks/atoms/chat");
4
+ let jotai = require("jotai");
5
+ let react = require("react");
6
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
@@ -1,7 +1,7 @@
1
1
  import { isLoading, isProductComparison, userHasInteracted, userHasNotInteracted } from "../utils/functions.js";
2
- import { useMemo } from "react";
3
- import { useAtomValue } from "jotai";
4
2
  import { chatAtom, lastAssistantMessageAtom } from "@envive-ai/react-hooks/atoms/chat";
3
+ import { useAtomValue } from "jotai";
4
+ import { useMemo } from "react";
5
5
  import { responseStreamingAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
6
6
 
7
7
  //#region src/widgets/hooks/useGetWidgetStatus.tsx
@@ -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
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@envive-ai/react-widgets-v3",
3
- "version": "0.3.23",
3
+ "version": "0.3.24",
4
4
  "description": "React widget library v3 for Envive services.",
5
5
  "keywords": [
6
6
  "react",
@@ -80,10 +80,13 @@ const CXButtonProvider = ({
80
80
  interface FloatingChatWidgetHandlerProps extends BaseWidgetProps {
81
81
  previewButtonOnly?: boolean;
82
82
  previewChatAlwaysOpen?: boolean;
83
+ previewCXButtonsEnabled?: boolean;
84
+ previewDisclaimer?: boolean;
83
85
  }
84
86
 
85
87
  const FloatingChatWidgetHandler = (props: FloatingChatWidgetHandlerProps) => {
86
- const { previewButtonOnly, previewChatAlwaysOpen } = props;
88
+ const { previewButtonOnly, previewChatAlwaysOpen, previewCXButtonsEnabled, previewDisclaimer } =
89
+ props;
87
90
  const salesAgentData = useSalesAgent();
88
91
  const { trackWidgetInteraction } = useWidgetInteraction();
89
92
  const { userHasInteractedValue } = useGetWidgetStatus();
@@ -205,7 +208,7 @@ const FloatingChatWidgetHandler = (props: FloatingChatWidgetHandlerProps) => {
205
208
  hardcopyContent={hardcopyContent}
206
209
  floatingChatConfig={uiConfig?.floatingChat ?? ({} as FloatingChatConfig)}
207
210
  lookAndFeelConfig={modifiedLookAndFeelConfig ?? ({} as LookAndFeelConfig)}
208
- isCXButtonSwitchEnabled={!!isSwitchEnabled?.()}
211
+ isCXButtonSwitchEnabled={previewCXButtonsEnabled ? true : !!isSwitchEnabled?.()}
209
212
  isFloatingChatOpen={effectiveIsOpen}
210
213
  onToggleCXButton={toggle}
211
214
  debugBar={<DebugBar />}
@@ -271,11 +274,15 @@ const FloatingChatWidgetWithBaseWidget = withBaseWidget<FloatingChatWidgetHandle
271
274
  export interface FloatingChatWidgetProps {
272
275
  previewButtonOnly?: boolean;
273
276
  previewChatAlwaysOpen?: boolean;
277
+ previewCXButtonsEnabled?: boolean;
278
+ previewDisclaimer?: boolean;
274
279
  }
275
280
 
276
281
  export const FloatingChatWidget = ({
277
282
  previewButtonOnly,
278
283
  previewChatAlwaysOpen,
284
+ previewCXButtonsEnabled,
285
+ previewDisclaimer,
279
286
  }: FloatingChatWidgetProps = {}) => {
280
287
  return (
281
288
  <FloatingChatWidgetWithBaseWidget
@@ -283,6 +290,8 @@ export const FloatingChatWidget = ({
283
290
  widgetConfigId="fake-widget-config-id"
284
291
  previewButtonOnly={previewButtonOnly}
285
292
  previewChatAlwaysOpen={previewChatAlwaysOpen}
293
+ previewCXButtonsEnabled={previewCXButtonsEnabled}
294
+ previewDisclaimer={previewDisclaimer}
286
295
  />
287
296
  );
288
297
  };
@@ -2,7 +2,7 @@ import { FeatureGates } from '@envive-ai/react-hooks/application/models';
2
2
  import { variantInfoAtom } from '@envive-ai/react-hooks/atoms/app';
3
3
  import { featureFlagServiceAtom } from '@envive-ai/react-hooks/atoms/org';
4
4
  import { FloatingButtonShow } from '@envive-ai/react-toolkit-v3/FloatingButton';
5
- import { useAtom, useAtomValue } from 'jotai';
5
+ import { useAtomValue } from 'jotai';
6
6
  import { useMemo } from 'react';
7
7
 
8
8
  export interface UseFloatingButtonVisibilityProps {
@@ -22,7 +22,7 @@ export const useFloatingButtonVisibility = ({
22
22
  userHasInteracted,
23
23
  }: UseFloatingButtonVisibilityProps): UseFloatingButtonVisibilityReturn => {
24
24
  const featureFlagService = useAtomValue(featureFlagServiceAtom);
25
- const [variantInfo] = useAtom(variantInfoAtom);
25
+ const variantInfo = useAtomValue(variantInfoAtom);
26
26
 
27
27
  const internalfloatingButtonShowConfig =
28
28
  variantInfo.floatingButtonOverride ?? floatingButtonShowConfig;