feat(ott-1556): add gradient for video controls (#463)

keep-around/af30b88d367751c9e05a735e4a0467a96238ef47
KarelinDm 4 years ago committed by GitHub
parent e0d83a0eab
commit 20ac46d57c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. BIN
      public/images/player-controls-gradient.png
  2. 2
      src/features/MultiSourcePlayer/index.tsx
  3. 2
      src/features/StreamPlayer/index.tsx
  4. 10
      src/features/StreamPlayer/styled.tsx

Binary file not shown.

After

Width:  |  Height:  |  Size: 315 B

@ -12,6 +12,7 @@ import {
Backward,
Forward,
PlaybackTime,
ControlsGradient,
} from 'features/StreamPlayer/styled'
import { VideoPlayer } from 'features/VideoPlayer'
@ -202,6 +203,7 @@ export const MultiSourcePlayer = (props: Props) => {
</ControlsGroup>
</ControlsRow>
</Controls>
<ControlsGradient />
</PlayerWrapper>
)
}

@ -21,6 +21,7 @@ import {
Backward,
Forward,
PlaybackTime,
ControlsGradient,
} from './styled'
export const StreamPlayer = (props: Props) => {
@ -136,6 +137,7 @@ export const StreamPlayer = (props: Props) => {
</ControlsGroup>
</ControlsRow>
</Controls>
<ControlsGradient />
</PlayerWrapper>
)
}

@ -10,7 +10,17 @@ export const VideoPlayer = styled(VideoPlayerBase)`
left: 0;
`
export const ControlsGradient = styled.div`
background-image: url(/images/player-controls-gradient.png);
bottom: 0;
position: absolute;
width: 100%;
pointer-events: none;
height: 145px;
`
export const Controls = styled.div`
z-index: 50;
position: absolute;
width: 100%;
bottom: 22px;

Loading…
Cancel
Save