question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cellStylesSticky zIndex doesn't work properly with Material UI Table with stickyHeader prop

See original GitHub issue

The current zIndex interferes with MaterialUI Table with stickyHeader prop.

const cellStylesSticky = {
  position: 'sticky',
  zIndex: 2,
};

Please, increase the zIndex to 3 to solve the issue.

Screenshot 2020-03-17 at 11 41 41 Screenshot 2020-03-17 at 11 41 53

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
GuillaumeJasmincommented, Mar 21, 2020

fixed on v1.1.2 with z-index: 3 . Sorry for the late publish. In the next major version, I will remove hard coded inline style and use only CSS. Thanks for your help 😃

1reaction
GuillaumeJasmincommented, Mar 17, 2020

Ok I get the issue ! I have release 1.1.0 yesterday with new css selector: https://github.com/GuillaumeJasmin/react-table-sticky/releases/tag/v1.1.0

You can temporary try:

[data-sticky-td] {
    position: sticky;
    z-index: 3 !important;
}

I will make a new release today with full CSS support and I think remove the inline zIndex

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to stop the buttons overflowing in material ui table row ...
Try this simple solution .SimpleTable-head-2 { //Code you already have z-index: 3; } .MuiButton-sizeSmall-31 { z-index: 1; }.
Read more >
How to Create a Material-UI Table Sticky Column in Only ...
Material-UI Table does not have a prop for setting 'sticky column'. We will solve that with a quick, light-weight styling solution.
Read more >
Table header defined as sticky header overlays option list o
The option list of the selects may not be overlaid by the sticky header of ... header is defined as non-sticky, the two...
Read more >
Fixed table header and height in Material-UI@next (v1.0.0 ...
Have you tried adding position: 'sticky' to your header TableCell components? I'm not sure it will work with your version of material UI,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found