From 4bb72b9f6d2a56fc6bd67f4248fcabfcc8166493 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Fri, 17 Jul 2020 18:52:24 +0200 Subject: refactor annotation and paragraph types --- .../annotationForms/annotationForm.video.js | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 animism-align/frontend/views/align/components/annotations/annotationForms/annotationForm.video.js (limited to 'animism-align/frontend/views/align/components/annotations/annotationForms/annotationForm.video.js') diff --git a/animism-align/frontend/views/align/components/annotations/annotationForms/annotationForm.video.js b/animism-align/frontend/views/align/components/annotations/annotationForms/annotationForm.video.js new file mode 100644 index 0000000..9302ba4 --- /dev/null +++ b/animism-align/frontend/views/align/components/annotations/annotationForms/annotationForm.video.js @@ -0,0 +1,27 @@ +import React, { Component } from 'react' + +import { Select } from '../../../../../common' + +export const AnnotationFormVideo = ({ annotation, media, handleSettingsSelect }) => { + if (!media.lookup) return
+ const { lookup, order } = media + const video_list_items = order.filter(id => lookup[id].type === 'video').map(id => { + const video = lookup[id] + return { + name: video.id, + label: video.author + ' - ' + video.title + } + }) + return ( +
+