-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[DataGrid] The CSS customization section is misleading #1163
Comments
I also just hit this trying to add I'll use global CSS as a workaround for now, but am otherwise using CSS modules so having a working |
@holdenmatt We only plan to include |
I'm adding some CSS to customize a few classes like I ended up using a global SCSS file with nested selectors, which works fine. Slight preference for having a method that would let me define scoped styles with my component rather than globally. But if not, this works fine. |
@holdenmatt Correct. If you are used to CSS modules, you could still apply the root class name to the root of the data grid, and then, use global descendant CSS selectors to target what you need. For instance, to get something like this at the end: .a12vt .MuiDataGrid-cell {
background-color: red;
} <DataGrid className="a12vt" /> |
I have added the "good to take" label as the solution should be as simple as:
|
Current Behavior 😯
Expected Behavior 🤔
Context 🔦
The issue was reported by a user under the wrong channel ([email protected]).
Your Environment 🌎
`npx @material-ui/envinfo`
Order id 💳
21793
The text was updated successfully, but these errors were encountered: