@internetarchive/collection-browser 4.8.0 → 4.8.1-webdev-9227.1

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.
Files changed (381) hide show
  1. package/README.md +33 -0
  2. package/dist/src/collection-browser.d.ts +2 -1
  3. package/dist/src/collection-browser.js +3 -3
  4. package/dist/src/collection-browser.js.map +1 -1
  5. package/dist/src/collection-facets/more-facets-content.js +3 -2
  6. package/dist/src/collection-facets/more-facets-content.js.map +1 -1
  7. package/dist/src/collection-facets/more-facets-scroller.js +3 -2
  8. package/dist/src/collection-facets/more-facets-scroller.js.map +1 -1
  9. package/dist/src/collection-facets.js +3 -2
  10. package/dist/src/collection-facets.js.map +1 -1
  11. package/dist/src/empty-placeholder.d.ts +7 -7
  12. package/dist/src/empty-placeholder.js +29 -15
  13. package/dist/src/empty-placeholder.js.map +1 -1
  14. package/dist/src/expanded-date-picker.js +3 -2
  15. package/dist/src/expanded-date-picker.js.map +1 -1
  16. package/dist/src/locales/es.d.ts +94 -0
  17. package/dist/src/locales/es.js +109 -0
  18. package/dist/src/locales/es.js.map +1 -0
  19. package/dist/src/manage/manage-bar.d.ts +3 -2
  20. package/dist/src/manage/manage-bar.js +6 -7
  21. package/dist/src/manage/manage-bar.js.map +1 -1
  22. package/dist/src/manage/remove-items-modal-content.js +3 -2
  23. package/dist/src/manage/remove-items-modal-content.js.map +1 -1
  24. package/dist/src/models.js +6 -2
  25. package/dist/src/models.js.map +1 -1
  26. package/dist/src/sort-filter-bar/sort-filter-bar.js +3 -2
  27. package/dist/src/sort-filter-bar/sort-filter-bar.js.map +1 -1
  28. package/dist/src/tiles/grid/account-tile.js +3 -2
  29. package/dist/src/tiles/grid/account-tile.js.map +1 -1
  30. package/dist/src/tiles/grid/collection-tile.js +3 -2
  31. package/dist/src/tiles/grid/collection-tile.js.map +1 -1
  32. package/dist/src/tiles/grid/item-tile.js +3 -2
  33. package/dist/src/tiles/grid/item-tile.js.map +1 -1
  34. package/dist/src/tiles/grid/tile-stats.js +3 -2
  35. package/dist/src/tiles/grid/tile-stats.js.map +1 -1
  36. package/dist/src/tiles/list/tile-list-compact-header.js +3 -2
  37. package/dist/src/tiles/list/tile-list-compact-header.js.map +1 -1
  38. package/dist/src/tiles/list/tile-list-compact.js +3 -1
  39. package/dist/src/tiles/list/tile-list-compact.js.map +1 -1
  40. package/dist/src/tiles/list/tile-list.js +3 -2
  41. package/dist/src/tiles/list/tile-list.js.map +1 -1
  42. package/dist/src/tiles/overlay/text-overlay.js +3 -1
  43. package/dist/src/tiles/overlay/text-overlay.js.map +1 -1
  44. package/dist/src/tiles/review-block.js +3 -2
  45. package/dist/src/tiles/review-block.js.map +1 -1
  46. package/dist/src/tiles/tile-dispatcher.d.ts +2 -1
  47. package/dist/src/tiles/tile-dispatcher.js +5 -4
  48. package/dist/src/tiles/tile-dispatcher.js.map +1 -1
  49. package/locales/es.d.ts +1 -0
  50. package/locales/es.js +1 -0
  51. package/package.json +13 -1
  52. package/.editorconfig +0 -29
  53. package/.github/workflows/ci.yml +0 -29
  54. package/.github/workflows/gh-pages-main.yml +0 -41
  55. package/.github/workflows/npm-publish.yml +0 -42
  56. package/.github/workflows/pr-preview.yml +0 -40
  57. package/.husky/pre-commit +0 -1
  58. package/.prettierignore +0 -1
  59. package/dist/test/collection-browser.test.d.ts +0 -1
  60. package/dist/test/collection-browser.test.js +0 -1815
  61. package/dist/test/collection-browser.test.js.map +0 -1
  62. package/dist/test/collection-facets/facet-row.test.d.ts +0 -1
  63. package/dist/test/collection-facets/facet-row.test.js +0 -291
  64. package/dist/test/collection-facets/facet-row.test.js.map +0 -1
  65. package/dist/test/collection-facets/facets-template.test.d.ts +0 -1
  66. package/dist/test/collection-facets/facets-template.test.js +0 -95
  67. package/dist/test/collection-facets/facets-template.test.js.map +0 -1
  68. package/dist/test/collection-facets/more-facets-content.test.d.ts +0 -1
  69. package/dist/test/collection-facets/more-facets-content.test.js +0 -509
  70. package/dist/test/collection-facets/more-facets-content.test.js.map +0 -1
  71. package/dist/test/collection-facets/more-facets-scroller.test.d.ts +0 -1
  72. package/dist/test/collection-facets/more-facets-scroller.test.js +0 -288
  73. package/dist/test/collection-facets/more-facets-scroller.test.js.map +0 -1
  74. package/dist/test/collection-facets/page-window.test.d.ts +0 -1
  75. package/dist/test/collection-facets/page-window.test.js +0 -175
  76. package/dist/test/collection-facets/page-window.test.js.map +0 -1
  77. package/dist/test/collection-facets/toggle-switch.test.d.ts +0 -1
  78. package/dist/test/collection-facets/toggle-switch.test.js +0 -99
  79. package/dist/test/collection-facets/toggle-switch.test.js.map +0 -1
  80. package/dist/test/collection-facets.test.d.ts +0 -2
  81. package/dist/test/collection-facets.test.js +0 -728
  82. package/dist/test/collection-facets.test.js.map +0 -1
  83. package/dist/test/data-source/collection-browser-data-source.test.d.ts +0 -1
  84. package/dist/test/data-source/collection-browser-data-source.test.js +0 -154
  85. package/dist/test/data-source/collection-browser-data-source.test.js.map +0 -1
  86. package/dist/test/empty-placeholder.test.d.ts +0 -1
  87. package/dist/test/empty-placeholder.test.js +0 -57
  88. package/dist/test/empty-placeholder.test.js.map +0 -1
  89. package/dist/test/expanded-date-picker.test.d.ts +0 -1
  90. package/dist/test/expanded-date-picker.test.js +0 -124
  91. package/dist/test/expanded-date-picker.test.js.map +0 -1
  92. package/dist/test/icon-overlay.test.d.ts +0 -1
  93. package/dist/test/icon-overlay.test.js +0 -31
  94. package/dist/test/icon-overlay.test.js.map +0 -1
  95. package/dist/test/image-block.test.d.ts +0 -1
  96. package/dist/test/image-block.test.js +0 -208
  97. package/dist/test/image-block.test.js.map +0 -1
  98. package/dist/test/item-image.test.d.ts +0 -1
  99. package/dist/test/item-image.test.js +0 -187
  100. package/dist/test/item-image.test.js.map +0 -1
  101. package/dist/test/manage/manage-bar.test.d.ts +0 -3
  102. package/dist/test/manage/manage-bar.test.js +0 -216
  103. package/dist/test/manage/manage-bar.test.js.map +0 -1
  104. package/dist/test/manage/remove-items-modal-content.test.d.ts +0 -1
  105. package/dist/test/manage/remove-items-modal-content.test.js +0 -60
  106. package/dist/test/manage/remove-items-modal-content.test.js.map +0 -1
  107. package/dist/test/mediatype-config.test.d.ts +0 -1
  108. package/dist/test/mediatype-config.test.js +0 -11
  109. package/dist/test/mediatype-config.test.js.map +0 -1
  110. package/dist/test/mocks/mock-analytics-handler.d.ts +0 -10
  111. package/dist/test/mocks/mock-analytics-handler.js +0 -16
  112. package/dist/test/mocks/mock-analytics-handler.js.map +0 -1
  113. package/dist/test/mocks/mock-search-responses.d.ts +0 -37
  114. package/dist/test/mocks/mock-search-responses.js +0 -1293
  115. package/dist/test/mocks/mock-search-responses.js.map +0 -1
  116. package/dist/test/mocks/mock-search-service.d.ts +0 -16
  117. package/dist/test/mocks/mock-search-service.js +0 -65
  118. package/dist/test/mocks/mock-search-service.js.map +0 -1
  119. package/dist/test/restoration-state-handler.test.d.ts +0 -1
  120. package/dist/test/restoration-state-handler.test.js +0 -335
  121. package/dist/test/restoration-state-handler.test.js.map +0 -1
  122. package/dist/test/review-block.test.d.ts +0 -1
  123. package/dist/test/review-block.test.js +0 -46
  124. package/dist/test/review-block.test.js.map +0 -1
  125. package/dist/test/sort-filter-bar/alpha-bar-tooltip.test.d.ts +0 -1
  126. package/dist/test/sort-filter-bar/alpha-bar-tooltip.test.js +0 -12
  127. package/dist/test/sort-filter-bar/alpha-bar-tooltip.test.js.map +0 -1
  128. package/dist/test/sort-filter-bar/alpha-bar.test.d.ts +0 -1
  129. package/dist/test/sort-filter-bar/alpha-bar.test.js +0 -68
  130. package/dist/test/sort-filter-bar/alpha-bar.test.js.map +0 -1
  131. package/dist/test/sort-filter-bar/sort-filter-bar.test.d.ts +0 -1
  132. package/dist/test/sort-filter-bar/sort-filter-bar.test.js +0 -304
  133. package/dist/test/sort-filter-bar/sort-filter-bar.test.js.map +0 -1
  134. package/dist/test/text-overlay.test.d.ts +0 -1
  135. package/dist/test/text-overlay.test.js +0 -43
  136. package/dist/test/text-overlay.test.js.map +0 -1
  137. package/dist/test/text-snippet-block.test.d.ts +0 -1
  138. package/dist/test/text-snippet-block.test.js +0 -58
  139. package/dist/test/text-snippet-block.test.js.map +0 -1
  140. package/dist/test/tile-stats.test.d.ts +0 -1
  141. package/dist/test/tile-stats.test.js +0 -167
  142. package/dist/test/tile-stats.test.js.map +0 -1
  143. package/dist/test/tiles/grid/account-tile.test.d.ts +0 -1
  144. package/dist/test/tiles/grid/account-tile.test.js +0 -96
  145. package/dist/test/tiles/grid/account-tile.test.js.map +0 -1
  146. package/dist/test/tiles/grid/collection-tile.test.d.ts +0 -1
  147. package/dist/test/tiles/grid/collection-tile.test.js +0 -90
  148. package/dist/test/tiles/grid/collection-tile.test.js.map +0 -1
  149. package/dist/test/tiles/grid/item-tile.test.d.ts +0 -1
  150. package/dist/test/tiles/grid/item-tile.test.js +0 -400
  151. package/dist/test/tiles/grid/item-tile.test.js.map +0 -1
  152. package/dist/test/tiles/grid/search-tile.test.d.ts +0 -1
  153. package/dist/test/tiles/grid/search-tile.test.js +0 -62
  154. package/dist/test/tiles/grid/search-tile.test.js.map +0 -1
  155. package/dist/test/tiles/hover/hover-pane-controller.test.d.ts +0 -1
  156. package/dist/test/tiles/hover/hover-pane-controller.test.js +0 -351
  157. package/dist/test/tiles/hover/hover-pane-controller.test.js.map +0 -1
  158. package/dist/test/tiles/hover/tile-hover-pane.test.d.ts +0 -1
  159. package/dist/test/tiles/hover/tile-hover-pane.test.js +0 -53
  160. package/dist/test/tiles/hover/tile-hover-pane.test.js.map +0 -1
  161. package/dist/test/tiles/list/tile-list-compact-header.test.d.ts +0 -1
  162. package/dist/test/tiles/list/tile-list-compact-header.test.js +0 -36
  163. package/dist/test/tiles/list/tile-list-compact-header.test.js.map +0 -1
  164. package/dist/test/tiles/list/tile-list-compact.test.d.ts +0 -1
  165. package/dist/test/tiles/list/tile-list-compact.test.js +0 -237
  166. package/dist/test/tiles/list/tile-list-compact.test.js.map +0 -1
  167. package/dist/test/tiles/list/tile-list.test.d.ts +0 -1
  168. package/dist/test/tiles/list/tile-list.test.js +0 -460
  169. package/dist/test/tiles/list/tile-list.test.js.map +0 -1
  170. package/dist/test/tiles/tile-dispatcher.test.d.ts +0 -1
  171. package/dist/test/tiles/tile-dispatcher.test.js +0 -246
  172. package/dist/test/tiles/tile-dispatcher.test.js.map +0 -1
  173. package/dist/test/tiles/tile-display-value-provider.test.d.ts +0 -1
  174. package/dist/test/tiles/tile-display-value-provider.test.js +0 -142
  175. package/dist/test/tiles/tile-display-value-provider.test.js.map +0 -1
  176. package/dist/test/tiles/tile-mediatype-icon.test.d.ts +0 -1
  177. package/dist/test/tiles/tile-mediatype-icon.test.js +0 -133
  178. package/dist/test/tiles/tile-mediatype-icon.test.js.map +0 -1
  179. package/dist/test/utils/array-equals.test.d.ts +0 -1
  180. package/dist/test/utils/array-equals.test.js +0 -27
  181. package/dist/test/utils/array-equals.test.js.map +0 -1
  182. package/dist/test/utils/format-count.test.d.ts +0 -1
  183. package/dist/test/utils/format-count.test.js +0 -24
  184. package/dist/test/utils/format-count.test.js.map +0 -1
  185. package/dist/test/utils/format-date.test.d.ts +0 -1
  186. package/dist/test/utils/format-date.test.js +0 -61
  187. package/dist/test/utils/format-date.test.js.map +0 -1
  188. package/dist/test/utils/format-unit-size.test.d.ts +0 -1
  189. package/dist/test/utils/format-unit-size.test.js +0 -18
  190. package/dist/test/utils/format-unit-size.test.js.map +0 -1
  191. package/dist/test/utils/local-date-from-utc.test.d.ts +0 -1
  192. package/dist/test/utils/local-date-from-utc.test.js +0 -27
  193. package/dist/test/utils/local-date-from-utc.test.js.map +0 -1
  194. package/dist/test/utils/normalize-filter-text.test.d.ts +0 -1
  195. package/dist/test/utils/normalize-filter-text.test.js +0 -69
  196. package/dist/test/utils/normalize-filter-text.test.js.map +0 -1
  197. package/docs/design/column-virtualization.md +0 -214
  198. package/eslint.config.mjs +0 -53
  199. package/index.html +0 -24
  200. package/index.ts +0 -29
  201. package/local.archive.org.cert +0 -86
  202. package/local.archive.org.key +0 -27
  203. package/pnpm-workspace.yaml +0 -30
  204. package/renovate.json +0 -6
  205. package/src/app-root.ts +0 -1282
  206. package/src/assets/img/icons/arrow-left.ts +0 -10
  207. package/src/assets/img/icons/arrow-right.ts +0 -10
  208. package/src/assets/img/icons/check.ts +0 -5
  209. package/src/assets/img/icons/chevron.ts +0 -4
  210. package/src/assets/img/icons/close-circle-dark.ts +0 -5
  211. package/src/assets/img/icons/contract.ts +0 -9
  212. package/src/assets/img/icons/empty-query.ts +0 -5
  213. package/src/assets/img/icons/expand.ts +0 -9
  214. package/src/assets/img/icons/eye-closed.ts +0 -5
  215. package/src/assets/img/icons/eye.ts +0 -5
  216. package/src/assets/img/icons/favorite-filled.ts +0 -10
  217. package/src/assets/img/icons/favorite-unfilled.ts +0 -9
  218. package/src/assets/img/icons/filter.ts +0 -10
  219. package/src/assets/img/icons/login-required.ts +0 -18
  220. package/src/assets/img/icons/mediatype/account.ts +0 -14
  221. package/src/assets/img/icons/mediatype/audio.ts +0 -14
  222. package/src/assets/img/icons/mediatype/collection.ts +0 -12
  223. package/src/assets/img/icons/mediatype/data.ts +0 -15
  224. package/src/assets/img/icons/mediatype/etree.ts +0 -14
  225. package/src/assets/img/icons/mediatype/film.ts +0 -14
  226. package/src/assets/img/icons/mediatype/images.ts +0 -13
  227. package/src/assets/img/icons/mediatype/radio.ts +0 -15
  228. package/src/assets/img/icons/mediatype/search.ts +0 -14
  229. package/src/assets/img/icons/mediatype/software.ts +0 -13
  230. package/src/assets/img/icons/mediatype/texts.ts +0 -13
  231. package/src/assets/img/icons/mediatype/tv-commercial.ts +0 -12
  232. package/src/assets/img/icons/mediatype/tv-fact-check.ts +0 -12
  233. package/src/assets/img/icons/mediatype/tv-quote.ts +0 -12
  234. package/src/assets/img/icons/mediatype/tv.ts +0 -14
  235. package/src/assets/img/icons/mediatype/video.ts +0 -14
  236. package/src/assets/img/icons/mediatype/web.ts +0 -13
  237. package/src/assets/img/icons/null-result.ts +0 -5
  238. package/src/assets/img/icons/quote.ts +0 -7
  239. package/src/assets/img/icons/restricted.ts +0 -13
  240. package/src/assets/img/icons/reviews.ts +0 -11
  241. package/src/assets/img/icons/upload.ts +0 -12
  242. package/src/assets/img/icons/views.ts +0 -11
  243. package/src/circular-activity-indicator.ts +0 -64
  244. package/src/collection-browser.ts +0 -3165
  245. package/src/collection-facets/facet-row-template.ts +0 -242
  246. package/src/collection-facets/facet-row.ts +0 -122
  247. package/src/collection-facets/facet-tombstone-row.ts +0 -40
  248. package/src/collection-facets/facets-template.ts +0 -85
  249. package/src/collection-facets/models.ts +0 -16
  250. package/src/collection-facets/more-facets-content.ts +0 -951
  251. package/src/collection-facets/more-facets-scroller.ts +0 -485
  252. package/src/collection-facets/page-window.ts +0 -247
  253. package/src/collection-facets/smart-facets/dedupe.ts +0 -44
  254. package/src/collection-facets/smart-facets/heuristics/browser-language/browser-language-heuristic.ts +0 -27
  255. package/src/collection-facets/smart-facets/heuristics/index.ts +0 -3
  256. package/src/collection-facets/smart-facets/heuristics/query-keywords/query-keywords-heuristic.ts +0 -17
  257. package/src/collection-facets/smart-facets/heuristics/query-keywords/query-keywords-map.ts +0 -70
  258. package/src/collection-facets/smart-facets/heuristics/wikidata/wikidata-entity-map.ts +0 -79
  259. package/src/collection-facets/smart-facets/heuristics/wikidata/wikidata-heuristic.ts +0 -93
  260. package/src/collection-facets/smart-facets/models.ts +0 -36
  261. package/src/collection-facets/smart-facets/smart-facet-bar.ts +0 -437
  262. package/src/collection-facets/smart-facets/smart-facet-button.ts +0 -145
  263. package/src/collection-facets/smart-facets/smart-facet-dropdown.ts +0 -185
  264. package/src/collection-facets/smart-facets/smart-facet-equals.ts +0 -16
  265. package/src/collection-facets/smart-facets/smart-facet-heuristics.ts +0 -26
  266. package/src/collection-facets/toggle-switch.ts +0 -175
  267. package/src/collection-facets.ts +0 -1013
  268. package/src/data-source/collection-browser-data-source-interface.ts +0 -351
  269. package/src/data-source/collection-browser-data-source.ts +0 -1474
  270. package/src/data-source/collection-browser-query-state.ts +0 -60
  271. package/src/data-source/models.ts +0 -56
  272. package/src/empty-placeholder.ts +0 -192
  273. package/src/expanded-date-picker.ts +0 -191
  274. package/src/language-code-handler/language-code-handler.ts +0 -64
  275. package/src/language-code-handler/language-code-mapping.ts +0 -564
  276. package/src/manage/manage-bar.ts +0 -276
  277. package/src/manage/remove-items-modal-content.ts +0 -102
  278. package/src/mediatype/mediatype-config.ts +0 -146
  279. package/src/models.ts +0 -912
  280. package/src/restoration-state-handler.ts +0 -550
  281. package/src/sort-filter-bar/alpha-bar-tooltip.ts +0 -53
  282. package/src/sort-filter-bar/alpha-bar.ts +0 -252
  283. package/src/sort-filter-bar/img/compact.ts +0 -5
  284. package/src/sort-filter-bar/img/list.ts +0 -5
  285. package/src/sort-filter-bar/img/sort-toggle-disabled.ts +0 -15
  286. package/src/sort-filter-bar/img/sort-toggle-down.ts +0 -17
  287. package/src/sort-filter-bar/img/sort-toggle-up.ts +0 -17
  288. package/src/sort-filter-bar/img/sort-triangle.ts +0 -5
  289. package/src/sort-filter-bar/img/tile.ts +0 -5
  290. package/src/sort-filter-bar/sort-filter-bar.ts +0 -733
  291. package/src/styles/ia-button.ts +0 -139
  292. package/src/styles/item-image-styles.ts +0 -124
  293. package/src/styles/sr-only.ts +0 -18
  294. package/src/styles/tile-action-styles.ts +0 -59
  295. package/src/tiles/base-tile-component.ts +0 -124
  296. package/src/tiles/collection-browser-loading-tile.ts +0 -26
  297. package/src/tiles/grid/account-tile.ts +0 -113
  298. package/src/tiles/grid/collection-tile.ts +0 -184
  299. package/src/tiles/grid/item-tile.ts +0 -347
  300. package/src/tiles/grid/search-tile.ts +0 -90
  301. package/src/tiles/grid/styles/tile-grid-shared-styles.ts +0 -130
  302. package/src/tiles/grid/tile-stats.ts +0 -211
  303. package/src/tiles/hover/hover-pane-controller.ts +0 -638
  304. package/src/tiles/hover/tile-hover-pane.ts +0 -184
  305. package/src/tiles/image-block.ts +0 -162
  306. package/src/tiles/item-image.ts +0 -214
  307. package/src/tiles/list/tile-list-compact-header.ts +0 -112
  308. package/src/tiles/list/tile-list-compact.ts +0 -278
  309. package/src/tiles/list/tile-list.ts +0 -718
  310. package/src/tiles/models.ts +0 -21
  311. package/src/tiles/overlay/icon-overlay.ts +0 -57
  312. package/src/tiles/overlay/text-overlay.ts +0 -79
  313. package/src/tiles/review-block.ts +0 -130
  314. package/src/tiles/text-snippet-block.ts +0 -132
  315. package/src/tiles/tile-dispatcher.ts +0 -637
  316. package/src/tiles/tile-display-value-provider.ts +0 -133
  317. package/src/tiles/tile-mediatype-icon.ts +0 -133
  318. package/src/utils/analytics-events.ts +0 -29
  319. package/src/utils/array-equals.ts +0 -8
  320. package/src/utils/collapse-repeated-quotes.ts +0 -13
  321. package/src/utils/date-filter-field.ts +0 -11
  322. package/src/utils/facet-utils.ts +0 -183
  323. package/src/utils/format-count.ts +0 -95
  324. package/src/utils/format-date.ts +0 -62
  325. package/src/utils/format-unit-size.ts +0 -43
  326. package/src/utils/local-date-from-utc.ts +0 -15
  327. package/src/utils/log.ts +0 -14
  328. package/src/utils/normalize-filter-text.ts +0 -54
  329. package/src/utils/resolve-mediatype.ts +0 -26
  330. package/src/utils/sha1.ts +0 -9
  331. package/test/collection-browser.test.ts +0 -2639
  332. package/test/collection-facets/facet-row.test.ts +0 -421
  333. package/test/collection-facets/facets-template.test.ts +0 -139
  334. package/test/collection-facets/more-facets-content.test.ts +0 -716
  335. package/test/collection-facets/more-facets-scroller.test.ts +0 -401
  336. package/test/collection-facets/page-window.test.ts +0 -208
  337. package/test/collection-facets/toggle-switch.test.ts +0 -164
  338. package/test/collection-facets.test.ts +0 -928
  339. package/test/data-source/collection-browser-data-source.test.ts +0 -193
  340. package/test/empty-placeholder.test.ts +0 -88
  341. package/test/expanded-date-picker.test.ts +0 -201
  342. package/test/icon-overlay.test.ts +0 -38
  343. package/test/image-block.test.ts +0 -247
  344. package/test/item-image.test.ts +0 -220
  345. package/test/manage/manage-bar.test.ts +0 -347
  346. package/test/manage/remove-items-modal-content.test.ts +0 -81
  347. package/test/mediatype-config.test.ts +0 -11
  348. package/test/mocks/mock-analytics-handler.ts +0 -30
  349. package/test/mocks/mock-search-responses.ts +0 -1420
  350. package/test/mocks/mock-search-service.ts +0 -136
  351. package/test/restoration-state-handler.test.ts +0 -480
  352. package/test/review-block.test.ts +0 -62
  353. package/test/sort-filter-bar/alpha-bar-tooltip.test.ts +0 -17
  354. package/test/sort-filter-bar/alpha-bar.test.ts +0 -101
  355. package/test/sort-filter-bar/sort-filter-bar.test.ts +0 -443
  356. package/test/text-overlay.test.ts +0 -55
  357. package/test/text-snippet-block.test.ts +0 -85
  358. package/test/tile-stats.test.ts +0 -191
  359. package/test/tiles/grid/account-tile.test.ts +0 -121
  360. package/test/tiles/grid/collection-tile.test.ts +0 -114
  361. package/test/tiles/grid/item-tile.test.ts +0 -520
  362. package/test/tiles/grid/search-tile.test.ts +0 -75
  363. package/test/tiles/hover/hover-pane-controller.test.ts +0 -482
  364. package/test/tiles/hover/tile-hover-pane.test.ts +0 -80
  365. package/test/tiles/list/tile-list-compact-header.test.ts +0 -43
  366. package/test/tiles/list/tile-list-compact.test.ts +0 -282
  367. package/test/tiles/list/tile-list.test.ts +0 -576
  368. package/test/tiles/tile-dispatcher.test.ts +0 -320
  369. package/test/tiles/tile-display-value-provider.test.ts +0 -172
  370. package/test/tiles/tile-mediatype-icon.test.ts +0 -160
  371. package/test/utils/array-equals.test.ts +0 -31
  372. package/test/utils/format-count.test.ts +0 -32
  373. package/test/utils/format-date.test.ts +0 -89
  374. package/test/utils/format-unit-size.test.ts +0 -21
  375. package/test/utils/local-date-from-utc.test.ts +0 -37
  376. package/test/utils/normalize-filter-text.test.ts +0 -87
  377. package/tsconfig.json +0 -25
  378. package/types/dompurify.d.ts +0 -1
  379. package/vite.config.ts +0 -29
  380. package/web-dev-server.config.mjs +0 -30
  381. package/web-test-runner.config.mjs +0 -57
@@ -1,733 +0,0 @@
1
- import {
2
- LitElement,
3
- html,
4
- css,
5
- nothing,
6
- PropertyValues,
7
- TemplateResult,
8
- } from 'lit';
9
- import { customElement, property, query, state } from 'lit/decorators.js';
10
- import { msg, str } from '@lit/localize';
11
- import type { IaDropdown, optionInterface } from '@internetarchive/ia-dropdown';
12
- import type { SortDirection } from '@internetarchive/search-service';
13
- import {
14
- CollectionDisplayMode,
15
- defaultSortAvailability,
16
- PrefixFilterCounts,
17
- PrefixFilterType,
18
- SORT_OPTIONS,
19
- SortField,
20
- SortOption,
21
- } from '../models';
22
-
23
- import { sortUpIcon } from './img/sort-toggle-up';
24
- import { sortDownIcon } from './img/sort-toggle-down';
25
- import { sortDisabledIcon } from './img/sort-toggle-disabled';
26
- import { tileIcon } from './img/tile';
27
- import { listIcon } from './img/list';
28
- import { compactIcon } from './img/compact';
29
- import { srOnlyStyle } from '../styles/sr-only';
30
-
31
- import '@internetarchive/ia-dropdown';
32
- import './alpha-bar';
33
-
34
- type AlphaSelector = 'creator' | 'title';
35
-
36
- @customElement('sort-filter-bar')
37
- export class SortFilterBar extends LitElement {
38
- /** Which display mode the tiles are being rendered with (grid/list-detail/list-compact) */
39
- @property({ type: String }) displayMode?: CollectionDisplayMode;
40
-
41
- /** The default sort direction to use if none is set */
42
- @property({ type: String }) defaultSortDirection: SortDirection | null = null;
43
-
44
- /** The default sort field to use if none is set */
45
- @property({ type: String }) defaultSortField: Exclude<
46
- SortField,
47
- SortField.default
48
- > = SortField.relevance;
49
-
50
- /** The current sort direction (asc/desc), or null if none is set */
51
- @property({ type: String }) sortDirection: SortDirection | null = null;
52
-
53
- /** The field currently being sorted on (e.g., 'title'). Defaults to relevance. */
54
- @property({ type: String }) selectedSort: SortField = SortField.default;
55
-
56
- /** The currently selected title letter filter, or null if none is set */
57
- @property({ type: String }) selectedTitleFilter: string | null = null;
58
-
59
- /** The currently selected creator letter filter, or null if none is set */
60
- @property({ type: String }) selectedCreatorFilter: string | null = null;
61
-
62
- /**
63
- * Map defining which sortable fields should be included on the sort bar.
64
- *
65
- * E.g.,
66
- * ```
67
- * {
68
- * [SortField.relevance]: true,
69
- * [SortField.date]: false,
70
- * [SortField.title]: true,
71
- * ...
72
- * }
73
- * ```
74
- */
75
- @property({ type: Object }) sortFieldAvailability = defaultSortAvailability;
76
-
77
- /** Whether to replace the default sort options with a slot for customization (default `false`) */
78
- @property({ type: Boolean, reflect: true }) enableSortOptionsSlot: boolean =
79
- false;
80
-
81
- /** Whether to suppress showing the three display mode options on the right of the bar (default `false`) */
82
- @property({ type: Boolean, reflect: true })
83
- suppressDisplayModes: boolean = false;
84
-
85
- /** Maps of result counts for letters on the alphabet bar, for each letter filter type */
86
- @property({ type: Object }) prefixFilterCountMap?: Record<
87
- PrefixFilterType,
88
- PrefixFilterCounts
89
- >;
90
-
91
- /**
92
- * Which of the alphabet bars (title/creator) should be shown, or null if one
93
- * should not currently be rendered.
94
- */
95
- @state() alphaSelectorVisible: AlphaSelector | null = null;
96
-
97
- /**
98
- * Whether the transparent backdrop to catch clicks outside the dropdown menu
99
- * should be rendered.
100
- */
101
- @state() dropdownBackdropVisible = false;
102
-
103
- /** The single, consolidated dropdown component containing all available options */
104
- @query('#sort-dropdown')
105
- private sortOptionsDropdown!: IaDropdown;
106
-
107
- render() {
108
- return html`
109
- <div id="container">
110
- <section id="sort-bar" aria-label="Sorting options">
111
- <slot name="sort-options-left"></slot>
112
- <div id="sort-options">
113
- ${!this.enableSortOptionsSlot
114
- ? html`
115
- <div class="sort-direction-container">
116
- ${this.sortDirectionSelectorTemplate}
117
- </div>
118
- <span class="sort-by-text">${msg('Sort by:')}</span>
119
- <div id="sort-selector-container">
120
- ${this.sortSelectorTemplate}
121
- </div>
122
- `
123
- : html`<slot name="sort-options"></slot>`}
124
- </div>
125
- <slot name="sort-options-right"></slot>
126
-
127
- ${this.suppressDisplayModes
128
- ? nothing
129
- : html`<div id="display-style-selector">
130
- ${this.displayOptionTemplate}
131
- </div>`}
132
- </section>
133
-
134
- ${this.dropdownBackdropVisible ? this.dropdownBackdrop : nothing}
135
- ${this.alphaBarTemplate}
136
- </div>
137
- `;
138
- }
139
-
140
- willUpdate(changed: PropertyValues) {
141
- if (changed.has('selectedSort') || changed.has('defaultSortField')) {
142
- // If the sort is changed from its default without a direction set,
143
- // we adopt the default sort direction for that sort type.
144
- if (
145
- this.selectedSort &&
146
- this.selectedSort !== SortField.default &&
147
- this.sortDirection === null
148
- ) {
149
- const sortOption = SORT_OPTIONS[this.finalizedSortField];
150
- this.sortDirection = sortOption.defaultSortDirection;
151
- }
152
- }
153
- }
154
-
155
- updated(changed: PropertyValues) {
156
- if (changed.has('displayMode')) {
157
- this.displayModeChanged();
158
- }
159
-
160
- if (changed.has('selectedTitleFilter') && this.selectedTitleFilter) {
161
- this.alphaSelectorVisible = 'title';
162
- }
163
-
164
- if (changed.has('selectedCreatorFilter') && this.selectedCreatorFilter) {
165
- this.alphaSelectorVisible = 'creator';
166
- }
167
-
168
- if (changed.has('dropdownBackdropVisible')) {
169
- this.setupEscapeListeners();
170
- }
171
- }
172
-
173
- private setupEscapeListeners() {
174
- if (this.dropdownBackdropVisible) {
175
- document.addEventListener(
176
- 'keydown',
177
- this.boundSortBarSelectorEscapeListener,
178
- );
179
- } else {
180
- document.removeEventListener(
181
- 'keydown',
182
- this.boundSortBarSelectorEscapeListener,
183
- );
184
- }
185
- }
186
-
187
- private boundSortBarSelectorEscapeListener = (e: KeyboardEvent) => {
188
- if (e.key === 'Escape') {
189
- this.closeDropdown();
190
- }
191
- };
192
-
193
- /**
194
- * Template to render the alphabet bar, or `nothing` if it should not be rendered
195
- * for the current sort
196
- */
197
- private get alphaBarTemplate(): TemplateResult | typeof nothing {
198
- if (!['title', 'creator'].includes(this.selectedSort)) return nothing;
199
-
200
- if (this.alphaSelectorVisible === null) {
201
- if (this.selectedSort === 'creator') return this.creatorSelectorBar;
202
- if (this.selectedSort === 'title') return this.titleSelectorBar;
203
- } else {
204
- return this.alphaSelectorVisible === 'creator'
205
- ? this.creatorSelectorBar
206
- : this.titleSelectorBar;
207
- }
208
-
209
- return nothing;
210
- }
211
-
212
- /** Template to render the sort direction toggle button */
213
- private get sortDirectionSelectorTemplate(): TemplateResult {
214
- const oppositeSortDirectionReadable =
215
- this.sortDirection === 'asc' ? msg('descending') : msg('ascending');
216
- const buttonLabel = this.canChangeSortDirection
217
- ? msg(str`Change to ${oppositeSortDirectionReadable} sort`)
218
- : msg('Directions are not available for the current sort option');
219
-
220
- return html`
221
- <button
222
- class="sort-direction-selector"
223
- title=${buttonLabel}
224
- ?disabled=${!this.canChangeSortDirection}
225
- @click=${this.handleSortDirectionClicked}
226
- >
227
- <span class="sr-only">${buttonLabel}</span>
228
- ${this.sortDirectionIcon}
229
- </button>
230
- `;
231
- }
232
-
233
- /** Template to render the sort direction button's icon in the correct current state */
234
- private get sortDirectionIcon(): TemplateResult {
235
- // Show a fully disabled icon for sort options without direction support
236
- if (!this.canChangeSortDirection) {
237
- return html`<div class="sort-direction-icon">${sortDisabledIcon}</div>`;
238
- }
239
-
240
- // For all other sorts, show the ascending/descending direction
241
- return html`
242
- <div class="sort-direction-icon">
243
- ${this.finalizedSortDirection === 'asc' ? sortUpIcon : sortDownIcon}
244
- </div>
245
- `;
246
- }
247
-
248
- /** The template to render all the sort options in a single dropdown */
249
- private get sortSelectorTemplate() {
250
- const displayedOptions = Object.values(SORT_OPTIONS).filter(
251
- opt => opt.shownInSortBar && this.sortFieldAvailability[opt.field],
252
- );
253
-
254
- return html`
255
- <div id="sort-dropdown-container">
256
- ${this.getSortDropdown({
257
- displayName: SORT_OPTIONS[this.finalizedSortField].displayName,
258
- id: 'sort-dropdown',
259
- selected: true,
260
- dropdownOptions: displayedOptions.map(opt =>
261
- this.getDropdownOption(opt.field),
262
- ),
263
- selectedOption: this.finalizedSortField,
264
- onOptionSelected: this.sortOptionSelected,
265
- onDropdownClick: () => {
266
- this.dropdownBackdropVisible = this.sortOptionsDropdown.open;
267
- this.sortOptionsDropdown.classList.toggle(
268
- 'open',
269
- this.sortOptionsDropdown.open,
270
- );
271
- },
272
- })}
273
- </div>
274
- `;
275
- }
276
-
277
- /**
278
- * Generates a dropdown component containing multiple grouped sort options.
279
- *
280
- * @param options.displayName The name to use for the dropdown's visible label
281
- * @param options.id The id to apply to the dropdown element
282
- * @param options.dropdownOptions An array of option objects used to populate the dropdown
283
- * @param options.selectedOption The id of the option that should be initially selected
284
- * @param options.selected A boolean indicating whether this dropdown should use its
285
- * selected appearance
286
- * @param options.onOptionSelected A handler for optionSelected events coming from the dropdown
287
- * @param options.onDropdownClick A handler for click events on the dropdown
288
- */
289
- private getSortDropdown(options: {
290
- displayName: string;
291
- id: string;
292
- dropdownOptions: optionInterface[];
293
- selectedOption?: string;
294
- selected: boolean;
295
- onOptionSelected?: (e: CustomEvent<{ option: optionInterface }>) => void;
296
- onDropdownClick?: (e: PointerEvent) => void;
297
- }): TemplateResult {
298
- return html`
299
- <ia-dropdown
300
- id=${options.id}
301
- class=${options.selected ? 'selected' : ''}
302
- displayCaret
303
- closeOnSelect
304
- includeSelectedOption
305
- .openViaButton=${options.selected}
306
- .options=${options.dropdownOptions}
307
- .selectedOption=${options.selectedOption ?? ''}
308
- @optionSelected=${options.onOptionSelected ?? nothing}
309
- @click=${options.onDropdownClick ?? nothing}
310
- >
311
- <span
312
- class="dropdown-label"
313
- slot="dropdown-label"
314
- data-title=${options.displayName}
315
- >
316
- ${options.displayName}
317
- </span>
318
- </ia-dropdown>
319
- `;
320
- }
321
-
322
- /** Generates a single dropdown option object for the given sort field */
323
- private getDropdownOption(sortField: SortField): optionInterface {
324
- return {
325
- id: sortField,
326
- label: html`
327
- <span class="dropdown-option-label">
328
- ${SORT_OPTIONS[sortField].displayName}
329
- </span>
330
- `,
331
- };
332
- }
333
-
334
- /** Handler for when a new sort dropdown option is selected */
335
- private sortOptionSelected(e: CustomEvent<{ option: optionInterface }>) {
336
- this.dropdownBackdropVisible = false;
337
-
338
- const sortField = e.detail.option.id as SortField;
339
- this.setSelectedSort(sortField);
340
-
341
- this.alphaSelectorVisible = null;
342
- if (sortField !== 'title' && this.selectedTitleFilter) {
343
- this.selectedTitleFilter = null;
344
- this.emitTitleLetterChangedEvent();
345
- }
346
- if (sortField !== 'creator' && this.selectedCreatorFilter) {
347
- this.selectedCreatorFilter = null;
348
- this.emitCreatorLetterChangedEvent();
349
- }
350
- }
351
-
352
- /** Template for rendering the three display mode options */
353
- /** Added data-testid for Playwright testing * */
354
- private get displayOptionTemplate() {
355
- return html`
356
- <ul>
357
- <li>
358
- <button
359
- id="grid-button"
360
- @click=${() => {
361
- this.displayMode = 'grid';
362
- }}
363
- class=${this.displayMode === 'grid' ? 'active' : ''}
364
- title="Tile view"
365
- data-testid="grid-button"
366
- >
367
- ${tileIcon}
368
- </button>
369
- </li>
370
- <li>
371
- <button
372
- id="list-detail-button"
373
- @click=${() => {
374
- this.displayMode = 'list-detail';
375
- }}
376
- class=${this.displayMode === 'list-detail' ? 'active' : ''}
377
- title="List view"
378
- data-testid="list-detail-button"
379
- >
380
- ${listIcon}
381
- </button>
382
- </li>
383
- <li>
384
- <button
385
- id="list-compact-button"
386
- @click=${() => {
387
- this.displayMode = 'list-compact';
388
- }}
389
- class=${this.displayMode === 'list-compact' ? 'active' : ''}
390
- title="Compact list view"
391
- data-testid="list-compact-button"
392
- >
393
- ${compactIcon}
394
- </button>
395
- </li>
396
- </ul>
397
- `;
398
- }
399
-
400
- /**
401
- * Template for rendering the transparent backdrop to capture clicks outside the
402
- * dropdown menu while it is open.
403
- */
404
- private get dropdownBackdrop() {
405
- return html`
406
- <div
407
- id="sort-selector-backdrop"
408
- @keyup=${this.closeDropdown}
409
- @click=${this.closeDropdown}
410
- ></div>
411
- `;
412
- }
413
-
414
- /** Closes the sorting dropdown component's menus */
415
- private closeDropdown() {
416
- this.dropdownBackdropVisible = false;
417
-
418
- if (!this.sortOptionsDropdown) return;
419
- this.sortOptionsDropdown.open = false;
420
- this.sortOptionsDropdown.classList.remove('open');
421
- }
422
-
423
- setSortDirection(sortDirection: SortDirection) {
424
- this.sortDirection = sortDirection;
425
- this.emitSortChangedEvent();
426
- }
427
-
428
- /** Toggles the current sort direction between 'asc' and 'desc' */
429
- private toggleSortDirection() {
430
- this.setSortDirection(
431
- this.finalizedSortDirection === 'desc' ? 'asc' : 'desc',
432
- );
433
- }
434
-
435
- private handleSortDirectionClicked(): void {
436
- if (
437
- !this.sortDirection &&
438
- this.defaultSortField &&
439
- this.defaultSortDirection
440
- ) {
441
- // When the sort direction is merely defaulted (not set by the user), clicking
442
- // the toggled button should "promote" the default sort to an explicitly-set one
443
- // and then toggle it as usual.
444
- this.selectedSort = this.defaultSortField;
445
- this.sortDirection = this.defaultSortDirection;
446
- }
447
-
448
- this.toggleSortDirection();
449
- }
450
-
451
- setSelectedSort(sort: SortField) {
452
- this.selectedSort = sort;
453
- // Apply this field's default sort direction
454
- const sortOption = SORT_OPTIONS[sort];
455
- this.sortDirection = sortOption.defaultSortDirection;
456
- this.emitSortChangedEvent();
457
- }
458
-
459
- /** The current sort field, or the default one if no explicit sort is set */
460
- private get finalizedSortField(): SortField {
461
- const resolvedField =
462
- this.selectedSort === SortField.default
463
- ? this.defaultSortField
464
- : this.selectedSort;
465
- if (this.sortFieldAvailability[resolvedField]) return resolvedField;
466
-
467
- // Fall back to the first available sort option shown in the sort bar, if
468
- // the requested one isn't available
469
- return this.firstAvailableOption?.field ?? resolvedField;
470
- }
471
-
472
- /** The current sort direction, or the default one if no explicit direction is set */
473
- private get finalizedSortDirection(): SortDirection | null {
474
- return this.sortDirection === null
475
- ? this.defaultSortDirection
476
- : this.sortDirection;
477
- }
478
-
479
- /** The first option shown in the sort dropdown, or undefined if none are available */
480
- private get firstAvailableOption(): SortOption | undefined {
481
- return Object.values(SORT_OPTIONS).find(
482
- opt => opt.shownInSortBar && this.sortFieldAvailability[opt.field],
483
- );
484
- }
485
-
486
- /** Whether the sort direction button should be enabled for the current sort */
487
- private get canChangeSortDirection(): boolean {
488
- return SORT_OPTIONS[this.finalizedSortField].canSetDirection;
489
- }
490
-
491
- private get titleSelectorBar() {
492
- return html` <alpha-bar
493
- .selectedLetter=${this.selectedTitleFilter}
494
- .letterCounts=${this.prefixFilterCountMap?.title}
495
- ariaLandmarkLabel="Filter by title letter"
496
- @letterChanged=${this.titleLetterChanged}
497
- ></alpha-bar>`;
498
- }
499
-
500
- private get creatorSelectorBar() {
501
- return html` <alpha-bar
502
- .selectedLetter=${this.selectedCreatorFilter}
503
- .letterCounts=${this.prefixFilterCountMap?.creator}
504
- ariaLandmarkLabel="Filter by creator letter"
505
- @letterChanged=${this.creatorLetterChanged}
506
- ></alpha-bar>`;
507
- }
508
-
509
- private titleLetterChanged(
510
- e: CustomEvent<{ selectedLetter: string | undefined }>,
511
- ) {
512
- this.selectedTitleFilter = e.detail.selectedLetter ?? null;
513
- this.emitTitleLetterChangedEvent();
514
- }
515
-
516
- private creatorLetterChanged(
517
- e: CustomEvent<{ selectedLetter: string | undefined }>,
518
- ) {
519
- this.selectedCreatorFilter = e.detail.selectedLetter ?? null;
520
- this.emitCreatorLetterChangedEvent();
521
- }
522
-
523
- private emitTitleLetterChangedEvent() {
524
- const event = new CustomEvent<{ selectedLetter: string | null }>(
525
- 'titleLetterChanged',
526
- {
527
- detail: { selectedLetter: this.selectedTitleFilter },
528
- },
529
- );
530
- this.dispatchEvent(event);
531
- }
532
-
533
- private emitCreatorLetterChangedEvent() {
534
- const event = new CustomEvent<{ selectedLetter: string | null }>(
535
- 'creatorLetterChanged',
536
- {
537
- detail: { selectedLetter: this.selectedCreatorFilter },
538
- },
539
- );
540
- this.dispatchEvent(event);
541
- }
542
-
543
- private displayModeChanged() {
544
- const event = new CustomEvent<{
545
- displayMode?: CollectionDisplayMode;
546
- }>('displayModeChanged', {
547
- detail: { displayMode: this.displayMode },
548
- });
549
- this.dispatchEvent(event);
550
- }
551
-
552
- private emitSortChangedEvent() {
553
- const event = new CustomEvent<{
554
- selectedSort: SortField;
555
- sortDirection: SortDirection | null;
556
- }>('sortChanged', {
557
- detail: {
558
- selectedSort: this.selectedSort,
559
- sortDirection: this.sortDirection,
560
- },
561
- });
562
- this.dispatchEvent(event);
563
- }
564
-
565
- static get styles() {
566
- const disabledIconColor = css`#bbbbbb`;
567
-
568
- return [
569
- srOnlyStyle,
570
- css`
571
- #container {
572
- position: relative;
573
- }
574
-
575
- #sort-bar {
576
- display: flex;
577
- justify-content: flex-start;
578
- align-items: center;
579
- padding-bottom: 1px;
580
- border-bottom: 1px solid #2c2c2c;
581
- font-size: 1.4rem;
582
- }
583
-
584
- #sort-options {
585
- display: flex;
586
- align-items: center;
587
- flex-grow: 1;
588
- }
589
-
590
- ul {
591
- list-style: none;
592
- display: flex;
593
- align-items: center;
594
- margin: 0;
595
- padding: 0;
596
- }
597
-
598
- li {
599
- padding: 0;
600
- }
601
-
602
- .sort-by-text {
603
- margin-right: 5px;
604
- font-weight: bold;
605
- white-space: nowrap;
606
- }
607
-
608
- .sort-direction-container {
609
- display: flex;
610
- align-self: stretch;
611
- flex: 0;
612
- margin: 0 3px;
613
- }
614
-
615
- .sort-direction-selector {
616
- display: flex;
617
- justify-content: center;
618
- width: 30px;
619
- margin: 0 5px 0 0;
620
- padding: 7px 8px;
621
- max-height: fit-content;
622
- border-radius: 5px;
623
- background: white;
624
- border: 1px solid rgb(25, 72, 128);
625
- appearance: none;
626
- cursor: pointer;
627
- }
628
-
629
- .sort-direction-selector:disabled {
630
- cursor: not-allowed;
631
- border-color: ${disabledIconColor};
632
- }
633
-
634
- .sort-direction-icon {
635
- display: flex;
636
- align-items: center;
637
- background: none;
638
- color: inherit;
639
- border: none;
640
- padding: 0;
641
- outline: inherit;
642
- width: 12px;
643
- height: 12px;
644
- }
645
-
646
- .sort-direction-icon > svg {
647
- flex: 1;
648
- }
649
-
650
- #sort-selector-container {
651
- flex: 1;
652
- display: flex;
653
- justify-content: flex-start;
654
- align-items: center;
655
- }
656
-
657
- #sort-dropdown-container {
658
- display: flex;
659
- justify-content: flex-start;
660
- align-items: center;
661
- }
662
-
663
- #sort-selector-backdrop {
664
- position: fixed;
665
- top: 0;
666
- left: 0;
667
- width: 100vw;
668
- height: 100vh;
669
- z-index: 1;
670
- background-color: transparent;
671
- }
672
-
673
- #display-style-selector {
674
- flex: 0;
675
- }
676
-
677
- #display-style-selector button {
678
- background: none;
679
- color: inherit;
680
- border: none;
681
- appearance: none;
682
- cursor: pointer;
683
- -webkit-appearance: none;
684
- fill: ${disabledIconColor};
685
- }
686
-
687
- #display-style-selector button.active {
688
- fill: var(--ia-theme-primary-text-color, #2c2c2c);
689
- }
690
-
691
- #display-style-selector button svg {
692
- width: 24px;
693
- height: 24px;
694
- }
695
-
696
- ia-dropdown {
697
- --dropdownTextColor: white;
698
- --dropdownOffsetTop: 0;
699
- --dropdownBorderTopWidth: 0;
700
- --dropdownBorderTopLeftRadius: 0;
701
- --dropdownBorderTopRightRadius: 0;
702
- --dropdownWhiteSpace: nowrap;
703
- --dropdownListZIndex: 2;
704
- --dropdownCaretColor: var(--ia-theme-primary-text-color, #2c2c2c);
705
- --dropdownSelectedTextColor: white;
706
- --dropdownSelectedBgColor: rgba(255, 255, 255, 0.3);
707
- --dropdownHoverBgColor: rgba(255, 255, 255, 0.3);
708
- --caretHeight: 9px;
709
- --caretWidth: 12px;
710
- --caretPadding: 0 5px 0 0;
711
- }
712
- ia-dropdown.selected .dropdown-label {
713
- font-weight: bold;
714
- }
715
- ia-dropdown.open {
716
- z-index: 2;
717
- }
718
-
719
- .dropdown-label {
720
- display: inline-block;
721
- height: 100%;
722
- padding-left: 5px;
723
- font-size: 1.4rem;
724
- font-family: var(--ia-theme-base-font-family);
725
- line-height: 2;
726
- color: var(--ia-theme-primary-text-color, #2c2c2c);
727
- white-space: nowrap;
728
- user-select: none;
729
- }
730
- `,
731
- ];
732
- }
733
- }