1
+ import { type Interpolation , type Theme } from "@emotion/react" ;
1
2
import Button from "@mui/material/Button" ;
2
3
import Link from "@mui/material/Link" ;
3
- import { makeStyles } from "@mui/styles" ;
4
4
import Table from "@mui/material/Table" ;
5
5
import TableBody from "@mui/material/TableBody" ;
6
6
import TableCell from "@mui/material/TableCell" ;
@@ -20,10 +20,10 @@ import {
20
20
TableRowSkeleton ,
21
21
} from "components/TableLoader/TableLoader" ;
22
22
import { UserAvatar } from "components/UserAvatar/UserAvatar" ;
23
- import { FC } from "react" ;
23
+ import { type FC } from "react" ;
24
24
import { Link as RouterLink , useNavigate } from "react-router-dom" ;
25
25
import { Paywall } from "components/Paywall/Paywall" ;
26
- import { Group } from "api/typesGenerated" ;
26
+ import type { Group } from "api/typesGenerated" ;
27
27
import { GroupAvatar } from "components/GroupAvatar/GroupAvatar" ;
28
28
import { docs } from "utils/docs" ;
29
29
import Skeleton from "@mui/material/Skeleton" ;
@@ -44,7 +44,6 @@ export const GroupsPageView: FC<GroupsPageViewProps> = ({
44
44
const isLoading = Boolean ( groups === undefined ) ;
45
45
const isEmpty = Boolean ( groups && groups . length === 0 ) ;
46
46
const navigate = useNavigate ( ) ;
47
- const styles = useStyles ( ) ;
48
47
49
48
return (
50
49
< >
@@ -137,7 +136,7 @@ export const GroupsPageView: FC<GroupsPageViewProps> = ({
137
136
navigate ( groupPageLink ) ;
138
137
}
139
138
} }
140
- className = { styles . clickableTableRow }
139
+ css = { styles . clickableTableRow }
141
140
>
142
141
< TableCell >
143
142
< AvatarData
@@ -170,10 +169,8 @@ export const GroupsPageView: FC<GroupsPageViewProps> = ({
170
169
</ TableCell >
171
170
172
171
< TableCell >
173
- < div className = { styles . arrowCell } >
174
- < KeyboardArrowRight
175
- className = { styles . arrowRight }
176
- />
172
+ < div css = { styles . arrowCell } >
173
+ < KeyboardArrowRight css = { styles . arrowRight } />
177
174
</ div >
178
175
</ TableCell >
179
176
</ TableRow >
@@ -210,8 +207,8 @@ const TableLoader = () => {
210
207
) ;
211
208
} ;
212
209
213
- const useStyles = makeStyles ( ( theme ) => ( {
214
- clickableTableRow : {
210
+ const styles = {
211
+ clickableTableRow : ( theme ) => ( {
215
212
cursor : "pointer" ,
216
213
217
214
"&:hover td" : {
@@ -225,15 +222,15 @@ const useStyles = makeStyles((theme) => ({
225
222
"& .MuiTableCell-root:last-child" : {
226
223
paddingRight : theme . spacing ( 2 ) ,
227
224
} ,
228
- } ,
229
- arrowRight : {
225
+ } ) ,
226
+ arrowRight : ( theme ) => ( {
230
227
color : theme . palette . text . secondary ,
231
228
width : 20 ,
232
229
height : 20 ,
233
- } ,
230
+ } ) ,
234
231
arrowCell : {
235
232
display : "flex" ,
236
233
} ,
237
- } ) ) ;
234
+ } satisfies Record < string , Interpolation < Theme > > ;
238
235
239
236
export default GroupsPageView ;
0 commit comments