ember-radio-button
ember-radio-button copied to clipboard
`aria-checked` not being set on `master` branch
I upgrade my Ember app to use the latest commit on the master
branch of ember-radio-button
to remove all the deprecation warnings. It seems that the latest code on the master
branch no longer sets the aria-checked
attribute.
{{! component usage }}
<RadioButton @value='yes' @groupValue='yes' @name='response' />
{{! `master` branch rendered HTML }}
<input name="response" type="radio" value="yes">
{{! version 2.0.1 rendered HTML }}
<input aria-checked="true" name="response" type="radio" value="yes">
I've reproduced this issue with both an Ember 3.28 app as well as a 4.1 app.
I created PR https://github.com/yapplabs/ember-radio-button/pull/115 to add the test assertions to show that they are currently failing to set the aria-checked
attribute.
I'm wondering if when using the radio button without the yielded content, it should be setting the @checked
argument of the component rather than the checked
HTML attribute of the underlying input
field.
See: https://github.com/yapplabs/ember-radio-button/blob/74036d5cade335c19d4d61439c6ea7d90eee288c/addon/components/radio-button.hbs#L30
This is fixed in 3.0.0-beta.1 via https://github.com/yapplabs/ember-radio-button/pull/141