@envive-ai/react-widgets-v3 0.3.14 → 0.3.15-alpha.1
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/debug/chatEmbed.cjs +1 -1
- package/dist/debug/chatEmbed.js +1 -1
- package/dist/debug/reportIssue.cjs +1 -1
- package/dist/debug/reportIssue.js +1 -1
- package/dist/hocs/withBaseWidget/types.d.cts +3 -3
- package/dist/hocs/withBaseWidget/types.d.ts +5 -3
- package/dist/hocs/withBaseWidget/withBaseWidget.d.cts +2 -2
- package/dist/hocs/withBaseWidget/withBaseWidget.d.ts +2 -2
- package/dist/hooks/dist/application/models/api/widgetText.d.cts +8 -0
- package/dist/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.cts +12 -0
- package/dist/hooks/dist/contexts/types.d.cts +38 -0
- package/dist/hooks/dist/contexts/typesV3.d.cts +230 -0
- package/dist/hooks/dist/services/amplitudeService/eventNames.d.cts +43 -0
- package/dist/hooks/dist/types/customerService.d.cts +21 -0
- package/dist/node_modules/@spiffy-ai/commerce-api-client/dist/models/WidgetType.cjs +1 -0
- package/dist/packages/hooks/dist/application/models/api/orgConfigResults.d.ts +1 -0
- package/dist/packages/hooks/dist/application/models/api/widgetText.d.ts +8 -0
- package/dist/packages/hooks/dist/application/models/frontendConfig.d.ts +1 -0
- package/dist/packages/hooks/dist/contexts/amplitudeContext/amplitudeContext.d.ts +2 -0
- package/dist/packages/hooks/dist/contexts/amplitudeContext/index.d.ts +2 -0
- package/dist/packages/hooks/dist/contexts/featureFlagServiceContext/featureFlagServiceContext.d.ts +2 -0
- package/dist/packages/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts +14 -0
- package/dist/packages/hooks/dist/contexts/hardcopyContext/index.d.ts +1 -0
- package/dist/packages/hooks/dist/contexts/types.d.ts +42 -0
- package/dist/packages/hooks/dist/contexts/typesV3.d.ts +230 -0
- package/dist/packages/hooks/dist/services/amplitudeService/amplitudeService.d.ts +1 -0
- package/dist/packages/hooks/dist/services/amplitudeService/eventNames.d.ts +43 -0
- package/dist/packages/hooks/dist/types/customerService.d.ts +21 -0
- package/dist/packages/icons/dist/IconCloseVariant.cjs +5 -6
- package/dist/packages/icons/dist/IconCloseVariant.js +4 -6
- package/dist/packages/widgets/dist/SearchResults/SearchResults.d.ts +4 -3
- package/dist/packages/widgets/dist/SearchResults/SearchResultsWidget.d.ts +2 -2
- package/dist/packages/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.ts +2 -2
- package/dist/packages/widgets/dist/SearchZeroState/index.d.ts +2 -1
- package/dist/packages/widgets/dist/SearchZeroState/types.d.ts +2 -2
- package/dist/packages/widgets/dist/SuggestionBar/SuggestionBar.d.ts +3 -3
- package/dist/packages/widgets/dist/SuggestionButtonContainer/index.d.ts +2 -0
- package/dist/packages/widgets/dist/SuggestionButtonContainer/types.d.ts +3 -2
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/api/response.d.ts +14 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/api/search.d.ts +15 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.ts +73 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts +61 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.ts +25 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.ts +35 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.ts +32 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.ts +32 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/application/models/variantInfo/variantInfo.d.ts +1 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts +15 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/contexts/hardcopyContext/hardcopyContext.d.ts +1 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/contexts/types.d.ts +63 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts +60 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/hooks/utils.d.ts +13 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/types/OrgInfo.d.ts +1 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/types/index.d.ts +1 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/types/search-filter-types.d.ts +28 -0
- package/dist/packages/widgets/dist/packages/hooks/dist/types/test-types.d.ts +10 -0
- package/dist/src/CXIntegration/hooks/useUnifiedCXButton.d.ts +10 -0
- package/dist/src/CXIntegration/hooks/useUnifiedCXButton.js +29 -0
- package/dist/src/CXIntegration/implementations/useDefaultUnifiedCXButton.d.ts +2 -0
- package/dist/src/CXIntegration/implementations/useDefaultUnifiedCXButton.js +6 -0
- package/dist/src/CXIntegration/implementations/useEightByEightUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useEightByEightUnifiedCXButton.js +63 -0
- package/dist/src/CXIntegration/implementations/useGladlyUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useGladlyUnifiedCXButton.js +23 -0
- package/dist/src/CXIntegration/implementations/useGorgiasUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useGorgiasUnifiedCXButton.js +54 -0
- package/dist/src/CXIntegration/implementations/useGrooveUnifiedCXButton.d.ts +18 -0
- package/dist/src/CXIntegration/implementations/useGrooveUnifiedCXButton.js +48 -0
- package/dist/src/CXIntegration/implementations/useHelpScoutUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useHelpScoutUnifiedCXButton.js +84 -0
- package/dist/src/CXIntegration/implementations/useKustomerUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useKustomerUnifiedCXButton.js +86 -0
- package/dist/src/CXIntegration/implementations/useReDoUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useReDoUnifiedCXButton.js +59 -0
- package/dist/src/CXIntegration/implementations/useRichpanelUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useRichpanelUnifiedCXButton.js +62 -0
- package/dist/src/CXIntegration/implementations/useShopifyChatUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useShopifyChatUnifiedCXButton.js +49 -0
- package/dist/src/CXIntegration/implementations/useTalkdeskUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useTalkdeskUnifiedCXButton.js +77 -0
- package/dist/src/CXIntegration/implementations/useTidioUnifiedCXButton.d.ts +13 -0
- package/dist/src/CXIntegration/implementations/useTidioUnifiedCXButton.js +20 -0
- package/dist/src/CXIntegration/implementations/useZendeskUnifiedCXButton.d.ts +5 -0
- package/dist/src/CXIntegration/implementations/useZendeskUnifiedCXButton.js +55 -0
- package/dist/src/CXIntegration/implementations/useZowieUnifiedCXButton.d.ts +13 -0
- package/dist/src/CXIntegration/implementations/useZowieUnifiedCXButton.js +20 -0
- package/dist/src/CXIntegration/types.d.ts +26 -0
- package/dist/src/CXIntegration/types.js +17 -0
- package/dist/src/CXIntegration/utils/functions.d.ts +2 -0
- package/dist/src/CXIntegration/utils/functions.js +57 -0
- package/dist/src/debug/GenericSelect.d.ts +11 -0
- package/dist/src/debug/GenericSelect.js +151 -0
- package/dist/src/debug/MessageContent.d.ts +4 -0
- package/dist/src/debug/MessageContent.js +87 -0
- package/dist/src/debug/chatEmbed.d.ts +2 -0
- package/dist/src/debug/chatEmbed.js +58 -0
- package/dist/src/debug/debugBar.d.ts +1 -0
- package/dist/src/debug/debugBar.js +9 -0
- package/dist/src/debug/reportIssue.d.ts +1 -0
- package/dist/src/debug/reportIssue.js +322 -0
- package/dist/src/hocs/withBaseWidget/__tests__/withBaseWidget.test.d.ts +1 -0
- package/dist/src/hocs/withBaseWidget/__tests__/withBaseWidget.test.js +452 -0
- package/dist/src/hocs/withBaseWidget/index.d.ts +2 -0
- package/dist/src/hocs/withBaseWidget/index.js +1 -0
- package/dist/src/hocs/withBaseWidget/types.d.ts +33 -0
- package/dist/src/hocs/withBaseWidget/types.js +0 -0
- package/dist/src/hocs/withBaseWidget/withBaseWidget.d.ts +5 -0
- package/dist/src/hocs/withBaseWidget/withBaseWidget.js +80 -0
- package/dist/src/stories/FloatingChatWidget.stories.d.ts +25 -0
- package/dist/src/stories/FloatingChatWidget.stories.js +44 -0
- package/dist/src/stories/FullPageSalesAgentWidget.stories.d.ts +31 -0
- package/dist/src/stories/FullPageSalesAgentWidget.stories.js +51 -0
- package/dist/src/stories/ProductCardWidget.stories.d.ts +31 -0
- package/dist/src/stories/ProductCardWidget.stories.js +44 -0
- package/dist/src/stories/PromptButtonCarouselWithImageWidget.stories.d.ts +31 -0
- package/dist/src/stories/PromptButtonCarouselWithImageWidget.stories.js +40 -0
- package/dist/src/stories/PromptCarouselWidget.stories.d.ts +31 -0
- package/dist/src/stories/PromptCarouselWidget.stories.js +40 -0
- package/dist/src/stories/SalesAgentTest/SalesAgentTest.d.ts +1 -0
- package/dist/src/stories/SalesAgentTest/SalesAgentTest.js +40 -0
- package/dist/src/stories/SalesAgentTest/SalesAgentTest.stories.d.ts +12 -0
- package/dist/src/stories/SalesAgentTest/SalesAgentTest.stories.js +12 -0
- package/dist/src/stories/SalesAgentTest/index.d.ts +0 -0
- package/dist/src/stories/SalesAgentTest/index.js +0 -0
- package/dist/src/stories/SearchResults.stories.d.ts +6 -0
- package/dist/src/stories/SearchResults.stories.js +23 -0
- package/dist/src/stories/SearchZeroState.stories.d.ts +38 -0
- package/dist/src/stories/SearchZeroState.stories.js +42 -0
- package/dist/src/stories/SocialProofFlowWidget.stories.d.ts +35 -0
- package/dist/src/stories/SocialProofFlowWidget.stories.js +60 -0
- package/dist/src/stories/SuggestionBar.stories.d.ts +7 -0
- package/dist/src/stories/SuggestionBar.stories.js +36 -0
- package/dist/src/stories/TitledPromptCarouselWidget.stories.d.ts +32 -0
- package/dist/src/stories/TitledPromptCarouselWidget.stories.js +55 -0
- package/dist/src/stories/TypingAnimationFlowWidget.stories.d.ts +34 -0
- package/dist/src/stories/TypingAnimationFlowWidget.stories.js +51 -0
- package/dist/src/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.ts +12 -0
- package/dist/src/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js +112 -0
- package/dist/src/widgets/ChatPreviewComparisonWidget/index.d.ts +3 -0
- package/dist/src/widgets/ChatPreviewComparisonWidget/index.js +2 -0
- package/dist/src/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.ts +9 -0
- package/dist/src/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.js +34 -0
- package/dist/src/widgets/ChatPreviewLoadingWidget/index.d.ts +3 -0
- package/dist/src/widgets/ChatPreviewLoadingWidget/index.js +2 -0
- package/dist/src/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +12 -0
- package/dist/src/widgets/ChatPreviewWidget/ChatPreviewWidget.js +111 -0
- package/dist/src/widgets/ChatPreviewWidget/__tests__/ChatPreviewWidget.test.d.ts +1 -0
- package/dist/src/widgets/ChatPreviewWidget/__tests__/ChatPreviewWidget.test.js +97 -0
- package/dist/src/widgets/ChatPreviewWidget/index.d.ts +3 -0
- package/dist/src/widgets/ChatPreviewWidget/index.js +2 -0
- package/dist/src/widgets/FloatingChatWidget/FloatingChatOverlay.d.ts +14 -0
- package/dist/src/widgets/FloatingChatWidget/FloatingChatOverlay.js +44 -0
- package/dist/src/widgets/FloatingChatWidget/FloatingChatWidget.d.ts +8 -0
- package/dist/src/widgets/FloatingChatWidget/FloatingChatWidget.js +134 -0
- package/dist/src/widgets/FloatingChatWidget/__tests__/FloatingChatWidget.test.d.ts +1 -0
- package/dist/src/widgets/FloatingChatWidget/__tests__/FloatingChatWidget.test.js +100 -0
- package/dist/src/widgets/FloatingChatWidget/constants.d.ts +1 -0
- package/dist/src/widgets/FloatingChatWidget/constants.js +1 -0
- package/dist/src/widgets/FloatingChatWidget/hooks/useAutoPopup.d.ts +4 -0
- package/dist/src/widgets/FloatingChatWidget/hooks/useAutoPopup.js +51 -0
- package/dist/src/widgets/FloatingChatWidget/hooks/useFloatingButtonVisibility.d.ts +11 -0
- package/dist/src/widgets/FloatingChatWidget/hooks/useFloatingButtonVisibility.js +21 -0
- package/dist/src/widgets/FloatingChatWidget/index.d.ts +4 -0
- package/dist/src/widgets/FloatingChatWidget/index.js +3 -0
- package/dist/src/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.ts +12 -0
- package/dist/src/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.js +14 -0
- package/dist/src/widgets/FullPageSalesAgentWidget/index.d.ts +1 -0
- package/dist/src/widgets/FullPageSalesAgentWidget/index.js +1 -0
- package/dist/src/widgets/ProductCardWidget/ProductCardWidget.d.ts +7 -0
- package/dist/src/widgets/ProductCardWidget/ProductCardWidget.js +94 -0
- package/dist/src/widgets/ProductCardWidget/__tests__/ProductCardWidget.test.d.ts +1 -0
- package/dist/src/widgets/ProductCardWidget/__tests__/ProductCardWidget.test.js +106 -0
- package/dist/src/widgets/ProductCardWidget/index.d.ts +2 -0
- package/dist/src/widgets/ProductCardWidget/index.js +1 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.ts +12 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +88 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/__tests__/PromptButtonCarouselWithImageWidget.test.d.ts +1 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/__tests__/PromptButtonCarouselWithImageWidget.test.js +132 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/index.d.ts +2 -0
- package/dist/src/widgets/PromptButtonCarouselWithImageWidget/index.js +2 -0
- package/dist/src/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +7 -0
- package/dist/src/widgets/PromptCarouselWidget/PromptCarouselWidget.js +74 -0
- package/dist/src/widgets/PromptCarouselWidget/__tests__/PromptCarouselWidget.test.d.ts +1 -0
- package/dist/src/widgets/PromptCarouselWidget/__tests__/PromptCarouselWidget.test.js +106 -0
- package/dist/src/widgets/PromptCarouselWidget/index.d.ts +2 -0
- package/dist/src/widgets/PromptCarouselWidget/index.js +1 -0
- package/dist/src/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.ts +7 -0
- package/dist/src/widgets/SocialProofFlowWidget/SocialProofFlowWidget.js +25 -0
- package/dist/src/widgets/SocialProofFlowWidget/index.d.ts +3 -0
- package/dist/src/widgets/SocialProofFlowWidget/index.js +2 -0
- package/dist/src/widgets/SocialProofWidget/SocialProofWidget.d.ts +12 -0
- package/dist/src/widgets/SocialProofWidget/SocialProofWidget.js +203 -0
- package/dist/src/widgets/SocialProofWidget/__tests__/SocialProofWidget.test.d.ts +1 -0
- package/dist/src/widgets/SocialProofWidget/__tests__/SocialProofWidget.test.js +135 -0
- package/dist/src/widgets/SocialProofWidget/index.d.ts +2 -0
- package/dist/src/widgets/SocialProofWidget/index.js +1 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +7 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +75 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/__tests__/TitledPromptCarouselWidget.test.d.ts +1 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/__tests__/TitledPromptCarouselWidget.test.js +106 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/index.d.ts +2 -0
- package/dist/src/widgets/TitledPromptCarouselWidget/index.js +1 -0
- package/dist/src/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts +7 -0
- package/dist/src/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.js +25 -0
- package/dist/src/widgets/TypingAnimationFlowWidget/index.d.ts +3 -0
- package/dist/src/widgets/TypingAnimationFlowWidget/index.js +2 -0
- package/dist/src/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts +12 -0
- package/dist/src/widgets/TypingAnimationWidget/TypingAnimationWidget.js +126 -0
- package/dist/src/widgets/TypingAnimationWidget/__tests__/TypingAnimationWidget.test.d.ts +1 -0
- package/dist/src/widgets/TypingAnimationWidget/__tests__/TypingAnimationWidget.test.js +118 -0
- package/dist/src/widgets/TypingAnimationWidget/index.d.ts +2 -0
- package/dist/src/widgets/TypingAnimationWidget/index.js +1 -0
- package/dist/src/widgets/__tests__/testUtils.d.ts +60 -0
- package/dist/src/widgets/__tests__/testUtils.js +46 -0
- package/dist/src/widgets/__tests__/trackEventCanary.test.d.ts +1 -0
- package/dist/src/widgets/__tests__/trackEventCanary.test.js +37 -0
- package/dist/src/widgets/hooks/useGetWidgetStatus.d.ts +7 -0
- package/dist/src/widgets/hooks/useGetWidgetStatus.js +17 -0
- package/dist/src/widgets/utils/functions.d.ts +16 -0
- package/dist/src/widgets/utils/functions.js +87 -0
- package/dist/src/widgets-v2/SearchResults/index.d.ts +2 -0
- package/dist/src/widgets-v2/SearchResults/index.js +2 -0
- package/dist/src/widgets-v2/SearchZeroState/index.d.ts +2 -0
- package/dist/src/widgets-v2/SearchZeroState/index.js +2 -0
- package/dist/src/widgets-v2/SuggestionBar/index.d.ts +2 -0
- package/dist/src/widgets-v2/SuggestionBar/index.js +2 -0
- package/dist/src/widgets-v2/SuggestionButtonContainer/index.d.ts +2 -0
- package/dist/src/widgets-v2/SuggestionButtonContainer/index.js +2 -0
- package/dist/tsdown.config.d.ts +2 -0
- package/dist/tsdown.config.js +12 -0
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.cjs +36 -5
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.js +36 -5
- package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.cts +3 -3
- package/dist/widgets/ChatPreviewLoadingWidget/ChatPreviewLoadingWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.cjs +34 -4
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.cts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.d.ts +3 -3
- package/dist/widgets/ChatPreviewWidget/ChatPreviewWidget.js +35 -5
- package/dist/widgets/FloatingChatWidget/FloatingChatOverlay.cjs +0 -2
- package/dist/widgets/FloatingChatWidget/FloatingChatOverlay.js +0 -2
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.cjs +31 -7
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.d.cts +2 -2
- package/dist/widgets/FloatingChatWidget/FloatingChatWidget.js +32 -8
- package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.cts +2 -2
- package/dist/widgets/FullPageSalesAgentWidget/FullPageSalesAgentWidget.d.ts +2 -2
- package/dist/widgets/ProductCardWidget/ProductCardWidget.cjs +25 -3
- package/dist/widgets/ProductCardWidget/ProductCardWidget.d.cts +2 -2
- package/dist/widgets/ProductCardWidget/ProductCardWidget.d.ts +2 -2
- package/dist/widgets/ProductCardWidget/ProductCardWidget.js +25 -3
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.cjs +23 -4
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.cts +3 -3
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.d.ts +3 -3
- package/dist/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.js +23 -4
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.cjs +15 -3
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.cts +2 -2
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.d.ts +2 -2
- package/dist/widgets/PromptCarouselWidget/PromptCarouselWidget.js +17 -5
- package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.cts +2 -2
- package/dist/widgets/SocialProofFlowWidget/SocialProofFlowWidget.d.ts +2 -2
- package/dist/widgets/SocialProofWidget/SocialProofWidget.cjs +53 -6
- package/dist/widgets/SocialProofWidget/SocialProofWidget.d.ts +3 -3
- package/dist/widgets/SocialProofWidget/SocialProofWidget.js +54 -7
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.cjs +10 -1
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.cts +2 -2
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.d.ts +2 -2
- package/dist/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.js +11 -2
- package/dist/widgets/TypingAnimationFlowWidget/TypingAnimationFlowWidget.d.ts +2 -2
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.cjs +24 -3
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.cts +3 -3
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.d.ts +3 -3
- package/dist/widgets/TypingAnimationWidget/TypingAnimationWidget.js +25 -4
- package/dist/widgets/dist/SearchResults/SearchResults.d.cts +4 -3
- package/dist/widgets/dist/SearchResults/SearchResultsWidget.d.cts +2 -2
- package/dist/widgets/dist/SearchZeroState/SearchZeroStateWidget.d.cts +2 -2
- package/dist/widgets/dist/SearchZeroState/types.d.cts +2 -2
- package/dist/widgets/dist/SuggestionBar/SuggestionBar.d.cts +3 -3
- package/dist/widgets/dist/SuggestionButtonContainer/types.d.cts +3 -2
- package/dist/widgets/dist/packages/hooks/dist/application/models/api/response.d.cts +14 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/api/search.d.cts +15 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.cts +73 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.cts +61 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.cts +25 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.cts +35 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.cts +32 -0
- package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.cts +32 -0
- package/dist/widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.cts +14 -0
- package/dist/widgets/dist/packages/hooks/dist/contexts/types.d.cts +61 -0
- package/dist/widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.cts +60 -0
- package/dist/widgets/dist/packages/hooks/dist/hooks/utils.d.cts +12 -0
- package/dist/widgets/dist/packages/hooks/dist/types/search-filter-types.d.cts +28 -0
- package/dist/widgets/dist/packages/hooks/dist/types/test-types.d.cts +10 -0
- package/dist/widgets/hooks/useGetWidgetStatus.cjs +1 -1
- package/dist/widgets/hooks/useGetWidgetStatus.js +1 -1
- package/dist/widgets/utils/functions.cjs +0 -14
- package/dist/widgets/utils/functions.js +1 -14
- package/dist/widgets-v2/SearchZeroState/index.d.cts +2 -1
- package/dist/widgets-v2/SearchZeroState/index.d.ts +2 -1
- package/dist/widgets-v2/SuggestionButtonContainer/index.d.ts +1 -0
- package/package.json +4 -4
- package/src/hocs/withBaseWidget/__tests__/withBaseWidget.test.tsx +68 -302
- package/src/hocs/withBaseWidget/types.ts +6 -6
- package/src/hocs/withBaseWidget/withBaseWidget.tsx +46 -61
- package/src/widgets/ChatPreviewComparisonWidget/ChatPreviewComparisonWidget.tsx +59 -8
- package/src/widgets/ChatPreviewWidget/ChatPreviewWidget.tsx +54 -18
- package/src/widgets/ChatPreviewWidget/__tests__/ChatPreviewWidget.test.tsx +11 -5
- package/src/widgets/FloatingChatWidget/FloatingChatOverlay.tsx +48 -19
- package/src/widgets/FloatingChatWidget/FloatingChatWidget.tsx +100 -52
- package/src/widgets/FloatingChatWidget/__tests__/FloatingChatWidget.test.tsx +11 -5
- package/src/widgets/ProductCardWidget/ProductCardWidget.tsx +37 -16
- package/src/widgets/ProductCardWidget/__tests__/ProductCardWidget.test.tsx +12 -8
- package/src/widgets/PromptButtonCarouselWithImageWidget/PromptButtonCarouselWithImageWidget.tsx +38 -19
- package/src/widgets/PromptButtonCarouselWithImageWidget/__tests__/PromptButtonCarouselWithImageWidget.test.tsx +19 -8
- package/src/widgets/PromptCarouselWidget/PromptCarouselWidget.tsx +32 -19
- package/src/widgets/PromptCarouselWidget/__tests__/PromptCarouselWidget.test.tsx +21 -8
- package/src/widgets/SocialProofWidget/SocialProofWidget.tsx +77 -18
- package/src/widgets/SocialProofWidget/__tests__/SocialProofWidget.test.tsx +19 -8
- package/src/widgets/TitledPromptCarouselWidget/TitledPromptCarouselWidget.tsx +23 -19
- package/src/widgets/TitledPromptCarouselWidget/__tests__/TitledPromptCarouselWidget.test.tsx +19 -8
- package/src/widgets/TypingAnimationWidget/TypingAnimationWidget.tsx +45 -21
- package/src/widgets/TypingAnimationWidget/__tests__/TypingAnimationWidget.test.tsx +19 -8
- package/src/widgets/__tests__/trackEventCanary.test.ts +1 -1
- package/dist/packages/icons/dist/_virtual/rolldown_runtime.cjs +0 -27
- package/dist/packages/icons/dist/_virtual/rolldown_runtime.js +0 -25
- package/dist/packages/icons/dist/node_modules/react/cjs/react-jsx-runtime.development.cjs +0 -696
- package/dist/packages/icons/dist/node_modules/react/cjs/react-jsx-runtime.development.js +0 -696
- package/dist/packages/icons/dist/node_modules/react/cjs/react-jsx-runtime.production.min.cjs +0 -43
- package/dist/packages/icons/dist/node_modules/react/cjs/react-jsx-runtime.production.min.js +0 -43
- package/dist/packages/icons/dist/node_modules/react/cjs/react.development.cjs +0 -1528
- package/dist/packages/icons/dist/node_modules/react/cjs/react.development.js +0 -1528
- package/dist/packages/icons/dist/node_modules/react/cjs/react.production.min.cjs +0 -329
- package/dist/packages/icons/dist/node_modules/react/cjs/react.production.min.js +0 -329
- package/dist/packages/icons/dist/node_modules/react/index.cjs +0 -13
- package/dist/packages/icons/dist/node_modules/react/index.js +0 -13
- package/dist/packages/icons/dist/node_modules/react/jsx-runtime.cjs +0 -13
- package/dist/packages/icons/dist/node_modules/react/jsx-runtime.js +0 -13
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CamelCasedPropertiesDeep } from "../utilityTypes/camelCasedPropertiesDeep.cjs";
|
|
2
|
+
import { ResponseCategory, SearchResponseProduct } from "@spiffy-ai/commerce-api-client";
|
|
3
|
+
|
|
4
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/api/response.d.ts
|
|
5
|
+
|
|
6
|
+
//#region ../hooks/dist/application/models/api/response.d.ts
|
|
7
|
+
interface SearchResponseProductAttributes {
|
|
8
|
+
category: ResponseCategory.Product;
|
|
9
|
+
attributes: CamelCasedPropertiesDeep<SearchResponseProduct>;
|
|
10
|
+
}
|
|
11
|
+
//#endregion
|
|
12
|
+
|
|
13
|
+
//#endregion
|
|
14
|
+
export { SearchResponseProductAttributes };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { SearchResponseProduct } from "@spiffy-ai/commerce-api-client";
|
|
2
|
+
|
|
3
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/api/search.d.ts
|
|
4
|
+
|
|
5
|
+
//#region ../hooks/dist/application/models/api/search.d.ts
|
|
6
|
+
interface SearchResult {
|
|
7
|
+
products: SearchResponseProduct[];
|
|
8
|
+
filters: string[];
|
|
9
|
+
generatedQuery?: string;
|
|
10
|
+
totalProductCount: number;
|
|
11
|
+
searchResponseId: string;
|
|
12
|
+
}
|
|
13
|
+
//#endregion
|
|
14
|
+
//#endregion
|
|
15
|
+
export { SearchResult };
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { SplitWords } from "./splitWords.cjs";
|
|
2
|
+
|
|
3
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCase.d.ts
|
|
4
|
+
|
|
5
|
+
//#region ../hooks/dist/application/models/utilityTypes/camelCase.d.ts
|
|
6
|
+
//#region src/application/models/utilityTypes/camelCase.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* CamelCase options.
|
|
9
|
+
*
|
|
10
|
+
* @see {@link CamelCase}
|
|
11
|
+
*/
|
|
12
|
+
type CamelCaseOptions = {
|
|
13
|
+
/**
|
|
14
|
+
* Whether to preserved consecutive uppercase letter.
|
|
15
|
+
*
|
|
16
|
+
* @default true
|
|
17
|
+
*/
|
|
18
|
+
preserveConsecutiveUppercase?: boolean;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* Convert an array of words to camel-case.
|
|
22
|
+
*/
|
|
23
|
+
type CamelCaseFromArray<Words extends string[], Options extends CamelCaseOptions, OutputString extends string = ''> = Words extends [infer FirstWord extends string, ...infer RemainingWords extends string[]] ? Options['preserveConsecutiveUppercase'] extends true ? `${Capitalize<FirstWord>}${CamelCaseFromArray<RemainingWords, Options>}` : `${Capitalize<Lowercase<FirstWord>>}${CamelCaseFromArray<RemainingWords, Options>}` : OutputString;
|
|
24
|
+
/**
|
|
25
|
+
* Convert a string literal to camel-case.
|
|
26
|
+
*
|
|
27
|
+
* This can be useful when, for example, converting some kebab-cased command-line flags or a snake-cased database result.
|
|
28
|
+
*
|
|
29
|
+
* By default, consecutive uppercase letter are preserved. See {@link CamelCaseOptions.preserveConsecutiveUppercase preserveConsecutiveUppercase} option to change this behaviour.
|
|
30
|
+
*
|
|
31
|
+
* @example
|
|
32
|
+
* ```
|
|
33
|
+
* import type {CamelCase} from 'type-fest';
|
|
34
|
+
*
|
|
35
|
+
* // Simple
|
|
36
|
+
*
|
|
37
|
+
* const someVariable: CamelCase<'foo-bar'> = 'fooBar';
|
|
38
|
+
*
|
|
39
|
+
* // Advanced
|
|
40
|
+
*
|
|
41
|
+
* type CamelCasedProperties<T> = {
|
|
42
|
+
* [K in keyof T as CamelCase<K>]: T[K]
|
|
43
|
+
* };
|
|
44
|
+
*
|
|
45
|
+
* interface RawOptions {
|
|
46
|
+
* 'dry-run': boolean;
|
|
47
|
+
* 'full_family_name': string;
|
|
48
|
+
* foo: number;
|
|
49
|
+
* BAR: string;
|
|
50
|
+
* QUZ_QUX: number;
|
|
51
|
+
* 'OTHER-FIELD': boolean;
|
|
52
|
+
* }
|
|
53
|
+
*
|
|
54
|
+
* const dbResult: CamelCasedProperties<RawOptions> = {
|
|
55
|
+
* dryRun: true,
|
|
56
|
+
* fullFamilyName: 'bar.js',
|
|
57
|
+
* foo: 123,
|
|
58
|
+
* bar: 'foo',
|
|
59
|
+
* quzQux: 6,
|
|
60
|
+
* otherField: false
|
|
61
|
+
* };
|
|
62
|
+
* ```
|
|
63
|
+
*
|
|
64
|
+
* @category Change case
|
|
65
|
+
* @category Template literal
|
|
66
|
+
*/
|
|
67
|
+
type CamelCase<Type, Options extends CamelCaseOptions = {
|
|
68
|
+
preserveConsecutiveUppercase: true;
|
|
69
|
+
}> = Type extends string ? string extends Type ? Type : Uncapitalize<CamelCaseFromArray<SplitWords<Type extends Uppercase<Type> ? Lowercase<Type> : Type>, Options>> : Type;
|
|
70
|
+
//#endregion
|
|
71
|
+
//#endregion
|
|
72
|
+
//#endregion
|
|
73
|
+
export { CamelCase, CamelCaseOptions };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { CamelCase, CamelCaseOptions } from "./camelCase.cjs";
|
|
2
|
+
import { UnknownArray } from "./unknownArray.cjs";
|
|
3
|
+
|
|
4
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts
|
|
5
|
+
|
|
6
|
+
//#region ../hooks/dist/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts
|
|
7
|
+
//#region src/application/models/utilityTypes/camelCasedPropertiesDeep.d.ts
|
|
8
|
+
/**
|
|
9
|
+
* Convert object properties to camel case recursively.
|
|
10
|
+
*
|
|
11
|
+
* This can be useful when, for example, converting some API types from a different style.
|
|
12
|
+
*
|
|
13
|
+
* @see CamelCasedProperties
|
|
14
|
+
* @see CamelCase
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```
|
|
18
|
+
* import type {CamelCasedPropertiesDeep} from 'type-fest';
|
|
19
|
+
*
|
|
20
|
+
* interface User {
|
|
21
|
+
* UserId: number;
|
|
22
|
+
* UserName: string;
|
|
23
|
+
* }
|
|
24
|
+
*
|
|
25
|
+
* interface UserWithFriends {
|
|
26
|
+
* UserInfo: User;
|
|
27
|
+
* UserFriends: User[];
|
|
28
|
+
* }
|
|
29
|
+
*
|
|
30
|
+
* const result: CamelCasedPropertiesDeep<UserWithFriends> = {
|
|
31
|
+
* userInfo: {
|
|
32
|
+
* userId: 1,
|
|
33
|
+
* userName: 'Tom',
|
|
34
|
+
* },
|
|
35
|
+
* userFriends: [
|
|
36
|
+
* {
|
|
37
|
+
* userId: 2,
|
|
38
|
+
* userName: 'Jerry',
|
|
39
|
+
* },
|
|
40
|
+
* {
|
|
41
|
+
* userId: 3,
|
|
42
|
+
* userName: 'Spike',
|
|
43
|
+
* },
|
|
44
|
+
* ],
|
|
45
|
+
* };
|
|
46
|
+
* ```
|
|
47
|
+
*
|
|
48
|
+
* @category Change case
|
|
49
|
+
* @category Template literal
|
|
50
|
+
* @category Object
|
|
51
|
+
*/
|
|
52
|
+
type CamelCasedPropertiesDeep<Value, Options extends CamelCaseOptions = {
|
|
53
|
+
preserveConsecutiveUppercase: true;
|
|
54
|
+
}> = Value extends Function ? Value : Value extends UnknownArray ? CamelCasedPropertiesArrayDeep<Value> : Value extends Set<infer U> ? Set<CamelCasedPropertiesDeep<U, Options>> : { [K in keyof Value as CamelCase<K, Options>]: CamelCasedPropertiesDeep<Value[K], Options> };
|
|
55
|
+
type CamelCasedPropertiesArrayDeep<Value extends UnknownArray> = Value extends [] ? [] : Value extends [infer U, ...infer V] ? [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>] : Value extends readonly [infer U, ...infer V] ? readonly [CamelCasedPropertiesDeep<U>, ...CamelCasedPropertiesDeep<V>] : Value extends readonly [...infer U, infer V] ? [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>] : Value extends readonly [...infer U, infer V] ? readonly [...CamelCasedPropertiesDeep<U>, CamelCasedPropertiesDeep<V>] : Value extends Array<infer U> ? Array<CamelCasedPropertiesDeep<U>> : Value extends ReadonlyArray<infer U> ? ReadonlyArray<CamelCasedPropertiesDeep<U>> : never;
|
|
56
|
+
//#endregion
|
|
57
|
+
|
|
58
|
+
//#endregion
|
|
59
|
+
|
|
60
|
+
//#endregion
|
|
61
|
+
export { CamelCasedPropertiesDeep };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Trim } from "./trim.cjs";
|
|
2
|
+
|
|
3
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/internal.d.ts
|
|
4
|
+
|
|
5
|
+
//#region ../hooks/dist/application/models/utilityTypes/internal.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Returns a boolean for whether the string is numeric.
|
|
8
|
+
*
|
|
9
|
+
* This type is a workaround for [Microsoft/TypeScript#46109](https://github.com/microsoft/TypeScript/issues/46109#issuecomment-930307987).
|
|
10
|
+
*/
|
|
11
|
+
type IsNumeric<T extends string> = T extends `${number}` ? Trim<T> extends T ? true : false : false;
|
|
12
|
+
/**
|
|
13
|
+
* Returns a boolean for whether the string is lowercased.
|
|
14
|
+
*/
|
|
15
|
+
type IsLowerCase<T extends string> = T extends Lowercase<T> ? true : false;
|
|
16
|
+
/**
|
|
17
|
+
* Returns a boolean for whether the string is upper-cased.
|
|
18
|
+
*/
|
|
19
|
+
type IsUpperCase<T extends string> = T extends Uppercase<T> ? true : false;
|
|
20
|
+
type WordSeparators = '-' | '_' | Whitespace;
|
|
21
|
+
type Whitespace = '\u{9}' | '\u{A}' | '\u{B}' | '\u{C}' | '\u{D}' | '\u{20}' | '\u{85}' | '\u{A0}' | '\u{1680}' | '\u{2000}' | '\u{2001}' | '\u{2002}' | '\u{2003}' | '\u{2004}' | '\u{2005}' | '\u{2006}' | '\u{2007}' | '\u{2008}' | '\u{2009}' | '\u{200A}' | '\u{2028}' | '\u{2029}' | '\u{202F}' | '\u{205F}' | '\u{3000}' | '\u{FEFF}';
|
|
22
|
+
//#endregion
|
|
23
|
+
|
|
24
|
+
//#endregion
|
|
25
|
+
export { IsLowerCase, IsNumeric, IsUpperCase, Whitespace, WordSeparators };
|
package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.cts
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { IsLowerCase, IsNumeric, IsUpperCase, WordSeparators } from "./internal.cjs";
|
|
2
|
+
|
|
3
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/splitWords.d.ts
|
|
4
|
+
|
|
5
|
+
//#region ../hooks/dist/application/models/utilityTypes/splitWords.d.ts
|
|
6
|
+
//#region src/application/models/utilityTypes/splitWords.d.ts
|
|
7
|
+
type SkipEmptyWord<Word extends string> = Word extends '' ? [] : [Word];
|
|
8
|
+
type RemoveLastCharacter<Sentence extends string, Character extends string> = Sentence extends `${infer LeftSide}${Character}` ? SkipEmptyWord<LeftSide> : never;
|
|
9
|
+
/**
|
|
10
|
+
* Split a string (almost) like Lodash's `_.words()` function.
|
|
11
|
+
*
|
|
12
|
+
* - Split on each word that begins with a capital letter.
|
|
13
|
+
* - Split on each {@link WordSeparators}.
|
|
14
|
+
* - Split on numeric sequence.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```
|
|
18
|
+
* type Words0 = SplitWords<'helloWorld'>; // ['hello', 'World']
|
|
19
|
+
* type Words1 = SplitWords<'helloWORLD'>; // ['hello', 'WORLD']
|
|
20
|
+
* type Words2 = SplitWords<'hello-world'>; // ['hello', 'world']
|
|
21
|
+
* type Words3 = SplitWords<'--hello the_world'>; // ['hello', 'the', 'world']
|
|
22
|
+
* type Words4 = SplitWords<'lifeIs42'>; // ['life', 'Is', '42']
|
|
23
|
+
* ```
|
|
24
|
+
*
|
|
25
|
+
* @internal
|
|
26
|
+
* @category Change case
|
|
27
|
+
* @category Template literal
|
|
28
|
+
*/
|
|
29
|
+
type SplitWords<Sentence extends string, LastCharacter extends string = '', CurrentWord extends string = ''> = Sentence extends `${infer FirstCharacter}${infer RemainingCharacters}` ? FirstCharacter extends WordSeparators ? [...SkipEmptyWord<CurrentWord>, ...SplitWords<RemainingCharacters>] : LastCharacter extends '' ? SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter> : [false, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>] ? [...SkipEmptyWord<CurrentWord>, ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>] : [true, false] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>] ? [...SkipEmptyWord<CurrentWord>, ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>] : [true, true] extends [IsNumeric<LastCharacter>, IsNumeric<FirstCharacter>] ? SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`> : [true, true] extends [IsLowerCase<LastCharacter>, IsUpperCase<FirstCharacter>] ? [...SkipEmptyWord<CurrentWord>, ...SplitWords<RemainingCharacters, FirstCharacter, FirstCharacter>] : [true, true] extends [IsUpperCase<LastCharacter>, IsLowerCase<FirstCharacter>] ? [...RemoveLastCharacter<CurrentWord, LastCharacter>, ...SplitWords<RemainingCharacters, FirstCharacter, `${LastCharacter}${FirstCharacter}`>] : SplitWords<RemainingCharacters, FirstCharacter, `${CurrentWord}${FirstCharacter}`> : [...SkipEmptyWord<CurrentWord>];
|
|
30
|
+
//#endregion
|
|
31
|
+
|
|
32
|
+
//#endregion
|
|
33
|
+
|
|
34
|
+
//#endregion
|
|
35
|
+
export { SplitWords };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Whitespace } from "./internal.cjs";
|
|
2
|
+
|
|
3
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/trim.d.ts
|
|
4
|
+
|
|
5
|
+
//#region ../hooks/dist/application/models/utilityTypes/trim.d.ts
|
|
6
|
+
//#region src/application/models/utilityTypes/trim.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* Remove spaces from the left side.
|
|
9
|
+
*/
|
|
10
|
+
type TrimLeft<V extends string> = V extends `${Whitespace}${infer R}` ? TrimLeft<R> : V;
|
|
11
|
+
/**
|
|
12
|
+
* Remove spaces from the right side.
|
|
13
|
+
*/
|
|
14
|
+
type TrimRight<V extends string> = V extends `${infer R}${Whitespace}` ? TrimRight<R> : V;
|
|
15
|
+
/**
|
|
16
|
+
* Remove leading and trailing spaces from a string.
|
|
17
|
+
* @example
|
|
18
|
+
* ```
|
|
19
|
+
* import type {Trim} from 'type-fest';
|
|
20
|
+
*
|
|
21
|
+
* Trim<' foo '>
|
|
22
|
+
* //=> 'foo'
|
|
23
|
+
* ```
|
|
24
|
+
*
|
|
25
|
+
* @category String
|
|
26
|
+
* @category Template literal
|
|
27
|
+
*/
|
|
28
|
+
type Trim<V extends string> = TrimLeft<TrimRight<V>>;
|
|
29
|
+
//#endregion
|
|
30
|
+
//#endregion
|
|
31
|
+
//#endregion
|
|
32
|
+
export { Trim };
|
package/dist/widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.cts
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/application/models/utilityTypes/unknownArray.d.ts
|
|
2
|
+
//#region ../hooks/dist/application/models/utilityTypes/unknownArray.d.ts
|
|
3
|
+
//#region src/application/models/utilityTypes/unknownArray.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* Represents an array with `unknown` value.
|
|
6
|
+
*
|
|
7
|
+
* Use case: You want a type that all arrays can be assigned to, but you don't care about the value.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```
|
|
11
|
+
* import type {UnknownArray} from 'type-fest';
|
|
12
|
+
*
|
|
13
|
+
* type IsArray<T> = T extends UnknownArray ? true : false;
|
|
14
|
+
*
|
|
15
|
+
* type A = IsArray<['foo']>;
|
|
16
|
+
* //=> true
|
|
17
|
+
*
|
|
18
|
+
* type B = IsArray<readonly number[]>;
|
|
19
|
+
* //=> true
|
|
20
|
+
*
|
|
21
|
+
* type C = IsArray<string>;
|
|
22
|
+
* //=> false
|
|
23
|
+
* ```
|
|
24
|
+
*
|
|
25
|
+
* @category Type
|
|
26
|
+
* @category Array
|
|
27
|
+
*/
|
|
28
|
+
type UnknownArray = readonly unknown[];
|
|
29
|
+
//#endregion
|
|
30
|
+
//#endregion
|
|
31
|
+
//#endregion
|
|
32
|
+
export { UnknownArray };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/atoms/search/searchAPI.d.ts
|
|
2
|
+
|
|
3
|
+
//#region ../hooks/dist/atoms/search/searchAPI.d.ts
|
|
4
|
+
|
|
5
|
+
//#region src/atoms/search/searchAPI.d.ts
|
|
6
|
+
type SelectedFilterOption = {
|
|
7
|
+
id: string;
|
|
8
|
+
displayName: string;
|
|
9
|
+
filterId: string;
|
|
10
|
+
filterItemId: string;
|
|
11
|
+
};
|
|
12
|
+
//#endregion
|
|
13
|
+
//#endregion
|
|
14
|
+
export { SelectedFilterOption };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/contexts/types.d.ts
|
|
2
|
+
|
|
3
|
+
type ProductCardVariant = 'filled' | 'bordered' | 'minimal' | 'transparentBordered';
|
|
4
|
+
type ProductCardHoverVariant = 'backgroundDark' | 'none';
|
|
5
|
+
type ProductCardLayoutVariant = 'normal' | 'tall' | 'square';
|
|
6
|
+
interface ProductCardConfig {
|
|
7
|
+
variant: ProductCardVariant;
|
|
8
|
+
hoverVariant: ProductCardHoverVariant;
|
|
9
|
+
layoutVariant: ProductCardLayoutVariant;
|
|
10
|
+
pricePrefix?: string;
|
|
11
|
+
}
|
|
12
|
+
type SuggestionButtonVariant = 'outlined' | 'outlinedLight' | 'primary' | 'secondary' | 'tertiary' | 'dark' | 'darkAccent' | 'darkPrimary' | 'secondaryDark' | 'secondaryAccent' | 'transparent' | 'transparentDark' | 'lightDark';
|
|
13
|
+
interface SuggestionButtonConfig {
|
|
14
|
+
variant?: SuggestionButtonVariant;
|
|
15
|
+
hoverVariant?: SuggestionButtonVariant;
|
|
16
|
+
answerVariant?: SuggestionButtonVariant;
|
|
17
|
+
borderRadius?: 'sm' | 'md' | 'lg';
|
|
18
|
+
}
|
|
19
|
+
type SearchZeroStateVariant = 'backgroundTertiary' | 'backgroundDark' | 'backgroundPrimary';
|
|
20
|
+
type SearchZeroStateLayout = 'input' | 'icon';
|
|
21
|
+
type SearchInputVariant = 'standard';
|
|
22
|
+
type SearchIconVariant = 'thin' | 'bold';
|
|
23
|
+
declare enum WidgetType {
|
|
24
|
+
ChatPreview = "ChatPreview",
|
|
25
|
+
SocialProofV2 = "SocialProofV2",
|
|
26
|
+
ChatPreviewV2 = "ChatPreviewV2",
|
|
27
|
+
ChatPreviewIsLoading = "ChatPreviewIsLoading",
|
|
28
|
+
ChatPreviewPostInteraction = "ChatPreviewPostInteraction",
|
|
29
|
+
ChatPreviewProductComparison = "ChatPreviewProductComparison",
|
|
30
|
+
SuggestionBar = "SuggestionBar",
|
|
31
|
+
SuggestionBarV2 = "SuggestionBarV2",
|
|
32
|
+
ImagePromptCard = "ImagePromptCard",
|
|
33
|
+
ImageBanner = "ImageBanner",
|
|
34
|
+
SingleImagePrompt = "SingleImagePrompt",
|
|
35
|
+
SearchPrompt = "SearchPrompt",
|
|
36
|
+
SearchZeroStateEntryPoint = "SearchZeroStateEntryPoint",
|
|
37
|
+
SearchResultsEntryPoint = "SearchResultsEntryPoint",
|
|
38
|
+
SearchOverlayHost = "SearchOverlayHost",
|
|
39
|
+
NoOp = "NoOp",
|
|
40
|
+
}
|
|
41
|
+
interface BaseWidgetConfig<T extends WidgetType> {
|
|
42
|
+
widgetConfigId: string;
|
|
43
|
+
type: T;
|
|
44
|
+
contentId?: string;
|
|
45
|
+
}
|
|
46
|
+
interface SearchEntryPointWidgetConfig extends BaseWidgetConfig<WidgetType.SearchZeroStateEntryPoint> {
|
|
47
|
+
searchZeroStateVariant: SearchZeroStateVariant;
|
|
48
|
+
searchInputVariant: SearchInputVariant;
|
|
49
|
+
searchIconVariant?: SearchIconVariant;
|
|
50
|
+
searchIconSize?: number;
|
|
51
|
+
suggestionButtonConfig: SuggestionButtonConfig;
|
|
52
|
+
layout: SearchZeroStateLayout;
|
|
53
|
+
searchBoxPlaceholder: string;
|
|
54
|
+
animationSpeed?: 'standard' | 'slow' | 'none';
|
|
55
|
+
compactLabel?: string;
|
|
56
|
+
initialSuggestions?: string[];
|
|
57
|
+
usingPortal?: boolean;
|
|
58
|
+
includeSubtitle?: boolean;
|
|
59
|
+
}
|
|
60
|
+
//#endregion
|
|
61
|
+
export { type ProductCardConfig, type SearchEntryPointWidgetConfig, SearchInputVariant, type SuggestionButtonVariant };
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { SearchResponseProductAttributes } from "../../application/models/api/response.cjs";
|
|
2
|
+
import { ProductCardConfig } from "../../contexts/types.cjs";
|
|
3
|
+
import { SearchResult } from "../../application/models/api/search.cjs";
|
|
4
|
+
import { SelectedFilterOption } from "../../atoms/search/searchAPI.cjs";
|
|
5
|
+
import { SearchFilterDatum, SelectFilterItem } from "../../types/search-filter-types.cjs";
|
|
6
|
+
import { SearchResultsState } from "../utils.cjs";
|
|
7
|
+
import { SearchResponseProduct } from "@spiffy-ai/commerce-api-client";
|
|
8
|
+
|
|
9
|
+
//#region ../widgets/dist/packages/hooks/dist/hooks/Search/useSearch.d.ts
|
|
10
|
+
|
|
11
|
+
//#region ../hooks/dist/hooks/Search/useSearch.d.ts
|
|
12
|
+
//#region src/hooks/Search/useSearch.d.ts
|
|
13
|
+
interface SearchResultsHocProps {
|
|
14
|
+
searchData: SearchResult | null;
|
|
15
|
+
searchResponseId: string;
|
|
16
|
+
merchantShortName: string;
|
|
17
|
+
productCardConfig: ProductCardConfig;
|
|
18
|
+
productList: SearchResponseProduct[];
|
|
19
|
+
autocompleteResults: string[];
|
|
20
|
+
searchFilters: SearchFilterDatum[];
|
|
21
|
+
availableDynamicFilters: {
|
|
22
|
+
name: string;
|
|
23
|
+
displayName: string;
|
|
24
|
+
}[];
|
|
25
|
+
selectedFilterOptions: SelectedFilterOption[];
|
|
26
|
+
recommendedProducts: SearchResponseProductAttributes['attributes'][];
|
|
27
|
+
recommendedProductsHeading: string;
|
|
28
|
+
searchOverlayHeading: string;
|
|
29
|
+
searchText: string;
|
|
30
|
+
query: string;
|
|
31
|
+
searchResultsState: SearchResultsState;
|
|
32
|
+
isLoadingSearch: boolean;
|
|
33
|
+
isFilterOpen: boolean;
|
|
34
|
+
shouldShowAutocomplete: boolean;
|
|
35
|
+
focusedIndex: number;
|
|
36
|
+
focusedOptionId: string | undefined;
|
|
37
|
+
filterButtonText: string;
|
|
38
|
+
onSearchInputChange: (value: string) => void;
|
|
39
|
+
onSubmitSearch: () => void;
|
|
40
|
+
onAutocompleteSelect: (suggestion: string) => void;
|
|
41
|
+
onKeyDown: (event: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
42
|
+
onSearchInputFocus: () => void;
|
|
43
|
+
onSearchInputBlur: () => void;
|
|
44
|
+
onToggleDynamicFilter: ({
|
|
45
|
+
filter,
|
|
46
|
+
dynamicFilterDisplayName
|
|
47
|
+
}: {
|
|
48
|
+
filter: string;
|
|
49
|
+
dynamicFilterDisplayName: string;
|
|
50
|
+
}) => void;
|
|
51
|
+
onSelectFilterItem: SelectFilterItem;
|
|
52
|
+
onRemoveFilter: (filter: SelectedFilterOption) => void;
|
|
53
|
+
onClearAllFilters: () => void;
|
|
54
|
+
setIsFilterOpen: (isFilterOpen: boolean) => void;
|
|
55
|
+
resetSearch: () => void;
|
|
56
|
+
searchResultsRef: React.RefObject<HTMLDivElement>;
|
|
57
|
+
}
|
|
58
|
+
//#endregion
|
|
59
|
+
//#endregion
|
|
60
|
+
export { SearchResultsHocProps };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/hooks/utils.d.ts
|
|
2
|
+
|
|
3
|
+
//#region ../hooks/dist/hooks/utils.d.ts
|
|
4
|
+
|
|
5
|
+
declare enum SearchResultsState {
|
|
6
|
+
Loading = 0,
|
|
7
|
+
Results = 1,
|
|
8
|
+
NoResults = 2,
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
//#endregion
|
|
12
|
+
export { SearchResultsState };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/types/search-filter-types.d.ts
|
|
2
|
+
//#region ../hooks/dist/types/search-filter-types.d.ts
|
|
3
|
+
|
|
4
|
+
type SelectFilterItem = ({
|
|
5
|
+
filterId,
|
|
6
|
+
filterItemId,
|
|
7
|
+
isSelected,
|
|
8
|
+
displayName
|
|
9
|
+
}: {
|
|
10
|
+
filterId: string;
|
|
11
|
+
filterItemId: string;
|
|
12
|
+
isSelected: boolean;
|
|
13
|
+
displayName: string;
|
|
14
|
+
}) => void;
|
|
15
|
+
type SearchFilterDatum = {
|
|
16
|
+
filterId: string;
|
|
17
|
+
displayName: string;
|
|
18
|
+
items: SearchFilterItemDatum[];
|
|
19
|
+
};
|
|
20
|
+
type SearchFilterItemDatum = {
|
|
21
|
+
filterItemId: string;
|
|
22
|
+
displayName: string;
|
|
23
|
+
productCount: number;
|
|
24
|
+
isSelected: boolean;
|
|
25
|
+
};
|
|
26
|
+
//#endregion
|
|
27
|
+
//#endregion
|
|
28
|
+
export { SearchFilterDatum, SelectFilterItem };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
//#region ../widgets/dist/packages/hooks/dist/types/test-types.d.ts
|
|
2
|
+
//#region ../hooks/dist/types/test-types.d.ts
|
|
3
|
+
//#region src/types/test-types.d.ts
|
|
4
|
+
interface TestProps {
|
|
5
|
+
dataTestId?: string;
|
|
6
|
+
}
|
|
7
|
+
//#endregion
|
|
8
|
+
//#endregion
|
|
9
|
+
//#endregion
|
|
10
|
+
export { TestProps };
|
|
@@ -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
3
|
let react = require("react");
|
|
4
|
-
let jotai = require("jotai");
|
|
5
4
|
let __envive_ai_react_hooks_atoms_chat = require("@envive-ai/react-hooks/atoms/chat");
|
|
5
|
+
let jotai = require("jotai");
|
|
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
2
|
import { useMemo } from "react";
|
|
3
|
-
import { useAtomValue } from "jotai";
|
|
4
3
|
import { chatAtom, lastAssistantMessageAtom } from "@envive-ai/react-hooks/atoms/chat";
|
|
4
|
+
import { useAtomValue } from "jotai";
|
|
5
5
|
import { responseStreamingAtom } from "@envive-ai/react-hooks/atoms/chat/chatState";
|
|
6
6
|
|
|
7
7
|
//#region src/widgets/hooks/useGetWidgetStatus.tsx
|
|
@@ -4,19 +4,6 @@ let __envive_ai_react_hooks_application_models = require("@envive-ai/react-hooks
|
|
|
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
|
|
7
|
-
const getProductImageUrl = (lastAssistantMessage) => {
|
|
8
|
-
const productImageUrls = lastAssistantMessage != null ? lastAssistantMessage.reduce((acc, msg) => {
|
|
9
|
-
if (msg.type === __envive_ai_react_hooks_application_models.MessageType.Product && msg.metadata) {
|
|
10
|
-
if (msg.metadata.imageUrls?.length) return [...acc, ...msg.metadata.imageUrls];
|
|
11
|
-
if (msg.metadata.imageUrl) return [...acc, msg.metadata.imageUrl];
|
|
12
|
-
}
|
|
13
|
-
return acc;
|
|
14
|
-
}, []) : [];
|
|
15
|
-
return (() => {
|
|
16
|
-
const productImageUrlIndex = 1;
|
|
17
|
-
return productImageUrls.length > 0 && productImageUrlIndex > productImageUrls.length - 1 ? productImageUrls[productImageUrls.length - 1] : productImageUrls[productImageUrlIndex];
|
|
18
|
-
})();
|
|
19
|
-
};
|
|
20
7
|
const getRecentProductImageUrls = (lastMessages, currentProductId) => {
|
|
21
8
|
const productMessages = lastMessages.filter((message) => message.type === __envive_ai_react_hooks_application_models.MessageType.Product && message.metadata?.imageUrl).map((m) => m);
|
|
22
9
|
return [...productMessages.filter((m) => m.metadata?.id === currentProductId), ...productMessages.filter((m) => m.metadata?.id !== currentProductId)].map((m) => m.metadata.imageUrl);
|
|
@@ -55,7 +42,6 @@ const getStringIdForText = (rawValues, text) => {
|
|
|
55
42
|
|
|
56
43
|
//#endregion
|
|
57
44
|
exports.getMessageText = getMessageText;
|
|
58
|
-
exports.getProductImageUrl = getProductImageUrl;
|
|
59
45
|
exports.getRecentProductImageUrls = getRecentProductImageUrls;
|
|
60
46
|
exports.getStringIdForText = getStringIdForText;
|
|
61
47
|
exports.isLoading = isLoading;
|
|
@@ -3,19 +3,6 @@ import { MessageRole, MessageType } from "@envive-ai/react-hooks/application/mod
|
|
|
3
3
|
import { getAtomStore } from "@envive-ai/react-hooks/atoms/atomStore";
|
|
4
4
|
|
|
5
5
|
//#region src/widgets/utils/functions.ts
|
|
6
|
-
const getProductImageUrl = (lastAssistantMessage) => {
|
|
7
|
-
const productImageUrls = lastAssistantMessage != null ? lastAssistantMessage.reduce((acc, msg) => {
|
|
8
|
-
if (msg.type === MessageType.Product && msg.metadata) {
|
|
9
|
-
if (msg.metadata.imageUrls?.length) return [...acc, ...msg.metadata.imageUrls];
|
|
10
|
-
if (msg.metadata.imageUrl) return [...acc, msg.metadata.imageUrl];
|
|
11
|
-
}
|
|
12
|
-
return acc;
|
|
13
|
-
}, []) : [];
|
|
14
|
-
return (() => {
|
|
15
|
-
const productImageUrlIndex = 1;
|
|
16
|
-
return productImageUrls.length > 0 && productImageUrlIndex > productImageUrls.length - 1 ? productImageUrls[productImageUrls.length - 1] : productImageUrls[productImageUrlIndex];
|
|
17
|
-
})();
|
|
18
|
-
};
|
|
19
6
|
const getRecentProductImageUrls = (lastMessages, currentProductId) => {
|
|
20
7
|
const productMessages = lastMessages.filter((message) => message.type === MessageType.Product && message.metadata?.imageUrl).map((m) => m);
|
|
21
8
|
return [...productMessages.filter((m) => m.metadata?.id === currentProductId), ...productMessages.filter((m) => m.metadata?.id !== currentProductId)].map((m) => m.metadata.imageUrl);
|
|
@@ -53,4 +40,4 @@ const getStringIdForText = (rawValues, text) => {
|
|
|
53
40
|
};
|
|
54
41
|
|
|
55
42
|
//#endregion
|
|
56
|
-
export { getMessageText,
|
|
43
|
+
export { getMessageText, getRecentProductImageUrls, getStringIdForText, isLoading, isProductComparison, userHasInteracted, userHasNotInteracted };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { SearchEntryPointWidgetConfig, SearchInputVariant
|
|
1
|
+
import { SearchEntryPointWidgetConfig, SearchInputVariant } from "../../widgets/dist/packages/hooks/dist/contexts/types.cjs";
|
|
2
|
+
import { SearchZeroStateProps } from "../../widgets/dist/SearchZeroState/types.cjs";
|
|
2
3
|
import { SearchZeroState } from "../../widgets/dist/SearchZeroState/SearchZeroState.cjs";
|
|
3
4
|
import { SearchZeroStateWidget } from "../../widgets/dist/SearchZeroState/SearchZeroStateWidget.cjs";
|
|
4
5
|
export { SearchEntryPointWidgetConfig, SearchInputVariant, SearchZeroState, SearchZeroStateProps, SearchZeroStateWidget };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { SearchEntryPointWidgetConfig, SearchInputVariant
|
|
1
|
+
import { SearchEntryPointWidgetConfig, SearchInputVariant } from "../../packages/widgets/dist/packages/hooks/dist/contexts/types.js";
|
|
2
|
+
import { SearchZeroStateProps } from "../../packages/widgets/dist/SearchZeroState/types.js";
|
|
2
3
|
import { SearchZeroState } from "../../packages/widgets/dist/SearchZeroState/SearchZeroState.js";
|
|
3
4
|
import { SearchZeroStateWidget } from "../../packages/widgets/dist/SearchZeroState/SearchZeroStateWidget.js";
|
|
4
5
|
import "../../packages/widgets/dist/SearchZeroState/index.js";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { SuggestionButtonContainerProps } from "../../packages/widgets/dist/SuggestionButtonContainer/types.js";
|
|
2
2
|
import { SuggestionButtonContainer } from "../../packages/widgets/dist/SuggestionButtonContainer/SuggestionButtonContainer.js";
|
|
3
|
+
import "../../packages/widgets/dist/SuggestionButtonContainer/index.js";
|
|
3
4
|
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.
|
|
3
|
+
"version": "0.3.15-alpha.1",
|
|
4
4
|
"description": "React widget library v3 for Envive services.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"@envive-ai/react-toolkit": "*",
|
|
43
43
|
"@envive-ai/react-toolkit-v3": "*",
|
|
44
44
|
"@envive-ai/react-widgets": "*",
|
|
45
|
-
"react": "
|
|
46
|
-
"react-dom": "
|
|
45
|
+
"react": "^18.3.0 || ^19.0.0",
|
|
46
|
+
"react-dom": "^18.3.0 || ^19.0.0"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@envive-ai/react-widgets": "*",
|
|
@@ -163,4 +163,4 @@
|
|
|
163
163
|
"plugin:storybook/recommended"
|
|
164
164
|
]
|
|
165
165
|
}
|
|
166
|
-
}
|
|
166
|
+
}
|