-
Notifications
You must be signed in to change notification settings - Fork 270
feat: Add prop to skip navigation on nodes #375
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
feat: Add prop to skip navigation on nodes #375
Conversation
Code Climate has analyzed commit 62d60f1 and detected 0 issues on this pull request. View more on Code Climate. |
Pull Request Test Coverage Report for Build 1380
💛 - Coveralls |
I don't think we need a new prop for this. Skipping all keyboard actions on hidden nodes can be the default behavior. @ellinge Any apparent concerns if we do this? |
Also, please add tests for these changes. |
no sure if I understand, more tests using that prop? |
we need that because on
|
@isuscbrmid would you be ok with something like this #371 ? Any nodes that were initially hidden in the data will remain hidden (and skipped by the keyboard navigation). Unless of course you want a completely hidden "fake" node, and then you can label it "" which makes it is also unsearchable. |
Not sure I understand this bit. In general, I'm usually hesitant to add more props like these ones as it increases the maintenance area in general while it provides little value to only a handful of edge cases. You also have to analyse the impact of this change from an accessibility standpoint. Also, can we have a CodeSandbox to reproduce the problem? |
We cannot use the "hide" prop in each node, since it is overwritten when "restoringDefaults".
|
yes it seems it can be the solution, I will double check if this one work, will close my Pr |
I guess I'm confused because there is no such prop; or a method called |
sorry i write down wrongly the name, here the hidde is set to false, even if we pass a hidde = true at the beginning.. So only in the beginning it will hidde the node, but after closing the dropdown this method is triggered removing the hidde = true
|
I wil test @MJRuskin PR I thing the way he did avoid that overwrite can help me |
What does it do?
Currently if I want to hide a node, I can do this with css, but the keyboard feature is able to reach those nodes. We cannot use the "hide" prop in each node, since it is overwritten when "restoringDefaults".
Fixes # (issue)
Add a custom/optional prop to the nodes to disable keyboard navigation on them.
Type of change
Please delete options that are not relevant.
Checklist: