window.addEventListener("load", function () {
const videos = document.querySelectorAll("video");
videos.forEach(function(video) {
video.loop = false;
video.removeAttribute("loop");
video.autoplay = false;
video.removeAttribute("autoplay");
video.onended = function () {
this.pause();
this.currentTime = this.duration;
this.removeAttribute("src");
this.load();
};
});
});