Comments (3)
However, if the expected behavior is to never be able to have keyboard focus on to a disabled pressable, then there are likely some changes we need to make to the pressable behavior, similar to the issue linked above.
That would be my expectation. A disabled Pressable should not be tabbed to.
Compare with WinUI. Launch their gallery, got the button page, and click the "Disable button" checkbox. Then try to tab around. That Button cannot be selected with tab navigation.
Note that there is a separate mechanism for inspecting disabled components, scan mode. With that you should be able to see the component. But not normal tab navigation.
So that's the issue here. Our disabled item is still tab navigatable.
from react-native-gallery.
I tried debugging this issue and it looks like narrator is not focusing on the prop because the disabled property is set. If I remove the disabled={true}
prop from the pressable example, then narrator shifts focus onto the disabled pressable example. This may be an issue caused by microsoft/react-native-windows#12457, where the platform code isn't recognizing the disabled prop, and is therefore allowing keyboard focus on to the disabled prop.
Not sure what the exact expected behavior is for a disabled pressable. If it is expected that you can focus on to a disabled pressable, but cannot press it, then it looks like this is a narrator issue and potentially outside our scope. However, if the expected behavior is to never be able to have keyboard focus on to a disabled pressable, then there are likely some changes we need to make to the pressable behavior, similar to the issue linked above.
@chrisglein @chiaramooney adding you for additional perspective.
from react-native-gallery.
I tested a disabled Pressable on a simple Expo snack here, and it looks like on RN core, when disabled={true}
, you can't focus on the pressable at all through keyboard tab input. Going to assume that's the expected behaviour, which means there's an issue with the pressable code not recognizing the disabled
prop, similar to microsoft/react-native-windows#12457.
from react-native-gallery.
Related Issues (20)
- [React Native Gallery -> Print]: Color contrast ratio for 'Print PDF' is 3.56:1 which is less than minimum requirement of 4.5:1.
- [React Native Gallery -> Pressable]: Action is defined for disabled button i.e., for 'Disabled Pressable' button present under "A disabled Pressable component".
- [React Native Gallery -> Popup]: Keyboard focus is getting reset on invoking 'Close popup' button.
- [React Native Gallery -> VirtualizedList]: Unable to select/unselect multiple list items present under "A VirtualizedList with multiple selection support" group in one go using keyboard.
- [React Native Gallery]: Visual looking headings,"View page code at GitHub", "Documentation", "Feedback" are not defined as heading. HOT 3
- [React Native Gallery -> Track Player]: The Name property of a focusable element must not be null. HOT 1
- [React Native Gallery -> Print]: Accessible name does not match with visible name for 'Print PDF' button.
- [React Native Gallery -> Sensitive Info]: Focusable sibling elements are having the same Name and LocalizedControlType.
- [React Native Gallery -> VirtualizedList]: Narrator fails to announce the name of the combo box.
- Page Badges aren't easy to see to read in dark mode (nor do they look exactly right in light mode) HOT 3
- There's no native ARM64 build
- Gallery on Fabric
- Add ActivityIndicator Example Page HOT 1
- Add stack navigation using navigation stub from Create app
- Add Home page
- Badges on fabric version of app don't have icons displaying
- Documentation tile gets cut off on example pages in Gallery Fabric app HOT 1
- Add Home page with all planned components HOT 1
- Community Module info button not legible in dark theme HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-gallery.