MudMenu: Invoke OnClick before closing the menu
Merged
DA
4mo ago+38+38+01234567890123456789-6-6-0123456789
Fixes #6349.
MudMenuItem.OnClickHandlerAsync closed the menu (ParentMenu.CloseAllMenusAsync) before awaiting the user's OnClick (and Href navigation). A component wrapping the item could therefore be disposed while the user's async OnClick was still awaiting, so the continuation ran on a disposed component or never completed. This invokes OnClick/navigation first and closes the menu afterwards.
Checklist:
- I've read the contribution guidelines
- My code follows the style of this project
- I've added or updated relevant unit tests