PageSourceSearch

https://wakingdreamswellnessretreat.com/assets/AdminCheckIn-DFHmE3Mh.js

js wakingdreamswellnessretreat.com collected 2026-10-04 07:34:37 UTC 38,191 bytes, 47 lines download raw bytes

1import{r as i,j as e}from"./vendor-react-DKqPgjep.js";import{t as j}from"./index-CGxUor7o.js";import{u as Pe}from"./vendor-ui-CKHum-wz.js";import{B as d}from"./button-D7W3yy3b.js";import{B as P}from"./badge-DJuhJcjp.js";import{D as V,a as z,d as K,b as q}from"./dialog-E1yQXI6c.js";import{I as m}from"./input-D_12_OGf.js";import{L as p}from"./label-txEATKn0.js";import{g as Re,a0 as je,ab as $e,$ as H,F as Oe,d as Fe,a7 as Me,E as ke,c as D,q as ce,e as Y,a5 as fe,t as ie,ac as Ae,P as We,w as Be,r as ve,ad as Ie,ae as Ge}from"./vendor-lucide-wOhzIz24.js";import"./vendor-radix-DyzjmB17.js";const Ne={1:{name:"Sky Cottage",color:"#4a90d9"},2:{name:"Hickory Hilltop",color:"#7b5ea7"},3:{name:"Mountain Laurel",color:"#4a9e6b"},30001:{name:"Poplar Peak",color:"#d97b4a"}};function Ue(n,h,l){return`${n}-${String(h+1).padStart(2,"0")}-${String(l).padStart(2,"0")}`}function ye({checkIn:n}){return n?n.checkInCompletedAt?e.jsxs(P,{"data-loc":"client/src/pages/AdminCheckIn.tsx:53",className:"text-xs gap-1 bg-green-600 hover:bg-green-600",children:[e.jsx(ve,{"data-loc":"client/src/pages/AdminCheckIn.tsx:53",className:"w-3 h-3"})," Waiver Signed"]}):n.orientationAcknowledgedAt?e.jsxs(P,{"data-loc":"client/src/pages/AdminCheckIn.tsx:56",className:"text-xs gap-1 bg-amber-500 hover:bg-amber-500",children:[e.jsx(Ie,{"data-loc":"client/src/pages/AdminCheckIn.tsx:56",className:"w-3 h-3"})," Orientation Done"]}):e.jsxs(P,{"data-loc":"client/src/pages/AdminCheckIn.tsx:58",className:"text-xs gap-1 bg-blue-500 hover:bg-blue-500",children:[e.jsx(Ie,{"data-loc":"client/src/pages/AdminCheckIn.tsx:58",className:"w-3 h-3"})," Link Sent"]}):e.jsxs(P,{"data-loc":"client/src/pages/AdminCheckIn.tsx:50",variant:"outline",className:"text-xs gap-1",children:[e.jsx(Be,{"data-loc":"client/src/pages/AdminCheckIn.tsx:50",className:"w-3 h-3"})," No Link Sent"]})}function He({checkIn:n,onClose:h}){const l=n.waiverSignedAt?new Date(n.waiverSignedAt):null,x=`WAKING DREAMS WELLNESS RETREAT
2EECP CIRCULATION ENHANCEMENT ACTIVITY WAIVER AND RELEASE OF LIABILITY
3
4Guest: ${n.guestFirstName} ${n.guestLastName}
5Signed: ${l?l.toLocaleString():"—"}
6Signature: ${n.waiverSignature??"—"}
7IP Address: ${n.ipAddress??"—"}
8Token: ${n.token}
9
10────────────────────────────────────────────────────────────────────────
11
121. NATURE OF ACTIVITY
13The undersigned ("Participant") understands that EECP (Enhanced External Counterpulsation) circulation enhancement is a non-invasive wellness activity involving the application of external pneumatic compression cuffs to the lower extremities, which inflate and deflate in synchrony with the cardiac cycle. The activity is provided as a wellness amenity at Waking Dreams Wellness Retreat, 43 Cowan Cove Road, Asheville, NC 28806 ("Retreat").
14
152. PHYSICIAN CLEARANCE
16Participant represents and warrants that they have obtained written clearance from a licensed physician, nurse practitioner, or physician assistant who has reviewed Participant's complete health history and determined that EECP circulation enhancement is an appropriate activity for Participant. Participant further represents that all contraindications to EECP have been screened for and none are present.
17
183. VOLUNTARY PARTICIPATION AND ASSUMPTION OF RISK
19Participant voluntarily chooses to participate in EECP circulation enhancement sessions at the Retreat. Participant acknowledges and accepts that, as with any physical wellness activity, there are inherent risks, including but not limited to: temporary fatigue, muscle soreness, skin irritation at cuff contact sites, lightheadedness, and in rare cases, exacerbation of pre-existing cardiovascular conditions. Participant assumes all such risks.
20
214. RELEASE OF LIABILITY
22In consideration of being permitted to participate in EECP circulation enhancement sessions, Participant, on behalf of themselves and their heirs, executors, administrators, and assigns, hereby releases, waives, discharges, and covenants not to sue Waking Dreams Wellness Retreat, its owners, operators, managers, employees, agents, and representatives (collectively, "Released Parties") from any and all claims, demands, losses, damages, costs, and expenses arising out of or related to Participant's participation in EECP circulation enhancement sessions, whether caused by the negligence of the Released Parties or otherwise.
23
245. INDEMNIFICATION
25Participant agrees to indemnify, defend, and hold harmless the Released Parties from and against any and all claims, actions, suits, proceedings, losses, liabilities, damages, costs, and expenses (including reasonable attorneys' fees) arising out of or related to Participant's participation in EECP circulation enhancement sessions or any breach of the representations made herein.
26
276. MEDICAL EMERGENCY AUTHORIZATION
28In the event of a medical emergency, Participant authorizes the Released Parties to contact emergency medical services and to provide basic first aid. Participant acknowledges that the Retreat is not a medical facility and that its staff are not licensed medical professionals.
29
307. ACKNOWLEDGMENT OF ORIENTATION
31Participant confirms that they have received and understood the Waking Dreams Wellness Retreat Guest Orientation, including information about: (a) what to expect during and after EECP sessions; (b) the intensive two-sessions-per-day schedule and its demands; (c) the importance of hydration and rest; and (d) the appropriateness of skipping a second session on any day of excessive fatigue.
32
338. PHOTOGRAPHY AND TESTIMONIAL CONSENT
34Participant grants the Retreat permission to use any photographs, videos, or written testimonials provided voluntarily by Participant for marketing and educational purposes, subject to Participant's right to revoke this consent in writing at any time.
35
369. SEVERABILITY
37If any provision of this Agreement is found to be unenforceable, the remaining provisions shall continue in full force and effect.
38
3910. GOVERNING LAW
40This Agreement shall be governed by and construed in accordance with the laws of the State of North Carolina, without regard to its conflict of law provisions. Any disputes arising hereunder shall be resolved 
40in the courts of Buncombe County, North Carolina.
41
42BY COMPLETING THE ELECTRONIC CHECK-IN PROCESS AND TYPING THEIR FULL LEGAL NAME AS THEIR ELECTRONIC SIGNATURE, PARTICIPANT ACKNOWLEDGES THAT THEY HAVE READ, UNDERSTOOD, AND AGREE TO BE BOUND BY ALL TERMS OF THIS AGREEMENT.
43
44Electronic Signature: ${n.waiverSignature??"—"}
45Date/Time: ${l?l.toLocaleString():"—"}
46IP Address: ${n.ipAddress??"—"}`,R=()=>{const $=new Blob([x],{type:"text/plain"}),I=URL.createObjectURL($),v=document.createElement("a");v.href=I,v.download=`waiver-${n.guestFirstName}-${n.guestLastName}-${n.token.slice(0,8)}.txt`,v.click(),URL.revokeObjectURL(I)};return e.jsx(V,{"data-loc":"client/src/pages/AdminCheckIn.tsx:125",open:!0,onOpenChange:h,children:e.jsxs(z,{"data-loc":"client/src/pages/AdminCheckIn.tsx:126",className:"max-w-2xl max-h-[80vh] overflow-y-auto",children:[e.jsx(K,{"data-loc":"client/src/pages/AdminCheckIn.tsx:127",children:e.jsxs(q,{"data-loc":"client/src/pages/AdminCheckIn.tsx:128",className:"flex items-center gap-2",children:[e.jsx(je,{"data-loc":"client/src/pages/AdminCheckIn.tsx:129",className:"w-5 h-5",style:{color:"oklch(0.65 0.12 75)"}}),"Signed Waiver — ",n.guestFirstName," ",n.guestLastName]})}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:133",className:"space-y-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:134",className:"flex items-center gap-3 p-3 rounded-lg",style:{background:"#f0fdf4",border:"1px solid #bbf7d0"},children:[e.jsx(ve,{"data-loc":"client/src/pages/AdminCheckIn.tsx:135",className:"w-5 h-5 text-green-600 flex-shrink-0"}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:136",children:[e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:137",className:"text-sm font-semibold text-green-800",children:"Waiver signed electronically"}),e.jsxs("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:138",className:"text-xs text-green-700",children:[l?l.toLocaleString():"—"," · IP: ",n.ipAddress??"unknown"]})]})]}),e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:141",className:"p-4 rounded-lg font-mono text-xs leading-relaxed whitespace-pre-wrap overflow-x-auto",style:{background:"#f8f7f4",border:"1px solid #e5e2da",maxHeight:400},children:x}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:144",onClick:R,className:"w-full gap-2",style:{background:"#162035",color:"#fff"},children:[e.jsx(Ge,{"data-loc":"client/src/pages/AdminCheckIn.tsx:145",className:"w-4 h-4"})," Download Waiver as Text File"]})]})]})})}function es(){const[,n]=Pe(),h=new Date,l=Ue(h.getFullYear(),h.getMonth(),h.getDate()),[x,R]=i.useState(null),[$,I]=i.useState(null),[v,Q]=i.useState(!1),[o,k]=i.useState({firstName:"",lastName:"",email:"",phone:"",sessionDate:l,sessionTime:""}),[O,_]=i.useState(null),[F,le]=i.useState(null),[g,oe]=i.useState(null),[u,w]=i.useState(null),[re,J]=i.useState(null),[C,b]=i.useState(null),[de,M]=i.useState(null),[r,me]=i.useState("all"),[Z,we]=i.useState(""),{data:E=[],refetch:W,isLoading:be}=j.guestCheckIn.list.useQuery(),{data:he=[],isLoading:Ee}=j.adminBookings.list.useQuery(),S=j.guestCheckIn.create.useMutation({onSuccess:s=>{const t=`${window.location.origin}${s.url}`;_(t),le(s.id),W()}}),f=j.guestCheckIn.emailLink.useMutation({onSuccess:s=>oe(s.checkInId)}),X=j.guestCheckIn.updateDayClientAppointment.useMutation({onMutate:()=>J(null),onSuccess:()=>{w(null),W()},onError:s=>J(s.message)}),ee=j.guestCheckIn.updateDayClientContact.useMutation({onMutate:()=>M(null),onSuccess:()=>{b(null),W()},onError:s=>M(s.message)}),se=()=>{k({firstName:"",lastName:"",email:"",phone:"",sessionDate:l,sessionTime:""}),_(null),le(null),oe(null),Q(!0)};i.useEffect(()=>{const s=new URLSearchParams(window.location.search);s.get("day-client")==="1"&&(se(),s.delete("day-client"));const t=s.get("filter");(t==="all"||t==="pending"||t==="signed"||t==="today")&&(me(t),s.delete("filter"));const c=`${window.location.pathname}${s.size?`?${s.toString()}`:""}`;window.history.replaceState({},"",c)},[]);const N=i.useMemo(()=>{const s=new Map;for(const t of E)t.bookingId&&s.set(t.bookingId,t);return s},[E]),te=i.useMemo(()=>E.filter(s=>!s.bookingId),[E]),Se=s=>{const t=new Date(s);return t.getFullYear()===h.getFullYear()&&t.getMonth()===h.getMonth()&&t.getDate()===h.getDate()},B=Z.trim().toLowerCase(),xe=s=>B?`${s.guestFirstName} ${s.guestLastName} ${s.guestEmail??""} ${s.guestPhone??""}`.toLowerCase().includes(B):!0,G=i.useMemo(()=>te.filter(s=>xe(s)).filter(s=>r==="all"?!0:r==="signed"?!!s.checkInCompletedAt:r==="today"?(s.sessionDate===l||!s.sessionDate&&Se(s.createdAt))&&!s.checkInCompletedAt:!s.checkInCompletedAt).sort((s,t)=>{const c=+!!s.checkInCompletedAt-+!!t.checkInCompletedAt;if(c!==0)return c;const T=`${s.sessionDate??"9999-12-31"} ${s.sessionTime??"23:59"}`,y=`${t.sessionDate??"9999-12-31"} ${t.sessionTime??"23:59"}`;return T.localeCompare(y)||new Date(t.createdAt).getTime()-new Date(s.createdAt).getTime()}),[te,r,B]),L=i.useMemo(()=>he.filter(s=>
46s.status!=="cancelled"&&(s.bookingKind??"guest_stay")==="guest_stay"&&s.checkOut>=l).sort((s,t)=>s.checkIn.localeCompare(t.checkIn)),[he,l]),U=i.useMemo(()=>L.filter(s=>{if(!xe(s))return!1;const t=N.get(s.id);return r==="all"?!0:r==="signed"?t?.checkInCompletedAt:r==="today"?s.checkIn===l&&!t?.checkInCompletedAt:r==="pending"?!t?.checkInCompletedAt:!0}),[L,N,r,B]),Le=()=>{const s=a=>`"${String(a??"").replace(/"/g,'""')}"`,t=a=>a?a.checkInCompletedAt?"Waiver signed":a.orientationAcknowledgedAt?"Orientation completed":"Link sent":"No link sent",c=[...G.map(a=>["Day Client",`${a.guestFirstName} ${a.guestLastName}`,a.guestEmail??"",a.guestPhone??"","",`${a.sessionDate??""}${a.sessionTime?` ${a.sessionTime}`:""}`,t(a),new Date(a.createdAt).toLocaleString(),a.waiverSignedAt?new Date(a.waiverSignedAt).toLocaleString():"",a.checkInCompletedAt?new Date(a.checkInCompletedAt).toLocaleString():""]),...U.map(a=>{const A=N.get(a.id);return["Lodging Guest",`${a.guestFirstName} ${a.guestLastName}`,a.guestEmail??"",a.guestPhone??"",Ne[a.roomId]?.name??`Room ${a.roomId}`,`${a.checkIn} to ${a.checkOut}`,t(A),A?new Date(A.createdAt).toLocaleString():"",A?.waiverSignedAt?new Date(A.waiverSignedAt).toLocaleString():"",A?.checkInCompletedAt?new Date(A.checkInCompletedAt).toLocaleString():""]})],y=[["Record Type","Client Name","Email","Phone","Room","Stay / Session Date","Check-In Status","Link Created","Waiver Signed","Check-In Completed"],...c].map(a=>a.map(s).join(",")).join(`
47`),De=new Blob([y],{type:"text/csv;charset=utf-8"}),Ce=URL.createObjectURL(De),ne=document.createElement("a");ne.href=Ce,ne.download=`waking-dreams-check-in-${r}-${l}.csv`,ne.click(),URL.revokeObjectURL(Ce)},ge=(s,t)=>{navigator.clipboard.writeText(s).then(()=>{R(t),setTimeout(()=>R(null),2500)})},pe=s=>{window.open(s,"_blank","noopener,noreferrer")},ae=s=>{f.mutate({checkInId:s,origin:window.location.origin})},Te=s=>{S.mutate({bookingId:s.id,guestFirstName:s.guestFirstName,guestLastName:s.guestLastName,guestEmail:s.guestEmail||""})},ue=$!==null?E.find(s=>s.id===$):null;return e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:357",className:"min-h-screen",style:{background:"#f5f3ef",fontFamily:"var(--font-body, sans-serif)"},children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:359",style:{background:"#162035",color:"#fff"},className:"px-6 py-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:360",className:"flex items-center justify-between",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:361",className:"flex items-center gap-4",children:[e.jsx("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:362",onClick:()=>n("/admin"),className:"p-1.5 rounded hover:bg-white/10 transition-colors",title:"Back to Administration",children:e.jsx(Re,{"data-loc":"client/src/pages/AdminCheckIn.tsx:367",className:"w-5 h-5"})}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:369",children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:370",className:"text-xs uppercase tracking-widest opacity-60 mb-0.5",children:"Waking Dreams Wellness Retreat"}),e.jsxs("h1",{"data-loc":"client/src/pages/AdminCheckIn.tsx:371",className:"text-xl font-bold flex items-center gap-2",children:[e.jsx(je,{"data-loc":"client/src/pages/AdminCheckIn.tsx:372",className:"w-5 h-5",style:{color:"oklch(0.65 0.12 75)"}}),"Guest Check-In & Waivers"]})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:377",className:"flex items-center gap-2",children:[e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:378",variant:"outline",size:"sm",onClick:()=>{W()},className:"gap-1.5 text-white border-white/30 hover:bg-white/10",children:[e.jsx($e,{"data-loc":"client/src/pages/AdminCheckIn.tsx:384",className:"w-3.5 h-3.5"})," Refresh"]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:386",size:"sm",onClick:se,style:{background:"oklch(0.65 0.12 75)",color:"#162035"},className:"font-semibold gap-1.5",children:[e.jsx(H,{"data-loc":"client/src/pages/AdminCheckIn.tsx:392",className:"w-4 h-4"})," Day Client Check-In"]})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:398",className:"flex items-center gap-1 mt-4",children:[e.jsx("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:399",onClick:()=>n("/admin/bookings"),className:"px-4 py-2 text-sm font-medium rounded-t-md transition-colors",style:{color:"rgba(255,255,255,0.6)"},children:"📅 Booking Calendar"}),e.jsx("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:406",className:"px-4 py-2 text-sm font-medium rounded-t-md",style:{background:"#f5f3ef",color:"#162035"},children:"✅ Check-In & Waivers"})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:415",className:"px-6 py-6 max-w-5xl mx-auto",children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:417",className:"grid grid-cols-2 lg:grid-cols-4 gap-4 mb-6",children:[{label:"Active Bookings",value:L.length,color:"#162035"},{label:"Waivers Signed",value:L.filter(s=>N.get(s.id)?.checkInCompletedAt).length,color:"#4a9e6b"},{label:"Pending Check-In",value:L.filter(s=>!N.get(s.id)?.checkInCompletedAt).length,color:"#d97b4a"},{label:"Day Client Waivers Pending",value:te.filter(s=>!s.checkInCompletedAt).length,color:"#7b5ea7"}].map(s=>e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:424",className:"rounded-xl p-4 bg-white shadow-sm",style:{border:"1px solid oklch(0.88 0.01 80)"},children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:425",className:"text-2xl font-bold",style:{color:s.color,fontFamily:"var(--font-display)"},children:s.value}),e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:426",className:"text-xs text-gray-500 mt-0.5",children:s.label})]},s.label))}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:432",className:"flex flex-wrap items-center gap-2 mb-4",children:[["all","pending","today","signed"].map(s=>e.jsx("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:434",onClick:()=>me(s),className:"px-3 py-1.5 text-xs font-semibold rounded-full transition-colors capitalize",style:{background:r===s?"#162035":"#fff",color:r===s?"#fff":"#374151",border:"1px solid oklch(0.88 0.01 80)"},children:s==="all"?"All Guests":s==="pending"?"Pending Waiver":s==="today"?"Today’s Open Queue":"Waiver Signed"},s)),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:447",variant:"outline",size:"sm",onClick:Le,className:"gap-1.5 bg-white text-xs",children:[e.jsx(Oe,{"data-loc":"client/src/pages/AdminCheckIn.tsx:448",className:"h-3.5 w-3.5"})," Export CSV (",G.length+U.length,")"]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:450",className:"relative ml-auto w-full sm:w-64",children:[e.jsx(Fe,{"data-loc":"client/src/pages/AdminCheckIn.tsx:451",className:"absolute left-3 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-gray-400"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:452",value:Z,onChange:s=>we(s.target.value),placeholder:"Search client name or email",className:"h-8 bg-white pl-8 text-xs"})]})]}),e.jsxs("section",{"data-loc":"client/src/pages/AdminCheckIn.tsx:457",className:"mb-8 rounded-2xl p-5",style:{background:"#fffdf7",border:"1px solid #ead39b"},children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:458",className:"flex flex-wrap items-start justify-between gap-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:459",children:[e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:460",className:"text-xs font-semibold uppercase tracking-[0.16em]",style:{color:"#8a6d1f"},children:"Elyse's day-client action queue"}),e.jsx("h2",{"data-loc":"client/src/pages/AdminCheckIn.tsx:461",className:"mt-1 text-xl font-bold",style:{color:"#162035",fontFamily:"var(--font-display)"},children:"No lodging reservation required"}),e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:462",className:"mt-1 text-sm text-gray-600",children:"Create the link, open it on a shared device or copy it to the client, then watch for the completed electronic waiver below."}),r==="today"&&e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:463",className:"mt-2 text-xs font-semibold",style:{color:"#8a6d1f"},children:"Showing incomplete day-client sessions scheduled for today (or legacy links created today) and incomplete lodging check-ins scheduled for today."})]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:465",onClick:se,className:"gap-2 font-semibold",style:{background:"#c9a84c",color:"#162035"},children:[e.jsx(H,{"data-loc":"client/src/pages/AdminCheckIn.tsx:466",className:"h-4 w-4"})," Start Day Client Check-In"]})]}),e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:469",className:"mt-5 space-y-3",children:G.length===0?e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:471",className:"rounded-lg bg-white px-4 py-5 text-sm text-gray-500",style:{border:"1px solid oklch(0.9 0.01 80)"},children:Z?"No day-client records match this search.":"No day-client check-ins yet. Use the button above when a non-lodging client arrives."}):G.map(s=>{const t=`${window.location.origin}/check-in/${s.token}`;return e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:477",className:"rounded-xl bg-white p-4 shadow-sm",style:{border:"1px solid oklch(0.88 0.01 80)"},children:e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:478",className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:479",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:480",className:"flex items-center gap-2",children:[e.jsx(Me,{"data-loc":"client/src/pages/AdminCheckIn.tsx:481",className:"h-4 w-4 text-gray-400"}),e.jsxs("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:482",className:"text-sm font-semibold",children:[s.guestFirstName," ",s.guestLastName]}),e.jsx(P,{"data-loc":"client/src/pages/AdminCheckIn.tsx:483",variant:"outline",className:"text-[10px]",children:"Day Client"})]}),e.jsxs("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:485",className:"mt-1 text-xs text-gray-500",children:[s.sessionDate?`Session ${s.sessionDate}${s.sessionTime?` at ${s.sessionTime}`:""}
47 · `:"","Created ",new Date(s.createdAt).toLocaleString(),s.guestEmail?` · ${s.guestEmail}`:"",s.guestPhone?` · ${s.guestPhone}`:""]})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:487",className:"flex flex-wrap items-center gap-2",children:[e.jsx(ye,{"data-loc":"client/src/pages/AdminCheckIn.tsx:488",checkIn:s}),e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:489",onClick:()=>pe(t),className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold",style:{background:"#162035",color:"#fff"},children:[e.jsx(ke,{"data-loc":"client/src/pages/AdminCheckIn.tsx:490",className:"h-3 w-3"})," Open"]}),e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:492",onClick:()=>ge(t,s.token),className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold",style:{background:x===s.token?"#4a9e6b":"#f8f7f4",color:x===s.token?"#fff":"#162035",border:"1px solid oklch(0.88 0.01 80)"},children:[x===s.token?e.jsx(D,{"data-loc":"client/src/pages/AdminCheckIn.tsx:493",className:"h-3 w-3"}):e.jsx(ce,{"data-loc":"client/src/pages/AdminCheckIn.tsx:493",className:"h-3 w-3"}),x===s.token?"Copied":"Copy Link"]}),s.guestEmail&&e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:496",disabled:f.isPending,onClick:()=>ae(s.id),className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold disabled:opacity-60",style:{background:g===s.id?"#4a9e6b":"#eef6f0",color:g===s.id?"#fff":"#256b45",border:"1px solid #b7d9c0"},children:[g===s.id?e.jsx(D,{"data-loc":"client/src/pages/AdminCheckIn.tsx:497",className:"h-3 w-3"}):e.jsx(Y,{"data-loc":"client/src/pages/AdminCheckIn.tsx:497",className:"h-3 w-3"}),g===s.id?"Email Sent":f.isPending?"Sending…":"Email Link"]}),e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:500",onClick:()=>{M(null),b({id:s.id,name:`${s.guestFirstName} ${s.guestLastName}`,email:s.guestEmail??"",phone:s.guestPhone??""})},className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold",style:{background:"#f8f7f4",color:"#162035",border:"1px solid oklch(0.88 0.01 80)"},children:[e.jsx(fe,{"data-loc":"client/src/pages/AdminCheckIn.tsx:501",className:"h-3 w-3"})," Edit Contact"]}),e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:503",onClick:()=>{J(null),w({id:s.id,name:`${s.guestFirstName} ${s.guestLastName}`,sessionDate:s.sessionDate??l,sessionTime:s.sessionTime??""})},className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold",style:{background:"#f8f7f4",color:"#162035",border:"1px solid oklch(0.88 0.01 80)"},children:[e.jsx(ie,{"data-loc":"client/src/pages/AdminCheckIn.tsx:504",className:"h-3 w-3"})," Edit Session"]}),s.checkInCompletedAt&&e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:506",onClick:()=>I(s.id),className:"flex items-center gap-1.5 rounded-lg px-3 py-1.5 text-xs font-semibold",style:{background:"#4a9e6b",color:"#fff"},children:[e.jsx(Ae,{"data-loc":"client/src/pages/AdminCheckIn.tsx:506",className:"h-3 w-3"})," View Waiver"]})]})]})},s.id)})})]}),Ee||be?e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:517",className:"text-center py-12 text-gray-400",children:"Loading…"}):U.length===0?e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:519",className:"text-center py-12 text-gray-400",children:"No bookings match this filter."}):e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:521",className:"space-y-3",children:U.map(s=>{const t=Ne[s.roomId],c=N.get(s.id)??null,T=c?`${window.location.origin}/check-in/${c.token}`:null,y=S.isPending;return e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:529",className:"rounded-xl bg-white p-5 shadow-sm",style:{border:"1px solid oklch(0.88 0.01 80)"},children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:534",className:"flex items-start justify-between gap-4 flex-wrap",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:535",className:"flex items-start gap-3",children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:536",className:"w-3 h-3 rounded-sm mt-1.5 flex-shrink-0",style:{background:t?.color??"#999"}}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:540",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:541",className:"font-semibold text-gray-900",children:[s.guestFirstName," ",s.guestLastName]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:544",className:"text-xs text-gray-500 mt-0.5 flex items-center gap-3 flex-wrap",children:[e.jsxs("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:545",className:"flex items-center gap-1",children:[e.jsx(ie,{"data-loc":"client/src/pages/AdminCheckIn.tsx:546",className:"w-3 h-3"}),s.checkIn," → ",s.checkOut," (",s.nights,"n)"]}),e.jsx("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:549",style:{color:t?.color},children:t?.name??`Room ${s.roomId}`}),s.guestEmail&&e.jsxs("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:551",className:"flex items-center gap-1",children:[e.jsx(Y,{"data-loc":"client/src/pages/AdminCheckIn.tsx:552",className:"w-3 h-3"})," ",s.guestEmail]}),s.guestPhone&&e.jsxs("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:556",className:"flex items-center gap-1",children:[e.jsx(We,{"data-loc":"client/src/pages/AdminCheckIn.tsx:557",className:"w-3 h-3"})," ",s.guestPhone]})]})]})]}),e.jsx(ye,{"data-loc":"client/src/pages/AdminCheckIn.tsx:563",checkIn:c})]}),e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:567",className:"mt-4 pt-4",style:{borderTop:"1px solid oklch(0.92 0.01 80)"},children:c?e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:569",className:"flex items-center gap-2 flex-wrap",children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:570",className:"flex-1 min-w-0",children:e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:571",className:"flex items-center gap-2 rounded-lg px-3 py-2 text-xs font-mono truncate",style:{background:"#f8f7f4",border:"1px solid oklch(0.88 0.01 80)"},children:e.jsx("span",{"data-loc":"client/src/pages/AdminCheckIn.tsx:572",className:"truncate text-gray-600",children:T})})}),e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:575",onClick:()=>ge(T,c.token),className:"flex items-center gap-1.5 px-3 py-2 text-xs font-semibold rounded-lg transition-colors",style:{background:x===c.token?"#4a9e6b":"#162035",color:"#fff"},children:[x===c.token?e.jsx(D,{"data-loc":"client/src/pages/AdminCheckIn.tsx:580",className:"w-3.5 h-3.5"}):e.jsx(ce,{"data-loc":"client/src/pages/AdminCheckIn.tsx:580",className:"w-3.5 h-3.5"}),x===c.token?"Copied!":"Copy Link"]}),c.guestEmail&&e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:584",disabled:f.isPending,onClick:()=>ae(c.id),className:"flex items-center gap-1.5 px-3 py-2 text-xs font-semibold rounded-lg transition-colors disabled:opacity-60",style:{background:g===c.id?"#4a9e6b":"#eef6f0",color:g===c.id?"#fff":"#256b45",border:"1px solid #b7d9c0"},children:[g===c.id?e.jsx(D,{"data-loc":"client/src/pages/AdminCheckIn.tsx:590",className:"w-3.5 h-3.5"}):e.jsx(Y,{"data-loc":"client/src/pages/AdminCheckIn.tsx:590",className:"w-3.5 h-3.5"}),g===c.id?"Email Sent":f.isPending?"Sending…":"Email Link"]}),c.checkInCompletedAt&&e.jsxs("button",{"data-loc":"client/src/pages/AdminCheckIn.tsx:595",onClick:()=>I(c.id),className:"flex items-center gap-1.5 px-3 py-2 text-xs font-semibold rounded-lg transition-colors",style:{background:"#4a9e6b",color:"#fff"},children:[e.jsx(Ae,{"data-loc":"client/src/pages/AdminCheckIn.tsx:600",className:"w-3.5 h-3.5"})," View Waiver"]})]}):e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:605",size:"sm",onClick:()=>Te(s),disabled:y,className:"gap-1.5 text-xs",style:{background:"oklch(0.65 0.12 75
47)",color:"#162035"},children:[e.jsx(H,{"data-loc":"client/src/pages/AdminCheckIn.tsx:612",className:"w-3.5 h-3.5"}),y?"Generating…":"Generate Check-In Link"]})})]},s.id)})})]}),ue&&e.jsx(He,{"data-loc":"client/src/pages/AdminCheckIn.tsx:627",checkIn:ue,onClose:()=>I(null)}),e.jsx(V,{"data-loc":"client/src/pages/AdminCheckIn.tsx:630",open:!!u,onOpenChange:s=>{s||w(null)},children:e.jsxs(z,{"data-loc":"client/src/pages/AdminCheckIn.tsx:631",className:"max-w-sm",children:[e.jsx(K,{"data-loc":"client/src/pages/AdminCheckIn.tsx:632",children:e.jsx(q,{"data-loc":"client/src/pages/AdminCheckIn.tsx:633",children:"Edit Day Client Session"})}),u&&e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:636",className:"space-y-4",children:[e.jsxs("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:637",className:"text-sm text-gray-600",children:["Update the scheduled session for ",u.name,". The existing check-in link remains valid."]}),re&&e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:638",role:"alert",className:"rounded-md border border-red-200 bg-red-50 px-3 py-2 text-sm text-red-800",children:re}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:639",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:640",children:"Session date"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:641",type:"date",value:u.sessionDate,onChange:s=>w(t=>t&&{...t,sessionDate:s.target.value})})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:643",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:644",children:"Session time (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:645",type:"time",value:u.sessionTime,onChange:s=>w(t=>t&&{...t,sessionTime:s.target.value})})]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:647",className:"w-full gap-2",disabled:!u.sessionDate||X.isPending,style:{background:"#162035",color:"#fff"},onClick:()=>X.mutate({checkInId:u.id,sessionDate:u.sessionDate,sessionTime:u.sessionTime}),children:[e.jsx(ie,{"data-loc":"client/src/pages/AdminCheckIn.tsx:648",className:"w-4 h-4"})," ",X.isPending?"Saving…":"Save Session Timing"]})]})]})}),e.jsx(V,{"data-loc":"client/src/pages/AdminCheckIn.tsx:655",open:!!C,onOpenChange:s=>{s||(b(null),M(null))},children:e.jsxs(z,{"data-loc":"client/src/pages/AdminCheckIn.tsx:656",className:"max-w-sm",children:[e.jsx(K,{"data-loc":"client/src/pages/AdminCheckIn.tsx:657",children:e.jsx(q,{"data-loc":"client/src/pages/AdminCheckIn.tsx:658",children:"Edit Day Client Contact"})}),C&&e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:661",className:"space-y-4",children:[e.jsxs("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:662",className:"text-sm text-gray-600",children:["Correct the delivery details for ",C.name,". Save before using Email Link; this does not resend the link automatically."]}),de&&e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:663",role:"alert",className:"rounded-md border border-red-200 bg-red-50 px-3 py-2 text-sm text-red-800",children:de}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:664",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:665",children:"Email address (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:666",type:"email",value:C.email,onChange:s=>b(t=>t&&{...t,email:s.target.value})})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:668",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:669",children:"Phone (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:670",type:"tel",value:C.phone,onChange:s=>b(t=>t&&{...t,phone:s.target.value})})]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:672",className:"w-full gap-2",disabled:ee.isPending,style:{background:"#162035",color:"#fff"},onClick:()=>ee.mutate({checkInId:C.id,guestEmail:C.email,guestPhone:C.phone}),children:[e.jsx(fe,{"data-loc":"client/src/pages/AdminCheckIn.tsx:673",className:"w-4 h-4"})," ",ee.isPending?"Saving…":"Save Contact Details"]})]})]})}),e.jsx(V,{"data-loc":"client/src/pages/AdminCheckIn.tsx:681",open:v,onOpenChange:Q,children:e.jsxs(z,{"data-loc":"client/src/pages/AdminCheckIn.tsx:682",className:"max-w-md",children:[e.jsx(K,{"data-loc":"client/src/pages/AdminCheckIn.tsx:683",children:e.jsx(q,{"data-loc":"client/src/pages/AdminCheckIn.tsx:684",children:"Create Day Client Check-In Link"})}),O?e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:687",className:"space-y-4",children:[e.jsx("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:688",className:"p-3 rounded-lg text-sm font-mono break-all",style:{background:"#f8f7f4",border:"1px solid oklch(0.88 0.01 80)"},children:O}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:691",className:"w-full gap-2",style:{background:"#162035",color:"#fff"},onClick:()=>{navigator.clipboard.writeText(O)},children:[e.jsx(ce,{"data-loc":"client/src/pages/AdminCheckIn.tsx:696",className:"w-4 h-4"})," Copy Link"]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:698",variant:"outline",className:"w-full gap-2",onClick:()=>pe(O),children:[e.jsx(ke,{"data-loc":"client/src/pages/AdminCheckIn.tsx:699",className:"w-4 h-4"})," Open on This Device"]}),o.email&&F&&e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:702",variant:"outline",className:"w-full gap-2",disabled:f.isPending,onClick:()=>ae(F),children:[g===F?e.jsx(D,{"data-loc":"client/src/pages/AdminCheckIn.tsx:708",className:"w-4 h-4"}):e.jsx(Y,{"data-loc":"client/src/pages/AdminCheckIn.tsx:708",className:"w-4 h-4"}),g===F?"Email Sent to Client":f.isPending?"Sending…":"Email Link to Client"]}),e.jsx(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:712",variant:"outline",className:"w-full",onClick:()=>{Q(!1),_(null)},children:"Done"})]}):e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:71
477",className:"space-y-4",children:[e.jsx("p",{"data-loc":"client/src/pages/AdminCheckIn.tsx:718",className:"text-sm text-gray-600",children:"Use this for a client receiving sessions without a Waking Dreams lodging reservation. Elyse can share the generated link on the client's phone or by email."}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:719",className:"grid grid-cols-2 gap-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:720",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:721",children:"First Name *"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:722",value:o.firstName,onChange:s=>k(t=>({...t,firstName:s.target.value})),placeholder:"Jane"})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:724",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:725",children:"Last Name *"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:726",value:o.lastName,onChange:s=>k(t=>({...t,lastName:s.target.value})),placeholder:"Smith"})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:729",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:730",children:"Email (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:731",value:o.email,onChange:s=>k(t=>({...t,email:s.target.value})),placeholder:"[email protected]",type:"email"})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:733",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:734",children:"Phone (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:735",value:o.phone,onChange:s=>k(t=>({...t,phone:s.target.value})),placeholder:"(555) 555-5555",type:"tel"})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:737",className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:738",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:739",children:"Session date (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:740",value:o.sessionDate,onChange:s=>k(t=>({...t,sessionDate:s.target.value})),type:"date"})]}),e.jsxs("div",{"data-loc":"client/src/pages/AdminCheckIn.tsx:742",children:[e.jsx(p,{"data-loc":"client/src/pages/AdminCheckIn.tsx:743",children:"Session time (optional)"}),e.jsx(m,{"data-loc":"client/src/pages/AdminCheckIn.tsx:744",value:o.sessionTime,onChange:s=>k(t=>({...t,sessionTime:s.target.value})),type:"time"})]})]}),e.jsxs(d,{"data-loc":"client/src/pages/AdminCheckIn.tsx:747",className:"w-full gap-2",style:{background:"oklch(0.65 0.12 75)",color:"#162035"},disabled:!o.firstName||!o.lastName||S.isPending,onClick:()=>S.mutate({guestFirstName:o.firstName,guestLastName:o.lastName,guestEmail:o.email,guestPhone:o.phone,sessionDate:o.sessionDate,sessionTime:o.sessionTime}),children:[e.jsx(H,{"data-loc":"client/src/pages/AdminCheckIn.tsx:753",className:"w-4 h-4"}),S.isPending?"Generating…":"Generate Day Client Link"]})]})]})})]})}export{es 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.