From 8b962053f2af99ece482537b9ac7a1daff1400b9 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Sat, 7 Nov 2020 02:03:40 +0100 Subject: starting to add subtitles. fix carousels not showing up in transcript --- animism-align/frontend/app/constants.js | 4 ++-- .../align/components/annotations/annotation.form.js | 2 +- .../annotationForms/annotationForm.text.js | 20 ++++++++++++++++++++ .../components/annotations/annotationForms/index.js | 2 ++ .../annotationTypes/annotationTypes.text.js | 19 +++++++++++++++++++ .../components/annotations/annotationTypes/index.js | 2 ++ .../app/views/viewer/transcript/components/index.js | 1 + .../frontend/app/views/viewer/viewer.actions.js | 2 +- 8 files changed, 48 insertions(+), 4 deletions(-) (limited to 'animism-align/frontend') diff --git a/animism-align/frontend/app/constants.js b/animism-align/frontend/app/constants.js index af0e08c..c113f3c 100644 --- a/animism-align/frontend/app/constants.js +++ b/animism-align/frontend/app/constants.js @@ -46,7 +46,7 @@ export const ROMAN_NUMERALS = [ export const TEXT_ANNOTATION_TYPES = new Set([ 'section_heading', 'heading_text', 'sentence', 'paragraph_end', 'pullquote_credit', - 'footnote', 'text_plate', + 'footnote', 'text_plate', 'subtitle', ]) export const MEDIA_ANNOTATION_TYPES = new Set([ @@ -69,7 +69,7 @@ export const INLINE_UTILITY_ANNOTATION_TYPES = new Set([ ]) export const FULLSCREEN_UTILITY_ANNOTATION_TYPES = new Set([ - 'curtain', 'text_plate', + 'curtain', 'text_plate', 'subtitle', ]) export const GALLERY_UTILITY_ANNOTATION_TYPES = new Set([ diff --git a/animism-align/frontend/app/views/align/components/annotations/annotation.form.js b/animism-align/frontend/app/views/align/components/annotations/annotation.form.js index b1bc052..e0a66e4 100644 --- a/animism-align/frontend/app/views/align/components/annotations/annotation.form.js +++ b/animism-align/frontend/app/views/align/components/annotations/annotation.form.js @@ -16,7 +16,7 @@ const ANNOTATION_TYPES = [ 'sentence', 'section_heading', 'heading_text', 'pullquote_credit', 'paragraph_end', 'footnote', 'text_plate', - 'video', + 'video', 'subtitle', 'image', 'gallery', 'carousel', 'grid', 'vitrine', 'gallery_advance', diff --git a/animism-align/frontend/app/views/align/components/annotations/annotationForms/annotationForm.text.js b/animism-align/frontend/app/views/align/components/annotations/annotationForms/annotationForm.text.js index 82a0d6e..cc7cc41 100644 --- a/animism-align/frontend/app/views/align/components/annotations/annotationForms/annotationForm.text.js +++ b/animism-align/frontend/app/views/align/components/annotations/annotationForms/annotationForm.text.js @@ -84,6 +84,26 @@ export const AnnotationFormTextPlate = ({ annotation, handleSettingsSelect, hand ) } +export const AnnotationFormSubtitle = ({ annotation, handleSettingsSelect, handleSettingsChange }) => { + return ( +
+