MunifTanjim / nui.nvim

UI Component Library for Neovim.
MIT License
1.62k stars 57 forks source link

Event on tree node selection change #386

Closed oclay1st closed 3 weeks ago

oclay1st commented 3 weeks ago

Hello, thanks for this amazing plugin, Is there any way to react on tree node selection? .Thanks in advance

MunifTanjim commented 3 weeks ago

What do you mean by tree node selection? nui.nvim doesn't provide any selection feature for tree nodes. 🤔

oclay1st commented 3 weeks ago

Sorry, I'm new developing plugins for Neovim and my issue is probably not related to nui, but I wanted to create an interface where whenever any node in the left tree is selected, the right tree is updated. Screenshot_20240926_134724 I managed to do it by reacting to the CursorMoved event. Do you think that is an acceptable solution?. Thanks

MunifTanjim commented 3 weeks ago

I managed to do it reacting to the CursorMoved event. Do you think that is an acceptable solution?

Ah, yes. That is what I would have suggested. Using CursorMoved event is the solution.

oclay1st commented 3 weeks ago

Congrats for the amazing work... Closing this issue!!!