From 9886bf9c5181ee62301614449b336eb4a0a49893 Mon Sep 17 00:00:00 2001 From: Julian Gonggrijp Date: Wed, 8 Jun 2022 15:40:07 +0200 Subject: [PATCH] Use classes instead of ids in annotation view (#448 #447) --- frontend/src/panel-annotation/annotation-template.hbs | 8 ++++---- frontend/src/panel-annotation/annotation-view.ts | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/frontend/src/panel-annotation/annotation-template.hbs b/frontend/src/panel-annotation/annotation-template.hbs index 247aa932..7b168524 100644 --- a/frontend/src/panel-annotation/annotation-template.hbs +++ b/frontend/src/panel-annotation/annotation-template.hbs @@ -54,7 +54,7 @@ {{#if itemSerial }}
-
+
-
+

{{#if annotationSerial }} {{#i18n 'button.other-annotations'}}Other annotations{{/i18n}} {{else}} @@ -80,7 +80,7 @@

-
+

{{#i18n 'button.external-resources'}}External resources{{/i18n}}

- +
{{/if}} diff --git a/frontend/src/panel-annotation/annotation-view.ts b/frontend/src/panel-annotation/annotation-view.ts index 6cb3ed84..ffe5947a 100644 --- a/frontend/src/panel-annotation/annotation-view.ts +++ b/frontend/src/panel-annotation/annotation-view.ts @@ -145,10 +145,10 @@ extend(AnnotationView.prototype, { selector: '.metadataContainer', }], events: { - 'click #btnRelItems': 'onRelItemsClicked', - 'click #btnAnnotations': 'onAnnotationsClicked', - 'click #btnExtResources': 'onExtResourcesClicked', + 'click .btn-related': 'onRelItemsClicked', + 'click .btn-annotations': 'onAnnotationsClicked', + 'click .btn-external': 'onExtResourcesClicked', 'click .btn-edit': 'onEditClicked', - 'click #btnNewAnnotation': 'onNewClicked' + 'click .btn-new': 'onNewClicked' }, });