PageSourceSearch

https://casinosanalyzer.ca/build/midori/assets/js/components/EditorialGuidelinesHero.min.js?v=5801963

js casinosanalyzer.ca collected 2026-09-25 23:52:34 UTC 2,707 bytes, 1 lines download raw bytes

1const HERO_TNC_SELECTOR='.editorialGuidelines__hero-tnc[data-element="editorial_intro-block"]',CAROUSEL_SELECTOR="[data-editorial-carousel]",EMAIL_COPY_SELECTOR="#editorialCopyEmailBtn";export class EditorialGuidelinesHero{constructor(){this.initHeroBlocks(),this.initCarousels(),this.initEmailCopy()}initHeroBlocks(){document.querySelectorAll(HERO_TNC_SELECTOR).forEach(e=>{const t=e.querySelector(".show-more-link");if(!t)return;const i=()=>e.classList.add("shown");t.addEventListener("click",e=>{e.preventDefault(),i()}),t.addEventListener("keydown",e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),i())})})}initCarousels(){document.querySelectorAll(CAROUSEL_SELECTOR).forEach(e=>{const t=e.querySelector(".editorialGuidelines__carouselTrack"),i=Array.from(e.querySelectorAll(".editorialGuidelines__carouselSlide")),l=e.querySelector(".editorialGuidelines__carouselArrow--prev"),o=e.querySelector(".editorialGuidelines__carouselArrow--next"),n=e.querySelector(".editorialGuidelines__carouselDots"),r=e.classList.contains("editorialGuidelines__placeholder--carouselSingle");if(!t||i.length<2||!l||!o||!n)return;let a=0,s=!1;const d=()=>r?1:window.innerWidth>=768?2:1,c=()=>Math.ceil(i.length/d()),u=()=>{const e=d(),s=c(),u=Math.max(0,s-1),y=r?i.length>1:!(2===i.length&&2===e);a>u&&(a=u),t.style.transform=`translateX(-${a*(100/e)}%)`,l.disabled=0===a,o.disabled=a===u,l.style.display=y?"":"none",o.style.display=y?"":"none",n.style.display=y?"":"none",n.querySelectorAll(".editorialGuidelines__carouselDot").forEach((e,t)=>{e.classList.toggle("active",t===a)})},y=()=>{const e=c();s?n.innerHTML="":s=!0,Array.from({length:e}).forEach((e,t)=>{const i=document.createElement("button");i.type="button",i.className="editorialGuidelines__carouselDot",i.setAttribute("aria-label",`Go to slide ${t+1}`),i.addEventListener("click",()=>{a=t,u()}),n.appendChild(i)})};l.addEventListener("click",()=>{a>0&&(a--,u())}),o.addEventListener("click",()=>{a<i.length-1&&(a++,u())}),window.addEventListener("resize",()=>{y(),u()}),y(),u()})}initEmailCopy(){const e=document.querySelector(EMAIL_COPY_SELECTOR),t=document.getElementById("editorialCopyIcon"),i=document.getElementById("editorialCheckIcon");e&&t&&i&&e.addEventListener("click",async()=>{const l=e.dataset.email||document.getElementById("editorialContactEmail")?.textContent?.trim();if(l)try{await navigator.clipboard.writeText(l),e.classList.add("editorialGuidelines__email-copy--copied"),t.style.display="none",i.style.display="block",setTimeout(()=>{e.classList.remove("editorialGuidelines__email-copy--copied"),t.style.display="block",i.style.display="none"},2e3)}catch(e){}})}}export const newEditorialGuidelinesHero=()=>new EditorialGuidelinesHero;

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.