Collapse menu when menu item is clicked and selected page is open

I would like to collapse the side panel programmatically when clicking on a menu item that opens a page. How do I do this? I could not find any click listener for menu item in SideMenu API. I’ve also tried to use onUrlParamsChanged in ExtMainScreen but it does not detect any event.