1import $ from"./By5OWUNx.js";import j from"./BJn64Y_q.js";import{_ as F,a as P,b as J}from"./C4c3hneL.js";import{_ as W}from"./Bt50DV_e.js";import{Q as c}from"./D8f3P8Zk.js";import{_ as Y}from"./CImT4WDv.js";import{u as E}from"./DHVX4cEH.js";import{a as G,s as Q}from"./BINjRqgu.js";import{a as q}from"./BeRA6nGp.js";import{l as K,o as X,e as a,f as t,G as s,N as H,R as w,t as l,O as tt,S as d,g as et,j as T,k as D,a4 as st,r as ot,d as M,i as n}from"./Pf7buPU6.js";import"./BcyFyP42.js";import"./C3moMyKJ.js";const nt=c("/imgs/profile/icons/calendar-solid.svg"),it=c("/imgs/profile/icons/people-solid.svg"),lt=c("/imgs/profile/icons/bed-solid.svg"),at=c("/imgs/profile/icons/check-circle-solid.svg"),ct=c("/imgs/profile/icons/hotel.svg"),rt=c("/imgs/profile/icons/info.svg"),dt={class:"max-w-7xl mx-auto px-4"},mt={class:"grid md:grid-cols-5 gap-6 mb-8"},pt={class:"md:col-span-2 flex flex-col"},ut={class:"text-2xl font-semibold text-zinc-800 mb-6 h-8"},ht={key:0,class:"inline-block w-32 h-6 bg-zinc-200 rounded animate-pulse"},xt={key:0,class:"bg-white shadow-md overflow-hidden flex-1 flex flex-col"},gt={class:"p-10 flex-1"},_t={class:"space-y-3"},ft={key:1,class:"bg-white shadow-md overflow-hidden flex-1 flex flex-col"},bt={class:"text-center py-4 border-b border-zinc-200 flex items-center justify-center min-h-[60px] hotel-logo"},vt={key:5,class:"text-lg font-semibold tracking-widest text-zinc-700"},wt={class:"p-10 flex-1"},yt={key:0,class:"text-center mb-6"},kt={class:"text-zinc-600 text-sm"},Ct={class:"space-y-3"},zt={class:"flex items-center gap-3"},Vt={class:"text-zinc-700"},Nt={class:"flex items-center gap-3"},Ht={class:"text-zinc-700"},Tt={class:"flex items-center gap-3"},Dt={class:"text-zinc-700"},Mt={class:"flex items-center gap-3"},Lt={class:"text-zinc-700"},At={class:"flex items-center gap-3"},Ot={class:"text-zinc-700"},Ut={class:"flex items-center gap-3"},It={class:"text-zinc-700"},St={class:"border-t border-zinc-200 p-4 text-center"},Bt={key:2,class:"bg-white shadow-md overflow-hidden flex-1 flex flex-col"},Rt={class:"p-6 flex-1 flex flex-col items-center justify-center text-center"},te=K({__name:"dashboard",setup(Zt){q({title:"My Atlantis Vacation | Dashboard",ogTitle:"My Atlantis Vacation | Dashboard"});const{user:u,fetchUser:L}=E(),h=ot(!0),{towerSlug:r}=G();X(async()=>{try{await L()}finally{h.value=!1}});const A=M(()=>u.value?.name?u.value.name.split(" ")[0]:null),i=M(()=>{const m=u.value?.trips;if(!m||Object.keys(m).length===0)return null;const e=new Date;e.setHours(0,0,0,0);const o=Q(m);if(!o)return null;const[x,g,_]=o.check_in.split("-").map(Number),[f,p,b]=o.check_out.split("-").map(Number),v=new Date(Date.UTC(x,g-1,_,12)),y=new Date(Date.UTC(f,p-1,b,12)),k=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),12)),O=Math.ceil((v.getTime()-e.getTime())/(1e3*60*60*24)),U=k>=v&&k<=y,I=Math.ceil((y.getTime()-v.getTime())/(1e3*60*60*24)),C=S=>{const[z,V,N]=S.split("-").map(Number),B=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],R=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"][new Date(Date.UTC(z,V-1,N,12)).getUTCDay()],Z=B[V-1];return`${R}, ${Z} ${N}, ${z}`};return{hotel:"ATLANTIS",daysUntil:O,isActive:U,checkIn:C(o.check_in),checkOut:C(o.check_out),checkInRaw:o.check_in,adults:o.number_of_adults||0,children:o.number_of_children||0,nights:I,status:o.status||"Confirmed",roomType:o.main_room?.name||o.room||"Room",bookingNumber:o.booking_number,lastName:o.last_name}});return(m,e)=>{const o=$,x=j,g=F,_=P,f=J,p=W;return n(),a("main",dt,[t("div",mt,[t("div",pt,[t("h1",ut,[s(h)?(n(),a("span",ht)):(n(),a(H,{key:1},[w(" Hi, "+l(s(A))+"! ",1)],64))]),s(h)?(n(),a("div",xt,[e[2]||(e[2]=t("div",{class:"text-center py-4 border-b border-zinc-200"},[t("span",{class:"inline-block w-24 h-12 bg-zinc-200 rounded animate-pulse"})],-1)),t("div",gt,[e[1]||(e[1]=t("div",{class:"text-center mb-6"},[t("div",{class:"w-10 h-10 mx-auto mb-2 bg-zinc-200 rounded-full animate-pulse"}),t("span",{class:"inline-block w-48 h-4 bg-zinc-200 rounded animate-pulse"})],-1)),t("div",_t,[(n(),a(H,null,tt(6,b=>t("div",{key:b,class:"flex items-center gap-3"},[...e[0]||(e[0]=[t("div",{class:"w-5 h-5 bg-zinc-200 rounded animate-pulse"},null,-1),t("span",{class:"inline-block w-40 h-4 bg-zinc-200 rounded animate-pulse"},null,-1)])])),64))])]),e[3]||(e[3]=t("div",{class:"border-t border-zinc-200 p-4 text-center"},[t("span",{class:"inline-block w-24 h-4 bg-zinc-200 rounded animate-pulse"})],-1))])):s(i)?(n(),a("div",ft,[t("div",bt,[s(r)==="cove"?(n(),d(o,{key:0,class:"h-6"})):s(r)==="reef"?(n(),d(x,{key:1,class:"h-20","show-sub-text":!1})):s(r)==="coral"?(n(),d(g,{key:2,class:"h-12"})):s(r)==="royal"?(n(),d(_,{key:3,class:"h-20","show-sub-text":!1})):s(r)==="harborside"?(n(),d(f,{key:4,class:"h-24"})):(n(),a("h2",vt,l(s(i).hotel),1))]),t("div",wt,[s(i).isActive?et("",!0):(n(),a("div",yt,[e[4]||(e[4]=t("svg",{fill:"none",height:"35",viewBox:"0 0 46 35",width:"46",xmlns:"http://www.w3.org/2000/svg",class:"plane-icon w-10 h-10 mx-auto mb-2"},[t("path",{d:"m44.8494 30.3334h-43.69922c-.63536 0-1.14997569.5221-1.14997569 1.1667v2.3332c0 .6446.51461569 1.1667 1.14997569 1.1667h43.69922c.6353 0 1.1499-.5221 1.1499-1.1667v
1-2.3332c0-.6446-.5146-1.1667-1.1499-1.1667zm-39.05977-7.7823c.45136.4988 1.08529.7817 1.74868.781l9.38239-.0132c.7404-.001 1.4702-.1788 2.1303-.5191l20.9124-10.766c1.9219-.9895 3.6447-2.40186 4.817-4.25172 1.316-2.07664 1.459-3.57943.9393-4.64108-.5182-1.06238-1.7781-1.84258-4.1866-2.00153-2.1454-.141459-4.2794.43166-6.2013 1.42039l-7.0802 3.64505-15.7188-5.98345c-.189-.1291645-.4086-.2047698-.636-.21899899-.2274-.01422921-.4545.03343429-.6577.13806199l-4.72571 2.433197c-.76689.39447-.95232 1.43279-.37158 2.08028l11.22809 7.153-7.41807 3.8193-5.20006-2.6592c-.17915-.0916-.37704-.1392-.57768-.139-.20063.0003-.3984.0484-.57733.1405l-2.884288 1.4852c-.7503607.3865-.948013 1.3942-.400336 2.0475z",fill:"#254297"})],-1)),t("p",kt," Only "+l(s(i).daysUntil)+" days until you arrive in paradise! ",1)])),t("div",Ct,[t("div",zt,[e[5]||(e[5]=t("img",{src:nt,alt:"Calendar",class:"w-5 h-5"},null,-1)),t("span",Vt,l(s(i).checkIn)+" - "+l(s(i).checkOut),1)]),t("div",Nt,[e[6]||(e[6]=t("img",{src:it,alt:"People",class:"w-5 h-5"},null,-1)),t("span",Ht,l(s(i).adults)+" Adults   "+l(s(i).children)+" Children",1)]),t("div",Tt,[e[7]||(e[7]=t("img",{src:lt,alt:"Bed",class:"w-5 h-5"},null,-1)),t("span",Dt,l(s(i).nights)+" Nights",1)]),t("div",Mt,[e[8]||(e[8]=t("img",{src:at,alt:"","aria-hidden":"true",class:"w-5 h-5"},null,-1)),t("span",Lt,l(s(i).status),1)]),t("div",At,[e[9]||(e[9]=t("img",{src:ct,alt:"Hotel",class:"w-5 h-5"},null,-1)),t("span",Ot,"Room: "+l(s(i).roomType),1)]),t("div",Ut,[e[10]||(e[10]=t("img",{src:rt,alt:"Info",class:"w-5 h-5"},null,-1)),t("span",It,"Booking #: "+l(s(i).bookingNumber),1)])])]),t("div",St,[T(p,{to:`/profile/trips/${s(i).bookingNumber}`,class:"text-zinc-700 font-medium hover:text-glueblue-600"},{default:D(()=>[...e[11]||(e[11]=[w(" View itinerary ",-1)])]),_:1},8,["to"])])])):(n(),a("div",Bt,[t("div",Rt,[e[13]||(e[13]=t("img",{src:Y,alt:"Fish",class:"w-48 h-48 mx-auto mb-2"},null,-1)),e[14]||(e[14]=t("h3",{class:"text-lg font-semibold text-zinc-700 mb-2"}," No upcoming trips ",-1)),e[15]||(e[15]=t("p",{class:"text-zinc-500 text-sm mb-6"}," Ready for your next adventure in paradise? ",-1)),T(p,{to:"/profile/trips",class:"px-6 py-2 bg-glueblue-600 text-white font-semibold text-sm hover:bg-glueblue-700 transition-colors"},{default:D(()=>[...e[12]||(e[12]=[w(" Add a Trip ",-1)])]),_:1})])]))]),e[16]||(e[16]=st('<div class="md:col-span-3 flex flex-col"><h2 class="text-2xl font-semibold text-zinc-800 mb-6"> Welcome to Paradise </h2><div class="bg-white shadow-md p-8 flex-1 flex flex-col justify-center"><p class="text-center text-zinc-800 text-[18px] font-semibold mb-8"> Start exploring to book your next trip! </p><div class="text-center mb-8"><svg width="54" height="48" viewBox="0 0 54 48" class="big-hotel-icon w-12 h-12 mx-auto mb-3" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M52.5 6C53.3288 6 54 5.32875 54 4.5V1.5C54 0.67125 53.3288 0 52.5 0H1.5C0.67125 0 0 0.67125 0 1.5V4.5C0 5.32875 0.67125 6 1.5 6H2.99813V42H1.5C0.67125 42 0 42.6712 0 43.5V46.5C0 47.3288 0.67125 48 1.5 48H24V40.5C24 39.675 24.675 39 25.5 39H28.5C29.325 39 30 39.675 30 40.5V48H52.5C53.3288 48 54 47.3288 54 46.5V43.5C54 42.6712 53.3288 42 52.5 42H51V6H52.5ZM24 10.2C24 9.6 24.6 9 25.2 9H28.8C29.4 9 30 9.6 30 10.2V13.8C30 14.4 29.4 15 28.8 15H25.2C24.6 15 24 14.4 24 13.8V10.2ZM24 19.2C24 18.6 24.6 18 25.2 18H28.8C29.4 18 30 18.6 30 19.2V22.8C30 23.4 29.4 24 28.8 24H25.2C24.6 24 24 23.4 24 22.8V19.2ZM12 10.2C12 9.6 12.6 9 13.2 9H16.8C17.4 9 18 9.6 18 10.2V13.8C18 14.4 17.4 15 16.8 15H13.2C12.6 15 12 14.4 12 13.8V10.2ZM16.8 24H13.2C12.6 24 12 23.4 12 22.8V19.2C12 18.6 12.6 18 13.2 18H16.8C17.4 18 18 18.6 18 19.2V22.8C18 23.4 17.4 24 16.8 24ZM18 36C18 31.0294 22.0294 27 27 27C31.9706 27 36 31.0294 36 36H18ZM42 22.8C42 23.4 41.4 24 40.8 24H37.2C36.6 24 36 23.4 36 22.8V19.2C36 18.6 36.6 18 37.2 18H40.8C41.4 18 42 18.6 42 19.2V22.8ZM42 13.8C42 14.4 41.4 15 40.8 15H37.2C36.6 15 36 14.4 36 13.8V10.2C36 9.6 36.6 9 37.2 9H40.8C41.4 9 42 9.6 42 10.2V13.8Z" fill="#254297"></path></svg><p class="text-zinc-600 mb-4"> Pick the hotel with the vibe that's right for you. </p><a href="#book-now" type="button" class="px-8 py-3 border border-zinc-800 text-zinc-800 font-semibold text-xs uppercase tracking-wider hover:bg-glueblue-600 hover:font-semibold hover:border-glueblue-600 hover:text-white transition-colors"> Book Now </a></div></div></div>',1))])])}}});
1export{te 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.