PageSourceSearch

https://www.fincantieri.com/etc.clientlibs/fincantieri/clientlibs/…/resources/3006-ad50cb7da596421dab81.js

js fincantieri.com collected 2026-10-02 03:05:11 UTC 7,638 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkaem_maven_archetype=self.webpackChunkaem_maven_archetype||[]).push([[3006],{3006:function(e,t,n){n.r(t);var o=n(6358),i=n(9127);o.ZP.registerPlugin(i.L);const s=document.querySelector(".products-nav-container"),r=s?.closest(".parallax-group-reveal"),c=document.querySelectorAll(".product-section .product-slide"),a=document.querySelector(".product-section .inner-product-section");if(s&&r&&c.length){c.forEach((e=>{e.overlay01=e.querySelector(".product-overlay"),e.slideTitle=e.querySelector(".slide-title"),e.bgElement=e.querySelector(".bg-element")}));let l=!1,d=0,u=0,h=0,m=-1;const p=600;let v=p;const f=window.innerHeight/2,w=window.innerHeight/4,g=window.innerHeight/8;let y,L,b,E=0;function S(){window.matchMedia("(min-width: 1024px)").matches&&(y||(y=setTimeout((()=>{_(),B(),y=null,clearTimeout(L),L=setTimeout((()=>{if(l)return;const e=document.querySelector(".product-section .current-slide");e&&Math.abs(e.getAttribute("data-last-offset"));h!=m&&Z(parseFloat(c[h-1]?.dataset.slideTop))}),75)}),8)))}function q(){clearTimeout(b),b=setTimeout((()=>{R(),W(),B(),_();window.matchMedia("(min-width: 1024px)").matches||x()}),250)}function A(){const e=window.matchMedia("(pointer: coarse)").matches,t=window.matchMedia("(hover: none)").matches;return e||t}M(),N(),W(),B(),P(),R(),X(),k();let C=window.innerWidth;function T(){const e=window.innerWidth;e!==C&&(C=e,q())}A()?window.addEventListener("resize",T):window.addEventListener("resize",q,{passive:!0}),window.addEventListener("scroll",S,{passive:!0}),H();function x(){setTimeout((()=>{const e=s.querySelectorAll(".inner-products-nav-container .nav-bullet"),t=s.querySelectorAll(".inner-products-nav-container .dash-graph");t.forEach((e=>{e.classList.add("no-transition")})),e[e.length-1].click(),setTimeout((()=>{e[0].click(),setTimeout((()=>{t.forEach((e=>{e.classList.remove("no-transition")}))}),100)}),1)}),1)}function k(){const e=document.createElement("div");e.classList.add("bottom-gradient-element"),a.appendChild(e)}function M(){const e=a.closest(".parallax-section");if(e){e.style.background="rgba(0,0,0,0)";const t=e.querySelector(".background-image-container"),n=document.createElement("div");n.className="product-section fixed-products-bg",document.querySelector(".main-container")?.appendChild(n),t&&(t.classList.add("show"),n.appendChild(t))}}function H(){a.addEventListener("scroll",$,{passive:!0});let e,t,n=!1;a.addEventListener("mousedown",(o=>{n=!0,a.classList.remove("mandatory-smooth-scroll"),a.classList.add("dragging"),e=o.pageX-a.offsetLeft,t=a.scrollLeft})),a.addEventListener("mouseleave",(()=>{n=!1,a.classList.add("mandatory-smooth-scroll"),a.classList.remove("dragging")})),a.addEventListener("mouseup",(()=>{n=!1,a.classList.add("mandatory-smooth-scroll"),a.classList.remove("dragging")})),a.addEventListener("mousemove",(o=>{if(!n)return;o.preventDefault();const i=1.5*(o.pageX-a.offsetLeft-e);a.scrollLeft=t-i}))}function R(){window.matchMedia("(min-width: 1024px)").matches?setTimeout((()=>{if(document.querySelector(".fixed-products-nav"))document.querySelector(".fixed-products-nav").appendChild(s);else{const e=document.createElement("div");e.className="product-section fixed-products-nav",e.appendChild(s),document.querySelector(".main-container")?.appendChild(e)}}),500):document.querySelector(".product-section").appendChild(s)}function B(){let e=0,t=r.previousElementSibling;const n=[];for(;t;)n.push(t.getBoundingClientRect().height),t=t.previousElementSibling;if(e=n.reduce(((e,t)=>e+t),0),E!=e){E=e,c.forEach(((t,n)=>{t.setAttribute("data-slide-top",e+window.innerHeight*n)}));s.querySelectorAll(".inner-products-nav-container .nav-bullet").forEach(((t,n)=>{t.setAttribute("data-slide-top",e+window.innerHeight*n)}))}}function P(){s.querySelectorAll(".inner-products-nav-container .nav-bullet").forEach(((e,t)=>{e.addEventListener("click",(()=>{if(window.matchMedia("(min-width: 1024px)").matches){const t=parseFloat(e.dataset.slideTop);v=0,o.ZP.to(window,{scrollTo:t,duration:0,ease:"power1.out"})}else{let e=window.innerWidth*t;a.scrollLeft=e}})),e.addEventListener("keydown",(function(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),e.click())}))}))}
1function W(){c.forEach(((e,t)=>{e.setAttribute("data-slide-center",window.innerHeight*t)}));const e=s.querySelector(".inner-products-nav-container");if(!e)return;const t=e.querySelectorAll(".nav-bullet-label"),n=e.getBoundingClientRect().height,o=Array.from(t).reduce(((e,t)=>e+t.getBoundingClientRect().height),0);d=(n-o)/2;const i=e.getBoundingClientRect().width,r=Array.from(t).reduce(((e,t)=>e+t.getBoundingClientRect().width),0);u=(i-r)/2}window.matchMedia("(min-width: 1024px)").matches||x();const Z=e=>{!l&&e&&(l=!0,o.ZP.to(window,{scrollTo:e,duration:v/1e3,ease:"sine.out",onComplete:()=>{m=h,setTimeout((()=>{v=p,l=!1}),v)}}))};function $(){let e=(a.scrollLeft+window.innerWidth)/window.innerWidth,t=0;c.forEach(((n,o)=>{n.classList.remove("current-slide"),Math.floor(e)-1==o&&(t=o+1,n.classList.add("current-slide"))})),D(t)}function _(){let e=0;e=r.getBoundingClientRect().top;const t=-e;let n=0,o=!1;c.forEach(((e,i)=>{const r=parseFloat(e.dataset.slideCenter);let c=Math.floor(t-r),a=(c+f)/window.innerHeight;e.classList.remove("current-slide"),a>0&&a<1&&(n=i+1,o=!0,s.classList.contains("show-nav")&&e.classList.add("current-slide")),e.setAttribute("data-last-offset",c)}));const i=c.length;e-w>0||Math.abs(e)>window.innerHeight*(i-1)+g||!o?F():0===n&&s.classList.contains("show-nav")||z(n)}function F(){h=0,m=-1,s.classList.contains("show-nav")&&o.ZP.to(s,{opacity:0,duration:.2,onComplete:()=>{s.classList.remove("show-nav"),document.querySelector(".product-section .current-slide")?.classList.remove("current-slide")}})}function z(e){D(e),h=e,s.classList.add("show-nav"),o.ZP.to(s,{opacity:1,duration:.3})}function D(e){const t=s.querySelectorAll(".inner-products-nav-container .nav-bullet"),n=window.matchMedia("(min-width: 1024px)");t.forEach((e=>{e.classList.remove("active-bullet");e.querySelectorAll(".dash-graph").forEach((e=>{n.matches?e.style.height="0px":e.style.width="0px"}))}));const o=t[e-1];if(o){o.classList.add("active-bullet");o.querySelectorAll(".dash-graph").forEach((e=>{n.matches?(e.style.height=d+"px",e.style.width="auto"):(e.style.width=u+"px",e.style.height="100%")}))}}function N(){const e=Array.from(c).map(((e,t)=>{const n=e.querySelector(".slide-title")?.innerHTML||"";let o="00"+t,i="0"+t;return 0===t&&(o="&nbsp;―",i="|"),`\n                <div class="nav-bullet">\n                    <div class="dash-graph"></div>\n                    <div class="nav-bullet-label"\n                         role="button"\n                         aria-label="Vai alla slide ${n}"\n                    >\n                        <div class="nav-bullet-number nav-bullet-desktop">&#8203;${o}&#8203;</div>\n                        <div class="nav-bullet-number nav-bullet-mobile">&#8203;${i}&#8203;</div>\n                        <div class="nav-bullet-title">${n}</div>\n                    </div>\n                    <div class="dash-graph"></div>\n                </div>\n            `})).join(""),t=s.querySelector(".inner-products-nav-container");t&&(t.innerHTML=e)}
1function X(){c.forEach((e=>{const t=e.querySelector(".cta-button");t&&t.addEventListener("focus",(()=>{const t=Array.from(c).indexOf(e),n=s.querySelectorAll(".nav-bullet")[t];l=!1,n.click(),document.querySelector(".product-section .current-slide")||setTimeout((()=>{document.querySelectorAll(".product-section .product-slide")[t].classList.add("current-slide"),n.click()}),500)}))}))}}else console.warn("Required elements not found")}}]);

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.