Bug 25234 - Update OPAC search results pagination with aria labels
Summary: Update OPAC search results pagination with aria labels
Status: Pushed to master
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 23003
  Show dependency treegraph
 
Reported: 2020-04-21 21:18 UTC by Owen Leonard
Modified: 2020-05-08 22:25 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
20.05.00


Attachments
Bug 25234: Update OPAC search results pagination with aria labels (6.36 KB, patch)
2020-04-21 21:29 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 25234: Update OPAC search results pagination with aria labels (6.36 KB, patch)
2020-04-22 01:05 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 25234: Update OPAC search results pagination with aria labels (6.42 KB, patch)
2020-04-23 22:02 UTC, Lucas Gass
Details | Diff | Splinter Review
Bug 25234: Update OPAC search results pagination with aria labels (6.48 KB, patch)
2020-04-24 10:24 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2020-04-21 21:18:56 UTC
For better accessibility I would like to add aria labels to the include file which generates OPAC search results pagination. See articles:

https://a11y-style-guide.com/style-guide/section-navigation.html#kssref-navigation-pagination
https://www.a11ymatters.com/pattern/pagination/
Comment 1 Owen Leonard 2020-04-21 21:29:11 UTC Comment hidden (obsolete)
Comment 2 Lucas Gass 2020-04-21 21:43:56 UTC
I was testing this and caught one small typo that existed before this change:

<a clas="page-num current"

should be 

<a class="page-num current"


Not 100% sure if we should fix that here or in a separate bug?
Comment 3 Owen Leonard 2020-04-22 01:05:50 UTC Comment hidden (obsolete)
Comment 4 Owen Leonard 2020-04-22 01:06:35 UTC
(In reply to Lucas Gass from comment #2)
> Not 100% sure if we should fix that here or in a separate bug?

Easy enough to fix up the patch. Thanks for noticing it.
Comment 5 Lucas Gass 2020-04-23 22:02:09 UTC Comment hidden (obsolete)
Comment 6 Jonathan Druart 2020-04-24 10:24:13 UTC
Created attachment 103639 [details] [review]
Bug 25234: Update OPAC search results pagination with aria labels

This patch updates the include file which generates OPAC search results
pagination so that it has better semantic markup and correct aria
labels.

To test, apply the patch and do a search in the OPAC which will return
multiple pages of search results.

View the source to confirm the markup changes:

 - <nav> instead of <div> surrounding the list of links, with a
   corresponding aria label
 - Navigation links should have labels indicating which page in the
   results they point to.
 - The current link should have "aria-disabled," and "aria-current" set.
 - Numbered links should have aria labels that indicate their number.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 7 Martin Renvoize 2020-04-29 15:56:17 UTC
Always awesome to see some movement on accessibility, thanks Owe :)
Comment 8 Martin Renvoize 2020-04-29 16:36:22 UTC
Nice work everyone!

Pushed to master for 20.05
Comment 9 Joy Nelson 2020-05-08 22:25:26 UTC
enhancement not backported to 19.11.x