diff --git a/.dist/file.js b/.dist/file.js index 5d7a689..ee7588d 100644 --- a/.dist/file.js +++ b/.dist/file.js @@ -61,6 +61,10 @@ class File { video.append(source); source.type = this.content_type; video.controls = !temp; + if (this.width) { + video.width = this.width; + video.height = this.height; + } return video; } else if (this.content_type.startsWith('audio/')) { diff --git a/webpage/file.ts b/webpage/file.ts index 21e6e25..12d56c9 100644 --- a/webpage/file.ts +++ b/webpage/file.ts @@ -62,6 +62,10 @@ class File{ video.append(source); source.type=this.content_type; video.controls=!temp; + if(this.width){ + video.width=this.width; + video.height=this.height; + } return video; }else if(this.content_type.startsWith('audio/')){ const audio=document.createElement("audio");