Ott 754 fix score popup (#280)

* fix(finishedplaylistpage): hide/show score match

* fix(finishedplaylistpage): add '-' between teams if score hidden

* refactor(finishedplaylistpage component): refactoring code

Co-authored-by: Ivan Piminov <ivan.piminov@instatsport.com>
keep-around/af30b88d367751c9e05a735e4a0467a96238ef47
Иван Пиминов 5 years ago committed by GitHub
parent 121464da89
commit f9702c9d2f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      src/features/MatchPopup/components/FinishedPlaylistPage/index.tsx

@ -2,6 +2,7 @@ import { Fragment } from 'react'
import isEmpty from 'lodash/isEmpty'
import { useMatchSwitchesStore } from 'features/MatchSwitches'
import { Name } from 'features/Name'
import { MediaQuery } from 'features/MediaQuery'
import { useMatchPopupStore } from 'features/MatchPopup'
@ -21,6 +22,8 @@ import {
export const FinishedPlaylistPage = () => {
const { match, matchPlaylists } = useMatchPopupStore()
const { isScoreHidden } = useMatchSwitchesStore()
if (!match) return null
const { team1, team2 } = match
@ -40,7 +43,7 @@ export const FinishedPlaylistPage = () => {
<HeaderTitle>
<Name nameObj={team1} />
{score}
{isScoreHidden ? ' - ' : score}
<Name nameObj={team2} />
</HeaderTitle>

Loading…
Cancel
Save