Clicking on tree menu items instead of the arrow for expanding

Hello,

I am using the tree component as menu. However the menu items will only be expanded when clicking on the arrow.
Clicking on the menu items itself doesn’t have any effects by default.

What’s the easiest way to implement the expanding feature to the menu items ?

Hi,

Add a ValueChangeListener that calls expandItem(event.getProperty().getValue()) and set your tree to be immediate (setImmediate(true)).

HTH,
/Jonatan

Thanks again !