1import{_ as j}from"./BLRUKKk8.js";import{d as S,a as T,m as I,r as V,c as x,o as f,f as _,g as B,y as F,v as a,C as P,I as R,h as C,x as N,J as A,H as D,w as q,q as Q,Q as M,F as Z,B as J,i as O}from"./tP_neK1T.js";import{s as U}from"./DjxsCAPF.js";import{_ as W}from"./CoKr0kUD.js";import{h as H}from"./C5S46NFB.js";import{u as X}from"./B6_m7RZ8.js";const G="data:image/svg+xml,%3csvg%20width='43'%20height='42'%20viewBox='0%200%2043%2042'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M21.5%200C15.9305%200%2010.589%202.21249%206.65076%206.15076C2.71249%2010.089%200.5%2015.4305%200.5%2021C0.5%2026.5695%202.71249%2031.911%206.65076%2035.8492C10.589%2039.7875%2015.9305%2042%2021.5%2042C27.0695%2042%2032.411%2039.7875%2036.3492%2035.8492C40.2875%2031.911%2042.5%2026.5695%2042.5%2021C42.5%2015.4305%2040.2875%2010.089%2036.3492%206.15076C32.411%202.21249%2027.0695%200%2021.5%200ZM34%2023.5H24V33.5H19V23.5H9V18.5H19V8.5H24V18.5H34V23.5Z'%20fill='white'/%3e%3c/svg%3e",K={class:"w-full max-w-[73.375rem]"},ee={class:"aspect-w-9 lg:aspect-w-16 aspect-h-9"},te={key:1,src:W,class:"h-full w-full object-contain bg-blue-midnight"},ne={class:"space-y-2.5"},se=["innerHTML"],oe={class:"text-sm leading-5 lg:text-lg lg:leading-7 font-normal"},ae=S({__name:"RecentItem",props:["event"],setup(r){T();const d=s=>{try{const e=new Date(s),l=e.getDate().toString().padStart(2,"0"),p=(e.getMonth()+1).toString().padStart(2,"0"),m=e.getFullYear();return`${l}/${p}/${m}`}catch{return""}},{page:v}=I("page",{page:V({})}),h=x(()=>{var s,e,l;return((l=(e=(s=v.value)==null?void 0:s.acf)==null?void 0:e.page_defaults)==null?void 0:l.color_theme)==="invest"});return(s,e)=>{const l=j,p=A;return f(),_("div",K,[B(p,{to:r.event.link,class:"w-full block overflow-hidden rounded-2.5xl inner"},{default:F(()=>[a("div",ee,[r.event.featured_media?(f(),P(l,{key:0,image:r.event.featured_media,"img-class":"object-cover h-full w-full",mode:"contain"},null,8,["image"])):(f(),_("img",te)),a("div",{class:R(["px-2.5 lg:px-7.5 py-2.5 text-white text-lg leading-7 font-bold absolute !top-[unset] bottom-0 left-0 flex justify-between gap-2.5 h-auto",{"bg-orange-bright":C(h),gradient:!C(h)}])},[a("div",ne,[a("div",{class:"text-base leading-6 lg:text-2xl lg:leading-8 font-bold",innerHTML:("sanitizeTitle"in s?s.sanitizeTitle:C(U))(r.event.title.rendered)},null,8,se),a("div",oe,N(d(r.event.acf.date_from)),1)]),e[0]||(e[0]=a("img",{src:G,class:"w-[1.875rem] lg:w-[2.625rem]"},null,-1))],2)])]),_:1},8,["to"])])}}}),le=D(ae,[["__scopeId","data-v-14955234"]]),ie={class:"w-full relative recent-container"},re=S({__name:"Recent",props:["industry"],async setup(r){let d,v;const h=r,s=T(),e=O(),l=x(()=>`${e.public.apiBase}/wp-json/wp/v2/events/`),p=x(()=>({per_page:16,lang:s.locale.value,"_fields[]":["title","slug","link","featured_media","acf.date_from"],acf_format:"standard",date_from:H().add(3,"days").format("YYYY-MM-DD"),date_to:H().add(3,"months").format("YYYY-MM-DD"),"event-sector":h.industry??void 0})),{data:m,pending:ce,error:de,refresh:ue}=([d,v]=q(()=>X(l,{query:p,onResponse({response:t}){}},"$paX4cF6bsf")),d=await d,v(),d),L=x(()=>(m.value??[]).slice().reverse()),c=V(),Y=()=>{c.value.swiper.slideNext()},$=()=>{c.value.swiper.slidePrev()};Q(()=>{if(c.value){c.value.disconnectedCallback();const t={pagination:{clickable:!0,renderBullet:function(n,o){return n>=m.value.length?"":'<span class="'+o+'"/></span>'}},effect:"coverflow",coverflowEffect:{rotate:0,stretch:0,slideShadows:!1,depth:0},centeredSlides:!0,slidesPerView:1,slidesPerGroup:1,spaceBetween:80,grabCursor:!0,loop:!0,loopAddBlankSlides:!1,breakpoints:{1024:{slidesPerView:1.5,coverflowEffect:{depth:100}}},on:{init:n=>{y(n)},resize:n=>{y(n)}}};Object.assign(c.value,t),c.value.initialize()}});function y(t,n=()=>{}){const o=m.value.length,i=1,u=t.slides.length,g=o+i;(u<g||u%i!==0)&&z(t,g,i,n)}function z(t,n,o,i=()=>{}){const u=t.slides.length;let g=n-u;u%o!==0&&(g+=o-u%o);const k=document.createDocumentFragment(),E=t.slides.map(w=>w.outerHTML).join("");for(let w=0;w<g;w++){const b=document.createElement("div");for(b.innerHTML=E;b.firstChild;)k.appendChild(b.firstChild)}
1t.hostEl.appendChild(k),t.update(),i()}return(t,n)=>{const o=le;return f(),_("div",ie,[a("a",{href:"#",onClick:M($,["prevent"]),class:"absolute top-0 left-0 h-full go-to-prev z-10"}),a("swiper-container",{ref_key:"swiper",ref:c,pagination:"true",init:"false"},[(f(!0),_(Z,null,J(C(L),i=>(f(),_("swiper-slide",{key:i.slug,class:"max-lg:px-5"},[B(o,{event:i,class:"mx-auto"},null,8,["event"])]))),128))],512),a("a",{href:"#",onClick:M(Y,["prevent"]),class:"absolute top-0 right-0 h-full go-to-next z-10"})])}}}),he=D(re,[["__scopeId","data-v-929a5783"]]);export{he as _};
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.