🐛Fix misjudged file to image format #88
This commit is contained in:
parent
10d6a95e3c
commit
8782b4396e
@ -132,7 +132,7 @@ export default {
|
|||||||
...mapState("acrou/view", ["mode"]),
|
...mapState("acrou/view", ["mode"]),
|
||||||
images() {
|
images() {
|
||||||
return this.files.filter(
|
return this.files.filter(
|
||||||
(file) => file.mimeType.indexOf("image") != -1
|
(file) => file.mimeType.startsWith("image/")
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
renderHeadMD() {
|
renderHeadMD() {
|
||||||
@ -261,7 +261,7 @@ export default {
|
|||||||
this.$viewer = viewer;
|
this.$viewer = viewer;
|
||||||
},
|
},
|
||||||
action(file, target) {
|
action(file, target) {
|
||||||
if (file.mimeType.indexOf("image") != -1) {
|
if (file.mimeType.startsWith("image/")) {
|
||||||
this.viewer = true;
|
this.viewer = true;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
let index = this.images.findIndex((item) => item.path === file.path);
|
let index = this.images.findIndex((item) => item.path === file.path);
|
||||||
|
Loading…
Reference in New Issue
Block a user