1import{M as U,a1 as O,b as j,ae as H,y as K,N as Y,a6 as G,w as J,O as Q,e as y,B as N,a2 as W,a3 as X,a4 as Z,t as ee,o,m as p,E as x,K as te,g as e,p as a,R as ne,F as b,P as ae,f as k,i as se,q as oe,T as S,j as h,d as re}from"./BuZANQZ7.js";import{_ as le}from"./DlDxgDhX.js";import{_ as ie}from"./A3ZKKNgk.js";import{_ as ce}from"./Bfm5Hv4O.js";import{_ as ue}from"./BUXerP9h.js";import{u as de}from"./D4k_6HrB.js";import{u as me}from"./B1gmW7CS.js";import"./DYsrpntp.js";import"./_uQQanzb.js";import"./CtziVm_B.js";import"./DCntQkRz.js";import"./BkNONDKj.js";import"./CjKDI5UW.js";import"./ByU2Ce1T.js";(function(){try{var r=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};r.SENTRY_RELEASE={id:"cf3e31ebcff8732c213d6eed7ed4ef2a1c0ee0ba"};var c=new r.Error().stack;c&&(r._sentryDebugIds=r._sentryDebugIds||{},r._sentryDebugIds[c]="eeb5502a-480d-4953-83fd-a0018f46e7e8",r._sentryDebugIdIdentifier="sentry-dbid-eeb5502a-480d-4953-83fd-a0018f46e7e8")}catch{}})();const pe={class:"magnetic-container"},ve={class:"magnetic-inner flex gap-1 items-center mb-2"},fe={class:"flex-1"},_e={class:"text-center"},C="current",De=U({__name:"index",async setup(r){let c,g;const{t:n}=O(),{events:s,fetchEvents:l}=de(),{place:v,range:D}=j(),{keyword:A}=me(),{refreshSignal:L}=H(),E=K(),R=Y(),$=G(),u=S(1),i=S(!1),t=h({get(){return R.query.tab||C},set(d){$.push({query:{tab:d!==C?d:void 0}})}}),q=h(()=>s.value?.paginator.end?!1:(s.value?.paginator.pages||100)>u.value),z=h(()=>"events-"+t.value);[c,g]=J(()=>re(z,()=>l({calendar:t.value}),{lazy:!0})),await c,g(),Q({title:n("event.title"),ogTitle:n("event.title"),description:n("event.description"),ogDescription:n("event.description")}),y(L,async()=>{u.value=1,i.value=!0,await l({calendar:t.value}),requestAnimationFrame(()=>requestAnimationFrame(()=>i.value=!1))}),y(A,async()=>{await l({calendar:t.value})}),y(D,async()=>{await l({calendar:t.value})}),y(v,async()=>{if(!v.value){await l({calendar:t.value});return}v.value?.city?await N(E.linkTo("event-slug",{slug:v.value?.city.slug})):await N(E.linkTo("event-nearby"))});const{logView:T}=W(),B=()=>{s.value?.paginator.end||(u.value++,i.value=!0,l({calendar:t.value},u.value).then(()=>i.value=!1),T("events-default","page"+u.value))},I=X("sentinel");return Z(I,async([d])=>{d?.isIntersecting&&(i.value||B())},{rootMargin:"800px"}),ee(async()=>{T("events-default")}),(d,f)=>{const w=ne,F=le,M=ie,V=ce,P=ue,m=oe;return o(),p("section",pe,[x("div",ve,[x("h1",fe,te(e(n)("event.title")),1),a(w,{active:e(t)==="current",label:e(n)("event.calendar.current"),color:"neutral",variant:"outline","active-color":"primary","active-variant":"solid",size:"sm",onClick:f[0]||(f[0]=_=>t.value="current")},null,8,["active","label"]),a(w,{active:e(t)==="history",label:e(n)("event.calendar.history"),color:"neutral",variant:"outline","active-color":"primary","active-variant":"solid",size:"sm",onClick:f[1]||(f[1]=_=>t.value="history")},null,8,["active","label"])]),a(F),e(s)?(o(),p(b,{key:0},[a(M,{expanded:e(s).expanded},null,8,["expanded"]),e(s).items&&e(s).items.length>0?(o(),p(b,{key:0},[(o(!0),p(b,null,ae(e(s).items,_=>(o(),k(V,{key:_.id,evt:_},null,8,["evt"]))),128)),x("div",_e,[e(q)?(o(),k(w,{key:0,ref_key:"sentinel",ref:I,label:e(n)("button.loadNext"),icon:"i-lucide-arrow-down",size:"xs",onClick:B,disabled:e(i)},null,8,["label","disabled"])):se("",!0)])],64)):(o(),k(P,{key:1,title:e(n)("event.empty.title"),description:e(n)("event.empty.description"),icon:"material-symbols-light:calendar-clock-outline",variant:"subtle"},null,8,["title","description"]))],64)):(o(),p(b,{key:1},[a(m,{class:"p-3 mb-3 w-full aspect-375/238 sm:aspect-736/374 bg-accented/30 rounded-none md:rounded-xl"}),a(m,{class:"p-3 mb-3 w-full aspect-375/238 sm:aspect-736/374 bg-accented/30 rounded-none md:rounded-xl"}),a(m,{class:"p-3 mb-3 w-full aspect-375/238 sm:aspect-736/374 bg-accented/30 rounded-none md:rounded-xl"}),a(m,{class:"p-3 mb-3 w-full aspect-375/238 sm:aspect-736/374 bg-accented/30 rounded-none md:rounded-xl"}
1),a(m,{class:"p-3 mb-3 w-full aspect-375/238 sm:aspect-736/374 bg-accented/30 rounded-none md:rounded-xl"})],64))])}}});export{De 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.