-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Nested submenus in dropdown options #1538
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
Comments
I guess this is already doable using the |
@Papooch please share some example code. |
Actually, I was thinking about it. What is the desired behavior here? Can you select a root node as the choice? Or are those only a separator? Should you be able to expand/collapse the nodes by clicking (that one would not be possible I guess)? Should all the root nodes still show up if none of their child nodes match? |
Can you select a root node as the choice? - Yes |
I tried to put together a quick demo with the first feature: https://jsfiddle.net/5ea7zc8n/16/ |
Thank you very much @Papooch 👍 . i got some idea. |
Currently Options value :
[
{ id : 1, name : 'test'},
{ id : 2, name : 'test 1'},
]
Behaviour :

Expecting behaviour :
[
{ id : 1, name : 'A',children : [{ id : 1, name : 'AA'},{ id : 2, name : 'AB'}]},
{ id : 2, name : 'B', children : [{ id : 1, name : 'test'},{ id : 2, name : 'test 1'}]},
]
The text was updated successfully, but these errors were encountered: