|
|
|
|
@ -2,7 +2,11 @@ import { Fragment } from 'react' |
|
|
|
|
import type { ReactNode } from 'react' |
|
|
|
|
import { Link } from 'react-router-dom' |
|
|
|
|
|
|
|
|
|
import { PAGES } from 'config' |
|
|
|
|
import { |
|
|
|
|
PAGES, |
|
|
|
|
SportTypes, |
|
|
|
|
ProfileTypes, |
|
|
|
|
} from 'config' |
|
|
|
|
|
|
|
|
|
import { client } from 'config/clients' |
|
|
|
|
|
|
|
|
|
@ -12,6 +16,7 @@ import { ScoreSwitch } from 'features/MatchSwitches' |
|
|
|
|
|
|
|
|
|
import { isMatchPage } from 'helpers/isMatchPage' |
|
|
|
|
|
|
|
|
|
import { usePageParams } from 'hooks/usePageParams' |
|
|
|
|
import { useProfileColor } from './hooks' |
|
|
|
|
|
|
|
|
|
import { |
|
|
|
|
@ -36,11 +41,20 @@ export const ProfileHeader = ({ |
|
|
|
|
height, |
|
|
|
|
profileId, |
|
|
|
|
}: Props) => { |
|
|
|
|
const { |
|
|
|
|
profileType, |
|
|
|
|
sportType, |
|
|
|
|
} = usePageParams() |
|
|
|
|
|
|
|
|
|
const url = '/images/5704.png' |
|
|
|
|
const color = useProfileColor(profileId) |
|
|
|
|
const imageHeader = profileId === 5704 |
|
|
|
|
&& sportType === SportTypes.FOOTBALL |
|
|
|
|
&& profileType === ProfileTypes.TOURNAMENTS ? url : headerImage |
|
|
|
|
return ( |
|
|
|
|
<Fragment> |
|
|
|
|
<HeaderStyled |
|
|
|
|
headerImage={headerImage} |
|
|
|
|
headerImage={imageHeader} |
|
|
|
|
color={headerColor || color} |
|
|
|
|
height={height} |
|
|
|
|
> |
|
|
|
|
|