* ui: start highlight ui * ui: tag items * ui: connecting highlights to notes api... * Highlight feature refinements (#2948) * ui: move clips player to foss, connect notes api to hl * ui: tune note/hl editing, prevent zoom slider body from jumping around * ui: safe check for tag * ui: fix thumbnail gen * ui: fix thumbnail gen * ui: make player modal wider, add shadow * ui: custom warn barge for clips * ui: swap icon for note event wrapper * ui: rm other, fix cancel * ui: moving around creation modal * ui: bg tint * ui: rm disabled for text btn * ui: fix ownership sorting * ui: close player on bg click * ui: fix query, fix min distance for default range * ui: move hl list header out of list comp * ui: spot list header segmented size * Various improvements in highlights (#2955) * ui: update hl in hlPanel comp * ui: rm debug * ui: fix icons file --------- Co-authored-by: Sudheer Salavadi <connect.uxmaster@gmail.com>
35 lines
1 KiB
TypeScript
35 lines
1 KiB
TypeScript
import React from 'react';
|
|
import {observer} from 'mobx-react-lite';
|
|
import {PlayerContext} from "Components/Session/playerContext";
|
|
import {Loader} from "UI";
|
|
import PlayIconLayer from "Components/Session_/Player/Overlay/PlayIconLayer";
|
|
import ClipFeedback from "Components/Session/Player/ClipPlayer/ClipFeedback";
|
|
import AutoplayTimer from "Components/Session/Player/ClipPlayer/AutoPlayTimer";
|
|
|
|
interface Props {
|
|
autoplay: boolean;
|
|
}
|
|
|
|
function Overlay({ autoplay }: Props) {
|
|
const {player, store} = React.useContext(PlayerContext);
|
|
const togglePlay = () => player.togglePlay();
|
|
|
|
const {
|
|
messagesLoading,
|
|
playing,
|
|
completed,
|
|
} = store.get();
|
|
|
|
return (
|
|
<>
|
|
{messagesLoading ? <Loader/> : null}
|
|
{/*<div className="hidden group-hover:block">*/}
|
|
{/* <ClipFeedback/>*/}
|
|
{/*</div>*/}
|
|
<PlayIconLayer playing={playing} togglePlay={togglePlay}/>
|
|
{completed && autoplay && <AutoplayTimer/>}
|
|
</>
|
|
);
|
|
}
|
|
|
|
export default observer(Overlay);
|