diff --git a/src/stories/player/parts/controls.tsx b/src/stories/player/parts/controls.tsx index 3236077c..8625277f 100644 --- a/src/stories/player/parts/controls.tsx +++ b/src/stories/player/parts/controls.tsx @@ -14,9 +14,11 @@ import { PlayerTooltip } from "./tooltip"; import { formatDuration } from "../utils"; import useDebounce from "../../../hooks/useDebounce"; import { CutStart } from "./CutStart"; +import { theme } from "../../theme"; export const ControlsWrapper = styled.div` - ${({ showControls }) => showControls ? "position: relative;" : "position: absolute;"} + ${({ showControls }) => + showControls ? "position: relative;" : "position: absolute;"} bottom: 0; left: 0; right: 0; @@ -84,7 +86,7 @@ export const Controls = ({ const [marks, setMarks] = useState(bookmarks); const [updatedMark, setUpdatedMark] = useState(); const progressRef = useRef(null); - const { context, setCurrentTime } = useVideoContext() + const { context, setCurrentTime } = useVideoContext(); const debouncedMark = useDebounce(updatedMark, 500); const [cutStart, setCutStart] = useState(0); @@ -228,19 +230,21 @@ export const Controls = ({ progress={progress} handleSkipAhead={handleSkipAhead} duration={duration} - /> + /> {isCutting && } - + - + theme.space.xxs}; `; export const ControlsGroupCenter = (props: HTMLAttributes) => { @@ -45,6 +46,7 @@ export const ControlsGroupCenter = (props: HTMLAttributes) => { return ( { if (videoRef) { videoRef.currentTime = 0; @@ -55,6 +57,7 @@ export const ControlsGroupCenter = (props: HTMLAttributes) => { { onRewind(); e.stopPropagation(); @@ -62,14 +65,15 @@ export const ControlsGroupCenter = (props: HTMLAttributes) => { > - + {isPlaying ? ( - + ) : ( - + )} { onForward(); e.stopPropagation(); @@ -78,6 +82,7 @@ export const ControlsGroupCenter = (props: HTMLAttributes) => { { const newSpeed = getNextPlaybackRate(playBackRate);