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QAC1CC,GAAG,EAAE,KAAK;QAAI;QACdC,KAAK,EAAE,YAAY,CAAE;MACvB;IACF,CAAC,CAAC;;IAEFL,QAAQ,CACLR,EAAE,CAAC,mBAAmB,EAAE;MAACC,OAAO,EAAE,CAAC;MAAEC,QAAQ,EAAE;IAAC,CAAC,CAAC;IAErD,MAAMY,YAAY,GAAIC,CAAC,IAAK;MAC1BA,CAAC,CAACC,cAAc,EAAE;MAClBvB,MAAM,CAACwB,QAAQ,CAAC;QAACC,GAAG,EAAEzB,MAAM,CAAC0B,WAAW;QAAEC,IAAI,EAAC;MAAC,CAAC,CAAC;IACpD,CAAC;IAED,MAAMC,SAAS,GAAG1B,QAAQ,CAAC2B,cAAc,CAAC,gBAAgB,CAAC;IAE3DD,SAAS,CAAC3B,gBAAgB,CAAC,OAAO,EAAEoB,YAAY,CAAC;EACnD;AAEF,CAAC,CAAC,C","sources":["webpack://wp-scripts-starter-theme/./blocks/hero/index.scss?b80a","webpack://wp-scripts-starter-theme/webpack/bootstrap","webpack://wp-scripts-starter-theme/webpack/runtime/make namespace object","webpack://wp-scripts-starter-theme/./blocks/hero/index.js"],"sourcesContent":["// extracted by mini-css-extract-plugin\nexport {};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import './index.scss';\n\n// import { gsap } from \"gsap\";\n// import { ScrollTrigger } from \"gsap/ScrollTrigger\";\n\n\nwindow.addEventListener('load', function(){\n\n if(document.querySelector('.hero-type-home') || document.querySelector('.hero-type-contact')){\n\n const heroTl = gsap.timeline()\n\n heroTl\n .to(\".pd_splide\", {opacity: 1, duration: 2})\n .from(\".pd_hero-image\", {opacity: 0, duration: 2}, \">-2\" )\n .from(\".pd-block-hero .acf-innerblocks-container > *\", {\n opacity: 0,\n y: 20,\n duration: 0.5,\n stagger: { // wrap advanced options in an object\n each: 0.3,\n ease: \"linear\", \n }\n }, '>-1.5')\n .from(\".pd_hero-contact-footer-info\", { opacity: 0,\n y: 20,\n duration: 0.5,}, '>-0.25')\n\n }\n\n\n if(document.querySelector('.hero-type-home')){\n const scrollTl = gsap.timeline({\n scrollTrigger: {\n trigger: '.hero-type-home',\n toggleActions: \"restart none none reverse\",\n pin: false, // pin the trigger element while active\n start: \"bottom 80%\", // when the top of the trigger hits the top of the viewport\n },\n });\n \n scrollTl\n .to('.scroll-indicator', {opacity: 0, duration: 1})\n\n const handleScroll = (e) => {\n e.preventDefault()\n window.scrollTo({top: window.innerHeight, left:0});\n }\n \n const scrollBtn = document.getElementById('pd_hero-scroll')\n \n scrollBtn.addEventListener('click', handleScroll)\n }\n\n})"],"names":["window","addEventListener","document","querySelector","heroTl","gsap","timeline","to","opacity","duration","from","y","stagger","each","ease","scrollTl","scrollTrigger","trigger","toggleActions","pin","start","handleScroll","e","preventDefault","scrollTo","top","innerHeight","left","scrollBtn","getElementById"],"sourceRoot":""}