From a12ae1c0b72794561d80ffe084b4f3dbf717426b Mon Sep 17 00:00:00 2001 From: lonkaars Date: Sun, 25 Jul 2021 17:15:07 +0200 Subject: css tweaks + code splitting --- components/slideprops.tsx | 57 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 components/slideprops.tsx (limited to 'components') diff --git a/components/slideprops.tsx b/components/slideprops.tsx new file mode 100644 index 0000000..aa118e8 --- /dev/null +++ b/components/slideprops.tsx @@ -0,0 +1,57 @@ +import { State } from '@hookstate/core'; + +import TextField from '@material-ui/core/TextField'; + +import TimecodeInput from '../components/timeinput'; +import { globalState } from '../pages/editor'; +import { TimedVideoPlayer } from '../pages/present'; +import { anySlide, loopSlide } from '../timeline'; + +export default function SlideProperties(props: { + slide: State; + global: State; + player: TimedVideoPlayer; +}) { + if (props.slide.value.type == 'default') return null; + + return
+ Properties + {{ + 'loop': <> + ).frame.get() + - (props.slide as State).beginFrame.get()} + /> + ).beginFrame.get()} + update={newValue => { + (props.slide as State).frame.set(newValue); + props.global.update.refreshLiveTimeline.value(); + }} + player={props.player} + /> + ).frame.get()} + update={newValue => { + (props.slide as State).frame.set(newValue); + props.global.update.refreshLiveTimeline.value(); + }} + player={props.player} + /> + + , + 'delay': <> + + , + 'speedChange': <> + + + , + }[props.slide.value.type]} +
; +} -- cgit v1.2.3