/* flatpickr v4.0.6,, @license MIT */ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.flatpickr=t()}(this,function(){"use strict";function e(e,t,n){return!1!==n?new Date(e.getTime()).setHours(0,0,0,0)-new Date(t.getTime()).setHours(0,0,0,0):e.getTime()-t.getTime()}function t(e,t,n){void 0===n&&(n=!1);var a;return function(){var i=this,o=arguments;null!==a&&clearTimeout(a),a=window.setTimeout(function(){a=null,n||e.apply(i,o)},t),n&&!a&&e.apply(i,o)}}function n(e){return(e.wheelDelta||-e.deltaY)>=0?1:-1}function a(e,t,n){if(!0===n)return e.classList.add(t);e.classList.remove(t)}function i(e,t,n){var a=window.document.createElement(e);return t=t||"",n=n||"",a.className=t,void 0!==n&&(a.textContent=n),a}function o(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function r(e,t){return t(e)?e:e.parentNode?r(e.parentNode,t):void 0}function l(e){var t=i("div","numInputWrapper"),n=i("input","numInput "+e),a=i("span","arrowUp"),o=i("span","arrowDown");return n.type="text",n.pattern="\\d*",t.appendChild(n),t.appendChild(a),t.appendChild(o),t}function c(c,d){function m(){ye.utils={getDaysInMonth:function(e,t){return void 0===e&&(e=ye.currentMonth),void 0===t&&(t=ye.currentYear),1===e&&(t%4==0&&t%100!=0||t%400==0)?29:ye.l10n.daysInMonth[e]}}}function g(e){return e.bind(ye)}function D(e){ye.config.noCalendar&&!ye.selectedDates.length&&(ye.setDate((new Date).setHours(ye.config.defaultHour,ye.config.defaultMinute,ye.config.defaultSeconds),!1),E(),Ce()),be(e),0!==ye.selectedDates.length&&(!ye.minDateHasTime||"input"!==e.type||e.target.value.length>=2?(E(),Ce()):setTimeout(function(){E(),Ce()},1e3))}function y(e,t){return e%12+12*h("PM"===t)}function x(e){switch(e%24){case 0:case 12:return 12;default:return e%12}}function E(){if(void 0!==ye.hourElement&&void 0!==ye.minuteElement){var t=(parseInt(ye.hourElement.value.slice(-2),10)||0)%24,n=(parseInt(ye.minuteElement.value,10)||0)%60,a=void 0!==ye.secondElement?(parseInt(ye.secondElement.value,10)||0)%60:0;void 0!==ye.amPM&&(t=y(t,ye.amPM.textContent)),ye.config.minDate&&ye.minDateHasTime&&ye.latestSelectedDateObj&&0===e(ye.latestSelectedDateObj,ye.config.minDate)&&(t=Math.max(t,ye.config.minDate.getHours()))===ye.config.minDate.getHours()&&(n=Math.max(n,ye.config.minDate.getMinutes())),ye.config.maxDate&&ye.maxDateHasTime&&ye.latestSelectedDateObj&&0===e(ye.latestSelectedDateObj,ye.config.maxDate)&&(t=Math.min(t,ye.config.maxDate.getHours()))===ye.config.maxDate.getHours()&&(n=Math.min(n,ye.config.maxDate.getMinutes())),N(t,n,a)}}function k(e){var t=e||ye.latestSelectedDateObj;t&&N(t.getHours(),t.getMinutes(),t.getSeconds())}function N(e,t,n){void 0!==ye.latestSelectedDateObj&&ye.latestSelectedDateObj.setHours(e%24,t,n||0,0),ye.hourElement&&ye.minuteElement&&!ye.isMobile&&(ye.hourElement.value=p(ye.config.time_24hr?e:(12+e)%12+12*h(e%12==0)),ye.minuteElement.value=p(t),void 0!==ye.amPM&&(ye.amPM.textContent=e>=12?"PM":"AM"),void 0!==ye.secondElement&&(ye.secondElement.value=p(n)))}function S(e){var t=parseInt(e.target.value)+(e.delta||0);4!==t.toString().length&&"Enter"!==e.key||(ye.currentYearElement.blur(),/[^\d]/.test(t.toString())||Z(t))}function T(e,t,n){return t instanceof Array?t.forEach(function(t){return T(e,t,n)}):e instanceof Array?e.forEach(function(e){return T(e,t,n)}):(e.addEventListener(t,n),void ye._handlers.push({element:e,event:t,handler:n}))}function I(e){return function(t){return 1===t.which&&e(t)}}function Y(){ge("onChange")}function _(){if(ye.config.wrap&&["open","close","toggle","clear"].forEach(function(e){Array.prototype.forEach.call(ye.element.querySelectorAll("[data-"+e+"]"),function(t){return T(t,"click",ye[e])})}),ye.isMobile)me();else{var e=t(te,50);if(ye._debouncedChange=t(Y,300),"range"===ye.config.mode&&ye.daysContainer&&T(ye.daysContainer,"mouseover",function(e){return ee(e.target)}),T(window.document.body,"keydown",X),ye.config.static||T(ye._input,"keydown",X),ye.config.inline||ye.config.static||T(window,"resize",e),void 0!==window.ontouchstart&&T(window.document.body,"touchstart",V),T(window.document.body,"mousedown",I(V)),T(ye._input,"blur",V),!0===ye.config.clickOpens&&(T(ye._input,"focus",ye.open),T(ye._input,"mousedown",I(ye.open))),void 0!==ye.daysContainer&&(ye.monthNav.addEventListener("wheel",function(e){return e.preventDefault()}),T(ye.monthNav,"wheel",t(we,10)),T(ye.monthNav,"mousedown",I(Me)),T(ye.monthNav,["keyup","increment"],S),T(ye.daysContainer,"mousedown",I(le)),ye.config.animate&&(T(ye.daysContainer,["webkitAnimationEnd","animationend"],F),T(ye.monthNav,["webkitAnimationEnd","animationend"],A))),void 0!==ye.timeContainer&&void 0!==ye.minuteElement&&void 0!==ye.hourElement){T(ye.timeContainer,["wheel","input","increment"],D),T(ye.timeContainer,"mousedown",I(P)),T(ye.timeContainer,["wheel","increment"],ye._debouncedChange),T(ye.timeContainer,"input",Y),T([ye.hourElement,ye.minuteElement],["focus","click"],function(e){return e.target.select()}),void 0!==ye.secondElement&&T(ye.secondElement,"focus",function(){return ye.secondElement&&ye.secondElement.select()}),void 0!==ye.amPM&&T(ye.amPM,"mousedown",I(function(e){D(e),Y()}))}}}function O(){ye._animationLoop.forEach(function(e){return e()}),ye._animationLoop=[]}function F(e){if(ye.daysContainer&&ye.daysContainer.childNodes.length>1)switch(e.animationName){case"fpSlideLeft":ye.daysContainer.lastChild&&ye.daysContainer.lastChild.classList.remove("slideLeftNew"),ye.daysContainer.removeChild(ye.daysContainer.firstChild),ye.days=ye.daysContainer.firstChild,O();break;case"fpSlideRight":ye.daysContainer.firstChild&&ye.daysContainer.firstChild.classList.remove("slideRightNew"),ye.daysContainer.removeChild(ye.daysContainer.lastChild),ye.days=ye.daysContainer.firstChild,O()}}function A(e){switch(e.animationName){case"fpSlideLeftNew":case"fpSlideRightNew":ye.navigationCurrentMonth.classList.remove("slideLeftNew"),ye.navigationCurrentMonth.classList.remove("slideRightNew");for(var t=ye.navigationCurrentMonth;t.nextSibling&&/curr/.test(t.nextSibling.className);)ye.monthNav.removeChild(t.nextSibling);for(;t.previousSibling&&/curr/.test(t.previousSibling.className);)ye.monthNav.removeChild(t.previousSibling);ye.oldCurMonth=void 0}}function L(e){var t=void 0!==e?ue(e):ye.latestSelectedDateObj||(ye.config.minDate&&ye.config.minDate>ye.now?ye.config.minDate:ye.config.maxDate&&ye.config.maxDateye.minRangeDate&&nye.selectedDates[0]&&(ye.maxRangeDate=n)),"range"===ye.config.mode&&(ve(n)&&!he(n)&&c.classList.add("inRange"),1===ye.selectedDates.length&&void 0!==ye.minRangeDate&&void 0!==ye.maxRangeDate&&(nye.maxRangeDate)&&c.classList.add("notAllowed")),ye.weekNumbers&&"prevMonthDay"!==t&&o%7==1&&ye.weekNumbers.insertAdjacentHTML("beforeend",""+ye.config.getWeek(n)+""),ge("onDayCreate",c),c}function W(e,t){var n=e+t||0,a=void 0!==e?ye.days.childNodes[n]:ye.selectedDateElem||ye.todayDateElem||ye.days.childNodes[0],i=function(){(a=a||ye.days.childNodes[n]).focus(),"range"===ye.config.mode&&ee(a)};if(void 0===a&&0!==t)return t>0?(ye.changeMonth(1,!0,void 0,!0),n%=42):t<0&&(ye.changeMonth(-1,!0,void 0,!0),n+=42),B(i);i()}function B(e){!0===ye.config.animate?ye._animationLoop.push(e):e()}function J(e){if(void 0!==ye.daysContainer){var t=(new Date(ye.currentYear,ye.currentMonth,1).getDay()-ye.l10n.firstDayOfWeek+7)%7,n="range"===ye.config.mode,a=ye.utils.getDaysInMonth((ye.currentMonth-1+12)%12),r=ye.utils.getDaysInMonth(),l=window.document.createDocumentFragment(),c=a+1-t,d=0;for(ye.weekNumbers&&ye.weekNumbers.firstChild&&(ye.weekNumbers.textContent=""),n&&(ye.minRangeDate=new Date(ye.currentYear,ye.currentMonth-1,c),ye.maxRangeDate=new Date(ye.currentYear,ye.currentMonth+1,(42-t)%r));c<=a;c++,d++)l.appendChild(R("prevMonthDay",new Date(ye.currentYear,ye.currentMonth-1,c),c,d));for(c=1;c<=r;c++,d++)l.appendChild(R("",new Date(ye.currentYear,ye.currentMonth,c),c,d));for(var s=r+1;s<=42-t;s++,d++)l.appendChild(R("nextMonthDay",new Date(ye.currentYear,ye.currentMonth+1,s%r),s,d));n&&1===ye.selectedDates.length&&l.childNodes[0]?(ye._hidePrevMonthArrow=ye._hidePrevMonthArrow||!!ye.minRangeDate&&ye.minRangeDate>l.childNodes[0].dateObj,ye._hideNextMonthArrow=ye._hideNextMonthArrow||!!ye.maxRangeDate&&ye.maxRangeDate1;)ye.daysContainer.removeChild(ye.daysContainer.firstChild);else o(ye.daysContainer);e&&e>=0?ye.daysContainer.appendChild(u):ye.daysContainer.insertBefore(u,ye.daysContainer.firstChild),ye.days=ye.daysContainer.childNodes[0]}}function K(){var e=window.document.createDocumentFragment();ye.monthNav=i("div","flatpickr-month"),ye.prevMonthNav=i("span","flatpickr-prev-month"),ye.prevMonthNav.innerHTML=ye.config.prevArrow,ye.currentMonthElement=i("span","cur-month"),ye.currentMonthElement.title=ye.l10n.scrollTitle;var t=l("cur-year");return ye.currentYearElement=t.childNodes[0],ye.currentYearElement.title=ye.l10n.scrollTitle,ye.config.minDate&&(ye.currentYearElement.min=ye.config.minDate.getFullYear().toString()),ye.config.maxDate&&(ye.currentYearElement.max=ye.config.maxDate.getFullYear().toString(),ye.currentYearElement.disabled=!!ye.config.minDate&&ye.config.minDate.getFullYear()===ye.config.maxDate.getFullYear()),ye.nextMonthNav=i("span","flatpickr-next-month"),ye.nextMonthNav.innerHTML=ye.config.nextArrow,ye.navigationCurrentMonth=i("span","flatpickr-current-month"),ye.navigationCurrentMonth.appendChild(ye.currentMonthElement),ye.navigationCurrentMonth.appendChild(t),e.appendChild(ye.prevMonthNav),e.appendChild(ye.navigationCurrentMonth),e.appendChild(ye.nextMonthNav),ye.monthNav.appendChild(e),Object.defineProperty(ye,"_hidePrevMonthArrow",{get:function(){return ye.__hidePrevMonthArrow},set:function(e){ye.__hidePrevMonthArrow!==e&&(ye.prevMonthNav.style.display=e?"none":"block"),ye.__hidePrevMonthArrow=e}}),Object.defineProperty(ye,"_hideNextMonthArrow",{get:function(){return ye.__hideNextMonthArrow},set:function(e){ye.__hideNextMonthArrow!==e&&(ye.nextMonthNav.style.display=e?"none":"block"),ye.__hideNextMonthArrow=e}}),De(),ye.monthNav}function U(){ye.calendarContainer.classList.add("hasTime"),ye.config.noCalendar&&ye.calendarContainer.classList.add("noCalendar"),ye.timeContainer=i("div","flatpickr-time"),ye.timeContainer.tabIndex=-1;var e=i("span","flatpickr-time-separator",":"),t=l("flatpickr-hour");ye.hourElement=t.childNodes[0];var n=l("flatpickr-minute");if(ye.minuteElement=n.childNodes[0],ye.hourElement.tabIndex=ye.minuteElement.tabIndex=-1,ye.hourElement.value=p(ye.latestSelectedDateObj?ye.latestSelectedDateObj.getHours():ye.config.time_24hr?ye.config.defaultHour:x(ye.config.defaultHour)),ye.minuteElement.value=p(ye.latestSelectedDateObj?ye.latestSelectedDateObj.getMinutes():ye.config.defaultMinute),ye.hourElement.step=ye.config.hourIncrement.toString(),ye.minuteElement.step=ye.config.minuteIncrement.toString(),ye.hourElement.min=ye.config.time_24hr?"0":"1",ye.hourElement.max=ye.config.time_24hr?"23":"12",ye.minuteElement.min="0",ye.minuteElement.max="59",ye.hourElement.title=ye.minuteElement.title=ye.l10n.scrollTitle,ye.timeContainer.appendChild(t),ye.timeContainer.appendChild(e),ye.timeContainer.appendChild(n),ye.config.time_24hr&&ye.timeContainer.classList.add("time24hr"),ye.config.enableSeconds){ye.timeContainer.classList.add("hasSeconds");var a=l("flatpickr-second");ye.secondElement=a.childNodes[0],ye.secondElement.value=p(ye.latestSelectedDateObj?ye.latestSelectedDateObj.getSeconds():ye.config.defaultSeconds),ye.secondElement.step=ye.minuteElement.step,ye.secondElement.min=ye.minuteElement.min,ye.secondElement.max=ye.minuteElement.max,ye.timeContainer.appendChild(i("span","flatpickr-time-separator",":")),ye.timeContainer.appendChild(a)}return ye.config.time_24hr||(ye.amPM=i("span","flatpickr-am-pm",ye.l10n.amPM[h((ye.latestSelectedDateObj?ye.hourElement.value:ye.config.defaultHour)>11)]),ye.amPM.title=ye.l10n.toggleTitle,ye.amPM.tabIndex=-1,ye.timeContainer.appendChild(ye.amPM)),ye.timeContainer}function $(){ye.weekdayContainer||(ye.weekdayContainer=i("div","flatpickr-weekdays"));var e=ye.l10n.firstDayOfWeek,t=ye.l10n.weekdays.shorthand.slice();return e>0&&e\n "+t.join("")+"\n \n ",ye.weekdayContainer}function q(){ye.calendarContainer.classList.add("hasWeeks");var e=i("div","flatpickr-weekwrapper");e.appendChild(i("span","flatpickr-weekday",ye.l10n.weekAbbreviation));var t=i("div","flatpickr-weeks");return e.appendChild(t),{weekWrapper:e,weekNumbers:t}}function z(e,t,n,a){void 0===t&&(t=!0),void 0===n&&(n=ye.config.animate),void 0===a&&(a=!1);var i=t?e:e-ye.currentMonth;if(!(i<0&&ye._hidePrevMonthArrow||i>0&&ye._hideNextMonthArrow)){if(ye.currentMonth+=i,(ye.currentMonth<0||ye.currentMonth>11)&&(ye.currentYear+=ye.currentMonth>11?1:-1,ye.currentMonth=(ye.currentMonth+12)%12,ge("onYearChange")),J(n?i:void 0),!n)return ge("onMonthChange"),De();var o=ye.navigationCurrentMonth;if(i<0)for(;o.nextSibling&&/curr/.test(o.nextSibling.className);)ye.monthNav.removeChild(o.nextSibling);else if(i>0)for(;o.previousSibling&&/curr/.test(o.previousSibling.className);)ye.monthNav.removeChild(o.previousSibling);ye.oldCurMonth=ye.navigationCurrentMonth,ye.navigationCurrentMonth=ye.monthNav.insertBefore(ye.oldCurMonth.cloneNode(!0),i>0?ye.oldCurMonth.nextSibling:ye.oldCurMonth);var r=ye.daysContainer;if(r.firstChild&&r.lastChild&&(i>0?(r.firstChild.classList.add("slideLeft"),r.lastChild.classList.add("slideLeftNew"),ye.oldCurMonth.classList.add("slideLeft"),ye.navigationCurrentMonth.classList.add("slideLeftNew")):i<0&&(r.firstChild.classList.add("slideRightNew"),r.lastChild.classList.add("slideRight"),ye.oldCurMonth.classList.add("slideRight"),ye.navigationCurrentMonth.classList.add("slideRightNew"))),ye.currentMonthElement=ye.navigationCurrentMonth.firstChild,ye.currentYearElement=ye.navigationCurrentMonth.lastChild.childNodes[0],De(),ye.oldCurMonth.firstChild&&(ye.oldCurMonth.firstChild.textContent=u(ye.currentMonth-i,ye.config.shorthandCurrentMonth,ye.l10n)),ge("onMonthChange"),a&&document.activeElement&&document.activeElement.$i){var l=document.activeElement.$i;B(function(){W(l,0)})}}}function G(e){return!(!ye.config.appendTo||!ye.config.appendTo.contains(e))||ye.calendarContainer.contains(e)}function V(e){if(ye.isOpen&&!ye.config.inline){var t=G(e.target),n=e.target===ye.input||e.target===ye.altInput||ye.element.contains(e.target)||e.path&&e.path.indexOf&&(~e.path.indexOf(ye.input)||~e.path.indexOf(ye.altInput));("blur"===e.type?n&&e.relatedTarget&&!G(e.relatedTarget):!n&&!t)&&-1===ye.config.ignoredFocusElements.indexOf(e.target)&&(ye.close(),"range"===ye.config.mode&&1===ye.selectedDates.length&&(ye.clear(!1),ye.redraw()))}}function Z(e){if(!(!e||ye.currentYearElement.min&&eparseInt(ye.currentYearElement.max))){var t=e,n=ye.currentYear!==t;ye.currentYear=t||ye.currentYear,ye.config.maxDate&&ye.currentYear===ye.config.maxDate.getFullYear()?ye.currentMonth=Math.min(ye.config.maxDate.getMonth(),ye.currentMonth):ye.config.minDate&&ye.currentYear===ye.config.minDate.getFullYear()&&(ye.currentMonth=Math.max(ye.config.minDate.getMonth(),ye.currentMonth)),n&&(ye.redraw(),ge("onYearChange"))}}function Q(t,n){void 0===n&&(n=!0);var a=ye.parseDate(t,void 0,n);if(ye.config.minDate&&a&&e(a,ye.config.minDate,void 0!==n?n:!ye.minDateHasTime)<0||ye.config.maxDate&&a&&e(a,ye.config.maxDate,void 0!==n?n:!ye.maxDateHasTime)>0)return!1;if(!ye.config.enable.length&&!ye.config.disable.length)return!0;if(void 0===a)return!1;for(var i=ye.config.enable.length>0,o=i?ye.config.enable:ye.config.disable,r=0,l=void 0;r=l.from.getTime()&&a.getTime()<=l.to.getTime())return i}return!i}function X(e){var t=e.target===ye._input,n=G(e.target),a=ye.config.allowInput,i=ye.isOpen&&(!a||!t),o=ye.config.inline&&t&&!a;if("Enter"===e.key&&t){if(a)return ye.setDate(ye._input.value,!0,e.target===ye.altInput?ye.config.altFormat:ye.config.dateFormat),e.target.blur();ye.open()}else if(n||i||o){var r=!!ye.timeContainer&&ye.timeContainer.contains(e.target);switch(e.key){case"Enter":r?Ce():le(e);break;case"Escape":e.preventDefault(),ye.close();break;case"Backspace":case"Delete":t&&!ye.config.allowInput&&ye.clear();break;case"ArrowLeft":case"ArrowRight":if(r)ye.hourElement&&ye.hourElement.focus();else if(e.preventDefault(),ye.daysContainer){var l="ArrowRight"===e.key?1:-1;e.ctrlKey?z(l,!0,void 0,!0):W(e.target.$i,l)}break;case"ArrowUp":case"ArrowDown":e.preventDefault();var c="ArrowDown"===e.key?1:-1;ye.daysContainer&&void 0!==e.target.$i?e.ctrlKey?(Z(ye.currentYear-c),W(e.target.$i,0)):r||W(e.target.$i,7*c):ye.config.enableTime&&(!r&&ye.hourElement&&ye.hourElement.focus(),D(e),ye._debouncedChange());break;case"Tab":e.target===ye.hourElement?(e.preventDefault(),ye.minuteElement.select()):e.target===ye.minuteElement&&(ye.secondElement||ye.amPM)?(e.preventDefault(),void 0!==ye.secondElement?ye.secondElement.focus():void 0!==ye.amPM&&ye.amPM.focus()):e.target===ye.secondElement&&ye.amPM&&(e.preventDefault(),ye.amPM.focus());break;case"a":void 0!==ye.amPM&&e.target===ye.amPM&&(ye.amPM.textContent="AM",E(),Ce());break;case"p":void 0!==ye.amPM&&e.target===ye.amPM&&(ye.amPM.textContent="PM",E(),Ce())}ge("onKeyDown",e)}}function ee(e){if(1===ye.selectedDates.length&&e.classList.contains("flatpickr-day")&&void 0!==ye.minRangeDate&&void 0!==ye.maxRangeDate){for(var t=e.dateObj,n=ye.parseDate(ye.selectedDates[0],void 0,!0),a=Math.min(t.getTime(),ye.selectedDates[0].getTime()),i=Math.max(t.getTime(),ye.selectedDates[0].getTime()),o=!1,r=a;rye.maxRangeDate.getTime(),d=ye.days.childNodes[l];if(c)return d.classList.add("notAllowed"),["inRange","startRange","endRange"].forEach(function(e){d.classList.remove(e)}),"continue";if(o&&!c)return"continue";["startRange","inRange","endRange","notAllowed"].forEach(function(e){d.classList.remove(e)});var s=Math.max(ye.minRangeDate.getTime(),a),u=Math.min(ye.maxRangeDate.getTime(),i);e.classList.add(tt&&r===n.getTime()&&d.classList.add("endRange"),r>=s&&r<=u&&d.classList.add("inRange")}(l,c)}}function te(){!ye.isOpen||ye.config.static||ye.config.inline||oe()}function ne(e){return function(t){var n=ye.config["_"+e+"Date"]=ye.parseDate(t),a=ye.config["_"+("min"===e?"max":"min")+"Date"];void 0!==n&&(ye["min"===e?"minDateHasTime":"maxDateHasTime"]=n.getHours()>0||n.getMinutes()>0||n.getSeconds()>0),ye.selectedDates&&(ye.selectedDates=ye.selectedDates.filter(function(e){return Q(e)}),ye.selectedDates.length||"min"!==e||k(n),Ce()),ye.daysContainer&&(re(),void 0!==n?ye.currentYearElement[e]=n.getFullYear().toString():ye.currentYearElement.removeAttribute(e),ye.currentYearElement.disabled=!!a&&void 0!==n&&a.getFullYear()===n.getFullYear())}}function ae(){var e=["wrap","weekNumbers","allowInput","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],t=["onChange","onClose","onDayCreate","onDestroy","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange"];ye.config=s({},b.defaultConfig);var n=s({},d,JSON.parse(JSON.stringify(c.dataset||{}))),a={};Object.defineProperty(ye.config,"enable",{get:function(){return ye.config._enable||[]},set:function(e){ye.config._enable=de(e)}}),Object.defineProperty(ye.config,"disable",{get:function(){return ye.config._disable||[]},set:function(e){ye.config._disable=de(e)}}),!n.dateFormat&&n.enableTime&&(a.dateFormat=n.noCalendar?"H:i"+(n.enableSeconds?":S":""):b.defaultConfig.dateFormat+" H:i"+(n.enableSeconds?":S":"")),n.altInput&&n.enableTime&&!n.altFormat&&(a.altFormat=n.noCalendar?"h:i"+(n.enableSeconds?":S K":" K"):b.defaultConfig.altFormat+" h:i"+(n.enableSeconds?":S":"")+" K"),Object.defineProperty(ye.config,"minDate",{get:function(){return ye.config._minDate},set:ne("min")}),Object.defineProperty(ye.config,"maxDate",{get:function(){return ye.config._maxDate},set:ne("max")}),Object.assign(ye.config,a,n);for(i=0;it,c=window.pageYOffset+o.top+(l?-t-2:e.offsetHeight+2);if(a(ye.calendarContainer,"arrowTop",!l),a(ye.calendarContainer,"arrowBottom",l),!ye.config.inline){var d=window.pageXOffset+o.left,s=window.document.body.offsetWidth-o.right,u=d+n>window.document.body.offsetWidth;a(ye.calendarContainer,"rightMost",u),ye.config.static||(ye.calendarContainer.style.top=c+"px",u?(ye.calendarContainer.style.left="auto",ye.calendarContainer.style.right=s+"px"):(ye.calendarContainer.style.left=d+"px",ye.calendarContainer.style.right="auto"))}}}function re(){ye.config.noCalendar||ye.isMobile||($(),De(),J())}function le(t){t.preventDefault(),t.stopPropagation();var n=r(t.target,function(e){return e.classList&&e.classList.contains("flatpickr-day")&&!e.classList.contains("disabled")&&!e.classList.contains("notAllowed")});if(void 0!==n){var a=n,i=ye.latestSelectedDateObj=new Date(a.dateObj.getTime()),o=i.getMonth()!==ye.currentMonth&&"range"!==ye.config.mode;if(ye.selectedDateElem=a,"single"===ye.config.mode)ye.selectedDates=[i];else if("multiple"===ye.config.mode){var l=he(i);l?ye.selectedDates.splice(parseInt(l),1):ye.selectedDates.push(i)}else"range"===ye.config.mode&&(2===ye.selectedDates.length&&ye.clear(),ye.selectedDates.push(i),0!==e(i,ye.selectedDates[0],!0)&&ye.selectedDates.sort(function(e,t){return e.getTime()-t.getTime()}));if(E(),o){var c=ye.currentYear!==i.getFullYear();ye.currentYear=i.getFullYear(),ye.currentMonth=i.getMonth(),c&&ge("onYearChange"),ge("onMonthChange")}if(J(),ye.config.minDate&&ye.minDateHasTime&&ye.config.enableTime&&0===e(i,ye.config.minDate)&&k(ye.config.minDate),Ce(),ye.config.enableTime&&setTimeout(function(){return ye.showTimeInput=!0},50),"range"===ye.config.mode&&(1===ye.selectedDates.length?(ee(a),ye._hidePrevMonthArrow=ye._hidePrevMonthArrow||void 0!==ye.minRangeDate&&ye.minRangeDate>ye.days.childNodes[0].dateObj,ye._hideNextMonthArrow=ye._hideNextMonthArrow||void 0!==ye.maxRangeDate&&ye.maxRangeDateye.now.getTime()?ye.config.minDate:ye.config.maxDate&&ye.config.maxDate.getTime()0||ye.config.minDate.getMinutes()>0||ye.config.minDate.getSeconds()>0),ye.maxDateHasTime=!!ye.config.maxDate&&(ye.config.maxDate.getHours()>0||ye.config.maxDate.getMinutes()>0||ye.config.maxDate.getSeconds()>0),Object.defineProperty(ye,"showTimeInput",{get:function(){return ye._showTimeInput},set:function(e){ye._showTimeInput=e,ye.calendarContainer&&a(ye.calendarContainer,"showTimeInput",e),oe()}})}function ue(e,t,n){if(0===e||e){var a,i=e;if(e instanceof Date)a=new Date(e.getTime());else if("string"!=typeof e&&void 0!==e.toFixed)a=new Date(e);else if("string"==typeof e){var o=t||(ye.config||b.defaultConfig).dateFormat,r=String(e).trim();if("today"===r)a=new Date,n=!0;else if(/Z$/.test(r)||/GMT$/.test(r))a=new Date(e);else if(ye.config&&ye.config.parseDate)a=ye.config.parseDate(e,o);else{a=ye.config&&ye.config.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0);for(var l=void 0,c=[],d=0,s=0,u="";d0)for(var a=0;n[a]&&a=0&&e(t,ye.selectedDates[1])<=0)}function De(){ye.config.noCalendar||ye.isMobile||!ye.monthNav||(ye.currentMonthElement.textContent=u(ye.currentMonth,ye.config.shorthandCurrentMonth,ye.l10n)+" ",ye.currentYearElement.value=ye.currentYear.toString(),ye._hidePrevMonthArrow=void 0!==ye.config.minDate&&(ye.currentYear===ye.config.minDate.getFullYear()?ye.currentMonth<=ye.config.minDate.getMonth():ye.currentYearye.config.maxDate.getMonth():ye.currentYear>ye.config.maxDate.getFullYear()))}function Ce(e){if(void 0===e&&(e=!0),!ye.selectedDates.length)return ye.clear(e);void 0!==ye.mobileInput&&ye.mobileFormatStr&&(ye.mobileInput.value=void 0!==ye.latestSelectedDateObj?ye.formatDate(ye.latestSelectedDateObj,ye.mobileFormatStr):"");var t="range"!==ye.config.mode?ye.config.conjunction:ye.l10n.rangeSeparator;ye.input.value=ye.selectedDates.map(function(e){return ye.formatDate(e,ye.config.dateFormat)}).join(t),void 0!==ye.altInput&&(ye.altInput.value=ye.selectedDates.map(function(e){return ye.formatDate(e,ye.config.altFormat)}).join(t)),!1!==e&&ge("onValueUpdate")}function we(e){e.preventDefault();var t=ye.currentYearElement.parentNode&&ye.currentYearElement.parentNode.contains(e.target);if(e.target===ye.currentMonthElement||t){var a=n(e);t?(Z(ye.currentYear+a),e.target.value=ye.currentYear.toString()):ye.changeMonth(a,!0,!1)}}function Me(e){var t=ye.prevMonthNav.contains(e.target),n=ye.nextMonthNav.contains(e.target);t||n?z(t?-1:1):e.target===ye.currentYearElement?(e.preventDefault(),ye.currentYearElement.select()):"arrowUp"===e.target.className?ye.changeYear(ye.currentYear+1):"arrowDown"===e.target.className&&ye.changeYear(ye.currentYear-1)}function be(e){e.preventDefault();var t="keydown"===e.type,n=e.target;void 0!==ye.amPM&&e.target===ye.amPM&&(ye.amPM.textContent=ye.l10n.amPM["AM"===ye.amPM.textContent?1:0]);var a=Number(n.min),i=Number(n.max),o=Number(n.step),r=parseInt(n.value,10),l=r+o*(e.delta||(t?38===e.which?1:-1:Math.max(-1,Math.min(1,e.wheelDelta||-e.deltaY))||0));if(void 0!==n.value&&2===n.value.length){var c=n===ye.hourElement,d=n===ye.minuteElement;li&&(l=n===ye.hourElement?l-i-h(!ye.amPM):a,d&&j(void 0,1,ye.hourElement)),ye.amPM&&c&&(1===o?l+r===23:Math.abs(l-r)>o)&&(ye.amPM.textContent="PM"===ye.amPM.textContent?"AM":"PM"),n.value=p(l)}}var ye={};return ye.parseDate=ue,ye.formatDate=function(e,t){return void 0!==ye.config&&void 0!==ye.config.formatDate?ye.config.formatDate(e,t):t.split("").map(function(t,n,a){return M[t]&&"\\"!==a[n-1]?M[t](e,ye.l10n,ye.config):"\\"!==t?t:""}).join("")},ye._animationLoop=[],ye._handlers=[],ye._bind=T,ye._setHoursFromDate=k,ye.changeMonth=z,ye.changeYear=Z,ye.clear=function(e){void 0===e&&(e=!0),ye.input.value="",ye.altInput&&(ye.altInput.value=""),ye.mobileInput&&(ye.mobileInput.value=""),ye.selectedDates=[],ye.latestSelectedDateObj=void 0,ye.showTimeInput=!1,ye.redraw(),e&&ge("onChange")},ye.close=function(){ye.isOpen=!1,ye.isMobile||(ye.calendarContainer.classList.remove("open"),ye._input.classList.remove("active")),ge("onClose")},ye._createElement=i,ye.destroy=function(){void 0!==ye.config&&ge("onDestroy");for(var e=ye._handlers.length;e--;){var t=ye._handlers[e];t.element.removeEventListener(t.event,t.handler)}ye._handlers=[],ye.mobileInput?(ye.mobileInput.parentNode&&ye.mobileInput.parentNode.removeChild(ye.mobileInput),ye.mobileInput=void 0):ye.calendarContainer&&ye.calendarContainer.parentNode&&ye.calendarContainer.parentNode.removeChild(ye.calendarContainer),ye.altInput&&(ye.input.type="text",ye.altInput.parentNode&&ye.altInput.parentNode.removeChild(ye.altInput),delete ye.altInput),ye.input&&(ye.input.type=ye.input._type,ye.input.classList.remove("flatpickr-input"),ye.input.removeAttribute("readonly"),ye.input.value=""),["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach(function(e){try{delete ye[e]}catch(e){}})},ye.isEnabled=Q,ye.jumpToDate=L,ye.open=function(e,t){if(void 0===t&&(t=ye._input),ye.isMobile)return e&&(e.preventDefault(),e.target&&e.target.blur()),setTimeout(function(){void 0!==ye.mobileInput&&ye.mobileInput.click()},0),void ge("onOpen");ye._input.disabled||ye.config.inline||(ye.isOpen=!0,ye.calendarContainer.classList.add("open"),oe(t),ye._input.classList.add("active"),ge("onOpen"))},ye.redraw=re,ye.set=function(e,t){null!==e&&"object"==typeof e?Object.assign(ye.config,e):ye.config[e]=t,ye.redraw(),L()},ye.setDate=function(e,t,n){if(void 0===t&&(t=!1),void 0===n&&(n=void 0),0!==e&&!e)return ye.clear(t);ce(e,n),ye.showTimeInput=ye.selectedDates.length>0,ye.latestSelectedDateObj=ye.selectedDates[0],ye.redraw(),L(),k(),Ce(t),t&&ge("onChange")},ye.toggle=function(){if(ye.isOpen)return ye.close();ye.open()},ye.element=ye.input=c,ye.isOpen=!1,ae(),ie(),fe(),se(),m(),ye.isMobile||H(),_(),(ye.selectedDates.length||ye.config.noCalendar)&&(ye.config.enableTime&&k(ye.config.noCalendar?ye.latestSelectedDateObj||ye.config.minDate:void 0),Ce(!1)),ye.showTimeInput=ye.selectedDates.length>0||ye.config.noCalendar,void 0!==ye.weekWrapper&&void 0!==ye.daysContainer&&(ye.calendarContainer.style.width=ye.daysContainer.offsetWidth+ye.weekWrapper.offsetWidth+"px"),ye.isMobile||oe(),ge("onReady"),ye}function d(e,t){for(var n=Array.prototype.slice.call(e),a=[],i=0;i",noCalendar:!1,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"",shorthandCurrentMonth:!1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},g={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(e){var t=e%100;if(t>3&&t<21)return"th";switch(t%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"]},p=function(e){return("0"+e).slice(-2)},h=function(e){return!0===e?1:0},v=function(e){return e instanceof Array?e:[e]},D=function(){},C={D:D,F:function(e,t,n){e.setMonth(n.months.longhand.indexOf(t))},G:function(e,t){e.setHours(parseFloat(t))},H:function(e,t){e.setHours(parseFloat(t))},J:function(e,t){e.setDate(parseFloat(t))},K:function(e,t){e.setHours(e.getHours()%12+12*h(/pm/i.test(t)))},M:function(e,t,n){e.setMonth(n.months.shorthand.indexOf(t))},S:function(e,t){e.setSeconds(parseFloat(t))},U:function(e,t){return new Date(1e3*parseFloat(t))},W:function(e,t){var n=parseInt(t);return new Date(e.getFullYear(),0,2+7*(n-1),0,0,0,0)},Y:function(e,t){e.setFullYear(parseFloat(t))},Z:function(e,t){return new Date(t)},d:function(e,t){e.setDate(parseFloat(t))},h:function(e,t){e.setHours(parseFloat(t))},i:function(e,t){e.setMinutes(parseFloat(t))},j:function(e,t){e.setDate(parseFloat(t))},l:D,m:function(e,t){e.setMonth(parseFloat(t)-1)},n:function(e,t){e.setMonth(parseFloat(t)-1)},s:function(e,t){e.setSeconds(parseFloat(t))},w:D,y:function(e,t){e.setFullYear(2e3+parseFloat(t))}},w={D:"(\\w+)",F:"(\\w+)",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"(am|AM|Am|aM|pm|PM|Pm|pM)",M:"(\\w+)",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:"(\\w+)",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},M={Z:function(e){return e.toISOString()},D:function(e,t,n){return t.weekdays.shorthand[M.w(e,t,n)]},F:function(e,t,n){return u(M.n(e,t,n)-1,!1,t)},G:function(e,t,n){return p(M.h(e,t,n))},H:function(e){return p(e.getHours())},J:function(e,t){return void 0!==t.ordinal?e.getDate()+t.ordinal(e.getDate()):e.getDate()},K:function(e){return e.getHours()>11?"PM":"AM"},M:function(e,t){return u(e.getMonth(),!0,t)},S:function(e){return p(e.getSeconds())},U:function(e){return e.getTime()/1e3},W:function(e,t,n){return n.getWeek(e)},Y:function(e){return e.getFullYear()},d:function(e){return p(e.getDate())},h:function(e){return e.getHours()%12?e.getHours()%12:12},i:function(e){return p(e.getMinutes())},j:function(e){return e.getDate()},l:function(e,t){return t.weekdays.longhand[e.getDay()]},m:function(e){return p(e.getMonth()+1)},n:function(e){return e.getMonth()+1},s:function(e){return e.getSeconds()},w:function(e){return e.getDay()},y:function(e){return String(e.getFullYear()).substring(2)}};"function"!=typeof Object.assign&&(Object.assign=function(e){for(var t=[],n=1;n