blacklight 7.40.0 → 7.41.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.
- checksums.yaml +4 -4
- data/.github/matrix.json +62 -0
- data/.github/workflows/build.yml +16 -0
- data/.github/workflows/lint.yml +23 -0
- data/.github/workflows/main.yml +23 -0
- data/.github/workflows/test.yml +53 -0
- data/VERSION +1 -1
- data/app/components/blacklight/document/action_component.rb +1 -3
- data/app/components/blacklight/search_context/server_item_pagination_component.html.erb +10 -0
- data/app/components/blacklight/search_context/server_item_pagination_component.rb +15 -0
- data/app/components/blacklight/search_context_component.rb +1 -0
- data/app/helpers/blacklight/catalog_helper_behavior.rb +1 -1
- data/app/helpers/blacklight/url_helper_behavior.rb +2 -2
- data/app/presenters/blacklight/json_presenter.rb +1 -3
- data/app/views/catalog/_previous_next_doc.html.erb +1 -1
- data/blacklight.gemspec +1 -1
- data/docker-compose.yml +1 -0
- data/lib/blacklight/nested_open_struct_with_hash_access.rb +1 -1
- data/lib/generators/blacklight/controller_generator.rb +1 -1
- data/lib/generators/blacklight/templates/solr/conf/solrconfig.xml +1 -1
- data/lib/generators/blacklight/test_support_generator.rb +1 -1
- data/package.json +1 -1
- data/spec/components/blacklight/search_context/server_item_pagination_component_spec.rb +35 -0
- data/spec/components/blacklight/search_context_component_spec.rb +31 -0
- data/spec/features/facets_spec.rb +3 -5
- data/spec/features/search_context_spec.rb +1 -1
- data/spec/models/solr_document_spec.rb +3 -1
- data/spec/spec_helper.rb +5 -2
- metadata +15 -5
- data/.github/workflows/ruby.yml +0 -159
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 999d98759b905568ee633ca05e1d7b054564d9bd7467d55e7bf816da365a1941
|
4
|
+
data.tar.gz: 452085f8079287d578b2141429077134ea68dd9a7da08372971f868acfe28f14
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c5f9ed2a7d1f1b03b8a1f704a5233eec2aa6885ca2637ef60e315a286e834740388f3c8c203f0cc78b98bc6c9463cf562fcd54bdc5f2e6423c4c2925a26bdc32
|
7
|
+
data.tar.gz: 78c0f61b1c4d821f084eea9a994947042c7f3afb3c8383ece3f95a44498d227f558256460ef215197e6b776aac52f53158b1e53aaca0267fc774de0c52d5938e
|
data/.github/matrix.json
ADDED
@@ -0,0 +1,62 @@
|
|
1
|
+
{
|
2
|
+
"ruby": ["3.3"],
|
3
|
+
"rails_version": [
|
4
|
+
"7.1.5.1",
|
5
|
+
"7.2.2.1"
|
6
|
+
],
|
7
|
+
"bootstrap_version": [
|
8
|
+
null
|
9
|
+
],
|
10
|
+
"view_component_version": [
|
11
|
+
"~> 3.12"
|
12
|
+
],
|
13
|
+
"api": [
|
14
|
+
null
|
15
|
+
],
|
16
|
+
"additional_engine_cart_rails_options": [
|
17
|
+
""
|
18
|
+
],
|
19
|
+
"additional_name": [
|
20
|
+
""
|
21
|
+
],
|
22
|
+
"include": [
|
23
|
+
{
|
24
|
+
"ruby": "3.2",
|
25
|
+
"rails_version": "7.1.5.1"
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"ruby": "3.3",
|
29
|
+
"rails_version": "7.1.5.1",
|
30
|
+
"bootstrap_version": "~> 5.0",
|
31
|
+
"additional_name": "| bootstrap 5"
|
32
|
+
},
|
33
|
+
{
|
34
|
+
"ruby": "3.4",
|
35
|
+
"rails_version": "7.2.2.1"
|
36
|
+
},
|
37
|
+
{
|
38
|
+
"ruby": "3.4",
|
39
|
+
"rails_version": "8.0.2"
|
40
|
+
},
|
41
|
+
{
|
42
|
+
"ruby": "3.3",
|
43
|
+
"rails_version": "7.1.5.1",
|
44
|
+
"view_component_version": "~> 2.74",
|
45
|
+
"additional_name": "| View Component 2"
|
46
|
+
},
|
47
|
+
{
|
48
|
+
"ruby": "3.2",
|
49
|
+
"rails_version": "7.1.5.1",
|
50
|
+
"api": "true",
|
51
|
+
"additional_engine_cart_rails_options": "--api --skip-yarn",
|
52
|
+
"additional_name": "| API"
|
53
|
+
},
|
54
|
+
{
|
55
|
+
"ruby": "3.3",
|
56
|
+
"rails_version": "7.1.5.1",
|
57
|
+
"api:": "true",
|
58
|
+
"additional_engine_cart_rails_options": "--api --skip-yarn",
|
59
|
+
"additional_name": "| API"
|
60
|
+
}
|
61
|
+
]
|
62
|
+
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
on:
|
2
|
+
workflow_call:
|
3
|
+
inputs:
|
4
|
+
ref:
|
5
|
+
required: false
|
6
|
+
type: string
|
7
|
+
default: ''
|
8
|
+
jobs:
|
9
|
+
build:
|
10
|
+
runs-on: ubuntu-latest
|
11
|
+
steps:
|
12
|
+
- uses: actions/checkout@v4
|
13
|
+
with:
|
14
|
+
ref: ${{ inputs.ref }}
|
15
|
+
- name: Build docker image
|
16
|
+
run: docker compose build app
|
@@ -0,0 +1,23 @@
|
|
1
|
+
on:
|
2
|
+
workflow_call:
|
3
|
+
inputs:
|
4
|
+
ref:
|
5
|
+
required: false
|
6
|
+
type: string
|
7
|
+
default: ''
|
8
|
+
jobs:
|
9
|
+
lint:
|
10
|
+
runs-on: ubuntu-latest
|
11
|
+
steps:
|
12
|
+
- uses: actions/checkout@v4
|
13
|
+
with:
|
14
|
+
ref: ${{ inputs.ref }}
|
15
|
+
- name: Set up Ruby
|
16
|
+
uses: ruby/setup-ruby@v1
|
17
|
+
with:
|
18
|
+
ruby-version: 3.2
|
19
|
+
bundler: "default"
|
20
|
+
- name: Install dependencies
|
21
|
+
run: bundle install
|
22
|
+
- name: Run linter
|
23
|
+
run: bundle exec rake rubocop
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# This workflow uses actions that are not certified by GitHub.
|
2
|
+
# They are provided by a third-party and are governed by
|
3
|
+
# separate terms of service, privacy policy, and support
|
4
|
+
# documentation.
|
5
|
+
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
|
6
|
+
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
|
7
|
+
|
8
|
+
name: CI
|
9
|
+
|
10
|
+
on:
|
11
|
+
push:
|
12
|
+
branches:
|
13
|
+
- main
|
14
|
+
- 'release-*'
|
15
|
+
pull_request:
|
16
|
+
|
17
|
+
jobs:
|
18
|
+
lint:
|
19
|
+
uses: ./.github/workflows/lint.yml
|
20
|
+
test:
|
21
|
+
uses: ./.github/workflows/test.yml
|
22
|
+
docker_build:
|
23
|
+
uses: ./.github/workflows/build.yml
|
@@ -0,0 +1,53 @@
|
|
1
|
+
on:
|
2
|
+
workflow_call:
|
3
|
+
inputs:
|
4
|
+
ref:
|
5
|
+
required: false
|
6
|
+
type: string
|
7
|
+
default: ''
|
8
|
+
description: The branch or reference to run the workflow against
|
9
|
+
jobs:
|
10
|
+
set_matrix:
|
11
|
+
runs-on: ubuntu-latest
|
12
|
+
outputs:
|
13
|
+
matrix: ${{ steps.matrix.outputs.matrix }}
|
14
|
+
steps:
|
15
|
+
- name: Checkout repository
|
16
|
+
uses: actions/checkout@v3
|
17
|
+
with:
|
18
|
+
ref: ${{ inputs.ref }}
|
19
|
+
- name: Echo ./.github/matrix.json
|
20
|
+
id: matrix
|
21
|
+
run: |
|
22
|
+
echo "matrix<<EOF" >> $GITHUB_OUTPUT
|
23
|
+
cat ./.github/matrix.json >> $GITHUB_OUTPUT
|
24
|
+
echo "EOF" >> $GITHUB_OUTPUT
|
25
|
+
test:
|
26
|
+
needs: set_matrix
|
27
|
+
runs-on: ubuntu-latest
|
28
|
+
name: ruby ${{ matrix.ruby }} | rails ${{ matrix.rails_version }} ${{ matrix.additional_name }}
|
29
|
+
strategy:
|
30
|
+
fail-fast: false
|
31
|
+
matrix: ${{fromJson(needs.set_matrix.outputs.matrix)}}
|
32
|
+
env:
|
33
|
+
RAILS_VERSION: ${{ matrix.rails_version }}
|
34
|
+
SOLR_VERSION: ${{ matrix.solr_version || 'latest' }}
|
35
|
+
VIEW_COMPONENT_VERSION: ${{ matrix.view_component_version }}
|
36
|
+
BOOTSTRAP_VERSION: ${{ matrix.bootstrap_version }}
|
37
|
+
BLACKLIGHT_API_TEST: ${{ matrix.api }}
|
38
|
+
ENGINE_CART_RAILS_OPTIONS: "--skip-git --skip-listen --skip-spring --skip-keeps --skip-kamal --skip-solid --skip-coffee --skip-test ${{ matrix.additional_engine_cart_rails_options }}"
|
39
|
+
steps:
|
40
|
+
- uses: actions/checkout@v4
|
41
|
+
with:
|
42
|
+
ref: ${{ inputs.ref }}
|
43
|
+
- name: Set up Ruby
|
44
|
+
uses: ruby/setup-ruby@v1
|
45
|
+
with:
|
46
|
+
bundler: "latest"
|
47
|
+
ruby-version: ${{ matrix.ruby }}
|
48
|
+
- name: Change permissions
|
49
|
+
run: "chmod -f -R o-w /opt/hostedtoolcache/Ruby/3.2.5/x64/lib/ruby/gems/3.2.0/gems | :"
|
50
|
+
- name: Install dependencies
|
51
|
+
run: bundle install
|
52
|
+
- name: Run tests
|
53
|
+
run: bundle exec rake ci
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
7.
|
1
|
+
7.41.0
|
@@ -0,0 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Blacklight
|
4
|
+
module SearchContext
|
5
|
+
class ServerItemPaginationComponent < Blacklight::SearchContextComponent
|
6
|
+
with_collection_parameter :search_context
|
7
|
+
|
8
|
+
def initialize(search_context:, search_session:, current_document:)
|
9
|
+
@search_context = search_context
|
10
|
+
@search_session = search_session
|
11
|
+
@current_document_id = current_document.id
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -5,6 +5,7 @@ module Blacklight
|
|
5
5
|
with_collection_parameter :search_context
|
6
6
|
|
7
7
|
def initialize(search_context:, search_session:)
|
8
|
+
Deprecation.warn("Blacklight::SearchContextComponent is deprecated and will be moved to Blacklight::SearchContext::ServerItemPaginationComponent in Blacklight 8.0.0")
|
8
9
|
@search_context = search_context
|
9
10
|
@search_session = search_session
|
10
11
|
end
|
@@ -106,7 +106,7 @@ module Blacklight::CatalogHelperBehavior
|
|
106
106
|
total: number_with_delimiter(search_session['total']),
|
107
107
|
count: search_session['total'].to_i).html_safe
|
108
108
|
end
|
109
|
-
deprecation_deprecate item_page_entry_info: 'Use Blacklight::
|
109
|
+
deprecation_deprecate item_page_entry_info: 'Use Blacklight::SearchContext::ServerItemPaginationComponent methods instead'
|
110
110
|
|
111
111
|
##
|
112
112
|
# Look up search field user-displayable label
|
@@ -58,7 +58,7 @@ module Blacklight::UrlHelperBehavior
|
|
58
58
|
tag.span raw(t('views.pagination.previous')), class: 'previous'
|
59
59
|
end
|
60
60
|
end
|
61
|
-
deprecation_deprecate link_to_previous_document: 'Moving to Blacklight::
|
61
|
+
deprecation_deprecate link_to_previous_document: 'Moving to Blacklight::SearchContext::ServerItemPaginationComponent'
|
62
62
|
|
63
63
|
##
|
64
64
|
# Link to the next document in the current search context
|
@@ -69,7 +69,7 @@ module Blacklight::UrlHelperBehavior
|
|
69
69
|
tag.span raw(t('views.pagination.next')), class: 'next'
|
70
70
|
end
|
71
71
|
end
|
72
|
-
deprecation_deprecate link_to_previous_document: 'Moving to Blacklight::
|
72
|
+
deprecation_deprecate link_to_previous_document: 'Moving to Blacklight::SearchContext::ServerItemPaginationComponent'
|
73
73
|
|
74
74
|
##
|
75
75
|
# Attributes for a link that gives a URL we can use to track clicks for the current search session
|
@@ -1,2 +1,2 @@
|
|
1
|
-
<% Deprecation.warn(self, 'The partial _previous_next_doc.html.erb will be removed in 8.0. Render Blacklight::
|
1
|
+
<% Deprecation.warn(self, 'The partial _previous_next_doc.html.erb will be removed in 8.0. Render Blacklight::SearchContext::ServerItemPaginationComponent instead.') %>
|
2
2
|
<%= render(Blacklight::SearchContextComponent.new(search_context: @search_context, search_session: search_session)) %>
|
data/blacklight.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |s|
|
|
25
25
|
|
26
26
|
s.required_ruby_version = '>= 2.7'
|
27
27
|
|
28
|
-
s.add_dependency "rails", '>= 6.1', '<
|
28
|
+
s.add_dependency "rails", '>= 6.1', '< 8.1'
|
29
29
|
s.add_dependency "globalid"
|
30
30
|
s.add_dependency "jbuilder", '~> 2.7'
|
31
31
|
s.add_dependency "kaminari", ">= 0.15" # the pagination (page 1,2,3, etc..) of our search results
|
data/docker-compose.yml
CHANGED
@@ -23,6 +23,7 @@ services:
|
|
23
23
|
environment:
|
24
24
|
- SOLR_PORT # Set via environment variable or use default defined in .env file
|
25
25
|
- SOLR_VERSION # Set via environment variable or use default defined in .env file
|
26
|
+
- SOLR_MODULES=analysis-extras
|
26
27
|
image: "solr:${SOLR_VERSION}"
|
27
28
|
volumes:
|
28
29
|
- $PWD/lib/generators/blacklight/templates/solr/conf:/opt/solr/conf
|
@@ -30,7 +30,7 @@ module Blacklight
|
|
30
30
|
route <<-EOF
|
31
31
|
concern :searchable, Blacklight::Routes::Searchable.new
|
32
32
|
|
33
|
-
resource :catalog, only: [
|
33
|
+
resource :catalog, only: [], as: 'catalog', path: '/catalog', controller: 'catalog' do
|
34
34
|
concerns :searchable
|
35
35
|
end
|
36
36
|
EOF
|
@@ -16,7 +16,7 @@
|
|
16
16
|
</updateLog>
|
17
17
|
</updateHandler>
|
18
18
|
|
19
|
-
<!-- solr lib dirs -->
|
19
|
+
<!-- solr lib dirs, which are needed for Solr 8 compatibility but ignored in solr 9.8 and above -->
|
20
20
|
<lib dir="${solr.install.dir:../../../..}/modules/analysis-extras/lib" />
|
21
21
|
<lib dir="${solr.install.dir:../../../..}/contrib/analysis-extras/lib" />
|
22
22
|
<lib dir="${solr.install.dir:../../../..}/contrib/analysis-extras/lucene-libs" />
|
@@ -17,7 +17,7 @@ module Blacklight
|
|
17
17
|
copy_file "alternate_controller.rb", "app/controllers/alternate_controller.rb"
|
18
18
|
|
19
19
|
routing_code = <<-EOF
|
20
|
-
resource :alternate, controller: 'alternate', only: [
|
20
|
+
resource :alternate, controller: 'alternate', only: [] do
|
21
21
|
concerns :searchable
|
22
22
|
end
|
23
23
|
EOF
|
data/package.json
CHANGED
@@ -0,0 +1,35 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'spec_helper'
|
4
|
+
|
5
|
+
RSpec.describe Blacklight::SearchContext::ServerItemPaginationComponent, type: :component do
|
6
|
+
subject(:render) { render_inline(instance) }
|
7
|
+
|
8
|
+
let(:current_document_id) { 9 }
|
9
|
+
let(:current_document) { SolrDocument.new(id: current_document_id) }
|
10
|
+
let(:search_session) { { 'document_id' => current_document_id, 'counter' => 1, 'total' => '3' } }
|
11
|
+
let(:instance) { described_class.new(search_context: search_context, search_session: search_session, current_document: current_document) }
|
12
|
+
|
13
|
+
before do
|
14
|
+
allow(controller).to receive(:search_session).and_return(search_session)
|
15
|
+
allow(controller).to receive(:current_search_session).and_return(double(id: current_document_id))
|
16
|
+
controller.class.helper_method :search_session
|
17
|
+
controller.class.helper_method :current_search_session
|
18
|
+
end
|
19
|
+
|
20
|
+
context 'when there is next and previous' do
|
21
|
+
let(:search_context) { { next: next_doc, prev: prev_doc } }
|
22
|
+
let(:prev_doc) { SolrDocument.new(id: '777') }
|
23
|
+
let(:next_doc) { SolrDocument.new(id: '888') }
|
24
|
+
|
25
|
+
before do
|
26
|
+
# allow(controller).to receive(:controller_tracking_method).and_return('track_catalog_path')
|
27
|
+
|
28
|
+
allow(controller).to receive_messages(controller_name: 'catalog', link_to_previous_document: '', link_to_next_document: '')
|
29
|
+
end
|
30
|
+
|
31
|
+
it "renders content" do
|
32
|
+
expect(render.css('.page-links').to_html).not_to be_blank
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'spec_helper'
|
4
|
+
RSpec.describe Blacklight::SearchContextComponent, type: :component do
|
5
|
+
subject(:render) { render_inline(instance) }
|
6
|
+
|
7
|
+
let(:current_document_id) { 9 }
|
8
|
+
let(:search_session) { { 'document_id' => current_document_id, 'counter' => 1, 'total' => '3' } }
|
9
|
+
let(:instance) { described_class.new(search_context: search_context, search_session: search_session) }
|
10
|
+
|
11
|
+
before do
|
12
|
+
allow(controller).to receive(:search_session).and_return(search_session)
|
13
|
+
allow(controller).to receive(:current_search_session).and_return(double(id: current_document_id))
|
14
|
+
controller.class.helper_method :search_session
|
15
|
+
controller.class.helper_method :current_search_session
|
16
|
+
end
|
17
|
+
|
18
|
+
context 'when there is next and previous' do
|
19
|
+
let(:search_context) { { next: next_doc, prev: prev_doc } }
|
20
|
+
let(:prev_doc) { SolrDocument.new(id: '777') }
|
21
|
+
let(:next_doc) { SolrDocument.new(id: '888') }
|
22
|
+
|
23
|
+
before do
|
24
|
+
allow(controller).to receive_messages(controller_name: 'catalog', link_to_previous_document: '', link_to_next_document: '')
|
25
|
+
end
|
26
|
+
|
27
|
+
it "renders content" do
|
28
|
+
expect(render.css('.page-links').to_html).not_to be_blank
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
@@ -79,13 +79,11 @@ RSpec.describe "Facets" do
|
|
79
79
|
expect(page).to have_css('.constraint-value', text: 'Language Tibetan')
|
80
80
|
end
|
81
81
|
|
82
|
-
describe 'heading button focus
|
83
|
-
it 'changes to the button on button click
|
84
|
-
pending 'Capybara::NotSupportedByDriverError: Capybara::Driver::Base#evaluate_script'
|
82
|
+
describe 'heading button focus' do
|
83
|
+
it 'changes to the button on button click', js: true do
|
85
84
|
visit root_path
|
86
85
|
page.find('h3.facet-field-heading button', text: 'Format').click
|
87
|
-
|
88
|
-
expect(focused_element_data_target).to eq '#facet-format'
|
86
|
+
expect(page.active_element.text).to eq 'Format'
|
89
87
|
end
|
90
88
|
end
|
91
89
|
|
@@ -35,7 +35,7 @@ RSpec.describe "Search Results context", js: true do
|
|
35
35
|
it "does not display stale previous and next links for direct item views" do
|
36
36
|
search_for ''
|
37
37
|
click_on 'Pluvial nectar of blessings'
|
38
|
-
|
38
|
+
expect(page).to have_link('Cite')
|
39
39
|
# Go to the number 9 result separately
|
40
40
|
visit '/catalog/2003546302'
|
41
41
|
expect(page).not_to have_selector '.page-links'
|
@@ -37,7 +37,9 @@ RSpec.describe SolrDocument, api: true do
|
|
37
37
|
title_tesim: ['Good Omens'])
|
38
38
|
end
|
39
39
|
|
40
|
-
it
|
40
|
+
it 'ends with the expected information' do
|
41
|
+
expect(inspect).to match(/_source: {"id" ?=> ?"123", "title_tesim" ?=> ?\["Good Omens"\]\}>$/)
|
42
|
+
end
|
41
43
|
end
|
42
44
|
|
43
45
|
describe '.attribute' do
|
data/spec/spec_helper.rb
CHANGED
@@ -48,8 +48,11 @@ RSpec.configure do |config|
|
|
48
48
|
# When we're testing the API, only run the api tests
|
49
49
|
config.filter_run api: true if ENV['BLACKLIGHT_API_TEST']
|
50
50
|
|
51
|
-
|
52
|
-
|
51
|
+
if Rails.version.to_f >= 7.1
|
52
|
+
config.fixture_paths = [Rails.root.join("spec/fixtures")]
|
53
|
+
else
|
54
|
+
config.fixture_path = Rails.root.join("spec/fixtures")
|
55
|
+
end
|
53
56
|
|
54
57
|
# If you're not using ActiveRecord, or you'd prefer not to run each of your
|
55
58
|
# examples within a transaction, remove the following line or assign false
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blacklight
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.
|
4
|
+
version: 7.41.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonathan Rochkind
|
@@ -17,7 +17,7 @@ authors:
|
|
17
17
|
autorequire:
|
18
18
|
bindir: exe
|
19
19
|
cert_chain: []
|
20
|
-
date:
|
20
|
+
date: 2025-05-30 00:00:00.000000000 Z
|
21
21
|
dependencies:
|
22
22
|
- !ruby/object:Gem::Dependency
|
23
23
|
name: rails
|
@@ -28,7 +28,7 @@ dependencies:
|
|
28
28
|
version: '6.1'
|
29
29
|
- - "<"
|
30
30
|
- !ruby/object:Gem::Version
|
31
|
-
version: '
|
31
|
+
version: '8.1'
|
32
32
|
type: :runtime
|
33
33
|
prerelease: false
|
34
34
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -38,7 +38,7 @@ dependencies:
|
|
38
38
|
version: '6.1'
|
39
39
|
- - "<"
|
40
40
|
- !ruby/object:Gem::Version
|
41
|
-
version: '
|
41
|
+
version: '8.1'
|
42
42
|
- !ruby/object:Gem::Dependency
|
43
43
|
name: globalid
|
44
44
|
requirement: !ruby/object:Gem::Requirement
|
@@ -417,7 +417,11 @@ files:
|
|
417
417
|
- ".docker/app/entrypoint.sh"
|
418
418
|
- ".dockerignore"
|
419
419
|
- ".env"
|
420
|
-
- ".github/
|
420
|
+
- ".github/matrix.json"
|
421
|
+
- ".github/workflows/build.yml"
|
422
|
+
- ".github/workflows/lint.yml"
|
423
|
+
- ".github/workflows/main.yml"
|
424
|
+
- ".github/workflows/test.yml"
|
421
425
|
- ".gitignore"
|
422
426
|
- ".hound.yml"
|
423
427
|
- ".jshintrc"
|
@@ -528,6 +532,8 @@ files:
|
|
528
532
|
- app/components/blacklight/search_bar_component.html.erb
|
529
533
|
- app/components/blacklight/search_bar_component.rb
|
530
534
|
- app/components/blacklight/search_button_component.rb
|
535
|
+
- app/components/blacklight/search_context/server_item_pagination_component.html.erb
|
536
|
+
- app/components/blacklight/search_context/server_item_pagination_component.rb
|
531
537
|
- app/components/blacklight/search_context_component.html.erb
|
532
538
|
- app/components/blacklight/search_context_component.rb
|
533
539
|
- app/components/blacklight/search_history_constraint_layout_component.rb
|
@@ -841,6 +847,8 @@ files:
|
|
841
847
|
- spec/components/blacklight/response/pagination_component_spec.rb
|
842
848
|
- spec/components/blacklight/response/spellcheck_component_spec.rb
|
843
849
|
- spec/components/blacklight/search_bar_component_spec.rb
|
850
|
+
- spec/components/blacklight/search_context/server_item_pagination_component_spec.rb
|
851
|
+
- spec/components/blacklight/search_context_component_spec.rb
|
844
852
|
- spec/components/blacklight/start_over_button_component_spec.rb
|
845
853
|
- spec/components/blacklight/system/flash_message_component_spec.rb
|
846
854
|
- spec/controllers/alternate_controller_spec.rb
|
@@ -1029,6 +1037,8 @@ test_files:
|
|
1029
1037
|
- spec/components/blacklight/response/pagination_component_spec.rb
|
1030
1038
|
- spec/components/blacklight/response/spellcheck_component_spec.rb
|
1031
1039
|
- spec/components/blacklight/search_bar_component_spec.rb
|
1040
|
+
- spec/components/blacklight/search_context/server_item_pagination_component_spec.rb
|
1041
|
+
- spec/components/blacklight/search_context_component_spec.rb
|
1032
1042
|
- spec/components/blacklight/start_over_button_component_spec.rb
|
1033
1043
|
- spec/components/blacklight/system/flash_message_component_spec.rb
|
1034
1044
|
- spec/controllers/alternate_controller_spec.rb
|
data/.github/workflows/ruby.yml
DELETED
@@ -1,159 +0,0 @@
|
|
1
|
-
# This workflow uses actions that are not certified by GitHub.
|
2
|
-
# They are provided by a third-party and are governed by
|
3
|
-
# separate terms of service, privacy policy, and support
|
4
|
-
# documentation.
|
5
|
-
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
|
6
|
-
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
|
7
|
-
|
8
|
-
name: CI
|
9
|
-
|
10
|
-
on:
|
11
|
-
push:
|
12
|
-
branches:
|
13
|
-
- main
|
14
|
-
- 'release-*'
|
15
|
-
pull_request:
|
16
|
-
|
17
|
-
jobs:
|
18
|
-
lint:
|
19
|
-
runs-on: ubuntu-latest
|
20
|
-
steps:
|
21
|
-
- uses: actions/checkout@v2
|
22
|
-
- name: Set up Ruby
|
23
|
-
uses: ruby/setup-ruby@v1
|
24
|
-
with:
|
25
|
-
ruby-version: 3.1
|
26
|
-
bundler: 'default'
|
27
|
-
- name: Install dependencies
|
28
|
-
run: bundle install
|
29
|
-
- name: Run linter
|
30
|
-
run: bundle exec rake rubocop
|
31
|
-
test:
|
32
|
-
runs-on: ubuntu-latest
|
33
|
-
strategy:
|
34
|
-
matrix:
|
35
|
-
ruby: [3.1, 3.2]
|
36
|
-
env:
|
37
|
-
RAILS_VERSION: 7.0.8
|
38
|
-
steps:
|
39
|
-
- uses: actions/checkout@v2
|
40
|
-
- name: Set up Ruby
|
41
|
-
uses: ruby/setup-ruby@v1
|
42
|
-
with:
|
43
|
-
ruby-version: ${{ matrix.ruby }}
|
44
|
-
bundler: 'default'
|
45
|
-
- name: Install dependencies
|
46
|
-
run: bundle install
|
47
|
-
- name: Run tests
|
48
|
-
run: bundle exec rake ci
|
49
|
-
env:
|
50
|
-
ENGINE_CART_RAILS_OPTIONS: '--skip-git --skip-listen --skip-spring --skip-keeps --skip-coffee --skip-test'
|
51
|
-
test_bootstrap5:
|
52
|
-
runs-on: ubuntu-latest
|
53
|
-
strategy:
|
54
|
-
matrix:
|
55
|
-
ruby: ['3.0']
|
56
|
-
env:
|
57
|
-
RAILS_VERSION: 7.0.8
|
58
|
-
steps:
|
59
|
-
- uses: actions/checkout@v2
|
60
|
-
- name: Set up Ruby
|
61
|
-
uses: ruby/setup-ruby@v1
|
62
|
-
with:
|
63
|
-
ruby-version: ${{ matrix.ruby }}
|
64
|
-
bundler: 'default'
|
65
|
-
- name: Install dependencies
|
66
|
-
run: bundle install
|
67
|
-
- name: Run tests
|
68
|
-
run: bundle exec rake ci
|
69
|
-
env:
|
70
|
-
BOOTSTRAP_VERSION: '~> 5.0'
|
71
|
-
ENGINE_CART_RAILS_OPTIONS: '--skip-git --skip-listen --skip-spring --skip-keeps --skip-coffee --skip-test'
|
72
|
-
test_rails6_1:
|
73
|
-
runs-on: ubuntu-latest
|
74
|
-
strategy:
|
75
|
-
matrix:
|
76
|
-
ruby: ['3.0']
|
77
|
-
env:
|
78
|
-
RAILS_VERSION: 6.1.6.1
|
79
|
-
steps:
|
80
|
-
- uses: actions/checkout@v2
|
81
|
-
- name: Set up Ruby
|
82
|
-
uses: ruby/setup-ruby@v1
|
83
|
-
with:
|
84
|
-
ruby-version: ${{ matrix.ruby }}
|
85
|
-
bundler: 'default'
|
86
|
-
- name: Install dependencies
|
87
|
-
run: bundle install
|
88
|
-
- name: Run tests
|
89
|
-
run: bundle exec rake ci
|
90
|
-
env:
|
91
|
-
ENGINE_CART_RAILS_OPTIONS: '--skip-git --skip-keeps --skip-action-cable --skip-test'
|
92
|
-
test_rails7_2:
|
93
|
-
runs-on: ubuntu-latest
|
94
|
-
strategy:
|
95
|
-
matrix:
|
96
|
-
ruby: [3.1, 3.2]
|
97
|
-
env:
|
98
|
-
RAILS_VERSION: 7.2.0
|
99
|
-
steps:
|
100
|
-
- uses: actions/checkout@v2
|
101
|
-
- name: Set up Ruby
|
102
|
-
uses: ruby/setup-ruby@v1
|
103
|
-
with:
|
104
|
-
ruby-version: ${{ matrix.ruby }}
|
105
|
-
bundler: 'default'
|
106
|
-
- name: Install dependencies
|
107
|
-
run: bundle install
|
108
|
-
- name: Run tests
|
109
|
-
run: bundle exec rake ci
|
110
|
-
env:
|
111
|
-
ENGINE_CART_RAILS_OPTIONS: '--skip-keeps --skip-test'
|
112
|
-
test_vc2:
|
113
|
-
runs-on: ubuntu-latest
|
114
|
-
strategy:
|
115
|
-
matrix:
|
116
|
-
ruby: ['3.2']
|
117
|
-
env:
|
118
|
-
RAILS_VERSION: 7.0.8
|
119
|
-
VIEW_COMPONENT_VERSION: "~> 2.74"
|
120
|
-
steps:
|
121
|
-
- uses: actions/checkout@v2
|
122
|
-
- name: Set up Ruby
|
123
|
-
uses: ruby/setup-ruby@v1
|
124
|
-
with:
|
125
|
-
ruby-version: ${{ matrix.ruby }}
|
126
|
-
bundler: 'default'
|
127
|
-
- name: Install dependencies
|
128
|
-
run: bundle install
|
129
|
-
- name: Run tests
|
130
|
-
run: bundle exec rake ci
|
131
|
-
env:
|
132
|
-
ENGINE_CART_RAILS_OPTIONS: '--skip-git --skip-listen --skip-spring --skip-keeps --skip-coffee --skip-test'
|
133
|
-
api_test:
|
134
|
-
runs-on: ubuntu-latest
|
135
|
-
strategy:
|
136
|
-
matrix:
|
137
|
-
ruby: [2.7, '3.0']
|
138
|
-
env:
|
139
|
-
RAILS_VERSION: 7.0.8
|
140
|
-
steps:
|
141
|
-
- uses: actions/checkout@v2
|
142
|
-
- name: Set up Ruby
|
143
|
-
uses: ruby/setup-ruby@v1
|
144
|
-
with:
|
145
|
-
bundler: 'default'
|
146
|
-
ruby-version: ${{ matrix.ruby }}
|
147
|
-
- name: Install dependencies
|
148
|
-
run: bundle install
|
149
|
-
- name: Run tests
|
150
|
-
run: bundle exec rake ci
|
151
|
-
env:
|
152
|
-
BLACKLIGHT_API_TEST: true
|
153
|
-
ENGINE_CART_RAILS_OPTIONS: '-a propshaft --api --skip-git --skip-bundle --skip-listen --skip-spring --skip-yarn --skip-keeps --skip-action-cable --skip-coffee --skip-test'
|
154
|
-
docker_build:
|
155
|
-
runs-on: ubuntu-latest
|
156
|
-
steps:
|
157
|
-
- uses: actions/checkout@v3
|
158
|
-
- name: Build docker image
|
159
|
-
run: docker compose build app
|