UNPKG

@softechub-ib/vue-datepicker

Version:
1 lines 245 kB
(function(d,Y){typeof exports=="object"&&typeof module<"u"?module.exports=Y(require("vue")):typeof define=="function"&&define.amd?define(["vue"],Y):(d=typeof globalThis<"u"?globalThis:d||self,d.VueDatePicker=Y(d.Vue))})(this,function(d){"use strict";function Y(r,_){for(var n=0;n<_.length;n++){const t=_[n];if(typeof t!="string"&&!Array.isArray(t)){for(const o in t)if(o!=="default"&&!(o in r)){const a=Object.getOwnPropertyDescriptor(t,o);a&&Object.defineProperty(r,o,a.get?a:{enumerable:!0,get:()=>t[o]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var p=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function h(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var St={exports:{}};(function(r,_){(function(n,t){r.exports=t()})(p,function(){var n=1e3,t=6e4,o=36e5,a="millisecond",e="second",i="minute",s="hour",u="day",c="week",f="month",b="quarter",w="year",S="date",A="Invalid Date",O=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,R=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,V={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(T){var D=["th","st","nd","rd"],k=T%100;return"["+T+(D[(k-20)%10]||D[k]||D[0])+"]"}},q=function(T,D,k){var H=String(T);return!H||H.length>=D?T:""+Array(D+1-H.length).join(k)+T},ae={s:q,z:function(T){var D=-T.utcOffset(),k=Math.abs(D),H=Math.floor(k/60),g=k%60;return(D<=0?"+":"-")+q(H,2,"0")+":"+q(g,2,"0")},m:function T(D,k){if(D.date()<k.date())return-T(k,D);var H=12*(k.year()-D.year())+(k.month()-D.month()),g=D.clone().add(H,f),j=k-g<0,z=D.clone().add(H+(j?-1:1),f);return+(-(H+(k-g)/(j?g-z:z-g))||0)},a:function(T){return T<0?Math.ceil(T)||0:Math.floor(T)},p:function(T){return{M:f,y:w,w:c,d:u,D:S,h:s,m:i,s:e,ms:a,Q:b}[T]||String(T||"").toLowerCase().replace(/s$/,"")},u:function(T){return T===void 0}},E="en",te={};te[E]=V;var ee="$isDayjsObject",U=function(T){return T instanceof me||!(!T||!T[ee])},_e=function T(D,k,H){var g;if(!D)return E;if(typeof D=="string"){var j=D.toLowerCase();te[j]&&(g=j),k&&(te[j]=k,g=j);var z=D.split("-");if(!g&&z.length>1)return T(z[0])}else{var W=D.name;te[W]=D,g=W}return!H&&g&&(E=g),g||!H&&E},G=function(T,D){if(U(T))return T.clone();var k=typeof D=="object"?D:{};return k.date=T,k.args=arguments,new me(k)},I=ae;I.l=_e,I.i=U,I.w=function(T,D){return G(T,{locale:D.$L,utc:D.$u,x:D.$x,$offset:D.$offset})};var me=function(){function T(k){this.$L=_e(k.locale,null,!0),this.parse(k),this.$x=this.$x||k.x||{},this[ee]=!0}var D=T.prototype;return D.parse=function(k){this.$d=function(H){var g=H.date,j=H.utc;if(g===null)return new Date(NaN);if(I.u(g))return new Date;if(g instanceof Date)return new Date(g);if(typeof g=="string"&&!/Z$/i.test(g)){var z=g.match(O);if(z){var W=z[2]-1||0,Z=(z[7]||"0").substring(0,3);return j?new Date(Date.UTC(z[1],W,z[3]||1,z[4]||0,z[5]||0,z[6]||0,Z)):new Date(z[1],W,z[3]||1,z[4]||0,z[5]||0,z[6]||0,Z)}}return new Date(g)}(k),this.init()},D.init=function(){var k=this.$d;this.$y=k.getFullYear(),this.$M=k.getMonth(),this.$D=k.getDate(),this.$W=k.getDay(),this.$H=k.getHours(),this.$m=k.getMinutes(),this.$s=k.getSeconds(),this.$ms=k.getMilliseconds()},D.$utils=function(){return I},D.isValid=function(){return this.$d.toString()!==A},D.isSame=function(k,H){var g=G(k);return this.startOf(H)<=g&&g<=this.endOf(H)},D.isAfter=function(k,H){return G(k)<this.startOf(H)},D.isBefore=function(k,H){return this.endOf(H)<G(k)},D.$g=function(k,H,g){return I.u(k)?this[H]:this.set(g,k)},D.unix=function(){return Math.floor(this.valueOf()/1e3)},D.valueOf=function(){return this.$d.getTime()},D.startOf=function(k,H){var g=this,j=!!I.u(H)||H,z=I.p(k),W=function(B,X){var $=I.w(g.$u?Date.UTC(g.$y,X,B):new Date(g.$y,X,B),g);return j?$:$.endOf(u)},Z=function(B,X){return I.w(g.toDate()[B].apply(g.toDate("s"),(j?[0,0,0,0]:[23,59,59,999]).slice(X)),g)},C=this.$W,oe=this.$M,le=this.$D,ue="set"+(this.$u?"UTC":"");switch(z){case w:return j?W(1,0):W(31,11);case f:return j?W(1,oe):W(0,oe+1);case c:var v=this.$locale().weekStart||0,P=(C<v?C+7:C)-v;return W(j?le-P:le+(6-P),oe);case u:case S:return Z(ue+"Hours",0);case s:return Z(ue+"Minutes",1);case i:return Z(ue+"Seconds",2);case e:return Z(ue+"Milliseconds",3);default:return this.clone()}},D.endOf=function(k){return this.startOf(k,!1)},D.$set=function(k,H){var g,j=I.p(k),z="set"+(this.$u?"UTC":""),W=(g={},g[u]=z+"Date",g[S]=z+"Date",g[f]=z+"Month",g[w]=z+"FullYear",g[s]=z+"Hours",g[i]=z+"Minutes",g[e]=z+"Seconds",g[a]=z+"Milliseconds",g)[j],Z=j===u?this.$D+(H-this.$W):H;if(j===f||j===w){var C=this.clone().set(S,1);C.$d[W](Z),C.init(),this.$d=C.set(S,Math.min(this.$D,C.daysInMonth())).$d}else W&&this.$d[W](Z);return this.init(),this},D.set=function(k,H){return this.clone().$set(k,H)},D.get=function(k){return this[I.p(k)]()},D.add=function(k,H){var g,j=this;k=Number(k);var z=I.p(H),W=function(oe){var le=G(j);return I.w(le.date(le.date()+Math.round(oe*k)),j)};if(z===f)return this.set(f,this.$M+k);if(z===w)return this.set(w,this.$y+k);if(z===u)return W(1);if(z===c)return W(7);var Z=(g={},g[i]=t,g[s]=o,g[e]=n,g)[z]||1,C=this.$d.getTime()+k*Z;return I.w(C,this)},D.subtract=function(k,H){return this.add(-1*k,H)},D.format=function(k){var H=this,g=this.$locale();if(!this.isValid())return g.invalidDate||A;var j=k||"YYYY-MM-DDTHH:mm:ssZ",z=I.z(this),W=this.$H,Z=this.$m,C=this.$M,oe=g.weekdays,le=g.months,ue=g.meridiem,v=function(X,$,se,Le){return X&&(X[$]||X(H,j))||se[$].slice(0,Le)},P=function(X){return I.s(W%12||12,X,"0")},B=ue||function(X,$,se){var Le=X<12?"AM":"PM";return se?Le.toLowerCase():Le};return j.replace(R,function(X,$){return $||function(se){switch(se){case"YY":return String(H.$y).slice(-2);case"YYYY":return I.s(H.$y,4,"0");case"M":return C+1;case"MM":return I.s(C+1,2,"0");case"MMM":return v(g.monthsShort,C,le,3);case"MMMM":return v(le,C);case"D":return H.$D;case"DD":return I.s(H.$D,2,"0");case"d":return String(H.$W);case"dd":return v(g.weekdaysMin,H.$W,oe,2);case"ddd":return v(g.weekdaysShort,H.$W,oe,3);case"dddd":return oe[H.$W];case"H":return String(W);case"HH":return I.s(W,2,"0");case"h":return P(1);case"hh":return P(2);case"a":return B(W,Z,!0);case"A":return B(W,Z,!1);case"m":return String(Z);case"mm":return I.s(Z,2,"0");case"s":return String(H.$s);case"ss":return I.s(H.$s,2,"0");case"SSS":return I.s(H.$ms,3,"0");case"Z":return z}return null}(X)||z.replace(":","")})},D.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},D.diff=function(k,H,g){var j,z=this,W=I.p(H),Z=G(k),C=(Z.utcOffset()-this.utcOffset())*t,oe=this-Z,le=function(){return I.m(z,Z)};switch(W){case w:j=le()/12;break;case f:j=le();break;case b:j=le()/3;break;case c:j=(oe-C)/6048e5;break;case u:j=(oe-C)/864e5;break;case s:j=oe/o;break;case i:j=oe/t;break;case e:j=oe/n;break;default:j=oe}return g?j:I.a(j)},D.daysInMonth=function(){return this.endOf(f).$D},D.$locale=function(){return te[this.$L]},D.locale=function(k,H){if(!k)return this.$L;var g=this.clone(),j=_e(k,H,!0);return j&&(g.$L=j),g},D.clone=function(){return I.w(this.$d,this)},D.toDate=function(){return new Date(this.valueOf())},D.toJSON=function(){return this.isValid()?this.toISOString():null},D.toISOString=function(){return this.$d.toISOString()},D.toString=function(){return this.$d.toUTCString()},T}(),be=me.prototype;return G.prototype=be,[["$ms",a],["$s",e],["$m",i],["$H",s],["$W",u],["$M",f],["$y",w],["$D",S]].forEach(function(T){be[T[1]]=function(D){return this.$g(D,T[0],T[1])}}),G.extend=function(T,D){return T.$i||(T(D,me,G),T.$i=!0),G},G.locale=_e,G.isDayjs=U,G.unix=function(T){return G(1e3*T)},G.en=te[E],G.Ls=te,G.p={},G})})(St);var y=St.exports;const M=h(y);(async()=>(M.locale(await Promise.resolve().then(()=>Ji),void 0,!0),M.locale(await Promise.resolve().then(()=>Oi),void 0,!0),M.locale(await Promise.resolve().then(()=>Fi),void 0,!0),M.locale(await Promise.resolve().then(()=>Ii),void 0,!0),M.locale(await Promise.resolve().then(()=>Ni),void 0,!0),M.locale(await Promise.resolve().then(()=>Bi),void 0,!0),M.locale(await Promise.resolve().then(()=>Ri),void 0,!0),M.locale(await Promise.resolve().then(()=>Vi),void 0,!0),M.locale(await Promise.resolve().then(()=>Wi),void 0,!0),M.locale(await Promise.resolve().then(()=>Ki),void 0,!0),M.locale(await Promise.resolve().then(()=>Gi),void 0,!0),M.locale(await Promise.resolve().then(()=>qi),void 0,!0),M.locale(await Promise.resolve().then(()=>Ui),void 0,!0),M.locale(await Promise.resolve().then(()=>Xi),void 0,!0),M.locale(await Promise.resolve().then(()=>Zi),void 0,!0),M.locale(await Promise.resolve().then(()=>Qi),void 0,!0),M.locale(await Promise.resolve().then(()=>el),void 0,!0),M.locale(await Promise.resolve().then(()=>tl),void 0,!0),M.locale(await Promise.resolve().then(()=>nl),void 0,!0),M.locale(await Promise.resolve().then(()=>rl),void 0,!0),M.locale(await Promise.resolve().then(()=>al),void 0,!0),M.locale(await Promise.resolve().then(()=>ol),void 0,!0),M.locale(await Promise.resolve().then(()=>_l),void 0,!0),M.locale(await Promise.resolve().then(()=>sl),void 0,!0),M.locale(await Promise.resolve().then(()=>il),void 0,!0),M.locale(await Promise.resolve().then(()=>ll),void 0,!0),M.locale(await Promise.resolve().then(()=>ul),void 0,!0),M.locale(await Promise.resolve().then(()=>dl),void 0,!0),M.locale(await Promise.resolve().then(()=>ml),void 0,!0),M.locale(await Promise.resolve().then(()=>cl),void 0,!0),M.locale(await Promise.resolve().then(()=>Ml),void 0,!0),M.locale(await Promise.resolve().then(()=>fl),void 0,!0),M.locale(await Promise.resolve().then(()=>pl),void 0,!0),M.locale(await Promise.resolve().then(()=>Yl),void 0,!0),M.locale(await Promise.resolve().then(()=>hl),void 0,!0),M.locale(await Promise.resolve().then(()=>yl),void 0,!0),M.locale(await Promise.resolve().then(()=>Ll),void 0,!0),M.locale(await Promise.resolve().then(()=>vl),void 0,!0),M.locale(await Promise.resolve().then(()=>bl),void 0,!0),M.locale(await Promise.resolve().then(()=>kl),void 0,!0),M.locale(await Promise.resolve().then(()=>wl),void 0,!0),M.locale(await Promise.resolve().then(()=>gl),void 0,!0),M.locale(await Promise.resolve().then(()=>Dl),void 0,!0),M.locale(await Promise.resolve().then(()=>Sl),void 0,!0),M.locale(await Promise.resolve().then(()=>Hl),void 0,!0),M.locale(await Promise.resolve().then(()=>xl),void 0,!0),M.locale(await Promise.resolve().then(()=>Tl),void 0,!0),M.locale(await Promise.resolve().then(()=>jl),void 0,!0),M.locale(await Promise.resolve().then(()=>$l),void 0,!0),M.locale(await Promise.resolve().then(()=>Al),void 0,!0),M.locale(await Promise.resolve().then(()=>Pl),void 0,!0),M.locale(await Promise.resolve().then(()=>El),void 0,!0),M.locale(await Promise.resolve().then(()=>zl),void 0,!0),M.locale(await Promise.resolve().then(()=>Cl),void 0,!0),M.locale(await Promise.resolve().then(()=>Jl),void 0,!0),M.locale(await Promise.resolve().then(()=>Ol),void 0,!0),M.locale(await Promise.resolve().then(()=>Fl),void 0,!0),M.locale(await Promise.resolve().then(()=>Il),void 0,!0),M.locale(await Promise.resolve().then(()=>Nl),void 0,!0),M.locale(await Promise.resolve().then(()=>Bl),void 0,!0),M.locale(await Promise.resolve().then(()=>Rl),void 0,!0),M.locale(await Promise.resolve().then(()=>Vl),void 0,!0),M.locale(await Promise.resolve().then(()=>Wl),void 0,!0),M.locale(await Promise.resolve().then(()=>Kl),void 0,!0),M.locale(await Promise.resolve().then(()=>Gl),void 0,!0),M.locale(await Promise.resolve().then(()=>ql),void 0,!0),M.locale(await Promise.resolve().then(()=>Ul),void 0,!0),M.locale(await Promise.resolve().then(()=>Xl),void 0,!0),M.locale(await Promise.resolve().then(()=>Zl),void 0,!0),M.locale(await Promise.resolve().then(()=>Ql),void 0,!0),M.locale(await Promise.resolve().then(()=>eu),void 0,!0),M.locale(await Promise.resolve().then(()=>tu),void 0,!0),M.locale(await Promise.resolve().then(()=>nu),void 0,!0),M.locale(await Promise.resolve().then(()=>ru),void 0,!0),M.locale(await Promise.resolve().then(()=>au),void 0,!0),M.locale(await Promise.resolve().then(()=>ou),void 0,!0),M.locale(await Promise.resolve().then(()=>_u),void 0,!0),M.locale(await Promise.resolve().then(()=>su),void 0,!0),M.locale(await Promise.resolve().then(()=>iu),void 0,!0),M.locale(await Promise.resolve().then(()=>lu),void 0,!0),M.locale(await Promise.resolve().then(()=>uu),void 0,!0),M.locale(await Promise.resolve().then(()=>du),void 0,!0),M.locale(await Promise.resolve().then(()=>mu),void 0,!0),M.locale(await Promise.resolve().then(()=>cu),void 0,!0),M.locale(await Promise.resolve().then(()=>Mu),void 0,!0),M.locale(await Promise.resolve().then(()=>fu),void 0,!0),M.locale(await Promise.resolve().then(()=>pu),void 0,!0),M.locale(await Promise.resolve().then(()=>Yu),void 0,!0),M.locale(await Promise.resolve().then(()=>hu),void 0,!0),M.locale(await Promise.resolve().then(()=>yu),void 0,!0),M.locale(await Promise.resolve().then(()=>Lu),void 0,!0),M.locale(await Promise.resolve().then(()=>vu),void 0,!0),M.locale(await Promise.resolve().then(()=>bu),void 0,!0),M.locale(await Promise.resolve().then(()=>ku),void 0,!0),M.locale(await Promise.resolve().then(()=>wu),void 0,!0),M.locale(await Promise.resolve().then(()=>gu),void 0,!0),M.locale(await Promise.resolve().then(()=>Du),void 0,!0),M.locale(await Promise.resolve().then(()=>Su),void 0,!0),M.locale(await Promise.resolve().then(()=>Hu),void 0,!0),M.locale(await Promise.resolve().then(()=>xu),void 0,!0),M.locale(await Promise.resolve().then(()=>Tu),void 0,!0),M.locale(await Promise.resolve().then(()=>ju),void 0,!0),M.locale(await Promise.resolve().then(()=>$u),void 0,!0),M.locale(await Promise.resolve().then(()=>Au),void 0,!0),M.locale(await Promise.resolve().then(()=>Pu),void 0,!0),M.locale(await Promise.resolve().then(()=>Eu),void 0,!0),M.locale(await Promise.resolve().then(()=>zu),void 0,!0),M.locale(await Promise.resolve().then(()=>Cu),void 0,!0),M.locale(await Promise.resolve().then(()=>Ju),void 0,!0),M.locale(await Promise.resolve().then(()=>Ou),void 0,!0),M.locale(await Promise.resolve().then(()=>Fu),void 0,!0),M.locale(await Promise.resolve().then(()=>Iu),void 0,!0),M.locale(await Promise.resolve().then(()=>Nu),void 0,!0),M.locale(await Promise.resolve().then(()=>Bu),void 0,!0),M.locale(await Promise.resolve().then(()=>Ru),void 0,!0),M.locale(await Promise.resolve().then(()=>Vu),void 0,!0),M.locale(await Promise.resolve().then(()=>Wu),void 0,!0),M.locale(await Promise.resolve().then(()=>Ku),void 0,!0),M.locale(await Promise.resolve().then(()=>Gu),void 0,!0),M.locale(await Promise.resolve().then(()=>qu),void 0,!0),M.locale(await Promise.resolve().then(()=>Uu),void 0,!0),M.locale(await Promise.resolve().then(()=>Xu),void 0,!0),M.locale(await Promise.resolve().then(()=>Zu),void 0,!0),M.locale(await Promise.resolve().then(()=>Qu),void 0,!0),M.locale(await Promise.resolve().then(()=>ed),void 0,!0),M.locale(await Promise.resolve().then(()=>td),void 0,!0),M.locale(await Promise.resolve().then(()=>nd),void 0,!0),M.locale(await Promise.resolve().then(()=>rd),void 0,!0),M.locale(await Promise.resolve().then(()=>ad),void 0,!0),M.locale(await Promise.resolve().then(()=>od),void 0,!0),M.locale(await Promise.resolve().then(()=>_d),void 0,!0),M.locale(await Promise.resolve().then(()=>sd),void 0,!0),M.locale(await Promise.resolve().then(()=>id),void 0,!0),M.locale(await Promise.resolve().then(()=>ld),void 0,!0),M.locale(await Promise.resolve().then(()=>ud),void 0,!0),M.locale(await Promise.resolve().then(()=>dd),void 0,!0),M.locale(await Promise.resolve().then(()=>md),void 0,!0),M.locale(await Promise.resolve().then(()=>cd),void 0,!0),M.locale(await Promise.resolve().then(()=>Md),void 0,!0),M.locale(await Promise.resolve().then(()=>fd),void 0,!0),M.locale(await Promise.resolve().then(()=>pd),void 0,!0),M.locale(await Promise.resolve().then(()=>Yd),void 0,!0),M.locale(await Promise.resolve().then(()=>hd),void 0,!0)))();const J={dark:"hsla(0, 0%, 0%, 0.9)",middleDark:"hsla(0, 0%, 12%, 1)",lightDark:"hsla(0, 0%, 0%, 0.5)",darkGray:"hsl(0, 0%, 24%)",middleGray1:"hsl(0, 0%, 66%)",middleGray2:"hsl(0, 0%, 80%)",lightGray:"hsl(0, 0%, 94%)",light:"hsl(0, 0%, 100%)",selected:"hsl(213, 100%, 50%)",border:"hsla(0, 0%, 0%, 0.1)",borderDark:"hsla(0, 0%, 30%, 1)",hoverBorder:"hsla(0, 0%, 0%, 0.3)",hoverBorderDark:"hsla(0, 0%, 85%, 1)",error:{borderColor:"hsl(0, 74%, 42%)",backgroundColor:"hsl(0, 86%, 97%)"},errorDark:{borderColor:"hsl(0, 65%, 42%)",backgroundColor:"hsla(0, 90%, 75%, 0.6)"}},Ht=r=>({container:{border:`1px solid ${r?J.borderDark:J.border}`,hoverBorder:`1px solid ${r?J.hoverBorderDark:J.hoverBorder}`,borderRadius:"4px",backgroundColor:r?J.middleDark:J.light,small:{paddingX:"8px",paddingY:"6px",calendarIcon:{size:"14px"},clearIcon:{size:"16px"}},medium:{paddingX:"12px",paddingY:"10px",calendarIcon:{size:"16px"},clearIcon:{size:"20px"}},large:{paddingX:"14px",paddingY:"12px",calendarIcon:{size:"18px"},clearIcon:{size:"22px"}},disabled:{opacity:"0.5"},error:{borderColor:r?J.errorDark.borderColor:J.error.borderColor,backgroundColor:r?J.errorDark.backgroundColor:J.error.backgroundColor}},selection:{calendarIcon:{color:r?J.light:J.lightDark,marginRight:"8px"},clearIcon:{color:r?J.light:J.lightDark,marginLeft:"4px"}},input:{fontSize:"14px",lineHeight:"16px",color:r?J.light:J.dark},calendarWrapper:{zIndex:"10"}}),xt=r=>({container:{width:"272px",paddingX:"12px",paddingY:"12px",border:`1px solid ${r?J.borderDark:J.border}`,borderRadius:"4px",backgroundColor:r?J.middleDark:J.light,boxShadow:"0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)"},header:{marginBottom:"12px"},headerButton:{padding:"4px",color:r?J.light:J.lightDark,border:"none",borderRadius:"4px",backgroundColor:"transparent",hoverBackgroundColor:r?J.darkGray:J.lightGray,iconSize:"16px",restricted:{opacity:"0.5"}},headerDateItem:{fontSize:"12px",fontWeight:"600",lineHeight:"16px",color:r?J.light:J.dark,paddingX:"4px",paddingY:"8px",borderRadius:"4px",hoverBackgroundColor:r?J.darkGray:J.lightGray},table:{fontSize:"12px",gap:"4px"},tableHead:{fontWeight:"700"},tableHeadItem:{color:r?J.middleGray2:J.lightDark},tableBody:{fontWeight:"500"},tableBodyRow:{days:{marginTop:"2px"},monthsYears:{marginBottom:"24px"}},tableBodyItem:{borderRadius:"4px",color:r?J.light:J.dark,hoverBackgroundColor:r?J.darkGray:J.lightGray,offset:{color:r?J.middleGray1:J.lightDark,hoverColor:r?J.light:J.dark,opacity:"0.5"},current:{border:`1px solid ${J.selected}`},restricted:{color:r?J.middleGray1:J.lightDark,opacity:"0.5"},selected:{color:J.light,backgroundColor:J.selected}}}),Ye=function(r,_){return _==="year"?r.split("-")[0]:r.split("-")[1]},F=function(r,_,n,t="month"){let o=M(r);if(!o.isValid())return"";switch(n){case"subtract":o=o.subtract(1,t);break;case"add":o=o.add(1,t);break}return o.format(_)},Tt=Math.min,Ee=Math.max,Be=Math.round,he=r=>({x:r,y:r}),$s={left:"right",right:"left",bottom:"top",top:"bottom"},As={start:"end",end:"start"};function jt(r,_){return typeof r=="function"?r(_):r}function ze(r){return r.split("-")[0]}function ot(r){return r.split("-")[1]}function Ps(r){return r==="x"?"y":"x"}function $t(r){return r==="y"?"height":"width"}function Re(r){return["top","bottom"].includes(ze(r))?"y":"x"}function At(r){return Ps(Re(r))}function Es(r,_,n){n===void 0&&(n=!1);const t=ot(r),o=At(r),a=$t(o);let e=o==="x"?t===(n?"end":"start")?"right":"left":t==="start"?"bottom":"top";return _.reference[a]>_.floating[a]&&(e=Ve(e)),[e,Ve(e)]}function zs(r){const _=Ve(r);return[_t(r),_,_t(_)]}function _t(r){return r.replace(/start|end/g,_=>As[_])}function Cs(r,_,n){const t=["left","right"],o=["right","left"],a=["top","bottom"],e=["bottom","top"];switch(r){case"top":case"bottom":return n?_?o:t:_?t:o;case"left":case"right":return _?a:e;default:return[]}}function Js(r,_,n,t){const o=ot(r);let a=Cs(ze(r),n==="start",t);return o&&(a=a.map(e=>e+"-"+o),_&&(a=a.concat(a.map(_t)))),a}function Ve(r){return r.replace(/left|right|bottom|top/g,_=>$s[_])}function Os(r){return{top:0,right:0,bottom:0,left:0,...r}}function Fs(r){return typeof r!="number"?Os(r):{top:r,right:r,bottom:r,left:r}}function We(r){const{x:_,y:n,width:t,height:o}=r;return{width:t,height:o,top:n,left:_,right:_+t,bottom:n+o,x:_,y:n}}function Pt(r,_,n){let{reference:t,floating:o}=r;const a=Re(_),e=At(_),i=$t(e),s=ze(_),u=a==="y",c=t.x+t.width/2-o.width/2,f=t.y+t.height/2-o.height/2,b=t[i]/2-o[i]/2;let w;switch(s){case"top":w={x:c,y:t.y-o.height};break;case"bottom":w={x:c,y:t.y+t.height};break;case"right":w={x:t.x+t.width,y:f};break;case"left":w={x:t.x-o.width,y:f};break;default:w={x:t.x,y:t.y}}switch(ot(_)){case"start":w[e]-=b*(n&&u?-1:1);break;case"end":w[e]+=b*(n&&u?-1:1);break}return w}const Is=async(r,_,n)=>{const{placement:t="bottom",strategy:o="absolute",middleware:a=[],platform:e}=n,i=a.filter(Boolean),s=await(e.isRTL==null?void 0:e.isRTL(_));let u=await e.getElementRects({reference:r,floating:_,strategy:o}),{x:c,y:f}=Pt(u,t,s),b=t,w={},S=0;for(let A=0;A<i.length;A++){const{name:O,fn:R}=i[A],{x:V,y:q,data:ae,reset:E}=await R({x:c,y:f,initialPlacement:t,placement:b,strategy:o,middlewareData:w,rects:u,platform:e,elements:{reference:r,floating:_}});c=V??c,f=q??f,w={...w,[O]:{...w[O],...ae}},E&&S<=50&&(S++,typeof E=="object"&&(E.placement&&(b=E.placement),E.rects&&(u=E.rects===!0?await e.getElementRects({reference:r,floating:_,strategy:o}):E.rects),{x:c,y:f}=Pt(u,b,s)),A=-1)}return{x:c,y:f,placement:b,strategy:o,middlewareData:w}};async function Ns(r,_){var n;_===void 0&&(_={});const{x:t,y:o,platform:a,rects:e,elements:i,strategy:s}=r,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:f="floating",altBoundary:b=!1,padding:w=0}=jt(_,r),S=Fs(w),O=i[b?f==="floating"?"reference":"floating":f],R=We(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(O)))==null||n?O:O.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(i.floating)),boundary:u,rootBoundary:c,strategy:s})),V=f==="floating"?{x:t,y:o,width:e.floating.width,height:e.floating.height}:e.reference,q=await(a.getOffsetParent==null?void 0:a.getOffsetParent(i.floating)),ae=await(a.isElement==null?void 0:a.isElement(q))?await(a.getScale==null?void 0:a.getScale(q))||{x:1,y:1}:{x:1,y:1},E=We(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:V,offsetParent:q,strategy:s}):V);return{top:(R.top-E.top+S.top)/ae.y,bottom:(E.bottom-R.bottom+S.bottom)/ae.y,left:(R.left-E.left+S.left)/ae.x,right:(E.right-R.right+S.right)/ae.x}}const Bs=function(r){return r===void 0&&(r={}),{name:"flip",options:r,async fn(_){var n,t;const{placement:o,middlewareData:a,rects:e,initialPlacement:i,platform:s,elements:u}=_,{mainAxis:c=!0,crossAxis:f=!0,fallbackPlacements:b,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:A=!0,...O}=jt(r,_);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const R=ze(o),V=Re(i),q=ze(i)===i,ae=await(s.isRTL==null?void 0:s.isRTL(u.floating)),E=b||(q||!A?[Ve(i)]:zs(i)),te=S!=="none";!b&&te&&E.push(...Js(i,A,S,ae));const ee=[i,...E],U=await Ns(_,O),_e=[];let G=((t=a.flip)==null?void 0:t.overflows)||[];if(c&&_e.push(U[R]),f){const T=Es(o,e,ae);_e.push(U[T[0]],U[T[1]])}if(G=[...G,{placement:o,overflows:_e}],!_e.every(T=>T<=0)){var I,me;const T=(((I=a.flip)==null?void 0:I.index)||0)+1,D=ee[T];if(D)return{data:{index:T,overflows:G},reset:{placement:D}};let k=(me=G.filter(H=>H.overflows[0]<=0).sort((H,g)=>H.overflows[1]-g.overflows[1])[0])==null?void 0:me.placement;if(!k)switch(w){case"bestFit":{var be;const H=(be=G.filter(g=>{if(te){const j=Re(g.placement);return j===V||j==="y"}return!0}).map(g=>[g.placement,g.overflows.filter(j=>j>0).reduce((j,z)=>j+z,0)]).sort((g,j)=>g[1]-j[1])[0])==null?void 0:be[0];H&&(k=H);break}case"initialPlacement":k=i;break}if(o!==k)return{reset:{placement:k}}}return{}}}};function Ke(){return typeof window<"u"}function Se(r){return st(r)?(r.nodeName||"").toLowerCase():"#document"}function de(r){var _;return(r==null||(_=r.ownerDocument)==null?void 0:_.defaultView)||window}function ve(r){var _;return(_=(st(r)?r.ownerDocument:r.document)||window.document)==null?void 0:_.documentElement}function st(r){return Ke()?r instanceof Node||r instanceof de(r).Node:!1}function Me(r){return Ke()?r instanceof Element||r instanceof de(r).Element:!1}function ye(r){return Ke()?r instanceof HTMLElement||r instanceof de(r).HTMLElement:!1}function Et(r){return!Ke()||typeof ShadowRoot>"u"?!1:r instanceof ShadowRoot||r instanceof de(r).ShadowRoot}function Ce(r){const{overflow:_,overflowX:n,overflowY:t,display:o}=fe(r);return/auto|scroll|overlay|hidden|clip/.test(_+t+n)&&!["inline","contents"].includes(o)}function Rs(r){return["table","td","th"].includes(Se(r))}function Ge(r){return[":popover-open",":modal"].some(_=>{try{return r.matches(_)}catch{return!1}})}function it(r){const _=lt(),n=Me(r)?fe(r):r;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!_&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!_&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(t=>(n.willChange||"").includes(t))||["paint","layout","strict","content"].some(t=>(n.contain||"").includes(t))}function Vs(r){let _=ge(r);for(;ye(_)&&!je(_);){if(it(_))return _;if(Ge(_))return null;_=ge(_)}return null}function lt(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function je(r){return["html","body","#document"].includes(Se(r))}function fe(r){return de(r).getComputedStyle(r)}function qe(r){return Me(r)?{scrollLeft:r.scrollLeft,scrollTop:r.scrollTop}:{scrollLeft:r.scrollX,scrollTop:r.scrollY}}function ge(r){if(Se(r)==="html")return r;const _=r.assignedSlot||r.parentNode||Et(r)&&r.host||ve(r);return Et(_)?_.host:_}function zt(r){const _=ge(r);return je(_)?r.ownerDocument?r.ownerDocument.body:r.body:ye(_)&&Ce(_)?_:zt(_)}function ut(r,_,n){var t;_===void 0&&(_=[]),n===void 0&&(n=!0);const o=zt(r),a=o===((t=r.ownerDocument)==null?void 0:t.body),e=de(o);if(a){const i=dt(e);return _.concat(e,e.visualViewport||[],Ce(o)?o:[],i&&n?ut(i):[])}return _.concat(o,ut(o,[],n))}function dt(r){return r.parent&&Object.getPrototypeOf(r.parent)?r.frameElement:null}function Ct(r){const _=fe(r);let n=parseFloat(_.width)||0,t=parseFloat(_.height)||0;const o=ye(r),a=o?r.offsetWidth:n,e=o?r.offsetHeight:t,i=Be(n)!==a||Be(t)!==e;return i&&(n=a,t=e),{width:n,height:t,$:i}}function Jt(r){return Me(r)?r:r.contextElement}function $e(r){const _=Jt(r);if(!ye(_))return he(1);const n=_.getBoundingClientRect(),{width:t,height:o,$:a}=Ct(_);let e=(a?Be(n.width):n.width)/t,i=(a?Be(n.height):n.height)/o;return(!e||!Number.isFinite(e))&&(e=1),(!i||!Number.isFinite(i))&&(i=1),{x:e,y:i}}const Ws=he(0);function Ot(r){const _=de(r);return!lt()||!_.visualViewport?Ws:{x:_.visualViewport.offsetLeft,y:_.visualViewport.offsetTop}}function Ks(r,_,n){return _===void 0&&(_=!1),!n||_&&n!==de(r)?!1:_}function Je(r,_,n,t){_===void 0&&(_=!1),n===void 0&&(n=!1);const o=r.getBoundingClientRect(),a=Jt(r);let e=he(1);_&&(t?Me(t)&&(e=$e(t)):e=$e(r));const i=Ks(a,n,t)?Ot(a):he(0);let s=(o.left+i.x)/e.x,u=(o.top+i.y)/e.y,c=o.width/e.x,f=o.height/e.y;if(a){const b=de(a),w=t&&Me(t)?de(t):t;let S=b,A=dt(S);for(;A&&t&&w!==S;){const O=$e(A),R=A.getBoundingClientRect(),V=fe(A),q=R.left+(A.clientLeft+parseFloat(V.paddingLeft))*O.x,ae=R.top+(A.clientTop+parseFloat(V.paddingTop))*O.y;s*=O.x,u*=O.y,c*=O.x,f*=O.y,s+=q,u+=ae,S=de(A),A=dt(S)}}return We({width:c,height:f,x:s,y:u})}function mt(r,_){const n=qe(r).scrollLeft;return _?_.left+n:Je(ve(r)).left+n}function Ft(r,_,n){n===void 0&&(n=!1);const t=r.getBoundingClientRect(),o=t.left+_.scrollLeft-(n?0:mt(r,t)),a=t.top+_.scrollTop;return{x:o,y:a}}function Gs(r){let{elements:_,rect:n,offsetParent:t,strategy:o}=r;const a=o==="fixed",e=ve(t),i=_?Ge(_.floating):!1;if(t===e||i&&a)return n;let s={scrollLeft:0,scrollTop:0},u=he(1);const c=he(0),f=ye(t);if((f||!f&&!a)&&((Se(t)!=="body"||Ce(e))&&(s=qe(t)),ye(t))){const w=Je(t);u=$e(t),c.x=w.x+t.clientLeft,c.y=w.y+t.clientTop}const b=e&&!f&&!a?Ft(e,s,!0):he(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+c.x+b.x,y:n.y*u.y-s.scrollTop*u.y+c.y+b.y}}function qs(r){return Array.from(r.getClientRects())}function Us(r){const _=ve(r),n=qe(r),t=r.ownerDocument.body,o=Ee(_.scrollWidth,_.clientWidth,t.scrollWidth,t.clientWidth),a=Ee(_.scrollHeight,_.clientHeight,t.scrollHeight,t.clientHeight);let e=-n.scrollLeft+mt(r);const i=-n.scrollTop;return fe(t).direction==="rtl"&&(e+=Ee(_.clientWidth,t.clientWidth)-o),{width:o,height:a,x:e,y:i}}function Xs(r,_){const n=de(r),t=ve(r),o=n.visualViewport;let a=t.clientWidth,e=t.clientHeight,i=0,s=0;if(o){a=o.width,e=o.height;const u=lt();(!u||u&&_==="fixed")&&(i=o.offsetLeft,s=o.offsetTop)}return{width:a,height:e,x:i,y:s}}function Zs(r,_){const n=Je(r,!0,_==="fixed"),t=n.top+r.clientTop,o=n.left+r.clientLeft,a=ye(r)?$e(r):he(1),e=r.clientWidth*a.x,i=r.clientHeight*a.y,s=o*a.x,u=t*a.y;return{width:e,height:i,x:s,y:u}}function It(r,_,n){let t;if(_==="viewport")t=Xs(r,n);else if(_==="document")t=Us(ve(r));else if(Me(_))t=Zs(_,n);else{const o=Ot(r);t={x:_.x-o.x,y:_.y-o.y,width:_.width,height:_.height}}return We(t)}function Nt(r,_){const n=ge(r);return n===_||!Me(n)||je(n)?!1:fe(n).position==="fixed"||Nt(n,_)}function Qs(r,_){const n=_.get(r);if(n)return n;let t=ut(r,[],!1).filter(i=>Me(i)&&Se(i)!=="body"),o=null;const a=fe(r).position==="fixed";let e=a?ge(r):r;for(;Me(e)&&!je(e);){const i=fe(e),s=it(e);!s&&i.position==="fixed"&&(o=null),(a?!s&&!o:!s&&i.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Ce(e)&&!s&&Nt(r,e))?t=t.filter(c=>c!==e):o=i,e=ge(e)}return _.set(r,t),t}function ei(r){let{element:_,boundary:n,rootBoundary:t,strategy:o}=r;const e=[...n==="clippingAncestors"?Ge(_)?[]:Qs(_,this._c):[].concat(n),t],i=e[0],s=e.reduce((u,c)=>{const f=It(_,c,o);return u.top=Ee(f.top,u.top),u.right=Tt(f.right,u.right),u.bottom=Tt(f.bottom,u.bottom),u.left=Ee(f.left,u.left),u},It(_,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function ti(r){const{width:_,height:n}=Ct(r);return{width:_,height:n}}function ni(r,_,n){const t=ye(_),o=ve(_),a=n==="fixed",e=Je(r,!0,a,_);let i={scrollLeft:0,scrollTop:0};const s=he(0);if(t||!t&&!a)if((Se(_)!=="body"||Ce(o))&&(i=qe(_)),t){const b=Je(_,!0,a,_);s.x=b.x+_.clientLeft,s.y=b.y+_.clientTop}else o&&(s.x=mt(o));const u=o&&!t&&!a?Ft(o,i):he(0),c=e.left+i.scrollLeft-s.x-u.x,f=e.top+i.scrollTop-s.y-u.y;return{x:c,y:f,width:e.width,height:e.height}}function ct(r){return fe(r).position==="static"}function Bt(r,_){if(!ye(r)||fe(r).position==="fixed")return null;if(_)return _(r);let n=r.offsetParent;return ve(r)===n&&(n=n.ownerDocument.body),n}function Rt(r,_){const n=de(r);if(Ge(r))return n;if(!ye(r)){let o=ge(r);for(;o&&!je(o);){if(Me(o)&&!ct(o))return o;o=ge(o)}return n}let t=Bt(r,_);for(;t&&Rs(t)&&ct(t);)t=Bt(t,_);return t&&je(t)&&ct(t)&&!it(t)?n:t||Vs(r)||n}const ri=async function(r){const _=this.getOffsetParent||Rt,n=this.getDimensions,t=await n(r.floating);return{reference:ni(r.reference,await _(r.floating),r.strategy),floating:{x:0,y:0,width:t.width,height:t.height}}};function ai(r){return fe(r).direction==="rtl"}const oi={convertOffsetParentRelativeRectToViewportRelativeRect:Gs,getDocumentElement:ve,getClippingRect:ei,getOffsetParent:Rt,getElementRects:ri,getClientRects:qs,getDimensions:ti,getScale:$e,isElement:Me,isRTL:ai},_i=Bs,si=(r,_,n)=>{const t=new Map,o={platform:oi,...n},a={...o.platform,_c:t};return Is(r,_,{...o,platform:a})};function ii(r){return r!=null&&typeof r=="object"&&"$el"in r}function Vt(r){if(ii(r)){const _=r.$el;return st(_)&&Se(_)==="#comment"?null:_}return r}function Oe(r){return typeof r=="function"?r():d.unref(r)}function Wt(r){return typeof window>"u"?1:(r.ownerDocument.defaultView||window).devicePixelRatio||1}function Kt(r,_){const n=Wt(r);return Math.round(_*n)/n}function li(r,_,n){n===void 0&&(n={});const t=n.whileElementsMounted,o=d.computed(()=>{var ee;return(ee=Oe(n.open))!=null?ee:!0}),a=d.computed(()=>Oe(n.middleware)),e=d.computed(()=>{var ee;return(ee=Oe(n.placement))!=null?ee:"bottom"}),i=d.computed(()=>{var ee;return(ee=Oe(n.strategy))!=null?ee:"absolute"}),s=d.computed(()=>{var ee;return(ee=Oe(n.transform))!=null?ee:!0}),u=d.computed(()=>Vt(r.value)),c=d.computed(()=>Vt(_.value)),f=d.ref(0),b=d.ref(0),w=d.ref(i.value),S=d.ref(e.value),A=d.shallowRef({}),O=d.ref(!1),R=d.computed(()=>{const ee={position:w.value,left:"0",top:"0"};if(!c.value)return ee;const U=Kt(c.value,f.value),_e=Kt(c.value,b.value);return s.value?{...ee,transform:"translate("+U+"px, "+_e+"px)",...Wt(c.value)>=1.5&&{willChange:"transform"}}:{position:w.value,left:U+"px",top:_e+"px"}});let V;function q(){if(u.value==null||c.value==null)return;const ee=o.value;si(u.value,c.value,{middleware:a.value,placement:e.value,strategy:i.value}).then(U=>{f.value=U.x,b.value=U.y,w.value=U.strategy,S.value=U.placement,A.value=U.middlewareData,O.value=ee!==!1})}function ae(){typeof V=="function"&&(V(),V=void 0)}function E(){if(ae(),t===void 0){q();return}if(u.value!=null&&c.value!=null){V=t(u.value,c.value,q);return}}function te(){o.value||(O.value=!1)}return d.watch([a,e,i,o],q,{flush:"sync"}),d.watch([u,c],E,{flush:"sync"}),d.watch(o,te,{flush:"sync"}),d.getCurrentScope()&&d.onScopeDispose(ae),{x:d.shallowReadonly(f),y:d.shallowReadonly(b),strategy:d.shallowReadonly(w),placement:d.shallowReadonly(S),middlewareData:d.shallowReadonly(A),isPositioned:d.shallowReadonly(O),floatingStyles:R,update:q}}const ui={class:"sib-calendar"},di={key:0,class:"sib-calendar__header"},mi=["disabled","aria-label"],ci={class:"sib-calendar__header__date"},Mi=["aria-label"],fi=["aria-label"],pi=["disabled","aria-label"],Yi={class:"sib-calendar__table",role:"grid","aria-labelledby":"Days calendar"},hi={class:"sib-calendar__table__head",role:"rowgroup"},yi={class:"sib-calendar__table__head__row",role:"row"},Li=["aria-label"],vi=["onMouseenter"],bi=["disabled","data-test-id","onClick"],ki={class:"sib-calendar__table",role:"grid","aria-labelledby":"Months calendar"},wi=["onMouseenter"],gi=["disabled","data-test-id","onClick"],Di=["onMouseenter"],Si=["disabled","data-test-id","onClick"],Hi=d.defineComponent({__name:"VueCalendar",props:{opened:{type:Boolean},value:{},range:{type:Boolean},monthPicker:{type:Boolean},yearPicker:{type:Boolean},startWeekOnMonday:{type:Boolean},hideTodayMark:{type:Boolean},min:{},max:{},styles:{}},emits:["change"],setup(r,{emit:_}){d.useCssVars(v=>({"04131db7":v.styles.container.width,a554f654:v.styles.container.paddingX,"1cde86d4":v.styles.table.gap,a554f652:v.styles.container.paddingY,"5ad5825b":v.styles.container.border,"70766acd":v.styles.container.borderRadius,"5f3a6d86":v.styles.container.backgroundColor,d658a388:v.styles.container.boxShadow,"10eff850":v.styles.header.marginBottom,"7274e738":v.styles.headerButton.padding,dfab0f14:v.styles.headerButton.color,"73724d79":v.styles.headerButton.border,"6809e76b":v.styles.headerButton.borderRadius,"136d4428":v.styles.headerButton.backgroundColor,"4e56d486":v.styles.headerButton.hoverBackgroundColor,"5e905976":v.styles.headerButton.restricted.opacity,"904f33b2":v.styles.headerButton.iconSize,ee99e224:v.styles.headerDateItem.fontSize,"2ebe6a25":v.styles.headerDateItem.fontWeight,"3bc64cb9":v.styles.headerDateItem.lineHeight,"7da09bb6":v.styles.headerDateItem.color,be009736:v.styles.headerDateItem.paddingX,be009734:v.styles.headerDateItem.paddingY,"1d503adc":v.styles.headerDateItem.borderRadius,"0061b212":v.styles.headerDateItem.hoverBackgroundColor,"0531c146":v.styles.tableBodyRow.monthsYears.marginBottom,"5e42109c":v.styles.table.fontSize,"84cc742e":v.styles.tableHead.fontWeight,"2dda9a58":v.styles.tableHeadItem.color,"3b8a6632":v.styles.tableBody.fontWeight,"1b78505c":v.styles.tableBodyRow.days.marginTop,"2cae37cb":v.styles.tableBodyItem.borderRadius,"3cd5d416":v.styles.tableBodyItem.color,"2b54c4e6":v.styles.tableBodyItem.hoverBackgroundColor,"848c7b96":v.styles.tableBodyItem.offset.color,"9b9dc346":v.styles.tableBodyItem.offset.opacity,"1ba13bf5":v.styles.tableBodyItem.offset.hoverColor,"4552e6ee":v.styles.tableBodyItem.current.border,"40049d06":v.styles.tableBodyItem.restricted.color,"53365ba5":v.styles.tableBodyItem.restricted.opacity,"073862fd":v.styles.tableBodyItem.selected.color,"6e38f1ef":v.styles.tableBodyItem.selected.backgroundColor}));const n=r,t=_,o=F(new Date().toDateString(),"YYYY-MM-DD"),a=[[{text:F(M().month(0),"MMM"),value:"01"},{text:F(M().month(1),"MMM"),value:"02"},{text:F(M().month(2),"MMM"),value:"03"}],[{text:F(M().month(3),"MMM"),value:"04"},{text:F(M().month(4),"MMM"),value:"05"},{text:F(M().month(5),"MMM"),value:"06"}],[{text:F(M().month(6),"MMM"),value:"07"},{text:F(M().month(7),"MMM"),value:"08"},{text:F(M().month(8),"MMM"),value:"09"}],[{text:F(M().month(9),"MMM"),value:"10"},{text:F(M().month(10),"MMM"),value:"11"},{text:F(M().month(11),"MMM"),value:"12"}]],e=d.ref(),i=d.ref(),s=d.ref(E()),u=d.ref(te()),c=d.ref(ee()),f=d.ref(),b=d.computed(()=>n.min&&Ye(n.min,"year")),w=d.computed(()=>n.min&&Ye(n.min,"month")),S=d.computed(()=>n.max&&Ye(n.max,"year")),A=d.computed(()=>n.max&&Ye(n.max,"month")),O=d.computed(()=>`${u.value}-${c.value}`),R=d.computed(()=>{const v=M(O.value),P=F(O.value,"YYYY-MM","subtract"),B=F(O.value,"YYYY-MM","add"),X=v.date(0),$=X.day(),se=v.daysInMonth(),Le=n.startWeekOnMonday?$===0?6:$:$!==6?$+1:0;return[...Array.from({length:Le},(ie,ke)=>+X.format("D")-Le+ke+1).map(ie=>({date:F(`${P}-${ie}`,"YYYY-MM-DD"),day:ie,offset:!0})),...Array.from({length:se},(ie,ke)=>ke+1).map(ie=>({date:F(`${O.value}-${ie}`,"YYYY-MM-DD"),day:ie,offset:!1})),...Array.from({length:(7-(Le+se)%7)%7},(ie,ke)=>ke+1).map(ie=>({date:F(`${B}-${ie}`,"YYYY-MM-DD"),day:ie,offset:!0}))].reduce((ie,ke,ft)=>(ft%7===0&&ie.push([]),ie[ie.length-1].push(ke),ie),[])}),V=d.computed(()=>{const v=[];for(let P=+u.value-100;P<=+u.value+100;P++)v.push(P+"");return v.reduce((P,B,X)=>(X%3===0&&P.push([]),P[P.length-1].push(B),P),[])});function q(v){return M().day(v).format("dd")}function ae(v){return n.startWeekOnMonday?q(v):q(v-1)}function E(){return n.yearPicker?"years":n.monthPicker?"months":"days"}function te(){return n.range&&(n.value[1]||n.value[0])?Ye(n.value[1]||n.value[0],"year"):n.value&&typeof n.value=="string"?Ye(n.value,"year"):F(new Date().toDateString(),"YYYY")}function ee(){return n.range&&(n.value[1]||n.value[0])?Ye(n.value[1]||n.value[0],"month"):n.value&&typeof n.value=="string"?Ye(n.value,"month"):F(new Date().toDateString(),"MM")}function U(v,P){return M(v).diff(P)}function _e(v){return n.monthPicker?G(F(u.value,"YYYY",v,"year")):me(F(O.value,"YYYY-MM",v))}function G(v){return b.value&&+b.value>+v||S.value&&+v>+S.value}function I(v){return n.yearPicker?n.range?[n.value[0],n.value[1]].includes(v):v===n.value:v===u.value}function me(v){return b.value&&w&&U(v,`${b.value}-${w.value}`)<0||S.value&&A&&U(`${S.value}-${A.value}`,v)<0}function be(v){return n.monthPicker?n.range?[n.value[0],n.value[1]].includes(`${u.value}-${v}`):`${u.value}-${v}`===n.value:v===c.value}function T(v){return n.min&&U(v,n.min)<0||n.max&&U(n.max,v)<0}function D(v){return n.range?[n.value[0],n.value[1]].includes(v):v===n.value}function k(v){if(n.monthPicker){s.value==="years"?s.value="months":s.value="years";return}["years","months"].includes(v)&&s.value===v?s.value="days":s.value=v}function H(v){u.value=v}function g(v){c.value=v}function j(v){const P=n.monthPicker?F(u.value,"YYYY",v,"year"):F(O.value,"YYYY-MM",v);H(Ye(P,"year")),!n.monthPicker&&g(Ye(P,"month"))}function z(v,P){(!n.yearPicker&&v===u.value||n.range&&(v===n.value[1]||v===n.value[0])||!n.range&&v===n.value||v===F(o,"YYYY"))&&(i.value=P)}function W(){var B;if(!e.value)return;const v=(B=i.value)==null?void 0:B.parentElement,P=parseFloat(window.getComputedStyle(v).height);v.style.scrollMarginTop=-((parseFloat(window.getComputedStyle(e.value).maxHeight)-(P*3+parseFloat(window.getComputedStyle(v).marginBlockEnd)*2))/2+P/2)+.5+"px",v.scrollIntoView({block:"center"})}function Z(v){if(!(!n.range||!n.value[0]))return n.value[1]?U(v,n.value[0])>0&&U(v,n.value[1])<0:f.value&&(U(v,n.value[0])>0&&U(v,f.value)<=0||U(n.value[0],v)>0&&U(f.value,v)<=0)}async function C(){k("years"),await d.nextTick(),W()}function oe(v){if(n.yearPicker){t("change",v);return}if(H(v),n.monthPicker){k("months");return}k("days")}function le(v){if(n.monthPicker){t("change",`${u.value}-${v}`);return}g(v),k("days")}function ue(v){t("change",v)}return d.watch(()=>n.opened,async v=>{s.value=E(),u.value=te(),c.value=ee(),!(!n.yearPicker||!v)&&(await d.nextTick(),W())}),(v,P)=>(d.openBlock(),d.createElementBlock("div",ui,[n.yearPicker?d.createCommentVNode("",!0):(d.openBlock(),d.createElementBlock("div",di,[d.createElementVNode("button",{class:d.normalizeClass(["sib-calendar__header__button",{"sib-calendar__header__button--restricted":_e("subtract"),"sib-calendar__header__button--invisible":!n.monthPicker&&s.value==="months"||s.value==="years"}]),disabled:_e("subtract"),"aria-label":n.monthPicker?"Previous year":"Previous month",type:"button",onClick:P[0]||(P[0]=B=>j("subtract"))},[d.renderSlot(v.$slots,"leftHeaderButtonIcon",{},()=>[P[6]||(P[6]=d.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[d.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.5",d:"m15 18-6-6 6-6"})],-1))],!0)],10,mi),d.createElementVNode("div",ci,[n.monthPicker?d.createCommentVNode("",!0):(d.openBlock(),d.createElementBlock("button",{key:0,class:"sib-calendar__header__date__item","aria-label":`${d.unref(F)(O.value,"MMMM")}-Open/close months overlay`,type:"button",onClick:P[1]||(P[1]=B=>k("months"))},d.toDisplayString(d.unref(F)(O.value,"MMMM")),9,Mi)),d.createElementVNode("button",{class:"sib-calendar__header__date__item","aria-label":`${d.unref(F)(u.value,"YYYY")}-Open/close years overlay`,type:"button",onClick:C},d.toDisplayString(d.unref(F)(u.value,"YYYY")),9,fi)]),d.createElementVNode("button",{class:d.normalizeClass(["sib-calendar__header__button",{"sib-calendar__header__button--restricted":_e("add"),"sib-calendar__header__button--invisible":!n.monthPicker&&s.value==="months"||s.value==="years"}]),disabled:_e("add"),"aria-label":n.monthPicker?"Next year":"Next month",type:"button",onClick:P[2]||(P[2]=B=>j("add"))},[d.renderSlot(v.$slots,"rightHeaderButtonIcon",{},()=>[P[7]||(P[7]=d.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[d.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.5",d:"m9 18 6-6-6-6"})],-1))],!0)],10,pi)])),d.withDirectives(d.createElementVNode("table",Yi,[d.createElementVNode("thead",hi,[d.createElementVNode("tr",yi,[(d.openBlock(),d.createElementBlock(d.Fragment,null,d.renderList(7,B=>d.createElementVNode("th",{key:B,class:"sib-calendar__table__head__item","aria-label":ae(B),role:"columnheader"},d.toDisplayString(ae(B)),9,Li)),64))])]),d.createElementVNode("tbody",{class:"sib-calendar__table__body",role:"rowgroup",onMouseleave:P[3]||(P[3]=B=>!n.monthPicker&&!n.yearPicker&&(f.value=void 0))},[(d.openBlock(!0),d.createElementBlock(d.Fragment,null,d.renderList(R.value,(B,X)=>(d.openBlock(),d.createElementBlock("tr",{key:`row-${X}`,class:"sib-calendar__table__body__row sib-calendar__table__body__row--days",role:"row"},[(d.openBlock(!0),d.createElementBlock(d.Fragment,null,d.renderList(B,$=>(d.openBlock(),d.createElementBlock("td",{key:$.date,class:d.normalizeClass(["sib-calendar__table__body__item sib-calendar__table__body__item--days",{"sib-calendar__table__body__item--offset":$.offset,"sib-calendar__table__body__item--current":!n.hideTodayMark&&$.date===d.unref(o),"sib-calendar__table__body__item--restricted":T($.date),"sib-calendar__table__body__item--selected":D($.date),"sib-calendar__table__body__item--hovered":Z($.date)}]),role:"gridcell",onMouseenter:se=>f.value=$.date},[d.createElementVNode("button",{disabled:T($.date),"data-test-id":$.date,type:"button",onClick:se=>ue($.date)},d.toDisplayString($.day),9,bi)],42,vi))),128))]))),128))],32)],512),[[d.vShow,s.value==="days"]]),d.withDirectives(d.createElementVNode("table",ki,[d.createElementVNode("tbody",{class:"sib-calendar__table__body",role:"rowgroup",onMouseleave:P[4]||(P[4]=B=>n.monthPicker&&(f.value=void 0))},[(d.openBlock(),d.createElementBlock(d.Fragment,null,d.renderList(a,(B,X)=>d.createElementVNode("tr",{key:`row-${X}`,class:"sib-calendar__table__body__row sib-calendar__table__body__row--months",role:"row"},[(d.openBlock(!0),d.createElementBlock(d.Fragment,null,d.renderList(B,$=>(d.openBlock(),d.createElementBlock("td",{key:$.value,class:d.normalizeClass(["sib-calendar__table__body__item sib-calendar__table__body__item--months",{"sib-calendar__table__body__item--current":!n.hideTodayMark&&n.monthPicker&&`${u.value}-${$.value}`===d.unref(F)(d.unref(o),"YYYY-MM"),"sib-calendar__table__body__item--restricted":me(`${u.value}-${$.value}`),"sib-calendar__table__body__item--selected":be($.value),"sib-calendar__table__body__item--hovered":n.monthPicker&&Z(`${u.value}-${$.value}`)}]),role:"gridcell",onMouseenter:se=>n.monthPicker&&(f.value=`${u.value}-${$.value}`)},[d.createElementVNode("button",{disabled:me(`${u.value}-${$.value}`),"data-test-id":`${u.value}-${$.value}`,type:"button",onClick:se=>le($.value)},d.toDisplayString($.text),9,gi)],42,wi))),128))])),64))],32)],512),[[d.vShow,s.value==="months"]]),d.withDirectives(d.createElementVNode("table",{ref_key:"table",ref:e,class:"sib-calendar__table sib-calendar__table--years",role:"grid","aria-labelledby":"Years calendar"},[d.createElementVNode("tbody",{class:"sib-calendar__table__body",role:"rowgroup",onMouseleave:P[5]||(P[5]=B=>n.yearPicker&&(f.value=void 0))},[(d.openBlock(!0),d.createElementBlock(d.Fragment,null,d.renderList(V.value,(B,X)=>(d.openBlock(),d.createElementBlock("tr",{key:`row-${X}`,class:"sib-calendar__table__body__row sib-calendar__table__body__row--years",role:"row"},[(d.openBlock(!0),d.createElementBlock(d.Fragment,null,d.renderList(B,$=>(d.openBlock(),d.createElementBlock("td",{ref_for:!0,ref:se=>z($,se),key:$,class:d.normalizeClass(["sib-calendar__table__body__item sib-calendar__table__body__item--years",{"sib-calendar__table__body__item--current":!n.hideTodayMark&&n.yearPicker&&$===d.unref(F)(d.unref(o),"YYYY"),"sib-calendar__table__body__item--restricted":G($),"sib-calendar__table__body__item--selected":I($),"sib-calendar__table__body__item--hovered":n.yearPicker&&Z($)}]),role:"gridcell",onMouseenter:se=>n.yearPicker&&(f.value=$)},[d.createElementVNode("button",{disabled:G($),"data-test-id":$,type:"button",onClick:se=>oe($)},d.toDisplayString($),9,Si)],42,Di))),128))]))),128))],32)],512),[[d.vShow,s.value==="years"]])]))}}),Gt=(r,_)=>{const n=r.__vccOpts||r;for(const[t,o]of _)n[t]=o;return n},xi=Gt(Hi,[["__scopeId","data-v-bb27fac7"]]);var Ue={exports:{}};Ue.exports,function(r,_){var n=200,t="__lodash_hash_undefined__",o=800,a=16,e=9007199254740991,i="[object Arguments]",s="[object Array]",u="[object AsyncFunction]",c="[object Boolean]",f="[object Date]",b="[object Error]",w="[object Function]",S="[object GeneratorFunction]",A="[object Map]",O="[object Number]",R="[object Null]",V="[object Object]",q="[object Proxy]",ae="[object RegExp]",E="[object Set]",te="[object String]",ee="[object Undefined]",U="[object WeakMap]",_e="[object ArrayBuffer]",G="[object DataView]",I="[object Float32Array]",me="[object Float64Array]",be="[object Int8Array]",T="[object Int16Array]",D="[object Int32Array]",k="[object Uint8Array]",H="[object Uint8ClampedArray]",g="[object Uint16Array]",j="[object Uint32Array]",z=/[\\^$.*+?()[\]{}|]/g,W=/^\[object .+?Constructor\]$/,Z=/^(?:0|[1-9]\d*)$/,C={};C[I]=C[me]=C[be]=C[T]=C[D]=C[k]=C[H]=C[g]=C[j]=!0,C[i]=C[s]=C[_e]=C[c]=C[G]=C[f]=C[b]=C[w]=C[A]=C[O]=C[V]=C[ae]=C[E]=C[te]=C[U]=!1;var oe=typeof p=="object"&&p&&p.Object===Object&&p,le=typeof self=="object"&&self&&self.Object===Object&&self,ue=oe||le||Function("return this")(),v=_&&!_.nodeType&&_,P=v&&!0&&r&&!r.nodeType&&r,B=P&&P.exports===v,X=B&&oe.process,$=function(){try{var l=P&&P.require&&P.require("util").types;return l||X&&X.binding&&X.binding("util")}catch{}}(),se=$&&$.isTypedArray;function Le(l,m,L){switch(L.length){case 0:return l.call(m);case 1:return l.call(m,L[0]);case 2:return l.call(m,L[0],L[1]);case 3:return l.call(m,L[0],L[1],L[2])}return l.apply(m,L)}function cs(l,m){for(var L=-1,x=Array(l);++L<l;)x[L]=m(L);return x}function ie(l){return function(m){return l(m)}}function ke(l,m){return l==null?void 0:l[m]}function ft(l,m){return function(L){return l(m(L))}}var yd=Array.prototype,Ld=Function.prototype,Xe=Object.prototype,pt=ue["__core-js_shared__"],Ze=Ld.toString,De=Xe.hasOwnProperty,Ms=function(){var l=/[^.]+$/.exec(pt&&pt.keys&&pt.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""}(),fs=Xe.toString,vd=Ze.call(Object),bd=RegExp("^"+Ze.call(De).replace(z,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Qe=B?ue.Buffer:void 0,ps=ue.Symbol,Ys=ue.Uint8Array;Qe&&Qe.allocUnsafe;var hs=ft(Object.getPrototypeOf,Object),ys=Object.create,kd=Xe.propertyIsEnumerable,wd=yd.splice,He=ps?ps.toStringTag:void 0,et=function(){try{var l=yt(Object,"defineProperty");return l({},"",{}),l}catch{}}(),gd=Qe?Qe.isBuffer:void 0,Ls=Math.max,Dd=Date.now,vs=yt(ue,"Map"),Fe=yt(Object,"create"),Sd=function(){function l(){}return function(m){if(!Te(m))return{};if(ys)return ys(m);l.prototype=m;var L=new l;return l.prototype=void 0,L}}();function xe(l){var m=-1,L=l==null?0:l.length;for(this.clear();++