PageSourceSearch

https://electric.pl/_next/static/chunks/app/layout-d0737a2ca4ff5c54.js

js electric.pl collected 2026-10-04 22:31:15 UTC 41,852 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{2121:(e,t,i)=>{Promise.resolve().then(i.t.bind(i,35109,23)),Promise.resolve().then(i.t.bind(i,62312,23)),Promise.resolve().then(i.bind(i,39680)),Promise.resolve().then(i.bind(i,67867)),Promise.resolve().then(i.bind(i,91353)),Promise.resolve().then(i.bind(i,74463)),Promise.resolve().then(i.bind(i,1517)),Promise.resolve().then(i.bind(i,88449)),Promise.resolve().then(i.bind(i,40159)),Promise.resolve().then(i.bind(i,49298)),Promise.resolve().then(i.bind(i,89033)),Promise.resolve().then(i.bind(i,48358)),Promise.resolve().then(i.bind(i,33227)),Promise.resolve().then(i.bind(i,41392)),Promise.resolve().then(i.bind(i,1205)),Promise.resolve().then(i.bind(i,17720)),Promise.resolve().then(i.bind(i,84915)),Promise.resolve().then(i.bind(i,75216))},39680:(e,t,i)=>{"use strict";i.d(t,{default:()=>o});var n=i(95155),a=i(54203),s=i(76046),r=i(12115);let l=i(2818).env.NEXT_PUBLIC_FACEBOOK_PIXEL_ID||"";function o(){let e=(0,s.usePathname)(),t=(0,s.useSearchParams)(),[i,o]=(0,r.useState)(!1),[c,d]=(0,r.useState)(!1);return((0,r.useEffect)(()=>{d(!0)},[]),(0,r.useEffect)(()=>{let e=()=>{try{let e=localStorage.getItem("cookieConsent");if(e){let t=JSON.parse(e);o(!0===t.marketing)}}catch(e){console.error("Error checking cookie consent:",e)}};e();let t=()=>{e()};return window.addEventListener("cookieConsentChanged",t),()=>{window.removeEventListener("cookieConsentChanged",t)}},[]),(0,r.useEffect)(()=>{i&&void 0!==window.fbq&&window.fbq("track","PageView")},[e,t,i]),c&&l&&i)?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(a.default,{id:"facebook-pixel",strategy:"afterInteractive",dangerouslySetInnerHTML:{__html:"\n            !function(f,b,e,v,n,t,s)\n            {if(f.fbq)return;n=f.fbq=function(){n.callMethod?\n            n.callMethod.apply(n,arguments):n.queue.push(arguments)};\n            if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\n            n.queue=[];t=b.createElement(e);t.async=!0;\n            t.src=v;s=b.getElementsByTagName(e)[0];\n            if(s && s.parentNode){s.parentNode.insertBefore(t,s)}\n            else{b.head.appendChild(t)}}(window, document,'script',\n            'https://connect.facebook.net/en_US/fbevents.js');\n            fbq('init', '".concat(l,"');\n            fbq('track', 'PageView');\n          ")}}),(0,n.jsx)("noscript",{children:(0,n.jsx)("img",{height:"1",width:"1",style:{display:"none"},src:"https://www.facebook.com/tr?id=".concat(l,"&ev=PageView&noscript=1")})})]}):null}},91353:(e,t,i)=>{"use strict";i.d(t,{default:()=>l});var n=i(95155),a=i(12115),s=i(93469),r=i(67396);i(56676);let l=()=>{let[e,t]=(0,a.useState)(!1);(0,a.useEffect)(()=>{let e=localStorage.getItem("cookieConsent");if(e)try{JSON.parse(e).statistics&&window.dispatchEvent(new Event("cookieConsentChanged"))}catch(e){console.error("Error reading cookie consent:",e)}},[]);let i=()=>{};return(0,n.jsx)(s.Ay,{location:"bottom",buttonText:"Akceptuję wszystkie",declineButtonText:"Odrzuć opcjonalne",enableDeclineButton:!0,cookieName:"electricCookieConsent",onAccept:()=>{localStorage.setItem("cookieConsent",JSON.stringify({necessary:!0,statistics:!0,marketing:!0,timestamp:new Date().toISOString()})),i(),window.dispatchEvent(new Event("cookieConsentChanged"))},onDecline:()=>{localStorage.setItem("cookieConsent",JSON.stringify({necessary:!0,statistics:!1,marketing:!1,timestamp:new Date().toISOString()})),window.dispatchEvent(new Event("cookieConsentChanged"))},style:{background:"#fff",boxShadow:"0 -2px 20px rgba(0,0,0,0.15)",alignItems:"center",justifyContent:"center",flexWrap:"wrap"},containerClasses:"cookie-consent-container",buttonStyle:{background:"#d60000",color:"#fff",fontSize:"14px",padding:"12px 24px",borderRadius:"6px",border:"none",cursor:"pointer",fontWeight:"600",transition:"background 0.2s"},declineButtonStyle:{background:"#f0f0f0",color:"#333",fontSize:"14px",padding:"12px 24px",borderRadius:"6px",border:"none",cursor:"pointer",fontWeight:"600",transition:"background 0.2s"},buttonWrapperClasses:"cookie-consent-buttons",expires:365,overlay:!0,overlayStyle:{background:"rgba(0,0,0,0.3)"},children:(0,n.jsx)("div",{className:"cookie-consent-content",children:(0,n.jsxs)("p",{className:"cookie-consent-text",children:["Używamy plik\xf3w cookies, aby zapewnić najlepszą jakość usług. Cookies niezbędne są zawsze aktywne. Możesz zaakceptować wszystkie lub odrzucić opcjonalne cookies (statystyki, marketing)."," ",(0,n.jsx)(r.default,{href:"/polityka-prywatnosci",className:"cookie-consent-link",children:"Więcej w Polityce Prywatności"})]})})})}},74463:(e,t,i)=>{"use strict";i.d(t,{default:()=>d});var n=i(95155);i(12115);var a=i(11536);i(95127);var s=i(61039);let r={src:"/_next/static/media/elektro_omega.9c7dadce.svg",height:129,width:349,blurWidth:0,blurHeight:0};var l=i(67396),o=i(5565),c=i(2615);let d=()=>{let{data:e}=(0,c.useSession)();return(0,n.jsx)("footer",{className:"footer",children:(0,n.jsxs)("div",{className:"footer__c
1ontainer",children:[(0,n.jsx)("div",{className:"footer__logo",children:(0,n.jsx)(l.default,{href:"/",children:(0,n.jsx)(o.default,{src:s.A,alt:"Electric Logo",unoptimized:!0})})}),(0,n.jsxs)("div",{className:"footer__columns",children:[(0,n.jsxs)("div",{className:"footer__column",children:[(0,n.jsx)("h4",{className:"footer__heading",children:"O sklepie"}),(0,n.jsx)("p",{className:"footer__text",children:"Jesteśmy doświadczoną hurtownią elektrotechniczną działającą od ponad 25 lat. Oferujemy szeroki asortyment produkt\xf3w elektrycznych najwyższej jakości, gwarantując profesjonalną obsługę oraz konkurencyjne ceny."})]}),(0,n.jsxs)("div",{className:"footer__column",children:[(0,n.jsx)("h4",{className:"footer__heading",children:"Informacje"}),(0,n.jsxs)("ul",{className:"footer__list",children:[(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"/regulamin",className:"footer__link",children:"Regulamin"})}),(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"/polityka-prywatnosci",className:"footer__link",children:"Polityka prywatności"})}),(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:e?"/konto/zwroty":"/login",className:"footer__link",children:"Zwroty"})}),(0,n.jsx)("li",{children:(0,n.jsx)("button",{onClick:()=>{document.cookie="electricCookieConsent=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;",localStorage.removeItem("cookieConsent"),window.location.reload()},className:"footer__link footer__link--button",style:{background:"none",border:"none",padding:0,cursor:"pointer",textAlign:"left"},children:"Ustawienia cookies"})})]})]}),(0,n.jsxs)("div",{className:"footer__column",children:[(0,n.jsx)("h4",{className:"footer__heading",children:"Obsługa klienta"}),(0,n.jsxs)("ul",{className:"footer__list",children:[(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"/kontakt",className:"footer__link",children:"Kontakt"})}),(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"/dostawa",className:"footer__link",children:"Dostawa"})}),(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"/about-us",className:"footer__link",children:"O nas"})})]})]}),(0,n.jsxs)("div",{className:"footer__column",children:[(0,n.jsx)("h4",{className:"footer__heading",children:"Dane kontaktowe"}),(0,n.jsxs)("p",{className:"footer__text",children:["Electric Krzysztof Gil Oktawian Ambroziak Sp\xf3łka\xa0Jawna",(0,n.jsx)("br",{}),"al. Grunwaldzka 481",(0,n.jsx)("br",{}),"80-309 Gdańsk",(0,n.jsx)("br",{}),(0,n.jsxs)("span",{children:["Email: ",(0,n.jsx)("a",{href:"mailto:[email protected]",style:{color:"inherit",textDecoration:"underline"},children:"[email protected]"})]}),(0,n.jsx)("br",{}),(0,n.jsxs)("span",{children:["Tel: ",(0,n.jsx)("a",{href:"tel:+48604900346",style:{color:"inherit",textDecoration:"underline"},children:"+48 604-900-346"})]}),(0,n.jsx)("br",{}),(0,n.jsx)("span",{style:{marginLeft:"22px"},children:(0,n.jsx)("a",{href:"tel:+48583447354",style:{color:"inherit",textDecoration:"underline"},children:"+48 58 344-73-54"})}),(0,n.jsx)("br",{}),(0,n.jsx)("span",{style:{marginLeft:"22px"},children:(0,n.jsx)("a",{href:"tel:+48583452163",style:{color:"inherit",textDecoration:"underline"},children:"+48 58 345-21-63"})})]})]})]}),(0,n.jsxs)("div",{className:"footer__social",children:[(0,n.jsx)("a",{href:"https://www.facebook.com/Electricgdansk",target:"_blank",rel:"noopener noreferrer",className:"footer__social-link","aria-label":"Facebook",children:(0,n.jsx)(a.ok6,{size:20})}),(0,n.jsx)("a",{href:"https://www.instagram.com/electricoze/",target:"_blank",rel:"noopener noreferrer",className:"footer__social-link","aria-label":"Instagram",children:(0,n.jsx)(a.ao$,{size:20})}),(0,n.jsx)("a",{href:"https://www.linkedin.com/company/electricgdansk/",target:"_blank",rel:"noopener noreferrer",className:"footer__social-link","aria-label":"LinkedIn",children:(0,n.jsx)(a.H1h,{size:20})})]}),(0,n.jsxs)("div",{className:"footer__omega",children:[(0,n.jsx)("p",{className:"footer__omega-text",children:"Należymy do grupy hurtowni"}),(0,n.jsx)(o.default,{src:r,alt:"Elektro Omega - Grupa Hurtowni Elektrycznych",width:250,height:80,className:"footer__omega-logo",style:{width:"auto",height:"auto"},unoptimized:!0})]}),(0,n.jsx)("div",{className:"footer__bottom-bar",children:(0,n.jsxs)("p",{className:"footer__bottom-text",children:["\xa9 ",new Date().getFullYear()," Electric.pl - Wszelkie prawa zastrzeżone"]})})]})})}},1517:(e,t,i)=>{"use strict";i.d(t,{default:()=>r});var n=i(95155),a=i(12115),s=i(67396);function r(){let[e,t]=(0,a.useState)(!1),[i,r]=(0,a.useState)(!0);return((0,a.useEffect)(()=>{let e=()=>{r(!0),t(!0),setTimeout(()=>t(!1),4e3)},i=()=>{r(!1),t(!0),setTimeout(()=>t(!1),4e3)};return window.addEventListener("favorite:added",e),window.addEventListener("favorite:removed",i),()=>{window.removeEventListener("favorite:added",e),window.removeEventListener("favorite:removed",i)}},[]),e)?(0,n.jsxs)("div",{className:"fav-toast",children:[(0,n.jsx)("p",{children:i?"Dodano do ulubionych.":"Usunięto z ulubionych."}),(0,n.jsxs)("div",{className:"actions",style:{display:"flex",gap:"8px",alignItems:"center"},children:[i&&(0,n.jsx)(s.default,{href:"/ulubione",children:"Pokaż wszystkie"}),(0,n.jsx)("button",{onClick:()=>t(!1),children:"Zamknij"})]})]}):null}},88449:(e,t,i)=>{"use strict";i.d(t,{default:()=>o});var n=i(95155),a=i(84915),s=i(18474),r=i(76046),l=i(12115);function o(){let{state:e}=(0,a._)(),t=(0,r.usePathname)(),[i,o]=(0,l.useState)(!1);if((0,l.useEffect)(()=>{let e=()=>{let e=document.querySelector(".categories__mobileButton"),t=document.body.classList.contains("has-categories-button"),i=!!e||t;return o(i),i};e();
1let t=setTimeout(e,100),i=setTimeout(e,300),n=setTimeout(e,500),a=setTimeout(e,1e3),s=new MutationObserver(()=>{e()});return s.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class"]}),()=>{clearTimeout(t),clearTimeout(i),clearTimeout(n),clearTimeout(a),s.disconnect()}},[t]),(null==t?void 0:t.startsWith("/koszyk"))||(null==t?void 0:t.startsWith("/zamowienie")))return null;let c=e.items.reduce((e,t)=>e+t.qty,0);return(0,n.jsxs)("button",{className:"floating-cart-button","aria-label":"Otw\xf3rz koszyk",onClick:()=>{window.dispatchEvent(new CustomEvent("cart:open"))},style:{bottom:i?"170px":"90px"},children:[(0,n.jsx)(s.A,{size:24,strokeWidth:2.5}),c>0&&(0,n.jsx)("span",{className:"floating-cart-badge",children:c})]})}},40159:(e,t,i)=>{"use strict";i.d(t,{default:()=>u});var n=i(95155),a=i(12115),s=i(76046),r=i(5565),l=i(1572);i(57417);var o=i(11825),c=i(34390);function d(e){let{open:t,onClose:i}=e;return(0,a.useEffect)(()=>(t?document.body.classList.add("no-scroll"):document.body.classList.remove("no-scroll"),()=>{document.body.classList.remove("no-scroll")}),[t]),(0,a.useEffect)(()=>{let e=e=>{"Escape"===e.key&&t&&i()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t,i]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"mobile-search-backdrop ".concat(t?"open":""),onClick:i,"aria-hidden":"true"}),(0,n.jsxs)("div",{className:"mobile-search-modal ".concat(t?"open":""),role:"dialog","aria-modal":"true","aria-label":"Wyszukiwarka",children:[(0,n.jsxs)("div",{className:"mobile-search-header",children:[(0,n.jsx)("h2",{className:"mobile-search-title",children:"Wyszukaj produkty"}),(0,n.jsx)("button",{className:"mobile-search-close",onClick:i,"aria-label":"Zamknij wyszukiwarkę",children:(0,n.jsx)(r.default,{src:c.A,alt:"Zamknij",width:24,height:24,unoptimized:!0})})]}),(0,n.jsx)("div",{className:"mobile-search-content",children:(0,n.jsx)(o.A,{mobileMode:!0,placeholder:"Szukaj po nazwie, indeksie...",onClose:i})})]})]})}function u(){let[e,t]=(0,a.useState)(!1),[i,o]=(0,a.useState)(!1),c=(0,s.usePathname)();return((0,a.useEffect)(()=>{let e=()=>{let e=document.querySelector(".categories__mobileButton"),t=document.body.classList.contains("has-categories-button"),i=!!e||t;return o(i),i};e();let t=setTimeout(e,100),i=setTimeout(e,300),n=setTimeout(e,500),a=setTimeout(e,1e3),s=new MutationObserver(()=>{e()});return s.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class"]}),()=>{clearTimeout(t),clearTimeout(i),clearTimeout(n),clearTimeout(a),s.disconnect()}},[c]),null==c?void 0:c.startsWith("/konto"))?null:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("button",{className:"floating-search-button","aria-label":"Otw\xf3rz wyszukiwarkę",onClick:()=>t(!0),style:{bottom:i?"100px":"20px"},children:(0,n.jsx)(r.default,{src:l.A,alt:"Szukaj",width:24,height:24,unoptimized:!0})}),(0,n.jsx)(d,{open:e,onClose:()=>t(!1)})]})}},49298:(e,t,i)=>{"use strict";i.d(t,{default:()=>a});var n=i(73564);function a(){return(0,n.A)(),null}},89033:(e,t,i)=>{"use strict";i.d(t,{default:()=>c});var n=i(95155),a=i(12115),s=i(76046),r=i(5565),l=i(61039);function o(){return(0,n.jsx)("div",{className:"app-preloader",role:"status","aria-label":"Wczytywanie",children:(0,n.jsxs)("div",{className:"app-preloader__content",children:[(0,n.jsx)(r.default,{src:l.A,alt:"Electric",priority:!0,unoptimized:!0}),(0,n.jsx)("div",{className:"app-preloader__spinner"})]})})}function c(){let e=(0,s.usePathname)(),t=(0,s.useRouter)(),[i,r]=(0,a.useState)(!1),l=(0,a.useRef)(null),c=(0,a.useRef)(null),d=(0,a.useRef)(null),u=(0,a.useRef)(e),m=(0,a.useRef)(!1);return((0,a.useEffect)(()=>{u.current=e},[e]),(0,a.useEffect)(()=>{let e=t.push,i=t.replace;function n(){m.current=!0;let e=Date.now(),t=u.current;d.current&&clearTimeout(d.current),d.current=setTimeout(()=>{m.current&&u.current===t&&null===l.current&&(l.current=e,r(!0))},150)}return t.push=function(){for(var t=arguments.length,i=Array(t),a=0;a<t;a++)i[a]=arguments[a];return n(),e(...i)},t.replace=function(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return n(),i(...t)},()=>{t.push=e,t.replace=i,d.current&&clearTimeout(d.current)}},[]),(0,a.useEffect)(()=>
1{if(m.current=!1,!i)return;let e=Math.max(0,180-(l.current?Date.now()-l.current:0));return c.current&&clearTimeout(c.current),c.current=setTimeout(()=>{r(!1),l.current=null},e),()=>{c.current&&clearTimeout(c.current)}},[e,i]),i)?(0,n.jsx)(o,{}):null}},48358:(e,t,i)=>{"use strict";i.d(t,{default:()=>s});var n=i(12115),a=i(76046);function s(){let e=(0,a.usePathname)();return(0,n.useEffect)(()=>{window.scrollTo(0,0)},[e]),null}},33227:(e,t,i)=>{"use strict";i.d(t,{default:()=>r});var n=i(12115),a=i(88442),s=i(2818);function r(){return(0,a.useReportWebVitals)(e=>{window.gtag&&window.gtag("event",e.name,{value:Math.round("CLS"===e.name?1e3*e.value:e.value),event_category:"Web Vitals",event_label:e.id,non_interaction:!0}),s.env.NEXT_PUBLIC_ANALYTICS_ENDPOINT&&fetch(s.env.NEXT_PUBLIC_ANALYTICS_ENDPOINT,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:e.name,value:e.value,rating:e.rating,delta:e.delta,id:e.id,navigationType:e.navigationType,timestamp:Date.now(),url:window.location.href})}).catch(e=>{console.error("Failed to send web vitals:",e)});{let t={FCP:1800,LCP:2500,FID:100,CLS:.1,TTFB:800,INP:200}[e.name];t&&e.value>t&&console.warn("⚠️ Poor ".concat(e.name,":"),{value:e.value,threshold:t,rating:e.rating})}}),(0,n.useEffect)(()=>{},[]),null}},41392:(e,t,i)=>{"use strict";i.d(t,{Header:()=>z});var n=i(95155),a=i(67396);i(45873);var s=i(61039),r=i(5565),l=i(11825);let o={src:"/_next/static/media/phone-icon.d89f7814.svg",height:117,width:117,blurWidth:0,blurHeight:0},c={src:"/_next/static/media/medal-icon.f986efff.svg",height:293,width:230,blurWidth:0,blurHeight:0},d={src:"/_next/static/media/account-icon.6d4a3f3e.svg",height:133,width:111,blurWidth:0,blurHeight:0},u={src:"/_next/static/media/hamburger-icon.ca2e12dd.svg",height:297,width:297,blurWidth:0,blurHeight:0},m={src:"/_next/static/media/cart-icon.bf08ab1f.svg",height:125,width:126,blurWidth:0,blurHeight:0},h={src:"/_next/static/media/favourite-icon.9fda0ca0.svg",height:112,width:135,blurWidth:0,blurHeight:0};var p=i(12115),v=i(76046),x=i(34390),k=i(17720),b=i(75216),j=i(84915);function f(e){let{open:t,onClose:i}=e,{user:s,loading:l,logout:o}=(0,k.A)(),{state:c}=(0,b.r)(),{state:d}=(0,j._)(),u=(0,v.usePathname)(),[m,h]=(0,p.useState)(!1),f=Object.keys(c.items).length,g=d.items.reduce((e,t)=>e+t.qty,0),y=d.items.reduce((e,t)=>{var i,n;return e+t.price*t.qty+((null===(i=t.cableCutting)||void 0===i?void 0:i.enabled)&&(null===(n=t.cableCutting)||void 0===n?void 0:n.quantity)?t.cableCutting.price*t.cableCutting.quantity:0)},0);(0,p.useEffect)(()=>{h(!0)},[]);let _=async()=>{try{await o(),i()}catch(e){console.error("Błąd wylogowania:",e)}},w=e=>!!("/"===e&&"/"===u||"/konto/kokpit"===e&&"/konto/kokpit"===u||"/"!==e&&"/konto/kokpit"!==e&&(null==u?void 0:u.startsWith(e)));return(0,n.jsxs)("div",{id:"mobile-menu",className:"mobileMenu ".concat(t?"mobileMenu--open":""),role:"dialog","aria-modal":"true",children:[(0,n.jsx)("div",{className:"mobileMenu__backdrop",onClick:i}),(0,n.jsxs)("div",{className:"mobileMenu__panel",children:[(0,n.jsxs)("div",{className:"mobileMenu__header",children:[(0,n.jsx)("h2",{className:"mobileMenu__title",children:"Menu"}),(0,n.jsx)("button",{className:"mobileMenu__close","aria-label":"Zamknij menu",onClick:i,children:(0,n.jsx)(r.default,{src:x.A,alt:"Zamknij",width:24,height:24,unoptimized:!0})})]}),(0,n.jsxs)("nav",{className:"mobileMenu__nav",children:[l?(0,n.jsx)("span",{className:"mobileMenu__loading",children:"Ładowanie..."}):s?(0,n.jsx)(a.default,{href:"/konto/kokpit",onClick:i,className:"mobileMenu__account mobileMenu__account--logged ".concat(w("/konto/kokpit")?"mobileMenu__account--active":""),children:"Moje konto"}):(0,n.jsx)(a.default,{href:"/login",onClick:i,className:"mobileMenu__account mobileMenu__account--login",children:"Zaloguj się"}),(0,n.jsx)(a.default,{href:"/",onClick:i,className:w("/")&&"/"===u?"mobileMenu__link--active":"",children:"Strona gł\xf3wna"}),(0,n.jsx)(a.default,{href:"/produkty",onClick:i,className:w("/produkty")?"mobileMenu__link--active":"",children:"Wszystkie produkty"}),(0,n.jsxs)("button",{onClick:()=>{i(),setTimeout(()=>{window.dispatchEvent(new Event("cart:open"))},300)},className:"mobileMenu__link mobileMenu__withBadge ".concat(w("/koszyk")?"mobileMenu__link--active":""),children:["Koszyk",g>0&&(0,n.jsxs)("span",{className:"mobileMenu__badge",children:[g," | ",y.toFixed(2)," zł"]})]}),(0,n.jsxs)(a.default,{href:"/ulubione",onClick:i,className:"mobileMenu__withBadge ".concat(w("/ulubione")?"mobileMenu__link--active":""),children:["Ulubione",f>0&&(0,n.jsx)("span",{className:"mobileMenu__badge",children:f})]}
1),m&&s&&(0,n.jsx)(a.default,{href:"/konto/zamowienia",onClick:i,className:w("/konto/zamowienia")?"mobileMenu__link--active":"",children:"Moje zam\xf3wienia"}),(0,n.jsx)(a.default,{href:"/kontakt",onClick:i,className:w("/kontakt")?"mobileMenu__link--active":"",children:"Kontakt"}),(0,n.jsx)(a.default,{href:"/about-us",onClick:i,className:w("/about-us")?"mobileMenu__link--active":"",children:"O nas"}),(0,n.jsx)(a.default,{href:"/blog",onClick:i,className:w("/blog")?"mobileMenu__link--active":"",children:"Blog"}),(0,n.jsx)("div",{className:"mobileMenu__divider"}),m&&(s?(0,n.jsx)("button",{onClick:_,className:"mobileMenu__logout",children:"Wyloguj"}):(0,n.jsx)(a.default,{href:"/login",onClick:i,className:"mobileMenu__login",children:"Zaloguj / Zał\xf3ż konto"}))]})]})]})}var g=i(37874),y=i(60384);i(6465),i(2250);var _=i(47658),w=i(56957);function N(e){let{open:t,onClose:i}=e,{state:a,dispatch:s}=(0,j._)(),r=(0,v.useRouter)(),l=e=>{var t,i;return(null===(t=e.cableCutting)||void 0===t?void 0:t.enabled)&&(null===(i=e.cableCutting)||void 0===i?void 0:i.quantity)?e.cableCutting.price*e.cableCutting.quantity:0},o=e=>{var t,i;return(null===(t=e.cableCutting)||void 0===t?void 0:t.enabled)&&(null===(i=e.cableCutting)||void 0===i?void 0:i.quantity)?e.cableCutting.quantity:0},c=a.items.reduce((e,t)=>e+t.price*t.qty,0),d=a.items.reduce((e,t)=>e+l(t),0),u=c+d;(0,p.useMemo)(()=>{let e=a.items.map(e=>({id:e.id,name:e.name,price:e.price,qty:e.qty,shippingType:e.shippingType,shippingUnitType:e.shippingUnitType,image:e.image,stock:e.stock,productId:e.productId,inpostAvailable:e.inpostAvailable,deliveryTime:e.deliveryTime,weightPerUnit:e.weightPerUnit,isDrumProduct:e.isDrumProduct,customShippingPrice:e.customShippingPrice}));return(0,g.NM)(e)},[a.items]);let m=(e,t)=>{var i,n;let r=a.items.find(t=>t.id===e);if(!r)return;if(null===(i=r.cableCutting)||void 0===i?void 0:i.enabled){let i=Math.max(1,t);s({type:"setQty",id:e,qty:null!=r.stock?Math.min(i,r.stock):i});return}let l=(0,w.U)(r),o=null!==(n=r.stock)&&void 0!==n?n:t;s({type:"setQty",id:e,qty:(0,w.O)(t,l,o)})},h=e=>{s({type:"remove",id:e})};return(0,n.jsxs)("div",{className:"cart-drawer ".concat(t?"open":""),"aria-hidden":!t,children:[(0,n.jsx)("div",{className:"cart-drawer__backdrop",onClick:i}),(0,n.jsxs)("aside",{className:"cart-drawer__panel",role:"dialog","aria-modal":"true",children:[(0,n.jsxs)("header",{className:"cart-drawer__header",children:[(0,n.jsx)("h3",{children:"Koszyk"}),(0,n.jsx)("button",{onClick:i,"aria-label":"Zamknij",children:"\xd7"})]}),(0,n.jsx)(y.A,{className:"cart-drawer__content",autoHide:!1,children:0===a.items.length?(0,n.jsx)("p",{children:"Tw\xf3j koszyk jest pusty."}):(0,n.jsx)("ul",{className:"cart-items",children:a.items.map(e=>{let t=e.price*e.qty,i=l(e),a=o(e);return(0,n.jsxs)("li",{className:"cart-item",children:[(0,n.jsx)("img",{src:(0,_._)(e.image||"/trusted/electric-placeholder.jpg"),alt:e.name||""}),(0,n.jsxs)("div",{className:"cart-item__info",children:[(0,n.jsx)("strong",{children:e.name}),a>0&&(0,n.jsxs)("div",{className:"cable-cutting-badge",children:["✂️ Cięcie kabla x",a,": ",i.toFixed(2)," zł"]}),(0,n.jsxs)("div",{className:"cart-item__controls",children:[(0,n.jsx)("button",{type:"button","aria-label":"Zmniejsz ilość",onClick:()=>{var t;return m(e.id,e.qty-((null===(t=e.cableCutting)||void 0===t?void 0:t.enabled)?1:e.orderQuantityMultiple||1))},children:"-"}),(0,n.jsx)("input",{type:"number",min:e.minOrderQuantity||1,step:e.orderQuantityMultiple||1,value:e.qty,onChange:t=>m(e.id,Number(t.target.value)||1)}),(0,n.jsx)("button",{type:"button","aria-label":"Zwiększ ilość",onClick:()=>{var t;return m(e.id,e.qty+((null===(t=e.cableCutting)||void 0===t?void 0:t.enabled)?1:e.orderQuantityMultiple||1))},children:"+"}),(0,n.jsx)("button",{onClick:()=>h(e.id),children:"Usuń"})]})]}),(0,n.jsxs)("div",{className:"cart-item__price",children:[t.toFixed(2)," zł",(0,n.jsxs)("span",{className:"cart-item__price-netto",children:[(t/1.23).toFixed(2)," zł netto"]}),null!=e.stock&&(0,n.jsxs)("div",{className:"stock-hint",children:["Max: ",e.stock]})]})]},e.id)})})}),(0,n.jsxs)("footer",{className:"cart-drawer__footer",children:[a.items.length>0&&(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)("div",{className:"summary-breakdown",children:[(0,n.jsxs)("div",{className:"summary-line",children:[(0,n.jsx)("span",{children:"Produkty:"}),(0,n.jsxs)("strong",{children:[c.toFixed(2)," zł"]})]}),d>0&&(0,n.jsxs)("div",{className:"summary-line",children:[(0,n.jsx)("span",{children:"Cięcia kabla:"}),(0,n.jsxs)("strong",{children:[d.toFixed(2)," zł"]})]}),(0,n.jsxs)("div",{className:"summary summary-total",children:[(0,n.jsx)("span",{children:"Razem"}),(0,n.jsxs)("strong",{children:[u.toFixed(2)," zł"]})]}),(0,n.jsxs)("div",{className:"summary-line summary-line--netto",children:[(0,n.jsx)("span",{children:"w tym netto:"}),(0,n.jsxs)("span",{children:[(u/1.23).toFixed(2)," zł"]})]})]})}),(0,n.jsx)("button",{className:"checkout",disabled:0===a.items.length,onClick:()=>{i(),r.push("/zamowienie")},children:"Przejdź do zam\xf3wienia"})]})]})]})}function z(){let[e,t]=(0,p.useState)(!1),[i,v]=(0,p.useState)(!1),[x,g]=(0,p.useState)(!1),{state:y}=(0,j._)(),{user:_,loading:w}=(0,k.A)(),z=y.items.reduce((e,t)=>
1e+t.qty,0),{state:C}=(0,b.r)(),S=Object.keys(C.items).length,E=y.items.reduce((e,t)=>{var i,n;return e+t.price*t.qty+((null===(i=t.cableCutting)||void 0===i?void 0:i.enabled)&&(null===(n=t.cableCutting)||void 0===n?void 0:n.quantity)?t.cableCutting.price*t.cableCutting.quantity:0)},0);return(0,p.useEffect)(()=>(e?requestAnimationFrame(()=>{let e=window.innerWidth-document.documentElement.clientWidth;requestAnimationFrame(()=>{document.documentElement.style.setProperty("--scrollbar-width","".concat(e,"px")),document.body.classList.add("no-scroll")})}):(document.body.classList.remove("no-scroll"),document.documentElement.style.removeProperty("--scrollbar-width")),()=>{document.body.classList.remove("no-scroll"),document.documentElement.style.removeProperty("--scrollbar-width")}),[e]),(0,p.useEffect)(()=>{let e=()=>v(!0);return window.addEventListener("cart:open",e),()=>window.removeEventListener("cart:open",e)},[]),(0,p.useEffect)(()=>{let e=()=>g(!0);return window.addEventListener("categories:open",e),()=>window.removeEventListener("categories:open",e)},[]),(0,n.jsxs)("header",{className:"header",children:[(0,n.jsxs)("div",{className:"container wrapper",children:[(0,n.jsxs)("div",{className:"header_left wrapper",children:[(0,n.jsx)(a.default,{className:"header__logo",href:"/",children:(0,n.jsx)(r.default,{src:s.A,alt:"Electric Logo",priority:!0,unoptimized:!0})}),(0,n.jsx)("div",{className:"header_searchBar wrapper",children:(0,n.jsx)(l.A,{})})]}),(0,n.jsxs)("div",{className:"header_middle",children:[(0,n.jsx)(r.default,{src:c,alt:"Medal",unoptimized:!0}),(0,n.jsxs)("p",{children:["Od ",(0,n.jsx)("strong",{children:"25 lat"})," na rynku!"]})]}),(0,n.jsxs)("div",{className:"header_right wrapper",children:[(0,n.jsxs)(a.default,{className:"header_menuLink",href:"/ulubione",children:[(0,n.jsx)(r.default,{src:h,alt:"Ulubione",unoptimized:!0}),S>0&&(0,n.jsx)("div",{className:"cartCounter",style:{right:"auto",left:"22px"},children:S}),(0,n.jsx)("span",{children:"Ulubione"})]}),(0,n.jsxs)(a.default,{className:"header_menuLink",href:"/kontakt",children:[(0,n.jsx)(r.default,{src:o,alt:"Kontakt",unoptimized:!0}),(0,n.jsx)("span",{children:"Kontakt"})]}),(0,n.jsxs)("button",{className:"header_menuLink",onClick:()=>v(!0),children:[(0,n.jsx)(r.default,{src:m,alt:"Koszyk",unoptimized:!0}),z>0&&(0,n.jsx)("div",{className:"cartCounter",children:z}),(0,n.jsxs)("span",{children:["Koszyk"," ",(0,n.jsxs)("small",{style:{fontVariantNumeric:"tabular-nums"},children:["(",E.toFixed(2)," zł)"]})]})]}),w?(0,n.jsxs)("div",{className:"header_menuLink account-loading",children:[(0,n.jsx)(r.default,{src:d,alt:"Ładowanie",unoptimized:!0}),(0,n.jsx)("span",{children:"Ładowanie..."})]}):_?(0,n.jsxs)(a.default,{className:"header_menuLink account account-logged",href:"/konto",children:[(0,n.jsx)(r.default,{src:d,alt:"Moje konto",unoptimized:!0}),(0,n.jsx)("span",{children:"Moje konto"})]}):(0,n.jsxs)(a.default,{className:"header_myAccount wrapper",href:"/login",children:[(0,n.jsx)(r.default,{src:d,alt:"Konto",unoptimized:!0}),(0,n.jsxs)("div",{className:"myAccount_content",children:[(0,n.jsx)("span",{children:"Zaloguj się"}),(0,n.jsx)("small",{children:"Lub"}),(0,n.jsx)("span",{children:"Zał\xf3ż konto"})]})]}),(0,n.jsxs)("button",{className:"header_menuLink header_menuButton","aria-expanded":e,"aria-controls":"mobile-menu","aria-label":"Otw\xf3rz menu",onClick:()=>t(!0),children:[(0,n.jsx)(r.default,{src:u,alt:"Menu",unoptimized:!0}),(0,n.jsx)("span",{children:"Menu"})]})]})]}),(0,n.jsx)(f,{open:e,onClose:()=>t(!1)}),(0,n.jsx)(N,{open:i,onClose:()=>v(!1)}),(0,n.jsx)("div",{style:{display:"none"},"data-categories-state":x?"open":"closed"})]})}},11825:(e,t,i)=>{"use strict";i.d(t,{A:()=>p});var n=i(95155),a=i(84915),s=i(5565),r=i(1572),l=i(12115),o=i(67396),c=i(19508),d=i(63242),u=i(19797),m=i(93961);let h="recent-searches-v1";function p(){let{mobileMode:e,placeholder:t="Szukaj po nazwie, indeksie, producencie, kodzie EAN...",onClose:i}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},[p,x]=(0,l.useState)(""),[k,b]=(0,l.useState)(!1),[j,f]=(0,l.useState)(!1),[g,y]=(0,l.useState)([]),[_,w]=(0,l.useState)(null),{dispatch:N}=(0,a._)(),z=(0,l.useRef)(null),C=(0,l.useRef)(null),[S,E]=(0,l.useState)([]),[T,P]=(0,l.useState)(null),[L,M]=(0,l.useState)({}),[I,A]=(0,l.useState)(!1),[q,W]=(0,l.useState)(null),O=g.map(e=>e.productId).filter(e=>void 0!==e),{stockData:D}=(0,u.r)(O),Q=g.map(e=>
1{if(e.productId){if(D[e.productId]){let t=D[e.productId];return{...e,stockQuantity:t.available_stock,stockStatus:t.stock_status.toUpperCase(),isLoadingStock:!1}}return{...e,stockQuantity:void 0,isLoadingStock:!0}}return{...e,isLoadingStock:!1}});function U(e){let t=e.trim();if(!t)return;let i=[t,...S.filter(e=>e.toLowerCase()!==t.toLowerCase())].slice(0,8);E(i);try{localStorage.setItem(h,JSON.stringify(i))}catch(e){}}(0,l.useEffect)(()=>{try{let e=localStorage.getItem(h);e&&E(JSON.parse(e))}catch(e){}},[]),(0,l.useEffect)(()=>{if(!k){y([]),w(null);return}},[k]),(0,l.useEffect)(()=>{function e(e){C.current&&!C.current.contains(e.target)&&b(!1)}return k?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[k]),(0,l.useEffect)(()=>{let e=new AbortController,t=p.trim();if(!k)return;if(t.length<3){y([]),f(!1),w(null);return}f(!0),w(null);let i=setTimeout(async()=>{try{var i;let n=await fetch("/api/live-search?q=".concat(encodeURIComponent(t),"&limit=12"),{signal:e.signal,cache:"no-store"}),a=await n.json();if(null===(i=a.items)||void 0===i||i.length,!n.ok)throw Error((null==a?void 0:a.error)||"SEARCH_FAILED");y(a.items||[])}catch(e){(null==e?void 0:e.name)!=="AbortError"&&(console.error("[LiveSearch] Error:",e),w((null==e?void 0:e.message)||"Błąd wyszukiwania"))}finally{f(!1)}},300);return()=>{clearTimeout(i),e.abort()}},[p,k]);let F=e=>{0===e.stockQuantity?(P(e.id),setTimeout(()=>P(null),2e3)):function(e){var t,n,a;let s="number"==typeof e.stockQuantity?e.stockQuantity:void 0,r=L[e.id]||1,l=void 0!==s?Math.min(r,s):r;if(0!==s){if((0,d.Xb)(e.name)){W(e),A(!0);return}N({type:"add",item:{id:e.id,productId:e.productId,name:e.name,price:e.price||0,qty:l,image:e.thumb||void 0,stock:s,shippingType:e.shippingType,shippingUnitType:e.shippingUnitType,inpostAvailable:null===(t=e.attributes)||void 0===t?void 0:t["Dostępne w paczkomacie"],deliveryTime:e.shippingType||(null===(n=e.attributes)||void 0===n?void 0:n["Czas dostawy"])||(null===(a=e.attributes)||void 0===a?void 0:a["Czas wysyłki"]),weightPerUnit:e.weight,isDrumProduct:e.isDrumProduct,customShippingPrice:e.customShippingPrice}}),b(!1),null==i||i(),window.dispatchEvent(new CustomEvent("cart:open"))}}(e)},B=e=>L[e]||1,R=(e,t,i)=>{let n=Math.max(1,B(e)+t),a=void 0!==i?Math.min(n,i):n;M(t=>({...t,[e]:a}))};return(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)("div",{className:"liveSearch",ref:C,children:[(0,n.jsxs)("form",{className:"liveSearch__form",onSubmit:function(e){e.preventDefault(),p.trim()&&(U(p),window.location.href="/search?query=".concat(encodeURIComponent(p)))},role:"search",children:[(0,n.jsx)("input",{ref:z,value:p,onChange:e=>{x(e.target.value),b(!0)},placeholder:t,onFocus:()=>b(!0)}),p&&(0,n.jsx)("button",{type:"button",className:"liveSearch__clear",onClick:function(){var e;x(""),y([]),null===(e=z.current)||void 0===e||e.focus()},"aria-label":"Wyczyść",children:"\xd7"}),(0,n.jsx)("button",{"aria-label":"Szukaj",type:"submit",children:(0,n.jsx)(s.default,{src:r.A,alt:"Szukaj",width:20,height:20,unoptimized:!0})})]}),k&&(0,n.jsxs)("div",{className:"liveSearch__panel",children:[j&&(0,n.jsx)("div",{className:"liveSearch__loading",children:"Szukam..."}),_&&(0,n.jsx)("div",{className:"liveSearch__error",children:_}),!j&&!_&&(0,n.jsxs)("div",{className:"liveSearch__content",children:[!p.trim()&&(0,n.jsxs)("div",{className:"liveSearch__section",children:[(0,n.jsx)("div",{className:"liveSearch__sectionTitle",children:"Najczęściej kupowane:"}),(0,n.jsx)("ul",{className:"liveSearch__list",children:Q.map(e=>{var t,a,r,l;return(0,n.jsxs)("li",{className:"liveSearch__row liveSearch__row--anim",children:[(0,n.jsxs)(o.default,{className:"liveSearch__prod",href:"/product/".concat(e.slug),onClick:()=>{b(!1),null==i||i()},children:[(0,n.jsx)("div",{className:"liveSearch__thumb","aria-hidden":!e.thumb,children:e.thumb?(0,n.jsx)("img",{src:"string"==typeof e.thumb?e.thumb:"/trusted/electric-placeholder.jpg",alt:e.name,loading:"lazy"}):(0,n.jsx)("div",{className:"liveSearch__thumbFallback",title:"Brak zdjęcia"})}),(0,n.jsxs)("div",{className:"liveSearch__info",children:[(0,n.jsx)("div",{className:"liveSearch__name",children:e.name}),(0,n.jsxs)("div",{className:"liveSearch__meta",children:[e.isLoadingStock?(0,n.jsx)("span",{className:"tag",children:"Ładowanie..."}):"number"==typeof e.stockQuantity&&e.stockQuantity>0?(0,n.jsxs)("span",{className:"tag tag--green",children:["Czas dostawy: ",e.shippingType||(null===(t=e.attributes)||void 0===t?void 0:t["Czas dostawy"])||(null===(a=e.attributes)||void 0===a?void 0:a["Czas wysyłki"])||"24h"]}):(0,n.jsx)("span",{className:"tag",children:"Na zam\xf3wienie"}),e.isLoadingStock?(0,n.jsx)("span",{className:"muted skeleton-loading",children:"—"}):"number"==typeof e.stockQuantity?(0,n.jsxs)("span",{className:"muted",children:[e.stockQuantity," szt."]}):null,(null===(l=e.attributes)||void 0===l?void 0:null===(r=l["Dostępne w pacz
1komacie"])||void 0===r?void 0:r.toLowerCase())==="tak"&&e.shippingType&&/24\s*h?/i.test(e.shippingType)&&(0,n.jsx)(s.default,{src:"/payments/inpost-logo.svg",alt:"InPost",width:16,height:16,style:{marginLeft:"4px"}}),(0,d.jf)(e.name)&&(0,n.jsx)("span",{title:"Brak możliwości zwrotu produktu",style:{marginLeft:"4px",display:"inline-flex",alignItems:"center"},children:(0,n.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,n.jsx)("circle",{cx:"12",cy:"12",r:"10",stroke:"#e74c3c",strokeWidth:"2"}),(0,n.jsx)("path",{d:"M15 9L9 15M9 9L15 15",stroke:"#e74c3c",strokeWidth:"2",strokeLinecap:"round"})]})})]})]})]}),(0,n.jsxs)("div",{className:"liveSearch__priceRow",children:[(0,n.jsx)("div",{className:"liveSearch__price",children:v(e.price)}),(0,n.jsxs)("div",{className:"liveSearch__actions",children:[(0,n.jsxs)("div",{className:"liveSearch__qty",children:[(0,n.jsx)("button",{type:"button",onClick:()=>R(e.id,-1,e.stockQuantity),disabled:1>=B(e.id),children:"-"}),(0,n.jsx)("span",{children:B(e.id)}),(0,n.jsx)("button",{type:"button",onClick:()=>R(e.id,1,e.stockQuantity),disabled:void 0!==e.stockQuantity&&B(e.id)>=e.stockQuantity,children:"+"})]}),(0,n.jsx)(c.A,{content:0===e.stockQuantity?"Produkt niedostępny w magazynie":"",show:T===e.id,alwaysRenderWrapper:!0,children:(0,n.jsx)("button",{className:"liveSearch__add",onClick:()=>F(e),"aria-label":(0,d.Xb)(e.name)?"Przejdź do produktu":"Dodaj do koszyka",disabled:0===e.stockQuantity,style:0===e.stockQuantity?{opacity:.5,cursor:"not-allowed"}:{},children:(0,d.Xb)(e.name)?"→":"+"})})]})]})]},e.id)})})]}),p.trim()&&(0,n.jsxs)("div",{className:"liveSearch__section",children:[(0,n.jsx)("div",{className:"liveSearch__sectionTitle",children:"Wyniki:"}),(0,n.jsx)("ul",{className:"liveSearch__list",children:Q.length?Q.map(e=>{var t,a,r,l;return(0,n.jsxs)("li",{className:"liveSearch__row liveSearch__row--anim",children:[(0,n.jsxs)(o.default,{className:"liveSearch__prod",href:"/product/".concat(e.slug),onClick:()=>{U(p),b(!1),null==i||i()},children:[(0,n.jsx)("div",{className:"liveSearch__thumb","aria-hidden":!e.thumb,children:e.thumb?(0,n.jsx)("img",{src:"string"==typeof e.thumb?e.thumb:"/trusted/electric-placeholder.jpg",alt:e.name,loading:"lazy"}):(0,n.jsx)("div",{className:"liveSearch__thumbFallback",title:"Brak zdjęcia"})}),(0,n.jsxs)("div",{className:"liveSearch__info",children:[(0,n.jsx)("div",{className:"liveSearch__name",children:e.name}),(0,n.jsxs)("div",{className:"liveSearch__meta",children:[e.isLoadingStock?(0,n.jsx)("span",{className:"tag",children:"Ładowanie..."}):"number"==typeof e.stockQuantity&&e.stockQuantity>0?(0,n.jsxs)("span",{className:"tag tag--green",children:["Czas dostawy: ",e.shippingType||(null===(t=e.attributes)||void 0===t?void 0:t["Czas dostawy"])||(null===(a=e.attributes)||void 0===a?void 0:a["Czas wysyłki"])||"24h"]}):(0,n.jsx)("span",{className:"tag",children:"Na zam\xf3wienie"}),e.isLoadingStock?(0,n.jsx)("span",{className:"muted skeleton-loading",children:"—"}):"number"==typeof e.stockQuantity?(0,n.jsxs)("span",{className:"muted",children:[e.stockQuantity," szt."]}):null,(null===(l=e.attributes)||void 0===l?void 0:null===(r=l["Dostępne w paczkomacie"])||void 0===r?void 0:r.toLowerCase())==="tak"&&e.shippingType&&/24\s*h?/i.test(e.shippingType)&&(0,n.jsx)(s.default,{src:"/payments/inpost-logo.svg",alt:"InPost",width:16,height:16,style:{marginLeft:"4px"}}),(0,d.jf)(e.name)&&(0,n.jsx)("span",{title:"Brak możliwości zwrotu produktu",style:{marginLeft:"4px",display:"inline-flex",alignItems:"center"},children:(0,n.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,n.jsx)("circle",{cx:"12",cy:"12",r:"10",stroke:"#e74c3c",strokeWidth:"2"}),(0,n.jsx)("path",{d:"M15 9L9 15M9 9L15 15",stroke:"#e74c3c",strokeWidth:"2",strokeLinecap:"round"})]})})]})]})]}),(0,n.jsxs)("div",{className:"liveSearch__priceRow",children:[(0,n.jsx)("div",{className:"liveSearch__price",children:v(e.price)}),(0,n.jsxs)("div",{className:"liveSearch__actions",children:[(0,n.jsxs)("div",{className:"liveSearch__qty",children:[(0,n.jsx)("button",{type:"button",onClick:()=>R(e.id,-1,e.stockQuantity),disabled:1>=B(e.id),children:"-"}),(0,n.jsx)("span",{children:B(e.id)}),(0,n.jsx)("button",{type:"button",onClick:()=>R(e.id,1,e.stockQuantity),disabled:void 0!==e.stockQuantity&&B(e.id)>=e.stockQuantity,children:"+"})]}),(0,n.jsx)(c.A,{content:0===e.stockQuantity?"Produkt niedostępny w magazynie":"",show:T===e.id,alwaysRenderWrapper:!0,children:(0,n.jsx)("button",{className:"liveSearch__add",onClick:()=>F(e),"aria-label":(0,d.Xb)(e.name)?"Przejdź do produktu":"Dodaj do koszyka",disabled:0===e.stockQuantity,style:0===e.stockQuantity?{opacity:.5,cursor:"not-allowed"}:{},children:(0,d.Xb)(e.name)?"→":"+"})})]})]})]},e.id)}):(0,n.jsxs)("div",{className:"liveSearch__empty",children:["Brak wynik\xf3w dla „",p,'".']})})]}),(0,n.jsxs)("div",{className:"liveSearch__recent",children:[(0,n.jsxs)("div",{className:"liveSearch__recentHeader",children:[(0,n.jsx)("span",{children:"Ostatnio szukane:"}),S.length>0&&(0,n.jsx)("button",{type:"button",onClick:function(){E([]);try{localStorage.removeItem(h)}catch(e){}},className:"link",children:"Usuń wszystkie"})]}),(0,n.jsx)("div",{className:"liveSearch__chips",children:S.map(e=>(0,n.jsx)("button",{onClick:()=>{x(e),b(!0)},className:"chip",children:e},e))}),p.trim()&&(0,n.jsx)("div",{className:"liveSearch__all",children:(0,n.jsx)(o.default,{href:"/search?query=".concat(encodeURIComponent(p)),onClick:()=>{b(!1),null==i||i()},className:"link",children:"Zobacz wszystkie"})})]})]})]}),(0,n.jsx)(m.A,{isOpen:I,onClose:()=>{A(!1),W(null)},onConfirm:e=>{var t,n,a,s;if(!q)return;let r="number"==typeof q.stockQuantity?q.stockQuantity:void 0,l=void 0!==r?Math.min(e,r):e;N({type:"add",item:{id:(null===(t=window.crypto)||void 0===t?void 0:t.randomUUID)?"".concat(q.id,"_").concat(window.crypto.randomUUID()):"".concat(q.id,"_").concat(Math.random().toString(36).substring(2,15)),productId:q.productId,name:q.name,price:q.price||0,qty:l,image:q.thumb||void 0,stock:r,shippingType:q.shippingType,shippingUnitType:q.shippingUnitType,inpostAvailable:null===(n=q.attributes)||void 0===n?void 0:n["Dostępne w pacz
1komacie"],deliveryTime:q.shippingType||(null===(a=q.attributes)||void 0===a?void 0:a["Czas dostawy"])||(null===(s=q.attributes)||void 0===s?void 0:s["Czas wysyłki"]),weightPerUnit:q.weight,isDrumProduct:q.isDrumProduct,customShippingPrice:q.customShippingPrice,cableCutting:{enabled:!0,quantity:1,price:30.75}}}),A(!1),W(null),b(!1),null==i||i(),window.dispatchEvent(new CustomEvent("cart:open"))},productName:(null==q?void 0:q.name)||"",productPrice:(null==q?void 0:q.price)||0,initialMeters:q&&L[q.id]||1})]})})}function v(e){try{return new Intl.NumberFormat("pl-PL",{style:"currency",currency:"PLN"}).format(e)}catch(t){return"".concat(e.toFixed(2)," zł")}}},1205:(e,t,i)=>{"use strict";i.d(t,{SessionProvider:()=>s});var n=i(95155),a=i(2615);function s(e){let{children:t}=e;return(0,n.jsx)(a.SessionProvider,{children:t})}},62312:()=>{},2250:()=>{},56676:()=>{},95127:()=>{},57417:()=>{},45873:()=>{},61039:(e,t,i)=>{"use strict";i.d(t,{A:()=>n});let n={src:"/_next/static/media/color-logo.eb9dfbba.svg",height:38,width:223,blurWidth:0,blurHeight:0}},1572:(e,t,i)=>{"use strict";i.d(t,{A:()=>n});let n={src:"/_next/static/media/search-icon.a415d5d9.svg",height:27,width:27,blurWidth:0,blurHeight:0}}},e=>{var t=t=>e(e.s=t);e.O(0,[7128,7144,8826,2229,8961,7122,918,1443,220,1123,5215,2742,313,9721,3135,2548,8703,1261,3879,9901,3628,7538,5477,3308,4062,5201,7432,9381,7924,5971,5450,2076,7358],()=>t(2121)),_N_E=e.O()}]);

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.