X Tutup
The Wayback Machine - https://web.archive.org/web/20211008120155/https://github.com/angular/components/issues/20719
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

bug(Slider): Jaws and NVDA incorrectly announcing decimal numbers #20719

Closed
Aivanic opened this issue Oct 5, 2020 · 2 comments
Closed

bug(Slider): Jaws and NVDA incorrectly announcing decimal numbers #20719

Aivanic opened this issue Oct 5, 2020 · 2 comments

Comments

@Aivanic
Copy link

@Aivanic Aivanic commented Oct 5, 2020

Reproduction

https://stackblitz.com/edit/components-issue-nr5zgy?file=src%2Fapp%2Fexample-component.html
(stackblitz have weird behaviour, you have to add tabindex="0" for working example)

Steps to reproduce:

  1. Enable Jaws or NVDA
  2. Focus slider
  3. Move slider

Expected Behavior

Screen reader announce 0.2

Actual Behavior

Screen reader announcing e.g. 0.20000068

Environment

  • Angular: V. 10.1.3
  • CDK/Material: V. 10.2.3
  • Browser(s): Google Chrome
  • Operating System (e.g. Windows, macOS, Ubuntu): Windows 10
@crisbeto crisbeto self-assigned this Oct 5, 2020
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 5, 2020
It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 5, 2020
It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
wagnermaciel pushed a commit that referenced this issue Oct 7, 2020
…ues (#20721)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.
wagnermaciel added a commit that referenced this issue Oct 7, 2020
…ues (#20721)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.

(cherry picked from commit d93e16f)
@crisbeto
Copy link
Member

@crisbeto crisbeto commented Oct 9, 2020

Reopening since the fix had to be reverted.

@crisbeto crisbeto reopened this Oct 9, 2020
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 9, 2020
It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
jelbourn pushed a commit that referenced this issue Oct 20, 2020
…ues (#20760)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.
jelbourn added a commit that referenced this issue Oct 20, 2020
…ues (#20760)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.

(cherry picked from commit 19f5f5c)
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 23, 2020
It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
crisbeto added a commit to crisbeto/material2 that referenced this issue Oct 26, 2020
It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
annieyw pushed a commit that referenced this issue Nov 4, 2020
…ues (#20870)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.
annieyw added a commit that referenced this issue Nov 4, 2020
…ues (#20870)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.

(cherry picked from commit 9f4415e)
annieyw added a commit that referenced this issue Nov 4, 2020
…ues (#20870)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes #20719.

(cherry picked from commit 9f4415e)
@angular-automatic-lock-bot
Copy link

@angular-automatic-lock-bot angular-automatic-lock-bot bot commented Nov 20, 2020

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Nov 20, 2020
wagnermaciel added a commit to wagnermaciel/components that referenced this issue Jan 14, 2021
…ues (angular#20721)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
wagnermaciel added a commit to wagnermaciel/components that referenced this issue Jan 14, 2021
…ues (angular#20760)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
wagnermaciel added a commit to wagnermaciel/components that referenced this issue Jan 14, 2021
…ues (angular#20870)

It looks like some screen readers announce the value of a slider by calculating the
percentage themselves using the `aria-valuemin`, `aria-valuemax` and `aria-valuenow`.
The problem is that they don't round down the decimals so for a slider between 0 and 1
with a step of 0.1, they end up reading out values like 0.20000068. These changes work
around the issue by setting `aria-valuetext` to the same value that we shown in the thumb
which we truncate ourselves.

Fixes angular#20719.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
X Tutup