Material-table filtering:筛选单元格样式的背景色不应用于整行。为行选择创建的列有自己的样式,我不知道如何覆盖它。
代码示例:https://codesandbox.io/s/material-table-filter-selection-forked-t9vb54?file=/src/App.js
只需将此添加到您的style.css
文件:
.App
.MuiTableBody-root .MuiTableRow-root:first-of-type {
background: #6ABAC9;
}
你也可以删除这个道具:
filterCellStyle: {
backgroundColor: "#6ABAC9"
}