diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2020-07-04 17:24:21 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2020-07-04 17:24:21 +0200 |
| commit | 82c2ac11f4ef2112a0332f2f9c7cdd52444f0d2a (patch) | |
| tree | 38ce15d8cb9dd71ec756a6b3a9d7cbebe5ff084a /animism-align/frontend/views/align/components/annotations/annotation.form.js | |
| parent | e973412b5ea29685f4fa260d8eb44baae095fb81 (diff) | |
displaying annotation list, click to select, doubleclick to show form, updating annotations
Diffstat (limited to 'animism-align/frontend/views/align/components/annotations/annotation.form.js')
| -rw-r--r-- | animism-align/frontend/views/align/components/annotations/annotation.form.js | 6 |
1 files changed, 5 insertions, 1 deletions
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 9432948..b62c36e 100644 --- a/animism-align/frontend/views/align/components/annotations/annotation.form.js +++ b/animism-align/frontend/views/align/components/annotations/annotation.form.js @@ -24,9 +24,13 @@ class AnnotationForm extends Component { this.handleSubmit = this.handleSubmit.bind(this) } handleKeyDown(e) { + if (e.keyCode === 27) { // escape + actions.align.hideAnnotationForm() + return + } + // console.log(e.keyCode) if (!e.metaKey && !e.ctrlKey) return let { start_ts } = this.props.annotation - console.log(e.keyCode) switch (e.keyCode) { case 38: // up e.preventDefault() |
