From c57b5b04911dca9cf62d4aa0a115de6e548699af Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Fri, 30 Oct 2020 15:46:23 +0100 Subject: inline video captions --- .../app/views/viewer/player/components.inline/inline.video.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'animism-align/frontend/app/views/viewer/player/components.inline/inline.video.js') diff --git a/animism-align/frontend/app/views/viewer/player/components.inline/inline.video.js b/animism-align/frontend/app/views/viewer/player/components.inline/inline.video.js index 86fc0df..85af05e 100644 --- a/animism-align/frontend/app/views/viewer/player/components.inline/inline.video.js +++ b/animism-align/frontend/app/views/viewer/player/components.inline/inline.video.js @@ -16,7 +16,7 @@ export const MediaVideo = ({ paragraph, media, currentParagraph, onAnnotationCli const color = CURTAIN_COLOR_LOOKUP[annotation.settings.color] || CURTAIN_COLOR_LOOKUP.white const width = window.innerWidth const height = window.innerHeight - (17 * 16) - const style = { + let style = { color: color.textColor, height: height + 32, backgroundColor: color.backgroundColor, @@ -24,13 +24,20 @@ export const MediaVideo = ({ paragraph, media, currentParagraph, onAnnotationCli // if this is a fullscreen video, display the poster image if (annotation.settings.fullscreen && !annotation.settings.inline) { + const color = CURTAIN_COLOR_LOOKUP[annotation.settings.poster_background_color || annotation.settings.color] || CURTAIN_COLOR_LOOKUP.white + style.color = color.textColor + style.backgroundColor = color.backgroundColor style.backgroundImage = 'url(' + posterURL(item) + ')' if (annotation.settings.poster_size) { style.backgroundSize = annotation.settings.poster_size } return (
-
+
onAnnotationClick(e, paragraph, annotation)} + >
{SpeakerIcon}
-- cgit v1.2.3-70-g09d2