PageSourceSearch

https://myaccount.chelseapiers.com/js/manager-booking-schedule.7f548a41.js

js chelseapiers.com collected 2026-10-02 04:32:01 UTC 130,746 bytes, 7 lines download raw bytes

1"use strict";(self["webpackChunkwebapp_standard"]=self["webpackChunkwebapp_standard"]||[]).push([[7692],{73485:function(e,t,i){i.d(t,{A:function(){return E}});var s=i(20641),n=i(90033),a=i(53751);const l=e=>((0,s.Qi)("data-v-3eb70022"),e=e(),(0,s.jt)(),e),o=["disabled"],r={key:0,value:null,selected:""},d={key:1,value:null,selected:""},c={key:2,value:null},u=["value"],h=l((()=>(0,s.Lk)("span",null,null,-1)));function v(e,t,i,l,v,p){return(0,s.uX)(),(0,s.CE)(s.FK,null,[(0,s.Lk)("p",null,(0,n.v_)(e.$t("general.center"))+":",1),(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.searchCenter=t),onChange:t[1]||(t[1]=(...t)=>e.onCenterChanged&&e.onCenterChanged(...t)),class:"select-input-field","data-cy":"staff-select-center",disabled:e.loadingCenters||e.loadingCentersError.length>0},[e.loadingCenters?((0,s.uX)(),(0,s.CE)("option",r,"Loading centers..")):e.loadingCentersError?((0,s.uX)(),(0,s.CE)("option",d,(0,n.v_)(e.$t(e.loadingCentersError)),1)):e.searchCenter?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("option",c,"Please select a center")),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.listCenters,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e.id,value:e},(0,n.v_)(e.name),9,u)))),128))],40,o),[[a.u1,e.searchCenter]]),h],64)}var p=i(23772),m=i(15215),g=i(66753),f=i(63863),y=i(37884),w=i(14453);let b=class extends y.lD{constructor(...e){super(...e),(0,p.A)(this,"clipcardService",void 0),(0,p.A)(this,"configurationService",void 0),(0,p.A)(this,"roles",void 0),(0,p.A)(this,"searchCenter",null),(0,p.A)(this,"listCenters",[]),(0,p.A)(this,"loadingCenters",!1),(0,p.A)(this,"loadingCentersError","")}onCenterChanged(){this.searchCenter&&this.$emit("staffCenterChanged",this.searchCenter)}mounted(){this.loadingCenters=!0,this.loadingCentersError="",this.configurationService.loadStaffCenters(this.roles).then((e=>{this.listCenters=e,this.listCenters.forEach((e=>{e.id===Number(f.A.state.user.centerId)&&(this.searchCenter=e,this.onCenterChanged())})),this.loadingCenters=!1}
1)).catch((e=>{this.loadingCentersError=e.errorI18NMessage,this.loadingCenters=!1}))}};(0,m.Cg)([(0,w.y_)("clipcardService")],b.prototype,"clipcardService",void 0),(0,m.Cg)([(0,w.y_)("configurationService")],b.prototype,"configurationService",void 0),(0,m.Cg)([(0,w.kv)({default:[]})],b.prototype,"roles",void 0),b=(0,m.Cg)([(0,y.JY)({props:{},components:{Spinner:g.A},emits:["staffCenterChanged"]})],b);var k=b,D=i(66262);const C=(0,D.A)(k,[["render",v],["__scopeId","data-v-3eb70022"]]);var E=C},98903:function(e,t,i){i.d(t,{A:function(){return b}});var s=i(20641),n=i(90033);const a={key:0},l={class:"w-full flex pt-2 justify-center text-red-500","data-cy":"error-display-global-error"},o={key:0,class:"w-full flex flex-wrap pt-2 pb-2 justify-center text-red-500","data-cy":"error-display-global-error-note-infos"},r={class:"w-full text-center text-xs"},d={key:1,class:"w-full flex flex-wrap pt-2 pb-2 justify-center text-red-500","data-cy":"error-display-global-error-extra-details"},c={key:2,class:"w-full flex flex-wrap pt-2 pb-2 justify-center text-red-500","data-cy":"error-display-global-error-duplicate"};function u(e,t,i,u,h,v){return e.errorModel?((0,s.uX)(),(0,s.CE)("div",a,[(0,s.Lk)("div",l,(0,n.v_)(e.$t(e.errorModel.errorI18NMessage)),1),e.errorModel.errorCode.paymentResult?.noteInfos?((0,s.uX)(),(0,s.CE)("div",o,[(0,s.Lk)("p",r,(0,n.v_)(e.errorModel.errorCode.paymentResult.noteInfos),1)])):(0,s.Q3)("",!0),e.errorModel.errorCode.extraDetails?.length?((0,s.uX)(),(0,s.CE)("div",d,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.errorModel.errorCode.extraDetails,(e=>((0,s.uX)(),(0,s.CE)("p",{key:e,class:"w-full text-center text-xs"},[(0,s.Lk)("span",null,(0,n.v_)(e),1)])))),128))])):(0,s.Q3)("",!0),e.errorModel.errorCode.duplicateFields?.length?((0,s.uX)(),(0,s.CE)("div",c,[(0,s.eW)((0,n.v_)(e.$t("person.errorDuplicateField"))+" ",1),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.errorModel.errorCode.duplicateFields,(t=>((0,s.uX)(),(0,s.CE)("p",{key:t,class:"w-full text-center text-xs"},[(0,s.Lk)("span",null,(0,n.v_)(e.$t("person."+t)),1)])))),128))])):(0,s.Q3)("",!0)])):(0,s.Q3)("",!0)}var h=i(23772),v=i(15215),p=i(37884),m=i(78110);let g=class extends p.lD{constructor(...e){super(...e),(0,h.A)(this,"errorModel",void 0)}};g=(0,v.Cg)([(0,p.JY)({props:{errorModel:Object},components:{RefreshIcon:m.A}})],g);var f=g,y=i(66262);const w=(0,y.A)(f,[["render",u]]);var b=w},66753:function(e,t,i){i.d(t,{A:function(){return g}});var s=i(20641),n=i(90033);const a={class:"flex justify-center items-center"},l={class:"pr-1"};function o(e,t,i,o,r,d){const c=(0,s.g2)("RefreshIcon");return(0,s.uX)(),(0,s.CE)("div",a,[(0,s.Lk)("div",l,[(0,s.bF)(c,{class:"animate-spin transform rotate-179 w-5 h-5"})]),(0,s.Lk)("div",null,(0,n.v_)(e.text),1)])}var r=i(23772),d=i(15215),c=i(37884),u=i(78110);let h=class extends c.lD{constructor(...e){super(...e),(0,r.A)(this,"text",void 0)}};h=(0,d.Cg)([(0,c.JY)({props:{text:String},components:{RefreshIcon:u.A}})],h);var v=h,p=i(66262);const m=(0,p.A)(v,[["render",o]]);var g=m},71073:function(e,t,i){i.r(t),i.d(t,{default:function(){return Vs}});var s=i(20641),n=i(90033),a=i(53751);const l={class:"w-full"},o={class:"text-center text-3xl font-bold my-4","data-cy":"manager-booking-page-title"},r={class:"flex flex-wrap w-full mt-4 border border-primary-200 p-4","data-cy":"manager-booking-search-filters"},d={class:"w-full p-2 md:w-1/4"},c={class:"w-full p-2 md:w-1/4"},u={class:"w-full p-2 md:w-1/4"},h=["disabled"],v={selected:"",value:null},p=["value"],m={class:"w-full p-2 md:w-1/4"},g={class:"w-full flex mt-2 justify-end"},f={class:"flex btn-positive btn-sm justify-center",style:{visibility:"hidden"}},y={key:0,class:"flex flex-wrap mt-2 relative","data-cy":"manager-booking-cal"},w={class:"w-full min-h-[32rem] max-h-[46rem]"},b={class:"vuecal__event-title"},k={class:"vuecal__event-time"},D={key:0,class:"absolute bg-white bg-opacity-60 z-10 h-full w-full flex items-center justify-center","data-cy":"manager-booking-cal-overlay"},C={class:"flex items-center"};function E(e,t,i,E,_,A){const S=(0,s.g2)("search-staff-centers"),T=(0,s.g2)("staff-autocomplete"),M=(0,s.g2)("VueMultiselect"),L=(0,s.g2)("error-display"),x=(0,s.g2)("vue-cal"),B=(0,s.g2)("spinner"),$=(0,s.g2)("add-booking-modal");return(0,s.uX)(),(0,s.CE)(s.FK,null,[(0,s.Lk)("div",l,[(0,s.Lk)("h1",o,(0,n.v_)(e.$t("staff.classBookingSchedule")),1)]),(0,s.Lk)("div",r,[(0,s.Lk)("div",d,[(0,s.bF)(S,{onStaffCenterChanged:e.updateCenterId,roles:e.$store.state.config.general.managerRole},null,8,["onStaffCenterChanged","roles"])]),(0,s.Lk)("div",c,[(0,s.Lk)("p",null,(0,n.v_)(e.$t("general.instructor"))+":",1),(0,s.bF)(T,{ref:"searchStaffAutocomplete","staff-autocomplete-function":e.staffAutocompleteFunction,disabled:null===e.selectedCenter,onStaffSelected:e.staffSelected},null,8,["staff-autocomplete-function","disabled","onStaffSelected"])]),(0,s.Lk)("div",u,[(0,s.Lk)("p",null,(0,n.v_)(e.$t("staff.activityGroups"))+":",1),(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedActivityGroup=t),class:"select-input-field",onChange:t[1]||(t[1]=t=>e.changedActivityGroup()),disabled:null!==e.activitiesPlaceholder,"data-cy":"manager-booking-activity-group"},[(0,s.Lk)("option",v,(0,n.v_)(e.activitiesPlaceholder||e.$t("staff.allGroups")),1),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.listActivityGroups,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e.id,value:e},(0,n.v_)(e.name),9,p)))),128))],40,h),[[a.u1,e.selectedActivityGroup]])]),(0,s.Lk)("div",m,[(0,s.Lk)("p",null,(0,n.v_)(e.$t("staff.activities"))+":",1),(0,s.bF)(M,{disabled:null!==e.activitiesPlaceholder,modelValue:e.selectedActivities,"onUpdate:modelValue":t[2]||(t[2]=t=>e.selectedActivities=t),options:e.listActivities,multiple:!0,"close-on-select":!1,"group-select":!0,placeholder:e.activitiesPlaceholder||e.$t("staff.allActivities"),"track-by":"name",label:"name",selectLabel:e.$t("general.clickToSelect"),deselectLabel:e.$t("general.clickToRemove"),selectedLabel:e.$t("general.selected"),onClose:t[3]||(t[3]=t=>e.changedActivities()),limit:5,"data-cy":"manager-booking-activities"},null,8,["disabled","modelValue","options","placeholder","selectLabel","deselectLabel","selectedLabel"])])]),(0,s.bF)(L,{"error-model":e.errorLoadingBookings,"data-cy":"manager-booking-search-error"},null,8,["error-model"]),(0,s.Lk)("div",g,[(0,s.bo)((0,s.Lk)("button",{class:"flex btn-positive btn-sm justify-center",onClick:t[4]||(t[4]=t=>e.openPopupAdd()),"data-cy":"manager-booking-add-button"},(0,n.v_)(e.$t("general.add"))+" + ",513),[[a.aG,"day"===e.currentView&&e.displayCalendar]]),(0,s.bo)((0,s.Lk)("button",f,"   ",512),[[a.aG,"day"!==e.currentView]])]),e.displayCalendar?((0,s.uX)(),(0,s.CE)("div",y,[(0,s.Lk)("div",w,[(0,s.bF)(x,{class:"vuecal--blue-theme","today-button":"","active-view":"day",ref:"vue-cal",time:!0,"disable-views":["years","year"],events:e.events,"time-step":30,"snap-to-time":15,"on-event-click":e.onEventClick,onCellDblclick:e.onCellDblClick,onCellClick:e.switchToNarrowerView,onViewChange:e.viewChange,onReady:e.calendarReady,"selected-date":e.selectedCalendarDate,"data-cy":"manager-booking-cal-contents"},{event:(0,s.k6)((({event:e})=>
1[(0,s.Lk)("div",b,(0,n.v_)(e.title),1),(0,s.Lk)("div",k,[(0,s.eW)((0,n.v_)(e.start.formatTime("HH:mm"))+" - ",1),(0,s.Lk)("span",null,(0,n.v_)(e.end.formatTime("HH:mm")),1)])])),_:1},8,["events","on-event-click","onCellDblclick","onCellClick","onViewChange","onReady","selected-date"])]),e.loadingBookings?((0,s.uX)(),(0,s.CE)("div",D,[(0,s.Lk)("div",C,[(0,s.bF)(B,{text:e.$t("general.loading")},null,8,["text"])])])):(0,s.Q3)("",!0)])):(0,s.Q3)("",!0),(0,s.bF)($,{"popup-add-booking-type":e.popupAddBookingType,"new-booking":e.newBooking,onClosePopup:e.closePopup,onBookingUpdated:e.bookingUpdatedFromPopup},null,8,["popup-add-booking-type","new-booking","onClosePopup","onBookingUpdated"])],64)}var _=i(23772),A=i(15215),S=i(37884),T=i(14453),M=i(71263),L=i(66753),x=i(98903),B=Object.defineProperty,$=(e,t,i)=>t in e?B(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,O=(e,t,i)=>($(e,"symbol"!=typeof t?t+"":t,i),i)
2/**
3  * vue-cal v4.8.1
4  * (c) 2022 Antoni Andre <[email protected]>
5  * @license MIT
6  */;let V,W,I,H,R,F,P,X={},j={};class N{constructor(e){O(this,"_vuecal",null),O(this,"selectCell",((e=!1,t,i)=>{this._vuecal.$emit("cell-click",i?{date:t,split:i}:t),this._vuecal.clickToNavigate||e?this._vuecal.switchToNarrowerView():this._vuecal.dblclickToNavigate&&"ontouchstart"in window&&(this._vuecal.domEvents.dblTapACell.taps++,setTimeout((()=>this._vuecal.domEvents.dblTapACell.taps=0),this._vuecal.domEvents.dblTapACell.timeout),this._vuecal.domEvents.dblTapACell.taps>=2&&(this._vuecal.domEvents.dblTapACell.taps=0,this._vuecal.switchToNarrowerView(),this._vuecal.$emit("cell-dblclick",i?{date:t,split:i}:t)))})),O(this,"keyPressEnterCell",((e,t)=>{this._vuecal.$emit("cell-keypress-enter",t?{date:e,split:t}:e),this._vuecal.switchToNarrowerView()})),O(this,"getPosition",(e=>{const{left:t,top:i}=this._vuecal.cellsEl.getBoundingClientRect(),{clientX:s,clientY:n}="ontouchstart"in window&&e.touches?e.touches[0]:e;return{x:s-t,y:n-i}})),O(this,"minutesAtCursor",(e=>{let t=0,i={x:0,y:0};const{timeStep:s,timeCellHeight:n,timeFrom:a}=this._vuecal.$props;return"number"==typeof e?t=e:"object"==typeof e&&(i=this.getPosition(e),t=Math.round(i.y*s/parseInt(n)+a)),{minutes:Math.max(Math.min(t,1440),0),cursorCoords:i}})),this._vuecal=e}}class Y{constructor(e,t){O(this,"_vuecal",null),O(this,"eventDefaults",{_eid:null,start:"",startTimeMinutes:0,end:"",endTimeMinutes:0,title:"",content:"",background:!1,allDay:!1,segments:null,repeat:null,daysCount:1,deletable:!0,deleting:!1,titleEditable:!0,resizable:!0,resizing:!1,draggable:!0,dragging:!1,draggingStatic:!1,focused:!1,class:""}),this._vuecal=e,R=t}createAnEvent(e,t,i){if("string"==typeof e&&(e=R.stringToDate(e)),!(e instanceof Date))return!1;const s=R.dateToMinutes(e),n=s+(t=1*t||120),a=R.addMinutes(new Date(e),t);i.end&&("string"==typeof i.end&&(i.end=R.stringToDate(i.end)),i.endTimeMinutes=R.dateToMinutes(i.end));const l={...this.eventDefaults,_eid:`${this._vuecal._.uid}_${this._vuecal.eventIdIncrement++}`,start:e,startTimeMinutes:s,end:a,endTimeMinutes:n,segments:null,...i};return"function"!=typeof this._vuecal.onEventCreate||this._vuecal.onEventCreate(l,(()=>this.deleteAnEvent(l)))?(l.startDateF!==l.endDateF&&(l.daysCount=R.countDays(l.start,l.end)),this._vuecal.mutableEvents.push(l),this._vuecal.addEventsToView([l]),this._vuecal.emitWithEvent("event-create",l),this._vuecal.$emit("event-change",{event:this._vuecal.cleanupEvent(l),originalEvent:null}),l):void 0}addEventSegment(e){e.segments||(e.segments={},e.segments[R.formatDateLite(e.start)]={start:e.start,startTimeMinutes:e.startTimeMinutes,endTimeMinutes:1440,isFirstDay:!0,isLastDay:!1});const t=e.segments[R.formatDateLite(e.end)];t&&(t.isLastDay=!1,t.endTimeMinutes=1440);const i=R.addDays(e.end,1),s=R.formatDateLite(i);return i.setHours(0,0,0,0),e.segments[s]={start:i,startTimeMinutes:0,endTimeMinutes:e.endTimeMinutes,isFirstDay:!1,isLastDay:!0},e.end=R.addMinutes(i,e.endTimeMinutes),e.daysCount=Object.keys(e.segments).length,s}removeEventSegment(e){let t=Object.keys(e.segments).length;if(t<=1)return R.formatDateLite(e.end);delete e.segments[R.formatDateLite(e.end)],t--;const i=R.subtractDays(e.end,1),s=R.formatDateLite(i),n=e.segments[s];return t?n&&(n.isLastDay=!0,n.endTimeMinutes=e.endTimeMinutes):e.segments=null,e.daysCount=t||1,e.end=i,s}createEventSegments(e,t,i){const s=t.getTime(),n=i.getTime();let a,l,o,r=e.start.getTime(),d=e.end.getTime(),c=!1;for(e.end.getHours()||e.end.getMinutes()||(d-=1e3),e.segments={},e.repeat?(a=s,l=Math.min(n,e.repeat.until?R.stringToDate(e.repeat.until).getTime():n)):(a=Math.max(s,r),l=Math.min(n,d));a<=l;){let t=!1;const i=R.addDays(new Date(a),1).setHours(0,0,0,0);let s,n,u,h;if(e.repeat){const i=new Date(a),l=R.formatDateLite(i);(c||e.occurrences&&e.occurrences[l])&&(c||(r=e.occurrences[l].start,o=new Date(r).setHours(0,0,0,0),d=e.occurrences[l].end),c=!0,t=!0),s=a===o,n=l===R.formatDateLite(new Date(d)),u=new Date(s?r:a),h=R.formatDateLite(u),n&&(c=!1)}else t=!0,s=a===r,n=l===d&&i>
6l,u=s?e.start:new Date(a),h=R.formatDateLite(s?e.start:u);t&&(e.segments[h]={start:u,startTimeMinutes:s?e.startTimeMinutes:0,endTimeMinutes:n?e.endTimeMinutes:1440,isFirstDay:s,isLastDay:n}),a=i}return e}deleteAnEvent(e){this._vuecal.emitWithEvent("event-delete",e),this._vuecal.mutableEvents=this._vuecal.mutableEvents.filter((t=>t._eid!==e._eid)),this._vuecal.view.events=this._vuecal.view.events.filter((t=>t._eid!==e._eid))}checkCellOverlappingEvents(e,t){P=e.slice(0),F={},e.forEach((e=>{P.shift(),F[e._eid]||(F[e._eid]={overlaps:[],start:e.start,position:0}),F[e._eid].position=0,P.forEach((i=>{F[i._eid]||(F[i._eid]={overlaps:[],start:i.start,position:0});const s=this.eventInRange(i,e.start,e.end),n=t.overlapsPerTimeStep?R.datesInSameTimeStep(e.start,i.start,t.timeStep):1;if(e.background||e.allDay||i.background||i.allDay||!s||!n){let t,s;(t=(F[e._eid]||{overlaps:[]}).overlaps.indexOf(i._eid))>-1&&F[e._eid].overlaps.splice(t,1),(s=(F[i._eid]||{overlaps:[]}).overlaps.indexOf(e._eid))>-1&&F[i._eid].overlaps.splice(s,1),F[i._eid].position--}else F[e._eid].overlaps.push(i._eid),F[e._eid].overlaps=[...new Set(F[e._eid].overlaps)],F[i._eid].overlaps.push(e._eid),F[i._eid].overlaps=[...new Set(F[i._eid].overlaps)],F[i._eid].position++}))}));let i=0;for(const s in F){const e=F[s],t=e.overlaps.map((e=>({id:e,start:F[e].start})));t.push({id:s,start:e.start}),t.sort(((e,t)=>e.start<t.start?-1:e.start>t.start?1:e.id>t.id?-1:1)),e.position=t.findIndex((e=>e.id===s)),i=Math.max(this.getOverlapsStreak(e,F),i)}return[F,i]}getOverlapsStreak(e,t={}){let i=e.overlaps.length+1,s=[];return e.overlaps.forEach((i=>{s.includes(i)||e.overlaps.filter((e=>e!==i)).forEach((e=>{t[e].overlaps.includes(i)||s.push(e)}))})),s=[...new Set(s)],i-=s.length,i}eventInRange(e,t,i){if(e.allDay||!this._vuecal.time){const s=new Date(e.start).setHours(0,0,0,0);return new Date(e.end).setHours(23,59,0,0)>=new Date(t).setHours(0,0,0,0)&&s<=new Date(i).setHours(0,0,0,0)}const s=e.start.getTime(),n=e.end.getTime();return s<i.getTime()&&n>t.getTime()}}const G={class:"vuecal__flex vuecal__weekdays-headings"},U=["onClick"],Q={class:"vuecal__flex weekday-label",grow:""},z={class:"full"},K={class:"small"},q={class:"xsmall"},J={key:0},Z={key:0,class:"vuecal__flex vuecal__split-days-headers",grow:""},ee=(e,t)=>{const i=e.__vccOpts||e;for(const[s,n]of t)i[s]=n;return i},te=ee({inject:["vuecal","utils","view"],props:{transitionDirection:{type:String,default:"right"},weekDays:{type:Array,default:()=>[]},switchToNarrowerView:{type:Function,default:()=>{}}},methods:{selectCell(e,t){e.getTime()!==this.view.selectedDate.getTime()&&(this.view.selectedDate=e),this.utils.cell.selectCell(!1,e,t)},cleanupHeading:e=>({label:e.full,date:e.date,...e.today?{today:e.today}:{}})},computed:{headings(){if(!["month","week"].includes(this.view.id))return[];let e=!1;return this.weekDays.map(((t,i)=>{const s=this.utils.date.addDays(this.view.startDate,this.vuecal.startWeekOnSunday?i-1:i);return{hide:t.hide,full:t.label,small:t.short||t.label.substr(0,3),xsmall:t.short||t.label.substr(0,1),..."week"===this.view.id?{dayOfMonth:s.getDate(),date:s,today:!e&&this.utils.date.isToday(s)&&!e++}:{}}}))},cellWidth(){return 100/(7-this.weekDays.reduce(((e,t)=>e+t.hide),0))},weekdayCellStyles(){return{...this.vuecal.hideWeekdays.length?{width:`${this.cellWidth}%`}:{}}},cellHeadingsClickable(){return"week"===this.view.id&&(this.vuecal.clickToNavigate||this.vuecal.dblclickToNavigate)}}},[["render",function(e,t,i,l,o,r){return(0,s.uX)(),(0,s.CE)("div",G,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.headings,((l,o)=>((0,s.uX)(),(0,s.CE)(s.FK,{key:o},[l.hide?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",{key:0,class:(0,n.C4)(["vuecal__flex vuecal__heading",{today:l.today,clickable:r.cellHeadingsClickable}]),style:(0,n.Tr)(r.weekdayCellStyles),onClick:e=>"week"===r.view.id&&r.selectCell(l.date,e),onDblclick:t[0]||(t[0]=e=>"week"===r.view.id&&r.vuecal.dblclickToNavigate&&i.switchToNarrowerView())},[(0,s.bF)(a.eB,{name:`slide-fade--${i.transitionDirection}`,appear:r.vuecal.transitions},{default:(0,s.k6)((()=>[((0,s.uX)(),(0,s.CE)("div",{class:"vuecal__flex",column:"",key:!!r.vuecal.transitions&&`${o}-${l.dayOfMonth}`},[(0,s.Lk)("div",Q,[(0,s.RG)(e.$slots,"weekday-heading",{heading:r.cleanupHeading(l),view:r.view},(()=>[(0,s.Lk)("span",z,(0,n.v_)(l.full),1),(0,s.Lk)("span",K,(0,n.v_)(l.small),1),(0,s.Lk)("span",q,(0,n.v_)(l.xsmall),1),l.dayOfMonth?((0,s.uX)(),(0,s.CE)("span",J," "+(0,n.v_)(l.dayOfMonth),1)):(0,s.Q3)("",!0)]))]),r.vuec
6al.hasSplits&&r.vuecal.stickySplitLabels?((0,s.uX)(),(0,s.CE)("div",Z,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.vuecal.daySplits,((t,i)=>((0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["day-split-header",t.class||!1]),key:i},[(0,s.RG)(e.$slots,"split-label",{split:t,view:r.view},(()=>[(0,s.eW)((0,n.v_)(t.label),1)]))],2)))),128))])):(0,s.Q3)("",!0)]))])),_:2},1032,["name","appear"])],46,U))],64)))),128))])}]]),ie={class:"vuecal__header"},se={key:0,class:"vuecal__flex vuecal__menu",role:"tablist","aria-label":"Calendar views navigation"},ne=["onDragenter","onDragleave","onClick","aria-label"],ae={key:1,class:"vuecal__title-bar"},le=["aria-label"],oe={class:"vuecal__flex vuecal__title",grow:""},re=["aria-label"],de={key:0,class:"vuecal__flex vuecal__split-days-headers"},ce=ee({inject:["vuecal","previous","next","switchView","updateSelectedDate","modules","view"],components:{WeekdaysHeadings:te},props:{options:{type:Object,default:()=>({})},editEvents:{type:Object,required:!0},hasSplits:{type:[Boolean,Number],default:!1},daySplits:{type:Array,default:()=>[]},viewProps:{type:Object,default:()=>({})},weekDays:{type:Array,default:()=>[]},switchToNarrowerView:{type:Function,default:()=>{}}},data:()=>({highlightedControl:null}),methods:{goToToday(){this.updateSelectedDate(new Date((new Date).setHours(0,0,0,0)))},switchToBroaderView(){this.transitionDirection="left",this.broaderView&&this.switchView(this.broaderView)}},computed:{transitionDirection:{get(){return this.vuecal.transitionDirection},set(e){this.vuecal.transitionDirection=e}},broaderView(){const{enabledViews:e}=this.vuecal;return e[e.indexOf(this.view.id)-1]}
6,showDaySplits(){return"day"===this.view.id&&this.hasSplits&&this.options.stickySplitLabels&&!this.options.minSplitWidth},dnd(){return this.modules.dnd}}},[["render",function(e,t,i,l,o,r){const d=(0,s.g2)("weekdays-headings");return(0,s.uX)(),(0,s.CE)("div",ie,[i.options.hideViewSelector?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",se,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(i.viewProps.views,((t,a)=>((0,s.uX)(),(0,s.CE)(s.FK,{key:a},[t.enabled?((0,s.uX)(),(0,s.CE)("button",{key:0,class:(0,n.C4)(["vuecal__view-btn",{"vuecal__view-btn--active":r.view.id===a,"vuecal__view-btn--highlighted":e.highlightedControl===a}]),type:"button",onDragenter:t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragEnter(t,a,e.$data),onDragleave:t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragLeave(t,a,e.$data),onClick:e=>r.switchView(a,null,!0),"aria-label":`${t.label} view`},(0,n.v_)(t.label),43,ne)):(0,s.Q3)("",!0)],64)))),128))])),i.options.hideTitleBar?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",ae,[(0,s.Lk)("button",{class:(0,n.C4)(["vuecal__arrow vuecal__arrow--prev",{"vuecal__arrow--highlighted":"previous"===e.highlightedControl}]),type:"button",onClick:t[0]||(t[0]=(...e)=>r.previous&&r.previous(...e)),onDragenter:t[1]||(t[1]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragEnter(t,"previous",e.$data)),onDragleave:t[2]||(t[2]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragLeave(t,"previous",e.$data)),"aria-label":`Previous ${r.view.id}`},[(0,s.RG)(e.$slots,"arrow-prev")],42,le),(0,s.Lk)("div",oe,[(0,s.bF)(a.eB,{name:i.options.transitions?`slide-fade--${r.transitionDirection}`:""},{default:(0,s.k6)((()=>[((0,s.uX)(),(0,s.Wv)((0,s.$y)(r.broaderView?"button":"span"),{type:!!r.broaderView&&"button",key:`${r.view.id}${r.view.startDate.toString()}`,onClick:t[3]||(t[3]=e=>!!r.broaderView&&r.switchToBroaderView()),"aria-label":!!r.broaderView&&`Go to ${r.broaderView} view`},{default:(0,s.k6)((()=>[(0,s.RG)(e.$slots,"title")])),_:3},8,["type","aria-label"]))])),_:3},8,["name"])]),i.options.todayButton?((0,s.uX)(),(0,s.CE)("button",{key:0,class:(0,n.C4)(["vuecal__today-btn",{"vuecal__today-btn--highlighted":"today"===e.highlightedControl}]),type:"button",onClick:t[4]||(t[4]=(...e)=>r.goToToday&&r.goToToday(...e)),onDragenter:t[5]||(t[5]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragEnter(t,"today",e.$data)),onDragleave:t[6]||(t[6]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragLeave(t,"today",e.$data)),"aria-label":"Today"},[(0,s.RG)(e.$slots,"today-button")],34)):(0,s.Q3)("",!0),(0,s.Lk)("button",{class:(0,n.C4)(["vuecal__arrow vuecal__arrow--next",{"vuecal__arrow--highlighted":"next"===e.highlightedControl}]),type:"button",onClick:t[7]||(t[7]=(...e)=>r.next&&r.next(...e)),onDragenter:t[8]||(t[8]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragEnter(t,"next",e.$data)),onDragleave:t[9]||(t[9]=t=>i.editEvents.drag&&r.dnd&&r.dnd.viewSelectorDragLeave(t,"next",e.$data)),"aria-label":`Next ${r.view.id}`},[(0,s.RG)(e.$slots,"arrow-next")],42,re)])),i.viewProps.weekDaysInHeader?((0,s.uX)(),(0,s.Wv)(d,{key:2,"week-days":i.weekDays,"transition-direction":r.transitionDirection,"switch-to-narrower-view":i.switchToNarrowerView},(0,s.eX)({_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,s.k6)((({heading:t,view:i})=>[(0,s.RG)(e.$slots,"weekday-heading",{heading:t,view:i})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,s.k6)((({split:t})=>[(0,s.RG)(e.$slots,"split-label",{split:t,view:r.view})])),key:"1"}:void 0]),1032,["week-days","transition-direction","switch-to-narrower-view"])):(0,s.Q3)("",!0),(0,s.bF)(a.eB,{name:`slide-fade--${r.transitionDirection}`},{default:(0,s.k6)((()=>[r.showDaySplits?((0,s.uX)(),(0,s.CE)("div",de,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(i.daySplits,((t,i)=>((0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["day-split-header",t.class||!1]),key:i},[(0,s.RG)(e.$slots,"split-label",{split:t,view:r.view.id},(()=>[(0,s.eW)((0,n.v_)(t.label),1)]))],2)))),128))])):(0,s.Q3)("",!0)])),_:3},8,["name"])])}]]),ue=["draggable"],he={inject:["vuecal","utils","modules","view","domEvents","editEvents"],props:{cellFormattedDate:{type:String,default:""},event:{type:Object,default:()=>({})},cellEvents:{type:Array,default:()=>[]},overlaps:{type:Array,default:()=>[]},eventPosition:{type:Number,default:0},overlapsStreak:{type:Number,default:0},allDay:{type:Boolean,default:!1}},data:()=>({touch:{dragThreshold:30,startX:0,startY:0,dragged:!1}}),methods:{onMouseDown(e,t=!1){if("ontouchstart"in window&&!t)return!1;const{clickHoldAnEvent:i,focusAnEvent:s,resizeAnEvent:n,dragAnEvent:a}=this.domEvents;if(s._eid===this.event._eid&&i._eid===this.event._eid)return!0;this.focusEvent(),i._eid=null,this.vuecal.editEvents.delete&&this.event.deletable&&(i.timeoutId=setTimeout((()=>{n._eid||a._eid||(i._eid=this.event._eid,this.event.deleting=!0)}),i.timeout))},onMouseUp(e){this.domEvents.focusAnEvent._eid!==this.event._eid||this.touch.dragged||(this.domEvents.focusAnEvent.mousedUp=!0),this.touch.dragged=!1},onMouseEnter(e){e.preventDefault(),this.vuecal.emitWithEvent("event-mouse-enter",this.event)},onMouseLeave(e){e.preventDefault(),this.vuecal.emitWithEvent("event-mouse-leave",this.event)},onTouchMove(e){if("function"!=typeof this.vuecal.onEventClick)return;const{clientX:t,clientY:i}=e.touches[0],{startX:s,startY:n,dragThreshold:a}=this.touch;(Math.abs(t-s)>a||Math.abs(i-n)>a)&&(this.touch.dragged=!0)},onTouchStart(e){this.touch.startX=e.touches[0].clientX,this.touch.startY=e.touches[0].clientY,this.onMouseDown(e,!0)},onEnterKeypress(e){if("function"==typeof this.vuecal.onEventClick)return this.vuecal.onEventClick(this.event,e)},onDblClick(e){if("function"==typeof this.vuecal.onEventDblclick)return this.vuecal.onEventDblclick(this.event,e)},onDragStart(e){this.dnd&&this.dnd.eventDragStart(e,this.event)},onDragEnd(){this.dnd&&this.dnd.eventDragEnd(this.event)},onResizeHandleMouseDown(){this.focusEvent(),this.domEvents.dragAnEvent._eid=null,this.domEvents.resizeAnEvent=Object.assign(this.domEvents.resizeAnEvent,{_eid:this.event._eid,start:(this.segment||this.event).start,split:this.event.split||null,segment:!!this.segment&&this.utils.date.formatDateLite(this.segment.start),originalEnd:new Date((this.segment||this.event).end),originalEndTimeMinutes:this.event.endTimeMinutes}),this.event.resizing=!0},deleteEvent(e=!1){if("ontouchstart"in window&&!e)return!1;this.utils.event.deleteAnEvent(this.event)},touchDeleteEvent(e){this.deleteEvent(!0)},cancelDeleteEvent(){this.event.deleting=!1},focusEvent(){const{focusAnEvent:e}=this.domEvents,t=e._eid;if(t!==this.event._eid){if(t){const e=this.view.events.find((e=>e._eid===t));e&&(e.focused=!1)}this.vuecal.cancelDelete(),this.vuecal.emitWithEvent("event-focus",this.event),e._eid=this.event._eid,this.event.focused=!0}}},computed:{eventDimensions(){const{startTimeMinutes:e,endTimeMinutes:t}=this.segment||this.event;let i=e-this.vuecal.timeFrom;const s=Math.max(Math.round(i*this.vuecal.timeCellHeight/this.vuecal.timeStep),0);i=Math.min(t,this.vuecal.timeTo)-this.vuecal.timeFrom;const n=Math.round(i*this.vuecal.timeCellHeight/this.vuecal.timeStep);return{top:s,height:Math.max(n-s,5)}},eventStyles(){if(this.event.allDay||!this.vuecal.time||!this.event.endTimeMinutes||"month"===this.view.id||this.allDay)return{};let e=100/Math.min(this.overlaps.length+1,this.overlapsStreak),t=100/(this.overlaps.length+1)*this.eventPosition;this.vuecal.minEventWidth&&e<this.vuecal.minEventWidth&&(e=this.vuecal.minEventWidth,t=(100-this.vuecal.minEventWidth)/this.overlaps.length*this.eventPosition);const{top:i,height:s}=this.eventDimensions;return{top:`${i}px`,height:`${s}px`,width:`${e}%`,left:this.event.left&&`${this.event.left}px`||`${t}%`}},eventClasses(){const{isFirstDay:e,isLastDay:t}=this.segment||{};return{[this.event.class]:!!this.event.class,"vuecal__event--focus":this.event.focused,"vuecal__event--resizing":this.event.resizing,"vuecal__event--background":this.event.background,"vuecal__event--deletable":this.event.deleting,"vuecal__event--all-day":this.event.allDay,"vuecal__event--dragging":!this.event.draggingStatic&&this.event.dragging,"vuecal__event--static":this.event.dragging&&this.event.draggingStatic,"vuecal__event--multiple-days":!!this.segment,"event-start":this.segment&&e&&!t,"event-mid
6dle":this.segment&&!e&&!t,"event-end":this.segment&&t&&!e}},segment(){return this.event.segments&&this.event.segments[this.cellFormattedDate]||null},draggable(){const{draggable:e,background:t,daysCount:i}=this.event;return this.vuecal.editEvents.drag&&e&&!t&&1===i},resizable(){const{editEvents:e,time:t}=this.vuecal;return e.resize&&this.event.resizable&&t&&!this.allDay&&(!this.segment||this.segment&&this.segment.isLastDay)&&"month"!==this.view.id},dnd(){return this.modules.dnd}}},ve=["data-split","aria-label","onTouchstart","onMousedown","onDragover","onDrop"],pe={key:0,class:"cell-time-labels"},me=["innerHTML"],ge={key:2,class:"vuecal__cell-events"},fe=["title"],ye=ee({inject:["vuecal","utils","modules","view","domEvents"],components:{Event:ee(he,[["render",function(e,t,i,l,o,r){return(0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["vuecal__event",r.eventClasses]),style:(0,n.Tr)(r.eventStyles),tabindex:"0",onFocus:t[4]||(t[4]=(...e)=>r.focusEvent&&r.focusEvent(...e)),onKeypress:t[5]||(t[5]=(0,a.jR)((0,a.D$)(((...e)=>r.onEnterKeypress&&r.onEnterKeypress(...e)),["stop"]),["enter"])),onMouseenter:t[6]||(t[6]=(...e)=>r.onMouseEnter&&r.onMouseEnter(...e)),onMouseleave:t[7]||(t[7]=(...e)=>r.onMouseLeave&&r.onMouseLeave(...e)),onTouchstart:t[8]||(t[8]=(0,a.D$)(((...e)=>r.onTouchStart&&r.onTouchStart(...e)),["stop"])),onMousedown:t[9]||(t[9]=e=>r.onMouseDown(e)),onMouseup:t[10]||(t[10]=(...e)=>r.onMouseUp&&r.onMouseUp(...e)),onTouchend:t[11]||(t[11]=(...e)=>r.onMouseUp&&r.onMouseUp(...e)),onTouchmove:t[12]||(t[12]=(...e)=>r.onTouchMove&&r.onTouchMove(...e)),onDblclick:t[13]||(t[13]=(...e)=>r.onDblClick&&r.onDblClick(...e)),draggable:r.draggable,onDragstart:t[14]||(t[14]=e=>r.draggable&&r.onDragStart(e)),onDragend:t[15]||(t[15]=e=>r.draggable&&r.onDragEnd())},[r.vuecal.editEvents.delete&&i.event.deletable?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"vuecal__event-delete",onClick:t[0]||(t[0]=(0,a.D$)(((...e)=>r.deleteEvent&&r.deleteEvent(...e)),["stop"])),onTouchstart:t[1]||(t[1]=(0,a.D$)(((...e)=>r.touchDeleteEvent&&r.touchDeleteEvent(...e)),["stop"]))},(0,n.v_)(r.vuecal.texts.deleteEvent),33)):(0,s.Q3)("",!0),(0,s.RG)(e.$slots,"event",{event:i.event,view:r.view.id}),r.resizable?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__event-resize-handle",contenteditable:"false",onMousedown:t[2]||(t[2]=(0,a.D$)(((...e)=>r.onResizeHandleMouseDown&&r.onResizeHandleMouseDown(...e)),["stop","prevent"])),onTouchstart:t[3]||(t[3]=(0,a.D$)(((...e)=>r.onResizeHandleMouseDown&&r.onResizeHandleMouseDown(...e)),["stop","prevent"]))},null,32)):(0,s.Q3)("",!0)],46,ue)}]])},props:{options:{type:Object,default:()=>({})},editEvents:{type:Object,required:!0},data:{type:Object,required:!0},cellSplits:{type:Array,default:()=>[]},minTimestamp:{type:[Number,null],default:null},maxTimestamp:{type:[Number,null],default:null},cellWidth:{type:[Number,Boolean],default:!1},allDay:{type:Boolean,default:!1}},data:()=>({cellOverlaps:{},cellOverlapsStreak:1,timeAtCursor:null,highlighted:!1,highlightedSplit:null}),methods:{getSplitAtCursor({target:e}){let t=e.classList.contains("vuecal__cell-split")?e:this.vuecal.findAncestor(e,"vuecal__cell-split");return t&&(t=t.attributes["data-split"].value,parseInt(t).toString()===t.toString()&&(t=parseInt(t))),t||null},splitClasses(e){return{"vuecal__cell-split":!0,"vuecal__cell-split--highlighted":this.highlightedSplit===e.id,[e.class]:!!e.class}},checkCellOverlappingEvents(){this.options.time&&this.eventsCount&&!this.splitsCount&&(1===this.eventsCount?(this.cellOverlaps=[],this.cellOverlapsStreak=1):[this.cellOverlaps,this.cellOverlapsStreak]=this.utils.event.checkCellOverlappingEvents(this.events,this.options))},isDOMElementAnEvent(e){return this.vuecal.isDOMElementAnEvent(e)},selectCell(e,t=!1){const i=this.splitsCount?this.getSplitAtCursor(e):null;this.utils.cell.selectCell(t,this.timeAtCursor,i),this.timeAtCursor=null},onCellkeyPressEnter(e){this.isSelected||this.onCellFocus(e);const t=this.splitsCount?this.getSplitAtCursor(e):null;this.utils.cell.keyPressEnterCell(this.timeAtCursor,t),this.timeAtCursor=null},onCellFocus(e){if(!this.isSelected&&!this.isDisabled){this.isSelected=this.data.startDate;
6const t=this.splitsCount?this.getSplitAtCursor(e):null,i=this.timeAtCursor||this.data.startDate;this.vuecal.$emit("cell-focus",t?{date:i,split:t}:i)}},onCellMouseDown(e,t=null,i=!1){if("ontouchstart"in window&&!i)return!1;this.isSelected||this.onCellFocus(e);const{clickHoldACell:s,focusAnEvent:n}=this.domEvents;this.domEvents.cancelClickEventCreation=!1,s.eventCreated=!1,this.timeAtCursor=new Date(this.data.startDate);const{minutes:a,cursorCoords:{y:l}}=this.vuecal.minutesAtCursor(e);this.timeAtCursor.setMinutes(a);const o=this.isDOMElementAnEvent(e.target);!o&&n._eid&&((this.view.events.find((e=>e._eid===n._eid))||{}).focused=!1),this.editEvents.create&&!o&&this.setUpEventCreation(e,l)},setUpEventCreation(e,t){if(this.options.dragToCreateEvent&&["week","day"].includes(this.view.id)){const{dragCreateAnEvent:i}=this.domEvents;if(i.startCursorY=t,i.split=this.splitsCount?this.getSplitAtCursor(e):null,i.start=this.timeAtCursor,this.options.snapToTime){let e=60*this.timeAtCursor.getHours()+this.timeAtCursor.getMinutes();const t=e+this.options.snapToTime/2;e=t-t%this.options.snapToTime,i.start.setHours(0,e,0,0)}}else this.options.cellClickHold&&["month","week","day"].includes(this.view.id)&&this.setUpCellHoldTimer(e)},setUpCellHoldTimer(e){const{clickHoldACell:t}=this.domEvents;t.cellId=`${this.vuecal._.uid}_${this.data.formattedDate}`,t.split=this.splitsCount?this.getSplitAtCursor(e):null,t.timeoutId=setTimeout((()=>{if(t.cellId&&!this.domEvents.cancelClickEventCreation){const{_eid:e}=this.utils.event.createAnEvent(this.timeAtCursor,null,t.split?{split:t.split}:{});t.eventCreated=e}}),t.timeout)},onCellTouchStart(e,t=null){this.onCellMouseDown(e,t,!0)},onCellClick(e){this.isDOMElementAnEvent(e.target)||this.selectCell(e)},onCellDblClick(e){const t=new Date(this.data.startDate);t.setMinutes(this.vuecal.minutesAtCursor(e).minutes);const i=this.splitsCount?this.getSplitAtCursor(e):null;this.vuecal.$emit("cell-dblclick",i?{date:t,split:i}:t),this.options.dblclickToNavigate&&this.vuecal.switchToNarrowerView()},onCellContextMenu(e){e.stopPropagation(),e.preventDefault();const t=new Date(this.data.startDate),{cursorCoords:i,minutes:s}=this.vuecal.minutesAtCursor(e);t.setMinutes(s);const n=this.splitsCount?this.getSplitAtCursor(e):null;this.vuecal.$emit("cell-contextmenu",{date:t,...i,...n||{},e:e})}},computed:{dnd(){return this.modules.dnd},nowInMinutes(){return this.utils.date.dateToMinutes(this.vuecal.now)},isBeforeMinDate(){return null!==this.minTimestamp&&this.minTimestamp>this.data.endDate.getTime()},isAfterMaxDate(){return this.maxTimestamp&&this.maxTimestamp<this.data.startDate.getTime()},isDisabled(){const{disableDays:e}=this.options,{isYearsOrYearView:t}=this.vuecal;return!(!e.length||!e.includes(this.data.formattedDate)||t)||this.isBeforeMinDate||this.isAfterMaxDate},isSelected:{get(){let e=!1;const{selectedDate:t}=this.view;return e="years"===this.view.id?t.getFullYear()===this.data.startDate.getFullYear():"year"===this.view.id?t.getFullYear()===this.data.startDate.getFullYear()&&t.getMonth()===this.data.startDate.getMonth():t.getTime()===this.data.startDate.getTime(),e},set(e){this.view.selectedDate=e,this.vuecal.$emit("update:selected-date",this.view.selectedDate)}},isWeekOrDayView(){return["week","day"].includes(this.view.id)},transitionDirection(){return this.vuecal.transitionDirection},specialHours(){return this.data.specialHours.map((e=>{let{from:t,to:i}=e;return t=Math.max(t,this.options.timeFrom),i=Math.min(i,this.options.timeTo),{...e,height:(i-t)*this.timeScale,top:(t-this.options.timeFrom)*this.timeScale}}))},events(){const{startDate:e,endDate:t}=this.data;let i=[];if(!["years","year"].includes(this.view.id)||this.options.eventsCountOnYearView){if(i=this.view.events.slice(0),"month"===this.view.id&&i.push(...this.view.outOfScopeEvents),i=i.filter((i=>this.utils.event.eventInRange(i,e,t))),this.options.showAllDayEvents&&"month"!==this.view.id&&(i=i.filter((e=>!!e.allDay===this.allDay))),this.options.time&&this.isWeekOrDayView&&!this.allDay){const{timeFrom:e,timeTo:t}=this.options;i=i.filter((i=>{const s=i.daysCount>1&&i.segments[this.data.formattedDate]||{},n=1===i.daysCount&&i.startTimeMinutes<t&&i.endTimeMinutes>e,a=i.daysCount>1&&s.startTimeMinutes<t&&s.endTimeMinutes>e;return i.allDay||n||a||!1}))}!this.options.time||!this.isWeekOrDayView||this.options.showAllDayEvents&&this.allDay||i.sort(((e,t)=>e.start<t.start?-1:1)),this.cellSplits.length||this.$nextTick(this.checkCellOverlappingEvents)}return i},eventsCount(){return this.events.length},splits(){return this.cellSplits.map(((e,t)=>{const i=this.events.filter((t=>t.split===e.id)),[s,n]=this.utils.event.checkCellOverlappingEvents(i.filter((e=>!e.background&&!e.allDay)),this.options);return{...e,overlaps:s,overlapsStreak:n,events:i}}))},splitsCount(){return this.splits.length},cellClasses(){return{[this.data.class]:!!this.data.class,"vuecal__cell--current":this.data.current,"vuecal__cell--today":this.data.today,"vuecal__cell--out-
6of-scope":this.data.outOfScope,"vuecal__cell--before-min":this.isDisabled&&this.isBeforeMinDate,"vuecal__cell--after-max":this.isDisabled&&this.isAfterMaxDate,"vuecal__cell--disabled":this.isDisabled,"vuecal__cell--selected":this.isSelected,"vuecal__cell--highlighted":this.highlighted,"vuecal__cell--has-splits":this.splitsCount,"vuecal__cell--has-events":this.eventsCount}},cellStyles(){return{...this.cellWidth?{width:`${this.cellWidth}%`}:{}}},timelineVisible(){const{time:e,timeTo:t}=this.options;return this.data.today&&this.isWeekOrDayView&&e&&!this.allDay&&this.nowInMinutes<=t},todaysTimePosition(){if(!this.data.today||!this.options.time)return;const e=this.nowInMinutes-this.options.timeFrom;return Math.round(e*this.timeScale)},timeScale(){return this.options.timeCellHeight/this.options.timeStep}}},[["render",function(e,t,i,l,o,r){const d=(0,s.g2)("event");return(0,s.uX)(),(0,s.Wv)(a.F,{class:(0,n.C4)(["vuecal__cell",r.cellClasses]),name:`slide-fade--${r.transitionDirection}`,tag:"div",appear:i.options.transitions,style:(0,n.Tr)(r.cellStyles)},{default:(0,s.k6)((()=>[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.splitsCount?r.splits:1,((l,o)=>((0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["vuecal__flex vuecal__cell-content",r.splitsCount&&r.splitClasses(l)]),key:i.options.transitions?`${r.view.id}-${i.data.content}-${o}`:o,"data-split":!!r.splitsCount&&l.id,column:"",tabindex:"0","aria-label":i.data.content,onFocus:t[0]||(t[0]=e=>r.onCellFocus(e)),onKeypress:t[1]||(t[1]=(0,a.jR)((e=>r.onCellkeyPressEnter(e)),["enter"])),onTouchstart:e=>!r.isDisabled&&r.onCellTouchStart(e,r.splitsCount?l.id:null),onMousedown:e=>!r.isDisabled&&r.onCellMouseDown(e,r.splitsCount?l.id:null),onClick:t[2]||(t[2]=e=>!r.isDisabled&&r.onCellClick(e)),onDblclick:t[3]||(t[3]=e=>!r.isDisabled&&r.onCellDblClick(e)),onContextmenu:t[4]||(t[4]=e=>!r.isDisabled&&i.options.cellContextmenu&&r.onCellContextMenu(e)),onDragenter:t[5]||(t[5]=t=>!r.isDisabled&&i.editEvents.drag&&r.dnd&&r.dnd.cellDragEnter(t,e.$data,i.data.startDate)),onDragover:t=>!r.isDisabled&&i.editEvents.drag&&r.dnd&&r.dnd.cellDragOver(t,e.$data,i.data.startDate,r.splitsCount?l.id:null),onDragleave:t[6]||(t[6]=t=>!r.isDisabled&&i.editEvents.drag&&r.dnd&&r.dnd.cellDragLeave(t,e.$data,i.data.startDate)),onDrop:t=>!r.isDisabled&&i.editEvents.drag&&r.dnd&&r.dnd.cellDragDrop(t,e.$data,i.data.startDate,r.splitsCount?l.id:null)},[i.options.showTimeInCells&&i.options.time&&r.isWeekOrDayView&&!i.allDay?((0,s.uX)(),(0,s.CE)("div",pe,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.vuecal.timeCells,((e,t)=>((0,s.uX)(),(0,s.CE)("span",{class:"cell-time-label",key:t},(0,n.v_)(e.label),1)))),128))])):(0,s.Q3)("",!0),r.isWeekOrDayView&&!i.allDay&&r.specialHours.length?((0,s.uX)(!0),(0,s.CE)(s.FK,{key:1},(0,s.pI)(r.specialHours,((e,t)=>((0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["vuecal__special-hours",`vuecal__special-hours--day${e.day} ${e.class}`]),style:(0,n.Tr)(`height: ${e.height}px;top: ${e.top}px`)},[e.label?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"special-hours-label",innerHTML:e.label},null,8,me)):(0,s.Q3)("",!0)],6)))),256)):(0,s.Q3)("",!0),(0,s.RG)(e.$slots,"cell-content",{events:r.events,selectCell:e=>r.selectCell(e,!0),split:!!r.splitsCount&&l}),r.eventsCount&&(r.isWeekOrDayView||"month"===r.view.id&&i.options.eventsOnMonthView)?((0,s.uX)(),(0,s.CE)("div",ge,[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.splitsCount?l.events:r.events,((t,n)=>((0,s.uX)(),(0,s.Wv)(d,{key:n,"cell-formatted-date":i.data.formattedDate,event:t,"all-day":i.allDay,"cell-events":r.splitsCount?l.events:r.events,overlaps:((r.splitsCount?l.overlaps[t._eid]:e.cellOverlaps[t._eid])||[]).overlaps,"event-position":((r.splitsCount?l.overlaps[t._eid]:e.cellOverlaps[t._eid])||[]).position,"overlaps-streak":r.splitsCount?l.overlapsStreak:e.cellOverlapsStreak},{event:(0,s.k6)((({event:t,view:i})=>[(0,s.RG)(e.$slots,"event",{view:i,event:t})])),_:2},1032,["cell-formatted-date","event","all-day","cell-events","overlaps","event-position","overlaps-streak"])))),128))])):(0,s.Q3)("",!0)],42,ve)))),128)),r.timelineVisible?((0,s.uX)(),(0,s.CE)("div",{class:"vuecal__now-line",style:(0,n.Tr)(`top: ${r.todaysTimePosition}px`),key:i.options.transitions?`${r.view.id}-now-line`:"now-line",title:r.utils.date.formatTime(r.vuecal.now)},null,12,fe)):(0,s.Q3)("",!0)])),_:3},8,["class","name","appear","style"])}]]),we={key:0,class:"vuecal__all-day-text",style:{width:"3em"}},be=ee({inject:["vuecal","view","editEvents"],components:{"vuecal-cell":ye},props:{options:{type:Object,required:!0},cells:{type:Array,required:!0},label:{type:String,required:!0},daySplits:{type:Array,default:()=>[]},shortEvents:{type:Boolean,default:!0},height:{type:String,default:""},cellOrSplitMinWidth:{type:Number,default:null}},computed:{hasCellOrSplitWidth(){return!!(this.options.minCellWidth||this.daySplits.length&&this.options.minSplitWidth)}}},[["render",function(e,t,i,a,l,o){const r=(0,s.g2)("vuecal-cell");return(0,s.uX)(),(0,s.CE)("div",{class:"vuecal__flex vuecal__all-day",style:(0,n.Tr)(i.cellOrSplitMinWidth&&{height:i.height})},[i.cellOrSplitMinWidth?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",we,[(0,s.Lk)("span",null,(0,n.v_)(i.label),1)])),(0,s.Lk)("div",{class:(0,n.C4)(["vuec
6al__flex vuecal__cells",`${o.view.id}-view`]),grow:"",style:(0,n.Tr)(i.cellOrSplitMinWidth?`min-width: ${i.cellOrSplitMinWidth}px`:"")},[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(i.cells,((t,n)=>((0,s.uX)(),(0,s.Wv)(r,{key:n,options:i.options,"edit-events":o.editEvents,data:t,"all-day":!0,"cell-width":i.options.hideWeekdays.length&&(o.vuecal.isWeekView||o.vuecal.isMonthView)&&o.vuecal.cellWidth,"min-timestamp":i.options.minTimestamp,"max-timestamp":i.options.maxTimestamp,"cell-splits":i.daySplits},{event:(0,s.k6)((({event:t,view:i})=>[(0,s.RG)(e.$slots,"event",{view:i,event:t})])),_:2},1032,["options","edit-events","data","cell-width","min-timestamp","max-timestamp","cell-splits"])))),128))],6)],4)}]]),ke=["lang"],De=(0,s.Lk)("i",{class:"angle"},null,-1),Ce=(0,s.Lk)("i",{class:"angle"},null,-1),Ee={class:"default"},_e={key:0,class:"vuecal__flex vuecal__body",grow:""},Ae=["onBlur","innerHTML"],Se=["innerHTML"],Te=["innerHTML"],Me={class:"vuecal__flex",row:"",grow:""},Le={key:0,class:"vuecal__time-column"},xe=(0,s.Lk)("span",{class:"vuecal__time-cell-line"},null,-1),Be={class:"vuecal__time-cell-label"},$e={key:1,class:"vuecal__flex vuecal__week-numbers",column:""},Oe=["wrap","column"],Ve=["onBlur","innerHTML"],We=["innerHTML"],Ie=["innerHTML"],He=["wrap"],Re=["innerHTML"],Fe=["innerHTML"],Pe={key:2,class:"vuecal__cell-events-count"},Xe={key:3,class:"vuecal__no-event"},je=["onBlur","innerHTML"],Ne=["innerHTML"],Ye={key:2,class:"vuecal__event-time"},Ge={key:0},Ue={key:1,class:"days-to-end"},Qe=["innerHTML"],ze={key:0,class:"vuecal__scrollbar-check"},Ke=[(0,s.Lk)("div",null,null,-1)],qe={weekDays:Array(7).fill(""),weekDaysShort:[],months:Array(12).fill(""),years:"",year:"",month:"",week:"",day:"",today:"",noEvent:"",allDay:"",deleteEvent:"",createEvent:"",dateFormat:"dddd MMMM D, YYYY",am:"am",pm:"pm"},Je=["years","year","month","week","day"],Ze=new class{constructor(e,t=!1){O(this,"texts",{}),O(this,"dateToMinutes",(e=>60*e.getHours()+e.getMinutes())),H=this,this._texts=e,t||!Date||Date.prototype.addDays||this._initDatePrototypes()}_initDatePrototypes(){Date.prototype.addDays=function(e){return H.addDays(this,e)},Date.prototype.subtractDays=function(e){return H.subtractDays(this,e)},Date.prototype.addHours=function(e){return H.addHours(this,e)},Date.prototype.subtractHours=function(e){return H.subtractHours(this,e)},Date.prototype.addMinutes=function(e){return H.addMinutes(this,e)},Date.prototype.subtractMinutes=function(e){return H.subtractMinutes(this,e)},Date.prototype.getWeek=function(){return H.getWeek(this)},Date.prototype.isToday=function(){return H.isToday(this)},Date.prototype.isLeapYear=function(){return H.isLeapYear(this)},Date.prototype.format=function(e="YYYY-MM-DD"){return H.formatDate(this,e)},Date.prototype.formatTime=function(e="HH:mm"){return H.formatTime(this,e)}}removePrototypes(){delete Date.prototype.addDays,delete Date.prototype.subtractDays,delete Date.prototype.addHours,delete Date.prototype.subtractHours,delete Date.prototype.addMinutes,delete Date.prototype.subtractMinutes,delete Date.prototype.getWeek,delete Date.prototype.isToday,delete Date.prototype.isLeapYear,delete Date.prototype.format,delete Date.prototype.formatTime}updateTexts(e){this._texts=e}_todayFormatted(){return W!==(new Date).getDate()&&(V=new Date,W=V.getDate(),I=`${V.getFullYear()}-${V.getMonth()}-${V.getDate()}`),I}addDays(e,t){const i=new Date(e.valueOf());return i.setDate(i.getDate()+t),i}subtractDays(e,t){const i=new Date(e.valueOf());return i.setDate(i.getDate()-t),i}addHours(e,t){const i=new Date(e.valueOf());return i.setHours(i.getHours()+t),i}subtractHours(e,t){const i=new Date(e.valueOf());return i.setHours(i.getHours()-t),i}addMinutes(e,t){const i=new Date(e.valueOf());return i.setMinutes(i.getMinutes()+t),i}subtractMinutes(e,t){const i=new Date(e.valueOf());return i.setMinutes(i.getMinutes()-t),i}getWeek(e){const t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate())),i=t.getUTCDay()||7;t.setUTCDate(t.getUTCDate()+4-i);const s=new Date(Date.UTC(t.getUTCFullYear(),0,1));return Math.ceil(((t-s)/864e5+1)/7)}isToday(e){return`${e.getFullYear()}-${e.getMonth()}-${e.getDate()}`===this._todayFormatted()}isLeapYear(e){const t=e.getFullYear();return!(t%400)||t%100&&!(t%4)}getPreviousFirstDayOfWeek(e=null,t){const i=e&&new Date(e.valueOf())||new Date,s=t?7:6;return i.setDate(i.getDate()-(i.getDay()+s)%7),i}stringToDate(e){return e instanceof Date?e:(10===e.length&&(e+=" 00:00"),new Date(e.replace(/-/g,"/")))}countDays(e,t){"string"==typeof e&&(e=e.replace(/-/g,"/")),"string"==typeof t&&(t=t.replace(/-/g,"/")),e=new Date(e).setHours(0,0,0,0),t=new Date(t).setHours(0,0,1,0);const i=60*(new Date(t).getTimezoneOffset()-new Date(e).getTimezoneOffset())*1e3;return Math.ceil((t-e-i)/864e5)}datesInSameTimeStep(e,t,i){return Math.abs(e.getTime()-t.getTime())<=60*i*1e3}formatDate(e,t="YYYY-MM-DD",i=null){if(i||(i=this._texts),t||(t="YYYY-MM-DD"),"YYYY-MM-DD"===t)return this.formatDateLite(e);X={},j={};const s={YYYY:()=>this._hydrateDateObject(e,i).YYYY,YY:()=>this._hydrateDateObject(e,i).YY(),M:()=>this._hydrateDateObject(e,i).M,MM:()=>this._hydrateDateObject(e,i).MM(),MMM:()=>this._hydrateDateObject(e,i).MMM(),MMMM:()=>this._hydrateDateObject(e,i).MMMM(),MMMMG:()=>this._hydrateDateObject(e,i).MMMMG(),D:()=>this._hydrateDateObject(e,i).D,DD:()=>this._hydrateDateObject(e,i).DD(),S:()=>this._hydrateDateObject(e,i).S(),d:()=>this._hydrateDateObject(e,i).d,dd:()=>this._hydrateDateObject(e,i).dd(),ddd:()=>this._hydrateDateObject(e,i).ddd(),dddd:()=>this._hydrateDateObject(e,i).dddd(),HH:()=>this._hydrateTimeObject(e,i).HH,H:()=>this._hydrateTimeObject(e,i).H,hh:()=>this._hydrateTimeObject(e,i).hh,h:()=>this._hydrateTimeObject(e,i).h,am:()=>this._hydrateTimeObject(e,i).am,AM:()=>this._hydrateTimeObject(e,i).AM,mm:()=>this._hydrateTimeObject(e,i).mm,m:()=>this._hydrateTimeObject(e,i).m};return t.replace(/(\{[a-zA-Z]+\}|[a-zA-Z]+)/g,((e,t)=>
6{const i=s[t.replace(/\{|\}/g,"")];return void 0!==i?i():t}))}formatDateLite(e){const t=e.getMonth()+1,i=e.getDate();return`${e.getFullYear()}-${t<10?"0":""}${t}-${i<10?"0":""}${i}`}formatTime(e,t="HH:mm",i=null,s=!1){let n=!1;if(s){const[t,i,s]=[e.getHours(),e.getMinutes(),e.getSeconds()];t+i+s===141&&(n=!0)}if(e instanceof Date&&"HH:mm"===t)return n?"24:00":this.formatTimeLite(e);j={},i||(i=this._texts);const a=this._hydrateTimeObject(e,i),l=t.replace(/(\{[a-zA-Z]+\}|[a-zA-Z]+)/g,((e,t)=>{const i=a[t.replace(/\{|\}/g,"")];return void 0!==i?i:t}));return n?l.replace("23:59","24:00"):l}formatTimeLite(e){const t=e.getHours(),i=e.getMinutes();return`${(t<10?"0":"")+t}:${(i<10?"0":"")+i}`}_nth(e){if(e>3&&e<21)return"th";switch(e%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}}_hydrateDateObject(e,t){if(X.D)return X;const i=e.getFullYear(),s=e.getMonth()+1,n=e.getDate(),a=(e.getDay()-1+7)%7;return X={YYYY:i,YY:()=>i.toString().substring(2),M:s,MM:()=>(s<10?"0":"")+s,MMM:()=>t.months[s-1].substring(0,3),MMMM:()=>t.months[s-1],MMMMG:()=>(t.monthsGenitive||t.months)[s-1],D:n,DD:()=>(n<10?"0":"")+n,S:()=>this._nth(n),d:a+1,dd:()=>t.weekDays[a][0],ddd:()=>t.weekDays[a].substr(0,3),dddd:()=>t.weekDays[a]},X}_hydrateTimeObject(e,t){if(j.am)return j;let i,s;e instanceof Date?(i=e.getHours(),s=e.getMinutes()):(i=Math.floor(e/60),s=Math.floor(e%60));const n=i%12?i%12:12,a=(t||{am:"am",pm:"pm"})[24===i||i<12?"am":"pm"];return j={H:i,h:n,HH:(i<10?"0":"")+i,hh:(n<10?"0":"")+n,am:a,AM:a.toUpperCase(),m:s,mm:(s<10?"0":"")+s},j}}(qe),et={name:"vue-cal",components:{"vuecal-cell":ye,"vuecal-header":ce,WeekdaysHeadings:te,AllDayBar:be},provide(){return{vuecal:this,utils:this.utils,modules:this.modules,previous:this.previous,next:this.next,switchView:this.switchView,updateSelectedDate:this.updateSelectedDate,editEvents:this.editEvents,view:this.view,domEvents:this.domEvents}},props:{activeView:{type:String,default:"week"},allDayBarHeight:{type:[String,Number],default:"25px"},cellClickHold:{type:Boolean,default:!0},cellContextmenu:{type:Boolean,default:!1},clickToNavigate:{type:Boolean,default:!1},dblclickToNavigate:{type:Boolean,default:!0},disableDatePrototypes:{type:Boolean,default:!1},disableDays:{type:Array,default:()=>[]},disableViews:{type:Array,default:()=>[]},dragToCreateEvent:{type:Boolean,default:!0},dragToCreateThreshold:{type:Number,default:15},editableEvents:{type:[Boolean,Object],default:!1},events:{type:Array,default:()=>[]},eventsCountOnYearView:{type:Boolean,default:!1},eventsOnMonthView:{type:[Boolean,String],default:!1},hideBody:{type:Boolean,default:!1},hideTitleBar:{type:Boolean,default:!1},hideViewSelector:{type:Boolean,default:!1},hideWeekdays:{type:Array,default:()=>[]},hideWeekends:{type:Boolean,default:!1},locale:{type:[String,Object],default:"en"},maxDate:{type:[String,Date],default:""},minCellWidth:{type:Number,default:0},minDate:{type:[String,Date],default:""},minEventWidth:{type:Number,default:0},minSplitWidth:{type:Number,default:0},onEventClick:{type:[Function,null],default:null},onEventCreate:{type:[Function,null],default:null},onEventDblclick:{type:[Function,null],default:null},overlapsPerTimeStep:{type:Boolean,default:!1},resizeX:{type:Boolean,default:!1},selectedDate:{type:[String,Date],default:""},showAllDayEvents:{type:[Boolean,String],default:!1},showTimeInCells:{type:Boolean,default:!1},showWeekNumbers:{type:[Boolean,String],default:!1},snapToTime:{type:Number,default:0},small:{type:Boolean,default:!1},specialHours:{type:Object,default:()=>({})},splitDays:{type:Array,default:()=>[]},startWeekOnSunday:{type:Boolean,default:!1},stickySplitLabels:{type:Boolean,default:!1},time:{type:Boolean,default:!0},timeCellHeight:{type:Number,default:40},timeFormat:{type:String,default:""},timeFrom:{type:Number,default:0},timeStep:{type:Number,default:60},timeTo:{type:Number,default:1440},todayButton:{type:Boolean,default:!1},transitions:{type:Boolean,default:!0},twelveHour:{type:Boolean,default:!1},watchRealTime:{type:Boolean,default:!1},xsmall:{type:Boolean,default:!1}},data(){return{ready:!1,texts:{...qe},utils:{date:!!this.disableDatePrototypes&&Ze.removePrototypes()||Ze,cell:null,event:null},modules:{dnd:null}
6,cellsEl:null,view:{id:"",title:"",startDate:null,endDate:null,firstCellDate:null,lastCellDate:null,selectedDate:null,events:[]},eventIdIncrement:1,now:new Date,timeTickerIds:[null,null],domEvents:{resizeAnEvent:{_eid:null,start:null,split:null,segment:null,originalEndTimeMinutes:0,originalEnd:null,end:null,startCell:null,endCell:null},dragAnEvent:{_eid:null},dragCreateAnEvent:{startCursorY:null,start:null,split:null,event:null},focusAnEvent:{_eid:null,mousedUp:!1},clickHoldAnEvent:{_eid:null,timeout:1200,timeoutId:null},dblTapACell:{taps:0,timeout:500},clickHoldACell:{cellId:null,split:null,timeout:1200,timeoutId:null,eventCreated:!1},cancelClickEventCreation:!1},mutableEvents:[],transitionDirection:"right"}},methods:{async loadLocale(e){if("object"==typeof this.locale)return this.texts=Object.assign({},qe,e),void this.utils.date.updateTexts(this.texts);if("en"===this.locale){const e=await i.e(7743).then(i.bind(i,37743));this.texts=Object.assign({},qe,e)}else((e,t)=>{const i=e[t];return i?"function"==typeof i?i():Promise.resolve(i):new Promise(((e,i)=>{("function"==typeof queueMicrotask?queueMicrotask:setTimeout)(i.bind(null,new Error("Unknown variable dynamic import: "+t)))}))})(Object.assign({
6"./i18n/ar.json":()=>i.e(1359).then(i.bind(i,71359)),
6"./i18n/bg.json":()=>i.e(5155).then(i.bind(i,15155)),
6"./i18n/bn.json":()=>i.e(9466).then(i.bind(i,89466)),
6"./i18n/bs.json":()=>i.e(3335).then(i.bind(i,23335)),
6"./i18n/ca.json":()=>i.e(4170).then(i.bind(i,24170)),
6"./i18n/cs.json":()=>i.e(724).then(i.bind(i,10724)),
6"./i18n/da.json":()=>i.e(7859).then(i.bind(i,7859)),
6"./i18n/de.json":()=>i.e(5863).then(i.bind(i,35863)),
6"./i18n/el.json":()=>i.e(3689).then(i.bind(i,93689)),
6"./i18n/en.json":()=>i.e(7743).then(i.bind(i,37743)),
6"./i18n/es.json":()=>i.e(722).then(i.bind(i,722)),
6"./i18n/et.json":()=>i.e(1233).then(i.bind(i,71233)),
6"./i18n/fa.json":()=>i.e(613).then(i.bind(i,30613)),
6"./i18n/fr.json":()=>i.e(2970).then(i.bind(i,22970)),
6"./i18n/he.json":()=>i.e(4595).then(i.bind(i,54595)),
6"./i18n/hr.json":()=>i.e(8400).then(i.bind(i,78400)),
6"./i18n/hu.json":()=>i.e(2131).then(i.bind(i,82131)),
6"./i18n/id.json":()=>i.e(5245).then(i.bind(i,65245)),
6"./i18n/is.json":()=>i.e(8326).then(i.bind(i,38326)),
6"./i18n/it.json":()=>i.e(269).then(i.bind(i,40269)),
6"./i18n/ja.json":()=>i.e(8841).then(i.bind(i,8841)),
6"./i18n/ka.json":()=>i.e(4514).then(i.bind(i,94514)),
6"./i18n/ko.json":()=>i.e(8216).then(i.bind(i,58216)),
6"./i18n/lt.json":()=>i.e(238).then(i.bind(i,90238)),
6"./i18n/mn.json":()=>i.e(3127).then(i.bind(i,13127)),
6"./i18n/nl.json":()=>i.e(3448).then(i.bind(i,33448)),
6"./i18n/no.json":()=>i.e(4543).then(i.bind(i,24543)),
6"./i18n/pl.json":()=>i.e(1442).then(i.bind(i,41442)),
6"./i18n/pt-br.json":()=>i.e(7533).then(i.bind(i,87533)),
6"./i18n/ro.json":()=>i.e(219).then(i.bind(i,30219)),
6"./i18n/ru.json":()=>i.e(6829).then(i.bind(i,96829)),
6"./i18n/sk.json":()=>i.e(2332).then(i.bind(i,82332)),
6"./i18n/sl.json":()=>i.e(775).then(i.bind(i,70775)),
6"./i18n/sq.json":()=>i.e(2634).then(i.bind(i,2634)),
6"./i18n/sr.json":()=>i.e(8677).then(i.bind(i,38677)),
6"./i18n/sv.json":()=>i.e(5913).then(i.bind(i,45913)),
6"./i18n/tr.json":()=>i.e(1324).then(i.bind(i,31324)),
6"./i18n/uk.json":()=>i.e(5274).then(i.bind(i,45274)),
6"./i18n/vi.json":()=>i.e(4573).then(i.bind(i,84573)),
6"./i18n/zh-cn.json":()=>i.e(444).then(i.bind(i,70444)),
6"./i18n/zh-hk.json":()=>i.e(8836)
6.then(i.bind(i,78836))}),`./i18n/${e}.json`).then((e=>{this.texts=Object.assign({},qe,e.default),this.utils.date.updateTexts(this.texts)}))},loadDragAndDrop(){i.e(3785).then(i.bind(i,13785)).then((e=>{const{DragAndDrop:t}=e;this.modules.dnd=new t(this)})).catch((()=>console.warn("Vue Cal: Missing drag & drop module.")))},validateView(e){return Je.includes(e)||(console.error(`Vue Cal: invalid active-view parameter provided: "${e}".\nA valid view must be one of: ${Je.join(", ")}.`),e="week"),this.enabledViews.includes(e)||(console.warn(`Vue Cal: the provided active-view "${e}" is disabled. Using the "${this.enabledViews[0]}" view instead.`),e=this.enabledViews[0]),e},switchToNarrowerView(e=null){this.transitionDirection="right";const t=this.enabledViews[this.enabledViews.indexOf(this.view.id)+1];t&&this.switchView(t,e)},switchView(e,t=null,i=!1){e=this.validateView(e);const s=this.utils.date,n=this.view.startDate&&this.view.startDate.getTime();if(this.transitions&&i){if(this.view.id===e)return;const t=this.enabledViews;this.transitionDirection=t.indexOf(this.view.id)>t.indexOf(e)?"left":"right"}const a=this.view.id;switch(this.view.events=[],this.view.id=e,this.view.firstCellDate=null,this.view.lastCellDate=null,t||(t=this.view.selectedDate||this.view.startDate),e){case"years":this.view.startDate=new Date(25*Math.floor(t.getFullYear()/25)||2e3,0,1),this.view.endDate=new Date(this.view.startDate.getFullYear()+25,0,1),this.view.endDate.setSeconds(-1);break;case"year":this.view.startDate=new Date(t.getFullYear(),0,1),this.view.endDate=new Date(t.getFullYear()+1,0,1),this.view.endDate.setSeconds(-1);break;case"month":{this.view.startDate=new Date(t.getFullYear(),t.getMonth(),1),this.view.endDate=new Date(t.getFullYear(),t.getMonth()+1,1),this.view.endDate.setSeconds(-1);let e=new Date(this.view.startDate);if(e.getDay()!==(this.startWeekOnSunday?0:1)&&(e=s.getPreviousFirstDayOfWeek(e,this.startWeekOnSunday)),this.view.firstCellDate=e,this.view.lastCellDate=s.addDays(e,41),this.view.lastCellDate.setHours(23,59,59,0),this.hideWeekends){if([0,6].includes(this.view.firstCellDate.getDay())){const e=6!==this.view.firstCellDate.getDay()||this.startWeekOnSunday?1:2;this.view.firstCellDate=s.addDays(this.view.firstCellDate,e)}if([0,6].includes(this.view.startDate.getDay())){const e=6===this.view.startDate.getDay()?2:1;this.view.startDate=s.addDays(this.view.startDate,e)}if([0,6].includes(this.view.lastCellDate.getDay())){const e=0!==this.view.lastCellDate.getDay()||this.startWeekOnSunday?1:2;this.view.lastCellDate=s.subtractDays(this.view.lastCellDate,e)}if([0,6].includes(this.view.endDate.getDay())){const e=0===this.view.endDate.getDay()?2:1;this.view.endDate=s.subtractDays(this.view.endDate,e)}}break}case"week":{t=s.getPreviousFirstDayOfWeek(t,this.startWeekOnSunday);const e=this.hideWeekends?5:7;this.view.startDate=this.hideWeekends&&this.startWeekOnSunday?s.addDays(t,1):t,this.view.startDate.setHours(0,0,0,0),this.view.endDate=s.addDays(t,e),this.view.endDate.setSeconds(-1);break}case"day":this.view.startDate=t,this.view.startDate.setHours(0,0,0,0),this.view.endDate=new Date(t),this.view.endDate.setHours(23,59,59,0)}this.addEventsToView();const l=this.view.startDate&&this.view.startDate.getTime();if((a!==e||l!==n)&&(this.$emit("update:activeView",e),this.ready)){const t=this.view.startDate,i={view:e,startDate:t,endDate:this.view.endDate,...this.isMonthView?{firstCellDate:this.view.firstCellDate,lastCellDate:this.view.lastCellDate,outOfScopeEvents:this.view.outOfScopeEvents.map(this.cleanupEvent)}:{},events:this.view.events.map(this.cleanupEvent),...this.isWeekView?{week:s.getWeek(this.startWeekOnSunday?s.addDays(t,1):t)}:{}};this.$emit("view-change",i)}},previous(){this.previousNext(!1)},next(){this.previousNext()},previousNext(e=!0){const t=this.utils.date;this.transitionDirection=e?"right":"left";const i=e?1:-1;let s=null;const{startDate:n,id:a}=this.view;switch(a){case"years":s=new Date(n.getFullYear()+25*i,0,1);break;case"year":s=new Date(n.getFullYear()+1*i,1,1);break;case"month":s=new Date(n.getFullYear(),n.getMonth()+1*i,1);break;case"week":s=t[e?"addDays":"subtractDays"](t.getPreviousFirstDayOfWeek(n,this.startWeekOnSunday),7);break;case"day":s=t[e?"addDays":"subtractDays"](n,1);const a=s.getDay(),l=this.startWeekOnSunday?a:(a||7)-1;if(this.weekDays[l].hide){const i=this.weekDays.map(((e,t)=>({...e,i:t}
6)));let n=0;e?([...i.slice(l),...i].find((e=>(n++,!e.hide))).i,n--):[...i,...i.slice(0,l)].reverse().find((e=>(n++,!e.hide))).i,s=t[e?"addDays":"subtractDays"](s,n)}}s&&this.switchView(a,s)},addEventsToView(e=[]){const t=this.utils.event,{startDate:i,endDate:s,firstCellDate:n,lastCellDate:a}=this.view;if(e.length||(this.view.events=[]),!(e=e.length?e:[...this.mutableEvents])||this.isYearsOrYearView&&!this.eventsCountOnYearView)return;let l=e.filter((e=>t.eventInRange(e,i,s)));this.isYearsOrYearView||this.isMonthView&&!this.eventsOnMonthView||(l=l.map((e=>e.daysCount>1?t.createEventSegments(e,n||i,a||s):e))),this.view.events.push(...l),this.isMonthView&&(this.view.outOfScopeEvents=[],e.forEach((e=>{(t.eventInRange(e,n,i)||t.eventInRange(e,s,a))&&(this.view.events.some((t=>t._eid===e._eid))||this.view.outOfScopeEvents.push(e))})))},findAncestor(e,t){for(;(e=e.parentElement)&&!e.classList.contains(t););return e},isDOMElementAnEvent(e){return e.classList.contains("vuecal__event")||this.findAncestor(e,"vuecal__event")},onMouseMove(e){const{resizeAnEvent:t,dragAnEvent:i,dragCreateAnEvent:s}=this.domEvents;(null!==t._eid||null!==i._eid||s.start)&&(e.preventDefault(),t._eid?this.eventResizing(e):this.dragToCreateEvent&&s.start&&this.eventDragCreation(e))},onMouseUp(e){const{focusAnEvent:t,resizeAnEvent:i,clickHoldAnEvent:s,clickHoldACell:n,dragCreateAnEvent:a}=this.domEvents,{_eid:l}=s,{_eid:o}=i;let r=!1;const{event:d,start:c}=a,u=this.isDOMElementAnEvent(e.target),h=t.mousedUp;if(t.mousedUp=!1,u&&(this.domEvents.cancelClickEventCreation=!0),n.eventCreated)return;if(o){const{originalEnd:e,originalEndTimeMinutes:t,endTimeMinutes:s}=i,n=this.view.events.find((e=>e._eid===i._eid));if(r=s&&s!==t,n&&n.end.getTime()!==e.getTime()){const t=this.mutableEvents.find((e=>e._eid===i._eid));t.endTimeMinutes=n.endTimeMinutes,t.end=n.end;const s=this.cleanupEvent(n),a={...this.cleanupEvent(n),end:e,endTimeMinutes:n.originalEndTimeMinutes};this.$emit("event-duration-change",{event:s,oldDate:i.originalEnd,originalEvent:a}),this.$emit("event-change",{event:s,originalEvent:a})}n&&(n.resizing=!1),i._eid=null,i.start=null,i.split=null,i.segment=null,i.originalEndTimeMinutes=null,i.originalEnd=null,i.endTimeMinutes=null,i.startCell=null,i.endCell=null}else c&&(d&&(this.emitWithEvent("event-drag-create",d),a.event.resizing=!1),a.start=null,a.split=null,a.event=null);u||o||this.unfocusEvent(),s.timeoutId&&!l&&(clearTimeout(s.timeoutId),s.timeoutId=null),n.timeoutId&&(clearTimeout(n.timeoutId),n.timeoutId=null);const v="function"==typeof this.onEventClick;if(h&&!r&&!l&&!d&&v){let i=this.view.events.find((e=>e._eid===t._eid));return!i&&this.isMonthView&&(i=this.view.outOfScopeEvents.find((e=>e._eid===t._eid))),i&&this.onEventClick(i,e)}},onKeyUp(e){27===e.keyCode&&this.cancelDelete()},eventResizing(e){const{resizeAnEvent:t}=this.domEvents,i=this.view.events.find((e=>e._eid===t._eid))||{segments:{}},{minutes:s,cursorCoords:n}=this.minutesAtCursor(e),a=i.segments&&i.segments[t.segment],{date:l,event:o}=this.utils,r=Math.max(s,this.timeFrom+1,(a||i).startTimeMinutes+1);if(i.endTimeMinutes=t.endTimeMinutes=r,this.snapToTime){const e=i.endTimeMinutes+this.snapToTime/2;i.endTimeMinutes=e-e%this.snapToTime}if(a&&(a.endTimeMinutes=i.endTimeMinutes),i.end.setHours(0,i.endTimeMinutes,1440===i.endTimeMinutes?-1:0,0),this.resizeX&&this.isWeekView){i.daysCount=l.countDays(i.start,i.end);const e=this.cellsEl,s=e.offsetWidth/e.childElementCount,a=Math.floor(n.x/s);if(null===t.startCell&&(t.startCell=a-(i.daysCount-1)),t.endCell!==a){t.endCell=a;const e=l.addDays(i.start,a-t.startCell),s=Math.max(l.countDays(i.start,e),1);if(s!==i.daysCount){let e=null;e=s>i.daysCount?o.addEventSegment(i):o.removeEventSegment(i),t.segment=e,i.endTimeMinutes+=.001}}}this.$emit("event-resizing",{_eid:i._eid,end:i.end,endTimeMinutes:i.endTimeMinutes})},eventDragCreation(e){const{dragCreateAnEvent:t}=this.domEvents,{start:i,startCursorY:s,split:n}=t,a=new Date(i),{minutes:l,cursorCoords:{y:o}}=this.minutesAtCursor(e);if(t.event||!(Math.abs(s-o)<this.dragToCreateThreshold))if(t.event){if(a.setHours(0,l,1440===l?-1:0,0),this.snapToTime){let e=60*a.getHours()+a.getMinutes();const t=e+this.snapToTime/2;e=t-t%this.snapToTime,a.setHours(0,e,0,0)}const e=i<a,{event:s}=t;s.start=e?i:a,s.end=e?a:i,s.startTimeMinutes=60*s.start.getHours()+s.start.getMinutes(),s.endTimeMinutes=60*s.end.getHours()+s.end.getMinutes()}else{if(t.event=this.utils.event.createAnEvent(i,1,{split:n}),!t.event)return t.start=null,t.split=null,void(t.event=null);t.event.resizing=!0}},unfocusEvent(){const{focusAnEvent:e,clickHoldAnEvent:t}=this.domEvents,i=this.view.events.find((i=>i._eid===(e._eid||t._eid)));e._eid=null,t._eid=null,i&&(i.focused=!1,i.deleting=!1)},cancelDelete(){const{clickHoldAnEvent:e}=this.domEvents;if(e._eid){const t=this.view.events.find((t=>t._eid===e._eid));t&&(t.deleting=!1),e._eid=null,e.timeoutId=null}},onEventTitleBlur(e,t){if(t.title===e.target.innerHTML)return;const i=t.title;t.title=e.target.innerHTML;const s=this.cleanupEvent(t);this.$emit("event-title-change",{event:s,oldTitle:i}),this.$emit("event-change",{event:s,originalEvent:{...s,title:i}})},updateMutableEvents(){const e=this.utils.date;
6this.mutableEvents=[],this.events.forEach((t=>{const i="string"==typeof t.start?e.stringToDate(t.start):t.start,s=e.formatDateLite(i),n=e.dateToMinutes(i);let a=null;"string"==typeof t.end&&t.end.includes("24:00")?(a=new Date(t.end.replace(" 24:00","")),a.setHours(23,59,59,0)):a="string"==typeof t.end?e.stringToDate(t.end):t.end;let l=e.formatDateLite(a),o=e.dateToMinutes(a);o&&1440!==o||(!this.time||"string"==typeof t.end&&10===t.end.length?a.setHours(23,59,59,0):a.setSeconds(a.getSeconds()-1),l=e.formatDateLite(a),o=1440);const r=s!==l;t=Object.assign({...this.utils.event.eventDefaults},t,{_eid:`${this._.uid}_${this.eventIdIncrement++}`,segments:r?{}:null,start:i,startTimeMinutes:n,end:a,endTimeMinutes:o,daysCount:r?e.countDays(i,a):1,class:t.class}),this.mutableEvents.push(t)}))},minutesAtCursor(e){return this.utils.cell.minutesAtCursor(e)},createEvent(e,t,i={}){return this.utils.event.createAnEvent(e,t,i)},cleanupEvent(e){return e={...e},["segments","deletable","deleting","titleEditable","resizable","resizing","draggable","dragging","draggingStatic","focused"].forEach((t=>{t in e&&delete e[t]})),e.repeat||delete e.repeat,e},emitWithEvent(e,t){this.$emit(e,this.cleanupEvent(t))},updateSelectedDate(e){if((e=e&&"string"==typeof e?this.utils.date.stringToDate(e):new Date(e))&&e instanceof Date){const{selectedDate:t}=this.view;t&&(this.transitionDirection=t.getTime()>e.getTime()?"left":"right"),e.setHours(0,0,0,0),t&&t.getTime()===e.getTime()||(this.view.selectedDate=e),this.switchView(this.view.id)}this.$emit("update:selected-date",this.view.selectedDate)},getWeekNumber(e){const t=this.utils.date,i=this.firstCellDateWeekNumber+e,s=this.startWeekOnSunday?1:0;return i>52?t.getWeek(t.addDays(this.view.firstCellDate,7*e+s)):i},timeTick(){this.now=new Date,this.timeTickerIds[1]=setTimeout(this.timeTick,6e4)},updateDateTexts(){this.utils.date.updateTexts(this.texts)},alignWithScrollbar(){if(document.getElementById("vuecal-align-with-scrollbar"))return;const e=this.$refs.vuecal.getElementsByClassName("vuecal__scrollbar-check")[0],t=e.offsetWidth-e.children[0].offsetWidth;if(t){const e=document.createElement("style");e.id="vuecal-align-with-scrollbar",e.type="text/css",e.innerHTML=`.vuecal--view-with-time .vuecal__weekdays-headings,.vuecal--view-with-time .vuecal__all-day {padding-right: ${t}px}`,document.head.appendChild(e)}},cellOrSplitHasEvents:(e,t=null)=>e.length&&(!t&&e.length||t&&e.some((e=>e.split===t.id)))},created(){this.utils.cell=new N(this),this.utils.event=new Y(this,this.utils.date),this.loadLocale(this.locale),this.editEvents.drag&&this.loadDragAndDrop(),this.updateMutableEvents(this.events),this.view.id=this.currentView,this.selectedDate?this.updateSelectedDate(this.selectedDate):(this.view.selectedDate=new Date,this.switchView(this.currentView)),this.time&&this.watchRealTime&&(this.timeTickerIds[0]=setTimeout(this.timeTick,1e3*(60-this.now.getSeconds())))},mounted(){const e=this.utils.date,t="ontouchstart"in window,{resize:i,drag:s,create:n,delete:a,title:l}=this.editEvents,o=this.onEventClick&&"function"==typeof this.onEventClick;(i||s||n||a||l||o)&&window.addEventListener(t?"touchend":"mouseup",this.onMouseUp),(i||s||n&&this.dragToCreateEvent)&&window.addEventListener(t?"touchmove":"mousemove",this.onMouseMove,{passive:!1}),l&&window.addEventListener("keyup",this.onKeyUp),t&&(this.$refs.vuecal.oncontextmenu=function(e){e.preventDefault(),e.stopPropagation()}),this.hideBody||this.alignWithScrollbar();const r=this.view.startDate,d={view:this.view.id,startDate:r,endDate:this.view.endDate,...this.isMonthView?{firstCellDate:this.view.firstCellDate,lastCellDate:this.view.lastCellDate}:{},events:this.view.events.map(this.cleanupEvent),...this.isWeekView?{week:e.getWeek(this.startWeekOnSunday?e.addDays(r,1):r)}:{}};this.$emit("ready",d),this.ready=!0},beforeUnmount(){const e="ontouchstart"in window;window.removeEventListener(e?"touchmove":"mousemove",this.onMouseMove,{passive:!1}),window.removeEventListener(e?"touchend":"mouseup",this.onMouseUp),window.removeEventListener("keyup",this.onKeyUp),this.timeTickerIds[0]&&clearTimeout(this.timeTickerIds[0]),this.timeTickerIds[1]&&clearTimeout(this.timeTickerIds[1]),this.timeTickerIds=[null,null]},computed:{editEvents(){return this.editableEvents&&"object"==typeof this.editableEvents?{title:!!this.editableEvents.title,drag:!!this.editableEvents.drag,resize:!!this.editableEvents.resize,create:!!this.editableEvents.create,delete:!!this.editableEvents.delete}:{title:!!this.editableEvents,drag:!!this.editableEvents,resize:!!this.editableEvents,create:!!this.editableEvents,delete:!!this.editableEvents}},views(){return{years:{label:this.texts.years,enabled:!this.disableViews.includes("years")},year:{label:this.texts.year,enabled:!this.disableViews.includes("year")},month:{label:this.texts.month,enabled:!this.disableViews.includes("month")},week:{label:this.texts.week,enabled:!this.disableViews.includes("week")},day:{label:this.texts.day,enabled:!this.disableViews.includes("day")}}},currentView(){return this.validateView(this.activeView)},enabledViews(){return Object.keys(this.views).filter((e=>this.views[e].enabled))},hasTimeColumn(){return this.time&&this.isWeekOrDayView},isShortMonthView(){return this.isMonthView&&"short"===this.eventsOnMonthView},firstCellDateWeekNumber(){const e=this.utils.date,t=this.view.firstCellDate;return e.getWeek(this.startWeekOnSunday?e.addDays(t,1):t)},timeCells(){const e=[];for(let t=this.timeFrom,i=this.timeTo;t<i;t+=this.timeStep)e.push({hours:Math.floor(t/60),minutes:t%60,label:this.utils.date.formatTime(t,this.TimeFormat),value:t});return e},TimeFormat(){return this.timeFormat||(this.twelveHour?"h:mm{am}":"HH:mm")},daySplits(){return(this.splitDays.filter((e=>!e.hide))||[]).map(((e,t)=>({...e,id:e.id||t+1})))},hasSplits(){return this.daySplits.length&&this.isWeekOrDayView},hasShortEvents(){return"short"===this.showAllDayEvents},cellOrSplitMinWidth(){let e=null;
6return this.hasSplits&&this.minSplitWidth?e=this.visibleDaysCount*this.minSplitWidth*this.daySplits.length:this.minCellWidth&&this.isWeekView&&(e=this.visibleDaysCount*this.minCellWidth),e},allDayBar(){let e=this.allDayBarHeight||null;return e&&!isNaN(e)&&(e+="px"),{cells:this.viewCells,options:this.$props,label:this.texts.allDay,shortEvents:this.hasShortEvents,daySplits:this.hasSplits&&this.daySplits||[],cellOrSplitMinWidth:this.cellOrSplitMinWidth,height:e}},minTimestamp(){let e=null;return this.minDate&&"string"==typeof this.minDate?e=this.utils.date.stringToDate(this.minDate):this.minDate&&this.minDate instanceof Date&&(e=this.minDate),e?e.getTime():null},maxTimestamp(){let e=null;return this.maxDate&&"string"==typeof this.maxDate?e=this.utils.date.stringToDate(this.maxDate):this.maxDate&&this.minDate instanceof Date&&(e=this.maxDate),e?e.getTime():null},weekDays(){let{weekDays:e,weekDaysShort:t=[]}=this.texts;return e=e.slice(0).map(((e,i)=>({label:e,...t.length?{short:t[i]}:{},hide:this.hideWeekends&&i>=5||this.hideWeekdays.length&&this.hideWeekdays.includes(i+1)}))),this.startWeekOnSunday&&e.unshift(e.pop()),e},weekDaysInHeader(){return this.isMonthView||this.isWeekView&&!this.minCellWidth&&!(this.hasSplits&&this.minSplitWidth)},months(){return this.texts.months.map((e=>({label:e})))},specialDayHours(){return this.specialHours&&Object.keys(this.specialHours).length?Array(7).fill("").map(((e,t)=>{let i=this.specialHours[t+1]||[];return Array.isArray(i)||(i=[i]),e=[],i.forEach((({from:i,to:s,class:n,label:a},l)=>{e[l]={day:t+1,from:[null,void 0].includes(i)?null:1*i,to:[null,void 0].includes(s)?null:1*s,class:n||"",label:a||""}})),e})):{}},viewTitle(){const e=this.utils.date;let t="";const i=this.view.startDate,s=i.getFullYear(),n=i.getMonth();switch(this.view.id){case"years":t=this.texts.years;break;case"year":t=s;break;case"month":t=`${this.months[n].label} ${s}`;break;case"week":{const s=this.view.endDate,n=i.getFullYear();let a=this.texts.months[i.getMonth()];this.xsmall&&(a=a.substring(0,3));let l=`${a} ${n}`;if(s.getMonth()!==i.getMonth()){const e=s.getFullYear();let t=this.texts.months[s.getMonth()];this.xsmall&&(t=t.substring(0,3)),l=n===e?`${a} - ${t} ${n}`:this.small?`${a.substring(0,3)} ${n} - ${t.substring(0,3)} ${e}`:`${a} ${n} - ${t} ${e}`}t=`${this.texts.week} ${e.getWeek(this.startWeekOnSunday?e.addDays(i,1):i)} (${l})`;break}case"day":t=this.utils.date.formatDate(i,this.texts.dateFormat,this.texts)}return t},viewCells(){const e=this.utils.date;let t=[],i=null,s=!1;this.watchRealTime||(this.now=new Date);const n=this.now;switch(this.view.id){case"years":i=this.view.startDate.getFullYear(),t=Array.apply(null,Array(25)).map(((t,s)=>{const a=new Date(i+s,0,1),l=new Date(i+s+1,0,1);return l.setSeconds(-1),{startDate:a,formattedDate:e.formatDateLite(a),endDate:l,content:i+s,current:i+s===n.getFullYear()}}));break;case"year":i=this.view.startDate.getFullYear(),t=Array.apply(null,Array(12)).map(((t,s)=>{const a=new Date(i,s,1),l=new Date(i,s+1,1);return l.setSeconds(-1),{startDate:a,formattedDate:e.formatDateLite(a),endDate:l,content:this.xsmall?this.months[s].label.substr(0,3):this.months[s].label,current:s===n.getMonth()&&i===n.getFullYear()}}));break;case"month":{const i=this.view.startDate.getMonth(),n=new Date(this.view.firstCellDate);s=!1,t=Array.apply(null,Array(42)).map(((t,a)=>{const l=e.addDays(n,a),o=new Date(l);o.setHours(23,59,59,0);const r=!s&&e.isToday(l)&&!s++;return{startDate:l,formattedDate:e.formatDateLite(l),endDate:o,content:l.getDate(),today:r,outOfScope:l.getMonth()!==i,class:`vuecal__cell--day${l.getDay()||7}`}})),(this.hideWeekends||this.hideWeekdays.length)&&(t=t.filter((e=>{const t=e.startDate.getDay()||7;return!(this.hideWeekends&&t>=6||this.hideWeekdays.length&&this.hideWeekdays.includes(t))})));break}case"week":{s=!1;const i=this.view.startDate,n=this.weekDays;t=n.map(((t,n)=>{const a=e.addDays(i,this.startWeekOnSunday?n-1:n),l=new Date(a);l.setHours(23,59,59,0);const o=(a.getDay()||7)-1;return{startDate:a,formattedDate:e.formatDateLite(a),endDate:l,today:!s&&e.isToday(a)&&!s++,specialHours:this.specialDayHours[o]||[]}})).filter(((e,t)=>!n[t].hide));break}
6case"day":{const i=this.view.startDate,s=new Date(this.view.startDate);s.setHours(23,59,59,0);const n=(i.getDay()||7)-1;t=[{startDate:i,formattedDate:e.formatDateLite(i),endDate:s,today:e.isToday(i),specialHours:this.specialDayHours[n]||[]}];break}}return t},visibleDaysCount(){return this.isDayView?1:7-this.weekDays.reduce(((e,t)=>e+t.hide),0)},cellWidth(){return 100/this.visibleDaysCount},cssClasses(){const{resizeAnEvent:e,dragAnEvent:t,dragCreateAnEvent:i}=this.domEvents;return{[`vuecal--${this.view.id}-view`]:!0,[`vuecal--${this.locale}`]:this.locale,"vuecal--no-time":!this.time,"vuecal--view-with-time":this.hasTimeColumn,"vuecal--week-numbers":this.showWeekNumbers&&this.isMonthView,"vuecal--twelve-hour":this.twelveHour,"vuecal--click-to-navigate":this.clickToNavigate,"vuecal--hide-weekends":this.hideWeekends,"vuecal--split-days":this.hasSplits,"vuecal--sticky-split-labels":this.hasSplits&&this.stickySplitLabels,"vuecal--overflow-x":this.minCellWidth&&this.isWeekView||this.hasSplits&&this.minSplitWidth,"vuecal--small":this.small,"vuecal--xsmall":this.xsmall,"vuecal--resizing-event":e._eid,"vuecal--drag-creating-event":i.event,"vuecal--dragging-event":t._eid,"vuecal--events-on-month-view":this.eventsOnMonthView,"vuecal--short-events":this.isMonthView&&"short"===this.eventsOnMonthView,"vuecal--has-touch":typeof window<"u"&&"ontouchstart"in window}},isYearsOrYearView(){return["years","year"].includes(this.view.id)},isYearsView(){return"years"===this.view.id},isYearView(){return"year"===this.view.id},isMonthView(){return"month"===this.view.id},isWeekOrDayView(){return["week","day"].includes(this.view.id)},isWeekView(){return"week"===this.view.id},isDayView(){return"day"===this.view.id}},watch:{events:{handler(e,t){this.updateMutableEvents(e),this.addEventsToView()},deep:!0},locale(e){this.loadLocale(e)},selectedDate(e){this.updateSelectedDate(e)},activeView(e){this.switchView(e)}}},tt=ee(et,[["render",function(e,t,i,l,o,r){const d=(0,s.g2)("vuecal-header"),c=(0,s.g2)("all-day-bar"),u=(0,s.g2)("weekdays-headings"),h=(0,s.g2)("vuecal-cell");return(0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["vuecal__flex vuecal",r.cssClasses]),column:"",ref:"vuecal",lang:i.locale},[(0,s.bF)(d,{options:e.$props,"edit-events":r.editEvents,"view-props":{views:r.views,weekDaysInHeader:r.weekDaysInHeader},"week-days":r.weekDays,"has-splits":r.hasSplits,"day-splits":r.daySplits,"switch-to-narrower-view":r.switchToNarrowerView},(0,s.eX)({"arrow-prev":(0,s.k6)((()=>[(0,s.RG)(e.$slots,"arrow-prev",{},(()=>[(0,s.eW)(" "),De,(0,s.eW)(" ")]))])),"arrow-next":(0,s.k6)((()=>[(0,s.RG)(e.$slots,"arrow-next",{},(()=>[(0,s.eW)(" "),Ce,(0,s.eW)(" ")]))])),"today-button":(0,s.k6)((()=>[(0,s.RG)(e.$slots,"today-button",{},(()=>[(0,s.Lk)("span",Ee,(0,n.v_)(o.texts.today),1)]))])),title:(0,s.k6)((()=>[(0,s.RG)(e.$slots,"title",{title:r.viewTitle,view:o.view},(()=>[(0,s.eW)((0,n.v_)(r.viewTitle),1)]))])),_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,s.k6)((({heading:t,view:i})=>[(0,s.RG)(e.$slots,"weekday-heading",{heading:t,view:i})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,s.k6)((({split:t})=>[(0,s.RG)(e.$slots,"split-label",{split:t,view:o.view.id})])),key:"1"}:void 0]),1032,["options","edit-events","view-props","week-days","has-splits","day-splits","switch-to-narrower-view"]),i.hideBody?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",_e,[(0,s.bF)(a.eB,{name:`slide-fade--${o.transitionDirection}`,appear:i.transitions},{default:(0,s.k6)((()=>[((0,s.uX)(),(0,s.CE)("div",{class:"vuecal__flex",style:{"min-width":"100%"},key:!!i.transitions&&o.view.id,column:""},[i.showAllDayEvents&&r.hasTimeColumn&&(!r.cellOrSplitMinWidth||r.isDayView&&!i.minSplitWidth)?((0,s.uX)(),(0,s.Wv)(c,(0,n._B)((0,s.v6)({key:0},r.allDayBar)),{event:(0,s.k6)((({event:t,view:i})=>[(0,s.RG)(e.$slots,"event",{view:i,event:t},(()=>[r.editEvents.title&&t.titleEditable?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"",onBlur:e=>r.onEventTitleBlur(e,t),innerHTML:t.title},null,40,Ae)):t.title?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__event-title",innerHTML:t.title},null,8,Se)):(0,s.Q3)("",!0),!t.content||r.hasShortEvents||r.isShortMonthView?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",{key:2,class:"vuecal__event-content",innerHTML:t.content},null,8,Te))]))])),_:3}
6,16)):(0,s.Q3)("",!0),(0,s.Lk)("div",{class:(0,n.C4)(["vuecal__bg",{vuecal__flex:!r.hasTimeColumn}]),column:""},[(0,s.Lk)("div",Me,[r.hasTimeColumn?((0,s.uX)(),(0,s.CE)("div",Le,[i.showAllDayEvents&&r.cellOrSplitMinWidth&&(!r.isDayView||i.minSplitWidth)?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"vuecal__all-day-text",style:(0,n.Tr)({height:r.allDayBar.height})},[(0,s.Lk)("span",null,(0,n.v_)(o.texts.allDay),1)],4)):(0,s.Q3)("",!0),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.timeCells,((t,a)=>((0,s.uX)(),(0,s.CE)("div",{class:"vuecal__time-cell",key:a,style:(0,n.Tr)(`height: ${i.timeCellHeight}px`)},[(0,s.RG)(e.$slots,"time-cell",{hours:t.hours,minutes:t.minutes},(()=>[xe,(0,s.Lk)("span",Be,(0,n.v_)(t.label),1)]))],4)))),128))])):(0,s.Q3)("",!0),i.showWeekNumbers&&r.isMonthView?((0,s.uX)(),(0,s.CE)("div",$e,[((0,s.uX)(),(0,s.CE)(s.FK,null,(0,s.pI)(6,(t=>(0,s.Lk)("div",{class:"vuecal__flex vuecal__week-number-cell",key:t,grow:""},[(0,s.RG)(e.$slots,"week-number-cell",{week:r.getWeekNumber(t-1)},(()=>[(0,s.eW)((0,n.v_)(r.getWeekNumber(t-1)),1)]))]))),64))])):(0,s.Q3)("",!0),(0,s.Lk)("div",{class:(0,n.C4)(["vuecal__flex vuecal__cells",`${o.view.id}-view`]),grow:"",wrap:!r.cellOrSplitMinWidth||!r.isWeekView,column:!!r.cellOrSplitMinWidth},[r.cellOrSplitMinWidth&&r.isWeekView?((0,s.uX)(),(0,s.Wv)(u,{key:0,"transition-direction":o.transitionDirection,"week-days":r.weekDays,"switch-to-narrower-view":r.switchToNarrowerView,style:(0,n.Tr)(r.cellOrSplitMinWidth?`min-width: ${r.cellOrSplitMinWidth}px`:"")},(0,s.eX)({_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,s.k6)((({heading:t,view:i})=>[(0,s.RG)(e.$slots,"weekday-heading",{heading:t,view:i})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,s.k6)((({split:t})=>[(0,s.RG)(e.$slots,"split-label",{split:t,view:o.view.id})])),key:"1"}:void 0]),1032,["transition-direction","week-days","switch-to-narrower-view","style"])):r.hasSplits&&i.stickySplitLabels&&i.minSplitWidth?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__flex vuecal__split-days-headers",style:(0,n.Tr)(r.cellOrSplitMinWidth?`min-width: ${r.cellOrSplitMinWidth}px`:"")},[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.daySplits,((t,i)=>((0,s.uX)(),(0,s.CE)("div",{class:(0,n.C4)(["day-split-header",t.class||!1]),key:i},[(0,s.RG)(e.$slots,"split-label",{split:t,view:o.view.id},(()=>[(0,s.eW)((0,n.v_)(t.label),1)]))],2)))),128))],4)):(0,s.Q3)("",!0),i.showAllDayEvents&&r.hasTimeColumn&&(r.isWeekView&&r.cellOrSplitMinWidth||r.isDayView&&r.hasSplits&&i.minSplitWidth)?((0,s.uX)(),(0,s.Wv)(c,(0,n._B)((0,s.v6)({key:2},r.allDayBar)),{event:(0,s.k6)((({event:t,view:i})=>[(0,s.RG)(e.$slots,"event",{view:i,event:t},(()=>[r.editEvents.title&&t.titleEditable?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"",onBlur:e=>r.onEventTitleBlur(e,t),innerHTML:t.title},null,40,Ve)):t.title?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__event-title",innerHTML:t.title},null,8,We)):(0,s.Q3)("",!0),!t.content||r.hasShortEvents||r.isShortMonthView?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",{key:2,class:"vuecal__event-content",innerHTML:t.content},null,8,Ie))]))])),_:3},16)):(0,s.Q3)("",!0),(0,s.Lk)("div",{class:"vuecal__flex",ref:e=>o.cellsEl=e,grow:"",wrap:!r.cellOrSplitMinWidth||!r.isWeekView,style:(0,n.Tr)(r.cellOrSplitMinWidth?`min-width: ${r.cellOrSplitMinWidth}px`:"")},[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(r.viewCells,((t,a)=>((0,s.uX)(),(0,s.Wv)(h,{key:a,options:e.$props,"edit-events":r.editEvents,data:t,"cell-width":i.hideWeekdays.length&&(r.isWeekView||r.isMonthView)&&r.cellWidth,"min-timestamp":r.minTimestamp,"max-timestamp":r.maxTimestamp,"cell-splits":r.hasSplits&&r.daySplits||[]},{"cell-content":(0,s.k6)((({events:a,split:l,selectCell:d})=>[(0,s.RG)(e.$slots,"cell-content",{cell:t,view:o.view,goNarrower:d,events:a},(()=>[l&&!i.stickySplitLabels?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"split-label",innerHTML:l.label},null,8,Re)):(0,s.Q3)("",!0),t.content?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__cell-date",innerHTML:t.content},null,8,Fe)):(0,s.Q3)("",!0),(r.isMonthView&&!i.eventsOnMonthView||r.isYearsOrYearView&&i.eventsCountOnYearView)&&a.length?((0,s.uX)(),(0,s.CE)("div",Pe,[(0,s.RG)(e.$slots,"events-count",{view:o.view,events:a},(()=>[(0,s.eW)((0,n.v_)(a.length),1)]))])):(0,s.Q3)("",!0),!r.cellOrSplitHasEvents(a,l)&&r.isWeekOrDayView?((0,s.uX)(),(0,s.CE)("div",Xe,[(0,s.RG)(e.$slots,"no-event",{},(()=>[(0,s.eW)((0,n.v_)(o.texts.noEvent),1)]))])):(0,s.Q3)("",!0)]))])),event:(0,s.k6)((({event:a,view:l})=>[(0,s.RG)(e.$slots,"event",{view:l,event:a},(()=>[r.editEvents.title&&a.titleEditable?((0,s.uX)(),(0,s.CE)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"",onBlur:e=>r.onEventTitleBlur(e,a),innerHTML:a.title},null,40,je)):a.title?((0,s.uX)(),(0,s.CE)("div",{key:1,class:"vuecal__event-title",innerHTML:a.title},null,8,Ne)):(0,s.Q3)("",!0),!i.time||a.allDay||r.isMonthView&&(a.allDay||"short"===i.showAllDayEvents)||r.isShortMonthView?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",Ye,[(0,s.eW)((0,n.v_)(o.utils.date.formatTime(a.start,r.TimeFormat)),1
6),a.endTimeMinutes?((0,s.uX)(),(0,s.CE)("span",Ge," - "+(0,n.v_)(o.utils.date.formatTime(a.end,r.TimeFormat,null,!0)),1)):(0,s.Q3)("",!0),a.daysCount>1&&(a.segments[t.formattedDate]||{}).isFirstDay?((0,s.uX)(),(0,s.CE)("small",Ue," +"+(0,n.v_)(a.daysCount-1)+(0,n.v_)((o.texts.day[0]||"").toLowerCase()),1)):(0,s.Q3)("",!0)])),!a.content||r.isMonthView&&a.allDay&&"short"===i.showAllDayEvents||r.isShortMonthView?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",{key:3,class:"vuecal__event-content",innerHTML:a.content},null,8,Qe))]))])),"no-event":(0,s.k6)((()=>[(0,s.RG)(e.$slots,"no-event",{},(()=>[(0,s.eW)((0,n.v_)(o.texts.noEvent),1)]))])),_:2},1032,["options","edit-events","data","cell-width","min-timestamp","max-timestamp","cell-splits"])))),128))],12,He)],10,Oe)])],2)]))])),_:3},8,["name","appear"]),o.ready?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",ze,Ke))]))],10,ke)}]]);var it=i(73485),st=i(60159);const nt={ref:"autocomplete",class:"autocomplete"},at=["disabled"],lt=(0,s.Lk)("ul",{class:"autocomplete-result-list"},null,-1);function ot(e,t,i,n,l,o){return(0,s.uX)(),(0,s.CE)("div",nt,[(0,s.bo)((0,s.Lk)("input",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedStaffSearch=t),class:"autocomplete-input",disabled:e.disabled,onBlur:t[1]||(t[1]=(...t)=>e.autocompleteBlur&&e.autocompleteBlur(...t))},null,40,at),[[a.Jo,e.selectedStaffSearch]]),lt],512)}function rt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dt(e,t){for(var i=0;i<t.length;i++){var s=t[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(e,s.key,s)}}function ct(e,t,i){return t&&dt(e.prototype,t),i&&dt(e,i),e}function ut(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var ht=function(e,t){return e.matches?e.matches(t):e.msMatchesSelector?e.msMatchesSelector(t):e.webkitMatchesSelector?e.webkitMatchesSelector(t):null},vt=function(e,t){var i=e;while(i&&1===i.nodeType){if(ht(i,t))return i;i=i.parentNode}return null},pt=function(e,t){return e.closest?e.closest(t):vt(e,t)},mt=function(e){return Boolean(e&&"function"===typeof e.then)},gt=function e(){var t=this,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},s=i.search,n=i.autoSelect,a=void 0!==n&&n,l=i.setValue,o=void 0===l?function(){}:l,r=i.setAttribute,d=void 0===r?function(){}:r,c=i.onUpdate,u=void 0===c?function(){}:c,h=i.onSubmit,v=void 0===h?function(){}:h,p=i.onShow,m=void 0===p?function(){}:p,g=i.autocorrect,f=void 0!==g&&g,y=i.onHide,w=void 0===y?function(){}:y,b=i.onLoading,k=void 0===b?function(){}:b,D=i.onLoaded,C=void 0===D?function(){}:D,E=i.submitOnEnter,_=void 0!==E&&E;rt(this,e),ut(this,"value",""),ut(this,"searchCounter",0),ut(this,"results",[]),ut(this,"selectedIndex",-1),ut(this,"selectedResult",null),ut(this,"destroy",(function(){t.search=null,t.setValue=null,t.setAttribute=null,t.onUpdate=null,t.onSubmit=null,t.autocorrect=null,t.onShow=null,t.onHide=null,t.onLoading=null,t.onLoaded=null})),ut(this,"handleInput",(function(e){var i=e.target.value;t.updateResults(i),t.value=i})),ut(this,"handleKeyDown",(function(e){var i=e.key;switch(i){case"Up":case"Down":case"ArrowUp":case"ArrowDown":var s="ArrowUp"===i||"Up"===i?t.selectedIndex-1:t.selectedIndex+1;e.preventDefault(),t.handleArrows(s);break;case"Tab":t.selectResult();break;case"Enter":var n=e.target.getAttribute("aria-activedescendant").length>0;t.selectedResult=t.results[t.selectedIndex]||t.selectedResult,t.selectResult(),t.submitOnEnter?t.selectedResult&&t.onSubmit(t.selectedResult):n?e.preventDefault():(t.selectedResult&&t.onSubmit(t.selectedResult),t.selectedResult=null);break;case"Esc":case"Escape":t.hideResults(),t.setValue();break;default:return}})),ut(this,"handleFocus",(function(e){var i=e.target.value;t.updateResults(i),t.value=i})),ut(this,"handleBlur",(function(){t.hideResults()})),ut(this,"handleResultMouseDown",(function(e){e.preventDefault()})),ut(this,"handleResultClick",(function(e){var i=e.target,s=pt(i,"[data-result-index]");if(s){t.selectedIndex=parseInt(s.dataset.resultIndex,10);var n=t.results[t.selectedIndex];t.selectResult(),t.onSubmit(n)}})),ut(this,"handleArrows",(function(e){var i=t.results.length;t.selectedIndex=(e%i+i)%i,t.onUpdate(t.results,t.selectedIndex)})),ut(this,"selectResult",(function(){var e=t.results[t.selectedIndex];e&&t.setValue(e),t.hideResults()})),ut(this,"updateResults",(function(e){var i=++t.searchCounter;t.onLoading(),t.search(e).then((function(e){i===t.searchCounter&&(t.results=e,t.onLoaded(),0!==t.results.length?(t.selectedIndex=t.autoSelect?0:-1,t.onUpdate(t.results,t.selectedIndex),t.showResults()):t.hideResults())}))})),ut(this,"showResults",(function(){t.setAttribute("aria-expanded",!0),t.onShow()})),ut(this,"hideResults",(function(){t.selectedIndex=-1,t.results=[],t.setAttribute("aria-expanded",!1),t.setAttribute("aria-activedescendant",""),t.onUpdate(t.results,t.selectedIndex),t.onHide()})),ut(this,"checkSelectedResultVisible",(function(e){var i=e.querySelector('[data-result-index="'.concat(t.selectedIndex,'"]'));if(i){var s=e.getBoundingClientRect(),n=i.getBoundingClientRect();n.top<s.top?e.scrollTop-=s.top-n.top:n.bottom>s.bottom&&(e.scrollTop+=n.bottom-s.bottom)}})),this.search=mt(s)?s:function(e){return Promise.resolve(s(e))},this.autoSelect=a,this.setValue=o,this.setAttribute=d,this.onUpdate=u,this.onSubmit=v,this.autocorrect=f,this.onShow=m,this.onHide=w,this.onLoading=k,this.onLoaded=C,this.submitOnEnter=_},ft=0,yt=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return"".concat(e).concat(++ft)},wt=function(e,t){var i=e.getBoundingClientRect(),s=t.getBoundingClientRect(),n=i.bottom+s.height>window.innerHeight&&window.innerHeight-i.bottom<i.top&&window.pageYOffset+i.top-s.height>0;return n?"above":"below"},bt=function(e,t,i){var s;return function(){var n=this,a=arguments,l=function(){s=null,i||e.apply(n,a)},o=i&&!s;clearTimeout(s),s=setTimeout(l,t),o&&e.apply(n,a)}},kt=function(e){if(null===e||void 0===e?void 0:e.length){var t=e.startsWith("#");return{attribute:t?"aria-labelledby":"aria-label",content:t?e.substring(1):e}}},Dt=function(){function e(t,i,s){rt(this,e),this.id="".concat(s,"-result-").concat(t),this["class"]="".concat(s,"-result"),this["data-result-index"]=t,this.role="option",t===i&&(this["aria-selected"]="true")}return ct(e,[{key:"toString",value:function(){var e=this;return Object.keys(this).reduce((function(t,i){return"".concat(t," ").concat(i,'="').concat(e[i],'"')}),"")}}]),e}(),Ct=function e(t){var i=this,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=s.search,a=s.onSubmit,l=void 0===a?function(){}:a,o=s.onUpdate,r=void 0===o?function(){}:o,d=s.baseClass,c=void 0===d?"autocomplete":d,u=s.autocorrect,h=void 0!==u&&u,v=s.autoSelect,p=s.getResultValue,m=void 0===p?function(e){return e}:p,g=s.renderResult,f=s.debounceTime,y=void 0===f?0:f,w=s.resultListLabel,b=s.submitOnEnter,k=void 0!==b&&b;rt(this,e),ut(this,"expanded",!1),ut(this,"loading",!1),ut(this,"position",{}),ut(this,"resetPosition",!0),ut(this,"initialize",(function(){i.root.style.position="relative",i.input.setAttribute("role","combobox"),i.input.setAttribute("autocomplete","off"),i.input.setAttribute("autocapitalize","off"),i.autocorrect&&i.input.setAttribute("autocorrect","on"),i.input.setAttribute("spellcheck","fal
6se"),i.input.setAttribute("aria-autocomplete","list"),i.input.setAttribute("aria-haspopup","listbox"),i.input.setAttribute("aria-expanded","false"),i.resultList.setAttribute("role","listbox");var e=kt(i.resultListLabel);e&&i.resultList.setAttribute(e.attribute,e.content),i.resultList.style.position="absolute",i.resultList.style.zIndex="1",i.resultList.style.width="100%",i.resultList.style.boxSizing="border-box",i.resultList.id||(i.resultList.id=yt("".concat(i.baseClass,"-result-list-"))),i.input.setAttribute("aria-owns",i.resultList.id),document.body.addEventListener("click",i.handleDocumentClick),i.input.addEventListener("input",i.core.handleInput),i.input.addEventListener("keydown",i.core.handleKeyDown),i.input.addEventListener("focus",i.core.handleFocus),i.input.addEventListener("blur",i.core.handleBlur),i.resultList.addEventListener("mousedown",i.core.handleResultMouseDown),i.resultList.addEventListener("click",i.core.handleResultClick),i.updateStyle()})),ut(this,"destroy",(function(){document.body.removeEventListener("click",i.handleDocumentClick),i.input.removeEventListener("input",i.core.handleInput),i.input.removeEventListener("keydown",i.core.handleKeyDown),i.input.removeEventListener("focus",i.core.handleFocus),i.input.removeEventListener("blur",i.core.handleBlur),i.resultList.removeEventListener("mousedown",i.core.handleResultMouseDown),i.resultList.removeEventListener("click",i.core.handleResultClick),i.root=null,i.input=null,i.resultList=null,i.getResultValue=null,i.onUpdate=null,i.renderResult=null,i.core.destroy(),i.core=null})),ut(this,"setAttribute",(function(e,t){i.input.setAttribute(e,t)})),ut(this,"setValue",(function(e){i.input.value=e?i.getResultValue(e):""})),ut(this,"renderResult",(function(e,t){return"<li ".concat(t,">").concat(i.getResultValue(e),"</li>")})),ut(this,"handleUpdate",(function(e,t){i.resultList.innerHTML="",e.forEach((function(e,s){var n=new Dt(s,t,i.baseClass),a=i.renderResult(e,n);"string"===typeof a?i.resultList.insertAdjacentHTML("beforeend",a):i.resultList.insertAdjacentElement("beforeend",a)})),i.input.setAttribute("aria-activedescendant",t>-1?"".concat(i.baseClass,"-result-").concat(t):""),i.resetPosition&&(i.resetPosition=!1,i.position=wt(i.input,i.resultList),i.updateStyle()),i.core.checkSelectedResultVisible(i.resultList),i.onUpdate(e,t)})),ut(this,"handleShow",(function(){i.expanded=!0,i.updateStyle()})),ut(this,"handleHide",(function(){i.expanded=!1,i.resetPosition=!0,i.updateStyle()})),ut(this,"handleLoading",(function(){i.loading=!0,i.updateStyle()})),ut(this,"handleLoaded",(function(){i.loading=!1,i.updateStyle()})),ut(this,"handleDocumentClick",(function(e){i.root.contains(e.target)||i.core.hideResults()})),ut(this,"updateStyle",(function(){i.root.dataset.expanded=i.expanded,i.root.dataset.loading=i.loading,i.root.dataset.position=i.position,i.resultList.style.visibility=i.expanded?"visible":"hidden",i.resultList.style.pointerEvents=i.expanded?"auto":"none","below"===i.position?(i.resultList.style.bottom=null,i.resultList.style.top="100%"):(i.resultList.style.top=null,i.resultList.style.bottom="100%")})),this.root="string"===typeof t?document.querySelector(t):t,this.input=this.root.querySelector("input"),this.resultList=this.root.querySelector("ul"),this.baseClass=c,this.autocorrect=h,this.getResultValue=m,this.onUpdate=r,"function"===typeof g&&(this.renderResult=g),this.resultListLabel=w,this.submitOnEnter=k;var D=new gt({search:n,autoSelect:v,setValue:this.setValue,setAttribute:this.setAttribute,onUpdate:this.handleUpdate,autocorrect:this.autocorrect,onSubmit:l,onShow:this.handleShow,onHide:this.handleHide,onLoading:this.handleLoading,onLoaded:this.handleLoaded,submitOnEnter:this.submitOnEnter});y>0&&(D.handleInput=bt(D.handleInput,y)),this.core=D,this.initialize()},Et=Ct;let _t=class extends S.lD{constructor(...e){super(...e),(0,_.A)(this,"staffManagerService",void 0),(0,_.A)(this,"autocompleteComp",null),(0,_.A)(this,"selectedStaff",null),(0,_.A)(this,"selectedStaffSearch",null),(0,_.A)(this,"staffAutocompleteFunction",void 0),(0,_.A)(this,"disabled",void 0)}mounted(){this.autocompleteComp=new Et(this.$refs.autocomplete,{search:e=>(this.selectedStaff=null,e?this.staffAutocompleteFunction(e):[]),onSubmit:e=>{this.selectedStaff=e,this.selectedStaffSearch=e.firstName+" "+e.lastName,this.$emit("staffSelected",e)},getResultValue:e=>e.firstName+" "+e.lastName,debounceTime:500})}clearSearch(){this.selectedStaff=null,this.selectedStaffSearch=null}beforeUnmount(){this.autocompleteComp.destroy()}autocompleteBlur(){null===this.selectedStaff&&null!==this.selectedStaffSearch&&(this.selectedStaffSearch=null,this.$emit("staffSelected",null))}};(0,A.Cg)([(0,T.y_)("staffManagerService")],_t.prototype,"staffManagerService",void 0),(0,A.Cg)([(0,T.kv)({required:!0})],_t.prototype,"staffAutocompleteFunction",void 0),(0,A.Cg)([(0,T.kv)({required:!1,default:!1})],_t.prototype,"disabled",void 0),_t=(0,A.Cg)([(0,S.JY)({props:{},components:{},emits:["staffSelected"]})],_t);var At=_t,St=i(66262);const Tt=(0,St.A)(At,[["render",ot]]);var Mt=Tt;const Lt=e=>((0,s.Qi)("data-v-9be0e6ce"),e=e(),(0,s.jt)(),e),xt={"data-cy":"manager-booking-modal-title"},Bt={class:"w-full",ref:"rootElement"}
6,$t={class:"w-full md:w-1/2 pt-2"},Ot={class:"mb-0","data-cy":"manager-booking-modal-center"},Vt=Lt((()=>(0,s.Lk)("b",null,"Center:",-1))),Wt={class:"w-full pt-2 md:w-1/2"},It={class:"mb-4"},Ht={class:"flex flex-wrap w-full"},Rt=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"},"Activity Group",-1))),Ft=["disabled"],Pt={selected:"",value:null},Xt=["value"],jt={class:"mb-4"},Nt={class:"flex flex-wrap w-full"},Yt={class:"w-full md:w-1/2 pr-1"},Gt=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"},[(0,s.eW)(" Activity "),(0,s.Lk)("span",{class:"text-red-500"},"*")],-1))),Ut=["disabled"],Qt=["value"],zt=Lt((()=>(0,s.Lk)("p",{class:"text-red-500 text-xs italic"},null,-1))),Kt={class:"w-full md:w-1/2 pr-1"},qt=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"}," Resource ",-1))),Jt=["disabled"],Zt={selected:"",value:void 0},ei=["value"],ti=Lt((()=>(0,s.Lk)("p",{class:"text-red-500 text-xs italic"},null,-1))),ii={class:"mb-4"},si={class:"flex flex-wrap w-full"},ni={class:"w-full md:w-1/2 pr-1"},ai=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"},[(0,s.eW)(" Start time "),(0,s.Lk)("span",{class:"text-red-500"},"*")],-1))),li={class:"w-full md:w-1/2 pl-1"},oi=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"},[(0,s.eW)(" Duration "),(0,s.Lk)("span",{class:"text-red-500"},"*")],-1))),ri=["disabled"],di={key:0,value:void 0},ci=["value"],ui={class:"mb-6"},hi=Lt((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"}," Select Instructors ",-1))),vi={class:"mt-1 flex flex-wrap"},pi={key:0,class:"mr-2 md:w-1/3"},mi=["onClick"],gi={class:"mb-4 flex flex-wrap w-full"},fi={class:"flex w-full justify-between"},yi=["disabled"],wi=["disabled"];function bi(e,t,i,l,o,r){const d=(0,s.g2)("staff-autocomplete"),c=(0,s.g2)("error-display"),u=(0,s.g2)("spinner"),h=(0,s.g2)("Modal"),v=(0,s.g2)("add-booking-participants-modal"),p=(0,s.g2)("add-booking-cancel-modal");return(0,s.uX)(),(0,s.CE)(s.FK,null,[!1===e.popupAddBookingType||e.popupAddBookingParticipants||e.popupCancelBooking?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.Wv)(h,{key:0,size:2,isOpen:!1!==e.popupAddBookingType,"overflow-visible":!0,"data-cy":"manager-booking-add-modal"},{title:(0,s.k6)((()=>[(0,s.Lk)("span",xt,(0,n.v_)(e.popupAddBookingType)+" A BOOKING",1)])),body:(0,s.k6)((()=>[(0,s.Lk)("div",Bt,[(0,s.Lk)("div",$t,[(0,s.Lk)("p",Ot,[Vt,(0,s.eW)(" "+(0,n.v_)(e.newBooking.selectedCenter.name),1)])]),(0,s.Lk)("div",Wt,[(0,s.Lk)("div",It,[(0,s.Lk)("div",Ht,[Rt,(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedActivityGroup=t),class:"select-input-field",onChange:t[1]||(t[1]=t=>e.initActivities()),disabled:e.readOnly,"data-cy":"manager-booking-activity-group-for-modal"},[(0,s.Lk)("option",Pt,(0,n.v_)(e.$t("staff.allGroups")),1),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.listActivityGroups,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e.id,value:e},(0,n.v_)(e.name),9,Xt)))),128))],40,Ft),[[a.u1,e.selectedActivityGroup]])])])]),(0,s.Lk)("div",jt,[(0,s.Lk)("div",Nt,[(0,s.Lk)("div",Yt,[Gt,(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[2]||(t[2]=t=>e.newBooking.selectedActivity=t),class:"select-input-field",onChange:t[3]||(t[3]=t=>e.selectedActivity()),disabled:e.readOnly,"data-cy":"manager-booking-modal-activity",autofocus:!1},[((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.listActivities,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e.id,value:e},(0,n.v_)(e.name),9,Qt)))),128))],40,Ut),[[a.u1,e.newBooking.selectedActivity]]),zt]),(0,s.Lk)("div",Kt,[qt,(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[4]||(t[4]=t=>e.newBooking.selectedResource=t),class:"select-input-field",disabled:null!==e.resourcesPlaceholder,"data-cy":"manager-booking-modal-resource",autofocus:!1},[(0,s.Lk)("option",Zt,(0,n.v_)(e.resourcesPlaceholder||""),1),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.listAvailableResources,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e.id,value:e},(0,n.v_)(e.name),9,ei)))),128))],8,Jt),[[a.u1,e.newBooking.selectedResource]]),ti])])]),(0,s.Lk)("div",ii,[(0,s.Lk)("div",si,[(0,s.Lk)("div",ni,[ai,(0,s.bo)((0,s.Lk)("input",{class:"select-input-field",type:"datetime-local","onUpdate:modelValue":t[5]||(t[5]=t=>e.newBooking.selectedDateTime=t),"data-cy":"manager-booking-modal-date-time",autofocus:!1},null,512),[[a.Jo,e.newBooking.selectedDateTime]])]),(0,s.Lk)("div",li,[oi,(0,s.bo)((0,s.Lk)("select",{"onUpdate:modelValue":t[6]||(t[6]=t=>e.newBooking.selectedDuration=t),class:"select-input-field",disabled:!e.newBooking.selectedActivity,"data-cy":"manager-booking-modal-duration",autofocus:!1},[e.newBooking.selectedActivity?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("option",di,"Select activity first")),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.newBooking.selectedActivity?.allowedDurations,(e=>((0,s.uX)(),(0,s.CE)("option",{key:e,value:e},(0,n.v_)(e)+" min ",9,ci)))),128))],8,ri),[[a.u1,e.newBooking.selectedDuration]])])])]),(0,s.Lk)("div",ui,[hi,
6(0,s.Lk)("div",vi,[e.readOnly?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",pi,[(0,s.bF)(d,{"data-cy":"manager-booking-modal-instructor-autocomplete",ref:"searchStaffAutocomplete","staff-autocomplete-function":e.staffAutocompleteFunction,onStaffSelected:e.staffSelected},null,8,["staff-autocomplete-function","onStaffSelected"])])),((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.newBooking.selectedInstructors,(t=>((0,s.uX)(),(0,s.CE)("span",{key:t.id,class:"select-input-badge px-2.5 py-0.5","data-cy":"manager-booking-modal-instructor-list"},[(0,s.eW)((0,n.v_)(t.firstName)+" "+(0,n.v_)(t.lastName)+" ",1),e.readOnly?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("p",{key:0,class:"text-sm text-red-500 ml-2 cursor-pointer",onClick:i=>e.removeStaff(t),"data-cy":"manager-booking-remove-staff"}," X ",8,mi))])))),128))])]),(0,s.Lk)("div",gi,[e.showAddParticipants?((0,s.uX)(),(0,s.CE)("button",{key:0,"data-cy":"button-open-popup-add-participants",onClick:t[7]||(t[7]=t=>e.openPopupParticipants()),class:"text-primary-500 font-bold py-1 text-sm outline-none focus:outline-none mr-1 mb-1",type:"button"}," View/Add participants ")):(0,s.Q3)("",!0),"EDIT"===e.popupAddBookingType?((0,s.uX)(),(0,s.CE)("button",{key:1,"data-cy":"button-open-popup-cancel-booking",onClick:t[8]||(t[8]=t=>e.openPopupCancelBooking()),class:"ml-auto text-primary-500 font-bold py-1 text-sm outline-none focus:outline-none mr-1 mb-1",type:"button"}," Cancel booking ")):(0,s.Q3)("",!0)])],512),(0,s.bF)(c,{"error-model":e.popupError,"data-cy":"manager-booking-modal-error"},null,8,["error-model"])])),buttons:(0,s.k6)((()=>[(0,s.Lk)("div",fi,[(0,s.Lk)("button",{onClick:t[9]||(t[9]=t=>e.saveBooking()),class:"flex btn-positive justify-center",disabled:e.popupLoading,"data-cy":"manager-booking-modal-save"},[(0,s.eW)((0,n.v_)(e.$t("general.save"))+" ",1),e.popupLoading?((0,s.uX)(),(0,s.Wv)(u,{key:0})):(0,s.Q3)("",!0)],8,yi),(0,s.Lk)("button",{onClick:t[10]||(t[10]=t=>e.closePopup()),class:"flex btn-negative justify-center",disabled:e.popupLoading,"data-cy":"manager-booking-modal-cancel"},(0,n.v_)(e.$t("general.close")),9,wi)])])),_:1},8,["isOpen"])),(0,s.bF)(v,{"popup-add-booking-participants":e.popupAddBookingParticipants,onClosePopup:t[11]||(t[11]=t=>e.closePopupParticipants())},null,8,["popup-add-booking-participants"]),(0,s.bF)(p,{"popup-cancel-booking":e.popupCancelBooking,onClosePopup:t[12]||(t[12]=t=>e.closePopupCancelBooking()),onCanceledBooking:t[13]||(t[13]=t=>e.canceledBooking())},null,8,["popup-cancel-booking"])],64)}var ki=i(73369);const Di=e=>((0,s.Qi)("data-v-218b7482"),e=e(),(0,s.jt)(),e),Ci=Di((()=>(0,s.Lk)("span",{"data-cy":"manager-booking-participant-modal-title"},"BOOKING PARTICIPANTS",-1))),Ei={class:"w-full min-h-[16rem]"},_i={key:0,"data-cy":"loading-participant"},Ai={key:1,class:"flex flex-wrap w-full"},Si={class:"w-full md:w-1/2 pr-1","data-cy":"list-participants"},Ti=Di((()=>(0,s.Lk)("h2",{class:"mb-2 text-lg font-semibold text-gray-900"},"List of participants:",-1))),Mi={class:"pt-1"},Li={class:"w-full md:w-1/2 pr-1","data-cy":"add-participant"},xi=Di((()=>(0,s.Lk)("h2",{class:"mb-2 text-lg font-semibold text-gray-900"},"Add a new participant",-1))),Bi={class:"mb-6"},$i=Di((()=>(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-2"}," Search member ",-1))),Oi={key:0,class:"max-w-sm rounded overflow-hidden shadow-lg","data-cy":"selected-member-popup"},Vi={class:"px-6 py-4"},Wi={class:"font-bold text-lg mb-2","data-cy":"selected-member-popup-name"},Ii=Di((()=>(0,s.Lk)("p",{class:"text-gray-700 text-base","data-cy":"selected-member-popup-question"},"Add member to the booking ?",-1))),Hi={class:"px-6 pt-4 pb-2"},Ri=["disabled"],Fi={class:"flex w-full justify-between"},Pi=["disabled"];function Xi(e,t,i,a,l,o){const r=(0,s.g2)("staff-autocomplete"),d=(0,s.g2)("error-display"),c=(0,s.g2)("Modal");return!1!==e.popupAddBookingParticipants?((0,s.uX)(),(0,s.Wv)(c,{key:0,size:3,isOpen:!1!==e.popupAddBookingParticipants,"data-cy":"manager-booking-participants-modal"},{title:(0,s.k6)((()=>[Ci])),body:(0,s.k6)((()=>[(0,s.Lk)("div",Ei,[e.bookingDetailsLoading?((0,s.uX)(),(0,s.CE)("div",_i,"Loading participants ..")):(0,s.Q3)("",!0),e.bookingDetailsLoading||null===e.bookingPaarticipants?(0,s.Q3)("",!0):((0,s.uX)(),(0,s.CE)("div",Ai,[(0,s.Lk)("div",Si,[Ti,((0,s.uX)(!0),(0,s.CE)(s.FK,null,(0,s.pI)(e.bookingPaarticipants,(e=>((0,s.uX)(),(0,s.CE)("ul",{key:e.id+"p"+e.centerId,class:"space-y-1 max-w-md list-disc list-inside"}
6,[(0,s.Lk)("li",Mi,(0,n.v_)(e.firstName)+" "+(0,n.v_)(e.lastName),1)])))),128))]),(0,s.Lk)("div",Li,[xi,(0,s.Lk)("div",Bi,[$i,(0,s.bF)(r,{"data-cy":"manager-booking-modal-member-autocomplete",ref:"searchMemberAutocomplete","staff-autocomplete-function":e.memberAutocompleteFunction,onStaffSelected:e.memberSelected},null,8,["staff-autocomplete-function","onStaffSelected"])]),e.memberSelectedToAdd?((0,s.uX)(),(0,s.CE)("div",Oi,[(0,s.Lk)("div",Vi,[(0,s.Lk)("div",Wi,(0,n.v_)(e.memberSelectedToAdd.firstName)+" "+(0,n.v_)(e.memberSelectedToAdd.lastName),1),Ii]),(0,s.Lk)("div",Hi,[(0,s.Lk)("button",{"data-cy":"selected-member-popup-button",onClick:t[0]||(t[0]=t=>e.addMemberToBooking(e.memberSelectedToAdd)),disabled:e.addingMemberLoading,class:"inline-block bg-gray-200 rounded-full px-3 py-1 text-sm font-semibold text-gray-700 mr-2 mb-2 cursor-pointer"},(0,n.v_)(e.addingMemberLoading?"Please wait..":"Add"),9,Ri)])])):(0,s.Q3)("",!0)])]))]),(0,s.bF)(d,{class:"align-bottom","error-model":e.popupError,"data-cy":"manager-booking-participants-modal-error"},null,8,["error-model"])])),buttons:(0,s.k6)((()=>[(0,s.Lk)("div",Fi,[(0,s.Lk)("button",{onClick:t[1]||(t[1]=t=>e.closePopup()),class:"flex btn-negative justify-center",disabled:e.bookingDetailsLoading,"data-cy":"manager-booking-participants-modal-cancel"},(0,n.v_)(e.$t("general.cancel")),9,Pi)])])),_:1},8,["isOpen"])):(0,s.Q3)("",!0)}let ji=class extends S.lD{constructor(...e){super(...e),(0,_.A)(this,"staffManagerService",void 0),(0,_.A)(this,"userService",void 0),(0,_.A)(this,"popupAddBookingParticipants",void 0),(0,_.A)(this,"bookingDetailsLoading",!1),(0,_.A)(this,"popupError",null),(0,_.A)(this,"addingMemberLoading",!1),(0,_.A)(this,"bookingPaarticipants",null),(0,_.A)(this,"searchMemberAutocomplete",null),(0,_.A)(this,"memberSelectedToAdd",null)}mounted(){this.searchMemberAutocomplete=this.$refs.searchMemberAutocomplete}onPopupAddBookingTypeChanged(){this.bookingPaarticipants=null,this.popupAddBookingParticipants&&this.loadBookingParticipants()}async memberAutocompleteFunction(e){return this.memberSelectedToAdd=null,this.userService.searchUsers(void 0,e,void 0,void 0).then((e=>e)).catch((e=>[]))}memberSelected(e){this.memberSelectedToAdd=e,this.searchMemberAutocomplete.clearSearch()}addMemberToBooking(e){this.addingMemberLoading=!0,this.popupError=null,this.staffManagerService.addBookingParticipant(this.popupAddBookingParticipants,e.centerId+"p"+e.userId).then((e=>{this.bookingPaarticipants=e,this.addingMemberLoading=!1,this.searchMemberAutocomplete.clearSearch(),this.memberSelectedToAdd=null})).catch((e=>{this.popupError=e,this.addingMemberLoading=!1}))}loadBookingParticipants(){this.bookingDetailsLoading=!0,this.popupError=null,this.staffManagerService.getBookingParticipants(this.popupAddBookingParticipants).then((e=>{this.bookingPaarticipants=e,this.bookingDetailsLoading=!1})).catch((e=>{this.popupError=e,this.bookingDetailsLoading=!1}))}closePopup(){this.$emit("closePopup")}};(0,A.Cg)([(0,T.y_)("staffManagerService")],ji.prototype,"staffManagerService",void 0),(0,A.Cg)([(0,T.y_)("userService")],ji.prototype,"userService",void 0),(0,A.Cg)([(0,T.kv)({required:!0})],ji.prototype,"popupAddBookingParticipants",void 0),(0,A.Cg)([(0,T.ox)("popupAddBookingParticipants")],ji.prototype,"onPopupAddBookingTypeChanged",null),ji=(0,A.Cg)([(0,S.JY)({props:{},components:{Spinner:L.A,Modal:ki.A,ErrorDisplay:x.A,StaffAutocomplete:Mt},emits:["closePopup"]})],ji);var Ni=ji;const Yi=(0,St.A)(Ni,[["render",Xi],["__scopeId","data-v-218b7482"]]);var Gi=Yi;const Ui=(0,s.Lk)("span",{"data-cy":"manager-booking-cancel-modal-title"},"CANCEL BOOKING",-1),Qi={class:"w-full",ref:"rootElement"},zi={class:"mb-6"},Ki={class:"flex flex-wrap w-full"},qi={class:"w-full pr-1"},Ji=(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-4"}," Cancel reason ",-1),Zi={class:"mb-6"},es={class:"flex flex-wrap w-full"},ts={class:"w-full pr-1"},is=(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-4"}," Send Message ",-1),ss={class:"flex"},ns={class:"flex items-center mr-4"},as=(0,s.Lk)("label",{for:"inline-checkbox-participants",class:"check-box-label"},"To Participants ",-1),ls={class:"flex items-center mr-4"},os=(0,s.Lk)("label",{for:"inline-checkbox-staff",class:"check-box-label"}
6,"To Instructors ",-1),rs={class:"mb-6"},ds={class:"flex flex-wrap w-full"},cs={class:"w-full pr-1 mb-2"},us=(0,s.Lk)("label",{class:"block text-gray-700 text-sm font-bold mb-4"}," Bookings to cancel ",-1),hs={class:"flex items-center mb-4"},vs=(0,s.Lk)("label",{for:"default-radio-1",class:"radio-label"},"This booking",-1),ps={class:"flex items-center mb-4"},ms=(0,s.Lk)("label",{for:"default-radio-2",class:"radio-label"},"This booking and future bookings",-1),gs={class:"flex items-center mb-4"},fs=(0,s.Lk)("label",{for:"default-radio-3",class:"radio-label"},"All bookings",-1),ys={class:"flex w-full justify-between"},ws=["disabled"],bs=["disabled"];function ks(e,t,i,l,o,r){const d=(0,s.g2)("error-display"),c=(0,s.g2)("spinner"),u=(0,s.g2)("Modal");return!1!==e.popupCancelBooking?((0,s.uX)(),(0,s.Wv)(u,{key:0,size:1,isOpen:!1!==e.popupCancelBooking,"data-cy":"manager-booking-cancel-modal"},{title:(0,s.k6)((()=>[Ui])),body:(0,s.k6)((()=>[(0,s.Lk)("div",Qi,[(0,s.Lk)("div",zi,[(0,s.Lk)("div",Ki,[(0,s.Lk)("div",qi,[Ji,(0,s.bo)((0,s.Lk)("input",{class:"select-input-field",type:"text","onUpdate:modelValue":t[0]||(t[0]=t=>e.cancelReason=t),"data-cy":"manager-booking-cancel-reason"},null,512),[[a.Jo,e.cancelReason]])])])]),(0,s.Lk)("div",Zi,[(0,s.Lk)("div",es,[(0,s.Lk)("div",ts,[is,(0,s.Lk)("div",ss,[(0,s.Lk)("div",ns,[(0,s.bo)((0,s.Lk)("input",{id:"inline-checkbox-participants",type:"checkbox","onUpdate:modelValue":t[1]||(t[1]=t=>e.toParticipants=t),class:"check-box-input","data-cy":"manager-booking-cancel-participants"},null,512),[[a.lH,e.toParticipants]]),as]),(0,s.Lk)("div",ls,[(0,s.bo)((0,s.Lk)("input",{id:"inline-checkbox-staff",type:"checkbox","onUpdate:modelValue":t[2]||(t[2]=t=>e.toStaff=t),class:"check-box-input","data-cy":"manager-booking-cancel-staff"},null,512),[[a.lH,e.toStaff]]),os])])])])]),(0,s.Lk)("div",rs,[(0,s.Lk)("div",ds,[(0,s.Lk)("div",cs,[us,(0,s.Lk)("div",hs,[(0,s.bo)((0,s.Lk)("input",{id:"default-radio-1",type:"radio","onUpdate:modelValue":t[3]||(t[3]=t=>e.cancelEffect=t),value:"SINGLE",name:"default-radio",class:"radio-input","data-cy":"manager-booking-cancel-this-booking"},null,512),[[a.XL,e.cancelEffect]]),vs]),(0,s.Lk)("div",ps,[(0,s.bo)((0,s.Lk)("input",{id:"default-radio-2",type:"radio","onUpdate:modelValue":t[4]||(t[4]=t=>e.cancelEffect=t),value:"FOLLOWING",name:"default-radio",class:"radio-input","data-cy":"manager-booking-cancel-future-booking"},null,512),[[a.XL,e.cancelEffect]]),ms]),(0,s.Lk)("div",gs,[(0,s.bo)((0,s.Lk)("input",{id:"default-radio-3",type:"radio","onUpdate:modelValue":t[5]||(t[5]=t=>e.cancelEffect=t),value:"ALL",name:"default-radio",class:"radio-input","data-cy":"manager-booking-cancel-all-booking"},null,512),[[a.XL,e.cancelEffect]]),fs])])])])],512),(0,s.bF)(d,{class:"align-bottom","error-model":e.popupError,"data-cy":"manager-booking-cancel-modal-error"},null,8,["error-model"])])),buttons:(0,s.k6)((()=>[(0,s.Lk)("div",ys,[(0,s.Lk)("button",{class:"flex btn-positive justify-center",disabled:e.bookingCancelLoading,onClick:t[6]||(t[6]=t=>e.cancelBooking()),"data-cy":"manager-booking-cancel-modal-confirm"},[(0,s.eW)((0,n.v_)(e.$t("general.confirm"))+" ",1),e.bookingCancelLoading?((0,s.uX)(),(0,s.Wv)(c,{key:0})):(0,s.Q3)("",!0)],8,ws),(0,s.Lk)("button",{onClick:t[7]||(t[7]=t=>e.closePopup()),class:"flex btn-negative justify-center",disabled:e.bookingCancelLoading,"data-cy":"manager-booking-cancel-modal-cancel"},(0,n.v_)(e.$t("general.close")),9,bs)])])),_:1},8,["isOpen"])):(0,s.Q3)("",!0)}var Ds=i(21722);let Cs=class extends S.lD{constructor(...e){super(...e),(0,_.A)(this,"staffManagerService",void 0),(0,_.A)(this,"popupCancelBooking",void 0),(0,_.A)(this,"bookingCancelLoading",!1),(0,_.A)(this,"popupError",null),(0,_.A)(this,"cancelReason",""),(0,_.A)(this,"toParticipants",!1),(0,_.A)(this,"toStaff",!1),(0,_.A)(this,"cancelEffect","SINGLE")}mounted(){}blurElements(){this.$nextTick((()=>{this.$refs.rootElement&&(0,Ds.kD)(this.$refs.rootElement)}))}onPopupCancelBooking(){this.popupError=null,this.bookingCancelLoading=!1,this.cancelReason="",this.toParticipants=!1,this.toStaff=!1,this.cancelEffect="SINGLE",this.blurElements()}cancelBooking(){this.bookingCancelLoading=!0,this.popupError=null,this.staffManagerService.deleteStaffBooking(this.popupCancelBooking,this.cancelReason,this.toParticipants,this.toStaff,this.cancelEffect).then((()=>{this.bookingCancelLoading=!1,this.canceledBooking()})).catch((e=>{this.popupError=e,this.bookingCancelLoading=!1}))}
6closePopup(){this.$emit("closePopup")}canceledBooking(){this.$emit("canceledBooking")}};(0,A.Cg)([(0,T.y_)("staffManagerService")],Cs.prototype,"staffManagerService",void 0),(0,A.Cg)([(0,T.kv)({required:!0})],Cs.prototype,"popupCancelBooking",void 0),(0,A.Cg)([(0,T.ox)("popupCancelBooking")],Cs.prototype,"onPopupCancelBooking",null),Cs=(0,A.Cg)([(0,S.JY)({props:{},components:{Spinner:L.A,Modal:ki.A,ErrorDisplay:x.A},emits:["closePopup","canceledBooking"]})],Cs);var Es=Cs;const _s=(0,St.A)(Es,[["render",ks]]);var As=_s;let Ss=class extends S.lD{constructor(...e){super(...e),(0,_.A)(this,"staffManagerService",void 0),(0,_.A)(this,"popupAddBookingType",void 0),(0,_.A)(this,"newBooking",void 0),(0,_.A)(this,"popupLoading",!1),(0,_.A)(this,"popupError",null),(0,_.A)(this,"searchStaffAutocomplete",null),(0,_.A)(this,"listAvailableResources",[]),(0,_.A)(this,"loadingResources",!1),(0,_.A)(this,"resroucesRequestError",null),(0,_.A)(this,"popupAddBookingParticipants",!1),(0,_.A)(this,"popupCancelBooking",!1),(0,_.A)(this,"listActivities",[]),(0,_.A)(this,"listActivityGroups",[]),(0,_.A)(this,"selectedActivityGroup",null)}mounted(){this.searchStaffAutocomplete=this.$refs.searchStaffAutocomplete}onPopupAddBookingTypeChanged(){this.popupError=null,this.listAvailableResources=[],this.initActivityGroups(this.newBooking.paramListActivities),"EDIT"===this.popupAddBookingType&&this.newBooking.selectedActivity&&this.selectedActivity(),this.blurElements()}blurElements(){this.$nextTick((()=>{setTimeout((()=>{this.$refs.rootElement&&(0,Ds.kD)(this.$refs.rootElement)}),70)}))}closePopup(){this.$emit("closePopup")}closePopupParticipants(){this.popupAddBookingParticipants=!1,this.blurElements()}openPopupParticipants(){this.popupAddBookingParticipants=this.newBooking.bookingCenterId+"book"+this.newBooking.bookingId}closePopupCancelBooking(){this.popupCancelBooking=!1,this.blurElements()}canceledBooking(){this.closePopupCancelBooking(),this.$emit("bookingUpdated",this.newBooking.selectedDateTime)}openPopupCancelBooking(){this.popupCancelBooking=this.newBooking.bookingCenterId+"book"+this.newBooking.bookingId}async staffAutocompleteFunction(e){return this.staffManagerService.findStaff(e,void 0).then((e=>e)).catch((e=>[]))}staffSelected(e){e&&(this.newBooking.selectedInstructors.find((t=>t.userId===e.userId))||this.newBooking.selectedInstructors.push(e)),this.searchStaffAutocomplete.clearSearch()}removeStaff(e){this.newBooking.selectedInstructors=this.newBooking.selectedInstructors.filter((t=>t.userId!==e.userId))}selectedActivity(){this.popupError=null,this.newBooking.selectedDuration=this.newBooking.selectedActivity.allowedDurations?.find((e=>e===this.newBooking.selectedDuration)),this.loadingResources=!0,this.resroucesRequestError=null,this.listAvailableResources=[],this.newBooking.selectedResource=void 0,this.staffManagerService.findResroucesForActivity(this.newBooking.selectedActivity.id,this.newBooking.selectedCenter.id).then((e=>{this.loadingResources=!1,this.resroucesRequestError=null,this.listAvailableResources=e,this.newBooking.selectedResource=e.find((e=>this.newBooking.selectedResourceNames?.includes(e.name)))})).catch((e=>{this.resroucesRequestError=e,this.loadingResources=!1}))}initActivityGroups(e){this.listActivityGroups=[],e.forEach((e=>{const t=this.listActivityGroups.find((t=>t.id===e.group.id));t||this.listActivityGroups.push(e.group)})),this.listActivityGroups.sort(((e,t)=>(e.name+"").localeCompare(t.name+""))),this.initActivities()}initActivities(){const e=this.newBooking.paramListActivities;this.selectedActivityGroup?(this.listActivities=e.filter((e=>e.group.id===this.selectedActivityGroup.id)),this.listActivities.sort(((e,t)=>(e.name+"").localeCompare(t.name+"")))):this.listActivities=e}saveBooking(){if(this.popupError=null,!this.newBooking.selectedActivity)return void(this.popupError=new M.C5("Please select an activity"));if(!this.newBooking.selectedDateTime||!this.newBooking.selectedDuration)return void(this.popupError=new M.C5("Please select a date and duration"));let e;e="CREATE"===this.popupAddBookingType?this.staffManagerService.createStaffBooking({maxCapacity:this.newBooking.maxCapacity,name:this.newBooking.name,selectedActivityId:this.newBooking.selectedActivity.id,selectedCenterId:this.newBooking.selectedCenter.id,selectedDate:this.newBooking.selectedDateTime.substring(0,10),selectedTime:this.newBooking.selectedDateTime.substring(11,16),selectedDuration:Number(this.newBooking.selectedDuration),selectedInstructors:this.newBooking.selectedInstructors.map((e=>
6e.centerId+"p"+e.userId)),selectedResourceId:this.getResourceById()}):this.staffManagerService.updateStaffBooking(this.newBooking.bookingId,this.newBooking.bookingCenterId,this.newBooking.selectedDateTime.substring(0,16),Number(this.newBooking.selectedDuration),this.getResourceById()),this.popupLoading=!0,e.then((()=>{this.popupLoading=!1,this.$emit("bookingUpdated",this.newBooking.selectedDateTime)})).catch((e=>{this.popupLoading=!1,this.popupError=e}))}getResourceById(){return this.newBooking.selectedResource?this.newBooking.selectedResource.key.center+"br"+this.newBooking.selectedResource.key.id:void 0}get readOnly(){return"EDIT"===this.popupAddBookingType}get resourcesPlaceholder(){return this.loadingResources?"Loading resources..":this.newBooking.selectedActivity?this.resroucesRequestError?this.$t(this.resroucesRequestError.errorI18NMessage):null:"Select activity first"}get showAddParticipants(){return("CLASS"===this.newBooking.selectedActivity?.activityType||"STAFF_BOOKING"===this.newBooking.selectedActivity?.activityType)&&"EDIT"===this.popupAddBookingType}};(0,A.Cg)([(0,T.y_)("staffManagerService")],Ss.prototype,"staffManagerService",void 0),(0,A.Cg)([(0,T.kv)({default:!1})],Ss.prototype,"popupAddBookingType",void 0),(0,A.Cg)([(0,T.kv)({required:!0})],Ss.prototype,"newBooking",void 0),(0,A.Cg)([(0,T.ox)("popupAddBookingType")],Ss.prototype,"onPopupAddBookingTypeChanged",null),Ss=(0,A.Cg)([(0,S.JY)({props:{},components:{Spinner:L.A,Modal:ki.A,ErrorDisplay:x.A,StaffAutocomplete:Mt,AddBookingParticipantsModal:Gi,AddBookingCancelModal:As},emits:["closePopup","bookingUpdated"]})],Ss);var Ts=Ss;const Ms=(0,St.A)(Ts,[["render",bi],["__scopeId","data-v-9be0e6ce"]]);var Ls=Ms,xs=i(45877);let Bs=class extends S.lD{constructor(...e){super(...e),(0,_.A)(this,"staffManagerService",void 0),(0,_.A)(this,"classesService",void 0),(0,_.A)(this,"selectedCenter",null),(0,_.A)(this,"selectedStaff",null),(0,_.A)(this,"errorLoadingBookings",null),(0,_.A)(this,"loadingBookings",!1),(0,_.A)(this,"bookings",[]),(0,_.A)(this,"events",[]),(0,_.A)(this,"calendarMinDate",null),(0,_.A)(this,"calendarMaxDate",null),(0,_.A)(this,"selectedCalendarDate",new Date),(0,_.A)(this,"isCalendarReady",!1),(0,_.A)(this,"searchStaffAutocomplete",null),(0,_.A)(this,"listAllActivities",[]),(0,_.A)(this,"listActivities",[]),(0,_.A)(this,"listActivityGroups",[]),(0,_.A)(this,"selectedActivityGroup",null),(0,_.A)(this,"selectedActivities",[]),(0,_.A)(this,"loadingActivities",!1),(0,_.A)(this,"errorActivities",null),(0,_.A)(this,"popupAddBookingType",!1),(0,_.A)(this,"selectedViewDate",null),(0,_.A)(this,"newBooking",null),(0,_.A)(this,"currentView","day"),(0,_.A)(this,"timeOutNumber",void 0)}mounted(){this.searchStaffAutocomplete=this.$refs.searchStaffAutocomplete}async staffAutocompleteFunction(e){return this.staffManagerService.findStaff(e,void 0).then((e=>e)).catch((e=>[]))}staffSelected(e){this.selectedStaff=e,this.searchBookings()}updateCenterId(e){this.selectedCenter=e,this.currentView="day",this.searchStaffAutocomplete.clearSearch(),this.loadActivities(e.id)}loadActivities(e){this.loadingActivities=!0,this.errorActivities=null,this.clearActivities(),this.classesService.loadAvailableActivitiesForCenter([e],[M.Mr.CLASS,M.Mr.STAFF_BOOKING,M.Mr.STAFF_AVAILABILITY]).then((e=>{this.listAllActivities=e,this.loadingActivities=!1,this.initActivityGroups(e),this.$nextTick((()=>{this.searchBookings()}))})).catch((e=>{this.errorActivities=e.errorI18NMessage,this.loadingActivities=!1,this.clearActivities()}))}clearActivities(){this.listActivities=[],this.listActivityGroups=[],this.listAllActivities=[],this.selectedActivities=[],this.selectedActivityGroup=null}initActivityGroups(e){this.listActivityGroups=[],e.forEach((e=>{const t=this.listActivityGroups.find((t=>t.id===e.group.id));t||this.listActivityGroups.push(e.group)})),this.listActivityGroups.sort(((e,t)=>(e.name+"").localeCompare(t.name+""))),this.initActivities()}initActivities(){this.selectedActivities=[],this.selectedActivityGroup?(this.listActivities=this.listAllActivities.filter((e=>e.group.id===this.selectedActivityGroup.id)),this.listActivities.sort(((e,t)=>(e.name+"").localeCompare(t.name+"")))):this.listActivities=this.listAllActivities}changedActivityGroup(){this.initActivities(),this.searchBookings()}changedActivities(){this.searchBookings()}bookingToEvent(e){return{start:e.date+" "+e.startTime,end:e.date+" "+e.endTime,title:String(e.name),booking:{id:e.id,center:e.centerId,instructors:e.instructorNames,maxCapacity:e.classCapacity,name:e.name,selectedActivity:e.activity,selectedDateTime:e.date+"T"+e.startTime,selectedDuration:String(e.durationMinutes),selectedResourceNames:e.roomNames}}}onEventClick(e){this.openPopupUpdate(e)}onCellDblClick(e){this.openPopupAdd(e)}switchToNarrowerView(){this.$refs["vue-cal"].switchView("day")}viewChange(e){this.calendarMinDate=e.firstCellDate?(0,st.d5)(e.firstCellDate).substring(0,10):(0,st.d5)(e.startDate).substring(0,10),this.calendarMaxDate=e.lastCellDate?(0,st.d5)(e.last
6CellDate).substring(0,10):(0,st.d5)(e.endDate).substring(0,10),this.currentView=e.view,"day"===e.view&&(this.selectedViewDate=e.startDate),this.searchBookings()}calendarReady(e){this.calendarMinDate=(0,st.d5)(e.startDate).substring(0,10),this.calendarMaxDate=(0,st.d5)(e.endDate).substring(0,10),this.selectedViewDate=e.startDate}handleDayWeekViewScrolling(e){if("month"==this.currentView)return;this.timeOutNumber&&clearTimeout(this.timeOutNumber);let t=new Date;if(e)t=new Date(e);else{t.setHours(6),t.setMinutes(30);let e=1;for(const i in this.events)if(Object.prototype.hasOwnProperty.call(this.events,i)){const s=this.events[i];if(1==e)t=new Date(s.start),e++;else{const e=new Date(s.start);t=(0,st.Jk)(e.getHours(),e.getMinutes())<(0,st.Jk)(t.getHours(),t.getMinutes())?e:t}}}this.scrollToSpecificTime(t,1)}scrollToSpecificTime(e,t){const i=this.$refs["vue-cal"];if("true"!=={VUE_APP_BACKEND_API_URL:"/api",NODE_ENV:"production",BASE_URL:"/"}.VUE_APP_CYPRESS&&i&&i.$el||"true"==={VUE_APP_BACKEND_API_URL:"/api",NODE_ENV:"production",BASE_URL:"/"}.VUE_APP_CYPRESS&&i&&i.$el&&t>1){const t=i.$el.querySelector(".vuecal__bg");let s=e.getHours()+e.getMinutes()/60;s>=1&&(s-=.5);const n=s*(2*i.timeCellHeight);t.scrollTo({top:n,behavior:"smooth"})}else this.timeOutNumber=setTimeout((()=>{this.scrollToSpecificTime(e,++t)}),100)}searchBookings(e=""){this.loadingBookings||(this.loadingBookings=!0,this.errorLoadingBookings=null,this.staffManagerService.searchAllBookings({instructor:this.selectedStaff?this.selectedStaff.firstName+" "+this.selectedStaff.lastName:void 0,dateFrom:this.calendarMinDate,dateTo:this.calendarMaxDate,activityGroupIds:!this.selectedActivities.length&&this.selectedActivityGroup?[this.selectedActivityGroup.id]:[],activityIds:this.selectedActivities.length?[...this.selectedActivities.map((e=>e.id))]:[],centers:[this.selectedCenter.id]}).then((t=>{this.bookings.length=0,this.events.length=0,t.forEach((e=>{this.bookings.push(e),this.events.push(this.bookingToEvent(e))})),this.loadingBookings=!1,this.$nextTick((()=>{this.handleDayWeekViewScrolling(e)}))})).catch((e=>{this.errorLoadingBookings=e,this.loadingBookings=!1})))}openPopupAdd(e){this.newBooking={paramListActivities:this.listAllActivities,selectedDateTime:(0,st.Eb)(e||this.selectedViewDate),selectedCenter:this.selectedCenter,selectedInstructors:this.selectedStaff?[this.selectedStaff]:[]},this.popupAddBookingType="CREATE"}closePopup(){this.popupAddBookingType=!1}bookingUpdatedFromPopup(e){this.closePopup(),this.selectedActivities=[],this.selectedActivityGroup=null,this.searchStaffAutocomplete.clearSearch(),this.selectedStaff=null,this.selectedCalendarDate=new Date(this.newBooking.selectedDateTime),this.$nextTick((()=>{this.searchBookings(e)}))}openPopupUpdate(e){this.newBooking={bookingId:e.booking.id,bookingCenterId:e.booking.center,paramListActivities:this.listAllActivities,selectedDateTime:e.booking.selectedDateTime,selectedCenter:this.selectedCenter,selectedInstructors:e.booking.instructors.map((e=>{const t={accessLevel:[],centerId:this.selectedCenter.id,userId:0,gender:"UNDEFINED",firstName:e,lastName:"",relations:[]};return t})),maxCapacity:e.booking.maxCapacity,name:e.booking.name,selectedActivity:this.listAllActivities.find((t=>e.booking.selectedActivity.id===t.id)),selectedDuration:e.booking.selectedDuration,selectedResourceNames:e.booking.selectedResourceNames},this.popupAddBookingType="EDIT"}get displayCalendar(){return!this.errorLoadingBookings&&!this.loadingActivities&&!this.errorActivities&&null!==this.selectedCenter}get activitiesPlaceholder(){return this.loadingActivities?this.$t("booking.loadingActivities"):this.errorActivities?this.$t(this.errorActivities):null===this.selectedCenter?"Select Center first":null}};(0,A.Cg)([(0,T.y_)("staffManagerService")],Bs.prototype,"staffManagerService",void 0),(0,A.Cg)([(0,T.y_)("classesService")],Bs.prototype,"classesService",void 0),Bs=(0,A.Cg)([(0,S.JY)({components:{SearchStaffCenters:it.A,Spinner:L.A,ErrorDisplay:x.A,VueCal:tt,StaffAutocomplete:Mt,VueMultiselect:xs.Ay,AddBookingModal:Ls}})],Bs);var $s=Bs;const Os=(0,St.A)($s,[["render",E]]);var Vs=Os},78110:function(e,t,i){i.d(t,{A:function(){return n}});var s=i(20641);function n(e,t){return(0,s.uX)(),(0,s.Wv)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor","aria-hidden":"true"},[(0,s.bF)("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15"})])}}}]);
7//# sourceMappingURL=manager-booking-schedule.7f548a41.js.map

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.