PageSourceSearch

https://statics.otomoto.pl/optimus-storage/s/v2/_next/static/chunks/62979-f3fa9990286da922.js

js otomoto.pl collected 2026-10-02 03:54:46 UTC 64,773 bytes, 1 lines download raw bytes

1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},a=(new e.Error).stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="6f48f3c0-35dc-433e-aff5-74f946ef6e5f",e._sentryDebugIdIdentifier="sentry-dbid-6f48f3c0-35dc-433e-aff5-74f946ef6e5f")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[62979],{106740:(e,a,l)=>{l.d(a,{T:()=>r});var r=e=>{var a=e.legacyAppliedFilters,l=e.appliedFilters,r=(null!=a?a:[]).filter(e=>null!=e.value&&""!==e.value);return r.length>0?r.map(e=>({name:e.name,value:e.value})):(null!=l?l:[]).flatMap(e=>{var a;return(null==(a=e.values)?void 0:a.length)?e.values.map(a=>({name:e.key,value:a})):null!=e.value&&""!==e.value?[{name:e.key,value:e.value}]:[]})}},293831:(e,a,l)=>{l.d(a,{C:()=>n,N:()=>t});var r=l(300561),t=e=>e.map(e=>{var a=e.name,l=e.value,t=e.canonical;return(0,r._)({name:a,value:l},t?{canonical:t}:{})}),n=e=>e.map(e=>({key:e.name,operator:"=",value:e.value}))},469389:(e,a,l)=>{l.d(a,{WX:()=>t,wL:()=>r});var r="rankingRelevance",t=16},477149:(e,a,l)=>{l.d(a,{Vz:()=>e0,M4:()=>eH,CQ:()=>eZ});var r=l(271864),t=l(119218),n=l(12013),i=l(138209),o=l(469389),d=l(300561),s=l(819470),c=l(160129),u=l(599202),m=l(498635),p=l(135259),h=l(289621),v=l(60794),g=l(203317),f=l(687305),x=l(170412),b=l(311080),y=l(982523),w=l.n(y),_=l(558162),N=l(28337),A=l(707767),k=l(283241),Y=(0,N.default)(u.P3,{target:"e1ka7w9x0"})("display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;"),I=(0,N.default)(e=>{var a=e.address;return(0,r.FD)(Y,{className:"mb-xs",children:[(0,r.Y)(k.A,{mr:2,size:"icon-small"}),a]})},{target:"e1ka7w9x1"})(),S=(0,N.default)("div",{target:"e1owtbrj0"})("display:flex;flex-direction:column;"),F=(0,N.default)("div",{target:"e1owtbrj1"})("display:flex;flex-direction:row;justify-content:space-between;"),D=(0,N.default)(e=>{var a=e.items,l=(0,_._)(e,["items"]);return(0,r.Y)("section",{"aria-label":"Characteristics",children:(0,r.Y)("ul",(0,s._)((0,d._)({},l),{children:(void 0===a?[]:a).map(e=>{var a=e.name,l=e.value;return(0,r.Y)("li",{children:(0,r.Y)("span",{children:l})},a)})}))})},{target:"e7z7r4s0"})("display:flex;flex-wrap:wrap;margin-bottom:8px;> li{display:inline-block;position:relative;padding-right:",e=>e.theme.space.sm,';&:not(:last-of-type):after{display:block;position:absolute;content:"";width:2px;height:2px;background:',e=>e.theme.colors.$07_black,";border-radius:50%;top:50%;right:",e=>e.theme.space.xs,";transform:translateY(-50%);}> span{font-size:",e=>e.theme.fontSizes[14],";}}"),T=l(409119),M=l(920584),P=l(464399),R=l(733199),C=l.n(R);function z(){var e=(0,T._)(["\n    display: flex;\n    flex-direction: column;\n    justify-content: space-between;\n    margin-top: auto;\n    margin-bottom: ",";\n  "]);return z=function(){return e},e}function B(){var e=(0,T._)(["\n    flex: 1;\n    display: flex;\n    align-items: center;\n    justify-content: space-between;\n    border: "," ","\n      ",";\n    border-radius: ",";\n    height: ",";\n    padding: ",";\n    margin-top: ",";\n    margin-bottom: ",";\n  "]);return B=function(){return e},e}var E="business_site_click",L=(0,N.default)("div",{target:"e1q2y61i0"})(e=>{var a=e.theme;return(0,M.css)(z(),a.space[4])},";"),$=(0,N.default)("a",{target:"e1q2y61i1"})(e=>{var a=e.theme;return(0,M.css)(B(),a.borderWidths.small,a.borderStyles.solid,a.colors.$03_green_tint_light,a.radii[4],a.sizes[40],a.space[8],a.space[16],a.space[8])},";"),G=(0,N.default)("img",{target:"e1q2y61i2"})("height:24px;width:auto;"),O=(0,t.F)()?e=>{var a,l,t,i,o,d,s,m,h,v=(0,n.c)(23),g=e.dealerName,f=e.logo,x=e.url,b=(0,p.z1)().trackEvent,y=(0,P.Bd)("home").t;v[0]!==b?(a=e=>{e.stopPropagation(),b(E,"click",{touch_point_button:"mid_offer-logo",touch_point_page:"home"})},v[0]=b,v[1]=a):a=v[1];var w=a;v[2]!==b?(l=e=>{e.stopPropagation(),b(E,"click",{touch_point_button:"mid_offer-know_seller",touch_point_page:"home"})},v[2]=b,v[3]=l):l=v[3];var _=l;return v[4]!==g||v[5]!==f?(t=f?(0,r.Y)(G,{alt:"".concat(g," logo"),src:f}):(0,r.Y)(u.P4,{children:g}),v[4]=g,v[5]=f,v[6]=t):t=v[6],v[7]===Symbol.for("react.memo_cache_sentinel")?(i=(0,r.Y)(c.default,{size:24}),v[7]=i):i=v[7],v[8]!==w||v[9]!==t||v[10]!==x?(o=(0,r.FD)($,{href:x,onClick:w,children:[t,i]}),v[8]=w,v[9]=t,v[10]=x,v[11]=o):o=v[11],v[12]!==y?(d=y("listing-ad-card-seller-link"),v[12]=y,v[13]=d):d=v[13],v[14]!==_||v[15]!==d?(s=(0,r.Y)(u.$n,{variant:"tertiary",size:"small",onClick:_,"data-testid":"experiment-featured-ad-business-site-cta",children:d}),v[14]=_,v[15]=d,v[16]=s):s=v[16],v[17]!==s||v[18]!==x?(m=(0,r.Y)(C(),{href:x,children:s}),v[17]=s,v[18]=x,v[19]=m):m=v[19],v[20]!==o||v[21]!==m?(h=(0,r.FD)(L,{children:[o,m]}),v[20]=o,v[21]=m,v[22]=h):h=v[22],h}:e=>{var a=e.dealerName,l=e.logo,t=e.url,n=(0,p.z1)().trackEvent,i=(0,P.Bd)("home").t;return(0,r.FD)(L,{children:[(0,r.FD)($,{href:t,onClick:e=>{e.stopPropagation(),n(E,"click",{touch_point_button:"mid_offer-logo",touch_point_page:"home"})},children:[l?(0,r.Y)(G,{alt:"".concat(a," logo"),src:l}):(0,r.Y)(u.P4,{children:a}),(0,r.Y)(c.default,{size:24})]}),(0,r.Y)(C(),{href:t,children:(0,r.Y)(u.$n,{variant:"tertiary",size:"small",onClick:e=>{e.stopPropagation(),n(E,"click",{touch_point_button:"mid_offer-know_seller",touch_point_page:"home"})},"data-testid":"experiment-featured-ad-business-site-cta",children:i("listing-ad-card-seller-link")})})]})},j=(0,N.default)("img",{target:"e5nnhao0"})("width:100%;height:auto;border-top-left-radius:4px;border-top-right-radius:4px;object-fit:cover;flex:2 1;aspect-ratio:4/3;"),q=(0,N.default)(e=>
1{e.verticalyAligned;var a=(e.withBorder,(0,_._)(e,["verticalyAligned","withBorder"]));return(0,r.Y)("section",(0,d._)({"aria-label":"Information"},a))},{target:"e1cz1wkm0"})("display:flex;flex-direction:column;flex:1 2 auto;padding:8px;justify-content:",e=>e.verticalyAligned?"space-between":"flex-start",";",e=>{var a=e.withBorder,l=e.theme;return a&&"\n      border: 1px solid ".concat(l.colors["borders-global-tertiary"],";\n      border-top: none;\n      border-bottom-left-radius: ").concat(l.radii[4],";\n      border-bottom-right-radius: ").concat(l.radii[4],";\n  ")}),U=(0,N.default)("img",{target:"e1dnyidj0"})("width:30%;height:auto;margin-top:auto;"),V=(0,t.F)()?e=>{var a,l,t,i,o,c,m=(0,n.c)(12);return m[0]!==e?(t=(0,_._)(e,["number","currency"]),l=e.number,a=e.currency,m[0]=e,m[1]=a,m[2]=l,m[3]=t):(a=m[1],l=m[2],t=m[3]),m[4]!==l?(i=(0,r.Y)("span",{children:l}),m[4]=l,m[5]=i):i=m[5],m[6]!==a?(o=(0,r.Y)("sup",{className:"pl-50 text-[10px] leading-body-base",children:a}),m[6]=a,m[7]=o):o=m[7],m[8]!==t||m[9]!==i||m[10]!==o?(c=(0,r.Y)("section",{"aria-label":"Price",className:"flex",children:(0,r.FD)(u.H4,(0,s._)((0,d._)({variant:"bold",className:"text-foreground-status-error"},t),{children:[i,o]}))}),m[8]=t,m[9]=i,m[10]=o,m[11]=c):c=m[11],c}:e=>{var a=e.number,l=e.currency,t=(0,_._)(e,["number","currency"]);return(0,r.Y)("section",{"aria-label":"Price",className:"flex",children:(0,r.FD)(u.H4,(0,s._)((0,d._)({variant:"bold",className:"text-foreground-status-error"},t),{children:[(0,r.Y)("span",{children:a}),(0,r.Y)("sup",{className:"pl-50 text-[10px] leading-body-base",children:l})]}))})};function W(){var e=(0,T._)(["\n    padding-top: ",";\n    padding-left: ",";\n    font-size: ",";\n    line-height: ",";\n  "]);return W=function(){return e},e}function K(){var e=(0,T._)(["\n    font-size: ",";\n    line-height: ",";\n    font-weight: normal;\n  "]);return K=function(){return e},e}var H=(0,N.default)("sup",{target:"eea7qew0"})(e=>{var a=e.theme;return(0,M.css)(W(),a.space[6],a.space[4],a.sizes[10],a.sizes[20])}),Q=(0,N.default)("sup",{target:"eea7qew1"})(e=>{var a=e.theme;return(0,M.css)(K(),a.sizes[14],a.sizes[20])}),X=(0,N.default)("section",{target:"eea7qew2"})("color:",e=>e.theme.colors.$05_red_primary,";display:flex;"),J=(0,t.F)()?e=>{var a,l,t,i,o,d,s,c=(0,n.c)(16),m=e.priceValue,p=e.installmentValue,h=e.currency,v=(0,P.Bd)("listing").t;c[0]!==v?(a=v("c2b-month-price-label"),c[0]=v,c[1]=a):a=c[1];var g=a;c[2]!==v?(l=v("c2b-from-price-label"),c[2]=v,c[3]=l):l=c[3];var f=l;c[4]!==m?(t=(0,r.Y)("span",{children:m}),c[4]=m,c[5]=t):t=c[5],c[6]!==h?(i=(0,r.Y)(H,{children:h}),c[6]=h,c[7]=i):i=c[7],c[8]!==t||c[9]!==i?(o=(0,r.FD)(u.H4,{variant:"bold","data-testid":"ad-card-price-value",children:[t,i]}),c[8]=t,c[9]=i,c[10]=o):o=c[10];var x="".concat(f," ").concat(p," ").concat(h," / ").concat(g);return c[11]!==x?(d=(0,r.Y)(u.H4,{variant:"bold","data-testid":"ad-card-installment-price-value",children:(0,r.Y)(Q,{children:(0,r.Y)("span",{children:x})})}),c[11]=x,c[12]=d):d=c[12],c[13]!==o||c[14]!==d?(s=(0,r.FD)(X,{"aria-label":"PriceWithInstallment","data-testid":"ad-card-price-with-installment",children:[o,d]}),c[13]=o,c[14]=d,c[15]=s):s=c[15],s}:e=>{var a=e.priceValue,l=e.installmentValue,t=e.currency,n=(0,P.Bd)("listing").t,i=n("c2b-month-price-label"),o=n("c2b-from-price-label");return(0,r.FD)(X,{"aria-label":"PriceWithInstallment","data-testid":"ad-card-price-with-installment",children:[(0,r.FD)(u.H4,{variant:"bold","data-testid":"ad-card-price-value",children:[(0,r.Y)("span",{children:a}),(0,r.Y)(H,{children:t})]}),(0,r.Y)(u.H4,{variant:"bold","data-testid":"ad-card-installment-price-value",children:(0,r.Y)(Q,{children:(0,r.Y)("span",{children:"".concat(o," ").concat(l," ").concat(t," / ").concat(i)})})})]})},Z=(0,N.default)(e=>(0,r.Y)(u.H2,(0,d._)({},e)),{target:"ej63gnd0"})("line-height:34px;margin-bottom:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:16px;"),ee=e=>(0,A.Bu)(String(e)).replaceAll(".",","),ea=(0,N.default)("article",{target:"ex8v4z0"})("display:flex;flex-direction:column;color:",e=>e.theme.colors.$07_black,";background:",e=>e.theme.colors.$01_white,";border-radius:4px;"),el=(0,t.F)()?e=>{var a,l,t,i,o,c,u,m,p,h,v,g=(0,n.c)(45);g[0]!==e?(y=(0,_._)(e,["ad","className","logo"]),w=e.ad,N=e.className,A=e.logo,g[0]=e,g[1]=y,g[2]=w,g[3]=N,g[4]=A):(y=g[1],w=g[2],N=g[3],A=g[4]);var f=void 0===w?null:w,x=void 0===N?null:N,b=void 0===A?null:A;if(g[5]!==y?(y.withBorder,k=(0,_._)(y,["withBorder"]),g[5]=y,g[6]=k):k=g[6],!f){var y,w,N,A,k,Y,I=x||"";return g[7]!==k||g[8]!==I?(Y=(0,r.Y)(ea,(0,d._)({className:I},k)),g[7]=k,g[8]=I,g[9]=Y):Y=g[9],Y}var S=f.image,F=f.title,D=f.price,T=f.characteristics,M=f.businessSiteUrl,P=f.dealerLogos,R=f.dealerName,C=f.address;if(g[10]!==y){y.shouldShowDealerInfo;var z=y.withBorder,B=(0,_._)(y,["shouldShowDealerInfo","withBorder"]);l=z,a=B,g[10]=y,g[11]=a,g[12]=l}else a=g[11],l=g[12];var E=void 0!==l&&l,L=x||void 0;g[13]!==S||g[14]!==F?(t=(0,r.Y)(el.Image,{src:S,alt:F,loading:"lazy","data-testid":"ad-card-image"}),g[13]=S,g[14]=F,g[15]=t):t=g[15];var $=D&&!!D.installmentValue;return g[16]!==F?(i=(0,r.Y)(el.Info.Title,{"data-testid":"ad-card-title",children:F}),g[16]=F,g[17]=i):i=g[17],g[18]!==T?(o=(0,r.Y)(el.Info.Characteristics,{items:T,"data-testid":"ad-card-characteristics"}),g[18]=T,g[19]=o):o=g[19],g[20]!==i||g[21]!==o?(c=(0,r.FD)(el.Info.TopRow,{children:[i,o]}),g[20]=i,g[21]=o,g[22]=c):c=g[22],g[23]!==C?(u=C&&(0,r.Y)(el.Info.Address,{address:C}),g[23]=C,g[24]=u):u=g[24],g[25]!==b||g[26]!==D?(m=D&&D.installmentValue?(0,r.FD)(el.Info.BottomRow,{children:[(0,r.Y)(el.Info.PriceWithInstallmentValue,{priceValue:ee(D.value),installmentValue:ee(D.installmentValue),currency:D.currency}),b&&(0,r.Y)(el.Logo,{src:b,loading:"lazy","data-testid":"ad-card-logo"})]}):(0,r.Y)(el.Info.PriceValue,{number:ee((null==D?void 0:D.value)||""),currency:(null==D?void 0:D.currency)||"","data-testid":"ad-card-price"}),g[25]=b,g[26]=D,g[27]=m):m=g[27],g[28]!==M||g[29]!==(null==P?void 0:P.small)||g[30]!==R||g[31]!==y.shouldShowDealerInfo?(p=y.shouldShowDealerInfo&&M?(0,r.Y)(O,{logo:null==P?void 0:P.small,dealerName:R||"",url:M}):null,g[28]=M,g[29]=null==P?void 0:P.small,g[30]=R,g[31]=y.shouldShowDealerInfo,g[32]=p):p=g[32],g[33]!==c||g[34]!==u||g[35]!==m||g[36]!==p||g[37]!==$||g[38]!==E?(h=(0,r.FD)(el.Info,{vertical
1yAligned:$,withBorder:E,children:[c,u,m,p]}),g[33]=c,g[34]=u,g[35]=m,g[36]=p,g[37]=$,g[38]=E,g[39]=h):h=g[39],g[40]!==a||g[41]!==h||g[42]!==L||g[43]!==t?(v=(0,r.FD)(ea,(0,s._)((0,d._)({className:L},a),{children:[t,h]})),g[40]=a,g[41]=h,g[42]=L,g[43]=t,g[44]=v):v=g[44],v}:e=>{var a=e.ad,l=void 0===a?null:a,t=e.className,n=void 0===t?null:t,i=e.logo,o=void 0===i?null:i,c=(0,_._)(e,["ad","className","logo"]);c.withBorder;var u=(0,_._)(c,["withBorder"]);if(!l)return(0,r.Y)(ea,(0,d._)({className:n||""},u));var m=l.image,p=l.title,h=l.price,v=l.characteristics,g=l.businessSiteUrl,f=l.dealerLogos,x=l.dealerName,b=l.address;c.shouldShowDealerInfo;var y=c.withBorder,w=(0,_._)(c,["shouldShowDealerInfo","withBorder"]);return(0,r.FD)(ea,(0,s._)((0,d._)({className:n||void 0},w),{children:[(0,r.Y)(el.Image,{src:m,alt:p,loading:"lazy","data-testid":"ad-card-image"}),(0,r.FD)(el.Info,{verticalyAligned:h&&!!h.installmentValue,withBorder:void 0!==y&&y,children:[(0,r.FD)(el.Info.TopRow,{children:[(0,r.Y)(el.Info.Title,{"data-testid":"ad-card-title",children:p}),(0,r.Y)(el.Info.Characteristics,{items:v,"data-testid":"ad-card-characteristics"})]}),b&&(0,r.Y)(el.Info.Address,{address:b}),h&&h.installmentValue?(0,r.FD)(el.Info.BottomRow,{children:[(0,r.Y)(el.Info.PriceWithInstallmentValue,{priceValue:ee(h.value),installmentValue:ee(h.installmentValue),currency:h.currency}),o&&(0,r.Y)(el.Logo,{src:o,loading:"lazy","data-testid":"ad-card-logo"})]}):(0,r.Y)(el.Info.PriceValue,{number:ee((null==h?void 0:h.value)||""),currency:(null==h?void 0:h.currency)||"","data-testid":"ad-card-price"}),c.shouldShowDealerInfo&&g?(0,r.Y)(O,{logo:null==f?void 0:f.small,dealerName:x||"",url:g}):null]})]}))};el.Image=j,el.Info=q,el.Info.TopRow=S,el.Info.BottomRow=F,el.Info.Characteristics=D,el.Info.PriceValue=V,el.Info.PriceWithInstallmentValue=J,el.Info.Address=I,el.Info.Title=Z,el.Logo=U;let er=(0,N.default)(el,{target:"ex8v4z1"})();var et=l(106740),en=(e,a)=>{var l=Number.parseInt(e).toLocaleString("pt-PT");return a?"".concat(l," ").concat(a):l};function ei(e,a){var l,r,t,n,i,o,s,c,u,m=a=>{var l;return(null!=(l=e.attributes)?l:[]).find(e=>(null==e?void 0:e.key)===a)},p=null!=(t=m("year"))?t:m("first_registration_year"),h=p?"".concat(null!=(n=p.valueLabel)?n:""," "):"",v=m("mileage"),g=(null==v?void 0:v.value)?en(v.value,v.valueSuffix):"",f=m("fuel_type"),x=null!=(i=null==f?void 0:f.valueLabel)?i:"",b=m("gearbox"),y=null!=(o=null==b?void 0:b.valueLabel)?o:"",w=m("engine_capacity"),_=(null==w?void 0:w.value)?en(w.value,w.valueSuffix):"",N=m("engine_power"),A=(null==N?void 0:N.value)?en(N.value,N.valueSuffix):"",k=(null==(l=e.price)?void 0:l.__typename)==="AdNetGrossPrice"?e.price.grossMinorAmount:null,Y=k?String(Number.parseInt(k,10)/100):"0";return(0,d._)({id:e.id,originAdId:e.originAdId,title:null!=(s=e.title)?s:"",url:e.url,image:null!=(c=e.photos[0])?c:"",price:{value:Y,installmentValue:null,currency:null!=(u=null==(r=e.price)?void 0:r.currencyCode)?u:""},attributes:{mileage:{name:"mileage",value:g},fuel_type:{name:"fuel_type",value:x},gearbox:{name:"gearbox",value:y},year:{name:"year",value:h},engine_capacity:{name:"engine_capacity",value:_},engine_power:{name:"engine_power",value:A}}},!a&&(e=>{if(!e.location)return{};var a=e.location,l=[a.cityName,a.regionName].reduce((e,a,l)=>a?0===l?"".concat(e).concat(a):e?"".concat(e," (").concat(a,")"):"".concat(e).concat(a):e,"");return l?{address:l}:{}})(e))}var eo=l(568758),ed=l(604118),es=l(501152),ec=l(957744),eu=l.n(ec),em=l(759360),ep=l(984684),eh=e=>e.trim().charAt(0).toUpperCase()||"A",ev=e=>{var a=Number(e);return Number.isFinite(a)?a.toLocaleString("pt-PT"):e},eg={mileage:ep.A,fuel_type:eo.A,gearbox:ed.A,year:em.A},ef=(0,t.F)()?e=>{var a,l,t,i,o,d=(0,n.c)(60),s=e.ad,c=e.characteristics;if(d[0]!==(null==(m=s.attributes.engine_capacity)?void 0:m.value)||d[1]!==(null==(p=s.attributes.engine_power)?void 0:p.value)||d[2]!==s.image||d[3]!==s.price.currency||d[4]!==s.price.value||d[5]!==s.title||d[6]!==c){var m,p,h,v,g,f,b,y,w,_,N,A,k,Y,I,S,F,D,T,M,P,R,C,z,B,E,L,$,G,O,j,q=null==c?void 0:c.filter(ex);d[14]!==(null==(_=s.attributes.engine_capacity)?void 0:_.value)?(Y=null!=(D=null==(S=s.attributes.engine_capacity)||null==(I=S.value)?void 0:I.trim())?D:"",d[14]=null==(F=s.attributes.engine_capacity)?void 0:F.value,d[15]=Y):Y=d[15];var U=Y;d[16]!==(null==(N=s.attributes.engine_power)?void 0:N.value)?(T=null!=(C=null==(P=s.attributes.engine_power)||null==(M=P.value)?void 0:M.trim())?C:"",d[16]=null==(R=s.attributes.engine_power)?void 0:R.value,d[17]=T):T=
1d[17];var V=T;d[18]!==U||d[19]!==V?(z=[U,V].filter(Boolean),d[18]=U,d[19]=V,d[20]=z):z=d[20];var W=z.join(" \xb7 ");d[21]===Symbol.for("react.memo_cache_sentinel")?(w=(0,x.A)("flex h-full min-h-0 w-full min-w-0 flex-col rounded-medium","border border-border-subtle bg-background-primary py-200"),d[21]=w):w=d[21],b="flex min-h-0 flex-1 flex-col gap-[12px]",d[22]===Symbol.for("react.memo_cache_sentinel")?(B=(0,x.A)("overflow-hidden rounded-medium bg-background-secondary","h-[160px] min-[768px]:h-[124px]"),d[22]=B):B=d[22],d[23]!==s.image||d[24]!==s.title?(y=(0,r.Y)("div",{className:"shrink-0 px-200",children:(0,r.Y)("div",{className:B,children:s.image?(0,r.Y)(eu(),{loader:es.w,src:s.image,alt:s.title,width:216,height:160,className:"h-full w-full object-cover"}):(0,r.Y)("div",{className:(0,x.A)("flex h-full w-full items-center justify-center","bg-[linear-gradient(135deg,var(--color-background-secondary),var(--color-background-accent-subtle))]"),"aria-hidden":"true",children:(0,r.Y)("span",{className:"font-weight-bold text-[40px] text-foreground-action-primary/60",children:eh(s.title)})})})}),d[23]=s.image,d[24]=s.title,d[25]=y):y=d[25],g="flex min-h-0 flex-1 flex-col gap-[12px] px-150",d[26]!==s.price.value?(E=ev(s.price.value),d[26]=s.price.value,d[27]=E):E=d[27],d[28]!==s.price.currency?(L=(0,r.Y)(u.t$,{as:"span",variant:"bodyExtraSmall",className:"font-regular",children:s.price.currency}),d[28]=s.price.currency,d[29]=L):L=d[29],d[30]!==E||d[31]!==L?($=(0,r.FD)(u.Ii,{variant:"headlineMedium",className:"flex items-baseline gap-[4px] text-foreground-primary",translate:"no",children:[E,L]}),d[30]=E,d[31]=L,d[32]=$):$=d[32],d[33]!==s.title?(G=(0,r.Y)(u.Ii,{variant:"headlineSmall",className:"font-semibold truncate text-body-base leading-body-base tracking-regular text-foreground-primary","data-testid":"ad-card-title",children:s.title}),d[33]=s.title,d[34]=G):G=d[34],d[35]!==W?(O=W&&(0,r.Y)(u.t$,{variant:"bodyExtraSmall",className:"text-foreground-secondary","data-testid":"ad-card-engine-info",children:W}),d[35]=W,d[36]=O):O=d[36],d[37]!==G||d[38]!==O?(j=(0,r.FD)("div",{className:"flex flex-col gap-[4px]",children:[G,O]}),d[37]=G,d[38]=O,d[39]=j):j=d[39],d[40]!==$||d[41]!==j?(f=(0,r.FD)("div",{className:"flex shrink-0 flex-col gap-[12px]",children:[$,j]}),d[40]=$,d[41]=j,d[42]=f):f=d[42],h="flex min-h-0 flex-1 flex-col items-start justify-start",v=q.length>0&&(0,r.Y)("div",{className:"flex flex-wrap content-start gap-x-100 gap-y-[6px]",children:q.map(eb)}),d[0]=null==(A=s.attributes.engine_capacity)?void 0:A.value,d[1]=null==(k=s.attributes.engine_power)?void 0:k.value,d[2]=s.image,d[3]=s.price.currency,d[4]=s.price.value,d[5]=s.title,d[6]=c,d[7]=h,d[8]=v,d[9]=g,d[10]=f,d[11]=b,d[12]=y,d[13]=w}else h=d[7],v=d[8],g=d[9],f=d[10],b=d[11],y=d[12],w=d[13];return d[43]!==h||d[44]!==v?(a=(0,r.Y)("div",{className:h,children:v}),d[43]=h,d[44]=v,d[45]=a):a=d[45],d[46]!==s.address?(l=s.address&&(0,r.Y)(u.t$,{variant:"bodyExtraSmall",className:"shrink-0 truncate text-foreground-secondary","data-testid":"ad-card-address",children:s.address}),d[46]=s.address,d[47]=l):l=d[47],d[48]!==g||d[49]!==f||d[50]!==a||d[51]!==l?(t=(0,r.FD)("div",{className:g,children:[f,a,l]}),d[48]=g,d[49]=f,d[50]=a,d[51]=l,d[52]=t):t=d[52],d[53]!==t||d[54]!==b||d[55]!==y?(i=(0,r.FD)("div",{className:b,children:[y,t]}),d[53]=t,d[54]=b,d[55]=y,d[56]=i):i=d[56],d[57]!==i||d[58]!==w?(o=(0,r.Y)("article",{className:w,children:i}),d[57]=i,d[58]=w,d[59]=o):o=d[59],o}:e=>{var a,l,t,n,i,o,d=e.ad,s=e.characteristics,c=null==s?void 0:s.filter(e=>!!(null==e?void 0:e.value)),m=[null!=(i=null==(l=d.attributes.engine_capacity)||null==(a=l.value)?void 0:a.trim())?i:"",null!=(o=null==(n=d.attributes.engine_power)||null==(t=n.value)?void 0:t.trim())?o:""].filter(Boolean).join(" \xb7 ");return(0,r.Y)("article",{className:(0,x.A)("flex h-full min-h-0 w-full min-w-0 flex-col rounded-medium","border border-border-subtle bg-background-primary py-200"),children:(0,r.FD)("div",{className:"flex min-h-0 flex-1 flex-col gap-[12px]",children:[(0,r.Y)("div",{className:"shrink-0 px-200",children:(0,r.Y)("div",{className:(0,x.A)("overflow-hidden rounded-medium bg-background-secondary","h-[160px] min-[768px]:h-[124px]"),children:d.image?(0,r.Y)(eu(),{loader:es.w,src:d.image,alt:d.title,width:216,height:160,className:"h-full w-full object-cover"}):(0,r.Y)("div",{className:(0,x.A)("flex h-full w-full items-center justify-center","bg-[linear-gradient(135deg,var(--color-background-secondary),var(--color-background-accent-subtle))]"),"aria-hidden":"true",children:(0,r.Y)("span",{className:"font-weight-bold text-[40px] text-foreground-action-primary/60",children:eh(d.title)})})})}),(0,r.FD)("div",{className:"flex min-h-0 flex-1 flex-col gap-[12px] px-150",children:[(0,r.FD)("div",{className:"flex shrink-0 flex-col gap-[12px]",children:[(0,r.FD)(u.Ii,{variant:"headlineMedium",className:"flex items-baseline gap-[4px] text-foreground-primary",translate:"no",children:[ev(d.price.value),(0,r.Y)(u.t$,{as:"span",variant:"bodyExtraSmall",className:"font-regular",children:d.price.currency})]}),(0,r.FD)("div",{className:"flex flex-col gap-[4px]",children:[(0,r.Y)(u.Ii,{variant:"headlineSmall",className:"font-semibold truncate text-body-base leading-body-base tracking-regular text-foreground-primary","data-testid":"ad-card-title",children:d.title}),m&&(0,r.Y)(u.t$,{variant:"bodyExtraSmall",className:"text-foreground-secondary","data-testid":"ad-card-engine-info",children:m})]})]}),(0,r.Y)("div",{className:"flex min-h-0 flex-1 flex-col items-start justify-start",children:c.length>0&&(0,r.Y)("div",{className:"flex flex-wrap content-start gap-x-100 gap-y-[6px]",children:c.map(e=>{var a=eg[e.name];return(0,r.FD)("div",{className:"flex items-center gap-50",children:[a&&(0,r.Y)(a,{size:"icon-small","aria-hidden":"true"}),(0,r.Y)(u.t$,{variant:"bodySmall",className:"overflow-hidden font-primary text-body-small leading-body-small tracking-wide text-nowrap text-ellipsis",children:e.value})]},e.name)})})}),d.address&&(0,r.Y)(u.t$,{variant:"bodyExtraSmall",className:"shrink-0 truncate text-foreground-secondary","data-testid":"ad-card-address",children:d.address})]})]})})};function ex(e){return!!(null==e?void 0:e.value)}function eb(e){var a=eg[e.name];return(0,r.FD)("div",{className:"flex items-center gap-50",children:[a&&(0,r.Y)(a,{size:"icon-small","aria-hidden":"true"}),(0,r.Y)(u.t$,{variant:"bodySmall",className:"overflow-hidden font-primary text-body-small leading-body-small tracking-wide text-nowrap text-ellipsis",children:e.value})]},e.name)}var ey="-mx-turbo-24 flex gap-turbo-12 overflow-x-auto px-turbo-24 pb-turbo-4 [scrollbar-width:none] md:-mx-turbo-32 md:gap-turbo-16 md:px-turbo-32 lg:-mx-turbo-40 lg:px-turbo-40 xl:mx-0 xl:gap-turbo-16 xl:px-0 [&::-webkit-scrollbar]:hidden",ew="-mx-turbo-24 flex gap-turbo-12 overflow-x-auto pl-turbo-24 pr-0 pb-turbo-4 [scrollbar-width:none] md:-mx-turbo-32 md:gap-turbo-16 md:px-turbo-32 lg:-mx-turbo-40 lg:pl-turbo-40 lg:pr-0 xl:mx-0 xl:pl-0 xl:pr-0 [&::-webkit-scrollbar]:hidden",e_="w-[171px] max-w-[171px] min-w-[171px] shrink-0 xl:w-[calc((100%_-_80px)/6)] xl:max-w-[calc((100%_-_80px)/6)] xl:min-w-[calc((100%_-_80px)/6)]",eN="flex w-full min-w-0 items-center justify-between gap-sm",eA="text-h3 leading-h3",ek="flex min-w-0 flex-1 items-center",eY="shrink-0",eI="relative w-full pb-[75%
1] [&>*]:absolute [&>*]:top-0 [&>*]:left-0 [&>*]:h-full [&>*]:w-full [&>*]:rounded-t-xs [&>*]:rounded-b-none",eS="flex flex-col border border-solid border-gray p-sm rounded-b-xs",eF=e=>({"--page-margin":null!=e?e:"var(--spacing-sm)"}),eD="flex w-full flex-col",eT=e=>{var a=e.featuredCardStyle,l=e.carouselMarginTop;return(0,x.A)("mb-xs flex w-full justify-center overflow-y-hidden max-md:-ml-[var(--page-margin)] max-md:-mr-[var(--page-margin)] max-md:w-[calc(100%+calc(2*var(--page-margin)))]",(e=>null==e?"mt-md":"string"==typeof e?"mt-[var(--carousel-margin-top)]":null!=e.desktop?"mt-[var(--carousel-margin-top-mobile)] xl:mt-[var(--carousel-margin-top-desktop)]":"mt-[var(--carousel-margin-top-mobile)]")(l),void 0!==a&&a&&"xl:overflow-visible")},eM=e=>(e=>{var a;if(null!=e)return"string"==typeof e?{"--carousel-margin-top":e}:(0,d._)({"--carousel-margin-top-mobile":null!=(a=e.mobile)?a:"var(--spacing-md)"},null!=e.desktop?{"--carousel-margin-top-desktop":e.desktop}:{})})(e.carouselMarginTop),eP=e=>{var a=e.shouldUseNewSimilarAdsDesign,l=e.featuredCardStyle;return void 0!==l&&l?"flex w-full gap-200 overflow-x-auto pb-xs max-md:px-[var(--page-margin)] [&>*]:w-[200px] [&>*]:flex-[0_0_auto] xl:-mx-xs xl:w-[calc(100%+16px)] xl:px-xs xl:pt-xs [&_article]:h-full [&_article]:border-none xl:[&_article]:shadow-[0_2px_8px_0_rgba(0,0,0,0.1)] xl:[&>*]:w-[184px] [&_[data-testid=ad-card-image]]:max-h-[131px] [&_[data-testid=ad-card-image]]:basis-[131px]":void 0!==a&&a?"flex w-full gap-200 overflow-x-auto pb-xs max-md:px-[var(--page-margin)] md:gap-100 [&_article]:h-full max-md:[&>*]:w-[248px] max-md:[&>*]:min-w-[248px] max-md:[&>*]:max-w-[248px] md:[&>*]:w-[196px] md:[&>*]:min-w-[196px] md:[&>*]:max-w-[196px]":"flex w-full overflow-x-auto pb-xs max-md:px-[var(--page-margin)] [&_article]:h-full [&>*]:min-w-[242px] [&>*]:max-w-[260px] sm:[&>*]:min-w-[260px] md:[&>*]:w-[calc((100%-var(--ads-gap-total))/var(--ads-slots))] md:[&>*]:min-w-[var(--ads-item-min-width)]"},eR=e=>{var a=e.slots,l=void 0===a?4:a,r=e.gap,t=void 0===r?16:r,n=e.len,i=e.shouldUseNewSimilarAdsDesign,o=e.featuredCardStyle;if(!(void 0!==o&&o)&&!(void 0!==i&&i))return{gap:"".concat(t,"px"),"--ads-slots":l,"--ads-gap-total":"".concat((l-1)*t,"px"),"--ads-item-min-width":(void 0===n?l:n)>l?"194px":"auto"}},eC=l(698319),ez={canScrollPrev:!1,canScrollNext:!1,showNavigation:!1};function eB(e){return{showNavigation:e.scrollWidth>e.clientWidth+1,canScrollPrev:e.scrollLeft>1,canScrollNext:e.scrollLeft+e.clientWidth<e.scrollWidth-1}}function eE(){var e=(0,eC._)((0,i.useState)(null),2),a=e[0],l=e[1],r=(0,eC._)((0,i.useState)(ez),2),t=r[0],n=r[1],o=(0,i.useCallback)(e=>{l(e),n(e?eB(e):ez)},[]);(0,i.useEffect)(()=>{if(a){var e=()=>{n(eB(a))},l=new ResizeObserver(e);return l.observe(a),a.addEventListener("scroll",e,{passive:!0}),()=>{l.disconnect(),a.removeEventListener("scroll",e)}}},[a]);var d=(0,i.useCallback)(e=>{if(a){var l=Math.max(.75*a.clientWidth,200);a.scrollTo({left:a.scrollLeft+("next"===e?l:-l),behavior:"smooth"})}},[a]);return{railRef:o,canScrollPrev:t.canScrollPrev,canScrollNext:t.canScrollNext,showNavigation:t.showNavigation,scrollPrev:()=>d("prev"),scrollNext:()=>d("next")}}var eL=e=>e.filter(e=>null!=e),e$=e=>{var a=e.isListingRelaxationLayout,l=e.ruleId,r=e.isSameDealer;return a?l&&"default"!==l?l:"active_inventory":r?"seller_inventory":"active_inventory"},eG=(0,t.F)()?e=>{var a,l,t,y,_,N,A,k,Y,I,S,F=(0,n.c)(133),D=e.group,T=e.sectionIndex,M=e.touchPointButton,P=e.touchPointPage,R=e.showInventoryBtn,C=e.showTitle,z=e.titleTranslationKey,B=e.titleTranslationNamespace,E=e.parentAdMakeModel,L=e.customTitleRenderer,$=e.pageMargin,G=e.carouselMarginTop,O=e.shouldUseNewSimilarAdsDesign,j=e.featuredCardStyle,q=e.layoutMode,U=e.formatGroupFilterPills,V=e.onApplyGroupFilters,W=e.renderAdCard,K=e.peekNextCard,H=e.showDesktopCarouselNav,Q=void 0!==j&&j,X=void 0===q?"default":q,J=void 0!==K&&K,Z=(0,b.A)(B||o.wL).t,ee=(0,p.z1)().trackEvent,ea=(0,i.useRef)(!1),el=eE(),en=el.railRef,eo=el.canScrollPrev,ed=el.canScrollNext,es=el.showNavigation,ec=el.scrollPrev,eu=el.scrollNext,em=D.isSameDealer,ep=D.adsAlgorithm,eh=D.businessUrl,ev=D.ruleId,eg=D.appliedFilters,ex=D.legacyAppliedFilters,eb="listing-relaxation"===X,eI="homepage-recommended"===X,eS=eI||"home"===P;F[0]!==U||F[1]!==D?(eJ=U?U(D):[],F[0]=U,F[1]=D,F[2]=eJ):eJ=F[2];var eC=eJ;F[3]!==eg||F[4]!==ex?(eZ=(0,et.T)({legacyAppliedFilters:ex,appliedFilters:eg}),F[3]=eg,F[4]=ex,F[5]=eZ):eZ=F[5];var ez=eZ,eB=eb&&!!V&&ez.length>0;F[6]!==D.ads||F[7]!==em?(F[9]!==em?(e1=e=>ei(e,em),F[9]=em,F[10]=e1):e1=F[10],e0=D.ads.map(e1),F[6]=D.ads,F[7]=em,F[8]=e0):e0=F[8];var eG=e0;F[11]!==ep?(e2=ep.map(eO),F[11]=ep,F[12]=e2):e2=F[12];var eV=e2;F[13]!==eV||F[14]!==eG||F[15]!==eb||F[16]!==em||F[17]!==ev||F[18]!==P||F[19]!==ee?(e3=e=>{e.isIntersecting&&!ea.current&&eG.length>0&&(ee("ads_view","click",{touch_point_page:P,ad_recommendation:eV,recommended_ads:!0,ad_impressions:eG.map(ej),ad_position:eG.map(eq),recommendation_source:e$({isListingRelaxationLayout:eb,ruleId:ev,isSameDealer:em})}),ea.current=!0)},F[13]=eV,F[14]=eG,F[15]=eb,F[16]=em,F[17]=ev,F[18]=P,F[19]=ee,F[20]=e3):e3=F[20];var eW=(0,m.Xd)(e3);F[21]!==eV||F[22]!==eS||F[23]!==eb||F[24]!==em||F[25]!==ev||F[26]!==M||F[27]!==ee?(e4=(e,a)=>{eb?(0,f.Bn)({adReason:f.EN.LISTING,adReasonWidget:(0,f.Fq)(ev),adId:e.id}):eS?(0,f.Bn)({adReason:f.EN.HOME,adReasonWidget:f.Rq.RECOMMENDATIONS,adId:e.id}):(0,f.Bn)({adReason:f.EN.AD_PAGE,adReasonWidget:f.Rq.RECOMMENDATIONS,adId:e.id});var l="active_inventory";em?l="seller_inventory":ev&&"default"!==ev&&(l=ev),ee("ad_click","click",(0,d._)({touch_point_button:M,ad_id:e.id,ad_recommendation:eV,recommended_ads:!0,recommendation_position:a+1,recommendation_source:l},(0,p._7)(e.originAdId)))},F[21]=eV,F[22]=eS,F[23]=eb,F[24]=em,F[25]=ev,F[26]=M,F[27]=ee,F[28]=e4):e4=F[28];var eK=e4;F[29]!==P||F[30]!==ee?(e6=()=>{ee("business_site_click","click",{touch_point_page:P,touch_point_button:"similar_ads"})},F[29]=P,F[30]=ee,F[31]=e6):e6=F[31];var eH=e6,eQ=null!=E?E:"";F[32]===Symbol.for("react.memo_cache_sentinel")?(e5="OTOMOTO",F[32]=e5):e5=F[32],F[33]!==eQ?(e8={MakeModel:eQ,platform:e5},F[33]=eQ,F[34]=e8):e8=F[34];var eX=e8;e:{if(z){F[35]!==Z||F[36]!==z?(e9=Z(z),F[35]=Z,F[36]=z,F[37]=e9):e9=F[37],e7=e9;break e}if(em){F[38]!==Z?(ae=Z("similar-ads-heading-when-ads-from-same-dealer"),F[38]=Z,F[39]=ae):ae=F[39],e7=ae;break e}var eJ,eZ,e0,e1,e2,e3,e4,e6,e5,e8,e7,e9,ae,aa,al=ev?"similar-ads-".concat(ev,"-title"):"similar-ads-heading";F[40]!==al||F[41]!==Z||F[42]!==eX?(aa=Z(al,eX,{fallback:"similar-ads-heading"}),F[40]=al,F[41]=Z,F[42]=eX,F[43]=aa):aa=F[43],e7=aa}var ar=e7;F[44]!==eB||F[45]!==ez||F[46]!==V||F[47]!==ev||F[48]!==P||F[49]!==ee?(as=()=>{eB&&V&&(ee("business_site_click","click",{touch_point_page:P,touch_point_button:"similar_ads_title_apply_filters",recommendation_source:null!=ev?ev:"active_inventory"}),V(ez))},F[44]=eB,F[45]=ez,F[46]=V,F[47]=ev,F[48]=P,F[49]=ee,F[50]=as):as=F[50];var at=as;F[51]!==eB||F[52]!==L||F[53]!==eC||F[54]!==at||F[55]!==eb||F[56]!==C||F[57]!==ar?(ac=()=>
1{if(!C)return null;if(eb)return(0,r.FD)("div",{className:"flex w-full flex-col gap-100","data-testid":"listing-relaxation-group-header",children:[(0,r.Y)("div",{className:"flex w-full min-w-0 items-center gap-100",children:(0,r.FD)("button",{type:"button",className:"flex min-w-0 flex-1 cursor-pointer items-center gap-50 border-0 bg-transparent p-0 text-left",onClick:at,disabled:!eB,"data-testid":"listing-relaxation-group-title",children:[(0,r.Y)(u.H2,{className:(0,x.A)(eA,"min-w-0 flex-1"),children:ar}),eB?(0,r.Y)(c.default,{"aria-hidden":!0,size:20,className:"shrink-0 text-foreground-primary"}):null]})}),eC.length>0?(0,r.Y)("div",{className:"flex flex-wrap gap-100","data-testid":"listing-relaxation-group-filter-pills",children:eC.map(eU)}):null]});var e=L?(0,r.Y)("span",{className:"min-w-0 flex-1",children:L(ar)}):(0,r.Y)(u.H2,{className:(0,x.A)(eA,"min-w-0 flex-1"),children:ar});return(0,r.Y)("div",{className:ek,children:e})},F[51]=eB,F[52]=L,F[53]=eC,F[54]=at,F[55]=eb,F[56]=C,F[57]=ar,F[58]=ac):ac=F[58];var an=ac;F[59]!==Q||F[60]!==eK||F[61]!==eI||F[62]!==W||F[63]!==O?(au=(e,a)=>{var l=e.attributes,t=l.year,n=l.mileage,i=l.fuel_type,o=l.gearbox,c=()=>{eK(e,a)};return W?(0,r.Y)("div",{className:eI?e_:"flex h-full min-h-0 flex-col",children:W({ad:e,index:a,onClick:c})},e.id):(0,r.Y)(w(),{className:eI?e_:"flex h-full min-h-0 flex-col",onClick:c,href:e.url,target:eI?void 0:"_blank",children:O&&!Q?(0,r.Y)(ef,{ad:e,characteristics:eL([n,i,o,t])}):(0,r.Y)(er,{ad:(0,s._)((0,d._)({},e),{characteristics:eL([t,n,i])}),withBorder:!Q})},e.id)},F[59]=Q,F[60]=eK,F[61]=eI,F[62]=W,F[63]=O,F[64]=au):au=F[64];var ai=au,ao=em&&eG.length>0&&R&&!eb?eh:null,ad=C||!!ao;if(eI){var as,ac,au,am,ap,ah,av,ag,af,ax,ab,ay=void 0!==H&&H&&es,aw=0===T?"similar-ads-section":"similar-ads-section-".concat(T);F[65]!==an?(am=an(),F[65]=an,F[66]=am):am=F[66],F[67]!==am?(ap=(0,r.Y)("div",{className:"min-w-0 flex-1",children:am}),F[67]=am,F[68]=ap):ap=F[68],F[69]!==ed||F[70]!==eo||F[71]!==eu||F[72]!==ec||F[73]!==ay?(ah=ay?(0,r.FD)("div",{className:"hidden shrink-0 gap-turbo-4 lg:flex",children:[(0,r.Y)(h.$,{layout:"icon-only",variant:"secondary",size:"small","aria-label":"Scroll recommended ads left","data-testid":"recommended-ads-carousel-prev",className:"!size-turbo-32 !min-h-turbo-32 !min-w-turbo-32 !rounded-turbo-full [&_.turbo-button-icon-only]:!size-turbo-16",disabled:!eo,onClick:ec,icon:(0,r.Y)(v.Y,{size:16})}),(0,r.Y)(h.$,{layout:"icon-only",variant:"secondary",size:"small","aria-label":"Scroll recommended ads right","data-testid":"recommended-ads-carousel-next",className:"!size-turbo-32 !min-h-turbo-32 !min-w-turbo-32 !rounded-turbo-full [&_.turbo-button-icon-only]:!size-turbo-16",disabled:!ed,onClick:eu,icon:(0,r.Y)(g.v,{size:16})})]}):null,F[69]=ed,F[70]=eo,F[71]=eu,F[72]=ec,F[73]=ay,F[74]=ah):ah=F[74],F[75]!==ap||F[76]!==ah?(av=(0,r.FD)("div",{className:"flex w-full items-center justify-between gap-turbo-16",children:[ap,ah]}),F[75]=ap,F[76]=ah,F[77]=av):av=F[77];var a_=J?ew:ey,aN=J?"true":void 0;return F[78]!==eG||F[79]!==ai?(F[81]!==ai?(af=(e,a)=>ai(e,a),F[81]=ai,F[82]=af):af=F[82],ag=eG.map(af),F[78]=eG,F[79]=ai,F[80]=ag):ag=F[80],F[83]!==en||F[84]!==a_||F[85]!==aN||F[86]!==ag?(ax=(0,r.Y)("div",{ref:en,className:a_,"data-testid":"homepage-recommended-rail","data-peek":aN,children:ag}),F[83]=en,F[84]=a_,F[85]=aN,F[86]=ag,F[87]=ax):ax=F[87],F[88]!==eW||F[89]!==aw||F[90]!==av||F[91]!==ax?(ab=(0,r.FD)("div",{ref:eW,className:"flex w-full flex-col gap-turbo-24","data-testid":aw,children:[av,ax]}),F[88]=eW,F[89]=aw,F[90]=av,F[91]=ax,F[92]=ab):ab=F[92],ab}F[93]!==$?(a=eF($),F[93]=$,F[94]=a):a=F[94];var aA=0===T?"similar-ads-section":"similar-ads-section-".concat(T);return F[95]!==eH||F[96]!==ao||F[97]!==an||F[98]!==ad||F[99]!==Z?(l=ad?(0,r.FD)("div",{className:eN,children:[an(),ao?(0,r.Y)(w(),{className:eY,href:ao,target:"_blank",children:(0,r.Y)(u.$n,{variant:"tertiary",onClick:eH,children:Z("similar-ads-inventory-button")})}):null]}):null,F[95]=eH,F[96]=ao,F[97]=an,F[98]=ad,F[99]=Z,F[100]=l):l=F[100],F[101]!==G||F[102]!==Q?(t=eT({featuredCardStyle:Q,carouselMarginTop:G}),F[101]=G,F[102]=Q,F[103]=t):t=F[103],F[104]!==G?(y=eM({carouselMarginTop:G}),F[104]=G,F[105]=y):y=F[105],F[106]!==eG.length||F[107]!==Q||F[108]!==O?(_=eP({len:eG.length,shouldUseNewSimilarAdsDesign:O,featuredCardStyle:Q}),F[106]=eG.length,F[107]=Q,F[108]=O,F[109]=_):_=F[109],F[110]!==eG.length||F[111]!==Q||F[112]!==O?(N=eR({len:eG.length,shouldUseNewSimilarAdsDesign:O,featuredCardStyle:Q}),F[110]=eG.length,F[111]=Q,F[112]=O,F[113]=N):N=F[113],F[114]!==eG||F[115]!==ai?(F[117]!==ai?(k=(e,a)=>ai(e,a),F[117]=ai,F[118]=k):k=F[118],A=eG.map(k),F[114]=eG,F[115]=ai,F[116]=A):A=F[116],F[119]!==_||F[120]!==N||F[121]!==A?(Y=(0,r.Y)("div",{className:_,style:N,children:A}),F[119]=_,F[120]=N,F[121]=A,F[122]=Y):Y=F[122],F[123]!==eW||F[124]!==t||F[125]!==y||F[126]!==Y?(I=(0,r.Y)("div",{ref:eW,className:t,style:y,children:Y}),F[123]=eW,F[124]=t,F[125]=y,F[126]=Y,F[127]=I):I=F[127],F[128]!==a||F[129]!==aA||F[130]!==l||F[131]!==I?(S=(0,r.FD)("div",{className:eD,style:a,"data-testid":aA,children:[l,I]}),F[128]=a,F[129]=aA,F[130]=l,F[131]=I,F[132]=S):S=F[132],S}:e=>{var a=e.group,l=e.sectionIndex,t=e.touchPointButton,n=e.touchPointPage,y=e.showInventoryBtn,_=e.showTitle,N=e.titleTranslationKey,A=e.titleTranslationNamespace,k=e.parentAdMakeModel,Y=e.customTitleRenderer,I=e.pageMargin,S=e.carouselMarginTop,F=e.shouldUseNewSimilarAdsDesign,D=e.featuredCardStyle,T=void 0!==D&&D,M=e.layoutMode,P=void 0===M?"default":M,R=e.formatGroupFilterPills,C=e.onApplyGroupFilters,z=e.renderAdCard,B=e.peekNextCard,E=void 0!==B&&B,L=e.showDesktopCarou
1selNav,$=(0,b.A)(A||o.wL).t,G=(0,p.z1)().trackEvent,O=(0,i.useRef)(!1),j=eE(),q=j.railRef,U=j.canScrollPrev,V=j.canScrollNext,W=j.showNavigation,K=j.scrollPrev,H=j.scrollNext,Q=a.isSameDealer,X=a.adsAlgorithm,J=a.businessUrl,Z=a.ruleId,ee=a.appliedFilters,ea=a.legacyAppliedFilters,el="listing-relaxation"===P,en="homepage-recommended"===P,eo=en||"home"===n,ed=(0,i.useMemo)(()=>R?R(a):[],[R,a]),es=(0,i.useMemo)(()=>(0,et.T)({legacyAppliedFilters:ea,appliedFilters:ee}),[ea,ee]),ec=el&&!!C&&es.length>0,eu=(0,i.useMemo)(()=>a.ads.map(e=>ei(e,Q)),[a.ads,Q]),em=X.map(e=>e.algorithm),ep=(0,m.Xd)(e=>{e.isIntersecting&&!O.current&&eu.length>0&&(G("ads_view","click",{touch_point_page:n,ad_recommendation:em,recommended_ads:!0,ad_impressions:eu.map(e=>+e.id),ad_position:eu.map((e,a)=>a+1),recommendation_source:e$({isListingRelaxationLayout:el,ruleId:Z,isSameDealer:Q})}),O.current=!0)}),eh=(0,i.useCallback)((e,a)=>{el?(0,f.Bn)({adReason:f.EN.LISTING,adReasonWidget:(0,f.Fq)(Z),adId:e.id}):eo?(0,f.Bn)({adReason:f.EN.HOME,adReasonWidget:f.Rq.RECOMMENDATIONS,adId:e.id}):(0,f.Bn)({adReason:f.EN.AD_PAGE,adReasonWidget:f.Rq.RECOMMENDATIONS,adId:e.id});var l="active_inventory";Q?l="seller_inventory":Z&&"default"!==Z&&(l=Z),G("ad_click","click",(0,d._)({touch_point_button:t,ad_id:e.id,ad_recommendation:em,recommended_ads:!0,recommendation_position:a+1,recommendation_source:l},(0,p._7)(e.originAdId)))},[em,G,t,Q,Z,el,eo]),ev=(0,i.useCallback)(()=>{G("business_site_click","click",{touch_point_page:n,touch_point_button:"similar_ads"})},[G,n]),eg=(0,i.useMemo)(()=>({MakeModel:null!=k?k:"",platform:"OTOMOTO"}),[k]),ex=(0,i.useMemo)(()=>N?$(N):Q?$("similar-ads-heading-when-ads-from-same-dealer"):$(Z?"similar-ads-".concat(Z,"-title"):"similar-ads-heading",eg,{fallback:"similar-ads-heading"}),[$,N,eg,Q,Z]),eb=(0,i.useCallback)(()=>{ec&&C&&(G("business_site_click","click",{touch_point_page:n,touch_point_button:"similar_ads_title_apply_filters",recommendation_source:null!=Z?Z:"active_inventory"}),C(es))},[ec,es,C,Z,n,G]),eI=()=>{if(!_)return null;if(el)return(0,r.FD)("div",{className:"flex w-full flex-col gap-100","data-testid":"listing-relaxation-group-header",children:[(0,r.Y)("div",{className:"flex w-full min-w-0 items-center gap-100",children:(0,r.FD)("button",{type:"button",className:"flex min-w-0 flex-1 cursor-pointer items-center gap-50 border-0 bg-transparent p-0 text-left",onClick:eb,disabled:!ec,"data-testid":"listing-relaxation-group-title",children:[(0,r.Y)(u.H2,{className:(0,x.A)(eA,"min-w-0 flex-1"),children:ex}),ec?(0,r.Y)(c.default,{"aria-hidden":!0,size:20,className:"shrink-0 text-foreground-primary"}):null]})}),ed.length>0?(0,r.Y)("div",{className:"flex flex-wrap gap-100","data-testid":"listing-relaxation-group-filter-pills",children:ed.map(e=>(0,r.Y)("span",{className:"min-h-8 inline-flex items-center justify-center rounded-full border border-border-accent bg-background-accent-subtle px-150 py-50 text-body-small leading-body-small text-foreground-primary",children:e.label},e.label))}):null]});var e=Y?(0,r.Y)("span",{className:"min-w-0 flex-1",children:Y(ex)}):(0,r.Y)(u.H2,{className:(0,x.A)(eA,"min-w-0 flex-1"),children:ex});return(0,r.Y)("div",{className:ek,children:e})},eS=(e,a)=>{var l=e.attributes,t=l.year,n=l.mileage,i=l.fuel_type,o=l.gearbox,c=()=>{eh(e,a)};return z?(0,r.Y)("div",{className:en?e_:"flex h-full min-h-0 flex-col",children:z({ad:e,index:a,onClick:c})},e.id):(0,r.Y)(w(),{className:en?e_:"flex h-full min-h-0 flex-col",onClick:c,href:e.url,target:en?void 0:"_blank",children:F&&!T?(0,r.Y)(ef,{ad:e,characteristics:eL([n,i,o,t])}):(0,r.Y)(er,{ad:(0,s._)((0,d._)({},e),{characteristics:eL([t,n,i])}),withBorder:!T})},e.id)},eC=Q&&eu.length>0&&y&&!el?J:null,ez=_||!!eC;return en?(0,r.FD)("div",{ref:ep,className:"flex w-full flex-col gap-turbo-24","data-testid":0===l?"similar-ads-section":"similar-ads-section-".concat(l),children:[(0,r.FD)("div",{className:"flex w-full items-center justify-between gap-turbo-16",children:[(0,r.Y)("div",{className:"min-w-0 flex-1",children:eI()}),void 0!==L&&L&&W?(0,r.FD)("div",{className:"hidden shrink-0 gap-turbo-4 lg:flex",children:[(0,r.Y)(h.$,{layout:"icon-only",variant:"secondary",size:"small","aria-label":"Scroll recommended ads left","data-testid":"recommended-ads-carousel-prev",className:"!size-turbo-32 !min-h-turbo-32 !min-w-turbo-32 !rounded-turbo-full [&_.turbo-button-icon-only]:!size-turbo-16",disabled:!U,onClick:K,icon:(0,r.Y)(v.Y,{size:16})}),(0,r.Y)(h.$,{layout:"icon-only",variant:"secondary",size:"small","aria-label":"Scroll recommended ads right","data-testid":"recommended-ads-carousel-next",className:"!size-turbo-32 !min-h-turbo-32 !min-w-turbo-32 !rounded-turbo-full [&_.turbo-button-icon-only]:!size-turbo-16",disabled:!V,onClick:H,icon:(0,r.Y)(g.v,{size:16})})]}):null]}),(0,r.Y)("div",{ref:q,className:E?ew:ey,"data-testid":"homepage-recommended-rail","data-peek":E?"true":void 0,children:eu.map((e,a)=>eS(e,a))})]}):(0,r.FD)("div",{className:eD,style:eF(I),"data-testid":0===l?"similar-ads-section":"similar-ads-section-".concat(l),children:[ez?(0,r.FD)("div",{className:eN,children:[eI(),eC?(0,r.Y)(w(),{className:eY,href:eC,target:"_blank",children:(0,r.Y)(u.$n,{variant:"tertiary",onClick:ev,children:$("similar-ads-inventory-button")})}):null]}):null,(0,r.Y)("div",{ref:ep,className:eT({featuredCardStyle:T,carouselMarginTop:S}),style:eM({carouselMarginTop:S}),children:(0,r.Y)("div",{className:eP({len:eu.length,shouldUseNewSimilarAdsDesign:F,featuredCardStyle:T}),style:eR({len:eu.length,shouldUseNewSimilarAdsDesign:F,featuredCardStyle:T}),children:eu.map((e,a)=>eS(e,a))})})]})};function eO(e){return e.algorithm}function ej(e){return+e.id}function eq(e,a){return a+1}function eU(e){return(0,r.Y)("span",{className:"min-h-8 inline-flex items-center justify-center rounded-full border border-border-accent bg-background-accent-subtle px-150 py-50 text-body-small leading-body-small text-foreground-primary",children:e.label},e.label)}var eV=l(744477),eW=(0,t.F)()?()=>{var e,a,l=(0,n.c)(2);return l[0]===Symbol.for("react.memo_cache_sentinel")?(e=(0,r.Y)("div",{className:eI,children:(0,r.Y)(eV.A,{})}),l[0]=e):e=l[0],l[1]===Symbol.for("react.memo_cache_sentinel")?(a=(0,r.FD)("div",{children:[e,(0,r.FD)("div",{className:eS,children:[(0,r.Y)(eV.A,{height:"16px",width:"100%",mb:8}),(0,r.Y)(eV.A,{height:"12px",width:"100%",mb:4}),(0,r.Y)(eV.A,{height:"12px",width:"40%",mb:8}),(0,r.Y)(eV.A,{height:"24px",width:"60%"})]})]}),l[1]=a):a=l[1],a}:()=>(0,r.FD)("div",{children:[(0,r.Y)("div",{className:eI,children:(0,r.Y)(eV.A,{})}),(0,r.FD)("div",{className:eS,children:[(0,r.Y)(eV.A,{height:"16px",width:"100%",mb:8}),(0,r.Y)(eV.A,{height:"12px",width:"100%",mb:4}),(0,r.Y)(eV.A,{height:"12px",width:"40%",mb:8}),(0,r.Y)(eV.A,{height:"24px",width:"60%"})]})]}),eK=(0,t.F)()?e=>{var a,l,t,i,o,d,s,c,u,m,p,h=(0,n.c)(36),v=e.sectionIndex,g=e.maxResults,f=e.showTitle,x=e.customTitleRenderer,b=e.pageMargin,y=e.carouselMarginTop,w=e.shouldUseNewSimilarAdsDesign,_=e.featuredCardStyle,N=void 0!==_&&_;h[0]!==b?(a=eF(b),h[0]=b,h[1]=a):a=h[1];var A=0===v?"similar-ads-section":"similar-ads-section-".concat(v);return h[2]!==x||h[3]!==f?(l=f?(0,r.Y)("div",{className:eN,children:(0,r.Y)("div",{className:ek,children:x?(0,r.FD)(r.FK,{children:[(0,r.Y)(eV.A,{height:"1px",width:"100%"}),(0,r.Y)(eV.A,{height:"24px",width:"350px",mt:8,mb:8,ml:16,mr:16}),(0,r.Y)(eV.A,{height:"1px",width:"100%"})]}):(0,r.Y)(eV.A,{height:"24px",width:"350px",mt:8,mb:8})})}):null,h[2]=x,h[3]=f,h[4]=l):l=h[4],h[5]!==y||h[6]!==N?(t=eT({featuredCardStyle:N,carouselMarginTop:y}),h[5]=y,h[6]=N,h[7]=t):t=h[7],h[8]!==y?(i=eM({carouselMarginTop:y}),h[8]=y,h[9]=i):i=h[9],h[10]!==N||h[11]!==g||h[12]!==w?(o=eP({len:g,shouldUseNewSimilarAdsDesign:w,featuredCardStyle:N}),h[10]=N,h[11]=g,h[12]=w,h[13]=o):o=h[13],h[14]!==N||h[15]!==g||h[16]!==w?(d=eR({len:g,shouldUseNewSimilarAdsDesign:w,featuredCardStyle:N}),h[14]=N,h[15]=g,h[16]=w,h[17]=d):d=h[17],h[18]!==g||h[19]!==v?(h[21]!==v?(c=(e,a)=>(0,r.Y)(eW,{},"similar-ads-skeleton-card-".concat(v,"-").concat(a)),h[21]=v,h[22]=c):c=h[22],s=Array.from({length:g},c),h[18]=g,h[19]=v,h[20]=s):s=h[20],h[23]!==o||h[24]!==d||h[25]!==s?(u=(0,r.Y)("div",{className:o,style:d,children:s}),h[23]=o,h[24]=d,h[25]=s,h[26]=u):u=h[26],h[27]!==u||h[28]!==t||h[29]!==i?(m=(0,r.Y)("div",{className:t,style:i,children:u}),h[27]=u,h[28]=t,h[29]=i,h[30]=m):m=h[30],h[31]!==m||h[32]!==a||h[33]!==A||h[34]!==l?(p=(0,r.FD)("div",{className:eD,style:a,"data-testid":A,children:[l,m]}),h[31]=m,h[32]=a,h[33]=A,h[34]=l,h[35]=p):p=h[35],p}:e=>{var a=e.sectionIndex,l=e.maxResults,t=e.showTitle,n=(e.showInventoryBtn,e.customTitleRenderer),i=e.pageMargin,o=e.carouselMarginTop,d=e.shouldUseNewSimilarAdsDesign,s=e.featuredCardStyle,c=void 0!==s&&s;return(0,r.FD)("div",{className:eD,style:eF(i),"data-testid":0===a?"similar-ads-section":"similar-ads-section-".concat(a),children:[t?(0,r.Y)("div",{className:eN,children:(0,r.Y)("div",{className:ek,children:n?(0,r.FD)(r.FK,{children:[(0,r.Y)(eV.A,{height:"1px",width:"100%"}),(0,r.Y)(eV.A,{height:"24px",width:"350px",mt:8,mb:8,ml:16,mr:16}),(0,r.Y)(eV.A,{height:"1px",width:"100%"})]}):(0,r.Y)(eV.A,{height:"24px",width:"350px",mt:8,mb:8})})}):null,(0,r.Y)("div",{className:eT({featuredCardStyle:c,carouselMarginTop:o}),style:eM({carouselMarginTop:o}),children:(0,r.Y)("div",{className:eP({len:l,shouldUseNewSimilarAdsDesign:d,featuredCardStyle:c}),style:eR({len:l,shouldUseNewSimilarAdsDesign:d,featuredCardStyle:c}),children:Array.from({length:l},(e,l)=>(0,r.Y)(eW,{},"similar-ads-skeleton-card-".concat(a,"-").concat(l)))})})]})},eH=(0,t.F)()?function(e){var a,l,t,i,o,d,s,c=(0,n.c)(64),u=e.adId,m=e.maxResults,p=e.touchPointPage,h=e.touchPointButton,v=e.showInventoryBtn,g=e.showTitle,f=e.titleTranslationKey,x=e.titleTranslationNamespace,b=e.customTitleRenderer,y=e.pageMargin,w=e.maxGroupsToRender,_=e.featuredCardStyle,N=e.carouselMarginTop,A=e.layoutMode,k=e.peekNextCard,Y=e.showDesktopCarou
1selNav,I=e.loadingPresentation,S=e.renderEmptyFallback,F=e.formatGroupFilterPills,D=e.onApplyGroupFilters,T=e.renderAdCard,M=e.queryState,P=void 0!==_&&_,R=void 0===A?"default":A,C=void 0!==k&&k,z=void 0!==Y&&Y,B=M.fetching,E=M.error,L=M.visibleGroups,$=M.parentAdMakeModel,G=M.shouldUseNewSimilarAdsDesign,O=M.skeletonSectionCount;return 0===w?null:B?"none"===(void 0===I?"skeleton":I)?null:(c[0]!==N||c[1]!==b||c[2]!==P||c[3]!==m||c[4]!==y||c[5]!==G||c[6]!==v||c[7]!==g||c[8]!==O?(c[10]!==N||c[11]!==b||c[12]!==P||c[13]!==m||c[14]!==y||c[15]!==G||c[16]!==v||c[17]!==g?(l=(e,a)=>(0,r.Y)(eK,{sectionIndex:a,maxResults:m,showTitle:g,showInventoryBtn:v,customTitleRenderer:b,pageMargin:y,carouselMarginTop:N,shouldUseNewSimilarAdsDesign:G,featuredCardStyle:P},"similar-ads-skeleton-".concat(a)),c[10]=N,c[11]=b,c[12]=P,c[13]=m,c[14]=y,c[15]=G,c[16]=v,c[17]=g,c[18]=l):l=c[18],a=(0,r.Y)(r.FK,{children:Array.from({length:O},l)}),c[0]=N,c[1]=b,c[2]=P,c[3]=m,c[4]=y,c[5]=G,c[6]=v,c[7]=g,c[8]=O,c[9]=a):a=c[9],a):!B&&(E||0===L.length)?(c[19]!==S?(t=null!=(i=null==S?void 0:S())?i:null,c[19]=S,c[20]=t):t=c[20],t):(c[21]!==u||c[22]!==N||c[23]!==b||c[24]!==P||c[25]!==F||c[26]!==R||c[27]!==D||c[28]!==y||c[29]!==$||c[30]!==C||c[31]!==T||c[32]!==G||c[33]!==z||c[34]!==v||c[35]!==g||c[36]!==f||c[37]!==x||c[38]!==h||c[39]!==p||c[40]!==L?(c[42]!==u||c[43]!==N||c[44]!==b||c[45]!==P||c[46]!==F||c[47]!==R||c[48]!==D||c[49]!==y||c[50]!==$||c[51]!==C||c[52]!==T||c[53]!==G||c[54]!==z||c[55]!==v||c[56]!==g||c[57]!==f||c[58]!==x||c[59]!==h||c[60]!==p?(d=(e,a)=>{var l;return(0,r.Y)(eG,{group:e,sectionIndex:a,touchPointButton:null!=u?u:h,touchPointPage:p,showInventoryBtn:v,showTitle:g,titleTranslationKey:f,titleTranslationNamespace:x,parentAdMakeModel:$,customTitleRenderer:b,pageMargin:y,carouselMarginTop:N,shouldUseNewSimilarAdsDesign:G,featuredCardStyle:P,layoutMode:R,peekNextCard:C,showDesktopCarouselNav:z,formatGroupFilterPills:F,onApplyGroupFilters:D,renderAdCard:T},null!=(l=e.ruleId)?l:"similar-ads-group-".concat(a))},c[42]=u,c[43]=N,c[44]=b,c[45]=P,c[46]=F,c[47]=R,c[48]=D,c[49]=y,c[50]=$,c[51]=C,c[52]=T,c[53]=G,c[54]=z,c[55]=v,c[56]=g,c[57]=f,c[58]=x,c[59]=h,c[60]=p,c[61]=d):d=c[61],o=L.map(d),c[21]=u,c[22]=N,c[23]=b,c[24]=P,c[25]=F,c[26]=R,c[27]=D,c[28]=y,c[29]=$,c[30]=C,c[31]=T,c[32]=G,c[33]=z,c[34]=v,c[35]=g,c[36]=f,c[37]=x,c[38]=h,c[39]=p,c[40]=L,c[41]=o):o=c[41],c[62]!==o?(s=(0,r.Y)(r.FK,{children:o}),c[62]=o,c[63]=s):s=c[63],s)}:function(e){var a,l=e.adId,t=e.maxResults,n=e.touchPointPage,i=e.touchPointButton,o=e.showInventoryBtn,d=e.showTitle,s=e.titleTranslationKey,c=e.titleTranslationNamespace,u=e.customTitleRenderer,m=e.pageMargin,p=e.maxGroupsToRender,h=e.featuredCardStyle,v=void 0!==h&&h,g=e.carouselMarginTop,f=e.layoutMode,x=void 0===f?"default":f,b=e.peekNextCard,y=void 0!==b&&b,w=e.showDesktopCarouselNav,_=void 0!==w&&w,N=e.loadingPresentation,A=e.renderEmptyFallback,k=e.formatGroupFilterPills,Y=e.onApplyGroupFilters,I=e.renderAdCard,S=e.queryState,F=S.fetching,D=S.error,T=S.visibleGroups,M=S.parentAdMakeModel,P=S.shouldUseNewSimilarAdsDesign,R=S.skeletonSectionCount;return 0===p?null:F?"none"===(void 0===N?"skeleton":N)?null:(0,r.Y)(r.FK,{children:Array.from({length:R},(e,a)=>(0,r.Y)(eK,{sectionIndex:a,maxResults:t,showTitle:d,showInventoryBtn:o,customTitleRenderer:u,pageMargin:m,carouselMarginTop:g,shouldUseNewSimilarAdsDesign:P,featuredCardStyle:v},"similar-ads-skeleton-".concat(a)))}):!F&&(D||0===T.length)?null!=(a=null==A?void 0:A())?a:null:(0,r.Y)(r.FK,{children:T.map((e,a)=>{var t;return(0,r.Y)(eG,{group:e,sectionIndex:a,touchPointButton:null!=l?l:i,touchPointPage:n,showInventoryBtn:o,showTitle:d,titleTranslationKey:s,titleTranslationNamespace:c,parentAdMakeModel:M,customTitleRenderer:u,pageMargin:m,carouselMarginTop:g,shouldUseNewSimilarAdsDesign:P,featuredCardStyle:v,layoutMode:x,peekNextCard:y,showDesktopCarouselNav:_,formatGroupFilterPills:k,onApplyGroupFilters:Y,renderAdCard:I},null!=(t=e.ruleId)?t:"similar-ads-group-".concat(a))})})},eQ=l(226365),eX=l(620703),eJ=l(983267);function eZ(e){var a,l,r=e.adId,t=e.maxResults,n=e.experiments,o=e.maxGroupsToRender,c=e.usePersonalizedQuery,u=void 0!==c&&c,m=e.personalizedStrategy,p=e.sessionID,h=e.personalizedMaxAds,v=e.searchBasedSimilarAds,g=e.pause,f=void 0!==g&&g,x=e.excludeAdIds,b=(0,eQ.useExperiment)(eX.BV),y=!!((null==v||null==(a=v.filters)?void 0:a.length)||(null==v||null==(l=v.legacyFilters)?void 0:l.length)),w=(0,eJ.z)(y?{requestType:"search",maxAds:t,experiments:n,filters:null==v?void 0:v.filters,legacyFilters:null==v?void 0:v.legacyFilters,pause:f||u}:{id:null!=r?r:"",maxAds:t,experiments:n,pause:f||u||!r}),_=w.fetching,N=w.data,A=w.error,k=w.parentAdMakeModel,Y=(0,eJ.R)({adId:r,strategy:m,sessionID:p,maxAds:h,pause:f||!u}),I=Y.fetching,S=Y.data,F=Y.error,D=u?I:_,T=u?S:N,M=u?F:A,P=(0,i.useMemo)(()=>
1{if(0===o||!(null==T?void 0:T.length))return[];var e=new Set(x),a=e.size?T.map(a=>(0,s._)((0,d._)({},a),{ads:a.ads.filter(a=>!e.has(a.id)),adsAlgorithm:a.adsAlgorithm.filter(a=>!e.has(a.adID))})).filter(e=>e.ads.length>0):T,l=null!=o?o:a.length;return a.slice(0,l)},[T,o,x]),R=!D&&!M&&P.length>0;return{fetching:D,error:M,visibleGroups:P,hasVisibleContent:R,parentAdMakeModel:k,shouldUseNewSimilarAdsDesign:"b"===b,skeletonSectionCount:null!=o?o:1}}var e0=(0,i.memo)((0,t.F)()?e=>{var a,l,t=(0,n.c)(35),i=e.adId,d=e.maxResults,s=e.touchPointPage,c=e.touchPointButton,u=e.showInventoryBtn,m=e.showTitle,p=e.titleTranslationKey,h=e.titleTranslationNamespace,v=e.customTitleRenderer,g=e.pageMargin,f=e.experiments,x=e.maxGroupsToRender,b=e.usePersonalizedQuery,y=e.personalizedStrategy,w=e.sessionID,_=e.personalizedMaxAds,N=e.excludeAdIds,A=e.featuredCardStyle,k=e.carouselMarginTop,Y=e.layoutMode,I=e.peekNextCard,S=e.showDesktopCarouselNav,F=e.searchBasedSimilarAds,D=e.loadingPresentation,T=e.pause,M=e.renderEmptyFallback,P=e.formatGroupFilterPills,R=e.onApplyGroupFilters,C=e.renderAdCard,z=void 0===d?o.WX:d,B=void 0===u||u,E=void 0===m||m,L=void 0!==b&&b,$=void 0!==A&&A,G=void 0===Y?"default":Y,O=void 0!==I&&I,j=void 0!==S&&S,q=void 0===D?"skeleton":D,U=void 0!==T&&T;t[0]!==i||t[1]!==N||t[2]!==f||t[3]!==x||t[4]!==z||t[5]!==U||t[6]!==_||t[7]!==y||t[8]!==F||t[9]!==w||t[10]!==L?(a={adId:i,maxResults:z,experiments:f,maxGroupsToRender:x,usePersonalizedQuery:L,personalizedStrategy:y,sessionID:w,personalizedMaxAds:_,searchBasedSimilarAds:F,pause:U,excludeAdIds:N},t[0]=i,t[1]=N,t[2]=f,t[3]=x,t[4]=z,t[5]=U,t[6]=_,t[7]=y,t[8]=F,t[9]=w,t[10]=L,t[11]=a):a=t[11];var V=eZ(a);return t[12]!==i||t[13]!==k||t[14]!==v||t[15]!==$||t[16]!==P||t[17]!==G||t[18]!==q||t[19]!==x||t[20]!==z||t[21]!==R||t[22]!==g||t[23]!==O||t[24]!==V||t[25]!==C||t[26]!==M||t[27]!==j||t[28]!==B||t[29]!==E||t[30]!==p||t[31]!==h||t[32]!==c||t[33]!==s?(l=(0,r.Y)(eH,{adId:i,maxResults:z,touchPointPage:s,touchPointButton:c,showInventoryBtn:B,showTitle:E,titleTranslationKey:p,titleTranslationNamespace:h,customTitleRenderer:v,pageMargin:g,maxGroupsToRender:x,featuredCardStyle:$,carouselMarginTop:k,layoutMode:G,peekNextCard:O,showDesktopCarouselNav:j,loadingPresentation:q,renderEmptyFallback:M,formatGroupFilterPills:P,onApplyGroupFilters:R,renderAdCard:C,queryState:V}),t[12]=i,t[13]=k,t[14]=v,t[15]=$,t[16]=P,t[17]=G,t[18]=q,t[19]=x,t[20]=z,t[21]=R,t[22]=g,t[23]=O,t[24]=V,t[25]=C,t[26]=M,t[27]=j,t[28]=B,t[29]=E,t[30]=p,t[31]=h,t[32]=c,t[33]=s,t[34]=l):l=t[34],l}:e=>{var a=e.adId,l=e.maxResults,t=void 0===l?o.WX:l,n=e.touchPointPage,i=e.touchPointButton,d=e.showInventoryBtn,s=e.showTitle,c=e.titleTranslationKey,u=e.titleTranslationNamespace,m=e.customTitleRenderer,p=e.pageMargin,h=e.experiments,v=e.maxGroupsToRender,g=e.usePersonalizedQuery,f=e.personalizedStrategy,x=e.sessionID,b=e.personalizedMaxAds,y=e.excludeAdIds,w=e.featuredCardStyle,_=e.carouselMarginTop,N=e.layoutMode,A=e.peekNextCard,k=e.showDesktopCarouselNav,Y=e.searchBasedSimilarAds,I=e.loadingPresentation,S=e.pause,F=e.renderEmptyFallback,D=e.formatGroupFilterPills,T=e.onApplyGroupFilters,M=e.renderAdCard,P=eZ({adId:a,maxResults:t,experiments:h,maxGroupsToRender:v,usePersonalizedQuery:void 0!==g&&g,personalizedStrategy:f,sessionID:x,personalizedMaxAds:b,searchBasedSimilarAds:Y,pause:void 0!==S&&S,excludeAdIds:y});return(0,r.Y)(eH,{adId:a,maxResults:t,touchPointPage:n,touchPointButton:i,showInventoryBtn:void 0===d||d,showTitle:void 0===s||s,titleTranslationKey:c,titleTranslationNamespace:u,customTitleRenderer:m,pageMargin:p,maxGroupsToRender:v,featuredCardStyle:void 0!==w&&w,carouselMarginTop:_,layoutMode:void 0===N?"default":N,peekNextCard:void 0!==A&&A,showDesktopCarouselNav:void 0!==k&&k,loadingPresentation:void 0===I?"skeleton":I,renderEmptyFallback:F,formatGroupFilterPills:D,onApplyGroupFilters:T,renderAdCard:M,queryState:P})});e0.displayName="SimilarAdsContainer"},501152:(e,a,l)=>{l.d(a,{w:()=>r});var r=e=>{var a=e.src,l=e.width,r=e.quality,t=void 0===r?void 0:r;return[a.split(/;s=(\d+)x(\d+)/)[0],";s=".concat(l,"x0"),t?";q=".concat(t):""].join("")}},983267:(e,a,l)=>{l.d(a,{R:()=>b,z:()=>f});var r=l(300561),t=l(698319),n=l(339824),i=l(138209),o=l(383055),d=l(346686),s=(0,d.UG)("\n  query getRecommendedPersonalizedAds(\n    $input: RecommendedPersonalizedAdsInput!\n  ) {\n    recommendedPersonalizedAds(input: $input) {\n      __typename\n      ... on RecommendedPersonalizedAdsOutput {\n        ads {\n          id\n          title\n          url\n          originAdId\n          photos\n          location {\n            cityName\n            regionName\n          }\n          deliveredFrom\n          attributes {\n            key\n            value\n            valueLabel\n            valueSuffix\n          }\n          price {\n            currencyCode\n            isNegotiable\n            isNet\n            ... on AdNetGrossPrice {\n              grossMinorAmount\n            }\n          }\n        }\n        metaData {\n          adsAlgorithm {\n            adID\n            algorithm\n            recommendationOrigin\n          }\n          adsFromSameDealer\n        }\n      }\n      ... on RecommendedPersonalizedAdsError {\n        message\n      }\n    }\n  }\n"),c=(0,d.UG)("\n  query getRecommendedSimilarAds(\n    $id: String\n    $maxAds: Int!\n    $experiments: [Experiment!]\n    $filters: [RecommendedSimilarAdsFilterInput!]\n    $legacyFilters: [RecommendedSimilarAdsLegacyFilterInput!]\n  ) {\n    recommendedSimilarAds(\n      input: {\n        id: $id\n        maxAds: $maxAds\n        experiments: $experiments\n        filters: $filters\n        legacyFilters: $legacyFilters\n      }\n    ) {\n      __typename\n      ... on RecommendedSimilarAdsOutput {\n        parentAd {\n          attributes {\n            key\n            value\n            valueLabel\n          }\n          seller {\n            __typename\n            ... on ProfessionalSeller {\n              dealerAdsUrl\n            }\n          }\n        }\n        multiSimilarAds {\n          metaData {\n            adsFromSameDealer\n            ruleId\n            appliedFilters {\n              key\n              value\n              values\n              operator\n              altered\n            }\n            legacyAppliedFilters {\n              name\n              value\n              altered\n            }\n            adsAlgorithm {\n              adID\n              algorithm\n            }\n          }\n          ads {\n            id\n            title\n            url\n            originAdId\n            photos\n            location {\n              cityName\n              regionName\n            }\n            deliveredFrom\n            attributes {\n              key\n              value\n              valueLabel\n              valueSuffix\n            }\n            price {\n              currencyCode\n              isNegotiable\n              isNet\n              ... on AdNetGrossPrice {\n                grossMinorAmount\n              }\n            }\n          }\n        }\n      }\n      ... on RecommendedSimilarAdsError {\n        message\n      }\n    }\n  }\n"),u=(0,d.UG)("\n  query getRecommendedSimilarAdsBySearch(\n    $maxAds: Int!\n    $experiments: [Experiment!]\n    $filters: [RecommendedSimilarAdsFilterInput!]\n    $legacyFilters: [RecommendedSimilarAdsLegacyFilterInput!]\n  ) {\n    recommendedSimilarAds(\n      input: {\n        maxAds: $maxAds\n        experiments: $experiments\n        filters: $filters\n        legacyFilters: $legacyFilters\n      }\n    ) {\n      __typename\n      ... on RecommendedSimilarAdsOutput {\n        multiSimilarAds {\n          metaData {\n            adsFromSameDealer\n            ruleId\n            appliedFilters {\n              key\n              value\n              values\n              operator\n              altered\n            }\n            legacyAppliedFilters {\n              name\n              value\n              altered\n            }\n            adsAlgorithm {\n              adID\n              algorithm\n            }\n          }\n          ads {\n            id\n            title\n            url\n            originAdId\n            photos\n            location {\n              cityName\n              regionName\n            }\n            deliveredFrom\n            attributes {\n              key\n              value\n              valueLabel\n              valueSuffix\n            }\n            price {\n              currencyCode\n              isNegotiable\n              isNet\n              ... on AdNetGrossPrice {\n                grossMinorAmount\n              }\n            }\n          }\n        }\n      }\n      ... on RecommendedSimilarAdsError {\n        message\n      }\n    }\n  }\n"),m=l(382662),p=l(934085),h=l(761876),v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=e.enabled,l=void 0===a||a,r=(0,p.Rw)(h.OJp),t=Array.isArray(r)?r.filter(Boolean):[],n=t.join(",");return{experiments:(0,i.useMemo)(()=>l?t.reduce((e,a)=>(e.push({key:a,variant:(0,m.F5)(a)||"a"}),e),[]):[],[l,n])}},g=e=>(null!=e?e:[]).flatMap(e=>
1(null==e?void 0:e.adID)==null||null==e.algorithm?[]:[{adID:e.adID,algorithm:e.algorithm,recommendationOrigin:(e=>"PERSONALIZED"===e||"BACKFILL"===e)(e.recommendationOrigin)?e.recommendationOrigin:null}]),f=e=>{var a,l,n,d="search"===e.requestType,s=e.maxAds,m=e.experiments,p=e.pause,h=!!d&&!!((null==(a=e.filters)?void 0:a.length)||(null==(l=e.legacyFilters)?void 0:l.length)),v=void 0!==p&&p||(d?!h:!("id"in e&&e.id)),f=d?{maxAds:s,experiments:m,filters:e.filters,legacyFilters:e.legacyFilters}:{id:e.id,maxAds:s,experiments:m},x=(0,t._)((0,o.IT)({query:c,variables:f,pause:v||d}),1)[0],b=(0,t._)((0,o.IT)({query:u,variables:f,pause:v||!d}),1)[0],y=d?b:x,w=y.data,_=y.fetching,N=y.error,A=(0,i.useMemo)(()=>{var e=null==w?void 0:w.recommendedSimilarAds;return(null==e?void 0:e.__typename)!=="RecommendedSimilarAdsOutput"?null:(e=>{var a,l="parentAd"in e&&e.parentAd?(e=>{if((null==e?void 0:e.__typename)==="ProfessionalSeller"&&e.dealerAdsUrl)try{var a=new URL(e.dealerAdsUrl);return a.pathname="/inventory",a.toString()}catch(e){return}})(e.parentAd.seller):void 0;return(null!=(a=e.multiSimilarAds)?a:[]).reduce((e,a)=>{if(null==a)return e;var t,n,i=(null!=(t=a.ads)?t:[]).filter(e=>null!=e);if(i.length<2)return e;var o=a.metaData,d=null!=(n=null==o?void 0:o.adsFromSameDealer)&&n;return e.push((0,r._)({ads:i,metaData:o,isSameDealer:d,ruleId:null==o?void 0:o.ruleId,adsAlgorithm:g(null==o?void 0:o.adsAlgorithm),appliedFilters:null==o?void 0:o.appliedFilters,legacyAppliedFilters:null==o?void 0:o.legacyAppliedFilters},d&&l&&{businessUrl:l})),e},[])})(e)},[null==w?void 0:w.recommendedSimilarAds]),k=(0,i.useMemo)(()=>{if(d)return null;var e,a,l,r=null==(e=x.data)?void 0:e.recommendedSimilarAds;if((null==r?void 0:r.__typename)!=="RecommendedSimilarAdsOutput")return null;var t=null!=(l=null==(a=r.parentAd)?void 0:a.attributes)?l:[],n=e=>{var a,l,r=t.find(a=>(null==a?void 0:a.key)===e);return null!=(l=null!=(a=null==r?void 0:r.valueLabel)?a:null==r?void 0:r.value)?l:""};return[n("make"),n("model")].filter(Boolean).join(" ")||null},[null==(n=x.data)?void 0:n.recommendedSimilarAds,d]);return{fetching:_,data:A,error:N,hasResponse:(null==w?void 0:w.recommendedSimilarAds)!==void 0,parentAdMakeModel:k}},x=e=>({adId:e.adId,timestamp:new Date(e.timestamp)}),b=e=>{var a,l=e.adId,d=e.strategy,c=void 0===d?"SIMILAR_ADS":d,u=e.sessionID,m=e.maxAds,p=void 0===m?4:m,h=e.experiments,f=e.categoryIds,b=e.pause,y="SESSION"===c,w="PROMOTED"===c,_=y||w,N=void 0!==b&&b||(_?!(null==u?void 0:u.trim()):!l),A=v({enabled:!N}).experiments,k=(0,i.useMemo)(()=>[...null!=h?h:[],...A],[h,A]),Y=N||y?"{}":JSON.stringify(null!=(a=(0,n.c)())?a:{}),I=(0,i.useMemo)(()=>{var e=k.length>0?{experiments:k}:void 0;if(y)return{input:(0,r._)({strategy:"SESSION",sessionID:null!=u?u:"",maxAds:p},e)};var a=(e=>{var a=JSON.parse(e);return(0,r._)({},a.views&&{views:a.views.map(x)},a.favourites&&{favourites:a.favourites.map(x)},a.contactLeads&&{contactLeads:a.contactLeads.map(e=>({adId:e.adId,event:e.event,timestamp:new Date(e.timestamp)}))},a.serviceLeads&&{serviceLeads:a.serviceLeads.map(e=>({adId:e.adId,event:e.event,timestamp:new Date(e.timestamp)}))})})(Y);return w?{input:(0,r._)({strategy:"PROMOTED",sessionID:null!=u?u:"",maxAds:p,interactions:(0,r._)({},a)},(null==f?void 0:f.length)?{categoryIds:f}:{},e)}:{input:(0,r._)({strategy:"SIMILAR_ADS",maxAds:p,interactions:(0,r._)({current:{adId:null!=l?l:"",timestamp:new Date}},a)},e)}},[y,w,l,u,p,f,Y,k]),S=(0,t._)((0,o.IT)({query:s,variables:I,pause:N}),1)[0],F=S.data,D=S.fetching,T=S.error;return{fetching:D,data:(0,i.useMemo)(()=>{var e,a,l,r,t=null==F?void 0:F.recommendedPersonalizedAds;if((null==t?void 0:t.__typename)!=="RecommendedPersonalizedAdsOutput")return null;var n=(null!=(l=t.ads)?l:[]).filter(e=>null!=e);return!w&&n.length<2?null:[{ads:n,metaData:null,isSameDealer:null!=(r=null==(e=t.metaData)?void 0:e.adsFromSameDealer)&&r,adsAlgorithm:g(null==(a=t.metaData)?void 0:a.adsAlgorithm),ruleId:null}]},[null==F?void 0:F.recommendedPersonalizedAds,w]),error:T,hasResponse:(null==F?void 0:F.recommendedPersonalizedAds)!==void 0}}}}]);

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.