@@ -126,11 +126,29 @@ const dataTableTheme = (theme: Theme, backgroundColor?: string) =>
126
126
typography : {
127
127
fontFamily : theme . typography . fontFamily
128
128
} ,
129
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
130
+ //@ts -ignore
131
+ palette : {
132
+ text : {
133
+ primary : theme . palette . text . default ,
134
+ secondary : theme . palette . text . secondary
135
+ } ,
136
+ background : {
137
+ default : backgroundColor || theme . palette . background . constant ?. table ,
138
+ paper : backgroundColor || theme . palette . background . constant ?. table
139
+ }
140
+ } ,
129
141
components : {
142
+ MuiTableCell : {
143
+ styleOverrides : {
144
+ root : {
145
+ borderBottom : `1px solid ${ theme . palette . border . default } `
146
+ }
147
+ }
148
+ } ,
130
149
MuiPaper : {
131
150
styleOverrides : {
132
151
root : {
133
- background : backgroundColor || theme . palette . background . default ,
134
152
maxWidth : '-moz-available'
135
153
}
136
154
}
@@ -141,24 +159,19 @@ const dataTableTheme = (theme: Theme, backgroundColor?: string) =>
141
159
width : '-webkit-fill-available' ,
142
160
'@media (max-width: 500px)' : {
143
161
wordWrap : 'break-word'
144
- } ,
145
- background : backgroundColor || theme . palette . background . constant ?. table ,
146
- color : theme . palette . text . default
162
+ }
147
163
}
148
164
}
149
165
} ,
150
166
MUIDataTableHeadCell : {
151
167
styleOverrides : {
152
168
data : {
153
169
fontWeight : 'bold' ,
154
- textTransform : 'uppercase' ,
155
- color : theme . palette . text . default
170
+ textTransform : 'uppercase'
156
171
} ,
157
172
root : {
158
173
fontWeight : 'bold' ,
159
- textTransform : 'uppercase' ,
160
- color : theme . palette . text . default ,
161
- backgroundColor : backgroundColor || theme . palette . background . constant ?. table
174
+ textTransform : 'uppercase'
162
175
}
163
176
}
164
177
} ,
@@ -177,7 +190,6 @@ const dataTableTheme = (theme: Theme, backgroundColor?: string) =>
177
190
intermediate : false ,
178
191
color : 'transparent' ,
179
192
'&.Mui-checked' : {
180
- color : theme . palette . text . default ,
181
193
'& .MuiSvgIcon-root' : {
182
194
width : '1.25rem' ,
183
195
height : '1.25rem' ,
@@ -207,30 +219,6 @@ const dataTableTheme = (theme: Theme, backgroundColor?: string) =>
207
219
}
208
220
}
209
221
} ,
210
- MuiTableCell : {
211
- styleOverrides : {
212
- body : {
213
- color : theme . palette . text . default
214
- } ,
215
- root : {
216
- borderBottom : `1px solid ${ theme . palette . border . default } `
217
- }
218
- }
219
- } ,
220
- MUIDataTablePagination : {
221
- styleOverrides : {
222
- toolbar : {
223
- color : theme . palette . text . default
224
- }
225
- }
226
- } ,
227
- MUIDataTableSelectCell : {
228
- styleOverrides : {
229
- headerCell : {
230
- background : backgroundColor || theme . palette . background . constant ?. table
231
- }
232
- }
233
- } ,
234
222
MuiInput : {
235
223
styleOverrides : {
236
224
root : {
0 commit comments