MudThemingProvider: MudThemeProvider without MudPopoverProvider#8102
MudThemingProvider: MudThemeProvider without MudPopoverProvider#8102mikes-gh merged 1 commit intoMudBlazor:devfrom
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #8102 +/- ##
=======================================
Coverage 88.11% 88.11%
=======================================
Files 394 394
Lines 11760 11760
Branches 2384 2384
=======================================
Hits 10362 10362
Misses 871 871
Partials 527 527 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
688f62f to
897b56a
Compare
henon
left a comment
There was a problem hiding this comment.
Good idea to derive the old ThemeProvider from the new ThemingProvider. LGTM
|
As a dirty workaround you can show an message in the ide with
|
|
This merge broke backwards compatibility. If you have a library that was built bevor the MudThemingProvider was introduced it can't be used after this update. Blazor just doesn't recognize components that inherit from BaseMudThemeProvider anymore. Would be nice to note this change as a breaking change. Example repo: https://github.com/HoeblingerDaniel/MudBlazorBugShowcase |
|
Sorry @HoeblingerDaniel, we didn't hink about that. If'd known it will break user code we wouldn't have done it |
Description
A long time ago we added
<MudPopoverProvider/>and wanted to ship it without user code changes.Since everyone had
<MudThemeProvider/>in their code we decided to add it to that provider so the new feature would light up automatically.This has proved to be problematic in net8 where new scenarios would require these providers to be separate.
A common requirement would be to use
<MudThemingProvider/>in the layout which could be statically rendered whilst requiring<MudPopoverProvider/>in an interactive page. Install the MudBlazor.Templates for some examples of the render mode scenarios.There is a way of disabling
<MudPopoverProvider/>inside<MudThemeProvider/>but its not intuitive.So we decided after much discussion to create a new provider
<MudThemingProvider/>(note theing) in order to not break everyone who is relying on the current behaviour.Unfortunately we can't obsolete a component due to it not being supported in razor.
One idea is to Log a warning at runtime.
I'd be interested if anyone has a better solution.
How Has This Been Tested?
<MudThemeProvider/>is now inherited from<MudThemingProvider/>so the current tests should test both.@henon can you think of some additional tests we need?
Types of changes
Checklist:
dev).