Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

265
Views
Material UI Table. How to line up expandable table with parent table

I'm building a table that is gonna display tabular data in multiple groups. The Table will have a main table header that shows what each table cell is. It will also consist of expandable groups which will hold all the tabular data.

Using Material UI, I've looked at the example at https://v4.mui.com/components/tables/#collapsible-table

What they do, is wrap a Collapse component inside a TableCell component. The problem is that at this point, the code inside Collapse has "lost connection" with the parent table structure, as it actually lives within a single table cell. I've tried multiple things, also tried creating a new table within the Collapsecomponent. This does for obvious reasons not work, as everything is created within said table cell.

How can I go about splitting a table into multiple groups, where each group is expandable/collapsible and consist of tabular data, structured after the main table?

I've created a quick mock at https://codesandbox.io/s/material-demo-forked-s3cqv?file=/demo.tsx You can imagine there would be multiple groups following the group in the mock. As you can see, the data doesn't line up with the main table header.

Is this actually accomplishable with Material UI components?

Thank you for reading.
Best regards
Stephan Bakkelund Valois

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!