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

Button and toggle-button should not contain a `<div>` #16350

Open
ksag-tap opened this issue Jun 21, 2019 · 3 comments

Comments

@ksag-tap
Copy link

@ksag-tap ksag-tap commented Jun 21, 2019

Reproduction

https://stackblitz.com/edit/components-issue-utnh8w

Steps to reproduce:

  1. run stackblitz
  2. see html source

Expected Behavior

element's Permitted content is Phrasing content , according to HTML5 rule.

Actual Behavior

element by Material Button Component and Toggle Button Component includes div element (Flow content)

Environment

  • Angular:7 ~ 8
  • CDK/Material:7 ~ 8

@jelbourn jelbourn changed the title Button and Toggle Button provide invalid structure Button and toggle-button should not contain a `<div>` Jun 21, 2019
@jelbourn jelbourn added P4 and removed P3 labels Jun 21, 2019
@jelbourn

This comment has been minimized.

Copy link
Member

@jelbourn jelbourn commented Jun 21, 2019

Confirmed that both contain a div which is technically not allowed by the spec, but doesn't actually cause any real problems.

@ksag-tap

This comment has been minimized.

Copy link
Author

@ksag-tap ksag-tap commented Jun 23, 2019

I agree with you, it doesn't cause real problems probably.
But I can't say that I adopt WCAG2.0 4.1.1 when using Matelial Button.

@crisbeto

This comment has been minimized.

Copy link
Member

@crisbeto crisbeto commented Jun 30, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.