1import{fL as y,jC as W,be as z,hz as k,hf as q,bd as S,hh as d,ft as x,fr as b,iF as i,aQ as D,fs as Q,gW as T,b5 as U,aX as L,hF as w,a_ as X,fn as A,iT as I,j4 as B,fw as J,fq as r,j9 as Z,j5 as G,je as Y,j3 as ee,jb as ne,gi as ae,i5 as te,jB as oe,fp as le,jc as re,i_ as se}from"./LTt4gKt9.js";import{u as ie}from"./D3KsAgN3.js";const ue=y({name:"EditablePage",__name:"EditablePage",props:{content:{},config:{},templateAnnotations:{},magnoliaContext:{}},setup(v){const t=v,s=w({}),g=w(),e=w(),c=w();W(()=>{var n,o;c.value=t.magnoliaContext;const l=JSON.parse(((o=(n=t.magnoliaContext)==null?void 0:n.searchParams)==null?void 0:o.selectedComponentVariants)||"{}"),{content:m,templateAnnotations:p}=z.getRenderContent(t.content,t.templateAnnotations,l);e.value=m,p&&(g.value=p)}),k("templateAnnotations",g),k("config",t.config),k("magnoliaContext",c);const C=()=>{var n,o;return e.value&&g.value&&g.value[(n=e.value)==null?void 0:n["@path"]]?g.value[(o=e.value)==null?void 0:o["@path"]]:""};q(()=>{var n;(n=t.magnoliaContext)!=null&&n.isMagnoliaEdit&&(S.initialVariantsHandler(s.value,t.config.useHistoryPushState),S.init(s.value))});const _=n=>{var o,l;return e.value?X.mgnlRender(e.value,n,(o=t.config)==null?void 0:o.componentMappings,(l=t.config)==null?void 0:l.fallbackComponent):null},f=A(()=>C());return(n,o)=>{var l;return d(),x(L,null,[f.value?(d(),b(i(D),{key:0,annotation:f.value,"always-render":(l=t.magnoliaContext)==null?void 0:l.isMagnolia,"should-run-on-frame-ready":!0},null,8,["annotation","always-render"])):Q("",!0),(d(),b(_,T({key:i(U).buildKey(e.value)},n.$attrs),null,16))],64)}}}),de={class:"mx-auto my-10 animate-pulse text-neutral-900 md:max-w-screen-md lg:max-w-screen-lg xl:max-w-screen-xl mobile:m-3"},ge={class:"flex gap-4 shadow-2xl"},me=y({__name:"Magnolia",setup(v){const t=I(),{$flags:s}=B();return(g,e)=>(d(),x("div",de,[e[10]||(e[10]=J('<div class="mb-10 flex h-[500px] w-full rounded-lg shadow-2xl mobile:flex-col-reverse"><div class="mt-auto w-full p-6"><div class="relative mb-10 h-full min-h-10 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:mb-6 mobile:h-2"></div><div class="relative mb-10 h-full min-h-10 w-3/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:mb-6 mobile:h-2"></div><div class="relative mb-10 h-full min-h-10 w-3/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:mb-6 mobile:h-2"></div></div><div class="relative size-full min-h-14 rounded-lg bg-gray-200"></div></div>',1)),r("div",ge,[e[8]||(e[8]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-1/2"},null,-1)),e[9]||(e[9]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-1/2"},null,-1)),i(s).has("sr-5497")&&!i(t).isMobile?(d(),x(L,{key:0},[e[0]||(e[0]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-0"},null,-1)),e[1]||(e[1]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-0"},null,-1)),e[2]||(e[2]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-0"},null,-1)),e[3]||(e[3]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:w-0"},null,-1))],64)):(d(),x(L,{key:1},[e[4]||(e[4]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:hidden mobile:w-0"},null,-1)),e[5]||(e[5]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:hidden mobile:w-0"},null,-1)),e[6]||(e[6]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:hidden mobile:w-0"},null,-1)),e[7]||(e[7]=r("div",{class:"relative mb-10 h-full min-h-72 w-2/5 rounded-lg border border-neutral-100 bg-gray-200 mobile:hidden mobile:w-0"},null,-1))],64))])]))}}),be=Object.assign(me,{__name:"KikSkeletonMagnolia"}),ve=y({__name:"PageLoader",setup(v){const{removeAtAttributesRecursivelyFromObject:t}=se(),s=Z(),g=s.fullPath,{$domain:e,$config:c}=B(),{fetchContent:C,fetchTemplateAnnotations:_,templateAnnotations:f,content:n,error:o}=G(`page-loader-${s.path}`),{setHrefLangForMagnolia:l}=ie(),{setContentPageInfo:m}=Y(),{atMagnoliaEditor:p,atMagnolia:R}=ee(),{onSSR:N}
1=re(),{appBase:V}=ne(),{mgnlAppLanguages:$}=c.public,j=A(()=>R.value?n.value:t(n.value,["path","@path","variantpath"],["image","switchable"])),F=a=>a.startsWith("/")?a.substr(1):a,E=()=>`/${F(s.path)}`;function H(a,h){const u=h.split(" ");if(!u.length)throw new Error("No language provided. Please make sure to add locales.");return u.find(P=>new RegExp(`/${P}($|/i)`).test(a))||u[0]}const K=ae.getMagnoliaContext(g,V,[$]),O=a=>{const h=$.split(" "),u=H(a,$),P=(e.cmsContentRootPath??`/${e.countryCode}/Home`).replace(/^\/+/,"");a=a.replace(new RegExp(`/${P}($|/)`),"/"),u!==h[0]&&(a=a.replace(new RegExp(`/${u}($|/)`),"/"),a+=`?lang=${u}`);const{mgnlVersion:M}=s.query;return M&&(a+=a.includes("?")?`&version=${M}`:`?version=${M}`),p.value&&(a+=a.includes("?")?"&variants=all":"?variants=all"),a.startsWith("/")?a:`/${a}`};return N(async()=>{if(!o.value.content&&n.value){m(n),l(n.value.hrefLang);return}R.value&&await _(E());const a=O(E());await C(a),o.value.content&&te({statusCode:404}),m(n),l(n.value?.hrefLang)}),oe(n,()=>{n.value&&(m(n),l(n.value?.hrefLang))}),(a,h)=>{const u=be;return i(j)?(d(),b(i(ue),{key:0,content:i(j),config:i(le),"template-annotations":i(f),"magnolia-context":i(K)},null,8,["content","config","template-annotations","magnolia-context"])):(d(),b(u,{key:1}))}}}),ce=Object.assign(ve,{__name:"SharedMagnoliaPageLoader"}),he=y({__name:"[id]",setup(v){return(t,s)=>(d(),b(ce))}});export{he 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.