var Lt=(o,s)=>()=>(s||o((s={exports:{}}).exports,s),s.exports);var Ht=Lt((Tt,It)=>{/* flatpickr v4.6.13,, @license MIT */(function(o,s){typeof Tt=="object"&&typeof It<"u"?It.exports=s():typeof define=="function"&&define.amd?define(s):(o=typeof globalThis<"u"?globalThis:o||self).flatpickr=s()})(void 0,function(){var o=function(){return(o=Object.assign||function(c){for(var f,t=1,H=arguments.length;t",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},S={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(c){var f=c%100;if(f>3&&f<21)return"th";switch(f%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},M=function(c,f){return f===void 0&&(f=2),("000"+c).slice(-1*f)},k=function(c){return c===!0?1:0};function R(c,f){var t;return function(){var H=this,Y=arguments;clearTimeout(t),t=setTimeout(function(){return c.apply(H,Y)},f)}}var _=function(c){return c instanceof Array?c:[c]};function W(c,f,t){if(t===!0)return c.classList.add(f);c.classList.remove(f)}function x(c,f,t){var H=window.document.createElement(c);return f=f||"",t=t||"",H.className=f,t!==void 0&&(H.textContent=t),H}function le(c){for(;c.firstChild;)c.removeChild(c.firstChild)}function de(c,f){return f(c)?c:c.parentNode?de(c.parentNode,f):void 0}function fe(c,f){var t=x("div","numInputWrapper"),H=x("input","numInput "+c),Y=x("span","arrowUp"),P=x("span","arrowDown");if(navigator.userAgent.indexOf("MSIE 9.0")===-1?H.type="number":(H.type="text",H.pattern="\\d*"),f!==void 0)for(var U in f)H.setAttribute(U,f[U]);return t.appendChild(H),t.appendChild(Y),t.appendChild(P),t}function ie(c){try{return typeof c.composedPath=="function"?c.composedPath()[0]:c.target}catch{return c.target}}var j=function(){},pe=function(c,f,t){return t.months[f?"shorthand":"longhand"][c]},Fe={D:j,F:function(c,f,t){c.setMonth(t.months.longhand.indexOf(f))},G:function(c,f){c.setHours((c.getHours()>=12?12:0)+parseFloat(f))},H:function(c,f){c.setHours(parseFloat(f))},J:function(c,f){c.setDate(parseFloat(f))},K:function(c,f,t){c.setHours(c.getHours()%12+12*k(new RegExp(t.amPM[1],"i").test(f)))},M:function(c,f,t){c.setMonth(t.months.shorthand.indexOf(f))},S:function(c,f){c.setSeconds(parseFloat(f))},U:function(c,f){return new Date(1e3*parseFloat(f))},W:function(c,f,t){var H=parseInt(f),Y=new Date(c.getFullYear(),0,2+7*(H-1),0,0,0,0);return Y.setDate(Y.getDate()-Y.getDay()+t.firstDayOfWeek),Y},Y:function(c,f){c.setFullYear(parseFloat(f))},Z:function(c,f){return new Date(f)},d:function(c,f){c.setDate(parseFloat(f))},h:function(c,f){c.setHours((c.getHours()>=12?12:0)+parseFloat(f))},i:function(c,f){c.setMinutes(parseFloat(f))},j:function(c,f){c.setDate(parseFloat(f))},l:j,m:function(c,f){c.setMonth(parseFloat(f)-1)},n:function(c,f){c.setMonth(parseFloat(f)-1)},s:function(c,f){c.setSeconds(parseFloat(f))},u:function(c,f){return new Date(parseFloat(f))},w:j,y:function(c,f){c.setFullYear(2e3+parseFloat(f))}},ce={D:"",F:"",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"",M:"",S:"(\\d\\d|\\d)",U:"(.+)",W:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",u:"(.+)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},ue={Z:function(c){return c.toISOString()},D:function(c,f,t){return f.weekdays.shorthand[ue.w(c,f,t)]},F:function(c,f,t){return pe(ue.n(c,f,t)-1,!1,f)},G:function(c,f,t){return M(ue.h(c,f,t))},H:function(c){return M(c.getHours())},J:function(c,f){return f.ordinal!==void 0?c.getDate()+f.ordinal(c.getDate()):c.getDate()},K:function(c,f){return f.amPM[k(c.getHours()>11)]},M:function(c,f){return pe(c.getMonth(),!0,f)},S:function(c){return M(c.getSeconds())},U:function(c){return c.getTime()/1e3},W:function(c,f,t){return t.getWeek(c)},Y:function(c){return M(c.getFullYear(),4)},d:function(c){return M(c.getDate())},h:function(c){return c.getHours()%12?c.getHours()%12:12},i:function(c){return M(c.getMinutes())},j:function(c){return c.getDate()},l:function(c,f){return f.weekdays.longhand[c.getDay()]},m:function(c){return M(c.getMonth()+1)},n:function(c){return c.getMonth()+1},s:function(c){return c.getSeconds()},u:function(c){return c.getTime()},w:function(c){return c.getDay()},y:function(c){return String(c.getFullYear()).substring(2)}},ve=function(c){var f=c.config,t=f===void 0?E:f,H=c.l10n,Y=H===void 0?S:H,P=c.isMobile,U=P!==void 0&&P;return function(ee,re,V){var ke=V||Y;return t.formatDate===void 0||U?re.split("").map(function(d,b,g){return ue[d]&&g[b-1]!=="\\"?ue[d](ee,ke,t):d!=="\\"?d:""}).join(""):t.formatDate(ee,re,ke)}},ye=function(c){var f=c.config,t=f===void 0?E:f,H=c.l10n,Y=H===void 0?S:H;return function(P,U,ee,re){if(P===0||P){var V,ke=re||Y,d=P;if(P instanceof Date)V=new Date(P.getTime());else if(typeof P!="string"&&P.toFixed!==void 0)V=new Date(P);else if(typeof P=="string"){var b=U||(t||E).dateFormat,g=String(P).trim();if(g==="today")V=new Date,ee=!0;else if(t&&t.parseDate)V=t.parseDate(P,b);else if(/Z$/.test(g)||/GMT$/.test(g))V=new Date(P);else{for(var I=void 0,p=[],w=0,B=0,T="";w=0?new Date:new Date(t.config.minDate.getTime()),l=Ae(t.config);i.setHours(l.hours,l.minutes,l.seconds,i.getMilliseconds()),t.selectedDates=[i],t.latestSelectedDateObj=i}n!==void 0&&n.type!=="blur"&&function(y){y.preventDefault();var v=y.type==="keydown",C=ie(y),D=C;t.amPM!==void 0&&C===t.amPM&&(t.amPM.textContent=t.l10n.amPM[k(t.amPM.textContent===t.l10n.amPM[0])]);var L=parseFloat(D.getAttribute("min")),A=parseFloat(D.getAttribute("max")),O=parseFloat(D.getAttribute("step")),F=parseInt(D.value,10),J=y.delta||(v?y.which===38?1:-1:0),G=F+O*J;if(D.value!==void 0&&D.value.length===2){var Z=D===t.hourElement,me=D===t.minuteElement;GA&&(G=D===t.hourElement?G-A-k(!t.amPM):L,me&&p(void 0,1,t.hourElement)),t.amPM&&Z&&(O===1?G+F===23:Math.abs(G-F)>O)&&(t.amPM.textContent=t.l10n.amPM[k(t.amPM.textContent===t.l10n.amPM[0])]),D.value=M(G)}}(n);var u=t._input.value;ee(),m(),t._input.value!==u&&t._debouncedChange()}function ee(){if(t.hourElement!==void 0&&t.minuteElement!==void 0){var n,i,l=(parseInt(t.hourElement.value.slice(-2),10)||0)%24,u=(parseInt(t.minuteElement.value,10)||0)%60,y=t.secondElement!==void 0?(parseInt(t.secondElement.value,10)||0)%60:0;t.amPM!==void 0&&(n=l,i=t.amPM.textContent,l=n%12+12*k(i===t.l10n.amPM[1]));var v=t.config.minTime!==void 0||t.config.minDate&&t.minDateHasTime&&t.latestSelectedDateObj&&te(t.latestSelectedDateObj,t.config.minDate,!0)===0,C=t.config.maxTime!==void 0||t.config.maxDate&&t.maxDateHasTime&&t.latestSelectedDateObj&&te(t.latestSelectedDateObj,t.config.maxDate,!0)===0;if(t.config.maxTime!==void 0&&t.config.minTime!==void 0&&t.config.minTime>t.config.maxTime){var D=De(t.config.minTime.getHours(),t.config.minTime.getMinutes(),t.config.minTime.getSeconds()),L=De(t.config.maxTime.getHours(),t.config.maxTime.getMinutes(),t.config.maxTime.getSeconds()),A=De(l,u,y);if(A>L&&A=12)]),t.secondElement!==void 0&&(t.secondElement.value=M(l)))}function ke(n){var i=ie(n),l=parseInt(i.value)+(n.delta||0);(l/1e3>1||n.key==="Enter"&&!/[^\d]/.test(l.toString()))&&Ne(l)}function d(n,i,l,u){return i instanceof Array?i.forEach(function(y){return d(n,y,l,u)}):n instanceof Array?n.forEach(function(y){return d(y,i,l,u)}):(n.addEventListener(i,l,u),void t._handlers.push({remove:function(){return n.removeEventListener(i,l,u)}}))}function b(){q("onChange")}function g(n,i){var l=n!==void 0?t.parseDate(n):t.latestSelectedDateObj||(t.config.minDate&&t.config.minDate>t.now?t.config.minDate:t.config.maxDate&&t.config.maxDate=0&&te(C,t.selectedDates[1])<=0}(i)&&!Xe(i)&&v.classList.add("inRange"),t.weekNumbers&&t.config.showMonths===1&&n!=="prevMonthDay"&&u%7==6&&t.weekNumbers.insertAdjacentHTML("beforeend",""+t.config.getWeek(i)+""),q("onDayCreate",v),v}function B(n){n.focus(),t.config.mode==="range"&&Re(n)}function T(n){for(var i=n>0?0:t.config.showMonths-1,l=n>0?t.config.showMonths:-1,u=i;u!=l;u+=n)for(var y=t.daysContainer.children[u],v=n>0?0:y.children.length-1,C=n>0?y.children.length:-1,D=v;D!=C;D+=n){var L=y.children[D];if(L.className.indexOf("hidden")===-1&&Te(L.dateObj))return L}}function N(n,i){var l=H(),u=Oe(l||document.body),y=n!==void 0?n:u?l:t.selectedDateElem!==void 0&&Oe(t.selectedDateElem)?t.selectedDateElem:t.todayDateElem!==void 0&&Oe(t.todayDateElem)?t.todayDateElem:T(i>0?1:-1);y===void 0?t._input.focus():u?function(v,C){for(var D=v.className.indexOf("Month")===-1?v.dateObj.getMonth():t.currentMonth,L=C>0?t.config.showMonths:-1,A=C>0?1:-1,O=D-t.currentMonth;O!=L;O+=A)for(var F=t.daysContainer.children[O],J=D-t.currentMonth===O?v.$i+C:C<0?F.children.length-1:0,G=F.children.length,Z=J;Z>=0&&Z0?G:-1);Z+=A){var me=F.children[Z];if(me.className.indexOf("hidden")===-1&&Te(me.dateObj)&&Math.abs(v.$i-Z)>=Math.abs(C))return B(me)}t.changeMonth(A),N(T(A),0)}(y,i):B(y)}function se(n,i){for(var l=(new Date(n,i,1).getDay()-t.l10n.firstDayOfWeek+7)%7,u=t.utils.getDaysInMonth((i-1+12)%12,n),y=t.utils.getDaysInMonth(i,n),v=window.document.createDocumentFragment(),C=t.config.showMonths>1,D=C?"prevMonthDay hidden":"prevMonthDay",L=C?"nextMonthDay hidden":"nextMonthDay",A=u+1-l,O=0;A<=u;A++,O++)v.appendChild(w("flatpickr-day "+D,new Date(n,i-1,A),0,O));for(A=1;A<=y;A++,O++)v.appendChild(w("flatpickr-day",new Date(n,i,A),0,O));for(var F=y+1;F<=42-l&&(t.config.showMonths===1||O%7!=0);F++,O++)v.appendChild(w("flatpickr-day "+L,new Date(n,i+1,F%y),0,O));var J=x("div","dayContainer");return J.appendChild(v),J}function z(){if(t.daysContainer!==void 0){le(t.daysContainer),t.weekNumbers&&le(t.weekNumbers);for(var n=document.createDocumentFragment(),i=0;i1||t.config.monthSelectorType!=="dropdown")){var n=function(u){return!(t.config.minDate!==void 0&&t.currentYear===t.config.minDate.getFullYear()&&ut.config.maxDate.getMonth())};t.monthsDropdownContainer.tabIndex=-1,t.monthsDropdownContainer.innerHTML="";for(var i=0;i<12;i++)if(n(i)){var l=x("option","flatpickr-monthDropdown-month");l.value=new Date(t.currentYear,i).getMonth().toString(),l.textContent=pe(i,t.config.shorthandCurrentMonth,t.l10n),l.tabIndex=-1,t.currentMonth===i&&(l.selected=!0),t.monthsDropdownContainer.appendChild(l)}}}function Q(){var n,i=x("div","flatpickr-month"),l=window.document.createDocumentFragment();t.config.showMonths>1||t.config.monthSelectorType==="static"?n=x("span","cur-month"):(t.monthsDropdownContainer=x("select","flatpickr-monthDropdown-months"),t.monthsDropdownContainer.setAttribute("aria-label",t.l10n.monthAriaLabel),d(t.monthsDropdownContainer,"change",function(C){var D=ie(C),L=parseInt(D.value,10);t.changeMonth(L-t.currentMonth),q("onMonthChange")}),ne(),n=t.monthsDropdownContainer);var u=fe("cur-year",{tabindex:"-1"}),y=u.getElementsByTagName("input")[0];y.setAttribute("aria-label",t.l10n.yearAriaLabel),t.config.minDate&&y.setAttribute("min",t.config.minDate.getFullYear().toString()),t.config.maxDate&&(y.setAttribute("max",t.config.maxDate.getFullYear().toString()),y.disabled=!!t.config.minDate&&t.config.minDate.getFullYear()===t.config.maxDate.getFullYear());var v=x("div","flatpickr-current-month");return v.appendChild(n),v.appendChild(u),l.appendChild(v),i.appendChild(l),{container:i,yearElement:y,monthElement:n}}function Me(){le(t.monthNav),t.monthNav.appendChild(t.prevMonthNav),t.config.showMonths&&(t.yearElements=[],t.monthElements=[]);for(var n=t.config.showMonths;n--;){var i=Q();t.yearElements.push(i.yearElement),t.monthElements.push(i.monthElement),t.monthNav.appendChild(i.container)}t.monthNav.appendChild(t.nextMonthNav)}function Le(){t.weekdayContainer?le(t.weekdayContainer):t.weekdayContainer=x("div","flatpickr-weekdays");for(var n=t.config.showMonths;n--;){var i=x("div","flatpickr-weekdaycontainer");t.weekdayContainer.appendChild(i)}return xe(),t.weekdayContainer}function xe(){if(t.weekdayContainer){var n=t.l10n.firstDayOfWeek,i=s(t.l10n.weekdays.shorthand);n>0&&n `+i.join("")+` `}}function Je(n,i){i===void 0&&(i=!0);var l=i?n:n-t.currentMonth;l<0&&t._hidePrevMonthArrow===!0||l>0&&t._hideNextMonthArrow===!0||(t.currentMonth+=l,(t.currentMonth<0||t.currentMonth>11)&&(t.currentYear+=t.currentMonth>11?1:-1,t.currentMonth=(t.currentMonth+12)%12,q("onYearChange"),ne()),z(),q("onMonthChange"),a())}function _e(n){return t.calendarContainer.contains(n)}function je(n){if(t.isOpen&&!t.config.inline){var i=ie(n),l=_e(i),u=!(i===t.input||i===t.altInput||t.element.contains(i)||n.path&&n.path.indexOf&&(~n.path.indexOf(t.input)||~n.path.indexOf(t.altInput)))&&!l&&!_e(n.relatedTarget),y=!t.config.ignoredFocusElements.some(function(v){return v.contains(i)});u&&y&&(t.config.allowInput&&t.setDate(t._input.value,!1,t.config.altInput?t.config.altFormat:t.config.dateFormat),t.timeContainer!==void 0&&t.minuteElement!==void 0&&t.hourElement!==void 0&&t.input.value!==""&&t.input.value!==void 0&&U(),t.close(),t.config&&t.config.mode==="range"&&t.selectedDates.length===1&&t.clear(!1))}}function Ne(n){if(!(!n||t.config.minDate&&nt.config.maxDate.getFullYear())){var i=n,l=t.currentYear!==i;t.currentYear=i||t.currentYear,t.config.maxDate&&t.currentYear===t.config.maxDate.getFullYear()?t.currentMonth=Math.min(t.config.maxDate.getMonth(),t.currentMonth):t.config.minDate&&t.currentYear===t.config.minDate.getFullYear()&&(t.currentMonth=Math.max(t.config.minDate.getMonth(),t.currentMonth)),l&&(t.redraw(),q("onYearChange"),ne())}}function Te(n,i){var l;i===void 0&&(i=!0);var u=t.parseDate(n,void 0,i);if(t.config.minDate&&u&&te(u,t.config.minDate,i!==void 0?i:!t.minDateHasTime)<0||t.config.maxDate&&u&&te(u,t.config.maxDate,i!==void 0?i:!t.maxDateHasTime)>0)return!1;if(!t.config.enable&&t.config.disable.length===0)return!0;if(u===void 0)return!1;for(var y=!!t.config.enable,v=(l=t.config.enable)!==null&&l!==void 0?l:t.config.disable,C=0,D=void 0;C=D.from.getTime()&&u.getTime()<=D.to.getTime())return y}return!y}function Oe(n){return t.daysContainer!==void 0&&n.className.indexOf("hidden")===-1&&n.className.indexOf("flatpickr-disabled")===-1&&t.daysContainer.contains(n)}function ut(n){var i=n.target===t._input,l=t._input.value.trimEnd()!==r();!i||!l||n.relatedTarget&&_e(n.relatedTarget)||t.setDate(t._input.value,!0,n.target===t.altInput?t.config.altFormat:t.config.dateFormat)}function Ge(n){var i=ie(n),l=t.config.wrap?c.contains(i):i===t._input,u=t.config.allowInput,y=t.isOpen&&(!u||!l),v=t.config.inline&&l&&!u;if(n.keyCode===13&&l){if(u)return t.setDate(t._input.value,!0,i===t.altInput?t.config.altFormat:t.config.dateFormat),t.close(),i.blur();t.open()}else if(_e(i)||y||v){var C=!!t.timeContainer&&t.timeContainer.contains(i);switch(n.keyCode){case 13:C?(n.preventDefault(),U(),X()):qe(n);break;case 27:n.preventDefault(),X();break;case 8:case 46:l&&!t.config.allowInput&&(n.preventDefault(),t.clear());break;case 37:case 39:if(C||l)t.hourElement&&t.hourElement.focus();else{n.preventDefault();var D=H();if(t.daysContainer!==void 0&&(u===!1||D&&Oe(D))){var L=n.keyCode===39?1:-1;n.ctrlKey?(n.stopPropagation(),Je(L),N(T(1),0)):N(void 0,L)}}break;case 38:case 40:n.preventDefault();var A=n.keyCode===40?1:-1;t.daysContainer&&i.$i!==void 0||i===t.input||i===t.altInput?n.ctrlKey?(n.stopPropagation(),Ne(t.currentYear-A),N(T(1),0)):C||N(void 0,7*A):i===t.currentYearElement?Ne(t.currentYear-A):t.config.enableTime&&(!C&&t.hourElement&&t.hourElement.focus(),U(n),t._debouncedChange());break;case 9:if(C){var O=[t.hourElement,t.minuteElement,t.secondElement,t.amPM].concat(t.pluginElements).filter(function(G){return G}),F=O.indexOf(i);if(F!==-1){var J=O[F+(n.shiftKey?-1:1)];n.preventDefault(),(J||t._input).focus()}}else!t.config.noCalendar&&t.daysContainer&&t.daysContainer.contains(i)&&n.shiftKey&&(n.preventDefault(),t._input.focus())}}if(t.amPM!==void 0&&i===t.amPM)switch(n.key){case t.l10n.amPM[0].charAt(0):case t.l10n.amPM[0].charAt(0).toLowerCase():t.amPM.textContent=t.l10n.amPM[0],ee(),m();break;case t.l10n.amPM[1].charAt(0):case t.l10n.amPM[1].charAt(0).toLowerCase():t.amPM.textContent=t.l10n.amPM[1],ee(),m()}(l||_e(i))&&q("onKeyDown",n)}function Re(n,i){if(i===void 0&&(i="flatpickr-day"),t.selectedDates.length===1&&(!n||n.classList.contains(i)&&!n.classList.contains("flatpickr-disabled"))){for(var l=n?n.dateObj.getTime():t.days.firstElementChild.dateObj.getTime(),u=t.parseDate(t.selectedDates[0],void 0,!0).getTime(),y=Math.min(l,t.selectedDates[0].getTime()),v=Math.max(l,t.selectedDates[0].getTime()),C=!1,D=0,L=0,A=y;Ay&&AD)?D=A:A>u&&(!L||A ."+i)).forEach(function(O){var F,J,G,Z=O.dateObj.getTime(),me=D>0&&Z0&&Z>L;if(me)return O.classList.add("notAllowed"),void["inRange","startRange","endRange"].forEach(function(He){O.classList.remove(He)});C&&!me||(["startRange","inRange","endRange","notAllowed"].forEach(function(He){O.classList.remove(He)}),n!==void 0&&(n.classList.add(l<=t.selectedDates[0].getTime()?"startRange":"endRange"),ul&&Z===u&&O.classList.add("endRange"),Z>=D&&(L===0||Z<=L)&&(J=u,G=l,(F=Z)>Math.min(J,G)&&F0||l.getMinutes()>0||l.getSeconds()>0),t.selectedDates&&(t.selectedDates=t.selectedDates.filter(function(y){return Te(y)}),t.selectedDates.length||n!=="min"||re(l),m()),t.daysContainer&&(rt(),l!==void 0?t.currentYearElement[n]=l.getFullYear().toString():t.currentYearElement.removeAttribute(n),t.currentYearElement.disabled=!!u&&l!==void 0&&u.getFullYear()===l.getFullYear())}}function ot(){return t.config.wrap?c.querySelector("[data-input]"):c}function $e(){typeof t.config.locale!="object"&&$.l10ns[t.config.locale]===void 0&&t.config.errorHandler(new Error("flatpickr: invalid locale "+t.config.locale)),t.l10n=o(o({},$.l10ns.default),typeof t.config.locale=="object"?t.config.locale:t.config.locale!=="default"?$.l10ns[t.config.locale]:void 0),ce.D="("+t.l10n.weekdays.shorthand.join("|")+")",ce.l="("+t.l10n.weekdays.longhand.join("|")+")",ce.M="("+t.l10n.months.shorthand.join("|")+")",ce.F="("+t.l10n.months.longhand.join("|")+")",ce.K="("+t.l10n.amPM[0]+"|"+t.l10n.amPM[1]+"|"+t.l10n.amPM[0].toLowerCase()+"|"+t.l10n.amPM[1].toLowerCase()+")",o(o({},f),JSON.parse(JSON.stringify(c.dataset||{}))).time_24hr===void 0&&$.defaultConfig.time_24hr===void 0&&(t.config.time_24hr=t.l10n.time_24hr),t.formatDate=ve(t),t.parseDate=ye({config:t.config,l10n:t.l10n})}function ze(n){if(typeof t.config.position!="function"){if(t.calendarContainer!==void 0){q("onPreCalendarPosition");var i=n||t._positionElement,l=Array.prototype.reduce.call(t.calendarContainer.children,function(Qe,et){return Qe+et.offsetHeight},0),u=t.calendarContainer.offsetWidth,y=t.config.position.split(" "),v=y[0],C=y.length>1?y[1]:null,D=i.getBoundingClientRect(),L=window.innerHeight-D.bottom,A=v==="above"||v!=="below"&&Ll,O=window.pageYOffset+D.top+(A?-l-2:i.offsetHeight+2);if(W(t.calendarContainer,"arrowTop",!A),W(t.calendarContainer,"arrowBottom",A),!t.config.inline){var F=window.pageXOffset+D.left,J=!1,G=!1;C==="center"?(F-=(u-D.width)/2,J=!0):C==="right"&&(F-=u-D.width,G=!0),W(t.calendarContainer,"arrowLeft",!J&&!G),W(t.calendarContainer,"arrowCenter",J),W(t.calendarContainer,"arrowRight",G);var Z=window.document.body.offsetWidth-(window.pageXOffset+D.right),me=F+u>window.document.body.offsetWidth,He=Z+u>window.document.body.offsetWidth;if(W(t.calendarContainer,"rightMost",me),!t.config.static)if(t.calendarContainer.style.top=O+"px",me)if(He){var Ze=function(){for(var Qe=null,et=0;ett.currentMonth+t.config.showMonths-1)&&t.config.mode!=="range";if(t.selectedDateElem=l,t.config.mode==="single")t.selectedDates=[u];else if(t.config.mode==="multiple"){var v=Xe(u);v?t.selectedDates.splice(parseInt(v),1):t.selectedDates.push(u)}else t.config.mode==="range"&&(t.selectedDates.length===2&&t.clear(!1,!1),t.latestSelectedDateObj=u,t.selectedDates.push(u),te(u,t.selectedDates[0],!0)!==0&&t.selectedDates.sort(function(A,O){return A.getTime()-O.getTime()}));if(ee(),y){var C=t.currentYear!==u.getFullYear();t.currentYear=u.getFullYear(),t.currentMonth=u.getMonth(),C&&(q("onYearChange"),ne()),q("onMonthChange")}if(a(),z(),m(),y||t.config.mode==="range"||t.config.showMonths!==1?t.selectedDateElem!==void 0&&t.hourElement===void 0&&t.selectedDateElem&&t.selectedDateElem.focus():B(l),t.hourElement!==void 0&&t.hourElement!==void 0&&t.hourElement.focus(),t.config.closeOnSelect){var D=t.config.mode==="single"&&!t.config.enableTime,L=t.config.mode==="range"&&t.selectedDates.length===2&&!t.config.enableTime;(D||L)&&X()}b()}}t.parseDate=ye({config:t.config,l10n:t.l10n}),t._handlers=[],t.pluginElements=[],t.loadedPlugins=[],t._bind=d,t._setHoursFromDate=re,t._positionCalendar=ze,t.changeMonth=Je,t.changeYear=Ne,t.clear=function(n,i){if(n===void 0&&(n=!0),i===void 0&&(i=!0),t.input.value="",t.altInput!==void 0&&(t.altInput.value=""),t.mobileInput!==void 0&&(t.mobileInput.value=""),t.selectedDates=[],t.latestSelectedDateObj=void 0,i===!0&&(t.currentYear=t._initialDate.getFullYear(),t.currentMonth=t._initialDate.getMonth()),t.config.enableTime===!0){var l=Ae(t.config),u=l.hours,y=l.minutes,v=l.seconds;V(u,y,v)}t.redraw(),n&&q("onChange")},t.close=function(){t.isOpen=!1,t.isMobile||(t.calendarContainer!==void 0&&t.calendarContainer.classList.remove("open"),t._input!==void 0&&t._input.classList.remove("active")),q("onClose")},t.onMouseOver=Re,t._createElement=x,t.createDay=w,t.destroy=function(){t.config!==void 0&&q("onDestroy");for(var n=t._handlers.length;n--;)t._handlers[n].remove();if(t._handlers=[],t.mobileInput)t.mobileInput.parentNode&&t.mobileInput.parentNode.removeChild(t.mobileInput),t.mobileInput=void 0;else if(t.calendarContainer&&t.calendarContainer.parentNode)if(t.config.static&&t.calendarContainer.parentNode){var i=t.calendarContainer.parentNode;if(i.lastChild&&i.removeChild(i.lastChild),i.parentNode){for(;i.firstChild;)i.parentNode.insertBefore(i.firstChild,i);i.parentNode.removeChild(i)}}else t.calendarContainer.parentNode.removeChild(t.calendarContainer);t.altInput&&(t.input.type="text",t.altInput.parentNode&&t.altInput.parentNode.removeChild(t.altInput),delete t.altInput),t.input&&(t.input.type=t.input._type,t.input.classList.remove("flatpickr-input"),t.input.removeAttribute("readonly")),["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","monthsDropdownContainer","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach(function(l){try{delete t[l]}catch{}})},t.isEnabled=Te,t.jumpToDate=g,t.updateValue=m,t.open=function(n,i){if(i===void 0&&(i=t._positionElement),t.isMobile===!0){if(n){n.preventDefault();var l=ie(n);l&&l.blur()}return t.mobileInput!==void 0&&(t.mobileInput.focus(),t.mobileInput.click()),void q("onOpen")}if(!(t._input.disabled||t.config.inline)){var u=t.isOpen;t.isOpen=!0,u||(t.calendarContainer.classList.add("open"),t._input.classList.add("active"),q("onOpen"),ze(i)),t.config.enableTime===!0&&t.config.noCalendar===!0&&(t.config.allowInput!==!1||n!==void 0&&t.timeContainer.contains(n.relatedTarget)||setTimeout(function(){return t.hourElement.select()},50))}},t.redraw=rt,t.set=function(n,i){if(n!==null&&typeof n=="object")for(var l in Object.assign(t.config,n),n)Be[l]!==void 0&&Be[l].forEach(function(u){return u()});else t.config[n]=i,Be[n]!==void 0?Be[n].forEach(function(u){return u()}):e.indexOf(n)>-1&&(t.config[n]=_(i));t.redraw(),m(!0)},t.setDate=function(n,i,l){if(i===void 0&&(i=!1),l===void 0&&(l=t.config.dateFormat),n!==0&&!n||n instanceof Array&&n.length===0)return t.clear(i);st(n,l),t.latestSelectedDateObj=t.selectedDates[t.selectedDates.length-1],t.redraw(),g(void 0,i),re(),t.selectedDates.length===0&&t.clear(!1),m(i),i&&q("onChange")},t.toggle=function(n){if(t.isOpen===!0)return t.close();t.open(n)};var Be={locale:[$e,xe],showMonths:[Me,P,Le],minDate:[g],maxDate:[g],positionElement:[We],clickOpens:[function(){t.config.clickOpens===!0?(d(t._input,"focus",t.open),d(t._input,"click",t.open)):(t._input.removeEventListener("focus",t.open),t._input.removeEventListener("click",t.open))}]};function st(n,i){var l=[];if(n instanceof Array)l=n.map(function(u){return t.parseDate(u,i)});else if(n instanceof Date||typeof n=="number")l=[t.parseDate(n,i)];else if(typeof n=="string")switch(t.config.mode){case"single":case"time":l=[t.parseDate(n,i)];break;case"multiple":l=n.split(t.config.conjunction).map(function(u){return t.parseDate(u,i)});break;case"range":l=n.split(t.l10n.rangeSeparator).map(function(u){return t.parseDate(u,i)})}else t.config.errorHandler(new Error("Invalid date supplied: "+JSON.stringify(n)));t.selectedDates=t.config.allowInvalidPreload?l:l.filter(function(u){return u instanceof Date&&Te(u,!1)}),t.config.mode==="range"&&t.selectedDates.sort(function(u,y){return u.getTime()-y.getTime()})}function Pe(n){return n.slice().map(function(i){return typeof i=="string"||typeof i=="number"||i instanceof Date?t.parseDate(i,void 0,!0):i&&typeof i=="object"&&i.from&&i.to?{from:t.parseDate(i.from,void 0),to:t.parseDate(i.to,void 0)}:i}).filter(function(i){return i})}function We(){t._positionElement=t.config.positionElement||t._input}function q(n,i){if(t.config!==void 0){var l=t.config[n];if(l!==void 0&&l.length>0)for(var u=0;l[u]&&u1||t.config.monthSelectorType==="static"?t.monthElements[i].textContent=pe(l.getMonth(),t.config.shorthandCurrentMonth,t.l10n)+" ":t.monthsDropdownContainer.value=l.getMonth().toString(),n.value=l.getFullYear().toString()}),t._hidePrevMonthArrow=t.config.minDate!==void 0&&(t.currentYear===t.config.minDate.getFullYear()?t.currentMonth<=t.config.minDate.getMonth():t.currentYeart.config.maxDate.getMonth():t.currentYear>t.config.maxDate.getFullYear()))}function r(n){var i=n||(t.config.altInput?t.config.altFormat:t.config.dateFormat);return t.selectedDates.map(function(l){return t.formatDate(l,i)}).filter(function(l,u,y){return t.config.mode!=="range"||t.config.enableTime||y.indexOf(l)===u}).join(t.config.mode!=="range"?t.config.conjunction:t.l10n.rangeSeparator)}function m(n){n===void 0&&(n=!0),t.mobileInput!==void 0&&t.mobileFormatStr&&(t.mobileInput.value=t.latestSelectedDateObj!==void 0?t.formatDate(t.latestSelectedDateObj,t.mobileFormatStr):""),t.input.value=r(t.config.dateFormat),t.altInput!==void 0&&(t.altInput.value=r(t.config.altFormat)),n!==!1&&q("onValueUpdate")}function h(n){var i=ie(n),l=t.prevMonthNav.contains(i),u=t.nextMonthNav.contains(i);l||u?Je(l?-1:1):t.yearElements.indexOf(i)>=0?i.select():i.classList.contains("arrowUp")?t.changeYear(t.currentYear+1):i.classList.contains("arrowDown")&&t.changeYear(t.currentYear-1)}return function(){t.element=t.input=c,t.isOpen=!1,function(){var i=["wrap","weekNumbers","allowInput","allowInvalidPreload","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],l=o(o({},JSON.parse(JSON.stringify(c.dataset||{}))),f),u={};t.config.parseDate=l.parseDate,t.config.formatDate=l.formatDate,Object.defineProperty(t.config,"enable",{get:function(){return t.config._enable},set:function(F){t.config._enable=Pe(F)}}),Object.defineProperty(t.config,"disable",{get:function(){return t.config._disable},set:function(F){t.config._disable=Pe(F)}});var y=l.mode==="time";if(!l.dateFormat&&(l.enableTime||y)){var v=$.defaultConfig.dateFormat||E.dateFormat;u.dateFormat=l.noCalendar||y?"H:i"+(l.enableSeconds?":S":""):v+" H:i"+(l.enableSeconds?":S":"")}if(l.altInput&&(l.enableTime||y)&&!l.altFormat){var C=$.defaultConfig.altFormat||E.altFormat;u.altFormat=l.noCalendar||y?"h:i"+(l.enableSeconds?":S K":" K"):C+" h:i"+(l.enableSeconds?":S":"")+" K"}Object.defineProperty(t.config,"minDate",{get:function(){return t.config._minDate},set:it("min")}),Object.defineProperty(t.config,"maxDate",{get:function(){return t.config._maxDate},set:it("max")});var D=function(F){return function(J){t.config[F==="min"?"_minTime":"_maxTime"]=t.parseDate(J,"H:i:S")}};Object.defineProperty(t.config,"minTime",{get:function(){return t.config._minTime},set:D("min")}),Object.defineProperty(t.config,"maxTime",{get:function(){return t.config._maxTime},set:D("max")}),l.mode==="time"&&(t.config.noCalendar=!0,t.config.enableTime=!0),Object.assign(t.config,u,l);for(var L=0;L-1?t.config[O]=_(A[O]).map(Y).concat(t.config[O]):l[O]===void 0&&(t.config[O]=A[O])}l.altInputClass||(t.config.altInputClass=ot().className+" "+t.config.altInputClass),q("onParseConfig")}(),$e(),function(){if(t.input=ot(),!t.input)return void t.config.errorHandler(new Error("Invalid input element specified"));t.input._type=t.input.type,t.input.type="text",t.input.classList.add("flatpickr-input"),t._input=t.input,t.config.altInput&&(t.altInput=x(t.input.nodeName,t.config.altInputClass),t._input=t.altInput,t.altInput.placeholder=t.input.placeholder,t.altInput.disabled=t.input.disabled,t.altInput.required=t.input.required,t.altInput.tabIndex=t.input.tabIndex,t.altInput.type="text",t.input.setAttribute("type","hidden"),!t.config.static&&t.input.parentNode&&t.input.parentNode.insertBefore(t.altInput,t.input.nextSibling)),t.config.allowInput||t._input.setAttribute("readonly","readonly"),We()}(),function(){t.selectedDates=[],t.now=t.parseDate(t.config.now)||new Date;var i=t.config.defaultDate||(t.input.nodeName!=="INPUT"&&t.input.nodeName!=="TEXTAREA"||!t.input.placeholder||t.input.value!==t.input.placeholder?t.input.value:null);i&&st(i,t.config.dateFormat),t._initialDate=t.selectedDates.length>0?t.selectedDates[0]:t.config.minDate&&t.config.minDate.getTime()>t.now.getTime()?t.config.minDate:t.config.maxDate&&t.config.maxDate.getTime()0&&(t.latestSelectedDateObj=t.selectedDates[0]),t.config.minTime!==void 0&&(t.config.minTime=t.parseDate(t.config.minTime,"H:i")),t.config.maxTime!==void 0&&(t.config.maxTime=t.parseDate(t.config.maxTime,"H:i")),t.minDateHasTime=!!t.config.minDate&&(t.config.minDate.getHours()>0||t.config.minDate.getMinutes()>0||t.config.minDate.getSeconds()>0),t.maxDateHasTime=!!t.config.maxDate&&(t.config.maxDate.getHours()>0||t.config.maxDate.getMinutes()>0||t.config.maxDate.getSeconds()>0)}(),t.utils={getDaysInMonth:function(i,l){return i===void 0&&(i=t.currentMonth),l===void 0&&(l=t.currentYear),i===1&&(l%4==0&&l%100!=0||l%400==0)?29:t.l10n.daysInMonth[i]}},t.isMobile||function(){var i=window.document.createDocumentFragment();if(t.calendarContainer=x("div","flatpickr-calendar"),t.calendarContainer.tabIndex=-1,!t.config.noCalendar){if(i.appendChild((t.monthNav=x("div","flatpickr-months"),t.yearElements=[],t.monthElements=[],t.prevMonthNav=x("span","flatpickr-prev-month"),t.prevMonthNav.innerHTML=t.config.prevArrow,t.nextMonthNav=x("span","flatpickr-next-month"),t.nextMonthNav.innerHTML=t.config.nextArrow,Me(),Object.defineProperty(t,"_hidePrevMonthArrow",{get:function(){return t.__hidePrevMonthArrow},set:function(D){t.__hidePrevMonthArrow!==D&&(W(t.prevMonthNav,"flatpickr-disabled",D),t.__hidePrevMonthArrow=D)}}),Object.defineProperty(t,"_hideNextMonthArrow",{get:function(){return t.__hideNextMonthArrow},set:function(D){t.__hideNextMonthArrow!==D&&(W(t.nextMonthNav,"flatpickr-disabled",D),t.__hideNextMonthArrow=D)}}),t.currentYearElement=t.yearElements[0],a(),t.monthNav)),t.innerContainer=x("div","flatpickr-innerContainer"),t.config.weekNumbers){var l=function(){t.calendarContainer.classList.add("hasWeeks");var D=x("div","flatpickr-weekwrapper");D.appendChild(x("span","flatpickr-weekday",t.l10n.weekAbbreviation));var L=x("div","flatpickr-weeks");return D.appendChild(L),{weekWrapper:D,weekNumbers:L}}(),u=l.weekWrapper,y=l.weekNumbers;t.innerContainer.appendChild(u),t.weekNumbers=y,t.weekWrapper=u}t.rContainer=x("div","flatpickr-rContainer"),t.rContainer.appendChild(Le()),t.daysContainer||(t.daysContainer=x("div","flatpickr-days"),t.daysContainer.tabIndex=-1),z(),t.rContainer.appendChild(t.daysContainer),t.innerContainer.appendChild(t.rContainer),i.appendChild(t.innerContainer)}t.config.enableTime&&i.appendChild(function(){t.calendarContainer.classList.add("hasTime"),t.config.noCalendar&&t.calendarContainer.classList.add("noCalendar");var D=Ae(t.config);t.timeContainer=x("div","flatpickr-time"),t.timeContainer.tabIndex=-1;var L=x("span","flatpickr-time-separator",":"),A=fe("flatpickr-hour",{"aria-label":t.l10n.hourAriaLabel});t.hourElement=A.getElementsByTagName("input")[0];var O=fe("flatpickr-minute",{"aria-label":t.l10n.minuteAriaLabel});if(t.minuteElement=O.getElementsByTagName("input")[0],t.hourElement.tabIndex=t.minuteElement.tabIndex=-1,t.hourElement.value=M(t.latestSelectedDateObj?t.latestSelectedDateObj.getHours():t.config.time_24hr?D.hours:function(J){switch(J%24){case 0:case 12:return 12;default:return J%12}}(D.hours)),t.minuteElement.value=M(t.latestSelectedDateObj?t.latestSelectedDateObj.getMinutes():D.minutes),t.hourElement.setAttribute("step",t.config.hourIncrement.toString()),t.minuteElement.setAttribute("step",t.config.minuteIncrement.toString()),t.hourElement.setAttribute("min",t.config.time_24hr?"0":"1"),t.hourElement.setAttribute("max",t.config.time_24hr?"23":"12"),t.hourElement.setAttribute("maxlength","2"),t.minuteElement.setAttribute("min","0"),t.minuteElement.setAttribute("max","59"),t.minuteElement.setAttribute("maxlength","2"),t.timeContainer.appendChild(A),t.timeContainer.appendChild(L),t.timeContainer.appendChild(O),t.config.time_24hr&&t.timeContainer.classList.add("time24hr"),t.config.enableSeconds){t.timeContainer.classList.add("hasSeconds");var F=fe("flatpickr-second");t.secondElement=F.getElementsByTagName("input")[0],t.secondElement.value=M(t.latestSelectedDateObj?t.latestSelectedDateObj.getSeconds():D.seconds),t.secondElement.setAttribute("step",t.minuteElement.getAttribute("step")),t.secondElement.setAttribute("min","0"),t.secondElement.setAttribute("max","59"),t.secondElement.setAttribute("maxlength","2"),t.timeContainer.appendChild(x("span","flatpickr-time-separator",":")),t.timeContainer.appendChild(F)}return t.config.time_24hr||(t.amPM=x("span","flatpickr-am-pm",t.l10n.amPM[k((t.latestSelectedDateObj?t.hourElement.value:t.config.defaultHour)>11)]),t.amPM.title=t.l10n.toggleTitle,t.amPM.tabIndex=-1,t.timeContainer.appendChild(t.amPM)),t.timeContainer}()),W(t.calendarContainer,"rangeMode",t.config.mode==="range"),W(t.calendarContainer,"animate",t.config.animate===!0),W(t.calendarContainer,"multiMonth",t.config.showMonths>1),t.calendarContainer.appendChild(i);var v=t.config.appendTo!==void 0&&t.config.appendTo.nodeType!==void 0;if((t.config.inline||t.config.static)&&(t.calendarContainer.classList.add(t.config.inline?"inline":"static"),t.config.inline&&(!v&&t.element.parentNode?t.element.parentNode.insertBefore(t.calendarContainer,t._input.nextSibling):t.config.appendTo!==void 0&&t.config.appendTo.appendChild(t.calendarContainer)),t.config.static)){var C=x("div","flatpickr-wrapper");t.element.parentNode&&t.element.parentNode.insertBefore(C,t.element),C.appendChild(t.element),t.altInput&&C.appendChild(t.altInput),C.appendChild(t.calendarContainer)}t.config.static||t.config.inline||(t.config.appendTo!==void 0?t.config.appendTo:window.document.body).appendChild(t.calendarContainer)}(),function(){if(t.config.wrap&&["open","close","toggle","clear"].forEach(function(u){Array.prototype.forEach.call(t.element.querySelectorAll("[data-"+u+"]"),function(y){return d(y,"click",t[u])})}),t.isMobile)return void function(){var u=t.config.enableTime?t.config.noCalendar?"time":"datetime-local":"date";t.mobileInput=x("input",t.input.className+" flatpickr-mobile"),t.mobileInput.tabIndex=1,t.mobileInput.type=u,t.mobileInput.disabled=t.input.disabled,t.mobileInput.required=t.input.required,t.mobileInput.placeholder=t.input.placeholder,t.mobileFormatStr=u==="datetime-local"?"Y-m-d\\TH:i:S":u==="date"?"Y-m-d":"H:i:S",t.selectedDates.length>0&&(t.mobileInput.defaultValue=t.mobileInput.value=t.formatDate(t.selectedDates[0],t.mobileFormatStr)),t.config.minDate&&(t.mobileInput.min=t.formatDate(t.config.minDate,"Y-m-d")),t.config.maxDate&&(t.mobileInput.max=t.formatDate(t.config.maxDate,"Y-m-d")),t.input.getAttribute("step")&&(t.mobileInput.step=String(t.input.getAttribute("step"))),t.input.type="hidden",t.altInput!==void 0&&(t.altInput.type="hidden");try{t.input.parentNode&&t.input.parentNode.insertBefore(t.mobileInput,t.input.nextSibling)}catch{}d(t.mobileInput,"change",function(y){t.setDate(ie(y).value,!1,t.mobileFormatStr),q("onChange"),q("onClose")})}();var i=R(at,50);if(t._debouncedChange=R(b,300),t.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&d(t.daysContainer,"mouseover",function(u){t.config.mode==="range"&&Re(ie(u))}),d(t._input,"keydown",Ge),t.calendarContainer!==void 0&&d(t.calendarContainer,"keydown",Ge),t.config.inline||t.config.static||d(window,"resize",i),window.ontouchstart!==void 0?d(window.document,"touchstart",je):d(window.document,"mousedown",je),d(window.document,"focus",je,{capture:!0}),t.config.clickOpens===!0&&(d(t._input,"focus",t.open),d(t._input,"click",t.open)),t.daysContainer!==void 0&&(d(t.monthNav,"click",h),d(t.monthNav,["keyup","increment"],ke),d(t.daysContainer,"click",qe)),t.timeContainer!==void 0&&t.minuteElement!==void 0&&t.hourElement!==void 0){var l=function(u){return ie(u).select()};d(t.timeContainer,["increment"],U),d(t.timeContainer,"blur",U,{capture:!0}),d(t.timeContainer,"click",I),d([t.hourElement,t.minuteElement],["focus","click"],l),t.secondElement!==void 0&&d(t.secondElement,"focus",function(){return t.secondElement&&t.secondElement.select()}),t.amPM!==void 0&&d(t.amPM,"click",function(u){U(u)})}t.config.allowInput&&d(t._input,"blur",ut)}(),(t.selectedDates.length||t.config.noCalendar)&&(t.config.enableTime&&re(t.config.noCalendar?t.latestSelectedDateObj:void 0),m(!1)),P();var n=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);!t.isMobile&&n&&ze(),q("onReady")}(),t}function Ce(c,f){for(var t=Array.prototype.slice.call(c).filter(function(U){return U instanceof HTMLElement}),H=[],Y=0;Y{Alpine.data("laravellivewiretable",o=>({tableId:"",showBulkActionsAlpine:!1,primaryKeyName:"",shouldBeDisplayed:o.entangle("shouldBeDisplayed"),tableName:o.entangle("tableName"),dataTableFingerprint:o.entangle("dataTableFingerprint"),listeners:[],childElementOpen:!1,filtersOpen:o.entangle("filterSlideDownDefaultVisible"),paginationCurrentCount:o.entangle("paginationCurrentCount"),paginationTotalItemCount:o.entangle("paginationTotalItemCount"),paginationCurrentItems:o.entangle("paginationCurrentItems"),selectedItems:o.entangle("selected"),selectAllStatus:o.entangle("selectAll"),delaySelectAll:o.entangle("delaySelectAll"),hideBulkActionsWhenEmpty:o.entangle("hideBulkActionsWhenEmpty"),dragging:!1,reorderEnabled:!1,sourceID:"",targetID:"",evenRowClasses:"",oddRowClasses:"",currentlyHighlightedElement:"",evenRowClassArray:{},oddRowClassArray:{},evenNotInOdd:{},oddNotInEven:{},orderedRows:[],defaultReorderColumn:o.get("defaultReorderColumn"),reorderStatus:o.entangle("reorderStatus"),currentlyReorderingStatus:o.entangle("currentlyReorderingStatus"),hideReorderColumnUnlessReorderingStatus:o.entangle("hideReorderColumnUnlessReorderingStatus"),reorderDisplayColumn:o.entangle("reorderDisplayColumn"),dragStart(s){this.$nextTick(()=>{this.setupEvenOddClasses()}),this.sourceID=s.target.id,s.dataTransfer.effectAllowed="move",s.dataTransfer.setData("text/plain",s.target.id),s.target.classList.add("laravel-livewire-tables-dragging")},dragOverEvent(s){typeof this.currentlyHighlightedElement=="object"&&this.currentlyHighlightedElement.classList.remove("laravel-livewire-tables-highlight-bottom","laravel-livewire-tables-highlight-top");let e=s.target.closest("tr");this.currentlyHighlightedElement=e,s.offsetYe.getBoundingClientRect().height/2?E.insertBefore(S,e.nextSibling):E.insertBefore(S,e);let k="even";for(let R=1,_;_=M.rows[R];R++)_.classList.contains("hidden")||_.classList.contains("md:hidden")||(k==="even"?(_.classList.remove(...this.oddNotInEven),_.classList.add(...this.evenNotInOdd),k="odd"):(_.classList.remove(...this.evenNotInOdd),_.classList.add(...this.oddNotInEven),k="even"))},reorderToggle(){this.currentlyReorderingStatus?o.disableReordering():(this.hideReorderColumnUnlessReorderingStatus&&(this.reorderDisplayColumn=!0),this.setupEvenOddClasses(),o.enableReordering()),this.$nextTick(()=>{this.setupEvenOddClasses()})},cancelReorder(){this.hideReorderColumnUnlessReorderingStatus&&(this.reorderDisplayColumn=!1),o.disableReordering()},updateOrderedItems(){let s=document.getElementById(this.tableId),e=[];for(let E=1,S;S=s.rows[E];E++)e.push({[this.primaryKeyName]:S.getAttribute("rowpk"),[this.defaultReorderColumn]:E});o.storeReorder(e)},setupEvenOddClasses(){if(this.evenNotInOdd.length===void 0||this.evenNotInOdd.length==0||this.oddNotInEven.length===void 0||this.oddNotInEven.length==0){let s=document.getElementById(this.tableId).getElementsByTagName("tbody")[0],e=[],E=[];s.rows[0]!==void 0&&s.rows[1]!==void 0&&(e=Array.from(s.rows[0].classList),E=Array.from(s.rows[1].classList),this.evenNotInOdd=e.filter(S=>!E.includes(S)),this.oddNotInEven=E.filter(S=>!e.includes(S)),e=[],E=[])}},toggleSelectAll(){this.showBulkActionsAlpine&&(this.paginationTotalItemCount===this.selectedItems.length?(this.clearSelected(),this.selectAllStatus=!1):this.delaySelectAll?this.setAllItemsSelected():this.setAllSelected())},setAllItemsSelected(){this.showBulkActionsAlpine&&(this.selectAllStatus=!0,this.selectAllOnPage())},setAllSelected(){this.showBulkActionsAlpine&&(this.delaySelectAll?(this.selectAllStatus=!0,this.selectAllOnPage()):o.setAllSelected())},clearSelected(){this.showBulkActionsAlpine&&(this.selectAllStatus=!1,o.clearSelected())},selectAllOnPage(){if(!this.showBulkActionsAlpine)return;let s=this.selectedItems,e=this.paginationCurrentItems.values();for(let E of e)s.push(E.toString());this.selectedItems=[...new Set(s)]},setTableId(s){this.tableId=s},setAlpineBulkActions(s){this.showBulkActionsAlpine=s},setPrimaryKeyName(s){this.primaryKeyName=s},showTable(s){let e=s.detail.tableName??"",E=s.detail.tableFingerpint??"";((e??"")!=""&&e===this.tableName||E!=""&&eventTableFingerpint===this.dataTableFingerprint)&&(this.shouldBeDisplayed=!0)},hideTable(s){let e=s.detail.tableName??"",E=s.detail.tableFingerpint??"";(e!=""&&e===this.tableName||E!=""&&eventTableFingerpint===this.dataTableFingerprint)&&(this.shouldBeDisplayed=!1)},destroy(){this.listeners.forEach(s=>{s()})}})),Alpine.data("booleanFilter",(o,s,e,E)=>({switchOn:!1,value:o.entangle("filterComponents."+s).live,init(){this.switchOn=!1,this.value!==void 0&&(this.switchOn=!!Number(this.value)),this.listeners.push(Livewire.on("filter-was-set",S=>{S.tableName==e&&S.filterKey==s&&(this.switchOn=S.value??E)}))}})),Alpine.data("newBooleanFilter",(o,s,e)=>({switchOn:!1,value:!1,toggleStatus(){let E=!Number(this.$wire.get("filterComponents."+o)??this.value);return this.switchOn=this.value=E,Number(E)},toggleStatusWithUpdate(){let E=this.toggleStatus();this.$wire.set("filterComponents."+o,E)},toggleStatusWithReset(){this.toggleStatus(),this.$wire.call("resetFilter",o)},setSwitchOn(E){let S=Number(E??0);this.switchOn=!!S},init(){this.$nextTick(()=>{this.value=this.$wire.get("filterComponents."+o)??e,this.setSwitchOn(this.value??0)}),this.listeners.push(Livewire.on("filter-was-set",E=>{E.tableName==s&&E.filterKey==o&&(this.switchOn=E.value??e)}))}})),Alpine.data("numberRangeFilter",(o,s,e,E,S)=>({allFilters:o.entangle("filterComponents",!1),originalMin:0,originalMax:100,filterMin:0,filterMax:100,currentMin:0,currentMax:100,hasUpdate:!1,wireValues:o.entangle("filterComponents."+s,!1),defaultMin:E.minRange,defaultMax:E.maxRange,restrictUpdates:!1,initialiseStyles(){let M=document.getElementById(e);M.style.setProperty("--value-a",this.wireValues.min??this.filterMin),M.style.setProperty("--text-value-a",JSON.stringify(this.wireValues.min??this.filterMin)),M.style.setProperty("--value-b",this.wireValues.max??this.filterMax),M.style.setProperty("--text-value-b",JSON.stringify(this.wireValues.max??this.filterMax))},updateStyles(M,k){let R=document.getElementById(e);R.style.setProperty("--value-a",M),R.style.setProperty("--text-value-a",JSON.stringify(M)),R.style.setProperty("--value-b",k),R.style.setProperty("--text-value-b",JSON.stringify(k))},setupWire(){this.wireValues!==void 0?(this.filterMin=this.originalMin=this.wireValues.min!==void 0?this.wireValues.min:this.defaultMin,this.filterMax=this.originalMax=this.wireValues.max!==void 0?this.wireValues.max:this.defaultMax):(this.filterMin=this.originalMin=this.defaultMin,this.filterMax=this.originalMax=this.defaultMax),this.updateStyles(this.filterMin,this.filterMax)},allowUpdates(){this.updateWire()},updateWire(){let M=parseInt(this.filterMin),k=parseInt(this.filterMax);(M!=this.originalMin||k!=this.originalMax)&&(kthis.setupWire())}})),Alpine.data("flatpickrFilter",(o,s,e,E,S)=>({wireValues:o.entangle("filterComponents."+s),flatpickrInstance:flatpickr(E,{mode:"range",altFormat:e.altFormat??"F j, Y",altInput:e.altInput??!1,allowInput:e.allowInput??!1,allowInvalidPreload:e.allowInvalidPreload??!0,ariaDateFormat:e.ariaDateFormat??"F j, Y",clickOpens:!0,dateFormat:e.dateFormat??"Y-m-d",defaultDate:e.defaultDate??null,defaultHour:e.defaultHour??12,defaultMinute:e.defaultMinute??0,enableTime:e.enableTime??!1,enableSeconds:e.enableSeconds??!1,hourIncrement:e.hourIncrement??1,locale:e.locale??"en",minDate:e.earliestDate??null,maxDate:e.latestDate??null,minuteIncrement:e.minuteIncrement??5,shorthandCurrentMonth:e.shorthandCurrentMonth??!1,time_24hr:e.time_24hr??!1,weekNumbers:e.weekNumbers??!1,onOpen:function(){window.childElementOpen=!0},onChange:function(M,k,R){if(M.length>1){var _=k.split(" "),W={};window.childElementOpen=!1,window.filterPopoverOpen=!1,W={minDate:_[0],maxDate:_[2]===void 0?_[0]:_[2]},o.set("filterComponents."+s,W)}}}),changedValue:function(M){M.length<5&&(this.flatpickrInstance.setDate([]),o.set("filterComponents."+s,{}))},setupWire(){if(this.wireValues!==void 0)if(this.wireValues.minDate!==void 0&&this.wireValues.maxDate!==void 0){let M=[this.wireValues.minDate,this.wireValues.maxDate];this.flatpickrInstance.setDate(M)}else this.flatpickrInstance.setDate([]);else this.flatpickrInstance.setDate([])},init(){this.setupWire(),this.$watch("wireValues",M=>this.setupWire())}})),Alpine.data("tableWrapper",(o,s)=>({shouldBeDisplayed:o.entangle("shouldBeDisplayed"),listeners:[],childElementOpen:!1,filtersOpen:o.entangle("filterSlideDownDefaultVisible"),paginationCurrentCount:o.entangle("paginationCurrentCount"),paginationTotalItemCount:o.entangle("paginationTotalItemCount"),paginationCurrentItems:o.entangle("paginationCurrentItems"),selectedItems:o.entangle("selected"),selectAllStatus:o.entangle("selectAll"),delaySelectAll:o.entangle("delaySelectAll"),hideBulkActionsWhenEmpty:o.entangle("hideBulkActionsWhenEmpty"),toggleSelectAll(){s&&(this.paginationTotalItemCount===this.selectedItems.length?(this.clearSelected(),this.selectAllStatus=!1):this.delaySelectAll?this.setAllItemsSelected():this.setAllSelected())},setAllItemsSelected(){s&&(this.selectAllStatus=!0,this.selectAllOnPage())},setAllSelected(){s&&(this.delaySelectAll?(this.selectAllStatus=!0,this.selectAllOnPage()):o.setAllSelected())},clearSelected(){s&&(this.selectAllStatus=!1,o.clearSelected())},selectAllOnPage(){if(!s)return;let e=this.selectedItems,E=this.paginationCurrentItems.values();for(let S of E)e.push(S.toString());this.selectedItems=[...new Set(e)]},destroy(){this.listeners.forEach(e=>{e()})}})),Alpine.data("reorderFunction",(o,s,e)=>({dragging:!1,reorderEnabled:!1,sourceID:"",targetID:"",evenRowClasses:"",oddRowClasses:"",currentlyHighlightedElement:"",evenRowClassArray:{},oddRowClassArray:{},evenNotInOdd:{},oddNotInEven:{},orderedRows:[],defaultReorderColumn:o.get("defaultReorderColumn"),reorderStatus:o.get("reorderStatus"),currentlyReorderingStatus:o.entangle("currentlyReorderingStatus"),hideReorderColumnUnlessReorderingStatus:o.entangle("hideReorderColumnUnlessReorderingStatus"),reorderDisplayColumn:o.entangle("reorderDisplayColumn"),dragStart(E){this.$nextTick(()=>{this.setupEvenOddClasses()}),this.sourceID=E.target.id,E.dataTransfer.effectAllowed="move",E.dataTransfer.setData("text/plain",E.target.id),E.target.classList.add("laravel-livewire-tables-dragging")},dragOverEvent(E){typeof this.currentlyHighlightedElement=="object"&&this.currentlyHighlightedElement.classList.remove("laravel-livewire-tables-highlight-bottom","laravel-livewire-tables-highlight-top");let S=E.target.closest("tr");this.currentlyHighlightedElement=S,E.offsetYS.getBoundingClientRect().height/2?M.insertBefore(k,S.nextSibling):M.insertBefore(k,S);let _="even";for(let W=1,x;x=R.rows[W];W++)x.classList.contains("hidden")||x.classList.contains("md:hidden")||(_==="even"?(x.classList.remove(...this.oddNotInEven),x.classList.add(...this.evenNotInOdd),_="odd"):(x.classList.remove(...this.evenNotInOdd),x.classList.add(...this.oddNotInEven),_="even"))},reorderToggle(){this.$nextTick(()=>{this.setupEvenOddClasses()}),this.currentlyReorderingStatus?o.disableReordering():(this.setupEvenOddClasses(),this.hideReorderColumnUnlessReorderingStatus&&(this.reorderDisplayColumn=!0),o.enableReordering())},cancelReorder(){this.hideReorderColumnUnlessReorderingStatus&&(this.reorderDisplayColumn=!1),o.disableReordering()},updateOrderedItems(){let E=document.getElementById(s),S=[];for(let M=1,k;k=E.rows[M];M++)S.push({[e]:k.getAttribute("rowpk"),[this.defaultReorderColumn]:M});o.storeReorder(S)},setupEvenOddClasses(){if(this.evenNotInOdd.length===void 0||this.evenNotInOdd.length==0||this.oddNotInEven.length===void 0||this.oddNotInEven.length==0){let E=document.getElementById(s).getElementsByTagName("tbody")[0],S=[],M=[];E.rows[0]!==void 0&&E.rows[1]!==void 0&&(S=Array.from(E.rows[0].classList),M=Array.from(E.rows[1].classList),this.evenNotInOdd=S.filter(k=>!M.includes(k)),this.oddNotInEven=M.filter(k=>!S.includes(k)),S=[],M=[])}},init(){}}))});var bt=["onChange","onClose","onDayCreate","onDestroy","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange","onPreCalendarPosition"],Ke={_disable:[],allowInput:!1,allowInvalidPreload:!1,altFormat:"F j, Y",altInput:!1,altInputClass:"form-control input",animate:typeof window=="object"&&window.navigator.userAgent.indexOf("MSIE")===-1,ariaDateFormat:"F j, Y",autoFillDefaultTime:!0,clickOpens:!0,closeOnSelect:!0,conjunction:", ",dateFormat:"Y-m-d",defaultHour:12,defaultMinute:0,defaultSeconds:0,disable:[],disableMobile:!1,enableSeconds:!1,enableTime:!1,errorHandler:function(o){return typeof console<"u"&&console.warn(o)},getWeek:function(o){var s=new Date(o.getTime());s.setHours(0,0,0,0),s.setDate(s.getDate()+3-(s.getDay()+6)%7);var e=new Date(s.getFullYear(),0,4);return 1+Math.round(((s.getTime()-e.getTime())/864e5-3+(e.getDay()+6)%7)/7)},hourIncrement:1,ignoredFocusElements:[],inline:!1,locale:"default",minuteIncrement:5,mode:"single",monthSelectorType:"dropdown",nextArrow:"",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},nt={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(o){var s=o%100;if(s>3&&s<21)return"th";switch(s%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},be=function(o,s){return s===void 0&&(s=2),("000"+o).slice(s*-1)},Ie=function(o){return o===!0?1:0};function St(o,s){var e;return function(){var E=this,S=arguments;clearTimeout(e),e=setTimeout(function(){return o.apply(E,S)},s)}}var yt=function(o){return o instanceof Array?o:[o]};function he(o,s,e){if(e===!0)return o.classList.add(s);o.classList.remove(s)}function K(o,s,e){var E=window.document.createElement(o);return s=s||"",e=e||"",E.className=s,e!==void 0&&(E.textContent=e),E}function lt(o){for(;o.firstChild;)o.removeChild(o.firstChild)}function kt(o,s){if(s(o))return o;if(o.parentNode)return kt(o.parentNode,s)}function dt(o,s){var e=K("div","numInputWrapper"),E=K("input","numInput "+o),S=K("span","arrowUp"),M=K("span","arrowDown");if(navigator.userAgent.indexOf("MSIE 9.0")===-1?E.type="number":(E.type="text",E.pattern="\\d*"),s!==void 0)for(var k in s)E.setAttribute(k,s[k]);return e.appendChild(E),e.appendChild(S),e.appendChild(M),e}function we(o){try{if(typeof o.composedPath=="function"){var s=o.composedPath();return s[0]}return o.target}catch{return o.target}}var wt=function(){},ct=function(o,s,e){return e.months[s?"shorthand":"longhand"][o]},Ot={D:wt,F:function(o,s,e){o.setMonth(e.months.longhand.indexOf(s))},G:function(o,s){o.setHours((o.getHours()>=12?12:0)+parseFloat(s))},H:function(o,s){o.setHours(parseFloat(s))},J:function(o,s){o.setDate(parseFloat(s))},K:function(o,s,e){o.setHours(o.getHours()%12+12*Ie(new RegExp(e.amPM[1],"i").test(s)))},M:function(o,s,e){o.setMonth(e.months.shorthand.indexOf(s))},S:function(o,s){o.setSeconds(parseFloat(s))},U:function(o,s){return new Date(parseFloat(s)*1e3)},W:function(o,s,e){var E=parseInt(s),S=new Date(o.getFullYear(),0,2+(E-1)*7,0,0,0,0);return S.setDate(S.getDate()-S.getDay()+e.firstDayOfWeek),S},Y:function(o,s){o.setFullYear(parseFloat(s))},Z:function(o,s){return new Date(s)},d:function(o,s){o.setDate(parseFloat(s))},h:function(o,s){o.setHours((o.getHours()>=12?12:0)+parseFloat(s))},i:function(o,s){o.setMinutes(parseFloat(s))},j:function(o,s){o.setDate(parseFloat(s))},l:wt,m:function(o,s){o.setMonth(parseFloat(s)-1)},n:function(o,s){o.setMonth(parseFloat(s)-1)},s:function(o,s){o.setSeconds(parseFloat(s))},u:function(o,s){return new Date(parseFloat(s))},w:wt,y:function(o,s){o.setFullYear(2e3+parseFloat(s))}},Ye={D:"",F:"",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"",M:"",S:"(\\d\\d|\\d)",U:"(.+)",W:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",u:"(.+)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},tt={Z:function(o){return o.toISOString()},D:function(o,s,e){return s.weekdays.shorthand[tt.w(o,s,e)]},F:function(o,s,e){return ct(tt.n(o,s,e)-1,!1,s)},G:function(o,s,e){return be(tt.h(o,s,e))},H:function(o){return be(o.getHours())},J:function(o,s){return s.ordinal!==void 0?o.getDate()+s.ordinal(o.getDate()):o.getDate()},K:function(o,s){return s.amPM[Ie(o.getHours()>11)]},M:function(o,s){return ct(o.getMonth(),!0,s)},S:function(o){return be(o.getSeconds())},U:function(o){return o.getTime()/1e3},W:function(o,s,e){return e.getWeek(o)},Y:function(o){return be(o.getFullYear(),4)},d:function(o){return be(o.getDate())},h:function(o){return o.getHours()%12?o.getHours()%12:12},i:function(o){return be(o.getMinutes())},j:function(o){return o.getDate()},l:function(o,s){return s.weekdays.longhand[o.getDay()]},m:function(o){return be(o.getMonth()+1)},n:function(o){return o.getMonth()+1},s:function(o){return o.getSeconds()},u:function(o){return o.getTime()},w:function(o){return o.getDay()},y:function(o){return String(o.getFullYear()).substring(2)}},xt=function(o){var s=o.config,e=s===void 0?Ke:s,E=o.l10n,S=E===void 0?nt:E,M=o.isMobile,k=M===void 0?!1:M;return function(R,_,W){var x=W||S;return e.formatDate!==void 0&&!k?e.formatDate(R,_,x):_.split("").map(function(le,de,fe){return tt[le]&&fe[de-1]!=="\\"?tt[le](R,x,e):le!=="\\"?le:""}).join("")}},Mt=function(o){var s=o.config,e=s===void 0?Ke:s,E=o.l10n,S=E===void 0?nt:E;return function(M,k,R,_){if(!(M!==0&&!M)){var W=_||S,x,le=M;if(M instanceof Date)x=new Date(M.getTime());else if(typeof M!="string"&&M.toFixed!==void 0)x=new Date(M);else if(typeof M=="string"){var de=k||(e||Ke).dateFormat,fe=String(M).trim();if(fe==="today")x=new Date,R=!0;else if(e&&e.parseDate)x=e.parseDate(M,de);else if(/Z$/.test(fe)||/GMT$/.test(fe))x=new Date(M);else{for(var ie=void 0,j=[],pe=0,Fe=0,ce="";peMath.min(s,e)&&o=0?new Date:new Date(e.config.minDate.getTime()),m=Dt(e.config);r.setHours(m.hours,m.minutes,m.seconds,r.getMilliseconds()),e.selectedDates=[r],e.latestSelectedDateObj=r}a!==void 0&&a.type!=="blur"&&Xe(a);var h=e._input.value;le(),q(),e._input.value!==h&&e._debouncedChange()}function W(a,r){return a%12+12*Ie(r===e.l10n.amPM[1])}function x(a){switch(a%24){case 0:case 12:return 12;default:return a%12}}function le(){if(!(e.hourElement===void 0||e.minuteElement===void 0)){var a=(parseInt(e.hourElement.value.slice(-2),10)||0)%24,r=(parseInt(e.minuteElement.value,10)||0)%60,m=e.secondElement!==void 0?(parseInt(e.secondElement.value,10)||0)%60:0;e.amPM!==void 0&&(a=W(a,e.amPM.textContent));var h=e.config.minTime!==void 0||e.config.minDate&&e.minDateHasTime&&e.latestSelectedDateObj&&Ee(e.latestSelectedDateObj,e.config.minDate,!0)===0,n=e.config.maxTime!==void 0||e.config.maxDate&&e.maxDateHasTime&&e.latestSelectedDateObj&&Ee(e.latestSelectedDateObj,e.config.maxDate,!0)===0;if(e.config.maxTime!==void 0&&e.config.minTime!==void 0&&e.config.minTime>e.config.maxTime){var i=Et(e.config.minTime.getHours(),e.config.minTime.getMinutes(),e.config.minTime.getSeconds()),l=Et(e.config.maxTime.getHours(),e.config.maxTime.getMinutes(),e.config.maxTime.getSeconds()),u=Et(a,r,m);if(u>l&&u=12)]),e.secondElement!==void 0&&(e.secondElement.value=be(m)))}function ie(a){var r=we(a),m=parseInt(r.value)+(a.delta||0);(m/1e3>1||a.key==="Enter"&&!/[^\d]/.test(m.toString()))&&I(m)}function j(a,r,m,h){if(r instanceof Array)return r.forEach(function(n){return j(a,n,m,h)});if(a instanceof Array)return a.forEach(function(n){return j(n,r,m,h)});a.addEventListener(r,m,h),e._handlers.push({remove:function(){return a.removeEventListener(r,m,h)}})}function pe(){X("onChange")}function Fe(){if(e.config.wrap&&["open","close","toggle","clear"].forEach(function(m){Array.prototype.forEach.call(e.element.querySelectorAll("[data-"+m+"]"),function(h){return j(h,"click",e[m])})}),e.isMobile){ze();return}var a=St(se,50);if(e._debouncedChange=St(pe,_t),e.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&j(e.daysContainer,"mouseover",function(m){e.config.mode==="range"&&N(we(m))}),j(e._input,"keydown",T),e.calendarContainer!==void 0&&j(e.calendarContainer,"keydown",T),!e.config.inline&&!e.config.static&&j(window,"resize",a),window.ontouchstart!==void 0?j(window.document,"touchstart",g):j(window.document,"mousedown",g),j(window.document,"focus",g,{capture:!0}),e.config.clickOpens===!0&&(j(e._input,"focus",e.open),j(e._input,"click",e.open)),e.daysContainer!==void 0&&(j(e.monthNav,"click",Ve),j(e.monthNav,["keyup","increment"],ie),j(e.daysContainer,"click",Te)),e.timeContainer!==void 0&&e.minuteElement!==void 0&&e.hourElement!==void 0){var r=function(m){return we(m).select()};j(e.timeContainer,["increment"],_),j(e.timeContainer,"blur",_,{capture:!0}),j(e.timeContainer,"click",ue),j([e.hourElement,e.minuteElement],["focus","click"],r),e.secondElement!==void 0&&j(e.secondElement,"focus",function(){return e.secondElement&&e.secondElement.select()}),e.amPM!==void 0&&j(e.amPM,"click",function(m){_(m)})}e.config.allowInput&&j(e._input,"blur",B)}function ce(a,r){var m=a!==void 0?e.parseDate(a):e.latestSelectedDateObj||(e.config.minDate&&e.config.minDate>e.now?e.config.minDate:e.config.maxDate&&e.config.maxDate1),e.calendarContainer.appendChild(a);var n=e.config.appendTo!==void 0&&e.config.appendTo.nodeType!==void 0;if((e.config.inline||e.config.static)&&(e.calendarContainer.classList.add(e.config.inline?"inline":"static"),e.config.inline&&(!n&&e.element.parentNode?e.element.parentNode.insertBefore(e.calendarContainer,e._input.nextSibling):e.config.appendTo!==void 0&&e.config.appendTo.appendChild(e.calendarContainer)),e.config.static)){var i=K("div","flatpickr-wrapper");e.element.parentNode&&e.element.parentNode.insertBefore(i,e.element),i.appendChild(e.element),e.altInput&&i.appendChild(e.altInput),i.appendChild(e.calendarContainer)}!e.config.static&&!e.config.inline&&(e.config.appendTo!==void 0?e.config.appendTo:window.document.body).appendChild(e.calendarContainer)}function te(a,r,m,h){var n=p(r,!0),i=K("span",a,r.getDate().toString());return i.dateObj=r,i.$i=h,i.setAttribute("aria-label",e.formatDate(r,e.config.ariaDateFormat)),a.indexOf("hidden")===-1&&Ee(r,e.now)===0&&(e.todayDateElem=i,i.classList.add("today"),i.setAttribute("aria-current","date")),n?(i.tabIndex=-1,Be(r)&&(i.classList.add("selected"),e.selectedDateElem=i,e.config.mode==="range"&&(he(i,"startRange",e.selectedDates[0]&&Ee(r,e.selectedDates[0],!0)===0),he(i,"endRange",e.selectedDates[1]&&Ee(r,e.selectedDates[1],!0)===0),a==="nextMonthDay"&&i.classList.add("inRange")))):i.classList.add("flatpickr-disabled"),e.config.mode==="range"&&st(r)&&!Be(r)&&i.classList.add("inRange"),e.weekNumbers&&e.config.showMonths===1&&a!=="prevMonthDay"&&h%7===6&&e.weekNumbers.insertAdjacentHTML("beforeend",""+e.config.getWeek(r)+""),X("onDayCreate",i),i}function De(a){a.focus(),e.config.mode==="range"&&N(a)}function Se(a){for(var r=a>0?0:e.config.showMonths-1,m=a>0?e.config.showMonths:-1,h=r;h!=m;h+=a)for(var n=e.daysContainer.children[h],i=a>0?0:n.children.length-1,l=a>0?n.children.length:-1,u=i;u!=l;u+=a){var y=n.children[u];if(y.className.indexOf("hidden")===-1&&p(y.dateObj))return y}}function Ae(a,r){for(var m=a.className.indexOf("Month")===-1?a.dateObj.getMonth():e.currentMonth,h=r>0?e.config.showMonths:-1,n=r>0?1:-1,i=m-e.currentMonth;i!=h;i+=n)for(var l=e.daysContainer.children[i],u=m-e.currentMonth===i?a.$i+r:r<0?l.children.length-1:0,y=l.children.length,v=u;v>=0&&v0?y:-1);v+=n){var C=l.children[v];if(C.className.indexOf("hidden")===-1&&p(C.dateObj)&&Math.abs(a.$i-v)>=Math.abs(r))return De(C)}e.changeMonth(n),oe(Se(n),0)}function oe(a,r){var m=M(),h=w(m||document.body),n=a!==void 0?a:h?m:e.selectedDateElem!==void 0&&w(e.selectedDateElem)?e.selectedDateElem:e.todayDateElem!==void 0&&w(e.todayDateElem)?e.todayDateElem:Se(r>0?1:-1);n===void 0?e._input.focus():h?Ae(n,r):De(n)}function Ce(a,r){for(var m=(new Date(a,r,1).getDay()-e.l10n.firstDayOfWeek+7)%7,h=e.utils.getDaysInMonth((r-1+12)%12,a),n=e.utils.getDaysInMonth(r,a),i=window.document.createDocumentFragment(),l=e.config.showMonths>1,u=l?"prevMonthDay hidden":"prevMonthDay",y=l?"nextMonthDay hidden":"nextMonthDay",v=h+1-m,C=0;v<=h;v++,C++)i.appendChild(te("flatpickr-day "+u,new Date(a,r-1,v),v,C));for(v=1;v<=n;v++,C++)i.appendChild(te("flatpickr-day",new Date(a,r,v),v,C));for(var D=n+1;D<=42-m&&(e.config.showMonths===1||C%7!==0);D++,C++)i.appendChild(te("flatpickr-day "+y,new Date(a,r+1,D%n),D,C));var L=K("div","dayContainer");return L.appendChild(i),L}function $(){if(e.daysContainer!==void 0){lt(e.daysContainer),e.weekNumbers&<(e.weekNumbers);for(var a=document.createDocumentFragment(),r=0;r1||e.config.monthSelectorType!=="dropdown")){var a=function(h){return e.config.minDate!==void 0&&e.currentYear===e.config.minDate.getFullYear()&&he.config.maxDate.getMonth())};e.monthsDropdownContainer.tabIndex=-1,e.monthsDropdownContainer.innerHTML="";for(var r=0;r<12;r++)if(a(r)){var m=K("option","flatpickr-monthDropdown-month");m.value=new Date(e.currentYear,r).getMonth().toString(),m.textContent=ct(r,e.config.shorthandCurrentMonth,e.l10n),m.tabIndex=-1,e.currentMonth===r&&(m.selected=!0),e.monthsDropdownContainer.appendChild(m)}}}function f(){var a=K("div","flatpickr-month"),r=window.document.createDocumentFragment(),m;e.config.showMonths>1||e.config.monthSelectorType==="static"?m=K("span","cur-month"):(e.monthsDropdownContainer=K("select","flatpickr-monthDropdown-months"),e.monthsDropdownContainer.setAttribute("aria-label",e.l10n.monthAriaLabel),j(e.monthsDropdownContainer,"change",function(l){var u=we(l),y=parseInt(u.value,10);e.changeMonth(y-e.currentMonth),X("onMonthChange")}),c(),m=e.monthsDropdownContainer);var h=dt("cur-year",{tabindex:"-1"}),n=h.getElementsByTagName("input")[0];n.setAttribute("aria-label",e.l10n.yearAriaLabel),e.config.minDate&&n.setAttribute("min",e.config.minDate.getFullYear().toString()),e.config.maxDate&&(n.setAttribute("max",e.config.maxDate.getFullYear().toString()),n.disabled=!!e.config.minDate&&e.config.minDate.getFullYear()===e.config.maxDate.getFullYear());var i=K("div","flatpickr-current-month");return i.appendChild(m),i.appendChild(h),r.appendChild(i),a.appendChild(r),{container:a,yearElement:n,monthElement:m}}function t(){lt(e.monthNav),e.monthNav.appendChild(e.prevMonthNav),e.config.showMonths&&(e.yearElements=[],e.monthElements=[]);for(var a=e.config.showMonths;a--;){var r=f();e.yearElements.push(r.yearElement),e.monthElements.push(r.monthElement),e.monthNav.appendChild(r.container)}e.monthNav.appendChild(e.nextMonthNav)}function H(){return e.monthNav=K("div","flatpickr-months"),e.yearElements=[],e.monthElements=[],e.prevMonthNav=K("span","flatpickr-prev-month"),e.prevMonthNav.innerHTML=e.config.prevArrow,e.nextMonthNav=K("span","flatpickr-next-month"),e.nextMonthNav.innerHTML=e.config.nextArrow,t(),Object.defineProperty(e,"_hidePrevMonthArrow",{get:function(){return e.__hidePrevMonthArrow},set:function(a){e.__hidePrevMonthArrow!==a&&(he(e.prevMonthNav,"flatpickr-disabled",a),e.__hidePrevMonthArrow=a)}}),Object.defineProperty(e,"_hideNextMonthArrow",{get:function(){return e.__hideNextMonthArrow},set:function(a){e.__hideNextMonthArrow!==a&&(he(e.nextMonthNav,"flatpickr-disabled",a),e.__hideNextMonthArrow=a)}}),e.currentYearElement=e.yearElements[0],Pe(),e.monthNav}function Y(){e.calendarContainer.classList.add("hasTime"),e.config.noCalendar&&e.calendarContainer.classList.add("noCalendar");var a=Dt(e.config);e.timeContainer=K("div","flatpickr-time"),e.timeContainer.tabIndex=-1;var r=K("span","flatpickr-time-separator",":"),m=dt("flatpickr-hour",{"aria-label":e.l10n.hourAriaLabel});e.hourElement=m.getElementsByTagName("input")[0];var h=dt("flatpickr-minute",{"aria-label":e.l10n.minuteAriaLabel});if(e.minuteElement=h.getElementsByTagName("input")[0],e.hourElement.tabIndex=e.minuteElement.tabIndex=-1,e.hourElement.value=be(e.latestSelectedDateObj?e.latestSelectedDateObj.getHours():e.config.time_24hr?a.hours:x(a.hours)),e.minuteElement.value=be(e.latestSelectedDateObj?e.latestSelectedDateObj.getMinutes():a.minutes),e.hourElement.setAttribute("step",e.config.hourIncrement.toString()),e.minuteElement.setAttribute("step",e.config.minuteIncrement.toString()),e.hourElement.setAttribute("min",e.config.time_24hr?"0":"1"),e.hourElement.setAttribute("max",e.config.time_24hr?"23":"12"),e.hourElement.setAttribute("maxlength","2"),e.minuteElement.setAttribute("min","0"),e.minuteElement.setAttribute("max","59"),e.minuteElement.setAttribute("maxlength","2"),e.timeContainer.appendChild(m),e.timeContainer.appendChild(r),e.timeContainer.appendChild(h),e.config.time_24hr&&e.timeContainer.classList.add("time24hr"),e.config.enableSeconds){e.timeContainer.classList.add("hasSeconds");var n=dt("flatpickr-second");e.secondElement=n.getElementsByTagName("input")[0],e.secondElement.value=be(e.latestSelectedDateObj?e.latestSelectedDateObj.getSeconds():a.seconds),e.secondElement.setAttribute("step",e.minuteElement.getAttribute("step")),e.secondElement.setAttribute("min","0"),e.secondElement.setAttribute("max","59"),e.secondElement.setAttribute("maxlength","2"),e.timeContainer.appendChild(K("span","flatpickr-time-separator",":")),e.timeContainer.appendChild(n)}return e.config.time_24hr||(e.amPM=K("span","flatpickr-am-pm",e.l10n.amPM[Ie((e.latestSelectedDateObj?e.hourElement.value:e.config.defaultHour)>11)]),e.amPM.title=e.l10n.toggleTitle,e.amPM.tabIndex=-1,e.timeContainer.appendChild(e.amPM)),e.timeContainer}function P(){e.weekdayContainer?lt(e.weekdayContainer):e.weekdayContainer=K("div","flatpickr-weekdays");for(var a=e.config.showMonths;a--;){var r=K("div","flatpickr-weekdaycontainer");e.weekdayContainer.appendChild(r)}return U(),e.weekdayContainer}function U(){if(e.weekdayContainer){var a=e.l10n.firstDayOfWeek,r=At(e.l10n.weekdays.shorthand);a>0&&a `+r.join("")+` `}}function ee(){e.calendarContainer.classList.add("hasWeeks");var a=K("div","flatpickr-weekwrapper");a.appendChild(K("span","flatpickr-weekday",e.l10n.weekAbbreviation));var r=K("div","flatpickr-weeks");return a.appendChild(r),{weekWrapper:a,weekNumbers:r}}function re(a,r){r===void 0&&(r=!0);var m=r?a:a-e.currentMonth;m<0&&e._hidePrevMonthArrow===!0||m>0&&e._hideNextMonthArrow===!0||(e.currentMonth+=m,(e.currentMonth<0||e.currentMonth>11)&&(e.currentYear+=e.currentMonth>11?1:-1,e.currentMonth=(e.currentMonth+12)%12,X("onYearChange"),c()),$(),X("onMonthChange"),Pe())}function V(a,r){if(a===void 0&&(a=!0),r===void 0&&(r=!0),e.input.value="",e.altInput!==void 0&&(e.altInput.value=""),e.mobileInput!==void 0&&(e.mobileInput.value=""),e.selectedDates=[],e.latestSelectedDateObj=void 0,r===!0&&(e.currentYear=e._initialDate.getFullYear(),e.currentMonth=e._initialDate.getMonth()),e.config.enableTime===!0){var m=Dt(e.config),h=m.hours,n=m.minutes,i=m.seconds;fe(h,n,i)}e.redraw(),a&&X("onChange")}function ke(){e.isOpen=!1,e.isMobile||(e.calendarContainer!==void 0&&e.calendarContainer.classList.remove("open"),e._input!==void 0&&e._input.classList.remove("active")),X("onClose")}function d(){e.config!==void 0&&X("onDestroy");for(var a=e._handlers.length;a--;)e._handlers[a].remove();if(e._handlers=[],e.mobileInput)e.mobileInput.parentNode&&e.mobileInput.parentNode.removeChild(e.mobileInput),e.mobileInput=void 0;else if(e.calendarContainer&&e.calendarContainer.parentNode)if(e.config.static&&e.calendarContainer.parentNode){var r=e.calendarContainer.parentNode;if(r.lastChild&&r.removeChild(r.lastChild),r.parentNode){for(;r.firstChild;)r.parentNode.insertBefore(r.firstChild,r);r.parentNode.removeChild(r)}}else e.calendarContainer.parentNode.removeChild(e.calendarContainer);e.altInput&&(e.input.type="text",e.altInput.parentNode&&e.altInput.parentNode.removeChild(e.altInput),delete e.altInput),e.input&&(e.input.type=e.input._type,e.input.classList.remove("flatpickr-input"),e.input.removeAttribute("readonly")),["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","monthsDropdownContainer","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach(function(m){try{delete e[m]}catch{}})}function b(a){return e.calendarContainer.contains(a)}function g(a){if(e.isOpen&&!e.config.inline){var r=we(a),m=b(r),h=r===e.input||r===e.altInput||e.element.contains(r)||a.path&&a.path.indexOf&&(~a.path.indexOf(e.input)||~a.path.indexOf(e.altInput)),n=!h&&!m&&!b(a.relatedTarget),i=!e.config.ignoredFocusElements.some(function(l){return l.contains(r)});n&&i&&(e.config.allowInput&&e.setDate(e._input.value,!1,e.config.altInput?e.config.altFormat:e.config.dateFormat),e.timeContainer!==void 0&&e.minuteElement!==void 0&&e.hourElement!==void 0&&e.input.value!==""&&e.input.value!==void 0&&_(),e.close(),e.config&&e.config.mode==="range"&&e.selectedDates.length===1&&e.clear(!1))}}function I(a){if(!(!a||e.config.minDate&&ae.config.maxDate.getFullYear())){var r=a,m=e.currentYear!==r;e.currentYear=r||e.currentYear,e.config.maxDate&&e.currentYear===e.config.maxDate.getFullYear()?e.currentMonth=Math.min(e.config.maxDate.getMonth(),e.currentMonth):e.config.minDate&&e.currentYear===e.config.minDate.getFullYear()&&(e.currentMonth=Math.max(e.config.minDate.getMonth(),e.currentMonth)),m&&(e.redraw(),X("onYearChange"),c())}}function p(a,r){var m;r===void 0&&(r=!0);var h=e.parseDate(a,void 0,r);if(e.config.minDate&&h&&Ee(h,e.config.minDate,r!==void 0?r:!e.minDateHasTime)<0||e.config.maxDate&&h&&Ee(h,e.config.maxDate,r!==void 0?r:!e.maxDateHasTime)>0)return!1;if(!e.config.enable&&e.config.disable.length===0)return!0;if(h===void 0)return!1;for(var n=!!e.config.enable,i=(m=e.config.enable)!==null&&m!==void 0?m:e.config.disable,l=0,u=void 0;l=u.from.getTime()&&h.getTime()<=u.to.getTime())return n}return!n}function w(a){return e.daysContainer!==void 0?a.className.indexOf("hidden")===-1&&a.className.indexOf("flatpickr-disabled")===-1&&e.daysContainer.contains(a):!1}function B(a){var r=a.target===e._input,m=e._input.value.trimEnd()!==We();r&&m&&!(a.relatedTarget&&b(a.relatedTarget))&&e.setDate(e._input.value,!0,a.target===e.altInput?e.config.altFormat:e.config.dateFormat)}function T(a){var r=we(a),m=e.config.wrap?o.contains(r):r===e._input,h=e.config.allowInput,n=e.isOpen&&(!h||!m),i=e.config.inline&&m&&!h;if(a.keyCode===13&&m){if(h)return e.setDate(e._input.value,!0,r===e.altInput?e.config.altFormat:e.config.dateFormat),e.close(),r.blur();e.open()}else if(b(r)||n||i){var l=!!e.timeContainer&&e.timeContainer.contains(r);switch(a.keyCode){case 13:l?(a.preventDefault(),_(),Ne()):Te(a);break;case 27:a.preventDefault(),Ne();break;case 8:case 46:m&&!e.config.allowInput&&(a.preventDefault(),e.clear());break;case 37:case 39:if(!l&&!m){a.preventDefault();var u=M();if(e.daysContainer!==void 0&&(h===!1||u&&w(u))){var y=a.keyCode===39?1:-1;a.ctrlKey?(a.stopPropagation(),re(y),oe(Se(1),0)):oe(void 0,y)}}else e.hourElement&&e.hourElement.focus();break;case 38:case 40:a.preventDefault();var v=a.keyCode===40?1:-1;e.daysContainer&&r.$i!==void 0||r===e.input||r===e.altInput?a.ctrlKey?(a.stopPropagation(),I(e.currentYear-v),oe(Se(1),0)):l||oe(void 0,v*7):r===e.currentYearElement?I(e.currentYear-v):e.config.enableTime&&(!l&&e.hourElement&&e.hourElement.focus(),_(a),e._debouncedChange());break;case 9:if(l){var C=[e.hourElement,e.minuteElement,e.secondElement,e.amPM].concat(e.pluginElements).filter(function(A){return A}),D=C.indexOf(r);if(D!==-1){var L=C[D+(a.shiftKey?-1:1)];a.preventDefault(),(L||e._input).focus()}}else!e.config.noCalendar&&e.daysContainer&&e.daysContainer.contains(r)&&a.shiftKey&&(a.preventDefault(),e._input.focus());break}}if(e.amPM!==void 0&&r===e.amPM)switch(a.key){case e.l10n.amPM[0].charAt(0):case e.l10n.amPM[0].charAt(0).toLowerCase():e.amPM.textContent=e.l10n.amPM[0],le(),q();break;case e.l10n.amPM[1].charAt(0):case e.l10n.amPM[1].charAt(0).toLowerCase():e.amPM.textContent=e.l10n.amPM[1],le(),q();break}(m||b(r))&&X("onKeyDown",a)}function N(a,r){if(r===void 0&&(r="flatpickr-day"),!(e.selectedDates.length!==1||a&&(!a.classList.contains(r)||a.classList.contains("flatpickr-disabled")))){for(var m=a?a.dateObj.getTime():e.days.firstElementChild.dateObj.getTime(),h=e.parseDate(e.selectedDates[0],void 0,!0).getTime(),n=Math.min(m,e.selectedDates[0].getTime()),i=Math.max(m,e.selectedDates[0].getTime()),l=!1,u=0,y=0,v=n;vn&&vu)?u=v:v>h&&(!y||v ."+r));C.forEach(function(D){var L=D.dateObj,A=L.getTime(),O=u>0&&A0&&A>y;if(O){D.classList.add("notAllowed"),["inRange","startRange","endRange"].forEach(function(F){D.classList.remove(F)});return}else if(l&&!O)return;["startRange","inRange","endRange","notAllowed"].forEach(function(F){D.classList.remove(F)}),a!==void 0&&(a.classList.add(m<=e.selectedDates[0].getTime()?"startRange":"endRange"),hm&&A===h&&D.classList.add("endRange"),A>=u&&(y===0||A<=y)&&Nt(A,h,m)&&D.classList.add("inRange"))})}}function se(){e.isOpen&&!e.config.static&&!e.config.inline&&xe()}function z(a,r){if(r===void 0&&(r=e._positionElement),e.isMobile===!0){if(a){a.preventDefault();var m=we(a);m&&m.blur()}e.mobileInput!==void 0&&(e.mobileInput.focus(),e.mobileInput.click()),X("onOpen");return}else if(e._input.disabled||e.config.inline)return;var h=e.isOpen;e.isOpen=!0,h||(e.calendarContainer.classList.add("open"),e._input.classList.add("active"),X("onOpen"),xe(r)),e.config.enableTime===!0&&e.config.noCalendar===!0&&e.config.allowInput===!1&&(a===void 0||!e.timeContainer.contains(a.relatedTarget))&&setTimeout(function(){return e.hourElement.select()},50)}function ne(a){return function(r){var m=e.config["_"+a+"Date"]=e.parseDate(r,e.config.dateFormat),h=e.config["_"+(a==="min"?"max":"min")+"Date"];m!==void 0&&(e[a==="min"?"minDateHasTime":"maxDateHasTime"]=m.getHours()>0||m.getMinutes()>0||m.getSeconds()>0),e.selectedDates&&(e.selectedDates=e.selectedDates.filter(function(n){return p(n)}),!e.selectedDates.length&&a==="min"&&de(m),q()),e.daysContainer&&(je(),m!==void 0?e.currentYearElement[a]=m.getFullYear().toString():e.currentYearElement.removeAttribute(a),e.currentYearElement.disabled=!!h&&m!==void 0&&h.getFullYear()===m.getFullYear())}}function Q(){var a=["wrap","weekNumbers","allowInput","allowInvalidPreload","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],r=ge(ge({},JSON.parse(JSON.stringify(o.dataset||{}))),s),m={};e.config.parseDate=r.parseDate,e.config.formatDate=r.formatDate,Object.defineProperty(e.config,"enable",{get:function(){return e.config._enable},set:function(C){e.config._enable=at(C)}}),Object.defineProperty(e.config,"disable",{get:function(){return e.config._disable},set:function(C){e.config._disable=at(C)}});var h=r.mode==="time";if(!r.dateFormat&&(r.enableTime||h)){var n=ae.defaultConfig.dateFormat||Ke.dateFormat;m.dateFormat=r.noCalendar||h?"H:i"+(r.enableSeconds?":S":""):n+" H:i"+(r.enableSeconds?":S":"")}if(r.altInput&&(r.enableTime||h)&&!r.altFormat){var i=ae.defaultConfig.altFormat||Ke.altFormat;m.altFormat=r.noCalendar||h?"h:i"+(r.enableSeconds?":S K":" K"):i+(" h:i"+(r.enableSeconds?":S":"")+" K")}Object.defineProperty(e.config,"minDate",{get:function(){return e.config._minDate},set:ne("min")}),Object.defineProperty(e.config,"maxDate",{get:function(){return e.config._maxDate},set:ne("max")});var l=function(C){return function(D){e.config[C==="min"?"_minTime":"_maxTime"]=e.parseDate(D,"H:i:S")}};Object.defineProperty(e.config,"minTime",{get:function(){return e.config._minTime},set:l("min")}),Object.defineProperty(e.config,"maxTime",{get:function(){return e.config._maxTime},set:l("max")}),r.mode==="time"&&(e.config.noCalendar=!0,e.config.enableTime=!0),Object.assign(e.config,m,r);for(var u=0;u-1?e.config[v]=yt(y[v]).map(k).concat(e.config[v]):typeof r[v]>"u"&&(e.config[v]=y[v])}r.altInputClass||(e.config.altInputClass=Me().className+" "+e.config.altInputClass),X("onParseConfig")}function Me(){return e.config.wrap?o.querySelector("[data-input]"):o}function Le(){typeof e.config.locale!="object"&&typeof ae.l10ns[e.config.locale]>"u"&&e.config.errorHandler(new Error("flatpickr: invalid locale "+e.config.locale)),e.l10n=ge(ge({},ae.l10ns.default),typeof e.config.locale=="object"?e.config.locale:e.config.locale!=="default"?ae.l10ns[e.config.locale]:void 0),Ye.D="("+e.l10n.weekdays.shorthand.join("|")+")",Ye.l="("+e.l10n.weekdays.longhand.join("|")+")",Ye.M="("+e.l10n.months.shorthand.join("|")+")",Ye.F="("+e.l10n.months.longhand.join("|")+")",Ye.K="("+e.l10n.amPM[0]+"|"+e.l10n.amPM[1]+"|"+e.l10n.amPM[0].toLowerCase()+"|"+e.l10n.amPM[1].toLowerCase()+")";var a=ge(ge({},s),JSON.parse(JSON.stringify(o.dataset||{})));a.time_24hr===void 0&&ae.defaultConfig.time_24hr===void 0&&(e.config.time_24hr=e.l10n.time_24hr),e.formatDate=xt(e),e.parseDate=Mt({config:e.config,l10n:e.l10n})}function xe(a){if(typeof e.config.position=="function")return void e.config.position(e,a);if(e.calendarContainer!==void 0){X("onPreCalendarPosition");var r=a||e._positionElement,m=Array.prototype.reduce.call(e.calendarContainer.children,function(gt,ht){return gt+ht.offsetHeight},0),h=e.calendarContainer.offsetWidth,n=e.config.position.split(" "),i=n[0],l=n.length>1?n[1]:null,u=r.getBoundingClientRect(),y=window.innerHeight-u.bottom,v=i==="above"||i!=="below"&&ym,C=window.pageYOffset+u.top+(v?-m-2:r.offsetHeight+2);if(he(e.calendarContainer,"arrowTop",!v),he(e.calendarContainer,"arrowBottom",v),!e.config.inline){var D=window.pageXOffset+u.left,L=!1,A=!1;l==="center"?(D-=(h-u.width)/2,L=!0):l==="right"&&(D-=h-u.width,A=!0),he(e.calendarContainer,"arrowLeft",!L&&!A),he(e.calendarContainer,"arrowCenter",L),he(e.calendarContainer,"arrowRight",A);var O=window.document.body.offsetWidth-(window.pageXOffset+u.right),F=D+h>window.document.body.offsetWidth,J=O+h>window.document.body.offsetWidth;if(he(e.calendarContainer,"rightMost",F),!e.config.static)if(e.calendarContainer.style.top=C+"px",!F)e.calendarContainer.style.left=D+"px",e.calendarContainer.style.right="auto";else if(!J)e.calendarContainer.style.left="auto",e.calendarContainer.style.right=O+"px";else{var G=Je();if(G===void 0)return;var Z=window.document.body.offsetWidth,me=Math.max(0,Z/2-h/2),He=".flatpickr-calendar.centerMost:before",Ze=".flatpickr-calendar.centerMost:after",mt=G.cssRules.length,ft="{left:"+u.left+"px;right:auto;}";he(e.calendarContainer,"rightMost",!1),he(e.calendarContainer,"centerMost",!0),G.insertRule(He+","+Ze+ft,mt),e.calendarContainer.style.left=me+"px",e.calendarContainer.style.right="auto"}}}}function Je(){for(var a=null,r=0;re.currentMonth+e.config.showMonths-1)&&e.config.mode!=="range";if(e.selectedDateElem=h,e.config.mode==="single")e.selectedDates=[n];else if(e.config.mode==="multiple"){var l=Be(n);l?e.selectedDates.splice(parseInt(l),1):e.selectedDates.push(n)}else e.config.mode==="range"&&(e.selectedDates.length===2&&e.clear(!1,!1),e.latestSelectedDateObj=n,e.selectedDates.push(n),Ee(n,e.selectedDates[0],!0)!==0&&e.selectedDates.sort(function(C,D){return C.getTime()-D.getTime()}));if(le(),i){var u=e.currentYear!==n.getFullYear();e.currentYear=n.getFullYear(),e.currentMonth=n.getMonth(),u&&(X("onYearChange"),c()),X("onMonthChange")}if(Pe(),$(),q(),!i&&e.config.mode!=="range"&&e.config.showMonths===1?De(h):e.selectedDateElem!==void 0&&e.hourElement===void 0&&e.selectedDateElem&&e.selectedDateElem.focus(),e.hourElement!==void 0&&e.hourElement!==void 0&&e.hourElement.focus(),e.config.closeOnSelect){var y=e.config.mode==="single"&&!e.config.enableTime,v=e.config.mode==="range"&&e.selectedDates.length===2&&!e.config.enableTime;(y||v)&&Ne()}pe()}}var Oe={locale:[Le,U],showMonths:[t,R,P],minDate:[ce],maxDate:[ce],positionElement:[$e],clickOpens:[function(){e.config.clickOpens===!0?(j(e._input,"focus",e.open),j(e._input,"click",e.open)):(e._input.removeEventListener("focus",e.open),e._input.removeEventListener("click",e.open))}]};function ut(a,r){if(a!==null&&typeof a=="object"){Object.assign(e.config,a);for(var m in a)Oe[m]!==void 0&&Oe[m].forEach(function(h){return h()})}else e.config[a]=r,Oe[a]!==void 0?Oe[a].forEach(function(h){return h()}):bt.indexOf(a)>-1&&(e.config[a]=yt(r));e.redraw(),q(!0)}function Ge(a,r){var m=[];if(a instanceof Array)m=a.map(function(h){return e.parseDate(h,r)});else if(a instanceof Date||typeof a=="number")m=[e.parseDate(a,r)];else if(typeof a=="string")switch(e.config.mode){case"single":case"time":m=[e.parseDate(a,r)];break;case"multiple":m=a.split(e.config.conjunction).map(function(h){return e.parseDate(h,r)});break;case"range":m=a.split(e.l10n.rangeSeparator).map(function(h){return e.parseDate(h,r)});break}else e.config.errorHandler(new Error("Invalid date supplied: "+JSON.stringify(a)));e.selectedDates=e.config.allowInvalidPreload?m:m.filter(function(h){return h instanceof Date&&p(h,!1)}),e.config.mode==="range"&&e.selectedDates.sort(function(h,n){return h.getTime()-n.getTime()})}function Re(a,r,m){if(r===void 0&&(r=!1),m===void 0&&(m=e.config.dateFormat),a!==0&&!a||a instanceof Array&&a.length===0)return e.clear(r);Ge(a,m),e.latestSelectedDateObj=e.selectedDates[e.selectedDates.length-1],e.redraw(),ce(void 0,r),de(),e.selectedDates.length===0&&e.clear(!1),q(r),r&&X("onChange")}function at(a){return a.slice().map(function(r){return typeof r=="string"||typeof r=="number"||r instanceof Date?e.parseDate(r,void 0,!0):r&&typeof r=="object"&&r.from&&r.to?{from:e.parseDate(r.from,void 0),to:e.parseDate(r.to,void 0)}:r}).filter(function(r){return r})}function it(){e.selectedDates=[],e.now=e.parseDate(e.config.now)||new Date;var a=e.config.defaultDate||((e.input.nodeName==="INPUT"||e.input.nodeName==="TEXTAREA")&&e.input.placeholder&&e.input.value===e.input.placeholder?null:e.input.value);a&&Ge(a,e.config.dateFormat),e._initialDate=e.selectedDates.length>0?e.selectedDates[0]:e.config.minDate&&e.config.minDate.getTime()>e.now.getTime()?e.config.minDate:e.config.maxDate&&e.config.maxDate.getTime()0&&(e.latestSelectedDateObj=e.selectedDates[0]),e.config.minTime!==void 0&&(e.config.minTime=e.parseDate(e.config.minTime,"H:i")),e.config.maxTime!==void 0&&(e.config.maxTime=e.parseDate(e.config.maxTime,"H:i")),e.minDateHasTime=!!e.config.minDate&&(e.config.minDate.getHours()>0||e.config.minDate.getMinutes()>0||e.config.minDate.getSeconds()>0),e.maxDateHasTime=!!e.config.maxDate&&(e.config.maxDate.getHours()>0||e.config.maxDate.getMinutes()>0||e.config.maxDate.getSeconds()>0)}function ot(){if(e.input=Me(),!e.input){e.config.errorHandler(new Error("Invalid input element specified"));return}e.input._type=e.input.type,e.input.type="text",e.input.classList.add("flatpickr-input"),e._input=e.input,e.config.altInput&&(e.altInput=K(e.input.nodeName,e.config.altInputClass),e._input=e.altInput,e.altInput.placeholder=e.input.placeholder,e.altInput.disabled=e.input.disabled,e.altInput.required=e.input.required,e.altInput.tabIndex=e.input.tabIndex,e.altInput.type="text",e.input.setAttribute("type","hidden"),!e.config.static&&e.input.parentNode&&e.input.parentNode.insertBefore(e.altInput,e.input.nextSibling)),e.config.allowInput||e._input.setAttribute("readonly","readonly"),$e()}function $e(){e._positionElement=e.config.positionElement||e._input}function ze(){var a=e.config.enableTime?e.config.noCalendar?"time":"datetime-local":"date";e.mobileInput=K("input",e.input.className+" flatpickr-mobile"),e.mobileInput.tabIndex=1,e.mobileInput.type=a,e.mobileInput.disabled=e.input.disabled,e.mobileInput.required=e.input.required,e.mobileInput.placeholder=e.input.placeholder,e.mobileFormatStr=a==="datetime-local"?"Y-m-d\\TH:i:S":a==="date"?"Y-m-d":"H:i:S",e.selectedDates.length>0&&(e.mobileInput.defaultValue=e.mobileInput.value=e.formatDate(e.selectedDates[0],e.mobileFormatStr)),e.config.minDate&&(e.mobileInput.min=e.formatDate(e.config.minDate,"Y-m-d")),e.config.maxDate&&(e.mobileInput.max=e.formatDate(e.config.maxDate,"Y-m-d")),e.input.getAttribute("step")&&(e.mobileInput.step=String(e.input.getAttribute("step"))),e.input.type="hidden",e.altInput!==void 0&&(e.altInput.type="hidden");try{e.input.parentNode&&e.input.parentNode.insertBefore(e.mobileInput,e.input.nextSibling)}catch{}j(e.mobileInput,"change",function(r){e.setDate(we(r).value,!1,e.mobileFormatStr),X("onChange"),X("onClose")})}function rt(a){if(e.isOpen===!0)return e.close();e.open(a)}function X(a,r){if(e.config!==void 0){var m=e.config[a];if(m!==void 0&&m.length>0)for(var h=0;m[h]&&h=0&&Ee(a,e.selectedDates[1])<=0}function Pe(){e.config.noCalendar||e.isMobile||!e.monthNav||(e.yearElements.forEach(function(a,r){var m=new Date(e.currentYear,e.currentMonth,1);m.setMonth(e.currentMonth+r),e.config.showMonths>1||e.config.monthSelectorType==="static"?e.monthElements[r].textContent=ct(m.getMonth(),e.config.shorthandCurrentMonth,e.l10n)+" ":e.monthsDropdownContainer.value=m.getMonth().toString(),a.value=m.getFullYear().toString()}),e._hidePrevMonthArrow=e.config.minDate!==void 0&&(e.currentYear===e.config.minDate.getFullYear()?e.currentMonth<=e.config.minDate.getMonth():e.currentYeare.config.maxDate.getMonth():e.currentYear>e.config.maxDate.getFullYear()))}function We(a){var r=a||(e.config.altInput?e.config.altFormat:e.config.dateFormat);return e.selectedDates.map(function(m){return e.formatDate(m,r)}).filter(function(m,h,n){return e.config.mode!=="range"||e.config.enableTime||n.indexOf(m)===h}).join(e.config.mode!=="range"?e.config.conjunction:e.l10n.rangeSeparator)}function q(a){a===void 0&&(a=!0),e.mobileInput!==void 0&&e.mobileFormatStr&&(e.mobileInput.value=e.latestSelectedDateObj!==void 0?e.formatDate(e.latestSelectedDateObj,e.mobileFormatStr):""),e.input.value=We(e.config.dateFormat),e.altInput!==void 0&&(e.altInput.value=We(e.config.altFormat)),a!==!1&&X("onValueUpdate")}function Ve(a){var r=we(a),m=e.prevMonthNav.contains(r),h=e.nextMonthNav.contains(r);m||h?re(m?-1:1):e.yearElements.indexOf(r)>=0?r.select():r.classList.contains("arrowUp")?e.changeYear(e.currentYear+1):r.classList.contains("arrowDown")&&e.changeYear(e.currentYear-1)}function Xe(a){a.preventDefault();var r=a.type==="keydown",m=we(a),h=m;e.amPM!==void 0&&m===e.amPM&&(e.amPM.textContent=e.l10n.amPM[Ie(e.amPM.textContent===e.l10n.amPM[0])]);var n=parseFloat(h.getAttribute("min")),i=parseFloat(h.getAttribute("max")),l=parseFloat(h.getAttribute("step")),u=parseInt(h.value,10),y=a.delta||(r?a.which===38?1:-1:0),v=u+l*y;if(typeof h.value<"u"&&h.value.length===2){var C=h===e.hourElement,D=h===e.minuteElement;vi&&(v=h===e.hourElement?v-i-Ie(!e.amPM):n,D&&ve(void 0,1,e.hourElement)),e.amPM&&C&&(l===1?v+u===23:Math.abs(v-u)>l)&&(e.amPM.textContent=e.l10n.amPM[Ie(e.amPM.textContent===e.l10n.amPM[0])]),h.value=be(v)}}return S(),e}function Ue(o,s){for(var e=Array.prototype.slice.call(o).filter(function(k){return k instanceof HTMLElement}),E=[],S=0;S2&&N.firstElementChild.setAttribute("aria-expanded","false");var se=N.querySelectorAll("*[id]");Array.from(se).forEach(function(z){if(z.classList.remove("show"),z.childNodes.length>2){var ne=z.querySelectorAll("ul li a");Array.from(ne).forEach(function(Q){Q.hasAttribute("aria-expanded")&&Q.setAttribute("aria-expanded","false")})}})})}}),b.addEventListener("hide.bs.collapse",function(I){I.stopPropagation();var p=b.querySelectorAll(".collapse");Array.from(p).forEach(function(w){childCollapseInstance=bootstrap.Collapse.getInstance(w),childCollapseInstance.hide()})})})}}function W(){var d=document.documentElement.getAttribute("data-layout"),b=sessionStorage.getItem("defaultAttribute"),g=JSON.parse(b);if(g&&(d=="twocolumn"||g["data-layout"]=="twocolumn")){document.querySelector(".navbar-menu")&&(document.querySelector(".navbar-menu").innerHTML=o);var I=document.createElement("ul");I.innerHTML='',Array.from(document.getElementById("navbar-nav").querySelectorAll(".menu-link")).forEach(function(z){I.className="twocolumn-iconview";var ne=document.createElement("li"),Q=z;Q.querySelectorAll("span").forEach(function(Me){Me.classList.add("d-none")}),z.parentElement.classList.contains("twocolumn-item-show")&&z.classList.add("active"),ne.appendChild(Q),I.appendChild(ne),Q.classList.contains("nav-link")&&Q.classList.replace("nav-link","nav-icon"),Q.classList.remove("collapsed","menu-link")});var p=location.pathname=="/"?"index":location.pathname.substring(1);if(p=p.substring(p.lastIndexOf("/")+1),p){var w=document.getElementById("navbar-nav").querySelector('[href="'+p+'"]');if(w){var B=w.closest(".collapse.menu-dropdown");B&&(B.classList.add("show"),B.parentElement.children[0].classList.add("active"),B.parentElement.children[0].setAttribute("aria-expanded","true"),B.parentElement.closest(".collapse.menu-dropdown")&&(B.parentElement.closest(".collapse").classList.add("show"),B.parentElement.closest(".collapse").previousElementSibling&&B.parentElement.closest(".collapse").previousElementSibling.classList.add("active"),B.parentElement.parentElement.parentElement.parentElement.closest(".collapse.menu-dropdown")&&(B.parentElement.parentElement.parentElement.parentElement.closest(".collapse").classList.add("show"),B.parentElement.parentElement.parentElement.parentElement.closest(".collapse").previousElementSibling&&B.parentElement.parentElement.parentElement.parentElement.closest(".collapse").previousElementSibling.classList.add("active"))))}}document.getElementById("two-column-menu").innerHTML=I.outerHTML,Array.from(document.querySelector("#two-column-menu ul").querySelectorAll("li a")).forEach(function(z){var ne=location.pathname=="/"?"index":location.pathname.substring(1);ne=ne.substring(ne.lastIndexOf("/")+1),z.addEventListener("click",function(Q){if(ne=="/"+z.getAttribute("href")&&!z.getAttribute("data-bs-toggle")||document.body.classList.contains("twocolumn-panel")&&document.body.classList.remove("twocolumn-panel"),document.getElementById("navbar-nav").classList.remove("twocolumn-nav-hide"),document.querySelector(".hamburger-icon").classList.remove("open"),Q.target&&Q.target.matches("a.nav-icon")||Q.target&&Q.target.matches("i")){document.querySelector("#two-column-menu ul .nav-icon.active")!==null&&document.querySelector("#two-column-menu ul .nav-icon.active").classList.remove("active"),Q.target.matches("i")?Q.target.closest("a").classList.add("active"):Q.target.classList.add("active");var Me=document.getElementsByClassName("twocolumn-item-show");Me.length>0&&Me[0].classList.remove("twocolumn-item-show");var Le=Q.target.matches("i")?Q.target.closest("a"):Q.target,xe=Le.getAttribute("href").slice(1);document.getElementById(xe)&&document.getElementById(xe).parentElement.classList.add("twocolumn-item-show")}}),ne=="/"+z.getAttribute("href")&&!z.getAttribute("data-bs-toggle")&&(z.classList.add("active"),document.getElementById("navbar-nav").classList.add("twocolumn-nav-hide"),document.querySelector(".hamburger-icon")&&document.querySelector(".hamburger-icon").classList.add("open"))});var T=document.documentElement.getAttribute("data-layout");if(T!=="horizontal"){var N=new SimpleBar(document.getElementById("navbar-nav"));N&&N.getContentElement();var se=new SimpleBar(document.getElementsByClassName("twocolumn-iconview")[0]);se&&se.getContentElement()}}}function x(){var d=document.getElementById("search-close-options"),b=document.getElementById("search-dropdown"),g=document.getElementById("search-options");g&&(g.addEventListener("focus",function(){var I=g.value.length;I>0?(b.classList.add("show"),d.classList.remove("d-none")):(b.classList.remove("show"),d.classList.add("d-none"))}),g.addEventListener("keyup",function(I){var p=g.value.length;if(p>0){b.classList.add("show"),d.classList.remove("d-none");var w=g.value.toLowerCase(),B=document.getElementsByClassName("notify-item");Array.from(B).forEach(function(T){var N="";if(T.querySelector("h6")){var se=T.getElementsByTagName("span")[0].innerText.toLowerCase(),z=T.querySelector("h6").innerText.toLowerCase();z.includes(w)?N=z:N=se}else T.getElementsByTagName("span")&&(N=T.getElementsByTagName("span")[0].innerText.toLowerCase());N&&(T.style.display=N.includes(w)?"block":"none")})}else b.classList.remove("show"),d.classList.add("d-none")}),d.addEventListener("click",function(){g.value="",b.classList.remove("show"),d.classList.add("d-none")}),document.body.addEventListener("click",function(I){I.target.getAttribute("id")!=="search-options"&&(b.classList.remove("show"),d.classList.add("d-none"))}))}function le(){var d=document.getElementById("search-close-options"),b=document.getElementById("search-dropdown-reponsive"),g=document.getElementById("search-options-reponsive");d&&b&&g&&(g.addEventListener("focus",function(){var I=g.value.length;I>0?(b.classList.add("show"),d.classList.remove("d-none")):(b.classList.remove("show"),d.classList.add("d-none"))}),g.addEventListener("keyup",function(){var I=g.value.length;I>0?(b.classList.add("show"),d.classList.remove("d-none")):(b.classList.remove("show"),d.classList.add("d-none"))}),d.addEventListener("click",function(){g.value="",b.classList.remove("show"),d.classList.add("d-none")}),document.body.addEventListener("click",function(I){I.target.getAttribute("id")!=="search-options"&&(b.classList.remove("show"),d.classList.add("d-none"))}))}function de(){(document.documentElement.getAttribute("data-layout")=="vertical"||document.documentElement.getAttribute("data-layout")=="semibox")&&(document.getElementById("two-column-menu").innerHTML="",document.querySelector(".navbar-menu")&&(document.querySelector(".navbar-menu").innerHTML=o),document.getElementById("scrollbar").setAttribute("data-simplebar",""),document.getElementById("navbar-nav").setAttribute("data-simplebar",""),document.getElementById("scrollbar").classList.add("h-100")),document.documentElement.getAttribute("data-layout")=="twocolumn"&&(document.getElementById("scrollbar").removeAttribute("data-simplebar"),document.getElementById("scrollbar").classList.remove("h-100")),document.documentElement.getAttribute("data-layout")=="horizontal"&&Ae()}function fe(){var d=document.getElementsByClassName("vertical-overlay");d&&Array.from(d).forEach(function(b){b.addEventListener("click",function(){document.body.classList.remove("vertical-sidebar-enable"),sessionStorage.getItem("data-layout")=="twocolumn"?document.body.classList.add("twocolumn-panel"):document.documentElement.setAttribute("data-sidebar-size",sessionStorage.getItem("data-sidebar-size"))})})}function ie(){feather.replace();var d=document.documentElement.clientWidth;d<1025&&d>767?(document.body.classList.remove("twocolumn-panel"),sessionStorage.getItem("data-layout")=="twocolumn"&&(document.documentElement.setAttribute("data-layout","twocolumn"),document.getElementById("customizer-layout03")&&document.getElementById("customizer-layout03").click(),W(),ue(),_()),sessionStorage.getItem("data-layout")=="vertical"&&document.documentElement.setAttribute("data-sidebar-size","sm"),sessionStorage.getItem("data-layout")=="semibox"&&document.documentElement.setAttribute("data-sidebar-size","sm"),document.querySelector(".hamburger-icon")&&document.querySelector(".hamburger-icon").classList.add("open")):d>=1025?(document.body.classList.remove("twocolumn-panel"),sessionStorage.getItem("data-layout")=="twocolumn"&&(document.documentElement.setAttribute("data-layout","twocolumn"),document.getElementById("customizer-layout03")&&document.getElementById("customizer-layout03").click(),W(),ue(),_()),sessionStorage.getItem("data-layout")=="vertical"&&document.documentElement.setAttribute("data-sidebar-size",sessionStorage.getItem("data-sidebar-size")),sessionStorage.getItem("data-layout")=="semibox"&&document.documentElement.setAttribute("data-sidebar-size",sessionStorage.getItem("data-sidebar-size")),document.querySelector(".hamburger-icon")&&document.querySelector(".hamburger-icon").classList.remove("open")):d<=767&&(document.body.classList.remove("vertical-sidebar-enable"),document.body.classList.add("twocolumn-panel"),sessionStorage.getItem("data-layout")=="twocolumn"&&(document.documentElement.setAttribute("data-layout","vertical"),oe("vertical"),_()),sessionStorage.getItem("data-layout")!="horizontal"&&document.documentElement.setAttribute("data-sidebar-size","lg"),document.querySelector(".hamburger-icon")&&document.querySelector(".hamburger-icon").classList.add("open"));var b=document.querySelectorAll("#navbar-nav > li.nav-item");Array.from(b).forEach(function(g){g.addEventListener("click",j.bind(this),!1),g.addEventListener("mouseover",j.bind(this),!1)})}function j(d){if(d.target&&d.target.matches("a.nav-link span")){if(ye(d.target.parentElement.nextElementSibling)==!1){d.target.parentElement.nextElementSibling.classList.add("dropdown-custom-right"),d.target.parentElement.parentElement.parentElement.parentElement.classList.add("dropdown-custom-right");var b=d.target.parentElement.nextElementSibling;Array.from(b.querySelectorAll(".menu-dropdown")).forEach(function(I){I.classList.add("dropdown-custom-right")})}else if(ye(d.target.parentElement.nextElementSibling)==!0&&window.innerWidth>=1848)for(var g=document.getElementsByClassName("dropdown-custom-right");g.length>0;)g[0].classList.remove("dropdown-custom-right")}if(d.target&&d.target.matches("a.nav-link")){if(ye(d.target.nextElementSibling)==!1){d.target.nextElementSibling.classList.add("dropdown-custom-right"),d.target.parentElement.parentElement.parentElement.classList.add("dropdown-custom-right");var b=d.target.nextElementSibling;Array.from(b.querySelectorAll(".menu-dropdown")).forEach(function(p){p.classList.add("dropdown-custom-right")})}else if(ye(d.target.nextElementSibling)==!0&&window.innerWidth>=1848)for(var g=document.getElementsByClassName("dropdown-custom-right");g.length>0;)g[0].classList.remove("dropdown-custom-right")}}function pe(){var d=document.documentElement.clientWidth;d>767&&document.querySelector(".hamburger-icon").classList.toggle("open"),document.documentElement.getAttribute("data-layout")==="horizontal"&&(document.body.classList.contains("menu")?document.body.classList.remove("menu"):document.body.classList.add("menu")),document.documentElement.getAttribute("data-layout")==="vertical"&&(d<=1025&&d>767?(document.body.classList.remove("vertical-sidebar-enable"),document.documentElement.getAttribute("data-sidebar-size")=="sm"?document.documentElement.setAttribute("data-sidebar-size",""):document.documentElement.setAttribute("data-sidebar-size","sm")):d>1025?(document.body.classList.remove("vertical-sidebar-enable"),document.documentElement.getAttribute("data-sidebar-size")=="lg"?document.documentElement.setAttribute("data-sidebar-size","sm"):document.documentElement.setAttribute("data-sidebar-size","lg")):d<=767&&(document.body.classList.add("vertical-sidebar-enable"),document.documentElement.setAttribute("data-sidebar-size","lg"))),document.documentElement.getAttribute("data-layout")==="semibox"&&(d>767?document.documentElement.getAttribute("data-sidebar-visibility")=="show"?document.documentElement.getAttribute("data-sidebar-size")=="lg"?document.documentElement.setAttribute("data-sidebar-size","sm"):document.documentElement.setAttribute("data-sidebar-size","lg"):(document.getElementById("sidebar-visibility-show").click(),document.documentElement.setAttribute("data-sidebar-size",document.documentElement.getAttribute("data-sidebar-size"))):d<=767&&(document.body.classList.add("vertical-sidebar-enable"),document.documentElement.setAttribute("data-sidebar-size","lg"))),document.documentElement.getAttribute("data-layout")=="twocolumn"&&(document.body.classList.contains("twocolumn-panel")?document.body.classList.remove("twocolumn-panel"):document.body.classList.add("twocolumn-panel"))}function Fe(){document.addEventListener("DOMContentLoaded",function(){var I=document.getElementsByClassName("code-switcher");Array.from(I).forEach(function(p){p.addEventListener("change",function(){var w=p.closest(".card"),B=w.querySelector(".live-preview"),T=w.querySelector(".code-view");p.checked?(B.classList.add("d-none"),T.classList.remove("d-none")):(B.classList.remove("d-none"),T.classList.add("d-none"))})}),feather.replace()}),window.addEventListener("resize",ie),ie(),Waves.init(),document.addEventListener("scroll",function(){ce()}),window.addEventListener("load",function(){var I=document.documentElement.getAttribute("data-layout");I=="twocolumn"?ue():ve(),fe(),Ce()}),document.getElementById("topnav-hamburger-icon")&&document.getElementById("topnav-hamburger-icon").addEventListener("click",pe);var d=sessionStorage.getItem("defaultAttribute"),b=JSON.parse(d),g=document.documentElement.clientWidth;b["data-layout"]=="twocolumn"&&g<767&&Array.from(document.getElementById("two-column-menu").querySelectorAll("li")).forEach(function(I){I.addEventListener("click",function(p){document.body.classList.remove("twocolumn-panel")})})}function ce(){var d=document.getElementById("page-topbar");d&&(document.body.scrollTop>=50||document.documentElement.scrollTop>=50?d.classList.add("topbar-shadow"):d.classList.remove("topbar-shadow"))}function ue(){feather.replace();var d=location.pathname=="/"?"index":location.pathname.substring(1);if(d=d.substring(d.lastIndexOf("/")+1),d){document.body.className=="twocolumn-panel"&&document.getElementById("two-column-menu").querySelector('[href="'+d+'"]').classList.add("active");var b=document.getElementById("navbar-nav").querySelector('[href="'+d+'"]');if(b){b.classList.add("active");var g=b.closest(".collapse.menu-dropdown");if(g&&g.parentElement.closest(".collapse.menu-dropdown")){if(g.classList.add("show"),g.parentElement.children[0].classList.add("active"),g.parentElement.closest(".collapse.menu-dropdown").parentElement.classList.add("twocolumn-item-show"),g.parentElement.parentElement.parentElement.parentElement.closest(".collapse.menu-dropdown")){var I=g.parentElement.parentElement.parentElement.parentElement.closest(".collapse.menu-dropdown").getAttribute("id");g.parentElement.parentElement.parentElement.parentElement.closest(".collapse.menu-dropdown").parentElement.classList.add("twocolumn-item-show"),g.parentElement.closest(".collapse.menu-dropdown").parentElement.classList.remove("twocolumn-item-show"),document.getElementById("two-column-menu").querySelector('[href="#'+I+'"]')&&document.getElementById("two-column-menu").querySelector('[href="#'+I+'"]').classList.add("active")}var p=g.parentElement.closest(".collapse.menu-dropdown").getAttribute("id");document.getElementById("two-column-menu").querySelector('[href="#'+p+'"]')&&document.getElementById("two-column-menu").querySelector('[href="#'+p+'"]').classList.add("active")}else{b.closest(".collapse.menu-dropdown").parentElement.classList.add("twocolumn-item-show");var p=g.getAttribute("id");document.getElementById("two-column-menu").querySelector('[href="#'+p+'"]')&&document.getElementById("two-column-menu").querySelector('[href="#'+p+'"]').classList.add("active")}}else document.body.classList.add("twocolumn-panel")}}function ve(){var d=location.pathname=="/"?"index":location.pathname.substring(1);if(d=d.substring(d.lastIndexOf("/")+1),d){var b=document.getElementById("navbar-nav").querySelector('[href="'+d+'"]');if(b){b.classList.add("active");var g=b.closest(".collapse.menu-dropdown");g&&(g.classList.add("show"),g.parentElement.children[0].classList.add("active"),g.parentElement.children[0].setAttribute("aria-expanded","true"),g.parentElement.closest(".collapse.menu-dropdown")&&(g.parentElement.closest(".collapse").classList.add("show"),g.parentElement.closest(".collapse").previousElementSibling&&g.parentElement.closest(".collapse").previousElementSibling.classList.add("active"),g.parentElement.parentElement.parentElement.parentElement.closest(".collapse.menu-dropdown")&&(g.parentElement.parentElement.parentElement.parentElement.closest(".collapse").classList.add("show"),g.parentElement.parentElement.parentElement.parentElement.closest(".collapse").previousElementSibling&&(g.parentElement.parentElement.parentElement.parentElement.closest(".collapse").previousElementSibling.classList.add("active"),document.documentElement.getAttribute("data-layout")=="horizontal"&&g.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.closest(".collapse")&&g.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.closest(".collapse").previousElementSibling.classList.add("active")))))}}}function ye(d){if(d){var b=d.offsetTop,g=d.offsetLeft,I=d.offsetWidth,p=d.offsetHeight;if(d.offsetParent)for(;d.offsetParent;)d=d.offsetParent,b+=d.offsetTop,g+=d.offsetLeft;return b>=window.pageYOffset&&g>=window.pageXOffset&&b+p<=window.pageYOffset+window.innerHeight&&g+I<=window.pageXOffset+window.innerWidth}}function te(){if(document.getElementsByClassName("dropdown-item-cart")){let p=function(){var w="$",B=0;Array.from(document.getElementsByClassName("cart-item-price")).forEach(function(T){B+=parseFloat(T.innerHTML)}),document.getElementById("cart-item-total")&&(document.getElementById("cart-item-total").innerHTML=w+B.toFixed(2))};var g=p,d=document.querySelectorAll(".dropdown-item-cart").length;Array.from(document.querySelectorAll("#page-topbar .dropdown-menu-cart .remove-item-btn")).forEach(function(w){w.addEventListener("click",function(B){d--,this.closest(".dropdown-item-cart").remove(),Array.from(document.getElementsByClassName("cartitem-badge")).forEach(function(T){T.innerHTML=d}),p(),document.getElementById("empty-cart")&&(document.getElementById("empty-cart").style.display=d==0?"block":"none"),document.getElementById("checkout-elem")&&(document.getElementById("checkout-elem").style.display=d==0?"none":"block")})}),Array.from(document.getElementsByClassName("cartitem-badge")).forEach(function(w){w.innerHTML=d}),document.getElementById("empty-cart")&&(document.getElementById("empty-cart").style.display="none"),document.getElementById("checkout-elem")&&(document.getElementById("checkout-elem").style.display="block"),p()}if(document.getElementsByClassName("notification-check")){let p=function(){Array.from(document.querySelectorAll("#notificationItemsTabContent .tab-pane")).forEach(function(w){if(w.querySelectorAll(".notification-item").length>0)w.querySelector(".view-all")&&(w.querySelector(".view-all").style.display="block");else{w.querySelector(".view-all")&&(w.querySelector(".view-all").style.display="none");var B=w.querySelector(".empty-notification-elem");B||(w.innerHTML+='
user-pic
Hey! You have no any notifications
')}})};var I=p;p(),Array.from(document.querySelectorAll(".notification-check input")).forEach(function(w){w.addEventListener("change",function(T){T.target.closest(".notification-item").classList.toggle("active");var N=document.querySelectorAll(".notification-check input:checked").length;T.target.closest(".notification-item").classList.contains("active"),N>0?document.getElementById("notification-actions").style.display="block":document.getElementById("notification-actions").style.display="none",document.getElementById("select-content").innerHTML=N});var B=document.getElementById("notificationDropdown");B.addEventListener("hide.bs.dropdown",function(T){w.checked=!1,document.querySelectorAll(".notification-item").forEach(function(N){N.classList.remove("active")}),document.getElementById("notification-actions").style.display=""})});var b=document.getElementById("removeNotificationModal");b.addEventListener("show.bs.modal",function(w){document.getElementById("delete-notification").addEventListener("click",function(){Array.from(document.querySelectorAll(".notification-item")).forEach(function(B){B.classList.contains("active")&&B.remove()}),p(),document.getElementById("NotificationModalbtn-close").click()})})}}function De(){var d=[].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'));d.map(function(g){return new bootstrap.Tooltip(g)});var b=[].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'));b.map(function(g){return new bootstrap.Popover(g)})}function Se(){var d=document.querySelectorAll(".counter-value"),b=250;d&&Array.from(d).forEach(function(I){function p(){var w=+I.getAttribute("data-target"),B=+I.innerText,T=w/b;T<1&&(T=1),B li.nav-item"),I="",p="";Array.from(g).forEach(function(w,B){B+1===d&&(p=w),B+1>d&&(I+=w.outerHTML,w.remove()),B+1===g.length&&p.insertAdjacentHTML&&p.insertAdjacentHTML("afterend",'")})}function oe(d){d=="vertical"?(document.getElementById("two-column-menu").innerHTML="",document.querySelector(".navbar-menu")&&(document.querySelector(".navbar-menu").innerHTML=o),document.getElementById("theme-settings-offcanvas")&&(document.getElementById("sidebar-size").style.display="block",document.getElementById("sidebar-view").style.display="block",document.getElementById("sidebar-color").style.display="block",document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display="block"),document.getElementById("layout-position").style.display="block",document.getElementById("layout-width").style.display="block",document.getElementById("sidebar-visibility").style.display="none"),de(),ve(),Ce(),c()):d=="horizontal"?(Ae(),document.getElementById("theme-settings-offcanvas")&&(document.getElementById("sidebar-size").style.display="none",document.getElementById("sidebar-view").style.display="none",document.getElementById("sidebar-color").style.display="none",document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display="none"),document.getElementById("layout-position").style.display="block",document.getElementById("layout-width").style.display="block",document.getElementById("sidebar-visibility").style.display="none"),ve()):d=="twocolumn"?(document.getElementById("scrollbar").removeAttribute("data-simplebar"),document.getElementById("scrollbar").classList.remove("h-100"),document.getElementById("theme-settings-offcanvas")&&(document.getElementById("sidebar-size").style.display="none",document.getElementById("sidebar-view").style.display="none",document.getElementById("sidebar-color").style.display="block",document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display="block"),document.getElementById("layout-position").style.display="none",document.getElementById("layout-width").style.display="none",document.getElementById("sidebar-visibility").style.display="none")):d=="semibox"&&(document.getElementById("two-column-menu").innerHTML="",document.querySelector(".navbar-menu")&&(document.querySelector(".navbar-menu").innerHTML=o),document.getElementById("theme-settings-offcanvas")&&(document.getElementById("sidebar-size").style.display="block",document.getElementById("sidebar-view").style.display="none",document.getElementById("sidebar-color").style.display="block",document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display="block"),document.getElementById("layout-position").style.display="block",document.getElementById("layout-width").style.display="none",document.getElementById("sidebar-visibility").style.display="block"),de(),ve(),Ce(),c())}function Ce(){document.getElementById("vertical-hover").addEventListener("click",function(){document.documentElement.getAttribute("data-sidebar-size")==="sm-hover"?document.documentElement.setAttribute("data-sidebar-size","sm-hover-active"):(document.documentElement.getAttribute("data-sidebar-size"),document.documentElement.setAttribute("data-sidebar-size","sm-hover"))})}function $(d){switch(d){case d:switch(d["data-layout"]){case"vertical":t("data-layout","vertical"),sessionStorage.setItem("data-layout","vertical"),document.documentElement.setAttribute("data-layout","vertical"),oe("vertical"),_();break;case"horizontal":t("data-layout","horizontal"),sessionStorage.setItem("data-layout","horizontal"),document.documentElement.setAttribute("data-layout","horizontal"),oe("horizontal");break;case"twocolumn":t("data-layout","twocolumn"),sessionStorage.setItem("data-layout","twocolumn"),document.documentElement.setAttribute("data-layout","twocolumn"),oe("twocolumn");break;case"semibox":t("data-layout","semibox"),sessionStorage.setItem("data-layout","semibox"),document.documentElement.setAttribute("data-layout","semibox"),oe("semibox");break;default:sessionStorage.getItem("data-layout")=="vertical"&&sessionStorage.getItem("data-layout")?(t("data-layout","vertical"),sessionStorage.setItem("data-layout","vertical"),document.documentElement.setAttribute("data-layout","vertical"),oe("vertical"),_()):sessionStorage.getItem("data-layout")=="horizontal"?(t("data-layout","horizontal"),sessionStorage.setItem("data-layout","horizontal"),document.documentElement.setAttribute("data-layout","horizontal"),oe("horizontal")):sessionStorage.getItem("data-layout")=="twocolumn"?(t("data-layout","twocolumn"),sessionStorage.setItem("data-layout","twocolumn"),document.documentElement.setAttribute("data-layout","twocolumn"),oe("twocolumn")):sessionStorage.getItem("data-layout")=="semibox"&&(t("data-layout","semibox"),sessionStorage.setItem("data-layout","semibox"),document.documentElement.setAttribute("data-layout","semibox"),oe("semibox"));break}switch(d["data-topbar"]){case"light":t("data-topbar","light"),sessionStorage.setItem("data-topbar","light"),document.documentElement.setAttribute("data-topbar","light");break;case"dark":t("data-topbar","dark"),sessionStorage.setItem("data-topbar","dark"),document.documentElement.setAttribute("data-topbar","dark");break;default:sessionStorage.getItem("data-topbar")=="dark"?(t("data-topbar","dark"),sessionStorage.setItem("data-topbar","dark"),document.documentElement.setAttribute("data-topbar","dark")):(t("data-topbar","light"),sessionStorage.setItem("data-topbar","light"),document.documentElement.setAttribute("data-topbar","light"));break}switch(d["data-sidebar-visibility"]){case"hidden":t("data-sidebar-visibility","hidden"),sessionStorage.setItem("data-sidebar-visibility","hidden"),document.documentElement.setAttribute("data-sidebar-visibility","hidden");break;default:t("data-sidebar-visibility","show"),sessionStorage.setItem("data-sidebar-visibility","show"),document.documentElement.setAttribute("data-sidebar-visibility","show");break}switch(d["data-layout-style"]){case"default":t("data-layout-style","default"),sessionStorage.setItem("data-layout-style","default"),document.documentElement.setAttribute("data-layout-style","default");break;case"detached":t("data-layout-style","detached"),sessionStorage.setItem("data-layout-style","detached"),document.documentElement.setAttribute("data-layout-style","detached");break;default:sessionStorage.getItem("data-layout-style")=="detached"?(t("data-layout-style","detached"),sessionStorage.setItem("data-layout-style","detached"),document.documentElement.setAttribute("data-layout-style","detached")):(t("data-layout-style","default"),sessionStorage.setItem("data-layout-style","default"),document.documentElement.setAttribute("data-layout-style","default"));break}switch(d["data-sidebar-size"]){case"lg":t("data-sidebar-size","lg"),document.documentElement.setAttribute("data-sidebar-size","lg"),sessionStorage.setItem("data-sidebar-size","lg");break;case"sm":t("data-sidebar-size","sm"),document.documentElement.setAttribute("data-sidebar-size","sm"),sessionStorage.setItem("data-sidebar-size","sm");break;case"md":t("data-sidebar-size","md"),document.documentElement.setAttribute("data-sidebar-size","md"),sessionStorage.setItem("data-sidebar-size","md");break;case"sm-hover":t("data-sidebar-size","sm-hover"),document.documentElement.setAttribute("data-sidebar-size","sm-hover"),sessionStorage.setItem("data-sidebar-size","sm-hover");break;default:sessionStorage.getItem("data-sidebar-size")=="sm"?(document.documentElement.setAttribute("data-sidebar-size","sm"),t("data-sidebar-size","sm"),sessionStorage.setItem("data-sidebar-size","sm")):sessionStorage.getItem("data-sidebar-size")=="md"?(document.documentElement.setAttribute("data-sidebar-size","md"),t("data-sidebar-size","md"),sessionStorage.setItem("data-sidebar-size","md")):sessionStorage.getItem("data-sidebar-size")=="sm-hover"?(document.documentElement.setAttribute("data-sidebar-size","sm-hover"),t("data-sidebar-size","sm-hover"),sessionStorage.setItem("data-sidebar-size","sm-hover")):(document.documentElement.setAttribute("data-sidebar-size","lg"),t("data-sidebar-size","lg"),sessionStorage.setItem("data-sidebar-size","lg"));break}switch(d["data-bs-theme"]){case"light":t("data-bs-theme","light"),document.documentElement.setAttribute("data-bs-theme","light"),sessionStorage.setItem("data-bs-theme","light");break;case"dark":t("data-bs-theme","dark"),document.documentElement.setAttribute("data-bs-theme","dark"),sessionStorage.setItem("data-bs-theme","dark");break;default:sessionStorage.getItem("data-bs-theme")&&sessionStorage.getItem("data-bs-theme")=="dark"?(sessionStorage.setItem("data-bs-theme","dark"),document.documentElement.setAttribute("data-bs-theme","dark"),t("data-bs-theme","dark")):(sessionStorage.setItem("data-bs-theme","light"),document.documentElement.setAttribute("data-bs-theme","light"),t("data-bs-theme","light"));break}switch(d["data-layout-width"]){case"fluid":t("data-layout-width","fluid"),document.documentElement.setAttribute("data-layout-width","fluid"),sessionStorage.setItem("data-layout-width","fluid");break;case"boxed":t("data-layout-width","boxed"),document.documentElement.setAttribute("data-layout-width","boxed"),sessionStorage.setItem("data-layout-width","boxed");break;default:sessionStorage.getItem("data-layout-width")=="boxed"?(sessionStorage.setItem("data-layout-width","boxed"),document.documentElement.setAttribute("data-layout-width","boxed"),t("data-layout-width","boxed")):(sessionStorage.setItem("data-layout-width","fluid"),document.documentElement.setAttribute("data-layout-width","fluid"),t("data-layout-width","fluid"));break}switch(d["data-sidebar"]){case"light":t("data-sidebar","light"),sessionStorage.setItem("data-sidebar","light"),document.documentElement.setAttribute("data-sidebar","light");break;case"dark":t("data-sidebar","dark"),sessionStorage.setItem("data-sidebar","dark"),document.documentElement.setAttribute("data-sidebar","dark");break;case"gradient":t("data-sidebar","gradient"),sessionStorage.setItem("data-sidebar","gradient"),document.documentElement.setAttribute("data-sidebar","gradient");break;case"gradient-2":t("data-sidebar","gradient-2"),sessionStorage.setItem("data-sidebar","gradient-2"),document.documentElement.setAttribute("data-sidebar","gradient-2");break;case"gradient-3":t("data-sidebar","gradient-3"),sessionStorage.setItem("data-sidebar","gradient-3"),document.documentElement.setAttribute("data-sidebar","gradient-3");break;case"gradient-4":t("data-sidebar","gradient-4"),sessionStorage.setItem("data-sidebar","gradient-4"),document.documentElement.setAttribute("data-sidebar","gradient-4");break;default:sessionStorage.getItem("data-sidebar")&&sessionStorage.getItem("data-sidebar")=="light"?(sessionStorage.setItem("data-sidebar","light"),t("data-sidebar","light"),document.documentElement.setAttribute("data-sidebar","light")):sessionStorage.getItem("data-sidebar")=="dark"?(sessionStorage.setItem("data-sidebar","dark"),t("data-sidebar","dark"),document.documentElement.setAttribute("data-sidebar","dark")):sessionStorage.getItem("data-sidebar")=="gradient"?(sessionStorage.setItem("data-sidebar","gradient"),t("data-sidebar","gradient"),document.documentElement.setAttribute("data-sidebar","gradient")):sessionStorage.getItem("data-sidebar")=="gradient-2"?(sessionStorage.setItem("data-sidebar","gradient-2"),t("data-sidebar","gradient-2"),document.documentElement.setAttribute("data-sidebar","gradient-2")):sessionStorage.getItem("data-sidebar")=="gradient-3"?(sessionStorage.setItem("data-sidebar","gradient-3"),t("data-sidebar","gradient-3"),document.documentElement.setAttribute("data-sidebar","gradient-3")):sessionStorage.getItem("data-sidebar")=="gradient-4"&&(sessionStorage.setItem("data-sidebar","gradient-4"),t("data-sidebar","gradient-4"),document.documentElement.setAttribute("data-sidebar","gradient-4"));break}switch(d["data-sidebar-image"]){case"none":t("data-sidebar-image","none"),sessionStorage.setItem("data-sidebar-image","none"),document.documentElement.setAttribute("data-sidebar-image","none");break;case"img-1":t("data-sidebar-image","img-1"),sessionStorage.setItem("data-sidebar-image","img-1"),document.documentElement.setAttribute("data-sidebar-image","img-1");break;case"img-2":t("data-sidebar-image","img-2"),sessionStorage.setItem("data-sidebar-image","img-2"),document.documentElement.setAttribute("data-sidebar-image","img-2");break;case"img-3":t("data-sidebar-image","img-3"),sessionStorage.setItem("data-sidebar-image","img-3"),document.documentElement.setAttribute("data-sidebar-image","img-3");break;case"img-4":t("data-sidebar-image","img-4"),sessionStorage.setItem("data-sidebar-image","img-4"),document.documentElement.setAttribute("data-sidebar-image","img-4");break;default:sessionStorage.getItem("data-sidebar-image")&&sessionStorage.getItem("data-sidebar-image")=="none"?(sessionStorage.setItem("data-sidebar-image","none"),t("data-sidebar-image","none"),document.documentElement.setAttribute("data-sidebar-image","none")):sessionStorage.getItem("data-sidebar-image")=="img-1"?(sessionStorage.setItem("data-sidebar-image","img-1"),t("data-sidebar-image","img-1"),document.documentElement.setAttribute("data-sidebar-image","img-2")):sessionStorage.getItem("data-sidebar-image")=="img-2"?(sessionStorage.setItem("data-sidebar-image","img-2"),t("data-sidebar-image","img-2"),document.documentElement.setAttribute("data-sidebar-image","img-2")):sessionStorage.getItem("data-sidebar-image")=="img-3"?(sessionStorage.setItem("data-sidebar-image","img-3"),t("data-sidebar-image","img-3"),document.documentElement.setAttribute("data-sidebar-image","img-3")):sessionStorage.getItem("data-sidebar-image")=="img-4"&&(sessionStorage.setItem("data-sidebar-image","img-4"),t("data-sidebar-image","img-4"),document.documentElement.setAttribute("data-sidebar-image","img-4"));break}switch(d["data-layout-position"]){case"fixed":t("data-layout-position","fixed"),sessionStorage.setItem("data-layout-position","fixed"),document.documentElement.setAttribute("data-layout-position","fixed");break;case"scrollable":t("data-layout-position","scrollable"),sessionStorage.setItem("data-layout-position","scrollable"),document.documentElement.setAttribute("data-layout-position","scrollable");break;default:sessionStorage.getItem("data-layout-position")&&sessionStorage.getItem("data-layout-position")=="scrollable"?(t("data-layout-position","scrollable"),sessionStorage.setItem("data-layout-position","scrollable"),document.documentElement.setAttribute("data-layout-position","scrollable")):(t("data-layout-position","fixed"),sessionStorage.setItem("data-layout-position","fixed"),document.documentElement.setAttribute("data-layout-position","fixed"));break}switch(d["data-preloader"]){case"disable":t("data-preloader","disable"),sessionStorage.setItem("data-preloader","disable"),document.documentElement.setAttribute("data-preloader","disable");break;case"enable":t("data-preloader","enable"),sessionStorage.setItem("data-preloader","enable"),document.documentElement.setAttribute("data-preloader","enable");var b=document.getElementById("preloader");b&&window.addEventListener("load",function(){b.style.opacity="0",b.style.visibility="hidden"});break;default:if(sessionStorage.getItem("data-preloader")&&sessionStorage.getItem("data-preloader")=="disable")t("data-preloader","disable"),sessionStorage.setItem("data-preloader","disable"),document.documentElement.setAttribute("data-preloader","disable");else if(sessionStorage.getItem("data-preloader")=="enable"){t("data-preloader","enable"),sessionStorage.setItem("data-preloader","enable"),document.documentElement.setAttribute("data-preloader","enable");var b=document.getElementById("preloader");b&&window.addEventListener("load",function(){b.style.opacity="0",b.style.visibility="hidden"})}else document.documentElement.setAttribute("data-preloader","disable");break}switch(d["data-body-image"]){case"img-1":t("data-body-image","img-1"),sessionStorage.setItem("data-sidebabodyr-image","img-1"),document.documentElement.setAttribute("data-body-image","img-1"),document.getElementById("theme-settings-offcanvas")&&document.documentElement.removeAttribute("data-sidebar-image");break;case"img-2":t("data-body-image","img-2"),sessionStorage.setItem("data-body-image","img-2"),document.documentElement.setAttribute("data-body-image","img-2");break;case"img-3":t("data-body-image","img-3"),sessionStorage.setItem("data-body-image","img-3"),document.documentElement.setAttribute("data-body-image","img-3");break;case"none":t("data-body-image","none"),sessionStorage.setItem("data-body-image","none"),document.documentElement.setAttribute("data-body-image","none");break;default:sessionStorage.getItem("data-body-image")&&sessionStorage.getItem("data-body-image")=="img-1"?(sessionStorage.setItem("data-body-image","img-1"),t("data-body-image","img-1"),document.documentElement.setAttribute("data-body-image","img-1"),document.getElementById("theme-settings-offcanvas")&&document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display="none",document.documentElement.removeAttribute("data-sidebar-image"))):sessionStorage.getItem("data-body-image")=="img-2"?(sessionStorage.setItem("data-body-image","img-2"),t("data-body-image","img-2"),document.documentElement.setAttribute("data-body-image","img-2")):sessionStorage.getItem("data-body-image")=="img-3"?(sessionStorage.setItem("data-body-image","img-3"),t("data-body-image","img-3"),document.documentElement.setAttribute("data-body-image","img-3")):sessionStorage.getItem("data-body-image")=="none"&&(sessionStorage.setItem("data-body-image","none"),t("data-body-image","none"),document.documentElement.setAttribute("data-body-image","none"));break}}}function c(){setTimeout(function(){var d=document.getElementById("navbar-nav");if(d){var b=d.querySelector(".nav-item .active"),g=b?b.offsetTop:0;if(g>300){var I=document.getElementsByClassName("app-menu")?document.getElementsByClassName("app-menu")[0]:"";I&&I.querySelector(".simplebar-content-wrapper")&&setTimeout(function(){g==330?I.querySelector(".simplebar-content-wrapper").scrollTop=g+85:I.querySelector(".simplebar-content-wrapper").scrollTop=g},0)}}},250)}var f=new Event("resize");function t(d,b){Array.from(document.querySelectorAll("input[name="+d+"]")).forEach(function(g){b==g.value?g.checked=!0:g.checked=!1,g.addEventListener("change",function(){document.documentElement.setAttribute(d,g.value),sessionStorage.setItem(d,g.value),S(),d=="data-layout-width"&&g.value=="boxed"?(document.documentElement.setAttribute("data-sidebar-size","sm-hover"),sessionStorage.setItem("data-sidebar-size","sm-hover"),document.getElementById("sidebar-size-small-hover").checked=!0):d=="data-layout-width"&&g.value=="fluid"&&(document.documentElement.setAttribute("data-sidebar-size","lg"),sessionStorage.setItem("data-sidebar-size","lg"),document.getElementById("sidebar-size-default").checked=!0),d=="data-layout"&&(g.value=="vertical"?(oe("vertical"),_(),feather.replace()):g.value=="horizontal"?(document.getElementById("sidebarimg-none")&&document.getElementById("sidebarimg-none").click(),oe("horizontal"),feather.replace()):g.value=="twocolumn"?(oe("twocolumn"),document.documentElement.setAttribute("data-layout-width","fluid"),document.getElementById("layout-width-fluid").click(),W(),ue(),_(),feather.replace()):g.value=="semibox"&&(oe("semibox"),document.documentElement.setAttribute("data-layout-width","fluid"),document.getElementById("layout-width-fluid").click(),document.documentElement.setAttribute("data-layout-style","default"),document.getElementById("sidebar-view-default").click(),_(),feather.replace()));var I="block";if(document.documentElement.getAttribute("data-layout")=="semibox"&&(document.documentElement.getAttribute("data-sidebar-visibility")=="hidden"?(document.documentElement.removeAttribute("data-sidebar"),document.documentElement.removeAttribute("data-sidebar-image"),document.documentElement.removeAttribute("data-sidebar-size"),I="none"):(document.documentElement.setAttribute("data-sidebar",sessionStorage.getItem("data-sidebar")),document.documentElement.setAttribute("data-sidebar-image",sessionStorage.getItem("data-sidebar-image")),document.documentElement.setAttribute("data-sidebar-size",sessionStorage.getItem("data-sidebar-size")))),document.getElementById("sidebar-size").style.display=I,document.getElementById("sidebar-color").style.display=I,document.getElementById("sidebar-img")&&(document.getElementById("sidebar-img").style.display=I),d=="data-preloader"&&g.value=="enable"){document.documentElement.setAttribute("data-preloader","enable");var p=document.getElementById("preloader");p&&setTimeout(function(){p.style.opacity="0",p.style.visibility="hidden"},1e3),document.getElementById("customizerclose-btn").click()}else d=="data-preloader"&&g.value=="disable"&&(document.documentElement.setAttribute("data-preloader","disable"),document.getElementById("customizerclose-btn").click());d=="data-bs-theme"&&window.dispatchEvent(f)})}),document.getElementById("collapseBgGradient")&&Array.from(document.querySelectorAll("#collapseBgGradient .form-check input")).forEach(function(g){var I=document.getElementById("collapseBgGradient");if(g.checked==!0){var p=new bootstrap.Collapse(I,{toggle:!1});p.show()}document.querySelector("[data-bs-target='#collapseBgGradient']")&&document.querySelector("[data-bs-target='#collapseBgGradient']").addEventListener("click",function(w){document.getElementById("sidebar-color-gradient").click()})}),document.querySelectorAll("[data-bs-target='#collapseBgGradient.show']")&&Array.from(document.querySelectorAll("[data-bs-target='#collapseBgGradient.show']")).forEach(function(g){g.addEventListener("click",function(){var I=document.getElementById("collapseBgGradient"),p=new bootstrap.Collapse(I,{toggle:!1});p.hide()})}),Array.from(document.querySelectorAll("[name='data-sidebar']")).forEach(function(g){document.querySelector("[data-bs-target='#collapseBgGradient']")&&(document.querySelector("#collapseBgGradient .form-check input:checked")?document.querySelector("[data-bs-target='#collapseBgGradient']").classList.add("active"):document.querySelector("[data-bs-target='#collapseBgGradient']").classList.remove("active"),g.addEventListener("change",function(){document.querySelector("#collapseBgGradient .form-check input:checked")?document.querySelector("[data-bs-target='#collapseBgGradient']").classList.add("active"):document.querySelector("[data-bs-target='#collapseBgGradient']").classList.remove("active")}))})}function H(){if(sessionStorage.getItem("defaultAttribute")){var b={};b["data-layout"]=sessionStorage.getItem("data-layout"),b["data-sidebar-size"]=sessionStorage.getItem("data-sidebar-size"),b["data-bs-theme"]=sessionStorage.getItem("data-bs-theme"),b["data-layout-width"]=sessionStorage.getItem("data-layout-width"),b["data-sidebar"]=sessionStorage.getItem("data-sidebar"),b["data-sidebar-image"]=sessionStorage.getItem("data-sidebar-image"),b["data-layout-position"]=sessionStorage.getItem("data-layout-position"),b["data-layout-style"]=sessionStorage.getItem("data-layout-style"),b["data-topbar"]=sessionStorage.getItem("data-topbar"),b["data-preloader"]=sessionStorage.getItem("data-preloader"),b["data-body-image"]=sessionStorage.getItem("data-body-image"),$(b)}else{var d=document.documentElement.attributes,b={};Array.from(d).forEach(function(g){if(g&&g.nodeName&&g.nodeName!="undefined"){var I=g.nodeName;b[I]=g.nodeValue,sessionStorage.setItem(I,g.nodeValue)}}),sessionStorage.setItem("defaultAttribute",JSON.stringify(b)),$(b)}}function Y(){var d=document.querySelector('[data-toggle="fullscreen"]');d&&d.addEventListener("click",function(g){g.preventDefault(),document.body.classList.toggle("fullscreen-enable"),!document.fullscreenElement&&!document.mozFullScreenElement&&!document.webkitFullscreenElement?document.documentElement.requestFullscreen?document.documentElement.requestFullscreen():document.documentElement.mozRequestFullScreen?document.documentElement.mozRequestFullScreen():document.documentElement.webkitRequestFullscreen&&document.documentElement.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT):document.cancelFullScreen?document.cancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen&&document.webkitCancelFullScreen()}),document.addEventListener("fullscreenchange",b),document.addEventListener("webkitfullscreenchange",b),document.addEventListener("mozfullscreenchange",b);function b(){!document.webkitIsFullScreen&&!document.mozFullScreen&&!document.msFullscreenElement&&document.body.classList.remove("fullscreen-enable")}}function P(d,b,g,I){var p=document.getElementById(g);I.setAttribute(d,b),p&&document.getElementById(g).click()}function U(){var d=document.getElementsByTagName("HTML")[0],b=document.querySelectorAll(".light-dark-mode");b&&b.length&&b[0].addEventListener("click",function(g){d.hasAttribute("data-bs-theme")&&d.getAttribute("data-bs-theme")=="dark"?P("data-bs-theme","light","layout-mode-light",d):P("data-bs-theme","dark","layout-mode-dark",d),window.dispatchEvent(f)})}function ee(){document.getElementById("reset-layout")&&document.getElementById("reset-layout").addEventListener("click",function(){sessionStorage.clear(),window.location.reload()})}function re(){H(),W(),x(),le(),Y(),U(),Fe(),Se(),de(),te(),De(),ee(),R(),S(),_(),c()}re();var V;function ke(){var d=document.documentElement.getAttribute("data-layout");if(d!=="horizontal"){if(document.getElementById("navbar-nav")){var b=new SimpleBar(document.getElementById("navbar-nav"));b&&b.getContentElement()}if(document.getElementsByClassName("twocolumn-iconview")[0]){var g=new SimpleBar(document.getElementsByClassName("twocolumn-iconview")[0]);g&&g.getContentElement()}clearTimeout(V)}}window.addEventListener("resize",function(){V&&clearTimeout(V),V=setTimeout(ke,2e3)})})();var Ct=document.getElementById("back-to-top");if(Ct){let o=function(){document.body.scrollTop>100||document.documentElement.scrollTop>100?Ct.style.display="block":Ct.style.display="none"};var Rt=o;window.onscroll=function(){o()}}});export default Ht();