-
Notifications
You must be signed in to change notification settings - Fork 333
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: Double click needed for expanding/collapsing child elements in FluentNavGroup when prerendering is turned off #2097
Comments
I can't reproduce it. Please supply a ready-to-run repo sample or more refined steps on how to reproduce. For reproducing, I created a new project based on our template with interactivity render mode=server and interactivity location set to global. I added the rendermode change you supplied and added a group with items to the nav menu. |
Thank you Vincent, please see the sample "https://github.com/emetrix/Samples.BlazorFluentUI-FluentNavGroup". As far as I remember I only modified the files App.razor (for rendermode) and NavMenu.razor (for adding FluentNavGroup with subitems). I hope that makes it possible to reproduce the issue. Otherwise please let me know... |
[NavMenu] Revert fix for #2097. Needsa different/better solution
We are reverting this fix for the next release (4.9.0) as there are too many unwanted side effects. As explained in the PR mentioned above, this issue can still easily be resolved by setting the
|
* [NavMenu] Revert fix for #2097. Needsa different/better solution * [Demo] Make NavGroup.Expanded bindable
Hi Vincent, do you think a fix will be possible in one of the next releases or is the mentioned workaround a permanent one ? |
I'm guessing the workaround will be permanent. There are not that many cases where prerendering is being used while the effort we need to take to solve this in a good and solid way is pretty high. |
🐛 Bug Report
In a Blazor SSR project with PreRendering turned off when I first click on a FluentNavGroup Expand Icon the subitems are expanded or collapsed as they should.
But when I then click on the FluentNavGroup Title Text a short flickering occurs and the subitems are not expanded nor collapsed.
The displaying or hiding of the subitems occurs correctly when I click on the Title a second time.
💻 Repro or Code Sample
Turn off prerendering for HeadOutlet and Routes:
@rendermode="new InteractiveServerRenderMode(prerender: false)
Click the expand icon
Child items are expanded
Click the Title Text
A flickering occurs but child item are NOT being collapsed
Click the Title Text a second time
Now the child items are collapsed
This also happens vice versa: When I collapse sub items by the expand icon two clicks on the title text are neccessary to expand the sub items again...
When Blazor Server pre-rendering is turned on it works as expected. But due to different circumstances I can't/don't want to use pre-rendering in my project.
🤔 Expected Behavior
Expanding / Collapsing child items should be done with one click.
😯 Current Behavior
see bug description
💁 Possible Solution
🔦 Context
🌍 Your Environment
The text was updated successfully, but these errors were encountered: