From 168dda0a7fff22c0194d215a4e0a7cc5dbc5b799 Mon Sep 17 00:00:00 2001 From: LeireA Date: Fri, 21 Jan 2022 14:31:04 +0100 Subject: [PATCH] fix lint --- .../components/token-classifier/results/TextSpan.vue | 11 ++++++++--- frontend/models/TokenClassification.js | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/frontend/components/token-classifier/results/TextSpan.vue b/frontend/components/token-classifier/results/TextSpan.vue index 7fcc1defb0..f512a4daa1 100755 --- a/frontend/components/token-classifier/results/TextSpan.vue +++ b/frontend/components/token-classifier/results/TextSpan.vue @@ -76,7 +76,7 @@ import ClickOutside from "v-click-outside"; import "assets/icons/check"; import "assets/icons/cross"; -import { substring } from 'stringz'; +import { substring } from "stringz"; export default { directives: { @@ -114,10 +114,15 @@ export default { return this.spans[this.spanId]; }, text() { - return substring(this.record.raw_text, this.spans[this.spanId].start, this.spans[this.spanId].end) + return substring( + this.record.raw_text, + this.spans[this.spanId].start, + this.spans[this.spanId].end + ); }, whiteSpace() { - return substring(this.record.raw_text, + return substring( + this.record.raw_text, this.spans[this.spanId].end, this.spans[this.spanId + 1] ? this.spans[this.spanId + 1].start : "" ); diff --git a/frontend/models/TokenClassification.js b/frontend/models/TokenClassification.js index da165b924e..2473095fbc 100644 --- a/frontend/models/TokenClassification.js +++ b/frontend/models/TokenClassification.js @@ -17,7 +17,7 @@ import { ObservationDataset, USER_DATA_METADATA_KEY } from "./Dataset"; import { BaseRecord, BaseSearchQuery, BaseSearchResults } from "./Common"; -import { indexOf, length } from 'stringz'; +import { indexOf, length } from "stringz"; class TokenClassificationRecord extends BaseRecord { tokens;