@@ -3,11 +3,11 @@ import { memo, useMemo } from 'react';
33import { Box , Button } from '../../base' ;
44import { iconXSmall } from '../../constants/iconsSizes' ;
55import { LeaderBoardIcon , TropyIcon } from '../../icons' ;
6- import { useTheme } from '../../theme' ;
6+ import { useMediaQuery , useTheme } from '../../theme' ;
77import { Carousel } from '../Carousel' ;
88import { Pattern } from '../CustomCatalog/CustomCard' ;
99import { ErrorBoundary } from '../ErrorBoundary' ;
10- import { StateCardSekeleton } from './PerformersToogleButton' ;
10+ import { OpenLeaderBoardButton , StateCardSekeleton } from './PerformersToogleButton' ;
1111import {
1212 CardsContainer ,
1313 ContentWrapper ,
@@ -228,6 +228,7 @@ const PerformersSection: React.FC<PerformersSectionProps> = ({
228228} ) => {
229229 const theme = useTheme ( ) ;
230230 const { queries, isLoading, hasError } = useMetricQueries ( useGetCatalogFilters ) ;
231+ const smallScreen = useMediaQuery ( theme . breakpoints . down ( 'sm' ) ) ;
231232
232233 const stats = useMemo (
233234 ( ) =>
@@ -265,20 +266,24 @@ const PerformersSection: React.FC<PerformersSectionProps> = ({
265266 style = { {
266267 height : '2rem' ,
267268 width : '2rem' ,
268- color : theme . palette . icon . secondary
269+ color : theme . palette . icon . secondary ,
270+ display : smallScreen ? 'none' : 'inline-flex'
269271 } }
270272 />
271273 </ Box >
272274 { onOpenLeaderboard && (
273- < Button
274- variant = "contained"
275- onClick = { ( ) => onOpenLeaderboard ( ) }
276- sx = { {
277- display : { xs : 'none' , md : 'inline-flex' }
278- } }
279- >
280- Open Leaderboard
281- </ Button >
275+ < div >
276+ < Button
277+ variant = "contained"
278+ onClick = { ( ) => onOpenLeaderboard ( ) }
279+ sx = { {
280+ display : { xs : 'none' , sm : 'inline-flex' }
281+ } }
282+ >
283+ Open Leaderboard
284+ </ Button >
285+ < OpenLeaderBoardButton handleClick = { onOpenLeaderboard } />
286+ </ div >
282287 ) }
283288 </ TitleBox >
284289 < CardsContainer >
0 commit comments