@internetarchive/collection-browser 2.14.2-alpha-webdev7679.0 → 2.14.2-alpha-webdev7679.2

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.
@@ -59,6 +59,13 @@ export declare class CollectionBrowser extends LitElement implements InfiniteScr
59
59
  minSelectedDate?: string;
60
60
  maxSelectedDate?: string;
61
61
  selectedFacets?: SelectedFacets;
62
+ /**
63
+ * Set of filters to be applied internally to searches, but not included in URL params or
64
+ * visibly selected facets. Use when this instance of collection browser is being shown
65
+ * in a filtered context, such as a single-mediatype tab, but the corresponding filters
66
+ * should not be exposed/changeable within that context.
67
+ */
68
+ internalFilters?: SelectedFacets;
62
69
  showSmartFacetBar: boolean;
63
70
  /**
64
71
  * Whether to show the date picker (above the facets)
@@ -94,6 +101,11 @@ export declare class CollectionBrowser extends LitElement implements InfiniteScr
94
101
  * If true, those options will be omitted (though the rest of the sort bar may still render).
95
102
  */
96
103
  suppressDisplayModes: boolean;
104
+ /**
105
+ * Whether to suppress the display of the `mediatype` facet group, e.g., because this instance
106
+ * of collection browser is being shown in a filtered single-mediatype context.
107
+ */
108
+ suppressMediatypeFacets: boolean;
97
109
  /**
98
110
  * What strategy to use for when/whether to load facet data for a search.
99
111
  *
@@ -73,6 +73,11 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
73
73
  * If true, those options will be omitted (though the rest of the sort bar may still render).
74
74
  */
75
75
  this.suppressDisplayModes = false;
76
+ /**
77
+ * Whether to suppress the display of the `mediatype` facet group, e.g., because this instance
78
+ * of collection browser is being shown in a filtered single-mediatype context.
79
+ */
80
+ this.suppressMediatypeFacets = false;
76
81
  /**
77
82
  * What strategy to use for when/whether to load facet data for a search.
78
83
  *
@@ -908,6 +913,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
908
913
  ?collapsableFacets=${this.mobileView}
909
914
  ?facetsLoading=${this.facetsLoading}
910
915
  ?fullYearAggregationLoading=${this.facetsLoading}
916
+ ?suppressMediatypeFacets=${this.suppressMediatypeFacets}
911
917
  @facetClick=${this.facetClickHandler}
912
918
  @facetsChanged=${this.facetsChanged}
913
919
  @histogramDateRangeUpdated=${this.histogramDateRangeUpdated}
@@ -1037,6 +1043,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
1037
1043
  this.searchType = queryState.searchType;
1038
1044
  this.selectedFacets =
1039
1045
  (_a = queryState.selectedFacets) !== null && _a !== void 0 ? _a : getDefaultSelectedFacets();
1046
+ this.internalFilters = queryState.internalFilters;
1040
1047
  this.minSelectedDate = queryState.minSelectedDate;
1041
1048
  this.maxSelectedDate = queryState.maxSelectedDate;
1042
1049
  this.selectedSort = (_b = queryState.selectedSort) !== null && _b !== void 0 ? _b : SortField.default;
@@ -1044,6 +1051,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
1044
1051
  this.selectedTitleFilter = queryState.selectedTitleFilter;
1045
1052
  this.selectedCreatorFilter = queryState.selectedCreatorFilter;
1046
1053
  this.tvClipFilter = (_c = queryState.tvClipFilter) !== null && _c !== void 0 ? _c : 'all';
1054
+ console.log('pages to render:', this.pagesToRender);
1047
1055
  // We set this flag during the update to prevent the URL state persistence
1048
1056
  // from creating an unwanted extra history entry.
1049
1057
  this.dataSourceInstallInProgress = true;
@@ -1352,6 +1360,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
1352
1360
  profileElement: this.profileElement,
1353
1361
  searchType: this.searchType,
1354
1362
  selectedFacets: this.selectedFacets,
1363
+ internalFilters: this.internalFilters,
1355
1364
  minSelectedDate: this.minSelectedDate,
1356
1365
  maxSelectedDate: this.maxSelectedDate,
1357
1366
  selectedSort: this.selectedSort,
@@ -2252,6 +2261,9 @@ __decorate([
2252
2261
  __decorate([
2253
2262
  property({ type: Object })
2254
2263
  ], CollectionBrowser.prototype, "selectedFacets", void 0);
2264
+ __decorate([
2265
+ property({ type: Object })
2266
+ ], CollectionBrowser.prototype, "internalFilters", void 0);
2255
2267
  __decorate([
2256
2268
  property({ type: Boolean })
2257
2269
  ], CollectionBrowser.prototype, "showSmartFacetBar", void 0);
@@ -2276,6 +2288,9 @@ __decorate([
2276
2288
  __decorate([
2277
2289
  property({ type: Boolean })
2278
2290
  ], CollectionBrowser.prototype, "suppressDisplayModes", void 0);
2291
+ __decorate([
2292
+ property({ type: Boolean })
2293
+ ], CollectionBrowser.prototype, "suppressMediatypeFacets", void 0);
2279
2294
  __decorate([
2280
2295
  property({ type: String })
2281
2296
  ], CollectionBrowser.prototype, "facetLoadStrategy", void 0);