Skip to content

Commit

Permalink
admin页面预览支持mp4视频 (cf-pages#63)
Browse files Browse the repository at this point in the history
  • Loading branch information
Airmole authored Aug 27, 2023
1 parent 1a4b6de commit 85ff118
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion admin.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,11 @@
label="preview"
prop="preview">
<template slot-scope="scope">
<video v-if="scope.row.name.indexOf('.mp4')>0" style="width: 100%; height: 100%;" controls>
<source :src="'/file/'+scope.row.name" type="video/mp4">
</video>
<el-image
v-else
style="width: 100%; height: 100%;"
:src="'/file/'+scope.row.name"
:zoom-rate="1.2"
Expand Down Expand Up @@ -277,4 +281,4 @@
y=l.getElementsByTagName(r)[0];y.parentNode.insertBefore(t,y);
})(window, document, "clarity", "script", "7t5ai7agat");
</script>
</html>
</html>

0 comments on commit 85ff118

Please sign in to comment.