PageSourceSearch

https://www.odlo.com/_nuxt/1GEncTav.js

js odlo.com collected 2026-09-24 22:06:04 UTC 5,678 bytes, 1 lines download raw bytes

1import{ag as ue,bF as de,a4 as fe,k as pe,as as me,B as ge,M as _e,c9 as be,g as O,_ as ye,c8 as he,b_ as ke,bX as E,bG as ve,R as Ce}from"./gwS-z_dU.js";import{_ as we,a as xe}from"./DzsVYofD.js";import{S as Se,a as Pe}from"./BYnjvYiV.js";import{g as Te}from"./cfsdIA4I.js";import{u as De}from"./Bj4b_uKN.js";import{A as Ie,u as c,a_ as Be,z as s,L as p,aO as S,aP as u,aY as g,a$ as Ae,b0 as P,W as i,aS as _,aN as r,aM as F,V as R,aV as j,C as o}from"./DwnjgjC8.js";import"./9TE3GxgE.js";import"./C5_q5rTQ.js";import"./DjBGMRT2.js";function Me(l){return!l.sys.contentType||l.sys.contentType.sys.id==="componentTeaser"}function Le(l){return!l.sys.contentType||l.sys.contentType.sys.id==="contentPage"}function $e(l){return!l.sys.contentType||l.sys.contentType.sys.id==="listingPage"}const Ne={key:0,class:"h3 uppercase"},Oe={class:"mb-16"},Ee={key:0,class:"h3 uppercase"},Fe={key:1,class:"mt-4 max-w-[63.25rem] font-normal tracking-wide text-grey-40 lg:text-lg lg:leading-6 mobile:text-1.2base mobile:leading-5.4"},Re=500,je=Ie({name:"CMSCarousel",__name:"Carousel",props:{blok:{}},async setup(l){let b,T;const d=l,D=ke();let I=0;const B=()=>{const e=Date.now();e-I<Re||(I=e,D&&D())},v=c(!1),{fetchBySlugs:V}=ue(`carousel-category-${d.blok?.fields.headline}`),{taxonomy:A}=de(),a=c(d.blok),M=o(()=>E(a.value?.fields?.headline)),z=o(()=>E(a.value?.fields?.topline)),W=c(),H=c("50%"),{isSmaller:K}=fe(),U=o(()=>K("lg")),X=Te(),{allCurrentPromotions:G}=pe(),Y=me(be),y=c(!1),q=o(()=>{const e=(a.value?.fields).isDark,t=(a.value?.fields).textColor||"White";return e?!0:e===!1?!1:t.toLowerCase()==="white"}),J=o(()=>{const e=a.value?.fields?.fallbackProducts;return Array.isArray(e)?e.filter(t=>typeof t=="object"&&t!==null&&"id"in t&&typeof t.id=="number").map(t=>t.id):[]}),Q=o(()=>{const e=a.value?.fields?.fallbackCategories;return Array.isArray(e)?e.flatMap(t=>typeof t=="object"&&t!==null&&"id"in t&&typeof t.id=="number"&&ve(A.value,n=>n.category&&n.category?.id===t.id)?.path||[])||[]:[]}),{productsData:Z,listingPageData:ee,fetching:te}=([b,T]=Be(()=>re(J.value,Q.value)),b=await b,T(),b),L=o(()=>Z.value?.map(oe)??[]),se=o(()=>ee.value??[]),ae=o(()=>[...a.value?.fields?.fallbackContentEntries??[],...se.value].flatMap(e=>e&&Me(e)?e:e&&(Le(e)||$e(e))?e.fields.teaser||[]:[]).filter(e=>e!==null)??[]),ne=o(()=>["w-full !overflow-visible transition-all delay-100 duration-700 lg:!pb-20 mobile:!ml-0 mobile:!pb-11",{"lg:translate-x-1/4 mobile:translate-x-1/2":!v.value}]),$=o(()=>["!w-12 rounded-full p-0 after:!content-none disabled:hidden mobile:invisible"]),oe=e=>{const{name:t,image:n,link:m}=Ce(e);return{url:m?.value.toString()??"",heading:t?.value.toString()??"",desktopImage:n.value?.hash??"",mobileImage:n.value?.hash??"",label:t?.value.toString()??""}},le=e=>({url:he(e?.fields.buttonLinks?.[0],A.value),heading:e?.fields.teaserHeading??"",desktopImage:e?.fields.teaserImage?.fields.desktopImage?.fields.file?.url??"",mobileImage:e?.fields.teaserImage?.fields.mobileImage?.fields.file?.url??"",label:e?.fields.buttonLinks?.[0]?.fields?.label??""}),N=e=>v.value||U.value?{transform:"translateX(0px)"}:{transform:`translateX(${100*(e+1)}px)`},ie=()=>{y.value=!0};d.blok?.fields.promotionContent&&G.value.find(e=>e.customData.campaignKey===d.blok?.fields.campaignKey)&&(a.value=d.blok?.fields.promotionContent);async function re(e,t){const n={data:c([]),pending:c(!1)},m={data:c([])},[{data:C,pending:h},{data:w}]=await Promise.all([e.length?De({params:{ids:e.map(x=>Number(x))||[],with:Y}},`Carousel-${d.blok?.fields.headline}-${e.join("-")}`):n,t.length?V({content_type:"listingPage",limit:12,"fields.path[in]":t}):m]);return{productsData:C,listingPageData:w,fetching:h}}return(e,t)=>{const n=ye,m=ge,C=we,h=Pe,w=xe,x=Se,ce=_e;return s(a)&&!s(te)?(r(),p("div",{key:0,"data-testid":"ta-carousel-wrapper",class:_(["wrapper contents-carousel overflow-hidden pt-16","bg-[color:rgb(var(--color-background))] text-[color:var(--color-text)]",s(q)?"dark-mode":"light-mode"])},[s(a).fields.path?(r(),S(m,{key:0,to:s(a).fields.path,raw:"","track-click":B,class:"group mb-8 flex justify-between lg:mb-16 lg:justify-start"},{default:u(()=>[s(M)?(r(),p("h2",Ne,P(s(a).fields.headline),1)):g("",!0),i(n,{name:"arrow",direction:"right",class:"flex-0 transition delay-100 duration-500 group-hover:translate-x-0 group-hover:opacity-100 lg:ml-10 lg:-translate-x-8 mobile:ml-2",size:48})]),_:1},8,["to"])):g("",!0),Ae("div",Oe,[!s(a).fields.path&&s(M)?(r(),p("h2",Ee,P(s(a).fields.headline),1)):g("",!0),s(z)?(r(),p("p",Fe,P(s(a).fields.topline),1)):g("",!0)]),i(ce,{onEnter:t[0]||(t[0]=f=>v.value=!0)},{default:u(()=>[i(x,F({ref_key:"swiperRef",ref:W,"data-testid":"horizontal-carousel",class:s(ne)},s(X),{style:{"--swiper-navigation-top-offset":s(H)},onInit:ie}),{default:u(()=>[(r(!0),p(R,null,j(s(L),(f,k)=>(r(),S(h,{key:`product-${k}`,class:_({"!w-1/4":!s(y)})},{default:u(()=>[i(C,F({ref_for:!0}
1,f,{style:N(k),provider:"scayle","track-click":B}),null,16,["style"])]),_:2},1032,["class"]))),128)),(r(!0),p(R,null,j(s(ae),(f,k)=>(r(),S(h,{key:`cms-${f?.sys.id??"slide"}`,class:_({"!w-1/4":!s(y)})},{default:u(()=>[i(w,{teaser:f,"slide-data":le(f),"slide-style":N(s(L).length+k),"slide-class":"transition-all delay-200 duration-700"},null,8,["teaser","slide-data","slide-style"])]),_:2},1032,["class"]))),128)),i(O,{class:_(["swiper-button-prev",s($),{hidden:!s(y)}])},{default:u(()=>[i(n,{name:"arrow",direction:"left"})]),_:1},8,["class"]),i(O,{class:_(["swiper-button-next",s($)])},{default:u(()=>[i(n,{name:"arrow",direction:"right"})]),_:1},8,["class"])]),_:1},16,["class","style"])]),_:1})],2)):g("",!0)}}}),qe=Object.assign(je,{__name:"CMSCarousel"});export{qe as default};

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.