1 Answer, 1 is accepted
Hello, Andrei,
Yes, this is a supported scenario in the KendoReact DropDownTree as well.
I made an example showcasing this:
https://stackblitz.com/edit/react-gr9hn2?file=app/main.jsx
Regards,
Stefan
Progress Telerik
Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.
https://stackblitz.com/edit/react-gr9hn2-mwtird?file=app/main.jsx
Both can be achieved using the controlled mode of the component where we can control the value and decide when to update it.
I updated example to showcase it:
https://stackblitz.com/edit/react-gr9hn2?file=app%2Fmain.jsx
example wasn't updated
Please check this one https://stackblitz.com/edit/react-gr9hn2-cwsgus?file=app%2Fmain.jsx
There are some issues with StackBlitz these days I will double check.
This is expected as the list is closed on click and not only when the value is changed.
The developer can control when the component is open/close with the opened property:
https://www.telerik.com/kendo-react-ui/components/dropdowns/api/DropDownTreeProps/#toc-opened
This will require using a custom logic on when the open it and when to close it.
For example, we can use the onOpen and onClose events. Then during the onClose events a custom logic has to be used to locate these cases where we will not close it:
https://www.telerik.com/kendo-react-ui/components/dropdowns/api/DropDownTreeProps/#toc-onopen
https://www.telerik.com/kendo-react-ui/components/dropdowns/api/DropDownTreeProps/#toc-onclose