Admin settings alignment fix

This commit is contained in:
2026-03-08 01:15:41 -04:00
parent 8c1ad49518
commit c5d8630ca9
3 changed files with 3 additions and 87 deletions

View File

@@ -173,7 +173,8 @@
function openVideoModal(url) {
var ytId = parseYouTubeId(url);
if (ytId) {
videoPlayer.innerHTML = '<iframe src="https://www.youtube.com/embed/' + ytId + '?autoplay=1&rel=0" allow="autoplay; encrypted-media" allowfullscreen></iframe>';
var origin = encodeURIComponent(window.location.origin);
videoPlayer.innerHTML = '<iframe src="https://www.youtube.com/embed/' + ytId + '?autoplay=1&rel=0&origin=' + origin + '&enablejsapi=1" allow="autoplay; encrypted-media" allowfullscreen frameborder="0"></iframe>';
} else {
videoPlayer.innerHTML = '<video src="' + url + '" controls autoplay></video>';
}