Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Validator flags @aria-label on <svg:g> as invalid #1805

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

Open
martindholmes opened this issue Mar 19, 2025 · 0 comments
Open

Validator flags @aria-label on <svg:g> as invalid #1805

martindholmes opened this issue Mar 19, 2025 · 0 comments

Comments

@martindholmes
Copy link

<svg xmlns="http://www.w3.org/2000/svg" id="svg8" version="2.0" viewBox="0 0 266.77068 209.61487" height="30" width="39">
                        
  <g style="font-style:normal;font-weight:normal;font-size:38.3821px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#505050;fill-opacity:1;stroke:none;stroke-width:0.29986" id="text835" transform="scale(0.88235593,1.1333295)" aria-label="ʃ">
  </g>
</svg>              

(Abbreviated for example purposes.)

Error: Attribute “aria-label” not allowed on element “g” at this point.

However, the SVG 2 draft does allow it:

https://svgwg.org/svg2-draft/struct.html#GElement

The 1.1 spec does not, but the error is still flagged when the svg has @version="2.0".

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

1 participant