feat: add image thumbnails support (#980)

* set max image preview size to 1080x1080px
This commit is contained in:
monkeyWie authored and GitHub committed 2020-06-25 09:37:13 +02:00
1 parent 4c20772e11
commit 6b0d49b1fc
8 files changed
+137 -9

No files matched your search

+7 -1
View File
@@ -86,8 +86,14 @@ export default {
download () {
return `${baseURL}/api/raw${this.req.path}?auth=${this.jwt}`
},
previewUrl () {
if (this.req.type === 'image') {
return `${baseURL}/api/preview/big${this.req.path}?auth=${this.jwt}`
}
return `${baseURL}/api/raw${this.req.path}?auth=${this.jwt}`
},
raw () {
return `${this.download}&inline=true`
return `${this.previewUrl}&inline=true`
}
},
async mounted () {