Browse Source

Hide special metadata values from display

pull/487/head
Clemens Wolff 5 years ago
parent
commit
331e12ff28
2 changed files with 13 additions and 1 deletions
  1. 2
      app/server/static/components/annotation.pug
  2. 12
      app/server/static/components/annotationMixin.js

2
app/server/static/components/annotation.pug

@ -103,7 +103,7 @@ div.columns(v-cloak="")
)
section.modal-card-body.modal-card-body-footer
vue-json-pretty(
v-bind:data="documentMetadata"
v-bind:data="displayDocumentMetadata"
v-bind:show-double-quotes="false"
v-bind:show-line="false"
)

12
app/server/static/components/annotationMixin.js

@ -297,6 +297,18 @@ export default {
: 'Click to approve annotations';
},
displayDocumentMetadata() {
let documentMetadata = this.documentMetadata;
if (documentMetadata == null) {
return null;
}
documentMetadata = { ...documentMetadata };
delete documentMetadata.guideline;
delete documentMetadata.documentSourceUrl;
return documentMetadata;
},
documentMetadata() {
const document = this.docs[this.pageNumber];
if (document == null || document.meta == null) {

Loading…
Cancel
Save