PageSourceSearch

https://www.liebherr.com/_next/static/chunks/4186.4d3726e622d1ca1b.js

js liebherr.com collected 2026-09-24 08:40:27 UTC 11,522 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4186],{74186:(e,l,a)=>{a.r(l),a.d(l,{default:()=>A});var n=a(37876),o=a(59939);let s={diesel:{metric:3.1168,imperial:3.1168*3.78541},hvo:{metric:.38095,imperial:.38095*3.78541}};var i=a(99653),t=a(9362),r=a(42353),c=a(48840),u=a(90634),d=a(1803),m=a(24743),v=a(54527),p=a(75423),h=a(46582),x=a(92503),g=a(98690),b=a(77422),f=a(42621);class j{parse(e){if(!e)return null;let l=Number(e.replace(RegExp("[".concat(this.groupSymbol,"]"),"g"),"").replace(this.decimalSymbol,".").replace(/[−-]\s?/,"-").replace(this.numeralRegex,e=>this.numerals.indexOf(e).toString()));return isNaN(l)?null:l}constructor(e){var l,a,n,o;this.locale=e;let s=Intl.NumberFormat(e).formatToParts(1111.11);this.groupSymbol=null!==(n=null==s?void 0:null===(l=s.find(e=>(null==e?void 0:e.type)==="group"))||void 0===l?void 0:l.value)&&void 0!==n?n:"",this.decimalSymbol=null!==(o=null==s?void 0:null===(a=s.find(e=>(null==e?void 0:e.type)==="decimal"))||void 0===a?void 0:a.value)&&void 0!==o?o:"",this.numerals=new Intl.NumberFormat(e,{useGrouping:!1}).format(0x24cb016ea).split("").reverse().join(""),this.numeralRegex=RegExp("[".concat(this.numerals,"]"),"g")}}let N=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"de-DE",a=e.replace(/([a-zA-Z]|£|\$|€|¥|zł|₽|\s|:)+/g,"").trim();return new j(l).parse(a)},C=(e,l,a)=>{var n,o,s;let{id:i,unitDisplayName:t,value:r}=null!==(s=null==e?void 0:null===(o=e.filter(e=>(null==e?void 0:e.metricFilterRelevance)===l).at(0))||void 0===o?void 0:null===(n=o.values)||void 0===n?void 0:n.find(e=>e.id===a))&&void 0!==s?s:{};return{id:i,unitDisplayName:t,value:parseFloat(null!=r?r:"0")}};var _=a(14232);let w=e=>{let{onSubmit:l}=e,{locale:a}=(0,t.H)(),o=(0,_.useRef)(null),s=(0,_.useRef)(null),i=(0,_.useRef)(null),r=(0,f.h)(),c=new Map;c.set("consumptionPerHour",o),c.set("hoursOfOperation",s),c.set("fuelPrice",i);let[u,d]=(0,_.useState)({consumptionPerHour:null,hoursOfOperation:null,fuelPrice:null}),m=(0,_.useMemo)(()=>Object.values(u).every(e=>null!==e),[u]),v=(0,_.useCallback)(()=>{m&&l(u)},[u,m,l]),p=e=>{var l,n;let o=e.target,s=o.name,i=r.formLabelsMap.get(s),t=null!==(l=o.value)&&void 0!==l?l:"",c=N(String(t),a);null!=c?("lhBlur"===e.type&&(o.value=c?Intl.NumberFormat(a).format(c):t),o.status="default",d(e=>({...e,[s]:c}))):t.toString().length>0?(o.errorText=null!==(n=null==i?void 0:i.error)&&void 0!==n?n:"error_"+o.name,o.status="error",d(e=>({...e,[s]:null}))):(d(e=>({...e,[s]:null})),o.status="default")};return(0,n.jsxs)("div",{className:"flex flex-col",children:[(0,n.jsx)("div",{className:"mb-2 flex flex-col md:mb-6 md:grid md:grid-cols-3 md:gap-x-8",children:[...c.entries()].map(e=>{let[l,a]=e,o=r.formLabelsMap.get(l);return l&&o&&a&&(0,n.jsx)("div",{className:"mb-4 md:contents",children:(0,n.jsx)(g.ts,{type:"text",placeholder:o.placeholder,label:o.label,onLhChange:p,onLhBlur:p,name:l,ref:a})},l)})}),(0,n.jsx)(g.eC,{onClick:v,...!m&&{disabled:!0},className:"mb-4 block md:mb-0 md:self-end",focusBorderInside:!0,children:r.commonLabels.calculate})]})};var y=a(4856);let S=e=>{var l,a,o,s,i,t,r,c;let{lidat:u,isPdpE:j,onSubmit:N}=e,C=(0,f.h)(),{productPresentation:S}=(0,h.j)(),[L,k]=(0,_.useState)(!1),{wrapClose:E}=(0,x.$)(L),F=E((0,_.useCallback)(()=>{k(!1)},[])),D=(0,_.useCallback)(()=>{k(!0)},[]),A=(0,_.useCallback)(e=>{("Enter"===e.key||" "===e.key)&&(e.preventDefault(),k(!0))},[]);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("p",{className:(0,y.x)("mb-4 font-head",j?"text-h2":"text-h4"),children:C.viewLabels.calculator.escModuleHeadline}),(0,n.jsx)("p",{className:"mb-2",children:C.viewLabels.calculator.escModuleInfo}),(0,n.jsx)("div",{className:"mb-4 flex flex-row items-center gap-x-2",children:(0,n.jsx)(v.A,{onClick:D,onKeyDown:A,children:(0,n.jsx)(g.Ud,{label:C.viewLabels.calculator.escInfoIconLabel,noAnchorCase:!0,tabIndex:-1,children:(0,n.jsx)(p.A,{useIconSlot:!0,name:"info-circle"})})})}),(0,n.jsx)("div",{className:"mb-4 border-b border-t border-steel-400 py-2",children:(0,n.jsxs)("dl",{className:"flex flex-col gap-x-4 gap-y-0 md:grid md:grid-cols-[min-content_auto]",children:[(0,n.jsx)("dt",{className:"font-text-bold md:whitespace-nowrap",children:C.viewLabels.calculator.escAvgEnergyConsumptionPerHour}),(0,n.jsx)("dd",{className:"mb-2 md:mb-0",children:u.consumption}),(0,n.jsx)("dt",{className:"font-text-bold md:whitespace-nowrap",children:C.viewLabels.calculator.escHoursOfOperation}),(0,n.jsx)("dd",{className:"",children:u.hours_of_operation})]})}),(0,n.jsx)(w,{onSubmit:N})]}),(0,n.jsx)(b.A,{closeCallback:F,open:L,alignTop:!0,children:(0,n.jsxs)("div",{className:"px-5 pb-8 pt-5 xl:p-8",children:[(null==S?void 0:null===(a=S.productEnergySavingCalculator)||void 0===a?void 0:null===(l=a.infoModal)||void 0===l?void 0:l.headline)&&(0,n.jsx)(m.A,{text:null==S?void 0:null===(s=S.productEnergySavingCalculator)||void 0===s?void 0:null===(o=s.infoModal)||void 0===o?void 0:o.headline,className:"mb-4"}),(null==S?void 0:null===(t=S.productEnergySavingCalculator)||void 0===t?void 0:null===(i=t.infoModal)||void 0===i?void 0:i.text)&&(0,n.jsx)(d.A,{html:null==S?void 0:null===(c=S.productEnergySavingCalculator)||void 0===c?void 0:null===(r=c.infoModal)||void 0===r?void 0:r.text})]})})]})};var L=a(75738);let k=e=>{var l;let{onReset:a,values:o}=e,{locale:s}=(0,t.H)(),i=(0,f.h)(),{isMobileScreen:r}=(0,u.G)(),{productPresentation:c}=(0,h.j)();return(0,n.jsxs)("div",{className:"grid grid-cols-[min-content_1fr] items-center gap-y-0 md:flex-nowrap md:items-start md:gap-x-3 xl:gap-x-6",children:[(0,n.jsx)("div",{className:"col-start-1 mb-4 mr-4 rounded-full bg-white p-1 md:float-none md:mr-0 md:p-4",children:(0,n.jsx)(p.A,{name:"innovations",size:r?24:40})}),(0,n.jsxs)("div",{className:"contents md:flex md:w-full md:flex-col",children:[(0,n.jsx)("p",{className:"col-start-2 mb-4 w-full flex-shrink-0 flex-grow font-head text-h4",children:i.viewLabels.compare.escCompareHeadline}),(0,n.jsx)("p",{className:"col-span-2 col-start-1 mb-4",children:i.viewLabels.compare.escCompareSubline}),(0,n.jsxs)("div",{className:"col-span-2 col-start-1 mb-4 border-b border-t border-steel-400 py-2",children:[(0,n.jsxs)("p",{className:"mb-2",children:[(0,n.jsxs)("span",{className:"mr-3 block font-head text-h5 md:inline-block",children:[(0,L.ZV)(o.costSaving,s,{maximumFractionDigits:2,minimumFractionDigits:2}
1)," ",i.commonLabels.escCurrency]}),(0,n.jsx)("span",{children:i.viewLabels.compare.escFuelSavingPerYear})]}),(0,n.jsxs)("p",{className:"mb-2",children:[(0,n.jsxs)("span",{className:"mr-3 block font-head text-h5 md:inline-block",children:[(0,L.ZV)(o.co2diesel,s,{maximumFractionDigits:2,minimumFractionDigits:2})," ",i.commonLabels.escCo2Equivalent]}),(0,n.jsx)("span",{children:i.viewLabels.compare.escDieselReductionPerYear})]}),(0,n.jsxs)("p",{className:"mb-2",children:[(0,n.jsxs)("span",{className:"mr-3 block font-head text-h5 md:inline-block",children:[(0,L.ZV)(o.co2hvo,s,{maximumFractionDigits:2,minimumFractionDigits:2})," ",i.commonLabels.escCo2Equivalent]}),(0,n.jsx)("span",{children:i.viewLabels.compare.escHvoReductionPerYear})]})]}),(null==c?void 0:null===(l=c.productEnergySavingCalculator)||void 0===l?void 0:l.resultViewSavings)&&(0,n.jsx)("div",{className:"col-span-2 col-start-1 mb-6",children:(0,n.jsx)(d.A,{html:c.productEnergySavingCalculator.resultViewSavings})}),(0,n.jsx)(g.eC,{onClick:a,type:"secondary",className:"col-span-2 col-start-1 mb-4 block self-end md:mb-0",focusBorderInside:!0,children:i.commonLabels.recalculate})]})]})},E=e=>{var l;let{onReset:a}=e,o=(0,f.h)(),{isMobileScreen:s}=(0,u.G)(),{productPresentation:i}=(0,h.j)();return(0,n.jsxs)("div",{className:"grid grid-cols-[min-content_1fr] items-center md:flex-nowrap md:items-start md:gap-x-3 xl:gap-x-6",children:[(0,n.jsx)("div",{className:"col-start-1 mb-4 mr-4 rounded-full bg-white p-1 md:float-none md:mr-0 md:p-4",children:(0,n.jsx)(p.A,{name:"innovations",size:s?24:40})}),(0,n.jsxs)("div",{className:"contents md:flex md:w-full md:flex-col",children:[(0,n.jsx)("p",{className:"col-start-2 mb-4 w-full flex-shrink-0 flex-grow font-head text-h4",children:o.viewLabels.congrats.escCongratulationHeadline}),(0,n.jsx)("p",{className:"col-span-2 col-start-1 mb-2 font-head text-h6",children:o.viewLabels.congrats.escCongratulationSubline}),(null==i?void 0:null===(l=i.productEnergySavingCalculator)||void 0===l?void 0:l.resultViewNoSavings)&&(0,n.jsx)("div",{className:"col-span-2 col-start-1 mb-4",children:(0,n.jsx)(d.A,{html:i.productEnergySavingCalculator.resultViewNoSavings})}),(0,n.jsx)(g.eC,{className:"col-span-2 col-start-1 mb-4 block self-end md:mb-0",onClick:a,type:"secondary",focusBorderInside:!0,children:o.commonLabels.recalculate})]})]})};var F=a(6644),D=a(4243);let A=e=>{var l,a,d,m,v;let{isPdpE:p}=e,{isMobileScreen:h}=(0,u.G)(),{url:x,locale:g}=(0,t.H)(),{trackEvent:b}=(0,D.z)(),{fuelConsumptions:j,id:N}=(0,r.G)(),w=(0,_.useRef)(null),A=(0,f.h)(),O=C(j,"metric","fuel_consumption_per_operating_hour_average"),R=C(j,"imperial","fuel_consumption_per_operating_hour_average"),I={averageConsumptionFull:{metric:(0,L.ZV)(null==O?void 0:O.value,g,{minimumFractionDigits:2,maximumFractionDigits:2}).concat(" ",null!==(d=null==O?void 0:O.unitDisplayName)&&void 0!==d?d:""),imperial:(0,L.ZV)(null==R?void 0:R.value,g,{minimumFractionDigits:2,maximumFractionDigits:2}).concat(" ",null!==(m=null==R?void 0:R.unitDisplayName)&&void 0!==m?m:"")},averageConsumption:{metric:null==O?void 0:O.value,imperial:null==R?void 0:R.value},operating_hours_total:(0,L.ZV)(null===(l=C(j,"metric","operating_hours_total"))||void 0===l?void 0:l.value,g,{minimumFractionDigits:2,maximumFractionDigits:2}).toString().concat(" ",null!==(v=null===(a=C(j,"metric","operating_hours_total"))||void 0===a?void 0:a.unitDisplayName)&&void 0!==v?v:"")},P=(0,_.useRef)(null),H=(0,_.useRef)({costSaving:0,co2diesel:0,co2hvo:0}),[M,V]=(0,_.useState)("calculate"),Z=(0,c.d)(e=>e.unit),z=()=>{b(i.b.LINK_CLICK,(0,F.Uy)({href:x,uid:N,title:A.commonLabels.recalculate,layout:"button",size:"big"})),V("calculate")};return(0,_.useEffect)(()=>{let e=new CustomEvent("lhContentChanged",{bubbles:!0});setTimeout(()=>{var l;null==w||null===(l=w.current)||void 0===l||l.dispatchEvent(e)},100)},[M]),(0,n.jsx)("section",{className:(0,y.x)(p&&"content-container-padding"),...p&&!h&&{id:"energysavingcalculator"},ref:w,children:(0,n.jsxs)("div",{className:"relative flex flex-col bg-steel-100 p-4 md:p-6",children:["calculate"===M&&(0,n.jsx)(S,{lidat:{consumption:I.averageConsumptionFull[Z],hours_of_operation:I.operating_hours_total},isPdpE:p,onSubmit:e=>{b(i.b.CTA_CLICK,(0,F.sp)({href:x,uid:N,title:A.commonLabels.calculate,esc_data:{metric_filter:Z,pim_consumption:I.averageConsumptionFull[Z],pim_operation_hours:I.operating_hours_total,user_consumption:e.consumptionPerHour,user_operation_hours:e.hoursOfOperation,user_energy_price:e.fuelPrice}},F.tZ.ESC_CALCULATE)),P.current=e;let l=e.consumptionPerHour-I.averageConsumption[Z];H.current.costSaving=l*e.hoursOfOperation*e.fuelPrice,H.current.co2diesel=l*e.hoursOfOperation*s.diesel[Z],H.current.co2hvo=l*e.hoursOfOperation*s.hvo[Z],V(l<=0?"congrats":"compare")}}),"congrats"===M&&(0,n.jsx)(E,{onReset:z}),"compare"===M&&(0,n.jsx)(k,{values:H.current,onReset:z}),(0,n.jsx)("div",{className:"self-center md:absolute md:bottom-9 md:self-start",children:(0,n.jsx)(o.A,{valueCurrent:"calculate"===M?"01":"02",valueMax:"02"})})]})})}}}]);

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.