@internetarchive/collection-browser 4.4.1 → 4.5.0
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/.editorconfig +29 -29
- package/.github/workflows/ci.yml +27 -27
- package/.github/workflows/gh-pages-main.yml +39 -39
- package/.github/workflows/npm-publish.yml +39 -39
- package/.github/workflows/pr-preview.yml +38 -38
- package/.husky/pre-commit +1 -1
- package/.prettierignore +1 -1
- package/LICENSE +661 -661
- package/README.md +83 -83
- package/dist/index.d.ts +1 -0
- package/dist/index.js.map +1 -1
- package/dist/src/app-root.d.ts +8 -0
- package/dist/src/app-root.js +698 -672
- package/dist/src/app-root.js.map +1 -1
- package/dist/src/collection-browser.d.ts +8 -0
- package/dist/src/collection-browser.js +782 -764
- package/dist/src/collection-browser.js.map +1 -1
- package/dist/src/collection-facets/facet-row.d.ts +6 -0
- package/dist/src/collection-facets/facet-row.js +158 -140
- package/dist/src/collection-facets/facet-row.js.map +1 -1
- package/dist/src/collection-facets/facets-template.js +25 -23
- package/dist/src/collection-facets/facets-template.js.map +1 -1
- package/dist/src/styles/tile-action-styles.d.ts +14 -0
- package/dist/src/styles/tile-action-styles.js +59 -0
- package/dist/src/styles/tile-action-styles.js.map +1 -0
- package/dist/src/tiles/base-tile-component.d.ts +17 -1
- package/dist/src/tiles/base-tile-component.js +50 -1
- package/dist/src/tiles/base-tile-component.js.map +1 -1
- package/dist/src/tiles/grid/item-tile.js +139 -138
- package/dist/src/tiles/grid/item-tile.js.map +1 -1
- package/dist/src/tiles/list/tile-list-compact-header.js +71 -46
- package/dist/src/tiles/list/tile-list-compact-header.js.map +1 -1
- package/dist/src/tiles/list/tile-list-compact.d.ts +1 -1
- package/dist/src/tiles/list/tile-list-compact.js +138 -100
- package/dist/src/tiles/list/tile-list-compact.js.map +1 -1
- package/dist/src/tiles/list/tile-list.d.ts +1 -1
- package/dist/src/tiles/list/tile-list.js +316 -298
- package/dist/src/tiles/list/tile-list.js.map +1 -1
- package/dist/src/tiles/models.d.ts +11 -0
- package/dist/src/tiles/models.js.map +1 -1
- package/dist/src/tiles/tile-dispatcher.d.ts +14 -0
- package/dist/src/tiles/tile-dispatcher.js +319 -216
- package/dist/src/tiles/tile-dispatcher.js.map +1 -1
- package/dist/src/tiles/tile-display-value-provider.js.map +1 -1
- package/dist/test/collection-facets/facet-row.test.js +55 -23
- package/dist/test/collection-facets/facet-row.test.js.map +1 -1
- package/dist/test/tiles/grid/item-tile.test.js +77 -77
- package/dist/test/tiles/grid/item-tile.test.js.map +1 -1
- package/dist/test/tiles/list/tile-list.test.js +134 -134
- package/dist/test/tiles/list/tile-list.test.js.map +1 -1
- package/dist/test/tiles/tile-dispatcher.test.js +92 -92
- package/dist/test/tiles/tile-dispatcher.test.js.map +1 -1
- package/eslint.config.mjs +53 -53
- package/index.html +24 -24
- package/index.ts +29 -28
- package/local.archive.org.cert +86 -86
- package/local.archive.org.key +27 -27
- package/package.json +120 -120
- package/renovate.json +6 -6
- package/src/app-root.ts +1284 -1254
- package/src/collection-browser.ts +3176 -3161
- package/src/collection-facets/facet-row.ts +309 -299
- package/src/collection-facets/facets-template.ts +85 -83
- package/src/styles/tile-action-styles.ts +59 -0
- package/src/tiles/base-tile-component.ts +124 -65
- package/src/tiles/grid/item-tile.ts +347 -346
- package/src/tiles/list/tile-list-compact-header.ts +112 -86
- package/src/tiles/list/tile-list-compact.ts +278 -239
- package/src/tiles/list/tile-list.ts +718 -700
- package/src/tiles/models.ts +21 -8
- package/src/tiles/tile-dispatcher.ts +637 -527
- package/src/tiles/tile-display-value-provider.ts +133 -133
- package/test/collection-facets/facet-row.test.ts +421 -375
- package/test/tiles/grid/item-tile.test.ts +520 -520
- package/test/tiles/list/tile-list.test.ts +576 -576
- package/test/tiles/tile-dispatcher.test.ts +320 -320
- package/tsconfig.json +25 -25
- package/web-dev-server.config.mjs +30 -30
- package/web-test-runner.config.mjs +52 -52
|
@@ -124,6 +124,13 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
124
124
|
* If item management UI active
|
|
125
125
|
*/
|
|
126
126
|
this.isManageView = false;
|
|
127
|
+
/** Action buttons to display on each tile */
|
|
128
|
+
this.tileActions = [];
|
|
129
|
+
/**
|
|
130
|
+
* The simplified layout to apply to grid-mode tiles, if any. See
|
|
131
|
+
* `LayoutType` for available options. Has no effect on list display modes.
|
|
132
|
+
*/
|
|
133
|
+
this.tileLayoutType = 'default';
|
|
127
134
|
this.manageViewLabel = 'Select items to remove';
|
|
128
135
|
/** Whether to replace the default sort options with a slot for customization (default: false) */
|
|
129
136
|
this.enableSortOptionsSlot = false;
|
|
@@ -451,32 +458,32 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
451
458
|
}
|
|
452
459
|
}
|
|
453
460
|
render() {
|
|
454
|
-
return html `
|
|
461
|
+
return html `
|
|
455
462
|
${this.showSmartFacetBar && this.placeholderType === null
|
|
456
|
-
? html `<smart-facet-bar
|
|
457
|
-
.query=${this.baseQuery}
|
|
458
|
-
.aggregations=${this.dataSource.aggregations}
|
|
459
|
-
.selectedFacets=${this.selectedFacets}
|
|
460
|
-
.collectionTitles=${this.dataSource.collectionTitles}
|
|
461
|
-
.filterToggleShown=${!this.mobileView}
|
|
462
|
-
.filterToggleActive=${this.facetPaneVisible}
|
|
463
|
-
.label=${this.smartFacetBarLabel}
|
|
464
|
-
@facetsChanged=${this.facetsChanged}
|
|
463
|
+
? html `<smart-facet-bar
|
|
464
|
+
.query=${this.baseQuery}
|
|
465
|
+
.aggregations=${this.dataSource.aggregations}
|
|
466
|
+
.selectedFacets=${this.selectedFacets}
|
|
467
|
+
.collectionTitles=${this.dataSource.collectionTitles}
|
|
468
|
+
.filterToggleShown=${!this.mobileView}
|
|
469
|
+
.filterToggleActive=${this.facetPaneVisible}
|
|
470
|
+
.label=${this.smartFacetBarLabel}
|
|
471
|
+
@facetsChanged=${this.facetsChanged}
|
|
465
472
|
@filtersToggled=${() => {
|
|
466
473
|
this.facetPaneVisible = !this.facetPaneVisible;
|
|
467
474
|
this.emitFacetPaneVisibilityChanged();
|
|
468
|
-
}}
|
|
475
|
+
}}
|
|
469
476
|
></smart-facet-bar>`
|
|
470
|
-
: nothing}
|
|
471
|
-
|
|
472
|
-
<div
|
|
473
|
-
id="content-container"
|
|
474
|
-
class=${this.mobileView ? 'mobile' : 'desktop'}
|
|
475
|
-
>
|
|
477
|
+
: nothing}
|
|
478
|
+
|
|
479
|
+
<div
|
|
480
|
+
id="content-container"
|
|
481
|
+
class=${this.mobileView ? 'mobile' : 'desktop'}
|
|
482
|
+
>
|
|
476
483
|
${this.placeholderType
|
|
477
484
|
? this.emptyPlaceholderTemplate
|
|
478
|
-
: this.collectionBrowserTemplate}
|
|
479
|
-
</div>
|
|
485
|
+
: this.collectionBrowserTemplate}
|
|
486
|
+
</div>
|
|
480
487
|
`;
|
|
481
488
|
}
|
|
482
489
|
/**
|
|
@@ -520,23 +527,23 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
520
527
|
* Template for the placeholder content to show when no results are available.
|
|
521
528
|
*/
|
|
522
529
|
get emptyPlaceholderTemplate() {
|
|
523
|
-
return html `
|
|
524
|
-
<empty-placeholder
|
|
525
|
-
.placeholderType=${this.placeholderType}
|
|
526
|
-
?isMobileView=${this.mobileView}
|
|
527
|
-
?isCollection=${!!this.withinCollection}
|
|
528
|
-
.detailMessage=${this.dataSource.queryErrorMessage ?? ''}
|
|
529
|
-
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
530
|
-
></empty-placeholder>
|
|
530
|
+
return html `
|
|
531
|
+
<empty-placeholder
|
|
532
|
+
.placeholderType=${this.placeholderType}
|
|
533
|
+
?isMobileView=${this.mobileView}
|
|
534
|
+
?isCollection=${!!this.withinCollection}
|
|
535
|
+
.detailMessage=${this.dataSource.queryErrorMessage ?? ''}
|
|
536
|
+
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
537
|
+
></empty-placeholder>
|
|
531
538
|
`;
|
|
532
539
|
}
|
|
533
540
|
/**
|
|
534
541
|
* Top-level template for rendering the left (facets) and right (results) columns.
|
|
535
542
|
*/
|
|
536
543
|
get collectionBrowserTemplate() {
|
|
537
|
-
return html `
|
|
538
|
-
<div id="left-column-scroll-sentinel"></div>
|
|
539
|
-
${this.leftColumnTemplate} ${this.rightColumnTemplate}
|
|
544
|
+
return html `
|
|
545
|
+
<div id="left-column-scroll-sentinel"></div>
|
|
546
|
+
${this.leftColumnTemplate} ${this.rightColumnTemplate}
|
|
540
547
|
`;
|
|
541
548
|
}
|
|
542
549
|
/**
|
|
@@ -555,33 +562,33 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
555
562
|
* accordion-style facets.
|
|
556
563
|
*/
|
|
557
564
|
get mobileLeftColumnTemplate() {
|
|
558
|
-
return html `
|
|
559
|
-
<div
|
|
560
|
-
id="left-column"
|
|
561
|
-
class="column${this.isResizeToMobile ? ' preload' : ''}"
|
|
562
|
-
>
|
|
563
|
-
${this.facetTopViewSlot} ${this.resultsCountTemplate}
|
|
564
|
-
<div id="facets-header-container">${this.mobileFacetsTemplate}</div>
|
|
565
|
-
</div>
|
|
565
|
+
return html `
|
|
566
|
+
<div
|
|
567
|
+
id="left-column"
|
|
568
|
+
class="column${this.isResizeToMobile ? ' preload' : ''}"
|
|
569
|
+
>
|
|
570
|
+
${this.facetTopViewSlot} ${this.resultsCountTemplate}
|
|
571
|
+
<div id="facets-header-container">${this.mobileFacetsTemplate}</div>
|
|
572
|
+
</div>
|
|
566
573
|
`;
|
|
567
574
|
}
|
|
568
575
|
/**
|
|
569
576
|
* Template for the desktop version of the left column, displaying the facets sidebar.
|
|
570
577
|
*/
|
|
571
578
|
get desktopLeftColumnTemplate() {
|
|
572
|
-
return html `
|
|
573
|
-
<div id="left-column" class="column" ?hidden=${!this.facetPaneVisible}>
|
|
574
|
-
${this.facetTopViewSlot}
|
|
575
|
-
<div id="facets-header-container">
|
|
576
|
-
<h2 id="facets-header" class="sr-only">${msg('Filters')}</h2>
|
|
577
|
-
${this.resultsCountTemplate} ${this.clearFiltersBtnTemplate(false)}
|
|
578
|
-
</div>
|
|
579
|
-
<div id="facets-container" aria-labelledby="facets-header">
|
|
580
|
-
${this.facetsTemplate}
|
|
581
|
-
<div id="facets-scroll-sentinel"></div>
|
|
582
|
-
</div>
|
|
583
|
-
<div id="facets-bottom-fade"></div>
|
|
584
|
-
</div>
|
|
579
|
+
return html `
|
|
580
|
+
<div id="left-column" class="column" ?hidden=${!this.facetPaneVisible}>
|
|
581
|
+
${this.facetTopViewSlot}
|
|
582
|
+
<div id="facets-header-container">
|
|
583
|
+
<h2 id="facets-header" class="sr-only">${msg('Filters')}</h2>
|
|
584
|
+
${this.resultsCountTemplate} ${this.clearFiltersBtnTemplate(false)}
|
|
585
|
+
</div>
|
|
586
|
+
<div id="facets-container" aria-labelledby="facets-header">
|
|
587
|
+
${this.facetsTemplate}
|
|
588
|
+
<div id="facets-scroll-sentinel"></div>
|
|
589
|
+
</div>
|
|
590
|
+
<div id="facets-bottom-fade"></div>
|
|
591
|
+
</div>
|
|
585
592
|
`;
|
|
586
593
|
}
|
|
587
594
|
/**
|
|
@@ -589,8 +596,8 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
589
596
|
* - mainly used to render userlists
|
|
590
597
|
*/
|
|
591
598
|
get facetTopViewSlot() {
|
|
592
|
-
return html `<div id="facet-top-view">
|
|
593
|
-
<slot name="facet-top-slot"></slot>
|
|
599
|
+
return html `<div id="facet-top-view">
|
|
600
|
+
<slot name="facet-top-slot"></slot>
|
|
594
601
|
</div>`;
|
|
595
602
|
}
|
|
596
603
|
/**
|
|
@@ -605,15 +612,15 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
605
612
|
const resultsCount = this.totalResults?.toLocaleString();
|
|
606
613
|
const resultsLabel = this.totalResults === 1 ? 'Result' : 'Results';
|
|
607
614
|
// Added data-testid for Playwright testing
|
|
608
|
-
return html `
|
|
609
|
-
<div id="results-total" class=${classes} data-testid="results-total">
|
|
610
|
-
<span id="big-results-count">
|
|
611
|
-
${shouldShowSearching ? html `Searching…` : resultsCount}
|
|
612
|
-
</span>
|
|
613
|
-
<span id="big-results-label">
|
|
614
|
-
${shouldShowSearching ? nothing : resultsLabel}
|
|
615
|
-
</span>
|
|
616
|
-
</div>
|
|
615
|
+
return html `
|
|
616
|
+
<div id="results-total" class=${classes} data-testid="results-total">
|
|
617
|
+
<span id="big-results-count">
|
|
618
|
+
${shouldShowSearching ? html `Searching…` : resultsCount}
|
|
619
|
+
</span>
|
|
620
|
+
<span id="big-results-label">
|
|
621
|
+
${shouldShowSearching ? nothing : resultsLabel}
|
|
622
|
+
</span>
|
|
623
|
+
</div>
|
|
617
624
|
`;
|
|
618
625
|
}
|
|
619
626
|
/**
|
|
@@ -626,47 +633,47 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
626
633
|
'full-width': !this.facetPaneVisible,
|
|
627
634
|
'smart-results-spacing': !!this.showSmartResults,
|
|
628
635
|
});
|
|
629
|
-
return html `
|
|
630
|
-
<div id="right-column" class=${rightColumnClasses}>
|
|
636
|
+
return html `
|
|
637
|
+
<div id="right-column" class=${rightColumnClasses}>
|
|
631
638
|
${this.showSmartResults
|
|
632
639
|
? html `<slot name="smart-results"></slot>`
|
|
633
|
-
: nothing}
|
|
634
|
-
<section id="results">
|
|
635
|
-
<h2 class="results-section-heading">
|
|
636
|
-
<slot name="results-heading"></slot>
|
|
637
|
-
</h2>
|
|
638
|
-
<div id="cb-top-view">
|
|
639
|
-
<slot name="cb-top-slot"></slot>
|
|
640
|
-
</div>
|
|
640
|
+
: nothing}
|
|
641
|
+
<section id="results">
|
|
642
|
+
<h2 class="results-section-heading">
|
|
643
|
+
<slot name="results-heading"></slot>
|
|
644
|
+
</h2>
|
|
645
|
+
<div id="cb-top-view">
|
|
646
|
+
<slot name="cb-top-slot"></slot>
|
|
647
|
+
</div>
|
|
641
648
|
${this.isManageView
|
|
642
649
|
? this.manageBarTemplate
|
|
643
|
-
: this.sortFilterBarTemplate}
|
|
644
|
-
<slot name="cb-results"></slot>
|
|
650
|
+
: this.sortFilterBarTemplate}
|
|
651
|
+
<slot name="cb-results"></slot>
|
|
645
652
|
${this.displayMode === `list-compact` && this.totalResults
|
|
646
653
|
? this.listHeaderTemplate
|
|
647
|
-
: nothing}
|
|
648
|
-
${this.suppressResultTiles ? nothing : this.infiniteScrollerTemplate}
|
|
649
|
-
</section>
|
|
650
|
-
</div>
|
|
654
|
+
: nothing}
|
|
655
|
+
${this.suppressResultTiles ? nothing : this.infiniteScrollerTemplate}
|
|
656
|
+
</section>
|
|
657
|
+
</div>
|
|
651
658
|
`;
|
|
652
659
|
}
|
|
653
660
|
/**
|
|
654
661
|
* Template for the infinite scroller widget that contains the result tiles.
|
|
655
662
|
*/
|
|
656
663
|
get infiniteScrollerTemplate() {
|
|
657
|
-
return html `<infinite-scroller
|
|
658
|
-
class=${this.infiniteScrollerClasses}
|
|
659
|
-
itemCount=${this.placeholderType ? 0 : nothing}
|
|
660
|
-
ariaLandmarkLabel="Search results"
|
|
661
|
-
.estimatedCellHeight=${this.estimatedTileHeight}
|
|
662
|
-
.minBufferMarginCells=${this.pageSize}
|
|
663
|
-
.cellProvider=${this}
|
|
664
|
-
.placeholderCellTemplate=${this.placeholderCellTemplate}
|
|
665
|
-
@scrollThresholdReached=${this.scrollThresholdReached}
|
|
666
|
-
@visibleCellsChanged=${this.visibleCellsChanged}
|
|
664
|
+
return html `<infinite-scroller
|
|
665
|
+
class=${this.infiniteScrollerClasses}
|
|
666
|
+
itemCount=${this.placeholderType ? 0 : nothing}
|
|
667
|
+
ariaLandmarkLabel="Search results"
|
|
668
|
+
.estimatedCellHeight=${this.estimatedTileHeight}
|
|
669
|
+
.minBufferMarginCells=${this.pageSize}
|
|
670
|
+
.cellProvider=${this}
|
|
671
|
+
.placeholderCellTemplate=${this.placeholderCellTemplate}
|
|
672
|
+
@scrollThresholdReached=${this.scrollThresholdReached}
|
|
673
|
+
@visibleCellsChanged=${this.visibleCellsChanged}
|
|
667
674
|
>${this.displayMode === 'grid'
|
|
668
675
|
? html `<slot name="result-last-tile" slot="result-last-tile"></slot>`
|
|
669
|
-
: nothing}
|
|
676
|
+
: nothing}
|
|
670
677
|
</infinite-scroller>`;
|
|
671
678
|
}
|
|
672
679
|
/**
|
|
@@ -718,29 +725,29 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
718
725
|
}
|
|
719
726
|
// We only show relevance sort if a search query is currently defined
|
|
720
727
|
sortFieldAvailability.relevance = this.isRelevanceSortAvailable;
|
|
721
|
-
return html `
|
|
722
|
-
<sort-filter-bar
|
|
723
|
-
.defaultSortField=${this.defaultSortField}
|
|
724
|
-
.defaultSortDirection=${this.defaultSortDirection}
|
|
725
|
-
.selectedSort=${this.selectedSort}
|
|
726
|
-
.sortDirection=${this.sortDirection}
|
|
727
|
-
.sortFieldAvailability=${sortFieldAvailability}
|
|
728
|
-
.displayMode=${this.displayMode}
|
|
729
|
-
.selectedTitleFilter=${this.selectedTitleFilter}
|
|
730
|
-
.selectedCreatorFilter=${this.selectedCreatorFilter}
|
|
731
|
-
.prefixFilterCountMap=${this.dataSource.prefixFilterCountMap}
|
|
732
|
-
.enableSortOptionsSlot=${this.enableSortOptionsSlot}
|
|
733
|
-
.suppressDisplayModes=${this.suppressDisplayModes}
|
|
734
|
-
@sortChanged=${this.userChangedSort}
|
|
735
|
-
@displayModeChanged=${this.displayModeChanged}
|
|
736
|
-
@titleLetterChanged=${this.titleLetterSelected}
|
|
737
|
-
@creatorLetterChanged=${this.creatorLetterSelected}
|
|
738
|
-
>
|
|
739
|
-
${this.tileBlurCheckboxTemplate}
|
|
740
|
-
<slot name="sort-options-left" slot="sort-options-left"></slot>
|
|
741
|
-
<slot name="sort-options" slot="sort-options"></slot>
|
|
742
|
-
<slot name="sort-options-right" slot="sort-options-right"></slot>
|
|
743
|
-
</sort-filter-bar>
|
|
728
|
+
return html `
|
|
729
|
+
<sort-filter-bar
|
|
730
|
+
.defaultSortField=${this.defaultSortField}
|
|
731
|
+
.defaultSortDirection=${this.defaultSortDirection}
|
|
732
|
+
.selectedSort=${this.selectedSort}
|
|
733
|
+
.sortDirection=${this.sortDirection}
|
|
734
|
+
.sortFieldAvailability=${sortFieldAvailability}
|
|
735
|
+
.displayMode=${this.displayMode}
|
|
736
|
+
.selectedTitleFilter=${this.selectedTitleFilter}
|
|
737
|
+
.selectedCreatorFilter=${this.selectedCreatorFilter}
|
|
738
|
+
.prefixFilterCountMap=${this.dataSource.prefixFilterCountMap}
|
|
739
|
+
.enableSortOptionsSlot=${this.enableSortOptionsSlot}
|
|
740
|
+
.suppressDisplayModes=${this.suppressDisplayModes}
|
|
741
|
+
@sortChanged=${this.userChangedSort}
|
|
742
|
+
@displayModeChanged=${this.displayModeChanged}
|
|
743
|
+
@titleLetterChanged=${this.titleLetterSelected}
|
|
744
|
+
@creatorLetterChanged=${this.creatorLetterSelected}
|
|
745
|
+
>
|
|
746
|
+
${this.tileBlurCheckboxTemplate}
|
|
747
|
+
<slot name="sort-options-left" slot="sort-options-left"></slot>
|
|
748
|
+
<slot name="sort-options" slot="sort-options"></slot>
|
|
749
|
+
<slot name="sort-options-right" slot="sort-options-right"></slot>
|
|
750
|
+
</sort-filter-bar>
|
|
744
751
|
`;
|
|
745
752
|
}
|
|
746
753
|
/**
|
|
@@ -751,20 +758,20 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
751
758
|
// Only show the checkbox for @archive.org users
|
|
752
759
|
if (!this.dataSource.sessionContext?.is_archive_user)
|
|
753
760
|
return nothing;
|
|
754
|
-
return html `
|
|
755
|
-
<label
|
|
756
|
-
id="tile-blur-label"
|
|
757
|
-
for="tile-blur-check"
|
|
758
|
-
slot="sort-options-right"
|
|
759
|
-
>
|
|
760
|
-
${msg('Blurring')}
|
|
761
|
-
<input
|
|
762
|
-
id="tile-blur-check"
|
|
763
|
-
type="checkbox"
|
|
764
|
-
?checked=${!this.shouldSuppressTileBlurring}
|
|
765
|
-
@change=${this.tileBlurCheckboxChanged}
|
|
766
|
-
/>
|
|
767
|
-
</label>
|
|
761
|
+
return html `
|
|
762
|
+
<label
|
|
763
|
+
id="tile-blur-label"
|
|
764
|
+
for="tile-blur-check"
|
|
765
|
+
slot="sort-options-right"
|
|
766
|
+
>
|
|
767
|
+
${msg('Blurring')}
|
|
768
|
+
<input
|
|
769
|
+
id="tile-blur-check"
|
|
770
|
+
type="checkbox"
|
|
771
|
+
?checked=${!this.shouldSuppressTileBlurring}
|
|
772
|
+
@change=${this.tileBlurCheckboxChanged}
|
|
773
|
+
/>
|
|
774
|
+
</label>
|
|
768
775
|
`;
|
|
769
776
|
}
|
|
770
777
|
/**
|
|
@@ -772,27 +779,27 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
772
779
|
* showing the management view. This generally replaces the sort bar when present.
|
|
773
780
|
*/
|
|
774
781
|
get manageBarTemplate() {
|
|
775
|
-
return html `
|
|
776
|
-
<manage-bar
|
|
777
|
-
.label=${this.manageViewLabel}
|
|
778
|
-
.modalManager=${this.modalManager}
|
|
779
|
-
.selectedItems=${this.dataSource.checkedTileModels}
|
|
780
|
-
.profileElement=${this.profileElement}
|
|
781
|
-
showSelectAll
|
|
782
|
-
showUnselectAll
|
|
783
|
-
?showItemManageButton=${this.pageContext === 'search'}
|
|
784
|
-
?removeAllowed=${this.dataSource.checkedTileModels.length !== 0}
|
|
785
|
-
@removeItems=${this.handleRemoveItems}
|
|
786
|
-
@manageItems=${this.handleManageItems}
|
|
787
|
-
@selectAll=${() => this.dataSource.checkAllTiles()}
|
|
788
|
-
@unselectAll=${() => this.dataSource.uncheckAllTiles()}
|
|
782
|
+
return html `
|
|
783
|
+
<manage-bar
|
|
784
|
+
.label=${this.manageViewLabel}
|
|
785
|
+
.modalManager=${this.modalManager}
|
|
786
|
+
.selectedItems=${this.dataSource.checkedTileModels}
|
|
787
|
+
.profileElement=${this.profileElement}
|
|
788
|
+
showSelectAll
|
|
789
|
+
showUnselectAll
|
|
790
|
+
?showItemManageButton=${this.pageContext === 'search'}
|
|
791
|
+
?removeAllowed=${this.dataSource.checkedTileModels.length !== 0}
|
|
792
|
+
@removeItems=${this.handleRemoveItems}
|
|
793
|
+
@manageItems=${this.handleManageItems}
|
|
794
|
+
@selectAll=${() => this.dataSource.checkAllTiles()}
|
|
795
|
+
@unselectAll=${() => this.dataSource.uncheckAllTiles()}
|
|
789
796
|
@cancel=${() => {
|
|
790
797
|
this.isManageView = false;
|
|
791
798
|
this.dataSource.uncheckAllTiles();
|
|
792
799
|
if (this.searchResultsLoading)
|
|
793
800
|
this.dataSource.resetPages();
|
|
794
|
-
}}
|
|
795
|
-
></manage-bar>
|
|
801
|
+
}}
|
|
802
|
+
></manage-bar>
|
|
796
803
|
`;
|
|
797
804
|
}
|
|
798
805
|
/**
|
|
@@ -1027,15 +1034,15 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1027
1034
|
label: target.open ? 'open' : 'closed',
|
|
1028
1035
|
});
|
|
1029
1036
|
};
|
|
1030
|
-
return html `
|
|
1031
|
-
<details id="mobile-filter-collapse" @toggle=${toggleFacetsVisible}>
|
|
1032
|
-
<summary>
|
|
1033
|
-
<span class="collapser-icon">${chevronIcon}</span>
|
|
1034
|
-
<h2>${msg('Filters')}</h2>
|
|
1035
|
-
${this.clearFiltersBtnTemplate(true)}
|
|
1036
|
-
</summary>
|
|
1037
|
-
${this.facetsTemplate}
|
|
1038
|
-
</details>
|
|
1037
|
+
return html `
|
|
1038
|
+
<details id="mobile-filter-collapse" @toggle=${toggleFacetsVisible}>
|
|
1039
|
+
<summary>
|
|
1040
|
+
<span class="collapser-icon">${chevronIcon}</span>
|
|
1041
|
+
<h2>${msg('Filters')}</h2>
|
|
1042
|
+
${this.clearFiltersBtnTemplate(true)}
|
|
1043
|
+
</summary>
|
|
1044
|
+
${this.facetsTemplate}
|
|
1045
|
+
</details>
|
|
1039
1046
|
`;
|
|
1040
1047
|
}
|
|
1041
1048
|
/**
|
|
@@ -1119,50 +1126,50 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1119
1126
|
const filterByNetworkLabel = msg('Filter by Network');
|
|
1120
1127
|
const filterByShowLabel = msg('Filter by Show');
|
|
1121
1128
|
const shows = showEntries.map(([show]) => show);
|
|
1122
|
-
const loadingIndicator = html `
|
|
1123
|
-
<span slot="empty-options">
|
|
1124
|
-
<img src="https://archive.org/images/loading.gif" />
|
|
1125
|
-
</span>
|
|
1129
|
+
const loadingIndicator = html `
|
|
1130
|
+
<span slot="empty-options">
|
|
1131
|
+
<img src="https://archive.org/images/loading.gif" />
|
|
1132
|
+
</span>
|
|
1126
1133
|
`;
|
|
1127
|
-
const errorMessage = html `
|
|
1128
|
-
<span slot="empty-options">
|
|
1129
|
-
${msg('Unable to fetch options, try again later')}
|
|
1130
|
-
</span>
|
|
1134
|
+
const errorMessage = html `
|
|
1135
|
+
<span slot="empty-options">
|
|
1136
|
+
${msg('Unable to fetch options, try again later')}
|
|
1137
|
+
</span>
|
|
1131
1138
|
`;
|
|
1132
|
-
return html `
|
|
1133
|
-
<div id="tv-filters" slot="facets-top">
|
|
1134
|
-
<ia-combo-box
|
|
1135
|
-
id="tv-networks"
|
|
1136
|
-
class="tv-filter-dropdown"
|
|
1137
|
-
placeholder=${filterByNetworkLabel}
|
|
1138
|
-
clearable
|
|
1139
|
-
wrap-arrow-keys
|
|
1140
|
-
sort
|
|
1141
|
-
.options=${networks.map((n, i) => ({ id: `network-${i}`, text: n }))}
|
|
1142
|
-
@toggle=${this.tvDropdownToggled}
|
|
1143
|
-
@change=${this.networksDropdownChanged}
|
|
1144
|
-
>
|
|
1145
|
-
<span slot="label" class="sr-only">${filterByNetworkLabel}</span>
|
|
1146
|
-
${this.tvMapsLoading ? loadingIndicator : nothing}
|
|
1147
|
-
${this.tvMapsErrored ? errorMessage : nothing}
|
|
1148
|
-
</ia-combo-box>
|
|
1149
|
-
<ia-combo-box
|
|
1150
|
-
id="tv-shows"
|
|
1151
|
-
class="tv-filter-dropdown"
|
|
1152
|
-
placeholder=${filterByShowLabel}
|
|
1153
|
-
max-autocomplete-entries="500"
|
|
1154
|
-
clearable
|
|
1155
|
-
wrap-arrow-keys
|
|
1156
|
-
sort
|
|
1157
|
-
.options=${shows.map((s, i) => ({ id: `show-${i}`, text: s }))}
|
|
1158
|
-
@toggle=${this.tvDropdownToggled}
|
|
1159
|
-
@change=${this.showsDropdownChanged}
|
|
1160
|
-
>
|
|
1161
|
-
<span slot="label" class="sr-only">${filterByShowLabel}</span>
|
|
1162
|
-
${this.tvMapsLoading ? loadingIndicator : nothing}
|
|
1163
|
-
${this.tvMapsErrored ? errorMessage : nothing}
|
|
1164
|
-
</ia-combo-box>
|
|
1165
|
-
</div>
|
|
1139
|
+
return html `
|
|
1140
|
+
<div id="tv-filters" slot="facets-top">
|
|
1141
|
+
<ia-combo-box
|
|
1142
|
+
id="tv-networks"
|
|
1143
|
+
class="tv-filter-dropdown"
|
|
1144
|
+
placeholder=${filterByNetworkLabel}
|
|
1145
|
+
clearable
|
|
1146
|
+
wrap-arrow-keys
|
|
1147
|
+
sort
|
|
1148
|
+
.options=${networks.map((n, i) => ({ id: `network-${i}`, text: n }))}
|
|
1149
|
+
@toggle=${this.tvDropdownToggled}
|
|
1150
|
+
@change=${this.networksDropdownChanged}
|
|
1151
|
+
>
|
|
1152
|
+
<span slot="label" class="sr-only">${filterByNetworkLabel}</span>
|
|
1153
|
+
${this.tvMapsLoading ? loadingIndicator : nothing}
|
|
1154
|
+
${this.tvMapsErrored ? errorMessage : nothing}
|
|
1155
|
+
</ia-combo-box>
|
|
1156
|
+
<ia-combo-box
|
|
1157
|
+
id="tv-shows"
|
|
1158
|
+
class="tv-filter-dropdown"
|
|
1159
|
+
placeholder=${filterByShowLabel}
|
|
1160
|
+
max-autocomplete-entries="500"
|
|
1161
|
+
clearable
|
|
1162
|
+
wrap-arrow-keys
|
|
1163
|
+
sort
|
|
1164
|
+
.options=${shows.map((s, i) => ({ id: `show-${i}`, text: s }))}
|
|
1165
|
+
@toggle=${this.tvDropdownToggled}
|
|
1166
|
+
@change=${this.showsDropdownChanged}
|
|
1167
|
+
>
|
|
1168
|
+
<span slot="label" class="sr-only">${filterByShowLabel}</span>
|
|
1169
|
+
${this.tvMapsLoading ? loadingIndicator : nothing}
|
|
1170
|
+
${this.tvMapsErrored ? errorMessage : nothing}
|
|
1171
|
+
</ia-combo-box>
|
|
1172
|
+
</div>
|
|
1166
1173
|
`;
|
|
1167
1174
|
}
|
|
1168
1175
|
/**
|
|
@@ -1172,10 +1179,10 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1172
1179
|
if (FACETLESS_PAGE_ELEMENTS.includes(this.profileElement))
|
|
1173
1180
|
return nothing;
|
|
1174
1181
|
if (this.facetLoadStrategy === 'off') {
|
|
1175
|
-
return html `
|
|
1176
|
-
<p class="facets-message">
|
|
1177
|
-
${msg('Facets are temporarily unavailable.')}
|
|
1178
|
-
</p>
|
|
1182
|
+
return html `
|
|
1183
|
+
<p class="facets-message">
|
|
1184
|
+
${msg('Facets are temporarily unavailable.')}
|
|
1185
|
+
</p>
|
|
1179
1186
|
`;
|
|
1180
1187
|
}
|
|
1181
1188
|
// We switch to TV facet ordering & date picker if we are in a TV collection or showing TV search results
|
|
@@ -1184,46 +1191,46 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1184
1191
|
const facetDisplayOrder = shouldUseTvInterface
|
|
1185
1192
|
? tvFacetDisplayOrder
|
|
1186
1193
|
: defaultFacetDisplayOrder;
|
|
1187
|
-
const facets = html `
|
|
1188
|
-
<collection-facets
|
|
1189
|
-
.collectionPagePath=${this.collectionPagePath}
|
|
1190
|
-
.parentCollections=${this.dataSource.parentCollections}
|
|
1191
|
-
.pageSpecifierParams=${this.dataSource.pageSpecifierParams}
|
|
1192
|
-
.searchService=${this.searchService}
|
|
1193
|
-
.featureFeedbackService=${this.featureFeedbackService}
|
|
1194
|
-
.recaptchaManager=${this.recaptchaManager}
|
|
1195
|
-
.resizeObserver=${this.resizeObserver}
|
|
1196
|
-
.searchType=${this.searchType}
|
|
1197
|
-
.aggregations=${this.dataSource.aggregations}
|
|
1198
|
-
.histogramAggregation=${this.dataSource.histogramAggregation}
|
|
1199
|
-
.minSelectedDate=${this.minSelectedDate}
|
|
1200
|
-
.maxSelectedDate=${this.maxSelectedDate}
|
|
1201
|
-
.selectedFacets=${this.selectedFacets}
|
|
1202
|
-
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
1203
|
-
.collectionTitles=${this.dataSource.collectionTitles}
|
|
1204
|
-
.tvChannelAliases=${this.dataSource.tvChannelAliases}
|
|
1205
|
-
.showHistogramDatePicker=${this.showHistogramDatePicker}
|
|
1206
|
-
.allowExpandingDatePicker=${!this.mobileView}
|
|
1207
|
-
.allowDatePickerMonths=${shouldUseTvInterface}
|
|
1208
|
-
.contentWidth=${this.contentWidth}
|
|
1209
|
-
.query=${this.baseQuery}
|
|
1210
|
-
.identifiers=${this.identifiers}
|
|
1211
|
-
.filterMap=${this.dataSource.filterMap}
|
|
1212
|
-
.isManageView=${this.isManageView}
|
|
1213
|
-
.modalManager=${this.modalManager}
|
|
1214
|
-
.analyticsHandler=${this.analyticsHandler}
|
|
1215
|
-
.facetDisplayOrder=${facetDisplayOrder}
|
|
1216
|
-
.isTvSearch=${shouldUseTvInterface}
|
|
1217
|
-
?collapsableFacets=${this.mobileView}
|
|
1218
|
-
?facetsLoading=${this.facetsLoading}
|
|
1219
|
-
?histogramAggregationLoading=${this.facetsLoading}
|
|
1220
|
-
?suppressMediatypeFacets=${this.suppressMediatypeFacets}
|
|
1221
|
-
@facetClick=${this.facetClickHandler}
|
|
1222
|
-
@facetsChanged=${this.facetsChanged}
|
|
1223
|
-
@histogramDateRangeUpdated=${this.histogramDateRangeUpdated}
|
|
1224
|
-
>
|
|
1225
|
-
${this.tvDropdownFiltersTemplate}
|
|
1226
|
-
</collection-facets>
|
|
1194
|
+
const facets = html `
|
|
1195
|
+
<collection-facets
|
|
1196
|
+
.collectionPagePath=${this.collectionPagePath}
|
|
1197
|
+
.parentCollections=${this.dataSource.parentCollections}
|
|
1198
|
+
.pageSpecifierParams=${this.dataSource.pageSpecifierParams}
|
|
1199
|
+
.searchService=${this.searchService}
|
|
1200
|
+
.featureFeedbackService=${this.featureFeedbackService}
|
|
1201
|
+
.recaptchaManager=${this.recaptchaManager}
|
|
1202
|
+
.resizeObserver=${this.resizeObserver}
|
|
1203
|
+
.searchType=${this.searchType}
|
|
1204
|
+
.aggregations=${this.dataSource.aggregations}
|
|
1205
|
+
.histogramAggregation=${this.dataSource.histogramAggregation}
|
|
1206
|
+
.minSelectedDate=${this.minSelectedDate}
|
|
1207
|
+
.maxSelectedDate=${this.maxSelectedDate}
|
|
1208
|
+
.selectedFacets=${this.selectedFacets}
|
|
1209
|
+
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
1210
|
+
.collectionTitles=${this.dataSource.collectionTitles}
|
|
1211
|
+
.tvChannelAliases=${this.dataSource.tvChannelAliases}
|
|
1212
|
+
.showHistogramDatePicker=${this.showHistogramDatePicker}
|
|
1213
|
+
.allowExpandingDatePicker=${!this.mobileView}
|
|
1214
|
+
.allowDatePickerMonths=${shouldUseTvInterface}
|
|
1215
|
+
.contentWidth=${this.contentWidth}
|
|
1216
|
+
.query=${this.baseQuery}
|
|
1217
|
+
.identifiers=${this.identifiers}
|
|
1218
|
+
.filterMap=${this.dataSource.filterMap}
|
|
1219
|
+
.isManageView=${this.isManageView}
|
|
1220
|
+
.modalManager=${this.modalManager}
|
|
1221
|
+
.analyticsHandler=${this.analyticsHandler}
|
|
1222
|
+
.facetDisplayOrder=${facetDisplayOrder}
|
|
1223
|
+
.isTvSearch=${shouldUseTvInterface}
|
|
1224
|
+
?collapsableFacets=${this.mobileView}
|
|
1225
|
+
?facetsLoading=${this.facetsLoading}
|
|
1226
|
+
?histogramAggregationLoading=${this.facetsLoading}
|
|
1227
|
+
?suppressMediatypeFacets=${this.suppressMediatypeFacets}
|
|
1228
|
+
@facetClick=${this.facetClickHandler}
|
|
1229
|
+
@facetsChanged=${this.facetsChanged}
|
|
1230
|
+
@histogramDateRangeUpdated=${this.histogramDateRangeUpdated}
|
|
1231
|
+
>
|
|
1232
|
+
${this.tvDropdownFiltersTemplate}
|
|
1233
|
+
</collection-facets>
|
|
1227
1234
|
`;
|
|
1228
1235
|
// If we are using one of the opt-in facet load strategies, we may need to wrap the
|
|
1229
1236
|
// desktop view facets in a <details> widget so that patrons can opt into loading them.
|
|
@@ -1231,20 +1238,20 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1231
1238
|
const showDesktopOptInWidget = this.facetLoadStrategy === 'opt-in' ||
|
|
1232
1239
|
(this.facetLoadStrategy === 'opt-in-or-login' && !this.loggedIn);
|
|
1233
1240
|
if (showDesktopOptInWidget && !this.mobileView) {
|
|
1234
|
-
return html `
|
|
1235
|
-
<details
|
|
1236
|
-
class="desktop-facets-dropdown"
|
|
1241
|
+
return html `
|
|
1242
|
+
<details
|
|
1243
|
+
class="desktop-facets-dropdown"
|
|
1237
1244
|
@toggle=${(e) => {
|
|
1238
1245
|
const target = e.target;
|
|
1239
1246
|
this.collapsibleFacetsVisible = target.open;
|
|
1240
|
-
}}
|
|
1241
|
-
>
|
|
1242
|
-
<summary>
|
|
1243
|
-
<span class="collapser-icon">${chevronIcon}</span>
|
|
1244
|
-
<h2>${msg('Filters')}</h2>
|
|
1245
|
-
</summary>
|
|
1246
|
-
${facets}
|
|
1247
|
-
</details>
|
|
1247
|
+
}}
|
|
1248
|
+
>
|
|
1249
|
+
<summary>
|
|
1250
|
+
<span class="collapser-icon">${chevronIcon}</span>
|
|
1251
|
+
<h2>${msg('Filters')}</h2>
|
|
1252
|
+
</summary>
|
|
1253
|
+
${facets}
|
|
1254
|
+
</details>
|
|
1248
1255
|
`;
|
|
1249
1256
|
}
|
|
1250
1257
|
// Otherwise, just render the facets component bare
|
|
@@ -1264,34 +1271,35 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1264
1271
|
mobile,
|
|
1265
1272
|
});
|
|
1266
1273
|
const buttonText = mobile ? 'Clear all' : 'Clear all filters';
|
|
1267
|
-
return html `
|
|
1268
|
-
<div class="clear-filters-btn-row">
|
|
1274
|
+
return html `
|
|
1275
|
+
<div class="clear-filters-btn-row">
|
|
1269
1276
|
${mobile
|
|
1270
1277
|
? html `<span class="clear-filters-btn-separator"> </span>`
|
|
1271
|
-
: nothing}
|
|
1272
|
-
<button class=${buttonClasses} @click=${this.clearFilters}>
|
|
1273
|
-
${buttonText}
|
|
1274
|
-
</button>
|
|
1275
|
-
</div>
|
|
1278
|
+
: nothing}
|
|
1279
|
+
<button class=${buttonClasses} @click=${this.clearFilters}>
|
|
1280
|
+
${buttonText}
|
|
1281
|
+
</button>
|
|
1282
|
+
</div>
|
|
1276
1283
|
`;
|
|
1277
1284
|
}
|
|
1278
1285
|
/**
|
|
1279
1286
|
* Template for the table header content that appears atop the compact list view.
|
|
1280
1287
|
*/
|
|
1281
1288
|
get listHeaderTemplate() {
|
|
1282
|
-
return html `
|
|
1283
|
-
<div id="list-header">
|
|
1284
|
-
<tile-dispatcher
|
|
1285
|
-
.tileDisplayMode=${'list-header'}
|
|
1286
|
-
.resizeObserver=${this.resizeObserver}
|
|
1287
|
-
.sortParam=${this.sortParam}
|
|
1288
|
-
.defaultSortParam=${this.defaultSortParam}
|
|
1289
|
-
.mobileBreakpoint=${this.mobileBreakpoint}
|
|
1290
|
-
.loggedIn=${this.loggedIn}
|
|
1291
|
-
.suppressBlurring=${this.shouldSuppressTileBlurring}
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1289
|
+
return html `
|
|
1290
|
+
<div id="list-header">
|
|
1291
|
+
<tile-dispatcher
|
|
1292
|
+
.tileDisplayMode=${'list-header'}
|
|
1293
|
+
.resizeObserver=${this.resizeObserver}
|
|
1294
|
+
.sortParam=${this.sortParam}
|
|
1295
|
+
.defaultSortParam=${this.defaultSortParam}
|
|
1296
|
+
.mobileBreakpoint=${this.mobileBreakpoint}
|
|
1297
|
+
.loggedIn=${this.loggedIn}
|
|
1298
|
+
.suppressBlurring=${this.shouldSuppressTileBlurring}
|
|
1299
|
+
.tileActions=${this.tileActions}
|
|
1300
|
+
>
|
|
1301
|
+
</tile-dispatcher>
|
|
1302
|
+
</div>
|
|
1295
1303
|
`;
|
|
1296
1304
|
}
|
|
1297
1305
|
/**
|
|
@@ -1411,7 +1419,9 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
1411
1419
|
if (changed.has('displayMode') ||
|
|
1412
1420
|
changed.has('baseNavigationUrl') ||
|
|
1413
1421
|
changed.has('baseImageUrl') ||
|
|
1414
|
-
changed.has('loggedIn')
|
|
1422
|
+
changed.has('loggedIn') ||
|
|
1423
|
+
changed.has('tileActions') ||
|
|
1424
|
+
changed.has('tileLayoutType')) {
|
|
1415
1425
|
this.infiniteScroller?.reload();
|
|
1416
1426
|
}
|
|
1417
1427
|
if (changed.has('profileElement')) {
|
|
@@ -2049,28 +2059,30 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
2049
2059
|
const isRadioSearch = this.searchType === SearchType.RADIO;
|
|
2050
2060
|
const { isTVCollection, isRadioCollection } = this;
|
|
2051
2061
|
const shouldUseLocalTime = isTVSearch || isRadioSearch || isTVCollection || isRadioCollection;
|
|
2052
|
-
return html `
|
|
2053
|
-
<tile-dispatcher
|
|
2054
|
-
.collectionPagePath=${this.collectionPagePath}
|
|
2055
|
-
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
2056
|
-
.baseImageUrl=${this.baseImageUrl}
|
|
2057
|
-
.model=${model}
|
|
2058
|
-
.tileDisplayMode=${this.displayMode}
|
|
2059
|
-
.resizeObserver=${this.resizeObserver}
|
|
2060
|
-
.collectionTitles=${this.dataSource.collectionTitles}
|
|
2061
|
-
.sortParam=${this.sortParam}
|
|
2062
|
-
.defaultSortParam=${this.defaultSortParam}
|
|
2063
|
-
.creatorFilter=${this.selectedCreatorFilter}
|
|
2064
|
-
.mobileBreakpoint=${this.mobileBreakpoint}
|
|
2065
|
-
.loggedIn=${this.loggedIn}
|
|
2066
|
-
.suppressBlurring=${this.shouldSuppressTileBlurring}
|
|
2067
|
-
.isManageView=${this.isManageView}
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
?
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2062
|
+
return html `
|
|
2063
|
+
<tile-dispatcher
|
|
2064
|
+
.collectionPagePath=${this.collectionPagePath}
|
|
2065
|
+
.baseNavigationUrl=${this.baseNavigationUrl}
|
|
2066
|
+
.baseImageUrl=${this.baseImageUrl}
|
|
2067
|
+
.model=${model}
|
|
2068
|
+
.tileDisplayMode=${this.displayMode}
|
|
2069
|
+
.resizeObserver=${this.resizeObserver}
|
|
2070
|
+
.collectionTitles=${this.dataSource.collectionTitles}
|
|
2071
|
+
.sortParam=${this.sortParam}
|
|
2072
|
+
.defaultSortParam=${this.defaultSortParam}
|
|
2073
|
+
.creatorFilter=${this.selectedCreatorFilter}
|
|
2074
|
+
.mobileBreakpoint=${this.mobileBreakpoint}
|
|
2075
|
+
.loggedIn=${this.loggedIn}
|
|
2076
|
+
.suppressBlurring=${this.shouldSuppressTileBlurring}
|
|
2077
|
+
.isManageView=${this.isManageView}
|
|
2078
|
+
.tileActions=${this.tileActions}
|
|
2079
|
+
.layoutType=${this.tileLayoutType}
|
|
2080
|
+
?showTvClips=${isTVSearch || isTVCollection}
|
|
2081
|
+
?enableHoverPane=${true}
|
|
2082
|
+
?useLocalTime=${shouldUseLocalTime}
|
|
2083
|
+
@resultSelected=${(e) => this.resultSelected(e)}
|
|
2084
|
+
>
|
|
2085
|
+
</tile-dispatcher>
|
|
2074
2086
|
`;
|
|
2075
2087
|
}
|
|
2076
2088
|
/**
|
|
@@ -2105,479 +2117,479 @@ let CollectionBrowser = class CollectionBrowser extends LitElement {
|
|
|
2105
2117
|
static get styles() {
|
|
2106
2118
|
return [
|
|
2107
2119
|
srOnlyStyle,
|
|
2108
|
-
css `
|
|
2109
|
-
:host {
|
|
2110
|
-
display: block;
|
|
2111
|
-
--leftColumnWidth: 18rem;
|
|
2112
|
-
--leftColumnPaddingTop: 2rem;
|
|
2113
|
-
--leftColumnPaddingRight: 2.5rem;
|
|
2114
|
-
}
|
|
2115
|
-
|
|
2116
|
-
#facet-top-view {
|
|
2117
|
-
display: flex;
|
|
2118
|
-
}
|
|
2119
|
-
|
|
2120
|
-
/**
|
|
2121
|
-
* When page width resizes from desktop to mobile, use this class to
|
|
2122
|
-
* disable expand/collapse transition when loading.
|
|
2123
|
-
*/
|
|
2124
|
-
.preload * {
|
|
2125
|
-
transition: none !important;
|
|
2126
|
-
-webkit-transition: none !important;
|
|
2127
|
-
-moz-transition: none !important;
|
|
2128
|
-
-ms-transition: none !important;
|
|
2129
|
-
-o-transition: none !important;
|
|
2130
|
-
}
|
|
2131
|
-
|
|
2132
|
-
#content-container {
|
|
2133
|
-
display: flex;
|
|
2134
|
-
}
|
|
2135
|
-
|
|
2136
|
-
empty-placeholder {
|
|
2137
|
-
margin-top: var(--placeholderMarginTop, 0);
|
|
2138
|
-
}
|
|
2139
|
-
|
|
2140
|
-
.collapser-icon {
|
|
2141
|
-
display: inline-block;
|
|
2142
|
-
}
|
|
2143
|
-
|
|
2144
|
-
.collapser-icon svg {
|
|
2145
|
-
display: inline-block;
|
|
2146
|
-
width: 12px;
|
|
2147
|
-
height: 12px;
|
|
2148
|
-
transition: transform 0.2s ease-out;
|
|
2149
|
-
}
|
|
2150
|
-
|
|
2151
|
-
#mobile-filter-collapse {
|
|
2152
|
-
width: 100%;
|
|
2153
|
-
}
|
|
2154
|
-
|
|
2155
|
-
#mobile-filter-collapse > summary {
|
|
2156
|
-
cursor: pointer;
|
|
2157
|
-
list-style: none;
|
|
2158
|
-
}
|
|
2159
|
-
|
|
2160
|
-
#mobile-filter-collapse[open] > summary {
|
|
2161
|
-
margin-bottom: 10px;
|
|
2162
|
-
}
|
|
2163
|
-
|
|
2164
|
-
#mobile-filter-collapse h2 {
|
|
2165
|
-
display: inline-block;
|
|
2166
|
-
margin: 0;
|
|
2167
|
-
font-size: 2rem;
|
|
2168
|
-
}
|
|
2169
|
-
|
|
2170
|
-
#mobile-filter-collapse[open] svg {
|
|
2171
|
-
transform: rotate(90deg);
|
|
2172
|
-
}
|
|
2173
|
-
|
|
2174
|
-
#content-container.mobile {
|
|
2175
|
-
display: block;
|
|
2176
|
-
}
|
|
2177
|
-
|
|
2178
|
-
#right-column {
|
|
2179
|
-
flex: 1;
|
|
2180
|
-
position: relative;
|
|
2181
|
-
min-height: 90vh;
|
|
2182
|
-
border-right: 1px solid rgb(232, 232, 232);
|
|
2183
|
-
margin-top: var(--rightColumnMarginTop, 0);
|
|
2184
|
-
padding-top: var(--rightColumnPaddingTop, 2rem);
|
|
2185
|
-
background: #fff;
|
|
2186
|
-
}
|
|
2187
|
-
|
|
2188
|
-
#left-column:not([hidden]) + #right-column {
|
|
2189
|
-
border-left: 1px solid rgb(232, 232, 232);
|
|
2190
|
-
}
|
|
2191
|
-
|
|
2192
|
-
#right-column.smart-results-spacing {
|
|
2193
|
-
padding-top: 0.5rem;
|
|
2194
|
-
border-right: none;
|
|
2195
|
-
background: transparent;
|
|
2196
|
-
min-width: 0;
|
|
2197
|
-
}
|
|
2198
|
-
|
|
2199
|
-
#results {
|
|
2200
|
-
background: #fff;
|
|
2201
|
-
padding-left: 1rem;
|
|
2202
|
-
padding-right: 1rem;
|
|
2203
|
-
}
|
|
2204
|
-
|
|
2205
|
-
#right-column.smart-results-spacing #results {
|
|
2206
|
-
border-radius: 10px 10px 0px 0px;
|
|
2207
|
-
padding-top: 0.5rem;
|
|
2208
|
-
margin-top: 1rem;
|
|
2209
|
-
}
|
|
2210
|
-
|
|
2211
|
-
.mobile #right-column {
|
|
2212
|
-
border-left: none;
|
|
2213
|
-
}
|
|
2214
|
-
|
|
2215
|
-
.mobile #results {
|
|
2216
|
-
padding: 5px 5px 0;
|
|
2217
|
-
}
|
|
2218
|
-
|
|
2219
|
-
#left-column {
|
|
2220
|
-
width: var(--leftColumnWidth, 18rem);
|
|
2221
|
-
/* Prevents Safari from shrinking col at first draw */
|
|
2222
|
-
min-width: var(--leftColumnWidth, 18rem);
|
|
2223
|
-
padding-top: var(--leftColumnPaddingTop, 2rem);
|
|
2224
|
-
/* Reduced padding by 0.2rem to add the invisible border in the rule below */
|
|
2225
|
-
padding-right: calc(var(--leftColumnPaddingRight, 2.5rem) - 0.2rem);
|
|
2226
|
-
border-right: 0.2rem solid transparent; /* Pads to the right of the scrollbar a bit */
|
|
2227
|
-
z-index: 1;
|
|
2228
|
-
}
|
|
2229
|
-
|
|
2230
|
-
.desktop #left-column {
|
|
2231
|
-
top: 0;
|
|
2232
|
-
position: sticky;
|
|
2233
|
-
height: calc(100vh - 2rem);
|
|
2234
|
-
max-height: calc(100vh - 2rem);
|
|
2235
|
-
overflow-x: hidden;
|
|
2236
|
-
overflow-y: scroll;
|
|
2237
|
-
|
|
2238
|
-
/*
|
|
2239
|
-
* Firefox doesn't support any of the -webkit-scrollbar stuff below, but
|
|
2240
|
-
* does at least give us a tiny bit of control over width & color.
|
|
2241
|
-
*/
|
|
2242
|
-
scrollbar-width: thin;
|
|
2243
|
-
scrollbar-color: transparent transparent;
|
|
2244
|
-
}
|
|
2245
|
-
.desktop #left-column:hover {
|
|
2246
|
-
scrollbar-color: auto;
|
|
2247
|
-
}
|
|
2248
|
-
.desktop #left-column::-webkit-scrollbar {
|
|
2249
|
-
appearance: none;
|
|
2250
|
-
width: 6px;
|
|
2251
|
-
}
|
|
2252
|
-
.desktop #left-column::-webkit-scrollbar-button {
|
|
2253
|
-
height: 3px;
|
|
2254
|
-
background: transparent;
|
|
2255
|
-
}
|
|
2256
|
-
.desktop #left-column::-webkit-scrollbar-corner {
|
|
2257
|
-
background: transparent;
|
|
2258
|
-
}
|
|
2259
|
-
.desktop #left-column::-webkit-scrollbar-thumb {
|
|
2260
|
-
border-radius: 4px;
|
|
2261
|
-
}
|
|
2262
|
-
.desktop #left-column:hover::-webkit-scrollbar-thumb {
|
|
2263
|
-
background: rgba(0, 0, 0, 0.15);
|
|
2264
|
-
}
|
|
2265
|
-
.desktop #left-column:hover::-webkit-scrollbar-thumb:hover {
|
|
2266
|
-
background: rgba(0, 0, 0, 0.2);
|
|
2267
|
-
}
|
|
2268
|
-
.desktop #left-column:hover::-webkit-scrollbar-thumb:active {
|
|
2269
|
-
background: rgba(0, 0, 0, 0.3);
|
|
2270
|
-
}
|
|
2271
|
-
|
|
2272
|
-
#facets-bottom-fade {
|
|
2273
|
-
background: linear-gradient(
|
|
2274
|
-
to bottom,
|
|
2275
|
-
#fbfbfd00 0%,
|
|
2276
|
-
#fbfbfdc0 50%,
|
|
2277
|
-
#fbfbfd 80%,
|
|
2278
|
-
#fbfbfd 100%
|
|
2279
|
-
);
|
|
2280
|
-
position: fixed;
|
|
2281
|
-
bottom: 0;
|
|
2282
|
-
height: 50px;
|
|
2283
|
-
/* Wide enough to cover the content, but leave the scrollbar uncovered */
|
|
2284
|
-
width: calc(
|
|
2285
|
-
var(--leftColumnWidth) + var(--leftColumnPaddingRight) - 10px
|
|
2286
|
-
);
|
|
2287
|
-
z-index: 2;
|
|
2288
|
-
pointer-events: none;
|
|
2289
|
-
transition: height 0.1s ease;
|
|
2290
|
-
}
|
|
2291
|
-
#facets-bottom-fade.hidden {
|
|
2292
|
-
height: 0;
|
|
2293
|
-
}
|
|
2294
|
-
|
|
2295
|
-
.facets-message {
|
|
2296
|
-
font-size: 1.4rem;
|
|
2297
|
-
}
|
|
2298
|
-
|
|
2299
|
-
.desktop-facets-dropdown > summary {
|
|
2300
|
-
cursor: pointer;
|
|
2301
|
-
list-style: none;
|
|
2302
|
-
}
|
|
2303
|
-
|
|
2304
|
-
.desktop-facets-dropdown h2 {
|
|
2305
|
-
display: inline-block;
|
|
2306
|
-
margin: 0;
|
|
2307
|
-
font-size: 1.6rem;
|
|
2308
|
-
}
|
|
2309
|
-
|
|
2310
|
-
.desktop-facets-dropdown[open] > summary {
|
|
2311
|
-
margin-bottom: 10px;
|
|
2312
|
-
}
|
|
2313
|
-
|
|
2314
|
-
.desktop-facets-dropdown[open] svg {
|
|
2315
|
-
transform: rotate(90deg);
|
|
2316
|
-
}
|
|
2317
|
-
|
|
2318
|
-
.desktop #left-column-scroll-sentinel {
|
|
2319
|
-
width: 1px;
|
|
2320
|
-
height: 100vh;
|
|
2321
|
-
background: transparent;
|
|
2322
|
-
}
|
|
2323
|
-
|
|
2324
|
-
.desktop #facets-scroll-sentinel {
|
|
2325
|
-
width: 1px;
|
|
2326
|
-
height: 1px;
|
|
2327
|
-
background: transparent;
|
|
2328
|
-
}
|
|
2329
|
-
|
|
2330
|
-
#facets-header-container {
|
|
2331
|
-
display: flex;
|
|
2332
|
-
justify-content: space-between;
|
|
2333
|
-
align-items: flex-start;
|
|
2334
|
-
clear: both;
|
|
2335
|
-
}
|
|
2336
|
-
|
|
2337
|
-
.desktop #facets-header-container {
|
|
2338
|
-
flex-wrap: wrap;
|
|
2339
|
-
}
|
|
2340
|
-
|
|
2341
|
-
.mobile #left-column {
|
|
2342
|
-
width: 100%;
|
|
2343
|
-
min-width: 0;
|
|
2344
|
-
padding: 5px 0;
|
|
2345
|
-
border: 0;
|
|
2346
|
-
}
|
|
2347
|
-
|
|
2348
|
-
.clear-filters-btn-row {
|
|
2349
|
-
display: inline-block;
|
|
2350
|
-
}
|
|
2351
|
-
|
|
2352
|
-
.desktop .clear-filters-btn-row {
|
|
2353
|
-
width: 100%;
|
|
2354
|
-
}
|
|
2355
|
-
|
|
2356
|
-
.clear-filters-btn {
|
|
2357
|
-
display: inline-block;
|
|
2358
|
-
appearance: none;
|
|
2359
|
-
margin: 0;
|
|
2360
|
-
padding: 0;
|
|
2361
|
-
border: 0;
|
|
2362
|
-
background: none;
|
|
2363
|
-
color: var(--ia-theme-link-color);
|
|
2364
|
-
font-size: 1.4rem;
|
|
2365
|
-
font-family: inherit;
|
|
2366
|
-
cursor: pointer;
|
|
2367
|
-
}
|
|
2368
|
-
|
|
2369
|
-
.clear-filters-btn:hover {
|
|
2370
|
-
text-decoration: underline;
|
|
2371
|
-
}
|
|
2372
|
-
|
|
2373
|
-
.clear-filters-btn-separator {
|
|
2374
|
-
display: inline-block;
|
|
2375
|
-
margin-left: 5px;
|
|
2376
|
-
border-left: 1px solid #2c2c2c;
|
|
2377
|
-
font-size: 1.4rem;
|
|
2378
|
-
line-height: 1.3rem;
|
|
2379
|
-
}
|
|
2380
|
-
|
|
2381
|
-
#tv-filters {
|
|
2382
|
-
margin-bottom: 15px;
|
|
2383
|
-
}
|
|
2384
|
-
|
|
2385
|
-
#tv-shows {
|
|
2386
|
-
--comboBoxListWidth: 300px;
|
|
2387
|
-
}
|
|
2388
|
-
|
|
2389
|
-
.tv-filter-dropdown {
|
|
2390
|
-
display: block;
|
|
2391
|
-
font-size: 14px;
|
|
2392
|
-
margin-left: 1px;
|
|
2393
|
-
margin-bottom: 5px;
|
|
2394
|
-
}
|
|
2395
|
-
|
|
2396
|
-
.tv-filter-dropdown::part(combo-box) {
|
|
2397
|
-
outline-offset: 1px;
|
|
2398
|
-
}
|
|
2399
|
-
|
|
2400
|
-
.tv-filter-dropdown::part(option) {
|
|
2401
|
-
line-height: 1.1;
|
|
2402
|
-
padding: 7px;
|
|
2403
|
-
}
|
|
2404
|
-
|
|
2405
|
-
.tv-filter-dropdown::part(clear-button) {
|
|
2406
|
-
flex: 0 0 26px;
|
|
2407
|
-
--combo-box-clear-icon-size: 14px;
|
|
2408
|
-
}
|
|
2409
|
-
|
|
2410
|
-
.tv-filter-dropdown::part(icon) {
|
|
2411
|
-
width: 1.4rem;
|
|
2412
|
-
height: 1.4rem;
|
|
2413
|
-
}
|
|
2414
|
-
|
|
2415
|
-
#facets-container {
|
|
2416
|
-
position: relative;
|
|
2417
|
-
max-height: 0;
|
|
2418
|
-
transition: max-height 0.2s ease-in-out;
|
|
2419
|
-
z-index: 1;
|
|
2420
|
-
margin-top: var(--facetsContainerMarginTop, 3rem);
|
|
2421
|
-
padding-bottom: 2rem;
|
|
2422
|
-
}
|
|
2423
|
-
|
|
2424
|
-
.desktop #facets-container {
|
|
2425
|
-
width: 18rem;
|
|
2426
|
-
}
|
|
2427
|
-
|
|
2428
|
-
.mobile #facets-container {
|
|
2429
|
-
overflow: hidden;
|
|
2430
|
-
padding-bottom: 0;
|
|
2431
|
-
padding-left: 10px;
|
|
2432
|
-
padding-right: 10px;
|
|
2433
|
-
}
|
|
2434
|
-
|
|
2435
|
-
#facets-container.expanded {
|
|
2436
|
-
max-height: 2000px;
|
|
2437
|
-
}
|
|
2438
|
-
|
|
2439
|
-
.results-section-heading {
|
|
2440
|
-
margin: 0.5rem 0.3rem;
|
|
2441
|
-
font-size: 2rem;
|
|
2442
|
-
line-height: 25px;
|
|
2443
|
-
}
|
|
2444
|
-
|
|
2445
|
-
#results-total {
|
|
2446
|
-
display: flex;
|
|
2447
|
-
align-items: baseline;
|
|
2448
|
-
}
|
|
2449
|
-
|
|
2450
|
-
#results-total:not(.filtered) {
|
|
2451
|
-
padding-bottom: 2rem;
|
|
2452
|
-
}
|
|
2453
|
-
|
|
2454
|
-
.mobile #results-total {
|
|
2455
|
-
position: absolute;
|
|
2456
|
-
right: 10px;
|
|
2457
|
-
}
|
|
2458
|
-
|
|
2459
|
-
#big-results-count {
|
|
2460
|
-
font-size: 2.4rem;
|
|
2461
|
-
font-weight: 500;
|
|
2462
|
-
margin-right: 5px;
|
|
2463
|
-
}
|
|
2464
|
-
|
|
2465
|
-
.mobile #big-results-count {
|
|
2466
|
-
font-size: 2rem;
|
|
2467
|
-
}
|
|
2468
|
-
|
|
2469
|
-
#big-results-label {
|
|
2470
|
-
font-size: 1.4rem;
|
|
2471
|
-
font-weight: 200;
|
|
2472
|
-
}
|
|
2473
|
-
|
|
2474
|
-
#list-header {
|
|
2475
|
-
max-height: 4.2rem;
|
|
2476
|
-
}
|
|
2477
|
-
|
|
2478
|
-
.loading-cover {
|
|
2479
|
-
position: absolute;
|
|
2480
|
-
top: 0;
|
|
2481
|
-
left: 0;
|
|
2482
|
-
width: 100%;
|
|
2483
|
-
height: 100%;
|
|
2484
|
-
display: flex;
|
|
2485
|
-
justify-content: center;
|
|
2486
|
-
z-index: 1;
|
|
2487
|
-
padding-top: 50px;
|
|
2488
|
-
}
|
|
2489
|
-
|
|
2490
|
-
#tile-blur-label {
|
|
2491
|
-
display: flex;
|
|
2492
|
-
align-items: center;
|
|
2493
|
-
column-gap: 5px;
|
|
2494
|
-
}
|
|
2495
|
-
|
|
2496
|
-
#tile-blur-check {
|
|
2497
|
-
margin: 0 5px 0 0;
|
|
2498
|
-
width: 15px;
|
|
2499
|
-
}
|
|
2500
|
-
|
|
2501
|
-
circular-activity-indicator {
|
|
2502
|
-
width: 30px;
|
|
2503
|
-
height: 30px;
|
|
2504
|
-
}
|
|
2505
|
-
|
|
2506
|
-
sort-filter-bar {
|
|
2507
|
-
display: block;
|
|
2508
|
-
margin-bottom: 4rem;
|
|
2509
|
-
}
|
|
2510
|
-
|
|
2511
|
-
infinite-scroller {
|
|
2512
|
-
display: block;
|
|
2513
|
-
--infiniteScrollerRowGap: var(--collectionBrowserRowGap, 1.7rem);
|
|
2514
|
-
--infiniteScrollerColGap: var(--collectionBrowserColGap, 1.7rem);
|
|
2515
|
-
}
|
|
2516
|
-
|
|
2517
|
-
infinite-scroller.list-compact {
|
|
2518
|
-
--infiniteScrollerCellMinWidth: var(
|
|
2519
|
-
--collectionBrowserCellMinWidth,
|
|
2520
|
-
100%
|
|
2521
|
-
);
|
|
2522
|
-
--infiniteScrollerCellMinHeight: 45px; /* override infinite scroller component */
|
|
2523
|
-
--infiniteScrollerCellMaxHeight: 56px;
|
|
2524
|
-
--infiniteScrollerRowGap: 10px;
|
|
2525
|
-
}
|
|
2526
|
-
|
|
2527
|
-
infinite-scroller.list-detail {
|
|
2528
|
-
--infiniteScrollerCellMinWidth: var(
|
|
2529
|
-
--collectionBrowserCellMinWidth,
|
|
2530
|
-
100%
|
|
2531
|
-
);
|
|
2532
|
-
--infiniteScrollerCellMinHeight: var(
|
|
2533
|
-
--collectionBrowserCellMinHeight,
|
|
2534
|
-
5rem
|
|
2535
|
-
);
|
|
2536
|
-
/*
|
|
2537
|
-
30px in spec, compensating for a -4px margin
|
|
2538
|
-
to align title with top of item image
|
|
2539
|
-
src/tiles/list/tile-list.ts
|
|
2540
|
-
*/
|
|
2541
|
-
--infiniteScrollerRowGap: 34px;
|
|
2542
|
-
}
|
|
2543
|
-
|
|
2544
|
-
.mobile infinite-scroller.list-detail {
|
|
2545
|
-
--infiniteScrollerRowGap: 24px;
|
|
2546
|
-
}
|
|
2547
|
-
|
|
2548
|
-
infinite-scroller.grid {
|
|
2549
|
-
--infiniteScrollerCellMinWidth: var(
|
|
2550
|
-
--collectionBrowserCellMinWidth,
|
|
2551
|
-
17rem
|
|
2552
|
-
);
|
|
2553
|
-
--infiniteScrollerCellMaxWidth: var(
|
|
2554
|
-
--collectionBrowserCellMaxWidth,
|
|
2555
|
-
1fr
|
|
2556
|
-
);
|
|
2557
|
-
}
|
|
2558
|
-
|
|
2559
|
-
/* Allow tiles to shrink a bit further at smaller viewport widths */
|
|
2560
|
-
@media screen and (max-width: 880px) {
|
|
2561
|
-
infinite-scroller.grid {
|
|
2562
|
-
--infiniteScrollerCellMinWidth: var(
|
|
2563
|
-
--collectionBrowserCellMinWidth,
|
|
2564
|
-
15rem
|
|
2565
|
-
);
|
|
2566
|
-
}
|
|
2567
|
-
}
|
|
2568
|
-
/* At very small widths, maintain a 2-tile layout as far as it can reasonably go */
|
|
2569
|
-
@media screen and (max-width: 360px) {
|
|
2570
|
-
infinite-scroller.grid {
|
|
2571
|
-
--infiniteScrollerCellMinWidth: var(
|
|
2572
|
-
--collectionBrowserCellMinWidth,
|
|
2573
|
-
12rem
|
|
2574
|
-
);
|
|
2575
|
-
}
|
|
2576
|
-
}
|
|
2577
|
-
|
|
2578
|
-
infinite-scroller.hidden {
|
|
2579
|
-
display: none;
|
|
2580
|
-
}
|
|
2120
|
+
css `
|
|
2121
|
+
:host {
|
|
2122
|
+
display: block;
|
|
2123
|
+
--leftColumnWidth: 18rem;
|
|
2124
|
+
--leftColumnPaddingTop: 2rem;
|
|
2125
|
+
--leftColumnPaddingRight: 2.5rem;
|
|
2126
|
+
}
|
|
2127
|
+
|
|
2128
|
+
#facet-top-view {
|
|
2129
|
+
display: flex;
|
|
2130
|
+
}
|
|
2131
|
+
|
|
2132
|
+
/**
|
|
2133
|
+
* When page width resizes from desktop to mobile, use this class to
|
|
2134
|
+
* disable expand/collapse transition when loading.
|
|
2135
|
+
*/
|
|
2136
|
+
.preload * {
|
|
2137
|
+
transition: none !important;
|
|
2138
|
+
-webkit-transition: none !important;
|
|
2139
|
+
-moz-transition: none !important;
|
|
2140
|
+
-ms-transition: none !important;
|
|
2141
|
+
-o-transition: none !important;
|
|
2142
|
+
}
|
|
2143
|
+
|
|
2144
|
+
#content-container {
|
|
2145
|
+
display: flex;
|
|
2146
|
+
}
|
|
2147
|
+
|
|
2148
|
+
empty-placeholder {
|
|
2149
|
+
margin-top: var(--placeholderMarginTop, 0);
|
|
2150
|
+
}
|
|
2151
|
+
|
|
2152
|
+
.collapser-icon {
|
|
2153
|
+
display: inline-block;
|
|
2154
|
+
}
|
|
2155
|
+
|
|
2156
|
+
.collapser-icon svg {
|
|
2157
|
+
display: inline-block;
|
|
2158
|
+
width: 12px;
|
|
2159
|
+
height: 12px;
|
|
2160
|
+
transition: transform 0.2s ease-out;
|
|
2161
|
+
}
|
|
2162
|
+
|
|
2163
|
+
#mobile-filter-collapse {
|
|
2164
|
+
width: 100%;
|
|
2165
|
+
}
|
|
2166
|
+
|
|
2167
|
+
#mobile-filter-collapse > summary {
|
|
2168
|
+
cursor: pointer;
|
|
2169
|
+
list-style: none;
|
|
2170
|
+
}
|
|
2171
|
+
|
|
2172
|
+
#mobile-filter-collapse[open] > summary {
|
|
2173
|
+
margin-bottom: 10px;
|
|
2174
|
+
}
|
|
2175
|
+
|
|
2176
|
+
#mobile-filter-collapse h2 {
|
|
2177
|
+
display: inline-block;
|
|
2178
|
+
margin: 0;
|
|
2179
|
+
font-size: 2rem;
|
|
2180
|
+
}
|
|
2181
|
+
|
|
2182
|
+
#mobile-filter-collapse[open] svg {
|
|
2183
|
+
transform: rotate(90deg);
|
|
2184
|
+
}
|
|
2185
|
+
|
|
2186
|
+
#content-container.mobile {
|
|
2187
|
+
display: block;
|
|
2188
|
+
}
|
|
2189
|
+
|
|
2190
|
+
#right-column {
|
|
2191
|
+
flex: 1;
|
|
2192
|
+
position: relative;
|
|
2193
|
+
min-height: 90vh;
|
|
2194
|
+
border-right: 1px solid rgb(232, 232, 232);
|
|
2195
|
+
margin-top: var(--rightColumnMarginTop, 0);
|
|
2196
|
+
padding-top: var(--rightColumnPaddingTop, 2rem);
|
|
2197
|
+
background: #fff;
|
|
2198
|
+
}
|
|
2199
|
+
|
|
2200
|
+
#left-column:not([hidden]) + #right-column {
|
|
2201
|
+
border-left: 1px solid rgb(232, 232, 232);
|
|
2202
|
+
}
|
|
2203
|
+
|
|
2204
|
+
#right-column.smart-results-spacing {
|
|
2205
|
+
padding-top: 0.5rem;
|
|
2206
|
+
border-right: none;
|
|
2207
|
+
background: transparent;
|
|
2208
|
+
min-width: 0;
|
|
2209
|
+
}
|
|
2210
|
+
|
|
2211
|
+
#results {
|
|
2212
|
+
background: #fff;
|
|
2213
|
+
padding-left: 1rem;
|
|
2214
|
+
padding-right: 1rem;
|
|
2215
|
+
}
|
|
2216
|
+
|
|
2217
|
+
#right-column.smart-results-spacing #results {
|
|
2218
|
+
border-radius: 10px 10px 0px 0px;
|
|
2219
|
+
padding-top: 0.5rem;
|
|
2220
|
+
margin-top: 1rem;
|
|
2221
|
+
}
|
|
2222
|
+
|
|
2223
|
+
.mobile #right-column {
|
|
2224
|
+
border-left: none;
|
|
2225
|
+
}
|
|
2226
|
+
|
|
2227
|
+
.mobile #results {
|
|
2228
|
+
padding: 5px 5px 0;
|
|
2229
|
+
}
|
|
2230
|
+
|
|
2231
|
+
#left-column {
|
|
2232
|
+
width: var(--leftColumnWidth, 18rem);
|
|
2233
|
+
/* Prevents Safari from shrinking col at first draw */
|
|
2234
|
+
min-width: var(--leftColumnWidth, 18rem);
|
|
2235
|
+
padding-top: var(--leftColumnPaddingTop, 2rem);
|
|
2236
|
+
/* Reduced padding by 0.2rem to add the invisible border in the rule below */
|
|
2237
|
+
padding-right: calc(var(--leftColumnPaddingRight, 2.5rem) - 0.2rem);
|
|
2238
|
+
border-right: 0.2rem solid transparent; /* Pads to the right of the scrollbar a bit */
|
|
2239
|
+
z-index: 1;
|
|
2240
|
+
}
|
|
2241
|
+
|
|
2242
|
+
.desktop #left-column {
|
|
2243
|
+
top: 0;
|
|
2244
|
+
position: sticky;
|
|
2245
|
+
height: calc(100vh - 2rem);
|
|
2246
|
+
max-height: calc(100vh - 2rem);
|
|
2247
|
+
overflow-x: hidden;
|
|
2248
|
+
overflow-y: scroll;
|
|
2249
|
+
|
|
2250
|
+
/*
|
|
2251
|
+
* Firefox doesn't support any of the -webkit-scrollbar stuff below, but
|
|
2252
|
+
* does at least give us a tiny bit of control over width & color.
|
|
2253
|
+
*/
|
|
2254
|
+
scrollbar-width: thin;
|
|
2255
|
+
scrollbar-color: transparent transparent;
|
|
2256
|
+
}
|
|
2257
|
+
.desktop #left-column:hover {
|
|
2258
|
+
scrollbar-color: auto;
|
|
2259
|
+
}
|
|
2260
|
+
.desktop #left-column::-webkit-scrollbar {
|
|
2261
|
+
appearance: none;
|
|
2262
|
+
width: 6px;
|
|
2263
|
+
}
|
|
2264
|
+
.desktop #left-column::-webkit-scrollbar-button {
|
|
2265
|
+
height: 3px;
|
|
2266
|
+
background: transparent;
|
|
2267
|
+
}
|
|
2268
|
+
.desktop #left-column::-webkit-scrollbar-corner {
|
|
2269
|
+
background: transparent;
|
|
2270
|
+
}
|
|
2271
|
+
.desktop #left-column::-webkit-scrollbar-thumb {
|
|
2272
|
+
border-radius: 4px;
|
|
2273
|
+
}
|
|
2274
|
+
.desktop #left-column:hover::-webkit-scrollbar-thumb {
|
|
2275
|
+
background: rgba(0, 0, 0, 0.15);
|
|
2276
|
+
}
|
|
2277
|
+
.desktop #left-column:hover::-webkit-scrollbar-thumb:hover {
|
|
2278
|
+
background: rgba(0, 0, 0, 0.2);
|
|
2279
|
+
}
|
|
2280
|
+
.desktop #left-column:hover::-webkit-scrollbar-thumb:active {
|
|
2281
|
+
background: rgba(0, 0, 0, 0.3);
|
|
2282
|
+
}
|
|
2283
|
+
|
|
2284
|
+
#facets-bottom-fade {
|
|
2285
|
+
background: linear-gradient(
|
|
2286
|
+
to bottom,
|
|
2287
|
+
#fbfbfd00 0%,
|
|
2288
|
+
#fbfbfdc0 50%,
|
|
2289
|
+
#fbfbfd 80%,
|
|
2290
|
+
#fbfbfd 100%
|
|
2291
|
+
);
|
|
2292
|
+
position: fixed;
|
|
2293
|
+
bottom: 0;
|
|
2294
|
+
height: 50px;
|
|
2295
|
+
/* Wide enough to cover the content, but leave the scrollbar uncovered */
|
|
2296
|
+
width: calc(
|
|
2297
|
+
var(--leftColumnWidth) + var(--leftColumnPaddingRight) - 10px
|
|
2298
|
+
);
|
|
2299
|
+
z-index: 2;
|
|
2300
|
+
pointer-events: none;
|
|
2301
|
+
transition: height 0.1s ease;
|
|
2302
|
+
}
|
|
2303
|
+
#facets-bottom-fade.hidden {
|
|
2304
|
+
height: 0;
|
|
2305
|
+
}
|
|
2306
|
+
|
|
2307
|
+
.facets-message {
|
|
2308
|
+
font-size: 1.4rem;
|
|
2309
|
+
}
|
|
2310
|
+
|
|
2311
|
+
.desktop-facets-dropdown > summary {
|
|
2312
|
+
cursor: pointer;
|
|
2313
|
+
list-style: none;
|
|
2314
|
+
}
|
|
2315
|
+
|
|
2316
|
+
.desktop-facets-dropdown h2 {
|
|
2317
|
+
display: inline-block;
|
|
2318
|
+
margin: 0;
|
|
2319
|
+
font-size: 1.6rem;
|
|
2320
|
+
}
|
|
2321
|
+
|
|
2322
|
+
.desktop-facets-dropdown[open] > summary {
|
|
2323
|
+
margin-bottom: 10px;
|
|
2324
|
+
}
|
|
2325
|
+
|
|
2326
|
+
.desktop-facets-dropdown[open] svg {
|
|
2327
|
+
transform: rotate(90deg);
|
|
2328
|
+
}
|
|
2329
|
+
|
|
2330
|
+
.desktop #left-column-scroll-sentinel {
|
|
2331
|
+
width: 1px;
|
|
2332
|
+
height: 100vh;
|
|
2333
|
+
background: transparent;
|
|
2334
|
+
}
|
|
2335
|
+
|
|
2336
|
+
.desktop #facets-scroll-sentinel {
|
|
2337
|
+
width: 1px;
|
|
2338
|
+
height: 1px;
|
|
2339
|
+
background: transparent;
|
|
2340
|
+
}
|
|
2341
|
+
|
|
2342
|
+
#facets-header-container {
|
|
2343
|
+
display: flex;
|
|
2344
|
+
justify-content: space-between;
|
|
2345
|
+
align-items: flex-start;
|
|
2346
|
+
clear: both;
|
|
2347
|
+
}
|
|
2348
|
+
|
|
2349
|
+
.desktop #facets-header-container {
|
|
2350
|
+
flex-wrap: wrap;
|
|
2351
|
+
}
|
|
2352
|
+
|
|
2353
|
+
.mobile #left-column {
|
|
2354
|
+
width: 100%;
|
|
2355
|
+
min-width: 0;
|
|
2356
|
+
padding: 5px 0;
|
|
2357
|
+
border: 0;
|
|
2358
|
+
}
|
|
2359
|
+
|
|
2360
|
+
.clear-filters-btn-row {
|
|
2361
|
+
display: inline-block;
|
|
2362
|
+
}
|
|
2363
|
+
|
|
2364
|
+
.desktop .clear-filters-btn-row {
|
|
2365
|
+
width: 100%;
|
|
2366
|
+
}
|
|
2367
|
+
|
|
2368
|
+
.clear-filters-btn {
|
|
2369
|
+
display: inline-block;
|
|
2370
|
+
appearance: none;
|
|
2371
|
+
margin: 0;
|
|
2372
|
+
padding: 0;
|
|
2373
|
+
border: 0;
|
|
2374
|
+
background: none;
|
|
2375
|
+
color: var(--ia-theme-link-color);
|
|
2376
|
+
font-size: 1.4rem;
|
|
2377
|
+
font-family: inherit;
|
|
2378
|
+
cursor: pointer;
|
|
2379
|
+
}
|
|
2380
|
+
|
|
2381
|
+
.clear-filters-btn:hover {
|
|
2382
|
+
text-decoration: underline;
|
|
2383
|
+
}
|
|
2384
|
+
|
|
2385
|
+
.clear-filters-btn-separator {
|
|
2386
|
+
display: inline-block;
|
|
2387
|
+
margin-left: 5px;
|
|
2388
|
+
border-left: 1px solid #2c2c2c;
|
|
2389
|
+
font-size: 1.4rem;
|
|
2390
|
+
line-height: 1.3rem;
|
|
2391
|
+
}
|
|
2392
|
+
|
|
2393
|
+
#tv-filters {
|
|
2394
|
+
margin-bottom: 15px;
|
|
2395
|
+
}
|
|
2396
|
+
|
|
2397
|
+
#tv-shows {
|
|
2398
|
+
--comboBoxListWidth: 300px;
|
|
2399
|
+
}
|
|
2400
|
+
|
|
2401
|
+
.tv-filter-dropdown {
|
|
2402
|
+
display: block;
|
|
2403
|
+
font-size: 14px;
|
|
2404
|
+
margin-left: 1px;
|
|
2405
|
+
margin-bottom: 5px;
|
|
2406
|
+
}
|
|
2407
|
+
|
|
2408
|
+
.tv-filter-dropdown::part(combo-box) {
|
|
2409
|
+
outline-offset: 1px;
|
|
2410
|
+
}
|
|
2411
|
+
|
|
2412
|
+
.tv-filter-dropdown::part(option) {
|
|
2413
|
+
line-height: 1.1;
|
|
2414
|
+
padding: 7px;
|
|
2415
|
+
}
|
|
2416
|
+
|
|
2417
|
+
.tv-filter-dropdown::part(clear-button) {
|
|
2418
|
+
flex: 0 0 26px;
|
|
2419
|
+
--combo-box-clear-icon-size: 14px;
|
|
2420
|
+
}
|
|
2421
|
+
|
|
2422
|
+
.tv-filter-dropdown::part(icon) {
|
|
2423
|
+
width: 1.4rem;
|
|
2424
|
+
height: 1.4rem;
|
|
2425
|
+
}
|
|
2426
|
+
|
|
2427
|
+
#facets-container {
|
|
2428
|
+
position: relative;
|
|
2429
|
+
max-height: 0;
|
|
2430
|
+
transition: max-height 0.2s ease-in-out;
|
|
2431
|
+
z-index: 1;
|
|
2432
|
+
margin-top: var(--facetsContainerMarginTop, 3rem);
|
|
2433
|
+
padding-bottom: 2rem;
|
|
2434
|
+
}
|
|
2435
|
+
|
|
2436
|
+
.desktop #facets-container {
|
|
2437
|
+
width: 18rem;
|
|
2438
|
+
}
|
|
2439
|
+
|
|
2440
|
+
.mobile #facets-container {
|
|
2441
|
+
overflow: hidden;
|
|
2442
|
+
padding-bottom: 0;
|
|
2443
|
+
padding-left: 10px;
|
|
2444
|
+
padding-right: 10px;
|
|
2445
|
+
}
|
|
2446
|
+
|
|
2447
|
+
#facets-container.expanded {
|
|
2448
|
+
max-height: 2000px;
|
|
2449
|
+
}
|
|
2450
|
+
|
|
2451
|
+
.results-section-heading {
|
|
2452
|
+
margin: 0.5rem 0.3rem;
|
|
2453
|
+
font-size: 2rem;
|
|
2454
|
+
line-height: 25px;
|
|
2455
|
+
}
|
|
2456
|
+
|
|
2457
|
+
#results-total {
|
|
2458
|
+
display: flex;
|
|
2459
|
+
align-items: baseline;
|
|
2460
|
+
}
|
|
2461
|
+
|
|
2462
|
+
#results-total:not(.filtered) {
|
|
2463
|
+
padding-bottom: 2rem;
|
|
2464
|
+
}
|
|
2465
|
+
|
|
2466
|
+
.mobile #results-total {
|
|
2467
|
+
position: absolute;
|
|
2468
|
+
right: 10px;
|
|
2469
|
+
}
|
|
2470
|
+
|
|
2471
|
+
#big-results-count {
|
|
2472
|
+
font-size: 2.4rem;
|
|
2473
|
+
font-weight: 500;
|
|
2474
|
+
margin-right: 5px;
|
|
2475
|
+
}
|
|
2476
|
+
|
|
2477
|
+
.mobile #big-results-count {
|
|
2478
|
+
font-size: 2rem;
|
|
2479
|
+
}
|
|
2480
|
+
|
|
2481
|
+
#big-results-label {
|
|
2482
|
+
font-size: 1.4rem;
|
|
2483
|
+
font-weight: 200;
|
|
2484
|
+
}
|
|
2485
|
+
|
|
2486
|
+
#list-header {
|
|
2487
|
+
max-height: 4.2rem;
|
|
2488
|
+
}
|
|
2489
|
+
|
|
2490
|
+
.loading-cover {
|
|
2491
|
+
position: absolute;
|
|
2492
|
+
top: 0;
|
|
2493
|
+
left: 0;
|
|
2494
|
+
width: 100%;
|
|
2495
|
+
height: 100%;
|
|
2496
|
+
display: flex;
|
|
2497
|
+
justify-content: center;
|
|
2498
|
+
z-index: 1;
|
|
2499
|
+
padding-top: 50px;
|
|
2500
|
+
}
|
|
2501
|
+
|
|
2502
|
+
#tile-blur-label {
|
|
2503
|
+
display: flex;
|
|
2504
|
+
align-items: center;
|
|
2505
|
+
column-gap: 5px;
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2508
|
+
#tile-blur-check {
|
|
2509
|
+
margin: 0 5px 0 0;
|
|
2510
|
+
width: 15px;
|
|
2511
|
+
}
|
|
2512
|
+
|
|
2513
|
+
circular-activity-indicator {
|
|
2514
|
+
width: 30px;
|
|
2515
|
+
height: 30px;
|
|
2516
|
+
}
|
|
2517
|
+
|
|
2518
|
+
sort-filter-bar {
|
|
2519
|
+
display: block;
|
|
2520
|
+
margin-bottom: 4rem;
|
|
2521
|
+
}
|
|
2522
|
+
|
|
2523
|
+
infinite-scroller {
|
|
2524
|
+
display: block;
|
|
2525
|
+
--infiniteScrollerRowGap: var(--collectionBrowserRowGap, 1.7rem);
|
|
2526
|
+
--infiniteScrollerColGap: var(--collectionBrowserColGap, 1.7rem);
|
|
2527
|
+
}
|
|
2528
|
+
|
|
2529
|
+
infinite-scroller.list-compact {
|
|
2530
|
+
--infiniteScrollerCellMinWidth: var(
|
|
2531
|
+
--collectionBrowserCellMinWidth,
|
|
2532
|
+
100%
|
|
2533
|
+
);
|
|
2534
|
+
--infiniteScrollerCellMinHeight: 45px; /* override infinite scroller component */
|
|
2535
|
+
--infiniteScrollerCellMaxHeight: 56px;
|
|
2536
|
+
--infiniteScrollerRowGap: 10px;
|
|
2537
|
+
}
|
|
2538
|
+
|
|
2539
|
+
infinite-scroller.list-detail {
|
|
2540
|
+
--infiniteScrollerCellMinWidth: var(
|
|
2541
|
+
--collectionBrowserCellMinWidth,
|
|
2542
|
+
100%
|
|
2543
|
+
);
|
|
2544
|
+
--infiniteScrollerCellMinHeight: var(
|
|
2545
|
+
--collectionBrowserCellMinHeight,
|
|
2546
|
+
5rem
|
|
2547
|
+
);
|
|
2548
|
+
/*
|
|
2549
|
+
30px in spec, compensating for a -4px margin
|
|
2550
|
+
to align title with top of item image
|
|
2551
|
+
src/tiles/list/tile-list.ts
|
|
2552
|
+
*/
|
|
2553
|
+
--infiniteScrollerRowGap: 34px;
|
|
2554
|
+
}
|
|
2555
|
+
|
|
2556
|
+
.mobile infinite-scroller.list-detail {
|
|
2557
|
+
--infiniteScrollerRowGap: 24px;
|
|
2558
|
+
}
|
|
2559
|
+
|
|
2560
|
+
infinite-scroller.grid {
|
|
2561
|
+
--infiniteScrollerCellMinWidth: var(
|
|
2562
|
+
--collectionBrowserCellMinWidth,
|
|
2563
|
+
17rem
|
|
2564
|
+
);
|
|
2565
|
+
--infiniteScrollerCellMaxWidth: var(
|
|
2566
|
+
--collectionBrowserCellMaxWidth,
|
|
2567
|
+
1fr
|
|
2568
|
+
);
|
|
2569
|
+
}
|
|
2570
|
+
|
|
2571
|
+
/* Allow tiles to shrink a bit further at smaller viewport widths */
|
|
2572
|
+
@media screen and (max-width: 880px) {
|
|
2573
|
+
infinite-scroller.grid {
|
|
2574
|
+
--infiniteScrollerCellMinWidth: var(
|
|
2575
|
+
--collectionBrowserCellMinWidth,
|
|
2576
|
+
15rem
|
|
2577
|
+
);
|
|
2578
|
+
}
|
|
2579
|
+
}
|
|
2580
|
+
/* At very small widths, maintain a 2-tile layout as far as it can reasonably go */
|
|
2581
|
+
@media screen and (max-width: 360px) {
|
|
2582
|
+
infinite-scroller.grid {
|
|
2583
|
+
--infiniteScrollerCellMinWidth: var(
|
|
2584
|
+
--collectionBrowserCellMinWidth,
|
|
2585
|
+
12rem
|
|
2586
|
+
);
|
|
2587
|
+
}
|
|
2588
|
+
}
|
|
2589
|
+
|
|
2590
|
+
infinite-scroller.hidden {
|
|
2591
|
+
display: none;
|
|
2592
|
+
}
|
|
2581
2593
|
`,
|
|
2582
2594
|
];
|
|
2583
2595
|
}
|
|
@@ -2726,6 +2738,12 @@ __decorate([
|
|
|
2726
2738
|
__decorate([
|
|
2727
2739
|
property({ type: Boolean })
|
|
2728
2740
|
], CollectionBrowser.prototype, "isManageView", void 0);
|
|
2741
|
+
__decorate([
|
|
2742
|
+
property({ type: Array })
|
|
2743
|
+
], CollectionBrowser.prototype, "tileActions", void 0);
|
|
2744
|
+
__decorate([
|
|
2745
|
+
property({ type: String })
|
|
2746
|
+
], CollectionBrowser.prototype, "tileLayoutType", void 0);
|
|
2729
2747
|
__decorate([
|
|
2730
2748
|
property({ type: String })
|
|
2731
2749
|
], CollectionBrowser.prototype, "manageViewLabel", void 0);
|