@internetarchive/collection-browser 3.3.4-alpha-webdev7761.3 → 3.3.4-alpha-webdev7761.5
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/src/collection-browser.d.ts +4 -0
- package/dist/src/collection-browser.js +16 -8
- package/dist/src/collection-browser.js.map +1 -1
- package/dist/src/collection-facets.js +269 -266
- package/dist/src/collection-facets.js.map +1 -1
- package/package.json +1 -1
- package/src/collection-browser.ts +19 -8
- package/src/collection-facets.ts +1009 -1005
|
@@ -279,6 +279,10 @@ export declare class CollectionBrowser extends LitElement implements InfiniteScr
|
|
|
279
279
|
letterFilters?: boolean | undefined;
|
|
280
280
|
sort?: boolean | undefined;
|
|
281
281
|
}): void;
|
|
282
|
+
/**
|
|
283
|
+
* Resets any selected TV network/show dropdowns to their default state
|
|
284
|
+
*/
|
|
285
|
+
private clearTVDropdowns;
|
|
282
286
|
/**
|
|
283
287
|
* Returns true if the current value of `this.selectedFacets` contains
|
|
284
288
|
* any facet buckets than have been selected or negated, or false otherwise.
|
|
@@ -326,12 +326,24 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
326
326
|
this.sortDirection = null;
|
|
327
327
|
this.selectedSort = SortField.default;
|
|
328
328
|
}
|
|
329
|
-
this.
|
|
330
|
-
this.selectedTVShow = undefined;
|
|
329
|
+
this.clearTVDropdowns();
|
|
331
330
|
if (this.smartFacetBar) {
|
|
332
331
|
this.smartFacetBar.deselectAll();
|
|
333
332
|
}
|
|
334
333
|
}
|
|
334
|
+
/**
|
|
335
|
+
* Resets any selected TV network/show dropdowns to their default state
|
|
336
|
+
*/
|
|
337
|
+
clearTVDropdowns() {
|
|
338
|
+
this.selectedTVNetwork = undefined;
|
|
339
|
+
this.selectedTVShow = undefined;
|
|
340
|
+
if (this.tvNetworksDropdown) {
|
|
341
|
+
this.tvNetworksDropdown.selectedIndex = 0;
|
|
342
|
+
}
|
|
343
|
+
if (this.tvShowsDropdown) {
|
|
344
|
+
this.tvShowsDropdown.selectedIndex = 0;
|
|
345
|
+
}
|
|
346
|
+
}
|
|
335
347
|
/**
|
|
336
348
|
* Returns true if the current value of `this.selectedFacets` contains
|
|
337
349
|
* any facet buckets than have been selected or negated, or false otherwise.
|
|
@@ -1059,9 +1071,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1059
1071
|
</option>
|
|
1060
1072
|
`;
|
|
1061
1073
|
const makeShowOption = (show) => html `
|
|
1062
|
-
<option ?selected=${this.selectedTVShow === show}>
|
|
1063
|
-
${show}
|
|
1064
|
-
</option>
|
|
1074
|
+
<option ?selected=${this.selectedTVShow === show}>${show}</option>
|
|
1065
1075
|
`;
|
|
1066
1076
|
const loadingIndicator = html `
|
|
1067
1077
|
<img src="https://archive.org/images/loading.gif" />
|
|
@@ -1093,9 +1103,7 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1093
1103
|
<option value="" ?selected=${!this.selectedTVShow}>
|
|
1094
1104
|
${msg('Filter by Show')}
|
|
1095
1105
|
</option>
|
|
1096
|
-
${this.shouldPopulateShows
|
|
1097
|
-
? map(shows, makeShowOption)
|
|
1098
|
-
: nothing}
|
|
1106
|
+
${this.shouldPopulateShows ? map(shows, makeShowOption) : nothing}
|
|
1099
1107
|
</select>
|
|
1100
1108
|
${loadingIndicator}
|
|
1101
1109
|
</div>
|