-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f12b005
commit 08a55ff
Showing
3 changed files
with
90 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import { Annotation, Gesture, GestureTarget, Layout } from '../video-strategy' | ||
|
||
const layoutNames: Record<Layout, string> = { | ||
'slide-only': 'slide with voiceover', | ||
'slide-avatar': 'slide and avatar', | ||
'avatar-only': 'avatar only' | ||
} | ||
const gestureNames: Record<Gesture, string> = { | ||
point: 'Point', | ||
nod: 'Nod', | ||
glance: 'Glance' | ||
} | ||
const gestureTargetNames: Record<GestureTarget, string> = { | ||
top: 'top of slide', | ||
middle: 'middle of slide', | ||
bottom: 'bottom of slide' | ||
} | ||
|
||
export type AnnotationContentsProps = { | ||
annotation: Annotation | ||
} | ||
export function AnnotationContents ({ annotation }: AnnotationContentsProps) { | ||
switch (annotation.type) { | ||
case 'set-layout': | ||
return ( | ||
<span> | ||
Change layout to <strong>{layoutNames[annotation.layout]}</strong> | ||
</span> | ||
) | ||
case 'gesture': | ||
return ( | ||
<span> | ||
<strong>{gestureNames[annotation.gesture]}</strong> towards{' '} | ||
<strong>{gestureTargetNames[annotation.towards]}</strong> | ||
</span> | ||
) | ||
case 'set-slide': | ||
return ( | ||
<span> | ||
Change slide to <strong>todo</strong> | ||
</span> | ||
) | ||
case 'play-video': | ||
return ( | ||
<span> | ||
Play video <strong>todo</strong> | ||
</span> | ||
) | ||
default: | ||
return null | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters