UNPKG

@progress/kendo-react-dateinputs

Version:
1 lines 172 kB
System.register("@progress/kendo-react-dateinputs",["react","@progress/kendo-react-common","prop-types","@progress/kendo-date-math","@progress/kendo-react-intl","@progress/kendo-react-popup","@progress/kendo-react-buttons"],function(m){var n,i,r,a,o,s,l;function t(e){return e.__useDefault?e.default:e}return{setters:[function(e){n=t(e)},function(e){i=t(e)},function(e){r=t(e)},function(e){a=t(e)},function(e){o=t(e)},function(e){s=t(e)},function(e){l=t(e)}],execute:function(){!function(n){var i={};function r(e){if(i[e])return i[e].exports;var t=i[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,r),t.l=!0,t.exports}r.m=n,r.c=i,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)r.d(n,i,function(e){return t[e]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=33)}([function(e,t){e.exports=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var l=n(0),i=n(0),u=n(11);t.isEqualRange=function(e,t){var n=e||u.EMPTY_SELECTIONRANGE,i=n.start,r=n.end,a=t||u.EMPTY_SELECTIONRANGE,o=a.start,s=a.end;return null!==i&&null!==r&&null!==o&&null!==s&&l.isEqual(i,o)&&l.isEqual(r,s)},t.viewInRange=function(e,t,n){return void 0===t||void 0===n?e:t<=e&&e<=n?e:e<t?t:n},t.MIDNIGHT_DATE=new Date(1980,0,1),t.MIN_DATE=new Date(1900,0,1),t.MAX_DATE=new Date(2099,11,31),t.MIN_TIME=new Date(1980,0,1),t.MAX_TIME=new Date(1980,0,1,23,59,59);var r=function(e){return null!=e};t.isValidRange=function(e,t){return!r(e)||!r(t)||e<=t},t.setTime=function(e,t){var n=l.cloneDate(e);return n.setHours(t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),n},t.getToday=function(){return i.getDate(new Date)},t.isInRange=function(e,t,n){return!e||!(t&&e<t||n&&n<e)},t.isInRangePicker=function(e,t,n){return null===e||!(t&&i.getDate(t)>i.getDate(e)||n&&i.getDate(n)<i.getDate(e))},t.isInSelectionRange=function(e,t){var n=t||u.EMPTY_SELECTIONRANGE,i=n.start,r=n.end;return!(!i||!r)&&i<e&&e<r},t.range=function(e,t,n){void 0===n&&(n=1);for(var i=[],r=e;r<t;r+=n)i.push(r);return i},t.shiftWeekNames=function(e,t){return e.slice(t).concat(e.slice(0,t))},t.dateInRange=function(e,t,n){return e?t&&e<t?l.cloneDate(t):n&&n<e?l.cloneDate(n):e:e},t.domContainerFactory=function(r){return function(e,t,n){void 0===t&&(t=""),void 0===n&&(n={});var i=document.createElement(r);return i.className=t,Object.keys(n).map(function(e){return i.style[e]=n[e]}),"string"==typeof e?i.innerHTML=e||"":(e||[]).forEach(function(e){return e&&i.appendChild(e)}),i}},t.isDocumentAvailable=function(){return"undefined"!=typeof document}},function(e,t){e.exports=n},function(e,t){e.exports=i},function(e,t){e.exports=r},function(e,t){e.exports=o},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0}),t.prevView="multiviewcalendar.prevView",t.nextView="multiviewcalendar.nextView",t.increaseValue="dateinput.increment",t.decreaseValue="dateinput.decrement",t.today="calendar.today",t.toggleCalendar="datepicker.toggleCalendar",t.swapStartEnd="daterangepicker.swapStartEnd",t.start="daterangepicker.start",t.end="daterangepicker.end",t.toggleDateTimeSelector="datetimepicker.toggleDateTimeSelector",t.now="timepicker.now",t.selectNow="timepicker.selectNow",t.timePickerCancel="timepicker.cancel",t.timePickerSet="timepicker.set",t.toggleTimeSelector="timepicker.toggleTimeSelector",t.toggleClock="timepicker.toggleClock",t.date="datetimepicker.date",t.time="datetimepicker.time",t.dateTimePickerCancel="datetimepicker.cancel",t.dateTimePickerSet="datetimepicker.set",t.messages=((i={})[t.today]="TODAY",i[t.now]="NOW",i[t.timePickerSet]="Set",i[t.timePickerCancel]="Cancel",i[t.date]="Date",i[t.time]="Time",i[t.dateTimePickerCancel]="Cancel",i[t.dateTimePickerSet]="Set",i[t.start]="Start",i[t.end]="End",i[t.selectNow]="Select Now",i[t.toggleTimeSelector]="Toggle TimeSelector",i[t.toggleClock]="Toggle Clock",i[t.increaseValue]="Increase value",i[t.decreaseValue]="Decrease value",i[t.toggleCalendar]="Toggle calendar",i[t.prevView]="Navigate to previous view",i[t.nextView]="Navigate to next view",i[t.swapStartEnd]="Swap start and end values",i[t.toggleDateTimeSelector]="Toggle date-time selector",i)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(10);t.Action=i.Action;var r=n(16);t.CalendarViewEnum=r.CalendarViewEnum;var a=n(11);t.EMPTY_SELECTIONRANGE=a.EMPTY_SELECTIONRANGE},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i,r,a=n(0),o=n(18),s=n(1),l=function(i){return function(e,t){var n=a.cloneDate(e);return n[i](t),n}},u=[{type:o.TIME_PART.hour,getter:function(e){return e.getHours()}},{type:o.TIME_PART.minute,getter:function(e){return e.getMinutes()}},{type:o.TIME_PART.second,getter:function(e){return e.getSeconds()}},{type:o.TIME_PART.millisecond,getter:function(e){return e.getMilliseconds()}}];t.generateGetters=(i=u,function(e){return i.map((t=e.reduce(function(e,t){return e[t.type]=t.type,e},{}),function(e){return t[e.type]?(i=e.getter,function(e,t){return i(t)}):(n=e.getter,function(e,t){return n(e)});var n,i}));var t}),t.generateSnappers=(r=u,function(n,s){return r.map(function(e){var i,r,a,o,t=Math.floor(n[e.type]);return t?(i=e.getter,r=t,a=s,o=e.type,function(e){var t=i(e),n=i(a);return"hour"===o?t-(t-n)%r:e.getTime()<=a.getTime()&&0!==t&&t<=n?Math.ceil(t/r)*r:t-t%r}):e.getter})}),t.valueMerger=function(e){return function(t,n){return t.setHours.apply(t,e.map(function(e){return e(t,n)})),t}},t.snapTime=function(n){return function(e){var t=a.cloneDate(e);return t.setHours.apply(t,n.map(function(e){return e(t)})),t}},t.setHours=l("setHours"),t.setMinutes=l("setMinutes"),t.setSeconds=l("setSeconds"),t.getNow=function(){return new Date},t.range=function(e,t,n){void 0===n&&(n=1);for(var i=[],r=e;r<t;r+=n)i.push(r);return i};var c=function(e,t,n){return{candidateValue:s.setTime(s.MIDNIGHT_DATE,e),maxValue:a.addDays(s.setTime(s.MIDNIGHT_DATE,n),t.getHours()<n.getHours()?0:1),minValue:s.setTime(s.MIDNIGHT_DATE,t)}};t.timeInRange=function(e,t,n){if(!e||!t||!n)return e;var i=c(e,t,n),r=i.candidateValue,a=i.minValue,o=i.maxValue;return r<a?s.setTime(e,t):o<r?s.setTime(e,n):e},t.isInTimeRange=function(e,t,n){if(!e||!t||!n)return!0;var i=c(e,t,n),r=i.candidateValue,a=i.minValue,o=i.maxValue;return a<=r&&r<=o},t.isInRange=function(e,t,n){if(null===e)return!0;var i=c(e,t,n),r=i.candidateValue,a=i.minValue,o=i.maxValue;return a<=r&&r<=o},t.isSmallerThanMin=function(e,t){if(null===e||null===t)return!1;var n=s.setTime(s.MIDNIGHT_DATE,e),i=s.setTime(s.MIDNIGHT_DATE,t);return n.getTime()<i.getHours()},t.isBiggerThanMax=function(e,t){if(null===e||null===t)return!1;var n=s.setTime(s.MIDNIGHT_DATE,e);return s.setTime(s.MIDNIGHT_DATE,t).getTime()<n.getHours()}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MIDNIGHT_DATE=new Date(1980,0,1),t.MIN_DATE=new Date(1900,0,1),t.MAX_DATE=new Date(2099,11,31),t.MIN_TIME=new Date(1980,0,1),t.MAX_TIME=new Date(1980,0,1,23,59,59)},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0}),(i=t.Action||(t.Action={}))[i.Left=0]="Left",i[i.Right=1]="Right",i[i.Up=2]="Up",i[i.Down=3]="Down",i[i.PrevView=4]="PrevView",i[i.NextView=5]="NextView",i[i.FirstInView=6]="FirstInView",i[i.LastInView=7]="LastInView",i[i.LowerView=8]="LowerView",i[i.UpperView=9]="UpperView"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EMPTY_SELECTIONRANGE={start:null,end:null}},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),D=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e};Object.defineProperty(t,"__esModule",{value:!0});var _=n(2),a=n(4),o=n(0),S=n(5),k=n(44),O=n(3),I=n(30),s=n(1),E=n(6),l=function(e){function w(){var u=null!==e&&e.apply(this,arguments)||this;return u.kendoDate=null,u._element=null,u._inputId=O.guid(),u.setValidity=function(){u.element&&u.element.setCustomValidity&&u.element.setCustomValidity(u.validity.valid?"":u.props.validationMessage||w.defaultProps.validationMessage)},u.spinnersMouseDown=function(e){e.preventDefault(),u.element&&document.activeElement!==u.element&&u.element.focus()},u.elementChange=function(e){if(u.element&&u.kendoDate){var t=u.kendoDate.getTextAndFormat(),n=t.text,i=t.format;u.currentFormat=i;var r=u.value,a=I.approximateStringMatching(n,u.currentFormat,u.element.value,u.selection.start),o=1===a.length&&"_"===a[0][1],s=!1;if(!o)for(var l=0;l<a.length;l++)s=u.kendoDate.parsePart(a[l][0],a[l][1]).switchToNext;a.length&&"_"!==a[0][0]&&u.setSelection(u.selectionBySymbol(a[0][0])),(s||o)&&u.switchDateSegment(1),u.triggerChange(e,r)}},u.elementClick=function(e){u.setSelection(u.selectionByIndex(u.selection.start))},u.wheel=function(e){document.activeElement===u.element&&(e.nativeEvent.deltaY<0&&(e.preventDefault(),u.increasePart(e)),0<e.nativeEvent.deltaY&&(e.preventDefault(),u.decreasePart(e)))},u.increasePart=function(e){u.modifyDateSegmentValue(1,e)},u.decreasePart=function(e){u.modifyDateSegmentValue(-1,e)},u.elementKeyDown=function(e){if(!e.altKey){switch(e.keyCode){case 37:u.switchDateSegment(-1);break;case 38:u.modifyDateSegmentValue(1,e);break;case 39:u.switchDateSegment(1);break;case 40:u.modifyDateSegmentValue(-1,e);break;default:return}e.preventDefault()}},u}return r(w,e),w.prototype.componentDidMount=function(){this.setValidity()},w.prototype.componentDidUpdate=function(){this._lastSelectedSymbol&&this.setSelection(this.selectionBySymbol(this._lastSelectedSymbol)),this.setValidity()},w.prototype.render=function(){var t=this,e=S.provideLocalizationService(this),n=D({},w.defaultProps,this.props),i=n.formatPlaceholder,r=n.format,a=n.value,o=n.min,s=n.max,l=n.name,u=n.label,c=n.id,p=n.defaultValue;null===this.kendoDate?(this.kendoDate=new k.KendoDate(this.intl.bind(this),i,r),this.kendoDate.setValue(a||p)):(this.kendoDate.format=r,this.kendoDate.formatPlaceholder=i),void 0!==a&&this.value!==a&&this.kendoDate.setValue(a);var d=this.kendoDate.getTextAndFormat(),h=d.text,f=d.format;this.currentFormat=f;var m=c||this._inputId,v=!this.validityStyles||this.validity.valid,g={"aria-valuemin":null===o?void 0:o.getTime(),"aria-valuemax":null===s?void 0:s.getTime(),"aria-valuetext":h};null!==this.value&&(g["aria-valuenow"]=this.value.getTime());var y=I.wrapperClasses.slice();this.props.className&&y.push(this.props.className);var b=_.createElement("span",{style:u?void 0:{width:this.props.width},dir:this.props.dir,className:v?y.join(" "):Array.prototype.concat([],y,I.invalidClasses).join(" ")},_.createElement("span",{className:"k-dateinput-wrap"+(this.props.disabled?" k-state-disabled":"")},_.createElement("input",D({tabIndex:this.props.tabIndex,disabled:this.props.disabled,title:this.props.title||h,type:"text",spellCheck:!1,autoComplete:"off",autoCorrect:"off",className:"k-input",id:m,onWheel:this.wheel,onClick:this.elementClick,onChange:this.elementChange,onKeyDown:this.elementKeyDown,value:h,name:l},g,{ref:function(e){return t._element=e}})),this.props.children,this.props.spinners&&_.createElement("span",{className:"k-select",onMouseDown:this.spinnersMouseDown},_.createElement("span",{className:"k-link k-link-increase","aria-label":e.toLanguageString(E.increaseValue,E.messages[E.increaseValue]),title:e.toLanguageString(E.increaseValue,E.messages[E.increaseValue]),onClick:this.increasePart},_.createElement("span",{className:"k-icon k-i-arrow-n"})),_.createElement("span",{className:"k-link k-link-decrease","aria-label":e.toLanguageString(E.decreaseValue,E.messages[E.decreaseValue]),title:e.toLanguageString(E.decreaseValue,E.messages[E.decreaseValue]),onClick:this.decreasePart},_.createElement("span",{className:"k-icon k-i-arrow-s"})))));return u?_.createElement(O.FloatingLabel,{id:m,value:h,valid:v,label:u,children:b,style:{width:this.props.width}}):b},Object.defineProperty(w.prototype,"value",{get:function(){return void 0!==this.valueDuringOnChange?this.valueDuringOnChange:this.kendoDate&&this.kendoDate.getDateObject()},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"name",{get:function(){return this.props.name},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"min",{get:function(){return void 0!==this.props.min?this.props.min:w.defaultProps.min},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"max",{get:function(){return void 0!==this.props.max?this.props.max:w.defaultProps.max},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"validity",{get:function(){var e=I.isInRange(this.value,this.min,this.max),t=void 0!==this.props.validationMessage,n=(!this.required||null!==this.value)&&e,i=void 0!==this.props.valid?this.props.valid:n;return{customError:t,rangeOverflow:this.value&&this.max.getTime()<this.value.getTime()||!1,rangeUnderflow:this.value&&this.value.getTime()<this.min.getTime()||!1,valid:i,valueMissing:null===this.value}},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"validityStyles",{get:function(){return void 0!==this.props.validityStyles?this.props.validityStyles:w.defaultProps.validityStyles},enumerable:!0,configurable:!0}),Object.defineProperty(w.prototype,"required",{get:function(){return void 0!==this.props.required?this.props.required:w.defaultProps.required},enumerable:!0,configurable:!0}),w.prototype.intl=function(){return S.provideIntlService(this)},Object.defineProperty(w.prototype,"selection",{get:function(){var e={start:0,end:0};return null!==this.element&&void 0!==this.element.selectionStart&&(e={start:this.element.selectionStart,end:this.element.selectionEnd}),e},enumerable:!0,configurable:!0}),w.prototype.setSelection=function(e){var t=this;this._lastSelectedSymbol=this.currentFormat[e.start],window.requestAnimationFrame(function(){t.element&&document.activeElement===t.element&&t.element.setSelectionRange(e.start,e.end)})},w.prototype.triggerChange=function(e,t){this.valueDuringOnChange=this.value,this.forceUpdate(),this.props.onChange&&!o.isEqual(t,this.value)&&this.props.onChange.call(void 0,{syntheticEvent:e,nativeEvent:e.nativeEvent,value:this.value,target:this}),this.valueDuringOnChange=void 0},w.prototype.selectionBySymbol=function(e){for(var t=-1,n=0,i=0;i<this.currentFormat.length;i++)this.currentFormat[i]===e&&(n=i+1,-1===t&&(t=i));return t<0&&(t=0),{start:t,end:n}},w.prototype.selectionByIndex=function(e){for(var t={start:e,end:e},n=e,i=e-1;n<this.currentFormat.length||0<=i;n++,i--){if(n<this.currentFormat.length&&"_"!==this.currentFormat[n]){t=this.selectionBySymbol(this.currentFormat[n]);break}if(0<=i&&"_"!==this.currentFormat[i]){t=this.selectionBySymbol(this.currentFormat[i]);break}}return t},w.prototype.switchDateSegment=function(e){var t=this.selection,n=t.start,i=t.end;if(n<i&&this.currentFormat[n]!==this.currentFormat[i-1])this.setSelection(this.selectionByIndex(0<e?n:i-1));else{for(var r=this.currentFormat[n],a=n+e;0<a&&a<this.currentFormat.length&&(this.currentFormat[a]===r||"_"===this.currentFormat[a]);)a+=e;if("_"!==this.currentFormat[a]){for(var o=a;0<=o&&o<this.currentFormat.length&&this.currentFormat[o]===this.currentFormat[a];)o+=e;o<a&&(o+1!==n||a+1!==i)?this.setSelection({start:o+1,end:a+1}):a<o&&(a!==n||o!==i)&&this.setSelection({start:a,end:o})}}},w.prototype.modifyDateSegmentValue=function(e,t){if(this.kendoDate){var n=this.value,i=this.currentFormat[this.selection.start],r=this.kendoDate.symbolMap(i),a=((this.props.steps||{})[r]||1)*e;this.kendoDate.modifyPart(i,a),this.setSelection(this.selectionBySymbol(i)),this.triggerChange(t,n)}},w.propTypes={value:a.instanceOf(Date),format:a.string,formatPlaceholder:a.oneOfType([a.oneOf(["wide","narrow","short","formatPattern"]),a.shape({year:a.string,month:a.string,day:a.string,hour:a.string,minute:a.string,second:a.string})]),width:a.oneOfType([a.string,a.number]),tabIndex:a.number,title:a.string,steps:a.shape({year:a.number,month:a.number,day:a.number,hour:a.number,minute:a.number,second:a.number}),min:a.instanceOf(Date),max:a.instanceOf(Date),disabled:a.bool,spinners:a.bool,name:a.string,dir:a.string,label:a.string,id:a.string,onChange:a.func,validationMessage:a.string,required:a.bool,validate:a.bool,valid:a.bool},w.defaultProps={format:I.defaultFormat,formatPlaceholder:I.defaultFormatPlaceholder,defaultValue:null,spinners:!1,disabled:!1,max:o.cloneDate(s.MAX_DATE),min:o.cloneDate(s.MIN_DATE),required:!1,validityStyles:!0,validationMessage:"Please enter a valid value!"},w}(_.Component);t.DateInput=l,S.registerForIntl(l),S.registerForLocalization(l)},function(e,t){e.exports=s},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),u=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e};Object.defineProperty(t,"__esModule",{value:!0});var c=n(2),a=n(4),p=n(3),d=n(0),h=n(5),f=n(34),m=n(43),o=n(9),v=n(7),g=n(1),s=n(17),y=function(e){return e?e.virtualization:null},b=function(e,t,n,i){return void 0===e&&(e=l.defaultProps.min),void 0===t&&(t=l.defaultProps.max),void 0!==i?null!==i&&g.isInRange(i,e,t)?i:null:null!==n&&g.isInRange(n,e,t)?n:null},l=function(n){function l(e){var o=n.call(this,e)||this;o.cellUID=p.guid(),o.id=p.guid(),o.isActive=!1,o.handleScroll=function(e){o.scrollSyncService&&o.scrollSyncService.sync(y(o.Navigation),y(o.calendarViewList),e)},o.handleNavigationChange=function(e){if(!o.props.disabled){var t=d.cloneDate(e.value);o.setState({focusedDate:t})}},o.handleViewChange=function(e){var t=e.view;o.scrollSyncService.configure(t),o.setState({activeView:t})},o.handleDateChange=function(e){var t=d.cloneDate(e.value),n=d.cloneDate(e.value),i=o.bus.canMoveDown(o.state.activeView);if(!o.props.disabled){if(i){if(!e.isTodayClick)return o.bus.moveDown(o.state.activeView,e.syntheticEvent),void o.setState({focusedDate:n});o.bus.moveToBottom(o.state.activeView)}o.setState({value:t,focusedDate:n}),o.valueDuringOnChange=t;var r=o.props.onChange;if(r){var a={syntheticEvent:e.syntheticEvent,nativeEvent:e.nativeEvent,value:t,target:o};r.call(void 0,a)}o.valueDuringOnChange=void 0}},o.handleFocus=function(e){if(o.isActive=!0,o.calendarViewList){o.calendarViewList.focusActiveDate();var t=o.props.onFocus;t&&t.call(void 0,e)}},o.handleBlur=function(e){if(o.isActive=!1,o.calendarViewList){o.calendarViewList.blurActiveDate();var t=o.props.onBlur;t&&t.call(void 0,e)}},o.handleKeyDown=function(e){if(e.keyCode===p.Keys.enter){if(null!==o.value&&d.isEqualDate(o.focusedDate,o.value)){var t=g.dateInRange(o.focusedDate,o.min,o.max);y(o.calendarViewList).scrollToIndex(o.service.skip(t,o.min))}var n={syntheticEvent:e,nativeEvent:e.nativeEvent,value:o.focusedDate,target:o};o.handleDateChange.call(void 0,n)}else{var i=g.dateInRange(o.navigation.move(o.focusedDate,o.navigation.action(e),o.state.activeView,o.service,e),o.min,o.max);if(d.isEqualDate(o.focusedDate,i))return;o.setState({focusedDate:i})}e.preventDefault()},o.handleMouseDown=function(e){e.preventDefault()},o.handleClick=function(e){o._element&&o._element.focus()};var t=b(o.min,o.max,o.props.defaultValue||l.defaultProps.defaultValue,o.props.value);return o.state={value:t,activeView:g.viewInRange(v.CalendarViewEnum[e.defaultActiveView],o.bottomView,o.topView),focusedDate:g.dateInRange(e.focusedDate||t||g.getToday(),o.min,o.max)},o.dom=new s.DOMService,o.bus=new s.BusViewService(o.handleViewChange),o.navigation=new s.NavigationService(o.bus),o.oldValue=t,o}return r(l,n),Object.defineProperty(l.prototype,"element",{get:function(){return this._element},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"value",{get:function(){return void 0!==this.valueDuringOnChange?this.valueDuringOnChange:void 0!==this.props.value?this.props.value:this.state.value},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"min",{get:function(){return d.getDate(void 0!==this.props.min?this.props.min:l.defaultProps.min)},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"max",{get:function(){return d.getDate(void 0!==this.props.max?this.props.max:l.defaultProps.max)},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"bottomView",{get:function(){return v.CalendarViewEnum[void 0!==this.props.bottomView?this.props.bottomView:l.defaultProps.bottomView]},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"topView",{get:function(){return v.CalendarViewEnum[void 0!==this.props.topView?this.props.topView:l.defaultProps.topView]},enumerable:!0,configurable:!0}),l.prototype.componentDidMount=function(){var e=this;Promise.resolve().then(function(){e._element&&(e.dom.calculateHeights(e._element),e.scrollSyncService=new s.ScrollSyncService(e.dom),e.scrollSyncService.configure(e.state.activeView),e.forceUpdate())})},l.prototype.componentDidUpdate=function(e,t){t.activeView!==this.state.activeView&&this.scrollSyncService.configure(this.state.activeView),this.calendarViewList&&(this.isActive?this.calendarViewList.focusActiveDate():this.calendarViewList.blurActiveDate()),this.oldValue=this.value},l.prototype.render=function(){var t=this,e=null!==this.value&&null!==this.oldValue?!d.isEqualDate(this.value,this.oldValue):this.value!==this.oldValue,n=g.viewInRange(this.state.activeView,v.CalendarViewEnum[void 0!==this.props.bottomView?this.props.bottomView:l.defaultProps.bottomView],v.CalendarViewEnum[void 0!==this.props.topView?this.props.topView:l.defaultProps.topView]),i=b(this.min,this.max,this.value,this.value),r=i?d.getDate(i):null;this.focusedDate=d.getDate(g.dateInRange(e&&null!==i?i:this.state.focusedDate,this.min,this.max)),this.intl=h.provideIntlService(this),this.bus.configure(this.bottomView,this.topView),this.service=this.bus.service(n,this.intl);var a=p.classNames("k-widget k-calendar k-calendar-infinite",{"k-state-disabled":this.props.disabled,"k-week-number":this.props.weekNumber},this.props.className),o={"aria-disabled":this.props.disabled,"aria-activedescendant":this.cellUID+this.focusedDate.getTime()},s=[this.props.navigation&&c.createElement(m.Navigation,{key:0,ref:function(e){t.Navigation=e},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,onChange:this.handleNavigationChange,service:this.service,dom:this.dom,navigationItem:this.props.navigationItem}),c.createElement(f.ViewList,{key:1,ref:function(e){t.calendarViewList=e},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,bus:this.bus,service:this.service,cell:this.props.cell,weekCell:this.props.weekCell,dom:this.dom,smoothScroll:this.props.smoothScroll,showWeekNumbers:this.props.weekNumber,onChange:this.handleDateChange,value:r,cellUID:this.cellUID,headerTitle:this.props.headerTitle})];return c.createElement("div",u({},o,{ref:function(e){t._element=e},className:a,id:this.props.id||this.id,role:"grid",tabIndex:this.props.disabled?void 0:this.props.tabIndex||0,onScroll:this.handleScroll,onFocus:this.handleFocus,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseDown:this.handleMouseDown,onClick:this.handleClick}),s)},l.propTypes={className:a.string,defaultActiveView:a.oneOf(["month","year","decade","century"]),defaultValue:a.instanceOf(Date),disabled:a.bool,focusedDate:a.instanceOf(Date),id:a.string,max:a.instanceOf(Date),min:a.instanceOf(Date),navigation:a.bool,smoothScroll:a.bool,onBlur:a.func,onChange:a.func,onFocus:a.func,tabIndex:a.number,value:a.instanceOf(Date),weekNumber:a.bool,topView:function(e,t,n){var i=e[t],r=e.bottomView;if(i&&r&&v.CalendarViewEnum[i]<v.CalendarViewEnum[r])return new Error("Invalid prop + "+t+" suplied to "+n+".\n "+t+" can not be smaller than bottomView.\n ")},bottomView:function(e,t,n){var i=e[t],r=e.topView;if(i&&r&&v.CalendarViewEnum[i]>v.CalendarViewEnum[r])return new Error("Invalid prop + "+t+" suplied to "+n+".\n "+t+" can not be bigger than topView.\n ")}},l.defaultProps={disabled:!1,min:o.MIN_DATE,max:o.MAX_DATE,navigation:!0,defaultActiveView:"month",defaultValue:null,smoothScroll:!0,topView:"century",bottomView:"month"},l}(c.Component);t.Calendar=l,h.registerForIntl(l)},function(e,t,n){"use strict";var i,r,a,o,s=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var l,u,c=n(2),p=n(4),d=n(3),h=n(35);(u=l=t.ScrollDirection||(t.ScrollDirection={}))[u.Backward=0]="Backward",u[u.Forward=1]="Forward";var f=((r={})[l.Forward]=function(t){return function(e){return e+t}},r[l.Backward]=function(t){return function(e){return e-t}},r),m=((a={})[l.Forward]=function(t){return function(e){return Math.min(e,t)}},a[l.Backward]=function(t){return function(e){return Math.max(e,t)}},a),v=((o={})[l.Forward]=function(t){return function(e){return e<t}},o[l.Backward]=function(t){return function(e){return t<e}},o),g=function(t){function i(e){var p=t.call(this,e)||this;return p.animationInProgress=!1,p.scrollTo=function(e){var t="vertical"===p.direction?"scrollTop":"scrollLeft";p.scrollContainer&&(p.scrollContainer[t]=e)},p.scrollToIndex=function(e){p.rowHeightService&&(p.animationInProgress=!1,p.scrollTo(p.rowHeightService.offset(e)))},p.animateToIndex=function(e){if(p.rowHeightService&&window){window.cancelAnimationFrame(p.cancelAnimation);var t=p.rowHeightService.offset(e),n=p.getContainerScrollDirection(t),i=p.scrollRange(t,n),r=i.start,a=i.end;if(r!==a){var o=p.scrollStep(r,a),s=f[n](o),l=m[n](a),u=v[n](s(a)),c=function(e){p.animationInProgress=!0;var t=s(e);p.scrollTo(l(t)),u(t)?p.cancelAnimation=window.requestAnimationFrame(function(){c(t)}):p.animationInProgress=!1};p.cancelAnimation=window.requestAnimationFrame(function(){c(r)})}}},p.scrollToBottom=function(){p.rowHeightService&&p.scrollTo(p.rowHeightService.totalHeight()+p.props.bottomOffset)},p.scrollStep=function(e,t){var n=p.props.scrollDuration||i.defaultProps.scrollDuration;return Math.abs(t-e)/(n/17)},p.scrollRange=function(e,t){var n=p.containerScrollPosition;if(parseInt(""+e,10)===parseInt(""+n,10))return{start:e,end:e};var i=p.containerMaxScroll(),r=t===l.Backward?1:-1,a=function(e,t,n){return Math.min(Math.abs(t-e),n)}(n,e,p.props.maxScrollDifference),o=Math.min(e,i);return{start:Math.min(Math.max(o+r*a,0),i),end:o}},p.containerMaxScroll=function(){return p.containerScrollSize-p.containerOffsetSize},p.getContainerScrollDirection=function(e){return e<p.containerScrollPosition?l.Backward:l.Forward},p.initServices=function(e){void 0===e&&(e=p.props);var t="vertical"===p.direction?e.itemHeight:e.itemWidth;void 0!==t&&(p.rowHeightService=new h.RowHeightService(e.total,t,0),p.scrollerService.create(p.rowHeightService,e.skip,e.take,e.total,e.topOffset,p.scrollOffsetSize,p.direction))},p.getContainerProperty=function(e){return p.scrollContainer?p.scrollContainer[e]:0},p.handleScroll=function(e){if(p.scrollContainer&&p.rowHeightService){var t=e.target;p.scrollerService.onScroll({scrollLeft:t.scrollLeft,scrollTop:t.scrollTop,offsetHeight:t.offsetHeight,offsetWidth:t.offsetWidth});var n=p.rowHeightService.index(p.containerScrollPosition-p.props.topOffset),i=p.props.onScrollAction,r={index:n,target:t,scrollAction:p.scrollAction,pageAction:p.pageAction,animationInProgress:p.animationInProgress};i&&i.call(void 0,r),p.scrollAction=void 0,p.pageAction=void 0}},p.handleScrollAction=function(e){p.scrollAction=e},p.handlePageAction=function(e){p.pageAction=e},p.scrollerService=new h.ScrollerService(p.handleScrollAction,p.handlePageAction),p}return s(i,t),Object.defineProperty(i.prototype,"element",{get:function(){return this.scrollContainer},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"containerOffsetSize",{get:function(){return this.getContainerProperty("vertical"===this.direction?"offsetHeight":"offsetWidth")},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"containerScrollSize",{get:function(){return this.getContainerProperty("vertical"===this.direction?"scrollHeight":"scrollWidth")},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"containerScrollPosition",{get:function(){return this.getContainerProperty("vertical"===this.direction?"scrollTop":"scrollLeft")},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"direction",{get:function(){return void 0!==this.props.direction?this.props.direction:i.defaultProps.direction},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"scrollOffsetSize",{get:function(){return void 0!==this.props.scrollOffsetSize?this.props.scrollOffsetSize:i.defaultProps.scrollOffsetSize},enumerable:!0,configurable:!0}),i.prototype.activeIndex=function(){return this.itemIndex(Math.ceil(this.containerScrollPosition))},i.prototype.itemIndex=function(e){return this.rowHeightService?this.rowHeightService.index(e):0},i.prototype.itemOffset=function(e){return this.rowHeightService?this.rowHeightService.offset(e):0},i.prototype.isIndexVisible=function(e){if(!this.rowHeightService)return!1;var t=this.containerScrollPosition,n=t+this.containerOffsetSize,i=this.rowHeightService.offset(e),r=i+this.rowHeightService.height(e);return t<=i&&r<=n},i.prototype.isListScrolled=function(e){return!!this.rowHeightService&&this.containerScrollPosition!==this.rowHeightService.offset(e)},i.prototype.componentDidMount=function(){var e=this.props.onMount;e&&e.call(void 0,this)},i.prototype.render=function(){var t=this;this.lastTotal===this.props.total&&this.lastDirection===this.direction&&this.lastTake===this.props.take||(this.initServices(),this.lastTotal=this.props.total,this.lastDirection=this.direction,this.lastTake=this.props.take);var e=""+((this.rowHeightService?this.rowHeightService.totalHeight():0)+this.props.bottomOffset),n="vertical"===this.direction?{height:e+"px"}:{width:e+"px"},i=d.classNames("k-content k-scrollable",{"k-scrollable-horizontal":"horizontal"===this.direction},this.props.className),r=d.classNames("k-scrollable-placeholder",{"k-scrollable-horizontal-placeholder":"horizontal"===this.direction});return c.createElement("div",{ref:function(e){t.scrollContainer=e},onScroll:this.handleScroll,className:i,tabIndex:this.props.tabIndex,role:this.props.role},this.props.children,c.createElement("div",{style:n,className:r}))},i.propTypes={bottomOffset:p.number.isRequired,className:p.string,direction:p.oneOf(["horizontal","vertical"]),forceScroll:p.bool,itemHeight:p.number,itemWidth:p.number,maxScrollDifference:p.number,onScroll:p.func,onScrollAction:p.func,scrollDuration:p.number,scrollOffsetSize:p.number,skip:p.number.isRequired,tabIndex:p.number,take:p.number.isRequired,topOffset:p.number.isRequired,total:p.number.isRequired,role:p.string},i.defaultProps={direction:"vertical",forceScroll:!1,scrollOffsetSize:0,maxScrollDifference:100,scrollDuration:100},i}(c.Component);t.Virtualization=g},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0}),(i=t.CalendarViewEnum||(t.CalendarViewEnum={}))[i.month=0]="month",i[i.year=1]="year",i[i.decade=2]="decade",i[i.century=3]="century"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(38);t.BusViewService=i.BusViewService;var r=n(22);t.CenturyViewService=r.CenturyViewService;var a=n(23);t.DecadeViewService=a.DecadeViewService;var o=n(39);t.DOMService=o.DOMService;var s=n(24);t.MonthViewService=s.MonthViewService;var l=n(40);t.NavigationService=l.NavigationService;var u=n(41);t.ScrollSyncService=u.ScrollSyncService;var c=n(42);t.WeekNamesService=c.WeekNamesService;var p=n(25);t.YearViewService=p.YearViewService},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TIME_PART={dayperiod:"dayperiod",hour:"hour",millisecond:"millisecond",minute:"minute",second:"second"}},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),s=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e};Object.defineProperty(t,"__esModule",{value:!0});var l=n(2),a=n(4),u=n(0),c=n(5),p=n(20),d=n(21),o=n(7),h=n(1),f=n(17),m=function(e){return l.createElement("td",{key:e}," ")},v=function(e){function t(){var o=null!==e&&e.apply(this,arguments)||this;return o.buildWeekNumber=function(e,t){if(!o.firstDate(e))return m("week-cell-"+t);var n=o.getWeekNumber(o.firstDate(e)),i="kendo-react-calendar-week-cell-"+n,r={className:"k-alt",value:n};return o.props.weekCell?l.createElement(o.props.weekCell,s({},r,{key:i}),n):l.createElement(d.CalendarWeekCell,s({},r,{key:i}),n)},o.buildRow=function(e){return e.map(function(e,t){if(!e)return m(t);var n={"aria-selected":e.isSelected},i="kendo-react-calendar-cell-"+e.value.getTime(),r=e.value.getTime()<o.props.min.getTime()||e.value.getTime()>o.props.max.getTime(),a=s({},n,e,{isDisabled:r,view:o.props.activeView,onClick:o.handleClick,onMouseEnter:o.handleMouseEnter,onMouseLeave:o.handleMouseLeave});return o.props.cell?l.createElement(o.props.cell,s({},a,{key:i}),e.formattedValue):l.createElement(p.CalendarCell,s({},a,{key:i}),e.formattedValue)})},o.firstDate=function(e){var t=o.firstWeekDateContext(e);return t?t.value:null},o.firstWeekDateContext=function(e){if(!o.weekNumber)return null;for(var t=0,n=e[t];!n&&t<e.length;)n=e[++t];return n},o.handleClick=function(e,t){var n=o.props.onChange;if(n){var i={value:u.cloneDate(e),target:o,nativeEvent:t&&t.nativeEvent,syntheticEvent:t};n.call(void 0,i)}},o.handleMouseEnter=function(e){var t=o.props.onCellEnter;t&&t.call(void 0,u.cloneDate(e))},o.handleMouseLeave=function(e){var t=o.props.onCellLeave;t&&t.call(void 0,u.cloneDate(e))},o}return r(t,e),Object.defineProperty(t.prototype,"isHorizontal",{get:function(){return"horizontal"===this.props.direction},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isMonthView",{get:function(){return this.props.activeView===o.CalendarViewEnum.month},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"weekNumber",{get:function(){return Boolean(this.props.showWeekNumbers&&this.props.activeView===o.CalendarViewEnum.month)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"selectedDate",{get:function(){return void 0!==this.props.selectedDate?this.props.selectedDate:t.defaultProps.selectedDate},enumerable:!0,configurable:!0}),t.prototype.render=function(){var n=this;this.intl=c.provideIntlService(this),this.weekService=new f.WeekNamesService(this.intl);var e=this.weekService.getWeekNames(this.weekNumber),t=this.props.service.rowLength(this.weekNumber),i=this.props.service.title(this.props.viewDate),r=h.getToday(),a=h.setTime(this.props.viewDate,r),o=this.props.service.data({cellUID:this.props.cellUID,focusedDate:this.props.focusedDate,isActiveView:!this.props.bus.canMoveDown(this.props.activeView),selectedDate:this.selectedDate,selectionRange:this.props.selectionRange,viewDate:a});return l.createElement("tbody",{role:"rowgroup"},!this.isHorizontal&&l.createElement("tr",{role:"row"},l.createElement("th",{scope:"col",colSpan:t},i)),this.isMonthView&&this.isHorizontal&&l.createElement("tr",{role:"row"},e.map(function(e,t){return l.createElement("th",{key:t},e)})),o.map(function(e,t){return l.createElement("tr",{role:"row",key:t},n.weekNumber&&n.buildWeekNumber(e,t),n.buildRow(e))}))},t.prototype.getWeekNumber=function(e){return this.weekNumber?u.weekInYear(e,this.intl.firstDay()):null},t.propTypes={activeRangeEnd:a.oneOf(["start","end",null]),activeView:a.number.isRequired,cellUID:a.string.isRequired,direction:a.oneOf(["horizontal","vertical"]),focusedDate:a.instanceOf(Date).isRequired,max:a.instanceOf(Date).isRequired,min:a.instanceOf(Date).isRequired,onChange:a.func,selectedDate:a.oneOfType([a.instanceOf(Date),a.arrayOf(a.instanceOf(Date))]),showWeekNumbers:a.bool,viewDate:a.instanceOf(Date).isRequired},t.defaultProps={direction:"vertical",selectedDate:h.getToday(),showWeekNumbers:!1},t}(l.Component);t.View=v,c.registerForIntl(v)},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),v=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},g=this&&this.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&(n[i[r]]=e[i[r]])}return n};Object.defineProperty(t,"__esModule",{value:!0});var y=n(2),b=n(3),a=function(e){function t(){var r=null!==e&&e.apply(this,arguments)||this;return r.handleClick=function(e){var t=r.props,n=t.onClick,i=t.value;n&&n.call(void 0,i,e)},r.handleMouseEnter=function(){var e=r.props,t=e.onMouseEnter,n=e.value;t&&t.call(void 0,n)},r.handleMouseLeave=function(){var e=r.props,t=e.onMouseLeave,n=e.value;t&&t.call(void 0,n)},r}return r(t,e),t.prototype.shouldComponentUpdate=function(e){var t=this.props,n=t.value,i=g(t,["value"]),r=e.value,a=g(e,["value"]);return!((!n||!r||n.getTime()===r.getTime())&&function(e,t){var n=Object.getOwnPropertyNames(e),i=Object.getOwnPropertyNames(t);if(n.length!==i.length)return!1;for(var r=0;r<n.length;r++){var a=n[r];if(e[a]!==t[a])return!1}return!0}(i,a))},t.prototype.render=function(){var e=this.props,t=e.className,n=(e.formattedValue,e.isWeekend),i=e.isFocused,r=e.isSelected,a=e.isRangeStart,o=e.isRangeMid,s=e.isRangeEnd,l=e.isRangeSplitStart,u=e.isRangeSplitEnd,c=e.isToday,p=e.isDisabled,d=(e.view,e.value,g(e,["className","formattedValue","isWeekend","isFocused","isSelected","isRangeStart","isRangeMid","isRangeEnd","isRangeSplitStart","isRangeSplitEnd","isToday","isDisabled","view","value"])),h="end"===this.props.activeRangeEnd&&s,f="start"===this.props.activeRangeEnd&&a,m=b.classNames({"k-range-end":s,"k-range-mid":o,"k-range-split-end":u,"k-range-split-start":l,"k-range-start":a,"k-state-active":f||h,"k-state-pending-focus":i,"k-state-selected":r||a||s,"k-today":c,"k-weekend":n,"k-state-disabled":p},t);return y.createElement("td",v({},d,{className:m,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave}),y.createElement("span",{className:"k-link"},this.props.children))},t}(y.Component);t.CalendarCell=a},function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r(t,e),t.prototype.render=function(){return o.createElement("td",a({},this.props),this.props.children)},t}(o.Component);t.CalendarWeekCell=s},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0});var y=n(0),r=n(7),b=n(1),a=[[]],o=((i={})[r.Action.Left]=function(e){return y.addDecades(e,-1)},i[r.Action.Up]=function(e){return y.addDecades(e,-5)},i[r.Action.Right]=function(e){return y.addDecades(e,1)},i[r.Action.Down]=function(e){return y.addDecades(e,5)},i[r.Action.PrevView]=function(e){return y.addCenturies(e,-1)},i[r.Action.NextView]=function(e){return y.addCenturies(e,1)},i[r.Action.FirstInView]=function(e){return y.firstDecadeOfCentury(e)},i[r.Action.LastInView]=function(e){return y.lastDecadeOfCentury(e)},i),s=function(){function e(){}return e.prototype.addToDate=function(e,t){return y.addCenturies(e,t)},e.prototype.datesList=function(t,e){return b.range(0,e).map(function(e){return y.addCenturies(t,e)})},e.prototype.data=function(e){var s=this,l=e.cellUID,u=e.focusedDate,c=e.isActiveView,p=e.max,d=e.min,h=e.selectedDate,t=e.selectionRange,f=void 0===t?r.EMPTY_SELECTIONRANGE:t,n=e.viewDate;if(!n)return a;var i=b.range(0,5),m=y.firstDecadeOfCentury(n),v=y.lastDecadeOfCentury(n),g=b.getToday();return b.range(0,2).map(function(e){var o=y.addDecades(m,5*e);return i.map(function(e){var t=s.normalize(y.addDecades(o,e),d,p);if(!s.isInRange(t,d,p))return null;var n=s.isEqual(t,f.start),i=s.isEqual(t,f.end),r=!n&&!i&&b.isInSelectionRange(t,f),a=c&&(Array.isArray(h)?s.isSelectedFromArray(t,h,d,p):b.isInRange(h,d,p)&&s.isEqual(t,h));return{formattedValue:s.value(t),id:""+l+t.getTime(),isFocused:s.isEqual(t,u),isSelected:a,isWeekend:!1,isRangeStart:n,isRangeMid:r,isRangeEnd:i,isRangeSplitEnd:r&&s.isEqual(t,v),isRangeSplitStart:r&&s.isEqual(t,m),isToday:s.isEqual(t,g),title:s.cellTitle(t),value:t}})})},e.prototype.isSelectedFromArray=function(t,e,n,i){var r=this,a=!1;return e.forEach(function(e){b.isInRange(t,n,i)&&r.isEqual(t,e)&&(a=!0)}),a},e.prototype.isEqual=function(e,t){return!(!e||!t)&&y.firstYearOfDecade(e).getFullYear()===y.firstYearOfDecade(t).getFullYear()},e.prototype.isInArray=function(e,t){if(!t.length)return!1;var n=e.getFullYear();return t[0].getFullYear()<=n&&n<=t[t.length-1].getFullYear()+99},e.prototype.isInRange=function(e,t,n){var i=y.firstYearOfDecade(e).getFullYear(),r=!t||y.firstYearOfDecade(t).getFullYear()<=i,a=!n||i<=y.firstYearOfDecade(n).getFullYear();return r&&a},e.prototype.isInSameView=function(e,t){return 0===y.durationInCenturies(e,t)},e.prototype.isRangeStart=function(e){return e.getFullYear()%1e3==0},e.prototype.move=function(e,t){var n=o[t];return n?n(e):e},e.prototype.cellTitle=function(e){return y.firstYearOfDecade(e).getFullYear().toString()},e.prototype.navigationTitle=function(e){return e?y.firstDecadeOfCentury(e).getFullYear().toString():""},e.prototype.title=function(e){return e?y.firstDecadeOfCentury(e).getFullYear()+" - "+y.lastDecadeOfCentury(e).getFullYear():""},e.prototype.rowLength=function(e){return 5},e.prototype.skip=function(e,t){return y.durationInCenturies(t,e)},e.prototype.total=function(e,t){return y.durationInCenturies(e,t)+1},e.prototype.value=function(e){return e?y.firstYearOfDecade(e).getFullYear().toString():""},e.prototype.viewDate=function(e,t,n){return void 0===n&&(n=1),y.durationInCenturies(e,t)<n?y.addCenturies(e,-1):e},e.prototype.normalize=function(e,t,n){return e<t&&this.isEqual(e,t)?y.cloneDate(t):n<e&&this.isEqual(e,n)?y.cloneDate(n):e},e}();t.CenturyViewService=s},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0});var y=n(0),r=n(10),a=n(11),b=n(1),o=[[]],s=((i={})[r.Action.Left]=function(e){return y.addYears(e,-1)},i[r.Action.Up]=function(e){return y.addYears(e,-5)},i[r.Action.Right]=function(e){return y.addYears(e,1)},i[r.Action.Down]=function(e){return y.addYears(e,5)},i[r.Action.PrevView]=function(e){return y.addDecades(e,-1)},i[r.Action.NextView]=function(e){return y.addDecades(e,1)},i[r.Action.FirstInView]=function(e){return y.firstYearOfDecade(e)},i[r.Action.LastInView]=function(e){return y.lastYearOfDecade(e)},i),l=function(){function e(){}return e.prototype.addToDate=function(e,t){return y.addDecades(e,t)},e.prototype.datesList=function(t,e){return b.range(0,e).map(function(e){return y.addDecades(t,e)})},e.prototype.data=function(e){var s=this,l=e.cellUID,u=e.focusedDate,c=e.isActiveView,p=e.max,d=e.min,h=e.selectedDate,t=e.selectionRange,f=void 0===t?a.EMPTY_SELECTIONRANGE:t,n=e.viewDate;if(!n)return o;var i=b.range(0,5),m=y.firstYearOfDecade(n),v=y.lastYearOfDecade(n),g=b.getToday();return b.range(0,2).map(function(e){var o=y.addYears(m,5*e);return i.map(function(e){var t=s.normalize(y.addYears(o,e),d,p);if(!s.isInRange(t,d,p))return null;var n=s.isEqual(t,f.start),i=s.isEqual(t,f.end),r=!n&&!i&&b.isInSelectionRange(t,f),a=c&&(Array.isArray(h)?s.isSelectedFromArray(t,h,d,p):b.isInRange(h,d,p)&&s.isEqual(t,h));return{formattedValue:s.value(t),id:""+l+t.getTime(),isFocused:s.isEqual(t,u),isSelected:a,isWeekend:!1,isRangeStart:n,isRangeMid:r,isRangeEnd:i,isRangeSplitEnd:r&&s.isEqual(t,v),isRangeSplitStart:r&&s.isEqual(t,m),isToday:s.isEqual(t,g),title:s.cellTitle(t),value:t}})})},e.prototype.isSelectedFromArray=function(t,e,n,i){var r=this,a=!1;return e.forEach(function(e){b.isInRange(t,n,i)&&r.isEqual(t,e)&&(a=!0)}),a},e.prototype.isEqual=function(e,t){return!(!e||!t)&&e.getFullYear()===t.getFullYear()},e.prototype.isInArray=function(e,t){if(!t.length)return!1;var n=e.getFullYear();return t[0].getFullYear()<=n&&n<=t[t.length-1].getFullYear()+9},e.prototype.isInRange=function(e,t,n){var i=e.getFullYear(),r=!t||t.getFullYear()<=i,a=!n||i<=n.getFullYear();return r&&a},e.prototype.isRangeStart=function(e){return e.getFullYear()%100==0},e.prototype.isInSameView=function(e,t){return 0===y.durationInDecades(e,t)},e.prototype.move=function(e,t){var n=s[t];return n?n(e):e},e.prototype.cellTitle=function(e){return e.getFullYear().toString()},e.prototype.navigationTitle=function(e){return e?y.firstYearOfDecade(e).getFullYear().toString():""},e.prototype.title=function(e){return e?y.firstYearOfDecade(e).getFullYear()+" - "+y.lastYearOfDecade(e).getFullYear():""},e.prototype.rowLength=function(e){return 5},e.prototype.skip=function(e,t){return y.durationInDecades(t,e)},e.prototype.total=function(e,t){return y.durationInDecades(e,t)+1},e.prototype.value=function(e){return e?e.getFullYear().toString():""},e.prototype.viewDate=function(e,t,n){return void 0===n&&(n=1),y.durationInDecades(e,t)<n?y.addDecades(e,-1):e},e.prototype.normalize=function(e,t,n){return e<t&&this.isEqual(e,t)?y.cloneDate(t):n<e&&this.isEqual(e,n)?y.cloneDate(n):e},e}();t.DecadeViewService=l},function(e,t,n){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0});var y=n(0),r=n(10),a=n(11),b=n(1),o=[[]],s=((i={})[r.Action.Left]=function(e){return y.addDays(e,-1)},i[r.Action.Up]=function(e){return y.addWeeks(e,-1)},i[r.Action.Right]=function(e){return y.addDays(e,1)},i[r.Action.Down]=function(e){return y.addWeeks(e,1)},i[r.Action.PrevView]=function(e){return y.addMonths(e,-1)},i[r.Action.NextView]=function(e){return y.addMonths(e,1)},i[r.Action.FirstInView]=function(e){return y.firstDayOfMonth(e)},i[r.Action.LastInView]=function(e){return y.lastDayOfMonth(e)},i),l=function(){function e(e){this.intl=e}return e.prototype.addToDate=function(e,t){return y.addMonths(e,t)},e.prototype.datesList=function(t,e){return b.range(0,e).map(function(e){return y.addMonths(t,e)})},e.prototype.data=function(e){var s=this,l=e.cellUID,u=e.focusedDate,c=e.isActiveView,p=e.max,d=e.min,h=e.selectedDate,t=e.selectionRange,f=void 0===t?a.EMPTY_SELECTIONRANGE:t,n=e.viewDate;if(!n)return o;var m=y.firstDayOfMonth(n),v=y.lastDayOfMonth(n),i=y.dayOfWeek(m,this.intl.firstDay(),-1),r=b.range(0,7),g=b.getToday();return b.range(0,6).map(function(e){var o=y.addDays(i,7*e);return r.map(function(e){var t=s.normalize(y.addDays(o,e),d,p);if(t<m||v<t||t<d||p<t)return null;var n=s.isEqual(t,f.start),i=s.isEqual(t,f.end),r=!n&&!i&&b.isInSelectionRange(t,f),a=c&&(Array.isArray(h)?s.isSelectedFromArray(t,h,d,p):b.isInRange(h,d,p)&&s.isEqual(t,h));return{formattedValue:s.value(t),id:""+l+t.getTime(),isFocused:s.isEqual(t,u),isSelected:a,isWeekend:s.isWeekend(t),isRangeStart:n,isRangeMid:r,isRangeEnd:i,isRangeSplitStart:r&&s.isEqual(t,m),isRangeSplitEnd:r&&s.isEqual(t,v),isToday:s.isEqual(t,g),title:s.cellTitle(t),value:t}})})},e.prototype.isEqual=function(e,t){return!(!e||!t)&&y.getDate(e).getTime()===y.getDate(t).getTime()},e.prototype.isSelectedFromArray=function(t,e,n,i){var r=this,a=!1;return e.forEach(function(e){b.isInRange(t,n,i)&&r.isEqual(t,e)&&(a=!0)}),a},e.prototype.isInArray=function(e,t){return!!t.length&&y.firstDayOfMonth(t[0])<=e&&e<=y.lastDayOfMonth(t[t.length-1])},e.prototype.isInRange=function(e,t,n){var i=y.getDate(e),r=!t||y.getDate(t)<=i,a=!n||i<=y.getDate(n);return r&&a},e.prototype.isInSameView=function(e,t){return 0===y.durationInMonths(e,t)},e.prototype.isRan