PageSourceSearch

https://xterraplanet.com/_nuxt/BTqJf_2q.js

js xterraplanet.com collected 2026-09-24 20:08:26 UTC 30,987 bytes, 1 lines download raw bytes

1import{_ as oe}from"./PzznnjGT.js";import{_ as le}from"./DxlhZG8R.js";import{T as O}from"./DWwGGDMq.js";import{S as ie}from"./BUTF0EtD.js";import{C as N,G as C,D as i,H,E as F,d as E,o as t,c as o,b as n,F as M,r as R,n as P,t as y,g as T,f as r,l as c,z as G,h as L,i as z,k as $,w as j,_ as ae,ak as ce,A as q,e as B,S as X,N as re,m as ue,U as de,Q as he,j as me,I as fe,J as ge,Z as _e,K as be,s as pe,x as xe,y as ve}from"./D-lTpltH.js";import{s as J}from"./Ba6rcGiV.js";import{_ as ye}from"./BYlV5qwl.js";import{_ as K}from"./lnCE4Z2x.js";import{a as ke,_ as we}from"./DjJePBtp.js";import{_ as $e}from"./COO2SGc5.js";import{_ as Ce,a as Se}from"./DQtnpGr2.js";import{_ as Q}from"./Dtwww8XU.js";import{_ as Te}from"./DlAUqK2U.js";import{_ as Ee}from"./CVnkEXoZ.js";import{d as Le}from"./BF4Cdv7I.js";import{d as Ae}from"./9Sj_QenJ.js";import{g as Me}from"./CgZKYZWZ.js";import{u as Re}from"./DKPk7vEH.js";import{c as Ge}from"./CoD-DTFI.js";const Ne=N({person_name:i().nullable().optional(),person_title:i().nullable().optional(),advertisement_url:i().nullable().optional(),sponsor_level:C({coerce:!0}).optional()}),Ie=N({id:C(),uuid:i(),position:C(),times:i(),activity:O,location:O.nullable(),map_link:i().nullable()}),je=N({id:C(),uuid:i(),date:i(),date_pretty:i(),day_name:i(),entries:H(Ie).nullable().optional()}),Pe=N({id:C(),uuid:i(),name:i(),gpx:i().nullable(),geo_json:i().nullable(),distance:C().nullable(),elevation_up:C().nullable(),elevation_down:C().nullable(),created_at:i(),updated_at:i()}),He=N({uuid:i(),name:O,intro:O.nullable(),description:O.nullable(),map_embed:i().nullable(),preview_video:i().nullable(),image:i().nullable(),gpx:i().nullable(),geo_json:i().nullable(),type:N({key:C().nullable(),value:i().nullable()}).nullable(),thumbnail:i().nullable(),track_distance:C().nullable(),track_elevation_up:C().nullable(),track_elevation_down:C().nullable(),track:Pe.nullable().optional()}),Y=N({id:C(),uuid:i(),name:i(),title:i().nullable(),specialities:i().nullable(),bio:i().nullable(),facebook:i().nullable(),instagram:i().nullable(),email:i().nullable(),phone:i().nullable(),location:i().nullable(),image:i().nullable(),website:i().nullable()}),Oe=N({id:C(),uuid:i(),title:i(),discipline:i().nullable(),date:i().nullable(),date_display:i().nullable(),start_time:i().nullable(),end_time:i().nullable(),time_display:i().nullable(),location:i().nullable(),description:i().nullable(),coaches:H(Y),map_link:i().nullable()}),De=N({id:C(),uuid:i(),title:i().nullable(),content:i().nullable(),position:C(),include_in_toc:F(),type:i(),person_image:i().nullable(),advertisement_image:i().nullable(),extra_info:Ne.nullable(),schedule:je.nullable().optional(),course:He.nullable().optional(),hide_title:F(),clinics:H(Oe).nullable().optional(),coaches:H(Y).nullable().optional()}),ze=N({id:C(),uuid:i(),title:i(),contents_summary:i().nullable(),type:i(),position:C(),slug:i(),sections:H(De).nullable().optional()}),Ve=N({uuid:i(),slug:i(),sponsors:ie.array().optional()}),Be=N({uuid:i(),title:i(),overview:i().nullable(),description:i().nullable(),slug:i(),is_published:F(),banner_image:i().nullable(),ss_image:i().nullable(),event:Ve.nullable(),chapters:H(ze).nullable().optional()});var A=(e=>(e.GENERAL="general",e.COURSE="course",e.SCHEDULE="schedule",e.PERSONAL="personal",e.ADVERT="advertisement",e.SPONSORS="sponsor",e.CLINIC="clinic",e))(A||{});const Ue={class:""},Fe={class:"flex flex-col gap-2 h-full overflow-y-auto"},Je=["onClick"],Ke={class:"font-display text-neutral-900"},We={class:"flex flex-col gap-1 overflow-y-auto pr-1"},qe=["onClick"],Xe=["onClick"],Qe=E({__name:"SinglePageTableOfContent",props:{chapters:{},chapterInView:{}},emits:["tocSectionClicked"],setup(e,{emit:a}){const l=a,h=G(()=>(e.chapters??[]).map(s=>({uuid:s.uuid,title:s.title,sections:(s.sections??[]).filter(d=>d.include_in_toc&&d.type!==A.PERSONAL)})).filter(s=>s.title||s.sections.length>0)),u=L(null),b=s=>{u.value=u.value===s?null:s},f=s=>{J(s),l("tocSectionClicked")},m=s=>{J(s),l("tocSectionClicked")};return(s,d)=>{const v=le;return t(),o("div",Ue,[d[0]||(d[0]=n("p",{class:"font-display font-black uppercase italic underline decoration-xt-gold text-lg"}," Table of Contents ",-1)),n("div",Fe,[(t(!0),o(M,null,R(r(h),g=>(t(),o("div",{key:g.uuid,class:"rounded-lg"},[n("button",{type:"button",class:P(["flex w-full items-center justify-between rounded-md px-2 py-2 text-left hover:bg-neutral-100",{"bg-blue-100":e.chapterInView===g.uuid}]),onClick:_=>b(g.uuid)}
1,[n("span",Ke,y(g.title),1),T(v,{class:P(["size-4 transition-transform duration-200",{"rotate-180":r(u)===g.uuid}])},null,8,["class"])],10,Je),n("div",{class:P(["grid ml-4 mt-1 transition-all duration-300 ease-in-out",{"grid-rows-[1fr]":r(u)===g.uuid||e.chapterInView===g.uuid,"grid-rows-[0fr]":r(u)!==g.uuid&&e.chapterInView!==g.uuid}])},[n("div",We,[g.sections.length?c("",!0):(t(),o("button",{key:0,type:"button",class:"rounded-md px-2 py-1 text-left text-sm text-neutral-600 hover:bg-neutral-100 hover:text-neutral-900",onClick:_=>m(g.uuid)}," See chapter ",8,qe)),(t(!0),o(M,null,R(g.sections,_=>(t(),o("button",{key:_.uuid,type:"button",class:"rounded-md px-2 py-1 text-left text-sm text-neutral-600 hover:bg-neutral-100 hover:text-neutral-900",onClick:k=>f(_.uuid)},y(_.title),9,Xe))),128))])],2)]))),128))])])}}}),Ye=["innerHTML"],Ze={key:1,class:"text-sm text-gray-500"},et=E({__name:"GeneralSection",props:{section:{}},setup(e){return(a,l)=>(t(),o("div",null,[e.section.content?.length?(t(),o("div",{key:0,class:"athlete-guide-content",innerHTML:e.section.content},null,8,Ye)):c("",!0),e.section.content?.length?c("",!0):(t(),o("p",Ze," No content is provided for now. "))]))}}),tt=["innerHTML"],nt={key:1,class:"text-sm text-gray-500"},st={key:2,class:"flex mt-4 gap-6 items-center"},ot={class:"text-sm"},lt={class:"mb-2 font-display text-lg"},it={class:"italic"},at=E({__name:"PersonalSection",props:{section:{}},setup(e){const a=l=>l.extra_info?.person_name?.length||l.extra_info?.person_title?.length||l.person_image?.length;return(l,h)=>{const u=K;return t(),o("div",null,[e.section.content?.length?(t(),o("div",{key:0,class:"athlete-guide-content max-w-3xl",innerHTML:e.section.content},null,8,tt)):c("",!0),e.section.content?.length?c("",!0):(t(),o("p",nt," No content is provided for now. ")),a(e.section)?(t(),o("div",st,[T(u,{placeholder:"/images/placeholder.svg",class:"w-36 object-cover rounded-md",src:e.section.person_image||""},null,8,["src"]),n("div",ot,[n("p",lt,y(e.section.extra_info?.person_name),1),n("p",it,y(e.section.extra_info?.person_title),1)])])):c("",!0),h[0]||(h[0]=n("hr",{class:"mt-6 max-w-3xl"},null,-1))])}}}),ct={class:"w-full lg:w-2/12 font-display font-bold lg:font-normal pr-4 whitespace-nowrap"},rt={class:"w-full lg:w-5/12 pl-4 lg:pl-0"},ut={class:"w-full lg:w-5/12 pl-4 lg:pl-6"},dt={class:"lg:text-sm text-gray-500 italic lg:not-italic"},ht={key:0,class:"mt-4 text-gray-500 text-sm italic"},mt=E({__name:"ScheduleSection",props:{entries:{}},setup(e){return(a,l)=>{const h=ae;return t(),o("div",null,[n("div",null,[l[1]||(l[1]=n("div",{class:"hidden lg:flex bg-black text-white font-display px-2 py-2"},[n("span",{class:"w-2/12 pr-4"},"Time"),n("span",{class:"w-5/12"},"Activity"),n("span",{class:"w-5/12 pl-6"},"Location")],-1)),n("div",null,[(t(!0),o(M,null,R(e.entries,u=>(t(),o("div",{key:u.uuid,class:"flex flex-col lg:flex-row px-2 py-2 mb-2 lg:mb-0 lg:border-x lg:border-b border-gray-200"},[n("span",ct,y(u.times),1),n("span",rt,y(u.activity?.en),1),n("div",ut,[n("span",dt,[z(y(u.location?.en)+" ",1),u.map_link?(t(),$(h,{key:0,to:u.map_link,target:"_blank",class:"text-xt-lightblue lg:text-blue-400 lg:hover:underline not-italic"},{default:j(()=>[...l[0]||(l[0]=[z(" (map) ",-1)])]),_:1},8,["to"])):c("",!0)])])]))),128))])]),e.entries?.length?c("",!0):(t(),o("p",ht," No schedule is provided for this day. "))])}}});async function ft(e){if(!e)throw new Error("no geojson file url provided");const a=await fetch(e);if(!a.ok)throw new Error(`Failed to fetch GeoJSON (${a.status})`);return await a.json()}function gt(e){const l=V(e)[0];if(!l)throw new Error("GeoJSON has no coordinates");return[l[1],l[0]]}function _t(e){const a=V(e),l=a[a.length-1];if(!l)throw new Error("GeoJSON has no coordinates");return[l[1],l[0]]}function bt(e,a){return e[0]===a[0]&&e[1]===a[1]}function V(e){return e?e.type==="FeatureCollection"?e.features.flatMap(a=>V(a)):e.type==="Feature"?V(e.geometry):e.type==="LineString"?e.coordinates:e.type==="MultiLineString"?e.coordinates.flat():[]:[]}function pt(){const e=(s,d,v,g)=>{const _=a(d,s.leaflet);l(_,s.mapTiler);const k=h(v,_,s.leaflet);u(k,_),b(_),f(_,g,k,s.leaflet),m(v,_,s.leaflet)},a=(s,d)=>s?d.map(s):null,l=(s,d)=>
1{if(!s||!d)return null;d.maptilerLayer({apiKey:ce().public.maptilerKey||"",style:"019bb060-a5fa-7b8d-95fa-fcb588e684b4"}).addTo(s)},h=(s,d,v)=>d?v.geoJSON(s,{style:{color:"#333333",weight:4}}).addTo(d):null,u=(s,d)=>{!s||!d||d.fitBounds(s.getBounds())},b=s=>{s&&s?.attributionControl?.remove()},f=(s,d,v,g)=>{if(!v||!s)return;const _=g.Control.extend({onAdd(){const k=g.DomUtil.create("div","leaflet-bar leaflet-control-zoom"),p=g.DomUtil.create("button","",k);p.type="button",p.style.width="30px",p.style.height="32px",p.style.padding="3px",p.style.display="flex",p.style.justifyContent="center",p.style.alignItems="center",p.style.background="#fff",p.innerHTML=d;const w=()=>{p.style.background="#F4F4F4"},x=()=>{p.style.background="#fff"},S=()=>{s.fitBounds(v.getBounds())};return p.addEventListener("mouseenter",w),p.addEventListener("mouseleave",x),g.DomEvent.on(p,"click",S),this._button=p,this._onMouseEnter=w,this._onMouseLeave=x,this._onClick=S,k},onRemove(){const k=this._button;k&&(k.removeEventListener("mouseenter",this._onMouseEnter),k.removeEventListener("mouseleave",this._onMouseLeave),g.DomEvent.off(k,"click",this._onClick),delete this._button,delete this._onMouseEnter,delete this._onMouseLeave,delete this._onClick)}});new _({position:"topleft"}).addTo(s)},m=(s,d,v)=>{if(!d)return;const g=gt(s),_=_t(s);if(bt(g,_)){v.marker(g,{title:"Start & End"}).addTo(d).bindPopup("Start & End");return}v.marker(g,{title:"Start"}).addTo(d).bindPopup("Start"),v.marker(_,{title:"End"}).addTo(d).bindPopup("End")};return{initMap:e}}const xt={class:"h-36 w-full flex items-center justify-center bg-slate-100 rounded-lg"},vt={key:0},yt=E({__name:"GeoJsonViewer",props:{geoJson:{}},setup(e){const a=e,{$loadLeaflet:l,$leafletLoaded:h}=q(),{initMap:u}=pt(),b=L(null),f=L(null);return B(async()=>{const m=await l(),s=f.value?.firstElementChild instanceof Element?f.value.firstElementChild.outerHTML:"";u(m,b.value,a.geoJson,s)}),(m,s)=>(t(),o("div",null,[n("div",xt,[r(h)?c("",!0):(t(),o("div",vt,"Maps are not loaded")),s[0]||(s[0]=n("span",{class:"text-sm"},"GeoJson map is not supported yet.",-1))])]))}}),kt={class:"my-8"},wt=["src"],$t=E({__name:"GpxViewer",props:{map:{}},setup(e){return(a,l)=>(t(),o("div",kt,[n("iframe",{src:e.map,width:"100%",height:"600",frameborder:"0",style:{border:"1px solid #ccc"},title:"GPX Viewer"},null,8,wt)]))}});function Ct(e){const a=L(null);async function l(){e?.value?.track?.geo_json&&(a.value=await ft(e.value.track.geo_json))}return e?.value?.track?.geo_json&&l(),X(()=>e.value,h=>{h&&l()}),B(()=>{e.value&&l()}),{geoJson:a}}const St={class:"mb-8"},Tt={key:2},Et=["src"],Lt={key:3},At={class:"flex mb-6 -mt-3"},Mt=["href","download"],Rt=["innerHTML"],Gt={key:1,class:"text-sm text-gray-500"},Nt=E({__name:"CourseSection",props:{section:{}},setup(e){const a=e,l=G(()=>a.section.course||null),h=G(()=>l.value?.track?.geo_json?"geojson":l.value?.map_embed?"map":l.value?.image?"image":"none"),{geoJson:u}=Ct(l),b=G(()=>a.section.course?.gpx?`${(a.section.course.name?.en||"XTERRA Course").toLowerCase().replaceAll(" ","_")}.gpx`:"");return(f,m)=>{const s=yt,d=$t;return t(),o("div",null,[n("div",St,[r(u)&&r(h)==="geojson"?(t(),$(s,{key:0,"geo-json":r(u)},null,8,["geo-json"])):c("",!0),e.section.course?.map_embed&&r(h)==="map"?(t(),$(d,{key:1,map:e.section.course?.map_embed},null,8,["map"])):c("",!0),e.section.course?.image&&r(h)==="image"?(t(),o("div",Tt,[n("img",{src:e.section.course?.image},null,8,Et)])):c("",!0),r(h)==="none"?(t(),o("div",Lt,[...m[0]||(m[0]=[n("p",{class:"text-sm text-gray-500 my-4"}," The attached course has no usable map or image. ",-1)])])):c("",!0)]),n("div",At,[e.section.course?.gpx?(t(),o("a",{key:0,href:e.section.course.gpx,download:r(b),class:"bg-black px-3 py-1 rounded-full font-display text-sm border border-black text-white hover:bg-white hover:text-black",target:"_blank"}," Download GPX ",8,Mt)):c("",!0)]),e.section.content?.length?(t(),o("div",{key:0,class:"athlete-guide-content",innerHTML:e.section.content},null,8,Rt)):c("",!0),e.section.content?.length?c("",!0):(t(),o("p",Gt," No content is provided for now. "))])}}}),It={key:0},jt=["href"],Pt=["src"],Ht=E({__name:"AdvertSection",props:{section:{}},setup(e){const a=G(()=>!!e.section.advertisement_image);return(l,h)=>r(a)?(t(),o("div",It,[n("a",{target:"_blank",noreferrer:"",nofollow:"",href:e.section.extra_info?.advertisement_url||""},[n("img",{src:e.section.advertisement_image||"",alt:"",class:"w-full"},null,8,Pt)],8,jt)])):c("",!0)}}),Ot={class:"my-8"},Dt={class:"text-lg uppercase italic font-display"},zt={class:"w-full aspect-video"},Vt=["src"],Bt={class:"text-center font-display wg-ignore"},Ut={key:1,class:"my-6 text-center text-gray-500"},Ft=["innerHTML"],Jt=E({__name:"SponsorSection",props:{section:{},sponsors:{}},setup(e){const a=G(()=>e.section.extra_info?.sponsor_level?e.sponsors?.filter(h=>(h.level||99)<=(e.section.extra_info?.sponsor_level||0))||[]:[]),l=h=>h===1?"grid-cols-2 md:grid-cols-3":h===2?"grid-cols-2 md:grid-cols-4":"grid-cols-2 md:grid-cols-5";return(h,u)=>(t(),o("div",null,[r(a).length>1?(t(!0),o(M,{key:0},R(r(a),b=>
1(t(),o("div",Ot,[n("p",Dt,y(b.title),1),n("div",{class:P(["grid grid-cols-3 gap-8",l(b.level||99)])},[(t(!0),o(M,null,R(b.sponsors,f=>(t(),o("div",zt,[(t(),$(re(f.link?"a":"span"),{href:f.link||"",target:"_blank"},{default:j(()=>[n("img",{class:"w-full h-full object-contain",src:f.image||""},null,8,Vt)]),_:2},1032,["href"])),n("p",Bt,y(f.name),1)]))),256))],2)]))),256)):c("",!0),r(a).length<1?(t(),o("p",Ut," No Sponsor is provided. ")):c("",!0),e.section.content?.length?(t(),o("div",{key:2,class:"athlete-guide-content",innerHTML:e.section.content},null,8,Ft)):c("",!0)]))}}),Kt=["id"],Wt={class:"border-b mb-4 pb-4"},qt={key:0,class:"text-sm font-display"},Xt={class:"font-display font-bold text-lg mb-1"},Qt={class:"text-xs text-gray-500"},Yt={key:0},Zt={key:1},en={key:2},tn=["href"],nn={key:0},sn={key:0,class:"text-sm text-gray-700 leading-relaxed mt-4"},on={key:1,class:"mt-6"},ln={class:"flex flex-wrap gap-8"},an=["onClick"],cn={key:1,class:"size-14 rounded-md bg-gray-100 shrink-0 flex items-center justify-center"},rn={class:"font-display text-sm group-hover:text-xt-red whitespace-nowrap"},un=E({__name:"Card",props:{clinic:{}},setup(e){return(a,l)=>{const h=K;return t(),o("div",{id:`clinic-${e.clinic.uuid}`,class:"border rounded-xl p-6 mb-6 scroll-mt-20 w-fit"},[n("div",Wt,[e.clinic.time_display?(t(),o("span",qt,y(e.clinic.time_display),1)):c("",!0),n("p",Xt,y(e.clinic.title),1),n("div",Qt,[e.clinic.discipline?(t(),o("span",Yt,y(e.clinic.discipline),1)):c("",!0),e.clinic.discipline&&e.clinic.location?(t(),o("span",Zt," | ")):c("",!0),e.clinic.location||e.clinic.map_link?(t(),o("span",en,[z(y(e.clinic.location)+" ",1),e.clinic.map_link?(t(),o("a",{key:0,href:e.clinic.map_link,target:"_blank",class:"text-blue-400 hover:underline"}," (Map)",8,tn)):c("",!0)])):c("",!0)])]),e.clinic.description?(t(),o("div",nn,[e.clinic.description?(t(),o("p",sn,y(e.clinic.description),1)):c("",!0)])):c("",!0),e.clinic.coaches.length?(t(),o("div",on,[l[1]||(l[1]=n("p",{class:"font-display text-sm mb-3"},"Coaches",-1)),n("div",ln,[(t(!0),o(M,null,R(e.clinic.coaches,u=>(t(),o("button",{key:u.uuid,type:"button",class:"group flex items-center gap-2 text-left",onClick:b=>("smoothScroll"in a?a.smoothScroll:r(J))(`coach-${u.uuid}`)},[u.image?(t(),$(h,{key:0,src:u.image,alt:u.name,class:"size-14 rounded-md object-cover shrink-0"},null,8,["src","alt"])):c("",!0),u.image?c("",!0):(t(),o("div",cn,[...l[0]||(l[0]=[n("span",{class:"text-xs text-gray-400 text-center"}," No image ",-1)])])),n("span",rn,y(u.name),1)],8,an))),128))])])):c("",!0)],8,Kt)}}}),dn=["id"],hn={class:"mb-6 border-b"},mn={class:"font-display text-xl font-bold"},fn={key:0,class:"text-gray-500 text-sm italic mb-2"},gn={class:"flex flex-col lg:flex-row gap-6"},_n={class:"order-2 lg:order-1"},bn=["innerHTML"],pn={key:0,class:"text-sm text-gray-500 mt-1"},xn={class:"shrink-0 order-1 lg:order-2"},vn={key:1,class:"size-40 rounded-lg bg-gray-100 flex items-center justify-center"},yn={class:"mt-6 mb-4 border-t pt-6"},kn={class:"flex flex-wrap gap-4 items-center"},wn=["href"],$n=["href"],Cn=["href"],Sn=["href"],Tn=["href"],En=E({__name:"CoachCard",props:{coach:{}},setup(e){return(a,l)=>{const h=K,u=$e,b=Ce,f=Se,m=ke;return t(),o("div",{id:`coach-${e.coach.uuid}`,class:"border rounded-xl p-6 scroll-mt-20"},[n("div",hn,[n("p",mn,y(e.coach.name),1),e.coach.location?(t(),o("p",fn,y(e.coach.location),1)):c("",!0)]),n("div",gn,[n("div",_n,[n("div",{class:"wysiwyg text-gray-700",innerHTML:e.coach.bio},null,8,bn),l[0]||(l[0]=n("p",{class:"font-display text-xs uppercase italic mb-1 mt-6"}," Specialities ",-1)),e.coach.specialities?(t(),o("p",pn,y(e.coach.specialities),1)):c("",!0)]),n("div",xn,[e.coach.image?(t(),$(h,{key:0,src:e.coach.image,alt:e.coach.name,class:"size-40 rounded-lg object-cover"},null,8,["src","alt"])):c("",!0),e.coach.image?c("",!0):(t(),o("div",vn,[...l[1]||(l[1]=[n("span",{class:"text-sm text-gray-400 text-center"}," No image ",-1)])]))])]),n("div",yn,[n("div",kn,[e.coach.website?(t(),o("a",{key:0,href:e.coach.website,target:"_blank",class:"flex items-center gap-2 text-neutral-800 hover:text-black hover:underline"},[T(u,{class:"size-4 fill-black"})],8,wn)):c("",!0),e.coach.facebook?(t(),o("a",{key:1,href:e.coach.facebook,target:"_blank",class:"flex items-center gap-2 text-neutral-800 hover:text-black hover:underline"},[T(b,{class:"size-5 shrink-0"})],8,$n)):c("",!0),e.coach.instagram?(t(),o("a",{key:2,href:e.coach.instagram,target:"_blank",class:"flex items-center gap-2 text-neutral-800 hover:text-black hover:underline"},[T(f,{class:"size-5 shrink-0"})],8,Cn)):c("",!0),e.coach.email?(t(),o("a",{key:3,href:`mailto:${e.coach.email}`,class:"text-black hover:underline text-xs break-all"},y(e.coach.email),9,Sn)):c("",!0),e.coach.phone?(t(),o("a",{key:4,href:`tel:${e.coach.phone}`,class:"flex items-center text-black hover:underline text-xs"},[T(m,{class:"size-4 fill-black rotate-12 relative"}),n("span",null,y(e.coach.phone),1)],8,Tn)):c("",!0)])])],8,dn)}}}),Ln=["innerHTML"],An={key:1,class:"mt-10"},Mn={class:"space-y-6"},Rn={class:"font-display text-base font-black uppercase italic underline"},Gn={class:"mb-12"},Nn={class:"mt-10"},In={key:0,class:"space-y-6"},jn={key:1,class:"text-sm text-gray-500 italic"},Pn=E({__name:"Section",props:{section:{}},setup(e){const a=e,l=G(()=>a.section.clinics||[]),h=G(()=>{const b=(a.section.clinics||[]).reduce((f,m)=>{const s=m.date_display||"Unknown";return f[s]||(f[s]=[]),f[s].push(m),f},{});return Object.entries(b).map(([f,m])=>({date:f,clinics:m}))}),u=G(()=>a.section.coaches||[]);return(b,f)=>{const m=we,s=un,d=En;return t(),o("div",null,[e.section.content?.length?(t(),o("div",{key:0,class:"athlete-guide-content mb-8",innerHTML:e.section.content},null,8,Ln)):c("",!0),T(m,{clinics:r(l)},null,8,["clinics"]),r(l).length?(t(),o("div",An,[f[0]||(f[0]=n("p",{class:"font-display text-xl font-bold border-b mb-4 pb-1"},"Clinics",-1)),n("div",Mn,[(t(!0),o(M,null,R(r(h),v=>(t(),o("div",{key:v.date,class:"space-y-6"},[n("p",Rn,y(v.date),1),n("div",Gn,[(t(!0),o(M,null,R(v.clinics,g=>(t(),$(s,{key:g.uuid,clinic:g},null,8,["clinic"]))),128))])]))),128))])])):c("",!0),n("div",Nn,[f[1]||(f[1]=n("p",{class:"font-display text-xl font-bold border-b mb-4 pb-1"}," Meet the Coaches ",-1)),r(u).length?(t(),o("div",In,[(t(!0),o(M,null,R(r(u),v=>(t(),$(d,{key:v.uuid,coach:v},null,8,["coach"]))),128))])):c("",!0),r(u).length?c("",!0):(t(),o("p",jn," No coaches have been added. "))])])}}}),Hn={class:"xt-guide-section-wrapper max-w-3xl"},On=["data-guide-section-heading"],Dn={key:0,class:"font-display text-3xl font-bold underline decoration-xt-gold mt-8 mb-6"},zn={key:1,class:"font-display text-2xl font-bold mt-8 mb-6"},Vn=E({__name:"SectionContent",props:{section:{},sponsors:{},chapterTitle:{}},setup(e){return(a,l)=>{const h=et,u=at,b=mt,f=Nt,m=Ht,s=Jt,d=Pn;return t(),o("div",Hn,[n("span",{class:"hidden xt-guide-section-heading","data-guide-section-heading":`${e.chapterTitle} ${e.section.title?`- ${e.section.title}`:""}`},null,8,On),e.section.type!==r(A).PERSONAL&&e.section.type!==r(A).ADVERT&&e.section.include_in_toc?(t(),o("h3",Dn,y(e.section.title),1)):c("",!0),e.section.type!==r(A).PERSONAL&&e.section.type!==r(A).ADVERT&&!e.section.include_in_toc&&!e.section.hide_title?(t(),o("h3",zn,y(e.section.title),1)):c("",!0),e.section.type===r(A).GENERAL?(t(),$(h,{key:2,section:e.section},null,8,["section"])):c("",!0),e.section.type===r(A).PERSONAL?(t(),$(u,{key:3,section:e.section},null,8,["section"])):c("",!0),e.section.type===r(A).SCHEDULE&&e.section.schedule?.entries?(t(),$(b,{key:4,entries:e.section.schedule?.entries}
1,null,8,["entries"])):c("",!0),e.section.type===r(A).COURSE?(t(),$(f,{key:5,section:e.section},null,8,["section"])):c("",!0),e.section.type===r(A).ADVERT?(t(),$(m,{key:6,section:e.section},null,8,["section"])):c("",!0),e.section.type===r(A).SPONSORS?(t(),$(s,{key:7,section:e.section,sponsors:e.sponsors||[]},null,8,["section","sponsors"])):c("",!0),e.section.type===r(A).CLINIC?(t(),$(d,{key:8,section:e.section},null,8,["section"])):c("",!0)])}}}),Bn={},Un={xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"};function Fn(e,a){return t(),o("svg",Un,[...a[0]||(a[0]=[n("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25H12"},null,-1)])])}const Jn=Te(Bn,[["render",Fn]]),Kn=e=>{const a=L(""),l=L([]),h=s=>{const d=s.trim().toLowerCase();if(!e||d.length<3){l.value=[];return}const v=[],g=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);let _;for(;_=g.nextNode();){const k=_.textContent?.toLowerCase()||"";if(k.includes(d)){const p=_.parentElement,w=f(p,e);p&&v.push(u(k,w,d,p))}}l.value=v},u=(s,d,v,g)=>{const _=v.toLowerCase().trim(),p=s.toLowerCase().indexOf(_);if(p===-1)return{text:s,heading:d,extraInfo:{element:g},before:"",match:"",after:""};const w=60,x=Math.max(0,p-w),S=Math.min(s.length,p+_.length+w);return{text:s,heading:d,extraInfo:{element:g},before:s.slice(x,p),match:s.slice(p,p+_.length),after:s.slice(p+_.length,S)}},b=Le(s=>{h(s)},200);X(()=>a.value,s=>{b(s)});const f=(s,d)=>!s||!d?"":s.closest(".xt-guide-section-wrapper")?.querySelector(".xt-guide-section-heading")?.dataset.guideSectionHeading??"";return{searchQuery:a,formattedResults:l,reset:()=>{a.value="",l.value=[]}}},Wn={class:"w-[95vw] max-w-xl rounded-lg bg-white p-6 shadow-xl"},qn={class:"mb-6"},Xn={class:"border px-4 rounded-full flex justify-between items-center focus-within:ring-1 focus-within:ring-blue-500"},Qn={class:"h-[60vh] space-y-2"},Yn={key:0},Zn={key:0,class:"rounded-lg p-4 text-sm text-gray-500"},es={key:1,class:"h-full overflow-y-auto"},ts=["onClick","onMouseenter"],ns={class:"mb-2 font-display font-semibold text-gray-900"},ss={class:"text-sm leading-6 text-gray-600"},os={class:"rounded bg-yellow-700/30 px-1 font-semibold text-yellow-900"},ls=E({__name:"Search",props:{root:{}},emits:["searchResultSelected"],setup(e,{emit:a}){const l=e,h=a,{searchQuery:u,formattedResults:b,reset:f}=Kn(l.root),m=L(-1),s=L([]),d=_=>{b.value.length&&(_.key==="ArrowDown"&&(_.preventDefault(),m.value=(m.value+1)%b.value.length,v()),_.key==="ArrowUp"&&(_.preventDefault(),m.value=(m.value-1+b.value.length)%b.value.length,v()),_.key==="Enter"&&(_.preventDefault(),m.value>=0&&m.value<b.value.length&&g(b.value[m.value])))},v=()=>{const _=s.value[m.value];_&&_.scrollIntoView({block:"nearest",behavior:"smooth"})},g=_=>{h("searchResultSelected",_),f()};return(_,k)=>(t(),o("div",Wn,[n("div",qn,[k[1]||(k[1]=n("p",{class:"mb-4 font-display text-lg font-semibold text-gray-900"}," Search for Content ",-1)),n("div",Xn,[ue(n("input",{onKeydown:d,class:"flex-1 py-2 focus:outline-none focus:ring-0",type:"text","onUpdate:modelValue":k[0]||(k[0]=p=>he(u)?u.value=p:null),autofocus:""},null,544),[[de,r(u)]]),T(Q,{class:"size-4"})])]),n("div",Qn,[r(b).length?c("",!0):(t(),o("div",Yn,[!r(b).length&&r(u).length?(t(),o("p",Zn," No results found. ")):c("",!0)])),r(b).length?(t(),o("div",es,[(t(!0),o(M,null,R(r(b),(p,w)=>(t(),o("button",{ref_for:!0,ref_key:"itemRefs",ref:s,key:`${p.heading}-${p.text.slice(0,10)}`,type:"button",class:P(["block w-full rounded-lg p-4 text-left transition-all duration-200",{"bg-gray-100 shadow-sm":r(m)===w,"hover:bg-gray-100 hover:shadow-sm":r(m)!==w}]),onClick:x=>g(p),onMouseenter:x=>m.value=w},[n("div",ns,[n("p",null,y(p.heading),1)]),n("p",ss,[k[2]||(k[2]=n("span",null,"...",-1)),n("span",null,y(p.before),1),n("mark",os,y(p.match),1),n("span",null,y(p.after),1),k[3]||(k[3]=n("span",null,"...",-1))])],42,ts))),128))])):c("",!0)])]))}}),is={class:"relative"},as=["src"],cs={class:"flex flex-col items-start"},rs={class:"text-5xl md:text-7xl header-text-shadow font-display font-black text-white text-shadow"},us={class:"flex h-full items-center"},ds={class:"font-display text-xl font-black truncate"},hs={class:"flex flex-col gap-6 lg:flex-row lg:justify-between"},ms={class:"order-0 lg:order-1"},fs={class:"bg-white my-12 max-w-960 lg:sticky lg:top-20 lg:z-1000 lg:ml-auto lg:mr-4 lg:p-2 lg:w-56 lg:max-h-[calc(100vh-8rem)] lg:overflow-y-auto lg:pb-6 lg:pr-1 no-scrollbar"},gs={class:"py-12"},_s={class:"max-w-2xl"},bs={class:"text-xl leading-8 scroll-mt-16"},ps=["id"],xs={class:"flex flex-col md:flex-row gap-12"},vs={class:"order-1 md:order-0 flex-1"},ys=["id"],ks={class:"fixed bottom-6 right-6 flex flex-col gap-3"},ws={class:"w-[95vw] max-w-xl rounded-lg bg-white p-6 shadow-xl"},$s=E({__name:"SinglePage",props:{guide:{}},setup(e){const a=e,l=L(null),h=L(null),u=G(()=>a.guide.chapters),b=L(!1),f=L(!1),m=L(!1),s=w=>{f.value=!1;const x=w.extraInfo.element,S=window.getSelection();S&&(S.removeAllRanges(),S.selectAllChildren(x)),w.extraInfo.element.scrollIntoView({behavior:"smooth",block:"center"})};let d=null;const v=()=>{l.value&&(d=new IntersectionObserver(([w])=>{m.value=!w.isIntersecting}),d.observe(l.value))};let g=null;const _=G(()=>k.value.filter(x=>x.ratio>0).sort((x,S)=>S.ratio-x.ratio).at(0)?.uuid??null),k=L([]);
1function p(w){w.forEach(x=>{const S=k.value.find(D=>D.uuid===x.target.id);if(S){S.ratio=x.intersectionRatio;return}k.value.push({uuid:x.target.id,ratio:x.intersectionRatio})})}return B(()=>{v(),g=new IntersectionObserver(p,{threshold:[0,.2,.4,.6,.8,1]}),document.querySelectorAll(".xt-athlete-guide-chapter").forEach(w=>g?.observe(w))}),me(()=>{d?.disconnect()}),(w,x)=>{const S=oe,D=Qe,Z=ye,ee=Vn,te=Q,ne=Jn,W=Ee,se=ls;return t(),o("div",is,[n("div",{ref_key:"bannerRef",ref:l,class:"min-h-700 flex flex-col justify-end pb-12 relative"},[n("img",{src:e.guide.banner_image||"",class:"absolute inset-0 top-0 left-0 w-full h-full object-cover brightness-90",alt:""},null,8,as),T(S,{width:960,class:"relative"},{default:j(()=>[n("div",cs,[n("h1",rs,y(e.guide.title),1),x[5]||(x[5]=n("div",{class:"h-0.5 bg-white w-32 my-3"},null,-1)),x[6]||(x[6]=n("p",{class:"text-2xl md:text-3xl font-black font-display text-white uppercase italic"}," Athlete Guide ",-1))])]),_:1})],512),n("div",{class:P(["fixed inset-x-0 top-0 z-1100 h-16 bg-xt-carbon backdrop-blur text-white shadow duration-200 transition-all",{"-translate-y-full opacity-0":!r(m),"translate-y-0 opacity-100":r(m)}])},[T(S,{width:1220,class:"h-full"},{default:j(()=>[n("div",us,[n("h2",ds,y(e.guide.title),1)])]),_:1})],2),T(S,{width:1220,class:"relative px-2 lg:px-0"},{default:j(()=>[n("div",hs,[n("div",ms,[n("div",fs,[r(u)?(t(),$(D,{key:0,chapters:r(u),"chapter-in-view":r(_)},null,8,["chapters","chapter-in-view"])):c("",!0)])]),n("div",{ref_key:"contentRef",ref:h,class:"flex flex-col gap-6"},[n("div",null,[n("div",gs,[n("div",_s,[x[7]||(x[7]=n("span",{class:"hidden xt-guide-section-heading","data-guide-section-heading":"Overview"},null,-1)),n("p",bs,y(e.guide.overview),1)]),x[8]||(x[8]=n("hr",{class:"mt-8"},null,-1))]),(t(!0),o(M,null,R(r(u),I=>(t(),o("div",{key:I.uuid,id:I.uuid,class:"xt-athlete-guide-chapter scroll-mt-24"},[T(Z,{level:2},{default:j(()=>[z(y(I.title),1)]),_:2},1024),n("div",xs,[n("div",vs,[(t(!0),o(M,null,R(I.sections,U=>(t(),o("div",{key:U.uuid,id:U.uuid,class:"scroll-mt-20 mb-12"},[T(ee,{section:U,sponsors:e.guide.event?.sponsors||[],"chapter-title":I.title},null,8,["section","sponsors","chapter-title"])],8,ys))),128))])])],8,ps))),128))])],512)])]),_:1}),n("div",ks,[n("button",{type:"button",class:"z-50 flex size-9 items-center justify-center rounded-full bg-black/70 text-white shadow-lg transition hover:bg-black lg:size-11","aria-label":"Back to top",onClick:x[0]||(x[0]=I=>f.value=!0)},[T(te,{class:"size-4 lg:size-5"})]),n("button",{type:"button",class:"z-50 flex lg:hidden size-9 items-center justify-center rounded-full bg-black/70 text-white shadow-lg transition hover:bg-black","aria-label":"Back to top",onClick:x[1]||(x[1]=I=>b.value=!0)},[T(ne,{class:"size-4 lg:size-5"})])]),T(W,{show:r(b),onClose:x[3]||(x[3]=I=>b.value=!1)},{default:j(()=>[n("div",ws,[r(u)?(t(),$(D,{key:0,chapters:r(u),onTocSectionClicked:x[2]||(x[2]=I=>b.value=!1)},null,8,["chapters"])):c("",!0)])]),_:1},8,["show"]),T(W,{show:r(f),onClose:x[4]||(x[4]=I=>f.value=!1)},{default:j(()=>[n("div",null,[r(h)?(t(),$(se,{key:0,root:r(h),onSearchResultSelected:s},null,8,["root"])):c("",!0)])]),_:1},8,["show"])])}}}),Cs=async e=>{const a=await fe(`/open/athlete-guides/${e}`);return Be.parse(a.data)},Ss=ge("athlete-guides",()=>{const e=L(null),a=async h=>{if(e.value?.slug!==h)return await l(h)},l=async h=>e.value=await Cs(h);return{current:e,fetchCurrent:a}}),Ts=1e3*60*60*24,Ks=E({__name:"[slug]",async setup(e){let a,l;Ae({accessType:_e.respectsUser});const h=be(),u=Ss(),{$loadLeaflet:b}=q(),f=Me(h.params.slug),m=G(()=>u.current);Re({title:()=>m.value?.title||"",description:()=>m.value?.description||"",ogImage:()=>m.value?.ss_image||""});try{[a,l]=pe(async()=>Ge(`athlete-guide_${f}`,async()=>{await u.fetchCurrent(f)},{mode:"navigation"})),await a,l()}catch(d){if(xe(d))throw ve(d)}let s=null;return B(async()=>{await b(),s=new Date().getTime(),document.addEventListener("visibilitychange",()=>{if(document.visibilityState==="visible"){const d=new Date().getTime();d-(s??d)>Ts&&window.location.reload()}})}),(d,v)=>{const g=$s;return t(),o("div",null,[r(m)?(t(),$(g,{key:0,guide:r(m)},null,8,["guide"])):c("",!0)])}}});
1export{Ks 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.