Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style(lint): fix lint errors #65

Merged
merged 4 commits into from
Aug 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/components/annotations/AnnotationDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,6 @@ import {appendShortTermToken} from '@/utils/token-utils.js';
import ChannelName from '@/components/viewer/ChannelName';
import {PropertyCollection} from 'cytomine-client';
import constants from '@/utils/constants.js';
import SimilarAnnotation from '@/components/annotations/SimilarAnnotation.vue';

export default {
name: 'annotations-details',
Expand All @@ -327,7 +326,6 @@ export default {
TrackTree,
CytomineTrack,
AnnotationLinksPreview,
SimilarAnnotation
},
props: {
annotation: {type: Object},
Expand Down Expand Up @@ -612,7 +610,7 @@ export default {
async searchSimilarAnnotations() {
let data = (await Cytomine.instance.api.get(
'retrieval/retrieve.json',
{params: {annotation: this.annotation.id, nrt_neigh: 10}}
{params: {annotation: this.annotation.id, nrt_neigh: 10}} // eslint-disable-line camelcase
)).data;

this.$eventBus.$emit('show-similar-annotations', data);
Expand Down
3 changes: 2 additions & 1 deletion src/components/annotations/SimilarAnnotation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ export default {
try {
await new AnnotationTerm({annotation: this.annotation.id, term: term.id}).save();
this.$emit('updateTermsOrTracks', this.annotation);
} catch (error) {
}
catch (error) {
this.$notify({type: 'error', text: this.$t('notif-error-add-term')});
}
},
Expand Down
8 changes: 4 additions & 4 deletions src/components/search/MetadataFilter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,10 @@ export default {
},
props: {
format: {type: String, default: ''},
imageIds: {type: Array, default: []},
keys: {type: Array, default: []},
max: {type: Object, default: {}},
type: {type: Object, default: {}},
imageIds: {type: Array, default: () => []},
keys: {type: Array, default: () => []},
max: {type: Object, default: () => {}},
type: {type: Object, default: () => {}},
},
data() {
return {
Expand Down
10 changes: 5 additions & 5 deletions src/components/search/MetadataSearch.vue
Original file line number Diff line number Diff line change
Expand Up @@ -147,18 +147,18 @@ export default {
MetadataFilter,
},
props: {
formats: {type: Array, default: []},
formats: {type: Array, default: () => []},
imageIds: {type: Object, default: null},
magnifications: {type: Array, default: []},
magnifications: {type: Array, default: () => []},
maxHeight: {type: Number, default: 0},
maxWidth: {type: Number, default: 0},
maxNbJobAnnotations: {type: Number, default: 0},
maxNbReviewedAnnotations: {type: Number, default: 0},
maxNbUserAnnotations: {type: Number, default: 0},
metadata: {type: Object, default: null},
resolutions: {type: Array, default: []},
tags: {type: Array, default: []},
vendors: {type: Array, default: []},
resolutions: {type: Array, default: () => []},
tags: {type: Array, default: () => []},
vendors: {type: Array, default: () => []},
},
data() {
return {
Expand Down
4 changes: 2 additions & 2 deletions src/components/viewer/panels/FollowPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export default {
if(!this.wsConnected){
this.initWebSocket();
this.wsInterval = setInterval(() => {
this.sendPosition();
this.sendPosition();
}, constants.TRACKING_REFRESH_INTERVAL);
}
this.trackedUser = null;
Expand Down Expand Up @@ -326,7 +326,7 @@ export default {
}
this.trackedUser = null;
},

sendPosition() {
const shouldRefreshForKeepAlive = Date.now() - this.lastPositionUpdate > constants.WS_POSITION_KEEP_ALIVE_INTERVAL;
if (this.broadcast && this.wsConnected && (this.viewerPositionChanged || shouldRefreshForKeepAlive)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export default {
},

setApparentChannels(state, apparentChannels) {
state.apparentChannels = apparentChannels;
state.apparentChannels = apparentChannels;
},

setApparentChannelVisibility(state, {indexApparentChannel, visible}) {
Expand Down
Loading