33import { mdiCached } from '@mdi/js' ;
44import { Icon } from '@mdi/react' ;
55import { Box , IconButton } from '@mui/material' ;
6- import { useState , type FunctionComponent , type ReactNode } from 'react' ;
6+ import { useState , type ReactNode } from 'react' ;
77
88import { CardFace } from '@/components/Card/CardFace' ;
99import { type ScryCard } from '@/tools/scryfall/types' ;
@@ -12,7 +12,7 @@ type Props = {
1212 data : ScryCard [ ] ;
1313} ;
1414
15- export const Card : FunctionComponent < Props > = ( { data } ) => {
15+ export const Card = ( { data } : Props ) => {
1616 const [ selectedFace , setSelectedFace ] = useState ( 0 ) ;
1717
1818 /** Toggle index between 0 and 1 */
@@ -23,9 +23,9 @@ export const Card: FunctionComponent<Props> = ({ data }) => {
2323 < IconButton
2424 className = "light"
2525 onClick = { onFlip }
26- sx = { ( { mixins , vars } ) => ( {
27- ...mixins . blur ( 'weakest' ) ,
28- bgcolor : `rgba(${ vars . palette . background . paperChannel } / .4)` ,
26+ sx = { ( theme ) => ( {
27+ ...theme . mixins . blur ( 'weakest' ) ,
28+ bgcolor : `rgba(${ theme . vars . palette . background . paperChannel } / .4)` ,
2929 boxShadow : 1 ,
3030 height : [ 40 , 48 ] ,
3131 left : 'unset' ,
@@ -34,7 +34,7 @@ export const Card: FunctionComponent<Props> = ({ data }) => {
3434 top : '13%' ,
3535 width : [ 40 , 48 ] ,
3636 '&:hover' : {
37- bgcolor : `rgba(${ vars . palette . background . paperChannel } / .5)` ,
37+ bgcolor : `rgba(${ theme . vars . palette . background . paperChannel } / .5)` ,
3838 } ,
3939 } ) }
4040 title = "Flip"
0 commit comments