|
|
|
|
@ -3,7 +3,6 @@ import { |
|
|
|
|
Route, |
|
|
|
|
Redirect, |
|
|
|
|
Switch, |
|
|
|
|
useRouteMatch, |
|
|
|
|
} from 'react-router-dom' |
|
|
|
|
|
|
|
|
|
import { indexLexics } from 'config/lexics/indexLexics' |
|
|
|
|
@ -22,19 +21,15 @@ import { Header } from 'features/Header' |
|
|
|
|
import { MainWrapper } from 'features/MainWrapper' |
|
|
|
|
import { |
|
|
|
|
HeaderFiltersStore, |
|
|
|
|
SportTypeFilter, |
|
|
|
|
TournamentFilter, |
|
|
|
|
} from 'features/HeaderFilters' |
|
|
|
|
import { UserFavorites } from 'features/UserFavorites' |
|
|
|
|
import { UserFavoritesStore } from 'features/UserFavorites/store' |
|
|
|
|
import { useMediaQuery } from 'features/MediaQuery' |
|
|
|
|
import { HeaderMobile } from 'features/HeaderMobile' |
|
|
|
|
import { BottomMenuWrapper } from 'features/HeaderMobile/styled' |
|
|
|
|
|
|
|
|
|
export const AuthenticatedApp = () => { |
|
|
|
|
useLexicsConfig(indexLexics) |
|
|
|
|
const isMobile = useMediaQuery({ query: devices.tablet }) |
|
|
|
|
const isMatch = useRouteMatch(`/:sportName${PAGES.match}/:pageId`)?.isExact |
|
|
|
|
|
|
|
|
|
return ( |
|
|
|
|
<ScoreStore> |
|
|
|
|
@ -83,16 +78,6 @@ export const AuthenticatedApp = () => { |
|
|
|
|
<Route path={`/:sportName${PAGES.match}/:pageId`}> |
|
|
|
|
<MatchPage /> |
|
|
|
|
</Route> |
|
|
|
|
{ |
|
|
|
|
isMobile && !isMatch |
|
|
|
|
? ( |
|
|
|
|
<BottomMenuWrapper> |
|
|
|
|
<SportTypeFilter /> |
|
|
|
|
<TournamentFilter /> |
|
|
|
|
</BottomMenuWrapper> |
|
|
|
|
) |
|
|
|
|
: null |
|
|
|
|
} |
|
|
|
|
</MainWrapper> |
|
|
|
|
</UserFavoritesStore> |
|
|
|
|
</HeaderFiltersStore> |
|
|
|
|
|