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

[accessibility] Remove role="list" from Attribution #12857

Merged
merged 3 commits into from
Sep 12, 2023

Conversation

kumilange
Copy link
Contributor

@kumilange kumilange commented Aug 18, 2023

Handling the good first issue #11033, removing role="list" and role="listitem" from Attribution.

[Before]
before

[After]
after

Note about removing role="listitem"

Attribution link elements seem to be provided from TileJSON and this original source should be fixed.
attibution style server data

I don't seem to have access to fix it so I removed it from the attribution source obtained by this._map.style._sourceCaches in this PR as a quick fix.

I hope someone in the Mapbox team could handle this part.

  • Remove role="listitem" from TileJSON

Launch Checklist

  • briefly describe the changes in this PR
  • include before/after visuals or gifs if this PR includes visual changes
  • manually test the debug page
  • apply changelog label ('bug', 'feature', 'docs', etc) or use the label 'skip changelog'
  • add an entry inside this element for inclusion in the mapbox-gl-js changelog: <changelog>Remove role="list" and role="listitem" from Attribution</changelog>

@@ -64,7 +64,6 @@ class AttributionControl {
this._compactButton.addEventListener('click', this._toggleAttribution);
this._setElementTitle(this._compactButton, 'ToggleAttribution');
this._innerContainer = DOM.create('div', 'mapboxgl-ctrl-attrib-inner', this._container);
this._innerContainer.setAttribute('role', 'list');
Copy link
Member

Choose a reason for hiding this comment

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

@kumiko-haraguchi could we just include this change in your PR and revert those other changes? I can make the upstream changes to remove listitem without having to intercept them in the dom.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@tristen Thank you, I just reverted the commit! 73706e6

@kumilange kumilange requested a review from tristen August 19, 2023 20:34
Copy link
Member

@tristen tristen left a comment

Choose a reason for hiding this comment

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

LGTM. Followup to remove listitem from TileJSON records will happen upstream.

@tristen tristen changed the title [accessibility] Remove role="list" and role="listitem" from Attribution [accessibility] Remove role="list" from Attribution Aug 28, 2023
@stepankuzmin stepankuzmin merged commit 34b26d3 into mapbox:main Sep 12, 2023
28 of 29 checks passed
@kumilange kumilange deleted the rm-rolelist-attribution branch August 8, 2024 16:50
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.

3 participants