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

MudThemeProvider: Set clearer boundary between MudThemeProvider and M… #3654

Merged
merged 1 commit into from
Jan 2, 2022

Conversation

just-the-benno
Copy link
Contributor

@just-the-benno just-the-benno commented Jan 2, 2022

Setting clearer boundaries between MudTheme and MudThemeProvider

Description

Currently, there is a bit of confusion between the IsDarkMode property of a MudTheme and the property IsDarkMode of the MudThemeProvider. The latter can create a condition where the dark mode is enabled in the Themeprovider but not in the theme itself, which creates "unstable" rendering. With this PR, the theme itself is only providing a dark palette but the ThemeProvider "decides" if it should be used.

How Has This Been Tested?

Visually. Unit tests were neither changed nor newly created. This will be done when there is a major change regarding themes.

Checklist:

✔️ The PR is submitted to the correct branch (dev).
✔️ My code follows the code style of this project.
❌ I've added relevant tests.

@mudbot mudbot bot added bug Something does not work as intended/expected needs review labels Jan 2, 2022
@Garderoben Garderoben added this to the 6.0.4 milestone Jan 2, 2022
@codecov
Copy link

codecov bot commented Jan 2, 2022

Codecov Report

Merging #3654 (848f817) into dev (f1e65cd) will increase coverage by 0.00%.
The diff coverage is 97.67%.

Impacted file tree graph

@@           Coverage Diff           @@
##              dev    #3654   +/-   ##
=======================================
  Coverage   90.37%   90.38%           
=======================================
  Files         333      333           
  Lines       10487    10545   +58     
=======================================
+ Hits         9478     9531   +53     
- Misses       1009     1014    +5     
Impacted Files Coverage Δ
src/MudBlazor/Themes/MudTheme.cs 100.00% <ø> (ø)
...Components/ThemeProvider/MudThemeProvider.razor.cs 98.22% <97.67%> (-1.78%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f1e65cd...848f817. Read the comment docs.

@Garderoben Garderoben merged commit 1251cdf into MudBlazor:dev Jan 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something does not work as intended/expected needs review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants