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

Update leaflet library to provide a11y improvements #56

Open
kimisgold opened this issue Jun 26, 2024 · 5 comments
Open

Update leaflet library to provide a11y improvements #56

kimisgold opened this issue Jun 26, 2024 · 5 comments

Comments

@kimisgold
Copy link
Member

An accessibility audit has flagged a number of challenges for screen readers:

  • Poor labeling for the "close" buttons on individual marker panes.
  • Map markers cannot be navigated to via keyboard.
  • Screen readers do not announce the map when it comes into focus.

I think Geolocation is currently using Leaflet 1.6.0, and there have been several accessibility updates since that may address these issues.

jimsafley added a commit that referenced this issue Jun 26, 2024
@jimsafley
Copy link
Member

jimsafley commented Jun 26, 2024

The update-leaflet-library branch updates the Leaflet library to v1.9. Hopefully that'll address the issues.

@zerocrates
Copy link
Member

Yes, I'd looked into this a week or so ago. The "close" button should definitely be included in this update. Not sure about the others.

@kimisgold
Copy link
Member Author

I can confirm the close button issue is resolved, as well as the map markers now being navigable via keyboard. I think there are some other elements we have to do ourselves: it seems currently not possible to navigate to popup pane content once a map marker is clicked, and we need a better aria role for the map itself.

@zerocrates
Copy link
Member

The update here is merged, along with updates to the other two leaflet-related dependencies we use.

Other things I'll note here:

  • The marker clusterer did seem to have some accessibility updates, but looks like it has more (in particular aria labeling for the cluster) that were done a long time ago but haven't been released... they haven't made a release in a long time. We could pull it in manually if necessary.
  • Leaflet allows/recommends setting an alt for markers which we're not currently doing, markers have an alt of "Marker" by default it looks like

@kimisgold
Copy link
Member Author

I've provided the item title as an alt for the markers. (28dfc6a).

I think I'd be okay with the manual updates getting pulled in. We could always upgrade again whenever they do a formal release including any future fixes.

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

No branches or pull requests

3 participants