feat(ott-2880): video layout fixes

feat(ott-2880): video layout 2

feat(ott-2880): video fix
keep-around/35b5d122c05048fb9e164c9881034e52d923e277
Rita 3 years ago
parent 6b02399412
commit 35b5d122c0
  1. 6
      src/features/MatchPage/styled.tsx
  2. 7
      src/features/MatchSidePlaylists/components/TabVideo/components/VideoDate/styled.tsx
  3. 2
      src/features/MatchSidePlaylists/components/TabVideo/styled.tsx
  4. 30
      src/features/MatchSidePlaylists/index.tsx
  5. 23
      src/features/MatchSidePlaylists/styled.tsx
  6. 4
      src/features/StreamPlayer/styled.tsx
  7. 1
      src/features/UserFavorites/styled.tsx

@ -4,7 +4,7 @@ import { devices } from 'config/devices'
import { isMobileDevice } from 'config/userAgent' import { isMobileDevice } from 'config/userAgent'
export const Wrapper = styled.div` export const Wrapper = styled.div`
width: 100%; width: 96%;
height: calc(100vh - 115px); height: calc(100vh - 115px);
margin: 20px 0px 0 10px; margin: 20px 0px 0 10px;
display: flex; display: flex;
@ -27,8 +27,7 @@ export const Wrapper = styled.div`
` `
export const Container = styled.div` export const Container = styled.div`
width: 100%; min-width: 83%;
max-width: 2090px;
max-height: 896px; max-height: 896px;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
@ -47,6 +46,7 @@ export const Container = styled.div`
padding: 0; padding: 0;
margin-bottom: 15px; margin-bottom: 15px;
min-height: min-content; min-height: min-content;
min-width: auto;
@media screen and (orientation: landscape){ @media screen and (orientation: landscape){
display: block; display: block;

@ -7,10 +7,11 @@ export const Wrapper = styled.div`
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
margin-bottom: 10px; padding-bottom: 10px;
height: 5%;
> :not(:last-child) { > :not(:last-child) {
margin-right: 20px; margin-right: 2%;
} }
${isMobileDevice ? css` ${isMobileDevice ? css`
@ -27,7 +28,7 @@ export const WeekDay = styled.div.attrs(() => ({
}))<{isActive?: boolean}>` }))<{isActive?: boolean}>`
position: relative; position: relative;
color: rgba(255, 255, 255, 0.5); color: rgba(255, 255, 255, 0.5);
font-size: 12px; font-size: 0.6rem;
white-space: nowrap; white-space: nowrap;
padding: 5px; padding: 5px;
cursor: pointer; cursor: pointer;

@ -4,7 +4,7 @@ import { isMobileDevice } from '../../../../config/userAgent'
export const MatchesWrapper = styled.div<{hasScroll?: boolean}>` export const MatchesWrapper = styled.div<{hasScroll?: boolean}>`
overflow-y: auto; overflow-y: auto;
max-height: calc(100vh - 170px); height: 95%;
padding-right: ${({ hasScroll }) => (hasScroll ? '10px' : '')}; padding-right: ${({ hasScroll }) => (hasScroll ? '10px' : '')};
> * { > * {

@ -22,6 +22,7 @@ import {
Wrapper, Wrapper,
TabsWrapper, TabsWrapper,
Container, Container,
ContainerWrapper,
} from './styled' } from './styled'
const tabPanes = { const tabPanes = {
@ -122,19 +123,22 @@ export const MatchSidePlaylists = ({
</TabsGroup> </TabsGroup>
</TabsWrapper> </TabsWrapper>
<Container <ContainerWrapper>
hasScroll={hasTabPaneScroll} <Container
ref={tabPaneContainerRef} hasScroll={hasTabPaneScroll}
forVideoTab={selectedTab === Tabs.VIDEO} ref={tabPaneContainerRef}
> forVideoTab={selectedTab === Tabs.VIDEO}
<TabPane >
tournamentData={tournamentData} <TabPane
onSelect={onSelect} tournamentData={tournamentData}
playlists={playlists} onSelect={onSelect}
profile={profile} playlists={playlists}
selectedPlaylist={selectedPlaylist} profile={profile}
/> selectedPlaylist={selectedPlaylist}
</Container> />
</Container>
</ContainerWrapper>
</Wrapper> </Wrapper>
) )
} }

@ -7,11 +7,14 @@ import { customScrollbar } from 'features/Common'
export const Wrapper = styled.div` export const Wrapper = styled.div`
padding-right: 14px; padding-right: 14px;
min-width: 17%;
max-height: 896px;
${isMobileDevice ${isMobileDevice
? css` ? css`
overflow-y: auto; overflow-y: auto;
width: 100%; width: 100%;
padding-right: 10px;
${customScrollbar} ${customScrollbar}
` `
@ -20,6 +23,7 @@ export const Wrapper = styled.div`
export const TabsWrapper = styled.div` export const TabsWrapper = styled.div`
padding-left: 14px; padding-left: 14px;
height: 4%;
${isMobileDevice ${isMobileDevice
? css` ? css`
@ -28,17 +32,28 @@ export const TabsWrapper = styled.div`
: ''}; : ''};
` `
export const ContainerWrapper = styled.div`
padding-top: 14px;
height: 100%;
max-width: 300px;
${isMobileDevice
? css`
max-width: 100%;
`
: ''};
`
type TContainer = { type TContainer = {
forVideoTab?: boolean, forVideoTab?: boolean,
hasScroll: boolean, hasScroll: boolean,
} }
export const Container = styled.div<TContainer>` export const Container = styled.div<TContainer>`
width: 320px; height: 96%;
margin-top: 14px; padding: ${({ hasScroll }) => (hasScroll ? '0 10px 0 14px' : '0 10px 0 14px')};
padding: ${({ hasScroll }) => (hasScroll ? '0 10px 0 14px' : '0 18px 0 14px')};
max-height: calc(100vh - 130px); max-height: calc(100vh - 130px);
overflow-y: ${({ forVideoTab }) => (forVideoTab ? 'hidden' : 'auto')}; overflow: ${({ forVideoTab }) => (forVideoTab ? 'hidden' : 'auto')};
padding-right: ${({ forVideoTab }) => (forVideoTab ? '0' : '')}; padding-right: ${({ forVideoTab }) => (forVideoTab ? '0' : '')};
${customScrollbar} ${customScrollbar}

@ -93,7 +93,7 @@ export const ControlsGroup = styled.div`
: ''}; : ''};
` `
const supportsAspectRatio = CSS.supports('aspect-ratio', '16 / 9') && isMobileDevice const supportsAspectRatio = CSS.supports('aspect-ratio', '16 / 9')
export const PlayerWrapper = styled.div<PlayStopProps>` export const PlayerWrapper = styled.div<PlayStopProps>`
width: 100%; width: 100%;
@ -107,7 +107,7 @@ export const PlayerWrapper = styled.div<PlayStopProps>`
? css`aspect-ratio: 16 / 9;` ? css`aspect-ratio: 16 / 9;`
: css` : css`
height: 0px; height: 0px;
padding-top: 56.25%; object-fit: cover;
`} `}
${isMobileDevice ${isMobileDevice

@ -19,6 +19,7 @@ export const UserSportFavWrapper = styled.aside`
top: 0; top: 0;
bottom: 0; bottom: 0;
z-index: 10; z-index: 10;
width: 4%;
${isMobileDevice ${isMobileDevice
? css` ? css`

Loading…
Cancel
Save