knownasilya / ember-toggle

Checkbox based Toggle Switches for Ember
http://knownasilya.github.io/ember-toggle/
MIT License
112 stars 52 forks source link

A11Y error due to tabindex > 0 #118

Closed Willibaur closed 5 years ago

Willibaur commented 5 years ago

Thanks for this awesome addon.

Below you will see an A11Y error related, it was catched by ember-A11Y-testing it seems an easy one to fix on :point_right: x-toggle/component.js

image

I'm happy to create a PR if you agree this should be tabindex: '0'.

Thanks

knownasilya commented 5 years ago

Could probably just remove the tabindex all together and users can apply those as needed.

Willibaur commented 5 years ago

I'm not sure, as a general A11Y rule, it should be tabindex: 0, so what about to set it to that value by default within the addon, but give the option to the user to modify as required @knownasilya like we do with offLabel property ?

knownasilya commented 5 years ago

The user can already set it, e.g. {{x-toggle tabindex='0'}}

knownasilya commented 5 years ago

I'll change it to '0'

Willibaur commented 5 years ago

Thanks for the fix @knownasilya

knownasilya commented 5 years ago

Released in 5.3.1