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

[RFC] Remove enableColorScheme prop from CssBaseline #42695

Open
o-alexandrov opened this issue Jun 20, 2024 · 3 comments
Open

[RFC] Remove enableColorScheme prop from CssBaseline #42695

o-alexandrov opened this issue Jun 20, 2024 · 3 comments
Assignees
Labels
component: CssBaseline The React component RFC Request For Comments v6.x

Comments

@o-alexandrov
Copy link

o-alexandrov commented Jun 20, 2024

What's the problem?

There is an unused prop enableColorScheme in CssBaseline which gives an option to choose something that does not make any sense.

From #42640 (comment)

What’s the need for enableColorScheme: false?
In other words, why would anyone want the browser to show light color scheme for a dark theme?

The existence of enableColorScheme led to the introduction of an extra hanging span HTML element.

What are the requirements?

Remove enableColorScheme prop

What are our options?

In Material UI v7+, you might consider to remove the enableColorScheme prop.

Search keywords: enableColorScheme, CssBaseline

@o-alexandrov o-alexandrov added RFC Request For Comments status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jun 20, 2024
@zannager zannager added the component: CssBaseline The React component label Jun 20, 2024
@oliviertassinari
Copy link
Member

The prop was added to avoid breaking changes, as far as I remember.

This issue looks like point 4 of #38507 but where we also remove the prop.

@o-alexandrov
Copy link
Author

o-alexandrov commented Jun 20, 2024

@oliviertassinari thank you for linking the issue and specifying the point 4. Would you like to reword the 4th point there, so it says removal, instead of setting the value to true by default?

  • if yes, then I’d happily suggest to close this issue as this one would become a duplicate

@siriwatknp
Copy link
Member

I think we can remove it before the stable release of v6. It's a breaking change but I think CssBaseline is used once in a project.

@siriwatknp siriwatknp added v6.x and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jun 26, 2024
@siriwatknp siriwatknp added this to the Material UI: v6 milestone Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: CssBaseline The React component RFC Request For Comments v6.x
Projects
None yet
Development

No branches or pull requests

5 participants