text: function findVideos(){for(var e=document.querySelectorAll(".video"),t=0;t<e.length;t++)setupVideo(e[t])}function setupVideo(e){var t=e.querySelector(".video__link"),r=e.querySelector(".video__media"),i=e.querySelector(".video__button"),o=parseMediaURL(r);e.addEventListener("click",function(){var r=createIframe(o);e.removeChild(t),e.removeChild(i),e.appendChild(r)}),t.removeAttribute("href"),e.classList.add("video--enabled")}function parseMediaURL(e){return e.src.match(/https:\/\/i\.ytimg\.com\/vi\/([a-zA-Z0-9_-]+)\/maxresdefault\.jpg/i)[1]}function createIframe(e){var t=document.createElement("iframe");return t.setAttribute("allowfullscreen",""),t.setAttribute("allow","autoplay"),t.setAttribute("src",generateURL(e)),t.classList.add("video__media"),t}function generateURL(e){return"https://www.youtube.com/embed/"+e+"?rel=0&showinfo=0&autoplay=1"}findVideos();
  