1import{_ as Kt}from"./FallbackImg.vue.58b9d284.js";import{s as Y,k as we,t as ue,r as ie,q as I,g as z,m as Te,R as dt,d as pe,b as ut,Q as Qt,u as Se,v as Ce,M as Oe,f as Ue,L as Be,T as qe,I as Xt,n as Je,ad as $e,o as Zt,a as pt,F as eo,e as _t,A as mt,_ as vt,af as to,P as oo}from"./entry.363f673c.js";import{j as E,k as X,R as d,S as M,F as Le,aa as Ne,Y as U,u as e,U as t,A as o,Z as r,a0 as no,X as W,a as V,m as lt,ac as Ge,ad as Ve,a2 as it,_ as h,W as N,E as Ke,a9 as De,a4 as rt,a3 as Fe,b as ao,n as so,ab as ht,$ as lo}from"./swiper-vue.2af9d341.js";import{_ as io}from"./Checkbox.3a797ff3.js";import{_ as ro}from"./SwitchStation.a1bd3637.js";import{a as ye,_ as ft}from"./FormWrapper.39dbf8ad.js";import{u as gt,_ as wt,a as $t,b as co,c as uo,d as po}from"./DestinationModal.17720d6a.js";import{u as Ae,a as ct}from"./useTrainFunction.629a7aa4.js";import{_ as Qe}from"./index.6bcde493.js";import{_ as Xe}from"./client-only.0924ad74.js";import{_ as _o,u as mo,a as vo}from"./MobileFormSearchFlight.f534b93b.js";import{u as yt}from"./usePlusMinusGuest.5b4449f5.js";import{a as Ze,_ as bt}from"./index.3472d536.js";import{a as ho}from"./useFlightFunction.2563a6ba.js";import{e as ke}from"./popper.esm.01f09b33.js";import{c as fo,_ as go,a as wo,d as $o,b as yo,u as bo}from"./useSeachHotelHistory.c6564366.js";import{u as Co}from"./index.esm.fd4742cc.js";import{_ as Do,u as ko,a as So,b as xo,c as Mo,d as Fo}from"./MobilePassengerForm.b4a4d52a.js";import{_ as Ao}from"./ListModal.vue.67d58b76.js";const To={class:"form-search-tab-container"},Oo=["onClick"],Po={class:"image-wrapper"},Ho={class:"tab-title"},Io=E({__name:"FormSearchTab",props:{menuBadges:{}},setup(m){const{tabListMenu:c,activeTab:g}=Y(we()),{selectedFirstDate:k,selectedSecondDate:f}=Y(ue()),{updateCalendarStore:p}=ie(),x=m,w=X(()=>{var v,H;return((H=(v=x.menuBadges)==null?void 0:v.find(n=>n.context==="mainMenu"))==null?void 0:H.items)||[]}),$=v=>w.value.find(H=>H.type===v)||null,l=v=>{const{text_color:H,bg_color:n}=v.style,_={DEFAULT:"to right",GRADIENT_TO_RIGHT:"to right",GRADIENT_TO_LEFT:"to left",GRADIENT_TO_TOP:"to top",GRADIENT_TO_BOTTOM:"to bottom"},S=[`rgba(${n.startColor})`];return Array.isArray(n.viaColor)&&n.viaColor.length&&S.push(...n.viaColor.map(O=>`rgba(${O})`)),S.push(`rgba(${n.endColor})`),{color:H,background:`linear-gradient(${_[n.type]||"to right"}, ${S.join(", ")})`}}
1,i=v=>{g.value=v,k.value=I().format("YYYY-MM-DD"),f.value=I(k.value).add(1,"day").format("YYYY-MM-DD"),p()};return(v,H)=>{const n=Kt;return d(),M("div",To,[(d(!0),M(Le,null,Ne(e(c),_=>{var S,O;return d(),M("button",{key:_.label,class:U(e(g)===_.value?"active-tab":""),onClick:F=>i(_.value)},[t("div",Po,[o(n,{src:_.icon.web,alt:_.value,class:"tw-w-auto"},null,8,["src","alt"])]),t("span",Ho,r(v.$t(`${_.value}.type`)),1),(S=$(_.value))!=null&&S.label?(d(),M("span",{key:0,class:"discount-badge",style:no(l($(_.value)))},r((O=$(_.value))==null?void 0:O.label),5)):W("",!0)],10,Oo)}),128))])}}});const $l=z(Io,[["__scopeId","data-v-27e4f3cb"]]),Ro=m=>(Ge("data-v-1726b9f9"),m=m(),Ve(),m),Yo={class:"flight-trip-option"},Lo=Ro(()=>t("div",{class:"tw-border tw-border-r tw-h-[24px]"},null,-1)),No={class:"tw-w-fit"},Bo=E({__name:"TripOptionFlight",setup(m){const{isRoundTrip:c,isSeatDistancing:g}=Y(Te()),k=V([]),f=p=>{if(k.value=p,!p.length){g.value=1;return}g.value=2};return(p,x)=>{const w=dt,$=io;return d(),M("div",Yo,[o(w,{modelValue:e(c),"onUpdate:modelValue":x[0]||(x[0]=l=>lt(c)?c.value=l:null),name:"trip-option",value:2,label:p.$t("general.roundTrip"),isChecked:e(c)===2,labelStyle:"tw-text-sm tw-text-charcoal",class:"hover:tw-bg-transparent"},null,8,["modelValue","label","isChecked"]),o(w,{modelValue:e(c),"onUpdate:modelValue":x[1]||(x[1]=l=>lt(c)?c.value=l:null),name:"trip-option",value:1,label:p.$t("general.oneWay"),isChecked:e(c)===1,labelStyle:"tw-text-sm tw-text-charcoal",class:"hover:tw-bg-transparent"},null,8,["modelValue","label","isChecked"]),Lo,t("div",No,[o($,{image:!1,items:[{value:2,label:p.$t("flight.freeReschedule")}],selectedValues:e(k),onUpdate:f,hoverClass:"tw-p-0"},null,8,["items","selectedValues"])])])}}});const Go=z(Bo,[["__scopeId","data-v-1726b9f9"]]),Vo={class:"destination-form-input"},Wo={class:"destination-form-content"},zo={class:"form-label"},Eo={class:"destination-name tw-mt-2 tw-text-start tw-max-w-[150px] tw-h-[18px] tw-truncate"},jo={class:"tw-flex tw-flex-1 tw-gap-2"},Uo={class:"form-label"},qo={class:"arrival-name tw-mt-2 tw-text-start tw-max-w-[150px] tw-h-[18px] tw-truncate"},Jo=E({__name:"DestinationFormContent",props:{destinationName:{type:String,default:""},destinationLabel:{type:String,default:""},destinationCode:{type:String,default:""},arrivalName:{type:String,default:""},arrivalLabel:{type:String,default:""},arrivalCode:{type:String,default:""},isDestinationActive:{type:Boolean,default:!1},isArrivalActive:{type:Boolean,default:!1}},setup(m){return(c,g)=>{const k=ro;return d(),M("div",Vo,[t("div",Wo,[t("div",{class:"tw-w-[45%] tw-cursor-pointer",onClick:g[0]||(g[0]=f=>c.$emit("clickDestination"))},[t("div",{class:U(["flex-column form-item",m.isDestinationActive?"tw-bg-white-smoke":""])},[t("p",zo,r(m.destinationLabel),1),t("p",Eo,[it(r(m.destinationName)+" ",1),t("span",null,r(m.destinationCode),1)])],2)]),t("div",jo,[o(k,{onClick:g[1]||(g[1]=f=>c.$emit("switch"))}),t("div",{class:"tw-flex-1 tw-cursor-pointer",onClick:g[2]||(g[2]=f=>c.$emit("clickArrival"))},[t("div",{class:U(["flex-column form-item",m.isArrivalActive?"tw-bg-white-smoke":""])},[t("p",Uo,r(m.arrivalLabel),1),t("p",qo,[it(r(m.arrivalName)+" ",1),t("span",null,r(m.arrivalCode),1)])],2)])])])])}}});const Ct=z(Jo,[["__scopeId","data-v-b8923d29"]]),Ko={class:"flight-destination-form"},Qo=["onClick"],Xo=E({__name:"DestinationFormFlight",props:{openModal:{type:Boolean,default:!1},openModalArrival:{type:Boolean,default:!1},lastSearch:{type:Array,default:[]}},setup(m){const{formState:c}=Y(Te()),{searchInputDestination:g,autoCompleteResult:k}=Y(we()),{highlightText:f}=Ae(),{clearDepartureHistory:p,clearDestinationHistory:x}=gt(),w=V(c.value.arrival.airport.replace(/\s?\(.*?\)/g,"")),$=V(c.value.departure.airport.replace(/\s?\(.*?\)/g,"")),l=m,i=()=>{[c.value.departure,c.value.arrival]=[c.value.arrival,c.value.departure],w.value=c.value.arrival.airport.replace(/\s?\(.*?\)/g,""),$.value=c.value.departure.airport.replace(/\s?\(.*?\)/g,"")},v=X(()=>{const n=[];return k.value.forEach(_=>{n.push({..._,_isChild:!1}),_.child&&_.child.length>0&&_.child.forEach(S=>{n.push({...S,_isChild:!0})})}),n}),H=()=>{l.openModal&&p(),l.openModalArrival&&x()};return(n,_)=>{const S=Ct,O=ye,F=pe,P=wt,q=$t;return d(),M("div",Ko,[o(O,{label:n.$t("general.departureFrom"),class:"flight-destination-form-wrapper"},{"form-content":h(()=>[o(S,{"destination-label":n.$t("general.departureFrom"),"destination-name":e(c).departure.airport,"destination-code":e(c).departure.code,"arrival-label":n.$t("general.yourDestination"),"arrival-name":e(c).arrival.airport,"arrival-code":e(c).arrival.code,onSwitch:_[0]||(_[0]=R=>i()),onClickDestination:_[1]||(_[1]=R=>n.$emit("clickDestination")),onClickArrival:_[2]||(_[2]=R=>n.$emit("clickArrival")),isDestinationActive:m.openModal,isArrivalActive:m.openModalArrival},null,8,["destination-label","destination-name","destination-code","arrival-label","arrival-name","arrival-code","isDestinationActive","
1isArrivalActive"])]),_:1},8,["label"]),m.openModal||m.openModalArrival?(d(),N(q,{key:0,lastSearch:m.lastSearch,onSearch:_[3]||(_[3]=R=>n.$emit("onSearch",R)),onHandleRemoveLastSearch:_[4]||(_[4]=R=>H()),openModal:m.openModal,openModalArrival:m.openModalArrival},{"list-search":h(()=>[(d(!0),M(Le,null,Ne(e(v),(R,Z)=>(d(),M("div",{key:Z},[t("div",{class:U(["hover:tw-bg-white-smoke hover:tw-cursor-pointer",R._isChild?"tw-pl-8":"",Z===e(v).length-1?"tw-rounded-b-xl tw-pb-1":""]),onClick:J=>n.$emit("choose",R)},[o(P,{name:e(f)(`${R.city_name+", "+R.country_name}`,e(g)),city:e(f)(R.type==="city"?n.$t("bookingCheck.allAirport"):R.airport_name,e(g)),code:R.type==="city"?n.$t("general.all"):R.airport_code,onClick:J=>n.$emit("handleChooseAirport",R)},{icon:h(()=>[o(F,{src:"/icon/Airport.svg",class:"tw-w-5 tw-h-5",alt:"flight-airport"})]),_:2},1032,["name","city","code","onClick"])],10,Qo)]))),128))]),_:1},8,["lastSearch","openModal","openModalArrival"])):W("",!0)])}}});const Zo=z(Xo,[["__scopeId","data-v-fb2e33c2"]]),en={class:"form-label"},tn={class:"passenger-label"},on=E({__name:"PassengerFormContent",props:{active:{type:Boolean,default:!1},label:{type:String,default:""},value:{type:String,default:!1}},setup(m){return(c,g)=>(d(),M("div",{class:U(["passenger-form-content flex-column tw-text-start",m.active?"tw-bg-white-smoke":""])},[t("p",en,r(m.label),1),t("p",tn,r(m.value),1)],2))}});const Dt=z(on,[["__scopeId","data-v-05440ab1"]]),nn={class:"train-passenger-form"},an=E({__name:"PassengerFormFlight",props:{openModal:{type:Boolean,default:!1},formPassanger:{type:String,default:"1 Penumpang, Ekonomi"}},setup(m){yt(),ie();const c=Te();return Y(c),(g,k)=>{const f=Dt,p=ye,x=_o;return d(),M("div",nn,[o(p,{label:g.$t("general.passenger"),onClick:k[0]||(k[0]=w=>g.$emit("open"))},{"form-content":h(()=>[o(f,{active:m.openModal,label:g.$t("flight.passengerAndClass"),value:m.formPassanger},null,8,["active","label","value"])]),_:1},8,["label"]),m.openModal?(d(),N(x,{key:0,class:"tw-z-10 tw-absolute",onHandleSave:k[1]||(k[1]=w=>g.$emit("handleSaveValuePassenger",w)),isOpen:m.openModal},null,8,["isOpen"])):W("",!0)])}}});const sn=z(an,[["__scopeId","data-v-1d7ea655"]]),ln={key:0,class:"button-text lg:tw-flex"},rn=E({__name:"SearchButton",props:{buttonHeight:{type:String,default:"tw-h-[65px]"},buttonText:{type:String,default:""}},setup(m){return(c,g)=>{const k=pe;return d(),M("button",{onClick:g[0]||(g[0]=f=>c.$emit("search")),class:U(["search-button",m.buttonHeight])},[o(k,{src:"/images/general/icon/form/search_icon.svg",width:"15px",height:"15px",class:"tw-flex-shrink-0",alt:"search_icon"}),m.buttonText?(d(),M("p",ln,r(m.buttonText),1)):W("",!0)],2)}}});const et=z(rn,[["__scopeId","data-v-e41ac343"]]),tt=m=>(Ge("data-v-72c63c24"),m=m(),Ve(),m),cn={class:"flight-form-search tw-relative"},dn={class:"flight-form-wrapper"},un={class:"flight-date-form"},pn={class:"tw-flex"},_n={class:"tw-text-start tw-cursor-pointer"},mn={class:"tw-mt-1"},vn={class:"tw-text-base tw-whitespace-nowrap tw-font-bold"},hn=tt(()=>t("div",{class:"tw-self-center tw-bg-gainsboro tw-w-2 tw-h-[1px]"},null,-1)),fn={class:"tw-text-start tw-cursor-pointer"},gn={class:"tw-mt-1"},wn={key:0,class:"tw-text-base tw-whitespace-nowrap tw-font-bold"},$n={key:1,class:"tw-text-base tw-font-bold tw-w-full tw-text-N400"},yn={class:"booking-date-header"},bn={class:"booking-date-title"},Cn={class:"booking-date-header"},Dn={class:"booking-date-title"},kn={class:"flex-column tw-gap-6"},Sn=tt(()=>t("div",{class:"border-bottom tw-my-0"},null,-1)),xn={class:"tw-grid tw-grid-cols-2 tw-gap-3"},Mn=["onClick"],Fn={class:"tw-text-white tw-text-sm tw-font-bold"},An={class:"tw-flex tw-items-center tw-gap-3"},Tn={class:"tw-font-bold"},On={class:"tw-sticky tw-top-0 tw-bg-white tw-px-5"},Pn={class:"input-search-flight-mobile"},Hn={key:0,class:"tw-px-5"},In={key:0,class:"last-search-mobile"},Rn={key:0,class:"tw-flex tw-justify-between tw-my-5"},Yn={class:"tw-font-bold tw-text-sm tw-text-charcoal"},Ln={key:1,class:"tw-py-5 tw-px-6"},Nn={key:2},Bn=tt(()=>t("div",{class:"border-bottom"},null,-1)),Gn={class:"tw-text-start tw-mb-5 tw-font-bold tw-text-sm tw-text-charcoal"},Vn={key:1,class:"tw-mt-3 tw-px-5"},Wn=["onClick"],zn={class:"flex-column tw-justify-center tw-gap-3 tw-text-center"},En={class:"tw-font-bold tw-text-18 tw-text-neutral-N700"},jn={class:"tw-text-base tw-text-neutral-N500 tw-mb-3"},Un={class:"tw-font-bold tw-text-base"},qn={class:"m-modal-detail-search tw-z-10 tw-p-5"},Jn={class:"flex-column tw-gap-3 tw-text-center"},Kn={class:"tw-font-bold tw-text-base lg:tw-text-18 tw-text-neutral-N700"},Qn={class:"tw-text-sm lg:tw-text-base tw-text-neutral-N500 tw-mb-3"},Xn={class:"tw-font-bold tw-text-base"},Zn=E({__name:"Index",setup(m){const c=ut(),g=Qt(),{locale:k,t:f}=Se(),{pushSearchEvent:p,buildContentId:x}=qe(),{isRoundTrip:w,isSeatDistancing:$,formState:l,tempFlightPassenger:i,flightClass:v,popularList:H,mobileOpenPassenger:n,mobileOpenDatePicker:_,openModalOrigin:S,openM
1odalArrival:O,mobileOpenDestination:F,mobileOpenArrival:P,flightDepartureLastSearch:q,flightDestinationLastSearch:R}=Y(Te()),{removeBodyClass:Z,arrayToUrlStr:J,handleRedirect:de,formatClass:se,getDateFormat:ee,isAirportCheck:L}=ie(),{handleMinus:y,handlePlus:te}=mo(),{saveDepartureHistory:oe,saveDestinationHistory:ae,hydrateFromStorage:_e,clearDepartureHistory:re,clearDestinationHistory:G,saveLastSearch:b}=gt(),{selectedFirstDate:u,selectedSecondDate:A,openDepartCalendar:C,openReturnCalendar:B}=Y(ue()),T=we(),{onSearchFlight:ce}=ho(),{highlightText:le}=Ae(),me=X(()=>S.value||F.value?q.value??[]:R.value??[]),ne=V(!1);V(!1);const j=X(()=>l.value.adult+l.value.infant+l.value.child),be=V();be.value=`${j.value} ${f("general.passenger",j.value)}, ${se(l.value.classFlight)}`;const ve=V(!1),xe=V({airport_name:"",airport_code:"",type:"city",city_code:"",city_name:"",country_name:null,ref:"",airport_codes:[],timezone:"",child:[],country_code:""}),Me=V({airport_name:"",airport_code:"",type:"city",city_code:"",city_name:"",country_name:null,ref:"",airport_codes:[],timezone:"",child:[],country_code:""});Ke(()=>{_e()});const K=s=>{var fe;const a=s.mpf_destination_city_name.split(" - ")[0],Q=s.mpf_destination_city_code,he=(fe=L(s.mpf_destination_city_code))==null?void 0:fe.country_code;F.value&&(l.value.departure.airport=a,l.value.departure.code=Q,l.value.departure.country_code=he,S.value=!1,oe({code:Q,type:"airport",city:a,country_code:he,name:a}),Pe()),P.value&&(l.value.arrival.airport=a,l.value.arrival.code=Q,l.value.arrival.country_code=he,O.value=!1,ae({code:Q,type:"airport",city:a,country_code:he,name:a}),Pe())},Pe=()=>{F.value=!1,P.value=!1},kt=s=>{if(S.value){l.value.departure={airport:s.city_name,code:s.airport_code,country_code:s.country_code,type:s.type},xe.value=s,S.value=!1,F.value=!1,T.autoCompleteResult=[],T.searchInputDestination="";const Q={code:s.airport_code,type:s.type,city:s.city_name,country_code:s.country_code,name:s.airport_name||""};oe(Q);return}l.value.arrival={airport:s.city_name,code:s.airport_code,country_code:s.country_code,type:s.type},Me.value=s,T.searchInputDestination="",O.value=!1,P.value=!1,T.autoCompleteResult=[];const a={code:s.airport_code,type:s.type,city:s.city_name,country_code:s.country_code,name:s.airport_name||""};ae(a)},St=s=>{if(F.value){l.value.departure={airport:s.city_name,code:s.airport_code,country_code:s.country_code,type:s.type},xe.value=s,T.searchInputDestination="",S.value=!1,F.value=!1,T.autoCompleteResult=[];const Q={code:s.airport_code,type:s.type,city:s.city_name,country_code:s.country_code,name:s.airport_name||""};oe(Q);return}l.value.arrival={airport:s.city_name,code:s.airport_code,country_code:s.country_code,type:s.type},Me.value=s,T.searchInputDestination="",O.value=!1,P.value=!1,T.autoCompleteResult=[];const a={code:s.airport_code,type:s.type,city:s.city_name,country_code:s.country_code,name:s.airport_name||""};ae(a)},xt=()=>{w.value=2;const s=I(u.value),Q=I().startOf("day").add(364,"day");s.isSame(Q,"day")?A.value=s.format("YYYY-MM-DD"):A.value=s.add(1,"day").format("YYYY-MM-DD")},Mt=s=>{s&&Z(),ne.value=!1,S.value=!1,B.value=!1,C.value=!1,O.value=!1},Ft=()=>{C.value=!0,B.value=!1,O.value=!1,ne.value=!1,S.value=!1},At=()=>{B.value=!0,C.value=!1,O.value=!1,C.value=!1,ne.value=!1,S.value=!1,w.value===1&&(w.value=2)},Tt=()=>{S.value=!0,T.autoCompleteResult=[],T.searchInputDestination="",O.value=!1,C.value=!1,B.value=!1,ne.value=!1,T.selectAllTextValue("#search-input")},Ot=()=>{O.value=!0,T.autoCompleteResult=[],T.searchInputDestination="",S.value=!1,C.value=!1,B.value=!1,ne.value=!1,T.selectAllTextValue("#search-input")},Pt=()=>{F.value=!F.value,T.autoCompleteResult=[],T.searchInputDestination=""},Ht=()=>{P.value=!P.value,T.autoCompleteResult=[],T.searchInputDestination=""},We=()=>{n.value=!n.value,n.value?setTimeout(()=>{Z()},50):(i.value.adult=l.value.adult,i.value.child=l.value.child,i.value.infant=l.value.infant,i.value.flightClass=l.value.classFlight)},It=()=>{_.value=!_.value,w.value===1&&(A.value="")},Rt=()=>{ne.value=!ne.value,i.value.adult=l.value.adult,i.value.child=l.value.child,i.value.infant=l.value.infant,i.value.flightClass=l.value.classFlight,S.value=!1,B.value=!1,C.value=!1,O.value=!1},ot=s=>{l.value={...l.value,...s},be.value=`${j.value} ${f("general.passenger",j.value)}, ${se(l.value.classFlight)}`,n.value=!1,ne.value=!1},Yt=s=>{i.value.flightClass=s},Lt=X(()=>!!Object.keys(c.query).length),nt=X(()=>{const s=[];return T.autoCompleteResult.forEach(a=>{s.push({...a,_isChild:!1}),a.child&&a.child.length>0&&a.child.forEach(Q=>{s.push({...Q,_isChild:!0})})}),s}),at=()=>{const s=l.value.departure.country_code!=="ID"||l.value.arrival.country_code!=="ID",a={flight_origin:l.value.departure.code,flight_destination:l.value.arrival.code,flight_departure:u.value,flight_return:w.value===2?A.value:"",flight_is_round_trip:w.value===2,flight_class:l.value.classFlight,flight_adult:String(l.value.adult),flight_child:String(l.value.child),flight_infant:String(l.value.infant),isInternationalFlight:String(s),isCombo:String(s),isSeatDistancing:String($.value===2),flight_origin_type:l.value.departure.type,flight_destination_type:l.value.arrival.type,flightDepartureName:l.value.departure.airport,flightArrivalName:l.value.arrival.airport};p({content_category:"flight",content_ids:x("flight",a.flight_origin,a.flight_destination),origin:a.flight_origin,destination:a.flight_destination,travel_date:a.flight_departure,content_name:`${a.flightDepartureName} (${a.flight_origin}) - ${a.flightArrivalName} (${a.flight_destination})`}),b({...a,flightDepartureAirportName:xe.value.airport_name,flightArrivalAirportName:Me.value.airport_name});const{flightDepartureName:Q,flightArrivalName:he,...fe}=a,ge={...fe,depLabel:Q,arrLabel:he};if(Lt.value)g.replace({path:c.path,query:{...c.query,...ge}}).then(()=>{window.location.reload()});else{if(l.value.departure.code===l.value.arrival.code){ve.value=!0;return}const He=J(ge);de(`/${k.value}/flight/search?${He}`)}},Nt=()=>{F.value&&re(),P.value&&G()};return(s,a)=>{const Q=Go,he=Zo,fe=ft,ge=Qe,He=Xe,Bt=ye,Gt=sn,Vt=et,Wt=vo,Ie=pe,zt=Ze,Re=Oe,ze=bt,Ee=Ue,Et=co,jt=uo,Ut=po,qt=wt,Jt=Be;return d(),M("div",null,[t("div",cn,[o(Q,{class:"tw-hidden lg:tw-flex tw-mb-3"}),De((d(),M("div",dn,[o(he,{class:"tw-w-[450px]",openModal:e(S),onClickDestination:a[0]||(a[0]=D=>Tt()),onClickArrival:a[1]||(a[1]=D=>Ot()),lastSearch:e(me),openModalArrival:e(O),onOnSearch:a[2]||(a[2]=D=>e(ce)(D)),onHandleChooseAirport:a[3]||(a[3]=D=>kt(D)),popularDestination:e(H),labelDestination:s.$t("general.departureFrom"),labelArrival:s.$t("general.yourDestination")},null,8,["openModal","lastSearch","openModalArrival","popularDestination","labelDestination","labelArrival"]),t("div",un,[o(Bt,{class:""},{"form-content":h(()=>[t("div",pn,[t("div",{class:U(["date-time-airport-form",e(C)?"tw-bg-white-smoke":""]),onClick:a[4]||(a[4]=D=>Ft())},[o(fe,{label:s.$t("general.departure")},null,8,["label"]),o(He,null,{default:h(()=>[(d(),N(rt,null,[t("div",_n,[o(e(ke),{class:"poper-container",show:e(C)},{content:h(()=>[e(C)?(d(),N(ge,{key:0,class:"departure-datepicker",openCalender:e(C),columns:2,"
1step-two":!1,"is-round-trip":e(w)===2?2:1},null,8,["openCalender","is-round-trip"])):W("",!0)]),default:h(()=>[t("div",mn,[t("p",vn,r(e(I)(e(u)).format(e(ee)("format12"))),1)])]),_:1},8,["show"])])],1024))]),_:1})],2),hn,t("div",{class:U(["date-time-airport-form",e(B)?"tw-bg-white-smoke":""]),onClick:a[5]||(a[5]=D=>At())},[o(fe,{label:s.$t("general.return")},null,8,["label"]),o(He,null,{default:h(()=>[(d(),N(rt,null,[t("div",fn,[o(e(ke),{class:"poper-container",show:e(B)},{content:h(()=>[e(B)?(d(),N(ge,{key:0,class:"arrival-datepicker",openCalender:e(B),columns:2,"step-two":!0,"is-round-trip":2},null,8,["openCalender"])):W("",!0)]),default:h(()=>[t("div",gn,[e(w)===2?(d(),M("p",wn,r(e(I)(e(A)).format(e(ee)("format12"))),1)):(d(),M("p",$n,r(s.$t("general.add")),1))])]),_:1},8,["show"])])],1024))]),_:1})],2)])]),_:1})]),o(Gt,{class:"tw-w-[254px] tw-cursor-pointer",openModal:e(ne),onOpen:a[6]||(a[6]=D=>Rt()),onHandleSaveValuePassenger:a[7]||(a[7]=D=>ot(D)),formPassanger:e(be)},null,8,["openModal","formPassanger"]),o(Vt,{buttonText:s.$t("general.searchButton"),class:"",onSearch:a[8]||(a[8]=D=>at())},null,8,["buttonText"])])),[[e(Ce),Mt]])]),o(Wt,{class:"lg:tw-hidden",onOpenModalDatePicker:a[9]||(a[9]=D=>It()),onOpenModalPassanger:a[10]||(a[10]=D=>We()),formPassanger:e(be),firstDate:e(u),secondDate:e(A),onOpenModalDestination:a[11]||(a[11]=D=>Pt()),onOpenModalArrival:a[12]||(a[12]=D=>Ht()),onOnSearchMobile:a[13]||(a[13]=D=>at())},null,8,["formPassanger","firstDate","secondDate"]),o(Re,{useOverlay:"",open:e(_),topRadius:!0},{headers:h(()=>[t("div",yn,[o(Ie,{src:"/icon/close.svg",alt:"close",class:"close-icon",onClick:a[14]||(a[14]=D=>_.value=!1)}),t("p",bn,r(s.$t("general.setDate")),1)])]),content:h(()=>[t("div",{onClick:a[17]||(a[17]=Fe(()=>{},["stop"])),class:"tw-h-[80dvh] m-modal-content tw-pt-0"},[o(zt,{originLabel:s.$t("general.departure"),arrivalLabel:s.$t("general.return"),isRoundTrip:e(w)===2,useHighlight:!1,onChangeTrip:a[15]||(a[15]=D=>xt()),onSaveDate:a[16]||(a[16]=D=>_.value=!1)},null,8,["originLabel","arrivalLabel","isRoundTrip"])])]),_:1},8,["open"]),o(Re,{useOverlay:"",open:e(n),topRadius:!0,onClose:a[27]||(a[27]=D=>We())},{headers:h(()=>[t("div",null,[t("div",Cn,[o(Ie,{src:"/icon/close.svg",alt:"false",class:"close-icon",onClick:a[18]||(a[18]=D=>We())}
1),t("p",Dn,r(s.$t("flight.setPassengerAndClass")),1)])])]),content:h(()=>[t("div",{onClick:a[26]||(a[26]=Fe(()=>{},["stop"])),class:"m-modal-content tw-pt-0"},[t("div",kn,[o(ze,{key:"room-item",label:`${s.$t("flight.adultWithAge")}`,numberToAdd:e(i).adult,onClickMin:a[19]||(a[19]=D=>e(y)("adult")),onClickPlus:a[20]||(a[20]=D=>e(te)("adult")),isDisableMinus:e(i).adult===1,isDisablePlus:e(i).child+e(i).adult==7},null,8,["label","numberToAdd","isDisableMinus","isDisablePlus"]),o(ze,{key:"room-item",label:`${s.$t("flight.childWithAge")}`,numberToAdd:e(i).child,onClickMin:a[21]||(a[21]=D=>e(y)("child")),onClickPlus:a[22]||(a[22]=D=>e(te)("child")),isDisableMinus:e(i).child===0,isDisablePlus:e(i).child+e(i).adult==7},null,8,["label","numberToAdd","isDisableMinus","isDisablePlus"]),o(ze,{key:"room-item",label:`${s.$t("flight.infantWithAge")}`,numberToAdd:e(i).infant,onClickMin:a[23]||(a[23]=D=>e(y)("infant")),onClickPlus:a[24]||(a[24]=D=>e(te)("infant")),isDisableMinus:e(i).infant===0,isDisablePlus:e(i).infant===4||e(i).infant===e(i).adult},null,8,["label","numberToAdd","isDisableMinus","isDisablePlus"]),Sn,t("div",xn,[(d(!0),M(Le,null,Ne(e(v),(D,Ye)=>{var je,st;return d(),M("div",{class:U(["tw-p-2 tw-border tw-rounded-4 tw-flex tw-justify-center tw-items-center",D.value==((je=e(i))==null?void 0:je.flightClass)?"tw-border-shapphire-blue":"tw-border-blue-gray"]),key:Ye,onClick:el=>Yt(D.value)},[t("p",{class:U(["tw-text-sm tw-font-normal",D.value==((st=e(i))==null?void 0:st.flightClass)?"tw-text-shapphire-blue":""])},r(D.label),3)],10,Mn)}),128))]),o(Ee,{size:"lg",onClick:a[25]||(a[25]=D=>ot({adult:e(i).adult,child:e(i).child,infant:e(i).infant,classFlight:e(i).flightClass}))},{content:h(()=>[t("p",Fn,r(s.$t("general.save")),1)]),_:1})])])]),_:1},8,["open"]),o(Re,{useOverlay:"",open:e(F)||e(P),onClose:a[33]||(a[33]=D=>Pe()),topRadius:!0},{headers:h(()=>[t("div",null,[t("div",An,[o(Ie,{src:"/icon/close.svg",alt:"close",width:"14",class:"close-icon",onClick:a[28]||(a[28]=D=>Pe())}),t("p",Tn,r(e(f)("bookingCheck.selectCityOrAirport")),1)])])]),content:h(()=>[t("div",{onClick:a[32]||(a[32]=Fe(()=>{},["stop"])),class:"tw-overflow-y-auto tw-h-[calc(80vh-40px)]"},[t("div",On,[t("div",Pn,[o(Et,{placeholder:s.$t("general.placeholder.hotel.inputSearch"),onSearch:a[29]||(a[29]=D=>e(ce)(D))},null,8,["placeholder"])])]),e(T).autoCompleteResult.length<=0?(d(),M("div",Hn,[e(T).searchInputDestination.length<3?(d(),M("div",In,[e(me).length>0?(d(),M("div",Rn,[t("p",Yn,r(s.$t("general.recentSearch")),1),t("p",{class:"tw-font-bold tw-text-sm tw-text-shapphire-blue",onClick:a[30]||(a[30]=D=>Nt())},r(s.$t("general.clear")),1)])):W("",!0),o(jt,{lastSearch:e(me)},null,8,["lastSearch"])])):e(T).searchInputDestination.length>=3&&!e(T).autoCompleteResult.length&&!e(T).onSearchAutoComplete?(d(),M("p",Ln,r(s.$t("general.searchNotFound")),1)):W("",!0),e(T).autoCompleteResult.length<=0&&e(T).searchInputDestination.replace(/\s/g,"").length===0?(d(),M("div",Nn,[Bn,t("div",null,[t("p",Gn,r(s.$t("general.popularDestination")),1),o(Ut,{onChoose:a[31]||(a[31]=D=>K(D))})])])):W("",!0)])):(d(),M("div",Vn,[(d(!0),M(Le,null,Ne(e(nt),(D,Ye)=>(d(),M("div",{key:Ye,onClick:je=>St(D),class:U(["lg:hover:tw-bg-white-smoke hover:tw-cursor-pointer",D._isChild?"tw-pl-8":"",Ye===e(nt).length-1?"tw-pb-1":""])},[t("div",null,[o(qt,{class:"tw-mx-0",name:e(le)(`${D.city_name+", "+D.country_name}`,e(T).searchInputDestination),city:e(le)(D.type==="city"?s.$t("bookingCheck.allAirport"):D.airport_name,e(T).searchInputDestination),code:D.type==="city"?s.$t("general.all"):D.airport_code},{icon:h(()=>[o(Ie,{src:"/icon/Airport.svg",class:"tw-w-5 tw-h-5",alt:"flight-airport"})]),_:2},1032,["name","city","code"])])],10,Wn))),128))]))])]),_:1},8,["open"]),o(Jt,{isOpen:e(ve),header:!1,footer:!1,class:"tw-hidden lg:tw-block no-scrollbar",id:"modal-same-destination"},{description:h(()=>[t("div",zn,[t("p",En,r(s.$t("flight.confirmationChangeSelected")),1),t("p",jn,r(s.$t("flight.confirmationChangeSelectedDesc")),1),o(Ee,{onClick:a[34]||(a[34]=D=>ve.value=!1)},{content:h(()=>[t("p",Un,r(s.$t("general.edit")),1)]),_:1})])]),_:1},8,["isOpen"]),o(Re,{useOverlay:"",open:e(ve),topRadius:!0,header:!1},{content:h(()=>[t("div",qn,[t("div",Jn,[t("p",Kn,r(s.$t("flight.confirmationChangeSelected")),1),t("p",Qn,r(s.$t("flight.confirmationChangeSelectedDesc")),1
1),o(Ee,{onClick:a[35]||(a[35]=D=>ve.value=!1),size:"md"},{content:h(()=>[t("p",Xn,r(s.$t("general.edit")),1)]),_:1})])])]),_:1},8,["open"])])}}});const ea=z(Zn,[["__scopeId","data-v-72c63c24"]]),ta={class:"hotel-form-search tw-relative"},oa={class:"form-size tw-relative"},na={class:"tw-mt-1 tw-hidden lg:tw-block"},aa={class:"tw-flex tw-items-center tw-gap-2"},sa={class:"tw-truncate tw-text-base tw-font-bold tw-mt-0.5"},la={class:"lg:tw-hidden tw-text-start tw-flex tw-gap-2 tw-items-center tw-mt-2"},ia={class:"tw-font-bold tw-text-sm tw-text-charcoal tw-truncate"},ra={class:"form-size"},ca={class:"tw-flex tw-justify-between"},da={class:"tw-text-start"},ua={class:"tw-flex tw-items-center tw-gap-2 tw-mt-2"},pa={class:"tw-text-sm tw-font-bold tw-whitespace-nowrap"},_a={class:"tw-text-start"},ma={class:"tw-flex tw-items-center tw-gap-2 tw-mt-2"},va={class:"tw-text-sm tw-font-bold tw-whitespace-nowrap"},ha={class:"tw-flex"},fa={class:"hotel-form-chip"},ga={class:"chip-label"},wa={class:"checkin-date-header tw-pb-3"},$a={class:"checkin-date-title"},ya={class:"form-size guest-input-form tw-relative"},ba={class:"tw-flex tw-items-center tw-gap-2.5 tw-mt-2"},Ca={class:"guest-input-form-value"},Da={class:"m-modal-content tw-p-0 m-mobile-hotel-guest-modal-content"},ka={class:"checkin-date-header tw-px-5 tw-pt-5"},Sa={class:"checkin-date-title"},xa={class:"m-modal-content tw-p-0 m-mobile-hotel-guest-modal-content"},Ma={class:"tw-flex tw-px-5 tw-pt-5 tw-gap-3 tw-items-center"},Fa={class:"tw-text-neutral-N700 tw-text-base tw-font-bold"},Aa={class:""},Ta=E({__name:"Index",setup(m){const{$locally:c}=Xt(),{locale:g}=Se(),{pushSearchEvent:k,buildContentId:f}=qe(),{selectedFirstDate:p,selectedSecondDate:x,openDepartCalendar:w,openReturnCalendar:$}=Y(ue()),{removeBodyClass:l,arrayToUrlStr:i,getDateFormat:v}=ie(),{updateHotelLastSearch:H}=bo(),n=we(),_=V(Co.v1()),S=V(JSON.parse(c.getItem("btgv2_hotel_last_search")||"[]"));n.hotelLastSearch=S.value;const O=b=>{b&&l(),n.openHotelDestination=!1,n.openGuestSelection=!1,w.value=!1,$.value=!1},F=X(()=>{const b=I().add(1,"year").subtract(1,"day"),u=I(p.value).add(45,"day"),A=b.isBefore(u)?b:u;return I(A).format("YYYY-MM-DD")}),P=X(()=>
1{if($.value)return p.value;I().format("YYYY-MM-DD")});ao(()=>p.value,b=>{if(!b)return;I(x.value).diff(I(b),"day")>45&&(x.value=I(b).add(1,"day").format("YYYY-MM-DD"))});const q=()=>{n.openMobileSelectChildrenAge=!1,n.openGuestSelection=!0},R=b=>{n.hotelFormState.guest_children_ages[n.activeIndexSelectChildrenAge-1]=b,n.activeIndexSelectChildrenAge=0,n.openMobileSelectChildrenAge=!1,n.openGuestSelection=!0},Z=()=>{const{key:b,...u}=n.hotelFormState,A={...u,check_in:p.value,check_out:x.value,package_id:_.value},C={...u,check_in:p.value,check_out:x.value,package_id:_.value},B=(A==null?void 0:A.search_value.split("-").at(-1))||"";k({content_category:"hotel",content_ids:f("hotel",B),content_name:A==null?void 0:A.search_label,search_string:A==null?void 0:A.search_label}),H({search_value:C.search_value,search_label:C.search_label,search_type:C.search_type,check_in:C.check_in,check_out:C.check_out,guest_adult:C.guest_adult,guest_children:C.guest_children,guest_children_ages:C.guest_children_ages,total_room:C.total_room,package_id:C.package_id});const T=i(A),ce=`/${g.value}/hotel/${A.search_type==="HOTEL"?A.search_value:"search"}?${T}`;Je(ce)},J=async(b=!1,u)=>{if(n.openHotelDestination=!0,await so(),n.autoCompleteResult=[],n.searchInputDestination="",b){n.showMobileLastSeen=!0;return}else n.selectAllTextValue("#search-input");(!u.length||!n.hotelAutoComplete.length)&&(n.showLastSeen=!0),$.value=!1,w.value=!1,n.openGuestSelection=!1},de=()=>{w.value=!0,$.value=!1},se=()=>{$.value=!0,w.value=!1},ee=()=>{n.openGuestSelection=!0,n.openHotelDestination=!1,$.value=!1,w.value=!1},L=X(()=>I(x.value).diff(I(p.value),"day")),y=V(0);{let b=function(){y.value=window.innerWidth};b(),window.addEventListener("resize",b)}const te=()=>{n.openHotelDestination=!1},oe=()=>{n.openMobileCheckinDate=!1,n.openMobileCheckoutDate=!1,w.value=!1,$.value=!1},ae=()=>{n.openGuestSelection=!1},_e=()=>{y.value<1024&&(n.openMobileCheckoutDate=!0),n.openHotelDestination=!1,n.openGuestSelection=!1},re=V(["2023-12-22","2023-12-25","2023-12-26","2024-01-01","2024-02-08","2024-02-09","2024-02-10","2024-03-11","2024-03-12","2024-03-29","2024-04-08","2024-04-09","2024-04-10","2024-04-11","2024-04-12","2024-04-14","2024-04-15"]),G=V([{date:"2023-12-22",price:500,higlight:"cheapest"},{date:"2023-12-31",price:200,higlight:"cheapest"},{date:"2024-01-10",price:500,higlight:"normal"},{date:"2024-01-17",price:500,higlight:"normal"},{date:"2024-01-26",price:500,higlight:"cheapest"}]);return(b,u)=>{const A=pe,C=Xe,B=ye,T=fo,ce=go,le=Oe,me=ft,ne=Qe,j=Ze,be=wo,ve=$o,xe=yo,Me=et;return d(),M("div",null,[De((d(),M("div",ta,[t("div",oa,[t("div",{onClick:u[0]||(u[0]=K=>J(e(y)<=1024,e(n).hotelFormState.search_label)),class:"tw-cursor-pointer"},[o(B,{label:b.$t("hotel.destinationOrProperty"),isActive:e(n).openHotelDestination},{input:h(()=>[t("div",na,[o(C,null,{default:h(()=>[t("div",aa,[o(A,{src:"/images/general/icon/form/location.svg",alt:"location",width:"15",height:"15",class:"tw-flex-shrink-0"}),t("p",sa,r(e(n).hotelFormState.search_label),1)])]),_:1})]),t("div",la,[o(A,{src:"/images/general/icon/form/location.svg",alt:"location",width:"15",height:"15"}),t("p",ia,r(e(n).hotelFormState.search_label),1)])]),_:1},8,["label","isActive"])]),e(n).openHotelDestination&&e(y)>=1024?(d(),N(T,{key:0})):W("",!0),o(le,{open:e(n).openHotelDestination,topRadius:!0,header:!1,useOverlay:"",onClose:u[3]||(u[3]=K=>te())},{content:h(()=>[t("div",{class:"m-modal-content m-mobile-hotel-destination-modal-content",onClick:u[2]||(u[2]=Fe(()=>{},["stop"]))},[o(ce,{onClose:u[1]||(u[1]=K=>te())})])]),_:1},8,["open"])]),t("div",ra,[o(B,{onClick:u[6]||(u[6]=K=>_e()),class:"tw-cursor-pointer"},{"form-content":h(()=>[t("div",{class:U(["tw-m-1 tw-px-2 tw-py-[3px] tw-rounded-10",e(w)||e($)?"tw-bg-white-smoke":""])},[t("div",ca,[t("div",{class:"lg:tw-w-[124px]",onClick:u[4]||(u[4]=K=>de())},[o(me,{label:b.$t("hotel.checkin")},null,8,["label"]),o(C,null,{default:h(()=>[t("div",da,[o(e(ke),{show:e(w),class:"poper-container"},{content:h(()=>[e(w)?(d(),N(ne,{key:0,class:"tw-absolute tw-left-[-63px] tw-top-[-2px] tw-hidden lg:tw-block","holiday-date":e(re),openCalender:e(w),columns:2,"price-data":e(G),"step-two":!1,"is-round-trip":2}
1,null,8,["holiday-date","openCalender","price-data"])):W("",!0)]),default:h(()=>[t("div",ua,[o(A,{src:"/images/general/icon/form/datepicker_icon.svg",width:"15px",height:"15px",alt:"datepicker_icon"}),t("p",pa,r(e(I)(e(p)).format(e(v)("format12"))),1)])]),_:1},8,["show"])])]),_:1})]),t("div",{class:"lg:tw-w-[124px]",onClick:u[5]||(u[5]=K=>se())},[o(me,{label:b.$t("hotel.checkout")},null,8,["label"]),o(C,null,{default:h(()=>[t("div",_a,[o(e(ke),{show:e($),class:"poper-container"},{content:h(()=>[e($)?(d(),N(ne,{key:0,class:"tw-absolute tw-left-[-180px] tw-top-[-2px] tw-hidden lg:tw-block","holiday-date":e(re),openCalender:e($),columns:2,"price-data":e(G),"step-two":!0,"is-round-trip":2,"max-allowed-date":e(F),minAllowedDate:e(P),isSecondDateAllowedToSameWithFirstDate:!1},null,8,["holiday-date","openCalender","price-data","max-allowed-date","minAllowedDate"])):W("",!0)]),default:h(()=>[t("div",ma,[o(A,{src:"/images/general/icon/form/datepicker_icon.svg",width:"15px",height:"15px",alt:"datepicker_icon"}),t("p",va,r(e(I)(e(x)).format(e(v)("format12"))),1)])]),_:1},8,["show"])])]),_:1})]),t("div",ha,[t("div",fa,[t("p",ga,r(e(L))+" "+r(b.$t("hotel.nights",e(L))),1)])])])],2)]),_:1})]),o(le,{open:e(n).openMobileCheckinDate||e(n).openMobileCheckoutDate,topRadius:!0,header:!1,useOverlay:"",onClose:u[10]||(u[10]=K=>oe())},{content:h(()=>[t("div",{class:"m-modal-content m-mobile-hotel-datepicker-modal-content",onClick:u[9]||(u[9]=Fe(()=>{},["stop"]))},[t("div",wa,[o(A,{src:"/icon/close.svg",alt:"close",class:"close-icon",onClick:u[7]||(u[7]=K=>oe())}),t("p",$a,r(b.$t("general.selectStayDate")),1)]),o(j,{class:"tw-mb-0",isRoundTrip:!0,isSecondDateAllowedToSameWithFirstDate:!1}),o(be,{onSaveDate:u[8]||(u[8]=K=>oe())})])]),_:1},8,["open"]),t("div",ya,[t("div",{onClick:u[11]||(u[11]=K=>ee()),class:"tw-cursor-pointer"},[o(B,{label:b.$t("hotel.roomAndGuests"),class:"tw-h-full",isActive:e(n).openGuestSelection},{input:h(()=>[t("div",ba,[o(A,{src:"/icon/person.svg",class:"tw-w-5 tw-h-5",alt:"person"}),t("p",Ca,[t("span",null,r(e(n).hotelFormState.total_room)+" "+r(b.$t("hotel.room",e(n).hotelFormState.total_room))+", ",1),t("span",null,r(e(n).hotelFormState.guest_adult)+" "+r(b.$t("general.adult",e(n).hotelFormState.guest_adult))+", ",1),t("span",null,r(e(n).hotelFormState.guest_children)+" "+r(b.$t("general.child",e(n).hotelFormState.guest_children)),1)])])]),_:1},8,["label","isActive"])]),t("div",null,[e(n).openGuestSelection&&e(y)>=1024?(d(),N(ve,{key:0})):W("",!0),o(le,{open:e(n).openGuestSelection,useOverlay:"",header:!1,topRadius:!0,onClose:u[13]||(u[13]=K=>ae())},{content:h(()=>[t("div",Da,[t("div",ka,[o(A,{src:"/icon/close.svg",alt:"close",class:"close-icon",onClick:u[12]||(u[12]=K=>ae())}),t("p",Sa,r(b.$t("hotel.selectRoomAndGuest")),1)]),o(ve)])]),_:1},8,["open"]),o(le,{open:e(n).openMobileSelectChildrenAge,topRadius:!0,header:!1,onClose:u[15]||(u[15]=K=>q()),class:"lg:tw-hidden"},{content:h(()=>[t("div",xa,[t("div",null,[t("div",Ma,[o(A,{src:"/icon/close.svg",alt:"close",class:"tw-w-4 tw-h-4 tw-cursor-pointer",onClick:u[14]||(u[14]=K=>q())}),t("p",Fa,r(b.$t("hotel.selectChildDate")),1)]),t("div",Aa,[o(xe,{onSelected:R,class:"tw-shadow-none tw-min-h-[50dvh] tw-pb-5 tw-mt-2"})])])])]),_:1},8,["open"])])]),o(Me,{buttonText:b.$t("general.searchButton"),buttonHeight:"tw-h-[42px] lg:tw-h-full",class:"hotel-form-search-button lg:tw-flex-1 lg:tw-basis-auto",onSearch:u[16]||(u[16]=K=>Z())},null,8,["buttonText"])])),[[e(Ce),O]])])}}});const Oa=z(Ta,[["__scopeId","data-v-78556e1d"]]),Pa={class:"train-trip-option"},Ha=E({__name:"TripOption",setup(m){const{trainFormState:c}=Y($e()),{selectedFirstDate:g,selectedSecondDate:k,openDepartCalendar:f,openReturnCalendar:p}=Y(ue()),x=()=>{const w=I().startOf("day"),$=I(g.value);$.diff(w,"day")>45?k.value=$.format("YYYY-MM-DD"):k.value=$.add(1,"day").format("YYYY-MM-DD")};return(w,$)=>{const l=dt;return d(),M("div",Pa,[o(l,{modelValue:e(c).isRoundTrip,"onUpdate:modelValue":$[0]||($[0]=i=>e(c).isRoundTrip=i),name:"trip-option",value:!0,label:w.$t("general.roundTrip"),isChecked:e(c).isRoundTrip,labelStyle:"tw-text-sm tw-text-charcoal",class:"hover:tw-bg-transparent",onClick:$[1]||($[1]=i=>x())},null,8,["modelValue","label","isChecked"]),o(l,{modelValue:e(c).isRoundTrip,"onUpdate:modelValue":$[2]||($[2]=i=>e(c).isRoundTrip=i),name:"trip-option",value:!1,label:w.$t("general.oneWay"),isChecked:!e(c).isRoundTrip,labelStyle:"tw-text-sm tw-text-charcoal",class:"hover:tw-bg-transparent"},null,8,["modelValue","label","isChecked"])])}}});const Ia=z(Ha,[["__scopeId","data-v-f5e4bd1c"]]),Ra={class:"train-destination-form"},Ya=E({__name:"DestinationForm",props:{trainLastSearch:{type:Array,default:()=>[]}},emits:["clickpopular","onsearch","chooseStation","switch"],setup(m,{emit:c}){const{trainFormState:g,isOpenOriginModal:k,isOpenArrivalModal:f,isOpenPassengerModal:p,popularDestination:x}=Y($e()),{openDepartCalendar:w,openReturnCalendar:$}=Y(ue()),l=we(),i=()=>{k.value=!0,f.value=!1,w.value=!1,$.value=!1,p.value=!1,l.autoCompleteResult=[],l.searchInputDestination="",l.selectAllTextValue("#search-input")},v=()=>{f.value=!0,k.value=!1,w.value=!1,$.value=!1,p.value=!1,l.autoCompleteResult=[],l.searchInputDestination="",l.selectAllTextValue("#search-input")};return(H,n)=>{const _=Ct,S=ye,O=$t;return d(),M("div",Ra,[o(S,{class:"train-destination-form-wrapper"},{"form-content":h(()=>[o(_,{"destination-label":H.$t("general.departureFrom"),"destination-name":e(g).selectedStation.origin.name,"de
1stination-code":e(g).selectedStation.origin.type==="station"?e(g).selectedStation.origin.code:"Semua","arrival-label":H.$t("general.yourDestination"),"arrival-name":e(g).selectedStation.destination.name,"arrival-code":e(g).selectedStation.destination.type==="station"?e(g).selectedStation.destination.code:"Semua",isDestinationActive:e(k),isArrivalActive:e(f),onSwitch:n[0]||(n[0]=F=>H.$emit("switch")),onClickDestination:n[1]||(n[1]=F=>i()),onClickArrival:n[2]||(n[2]=F=>v())},null,8,["destination-label","destination-name","destination-code","arrival-label","arrival-name","arrival-code","isDestinationActive","isArrivalActive"])]),_:1}),e(k)||e(f)?(d(),N(O,{key:0,popularDestination:e(x),lastSearch:m.trainLastSearch,onChoosePopularDestination:n[3]||(n[3]=F=>H.$emit("clickpopular",F)),onSearch:n[4]||(n[4]=F=>H.$emit("onsearch",F)),onChoose:n[5]||(n[5]=F=>H.$emit("chooseStation",F))},null,8,["popularDestination","lastSearch"])):W("",!0)])}}});const La=z(Ya,[["__scopeId","data-v-18ad6c35"]]),Na=m=>(Ge("data-v-f1224602"),m=m(),Ve(),m),Ba={class:"train-date-picker-form"},Ga={class:"date-label"},Va={class:"date-value"},Wa=Na(()=>t("div",{class:"divider"},null,-1)),za={key:0},Ea={class:"date-label"},ja={class:"date-value"},Ua={class:"tw-text-dark-grey tw-text-sm"},qa={class:"tw-flex tw-items-center tw-flex-1 tw-justify-between"},Ja={class:"date-value tw-text-N400 tw-text-base tw-font-bold"},Ka=E({__name:"DatePicker",setup(m){const{getDateFormat:c}=ie(),{trainFormState:g,isOpenOriginModal:k,isOpenArrivalModal:f,isOpenPassengerModal:p}=Y($e()),{selectedFirstDate:x,selectedSecondDate:w,openDepartCalendar:$,openReturnCalendar:l}=Y(ue()),i=()=>{$.value=!0,l.value=!1,k.value=!1,f.value=!1,p.value=!1},v=()=>{l.value=!0,$.value=!1,k.value=!1,f.value=!1,p.value=!1},H=()=>{g.value.isRoundTrip=!0;const n=I().startOf("day"),_=I(x.value),S=_.diff(n,"day");w.value=S>45?_.format("YYYY-MM-DD"):_.add(1,"day").format("YYYY-MM-DD")};return(n,_)=>{const S=Qe,O=Xe,F=pe,P=ye;return d(),M("div",Ba,[o(P,{label:n.$t("general.departure")},{"form-content":h(()=>[t("div",{class:U(["train-date-picker-form-content",e(g).isRoundTrip?"":"tw-justify-between"])},[t("div",{class:U(["depart-arrival-date",e($)?"tw-bg-white-smoke":""])},[o(O,null,{default:h(()=>[o(e(ke),{show:e($),style:{display:"block",position:"relative"}},{content:h(()=>[e($)?(d(),N(S,{key:0,class:"departure-datepicker",openCalender:!0,columns:2,"step-two":!1,"is-round-trip":e(g).isRoundTrip?2:1,maxAllowedDate:e(I)().add(46,"day").format("YYYY-MM-DD")},null,8,["is-round-trip","maxAllowedDate"])):W("",!0)]),default:h(()=>[t("div",{onClick:_[0]||(_[0]=q=>i())},[t("p",Ga,r(n.$t("general.departure")),1),t("p",Va,r(e(I)(e(x)).format(e(c)("format9"))),1)])]),_:1},8,["show"])]),_:1})],2),Wa,t("div",{class:U(["depart-arrival-date",e(l)?"tw-bg-white-smoke":""])},[e(g).isRoundTrip?(d(),M("div",za,[o(O,null,{default:h(()=>[o(e(ke),{show:e(l),style:{display:"block",position:"relative"}},{content:h(()=>[e(l)?(d(),N(S,{key:0,class:"departure-datepicker",openCalender:!0,columns:2,"step-two":!0,"is-round-trip":2,maxAllowedDate:e(I)().add(46,"day").format("YYYY-MM-DD")},null,8,["maxAllowedDate"])):W("",!0)]),default:h(()=>[t("div",{onClick:_[1]||(_[1]=q=>v())},[t("p",Ea,r(n.$t("general.return")),1),t("p",ja,r(e(I)(e(w)).format(e(c)("format9"))),1)])]),_:1},8,["show"])]),_:1})])):(d(),M("div",{key:1,onClick:_[2]||(_[2]=q=>H()),class:"tw-cursor-pointer"},[t("p",Ua,r(n.$t("general.add")),1),t("div",qa,[t("p",Ja,r(n.$t("general.returnDate")),1),o(F,{src:"/images/general/icon/plus.svg",class:"tw-w-4 tw-h-4 tw-mt-2",alt:"plus"})])]))],2)],2)]),_:1},8,["label"])])}}});const Qa=z(Ka,[["__scopeId","data-v-f1224602"]]),Xa={class:"train-passenger-form"},Za=E({__name:"PassengerForm",setup(m){yt();const{trainFormState:c,isOpenPassengerModal:g}=Y($e()),k=X(()=>c.value.passenger.adult+c.value.passenger.infant);return(f,p)=>{const x=Dt,w=ye,$=Do;return d(),M("div",Xa,[o(w,{label:f.$t("general.passenger"),onClick:p[0]||(p[0]=l=>f.$emit("open")),class:"tw-cursor-pointer"},{"form-content":h(()=>[o(x,{active:e(g),label:f.$t("general.passenger",2),value:`${e(k)} ${f.$t("general.passenger",e(k))}`},null,8,["active","label","value"])]),_:1},8,["label"]),e(g)?(d(),N($,{key:0})):W("",!0)])}}});const es=z(Za,[["__scopeId","data-v-ed6e598c"]]),ts=m=>(Ge("data-v-96a180ee"),m=m(),Ve(),m),os={class:"m-train-form-search"},ns={class:"tw-flex tw-items-center tw-justify-start tw-gap-3 tw-p-5 tw-pb-0"},as={class:"tw-font-bold tw-text-base"},ss={class:"flex-column tw-gap-5 tw-p-5"},ls=ts(()=>t("div",{class:"border-bottom tw-my-0"},null,-1)),is={class:"tw-text-left tw-text-charcoal tw-text-sm"},rs={class:"passenger-modal-footer tw-p-5"},cs={class:"m-train-modal train-date-picker-modal"},ds={class:"m-modal-header"},us={class:"m-modal-title-header"},ps={class:"flex-column tw-gap-3"},_s={class:"switch-trip-option"},ms={class:"option-label"},vs={class:"option-label"},hs={class:"tw-flex tw-items-center tw-justify-center tw-gap-2"},fs={class:"tw-text-white tw-text-sm tw-font-bold"},gs=E({__name:"MobileFormSearch",setup(m){const{handleSwitchStation:c}=Ae(),{addPassenger:g,reducePassenger:k}
1=ko(),{trainFormState:f,tempTrainPassenger:p,openMobileOriginModal:x,openMobileReturnModal:w,isOpenMobilePassengerModal:$,isOpenMobileDepartureDate:l,isOpenMobileReturnDate:i,popularDestination:v,trainLastSearch:H,openMobileForm:n}=Y($e());Y(we());const{selectedFirstDate:_,selectedSecondDate:S}=Y(ue());f.value.isRoundTrip||(S.value="");const O=V(!1),F=()=>{f.value.passenger={adult:p.value.adult,infant:p.value.infant},$.value=!1,n.value=!0},P=L=>{if(f.value.isRoundTrip=L,L){const y=I().startOf("day"),te=I(_.value);te.diff(y,"day")>45?S.value=te.format("YYYY-MM-DD"):S.value=te.add(1,"day").format("YYYY-MM-DD"),f.value.date.return=S.value}},q=()=>{x.value=!0},R=()=>{w.value=!0,O.value=!0},Z=()=>{$.value=!0},J=()=>{x.value=!1,w.value=!1,$.value=!1,O.value=!1},de=L=>{L==="depart"?(l.value=!0,f.value.isRoundTrip||(S.value="",f.value.date.return=""),_.value=f.value.date.departure):(i.value=!0,S.value=f.value.date.return)},se=()=>{l.value=!1,i.value=!1},ee=()=>{f.value.date={departure:_.value,return:S.value},se()};return(L,y)=>{const te=So,oe=Oe,ae=pe,_e=bt,re=Ue,G=Ze,b=xo,u=Mo,A=Fo;return d(),M("div",os,[o(oe,{useOverlay:"",open:e(x)||e(w),topRadius:!0,header:!1,onClose:y[1]||(y[1]=C=>J())},{content:h(()=>[o(te,{isArrival:e(O),onClose:y[0]||(y[0]=C=>J())},null,8,["isArrival"])]),_:1},8,["open"]),o(oe,{useOverlay:"",open:e($),topRadius:!0,header:!1,onClose:y[7]||(y[7]=C=>J())},{content:h(()=>[t("div",null,[t("div",ns,[o(ae,{src:"/icon/close.svg",alt:"close",class:"close-icon",width:"14",onClick:J}),t("p",as,r(L.$t("train.setPassenger")),1)]),t("div",null,[t("div",ss,[o(_e,{label:L.$t("train.adultWithAge"),numberToAdd:e(p).adult,isDisableMinus:e(p).adult===1,onClickMin:y[2]||(y[2]=C=>e(k)("adult")),onClickPlus:y[3]||(y[3]=C=>e(g)("adult"))},null,8,["label","numberToAdd","isDisableMinus"]),o(_e,{label:L.$t("train.infantWithAge"),numberToAdd:e(p).infant,isDisableMinus:e(p).infant===0,isDisablePlus:e(p).infant===e(p).adult,onClickMin:y[4]||(y[4]=C=>e(k)("infant")),onClickPlus:y[5]||(y[5]=C=>e(g)("infant"))},null,8,["label","numberToAdd","isDisableMinus","isDisablePlus"]),ls,t("p",is,"*"+r(L.$t("train.infantNoSeat")),1)]),t("div",rs,[o(re,{size:"lg",onClick:y[6]||(y[6]=C=>F())},{content:h(()=>[t("p",null,r(L.$t("general.save")),1)]),_:1})])])])]),_:1},8,["open"]),o(oe,{useOverlay:"",open:e(l)||e(i),onClose:y[11]||(y[11]=C=>se()),topRadius:!0,header:!1},{content:h(()=>[t("div",cs,[t("div",ds,[o(ae,{src:"/icon/close.svg",alt:"close",class:"close-icon",onClick:y[8]||(y[8]=C=>se())}),t("p",us,r(L.$t("general.setDate")),1)]),o(G,{useHighlight:!1,isRoundTrip:e(f).isRoundTrip,class:"m-form-search-date-picker",maxSelectableDate:e(I)().add(46,"day").format("YYYY-MM-DD"),onChangeTrip:y[9]||(y[9]=C=>P(!0)),onSaveDate:y[10]||(y[10]=C=>ee())},null,8,["isRoundTrip","maxSelectableDate"])])]),_:1},8,["open"]),t("div",ps,[t("div",_s,[t("div",{class:U(["option-item",e(f).isRoundTrip?"active":""]),onClick:y[12]||(y[12]=C=>P(!0))},[t("p",ms,r(L.$t("general.roundTrip")),1)],2),t("div",{class:U(["option-item",e(f).isRoundTrip?"":"active"]),onClick:y[13]||(y[13]=C=>P(!1))},[t("p",vs,r(L.$t("general.oneWay")),1)],2)]),o(b,{onOpenOrigin:y[14]||(y[14]=C=>q()),onOpenArrival:y[15]||(y[15]=C=>R()),onSwitch:y[16]||(y[16]=C=>e(c)())}),o(u,{onOpen:y[17]||(y[17]=C=>de(C))}),o(A,{onOpen:y[18]||(y[18]=C=>Z())}),t("div",null,[o(re,{size:"lg",onClick:y[19]||(y[19]=C=>L.$emit("clicksearch"))},{content:h(()=>[t("div",hs,[o(ae,{src:"/images/general/icon/form/search_icon.svg",width:"18",height:"18",alt:"search_icon"}),t("p",fs,r(L.$t("train.searchTrain")),1)])]),_:1})])])])}}});const ws=z(gs,[["__scopeId","data-v-96a180ee"]]),$s={id:"train-form-search",class:"train-form-container"},ys={class:"train-form-search"},bs={class:"tw-flex tw-flex-col lg:tw-flex-row tw-mt-3 tw-gap-3 lg:tw-h-[67px]"},Cs={class:"flex-column tw-justify-center tw-gap-3 tw-text-center"},Ds={class:"tw-font-bold tw-text-18 tw-text-neutral-N700"},ks={class:"tw-text-base tw-text-neutral-N500 tw-mb-3"},Ss={class:"tw-font-bold tw-text-base"},xs={class:"m-modal-detail-search tw-z-10 tw-p-5"},Ms={class:"flex-column tw-gap-3 tw-text-center"},Fs={class:"tw-font-bold tw-text-base lg:tw-text-18 tw-text-neutral-N700"},As={class:"tw-text-sm lg:tw-text-base tw-text-neutral-N500 tw-mb-3"},Ts={class:"tw-font-bold tw-text-base"},Os=E({__name:"Index",setup(m){const{locale:c,t:g}=Se(),{removeBodyClass:k}=ie(),{handleSwitchStation:f,handleClickPopularStation:p}=Ae(),{saveLastSearch:x}=ct(),{selectedFirstDate:w,selectedSecondDate:$,openDepartCalendar:l,openReturnCalendar:i}=Y(ue()),{trainFormState:v,isOpenPassengerModal:H,isOpenOriginModal:n,isOpenArrivalModal:_,tempTrainPasse
1nger:S,selectedTrainSchedule:O,trainOriginLastSearch:F,trainDestinationLastSearch:P}=Y($e()),{arrayToUrlStr:q}=ie(),{searchTrain:R,handleChooseTrainStation:Z}=Ae(),{hydrateFromStorage:J}=ct(),{pushSearchEvent:de,buildContentId:se}=qe(),ee=V(!1),L=V(""),y=X(()=>n.value?F.value:P.value);Ke(()=>{J()});const te=G=>{Z(G)},oe=G=>{G&&(k(),ae())},ae=()=>{l.value=!1,i.value=!1,H.value=!1,n.value=!1,_.value=!1,O.value={depart:{},return:{}}},_e=()=>{H.value=!0,S.value={...v.value.passenger},l.value=!1,i.value=!1,n.value=!1,_.value=!1},re=()=>{const G=v.value.selectedStation.origin.code,b=v.value.selectedStation.destination.code;if(G===b){ee.value=!0,L.value=g("train.changeRouteDesc");return}let u={origin_code:G,origin_type:v.value.selectedStation.origin.type,destination_code:b,destination_type:v.value.selectedStation.destination.type,departure_date:w.value,return_date:v.value.isRoundTrip?$.value:"",is_round_trip:v.value.isRoundTrip,adult_qty:v.value.passenger.adult,infant_qty:v.value.passenger.infant,destination_name:v.value.selectedStation.destination.name,origin_name:v.value.selectedStation.origin.name};de({content_category:"train",content_ids:se("train",u.origin_name,u.destination_name),content_name:`${u.origin_name} - ${u.destination_name}`,origin:u.origin_name,destination:u.destination_name,travel_date:u.departure_date}),ae(),{...u,origin_city:v.value.selectedStation.origin.city,origin_type:v.value.selectedStation.origin.type,destination_city:v.value.selectedStation.destination.city,destination_type:v.value.selectedStation.destination.type,createdAt:Date.now()},x({...u,origin_city:v.value.selectedStation.origin.city,destination_city:v.value.selectedStation.destination.city});const{origin_name:A,destination_name:C,...B}=u,T={...B,depLabel:A,arrLabel:C},ce=q(T);let le=`/${c.value}/train/search?${ce}`;Je(le)};return(G,b)=>{const u=Ia,A=La,C=Qa,B=es,T=et,ce=ws,le=Ue,me=Be,ne=Oe;return d(),M("div",$s,[t("div",ys,[o(u),De((d(),M("div",bs,[o(A,{openDestinationModal:e(n),openArrivalModal:e(_),trainLastSearch:e(y),onSwitch:b[0]||(b[0]=j=>e(f)()),onOnsearch:b[1]||(b[1]=j=>
1e(R)(j)),onChooseStation:b[2]||(b[2]=j=>te(j)),onClickpopular:b[3]||(b[3]=j=>e(p)(j))},null,8,["openDestinationModal","openArrivalModal","trainLastSearch"]),o(C),o(B,{onOpen:_e}),o(T,{buttonText:G.$t("general.searchButton"),class:"train-form-search-button",onSearch:b[4]||(b[4]=j=>re())},null,8,["buttonText"])])),[[e(Ce),oe]])]),o(ce,{onClicksearch:b[5]||(b[5]=j=>re())}),o(me,{isOpen:e(ee),header:!1,footer:!1,class:"tw-hidden lg:tw-block no-scrollbar",id:"modal-same-destination"},{description:h(()=>[t("div",Cs,[t("p",Ds,r(G.$t("train.changeRouteTitle")),1),t("p",ks,r(e(L)),1),o(le,{onClick:b[6]||(b[6]=j=>ee.value=!1)},{content:h(()=>[t("p",Ss,r(G.$t("general.edit")),1)]),_:1})])]),_:1},8,["isOpen"]),o(ne,{useOverlay:"",open:e(ee),topRadius:!0,header:!1},{content:h(()=>[t("div",xs,[t("div",Ms,[t("p",Fs,r(G.$t("train.changeRouteTitle")),1),t("p",As,r(e(L)),1),o(le,{onClick:b[7]||(b[7]=j=>ee.value=!1),size:"md"},{content:h(()=>[t("p",Ts,r(G.$t("general.edit")),1)]),_:1})])])]),_:1},8,["open"])])}}});const Ps=z(Os,[["__scopeId","data-v-a54f5d23"]]),Hs={class:"tw-flex tw-items-center tw-gap-2"},Is={class:"search-tour-placeholder"},Rs={class:"tw-text-neutral-N700 tw-font-bold tw-text-18"},Ys={class:"container-modal m-modal-content"},Ls={class:"header-modal"},Ns={class:"title-header tw-font-bold"},Bs={class:"body-modal"},Gs=E({__name:"Index",setup(m){const{removeBodyClass:c}=ie(),g=i=>{i&&c()},{locale:k}=Se(),f=V(!1),{tourData:p}=Y(Zt()),{getBaseHeaders:x}=pt(),{data:w,pending:$}=eo(_t(mt.tours.getListRegion),{onRequest({options:i}){i.method="get",i.headers=x()},transform(i){return p.value=i.data,i.data}},"$n0dLBG2WoM"),l=async i=>{f.value=!1,await Je(`/${k.value}/tour/list?searchType=list&placeType=${i.type}&placeId=${i.value}`)};return(i,v)=>{const H=pe,n=vt,_=Ao,S=Be,O=Oe;return De((d(),M("div",{id:"tour-form-content",onClick:v[5]||(v[5]=F=>f.value=!0)},[t("div",Hs,[o(H,{src:"/images/general/icon/form/location.svg",alt:"hotel-address",class:"location-icon",width:"16",height:"20"}),t("p",Is,r(i.$t("tour.searchDestinationPrompt")),1)]),o(n,{width:"20",height:"20",class:"tw-rotate-90"}),(d(),N(ht,{defer:"",to:"body"},[o(S,{isOpen:e(f),onClose:v[1]||(v[1]=F=>f.value=!1),"modal-type":"info",footer:!1,width:"588px",bodyMaxHeight:"tw-max-h-[90dvh]",class:"tw-hidden lg:tw-block"},{titleHead:h(()=>[t("div",null,[t("p",Rs,r(i.$t("tour.selectAvailableDestination")),1)])]),description:h(()=>[t("div",null,[o(_,{list:e(w),onClick:v[0]||(v[0]=F=>l(F))},null,8,["list"])])]),_:1},8,["isOpen"]),o(O,{open:e(f),useOverlay:"",onClose:v[4]||(v[4]=F=>f.value=!1),topRadius:!0,header:!1},{content:h(()=>[t("div",Ys,[t("div",Ls,[t("div",{onClick:v[2]||(v[2]=F=>f.value=!1),role:"button"},[o(H,{src:"/icon/close.svg",class:"tw-cursor-pointer tw-w-3.5 lg:tw-w-4"})]),t("p",Ns,r(i.$t("tour.selectAvailableDestination")),1)]),t("div",Bs,[o(_,{list:e(w),onClick:v[3]||(v[3]=F=>l(F))},null,8,["list"])])])]),_:1},8,["open"])]))])),[[e(Ce),g]])}}});const Vs=z(Gs,[["__scopeId","data-v-9a2af42b"]]),Ws={class:"tw-flex tw-items-center tw-gap-2"},zs={class:"search-jetplane-placeholder"},Es={class:"tw-text-neutral-N700 tw-font-bold tw-text-18 tw-text-left"},js={class:"tw-text-neutral-N500 bold tw-text-base tw-mb-6 tw-text-left"},Us={class:"tw-max-h-[415px] tw-overflow-scroll tw-overflow-x-hidden",style:{"scrollbar-width":"thin !important"}},qs=E({__name:"Index",setup(m){const{removeBodyClass:c}=ie(),g=p=>{p&&c()};Se();const k=V(!1),f=async p=>{k.value=!1};return(p,x)=>{const w=pe,$=vt,l=to,i=Be;return De((d(),M("div",{id:"jetplane-form-content",onClick:x[2]||(x[2]=v=>k.value=!0)},[t("div",Ws,[o(w,{src:"/images/general/icon/form/location.svg",alt:"hotel-address",class:"location-icon",width:"16",height:"20"}),t("p",zs,r(p.$t("private_jet.searchPlaceholder")),1)]),o($,{width:"20",height:"20",class:"tw-rotate-90"}),(d(),N(ht,{defer:"",to:"body"},[o(i,{isOpen:e(k),onClose:x[1]||(x[1]=v=>k.value=!1),"modal-type":"info",footer:!1,width:"588px",bodyMaxHeight:"tw-h-[488px]",class:"tw-hidden lg:tw-block"},{titleHead:h(()=>[t("div",null,[t("p",Es,r(p.$t("private_jet.selectAvailableDestination")),1)])]),description:h(()=>
1[t("div",null,[t("p",js,r(p.$t("private_jet.titleDesc")),1),De((d(),M("div",Us,[o(l,{onClick:x[0]||(x[0]=v=>f(v))})])),[[e(Ce),g]])])]),_:1},8,["isOpen"])]))])),[[e(Ce),g]])}}});const Js=z(qs,[["__scopeId","data-v-51c8f4d2"]]),Ks={class:"form-container container-size"},Qs={key:5,class:"promo-check-wrapper"},Xs={class:"promo-check-text"},Zs=E({__name:"FormContainer",async setup(m){let c,g;const{t:k}=Se(),f=["flight","hotel","train","tour","private_jet"];X(()=>f.includes(n.query.tab));const{activeTab:p,hotelPopularSearch:x}=Y(we()),{trainFormState:w}=Y($e()),{addBodyClass:$}=ie();Y(Te());const{selectedFirstDate:l,selectedSecondDate:i}=Y(ue()),{updateCalendarStore:v}=ie(),{getAuthHeaders:H}=pt(),n=ut(),_=X(()=>!!Object.keys(n.query).length);Ke(()=>{_.value||$("form-container")}),p&&(l.value=I().format("YYYY-MM-DD"),i.value=I(l.value).add(1,"day").format("YYYY-MM-DD"),p.value==="train"&&(w.value.date.departure=l.value,w.value.date.return=i.value),v()),p.value==="hotel"&&([c,g]=lo(async()=>oo(_t(mt.hotel.popularDestination),{async onRequest({options:P}){P.method="get",P.headers=await H()},onResponse({response:P}){P._data.status&&(x.value=P._data.values.cities)}},"$ed6AzBu58y")),c=await c,g());const S={flight:"promo.promoTextFlight",hotel:"promo.promoTextHotel",train:"promo.promoTextTrain"};X(()=>{const P=n.path.split("/").filter(Boolean);return P[P.length-1]||""});const O=X(()=>{const P=S[p.value]||"";return k(P)}),F=X(()=>{const q=n.path.split("/").filter(Boolean).length===1,Z=["tour","private_jet"].some(J=>n.path.includes(J));return!q&&!Z});return(P,q)=>{const R=ea,Z=Oa,J=Ps,de=Vs,se=Js,ee=pe;return d(),M("div",Ks,[e(p)==="flight"?(d(),N(R,{key:0})):e(p)==="hotel"?(d(),N(Z,{key:1})):e(p)==="train"?(d(),N(J,{key:2})):e(p)==="tour"?(d(),N(de,{key:3})):e(p)==="private_jet"?(d(),N(se,{key:4})):W("",!0),e(F)?(d(),M("div",Qs,[o(ee,{src:"/icon/promo/3d-voucher.svg",alt:"Promo Voucher",class:"promo-check-icon"}),t("p",Xs,r(e(O)),1)])):W("",!0)])}}});const yl=z(Zs,[["__scopeId","data-v-dc1a0636"]]);export{$l as _,yl as a};
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.