{"version":3,"file":"/js/blocks/featured-service/script.js","mappings":"m0CAAAA,SAASC,iBACR,oBACA,WAECC,OAAOD,iBACN,QACA,WAEKE,OAASH,SAASI,KAAKC,UAAUC,SAAS,aAE7CH,KACEI,aACAC,IACA,6EACA,WAEC,IAAMC,EAAMT,SAASU,iBAAiB,4BAElCD,EAAIE,OAAS,GAEhBF,EAAIG,SACH,SAACC,GAEA,IAAMC,EAAYD,EACZE,EAAQF,EAAGG,cAAc,uBACzBC,EAAUJ,EAAGG,cAAc,yBAE3BE,EAAW,CAChBC,cAAe,CACdC,QAASN,EACTO,MAAO,aACPC,IAAK,aACLC,cAAe,2BAIjBpB,KAAKqB,IAAIT,EAAO,CAACU,MAAO,IAAKC,MAAO,SACpCvB,KAAKqB,IAAIP,EAAS,CAACU,OAAQ,QAE3BxB,KAAKyB,GAAGb,EAAKc,EAAAA,EAAA,GAAMX,GAAQ,IAAEO,MAAO,EAAGK,SAAU,KACjD3B,KAAKyB,GAAGX,EAAOY,EAAAA,EAAA,GAAMX,GAAQ,IAAES,OAAQ,EAAGG,SAAU,IAErD,GAKH,GAKJ,GAGF,G","sources":["webpack://wp-plugin-cirrus-blocks/./blocks/featured-service/script.js"],"sourcesContent":["document.addEventListener(\n\t'DOMContentLoaded',\n\t() => {\n\n\t\twindow.addEventListener(\n\t\t\t'load',\n\t\t\t() => {\n\n\t\t\t\tif (gsap && !document.body.classList.contains('wp-admin')) {\n\n\t\t\t\t\tgsap\n\t\t\t\t\t\t.matchMedia()\n\t\t\t\t\t\t.add(\n\t\t\t\t\t\t\t'screen and (prefers-reduced-motion: no-preference) and (min-width: 768px)',\n\t\t\t\t\t\t\t() => {\n\n\t\t\t\t\t\t\t\tconst els = document.querySelectorAll('.cirrus-featured-service');\n\n\t\t\t\t\t\t\t\tif (els.length > 0) {\n\n\t\t\t\t\t\t\t\t\tels.forEach(\n\t\t\t\t\t\t\t\t\t\t(el) => {\n\n\t\t\t\t\t\t\t\t\t\t\tconst container = el;\n\t\t\t\t\t\t\t\t\t\t\tconst image = el.querySelector('[data-name=\"image\"]');\n\t\t\t\t\t\t\t\t\t\t\tconst overlay = el.querySelector('[data-name=\"overlay\"]');\n\n\t\t\t\t\t\t\t\t\t\t\tconst defaults = {\n\t\t\t\t\t\t\t\t\t\t\t\tscrollTrigger: {\n\t\t\t\t\t\t\t\t\t\t\t\t\ttrigger: container,\n\t\t\t\t\t\t\t\t\t\t\t\t\tstart: '50% bottom',\n\t\t\t\t\t\t\t\t\t\t\t\t\tend: 'center top',\n\t\t\t\t\t\t\t\t\t\t\t\t\ttoggleActions: 'play none none reverse',\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\tgsap.set(image, {scale: 1.5, width: '100%'})\n\t\t\t\t\t\t\t\t\t\t\tgsap.set(overlay, {height: '50%'})\n\n\t\t\t\t\t\t\t\t\t\t\tgsap.to(image, {...defaults, scale: 1, duration: 2})\n\t\t\t\t\t\t\t\t\t\t\tgsap.to(overlay, {...defaults, height: 0, duration: 2})\n\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t)\n\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t);\n\n\t\t\t\t}\n\n\t\t\t}\n\t\t);\n\n\t}\n);"],"names":["document","addEventListener","window","gsap","body","classList","contains","matchMedia","add","els","querySelectorAll","length","forEach","el","container","image","querySelector","overlay","defaults","scrollTrigger","trigger","start","end","toggleActions","set","scale","width","height","to","_objectSpread","duration"],"sourceRoot":""}