Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add content nav bar for media #2346

Merged
merged 1 commit into from
Feb 6, 2025
Merged

add content nav bar for media #2346

merged 1 commit into from
Feb 6, 2025

Conversation

dnoneill
Copy link
Contributor

@dnoneill dnoneill commented Feb 3, 2025

closes #2342

@@ -24,7 +24,7 @@ def call
if SUPPORTED_MEDIA_TYPES.include?(type.to_sym)
media_element
else
render PreviewImageComponent.new(druid:, file:, type:, resource_index: @resource_iteration.index)
render PreviewImageComponent.new(druid:, file:, type:, size: @resource_iteration.size, resource_index: @resource_iteration.index)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This got updated. I am thinking we should probably just pass the resource_iteration to the component instead of just the index.

@dnoneill dnoneill force-pushed the 2342-media-navbar branch 2 times, most recently from ded8325 to e69d2be Compare February 4, 2025 22:50
@dnoneill dnoneill marked this pull request as ready for review February 4, 2025 22:55
@alundgard
Copy link
Member

Looking good so far. A couple changes:

  • The buttons should have discernible text. Mirador uses aria-label="Previous item" and aria-label="Next item".
  • The buttons should receive focus when navigating by keyboard (Tab and Shift+Tab).

@dnoneill
Copy link
Contributor Author

dnoneill commented Feb 5, 2025

@alundgard Done and deployed

Copy link
Contributor

@jcoyne jcoyne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a test for the presence of the buttons and their aria labels in the spec for the MediaWrapperComponent.

@dnoneill dnoneill requested a review from jcoyne February 6, 2025 15:50
@jcoyne jcoyne merged commit bd15277 into main Feb 6, 2025
2 checks passed
@jcoyne jcoyne deleted the 2342-media-navbar branch February 6, 2025 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Media: Add media content navigation bar
3 participants