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

196
Views
Styling nested MUI TreeView and TreeItem not working as expected

I'm using TreeView, TreeItem of material ui. I'm trying to style conditionally each node (selected, hover, focus). actually what I'm trying to do is that only node that not disabledButton (props that come from outside) will be in right color. only node that selectable will be in active color (expand node not means that node is selectable). something like this example enter image description here

I did this example, but the behavior is really weird, sometimes the "child-4" looks like the style of disabledButton even I sent the right props, maybe because it nested props, sometimes the other nested not get the right colors of the hover, focus and selected.. link for example (with colors) example with different colors

I want it to be in real colors also with the theme (active should be like blue color, hover gray) so I created this example. example with theme colors sometimes it works as expected and sometimes is not. I looked in this issue but it's not like my example but there it uses in classes but I don't want to send this way

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!