VE-654: fix collapsing dialog menus