From 00ee6c4421e4128787755309bbf04047bc91e686 Mon Sep 17 00:00:00 2001 From: David Zuckerman Date: Wed, 16 Sep 2026 13:23:07 -0700 Subject: [PATCH 1/2] keyboard accessibility for collection management dropdown accordian --- .../collection_management/_show.html.erb | 4 ++-- .../features/collection_management_spec.rb | 23 +++++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/frontend/app/views/collection_management/_show.html.erb b/frontend/app/views/collection_management/_show.html.erb index a16602b9c6..ed523070ff 100644 --- a/frontend/app/views/collection_management/_show.html.erb +++ b/frontend/app/views/collection_management/_show.html.erb @@ -7,7 +7,7 @@
<%= read_only_view(collection_management) %> diff --git a/frontend/spec/features/collection_management_spec.rb b/frontend/spec/features/collection_management_spec.rb index 1ec7fa4dbe..3c9775e57d 100644 --- a/frontend/spec/features/collection_management_spec.rb +++ b/frontend/spec/features/collection_management_spec.rb @@ -23,6 +23,29 @@ expect(page).to have_text 'No records found' end + it 'provides a keyboard-operable accordion control on the accession show page' do + accession = create( + :accession, + collection_management: { + "processing_priority" => "high" + } + ) + + begin + visit "/accessions/#{accession.id}" + + within '#accession_collection_management_' do + toggle = find('.accordion-toggle') + expect(toggle.tag_name).to eq('a') + expect(toggle[:href]).to end_with('#accession_collection_management__collection_management') + expect(toggle[:'aria-controls']).to eq('accession_collection_management__collection_management') + end + ensure + accession.delete + run_index_round + end + end + it 'is browseable even when its linked accession has no title' do now = Time.now.to_i From f29a0ead5dbc7228a3fe54ff17dd67ae358f620c Mon Sep 17 00:00:00 2001 From: David Zuckerman Date: Mon, 21 Sep 2026 10:13:34 -0700 Subject: [PATCH 2/2] Using button instead of for accordion dropdown --- frontend/app/views/collection_management/_show.html.erb | 4 ++-- frontend/spec/features/collection_management_spec.rb | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/frontend/app/views/collection_management/_show.html.erb b/frontend/app/views/collection_management/_show.html.erb index ed523070ff..cd283dbb62 100644 --- a/frontend/app/views/collection_management/_show.html.erb +++ b/frontend/app/views/collection_management/_show.html.erb @@ -7,7 +7,7 @@
<%= read_only_view(collection_management) %> diff --git a/frontend/spec/features/collection_management_spec.rb b/frontend/spec/features/collection_management_spec.rb index 3c9775e57d..ff0c91f048 100644 --- a/frontend/spec/features/collection_management_spec.rb +++ b/frontend/spec/features/collection_management_spec.rb @@ -36,8 +36,9 @@ within '#accession_collection_management_' do toggle = find('.accordion-toggle') - expect(toggle.tag_name).to eq('a') - expect(toggle[:href]).to end_with('#accession_collection_management__collection_management') + expect(toggle.tag_name).to eq('button') + expect(toggle[:type]).to eq('button') + expect(toggle[:'data-target']).to eq('#accession_collection_management__collection_management') expect(toggle[:'aria-controls']).to eq('accession_collection_management__collection_management') end ensure