@envive-ai/react-widgets-v3 0.3.2 → 0.3.5
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.
- package/dist/hocs/withBaseWidget/types.d.ts +5 -5
- package/dist/hocs/withBaseWidget/withBaseWidget.d.cts +2 -2
- package/dist/hocs/withBaseWidget/withBaseWidget.d.ts +2 -2
- package/dist/node_modules/uuid/dist/native.js +6 -0
- package/dist/node_modules/uuid/dist/rng.js +13 -0
- package/dist/node_modules/uuid/dist/stringify.js +9 -0
- package/dist/node_modules/uuid/dist/v4.js +27 -0
- package/dist/node_modules/uuid/dist-node/native.cjs +8 -0
- package/dist/node_modules/uuid/dist-node/rng.cjs +16 -0
- package/dist/node_modules/uuid/dist-node/stringify.cjs +10 -0
- package/dist/node_modules/uuid/dist-node/v4.cjs +27 -0
- package/dist/{widgets → packages/widgets}/dist/SearchResults/SearchResults.d.ts +2 -2
- package/dist/{widgets → packages/widgets}/dist/SearchResults/SearchResultsWidget.d.ts +2 -2
- package/dist/{widgets → packages/widgets}/dist/SearchZeroState/SearchZeroStateWidget.d.ts +2 -2
- package/dist/{widgets → packages/widgets}/dist/SuggestionBar/SuggestionBar.d.ts +2 -2
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.cjs +28 -11
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.cts +3 -3
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js +28 -11
- package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.cts +3 -3
- package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.cjs +27 -10
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.cts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.js +27 -10
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.cjs +3 -3
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.cts +2 -2
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.ts +2 -2
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.js +3 -3
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.cjs +26 -8
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.cts +3 -3
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +27 -9
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.cjs +14 -6
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +2 -2
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.js +15 -7
- package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.cjs +1 -1
- package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.cts +2 -2
- package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.js +1 -1
- package/dist/widgets/SocialProofWidget/SocialProofWidget.cjs +36 -13
- package/dist/widgets/SocialProofWidget/SocialProofWidget.d.cts +3 -3
- package/dist/widgets/SocialProofWidget/SocialProofWidget.d.ts +3 -3
- package/dist/widgets/SocialProofWidget/SocialProofWidget.js +36 -13
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.cjs +13 -5
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.cts +2 -2
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +2 -2
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +14 -6
- package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.cjs +1 -1
- package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.cts +2 -2
- package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts +2 -2
- package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.js +1 -1
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.cjs +14 -7
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.cts +3 -3
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts +3 -3
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.js +14 -7
- package/dist/widgets/dist/SearchResults/SearchResults.d.cts +2 -2
- package/dist/widgets/dist/SearchResults/SearchResultsWidget.d.cts +2 -2
- package/dist/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.cts +2 -2
- package/dist/widgets/dist/SuggestionBar/SuggestionBar.d.cts +2 -2
- package/dist/widgets/hooks/useGetWidgetStatus.cjs +1 -1
- package/dist/widgets/hooks/useGetWidgetStatus.js +1 -1
- package/dist/widgets/utils/functions.cjs +1 -1
- package/dist/widgets/utils/functions.js +1 -1
- package/dist/widgets-v2/SearchResults/index.d.ts +3 -3
- package/dist/widgets-v2/SearchZeroState/index.d.ts +5 -5
- package/dist/widgets-v2/SuggestionBar/index.d.ts +3 -3
- package/dist/widgets-v2/SuggestionButtonContainer/index.d.ts +2 -2
- package/package.json +1 -1
- package/src/stories/SalesAgentTest/SalesAgentTest.tsx +2 -2
- package/src/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.tsx +30 -8
- package/src/widgets/ChatPreviewWidget/ChatPreviewWidget.tsx +33 -9
- package/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.tsx +33 -8
- package/src/widgets/PromptCarouselWidget/PromptCarouselWidget.tsx +19 -5
- package/src/widgets/SocialProofWidget/SocialProofWidget.tsx +41 -10
- package/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.tsx +19 -5
- package/src/widgets/TypingAnimationWidget/TypingAnimationWidget.tsx +18 -5
- /package/dist/{hooks → packages/hooks}/dist/application/models/api/orgConfigResults.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/application/models/frontendConfig.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/amplitudeContext/amplitudeContext.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/amplitudeContext/index.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/featureFlagServiceContext/featureFlagServiceContext.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/hardcopyContext/hardcopyContext.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/hardcopyContext/index.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/types.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/contexts/typesV3.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/services/amplitudeService/amplitudeService.d.ts +0 -0
- /package/dist/{hooks → packages/hooks}/dist/types/customerService.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SearchResults/index.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SearchResults/types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SearchZeroState/SearchZeroState.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SearchZeroState/index.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SearchZeroState/types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SuggestionBar/index.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SuggestionBar/types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SuggestionButtonContainer/SuggestionButtonContainer.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/SuggestionButtonContainer/types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/config/BaseWidgetConfig.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/config/WidgetType.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/api/response.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/api/search.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/contexts/types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/hooks/utils.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/types/search-filter-types.d.ts +0 -0
- /package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/types/test-types.d.ts +0 -0
|
@@ -4,8 +4,15 @@ import {
|
|
|
4
4
|
} from '@envive-ai/react-hooks/contexts/typesV3';
|
|
5
5
|
import { PromptButtonVariant } from '@envive-ai/react-toolkit-v3/PromptButton/types';
|
|
6
6
|
import { useCallback } from 'react';
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
7
|
+
import { v4 as uuid } from 'uuid';
|
|
8
|
+
import {
|
|
9
|
+
ChatElementDisplayLocationV3,
|
|
10
|
+
Message,
|
|
11
|
+
MessageRole,
|
|
12
|
+
MessageType,
|
|
13
|
+
} from '@envive-ai/react-hooks/application/models';
|
|
14
|
+
import { useSetAtom } from 'jotai';
|
|
15
|
+
import { handleReplyAtom } from '@envive-ai/react-hooks/atoms/chat/replies';
|
|
9
16
|
import { useChatToggle } from '@envive-ai/react-hooks/hooks/ChatToggle';
|
|
10
17
|
import { AnimationSpeed } from '@envive-ai/react-toolkit-v3/PromptCarousel/types/types';
|
|
11
18
|
import { Theme } from '@envive-ai/react-toolkit-v3/Tokens';
|
|
@@ -21,7 +28,7 @@ const mockButtonTexts = [
|
|
|
21
28
|
];
|
|
22
29
|
|
|
23
30
|
const PromptCarouselWidgetHandler = (props: BaseWidgetProps) => {
|
|
24
|
-
const
|
|
31
|
+
const handleReply = useSetAtom(handleReplyAtom);
|
|
25
32
|
const { openChat } = useChatToggle();
|
|
26
33
|
|
|
27
34
|
const { hardcopyContent, widgetConfig, isLoading } = props;
|
|
@@ -41,10 +48,17 @@ const PromptCarouselWidgetHandler = (props: BaseWidgetProps) => {
|
|
|
41
48
|
|
|
42
49
|
const handleButtonClick = useCallback(
|
|
43
50
|
(text: string) => {
|
|
44
|
-
|
|
51
|
+
const newMessage: Message = {
|
|
52
|
+
id: uuid(),
|
|
53
|
+
role: MessageRole.User,
|
|
54
|
+
type: MessageType.QueryTyped,
|
|
55
|
+
createdAt: new Date().toISOString(),
|
|
56
|
+
metadata: { content: text },
|
|
57
|
+
};
|
|
58
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
45
59
|
openChat(ChatElementDisplayLocationV3.PROMPT_CAROUSEL);
|
|
46
60
|
},
|
|
47
|
-
[
|
|
61
|
+
[handleReply, openChat],
|
|
48
62
|
);
|
|
49
63
|
|
|
50
64
|
return (
|
|
@@ -4,14 +4,20 @@ import {
|
|
|
4
4
|
WidgetTypeV3,
|
|
5
5
|
} from '@envive-ai/react-hooks/contexts/typesV3';
|
|
6
6
|
import { useAtomValue, useSetAtom } from 'jotai';
|
|
7
|
-
import {
|
|
7
|
+
import { handleReplyAtom } from '@envive-ai/react-hooks/atoms/chat/replies';
|
|
8
8
|
import { useChatToggle } from '@envive-ai/react-hooks/hooks/ChatToggle';
|
|
9
9
|
import { lastAssistantMessageAtom } from '@envive-ai/react-hooks/atoms/chat';
|
|
10
10
|
|
|
11
11
|
import { SocialProof, SocialProofProps } from '@envive-ai/react-toolkit-v3/SocialProof';
|
|
12
12
|
import { Theme } from '@envive-ai/react-toolkit-v3/Tokens';
|
|
13
13
|
import { useCallback } from 'react';
|
|
14
|
-
import {
|
|
14
|
+
import {
|
|
15
|
+
ChatElementDisplayLocationV3,
|
|
16
|
+
Message,
|
|
17
|
+
MessageRole,
|
|
18
|
+
MessageType,
|
|
19
|
+
} from '@envive-ai/react-hooks/application/models';
|
|
20
|
+
import { v4 as uuid } from 'uuid';
|
|
15
21
|
import { chatPreviewLoadingDataAtom } from '@envive-ai/react-hooks/atoms/widget';
|
|
16
22
|
import { ChatPreviewLoading } from '@envive-ai/react-toolkit-v3/ChatPreviewLoading';
|
|
17
23
|
import { BaseWidgetProps } from '../../hocs/withBaseWidget/types';
|
|
@@ -21,7 +27,7 @@ import { getProductImageUrl } from '../utils/functions';
|
|
|
21
27
|
const SocialProofWidgetHandler = (props: BaseWidgetProps) => {
|
|
22
28
|
const setChatPreviewLoadingData = useSetAtom(chatPreviewLoadingDataAtom);
|
|
23
29
|
|
|
24
|
-
const
|
|
30
|
+
const handleReply = useSetAtom(handleReplyAtom);
|
|
25
31
|
const { openChat } = useChatToggle();
|
|
26
32
|
const lastAssistantMessage = useAtomValue(lastAssistantMessageAtom);
|
|
27
33
|
|
|
@@ -63,23 +69,48 @@ const SocialProofWidgetHandler = (props: BaseWidgetProps) => {
|
|
|
63
69
|
|
|
64
70
|
const handlePrimaryButtonClick = useCallback(
|
|
65
71
|
(text: string) => {
|
|
66
|
-
|
|
72
|
+
const newMessage: Message = {
|
|
73
|
+
id: uuid(),
|
|
74
|
+
role: MessageRole.User,
|
|
75
|
+
type: MessageType.QueryTyped,
|
|
76
|
+
createdAt: new Date().toISOString(),
|
|
77
|
+
metadata: { content: text },
|
|
78
|
+
};
|
|
79
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
67
80
|
openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_PRIMARY_BUTTON);
|
|
68
81
|
},
|
|
69
|
-
[
|
|
82
|
+
[handleReply, openChat],
|
|
70
83
|
);
|
|
71
84
|
|
|
72
85
|
const handleSecondaryButtonClick = useCallback(
|
|
73
86
|
(text: string) => {
|
|
74
|
-
|
|
87
|
+
const newMessage: Message = {
|
|
88
|
+
id: uuid(),
|
|
89
|
+
role: MessageRole.User,
|
|
90
|
+
type: MessageType.QueryTyped,
|
|
91
|
+
createdAt: new Date().toISOString(),
|
|
92
|
+
metadata: { content: text },
|
|
93
|
+
};
|
|
94
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
75
95
|
openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_SECONDARY_BUTTON);
|
|
76
96
|
},
|
|
77
|
-
[
|
|
97
|
+
[handleReply, openChat],
|
|
78
98
|
);
|
|
79
99
|
|
|
80
|
-
const handleTextFieldClick = useCallback(
|
|
81
|
-
|
|
82
|
-
|
|
100
|
+
const handleTextFieldClick = useCallback(
|
|
101
|
+
(text: string) => {
|
|
102
|
+
const newMessage: Message = {
|
|
103
|
+
id: uuid(),
|
|
104
|
+
role: MessageRole.User,
|
|
105
|
+
type: MessageType.QueryTyped,
|
|
106
|
+
createdAt: new Date().toISOString(),
|
|
107
|
+
metadata: { content: text },
|
|
108
|
+
};
|
|
109
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
110
|
+
openChat(ChatElementDisplayLocationV3.SOCIAL_PROOF_TEXT_FIELD);
|
|
111
|
+
},
|
|
112
|
+
[handleReply, openChat],
|
|
113
|
+
);
|
|
83
114
|
|
|
84
115
|
if (isLoading) {
|
|
85
116
|
return <ChatPreviewLoading fullIsLoading />;
|
|
@@ -4,8 +4,15 @@ import {
|
|
|
4
4
|
} from '@envive-ai/react-hooks/contexts/typesV3';
|
|
5
5
|
import { PromptButtonVariant } from '@envive-ai/react-toolkit-v3/PromptButton/types';
|
|
6
6
|
import { useCallback } from 'react';
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
7
|
+
import { v4 as uuid } from 'uuid';
|
|
8
|
+
import {
|
|
9
|
+
ChatElementDisplayLocationV3,
|
|
10
|
+
Message,
|
|
11
|
+
MessageRole,
|
|
12
|
+
MessageType,
|
|
13
|
+
} from '@envive-ai/react-hooks/application/models';
|
|
14
|
+
import { useSetAtom } from 'jotai';
|
|
15
|
+
import { handleReplyAtom } from '@envive-ai/react-hooks/atoms/chat/replies';
|
|
9
16
|
import { useChatToggle } from '@envive-ai/react-hooks/hooks/ChatToggle';
|
|
10
17
|
import { TitledPromptCarousel } from '@envive-ai/react-toolkit-v3/TitledPromptCarousel';
|
|
11
18
|
import { AnimationSpeed, PromptCarouselRows } from '@envive-ai/react-toolkit-v3/PromptCarousel';
|
|
@@ -22,7 +29,7 @@ const mockButtonTexts = [
|
|
|
22
29
|
const mockTitleLabel = 'Loading...';
|
|
23
30
|
|
|
24
31
|
const TitledPromptCarouselWidgetHandler = (props: BaseWidgetProps) => {
|
|
25
|
-
const
|
|
32
|
+
const handleReply = useSetAtom(handleReplyAtom);
|
|
26
33
|
const { openChat } = useChatToggle();
|
|
27
34
|
const { hardcopyContent, widgetConfig, isLoading } = props;
|
|
28
35
|
|
|
@@ -50,10 +57,17 @@ const TitledPromptCarouselWidgetHandler = (props: BaseWidgetProps) => {
|
|
|
50
57
|
|
|
51
58
|
const handleButtonClick = useCallback(
|
|
52
59
|
(text: string) => {
|
|
53
|
-
|
|
60
|
+
const newMessage: Message = {
|
|
61
|
+
id: uuid(),
|
|
62
|
+
role: MessageRole.User,
|
|
63
|
+
type: MessageType.QueryTyped,
|
|
64
|
+
createdAt: new Date().toISOString(),
|
|
65
|
+
metadata: { content: text },
|
|
66
|
+
};
|
|
67
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
54
68
|
openChat(ChatElementDisplayLocationV3.TITLED_PROMPT_CAROUSEL);
|
|
55
69
|
},
|
|
56
|
-
[
|
|
70
|
+
[handleReply, openChat],
|
|
57
71
|
);
|
|
58
72
|
|
|
59
73
|
return (
|
|
@@ -5,9 +5,15 @@ import {
|
|
|
5
5
|
import { PromptButtonVariant } from '@envive-ai/react-toolkit-v3/PromptButton/types';
|
|
6
6
|
import { WidgetWrapperVariant } from '@envive-ai/react-toolkit-v3/WidgetWrapper';
|
|
7
7
|
import { useCallback } from 'react';
|
|
8
|
-
import {
|
|
8
|
+
import { v4 as uuid } from 'uuid';
|
|
9
|
+
import {
|
|
10
|
+
ChatElementDisplayLocationV3,
|
|
11
|
+
Message,
|
|
12
|
+
MessageRole,
|
|
13
|
+
MessageType,
|
|
14
|
+
} from '@envive-ai/react-hooks/application/models';
|
|
9
15
|
import { useSetAtom } from 'jotai';
|
|
10
|
-
import {
|
|
16
|
+
import { handleReplyAtom } from '@envive-ai/react-hooks/atoms/chat/replies';
|
|
11
17
|
import { chatOnToggleAtom } from '@envive-ai/react-hooks/atoms/chat/chatState';
|
|
12
18
|
import { PromptCarouselRows } from '@envive-ai/react-toolkit-v3/PromptCarousel';
|
|
13
19
|
import { TypingAnimation } from '@envive-ai/react-toolkit-v3/TypingAnimation';
|
|
@@ -26,7 +32,7 @@ const mockAnimatedTextSequence = ['...'];
|
|
|
26
32
|
const mockHintText = 'Ask me anything';
|
|
27
33
|
|
|
28
34
|
const TypingAnimationWidgetHandler = (props: BaseWidgetProps) => {
|
|
29
|
-
const
|
|
35
|
+
const handleReply = useSetAtom(handleReplyAtom);
|
|
30
36
|
const onToggle = useSetAtom(chatOnToggleAtom);
|
|
31
37
|
|
|
32
38
|
const { hardcopyContent, widgetConfig, isLoading } = props;
|
|
@@ -56,10 +62,17 @@ const TypingAnimationWidgetHandler = (props: BaseWidgetProps) => {
|
|
|
56
62
|
|
|
57
63
|
const handleButtonClick = useCallback(
|
|
58
64
|
(text: string) => {
|
|
59
|
-
|
|
65
|
+
const newMessage: Message = {
|
|
66
|
+
id: uuid(),
|
|
67
|
+
role: MessageRole.User,
|
|
68
|
+
type: MessageType.QueryTyped,
|
|
69
|
+
createdAt: new Date().toISOString(),
|
|
70
|
+
metadata: { content: text },
|
|
71
|
+
};
|
|
72
|
+
handleReply({ message: newMessage, userTyped: false });
|
|
60
73
|
onToggle(ChatElementDisplayLocationV3.TYPING_ANIMATION);
|
|
61
74
|
},
|
|
62
|
-
[
|
|
75
|
+
[handleReply, onToggle],
|
|
63
76
|
);
|
|
64
77
|
|
|
65
78
|
const handleTextFieldClick = useCallback(() => {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts
RENAMED
|
File without changes
|
|
File without changes
|
/package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts
RENAMED
|
File without changes
|
|
File without changes
|
/package/dist/{widgets → packages/widgets}/dist/packages/hooks/dist/types/search-filter-types.d.ts
RENAMED
|
File without changes
|
|
File without changes
|