Skip to content

MudTheme: Don't cache supplied Theme parameter#12559

Merged
ScarletKuro merged 1 commit intoMudBlazor:devfrom
ScarletKuro:theme_init_fix
Jan 28, 2026
Merged

MudTheme: Don't cache supplied Theme parameter#12559
ScarletKuro merged 1 commit intoMudBlazor:devfrom
ScarletKuro:theme_init_fix

Conversation

@ScarletKuro
Copy link
Member

@ScarletKuro ScarletKuro commented Jan 27, 2026

Possible fix for #12557
Well, it should get calculated on OnInitialized and recalculated on changes via OnParametersSetAsync, but if my theory is correct in the issue above, the OnInitialized might be ignored on reopen.
Was probably a bad idea anyway, it's always more robust to read Theme directly all the time and removes the need of OnParametersSetAsync + OnInitialized for that logic.

Checklist:

  • I've read the contribution guidelines
  • My code follows the style of this project
  • I've added or updated relevant unit tests

@mudbot mudbot bot added the bug Unexpected behavior or functionality not working as intended label Jan 27, 2026
@ScarletKuro ScarletKuro changed the title MudTheme: Don't cache supplied Theme property MudTheme: Don't cache supplied Theme parameter Jan 27, 2026
@ScarletKuro ScarletKuro merged commit 9f29728 into MudBlazor:dev Jan 28, 2026
7 checks passed
@ScarletKuro ScarletKuro deleted the theme_init_fix branch January 28, 2026 11:33
This was referenced Feb 20, 2026
This was referenced Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Unexpected behavior or functionality not working as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

iOS 26+ Safari PWA: MudTheme resets to default after app is closed and reopened (Add to Home Screen)

1 participant