@coveo/quantic 3.45.7 → 3.45.8
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/docs/out/quantic-docs.json +5 -5
- package/force-app/main/default/lwc/quanticBreadcrumbManager/quanticBreadcrumbManager.html +4 -4
- package/force-app/main/default/lwc/quanticCarousel/quanticCarousel.html +2 -2
- package/force-app/main/default/lwc/quanticCaseClassification/quanticCaseClassification.html +18 -18
- package/force-app/main/default/lwc/quanticCaseClassification/quanticCaseClassification.js +3 -3
- package/force-app/main/default/lwc/quanticCategoryFacet/quanticCategoryFacet.html +45 -45
- package/force-app/main/default/lwc/quanticCategoryFacet/quanticCategoryFacet.js +9 -0
- package/force-app/main/default/lwc/quanticCategoryFacetValue/quanticCategoryFacetValue.html +11 -11
- package/force-app/main/default/lwc/quanticColoredResultBadge/quanticColoredResultBadge.html +5 -5
- package/force-app/main/default/lwc/quanticDateFacet/quanticDateFacet.html +4 -4
- package/force-app/main/default/lwc/quanticDateFacet/quanticDateFacet.js +4 -0
- package/force-app/main/default/lwc/quanticDidYouMean/templates/didYouMean.html +2 -2
- package/force-app/main/default/lwc/quanticDocumentSuggestion/quanticDocumentSuggestion.html +4 -4
- package/force-app/main/default/lwc/quanticFacet/quanticFacet.html +43 -43
- package/force-app/main/default/lwc/quanticFacet/quanticFacet.js +8 -0
- package/force-app/main/default/lwc/quanticFacetValue/quanticFacetValue.html +5 -5
- package/force-app/main/default/lwc/quanticFacetValue/quanticFacetValue.js +4 -0
- package/force-app/main/default/lwc/quanticFeedbackModal/feedbackForm.html +2 -2
- package/force-app/main/default/lwc/quanticFoldedResultList/quanticFoldedResultList.html +1 -1
- package/force-app/main/default/lwc/quanticInsightSummary/quanticInsightSummary.html +5 -5
- package/force-app/main/default/lwc/quanticInsightSummary/quanticInsightSummary.js +4 -0
- package/force-app/main/default/lwc/quanticModal/quanticModal.html +2 -2
- package/force-app/main/default/lwc/quanticNoResults/quanticNoResults.html +4 -4
- package/force-app/main/default/lwc/quanticNumericFacet/quanticNumericFacet.html +6 -6
- package/force-app/main/default/lwc/quanticNumericFacet/quanticNumericFacet.js +4 -0
- package/force-app/main/default/lwc/quanticPlaceholder/quanticPlaceholder.html +3 -3
- package/force-app/main/default/lwc/quanticQueryError/quanticQueryError.html +6 -6
- package/force-app/main/default/lwc/quanticQueryError/quanticQueryError.js +4 -0
- package/force-app/main/default/lwc/quanticQuickviewContent/quanticQuickviewDefault.html +1 -1
- package/force-app/main/default/lwc/quanticQuickviewContent/quanticQuickviewYoutube.html +1 -1
- package/force-app/main/default/lwc/quanticRecentQueriesList/quanticRecentQueriesList.html +4 -4
- package/force-app/main/default/lwc/quanticRecentQueriesList/quanticRecentQueriesList.js +8 -0
- package/force-app/main/default/lwc/quanticRecentResultsList/quanticRecentResultsList.html +4 -4
- package/force-app/main/default/lwc/quanticRecentResultsList/quanticRecentResultsList.js +8 -0
- package/force-app/main/default/lwc/quanticRefineModalContent/quanticRefineModalContent.js +4 -0
- package/force-app/main/default/lwc/quanticRefineModalContent/templates/disabledDynamicNavigation.html +9 -9
- package/force-app/main/default/lwc/quanticRefineModalContent/templates/dynamicNavigation.html +9 -9
- package/force-app/main/default/lwc/quanticRefineToggle/quanticRefineToggle.html +2 -2
- package/force-app/main/default/lwc/quanticResult/quanticResult.html +1 -1
- package/force-app/main/default/lwc/quanticResultAction/quanticResultAction.html +3 -3
- package/force-app/main/default/lwc/quanticResultChildren/quanticResultChildren.html +3 -3
- package/force-app/main/default/lwc/quanticResultDate/quanticResultDate.html +2 -2
- package/force-app/main/default/lwc/quanticResultDate/quanticResultDate.js +1 -1
- package/force-app/main/default/lwc/quanticResultField/quanticResultField.js +1 -1
- package/force-app/main/default/lwc/quanticResultHighlightedTextField/quanticResultHighlightedTextField.html +3 -3
- package/force-app/main/default/lwc/quanticResultLabel/quanticResultLabel.html +3 -3
- package/force-app/main/default/lwc/quanticResultLabel/quanticResultLabel.js +4 -0
- package/force-app/main/default/lwc/quanticResultList/quanticResultList.html +1 -1
- package/force-app/main/default/lwc/quanticResultMultiValueText/quanticResultMultiValueText.html +3 -3
- package/force-app/main/default/lwc/quanticResultMultiValueText/quanticResultMultiValueText.js +1 -1
- package/force-app/main/default/lwc/quanticResultNumber/quanticResultNumber.html +2 -2
- package/force-app/main/default/lwc/quanticResultNumber/quanticResultNumber.js +1 -1
- package/force-app/main/default/lwc/quanticResultPrintableUri/quanticResultPrintableUri.html +4 -4
- package/force-app/main/default/lwc/quanticResultQuickview/quanticResultQuickview.html +5 -5
- package/force-app/main/default/lwc/quanticResultQuickview/quanticResultQuickview.js +2 -2
- package/force-app/main/default/lwc/quanticResultTag/quanticResultTag.html +2 -2
- package/force-app/main/default/lwc/quanticResultText/quanticResultText.html +3 -3
- package/force-app/main/default/lwc/quanticResultText/quanticResultText.js +1 -1
- package/force-app/main/default/lwc/quanticResultsPerPage/quanticResultsPerPage.html +1 -1
- package/force-app/main/default/lwc/quanticSearchBoxInput/quanticSearchBoxInput.js +6 -2
- package/force-app/main/default/lwc/quanticSearchBoxInput/templates/defaultSearchBoxInput.html +4 -4
- package/force-app/main/default/lwc/quanticSearchBoxInput/templates/expandableSearchBoxInput.html +4 -4
- package/force-app/main/default/lwc/quanticSmartSnippet/quanticSmartSnippet.html +2 -2
- package/force-app/main/default/lwc/quanticSmartSnippetSuggestions/quanticSmartSnippetSuggestions.html +1 -1
- package/force-app/main/default/lwc/quanticSourceCitations/quanticSourceCitations.html +1 -1
- package/force-app/main/default/lwc/quanticStandaloneSearchBox/templates/standaloneSearchBox.html +2 -2
- package/force-app/main/default/lwc/quanticSummary/quanticSummary.html +1 -1
- package/force-app/main/default/lwc/quanticTimeframeFacet/quanticTimeframeFacet.html +7 -7
- package/force-app/main/default/lwc/quanticTimeframeFacet/quanticTimeframeFacet.js +5 -0
- package/force-app/main/default/lwc/quanticViewedByCustomerBadge/quanticViewedByCustomerBadge.html +2 -2
- package/force-app/main/default/staticresources/coveoheadless/case-assist/headless.js +16 -16
- package/force-app/main/default/staticresources/coveoheadless/definitions/app/logger.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next/commerce/factories/build-factory.d.ts +1 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/ssr-next/commerce/types/build.d.ts +2 -2
- package/force-app/main/default/staticresources/coveoheadless/headless.js +20 -20
- package/force-app/main/default/staticresources/coveoheadless/insight/headless.js +17 -17
- package/force-app/main/default/staticresources/coveoheadless/recommendation/headless.js +15 -15
- package/package.json +6 -6
|
@@ -2925,7 +2925,7 @@
|
|
|
2925
2925
|
],
|
|
2926
2926
|
"fires": "",
|
|
2927
2927
|
"examples": [
|
|
2928
|
-
"<template if
|
|
2928
|
+
"<template lwc:if={result.raw.date}>\n <c-quantic-result-date result={result} label=\"Date\" field=\"date\"></c-quantic-result-date>\n</template>"
|
|
2929
2929
|
],
|
|
2930
2930
|
"xmlMeta": {
|
|
2931
2931
|
"apiVersion": "56.0",
|
|
@@ -2980,7 +2980,7 @@
|
|
|
2980
2980
|
],
|
|
2981
2981
|
"fires": "",
|
|
2982
2982
|
"examples": [
|
|
2983
|
-
"<template if
|
|
2983
|
+
"<template lwc:if={result.raw.source}>\n <c-quantic-result-field result={result} label=\"Source\" field=\"source\" type=\"string\"></c-quantic-result-field>\n</template>"
|
|
2984
2984
|
],
|
|
2985
2985
|
"xmlMeta": {
|
|
2986
2986
|
"apiVersion": "56.0",
|
|
@@ -3210,7 +3210,7 @@
|
|
|
3210
3210
|
],
|
|
3211
3211
|
"fires": "",
|
|
3212
3212
|
"examples": [
|
|
3213
|
-
"<template if
|
|
3213
|
+
"<template lwc:if={result.raw.language}>\n <c-quantic-result-multi-value-text result={result} label=\"Languages\" field=\"language\" max-values-to-display=\"4\"></c-quantic-result-multi-value-text>\n</template>"
|
|
3214
3214
|
],
|
|
3215
3215
|
"xmlMeta": {
|
|
3216
3216
|
"apiVersion": "56.0",
|
|
@@ -3274,7 +3274,7 @@
|
|
|
3274
3274
|
],
|
|
3275
3275
|
"fires": "",
|
|
3276
3276
|
"examples": [
|
|
3277
|
-
"<template if
|
|
3277
|
+
"<template lwc:if={result.raw.ytlikecount}>\n <c-quantic-result-number result={result} label=\"Likes\" field=\"ytlikecount\"></c-quantic-result-number>\n</template>"
|
|
3278
3278
|
],
|
|
3279
3279
|
"xmlMeta": {
|
|
3280
3280
|
"apiVersion": "56.0",
|
|
@@ -3542,7 +3542,7 @@
|
|
|
3542
3542
|
],
|
|
3543
3543
|
"fires": "",
|
|
3544
3544
|
"examples": [
|
|
3545
|
-
"<template if
|
|
3545
|
+
"<template lwc:if={result.raw.source}>\n <c-quantic-result-text result={result} label=\"Source\" field=\"source\"></c-quantic-result-text>\n</template>"
|
|
3546
3546
|
],
|
|
3547
3547
|
"xmlMeta": {
|
|
3548
3548
|
"apiVersion": "56.0",
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
</c-quantic-component-error>
|
|
5
5
|
</template>
|
|
6
6
|
<template lwc:else>
|
|
7
|
-
<template if
|
|
7
|
+
<template lwc:if={hasBreadcrumbs}>
|
|
8
8
|
<div class="slds-grid slds-grid_vertical-align-start slds-size_1-of-1 slds-var-m-vertical_x-small">
|
|
9
9
|
<div class="slds-col slds-truncate slds-col_bump-right breadcrumb-manager__column">
|
|
10
10
|
<ul>
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
<c-quantic-pill data-testid="facet-breadcrumb-value" label={breadcrumbValue.formattedValue} onquantic__deselect={breadcrumbValue.deselect} group-name={breadcrumb.label} action-name={labels.clearFilter}></c-quantic-pill>
|
|
18
18
|
</li>
|
|
19
19
|
</template>
|
|
20
|
-
<template if
|
|
20
|
+
<template lwc:if={breadcrumb.showMoreButton}>
|
|
21
21
|
<li>
|
|
22
22
|
<button onclick={breadcrumb.expandButtonClick} data-testid="breadcrumb-manager__more-button" class="slds-grid slds-button slds-var-m-around_xxx-small slds-p-horizontal_x-small slds-p-vertical_xx-small slds-text-color_default breadcrumb-manager__more-button">{breadcrumb.showMoreButtonText}</button>
|
|
23
23
|
</li>
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
<c-quantic-pill data-testid="numeric-facet-breadcrumb-value" label={breadcrumbValue.formattedValue} onquantic__deselect={breadcrumbValue.deselect} group-name={breadcrumb.label} action-name={labels.clearFilter}></c-quantic-pill>
|
|
35
35
|
</li>
|
|
36
36
|
</template>
|
|
37
|
-
<template if
|
|
37
|
+
<template lwc:if={breadcrumb.showMoreButton}>
|
|
38
38
|
<li>
|
|
39
39
|
<button onclick={breadcrumb.expandButtonClick} class="slds-grid slds-button slds-var-m-around_xxx-small slds-p-horizontal_x-small slds-p-vertical_xx-small slds-text-color_default breadcrumb-manager__more-button">{breadcrumb.showMoreButtonText}</button>
|
|
40
40
|
</li>
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
<c-quantic-pill data-testid="date-facet-breadcrumb-value" label={breadcrumbValue.value} onquantic__deselect={breadcrumbValue.deselect} group-name={breadcrumb.label} action-name={labels.clearFilter}></c-quantic-pill>
|
|
62
62
|
</li>
|
|
63
63
|
</template>
|
|
64
|
-
<template if
|
|
64
|
+
<template lwc:if={breadcrumb.showMoreButton}>
|
|
65
65
|
<li>
|
|
66
66
|
<button onclick={breadcrumb.expandButtonClick} class="slds-grid slds-button slds-var-m-around_xxx-small slds-p-horizontal_x-small slds-p-vertical_xx-small slds-text-color_default breadcrumb-manager__more-button">{breadcrumb.showMoreButtonText}</button>
|
|
67
67
|
</li>
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<template if
|
|
2
|
+
<template lwc:if={errorMessage}>
|
|
3
3
|
<c-quantic-component-error
|
|
4
4
|
component-name={template.host.localName}
|
|
5
5
|
message={errorMessage}
|
|
6
6
|
>
|
|
7
7
|
</c-quantic-component-error>
|
|
8
8
|
</template>
|
|
9
|
-
<template
|
|
9
|
+
<template lwc:else>
|
|
10
10
|
<section role="region" aria-roledescription={labels.carousel} aria-label={label}>
|
|
11
11
|
<div class="slds-grid carousel__container slds-is-relative">
|
|
12
12
|
<lightning-button-icon
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
>
|
|
15
15
|
{label}
|
|
16
16
|
</legend>
|
|
17
|
-
<template if
|
|
17
|
+
<template lwc:if={loading}>
|
|
18
18
|
<div class="loading-holder slds-is-relative slds-var-m-top_x-small">
|
|
19
19
|
<lightning-spinner
|
|
20
20
|
alternative-text={labels.loading}
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
></lightning-spinner>
|
|
23
23
|
</div>
|
|
24
24
|
</template>
|
|
25
|
-
<template
|
|
25
|
+
<template lwc:else>
|
|
26
26
|
<div
|
|
27
27
|
class="slds-form-element__control"
|
|
28
28
|
aria-describedby="case-classification-error-message"
|
|
29
29
|
>
|
|
30
30
|
<div class="slds-grid slds-wrap">
|
|
31
|
-
<template if
|
|
31
|
+
<template lwc:if={showSuggestions}>
|
|
32
32
|
<template for:each={suggestions} for:item="suggestion">
|
|
33
33
|
<div
|
|
34
34
|
key={suggestion.value}
|
|
@@ -60,19 +60,8 @@
|
|
|
60
60
|
</div>
|
|
61
61
|
</template>
|
|
62
62
|
</template>
|
|
63
|
-
<template if
|
|
64
|
-
<template if
|
|
65
|
-
<lightning-button
|
|
66
|
-
data-testid="show-select-input-button"
|
|
67
|
-
class="slds-var-m-top_x-small"
|
|
68
|
-
variant="base"
|
|
69
|
-
label={selectPlaceholder}
|
|
70
|
-
title={selectPlaceholder}
|
|
71
|
-
onclick={showSelect}
|
|
72
|
-
>
|
|
73
|
-
</lightning-button>
|
|
74
|
-
</template>
|
|
75
|
-
<template if:true={isSelectVisible}>
|
|
63
|
+
<template lwc:if={isMoreOptionsVisible}>
|
|
64
|
+
<template lwc:if={isSelectVisible}>
|
|
76
65
|
<lightning-combobox
|
|
77
66
|
data-testid="case-classification-all-options-combobox"
|
|
78
67
|
class="slds-var-m-top_x-small"
|
|
@@ -83,8 +72,19 @@
|
|
|
83
72
|
onchange={handleSelectChange}
|
|
84
73
|
></lightning-combobox>
|
|
85
74
|
</template>
|
|
75
|
+
<template lwc:else>
|
|
76
|
+
<lightning-button
|
|
77
|
+
data-testid="show-select-input-button"
|
|
78
|
+
class="slds-var-m-top_x-small"
|
|
79
|
+
variant="base"
|
|
80
|
+
label={selectPlaceholder}
|
|
81
|
+
title={selectPlaceholder}
|
|
82
|
+
onclick={showSelect}
|
|
83
|
+
>
|
|
84
|
+
</lightning-button>
|
|
85
|
+
</template>
|
|
86
86
|
</template>
|
|
87
|
-
<template
|
|
87
|
+
<template lwc:else>
|
|
88
88
|
<template for:each={filteredOptions} for:item="option">
|
|
89
89
|
<div
|
|
90
90
|
key={option.value}
|
|
@@ -117,7 +117,7 @@
|
|
|
117
117
|
</template>
|
|
118
118
|
</div>
|
|
119
119
|
</div>
|
|
120
|
-
<template if
|
|
120
|
+
<template lwc:if={hasError}>
|
|
121
121
|
<div
|
|
122
122
|
data-testid="case-classification-error-message"
|
|
123
123
|
class="slds-form-element__help"
|
|
@@ -167,7 +167,7 @@ export default class QuanticCaseClassification extends LightningElement {
|
|
|
167
167
|
/** @type {boolean} */
|
|
168
168
|
hasInitializationError = false;
|
|
169
169
|
/** @type {boolean} */
|
|
170
|
-
|
|
170
|
+
showSuggestions = true;
|
|
171
171
|
/** @type {boolean} */
|
|
172
172
|
lockedState = false;
|
|
173
173
|
/** @type {boolean} */
|
|
@@ -498,10 +498,10 @@ export default class QuanticCaseClassification extends LightningElement {
|
|
|
498
498
|
!this.isSuggestion(this._value) &&
|
|
499
499
|
this.isMoreOptionsVisible
|
|
500
500
|
) {
|
|
501
|
-
this.
|
|
501
|
+
this.showSuggestions = false;
|
|
502
502
|
this.showSelect();
|
|
503
503
|
} else {
|
|
504
|
-
this.
|
|
504
|
+
this.showSuggestions = true;
|
|
505
505
|
this.hideSelect();
|
|
506
506
|
}
|
|
507
507
|
}
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
<template lwc:else>
|
|
7
7
|
<template lwc:if={isFacetEnabled}>
|
|
8
8
|
<div data-testid="facet-content">
|
|
9
|
-
<template if
|
|
9
|
+
<template lwc:if={showPlaceholder}>
|
|
10
10
|
<c-quantic-placeholder
|
|
11
11
|
variant="card"
|
|
12
12
|
number-of-rows={numberOfValues}
|
|
13
13
|
></c-quantic-placeholder>
|
|
14
14
|
</template>
|
|
15
|
-
<template if
|
|
15
|
+
<template lwc:if={hasParentsOrValues}>
|
|
16
16
|
<div class="slds-size_1-of-1 slds-var-m-bottom_large">
|
|
17
17
|
<c-quantic-card-container
|
|
18
18
|
title={label}
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
aria-hidden="true"
|
|
31
31
|
>
|
|
32
32
|
</lightning-button-icon>
|
|
33
|
-
<template if
|
|
33
|
+
<template lwc:if={isExpanded}>
|
|
34
34
|
<ul data-testid="facet__body" class="slds-has-dividers_around-space slds-m-top_medium">
|
|
35
|
-
<template if
|
|
35
|
+
<template lwc:if={withSearch}>
|
|
36
36
|
<div onchange={handleKeyUp} class="slds-size_1-of-1">
|
|
37
37
|
<lightning-input
|
|
38
38
|
data-testid="facet__searchbox-input"
|
|
@@ -45,8 +45,44 @@
|
|
|
45
45
|
></lightning-input>
|
|
46
46
|
</div>
|
|
47
47
|
</template>
|
|
48
|
-
<template if
|
|
49
|
-
<template if
|
|
48
|
+
<template lwc:if={isFacetSearchActive}>
|
|
49
|
+
<template lwc:if={hasSearchResults}>
|
|
50
|
+
<template for:each={facetSearchResults} for:item="result">
|
|
51
|
+
<c-quantic-category-facet-value
|
|
52
|
+
data-testid="facet-search-value"
|
|
53
|
+
key={result.index}
|
|
54
|
+
item={result}
|
|
55
|
+
is-search-result="true"
|
|
56
|
+
formatting-function={remoteGetValueCaption}
|
|
57
|
+
onquantic__selectvalue={onSelectValue}
|
|
58
|
+
>
|
|
59
|
+
</c-quantic-category-facet-value>
|
|
60
|
+
</template>
|
|
61
|
+
</template>
|
|
62
|
+
<div class="slds-p-horizontal_x-small">
|
|
63
|
+
<template lwc:if={hasNoSearchResults}>
|
|
64
|
+
<li class="slds-grid slds-var-m-top_x-small">
|
|
65
|
+
<span
|
|
66
|
+
data-testid="facet-search__no-match"
|
|
67
|
+
class="slds-truncate slds-var-p-around_small slds-size_1-of-1 facet__search-results_no-match"
|
|
68
|
+
>
|
|
69
|
+
{noMatchesForLabel}
|
|
70
|
+
</span>
|
|
71
|
+
</li>
|
|
72
|
+
</template>
|
|
73
|
+
<template lwc:if={canShowMoreSearchResults}>
|
|
74
|
+
<li>
|
|
75
|
+
<span
|
|
76
|
+
data-testid="facet-search__more-matches"
|
|
77
|
+
class="slds-truncate facet__search-results_more-matches"
|
|
78
|
+
>{moreMatchesForLabel}</span
|
|
79
|
+
>
|
|
80
|
+
</li>
|
|
81
|
+
</template>
|
|
82
|
+
</div>
|
|
83
|
+
</template>
|
|
84
|
+
<template lwc:else>
|
|
85
|
+
<template lwc:if={hasParents}>
|
|
50
86
|
<li
|
|
51
87
|
class="facet__value-option slds-size_1-of-1 slds-p-around_x-small"
|
|
52
88
|
>
|
|
@@ -85,7 +121,7 @@
|
|
|
85
121
|
></c-quantic-category-facet-value>
|
|
86
122
|
</li>
|
|
87
123
|
</template>
|
|
88
|
-
<template if
|
|
124
|
+
<template lwc:if={activeParent}>
|
|
89
125
|
<li
|
|
90
126
|
class="facet__active-parent slds-grid slds-grid_vertical-align-center slds-p-around_x-small slds-m-left_medium"
|
|
91
127
|
>
|
|
@@ -131,47 +167,11 @@
|
|
|
131
167
|
</fieldset>
|
|
132
168
|
</li>
|
|
133
169
|
</template>
|
|
134
|
-
<template if:true={isFacetSearchActive}>
|
|
135
|
-
<template if:true={hasSearchResults}>
|
|
136
|
-
<template for:each={facetSearchResults} for:item="result">
|
|
137
|
-
<c-quantic-category-facet-value
|
|
138
|
-
data-testid="facet-search-value"
|
|
139
|
-
key={result.index}
|
|
140
|
-
item={result}
|
|
141
|
-
is-search-result="true"
|
|
142
|
-
formatting-function={remoteGetValueCaption}
|
|
143
|
-
onquantic__selectvalue={onSelectValue}
|
|
144
|
-
>
|
|
145
|
-
</c-quantic-category-facet-value>
|
|
146
|
-
</template>
|
|
147
|
-
</template>
|
|
148
|
-
<div class="slds-p-horizontal_x-small">
|
|
149
|
-
<template if:false={hasSearchResults}>
|
|
150
|
-
<li class="slds-grid slds-var-m-top_x-small">
|
|
151
|
-
<span
|
|
152
|
-
data-testid="facet-search__no-match"
|
|
153
|
-
class="slds-truncate slds-var-p-around_small slds-size_1-of-1 facet__search-results_no-match"
|
|
154
|
-
>
|
|
155
|
-
{noMatchesForLabel}
|
|
156
|
-
</span>
|
|
157
|
-
</li>
|
|
158
|
-
</template>
|
|
159
|
-
<template if:true={canShowMoreSearchResults}>
|
|
160
|
-
<li>
|
|
161
|
-
<span
|
|
162
|
-
data-testid="facet-search__more-matches"
|
|
163
|
-
class="slds-truncate facet__search-results_more-matches"
|
|
164
|
-
>{moreMatchesForLabel}</span
|
|
165
|
-
>
|
|
166
|
-
</li>
|
|
167
|
-
</template>
|
|
168
|
-
</div>
|
|
169
|
-
</template>
|
|
170
170
|
</ul>
|
|
171
171
|
<div
|
|
172
172
|
class="facet__show slds-m-top_x-small slds-p-horizontal_x-small"
|
|
173
173
|
>
|
|
174
|
-
<template if
|
|
174
|
+
<template lwc:if={canShowLess}>
|
|
175
175
|
<button
|
|
176
176
|
data-testid="facet-values__show-less"
|
|
177
177
|
variant="base"
|
|
@@ -185,7 +185,7 @@
|
|
|
185
185
|
>
|
|
186
186
|
</button>
|
|
187
187
|
</template>
|
|
188
|
-
<template if
|
|
188
|
+
<template lwc:if={canShowMore}>
|
|
189
189
|
<button
|
|
190
190
|
data-testid="facet-values__show-more"
|
|
191
191
|
variant="base"
|
|
@@ -172,6 +172,11 @@ export default class QuanticCategoryFacet extends LightningElement {
|
|
|
172
172
|
}
|
|
173
173
|
/** @type {boolean} */
|
|
174
174
|
_isCollapsed = false;
|
|
175
|
+
|
|
176
|
+
get isExpanded() {
|
|
177
|
+
return !this.isCollapsed;
|
|
178
|
+
}
|
|
179
|
+
|
|
175
180
|
static attributes = [
|
|
176
181
|
'facetId',
|
|
177
182
|
'field',
|
|
@@ -405,6 +410,10 @@ export default class QuanticCategoryFacet extends LightningElement {
|
|
|
405
410
|
return this.getSearchValues().length > 0;
|
|
406
411
|
}
|
|
407
412
|
|
|
413
|
+
get hasNoSearchResults() {
|
|
414
|
+
return !this.hasSearchResults;
|
|
415
|
+
}
|
|
416
|
+
|
|
408
417
|
get canShowMoreSearchResults() {
|
|
409
418
|
return this.facet?.state.facetSearch.moreValuesAvailable;
|
|
410
419
|
}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
onkeydown={onKeyDown}
|
|
9
9
|
aria-label={ariaLabelValue}
|
|
10
10
|
>
|
|
11
|
-
<template if
|
|
11
|
+
<template lwc:if={nonActiveParent}>
|
|
12
12
|
<div
|
|
13
13
|
class="facet__parent-value-option facet__value-option slds-grid slds-truncate slds-grid_vertical-align-center slds-size_1-of-1 slds-p-around_x-small"
|
|
14
14
|
>
|
|
@@ -17,16 +17,8 @@
|
|
|
17
17
|
<span class="facet__number-of-results slds-var-m-left_xx-small">({numberOfResults})</span>
|
|
18
18
|
</div>
|
|
19
19
|
</template>
|
|
20
|
-
<template
|
|
21
|
-
<template if
|
|
22
|
-
<div
|
|
23
|
-
class="slds-grid slds-grid_vertical-align-center slds-text-color_default facet__child-value-option facet__value-option slds-size_1-of-1 slds-p-around_x-small"
|
|
24
|
-
>
|
|
25
|
-
<span class="slds-truncate" title={facetValue}>{facetValue}</span>
|
|
26
|
-
<span class="facet__number-of-results slds-var-m-left_xx-small">({numberOfResults})</span>
|
|
27
|
-
</div>
|
|
28
|
-
</template>
|
|
29
|
-
<template if:true={isSearchResult}>
|
|
20
|
+
<template lwc:else>
|
|
21
|
+
<template lwc:if={isSearchResult}>
|
|
30
22
|
<div class="facet__value-option slds-size_1-of-1 slds-p-around_x-small slds-text-color_default">
|
|
31
23
|
<div class="slds-grid slds-grid_vertical slds-size_1-of-1">
|
|
32
24
|
<div
|
|
@@ -45,6 +37,14 @@
|
|
|
45
37
|
</div>
|
|
46
38
|
</div>
|
|
47
39
|
</template>
|
|
40
|
+
<template lwc:else>
|
|
41
|
+
<div
|
|
42
|
+
class="slds-grid slds-grid_vertical-align-center slds-text-color_default facet__child-value-option facet__value-option slds-size_1-of-1 slds-p-around_x-small"
|
|
43
|
+
>
|
|
44
|
+
<span class="slds-truncate" title={facetValue}>{facetValue}</span>
|
|
45
|
+
<span class="facet__number-of-results slds-var-m-left_xx-small">({numberOfResults})</span>
|
|
46
|
+
</div>
|
|
47
|
+
</template>
|
|
48
48
|
</template>
|
|
49
49
|
</div>
|
|
50
50
|
</template>
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<template if
|
|
2
|
+
<template lwc:if={error}>
|
|
3
3
|
<div class="error-message slds-text-color_destructive">{error}</div>
|
|
4
4
|
</template>
|
|
5
|
-
<template if
|
|
6
|
-
<template if
|
|
5
|
+
<template lwc:if={isValid}>
|
|
6
|
+
<template lwc:if={hasTextToDisplay}>
|
|
7
7
|
<div class="slds-badge slds-var-p-horizontal_medium slds-truncate result-badge">
|
|
8
|
-
<template if
|
|
8
|
+
<template lwc:if={hasLabel}>
|
|
9
9
|
{label}
|
|
10
10
|
</template>
|
|
11
|
-
<template
|
|
11
|
+
<template lwc:else>
|
|
12
12
|
<c-quantic-result-field result={result} field={field} type={type}></c-quantic-result-field>
|
|
13
13
|
</template>
|
|
14
14
|
</div>
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
<template lwc:else>
|
|
7
7
|
<template lwc:if={isFacetEnabled}>
|
|
8
8
|
<div data-test="facet-content">
|
|
9
|
-
<template if
|
|
9
|
+
<template lwc:if={showPlaceholder}>
|
|
10
10
|
<c-quantic-placeholder
|
|
11
11
|
variant="card"
|
|
12
12
|
number-of-rows={numberOfValues}
|
|
13
13
|
></c-quantic-placeholder>
|
|
14
14
|
</template>
|
|
15
|
-
<template if
|
|
15
|
+
<template lwc:if={hasValues}>
|
|
16
16
|
<div class="slds-size_1-of-1">
|
|
17
17
|
<c-quantic-card-container
|
|
18
18
|
title={label}
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
aria-hidden="true"
|
|
31
31
|
>
|
|
32
32
|
</lightning-button-icon>
|
|
33
|
-
<template if
|
|
33
|
+
<template lwc:if={hasActiveValues}>
|
|
34
34
|
<button
|
|
35
35
|
data-testid="clear-selection-button"
|
|
36
36
|
class="facet__clear-filter slds-button slds-grid slds-grid_vertical-align-center slds-p-horizontal_x-small slds-m-top_small"
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
>
|
|
50
50
|
</button>
|
|
51
51
|
</template>
|
|
52
|
-
<template if
|
|
52
|
+
<template lwc:if={isExpanded}>
|
|
53
53
|
<fieldset data-testid="facet__body">
|
|
54
54
|
<legend class="slds-assistive-text">{field}</legend>
|
|
55
55
|
<ul class="slds-has-dividers_around-space slds-m-top_medium">
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<template if
|
|
2
|
+
<template lwc:if={wasAutomaticallyCorrected}>
|
|
3
3
|
<div class="slds-var-m-vertical_x-small">
|
|
4
4
|
<p class="slds-var-m-bottom_xx-small">
|
|
5
5
|
<lightning-formatted-rich-text data-testid="no-result-label"
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
value={correctedQueryLabel}></lightning-formatted-rich-text>
|
|
10
10
|
</div>
|
|
11
11
|
</template>
|
|
12
|
-
<template
|
|
12
|
+
<template lwc:else>
|
|
13
13
|
<div class="slds-var-m-vertical_x-small">
|
|
14
14
|
<span data-testid="did-you-mean-label">{labels.didYouMean} </span>
|
|
15
15
|
<button data-testid="apply-correction-button" class="slds-button" onclick={applyCorrection}>
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
</c-quantic-component-error>
|
|
5
5
|
</template>
|
|
6
6
|
<template lwc:else>
|
|
7
|
-
<template if
|
|
7
|
+
<template lwc:if={loading}>
|
|
8
8
|
<div class="loading-holder">
|
|
9
9
|
<lightning-spinner alternative-text={labels.loading}></lightning-spinner>
|
|
10
10
|
</div>
|
|
11
11
|
</template>
|
|
12
|
-
<template
|
|
13
|
-
<template if
|
|
12
|
+
<template lwc:else>
|
|
13
|
+
<template lwc:if={hasSuggestions}>
|
|
14
14
|
<div class="slds-card card-border">
|
|
15
15
|
<lightning-accordion active-section-name={openedDocuments} allow-multiple-sections-open
|
|
16
16
|
class="slds-p-vertical_xx-small">
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
</lightning-accordion>
|
|
44
44
|
</div>
|
|
45
45
|
</template>
|
|
46
|
-
<template
|
|
46
|
+
<template lwc:else>
|
|
47
47
|
<slot name="no-suggestions">
|
|
48
48
|
<div class="
|
|
49
49
|
no-suggestion-message
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
<template lwc:else>
|
|
7
7
|
<template lwc:if={isFacetEnabled}>
|
|
8
8
|
<div data-test="facet-content">
|
|
9
|
-
<template if
|
|
9
|
+
<template lwc:if={showPlaceholder}>
|
|
10
10
|
<c-quantic-placeholder
|
|
11
11
|
variant="card"
|
|
12
12
|
number-of-rows={numberOfValues}
|
|
13
13
|
></c-quantic-placeholder>
|
|
14
14
|
</template>
|
|
15
|
-
<template if
|
|
15
|
+
<template lwc:if={hasValues}>
|
|
16
16
|
<div class="slds-size_1-of-1 slds-var-m-bottom_large">
|
|
17
17
|
<c-quantic-card-container
|
|
18
18
|
title={label}
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
aria-hidden="true"
|
|
31
31
|
>
|
|
32
32
|
</lightning-button-icon>
|
|
33
|
-
<template if
|
|
33
|
+
<template lwc:if={hasActiveValues}>
|
|
34
34
|
<button
|
|
35
35
|
data-testid="clear-selection-button"
|
|
36
36
|
class="facet__clear-filter slds-button slds-grid slds-grid_vertical-align-center slds-p-horizontal_x-small slds-m-top_small"
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
>
|
|
50
50
|
</button>
|
|
51
51
|
</template>
|
|
52
|
-
<template if
|
|
52
|
+
<template lwc:if={isExpanded}>
|
|
53
53
|
<div data-testid="facet__body" class="slds-has-dividers_around-space slds-m-top_medium">
|
|
54
|
-
<template if
|
|
54
|
+
<template lwc:if={displaySearch}>
|
|
55
55
|
<div onchange={handleKeyUp} class="slds-size_1-of-1">
|
|
56
56
|
<lightning-input
|
|
57
57
|
data-testid="facet__searchbox-input"
|
|
@@ -65,7 +65,42 @@
|
|
|
65
65
|
</div>
|
|
66
66
|
</template>
|
|
67
67
|
|
|
68
|
-
<template if
|
|
68
|
+
<template lwc:if={isFacetSearchActive}>
|
|
69
|
+
<template lwc:if={hasSearchResults}>
|
|
70
|
+
<template for:each={facetSearchResults} for:item="result">
|
|
71
|
+
<c-quantic-facet-value
|
|
72
|
+
onquantic__selectvalue={onSelectValue}
|
|
73
|
+
key={result.value}
|
|
74
|
+
item={result}
|
|
75
|
+
is-checked={result.checked}
|
|
76
|
+
display-as-link={isDisplayAsLink}
|
|
77
|
+
formatting-function={remoteGetValueCaption}
|
|
78
|
+
>
|
|
79
|
+
</c-quantic-facet-value>
|
|
80
|
+
</template>
|
|
81
|
+
</template>
|
|
82
|
+
<div class="slds-p-horizontal_x-small">
|
|
83
|
+
<template lwc:if={hasNoSearchResults}>
|
|
84
|
+
<li data-testid="facet-search__no-match" class="slds-grid slds-m-top_x-small">
|
|
85
|
+
<span
|
|
86
|
+
class="slds-truncate slds-p-around_small slds-size_1-of-1 facet__search-results_no-match"
|
|
87
|
+
>
|
|
88
|
+
{noMatchesForLabel}
|
|
89
|
+
</span>
|
|
90
|
+
</li>
|
|
91
|
+
</template>
|
|
92
|
+
<template lwc:if={canShowMoreSearchResults}>
|
|
93
|
+
<li data-testid="facet-search__more-match" class="slds-grid">
|
|
94
|
+
<span
|
|
95
|
+
class="slds-truncate facet__search-results_more-matches"
|
|
96
|
+
>{moreMatchesForLabel}</span
|
|
97
|
+
>
|
|
98
|
+
</li>
|
|
99
|
+
</template>
|
|
100
|
+
</div>
|
|
101
|
+
</template>
|
|
102
|
+
|
|
103
|
+
<template lwc:else>
|
|
69
104
|
<fieldset>
|
|
70
105
|
<legend class="slds-assistive-text">{field}</legend>
|
|
71
106
|
<ul>
|
|
@@ -87,7 +122,7 @@
|
|
|
87
122
|
<div
|
|
88
123
|
class="facet__show slds-m-top_x-small slds-p-horizontal_x-small"
|
|
89
124
|
>
|
|
90
|
-
<template if
|
|
125
|
+
<template lwc:if={canShowLess}>
|
|
91
126
|
<button
|
|
92
127
|
variant="base"
|
|
93
128
|
class="facet__show-less slds-p-around_none"
|
|
@@ -100,7 +135,7 @@
|
|
|
100
135
|
>
|
|
101
136
|
</button>
|
|
102
137
|
</template>
|
|
103
|
-
<template if
|
|
138
|
+
<template lwc:if={canShowMore}>
|
|
104
139
|
<button
|
|
105
140
|
variant="base"
|
|
106
141
|
class="facet__show-more slds-p-around_none"
|
|
@@ -115,41 +150,6 @@
|
|
|
115
150
|
</template>
|
|
116
151
|
</div>
|
|
117
152
|
</template>
|
|
118
|
-
|
|
119
|
-
<template if:true={isFacetSearchActive}>
|
|
120
|
-
<template if:true={hasSearchResults}>
|
|
121
|
-
<template for:each={facetSearchResults} for:item="result">
|
|
122
|
-
<c-quantic-facet-value
|
|
123
|
-
onquantic__selectvalue={onSelectValue}
|
|
124
|
-
key={result.value}
|
|
125
|
-
item={result}
|
|
126
|
-
is-checked={result.checked}
|
|
127
|
-
display-as-link={isDisplayAsLink}
|
|
128
|
-
formatting-function={remoteGetValueCaption}
|
|
129
|
-
>
|
|
130
|
-
</c-quantic-facet-value>
|
|
131
|
-
</template>
|
|
132
|
-
</template>
|
|
133
|
-
<div class="slds-p-horizontal_x-small">
|
|
134
|
-
<template if:false={hasSearchResults}>
|
|
135
|
-
<li data-testid="facet-search__no-match" class="slds-grid slds-m-top_x-small">
|
|
136
|
-
<span
|
|
137
|
-
class="slds-truncate slds-p-around_small slds-size_1-of-1 facet__search-results_no-match"
|
|
138
|
-
>
|
|
139
|
-
{noMatchesForLabel}
|
|
140
|
-
</span>
|
|
141
|
-
</li>
|
|
142
|
-
</template>
|
|
143
|
-
<template if:true={canShowMoreSearchResults}>
|
|
144
|
-
<li data-testid="facet-search__more-match" class="slds-grid">
|
|
145
|
-
<span
|
|
146
|
-
class="slds-truncate facet__search-results_more-matches"
|
|
147
|
-
>{moreMatchesForLabel}</span
|
|
148
|
-
>
|
|
149
|
-
</li>
|
|
150
|
-
</template>
|
|
151
|
-
</div>
|
|
152
|
-
</template>
|
|
153
153
|
</div>
|
|
154
154
|
</template>
|
|
155
155
|
</c-quantic-card-container>
|