@soul-refiner/design-system 1.0.3 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -10,4 +10,4 @@ export interface VideoProps {
|
|
|
10
10
|
style?: React.CSSProperties;
|
|
11
11
|
thumbnail: string;
|
|
12
12
|
}
|
|
13
|
-
export declare const Video: ({ controls, loop, playsInline, src, subtitles, style, thumbnail, }: VideoProps) => React.JSX.Element;
|
|
13
|
+
export declare const Video: ({ controls, loop, muted, playsInline, src, subtitles, style, thumbnail, }: VideoProps) => React.JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import ReactPlayer from 'react-player';
|
|
3
3
|
import Image from 'next/image';
|
|
4
|
-
export const Video = ({ controls = true, loop = false, playsInline, src, subtitles, style, thumbnail, }) => {
|
|
4
|
+
export const Video = ({ controls = true, loop = false, muted, playsInline, src, subtitles, style, thumbnail, }) => {
|
|
5
5
|
const ref = React.useRef(null);
|
|
6
6
|
return (React.createElement(ReactPlayer, { config: {
|
|
7
7
|
file: {
|
|
@@ -19,7 +19,7 @@ export const Video = ({ controls = true, loop = false, playsInline, src, subtitl
|
|
|
19
19
|
srcLang: subtitle.locale,
|
|
20
20
|
})),
|
|
21
21
|
},
|
|
22
|
-
}, controls: controls, height: "100%", light: thumbnail ? (React.createElement(Image, { alt: "thumbnail for trailer",
|
|
22
|
+
}, controls: controls, height: "100%", light: thumbnail ? (React.createElement(Image, { alt: "thumbnail for trailer", height: 720, priority: true, src: thumbnail, style: { objectFit: 'contain' }, width: 1280 })) : undefined, loop: loop, muted: muted, pip: false, playsinline: playsInline, playing: true, ref: ref, style: {
|
|
23
23
|
backgroundColor: 'var(--color-grey-0)',
|
|
24
24
|
maxHeight: 720,
|
|
25
25
|
maxWidth: 1280,
|
|
@@ -45,7 +45,7 @@ export const VideoPlayer = ({ activeIndex, pip, playlist, onPipChange, onProgres
|
|
|
45
45
|
srcLang: subtitle.locale,
|
|
46
46
|
})),
|
|
47
47
|
},
|
|
48
|
-
}, controls: true, height: "100%", light: React.createElement(Image, { alt: `thumbnail for ${title}`,
|
|
48
|
+
}, controls: true, height: "100%", light: React.createElement(Image, { alt: `thumbnail for ${title}`, height: 720, priority: true, style: { objectFit: 'contain' }, src: mediaItem.thumbnail, width: 1280 }), onDisablePIP: () => onPipChange && onPipChange(false), onEnablePIP: () => onPipChange && onPipChange(true), onProgress: onProgress, onReady: handleReady, pip: pip, playing: true, ref: ref, style: {
|
|
49
49
|
backgroundColor: 'var(--color-grey-0)',
|
|
50
50
|
maxHeight: 720,
|
|
51
51
|
maxWidth: 1280,
|
|
@@ -56,10 +56,9 @@ const Inner = styled.div `
|
|
|
56
56
|
flex-flow: row nowrap;
|
|
57
57
|
scroll-behavior: smooth;
|
|
58
58
|
padding-right: 32px;
|
|
59
|
-
margin-top: -
|
|
60
|
-
padding-top:
|
|
61
|
-
|
|
62
|
-
padding-bottom: 200px;
|
|
59
|
+
margin-top: -56px;
|
|
60
|
+
padding-top: 56px;
|
|
61
|
+
padding-bottom: 92px;
|
|
63
62
|
|
|
64
63
|
& > * {
|
|
65
64
|
flex-shrink: 0;
|