feat(client): Improve image viewer
Resolve #7545 Resolve #6811 Close #7808
This commit is contained in:
@@ -12,7 +12,6 @@
|
||||
<a
|
||||
:href="image.url"
|
||||
:title="image.name"
|
||||
@click.prevent="onClick"
|
||||
>
|
||||
<ImgWithBlurhash :hash="image.blurhash" :src="url" :alt="image.comment" :title="image.comment" :cover="false"/>
|
||||
<div class="gif" v-if="image.type === 'image/gif'">GIF</div>
|
||||
@@ -73,17 +72,6 @@ export default defineComponent({
|
||||
immediate: true,
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
onClick() {
|
||||
if (this.$store.state.imageNewTab) {
|
||||
window.open(this.image.url, '_blank');
|
||||
} else {
|
||||
os.popup(ImageViewer, {
|
||||
image: this.image
|
||||
}, {}, 'closed');
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
|
Reference in New Issue
Block a user