From beac05596a0d09e07087c326224160db6fd1e936 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Mon, 6 Jul 2020 19:54:33 +0200 Subject: set paragraph end with specific element --- .../frontend/views/align/components/annotations/annotation.form.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'animism-align/frontend/views/align/components/annotations/annotation.form.js') diff --git a/animism-align/frontend/views/align/components/annotations/annotation.form.js b/animism-align/frontend/views/align/components/annotations/annotation.form.js index e18d6df..226bb45 100644 --- a/animism-align/frontend/views/align/components/annotations/annotation.form.js +++ b/animism-align/frontend/views/align/components/annotations/annotation.form.js @@ -12,7 +12,7 @@ import { timeToPosition } from '../../align.util' import { Select } from '../../../../common' const ANNOTATION_TYPES = [ - 'sentence', 'header' + 'sentence', 'header', 'paragraph_end' ].map(name => ({ name, label: name })) class AnnotationForm extends Component { @@ -68,6 +68,9 @@ class AnnotationForm extends Component { } handleSubmit() { const { annotation } = this.props + if (annotation.type === 'paragraph_end') { + annotation.text = '' + } if (annotation.id === 'new') { delete annotation.id actions.annotation.create(annotation) -- cgit v1.2.3-70-g09d2