mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
2 lines
150 KiB
JavaScript
2 lines
150 KiB
JavaScript
(function(){var e={41993:function(e){function t(e){return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}))}t.keys=function(){return[]},t.resolve=t,t.id=41993,e.exports=t},46700:function(e,t,s){var a={"./af":63906,"./af.js":63906,"./ar":40902,"./ar-dz":3853,"./ar-dz.js":3853,"./ar-kw":20299,"./ar-kw.js":20299,"./ar-ly":96825,"./ar-ly.js":96825,"./ar-ma":66379,"./ar-ma.js":66379,"./ar-sa":87700,"./ar-sa.js":87700,"./ar-tn":2059,"./ar-tn.js":2059,"./ar.js":40902,"./az":76043,"./az.js":76043,"./be":7936,"./be.js":7936,"./bg":34078,"./bg.js":34078,"./bm":14014,"./bm.js":14014,"./bn":29554,"./bn-bd":17114,"./bn-bd.js":17114,"./bn.js":29554,"./bo":6529,"./bo.js":6529,"./br":65437,"./br.js":65437,"./bs":19647,"./bs.js":19647,"./ca":59951,"./ca.js":59951,"./cs":26113,"./cs.js":26113,"./cv":37965,"./cv.js":37965,"./cy":35858,"./cy.js":35858,"./da":33515,"./da.js":33515,"./de":62831,"./de-at":6263,"./de-at.js":6263,"./de-ch":51127,"./de-ch.js":51127,"./de.js":62831,"./dv":4510,"./dv.js":4510,"./el":68616,"./el.js":68616,"./en-au":24595,"./en-au.js":24595,"./en-ca":73545,"./en-ca.js":73545,"./en-gb":79609,"./en-gb.js":79609,"./en-ie":43727,"./en-ie.js":43727,"./en-il":93302,"./en-il.js":93302,"./en-in":46305,"./en-in.js":46305,"./en-nz":39128,"./en-nz.js":39128,"./en-sg":84569,"./en-sg.js":84569,"./eo":50650,"./eo.js":50650,"./es":26358,"./es-do":64214,"./es-do.js":64214,"./es-mx":38639,"./es-mx.js":38639,"./es-us":30232,"./es-us.js":30232,"./es.js":26358,"./et":47279,"./et.js":47279,"./eu":15515,"./eu.js":15515,"./fa":27981,"./fa.js":27981,"./fi":37090,"./fi.js":37090,"./fil":79208,"./fil.js":79208,"./fo":2799,"./fo.js":2799,"./fr":23463,"./fr-ca":2213,"./fr-ca.js":2213,"./fr-ch":52848,"./fr-ch.js":52848,"./fr.js":23463,"./fy":41468,"./fy.js":41468,"./ga":88163,"./ga.js":88163,"./gd":2898,"./gd.js":2898,"./gl":76312,"./gl.js":76312,"./gom-deva":20682,"./gom-deva.js":20682,"./gom-latn":49178,"./gom-latn.js":49178,"./gu":31400,"./gu.js":31400,"./he":52795,"./he.js":52795,"./hi":17009,"./hi.js":17009,"./hr":46506,"./hr.js":46506,"./hu":69565,"./hu.js":69565,"./hy-am":93864,"./hy-am.js":93864,"./id":5626,"./id.js":5626,"./is":36649,"./is.js":36649,"./it":90151,"./it-ch":95348,"./it-ch.js":95348,"./it.js":90151,"./ja":79830,"./ja.js":79830,"./jv":33751,"./jv.js":33751,"./ka":63365,"./ka.js":63365,"./kk":85980,"./kk.js":85980,"./km":99571,"./km.js":99571,"./kn":25880,"./kn.js":25880,"./ko":16809,"./ko.js":16809,"./ku":96773,"./ku.js":96773,"./ky":65505,"./ky.js":65505,"./lb":50553,"./lb.js":50553,"./lo":51237,"./lo.js":51237,"./lt":91563,"./lt.js":91563,"./lv":61057,"./lv.js":61057,"./me":96495,"./me.js":96495,"./mi":83096,"./mi.js":83096,"./mk":43874,"./mk.js":43874,"./ml":46055,"./ml.js":46055,"./mn":87747,"./mn.js":87747,"./mr":17113,"./mr.js":17113,"./ms":8687,"./ms-my":7948,"./ms-my.js":7948,"./ms.js":8687,"./mt":14532,"./mt.js":14532,"./my":4655,"./my.js":4655,"./nb":56961,"./nb.js":56961,"./ne":2512,"./ne.js":2512,"./nl":48448,"./nl-be":72936,"./nl-be.js":72936,"./nl.js":48448,"./nn":49031,"./nn.js":49031,"./oc-lnc":5174,"./oc-lnc.js":5174,"./pa-in":30118,"./pa-in.js":30118,"./pl":93448,"./pl.js":93448,"./pt":33518,"./pt-br":62447,"./pt-br.js":62447,"./pt.js":33518,"./ro":70817,"./ro.js":70817,"./ru":10262,"./ru.js":10262,"./sd":58990,"./sd.js":58990,"./se":43842,"./se.js":43842,"./si":37711,"./si.js":37711,"./sk":80756,"./sk.js":80756,"./sl":3772,"./sl.js":3772,"./sq":6187,"./sq.js":6187,"./sr":40732,"./sr-cyrl":75713,"./sr-cyrl.js":75713,"./sr.js":40732,"./ss":99455,"./ss.js":99455,"./sv":69770,"./sv.js":69770,"./sw":80959,"./sw.js":80959,"./ta":36459,"./ta.js":36459,"./te":25302,"./te.js":25302,"./tet":67975,"./tet.js":67975,"./tg":71294,"./tg.js":71294,"./th":2385,"./th.js":2385,"./tk":24613,"./tk.js":24613,"./tl-ph":58668,"./tl-ph.js":58668,"./tlh":58190,"./tlh.js":58190,"./tr":74506,"./tr.js":74506,"./tzl":63440,"./tzl.js":63440,"./tzm":69852,"./tzm-latn":42350,"./tzm-latn.js":42350,"./tzm.js":69852,"./ug-cn":70730,"./ug-cn.js":70730,"./uk":40099,"./uk.js":40099,"./ur":72100,"./ur.js":72100,"./uz":96002,"./uz-latn":26322,"./uz-latn.js":26322,"./uz.js":96002,"./vi":14207,"./vi.js":14207,"./x-pseudo":24674,"./x-pseudo.js":24674,"./yo":10570,"./yo.js":10570,"./zh-cn":73644,"./zh-cn.js":73644,"./zh-hk":22591,"./zh-hk.js":22591,"./zh-mo":89503,"./zh-mo.js":89503,"./zh-tw":88080,"./zh-tw.js":88080};function i(e){var t=n(e);return s(t)}function n(e){if(!s.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}i.keys=function(){return Object.keys(a)},i.resolve=n,e.exports=i,i.id=46700},40881:function(e,t,s){"use strict";s.d(t,{$t:function(){return Qi}});var a=s(49242),i=s(74973);async function n(){const e=await s.e(3657).then(s.t.bind(s,33657,23));e.load({google:{families:["Roboto:100,300,400,500,700,900&display=swap"]}})}var l=s(38685),o=(s(29773),(0,l.Rd)()),r=s(73752),d=s.n(r),c=s(73396),u=s(97718),h=s(29271);function m(e,t,s,a,i,n){const l=(0,c.up)("router-view"),o=(0,c.up)("Z-team-modal"),r=(0,c.up)("Z-delete-team-modal"),d=(0,c.up)("Z-task-modal"),m=(0,c.up)("Z-delete-task-modal"),p=(0,c.up)("Z-complete-task-modal"),v=(0,c.up)("Z-task-add-time-modal"),g=(0,c.up)("Z-blocker-modal"),w=(0,c.up)("Z-master-task-modal");return(0,c.wg)(),(0,c.iD)(c.HY,null,[(0,c.Wm)(u.q,null,{default:(0,c.w5)((()=>[(0,c.Wm)(h.O,null,{default:(0,c.w5)((()=>[(0,c.Wm)(l)])),_:1})])),_:1}),(0,c.Wm)(o,{ref:"z-team-modal",onUpdate:n.onTeamUpdate},null,8,["onUpdate"]),(0,c.Wm)(r,{ref:"z-delete-team-modal",onUpdate:n.onTeamUpdate},null,8,["onUpdate"]),(0,c.Wm)(d,{ref:"z-task-modal"},null,512),(0,c.Wm)(m,{ref:"z-delete-task-modal",onUpdate:n.onTaskDeleted},null,8,["onUpdate"]),(0,c.Wm)(p,{ref:"z-complete-task-modal"},null,512),(0,c.Wm)(v,{ref:"z-task-add-time-modal"},null,512),(0,c.Wm)(g,{ref:"z-blocker-modal"},null,512),(0,c.Wm)(w,{ref:"z-master-task-modal"},null,512)],64)}var p=s(87139),v=s(67312),g=s(70251),w=s(91334),f=s(33601),y=s(53289);const _={class:"d-flex justify-space-between align-center"};function k(e,t,s,i,n,l){return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:n.visible,"onUpdate:modelValue":t[3]||(t[3]=e=>n.visible=e),"max-width":"650"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,null,{default:(0,c.w5)((()=>[(0,c._)("div",_,[(0,c._)("h1",null,[(0,c.Uk)(" Ste si istý, že chcete zmazať tím "),(0,c._)("b",null,(0,p.zw)(n.team.name),1),(0,c.Uk)("? ")]),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>l.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"mt-10 d-flex justify-start align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(v.T,{class:"button primary half",variant:"flat",onClick:t[1]||(t[1]=e=>l.deleteTeam())},{default:(0,c.w5)((()=>[(0,c.Uk)("ÁNO")])),_:1}),(0,c.Wm)(v.T,{class:"button primary half outline",onClick:t[2]||(t[2]=(0,a.iM)((e=>l.closeModal()),["stop"]))},{default:(0,c.w5)((()=>[(0,c.Uk)("ZRUŠIŤ")])),_:1})])),_:1})])),_:1})])),_:1},8,["modelValue"])}var D={emits:["update"],data(){return{visible:!1,team:null}},methods:{async showModal(e){this.team=e,this.visible=!0},closeModal(){this.visible=!1},async deleteTeam(){try{await this.$axios.delete_auth(`v1/teams/${this.team.id}`),this.visible=!1,this.$emit("update",this.team)}catch(e){this.$toast.error(e)}}}},b=s(40089);const T=(0,b.Z)(D,[["render",k]]);var M=T,C=s(45869);const j={class:"d-flex justify-space-between align-center modal-header"};function E(e,t,s,i,n,l){const o=(0,c.up)("Z-autocomplete"),r=(0,c.up)("W-loadable");return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:n.visible,"onUpdate:modelValue":t[3]||(t[3]=e=>n.visible=e),"max-width":"650","max-height":"90%",height:"700px"},{default:(0,c.w5)((()=>[(0,c.Wm)(r,{content:n.team&&n.allEmployees,class:"h-100"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,{height:"100%",class:"d-flex flex-column"},{default:(0,c.w5)((()=>[(0,c._)("div",j,[(0,c._)("h1",null,(0,p.zw)(n.team.id?"Upraviť tím":"Vytvoriť tím"),1),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>l.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{class:(0,p.C_)(["modal-input",{error:n.v$.team.name.$errors.length}]),label:"Názov tímu",variant:"solo",hint:n.v$.team.name.$errors?n.errorUtils.parseErrors(n.v$.team.name.$errors):null,modelValue:n.team.name,"onUpdate:modelValue":t[1]||(t[1]=e=>n.team.name=e)},null,8,["class","hint","modelValue"]),((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(n.team.employees,((e,t)=>((0,c.wg)(),(0,c.iD)("div",{class:"relative w-100",key:e.id},[(0,c.Wm)(C.hw,{class:"modal-input",disabled:"",label:"Zamestanec",variant:"solo",modelValue:n.team.employees[t]._fullName,"onUpdate:modelValue":e=>n.team.employees[t]._fullName=e},null,8,["modelValue","onUpdate:modelValue"]),(0,c.Wm)(y.t,{class:"remove-input",onClick:(0,a.iM)((e=>n.team.employees.splice(t,1)),["stop"]),icon:"mdi-close",size:"small"},null,8,["onClick"])])))),128)),(0,c.Wm)(o,{options:l.employeesOptions,validations:n.v$.team.employees,class:"modal-input",onOptionSelected:l.employeeSelected},null,8,["options","validations","onOptionSelected"])])),_:1}),(0,c.Wm)(v.T,{class:"button primary block",onClick:t[2]||(t[2]=e=>l.save())},{default:(0,c.w5)((()=>[(0,c.Uk)((0,p.zw)(n.team.id?"UPRAVIŤ":"VYTVORIŤ"),1)])),_:1})])),_:1})])),_:1},8,["content"])])),_:1},8,["modelValue"])}s(57658);const W={class:"wrapper"},x={key:0,class:"suggestion"},$={class:"hidden-part"};function S(e,t,s,i,n,l){return(0,c.wg)(),(0,c.iD)("div",W,[(0,c.Wm)(C.hw,{label:"Vyhľadať zamestnanca",variant:"solo",modelValue:n.search,"onUpdate:modelValue":t[0]||(t[0]=e=>n.search=e),onKeydown:t[1]||(t[1]=(0,a.D2)((e=>l.optionSelected()),["enter"])),class:(0,p.C_)({error:s.validations?.$errors?.length}),hint:s.validations?.$errors?n.errorUtils.parseErrors(s.validations?.$errors):null},null,8,["modelValue","class","hint"]),l.suggestion?((0,c.wg)(),(0,c.iD)("div",x,[(0,c._)("span",$,(0,p.zw)(l.suggestion._suggestionHiddenPart),1),(0,c._)("span",null,(0,p.zw)(l.suggestion._suggestionShownPart),1)])):(0,c.kq)("",!0)])}var O=s(7648),V={emits:["option-selected"],props:{options:{type:Array,required:!0},validations:{type:Object||null,required:!1}},data(){return{errorUtils:O.Z,search:""}},computed:{suggestion(){const e=this._normalize(this.search);if(!e.length||!this.options.length)return null;const t=this.options.filter((t=>{const s=this._normalize(t.value);return e==s.slice(0,e.length)}));if(!t[0])return null;const s={...t[0],_suggestionHiddenPart:t[0].value.slice(0,e.length),_suggestionShownPart:t[0].value.slice(e.length,t[0].value.length)};return s}},methods:{optionSelected(){this.suggestion&&(this.$emit("option-selected",this.suggestion),this.search="")},_normalize(e){return e.trim().toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"")}}};const z=(0,b.Z)(V,[["render",S],["__scopeId","data-v-2aea25fa"]]);var H=z,A=s(33053),U=s(69117),L=s(36797),F=s.n(L),P={enrichEmployeesByFullName(e){return e.map((e=>({...e,_fullName:`${e.name} ${e.surname}`})))},formatDateTime(e){return F()(e).format("DD.MM.yyyy, HH:mm")},isBefore(e,t=null){return F()(e).isBefore(F()(t))},isAfter(e,t=null){return F()(e).isAfter(F()(t))}},I=s(34311);const Z=e=>e.length;var Y={emits:["close","update"],components:{ZAutocomplete:H},data(){return{visible:!1,allEmployees:null,v$:(0,A.ZP)(),errorUtils:O.Z,team:null}},validations(){return{team:{name:{required:U.C1},employees:{atLeastOne:Z}}}},methods:{async showModal(e=null){this.visible=!0,this.team=null;try{const t=await this.$axios.get_auth_data("v1/employees");if(this.allEmployees=P.enrichEmployeesByFullName(t),e?.id){const t=await this.$axios.get_auth_data(`v1/teams/${e.id}`);this.team={...t,employees:P.enrichEmployeesByFullName(t.employees)}}else this.team={employees:[]}}catch(t){this.$toast.error(t)}},closeModal(){this.visible=!1,this.$emit("close",this.team)},async save(){if(await this.v$.$validate())try{this.team.id?await I.Z.put(`v1/teams/${this.team.id}`,{data:this.team}):await this.$axios.post_auth_data("v1/teams",this.team),this.$emit("update",this.team),this.closeModal()}catch(e){this.$toast.error(e)}},employeeSelected(e){const t=this.allEmployees.find((t=>t.id==e.key));this.team.employees.push(t)}},computed:{employeesOptions(){const e=this.team.employees.map((e=>e.id)),t=this.allEmployees.filter((t=>!e.includes(t.id)));return t.map((e=>({key:e.id,value:`${e.name} ${e.surname}`})))}}};const N=(0,b.Z)(Y,[["render",E]]);var B=N;const q={class:"d-flex justify-space-between align-center"};function R(e,t,s,i,n,l){return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:n.visible,"onUpdate:modelValue":t[3]||(t[3]=e=>n.visible=e),"max-width":"650"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,null,{default:(0,c.w5)((()=>[(0,c._)("div",q,[(0,c._)("h1",null,[(0,c.Uk)("Ste si istý, že chcete zmazať "),(0,c._)("b",null,(0,p.zw)(n.task.title),1),(0,c.Uk)("?")]),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>l.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"mt-10 d-flex justify-start align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(v.T,{class:"button primary half",variant:"flat",onClick:t[1]||(t[1]=e=>l.deleteTask())},{default:(0,c.w5)((()=>[(0,c.Uk)("ÁNO")])),_:1}),(0,c.Wm)(v.T,{class:"button primary half outline",onClick:t[2]||(t[2]=(0,a.iM)((e=>l.closeModal()),["stop"]))},{default:(0,c.w5)((()=>[(0,c.Uk)("ZRUŠIŤ")])),_:1})])),_:1})])),_:1})])),_:1},8,["modelValue"])}var K={emits:["deleted"],data(){return{visible:!1,task:null}},methods:{async showModal(e){this.task=e,this.visible=!0},closeModal(){this.visible=!1},async deleteTask(){try{await this.$axios.delete(`v1/tasks/${this.task.id}`),this.$emit("deleted",this.task),this.closeModal()}catch(e){this.$toast.error(e)}}}};const G=(0,b.Z)(K,[["render",R]]);var X=G,J=s(87103),Q=s(16824),ee=s(68521),te=s(41583),se=s(74286);const ae=e=>((0,c.dD)("data-v-67b91079"),e=e(),(0,c.Cn)(),e),ie={class:"d-flex justify-space-between align-center modal-header"},ne={class:"w-100 modal-input"},le={class:"d-flex justify-space-between align-center"},oe={class:"d-flex justify-space-between align-center modal-header border-bottom pb-4"},re={class:"d-flex justify-start"},de=["src"],ce=["src"],ue={class:"w-100"},he={class:"d-flex align-center"},me=ae((()=>(0,c._)("p",{class:"mx-3"},"Mastertask",-1))),pe={class:"task-badge px-4 py-2 rounded-pill"},ve={class:"d-flex align-center"},ge=ae((()=>(0,c._)("p",{class:"mx-3"},"Status",-1))),we={key:0,class:"status-badge px-4 py-2 rounded-pill"},fe={key:1,class:"status-badge px-4 py-2 rounded-pill"},ye={class:"d-flex align-center"},_e=ae((()=>(0,c._)("p",{class:"mx-3"},"Trvanie",-1))),ke=["innerHTML"],De={class:"d-flex align-center"},be=ae((()=>(0,c._)("p",{class:"mx-3"},"Priradený",-1))),Te={class:"employee-selected-avatar d-flex justify-center align-center"},Me=["innerHTML"],Ce={class:"d-flex align-center"},je=ae((()=>(0,c._)("p",{class:"mx-3"},"Naplánovaný čas",-1))),Ee={class:"d-flex align-center"},We=ae((()=>(0,c._)("p",{class:"mx-3"},"Odpracovaný čas",-1))),xe={class:"d-flex align-center"},$e=ae((()=>(0,c._)("p",{class:"mx-3"},"Zostávajúci čas",-1))),Se={class:"px-5 py-5 border-bottom"},Oe=ae((()=>(0,c._)("p",null,"Popis zadania",-1))),Ve=["innerHTML"],ze=ae((()=>(0,c._)("p",{class:"mt-5"},"Prílohy",-1))),He={class:"w-100 d-flex align-center"},Ae={class:"d-flex justify-start align-center mt-8"};function Ue(e,t,i,n,l,o){const r=(0,c.up)("Datepicker"),d=(0,c.up)("QuillEditor"),u=(0,c.up)("Z-files-upload"),h=(0,c.up)("W-loadable");return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:l.visible,"onUpdate:modelValue":t[15]||(t[15]=e=>l.visible=e),"max-width":"650","max-height":"90%",height:"700px"},{default:(0,c.w5)((()=>[(0,c.Wm)(h,{content:l.task,class:"h-100"},{default:(0,c.w5)((()=>[l.editMode?((0,c.wg)(),(0,c.j4)(g._,{key:0,height:"100%",class:"d-flex flex-column scrolling"},{default:(0,c.w5)((()=>[(0,c._)("div",ie,[(0,c._)("h1",null,(0,p.zw)(l.task.id?"Upraviť task":"Vytvoriť task"),1),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>o.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{modelValue:l.task.project_code,"onUpdate:modelValue":t[1]||(t[1]=e=>l.task.project_code=e),onFocus:e.onInputFocus,class:"modal-input",label:"Kód projektu",variant:"solo",disabled:""},null,8,["modelValue","onFocus"]),(0,c.Wm)(te.r,{modelValue:l.masterTaskIdSelect,"onUpdate:modelValue":t[2]||(t[2]=e=>l.masterTaskIdSelect=e),onFocus:e.onInputFocus,class:"modal-input border-select",label:"MasterTask",variant:"solo",items:l.masterTasks,"item-value":"id","item-title":"name"},null,8,["modelValue","onFocus","items"]),(0,c.Wm)(te.r,{modelValue:l.employeeIdSelect,"onUpdate:modelValue":t[3]||(t[3]=e=>l.employeeIdSelect=e),onFocus:e.onInputFocus,class:"modal-input border-select",label:"Priradený",variant:"solo",items:o.employees,"item-value":"id","item-title":"_fullName"},null,8,["modelValue","onFocus","items"]),(0,c.Wm)(r,{class:(0,p.C_)(["modal-input mb-5",{error:l.v$.task.date.$errors.length}]),modelValue:l.task.date,"onUpdate:modelValue":t[4]||(t[4]=e=>l.task.date=e),format:"dd.MM.yyyy, HH:mm",locale:"sk",onFocus:e.onDateFocus,validations:l.v$.task.date,"select-text":"Vybrať","cancel-text":"Zrušiť",placeholder:"Trvanie od - do",range:""},null,8,["modelValue","class","onFocus","validations"]),(0,c.Wm)(C.hw,{modelValue:l.task.duration,"onUpdate:modelValue":t[5]||(t[5]=e=>l.task.duration=e),onFocus:e.onInputFocus,class:(0,p.C_)(["modal-input",{error:l.v$.task.duration.$errors.length}]),variant:"solo",type:"number",label:"Časový odhad",hint:l.v$.task.duration.$errors?l.errorUtils.parseErrors(l.v$.task.duration.$errors):null,"append-inner-icon":"mdi-clock-outline"},null,8,["modelValue","onFocus","class","hint"]),(0,c._)("div",ne,[(0,c.Wm)(d,{modelValue:l.task.description,"onUpdate:modelValue":t[6]||(t[6]=e=>l.task.description=e),placeholder:"Popis",theme:"snow",class:"rich-text-editor"},null,8,["modelValue"])]),(0,c.Wm)(u,{class:"mt-15 files",onFilesUploaded:o.filesUploaded},null,8,["onFilesUploaded"])])),_:1}),(0,c.Wm)(v.T,{class:"button primary",onClick:t[7]||(t[7]=e=>o.save())},{default:(0,c.w5)((()=>[(0,c.Uk)((0,p.zw)(l.task.id?"UPRAVIŤ":"VYTVORIŤ"),1)])),_:1})])),_:1})):((0,c.wg)(),(0,c.j4)(g._,{key:1,height:"100%",class:"d-flex flex-column scrolling"},{default:(0,c.w5)((()=>[(0,c._)("div",le,[(0,c._)("p",null,(0,p.zw)(l.task.project_code),1),(0,c.Wm)(y.t,{onClick:t[8]||(t[8]=(0,a.iM)((e=>o.closeModal()),["stop"])),icon:"mdi-close",size:"large",class:"pb-5"})]),(0,c._)("div",oe,[(0,c._)("h1",null,(0,p.zw)(l.task.title),1),(0,c._)("div",re,[(0,c._)("img",{class:"pencil-icon",src:s(75877),alt:"pencil-icon",onClick:t[9]||(t[9]=(0,a.iM)((e=>l.editMode=!l.editMode),["stop"]))},null,8,de),(0,c._)("img",{class:"trash-icon",src:s(79981),alt:"trash-icon",onClick:t[10]||(t[10]=(0,a.iM)((e=>o.openDeleteTaskModal(l.task)),["stop"]))},null,8,ce)])]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c._)("div",ue,[(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",he,[(0,c.Wm)(y.t,{icon:"mdi-link",size:"large"}),me])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",pe,(0,p.zw)(l.task.master_task.name),1)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",ve,[(0,c.Wm)(y.t,{icon:"mdi-drag-vertical",size:"large"}),ge])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[l.task.is_finished?((0,c.wg)(),(0,c.iD)("p",we," Ukončený ")):(0,c.kq)("",!0),l.task.is_finished?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("p",fe," Neukončený "))])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",ye,[(0,c.Wm)(y.t,{icon:"mdi-calendar-week",size:"large"}),_e])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{innerHTML:`${l.tmUtils.formatDateTime(l.task.starts_at)} - ${l.tmUtils.formatDateTime(l.task.ends_at)}`},null,8,ke)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",De,[(0,c.Wm)(y.t,{icon:"mdi-account-outline",size:"large"}),be])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2 d-flex align-center"},{default:(0,c.w5)((()=>[(0,c._)("p",Te,(0,p.zw)(l.task.employee.name.charAt(0)+l.task.employee.surname.charAt(0)),1),(0,c._)("p",{class:"ml-2",innerHTML:`${l.task.employee.name} ${l.task.employee.surname}`},null,8,Me)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",Ce,[(0,c.Wm)(y.t,{icon:"mdi-clock-time-three-outline",size:"large"}),je])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",null,(0,p.zw)(l.task.duration/3600)+" h",1)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",Ee,[(0,c.Wm)(y.t,{icon:"mdi-timer-outline",size:"large"}),We])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{modelValue:l.task.spent_time,"onUpdate:modelValue":t[11]||(t[11]=e=>l.task.spent_time=e),class:"modal-input",variant:"solo",type:"number",placeholder:"h"},null,8,["modelValue"])])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center border-bottom"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",xe,[(0,c.Wm)(y.t,{icon:"mdi-clock-time-three-outline",size:"large"}),$e])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",null,(0,p.zw)((l.task.duration-l.task.spent_time)/3600)+" h ",1)])),_:1})])),_:1})])),_:1}),(0,c._)("div",Se,[Oe,(0,c._)("section",{innerHTML:l.task.description,class:"description-detail px-2 py-2 w-100 rounded mt-2"},null,8,Ve),ze,(0,c._)("div",He,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.task.files,((s,a)=>((0,c.wg)(),(0,c.iD)("div",{key:s.id,class:(0,p.C_)(["d-flex align-center flex-wrap",[0===a?"ml-0":"ml-2"]])},[(0,c.Wm)(J.v,{class:"mt-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{onClick:t[12]||(t[12]=(...t)=>e.downloadFile&&e.downloadFile(...t)),class:"cursor-pointer"},(0,p.zw)(s.name),1),(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-paperclip"})])),_:2},1024)],2)))),128))])]),(0,c._)("div",Ae,[(0,c.Wm)(v.T,{class:"done-btn",onClick:t[13]||(t[13]=(0,a.iM)((e=>{l.task.is_finished=1,o.save()}),["stop"]))},{default:(0,c.w5)((()=>[(0,c.Uk)("Dokončené")])),_:1}),(0,c.Wm)(v.T,{class:"button secondary",onClick:t[14]||(t[14]=e=>o.save())},{default:(0,c.w5)((()=>[(0,c.Uk)("Uložiť zmeny")])),_:1})])])])),_:1})])),_:1}))])),_:1},8,["content"])])),_:1},8,["modelValue"])}var Le=s(86295);const Fe={class:"w-100 d-flex align-center"},Pe={key:0,class:"m-2 d-flex align-center flex-wrap"};function Ie(e,t,s,i,n,l){return(0,c.wg)(),(0,c.iD)("div",Fe,[(0,c._)("input",{type:"file",multiple:"",name:"file",id:"fileInput",class:"hidden-input",accept:"*",onChange:t[0]||(t[0]=(...e)=>l.onChange&&l.onChange(...e)),ref:"fileUpload"},null,544),(0,c.Wm)(v.T,{class:"upload-btn",onClick:t[1]||(t[1]=t=>e.$refs.fileUpload.click())},{default:(0,c.w5)((()=>[(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-cloud-upload-outline"}),(0,c.Uk)("NAHRAŤ ")])),_:1}),n.files.length?((0,c.wg)(),(0,c.iD)("div",Pe,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(n.files,(e=>((0,c.wg)(),(0,c.iD)("div",{key:e.name,class:"mx-2"},[(0,c.Wm)(J.v,{class:"mt-2"},{default:(0,c.w5)((()=>[(0,c.Uk)((0,p.zw)(e.name)+" ",1),(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-paperclip"}),(0,c.Wm)(y.t,{size:"small",icon:"mdi-close",onClick:(0,a.iM)((t=>l.remove(n.files.indexOf(e))),["stop"])},null,8,["onClick"])])),_:2},1024)])))),128))])):(0,c.kq)("",!0)])}var Ze={emit:["files-uploaded"],data(){return{files:[]}},methods:{onChange(){this.files=[...this.files,...this.$refs.fileUpload.files],this.$emit("files-uploaded",this.files)},remove(e){this.files.splice(e,1)}}};const Ye=(0,b.Z)(Ze,[["render",Ie],["__scopeId","data-v-7c7dff18"]]);var Ne=Ye,Be=s(96149),qe={data(){return{preventInputFocus:!1}},methods:{onDateFocus(e){void 0==e&&(this.preventInputFocus=!0)},onInputFocus(e){this.preventInputFocus&&(e.target.blur(),this.preventInputFocus=!1)}}},Re=(s(66154),{emits:["close","refresh"],mixins:[qe],components:{Datepicker:Le.Z,ZFilesUpload:Ne,QuillEditor:Be.Bn},data(){return{tmUtils:P,editMode:!1,visible:!1,task:null,errorUtils:O.Z,v$:(0,A.ZP)(),preventInputFocus:!1,masterTasks:[],masterTaskIdSelect:null,employeeIdSelect:null}},computed:{employees(){return this.task?.master_task?.employees?P.enrichEmployeesByFullName(this.task.master_task.employees):[]}},validations(){return{task:{date:{required:U.C1},duration:{required:U.C1},employee:{required:U.C1}}}},mounted(){this.$events.on("on-task-deleted",(e=>{e?.id==this.task?.id&&this.closeModal()}))},methods:{async showModal(e,t=!1){this.visible=!0,this.task=null;try{if(this.masterTasks=await this.$axios.get_auth_data("v1/mastertasks"),e?.id){const t=await this.$axios.get_auth_data(`v1/tasks/${e.id}`);this.employeeIdSelect=t.employee.id,this.masterTaskIdSelect=t.master_task.id,this.task=t}else this.task={master_task:{}};this.editMode=t||!this.task.id}catch(s){this.$toast.error(s)}},closeModal(){this.visible=!1},async save(){if(await this.v$.$validate())try{this.task.id?await this.$axios.put_auth(`v1/mastertasks/${this.task.id}`,this.task):await this.$axios.post_auth("v1/mastertasks",this.task),this.closeModal()}catch(e){this.$toast.error(e)}},openDeleteTaskModal(e){this.$events.emit("show-delete-task-modal",{task:e})},filesUploaded(e){this.task.files=e}},watch:{masterTaskIdSelect(e){e&&this.task&&(this.task.master_task=this.masterTasks.find((t=>t.id==e)))},employeeIdSelect(e){e&&this.task&&(this.task.employee=this.task.master_task.employees.find((t=>t.id==e)))}}});const Ke=(0,b.Z)(Re,[["render",Ue],["__scopeId","data-v-67b91079"]]);var Ge=Ke;const Xe={class:"d-flex justify-space-between align-center"};function Je(e,t,s,i,n,l){return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:n.visible,"onUpdate:modelValue":t[3]||(t[3]=e=>n.visible=e),"max-width":"650"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,null,{default:(0,c.w5)((()=>[(0,c._)("div",Xe,[(0,c._)("h1",null,[(0,c.Uk)("Ste si istý, že chcete ukončiť "),(0,c._)("b",null,(0,p.zw)(n.task.title),1),(0,c.Uk)("?")]),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>n.visible=!1),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"mt-10 d-flex justify-start align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(v.T,{class:"button primary half",variant:"flat",onClick:t[1]||(t[1]=e=>l.complete())},{default:(0,c.w5)((()=>[(0,c.Uk)("ÁNO")])),_:1}),(0,c.Wm)(v.T,{class:"button primary half outline",onClick:t[2]||(t[2]=(0,a.iM)((e=>n.visible=!1),["stop"]))},{default:(0,c.w5)((()=>[(0,c.Uk)("ZRUŠIŤ")])),_:1})])),_:1})])),_:1})])),_:1},8,["modelValue"])}var Qe={emits:["close","task-completed"],data(){return{visible:!1,task:null}},methods:{async showModal(e){this.task=e,this.visible=!0},async complete(){try{const e={...this.task,is_finished:!0};await this.$axios.patch_auth(`v1/tasks/${this.task.id}`,e),this.visible=!1,this.$emit("task-completed",e)}catch(e){this.$toast.error(e)}}}};const et=(0,b.Z)(Qe,[["render",Je]]);var tt=et;const st=e=>((0,c.dD)("data-v-7812ca17"),e=e(),(0,c.Cn)(),e),at={class:"d-flex justify-space-between align-center"},it=st((()=>(0,c._)("h1",null,"Prosím zadajte odpracovaný čas",-1)));function nt(e,t,s,i,n,l){return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:l.show,"onUpdate:modelValue":t[1]||(t[1]=e=>l.show=e),"max-width":"650"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,null,{default:(0,c.w5)((()=>[(0,c._)("div",at,[it,(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>l.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"mt-10 d-flex justify-start align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{class:"modal-input",label:"Odpracovaný čas",variant:"solo",type:"number",placeholder:"h","append-inner-icon":"mdi-timer-outline"})])),_:1}),(0,c.Wm)(v.T,{class:"button primary mt-5"},{default:(0,c.w5)((()=>[(0,c.Uk)("Potvrdiť")])),_:1})])),_:1})])),_:1},8,["modelValue"])}var lt={emits:["close"],data(){return{visible:!1}},computed:{show:{get(){return this.visible},set(e){e||this.$emit("close")}}},methods:{showModal(){this.visible=!0},closeModal(){this.visible=!1,this.$emit("close",this.blocker),this.blocker=null}}};const ot=(0,b.Z)(lt,[["render",nt],["__scopeId","data-v-7812ca17"]]);var rt=ot;const dt={class:"d-flex justify-space-between align-center modal-header"};function ct(e,t,s,i,n,l){const o=(0,c.up)("Z-autocomplete"),r=(0,c.up)("Datepicker"),d=(0,c.up)("W-loadable");return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:n.visible,"onUpdate:modelValue":t[4]||(t[4]=e=>n.visible=e),"max-width":"650","max-height":"90%",height:"700px"},{default:(0,c.w5)((()=>[(0,c.Wm)(d,{content:n.blocker,class:"h-100"},{default:(0,c.w5)((()=>[(0,c.Wm)(g._,{height:"100%",class:"d-flex flex-column"},{default:(0,c.w5)((()=>[(0,c._)("div",dt,[(0,c._)("h1",null,(0,p.zw)(n.blocker.id?"Upraviť":"Vytvoriť")+" blocker",1),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>l.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{onFocus:e.onInputFocus,class:(0,p.C_)(["modal-input",{error:n.v$.blocker.name.$errors.length}]),label:"Názov blockeru",hint:n.v$.blocker.name.$errors?n.errorUtils.parseErrors(n.v$.blocker.name.$errors):null,modelValue:n.blocker.name,"onUpdate:modelValue":t[1]||(t[1]=e=>n.blocker.name=e),variant:"solo"},null,8,["onFocus","class","hint","modelValue"]),((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(n.blocker.employees,((e,t)=>((0,c.wg)(),(0,c.iD)("div",{class:"relative w-100",key:e.id},[(0,c.Wm)(C.hw,{class:"modal-input",disabled:"",label:"Zamestanec",variant:"outlined",modelValue:n.blocker.employees[t]._fullName,"onUpdate:modelValue":e=>n.blocker.employees[t]._fullName=e},null,8,["modelValue","onUpdate:modelValue"]),(0,c.Wm)(y.t,{class:"remove-input",onClick:(0,a.iM)((e=>n.blocker.employees.splice(t,1)),["stop"]),icon:"mdi-close",size:"small"},null,8,["onClick"])])))),128)),(0,c.Wm)(o,{options:l.employeesOptions,class:(0,p.C_)(["modal-input",{error:n.v$.blocker.employees.$errors.length}]),onOptionSelected:l.employeeSelected},null,8,["options","class","onOptionSelected"]),(0,c.Wm)(r,{class:(0,p.C_)(["modal-input",{error:n.v$.blocker.date.$errors.length}]),modelValue:n.blocker.date,"onUpdate:modelValue":t[2]||(t[2]=e=>n.blocker.date=e),format:"dd.MM.yyyy, HH:mm",locale:"sk",onFocus:e.onDateFocus,validations:n.v$.blocker.employees,"select-text":"Vybrať","cancel-text":"Zrušiť",placeholder:"Trvanie od - do",range:""},null,8,["modelValue","class","onFocus","validations"])])),_:1}),(0,c.Wm)(v.T,{class:"button primary",onClick:t[3]||(t[3]=e=>l.save())},{default:(0,c.w5)((()=>[(0,c.Uk)((0,p.zw)(n.blocker.id?"UPRAVIŤ":"VYTVORIŤ"),1)])),_:1})])),_:1})])),_:1},8,["content"])])),_:1},8,["modelValue"])}const ut=e=>e.length;var ht={mixins:[qe],emits:["close"],components:{ZAutocomplete:H,Datepicker:Le.Z},data(){return{visible:!1,employees:null,v$:(0,A.ZP)(),errorUtils:O.Z,blocker:null}},computed:{employeesOptions(){const e=this.blocker.employees.map((e=>e.id)),t=this.employees.filter((t=>!e.includes(t.id)));return t.map((e=>({key:e.id,value:`${e.name} ${e.surname}`})))}},validations(){return{blocker:{name:{required:U.C1},date:{required:U.C1},employees:{atLeastOne:ut}}}},methods:{async showModal(e=null){this.visible=!0,this.blocker=null;try{const t=await this.$axios.get_auth_data("v1/employees");if(this.employees=P.enrichEmployeesByFullName(t),e?.id){const t=await this.$axios.get_auth_data(`v1/blockers/${e.id}`);this.blocker={...t,employees:P.enrichEmployeesByFullName(t.employees)}}else this.blocker={employees:[]}}catch(t){this.$toast.error(t)}},employeeSelected(e){const t=this.employees.find((t=>t.id==e.key));this.blocker.employees.push(t)},async save(){if(await this.v$.$validate())try{this.blocker.id?await this.$axios.post_auth(`v1/blockers/${this.blocker.id}`,this.blocker):await this.$axios.post_auth("v1/blockers",this.blocker),this.closeModal()}catch(e){this.$toast(e)}},closeModal(){this.visible=!1,this.$emit("close",this.blocker)}}};const mt=(0,b.Z)(ht,[["render",ct]]);var pt=mt,vt=s(4413);const gt=e=>((0,c.dD)("data-v-3ded616e"),e=e(),(0,c.Cn)(),e),wt={class:"d-flex justify-space-between align-center modal-header"},ft={class:"employee-select-avatar d-flex justify-center align-center"},yt={class:"w-100 modal-input"},_t={class:"d-flex justify-space-between align-center"},kt={class:"d-flex justify-space-between align-center modal-header border-bottom pb-4"},Dt={class:"d-flex justify-start"},bt=["src"],Tt=["src"],Mt={class:"w-100"},Ct={class:"d-flex align-center"},jt=gt((()=>(0,c._)("p",{class:"mx-3"},"Status",-1))),Et={key:0,class:"status-badge px-4 py-2 rounded-pill"},Wt={key:1,class:"status-badge px-4 py-2 rounded-pill"},xt={class:"d-flex align-center"},$t=gt((()=>(0,c._)("p",{class:"mx-3"},"Deadline",-1))),St={class:"d-flex align-center"},Ot=gt((()=>(0,c._)("p",{class:"mx-3"},"Tím",-1))),Vt={class:"task-badge px-4 py-2 rounded-pill flex-shrink-0"},zt={class:"employee-selected-avatar d-flex justify-center align-center"},Ht=["innerHTML"],At={class:"d-flex align-center"},Ut=gt((()=>(0,c._)("p",{class:"mx-3"},"Naplánovaný čas",-1))),Lt={class:"d-flex align-center"},Ft=gt((()=>(0,c._)("p",{class:"mx-3"},"Odpracovaný čas",-1))),Pt={class:"d-flex align-center"},It=gt((()=>(0,c._)("p",{class:"mx-3"},"Zostávajúci čas",-1))),Zt={class:"px-5 py-5 border-bottom"},Yt=gt((()=>(0,c._)("p",null,"Popis zadania",-1))),Nt=["innerHTML"],Bt=gt((()=>(0,c._)("p",{class:"mt-5"},"Prílohy",-1))),qt={class:"w-100 d-flex align-center"},Rt={class:"d-flex justify-start align-center mt-8"},Kt={class:"px-5 py-5"},Gt={class:"w-25"},Xt={class:"d-flex align-center"},Jt={class:"employee-selected-avatar d-flex justify-center align-center"},Qt=["innerHTML"],es={class:"task-action"},ts={class:"d-flex justify-start"},ss=["src"],as=["src"],is=["src"],ns={class:"d-flex align-center"};function ls(e,t,i,n,l,o){const r=(0,c.up)("Datepicker"),d=(0,c.up)("Z-autocomplete"),u=(0,c.up)("QuillEditor"),h=(0,c.up)("Z-files-upload"),m=(0,c.up)("W-loadable");return(0,c.wg)(),(0,c.j4)(f.B,{modelValue:l.visible,"onUpdate:modelValue":t[14]||(t[14]=e=>l.visible=e),"max-width":"650","max-height":"90%",height:"700px"},{default:(0,c.w5)((()=>[(0,c.Wm)(m,{content:l.masterTask,class:"h-100"},{default:(0,c.w5)((()=>[l.editMode?((0,c.wg)(),(0,c.j4)(g._,{key:0,height:"100%",class:"d-flex flex-column scrolling"},{default:(0,c.w5)((()=>[(0,c._)("div",wt,[(0,c._)("h1",null,(0,p.zw)(l.masterTask?.id?"Upraviť master task":"Vytvoriť master task"),1),(0,c.Wm)(y.t,{onClick:t[0]||(t[0]=(0,a.iM)((e=>o.closeModal()),["stop"])),icon:"mdi-close",size:"large"})]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c.Wm)(C.hw,{modelValue:l.masterTask.project_code,"onUpdate:modelValue":t[1]||(t[1]=e=>l.masterTask.project_code=e),onFocus:e.onInputFocus,class:(0,p.C_)(["modal-input",{error:l.v$.masterTask.project_code.$errors.length}]),label:"Kód projektu",variant:"solo",hint:l.v$.masterTask.project_code.$errors?l.errorUtils.parseErrors(l.v$.masterTask.project_code.$errors):null},null,8,["modelValue","onFocus","class","hint"]),(0,c.Wm)(C.hw,{modelValue:l.masterTask.name,"onUpdate:modelValue":t[2]||(t[2]=e=>l.masterTask.name=e),onFocus:e.onInputFocus,class:(0,p.C_)(["modal-input",{error:l.v$.masterTask.name.$errors.length}]),label:"Názov mastertasku",variant:"solo",hint:l.v$.masterTask.name.$errors?l.errorUtils.parseErrors(l.v$.masterTask.name.$errors):null},null,8,["modelValue","onFocus","class","hint"]),(0,c.Wm)(r,{modelValue:l.masterTask.deadline,"onUpdate:modelValue":t[3]||(t[3]=e=>l.masterTask.deadline=e),onFocus:e.onDateFocus,class:(0,p.C_)(["modal-input",{error:l.v$.masterTask.deadline.$errors.length}]),format:"dd.MM.yyyy, HH:mm",locale:"sk","select-text":"Vybrať","cancel-text":"Zrušiť",placeholder:"Deadline"},null,8,["modelValue","onFocus","class"]),(0,c.Wm)(C.hw,{modelValue:l.masterTask.duration,"onUpdate:modelValue":t[4]||(t[4]=e=>l.masterTask.duration=e),onFocus:e.onInputFocus,class:"modal-input mt-5",variant:"solo",type:"number",value:o.totalHours,disabled:"",label:o.totalHours+" h"},null,8,["modelValue","onFocus","value","label"]),(0,c.Wm)(te.r,{modelValue:l.teamSelect,"onUpdate:modelValue":t[5]||(t[5]=e=>l.teamSelect=e),onFocus:e.onInputFocus,class:"modal-input border-select",label:"Tím",variant:"solo",items:l.teams,"item-value":"id","item-title":"name"},null,8,["modelValue","onFocus","items"]),((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.masterTask.employees,((t,s)=>((0,c.wg)(),(0,c.j4)(C.hw,{key:t.id,onFocus:e.onInputFocus,class:(0,p.C_)([{error:l.masterTask.employees[s].hours<0},"modal-input"]),label:`${t.name} ${t.surname}`,variant:"solo",placeholder:"h",modelValue:l.masterTask.employees[s].hours,"onUpdate:modelValue":e=>l.masterTask.employees[s].hours=e,type:"number",min:"1"},{default:(0,c.w5)((()=>[(0,c._)("p",ft,(0,p.zw)(t.name.charAt(0)+t.surname.charAt(0)),1)])),_:2},1032,["onFocus","class","label","modelValue","onUpdate:modelValue"])))),128)),l.showAddEmployeeInput?((0,c.wg)(),(0,c.j4)(d,{key:0,options:o.employeesOptions,validations:l.v$.masterTask.employees,class:(0,p.C_)([{error:l.v$.masterTask.employees.$errors.length},"modal-input"]),onOptionSelected:o.employeeSelected},null,8,["options","validations","class","onOptionSelected"])):(0,c.kq)("",!0),(0,c.Wm)(v.T,{class:"w-100 mb-5 button secondary",disabled:!l.masterTask.team?.id,onClick:t[6]||(t[6]=e=>l.showAddEmployeeInput=!0)},{default:(0,c.w5)((()=>[(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-plus"}),(0,c.Uk)("Pridať zamestnanca ")])),_:1},8,["disabled"]),(0,c._)("div",yt,[(0,c.Wm)(u,{modelValue:l.masterTask.description,"onUpdate:modelValue":t[7]||(t[7]=e=>l.masterTask.description=e),placeholder:"Popis",theme:"snow",class:"rich-text-editor"},null,8,["modelValue"])]),(0,c.Wm)(h,{class:"mt-15 files",onFilesUploaded:o.filesUploaded},null,8,["onFilesUploaded"])])),_:1}),(0,c.Wm)(v.T,{class:"button primary",onClick:t[8]||(t[8]=e=>o.save())},{default:(0,c.w5)((()=>[(0,c.Uk)("VYTVORIŤ")])),_:1})])),_:1})):((0,c.wg)(),(0,c.j4)(g._,{key:1,height:"100%",class:"d-flex flex-column scrolling"},{default:(0,c.w5)((()=>[(0,c._)("div",_t,[(0,c._)("p",null,(0,p.zw)(l.masterTask.project_code),1),(0,c.Wm)(y.t,{onClick:t[9]||(t[9]=(0,a.iM)((e=>o.closeModal()),["stop"])),icon:"mdi-close",size:"large",class:"pb-5"})]),(0,c._)("div",kt,[(0,c._)("h1",null,(0,p.zw)(l.masterTask.name),1),(0,c._)("div",Dt,[(0,c._)("img",{class:"pencil-icon",src:s(75877),alt:"pencil-icon",onClick:t[10]||(t[10]=(0,a.iM)((e=>l.editMode=!l.editMode),["stop"]))},null,8,bt),(0,c._)("img",{class:"trash-icon",src:s(79981),alt:"trash-icon",onClick:t[11]||(t[11]=(0,a.iM)((e=>o._delete()),["stop"]))},null,8,Tt)])]),(0,c.Wm)(w.h,{class:"d-flex flex-column modal-content"},{default:(0,c.w5)((()=>[(0,c._)("div",Mt,[(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",Ct,[(0,c.Wm)(y.t,{icon:"mdi-drag-vertical",size:"large"}),jt])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[l.masterTask.is_finished?((0,c.wg)(),(0,c.iD)("p",Et,"Ukončený")):(0,c.kq)("",!0),l.masterTask.is_finished?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("p",Wt,"Neukončený"))])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",xt,[(0,c.Wm)(y.t,{icon:"mdi-calendar-week",size:"large"}),$t])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{class:(0,p.C_)(""+(l.tmUtils.isAfter(l.masterTask.deadline)?"text-black":"text-red-darken-4"))},(0,p.zw)(l.tmUtils.formatDateTime(l.masterTask.deadline)),3)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",St,[(0,c.Wm)(y.t,{icon:"mdi-account-multiple-outline",size:"large"}),Ot])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2 d-flex scroll-employees"},{default:(0,c.w5)((()=>[(0,c._)("p",Vt,(0,p.zw)(l.masterTask.team),1),((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.masterTask.employees,((e,t)=>((0,c.wg)(),(0,c.iD)("div",{class:"d-flex align-center flex-shrink-0 mx-3",key:e.id},[(0,c._)("p",zt,(0,p.zw)(e.name.charAt(0)+e.surname.charAt(0)),1),(0,c._)("p",{class:"ml-2",innerHTML:`${l.masterTask.employees[t].name} ${l.masterTask.employees[t].surname}`},null,8,Ht)])))),128))])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",At,[(0,c.Wm)(y.t,{icon:"mdi-clock-time-three-outline",size:"large"}),Ut])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",null,(0,p.zw)(l.masterTask?.duration?.toFixed(2))+" h",1)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",Lt,[(0,c.Wm)(y.t,{icon:"mdi-timer-outline",size:"large"}),Ft])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{class:(0,p.C_)(l.masterTask.time_worked>l.masterTask.duration?"text-red-darken-4":"text-black")},(0,p.zw)(l.masterTask.time_worked?.toFixed(2))+" h",3)])),_:1})])),_:1})])),_:1}),(0,c.Wm)(Q.o,{"no-gutters":"",class:"align-center border-bottom"},{default:(0,c.w5)((()=>[(0,c.Wm)(ee.D,{cols:"5"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"pa-2 ma-2"},{default:(0,c.w5)((()=>[(0,c._)("div",Pt,[(0,c.Wm)(y.t,{icon:"mdi-clock-time-three-outline",size:"large"}),It])])),_:1})])),_:1}),(0,c.Wm)(ee.D,{cols:"7"},{default:(0,c.w5)((()=>[(0,c.Wm)(se.C,{class:"ma-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{class:(0,p.C_)(l.masterTask.time_worked>l.masterTask.duration?"text-red-darken-4":"text-black")},(0,p.zw)((l.masterTask.duration-l.masterTask.time_worked)?.toFixed(2))+" h",3)])),_:1})])),_:1})])),_:1}),(0,c._)("div",Zt,[Yt,(0,c._)("section",{innerHTML:l.masterTask.description,class:"description-detail px-2 py-2 w-100 rounded mt-2"},null,8,Nt),Bt,(0,c._)("div",qt,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.masterTask.files,((s,a)=>((0,c.wg)(),(0,c.iD)("div",{key:s.id,class:(0,p.C_)(["d-flex align-center flex-wrap",[0===a?"ml-0":"ml-2"]])},[(0,c.Wm)(J.v,{class:"mt-2"},{default:(0,c.w5)((()=>[(0,c._)("p",{onClick:t[12]||(t[12]=(...t)=>e.downloadFile&&e.downloadFile(...t)),class:"cursor-pointer"},(0,p.zw)(s.name),1),(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-paperclip"})])),_:2},1024)],2)))),128))])]),(0,c._)("div",Rt,[(0,c.Wm)(v.T,{class:"button primary",onClick:t[13]||(t[13]=e=>o.save())},{default:(0,c.w5)((()=>[(0,c.Uk)("Ukončiť mastertask")])),_:1})]),(0,c.Wm)(vt.Y,{class:"mt-7 mb-5"},{default:(0,c.w5)((()=>[(0,c._)("tbody",Kt,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.masterTask.employees,((e,t)=>((0,c.wg)(),(0,c.iD)("tr",{key:e.id},[(0,c._)("td",Gt,(0,p.zw)(l.masterTask.name),1),(0,c._)("td",Xt,[(0,c._)("p",Jt,(0,p.zw)(e.name.charAt(0)+e.surname.charAt(0)),1),(0,c._)("p",{class:"ml-2",innerHTML:`${l.masterTask.employees[t].name} ${l.masterTask.employees[t].surname}`},null,8,Qt)]),(0,c._)("td",es,[(0,c._)("div",ts,[(0,c._)("img",{class:"pencil-icon",src:s(47146),alt:"checkmark-icon",style:(0,p.j5)({opacity:.3})},null,12,ss),(0,c._)("img",{class:"pencil-icon ml-2",src:s(75877),alt:"pencil-icon",style:(0,p.j5)({opacity:.3})},null,12,as),(0,c._)("img",{class:"trash-icon",src:s(79981),alt:"trash-icon",style:(0,p.j5)({opacity:.3})},null,12,is)])])])))),128))])])),_:1}),(0,c._)("div",ns,[(0,c.Wm)(v.T,{class:"subtask-btn w-100"},{default:(0,c.w5)((()=>[(0,c.Wm)(y.t,{class:"mx-1",icon:"mdi-plus"}),(0,c.Uk)("Pridať Subtask")])),_:1})])])])),_:1})])),_:1}))])),_:1},8,["content"])])),_:1},8,["modelValue"])}var os=s(15941);const rs=e=>e.length;var ds={emits:["close"],mixins:[qe],components:{Datepicker:Le.Z,ZFilesUpload:Ne,ZAutocomplete:H,QuillEditor:Be.Bn},data(){return{tmUtils:P,editMode:!1,visible:!1,errorUtils:O.Z,v$:(0,A.ZP)(),teams:null,employees:null,employeeSelect:null,teamSelect:"",masterTask:null,showAddEmployeeInput:!1}},validations(){return{masterTask:{project_code:{required:U.C1},name:{required:U.C1},team:{required:U.C1},deadline:{required:U.C1},employees:{atLeastOne:rs}}}},methods:{itemSelected(e){os.log(e)},async showModal(e,t=!1){this.visible=!0,this.masterTask=null,this.teamSelect=null,this.employeeSelect=null;try{this.teams=await this.$axios.get_auth_data("v1/teams");const s=await this.$axios.get_auth_data("v1/employees");this.employees=P.enrichEmployeesByFullName(s),e?.id?(this.masterTask=await this.$axios.get_auth_data(`v1/mastertasks/${e.id}`),this.teamSelect=this.masterTask.team.id):this.masterTask={team:{},employees:[]},this.editMode=t||!this.masterTask.id}catch(s){this.$toast.error(s)}os.log(this.masterTask)},async save(){if(await this.v$.$validate())try{this.masterTask.id?await this.$axios.put_auth(`v1/mastertasks/${this.masterTask.id}`,this.masterTask):await this.$axios.post_auth("v1/mastertasks",this.masterTask),this.closeModal()}catch(e){this.$toast(e)}},closeModal(){this.visible=!1,this.$emit("close",this.masterTask)},async _delete(){},employeeSelected(e){const t=this.employees.find((t=>t.id==e.key));this.masterTask.employees.push(t),this.showAddEmployeeInput=!1},filesUploaded(e){this.masterTask.files=e}},computed:{totalHours(){let e=0;return this.masterTask.employees.forEach((function(t){t.hours>0&&(e+=parseFloat(t.hours))})),e||0},employeesOptions(){const e=this.masterTask.employees.map((e=>e.id)),t=this.employees.filter((t=>!e.includes(t.id)))||[];return t.map((e=>({key:e.id,value:`${e.name} ${e.surname}`})))}},watch:{teamSelect(e){e&&this.masterTask&&(this.masterTask.team=this.teams.find((t=>t.id==e)),this.masterTask.employees=this.masterTask.team.employees)},employeeSelect(e){if(!e||!this.masterTask)return;const t=this.employees.find((t=>t.id==e));this.masterTask.employees.push(t),this.$nextTick((()=>{this.employeeSelect=null,this.$el.activeElement.blur()}))}}};const cs=(0,b.Z)(ds,[["render",ls],["__scopeId","data-v-3ded616e"]]);var us=cs,hs={components:{ZDeleteTeamModal:M,ZTeamModal:B,ZDeleteTaskModal:X,ZTaskModal:Ge,ZMasterTaskModal:us,ZCompleteTaskModal:tt,ZTaskAddTimeModal:rt,ZBlockerModal:pt},mounted(){this.$events.on("show-delete-team-modal",(({team:e})=>{this.$refs["z-delete-team-modal"].showModal(e)})),this.$events.on("show-team-modal",(({team:e})=>{this.$refs["z-team-modal"].showModal(e)})),this.$events.on("show-delete-task-modal",(({task:e})=>{this.$refs["z-delete-task-modal"].showModal(e)})),this.$events.on("show-task-modal",(({task:e,editMode:t})=>{this.$refs["z-task-modal"].showModal(e,t)})),this.$events.on("show-master-task-modal",(({masterTask:e,editMode:t})=>{this.$refs["z-master-task-modal"].showModal(e,t)})),this.$events.on("show-complete-task-modal",(({task:e})=>{this.$refs["z-complete-task-modal"].showModal(e)})),this.$events.on("show-blocker-modal",(({blocker:e})=>{this.$refs["z-blocker-modal"].showModal(e)})),this.$events.on("show-task-add-time-modal",(({task:e})=>{this.$refs["z-task-add-time-modal"].showModal(e)}))},methods:{onTeamUpdate(e){this.$events.emit("on-team-deleted",e)},onTaskDeleted(e){this.$events.emit("on-task-deleted",e)}}};const ms=(0,b.Z)(hs,[["render",m]]);var ps=ms,vs=s(22483);const gs=[{path:"",redirect:"/auth"},{path:"/auth/",component:()=>s.e(3829).then(s.bind(s,43829)),children:[{path:"",redirect:"/auth/login"},{path:"/auth/login",name:"Login",component:()=>s.e(1927).then(s.bind(s,31927))},{path:"/auth/forgot-password",name:"Forgot password",component:()=>s.e(3791).then(s.bind(s,23791))},{path:"/auth/reset-password",name:"Reset password",component:()=>s.e(5880).then(s.bind(s,45880))}]},{path:"/app",component:()=>s.e(5024).then(s.bind(s,35024)),children:[{path:"",redirect:"/app/dashboard"},{path:"/app/dashboard",redirect:"/app/dashboard/tasks",children:[{path:"/app/dashboard/tasks",name:"Dashboard - Tasks",meta:{title:"Tasks"},component:()=>s.e(3455).then(s.bind(s,43455))},{path:"/app/dashboard/teams",name:"Dashboard - Teams",meta:{title:"Teams Overview"},component:()=>s.e(5360).then(s.bind(s,55360))},{path:"/app/dashboard/projects",name:"Dashboard - Projects",meta:{title:"Projects overview"},component:()=>s.e(7909).then(s.bind(s,7909))},{path:"/app/overview/unscheduled",name:"Overview - Unscheduled tasks",meta:{title:"Unscheduled tasks"},component:()=>s.e(4468).then(s.bind(s,24468))},{path:"/app/overview/ongoing",name:"Overview - Ongoing tasks",meta:{title:"Ongoing tasks"},component:()=>s.e(7855).then(s.bind(s,7855))},{path:"/app/overview/teams",name:"Overview - Teams",meta:{title:"Teams"},component:()=>s.e(2848).then(s.bind(s,32848))},{path:"/app/dashboard/user",name:"Dashboard - User",meta:{title:"Profile"},component:()=>s.e(4132).then(s.bind(s,54132))},{path:"/app/search",name:"Search",meta:{title:"Search Results"},component:()=>s.e(7209).then(s.bind(s,7209))},{path:"/app/testing",name:"Testing",meta:{title:"Testing"},component:()=>s.e(4931).then(s.bind(s,84931))}]}]},{path:"/:catchAll(.*)",name:"404",component:()=>s.e(188).then(s.bind(s,60188))}],ws=(0,vs.p7)({history:(0,vs.r5)("/"),routes:gs});var fs=ws,ys=s(20065),_s=(0,ys.MT)({state:{},getters:{},mutations:{},actions:{},modules:{}}),ks=s(15941);I.Z.defaults.baseURL="https://taskmanager.internal.studiotem.com/api/";var Ds={async get(e,t){return I.Z.get(e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async get_auth(e,t){return t=this._config(t),I.Z.get(e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async get_data(e,t){return I.Z.get(e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async get_auth_data(e,t){return t=this._config(t),I.Z.get(e,t).then((e=>Promise.resolve(e.data.data))).catch((e=>Promise.reject(e.response||e)))},async post(e,t=null,s){return I.Z.post(e,{data:t},s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async post_auth(e,t=null,s){return s=this._config(s),I.Z.post(e,{data:t},s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async post_data(e,t=null,s){return I.Z.post(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async post_auth_data(e,t=null,s){return s=this._config(s),I.Z.post(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async delete(e,t){return I.Z["delete"](e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async delete_auth(e,t){return t=this._config(t),I.Z["delete"](e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async delete_data(e,t){return I.Z["delete"](e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async delete_auth_data(e,t){return t=this._config(t),I.Z["delete"](e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async patch(e,t=null,s){return I.Z.patch(e,{data:t},s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async patch_auth(e,t=null,s){return s=this._config(s),I.Z.patch(e,{data:t},s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async patch_data(e,t=null,s){return I.Z.patch(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async patch_auth_data(e,t=null,s){return s=this._config(s),I.Z.patch(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async put(e,t=null,s){return I.Z.put(e,{data:t},s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async put_auth(e,t=null,s){return s=this._config(s),I.Z.put(e,t,s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async put_data(e,t=null,s){return I.Z.put(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async put_auth_data(e,t=null,s){return s=this._config(s),I.Z.put(e,{data:t},s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},_config(e){return e&&ks.error("NOT IMPLEMENTED"),_s.getters["auth/token"]?{headers:{Authorization:`Bearer ${_s.getters["auth/token"]}`}}:{headers:{}}}},bs={install:(e,t)=>{t&&!0===t.disabled||(e.config.globalProperties.$axios=Ds)}},Ts=s(82482);const Ms=e=>Object.entries(e).map((e=>e.map(encodeURIComponent).join("="))).join("&");function Cs(e){let t=e;return t=t.replace(/\//g,"\\/"),t=t.replace(/\./g,"\\."),t=t.replace(/\([^)]+\)/g,"[^/]+"),t}var js=s(15941);class Es{constructor(){(0,Ts.Z)(this,"_mocks",{}),I.Z.interceptors.request.use(this._redirectRequestToMock.bind(this)),this._mocks={}}mock(e){for(const t in e){let s=e[t];!1!==s&&(s={},s.name=t,s.url=t.split(" ")[1],s.reUrl||(s.reUrl=Cs(s.url)),s.matchMethod||(s.matchMethod=t.split(" ")[0].toLowerCase()),this._mocks[t]=s)}}_redirectRequestToMock(e){const t=e.url.replace(/https?:\/\/[^/?]+/,"");let s;for(const a in this._mocks){const i=this._mocks[a];if(e.method==i.matchMethod&&t.match(i.reUrl)){s=i;break}}if(s){s.fname||(s.fname={NODE_ENV:"production",VUE_APP_WAXIOS_URL:"https://taskmanager.internal.studiotem.com/api/",BASE_URL:"/"}.VUE_APP_PLATFORM?`/mock/${{NODE_ENV:"production",VUE_APP_WAXIOS_URL:"https://taskmanager.internal.studiotem.com/api/",BASE_URL:"/"}.VUE_APP_PLATFORM}/${s.url}.${e.method.toUpperCase()}.json`:`/mock/${s.url}.${e.method.toUpperCase()}.json`),js.log(s.fname=`/mock/${s.url}.${e.method.toUpperCase()}.json`);const t={method:"get",url:window.location.origin+s.fname+"?___MOCK___&"+Ms(e.data||{})};e={...e,...t}}return e}}var Ws={install:(e,t)=>{const s=new Es;t&&t.routes&&Object.values(t.routes).length&&!0!==t.disabled&&s.mock(t.routes)}},xs=s(8069),$s={install:(e,t)=>{if(t&&!0===t.disabled)return;const s=(0,xs.Z)();e.config.globalProperties.$events=s}},Ss=s(44870),Os=s(5658),Vs=s(31310),zs=s(15941);class Hs{constructor(e){(0,Ts.Z)(this,"currentLanguage",(0,Ss.iH)()),(0,Ts.Z)(this,"availableLanguages",void 0),(0,Ts.Z)(this,"vendorI18n",void 0),(0,Ts.Z)(this,"defaultLanguage",void 0),(0,Ts.Z)(this,"languageKey",void 0),(0,Ts.Z)(this,"_missingTranslation",((e,t,s,a)=>t)),(0,Ts.Z)(this,"_postTranslation",(e=>e)),this.availableLanguages=e.languages||[],this.defaultLanguage=e.languages.find((t=>t.value==e.defaultLanguage)),this.languageKey=e.languageKey||{NODE_ENV:"production",VUE_APP_WAXIOS_URL:"https://taskmanager.internal.studiotem.com/api/",BASE_URL:"/"}.VUE_APP_PLATFORM+"_language"||0,this.vendorI18n=(0,Os.o)({legacy:!0,fallbackLocale:this.defaultLanguage.value,messages:this._loadLocaleMessages(),missing:this._missingTranslation,postTranslation:this._postTranslation}),this.changeLanguage({title:"Slovenský",flag:"sk",value:"sk"}),this.initCurrentLanguage()}async initCurrentLanguage(){const{value:e}=await Vs.u.get({key:this.languageKey});if(e)this.currentLanguage.value=JSON.parse(e);else if(this.defaultLanguage)this.currentLanguage.value=this.defaultLanguage;else{if(!this.availableLanguages[0])return zs.error("[w18n] Could not init current language");this.currentLanguage.value=this.availableLanguages[0]}const t={};this.availableLanguages.forEach((e=>{t[e.value]=e.title})),this.changeLanguage(this.currentLanguage.value),this._addAxiosHeaders()}changeLanguage(e){this.currentLanguage.value=e,this._addAxiosHeaders(),Vs.u.set({key:this.languageKey,value:JSON.stringify(e)}),this.vendorI18n.global.locale=e.value}_addAxiosHeaders(){I.Z.interceptors.request.use((e=>(this.currentLanguage.value&&this.currentLanguage.value.value&&(e.headers["Accept-Language"]=this.currentLanguage.value.value),e)))}_loadLocaleMessages(e="@/locales"){let t;try{t=s(8973)}catch(i){return zs.warn("[@wezeo/i18n] Could not initialize i18n. Missing folder /src/locales."),{}}const a={};return t.keys().forEach((e=>{const s=e.match(/([A-Za-z0-9-_]+)\./i);if(s&&s.length>1){const i=s[1];a[i]=t(e)}})),a}}var As=s(15941),Us={install:(e,t)=>{if(t&&!0===t.disabled)return;if(!t||!t.languages||!t.defaultLanguage)return As.warn("[@wezeo/i18n] Could not initialize i18n. Missing configuration options.");e.config.globalProperties.$events||e.use($s);const s=new Hs(t);e.use(s.vendorI18n),e.config.globalProperties.$w18n=s}},Ls={install:(e,t)=>{t&&!0===t.disabled||(e.component("ion-content",i.W2),e.component("ion-page",i._i),e.component("ion-label",i.Q$),e.component("ion-back-button",i.oU),e.component("ion-checkbox",i.nz),e.component("ion-text",i.yW),e.component("ion-button",i.YG),e.component("ion-item",i.Ie),e.component("ion-item-group",i.Ub),e.component("ion-item-sliding",i.td),e.component("ion-item-option",i.u8),e.component("ion-item-options",i.IK),e.component("ion-toolbar",i.sr),e.component("ion-header",i.Gu),e.component("ion-footer",i.fr),e.component("ion-slides",i.Hr),e.component("ion-slide",i.A$),e.component("ion-spinner",i.PQ),e.component("ion-row",i.Nd),e.component("ion-col",i.wI),e.component("ion-grid",i.jY),e.component("ion-input",i.pK),e.component("ion-buttons",i.Sm),e.component("ion-icon",i.gu),e.component("ion-img",i.Xz),e.component("ion-list",i.q_),e.component("ion-skeleton-text",i.CK),e.component("ion-title",i.wd),e.component("ion-menu",i.z0),e.component("ion-split-pane",i.jI),e.component("ion-menu-button",i.fG),e.component("ion-router-outlet",i.jP),e.component("ion-segment",i.cJ),e.component("ion-segment-button",i.GO),e.component("ion-virtual-scroll",i.aJ),e.component("ion-textarea",i.g2),e.component("ion-searchbar",i.VI),e.component("ion-refresher-content",i.Wo),e.component("ion-refresher",i.nJ),e.component("ion-infinite-scroll-content",i.MB),e.component("ion-infinite-scroll",i.ju),e.component("ion-avatar",i.BJ),e.component("ion-thumbnail",i.Bs),e.component("ion-modal",i.ki),e.component("ion-radio-group",i.se),e.component("ion-radio",i.B7),e.component("ion-note",i.uN),e.component("ion-card",i.PM),e.component("ion-card-content",i.FN),e.component("ion-tab-bar",i.yq),e.component("ion-tab-button",i.ZU),e.component("ion-menu-toggle",i.zc),e.component("ion-fab",i.IJ),e.component("ion-fab-button",i.W4),e.component("ion-fab-list",i.zq),e.component("ion-reorder-group",i.oz),e.component("ion-reorder",i.Nh),e.component("ion-select",i.t9),e.component("ion-select-option",i.n0),e.component("ion-toggle",i.ho),e.component("ion-badge",i.yp),e.component("ion-chip",i.hM),e.component("ion-tabs",i.UN))}},Fs=s(30237),Ps=s.n(Fs);I.Z.interceptors.request.use((e=>(e.headers["Authorization"]=`Bearer ${_s.getters["user/token"]}`,e)));const Is=e=>_s.dispatch("user/refreshToken").then((t=>(e.response.config.headers.Authorization=`Bearer ${t}`,Promise.resolve())));Ps()(I.Z,Is);var Zs=s(15941),Ys={namespaced:!0,state:{token:localStorage.getItem("wzo_vue_user_token")||"",user:JSON.parse(localStorage.getItem("wzo_vue_user_user")||"{}")},mutations:{auth_success(e,t){t.token&&(e.token=t.token,localStorage.setItem("wzo_vue_user_token",t.token)),t.user&&(e.user=t.user,localStorage.setItem("wzo_vue_user_user",JSON.stringify(t.user)))},auth_error(e){e.token="",localStorage.removeItem("wzo_vue_user_token"),localStorage.removeItem("wzo_vue_user_user")},logout(e){e.token="",e.user=null,localStorage.removeItem("wzo_vue_user_token"),localStorage.removeItem("wzo_vue_user_user"),window.open(location.origin,"_self")}},actions:{login({commit:e},t){return new Promise(((s,a)=>{Ds.post_data("v1/auth/login",t).then((t=>{const a=t.token,i=t.user;e("auth_success",{token:a,user:i}),s(t)})).catch((t=>{e("auth_error"),a(t)}))}))},signup({commit:e},t){return new Promise(((s,a)=>{e("auth_request"),Ds.post_data("v1/auth/signup",t).then((t=>{const a=t.token,i=t.user;e("auth_success",{token:a,user:i}),s(t)})).catch((t=>{e("auth_error"),a(t)}))}))},logout({commit:e}){return new Promise((t=>{Ds.post_auth_data("v1/auth/invalidate").finally((()=>{e("logout"),t(null)}))}))},forgotPassword({commit:e},t){return new Promise(((e,s)=>{Ds.post_auth_data("v1/auth/forgot",t).then((t=>e(t))).catch((e=>s(e)))}))},resetPassword({commit:e},t){return new Promise(((e,s)=>{Ds.post_auth_data("v1/auth/reset",t).then((t=>e(t))).catch((e=>s(e)))}))},async refreshToken({commit:e}){try{const t=await Ds.post_auth_data("v1/auth/refresh"),s=t.token,a=t.user;return e("auth_success",{token:s,user:a}),s}catch(t){e("auth_error"),Zs.error(t)}},async userInfo({commit:e}){return new Promise(((t,s)=>{Ds.get_auth_data("v1/auth/info").then((s=>{const a=s.user;e("auth_success",{user:a}),t(a)})).catch((e=>{s(e)}))}))},updateUserInfo({commit:e},t){return new Promise(((s,a)=>{Ds.post_auth_data("v1/auth/info",t).then((t=>{const a=t.user;e("auth_success",{user:a}),s(a)})).catch((e=>{a(e)}))}))}},getters:{isLoggedIn:e=>!!e.token,user:e=>e.user,token:e=>e.token&&void 0!=e.token?e.token:null}},Ns=s(15941),Bs={install:(e,t)=>{if(!t||1!=t.disabled)return e.config.globalProperties.$store?void e.config.globalProperties.$store.registerModule("auth",Ys):Ns.warn("[w/auth] Could not initialize. App does not have vuex store added.")}},qs=s(46215),Rs=s.n(qs),Ks={install:(e,t)=>{t&&!0===t.disabled||e.use(Rs())}};const Gs={ref:"loadingContainer"},Xs={key:0},Js={key:1},Qs={key:2};function ea(e,t,s,a,i,n){return(0,c.wg)(),(0,c.iD)("div",Gs,[s.content?s.content.error?((0,c.wg)(),(0,c.iD)("div",Js,(0,p.zw)(s.content.error),1)):"array"==typeof s.content&&!e.array.length||"object"==typeof s.content&&!Object.values(s.content).length?((0,c.wg)(),(0,c.iD)("div",Qs,(0,p.zw)(s.emptyMessage),1)):(0,c.WI)(e.$slots,"default",{key:3},void 0,!0):((0,c.wg)(),(0,c.iD)("div",Xs))],512)}var ta={props:{content:{type:[Object,Array,Boolean],default:()=>null},emptyMessage:{type:String,default:"No items"}},data(){return{loader:null}},async created(){await this._startLoading()},methods:{async _startLoading(){this.loader=await this.$loading.show()},_stopLoading(){this.loader.hide()}},watch:{content(e){e?this._stopLoading():this._startLoading()}}};const sa=(0,b.Z)(ta,[["render",ea],["__scopeId","data-v-1d0dfe8d"]]);var aa=sa,ia={install:(e,t)=>{t&&!0===t.disabled||e.component("W-loadable",aa)}},na={install:(e,t={})=>{$s.install(e,t.events),bs.install(e,t.axios),Us.install(e,t.i18n),Ws.install(e,t.moxios),Ls.install(e,t.ionic),Bs.install(e,t.auth),Ks.install(e,t.toast),ia.install(e,t.loadable)}},la=s(15941);I.Z.defaults.baseURL="https://taskmanager.internal.studiotem.com/api/";var oa={async get(e,t){return I.Z.get(e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async get_auth(e,t){return t=this._config(t),I.Z.get(e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async get_data(e,t){return I.Z.get(e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async get_auth_data(e,t){return t=this._config(t),I.Z.get(e,t).then((e=>Promise.resolve(e.data.data))).catch((e=>Promise.reject(e.response||e)))},async post(e,t=null,s){return I.Z.post(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async post_auth(e,t=null,s){return s=this._config(s),I.Z.post(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async post_data(e,t=null,s){return I.Z.post(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async post_auth_data(e,t=null,s){return s=this._config(s),I.Z.post(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async delete(e,t){return I.Z["delete"](e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async delete_auth(e,t){return t=this._config(t),I.Z["delete"](e,t).then((e=>e.data)).catch((e=>Promise.reject(e)))},async delete_data(e,t){return I.Z["delete"](e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async delete_auth_data(e,t){return t=this._config(t),I.Z["delete"](e,t).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async patch(e,t=null,s){return I.Z.patch(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async patch_auth(e,t=null,s){return s=this._config(s),I.Z.patch(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async patch_data(e,t=null,s){return I.Z.patch(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async patch_auth_data(e,t=null,s){return s=this._config(s),I.Z.patch(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async put(e,t=null,s){return I.Z.put(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async put_auth(e,t=null,s){return s=this._config(s),I.Z.put(e,this._objectToFormData(t),s).then((e=>e.data)).catch((e=>Promise.reject(e)))},async put_data(e,t=null,s){return I.Z.put(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},async put_auth_data(e,t=null,s){return s=this._config(s),I.Z.put(e,this._objectToFormData(t),s).then((e=>e.data.data)).catch((e=>Promise.reject(e.response||e)))},_config(e){return e&&la.error("NOT IMPLEMENTED"),_s.getters["auth/token"]?{headers:{Authorization:`Bearer ${_s.getters["auth/token"]}`}}:{headers:{}}},_buildFormData(e,t,s){!t||"object"!==typeof t||t instanceof Date||t instanceof File?e.append(s,null==t?"":t):Object.keys(t).forEach((a=>this._buildFormData(e,t[a],s?`${s}[${a}]`:a)))},_objectToFormData(e){const t=new FormData;return this._buildFormData(t,{data:e}),t}},ra={install:(e,t)=>{t&&!0===t.disabled||(e.config.globalProperties.$axios=oa)}};const da=["lang"],ca={key:0,class:"vuecal__flex vuecal__body",grow:"grow"},ua=["onBlur","innerHTML"],ha=["innerHTML"],ma=["innerHTML"],pa={class:"vuecal__flex",row:"row",grow:"grow"},va={key:0,class:"vuecal__time-column"},ga=(0,c._)("span",{class:"vuecal__time-cell-line"},null,-1),wa={class:"vuecal__time-cell-label"},fa={key:1,class:"vuecal__flex vuecal__week-numbers",column:"column"},ya=["wrap","column"],_a=["onBlur","innerHTML"],ka=["innerHTML"],Da=["innerHTML"],ba=["wrap"],Ta=["innerHTML"],Ma=["innerHTML"],Ca={key:2,class:"vuecal__cell-events-count"},ja={key:3,class:"vuecal__no-event"},Ea=["onBlur","innerHTML"],Wa=["innerHTML"],xa={key:2,class:"vuecal__event-time"},$a={key:0},Sa={key:1,class:"days-to-end"},Oa=["innerHTML"],Va={key:0,class:"vuecal__scrollbar-check"},za=(0,c._)("div",null,null,-1),Ha=[za];function Aa(e,t,s,i,n,l){const o=(0,c.up)("vuecal-header"),r=(0,c.up)("all-day-bar"),d=(0,c.up)("weekdays-headings"),u=(0,c.up)("vuecal-cell");return(0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["vuecal__flex vuecal",l.cssClasses]),column:"column",ref:"vuecal",lang:s.locale},[(0,c.Wm)(o,{options:e.$props,"edit-events":l.editEvents,"view-props":{views:l.views,weekDaysInHeader:l.weekDaysInHeader},"week-days":l.weekDays,"has-splits":l.hasSplits,"day-splits":l.daySplits,"switch-to-narrower-view":l.switchToNarrowerView},(0,c.Nv)({_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,c.w5)((({heading:t,view:s})=>[(0,c.WI)(e.$slots,"weekday-heading",{heading:t,view:s})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,c.w5)((({split:t,view:s})=>[(0,c.WI)(e.$slots,"split-label",{split:t,view:s.id})])),key:"1"}:void 0]),1032,["options","edit-events","view-props","week-days","has-splits","day-splits","switch-to-narrower-view"]),s.hideBody?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",ca,[(0,c.Wm)(a.uT,{name:`slide-fade--${n.transitionDirection}`,appear:s.transitions},{default:(0,c.w5)((()=>[((0,c.wg)(),(0,c.iD)("div",{class:"vuecal__flex",style:{"min-width":"100%"},key:!!s.transitions&&n.view.id,column:"column"},[s.showAllDayEvents&&l.hasTimeColumn&&(!l.cellOrSplitMinWidth||l.isDayView&&!s.minSplitWidth)?((0,c.wg)(),(0,c.j4)(r,(0,p.vs)((0,c.dG)({key:0},l.allDayBar)),{event:(0,c.w5)((({event:t,view:s})=>[(0,c.WI)(e.$slots,"event",{view:s,event:t},(()=>[l.editEvents.title&&t.titleEditable?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"contenteditable",onBlur:e=>l.onEventTitleBlur(e,t),innerHTML:t.title},null,40,ua)):t.title?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__event-title",innerHTML:t.title},null,8,ha)):(0,c.kq)("",!0),!t.content||l.hasShortEvents||l.isShortMonthView?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",{key:2,class:"vuecal__event-content",innerHTML:t.content},null,8,ma))]))])),_:3},16)):(0,c.kq)("",!0),(0,c._)("div",{class:(0,p.C_)(["vuecal__bg",{vuecal__flex:!l.hasTimeColumn}]),column:"column",ref:"vuecal_scroll"},[(0,c._)("div",pa,[l.hasTimeColumn?((0,c.wg)(),(0,c.iD)("div",va,[s.showAllDayEvents&&l.cellOrSplitMinWidth&&(!l.isDayView||s.minSplitWidth)?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"vuecal__all-day-text",style:(0,p.j5)({height:l.allDayBar.height})},[(0,c._)("span",null,(0,p.zw)(n.texts.allDay),1)],4)):(0,c.kq)("",!0),((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.timeCells,((t,a)=>((0,c.wg)(),(0,c.iD)("div",{class:"vuecal__time-cell",key:a,style:(0,p.j5)(`height: ${s.timeCellHeight}px`)},[(0,c.WI)(e.$slots,"time-cell",{hours:t.hours,minutes:t.minutes},(()=>[ga,(0,c._)("span",wa,(0,p.zw)(t.label),1)]))],4)))),128))])):(0,c.kq)("",!0),s.showWeekNumbers&&l.isMonthView?((0,c.wg)(),(0,c.iD)("div",fa,[((0,c.wg)(),(0,c.iD)(c.HY,null,(0,c.Ko)(6,(t=>(0,c._)("div",{class:"vuecal__flex vuecal__week-number-cell",key:t,grow:"grow"},[(0,c.WI)(e.$slots,"week-number-cell",{week:l.getWeekNumber(t-1)},(()=>[(0,c.Uk)((0,p.zw)(l.getWeekNumber(t-1)),1)]))]))),64))])):(0,c.kq)("",!0),(0,c._)("div",{class:(0,p.C_)(["vuecal__flex vuecal__cells vuecal__scrollable-body",`${n.view.id}-view`]),grow:"grow",wrap:!l.cellOrSplitMinWidth||!l.isWeekView,column:!!l.cellOrSplitMinWidth},[l.cellOrSplitMinWidth&&l.isWeekView?((0,c.wg)(),(0,c.j4)(d,{key:0,"transition-direction":n.transitionDirection,"week-days":l.weekDays,"switch-to-narrower-view":l.switchToNarrowerView,style:(0,p.j5)(l.cellOrSplitMinWidth?`min-width: ${l.cellOrSplitMinWidth}px`:""),unscheduledTime:s.unscheduledTime,ref:"vuecal_weekday_heading"},(0,c.Nv)({_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,c.w5)((({heading:t,view:s})=>[(0,c.WI)(e.$slots,"weekday-heading",{heading:t,view:s})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,c.w5)((({split:t})=>[(0,c.WI)(e.$slots,"split-label",{split:t,view:n.view.id})])),key:"1"}:void 0]),1032,["transition-direction","week-days","switch-to-narrower-view","style","unscheduledTime"])):l.hasSplits&&s.stickySplitLabels&&s.minSplitWidth?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__flex vuecal__split-days-headers",ref:"vuecal_splits_heading",style:(0,p.j5)(l.cellOrSplitMinWidth?`min-width: ${l.cellOrSplitMinWidth}px`:"")},[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.daySplits,((t,s)=>((0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["day-split-header",t.class||!1]),key:s},[(0,c.WI)(e.$slots,"split-label",{split:t,view:n.view.id},(()=>[(0,c.Uk)((0,p.zw)(t.label),1)]))],2)))),128))],4)):(0,c.kq)("",!0),s.showAllDayEvents&&l.hasTimeColumn&&(l.isWeekView&&l.cellOrSplitMinWidth||l.isDayView&&l.hasSplits&&s.minSplitWidth)?((0,c.wg)(),(0,c.j4)(r,(0,p.vs)((0,c.dG)({key:2},l.allDayBar)),{event:(0,c.w5)((({event:t,view:s})=>[(0,c.WI)(e.$slots,"event",{view:s,event:t},(()=>[l.editEvents.title&&t.titleEditable?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"contenteditable",onBlur:e=>l.onEventTitleBlur(e,t),innerHTML:t.title},null,40,_a)):t.title?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__event-title",innerHTML:t.title},null,8,ka)):(0,c.kq)("",!0),!t.content||l.hasShortEvents||l.isShortMonthView?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",{key:2,class:"vuecal__event-content",innerHTML:t.content},null,8,Da))]))])),_:3},16)):(0,c.kq)("",!0),(0,c._)("div",{class:"vuecal__flex vuecal__cells-body",ref:e=>n.cellsEl=e,grow:"grow",wrap:!l.cellOrSplitMinWidth||!l.isWeekView,style:(0,p.j5)(l.cellOrSplitMinWidth?`min-width: ${l.cellOrSplitMinWidth}px`:"")},[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.viewCells,((t,a)=>((0,c.wg)(),(0,c.j4)(u,{key:a,options:e.$props,"edit-events":l.editEvents,data:t,"cell-width":s.hideWeekdays.length&&(l.isWeekView||l.isMonthView)&&l.cellWidth,"min-timestamp":l.minTimestamp,"max-timestamp":l.maxTimestamp,"cell-splits":l.hasSplits&&l.daySplits||[]},{"cell-content":(0,c.w5)((({events:a,split:i,selectCell:o})=>[(0,c.WI)(e.$slots,"cell-content",{cell:t,view:n.view,goNarrower:o,events:a},(()=>[i&&!s.stickySplitLabels?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"split-label",innerHTML:i.label},null,8,Ta)):(0,c.kq)("",!0),t.content?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__cell-date",innerHTML:t.content},null,8,Ma)):(0,c.kq)("",!0),(l.isMonthView&&!s.eventsOnMonthView||l.isYearsOrYearView&&s.eventsCountOnYearView)&&a.length?((0,c.wg)(),(0,c.iD)("div",Ca,[(0,c.WI)(e.$slots,"events-count",{view:n.view,events:a},(()=>[(0,c.Uk)((0,p.zw)(a.length),1)]))])):(0,c.kq)("",!0),!l.cellOrSplitHasEvents(a,i)&&l.isWeekOrDayView?((0,c.wg)(),(0,c.iD)("div",ja,[(0,c.WI)(e.$slots,"no-event",{},(()=>[(0,c.Uk)((0,p.zw)(n.texts.noEvent),1)]))])):(0,c.kq)("",!0)]))])),event:(0,c.w5)((({event:a,view:i})=>[(0,c.WI)(e.$slots,"event",{view:i,event:a},(()=>[l.editEvents.title&&a.titleEditable?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"vuecal__event-title vuecal__event-title--edit",contenteditable:"contenteditable",onBlur:e=>l.onEventTitleBlur(e,a),innerHTML:a.title},null,40,Ea)):a.title?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__event-title",innerHTML:a.title},null,8,Wa)):(0,c.kq)("",!0),!s.time||a.allDay||l.isMonthView&&(a.allDay||"short"===s.showAllDayEvents)||l.isShortMonthView?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",xa,[(0,c.Uk)((0,p.zw)(n.utils.date.formatTime(a.start,l.TimeFormat)),1),a.endTimeMinutes?((0,c.wg)(),(0,c.iD)("span",$a," - "+(0,p.zw)(n.utils.date.formatTime(a.end,l.TimeFormat,null,!0)),1)):(0,c.kq)("",!0),a.daysCount>1&&(a.segments[t.formattedDate]||{}).isFirstDay?((0,c.wg)(),(0,c.iD)("small",Sa," +"+(0,p.zw)(a.daysCount-1)+(0,p.zw)((n.texts.day[0]||"").toLowerCase()),1)):(0,c.kq)("",!0)])),!a.content||l.isMonthView&&a.allDay&&"short"===s.showAllDayEvents||l.isShortMonthView?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",{key:3,class:"vuecal__event-content",innerHTML:a.content},null,8,Oa))]))])),_:2},1032,["options","edit-events","data","cell-width","min-timestamp","max-timestamp","cell-splits"])))),128))],12,ba)],10,ya)])],2)]))])),_:3},8,["name","appear"]),n.ready?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",Va,Ha))]))],10,da)}s(30541);let Ua,La,Fa,Pa,Ia={},Za={};class Ya{constructor(e,t=!1){(0,Ts.Z)(this,"texts",{}),(0,Ts.Z)(this,"dateToMinutes",(e=>60*e.getHours()+e.getMinutes())),Pa=this,this._texts=e,t||!Date||Date.prototype.addDays||this._initDatePrototypes()}_initDatePrototypes(){Date.prototype.addDays=function(e){return Pa.addDays(this,e)},Date.prototype.subtractDays=function(e){return Pa.subtractDays(this,e)},Date.prototype.addHours=function(e){return Pa.addHours(this,e)},Date.prototype.subtractHours=function(e){return Pa.subtractHours(this,e)},Date.prototype.addMinutes=function(e){return Pa.addMinutes(this,e)},Date.prototype.subtractMinutes=function(e){return Pa.subtractMinutes(this,e)},Date.prototype.getWeek=function(){return Pa.getWeek(this)},Date.prototype.isToday=function(){return Pa.isToday(this)},Date.prototype.isLeapYear=function(){return Pa.isLeapYear(this)},Date.prototype.format=function(e="YYYY-MM-DD"){return Pa.formatDate(this,e)},Date.prototype.formatTime=function(e="HH:mm"){return Pa.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 La!==(new Date).getDate()&&(Ua=new Date,La=Ua.getDate(),Fa=`${Ua.getFullYear()}-${Ua.getMonth()}-${Ua.getDate()}`),Fa}addDays(e,t){const s=new Date(e.valueOf());return s.setDate(s.getDate()+t),s}subtractDays(e,t){const s=new Date(e.valueOf());return s.setDate(s.getDate()-t),s}addHours(e,t){const s=new Date(e.valueOf());return s.setHours(s.getHours()+t),s}subtractHours(e,t){const s=new Date(e.valueOf());return s.setHours(s.getHours()-t),s}addMinutes(e,t){const s=new Date(e.valueOf());return s.setMinutes(s.getMinutes()+t),s}subtractMinutes(e,t){const s=new Date(e.valueOf());return s.setMinutes(s.getMinutes()-t),s}getWeek(e){const t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate())),s=t.getUTCDay()||7;t.setUTCDate(t.getUTCDate()+4-s);const a=new Date(Date.UTC(t.getUTCFullYear(),0,1));return Math.ceil(((t-a)/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 s=e&&new Date(e.valueOf())||new Date,a=t?7:6;return s.setDate(s.getDate()-(s.getDay()+a)%7),s}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 s=60*(new Date(t).getTimezoneOffset()-new Date(e).getTimezoneOffset())*1e3;return Math.ceil((t-e-s)/864e5)}datesInSameTimeStep(e,t,s){return Math.abs(e.getTime()-t.getTime())<=60*s*1e3}formatDate(e,t="YYYY-MM-DD",s=null){if(s||(s=this._texts),t||(t="YYYY-MM-DD"),"YYYY-MM-DD"===t)return this.formatDateLite(e);Ia={},Za={};const a={YYYY:()=>this._hydrateDateObject(e,s).YYYY,YY:()=>this._hydrateDateObject(e,s).YY(),M:()=>this._hydrateDateObject(e,s).M,MM:()=>this._hydrateDateObject(e,s).MM(),MMM:()=>this._hydrateDateObject(e,s).MMM(),MMMM:()=>this._hydrateDateObject(e,s).MMMM(),MMMMG:()=>this._hydrateDateObject(e,s).MMMMG(),D:()=>this._hydrateDateObject(e,s).D,DD:()=>this._hydrateDateObject(e,s).DD(),S:()=>this._hydrateDateObject(e,s).S(),d:()=>this._hydrateDateObject(e,s).d,dd:()=>this._hydrateDateObject(e,s).dd(),ddd:()=>this._hydrateDateObject(e,s).ddd(),dddd:()=>this._hydrateDateObject(e,s).dddd(),HH:()=>this._hydrateTimeObject(e,s).HH,H:()=>this._hydrateTimeObject(e,s).H,hh:()=>this._hydrateTimeObject(e,s).hh,h:()=>this._hydrateTimeObject(e,s).h,am:()=>this._hydrateTimeObject(e,s).am,AM:()=>this._hydrateTimeObject(e,s).AM,mm:()=>this._hydrateTimeObject(e,s).mm,m:()=>this._hydrateTimeObject(e,s).m};return t.replace(/(\{[a-zA-Z]+\}|[a-zA-Z]+)/g,((e,t)=>{const s=a[t.replace(/\{|\}/g,"")];return void 0!==s?s():t}))}formatDateLite(e){const t=e.getMonth()+1,s=e.getDate();return`${e.getFullYear()}-${t<10?"0":""}${t}-${s<10?"0":""}${s}`}formatTime(e,t="HH:mm",s=null,a=!1){let i=!1;if(a){const[t,s,a]=[e.getHours(),e.getMinutes(),e.getSeconds()];t+s+a===141&&(i=!0)}if(e instanceof Date&&"HH:mm"===t)return i?"24:00":this.formatTimeLite(e);Za={},s||(s=this._texts);const n=this._hydrateTimeObject(e,s),l=t.replace(/(\{[a-zA-Z]+\}|[a-zA-Z]+)/g,((e,t)=>{const s=n[t.replace(/\{|\}/g,"")];return void 0!==s?s:t}));return i?l.replace("23:59","24:00"):l}formatTimeLite(e){const t=e.getHours(),s=e.getMinutes();return`${(t<10?"0":"")+t}:${(s<10?"0":"")+s}`}_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(Ia.D)return Ia;const s=e.getFullYear(),a=e.getMonth()+1,i=e.getDate(),n=e.getDay(),l=(n-1+7)%7;return Ia={YYYY:s,YY:()=>s.toString().substring(2),M:a,MM:()=>(a<10?"0":"")+a,MMM:()=>t.months[a-1].substring(0,3),MMMM:()=>t.months[a-1],MMMMG:()=>(t.monthsGenitive||t.months)[a-1],D:i,DD:()=>(i<10?"0":"")+i,S:()=>this._nth(i),d:l+1,dd:()=>t.weekDays[l][0],ddd:()=>t.weekDays[l].substr(0,3),dddd:()=>t.weekDays[l]},Ia}_hydrateTimeObject(e,t){if(Za.am)return Za;let s,a;e instanceof Date?(s=e.getHours(),a=e.getMinutes()):(s=Math.floor(e/60),a=Math.floor(e%60));const i=s%12?s%12:12,n=(t||{am:"am",pm:"pm"})[24===s||s<12?"am":"pm"];return Za={H:s,h:i,HH:(s<10?"0":"")+s,hh:(i<10?"0":"")+i,am:n,AM:n.toUpperCase(),m:a,mm:(a<10?"0":"")+a},Za}}const Na=1440;class Ba{constructor(e){(0,Ts.Z)(this,"_vuecal",null),(0,Ts.Z)(this,"selectCell",((e=!1,t,s)=>{this._vuecal.$emit("cell-click",s?{date:t,split:s}: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",s?{date:t,split:s}:t)))})),(0,Ts.Z)(this,"keyPressEnterCell",((e,t)=>{this._vuecal.$emit("cell-keypress-enter",t?{date:e,split:t}:e),this._vuecal.switchToNarrowerView()})),(0,Ts.Z)(this,"getPosition",(e=>{const{left:t,top:s}=this._vuecal.cellsEl.getBoundingClientRect(),{clientX:a,clientY:i}="ontouchstart"in window&&e.touches?e.touches[0]:e;return{x:a-t,y:i-s}})),(0,Ts.Z)(this,"minutesAtCursor",(e=>{let t=0,s={x:0,y:0};const{timeStep:a,timeCellHeight:i,timeFrom:n}=this._vuecal.$props;return"number"===typeof e?t=e:"object"===typeof e&&(s=this.getPosition(e),t=Math.round(s.y*a/parseInt(i)+n)),{minutes:Math.max(Math.min(t,Na),0),cursorCoords:s}})),this._vuecal=e}}const qa=2,Ra=1440;let Ka,Ga,Xa;class Ja{constructor(e,t){(0,Ts.Z)(this,"_vuecal",null),(0,Ts.Z)(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,Ka=t}createAnEvent(e,t,s){if("string"===typeof e&&(e=Ka.stringToDate(e)),!(e instanceof Date))return!1;const a=Ka.dateToMinutes(e);t=1*t||60*qa;const i=a+t,n=Ka.addMinutes(new Date(e),t);s.end&&("string"===typeof s.end&&(s.end=Ka.stringToDate(s.end)),s.endTimeMinutes=Ka.dateToMinutes(s.end));const l={...this.eventDefaults,_eid:`${this._vuecal._.uid}_${this._vuecal.eventIdIncrement++}`,start:e,startTimeMinutes:a,end:n,endTimeMinutes:i,segments:null,...s};return"function"!==typeof this._vuecal.onEventCreate||this._vuecal.onEventCreate(l,(()=>this.deleteAnEvent(l)))?(l.startDateF!==l.endDateF&&(l.daysCount=Ka.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[Ka.formatDateLite(e.start)]={start:e.start,startTimeMinutes:e.startTimeMinutes,endTimeMinutes:Ra,isFirstDay:!0,isLastDay:!1});const t=e.segments[Ka.formatDateLite(e.end)];t&&(t.isLastDay=!1,t.endTimeMinutes=Ra);const s=Ka.addDays(e.end,1),a=Ka.formatDateLite(s);return s.setHours(0,0,0,0),e.segments[a]={start:s,startTimeMinutes:0,endTimeMinutes:e.endTimeMinutes,isFirstDay:!1,isLastDay:!0},e.end=Ka.addMinutes(s,e.endTimeMinutes),e.daysCount=Object.keys(e.segments).length,a}removeEventSegment(e){let t=Object.keys(e.segments).length;if(t<=1)return Ka.formatDateLite(e.end);delete e.segments[Ka.formatDateLite(e.end)],t--;const s=Ka.subtractDays(e.end,1),a=Ka.formatDateLite(s),i=e.segments[a];return t?i&&(i.isLastDay=!0,i.endTimeMinutes=e.endTimeMinutes):e.segments=null,e.daysCount=t||1,e.end=s,a}createEventSegments(e,t,s){const a=t.getTime(),i=s.getTime();let n,l,o,r=e.start.getTime(),d=e.end.getTime(),c=!1;e.end.getHours()||e.end.getMinutes()||(d-=1e3),e.segments={},e.repeat?(n=a,l=Math.min(i,e.repeat.until?Ka.stringToDate(e.repeat.until).getTime():i)):(n=Math.max(a,r),l=Math.min(i,d));while(n<=l){let t=!1;const s=Ka.addDays(new Date(n),1).setHours(0,0,0,0);let a,i,u,h;if(e.repeat){const s=new Date(n),l=Ka.formatDateLite(s);(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),a=n===o,i=l===Ka.formatDateLite(new Date(d)),u=new Date(a?r:n),h=Ka.formatDateLite(u),i&&(c=!1)}else t=!0,a=n===r,i=l===d&&s>l,u=a?e.start:new Date(n),h=Ka.formatDateLite(a?e.start:u);t&&(e.segments[h]={start:u,startTimeMinutes:a?e.startTimeMinutes:0,endTimeMinutes:i?e.endTimeMinutes:Ra,isFirstDay:a,isLastDay:i}),n=s}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){Xa=e.slice(0),Ga={},e.forEach((e=>{Xa.shift(),Ga[e._eid]||(Ga[e._eid]={overlaps:[],start:e.start,position:0,sameOverlaps:[]}),Ga[e._eid].position=0,Xa.forEach((s=>{Ga[s._eid]||(Ga[s._eid]={overlaps:[],start:s.start,position:0,sameOverlaps:[]});const a=this.eventInRange(s,e.start,e.end),i=this.eventSameRange(s,e),n=t.overlapsPerTimeStep?Ka.datesInSameTimeStep(e.start,s.start,t.timeStep):1;if(e.background||e.allDay||s.background||s.allDay||!a||!n){let t,a;(t=(Ga[e._eid]||{overlaps:[]}).overlaps.indexOf(s._eid))>-1&&Ga[e._eid].overlaps.splice(t,1),(a=(Ga[s._eid]||{overlaps:[]}).overlaps.indexOf(e._eid))>-1&&Ga[s._eid].overlaps.splice(a,1),Ga[s._eid].position--}else Ga[e._eid].overlaps.push(s._eid),Ga[e._eid].overlaps=[...new Set(Ga[e._eid].overlaps)],Ga[s._eid].overlaps.push(e._eid),Ga[s._eid].overlaps=[...new Set(Ga[s._eid].overlaps)],Ga[s._eid].position++,i&&(Ga[e._eid].sameOverlaps.push(s._eid),Ga[e._eid].sameOverlaps=[...new Set(Ga[e._eid].sameOverlaps)],Ga[s._eid].sameOverlaps.push(e._eid),Ga[s._eid].sameOverlaps=[...new Set(Ga[s._eid].sameOverlaps)])}))}));let s=0;for(const a in Ga){const e=Ga[a],t=e.overlaps.map((e=>({id:e,start:Ga[e].start})));t.push({id:a,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===a)),s=Math.max(this.getOverlapsStreak(e,Ga),s)}return[Ga,s]}getOverlapsStreak(e,t={}){let s=e.overlaps.length+1,a=[];return e.overlaps.forEach((s=>{if(!a.includes(s)){const i=e.overlaps.filter((e=>e!==s));i.forEach((e=>{t[e].overlaps.includes(s)||a.push(e)}))}})),a=[...new Set(a)],s-=a.length,s}eventInRange(e,t,s){if(e.allDay||!this._vuecal.time){const a=new Date(e.start).setHours(0,0,0,0),i=new Date(e.end).setHours(23,59,0,0);return i>=new Date(t).setHours(0,0,0,0)&&a<=new Date(s).setHours(0,0,0,0)}const a=e.start.getTime(),i=e.end.getTime();return a<s.getTime()&&i>t.getTime()}eventSameRange(e,t){const s=e.start.getTime()==t.start.getTime(),a=e.end.getTime()==t.end.getTime();return s&&a}}const Qa={class:"vuecal__header"},ei={key:0,class:"vuecal__flex vuecal__menu",role:"tablist","aria-label":"Calendar views navigation"},ti=["onDragenter","onDragleave","onClick","aria-label"],si={key:1,class:"vuecal__title-bar"},ai=["aria-label"],ii={class:"vuecal__flex vuecal__title",grow:""},ni=["aria-label"],li={key:0,class:"vuecal__flex vuecal__split-days-headers"};function oi(e,t,s,i,n,l){const o=(0,c.up)("weekdays-headings");return(0,c.wg)(),(0,c.iD)("div",Qa,[s.options.hideViewSelector?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",ei,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(s.viewProps.views,((t,a)=>((0,c.wg)(),(0,c.iD)(c.HY,{key:a},[t.enabled?((0,c.wg)(),(0,c.iD)("button",{key:0,class:(0,p.C_)(["vuecal__view-btn",{"vuecal__view-btn--active":l.view.id===a,"vuecal__view-btn--highlighted":e.highlightedControl===a}]),type:"button",onDragenter:t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragEnter(t,a,e.$data),onDragleave:t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragLeave(t,a,e.$data),onClick:e=>l.switchView(a,null,!0),"aria-label":`${t.label} view`},(0,p.zw)(t.label),43,ti)):(0,c.kq)("",!0)],64)))),128))])),s.options.hideTitleBar?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",si,[(0,c._)("button",{class:(0,p.C_)(["vuecal__arrow vuecal__arrow--prev",{"vuecal__arrow--highlighted":"previous"===e.highlightedControl}]),type:"button",onClick:t[0]||(t[0]=(...e)=>l.previous&&l.previous(...e)),onDragenter:t[1]||(t[1]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragEnter(t,"previous",e.$data)),onDragleave:t[2]||(t[2]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragLeave(t,"previous",e.$data)),"aria-label":`Previous ${l.view.id}`},[(0,c.WI)(e.$slots,"arrow-prev")],42,ai),(0,c._)("div",ii,[(0,c.Wm)(a.uT,{name:s.options.transitions?`slide-fade--${l.transitionDirection}`:""},{default:(0,c.w5)((()=>[((0,c.wg)(),(0,c.j4)((0,c.LL)(l.broaderView?"button":"span"),{type:!!l.broaderView&&"button",key:`${l.view.id}${l.view.startDate.toString()}`,onClick:t[3]||(t[3]=e=>!!l.broaderView&&l.switchToBroaderView()),"aria-label":!!l.broaderView&&`Go to ${l.broaderView} view`},{default:(0,c.w5)((()=>[(0,c.WI)(e.$slots,"title")])),_:3},8,["type","aria-label"]))])),_:3},8,["name"])]),s.options.todayButton?((0,c.wg)(),(0,c.iD)("button",{key:0,class:(0,p.C_)(["vuecal__today-btn",{"vuecal__today-btn--highlighted":"today"===e.highlightedControl}]),type:"button",onClick:t[4]||(t[4]=(...e)=>l.goToToday&&l.goToToday(...e)),onDragenter:t[5]||(t[5]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragEnter(t,"today",e.$data)),onDragleave:t[6]||(t[6]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragLeave(t,"today",e.$data)),"aria-label":"Today"},[(0,c.WI)(e.$slots,"today-button")],34)):(0,c.kq)("",!0),(0,c._)("button",{class:(0,p.C_)(["vuecal__arrow vuecal__arrow--next",{"vuecal__arrow--highlighted":"next"===e.highlightedControl}]),type:"button",onClick:t[7]||(t[7]=(...e)=>l.next&&l.next(...e)),onDragenter:t[8]||(t[8]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragEnter(t,"next",e.$data)),onDragleave:t[9]||(t[9]=t=>s.editEvents.drag&&l.dnd&&l.dnd.viewSelectorDragLeave(t,"next",e.$data)),"aria-label":`Next ${l.view.id}`},[(0,c.WI)(e.$slots,"arrow-next")],42,ni)])),s.viewProps.weekDaysInHeader?((0,c.wg)(),(0,c.j4)(o,{key:2,"week-days":s.weekDays,"transition-direction":l.transitionDirection,"switch-to-narrower-view":s.switchToNarrowerView},(0,c.Nv)({_:2},[e.$slots["weekday-heading"]?{name:"weekday-heading",fn:(0,c.w5)((({heading:t,view:s})=>[(0,c.WI)(e.$slots,"weekday-heading",{heading:t,view:s})])),key:"0"}:void 0,e.$slots["split-label"]?{name:"split-label",fn:(0,c.w5)((({split:t})=>[(0,c.WI)(e.$slots,"split-label",{split:t,view:l.view})])),key:"1"}:void 0]),1032,["week-days","transition-direction","switch-to-narrower-view"])):(0,c.kq)("",!0),(0,c.Wm)(a.uT,{name:`slide-fade--${l.transitionDirection}`},{default:(0,c.w5)((()=>[l.showDaySplits?((0,c.wg)(),(0,c.iD)("div",li,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(s.daySplits,((t,s)=>((0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["day-split-header",t.class||!1]),key:s},[(0,c.WI)(e.$slots,"split-label",{split:t,view:l.view.id},(()=>[(0,c.Uk)((0,p.zw)(t.label),1)]))],2)))),128))])):(0,c.kq)("",!0)])),_:3},8,["name"])])}const ri={class:"vuecal__flex vuecal__weekdays-headings",ref:"vuecal_weekday_heading"},di=["onClick"],ci={class:"vuecal__flex weekday-label",grow:""},ui={class:"full"},hi={class:"small"},mi={class:"xsmall"},pi={key:0},vi={key:0,class:"vuecal__flex vuecal__split-days-headers",grow:""};function gi(e,t,s,i,n,l){return(0,c.wg)(),(0,c.iD)("div",ri,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.headings,((i,n)=>((0,c.wg)(),(0,c.iD)(c.HY,{key:n},[i.hide?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",{key:0,class:(0,p.C_)(["vuecal__flex vuecal__heading",{today:i.today,"today-cell":i.today,clickable:l.cellHeadingsClickable,"yesterday-cell":new Date(i.date).toLocaleDateString("sk-SK")==new Date((new Date).setDate((new Date).getDate()-1)).toLocaleDateString("sk-SK")}]),style:(0,p.j5)(l.weekdayCellStyles),onClick:e=>"week"===l.view.id&&l.selectCell(i.date,e),onDblclick:t[0]||(t[0]=e=>"week"===l.view.id&&l.vuecal.dblclickToNavigate&&s.switchToNarrowerView())},[(0,c.Wm)(a.uT,{name:`slide-fade--${s.transitionDirection}`,appear:l.vuecal.transitions},{default:(0,c.w5)((()=>[((0,c.wg)(),(0,c.iD)("div",{class:"vuecal__flex",column:"",key:!!l.vuecal.transitions&&`${n}-${i.dayOfMonth}`},[(0,c._)("div",ci,[(0,c.WI)(e.$slots,"weekday-heading",{heading:l.cleanupHeading(i),view:l.view},(()=>[(0,c._)("span",ui,(0,p.zw)(i.full),1),(0,c._)("span",hi,(0,p.zw)(i.small),1),(0,c._)("span",mi,(0,p.zw)(i.xsmall),1),i.dayOfMonth?((0,c.wg)(),(0,c.iD)("span",pi," "+(0,p.zw)(i.dayOfMonth),1)):(0,c.kq)("",!0)]))]),l.vuecal.hasSplits&&l.vuecal.stickySplitLabels?((0,c.wg)(),(0,c.iD)("div",vi,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.vuecal.daySplits,((t,s)=>((0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["day-split-header",t.class||!1]),key:s},[(0,c.WI)(e.$slots,"split-label",{split:t,view:l.view},(()=>[(0,c.Uk)((0,p.zw)(t.label),1)]))],2)))),128))])):(0,c.kq)("",!0)]))])),_:2},1032,["name","appear"])],46,di))],64)))),128))],512)}var wi={inject:["vuecal","utils","view"],props:{transitionDirection:{type:String,default:"right"},weekDays:{type:Array,default:()=>[]},switchToNarrowerView:{type:Function,default:()=>{}},unscheduledTime:{type:Array,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,unscheduledTime:e.unscheduledTime,name:e.name,initials:e.initials,...e.today?{today:e.today}:{}}),onTimelineScroll(e){this.$refs["vuecal_weekday_heading"].style.top=`${e}px`}},computed:{headings(){if(!["month","week"].includes(this.view.id))return[];let e=!1;const t=this.weekDays.map(((t,s)=>{const a=this.utils.date.addDays(this.view.startDate,this.vuecal.startWeekOnSunday?s-1:s);let i=null,n=null,l=null;return this.unscheduledTime[s]?.time&&(i=Math.floor(this.unscheduledTime[s].time/60)+","+String(this.unscheduledTime[s].time%60)[0]),this.unscheduledTime[s]?.name&&this.unscheduledTime[s]?.name&&(n=this.unscheduledTime[s].name+" "+this.unscheduledTime[s].surname,l=this.unscheduledTime[s].name.charAt(0).toUpperCase()+this.unscheduledTime[s].surname.charAt(0).toUpperCase()),{hide:t.hide,full:t.label,small:t.short||t.label.substr(0,3),xsmall:t.short||t.label.substr(0,1),unscheduledTime:i,name:n,initials:l,..."week"===this.view.id?{dayOfMonth:a.getDate(),date:a,today:!e&&this.utils.date.isToday(a)&&!e++}:{}}}));return t},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)}}};const fi=(0,b.Z)(wi,[["render",gi]]);var yi=fi,_i={inject:["vuecal","previous","next","switchView","updateSelectedDate","modules","view"],components:{WeekdaysHeadings:yi},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]},showDaySplits(){return"day"===this.view.id&&this.hasSplits&&this.options.stickySplitLabels&&!this.options.minSplitWidth},dnd(){return this.modules.dnd}}};const ki=(0,b.Z)(_i,[["render",oi]]);var Di=ki;const bi={key:0,class:"vuecal__all-day-text",style:{width:"3em"}};function Ti(e,t,s,a,i,n){const l=(0,c.up)("vuecal-cell");return(0,c.wg)(),(0,c.iD)("div",{class:"vuecal__flex vuecal__all-day",style:(0,p.j5)(s.cellOrSplitMinWidth&&{height:s.height})},[s.cellOrSplitMinWidth?(0,c.kq)("",!0):((0,c.wg)(),(0,c.iD)("div",bi,[(0,c._)("span",null,(0,p.zw)(s.label),1)])),(0,c._)("div",{class:(0,p.C_)(["vuecal__flex vuecal__cells",`${n.view.id}-view`]),grow:"",style:(0,p.j5)(s.cellOrSplitMinWidth?`min-width: ${s.cellOrSplitMinWidth}px`:"")},[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(s.cells,((t,a)=>((0,c.wg)(),(0,c.j4)(l,{key:a,options:s.options,"edit-events":n.editEvents,data:t,"all-day":!0,"cell-width":s.options.hideWeekdays.length&&(n.vuecal.isWeekView||n.vuecal.isMonthView)&&n.vuecal.cellWidth,"min-timestamp":s.options.minTimestamp,"max-timestamp":s.options.maxTimestamp,"cell-splits":s.daySplits},{event:(0,c.w5)((({event:t,view:s})=>[(0,c.WI)(e.$slots,"event",{view:s,event:t})])),_:2},1032,["options","edit-events","data","cell-width","min-timestamp","max-timestamp","cell-splits"])))),128))],6)],4)}const Mi=["data-split","aria-label","onTouchstart","onMousedown","onDragover","onDrop"],Ci={key:0,class:"cell-time-labels"},ji=["innerHTML"],Ei={key:2,class:"vuecal__cell-events"},Wi=["title"];function xi(e,t,s,i,n,l){const o=(0,c.up)("event");return(0,c.wg)(),(0,c.j4)(a.W3,{class:(0,p.C_)(["vuecal__cell",l.cellClasses]),name:`slide-fade--${l.transitionDirection}`,tag:"div",appear:s.options.transitions,style:(0,p.j5)(l.cellStyles)},{default:(0,c.w5)((()=>[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.splitsCount?l.splits:1,((i,n)=>((0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["vuecal__flex vuecal__cell-content",l.splitsCount&&l.splitClasses(i)]),key:s.options.transitions?`${l.view.id}-${s.data.content}-${n}`:n,"data-split":!!l.splitsCount&&i.id,column:"",tabindex:"0","aria-label":s.data.content,onFocus:t[0]||(t[0]=e=>l.onCellFocus(e)),onKeypress:t[1]||(t[1]=(0,a.D2)((e=>l.onCellkeyPressEnter(e)),["enter"])),onTouchstart:e=>!l.isDisabled&&l.onCellTouchStart(e,l.splitsCount?i.id:null),onMousedown:e=>!l.isDisabled&&l.onCellMouseDown(e,l.splitsCount?i.id:null),onClick:t[2]||(t[2]=e=>!l.isDisabled&&l.onCellClick(e)),onDblclick:t[3]||(t[3]=e=>!l.isDisabled&&l.onCellDblClick(e)),onContextmenu:t[4]||(t[4]=e=>!l.isDisabled&&s.options.cellContextmenu&&l.onCellContextMenu(e)),onDragenter:t[5]||(t[5]=t=>!l.isDisabled&&s.editEvents.drag&&l.dnd&&l.dnd.cellDragEnter(t,e.$data,s.data.startDate)),onDragover:t=>!l.isDisabled&&s.editEvents.drag&&l.dnd&&l.dnd.cellDragOver(t,e.$data,s.data.startDate,l.splitsCount?i.id:null),onDragleave:t[6]||(t[6]=t=>!l.isDisabled&&s.editEvents.drag&&l.dnd&&l.dnd.cellDragLeave(t,e.$data,s.data.startDate)),onDrop:t=>!l.isDisabled&&s.editEvents.drag&&l.dnd&&l.dnd.cellDragDrop(t,e.$data,s.data.startDate,l.splitsCount?i.id:null)},[s.options.showTimeInCells&&s.options.time&&l.isWeekOrDayView&&!s.allDay?((0,c.wg)(),(0,c.iD)("div",Ci,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.vuecal.timeCells,((e,t)=>((0,c.wg)(),(0,c.iD)("span",{class:"cell-time-label",key:t},(0,p.zw)(e.label),1)))),128))])):(0,c.kq)("",!0),l.isWeekOrDayView&&!s.allDay&&l.specialHours.length?((0,c.wg)(!0),(0,c.iD)(c.HY,{key:1},(0,c.Ko)(l.specialHours,((e,t)=>((0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["vuecal__special-hours",`vuecal__special-hours--day${e.day} ${e.class}`]),style:(0,p.j5)(`height: ${e.height}px;top: ${e.top}px`)},[e.label?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"special-hours-label",innerHTML:e.label},null,8,ji)):(0,c.kq)("",!0)],6)))),256)):(0,c.kq)("",!0),(0,c.WI)(e.$slots,"cell-content",{events:l.events,selectCell:e=>l.selectCell(e,!0),split:!!l.splitsCount&&i}),l.eventsCount&&(l.isWeekOrDayView||"month"===l.view.id&&s.options.eventsOnMonthView)?((0,c.wg)(),(0,c.iD)("div",Ei,[((0,c.wg)(!0),(0,c.iD)(c.HY,null,(0,c.Ko)(l.splitsCount?i.events:l.events,((t,a)=>((0,c.wg)(),(0,c.j4)(o,{key:a,"cell-formatted-date":s.data.formattedDate,event:t,"all-day":s.allDay,"cell-events":l.splitsCount?i.events:l.events,cellOverlaps:(l.splitsCount?i.overlaps[t._eid]:e.cellOverlaps[t._eid])||[],allOverlaps:(l.splitsCount?i.overlaps:e.cellOverlaps)||[],"event-position":((l.splitsCount?i.overlaps[t._eid]:e.cellOverlaps[t._eid])||[]).position,"overlaps-streak":l.splitsCount?i.overlapsStreak:e.cellOverlapsStreak},{event:(0,c.w5)((({event:t,view:s})=>[(0,c.WI)(e.$slots,"event",{view:s,event:t})])),_:2},1032,["cell-formatted-date","event","all-day","cell-events","cellOverlaps","allOverlaps","event-position","overlaps-streak"])))),128))])):(0,c.kq)("",!0)],42,Mi)))),128)),l.timelineVisible?((0,c.wg)(),(0,c.iD)("div",{class:"vuecal__now-line",style:(0,p.j5)(`top: ${l.todaysTimePosition}px`),key:s.options.transitions?`${l.view.id}-now-line`:"now-line",title:l.utils.date.formatTime(l.vuecal.now)},null,12,Wi)):(0,c.kq)("",!0)])),_:3},8,["class","name","appear","style"])}const $i=["eventId","draggable"];function Si(e,t,s,i,n,l){return(0,c.wg)(),(0,c.iD)("div",{class:(0,p.C_)(["vuecal__event",l.eventClasses]),style:(0,p.j5)(l.eventStyles),eventId:`event-id-${s.event.id}`,tabindex:"0",onFocus:t[4]||(t[4]=(...e)=>l.focusEvent&&l.focusEvent(...e)),onKeypress:t[5]||(t[5]=(0,a.D2)((0,a.iM)(((...e)=>l.onEnterKeypress&&l.onEnterKeypress(...e)),["stop"]),["enter"])),onMouseenter:t[6]||(t[6]=(...e)=>l.onMouseEnter&&l.onMouseEnter(...e)),onMouseleave:t[7]||(t[7]=(...e)=>l.onMouseLeave&&l.onMouseLeave(...e)),onTouchstart:t[8]||(t[8]=(0,a.iM)(((...e)=>l.onTouchStart&&l.onTouchStart(...e)),["stop"])),onMousedown:t[9]||(t[9]=e=>l.onMouseDown(e)),onMouseup:t[10]||(t[10]=(...e)=>l.onMouseUp&&l.onMouseUp(...e)),onTouchend:t[11]||(t[11]=(...e)=>l.onMouseUp&&l.onMouseUp(...e)),onTouchmove:t[12]||(t[12]=(...e)=>l.onTouchMove&&l.onTouchMove(...e)),onDblclick:t[13]||(t[13]=(...e)=>l.onDblClick&&l.onDblClick(...e)),draggable:l.draggable,onDragstart:t[14]||(t[14]=e=>l.draggable&&l.onDragStart(e)),onDragend:t[15]||(t[15]=e=>l.draggable&&l.onDragEnd())},[l.vuecal.editEvents.delete&&s.event.deletable?((0,c.wg)(),(0,c.iD)("div",{key:0,class:"vuecal__event-delete",onClick:t[0]||(t[0]=(0,a.iM)(((...e)=>l.deleteEvent&&l.deleteEvent(...e)),["stop"])),onTouchstart:t[1]||(t[1]=(0,a.iM)(((...e)=>l.touchDeleteEvent&&l.touchDeleteEvent(...e)),["stop"]))},(0,p.zw)(l.vuecal.texts.deleteEvent),33)):(0,c.kq)("",!0),(0,c.WI)(e.$slots,"event",{event:s.event,view:l.view.id}),l.resizable?((0,c.wg)(),(0,c.iD)("div",{key:1,class:"vuecal__event-resize-handle",contenteditable:"false",onMousedown:t[2]||(t[2]=(0,a.iM)(((...e)=>l.onResizeHandleMouseDown&&l.onResizeHandleMouseDown(...e)),["stop","prevent"])),onTouchstart:t[3]||(t[3]=(0,a.iM)(((...e)=>l.onResizeHandleMouseDown&&l.onResizeHandleMouseDown(...e)),["stop","prevent"]))},null,32)):(0,c.kq)("",!0)],46,$i)}var Oi={inject:["vuecal","utils","modules","view","domEvents","editEvents"],props:{cellFormattedDate:{type:String,default:""},event:{type:Object,default:()=>({})},cellEvents:{type:Array,default:()=>[]},cellOverlaps:{type:Object,default:()=>({})},allOverlaps:{type:Object,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:s,focusAnEvent:a,resizeAnEvent:i,dragAnEvent:n}=this.domEvents;if(a._eid===this.event._eid&&s._eid===this.event._eid)return!0;this.focusEvent(),s._eid=null,this.vuecal.editEvents.delete&&this.event.deletable&&(s.timeoutId=setTimeout((()=>{i._eid||n._eid||(s._eid=this.event._eid,this.event.deleting=!0)}),s.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:s}=e.touches[0],{startX:a,startY:i,dragThreshold:n}=this.touch;(Math.abs(t-a)>n||Math.abs(s-i)>n)&&(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.event.nonWorking||(this.event.draggingStatic=!1,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 s=e-this.vuecal.timeFrom;const a=Math.max(Math.round(s*this.vuecal.timeCellHeight/this.vuecal.timeStep),0);s=Math.min(t,this.vuecal.timeTo)-this.vuecal.timeFrom;const i=Math.round(s*this.vuecal.timeCellHeight/this.vuecal.timeStep),n=Math.max(i-a,5);return{top:a,height:n}},eventStyles(){if(this.event.allDay||!this.vuecal.time||!this.event.endTimeMinutes||"month"===this.view.id||this.allDay)return{};let e=100-10*this.eventPosition,t=5*this.eventPosition,s=10*(this.eventPosition+1),a=this.event.master_task_color;if(Array.isArray(this.cellOverlaps.sameOverlaps)&&this.cellOverlaps.sameOverlaps.length){const s=this.cellOverlaps.sameOverlaps.length+1,a=this.cellOverlaps.overlaps.filter((e=>{if(!this.cellOverlaps.sameOverlaps.includes(e)&&this.allOverlaps[this.event._eid].position>this.allOverlaps[e].position)return e}));e=100/s-5,t=100/s*(this.eventPosition-a.length)+5*(this.eventPosition-a.length)/s,a.length&&(e-=a.length*(10/s),t+=5*a.length-10*a.length/s*(this.eventPosition-a.length))}this.vuecal.minEventWidth&&e<this.vuecal.minEventWidth&&(e=this.vuecal.minEventWidth,t=(100-this.vuecal.minEventWidth)/this.cellOverlaps.overlaps.length*this.eventPosition);const{top:i,height:n}=this.eventDimensions;return{background:a,"z-index":`${s}`,top:`${i}px`,height:`${n}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,"event-blocker":this.event.is_blocker,"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-middle":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:s}=this.event;return this.vuecal.editEvents.drag&&e&&!t&&1===s},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}}};const Vi=(0,b.Z)(Oi,[["render",Si]]);var zi=Vi,Hi={inject:["vuecal","utils","modules","view","domEvents"],components:{Event:zi},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}){const t=e.classList.contains("vuecal__cell-split");let s=t?e:this.vuecal.findAncestor(e,"vuecal__cell-split");return s&&(s=s.attributes["data-split"].value,parseInt(s).toString()===s.toString()&&(s=parseInt(s))),s||null},splitClasses(e){return{"vuecal__cell-split":!0,"vuecal__cell-split--highlighted":this.highlightedSplit===e.id,"vuecal__cell-split--weekend":e.isWeekend,[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 s=this.splitsCount?this.getSplitAtCursor(e):null;this.utils.cell.selectCell(t,this.timeAtCursor,s),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;const t=this.splitsCount?this.getSplitAtCursor(e):null,s=this.timeAtCursor||this.data.startDate;this.vuecal.$emit("cell-focus",t?{date:s,split:t}:s)}},onCellMouseDown(e,t=null,s=!1){if("ontouchstart"in window&&!s)return!1;this.isSelected||this.onCellFocus(e);const{clickHoldACell:a,focusAnEvent:i}=this.domEvents;this.domEvents.cancelClickEventCreation=!1,a.eventCreated=!1,this.timeAtCursor=new Date(this.data.startDate);const{minutes:n,cursorCoords:{y:l}}=this.vuecal.minutesAtCursor(e);this.timeAtCursor.setMinutes(n);const o=this.isDOMElementAnEvent(e.target);!o&&i._eid&&((this.view.events.find((e=>e._eid===i._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:s}=this.domEvents;if(s.startCursorY=t,s.split=this.splitsCount?this.getSplitAtCursor(e):null,s.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,s.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 s=this.splitsCount?this.getSplitAtCursor(e):null;this.vuecal.$emit("cell-dblclick",s?{date:t,split:s}:t),this.options.dblclickToNavigate&&this.vuecal.switchToNarrowerView()},onCellContextMenu(e){e.stopPropagation(),e.preventDefault();const t=new Date(this.data.startDate),{cursorCoords:s,minutes:a}=this.vuecal.minutesAtCursor(e);t.setMinutes(a);const i=this.splitsCount?this.getSplitAtCursor(e):null;this.vuecal.$emit("cell-contextmenu",{date:t,...s,...i||{},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:s}=e;return t=Math.max(t,this.options.timeFrom),s=Math.min(s,this.options.timeTo),{...e,height:(s-t)*this.timeScale,top:(t-this.options.timeFrom)*this.timeScale}}))},events(){const{startDate:e,endDate:t}=this.data;let s=[];if(!["years","year"].includes(this.view.id)||this.options.eventsCountOnYearView){if(s=this.view.events.slice(0),"month"===this.view.id&&s.push(...this.view.outOfScopeEvents),s=s.filter((s=>this.utils.event.eventInRange(s,e,t))),this.options.showAllDayEvents&&"month"!==this.view.id&&(s=s.filter((e=>!!e.allDay===this.allDay))),this.options.time&&this.isWeekOrDayView&&!this.allDay){const{timeFrom:e,timeTo:t}=this.options;s=s.filter((s=>{const a=s.daysCount>1&&s.segments[this.data.formattedDate]||{},i=1===s.daysCount&&s.startTimeMinutes<t&&s.endTimeMinutes>e,n=s.daysCount>1&&a.startTimeMinutes<t&&a.endTimeMinutes>e,l=!1;return s.allDay||i||n||l}))}!this.options.time||!this.isWeekOrDayView||this.options.showAllDayEvents&&this.allDay||s.sort(((e,t)=>e.start<t.start?-1:1)),this.cellSplits.length||this.$nextTick(this.checkCellOverlappingEvents)}return s},eventsCount(){return this.events.length},splits(){return this.cellSplits.map(((e,t)=>{const s=this.events.filter((t=>t.split===e.id)),[a,i]=this.utils.event.checkCellOverlappingEvents(s.filter((e=>!e.background&&!e.allDay)),this.options);return{...e,overlaps:a,overlapsStreak:i,events:s}}))},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-of-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}}};const Ai=(0,b.Z)(Hi,[["render",xi]]);var Ui=Ai,Li={inject:["vuecal","view","editEvents"],components:{"vuecal-cell":Ui},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)}}};const Fi=(0,b.Z)(Li,[["render",Ti]]);var Pi=Fi,Ii=s(15941);const Zi=1440,Yi={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"},Ni=["years","year","month","week","day"],Bi=new Ya(Yi);var qi={name:"vue-cal",components:{"vuecal-cell":Ui,"vuecal-header":Di,WeekdaysHeadings:yi,AllDayBar:Pi},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"},scrollToHour:{type:Number,default:0},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},unscheduledTime:{type:Array,default:[]},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:Zi},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:{...Yi},utils:{date:!!this.disableDatePrototypes&&Bi.removePrototypes()||Bi,cell:null,event:null},modules:{dnd:null},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({},Yi,e),void this.utils.date.updateTexts(this.texts);if("en"===this.locale){const e=await s.e(3320).then(s.t.bind(s,3320,19));this.texts=Object.assign({},Yi,e)}else s(66667)(`./${e}.json`).then((e=>{this.texts=Object.assign({},Yi,e.default),this.utils.date.updateTexts(this.texts)}))},loadDragAndDrop(){s.e(1466).then(s.bind(s,91466)).then((e=>{const{DragAndDrop:t}=e;this.modules.dnd=new t(this)})).catch((()=>Ii.warn("Vue Cal: Missing drag & drop module.")))},validateView(e){return Ni.includes(e)||(Ii.error(`Vue Cal: invalid active-view parameter provided: "${e}".\nA valid view must be one of: ${Ni.join(", ")}.`),e="week"),this.enabledViews.includes(e)||(Ii.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,s=!1){e=this.validateView(e);const a=this.utils.date,i=this.view.startDate&&this.view.startDate.getTime();if(this.transitions&&s){if(this.view.id===e)return;const t=this.enabledViews;this.transitionDirection=t.indexOf(this.view.id)>t.indexOf(e)?"left":"right"}const n=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=a.getPreviousFirstDayOfWeek(e,this.startWeekOnSunday)),this.view.firstCellDate=e,this.view.lastCellDate=a.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=a.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=a.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=a.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=a.subtractDays(this.view.endDate,e)}}break}case"week":{t=a.getPreviousFirstDayOfWeek(t,this.startWeekOnSunday);const e=this.hideWeekends?5:7;this.view.startDate=this.hideWeekends&&this.startWeekOnSunday?a.addDays(t,1):t,this.view.startDate.setHours(0,0,0,0),this.view.endDate=a.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);break}this.addEventsToView();const l=this.view.startDate&&this.view.startDate.getTime();if((n!==e||l!==i)&&(this.$emit("update:activeView",e),this.ready)){const t=this.view.startDate,s={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:a.getWeek(this.startWeekOnSunday?a.addDays(t,1):t)}:{}};this.$refs["vuecal_scroll"].scrollTop=this.scrollToHour*this.timeCellHeight,this.$emit("view-change",s)}},previous(){this.previousNext(!1)},next(){this.previousNext()},previousNext(e=!0){const t=this.utils.date;this.transitionDirection=e?"right":"left";const s=e?1:-1;let a=null;const{startDate:i,id:n}=this.view;switch(n){case"years":a=new Date(i.getFullYear()+25*s,0,1);break;case"year":a=new Date(i.getFullYear()+1*s,1,1);break;case"month":a=new Date(i.getFullYear(),i.getMonth()+1*s,1);break;case"week":a=t[e?"addDays":"subtractDays"](t.getPreviousFirstDayOfWeek(i,this.startWeekOnSunday),7);break;case"day":a=t[e?"addDays":"subtractDays"](i,1);const n=a.getDay(),l=this.startWeekOnSunday?n:(n||7)-1,o=this.weekDays[l].hide;if(o){const s=this.weekDays.map(((e,t)=>({...e,i:t})));let i=null,n=0;e?(i=[...s.slice(l),...s].find((e=>(n++,!e.hide))).i,n--):i=[...s,...s.slice(0,l)].reverse().find((e=>(n++,!e.hide))).i,a=t[e?"addDays":"subtractDays"](a,n)}break}a&&this.switchView(n,a)},addEventsToView(e=[]){const t=this.utils.event,{startDate:s,endDate:a,firstCellDate:i,lastCellDate:n}=this.view;if(e.length||(this.view.events=[]),e=e.length?e:[...this.mutableEvents],!e||this.isYearsOrYearView&&!this.eventsCountOnYearView)return;let l=e.filter((e=>t.eventInRange(e,s,a)));this.isYearsOrYearView||this.isMonthView&&!this.eventsOnMonthView||(l=l.map((e=>e.daysCount>1?t.createEventSegments(e,i||s,n||a):e))),this.view.events.push(...l),this.isMonthView&&(this.view.outOfScopeEvents=[],e.forEach((e=>{(t.eventInRange(e,i,s)||t.eventInRange(e,a,n))&&(this.view.events.some((t=>t._eid===e._eid))||this.view.outOfScopeEvents.push(e))})))},findAncestor(e,t){while((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:s,dragCreateAnEvent:a}=this.domEvents;(null!==t._eid||null!==s._eid||a.start)&&(e.preventDefault(),t._eid?this.eventResizing(e):this.dragToCreateEvent&&a.start&&this.eventDragCreation(e))},onMouseUp(e){const{focusAnEvent:t,resizeAnEvent:s,clickHoldAnEvent:a,clickHoldACell:i,dragCreateAnEvent:n}=this.domEvents,{_eid:l}=a,{_eid:o}=s;let r=!1;const{event:d,start:c}=n,u=this.isDOMElementAnEvent(e.target),h=t.mousedUp;if(t.mousedUp=!1,u&&(this.domEvents.cancelClickEventCreation=!0),i.eventCreated)return;if(o){const{originalEnd:e,originalEndTimeMinutes:t,endTimeMinutes:a}=s,i=this.view.events.find((e=>e._eid===s._eid));if(r=a&&a!==t,i&&i.end.getTime()!==e.getTime()){const t=this.mutableEvents.find((e=>e._eid===s._eid));t.endTimeMinutes=i.endTimeMinutes,t.end=i.end;const a=this.cleanupEvent(i),n={...this.cleanupEvent(i),end:e,endTimeMinutes:i.originalEndTimeMinutes};this.$emit("event-duration-change",{event:a,oldDate:s.originalEnd,originalEvent:n}),this.$emit("event-change",{event:a,originalEvent:n})}i&&(i.resizing=!1),s._eid=null,s.start=null,s.split=null,s.segment=null,s.originalEndTimeMinutes=null,s.originalEnd=null,s.endTimeMinutes=null,s.startCell=null,s.endCell=null}else c&&(d&&(this.emitWithEvent("event-drag-create",d),n.event.resizing=!1),n.start=null,n.split=null,n.event=null);u||o||this.unfocusEvent(),a.timeoutId&&!l&&(clearTimeout(a.timeoutId),a.timeoutId=null),i.timeoutId&&(clearTimeout(i.timeoutId),i.timeoutId=null);const m="function"===typeof this.onEventClick;if(h&&!r&&!l&&!d&&m){let s=this.view.events.find((e=>e._eid===t._eid));return!s&&this.isMonthView&&(s=this.view.outOfScopeEvents.find((e=>e._eid===t._eid))),s&&this.onEventClick(s,e)}},onKeyUp(e){27===e.keyCode&&this.cancelDelete()},eventResizing(e){const{resizeAnEvent:t}=this.domEvents,s=this.view.events.find((e=>e._eid===t._eid))||{segments:{}},{minutes:a,cursorCoords:i}=this.minutesAtCursor(e),n=s.segments&&s.segments[t.segment],{date:l,event:o}=this.utils,r=Math.max(a,this.timeFrom+1,(n||s).startTimeMinutes+1);if(s.endTimeMinutes=t.endTimeMinutes=r,this.snapToTime){const e=s.endTimeMinutes+this.snapToTime/2;s.endTimeMinutes=e-e%this.snapToTime}if(n&&(n.endTimeMinutes=s.endTimeMinutes),s.end.setHours(0,s.endTimeMinutes,s.endTimeMinutes===Zi?-1:0,0),this.resizeX&&this.isWeekView){s.daysCount=l.countDays(s.start,s.end);const e=this.cellsEl,a=e.offsetWidth/e.childElementCount,n=Math.floor(i.x/a);if(null===t.startCell&&(t.startCell=n-(s.daysCount-1)),t.endCell!==n){t.endCell=n;const e=l.addDays(s.start,n-t.startCell),a=Math.max(l.countDays(s.start,e),1);if(a!==s.daysCount){let e=null;e=a>s.daysCount?o.addEventSegment(s):o.removeEventSegment(s),t.segment=e,s.endTimeMinutes+=.001}}}this.$emit("event-resizing",{_eid:s._eid,end:s.end,endTimeMinutes:s.endTimeMinutes})},eventDragCreation(e){const{dragCreateAnEvent:t}=this.domEvents,{start:s,startCursorY:a,split:i}=t,n=new Date(s),{minutes:l,cursorCoords:{y:o}}=this.minutesAtCursor(e);if(t.event||!(Math.abs(a-o)<this.dragToCreateThreshold))if(t.event){if(n.setHours(0,l,l===Zi?-1:0,0),this.snapToTime){let e=60*n.getHours()+n.getMinutes();const t=e+this.snapToTime/2;e=t-t%this.snapToTime,n.setHours(0,e,0,0)}const e=s<n,{event:a}=t;a.start=e?s:n,a.end=e?n:s,a.startTimeMinutes=60*a.start.getHours()+a.start.getMinutes(),a.endTimeMinutes=60*a.end.getHours()+a.end.getMinutes()}else{if(t.event=this.utils.event.createAnEvent(s,1,{split:i}),!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,s=this.view.events.find((s=>s._eid===(e._eid||t._eid)));e._eid=null,t._eid=null,s&&(s.focused=!1,s.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 s=t.title;t.title=e.target.innerHTML;const a=this.cleanupEvent(t);this.$emit("event-title-change",{event:a,oldTitle:s}),this.$emit("event-change",{event:a,originalEvent:{...a,title:s}})},updateMutableEvents(){const e=this.utils.date;this.mutableEvents=[],this.events.forEach((t=>{const s="string"===typeof t.start?e.stringToDate(t.start):t.start,a=e.formatDateLite(s),i=e.dateToMinutes(s);let n=null;"string"===typeof t.end&&t.end.includes("24:00")?(n=new Date(t.end.replace(" 24:00","")),n.setHours(23,59,59,0)):n="string"===typeof t.end?e.stringToDate(t.end):t.end;let l=e.formatDateLite(n),o=e.dateToMinutes(n);o&&o!==Zi||(!this.time||"string"===typeof t.end&&10===t.end.length?n.setHours(23,59,59,0):n.setSeconds(n.getSeconds()-1),l=e.formatDateLite(n),o=Zi);const r=a!==l;t=Object.assign({...this.utils.event.eventDefaults},t,{_eid:`${this._.uid}_${this.eventIdIncrement++}`,segments:r?{}:null,start:s,startTimeMinutes:i,end:n,endTimeMinutes:o,daysCount:r?e.countDays(s,n):1,class:t.class}),this.mutableEvents.push(t)}))},minutesAtCursor(e){return this.utils.cell.minutesAtCursor(e)},createEvent(e,t,s={}){return this.utils.event.createAnEvent(e,t,s)},cleanupEvent(e){e={...e};const t=["segments","deletable","deleting","titleEditable","resizable","resizing","draggable","dragging","draggingStatic","focused"];return t.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&&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,s=this.firstCellDateWeekNumber,a=s+e,i=this.startWeekOnSunday?1:0;return a>52?t.getWeek(t.addDays(this.view.firstCellDate,7*e+i)):a},timeTick(){this.now=new Date,this.timeTickerIds[1]=setTimeout(this.timeTick,6e4)},updateDateTexts(){this.utils.date.updateTexts(this.texts)},alignWithScrollbar(){},cellOrSplitHasEvents(e,t=null){return e.length&&(!t&&e.length||t&&e.some((e=>e.split===t.id)))}},created(){this.utils.cell=new Ba(this),this.utils.event=new Ja(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:s,drag:a,create:i,delete:n,title:l}=this.editEvents,o=this.onEventClick&&"function"===typeof this.onEventClick;(s||a||i||n||l||o)&&window.addEventListener(t?"touchend":"mouseup",this.onMouseUp),(s||a||i&&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()});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.$refs["vuecal_scroll"].addEventListener("scroll",(()=>{this.$refs["vuecal_splits_heading"].style.top=`${this.$refs["vuecal_scroll"].scrollTop}px`})),this.viewportTimelineOffset=this.$refs["vuecal_scroll"].getBoundingClientRect().top,this.$refs["vuecal_scroll"].scrollTop=this.scrollToHour*this.timeCellHeight,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,s=this.timeTo;t<s;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;return 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,s)=>({label:e,...t.length?{short:t[s]}:{},hide:this.hideWeekends&&s>=5||this.hideWeekdays.length&&this.hideWeekdays.includes(s+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 s=this.specialHours[t+1]||[];return Array.isArray(s)||(s=[s]),e=[],s.forEach((({from:s,to:a,class:i,label:n},l)=>{e[l]={day:t+1,from:[null,void 0].includes(s)?null:1*s,to:[null,void 0].includes(a)?null:1*a,class:i||"",label:n||""}})),e})):{}},viewTitle(){const e=this.utils.date;let t="";const s=this.view.startDate,a=s.getFullYear(),i=s.getMonth();switch(this.view.id){case"years":t=this.texts.years;break;case"year":t=a;break;case"month":t=`${this.months[i].label} ${a}`;break;case"week":{const a=this.view.endDate,i=s.getFullYear();let n=this.texts.months[s.getMonth()];this.xsmall&&(n=n.substring(0,3));let l=`${n} ${i}`;if(a.getMonth()!==s.getMonth()){const e=a.getFullYear();let t=this.texts.months[a.getMonth()];this.xsmall&&(t=t.substring(0,3)),l=i===e?`${n} - ${t} ${i}`:this.small?`${n.substring(0,3)} ${i} - ${t.substring(0,3)} ${e}`:`${n} ${i} - ${t} ${e}`}t=`${this.texts.week} ${e.getWeek(this.startWeekOnSunday?e.addDays(s,1):s)} (${l})`;break}case"day":t=this.utils.date.formatDate(s,this.texts.dateFormat,this.texts);break}return t},viewCells(){const e=this.utils.date;let t=[],s=null,a=!1;this.watchRealTime||(this.now=new Date);const i=this.now;switch(this.view.id){case"years":s=this.view.startDate.getFullYear(),t=Array.apply(null,Array(25)).map(((t,a)=>{const n=new Date(s+a,0,1),l=new Date(s+a+1,0,1);return l.setSeconds(-1),{startDate:n,formattedDate:e.formatDateLite(n),endDate:l,content:s+a,current:s+a===i.getFullYear()}}));break;case"year":s=this.view.startDate.getFullYear(),t=Array.apply(null,Array(12)).map(((t,a)=>{const n=new Date(s,a,1),l=new Date(s,a+1,1);return l.setSeconds(-1),{startDate:n,formattedDate:e.formatDateLite(n),endDate:l,content:this.xsmall?this.months[a].label.substr(0,3):this.months[a].label,current:a===i.getMonth()&&s===i.getFullYear()}}));break;case"month":{const s=this.view.startDate.getMonth(),i=new Date(this.view.firstCellDate);a=!1,t=Array.apply(null,Array(42)).map(((t,n)=>{const l=e.addDays(i,n),o=new Date(l);o.setHours(23,59,59,0);const r=!a&&e.isToday(l)&&!a++;return{startDate:l,formattedDate:e.formatDateLite(l),endDate:o,content:l.getDate(),today:r,outOfScope:l.getMonth()!==s,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":{a=!1;let s=this.view.startDate;const i=this.weekDays;t=i.map(((t,i)=>{const n=e.addDays(s,this.startWeekOnSunday?i-1:i),l=new Date(n);l.setHours(23,59,59,0);const o=(n.getDay()||7)-1;return{startDate:n,formattedDate:e.formatDateLite(n),endDate:l,today:!a&&e.isToday(n)&&!a++,specialHours:this.specialDayHours[o]||[]}})).filter(((e,t)=>!i[t].hide));break}case"day":{const s=this.view.startDate,a=new Date(this.view.startDate);a.setHours(23,59,59,0);const i=(s.getDay()||7)-1;t=[{startDate:s,formattedDate:e.formatDateLite(s),endDate:a,today:e.isToday(s),specialHours:this.specialDayHours[i]||[]}];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:s}=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":s.event,"vuecal--dragging-event":t._eid,"vuecal--events-on-month-view":this.eventsOnMonthView,"vuecal--short-events":this.isMonthView&&"short"===this.eventsOnMonthView,"vuecal--has-touch":"undefined"!==typeof window&&"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)}}};const Ri=(0,b.Z)(qi,[["render",Aa]]);var Ki=Ri,Gi={install:e=>{e.component("Vue-cal",Ki)}};s(48851),s(1292),s(81633),s(51045),s(46187),s(22299),s(93423),s(54687),s(49147),s(6250);n();const Xi={axios:{disabled:!0},i18n:{languages:[{title:"Slovenský",flag:"sk",value:"sk"}],defaultLanguage:"sk"},moxios:{routes:{"GET v1/auth/info":!0,"POST v1/auth/forgot":!0,"POST v1/auth/reset":!0,"POST v1/auth/info":!0,"POST v1/auth/invalidate":!0,"POST v1/auth/login":!0,"POST v1/auth/post":!0,"POST v1/master-tasks/(id)":!0,"DELETE v1/master-tasks/(id)":!0,"POST v1/master-tasks":!0,"GET v1/overview/projects":!0,"GET v1/overview/tasks":!0,"GET v1/overview/teams":!0,"GET v1/overview/ongoing-tasks":!0,"GET v1/overview/unscheduled-tasks":!0,"GET v1/tasks/(id)":!0,"POST v1/tasks/(id)":!0,"DELETE v1/tasks/(id)":!0,"GET v1/search":!0,"POST v1/tasks":!0,"POST v1/blockers":!0}}},Ji=(0,a.ri)(ps).use(fs).use(_s).use(ra).use(na,Xi).use(i.oX).use(o).use(Gi).use(d(),{color:"#6200EE"}).mount("#app"),Qi=Ji.$i18n.t},7648:function(e,t,s){"use strict";var a=s(40881);t["Z"]={parseErrors(e){return Object.values(e).map((e=>(0,a.$t)(e?.$message))).join(". ")}}},8973:function(e,t,s){var a={"./en.json":20790,"./sk.json":71941};function i(e){var t=n(e);return s(t)}function n(e){if(!s.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}i.keys=function(){return Object.keys(a)},i.resolve=n,e.exports=i,i.id=8973},66667:function(e,t,s){var a={"./ar.json":[68568,8568],"./bg.json":[20684,684],"./bn.json":[61170,1170],"./bs.json":[41161,1161],"./ca.json":[40612,612],"./cs.json":[50213,213],"./da.json":[98542,8542],"./de.json":[4701,4701],"./el.json":[20453,453],"./en.json":[3320,3320],"./es.json":[60076,76],"./et.json":[44075,4075],"./fa.json":[69004,9004],"./fr.json":[60007,7],"./he.json":[23746,3746],"./hr.json":[92921,2921],"./hu.json":[75723,5723],"./id.json":[12502,2502],"./is.json":[13214,3214],"./it.json":[51380,1380],"./ja.json":[72484,2484],"./ka.json":[60285,285],"./ko.json":[79249,9249],"./lt.json":[42838,2838],"./mn.json":[6177,6177],"./nl.json":[99729,9729],"./no.json":[49409,9409],"./pl.json":[25409,5409],"./pt-br.json":[74529,4529],"./ro.json":[29715,9715],"./ru.json":[32113,2113],"./sk.json":[30229,229],"./sl.json":[28636,8636],"./sq.json":[204,204],"./sr.json":[55553,5553],"./sv.json":[75979,5979],"./tr.json":[5268,5268],"./uk.json":[14057,4057],"./vi.json":[88929,8929],"./zh-cn.json":[56730,6730],"./zh-hk.json":[30841,841]};function i(e){if(!s.o(a,e))return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}));var t=a[e],i=t[0];return s.e(t[1]).then((function(){return s.t(i,19)}))}i.keys=function(){return Object.keys(a)},i.id=66667,e.exports=i},47146:function(e,t,s){"use strict";e.exports=s.p+"img/checkmark.76754510.svg"},75877:function(e,t,s){"use strict";e.exports=s.p+"img/pencil-icon.56bbc3aa.svg"},79981:function(e,t,s){"use strict";e.exports=s.p+"img/trash-icon.7a6e51b0.svg"},20790:function(e){"use strict";e.exports=JSON.parse('{"Value is not a valid email address":"Value is not a valid email address","error":"chyba","Value is required":"Pole je povinné","This field should be at least 8 characters long":"Pole musí obsahovať aspoň 8 znakov","This field should be at least 6 characters long":"Pole musí obsahovať aspoň 6 znakov","This maximum length allowed is 6":"Pole musí obsahovať 6 znakov","The value must be equal to the other value":"Heslá sa nezhodujú"}')},71941:function(e){"use strict";e.exports=JSON.parse('{"Value is not a valid email address":"Zadali ste neplatný email","error":"chyba","Value is required":"Pole je povinné","This field should be at least 8 characters long":"Pole musí obsahovať aspoň 8 znakov","This field should be at least 6 characters long":"Pole musí obsahovať aspoň 6 znakov","This maximum length allowed is 6":"Pole musí obsahovať 6 znakov","The value must be equal to the other value":"Heslá sa nezhodujú"}')}},t={};function s(a){var i=t[a];if(void 0!==i)return i.exports;var n=t[a]={id:a,loaded:!1,exports:{}};return e[a].call(n.exports,n,n.exports,s),n.loaded=!0,n.exports}s.m=e,function(){var e=[];s.O=function(t,a,i,n){if(!a){var l=1/0;for(c=0;c<e.length;c++){a=e[c][0],i=e[c][1],n=e[c][2];for(var o=!0,r=0;r<a.length;r++)(!1&n||l>=n)&&Object.keys(s.O).every((function(e){return s.O[e](a[r])}))?a.splice(r--,1):(o=!1,n<l&&(l=n));if(o){e.splice(c--,1);var d=i();void 0!==d&&(t=d)}}return t}n=n||0;for(var c=e.length;c>0&&e[c-1][2]>n;c--)e[c]=e[c-1];e[c]=[a,i,n]}}(),function(){s.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return s.d(t,{a:t}),t}}(),function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};s.t=function(a,i){if(1&i&&(a=this(a)),8&i)return a;if("object"===typeof a&&a){if(4&i&&a.__esModule)return a;if(16&i&&"function"===typeof a.then)return a}var n=Object.create(null);s.r(n);var l={};e=e||[null,t({}),t([]),t(t)];for(var o=2&i&&a;"object"==typeof o&&!~e.indexOf(o);o=t(o))Object.getOwnPropertyNames(o).forEach((function(e){l[e]=function(){return a[e]}}));return l["default"]=function(){return a},s.d(n,l),n}}(),function(){s.d=function(e,t){for(var a in t)s.o(t,a)&&!s.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})}}(),function(){s.f={},s.e=function(e){return Promise.all(Object.keys(s.f).reduce((function(t,a){return s.f[a](e,t),t}),[]))}}(),function(){s.u=function(e){return"js/"+e+"."+{7:"7cef58a7",76:"9977e9df",188:"c519c0ac",204:"4dd3d03d",213:"c9ed5252",229:"b09f2145",285:"6a0985b5",453:"04d72c77",612:"4ea201aa",684:"017ebeb8",841:"65cae984",1161:"59a7c68b",1170:"16217940",1380:"fc40de11",1466:"22199392",1927:"9c2430d0",2113:"2a1bcdfa",2484:"6def3002",2502:"66addef9",2838:"aa69ee5c",2848:"e2571220",2921:"b5aad8e9",3214:"72d306e7",3311:"bcab8a66",3320:"fe7033d0",3455:"91f52f3f",3657:"e558064c",3728:"3e558208",3746:"09ee0424",3791:"f08ff057",3829:"58532c28",4057:"4b3b38fd",4075:"2d83f71e",4132:"2625c991",4468:"a0632025",4529:"6ff3334b",4701:"e34c277a",4931:"3e629959",5024:"870e1057",5268:"5d463fbd",5360:"73845b24",5409:"4ce439c3",5553:"032fcbe7",5723:"09853a5d",5880:"db99d93b",5979:"385e1b41",6177:"12db94aa",6730:"61289e01",7209:"daf726f7",7343:"1e290ed5",7855:"cc9cedfa",7909:"369f9062",8024:"bb377405",8520:"cb7009ea",8542:"09badcc3",8568:"7f0dfd32",8636:"2a90cf11",8929:"ea6da50f",8990:"6dd37151",9004:"ffe04245",9249:"d2b0f88c",9409:"339f5afb",9715:"21ca1afa",9729:"812aea5b"}[e]+".js"}}(),function(){s.miniCssF=function(e){return"css/"+e+"."+{188:"37c2c58b",2848:"1051f69d",3455:"3c921dba",3829:"d635162e",4132:"d6d42832",4468:"ce8cf4e6",5024:"c8dbdb62",5360:"cd6ce5d1",7209:"7629a0cd",7855:"f67470a7",7909:"63aad872"}[e]+".css"}}(),function(){s.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}()}(),function(){s.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)}}(),function(){var e={},t="jandl:";s.l=function(a,i,n,l){if(e[a])e[a].push(i);else{var o,r;if(void 0!==n)for(var d=document.getElementsByTagName("script"),c=0;c<d.length;c++){var u=d[c];if(u.getAttribute("src")==a||u.getAttribute("data-webpack")==t+n){o=u;break}}o||(r=!0,o=document.createElement("script"),o.charset="utf-8",o.timeout=120,s.nc&&o.setAttribute("nonce",s.nc),o.setAttribute("data-webpack",t+n),o.src=a),e[a]=[i];var h=function(t,s){o.onerror=o.onload=null,clearTimeout(m);var i=e[a];if(delete e[a],o.parentNode&&o.parentNode.removeChild(o),i&&i.forEach((function(e){return e(s)})),t)return t(s)},m=setTimeout(h.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=h.bind(null,o.onerror),o.onload=h.bind(null,o.onload),r&&document.head.appendChild(o)}}}(),function(){s.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}}(),function(){s.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e}}(),function(){s.p="/"}(),function(){var e=function(e,t,s,a){var i=document.createElement("link");i.rel="stylesheet",i.type="text/css";var n=function(n){if(i.onerror=i.onload=null,"load"===n.type)s();else{var l=n&&("load"===n.type?"missing":n.type),o=n&&n.target&&n.target.href||t,r=new Error("Loading CSS chunk "+e+" failed.\n("+o+")");r.code="CSS_CHUNK_LOAD_FAILED",r.type=l,r.request=o,i.parentNode.removeChild(i),a(r)}};return i.onerror=i.onload=n,i.href=t,document.head.appendChild(i),i},t=function(e,t){for(var s=document.getElementsByTagName("link"),a=0;a<s.length;a++){var i=s[a],n=i.getAttribute("data-href")||i.getAttribute("href");if("stylesheet"===i.rel&&(n===e||n===t))return i}var l=document.getElementsByTagName("style");for(a=0;a<l.length;a++){i=l[a],n=i.getAttribute("data-href");if(n===e||n===t)return i}},a=function(a){return new Promise((function(i,n){var l=s.miniCssF(a),o=s.p+l;if(t(l,o))return i();e(a,o,i,n)}))},i={4826:0};s.f.miniCss=function(e,t){var s={188:1,2848:1,3455:1,3829:1,4132:1,4468:1,5024:1,5360:1,7209:1,7855:1,7909:1};i[e]?t.push(i[e]):0!==i[e]&&s[e]&&t.push(i[e]=a(e).then((function(){i[e]=0}),(function(t){throw delete i[e],t})))}}(),function(){var e={4826:0};s.f.j=function(t,a){var i=s.o(e,t)?e[t]:void 0;if(0!==i)if(i)a.push(i[2]);else{var n=new Promise((function(s,a){i=e[t]=[s,a]}));a.push(i[2]=n);var l=s.p+s.u(t),o=new Error,r=function(a){if(s.o(e,t)&&(i=e[t],0!==i&&(e[t]=void 0),i)){var n=a&&("load"===a.type?"missing":a.type),l=a&&a.target&&a.target.src;o.message="Loading chunk "+t+" failed.\n("+n+": "+l+")",o.name="ChunkLoadError",o.type=n,o.request=l,i[1](o)}};s.l(l,r,"chunk-"+t,t)}},s.O.j=function(t){return 0===e[t]};var t=function(t,a){var i,n,l=a[0],o=a[1],r=a[2],d=0;if(l.some((function(t){return 0!==e[t]}))){for(i in o)s.o(o,i)&&(s.m[i]=o[i]);if(r)var c=r(s)}for(t&&t(a);d<l.length;d++)n=l[d],s.o(e,n)&&e[n]&&e[n][0](),e[n]=0;return s.O(c)},a=self["webpackChunkjandl"]=self["webpackChunkjandl"]||[];a.forEach(t.bind(null,0)),a.push=t.bind(null,a.push.bind(a))}();var a=s.O(void 0,[4998],(function(){return s(40881)}));a=s.O(a)})();
|
||
//# sourceMappingURL=index.bc24d4bc.js.map
|