autoplay when clicked

This commit is contained in:
MathMan05 2024-09-05 11:06:19 -05:00
parent 715eae7ff2
commit 0f497aaaab
2 changed files with 2 additions and 2 deletions

View file

@ -226,7 +226,7 @@ class Embed {
img.onclick = async () => {
img.remove();
const iframe = document.createElement("iframe");
iframe.src = this.json.video.url;
iframe.src = this.json.video.url + "?autoplay=1";
if (this.json.thumbnail.width && this.json.thumbnail.width) {
iframe.style.width = this.json.thumbnail.width + "px";
iframe.style.height = this.json.thumbnail.height + "px";