Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: The OnAction event is incorrectly fired on the first render of FluentNavMenu #803

Closed
sajadkardel opened this issue Sep 28, 2023 · 3 comments

Comments

@sajadkardel
Copy link

Untitled

@sajadkardel sajadkardel changed the title fix: the 'OnAction' event is incorrectly fired on the first render of 'FluentNavMenu' fix: The OnAction event is incorrectly fired on the first render of FluentNavMenu Sep 28, 2023
@vnbaaij
Copy link
Collaborator

vnbaaij commented Sep 29, 2023

Please supply proper repo steps. We can't work from an image...

@sajadkardel
Copy link
Author

sajadkardel commented Sep 30, 2023

Please supply proper repo steps. We can't work from an image...

Sure. Sorry for the lack of information. I’m currently working on this repo and wanted to create a responsive NavMenu. For example, when the screen size is mobile, the menu should be closed after selecting one of the items…
I noticed that after selecting each item (or changing the address), the first menu item is selected automatically. This changes the address and re-fires the OnAction event.
You can try it out on NavMenu.razor in ...\HiCode.Blog\Client\HC.Web\Shared\NavMenu.razor.
(For now, I have stopped using the OnAction event and have implemented a responsive NavMenu using the OnLocationChanged event.)

@vnbaaij
Copy link
Collaborator

vnbaaij commented Oct 4, 2023

We are replacing the NavMenu with a new NavLink based version in version 3.2. See PR #819

@vnbaaij vnbaaij closed this as completed Oct 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants