Skip to content

Conversation

@siriwatknp
Copy link
Member

@siriwatknp siriwatknp commented Aug 29, 2024

closes #43508, closes #43533

@siriwatknp siriwatknp requested a review from DiegoAndai August 29, 2024 15:02
@siriwatknp siriwatknp added type: bug It doesn't behave as expected. package: material-ui customization: theme Higher level theming customizability. labels Aug 29, 2024
@mui-bot
Copy link

mui-bot commented Aug 29, 2024

Netlify deploy preview

https://deploy-preview-43518--material-ui.netlify.app/

Bundle size report

Details of bundle changes (Toolpad)
Details of bundle changes

Generated by 🚫 dangerJS against 3df87c5

if (theme.palette.mode === 'light') {
theme.colorSchemes.light = { palette: theme.palette } as ColorSystem;
theme.colorSchemes.light = {
...(colorSchemesInput.light !== true && colorSchemesInput.light),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this covered by line 100 above?

Copy link
Member Author

@siriwatknp siriwatknp Aug 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without this line, the other fields that are not palette will be overridden because of the reassigning theme.colorSchemes.light.

@siriwatknp siriwatknp requested a review from DiegoAndai August 30, 2024 12:56
@siriwatknp siriwatknp merged commit e13f1c9 into mui:master Sep 2, 2024
@ksn5
Copy link

ksn5 commented Sep 2, 2024

@siriwatknp Thank you for addressing the issue. Could you please let me know when we can expect the patch version to be released with this fix?

@DiegoAndai
Copy link
Member

@ksn5 this should be available in the next patch version, 6.0.2, which should come out this week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

customization: theme Higher level theming customizability. type: bug It doesn't behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[docs] Adding custom light and dark themes always render dark theme [material-ui] Unable to customize palettes of colorSchemes

4 participants