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

Calling NavigationManager.Refresh breaks Toolbar and Tooltips UI in .NET 8 Blazor Server. #489

Open
melittleman opened this issue Jul 19, 2024 · 1 comment

Comments

@melittleman
Copy link

Hi there, firstly thank you for making such a great library! It really has made working with the charts so much easier in a .NET ecosystem.

We have come across a probably very niche issue where calling the NavigationManager.Refresh() method seems to break the UI of the charts, specifically the Toolbar and Tooltip components from what we can see.

We are using the NavigationManager.Refresh() call to update components once HttpContext information has changed e.g. 'dark mode' state being stored in a Cookie, or page / offset information being stored in the URL so it would be great if the chart component could simply hold it's state (I did try to use 'data-permanent' or provide an @key attribute with no luck).

Failing that I think having to manually call ApexChart.RenderAsync() would be perfectly acceptable, however when I tried this in an overridden OnAfterRenderAsync it worked initially but then reverted to the broken UI after the Task had completed.

Please see the attached .NET 8 Blazor Server Web App project that reproduces this issue. Simply click the 'Refresh' button on the Home page. Please let me know if there's any more information needed or if in fact I'm just doing something stupid!

ApexChartsTesting.zip

Thanks,
Matt

@joadan
Copy link
Member

joadan commented Oct 10, 2024

Hi,

Not exactly sure what the issue is here but we have started work on a ChartService that would make it easier to set global options.
#518

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