blacklight 8.8.0 → 9.0.0.beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.env +3 -3
- data/.github/pull_request_template.md +7 -0
- data/.github/workflows/ruby.yml +16 -19
- data/.rubocop.yml +2 -2
- data/.rubocop_todo.yml +0 -9
- data/README.md +30 -8
- data/VERSION +1 -1
- data/app/assets/builds/blacklight.css +448 -0
- data/app/assets/javascripts/blacklight/blacklight.esm.js +19 -16
- data/app/assets/javascripts/blacklight/blacklight.esm.js.map +1 -1
- data/app/assets/javascripts/blacklight/blacklight.js +19 -16
- data/app/assets/javascripts/blacklight/blacklight.js.map +1 -1
- data/app/assets/stylesheets/blacklight/_balanced_list.scss +1 -4
- data/app/assets/stylesheets/blacklight/_blacklight_base.scss +1 -3
- data/app/assets/stylesheets/blacklight/_bookmark.scss +44 -41
- data/app/assets/stylesheets/blacklight/_bootstrap_overrides.scss +7 -26
- data/app/assets/stylesheets/blacklight/_constraints.scss +15 -24
- data/app/assets/stylesheets/blacklight/_controls.scss +2 -18
- data/app/assets/stylesheets/blacklight/_facets.scss +15 -82
- data/app/assets/stylesheets/blacklight/_group.scss +2 -5
- data/app/assets/stylesheets/blacklight/_header.scss +4 -11
- data/app/assets/stylesheets/blacklight/_icons.scss +0 -8
- data/app/assets/stylesheets/blacklight/_modal.scss +2 -2
- data/app/assets/stylesheets/blacklight/_pagination.scss +0 -4
- data/app/assets/stylesheets/blacklight/_search_form.scss +7 -1
- data/app/assets/stylesheets/blacklight/_search_history.scss +0 -4
- data/app/assets/stylesheets/blacklight/_search_results.scss +1 -15
- data/app/assets/stylesheets/blacklight/blacklight_defaults.scss +9 -14
- data/app/assets/stylesheets/blacklight/build.scss +4 -0
- data/app/components/blacklight/advanced_search_form_component.rb +1 -1
- data/app/components/blacklight/constraint_component.rb +1 -1
- data/app/components/blacklight/constraint_layout_component.html.erb +2 -2
- data/app/components/blacklight/constraints_component.html.erb +2 -2
- data/app/components/blacklight/constraints_component.rb +1 -1
- data/app/components/blacklight/document/bookmark_component.html.erb +3 -3
- data/app/components/blacklight/document/group_component.html.erb +1 -1
- data/app/components/blacklight/document/page_header_component.rb +1 -1
- data/app/components/blacklight/document/sidebar_component.rb +5 -5
- data/app/components/blacklight/document_component.rb +9 -13
- data/app/components/blacklight/document_title_component.rb +3 -2
- data/app/components/blacklight/facet_field_component.html.erb +4 -4
- data/app/components/blacklight/facet_field_list_component.rb +4 -22
- data/app/components/blacklight/facet_field_pagination_component.html.erb +4 -4
- data/app/components/blacklight/facet_field_pagination_component.rb +2 -1
- data/app/components/blacklight/facet_item_component.rb +2 -2
- data/app/components/blacklight/facet_item_pivot_component.rb +2 -2
- data/app/components/blacklight/response/facet_group_component.html.erb +3 -18
- data/app/components/blacklight/response/facet_group_component.rb +7 -23
- data/app/components/blacklight/response/facet_toggle_button_component.html.erb +16 -0
- data/app/components/blacklight/response/facet_toggle_button_component.rb +14 -0
- data/app/components/blacklight/response/pagination_component.html.erb +1 -1
- data/app/components/blacklight/response/pagination_component.rb +2 -1
- data/app/components/blacklight/response/sort_component.rb +1 -0
- data/app/components/blacklight/response/view_type_button_component.html.erb +1 -1
- data/app/components/blacklight/response/view_type_component.html.erb +1 -1
- data/app/components/blacklight/search/facet_suggest_input.html.erb +7 -7
- data/app/components/blacklight/search/facet_suggest_input.rb +0 -4
- data/app/components/blacklight/search/per_page_component.html.erb +1 -1
- data/app/components/blacklight/search/per_page_component.rb +1 -0
- data/app/components/blacklight/search/sidebar_component.html.erb +1 -1
- data/app/components/blacklight/search/sidebar_component.rb +1 -1
- data/app/components/blacklight/search_bar_component.html.erb +3 -3
- data/app/components/blacklight/search_bar_component.rb +2 -2
- data/app/components/blacklight/search_button_component.rb +2 -2
- data/app/components/blacklight/search_context/server_applied_params_component.html.erb +2 -2
- data/app/components/blacklight/search_context/server_applied_params_component.rb +9 -0
- data/app/components/blacklight/skip_link_component.html.erb +1 -1
- data/app/components/blacklight/skip_link_component.rb +7 -3
- data/app/components/blacklight/skip_link_item_component.rb +18 -0
- data/app/components/blacklight/top_navbar_component.html.erb +1 -1
- data/app/controllers/concerns/blacklight/catalog.rb +3 -2
- data/app/controllers/concerns/blacklight/search_context.rb +0 -12
- data/app/helpers/blacklight/blacklight_helper_behavior.rb +0 -6
- data/app/helpers/blacklight/catalog_helper_behavior.rb +6 -12
- data/app/helpers/blacklight/configuration_helper_behavior.rb +0 -12
- data/app/helpers/blacklight/document_helper_behavior.rb +0 -26
- data/app/helpers/blacklight/icon_helper_behavior.rb +1 -9
- data/app/helpers/blacklight/layout_helper_behavior.rb +2 -2
- data/app/helpers/blacklight/render_partials_helper_behavior.rb +0 -14
- data/app/helpers/blacklight/url_helper_behavior.rb +1 -1
- data/app/javascript/{blacklight → blacklight-frontend}/bookmark_toggle.js +1 -1
- data/app/javascript/{blacklight → blacklight-frontend}/core.js +2 -10
- data/app/javascript/{blacklight → blacklight-frontend}/debounce.js +1 -1
- data/app/javascript/{blacklight → blacklight-frontend}/facet_suggest.js +4 -4
- data/app/javascript/blacklight-frontend/index.js +18 -0
- data/app/javascript/{blacklight → blacklight-frontend}/modal.js +16 -2
- data/app/models/blacklight/facet_paginator.rb +1 -1
- data/app/models/concerns/blacklight/document.rb +0 -11
- data/app/models/concerns/blacklight/user.rb +1 -1
- data/app/presenters/blacklight/facet_field_presenter.rb +2 -2
- data/app/services/blacklight/search_params_yaml_coder.rb +0 -2
- data/app/views/bookmarks/_clear_bookmarks_widget.html.erb +0 -2
- data/app/views/bookmarks/index.html.erb +1 -1
- data/app/views/catalog/_results_pagination.html.erb +2 -5
- data/app/views/catalog/_search_results.html.erb +4 -4
- data/app/views/catalog/_search_results_header.html.erb +1 -1
- data/app/views/catalog/_sort_and_per_page.html.erb +1 -1
- data/app/views/catalog/_sort_widget.html.erb +1 -0
- data/app/views/catalog/facet.html.erb +1 -1
- data/app/views/catalog/show.html.erb +2 -3
- data/app/views/kaminari/blacklight/_paginator.html.erb +1 -2
- data/app/views/layouts/blacklight/base.html.erb +3 -7
- data/app/views/search_history/index.html.erb +0 -2
- data/blacklight.gemspec +4 -4
- data/compose.yaml +1 -0
- data/config/importmap.rb +1 -1
- data/config/locales/blacklight.ar.yml +4 -4
- data/config/locales/blacklight.ca.yml +124 -124
- data/config/locales/blacklight.de.yml +2 -2
- data/config/locales/blacklight.en.yml +14 -14
- data/config/locales/blacklight.es.yml +4 -4
- data/config/locales/blacklight.fr.yml +4 -4
- data/config/locales/blacklight.hu.yml +4 -4
- data/config/locales/blacklight.it.yml +3 -3
- data/config/locales/blacklight.nl.yml +3 -3
- data/config/locales/blacklight.pt-BR.yml +3 -3
- data/config/locales/blacklight.sq.yml +4 -4
- data/config/locales/blacklight.zh.yml +4 -4
- data/lib/blacklight/configuration/display_field.rb +1 -1
- data/lib/blacklight/configuration/fields.rb +3 -3
- data/lib/blacklight/configuration/view_config.rb +0 -2
- data/lib/blacklight/configuration.rb +7 -12
- data/lib/blacklight/engine.rb +0 -6
- data/lib/blacklight/open_struct_with_hash_access.rb +4 -4
- data/lib/blacklight/search_builder.rb +4 -4
- data/lib/blacklight/solr/request.rb +1 -7
- data/lib/blacklight/solr/response/group_response.rb +2 -2
- data/lib/blacklight.rb +1 -1
- data/lib/generators/blacklight/assets/importmap_generator.rb +8 -24
- data/lib/generators/blacklight/assets/propshaft_generator.rb +1 -1
- data/lib/generators/blacklight/assets_generator.rb +3 -3
- data/lib/generators/blacklight/controller_generator.rb +3 -3
- data/lib/generators/blacklight/templates/solr/conf/solrconfig.xml +1 -1
- data/lib/generators/blacklight/user_generator.rb +9 -10
- data/package.json +14 -4
- data/rollup.config.js +1 -1
- data/spec/components/blacklight/document/action_component_spec.rb +1 -5
- data/spec/components/blacklight/document/sidebar_component_spec.rb +5 -20
- data/spec/components/blacklight/facet_field_checkboxes_component_spec.rb +2 -2
- data/spec/components/blacklight/facet_field_list_component_spec.rb +2 -2
- data/spec/components/blacklight/search/facet_suggest_input_spec.rb +2 -18
- data/spec/components/blacklight/search_bar_component_spec.rb +1 -1
- data/spec/features/axe_spec.rb +6 -11
- data/spec/features/bookmarks_spec.rb +48 -11
- data/spec/features/facets_spec.rb +25 -14
- data/spec/features/search_context_spec.rb +1 -2
- data/spec/features/search_filters_spec.rb +6 -6
- data/spec/helpers/blacklight/configuration_helper_behavior_spec.rb +0 -9
- data/spec/helpers/blacklight/render_partials_helper_behavior_spec.rb +1 -1
- data/spec/helpers/catalog_helper_spec.rb +8 -0
- data/spec/models/blacklight/solr/request_spec.rb +7 -0
- data/spec/test_app_templates/Gemfile.extra +0 -1
- data/spec/views/catalog/_facet_layout.html.erb_spec.rb +3 -3
- data/spec/views/catalog/index.html.erb_spec.rb +6 -3
- data/spec/views/catalog/show.html.erb_spec.rb +1 -0
- data/tasks/blacklight.rake +8 -5
- metadata +30 -57
- data/app/assets/stylesheets/blacklight/_autocomplete.scss +0 -25
- data/app/assets/stylesheets/blacklight/_mixins.scss +0 -20
- data/app/components/blacklight/icons/legacy_icon_component.rb +0 -30
- data/app/javascript/blacklight/index.js +0 -18
- data/app/views/catalog/_constraints.html.erb +0 -1
- data/app/views/catalog/_facets.html.erb +0 -5
- data/app/views/catalog/_search_form.html.erb +0 -7
- data/app/views/catalog/_search_header.html.erb +0 -1
- data/app/views/catalog/_show_sidebar.html.erb +0 -3
- data/app/views/catalog/_show_tools.html.erb +0 -2
- data/app/views/catalog/_start_over.html.erb +0 -1
- data/app/views/shared/_header_navbar.html.erb +0 -1
- data/lib/generators/blacklight/assets/sprockets_generator.rb +0 -68
- data/spec/views/catalog/_search_header.erb_spec.rb +0 -14
- data/spec/views/catalog/_show_sidebar.erb_spec.rb +0 -24
- data/spec/views/catalog/_show_tools.html.erb_spec.rb +0 -37
- /data/app/javascript/{blacklight → blacklight-frontend}/button_focus.js +0 -0
- /data/app/javascript/{blacklight → blacklight-frontend}/checkbox_submit.js +0 -0
- /data/app/javascript/{blacklight → blacklight-frontend}/modalForm.js +0 -0
- /data/app/javascript/{blacklight → blacklight-frontend}/search_context.js +0 -0
@@ -1,50 +1,53 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
min-width: 8.5em;
|
4
|
-
}
|
5
|
-
|
6
|
-
div.toggle-bookmark {
|
7
|
-
cursor: pointer;
|
8
|
-
}
|
1
|
+
.bookmark-toggle {
|
2
|
+
--bl-icon-color: var(--bs-primary);
|
9
3
|
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
}
|
4
|
+
.no-js & {
|
5
|
+
input[type="submit"] {
|
6
|
+
display: inline;
|
7
|
+
}
|
15
8
|
|
16
|
-
.bookmark
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
}
|
21
|
-
|
22
|
-
div.toggle-bookmark {
|
23
|
-
display: none
|
24
|
-
}
|
25
|
-
}
|
26
|
-
|
27
|
-
input[type="submit"] {
|
28
|
-
display: none;
|
29
|
-
}
|
30
|
-
}
|
31
|
-
.toggle-bookmark .blacklight-icons svg {
|
32
|
-
height: 1.25rem;
|
33
|
-
width: 1.25rem;
|
34
|
-
overflow: visible;
|
35
|
-
fill: var(--bs-primary);
|
9
|
+
.toggle-bookmark {
|
10
|
+
display: none;
|
11
|
+
}
|
12
|
+
}
|
36
13
|
|
37
|
-
|
14
|
+
input[type="submit"] {
|
38
15
|
display: none;
|
39
16
|
}
|
40
|
-
}
|
41
17
|
|
42
|
-
.toggle-bookmark
|
43
|
-
|
44
|
-
|
18
|
+
.toggle-bookmark {
|
19
|
+
cursor: pointer;
|
20
|
+
|
21
|
+
.toggle-bookmark-label {
|
22
|
+
font-weight: inherit;
|
23
|
+
min-width: 8.5em;
|
24
|
+
|
25
|
+
.blacklight-icons svg {
|
26
|
+
height: 1.25rem;
|
27
|
+
width: 1.25rem;
|
28
|
+
overflow: visible;
|
29
|
+
fill: var(--bl-icon-color);
|
30
|
+
|
31
|
+
&.bookmark-checked {
|
32
|
+
display: none;
|
33
|
+
}
|
34
|
+
}
|
35
|
+
}
|
36
|
+
|
37
|
+
.toggle-bookmark-input:checked + span svg {
|
38
|
+
&.bookmark-checked {
|
39
|
+
display: inherit;
|
40
|
+
}
|
41
|
+
|
42
|
+
&.bookmark-unchecked {
|
43
|
+
display: none;
|
44
|
+
}
|
45
|
+
}
|
45
46
|
}
|
46
47
|
|
47
|
-
|
48
|
-
|
48
|
+
/* override for line 21.
|
49
|
+
Creates weird spacing in toolbar when min-width is set to 8rem */
|
50
|
+
.header-tools .toggle-bookmark-label {
|
51
|
+
min-width: 2rem;
|
49
52
|
}
|
50
|
-
}
|
53
|
+
}
|
@@ -1,36 +1,17 @@
|
|
1
|
-
// Facet field headings and buttons
|
2
|
-
.facet-field-heading {
|
3
|
-
--bl-facet-field-heading-font-weight: #{$headings-font-weight};
|
4
|
-
border-bottom: 0;
|
5
|
-
|
6
|
-
button {
|
7
|
-
font-weight: var(--bl-facet-field-heading-font-weight);
|
8
|
-
|
9
|
-
&::after {
|
10
|
-
content: "❯";
|
11
|
-
float: right;
|
12
|
-
transform: rotate(90deg);
|
13
|
-
}
|
14
|
-
|
15
|
-
&.collapsed {
|
16
|
-
border-bottom: 0;
|
17
|
-
|
18
|
-
&::after {
|
19
|
-
transform: rotate(0deg);
|
20
|
-
transition: transform 0.1s ease;
|
21
|
-
}
|
22
|
-
}
|
23
|
-
}
|
24
|
-
}
|
25
|
-
|
26
1
|
.page-link {
|
27
2
|
white-space: nowrap;
|
28
3
|
}
|
29
4
|
|
30
|
-
|
5
|
+
// Blacklight's decision to try to use bootstrap modal CSS with an html5 dialog --
|
6
|
+
// in such a way the <dialog> element actually serves as the modal backdrop --
|
7
|
+
// requires some fixes to both bootstrap CSS and user-agent default css
|
8
|
+
dialog.modal[open] {
|
31
9
|
// override bootstrap .modal class default display: none
|
32
10
|
// since we aren't using bootstrap JS that sets and unsets the display
|
33
11
|
display: block;
|
34
12
|
background: none;
|
35
13
|
border: none;
|
14
|
+
|
15
|
+
max-height: unset; // override user-agent dialog
|
16
|
+
max-width: unset; // override user-agent dialog
|
36
17
|
}
|
@@ -1,41 +1,32 @@
|
|
1
1
|
.constraints-container {
|
2
|
-
@extend .mb-2;
|
3
2
|
display: flex;
|
4
3
|
flex-wrap: wrap;
|
5
4
|
gap: 0.5rem 0.25rem;
|
6
5
|
}
|
7
6
|
|
8
7
|
.applied-filter {
|
9
|
-
|
8
|
+
--separator-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='currentColor'%3e%3cpath fill-rule='evenodd' d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e");
|
10
9
|
|
11
10
|
.constraint-value {
|
12
11
|
cursor: default;
|
13
12
|
text-overflow: ellipsis;
|
14
13
|
overflow: hidden;
|
15
14
|
white-space: nowrap;
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
15
|
+
max-width: clamp(288px, calc(30vw), 500px);
|
16
|
+
|
17
|
+
.filter-name:after {
|
18
|
+
background-color: var(--bs-btn-color);
|
19
|
+
content: "";
|
20
|
+
mask: var(--separator-icon);
|
21
|
+
mask-repeat: no-repeat;
|
22
|
+
display: inline-block;
|
23
|
+
height: 1.1rem;
|
24
|
+
width: 1.25rem;
|
25
|
+
vertical-align: text-bottom;
|
26
|
+
margin-right: -0.2rem;
|
27
|
+
margin-left: 0.25rem;
|
28
|
+
transition: background-color 0.15s ease-in-out;
|
27
29
|
}
|
28
|
-
|
29
|
-
@media (min-width: breakpoint-min(lg)) {
|
30
|
-
max-width: breakpoint-min(lg) * 0.5;
|
31
|
-
}
|
32
|
-
}
|
33
|
-
|
34
|
-
.filter-name:after {
|
35
|
-
color: $gray-500;
|
36
|
-
content: "❯";
|
37
|
-
font-size: 90%;
|
38
|
-
padding-left: $caret-width;
|
39
30
|
}
|
40
31
|
|
41
32
|
.remove {
|
@@ -1,21 +1,10 @@
|
|
1
1
|
.search-widgets {
|
2
2
|
display: flex;
|
3
|
-
|
4
|
-
> * {
|
5
|
-
@extend .mx-1;
|
6
|
-
}
|
7
3
|
}
|
8
4
|
|
9
5
|
.sort-pagination,
|
10
6
|
.pagination-search-widgets {
|
11
|
-
border-bottom:
|
12
|
-
margin-bottom: 1em;
|
13
|
-
padding-bottom: 1em;
|
14
|
-
}
|
15
|
-
|
16
|
-
.pagination-search-widgets {
|
17
|
-
padding-top: 1px;
|
18
|
-
padding-bottom: $spacer;
|
7
|
+
border-bottom: var(--bs-border-width) solid var(--bs-border-color);
|
19
8
|
}
|
20
9
|
|
21
10
|
.sort-pagination .dropdown-toggle {
|
@@ -25,18 +14,13 @@
|
|
25
14
|
.no-js {
|
26
15
|
.btn-group:focus-within {
|
27
16
|
.dropdown-menu {
|
28
|
-
|
17
|
+
display: block; /* show menu when tabbing to it, without Javascript */
|
29
18
|
}
|
30
19
|
}
|
31
20
|
}
|
32
21
|
|
33
22
|
.view-type {
|
34
23
|
display: inline-block;
|
35
|
-
|
36
|
-
.caption {
|
37
|
-
@extend .sr-only !optional;
|
38
|
-
@extend .visually-hidden !optional;
|
39
|
-
}
|
40
24
|
}
|
41
25
|
|
42
26
|
.modal_form {
|
@@ -1,18 +1,11 @@
|
|
1
1
|
.sidenav {
|
2
|
-
--bl-facet-active-bg:
|
3
|
-
--bl-facet-active-item-color:
|
4
|
-
--bl-facet-margin-bottom: #{$spacer};
|
2
|
+
--bl-facet-active-bg: var(--bs-success);
|
3
|
+
--bl-facet-active-item-color: var(--bs-success);
|
5
4
|
--bl-facet-remove-color: var(--bs-secondary-color);
|
5
|
+
--bl-facet-remove-hover-color: var(--bs-danger);
|
6
6
|
--bl-facet-label-indent: -15px;
|
7
7
|
--bl-facet-label-padding-left: 15px;
|
8
|
-
|
9
|
-
--bl-facet-limit-body-padding: #{$spacer};
|
10
|
-
|
11
|
-
--bl-facets-smallish-padding: 0.25rem;
|
12
|
-
--bl-facets-smallish-border: var(--bs-border-width) solid
|
13
|
-
var(--bs-border-color);
|
14
|
-
--bl-facets-smallish-margin-bottom: #{$spacer};
|
15
|
-
--bl-facets-smallish-border-radius: #{$border-radius};
|
8
|
+
--bl-facet-header-padding-y: 0.5rem;
|
16
9
|
|
17
10
|
.facet-toggle-button {
|
18
11
|
[data-hide-label] {
|
@@ -33,34 +26,6 @@
|
|
33
26
|
}
|
34
27
|
}
|
35
28
|
|
36
|
-
.facets-toggleable {
|
37
|
-
@each $breakpoint in map-keys($grid-breakpoints) {
|
38
|
-
$next: breakpoint-next($breakpoint, $grid-breakpoints);
|
39
|
-
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
40
|
-
|
41
|
-
&#{$infix} {
|
42
|
-
@include media-breakpoint-down($next) {
|
43
|
-
border: var(--bl-facets-smallish-border);
|
44
|
-
padding: var(--bl-facets-smallish-padding);
|
45
|
-
margin-bottom: var(--bl-facets-smallish-margin-bottom);
|
46
|
-
border-radius: var(--bl-facets-smallish-border-radius);
|
47
|
-
}
|
48
|
-
@include media-breakpoint-up($next) {
|
49
|
-
// scss-lint:disable ImportantRule
|
50
|
-
.facets-collapse {
|
51
|
-
display: block !important;
|
52
|
-
width: 100%;
|
53
|
-
}
|
54
|
-
// scss-lint:enable ImportantRule
|
55
|
-
|
56
|
-
.navbar-toggler {
|
57
|
-
display: none;
|
58
|
-
}
|
59
|
-
}
|
60
|
-
}
|
61
|
-
}
|
62
|
-
}
|
63
|
-
|
64
29
|
.no-js {
|
65
30
|
@include media-breakpoint-down(lg) {
|
66
31
|
#sidebar {
|
@@ -88,49 +53,25 @@
|
|
88
53
|
.facets-header {
|
89
54
|
display: flex;
|
90
55
|
justify-content: space-between;
|
91
|
-
padding-
|
92
|
-
padding-top: 0.5rem;
|
56
|
+
padding-block: var(--bl-facet-header-padding-y);
|
93
57
|
}
|
94
58
|
|
95
59
|
.facets-heading {
|
96
|
-
@extend .h4;
|
97
60
|
line-height: inherit;
|
98
61
|
}
|
99
62
|
|
100
63
|
.facet-limit {
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
padding: var(--bl-facet-limit-body-padding);
|
105
|
-
}
|
106
|
-
|
107
|
-
/* Provide a focus ring on the expand/collapse button */
|
108
|
-
.btn {
|
109
|
-
--bs-btn-focus-shadow-rgb: 50, 50, 50;
|
110
|
-
&:focus-visible {
|
111
|
-
border-color: var(--bs-btn-hover-border-color);
|
112
|
-
outline: 0;
|
113
|
-
box-shadow: var(--bs-btn-focus-box-shadow);
|
114
|
-
}
|
115
|
-
}
|
64
|
+
--bs-accordion-btn-bg: var(--bs-gray-100);
|
65
|
+
--bs-btn-hover-bg: var(--bs-gray-200);
|
66
|
+
--bs-accordion-active-bg: var(--bs-accordion-btn-bg);
|
116
67
|
}
|
117
68
|
|
118
69
|
.facet-limit-active {
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
.btn {
|
125
|
-
@if function-exists(color-contrast) {
|
126
|
-
color: color-contrast($facet-active-bg);
|
127
|
-
}
|
128
|
-
|
129
|
-
@if function-exists(color-yiq) {
|
130
|
-
color: color-yiq($facet-active-bg);
|
131
|
-
}
|
132
|
-
}
|
133
|
-
}
|
70
|
+
--bs-accordion-btn-bg: var(--bl-facet-active-bg);
|
71
|
+
--bs-btn-hover-bg: var(--bs-accordion-btn-bg);
|
72
|
+
--bs-accordion-btn-color: var(--bs-light);
|
73
|
+
--bs-btn-hover-color: var(--bs-accordion-btn-color);
|
74
|
+
--bs-accordion-active-color: var(--bs-accordion-btn-color);
|
134
75
|
}
|
135
76
|
|
136
77
|
.facet-values {
|
@@ -145,7 +86,7 @@
|
|
145
86
|
align-items: flex-start;
|
146
87
|
padding: 3px 0;
|
147
88
|
|
148
|
-
|
89
|
+
&.treeitem {
|
149
90
|
display: block;
|
150
91
|
}
|
151
92
|
|
@@ -161,7 +102,7 @@
|
|
161
102
|
text-decoration: none;
|
162
103
|
|
163
104
|
&:hover {
|
164
|
-
color:
|
105
|
+
color: var(--bl-facet-remove-hover-color);
|
165
106
|
text-decoration: none;
|
166
107
|
}
|
167
108
|
}
|
@@ -194,8 +135,6 @@
|
|
194
135
|
}
|
195
136
|
|
196
137
|
.facet-field-heading {
|
197
|
-
@extend .h6;
|
198
|
-
|
199
138
|
a {
|
200
139
|
color: inherit;
|
201
140
|
}
|
@@ -207,12 +146,6 @@
|
|
207
146
|
/* Sidenav
|
208
147
|
-------------------------------------------------- */
|
209
148
|
|
210
|
-
.facet-pagination {
|
211
|
-
&.top {
|
212
|
-
padding: $modal-inner-padding;
|
213
|
-
}
|
214
|
-
}
|
215
|
-
|
216
149
|
.pivot-facet {
|
217
150
|
&.show {
|
218
151
|
display: flex;
|
@@ -1,5 +1,6 @@
|
|
1
1
|
.group-key {
|
2
|
-
border-
|
2
|
+
--bl-border-color: var(--bs-gray-600);
|
3
|
+
border-bottom: 1px solid var(--bl-border-color);
|
3
4
|
clear: right;
|
4
5
|
}
|
5
6
|
|
@@ -8,7 +9,3 @@
|
|
8
9
|
border-bottom: 0;
|
9
10
|
}
|
10
11
|
}
|
11
|
-
|
12
|
-
.more-in-group {
|
13
|
-
float: right;
|
14
|
-
}
|
@@ -4,15 +4,13 @@
|
|
4
4
|
|
5
5
|
.navbar-logo {
|
6
6
|
/* The main logo image for the Blacklight instance */
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
}
|
11
|
-
height: $logo-height;
|
7
|
+
background: transparent var(--bl-logo-image) no-repeat top left;
|
8
|
+
background-size: var(--bl-logo-width) var(--bl-logo-height);
|
9
|
+
height: var(--bl-logo-height);
|
12
10
|
overflow: hidden;
|
13
11
|
text-indent: 100%;
|
14
12
|
white-space: nowrap;
|
15
|
-
width:
|
13
|
+
width: var(--bl-logo-width);
|
16
14
|
}
|
17
15
|
|
18
16
|
.navbar-search {
|
@@ -26,9 +24,4 @@
|
|
26
24
|
// This prevents the widget from being squished so the text overflows
|
27
25
|
min-width: 7em;
|
28
26
|
}
|
29
|
-
|
30
|
-
.search-query-form {
|
31
|
-
@extend .col-md-12;
|
32
|
-
@extend .col-lg-8;
|
33
|
-
}
|
34
27
|
}
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
.modal-content {
|
6
6
|
.facet-pagination.top {
|
7
|
-
|
7
|
+
display: none; /* Doesn't display in a modal, but would display on a new page (e.g. without Javascript) */
|
8
8
|
}
|
9
9
|
|
10
10
|
.page-sidebar {
|
@@ -23,5 +23,5 @@
|
|
23
23
|
// app/views/catalog/facet.html.erb may be rendered as a modal or a whole page.
|
24
24
|
// When it's a whole page, don't show the close button.
|
25
25
|
.blacklight-modal-close {
|
26
|
-
|
26
|
+
display: none;
|
27
27
|
}
|
@@ -5,7 +5,6 @@
|
|
5
5
|
}
|
6
6
|
|
7
7
|
.input-group > .search-autocomplete-wrapper {
|
8
|
-
@extend .form-control;
|
9
8
|
display: inline-block;
|
10
9
|
flex-grow: 4;
|
11
10
|
padding: 0;
|
@@ -27,3 +26,10 @@
|
|
27
26
|
border-bottom-left-radius: 0;
|
28
27
|
display: flex;
|
29
28
|
}
|
29
|
+
|
30
|
+
// ensure that the search bar appears at the top of the page when focused using
|
31
|
+
// anchor links, e.g. from the skip links navigation
|
32
|
+
.search-field,
|
33
|
+
.search-q {
|
34
|
+
scroll-margin: 5rem;
|
35
|
+
}
|
@@ -5,28 +5,14 @@
|
|
5
5
|
|
6
6
|
.document {
|
7
7
|
display: flex;
|
8
|
-
border-bottom: 1px dotted
|
8
|
+
border-bottom: 1px dotted var(--bs-border-color);
|
9
9
|
margin-top: var(--bl-results-document-margin-top);
|
10
10
|
padding-top: var(--bl-results-document-padding-top);
|
11
11
|
|
12
|
-
.document-title-heading {
|
13
|
-
@extend h5;
|
14
|
-
}
|
15
|
-
|
16
12
|
.document-main-section {
|
17
13
|
flex-grow: 1;
|
18
14
|
}
|
19
15
|
|
20
|
-
// bookmarks checkbox on index, give it some
|
21
|
-
// lower margin when it collapses
|
22
|
-
.index-document-functions {
|
23
|
-
margin-bottom: ($spacer * 1.5);
|
24
|
-
|
25
|
-
@media (min-width: breakpoint-min(sm)) {
|
26
|
-
margin-bottom: 0;
|
27
|
-
}
|
28
|
-
}
|
29
|
-
|
30
16
|
.document-thumbnail {
|
31
17
|
flex-grow: 0;
|
32
18
|
margin-bottom: ($spacer * 3);
|
@@ -1,18 +1,13 @@
|
|
1
|
-
/* Warning! If you want to change these, just copy them into your own theme css. But you want to remove the !default, which only will set them if not already set. */
|
2
|
-
|
3
|
-
$logo-image: image_url("blacklight/logo.png") !default;
|
4
|
-
$logo-width: 150px !default;
|
5
|
-
$logo-height: 50px !default;
|
6
|
-
|
7
|
-
$facet-active-border: $success !default;
|
8
|
-
$facet-active-bg: $success !default;
|
9
|
-
$facet-active-item-color: $success !default;
|
10
|
-
|
11
|
-
/* for compatability with BS < 5.3 */
|
12
|
-
$body-secondary-color: rgba($body-color, 0.75) !default;
|
13
|
-
|
14
1
|
:root {
|
15
|
-
--
|
2
|
+
--bl-logo-image: url("blacklight/logo.png");
|
3
|
+
--bl-logo-width: 150px;
|
4
|
+
--bl-logo-height: 50px;
|
5
|
+
--bs-secondary-color: rgba(
|
6
|
+
33,
|
7
|
+
37,
|
8
|
+
41,
|
9
|
+
0.75
|
10
|
+
); /* for compatability with BS < 5.3 */
|
16
11
|
|
17
12
|
--bl-main-padding-y: 0.5rem;
|
18
13
|
|
@@ -24,7 +24,7 @@ module Blacklight
|
|
24
24
|
|
25
25
|
def default_operator_menu
|
26
26
|
options_with_labels = [:must, :should].index_by { |op| t(op, scope: 'blacklight.advanced_search.op') }
|
27
|
-
label_tag(:op, t('blacklight.advanced_search.op.label'), class: '
|
27
|
+
label_tag(:op, t('blacklight.advanced_search.op.label'), class: 'visually-hidden') + select_tag(:op, options_for_select(options_with_labels, params[:op]), class: 'input-small')
|
28
28
|
end
|
29
29
|
|
30
30
|
def sort_fields_select
|
@@ -4,7 +4,7 @@ module Blacklight
|
|
4
4
|
class ConstraintComponent < Blacklight::Component
|
5
5
|
with_collection_parameter :facet_item_presenter
|
6
6
|
|
7
|
-
def initialize(facet_item_presenter:, classes:
|
7
|
+
def initialize(facet_item_presenter:, classes: %w[filter mx-1], layout: Blacklight::ConstraintLayoutComponent)
|
8
8
|
@facet_item_presenter = facet_item_presenter
|
9
9
|
@classes = classes
|
10
10
|
@layout = layout
|
@@ -9,8 +9,8 @@
|
|
9
9
|
</span>
|
10
10
|
<% if @remove_path.present? %>
|
11
11
|
<%= link_to(@remove_path, class: 'btn btn-outline-secondary remove') do %>
|
12
|
-
<%= render Blacklight::Icons::RemoveComponent.new %>
|
13
|
-
<span class="
|
12
|
+
<%= render Blacklight::Icons::RemoveComponent.new(aria_hidden: true) %>
|
13
|
+
<span class="visually-hidden"><%= remove_aria_label %></span>
|
14
14
|
<% end %>
|
15
15
|
<% end %>
|
16
16
|
</span>
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<%= content_tag @tag || :div, id: @id, class: @classes do %>
|
2
2
|
<% if @render_headers %>
|
3
|
-
<h2 class="
|
3
|
+
<h2 class="visually-hidden"><%= t('blacklight.search.search_constraints_header') %></h2>
|
4
4
|
<% end %>
|
5
5
|
|
6
6
|
<%= render @start_over_component.new if @start_over_component %>
|
7
7
|
|
8
8
|
<% if @render_headers %>
|
9
|
-
<span class="constraints-label
|
9
|
+
<span class="constraints-label visually-hidden"><%= t('blacklight.search.filters.title') %></span>
|
10
10
|
<% end %>
|
11
11
|
<% if query_constraints_area.present? %>
|
12
12
|
<% query_constraints_area.each do |constraint| %>
|
@@ -20,7 +20,7 @@ module Blacklight
|
|
20
20
|
def initialize(search_state:,
|
21
21
|
tag: :div,
|
22
22
|
render_headers: true,
|
23
|
-
id: 'appliedParams', classes: 'clearfix constraints-container',
|
23
|
+
id: 'appliedParams', classes: 'clearfix constraints-container mb-2',
|
24
24
|
query_constraint_component: Blacklight::ConstraintLayoutComponent,
|
25
25
|
query_constraint_component_options: {},
|
26
26
|
facet_constraint_component: Blacklight::ConstraintComponent,
|
@@ -8,9 +8,9 @@
|
|
8
8
|
absent: t('blacklight.search.bookmarks.absent'),
|
9
9
|
inprogress: t('blacklight.search.bookmarks.inprogress')
|
10
10
|
}) do %>
|
11
|
-
<div class="
|
12
|
-
<label class="toggle-bookmark" data-checkboxsubmit-target="label">
|
13
|
-
<input type="checkbox" class="toggle-bookmark <%= bookmark_icon ? 'd-none' : '' %>" data-checkboxsubmit-target="checkbox" <%= 'checked="checked"' if bookmarked? %>>
|
11
|
+
<div class="toggle-bookmark">
|
12
|
+
<label class="toggle-bookmark-label" data-checkboxsubmit-target="label">
|
13
|
+
<input type="checkbox" class="toggle-bookmark-input <%= bookmark_icon ? 'd-none' : '' %>" data-checkboxsubmit-target="checkbox" <%= 'checked="checked"' if bookmarked? %>>
|
14
14
|
<%= bookmark_icon %>
|
15
15
|
<span data-checkboxsubmit-target="span"><%= bookmarked? ? t('blacklight.search.bookmarks.present') : t('blacklight.search.bookmarks.absent') %></span>
|
16
16
|
</label>
|
@@ -4,6 +4,6 @@
|
|
4
4
|
<%= grouped_documents %>
|
5
5
|
</div>
|
6
6
|
<%- if @group_limit > 0 && @group.total > @group_limit %>
|
7
|
-
<%= helpers.link_to t('blacklight.search.group.more'), add_group_facet_params_and_redirect(@group), class: 'more-in-group' %>
|
7
|
+
<%= helpers.link_to t('blacklight.search.group.more'), add_group_facet_params_and_redirect(@group), class: 'more-in-group float-right' %>
|
8
8
|
<%- end %>
|
9
9
|
</div>
|
@@ -40,7 +40,7 @@ module Blacklight
|
|
40
40
|
end
|
41
41
|
|
42
42
|
def header_container_classes
|
43
|
-
has_header_tools? ? 'row pagination-search-widgets pb-
|
43
|
+
has_header_tools? ? 'row pagination-search-widgets pb-3' : 'pagination-search-widgets pb-3'
|
44
44
|
end
|
45
45
|
|
46
46
|
def header_actions
|