@coveo/atomic-react 3.11.42 → 3.11.43
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/cjs/atomic-react.cjs +84 -44
- package/dist/cjs/atomic-react.cjs.map +1 -1
- package/dist/cjs/commerce/atomic-react.cjs +2 -2
- package/dist/cjs/commerce/atomic-react.cjs.map +1 -1
- package/dist/cjs/recommendation/atomic-react.cjs +84 -44
- package/dist/cjs/recommendation/atomic-react.cjs.map +1 -1
- package/package.json +3 -3
|
@@ -5092,7 +5092,7 @@ const renderCategoryFacetSearchValue = ({ props })=>{
|
|
|
5092
5092
|
|
|
5093
5093
|
const renderCategoryFacetTreeValueContainer = ()=>(children)=>lit.html`<li class="contents">${children}</li>`;
|
|
5094
5094
|
|
|
5095
|
-
const styles$r = lit.css`/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.value-count{margin-left:calc(var(--spacing,.25rem)*1.5);color:var(--atomic-neutral-dark)}[part=value-exclude-button]+.value-count{margin-right:calc(var(--spacing,.25rem)*2)}:host(.popover-nested){min-width:var(--container-2xs,18rem)}:host(.popover-nested)::part(label-button){display:none}:host(.popover-nested)::part(facet){--tw-shadow:0px 2px 8px var(--tw-shadow-color,#e5e8e8bf);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}:host(.popover-nested)::part(values){max-height:calc(var(--spacing,.25rem)*96);margin-top:0;overflow-y:auto}:host(.popover-nested)::part(search-wrapper){margin-bottom:calc(var(--spacing,.25rem)*2)}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}`;
|
|
5095
|
+
const styles$r = lit.css`/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.value-count{margin-left:calc(var(--spacing,.25rem)*1.5);color:var(--atomic-neutral-dark)}[part=value-exclude-button]+.value-count{margin-right:calc(var(--spacing,.25rem)*2)}:host(:state(hidden)){display:none}:host(.popover-nested){min-width:var(--container-2xs,18rem)}:host(.popover-nested)::part(label-button){display:none}:host(.popover-nested)::part(facet){--tw-shadow:0px 2px 8px var(--tw-shadow-color,#e5e8e8bf);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}:host(.popover-nested)::part(values){max-height:calc(var(--spacing,.25rem)*96);margin-top:0;overflow-y:auto}:host(.popover-nested)::part(search-wrapper){margin-bottom:calc(var(--spacing,.25rem)*2)}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}`;
|
|
5096
5096
|
const facet_common_tw_css = styles$r;
|
|
5097
5097
|
|
|
5098
5098
|
const styles$q = lit.css`/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */input[type=text]:focus-visible~.search-icon{color:var(--atomic-primary)}input[type=text]:hover~.search-icon{color:var(--atomic-primary-light)}.search-icon atomic-icon{width:var(--atomic-facet-search-icon-size,.75rem);height:var(--atomic-facet-search-icon-size,.75rem)}.search-clear-button atomic-icon{width:var(--atomic-facet-search-clear-icon-size,.625rem);height:var(--atomic-facet-search-clear-icon-size,.625rem)}`;
|
|
@@ -8302,7 +8302,7 @@ function getWindow$1() {
|
|
|
8302
8302
|
}
|
|
8303
8303
|
function getAtomicEnvironment(headlessVersion) {
|
|
8304
8304
|
return {
|
|
8305
|
-
version: "3.61.
|
|
8305
|
+
version: "3.61.3",
|
|
8306
8306
|
headlessVersion
|
|
8307
8307
|
};
|
|
8308
8308
|
}
|
|
@@ -21850,6 +21850,18 @@ function initializePopover(host, childFacet) {
|
|
|
21850
21850
|
host.dispatchEvent(buildCustomEvent('atomic/initializePopover', childFacet));
|
|
21851
21851
|
}
|
|
21852
21852
|
|
|
21853
|
+
class FacetVisibilityController {
|
|
21854
|
+
hostUpdate() {
|
|
21855
|
+
if (this.isHidden()) this.internals.states.add('hidden');
|
|
21856
|
+
else this.internals.states.delete('hidden');
|
|
21857
|
+
}
|
|
21858
|
+
constructor(host, isHidden){
|
|
21859
|
+
this.isHidden = isHidden;
|
|
21860
|
+
this.internals = host.attachInternals();
|
|
21861
|
+
host.addController(this);
|
|
21862
|
+
}
|
|
21863
|
+
}
|
|
21864
|
+
|
|
21853
21865
|
class ResultTemplateProvider extends TemplateProvider {
|
|
21854
21866
|
makeDefaultTemplate() {
|
|
21855
21867
|
const content = document.createDocumentFragment();
|
|
@@ -23589,22 +23601,27 @@ class TimeframeFacetCommon {
|
|
|
23589
23601
|
this.facetForDatePickerDependenciesManager?.stopWatching();
|
|
23590
23602
|
this.filterDependenciesManager?.stopWatching();
|
|
23591
23603
|
}
|
|
23592
|
-
|
|
23593
|
-
return !this.
|
|
23604
|
+
isHostHidden({ hasError, firstSearchExecuted }) {
|
|
23605
|
+
return hasError || !this.enabled || firstSearchExecuted && this.facetInfo.isHidden();
|
|
23594
23606
|
}
|
|
23595
|
-
|
|
23596
|
-
|
|
23607
|
+
get facetInfo() {
|
|
23608
|
+
return {
|
|
23597
23609
|
label: ()=>this.props.bindings.i18n.t(this.props.label),
|
|
23598
23610
|
facetId: this.facetId,
|
|
23599
23611
|
element: this.props.host,
|
|
23600
23612
|
isHidden: ()=>this.isHidden
|
|
23601
23613
|
};
|
|
23614
|
+
}
|
|
23615
|
+
get isHidden() {
|
|
23616
|
+
return !this.shouldRenderFacet || !this.enabled;
|
|
23617
|
+
}
|
|
23618
|
+
registerFacetToStore() {
|
|
23602
23619
|
this.props.bindings.store.registerFacet('dateFacets', {
|
|
23603
|
-
...facetInfo,
|
|
23620
|
+
...this.facetInfo,
|
|
23604
23621
|
format: (value)=>this.formatFacetValue(value)
|
|
23605
23622
|
});
|
|
23606
23623
|
initializePopover(this.props.host, {
|
|
23607
|
-
...facetInfo,
|
|
23624
|
+
...this.facetInfo,
|
|
23608
23625
|
hasValues: ()=>this.hasValues,
|
|
23609
23626
|
numberOfActiveValues: ()=>this.numberOfSelectedValues
|
|
23610
23627
|
});
|
|
@@ -23701,14 +23718,16 @@ class TimeframeFacetCommon {
|
|
|
23701
23718
|
></atomic-facet-date-input>`;
|
|
23702
23719
|
}
|
|
23703
23720
|
render({ hasError, firstSearchExecuted, isCollapsed, headerFocus, onToggleCollapse }) {
|
|
23704
|
-
if (
|
|
23721
|
+
if (this.isHostHidden({
|
|
23722
|
+
hasError,
|
|
23723
|
+
firstSearchExecuted
|
|
23724
|
+
})) return lit.nothing;
|
|
23705
23725
|
if (!firstSearchExecuted) return renderFacetPlaceholder({
|
|
23706
23726
|
props: {
|
|
23707
23727
|
numberOfValues: this.currentValues.length,
|
|
23708
23728
|
isCollapsed
|
|
23709
23729
|
}
|
|
23710
23730
|
});
|
|
23711
|
-
if (!this.shouldRenderFacet) return lit.nothing;
|
|
23712
23731
|
return renderFacetContainer()(lit.html`${this.renderHeader(isCollapsed, headerFocus, onToggleCollapse)}
|
|
23713
23732
|
${!isCollapsed ? lit.html`${this.shouldRenderValues ? this.renderValues() : lit.nothing}
|
|
23714
23733
|
${this.shouldRenderInput ? this.renderDateInput() : lit.nothing}` : lit.nothing}`);
|
|
@@ -25591,6 +25610,14 @@ function _ts_metadata$Y(metadataKey, metadataValue) {
|
|
|
25591
25610
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(metadataKey, metadataValue);
|
|
25592
25611
|
}
|
|
25593
25612
|
let AtomicCategoryFacet$1 = class AtomicCategoryFacet extends lit.LitElement {
|
|
25613
|
+
get facetInfo() {
|
|
25614
|
+
return {
|
|
25615
|
+
label: ()=>this.bindings.i18n.t(this.label),
|
|
25616
|
+
facetId: this.facetId,
|
|
25617
|
+
element: this,
|
|
25618
|
+
isHidden: ()=>this.isHidden
|
|
25619
|
+
};
|
|
25620
|
+
}
|
|
25594
25621
|
initialize() {
|
|
25595
25622
|
if (this.tabsIncluded.length > 0 && this.tabsExcluded.length > 0) console.warn('Values for both "tabs-included" and "tabs-excluded" have been provided. This could lead to unexpected behaviors.');
|
|
25596
25623
|
this.searchStatus = headless.buildSearchStatus(this.bindings.engine);
|
|
@@ -25620,15 +25647,9 @@ let AtomicCategoryFacet$1 = class AtomicCategoryFacet extends lit.LitElement {
|
|
|
25620
25647
|
announceFacetSearchResultsWithAriaLive(this.facet, this.label, (msg)=>{
|
|
25621
25648
|
this.facetSearchAriaMessage.message = msg;
|
|
25622
25649
|
}, this.bindings.i18n);
|
|
25623
|
-
|
|
25624
|
-
label: ()=>this.bindings.i18n.t(this.label),
|
|
25625
|
-
facetId: this.facetId,
|
|
25626
|
-
element: this,
|
|
25627
|
-
isHidden: ()=>this.isHidden
|
|
25628
|
-
};
|
|
25629
|
-
this.bindings.store.registerFacet('categoryFacets', facetInfo);
|
|
25650
|
+
this.bindings.store.registerFacet('categoryFacets', this.facetInfo);
|
|
25630
25651
|
initializePopover(this, {
|
|
25631
|
-
...facetInfo,
|
|
25652
|
+
...this.facetInfo,
|
|
25632
25653
|
hasValues: ()=>!!this.facet.state.valuesAsTrees.length,
|
|
25633
25654
|
numberOfActiveValues: ()=>this.facetState.hasActiveValues ? 1 : 0
|
|
25634
25655
|
});
|
|
@@ -25904,6 +25925,7 @@ let AtomicCategoryFacet$1 = class AtomicCategoryFacet extends lit.LitElement {
|
|
|
25904
25925
|
}
|
|
25905
25926
|
constructor(){
|
|
25906
25927
|
super(), this.resultIndexToFocusOnShowMore = 0, this.label = 'no-label', this.tabsIncluded = [], this.tabsExcluded = [], this.numberOfValues = 8, this.withSearch = false, this.sortCriteria = 'occurrences', this.delimitingCharacter = ';', this.basePath = [], this.filterByBasePath = true, this.isCollapsed = false, this.headingLevel = 0, this.filterFacetCount = true, this.injectionDepth = 1000, this.facetSearchAriaMessage = new AriaLiveRegionController(this, 'facet-search');
|
|
25928
|
+
new FacetVisibilityController(this, ()=>!!this.facet && this.facetInfo.isHidden());
|
|
25907
25929
|
new ValidatePropsController(this, ()=>({
|
|
25908
25930
|
field: this.field,
|
|
25909
25931
|
numberOfValues: this.numberOfValues,
|
|
@@ -26425,6 +26447,7 @@ let AtomicColorFacet$1 = class AtomicColorFacet extends lit.LitElement {
|
|
|
26425
26447
|
}
|
|
26426
26448
|
constructor(){
|
|
26427
26449
|
super(), this.label = 'no-label', this.tabsIncluded = [], this.tabsExcluded = [], this.numberOfValues = 8, this.withSearch = true, this.sortCriteria = 'automatic', this.resultsMustMatch = 'atLeastOneValue', this.displayValuesAs = 'box', this.isCollapsed = false, this.headingLevel = 0, this.filterFacetCount = true, this.injectionDepth = 1000, this.allowedValues = [], this.customSort = [], this.valuesBeforeShowMore = new Set();
|
|
26450
|
+
new FacetVisibilityController(this, ()=>!!this.facet && this.facetInfo.isHidden());
|
|
26428
26451
|
new ValidatePropsController(this, ()=>({
|
|
26429
26452
|
field: this.field,
|
|
26430
26453
|
numberOfValues: this.numberOfValues,
|
|
@@ -27218,6 +27241,7 @@ let AtomicFacet$1 = class AtomicFacet extends lit.LitElement {
|
|
|
27218
27241
|
}
|
|
27219
27242
|
constructor(){
|
|
27220
27243
|
super(), this.label = 'no-label', this.tabsIncluded = [], this.tabsExcluded = [], this.numberOfValues = 8, this.withSearch = true, this.sortCriteria = 'automatic', this.resultsMustMatch = 'atLeastOneValue', this.displayValuesAs = 'checkbox', this.isCollapsed = false, this.headingLevel = 0, this.filterFacetCount = true, this.enableExclusion = false, this.injectionDepth = 1000, this.allowedValues = [], this.customSort = [], this.valuesBeforeShowMore = new Set();
|
|
27244
|
+
new FacetVisibilityController(this, ()=>!!this.facet && this.facetInfo.isHidden());
|
|
27221
27245
|
new ValidatePropsController(this, ()=>({
|
|
27222
27246
|
field: this.field,
|
|
27223
27247
|
numberOfValues: this.numberOfValues,
|
|
@@ -29347,6 +29371,14 @@ function _ts_metadata$H(metadataKey, metadataValue) {
|
|
|
29347
29371
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(metadataKey, metadataValue);
|
|
29348
29372
|
}
|
|
29349
29373
|
let AtomicNumericFacet$1 = class AtomicNumericFacet extends lit.LitElement {
|
|
29374
|
+
get facetInfo() {
|
|
29375
|
+
return {
|
|
29376
|
+
label: ()=>this.bindings.i18n.t(this.label),
|
|
29377
|
+
facetId: this.facetId,
|
|
29378
|
+
element: this,
|
|
29379
|
+
isHidden: ()=>this.isHidden
|
|
29380
|
+
};
|
|
29381
|
+
}
|
|
29350
29382
|
initialize() {
|
|
29351
29383
|
this.validateTabs();
|
|
29352
29384
|
this.initializeTabManager();
|
|
@@ -29506,14 +29538,8 @@ let AtomicNumericFacet$1 = class AtomicNumericFacet extends lit.LitElement {
|
|
|
29506
29538
|
});
|
|
29507
29539
|
}
|
|
29508
29540
|
registerFacetToStore() {
|
|
29509
|
-
const facetInfo = {
|
|
29510
|
-
label: ()=>this.bindings.i18n.t(this.label),
|
|
29511
|
-
facetId: this.facetId,
|
|
29512
|
-
element: this,
|
|
29513
|
-
isHidden: ()=>this.isHidden
|
|
29514
|
-
};
|
|
29515
29541
|
this.bindings.store.registerFacet('numericFacets', {
|
|
29516
|
-
...facetInfo,
|
|
29542
|
+
...this.facetInfo,
|
|
29517
29543
|
format: (value)=>formatHumanReadable({
|
|
29518
29544
|
facetValue: value,
|
|
29519
29545
|
logger: this.bindings.engine.logger,
|
|
@@ -29524,7 +29550,7 @@ let AtomicNumericFacet$1 = class AtomicNumericFacet extends lit.LitElement {
|
|
|
29524
29550
|
})
|
|
29525
29551
|
});
|
|
29526
29552
|
initializePopover(this, {
|
|
29527
|
-
...facetInfo,
|
|
29553
|
+
...this.facetInfo,
|
|
29528
29554
|
hasValues: ()=>this.hasValues,
|
|
29529
29555
|
numberOfActiveValues: ()=>this.numberOfSelectedValues
|
|
29530
29556
|
});
|
|
@@ -29625,6 +29651,7 @@ let AtomicNumericFacet$1 = class AtomicNumericFacet extends lit.LitElement {
|
|
|
29625
29651
|
}
|
|
29626
29652
|
constructor(){
|
|
29627
29653
|
super(), this.label = 'no-label', this.tabsIncluded = [], this.tabsExcluded = [], this.numberOfValues = 8, this.sortCriteria = 'ascending', this.rangeAlgorithm = 'equiprobable', this.displayValuesAs = 'checkbox', this.isCollapsed = false, this.headingLevel = 0, this.filterFacetCount = true, this.injectionDepth = 1000, this.manualRanges = [], this.formatter = defaultNumberFormatter, this.conditionManagers = [];
|
|
29654
|
+
new FacetVisibilityController(this, ()=>!!this.searchStatus && this.facetInfo.isHidden());
|
|
29628
29655
|
new ValidatePropsController(this, ()=>({
|
|
29629
29656
|
displayValuesAs: this.displayValuesAs,
|
|
29630
29657
|
withInput: this.withInput
|
|
@@ -30488,6 +30515,14 @@ let AtomicRatingFacet$1 = class AtomicRatingFacet extends lit.LitElement {
|
|
|
30488
30515
|
if (!this.headerFocus) this.headerFocus = new FocusTargetController(this, this.bindings);
|
|
30489
30516
|
return this.headerFocus;
|
|
30490
30517
|
}
|
|
30518
|
+
get facetInfo() {
|
|
30519
|
+
return {
|
|
30520
|
+
label: ()=>this.bindings.i18n.t(this.label),
|
|
30521
|
+
facetId: this.facetId,
|
|
30522
|
+
element: this,
|
|
30523
|
+
isHidden: ()=>this.isHidden
|
|
30524
|
+
};
|
|
30525
|
+
}
|
|
30491
30526
|
connectedCallback() {
|
|
30492
30527
|
super.connectedCallback();
|
|
30493
30528
|
if (void 0 === this.maxValueInIndex) this.maxValueInIndex = this.numberOfIntervals;
|
|
@@ -30533,19 +30568,13 @@ let AtomicRatingFacet$1 = class AtomicRatingFacet extends lit.LitElement {
|
|
|
30533
30568
|
options
|
|
30534
30569
|
});
|
|
30535
30570
|
this.facetId = this.facet.state.facetId;
|
|
30536
|
-
const facetInfo = {
|
|
30537
|
-
label: ()=>this.bindings.i18n.t(this.label),
|
|
30538
|
-
facetId: this.facetId,
|
|
30539
|
-
element: this,
|
|
30540
|
-
isHidden: ()=>this.isHidden
|
|
30541
|
-
};
|
|
30542
30571
|
this.bindings.store.registerFacet('numericFacets', {
|
|
30543
|
-
...facetInfo,
|
|
30572
|
+
...this.facetInfo,
|
|
30544
30573
|
format: (value)=>this.formatFacetValue(value),
|
|
30545
30574
|
content: (value)=>this.ratingContent(value)
|
|
30546
30575
|
});
|
|
30547
30576
|
initializePopover(this, {
|
|
30548
|
-
...facetInfo,
|
|
30577
|
+
...this.facetInfo,
|
|
30549
30578
|
hasValues: ()=>!!this.valuesToRender.length,
|
|
30550
30579
|
numberOfActiveValues: ()=>this.numberOfSelectedValues
|
|
30551
30580
|
});
|
|
@@ -30672,6 +30701,7 @@ let AtomicRatingFacet$1 = class AtomicRatingFacet extends lit.LitElement {
|
|
|
30672
30701
|
}
|
|
30673
30702
|
constructor(){
|
|
30674
30703
|
super(), this.label = 'no-label', this.numberOfIntervals = 5, this.tabsIncluded = [], this.tabsExcluded = [], this.minValueInIndex = 1, this.displayValuesAs = 'checkbox', this.icon = star, this.isCollapsed = false, this.headingLevel = 0, this.injectionDepth = 1000;
|
|
30704
|
+
new FacetVisibilityController(this, ()=>!!this.facet && this.facetInfo.isHidden());
|
|
30675
30705
|
new ValidatePropsController(this, ()=>({
|
|
30676
30706
|
field: this.field,
|
|
30677
30707
|
numberOfIntervals: this.numberOfIntervals,
|
|
@@ -30885,6 +30915,14 @@ function _ts_metadata$A(metadataKey, metadataValue) {
|
|
|
30885
30915
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(metadataKey, metadataValue);
|
|
30886
30916
|
}
|
|
30887
30917
|
let AtomicRatingRangeFacet$1 = class AtomicRatingRangeFacet extends lit.LitElement {
|
|
30918
|
+
get facetInfo() {
|
|
30919
|
+
return {
|
|
30920
|
+
label: ()=>this.bindings.i18n.t(this.label),
|
|
30921
|
+
facetId: this.facetId,
|
|
30922
|
+
element: this,
|
|
30923
|
+
isHidden: ()=>this.isHidden
|
|
30924
|
+
};
|
|
30925
|
+
}
|
|
30888
30926
|
connectedCallback() {
|
|
30889
30927
|
super.connectedCallback();
|
|
30890
30928
|
if (void 0 === this.maxValueInIndex) this.maxValueInIndex = this.numberOfIntervals;
|
|
@@ -30933,19 +30971,13 @@ let AtomicRatingRangeFacet$1 = class AtomicRatingRangeFacet extends lit.LitEleme
|
|
|
30933
30971
|
options
|
|
30934
30972
|
});
|
|
30935
30973
|
this.facetId = this.facet.state.facetId;
|
|
30936
|
-
const facetInfo = {
|
|
30937
|
-
label: ()=>this.bindings.i18n.t(this.label),
|
|
30938
|
-
facetId: this.facetId,
|
|
30939
|
-
element: this,
|
|
30940
|
-
isHidden: ()=>this.isHidden
|
|
30941
|
-
};
|
|
30942
30974
|
this.bindings.store.registerFacet('numericFacets', {
|
|
30943
|
-
...facetInfo,
|
|
30975
|
+
...this.facetInfo,
|
|
30944
30976
|
format: (value)=>this.formatFacetValue(value),
|
|
30945
30977
|
content: (value)=>this.ratingContent(value)
|
|
30946
30978
|
});
|
|
30947
30979
|
initializePopover(this, {
|
|
30948
|
-
...facetInfo,
|
|
30980
|
+
...this.facetInfo,
|
|
30949
30981
|
hasValues: ()=>!!this.valuesToRender.length,
|
|
30950
30982
|
numberOfActiveValues: ()=>this.numberOfSelectedValues
|
|
30951
30983
|
});
|
|
@@ -31065,6 +31097,7 @@ let AtomicRatingRangeFacet$1 = class AtomicRatingRangeFacet extends lit.LitEleme
|
|
|
31065
31097
|
}
|
|
31066
31098
|
constructor(){
|
|
31067
31099
|
super(), this.label = 'no-label', this.tabsIncluded = [], this.tabsExcluded = [], this.numberOfIntervals = 5, this.minValueInIndex = 1, this.icon = star, this.isCollapsed = false, this.headingLevel = 0, this.injectionDepth = 1000;
|
|
31100
|
+
new FacetVisibilityController(this, ()=>!!this.facet && this.facetInfo.isHidden());
|
|
31068
31101
|
new ValidatePropsController(this, ()=>({
|
|
31069
31102
|
field: this.field,
|
|
31070
31103
|
numberOfIntervals: this.numberOfIntervals,
|
|
@@ -31329,8 +31362,10 @@ let AtomicRefineModal$1 = class AtomicRefineModal extends lit.LitElement {
|
|
|
31329
31362
|
const visibleFacetsClone = this.cloneFacets(visibleFacets);
|
|
31330
31363
|
const invisibleFacetsClone = this.cloneFacets(invisibleFacets);
|
|
31331
31364
|
collapseFacetsAfter(visibleFacetsClone, this.collapseFacetsAfter);
|
|
31332
|
-
|
|
31333
|
-
|
|
31365
|
+
const clonesByFacet = new Map();
|
|
31366
|
+
visibleFacets.forEach((facet, index)=>clonesByFacet.set(facet, visibleFacetsClone[index]));
|
|
31367
|
+
invisibleFacets.forEach((facet, index)=>clonesByFacet.set(facet, invisibleFacetsClone[index]));
|
|
31368
|
+
divSlot.append(...sortedFacets.map((facet)=>clonesByFacet.get(facet)));
|
|
31334
31369
|
const generator = this.makeAutomaticFacetGenerator();
|
|
31335
31370
|
if (generator) {
|
|
31336
31371
|
generator.updateCollapseFacetsDependingOnFacetsVisibility(this.collapseFacetsAfter, visibleFacets.length);
|
|
@@ -37742,6 +37777,10 @@ function _ts_metadata(metadataKey, metadataValue) {
|
|
|
37742
37777
|
if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(metadataKey, metadataValue);
|
|
37743
37778
|
}
|
|
37744
37779
|
let AtomicTimeframeFacet$1 = class AtomicTimeframeFacet extends lit.LitElement {
|
|
37780
|
+
get isHidden() {
|
|
37781
|
+
if (!this.timeframeFacetCommon || !this.searchStatusState) return false;
|
|
37782
|
+
return this.timeframeFacetCommon.isHostHidden(this.searchStatusState);
|
|
37783
|
+
}
|
|
37745
37784
|
get focusTarget() {
|
|
37746
37785
|
if (!this.headerFocus) this.headerFocus = new FocusTargetController(this, this.bindings);
|
|
37747
37786
|
return this.headerFocus;
|
|
@@ -37850,6 +37889,7 @@ let AtomicTimeframeFacet$1 = class AtomicTimeframeFacet extends lit.LitElement {
|
|
|
37850
37889
|
super(), this.label = 'no-label', this.field = 'date', this.tabsIncluded = [], this.tabsExcluded = [], this.withDatePicker = false, this.isCollapsed = false, this.headingLevel = 0, this.filterFacetCount = true, this.injectionDepth = 1000, this.sortCriteria = 'descending', this.handleDateInputApply = ()=>{
|
|
37851
37890
|
if (this.facetId) this.bindings.engine.dispatch(headless.loadDateFacetSetActions(this.bindings.engine).deselectAllDateFacetValues(this.facetId));
|
|
37852
37891
|
};
|
|
37892
|
+
new FacetVisibilityController(this, ()=>this.isHidden);
|
|
37853
37893
|
new ValidatePropsController(this, ()=>({
|
|
37854
37894
|
injectionDepth: this.injectionDepth,
|
|
37855
37895
|
headingLevel: this.headingLevel,
|