import{aB as r,aJ as i,A as c,aD as m,aE as b,j as f,k as p,H as d,ax as u,G as C,M as k}from"./CSGWN0Ke.js";const g=async()=>{const{API_CMS:s}=c().public,e=m(s),a=b(e),o=f(),t=p(),{data:l}=await d("booking_journey",()=>a.getSingle("booking_journey",{lang:t.value[o.params.lang]}));return l.value.data},q=()=>r("useEnquireOverrides",()=>({})),y=()=>{const s=r("enquireData",()=>({enquiryType:"",selectedClub:"",enquireTitle:"",hubspotErrors:{},enquireNowCustomNumber:"",enquiry:{bookTour:{step:0,tourDate:"",tourTime:"",firstName:"",surname:"",email:"",phoneNumber:"",phoneNumberFull:"",phoneCountryCode:"",geoIpPhoneCode:"",consentBulkEmail:"",consentBulkSMS:"",checkedInterests:[],errors:{selectClub:!1,tourDate:!1,tourTime:!1,firstName:!1,surname:!1,email:!1,emailInvalid:!1,phoneNumber:!1}},requestCall:{step:0,firstName:"",surname:"",email:"",phoneNumber:"",phoneNumberFull:"",phoneCountryCode:"",geoIpPhoneCode:"",membership:"",consent_news:!1,consentBulkEmail:"",consentBulkSMS:"",anythingElse:"",checkedInterests:[],errors:{selectClub:!1,firstName:!1,surname:!1,email:!1,emailInvalid:!1,phoneNumber:!1,membership:!1}},callUs:{step:0,errors:{selectClub:!1}}},gaRef:"none",routeType:{booktour:"bookTour",requestcall:"requestCall",callus:"callUs"}})),n=e=>u(e).day()===0||u(e).day()===6;return i(()=>s.value.enquiry.bookTour.tourDate,(e,a)=>{if(!a||a==="")s.value.enquiry.bookTour.tourTime="";else if(e&&a){const o=n(e),t=n(a);o!==t&&(s.value.enquiry.bookTour.tourTime="")}}),s},N=async()=>{var e;const s=await C(),n=y();return(e=n.value)!=null&&e.selectedClub?s.find(a=>k(a.data.internal_club_code)===n.value.selectedClub):{}};export{g as a,q as b,N as c,y as u};