@coveo/quantic 3.43.2 → 3.43.4
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/force-app/main/default/lwc/quanticBreadcrumbManager/e2e/data.ts +130 -0
- package/force-app/main/default/lwc/quanticBreadcrumbManager/e2e/fixture.ts +25 -14
- package/force-app/main/default/lwc/quanticBreadcrumbManager/e2e/quanticBreadcrumbManager.e2e.ts +57 -16
- package/force-app/main/default/lwc/quanticCardContainer/quanticCardContainer.css +3 -4
- package/force-app/main/default/lwc/quanticCardContainer/quanticCardContainer.html +1 -1
- package/force-app/main/default/lwc/quanticCarousel/quanticCarousel.css +5 -5
- package/force-app/main/default/lwc/quanticCaseClassification/quanticCaseClassification.css +3 -3
- package/force-app/main/default/lwc/quanticCategoryFacet/e2e/data.ts +70 -6
- package/force-app/main/default/lwc/quanticCategoryFacet/e2e/fixture.ts +17 -13
- package/force-app/main/default/lwc/quanticCategoryFacet/e2e/quanticCategoryFacet.e2e.ts +34 -14
- package/force-app/main/default/lwc/quanticCategoryFacet/quanticCategoryFacet.css +1 -1
- package/force-app/main/default/lwc/quanticCitation/quanticCitation.css +12 -11
- package/force-app/main/default/lwc/quanticDateFacet/e2e/data.ts +24 -4
- package/force-app/main/default/lwc/quanticDateFacet/e2e/fixture.ts +17 -13
- package/force-app/main/default/lwc/quanticDateFacet/e2e/quanticDateFacet.e2e.ts +26 -4
- package/force-app/main/default/lwc/quanticDidYouMean/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticDocumentSuggestion/quanticDocumentSuggestion.css +2 -2
- package/force-app/main/default/lwc/quanticFacet/e2e/data.ts +50 -9
- package/force-app/main/default/lwc/quanticFacet/e2e/fixture.ts +18 -13
- package/force-app/main/default/lwc/quanticFacet/e2e/quanticFacet.e2e.ts +43 -9
- package/force-app/main/default/lwc/quanticFacet/quanticFacet.css +1 -1
- package/force-app/main/default/lwc/quanticFacetManager/e2e/data.ts +59 -0
- package/force-app/main/default/lwc/quanticFacetManager/e2e/fixture.ts +26 -15
- package/force-app/main/default/lwc/quanticFacetManager/e2e/quanticFacetManager.e2e.ts +7 -7
- package/force-app/main/default/lwc/quanticFacetStyles/quanticFacetStyles.css +10 -10
- package/force-app/main/default/lwc/quanticFeedbackModalQna/templates/quanticFeedbackModalQna.css +1 -1
- package/force-app/main/default/lwc/quanticFoldedResultList/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticGeneratedAnswer/e2e/agentData.ts +32 -1
- package/force-app/main/default/lwc/quanticGeneratedAnswer/e2e/pageObject.ts +6 -0
- package/force-app/main/default/lwc/quanticGeneratedAnswer/e2e/quanticGeneratedAnswerAgent.e2e.ts +66 -1
- package/force-app/main/default/lwc/quanticGeneratedAnswer/quanticGeneratedAnswer.css +1 -1
- package/force-app/main/default/lwc/quanticGeneratedAnswer/templates/generatedAnswer.css +3 -3
- package/force-app/main/default/lwc/quanticGeneratedAnswer/templates/generatedAnswer.html +3 -3
- package/force-app/main/default/lwc/quanticGeneratedAnswerBody/__tests__/quanticGeneratedAnswerBody.test.js +39 -0
- package/force-app/main/default/lwc/quanticGeneratedAnswerBody/quanticGeneratedAnswerBody.js +4 -1
- package/force-app/main/default/lwc/quanticGeneratedAnswerContent/templates/generatedMarkdownContent.css +21 -21
- package/force-app/main/default/lwc/quanticGeneratedAnswerContent/templates/generatedTextContent.css +2 -2
- package/force-app/main/default/lwc/quanticGeneratedAnswerFollowUpInput/quanticGeneratedAnswerFollowUpInput.css +9 -9
- package/force-app/main/default/lwc/quanticGeneratedAnswerStreamOfThought/quanticGeneratedAnswerStreamOfThought.css +2 -2
- package/force-app/main/default/lwc/quanticGeneratedAnswerThread/quanticGeneratedAnswerThread.css +8 -8
- package/force-app/main/default/lwc/quanticInsightSummary/quanticInsightSummary.css +2 -1
- package/force-app/main/default/lwc/quanticModal/quanticModal.css +3 -3
- package/force-app/main/default/lwc/quanticNotifications/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticNotifications/quanticNotifications.css +2 -2
- package/force-app/main/default/lwc/quanticNumericFacet/e2e/data.ts +24 -4
- package/force-app/main/default/lwc/quanticNumericFacet/e2e/fixture.ts +17 -13
- package/force-app/main/default/lwc/quanticNumericFacet/e2e/quanticNumericFacet.e2e.ts +28 -6
- package/force-app/main/default/lwc/quanticPager/e2e/fixture.ts +3 -3
- package/force-app/main/default/lwc/quanticPager/e2e/quanticPager.e2e.ts +1 -1
- package/force-app/main/default/lwc/quanticPill/quanticPill.css +2 -2
- package/force-app/main/default/lwc/quanticPlaceholder/quanticPlaceholder.css +2 -6
- package/force-app/main/default/lwc/quanticPlaceholder/quanticPlaceholder.html +1 -1
- package/force-app/main/default/lwc/quanticRadioButtonsGroup/quanticRadioButtonsGroup.css +9 -9
- package/force-app/main/default/lwc/quanticRecentQueriesList/e2e/fixture.ts +1 -0
- package/force-app/main/default/lwc/quanticRecentQueriesList/quanticRecentQueriesList.css +3 -7
- package/force-app/main/default/lwc/quanticRecentQueriesList/quanticRecentQueriesList.html +1 -1
- package/force-app/main/default/lwc/quanticRecentResultsList/e2e/fixture.ts +1 -0
- package/force-app/main/default/lwc/quanticRecentResultsList/quanticRecentResultsList.css +2 -6
- package/force-app/main/default/lwc/quanticRecentResultsList/quanticRecentResultsList.html +1 -1
- package/force-app/main/default/lwc/quanticRecommendationList/e2e/fixture.ts +1 -0
- package/force-app/main/default/lwc/quanticRecommendationList/quanticRecommendationList.css +1 -1
- package/force-app/main/default/lwc/quanticRefineToggle/quanticRefineToggle.css +4 -4
- package/force-app/main/default/lwc/quanticResultActionStyles/quanticResultActionStyles.css +2 -2
- package/force-app/main/default/lwc/quanticResultCopyToClipboard/e2e/fixture.ts +5 -2
- package/force-app/main/default/lwc/quanticResultLink/quanticResultLink.css +1 -1
- package/force-app/main/default/lwc/quanticResultList/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticResultPrintableUri/quanticResultPrintableUri.css +1 -1
- package/force-app/main/default/lwc/quanticResultQuickview/e2e/fixture.ts +7 -3
- package/force-app/main/default/lwc/quanticResultQuickview/quanticResultQuickview.css +6 -6
- package/force-app/main/default/lwc/quanticResultTag/quanticResultTag.css +2 -0
- package/force-app/main/default/lwc/quanticResultTemplate/quanticResultTemplate.css +1 -1
- package/force-app/main/default/lwc/quanticResultsPerPage/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticSearchBox/e2e/fixture.ts +3 -1
- package/force-app/main/default/lwc/quanticSearchBoxInput/templates/defaultSearchBoxInput.css +1 -1
- package/force-app/main/default/lwc/quanticSearchBoxInput/templates/expandableSearchBoxInput.css +4 -12
- package/force-app/main/default/lwc/quanticSearchBoxInput/templates/expandableSearchBoxInput.html +2 -2
- package/force-app/main/default/lwc/quanticSearchBoxSuggestionsList/e2e/fixture.ts +3 -0
- package/force-app/main/default/lwc/quanticSmartSnippet/e2e/fixture.ts +6 -4
- package/force-app/main/default/lwc/quanticSmartSnippetSource/quanticSmartSnippetSource.css +1 -1
- package/force-app/main/default/lwc/quanticSmartSnippetSuggestions/e2e/fixture.ts +6 -4
- package/force-app/main/default/lwc/quanticSort/e2e/fixture.ts +3 -2
- package/force-app/main/default/lwc/quanticSort/quanticSort.css +3 -3
- package/force-app/main/default/lwc/quanticSourceCitations/quanticSourceCitations.css +1 -1
- package/force-app/main/default/lwc/quanticStandaloneSearchBox/e2e/fixture.ts +2 -1
- package/force-app/main/default/lwc/quanticStatefulButton/quanticStatefulButton.css +2 -2
- package/force-app/main/default/lwc/quanticTab/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticTabBar/e2e/fixture.ts +6 -2
- package/force-app/main/default/lwc/quanticTabBar/e2e/quanticTabBar.e2e.ts +3 -2
- package/force-app/main/default/lwc/quanticThreadItem/__tests__/quanticThreadItem.test.js +138 -0
- package/force-app/main/default/lwc/quanticThreadItem/quanticThreadItem.css +27 -6
- package/force-app/main/default/lwc/quanticThreadItem/quanticThreadItem.html +10 -2
- package/force-app/main/default/lwc/quanticThreadItem/quanticThreadItem.js +37 -1
- package/force-app/main/default/lwc/quanticTimeframeFacet/e2e/data.ts +66 -0
- package/force-app/main/default/lwc/quanticTimeframeFacet/e2e/fixture.ts +20 -4
- package/force-app/main/default/lwc/quanticTimeframeFacet/e2e/quanticTimeframeFacet.e2e.ts +24 -0
- package/force-app/main/default/lwc/quanticTimeframeFacet/quanticTimeframeFacet.css +1 -1
- package/force-app/main/default/lwc/quanticTooltip/quanticTooltip.css +3 -3
- package/force-app/main/default/lwc/quanticUserAction/quanticUserAction.css +7 -7
- package/force-app/main/default/lwc/quanticUserActionsSession/quanticUserActionsSession.css +3 -3
- package/force-app/main/default/lwc/quanticUserActionsTimeline/templates/userActionsTimeline.css +2 -2
- package/force-app/main/default/lwc/searchBoxStyle/searchBoxStyle.css +10 -10
- package/force-app/main/default/staticresources/coveobueno/browser/bueno.js +1 -3
- package/force-app/main/default/staticresources/coveoheadless/case-assist/headless.js +17 -17
- package/force-app/main/default/staticresources/coveoheadless/definitions/api/analytics/case-assist-analytics.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/api/analytics/insight-analytics.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/api/analytics/search-analytics.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/api/knowledge/stream-answer-api.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/engine-configuration.d.ts +34 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/insight-engine/insight-engine.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/insight-thunk-extra-arguments.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/search-thunk-extra-arguments.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/thunk-extra-arguments.d.ts +9 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/case-assist.index.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/commerce.index.d.ts +6 -6
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/breadcrumb-manager/headless-breadcrumb-manager.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/commerce/core/sort/headless-core-commerce-sort.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/commerce/core/url-manager/headless-core-url-manager.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/commerce/product-listing/headless-product-listing.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/commerce/recommendations/headless-recommendations.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/commerce/search/headless-search.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/context/headless-core-context.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/did-you-mean/headless-core-did-you-mean.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facet-manager/headless-core-facet-manager.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/category-facet/headless-core-category-facet.d.ts +0 -4
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/facet/headless-core-facet.d.ts +0 -5
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/range-facet/date-facet/headless-core-date-facet.d.ts +1 -5
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/range-facet/date-facet/headless-core-date-filter.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/range-facet/numeric-facet/headless-core-numeric-facet.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/facets/range-facet/numeric-facet/headless-core-numeric-filter.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/folded-result-list/headless-core-folded-result-list.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/generated-answer/headless-core-generated-answer.d.ts +1 -25
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/generated-answer/headless-searchapi-generated-answer.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/pager/headless-core-pager.d.ts +0 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/query-error/headless-core-query-error.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/recent-queries-list/headless-core-recent-queries-list.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/result-list/headless-core-result-list.d.ts +0 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/results-per-page/headless-core-results-per-page.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/sort/headless-core-sort.d.ts +0 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/status/headless-core-status.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/tab/headless-core-tab.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/triggers/headless-core-notify-trigger.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/triggers/headless-core-query-trigger.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/core/triggers/headless-core-redirection-trigger.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/dictionary-field-context/headless-dictionary-field-context.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/document-suggestion-list/case-assist-headless-interactive-result.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/facets/automatic-facet-generator/headless-automatic-facet-generator.d.ts +0 -4
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/facets/category-facet/headless-category-facet.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/facets/facet/headless-facet.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/field-suggestions/category-facet/headless-category-field-suggestions.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/field-suggestions/facet/headless-field-suggestions.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/generated-answer/headless-interactive-citation.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/history-manager/headless-history-manager.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/facet-conditions-manager/headless-facet-conditions-manager.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/generated-answer/headless-insight-interactive-citation.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/result-list/headless-insight-interactive-result.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/results-per-page/headless-insight-results-per-page.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/instant-results/instant-results.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/knowledge/generated-answer/headless-answerapi-generated-answer.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/knowledge/generated-answer/headless-generated-answer-with-follow-ups.d.ts +2 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/pager/headless-pager.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/query-summary/headless-query-summary.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/quickview/headless-quickview.d.ts +1 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/recent-results-list/headless-recent-results-list.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/recommendation/headless-recommendation.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/recommendation/result-list/headless-recommendation-interactive-result.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/relevance-inspector/headless-relevance-inspector.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/result-list/headless-interactive-result.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/result-list/headless-result-list.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/results-per-page/headless-results-per-page.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/smart-snippet-questions-list/headless-smart-snippet-questions-list.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/sort/headless-sort.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/standalone-search-box/headless-standalone-search-box.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/static-filter/headless-static-filter.d.ts +1 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/triggers/headless-execute-trigger.d.ts +0 -4
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/url-manager/headless-url-manager.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/analytics/analytics-utils.d.ts +1 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/attached-results/attached-results-analytics-actions.d.ts +4 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/commerce/configuration/configuration-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/commerce/context/cart/cart-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/commerce/context/context-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/commerce/facets/category-facet/category-facet-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/folding/insight-folding-actions.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/generated-answer/generated-answer-analytics-client.d.ts +38 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/generated-answer/generated-answer-insight-analytics-actions.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/insight-search/insight-query-set-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/insight-search/insight-search-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/query-set/query-set-actions-loader.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/result/result-insight-analytics-actions.d.ts +1 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/index.d.ts +7 -7
- package/force-app/main/default/staticresources/coveoheadless/definitions/insight.index.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/recommendation.index.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr/commerce/controllers/instant-products/headless-instant-products.ssr.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr/commerce/controllers/standalone-search-box/headless-standalone-search-box.ssr.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-commerce-next.index.d.ts +4 -4
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-commerce.index.d.ts +4 -4
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next/commerce/controllers/instant-products/headless-instant-products.ssr.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next/commerce/controllers/standalone-search-box/headless-standalone-search-box.ssr.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next/commerce/types/engine.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next.index.d.ts +6 -6
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr.index.d.ts +6 -6
- package/force-app/main/default/staticresources/coveoheadless/headless.js +17 -17
- package/force-app/main/default/staticresources/coveoheadless/insight/headless.js +16 -16
- package/force-app/main/default/staticresources/coveoheadless/recommendation/headless.js +16 -16
- package/package.json +4 -4
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Facet response builders for the breadcrumb manager example page
|
|
3
|
+
* (`exampleQuanticBreadcrumbManager.html`), which registers four facets:
|
|
4
|
+
* filetype (regular), ytlikecount (numeric), date (timeframe), and
|
|
5
|
+
* geographicalhierarchy (category).
|
|
6
|
+
*/
|
|
7
|
+
type State = 'idle' | 'selected';
|
|
8
|
+
|
|
9
|
+
const filetypeFacet = (state: State = 'idle') => ({
|
|
10
|
+
facetId: 'filetype',
|
|
11
|
+
field: 'filetype',
|
|
12
|
+
moreValuesAvailable: false,
|
|
13
|
+
values: [
|
|
14
|
+
{value: 'YouTubeVideo', state, numberOfResults: 100},
|
|
15
|
+
{value: 'txt', state: 'idle', numberOfResults: 50},
|
|
16
|
+
],
|
|
17
|
+
indexScore: 0.5,
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
const numericFacet = (state: State = 'idle') => ({
|
|
21
|
+
facetId: 'ytlikecount',
|
|
22
|
+
field: 'ytlikecount',
|
|
23
|
+
moreValuesAvailable: false,
|
|
24
|
+
values: [
|
|
25
|
+
{start: 0, end: 1000, endInclusive: false, state, numberOfResults: 100},
|
|
26
|
+
{
|
|
27
|
+
start: 1000,
|
|
28
|
+
end: 2000,
|
|
29
|
+
endInclusive: false,
|
|
30
|
+
state: 'idle',
|
|
31
|
+
numberOfResults: 50,
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
indexScore: 0.4,
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
const timeframeFacet = (state: State = 'idle') => ({
|
|
38
|
+
facetId: 'date',
|
|
39
|
+
field: 'date',
|
|
40
|
+
moreValuesAvailable: false,
|
|
41
|
+
values: [
|
|
42
|
+
{start: 'past-1-week', end: 'now', endInclusive: false, state, numberOfResults: 100},
|
|
43
|
+
{
|
|
44
|
+
start: 'past-1-month',
|
|
45
|
+
end: 'now',
|
|
46
|
+
endInclusive: false,
|
|
47
|
+
state: 'idle',
|
|
48
|
+
numberOfResults: 50,
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
start: 'past-6-month',
|
|
52
|
+
end: 'now',
|
|
53
|
+
endInclusive: false,
|
|
54
|
+
state: 'idle',
|
|
55
|
+
numberOfResults: 40,
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
start: 'past-1-year',
|
|
59
|
+
end: 'now',
|
|
60
|
+
endInclusive: false,
|
|
61
|
+
state: 'idle',
|
|
62
|
+
numberOfResults: 30,
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
start: 'past-10-year',
|
|
66
|
+
end: 'now',
|
|
67
|
+
endInclusive: false,
|
|
68
|
+
state: 'idle',
|
|
69
|
+
numberOfResults: 20,
|
|
70
|
+
},
|
|
71
|
+
],
|
|
72
|
+
indexScore: 0.3,
|
|
73
|
+
});
|
|
74
|
+
|
|
75
|
+
const categoryFacet = (state: State = 'idle') => ({
|
|
76
|
+
facetId: 'geographicalhierarchy',
|
|
77
|
+
field: 'geographicalhierarchy',
|
|
78
|
+
moreValuesAvailable: false,
|
|
79
|
+
values:
|
|
80
|
+
state === 'selected'
|
|
81
|
+
? [
|
|
82
|
+
{
|
|
83
|
+
value: 'North America',
|
|
84
|
+
state: 'selected',
|
|
85
|
+
numberOfResults: 100,
|
|
86
|
+
children: [],
|
|
87
|
+
path: ['North America'],
|
|
88
|
+
isLeafValue: false,
|
|
89
|
+
},
|
|
90
|
+
]
|
|
91
|
+
: [
|
|
92
|
+
{
|
|
93
|
+
value: 'North America',
|
|
94
|
+
state: 'idle',
|
|
95
|
+
numberOfResults: 100,
|
|
96
|
+
children: [],
|
|
97
|
+
path: ['North America'],
|
|
98
|
+
isLeafValue: false,
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
value: 'Africa',
|
|
102
|
+
state: 'idle',
|
|
103
|
+
numberOfResults: 50,
|
|
104
|
+
children: [],
|
|
105
|
+
path: ['Africa'],
|
|
106
|
+
isLeafValue: false,
|
|
107
|
+
},
|
|
108
|
+
],
|
|
109
|
+
indexScore: 0.2,
|
|
110
|
+
});
|
|
111
|
+
|
|
112
|
+
const allFacets = (selected?: 'regular' | 'numeric' | 'timeframe' | 'category') => [
|
|
113
|
+
filetypeFacet(selected === 'regular' ? 'selected' : 'idle'),
|
|
114
|
+
numericFacet(selected === 'numeric' ? 'selected' : 'idle'),
|
|
115
|
+
timeframeFacet(selected === 'timeframe' ? 'selected' : 'idle'),
|
|
116
|
+
categoryFacet(selected === 'category' ? 'selected' : 'idle'),
|
|
117
|
+
];
|
|
118
|
+
|
|
119
|
+
export const allIdle = allFacets();
|
|
120
|
+
export const regularSelected = allFacets('regular');
|
|
121
|
+
export const numericSelected = allFacets('numeric');
|
|
122
|
+
export const timeframeSelected = allFacets('timeframe');
|
|
123
|
+
export const categorySelected = allFacets('category');
|
|
124
|
+
|
|
125
|
+
export const regularAndTimeframeSelected = [
|
|
126
|
+
filetypeFacet('selected'),
|
|
127
|
+
numericFacet('idle'),
|
|
128
|
+
timeframeFacet('selected'),
|
|
129
|
+
categoryFacet('idle'),
|
|
130
|
+
];
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import {BreadcrumbManagerObject} from './pageObject';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import {facetBase} from '../../../../../../playwright/fixtures/baseFacetFixture';
|
|
3
|
+
import {BaseFacetObject} from '../../../../../../playwright/page-object/baseFacetObject';
|
|
4
4
|
import {
|
|
5
5
|
searchRequestRegex,
|
|
6
6
|
insightSearchRequestRegex,
|
|
7
7
|
} from '../../../../../../playwright/utils/requests';
|
|
8
8
|
import {InsightSetupObject} from '../../../../../../playwright/page-object/insightSetupObject';
|
|
9
9
|
import {useCaseEnum} from '../../../../../../playwright/utils/useCase';
|
|
10
|
+
import {allIdle} from './data';
|
|
10
11
|
|
|
11
12
|
const breadcrumbManagerUrl = 's/quantic-breadcrumb-manager';
|
|
12
13
|
|
|
@@ -17,7 +18,6 @@ interface BreadcrumbManagerOptions {
|
|
|
17
18
|
|
|
18
19
|
type QuanticBreadcrumbManagerE2EFixtures = {
|
|
19
20
|
breadcrumbManager: BreadcrumbManagerObject;
|
|
20
|
-
search: SearchObject;
|
|
21
21
|
options: Partial<BreadcrumbManagerOptions>;
|
|
22
22
|
};
|
|
23
23
|
|
|
@@ -32,43 +32,54 @@ type QuanticBreadcrumbManagerE2eInsightFixtures =
|
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
export const testSearch =
|
|
35
|
-
|
|
35
|
+
facetBase.extend<QuanticBreadcrumbManagerE2ESearchFixtures>({
|
|
36
36
|
options: {},
|
|
37
37
|
urlHash: '',
|
|
38
|
-
|
|
39
|
-
|
|
38
|
+
facetResponses: {responses: [allIdle]},
|
|
39
|
+
baseFacet: async ({page}, use) => {
|
|
40
|
+
await use(new BaseFacetObject(page, searchRequestRegex));
|
|
40
41
|
},
|
|
41
42
|
breadcrumbManager: async (
|
|
42
|
-
{page, options, configuration,
|
|
43
|
+
{page, options, configuration, baseFacet, urlHash, facetResponses},
|
|
43
44
|
use
|
|
44
45
|
) => {
|
|
46
|
+
await baseFacet.mockSearchWithBaseResponse();
|
|
45
47
|
await page.goto(
|
|
46
48
|
urlHash ? `${breadcrumbManagerUrl}#${urlHash}` : breadcrumbManagerUrl
|
|
47
49
|
);
|
|
50
|
+
await baseFacet.mockSearchWithFacetResponseSequence(
|
|
51
|
+
facetResponses?.responses
|
|
52
|
+
);
|
|
48
53
|
configuration.configure(options);
|
|
49
|
-
await
|
|
54
|
+
await baseFacet.waitForSearchResponse();
|
|
50
55
|
await use(new BreadcrumbManagerObject(page));
|
|
51
56
|
},
|
|
52
57
|
});
|
|
53
58
|
|
|
54
59
|
export const testInsight =
|
|
55
|
-
|
|
60
|
+
facetBase.extend<QuanticBreadcrumbManagerE2eInsightFixtures>({
|
|
56
61
|
options: {},
|
|
57
|
-
|
|
58
|
-
|
|
62
|
+
facetResponses: {responses: [allIdle]},
|
|
63
|
+
baseFacet: async ({page}, use) => {
|
|
64
|
+
await use(new BaseFacetObject(page, insightSearchRequestRegex));
|
|
59
65
|
},
|
|
60
66
|
insightSetup: async ({page}, use) => {
|
|
61
67
|
await use(new InsightSetupObject(page));
|
|
62
68
|
},
|
|
63
69
|
breadcrumbManager: async (
|
|
64
|
-
{page, options,
|
|
70
|
+
{page, options, baseFacet, configuration, insightSetup, facetResponses},
|
|
65
71
|
use
|
|
66
72
|
) => {
|
|
67
73
|
await page.goto(breadcrumbManagerUrl);
|
|
74
|
+
await baseFacet.mockSearchWithFacetResponseSequence(
|
|
75
|
+
facetResponses?.responses
|
|
76
|
+
);
|
|
68
77
|
configuration.configure({...options, useCase: useCaseEnum.insight});
|
|
69
78
|
await insightSetup.waitForInsightInterfaceInitialization();
|
|
70
|
-
await
|
|
71
|
-
|
|
79
|
+
await Promise.all([
|
|
80
|
+
baseFacet.waitForSearchResponse(),
|
|
81
|
+
baseFacet.performSearch(),
|
|
82
|
+
]);
|
|
72
83
|
await use(new BreadcrumbManagerObject(page));
|
|
73
84
|
},
|
|
74
85
|
});
|
package/force-app/main/default/lwc/quanticBreadcrumbManager/e2e/quanticBreadcrumbManager.e2e.ts
CHANGED
|
@@ -3,6 +3,14 @@ import {
|
|
|
3
3
|
useCaseEnum,
|
|
4
4
|
useCaseTestCases,
|
|
5
5
|
} from '../../../../../../playwright/utils/useCase';
|
|
6
|
+
import {
|
|
7
|
+
regularSelected,
|
|
8
|
+
numericSelected,
|
|
9
|
+
timeframeSelected,
|
|
10
|
+
categorySelected,
|
|
11
|
+
regularAndTimeframeSelected,
|
|
12
|
+
allIdle,
|
|
13
|
+
} from './data';
|
|
6
14
|
|
|
7
15
|
const fixtures = {
|
|
8
16
|
search: testSearch,
|
|
@@ -23,17 +31,22 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
23
31
|
test.describe(`quantic breadcrumb manager ${useCase.label}`, () => {
|
|
24
32
|
test.describe('when de-selecting a facet value', () => {
|
|
25
33
|
test.describe('with regular facet values', () => {
|
|
34
|
+
test.use({
|
|
35
|
+
facetResponses: {
|
|
36
|
+
responses: [allIdle, regularSelected, allIdle],
|
|
37
|
+
},
|
|
38
|
+
});
|
|
26
39
|
test('should trigger a new search and log analytics', async ({
|
|
27
40
|
breadcrumbManager,
|
|
28
|
-
|
|
41
|
+
baseFacet,
|
|
29
42
|
}) => {
|
|
30
43
|
const firstRegularFacetValue =
|
|
31
44
|
await breadcrumbManager.firstRegularFacetValue;
|
|
32
|
-
const searchResponsePromise =
|
|
45
|
+
const searchResponsePromise = baseFacet.waitForSearchResponse();
|
|
33
46
|
await breadcrumbManager.clickFirstRegularFacetLink();
|
|
34
47
|
await searchResponsePromise;
|
|
35
48
|
|
|
36
|
-
const secondSearchResponsePromise =
|
|
49
|
+
const secondSearchResponsePromise = baseFacet.waitForSearchResponse();
|
|
37
50
|
const breadcrumbAnalyticsPromise =
|
|
38
51
|
breadcrumbManager.waitForBreadcrumbFacetUaAnalytics({
|
|
39
52
|
facetValue: firstRegularFacetValue,
|
|
@@ -45,18 +58,23 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
45
58
|
});
|
|
46
59
|
|
|
47
60
|
test.describe('with numeric facet values', () => {
|
|
61
|
+
test.use({
|
|
62
|
+
facetResponses: {
|
|
63
|
+
responses: [allIdle, numericSelected, allIdle],
|
|
64
|
+
},
|
|
65
|
+
});
|
|
48
66
|
test('should trigger a new search and log analytics', async ({
|
|
49
67
|
breadcrumbManager,
|
|
50
|
-
|
|
68
|
+
baseFacet,
|
|
51
69
|
}) => {
|
|
52
70
|
const [facetRangeStart, facetRangeEnd] =
|
|
53
71
|
(await breadcrumbManager.firstNumericFacetValue)?.split(' - ') ??
|
|
54
72
|
[];
|
|
55
|
-
const searchResponsePromise =
|
|
73
|
+
const searchResponsePromise = baseFacet.waitForSearchResponse();
|
|
56
74
|
await breadcrumbManager.clickFirstNumericFacetLink();
|
|
57
75
|
await searchResponsePromise;
|
|
58
76
|
|
|
59
|
-
const secondSearchResponsePromise =
|
|
77
|
+
const secondSearchResponsePromise = baseFacet.waitForSearchResponse();
|
|
60
78
|
// We use the facet display value to compare, but the display value is localized and can contain non-numeric characters while the analytics request doesn't contain those characters.
|
|
61
79
|
const breadcrumbAnalyticsPromise =
|
|
62
80
|
breadcrumbManager.waitForBreadcrumbFacetUaAnalytics({
|
|
@@ -70,17 +88,22 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
70
88
|
});
|
|
71
89
|
|
|
72
90
|
test.describe('with timeframe|date facet values', () => {
|
|
91
|
+
test.use({
|
|
92
|
+
facetResponses: {
|
|
93
|
+
responses: [allIdle, timeframeSelected, allIdle],
|
|
94
|
+
},
|
|
95
|
+
});
|
|
73
96
|
test('should trigger a new search and log analytics', async ({
|
|
74
97
|
breadcrumbManager,
|
|
75
|
-
|
|
98
|
+
baseFacet,
|
|
76
99
|
}) => {
|
|
77
100
|
const facetValue = await breadcrumbManager.firstTimeframeFacetValue;
|
|
78
101
|
test.expect(facetValue).not.toBeNull();
|
|
79
|
-
const searchResponsePromise =
|
|
102
|
+
const searchResponsePromise = baseFacet.waitForSearchResponse();
|
|
80
103
|
await breadcrumbManager.clickFirstTimeframeFacetLink();
|
|
81
104
|
await searchResponsePromise;
|
|
82
105
|
|
|
83
|
-
const secondSearchResponsePromise =
|
|
106
|
+
const secondSearchResponsePromise = baseFacet.waitForSearchResponse();
|
|
84
107
|
// We use the facet display value to compare, but the display value is prettified and is transformed to be human readable, while the analytics request isn't.
|
|
85
108
|
const [expectedFacetRangeStart, expectedFacetRangeEnd] =
|
|
86
109
|
datetimeFacetLabelToValue[facetValue!].split('..');
|
|
@@ -96,17 +119,22 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
96
119
|
});
|
|
97
120
|
|
|
98
121
|
test.describe('with category facet values', () => {
|
|
122
|
+
test.use({
|
|
123
|
+
facetResponses: {
|
|
124
|
+
responses: [allIdle, categorySelected, allIdle],
|
|
125
|
+
},
|
|
126
|
+
});
|
|
99
127
|
test('should trigger a new search and log analytics', async ({
|
|
100
128
|
breadcrumbManager,
|
|
101
|
-
|
|
129
|
+
baseFacet,
|
|
102
130
|
}) => {
|
|
103
131
|
const facetValue = await breadcrumbManager.firstCategoryFacetValue;
|
|
104
132
|
test.expect(facetValue).not.toBeNull();
|
|
105
|
-
const searchResponsePromise =
|
|
133
|
+
const searchResponsePromise = baseFacet.waitForSearchResponse();
|
|
106
134
|
await breadcrumbManager.clickFirstCategoryFacetLink();
|
|
107
135
|
await searchResponsePromise;
|
|
108
136
|
|
|
109
|
-
const secondSearchResponsePromise =
|
|
137
|
+
const secondSearchResponsePromise = baseFacet.waitForSearchResponse();
|
|
110
138
|
const expectedFacetValue = facetValue!;
|
|
111
139
|
const breadcrumbAnalyticsPromise =
|
|
112
140
|
breadcrumbManager.waitForBreadcrumbFacetUaAnalytics({
|
|
@@ -120,20 +148,30 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
120
148
|
});
|
|
121
149
|
|
|
122
150
|
test.describe('when clicking on the clear all filters button', () => {
|
|
151
|
+
test.use({
|
|
152
|
+
facetResponses: {
|
|
153
|
+
responses: [
|
|
154
|
+
allIdle,
|
|
155
|
+
regularSelected,
|
|
156
|
+
regularAndTimeframeSelected,
|
|
157
|
+
allIdle,
|
|
158
|
+
],
|
|
159
|
+
},
|
|
160
|
+
});
|
|
123
161
|
test('should send a clear all filters analytics event and clear all selected facets values', async ({
|
|
124
162
|
breadcrumbManager,
|
|
125
|
-
|
|
163
|
+
baseFacet,
|
|
126
164
|
}) => {
|
|
127
|
-
const searchResponsePromise =
|
|
165
|
+
const searchResponsePromise = baseFacet.waitForSearchResponse();
|
|
128
166
|
await breadcrumbManager.clickFirstRegularFacetLink();
|
|
129
167
|
await searchResponsePromise;
|
|
130
168
|
|
|
131
|
-
const searchResponsePromiseTwo =
|
|
169
|
+
const searchResponsePromiseTwo = baseFacet.waitForSearchResponse();
|
|
132
170
|
await breadcrumbManager.clickFirstTimeframeFacetLink();
|
|
133
171
|
await searchResponsePromiseTwo;
|
|
134
172
|
|
|
135
173
|
await test.expect(breadcrumbManager.clearAllButton).toBeVisible();
|
|
136
|
-
const clearAllSearchResponsePromise =
|
|
174
|
+
const clearAllSearchResponsePromise = baseFacet.waitForSearchResponse();
|
|
137
175
|
const clearAllAnalyticsPromise =
|
|
138
176
|
breadcrumbManager.waitForBreadcrumbResetAllUaAnalytics();
|
|
139
177
|
await breadcrumbManager.clickClearAllButton();
|
|
@@ -152,6 +190,9 @@ useCaseTestCases.forEach((useCase) => {
|
|
|
152
190
|
const facetSelectedHash = 'f-filetype=YouTubeVideo';
|
|
153
191
|
test.use({
|
|
154
192
|
urlHash: facetSelectedHash,
|
|
193
|
+
facetResponses: {
|
|
194
|
+
responses: [regularSelected],
|
|
195
|
+
},
|
|
155
196
|
});
|
|
156
197
|
|
|
157
198
|
test('should have a facet selected in the breadcrumb manager', async ({
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
.card {
|
|
2
2
|
position: relative;
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
border: var(--
|
|
6
|
-
border-radius: 0.25rem;
|
|
3
|
+
background: var(--slds-g-color-surface-1, var(--lwc-colorBackgroundAlt, #ffffff));
|
|
4
|
+
border: var(--slds-g-sizing-border-1, var(--lwc-borderWidthThin, 1px)) solid var(--slds-g-color-neutral-base-90, var(--lwc-colorBorder, #dddbda));
|
|
5
|
+
border-radius: var(--slds-g-radius-border-2, 0.25rem);
|
|
7
6
|
background-clip: padding-box;
|
|
8
7
|
-webkit-box-shadow: 0 2px 2px 0 rgb(0 0 0 / 10%);
|
|
9
8
|
box-shadow: 0 2px 2px 0 rgb(0 0 0 / 10%);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<host>
|
|
3
|
-
<article class="card">
|
|
3
|
+
<article class="card slds-p-around_medium">
|
|
4
4
|
<header class="slds-grid slds-p-horizontal_x-small slds-has-flexi-truncate">
|
|
5
5
|
<div class="slds-media__body card_focusable-header" onclick={handleHeaderClick} onkeydown={handleHeaderKeyDown}
|
|
6
6
|
role="button" tabindex="0" data-testid="card-container__header">
|
|
@@ -13,19 +13,19 @@
|
|
|
13
13
|
|
|
14
14
|
.carousel__indicator {
|
|
15
15
|
width: 3.25rem;
|
|
16
|
-
height: 0.25rem;
|
|
16
|
+
height: var(--slds-g-sizing-2, 0.25rem);
|
|
17
17
|
border: 0;
|
|
18
|
-
border-radius: var(--lwc-borderRadiusMedium, 0.25rem);
|
|
19
|
-
background-color: var(--lwc-brandLightActive, #e3e5ed);
|
|
18
|
+
border-radius: var(--slds-g-radius-border-2, var(--lwc-borderRadiusMedium, 0.25rem));
|
|
19
|
+
background-color: var(--slds-g-color-accent-light-1, var(--lwc-brandLightActive, #e3e5ed));
|
|
20
20
|
transition: 0.2s;
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
.carousel__indicator--active {
|
|
24
|
-
background-color: var(--lwc-brandPrimary, #1b96ff);
|
|
24
|
+
background-color: var(--slds-g-color-accent-1, var(--lwc-brandPrimary, #1b96ff));
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
.carousel__indicator:hover {
|
|
28
|
-
background-color: var(--lwc-brandPrimaryActive, #0176d3);
|
|
28
|
+
background-color: var(--slds-g-color-accent-2, var(--lwc-brandPrimaryActive, #0176d3));
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
.carousel__previous-navigation {
|
|
@@ -28,7 +28,7 @@ lightning-icon {
|
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
.slds-visual-picker input:checked ~ label .visual-picker__figure:after {
|
|
31
|
-
border-right-color: var(--lwc-colorBorderRowSelectedHover, rgb(27, 150, 255));
|
|
32
|
-
border-top-color: var(--lwc-colorBorderRowSelectedHover, rgb(27, 150, 255));
|
|
33
|
-
border-radius: 4px;
|
|
31
|
+
border-right-color: var(--slds-g-color-brand-base-50, var(--lwc-colorBorderRowSelectedHover, rgb(27, 150, 255)));
|
|
32
|
+
border-top-color: var(--slds-g-color-brand-base-50, var(--lwc-colorBorderRowSelectedHover, rgb(27, 150, 255)));
|
|
33
|
+
border-radius: var(--slds-g-radius-border-2, 4px);
|
|
34
34
|
}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
const facetId = 'geographicalhierarchy';
|
|
2
|
+
const field = 'geographicalhierarchy';
|
|
3
|
+
const label = 'Country';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Facet response before any value is selected.
|
|
7
|
+
*/
|
|
8
|
+
export const initialFacetData = {
|
|
9
|
+
facetId,
|
|
10
|
+
field,
|
|
4
11
|
moreValuesAvailable: true,
|
|
5
12
|
values: [
|
|
6
13
|
{
|
|
@@ -20,8 +27,65 @@ const facetData = {
|
|
|
20
27
|
isLeafValue: false,
|
|
21
28
|
},
|
|
22
29
|
],
|
|
23
|
-
indexScore:
|
|
24
|
-
label
|
|
30
|
+
indexScore: 1,
|
|
31
|
+
label,
|
|
25
32
|
};
|
|
26
33
|
|
|
27
|
-
|
|
34
|
+
const [northAmerica] = initialFacetData.values;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Facet response after clicking "Show more".
|
|
38
|
+
*/
|
|
39
|
+
export const expandedFacetData = {
|
|
40
|
+
...initialFacetData,
|
|
41
|
+
values: [
|
|
42
|
+
...initialFacetData.values,
|
|
43
|
+
{
|
|
44
|
+
value: 'South America',
|
|
45
|
+
state: 'idle',
|
|
46
|
+
numberOfResults: 112,
|
|
47
|
+
children: [],
|
|
48
|
+
path: ['South America'],
|
|
49
|
+
isLeafValue: false,
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
value: 'Asia',
|
|
53
|
+
state: 'idle',
|
|
54
|
+
numberOfResults: 58,
|
|
55
|
+
children: [],
|
|
56
|
+
path: ['Asia'],
|
|
57
|
+
isLeafValue: false,
|
|
58
|
+
},
|
|
59
|
+
],
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Facet response after the first parent value is selected.
|
|
64
|
+
*/
|
|
65
|
+
export const selectedFacetData = {
|
|
66
|
+
...initialFacetData,
|
|
67
|
+
values: [
|
|
68
|
+
{
|
|
69
|
+
...northAmerica,
|
|
70
|
+
state: 'selected',
|
|
71
|
+
children: [
|
|
72
|
+
{
|
|
73
|
+
value: 'Canada',
|
|
74
|
+
state: 'idle',
|
|
75
|
+
numberOfResults: 45,
|
|
76
|
+
children: [],
|
|
77
|
+
path: ['North America', 'Canada'],
|
|
78
|
+
isLeafValue: true,
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
value: 'United States',
|
|
82
|
+
state: 'idle',
|
|
83
|
+
numberOfResults: 67,
|
|
84
|
+
children: [],
|
|
85
|
+
path: ['North America', 'United States'],
|
|
86
|
+
isLeafValue: true,
|
|
87
|
+
},
|
|
88
|
+
],
|
|
89
|
+
},
|
|
90
|
+
],
|
|
91
|
+
};
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
insightSearchRequestRegex,
|
|
7
7
|
} from '../../../../../../playwright/utils/requests';
|
|
8
8
|
import {BaseFacetObject} from '../../../../../../playwright/page-object/baseFacetObject';
|
|
9
|
-
import
|
|
9
|
+
import {initialFacetData} from './data';
|
|
10
10
|
import {facetBase} from '../../../../../../playwright/fixtures/baseFacetFixture';
|
|
11
11
|
|
|
12
12
|
const pageUrl = 's/quantic-category-facet';
|
|
@@ -26,20 +26,22 @@ type QuanticFacetE2EFixtures = {
|
|
|
26
26
|
|
|
27
27
|
export const testSearch = facetBase.extend<QuanticFacetE2EFixtures>({
|
|
28
28
|
options: {},
|
|
29
|
-
|
|
29
|
+
facetResponses: {responses: [[initialFacetData]]},
|
|
30
30
|
baseFacet: async ({page}, use) => {
|
|
31
31
|
await use(new BaseFacetObject(page, searchRequestRegex));
|
|
32
32
|
},
|
|
33
33
|
facet: async (
|
|
34
|
-
{page, options, configuration, baseFacet, urlHash,
|
|
34
|
+
{page, options, configuration, baseFacet, urlHash, facetResponses},
|
|
35
35
|
use
|
|
36
36
|
) => {
|
|
37
|
+
// search use case: interface auto-triggers a search on load, hence the mockSearchWithBaseResponse call below
|
|
38
|
+
await baseFacet.mockSearchWithBaseResponse();
|
|
37
39
|
await page.goto(
|
|
38
40
|
`${pageUrl}${options.caption ? '-with-captions' : ''}#${urlHash ? urlHash : ''}`
|
|
39
41
|
);
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
await baseFacet.mockSearchWithFacetResponseSequence(
|
|
43
|
+
facetResponses?.responses
|
|
44
|
+
);
|
|
43
45
|
configuration.configure(options);
|
|
44
46
|
await baseFacet.waitForSearchResponse();
|
|
45
47
|
|
|
@@ -49,7 +51,7 @@ export const testSearch = facetBase.extend<QuanticFacetE2EFixtures>({
|
|
|
49
51
|
|
|
50
52
|
export const testInsight = facetBase.extend<QuanticFacetE2EFixtures>({
|
|
51
53
|
options: {},
|
|
52
|
-
|
|
54
|
+
facetResponses: {responses: [[initialFacetData]]},
|
|
53
55
|
baseFacet: async ({page}, use) => {
|
|
54
56
|
await use(new BaseFacetObject(page, insightSearchRequestRegex));
|
|
55
57
|
},
|
|
@@ -57,17 +59,19 @@ export const testInsight = facetBase.extend<QuanticFacetE2EFixtures>({
|
|
|
57
59
|
await use(new InsightSetupObject(page));
|
|
58
60
|
},
|
|
59
61
|
facet: async (
|
|
60
|
-
{page, options, baseFacet, configuration, insightSetup,
|
|
62
|
+
{page, options, baseFacet, configuration, insightSetup, facetResponses},
|
|
61
63
|
use
|
|
62
64
|
) => {
|
|
63
65
|
await page.goto(`${pageUrl}${options.caption ? '-with-captions' : ''}`);
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
66
|
+
await baseFacet.mockSearchWithFacetResponseSequence(
|
|
67
|
+
facetResponses?.responses
|
|
68
|
+
);
|
|
67
69
|
configuration.configure({...options, useCase: useCaseEnum.insight});
|
|
68
70
|
await insightSetup?.waitForInsightInterfaceInitialization();
|
|
69
|
-
await
|
|
70
|
-
|
|
71
|
+
await Promise.all([
|
|
72
|
+
baseFacet.waitForSearchResponse(),
|
|
73
|
+
baseFacet.performSearch(),
|
|
74
|
+
]);
|
|
71
75
|
await use(new CategoryFacetObject(page));
|
|
72
76
|
},
|
|
73
77
|
});
|