react-native-paper
react-native-paper copied to clipboard
fix: Update accessibilityValue handling in ProgressBar to also use the animatedValue
Set the accessibilityValue if animatedValue is set.
Motivation
We noticed that the accessibilityValue is probably not set when only setting the animatedValue. Because the progress and animatedValue should not be used in parallel, we can see here that animatedValue is ignored by the accessibilityValue.
accessibilityValue={
indeterminate
? {}
: { min: 0, max: 100, now: Math.round(progress * 100) }
}
Related issue
n.a.
Test plan
I added tests to check the accessibilitValue of the ProgressBar.
Hey @KevinvdBurg, thank you for your pull request 🤗. The documentation from this branch can be viewed here.