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

Mobile VoiceOver problem when "step" attribute is too small #509

Closed
jessegreenberg opened this issue May 8, 2019 · 3 comments
Closed

Mobile VoiceOver problem when "step" attribute is too small #509

jessegreenberg opened this issue May 8, 2019 · 3 comments
Assignees

Comments

@jessegreenberg
Copy link
Contributor

Discovered while working on #499, and required for phetsims/gravity-force-lab-basics#119. <input type="range"> doesn't receive any input events from VoiceOver when the step attribute is too small relative to the range of the slider. In gravity force lab basics, the step attribute is 1/1000000000 of the range. If the step attribute is made larger to be 1/100000 of the range, input events are received. Currently, the step attribute is determined by

          // The step attribute must be non zero for the accessible input to receive all accessibility events, and
          // only certain values are allowed depending on the step size, or else the AT will announce values as
          // "Invalid". If the step size is equal to the precision of the slider readout, all values are allowed.
          this.setAccessibleAttribute( 'step', Math.pow( 10, -this.a11yDecimalPlaces ) );

This line was determined to be the best in #413 for non-mobile AT. We should return there for history.

@jessegreenberg
Copy link
Contributor Author

This isn't working because the step is using different units than the physical Property in GFLB. step is in billions of kg, while the range is in kg.

@jessegreenberg
Copy link
Contributor Author

I tried step="any" again (which is a valid DOM attribute) from #413, but it does't work with iOS VoiceOver either.

@jessegreenberg
Copy link
Contributor Author

I workaround has been added with the above commit, along with a lot of documentation that describes PhET's slider conquest until this point. Closing this issue, since discussion can continue in the related #495

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