5

Which component i must use, to obtain a highlight in a row when the mouse is over a row, using the material-table component?

I dint find any property or which component override to obtain that.

Thanks in advace for your time Best Regards

Here is the code https://codesandbox.io/s/yv13zjr9w9

Orestes
  • 637
  • 1
  • 4
  • 19

2 Answers2

3

you could create a css to highlight row

tr:hover{
background:gray;
}

Refer to sandbox

https://codesandbox.io/s/y686o6n9

Abdulla Thanseeh
  • 9,438
  • 3
  • 11
  • 17
1

If you want only this table to have an hover effect, wrap it in another element or give it a class as in the example above:

https://codesandbox.io/s/4wkpp98z69

.myTable tr:hover {
  background-color: red;
}
Mosè Raguzzini
  • 15,399
  • 1
  • 31
  • 43