@ozdao/prometheus-framework 0.2.196 → 0.2.198
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/node_modules/@googlemaps/js-api-loader/dist/index.cjs +1 -1
- package/dist/node_modules/@googlemaps/js-api-loader/dist/index.js +21 -20
- package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.cjs +1 -1
- package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.js +629 -622
- package/dist/node_modules/embla-carousel-vue/esm/embla-carousel-vue.esm.cjs +1 -1
- package/dist/node_modules/embla-carousel-vue/esm/embla-carousel-vue.esm.js +19 -17
- package/dist/node_modules/qrcode/lib/core/byte-data.cjs +1 -1
- package/dist/node_modules/qrcode/lib/core/byte-data.js +6 -7
- package/dist/node_modules/vue-qrcode-reader/dist/vue-qrcode-reader.cjs +1 -1
- package/dist/node_modules/vue-qrcode-reader/dist/vue-qrcode-reader.js +3 -3
- package/dist/prometheus-framework/node_modules/@vuepic/vue-datepicker/dist/vue-datepicker.cjs +1 -1
- package/dist/prometheus-framework/node_modules/@vuepic/vue-datepicker/dist/vue-datepicker.js +3356 -3363
- package/dist/prometheus-framework/node_modules/libphonenumber-js/metadata.min.json.cjs +1 -1
- package/dist/prometheus-framework/node_modules/libphonenumber-js/metadata.min.json.js +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.cjs +1 -1
- package/dist/prometheus-framework/src/modules/constructor/components/elements/Textarea.vue2.js +17 -17
- package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +11 -11
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/globals/views/components/layouts/Client.vue.js +46 -44
- package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.js +31 -31
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
- package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +1 -1
- package/dist/prometheus-framework.cjs.js +27 -27
- package/dist/prometheus-framework.es.js +2528 -2518
- package/dist/style.css +1 -1
- package/package.json +25 -25
- package/src/modules/globals/views/components/layouts/Client.vue +4 -3
package/dist/prometheus-framework/node_modules/@vuepic/vue-datepicker/dist/vue-datepicker.cjs
CHANGED
@@ -1 +1 @@
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),ue=require("../../../date-fns/getYear.cjs"),ce=require("../../../date-fns/getMonth.cjs"),rl=require("../../../date-fns/getDay.cjs"),$t=require("../../../date-fns/eachDayOfInterval.cjs"),ol=require("../../../date-fns/differenceInCalendarDays.cjs"),ze=require("../../../date-fns/format.cjs"),fe=require("../../../date-fns/set.cjs"),ul=require("../../../date-fns/startOfMonth.cjs"),ga=require("../../../date-fns/isBefore.cjs"),ua=require("../../../date-fns/isEqual.cjs"),ia=require("../../../date-fns/isAfter.cjs"),Aa=require("../../../date-fns/isValid.cjs"),il=require("../../../date-fns/addHours.cjs"),He=require("../../../date-fns/getHours.cjs"),Xe=require("../../../date-fns/getMinutes.cjs"),sa=require("../../../date-fns/getSeconds.cjs"),Ie=require("../../../date-fns/setYear.cjs"),xa=require("../../../date-fns/startOfYear.cjs"),Tt=require("../../../date-fns/add.cjs"),ta=require("../../../date-fns/addMonths.cjs"),nt=require("../../../date-fns/startOfWeek.cjs"),Nt=require("../../../date-fns/endOfWeek.cjs"),gt=require("../../../date-fns/isSameQuarter.cjs"),sl=require("../../../date-fns/eachQuarterOfInterval.cjs"),Pt=require("../../../date-fns/endOfYear.cjs"),dl=require("../../../date-fns/startOfQuarter.cjs"),kt=require("../../../date-fns/endOfQuarter.cjs"),at=require("../../../date-fns/parse.cjs"),ka=require("../../../date-fns/subMonths.cjs"),bt=require("../../../date-fns/getQuarter.cjs"),cl=require("../../../date-fns/setHours.cjs"),ml=require("../../../date-fns/setMinutes.cjs"),Vt=require("../../../date-fns/setSeconds.cjs"),Et=require("../../../date-fns/setMilliseconds.cjs"),vl=require("../../../date-fns/setMonth.cjs"),pl=require("../../../date-fns/getWeek.cjs"),fl=require("../../../date-fns/getISOWeek.cjs"),aa=require("../../../date-fns/addDays.cjs"),yl=require("../../../date-fns/isDate.cjs"),Rt=require("../../../date-fns/addYears.cjs"),Ot=require("../../../date-fns/subYears.cjs"),hl=require("../../../date-fns/sub.cjs"),gl=require("../../../date-fns/differenceInYears.cjs");function ma(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M29.333 8c0-2.208-1.792-4-4-4h-18.667c-2.208 0-4 1.792-4 4v18.667c0 2.208 1.792 4 4 4h18.667c2.208 0 4-1.792 4-4v-18.667zM26.667 8v18.667c0 0.736-0.597 1.333-1.333 1.333 0 0-18.667 0-18.667 0-0.736 0-1.333-0.597-1.333-1.333 0 0 0-18.667 0-18.667 0-0.736 0.597-1.333 1.333-1.333 0 0 18.667 0 18.667 0 0.736 0 1.333 0.597 1.333 1.333z"}),e.createElementVNode("path",{d:"M20 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),e.createElementVNode("path",{d:"M9.333 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),e.createElementVNode("path",{d:"M4 14.667h24c0.736 0 1.333-0.597 1.333-1.333s-0.597-1.333-1.333-1.333h-24c-0.736 0-1.333 0.597-1.333 1.333s0.597 1.333 1.333 1.333z"})])}ma.compatConfig={MODE:3};function Yt(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M23.057 7.057l-16 16c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l16-16c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0z"}),e.createElementVNode("path",{d:"M7.057 8.943l16 16c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885l-16-16c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}Yt.compatConfig={MODE:3};function rt(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M20.943 23.057l-7.057-7.057c0 0 7.057-7.057 7.057-7.057 0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-8 8c-0.521 0.521-0.521 1.365 0 1.885l8 8c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}rt.compatConfig={MODE:3};function ot(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M12.943 24.943l8-8c0.521-0.521 0.521-1.365 0-1.885l-8-8c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885l7.057 7.057c0 0-7.057 7.057-7.057 7.057-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0z"})])}ot.compatConfig={MODE:3};function ut(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M16 1.333c-8.095 0-14.667 6.572-14.667 14.667s6.572 14.667 14.667 14.667c8.095 0 14.667-6.572 14.667-14.667s-6.572-14.667-14.667-14.667zM16 4c6.623 0 12 5.377 12 12s-5.377 12-12 12c-6.623 0-12-5.377-12-12s5.377-12 12-12z"}),e.createElementVNode("path",{d:"M14.667 8v8c0 0.505 0.285 0.967 0.737 1.193l5.333 2.667c0.658 0.329 1.46 0.062 1.789-0.596s0.062-1.46-0.596-1.789l-4.596-2.298c0 0 0-7.176 0-7.176 0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"})])}ut.compatConfig={MODE:3};function it(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M24.943 19.057l-8-8c-0.521-0.521-1.365-0.521-1.885 0l-8 8c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l7.057-7.057c0 0 7.057 7.057 7.057 7.057 0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}it.compatConfig={MODE:3};function st(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[e.createElementVNode("path",{d:"M7.057 12.943l8 8c0.521 0.521 1.365 0.521 1.885 0l8-8c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-7.057 7.057c0 0-7.057-7.057-7.057-7.057-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}st.compatConfig={MODE:3};const Pe=(a,t)=>t?new Date(a.toLocaleString("en-US",{timeZone:t})):new Date(a),dt=(a,t,r)=>tt(a,t,r)||I(),kl=(a,t,r)=>{const n=t.dateInTz?Pe(new Date(a),t.dateInTz):I(a);return r?Ae(n,!0):n},tt=(a,t,r)=>{if(!a)return null;const n=r?Ae(I(a),!0):I(a);return t?t.exactMatch?kl(a,t,r):Pe(n,t.timezone):n},bl=a=>{if(!a)return 0;const t=new Date,r=new Date(t.toLocaleString("en-US",{timeZone:"UTC"})),n=new Date(t.toLocaleString("en-US",{timeZone:a})),l=n.getTimezoneOffset()/60;return(+r-+n)/(1e3*60*60)-l};var Ee=(a=>(a.month="month",a.year="year",a))(Ee||{}),ea=(a=>(a.top="top",a.bottom="bottom",a))(ea||{}),la=(a=>(a.header="header",a.calendar="calendar",a.timePicker="timePicker",a))(la||{}),Be=(a=>(a.month="month",a.year="year",a.calendar="calendar",a.time="time",a.minutes="minutes",a.hours="hours",a.seconds="seconds",a))(Be||{});const _l=["timestamp","date","iso"];var Me=(a=>(a.up="up",a.down="down",a.left="left",a.right="right",a))(Me||{}),he=(a=>(a.arrowUp="ArrowUp",a.arrowDown="ArrowDown",a.arrowLeft="ArrowLeft",a.arrowRight="ArrowRight",a.enter="Enter",a.space=" ",a.esc="Escape",a.tab="Tab",a.home="Home",a.end="End",a.pageUp="PageUp",a.pageDown="PageDown",a))(he||{});function _t(a){return t=>new Intl.DateTimeFormat(a,{weekday:"short",timeZone:"UTC"}).format(new Date(`2017-01-0${t}T00:00:00+00:00`)).slice(0,2)}function wl(a){return t=>ze.formatDate(new Date(`2017-01-0${t}T00:00:00+00:00`),"EEEEEE",{locale:a})}const Cl=(a,t,r)=>{const n=[1,2,3,4,5,6,7];let l;if(a!==null)try{l=n.map(wl(a))}catch{l=n.map(_t(t))}else l=n.map(_t(t));const m=l.slice(0,r),v=l.slice(r+1,l.length);return[l[r]].concat(...v).concat(...m)},ct=(a,t,r)=>{const n=[];for(let l=+a[0];l<=+a[1];l++)n.push({value:+l,text:Lt(l,t)});return r?n.reverse():n},It=(a,t,r)=>{const n=[1,2,3,4,5,6,7,8,9,10,11,12].map(m=>{const v=m<10?`0${m}`:m;return new Date(`2017-${v}-01T00:00:00+00:00`)});if(a!==null)try{const m=r==="long"?"LLLL":"LLL";return n.map((v,k)=>{const c=ze.formatDate(Pe(v,"UTC"),m,{locale:a});return{text:c.charAt(0).toUpperCase()+c.substring(1),value:k}})}catch{}const l=new Intl.DateTimeFormat(t,{month:r,timeZone:"UTC"});return n.map((m,v)=>{const k=l.format(m);return{text:k.charAt(0).toUpperCase()+k.substring(1),value:v}})},Sl=a=>[12,1,2,3,4,5,6,7,8,9,10,11,12,1,2,3,4,5,6,7,8,9,10,11][a],we=a=>{const t=e.unref(a);return t!=null&&t.$el?t==null?void 0:t.$el:t},Bl=a=>({type:"dot",...a??{}}),zt=a=>Array.isArray(a)?!!a[0]&&!!a[1]:!1,mt={prop:a=>`"${a}" prop must be enabled!`,dateArr:a=>`You need to use array as "model-value" binding in order to support "${a}"`},Ce=a=>a,wt=a=>a===0?a:!a||isNaN(+a)?null:+a,Ct=a=>a===null,Ft=a=>{if(a)return[...a.querySelectorAll("input, button, select, textarea, a[href]")][0]},Dl=a=>{const t=[],r=n=>n.filter(l=>l);for(let n=0;n<a.length;n+=3){const l=[a[n],a[n+1],a[n+2]];t.push(r(l))}return t},ba=(a,t,r)=>{const n=r!=null,l=t!=null;if(!n&&!l)return!1;const m=+r,v=+t;return n&&l?+a>m||+a<v:n?+a>m:l?+a<v:!1},da=(a,t)=>Dl(a).map(r=>r.map(n=>{const{active:l,disabled:m,isBetween:v,highlighted:k}=t(n);return{...n,active:l,disabled:m,className:{dp__overlay_cell_active:l,dp__overlay_cell:!l,dp__overlay_cell_disabled:m,dp__overlay_cell_pad:!0,dp__overlay_cell_active_disabled:m&&l,dp__cell_in_between:v,"dp--highlighted":k}}})),Je=(a,t,r=!1)=>{a&&t.allowStopPropagation&&(r&&a.stopImmediatePropagation(),a.stopPropagation())},Ml=()=>["a[href]","area[href]","input:not([disabled]):not([type='hidden'])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","[tabindex]:not([tabindex='-1'])","[data-datepicker-instance]"].join(", ");function Al(a,t){let r=[...document.querySelectorAll(Ml())];r=r.filter(l=>!a.contains(l)||l.hasAttribute("data-datepicker-instance"));const n=r.indexOf(a);if(n>=0&&(t?n-1>=0:n+1<=r.length))return r[n+(t?-1:1)]}const xl=(a,t)=>a==null?void 0:a.querySelector(`[data-dp-element="${t}"]`),Lt=(a,t)=>new Intl.NumberFormat(t,{useGrouping:!1,style:"decimal"}).format(a),vt=a=>ze.formatDate(a,"dd-MM-yyyy"),qa=a=>Array.isArray(a),$a=(a,t)=>t.get(vt(a)),$l=(a,t)=>a?t?t instanceof Map?!!$a(a,t):t(I(a)):!1:!0,$e=(a,t,r=!1)=>{if(a.key===he.enter||a.key===he.space)return r&&a.preventDefault(),t()},St=(a,t,r,n,l,m)=>{const v=at.parse(a,t.slice(0,a.length),new Date,{locale:m});return Aa.isValid(v)&&yl.isDate(v)?n||l?v:fe.set(v,{hours:+r.hours,minutes:+(r==null?void 0:r.minutes),seconds:+(r==null?void 0:r.seconds),milliseconds:0}):null},Tl=(a,t,r,n,l,m)=>{const v=Array.isArray(r)?r[0]:r;if(typeof t=="string")return St(a,t,v,n,l,m);if(Array.isArray(t)){let k=null;for(const c of t)if(k=St(a,c,v,n,l,m),k)break;return k}return typeof t=="function"?t(a):null},I=a=>a?new Date(a):new Date,Nl=(a,t,r)=>{if(t){const l=(a.getMonth()+1).toString().padStart(2,"0"),m=a.getDate().toString().padStart(2,"0"),v=a.getHours().toString().padStart(2,"0"),k=a.getMinutes().toString().padStart(2,"0"),c=r?a.getSeconds().toString().padStart(2,"0"):"00";return`${a.getFullYear()}-${l}-${m}T${v}:${k}:${c}.000Z`}const n=Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate(),a.getUTCHours(),a.getUTCMinutes(),a.getUTCSeconds());return new Date(n).toISOString()},Ae=(a,t)=>{const r=I(JSON.parse(JSON.stringify(a))),n=fe.set(r,{hours:0,minutes:0,seconds:0,milliseconds:0});return t?ul.startOfMonth(n):n},Qe=(a,t,r,n)=>{let l=a?I(a):I();return(t||t===0)&&(l=cl.setHours(l,+t)),(r||r===0)&&(l=ml.setMinutes(l,+r)),(n||n===0)&&(l=Vt.setSeconds(l,+n)),Et.setMilliseconds(l,0)},ke=(a,t)=>!a||!t?!1:ga.isBefore(Ae(a),Ae(t)),ve=(a,t)=>!a||!t?!1:ua.isEqual(Ae(a),Ae(t)),_e=(a,t)=>!a||!t?!1:ia.isAfter(Ae(a),Ae(t)),Ta=(a,t,r)=>a!=null&&a[0]&&a!=null&&a[1]?_e(r,a[0])&&ke(r,a[1]):a!=null&&a[0]&&t?_e(r,a[0])&&ke(r,t)||ke(r,a[0])&&_e(r,t):!1,Re=a=>{const t=fe.set(new Date(a),{date:1});return Ae(t)},Ua=(a,t,r)=>t&&(r||r===0)?Object.fromEntries(["hours","minutes","seconds"].map(n=>n===t?[n,r]:[n,isNaN(+a[n])?void 0:+a[n]])):{hours:isNaN(+a.hours)?void 0:+a.hours,minutes:isNaN(+a.minutes)?void 0:+a.minutes,seconds:isNaN(+a.seconds)?void 0:+a.seconds},na=a=>({hours:He.getHours(a),minutes:Xe.getMinutes(a),seconds:sa.getSeconds(a)}),Ht=(a,t)=>{if(t){const r=ue.getYear(I(t));if(r>a)return 12;if(r===a)return ce.getMonth(I(t))}},qt=(a,t)=>{if(t){const r=ue.getYear(I(t));return r<a?-1:r===a?ce.getMonth(I(t)):void 0}},ca=a=>{if(a)return ue.getYear(I(a))},Ut=(a,t)=>{const r=_e(a,t)?t:a,n=_e(t,a)?t:a;return $t.eachDayOfInterval({start:r,end:n})},Pl=a=>{const t=ta.addMonths(a,1);return{month:ce.getMonth(t),year:ue.getYear(t)}},Fe=(a,t)=>{const r=nt.startOfWeek(a,{weekStartsOn:+t}),n=Nt.endOfWeek(a,{weekStartsOn:+t});return[r,n]},jt=(a,t)=>{const r={hours:He.getHours(I()),minutes:Xe.getMinutes(I()),seconds:t?sa.getSeconds(I()):0};return Object.assign(r,a)},Ke=(a,t,r)=>[fe.set(I(a),{date:1}),fe.set(I(),{month:t,year:r,date:1})],Le=(a,t,r)=>{let n=a?I(a):I();return(t||t===0)&&(n=vl.setMonth(n,t)),r&&(n=Ie.setYear(n,r)),n},Kt=(a,t,r,n,l)=>{if(!n||l&&!t||!l&&!r)return!1;const m=l?ta.addMonths(a,1):ka.subMonths(a,1),v=[ce.getMonth(m),ue.getYear(m)];return l?!El(...v,t):!Vl(...v,r)},Vl=(a,t,r)=>ke(...Ke(r,a,t))||ve(...Ke(r,a,t)),El=(a,t,r)=>_e(...Ke(r,a,t))||ve(...Ke(r,a,t)),Jt=(a,t,r,n,l,m,v)=>{if(typeof t=="function"&&!v)return t(a);const k=r?{locale:r}:void 0;return Array.isArray(a)?`${ze.formatDate(a[0],m,k)}${l&&!a[1]?"":n}${a[1]?ze.formatDate(a[1],m,k):""}`:ze.formatDate(a,m,k)},ra=a=>{if(a)return null;throw new Error(mt.prop("partial-range"))},Da=(a,t)=>{if(t)return a();throw new Error(mt.prop("range"))},lt=a=>Array.isArray(a)?Aa.isValid(a[0])&&(a[1]?Aa.isValid(a[1]):!0):a?Aa.isValid(a):!1,Rl=(a,t)=>fe.set(t??I(),{hours:+a.hours||0,minutes:+a.minutes||0,seconds:+a.seconds||0}),ja=(a,t,r,n)=>{if(!a)return!0;if(n){const l=r==="max"?ga.isBefore(a,t):ia.isAfter(a,t),m={seconds:0,milliseconds:0};return l||ua.isEqual(fe.set(a,m),fe.set(t,m))}return r==="max"?a.getTime()<=t.getTime():a.getTime()>=t.getTime()},Ka=(a,t,r)=>a?Rl(a,t):I(r??t),Bt=(a,t,r,n,l)=>{if(Array.isArray(n)){const v=Ka(a,n[0],t),k=Ka(a,n[1],t);return ja(n[0],v,r,!!t)&&ja(n[1],k,r,!!t)&&l}const m=Ka(a,n,t);return ja(n,m,r,!!t)&&l},Ja=a=>fe.set(I(),na(a)),Ol=(a,t)=>a instanceof Map?Array.from(a.values()).filter(r=>ue.getYear(I(r))===t).map(r=>ce.getMonth(r)):[],Qt=(a,t,r)=>typeof a=="function"?a({month:t,year:r}):!!a.months.find(n=>n.month===t&&n.year===r),pt=(a,t)=>typeof a=="function"?a(t):a.years.includes(t),Xt=a=>ze.formatDate(a,"yyyy-MM-dd"),ya=e.reactive({menuFocused:!1,shiftKeyInMenu:!1}),Wt=()=>{const a=r=>{ya.menuFocused=r},t=r=>{ya.shiftKeyInMenu!==r&&(ya.shiftKeyInMenu=r)};return{control:e.computed(()=>({shiftKeyInMenu:ya.shiftKeyInMenu,menuFocused:ya.menuFocused})),setMenuFocused:a,setShiftKey:t}},ye=e.reactive({monthYear:[],calendar:[],time:[],actionRow:[],selectionGrid:[],timePicker:{0:[],1:[]},monthPicker:[]}),Qa=e.ref(null),Ma=e.ref(!1),Xa=e.ref(!1),Wa=e.ref(!1),Ga=e.ref(!1),Se=e.ref(0),be=e.ref(0),We=()=>{const a=e.computed(()=>Ma.value?[...ye.selectionGrid,ye.actionRow].filter(h=>h.length):Xa.value?[...ye.timePicker[0],...ye.timePicker[1],Ga.value?[]:[Qa.value],ye.actionRow].filter(h=>h.length):Wa.value?[...ye.monthPicker,ye.actionRow]:[ye.monthYear,...ye.calendar,ye.time,ye.actionRow].filter(h=>h.length)),t=h=>{Se.value=h?Se.value+1:Se.value-1;let y=null;a.value[be.value]&&(y=a.value[be.value][Se.value]),!y&&a.value[be.value+(h?1:-1)]?(be.value=be.value+(h?1:-1),Se.value=h?0:a.value[be.value].length-1):y||(Se.value=h?Se.value-1:Se.value+1)},r=h=>{be.value===0&&!h||be.value===a.value.length&&h||(be.value=h?be.value+1:be.value-1,a.value[be.value]?a.value[be.value]&&!a.value[be.value][Se.value]&&Se.value!==0&&(Se.value=a.value[be.value].length-1):be.value=h?be.value-1:be.value+1)},n=h=>{let y=null;a.value[be.value]&&(y=a.value[be.value][Se.value]),y?y.focus({preventScroll:!Ma.value}):Se.value=h?Se.value-1:Se.value+1},l=()=>{t(!0),n(!0)},m=()=>{t(!1),n(!1)},v=()=>{r(!1),n(!0)},k=()=>{r(!0),n(!0)},c=(h,y)=>{ye[y]=h},O=(h,y)=>{ye[y]=h},f=()=>{Se.value=0,be.value=0};return{buildMatrix:c,buildMultiLevelMatrix:O,setTimePickerBackRef:h=>{Qa.value=h},setSelectionGrid:h=>{Ma.value=h,f(),h||(ye.selectionGrid=[])},setTimePicker:(h,y=!1)=>{Xa.value=h,Ga.value=y,f(),h||(ye.timePicker[0]=[],ye.timePicker[1]=[])},setTimePickerElements:(h,y=0)=>{ye.timePicker[y]=h},arrowRight:l,arrowLeft:m,arrowUp:v,arrowDown:k,clearArrowNav:()=>{ye.monthYear=[],ye.calendar=[],ye.time=[],ye.actionRow=[],ye.selectionGrid=[],ye.timePicker[0]=[],ye.timePicker[1]=[],Ma.value=!1,Xa.value=!1,Ga.value=!1,Wa.value=!1,f(),Qa.value=null},setMonthPicker:h=>{Wa.value=h,f()},refSets:ye}},Dt=a=>({menuAppearTop:"dp-menu-appear-top",menuAppearBottom:"dp-menu-appear-bottom",open:"dp-slide-down",close:"dp-slide-up",next:"calendar-next",previous:"calendar-prev",vNext:"dp-slide-up",vPrevious:"dp-slide-down",...a??{}}),Yl=a=>({toggleOverlay:"Toggle overlay",menu:"Datepicker menu",input:"Datepicker input",calendarWrap:"Calendar wrapper",calendarDays:"Calendar days",openTimePicker:"Open time picker",closeTimePicker:"Close time Picker",incrementValue:t=>`Increment ${t}`,decrementValue:t=>`Decrement ${t}`,openTpOverlay:t=>`Open ${t} overlay`,amPmButton:"Switch AM/PM mode",openYearsOverlay:"Open years overlay",openMonthsOverlay:"Open months overlay",nextMonth:"Next month",prevMonth:"Previous month",nextYear:"Next year",prevYear:"Previous year",day:void 0,weekDay:void 0,...a??{}}),Mt=a=>a?typeof a=="boolean"?a?2:0:+a>=2?+a:2:0,Il=a=>{const t=typeof a=="object"&&a,r={static:!0,solo:!1};if(!a)return{...r,count:Mt(!1)};const n=t?a:{},l=t?n.count??!0:a,m=Mt(l);return Object.assign(r,n,{count:m})},zl=(a,t,r)=>a||(typeof r=="string"?r:t),Fl=a=>typeof a=="boolean"?a?Dt({}):!1:Dt(a),Ll=a=>{const t={enterSubmit:!0,tabSubmit:!0,openMenu:!0,selectOnFocus:!1,rangeSeparator:" - "};return typeof a=="object"?{...t,...a??{},enabled:!0}:{...t,enabled:a}},Hl=a=>({months:[],years:[],times:{hours:[],minutes:[],seconds:[]},...a??{}}),ql=a=>({showSelect:!0,showCancel:!0,showNow:!1,showPreview:!0,...a??{}}),Ul=a=>{const t={input:!1};return typeof a=="object"?{...t,...a??{},enabled:!0}:{enabled:a,...t}},jl=a=>({allowStopPropagation:!0,closeOnScroll:!1,modeHeight:255,allowPreventDefault:!1,closeOnClearValue:!0,closeOnAutoApply:!0,noSwipe:!1,keepActionRow:!1,onClickOutside:void 0,tabOutClosesMenu:!0,arrowLeft:void 0,keepViewOnOffsetClick:!1,timeArrowHoldThreshold:0,...a??{}}),Kl=a=>{const t={dates:Array.isArray(a)?a.map(r=>I(r)):[],years:[],months:[],quarters:[],weeks:[],weekdays:[],options:{highlightDisabled:!1}};return typeof a=="function"?a:{...t,...a??{}}},Jl=a=>typeof a=="object"?{type:(a==null?void 0:a.type)??"local",hideOnOffsetDates:(a==null?void 0:a.hideOnOffsetDates)??!1}:{type:a,hideOnOffsetDates:!1},Ql=(a,t)=>typeof a=="object"?{enabled:!0,...{noDisabledRange:!1,showLastInRange:!0,minMaxRawRange:!1,partialRange:!0,disableTimeRangeValidation:!1,maxRange:void 0,minRange:void 0,autoRange:void 0,fixedStart:!1,fixedEnd:!1},...a}:{enabled:a,noDisabledRange:t.noDisabledRange,showLastInRange:t.showLastInRange,minMaxRawRange:t.minMaxRawRange,partialRange:t.partialRange,disableTimeRangeValidation:t.disableTimeRangeValidation,maxRange:t.maxRange,minRange:t.minRange,autoRange:t.autoRange,fixedStart:t.fixedStart,fixedEnd:t.fixedEnd},Xl=(a,t)=>a?typeof a=="string"?{timezone:a,exactMatch:!1,dateInTz:void 0,emitTimezone:t,convertModel:!0}:{timezone:a.timezone,exactMatch:a.exactMatch??!1,dateInTz:a.dateInTz??void 0,emitTimezone:t??a.emitTimezone,convertModel:a.convertModel??!0}:{timezone:void 0,exactMatch:!1,emitTimezone:t},Za=(a,t,r)=>new Map(a.map(n=>{const l=dt(n,t,r);return[vt(l),l]})),Wl=(a,t)=>a.length?new Map(a.map(r=>{const n=dt(r.date,t);return[vt(n),r]})):null,Gl=a=>{var t;return{minDate:tt(a.minDate,a.timezone,a.isSpecific),maxDate:tt(a.maxDate,a.timezone,a.isSpecific),disabledDates:qa(a.disabledDates)?Za(a.disabledDates,a.timezone,a.isSpecific):a.disabledDates,allowedDates:qa(a.allowedDates)?Za(a.allowedDates,a.timezone,a.isSpecific):null,highlight:typeof a.highlight=="object"&&qa((t=a.highlight)==null?void 0:t.dates)?Za(a.highlight.dates,a.timezone):a.highlight,markers:Wl(a.markers,a.timezone)}},Zl=(a,t)=>typeof a=="boolean"?{enabled:a,dragSelect:!0,limit:+t}:{enabled:!!a,limit:a.limit?+a.limit:null,dragSelect:a.dragSelect??!0},en=a=>({...Object.fromEntries(Object.keys(a).map(t=>{const r=t,n=a[r],l=typeof a[r]=="string"?{[n]:!0}:Object.fromEntries(n.map(m=>[m,!0]));return[t,l]}))}),ge=a=>{const t=()=>{const T=a.enableSeconds?":ss":"",A=a.enableMinutes?":mm":"";return a.is24?`HH${A}${T}`:`hh${A}${T} aa`},r=()=>{var T;return a.format?a.format:a.monthPicker?"MM/yyyy":a.timePicker?t():a.weekPicker?`${((T=V.value)==null?void 0:T.type)==="iso"?"RR":"ww"}-yyyy`:a.yearPicker?"yyyy":a.quarterPicker?"QQQ/yyyy":a.enableTimePicker?`MM/dd/yyyy, ${t()}`:"MM/dd/yyyy"},n=T=>jt(T,a.enableSeconds),l=()=>F.value.enabled?a.startTime&&Array.isArray(a.startTime)?[n(a.startTime[0]),n(a.startTime[1])]:null:a.startTime&&!Array.isArray(a.startTime)?n(a.startTime):null,m=e.computed(()=>Il(a.multiCalendars)),v=e.computed(()=>l()),k=e.computed(()=>Yl(a.ariaLabels)),c=e.computed(()=>Hl(a.filters)),O=e.computed(()=>Fl(a.transitions)),f=e.computed(()=>ql(a.actionRow)),h=e.computed(()=>zl(a.previewFormat,a.format,r())),y=e.computed(()=>Ll(a.textInput)),C=e.computed(()=>Ul(a.inline)),$=e.computed(()=>jl(a.config)),_=e.computed(()=>Kl(a.highlight)),V=e.computed(()=>Jl(a.weekNumbers)),L=e.computed(()=>Xl(a.timezone,a.emitTimezone)),J=e.computed(()=>Zl(a.multiDates,a.multiDatesLimit)),D=e.computed(()=>Gl({minDate:a.minDate,maxDate:a.maxDate,disabledDates:a.disabledDates,allowedDates:a.allowedDates,highlight:_.value,markers:a.markers,timezone:L.value,isSpecific:a.monthPicker||a.yearPicker||a.quarterPicker})),F=e.computed(()=>Ql(a.range,{minMaxRawRange:!1,maxRange:a.maxRange,minRange:a.minRange,noDisabledRange:a.noDisabledRange,showLastInRange:a.showLastInRange,partialRange:a.partialRange,disableTimeRangeValidation:a.disableTimeRangeValidation,autoRange:a.autoRange,fixedStart:a.fixedStart,fixedEnd:a.fixedEnd})),K=e.computed(()=>en(a.ui));return{defaultedTransitions:O,defaultedMultiCalendars:m,defaultedStartTime:v,defaultedAriaLabels:k,defaultedFilters:c,defaultedActionRow:f,defaultedPreviewFormat:h,defaultedTextInput:y,defaultedInline:C,defaultedConfig:$,defaultedHighlight:_,defaultedWeekNumbers:V,defaultedRange:F,propDates:D,defaultedTz:L,defaultedMultiDates:J,defaultedUI:K,getDefaultPattern:r,getDefaultStartTime:l}},an=(a,t,r)=>{const n=e.ref(),{defaultedTextInput:l,defaultedRange:m,defaultedTz:v,defaultedMultiDates:k,getDefaultPattern:c}=ge(t),O=e.ref(""),f=e.toRef(t,"format"),h=e.toRef(t,"formatLocale");e.watch(n,()=>{typeof t.onInternalModelChange=="function"&&a("internal-model-change",n.value,G(!0))},{deep:!0}),e.watch(m,(d,ee)=>{d.enabled!==ee.enabled&&(n.value=null)}),e.watch(f,()=>{Y()});const y=d=>v.value.timezone&&v.value.convertModel?Pe(d,v.value.timezone):d,C=d=>{if(v.value.timezone&&v.value.convertModel){const ee=bl(v.value.timezone);return il.addHours(d,ee)}return d},$=(d,ee,se=!1)=>Jt(d,t.format,t.formatLocale,l.value.rangeSeparator,t.modelAuto,ee??c(),se),_=d=>d?t.modelType?te(d):{hours:He.getHours(d),minutes:Xe.getMinutes(d),seconds:t.enableSeconds?sa.getSeconds(d):0}:null,V=d=>t.modelType?te(d):{month:ce.getMonth(d),year:ue.getYear(d)},L=d=>Array.isArray(d)?k.value.enabled?d.map(ee=>J(ee,Ie.setYear(I(),ee))):Da(()=>[Ie.setYear(I(),d[0]),d[1]?Ie.setYear(I(),d[1]):ra(m.value.partialRange)],m.value.enabled):Ie.setYear(I(),+d),J=(d,ee)=>(typeof d=="string"||typeof d=="number")&&t.modelType?X(d):ee,D=d=>Array.isArray(d)?[J(d[0],Qe(null,+d[0].hours,+d[0].minutes,d[0].seconds)),J(d[1],Qe(null,+d[1].hours,+d[1].minutes,d[1].seconds))]:J(d,Qe(null,d.hours,d.minutes,d.seconds)),F=d=>{const ee=fe.set(I(),{date:1});return Array.isArray(d)?k.value.enabled?d.map(se=>J(se,Le(ee,+se.month,+se.year))):Da(()=>[J(d[0],Le(ee,+d[0].month,+d[0].year)),J(d[1],d[1]?Le(ee,+d[1].month,+d[1].year):ra(m.value.partialRange))],m.value.enabled):J(d,Le(ee,+d.month,+d.year))},K=d=>{if(Array.isArray(d))return d.map(ee=>X(ee));throw new Error(mt.dateArr("multi-dates"))},T=d=>{if(Array.isArray(d)&&m.value.enabled){const ee=d[0],se=d[1];return[I(Array.isArray(ee)?ee[0]:null),I(Array.isArray(se)?se[0]:null)]}return I(d[0])},A=d=>t.modelAuto?Array.isArray(d)?[X(d[0]),X(d[1])]:t.autoApply?[X(d)]:[X(d),null]:Array.isArray(d)?Da(()=>d[1]?[X(d[0]),d[1]?X(d[1]):ra(m.value.partialRange)]:[X(d[0])],m.value.enabled):X(d),Z=()=>{Array.isArray(n.value)&&m.value.enabled&&n.value.length===1&&n.value.push(ra(m.value.partialRange))},H=()=>{const d=n.value;return[te(d[0]),d[1]?te(d[1]):ra(m.value.partialRange)]},N=()=>n.value[1]?H():te(Ce(n.value[0])),W=()=>(n.value||[]).map(d=>te(d)),le=(d=!1)=>(d||Z(),t.modelAuto?N():k.value.enabled?W():Array.isArray(n.value)?Da(()=>H(),m.value.enabled):te(Ce(n.value))),re=d=>!d||Array.isArray(d)&&!d.length?null:t.timePicker?D(Ce(d)):t.monthPicker?F(Ce(d)):t.yearPicker?L(Ce(d)):k.value.enabled?K(Ce(d)):t.weekPicker?T(Ce(d)):A(Ce(d)),M=d=>{const ee=re(d);lt(Ce(ee))?(n.value=Ce(ee),Y()):(n.value=null,O.value="")},s=()=>{const d=ee=>ze.formatDate(ee,l.value.format);return`${d(n.value[0])} ${l.value.rangeSeparator} ${n.value[1]?d(n.value[1]):""}`},w=()=>r.value&&n.value?Array.isArray(n.value)?s():ze.formatDate(n.value,l.value.format):$(n.value),u=()=>n.value?k.value.enabled?n.value.map(d=>$(d)).join("; "):l.value.enabled&&typeof l.value.format=="string"?w():$(n.value):"",Y=()=>{!t.format||typeof t.format=="string"||l.value.enabled&&typeof l.value.format=="string"?O.value=u():O.value=t.format(n.value)},X=d=>{if(t.utc){const ee=new Date(d);return t.utc==="preserve"?new Date(ee.getTime()+ee.getTimezoneOffset()*6e4):ee}return t.modelType?_l.includes(t.modelType)?y(new Date(d)):t.modelType==="format"&&(typeof t.format=="string"||!t.format)?y(at.parse(d,c(),new Date,{locale:h.value})):y(at.parse(d,t.modelType,new Date,{locale:h.value})):y(new Date(d))},te=d=>d?t.utc?Nl(d,t.utc==="preserve",t.enableSeconds):t.modelType?t.modelType==="timestamp"?+C(d):t.modelType==="iso"?C(d).toISOString():t.modelType==="format"&&(typeof t.format=="string"||!t.format)?$(C(d)):$(C(d),t.modelType,!0):C(d):"",oe=(d,ee=!1,se=!1)=>{if(se)return d;if(a("update:model-value",d),v.value.emitTimezone&&ee){const x=Array.isArray(d)?d.map(ie=>Pe(Ce(ie),v.value.emitTimezone)):Pe(Ce(d),v.value.emitTimezone);a("update:model-timezone-value",x)}},p=d=>Array.isArray(n.value)?k.value.enabled?n.value.map(ee=>d(ee)):[d(n.value[0]),n.value[1]?d(n.value[1]):ra(m.value.partialRange)]:d(Ce(n.value)),E=()=>{if(Array.isArray(n.value)){const d=Fe(n.value[0],t.weekStart),ee=n.value[1]?Fe(n.value[1],t.weekStart):[];return[d.map(se=>I(se)),ee.map(se=>I(se))]}return Fe(n.value,t.weekStart).map(d=>I(d))},o=(d,ee)=>oe(Ce(p(d)),!1,ee),B=d=>{const ee=E();return d?ee:a("update:model-value",E())},G=(d=!1)=>(d||Y(),t.monthPicker?o(V,d):t.timePicker?o(_,d):t.yearPicker?o(ue.getYear,d):t.weekPicker?B(d):oe(le(d),!0,d));return{inputValue:O,internalModelValue:n,checkBeforeEmit:()=>n.value?m.value.enabled?m.value.partialRange?n.value.length>=1:n.value.length===2:!!n.value:!1,parseExternalModelValue:M,formatInputValue:Y,emitModelValue:G}},tn=(a,t)=>{const{defaultedFilters:r,propDates:n}=ge(a),{validateMonthYearInRange:l}=Ge(a),m=(f,h)=>{let y=f;return r.value.months.includes(ce.getMonth(y))?(y=h?ta.addMonths(f,1):ka.subMonths(f,1),m(y,h)):y},v=(f,h)=>{let y=f;return r.value.years.includes(ue.getYear(y))?(y=h?Rt.addYears(f,1):Ot.subYears(f,1),v(y,h)):y},k=(f,h=!1)=>{const y=fe.set(I(),{month:a.month,year:a.year});let C=f?ta.addMonths(y,1):ka.subMonths(y,1);a.disableYearSelect&&(C=Ie.setYear(C,a.year));let $=ce.getMonth(C),_=ue.getYear(C);r.value.months.includes($)&&(C=m(C,f),$=ce.getMonth(C),_=ue.getYear(C)),r.value.years.includes(_)&&(C=v(C,f),_=ue.getYear(C)),l($,_,f,a.preventMinMaxNavigation)&&c($,_,h)},c=(f,h,y)=>{t("update-month-year",{month:f,year:h,fromNav:y})},O=e.computed(()=>f=>Kt(fe.set(I(),{month:a.month,year:a.year}),n.value.maxDate,n.value.minDate,a.preventMinMaxNavigation,f));return{handleMonthYearChange:k,isDisabled:O,updateMonthYear:c}},Na={multiCalendars:{type:[Boolean,Number,String,Object],default:void 0},modelValue:{type:[String,Date,Array,Object,Number],default:null},modelType:{type:String,default:null},position:{type:String,default:"center"},dark:{type:Boolean,default:!1},format:{type:[String,Function],default:()=>null},autoPosition:{type:Boolean,default:!0},altPosition:{type:Function,default:null},transitions:{type:[Boolean,Object],default:!0},formatLocale:{type:Object,default:null},utc:{type:[Boolean,String],default:!1},ariaLabels:{type:Object,default:()=>({})},offset:{type:[Number,String],default:10},hideNavigation:{type:Array,default:()=>[]},timezone:{type:[String,Object],default:null},emitTimezone:{type:String,default:null},vertical:{type:Boolean,default:!1},disableMonthYearSelect:{type:Boolean,default:!1},disableYearSelect:{type:Boolean,default:!1},menuClassName:{type:String,default:null},dayClass:{type:Function,default:null},yearRange:{type:Array,default:()=>[1900,2100]},calendarCellClassName:{type:String,default:null},enableTimePicker:{type:Boolean,default:!0},autoApply:{type:Boolean,default:!1},disabledDates:{type:[Array,Function],default:()=>[]},monthNameFormat:{type:String,default:"short"},startDate:{type:[Date,String],default:null},startTime:{type:[Object,Array],default:null},hideOffsetDates:{type:Boolean,default:!1},autoRange:{type:[Number,String],default:null},noToday:{type:Boolean,default:!1},disabledWeekDays:{type:Array,default:()=>[]},allowedDates:{type:Array,default:null},nowButtonLabel:{type:String,default:"Now"},markers:{type:Array,default:()=>[]},escClose:{type:Boolean,default:!0},spaceConfirm:{type:Boolean,default:!0},monthChangeOnArrows:{type:Boolean,default:!0},presetDates:{type:Array,default:()=>[]},flow:{type:Array,default:()=>[]},partialFlow:{type:Boolean,default:!1},preventMinMaxNavigation:{type:Boolean,default:!1},minRange:{type:[Number,String],default:null},maxRange:{type:[Number,String],default:null},multiDatesLimit:{type:[Number,String],default:null},reverseYears:{type:Boolean,default:!1},weekPicker:{type:Boolean,default:!1},filters:{type:Object,default:()=>({})},arrowNavigation:{type:Boolean,default:!1},disableTimeRangeValidation:{type:Boolean,default:!1},highlight:{type:[Function,Object],default:null},teleport:{type:[Boolean,String,Object],default:null},teleportCenter:{type:Boolean,default:!1},locale:{type:String,default:"en-Us"},weekNumName:{type:String,default:"W"},weekStart:{type:[Number,String],default:1},weekNumbers:{type:[String,Function,Object],default:null},calendarClassName:{type:String,default:null},monthChangeOnScroll:{type:[Boolean,String],default:!0},dayNames:{type:[Function,Array],default:null},monthPicker:{type:Boolean,default:!1},customProps:{type:Object,default:null},yearPicker:{type:Boolean,default:!1},modelAuto:{type:Boolean,default:!1},selectText:{type:String,default:"Select"},cancelText:{type:String,default:"Cancel"},previewFormat:{type:[String,Function],default:()=>""},multiDates:{type:[Object,Boolean],default:!1},partialRange:{type:Boolean,default:!0},ignoreTimeValidation:{type:Boolean,default:!1},minDate:{type:[Date,String],default:null},maxDate:{type:[Date,String],default:null},minTime:{type:Object,default:null},maxTime:{type:Object,default:null},name:{type:String,default:null},placeholder:{type:String,default:""},hideInputIcon:{type:Boolean,default:!1},clearable:{type:Boolean,default:!0},state:{type:Boolean,default:null},required:{type:Boolean,default:!1},autocomplete:{type:String,default:"off"},inputClassName:{type:String,default:null},fixedStart:{type:Boolean,default:!1},fixedEnd:{type:Boolean,default:!1},timePicker:{type:Boolean,default:!1},enableSeconds:{type:Boolean,default:!1},is24:{type:Boolean,default:!0},noHoursOverlay:{type:Boolean,default:!1},noMinutesOverlay:{type:Boolean,default:!1},noSecondsOverlay:{type:Boolean,default:!1},hoursGridIncrement:{type:[String,Number],default:1},minutesGridIncrement:{type:[String,Number],default:5},secondsGridIncrement:{type:[String,Number],default:5},hoursIncrement:{type:[Number,String],default:1},minutesIncrement:{type:[Number,String],default:1},secondsIncrement:{type:[Number,String],default:1},range:{type:[Boolean,Object],default:!1},uid:{type:String,default:null},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},inline:{type:[Boolean,Object],default:!1},textInput:{type:[Boolean,Object],default:!1},noDisabledRange:{type:Boolean,default:!1},sixWeeks:{type:[Boolean,String],default:!1},actionRow:{type:Object,default:()=>({})},focusStartDate:{type:Boolean,default:!1},disabledTimes:{type:[Function,Array],default:void 0},showLastInRange:{type:Boolean,default:!0},timePickerInline:{type:Boolean,default:!1},calendar:{type:Function,default:null},config:{type:Object,default:void 0},quarterPicker:{type:Boolean,default:!1},yearFirst:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},onInternalModelChange:{type:[Function,Object],default:null},enableMinutes:{type:Boolean,default:!0},ui:{type:Object,default:()=>({})}},Oe={...Na,shadow:{type:Boolean,default:!1},flowStep:{type:Number,default:0},internalModelValue:{type:[Date,Array],default:null},noOverlayFocus:{type:Boolean,default:!1},collapse:{type:Boolean,default:!1},menuWrapRef:{type:Object,default:null},getInputRect:{type:Function,default:()=>({})},isTextInputDate:{type:Boolean,default:!1}},ln=["title"],nn=["disabled"],rn=e.defineComponent({compatConfig:{MODE:3},__name:"ActionRow",props:{menuMount:{type:Boolean,default:!1},calendarWidth:{type:Number,default:0},...Oe},emits:["close-picker","select-date","select-now","invalid-select"],setup(a,{emit:t}){const r=t,n=a,{defaultedActionRow:l,defaultedPreviewFormat:m,defaultedMultiCalendars:v,defaultedTextInput:k,defaultedInline:c,defaultedRange:O,defaultedMultiDates:f,getDefaultPattern:h}=ge(n),{isTimeValid:y,isMonthValid:C}=Ge(n),{buildMatrix:$}=We(),_=e.ref(null),V=e.ref(null),L=e.ref(!1),J=e.ref({}),D=e.ref(null),F=e.ref(null);e.onMounted(()=>{n.arrowNavigation&&$([we(_),we(V)],"actionRow"),K(),window.addEventListener("resize",K)}),e.onUnmounted(()=>{window.removeEventListener("resize",K)});const K=()=>{L.value=!1,setTimeout(()=>{var s,w;const u=(s=D.value)==null?void 0:s.getBoundingClientRect(),Y=(w=F.value)==null?void 0:w.getBoundingClientRect();u&&Y&&(J.value.maxWidth=`${Y.width-u.width-20}px`),L.value=!0},0)},T=e.computed(()=>O.value.enabled&&!O.value.partialRange&&n.internalModelValue?n.internalModelValue.length===2:!0),A=e.computed(()=>!y.value(n.internalModelValue)||!C.value(n.internalModelValue)||!T.value),Z=()=>{const s=m.value;return n.timePicker||n.monthPicker,s(Ce(n.internalModelValue))},H=()=>{const s=n.internalModelValue;return v.value.count>0?`${N(s[0])} - ${N(s[1])}`:[N(s[0]),N(s[1])]},N=s=>Jt(s,m.value,n.formatLocale,k.value.rangeSeparator,n.modelAuto,h()),W=e.computed(()=>!n.internalModelValue||!n.menuMount?"":typeof m.value=="string"?Array.isArray(n.internalModelValue)?n.internalModelValue.length===2&&n.internalModelValue[1]?H():f.value.enabled?n.internalModelValue.map(s=>`${N(s)}`):n.modelAuto?`${N(n.internalModelValue[0])}`:`${N(n.internalModelValue[0])} -`:N(n.internalModelValue):Z()),le=()=>f.value.enabled?"; ":" - ",re=e.computed(()=>Array.isArray(W.value)?W.value.join(le()):W.value),M=()=>{y.value(n.internalModelValue)&&C.value(n.internalModelValue)&&T.value?r("select-date"):r("invalid-select")};return(s,w)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"actionRowRef",ref:F,class:"dp__action_row"},[s.$slots["action-row"]?e.renderSlot(s.$slots,"action-row",e.normalizeProps(e.mergeProps({key:0},{internalModelValue:s.internalModelValue,disabled:A.value,selectDate:()=>s.$emit("select-date"),closePicker:()=>s.$emit("close-picker")}))):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.unref(l).showPreview?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__selection_preview",title:re.value,style:e.normalizeStyle(J.value)},[s.$slots["action-preview"]&&L.value?e.renderSlot(s.$slots,"action-preview",{key:0,value:s.internalModelValue}):e.createCommentVNode("",!0),!s.$slots["action-preview"]&&L.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(re.value),1)],64)):e.createCommentVNode("",!0)],12,ln)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"actionBtnContainer",ref:D,class:"dp__action_buttons","data-dp-element":"action-row"},[s.$slots["action-buttons"]?e.renderSlot(s.$slots,"action-buttons",{key:0,value:s.internalModelValue}):e.createCommentVNode("",!0),s.$slots["action-buttons"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[!e.unref(c).enabled&&e.unref(l).showCancel?(e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"cancelButtonRef",ref:_,type:"button",class:"dp__action_button dp__action_cancel",onClick:w[0]||(w[0]=u=>s.$emit("close-picker")),onKeydown:w[1]||(w[1]=u=>e.unref($e)(u,()=>s.$emit("close-picker")))},e.toDisplayString(s.cancelText),545)):e.createCommentVNode("",!0),e.unref(l).showNow?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"dp__action_button dp__action_cancel",onClick:w[2]||(w[2]=u=>s.$emit("select-now")),onKeydown:w[3]||(w[3]=u=>e.unref($e)(u,()=>s.$emit("select-now")))},e.toDisplayString(s.nowButtonLabel),33)):e.createCommentVNode("",!0),e.unref(l).showSelect?(e.openBlock(),e.createElementBlock("button",{key:2,ref_key:"selectButtonRef",ref:V,type:"button",class:"dp__action_button dp__action_select",disabled:A.value,"data-test":"select-button",onKeydown:w[4]||(w[4]=u=>e.unref($e)(u,()=>M())),onClick:M},e.toDisplayString(s.selectText),41,nn)):e.createCommentVNode("",!0)],64))],512)],64))],512))}}),on={class:"dp__selection_grid_header"},un=["aria-selected","aria-disabled","data-test","onClick","onKeydown","onMouseover"],sn=["aria-label"],_a=e.defineComponent({__name:"SelectionOverlay",props:{items:{},type:{},isLast:{type:Boolean},arrowNavigation:{type:Boolean},skipButtonRef:{type:Boolean},headerRefs:{},hideNavigation:{},escClose:{type:Boolean},useRelative:{type:Boolean},height:{},textInput:{type:[Boolean,Object]},config:{},noOverlayFocus:{type:Boolean},focusValue:{},menuWrapRef:{},ariaLabels:{}},emits:["selected","toggle","reset-flow","hover-value"],setup(a,{expose:t,emit:r}){const{setSelectionGrid:n,buildMultiLevelMatrix:l,setMonthPicker:m}=We(),v=r,k=a,{defaultedAriaLabels:c,defaultedTextInput:O,defaultedConfig:f}=ge(k),{hideNavigationButtons:h}=Ea(),y=e.ref(!1),C=e.ref(null),$=e.ref(null),_=e.ref([]),V=e.ref(),L=e.ref(null),J=e.ref(0),D=e.ref(null);e.onBeforeUpdate(()=>{C.value=null}),e.onMounted(()=>{e.nextTick().then(()=>W()),k.noOverlayFocus||K(),F(!0)}),e.onUnmounted(()=>F(!1));const F=p=>{var E;k.arrowNavigation&&((E=k.headerRefs)!=null&&E.length?m(p):n(p))},K=()=>{var p;const E=we($);E&&(O.value.enabled||(C.value?(p=C.value)==null||p.focus({preventScroll:!0}):E.focus({preventScroll:!0})),y.value=E.clientHeight<E.scrollHeight)},T=e.computed(()=>({dp__overlay:!0,"dp--overlay-absolute":!k.useRelative,"dp--overlay-relative":k.useRelative})),A=e.computed(()=>k.useRelative?{height:`${k.height}px`,width:"260px"}:void 0),Z=e.computed(()=>({dp__overlay_col:!0})),H=e.computed(()=>({dp__btn:!0,dp__button:!0,dp__overlay_action:!0,dp__over_action_scroll:y.value,dp__button_bottom:k.isLast})),N=e.computed(()=>{var p,E;return{dp__overlay_container:!0,dp__container_flex:((p=k.items)==null?void 0:p.length)<=6,dp__container_block:((E=k.items)==null?void 0:E.length)>6}});e.watch(()=>k.items,()=>W(!1),{deep:!0});const W=(p=!0)=>{e.nextTick().then(()=>{const E=we(C),o=we($),B=we(L),G=we(D),d=B?B.getBoundingClientRect().height:0;o&&(o.getBoundingClientRect().height?J.value=o.getBoundingClientRect().height-d:J.value=f.value.modeHeight-d),E&&G&&p&&(G.scrollTop=E.offsetTop-G.offsetTop-(J.value/2-E.getBoundingClientRect().height)-d)})},le=p=>{p.disabled||v("selected",p.value)},re=()=>{v("toggle"),v("reset-flow")},M=()=>{k.escClose&&re()},s=(p,E,o,B)=>{p&&((E.active||E.value===k.focusValue)&&(C.value=p),k.arrowNavigation&&(Array.isArray(_.value[o])?_.value[o][B]=p:_.value[o]=[p],w()))},w=()=>{var p,E;const o=(p=k.headerRefs)!=null&&p.length?[k.headerRefs].concat(_.value):_.value.concat([k.skipButtonRef?[]:[L.value]]);l(Ce(o),(E=k.headerRefs)!=null&&E.length?"monthPicker":"selectionGrid")},u=p=>{k.arrowNavigation||Je(p,f.value,!0)},Y=p=>{V.value=p,v("hover-value",p)},X=()=>{if(re(),!k.isLast){const p=xl(k.menuWrapRef??null,"action-row");if(p){const E=Ft(p);E==null||E.focus()}}},te=p=>{switch(p.key){case he.esc:return M();case he.arrowLeft:return u(p);case he.arrowRight:return u(p);case he.arrowUp:return u(p);case he.arrowDown:return u(p);default:return}},oe=p=>{if(p.key===he.enter)return re();if(p.key===he.tab)return X()};return t({focusGrid:K}),(p,E)=>{var o;return e.openBlock(),e.createElementBlock("div",{ref_key:"gridWrapRef",ref:$,class:e.normalizeClass(T.value),style:e.normalizeStyle(A.value),role:"dialog",tabindex:"0",onKeydown:te,onClick:E[0]||(E[0]=e.withModifiers(()=>{},["prevent"]))},[e.createElementVNode("div",{ref_key:"containerRef",ref:D,class:e.normalizeClass(N.value),role:"grid",style:e.normalizeStyle({"--dp-overlay-height":`${J.value}px`})},[e.createElementVNode("div",on,[e.renderSlot(p.$slots,"header")]),p.$slots.overlay?e.renderSlot(p.$slots,"overlay",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(p.items,(B,G)=>(e.openBlock(),e.createElementBlock("div",{key:G,class:e.normalizeClass(["dp__overlay_row",{dp__flex_row:p.items.length>=3}]),role:"row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B,(d,ee)=>(e.openBlock(),e.createElementBlock("div",{key:d.value,ref_for:!0,ref:se=>s(se,d,G,ee),role:"gridcell",class:e.normalizeClass(Z.value),"aria-selected":d.active||void 0,"aria-disabled":d.disabled||void 0,tabindex:"0","data-test":d.text,onClick:e.withModifiers(se=>le(d),["prevent"]),onKeydown:se=>e.unref($e)(se,()=>le(d),!0),onMouseover:se=>Y(d.value)},[e.createElementVNode("div",{class:e.normalizeClass(d.className)},[p.$slots.item?e.renderSlot(p.$slots,"item",{key:0,item:d}):e.createCommentVNode("",!0),p.$slots.item?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(d.text),1)],64))],2)],42,un))),128))],2))),128))],6),p.$slots["button-icon"]?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"toggleButton",ref:L,type:"button","aria-label":(o=e.unref(c))==null?void 0:o.toggleOverlay,class:e.normalizeClass(H.value),tabindex:"0",onClick:re,onKeydown:oe},[e.renderSlot(p.$slots,"button-icon")],42,sn)),[[e.vShow,!e.unref(h)(p.hideNavigation,p.type)]]):e.createCommentVNode("",!0)],38)}}}),Pa=e.defineComponent({__name:"InstanceWrap",props:{multiCalendars:{},stretch:{type:Boolean},collapse:{type:Boolean}},setup(a){const t=a,r=e.computed(()=>t.multiCalendars>0?[...Array(t.multiCalendars).keys()]:[0]),n=e.computed(()=>({dp__instance_calendar:t.multiCalendars>0}));return(l,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass({dp__menu_inner:!l.stretch,"dp--menu--inner-stretched":l.stretch,dp__flex_display:l.multiCalendars>0,"dp--flex-display-collapsed":l.collapse})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(v,k)=>(e.openBlock(),e.createElementBlock("div",{key:v,class:e.normalizeClass(n.value)},[e.renderSlot(l.$slots,"default",{instance:v,index:k})],2))),128))],2))}}),dn=["aria-label","aria-disabled"],ha=e.defineComponent({compatConfig:{MODE:3},__name:"ArrowBtn",props:{ariaLabel:{},disabled:{type:Boolean}},emits:["activate","set-ref"],setup(a,{emit:t}){const r=t,n=e.ref(null);return e.onMounted(()=>r("set-ref",n)),(l,m)=>(e.openBlock(),e.createElementBlock("button",{ref_key:"elRef",ref:n,type:"button",class:"dp__btn dp--arrow-btn-nav",tabindex:"0","aria-label":l.ariaLabel,"aria-disabled":l.disabled||void 0,onClick:m[0]||(m[0]=v=>l.$emit("activate")),onKeydown:m[1]||(m[1]=v=>e.unref($e)(v,()=>l.$emit("activate"),!0))},[e.createElementVNode("span",{class:e.normalizeClass(["dp__inner_nav",{dp__inner_nav_disabled:l.disabled}])},[e.renderSlot(l.$slots,"default")],2)],40,dn))}}),cn={class:"dp--year-mode-picker"},mn=["aria-label","data-test"],Gt=e.defineComponent({__name:"YearModePicker",props:{...Oe,showYearPicker:{type:Boolean,default:!1},items:{type:Array,default:()=>[]},instance:{type:Number,default:0},year:{type:Number,default:0},isDisabled:{type:Function,default:()=>!1}},emits:["toggle-year-picker","year-select","handle-year"],setup(a,{emit:t}){const r=t,n=a,{showRightIcon:l,showLeftIcon:m}=Ea(),{defaultedConfig:v,defaultedMultiCalendars:k,defaultedAriaLabels:c,defaultedTransitions:O,defaultedUI:f}=ge(n),{showTransition:h,transitionName:y}=wa(O),C=(V=!1,L)=>{r("toggle-year-picker",{flow:V,show:L})},$=V=>{r("year-select",V)},_=(V=!1)=>{r("handle-year",V)};return(V,L)=>{var J,D,F,K,T;return e.openBlock(),e.createElementBlock("div",cn,[e.unref(m)(e.unref(k),a.instance)?(e.openBlock(),e.createBlock(ha,{key:0,ref:"mpPrevIconRef","aria-label":(J=e.unref(c))==null?void 0:J.prevYear,disabled:a.isDisabled(!1),class:e.normalizeClass((D=e.unref(f))==null?void 0:D.navBtnPrev),onActivate:L[0]||(L[0]=A=>_(!1))},{default:e.withCtx(()=>[V.$slots["arrow-left"]?e.renderSlot(V.$slots,"arrow-left",{key:0}):e.createCommentVNode("",!0),V.$slots["arrow-left"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(rt),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.createElementVNode("button",{ref:"mpYearButtonRef",class:"dp__btn dp--year-select",type:"button","aria-label":(F=e.unref(c))==null?void 0:F.openYearsOverlay,"data-test":`year-mode-btn-${a.instance}`,onClick:L[1]||(L[1]=()=>C(!1)),onKeydown:L[2]||(L[2]=e.withKeys(()=>C(!1),["enter"]))},[V.$slots.year?e.renderSlot(V.$slots,"year",{key:0,year:a.year}):e.createCommentVNode("",!0),V.$slots.year?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(a.year),1)],64))],40,mn),e.unref(l)(e.unref(k),a.instance)?(e.openBlock(),e.createBlock(ha,{key:1,ref:"mpNextIconRef","aria-label":(K=e.unref(c))==null?void 0:K.nextYear,disabled:a.isDisabled(!0),class:e.normalizeClass((T=e.unref(f))==null?void 0:T.navBtnNext),onActivate:L[3]||(L[3]=A=>_(!0))},{default:e.withCtx(()=>[V.$slots["arrow-right"]?e.renderSlot(V.$slots,"arrow-right",{key:0}):e.createCommentVNode("",!0),V.$slots["arrow-right"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ot),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.createVNode(e.Transition,{name:e.unref(y)(a.showYearPicker),css:e.unref(h)},{default:e.withCtx(()=>[a.showYearPicker?(e.openBlock(),e.createBlock(_a,{key:0,items:a.items,"text-input":V.textInput,"esc-close":V.escClose,config:V.config,"is-last":V.autoApply&&!e.unref(v).keepActionRow,"hide-navigation":V.hideNavigation,"aria-labels":V.ariaLabels,type:"year",onToggle:C,onSelected:L[4]||(L[4]=A=>$(A))},e.createSlots({"button-icon":e.withCtx(()=>[V.$slots["calendar-icon"]?e.renderSlot(V.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),V.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ma),{key:1}))]),_:2},[V.$slots["year-overlay-value"]?{name:"item",fn:e.withCtx(({item:A})=>[e.renderSlot(V.$slots,"year-overlay-value",{text:A.text,value:A.value})]),key:"0"}:void 0]),1032,["items","text-input","esc-close","config","is-last","hide-navigation","aria-labels"])):e.createCommentVNode("",!0)]),_:3},8,["name","css"])])}}}),ft=(a,t,r)=>{if(t.value&&Array.isArray(t.value))if(t.value.some(n=>ve(a,n))){const n=t.value.filter(l=>!ve(l,a));t.value=n.length?n:null}else(r&&+r>t.value.length||!r)&&t.value.push(a);else t.value=[a]},yt=(a,t,r)=>{let n=a.value?a.value.slice():[];return n.length===2&&n[1]!==null&&(n=[]),n.length?ke(t,n[0])?(n.unshift(t),r("range-start",n[0]),r("range-start",n[1])):(n[1]=t,r("range-end",t)):(n=[t],r("range-start",t)),n},Va=(a,t,r,n)=>{a&&(a[0]&&a[1]&&r&&t("auto-apply"),a[0]&&!a[1]&&n&&r&&t("auto-apply"))},Zt=a=>{Array.isArray(a.value)&&a.value.length<=2&&a.range?a.modelValue.value=a.value.map(t=>Pe(I(t),a.timezone)):Array.isArray(a.value)||(a.modelValue.value=Pe(I(a.value),a.timezone))},el=(a,t,r,n)=>Array.isArray(t.value)&&(t.value.length===2||t.value.length===1&&n.value.partialRange)?n.value.fixedStart&&(_e(a,t.value[0])||ve(a,t.value[0]))?[t.value[0],a]:n.value.fixedEnd&&(ke(a,t.value[1])||ve(a,t.value[1]))?[a,t.value[1]]:(r("invalid-fixed-range",a),t.value):[],al=({multiCalendars:a,range:t,highlight:r,propDates:n,calendars:l,modelValue:m,props:v,filters:k,year:c,month:O,emit:f})=>{const h=e.computed(()=>ct(v.yearRange,v.locale,v.reverseYears)),y=e.ref([!1]),C=e.computed(()=>(N,W)=>{const le=fe.set(Re(new Date),{month:O.value(N),year:c.value(N)}),re=W?Pt.endOfYear(le):xa.startOfYear(le);return Kt(re,n.value.maxDate,n.value.minDate,v.preventMinMaxNavigation,W)}),$=()=>Array.isArray(m.value)&&a.value.solo&&m.value[1],_=()=>{for(let N=0;N<a.value.count;N++)if(N===0)l.value[N]=l.value[0];else if(N===a.value.count-1&&$())l.value[N]={month:ce.getMonth(m.value[1]),year:ue.getYear(m.value[1])};else{const W=fe.set(I(),l.value[N-1]);l.value[N]={month:ce.getMonth(W),year:ue.getYear(Rt.addYears(W,1))}}},V=N=>{if(!N)return _();const W=fe.set(I(),l.value[N]);return l.value[0].year=ue.getYear(Ot.subYears(W,a.value.count-1)),_()},L=(N,W)=>{const le=gl.differenceInYears(W,N);return t.value.showLastInRange&&le>1?W:N},J=N=>v.focusStartDate||a.value.solo?N[0]:N[1]?L(N[0],N[1]):N[0],D=()=>{if(m.value){const N=Array.isArray(m.value)?J(m.value):m.value;l.value[0]={month:ce.getMonth(N),year:ue.getYear(N)}}},F=()=>{D(),a.value.count&&_()};e.watch(m,(N,W)=>{v.isTextInputDate&&JSON.stringify(N??{})!==JSON.stringify(W??{})&&F()}),e.onMounted(()=>{F()});const K=(N,W)=>{l.value[W].year=N,f("update-month-year",{instance:W,year:N,month:l.value[W].month}),a.value.count&&!a.value.solo&&V(W)},T=e.computed(()=>N=>da(h.value,W=>{var le;const re=c.value(N)===W.value,M=ba(W.value,ca(n.value.minDate),ca(n.value.maxDate))||((le=k.value.years)==null?void 0:le.includes(c.value(N))),s=pt(r.value,W.value);return{active:re,disabled:M,highlighted:s}})),A=(N,W)=>{K(N,W),H(W)},Z=(N,W=!1)=>{if(!C.value(N,W)){const le=W?c.value(N)+1:c.value(N)-1;K(le,N)}},H=(N,W=!1,le)=>{W||f("reset-flow"),le!==void 0?y.value[N]=le:y.value[N]=!y.value[N],y.value[N]?f("overlay-toggle",{open:!0,overlay:Be.year}):(f("overlay-closed"),f("overlay-toggle",{open:!1,overlay:Be.year}))};return{isDisabled:C,groupedYears:T,showYearPicker:y,selectYear:K,toggleYearPicker:H,handleYearSelect:A,handleYear:Z}},vn=(a,t)=>{const{defaultedMultiCalendars:r,defaultedAriaLabels:n,defaultedTransitions:l,defaultedConfig:m,defaultedRange:v,defaultedHighlight:k,propDates:c,defaultedTz:O,defaultedFilters:f,defaultedMultiDates:h}=ge(a),y=()=>{a.isTextInputDate&&F(ue.getYear(I(a.startDate)),0)},{modelValue:C,year:$,month:_,calendars:V}=Ca(a,t,y),L=e.computed(()=>It(a.formatLocale,a.locale,a.monthNameFormat)),J=e.ref(null),{checkMinMaxRange:D}=Ge(a),{selectYear:F,groupedYears:K,showYearPicker:T,toggleYearPicker:A,handleYearSelect:Z,handleYear:H,isDisabled:N}=al({modelValue:C,multiCalendars:r,range:v,highlight:k,calendars:V,year:$,propDates:c,month:_,filters:f,props:a,emit:t});e.onMounted(()=>{a.startDate&&(C.value&&a.focusStartDate||!C.value)&&F(ue.getYear(I(a.startDate)),0)});const W=o=>o?{month:ce.getMonth(o),year:ue.getYear(o)}:{month:null,year:null},le=()=>C.value?Array.isArray(C.value)?C.value.map(o=>W(o)):W(C.value):W(),re=(o,B)=>{const G=V.value[o],d=le();return Array.isArray(d)?d.some(ee=>ee.year===(G==null?void 0:G.year)&&ee.month===B):(G==null?void 0:G.year)===d.year&&B===d.month},M=(o,B,G)=>{var d,ee;const se=le();return Array.isArray(se)?$.value(B)===((d=se[G])==null?void 0:d.year)&&o===((ee=se[G])==null?void 0:ee.month):!1},s=(o,B)=>{if(v.value.enabled){const G=le();if(Array.isArray(C.value)&&Array.isArray(G)){const d=M(o,B,0)||M(o,B,1),ee=Le(Re(I()),o,$.value(B));return Ta(C.value,J.value,ee)&&!d}return!1}return!1},w=e.computed(()=>o=>da(L.value,B=>{var G;const d=re(o,B.value),ee=ba(B.value,Ht($.value(o),c.value.minDate),qt($.value(o),c.value.maxDate))||Ol(c.value.disabledDates,$.value(o)).includes(B.value)||((G=f.value.months)==null?void 0:G.includes(B.value)),se=s(B.value,o),x=Qt(k.value,B.value,$.value(o));return{active:d,disabled:ee,isBetween:se,highlighted:x}})),u=(o,B)=>Le(Re(I()),o,$.value(B)),Y=(o,B)=>{const G=C.value?C.value:Re(new Date);C.value=Le(G,o,$.value(B)),t("auto-apply"),t("update-flow-step")},X=(o,B)=>{const G=u(o,B);v.value.fixedEnd||v.value.fixedStart?C.value=el(G,C,t,v):C.value?D(G,C.value)&&(C.value=yt(C,u(o,B),t)):C.value=[u(o,B)],e.nextTick().then(()=>{Va(C.value,t,a.autoApply,a.modelAuto)})},te=(o,B)=>{ft(u(o,B),C,h.value.limit),t("auto-apply",!0)},oe=(o,B)=>(V.value[B].month=o,E(B,V.value[B].year,o),h.value.enabled?te(o,B):v.value.enabled?X(o,B):Y(o,B)),p=(o,B)=>{F(o,B),E(B,o,null)},E=(o,B,G)=>{let d=G;if(!d&&d!==0){const ee=le();d=Array.isArray(ee)?ee[o].month:ee.month}t("update-month-year",{instance:o,year:B,month:d})};return{groupedMonths:w,groupedYears:K,year:$,isDisabled:N,defaultedMultiCalendars:r,defaultedAriaLabels:n,defaultedTransitions:l,defaultedConfig:m,showYearPicker:T,modelValue:C,presetDate:(o,B)=>{Zt({value:o,modelValue:C,range:v.value.enabled,timezone:B?void 0:O.value.timezone}),t("auto-apply")},setHoverDate:(o,B)=>{J.value=u(o,B)},selectMonth:oe,selectYear:p,toggleYearPicker:A,handleYearSelect:Z,handleYear:H,getModelMonthYear:le}},pn=e.defineComponent({compatConfig:{MODE:3},__name:"MonthPicker",props:{...Oe},emits:["update:internal-model-value","overlay-closed","reset-flow","range-start","range-end","auto-apply","update-month-year","update-flow-step","mount","invalid-fixed-range","overlay-toggle"],setup(a,{expose:t,emit:r}){const n=r,l=e.useSlots(),m=Ne(l,"yearMode"),v=a;e.onMounted(()=>{v.shadow||n("mount",null)});const{groupedMonths:k,groupedYears:c,year:O,isDisabled:f,defaultedMultiCalendars:h,defaultedConfig:y,showYearPicker:C,modelValue:$,presetDate:_,setHoverDate:V,selectMonth:L,selectYear:J,toggleYearPicker:D,handleYearSelect:F,handleYear:K,getModelMonthYear:T}=vn(v,n);return t({getSidebarProps:()=>({modelValue:$,year:O,getModelMonthYear:T,selectMonth:L,selectYear:J,handleYear:K}),presetDate:_,toggleYearPicker:A=>D(0,A)}),(A,Z)=>(e.openBlock(),e.createBlock(Pa,{"multi-calendars":e.unref(h).count,collapse:A.collapse,stretch:""},{default:e.withCtx(({instance:H})=>[A.$slots["top-extra"]?e.renderSlot(A.$slots,"top-extra",{key:0,value:A.internalModelValue}):e.createCommentVNode("",!0),A.$slots["month-year"]?e.renderSlot(A.$slots,"month-year",e.normalizeProps(e.mergeProps({key:1},{year:e.unref(O),months:e.unref(k)(H),years:e.unref(c)(H),selectMonth:e.unref(L),selectYear:e.unref(J),instance:H}))):(e.openBlock(),e.createBlock(_a,{key:2,items:e.unref(k)(H),"arrow-navigation":A.arrowNavigation,"is-last":A.autoApply&&!e.unref(y).keepActionRow,"esc-close":A.escClose,height:e.unref(y).modeHeight,config:A.config,"no-overlay-focus":!!(A.noOverlayFocus||A.textInput),"use-relative":"",type:"month",onSelected:N=>e.unref(L)(N,H),onHoverValue:N=>e.unref(V)(N,H)},e.createSlots({header:e.withCtx(()=>[e.createVNode(Gt,e.mergeProps(A.$props,{items:e.unref(c)(H),instance:H,"show-year-picker":e.unref(C)[H],year:e.unref(O)(H),"is-disabled":N=>e.unref(f)(H,N),onHandleYear:N=>e.unref(K)(H,N),onYearSelect:N=>e.unref(F)(N,H),onToggleYearPicker:N=>e.unref(D)(H,N==null?void 0:N.flow,N==null?void 0:N.show)}),e.createSlots({_:2},[e.renderList(e.unref(m),(N,W)=>({name:N,fn:e.withCtx(le=>[e.renderSlot(A.$slots,N,e.normalizeProps(e.guardReactiveProps(le)))])}))]),1040,["items","instance","show-year-picker","year","is-disabled","onHandleYear","onYearSelect","onToggleYearPicker"])]),_:2},[A.$slots["month-overlay-value"]?{name:"item",fn:e.withCtx(({item:N})=>[e.renderSlot(A.$slots,"month-overlay-value",{text:N.text,value:N.value})]),key:"0"}:void 0]),1032,["items","arrow-navigation","is-last","esc-close","height","config","no-overlay-focus","onSelected","onHoverValue"]))]),_:3},8,["multi-calendars","collapse"]))}}),fn=(a,t)=>{const r=()=>{a.isTextInputDate&&(f.value=ue.getYear(I(a.startDate)))},{modelValue:n}=Ca(a,t,r),l=e.ref(null),{defaultedHighlight:m,defaultedMultiDates:v,defaultedFilters:k,defaultedRange:c,propDates:O}=ge(a),f=e.ref();e.onMounted(()=>{a.startDate&&(n.value&&a.focusStartDate||!n.value)&&(f.value=ue.getYear(I(a.startDate)))});const h=_=>Array.isArray(n.value)?n.value.some(V=>ue.getYear(V)===_):n.value?ue.getYear(n.value)===_:!1,y=_=>c.value.enabled&&Array.isArray(n.value)?Ta(n.value,l.value,$(_)):!1,C=e.computed(()=>da(ct(a.yearRange,a.locale,a.reverseYears),_=>{const V=h(_.value),L=ba(_.value,ca(O.value.minDate),ca(O.value.maxDate))||k.value.years.includes(_.value),J=y(_.value)&&!V,D=pt(m.value,_.value);return{active:V,disabled:L,isBetween:J,highlighted:D}})),$=_=>Ie.setYear(Re(xa.startOfYear(new Date)),_);return{groupedYears:C,modelValue:n,focusYear:f,setHoverValue:_=>{l.value=Ie.setYear(Re(new Date),_)},selectYear:_=>{var V;if(t("update-month-year",{instance:0,year:_}),v.value.enabled)return n.value?Array.isArray(n.value)&&(((V=n.value)==null?void 0:V.map(L=>ue.getYear(L))).includes(_)?n.value=n.value.filter(L=>ue.getYear(L)!==_):n.value.push(Ie.setYear(Ae(I()),_))):n.value=[Ie.setYear(Ae(xa.startOfYear(I())),_)],t("auto-apply",!0);c.value.enabled?(n.value=yt(n,$(_),t),e.nextTick().then(()=>{Va(n.value,t,a.autoApply,a.modelAuto)})):(n.value=$(_),t("auto-apply"))}}},yn=e.defineComponent({compatConfig:{MODE:3},__name:"YearPicker",props:{...Oe},emits:["update:internal-model-value","reset-flow","range-start","range-end","auto-apply","update-month-year"],setup(a,{expose:t,emit:r}){const n=r,l=a,{groupedYears:m,modelValue:v,focusYear:k,selectYear:c,setHoverValue:O}=fn(l,n),{defaultedConfig:f}=ge(l);return t({getSidebarProps:()=>({modelValue:v,selectYear:c})}),(h,y)=>(e.openBlock(),e.createElementBlock("div",null,[h.$slots["top-extra"]?e.renderSlot(h.$slots,"top-extra",{key:0,value:h.internalModelValue}):e.createCommentVNode("",!0),h.$slots["month-year"]?e.renderSlot(h.$slots,"month-year",e.normalizeProps(e.mergeProps({key:1},{years:e.unref(m),selectYear:e.unref(c)}))):(e.openBlock(),e.createBlock(_a,{key:2,items:e.unref(m),"is-last":h.autoApply&&!e.unref(f).keepActionRow,height:e.unref(f).modeHeight,config:h.config,"no-overlay-focus":!!(h.noOverlayFocus||h.textInput),"focus-value":e.unref(k),type:"year","use-relative":"",onSelected:e.unref(c),onHoverValue:e.unref(O)},e.createSlots({_:2},[h.$slots["year-overlay-value"]?{name:"item",fn:e.withCtx(({item:C})=>[e.renderSlot(h.$slots,"year-overlay-value",{text:C.text,value:C.value})]),key:"0"}:void 0]),1032,["items","is-last","height","config","no-overlay-focus","focus-value","onSelected","onHoverValue"]))]))}}),hn={key:0,class:"dp__time_input"},gn=["data-test","aria-label","onKeydown","onClick","onMousedown"],kn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),bn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),_n=["aria-label","disabled","data-test","onKeydown","onClick"],wn=["data-test","aria-label","onKeydown","onClick","onMousedown"],Cn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),Sn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),Bn={key:0},Dn=["aria-label"],Mn=e.defineComponent({compatConfig:{MODE:3},__name:"TimeInput",props:{hours:{type:Number,default:0},minutes:{type:Number,default:0},seconds:{type:Number,default:0},closeTimePickerBtn:{type:Object,default:null},order:{type:Number,default:0},disabledTimesConfig:{type:Function,default:null},validateTime:{type:Function,default:()=>!1},...Oe},emits:["set-hours","set-minutes","update:hours","update:minutes","update:seconds","reset-flow","mounted","overlay-closed","overlay-opened","am-pm-change"],setup(a,{expose:t,emit:r}){const n=r,l=a,{setTimePickerElements:m,setTimePickerBackRef:v}=We(),{defaultedAriaLabels:k,defaultedTransitions:c,defaultedFilters:O,defaultedConfig:f,defaultedRange:h}=ge(l),{transitionName:y,showTransition:C}=wa(c),$=e.reactive({hours:!1,minutes:!1,seconds:!1}),_=e.ref("AM"),V=e.ref(null),L=e.ref([]),J=e.ref();e.onMounted(()=>{n("mounted")});const D=i=>fe.set(new Date,{hours:i.hours,minutes:i.minutes,seconds:l.enableSeconds?i.seconds:0,milliseconds:0}),F=e.computed(()=>i=>w(i,l[i])||T(i,l[i])),K=e.computed(()=>({hours:l.hours,minutes:l.minutes,seconds:l.seconds})),T=(i,P)=>h.value.enabled&&!h.value.disableTimeRangeValidation?!l.validateTime(i,P):!1,A=(i,P)=>{if(h.value.enabled&&!h.value.disableTimeRangeValidation){const q=P?+l[`${i}Increment`]:-+l[`${i}Increment`],z=l[i]+q;return!l.validateTime(i,z)}return!1},Z=e.computed(()=>i=>!oe(+l[i]+ +l[`${i}Increment`],i)||A(i,!0)),H=e.computed(()=>i=>!oe(+l[i]-+l[`${i}Increment`],i)||A(i,!1)),N=(i,P)=>Tt.add(fe.set(I(),i),P),W=(i,P)=>hl.sub(fe.set(I(),i),P),le=e.computed(()=>({dp__time_col:!0,dp__time_col_block:!l.timePickerInline,dp__time_col_reg_block:!l.enableSeconds&&l.is24&&!l.timePickerInline,dp__time_col_reg_inline:!l.enableSeconds&&l.is24&&l.timePickerInline,dp__time_col_reg_with_button:!l.enableSeconds&&!l.is24,dp__time_col_sec:l.enableSeconds&&l.is24,dp__time_col_sec_with_button:l.enableSeconds&&!l.is24})),re=e.computed(()=>{const i=[{type:"hours"}];return l.enableMinutes&&i.push({type:"",separator:!0},{type:"minutes"}),l.enableSeconds&&i.push({type:"",separator:!0},{type:"seconds"}),i}),M=e.computed(()=>re.value.filter(i=>!i.separator)),s=e.computed(()=>i=>{if(i==="hours"){const P=d(+l.hours);return{text:P<10?`0${P}`:`${P}`,value:P}}return{text:l[i]<10?`0${l[i]}`:`${l[i]}`,value:l[i]}}),w=(i,P)=>{var q;if(!l.disabledTimesConfig)return!1;const z=l.disabledTimesConfig(l.order,i==="hours"?P:void 0);return z[i]?!!((q=z[i])!=null&&q.includes(P)):!0},u=(i,P)=>P!=="hours"||_.value==="AM"?i:i+12,Y=i=>{const P=l.is24?24:12,q=i==="hours"?P:60,z=+l[`${i}GridIncrement`],R=i==="hours"&&!l.is24?z:0,me=[];for(let b=R;b<q;b+=z)me.push({value:l.is24?b:u(b,i),text:b<10?`0${b}`:`${b}`});return i==="hours"&&!l.is24&&me.unshift({value:_.value==="PM"?12:0,text:"12"}),da(me,b=>({active:!1,disabled:O.value.times[i].includes(b.value)||!oe(b.value,i)||w(i,b.value)||T(i,b.value)}))},X=i=>i>=0?i:59,te=i=>i>=0?i:23,oe=(i,P)=>{const q=l.minTime?D(Ua(l.minTime)):null,z=l.maxTime?D(Ua(l.maxTime)):null,R=D(Ua(K.value,P,P==="minutes"||P==="seconds"?X(i):te(i)));return q&&z?(ga.isBefore(R,z)||ua.isEqual(R,z))&&(ia.isAfter(R,q)||ua.isEqual(R,q)):q?ia.isAfter(R,q)||ua.isEqual(R,q):z?ga.isBefore(R,z)||ua.isEqual(R,z):!0},p=i=>l[`no${i[0].toUpperCase()+i.slice(1)}Overlay`],E=i=>{p(i)||($[i]=!$[i],$[i]?n("overlay-opened",i):n("overlay-closed",i))},o=i=>i==="hours"?He.getHours:i==="minutes"?Xe.getMinutes:sa.getSeconds,B=()=>{J.value&&clearTimeout(J.value)},G=(i,P=!0,q)=>{const z=P?N:W,R=P?+l[`${i}Increment`]:-+l[`${i}Increment`];oe(+l[i]+R,i)&&n(`update:${i}`,o(i)(z({[i]:+l[i]},{[i]:+l[`${i}Increment`]}))),!(q!=null&&q.keyboard)&&f.value.timeArrowHoldThreshold&&(J.value=setTimeout(()=>{G(i,P)},f.value.timeArrowHoldThreshold))},d=i=>l.is24?i:(i>=12?_.value="PM":_.value="AM",Sl(i)),ee=()=>{_.value==="PM"?(_.value="AM",n("update:hours",l.hours-12)):(_.value="PM",n("update:hours",l.hours+12)),n("am-pm-change",_.value)},se=i=>{$[i]=!0},x=(i,P,q)=>{if(i&&l.arrowNavigation){Array.isArray(L.value[P])?L.value[P][q]=i:L.value[P]=[i];const z=L.value.reduce((R,me)=>me.map((b,Q)=>[...R[Q]||[],me[Q]]),[]);v(l.closeTimePickerBtn),V.value&&(z[1]=z[1].concat(V.value)),m(z,l.order)}},ie=(i,P)=>(E(i),n(`update:${i}`,P));return t({openChildCmp:se}),(i,P)=>{var q;return i.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",hn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(re.value,(z,R)=>{var me,b,Q;return e.openBlock(),e.createElementBlock("div",{key:R,class:e.normalizeClass(le.value)},[z.separator?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" : ")],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("button",{ref_for:!0,ref:de=>x(de,R,0),type:"button",class:e.normalizeClass({dp__btn:!0,dp__inc_dec_button:!i.timePickerInline,dp__inc_dec_button_inline:i.timePickerInline,dp__tp_inline_btn_top:i.timePickerInline,dp__inc_dec_button_disabled:Z.value(z.type)}),"data-test":`${z.type}-time-inc-btn-${l.order}`,"aria-label":(me=e.unref(k))==null?void 0:me.incrementValue(z.type),tabindex:"0",onKeydown:de=>e.unref($e)(de,()=>G(z.type,!0,{keyboard:!0}),!0),onClick:de=>e.unref(f).timeArrowHoldThreshold?void 0:G(z.type,!0),onMousedown:de=>e.unref(f).timeArrowHoldThreshold?G(z.type,!0):void 0,onMouseup:B},[l.timePickerInline?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[i.$slots["tp-inline-arrow-up"]?e.renderSlot(i.$slots,"tp-inline-arrow-up",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[kn,bn],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i.$slots["arrow-up"]?e.renderSlot(i.$slots,"arrow-up",{key:0}):e.createCommentVNode("",!0),i.$slots["arrow-up"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(it),{key:1}))],64))],42,gn),e.createElementVNode("button",{ref_for:!0,ref:de=>x(de,R,1),type:"button","aria-label":(b=e.unref(k))==null?void 0:b.openTpOverlay(z.type),class:e.normalizeClass({dp__time_display:!0,dp__time_display_block:!i.timePickerInline,dp__time_display_inline:i.timePickerInline,"dp--time-invalid":F.value(z.type),"dp--time-overlay-btn":!F.value(z.type)}),disabled:p(z.type),tabindex:"0","data-test":`${z.type}-toggle-overlay-btn-${l.order}`,onKeydown:de=>e.unref($e)(de,()=>E(z.type),!0),onClick:de=>E(z.type)},[i.$slots[z.type]?e.renderSlot(i.$slots,z.type,{key:0,text:s.value(z.type).text,value:s.value(z.type).value}):e.createCommentVNode("",!0),i.$slots[z.type]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(s.value(z.type).text),1)],64))],42,_n),e.createElementVNode("button",{ref_for:!0,ref:de=>x(de,R,2),type:"button",class:e.normalizeClass({dp__btn:!0,dp__inc_dec_button:!i.timePickerInline,dp__inc_dec_button_inline:i.timePickerInline,dp__tp_inline_btn_bottom:i.timePickerInline,dp__inc_dec_button_disabled:H.value(z.type)}),"data-test":`${z.type}-time-dec-btn-${l.order}`,"aria-label":(Q=e.unref(k))==null?void 0:Q.decrementValue(z.type),tabindex:"0",onKeydown:de=>e.unref($e)(de,()=>G(z.type,!1,{keyboard:!0}),!0),onClick:de=>e.unref(f).timeArrowHoldThreshold?void 0:G(z.type,!1),onMousedown:de=>e.unref(f).timeArrowHoldThreshold?G(z.type,!1):void 0,onMouseup:B},[l.timePickerInline?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[i.$slots["tp-inline-arrow-down"]?e.renderSlot(i.$slots,"tp-inline-arrow-down",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[Cn,Sn],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i.$slots["arrow-down"]?e.renderSlot(i.$slots,"arrow-down",{key:0}):e.createCommentVNode("",!0),i.$slots["arrow-down"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(st),{key:1}))],64))],42,wn)],64))],2)}),128)),i.is24?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Bn,[i.$slots["am-pm-button"]?e.renderSlot(i.$slots,"am-pm-button",{key:0,toggle:ee,value:_.value}):e.createCommentVNode("",!0),i.$slots["am-pm-button"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:1,ref_key:"amPmButton",ref:V,type:"button",class:"dp__pm_am_button",role:"button","aria-label":(q=e.unref(k))==null?void 0:q.amPmButton,tabindex:"0",onClick:ee,onKeydown:P[0]||(P[0]=z=>e.unref($e)(z,()=>ee(),!0))},e.toDisplayString(_.value),41,Dn))])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,(z,R)=>(e.openBlock(),e.createBlock(e.Transition,{key:R,name:e.unref(y)($[z.type]),css:e.unref(C)},{default:e.withCtx(()=>[$[z.type]?(e.openBlock(),e.createBlock(_a,{key:0,items:Y(z.type),"is-last":i.autoApply&&!e.unref(f).keepActionRow,"esc-close":i.escClose,type:z.type,"text-input":i.textInput,config:i.config,"arrow-navigation":i.arrowNavigation,"aria-labels":i.ariaLabels,onSelected:me=>ie(z.type,me),onToggle:me=>E(z.type),onResetFlow:P[1]||(P[1]=me=>i.$emit("reset-flow"))},e.createSlots({"button-icon":e.withCtx(()=>[i.$slots["clock-icon"]?e.renderSlot(i.$slots,"clock-icon",{key:0}):e.createCommentVNode("",!0),i.$slots["clock-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.timePickerInline?e.unref(ma):e.unref(ut)),{key:1}))]),_:2},[i.$slots[`${z.type}-overlay-value`]?{name:"item",fn:e.withCtx(({item:me})=>[e.renderSlot(i.$slots,`${z.type}-overlay-value`,{text:me.text,value:me.value})]),key:"0"}:void 0,i.$slots[`${z.type}-overlay-header`]?{name:"header",fn:e.withCtx(()=>[e.renderSlot(i.$slots,`${z.type}-overlay-header`,{toggle:()=>E(z.type)})]),key:"1"}:void 0]),1032,["items","is-last","esc-close","type","text-input","config","arrow-navigation","aria-labels","onSelected","onToggle"])):e.createCommentVNode("",!0)]),_:2},1032,["name","css"]))),128))]))}}}),An={class:"dp--tp-wrap"},xn=["aria-label","tabindex"],$n=["tabindex"],Tn=["aria-label"],tl=e.defineComponent({compatConfig:{MODE:3},__name:"TimePicker",props:{hours:{type:[Number,Array],default:0},minutes:{type:[Number,Array],default:0},seconds:{type:[Number,Array],default:0},disabledTimesConfig:{type:Function,default:null},validateTime:{type:Function,default:()=>!1},...Oe},emits:["update:hours","update:minutes","update:seconds","mount","reset-flow","overlay-opened","overlay-closed","am-pm-change"],setup(a,{expose:t,emit:r}){const n=r,l=a,{buildMatrix:m,setTimePicker:v}=We(),k=e.useSlots(),{defaultedTransitions:c,defaultedAriaLabels:O,defaultedTextInput:f,defaultedConfig:h,defaultedRange:y}=ge(l),{transitionName:C,showTransition:$}=wa(c),{hideNavigationButtons:_}=Ea(),V=e.ref(null),L=e.ref(null),J=e.ref([]),D=e.ref(null);e.onMounted(()=>{n("mount"),!l.timePicker&&l.arrowNavigation?m([we(V.value)],"time"):v(!0,l.timePicker)});const F=e.computed(()=>y.value.enabled&&l.modelAuto?zt(l.internalModelValue):!0),K=e.ref(!1),T=u=>({hours:Array.isArray(l.hours)?l.hours[u]:l.hours,minutes:Array.isArray(l.minutes)?l.minutes[u]:l.minutes,seconds:Array.isArray(l.seconds)?l.seconds[u]:l.seconds}),A=e.computed(()=>{const u=[];if(y.value.enabled)for(let Y=0;Y<2;Y++)u.push(T(Y));else u.push(T(0));return u}),Z=(u,Y=!1,X="")=>{Y||n("reset-flow"),K.value=u,n(u?"overlay-opened":"overlay-closed",Be.time),l.arrowNavigation&&v(u),e.nextTick(()=>{X!==""&&J.value[0]&&J.value[0].openChildCmp(X)})},H=e.computed(()=>({dp__btn:!0,dp__button:!0,dp__button_bottom:l.autoApply&&!h.value.keepActionRow})),N=Ne(k,"timePicker"),W=(u,Y,X)=>y.value.enabled?Y===0?[u,A.value[1][X]]:[A.value[0][X],u]:u,le=u=>{n("update:hours",u)},re=u=>{n("update:minutes",u)},M=u=>{n("update:seconds",u)},s=()=>{if(D.value&&!f.value.enabled&&!l.noOverlayFocus){const u=Ft(D.value);u&&u.focus({preventScroll:!0})}},w=u=>{n("overlay-closed",u)};return t({toggleTimePicker:Z}),(u,Y)=>{var X;return e.openBlock(),e.createElementBlock("div",An,[!u.timePicker&&!u.timePickerInline?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"openTimePickerBtn",ref:V,type:"button",class:e.normalizeClass(H.value),"aria-label":(X=e.unref(O))==null?void 0:X.openTimePicker,tabindex:u.noOverlayFocus?void 0:0,"data-test":"open-time-picker-btn",onKeydown:Y[0]||(Y[0]=te=>e.unref($e)(te,()=>Z(!0))),onClick:Y[1]||(Y[1]=te=>Z(!0))},[u.$slots["clock-icon"]?e.renderSlot(u.$slots,"clock-icon",{key:0}):e.createCommentVNode("",!0),u.$slots["clock-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ut),{key:1}))],42,xn)),[[e.vShow,!e.unref(_)(u.hideNavigation,"time")]]):e.createCommentVNode("",!0),e.createVNode(e.Transition,{name:e.unref(C)(K.value),css:e.unref($)&&!u.timePickerInline},{default:e.withCtx(()=>{var te;return[K.value||u.timePicker||u.timePickerInline?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:D,class:e.normalizeClass({dp__overlay:!u.timePickerInline,"dp--overlay-absolute":!l.timePicker&&!u.timePickerInline,"dp--overlay-relative":l.timePicker}),style:e.normalizeStyle(u.timePicker?{height:`${e.unref(h).modeHeight}px`}:void 0),tabindex:u.timePickerInline?void 0:0},[e.createElementVNode("div",{class:e.normalizeClass(u.timePickerInline?"dp__time_picker_inline_container":"dp__overlay_container dp__container_flex dp__time_picker_overlay_container"),style:{display:"flex"}},[u.$slots["time-picker-overlay"]?e.renderSlot(u.$slots,"time-picker-overlay",{key:0,hours:a.hours,minutes:a.minutes,seconds:a.seconds,setHours:le,setMinutes:re,setSeconds:M}):e.createCommentVNode("",!0),u.$slots["time-picker-overlay"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(u.timePickerInline?"dp__flex":"dp__overlay_row dp__flex_row")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value,(oe,p)=>e.withDirectives((e.openBlock(),e.createBlock(Mn,e.mergeProps({key:p,ref_for:!0},{...u.$props,order:p,hours:oe.hours,minutes:oe.minutes,seconds:oe.seconds,closeTimePickerBtn:L.value,disabledTimesConfig:a.disabledTimesConfig,disabled:p===0?u.fixedStart:u.fixedEnd},{ref_for:!0,ref_key:"timeInputRefs",ref:J,"validate-time":(E,o)=>a.validateTime(E,W(o,p,E)),"onUpdate:hours":E=>le(W(E,p,"hours")),"onUpdate:minutes":E=>re(W(E,p,"minutes")),"onUpdate:seconds":E=>M(W(E,p,"seconds")),onMounted:s,onOverlayClosed:w,onOverlayOpened:Y[2]||(Y[2]=E=>u.$emit("overlay-opened",E)),onAmPmChange:Y[3]||(Y[3]=E=>u.$emit("am-pm-change",E))}),e.createSlots({_:2},[e.renderList(e.unref(N),(E,o)=>({name:E,fn:e.withCtx(B=>[e.renderSlot(u.$slots,E,e.mergeProps({ref_for:!0},B))])}))]),1040,["validate-time","onUpdate:hours","onUpdate:minutes","onUpdate:seconds"])),[[e.vShow,p===0?!0:F.value]])),128))],2)),!u.timePicker&&!u.timePickerInline?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:2,ref_key:"closeTimePickerBtn",ref:L,type:"button",class:e.normalizeClass(H.value),"aria-label":(te=e.unref(O))==null?void 0:te.closeTimePicker,tabindex:"0",onKeydown:Y[4]||(Y[4]=oe=>e.unref($e)(oe,()=>Z(!1))),onClick:Y[5]||(Y[5]=oe=>Z(!1))},[u.$slots["calendar-icon"]?e.renderSlot(u.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),u.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ma),{key:1}))],42,Tn)),[[e.vShow,!e.unref(_)(u.hideNavigation,"time")]]):e.createCommentVNode("",!0)],2)],14,$n)):e.createCommentVNode("",!0)]}),_:3},8,["name","css"])])}}}),ll=(a,t,r,n)=>{const{defaultedRange:l}=ge(a),m=(D,F)=>Array.isArray(t[D])?t[D][F]:t[D],v=D=>a.enableSeconds?Array.isArray(t.seconds)?t.seconds[D]:t.seconds:0,k=(D,F)=>D?F!==void 0?Qe(D,m("hours",F),m("minutes",F),v(F)):Qe(D,t.hours,t.minutes,v()):Vt.setSeconds(I(),v(F)),c=(D,F)=>{t[D]=F},O=e.computed(()=>a.modelAuto&&l.value.enabled?Array.isArray(r.value)?r.value.length>1:!1:l.value.enabled),f=(D,F)=>{const K=Object.fromEntries(Object.keys(t).map(T=>T===D?[T,F]:[T,t[T]].slice()));if(O.value&&!l.value.disableTimeRangeValidation){const T=Z=>r.value?Qe(r.value[Z],K.hours[Z],K.minutes[Z],K.seconds[Z]):null,A=Z=>Et.setMilliseconds(r.value[Z],0);return!(ve(T(0),T(1))&&(ia.isAfter(T(0),A(1))||ga.isBefore(T(1),A(0))))}return!0},h=(D,F)=>{f(D,F)&&(c(D,F),n&&n())},y=D=>{h("hours",D)},C=D=>{h("minutes",D)},$=D=>{h("seconds",D)},_=(D,F,K,T)=>{F&&y(D),!F&&!K&&C(D),K&&$(D),r.value&&T(r.value)},V=D=>{if(D){const F=Array.isArray(D),K=F?[+D[0].hours,+D[1].hours]:+D.hours,T=F?[+D[0].minutes,+D[1].minutes]:+D.minutes,A=F?[+D[0].seconds,+D[1].seconds]:+D.seconds;c("hours",K),c("minutes",T),a.enableSeconds&&c("seconds",A)}},L=(D,F)=>{const K={hours:Array.isArray(t.hours)?t.hours[D]:t.hours,disabledArr:[]};return(F||F===0)&&(K.hours=F),Array.isArray(a.disabledTimes)&&(K.disabledArr=l.value.enabled&&Array.isArray(a.disabledTimes[D])?a.disabledTimes[D]:a.disabledTimes),K},J=e.computed(()=>(D,F)=>{var K;if(Array.isArray(a.disabledTimes)){const{disabledArr:T,hours:A}=L(D,F),Z=T.filter(H=>+H.hours===A);return((K=Z[0])==null?void 0:K.minutes)==="*"?{hours:[A],minutes:void 0,seconds:void 0}:{hours:[],minutes:(Z==null?void 0:Z.map(H=>+H.minutes))??[],seconds:(Z==null?void 0:Z.map(H=>H.seconds?+H.seconds:void 0))??[]}}return{hours:[],minutes:[],seconds:[]}});return{setTime:c,updateHours:y,updateMinutes:C,updateSeconds:$,getSetDateTime:k,updateTimeValues:_,getSecondsValue:v,assignStartTime:V,validateTime:f,disabledTimesConfig:J}},Nn=(a,t)=>{const r=()=>{a.isTextInputDate&&F()},{modelValue:n,time:l}=Ca(a,t,r),{defaultedStartTime:m,defaultedRange:v,defaultedTz:k}=ge(a),{updateTimeValues:c,getSetDateTime:O,setTime:f,assignStartTime:h,disabledTimesConfig:y,validateTime:C}=ll(a,l,n,$);function $(){t("update-flow-step")}const _=T=>{const{hours:A,minutes:Z,seconds:H}=T;return{hours:+A,minutes:+Z,seconds:H?+H:0}},V=()=>{if(a.startTime){if(Array.isArray(a.startTime)){const A=_(a.startTime[0]),Z=_(a.startTime[1]);return[fe.set(I(),A),fe.set(I(),Z)]}const T=_(a.startTime);return fe.set(I(),T)}return v.value.enabled?[null,null]:null},L=()=>{if(v.value.enabled){const[T,A]=V();n.value=[Pe(O(T,0),k.value.timezone),Pe(O(A,1),k.value.timezone)]}else n.value=Pe(O(V()),k.value.timezone)},J=T=>Array.isArray(T)?[na(I(T[0])),na(I(T[1]))]:[na(T??I())],D=(T,A,Z)=>{f("hours",T),f("minutes",A),f("seconds",a.enableSeconds?Z:0)},F=()=>{const[T,A]=J(n.value);return v.value.enabled?D([T.hours,A.hours],[T.minutes,A.minutes],[T.seconds,A.seconds]):D(T.hours,T.minutes,T.seconds)};e.onMounted(()=>{if(!a.shadow)return h(m.value),n.value?F():L()});const K=()=>{Array.isArray(n.value)?n.value=n.value.map((T,A)=>T&&O(T,A)):n.value=O(n.value),t("time-update")};return{modelValue:n,time:l,disabledTimesConfig:y,updateTime:(T,A=!0,Z=!1)=>{c(T,A,Z,K)},validateTime:C}},Pn=e.defineComponent({compatConfig:{MODE:3},__name:"TimePickerSolo",props:{...Oe},emits:["update:internal-model-value","time-update","am-pm-change","mount","reset-flow","update-flow-step","overlay-toggle"],setup(a,{expose:t,emit:r}){const n=r,l=a,m=e.useSlots(),v=Ne(m,"timePicker"),k=e.ref(null),{time:c,modelValue:O,disabledTimesConfig:f,updateTime:h,validateTime:y}=Nn(l,n);return e.onMounted(()=>{l.shadow||n("mount",null)}),t({getSidebarProps:()=>({modelValue:O,time:c,updateTime:h}),toggleTimePicker:(C,$=!1,_="")=>{var V;(V=k.value)==null||V.toggleTimePicker(C,$,_)}}),(C,$)=>(e.openBlock(),e.createBlock(Pa,{"multi-calendars":0,stretch:""},{default:e.withCtx(()=>[e.createVNode(tl,e.mergeProps({ref_key:"tpRef",ref:k},C.$props,{hours:e.unref(c).hours,minutes:e.unref(c).minutes,seconds:e.unref(c).seconds,"internal-model-value":C.internalModelValue,"disabled-times-config":e.unref(f),"validate-time":e.unref(y),"onUpdate:hours":$[0]||($[0]=_=>e.unref(h)(_)),"onUpdate:minutes":$[1]||($[1]=_=>e.unref(h)(_,!1)),"onUpdate:seconds":$[2]||($[2]=_=>e.unref(h)(_,!1,!0)),onAmPmChange:$[3]||($[3]=_=>C.$emit("am-pm-change",_)),onResetFlow:$[4]||($[4]=_=>C.$emit("reset-flow")),onOverlayClosed:$[5]||($[5]=_=>C.$emit("overlay-toggle",{open:!1,overlay:_})),onOverlayOpened:$[6]||($[6]=_=>C.$emit("overlay-toggle",{open:!0,overlay:_}))}),e.createSlots({_:2},[e.renderList(e.unref(v),(_,V)=>({name:_,fn:e.withCtx(L=>[e.renderSlot(C.$slots,_,e.normalizeProps(e.guardReactiveProps(L)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config","validate-time"])]),_:3}))}}),Vn={class:"dp--header-wrap"},En={key:0,class:"dp__month_year_wrap"},Rn={key:0},On={class:"dp__month_year_wrap"},Yn=["aria-label","data-test","onClick","onKeydown"],In=e.defineComponent({compatConfig:{MODE:3},__name:"DpHeader",props:{month:{type:Number,default:0},year:{type:Number,default:0},instance:{type:Number,default:0},years:{type:Array,default:()=>[]},months:{type:Array,default:()=>[]},...Oe},emits:["update-month-year","mount","reset-flow","overlay-closed","overlay-opened"],setup(a,{expose:t,emit:r}){const n=r,l=a,{defaultedTransitions:m,defaultedAriaLabels:v,defaultedMultiCalendars:k,defaultedFilters:c,defaultedConfig:O,defaultedHighlight:f,propDates:h,defaultedUI:y}=ge(l),{transitionName:C,showTransition:$}=wa(m),{buildMatrix:_}=We(),{handleMonthYearChange:V,isDisabled:L,updateMonthYear:J}=tn(l,n),{showLeftIcon:D,showRightIcon:F}=Ea(),K=e.ref(!1),T=e.ref(!1),A=e.ref([null,null,null,null]);e.onMounted(()=>{n("mount")});const Z=p=>({get:()=>l[p],set:E=>{const o=p===Ee.month?Ee.year:Ee.month;n("update-month-year",{[p]:E,[o]:l[o]}),p===Ee.month?w(!0):u(!0)}}),H=e.computed(Z(Ee.month)),N=e.computed(Z(Ee.year)),W=e.computed(()=>p=>({month:l.month,year:l.year,items:p===Ee.month?l.months:l.years,instance:l.instance,updateMonthYear:J,toggle:p===Ee.month?w:u})),le=e.computed(()=>l.months.find(E=>E.value===l.month)||{text:"",value:0}),re=e.computed(()=>da(l.months,p=>{const E=l.month===p.value,o=ba(p.value,Ht(l.year,h.value.minDate),qt(l.year,h.value.maxDate))||c.value.months.includes(p.value),B=Qt(f.value,p.value,l.year);return{active:E,disabled:o,highlighted:B}})),M=e.computed(()=>da(l.years,p=>{const E=l.year===p.value,o=ba(p.value,ca(h.value.minDate),ca(h.value.maxDate))||c.value.years.includes(p.value),B=pt(f.value,p.value);return{active:E,disabled:o,highlighted:B}})),s=(p,E,o)=>{o!==void 0?p.value=o:p.value=!p.value,p.value?n("overlay-opened",E):n("overlay-closed",E)},w=(p=!1,E)=>{Y(p),s(K,Be.month,E)},u=(p=!1,E)=>{Y(p),s(T,Be.year,E)},Y=p=>{p||n("reset-flow")},X=(p,E)=>{l.arrowNavigation&&(A.value[E]=we(p),_(A.value,"monthYear"))},te=e.computed(()=>{var p,E;return[{type:Ee.month,index:1,toggle:w,modelValue:H.value,updateModelValue:o=>H.value=o,text:le.value.text,showSelectionGrid:K.value,items:re.value,ariaLabel:(p=v.value)==null?void 0:p.openMonthsOverlay},{type:Ee.year,index:2,toggle:u,modelValue:N.value,updateModelValue:o=>N.value=o,text:Lt(l.year,l.locale),showSelectionGrid:T.value,items:M.value,ariaLabel:(E=v.value)==null?void 0:E.openYearsOverlay}]}),oe=e.computed(()=>l.disableYearSelect?[te.value[0]]:l.yearFirst?[...te.value].reverse():te.value);return t({toggleMonthPicker:w,toggleYearPicker:u,handleMonthYearChange:V}),(p,E)=>{var o,B,G,d,ee,se;return e.openBlock(),e.createElementBlock("div",Vn,[p.$slots["month-year"]?(e.openBlock(),e.createElementBlock("div",En,[e.renderSlot(p.$slots,"month-year",e.normalizeProps(e.guardReactiveProps({month:a.month,year:a.year,months:a.months,years:a.years,updateMonthYear:e.unref(J),handleMonthYearChange:e.unref(V),instance:a.instance})))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[p.$slots["top-extra"]?(e.openBlock(),e.createElementBlock("div",Rn,[e.renderSlot(p.$slots,"top-extra",{value:p.internalModelValue})])):e.createCommentVNode("",!0),e.createElementVNode("div",On,[e.unref(D)(e.unref(k),a.instance)&&!p.vertical?(e.openBlock(),e.createBlock(ha,{key:0,"aria-label":(o=e.unref(v))==null?void 0:o.prevMonth,disabled:e.unref(L)(!1),class:e.normalizeClass((B=e.unref(y))==null?void 0:B.navBtnPrev),onActivate:E[0]||(E[0]=x=>e.unref(V)(!1,!0)),onSetRef:E[1]||(E[1]=x=>X(x,0))},{default:e.withCtx(()=>[p.$slots["arrow-left"]?e.renderSlot(p.$slots,"arrow-left",{key:0}):e.createCommentVNode("",!0),p.$slots["arrow-left"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(rt),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["dp__month_year_wrap",{dp__year_disable_select:p.disableYearSelect}])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(oe.value,(x,ie)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:x.type},[e.createElementVNode("button",{ref_for:!0,ref:i=>X(i,ie+1),type:"button",class:"dp__btn dp__month_year_select",tabindex:"0","aria-label":x.ariaLabel,"data-test":`${x.type}-toggle-overlay-${a.instance}`,onClick:x.toggle,onKeydown:i=>e.unref($e)(i,()=>x.toggle(),!0)},[p.$slots[x.type]?e.renderSlot(p.$slots,x.type,{key:0,text:x.text,value:l[x.type]}):e.createCommentVNode("",!0),p.$slots[x.type]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(x.text),1)],64))],40,Yn),e.createVNode(e.Transition,{name:e.unref(C)(x.showSelectionGrid),css:e.unref($)},{default:e.withCtx(()=>[x.showSelectionGrid?(e.openBlock(),e.createBlock(_a,{key:0,items:x.items,"arrow-navigation":p.arrowNavigation,"hide-navigation":p.hideNavigation,"is-last":p.autoApply&&!e.unref(O).keepActionRow,"skip-button-ref":!1,config:p.config,type:x.type,"header-refs":[],"esc-close":p.escClose,"menu-wrap-ref":p.menuWrapRef,"text-input":p.textInput,"aria-labels":p.ariaLabels,onSelected:x.updateModelValue,onToggle:x.toggle},e.createSlots({"button-icon":e.withCtx(()=>[p.$slots["calendar-icon"]?e.renderSlot(p.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),p.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ma),{key:1}))]),_:2},[p.$slots[`${x.type}-overlay-value`]?{name:"item",fn:e.withCtx(({item:i})=>[e.renderSlot(p.$slots,`${x.type}-overlay-value`,{text:i.text,value:i.value})]),key:"0"}:void 0,p.$slots[`${x.type}-overlay`]?{name:"overlay",fn:e.withCtx(()=>[e.renderSlot(p.$slots,`${x.type}-overlay`,e.mergeProps({ref_for:!0},W.value(x.type)))]),key:"1"}:void 0,p.$slots[`${x.type}-overlay-header`]?{name:"header",fn:e.withCtx(()=>[e.renderSlot(p.$slots,`${x.type}-overlay-header`,{toggle:x.toggle})]),key:"2"}:void 0]),1032,["items","arrow-navigation","hide-navigation","is-last","config","type","esc-close","menu-wrap-ref","text-input","aria-labels","onSelected","onToggle"])):e.createCommentVNode("",!0)]),_:2},1032,["name","css"])],64))),128))],2),e.unref(D)(e.unref(k),a.instance)&&p.vertical?(e.openBlock(),e.createBlock(ha,{key:1,"aria-label":(G=e.unref(v))==null?void 0:G.prevMonth,disabled:e.unref(L)(!1),class:e.normalizeClass((d=e.unref(y))==null?void 0:d.navBtnPrev),onActivate:E[2]||(E[2]=x=>e.unref(V)(!1,!0))},{default:e.withCtx(()=>[p.$slots["arrow-up"]?e.renderSlot(p.$slots,"arrow-up",{key:0}):e.createCommentVNode("",!0),p.$slots["arrow-up"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(it),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.unref(F)(e.unref(k),a.instance)?(e.openBlock(),e.createBlock(ha,{key:2,ref:"rightIcon",disabled:e.unref(L)(!0),"aria-label":(ee=e.unref(v))==null?void 0:ee.nextMonth,class:e.normalizeClass((se=e.unref(y))==null?void 0:se.navBtnNext),onActivate:E[3]||(E[3]=x=>e.unref(V)(!0,!0)),onSetRef:E[4]||(E[4]=x=>X(x,p.disableYearSelect?2:3))},{default:e.withCtx(()=>[p.$slots[p.vertical?"arrow-down":"arrow-right"]?e.renderSlot(p.$slots,p.vertical?"arrow-down":"arrow-right",{key:0}):e.createCommentVNode("",!0),p.$slots[p.vertical?"arrow-down":"arrow-right"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(p.vertical?e.unref(st):e.unref(ot)),{key:1}))]),_:3},8,["disabled","aria-label","class"])):e.createCommentVNode("",!0)])],64))])}}}),zn=["aria-label"],Fn={class:"dp__calendar_header",role:"row"},Ln={key:0,class:"dp__calendar_header_item",role:"gridcell"},Hn=["aria-label"],qn=e.createElementVNode("div",{class:"dp__calendar_header_separator"},null,-1),Un=["aria-label"],jn={key:0,role:"gridcell",class:"dp__calendar_item dp__week_num"},Kn={class:"dp__cell_inner"},Jn=["id","aria-selected","aria-disabled","aria-label","data-test","onClick","onKeydown","onMouseenter","onMouseleave","onMousedown"],Qn=e.defineComponent({compatConfig:{MODE:3},__name:"DpCalendar",props:{mappedDates:{type:Array,default:()=>[]},instance:{type:Number,default:0},month:{type:Number,default:0},year:{type:Number,default:0},...Oe},emits:["select-date","set-hover-date","handle-scroll","mount","handle-swipe","handle-space","tooltip-open","tooltip-close"],setup(a,{expose:t,emit:r}){const n=r,l=a,{buildMultiLevelMatrix:m}=We(),{defaultedTransitions:v,defaultedConfig:k,defaultedAriaLabels:c,defaultedMultiCalendars:O,defaultedWeekNumbers:f,defaultedMultiDates:h,defaultedUI:y}=ge(l),C=e.ref(null),$=e.ref({bottom:"",left:"",transform:""}),_=e.ref([]),V=e.ref(null),L=e.ref(!0),J=e.ref(""),D=e.ref({startX:0,endX:0,startY:0,endY:0}),F=e.ref([]),K=e.ref({left:"50%"}),T=e.ref(!1),A=e.computed(()=>l.calendar?l.calendar(l.mappedDates):l.mappedDates),Z=e.computed(()=>l.dayNames?Array.isArray(l.dayNames)?l.dayNames:l.dayNames(l.locale,+l.weekStart):Cl(l.formatLocale,l.locale,+l.weekStart));e.onMounted(()=>{n("mount",{cmp:"calendar",refs:_}),k.value.noSwipe||V.value&&(V.value.addEventListener("touchstart",X,{passive:!1}),V.value.addEventListener("touchend",te,{passive:!1}),V.value.addEventListener("touchmove",oe,{passive:!1})),l.monthChangeOnScroll&&V.value&&V.value.addEventListener("wheel",o,{passive:!1})});const H=x=>x?l.vertical?"vNext":"next":l.vertical?"vPrevious":"previous",N=(x,ie)=>{if(l.transitions){const i=Ae(Le(I(),l.month,l.year));J.value=_e(Ae(Le(I(),x,ie)),i)?v.value[H(!0)]:v.value[H(!1)],L.value=!1,e.nextTick(()=>{L.value=!0})}},W=e.computed(()=>({[l.calendarClassName]:!!l.calendarClassName,...y.value.calendar??{}})),le=e.computed(()=>x=>{const ie=Bl(x);return{dp__marker_dot:ie.type==="dot",dp__marker_line:ie.type==="line"}}),re=e.computed(()=>x=>ve(x,C.value)),M=e.computed(()=>({dp__calendar:!0,dp__calendar_next:O.value.count>0&&l.instance!==0})),s=e.computed(()=>x=>l.hideOffsetDates?x.current:!0),w=async(x,ie,i)=>{const P=we(_.value[ie][i]);if(P){const{width:q,height:z}=P.getBoundingClientRect();C.value=x.value;let R={left:`${q/2}px`},me=-50;if(await e.nextTick(),F.value[0]){const{left:b,width:Q}=F.value[0].getBoundingClientRect();b<0&&(R={left:"0"},me=0,K.value.left=`${q/2}px`),window.innerWidth<b+Q&&(R={right:"0"},me=0,K.value.left=`${Q-q/2}px`)}$.value={bottom:`${z}px`,...R,transform:`translateX(${me}%)`},n("tooltip-open",x.marker)}},u=async(x,ie,i)=>{var P,q;if(T.value&&h.value.enabled&&h.value.dragSelect)return n("select-date",x);n("set-hover-date",x),(q=(P=x.marker)==null?void 0:P.tooltip)!=null&&q.length&&await w(x,ie,i)},Y=x=>{C.value&&(C.value=null,$.value=JSON.parse(JSON.stringify({bottom:"",left:"",transform:""})),n("tooltip-close",x.marker))},X=x=>{D.value.startX=x.changedTouches[0].screenX,D.value.startY=x.changedTouches[0].screenY},te=x=>{D.value.endX=x.changedTouches[0].screenX,D.value.endY=x.changedTouches[0].screenY,p()},oe=x=>{l.vertical&&!l.inline&&x.preventDefault()},p=()=>{const x=l.vertical?"Y":"X";Math.abs(D.value[`start${x}`]-D.value[`end${x}`])>10&&n("handle-swipe",D.value[`start${x}`]>D.value[`end${x}`]?"right":"left")},E=(x,ie,i)=>{x&&(Array.isArray(_.value[ie])?_.value[ie][i]=x:_.value[ie]=[x]),l.arrowNavigation&&m(_.value,"calendar")},o=x=>{l.monthChangeOnScroll&&(x.preventDefault(),n("handle-scroll",x))},B=x=>f.value.type==="local"?pl.getWeek(x.value,{weekStartsOn:+l.weekStart}):f.value.type==="iso"?fl.getISOWeek(x.value):typeof f.value.type=="function"?f.value.type(x.value):"",G=x=>{const ie=x[0];return f.value.hideOnOffsetDates?x.some(i=>i.current)?B(ie):"":B(ie)},d=(x,ie)=>{h.value.enabled||(Je(x,k.value),n("select-date",ie))},ee=x=>{Je(x,k.value)},se=x=>{h.value.enabled&&h.value.dragSelect?(T.value=!0,n("select-date",x)):h.value.enabled&&n("select-date",x)};return t({triggerTransition:N}),(x,ie)=>{var i;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(M.value)},[e.createElementVNode("div",{ref_key:"calendarWrapRef",ref:V,role:"grid",class:e.normalizeClass(W.value),"aria-label":(i=e.unref(c))==null?void 0:i.calendarWrap},[e.createElementVNode("div",Fn,[x.weekNumbers?(e.openBlock(),e.createElementBlock("div",Ln,e.toDisplayString(x.weekNumName),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Z.value,(P,q)=>{var z,R;return e.openBlock(),e.createElementBlock("div",{key:q,class:"dp__calendar_header_item",role:"gridcell","data-test":"calendar-header","aria-label":(R=(z=e.unref(c))==null?void 0:z.weekDay)==null?void 0:R.call(z,q)},[x.$slots["calendar-header"]?e.renderSlot(x.$slots,"calendar-header",{key:0,day:P,index:q}):e.createCommentVNode("",!0),x.$slots["calendar-header"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(P),1)],64))],8,Hn)}),128))]),qn,e.createVNode(e.Transition,{name:J.value,css:!!x.transitions},{default:e.withCtx(()=>{var P;return[L.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__calendar",role:"rowgroup","aria-label":((P=e.unref(c))==null?void 0:P.calendarDays)||void 0,onMouseleave:ie[1]||(ie[1]=q=>T.value=!1)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value,(q,z)=>(e.openBlock(),e.createElementBlock("div",{key:z,class:"dp__calendar_row",role:"row"},[x.weekNumbers?(e.openBlock(),e.createElementBlock("div",jn,[e.createElementVNode("div",Kn,e.toDisplayString(G(q.days)),1)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(q.days,(R,me)=>{var b,Q,de;return e.openBlock(),e.createElementBlock("div",{id:e.unref(Xt)(R.value),ref_for:!0,ref:pe=>E(pe,z,me),key:me+z,role:"gridcell",class:"dp__calendar_item","aria-selected":(R.classData.dp__active_date||R.classData.dp__range_start||R.classData.dp__range_start)??void 0,"aria-disabled":R.classData.dp__cell_disabled||void 0,"aria-label":(Q=(b=e.unref(c))==null?void 0:b.day)==null?void 0:Q.call(b,R),tabindex:"0","data-test":R.value,onClick:e.withModifiers(pe=>d(pe,R),["prevent"]),onKeydown:pe=>e.unref($e)(pe,()=>x.$emit("select-date",R)),onMouseenter:pe=>u(R,z,me),onMouseleave:pe=>Y(R),onMousedown:pe=>se(R),onMouseup:ie[0]||(ie[0]=pe=>T.value=!1)},[e.createElementVNode("div",{class:e.normalizeClass(["dp__cell_inner",R.classData])},[x.$slots.day&&s.value(R)?e.renderSlot(x.$slots,"day",{key:0,day:+R.text,date:R.value}):e.createCommentVNode("",!0),x.$slots.day?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(R.text),1)],64)),R.marker&&s.value(R)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[x.$slots.marker?e.renderSlot(x.$slots,"marker",{key:0,marker:R.marker,day:+R.text,date:R.value}):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(le.value(R.marker)),style:e.normalizeStyle(R.marker.color?{backgroundColor:R.marker.color}:{})},null,6))],64)):e.createCommentVNode("",!0),re.value(R.value)?(e.openBlock(),e.createElementBlock("div",{key:3,ref_for:!0,ref_key:"activeTooltip",ref:F,class:"dp__marker_tooltip",style:e.normalizeStyle($.value)},[(de=R.marker)!=null&&de.tooltip?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__tooltip_content",onClick:ee},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(R.marker.tooltip,(pe,xe)=>(e.openBlock(),e.createElementBlock("div",{key:xe,class:"dp__tooltip_text"},[x.$slots["marker-tooltip"]?e.renderSlot(x.$slots,"marker-tooltip",{key:0,tooltip:pe,day:R.value}):e.createCommentVNode("",!0),x.$slots["marker-tooltip"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",{class:"dp__tooltip_mark",style:e.normalizeStyle(pe.color?{backgroundColor:pe.color}:{})},null,4),e.createElementVNode("div",null,e.toDisplayString(pe.text),1)],64))]))),128)),e.createElementVNode("div",{class:"dp__arrow_bottom_tp",style:e.normalizeStyle(K.value)},null,4)])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)],2)],40,Jn)}),128))]))),128))],40,Un)):e.createCommentVNode("",!0)]}),_:3},8,["name","css"])],10,zn)],2)}}}),At=a=>Array.isArray(a),Xn=(a,t,r,n)=>{const l=e.ref([]),m=e.ref(new Date),v=e.ref(),k=()=>te(a.isTextInputDate),{modelValue:c,calendars:O,time:f,today:h}=Ca(a,t,k),{defaultedMultiCalendars:y,defaultedStartTime:C,defaultedRange:$,defaultedConfig:_,defaultedTz:V,propDates:L,defaultedMultiDates:J}=ge(a),{validateMonthYearInRange:D,isDisabled:F,isDateRangeAllowed:K,checkMinMaxRange:T}=Ge(a),{updateTimeValues:A,getSetDateTime:Z,setTime:H,assignStartTime:N,validateTime:W,disabledTimesConfig:le}=ll(a,f,c,n),re=e.computed(()=>g=>O.value[g]?O.value[g].month:0),M=e.computed(()=>g=>O.value[g]?O.value[g].year:0),s=g=>!_.value.keepViewOnOffsetClick||g?!0:!v.value,w=(g,U,S,j=!1)=>{var ae,De;s(j)&&(O.value[g]||(O.value[g]={month:0,year:0}),O.value[g].month=Ct(U)?(ae=O.value[g])==null?void 0:ae.month:U,O.value[g].year=Ct(S)?(De=O.value[g])==null?void 0:De.year:S)},u=()=>{a.autoApply&&t("select-date")};e.onMounted(()=>{a.shadow||(c.value||(ie(),C.value&&N(C.value)),te(!0),a.focusStartDate&&a.startDate&&ie())});const Y=e.computed(()=>{var g;return(g=a.flow)!=null&&g.length&&!a.partialFlow?a.flowStep===a.flow.length:!0}),X=()=>{a.autoApply&&Y.value&&t("auto-apply")},te=(g=!1)=>{if(c.value)return Array.isArray(c.value)?(l.value=c.value,d(g)):E(c.value,g);if(y.value.count&&g&&!a.startDate)return p(I(),g)},oe=()=>Array.isArray(c.value)&&$.value.enabled?ce.getMonth(c.value[0])===ce.getMonth(c.value[1]??c.value[0]):!1,p=(g=new Date,U=!1)=>{if((!y.value.count||!y.value.static||U)&&w(0,ce.getMonth(g),ue.getYear(g)),y.value.count&&(!y.value.solo||!c.value||oe()))for(let S=1;S<y.value.count;S++){const j=fe.set(I(),{month:re.value(S-1),year:M.value(S-1)}),ae=Tt.add(j,{months:1});O.value[S]={month:ce.getMonth(ae),year:ue.getYear(ae)}}},E=(g,U)=>{p(g),H("hours",He.getHours(g)),H("minutes",Xe.getMinutes(g)),H("seconds",sa.getSeconds(g)),y.value.count&&U&&x()},o=g=>{if(y.value.count){if(y.value.solo)return 0;const U=ce.getMonth(g[0]),S=ce.getMonth(g[1]);return Math.abs(S-U)<y.value.count?0:1}return 1},B=(g,U)=>{g[1]&&$.value.showLastInRange?p(g[o(g)],U):p(g[0],U);const S=(j,ae)=>[j(g[0]),g[1]?j(g[1]):f[ae][1]];H("hours",S(He.getHours,"hours")),H("minutes",S(Xe.getMinutes,"minutes")),H("seconds",S(sa.getSeconds,"seconds"))},G=(g,U)=>{if(($.value.enabled||a.weekPicker)&&!J.value.enabled)return B(g,U);if(J.value.enabled&&U){const S=g[g.length-1];return E(S,U)}},d=g=>{const U=c.value;G(U,g),y.value.count&&y.value.solo&&x()},ee=(g,U)=>{const S=fe.set(I(),{month:re.value(U),year:M.value(U)}),j=g<0?ta.addMonths(S,1):ka.subMonths(S,1);D(ce.getMonth(j),ue.getYear(j),g<0,a.preventMinMaxNavigation)&&(w(U,ce.getMonth(j),ue.getYear(j)),t("update-month-year",{instance:U,month:ce.getMonth(j),year:ue.getYear(j)}),y.value.count&&!y.value.solo&&se(U),r())},se=g=>{for(let U=g-1;U>=0;U--){const S=ka.subMonths(fe.set(I(),{month:re.value(U+1),year:M.value(U+1)}),1);w(U,ce.getMonth(S),ue.getYear(S))}for(let U=g+1;U<=y.value.count-1;U++){const S=ta.addMonths(fe.set(I(),{month:re.value(U-1),year:M.value(U-1)}),1);w(U,ce.getMonth(S),ue.getYear(S))}},x=()=>{if(Array.isArray(c.value)&&c.value.length===2){const g=I(I(c.value[1]?c.value[1]:ta.addMonths(c.value[0],1))),[U,S]=[ce.getMonth(c.value[0]),ue.getYear(c.value[0])],[j,ae]=[ce.getMonth(c.value[1]),ue.getYear(c.value[1])];(U!==j||U===j&&S!==ae)&&y.value.solo&&w(1,ce.getMonth(g),ue.getYear(g))}else c.value&&!Array.isArray(c.value)&&(w(0,ce.getMonth(c.value),ue.getYear(c.value)),p(I()))},ie=()=>{a.startDate&&(w(0,ce.getMonth(I(a.startDate)),ue.getYear(I(a.startDate))),y.value.count&&se(0))},i=(g,U)=>{if(a.monthChangeOnScroll){const S=new Date().getTime()-m.value.getTime(),j=Math.abs(g.deltaY);let ae=500;j>1&&(ae=100),j>100&&(ae=0),S>ae&&(m.value=new Date,ee(a.monthChangeOnScroll!=="inverse"?-g.deltaY:g.deltaY,U))}},P=(g,U,S=!1)=>{a.monthChangeOnArrows&&a.vertical===S&&q(g,U)},q=(g,U)=>{ee(g==="right"?-1:1,U)},z=g=>{if(L.value.markers)return $a(g.value,L.value.markers)},R=(g,U)=>{switch(a.sixWeeks===!0?"append":a.sixWeeks){case"prepend":return[!0,!1];case"center":return[g==0,!0];case"fair":return[g==0||U>g,!0];case"append":return[!1,!1];default:return[!1,!1]}},me=(g,U,S,j)=>{if(a.sixWeeks&&g.length<6){const ae=6-g.length,De=(U.getDay()+7-j)%7,Ve=6-(S.getDay()+7-j)%7,[Ze,Ba]=R(De,Ve);for(let fa=1;fa<=ae;fa++)if(Ba?!!(fa%2)==Ze:Ze){const Ue=g[0].days[0],Ha=b(aa.addDays(Ue.value,-7),ce.getMonth(U));g.unshift({days:Ha})}else{const Ue=g[g.length-1],Ha=Ue.days[Ue.days.length-1],nl=b(aa.addDays(Ha.value,1),ce.getMonth(U));g.push({days:nl})}}return g},b=(g,U)=>{const S=I(g),j=[];for(let ae=0;ae<7;ae++){const De=aa.addDays(S,ae),Ve=ce.getMonth(De)!==U;j.push({text:a.hideOffsetDates&&Ve?"":De.getDate(),value:De,current:!Ve,classData:{}})}return j},Q=(g,U)=>{const S=[],j=new Date(U,g),ae=new Date(U,g+1,0),De=a.weekStart,Ve=nt.startOfWeek(j,{weekStartsOn:De}),Ze=Ba=>{const fa=b(Ba,g);if(S.push({days:fa}),!S[S.length-1].days.some(Ue=>ve(Ae(Ue.value),Ae(ae)))){const Ue=aa.addDays(Ba,7);Ze(Ue)}};return Ze(Ve),me(S,j,ae,De)},de=g=>{const U=Qe(I(g.value),f.hours,f.minutes,Te());t("date-update",U),J.value.enabled?ft(U,c,J.value.limit):c.value=U,n(),e.nextTick().then(()=>{X()})},pe=g=>$.value.noDisabledRange?Ut(l.value[0],g).some(U=>F(U)):!1,xe=()=>{l.value=c.value?c.value.slice():[],l.value.length===2&&!($.value.fixedStart||$.value.fixedEnd)&&(l.value=[])},ne=(g,U)=>{const S=[I(g.value),aa.addDays(I(g.value),+$.value.autoRange)];K(S)?(U&&qe(g.value),l.value=S):t("invalid-date",g.value)},qe=g=>{const U=ce.getMonth(I(g)),S=ue.getYear(I(g));if(w(0,U,S),y.value.count>0)for(let j=1;j<y.value.count;j++){const ae=Pl(fe.set(I(g),{year:re.value(j-1),month:M.value(j-1)}));w(j,ae.month,ae.year)}},Ye=g=>{if(pe(g.value)||!T(g.value,c.value,$.value.fixedStart?0:1))return t("invalid-date",g.value);l.value=el(I(g.value),c,t,$)},va=(g,U)=>{if(xe(),$.value.autoRange)return ne(g,U);if($.value.fixedStart||$.value.fixedEnd)return Ye(g);l.value[0]?T(I(g.value),c.value)&&!pe(g.value)?ke(I(g.value),I(l.value[0]))?(l.value.unshift(I(g.value)),t("range-end",l.value[0])):(l.value[1]=I(g.value),t("range-end",l.value[1])):(a.autoApply&&t("auto-apply-invalid",g.value),t("invalid-date",g.value)):(l.value[0]=I(g.value),t("range-start",l.value[0]))},Te=(g=!0)=>a.enableSeconds?Array.isArray(f.seconds)?g?f.seconds[0]:f.seconds[1]:f.seconds:0,pa=g=>{l.value[g]=Qe(l.value[g],f.hours[g],f.minutes[g],Te(g!==1))},Ra=()=>{var g,U;l.value[0]&&l.value[1]&&+((g=l.value)==null?void 0:g[0])>+((U=l.value)==null?void 0:U[1])&&(l.value.reverse(),t("range-start",l.value[0]),t("range-end",l.value[1]))},Sa=()=>{l.value.length&&(l.value[0]&&!l.value[1]?pa(0):(pa(0),pa(1),n()),Ra(),c.value=l.value.slice(),Va(l.value,t,a.autoApply,a.modelAuto))},Oa=(g,U=!1)=>{if(F(g.value)||!g.current&&a.hideOffsetDates)return t("invalid-date",g.value);if(v.value=JSON.parse(JSON.stringify(g)),!$.value.enabled)return de(g);At(f.hours)&&At(f.minutes)&&!J.value.enabled&&(va(g,U),Sa())},Ya=(g,U)=>{var S;w(g,U.month,U.year,!0),y.value.count&&!y.value.solo&&se(g),t("update-month-year",{instance:g,month:U.month,year:U.year}),r(y.value.solo?g:void 0);const j=(S=a.flow)!=null&&S.length?a.flow[a.flowStep]:void 0;!U.fromNav&&(j===Be.month||j===Be.year)&&n()},Ia=(g,U)=>{Zt({value:g,modelValue:c,range:$.value.enabled,timezone:U?void 0:V.value.timezone}),u(),a.multiCalendars&&e.nextTick().then(()=>te(!0))},za=()=>{const g=dt(I(),V.value);$.value.enabled?c.value&&Array.isArray(c.value)&&c.value[0]?c.value=ke(g,c.value[0])?[g,c.value[0]]:[c.value[0],g]:c.value=[g]:c.value=g,u()},Fa=()=>{if(Array.isArray(c.value))if(J.value.enabled){const g=La();c.value[c.value.length-1]=Z(g)}else c.value=c.value.map((g,U)=>g&&Z(g,U));else c.value=Z(c.value);t("time-update")},La=()=>Array.isArray(c.value)&&c.value.length?c.value[c.value.length-1]:null;return{calendars:O,modelValue:c,month:re,year:M,time:f,disabledTimesConfig:le,today:h,validateTime:W,getCalendarDays:Q,getMarker:z,handleScroll:i,handleSwipe:q,handleArrow:P,selectDate:Oa,updateMonthYear:Ya,presetDate:Ia,selectCurrentDate:za,updateTime:(g,U=!0,S=!1)=>{A(g,U,S,Fa)},assignMonthAndYear:p}},Wn={key:0},Gn=e.defineComponent({__name:"DatePicker",props:{...Oe},emits:["tooltip-open","tooltip-close","mount","update:internal-model-value","update-flow-step","reset-flow","auto-apply","focus-menu","select-date","range-start","range-end","invalid-fixed-range","time-update","am-pm-change","time-picker-open","time-picker-close","recalculate-position","update-month-year","auto-apply-invalid","date-update","invalid-date","overlay-toggle"],setup(a,{expose:t,emit:r}){const n=r,l=a,{calendars:m,month:v,year:k,modelValue:c,time:O,disabledTimesConfig:f,today:h,validateTime:y,getCalendarDays:C,getMarker:$,handleArrow:_,handleScroll:V,handleSwipe:L,selectDate:J,updateMonthYear:D,presetDate:F,selectCurrentDate:K,updateTime:T,assignMonthAndYear:A}=Xn(l,n,oe,p),Z=e.useSlots(),{setHoverDate:H,getDayClassData:N,clearHoverDate:W}=pr(c,l),{defaultedMultiCalendars:le}=ge(l),re=e.ref([]),M=e.ref([]),s=e.ref(null),w=Ne(Z,"calendar"),u=Ne(Z,"monthYear"),Y=Ne(Z,"timePicker"),X=i=>{l.shadow||n("mount",i)};e.watch(m,()=>{l.shadow||setTimeout(()=>{n("recalculate-position")},0)},{deep:!0}),e.watch(le,(i,P)=>{i.count-P.count>0&&A()},{deep:!0});const te=e.computed(()=>i=>C(v.value(i),k.value(i)).map(P=>({...P,days:P.days.map(q=>(q.marker=$(q),q.classData=N(q),q))})));function oe(i){var P;i||i===0?(P=M.value[i])==null||P.triggerTransition(v.value(i),k.value(i)):M.value.forEach((q,z)=>q.triggerTransition(v.value(z),k.value(z)))}function p(){n("update-flow-step")}const E=(i,P=!1)=>{J(i,P),l.spaceConfirm&&n("select-date")},o=(i,P,q=0)=>{var z;(z=re.value[q])==null||z.toggleMonthPicker(i,P)},B=(i,P,q=0)=>{var z;(z=re.value[q])==null||z.toggleYearPicker(i,P)},G=(i,P,q)=>{var z;(z=s.value)==null||z.toggleTimePicker(i,P,q)},d=(i,P)=>{var q;if(!l.range){const z=c.value?c.value:h,R=P?new Date(P):z,me=i?nt.startOfWeek(R,{weekStartsOn:1}):Nt.endOfWeek(R,{weekStartsOn:1});J({value:me,current:ce.getMonth(R)===v.value(0),text:"",classData:{}}),(q=document.getElementById(Xt(me)))==null||q.focus()}},ee=i=>{var P;(P=re.value[0])==null||P.handleMonthYearChange(i,!0)},se=i=>{D(0,{month:v.value(0),year:k.value(0)+(i?1:-1),fromNav:!0})},x=(i,P)=>{i===Be.time&&n(`time-picker-${P?"open":"close"}`),n("overlay-toggle",{open:P,overlay:i})},ie=i=>{n("overlay-toggle",{open:!1,overlay:i}),n("focus-menu")};return t({clearHoverDate:W,presetDate:F,selectCurrentDate:K,toggleMonthPicker:o,toggleYearPicker:B,toggleTimePicker:G,handleArrow:_,updateMonthYear:D,getSidebarProps:()=>({modelValue:c,month:v,year:k,time:O,updateTime:T,updateMonthYear:D,selectDate:J,presetDate:F}),changeMonth:ee,changeYear:se,selectWeekDate:d}),(i,P)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(Pa,{"multi-calendars":e.unref(le).count,collapse:i.collapse},{default:e.withCtx(({instance:q,index:z})=>[i.disableMonthYearSelect?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(In,e.mergeProps({key:0,ref:R=>{R&&(re.value[z]=R)},months:e.unref(It)(i.formatLocale,i.locale,i.monthNameFormat),years:e.unref(ct)(i.yearRange,i.locale,i.reverseYears),month:e.unref(v)(q),year:e.unref(k)(q),instance:q},i.$props,{onMount:P[0]||(P[0]=R=>X(e.unref(la).header)),onResetFlow:P[1]||(P[1]=R=>i.$emit("reset-flow")),onUpdateMonthYear:R=>e.unref(D)(q,R),onOverlayClosed:ie,onOverlayOpened:P[2]||(P[2]=R=>i.$emit("overlay-toggle",{open:!0,overlay:R}))}),e.createSlots({_:2},[e.renderList(e.unref(u),(R,me)=>({name:R,fn:e.withCtx(b=>[e.renderSlot(i.$slots,R,e.normalizeProps(e.guardReactiveProps(b)))])}))]),1040,["months","years","month","year","instance","onUpdateMonthYear"])),e.createVNode(Qn,e.mergeProps({ref:R=>{R&&(M.value[z]=R)},"mapped-dates":te.value(q),month:e.unref(v)(q),year:e.unref(k)(q),instance:q},i.$props,{onSelectDate:R=>e.unref(J)(R,q!==1),onHandleSpace:R=>E(R,q!==1),onSetHoverDate:P[3]||(P[3]=R=>e.unref(H)(R)),onHandleScroll:R=>e.unref(V)(R,q),onHandleSwipe:R=>e.unref(L)(R,q),onMount:P[4]||(P[4]=R=>X(e.unref(la).calendar)),onResetFlow:P[5]||(P[5]=R=>i.$emit("reset-flow")),onTooltipOpen:P[6]||(P[6]=R=>i.$emit("tooltip-open",R)),onTooltipClose:P[7]||(P[7]=R=>i.$emit("tooltip-close",R))}),e.createSlots({_:2},[e.renderList(e.unref(w),(R,me)=>({name:R,fn:e.withCtx(b=>[e.renderSlot(i.$slots,R,e.normalizeProps(e.guardReactiveProps({...b})))])}))]),1040,["mapped-dates","month","year","instance","onSelectDate","onHandleSpace","onHandleScroll","onHandleSwipe"])]),_:3},8,["multi-calendars","collapse"]),i.enableTimePicker?(e.openBlock(),e.createElementBlock("div",Wn,[i.$slots["time-picker"]?e.renderSlot(i.$slots,"time-picker",e.normalizeProps(e.mergeProps({key:0},{time:e.unref(O),updateTime:e.unref(T)}))):(e.openBlock(),e.createBlock(tl,e.mergeProps({key:1,ref_key:"timePickerRef",ref:s},i.$props,{hours:e.unref(O).hours,minutes:e.unref(O).minutes,seconds:e.unref(O).seconds,"internal-model-value":i.internalModelValue,"disabled-times-config":e.unref(f),"validate-time":e.unref(y),onMount:P[8]||(P[8]=q=>X(e.unref(la).timePicker)),"onUpdate:hours":P[9]||(P[9]=q=>e.unref(T)(q)),"onUpdate:minutes":P[10]||(P[10]=q=>e.unref(T)(q,!1)),"onUpdate:seconds":P[11]||(P[11]=q=>e.unref(T)(q,!1,!0)),onResetFlow:P[12]||(P[12]=q=>i.$emit("reset-flow")),onOverlayClosed:P[13]||(P[13]=q=>x(q,!1)),onOverlayOpened:P[14]||(P[14]=q=>x(q,!0)),onAmPmChange:P[15]||(P[15]=q=>i.$emit("am-pm-change",q))}),e.createSlots({_:2},[e.renderList(e.unref(Y),(q,z)=>({name:q,fn:e.withCtx(R=>[e.renderSlot(i.$slots,q,e.normalizeProps(e.guardReactiveProps(R)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config","validate-time"]))])):e.createCommentVNode("",!0)],64))}}),Zn=(a,t)=>{const r=e.ref(),{defaultedMultiCalendars:n,defaultedConfig:l,defaultedHighlight:m,defaultedRange:v,propDates:k,defaultedFilters:c,defaultedMultiDates:O}=ge(a),{modelValue:f,year:h,month:y,calendars:C}=Ca(a,t),{isDisabled:$}=Ge(a),{selectYear:_,groupedYears:V,showYearPicker:L,isDisabled:J,toggleYearPicker:D,handleYearSelect:F,handleYear:K}=al({modelValue:f,multiCalendars:n,range:v,highlight:m,calendars:C,propDates:k,month:y,year:h,filters:c,props:a,emit:t}),T=(s,w)=>[s,w].map(u=>ze.formatDate(u,"MMMM",{locale:a.formatLocale})).join("-"),A=e.computed(()=>s=>f.value?Array.isArray(f.value)?f.value.some(w=>gt.isSameQuarter(s,w)):gt.isSameQuarter(f.value,s):!1),Z=s=>{if(v.value.enabled){if(Array.isArray(f.value)){const w=ve(s,f.value[0])||ve(s,f.value[1]);return Ta(f.value,r.value,s)&&!w}return!1}return!1},H=(s,w)=>s.quarter===bt.getQuarter(w)&&s.year===ue.getYear(w),N=s=>typeof m.value=="function"?m.value({quarter:bt.getQuarter(s),year:ue.getYear(s)}):!!m.value.quarters.find(w=>H(w,s)),W=e.computed(()=>s=>{const w=fe.set(new Date,{year:h.value(s)});return sl.eachQuarterOfInterval({start:xa.startOfYear(w),end:Pt.endOfYear(w)}).map(u=>{const Y=dl.startOfQuarter(u),X=kt.endOfQuarter(u),te=$(u),oe=Z(Y),p=N(Y);return{text:T(Y,X),value:Y,active:A.value(Y),highlighted:p,disabled:te,isBetween:oe}})}),le=s=>{ft(s,f,O.value.limit),t("auto-apply",!0)},re=s=>{f.value=yt(f,s,t),Va(f.value,t,a.autoApply,a.modelAuto)},M=s=>{f.value=s,t("auto-apply")};return{defaultedConfig:l,defaultedMultiCalendars:n,groupedYears:V,year:h,isDisabled:J,quarters:W,showYearPicker:L,modelValue:f,setHoverDate:s=>{r.value=s},selectYear:_,selectQuarter:(s,w,u)=>{if(!u)return C.value[w].month=ce.getMonth(kt.endOfQuarter(s)),O.value.enabled?le(s):v.value.enabled?re(s):M(s)},toggleYearPicker:D,handleYearSelect:F,handleYear:K}},er={class:"dp--quarter-items"},ar=["data-test","disabled","onClick","onMouseover"],tr=e.defineComponent({compatConfig:{MODE:3},__name:"QuarterPicker",props:{...Oe},emits:["update:internal-model-value","reset-flow","overlay-closed","auto-apply","range-start","range-end","overlay-toggle","update-month-year"],setup(a,{expose:t,emit:r}){const n=r,l=a,m=e.useSlots(),v=Ne(m,"yearMode"),{defaultedMultiCalendars:k,defaultedConfig:c,groupedYears:O,year:f,isDisabled:h,quarters:y,modelValue:C,showYearPicker:$,setHoverDate:_,selectQuarter:V,toggleYearPicker:L,handleYearSelect:J,handleYear:D}=Zn(l,n);return t({getSidebarProps:()=>({modelValue:C,year:f,selectQuarter:V,handleYearSelect:J,handleYear:D})}),(F,K)=>(e.openBlock(),e.createBlock(Pa,{"multi-calendars":e.unref(k).count,collapse:F.collapse,stretch:""},{default:e.withCtx(({instance:T})=>[e.createElementVNode("div",{class:"dp-quarter-picker-wrap",style:e.normalizeStyle({minHeight:`${e.unref(c).modeHeight}px`})},[F.$slots["top-extra"]?e.renderSlot(F.$slots,"top-extra",{key:0,value:F.internalModelValue}):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.createVNode(Gt,e.mergeProps(F.$props,{items:e.unref(O)(T),instance:T,"show-year-picker":e.unref($)[T],year:e.unref(f)(T),"is-disabled":A=>e.unref(h)(T,A),onHandleYear:A=>e.unref(D)(T,A),onYearSelect:A=>e.unref(J)(A,T),onToggleYearPicker:A=>e.unref(L)(T,A==null?void 0:A.flow,A==null?void 0:A.show)}),e.createSlots({_:2},[e.renderList(e.unref(v),(A,Z)=>({name:A,fn:e.withCtx(H=>[e.renderSlot(F.$slots,A,e.normalizeProps(e.guardReactiveProps(H)))])}))]),1040,["items","instance","show-year-picker","year","is-disabled","onHandleYear","onYearSelect","onToggleYearPicker"])]),e.createElementVNode("div",er,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(y)(T),(A,Z)=>(e.openBlock(),e.createElementBlock("div",{key:Z},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["dp--qr-btn",{"dp--qr-btn-active":A.active,"dp--qr-btn-between":A.isBetween,"dp--qr-btn-disabled":A.disabled,"dp--highlighted":A.highlighted}]),"data-test":A.value,disabled:A.disabled,onClick:H=>e.unref(V)(A.value,T,A.disabled),onMouseover:H=>e.unref(_)(A.value)},[F.$slots.quarter?e.renderSlot(F.$slots,"quarter",{key:0,value:A.value,text:A.text}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(A.text),1)],64))],42,ar)]))),128))])],4)]),_:3},8,["multi-calendars","collapse"]))}}),lr=["id","aria-label"],nr={key:0,class:"dp--menu-load-container"},rr=e.createElementVNode("span",{class:"dp--menu-loader"},null,-1),or=[rr],ur={key:0,class:"dp__sidebar_left"},ir=["data-test","onClick","onKeydown"],sr={key:2,class:"dp__sidebar_right"},dr={key:3,class:"dp__action_extra"},xt=e.defineComponent({compatConfig:{MODE:3},__name:"DatepickerMenu",props:{...Na,shadow:{type:Boolean,default:!1},openOnTop:{type:Boolean,default:!1},internalModelValue:{type:[Date,Array],default:null},noOverlayFocus:{type:Boolean,default:!1},collapse:{type:Boolean,default:!1},getInputRect:{type:Function,default:()=>({})},isTextInputDate:{type:Boolean,default:!1}},emits:["close-picker","select-date","auto-apply","time-update","flow-step","update-month-year","invalid-select","update:internal-model-value","recalculate-position","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end","auto-apply-invalid","date-update","invalid-date","overlay-toggle"],setup(a,{expose:t,emit:r}){const n=r,l=a,m=e.ref(null),v=e.computed(()=>{const{openOnTop:b,...Q}=l;return{...Q,flowStep:H.value,collapse:l.collapse,noOverlayFocus:l.noOverlayFocus,menuWrapRef:m.value}}),{setMenuFocused:k,setShiftKey:c,control:O}=Wt(),f=e.useSlots(),{defaultedTextInput:h,defaultedInline:y,defaultedConfig:C,defaultedUI:$}=ge(l),_=e.ref(null),V=e.ref(0),L=e.ref(null),J=e.ref(!1),D=e.ref(null);e.onMounted(()=>{if(!l.shadow){J.value=!0,F(),window.addEventListener("resize",F);const b=we(m);if(b&&!h.value.enabled&&!y.value.enabled&&(k(!0),w()),b){const Q=de=>{C.value.allowPreventDefault&&de.preventDefault(),Je(de,C.value,!0)};b.addEventListener("pointerdown",Q),b.addEventListener("mousedown",Q)}}}),e.onUnmounted(()=>{window.removeEventListener("resize",F)});const F=()=>{const b=we(L);b&&(V.value=b.getBoundingClientRect().width)},{arrowRight:K,arrowLeft:T,arrowDown:A,arrowUp:Z}=We(),{flowStep:H,updateFlowStep:N,childMount:W,resetFlow:le,handleFlow:re}=fr(l,n,D),M=e.computed(()=>l.monthPicker?pn:l.yearPicker?yn:l.timePicker?Pn:l.quarterPicker?tr:Gn),s=e.computed(()=>{var b;if(C.value.arrowLeft)return C.value.arrowLeft;const Q=(b=m.value)==null?void 0:b.getBoundingClientRect(),de=l.getInputRect();return de.width<V.value&&de.left<=((Q==null?void 0:Q.left)??0)?`${de.width/2}px`:"50%"}),w=()=>{const b=we(m);b&&b.focus({preventScroll:!0})},u=e.computed(()=>{var b;return((b=D.value)==null?void 0:b.getSidebarProps())||{}}),Y=()=>{l.openOnTop&&n("recalculate-position")},X=Ne(f,"action"),te=e.computed(()=>l.monthPicker||l.yearPicker?Ne(f,"monthYear"):l.timePicker?Ne(f,"timePicker"):Ne(f,"shared")),oe=e.computed(()=>l.openOnTop?"dp__arrow_bottom":"dp__arrow_top"),p=e.computed(()=>({dp__menu_disabled:l.disabled,dp__menu_readonly:l.readonly,"dp-menu-loading":l.loading})),E=e.computed(()=>({dp__menu:!0,dp__menu_index:!y.value.enabled,dp__relative:y.value.enabled,[l.menuClassName]:!!l.menuClassName,...$.value.menu??{}})),o=b=>{Je(b,C.value,!0)},B=()=>{l.escClose&&n("close-picker")},G=b=>{if(l.arrowNavigation){if(b===Me.up)return Z();if(b===Me.down)return A();if(b===Me.left)return T();if(b===Me.right)return K()}else b===Me.left||b===Me.up?ie("handleArrow",Me.left,0,b===Me.up):ie("handleArrow",Me.right,0,b===Me.down)},d=b=>{c(b.shiftKey),!l.disableMonthYearSelect&&b.code===he.tab&&b.target.classList.contains("dp__menu")&&O.value.shiftKeyInMenu&&(b.preventDefault(),Je(b,C.value,!0),n("close-picker"))},ee=()=>{w(),n("time-picker-close")},se=b=>{var Q,de,pe;(Q=D.value)==null||Q.toggleTimePicker(!1,!1),(de=D.value)==null||de.toggleMonthPicker(!1,!1,b),(pe=D.value)==null||pe.toggleYearPicker(!1,!1,b)},x=(b,Q=0)=>{var de,pe,xe;return b==="month"?(de=D.value)==null?void 0:de.toggleMonthPicker(!1,!0,Q):b==="year"?(pe=D.value)==null?void 0:pe.toggleYearPicker(!1,!0,Q):b==="time"?(xe=D.value)==null?void 0:xe.toggleTimePicker(!0,!1):se(Q)},ie=(b,...Q)=>{var de,pe;(de=D.value)!=null&&de[b]&&((pe=D.value)==null||pe[b](...Q))},i=()=>{ie("selectCurrentDate")},P=(b,Q)=>{ie("presetDate",b,Q)},q=()=>{ie("clearHoverDate")},z=(b,Q)=>{ie("updateMonthYear",b,Q)},R=(b,Q)=>{b.preventDefault(),G(Q)},me=b=>{var Q;if(d(b),b.key===he.home||b.key===he.end)return ie("selectWeekDate",b.key===he.home,b.target.getAttribute("id"));switch((b.key===he.pageUp||b.key===he.pageDown)&&(b.shiftKey?ie("changeYear",b.key===he.pageUp):ie("changeMonth",b.key===he.pageUp),b.target.getAttribute("id")&&((Q=m.value)==null||Q.focus({preventScroll:!0}))),b.key){case he.esc:return B();case he.arrowLeft:return R(b,Me.left);case he.arrowRight:return R(b,Me.right);case he.arrowUp:return R(b,Me.up);case he.arrowDown:return R(b,Me.down);default:return}};return t({updateMonthYear:z,switchView:x,handleFlow:re}),(b,Q)=>{var de,pe,xe;return e.openBlock(),e.createElementBlock("div",{id:b.uid?`dp-menu-${b.uid}`:void 0,ref_key:"dpMenuRef",ref:m,tabindex:"0",role:"dialog","aria-label":(de=b.ariaLabels)==null?void 0:de.menu,class:e.normalizeClass(E.value),style:e.normalizeStyle({"--dp-arrow-left":s.value}),onMouseleave:q,onClick:o,onKeydown:me},[(b.disabled||b.readonly)&&e.unref(y).enabled||b.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(p.value)},[b.loading?(e.openBlock(),e.createElementBlock("div",nr,or)):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0),!e.unref(y).enabled&&!b.teleportCenter?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(oe.value)},null,2)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"innerMenuRef",ref:L,class:e.normalizeClass({dp__menu_content_wrapper:((pe=b.presetDates)==null?void 0:pe.length)||!!b.$slots["left-sidebar"]||!!b.$slots["right-sidebar"],"dp--menu-content-wrapper-collapsed":a.collapse&&(((xe=b.presetDates)==null?void 0:xe.length)||!!b.$slots["left-sidebar"]||!!b.$slots["right-sidebar"])}),style:e.normalizeStyle({"--dp-menu-width":`${V.value}px`})},[b.$slots["left-sidebar"]?(e.openBlock(),e.createElementBlock("div",ur,[e.renderSlot(b.$slots,"left-sidebar",e.normalizeProps(e.guardReactiveProps(u.value)))])):e.createCommentVNode("",!0),b.presetDates.length?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass({"dp--preset-dates-collapsed":a.collapse,"dp--preset-dates":!0})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.presetDates,(ne,qe)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:qe},[ne.slot?e.renderSlot(b.$slots,ne.slot,{key:0,presetDate:P,label:ne.label,value:ne.value}):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",style:e.normalizeStyle(ne.style||{}),class:e.normalizeClass(["dp__btn dp--preset-range",{"dp--preset-range-collapsed":a.collapse}]),"data-test":ne.testId??void 0,onClick:e.withModifiers(Ye=>P(ne.value,ne.noTz),["prevent"]),onKeydown:Ye=>e.unref($e)(Ye,()=>P(ne.value,ne.noTz),!0)},e.toDisplayString(ne.label),47,ir))],64))),128))],2)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"calendarWrapperRef",ref:_,class:"dp__instance_calendar",role:"document"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(M.value),e.mergeProps({ref_key:"dynCmpRef",ref:D},v.value,{"flow-step":e.unref(H),onMount:e.unref(W),onUpdateFlowStep:e.unref(N),onResetFlow:e.unref(le),onFocusMenu:w,onSelectDate:Q[0]||(Q[0]=ne=>b.$emit("select-date")),onDateUpdate:Q[1]||(Q[1]=ne=>b.$emit("date-update",ne)),onTooltipOpen:Q[2]||(Q[2]=ne=>b.$emit("tooltip-open",ne)),onTooltipClose:Q[3]||(Q[3]=ne=>b.$emit("tooltip-close",ne)),onAutoApply:Q[4]||(Q[4]=ne=>b.$emit("auto-apply",ne)),onRangeStart:Q[5]||(Q[5]=ne=>b.$emit("range-start",ne)),onRangeEnd:Q[6]||(Q[6]=ne=>b.$emit("range-end",ne)),onInvalidFixedRange:Q[7]||(Q[7]=ne=>b.$emit("invalid-fixed-range",ne)),onTimeUpdate:Q[8]||(Q[8]=ne=>b.$emit("time-update")),onAmPmChange:Q[9]||(Q[9]=ne=>b.$emit("am-pm-change",ne)),onTimePickerOpen:Q[10]||(Q[10]=ne=>b.$emit("time-picker-open",ne)),onTimePickerClose:ee,onRecalculatePosition:Y,onUpdateMonthYear:Q[11]||(Q[11]=ne=>b.$emit("update-month-year",ne)),onAutoApplyInvalid:Q[12]||(Q[12]=ne=>b.$emit("auto-apply-invalid",ne)),onInvalidDate:Q[13]||(Q[13]=ne=>b.$emit("invalid-date",ne)),onOverlayToggle:Q[14]||(Q[14]=ne=>b.$emit("overlay-toggle",ne)),"onUpdate:internalModelValue":Q[15]||(Q[15]=ne=>b.$emit("update:internal-model-value",ne))}),e.createSlots({_:2},[e.renderList(te.value,(ne,qe)=>({name:ne,fn:e.withCtx(Ye=>[e.renderSlot(b.$slots,ne,e.normalizeProps(e.guardReactiveProps({...Ye})))])}))]),1040,["flow-step","onMount","onUpdateFlowStep","onResetFlow"]))],512),b.$slots["right-sidebar"]?(e.openBlock(),e.createElementBlock("div",sr,[e.renderSlot(b.$slots,"right-sidebar",e.normalizeProps(e.guardReactiveProps(u.value)))])):e.createCommentVNode("",!0),b.$slots["action-extra"]?(e.openBlock(),e.createElementBlock("div",dr,[b.$slots["action-extra"]?e.renderSlot(b.$slots,"action-extra",{key:0,selectCurrentDate:i}):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],6),!b.autoApply||e.unref(C).keepActionRow?(e.openBlock(),e.createBlock(rn,e.mergeProps({key:2,"menu-mount":J.value},v.value,{"calendar-width":V.value,onClosePicker:Q[16]||(Q[16]=ne=>b.$emit("close-picker")),onSelectDate:Q[17]||(Q[17]=ne=>b.$emit("select-date")),onInvalidSelect:Q[18]||(Q[18]=ne=>b.$emit("invalid-select")),onSelectNow:i}),e.createSlots({_:2},[e.renderList(e.unref(X),(ne,qe)=>({name:ne,fn:e.withCtx(Ye=>[e.renderSlot(b.$slots,ne,e.normalizeProps(e.guardReactiveProps({...Ye})))])}))]),1040,["menu-mount","calendar-width"])):e.createCommentVNode("",!0)],46,lr)}}});var oa=(a=>(a.center="center",a.left="left",a.right="right",a))(oa||{});const cr=({menuRef:a,menuRefInner:t,inputRef:r,pickerWrapperRef:n,inline:l,emit:m,props:v,slots:k})=>{const c=e.ref({}),O=e.ref(!1),f=e.ref({top:"0",left:"0"}),h=e.ref(!1),y=e.toRef(v,"teleportCenter");e.watch(y,()=>{f.value=JSON.parse(JSON.stringify({})),F()});const C=s=>{if(v.teleport){const w=s.getBoundingClientRect();return{left:w.left+window.scrollX,top:w.top+window.scrollY}}return{top:0,left:0}},$=(s,w)=>{f.value.left=`${s+w-c.value.width}px`},_=s=>{f.value.left=`${s}px`},V=(s,w)=>{v.position===oa.left&&_(s),v.position===oa.right&&$(s,w),v.position===oa.center&&(f.value.left=`${s+w/2-c.value.width/2}px`)},L=s=>{const{width:w,height:u}=s.getBoundingClientRect(),{top:Y,left:X}=v.altPosition?v.altPosition(s):C(s);return{top:+Y,left:+X,width:w,height:u}},J=()=>{f.value.left="50%",f.value.top="50%",f.value.transform="translate(-50%, -50%)",f.value.position="fixed",delete f.value.opacity},D=()=>{const s=we(r),{top:w,left:u,transform:Y}=v.altPosition(s);f.value={top:`${w}px`,left:`${u}px`,transform:Y??""}},F=(s=!0)=>{var w;if(!l.value.enabled){if(y.value)return J();if(v.altPosition!==null)return D();if(s){const u=v.teleport?(w=t.value)==null?void 0:w.$el:a.value;u&&(c.value=u.getBoundingClientRect()),m("recalculate-position")}return W()}},K=({inputEl:s,left:w,width:u})=>{window.screen.width>768&&!O.value&&V(w,u),Z(s)},T=s=>{const{top:w,left:u,height:Y,width:X}=L(s);f.value.top=`${Y+w+ +v.offset}px`,h.value=!1,O.value||(f.value.left=`${u+X/2-c.value.width/2}px`),K({inputEl:s,left:u,width:X})},A=s=>{const{top:w,left:u,width:Y}=L(s);f.value.top=`${w-+v.offset-c.value.height}px`,h.value=!0,K({inputEl:s,left:u,width:Y})},Z=s=>{if(v.autoPosition){const{left:w,width:u}=L(s),{left:Y,right:X}=c.value;if(!O.value){if(Math.abs(Y)!==Math.abs(X)){if(Y<=0)return O.value=!0,_(w);if(X>=document.documentElement.clientWidth)return O.value=!0,$(w,u)}return V(w,u)}}},H=()=>{const s=we(r);if(s){const{height:w}=c.value,{top:u,height:Y}=s.getBoundingClientRect(),X=window.innerHeight-u-Y,te=u;return w<=X?ea.bottom:w>X&&w<=te?ea.top:X>=te?ea.bottom:ea.top}return ea.bottom},N=s=>H()===ea.bottom?T(s):A(s),W=()=>{const s=we(r);if(s)return v.autoPosition?N(s):T(s)},le=function(s){if(s){const w=s.scrollHeight>s.clientHeight,u=window.getComputedStyle(s).overflowY.indexOf("hidden")!==-1;return w&&!u}return!0},re=function(s){return!s||s===document.body||s.nodeType===Node.DOCUMENT_FRAGMENT_NODE?window:le(s)?s:re(s.assignedSlot?s.assignedSlot.parentNode:s.parentNode)},M=s=>{if(s)switch(v.position){case oa.left:return{left:0,transform:"translateX(0)"};case oa.right:return{left:`${s.width}px`,transform:"translateX(-100%)"};default:return{left:`${s.width/2}px`,transform:"translateX(-50%)"}}return{}};return{openOnTop:h,menuStyle:f,xCorrect:O,setMenuPosition:F,getScrollableParent:re,shadowRender:(s,w)=>{var u,Y,X;const te=document.createElement("div"),oe=(u=we(r))==null?void 0:u.getBoundingClientRect();te.setAttribute("id","dp--temp-container");const p=(Y=n.value)!=null&&Y.clientWidth?n.value:document.body;p.append(te);const E=M(oe),o=e.h(s,{...w,shadow:!0,style:{opacity:0,position:"absolute",...E}},Object.fromEntries(Object.keys(k).filter(B=>["right-sidebar","left-sidebar","top-extra","action-extra"].includes(B)).map(B=>[B,k[B]])));e.render(o,te),c.value=(X=o.el)==null?void 0:X.getBoundingClientRect(),e.render(null,te),p.removeChild(te)}}},je=[{name:"clock-icon",use:["time","calendar","shared"]},{name:"arrow-left",use:["month-year","calendar","shared","year-mode"]},{name:"arrow-right",use:["month-year","calendar","shared","year-mode"]},{name:"arrow-up",use:["time","calendar","month-year","shared"]},{name:"arrow-down",use:["time","calendar","month-year","shared"]},{name:"calendar-icon",use:["month-year","time","calendar","shared","year-mode"]},{name:"day",use:["calendar","shared"]},{name:"month-overlay-value",use:["calendar","month-year","shared"]},{name:"year-overlay-value",use:["calendar","month-year","shared","year-mode"]},{name:"year-overlay",use:["month-year","shared"]},{name:"month-overlay",use:["month-year","shared"]},{name:"month-overlay-header",use:["month-year","shared"]},{name:"year-overlay-header",use:["month-year","shared"]},{name:"hours-overlay-value",use:["calendar","time","shared"]},{name:"hours-overlay-header",use:["calendar","time","shared"]},{name:"minutes-overlay-value",use:["calendar","time","shared"]},{name:"minutes-overlay-header",use:["calendar","time","shared"]},{name:"seconds-overlay-value",use:["calendar","time","shared"]},{name:"seconds-overlay-header",use:["calendar","time","shared"]},{name:"hours",use:["calendar","time","shared"]},{name:"minutes",use:["calendar","time","shared"]},{name:"month",use:["calendar","month-year","shared"]},{name:"year",use:["calendar","month-year","shared","year-mode"]},{name:"action-buttons",use:["action"]},{name:"action-preview",use:["action"]},{name:"calendar-header",use:["calendar","shared"]},{name:"marker-tooltip",use:["calendar","shared"]},{name:"action-extra",use:["menu"]},{name:"time-picker-overlay",use:["calendar","time","shared"]},{name:"am-pm-button",use:["calendar","time","shared"]},{name:"left-sidebar",use:["menu"]},{name:"right-sidebar",use:["menu"]},{name:"month-year",use:["month-year","shared"]},{name:"time-picker",use:["menu","shared"]},{name:"action-row",use:["action"]},{name:"marker",use:["calendar","shared"]},{name:"quarter",use:["shared"]},{name:"top-extra",use:["shared","month-year"]},{name:"tp-inline-arrow-up",use:["shared","time"]},{name:"tp-inline-arrow-down",use:["shared","time"]}],mr=[{name:"trigger"},{name:"input-icon"},{name:"clear-icon"},{name:"dp-input"}],vr={all:()=>je,monthYear:()=>je.filter(a=>a.use.includes("month-year")),input:()=>mr,timePicker:()=>je.filter(a=>a.use.includes("time")),action:()=>je.filter(a=>a.use.includes("action")),calendar:()=>je.filter(a=>a.use.includes("calendar")),menu:()=>je.filter(a=>a.use.includes("menu")),shared:()=>je.filter(a=>a.use.includes("shared")),yearMode:()=>je.filter(a=>a.use.includes("year-mode"))},Ne=(a,t,r)=>{const n=[];return vr[t]().forEach(l=>{a[l.name]&&n.push(l.name)}),r!=null&&r.length&&r.forEach(l=>{l.slot&&n.push(l.slot)}),n},wa=a=>{const t=e.computed(()=>n=>a.value?n?a.value.open:a.value.close:""),r=e.computed(()=>n=>a.value?n?a.value.menuAppearTop:a.value.menuAppearBottom:"");return{transitionName:t,showTransition:!!a.value,menuTransition:r}},Ca=(a,t,r)=>{const{defaultedRange:n,defaultedTz:l}=ge(a),m=I(Pe(I(),l.value.timezone)),v=e.ref([{month:ce.getMonth(m),year:ue.getYear(m)}]),k=y=>{const C={hours:He.getHours(m),minutes:Xe.getMinutes(m),seconds:0};return n.value.enabled?[C[y],C[y]]:C[y]},c=e.reactive({hours:k("hours"),minutes:k("minutes"),seconds:k("seconds")});e.watch(n,(y,C)=>{y.enabled!==C.enabled&&(c.hours=k("hours"),c.minutes=k("minutes"),c.seconds=k("seconds"))},{deep:!0});const O=e.computed({get:()=>a.internalModelValue,set:y=>{!a.readonly&&!a.disabled&&t("update:internal-model-value",y)}}),f=e.computed(()=>y=>v.value[y]?v.value[y].month:0),h=e.computed(()=>y=>v.value[y]?v.value[y].year:0);return e.watch(O,(y,C)=>{r&&JSON.stringify(y??{})!==JSON.stringify(C??{})&&r()},{deep:!0}),{calendars:v,time:c,modelValue:O,month:f,year:h,today:m}},pr=(a,t)=>{const{defaultedMultiCalendars:r,defaultedMultiDates:n,defaultedUI:l,defaultedHighlight:m,defaultedTz:v,propDates:k,defaultedRange:c}=ge(t),{isDisabled:O}=Ge(t),f=e.ref(null),h=e.ref(Pe(new Date,v.value.timezone)),y=o=>{!o.current&&t.hideOffsetDates||(f.value=o.value)},C=()=>{f.value=null},$=o=>Array.isArray(a.value)&&c.value.enabled&&a.value[0]&&f.value?o?_e(f.value,a.value[0]):ke(f.value,a.value[0]):!0,_=(o,B)=>{const G=()=>a.value?B?a.value[0]||null:a.value[1]:null,d=a.value&&Array.isArray(a.value)?G():null;return ve(I(o.value),d)},V=o=>{const B=Array.isArray(a.value)?a.value[0]:null;return o?!ke(f.value??null,B):!0},L=(o,B=!0)=>(c.value.enabled||t.weekPicker)&&Array.isArray(a.value)&&a.value.length===2?t.hideOffsetDates&&!o.current?!1:ve(I(o.value),a.value[B?0:1]):c.value.enabled?_(o,B)&&V(B)||ve(o.value,Array.isArray(a.value)?a.value[0]:null)&&$(B):!1,J=(o,B)=>{if(Array.isArray(a.value)&&a.value[0]&&a.value.length===1){const G=ve(o.value,f.value);return B?_e(a.value[0],o.value)&&G:ke(a.value[0],o.value)&&G}return!1},D=o=>!a.value||t.hideOffsetDates&&!o.current?!1:c.value.enabled?t.modelAuto&&Array.isArray(a.value)?ve(o.value,a.value[0]?a.value[0]:h.value):!1:n.value.enabled&&Array.isArray(a.value)?a.value.some(B=>ve(B,o.value)):ve(o.value,a.value?a.value:h.value),F=o=>{if(c.value.autoRange||t.weekPicker){if(f.value){if(t.hideOffsetDates&&!o.current)return!1;const B=aa.addDays(f.value,+c.value.autoRange),G=Fe(I(f.value),t.weekStart);return t.weekPicker?ve(G[1],I(o.value)):ve(B,I(o.value))}return!1}return!1},K=o=>{if(c.value.autoRange||t.weekPicker){if(f.value){const B=aa.addDays(f.value,+c.value.autoRange);if(t.hideOffsetDates&&!o.current)return!1;const G=Fe(I(f.value),t.weekStart);return t.weekPicker?_e(o.value,G[0])&&ke(o.value,G[1]):_e(o.value,f.value)&&ke(o.value,B)}return!1}return!1},T=o=>{if(c.value.autoRange||t.weekPicker){if(f.value){if(t.hideOffsetDates&&!o.current)return!1;const B=Fe(I(f.value),t.weekStart);return t.weekPicker?ve(B[0],o.value):ve(f.value,o.value)}return!1}return!1},A=o=>Ta(a.value,f.value,o.value),Z=()=>t.modelAuto&&Array.isArray(t.internalModelValue)?!!t.internalModelValue[0]:!1,H=()=>t.modelAuto?zt(t.internalModelValue):!0,N=o=>{if(t.weekPicker)return!1;const B=c.value.enabled?!L(o)&&!L(o,!1):!0;return!O(o.value)&&!D(o)&&!(!o.current&&t.hideOffsetDates)&&B},W=o=>c.value.enabled?t.modelAuto?Z()&&D(o):!1:D(o),le=o=>m.value?$l(o.value,k.value.highlight):!1,re=o=>{const B=O(o.value);return B&&(typeof m.value=="function"?!m.value(o.value,B):!m.value.options.highlightDisabled)},M=o=>{var B;return typeof m.value=="function"?m.value(o.value):(B=m.value.weekdays)==null?void 0:B.includes(o.value.getDay())},s=o=>(c.value.enabled||t.weekPicker)&&(!(r.value.count>0)||o.current)&&H()&&!(!o.current&&t.hideOffsetDates)&&!D(o)?A(o):!1,w=o=>{const{isRangeStart:B,isRangeEnd:G}=te(o),d=c.value.enabled?B||G:!1;return{dp__cell_offset:!o.current,dp__pointer:!t.disabled&&!(!o.current&&t.hideOffsetDates)&&!O(o.value),dp__cell_disabled:O(o.value),dp__cell_highlight:!re(o)&&(le(o)||M(o))&&!W(o)&&!d&&!T(o)&&!(s(o)&&t.weekPicker)&&!G,dp__cell_highlight_active:!re(o)&&(le(o)||M(o))&&W(o),dp__today:!t.noToday&&ve(o.value,h.value)&&o.current,"dp--past":ke(o.value,h.value),"dp--future":_e(o.value,h.value)}},u=o=>({dp__active_date:W(o),dp__date_hover:N(o)}),Y=o=>{if(a.value&&!Array.isArray(a.value)){const B=Fe(a.value,t.weekStart);return{...p(o),dp__range_start:ve(B[0],o.value),dp__range_end:ve(B[1],o.value),dp__range_between_week:_e(o.value,B[0])&&ke(o.value,B[1])}}return{...p(o)}},X=o=>{if(a.value&&Array.isArray(a.value)){const B=Fe(a.value[0],t.weekStart),G=a.value[1]?Fe(a.value[1],t.weekStart):[];return{...p(o),dp__range_start:ve(B[0],o.value)||ve(G[0],o.value),dp__range_end:ve(B[1],o.value)||ve(G[1],o.value),dp__range_between_week:_e(o.value,B[0])&&ke(o.value,B[1])||_e(o.value,G[0])&&ke(o.value,G[1]),dp__range_between:_e(o.value,B[1])&&ke(o.value,G[0])}}return{...p(o)}},te=o=>{const B=r.value.count>0?o.current&&L(o)&&H():L(o)&&H(),G=r.value.count>0?o.current&&L(o,!1)&&H():L(o,!1)&&H();return{isRangeStart:B,isRangeEnd:G}},oe=o=>{const{isRangeStart:B,isRangeEnd:G}=te(o);return{dp__range_start:B,dp__range_end:G,dp__range_between:s(o),dp__date_hover:ve(o.value,f.value)&&!B&&!G&&!t.weekPicker,dp__date_hover_start:J(o,!0),dp__date_hover_end:J(o,!1)}},p=o=>({...oe(o),dp__cell_auto_range:K(o),dp__cell_auto_range_start:T(o),dp__cell_auto_range_end:F(o)}),E=o=>c.value.enabled?c.value.autoRange?p(o):t.modelAuto?{...u(o),...oe(o)}:t.weekPicker?X(o):oe(o):t.weekPicker?Y(o):u(o);return{setHoverDate:y,clearHoverDate:C,getDayClassData:o=>t.hideOffsetDates&&!o.current?{}:{...w(o),...E(o),[t.dayClass?t.dayClass(o.value,t.internalModelValue):""]:!0,[t.calendarCellClassName]:!!t.calendarCellClassName,...l.value.calendarCell??{}}}},Ge=a=>{const{defaultedFilters:t,defaultedRange:r,propDates:n,defaultedMultiDates:l}=ge(a),m=M=>n.value.disabledDates?typeof n.value.disabledDates=="function"?n.value.disabledDates(I(M)):!!$a(M,n.value.disabledDates):!1,v=M=>n.value.maxDate?a.yearPicker?ue.getYear(M)>ue.getYear(n.value.maxDate):_e(M,n.value.maxDate):!1,k=M=>n.value.minDate?a.yearPicker?ue.getYear(M)<ue.getYear(n.value.minDate):ke(M,n.value.minDate):!1,c=M=>{const s=v(M),w=k(M),u=m(M),Y=t.value.months.map(E=>+E).includes(ce.getMonth(M)),X=a.disabledWeekDays.length?a.disabledWeekDays.some(E=>+E===rl.getDay(M)):!1,te=C(M),oe=ue.getYear(M),p=oe<+a.yearRange[0]||oe>+a.yearRange[1];return!(s||w||u||Y||p||X||te)},O=(M,s)=>ke(...Ke(n.value.minDate,M,s))||ve(...Ke(n.value.minDate,M,s)),f=(M,s)=>_e(...Ke(n.value.maxDate,M,s))||ve(...Ke(n.value.maxDate,M,s)),h=(M,s,w)=>{let u=!1;return n.value.maxDate&&w&&f(M,s)&&(u=!0),n.value.minDate&&!w&&O(M,s)&&(u=!0),u},y=(M,s,w,u)=>{let Y=!1;return u?n.value.minDate&&n.value.maxDate?Y=h(M,s,w):(n.value.minDate&&O(M,s)||n.value.maxDate&&f(M,s))&&(Y=!0):Y=!0,Y},C=M=>Array.isArray(n.value.allowedDates)&&!n.value.allowedDates.length?!0:n.value.allowedDates?!$a(M,n.value.allowedDates):!1,$=M=>!c(M),_=M=>r.value.noDisabledRange?!$t.eachDayOfInterval({start:M[0],end:M[1]}).some(s=>$(s)):!0,V=M=>{if(M){const s=ue.getYear(M);return s>=+a.yearRange[0]&&s<=a.yearRange[1]}return!0},L=(M,s)=>!!(Array.isArray(M)&&M[s]&&(r.value.maxRange||r.value.minRange)&&V(M[s])),J=(M,s,w=0)=>{if(L(s,w)&&V(M)){const u=ol.differenceInCalendarDays(M,s[w]),Y=Ut(s[w],M),X=Y.length===1?0:Y.filter(oe=>$(oe)).length,te=Math.abs(u)-(r.value.minMaxRawRange?0:X);if(r.value.minRange&&r.value.maxRange)return te>=+r.value.minRange&&te<=+r.value.maxRange;if(r.value.minRange)return te>=+r.value.minRange;if(r.value.maxRange)return te<=+r.value.maxRange}return!0},D=()=>!a.enableTimePicker||a.monthPicker||a.yearPicker||a.ignoreTimeValidation,F=M=>Array.isArray(M)?[M[0]?Ja(M[0]):null,M[1]?Ja(M[1]):null]:Ja(M),K=(M,s,w)=>M.find(u=>+u.hours===He.getHours(s)&&u.minutes==="*"?!0:+u.minutes===Xe.getMinutes(s)&&+u.hours===He.getHours(s))&&w,T=(M,s,w)=>{const[u,Y]=M,[X,te]=s;return!K(u,X,w)&&!K(Y,te,w)&&w},A=(M,s)=>{const w=Array.isArray(s)?s:[s];return Array.isArray(a.disabledTimes)?Array.isArray(a.disabledTimes[0])?T(a.disabledTimes,w,M):!w.some(u=>K(a.disabledTimes,u,M)):M},Z=(M,s)=>{const w=Array.isArray(s)?[na(s[0]),s[1]?na(s[1]):void 0]:na(s),u=!a.disabledTimes(w);return M&&u},H=(M,s)=>a.disabledTimes?Array.isArray(a.disabledTimes)?A(s,M):Z(s,M):s,N=M=>{let s=!0;if(!M||D())return!0;const w=!n.value.minDate&&!n.value.maxDate?F(M):M;return(a.maxTime||n.value.maxDate)&&(s=Bt(a.maxTime,n.value.maxDate,"max",Ce(w),s)),(a.minTime||n.value.minDate)&&(s=Bt(a.minTime,n.value.minDate,"min",Ce(w),s)),H(M,s)},W=M=>{if(!a.monthPicker)return!0;let s=!0;const w=I(Re(M));if(n.value.minDate&&n.value.maxDate){const u=I(Re(n.value.minDate)),Y=I(Re(n.value.maxDate));return _e(w,u)&&ke(w,Y)||ve(w,u)||ve(w,Y)}if(n.value.minDate){const u=I(Re(n.value.minDate));s=_e(w,u)||ve(w,u)}if(n.value.maxDate){const u=I(Re(n.value.maxDate));s=ke(w,u)||ve(w,u)}return s},le=e.computed(()=>M=>!a.enableTimePicker||a.ignoreTimeValidation?!0:N(M)),re=e.computed(()=>M=>a.monthPicker?Array.isArray(M)&&(r.value.enabled||l.value.enabled)?!M.filter(s=>!W(s)).length:W(M):!0);return{isDisabled:$,validateDate:c,validateMonthYearInRange:y,isDateRangeAllowed:_,checkMinMaxRange:J,isValidTime:N,isTimeValid:le,isMonthValid:re}},Ea=()=>{const a=e.computed(()=>(n,l)=>n==null?void 0:n.includes(l)),t=e.computed(()=>(n,l)=>n.count?n.solo?!0:l===0:!0),r=e.computed(()=>(n,l)=>n.count?n.solo?!0:l===n.count-1:!0);return{hideNavigationButtons:a,showLeftIcon:t,showRightIcon:r}},fr=(a,t,r)=>{const n=e.ref(0),l=e.reactive({[la.timePicker]:!a.enableTimePicker||a.timePicker||a.monthPicker,[la.calendar]:!1,[la.header]:!1}),m=e.computed(()=>a.monthPicker||a.timePicker),v=h=>{var y;if((y=a.flow)!=null&&y.length){if(!h&&m.value)return f();l[h]=!0,Object.keys(l).filter(C=>!l[C]).length||f()}},k=()=>{var h,y;(h=a.flow)!=null&&h.length&&n.value!==-1&&(n.value+=1,t("flow-step",n.value),f()),((y=a.flow)==null?void 0:y.length)===n.value&&e.nextTick().then(()=>c())},c=()=>{n.value=-1},O=(h,y,...C)=>{var $,_;a.flow[n.value]===h&&r.value&&((_=($=r.value)[y])==null||_.call($,...C))},f=(h=0)=>{h&&(n.value+=h),O(Be.month,"toggleMonthPicker",!0),O(Be.year,"toggleYearPicker",!0),O(Be.calendar,"toggleTimePicker",!1,!0),O(Be.time,"toggleTimePicker",!0,!0);const y=a.flow[n.value];(y===Be.hours||y===Be.minutes||y===Be.seconds)&&O(y,"toggleTimePicker",!0,!0,y)};return{childMount:v,updateFlowStep:k,resetFlow:c,handleFlow:f,flowStep:n}},yr={key:1,class:"dp__input_wrap"},hr=["id","name","inputmode","placeholder","disabled","readonly","required","value","autocomplete","aria-label","aria-disabled","aria-invalid"],gr={key:2,class:"dp__clear_icon"},kr=e.defineComponent({compatConfig:{MODE:3},__name:"DatepickerInput",props:{isMenuOpen:{type:Boolean,default:!1},inputValue:{type:String,default:""},...Na},emits:["clear","open","update:input-value","set-input-date","close","select-date","set-empty-date","toggle","focus-prev","focus","blur","real-blur"],setup(a,{expose:t,emit:r}){const n=r,l=a,{defaultedTextInput:m,defaultedAriaLabels:v,defaultedInline:k,defaultedConfig:c,defaultedRange:O,defaultedMultiDates:f,defaultedUI:h,getDefaultPattern:y,getDefaultStartTime:C}=ge(l),{checkMinMaxRange:$}=Ge(l),_=e.ref(),V=e.ref(null),L=e.ref(!1),J=e.ref(!1),D=e.computed(()=>({dp__pointer:!l.disabled&&!l.readonly&&!m.value.enabled,dp__disabled:l.disabled,dp__input_readonly:!m.value.enabled,dp__input:!0,dp__input_icon_pad:!l.hideInputIcon,dp__input_valid:!!l.state,dp__input_invalid:l.state===!1,dp__input_focus:L.value||l.isMenuOpen,dp__input_reg:!m.value.enabled,[l.inputClassName]:!!l.inputClassName,...h.value.input??{}})),F=()=>{n("set-input-date",null),l.clearable&&l.autoApply&&(n("set-empty-date"),_.value=null)},K=u=>{const Y=C();return Tl(u,m.value.format??y(),Y??jt({},l.enableSeconds),l.inputValue,J.value,l.formatLocale)},T=u=>{const{rangeSeparator:Y}=m.value,[X,te]=u.split(`${Y}`);if(X){const oe=K(X.trim()),p=te?K(te.trim()):null;if(ia.isAfter(oe,p))return;const E=oe&&p?[oe,p]:[oe];$(p,E,0)&&(_.value=oe?E:null)}},A=()=>{J.value=!0},Z=u=>{if(O.value.enabled)T(u);else if(f.value.enabled){const Y=u.split(";");_.value=Y.map(X=>K(X.trim())).filter(X=>X)}else _.value=K(u)},H=u=>{var Y;const X=typeof u=="string"?u:(Y=u.target)==null?void 0:Y.value;X!==""?(m.value.openMenu&&!l.isMenuOpen&&n("open"),Z(X),n("set-input-date",_.value)):F(),J.value=!1,n("update:input-value",X)},N=u=>{m.value.enabled?(Z(u.target.value),m.value.enterSubmit&<(_.value)&&l.inputValue!==""?(n("set-input-date",_.value,!0),_.value=null):m.value.enterSubmit&&l.inputValue===""&&(_.value=null,n("clear"))):re(u)},W=u=>{m.value.enabled&&m.value.tabSubmit&&Z(u.target.value),m.value.tabSubmit&<(_.value)&&l.inputValue!==""?(n("set-input-date",_.value,!0,!0),_.value=null):m.value.tabSubmit&&l.inputValue===""&&(_.value=null,n("clear",!0))},le=()=>{L.value=!0,n("focus"),e.nextTick().then(()=>{var u;m.value.enabled&&m.value.selectOnFocus&&((u=V.value)==null||u.select())})},re=u=>{u.preventDefault(),Je(u,c.value,!0),m.value.enabled&&m.value.openMenu&&!k.value.input&&!l.isMenuOpen?n("open"):m.value.enabled||n("toggle")},M=()=>{n("real-blur"),L.value=!1,(!l.isMenuOpen||k.value.enabled&&k.value.input)&&n("blur"),l.autoApply&&m.value.enabled&&_.value&&!l.isMenuOpen&&(n("set-input-date",_.value),n("select-date"),_.value=null)},s=u=>{Je(u,c.value,!0),n("clear")},w=u=>{if(u.key==="Tab"&&W(u),u.key==="Enter"&&N(u),!m.value.enabled){if(u.code==="Tab")return;u.preventDefault()}};return t({focusInput:()=>{var u;(u=V.value)==null||u.focus({preventScroll:!0})},setParsedDate:u=>{_.value=u}}),(u,Y)=>{var X;return e.openBlock(),e.createElementBlock("div",{onClick:re},[u.$slots.trigger&&!u.$slots["dp-input"]&&!e.unref(k).enabled?e.renderSlot(u.$slots,"trigger",{key:0}):e.createCommentVNode("",!0),!u.$slots.trigger&&(!e.unref(k).enabled||e.unref(k).input)?(e.openBlock(),e.createElementBlock("div",yr,[u.$slots["dp-input"]&&!u.$slots.trigger&&(!e.unref(k).enabled||e.unref(k).enabled&&e.unref(k).input)?e.renderSlot(u.$slots,"dp-input",{key:0,value:a.inputValue,isMenuOpen:a.isMenuOpen,onInput:H,onEnter:N,onTab:W,onClear:s,onBlur:M,onKeypress:w,onPaste:A,onFocus:le,openMenu:()=>u.$emit("open"),closeMenu:()=>u.$emit("close"),toggleMenu:()=>u.$emit("toggle")}):e.createCommentVNode("",!0),u.$slots["dp-input"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("input",{key:1,id:u.uid?`dp-input-${u.uid}`:void 0,ref_key:"inputRef",ref:V,"data-test":"dp-input",name:u.name,class:e.normalizeClass(D.value),inputmode:e.unref(m).enabled?"text":"none",placeholder:u.placeholder,disabled:u.disabled,readonly:u.readonly,required:u.required,value:a.inputValue,autocomplete:u.autocomplete,"aria-label":(X=e.unref(v))==null?void 0:X.input,"aria-disabled":u.disabled||void 0,"aria-invalid":u.state===!1?!0:void 0,onInput:H,onBlur:M,onFocus:le,onKeypress:w,onKeydown:w,onPaste:A},null,42,hr)),e.createElementVNode("div",{onClick:Y[2]||(Y[2]=te=>n("toggle"))},[u.$slots["input-icon"]&&!u.hideInputIcon?(e.openBlock(),e.createElementBlock("span",{key:0,class:"dp__input_icon",onClick:Y[0]||(Y[0]=te=>n("toggle"))},[e.renderSlot(u.$slots,"input-icon")])):e.createCommentVNode("",!0),!u.$slots["input-icon"]&&!u.hideInputIcon&&!u.$slots["dp-input"]?(e.openBlock(),e.createBlock(e.unref(ma),{key:1,class:"dp__input_icon dp__input_icons",onClick:Y[1]||(Y[1]=te=>n("toggle"))})):e.createCommentVNode("",!0)]),u.$slots["clear-icon"]&&a.inputValue&&u.clearable&&!u.disabled&&!u.readonly?(e.openBlock(),e.createElementBlock("span",gr,[e.renderSlot(u.$slots,"clear-icon",{clear:s})])):e.createCommentVNode("",!0),u.clearable&&!u.$slots["clear-icon"]&&a.inputValue&&!u.disabled&&!u.readonly?(e.openBlock(),e.createBlock(e.unref(Yt),{key:3,class:"dp__clear_icon dp__input_icons","data-test":"clear-icon",onClick:Y[3]||(Y[3]=e.withModifiers(te=>s(te),["prevent"]))})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])}}}),br=typeof window<"u"?window:void 0,et=()=>{},_r=a=>e.getCurrentScope()?(e.onScopeDispose(a),!0):!1,wr=(a,t,r,n)=>{if(!a)return et;let l=et;const m=e.watch(()=>e.unref(a),k=>{l(),k&&(k.addEventListener(t,r,n),l=()=>{k.removeEventListener(t,r,n),l=et})},{immediate:!0,flush:"post"}),v=()=>{m(),l()};return _r(v),v},Cr=(a,t,r,n={})=>{const{window:l=br,event:m="pointerdown"}=n;return l?wr(l,m,v=>{const k=we(a),c=we(t);!k||!c||k===v.target||v.composedPath().includes(k)||v.composedPath().includes(c)||r(v)},{passive:!0}):void 0},Sr=e.defineComponent({compatConfig:{MODE:3},__name:"VueDatePicker",props:{...Na},emits:["update:model-value","update:model-timezone-value","text-submit","closed","cleared","open","focus","blur","internal-model-change","recalculate-position","flow-step","update-month-year","invalid-select","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end","date-update","invalid-date","overlay-toggle"],setup(a,{expose:t,emit:r}){const n=r,l=a,m=e.useSlots(),v=e.ref(!1),k=e.toRef(l,"modelValue"),c=e.toRef(l,"timezone"),O=e.ref(null),f=e.ref(null),h=e.ref(null),y=e.ref(!1),C=e.ref(null),$=e.ref(!1),_=e.ref(!1),V=e.ref(!1),L=e.ref(!1),{setMenuFocused:J,setShiftKey:D}=Wt(),{clearArrowNav:F}=We(),{validateDate:K,isValidTime:T}=Ge(l),{defaultedTransitions:A,defaultedTextInput:Z,defaultedInline:H,defaultedConfig:N,defaultedRange:W,defaultedMultiDates:le}=ge(l),{menuTransition:re,showTransition:M}=wa(A);e.onMounted(()=>{B(l.modelValue),e.nextTick().then(()=>{if(!H.value.enabled){const S=oe(C.value);S==null||S.addEventListener("scroll",z),window==null||window.addEventListener("resize",R)}}),H.value.enabled&&(v.value=!0),window==null||window.addEventListener("keyup",me),window==null||window.addEventListener("keydown",b)}),e.onUnmounted(()=>{if(!H.value.enabled){const S=oe(C.value);S==null||S.removeEventListener("scroll",z),window==null||window.removeEventListener("resize",R)}window==null||window.removeEventListener("keyup",me),window==null||window.removeEventListener("keydown",b)});const s=Ne(m,"all",l.presetDates),w=Ne(m,"input");e.watch([k,c],()=>{B(k.value)},{deep:!0});const{openOnTop:u,menuStyle:Y,xCorrect:X,setMenuPosition:te,getScrollableParent:oe,shadowRender:p}=cr({menuRef:O,menuRefInner:f,inputRef:h,pickerWrapperRef:C,inline:H,emit:n,props:l,slots:m}),{inputValue:E,internalModelValue:o,parseExternalModelValue:B,emitModelValue:G,formatInputValue:d,checkBeforeEmit:ee}=an(n,l,y),se=e.computed(()=>({dp__main:!0,dp__theme_dark:l.dark,dp__theme_light:!l.dark,dp__flex_display:H.value.enabled,"dp--flex-display-collapsed":V.value,dp__flex_display_with_input:H.value.input})),x=e.computed(()=>l.dark?"dp__theme_dark":"dp__theme_light"),ie=e.computed(()=>l.teleport?{to:typeof l.teleport=="boolean"?"body":l.teleport,disabled:!l.teleport||H.value.enabled}:{}),i=e.computed(()=>({class:"dp__outer_menu_wrap"})),P=e.computed(()=>H.value.enabled&&(l.timePicker||l.monthPicker||l.yearPicker||l.quarterPicker)),q=()=>{var S,j;return(j=(S=h.value)==null?void 0:S.$el)==null?void 0:j.getBoundingClientRect()},z=()=>{v.value&&(N.value.closeOnScroll?Te():te())},R=()=>{var S;v.value&&te();const j=(S=f.value)==null?void 0:S.$el.getBoundingClientRect().width;V.value=document.body.offsetWidth<=j},me=S=>{S.key==="Tab"&&!H.value.enabled&&!l.teleport&&N.value.tabOutClosesMenu&&(C.value.contains(document.activeElement)||Te()),_.value=S.shiftKey},b=S=>{_.value=S.shiftKey},Q=()=>{!l.disabled&&!l.readonly&&(p(xt,l),te(!1),v.value=!0,v.value&&n("open"),v.value||va(),B(l.modelValue))},de=()=>{var S;E.value="",va(),(S=h.value)==null||S.setParsedDate(null),n("update:model-value",null),n("update:model-timezone-value",null),n("cleared"),N.value.closeOnClearValue&&Te()},pe=()=>{const S=o.value;return!S||!Array.isArray(S)&&K(S)?!0:Array.isArray(S)?le.value.enabled||S.length===2&&K(S[0])&&K(S[1])?!0:W.value.partialRange&&!l.timePicker?K(S[0]):!1:!1},xe=()=>{ee()&&pe()?(G(),Te()):n("invalid-select",o.value)},ne=S=>{qe(),G(),N.value.closeOnAutoApply&&!S&&Te()},qe=()=>{h.value&&Z.value.enabled&&h.value.setParsedDate(o.value)},Ye=(S=!1)=>{l.autoApply&&T(o.value)&&pe()&&(W.value.enabled&&Array.isArray(o.value)?(W.value.partialRange||o.value.length===2)&&ne(S):ne(S))},va=()=>{Z.value.enabled||(o.value=null)},Te=()=>{H.value.enabled||(v.value&&(v.value=!1,X.value=!1,J(!1),D(!1),F(),n("closed"),E.value&&B(k.value)),va(),n("blur"))},pa=(S,j,ae=!1)=>{if(!S){o.value=null;return}const De=Array.isArray(S)?!S.some(Ze=>!K(Ze)):K(S),Ve=T(S);De&&Ve&&(L.value=!0,o.value=S,j&&($.value=ae,xe(),n("text-submit")),e.nextTick().then(()=>{L.value=!1}))},Ra=()=>{l.autoApply&&T(o.value)&&G(),qe()},Sa=()=>v.value?Te():Q(),Oa=S=>{o.value=S},Ya=()=>{Z.value.enabled&&(y.value=!0,d()),n("focus")},Ia=()=>{if(Z.value.enabled&&(y.value=!1,B(l.modelValue),$.value)){const S=Al(C.value,_.value);S==null||S.focus()}n("blur")},za=S=>{f.value&&f.value.updateMonthYear(0,{month:wt(S.month),year:wt(S.year)})},Fa=S=>{B(S??l.modelValue)},La=(S,j)=>{var ae;(ae=f.value)==null||ae.switchView(S,j)},g=S=>N.value.onClickOutside?N.value.onClickOutside(S):Te(),U=(S=0)=>{var j;(j=f.value)==null||j.handleFlow(S)};return Cr(O,h,()=>g(pe)),t({closeMenu:Te,selectDate:xe,clearValue:de,openMenu:Q,onScroll:z,formatInputValue:d,updateInternalModelValue:Oa,setMonthYear:za,parseModel:Fa,switchView:La,toggleMenu:Sa,handleFlow:U}),(S,j)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"pickerWrapperRef",ref:C,class:e.normalizeClass(se.value),"data-datepicker-instance":""},[e.createVNode(kr,e.mergeProps({ref_key:"inputRef",ref:h,"input-value":e.unref(E),"onUpdate:inputValue":j[0]||(j[0]=ae=>e.isRef(E)?E.value=ae:null),"is-menu-open":v.value},S.$props,{onClear:de,onOpen:Q,onSetInputDate:pa,onSetEmptyDate:e.unref(G),onSelectDate:xe,onToggle:Sa,onClose:Te,onFocus:Ya,onBlur:Ia,onRealBlur:j[1]||(j[1]=ae=>y.value=!1)}),e.createSlots({_:2},[e.renderList(e.unref(w),(ae,De)=>({name:ae,fn:e.withCtx(Ve=>[e.renderSlot(S.$slots,ae,e.normalizeProps(e.guardReactiveProps(Ve)))])}))]),1040,["input-value","is-menu-open","onSetEmptyDate"]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(S.teleport?e.Teleport:"div"),e.normalizeProps(e.guardReactiveProps(ie.value)),{default:e.withCtx(()=>[e.createVNode(e.Transition,{name:e.unref(re)(e.unref(u)),css:e.unref(M)&&!e.unref(H).enabled},{default:e.withCtx(()=>[v.value?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:0,ref_key:"dpWrapMenuRef",ref:O},i.value,{class:{"dp--menu-wrapper":!e.unref(H).enabled},style:e.unref(H).enabled?void 0:e.unref(Y)}),[e.createVNode(xt,e.mergeProps({ref_key:"dpMenuRef",ref:f},S.$props,{"internal-model-value":e.unref(o),"onUpdate:internalModelValue":j[2]||(j[2]=ae=>e.isRef(o)?o.value=ae:null),class:{[x.value]:!0,"dp--menu-wrapper":S.teleport},"open-on-top":e.unref(u),"no-overlay-focus":P.value,collapse:V.value,"get-input-rect":q,"is-text-input-date":L.value,onClosePicker:Te,onSelectDate:xe,onAutoApply:Ye,onTimeUpdate:Ra,onFlowStep:j[3]||(j[3]=ae=>S.$emit("flow-step",ae)),onUpdateMonthYear:j[4]||(j[4]=ae=>S.$emit("update-month-year",ae)),onInvalidSelect:j[5]||(j[5]=ae=>S.$emit("invalid-select",e.unref(o))),onAutoApplyInvalid:j[6]||(j[6]=ae=>S.$emit("invalid-select",ae)),onInvalidFixedRange:j[7]||(j[7]=ae=>S.$emit("invalid-fixed-range",ae)),onRecalculatePosition:e.unref(te),onTooltipOpen:j[8]||(j[8]=ae=>S.$emit("tooltip-open",ae)),onTooltipClose:j[9]||(j[9]=ae=>S.$emit("tooltip-close",ae)),onTimePickerOpen:j[10]||(j[10]=ae=>S.$emit("time-picker-open",ae)),onTimePickerClose:j[11]||(j[11]=ae=>S.$emit("time-picker-close",ae)),onAmPmChange:j[12]||(j[12]=ae=>S.$emit("am-pm-change",ae)),onRangeStart:j[13]||(j[13]=ae=>S.$emit("range-start",ae)),onRangeEnd:j[14]||(j[14]=ae=>S.$emit("range-end",ae)),onDateUpdate:j[15]||(j[15]=ae=>S.$emit("date-update",ae)),onInvalidDate:j[16]||(j[16]=ae=>S.$emit("invalid-date",ae)),onOverlayToggle:j[17]||(j[17]=ae=>S.$emit("overlay-toggle",ae))}),e.createSlots({_:2},[e.renderList(e.unref(s),(ae,De)=>({name:ae,fn:e.withCtx(Ve=>[e.renderSlot(S.$slots,ae,e.normalizeProps(e.guardReactiveProps({...Ve})))])}))]),1040,["internal-model-value","class","open-on-top","no-overlay-focus","collapse","is-text-input-date","onRecalculatePosition"])],16)):e.createCommentVNode("",!0)]),_:3},8,["name","css"])]),_:3},16))],2))}}),ht=(()=>{const a=Sr;return a.install=t=>{t.component("Vue3DatePicker",a)},a})(),Br=Object.freeze(Object.defineProperty({__proto__:null,default:ht},Symbol.toStringTag,{value:"Module"}));Object.entries(Br).forEach(([a,t])=>{a!=="default"&&(ht[a]=t)});exports.default=ht;
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),se=require("../../../date-fns/getYear.cjs"),me=require("../../../date-fns/getMonth.cjs"),ul=require("../../../date-fns/getDay.cjs"),Na=require("../../../date-fns/eachDayOfInterval.cjs"),il=require("../../../date-fns/differenceInCalendarDays.cjs"),Fe=require("../../../date-fns/format.cjs"),pe=require("../../../date-fns/set.cjs"),sl=require("../../../date-fns/startOfMonth.cjs"),gt=require("../../../date-fns/isBefore.cjs"),ut=require("../../../date-fns/isEqual.cjs"),it=require("../../../date-fns/isAfter.cjs"),At=require("../../../date-fns/isValid.cjs"),dl=require("../../../date-fns/addHours.cjs"),He=require("../../../date-fns/getHours.cjs"),We=require("../../../date-fns/getMinutes.cjs"),st=require("../../../date-fns/getSeconds.cjs"),ze=require("../../../date-fns/setYear.cjs"),Dt=require("../../../date-fns/startOfYear.cjs"),$a=require("../../../date-fns/add.cjs"),at=require("../../../date-fns/addMonths.cjs"),ra=require("../../../date-fns/startOfWeek.cjs"),Va=require("../../../date-fns/endOfWeek.cjs"),ka=require("../../../date-fns/isSameQuarter.cjs"),cl=require("../../../date-fns/eachQuarterOfInterval.cjs"),Ra=require("../../../date-fns/endOfYear.cjs"),ml=require("../../../date-fns/startOfQuarter.cjs"),ba=require("../../../date-fns/endOfQuarter.cjs"),ta=require("../../../date-fns/parse.cjs"),kt=require("../../../date-fns/subMonths.cjs"),wa=require("../../../date-fns/getQuarter.cjs"),vl=require("../../../date-fns/setHours.cjs"),pl=require("../../../date-fns/setMinutes.cjs"),Oa=require("../../../date-fns/setSeconds.cjs"),Ya=require("../../../date-fns/setMilliseconds.cjs"),fl=require("../../../date-fns/setMonth.cjs"),yl=require("../../../date-fns/getWeek.cjs"),hl=require("../../../date-fns/getISOWeek.cjs"),tt=require("../../../date-fns/addDays.cjs"),gl=require("../../../date-fns/isDate.cjs"),Ea=require("../../../date-fns/addYears.cjs"),za=require("../../../date-fns/subYears.cjs"),kl=require("../../../date-fns/sub.cjs"),bl=require("../../../date-fns/differenceInYears.cjs");function mt(){const t=e.useAttrs();return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img",...t},[e.createElementVNode("path",{d:"M29.333 8c0-2.208-1.792-4-4-4h-18.667c-2.208 0-4 1.792-4 4v18.667c0 2.208 1.792 4 4 4h18.667c2.208 0 4-1.792 4-4v-18.667zM26.667 8v18.667c0 0.736-0.597 1.333-1.333 1.333 0 0-18.667 0-18.667 0-0.736 0-1.333-0.597-1.333-1.333 0 0 0-18.667 0-18.667 0-0.736 0.597-1.333 1.333-1.333 0 0 18.667 0 18.667 0 0.736 0 1.333 0.597 1.333 1.333z"}),e.createElementVNode("path",{d:"M20 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),e.createElementVNode("path",{d:"M9.333 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),e.createElementVNode("path",{d:"M4 14.667h24c0.736 0 1.333-0.597 1.333-1.333s-0.597-1.333-1.333-1.333h-24c-0.736 0-1.333 0.597-1.333 1.333s0.597 1.333 1.333 1.333z"})])}mt.compatConfig={MODE:3};function Fa(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M23.057 7.057l-16 16c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l16-16c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0z"}),e.createElementVNode("path",{d:"M7.057 8.943l16 16c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885l-16-16c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}Fa.compatConfig={MODE:3};function oa(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M20.943 23.057l-7.057-7.057c0 0 7.057-7.057 7.057-7.057 0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-8 8c-0.521 0.521-0.521 1.365 0 1.885l8 8c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}oa.compatConfig={MODE:3};function ua(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M12.943 24.943l8-8c0.521-0.521 0.521-1.365 0-1.885l-8-8c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885l7.057 7.057c0 0-7.057 7.057-7.057 7.057-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0z"})])}ua.compatConfig={MODE:3};function ia(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M16 1.333c-8.095 0-14.667 6.572-14.667 14.667s6.572 14.667 14.667 14.667c8.095 0 14.667-6.572 14.667-14.667s-6.572-14.667-14.667-14.667zM16 4c6.623 0 12 5.377 12 12s-5.377 12-12 12c-6.623 0-12-5.377-12-12s5.377-12 12-12z"}),e.createElementVNode("path",{d:"M14.667 8v8c0 0.505 0.285 0.967 0.737 1.193l5.333 2.667c0.658 0.329 1.46 0.062 1.789-0.596s0.062-1.46-0.596-1.789l-4.596-2.298c0 0 0-7.176 0-7.176 0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"})])}ia.compatConfig={MODE:3};function sa(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M24.943 19.057l-8-8c-0.521-0.521-1.365-0.521-1.885 0l-8 8c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l7.057-7.057c0 0 7.057 7.057 7.057 7.057 0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}sa.compatConfig={MODE:3};function da(){return e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon",role:"img"},[e.createElementVNode("path",{d:"M7.057 12.943l8 8c0.521 0.521 1.365 0.521 1.885 0l8-8c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-7.057 7.057c0 0-7.057-7.057-7.057-7.057-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}da.compatConfig={MODE:3};const Te=(t,a)=>a?new Date(t.toLocaleString("en-US",{timeZone:a})):new Date(t),ca=(t,a,o)=>aa(t,a,o)||L(),wl=(t,a,o)=>{const l=a.dateInTz?Te(new Date(t),a.dateInTz):L(t);return o?De(l,!0):l},aa=(t,a,o)=>{if(!t)return null;const l=o?De(L(t),!0):L(t);return a?a.exactMatch?wl(t,a,o):Te(l,a.timezone):l},_l=t=>{if(!t)return 0;const a=new Date,o=new Date(a.toLocaleString("en-US",{timeZone:"UTC"})),l=new Date(a.toLocaleString("en-US",{timeZone:t})),n=l.getTimezoneOffset()/60;return(+o-+l)/(1e3*60*60)-n};var Re=(t=>(t.month="month",t.year="year",t))(Re||{}),et=(t=>(t.top="top",t.bottom="bottom",t))(et||{}),lt=(t=>(t.header="header",t.calendar="calendar",t.timePicker="timePicker",t))(lt||{}),xe=(t=>(t.month="month",t.year="year",t.calendar="calendar",t.time="time",t.minutes="minutes",t.hours="hours",t.seconds="seconds",t))(xe||{});const Sl=["timestamp","date","iso"];var Me=(t=>(t.up="up",t.down="down",t.left="left",t.right="right",t))(Me||{}),ye=(t=>(t.arrowUp="ArrowUp",t.arrowDown="ArrowDown",t.arrowLeft="ArrowLeft",t.arrowRight="ArrowRight",t.enter="Enter",t.space=" ",t.esc="Escape",t.tab="Tab",t.home="Home",t.end="End",t.pageUp="PageUp",t.pageDown="PageDown",t))(ye||{});function _a(t){return a=>new Intl.DateTimeFormat(t,{weekday:"short",timeZone:"UTC"}).format(new Date(`2017-01-0${a}T00:00:00+00:00`)).slice(0,2)}function Cl(t){return a=>Fe.formatDate(Te(new Date(`2017-01-0${a}T00:00:00+00:00`),"UTC"),"EEEEEE",{locale:t})}const xl=(t,a,o)=>{const l=[1,2,3,4,5,6,7];let n;if(t!==null)try{n=l.map(Cl(t))}catch{n=l.map(_a(a))}else n=l.map(_a(a));const s=n.slice(0,o),d=n.slice(o+1,n.length);return[n[o]].concat(...d).concat(...s)},ma=(t,a,o)=>{const l=[];for(let n=+t[0];n<=+t[1];n++)l.push({value:+n,text:qa(n,a)});return o?l.reverse():l},Ia=(t,a,o)=>{const l=[1,2,3,4,5,6,7,8,9,10,11,12].map(s=>{const d=s<10?`0${s}`:s;return new Date(`2017-${d}-01T00:00:00+00:00`)});if(t!==null)try{const s=o==="long"?"LLLL":"LLL";return l.map((d,b)=>{const m=Fe.formatDate(Te(d,"UTC"),s,{locale:t});return{text:m.charAt(0).toUpperCase()+m.substring(1),value:b}})}catch{}const n=new Intl.DateTimeFormat(a,{month:o,timeZone:"UTC"});return l.map((s,d)=>{const b=n.format(s);return{text:b.charAt(0).toUpperCase()+b.substring(1),value:d}})},Bl=t=>[12,1,2,3,4,5,6,7,8,9,10,11,12,1,2,3,4,5,6,7,8,9,10,11][t],_e=t=>{const a=e.unref(t);return a!=null&&a.$el?a==null?void 0:a.$el:a},Ml=t=>({type:"dot",...t??{}}),La=t=>Array.isArray(t)?!!t[0]&&!!t[1]:!1,va={prop:t=>`"${t}" prop must be enabled!`,dateArr:t=>`You need to use array as "model-value" binding in order to support "${t}"`},Se=t=>t,Sa=t=>t===0?t:!t||isNaN(+t)?null:+t,Ca=t=>t===null,Ha=t=>{if(t)return[...t.querySelectorAll("input, button, select, textarea, a[href]")][0]},Al=t=>{const a=[],o=l=>l.filter(n=>n);for(let l=0;l<t.length;l+=3){const n=[t[l],t[l+1],t[l+2]];a.push(o(n))}return a},bt=(t,a,o)=>{const l=o!=null,n=a!=null;if(!l&&!n)return!1;const s=+o,d=+a;return l&&n?+t>s||+t<d:l?+t>s:n?+t<d:!1},dt=(t,a)=>Al(t).map(o=>o.map(l=>{const{active:n,disabled:s,isBetween:d,highlighted:b}=a(l);return{...l,active:n,disabled:s,className:{dp__overlay_cell_active:n,dp__overlay_cell:!n,dp__overlay_cell_disabled:s,dp__overlay_cell_pad:!0,dp__overlay_cell_active_disabled:s&&n,dp__cell_in_between:d,"dp--highlighted":b}}})),Ke=(t,a,o=!1)=>{t&&a.allowStopPropagation&&(o&&t.stopImmediatePropagation(),t.stopPropagation())},Dl=()=>["a[href]","area[href]","input:not([disabled]):not([type='hidden'])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","[tabindex]:not([tabindex='-1'])","[data-datepicker-instance]"].join(", ");function Tl(t,a){let o=[...document.querySelectorAll(Dl())];o=o.filter(n=>!t.contains(n)||n.hasAttribute("data-datepicker-instance"));const l=o.indexOf(t);if(l>=0&&(a?l-1>=0:l+1<=o.length))return o[l+(a?-1:1)]}const la=(t,a)=>t==null?void 0:t.querySelector(`[data-dp-element="${a}"]`),qa=(t,a)=>new Intl.NumberFormat(a,{useGrouping:!1,style:"decimal"}).format(t),pa=t=>Fe.formatDate(t,"dd-MM-yyyy"),qt=t=>Array.isArray(t),Tt=(t,a)=>a.get(pa(t)),Pl=(t,a)=>t?a?a instanceof Map?!!Tt(t,a):a(L(t)):!1:!0,Ae=(t,a,o=!1,l)=>{if(t.key===ye.enter||t.key===ye.space)return o&&t.preventDefault(),a();if(l)return l(t)},xa=()=>["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].some(t=>navigator.userAgent.includes(t))||navigator.userAgent.includes("Mac")&&"ontouchend"in document,Ba=(t,a,o,l,n,s)=>{const d=ta.parse(t,a.slice(0,t.length),new Date,{locale:s});return At.isValid(d)&&gl.isDate(d)?l||n?d:pe.set(d,{hours:+o.hours,minutes:+(o==null?void 0:o.minutes),seconds:+(o==null?void 0:o.seconds),milliseconds:0}):null},Nl=(t,a,o,l,n,s)=>{const d=Array.isArray(o)?o[0]:o;if(typeof a=="string")return Ba(t,a,d,l,n,s);if(Array.isArray(a)){let b=null;for(const m of a)if(b=Ba(t,m,d,l,n,s),b)break;return b}return typeof a=="function"?a(t):null},L=t=>t?new Date(t):new Date,$l=(t,a,o)=>{if(a){const n=(t.getMonth()+1).toString().padStart(2,"0"),s=t.getDate().toString().padStart(2,"0"),d=t.getHours().toString().padStart(2,"0"),b=t.getMinutes().toString().padStart(2,"0"),m=o?t.getSeconds().toString().padStart(2,"0"):"00";return`${t.getFullYear()}-${n}-${s}T${d}:${b}:${m}.000Z`}const l=Date.UTC(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate(),t.getUTCHours(),t.getUTCMinutes(),t.getUTCSeconds());return new Date(l).toISOString()},De=(t,a)=>{const o=L(JSON.parse(JSON.stringify(t))),l=pe.set(o,{hours:0,minutes:0,seconds:0,milliseconds:0});return a?sl.startOfMonth(l):l},Ge=(t,a,o,l)=>{let n=t?L(t):L();return(a||a===0)&&(n=vl.setHours(n,+a)),(o||o===0)&&(n=pl.setMinutes(n,+o)),(l||l===0)&&(n=Oa.setSeconds(n,+l)),Ya.setMilliseconds(n,0)},ge=(t,a)=>!t||!a?!1:gt.isBefore(De(t),De(a)),ve=(t,a)=>!t||!a?!1:ut.isEqual(De(t),De(a)),be=(t,a)=>!t||!a?!1:it.isAfter(De(t),De(a)),Pt=(t,a,o)=>t!=null&&t[0]&&t!=null&&t[1]?be(o,t[0])&&ge(o,t[1]):t!=null&&t[0]&&a?be(o,t[0])&&ge(o,a)||ge(o,t[0])&&be(o,a):!1,Oe=t=>{const a=pe.set(new Date(t),{date:1});return De(a)},Ut=(t,a,o)=>a&&(o||o===0)?Object.fromEntries(["hours","minutes","seconds"].map(l=>l===a?[l,o]:[l,isNaN(+t[l])?void 0:+t[l]])):{hours:isNaN(+t.hours)?void 0:+t.hours,minutes:isNaN(+t.minutes)?void 0:+t.minutes,seconds:isNaN(+t.seconds)?void 0:+t.seconds},nt=t=>({hours:He.getHours(t),minutes:We.getMinutes(t),seconds:st.getSeconds(t)}),Ua=(t,a)=>{if(a){const o=se.getYear(L(a));if(o>t)return 12;if(o===t)return me.getMonth(L(a))}},ja=(t,a)=>{if(a){const o=se.getYear(L(a));return o<t?-1:o===t?me.getMonth(L(a)):void 0}},ct=t=>{if(t)return se.getYear(L(t))},Qa=(t,a)=>{const o=be(t,a)?a:t,l=be(a,t)?a:t;return Na.eachDayOfInterval({start:o,end:l})},Vl=t=>{const a=at.addMonths(t,1);return{month:me.getMonth(a),year:se.getYear(a)}},Ie=(t,a)=>{const o=ra.startOfWeek(t,{weekStartsOn:+a}),l=Va.endOfWeek(t,{weekStartsOn:+a});return[o,l]},Ka=(t,a)=>{const o={hours:He.getHours(L()),minutes:We.getMinutes(L()),seconds:a?st.getSeconds(L()):0};return Object.assign(o,t)},Qe=(t,a,o)=>[pe.set(L(t),{date:1}),pe.set(L(),{month:a,year:o,date:1})],Le=(t,a,o)=>{let l=t?L(t):L();return(a||a===0)&&(l=fl.setMonth(l,a)),o&&(l=ze.setYear(l,o)),l},Ga=(t,a,o,l,n)=>{if(!l||n&&!a||!n&&!o)return!1;const s=n?at.addMonths(t,1):kt.subMonths(t,1),d=[me.getMonth(s),se.getYear(s)];return n?!Ol(...d,a):!Rl(...d,o)},Rl=(t,a,o)=>ge(...Qe(o,t,a))||ve(...Qe(o,t,a)),Ol=(t,a,o)=>be(...Qe(o,t,a))||ve(...Qe(o,t,a)),Wa=(t,a,o,l,n,s,d)=>{if(typeof a=="function"&&!d)return a(t);const b=o?{locale:o}:void 0;return Array.isArray(t)?`${Fe.formatDate(t[0],s,b)}${n&&!t[1]?"":l}${t[1]?Fe.formatDate(t[1],s,b):""}`:Fe.formatDate(t,s,b)},rt=t=>{if(t)return null;throw new Error(va.prop("partial-range"))},Bt=(t,a)=>{if(a)return t();throw new Error(va.prop("range"))},na=t=>Array.isArray(t)?At.isValid(t[0])&&(t[1]?At.isValid(t[1]):!0):t?At.isValid(t):!1,Yl=(t,a)=>pe.set(a??L(),{hours:+t.hours||0,minutes:+t.minutes||0,seconds:+t.seconds||0}),jt=(t,a,o,l)=>{if(!t)return!0;if(l){const n=o==="max"?gt.isBefore(t,a):it.isAfter(t,a),s={seconds:0,milliseconds:0};return n||ut.isEqual(pe.set(t,s),pe.set(a,s))}return o==="max"?t.getTime()<=a.getTime():t.getTime()>=a.getTime()},Qt=(t,a,o)=>t?Yl(t,a):L(o??a),Ma=(t,a,o,l,n)=>{if(Array.isArray(l)){const d=Qt(t,l[0],a),b=Qt(t,l[1],a);return jt(l[0],d,o,!!a)&&jt(l[1],b,o,!!a)&&n}const s=Qt(t,l,a);return jt(l,s,o,!!a)&&n},Kt=t=>pe.set(L(),nt(t)),El=(t,a)=>t instanceof Map?Array.from(t.values()).filter(o=>se.getYear(L(o))===a).map(o=>me.getMonth(o)):[],Za=(t,a,o)=>typeof t=="function"?t({month:a,year:o}):!!t.months.find(l=>l.month===a&&l.year===o),fa=(t,a)=>typeof t=="function"?t(a):t.years.includes(a),Xa=t=>Fe.formatDate(t,"yyyy-MM-dd"),yt=e.reactive({menuFocused:!1,shiftKeyInMenu:!1}),Ja=()=>{const t=o=>{yt.menuFocused=o},a=o=>{yt.shiftKeyInMenu!==o&&(yt.shiftKeyInMenu=o)};return{control:e.computed(()=>({shiftKeyInMenu:yt.shiftKeyInMenu,menuFocused:yt.menuFocused})),setMenuFocused:t,setShiftKey:a}},fe=e.reactive({monthYear:[],calendar:[],time:[],actionRow:[],selectionGrid:[],timePicker:{0:[],1:[]},monthPicker:[]}),Gt=e.ref(null),Mt=e.ref(!1),Wt=e.ref(!1),Zt=e.ref(!1),Xt=e.ref(!1),Ce=e.ref(0),ke=e.ref(0),Ze=()=>{const t=e.computed(()=>Mt.value?[...fe.selectionGrid,fe.actionRow].filter(f=>f.length):Wt.value?[...fe.timePicker[0],...fe.timePicker[1],Xt.value?[]:[Gt.value],fe.actionRow].filter(f=>f.length):Zt.value?[...fe.monthPicker,fe.actionRow]:[fe.monthYear,...fe.calendar,fe.time,fe.actionRow].filter(f=>f.length)),a=f=>{Ce.value=f?Ce.value+1:Ce.value-1;let y=null;t.value[ke.value]&&(y=t.value[ke.value][Ce.value]),!y&&t.value[ke.value+(f?1:-1)]?(ke.value=ke.value+(f?1:-1),Ce.value=f?0:t.value[ke.value].length-1):y||(Ce.value=f?Ce.value-1:Ce.value+1)},o=f=>{ke.value===0&&!f||ke.value===t.value.length&&f||(ke.value=f?ke.value+1:ke.value-1,t.value[ke.value]?t.value[ke.value]&&!t.value[ke.value][Ce.value]&&Ce.value!==0&&(Ce.value=t.value[ke.value].length-1):ke.value=f?ke.value-1:ke.value+1)},l=f=>{let y=null;t.value[ke.value]&&(y=t.value[ke.value][Ce.value]),y?y.focus({preventScroll:!Mt.value}):Ce.value=f?Ce.value-1:Ce.value+1},n=()=>{a(!0),l(!0)},s=()=>{a(!1),l(!1)},d=()=>{o(!1),l(!0)},b=()=>{o(!0),l(!0)},m=(f,y)=>{fe[y]=f},Y=(f,y)=>{fe[y]=f},p=()=>{Ce.value=0,ke.value=0};return{buildMatrix:m,buildMultiLevelMatrix:Y,setTimePickerBackRef:f=>{Gt.value=f},setSelectionGrid:f=>{Mt.value=f,p(),f||(fe.selectionGrid=[])},setTimePicker:(f,y=!1)=>{Wt.value=f,Xt.value=y,p(),f||(fe.timePicker[0]=[],fe.timePicker[1]=[])},setTimePickerElements:(f,y=0)=>{fe.timePicker[y]=f},arrowRight:n,arrowLeft:s,arrowUp:d,arrowDown:b,clearArrowNav:()=>{fe.monthYear=[],fe.calendar=[],fe.time=[],fe.actionRow=[],fe.selectionGrid=[],fe.timePicker[0]=[],fe.timePicker[1]=[],Mt.value=!1,Wt.value=!1,Xt.value=!1,Zt.value=!1,p(),Gt.value=null},setMonthPicker:f=>{Zt.value=f,p()},refSets:fe}},Aa=t=>({menuAppearTop:"dp-menu-appear-top",menuAppearBottom:"dp-menu-appear-bottom",open:"dp-slide-down",close:"dp-slide-up",next:"calendar-next",previous:"calendar-prev",vNext:"dp-slide-up",vPrevious:"dp-slide-down",...t??{}}),zl=t=>({toggleOverlay:"Toggle overlay",menu:"Datepicker menu",input:"Datepicker input",openTimePicker:"Open time picker",closeTimePicker:"Close time Picker",incrementValue:a=>`Increment ${a}`,decrementValue:a=>`Decrement ${a}`,openTpOverlay:a=>`Open ${a} overlay`,amPmButton:"Switch AM/PM mode",openYearsOverlay:"Open years overlay",openMonthsOverlay:"Open months overlay",nextMonth:"Next month",prevMonth:"Previous month",nextYear:"Next year",prevYear:"Previous year",day:void 0,weekDay:void 0,clearInput:"Clear value",calendarIcon:"Calendar icon",timePicker:"Time picker",monthPicker:a=>`Month picker${a?" overlay":""}`,yearPicker:a=>`Year picker${a?" overlay":""}`,timeOverlay:a=>`${a} overlay`,...t??{}}),Da=t=>t?typeof t=="boolean"?t?2:0:+t>=2?+t:2:0,Fl=t=>{const a=typeof t=="object"&&t,o={static:!0,solo:!1};if(!t)return{...o,count:Da(!1)};const l=a?t:{},n=a?l.count??!0:t,s=Da(n);return Object.assign(o,l,{count:s})},Il=(t,a,o)=>t||(typeof o=="string"?o:a),Ll=t=>typeof t=="boolean"?t?Aa({}):!1:Aa(t),Hl=t=>{const a={enterSubmit:!0,tabSubmit:!0,openMenu:"open",selectOnFocus:!1,rangeSeparator:" - "};return typeof t=="object"?{...a,...t??{},enabled:!0}:{...a,enabled:t}},ql=t=>({months:[],years:[],times:{hours:[],minutes:[],seconds:[]},...t??{}}),Ul=t=>({showSelect:!0,showCancel:!0,showNow:!1,showPreview:!0,...t??{}}),jl=t=>{const a={input:!1};return typeof t=="object"?{...a,...t??{},enabled:!0}:{enabled:t,...a}},Ql=t=>({allowStopPropagation:!0,closeOnScroll:!1,modeHeight:255,allowPreventDefault:!1,closeOnClearValue:!0,closeOnAutoApply:!0,noSwipe:!1,keepActionRow:!1,onClickOutside:void 0,tabOutClosesMenu:!0,arrowLeft:void 0,keepViewOnOffsetClick:!1,timeArrowHoldThreshold:0,shadowDom:!1,...t??{}}),Kl=t=>{const a={dates:Array.isArray(t)?t.map(o=>L(o)):[],years:[],months:[],quarters:[],weeks:[],weekdays:[],options:{highlightDisabled:!1}};return typeof t=="function"?t:{...a,...t??{}}},Gl=t=>typeof t=="object"?{type:(t==null?void 0:t.type)??"local",hideOnOffsetDates:(t==null?void 0:t.hideOnOffsetDates)??!1}:{type:t,hideOnOffsetDates:!1},Wl=t=>{const a={noDisabledRange:!1,showLastInRange:!0,minMaxRawRange:!1,partialRange:!0,disableTimeRangeValidation:!1,maxRange:void 0,minRange:void 0,autoRange:void 0,fixedStart:!1,fixedEnd:!1};return typeof t=="object"?{enabled:!0,...a,...t}:{enabled:t,...a}},Zl=t=>t?typeof t=="string"?{timezone:t,exactMatch:!1,dateInTz:void 0,emitTimezone:void 0,convertModel:!0}:{timezone:t.timezone,exactMatch:t.exactMatch??!1,dateInTz:t.dateInTz??void 0,emitTimezone:t.emitTimezone??void 0,convertModel:t.convertModel??!0}:{timezone:void 0,exactMatch:!1,emitTimezone:void 0},Jt=(t,a,o)=>new Map(t.map(l=>{const n=ca(l,a,o);return[pa(n),n]})),Xl=(t,a)=>t.length?new Map(t.map(o=>{const l=ca(o.date,a);return[pa(l),o]})):null,Jl=t=>{var a;return{minDate:aa(t.minDate,t.timezone,t.isSpecific),maxDate:aa(t.maxDate,t.timezone,t.isSpecific),disabledDates:qt(t.disabledDates)?Jt(t.disabledDates,t.timezone,t.isSpecific):t.disabledDates,allowedDates:qt(t.allowedDates)?Jt(t.allowedDates,t.timezone,t.isSpecific):null,highlight:typeof t.highlight=="object"&&qt((a=t.highlight)==null?void 0:a.dates)?Jt(t.highlight.dates,t.timezone):t.highlight,markers:Xl(t.markers,t.timezone)}},en=t=>typeof t=="boolean"?{enabled:t,dragSelect:!0,limit:null}:{enabled:!!t,limit:t.limit?+t.limit:null,dragSelect:t.dragSelect??!0},tn=t=>({...Object.fromEntries(Object.keys(t).map(a=>{const o=a,l=t[o],n=typeof t[o]=="string"?{[l]:!0}:Object.fromEntries(l.map(s=>[s,!0]));return[a,n]}))}),he=t=>{const a=()=>{const V=t.enableSeconds?":ss":"",P=t.enableMinutes?":mm":"";return t.is24?`HH${P}${V}`:`hh${P}${V} aa`},o=()=>{var V;return t.format?t.format:t.monthPicker?"MM/yyyy":t.timePicker?a():t.weekPicker?`${((V=H.value)==null?void 0:V.type)==="iso"?"RR":"ww"}-yyyy`:t.yearPicker?"yyyy":t.quarterPicker?"QQQ/yyyy":t.enableTimePicker?`MM/dd/yyyy, ${a()}`:"MM/dd/yyyy"},l=V=>Ka(V,t.enableSeconds),n=()=>I.value.enabled?t.startTime&&Array.isArray(t.startTime)?[l(t.startTime[0]),l(t.startTime[1])]:null:t.startTime&&!Array.isArray(t.startTime)?l(t.startTime):null,s=e.computed(()=>Fl(t.multiCalendars)),d=e.computed(()=>n()),b=e.computed(()=>zl(t.ariaLabels)),m=e.computed(()=>ql(t.filters)),Y=e.computed(()=>Ll(t.transitions)),p=e.computed(()=>Ul(t.actionRow)),f=e.computed(()=>Il(t.previewFormat,t.format,o())),y=e.computed(()=>Hl(t.textInput)),C=e.computed(()=>jl(t.inline)),T=e.computed(()=>Ql(t.config)),S=e.computed(()=>Kl(t.highlight)),H=e.computed(()=>Gl(t.weekNumbers)),z=e.computed(()=>Zl(t.timezone)),q=e.computed(()=>en(t.multiDates)),M=e.computed(()=>Jl({minDate:t.minDate,maxDate:t.maxDate,disabledDates:t.disabledDates,allowedDates:t.allowedDates,highlight:S.value,markers:t.markers,timezone:z.value,isSpecific:t.monthPicker||t.yearPicker||t.quarterPicker})),I=e.computed(()=>Wl(t.range)),J=e.computed(()=>tn(t.ui));return{defaultedTransitions:Y,defaultedMultiCalendars:s,defaultedStartTime:d,defaultedAriaLabels:b,defaultedFilters:m,defaultedActionRow:p,defaultedPreviewFormat:f,defaultedTextInput:y,defaultedInline:C,defaultedConfig:T,defaultedHighlight:S,defaultedWeekNumbers:H,defaultedRange:I,propDates:M,defaultedTz:z,defaultedMultiDates:q,defaultedUI:J,getDefaultPattern:o,getDefaultStartTime:n}},an=(t,a,o)=>{const l=e.ref(),{defaultedTextInput:n,defaultedRange:s,defaultedTz:d,defaultedMultiDates:b,getDefaultPattern:m}=he(a),Y=e.ref(""),p=e.toRef(a,"format"),f=e.toRef(a,"formatLocale");e.watch(l,()=>{typeof a.onInternalModelChange=="function"&&t("internal-model-change",l.value,O(!0))},{deep:!0}),e.watch(s,(i,Z)=>{i.enabled!==Z.enabled&&(l.value=null)}),e.watch(p,()=>{X()});const y=i=>d.value.timezone&&d.value.convertModel?Te(i,d.value.timezone):i,C=i=>{if(d.value.timezone&&d.value.convertModel){const Z=_l(d.value.timezone);return dl.addHours(i,Z)}return i},T=(i,Z,ie=!1)=>Wa(i,a.format,a.formatLocale,n.value.rangeSeparator,a.modelAuto,Z??m(),ie),S=i=>i?a.modelType?W(i):{hours:He.getHours(i),minutes:We.getMinutes(i),seconds:a.enableSeconds?st.getSeconds(i):0}:null,H=i=>a.modelType?W(i):{month:me.getMonth(i),year:se.getYear(i)},z=i=>Array.isArray(i)?b.value.enabled?i.map(Z=>q(Z,ze.setYear(L(),Z))):Bt(()=>[ze.setYear(L(),i[0]),i[1]?ze.setYear(L(),i[1]):rt(s.value.partialRange)],s.value.enabled):ze.setYear(L(),+i),q=(i,Z)=>(typeof i=="string"||typeof i=="number")&&a.modelType?$(i):Z,M=i=>Array.isArray(i)?[q(i[0],Ge(null,+i[0].hours,+i[0].minutes,i[0].seconds)),q(i[1],Ge(null,+i[1].hours,+i[1].minutes,i[1].seconds))]:q(i,Ge(null,i.hours,i.minutes,i.seconds)),I=i=>{const Z=pe.set(L(),{date:1});return Array.isArray(i)?b.value.enabled?i.map(ie=>q(ie,Le(Z,+ie.month,+ie.year))):Bt(()=>[q(i[0],Le(Z,+i[0].month,+i[0].year)),q(i[1],i[1]?Le(Z,+i[1].month,+i[1].year):rt(s.value.partialRange))],s.value.enabled):q(i,Le(Z,+i.month,+i.year))},J=i=>{if(Array.isArray(i))return i.map(Z=>$(Z));throw new Error(va.dateArr("multi-dates"))},V=i=>{if(Array.isArray(i)&&s.value.enabled){const Z=i[0],ie=i[1];return[L(Array.isArray(Z)?Z[0]:null),L(Array.isArray(ie)?ie[0]:null)]}return L(i[0])},P=i=>a.modelAuto?Array.isArray(i)?[$(i[0]),$(i[1])]:a.autoApply?[$(i)]:[$(i),null]:Array.isArray(i)?Bt(()=>i[1]?[$(i[0]),i[1]?$(i[1]):rt(s.value.partialRange)]:[$(i[0])],s.value.enabled):$(i),ee=()=>{Array.isArray(l.value)&&s.value.enabled&&l.value.length===1&&l.value.push(rt(s.value.partialRange))},F=()=>{const i=l.value;return[W(i[0]),i[1]?W(i[1]):rt(s.value.partialRange)]},N=()=>l.value[1]?F():W(Se(l.value[0])),te=()=>(l.value||[]).map(i=>W(i)),ne=(i=!1)=>(i||ee(),a.modelAuto?N():b.value.enabled?te():Array.isArray(l.value)?Bt(()=>F(),s.value.enabled):W(Se(l.value))),ue=i=>!i||Array.isArray(i)&&!i.length?null:a.timePicker?M(Se(i)):a.monthPicker?I(Se(i)):a.yearPicker?z(Se(i)):b.value.enabled?J(Se(i)):a.weekPicker?V(Se(i)):P(Se(i)),h=i=>{const Z=ue(i);na(Se(Z))?(l.value=Se(Z),X()):(l.value=null,Y.value="")},x=()=>{const i=Z=>Fe.formatDate(Z,n.value.format);return`${i(l.value[0])} ${n.value.rangeSeparator} ${l.value[1]?i(l.value[1]):""}`},g=()=>o.value&&l.value?Array.isArray(l.value)?x():Fe.formatDate(l.value,n.value.format):T(l.value),R=()=>l.value?b.value.enabled?l.value.map(i=>T(i)).join("; "):n.value.enabled&&typeof n.value.format=="string"?g():T(l.value):"",X=()=>{!a.format||typeof a.format=="string"||n.value.enabled&&typeof n.value.format=="string"?Y.value=R():Y.value=a.format(l.value)},$=i=>{if(a.utc){const Z=new Date(i);return a.utc==="preserve"?new Date(Z.getTime()+Z.getTimezoneOffset()*6e4):Z}return a.modelType?Sl.includes(a.modelType)?y(new Date(i)):a.modelType==="format"&&(typeof a.format=="string"||!a.format)?y(ta.parse(i,m(),new Date,{locale:f.value})):y(ta.parse(i,a.modelType,new Date,{locale:f.value})):y(new Date(i))},W=i=>i?a.utc?$l(i,a.utc==="preserve",a.enableSeconds):a.modelType?a.modelType==="timestamp"?+C(i):a.modelType==="iso"?C(i).toISOString():a.modelType==="format"&&(typeof a.format=="string"||!a.format)?T(C(i)):T(C(i),a.modelType,!0):C(i):"",oe=(i,Z=!1,ie=!1)=>{if(ie)return i;if(t("update:model-value",i),d.value.emitTimezone&&Z){const we=Array.isArray(i)?i.map(B=>Te(Se(B),d.value.emitTimezone)):Te(Se(i),d.value.emitTimezone);t("update:model-timezone-value",we)}},c=i=>Array.isArray(l.value)?b.value.enabled?l.value.map(Z=>i(Z)):[i(l.value[0]),l.value[1]?i(l.value[1]):rt(s.value.partialRange)]:i(Se(l.value)),v=()=>{if(Array.isArray(l.value)){const i=Ie(l.value[0],a.weekStart),Z=l.value[1]?Ie(l.value[1],a.weekStart):[];return[i.map(ie=>L(ie)),Z.map(ie=>L(ie))]}return Ie(l.value,a.weekStart).map(i=>L(i))},r=(i,Z)=>oe(Se(c(i)),!1,Z),_=i=>{const Z=v();return i?Z:t("update:model-value",v())},O=(i=!1)=>(i||X(),a.monthPicker?r(H,i):a.timePicker?r(S,i):a.yearPicker?r(se.getYear,i):a.weekPicker?_(i):oe(ne(i),!0,i));return{inputValue:Y,internalModelValue:l,checkBeforeEmit:()=>l.value?s.value.enabled?s.value.partialRange?l.value.length>=1:l.value.length===2:!!l.value:!1,parseExternalModelValue:h,formatInputValue:X,emitModelValue:O}},ln=(t,a)=>{const{defaultedFilters:o,propDates:l}=he(t),{validateMonthYearInRange:n}=Xe(t),s=(p,f)=>{let y=p;return o.value.months.includes(me.getMonth(y))?(y=f?at.addMonths(p,1):kt.subMonths(p,1),s(y,f)):y},d=(p,f)=>{let y=p;return o.value.years.includes(se.getYear(y))?(y=f?Ea.addYears(p,1):za.subYears(p,1),d(y,f)):y},b=(p,f=!1)=>{const y=pe.set(L(),{month:t.month,year:t.year});let C=p?at.addMonths(y,1):kt.subMonths(y,1);t.disableYearSelect&&(C=ze.setYear(C,t.year));let T=me.getMonth(C),S=se.getYear(C);o.value.months.includes(T)&&(C=s(C,p),T=me.getMonth(C),S=se.getYear(C)),o.value.years.includes(S)&&(C=d(C,p),S=se.getYear(C)),n(T,S,p,t.preventMinMaxNavigation)&&m(T,S,f)},m=(p,f,y)=>{a("update-month-year",{month:p,year:f,fromNav:y})},Y=e.computed(()=>p=>Ga(pe.set(L(),{month:t.month,year:t.year}),l.value.maxDate,l.value.minDate,t.preventMinMaxNavigation,p));return{handleMonthYearChange:b,isDisabled:Y,updateMonthYear:m}},Nt={multiCalendars:{type:[Boolean,Number,String,Object],default:void 0},modelValue:{type:[String,Date,Array,Object,Number],default:null},modelType:{type:String,default:null},position:{type:String,default:"center"},dark:{type:Boolean,default:!1},format:{type:[String,Function],default:()=>null},autoPosition:{type:Boolean,default:!0},altPosition:{type:Function,default:null},transitions:{type:[Boolean,Object],default:!0},formatLocale:{type:Object,default:null},utc:{type:[Boolean,String],default:!1},ariaLabels:{type:Object,default:()=>({})},offset:{type:[Number,String],default:10},hideNavigation:{type:Array,default:()=>[]},timezone:{type:[String,Object],default:null},vertical:{type:Boolean,default:!1},disableMonthYearSelect:{type:Boolean,default:!1},disableYearSelect:{type:Boolean,default:!1},dayClass:{type:Function,default:null},yearRange:{type:Array,default:()=>[1900,2100]},enableTimePicker:{type:Boolean,default:!0},autoApply:{type:Boolean,default:!1},disabledDates:{type:[Array,Function],default:()=>[]},monthNameFormat:{type:String,default:"short"},startDate:{type:[Date,String],default:null},startTime:{type:[Object,Array],default:null},hideOffsetDates:{type:Boolean,default:!1},noToday:{type:Boolean,default:!1},disabledWeekDays:{type:Array,default:()=>[]},allowedDates:{type:Array,default:null},nowButtonLabel:{type:String,default:"Now"},markers:{type:Array,default:()=>[]},escClose:{type:Boolean,default:!0},spaceConfirm:{type:Boolean,default:!0},monthChangeOnArrows:{type:Boolean,default:!0},presetDates:{type:Array,default:()=>[]},flow:{type:Array,default:()=>[]},partialFlow:{type:Boolean,default:!1},preventMinMaxNavigation:{type:Boolean,default:!1},reverseYears:{type:Boolean,default:!1},weekPicker:{type:Boolean,default:!1},filters:{type:Object,default:()=>({})},arrowNavigation:{type:Boolean,default:!1},highlight:{type:[Function,Object],default:null},teleport:{type:[Boolean,String,Object],default:null},teleportCenter:{type:Boolean,default:!1},locale:{type:String,default:"en-Us"},weekNumName:{type:String,default:"W"},weekStart:{type:[Number,String],default:1},weekNumbers:{type:[String,Function,Object],default:null},monthChangeOnScroll:{type:[Boolean,String],default:!0},dayNames:{type:[Function,Array],default:null},monthPicker:{type:Boolean,default:!1},customProps:{type:Object,default:null},yearPicker:{type:Boolean,default:!1},modelAuto:{type:Boolean,default:!1},selectText:{type:String,default:"Select"},cancelText:{type:String,default:"Cancel"},previewFormat:{type:[String,Function],default:()=>""},multiDates:{type:[Object,Boolean],default:!1},ignoreTimeValidation:{type:Boolean,default:!1},minDate:{type:[Date,String],default:null},maxDate:{type:[Date,String],default:null},minTime:{type:Object,default:null},maxTime:{type:Object,default:null},name:{type:String,default:null},placeholder:{type:String,default:""},hideInputIcon:{type:Boolean,default:!1},clearable:{type:Boolean,default:!0},state:{type:Boolean,default:null},required:{type:Boolean,default:!1},autocomplete:{type:String,default:"off"},timePicker:{type:Boolean,default:!1},enableSeconds:{type:Boolean,default:!1},is24:{type:Boolean,default:!0},noHoursOverlay:{type:Boolean,default:!1},noMinutesOverlay:{type:Boolean,default:!1},noSecondsOverlay:{type:Boolean,default:!1},hoursGridIncrement:{type:[String,Number],default:1},minutesGridIncrement:{type:[String,Number],default:5},secondsGridIncrement:{type:[String,Number],default:5},hoursIncrement:{type:[Number,String],default:1},minutesIncrement:{type:[Number,String],default:1},secondsIncrement:{type:[Number,String],default:1},range:{type:[Boolean,Object],default:!1},uid:{type:String,default:null},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},inline:{type:[Boolean,Object],default:!1},textInput:{type:[Boolean,Object],default:!1},sixWeeks:{type:[Boolean,String],default:!1},actionRow:{type:Object,default:()=>({})},focusStartDate:{type:Boolean,default:!1},disabledTimes:{type:[Function,Array],default:void 0},timePickerInline:{type:Boolean,default:!1},calendar:{type:Function,default:null},config:{type:Object,default:void 0},quarterPicker:{type:Boolean,default:!1},yearFirst:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},onInternalModelChange:{type:[Function,Object],default:null},enableMinutes:{type:Boolean,default:!0},ui:{type:Object,default:()=>({})}},Ye={...Nt,shadow:{type:Boolean,default:!1},flowStep:{type:Number,default:0},internalModelValue:{type:[Date,Array],default:null},noOverlayFocus:{type:Boolean,default:!1},collapse:{type:Boolean,default:!1},menuWrapRef:{type:Object,default:null},getInputRect:{type:Function,default:()=>({})},isTextInputDate:{type:Boolean,default:!1}},nn=["title"],rn=["disabled"],on=e.defineComponent({compatConfig:{MODE:3},__name:"ActionRow",props:{menuMount:{type:Boolean,default:!1},calendarWidth:{type:Number,default:0},...Ye},emits:["close-picker","select-date","select-now","invalid-select"],setup(t,{emit:a}){const o=a,l=t,{defaultedActionRow:n,defaultedPreviewFormat:s,defaultedMultiCalendars:d,defaultedTextInput:b,defaultedInline:m,defaultedRange:Y,defaultedMultiDates:p}=he(l),{isTimeValid:f,isMonthValid:y}=Xe(l),{buildMatrix:C}=Ze(),T=e.ref(null),S=e.ref(null),H=e.ref(!1),z=e.ref({}),q=e.ref(null),M=e.ref(null);e.onMounted(()=>{l.arrowNavigation&&C([_e(T),_e(S)],"actionRow"),I(),window.addEventListener("resize",I)}),e.onUnmounted(()=>{window.removeEventListener("resize",I)});const I=()=>{H.value=!1,setTimeout(()=>{var h,x;const g=(h=q.value)==null?void 0:h.getBoundingClientRect(),R=(x=M.value)==null?void 0:x.getBoundingClientRect();g&&R&&(z.value.maxWidth=`${R.width-g.width-20}px`),H.value=!0},0)},J=e.computed(()=>Y.value.enabled&&!Y.value.partialRange&&l.internalModelValue?l.internalModelValue.length===2:!0),V=e.computed(()=>!f.value(l.internalModelValue)||!y.value(l.internalModelValue)||!J.value),P=()=>{const h=s.value;return l.timePicker||l.monthPicker,h(Se(l.internalModelValue))},ee=()=>{const h=l.internalModelValue;return d.value.count>0?`${F(h[0])} - ${F(h[1])}`:[F(h[0]),F(h[1])]},F=h=>Wa(h,s.value,l.formatLocale,b.value.rangeSeparator,l.modelAuto,s.value),N=e.computed(()=>!l.internalModelValue||!l.menuMount?"":typeof s.value=="string"?Array.isArray(l.internalModelValue)?l.internalModelValue.length===2&&l.internalModelValue[1]?ee():p.value.enabled?l.internalModelValue.map(h=>`${F(h)}`):l.modelAuto?`${F(l.internalModelValue[0])}`:`${F(l.internalModelValue[0])} -`:F(l.internalModelValue):P()),te=()=>p.value.enabled?"; ":" - ",ne=e.computed(()=>Array.isArray(N.value)?N.value.join(te()):N.value),ue=()=>{f.value(l.internalModelValue)&&y.value(l.internalModelValue)&&J.value?o("select-date"):o("invalid-select")};return(h,x)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"actionRowRef",ref:M,class:"dp__action_row"},[h.$slots["action-row"]?e.renderSlot(h.$slots,"action-row",e.normalizeProps(e.mergeProps({key:0},{internalModelValue:h.internalModelValue,disabled:V.value,selectDate:()=>h.$emit("select-date"),closePicker:()=>h.$emit("close-picker")}))):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.unref(n).showPreview?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__selection_preview",title:ne.value,style:e.normalizeStyle(z.value)},[h.$slots["action-preview"]&&H.value?e.renderSlot(h.$slots,"action-preview",{key:0,value:h.internalModelValue}):e.createCommentVNode("",!0),!h.$slots["action-preview"]&&H.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(ne.value),1)],64)):e.createCommentVNode("",!0)],12,nn)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"actionBtnContainer",ref:q,class:"dp__action_buttons","data-dp-element":"action-row"},[h.$slots["action-buttons"]?e.renderSlot(h.$slots,"action-buttons",{key:0,value:h.internalModelValue}):e.createCommentVNode("",!0),h.$slots["action-buttons"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[!e.unref(m).enabled&&e.unref(n).showCancel?(e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"cancelButtonRef",ref:T,type:"button",class:"dp__action_button dp__action_cancel",onClick:x[0]||(x[0]=g=>h.$emit("close-picker")),onKeydown:x[1]||(x[1]=g=>e.unref(Ae)(g,()=>h.$emit("close-picker")))},e.toDisplayString(h.cancelText),545)):e.createCommentVNode("",!0),e.unref(n).showNow?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"dp__action_button dp__action_cancel",onClick:x[2]||(x[2]=g=>h.$emit("select-now")),onKeydown:x[3]||(x[3]=g=>e.unref(Ae)(g,()=>h.$emit("select-now")))},e.toDisplayString(h.nowButtonLabel),33)):e.createCommentVNode("",!0),e.unref(n).showSelect?(e.openBlock(),e.createElementBlock("button",{key:2,ref_key:"selectButtonRef",ref:S,type:"button",class:"dp__action_button dp__action_select",disabled:V.value,"data-test":"select-button",onKeydown:x[4]||(x[4]=g=>e.unref(Ae)(g,()=>ue())),onClick:ue},e.toDisplayString(h.selectText),41,rn)):e.createCommentVNode("",!0)],64))],512)],64))],512))}}),un=["role","aria-label","tabindex"],sn={class:"dp__selection_grid_header"},dn=["aria-selected","aria-disabled","data-test","onClick","onKeydown","onMouseover"],cn=["aria-label"],wt=e.defineComponent({__name:"SelectionOverlay",props:{items:{},type:{},isLast:{type:Boolean},arrowNavigation:{type:Boolean},skipButtonRef:{type:Boolean},headerRefs:{},hideNavigation:{},escClose:{type:Boolean},useRelative:{type:Boolean},height:{},textInput:{type:[Boolean,Object]},config:{},noOverlayFocus:{type:Boolean},focusValue:{},menuWrapRef:{},ariaLabels:{},overlayLabel:{}},emits:["selected","toggle","reset-flow","hover-value"],setup(t,{expose:a,emit:o}){const{setSelectionGrid:l,buildMultiLevelMatrix:n,setMonthPicker:s}=Ze(),d=o,b=t,{defaultedAriaLabels:m,defaultedTextInput:Y,defaultedConfig:p}=he(b),{hideNavigationButtons:f}=Rt(),y=e.ref(!1),C=e.ref(null),T=e.ref(null),S=e.ref([]),H=e.ref(),z=e.ref(null),q=e.ref(0),M=e.ref(null);e.onBeforeUpdate(()=>{C.value=null}),e.onMounted(()=>{e.nextTick().then(()=>te()),b.noOverlayFocus||J(),I(!0)}),e.onUnmounted(()=>I(!1));const I=c=>{var v;b.arrowNavigation&&((v=b.headerRefs)!=null&&v.length?s(c):l(c))},J=()=>{var c;const v=_e(T);v&&(Y.value.enabled||(C.value?(c=C.value)==null||c.focus({preventScroll:!0}):v.focus({preventScroll:!0})),y.value=v.clientHeight<v.scrollHeight)},V=e.computed(()=>({dp__overlay:!0,"dp--overlay-absolute":!b.useRelative,"dp--overlay-relative":b.useRelative})),P=e.computed(()=>b.useRelative?{height:`${b.height}px`,width:"var(--dp-menu-min-width)"}:void 0),ee=e.computed(()=>({dp__overlay_col:!0})),F=e.computed(()=>({dp__btn:!0,dp__button:!0,dp__overlay_action:!0,dp__over_action_scroll:y.value,dp__button_bottom:b.isLast})),N=e.computed(()=>{var c,v;return{dp__overlay_container:!0,dp__container_flex:((c=b.items)==null?void 0:c.length)<=6,dp__container_block:((v=b.items)==null?void 0:v.length)>6}});e.watch(()=>b.items,()=>te(!1),{deep:!0});const te=(c=!0)=>{e.nextTick().then(()=>{const v=_e(C),r=_e(T),_=_e(z),O=_e(M),i=_?_.getBoundingClientRect().height:0;r&&(r.getBoundingClientRect().height?q.value=r.getBoundingClientRect().height-i:q.value=p.value.modeHeight-i),v&&O&&c&&(O.scrollTop=v.offsetTop-O.offsetTop-(q.value/2-v.getBoundingClientRect().height)-i)})},ne=c=>{c.disabled||d("selected",c.value)},ue=()=>{d("toggle"),d("reset-flow")},h=()=>{b.escClose&&ue()},x=(c,v,r,_)=>{c&&((v.active||v.value===b.focusValue)&&(C.value=c),b.arrowNavigation&&(Array.isArray(S.value[r])?S.value[r][_]=c:S.value[r]=[c],g()))},g=()=>{var c,v;const r=(c=b.headerRefs)!=null&&c.length?[b.headerRefs].concat(S.value):S.value.concat([b.skipButtonRef?[]:[z.value]]);n(Se(r),(v=b.headerRefs)!=null&&v.length?"monthPicker":"selectionGrid")},R=c=>{b.arrowNavigation||Ke(c,p.value,!0)},X=c=>{H.value=c,d("hover-value",c)},$=()=>{if(ue(),!b.isLast){const c=la(b.menuWrapRef??null,"action-row");if(c){const v=Ha(c);v==null||v.focus()}}},W=c=>{switch(c.key){case ye.esc:return h();case ye.arrowLeft:return R(c);case ye.arrowRight:return R(c);case ye.arrowUp:return R(c);case ye.arrowDown:return R(c);default:return}},oe=c=>{if(c.key===ye.enter)return ue();if(c.key===ye.tab)return $()};return a({focusGrid:J}),(c,v)=>{var r;return e.openBlock(),e.createElementBlock("div",{ref_key:"gridWrapRef",ref:T,class:e.normalizeClass(V.value),style:e.normalizeStyle(P.value),role:c.useRelative?void 0:"dialog","aria-label":c.overlayLabel,tabindex:c.useRelative?void 0:"0",onKeydown:W,onClick:v[0]||(v[0]=e.withModifiers(()=>{},["prevent"]))},[e.createElementVNode("div",{ref_key:"containerRef",ref:M,class:e.normalizeClass(N.value),style:e.normalizeStyle({"--dp-overlay-height":`${q.value}px`}),role:"grid"},[e.createElementVNode("div",sn,[e.renderSlot(c.$slots,"header")]),c.$slots.overlay?e.renderSlot(c.$slots,"overlay",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c.items,(_,O)=>(e.openBlock(),e.createElementBlock("div",{key:O,class:e.normalizeClass(["dp__overlay_row",{dp__flex_row:c.items.length>=3}]),role:"row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(_,(i,Z)=>(e.openBlock(),e.createElementBlock("div",{key:i.value,ref_for:!0,ref:ie=>x(ie,i,O,Z),role:"gridcell",class:e.normalizeClass(ee.value),"aria-selected":i.active||void 0,"aria-disabled":i.disabled||void 0,tabindex:"0","data-test":i.text,onClick:e.withModifiers(ie=>ne(i),["prevent"]),onKeydown:ie=>e.unref(Ae)(ie,()=>ne(i),!0),onMouseover:ie=>X(i.value)},[e.createElementVNode("div",{class:e.normalizeClass(i.className)},[c.$slots.item?e.renderSlot(c.$slots,"item",{key:0,item:i}):e.createCommentVNode("",!0),c.$slots.item?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(i.text),1)],64))],2)],42,dn))),128))],2))),128))],6),c.$slots["button-icon"]?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"toggleButton",ref:z,type:"button","aria-label":(r=e.unref(m))==null?void 0:r.toggleOverlay,class:e.normalizeClass(F.value),tabindex:"0",onClick:ue,onKeydown:oe},[e.renderSlot(c.$slots,"button-icon")],42,cn)),[[e.vShow,!e.unref(f)(c.hideNavigation,c.type)]]):e.createCommentVNode("",!0)],46,un)}}}),$t=e.defineComponent({__name:"InstanceWrap",props:{multiCalendars:{},stretch:{type:Boolean},collapse:{type:Boolean}},setup(t){const a=t,o=e.computed(()=>a.multiCalendars>0?[...Array(a.multiCalendars).keys()]:[0]),l=e.computed(()=>({dp__instance_calendar:a.multiCalendars>0}));return(n,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass({dp__menu_inner:!n.stretch,"dp--menu--inner-stretched":n.stretch,dp__flex_display:n.multiCalendars>0,"dp--flex-display-collapsed":n.collapse})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(d,b)=>(e.openBlock(),e.createElementBlock("div",{key:d,class:e.normalizeClass(l.value)},[e.renderSlot(n.$slots,"default",{instance:d,index:b})],2))),128))],2))}}),mn=["data-dp-element","aria-label","aria-disabled"],ht=e.defineComponent({compatConfig:{MODE:3},__name:"ArrowBtn",props:{ariaLabel:{},elName:{},disabled:{type:Boolean}},emits:["activate","set-ref"],setup(t,{emit:a}){const o=a,l=e.ref(null);return e.onMounted(()=>o("set-ref",l)),(n,s)=>(e.openBlock(),e.createElementBlock("button",{ref_key:"elRef",ref:l,type:"button","data-dp-element":n.elName,class:"dp__btn dp--arrow-btn-nav",tabindex:"0","aria-label":n.ariaLabel,"aria-disabled":n.disabled||void 0,onClick:s[0]||(s[0]=d=>n.$emit("activate")),onKeydown:s[1]||(s[1]=d=>e.unref(Ae)(d,()=>n.$emit("activate"),!0))},[e.createElementVNode("span",{class:e.normalizeClass(["dp__inner_nav",{dp__inner_nav_disabled:n.disabled}])},[e.renderSlot(n.$slots,"default")],2)],40,mn))}}),vn=["aria-label","data-test"],el=e.defineComponent({__name:"YearModePicker",props:{...Ye,showYearPicker:{type:Boolean,default:!1},items:{type:Array,default:()=>[]},instance:{type:Number,default:0},year:{type:Number,default:0},isDisabled:{type:Function,default:()=>!1}},emits:["toggle-year-picker","year-select","handle-year"],setup(t,{emit:a}){const o=a,l=t,{showRightIcon:n,showLeftIcon:s}=Rt(),{defaultedConfig:d,defaultedMultiCalendars:b,defaultedAriaLabels:m,defaultedTransitions:Y,defaultedUI:p}=he(l),{showTransition:f,transitionName:y}=_t(Y),C=e.ref(!1),T=(z=!1,q)=>{C.value=!C.value,o("toggle-year-picker",{flow:z,show:q})},S=z=>{C.value=!1,o("year-select",z)},H=(z=!1)=>{o("handle-year",z)};return(z,q)=>{var M,I,J,V,P;return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{class:e.normalizeClass(["dp--year-mode-picker",{"dp--hidden-el":C.value}])},[e.unref(s)(e.unref(b),t.instance)?(e.openBlock(),e.createBlock(ht,{key:0,ref:"mpPrevIconRef","aria-label":(M=e.unref(m))==null?void 0:M.prevYear,disabled:t.isDisabled(!1),class:e.normalizeClass((I=e.unref(p))==null?void 0:I.navBtnPrev),onActivate:q[0]||(q[0]=ee=>H(!1))},{default:e.withCtx(()=>[z.$slots["arrow-left"]?e.renderSlot(z.$slots,"arrow-left",{key:0}):e.createCommentVNode("",!0),z.$slots["arrow-left"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(oa),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.createElementVNode("button",{ref:"mpYearButtonRef",class:"dp__btn dp--year-select",type:"button","aria-label":`${t.year}-${(J=e.unref(m))==null?void 0:J.openYearsOverlay}`,"data-test":`year-mode-btn-${t.instance}`,onClick:q[1]||(q[1]=()=>T(!1)),onKeydown:q[2]||(q[2]=e.withKeys(()=>T(!1),["enter"]))},[z.$slots.year?e.renderSlot(z.$slots,"year",{key:0,year:t.year}):e.createCommentVNode("",!0),z.$slots.year?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(t.year),1)],64))],40,vn),e.unref(n)(e.unref(b),t.instance)?(e.openBlock(),e.createBlock(ht,{key:1,ref:"mpNextIconRef","aria-label":(V=e.unref(m))==null?void 0:V.nextYear,disabled:t.isDisabled(!0),class:e.normalizeClass((P=e.unref(p))==null?void 0:P.navBtnNext),onActivate:q[3]||(q[3]=ee=>H(!0))},{default:e.withCtx(()=>[z.$slots["arrow-right"]?e.renderSlot(z.$slots,"arrow-right",{key:0}):e.createCommentVNode("",!0),z.$slots["arrow-right"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ua),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0)],2),e.createVNode(e.Transition,{name:e.unref(y)(t.showYearPicker),css:e.unref(f)},{default:e.withCtx(()=>{var ee,F;return[t.showYearPicker?(e.openBlock(),e.createBlock(wt,{key:0,items:t.items,"text-input":z.textInput,"esc-close":z.escClose,config:z.config,"is-last":z.autoApply&&!e.unref(d).keepActionRow,"hide-navigation":z.hideNavigation,"aria-labels":z.ariaLabels,"overlay-label":(F=(ee=e.unref(m))==null?void 0:ee.yearPicker)==null?void 0:F.call(ee,!0),type:"year",onToggle:T,onSelected:q[4]||(q[4]=N=>S(N))},e.createSlots({"button-icon":e.withCtx(()=>[z.$slots["calendar-icon"]?e.renderSlot(z.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),z.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(mt),{key:1}))]),_:2},[z.$slots["year-overlay-value"]?{name:"item",fn:e.withCtx(({item:N})=>[e.renderSlot(z.$slots,"year-overlay-value",{text:N.text,value:N.value})]),key:"0"}:void 0]),1032,["items","text-input","esc-close","config","is-last","hide-navigation","aria-labels","overlay-label"])):e.createCommentVNode("",!0)]}),_:3},8,["name","css"])],64)}}}),ya=(t,a,o)=>{if(a.value&&Array.isArray(a.value))if(a.value.some(l=>ve(t,l))){const l=a.value.filter(n=>!ve(n,t));a.value=l.length?l:null}else(o&&+o>a.value.length||!o)&&a.value.push(t);else a.value=[t]},ha=(t,a,o)=>{let l=t.value?t.value.slice():[];return l.length===2&&l[1]!==null&&(l=[]),l.length?ge(a,l[0])?(l.unshift(a),o("range-start",l[0]),o("range-start",l[1])):(l[1]=a,o("range-end",a)):(l=[a],o("range-start",a)),l},Vt=(t,a,o,l)=>{t&&(t[0]&&t[1]&&o&&a("auto-apply"),t[0]&&!t[1]&&l&&o&&a("auto-apply"))},tl=t=>{Array.isArray(t.value)&&t.value.length<=2&&t.range?t.modelValue.value=t.value.map(a=>Te(L(a),t.timezone)):Array.isArray(t.value)||(t.modelValue.value=Te(L(t.value),t.timezone))},al=(t,a,o,l)=>Array.isArray(a.value)&&(a.value.length===2||a.value.length===1&&l.value.partialRange)?l.value.fixedStart&&(be(t,a.value[0])||ve(t,a.value[0]))?[a.value[0],t]:l.value.fixedEnd&&(ge(t,a.value[1])||ve(t,a.value[1]))?[t,a.value[1]]:(o("invalid-fixed-range",t),a.value):[],ll=({multiCalendars:t,range:a,highlight:o,propDates:l,calendars:n,modelValue:s,props:d,filters:b,year:m,month:Y,emit:p})=>{const f=e.computed(()=>ma(d.yearRange,d.locale,d.reverseYears)),y=e.ref([!1]),C=e.computed(()=>(N,te)=>{const ne=pe.set(Oe(new Date),{month:Y.value(N),year:m.value(N)}),ue=te?Ra.endOfYear(ne):Dt.startOfYear(ne);return Ga(ue,l.value.maxDate,l.value.minDate,d.preventMinMaxNavigation,te)}),T=()=>Array.isArray(s.value)&&t.value.solo&&s.value[1],S=()=>{for(let N=0;N<t.value.count;N++)if(N===0)n.value[N]=n.value[0];else if(N===t.value.count-1&&T())n.value[N]={month:me.getMonth(s.value[1]),year:se.getYear(s.value[1])};else{const te=pe.set(L(),n.value[N-1]);n.value[N]={month:me.getMonth(te),year:se.getYear(Ea.addYears(te,1))}}},H=N=>{if(!N)return S();const te=pe.set(L(),n.value[N]);return n.value[0].year=se.getYear(za.subYears(te,t.value.count-1)),S()},z=(N,te)=>{const ne=bl.differenceInYears(te,N);return a.value.showLastInRange&&ne>1?te:N},q=N=>d.focusStartDate||t.value.solo?N[0]:N[1]?z(N[0],N[1]):N[0],M=()=>{if(s.value){const N=Array.isArray(s.value)?q(s.value):s.value;n.value[0]={month:me.getMonth(N),year:se.getYear(N)}}},I=()=>{M(),t.value.count&&S()};e.watch(s,(N,te)=>{d.isTextInputDate&&JSON.stringify(N??{})!==JSON.stringify(te??{})&&I()}),e.onMounted(()=>{I()});const J=(N,te)=>{n.value[te].year=N,p("update-month-year",{instance:te,year:N,month:n.value[te].month}),t.value.count&&!t.value.solo&&H(te)},V=e.computed(()=>N=>dt(f.value,te=>{var ne;const ue=m.value(N)===te.value,h=bt(te.value,ct(l.value.minDate),ct(l.value.maxDate))||((ne=b.value.years)==null?void 0:ne.includes(m.value(N))),x=fa(o.value,te.value);return{active:ue,disabled:h,highlighted:x}})),P=(N,te)=>{J(N,te),F(te)},ee=(N,te=!1)=>{if(!C.value(N,te)){const ne=te?m.value(N)+1:m.value(N)-1;J(ne,N)}},F=(N,te=!1,ne)=>{te||p("reset-flow"),ne!==void 0?y.value[N]=ne:y.value[N]=!y.value[N],y.value[N]?p("overlay-toggle",{open:!0,overlay:xe.year}):(p("overlay-closed"),p("overlay-toggle",{open:!1,overlay:xe.year}))};return{isDisabled:C,groupedYears:V,showYearPicker:y,selectYear:J,toggleYearPicker:F,handleYearSelect:P,handleYear:ee}},pn=(t,a)=>{const{defaultedMultiCalendars:o,defaultedAriaLabels:l,defaultedTransitions:n,defaultedConfig:s,defaultedRange:d,defaultedHighlight:b,propDates:m,defaultedTz:Y,defaultedFilters:p,defaultedMultiDates:f}=he(t),y=()=>{t.isTextInputDate&&I(se.getYear(L(t.startDate)),0)},{modelValue:C,year:T,month:S,calendars:H}=St(t,a,y),z=e.computed(()=>Ia(t.formatLocale,t.locale,t.monthNameFormat)),q=e.ref(null),{checkMinMaxRange:M}=Xe(t),{selectYear:I,groupedYears:J,showYearPicker:V,toggleYearPicker:P,handleYearSelect:ee,handleYear:F,isDisabled:N}=ll({modelValue:C,multiCalendars:o,range:d,highlight:b,calendars:H,year:T,propDates:m,month:S,filters:p,props:t,emit:a});e.onMounted(()=>{t.startDate&&(C.value&&t.focusStartDate||!C.value)&&I(se.getYear(L(t.startDate)),0)});const te=r=>r?{month:me.getMonth(r),year:se.getYear(r)}:{month:null,year:null},ne=()=>C.value?Array.isArray(C.value)?C.value.map(r=>te(r)):te(C.value):te(),ue=(r,_)=>{const O=H.value[r],i=ne();return Array.isArray(i)?i.some(Z=>Z.year===(O==null?void 0:O.year)&&Z.month===_):(O==null?void 0:O.year)===i.year&&_===i.month},h=(r,_,O)=>{var i,Z;const ie=ne();return Array.isArray(ie)?T.value(_)===((i=ie[O])==null?void 0:i.year)&&r===((Z=ie[O])==null?void 0:Z.month):!1},x=(r,_)=>{if(d.value.enabled){const O=ne();if(Array.isArray(C.value)&&Array.isArray(O)){const i=h(r,_,0)||h(r,_,1),Z=Le(Oe(L()),r,T.value(_));return Pt(C.value,q.value,Z)&&!i}return!1}return!1},g=e.computed(()=>r=>dt(z.value,_=>{var O;const i=ue(r,_.value),Z=bt(_.value,Ua(T.value(r),m.value.minDate),ja(T.value(r),m.value.maxDate))||El(m.value.disabledDates,T.value(r)).includes(_.value)||((O=p.value.months)==null?void 0:O.includes(_.value)),ie=x(_.value,r),we=Za(b.value,_.value,T.value(r));return{active:i,disabled:Z,isBetween:ie,highlighted:we}})),R=(r,_)=>Le(Oe(L()),r,T.value(_)),X=(r,_)=>{const O=C.value?C.value:Oe(new Date);C.value=Le(O,r,T.value(_)),a("auto-apply"),a("update-flow-step")},$=(r,_)=>{const O=R(r,_);d.value.fixedEnd||d.value.fixedStart?C.value=al(O,C,a,d):C.value?M(O,C.value)&&(C.value=ha(C,R(r,_),a)):C.value=[R(r,_)],e.nextTick().then(()=>{Vt(C.value,a,t.autoApply,t.modelAuto)})},W=(r,_)=>{ya(R(r,_),C,f.value.limit),a("auto-apply",!0)},oe=(r,_)=>(H.value[_].month=r,v(_,H.value[_].year,r),f.value.enabled?W(r,_):d.value.enabled?$(r,_):X(r,_)),c=(r,_)=>{I(r,_),v(_,r,null)},v=(r,_,O)=>{let i=O;if(!i&&i!==0){const Z=ne();i=Array.isArray(Z)?Z[r].month:Z.month}a("update-month-year",{instance:r,year:_,month:i})};return{groupedMonths:g,groupedYears:J,year:T,isDisabled:N,defaultedMultiCalendars:o,defaultedAriaLabels:l,defaultedTransitions:n,defaultedConfig:s,showYearPicker:V,modelValue:C,presetDate:(r,_)=>{tl({value:r,modelValue:C,range:d.value.enabled,timezone:_?void 0:Y.value.timezone}),a("auto-apply")},setHoverDate:(r,_)=>{q.value=R(r,_)},selectMonth:oe,selectYear:c,toggleYearPicker:P,handleYearSelect:ee,handleYear:F,getModelMonthYear:ne}},fn=e.defineComponent({compatConfig:{MODE:3},__name:"MonthPicker",props:{...Ye},emits:["update:internal-model-value","overlay-closed","reset-flow","range-start","range-end","auto-apply","update-month-year","update-flow-step","mount","invalid-fixed-range","overlay-toggle"],setup(t,{expose:a,emit:o}){const l=o,n=e.useSlots(),s=Ne(n,"yearMode"),d=t;e.onMounted(()=>{d.shadow||l("mount",null)});const{groupedMonths:b,groupedYears:m,year:Y,isDisabled:p,defaultedMultiCalendars:f,defaultedConfig:y,showYearPicker:C,modelValue:T,presetDate:S,setHoverDate:H,selectMonth:z,selectYear:q,toggleYearPicker:M,handleYearSelect:I,handleYear:J,getModelMonthYear:V}=pn(d,l);return a({getSidebarProps:()=>({modelValue:T,year:Y,getModelMonthYear:V,selectMonth:z,selectYear:q,handleYear:J}),presetDate:S,toggleYearPicker:P=>M(0,P)}),(P,ee)=>(e.openBlock(),e.createBlock($t,{"multi-calendars":e.unref(f).count,collapse:P.collapse,stretch:""},{default:e.withCtx(({instance:F})=>[P.$slots["top-extra"]?e.renderSlot(P.$slots,"top-extra",{key:0,value:P.internalModelValue}):e.createCommentVNode("",!0),P.$slots["month-year"]?e.renderSlot(P.$slots,"month-year",e.normalizeProps(e.mergeProps({key:1},{year:e.unref(Y),months:e.unref(b)(F),years:e.unref(m)(F),selectMonth:e.unref(z),selectYear:e.unref(q),instance:F}))):(e.openBlock(),e.createBlock(wt,{key:2,items:e.unref(b)(F),"arrow-navigation":P.arrowNavigation,"is-last":P.autoApply&&!e.unref(y).keepActionRow,"esc-close":P.escClose,height:e.unref(y).modeHeight,config:P.config,"no-overlay-focus":!!(P.noOverlayFocus||P.textInput),"use-relative":"",type:"month",onSelected:N=>e.unref(z)(N,F),onHoverValue:N=>e.unref(H)(N,F)},e.createSlots({header:e.withCtx(()=>[e.createVNode(el,e.mergeProps(P.$props,{items:e.unref(m)(F),instance:F,"show-year-picker":e.unref(C)[F],year:e.unref(Y)(F),"is-disabled":N=>e.unref(p)(F,N),onHandleYear:N=>e.unref(J)(F,N),onYearSelect:N=>e.unref(I)(N,F),onToggleYearPicker:N=>e.unref(M)(F,N==null?void 0:N.flow,N==null?void 0:N.show)}),e.createSlots({_:2},[e.renderList(e.unref(s),(N,te)=>({name:N,fn:e.withCtx(ne=>[e.renderSlot(P.$slots,N,e.normalizeProps(e.guardReactiveProps(ne)))])}))]),1040,["items","instance","show-year-picker","year","is-disabled","onHandleYear","onYearSelect","onToggleYearPicker"])]),_:2},[P.$slots["month-overlay-value"]?{name:"item",fn:e.withCtx(({item:N})=>[e.renderSlot(P.$slots,"month-overlay-value",{text:N.text,value:N.value})]),key:"0"}:void 0]),1032,["items","arrow-navigation","is-last","esc-close","height","config","no-overlay-focus","onSelected","onHoverValue"]))]),_:3},8,["multi-calendars","collapse"]))}}),yn=(t,a)=>{const o=()=>{t.isTextInputDate&&(p.value=se.getYear(L(t.startDate)))},{modelValue:l}=St(t,a,o),n=e.ref(null),{defaultedHighlight:s,defaultedMultiDates:d,defaultedFilters:b,defaultedRange:m,propDates:Y}=he(t),p=e.ref();e.onMounted(()=>{t.startDate&&(l.value&&t.focusStartDate||!l.value)&&(p.value=se.getYear(L(t.startDate)))});const f=S=>Array.isArray(l.value)?l.value.some(H=>se.getYear(H)===S):l.value?se.getYear(l.value)===S:!1,y=S=>m.value.enabled&&Array.isArray(l.value)?Pt(l.value,n.value,T(S)):!1,C=e.computed(()=>dt(ma(t.yearRange,t.locale,t.reverseYears),S=>{const H=f(S.value),z=bt(S.value,ct(Y.value.minDate),ct(Y.value.maxDate))||b.value.years.includes(S.value),q=y(S.value)&&!H,M=fa(s.value,S.value);return{active:H,disabled:z,isBetween:q,highlighted:M}})),T=S=>ze.setYear(Oe(Dt.startOfYear(new Date)),S);return{groupedYears:C,modelValue:l,focusYear:p,setHoverValue:S=>{n.value=ze.setYear(Oe(new Date),S)},selectYear:S=>{var H;if(a("update-month-year",{instance:0,year:S}),d.value.enabled)return l.value?Array.isArray(l.value)&&(((H=l.value)==null?void 0:H.map(z=>se.getYear(z))).includes(S)?l.value=l.value.filter(z=>se.getYear(z)!==S):l.value.push(ze.setYear(De(L()),S))):l.value=[ze.setYear(De(Dt.startOfYear(L())),S)],a("auto-apply",!0);m.value.enabled?(l.value=ha(l,T(S),a),e.nextTick().then(()=>{Vt(l.value,a,t.autoApply,t.modelAuto)})):(l.value=T(S),a("auto-apply"))}}},hn=e.defineComponent({compatConfig:{MODE:3},__name:"YearPicker",props:{...Ye},emits:["update:internal-model-value","reset-flow","range-start","range-end","auto-apply","update-month-year"],setup(t,{expose:a,emit:o}){const l=o,n=t,{groupedYears:s,modelValue:d,focusYear:b,selectYear:m,setHoverValue:Y}=yn(n,l),{defaultedConfig:p}=he(n);return a({getSidebarProps:()=>({modelValue:d,selectYear:m})}),(f,y)=>(e.openBlock(),e.createElementBlock("div",null,[f.$slots["top-extra"]?e.renderSlot(f.$slots,"top-extra",{key:0,value:f.internalModelValue}):e.createCommentVNode("",!0),f.$slots["month-year"]?e.renderSlot(f.$slots,"month-year",e.normalizeProps(e.mergeProps({key:1},{years:e.unref(s),selectYear:e.unref(m)}))):(e.openBlock(),e.createBlock(wt,{key:2,items:e.unref(s),"is-last":f.autoApply&&!e.unref(p).keepActionRow,height:e.unref(p).modeHeight,config:f.config,"no-overlay-focus":!!(f.noOverlayFocus||f.textInput),"focus-value":e.unref(b),type:"year","use-relative":"",onSelected:e.unref(m),onHoverValue:e.unref(Y)},e.createSlots({_:2},[f.$slots["year-overlay-value"]?{name:"item",fn:e.withCtx(({item:C})=>[e.renderSlot(f.$slots,"year-overlay-value",{text:C.text,value:C.value})]),key:"0"}:void 0]),1032,["items","is-last","height","config","no-overlay-focus","focus-value","onSelected","onHoverValue"]))]))}}),gn={key:0,class:"dp__time_input"},kn=["data-test","aria-label","onKeydown","onClick","onMousedown"],bn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),wn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),_n=["aria-label","disabled","data-test","onKeydown","onClick"],Sn=["data-test","aria-label","onKeydown","onClick","onMousedown"],Cn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),xn=e.createElementVNode("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),Bn={key:0},Mn=["aria-label"],An=e.defineComponent({compatConfig:{MODE:3},__name:"TimeInput",props:{hours:{type:Number,default:0},minutes:{type:Number,default:0},seconds:{type:Number,default:0},closeTimePickerBtn:{type:Object,default:null},order:{type:Number,default:0},disabledTimesConfig:{type:Function,default:null},validateTime:{type:Function,default:()=>!1},...Ye},emits:["set-hours","set-minutes","update:hours","update:minutes","update:seconds","reset-flow","mounted","overlay-closed","overlay-opened","am-pm-change"],setup(t,{expose:a,emit:o}){const l=o,n=t,{setTimePickerElements:s,setTimePickerBackRef:d}=Ze(),{defaultedAriaLabels:b,defaultedTransitions:m,defaultedFilters:Y,defaultedConfig:p,defaultedRange:f}=he(n),{transitionName:y,showTransition:C}=_t(m),T=e.reactive({hours:!1,minutes:!1,seconds:!1}),S=e.ref("AM"),H=e.ref(null),z=e.ref([]),q=e.ref(),M=e.ref(!1);e.onMounted(()=>{l("mounted")});const I=u=>pe.set(new Date,{hours:u.hours,minutes:u.minutes,seconds:n.enableSeconds?u.seconds:0,milliseconds:0}),J=e.computed(()=>u=>R(u,n[u])||P(u,n[u])),V=e.computed(()=>({hours:n.hours,minutes:n.minutes,seconds:n.seconds})),P=(u,E)=>f.value.enabled&&!f.value.disableTimeRangeValidation?!n.validateTime(u,E):!1,ee=(u,E)=>{if(f.value.enabled&&!f.value.disableTimeRangeValidation){const Q=E?+n[`${u}Increment`]:-+n[`${u}Increment`],D=n[u]+Q;return!n.validateTime(u,D)}return!1},F=e.computed(()=>u=>!c(+n[u]+ +n[`${u}Increment`],u)||ee(u,!0)),N=e.computed(()=>u=>!c(+n[u]-+n[`${u}Increment`],u)||ee(u,!1)),te=(u,E)=>$a.add(pe.set(L(),u),E),ne=(u,E)=>kl.sub(pe.set(L(),u),E),ue=e.computed(()=>({dp__time_col:!0,dp__time_col_block:!n.timePickerInline,dp__time_col_reg_block:!n.enableSeconds&&n.is24&&!n.timePickerInline,dp__time_col_reg_inline:!n.enableSeconds&&n.is24&&n.timePickerInline,dp__time_col_reg_with_button:!n.enableSeconds&&!n.is24,dp__time_col_sec:n.enableSeconds&&n.is24,dp__time_col_sec_with_button:n.enableSeconds&&!n.is24})),h=e.computed(()=>{const u=[{type:"hours"}];return n.enableMinutes&&u.push({type:"",separator:!0},{type:"minutes"}),n.enableSeconds&&u.push({type:"",separator:!0},{type:"seconds"}),u}),x=e.computed(()=>h.value.filter(u=>!u.separator)),g=e.computed(()=>u=>{if(u==="hours"){const E=Z(+n.hours);return{text:E<10?`0${E}`:`${E}`,value:E}}return{text:n[u]<10?`0${n[u]}`:`${n[u]}`,value:n[u]}}),R=(u,E)=>{var Q;if(!n.disabledTimesConfig)return!1;const D=n.disabledTimesConfig(n.order,u==="hours"?E:void 0);return D[u]?!!((Q=D[u])!=null&&Q.includes(E)):!0},X=(u,E)=>E!=="hours"||S.value==="AM"?u:u+12,$=u=>{const E=n.is24?24:12,Q=u==="hours"?E:60,D=+n[`${u}GridIncrement`],de=u==="hours"&&!n.is24?D:0,w=[];for(let U=de;U<Q;U+=D)w.push({value:n.is24?U:X(U,u),text:U<10?`0${U}`:`${U}`});return u==="hours"&&!n.is24&&w.unshift({value:S.value==="PM"?12:0,text:"12"}),dt(w,U=>({active:!1,disabled:Y.value.times[u].includes(U.value)||!c(U.value,u)||R(u,U.value)||P(u,U.value)}))},W=u=>u>=0?u:59,oe=u=>u>=0?u:23,c=(u,E)=>{const Q=n.minTime?I(Ut(n.minTime)):null,D=n.maxTime?I(Ut(n.maxTime)):null,de=I(Ut(V.value,E,E==="minutes"||E==="seconds"?W(u):oe(u)));return Q&&D?(gt.isBefore(de,D)||ut.isEqual(de,D))&&(it.isAfter(de,Q)||ut.isEqual(de,Q)):Q?it.isAfter(de,Q)||ut.isEqual(de,Q):D?gt.isBefore(de,D)||ut.isEqual(de,D):!0},v=u=>n[`no${u[0].toUpperCase()+u.slice(1)}Overlay`],r=u=>{v(u)||(T[u]=!T[u],T[u]?(M.value=!0,l("overlay-opened",u)):(M.value=!1,l("overlay-closed",u)))},_=u=>u==="hours"?He.getHours:u==="minutes"?We.getMinutes:st.getSeconds,O=()=>{q.value&&clearTimeout(q.value)},i=(u,E=!0,Q)=>{const D=E?te:ne,de=E?+n[`${u}Increment`]:-+n[`${u}Increment`];c(+n[u]+de,u)&&l(`update:${u}`,_(u)(D({[u]:+n[u]},{[u]:+n[`${u}Increment`]}))),!(Q!=null&&Q.keyboard)&&p.value.timeArrowHoldThreshold&&(q.value=setTimeout(()=>{i(u,E)},p.value.timeArrowHoldThreshold))},Z=u=>n.is24?u:(u>=12?S.value="PM":S.value="AM",Bl(u)),ie=()=>{S.value==="PM"?(S.value="AM",l("update:hours",n.hours-12)):(S.value="PM",l("update:hours",n.hours+12)),l("am-pm-change",S.value)},we=u=>{T[u]=!0},B=(u,E,Q)=>{if(u&&n.arrowNavigation){Array.isArray(z.value[E])?z.value[E][Q]=u:z.value[E]=[u];const D=z.value.reduce((de,w)=>w.map((U,le)=>[...de[le]||[],w[le]]),[]);d(n.closeTimePickerBtn),H.value&&(D[1]=D[1].concat(H.value)),s(D,n.order)}},j=(u,E)=>(r(u),l(`update:${u}`,E));return a({openChildCmp:we}),(u,E)=>{var Q;return u.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",gn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(D,de)=>{var w,U,le;return e.openBlock(),e.createElementBlock("div",{key:de,class:e.normalizeClass(ue.value)},[D.separator?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[M.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(":")],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("button",{ref_for:!0,ref:ce=>B(ce,de,0),type:"button",class:e.normalizeClass({dp__btn:!0,dp__inc_dec_button:!u.timePickerInline,dp__inc_dec_button_inline:u.timePickerInline,dp__tp_inline_btn_top:u.timePickerInline,dp__inc_dec_button_disabled:F.value(D.type),"dp--hidden-el":M.value}),"data-test":`${D.type}-time-inc-btn-${n.order}`,"aria-label":(w=e.unref(b))==null?void 0:w.incrementValue(D.type),tabindex:"0",onKeydown:ce=>e.unref(Ae)(ce,()=>i(D.type,!0,{keyboard:!0}),!0),onClick:ce=>e.unref(p).timeArrowHoldThreshold?void 0:i(D.type,!0),onMousedown:ce=>e.unref(p).timeArrowHoldThreshold?i(D.type,!0):void 0,onMouseup:O},[n.timePickerInline?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[u.$slots["tp-inline-arrow-up"]?e.renderSlot(u.$slots,"tp-inline-arrow-up",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[bn,wn],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[u.$slots["arrow-up"]?e.renderSlot(u.$slots,"arrow-up",{key:0}):e.createCommentVNode("",!0),u.$slots["arrow-up"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(sa),{key:1}))],64))],42,kn),e.createElementVNode("button",{ref_for:!0,ref:ce=>B(ce,de,1),type:"button","aria-label":`${g.value(D.type).text}-${(U=e.unref(b))==null?void 0:U.openTpOverlay(D.type)}`,class:e.normalizeClass({dp__time_display:!0,dp__time_display_block:!u.timePickerInline,dp__time_display_inline:u.timePickerInline,"dp--time-invalid":J.value(D.type),"dp--time-overlay-btn":!J.value(D.type),"dp--hidden-el":M.value}),disabled:v(D.type),tabindex:"0","data-test":`${D.type}-toggle-overlay-btn-${n.order}`,onKeydown:ce=>e.unref(Ae)(ce,()=>r(D.type),!0),onClick:ce=>r(D.type)},[u.$slots[D.type]?e.renderSlot(u.$slots,D.type,{key:0,text:g.value(D.type).text,value:g.value(D.type).value}):e.createCommentVNode("",!0),u.$slots[D.type]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(g.value(D.type).text),1)],64))],42,_n),e.createElementVNode("button",{ref_for:!0,ref:ce=>B(ce,de,2),type:"button",class:e.normalizeClass({dp__btn:!0,dp__inc_dec_button:!u.timePickerInline,dp__inc_dec_button_inline:u.timePickerInline,dp__tp_inline_btn_bottom:u.timePickerInline,dp__inc_dec_button_disabled:N.value(D.type),"dp--hidden-el":M.value}),"data-test":`${D.type}-time-dec-btn-${n.order}`,"aria-label":(le=e.unref(b))==null?void 0:le.decrementValue(D.type),tabindex:"0",onKeydown:ce=>e.unref(Ae)(ce,()=>i(D.type,!1,{keyboard:!0}),!0),onClick:ce=>e.unref(p).timeArrowHoldThreshold?void 0:i(D.type,!1),onMousedown:ce=>e.unref(p).timeArrowHoldThreshold?i(D.type,!1):void 0,onMouseup:O},[n.timePickerInline?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[u.$slots["tp-inline-arrow-down"]?e.renderSlot(u.$slots,"tp-inline-arrow-down",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[Cn,xn],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[u.$slots["arrow-down"]?e.renderSlot(u.$slots,"arrow-down",{key:0}):e.createCommentVNode("",!0),u.$slots["arrow-down"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(da),{key:1}))],64))],42,Sn)],64))],2)}),128)),u.is24?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Bn,[u.$slots["am-pm-button"]?e.renderSlot(u.$slots,"am-pm-button",{key:0,toggle:ie,value:S.value}):e.createCommentVNode("",!0),u.$slots["am-pm-button"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:1,ref_key:"amPmButton",ref:H,type:"button",class:"dp__pm_am_button",role:"button","aria-label":(Q=e.unref(b))==null?void 0:Q.amPmButton,tabindex:"0",onClick:ie,onKeydown:E[0]||(E[0]=D=>e.unref(Ae)(D,()=>ie(),!0))},e.toDisplayString(S.value),41,Mn))])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(D,de)=>(e.openBlock(),e.createBlock(e.Transition,{key:de,name:e.unref(y)(T[D.type]),css:e.unref(C)},{default:e.withCtx(()=>{var w,U;return[T[D.type]?(e.openBlock(),e.createBlock(wt,{key:0,items:$(D.type),"is-last":u.autoApply&&!e.unref(p).keepActionRow,"esc-close":u.escClose,type:D.type,"text-input":u.textInput,config:u.config,"arrow-navigation":u.arrowNavigation,"aria-labels":u.ariaLabels,"overlay-label":(U=(w=e.unref(b)).timeOverlay)==null?void 0:U.call(w,D.type),onSelected:le=>j(D.type,le),onToggle:le=>r(D.type),onResetFlow:E[1]||(E[1]=le=>u.$emit("reset-flow"))},e.createSlots({"button-icon":e.withCtx(()=>[u.$slots["clock-icon"]?e.renderSlot(u.$slots,"clock-icon",{key:0}):e.createCommentVNode("",!0),u.$slots["clock-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.timePickerInline?e.unref(mt):e.unref(ia)),{key:1}))]),_:2},[u.$slots[`${D.type}-overlay-value`]?{name:"item",fn:e.withCtx(({item:le})=>[e.renderSlot(u.$slots,`${D.type}-overlay-value`,{text:le.text,value:le.value})]),key:"0"}:void 0,u.$slots[`${D.type}-overlay-header`]?{name:"header",fn:e.withCtx(()=>[e.renderSlot(u.$slots,`${D.type}-overlay-header`,{toggle:()=>r(D.type)})]),key:"1"}:void 0]),1032,["items","is-last","esc-close","type","text-input","config","arrow-navigation","aria-labels","overlay-label","onSelected","onToggle"])):e.createCommentVNode("",!0)]}),_:2},1032,["name","css"]))),128))]))}}}),Dn={class:"dp--tp-wrap"},Tn=["aria-label","tabindex"],Pn=["role","aria-label","tabindex"],Nn=["aria-label"],nl=e.defineComponent({compatConfig:{MODE:3},__name:"TimePicker",props:{hours:{type:[Number,Array],default:0},minutes:{type:[Number,Array],default:0},seconds:{type:[Number,Array],default:0},disabledTimesConfig:{type:Function,default:null},validateTime:{type:Function,default:()=>!1},...Ye},emits:["update:hours","update:minutes","update:seconds","mount","reset-flow","overlay-opened","overlay-closed","am-pm-change"],setup(t,{expose:a,emit:o}){const l=o,n=t,{buildMatrix:s,setTimePicker:d}=Ze(),b=e.useSlots(),{defaultedTransitions:m,defaultedAriaLabels:Y,defaultedTextInput:p,defaultedConfig:f,defaultedRange:y}=he(n),{transitionName:C,showTransition:T}=_t(m),{hideNavigationButtons:S}=Rt(),H=e.ref(null),z=e.ref(null),q=e.ref([]),M=e.ref(null),I=e.ref(!1);e.onMounted(()=>{l("mount"),!n.timePicker&&n.arrowNavigation?s([_e(H.value)],"time"):d(!0,n.timePicker)});const J=e.computed(()=>y.value.enabled&&n.modelAuto?La(n.internalModelValue):!0),V=e.ref(!1),P=$=>({hours:Array.isArray(n.hours)?n.hours[$]:n.hours,minutes:Array.isArray(n.minutes)?n.minutes[$]:n.minutes,seconds:Array.isArray(n.seconds)?n.seconds[$]:n.seconds}),ee=e.computed(()=>{const $=[];if(y.value.enabled)for(let W=0;W<2;W++)$.push(P(W));else $.push(P(0));return $}),F=($,W=!1,oe="")=>{W||l("reset-flow"),V.value=$,l($?"overlay-opened":"overlay-closed",xe.time),n.arrowNavigation&&d($),e.nextTick(()=>{oe!==""&&q.value[0]&&q.value[0].openChildCmp(oe)})},N=e.computed(()=>({dp__btn:!0,dp__button:!0,dp__button_bottom:n.autoApply&&!f.value.keepActionRow})),te=Ne(b,"timePicker"),ne=($,W,oe)=>y.value.enabled?W===0?[$,ee.value[1][oe]]:[ee.value[0][oe],$]:$,ue=$=>{l("update:hours",$)},h=$=>{l("update:minutes",$)},x=$=>{l("update:seconds",$)},g=()=>{if(M.value&&!p.value.enabled&&!n.noOverlayFocus){const $=Ha(M.value);$&&$.focus({preventScroll:!0})}},R=$=>{I.value=!1,l("overlay-closed",$)},X=$=>{I.value=!0,l("overlay-opened",$)};return a({toggleTimePicker:F}),($,W)=>{var oe;return e.openBlock(),e.createElementBlock("div",Dn,[!$.timePicker&&!$.timePickerInline?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:0,ref_key:"openTimePickerBtn",ref:H,type:"button",class:e.normalizeClass({...N.value,"dp--hidden-el":V.value}),"aria-label":(oe=e.unref(Y))==null?void 0:oe.openTimePicker,tabindex:$.noOverlayFocus?void 0:0,"data-test":"open-time-picker-btn",onKeydown:W[0]||(W[0]=c=>e.unref(Ae)(c,()=>F(!0))),onClick:W[1]||(W[1]=c=>F(!0))},[$.$slots["clock-icon"]?e.renderSlot($.$slots,"clock-icon",{key:0}):e.createCommentVNode("",!0),$.$slots["clock-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ia),{key:1}))],42,Tn)),[[e.vShow,!e.unref(S)($.hideNavigation,"time")]]):e.createCommentVNode("",!0),e.createVNode(e.Transition,{name:e.unref(C)(V.value),css:e.unref(T)&&!$.timePickerInline},{default:e.withCtx(()=>{var c,v;return[V.value||$.timePicker||$.timePickerInline?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:M,role:$.timePickerInline?void 0:"dialog",class:e.normalizeClass({dp__overlay:!$.timePickerInline,"dp--overlay-absolute":!n.timePicker&&!$.timePickerInline,"dp--overlay-relative":n.timePicker}),style:e.normalizeStyle($.timePicker?{height:`${e.unref(f).modeHeight}px`}:void 0),"aria-label":(c=e.unref(Y))==null?void 0:c.timePicker,tabindex:$.timePickerInline?void 0:0},[e.createElementVNode("div",{class:e.normalizeClass($.timePickerInline?"dp__time_picker_inline_container":"dp__overlay_container dp__container_flex dp__time_picker_overlay_container"),style:{display:"flex"}},[$.$slots["time-picker-overlay"]?e.renderSlot($.$slots,"time-picker-overlay",{key:0,hours:t.hours,minutes:t.minutes,seconds:t.seconds,setHours:ue,setMinutes:h,setSeconds:x}):e.createCommentVNode("",!0),$.$slots["time-picker-overlay"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass($.timePickerInline?"dp__flex":"dp__overlay_row dp__flex_row")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ee.value,(r,_)=>e.withDirectives((e.openBlock(),e.createBlock(An,e.mergeProps({key:_,ref_for:!0},{...$.$props,order:_,hours:r.hours,minutes:r.minutes,seconds:r.seconds,closeTimePickerBtn:z.value,disabledTimesConfig:t.disabledTimesConfig,disabled:_===0?e.unref(y).fixedStart:e.unref(y).fixedEnd},{ref_for:!0,ref_key:"timeInputRefs",ref:q,"validate-time":(O,i)=>t.validateTime(O,ne(i,_,O)),"onUpdate:hours":O=>ue(ne(O,_,"hours")),"onUpdate:minutes":O=>h(ne(O,_,"minutes")),"onUpdate:seconds":O=>x(ne(O,_,"seconds")),onMounted:g,onOverlayClosed:R,onOverlayOpened:X,onAmPmChange:W[2]||(W[2]=O=>$.$emit("am-pm-change",O))}),e.createSlots({_:2},[e.renderList(e.unref(te),(O,i)=>({name:O,fn:e.withCtx(Z=>[e.renderSlot($.$slots,O,e.mergeProps({ref_for:!0},Z))])}))]),1040,["validate-time","onUpdate:hours","onUpdate:minutes","onUpdate:seconds"])),[[e.vShow,_===0?!0:J.value]])),128))],2)),!$.timePicker&&!$.timePickerInline?e.withDirectives((e.openBlock(),e.createElementBlock("button",{key:2,ref_key:"closeTimePickerBtn",ref:z,type:"button",class:e.normalizeClass({...N.value,"dp--hidden-el":I.value}),"aria-label":(v=e.unref(Y))==null?void 0:v.closeTimePicker,tabindex:"0",onKeydown:W[3]||(W[3]=r=>e.unref(Ae)(r,()=>F(!1))),onClick:W[4]||(W[4]=r=>F(!1))},[$.$slots["calendar-icon"]?e.renderSlot($.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),$.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(mt),{key:1}))],42,Nn)),[[e.vShow,!e.unref(S)($.hideNavigation,"time")]]):e.createCommentVNode("",!0)],2)],14,Pn)):e.createCommentVNode("",!0)]}),_:3},8,["name","css"])])}}}),rl=(t,a,o,l)=>{const{defaultedRange:n}=he(t),s=(M,I)=>Array.isArray(a[M])?a[M][I]:a[M],d=M=>t.enableSeconds?Array.isArray(a.seconds)?a.seconds[M]:a.seconds:0,b=(M,I)=>M?I!==void 0?Ge(M,s("hours",I),s("minutes",I),d(I)):Ge(M,a.hours,a.minutes,d()):Oa.setSeconds(L(),d(I)),m=(M,I)=>{a[M]=I},Y=e.computed(()=>t.modelAuto&&n.value.enabled?Array.isArray(o.value)?o.value.length>1:!1:n.value.enabled),p=(M,I)=>{const J=Object.fromEntries(Object.keys(a).map(V=>V===M?[V,I]:[V,a[V]].slice()));if(Y.value&&!n.value.disableTimeRangeValidation){const V=ee=>o.value?Ge(o.value[ee],J.hours[ee],J.minutes[ee],J.seconds[ee]):null,P=ee=>Ya.setMilliseconds(o.value[ee],0);return!(ve(V(0),V(1))&&(it.isAfter(V(0),P(1))||gt.isBefore(V(1),P(0))))}return!0},f=(M,I)=>{p(M,I)&&(m(M,I),l&&l())},y=M=>{f("hours",M)},C=M=>{f("minutes",M)},T=M=>{f("seconds",M)},S=(M,I,J,V)=>{I&&y(M),!I&&!J&&C(M),J&&T(M),o.value&&V(o.value)},H=M=>{if(M){const I=Array.isArray(M),J=I?[+M[0].hours,+M[1].hours]:+M.hours,V=I?[+M[0].minutes,+M[1].minutes]:+M.minutes,P=I?[+M[0].seconds,+M[1].seconds]:+M.seconds;m("hours",J),m("minutes",V),t.enableSeconds&&m("seconds",P)}},z=(M,I)=>{const J={hours:Array.isArray(a.hours)?a.hours[M]:a.hours,disabledArr:[]};return(I||I===0)&&(J.hours=I),Array.isArray(t.disabledTimes)&&(J.disabledArr=n.value.enabled&&Array.isArray(t.disabledTimes[M])?t.disabledTimes[M]:t.disabledTimes),J},q=e.computed(()=>(M,I)=>{var J;if(Array.isArray(t.disabledTimes)){const{disabledArr:V,hours:P}=z(M,I),ee=V.filter(F=>+F.hours===P);return((J=ee[0])==null?void 0:J.minutes)==="*"?{hours:[P],minutes:void 0,seconds:void 0}:{hours:[],minutes:(ee==null?void 0:ee.map(F=>+F.minutes))??[],seconds:(ee==null?void 0:ee.map(F=>F.seconds?+F.seconds:void 0))??[]}}return{hours:[],minutes:[],seconds:[]}});return{setTime:m,updateHours:y,updateMinutes:C,updateSeconds:T,getSetDateTime:b,updateTimeValues:S,getSecondsValue:d,assignStartTime:H,validateTime:p,disabledTimesConfig:q}},$n=(t,a)=>{const o=()=>{t.isTextInputDate&&I()},{modelValue:l,time:n}=St(t,a,o),{defaultedStartTime:s,defaultedRange:d,defaultedTz:b}=he(t),{updateTimeValues:m,getSetDateTime:Y,setTime:p,assignStartTime:f,disabledTimesConfig:y,validateTime:C}=rl(t,n,l,T);function T(){a("update-flow-step")}const S=V=>{const{hours:P,minutes:ee,seconds:F}=V;return{hours:+P,minutes:+ee,seconds:F?+F:0}},H=()=>{if(t.startTime){if(Array.isArray(t.startTime)){const P=S(t.startTime[0]),ee=S(t.startTime[1]);return[pe.set(L(),P),pe.set(L(),ee)]}const V=S(t.startTime);return pe.set(L(),V)}return d.value.enabled?[null,null]:null},z=()=>{if(d.value.enabled){const[V,P]=H();l.value=[Te(Y(V,0),b.value.timezone),Te(Y(P,1),b.value.timezone)]}else l.value=Te(Y(H()),b.value.timezone)},q=V=>Array.isArray(V)?[nt(L(V[0])),nt(L(V[1]))]:[nt(V??L())],M=(V,P,ee)=>{p("hours",V),p("minutes",P),p("seconds",t.enableSeconds?ee:0)},I=()=>{const[V,P]=q(l.value);return d.value.enabled?M([V.hours,P.hours],[V.minutes,P.minutes],[V.seconds,P.seconds]):M(V.hours,V.minutes,V.seconds)};e.onMounted(()=>{if(!t.shadow)return f(s.value),l.value?I():z()});const J=()=>{Array.isArray(l.value)?l.value=l.value.map((V,P)=>V&&Y(V,P)):l.value=Y(l.value),a("time-update")};return{modelValue:l,time:n,disabledTimesConfig:y,updateTime:(V,P=!0,ee=!1)=>{m(V,P,ee,J)},validateTime:C}},Vn=e.defineComponent({compatConfig:{MODE:3},__name:"TimePickerSolo",props:{...Ye},emits:["update:internal-model-value","time-update","am-pm-change","mount","reset-flow","update-flow-step","overlay-toggle"],setup(t,{expose:a,emit:o}){const l=o,n=t,s=e.useSlots(),d=Ne(s,"timePicker"),b=e.ref(null),{time:m,modelValue:Y,disabledTimesConfig:p,updateTime:f,validateTime:y}=$n(n,l);return e.onMounted(()=>{n.shadow||l("mount",null)}),a({getSidebarProps:()=>({modelValue:Y,time:m,updateTime:f}),toggleTimePicker:(C,T=!1,S="")=>{var H;(H=b.value)==null||H.toggleTimePicker(C,T,S)}}),(C,T)=>(e.openBlock(),e.createBlock($t,{"multi-calendars":0,stretch:""},{default:e.withCtx(()=>[e.createVNode(nl,e.mergeProps({ref_key:"tpRef",ref:b},C.$props,{hours:e.unref(m).hours,minutes:e.unref(m).minutes,seconds:e.unref(m).seconds,"internal-model-value":C.internalModelValue,"disabled-times-config":e.unref(p),"validate-time":e.unref(y),"onUpdate:hours":T[0]||(T[0]=S=>e.unref(f)(S)),"onUpdate:minutes":T[1]||(T[1]=S=>e.unref(f)(S,!1)),"onUpdate:seconds":T[2]||(T[2]=S=>e.unref(f)(S,!1,!0)),onAmPmChange:T[3]||(T[3]=S=>C.$emit("am-pm-change",S)),onResetFlow:T[4]||(T[4]=S=>C.$emit("reset-flow")),onOverlayClosed:T[5]||(T[5]=S=>C.$emit("overlay-toggle",{open:!1,overlay:S})),onOverlayOpened:T[6]||(T[6]=S=>C.$emit("overlay-toggle",{open:!0,overlay:S}))}),e.createSlots({_:2},[e.renderList(e.unref(d),(S,H)=>({name:S,fn:e.withCtx(z=>[e.renderSlot(C.$slots,S,e.normalizeProps(e.guardReactiveProps(z)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config","validate-time"])]),_:3}))}}),Rn={class:"dp--header-wrap"},On={key:0,class:"dp__month_year_wrap"},Yn={key:0},En={class:"dp__month_year_wrap"},zn=["data-dp-element","aria-label","data-test","onClick","onKeydown"],Fn=e.defineComponent({compatConfig:{MODE:3},__name:"DpHeader",props:{month:{type:Number,default:0},year:{type:Number,default:0},instance:{type:Number,default:0},years:{type:Array,default:()=>[]},months:{type:Array,default:()=>[]},...Ye},emits:["update-month-year","mount","reset-flow","overlay-closed","overlay-opened"],setup(t,{expose:a,emit:o}){const l=o,n=t,{defaultedTransitions:s,defaultedAriaLabels:d,defaultedMultiCalendars:b,defaultedFilters:m,defaultedConfig:Y,defaultedHighlight:p,propDates:f,defaultedUI:y}=he(n),{transitionName:C,showTransition:T}=_t(s),{buildMatrix:S}=Ze(),{handleMonthYearChange:H,isDisabled:z,updateMonthYear:q}=ln(n,l),{showLeftIcon:M,showRightIcon:I}=Rt(),J=e.ref(!1),V=e.ref(!1),P=e.ref(!1),ee=e.ref([null,null,null,null]);e.onMounted(()=>{l("mount")});const F=v=>({get:()=>n[v],set:r=>{const _=v===Re.month?Re.year:Re.month;l("update-month-year",{[v]:r,[_]:n[_]}),v===Re.month?R(!0):X(!0)}}),N=e.computed(F(Re.month)),te=e.computed(F(Re.year)),ne=e.computed(()=>v=>({month:n.month,year:n.year,items:v===Re.month?n.months:n.years,instance:n.instance,updateMonthYear:q,toggle:v===Re.month?R:X})),ue=e.computed(()=>n.months.find(r=>r.value===n.month)||{text:"",value:0}),h=e.computed(()=>dt(n.months,v=>{const r=n.month===v.value,_=bt(v.value,Ua(n.year,f.value.minDate),ja(n.year,f.value.maxDate))||m.value.months.includes(v.value),O=Za(p.value,v.value,n.year);return{active:r,disabled:_,highlighted:O}})),x=e.computed(()=>dt(n.years,v=>{const r=n.year===v.value,_=bt(v.value,ct(f.value.minDate),ct(f.value.maxDate))||m.value.years.includes(v.value),O=fa(p.value,v.value);return{active:r,disabled:_,highlighted:O}})),g=(v,r,_)=>{_!==void 0?v.value=_:v.value=!v.value,v.value?(P.value=!0,l("overlay-opened",r)):(P.value=!1,l("overlay-closed",r))},R=(v=!1,r)=>{$(v),g(J,xe.month,r)},X=(v=!1,r)=>{$(v),g(V,xe.year,r)},$=v=>{v||l("reset-flow")},W=(v,r)=>{n.arrowNavigation&&(ee.value[r]=_e(v),S(ee.value,"monthYear"))},oe=e.computed(()=>{var v,r,_,O,i,Z;return[{type:Re.month,index:1,toggle:R,modelValue:N.value,updateModelValue:ie=>N.value=ie,text:ue.value.text,showSelectionGrid:J.value,items:h.value,ariaLabel:(v=d.value)==null?void 0:v.openMonthsOverlay,overlayLabel:((_=(r=d.value).monthPicker)==null?void 0:_.call(r,!0))??void 0},{type:Re.year,index:2,toggle:X,modelValue:te.value,updateModelValue:ie=>te.value=ie,text:qa(n.year,n.locale),showSelectionGrid:V.value,items:x.value,ariaLabel:(O=d.value)==null?void 0:O.openYearsOverlay,overlayLabel:((Z=(i=d.value).yearPicker)==null?void 0:Z.call(i,!0))??void 0}]}),c=e.computed(()=>n.disableYearSelect?[oe.value[0]]:n.yearFirst?[...oe.value].reverse():oe.value);return a({toggleMonthPicker:R,toggleYearPicker:X,handleMonthYearChange:H}),(v,r)=>{var _,O,i,Z,ie,we;return e.openBlock(),e.createElementBlock("div",Rn,[v.$slots["month-year"]?(e.openBlock(),e.createElementBlock("div",On,[e.renderSlot(v.$slots,"month-year",e.normalizeProps(e.guardReactiveProps({month:t.month,year:t.year,months:t.months,years:t.years,updateMonthYear:e.unref(q),handleMonthYearChange:e.unref(H),instance:t.instance})))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[v.$slots["top-extra"]?(e.openBlock(),e.createElementBlock("div",Yn,[e.renderSlot(v.$slots,"top-extra",{value:v.internalModelValue})])):e.createCommentVNode("",!0),e.createElementVNode("div",En,[e.unref(M)(e.unref(b),t.instance)&&!v.vertical?(e.openBlock(),e.createBlock(ht,{key:0,"aria-label":(_=e.unref(d))==null?void 0:_.prevMonth,disabled:e.unref(z)(!1),class:e.normalizeClass((O=e.unref(y))==null?void 0:O.navBtnPrev),"el-name":"action-prev",onActivate:r[0]||(r[0]=B=>e.unref(H)(!1,!0)),onSetRef:r[1]||(r[1]=B=>W(B,0))},{default:e.withCtx(()=>[v.$slots["arrow-left"]?e.renderSlot(v.$slots,"arrow-left",{key:0}):e.createCommentVNode("",!0),v.$slots["arrow-left"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(oa),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["dp__month_year_wrap",{dp__year_disable_select:v.disableYearSelect}])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(B,j)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:B.type},[e.createElementVNode("button",{ref_for:!0,ref:u=>W(u,j+1),type:"button","data-dp-element":`overlay-${B.type}`,class:e.normalizeClass(["dp__btn dp__month_year_select",{"dp--hidden-el":P.value}]),"aria-label":`${B.text}-${B.ariaLabel}`,"data-test":`${B.type}-toggle-overlay-${t.instance}`,onClick:B.toggle,onKeydown:u=>e.unref(Ae)(u,()=>B.toggle(),!0)},[v.$slots[B.type]?e.renderSlot(v.$slots,B.type,{key:0,text:B.text,value:n[B.type]}):e.createCommentVNode("",!0),v.$slots[B.type]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(B.text),1)],64))],42,zn),e.createVNode(e.Transition,{name:e.unref(C)(B.showSelectionGrid),css:e.unref(T)},{default:e.withCtx(()=>[B.showSelectionGrid?(e.openBlock(),e.createBlock(wt,{key:0,items:B.items,"arrow-navigation":v.arrowNavigation,"hide-navigation":v.hideNavigation,"is-last":v.autoApply&&!e.unref(Y).keepActionRow,"skip-button-ref":!1,config:v.config,type:B.type,"header-refs":[],"esc-close":v.escClose,"menu-wrap-ref":v.menuWrapRef,"text-input":v.textInput,"aria-labels":v.ariaLabels,"overlay-label":B.overlayLabel,onSelected:B.updateModelValue,onToggle:B.toggle},e.createSlots({"button-icon":e.withCtx(()=>[v.$slots["calendar-icon"]?e.renderSlot(v.$slots,"calendar-icon",{key:0}):e.createCommentVNode("",!0),v.$slots["calendar-icon"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(mt),{key:1}))]),_:2},[v.$slots[`${B.type}-overlay-value`]?{name:"item",fn:e.withCtx(({item:u})=>[e.renderSlot(v.$slots,`${B.type}-overlay-value`,{text:u.text,value:u.value})]),key:"0"}:void 0,v.$slots[`${B.type}-overlay`]?{name:"overlay",fn:e.withCtx(()=>[e.renderSlot(v.$slots,`${B.type}-overlay`,e.mergeProps({ref_for:!0},ne.value(B.type)))]),key:"1"}:void 0,v.$slots[`${B.type}-overlay-header`]?{name:"header",fn:e.withCtx(()=>[e.renderSlot(v.$slots,`${B.type}-overlay-header`,{toggle:B.toggle})]),key:"2"}:void 0]),1032,["items","arrow-navigation","hide-navigation","is-last","config","type","esc-close","menu-wrap-ref","text-input","aria-labels","overlay-label","onSelected","onToggle"])):e.createCommentVNode("",!0)]),_:2},1032,["name","css"])],64))),128))],2),e.unref(M)(e.unref(b),t.instance)&&v.vertical?(e.openBlock(),e.createBlock(ht,{key:1,"aria-label":(i=e.unref(d))==null?void 0:i.prevMonth,"el-name":"action-prev",disabled:e.unref(z)(!1),class:e.normalizeClass((Z=e.unref(y))==null?void 0:Z.navBtnPrev),onActivate:r[2]||(r[2]=B=>e.unref(H)(!1,!0))},{default:e.withCtx(()=>[v.$slots["arrow-up"]?e.renderSlot(v.$slots,"arrow-up",{key:0}):e.createCommentVNode("",!0),v.$slots["arrow-up"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(sa),{key:1}))]),_:3},8,["aria-label","disabled","class"])):e.createCommentVNode("",!0),e.unref(I)(e.unref(b),t.instance)?(e.openBlock(),e.createBlock(ht,{key:2,ref:"rightIcon","el-name":"action-next",disabled:e.unref(z)(!0),"aria-label":(ie=e.unref(d))==null?void 0:ie.nextMonth,class:e.normalizeClass((we=e.unref(y))==null?void 0:we.navBtnNext),onActivate:r[3]||(r[3]=B=>e.unref(H)(!0,!0)),onSetRef:r[4]||(r[4]=B=>W(B,v.disableYearSelect?2:3))},{default:e.withCtx(()=>[v.$slots[v.vertical?"arrow-down":"arrow-right"]?e.renderSlot(v.$slots,v.vertical?"arrow-down":"arrow-right",{key:0}):e.createCommentVNode("",!0),v.$slots[v.vertical?"arrow-down":"arrow-right"]?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(v.vertical?e.unref(da):e.unref(ua)),{key:1}))]),_:3},8,["disabled","aria-label","class"])):e.createCommentVNode("",!0)])],64))])}}}),In={class:"dp__calendar_header",role:"row"},Ln={key:0,class:"dp__calendar_header_item",role:"gridcell"},Hn=["aria-label"],qn=e.createElementVNode("div",{class:"dp__calendar_header_separator"},null,-1),Un={key:0,class:"dp__calendar_item dp__week_num",role:"gridcell"},jn={class:"dp__cell_inner"},Qn=["id","aria-pressed","aria-disabled","aria-label","data-test","onClick","onTouchend","onKeydown","onMouseenter","onMouseleave","onMousedown"],Kn=e.defineComponent({compatConfig:{MODE:3},__name:"DpCalendar",props:{mappedDates:{type:Array,default:()=>[]},instance:{type:Number,default:0},month:{type:Number,default:0},year:{type:Number,default:0},...Ye},emits:["select-date","set-hover-date","handle-scroll","mount","handle-swipe","handle-space","tooltip-open","tooltip-close"],setup(t,{expose:a,emit:o}){const l=o,n=t,{buildMultiLevelMatrix:s}=Ze(),{defaultedTransitions:d,defaultedConfig:b,defaultedAriaLabels:m,defaultedMultiCalendars:Y,defaultedWeekNumbers:p,defaultedMultiDates:f,defaultedUI:y}=he(n),C=e.ref(null),T=e.ref({bottom:"",left:"",transform:""}),S=e.ref([]),H=e.ref(null),z=e.ref(!0),q=e.ref(""),M=e.ref({startX:0,endX:0,startY:0,endY:0}),I=e.ref([]),J=e.ref({left:"50%"}),V=e.ref(!1),P=e.computed(()=>n.calendar?n.calendar(n.mappedDates):n.mappedDates),ee=e.computed(()=>n.dayNames?Array.isArray(n.dayNames)?n.dayNames:n.dayNames(n.locale,+n.weekStart):xl(n.formatLocale,n.locale,+n.weekStart));e.onMounted(()=>{l("mount",{cmp:"calendar",refs:S}),b.value.noSwipe||H.value&&(H.value.addEventListener("touchstart",W,{passive:!1}),H.value.addEventListener("touchend",oe,{passive:!1}),H.value.addEventListener("touchmove",c,{passive:!1})),n.monthChangeOnScroll&&H.value&&H.value.addEventListener("wheel",_,{passive:!1})});const F=B=>B?n.vertical?"vNext":"next":n.vertical?"vPrevious":"previous",N=(B,j)=>{if(n.transitions){const u=De(Le(L(),n.month,n.year));q.value=be(De(Le(L(),B,j)),u)?d.value[F(!0)]:d.value[F(!1)],z.value=!1,e.nextTick(()=>{z.value=!0})}},te=e.computed(()=>({...y.value.calendar??{}})),ne=e.computed(()=>B=>{const j=Ml(B);return{dp__marker_dot:j.type==="dot",dp__marker_line:j.type==="line"}}),ue=e.computed(()=>B=>ve(B,C.value)),h=e.computed(()=>({dp__calendar:!0,dp__calendar_next:Y.value.count>0&&n.instance!==0})),x=e.computed(()=>B=>n.hideOffsetDates?B.current:!0),g=async(B,j)=>{const{width:u,height:E}=B.getBoundingClientRect();C.value=j.value;let Q={left:`${u/2}px`},D=-50;if(await e.nextTick(),I.value[0]){const{left:de,width:w}=I.value[0].getBoundingClientRect();de<0&&(Q={left:"0"},D=0,J.value.left=`${u/2}px`),window.innerWidth<de+w&&(Q={right:"0"},D=0,J.value.left=`${w-u/2}px`)}T.value={bottom:`${E}px`,...Q,transform:`translateX(${D}%)`}},R=async(B,j,u)=>{var E,Q,D;const de=_e(S.value[j][u]);de&&((E=B.marker)!=null&&E.customPosition&&(D=(Q=B.marker)==null?void 0:Q.tooltip)!=null&&D.length?T.value=B.marker.customPosition(de):await g(de,B),l("tooltip-open",B.marker))},X=async(B,j,u)=>{var E,Q;if(V.value&&f.value.enabled&&f.value.dragSelect)return l("select-date",B);l("set-hover-date",B),(Q=(E=B.marker)==null?void 0:E.tooltip)!=null&&Q.length&&await R(B,j,u)},$=B=>{C.value&&(C.value=null,T.value=JSON.parse(JSON.stringify({bottom:"",left:"",transform:""})),l("tooltip-close",B.marker))},W=B=>{M.value.startX=B.changedTouches[0].screenX,M.value.startY=B.changedTouches[0].screenY},oe=B=>{M.value.endX=B.changedTouches[0].screenX,M.value.endY=B.changedTouches[0].screenY,v()},c=B=>{n.vertical&&!n.inline&&B.preventDefault()},v=()=>{const B=n.vertical?"Y":"X";Math.abs(M.value[`start${B}`]-M.value[`end${B}`])>10&&l("handle-swipe",M.value[`start${B}`]>M.value[`end${B}`]?"right":"left")},r=(B,j,u)=>{B&&(Array.isArray(S.value[j])?S.value[j][u]=B:S.value[j]=[B]),n.arrowNavigation&&s(S.value,"calendar")},_=B=>{n.monthChangeOnScroll&&(B.preventDefault(),l("handle-scroll",B))},O=B=>p.value.type==="local"?yl.getWeek(B.value,{weekStartsOn:+n.weekStart}):p.value.type==="iso"?hl.getISOWeek(B.value):typeof p.value.type=="function"?p.value.type(B.value):"",i=B=>{const j=B[0];return p.value.hideOnOffsetDates?B.some(u=>u.current)?O(j):"":O(j)},Z=(B,j,u=!0)=>{u&&xa()||!u&&!xa()||f.value.enabled||(Ke(B,b.value),l("select-date",j))},ie=B=>{Ke(B,b.value)},we=B=>{f.value.enabled&&f.value.dragSelect?(V.value=!0,l("select-date",B)):f.value.enabled&&l("select-date",B)};return a({triggerTransition:N}),(B,j)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(h.value)},[e.createElementVNode("div",{ref_key:"calendarWrapRef",ref:H,class:e.normalizeClass(te.value),role:"grid"},[e.createElementVNode("div",In,[B.weekNumbers?(e.openBlock(),e.createElementBlock("div",Ln,e.toDisplayString(B.weekNumName),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ee.value,(u,E)=>{var Q,D;return e.openBlock(),e.createElementBlock("div",{key:E,class:"dp__calendar_header_item",role:"gridcell","data-test":"calendar-header","aria-label":(D=(Q=e.unref(m))==null?void 0:Q.weekDay)==null?void 0:D.call(Q,E)},[B.$slots["calendar-header"]?e.renderSlot(B.$slots,"calendar-header",{key:0,day:u,index:E}):e.createCommentVNode("",!0),B.$slots["calendar-header"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(u),1)],64))],8,Hn)}),128))]),qn,e.createVNode(e.Transition,{name:q.value,css:!!B.transitions},{default:e.withCtx(()=>[z.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__calendar",role:"rowgroup",onMouseleave:j[1]||(j[1]=u=>V.value=!1)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(P.value,(u,E)=>(e.openBlock(),e.createElementBlock("div",{key:E,class:"dp__calendar_row",role:"row"},[B.weekNumbers?(e.openBlock(),e.createElementBlock("div",Un,[e.createElementVNode("div",jn,e.toDisplayString(i(u.days)),1)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.days,(Q,D)=>{var de,w,U;return e.openBlock(),e.createElementBlock("div",{id:e.unref(Xa)(Q.value),ref_for:!0,ref:le=>r(le,E,D),key:D+E,role:"gridcell",class:"dp__calendar_item","aria-pressed":(Q.classData.dp__active_date||Q.classData.dp__range_start||Q.classData.dp__range_start)??void 0,"aria-disabled":Q.classData.dp__cell_disabled||void 0,"aria-label":(w=(de=e.unref(m))==null?void 0:de.day)==null?void 0:w.call(de,Q),tabindex:"0","data-test":Q.value,onClick:e.withModifiers(le=>Z(le,Q),["prevent"]),onTouchend:le=>Z(le,Q,!1),onKeydown:le=>e.unref(Ae)(le,()=>B.$emit("select-date",Q)),onMouseenter:le=>X(Q,E,D),onMouseleave:le=>$(Q),onMousedown:le=>we(Q),onMouseup:j[0]||(j[0]=le=>V.value=!1)},[e.createElementVNode("div",{class:e.normalizeClass(["dp__cell_inner",Q.classData])},[B.$slots.day&&x.value(Q)?e.renderSlot(B.$slots,"day",{key:0,day:+Q.text,date:Q.value}):e.createCommentVNode("",!0),B.$slots.day?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(Q.text),1)],64)),Q.marker&&x.value(Q)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[B.$slots.marker?e.renderSlot(B.$slots,"marker",{key:0,marker:Q.marker,day:+Q.text,date:Q.value}):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(ne.value(Q.marker)),style:e.normalizeStyle(Q.marker.color?{backgroundColor:Q.marker.color}:{})},null,6))],64)):e.createCommentVNode("",!0),ue.value(Q.value)?(e.openBlock(),e.createElementBlock("div",{key:3,ref_for:!0,ref_key:"activeTooltip",ref:I,class:"dp__marker_tooltip",style:e.normalizeStyle(T.value)},[(U=Q.marker)!=null&&U.tooltip?(e.openBlock(),e.createElementBlock("div",{key:0,class:"dp__tooltip_content",onClick:ie},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Q.marker.tooltip,(le,ce)=>(e.openBlock(),e.createElementBlock("div",{key:ce,class:"dp__tooltip_text"},[B.$slots["marker-tooltip"]?e.renderSlot(B.$slots,"marker-tooltip",{key:0,tooltip:le,day:Q.value}):e.createCommentVNode("",!0),B.$slots["marker-tooltip"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",{class:"dp__tooltip_mark",style:e.normalizeStyle(le.color?{backgroundColor:le.color}:{})},null,4),e.createElementVNode("div",null,e.toDisplayString(le.text),1)],64))]))),128)),e.createElementVNode("div",{class:"dp__arrow_bottom_tp",style:e.normalizeStyle(J.value)},null,4)])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)],2)],40,Qn)}),128))]))),128))],32)):e.createCommentVNode("",!0)]),_:3},8,["name","css"])],2)],2))}}),Ta=t=>Array.isArray(t),Gn=(t,a,o,l)=>{const n=e.ref([]),s=e.ref(new Date),d=e.ref(),b=()=>W(t.isTextInputDate),{modelValue:m,calendars:Y,time:p,today:f}=St(t,a,b),{defaultedMultiCalendars:y,defaultedStartTime:C,defaultedRange:T,defaultedConfig:S,defaultedTz:H,propDates:z,defaultedMultiDates:q}=he(t),{validateMonthYearInRange:M,isDisabled:I,isDateRangeAllowed:J,checkMinMaxRange:V}=Xe(t),{updateTimeValues:P,getSetDateTime:ee,setTime:F,assignStartTime:N,validateTime:te,disabledTimesConfig:ne}=rl(t,p,m,l),ue=e.computed(()=>k=>Y.value[k]?Y.value[k].month:0),h=e.computed(()=>k=>Y.value[k]?Y.value[k].year:0),x=k=>!S.value.keepViewOnOffsetClick||k?!0:!d.value,g=(k,G,A,K=!1)=>{var ae,Be;x(K)&&(Y.value[k]||(Y.value[k]={month:0,year:0}),Y.value[k].month=Ca(G)?(ae=Y.value[k])==null?void 0:ae.month:G,Y.value[k].year=Ca(A)?(Be=Y.value[k])==null?void 0:Be.year:A)},R=()=>{t.autoApply&&a("select-date")};e.onMounted(()=>{t.shadow||(m.value||(B(),C.value&&N(C.value)),W(!0),t.focusStartDate&&t.startDate&&B())});const X=e.computed(()=>{var k;return(k=t.flow)!=null&&k.length&&!t.partialFlow?t.flowStep===t.flow.length:!0}),$=()=>{t.autoApply&&X.value&&a("auto-apply",t.partialFlow?t.flowStep!==t.flow.length:!1)},W=(k=!1)=>{if(m.value)return Array.isArray(m.value)?(n.value=m.value,i(k)):v(m.value,k);if(y.value.count&&k&&!t.startDate)return c(L(),k)},oe=()=>Array.isArray(m.value)&&T.value.enabled?me.getMonth(m.value[0])===me.getMonth(m.value[1]??m.value[0]):!1,c=(k=new Date,G=!1)=>{if((!y.value.count||!y.value.static||G)&&g(0,me.getMonth(k),se.getYear(k)),y.value.count&&(!y.value.solo||!m.value||oe()))for(let A=1;A<y.value.count;A++){const K=pe.set(L(),{month:ue.value(A-1),year:h.value(A-1)}),ae=$a.add(K,{months:1});Y.value[A]={month:me.getMonth(ae),year:se.getYear(ae)}}},v=(k,G)=>{c(k),F("hours",He.getHours(k)),F("minutes",We.getMinutes(k)),F("seconds",st.getSeconds(k)),y.value.count&&G&&we()},r=k=>{if(y.value.count){if(y.value.solo)return 0;const G=me.getMonth(k[0]),A=me.getMonth(k[1]);return Math.abs(A-G)<y.value.count?0:1}return 1},_=(k,G)=>{k[1]&&T.value.showLastInRange?c(k[r(k)],G):c(k[0],G);const A=(K,ae)=>[K(k[0]),k[1]?K(k[1]):p[ae][1]];F("hours",A(He.getHours,"hours")),F("minutes",A(We.getMinutes,"minutes")),F("seconds",A(st.getSeconds,"seconds"))},O=(k,G)=>{if((T.value.enabled||t.weekPicker)&&!q.value.enabled)return _(k,G);if(q.value.enabled&&G){const A=k[k.length-1];return v(A,G)}},i=k=>{const G=m.value;O(G,k),y.value.count&&y.value.solo&&we()},Z=(k,G)=>{const A=pe.set(L(),{month:ue.value(G),year:h.value(G)}),K=k<0?at.addMonths(A,1):kt.subMonths(A,1);M(me.getMonth(K),se.getYear(K),k<0,t.preventMinMaxNavigation)&&(g(G,me.getMonth(K),se.getYear(K)),a("update-month-year",{instance:G,month:me.getMonth(K),year:se.getYear(K)}),y.value.count&&!y.value.solo&&ie(G),o())},ie=k=>{for(let G=k-1;G>=0;G--){const A=kt.subMonths(pe.set(L(),{month:ue.value(G+1),year:h.value(G+1)}),1);g(G,me.getMonth(A),se.getYear(A))}for(let G=k+1;G<=y.value.count-1;G++){const A=at.addMonths(pe.set(L(),{month:ue.value(G-1),year:h.value(G-1)}),1);g(G,me.getMonth(A),se.getYear(A))}},we=()=>{if(Array.isArray(m.value)&&m.value.length===2){const k=L(L(m.value[1]?m.value[1]:at.addMonths(m.value[0],1))),[G,A]=[me.getMonth(m.value[0]),se.getYear(m.value[0])],[K,ae]=[me.getMonth(m.value[1]),se.getYear(m.value[1])];(G!==K||G===K&&A!==ae)&&y.value.solo&&g(1,me.getMonth(k),se.getYear(k))}else m.value&&!Array.isArray(m.value)&&(g(0,me.getMonth(m.value),se.getYear(m.value)),c(L()))},B=()=>{t.startDate&&(g(0,me.getMonth(L(t.startDate)),se.getYear(L(t.startDate))),y.value.count&&ie(0))},j=(k,G)=>{if(t.monthChangeOnScroll){const A=new Date().getTime()-s.value.getTime(),K=Math.abs(k.deltaY);let ae=500;K>1&&(ae=100),K>100&&(ae=0),A>ae&&(s.value=new Date,Z(t.monthChangeOnScroll!=="inverse"?-k.deltaY:k.deltaY,G))}},u=(k,G,A=!1)=>{t.monthChangeOnArrows&&t.vertical===A&&E(k,G)},E=(k,G)=>{Z(k==="right"?-1:1,G)},Q=k=>{if(z.value.markers)return Tt(k.value,z.value.markers)},D=(k,G)=>{switch(t.sixWeeks===!0?"append":t.sixWeeks){case"prepend":return[!0,!1];case"center":return[k==0,!0];case"fair":return[k==0||G>k,!0];case"append":return[!1,!1];default:return[!1,!1]}},de=(k,G,A,K)=>{if(t.sixWeeks&&k.length<6){const ae=6-k.length,Be=(G.getDay()+7-K)%7,Ve=6-(A.getDay()+7-K)%7,[Je,xt]=D(Be,Ve);for(let ft=1;ft<=ae;ft++)if(xt?!!(ft%2)==Je:Je){const Ue=k[0].days[0],Ht=w(tt.addDays(Ue.value,-7),me.getMonth(G));k.unshift({days:Ht})}else{const Ue=k[k.length-1],Ht=Ue.days[Ue.days.length-1],ol=w(tt.addDays(Ht.value,1),me.getMonth(G));k.push({days:ol})}}return k},w=(k,G)=>{const A=L(k),K=[];for(let ae=0;ae<7;ae++){const Be=tt.addDays(A,ae),Ve=me.getMonth(Be)!==G;K.push({text:t.hideOffsetDates&&Ve?"":Be.getDate(),value:Be,current:!Ve,classData:{}})}return K},U=(k,G)=>{const A=[],K=new Date(G,k),ae=new Date(G,k+1,0),Be=t.weekStart,Ve=ra.startOfWeek(K,{weekStartsOn:Be}),Je=xt=>{const ft=w(xt,k);if(A.push({days:ft}),!A[A.length-1].days.some(Ue=>ve(De(Ue.value),De(ae)))){const Ue=tt.addDays(xt,7);Je(Ue)}};return Je(Ve),de(A,K,ae,Be)},le=k=>{const G=Ge(L(k.value),p.hours,p.minutes,Pe());a("date-update",G),q.value.enabled?ya(G,m,q.value.limit):m.value=G,l(),e.nextTick().then(()=>{$()})},ce=k=>T.value.noDisabledRange?Qa(n.value[0],k).some(G=>I(G)):!1,$e=()=>{n.value=m.value?m.value.slice():[],n.value.length===2&&!(T.value.fixedStart||T.value.fixedEnd)&&(n.value=[])},re=(k,G)=>{const A=[L(k.value),tt.addDays(L(k.value),+T.value.autoRange)];J(A)?(G&&qe(k.value),n.value=A):a("invalid-date",k.value)},qe=k=>{const G=me.getMonth(L(k)),A=se.getYear(L(k));if(g(0,G,A),y.value.count>0)for(let K=1;K<y.value.count;K++){const ae=Vl(pe.set(L(k),{year:h.value(K-1),month:ue.value(K-1)}));g(K,ae.month,ae.year)}},Ee=k=>{if(ce(k.value)||!V(k.value,m.value,T.value.fixedStart?0:1))return a("invalid-date",k.value);n.value=al(L(k.value),m,a,T)},vt=(k,G)=>{if($e(),T.value.autoRange)return re(k,G);if(T.value.fixedStart||T.value.fixedEnd)return Ee(k);n.value[0]?V(L(k.value),m.value)&&!ce(k.value)?ge(L(k.value),L(n.value[0]))?(n.value.unshift(L(k.value)),a("range-end",n.value[0])):(n.value[1]=L(k.value),a("range-end",n.value[1])):(t.autoApply&&a("auto-apply-invalid",k.value),a("invalid-date",k.value)):(n.value[0]=L(k.value),a("range-start",n.value[0]))},Pe=(k=!0)=>t.enableSeconds?Array.isArray(p.seconds)?k?p.seconds[0]:p.seconds[1]:p.seconds:0,pt=k=>{n.value[k]=Ge(n.value[k],p.hours[k],p.minutes[k],Pe(k!==1))},Ot=()=>{var k,G;n.value[0]&&n.value[1]&&+((k=n.value)==null?void 0:k[0])>+((G=n.value)==null?void 0:G[1])&&(n.value.reverse(),a("range-start",n.value[0]),a("range-end",n.value[1]))},Ct=()=>{n.value.length&&(n.value[0]&&!n.value[1]?pt(0):(pt(0),pt(1),l()),Ot(),m.value=n.value.slice(),Vt(n.value,a,t.autoApply,t.modelAuto))},Yt=(k,G=!1)=>{if(I(k.value)||!k.current&&t.hideOffsetDates)return a("invalid-date",k.value);if(d.value=JSON.parse(JSON.stringify(k)),!T.value.enabled)return le(k);Ta(p.hours)&&Ta(p.minutes)&&!q.value.enabled&&(vt(k,G),Ct())},Et=(k,G)=>{var A;g(k,G.month,G.year,!0),y.value.count&&!y.value.solo&&ie(k),a("update-month-year",{instance:k,month:G.month,year:G.year}),o(y.value.solo?k:void 0);const K=(A=t.flow)!=null&&A.length?t.flow[t.flowStep]:void 0;!G.fromNav&&(K===xe.month||K===xe.year)&&l()},zt=(k,G)=>{tl({value:k,modelValue:m,range:T.value.enabled,timezone:G?void 0:H.value.timezone}),R(),t.multiCalendars&&e.nextTick().then(()=>W(!0))},Ft=()=>{const k=ca(L(),H.value);T.value.enabled?m.value&&Array.isArray(m.value)&&m.value[0]?m.value=ge(k,m.value[0])?[k,m.value[0]]:[m.value[0],k]:m.value=[k]:m.value=k,R()},It=()=>{if(Array.isArray(m.value))if(q.value.enabled){const k=Lt();m.value[m.value.length-1]=ee(k)}else m.value=m.value.map((k,G)=>k&&ee(k,G));else m.value=ee(m.value);a("time-update")},Lt=()=>Array.isArray(m.value)&&m.value.length?m.value[m.value.length-1]:null;return{calendars:Y,modelValue:m,month:ue,year:h,time:p,disabledTimesConfig:ne,today:f,validateTime:te,getCalendarDays:U,getMarker:Q,handleScroll:j,handleSwipe:E,handleArrow:u,selectDate:Yt,updateMonthYear:Et,presetDate:zt,selectCurrentDate:Ft,updateTime:(k,G=!0,A=!1)=>{P(k,G,A,It)},assignMonthAndYear:c}},Wn={key:0},Zn=e.defineComponent({__name:"DatePicker",props:{...Ye},emits:["tooltip-open","tooltip-close","mount","update:internal-model-value","update-flow-step","reset-flow","auto-apply","focus-menu","select-date","range-start","range-end","invalid-fixed-range","time-update","am-pm-change","time-picker-open","time-picker-close","recalculate-position","update-month-year","auto-apply-invalid","date-update","invalid-date","overlay-toggle"],setup(t,{expose:a,emit:o}){const l=o,n=t,{calendars:s,month:d,year:b,modelValue:m,time:Y,disabledTimesConfig:p,today:f,validateTime:y,getCalendarDays:C,getMarker:T,handleArrow:S,handleScroll:H,handleSwipe:z,selectDate:q,updateMonthYear:M,presetDate:I,selectCurrentDate:J,updateTime:V,assignMonthAndYear:P}=Gn(n,l,oe,c),ee=e.useSlots(),{setHoverDate:F,getDayClassData:N,clearHoverDate:te}=pr(m,n),{defaultedMultiCalendars:ne}=he(n),ue=e.ref([]),h=e.ref([]),x=e.ref(null),g=Ne(ee,"calendar"),R=Ne(ee,"monthYear"),X=Ne(ee,"timePicker"),$=j=>{n.shadow||l("mount",j)};e.watch(s,()=>{n.shadow||setTimeout(()=>{l("recalculate-position")},0)},{deep:!0}),e.watch(ne,(j,u)=>{j.count-u.count>0&&P()},{deep:!0});const W=e.computed(()=>j=>C(d.value(j),b.value(j)).map(u=>({...u,days:u.days.map(E=>(E.marker=T(E),E.classData=N(E),E))})));function oe(j){var u;j||j===0?(u=h.value[j])==null||u.triggerTransition(d.value(j),b.value(j)):h.value.forEach((E,Q)=>E.triggerTransition(d.value(Q),b.value(Q)))}function c(){l("update-flow-step")}const v=(j,u=!1)=>{q(j,u),n.spaceConfirm&&l("select-date")},r=(j,u,E=0)=>{var Q;(Q=ue.value[E])==null||Q.toggleMonthPicker(j,u)},_=(j,u,E=0)=>{var Q;(Q=ue.value[E])==null||Q.toggleYearPicker(j,u)},O=(j,u,E)=>{var Q;(Q=x.value)==null||Q.toggleTimePicker(j,u,E)},i=(j,u)=>{var E;if(!n.range){const Q=m.value?m.value:f,D=u?new Date(u):Q,de=j?ra.startOfWeek(D,{weekStartsOn:1}):Va.endOfWeek(D,{weekStartsOn:1});q({value:de,current:me.getMonth(D)===d.value(0),text:"",classData:{}}),(E=document.getElementById(Xa(de)))==null||E.focus()}},Z=j=>{var u;(u=ue.value[0])==null||u.handleMonthYearChange(j,!0)},ie=j=>{M(0,{month:d.value(0),year:b.value(0)+(j?1:-1),fromNav:!0})},we=(j,u)=>{j===xe.time&&l(`time-picker-${u?"open":"close"}`),l("overlay-toggle",{open:u,overlay:j})},B=j=>{l("overlay-toggle",{open:!1,overlay:j}),l("focus-menu")};return a({clearHoverDate:te,presetDate:I,selectCurrentDate:J,toggleMonthPicker:r,toggleYearPicker:_,toggleTimePicker:O,handleArrow:S,updateMonthYear:M,getSidebarProps:()=>({modelValue:m,month:d,year:b,time:Y,updateTime:V,updateMonthYear:M,selectDate:q,presetDate:I}),changeMonth:Z,changeYear:ie,selectWeekDate:i}),(j,u)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode($t,{"multi-calendars":e.unref(ne).count,collapse:j.collapse},{default:e.withCtx(({instance:E,index:Q})=>[j.disableMonthYearSelect?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(Fn,e.mergeProps({key:0,ref:D=>{D&&(ue.value[Q]=D)},months:e.unref(Ia)(j.formatLocale,j.locale,j.monthNameFormat),years:e.unref(ma)(j.yearRange,j.locale,j.reverseYears),month:e.unref(d)(E),year:e.unref(b)(E),instance:E},j.$props,{onMount:u[0]||(u[0]=D=>$(e.unref(lt).header)),onResetFlow:u[1]||(u[1]=D=>j.$emit("reset-flow")),onUpdateMonthYear:D=>e.unref(M)(E,D),onOverlayClosed:B,onOverlayOpened:u[2]||(u[2]=D=>j.$emit("overlay-toggle",{open:!0,overlay:D}))}),e.createSlots({_:2},[e.renderList(e.unref(R),(D,de)=>({name:D,fn:e.withCtx(w=>[e.renderSlot(j.$slots,D,e.normalizeProps(e.guardReactiveProps(w)))])}))]),1040,["months","years","month","year","instance","onUpdateMonthYear"])),e.createVNode(Kn,e.mergeProps({ref:D=>{D&&(h.value[Q]=D)},"mapped-dates":W.value(E),month:e.unref(d)(E),year:e.unref(b)(E),instance:E},j.$props,{onSelectDate:D=>e.unref(q)(D,E!==1),onHandleSpace:D=>v(D,E!==1),onSetHoverDate:u[3]||(u[3]=D=>e.unref(F)(D)),onHandleScroll:D=>e.unref(H)(D,E),onHandleSwipe:D=>e.unref(z)(D,E),onMount:u[4]||(u[4]=D=>$(e.unref(lt).calendar)),onResetFlow:u[5]||(u[5]=D=>j.$emit("reset-flow")),onTooltipOpen:u[6]||(u[6]=D=>j.$emit("tooltip-open",D)),onTooltipClose:u[7]||(u[7]=D=>j.$emit("tooltip-close",D))}),e.createSlots({_:2},[e.renderList(e.unref(g),(D,de)=>({name:D,fn:e.withCtx(w=>[e.renderSlot(j.$slots,D,e.normalizeProps(e.guardReactiveProps({...w})))])}))]),1040,["mapped-dates","month","year","instance","onSelectDate","onHandleSpace","onHandleScroll","onHandleSwipe"])]),_:3},8,["multi-calendars","collapse"]),j.enableTimePicker?(e.openBlock(),e.createElementBlock("div",Wn,[j.$slots["time-picker"]?e.renderSlot(j.$slots,"time-picker",e.normalizeProps(e.mergeProps({key:0},{time:e.unref(Y),updateTime:e.unref(V)}))):(e.openBlock(),e.createBlock(nl,e.mergeProps({key:1,ref_key:"timePickerRef",ref:x},j.$props,{hours:e.unref(Y).hours,minutes:e.unref(Y).minutes,seconds:e.unref(Y).seconds,"internal-model-value":j.internalModelValue,"disabled-times-config":e.unref(p),"validate-time":e.unref(y),onMount:u[8]||(u[8]=E=>$(e.unref(lt).timePicker)),"onUpdate:hours":u[9]||(u[9]=E=>e.unref(V)(E)),"onUpdate:minutes":u[10]||(u[10]=E=>e.unref(V)(E,!1)),"onUpdate:seconds":u[11]||(u[11]=E=>e.unref(V)(E,!1,!0)),onResetFlow:u[12]||(u[12]=E=>j.$emit("reset-flow")),onOverlayClosed:u[13]||(u[13]=E=>we(E,!1)),onOverlayOpened:u[14]||(u[14]=E=>we(E,!0)),onAmPmChange:u[15]||(u[15]=E=>j.$emit("am-pm-change",E))}),e.createSlots({_:2},[e.renderList(e.unref(X),(E,Q)=>({name:E,fn:e.withCtx(D=>[e.renderSlot(j.$slots,E,e.normalizeProps(e.guardReactiveProps(D)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config","validate-time"]))])):e.createCommentVNode("",!0)],64))}}),Xn=(t,a)=>{const o=e.ref(),{defaultedMultiCalendars:l,defaultedConfig:n,defaultedHighlight:s,defaultedRange:d,propDates:b,defaultedFilters:m,defaultedMultiDates:Y}=he(t),{modelValue:p,year:f,month:y,calendars:C}=St(t,a),{isDisabled:T}=Xe(t),{selectYear:S,groupedYears:H,showYearPicker:z,isDisabled:q,toggleYearPicker:M,handleYearSelect:I,handleYear:J}=ll({modelValue:p,multiCalendars:l,range:d,highlight:s,calendars:C,propDates:b,month:y,year:f,filters:m,props:t,emit:a}),V=(x,g)=>[x,g].map(R=>Fe.formatDate(R,"MMMM",{locale:t.formatLocale})).join("-"),P=e.computed(()=>x=>p.value?Array.isArray(p.value)?p.value.some(g=>ka.isSameQuarter(x,g)):ka.isSameQuarter(p.value,x):!1),ee=x=>{if(d.value.enabled){if(Array.isArray(p.value)){const g=ve(x,p.value[0])||ve(x,p.value[1]);return Pt(p.value,o.value,x)&&!g}return!1}return!1},F=(x,g)=>x.quarter===wa.getQuarter(g)&&x.year===se.getYear(g),N=x=>typeof s.value=="function"?s.value({quarter:wa.getQuarter(x),year:se.getYear(x)}):!!s.value.quarters.find(g=>F(g,x)),te=e.computed(()=>x=>{const g=pe.set(new Date,{year:f.value(x)});return cl.eachQuarterOfInterval({start:Dt.startOfYear(g),end:Ra.endOfYear(g)}).map(R=>{const X=ml.startOfQuarter(R),$=ba.endOfQuarter(R),W=T(R),oe=ee(X),c=N(X);return{text:V(X,$),value:X,active:P.value(X),highlighted:c,disabled:W,isBetween:oe}})}),ne=x=>{ya(x,p,Y.value.limit),a("auto-apply",!0)},ue=x=>{p.value=ha(p,x,a),Vt(p.value,a,t.autoApply,t.modelAuto)},h=x=>{p.value=x,a("auto-apply")};return{defaultedConfig:n,defaultedMultiCalendars:l,groupedYears:H,year:f,isDisabled:q,quarters:te,showYearPicker:z,modelValue:p,setHoverDate:x=>{o.value=x},selectYear:S,selectQuarter:(x,g,R)=>{if(!R)return C.value[g].month=me.getMonth(ba.endOfQuarter(x)),Y.value.enabled?ne(x):d.value.enabled?ue(x):h(x)},toggleYearPicker:M,handleYearSelect:I,handleYear:J}},Jn={class:"dp--quarter-items"},er=["data-test","disabled","onClick","onMouseover"],tr=e.defineComponent({compatConfig:{MODE:3},__name:"QuarterPicker",props:{...Ye},emits:["update:internal-model-value","reset-flow","overlay-closed","auto-apply","range-start","range-end","overlay-toggle","update-month-year"],setup(t,{expose:a,emit:o}){const l=o,n=t,s=e.useSlots(),d=Ne(s,"yearMode"),{defaultedMultiCalendars:b,defaultedConfig:m,groupedYears:Y,year:p,isDisabled:f,quarters:y,modelValue:C,showYearPicker:T,setHoverDate:S,selectQuarter:H,toggleYearPicker:z,handleYearSelect:q,handleYear:M}=Xn(n,l);return a({getSidebarProps:()=>({modelValue:C,year:p,selectQuarter:H,handleYearSelect:q,handleYear:M})}),(I,J)=>(e.openBlock(),e.createBlock($t,{"multi-calendars":e.unref(b).count,collapse:I.collapse,stretch:""},{default:e.withCtx(({instance:V})=>[e.createElementVNode("div",{class:"dp-quarter-picker-wrap",style:e.normalizeStyle({minHeight:`${e.unref(m).modeHeight}px`})},[I.$slots["top-extra"]?e.renderSlot(I.$slots,"top-extra",{key:0,value:I.internalModelValue}):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.createVNode(el,e.mergeProps(I.$props,{items:e.unref(Y)(V),instance:V,"show-year-picker":e.unref(T)[V],year:e.unref(p)(V),"is-disabled":P=>e.unref(f)(V,P),onHandleYear:P=>e.unref(M)(V,P),onYearSelect:P=>e.unref(q)(P,V),onToggleYearPicker:P=>e.unref(z)(V,P==null?void 0:P.flow,P==null?void 0:P.show)}),e.createSlots({_:2},[e.renderList(e.unref(d),(P,ee)=>({name:P,fn:e.withCtx(F=>[e.renderSlot(I.$slots,P,e.normalizeProps(e.guardReactiveProps(F)))])}))]),1040,["items","instance","show-year-picker","year","is-disabled","onHandleYear","onYearSelect","onToggleYearPicker"])]),e.createElementVNode("div",Jn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(y)(V),(P,ee)=>(e.openBlock(),e.createElementBlock("div",{key:ee},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["dp--qr-btn",{"dp--qr-btn-active":P.active,"dp--qr-btn-between":P.isBetween,"dp--qr-btn-disabled":P.disabled,"dp--highlighted":P.highlighted}]),"data-test":P.value,disabled:P.disabled,onClick:F=>e.unref(H)(P.value,V,P.disabled),onMouseover:F=>e.unref(S)(P.value)},[I.$slots.quarter?e.renderSlot(I.$slots,"quarter",{key:0,value:P.value,text:P.text}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(P.text),1)],64))],42,er)]))),128))])],4)]),_:3},8,["multi-calendars","collapse"]))}}),ar=["id","tabindex","role","aria-label"],lr={key:0,class:"dp--menu-load-container"},nr=e.createElementVNode("span",{class:"dp--menu-loader"},null,-1),rr=[nr],or={key:1,class:"dp--menu-header"},ur={key:0,class:"dp__sidebar_left"},ir=["data-test","onClick","onKeydown"],sr={key:2,class:"dp__sidebar_right"},dr={key:3,class:"dp__action_extra"},Pa=e.defineComponent({compatConfig:{MODE:3},__name:"DatepickerMenu",props:{...Nt,shadow:{type:Boolean,default:!1},openOnTop:{type:Boolean,default:!1},internalModelValue:{type:[Date,Array],default:null},noOverlayFocus:{type:Boolean,default:!1},collapse:{type:Boolean,default:!1},getInputRect:{type:Function,default:()=>({})},isTextInputDate:{type:Boolean,default:!1}},emits:["close-picker","select-date","auto-apply","time-update","flow-step","update-month-year","invalid-select","update:internal-model-value","recalculate-position","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end","auto-apply-invalid","date-update","invalid-date","overlay-toggle"],setup(t,{expose:a,emit:o}){const l=o,n=t,s=e.ref(null),d=e.computed(()=>{const{openOnTop:w,...U}=n;return{...U,flowStep:F.value,collapse:n.collapse,noOverlayFocus:n.noOverlayFocus,menuWrapRef:s.value}}),{setMenuFocused:b,setShiftKey:m,control:Y}=Ja(),p=e.useSlots(),{defaultedTextInput:f,defaultedInline:y,defaultedConfig:C,defaultedUI:T}=he(n),S=e.ref(null),H=e.ref(0),z=e.ref(null),q=e.ref(!1),M=e.ref(null);e.onMounted(()=>{if(!n.shadow){q.value=!0,I(),window.addEventListener("resize",I);const w=_e(s);if(w&&!f.value.enabled&&!y.value.enabled&&(b(!0),g()),w){const U=le=>{C.value.allowPreventDefault&&le.preventDefault(),Ke(le,C.value,!0)};w.addEventListener("pointerdown",U),w.addEventListener("mousedown",U)}}}),e.onUnmounted(()=>{window.removeEventListener("resize",I)});const I=()=>{const w=_e(z);w&&(H.value=w.getBoundingClientRect().width)},{arrowRight:J,arrowLeft:V,arrowDown:P,arrowUp:ee}=Ze(),{flowStep:F,updateFlowStep:N,childMount:te,resetFlow:ne,handleFlow:ue}=fr(n,l,M),h=e.computed(()=>n.monthPicker?fn:n.yearPicker?hn:n.timePicker?Vn:n.quarterPicker?tr:Zn),x=e.computed(()=>{var w;if(C.value.arrowLeft)return C.value.arrowLeft;const U=(w=s.value)==null?void 0:w.getBoundingClientRect(),le=n.getInputRect();return(le==null?void 0:le.width)<(H==null?void 0:H.value)&&(le==null?void 0:le.left)<=((U==null?void 0:U.left)??0)?`${(le==null?void 0:le.width)/2}px`:(le==null?void 0:le.right)>=((U==null?void 0:U.right)??0)&&(le==null?void 0:le.width)<(H==null?void 0:H.value)?`${(H==null?void 0:H.value)-(le==null?void 0:le.width)/2}px`:"50%"}),g=()=>{const w=_e(s);w&&w.focus({preventScroll:!0})},R=e.computed(()=>{var w;return((w=M.value)==null?void 0:w.getSidebarProps())||{}}),X=()=>{n.openOnTop&&l("recalculate-position")},$=Ne(p,"action"),W=e.computed(()=>n.monthPicker||n.yearPicker?Ne(p,"monthYear"):n.timePicker?Ne(p,"timePicker"):Ne(p,"shared")),oe=e.computed(()=>n.openOnTop?"dp__arrow_bottom":"dp__arrow_top"),c=e.computed(()=>({dp__menu_disabled:n.disabled,dp__menu_readonly:n.readonly,"dp-menu-loading":n.loading})),v=e.computed(()=>({dp__menu:!0,dp__menu_index:!y.value.enabled,dp__relative:y.value.enabled,...T.value.menu??{}})),r=w=>{Ke(w,C.value,!0)},_=()=>{n.escClose&&l("close-picker")},O=w=>{if(n.arrowNavigation){if(w===Me.up)return ee();if(w===Me.down)return P();if(w===Me.left)return V();if(w===Me.right)return J()}else w===Me.left||w===Me.up?B("handleArrow",Me.left,0,w===Me.up):B("handleArrow",Me.right,0,w===Me.down)},i=w=>{m(w.shiftKey),!n.disableMonthYearSelect&&w.code===ye.tab&&w.target.classList.contains("dp__menu")&&Y.value.shiftKeyInMenu&&(w.preventDefault(),Ke(w,C.value,!0),l("close-picker"))},Z=()=>{g(),l("time-picker-close")},ie=w=>{var U,le,ce;(U=M.value)==null||U.toggleTimePicker(!1,!1),(le=M.value)==null||le.toggleMonthPicker(!1,!1,w),(ce=M.value)==null||ce.toggleYearPicker(!1,!1,w)},we=(w,U=0)=>{var le,ce,$e;return w==="month"?(le=M.value)==null?void 0:le.toggleMonthPicker(!1,!0,U):w==="year"?(ce=M.value)==null?void 0:ce.toggleYearPicker(!1,!0,U):w==="time"?($e=M.value)==null?void 0:$e.toggleTimePicker(!0,!1):ie(U)},B=(w,...U)=>{var le,ce;(le=M.value)!=null&&le[w]&&((ce=M.value)==null||ce[w](...U))},j=()=>{B("selectCurrentDate")},u=(w,U)=>{B("presetDate",w,U)},E=()=>{B("clearHoverDate")},Q=(w,U)=>{B("updateMonthYear",w,U)},D=(w,U)=>{w.preventDefault(),O(U)},de=w=>{var U,le,ce;if(i(w),w.key===ye.home||w.key===ye.end)return B("selectWeekDate",w.key===ye.home,w.target.getAttribute("id"));switch((w.key===ye.pageUp||w.key===ye.pageDown)&&(w.shiftKey?(B("changeYear",w.key===ye.pageUp),(U=la(s.value,"overlay-year"))==null||U.focus()):(B("changeMonth",w.key===ye.pageUp),(le=la(s.value,w.key===ye.pageUp?"action-prev":"action-next"))==null||le.focus()),w.target.getAttribute("id")&&((ce=s.value)==null||ce.focus({preventScroll:!0}))),w.key){case ye.esc:return _();case ye.arrowLeft:return D(w,Me.left);case ye.arrowRight:return D(w,Me.right);case ye.arrowUp:return D(w,Me.up);case ye.arrowDown:return D(w,Me.down);default:return}};return a({updateMonthYear:Q,switchView:we,handleFlow:ue}),(w,U)=>{var le,ce,$e;return e.openBlock(),e.createElementBlock("div",{id:w.uid?`dp-menu-${w.uid}`:void 0,ref_key:"dpMenuRef",ref:s,tabindex:e.unref(y).enabled?void 0:"0",role:e.unref(y).enabled?void 0:"dialog","aria-label":(le=w.ariaLabels)==null?void 0:le.menu,class:e.normalizeClass(v.value),style:e.normalizeStyle({"--dp-arrow-left":x.value}),onMouseleave:E,onClick:r,onKeydown:de},[(w.disabled||w.readonly)&&e.unref(y).enabled||w.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(c.value)},[w.loading?(e.openBlock(),e.createElementBlock("div",lr,rr)):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0),w.$slots["menu-header"]?(e.openBlock(),e.createElementBlock("div",or,[e.renderSlot(w.$slots,"menu-header")])):e.createCommentVNode("",!0),!e.unref(y).enabled&&!w.teleportCenter?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(oe.value)},null,2)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"innerMenuRef",ref:z,class:e.normalizeClass({dp__menu_content_wrapper:((ce=w.presetDates)==null?void 0:ce.length)||!!w.$slots["left-sidebar"]||!!w.$slots["right-sidebar"],"dp--menu-content-wrapper-collapsed":t.collapse&&((($e=w.presetDates)==null?void 0:$e.length)||!!w.$slots["left-sidebar"]||!!w.$slots["right-sidebar"])}),style:e.normalizeStyle({"--dp-menu-width":`${H.value}px`})},[w.$slots["left-sidebar"]?(e.openBlock(),e.createElementBlock("div",ur,[e.renderSlot(w.$slots,"left-sidebar",e.normalizeProps(e.guardReactiveProps(R.value)))])):e.createCommentVNode("",!0),w.presetDates.length?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass({"dp--preset-dates-collapsed":t.collapse,"dp--preset-dates":!0})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.presetDates,(re,qe)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:qe},[re.slot?e.renderSlot(w.$slots,re.slot,{key:0,presetDate:u,label:re.label,value:re.value}):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",style:e.normalizeStyle(re.style||{}),class:e.normalizeClass(["dp__btn dp--preset-range",{"dp--preset-range-collapsed":t.collapse}]),"data-test":re.testId??void 0,onClick:e.withModifiers(Ee=>u(re.value,re.noTz),["prevent"]),onKeydown:Ee=>e.unref(Ae)(Ee,()=>u(re.value,re.noTz),!0)},e.toDisplayString(re.label),47,ir))],64))),128))],2)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"calendarWrapperRef",ref:S,class:"dp__instance_calendar",role:"document"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.value),e.mergeProps({ref_key:"dynCmpRef",ref:M},d.value,{"flow-step":e.unref(F),onMount:e.unref(te),onUpdateFlowStep:e.unref(N),onResetFlow:e.unref(ne),onFocusMenu:g,onSelectDate:U[0]||(U[0]=re=>w.$emit("select-date")),onDateUpdate:U[1]||(U[1]=re=>w.$emit("date-update",re)),onTooltipOpen:U[2]||(U[2]=re=>w.$emit("tooltip-open",re)),onTooltipClose:U[3]||(U[3]=re=>w.$emit("tooltip-close",re)),onAutoApply:U[4]||(U[4]=re=>w.$emit("auto-apply",re)),onRangeStart:U[5]||(U[5]=re=>w.$emit("range-start",re)),onRangeEnd:U[6]||(U[6]=re=>w.$emit("range-end",re)),onInvalidFixedRange:U[7]||(U[7]=re=>w.$emit("invalid-fixed-range",re)),onTimeUpdate:U[8]||(U[8]=re=>w.$emit("time-update")),onAmPmChange:U[9]||(U[9]=re=>w.$emit("am-pm-change",re)),onTimePickerOpen:U[10]||(U[10]=re=>w.$emit("time-picker-open",re)),onTimePickerClose:Z,onRecalculatePosition:X,onUpdateMonthYear:U[11]||(U[11]=re=>w.$emit("update-month-year",re)),onAutoApplyInvalid:U[12]||(U[12]=re=>w.$emit("auto-apply-invalid",re)),onInvalidDate:U[13]||(U[13]=re=>w.$emit("invalid-date",re)),onOverlayToggle:U[14]||(U[14]=re=>w.$emit("overlay-toggle",re)),"onUpdate:internalModelValue":U[15]||(U[15]=re=>w.$emit("update:internal-model-value",re))}),e.createSlots({_:2},[e.renderList(W.value,(re,qe)=>({name:re,fn:e.withCtx(Ee=>[e.renderSlot(w.$slots,re,e.normalizeProps(e.guardReactiveProps({...Ee})))])}))]),1040,["flow-step","onMount","onUpdateFlowStep","onResetFlow"]))],512),w.$slots["right-sidebar"]?(e.openBlock(),e.createElementBlock("div",sr,[e.renderSlot(w.$slots,"right-sidebar",e.normalizeProps(e.guardReactiveProps(R.value)))])):e.createCommentVNode("",!0),w.$slots["action-extra"]?(e.openBlock(),e.createElementBlock("div",dr,[w.$slots["action-extra"]?e.renderSlot(w.$slots,"action-extra",{key:0,selectCurrentDate:j}):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],6),!w.autoApply||e.unref(C).keepActionRow?(e.openBlock(),e.createBlock(on,e.mergeProps({key:3,"menu-mount":q.value},d.value,{"calendar-width":H.value,onClosePicker:U[16]||(U[16]=re=>w.$emit("close-picker")),onSelectDate:U[17]||(U[17]=re=>w.$emit("select-date")),onInvalidSelect:U[18]||(U[18]=re=>w.$emit("invalid-select")),onSelectNow:j}),e.createSlots({_:2},[e.renderList(e.unref($),(re,qe)=>({name:re,fn:e.withCtx(Ee=>[e.renderSlot(w.$slots,re,e.normalizeProps(e.guardReactiveProps({...Ee})))])}))]),1040,["menu-mount","calendar-width"])):e.createCommentVNode("",!0)],46,ar)}}});var ot=(t=>(t.center="center",t.left="left",t.right="right",t))(ot||{});const cr=({menuRef:t,menuRefInner:a,inputRef:o,pickerWrapperRef:l,inline:n,emit:s,props:d,slots:b})=>{const{defaultedConfig:m}=he(d),Y=e.ref({}),p=e.ref(!1),f=e.ref({top:"0",left:"0"}),y=e.ref(!1),C=e.toRef(d,"teleportCenter");e.watch(C,()=>{f.value=JSON.parse(JSON.stringify({})),J()});const T=g=>{if(d.teleport){const R=g.getBoundingClientRect();return{left:R.left+window.scrollX,top:R.top+window.scrollY}}return{top:0,left:0}},S=(g,R)=>{f.value.left=`${g+R-Y.value.width}px`},H=g=>{f.value.left=`${g}px`},z=(g,R)=>{d.position===ot.left&&H(g),d.position===ot.right&&S(g,R),d.position===ot.center&&(f.value.left=`${g+R/2-Y.value.width/2}px`)},q=g=>{const{width:R,height:X}=g.getBoundingClientRect(),{top:$,left:W}=d.altPosition?d.altPosition(g):T(g);return{top:+$,left:+W,width:R,height:X}},M=()=>{f.value.left="50%",f.value.top="50%",f.value.transform="translate(-50%, -50%)",f.value.position="fixed",delete f.value.opacity},I=()=>{const g=_e(o),{top:R,left:X,transform:$}=d.altPosition(g);f.value={top:`${R}px`,left:`${X}px`,transform:$??""}},J=(g=!0)=>{var R;if(!n.value.enabled){if(C.value)return M();if(d.altPosition!==null)return I();if(g){const X=d.teleport?(R=a.value)==null?void 0:R.$el:t.value;X&&(Y.value=X.getBoundingClientRect()),s("recalculate-position")}return ne()}},V=({inputEl:g,left:R,width:X})=>{window.screen.width>768&&!p.value&&z(R,X),F(g)},P=g=>{const{top:R,left:X,height:$,width:W}=q(g);f.value.top=`${$+R+ +d.offset}px`,y.value=!1,p.value||(f.value.left=`${X+W/2-Y.value.width/2}px`),V({inputEl:g,left:X,width:W})},ee=g=>{const{top:R,left:X,width:$}=q(g);f.value.top=`${R-+d.offset-Y.value.height}px`,y.value=!0,V({inputEl:g,left:X,width:$})},F=g=>{if(d.autoPosition){const{left:R,width:X}=q(g),{left:$,right:W}=Y.value;if(!p.value){if(Math.abs($)!==Math.abs(W)){if($<=0)return p.value=!0,H(R);if(W>=document.documentElement.clientWidth)return p.value=!0,S(R,X)}return z(R,X)}}},N=()=>{const g=_e(o);if(g){const{height:R}=Y.value,{top:X,height:$}=g.getBoundingClientRect(),W=window.innerHeight-X-$,oe=X;return R<=W?et.bottom:R>W&&R<=oe?et.top:W>=oe?et.bottom:et.top}return et.bottom},te=g=>N()===et.bottom?P(g):ee(g),ne=()=>{const g=_e(o);if(g)return d.autoPosition?te(g):P(g)},ue=function(g){if(g){const R=g.scrollHeight>g.clientHeight,X=window.getComputedStyle(g).overflowY.indexOf("hidden")!==-1;return R&&!X}return!0},h=function(g){return!g||g===document.body||g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?window:ue(g)?g:h(g.assignedSlot&&m.value.shadowDom?g.assignedSlot.parentNode:g.parentNode)},x=g=>{if(g)switch(d.position){case ot.left:return{left:0,transform:"translateX(0)"};case ot.right:return{left:`${g.width}px`,transform:"translateX(-100%)"};default:return{left:`${g.width/2}px`,transform:"translateX(-50%)"}}return{}};return{openOnTop:y,menuStyle:f,xCorrect:p,setMenuPosition:J,getScrollableParent:h,shadowRender:(g,R)=>{var X,$,W;const oe=document.createElement("div"),c=(X=_e(o))==null?void 0:X.getBoundingClientRect();oe.setAttribute("id","dp--temp-container");const v=($=l.value)!=null&&$.clientWidth?l.value:document.body;v.append(oe);const r=x(c),_=m.value.shadowDom?Object.keys(b).filter(i=>["right-sidebar","left-sidebar","top-extra","action-extra"].includes(i)):Object.keys(b),O=e.h(g,{...R,shadow:!0,style:{opacity:0,position:"absolute",...r}},Object.fromEntries(_.map(i=>[i,b[i]])));e.render(O,oe),Y.value=(W=O.el)==null?void 0:W.getBoundingClientRect(),e.render(null,oe),v.removeChild(oe)}}},je=[{name:"clock-icon",use:["time","calendar","shared"]},{name:"arrow-left",use:["month-year","calendar","shared","year-mode"]},{name:"arrow-right",use:["month-year","calendar","shared","year-mode"]},{name:"arrow-up",use:["time","calendar","month-year","shared"]},{name:"arrow-down",use:["time","calendar","month-year","shared"]},{name:"calendar-icon",use:["month-year","time","calendar","shared","year-mode"]},{name:"day",use:["calendar","shared"]},{name:"month-overlay-value",use:["calendar","month-year","shared"]},{name:"year-overlay-value",use:["calendar","month-year","shared","year-mode"]},{name:"year-overlay",use:["month-year","shared"]},{name:"month-overlay",use:["month-year","shared"]},{name:"month-overlay-header",use:["month-year","shared"]},{name:"year-overlay-header",use:["month-year","shared"]},{name:"hours-overlay-value",use:["calendar","time","shared"]},{name:"hours-overlay-header",use:["calendar","time","shared"]},{name:"minutes-overlay-value",use:["calendar","time","shared"]},{name:"minutes-overlay-header",use:["calendar","time","shared"]},{name:"seconds-overlay-value",use:["calendar","time","shared"]},{name:"seconds-overlay-header",use:["calendar","time","shared"]},{name:"hours",use:["calendar","time","shared"]},{name:"minutes",use:["calendar","time","shared"]},{name:"month",use:["calendar","month-year","shared"]},{name:"year",use:["calendar","month-year","shared","year-mode"]},{name:"action-buttons",use:["action"]},{name:"action-preview",use:["action"]},{name:"calendar-header",use:["calendar","shared"]},{name:"marker-tooltip",use:["calendar","shared"]},{name:"action-extra",use:["menu"]},{name:"time-picker-overlay",use:["calendar","time","shared"]},{name:"am-pm-button",use:["calendar","time","shared"]},{name:"left-sidebar",use:["menu"]},{name:"right-sidebar",use:["menu"]},{name:"month-year",use:["month-year","shared"]},{name:"time-picker",use:["menu","shared"]},{name:"action-row",use:["action"]},{name:"marker",use:["calendar","shared"]},{name:"quarter",use:["shared"]},{name:"top-extra",use:["shared","month-year"]},{name:"tp-inline-arrow-up",use:["shared","time"]},{name:"tp-inline-arrow-down",use:["shared","time"]},{name:"menu-header",use:["menu"]}],mr=[{name:"trigger"},{name:"input-icon"},{name:"clear-icon"},{name:"dp-input"}],vr={all:()=>je,monthYear:()=>je.filter(t=>t.use.includes("month-year")),input:()=>mr,timePicker:()=>je.filter(t=>t.use.includes("time")),action:()=>je.filter(t=>t.use.includes("action")),calendar:()=>je.filter(t=>t.use.includes("calendar")),menu:()=>je.filter(t=>t.use.includes("menu")),shared:()=>je.filter(t=>t.use.includes("shared")),yearMode:()=>je.filter(t=>t.use.includes("year-mode"))},Ne=(t,a,o)=>{const l=[];return vr[a]().forEach(n=>{t[n.name]&&l.push(n.name)}),o!=null&&o.length&&o.forEach(n=>{n.slot&&l.push(n.slot)}),l},_t=t=>{const a=e.computed(()=>l=>t.value?l?t.value.open:t.value.close:""),o=e.computed(()=>l=>t.value?l?t.value.menuAppearTop:t.value.menuAppearBottom:"");return{transitionName:a,showTransition:!!t.value,menuTransition:o}},St=(t,a,o)=>{const{defaultedRange:l,defaultedTz:n}=he(t),s=L(Te(L(),n.value.timezone)),d=e.ref([{month:me.getMonth(s),year:se.getYear(s)}]),b=y=>{const C={hours:He.getHours(s),minutes:We.getMinutes(s),seconds:0};return l.value.enabled?[C[y],C[y]]:C[y]},m=e.reactive({hours:b("hours"),minutes:b("minutes"),seconds:b("seconds")});e.watch(l,(y,C)=>{y.enabled!==C.enabled&&(m.hours=b("hours"),m.minutes=b("minutes"),m.seconds=b("seconds"))},{deep:!0});const Y=e.computed({get:()=>t.internalModelValue,set:y=>{!t.readonly&&!t.disabled&&a("update:internal-model-value",y)}}),p=e.computed(()=>y=>d.value[y]?d.value[y].month:0),f=e.computed(()=>y=>d.value[y]?d.value[y].year:0);return e.watch(Y,(y,C)=>{o&&JSON.stringify(y??{})!==JSON.stringify(C??{})&&o()},{deep:!0}),{calendars:d,time:m,modelValue:Y,month:p,year:f,today:s}},pr=(t,a)=>{const{defaultedMultiCalendars:o,defaultedMultiDates:l,defaultedUI:n,defaultedHighlight:s,defaultedTz:d,propDates:b,defaultedRange:m}=he(a),{isDisabled:Y}=Xe(a),p=e.ref(null),f=e.ref(Te(new Date,d.value.timezone)),y=r=>{!r.current&&a.hideOffsetDates||(p.value=r.value)},C=()=>{p.value=null},T=r=>Array.isArray(t.value)&&m.value.enabled&&t.value[0]&&p.value?r?be(p.value,t.value[0]):ge(p.value,t.value[0]):!0,S=(r,_)=>{const O=()=>t.value?_?t.value[0]||null:t.value[1]:null,i=t.value&&Array.isArray(t.value)?O():null;return ve(L(r.value),i)},H=r=>{const _=Array.isArray(t.value)?t.value[0]:null;return r?!ge(p.value??null,_):!0},z=(r,_=!0)=>(m.value.enabled||a.weekPicker)&&Array.isArray(t.value)&&t.value.length===2?a.hideOffsetDates&&!r.current?!1:ve(L(r.value),t.value[_?0:1]):m.value.enabled?S(r,_)&&H(_)||ve(r.value,Array.isArray(t.value)?t.value[0]:null)&&T(_):!1,q=(r,_)=>{if(Array.isArray(t.value)&&t.value[0]&&t.value.length===1){const O=ve(r.value,p.value);return _?be(t.value[0],r.value)&&O:ge(t.value[0],r.value)&&O}return!1},M=r=>!t.value||a.hideOffsetDates&&!r.current?!1:m.value.enabled?a.modelAuto&&Array.isArray(t.value)?ve(r.value,t.value[0]?t.value[0]:f.value):!1:l.value.enabled&&Array.isArray(t.value)?t.value.some(_=>ve(_,r.value)):ve(r.value,t.value?t.value:f.value),I=r=>{if(m.value.autoRange||a.weekPicker){if(p.value){if(a.hideOffsetDates&&!r.current)return!1;const _=tt.addDays(p.value,+m.value.autoRange),O=Ie(L(p.value),a.weekStart);return a.weekPicker?ve(O[1],L(r.value)):ve(_,L(r.value))}return!1}return!1},J=r=>{if(m.value.autoRange||a.weekPicker){if(p.value){const _=tt.addDays(p.value,+m.value.autoRange);if(a.hideOffsetDates&&!r.current)return!1;const O=Ie(L(p.value),a.weekStart);return a.weekPicker?be(r.value,O[0])&&ge(r.value,O[1]):be(r.value,p.value)&&ge(r.value,_)}return!1}return!1},V=r=>{if(m.value.autoRange||a.weekPicker){if(p.value){if(a.hideOffsetDates&&!r.current)return!1;const _=Ie(L(p.value),a.weekStart);return a.weekPicker?ve(_[0],r.value):ve(p.value,r.value)}return!1}return!1},P=r=>Pt(t.value,p.value,r.value),ee=()=>a.modelAuto&&Array.isArray(a.internalModelValue)?!!a.internalModelValue[0]:!1,F=()=>a.modelAuto?La(a.internalModelValue):!0,N=r=>{if(a.weekPicker)return!1;const _=m.value.enabled?!z(r)&&!z(r,!1):!0;return!Y(r.value)&&!M(r)&&!(!r.current&&a.hideOffsetDates)&&_},te=r=>m.value.enabled?a.modelAuto?ee()&&M(r):!1:M(r),ne=r=>s.value?Pl(r.value,b.value.highlight):!1,ue=r=>{const _=Y(r.value);return _&&(typeof s.value=="function"?!s.value(r.value,_):!s.value.options.highlightDisabled)},h=r=>{var _;return typeof s.value=="function"?s.value(r.value):(_=s.value.weekdays)==null?void 0:_.includes(r.value.getDay())},x=r=>(m.value.enabled||a.weekPicker)&&(!(o.value.count>0)||r.current)&&F()&&!(!r.current&&a.hideOffsetDates)&&!M(r)?P(r):!1,g=r=>{const{isRangeStart:_,isRangeEnd:O}=W(r),i=m.value.enabled?_||O:!1;return{dp__cell_offset:!r.current,dp__pointer:!a.disabled&&!(!r.current&&a.hideOffsetDates)&&!Y(r.value),dp__cell_disabled:Y(r.value),dp__cell_highlight:!ue(r)&&(ne(r)||h(r))&&!te(r)&&!i&&!V(r)&&!(x(r)&&a.weekPicker)&&!O,dp__cell_highlight_active:!ue(r)&&(ne(r)||h(r))&&te(r),dp__today:!a.noToday&&ve(r.value,f.value)&&r.current,"dp--past":ge(r.value,f.value),"dp--future":be(r.value,f.value)}},R=r=>({dp__active_date:te(r),dp__date_hover:N(r)}),X=r=>{if(t.value&&!Array.isArray(t.value)){const _=Ie(t.value,a.weekStart);return{...c(r),dp__range_start:ve(_[0],r.value),dp__range_end:ve(_[1],r.value),dp__range_between_week:be(r.value,_[0])&&ge(r.value,_[1])}}return{...c(r)}},$=r=>{if(t.value&&Array.isArray(t.value)){const _=Ie(t.value[0],a.weekStart),O=t.value[1]?Ie(t.value[1],a.weekStart):[];return{...c(r),dp__range_start:ve(_[0],r.value)||ve(O[0],r.value),dp__range_end:ve(_[1],r.value)||ve(O[1],r.value),dp__range_between_week:be(r.value,_[0])&&ge(r.value,_[1])||be(r.value,O[0])&&ge(r.value,O[1]),dp__range_between:be(r.value,_[1])&&ge(r.value,O[0])}}return{...c(r)}},W=r=>{const _=o.value.count>0?r.current&&z(r)&&F():z(r)&&F(),O=o.value.count>0?r.current&&z(r,!1)&&F():z(r,!1)&&F();return{isRangeStart:_,isRangeEnd:O}},oe=r=>{const{isRangeStart:_,isRangeEnd:O}=W(r);return{dp__range_start:_,dp__range_end:O,dp__range_between:x(r),dp__date_hover:ve(r.value,p.value)&&!_&&!O&&!a.weekPicker,dp__date_hover_start:q(r,!0),dp__date_hover_end:q(r,!1)}},c=r=>({...oe(r),dp__cell_auto_range:J(r),dp__cell_auto_range_start:V(r),dp__cell_auto_range_end:I(r)}),v=r=>m.value.enabled?m.value.autoRange?c(r):a.modelAuto?{...R(r),...oe(r)}:a.weekPicker?$(r):oe(r):a.weekPicker?X(r):R(r);return{setHoverDate:y,clearHoverDate:C,getDayClassData:r=>a.hideOffsetDates&&!r.current?{}:{...g(r),...v(r),[a.dayClass?a.dayClass(r.value,a.internalModelValue):""]:!0,...n.value.calendarCell??{}}}},Xe=t=>{const{defaultedFilters:a,defaultedRange:o,propDates:l,defaultedMultiDates:n}=he(t),s=h=>l.value.disabledDates?typeof l.value.disabledDates=="function"?l.value.disabledDates(L(h)):!!Tt(h,l.value.disabledDates):!1,d=h=>l.value.maxDate?t.yearPicker?se.getYear(h)>se.getYear(l.value.maxDate):be(h,l.value.maxDate):!1,b=h=>l.value.minDate?t.yearPicker?se.getYear(h)<se.getYear(l.value.minDate):ge(h,l.value.minDate):!1,m=h=>{const x=d(h),g=b(h),R=s(h),X=a.value.months.map(v=>+v).includes(me.getMonth(h)),$=t.disabledWeekDays.length?t.disabledWeekDays.some(v=>+v===ul.getDay(h)):!1,W=C(h),oe=se.getYear(h),c=oe<+t.yearRange[0]||oe>+t.yearRange[1];return!(x||g||R||X||c||$||W)},Y=(h,x)=>ge(...Qe(l.value.minDate,h,x))||ve(...Qe(l.value.minDate,h,x)),p=(h,x)=>be(...Qe(l.value.maxDate,h,x))||ve(...Qe(l.value.maxDate,h,x)),f=(h,x,g)=>{let R=!1;return l.value.maxDate&&g&&p(h,x)&&(R=!0),l.value.minDate&&!g&&Y(h,x)&&(R=!0),R},y=(h,x,g,R)=>{let X=!1;return R&&(l.value.minDate||l.value.maxDate)?l.value.minDate&&l.value.maxDate?X=f(h,x,g):(l.value.minDate&&Y(h,x)||l.value.maxDate&&p(h,x))&&(X=!0):X=!0,X},C=h=>Array.isArray(l.value.allowedDates)&&!l.value.allowedDates.length?!0:l.value.allowedDates?!Tt(h,l.value.allowedDates):!1,T=h=>!m(h),S=h=>o.value.noDisabledRange?!Na.eachDayOfInterval({start:h[0],end:h[1]}).some(x=>T(x)):!0,H=h=>{if(h){const x=se.getYear(h);return x>=+t.yearRange[0]&&x<=t.yearRange[1]}return!0},z=(h,x)=>!!(Array.isArray(h)&&h[x]&&(o.value.maxRange||o.value.minRange)&&H(h[x])),q=(h,x,g=0)=>{if(z(x,g)&&H(h)){const R=il.differenceInCalendarDays(h,x[g]),X=Qa(x[g],h),$=X.length===1?0:X.filter(oe=>T(oe)).length,W=Math.abs(R)-(o.value.minMaxRawRange?0:$);if(o.value.minRange&&o.value.maxRange)return W>=+o.value.minRange&&W<=+o.value.maxRange;if(o.value.minRange)return W>=+o.value.minRange;if(o.value.maxRange)return W<=+o.value.maxRange}return!0},M=()=>!t.enableTimePicker||t.monthPicker||t.yearPicker||t.ignoreTimeValidation,I=h=>Array.isArray(h)?[h[0]?Kt(h[0]):null,h[1]?Kt(h[1]):null]:Kt(h),J=(h,x,g)=>h.find(R=>+R.hours===He.getHours(x)&&R.minutes==="*"?!0:+R.minutes===We.getMinutes(x)&&+R.hours===He.getHours(x))&&g,V=(h,x,g)=>{const[R,X]=h,[$,W]=x;return!J(R,$,g)&&!J(X,W,g)&&g},P=(h,x)=>{const g=Array.isArray(x)?x:[x];return Array.isArray(t.disabledTimes)?Array.isArray(t.disabledTimes[0])?V(t.disabledTimes,g,h):!g.some(R=>J(t.disabledTimes,R,h)):h},ee=(h,x)=>{const g=Array.isArray(x)?[nt(x[0]),x[1]?nt(x[1]):void 0]:nt(x),R=!t.disabledTimes(g);return h&&R},F=(h,x)=>t.disabledTimes?Array.isArray(t.disabledTimes)?P(x,h):ee(x,h):x,N=h=>{let x=!0;if(!h||M())return!0;const g=!l.value.minDate&&!l.value.maxDate?I(h):h;return(t.maxTime||l.value.maxDate)&&(x=Ma(t.maxTime,l.value.maxDate,"max",Se(g),x)),(t.minTime||l.value.minDate)&&(x=Ma(t.minTime,l.value.minDate,"min",Se(g),x)),F(h,x)},te=h=>{if(!t.monthPicker)return!0;let x=!0;const g=L(Oe(h));if(l.value.minDate&&l.value.maxDate){const R=L(Oe(l.value.minDate)),X=L(Oe(l.value.maxDate));return be(g,R)&&ge(g,X)||ve(g,R)||ve(g,X)}if(l.value.minDate){const R=L(Oe(l.value.minDate));x=be(g,R)||ve(g,R)}if(l.value.maxDate){const R=L(Oe(l.value.maxDate));x=ge(g,R)||ve(g,R)}return x},ne=e.computed(()=>h=>!t.enableTimePicker||t.ignoreTimeValidation?!0:N(h)),ue=e.computed(()=>h=>t.monthPicker?Array.isArray(h)&&(o.value.enabled||n.value.enabled)?!h.filter(x=>!te(x)).length:te(h):!0);return{isDisabled:T,validateDate:m,validateMonthYearInRange:y,isDateRangeAllowed:S,checkMinMaxRange:q,isValidTime:N,isTimeValid:ne,isMonthValid:ue}},Rt=()=>{const t=e.computed(()=>(l,n)=>l==null?void 0:l.includes(n)),a=e.computed(()=>(l,n)=>l.count?l.solo?!0:n===0:!0),o=e.computed(()=>(l,n)=>l.count?l.solo?!0:n===l.count-1:!0);return{hideNavigationButtons:t,showLeftIcon:a,showRightIcon:o}},fr=(t,a,o)=>{const l=e.ref(0),n=e.reactive({[lt.timePicker]:!t.enableTimePicker||t.timePicker||t.monthPicker,[lt.calendar]:!1,[lt.header]:!1}),s=e.computed(()=>t.monthPicker||t.timePicker),d=f=>{var y;if((y=t.flow)!=null&&y.length){if(!f&&s.value)return p();n[f]=!0,Object.keys(n).filter(C=>!n[C]).length||p()}},b=()=>{var f,y;(f=t.flow)!=null&&f.length&&l.value!==-1&&(l.value+=1,a("flow-step",l.value),p()),((y=t.flow)==null?void 0:y.length)===l.value&&e.nextTick().then(()=>m())},m=()=>{l.value=-1},Y=(f,y,...C)=>{var T,S;t.flow[l.value]===f&&o.value&&((S=(T=o.value)[y])==null||S.call(T,...C))},p=(f=0)=>{f&&(l.value+=f),Y(xe.month,"toggleMonthPicker",!0),Y(xe.year,"toggleYearPicker",!0),Y(xe.calendar,"toggleTimePicker",!1,!0),Y(xe.time,"toggleTimePicker",!0,!0);const y=t.flow[l.value];(y===xe.hours||y===xe.minutes||y===xe.seconds)&&Y(y,"toggleTimePicker",!0,!0,y)};return{childMount:d,updateFlowStep:b,resetFlow:m,handleFlow:p,flowStep:l}},yr={key:1,class:"dp__input_wrap"},hr=["id","name","inputmode","placeholder","disabled","readonly","required","value","autocomplete","aria-disabled","aria-invalid"],gr={key:2,class:"dp--clear-btn"},kr=["aria-label"],br=e.defineComponent({compatConfig:{MODE:3},__name:"DatepickerInput",props:{isMenuOpen:{type:Boolean,default:!1},inputValue:{type:String,default:""},...Nt},emits:["clear","open","update:input-value","set-input-date","close","select-date","set-empty-date","toggle","focus-prev","focus","blur","real-blur","text-input"],setup(t,{expose:a,emit:o}){const l=o,n=t,{defaultedTextInput:s,defaultedAriaLabels:d,defaultedInline:b,defaultedConfig:m,defaultedRange:Y,defaultedMultiDates:p,defaultedUI:f,getDefaultPattern:y,getDefaultStartTime:C}=he(n),{checkMinMaxRange:T}=Xe(n),S=e.ref(),H=e.ref(null),z=e.ref(!1),q=e.ref(!1),M=e.ref(!1),I=e.ref(null),J=e.computed(()=>({dp__pointer:!n.disabled&&!n.readonly&&!s.value.enabled,dp__disabled:n.disabled,dp__input_readonly:!s.value.enabled,dp__input:!0,dp__input_icon_pad:!n.hideInputIcon,dp__input_valid:typeof n.state=="boolean"?n.state:!1,dp__input_invalid:typeof n.state=="boolean"?!n.state:!1,dp__input_focus:z.value||n.isMenuOpen,dp__input_reg:!s.value.enabled,...f.value.input??{}})),V=()=>{l("set-input-date",null),n.clearable&&n.autoApply&&(l("set-empty-date"),S.value=null)},P=c=>{const v=C();return Nl(c,s.value.format??y(),v??Ka({},n.enableSeconds),n.inputValue,M.value,n.formatLocale)},ee=c=>{const{rangeSeparator:v}=s.value,[r,_]=c.split(`${v}`);if(r){const O=P(r.trim()),i=_?P(_.trim()):null;if(it.isAfter(O,i))return;const Z=O&&i?[O,i]:[O];T(i,Z,0)&&(S.value=O?Z:null)}},F=()=>{M.value=!0},N=c=>{if(Y.value.enabled)ee(c);else if(p.value.enabled){const v=c.split(";");S.value=v.map(r=>P(r.trim())).filter(r=>r)}else S.value=P(c)},te=c=>{var v;const r=typeof c=="string"?c:(v=c.target)==null?void 0:v.value;r!==""?(s.value.openMenu&&!n.isMenuOpen&&l("open"),N(r),l("set-input-date",S.value)):V(),M.value=!1,l("update:input-value",r),l("text-input",c,S.value)},ne=c=>{s.value.enabled?(N(c.target.value),s.value.enterSubmit&&na(S.value)&&n.inputValue!==""?(l("set-input-date",S.value,!0),S.value=null):s.value.enterSubmit&&n.inputValue===""&&(S.value=null,l("clear"))):x(c)},ue=(c,v)=>{var r;I.value&&v&&!q.value&&(c.preventDefault(),q.value=!0,(r=I.value)==null||r.focus()),s.value.enabled&&s.value.tabSubmit&&N(c.target.value),s.value.tabSubmit&&na(S.value)&&n.inputValue!==""?(l("set-input-date",S.value,!0,!0),S.value=null):s.value.tabSubmit&&n.inputValue===""&&(S.value=null,l("clear",!0))},h=()=>{z.value=!0,l("focus"),e.nextTick().then(()=>{var c;s.value.enabled&&s.value.selectOnFocus&&((c=H.value)==null||c.select())})},x=c=>{if(c.preventDefault(),Ke(c,m.value,!0),s.value.enabled&&s.value.openMenu&&!b.value.input){if(s.value.openMenu==="open"&&!n.isMenuOpen)return l("open");if(s.value.openMenu==="toggle")return l("toggle")}else s.value.enabled||l("toggle")},g=()=>{l("real-blur"),z.value=!1,(!n.isMenuOpen||b.value.enabled&&b.value.input)&&l("blur"),n.autoApply&&s.value.enabled&&S.value&&!n.isMenuOpen&&(l("set-input-date",S.value),l("select-date"),S.value=null)},R=c=>{Ke(c,m.value,!0),l("clear")},X=(c,v)=>{if(c.key==="Tab"&&ue(c,v),c.key==="Enter"&&ne(c),!s.value.enabled){if(c.code==="Tab")return;c.preventDefault()}},$=()=>{var c;(c=H.value)==null||c.focus({preventScroll:!0})},W=c=>{S.value=c},oe=c=>{c.key===ye.tab&&(q.value=!1,ue(c))};return a({focusInput:$,setParsedDate:W}),(c,v)=>{var r,_;return e.openBlock(),e.createElementBlock("div",{onClick:x},[c.$slots.trigger&&!c.$slots["dp-input"]&&!e.unref(b).enabled?e.renderSlot(c.$slots,"trigger",{key:0}):e.createCommentVNode("",!0),!c.$slots.trigger&&(!e.unref(b).enabled||e.unref(b).input)?(e.openBlock(),e.createElementBlock("div",yr,[c.$slots["dp-input"]&&!c.$slots.trigger&&(!e.unref(b).enabled||e.unref(b).enabled&&e.unref(b).input)?e.renderSlot(c.$slots,"dp-input",{key:0,value:t.inputValue,isMenuOpen:t.isMenuOpen,onInput:te,onEnter:ne,onTab:ue,onClear:R,onBlur:g,onKeypress:X,onPaste:F,onFocus:h,openMenu:()=>c.$emit("open"),closeMenu:()=>c.$emit("close"),toggleMenu:()=>c.$emit("toggle")}):e.createCommentVNode("",!0),c.$slots["dp-input"]?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("input",{key:1,id:c.uid?`dp-input-${c.uid}`:void 0,ref_key:"inputRef",ref:H,"data-test":"dp-input",name:c.name,class:e.normalizeClass(J.value),inputmode:e.unref(s).enabled?"text":"none",placeholder:c.placeholder,disabled:c.disabled,readonly:c.readonly,required:c.required,value:t.inputValue,autocomplete:c.autocomplete,"aria-disabled":c.disabled||void 0,"aria-invalid":c.state===!1?!0:void 0,onInput:te,onBlur:g,onFocus:h,onKeypress:X,onKeydown:v[0]||(v[0]=O=>X(O,!0)),onPaste:F},null,42,hr)),e.createElementVNode("div",{onClick:v[3]||(v[3]=O=>l("toggle"))},[c.$slots["input-icon"]&&!c.hideInputIcon?(e.openBlock(),e.createElementBlock("span",{key:0,class:"dp__input_icon",onClick:v[1]||(v[1]=O=>l("toggle"))},[e.renderSlot(c.$slots,"input-icon")])):e.createCommentVNode("",!0),!c.$slots["input-icon"]&&!c.hideInputIcon&&!c.$slots["dp-input"]?(e.openBlock(),e.createBlock(e.unref(mt),{key:1,"aria-label":(r=e.unref(d))==null?void 0:r.calendarIcon,class:"dp__input_icon dp__input_icons",onClick:v[2]||(v[2]=O=>l("toggle"))},null,8,["aria-label"])):e.createCommentVNode("",!0)]),c.$slots["clear-icon"]&&t.inputValue&&c.clearable&&!c.disabled&&!c.readonly?(e.openBlock(),e.createElementBlock("span",gr,[e.renderSlot(c.$slots,"clear-icon",{clear:R})])):e.createCommentVNode("",!0),c.clearable&&!c.$slots["clear-icon"]&&t.inputValue&&!c.disabled&&!c.readonly?(e.openBlock(),e.createElementBlock("button",{key:3,ref_key:"clearBtnRef",ref:I,"aria-label":(_=e.unref(d))==null?void 0:_.clearInput,class:"dp--clear-btn",type:"button",onBlur:v[4]||(v[4]=O=>q.value=!1),onKeydown:v[5]||(v[5]=O=>e.unref(Ae)(O,()=>R(O),!0,oe)),onClick:v[6]||(v[6]=e.withModifiers(O=>R(O),["prevent"]))},[e.createVNode(e.unref(Fa),{class:"dp__input_icons","data-test":"clear-icon"})],40,kr)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])}}}),wr=typeof window<"u"?window:void 0,ea=()=>{},_r=t=>e.getCurrentScope()?(e.onScopeDispose(t),!0):!1,Sr=(t,a,o,l)=>{if(!t)return ea;let n=ea;const s=e.watch(()=>e.unref(t),b=>{n(),b&&(b.addEventListener(a,o,l),n=()=>{b.removeEventListener(a,o,l),n=ea})},{immediate:!0,flush:"post"}),d=()=>{s(),n()};return _r(d),d},Cr=(t,a,o,l={})=>{const{window:n=wr,event:s="pointerdown"}=l;return n?Sr(n,s,d=>{const b=_e(t),m=_e(a);!b||!m||b===d.target||d.composedPath().includes(b)||d.composedPath().includes(m)||o(d)},{passive:!0}):void 0},xr=e.defineComponent({compatConfig:{MODE:3},__name:"VueDatePicker",props:{...Nt},emits:["update:model-value","update:model-timezone-value","text-submit","closed","cleared","open","focus","blur","internal-model-change","recalculate-position","flow-step","update-month-year","invalid-select","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end","date-update","invalid-date","overlay-toggle","text-input"],setup(t,{expose:a,emit:o}){const l=o,n=t,s=e.useSlots(),d=e.ref(!1),b=e.toRef(n,"modelValue"),m=e.toRef(n,"timezone"),Y=e.ref(null),p=e.ref(null),f=e.ref(null),y=e.ref(!1),C=e.ref(null),T=e.ref(!1),S=e.ref(!1),H=e.ref(!1),z=e.ref(!1),{setMenuFocused:q,setShiftKey:M}=Ja(),{clearArrowNav:I}=Ze(),{validateDate:J,isValidTime:V}=Xe(n),{defaultedTransitions:P,defaultedTextInput:ee,defaultedInline:F,defaultedConfig:N,defaultedRange:te,defaultedMultiDates:ne}=he(n),{menuTransition:ue,showTransition:h}=_t(P);e.onMounted(()=>{_(n.modelValue),e.nextTick().then(()=>{if(!F.value.enabled){const A=oe(C.value);A==null||A.addEventListener("scroll",Q),window==null||window.addEventListener("resize",D)}}),F.value.enabled&&(d.value=!0),window==null||window.addEventListener("keyup",de),window==null||window.addEventListener("keydown",w)}),e.onUnmounted(()=>{if(!F.value.enabled){const A=oe(C.value);A==null||A.removeEventListener("scroll",Q),window==null||window.removeEventListener("resize",D)}window==null||window.removeEventListener("keyup",de),window==null||window.removeEventListener("keydown",w)});const x=Ne(s,"all",n.presetDates),g=Ne(s,"input");e.watch([b,m],()=>{_(b.value)},{deep:!0});const{openOnTop:R,menuStyle:X,xCorrect:$,setMenuPosition:W,getScrollableParent:oe,shadowRender:c}=cr({menuRef:Y,menuRefInner:p,inputRef:f,pickerWrapperRef:C,inline:F,emit:l,props:n,slots:s}),{inputValue:v,internalModelValue:r,parseExternalModelValue:_,emitModelValue:O,formatInputValue:i,checkBeforeEmit:Z}=an(l,n,y),ie=e.computed(()=>({dp__main:!0,dp__theme_dark:n.dark,dp__theme_light:!n.dark,dp__flex_display:F.value.enabled,"dp--flex-display-collapsed":H.value,dp__flex_display_with_input:F.value.input})),we=e.computed(()=>n.dark?"dp__theme_dark":"dp__theme_light"),B=e.computed(()=>n.teleport?{to:typeof n.teleport=="boolean"?"body":n.teleport,disabled:!n.teleport||F.value.enabled}:{}),j=e.computed(()=>({class:"dp__outer_menu_wrap"})),u=e.computed(()=>F.value.enabled&&(n.timePicker||n.monthPicker||n.yearPicker||n.quarterPicker)),E=()=>{var A,K;return(K=(A=f.value)==null?void 0:A.$el)==null?void 0:K.getBoundingClientRect()},Q=()=>{d.value&&(N.value.closeOnScroll?Pe():W())},D=()=>{var A;d.value&&W();const K=(A=p.value)==null?void 0:A.$el.getBoundingClientRect().width;H.value=document.body.offsetWidth<=K},de=A=>{A.key==="Tab"&&!F.value.enabled&&!n.teleport&&N.value.tabOutClosesMenu&&(C.value.contains(document.activeElement)||Pe()),S.value=A.shiftKey},w=A=>{S.value=A.shiftKey},U=()=>{!n.disabled&&!n.readonly&&(c(Pa,n),W(!1),d.value=!0,d.value&&l("open"),d.value||vt(),_(n.modelValue))},le=()=>{var A;v.value="",vt(),(A=f.value)==null||A.setParsedDate(null),l("update:model-value",null),l("update:model-timezone-value",null),l("cleared"),N.value.closeOnClearValue&&Pe()},ce=()=>{const A=r.value;return!A||!Array.isArray(A)&&J(A)?!0:Array.isArray(A)?ne.value.enabled||A.length===2&&J(A[0])&&J(A[1])?!0:te.value.partialRange&&!n.timePicker?J(A[0]):!1:!1},$e=()=>{Z()&&ce()?(O(),Pe()):l("invalid-select",r.value)},re=A=>{qe(),O(),N.value.closeOnAutoApply&&!A&&Pe()},qe=()=>{f.value&&ee.value.enabled&&f.value.setParsedDate(r.value)},Ee=(A=!1)=>{n.autoApply&&V(r.value)&&ce()&&(te.value.enabled&&Array.isArray(r.value)?(te.value.partialRange||r.value.length===2)&&re(A):re(A))},vt=()=>{ee.value.enabled||(r.value=null)},Pe=()=>{F.value.enabled||(d.value&&(d.value=!1,$.value=!1,q(!1),M(!1),I(),l("closed"),v.value&&_(b.value)),vt(),l("blur"))},pt=(A,K,ae=!1)=>{if(!A){r.value=null;return}const Be=Array.isArray(A)?!A.some(Je=>!J(Je)):J(A),Ve=V(A);Be&&Ve&&(z.value=!0,r.value=A,K&&(T.value=ae,$e(),l("text-submit")),e.nextTick().then(()=>{z.value=!1}))},Ot=()=>{n.autoApply&&V(r.value)&&O(),qe()},Ct=()=>d.value?Pe():U(),Yt=A=>{r.value=A},Et=()=>{ee.value.enabled&&(y.value=!0,i()),l("focus")},zt=()=>{if(ee.value.enabled&&(y.value=!1,_(n.modelValue),T.value)){const A=Tl(C.value,S.value);A==null||A.focus()}l("blur")},Ft=A=>{p.value&&p.value.updateMonthYear(0,{month:Sa(A.month),year:Sa(A.year)})},It=A=>{_(A??n.modelValue)},Lt=(A,K)=>{var ae;(ae=p.value)==null||ae.switchView(A,K)},k=A=>N.value.onClickOutside?N.value.onClickOutside(A):Pe(),G=(A=0)=>{var K;(K=p.value)==null||K.handleFlow(A)};return Cr(Y,f,()=>k(ce)),a({closeMenu:Pe,selectDate:$e,clearValue:le,openMenu:U,onScroll:Q,formatInputValue:i,updateInternalModelValue:Yt,setMonthYear:Ft,parseModel:It,switchView:Lt,toggleMenu:Ct,handleFlow:G,dpWrapMenuRef:Y}),(A,K)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"pickerWrapperRef",ref:C,class:e.normalizeClass(ie.value),"data-datepicker-instance":""},[e.createVNode(br,e.mergeProps({ref_key:"inputRef",ref:f,"input-value":e.unref(v),"onUpdate:inputValue":K[0]||(K[0]=ae=>e.isRef(v)?v.value=ae:null),"is-menu-open":d.value},A.$props,{onClear:le,onOpen:U,onSetInputDate:pt,onSetEmptyDate:e.unref(O),onSelectDate:$e,onToggle:Ct,onClose:Pe,onFocus:Et,onBlur:zt,onRealBlur:K[1]||(K[1]=ae=>y.value=!1),onTextInput:K[2]||(K[2]=ae=>A.$emit("text-input",ae))}),e.createSlots({_:2},[e.renderList(e.unref(g),(ae,Be)=>({name:ae,fn:e.withCtx(Ve=>[e.renderSlot(A.$slots,ae,e.normalizeProps(e.guardReactiveProps(Ve)))])}))]),1040,["input-value","is-menu-open","onSetEmptyDate"]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A.teleport?e.Teleport:"div"),e.normalizeProps(e.guardReactiveProps(B.value)),{default:e.withCtx(()=>[e.createVNode(e.Transition,{name:e.unref(ue)(e.unref(R)),css:e.unref(h)&&!e.unref(F).enabled},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:0,ref_key:"dpWrapMenuRef",ref:Y},j.value,{class:{"dp--menu-wrapper":!e.unref(F).enabled},style:e.unref(F).enabled?void 0:e.unref(X)}),[e.createVNode(Pa,e.mergeProps({ref_key:"dpMenuRef",ref:p},A.$props,{"internal-model-value":e.unref(r),"onUpdate:internalModelValue":K[3]||(K[3]=ae=>e.isRef(r)?r.value=ae:null),class:{[we.value]:!0,"dp--menu-wrapper":A.teleport},"open-on-top":e.unref(R),"no-overlay-focus":u.value,collapse:H.value,"get-input-rect":E,"is-text-input-date":z.value,onClosePicker:Pe,onSelectDate:$e,onAutoApply:Ee,onTimeUpdate:Ot,onFlowStep:K[4]||(K[4]=ae=>A.$emit("flow-step",ae)),onUpdateMonthYear:K[5]||(K[5]=ae=>A.$emit("update-month-year",ae)),onInvalidSelect:K[6]||(K[6]=ae=>A.$emit("invalid-select",e.unref(r))),onAutoApplyInvalid:K[7]||(K[7]=ae=>A.$emit("invalid-select",ae)),onInvalidFixedRange:K[8]||(K[8]=ae=>A.$emit("invalid-fixed-range",ae)),onRecalculatePosition:e.unref(W),onTooltipOpen:K[9]||(K[9]=ae=>A.$emit("tooltip-open",ae)),onTooltipClose:K[10]||(K[10]=ae=>A.$emit("tooltip-close",ae)),onTimePickerOpen:K[11]||(K[11]=ae=>A.$emit("time-picker-open",ae)),onTimePickerClose:K[12]||(K[12]=ae=>A.$emit("time-picker-close",ae)),onAmPmChange:K[13]||(K[13]=ae=>A.$emit("am-pm-change",ae)),onRangeStart:K[14]||(K[14]=ae=>A.$emit("range-start",ae)),onRangeEnd:K[15]||(K[15]=ae=>A.$emit("range-end",ae)),onDateUpdate:K[16]||(K[16]=ae=>A.$emit("date-update",ae)),onInvalidDate:K[17]||(K[17]=ae=>A.$emit("invalid-date",ae)),onOverlayToggle:K[18]||(K[18]=ae=>A.$emit("overlay-toggle",ae))}),e.createSlots({_:2},[e.renderList(e.unref(x),(ae,Be)=>({name:ae,fn:e.withCtx(Ve=>[e.renderSlot(A.$slots,ae,e.normalizeProps(e.guardReactiveProps({...Ve})))])}))]),1040,["internal-model-value","class","open-on-top","no-overlay-focus","collapse","is-text-input-date","onRecalculatePosition"])],16)):e.createCommentVNode("",!0)]),_:3},8,["name","css"])]),_:3},16))],2))}}),ga=(()=>{const t=xr;return t.install=a=>{a.component("Vue3DatePicker",t)},t})(),Br=Object.freeze(Object.defineProperty({__proto__:null,default:ga},Symbol.toStringTag,{value:"Module"}));Object.entries(Br).forEach(([t,a])=>{t!=="default"&&(ga[t]=a)});exports.default=ga;
|