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

Stripe rows tables via theme and other theme nested overrides #15476

Closed
dy opened this issue Apr 24, 2019 · 2 comments
Closed

Stripe rows tables via theme and other theme nested overrides #15476

dy opened this issue Apr 24, 2019 · 2 comments
Labels
component: table This is the name of the generic UI component, not the React module! customization: theme Centered around the theming features

Comments

@dy
Copy link

dy commented Apr 24, 2019

Oftentimes we have a situation in project when we need to redefine nested elements styles via theme. (We tend to use theme instead of styling each component individually because we need extensive skinning support).

The cases:

  • defining different ripple color for IconButton hover/active states.
  • defining TableBody > TableRow stripe pattern (not just generic TableRow, eg. TableHead > TableRow should not be affected)
  • reduce icon size for ListItemIcon in MenuItem

For now that seems to be impossible to do.

We'd expect something like

    MuiTableBody: {
      MuiTableRow: {
        root: {
          "&:nth-of-type(odd)": {
            backgroundColor: "rgba(251,251,251,1)"
          }
        }
      },
    },

I hoped there could be a simple nesting introduced to overrides, since class selectors are meaningless due to CSS mangling in production.

Related: #5286

@oliviertassinari @eps1lon @mbrookes

@oliviertassinari
Copy link
Member

@dy Could it be a duplicate with #15002?

@dy
Copy link
Author

dy commented Apr 25, 2019

Yes, I think that's it. Ok, just listed additional cases then.

@dy dy closed this as completed Apr 25, 2019
@oliviertassinari oliviertassinari added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Dec 20, 2022
@zannager zannager added component: table This is the name of the generic UI component, not the React module! customization: theme Centered around the theming features and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: table This is the name of the generic UI component, not the React module! customization: theme Centered around the theming features
Projects
None yet
Development

No branches or pull requests

3 participants