@steedos-widgets/fullcalendar 1.2.2 → 1.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,20 +4,20 @@
4
4
  Docs & License: https://fullcalendar.io/
5
5
  (c) 2022 Adam Shaw
6
6
  */
7
- var EventSourceApi=function(){function e(e,t){this.context=e,this.internalEventSource=t}return e.prototype.remove=function(){this.context.dispatch({type:"REMOVE_EVENT_SOURCE",sourceId:this.internalEventSource.sourceId})},e.prototype.refetch=function(){this.context.dispatch({type:"FETCH_EVENT_SOURCES",sourceIds:[this.internalEventSource.sourceId],isRefetch:!0})},Object.defineProperty(e.prototype,"id",{get:function(){return this.internalEventSource.publicId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this.internalEventSource.meta.url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"format",{get:function(){return this.internalEventSource.meta.format},enumerable:!1,configurable:!0}),e}();function removeElement(e){e.parentNode&&e.parentNode.removeChild(e)}function elementClosest(e,t){if(e.closest)return e.closest(t);if(!document.documentElement.contains(e))return null;do{if(elementMatches(e,t))return e;e=e.parentElement||e.parentNode}while(null!==e&&1===e.nodeType);return null}function elementMatches(e,t){return(e.matches||e.matchesSelector||e.msMatchesSelector).call(e,t)}function findElements(e,t){for(var n=e instanceof HTMLElement?[e]:e,r=[],o=0;o<n.length;o+=1)for(var i=n[o].querySelectorAll(t),a=0;a<i.length;a+=1)r.push(i[a]);return r}var PIXEL_PROP_RE=/(top|left|right|bottom|width|height)$/i;function applyStyle(e,t){for(var n in t)applyStyleProp(e,n,t[n])}function applyStyleProp(e,t,n){null==n?e.style[t]="":"number"==typeof n&&PIXEL_PROP_RE.test(t)?e.style[t]=n+"px":e.style[t]=n}function getEventTargetViaRoot(e){var t,n;return null!==(n=null===(t=e.composedPath)||void 0===t?void 0:t.call(e)[0])&&void 0!==n?n:e.target}function getElRoot(e){return e.getRootNode?e.getRootNode():document}var guid$1=0;function getUniqueDomId(){return"fc-dom-"+(guid$1+=1)}function preventDefault(e){e.preventDefault()}function buildDelegationHandler(e,t){return function(n){var r=elementClosest(n.target,e);r&&t.call(r,n,r)}}function listenBySelector(e,t,n,r){var o=buildDelegationHandler(n,r);return e.addEventListener(t,o),function(){e.removeEventListener(t,o)}}function listenToHoverBySelector(e,t,n,r){var o;return listenBySelector(e,"mouseover",t,(function(e,t){if(t!==o){o=t,n(e,t);var i=function(e){o=null,r(e,t),t.removeEventListener("mouseleave",i)};t.addEventListener("mouseleave",i)}}))}var transitionEventNames=["webkitTransitionEnd","otransitionend","oTransitionEnd","msTransitionEnd","transitionend"];function whenTransitionDone(e,t){var n=function(r){t(r),transitionEventNames.forEach((function(t){e.removeEventListener(t,n)}))};transitionEventNames.forEach((function(t){e.addEventListener(t,n)}))}function createAriaClickAttrs(e){return __assign$1({onClick:e},createAriaKeyboardAttrs(e))}function createAriaKeyboardAttrs(e){return{tabIndex:0,onKeyDown:function(t){"Enter"!==t.key&&" "!==t.key||(e(t),t.preventDefault())}}}var guidNumber=0;function guid(){return String(guidNumber+=1)}function disableCursor(){document.body.classList.add("fc-not-allowed")}function enableCursor(){document.body.classList.remove("fc-not-allowed")}function preventSelection(e){e.classList.add("fc-unselectable"),e.addEventListener("selectstart",preventDefault)}function allowSelection(e){e.classList.remove("fc-unselectable"),e.removeEventListener("selectstart",preventDefault)}function preventContextMenu(e){e.addEventListener("contextmenu",preventDefault)}function allowContextMenu(e){e.removeEventListener("contextmenu",preventDefault)}function parseFieldSpecs(e){var t,n,r=[],o=[];for("string"==typeof e?o=e.split(/\s*,\s*/):"function"==typeof e?o=[e]:Array.isArray(e)&&(o=e),t=0;t<o.length;t+=1)"string"==typeof(n=o[t])?r.push("-"===n.charAt(0)?{field:n.substring(1),order:-1}:{field:n,order:1}):"function"==typeof n&&r.push({func:n});return r}function compareByFieldSpecs(e,t,n){var r,o;for(r=0;r<n.length;r+=1)if(o=compareByFieldSpec(e,t,n[r]))return o;return 0}function compareByFieldSpec(e,t,n){return n.func?n.func(e,t):flexibleCompare(e[n.field],t[n.field])*(n.order||1)}function flexibleCompare(e,t){return e||t?null==t?-1:null==e?1:"string"==typeof e||"string"==typeof t?String(e).localeCompare(String(t)):e-t:0}function padStart(e,t){var n=String(e);return"000".substr(0,t-n.length)+n}function formatWithOrdinals(e,t,n){return"function"==typeof e?e.apply(void 0,t):"string"==typeof e?t.reduce((function(e,t,n){return e.replace("$"+n,t||"")}),e):n}function compareNumbers(e,t){return e-t}function isInt(e){return e%1==0}function computeSmallestCellWidth(e){var t=e.querySelector(".fc-scrollgrid-shrink-frame"),n=e.querySelector(".fc-scrollgrid-shrink-cushion");if(!t)throw new Error("needs fc-scrollgrid-shrink-frame className");if(!n)throw new Error("needs fc-scrollgrid-shrink-cushion className");return e.getBoundingClientRect().width-t.getBoundingClientRect().width+n.getBoundingClientRect().width}var DAY_IDS=["sun","mon","tue","wed","thu","fri","sat"];function addWeeks(e,t){var n=dateToUtcArray(e);return n[2]+=7*t,arrayToUtcDate(n)}function addDays(e,t){var n=dateToUtcArray(e);return n[2]+=t,arrayToUtcDate(n)}function addMs(e,t){var n=dateToUtcArray(e);return n[6]+=t,arrayToUtcDate(n)}function diffWeeks(e,t){return diffDays(e,t)/7}function diffDays(e,t){return(t.valueOf()-e.valueOf())/864e5}function diffHours(e,t){return(t.valueOf()-e.valueOf())/36e5}function diffMinutes(e,t){return(t.valueOf()-e.valueOf())/6e4}function diffSeconds(e,t){return(t.valueOf()-e.valueOf())/1e3}function diffDayAndTime(e,t){var n=startOfDay(e),r=startOfDay(t);return{years:0,months:0,days:Math.round(diffDays(n,r)),milliseconds:t.valueOf()-r.valueOf()-(e.valueOf()-n.valueOf())}}function diffWholeWeeks(e,t){var n=diffWholeDays(e,t);return null!==n&&n%7==0?n/7:null}function diffWholeDays(e,t){return timeAsMs(e)===timeAsMs(t)?Math.round(diffDays(e,t)):null}function startOfDay(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()])}function startOfHour(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours()])}function startOfMinute(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes()])}function startOfSecond(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds()])}function weekOfYear(e,t,n){var r=e.getUTCFullYear(),o=weekOfGivenYear(e,r,t,n);if(o<1)return weekOfGivenYear(e,r-1,t,n);var i=weekOfGivenYear(e,r+1,t,n);return i>=1?Math.min(o,i):o}function weekOfGivenYear(e,t,n,r){var o=arrayToUtcDate([t,0,1+firstWeekOffset(t,n,r)]),i=startOfDay(e),a=Math.round(diffDays(o,i));return Math.floor(a/7)+1}function firstWeekOffset(e,t,n){var r=7+t-n;return-((7+arrayToUtcDate([e,0,r]).getUTCDay()-t)%7)+r-1}function dateToLocalArray(e){return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()]}function arrayToLocalDate(e){return new Date(e[0],e[1]||0,null==e[2]?1:e[2],e[3]||0,e[4]||0,e[5]||0)}function dateToUtcArray(e){return[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()]}function arrayToUtcDate(e){return 1===e.length&&(e=e.concat([0])),new Date(Date.UTC.apply(Date,e))}function isValidDate(e){return!isNaN(e.valueOf())}function timeAsMs(e){return 1e3*e.getUTCHours()*60*60+1e3*e.getUTCMinutes()*60+1e3*e.getUTCSeconds()+e.getUTCMilliseconds()}function createEventInstance(e,t,n,r){return{instanceId:guid(),defId:e,range:t,forcedStartTzo:null==n?null:n,forcedEndTzo:null==r?null:r}}var hasOwnProperty=Object.prototype.hasOwnProperty;function mergeProps(e,t){var n={};if(t)for(var r in t){for(var o=[],i=e.length-1;i>=0;i-=1){var a=e[i][r];if("object"==typeof a&&a)o.unshift(a);else if(void 0!==a){n[r]=a;break}}o.length&&(n[r]=mergeProps(o))}for(i=e.length-1;i>=0;i-=1){var s=e[i];for(var l in s)l in n||(n[l]=s[l])}return n}function filterHash(e,t){var n={};for(var r in e)t(e[r],r)&&(n[r]=e[r]);return n}function mapHash(e,t){var n={};for(var r in e)n[r]=t(e[r],r);return n}function arrayToHash(e){for(var t={},n=0,r=e;n<r.length;n++){t[r[n]]=!0}return t}function hashValuesToArray(e){var t=[];for(var n in e)t.push(e[n]);return t}function isPropsEqual(e,t){if(e===t)return!0;for(var n in e)if(hasOwnProperty.call(e,n)&&!(n in t))return!1;for(var n in t)if(hasOwnProperty.call(t,n)&&e[n]!==t[n])return!1;return!0}function getUnequalProps(e,t){var n=[];for(var r in e)hasOwnProperty.call(e,r)&&(r in t||n.push(r));for(var r in t)hasOwnProperty.call(t,r)&&e[r]!==t[r]&&n.push(r);return n}function compareObjs(e,t,n){if(void 0===n&&(n={}),e===t)return!0;for(var r in t)if(!(r in e)||!isObjValsEqual(e[r],t[r],n[r]))return!1;for(var r in e)if(!(r in t))return!1;return!0}function isObjValsEqual(e,t,n){return e===t||!0===n||!!n&&n(e,t)}function collectFromHash(e,t,n,r){void 0===t&&(t=0),void 0===r&&(r=1);var o=[];null==n&&(n=Object.keys(e).length);for(var i=t;i<n;i+=r){var a=e[i];void 0!==a&&o.push(a)}return o}function parseRecurring(e,t,n,r){for(var o=0;o<r.length;o+=1){var i=r[o].parse(e,n);if(i){var a=e.allDay;return null==a&&null==(a=t)&&null==(a=i.allDayGuess)&&(a=!1),{allDay:a,duration:i.duration,typeData:i.typeData,typeId:o}}}return null}function expandRecurring(e,t,n){var r=n.dateEnv,o=n.pluginHooks,i=n.options,a=e.defs,s=e.instances;for(var l in s=filterHash(s,(function(e){return!a[e.defId].recurringDef})),a){var u=a[l];if(u.recurringDef){var c=u.recurringDef.duration;c||(c=u.allDay?i.defaultAllDayEventDuration:i.defaultTimedEventDuration);for(var d=0,p=expandRecurringRanges(u,c,t,r,o.recurringTypes);d<p.length;d++){var f=p[d],h=createEventInstance(l,{start:f,end:r.add(f,c)});s[h.instanceId]=h}}}return{defs:a,instances:s}}function expandRecurringRanges(e,t,n,r,o){var i=o[e.recurringDef.typeId].expand(e.recurringDef.typeData,{start:r.subtract(n.start,t),end:n.end},r);return e.allDay&&(i=i.map(startOfDay)),i}var INTERNAL_UNITS=["years","months","days","milliseconds"],PARSE_RE=/^(-?)(?:(\d+)\.)?(\d+):(\d\d)(?::(\d\d)(?:\.(\d\d\d))?)?/;function createDuration(e,t){var n;return"string"==typeof e?parseString(e):"object"==typeof e&&e?parseObject(e):"number"==typeof e?parseObject(((n={})[t||"milliseconds"]=e,n)):null}function parseString(e){var t=PARSE_RE.exec(e);if(t){var n=t[1]?-1:1;return{years:0,months:0,days:n*(t[2]?parseInt(t[2],10):0),milliseconds:n*(60*(t[3]?parseInt(t[3],10):0)*60*1e3+60*(t[4]?parseInt(t[4],10):0)*1e3+1e3*(t[5]?parseInt(t[5],10):0)+(t[6]?parseInt(t[6],10):0))}}return null}function parseObject(e){var t={years:e.years||e.year||0,months:e.months||e.month||0,days:e.days||e.day||0,milliseconds:60*(e.hours||e.hour||0)*60*1e3+60*(e.minutes||e.minute||0)*1e3+1e3*(e.seconds||e.second||0)+(e.milliseconds||e.millisecond||e.ms||0)},n=e.weeks||e.week;return n&&(t.days+=7*n,t.specifiedWeeks=!0),t}function durationsEqual(e,t){return e.years===t.years&&e.months===t.months&&e.days===t.days&&e.milliseconds===t.milliseconds}function addDurations(e,t){return{years:e.years+t.years,months:e.months+t.months,days:e.days+t.days,milliseconds:e.milliseconds+t.milliseconds}}function subtractDurations(e,t){return{years:e.years-t.years,months:e.months-t.months,days:e.days-t.days,milliseconds:e.milliseconds-t.milliseconds}}function multiplyDuration(e,t){return{years:e.years*t,months:e.months*t,days:e.days*t,milliseconds:e.milliseconds*t}}function asRoughYears(e){return asRoughDays(e)/365}function asRoughMonths(e){return asRoughDays(e)/30}function asRoughDays(e){return asRoughMs(e)/864e5}function asRoughMs(e){return 31536e6*e.years+2592e6*e.months+864e5*e.days+e.milliseconds}function wholeDivideDurations(e,t){for(var n=null,r=0;r<INTERNAL_UNITS.length;r+=1){var o=INTERNAL_UNITS[r];if(t[o]){var i=e[o]/t[o];if(!isInt(i)||null!==n&&n!==i)return null;n=i}else if(e[o])return null}return n}function greatestDurationDenominator(e){var t=e.milliseconds;if(t){if(t%1e3!=0)return{unit:"millisecond",value:t};if(t%6e4!=0)return{unit:"second",value:t/1e3};if(t%36e5!=0)return{unit:"minute",value:t/6e4};if(t)return{unit:"hour",value:t/36e5}}return e.days?e.specifiedWeeks&&e.days%7==0?{unit:"week",value:e.days/7}:{unit:"day",value:e.days}:e.months?{unit:"month",value:e.months}:e.years?{unit:"year",value:e.years}:{unit:"millisecond",value:0}}function buildIsoString(e,t,n){void 0===n&&(n=!1);var r=e.toISOString();return r=r.replace(".000",""),n&&(r=r.replace("T00:00:00Z","")),r.length>10&&(null==t?r=r.replace("Z",""):0!==t&&(r=r.replace("Z",formatTimeZoneOffset(t,!0)))),r}function formatDayString(e){return e.toISOString().replace(/T.*$/,"")}function formatIsoTimeString(e){return padStart(e.getUTCHours(),2)+":"+padStart(e.getUTCMinutes(),2)+":"+padStart(e.getUTCSeconds(),2)}function formatTimeZoneOffset(e,t){void 0===t&&(t=!1);var n=e<0?"-":"+",r=Math.abs(e),o=Math.floor(r/60),i=Math.round(r%60);return t?n+padStart(o,2)+":"+padStart(i,2):"GMT"+n+o+(i?":"+padStart(i,2):"")}function isArraysEqual(e,t,n){if(e===t)return!0;var r,o=e.length;if(o!==t.length)return!1;for(r=0;r<o;r+=1)if(!(n?n(e[r],t[r]):e[r]===t[r]))return!1;return!0}function memoize(e,t,n){var r,o;return function(){for(var i=[],a=0;a<arguments.length;a++)i[a]=arguments[a];if(r){if(!isArraysEqual(r,i)){n&&n(o);var s=e.apply(this,i);t&&t(s,o)||(o=s)}}else o=e.apply(this,i);return r=i,o}}function memoizeObjArg(e,t,n){var r,o,i=this;return function(a){if(r){if(!isPropsEqual(r,a)){n&&n(o);var s=e.call(i,a);t&&t(s,o)||(o=s)}}else o=e.call(i,a);return r=a,o}}var EXTENDED_SETTINGS_AND_SEVERITIES={week:3,separator:0,omitZeroMinute:0,meridiem:0,omitCommas:0},STANDARD_DATE_PROP_SEVERITIES={timeZoneName:7,era:6,year:5,month:4,day:2,weekday:2,hour:1,minute:1,second:1},MERIDIEM_RE=/\s*([ap])\.?m\.?/i,COMMA_RE=/,/g,MULTI_SPACE_RE=/\s+/g,LTR_RE=/\u200e/g,UTC_RE=/UTC|GMT/,NativeFormatter=function(){function e(e){var t={},n={},r=0;for(var o in e)o in EXTENDED_SETTINGS_AND_SEVERITIES?(n[o]=e[o],r=Math.max(EXTENDED_SETTINGS_AND_SEVERITIES[o],r)):(t[o]=e[o],o in STANDARD_DATE_PROP_SEVERITIES&&(r=Math.max(STANDARD_DATE_PROP_SEVERITIES[o],r)));this.standardDateProps=t,this.extendedSettings=n,this.severity=r,this.buildFormattingFunc=memoize(buildFormattingFunc)}return e.prototype.format=function(e,t){return this.buildFormattingFunc(this.standardDateProps,this.extendedSettings,t)(e)},e.prototype.formatRange=function(e,t,n,r){var o=this.standardDateProps,i=this.extendedSettings,a=computeMarkerDiffSeverity(e.marker,t.marker,n.calendarSystem);if(!a)return this.format(e,n);var s=a;!(s>1)||"numeric"!==o.year&&"2-digit"!==o.year||"numeric"!==o.month&&"2-digit"!==o.month||"numeric"!==o.day&&"2-digit"!==o.day||(s=1);var l=this.format(e,n),u=this.format(t,n);if(l===u)return l;var c=buildFormattingFunc(computePartialFormattingOptions(o,s),i,n),d=c(e),p=c(t),f=findCommonInsertion(l,d,u,p),h=i.separator||r||n.defaultSeparator||"";return f?f.before+d+h+p+f.after:l+h+u},e.prototype.getLargestUnit=function(){switch(this.severity){case 7:case 6:case 5:return"year";case 4:return"month";case 3:return"week";case 2:return"day";default:return"time"}},e}();function buildFormattingFunc(e,t,n){var r=Object.keys(e).length;return 1===r&&"short"===e.timeZoneName?function(e){return formatTimeZoneOffset(e.timeZoneOffset)}:0===r&&t.week?function(e){return formatWeekNumber(n.computeWeekNumber(e.marker),n.weekText,n.weekTextLong,n.locale,t.week)}:buildNativeFormattingFunc(e,t,n)}function buildNativeFormattingFunc(e,t,n){e=__assign$1({},e),t=__assign$1({},t),sanitizeSettings(e,t),e.timeZone="UTC";var r,o=new Intl.DateTimeFormat(n.locale.codes,e);if(t.omitZeroMinute){var i=__assign$1({},e);delete i.minute,r=new Intl.DateTimeFormat(n.locale.codes,i)}return function(i){var a=i.marker;return postProcess((r&&!a.getUTCMinutes()?r:o).format(a),i,e,t,n)}}function sanitizeSettings(e,t){e.timeZoneName&&(e.hour||(e.hour="2-digit"),e.minute||(e.minute="2-digit")),"long"===e.timeZoneName&&(e.timeZoneName="short"),t.omitZeroMinute&&(e.second||e.millisecond)&&delete t.omitZeroMinute}function postProcess(e,t,n,r,o){return e=e.replace(LTR_RE,""),"short"===n.timeZoneName&&(e=injectTzoStr(e,"UTC"===o.timeZone||null==t.timeZoneOffset?"UTC":formatTimeZoneOffset(t.timeZoneOffset))),r.omitCommas&&(e=e.replace(COMMA_RE,"").trim()),r.omitZeroMinute&&(e=e.replace(":00","")),!1===r.meridiem?e=e.replace(MERIDIEM_RE,"").trim():"narrow"===r.meridiem?e=e.replace(MERIDIEM_RE,(function(e,t){return t.toLocaleLowerCase()})):"short"===r.meridiem?e=e.replace(MERIDIEM_RE,(function(e,t){return t.toLocaleLowerCase()+"m"})):"lowercase"===r.meridiem&&(e=e.replace(MERIDIEM_RE,(function(e){return e.toLocaleLowerCase()}))),e=(e=e.replace(MULTI_SPACE_RE," ")).trim()}function injectTzoStr(e,t){var n=!1;return e=e.replace(UTC_RE,(function(){return n=!0,t})),n||(e+=" "+t),e}function formatWeekNumber(e,t,n,r,o){var i=[];return"long"===o?i.push(n):"short"!==o&&"narrow"!==o||i.push(t),"long"!==o&&"short"!==o||i.push(" "),i.push(r.simpleNumberFormat.format(e)),"rtl"===r.options.direction&&i.reverse(),i.join("")}function computeMarkerDiffSeverity(e,t,n){return n.getMarkerYear(e)!==n.getMarkerYear(t)?5:n.getMarkerMonth(e)!==n.getMarkerMonth(t)?4:n.getMarkerDay(e)!==n.getMarkerDay(t)?2:timeAsMs(e)!==timeAsMs(t)?1:0}function computePartialFormattingOptions(e,t){var n={};for(var r in e)(!(r in STANDARD_DATE_PROP_SEVERITIES)||STANDARD_DATE_PROP_SEVERITIES[r]<=t)&&(n[r]=e[r]);return n}function findCommonInsertion(e,t,n,r){for(var o=0;o<e.length;){var i=e.indexOf(t,o);if(-1===i)break;var a=e.substr(0,i);o=i+t.length;for(var s=e.substr(o),l=0;l<n.length;){var u=n.indexOf(r,l);if(-1===u)break;var c=n.substr(0,u);l=u+r.length;var d=n.substr(l);if(a===c&&s===d)return{before:a,after:s}}}return null}function expandZonedMarker(e,t){var n=t.markerToArray(e.marker);return{marker:e.marker,timeZoneOffset:e.timeZoneOffset,array:n,year:n[0],month:n[1],day:n[2],hour:n[3],minute:n[4],second:n[5],millisecond:n[6]}}function createVerboseFormattingArg(e,t,n,r){var o=expandZonedMarker(e,n.calendarSystem);return{date:o,start:o,end:t?expandZonedMarker(t,n.calendarSystem):null,timeZone:n.timeZone,localeCodes:n.locale.codes,defaultSeparator:r||n.defaultSeparator}}var CmdFormatter=function(){function e(e){this.cmdStr=e}return e.prototype.format=function(e,t,n){return t.cmdFormatter(this.cmdStr,createVerboseFormattingArg(e,null,t,n))},e.prototype.formatRange=function(e,t,n,r){return n.cmdFormatter(this.cmdStr,createVerboseFormattingArg(e,t,n,r))},e}(),FuncFormatter=function(){function e(e){this.func=e}return e.prototype.format=function(e,t,n){return this.func(createVerboseFormattingArg(e,null,t,n))},e.prototype.formatRange=function(e,t,n,r){return this.func(createVerboseFormattingArg(e,t,n,r))},e}();function createFormatter(e){return"object"==typeof e&&e?new NativeFormatter(e):"string"==typeof e?new CmdFormatter(e):"function"==typeof e?new FuncFormatter(e):null}var BASE_OPTION_REFINERS={navLinkDayClick:identity,navLinkWeekClick:identity,duration:createDuration,bootstrapFontAwesome:identity,buttonIcons:identity,customButtons:identity,defaultAllDayEventDuration:createDuration,defaultTimedEventDuration:createDuration,nextDayThreshold:createDuration,scrollTime:createDuration,scrollTimeReset:Boolean,slotMinTime:createDuration,slotMaxTime:createDuration,dayPopoverFormat:createFormatter,slotDuration:createDuration,snapDuration:createDuration,headerToolbar:identity,footerToolbar:identity,defaultRangeSeparator:String,titleRangeSeparator:String,forceEventDuration:Boolean,dayHeaders:Boolean,dayHeaderFormat:createFormatter,dayHeaderClassNames:identity,dayHeaderContent:identity,dayHeaderDidMount:identity,dayHeaderWillUnmount:identity,dayCellClassNames:identity,dayCellContent:identity,dayCellDidMount:identity,dayCellWillUnmount:identity,initialView:String,aspectRatio:Number,weekends:Boolean,weekNumberCalculation:identity,weekNumbers:Boolean,weekNumberClassNames:identity,weekNumberContent:identity,weekNumberDidMount:identity,weekNumberWillUnmount:identity,editable:Boolean,viewClassNames:identity,viewDidMount:identity,viewWillUnmount:identity,nowIndicator:Boolean,nowIndicatorClassNames:identity,nowIndicatorContent:identity,nowIndicatorDidMount:identity,nowIndicatorWillUnmount:identity,showNonCurrentDates:Boolean,lazyFetching:Boolean,startParam:String,endParam:String,timeZoneParam:String,timeZone:String,locales:identity,locale:identity,themeSystem:String,dragRevertDuration:Number,dragScroll:Boolean,allDayMaintainDuration:Boolean,unselectAuto:Boolean,dropAccept:identity,eventOrder:parseFieldSpecs,eventOrderStrict:Boolean,handleWindowResize:Boolean,windowResizeDelay:Number,longPressDelay:Number,eventDragMinDistance:Number,expandRows:Boolean,height:identity,contentHeight:identity,direction:String,weekNumberFormat:createFormatter,eventResizableFromStart:Boolean,displayEventTime:Boolean,displayEventEnd:Boolean,weekText:String,weekTextLong:String,progressiveEventRendering:Boolean,businessHours:identity,initialDate:identity,now:identity,eventDataTransform:identity,stickyHeaderDates:identity,stickyFooterScrollbar:identity,viewHeight:identity,defaultAllDay:Boolean,eventSourceFailure:identity,eventSourceSuccess:identity,eventDisplay:String,eventStartEditable:Boolean,eventDurationEditable:Boolean,eventOverlap:identity,eventConstraint:identity,eventAllow:identity,eventBackgroundColor:String,eventBorderColor:String,eventTextColor:String,eventColor:String,eventClassNames:identity,eventContent:identity,eventDidMount:identity,eventWillUnmount:identity,selectConstraint:identity,selectOverlap:identity,selectAllow:identity,droppable:Boolean,unselectCancel:String,slotLabelFormat:identity,slotLaneClassNames:identity,slotLaneContent:identity,slotLaneDidMount:identity,slotLaneWillUnmount:identity,slotLabelClassNames:identity,slotLabelContent:identity,slotLabelDidMount:identity,slotLabelWillUnmount:identity,dayMaxEvents:identity,dayMaxEventRows:identity,dayMinWidth:Number,slotLabelInterval:createDuration,allDayText:String,allDayClassNames:identity,allDayContent:identity,allDayDidMount:identity,allDayWillUnmount:identity,slotMinWidth:Number,navLinks:Boolean,eventTimeFormat:createFormatter,rerenderDelay:Number,moreLinkText:identity,moreLinkHint:identity,selectMinDistance:Number,selectable:Boolean,selectLongPressDelay:Number,eventLongPressDelay:Number,selectMirror:Boolean,eventMaxStack:Number,eventMinHeight:Number,eventMinWidth:Number,eventShortHeight:Number,slotEventOverlap:Boolean,plugins:identity,firstDay:Number,dayCount:Number,dateAlignment:String,dateIncrement:createDuration,hiddenDays:identity,monthMode:Boolean,fixedWeekCount:Boolean,validRange:identity,visibleRange:identity,titleFormat:identity,eventInteractive:Boolean,noEventsText:String,viewHint:identity,navLinkHint:identity,closeHint:String,timeHint:String,eventHint:String,moreLinkClick:identity,moreLinkClassNames:identity,moreLinkContent:identity,moreLinkDidMount:identity,moreLinkWillUnmount:identity},BASE_OPTION_DEFAULTS={eventDisplay:"auto",defaultRangeSeparator:" - ",titleRangeSeparator:" – ",defaultTimedEventDuration:"01:00:00",defaultAllDayEventDuration:{day:1},forceEventDuration:!1,nextDayThreshold:"00:00:00",dayHeaders:!0,initialView:"",aspectRatio:1.35,headerToolbar:{start:"title",center:"",end:"today prev,next"},weekends:!0,weekNumbers:!1,weekNumberCalculation:"local",editable:!1,nowIndicator:!1,scrollTime:"06:00:00",scrollTimeReset:!0,slotMinTime:"00:00:00",slotMaxTime:"24:00:00",showNonCurrentDates:!0,lazyFetching:!0,startParam:"start",endParam:"end",timeZoneParam:"timeZone",timeZone:"local",locales:[],locale:"",themeSystem:"standard",dragRevertDuration:500,dragScroll:!0,allDayMaintainDuration:!1,unselectAuto:!0,dropAccept:"*",eventOrder:"start,-duration,allDay,title",dayPopoverFormat:{month:"long",day:"numeric",year:"numeric"},handleWindowResize:!0,windowResizeDelay:100,longPressDelay:1e3,eventDragMinDistance:5,expandRows:!1,navLinks:!1,selectable:!1,eventMinHeight:15,eventMinWidth:30,eventShortHeight:30},CALENDAR_LISTENER_REFINERS={datesSet:identity,eventsSet:identity,eventAdd:identity,eventChange:identity,eventRemove:identity,windowResize:identity,eventClick:identity,eventMouseEnter:identity,eventMouseLeave:identity,select:identity,unselect:identity,loading:identity,_unmount:identity,_beforeprint:identity,_afterprint:identity,_noEventDrop:identity,_noEventResize:identity,_resize:identity,_scrollRequest:identity},CALENDAR_OPTION_REFINERS={buttonText:identity,buttonHints:identity,views:identity,plugins:identity,initialEvents:identity,events:identity,eventSources:identity},COMPLEX_OPTION_COMPARATORS={headerToolbar:isMaybeObjectsEqual,footerToolbar:isMaybeObjectsEqual,buttonText:isMaybeObjectsEqual,buttonHints:isMaybeObjectsEqual,buttonIcons:isMaybeObjectsEqual,dateIncrement:isMaybeObjectsEqual};function isMaybeObjectsEqual(e,t){return"object"==typeof e&&"object"==typeof t&&e&&t?isPropsEqual(e,t):e===t}var VIEW_OPTION_REFINERS={type:String,component:identity,buttonText:String,buttonTextKey:String,dateProfileGeneratorClass:identity,usesMinMaxTime:Boolean,classNames:identity,content:identity,didMount:identity,willUnmount:identity};function mergeRawOptions(e){return mergeProps(e,COMPLEX_OPTION_COMPARATORS)}function refineProps(e,t){var n={},r={};for(var o in t)o in e&&(n[o]=t[o](e[o]));for(var o in e)o in t||(r[o]=e[o]);return{refined:n,extra:r}}function identity(e){return e}function parseEvents(e,t,n,r){for(var o=createEmptyEventStore(),i=buildEventRefiners(n),a=0,s=e;a<s.length;a++){var l=parseEvent(s[a],t,n,r,i);l&&eventTupleToStore(l,o)}return o}function eventTupleToStore(e,t){return void 0===t&&(t=createEmptyEventStore()),t.defs[e.def.defId]=e.def,e.instance&&(t.instances[e.instance.instanceId]=e.instance),t}function getRelevantEvents(e,t){var n=e.instances[t];if(n){var r=e.defs[n.defId],o=filterEventStoreDefs(e,(function(e){return isEventDefsGrouped(r,e)}));return o.defs[r.defId]=r,o.instances[n.instanceId]=n,o}return createEmptyEventStore()}function isEventDefsGrouped(e,t){return Boolean(e.groupId&&e.groupId===t.groupId)}function createEmptyEventStore(){return{defs:{},instances:{}}}function mergeEventStores(e,t){return{defs:__assign$1(__assign$1({},e.defs),t.defs),instances:__assign$1(__assign$1({},e.instances),t.instances)}}function filterEventStoreDefs(e,t){var n=filterHash(e.defs,t),r=filterHash(e.instances,(function(e){return n[e.defId]}));return{defs:n,instances:r}}function excludeSubEventStore(e,t){var n=e.defs,r=e.instances,o={},i={};for(var a in n)t.defs[a]||(o[a]=n[a]);for(var s in r)!t.instances[s]&&o[r[s].defId]&&(i[s]=r[s]);return{defs:o,instances:i}}function normalizeConstraint(e,t){return Array.isArray(e)?parseEvents(e,null,t,!0):"object"==typeof e&&e?parseEvents([e],null,t,!0):null!=e?String(e):null}function parseClassNames(e){return Array.isArray(e)?e:"string"==typeof e?e.split(/\s+/):[]}var EVENT_UI_REFINERS={display:String,editable:Boolean,startEditable:Boolean,durationEditable:Boolean,constraint:identity,overlap:identity,allow:identity,className:parseClassNames,classNames:parseClassNames,color:String,backgroundColor:String,borderColor:String,textColor:String},EMPTY_EVENT_UI={display:null,startEditable:null,durationEditable:null,constraints:[],overlap:null,allows:[],backgroundColor:"",borderColor:"",textColor:"",classNames:[]};function createEventUi(e,t){var n=normalizeConstraint(e.constraint,t);return{display:e.display||null,startEditable:null!=e.startEditable?e.startEditable:e.editable,durationEditable:null!=e.durationEditable?e.durationEditable:e.editable,constraints:null!=n?[n]:[],overlap:null!=e.overlap?e.overlap:null,allows:null!=e.allow?[e.allow]:[],backgroundColor:e.backgroundColor||e.color||"",borderColor:e.borderColor||e.color||"",textColor:e.textColor||"",classNames:(e.className||[]).concat(e.classNames||[])}}function combineEventUis(e){return e.reduce(combineTwoEventUis,EMPTY_EVENT_UI)}function combineTwoEventUis(e,t){return{display:null!=t.display?t.display:e.display,startEditable:null!=t.startEditable?t.startEditable:e.startEditable,durationEditable:null!=t.durationEditable?t.durationEditable:e.durationEditable,constraints:e.constraints.concat(t.constraints),overlap:"boolean"==typeof t.overlap?t.overlap:e.overlap,allows:e.allows.concat(t.allows),backgroundColor:t.backgroundColor||e.backgroundColor,borderColor:t.borderColor||e.borderColor,textColor:t.textColor||e.textColor,classNames:e.classNames.concat(t.classNames)}}var EVENT_NON_DATE_REFINERS={id:String,groupId:String,title:String,url:String,interactive:Boolean},EVENT_DATE_REFINERS={start:identity,end:identity,date:identity,allDay:Boolean},EVENT_REFINERS=__assign$1(__assign$1(__assign$1({},EVENT_NON_DATE_REFINERS),EVENT_DATE_REFINERS),{extendedProps:identity});function parseEvent(e,t,n,r,o){void 0===o&&(o=buildEventRefiners(n));var i=refineEventDef(e,n,o),a=i.refined,s=i.extra,l=computeIsDefaultAllDay(t,n),u=parseRecurring(a,l,n.dateEnv,n.pluginHooks.recurringTypes);if(u)return(c=parseEventDef(a,s,t?t.sourceId:"",u.allDay,Boolean(u.duration),n)).recurringDef={typeId:u.typeId,typeData:u.typeData,duration:u.duration},{def:c,instance:null};var c,d=parseSingle(a,l,n,r);return d?{def:c=parseEventDef(a,s,t?t.sourceId:"",d.allDay,d.hasEnd,n),instance:createEventInstance(c.defId,d.range,d.forcedStartTzo,d.forcedEndTzo)}:null}function refineEventDef(e,t,n){return void 0===n&&(n=buildEventRefiners(t)),refineProps(e,n)}function buildEventRefiners(e){return __assign$1(__assign$1(__assign$1({},EVENT_UI_REFINERS),EVENT_REFINERS),e.pluginHooks.eventRefiners)}function parseEventDef(e,t,n,r,o,i){for(var a={title:e.title||"",groupId:e.groupId||"",publicId:e.id||"",url:e.url||"",recurringDef:null,defId:guid(),sourceId:n,allDay:r,hasEnd:o,interactive:e.interactive,ui:createEventUi(e,i),extendedProps:__assign$1(__assign$1({},e.extendedProps||{}),t)},s=0,l=i.pluginHooks.eventDefMemberAdders;s<l.length;s++){var u=l[s];__assign$1(a,u(e))}return Object.freeze(a.ui.classNames),Object.freeze(a.extendedProps),a}function parseSingle(e,t,n,r){var o,i,a=e.allDay,s=null,l=!1,u=null,c=null!=e.start?e.start:e.date;if(o=n.dateEnv.createMarkerMeta(c))s=o.marker;else if(!r)return null;return null!=e.end&&(i=n.dateEnv.createMarkerMeta(e.end)),null==a&&(a=null!=t?t:(!o||o.isTimeUnspecified)&&(!i||i.isTimeUnspecified)),a&&s&&(s=startOfDay(s)),i&&(u=i.marker,a&&(u=startOfDay(u)),s&&u<=s&&(u=null)),u?l=!0:r||(l=n.options.forceEventDuration||!1,u=n.dateEnv.add(s,a?n.options.defaultAllDayEventDuration:n.options.defaultTimedEventDuration)),{allDay:a,hasEnd:l,range:{start:s,end:u},forcedStartTzo:o?o.forcedTzo:null,forcedEndTzo:i?i.forcedTzo:null}}function computeIsDefaultAllDay(e,t){var n=null;return e&&(n=e.defaultAllDay),null==n&&(n=t.options.defaultAllDay),n}function computeAlignedDayRange(e){var t=Math.floor(diffDays(e.start,e.end))||1,n=startOfDay(e.start);return{start:n,end:addDays(n,t)}}function computeVisibleDayRange(e,t){void 0===t&&(t=createDuration(0));var n=null,r=null;if(e.end){r=startOfDay(e.end);var o=e.end.valueOf()-r.valueOf();o&&o>=asRoughMs(t)&&(r=addDays(r,1))}return e.start&&(n=startOfDay(e.start),r&&r<=n&&(r=addDays(n,1))),{start:n,end:r}}function isMultiDayRange(e){var t=computeVisibleDayRange(e);return diffDays(t.start,t.end)>1}function diffDates(e,t,n,r){return"year"===r?createDuration(n.diffWholeYears(e,t),"year"):"month"===r?createDuration(n.diffWholeMonths(e,t),"month"):diffDayAndTime(e,t)}function parseRange(e,t){var n=null,r=null;return e.start&&(n=t.createMarker(e.start)),e.end&&(r=t.createMarker(e.end)),n||r?n&&r&&r<n?null:{start:n,end:r}:null}function invertRanges(e,t){var n,r,o=[],i=t.start;for(e.sort(compareRanges),n=0;n<e.length;n+=1)(r=e[n]).start>i&&o.push({start:i,end:r.start}),r.end>i&&(i=r.end);return i<t.end&&o.push({start:i,end:t.end}),o}function compareRanges(e,t){return e.start.valueOf()-t.start.valueOf()}function intersectRanges(e,t){var n=e.start,r=e.end,o=null;return null!==t.start&&(n=null===n?t.start:new Date(Math.max(n.valueOf(),t.start.valueOf()))),null!=t.end&&(r=null===r?t.end:new Date(Math.min(r.valueOf(),t.end.valueOf()))),(null===n||null===r||n<r)&&(o={start:n,end:r}),o}function rangesEqual(e,t){return(null===e.start?null:e.start.valueOf())===(null===t.start?null:t.start.valueOf())&&(null===e.end?null:e.end.valueOf())===(null===t.end?null:t.end.valueOf())}function rangesIntersect(e,t){return(null===e.end||null===t.start||e.end>t.start)&&(null===e.start||null===t.end||e.start<t.end)}function rangeContainsRange(e,t){return(null===e.start||null!==t.start&&t.start>=e.start)&&(null===e.end||null!==t.end&&t.end<=e.end)}function rangeContainsMarker(e,t){return(null===e.start||t>=e.start)&&(null===e.end||t<e.end)}function constrainMarkerToRange(e,t){return null!=t.start&&e<t.start?t.start:null!=t.end&&e>=t.end?new Date(t.end.valueOf()-1):e}function sliceEventStore(e,t,n,r){var o={},i={},a={},s=[],l=[],u=compileEventUis(e.defs,t);for(var c in e.defs){"inverse-background"===(f=u[(S=e.defs[c]).defId]).display&&(S.groupId?(o[S.groupId]=[],a[S.groupId]||(a[S.groupId]=S)):i[c]=[])}for(var d in e.instances){var p=e.instances[d],f=u[(S=e.defs[p.defId]).defId],h=p.range,g=!S.allDay&&r?computeVisibleDayRange(h,r):h,v=intersectRanges(g,n);v&&("inverse-background"===f.display?S.groupId?o[S.groupId].push(v):i[p.defId].push(v):"none"!==f.display&&("background"===f.display?s:l).push({def:S,ui:f,instance:p,range:v,isStart:g.start&&g.start.valueOf()===v.start.valueOf(),isEnd:g.end&&g.end.valueOf()===v.end.valueOf()}))}for(var m in o)for(var y=0,E=invertRanges(o[m],n);y<E.length;y++){var S,D=E[y];f=u[(S=a[m]).defId];s.push({def:S,ui:f,instance:null,range:D,isStart:!1,isEnd:!1})}for(var c in i)for(var T=0,b=invertRanges(i[c],n);T<b.length;T++){D=b[T];s.push({def:e.defs[c],ui:u[c],instance:null,range:D,isStart:!1,isEnd:!1})}return{bg:s,fg:l}}function hasBgRendering(e){return"background"===e.ui.display||"inverse-background"===e.ui.display}function setElSeg(e,t){e.fcSeg=t}function getElSeg(e){return e.fcSeg||e.parentNode.fcSeg||null}function compileEventUis(e,t){return mapHash(e,(function(e){return compileEventUi(e,t)}))}function compileEventUi(e,t){var n=[];return t[""]&&n.push(t[""]),t[e.defId]&&n.push(t[e.defId]),n.push(e.ui),combineEventUis(n)}function sortEventSegs(e,t){var n=e.map(buildSegCompareObj);return n.sort((function(e,n){return compareByFieldSpecs(e,n,t)})),n.map((function(e){return e._seg}))}function buildSegCompareObj(e){var t=e.eventRange,n=t.def,r=t.instance?t.instance.range:t.range,o=r.start?r.start.valueOf():0,i=r.end?r.end.valueOf():0;return __assign$1(__assign$1(__assign$1({},n.extendedProps),n),{id:n.publicId,start:o,end:i,duration:i-o,allDay:Number(n.allDay),_seg:e})}function computeSegDraggable(e,t){for(var n=t.pluginHooks.isDraggableTransformers,r=e.eventRange,o=r.def,i=r.ui,a=i.startEditable,s=0,l=n;s<l.length;s++){a=(0,l[s])(a,o,i,t)}return a}function computeSegStartResizable(e,t){return e.isStart&&e.eventRange.ui.durationEditable&&t.options.eventResizableFromStart}function computeSegEndResizable(e,t){return e.isEnd&&e.eventRange.ui.durationEditable}function buildSegTimeText(e,t,n,r,o,i,a){var s=n.dateEnv,l=n.options,u=l.displayEventTime,c=l.displayEventEnd,d=e.eventRange.def,p=e.eventRange.instance;null==u&&(u=!1!==r),null==c&&(c=!1!==o);var f=p.range.start,h=p.range.end,g=i||e.start||e.eventRange.range.start,v=a||e.end||e.eventRange.range.end,m=startOfDay(f).valueOf()===startOfDay(g).valueOf(),y=startOfDay(addMs(h,-1)).valueOf()===startOfDay(addMs(v,-1)).valueOf();return u&&!d.allDay&&(m||y)?(g=m?f:g,v=y?h:v,c&&d.hasEnd?s.formatRange(g,v,t,{forcedStartTzo:i?null:p.forcedStartTzo,forcedEndTzo:a?null:p.forcedEndTzo}):s.format(g,t,{forcedTzo:i?null:p.forcedStartTzo})):""}function getSegMeta(e,t,n){var r=e.eventRange.range;return{isPast:r.end<(n||t.start),isFuture:r.start>=(n||t.end),isToday:t&&rangeContainsMarker(t,r.start)}}function getEventClassNames(e){var t=["fc-event"];return e.isMirror&&t.push("fc-event-mirror"),e.isDraggable&&t.push("fc-event-draggable"),(e.isStartResizable||e.isEndResizable)&&t.push("fc-event-resizable"),e.isDragging&&t.push("fc-event-dragging"),e.isResizing&&t.push("fc-event-resizing"),e.isSelected&&t.push("fc-event-selected"),e.isStart&&t.push("fc-event-start"),e.isEnd&&t.push("fc-event-end"),e.isPast&&t.push("fc-event-past"),e.isToday&&t.push("fc-event-today"),e.isFuture&&t.push("fc-event-future"),t}function buildEventRangeKey(e){return e.instance?e.instance.instanceId:e.def.defId+":"+e.range.start.toISOString()}function getSegAnchorAttrs(e,t){var n=e.eventRange,r=n.def,o=n.instance,i=r.url;if(i)return{href:i};var a=t.emitter,s=t.options.eventInteractive;return null==s&&null==(s=r.interactive)&&(s=Boolean(a.hasHandlers("eventClick"))),s?createAriaKeyboardAttrs((function(e){a.trigger("eventClick",{el:e.target,event:new EventApi(t,r,o),jsEvent:e,view:t.viewApi})})):{}}var STANDARD_PROPS={start:identity,end:identity,allDay:Boolean};function parseDateSpan(e,t,n){var r=parseOpenDateSpan(e,t),o=r.range;if(!o.start)return null;if(!o.end){if(null==n)return null;o.end=t.add(o.start,n)}return r}function parseOpenDateSpan(e,t){var n=refineProps(e,STANDARD_PROPS),r=n.refined,o=n.extra,i=r.start?t.createMarkerMeta(r.start):null,a=r.end?t.createMarkerMeta(r.end):null,s=r.allDay;return null==s&&(s=i&&i.isTimeUnspecified&&(!a||a.isTimeUnspecified)),__assign$1({range:{start:i?i.marker:null,end:a?a.marker:null},allDay:s},o)}function isDateSpansEqual(e,t){return rangesEqual(e.range,t.range)&&e.allDay===t.allDay&&isSpanPropsEqual(e,t)}function isSpanPropsEqual(e,t){for(var n in t)if("range"!==n&&"allDay"!==n&&e[n]!==t[n])return!1;for(var n in e)if(!(n in t))return!1;return!0}function buildDateSpanApi(e,t){return __assign$1(__assign$1({},buildRangeApi(e.range,t,e.allDay)),{allDay:e.allDay})}function buildRangeApiWithTimeZone(e,t,n){return __assign$1(__assign$1({},buildRangeApi(e,t,n)),{timeZone:t.timeZone})}function buildRangeApi(e,t,n){return{start:t.toDate(e.start),end:t.toDate(e.end),startStr:t.formatIso(e.start,{omitTime:n}),endStr:t.formatIso(e.end,{omitTime:n})}}function fabricateEventRange(e,t,n){var r=refineEventDef({editable:!1},n),o=parseEventDef(r.refined,r.extra,"",e.allDay,!0,n);return{def:o,ui:compileEventUi(o,t),instance:createEventInstance(o.defId,e.range),range:e.range,isStart:!0,isEnd:!0}}function triggerDateSelect(e,t,n){n.emitter.trigger("select",__assign$1(__assign$1({},buildDateSpanApiWithContext(e,n)),{jsEvent:t?t.origEvent:null,view:n.viewApi||n.calendarApi.view}))}function triggerDateUnselect(e,t){t.emitter.trigger("unselect",{jsEvent:e?e.origEvent:null,view:t.viewApi||t.calendarApi.view})}function buildDateSpanApiWithContext(e,t){for(var n={},r=0,o=t.pluginHooks.dateSpanTransforms;r<o.length;r++){var i=o[r];__assign$1(n,i(e,t))}return __assign$1(n,buildDateSpanApi(e,t.dateEnv)),n}function getDefaultEventEnd(e,t,n){var r=n.dateEnv,o=n.options,i=t;return e?(i=startOfDay(i),i=r.add(i,o.defaultAllDayEventDuration)):i=r.add(i,o.defaultTimedEventDuration),i}function applyMutationToEventStore(e,t,n,r){var o=compileEventUis(e.defs,t),i=createEmptyEventStore();for(var a in e.defs){var s=e.defs[a];i.defs[a]=applyMutationToEventDef(s,o[a],n,r)}for(var l in e.instances){var u=e.instances[l];s=i.defs[u.defId];i.instances[l]=applyMutationToEventInstance(u,s,o[u.defId],n,r)}return i}function applyMutationToEventDef(e,t,n,r){var o=n.standardProps||{};null==o.hasEnd&&t.durationEditable&&(n.startDelta||n.endDelta)&&(o.hasEnd=!0);var i=__assign$1(__assign$1(__assign$1({},e),o),{ui:__assign$1(__assign$1({},e.ui),o.ui)});n.extendedProps&&(i.extendedProps=__assign$1(__assign$1({},i.extendedProps),n.extendedProps));for(var a=0,s=r.pluginHooks.eventDefMutationAppliers;a<s.length;a++){(0,s[a])(i,n,r)}return!i.hasEnd&&r.options.forceEventDuration&&(i.hasEnd=!0),i}function applyMutationToEventInstance(e,t,n,r,o){var i=o.dateEnv,a=r.standardProps&&!0===r.standardProps.allDay,s=r.standardProps&&!1===r.standardProps.hasEnd,l=__assign$1({},e);return a&&(l.range=computeAlignedDayRange(l.range)),r.datesDelta&&n.startEditable&&(l.range={start:i.add(l.range.start,r.datesDelta),end:i.add(l.range.end,r.datesDelta)}),r.startDelta&&n.durationEditable&&(l.range={start:i.add(l.range.start,r.startDelta),end:l.range.end}),r.endDelta&&n.durationEditable&&(l.range={start:l.range.start,end:i.add(l.range.end,r.endDelta)}),s&&(l.range={start:l.range.start,end:getDefaultEventEnd(t.allDay,l.range.start,o)}),t.allDay&&(l.range={start:startOfDay(l.range.start),end:startOfDay(l.range.end)}),l.range.end<l.range.start&&(l.range.end=getDefaultEventEnd(t.allDay,l.range.start,o)),l}var ViewApi=function(){function e(e,t,n){this.type=e,this.getCurrentData=t,this.dateEnv=n}return Object.defineProperty(e.prototype,"calendar",{get:function(){return this.getCurrentData().calendarApi},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"title",{get:function(){return this.getCurrentData().viewTitle},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeStart",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.start)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeEnd",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.end)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentStart",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.start)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentEnd",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.end)},enumerable:!1,configurable:!0}),e.prototype.getOption=function(e){return this.getCurrentData().options[e]},e}(),EVENT_SOURCE_REFINERS={id:String,defaultAllDay:Boolean,url:String,format:String,events:identity,eventDataTransform:identity,success:identity,failure:identity};function parseEventSource(e,t,n){var r;if(void 0===n&&(n=buildEventSourceRefiners(t)),"string"==typeof e?r={url:e}:"function"==typeof e||Array.isArray(e)?r={events:e}:"object"==typeof e&&e&&(r=e),r){var o=refineProps(r,n),i=o.refined,a=o.extra,s=buildEventSourceMeta(i,t);if(s)return{_raw:e,isFetching:!1,latestFetchId:"",fetchRange:null,defaultAllDay:i.defaultAllDay,eventDataTransform:i.eventDataTransform,success:i.success,failure:i.failure,publicId:i.id||"",sourceId:guid(),sourceDefId:s.sourceDefId,meta:s.meta,ui:createEventUi(i,t),extendedProps:a}}return null}function buildEventSourceRefiners(e){return __assign$1(__assign$1(__assign$1({},EVENT_UI_REFINERS),EVENT_SOURCE_REFINERS),e.pluginHooks.eventSourceRefiners)}function buildEventSourceMeta(e,t){for(var n=t.pluginHooks.eventSourceDefs,r=n.length-1;r>=0;r-=1){var o=n[r].parseMeta(e);if(o)return{sourceDefId:r,meta:o}}return null}function reduceCurrentDate(e,t){return"CHANGE_DATE"===t.type?t.dateMarker:e}function getInitialDate(e,t){var n=e.initialDate;return null!=n?t.createMarker(n):getNow(e.now,t)}function getNow(e,t){return"function"==typeof e&&(e=e()),null==e?t.createNowMarker():t.createMarker(e)}var CalendarApi=function(){function e(){}return e.prototype.getCurrentData=function(){return this.currentDataManager.getCurrentData()},e.prototype.dispatch=function(e){return this.currentDataManager.dispatch(e)},Object.defineProperty(e.prototype,"view",{get:function(){return this.getCurrentData().viewApi},enumerable:!1,configurable:!0}),e.prototype.batchRendering=function(e){e()},e.prototype.updateSize=function(){this.trigger("_resize",!0)},e.prototype.setOption=function(e,t){this.dispatch({type:"SET_OPTION",optionName:e,rawOptionValue:t})},e.prototype.getOption=function(e){return this.currentDataManager.currentCalendarOptionsInput[e]},e.prototype.getAvailableLocaleCodes=function(){return Object.keys(this.getCurrentData().availableRawLocales)},e.prototype.on=function(e,t){var n=this.currentDataManager;n.currentCalendarOptionsRefiners[e]?n.emitter.on(e,t):console.warn("Unknown listener name '"+e+"'")},e.prototype.off=function(e,t){this.currentDataManager.emitter.off(e,t)},e.prototype.trigger=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];(t=this.currentDataManager.emitter).trigger.apply(t,__spreadArray([e],n))},e.prototype.changeView=function(e,t){var n=this;this.batchRendering((function(){if(n.unselect(),t)if(t.start&&t.end)n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e}),n.dispatch({type:"SET_OPTION",optionName:"visibleRange",rawOptionValue:t});else{var r=n.getCurrentData().dateEnv;n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e,dateMarker:r.createMarker(t)})}else n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e})}))},e.prototype.zoomTo=function(e,t){var n;t=t||"day",n=this.getCurrentData().viewSpecs[t]||this.getUnitViewSpec(t),this.unselect(),n?this.dispatch({type:"CHANGE_VIEW_TYPE",viewType:n.type,dateMarker:e}):this.dispatch({type:"CHANGE_DATE",dateMarker:e})},e.prototype.getUnitViewSpec=function(e){var t,n,r=this.getCurrentData(),o=r.viewSpecs,i=r.toolbarConfig,a=[].concat(i.header?i.header.viewsWithButtons:[],i.footer?i.footer.viewsWithButtons:[]);for(var s in o)a.push(s);for(t=0;t<a.length;t+=1)if((n=o[a[t]])&&n.singleUnit===e)return n;return null},e.prototype.prev=function(){this.unselect(),this.dispatch({type:"PREV"})},e.prototype.next=function(){this.unselect(),this.dispatch({type:"NEXT"})},e.prototype.prevYear=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:e.dateEnv.addYears(e.currentDate,-1)})},e.prototype.nextYear=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:e.dateEnv.addYears(e.currentDate,1)})},e.prototype.today=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:getNow(e.calendarOptions.now,e.dateEnv)})},e.prototype.gotoDate=function(e){var t=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:t.dateEnv.createMarker(e)})},e.prototype.incrementDate=function(e){var t=this.getCurrentData(),n=createDuration(e);n&&(this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:t.dateEnv.add(t.currentDate,n)}))},e.prototype.getDate=function(){var e=this.getCurrentData();return e.dateEnv.toDate(e.currentDate)},e.prototype.formatDate=function(e,t){var n=this.getCurrentData().dateEnv;return n.format(n.createMarker(e),createFormatter(t))},e.prototype.formatRange=function(e,t,n){var r=this.getCurrentData().dateEnv;return r.formatRange(r.createMarker(e),r.createMarker(t),createFormatter(n),n)},e.prototype.formatIso=function(e,t){var n=this.getCurrentData().dateEnv;return n.formatIso(n.createMarker(e),{omitTime:t})},e.prototype.select=function(e,t){var n;n=null==t?null!=e.start?e:{start:e,end:null}:{start:e,end:t};var r=this.getCurrentData(),o=parseDateSpan(n,r.dateEnv,createDuration({days:1}));o&&(this.dispatch({type:"SELECT_DATES",selection:o}),triggerDateSelect(o,null,r))},e.prototype.unselect=function(e){var t=this.getCurrentData();t.dateSelection&&(this.dispatch({type:"UNSELECT_DATES"}),triggerDateUnselect(e,t))},e.prototype.addEvent=function(e,t){if(e instanceof EventApi){var n=e._def,r=e._instance;return this.getCurrentData().eventStore.defs[n.defId]||(this.dispatch({type:"ADD_EVENTS",eventStore:eventTupleToStore({def:n,instance:r})}),this.triggerEventAdd(e)),e}var o,i=this.getCurrentData();if(t instanceof EventSourceApi)o=t.internalEventSource;else if("boolean"==typeof t)t&&(o=hashValuesToArray(i.eventSources)[0]);else if(null!=t){var a=this.getEventSourceById(t);if(!a)return console.warn('Could not find an event source with ID "'+t+'"'),null;o=a.internalEventSource}var s=parseEvent(e,o,i,!1);if(s){var l=new EventApi(i,s.def,s.def.recurringDef?null:s.instance);return this.dispatch({type:"ADD_EVENTS",eventStore:eventTupleToStore(s)}),this.triggerEventAdd(l),l}return null},e.prototype.triggerEventAdd=function(e){var t=this;this.getCurrentData().emitter.trigger("eventAdd",{event:e,relatedEvents:[],revert:function(){t.dispatch({type:"REMOVE_EVENTS",eventStore:eventApiToStore(e)})}})},e.prototype.getEventById=function(e){var t=this.getCurrentData(),n=t.eventStore,r=n.defs,o=n.instances;for(var i in e=String(e),r){var a=r[i];if(a.publicId===e){if(a.recurringDef)return new EventApi(t,a,null);for(var s in o){var l=o[s];if(l.defId===a.defId)return new EventApi(t,a,l)}}}return null},e.prototype.getEvents=function(){var e=this.getCurrentData();return buildEventApis(e.eventStore,e)},e.prototype.removeAllEvents=function(){this.dispatch({type:"REMOVE_ALL_EVENTS"})},e.prototype.getEventSources=function(){var e=this.getCurrentData(),t=e.eventSources,n=[];for(var r in t)n.push(new EventSourceApi(e,t[r]));return n},e.prototype.getEventSourceById=function(e){var t=this.getCurrentData(),n=t.eventSources;for(var r in e=String(e),n)if(n[r].publicId===e)return new EventSourceApi(t,n[r]);return null},e.prototype.addEventSource=function(e){var t=this.getCurrentData();if(e instanceof EventSourceApi)return t.eventSources[e.internalEventSource.sourceId]||this.dispatch({type:"ADD_EVENT_SOURCES",sources:[e.internalEventSource]}),e;var n=parseEventSource(e,t);return n?(this.dispatch({type:"ADD_EVENT_SOURCES",sources:[n]}),new EventSourceApi(t,n)):null},e.prototype.removeAllEventSources=function(){this.dispatch({type:"REMOVE_ALL_EVENT_SOURCES"})},e.prototype.refetchEvents=function(){this.dispatch({type:"FETCH_EVENT_SOURCES",isRefetch:!0})},e.prototype.scrollToTime=function(e){var t=createDuration(e);t&&this.trigger("_scrollRequest",{time:t})},e}(),EventApi=function(){function e(e,t,n){this._context=e,this._def=t,this._instance=n||null}return e.prototype.setProp=function(e,t){var n,r;if(e in EVENT_DATE_REFINERS)console.warn("Could not set date-related prop 'name'. Use one of the date-related methods instead.");else if("id"===e)t=EVENT_NON_DATE_REFINERS[e](t),this.mutate({standardProps:{publicId:t}});else if(e in EVENT_NON_DATE_REFINERS)t=EVENT_NON_DATE_REFINERS[e](t),this.mutate({standardProps:(n={},n[e]=t,n)});else if(e in EVENT_UI_REFINERS){var o=EVENT_UI_REFINERS[e](t);"color"===e?o={backgroundColor:t,borderColor:t}:"editable"===e?o={startEditable:t,durationEditable:t}:((r={})[e]=t,o=r),this.mutate({standardProps:{ui:o}})}else console.warn("Could not set prop '"+e+"'. Use setExtendedProp instead.")},e.prototype.setExtendedProp=function(e,t){var n;this.mutate({extendedProps:(n={},n[e]=t,n)})},e.prototype.setStart=function(e,t){void 0===t&&(t={});var n=this._context.dateEnv,r=n.createMarker(e);if(r&&this._instance){var o=diffDates(this._instance.range.start,r,n,t.granularity);t.maintainDuration?this.mutate({datesDelta:o}):this.mutate({startDelta:o})}},e.prototype.setEnd=function(e,t){void 0===t&&(t={});var n,r=this._context.dateEnv;if((null==e||(n=r.createMarker(e)))&&this._instance)if(n){var o=diffDates(this._instance.range.end,n,r,t.granularity);this.mutate({endDelta:o})}else this.mutate({standardProps:{hasEnd:!1}})},e.prototype.setDates=function(e,t,n){void 0===n&&(n={});var r,o=this._context.dateEnv,i={allDay:n.allDay},a=o.createMarker(e);if(a&&(null==t||(r=o.createMarker(t)))&&this._instance){var s=this._instance.range;!0===n.allDay&&(s=computeAlignedDayRange(s));var l=diffDates(s.start,a,o,n.granularity);if(r){var u=diffDates(s.end,r,o,n.granularity);durationsEqual(l,u)?this.mutate({datesDelta:l,standardProps:i}):this.mutate({startDelta:l,endDelta:u,standardProps:i})}else i.hasEnd=!1,this.mutate({datesDelta:l,standardProps:i})}},e.prototype.moveStart=function(e){var t=createDuration(e);t&&this.mutate({startDelta:t})},e.prototype.moveEnd=function(e){var t=createDuration(e);t&&this.mutate({endDelta:t})},e.prototype.moveDates=function(e){var t=createDuration(e);t&&this.mutate({datesDelta:t})},e.prototype.setAllDay=function(e,t){void 0===t&&(t={});var n={allDay:e},r=t.maintainDuration;null==r&&(r=this._context.options.allDayMaintainDuration),this._def.allDay!==e&&(n.hasEnd=r),this.mutate({standardProps:n})},e.prototype.formatRange=function(e){var t=this._context.dateEnv,n=this._instance,r=createFormatter(e);return this._def.hasEnd?t.formatRange(n.range.start,n.range.end,r,{forcedStartTzo:n.forcedStartTzo,forcedEndTzo:n.forcedEndTzo}):t.format(n.range.start,r,{forcedTzo:n.forcedStartTzo})},e.prototype.mutate=function(t){var n=this._instance;if(n){var r=this._def,o=this._context,i=o.getCurrentData().eventStore,a=getRelevantEvents(i,n.instanceId);a=applyMutationToEventStore(a,{"":{display:"",startEditable:!0,durationEditable:!0,constraints:[],overlap:null,allows:[],backgroundColor:"",borderColor:"",textColor:"",classNames:[]}},t,o);var s=new e(o,r,n);this._def=a.defs[r.defId],this._instance=a.instances[n.instanceId],o.dispatch({type:"MERGE_EVENTS",eventStore:a}),o.emitter.trigger("eventChange",{oldEvent:s,event:this,relatedEvents:buildEventApis(a,o,n),revert:function(){o.dispatch({type:"RESET_EVENTS",eventStore:i})}})}},e.prototype.remove=function(){var e=this._context,t=eventApiToStore(this);e.dispatch({type:"REMOVE_EVENTS",eventStore:t}),e.emitter.trigger("eventRemove",{event:this,relatedEvents:[],revert:function(){e.dispatch({type:"MERGE_EVENTS",eventStore:t})}})},Object.defineProperty(e.prototype,"source",{get:function(){var e=this._def.sourceId;return e?new EventSourceApi(this._context,this._context.getCurrentData().eventSources[e]):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"start",{get:function(){return this._instance?this._context.dateEnv.toDate(this._instance.range.start):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"end",{get:function(){return this._instance&&this._def.hasEnd?this._context.dateEnv.toDate(this._instance.range.end):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"startStr",{get:function(){var e=this._instance;return e?this._context.dateEnv.formatIso(e.range.start,{omitTime:this._def.allDay,forcedTzo:e.forcedStartTzo}):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"endStr",{get:function(){var e=this._instance;return e&&this._def.hasEnd?this._context.dateEnv.formatIso(e.range.end,{omitTime:this._def.allDay,forcedTzo:e.forcedEndTzo}):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this._def.publicId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"groupId",{get:function(){return this._def.groupId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"allDay",{get:function(){return this._def.allDay},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"title",{get:function(){return this._def.title},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._def.url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"display",{get:function(){return this._def.ui.display||"auto"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"startEditable",{get:function(){return this._def.ui.startEditable},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"durationEditable",{get:function(){return this._def.ui.durationEditable},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"constraint",{get:function(){return this._def.ui.constraints[0]||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"overlap",{get:function(){return this._def.ui.overlap},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"allow",{get:function(){return this._def.ui.allows[0]||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"backgroundColor",{get:function(){return this._def.ui.backgroundColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"borderColor",{get:function(){return this._def.ui.borderColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textColor",{get:function(){return this._def.ui.textColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classNames",{get:function(){return this._def.ui.classNames},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"extendedProps",{get:function(){return this._def.extendedProps},enumerable:!1,configurable:!0}),e.prototype.toPlainObject=function(e){void 0===e&&(e={});var t=this._def,n=t.ui,r=this.startStr,o=this.endStr,i={};return t.title&&(i.title=t.title),r&&(i.start=r),o&&(i.end=o),t.publicId&&(i.id=t.publicId),t.groupId&&(i.groupId=t.groupId),t.url&&(i.url=t.url),n.display&&"auto"!==n.display&&(i.display=n.display),e.collapseColor&&n.backgroundColor&&n.backgroundColor===n.borderColor?i.color=n.backgroundColor:(n.backgroundColor&&(i.backgroundColor=n.backgroundColor),n.borderColor&&(i.borderColor=n.borderColor)),n.textColor&&(i.textColor=n.textColor),n.classNames.length&&(i.classNames=n.classNames),Object.keys(t.extendedProps).length&&(e.collapseExtendedProps?__assign$1(i,t.extendedProps):i.extendedProps=t.extendedProps),i},e.prototype.toJSON=function(){return this.toPlainObject()},e}();function eventApiToStore(e){var t,n,r=e._def,o=e._instance;return{defs:(t={},t[r.defId]=r,t),instances:o?(n={},n[o.instanceId]=o,n):{}}}function buildEventApis(e,t,n){var r=e.defs,o=e.instances,i=[],a=n?n.instanceId:"";for(var s in o){var l=o[s],u=r[l.defId];l.instanceId!==a&&i.push(new EventApi(t,u,l))}return i}var calendarSystemClassMap={};function registerCalendarSystem(e,t){calendarSystemClassMap[e]=t}function createCalendarSystem(e){return new calendarSystemClassMap[e]}var GregorianCalendarSystem=function(){function e(){}return e.prototype.getMarkerYear=function(e){return e.getUTCFullYear()},e.prototype.getMarkerMonth=function(e){return e.getUTCMonth()},e.prototype.getMarkerDay=function(e){return e.getUTCDate()},e.prototype.arrayToMarker=function(e){return arrayToUtcDate(e)},e.prototype.markerToArray=function(e){return dateToUtcArray(e)},e}();registerCalendarSystem("gregory",GregorianCalendarSystem);var ISO_RE=/^\s*(\d{4})(-?(\d{2})(-?(\d{2})([T ](\d{2}):?(\d{2})(:?(\d{2})(\.(\d+))?)?(Z|(([-+])(\d{2})(:?(\d{2}))?))?)?)?)?$/;function parse(e){var t=ISO_RE.exec(e);if(t){var n=new Date(Date.UTC(Number(t[1]),t[3]?Number(t[3])-1:0,Number(t[5]||1),Number(t[7]||0),Number(t[8]||0),Number(t[10]||0),t[12]?1e3*Number("0."+t[12]):0));if(isValidDate(n)){var r=null;return t[13]&&(r=("-"===t[15]?-1:1)*(60*Number(t[16]||0)+Number(t[18]||0))),{marker:n,isTimeUnspecified:!t[6],timeZoneOffset:r}}}return null}var DateEnv=function(){function e(e){var t=this.timeZone=e.timeZone,n="local"!==t&&"UTC"!==t;e.namedTimeZoneImpl&&n&&(this.namedTimeZoneImpl=new e.namedTimeZoneImpl(t)),this.canComputeOffset=Boolean(!n||this.namedTimeZoneImpl),this.calendarSystem=createCalendarSystem(e.calendarSystem),this.locale=e.locale,this.weekDow=e.locale.week.dow,this.weekDoy=e.locale.week.doy,"ISO"===e.weekNumberCalculation&&(this.weekDow=1,this.weekDoy=4),"number"==typeof e.firstDay&&(this.weekDow=e.firstDay),"function"==typeof e.weekNumberCalculation&&(this.weekNumberFunc=e.weekNumberCalculation),this.weekText=null!=e.weekText?e.weekText:e.locale.options.weekText,this.weekTextLong=(null!=e.weekTextLong?e.weekTextLong:e.locale.options.weekTextLong)||this.weekText,this.cmdFormatter=e.cmdFormatter,this.defaultSeparator=e.defaultSeparator}return e.prototype.createMarker=function(e){var t=this.createMarkerMeta(e);return null===t?null:t.marker},e.prototype.createNowMarker=function(){return this.canComputeOffset?this.timestampToMarker((new Date).valueOf()):arrayToUtcDate(dateToLocalArray(new Date))},e.prototype.createMarkerMeta=function(e){if("string"==typeof e)return this.parse(e);var t=null;return"number"==typeof e?t=this.timestampToMarker(e):e instanceof Date?(e=e.valueOf(),isNaN(e)||(t=this.timestampToMarker(e))):Array.isArray(e)&&(t=arrayToUtcDate(e)),null!==t&&isValidDate(t)?{marker:t,isTimeUnspecified:!1,forcedTzo:null}:null},e.prototype.parse=function(e){var t=parse(e);if(null===t)return null;var n=t.marker,r=null;return null!==t.timeZoneOffset&&(this.canComputeOffset?n=this.timestampToMarker(n.valueOf()-60*t.timeZoneOffset*1e3):r=t.timeZoneOffset),{marker:n,isTimeUnspecified:t.isTimeUnspecified,forcedTzo:r}},e.prototype.getYear=function(e){return this.calendarSystem.getMarkerYear(e)},e.prototype.getMonth=function(e){return this.calendarSystem.getMarkerMonth(e)},e.prototype.add=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]+=t.years,n[1]+=t.months,n[2]+=t.days,n[6]+=t.milliseconds,this.calendarSystem.arrayToMarker(n)},e.prototype.subtract=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]-=t.years,n[1]-=t.months,n[2]-=t.days,n[6]-=t.milliseconds,this.calendarSystem.arrayToMarker(n)},e.prototype.addYears=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]+=t,this.calendarSystem.arrayToMarker(n)},e.prototype.addMonths=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[1]+=t,this.calendarSystem.arrayToMarker(n)},e.prototype.diffWholeYears=function(e,t){var n=this.calendarSystem;return timeAsMs(e)===timeAsMs(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)&&n.getMarkerMonth(e)===n.getMarkerMonth(t)?n.getMarkerYear(t)-n.getMarkerYear(e):null},e.prototype.diffWholeMonths=function(e,t){var n=this.calendarSystem;return timeAsMs(e)===timeAsMs(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)?n.getMarkerMonth(t)-n.getMarkerMonth(e)+12*(n.getMarkerYear(t)-n.getMarkerYear(e)):null},e.prototype.greatestWholeUnit=function(e,t){var n=this.diffWholeYears(e,t);return null!==n?{unit:"year",value:n}:null!==(n=this.diffWholeMonths(e,t))?{unit:"month",value:n}:null!==(n=diffWholeWeeks(e,t))?{unit:"week",value:n}:null!==(n=diffWholeDays(e,t))?{unit:"day",value:n}:isInt(n=diffHours(e,t))?{unit:"hour",value:n}:isInt(n=diffMinutes(e,t))?{unit:"minute",value:n}:isInt(n=diffSeconds(e,t))?{unit:"second",value:n}:{unit:"millisecond",value:t.valueOf()-e.valueOf()}},e.prototype.countDurationsBetween=function(e,t,n){var r;return n.years&&null!==(r=this.diffWholeYears(e,t))?r/asRoughYears(n):n.months&&null!==(r=this.diffWholeMonths(e,t))?r/asRoughMonths(n):n.days&&null!==(r=diffWholeDays(e,t))?r/asRoughDays(n):(t.valueOf()-e.valueOf())/asRoughMs(n)},e.prototype.startOf=function(e,t){return"year"===t?this.startOfYear(e):"month"===t?this.startOfMonth(e):"week"===t?this.startOfWeek(e):"day"===t?startOfDay(e):"hour"===t?startOfHour(e):"minute"===t?startOfMinute(e):"second"===t?startOfSecond(e):null},e.prototype.startOfYear=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e)])},e.prototype.startOfMonth=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e)])},e.prototype.startOfWeek=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e),e.getUTCDate()-(e.getUTCDay()-this.weekDow+7)%7])},e.prototype.computeWeekNumber=function(e){return this.weekNumberFunc?this.weekNumberFunc(this.toDate(e)):weekOfYear(e,this.weekDow,this.weekDoy)},e.prototype.format=function(e,t,n){return void 0===n&&(n={}),t.format({marker:e,timeZoneOffset:null!=n.forcedTzo?n.forcedTzo:this.offsetForMarker(e)},this)},e.prototype.formatRange=function(e,t,n,r){return void 0===r&&(r={}),r.isEndExclusive&&(t=addMs(t,-1)),n.formatRange({marker:e,timeZoneOffset:null!=r.forcedStartTzo?r.forcedStartTzo:this.offsetForMarker(e)},{marker:t,timeZoneOffset:null!=r.forcedEndTzo?r.forcedEndTzo:this.offsetForMarker(t)},this,r.defaultSeparator)},e.prototype.formatIso=function(e,t){void 0===t&&(t={});var n=null;return t.omitTimeZoneOffset||(n=null!=t.forcedTzo?t.forcedTzo:this.offsetForMarker(e)),buildIsoString(e,n,t.omitTime)},e.prototype.timestampToMarker=function(e){return"local"===this.timeZone?arrayToUtcDate(dateToLocalArray(new Date(e))):"UTC"!==this.timeZone&&this.namedTimeZoneImpl?arrayToUtcDate(this.namedTimeZoneImpl.timestampToArray(e)):new Date(e)},e.prototype.offsetForMarker=function(e){return"local"===this.timeZone?-arrayToLocalDate(dateToUtcArray(e)).getTimezoneOffset():"UTC"===this.timeZone?0:this.namedTimeZoneImpl?this.namedTimeZoneImpl.offsetForArray(dateToUtcArray(e)):null},e.prototype.toDate=function(e,t){return"local"===this.timeZone?arrayToLocalDate(dateToUtcArray(e)):"UTC"===this.timeZone?new Date(e.valueOf()):this.namedTimeZoneImpl?new Date(e.valueOf()-1e3*this.namedTimeZoneImpl.offsetForArray(dateToUtcArray(e))*60):new Date(e.valueOf()-(t||0))},e}(),globalLocales=[],MINIMAL_RAW_EN_LOCALE={code:"en",week:{dow:0,doy:4},direction:"ltr",buttonText:{prev:"prev",next:"next",prevYear:"prev year",nextYear:"next year",year:"year",today:"today",month:"month",week:"week",day:"day",list:"list"},weekText:"W",weekTextLong:"Week",closeHint:"Close",timeHint:"Time",eventHint:"Event",allDayText:"all-day",moreLinkText:"more",noEventsText:"No events to display"},RAW_EN_LOCALE=__assign$1(__assign$1({},MINIMAL_RAW_EN_LOCALE),{buttonHints:{prev:"Previous $0",next:"Next $0",today:function(e,t){return"day"===t?"Today":"This "+e}},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show "+e+" more event"+(1===e?"":"s")}});function organizeRawLocales(e){for(var t=e.length>0?e[0].code:"en",n=globalLocales.concat(e),r={en:RAW_EN_LOCALE},o=0,i=n;o<i.length;o++){var a=i[o];r[a.code]=a}return{map:r,defaultCode:t}}function buildLocale(e,t){return"object"!=typeof e||Array.isArray(e)?queryLocale(e,t):parseLocale(e.code,[e.code],e)}function queryLocale(e,t){var n=[].concat(e||[]);return parseLocale(e,n,queryRawLocale(n,t)||RAW_EN_LOCALE)}function queryRawLocale(e,t){for(var n=0;n<e.length;n+=1)for(var r=e[n].toLocaleLowerCase().split("-"),o=r.length;o>0;o-=1){var i=r.slice(0,o).join("-");if(t[i])return t[i]}return null}function parseLocale(e,t,n){var r=mergeProps([MINIMAL_RAW_EN_LOCALE,n],["buttonText"]);delete r.code;var o=r.week;return delete r.week,{codeArg:e,codes:t,week:o,simpleNumberFormat:new Intl.NumberFormat(e),options:r}}var DEF_DEFAULTS={startTime:"09:00",endTime:"17:00",daysOfWeek:[1,2,3,4,5],display:"inverse-background",classNames:"fc-non-business",groupId:"_businessHours"},canVGrowWithinCell;function parseBusinessHours(e,t){return parseEvents(refineInputs(e),null,t)}function refineInputs(e){return(!0===e?[{}]:Array.isArray(e)?e.filter((function(e){return e.daysOfWeek})):"object"==typeof e&&e?[e]:[]).map((function(e){return __assign$1(__assign$1({},DEF_DEFAULTS),e)}))}function pointInsideRect(e,t){return e.left>=t.left&&e.left<t.right&&e.top>=t.top&&e.top<t.bottom}function intersectRects(e,t){var n={left:Math.max(e.left,t.left),right:Math.min(e.right,t.right),top:Math.max(e.top,t.top),bottom:Math.min(e.bottom,t.bottom)};return n.left<n.right&&n.top<n.bottom&&n}function constrainPoint(e,t){return{left:Math.min(Math.max(e.left,t.left),t.right),top:Math.min(Math.max(e.top,t.top),t.bottom)}}function getRectCenter(e){return{left:(e.left+e.right)/2,top:(e.top+e.bottom)/2}}function diffPoints(e,t){return{left:e.left-t.left,top:e.top-t.top}}function getCanVGrowWithinCell(){return null==canVGrowWithinCell&&(canVGrowWithinCell=computeCanVGrowWithinCell()),canVGrowWithinCell}function computeCanVGrowWithinCell(){if("undefined"==typeof document)return!0;var e=document.createElement("div");e.style.position="absolute",e.style.top="0px",e.style.left="0px",e.innerHTML="<table><tr><td><div></div></td></tr></table>",e.querySelector("table").style.height="100px",e.querySelector("div").style.height="100%",document.body.appendChild(e);var t=e.querySelector("div").offsetHeight>0;return document.body.removeChild(e),t}var EMPTY_EVENT_STORE=createEmptyEventStore(),Splitter=function(){function e(){this.getKeysForEventDefs=memoize(this._getKeysForEventDefs),this.splitDateSelection=memoize(this._splitDateSpan),this.splitEventStore=memoize(this._splitEventStore),this.splitIndividualUi=memoize(this._splitIndividualUi),this.splitEventDrag=memoize(this._splitInteraction),this.splitEventResize=memoize(this._splitInteraction),this.eventUiBuilders={}}return e.prototype.splitProps=function(e){var t=this,n=this.getKeyInfo(e),r=this.getKeysForEventDefs(e.eventStore),o=this.splitDateSelection(e.dateSelection),i=this.splitIndividualUi(e.eventUiBases,r),a=this.splitEventStore(e.eventStore,r),s=this.splitEventDrag(e.eventDrag),l=this.splitEventResize(e.eventResize),u={};for(var c in this.eventUiBuilders=mapHash(n,(function(e,n){return t.eventUiBuilders[n]||memoize(buildEventUiForKey)})),n){var d=n[c],p=a[c]||EMPTY_EVENT_STORE,f=this.eventUiBuilders[c];u[c]={businessHours:d.businessHours||e.businessHours,dateSelection:o[c]||null,eventStore:p,eventUiBases:f(e.eventUiBases[""],d.ui,i[c]),eventSelection:p.instances[e.eventSelection]?e.eventSelection:"",eventDrag:s[c]||null,eventResize:l[c]||null}}return u},e.prototype._splitDateSpan=function(e){var t={};if(e)for(var n=0,r=this.getKeysForDateSpan(e);n<r.length;n++){t[r[n]]=e}return t},e.prototype._getKeysForEventDefs=function(e){var t=this;return mapHash(e.defs,(function(e){return t.getKeysForEventDef(e)}))},e.prototype._splitEventStore=function(e,t){var n=e.defs,r=e.instances,o={};for(var i in n)for(var a=0,s=t[i];a<s.length;a++){o[p=s[a]]||(o[p]=createEmptyEventStore()),o[p].defs[i]=n[i]}for(var l in r)for(var u=r[l],c=0,d=t[u.defId];c<d.length;c++){var p;o[p=d[c]]&&(o[p].instances[l]=u)}return o},e.prototype._splitIndividualUi=function(e,t){var n={};for(var r in e)if(r)for(var o=0,i=t[r];o<i.length;o++){var a=i[o];n[a]||(n[a]={}),n[a][r]=e[r]}return n},e.prototype._splitInteraction=function(e){var t={};if(e){var n=this._splitEventStore(e.affectedEvents,this._getKeysForEventDefs(e.affectedEvents)),r=this._getKeysForEventDefs(e.mutatedEvents),o=this._splitEventStore(e.mutatedEvents,r),i=function(r){t[r]||(t[r]={affectedEvents:n[r]||EMPTY_EVENT_STORE,mutatedEvents:o[r]||EMPTY_EVENT_STORE,isEvent:e.isEvent})};for(var a in n)i(a);for(var a in o)i(a)}return t},e}();function buildEventUiForKey(e,t,n){var r=[];e&&r.push(e),t&&r.push(t);var o={"":combineEventUis(r)};return n&&__assign$1(o,n),o}function getDateMeta(e,t,n,r){return{dow:e.getUTCDay(),isDisabled:Boolean(r&&!rangeContainsMarker(r.activeRange,e)),isOther:Boolean(r&&!rangeContainsMarker(r.currentRange,e)),isToday:Boolean(t&&rangeContainsMarker(t,e)),isPast:Boolean(n?e<n:!!t&&e<t.start),isFuture:Boolean(n?e>n:!!t&&e>=t.end)}}function getDayClassNames(e,t){var n=["fc-day","fc-day-"+DAY_IDS[e.dow]];return e.isDisabled?n.push("fc-day-disabled"):(e.isToday&&(n.push("fc-day-today"),n.push(t.getClass("today"))),e.isPast&&n.push("fc-day-past"),e.isFuture&&n.push("fc-day-future"),e.isOther&&n.push("fc-day-other")),n}var DAY_FORMAT=createFormatter({year:"numeric",month:"long",day:"numeric"}),WEEK_FORMAT=createFormatter({week:"long"});function buildNavLinkAttrs(e,t,n,r){void 0===n&&(n="day"),void 0===r&&(r=!0);var o=e.dateEnv,i=e.options,a=e.calendarApi,s=o.format(t,"week"===n?WEEK_FORMAT:DAY_FORMAT);if(i.navLinks){var l=o.toDate(t),u=function(e){var r="day"===n?i.navLinkDayClick:"week"===n?i.navLinkWeekClick:null;"function"==typeof r?r.call(a,o.toDate(t),e):("string"==typeof r&&(n=r),a.zoomTo(t,n))};return __assign$1({title:formatWithOrdinals(i.navLinkHint,[s,l],s),"data-navlink":""},r?createAriaClickAttrs(u):{onClick:u})}return{"aria-label":s}}var _isRtlScrollbarOnLeft=null,_scrollbarWidths;function getIsRtlScrollbarOnLeft(){return null===_isRtlScrollbarOnLeft&&(_isRtlScrollbarOnLeft=computeIsRtlScrollbarOnLeft()),_isRtlScrollbarOnLeft}function computeIsRtlScrollbarOnLeft(){var e=document.createElement("div");applyStyle(e,{position:"absolute",top:-1e3,left:0,border:0,padding:0,overflow:"scroll",direction:"rtl"}),e.innerHTML="<div></div>",document.body.appendChild(e);var t=e.firstChild.getBoundingClientRect().left>e.getBoundingClientRect().left;return removeElement(e),t}function getScrollbarWidths(){return _scrollbarWidths||(_scrollbarWidths=computeScrollbarWidths()),_scrollbarWidths}function computeScrollbarWidths(){var e=document.createElement("div");e.style.overflow="scroll",e.style.position="absolute",e.style.top="-9999px",e.style.left="-9999px",document.body.appendChild(e);var t=computeScrollbarWidthsForEl(e);return document.body.removeChild(e),t}function computeScrollbarWidthsForEl(e){return{x:e.offsetHeight-e.clientHeight,y:e.offsetWidth-e.clientWidth}}function computeEdges(e,t){void 0===t&&(t=!1);var n=window.getComputedStyle(e),r=parseInt(n.borderLeftWidth,10)||0,o=parseInt(n.borderRightWidth,10)||0,i=parseInt(n.borderTopWidth,10)||0,a=parseInt(n.borderBottomWidth,10)||0,s=computeScrollbarWidthsForEl(e),l=s.y-r-o,u={borderLeft:r,borderRight:o,borderTop:i,borderBottom:a,scrollbarBottom:s.x-i-a,scrollbarLeft:0,scrollbarRight:0};return getIsRtlScrollbarOnLeft()&&"rtl"===n.direction?u.scrollbarLeft=l:u.scrollbarRight=l,t&&(u.paddingLeft=parseInt(n.paddingLeft,10)||0,u.paddingRight=parseInt(n.paddingRight,10)||0,u.paddingTop=parseInt(n.paddingTop,10)||0,u.paddingBottom=parseInt(n.paddingBottom,10)||0),u}function computeInnerRect(e,t,n){void 0===t&&(t=!1);var r=n?e.getBoundingClientRect():computeRect(e),o=computeEdges(e,t),i={left:r.left+o.borderLeft+o.scrollbarLeft,right:r.right-o.borderRight-o.scrollbarRight,top:r.top+o.borderTop,bottom:r.bottom-o.borderBottom-o.scrollbarBottom};return t&&(i.left+=o.paddingLeft,i.right-=o.paddingRight,i.top+=o.paddingTop,i.bottom-=o.paddingBottom),i}function computeRect(e){var t=e.getBoundingClientRect();return{left:t.left+window.pageXOffset,top:t.top+window.pageYOffset,right:t.right+window.pageXOffset,bottom:t.bottom+window.pageYOffset}}function computeClippedClientRect(e){for(var t=getClippingParents(e),n=e.getBoundingClientRect(),r=0,o=t;r<o.length;r++){var i=intersectRects(n,o[r].getBoundingClientRect());if(!i)return null;n=i}return n}function getClippingParents(e){for(var t=[];e instanceof HTMLElement;){var n=window.getComputedStyle(e);if("fixed"===n.position)break;/(auto|scroll)/.test(n.overflow+n.overflowY+n.overflowX)&&t.push(e),e=e.parentNode}return t}function unpromisify(e,t,n){var r=!1,o=function(){r||(r=!0,t.apply(this,arguments))},i=function(){r||(r=!0,n&&n.apply(this,arguments))},a=e(o,i);a&&"function"==typeof a.then&&a.then(o,i)}var Emitter=function(){function e(){this.handlers={},this.thisContext=null}return e.prototype.setThisContext=function(e){this.thisContext=e},e.prototype.setOptions=function(e){this.options=e},e.prototype.on=function(e,t){addToHash(this.handlers,e,t)},e.prototype.off=function(e,t){removeFromHash(this.handlers,e,t)},e.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=this.handlers[e]||[],o=this.options&&this.options[e],i=[].concat(o||[],r),a=0,s=i;a<s.length;a++){var l=s[a];l.apply(this.thisContext,t)}},e.prototype.hasHandlers=function(e){return Boolean(this.handlers[e]&&this.handlers[e].length||this.options&&this.options[e])},e}();function addToHash(e,t,n){(e[t]||(e[t]=[])).push(n)}function removeFromHash(e,t,n){n?e[t]&&(e[t]=e[t].filter((function(e){return e!==n}))):delete e[t]}var PositionCache=function(){function e(e,t,n,r){this.els=t;var o=this.originClientRect=e.getBoundingClientRect();n&&this.buildElHorizontals(o.left),r&&this.buildElVerticals(o.top)}return e.prototype.buildElHorizontals=function(e){for(var t=[],n=[],r=0,o=this.els;r<o.length;r++){var i=o[r].getBoundingClientRect();t.push(i.left-e),n.push(i.right-e)}this.lefts=t,this.rights=n},e.prototype.buildElVerticals=function(e){for(var t=[],n=[],r=0,o=this.els;r<o.length;r++){var i=o[r].getBoundingClientRect();t.push(i.top-e),n.push(i.bottom-e)}this.tops=t,this.bottoms=n},e.prototype.leftToIndex=function(e){var t,n=this.lefts,r=this.rights,o=n.length;for(t=0;t<o;t+=1)if(e>=n[t]&&e<r[t])return t},e.prototype.topToIndex=function(e){var t,n=this.tops,r=this.bottoms,o=n.length;for(t=0;t<o;t+=1)if(e>=n[t]&&e<r[t])return t},e.prototype.getWidth=function(e){return this.rights[e]-this.lefts[e]},e.prototype.getHeight=function(e){return this.bottoms[e]-this.tops[e]},e}(),ScrollController=function(){function e(){}return e.prototype.getMaxScrollTop=function(){return this.getScrollHeight()-this.getClientHeight()},e.prototype.getMaxScrollLeft=function(){return this.getScrollWidth()-this.getClientWidth()},e.prototype.canScrollVertically=function(){return this.getMaxScrollTop()>0},e.prototype.canScrollHorizontally=function(){return this.getMaxScrollLeft()>0},e.prototype.canScrollUp=function(){return this.getScrollTop()>0},e.prototype.canScrollDown=function(){return this.getScrollTop()<this.getMaxScrollTop()},e.prototype.canScrollLeft=function(){return this.getScrollLeft()>0},e.prototype.canScrollRight=function(){return this.getScrollLeft()<this.getMaxScrollLeft()},e}(),ElementScrollController=function(e){function t(t){var n=e.call(this)||this;return n.el=t,n}return __extends(t,e),t.prototype.getScrollTop=function(){return this.el.scrollTop},t.prototype.getScrollLeft=function(){return this.el.scrollLeft},t.prototype.setScrollTop=function(e){this.el.scrollTop=e},t.prototype.setScrollLeft=function(e){this.el.scrollLeft=e},t.prototype.getScrollWidth=function(){return this.el.scrollWidth},t.prototype.getScrollHeight=function(){return this.el.scrollHeight},t.prototype.getClientHeight=function(){return this.el.clientHeight},t.prototype.getClientWidth=function(){return this.el.clientWidth},t}(ScrollController),WindowScrollController=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.getScrollTop=function(){return window.pageYOffset},t.prototype.getScrollLeft=function(){return window.pageXOffset},t.prototype.setScrollTop=function(e){window.scroll(window.pageXOffset,e)},t.prototype.setScrollLeft=function(e){window.scroll(e,window.pageYOffset)},t.prototype.getScrollWidth=function(){return document.documentElement.scrollWidth},t.prototype.getScrollHeight=function(){return document.documentElement.scrollHeight},t.prototype.getClientHeight=function(){return document.documentElement.clientHeight},t.prototype.getClientWidth=function(){return document.documentElement.clientWidth},t}(ScrollController),Theme=function(){function e(e){this.iconOverrideOption&&this.setIconOverride(e[this.iconOverrideOption])}return e.prototype.setIconOverride=function(e){var t,n;if("object"==typeof e&&e){for(n in t=__assign$1({},this.iconClasses),e)t[n]=this.applyIconOverridePrefix(e[n]);this.iconClasses=t}else!1===e&&(this.iconClasses={})},e.prototype.applyIconOverridePrefix=function(e){var t=this.iconOverridePrefix;return t&&0!==e.indexOf(t)&&(e=t+e),e},e.prototype.getClass=function(e){return this.classes[e]||""},e.prototype.getIconClass=function(e,t){var n;return(n=t&&this.rtlIconClasses&&this.rtlIconClasses[e]||this.iconClasses[e])?this.baseIconClass+" "+n:""},e.prototype.getCustomButtonIconClass=function(e){var t;return this.iconOverrideCustomButtonOption&&(t=e[this.iconOverrideCustomButtonOption])?this.baseIconClass+" "+this.applyIconOverridePrefix(t):""},e}();Theme.prototype.classes={},Theme.prototype.iconClasses={},Theme.prototype.baseIconClass="",Theme.prototype.iconOverridePrefix="";var ScrollResponder=function(){function e(e,t,n,r){var o=this;this.execFunc=e,this.emitter=t,this.scrollTime=n,this.scrollTimeReset=r,this.handleScrollRequest=function(e){o.queuedRequest=__assign$1({},o.queuedRequest||{},e),o.drain()},t.on("_scrollRequest",this.handleScrollRequest),this.fireInitialScroll()}return e.prototype.detach=function(){this.emitter.off("_scrollRequest",this.handleScrollRequest)},e.prototype.update=function(e){e&&this.scrollTimeReset?this.fireInitialScroll():this.drain()},e.prototype.fireInitialScroll=function(){this.handleScrollRequest({time:this.scrollTime})},e.prototype.drain=function(){this.queuedRequest&&this.execFunc(this.queuedRequest)&&(this.queuedRequest=null)},e}(),ViewContextType=createContext({});function buildViewContext(e,t,n,r,o,i,a,s,l,u,c,d,p){return{dateEnv:o,options:n,pluginHooks:a,emitter:u,dispatch:s,getCurrentData:l,calendarApi:c,viewSpec:e,viewApi:t,dateProfileGenerator:r,theme:i,isRtl:"rtl"===n.direction,addResizeHandler:function(e){u.on("_resize",e)},removeResizeHandler:function(e){u.off("_resize",e)},createScrollResponder:function(e){return new ScrollResponder(e,u,createDuration(n.scrollTime),n.scrollTimeReset)},registerInteractiveComponent:d,unregisterInteractiveComponent:p}}var PureComponent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.shouldComponentUpdate=function(e,t){return this.debug&&console.log(getUnequalProps(e,this.props),getUnequalProps(t,this.state)),!compareObjs(this.props,e,this.propEquality)||!compareObjs(this.state,t,this.stateEquality)},t.prototype.safeSetState=function(e){compareObjs(this.state,__assign$1(__assign$1({},this.state),e),this.stateEquality)||this.setState(e)},t.addPropsEquality=addPropsEquality,t.addStateEquality=addStateEquality,t.contextType=ViewContextType,t}(Component);PureComponent.prototype.propEquality={},PureComponent.prototype.stateEquality={};var BaseComponent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.contextType=ViewContextType,t}(PureComponent);function addPropsEquality(e){var t=Object.create(this.prototype.propEquality);__assign$1(t,e),this.prototype.propEquality=t}function addStateEquality(e){var t=Object.create(this.prototype.stateEquality);__assign$1(t,e),this.prototype.stateEquality=t}function setRef(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var DateComponent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.uid=guid(),t}return __extends(t,e),t.prototype.prepareHits=function(){},t.prototype.queryHit=function(e,t,n,r){return null},t.prototype.isValidSegDownEl=function(e){return!this.props.eventDrag&&!this.props.eventResize&&!elementClosest(e,".fc-event-mirror")},t.prototype.isValidDateDownEl=function(e){return!(elementClosest(e,".fc-event:not(.fc-bg-event)")||elementClosest(e,".fc-more-link")||elementClosest(e,"a[data-navlink]")||elementClosest(e,".fc-popover"))},t}(BaseComponent);function createPlugin(e){return{id:guid(),deps:e.deps||[],reducers:e.reducers||[],isLoadingFuncs:e.isLoadingFuncs||[],contextInit:[].concat(e.contextInit||[]),eventRefiners:e.eventRefiners||{},eventDefMemberAdders:e.eventDefMemberAdders||[],eventSourceRefiners:e.eventSourceRefiners||{},isDraggableTransformers:e.isDraggableTransformers||[],eventDragMutationMassagers:e.eventDragMutationMassagers||[],eventDefMutationAppliers:e.eventDefMutationAppliers||[],dateSelectionTransformers:e.dateSelectionTransformers||[],datePointTransforms:e.datePointTransforms||[],dateSpanTransforms:e.dateSpanTransforms||[],views:e.views||{},viewPropsTransformers:e.viewPropsTransformers||[],isPropsValid:e.isPropsValid||null,externalDefTransforms:e.externalDefTransforms||[],viewContainerAppends:e.viewContainerAppends||[],eventDropTransformers:e.eventDropTransformers||[],componentInteractions:e.componentInteractions||[],calendarInteractions:e.calendarInteractions||[],themeClasses:e.themeClasses||{},eventSourceDefs:e.eventSourceDefs||[],cmdFormatter:e.cmdFormatter,recurringTypes:e.recurringTypes||[],namedTimeZonedImpl:e.namedTimeZonedImpl,initialView:e.initialView||"",elementDraggingImpl:e.elementDraggingImpl,optionChangeHandlers:e.optionChangeHandlers||{},scrollGridImpl:e.scrollGridImpl||null,contentTypeHandlers:e.contentTypeHandlers||{},listenerRefiners:e.listenerRefiners||{},optionRefiners:e.optionRefiners||{},propSetHandlers:e.propSetHandlers||{}}}function buildPluginHooks(e,t){var n={},r={reducers:[],isLoadingFuncs:[],contextInit:[],eventRefiners:{},eventDefMemberAdders:[],eventSourceRefiners:{},isDraggableTransformers:[],eventDragMutationMassagers:[],eventDefMutationAppliers:[],dateSelectionTransformers:[],datePointTransforms:[],dateSpanTransforms:[],views:{},viewPropsTransformers:[],isPropsValid:null,externalDefTransforms:[],viewContainerAppends:[],eventDropTransformers:[],componentInteractions:[],calendarInteractions:[],themeClasses:{},eventSourceDefs:[],cmdFormatter:null,recurringTypes:[],namedTimeZonedImpl:null,initialView:"",elementDraggingImpl:null,optionChangeHandlers:{},scrollGridImpl:null,contentTypeHandlers:{},listenerRefiners:{},optionRefiners:{},propSetHandlers:{}};function o(e){for(var t=0,i=e;t<i.length;t++){var a=i[t];n[a.id]||(n[a.id]=!0,o(a.deps),r=combineHooks(r,a))}}return e&&o(e),o(t),r}function buildBuildPluginHooks(){var e,t=[],n=[];return function(r,o){return e&&isArraysEqual(r,t)&&isArraysEqual(o,n)||(e=buildPluginHooks(r,o)),t=r,n=o,e}}function combineHooks(e,t){return{reducers:e.reducers.concat(t.reducers),isLoadingFuncs:e.isLoadingFuncs.concat(t.isLoadingFuncs),contextInit:e.contextInit.concat(t.contextInit),eventRefiners:__assign$1(__assign$1({},e.eventRefiners),t.eventRefiners),eventDefMemberAdders:e.eventDefMemberAdders.concat(t.eventDefMemberAdders),eventSourceRefiners:__assign$1(__assign$1({},e.eventSourceRefiners),t.eventSourceRefiners),isDraggableTransformers:e.isDraggableTransformers.concat(t.isDraggableTransformers),eventDragMutationMassagers:e.eventDragMutationMassagers.concat(t.eventDragMutationMassagers),eventDefMutationAppliers:e.eventDefMutationAppliers.concat(t.eventDefMutationAppliers),dateSelectionTransformers:e.dateSelectionTransformers.concat(t.dateSelectionTransformers),datePointTransforms:e.datePointTransforms.concat(t.datePointTransforms),dateSpanTransforms:e.dateSpanTransforms.concat(t.dateSpanTransforms),views:__assign$1(__assign$1({},e.views),t.views),viewPropsTransformers:e.viewPropsTransformers.concat(t.viewPropsTransformers),isPropsValid:t.isPropsValid||e.isPropsValid,externalDefTransforms:e.externalDefTransforms.concat(t.externalDefTransforms),viewContainerAppends:e.viewContainerAppends.concat(t.viewContainerAppends),eventDropTransformers:e.eventDropTransformers.concat(t.eventDropTransformers),calendarInteractions:e.calendarInteractions.concat(t.calendarInteractions),componentInteractions:e.componentInteractions.concat(t.componentInteractions),themeClasses:__assign$1(__assign$1({},e.themeClasses),t.themeClasses),eventSourceDefs:e.eventSourceDefs.concat(t.eventSourceDefs),cmdFormatter:t.cmdFormatter||e.cmdFormatter,recurringTypes:e.recurringTypes.concat(t.recurringTypes),namedTimeZonedImpl:t.namedTimeZonedImpl||e.namedTimeZonedImpl,initialView:e.initialView||t.initialView,elementDraggingImpl:e.elementDraggingImpl||t.elementDraggingImpl,optionChangeHandlers:__assign$1(__assign$1({},e.optionChangeHandlers),t.optionChangeHandlers),scrollGridImpl:t.scrollGridImpl||e.scrollGridImpl,contentTypeHandlers:__assign$1(__assign$1({},e.contentTypeHandlers),t.contentTypeHandlers),listenerRefiners:__assign$1(__assign$1({},e.listenerRefiners),t.listenerRefiners),optionRefiners:__assign$1(__assign$1({},e.optionRefiners),t.optionRefiners),propSetHandlers:__assign$1(__assign$1({},e.propSetHandlers),t.propSetHandlers)}}var StandardTheme=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t}(Theme);function compileViewDefs(e,t){var n,r={};for(n in e)ensureViewDef(n,r,e,t);for(n in t)ensureViewDef(n,r,e,t);return r}function ensureViewDef(e,t,n,r){if(t[e])return t[e];var o=buildViewDef(e,t,n,r);return o&&(t[e]=o),o}function buildViewDef(e,t,n,r){var o=n[e],i=r[e],a=function(e){return o&&null!==o[e]?o[e]:i&&null!==i[e]?i[e]:null},s=a("component"),l=a("superType"),u=null;if(l){if(l===e)throw new Error("Can't have a custom view type that references itself");u=ensureViewDef(l,t,n,r)}return!s&&u&&(s=u.component),s?{type:e,component:s,defaults:__assign$1(__assign$1({},u?u.defaults:{}),o?o.rawOptions:{}),overrides:__assign$1(__assign$1({},u?u.overrides:{}),i?i.rawOptions:{})}:null}StandardTheme.prototype.classes={root:"fc-theme-standard",tableCellShaded:"fc-cell-shaded",buttonGroup:"fc-button-group",button:"fc-button fc-button-primary",buttonActive:"fc-button-active"},StandardTheme.prototype.baseIconClass="fc-icon",StandardTheme.prototype.iconClasses={close:"fc-icon-x",prev:"fc-icon-chevron-left",next:"fc-icon-chevron-right",prevYear:"fc-icon-chevrons-left",nextYear:"fc-icon-chevrons-right"},StandardTheme.prototype.rtlIconClasses={prev:"fc-icon-chevron-right",next:"fc-icon-chevron-left",prevYear:"fc-icon-chevrons-right",nextYear:"fc-icon-chevrons-left"},StandardTheme.prototype.iconOverrideOption="buttonIcons",StandardTheme.prototype.iconOverrideCustomButtonOption="icon",StandardTheme.prototype.iconOverridePrefix="fc-icon-";var RenderHook=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.handleRootEl=function(e){setRef(t.rootElRef,e),t.props.elRef&&setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.hookProps;return createElement(MountHook,{hookProps:n,didMount:t.didMount,willUnmount:t.willUnmount,elRef:this.handleRootEl},(function(r){return createElement(ContentHook,{hookProps:n,content:t.content,defaultContent:t.defaultContent,backupElRef:e.rootElRef},(function(e,o){return t.children(r,normalizeClassNames(t.classNames,n),e,o)}))}))},t}(BaseComponent),CustomContentRenderContext=createContext(0);function ContentHook(e){return createElement(CustomContentRenderContext.Consumer,null,(function(t){return createElement(ContentHookInner,__assign$1({renderId:t},e))}))}var ContentHookInner=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.innerElRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.innerElRef,this.renderInnerContent())},t.prototype.componentDidMount=function(){this.updateCustomContent()},t.prototype.componentDidUpdate=function(){this.updateCustomContent()},t.prototype.componentWillUnmount=function(){this.customContentInfo&&this.customContentInfo.destroy&&this.customContentInfo.destroy()},t.prototype.renderInnerContent=function(){var e=this.customContentInfo,t=this.getInnerContent(),n=this.getContentMeta(t);return e&&e.contentKey===n.contentKey?e&&(e.contentVal=t[n.contentKey]):(e&&(e.destroy&&e.destroy(),e=this.customContentInfo=null),n.contentKey&&(e=this.customContentInfo=__assign$1({contentKey:n.contentKey,contentVal:t[n.contentKey]},n.buildLifecycleFuncs()))),e?[]:t},t.prototype.getInnerContent=function(){var e=this.props,t=normalizeContent(e.content,e.hookProps);return void 0===t&&(t=normalizeContent(e.defaultContent,e.hookProps)),null==t?null:t},t.prototype.getContentMeta=function(e){var t=this.context.pluginHooks.contentTypeHandlers,n="",r=null;if(e)for(var o in t)if(void 0!==e[o]){n=o,r=t[o];break}return{contentKey:n,buildLifecycleFuncs:r}},t.prototype.updateCustomContent=function(){this.customContentInfo&&this.customContentInfo.render(this.innerElRef.current||this.props.backupElRef.current,this.customContentInfo.contentVal)},t}(BaseComponent),MountHook=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleRootEl=function(e){t.rootEl=e,t.props.elRef&&setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.handleRootEl)},t.prototype.componentDidMount=function(){var e=this.props.didMount;e&&e(__assign$1(__assign$1({},this.props.hookProps),{el:this.rootEl}))},t.prototype.componentWillUnmount=function(){var e=this.props.willUnmount;e&&e(__assign$1(__assign$1({},this.props.hookProps),{el:this.rootEl}))},t}(BaseComponent);function buildClassNameNormalizer(){var e,t,n=[];return function(r,o){return t&&isPropsEqual(t,o)&&r===e||(e=r,t=o,n=normalizeClassNames(r,o)),n}}function normalizeClassNames(e,t){return"function"==typeof e&&(e=e(t)),parseClassNames(e)}function normalizeContent(e,t){return"function"==typeof e?e(t,createElement):e}var ViewRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.normalizeClassNames=buildClassNameNormalizer(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r={view:t.viewApi},o=this.normalizeClassNames(n.viewClassNames,r);return createElement(MountHook,{hookProps:r,didMount:n.viewDidMount,willUnmount:n.viewWillUnmount,elRef:e.elRef},(function(t){return e.children(t,["fc-"+e.viewSpec.type+"-view","fc-view"].concat(o))}))},t}(BaseComponent);function parseViewConfigs(e){return mapHash(e,parseViewConfig)}function parseViewConfig(e){var t="function"==typeof e?{component:e}:e,n=t.component;return t.content&&(n=createViewHookComponent(t)),{superType:t.type,component:n,rawOptions:t}}function createViewHookComponent(e){return function(t){return createElement(ViewContextType.Consumer,null,(function(n){return createElement(ViewRoot,{viewSpec:n.viewSpec},(function(r,o){var i=__assign$1(__assign$1({},t),{nextDayThreshold:n.options.nextDayThreshold});return createElement(RenderHook,{hookProps:i,classNames:e.classNames,content:e.content,didMount:e.didMount,willUnmount:e.willUnmount,elRef:r},(function(e,t,n,r){return createElement("div",{className:o.concat(t).join(" "),ref:e},r)}))}))}))}}function buildViewSpecs(e,t,n,r){var o=parseViewConfigs(e),i=parseViewConfigs(t.views);return mapHash(compileViewDefs(o,i),(function(e){return buildViewSpec(e,i,t,n,r)}))}function buildViewSpec(e,t,n,r,o){var i=e.overrides.duration||e.defaults.duration||r.duration||n.duration,a=null,s="",l="",u={};if(i&&(a=createDurationCached(i))){var c=greatestDurationDenominator(a);s=c.unit,1===c.value&&(l=s,u=t[s]?t[s].rawOptions:{})}var d=function(t){var n=t.buttonText||{},r=e.defaults.buttonTextKey;return null!=r&&null!=n[r]?n[r]:null!=n[e.type]?n[e.type]:null!=n[l]?n[l]:null},p=function(t){var n=t.buttonHints||{},r=e.defaults.buttonTextKey;return null!=r&&null!=n[r]?n[r]:null!=n[e.type]?n[e.type]:null!=n[l]?n[l]:null};return{type:e.type,component:e.component,duration:a,durationUnit:s,singleUnit:l,optionDefaults:e.defaults,optionOverrides:__assign$1(__assign$1({},u),e.overrides),buttonTextOverride:d(r)||d(n)||e.overrides.buttonText,buttonTextDefault:d(o)||e.defaults.buttonText||d(BASE_OPTION_DEFAULTS)||e.type,buttonTitleOverride:p(r)||p(n)||e.overrides.buttonHint,buttonTitleDefault:p(o)||e.defaults.buttonHint||p(BASE_OPTION_DEFAULTS)}}var durationInputMap={};function createDurationCached(e){var t=JSON.stringify(e),n=durationInputMap[t];return void 0===n&&(n=createDuration(e),durationInputMap[t]=n),n}var DateProfileGenerator=function(){function e(e){this.props=e,this.nowDate=getNow(e.nowInput,e.dateEnv),this.initHiddenDays()}return e.prototype.buildPrev=function(e,t,n){var r=this.props.dateEnv,o=r.subtract(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(o,-1,n)},e.prototype.buildNext=function(e,t,n){var r=this.props.dateEnv,o=r.add(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(o,1,n)},e.prototype.build=function(e,t,n){void 0===n&&(n=!0);var r,o,i,a,s,l,u=this.props;return r=this.buildValidRange(),r=this.trimHiddenDays(r),n&&(e=constrainMarkerToRange(e,r)),o=this.buildCurrentRangeInfo(e,t),i=/^(year|month|week|day)$/.test(o.unit),a=this.buildRenderRange(this.trimHiddenDays(o.range),o.unit,i),s=a=this.trimHiddenDays(a),u.showNonCurrentDates||(s=intersectRanges(s,o.range)),s=intersectRanges(s=this.adjustActiveRange(s),r),l=rangesIntersect(o.range,r),{validRange:r,currentRange:o.range,currentRangeUnit:o.unit,isRangeAllDay:i,activeRange:s,renderRange:a,slotMinTime:u.slotMinTime,slotMaxTime:u.slotMaxTime,isValid:l,dateIncrement:this.buildDateIncrement(o.duration)}},e.prototype.buildValidRange=function(){var e=this.props.validRangeInput,t="function"==typeof e?e.call(this.props.calendarApi,this.nowDate):e;return this.refineRange(t)||{start:null,end:null}},e.prototype.buildCurrentRangeInfo=function(e,t){var n,r=this.props,o=null,i=null,a=null;return r.duration?(o=r.duration,i=r.durationUnit,a=this.buildRangeFromDuration(e,t,o,i)):(n=this.props.dayCount)?(i="day",a=this.buildRangeFromDayCount(e,t,n)):(a=this.buildCustomVisibleRange(e))?i=r.dateEnv.greatestWholeUnit(a.start,a.end).unit:(i=greatestDurationDenominator(o=this.getFallbackDuration()).unit,a=this.buildRangeFromDuration(e,t,o,i)),{duration:o,unit:i,range:a}},e.prototype.getFallbackDuration=function(){return createDuration({day:1})},e.prototype.adjustActiveRange=function(e){var t=this.props,n=t.dateEnv,r=t.usesMinMaxTime,o=t.slotMinTime,i=t.slotMaxTime,a=e.start,s=e.end;return r&&(asRoughDays(o)<0&&(a=startOfDay(a),a=n.add(a,o)),asRoughDays(i)>1&&(s=addDays(s=startOfDay(s),-1),s=n.add(s,i))),{start:a,end:s}},e.prototype.buildRangeFromDuration=function(e,t,n,r){var o,i,a,s=this.props,l=s.dateEnv,u=s.dateAlignment;if(!u){var c=this.props.dateIncrement;u=c&&asRoughMs(c)<asRoughMs(n)?greatestDurationDenominator(c).unit:r}function d(){o=l.startOf(e,u),i=l.add(o,n),a={start:o,end:i}}return asRoughDays(n)<=1&&this.isHiddenDay(o)&&(o=startOfDay(o=this.skipHiddenDays(o,t))),d(),this.trimHiddenDays(a)||(e=this.skipHiddenDays(e,t),d()),a},e.prototype.buildRangeFromDayCount=function(e,t,n){var r,o=this.props,i=o.dateEnv,a=o.dateAlignment,s=0,l=e;a&&(l=i.startOf(l,a)),l=startOfDay(l),r=l=this.skipHiddenDays(l,t);do{r=addDays(r,1),this.isHiddenDay(r)||(s+=1)}while(s<n);return{start:l,end:r}},e.prototype.buildCustomVisibleRange=function(e){var t=this.props,n=t.visibleRangeInput,r="function"==typeof n?n.call(t.calendarApi,t.dateEnv.toDate(e)):n,o=this.refineRange(r);return!o||null!=o.start&&null!=o.end?o:null},e.prototype.buildRenderRange=function(e,t,n){return e},e.prototype.buildDateIncrement=function(e){var t,n=this.props.dateIncrement;return n||((t=this.props.dateAlignment)?createDuration(1,t):e||createDuration({days:1}))},e.prototype.refineRange=function(e){if(e){var t=parseRange(e,this.props.dateEnv);return t&&(t=computeVisibleDayRange(t)),t}return null},e.prototype.initHiddenDays=function(){var e,t=this.props.hiddenDays||[],n=[],r=0;for(!1===this.props.weekends&&t.push(0,6),e=0;e<7;e+=1)(n[e]=-1!==t.indexOf(e))||(r+=1);if(!r)throw new Error("invalid hiddenDays");this.isHiddenDayHash=n},e.prototype.trimHiddenDays=function(e){var t=e.start,n=e.end;return t&&(t=this.skipHiddenDays(t)),n&&(n=this.skipHiddenDays(n,-1,!0)),null==t||null==n||t<n?{start:t,end:n}:null},e.prototype.isHiddenDay=function(e){return e instanceof Date&&(e=e.getUTCDay()),this.isHiddenDayHash[e]},e.prototype.skipHiddenDays=function(e,t,n){for(void 0===t&&(t=1),void 0===n&&(n=!1);this.isHiddenDayHash[(e.getUTCDay()+(n?t:0)+7)%7];)e=addDays(e,t);return e},e}();function reduceViewType(e,t){if("CHANGE_VIEW_TYPE"===t.type)e=t.viewType;return e}function reduceDynamicOptionOverrides(e,t){var n;return"SET_OPTION"===t.type?__assign$1(__assign$1({},e),((n={})[t.optionName]=t.rawOptionValue,n)):e}function reduceDateProfile(e,t,n,r){var o;switch(t.type){case"CHANGE_VIEW_TYPE":return r.build(t.dateMarker||n);case"CHANGE_DATE":return r.build(t.dateMarker);case"PREV":if((o=r.buildPrev(e,n)).isValid)return o;break;case"NEXT":if((o=r.buildNext(e,n)).isValid)return o}return e}function initEventSources(e,t,n){var r=t?t.activeRange:null;return addSources({},parseInitialSources(e,n),r,n)}function reduceEventSources(e,t,n,r){var o=n?n.activeRange:null;switch(t.type){case"ADD_EVENT_SOURCES":return addSources(e,t.sources,o,r);case"REMOVE_EVENT_SOURCE":return removeSource(e,t.sourceId);case"PREV":case"NEXT":case"CHANGE_DATE":case"CHANGE_VIEW_TYPE":return n?fetchDirtySources(e,o,r):e;case"FETCH_EVENT_SOURCES":return fetchSourcesByIds(e,t.sourceIds?arrayToHash(t.sourceIds):excludeStaticSources(e,r),o,t.isRefetch||!1,r);case"RECEIVE_EVENTS":case"RECEIVE_EVENT_ERROR":return receiveResponse(e,t.sourceId,t.fetchId,t.fetchRange);case"REMOVE_ALL_EVENT_SOURCES":return{};default:return e}}function reduceEventSourcesNewTimeZone(e,t,n){var r=t?t.activeRange:null;return fetchSourcesByIds(e,excludeStaticSources(e,n),r,!0,n)}function computeEventSourcesLoading(e){for(var t in e)if(e[t].isFetching)return!0;return!1}function addSources(e,t,n,r){for(var o={},i=0,a=t;i<a.length;i++){var s=a[i];o[s.sourceId]=s}return n&&(o=fetchDirtySources(o,n,r)),__assign$1(__assign$1({},e),o)}function removeSource(e,t){return filterHash(e,(function(e){return e.sourceId!==t}))}function fetchDirtySources(e,t,n){return fetchSourcesByIds(e,filterHash(e,(function(e){return isSourceDirty(e,t,n)})),t,!1,n)}function isSourceDirty(e,t,n){return doesSourceNeedRange(e,n)?!n.options.lazyFetching||!e.fetchRange||e.isFetching||t.start<e.fetchRange.start||t.end>e.fetchRange.end:!e.latestFetchId}function fetchSourcesByIds(e,t,n,r,o){var i={};for(var a in e){var s=e[a];t[a]?i[a]=fetchSource(s,n,r,o):i[a]=s}return i}function fetchSource(e,t,n,r){var o=r.options,i=r.calendarApi,a=r.pluginHooks.eventSourceDefs[e.sourceDefId],s=guid();return a.fetch({eventSource:e,range:t,isRefetch:n,context:r},(function(n){var a=n.rawEvents;o.eventSourceSuccess&&(a=o.eventSourceSuccess.call(i,a,n.xhr)||a),e.success&&(a=e.success.call(i,a,n.xhr)||a),r.dispatch({type:"RECEIVE_EVENTS",sourceId:e.sourceId,fetchId:s,fetchRange:t,rawEvents:a})}),(function(n){console.warn(n.message,n),o.eventSourceFailure&&o.eventSourceFailure.call(i,n),e.failure&&e.failure(n),r.dispatch({type:"RECEIVE_EVENT_ERROR",sourceId:e.sourceId,fetchId:s,fetchRange:t,error:n})})),__assign$1(__assign$1({},e),{isFetching:!0,latestFetchId:s})}function receiveResponse(e,t,n,r){var o,i=e[t];return i&&n===i.latestFetchId?__assign$1(__assign$1({},e),((o={})[t]=__assign$1(__assign$1({},i),{isFetching:!1,fetchRange:r}),o)):e}function excludeStaticSources(e,t){return filterHash(e,(function(e){return doesSourceNeedRange(e,t)}))}function parseInitialSources(e,t){var n=buildEventSourceRefiners(t),r=[].concat(e.eventSources||[]),o=[];e.initialEvents&&r.unshift(e.initialEvents),e.events&&r.unshift(e.events);for(var i=0,a=r;i<a.length;i++){var s=parseEventSource(a[i],t,n);s&&o.push(s)}return o}function doesSourceNeedRange(e,t){return!t.pluginHooks.eventSourceDefs[e.sourceDefId].ignoreRange}function reduceEventStore(e,t,n,r,o){switch(t.type){case"RECEIVE_EVENTS":return receiveRawEvents(e,n[t.sourceId],t.fetchId,t.fetchRange,t.rawEvents,o);case"ADD_EVENTS":return addEvent(e,t.eventStore,r?r.activeRange:null,o);case"RESET_EVENTS":return t.eventStore;case"MERGE_EVENTS":return mergeEventStores(e,t.eventStore);case"PREV":case"NEXT":case"CHANGE_DATE":case"CHANGE_VIEW_TYPE":return r?expandRecurring(e,r.activeRange,o):e;case"REMOVE_EVENTS":return excludeSubEventStore(e,t.eventStore);case"REMOVE_EVENT_SOURCE":return excludeEventsBySourceId(e,t.sourceId);case"REMOVE_ALL_EVENT_SOURCES":return filterEventStoreDefs(e,(function(e){return!e.sourceId}));case"REMOVE_ALL_EVENTS":return createEmptyEventStore();default:return e}}function receiveRawEvents(e,t,n,r,o,i){if(t&&n===t.latestFetchId){var a=parseEvents(transformRawEvents(o,t,i),t,i);return r&&(a=expandRecurring(a,r,i)),mergeEventStores(excludeEventsBySourceId(e,t.sourceId),a)}return e}function transformRawEvents(e,t,n){var r=n.options.eventDataTransform,o=t?t.eventDataTransform:null;return o&&(e=transformEachRawEvent(e,o)),r&&(e=transformEachRawEvent(e,r)),e}function transformEachRawEvent(e,t){var n;if(t){n=[];for(var r=0,o=e;r<o.length;r++){var i=o[r],a=t(i);a?n.push(a):null==a&&n.push(i)}}else n=e;return n}function addEvent(e,t,n,r){return n&&(t=expandRecurring(t,n,r)),mergeEventStores(e,t)}function rezoneEventStoreDates(e,t,n){var r=e.defs,o=mapHash(e.instances,(function(e){var o=r[e.defId];return o.allDay||o.recurringDef?e:__assign$1(__assign$1({},e),{range:{start:n.createMarker(t.toDate(e.range.start,e.forcedStartTzo)),end:n.createMarker(t.toDate(e.range.end,e.forcedEndTzo))},forcedStartTzo:n.canComputeOffset?null:e.forcedStartTzo,forcedEndTzo:n.canComputeOffset?null:e.forcedEndTzo})}));return{defs:r,instances:o}}function excludeEventsBySourceId(e,t){return filterEventStoreDefs(e,(function(e){return e.sourceId!==t}))}function excludeInstances(e,t){return{defs:e.defs,instances:filterHash(e.instances,(function(e){return!t[e.instanceId]}))}}function reduceDateSelection(e,t){switch(t.type){case"UNSELECT_DATES":return null;case"SELECT_DATES":return t.selection;default:return e}}function reduceSelectedEvent(e,t){switch(t.type){case"UNSELECT_EVENT":return"";case"SELECT_EVENT":return t.eventInstanceId;default:return e}}function reduceEventDrag(e,t){var n;switch(t.type){case"UNSET_EVENT_DRAG":return null;case"SET_EVENT_DRAG":return{affectedEvents:(n=t.state).affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function reduceEventResize(e,t){var n;switch(t.type){case"UNSET_EVENT_RESIZE":return null;case"SET_EVENT_RESIZE":return{affectedEvents:(n=t.state).affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function parseToolbars(e,t,n,r,o){return{header:e.headerToolbar?parseToolbar(e.headerToolbar,e,t,n,r,o):null,footer:e.footerToolbar?parseToolbar(e.footerToolbar,e,t,n,r,o):null}}function parseToolbar(e,t,n,r,o,i){var a={},s=[],l=!1;for(var u in e){var c=parseSection(e[u],t,n,r,o,i);a[u]=c.widgets,s.push.apply(s,c.viewsWithButtons),l=l||c.hasTitle}return{sectionWidgets:a,viewsWithButtons:s,hasTitle:l}}function parseSection(e,t,n,r,o,i){var a="rtl"===t.direction,s=t.customButtons||{},l=n.buttonText||{},u=t.buttonText||{},c=n.buttonHints||{},d=t.buttonHints||{},p=e?e.split(" "):[],f=[],h=!1;return{widgets:p.map((function(e){return e.split(",").map((function(e){if("title"===e)return h=!0,{buttonName:e};var n,p,g,v,m,y;if(n=s[e])g=function(e){n.click&&n.click.call(e.target,e,e.target)},(v=r.getCustomButtonIconClass(n))||(v=r.getIconClass(e,a))||(m=n.text),y=n.hint||n.text;else if(p=o[e]){f.push(e),g=function(){i.changeView(e)},(m=p.buttonTextOverride)||(v=r.getIconClass(e,a))||(m=p.buttonTextDefault);var E=p.buttonTextOverride||p.buttonTextDefault;y=formatWithOrdinals(p.buttonTitleOverride||p.buttonTitleDefault||t.viewHint,[E,e],E)}else if(i[e])if(g=function(){i[e]()},(m=l[e])||(v=r.getIconClass(e,a))||(m=u[e]),"prevYear"===e||"nextYear"===e){var S="prevYear"===e?"prev":"next";y=formatWithOrdinals(c[S]||d[S],[u.year||"year","year"],u[e])}else y=function(t){return formatWithOrdinals(c[e]||d[e],[u[t]||t,t],u[e])};return{buttonName:e,buttonClick:g,buttonIcon:v,buttonText:m,buttonHint:y}}))})),viewsWithButtons:f,hasTitle:h}}var eventSourceDef$2={ignoreRange:!0,parseMeta:function(e){return Array.isArray(e.events)?e.events:null},fetch:function(e,t){t({rawEvents:e.eventSource.meta})}},arrayEventSourcePlugin=createPlugin({eventSourceDefs:[eventSourceDef$2]}),eventSourceDef$1={parseMeta:function(e){return"function"==typeof e.events?e.events:null},fetch:function(e,t,n){var r=e.context.dateEnv;unpromisify(e.eventSource.meta.bind(null,buildRangeApiWithTimeZone(e.range,r)),(function(e){t({rawEvents:e})}),n)}},funcEventSourcePlugin=createPlugin({eventSourceDefs:[eventSourceDef$1]});function requestJson(e,t,n,r,o){var i=null;"GET"===(e=e.toUpperCase())?t=injectQueryStringParams(t,n):i=encodeParams(n);var a=new XMLHttpRequest;a.open(e,t,!0),"GET"!==e&&a.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),a.onload=function(){if(a.status>=200&&a.status<400){var e=!1,t=void 0;try{t=JSON.parse(a.responseText),e=!0}catch(e){}e?r(t,a):o("Failure parsing JSON",a)}else o("Request failed",a)},a.onerror=function(){o("Request failed",a)},a.send(i)}function injectQueryStringParams(e,t){return e+(-1===e.indexOf("?")?"?":"&")+encodeParams(t)}function encodeParams(e){var t=[];for(var n in e)t.push(encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t.join("&")}var JSON_FEED_EVENT_SOURCE_REFINERS={method:String,extraParams:identity,startParam:String,endParam:String,timeZoneParam:String},eventSourceDef={parseMeta:function(e){return!e.url||"json"!==e.format&&e.format?null:{url:e.url,format:"json",method:(e.method||"GET").toUpperCase(),extraParams:e.extraParams,startParam:e.startParam,endParam:e.endParam,timeZoneParam:e.timeZoneParam}},fetch:function(e,t,n){var r=e.eventSource.meta,o=buildRequestParams(r,e.range,e.context);requestJson(r.method,r.url,o,(function(e,n){t({rawEvents:e,xhr:n})}),(function(e,t){n({message:e,xhr:t})}))}},jsonFeedEventSourcePlugin=createPlugin({eventSourceRefiners:JSON_FEED_EVENT_SOURCE_REFINERS,eventSourceDefs:[eventSourceDef]});function buildRequestParams(e,t,n){var r,o,i,a,s=n.dateEnv,l=n.options,u={};return null==(r=e.startParam)&&(r=l.startParam),null==(o=e.endParam)&&(o=l.endParam),null==(i=e.timeZoneParam)&&(i=l.timeZoneParam),a="function"==typeof e.extraParams?e.extraParams():e.extraParams||{},__assign$1(u,a),u[r]=s.formatIso(t.start),u[o]=s.formatIso(t.end),"local"!==s.timeZone&&(u[i]=s.timeZone),u}var SIMPLE_RECURRING_REFINERS={daysOfWeek:identity,startTime:createDuration,endTime:createDuration,duration:createDuration,startRecur:identity,endRecur:identity},recurring={parse:function(e,t){if(e.daysOfWeek||e.startTime||e.endTime||e.startRecur||e.endRecur){var n={daysOfWeek:e.daysOfWeek||null,startTime:e.startTime||null,endTime:e.endTime||null,startRecur:e.startRecur?t.createMarker(e.startRecur):null,endRecur:e.endRecur?t.createMarker(e.endRecur):null},r=void 0;return e.duration&&(r=e.duration),!r&&e.startTime&&e.endTime&&(r=subtractDurations(e.endTime,e.startTime)),{allDayGuess:Boolean(!e.startTime&&!e.endTime),duration:r,typeData:n}}return null},expand:function(e,t,n){var r=intersectRanges(t,{start:e.startRecur,end:e.endRecur});return r?expandRanges(e.daysOfWeek,e.startTime,r,n):[]}},simpleRecurringEventsPlugin=createPlugin({recurringTypes:[recurring],eventRefiners:SIMPLE_RECURRING_REFINERS});function expandRanges(e,t,n,r){for(var o=e?arrayToHash(e):null,i=startOfDay(n.start),a=n.end,s=[];i<a;){var l=void 0;o&&!o[i.getUTCDay()]||(l=t?r.add(i,t):i,s.push(l)),i=addDays(i,1)}return s}var changeHandlerPlugin=createPlugin({optionChangeHandlers:{events:function(e,t){handleEventSources([e],t)},eventSources:handleEventSources}});function handleEventSources(e,t){for(var n=hashValuesToArray(t.getCurrentData().eventSources),r=[],o=0,i=e;o<i.length;o++){for(var a=i[o],s=!1,l=0;l<n.length;l+=1)if(n[l]._raw===a){n.splice(l,1),s=!0;break}s||r.push(a)}for(var u=0,c=n;u<c.length;u++){var d=c[u];t.dispatch({type:"REMOVE_EVENT_SOURCE",sourceId:d.sourceId})}for(var p=0,f=r;p<f.length;p++){var h=f[p];t.calendarApi.addEventSource(h)}}function handleDateProfile(e,t){t.emitter.trigger("datesSet",__assign$1(__assign$1({},buildRangeApiWithTimeZone(e.activeRange,t.dateEnv)),{view:t.viewApi}))}function handleEventStore(e,t){var n=t.emitter;n.hasHandlers("eventsSet")&&n.trigger("eventsSet",buildEventApis(e,t))}var globalPlugins=[arrayEventSourcePlugin,funcEventSourcePlugin,jsonFeedEventSourcePlugin,simpleRecurringEventsPlugin,changeHandlerPlugin,createPlugin({isLoadingFuncs:[function(e){return computeEventSourcesLoading(e.eventSources)}],contentTypeHandlers:{html:buildHtmlRenderer,domNodes:buildDomNodeRenderer},propSetHandlers:{dateProfile:handleDateProfile,eventStore:handleEventStore}})];function buildHtmlRenderer(){var e=null,t="";return{render:function(n,r){n===e&&r===t||(n.innerHTML=r),e=n,t=r},destroy:function(){e.innerHTML="",e=null,t=""}}}function buildDomNodeRenderer(){var e=null,t=[];function n(){t.forEach(removeElement),t=[],e=null}return{render:function(r,o){var i=Array.prototype.slice.call(o);if(r!==e||!isArraysEqual(t,i)){for(var a=0,s=i;a<s.length;a++){var l=s[a];r.appendChild(l)}n()}e=r,t=i},destroy:n}}var DelayedRunner=function(){function e(e){this.drainedOption=e,this.isRunning=!1,this.isDirty=!1,this.pauseDepths={},this.timeoutId=0}return e.prototype.request=function(e){this.isDirty=!0,this.isPaused()||(this.clearTimeout(),null==e?this.tryDrain():this.timeoutId=setTimeout(this.tryDrain.bind(this),e))},e.prototype.pause=function(e){void 0===e&&(e="");var t=this.pauseDepths;t[e]=(t[e]||0)+1,this.clearTimeout()},e.prototype.resume=function(e,t){void 0===e&&(e="");var n=this.pauseDepths;if(e in n){if(t)delete n[e];else n[e]-=1,n[e]<=0&&delete n[e];this.tryDrain()}},e.prototype.isPaused=function(){return Object.keys(this.pauseDepths).length},e.prototype.tryDrain=function(){if(!this.isRunning&&!this.isPaused()){for(this.isRunning=!0;this.isDirty;)this.isDirty=!1,this.drained();this.isRunning=!1}},e.prototype.clear=function(){this.clearTimeout(),this.isDirty=!1,this.pauseDepths={}},e.prototype.clearTimeout=function(){this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=0)},e.prototype.drained=function(){this.drainedOption&&this.drainedOption()},e}(),TaskRunner=function(){function e(e,t){this.runTaskOption=e,this.drainedOption=t,this.queue=[],this.delayedRunner=new DelayedRunner(this.drain.bind(this))}return e.prototype.request=function(e,t){this.queue.push(e),this.delayedRunner.request(t)},e.prototype.pause=function(e){this.delayedRunner.pause(e)},e.prototype.resume=function(e,t){this.delayedRunner.resume(e,t)},e.prototype.drain=function(){for(var e=this.queue;e.length;){for(var t=[],n=void 0;n=e.shift();)this.runTask(n),t.push(n);this.drained(t)}},e.prototype.runTask=function(e){this.runTaskOption&&this.runTaskOption(e)},e.prototype.drained=function(e){this.drainedOption&&this.drainedOption(e)},e}();function buildTitle(e,t,n){var r;return r=/^(year|month)$/.test(e.currentRangeUnit)?e.currentRange:e.activeRange,n.formatRange(r.start,r.end,createFormatter(t.titleFormat||buildTitleFormat(e)),{isEndExclusive:e.isRangeAllDay,defaultSeparator:t.titleRangeSeparator})}function buildTitleFormat(e){var t=e.currentRangeUnit;if("year"===t)return{year:"numeric"};if("month"===t)return{year:"numeric",month:"long"};var n=diffWholeDays(e.currentRange.start,e.currentRange.end);return null!==n&&n>1?{year:"numeric",month:"short",day:"numeric"}:{year:"numeric",month:"long",day:"numeric"}}var CalendarDataManager=function(){function e(e){var t=this;this.computeOptionsData=memoize(this._computeOptionsData),this.computeCurrentViewData=memoize(this._computeCurrentViewData),this.organizeRawLocales=memoize(organizeRawLocales),this.buildLocale=memoize(buildLocale),this.buildPluginHooks=buildBuildPluginHooks(),this.buildDateEnv=memoize(buildDateEnv),this.buildTheme=memoize(buildTheme),this.parseToolbars=memoize(parseToolbars),this.buildViewSpecs=memoize(buildViewSpecs),this.buildDateProfileGenerator=memoizeObjArg(buildDateProfileGenerator),this.buildViewApi=memoize(buildViewApi),this.buildViewUiProps=memoizeObjArg(buildViewUiProps),this.buildEventUiBySource=memoize(buildEventUiBySource,isPropsEqual),this.buildEventUiBases=memoize(buildEventUiBases),this.parseContextBusinessHours=memoizeObjArg(parseContextBusinessHours),this.buildTitle=memoize(buildTitle),this.emitter=new Emitter,this.actionRunner=new TaskRunner(this._handleAction.bind(this),this.updateData.bind(this)),this.currentCalendarOptionsInput={},this.currentCalendarOptionsRefined={},this.currentViewOptionsInput={},this.currentViewOptionsRefined={},this.currentCalendarOptionsRefiners={},this.getCurrentData=function(){return t.data},this.dispatch=function(e){t.actionRunner.request(e)},this.props=e,this.actionRunner.pause();var n={},r=this.computeOptionsData(e.optionOverrides,n,e.calendarApi),o=r.calendarOptions.initialView||r.pluginHooks.initialView,i=this.computeCurrentViewData(o,r,e.optionOverrides,n);e.calendarApi.currentDataManager=this,this.emitter.setThisContext(e.calendarApi),this.emitter.setOptions(i.options);var a=getInitialDate(r.calendarOptions,r.dateEnv),s=i.dateProfileGenerator.build(a);rangeContainsMarker(s.activeRange,a)||(a=s.currentRange.start);for(var l={dateEnv:r.dateEnv,options:r.calendarOptions,pluginHooks:r.pluginHooks,calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},u=0,c=r.pluginHooks.contextInit;u<c.length;u++){(0,c[u])(l)}for(var d=initEventSources(r.calendarOptions,s,l),p={dynamicOptionOverrides:n,currentViewType:o,currentDate:a,dateProfile:s,businessHours:this.parseContextBusinessHours(l),eventSources:d,eventUiBases:{},eventStore:createEmptyEventStore(),renderableEventStore:createEmptyEventStore(),dateSelection:null,eventSelection:"",eventDrag:null,eventResize:null,selectionConfig:this.buildViewUiProps(l).selectionConfig},f=__assign$1(__assign$1({},l),p),h=0,g=r.pluginHooks.reducers;h<g.length;h++){var v=g[h];__assign$1(p,v(null,null,f))}computeIsLoading(p,l)&&this.emitter.trigger("loading",!0),this.state=p,this.updateData(),this.actionRunner.resume()}return e.prototype.resetOptions=function(e,t){var n=this.props;n.optionOverrides=t?__assign$1(__assign$1({},n.optionOverrides),e):e,this.actionRunner.request({type:"NOTHING"})},e.prototype._handleAction=function(e){var t=this,n=t.props,r=t.state,o=t.emitter,i=reduceDynamicOptionOverrides(r.dynamicOptionOverrides,e),a=this.computeOptionsData(n.optionOverrides,i,n.calendarApi),s=reduceViewType(r.currentViewType,e),l=this.computeCurrentViewData(s,a,n.optionOverrides,i);n.calendarApi.currentDataManager=this,o.setThisContext(n.calendarApi),o.setOptions(l.options);var u={dateEnv:a.dateEnv,options:a.calendarOptions,pluginHooks:a.pluginHooks,calendarApi:n.calendarApi,dispatch:this.dispatch,emitter:o,getCurrentData:this.getCurrentData},c=r.currentDate,d=r.dateProfile;this.data&&this.data.dateProfileGenerator!==l.dateProfileGenerator&&(d=l.dateProfileGenerator.build(c)),d=reduceDateProfile(d,e,c=reduceCurrentDate(c,e),l.dateProfileGenerator),"PREV"!==e.type&&"NEXT"!==e.type&&rangeContainsMarker(d.currentRange,c)||(c=d.currentRange.start);for(var p=reduceEventSources(r.eventSources,e,d,u),f=reduceEventStore(r.eventStore,e,p,d,u),h=computeEventSourcesLoading(p)&&!l.options.progressiveEventRendering&&r.renderableEventStore||f,g=this.buildViewUiProps(u),v=g.eventUiSingleBase,m=g.selectionConfig,y=this.buildEventUiBySource(p),E={dynamicOptionOverrides:i,currentViewType:s,currentDate:c,dateProfile:d,eventSources:p,eventStore:f,renderableEventStore:h,selectionConfig:m,eventUiBases:this.buildEventUiBases(h.defs,v,y),businessHours:this.parseContextBusinessHours(u),dateSelection:reduceDateSelection(r.dateSelection,e),eventSelection:reduceSelectedEvent(r.eventSelection,e),eventDrag:reduceEventDrag(r.eventDrag,e),eventResize:reduceEventResize(r.eventResize,e)},S=__assign$1(__assign$1({},u),E),D=0,T=a.pluginHooks.reducers;D<T.length;D++){var b=T[D];__assign$1(E,b(r,e,S))}var w=computeIsLoading(r,u),C=computeIsLoading(E,u);!w&&C?o.trigger("loading",!0):w&&!C&&o.trigger("loading",!1),this.state=E,n.onAction&&n.onAction(e)},e.prototype.updateData=function(){var e=this.props,t=this.state,n=this.data,r=this.computeOptionsData(e.optionOverrides,t.dynamicOptionOverrides,e.calendarApi),o=this.computeCurrentViewData(t.currentViewType,r,e.optionOverrides,t.dynamicOptionOverrides),i=this.data=__assign$1(__assign$1(__assign$1({viewTitle:this.buildTitle(t.dateProfile,o.options,r.dateEnv),calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},r),o),t),a=r.pluginHooks.optionChangeHandlers,s=n&&n.calendarOptions,l=r.calendarOptions;if(s&&s!==l)for(var u in s.timeZone!==l.timeZone&&(t.eventSources=i.eventSources=reduceEventSourcesNewTimeZone(i.eventSources,t.dateProfile,i),t.eventStore=i.eventStore=rezoneEventStoreDates(i.eventStore,n.dateEnv,i.dateEnv)),a)s[u]!==l[u]&&a[u](l[u],i);e.onData&&e.onData(i)},e.prototype._computeOptionsData=function(e,t,n){var r=this.processRawCalendarOptions(e,t),o=r.refinedOptions,i=r.pluginHooks,a=r.localeDefaults,s=r.availableLocaleData;warnUnknownOptions(r.extra);var l=this.buildDateEnv(o.timeZone,o.locale,o.weekNumberCalculation,o.firstDay,o.weekText,i,s,o.defaultRangeSeparator),u=this.buildViewSpecs(i.views,e,t,a),c=this.buildTheme(o,i);return{calendarOptions:o,pluginHooks:i,dateEnv:l,viewSpecs:u,theme:c,toolbarConfig:this.parseToolbars(o,e,c,u,n),localeDefaults:a,availableRawLocales:s.map}},e.prototype.processRawCalendarOptions=function(e,t){var n=mergeRawOptions([BASE_OPTION_DEFAULTS,e,t]),r=n.locales,o=n.locale,i=this.organizeRawLocales(r),a=i.map,s=this.buildLocale(o||i.defaultCode,a).options,l=this.buildPluginHooks(e.plugins||[],globalPlugins),u=this.currentCalendarOptionsRefiners=__assign$1(__assign$1(__assign$1(__assign$1(__assign$1({},BASE_OPTION_REFINERS),CALENDAR_LISTENER_REFINERS),CALENDAR_OPTION_REFINERS),l.listenerRefiners),l.optionRefiners),c={},d=mergeRawOptions([BASE_OPTION_DEFAULTS,s,e,t]),p={},f=this.currentCalendarOptionsInput,h=this.currentCalendarOptionsRefined,g=!1;for(var v in d)"plugins"!==v&&(d[v]===f[v]||COMPLEX_OPTION_COMPARATORS[v]&&v in f&&COMPLEX_OPTION_COMPARATORS[v](f[v],d[v])?p[v]=h[v]:u[v]?(p[v]=u[v](d[v]),g=!0):c[v]=f[v]);return g&&(this.currentCalendarOptionsInput=d,this.currentCalendarOptionsRefined=p),{rawOptions:this.currentCalendarOptionsInput,refinedOptions:this.currentCalendarOptionsRefined,pluginHooks:l,availableLocaleData:i,localeDefaults:s,extra:c}},e.prototype._computeCurrentViewData=function(e,t,n,r){var o=t.viewSpecs[e];if(!o)throw new Error('viewType "'+e+"\" is not available. Please make sure you've loaded all neccessary plugins");var i=this.processRawViewOptions(o,t.pluginHooks,t.localeDefaults,n,r),a=i.refinedOptions;return warnUnknownOptions(i.extra),{viewSpec:o,options:a,dateProfileGenerator:this.buildDateProfileGenerator({dateProfileGeneratorClass:o.optionDefaults.dateProfileGeneratorClass,duration:o.duration,durationUnit:o.durationUnit,usesMinMaxTime:o.optionDefaults.usesMinMaxTime,dateEnv:t.dateEnv,calendarApi:this.props.calendarApi,slotMinTime:a.slotMinTime,slotMaxTime:a.slotMaxTime,showNonCurrentDates:a.showNonCurrentDates,dayCount:a.dayCount,dateAlignment:a.dateAlignment,dateIncrement:a.dateIncrement,hiddenDays:a.hiddenDays,weekends:a.weekends,nowInput:a.now,validRangeInput:a.validRange,visibleRangeInput:a.visibleRange,monthMode:a.monthMode,fixedWeekCount:a.fixedWeekCount}),viewApi:this.buildViewApi(e,this.getCurrentData,t.dateEnv)}},e.prototype.processRawViewOptions=function(e,t,n,r,o){var i=mergeRawOptions([BASE_OPTION_DEFAULTS,e.optionDefaults,n,r,e.optionOverrides,o]),a=__assign$1(__assign$1(__assign$1(__assign$1(__assign$1(__assign$1({},BASE_OPTION_REFINERS),CALENDAR_LISTENER_REFINERS),CALENDAR_OPTION_REFINERS),VIEW_OPTION_REFINERS),t.listenerRefiners),t.optionRefiners),s={},l=this.currentViewOptionsInput,u=this.currentViewOptionsRefined,c=!1,d={};for(var p in i)i[p]===l[p]||COMPLEX_OPTION_COMPARATORS[p]&&COMPLEX_OPTION_COMPARATORS[p](i[p],l[p])?s[p]=u[p]:(i[p]===this.currentCalendarOptionsInput[p]||COMPLEX_OPTION_COMPARATORS[p]&&COMPLEX_OPTION_COMPARATORS[p](i[p],this.currentCalendarOptionsInput[p])?p in this.currentCalendarOptionsRefined&&(s[p]=this.currentCalendarOptionsRefined[p]):a[p]?s[p]=a[p](i[p]):d[p]=i[p],c=!0);return c&&(this.currentViewOptionsInput=i,this.currentViewOptionsRefined=s),{rawOptions:this.currentViewOptionsInput,refinedOptions:this.currentViewOptionsRefined,extra:d}},e}();function buildDateEnv(e,t,n,r,o,i,a,s){var l=buildLocale(t||a.defaultCode,a.map);return new DateEnv({calendarSystem:"gregory",timeZone:e,namedTimeZoneImpl:i.namedTimeZonedImpl,locale:l,weekNumberCalculation:n,firstDay:r,weekText:o,cmdFormatter:i.cmdFormatter,defaultSeparator:s})}function buildTheme(e,t){return new(t.themeClasses[e.themeSystem]||StandardTheme)(e)}function buildDateProfileGenerator(e){return new(e.dateProfileGeneratorClass||DateProfileGenerator)(e)}function buildViewApi(e,t,n){return new ViewApi(e,t,n)}function buildEventUiBySource(e){return mapHash(e,(function(e){return e.ui}))}function buildEventUiBases(e,t,n){var r={"":t};for(var o in e){var i=e[o];i.sourceId&&n[i.sourceId]&&(r[o]=n[i.sourceId])}return r}function buildViewUiProps(e){var t=e.options;return{eventUiSingleBase:createEventUi({display:t.eventDisplay,editable:t.editable,startEditable:t.eventStartEditable,durationEditable:t.eventDurationEditable,constraint:t.eventConstraint,overlap:"boolean"==typeof t.eventOverlap?t.eventOverlap:void 0,allow:t.eventAllow,backgroundColor:t.eventBackgroundColor,borderColor:t.eventBorderColor,textColor:t.eventTextColor,color:t.eventColor},e),selectionConfig:createEventUi({constraint:t.selectConstraint,overlap:"boolean"==typeof t.selectOverlap?t.selectOverlap:void 0,allow:t.selectAllow},e)}}function computeIsLoading(e,t){for(var n=0,r=t.pluginHooks.isLoadingFuncs;n<r.length;n++){if((0,r[n])(e))return!0}return!1}function parseContextBusinessHours(e){return parseBusinessHours(e.options.businessHours,e)}function warnUnknownOptions(e,t){for(var n in e)console.warn("Unknown option '"+n+"'"+(t?" for view '"+t+"'":""))}var CalendarDataProvider=function(e){function t(t){var n=e.call(this,t)||this;return n.handleData=function(e){n.dataManager?n.setState(e):n.state=e},n.dataManager=new CalendarDataManager({optionOverrides:t.optionOverrides,calendarApi:t.calendarApi,onData:n.handleData}),n}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.state)},t.prototype.componentDidUpdate=function(e){var t=this.props.optionOverrides;t!==e.optionOverrides&&this.dataManager.resetOptions(t)},t}(Component),SegHierarchy=function(){function e(){this.strictOrder=!1,this.allowReslicing=!1,this.maxCoord=-1,this.maxStackCnt=-1,this.levelCoords=[],this.entriesByLevel=[],this.stackCnts={}}return e.prototype.addSegs=function(e){for(var t=[],n=0,r=e;n<r.length;n++){var o=r[n];this.insertEntry(o,t)}return t},e.prototype.insertEntry=function(e,t){var n=this.findInsertion(e);return this.isInsertionValid(n,e)?(this.insertEntryAt(e,n),1):this.handleInvalidInsertion(n,e,t)},e.prototype.isInsertionValid=function(e,t){return(-1===this.maxCoord||e.levelCoord+t.thickness<=this.maxCoord)&&(-1===this.maxStackCnt||e.stackCnt<this.maxStackCnt)},e.prototype.handleInvalidInsertion=function(e,t,n){return this.allowReslicing&&e.touchingEntry?this.splitEntry(t,e.touchingEntry,n):(n.push(t),0)},e.prototype.splitEntry=function(e,t,n){var r=0,o=[],i=e.span,a=t.span;return i.start<a.start&&(r+=this.insertEntry({index:e.index,thickness:e.thickness,span:{start:i.start,end:a.start}},o)),i.end>a.end&&(r+=this.insertEntry({index:e.index,thickness:e.thickness,span:{start:a.end,end:i.end}},o)),r?(n.push.apply(n,__spreadArray([{index:e.index,thickness:e.thickness,span:intersectSpans(a,i)}],o)),r):(n.push(e),0)},e.prototype.insertEntryAt=function(e,t){var n=this.entriesByLevel,r=this.levelCoords;-1===t.lateral?(insertAt(r,t.level,t.levelCoord),insertAt(n,t.level,[e])):insertAt(n[t.level],t.lateral,e),this.stackCnts[buildEntryKey(e)]=t.stackCnt},e.prototype.findInsertion=function(e){for(var t=this,n=t.levelCoords,r=t.entriesByLevel,o=t.strictOrder,i=t.stackCnts,a=n.length,s=0,l=-1,u=-1,c=null,d=0,p=0;p<a;p+=1){var f=n[p];if(!o&&f>=s+e.thickness)break;for(var h=r[p],g=void 0,v=binarySearch(h,e.span.start,getEntrySpanEnd),m=v[0]+v[1];(g=h[m])&&g.span.start<e.span.end;){var y=f+g.thickness;y>s&&(s=y,c=g,l=p,u=m),y===s&&(d=Math.max(d,i[buildEntryKey(g)]+1)),m+=1}}var E=0;if(c)for(E=l+1;E<a&&n[E]<s;)E+=1;var S=-1;return E<a&&n[E]===s&&(S=binarySearch(r[E],e.span.end,getEntrySpanEnd)[0]),{touchingLevel:l,touchingLateral:u,touchingEntry:c,stackCnt:d,levelCoord:s,level:E,lateral:S}},e.prototype.toRects=function(){for(var e=this.entriesByLevel,t=this.levelCoords,n=e.length,r=[],o=0;o<n;o+=1)for(var i=e[o],a=t[o],s=0,l=i;s<l.length;s++){var u=l[s];r.push(__assign$1(__assign$1({},u),{levelCoord:a}))}return r},e}();function getEntrySpanEnd(e){return e.span.end}function buildEntryKey(e){return e.index+":"+e.span.start}function groupIntersectingEntries(e){for(var t=[],n=0,r=e;n<r.length;n++){for(var o=r[n],i=[],a={span:o.span,entries:[o]},s=0,l=t;s<l.length;s++){var u=l[s];intersectSpans(u.span,a.span)?a={entries:u.entries.concat(a.entries),span:joinSpans(u.span,a.span)}:i.push(u)}i.push(a),t=i}return t}function joinSpans(e,t){return{start:Math.min(e.start,t.start),end:Math.max(e.end,t.end)}}function intersectSpans(e,t){var n=Math.max(e.start,t.start),r=Math.min(e.end,t.end);return n<r?{start:n,end:r}:null}function insertAt(e,t,n){e.splice(t,0,n)}function binarySearch(e,t,n){var r=0,o=e.length;if(!o||t<n(e[r]))return[0,0];if(t>n(e[o-1]))return[o,0];for(;r<o;){var i=Math.floor(r+(o-r)/2),a=n(e[i]);if(t<a)o=i;else{if(!(t>a))return[i,1];r=i+1}}return[r,0]}var Interaction=function(){function e(e){this.component=e.component,this.isHitComboAllowed=e.isHitComboAllowed||null}return e.prototype.destroy=function(){},e}();function parseInteractionSettings(e,t){return{component:e,el:t.el,useEventCenter:null==t.useEventCenter||t.useEventCenter,isHitComboAllowed:t.isHitComboAllowed||null}}function interactionSettingsToStore(e){var t;return(t={})[e.component.uid]=e,t}var interactionSettingsStore={},ElementDragging=function(){function e(e,t){this.emitter=new Emitter}return e.prototype.destroy=function(){},e.prototype.setMirrorIsVisible=function(e){},e.prototype.setMirrorNeedsRevert=function(e){},e.prototype.setAutoScrollEnabled=function(e){},e}(),config={},ToolbarSection=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props.widgetGroups.map((function(t){return e.renderWidgetGroup(t)}));return createElement.apply(void 0,__spreadArray(["div",{className:"fc-toolbar-chunk"}],t))},t.prototype.renderWidgetGroup=function(e){for(var t=this.props,n=this.context.theme,r=[],o=!0,i=0,a=e;i<a.length;i++){var s=a[i],l=s.buttonName,u=s.buttonClick,c=s.buttonText,d=s.buttonIcon,p=s.buttonHint;if("title"===l)o=!1,r.push(createElement("h2",{className:"fc-toolbar-title",id:t.titleId},t.title));else{var f=l===t.activeButton,h=!t.isTodayEnabled&&"today"===l||!t.isPrevEnabled&&"prev"===l||!t.isNextEnabled&&"next"===l,g=["fc-"+l+"-button",n.getClass("button")];f&&g.push(n.getClass("buttonActive")),r.push(createElement("button",{type:"button",title:"function"==typeof p?p(t.navUnit):p,disabled:h,"aria-pressed":f,className:g.join(" "),onClick:u},c||(d?createElement("span",{className:d}):"")))}}if(r.length>1){var v=o&&n.getClass("buttonGroup")||"";return createElement.apply(void 0,__spreadArray(["div",{className:v}],r))}return r[0]},t}(BaseComponent),Toolbar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e,t,n=this.props,r=n.model,o=n.extraClassName,i=!1,a=r.sectionWidgets,s=a.center;return a.left?(i=!0,e=a.left):e=a.start,a.right?(i=!0,t=a.right):t=a.end,createElement("div",{className:[o||"","fc-toolbar",i?"fc-toolbar-ltr":""].join(" ")},this.renderSection("start",e||[]),this.renderSection("center",s||[]),this.renderSection("end",t||[]))},t.prototype.renderSection=function(e,t){var n=this.props;return createElement(ToolbarSection,{key:e,widgetGroups:t,title:n.title,navUnit:n.navUnit,activeButton:n.activeButton,isTodayEnabled:n.isTodayEnabled,isPrevEnabled:n.isPrevEnabled,isNextEnabled:n.isNextEnabled,titleId:n.titleId})},t}(BaseComponent),ViewContainer=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={availableWidth:null},t.handleEl=function(e){t.el=e,setRef(t.props.elRef,e),t.updateAvailableWidth()},t.handleResize=function(){t.updateAvailableWidth()},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state,n=e.aspectRatio,r=["fc-view-harness",n||e.liquid||e.height?"fc-view-harness-active":"fc-view-harness-passive"],o="",i="";return n?null!==t.availableWidth?o=t.availableWidth/n:i=1/n*100+"%":o=e.height||"",createElement("div",{"aria-labelledby":e.labeledById,ref:this.handleEl,className:r.join(" "),style:{height:o,paddingBottom:i}},e.children)},t.prototype.componentDidMount=function(){this.context.addResizeHandler(this.handleResize)},t.prototype.componentWillUnmount=function(){this.context.removeResizeHandler(this.handleResize)},t.prototype.updateAvailableWidth=function(){this.el&&this.props.aspectRatio&&this.setState({availableWidth:this.el.offsetWidth})},t}(BaseComponent),EventClicking=function(e){function t(t){var n=e.call(this,t)||this;return n.handleSegClick=function(e,t){var r=n.component,o=r.context,i=getElSeg(t);if(i&&r.isValidSegDownEl(e.target)){var a=elementClosest(e.target,".fc-event-forced-url"),s=a?a.querySelector("a[href]").href:"";o.emitter.trigger("eventClick",{el:t,event:new EventApi(r.context,i.eventRange.def,i.eventRange.instance),jsEvent:e,view:o.viewApi}),s&&!e.defaultPrevented&&(window.location.href=s)}},n.destroy=listenBySelector(t.el,"click",".fc-event",n.handleSegClick),n}return __extends(t,e),t}(Interaction),EventHovering=function(e){function t(t){var n=e.call(this,t)||this;return n.handleEventElRemove=function(e){e===n.currentSegEl&&n.handleSegLeave(null,n.currentSegEl)},n.handleSegEnter=function(e,t){getElSeg(t)&&(n.currentSegEl=t,n.triggerEvent("eventMouseEnter",e,t))},n.handleSegLeave=function(e,t){n.currentSegEl&&(n.currentSegEl=null,n.triggerEvent("eventMouseLeave",e,t))},n.removeHoverListeners=listenToHoverBySelector(t.el,".fc-event",n.handleSegEnter,n.handleSegLeave),n}return __extends(t,e),t.prototype.destroy=function(){this.removeHoverListeners()},t.prototype.triggerEvent=function(e,t,n){var r=this.component,o=r.context,i=getElSeg(n);t&&!r.isValidSegDownEl(t.target)||o.emitter.trigger(e,{el:n,event:new EventApi(o,i.eventRange.def,i.eventRange.instance),jsEvent:t,view:o.viewApi})},t}(Interaction),CalendarContent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildViewContext=memoize(buildViewContext),t.buildViewPropTransformers=memoize(buildViewPropTransformers),t.buildToolbarProps=memoize(buildToolbarProps),t.headerRef=createRef(),t.footerRef=createRef(),t.interactionsStore={},t.state={viewLabelId:getUniqueDomId()},t.registerInteractiveComponent=function(e,n){var r=parseInteractionSettings(e,n),o=[EventClicking,EventHovering].concat(t.props.pluginHooks.componentInteractions).map((function(e){return new e(r)}));t.interactionsStore[e.uid]=o,interactionSettingsStore[e.uid]=r},t.unregisterInteractiveComponent=function(e){var n=t.interactionsStore[e.uid];if(n){for(var r=0,o=n;r<o.length;r++){o[r].destroy()}delete t.interactionsStore[e.uid]}delete interactionSettingsStore[e.uid]},t.resizeRunner=new DelayedRunner((function(){t.props.emitter.trigger("_resize",!0),t.props.emitter.trigger("windowResize",{view:t.props.viewApi})})),t.handleWindowResize=function(e){var n=t.props.options;n.handleWindowResize&&e.target===window&&t.resizeRunner.request(n.windowResizeDelay)},t}return __extends(t,e),t.prototype.render=function(){var e,t=this.props,n=t.toolbarConfig,r=t.options,o=this.buildToolbarProps(t.viewSpec,t.dateProfile,t.dateProfileGenerator,t.currentDate,getNow(t.options.now,t.dateEnv),t.viewTitle),i=!1,a="";t.isHeightAuto||t.forPrint?a="":null!=r.height?i=!0:null!=r.contentHeight?a=r.contentHeight:e=Math.max(r.aspectRatio,.5);var s=this.buildViewContext(t.viewSpec,t.viewApi,t.options,t.dateProfileGenerator,t.dateEnv,t.theme,t.pluginHooks,t.dispatch,t.getCurrentData,t.emitter,t.calendarApi,this.registerInteractiveComponent,this.unregisterInteractiveComponent),l=n.header&&n.header.hasTitle?this.state.viewLabelId:"";return createElement(ViewContextType.Provider,{value:s},n.header&&createElement(Toolbar,__assign$1({ref:this.headerRef,extraClassName:"fc-header-toolbar",model:n.header,titleId:l},o)),createElement(ViewContainer,{liquid:i,height:a,aspectRatio:e,labeledById:l},this.renderView(t),this.buildAppendContent()),n.footer&&createElement(Toolbar,__assign$1({ref:this.footerRef,extraClassName:"fc-footer-toolbar",model:n.footer,titleId:""},o)))},t.prototype.componentDidMount=function(){var e=this.props;this.calendarInteractions=e.pluginHooks.calendarInteractions.map((function(t){return new t(e)})),window.addEventListener("resize",this.handleWindowResize);var t=e.pluginHooks.propSetHandlers;for(var n in t)t[n](e[n],e)},t.prototype.componentDidUpdate=function(e){var t=this.props,n=t.pluginHooks.propSetHandlers;for(var r in n)t[r]!==e[r]&&n[r](t[r],t)},t.prototype.componentWillUnmount=function(){window.removeEventListener("resize",this.handleWindowResize),this.resizeRunner.clear();for(var e=0,t=this.calendarInteractions;e<t.length;e++){t[e].destroy()}this.props.emitter.trigger("_unmount")},t.prototype.buildAppendContent=function(){var e=this.props,t=e.pluginHooks.viewContainerAppends.map((function(t){return t(e)}));return createElement.apply(void 0,__spreadArray([Fragment,{}],t))},t.prototype.renderView=function(e){for(var t=e.pluginHooks,n=e.viewSpec,r={dateProfile:e.dateProfile,businessHours:e.businessHours,eventStore:e.renderableEventStore,eventUiBases:e.eventUiBases,dateSelection:e.dateSelection,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,isHeightAuto:e.isHeightAuto,forPrint:e.forPrint},o=0,i=this.buildViewPropTransformers(t.viewPropsTransformers);o<i.length;o++){var a=i[o];__assign$1(r,a.transform(r,e))}var s=n.component;return createElement(s,__assign$1({},r))},t}(PureComponent);function buildToolbarProps(e,t,n,r,o,i){var a=n.build(o,void 0,!1),s=n.buildPrev(t,r,!1),l=n.buildNext(t,r,!1);return{title:i,activeButton:e.type,navUnit:e.singleUnit,isTodayEnabled:a.isValid&&!rangeContainsMarker(t.currentRange,o),isPrevEnabled:s.isValid,isNextEnabled:l.isValid}}function buildViewPropTransformers(e){return e.map((function(e){return new e}))}var CalendarRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={forPrint:!1},t.handleBeforePrint=function(){t.setState({forPrint:!0})},t.handleAfterPrint=function(){t.setState({forPrint:!1})},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=e.options,n=this.state.forPrint,r=n||"auto"===t.height||"auto"===t.contentHeight,o=r||null==t.height?"":t.height,i=["fc",n?"fc-media-print":"fc-media-screen","fc-direction-"+t.direction,e.theme.getClass("root")];return getCanVGrowWithinCell()||i.push("fc-liquid-hack"),e.children(i,o,r,n)},t.prototype.componentDidMount=function(){var e=this.props.emitter;e.on("_beforeprint",this.handleBeforePrint),e.on("_afterprint",this.handleAfterPrint)},t.prototype.componentWillUnmount=function(){var e=this.props.emitter;e.off("_beforeprint",this.handleBeforePrint),e.off("_afterprint",this.handleAfterPrint)},t}(BaseComponent);function computeFallbackHeaderFormat(e,t){return createFormatter(!e||t>10?{weekday:"short"}:t>1?{weekday:"short",month:"numeric",day:"numeric",omitCommas:!0}:{weekday:"long"})}var CLASS_NAME="fc-col-header-cell";function renderInner$1(e){return e.text}var TableDateCell=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.dateEnv,n=e.options,r=e.theme,o=e.viewApi,i=this.props,a=i.date,s=i.dateProfile,l=getDateMeta(a,i.todayRange,null,s),u=[CLASS_NAME].concat(getDayClassNames(l,r)),c=t.format(a,i.dayHeaderFormat),d=!l.isDisabled&&i.colCnt>1?buildNavLinkAttrs(this.context,a):{},p=__assign$1(__assign$1(__assign$1({date:t.toDate(a),view:o},i.extraHookProps),{text:c}),l);return createElement(RenderHook,{hookProps:p,classNames:n.dayHeaderClassNames,content:n.dayHeaderContent,defaultContent:renderInner$1,didMount:n.dayHeaderDidMount,willUnmount:n.dayHeaderWillUnmount},(function(e,t,n,r){return createElement("th",__assign$1({ref:e,role:"columnheader",className:u.concat(t).join(" "),"data-date":l.isDisabled?void 0:formatDayString(a),colSpan:i.colSpan},i.extraDataAttrs),createElement("div",{className:"fc-scrollgrid-sync-inner"},!l.isDisabled&&createElement("a",__assign$1({ref:n,className:["fc-col-header-cell-cushion",i.isSticky?"fc-sticky":""].join(" ")},d),r)))}))},t}(BaseComponent),WEEKDAY_FORMAT=createFormatter({weekday:"long"}),TableDowCell=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.dateEnv,r=t.theme,o=t.viewApi,i=t.options,a=addDays(new Date(2592e5),e.dow),s={dow:e.dow,isDisabled:!1,isFuture:!1,isPast:!1,isToday:!1,isOther:!1},l=[CLASS_NAME].concat(getDayClassNames(s,r),e.extraClassNames||[]),u=n.format(a,e.dayHeaderFormat),c=__assign$1(__assign$1(__assign$1(__assign$1({date:a},s),{view:o}),e.extraHookProps),{text:u});return createElement(RenderHook,{hookProps:c,classNames:i.dayHeaderClassNames,content:i.dayHeaderContent,defaultContent:renderInner$1,didMount:i.dayHeaderDidMount,willUnmount:i.dayHeaderWillUnmount},(function(t,r,o,i){return createElement("th",__assign$1({ref:t,role:"columnheader",className:l.concat(r).join(" "),colSpan:e.colSpan},e.extraDataAttrs),createElement("div",{className:"fc-scrollgrid-sync-inner"},createElement("a",{"aria-label":n.format(a,WEEKDAY_FORMAT),className:["fc-col-header-cell-cushion",e.isSticky?"fc-sticky":""].join(" "),ref:o},i)))}))},t}(BaseComponent),NowTimer=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.initialNowDate=getNow(n.options.now,n.dateEnv),r.initialNowQueriedMs=(new Date).valueOf(),r.state=r.computeTiming().currentState,r}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state;return e.children(t.nowDate,t.todayRange)},t.prototype.componentDidMount=function(){this.setTimeout()},t.prototype.componentDidUpdate=function(e){e.unit!==this.props.unit&&(this.clearTimeout(),this.setTimeout())},t.prototype.componentWillUnmount=function(){this.clearTimeout()},t.prototype.computeTiming=function(){var e=this.props,t=this.context,n=addMs(this.initialNowDate,(new Date).valueOf()-this.initialNowQueriedMs),r=t.dateEnv.startOf(n,e.unit),o=t.dateEnv.add(r,createDuration(1,e.unit)),i=o.valueOf()-n.valueOf();return i=Math.min(864e5,i),{currentState:{nowDate:r,todayRange:buildDayRange(r)},nextState:{nowDate:o,todayRange:buildDayRange(o)},waitMs:i}},t.prototype.setTimeout=function(){var e=this,t=this.computeTiming(),n=t.nextState,r=t.waitMs;this.timeoutId=setTimeout((function(){e.setState(n,(function(){e.setTimeout()}))}),r)},t.prototype.clearTimeout=function(){this.timeoutId&&clearTimeout(this.timeoutId)},t.contextType=ViewContextType,t}(Component);function buildDayRange(e){var t=startOfDay(e);return{start:t,end:addDays(t,1)}}var DayHeader=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.createDayHeaderFormatter=memoize(createDayHeaderFormatter),t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=this.props,n=t.dates,r=t.dateProfile,o=t.datesRepDistinctDays,i=t.renderIntro,a=this.createDayHeaderFormatter(e.options.dayHeaderFormat,o,n.length);return createElement(NowTimer,{unit:"day"},(function(e,t){return createElement("tr",{role:"row"},i&&i("day"),n.map((function(e){return o?createElement(TableDateCell,{key:e.toISOString(),date:e,dateProfile:r,todayRange:t,colCnt:n.length,dayHeaderFormat:a}):createElement(TableDowCell,{key:e.getUTCDay(),dow:e.getUTCDay(),dayHeaderFormat:a})})))}))},t}(BaseComponent);function createDayHeaderFormatter(e,t,n){return e||computeFallbackHeaderFormat(t,n)}var DaySeriesModel=function(){function e(e,t){for(var n=e.start,r=e.end,o=[],i=[],a=-1;n<r;)t.isHiddenDay(n)?o.push(a+.5):(a+=1,o.push(a),i.push(n)),n=addDays(n,1);this.dates=i,this.indices=o,this.cnt=i.length}return e.prototype.sliceRange=function(e){var t=this.getDateDayIndex(e.start),n=this.getDateDayIndex(addDays(e.end,-1)),r=Math.max(0,t),o=Math.min(this.cnt-1,n);return(r=Math.ceil(r))<=(o=Math.floor(o))?{firstIndex:r,lastIndex:o,isStart:t===r,isEnd:n===o}:null},e.prototype.getDateDayIndex=function(e){var t=this.indices,n=Math.floor(diffDays(this.dates[0],e));return n<0?t[0]-1:n>=t.length?t[t.length-1]+1:t[n]},e}(),DayTableModel=function(){function e(e,t){var n,r,o,i=e.dates;if(t){for(r=i[0].getUTCDay(),n=1;n<i.length&&i[n].getUTCDay()!==r;n+=1);o=Math.ceil(i.length/n)}else o=1,n=i.length;this.rowCnt=o,this.colCnt=n,this.daySeries=e,this.cells=this.buildCells(),this.headerDates=this.buildHeaderDates()}return e.prototype.buildCells=function(){for(var e=[],t=0;t<this.rowCnt;t+=1){for(var n=[],r=0;r<this.colCnt;r+=1)n.push(this.buildCell(t,r));e.push(n)}return e},e.prototype.buildCell=function(e,t){var n=this.daySeries.dates[e*this.colCnt+t];return{key:n.toISOString(),date:n}},e.prototype.buildHeaderDates=function(){for(var e=[],t=0;t<this.colCnt;t+=1)e.push(this.cells[0][t].date);return e},e.prototype.sliceRange=function(e){var t=this.colCnt,n=this.daySeries.sliceRange(e),r=[];if(n)for(var o=n.firstIndex,i=n.lastIndex,a=o;a<=i;){var s=Math.floor(a/t),l=Math.min((s+1)*t,i+1);r.push({row:s,firstCol:a%t,lastCol:(l-1)%t,isStart:n.isStart&&a===o,isEnd:n.isEnd&&l-1===i}),a=l}return r},e}(),Slicer=function(){function e(){this.sliceBusinessHours=memoize(this._sliceBusinessHours),this.sliceDateSelection=memoize(this._sliceDateSpan),this.sliceEventStore=memoize(this._sliceEventStore),this.sliceEventDrag=memoize(this._sliceInteraction),this.sliceEventResize=memoize(this._sliceInteraction),this.forceDayIfListItem=!1}return e.prototype.sliceProps=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];var a=e.eventUiBases,s=this.sliceEventStore.apply(this,__spreadArray([e.eventStore,a,t,n],o));return{dateSelectionSegs:this.sliceDateSelection.apply(this,__spreadArray([e.dateSelection,a,r],o)),businessHourSegs:this.sliceBusinessHours.apply(this,__spreadArray([e.businessHours,t,n,r],o)),fgEventSegs:s.fg,bgEventSegs:s.bg,eventDrag:this.sliceEventDrag.apply(this,__spreadArray([e.eventDrag,a,t,n],o)),eventResize:this.sliceEventResize.apply(this,__spreadArray([e.eventResize,a,t,n],o)),eventSelection:e.eventSelection}},e.prototype.sliceNowDate=function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return this._sliceDateSpan.apply(this,__spreadArray([{range:{start:e,end:addMs(e,1)},allDay:!1},{},t],n))},e.prototype._sliceBusinessHours=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];return e?this._sliceEventStore.apply(this,__spreadArray([expandRecurring(e,computeActiveRange(t,Boolean(n)),r),{},t,n],o)).bg:[]},e.prototype._sliceEventStore=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];if(e){var a=sliceEventStore(e,t,computeActiveRange(n,Boolean(r)),r);return{bg:this.sliceEventRanges(a.bg,o),fg:this.sliceEventRanges(a.fg,o)}}return{bg:[],fg:[]}},e.prototype._sliceInteraction=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];if(!e)return null;var a=sliceEventStore(e.mutatedEvents,t,computeActiveRange(n,Boolean(r)),r);return{segs:this.sliceEventRanges(a.fg,o),affectedInstances:e.affectedEvents.instances,isEvent:e.isEvent}},e.prototype._sliceDateSpan=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];if(!e)return[];for(var i=fabricateEventRange(e,t,n),a=this.sliceRange.apply(this,__spreadArray([e.range],r)),s=0,l=a;s<l.length;s++){var u=l[s];u.eventRange=i}return a},e.prototype.sliceEventRanges=function(e,t){for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];n.push.apply(n,this.sliceEventRange(i,t))}return n},e.prototype.sliceEventRange=function(e,t){var n=e.range;this.forceDayIfListItem&&"list-item"===e.ui.display&&(n={start:n.start,end:addDays(n.start,1)});for(var r=this.sliceRange.apply(this,__spreadArray([n],t)),o=0,i=r;o<i.length;o++){var a=i[o];a.eventRange=e,a.isStart=e.isStart&&a.isStart,a.isEnd=e.isEnd&&a.isEnd}return r},e}();function computeActiveRange(e,t){var n=e.activeRange;return t?n:{start:addMs(n.start,e.slotMinTime.milliseconds),end:addMs(n.end,e.slotMaxTime.milliseconds-864e5)}}function isInteractionValid(e,t,n){var r=e.mutatedEvents.instances;for(var o in r)if(!rangeContainsRange(t.validRange,r[o].range))return!1;return isNewPropsValid({eventDrag:e},n)}function isDateSelectionValid(e,t,n){return!!rangeContainsRange(t.validRange,e.range)&&isNewPropsValid({dateSelection:e},n)}function isNewPropsValid(e,t){var n=t.getCurrentData(),r=__assign$1({businessHours:n.businessHours,dateSelection:"",eventStore:n.eventStore,eventUiBases:n.eventUiBases,eventSelection:"",eventDrag:null,eventResize:null},e);return(t.pluginHooks.isPropsValid||isPropsValid)(r,t)}function isPropsValid(e,t,n,r){return void 0===n&&(n={}),!(e.eventDrag&&!isInteractionPropsValid(e,t,n,r))&&!(e.dateSelection&&!isDateSelectionPropsValid(e,t,n,r))}function isInteractionPropsValid(e,t,n,r){var o=t.getCurrentData(),i=e.eventDrag,a=i.mutatedEvents,s=a.defs,l=a.instances,u=compileEventUis(s,i.isEvent?e.eventUiBases:{"":o.selectionConfig});r&&(u=mapHash(u,r));var c=excludeInstances(e.eventStore,i.affectedEvents.instances),d=c.defs,p=c.instances,f=compileEventUis(d,e.eventUiBases);for(var h in l){var g=l[h],v=g.range,m=u[g.defId],y=s[g.defId];if(!allConstraintsPass(m.constraints,v,c,e.businessHours,t))return!1;var E=t.options.eventOverlap,S="function"==typeof E?E:null;for(var D in p){var T=p[D];if(rangesIntersect(v,T.range)){if(!1===f[T.defId].overlap&&i.isEvent)return!1;if(!1===m.overlap)return!1;if(S&&!S(new EventApi(t,d[T.defId],T),new EventApi(t,y,g)))return!1}}for(var b=o.eventStore,w=0,C=m.allows;w<C.length;w++){var R=C[w],_=__assign$1(__assign$1({},n),{range:g.range,allDay:y.allDay}),x=b.defs[y.defId],k=b.instances[h],M=void 0;if(M=x?new EventApi(t,x,k):new EventApi(t,y),!R(buildDateSpanApiWithContext(_,t),M))return!1}}return!0}function isDateSelectionPropsValid(e,t,n,r){var o=e.eventStore,i=o.defs,a=o.instances,s=e.dateSelection,l=s.range,u=t.getCurrentData().selectionConfig;if(r&&(u=r(u)),!allConstraintsPass(u.constraints,l,o,e.businessHours,t))return!1;var c=t.options.selectOverlap,d="function"==typeof c?c:null;for(var p in a){var f=a[p];if(rangesIntersect(l,f.range)){if(!1===u.overlap)return!1;if(d&&!d(new EventApi(t,i[f.defId],f),null))return!1}}for(var h=0,g=u.allows;h<g.length;h++){if(!(0,g[h])(buildDateSpanApiWithContext(__assign$1(__assign$1({},n),s),t),null))return!1}return!0}function allConstraintsPass(e,t,n,r,o){for(var i=0,a=e;i<a.length;i++){if(!anyRangesContainRange(constraintToRanges(a[i],t,n,r,o),t))return!1}return!0}function constraintToRanges(e,t,n,r,o){return"businessHours"===e?eventStoreToRanges(expandRecurring(r,t,o)):"string"==typeof e?eventStoreToRanges(filterEventStoreDefs(n,(function(t){return t.groupId===e}))):"object"==typeof e&&e?eventStoreToRanges(expandRecurring(e,t,o)):[]}function eventStoreToRanges(e){var t=e.instances,n=[];for(var r in t)n.push(t[r].range);return n}function anyRangesContainRange(e,t){for(var n=0,r=e;n<r.length;n++){if(rangeContainsRange(r[n],t))return!0}return!1}var VISIBLE_HIDDEN_RE=/^(visible|hidden)$/,Scroller=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleEl=function(e){t.el=e,setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=e.liquid,n=e.liquidIsAbsolute,r=t&&n,o=["fc-scroller"];return t&&(n?o.push("fc-scroller-liquid-absolute"):o.push("fc-scroller-liquid")),createElement("div",{ref:this.handleEl,className:o.join(" "),style:{overflowX:e.overflowX,overflowY:e.overflowY,left:r&&-(e.overcomeLeft||0)||"",right:r&&-(e.overcomeRight||0)||"",bottom:r&&-(e.overcomeBottom||0)||"",marginLeft:!r&&-(e.overcomeLeft||0)||"",marginRight:!r&&-(e.overcomeRight||0)||"",marginBottom:!r&&-(e.overcomeBottom||0)||"",maxHeight:e.maxHeight||""}},e.children)},t.prototype.needsXScrolling=function(){if(VISIBLE_HIDDEN_RE.test(this.props.overflowX))return!1;for(var e=this.el,t=this.el.getBoundingClientRect().width-this.getYScrollbarWidth(),n=e.children,r=0;r<n.length;r+=1){if(n[r].getBoundingClientRect().width>t)return!0}return!1},t.prototype.needsYScrolling=function(){if(VISIBLE_HIDDEN_RE.test(this.props.overflowY))return!1;for(var e=this.el,t=this.el.getBoundingClientRect().height-this.getXScrollbarWidth(),n=e.children,r=0;r<n.length;r+=1){if(n[r].getBoundingClientRect().height>t)return!0}return!1},t.prototype.getXScrollbarWidth=function(){return VISIBLE_HIDDEN_RE.test(this.props.overflowX)?0:this.el.offsetHeight-this.el.clientHeight},t.prototype.getYScrollbarWidth=function(){return VISIBLE_HIDDEN_RE.test(this.props.overflowY)?0:this.el.offsetWidth-this.el.clientWidth},t}(BaseComponent),RefMap=function(){function e(e){var t=this;this.masterCallback=e,this.currentMap={},this.depths={},this.callbackMap={},this.handleValue=function(e,n){var r=t,o=r.depths,i=r.currentMap,a=!1,s=!1;null!==e?(a=n in i,i[n]=e,o[n]=(o[n]||0)+1,s=!0):(o[n]-=1,o[n]||(delete i[n],delete t.callbackMap[n],a=!0)),t.masterCallback&&(a&&t.masterCallback(null,String(n)),s&&t.masterCallback(e,String(n)))}}return e.prototype.createRef=function(e){var t=this,n=this.callbackMap[e];return n||(n=this.callbackMap[e]=function(n){t.handleValue(n,String(e))}),n},e.prototype.collect=function(e,t,n){return collectFromHash(this.currentMap,e,t,n)},e.prototype.getAll=function(){return hashValuesToArray(this.currentMap)},e}();function computeShrinkWidth(e){for(var t=0,n=0,r=findElements(e,".fc-scrollgrid-shrink");n<r.length;n++){var o=r[n];t=Math.max(t,computeSmallestCellWidth(o))}return Math.ceil(t)}function getSectionHasLiquidHeight(e,t){return e.liquid&&t.liquid}function getAllowYScrolling(e,t){return null!=t.maxHeight||getSectionHasLiquidHeight(e,t)}function renderChunkContent(e,t,n,r){var o=n.expandRows;return"function"==typeof t.content?t.content(n):createElement("table",{role:"presentation",className:[t.tableClassName,e.syncRowHeights?"fc-scrollgrid-sync-table":""].join(" "),style:{minWidth:n.tableMinWidth,width:n.clientWidth,height:o?n.clientHeight:""}},n.tableColGroupNode,createElement(r?"thead":"tbody",{role:"presentation"},"function"==typeof t.rowContent?t.rowContent(n):t.rowContent))}function isColPropsEqual(e,t){return isArraysEqual(e,t,isPropsEqual)}function renderMicroColGroup(e,t){for(var n=[],r=0,o=e;r<o.length;r++)for(var i=o[r],a=i.span||1,s=0;s<a;s+=1)n.push(createElement("col",{style:{width:"shrink"===i.width?sanitizeShrinkWidth(t):i.width||"",minWidth:i.minWidth||""}}));return createElement.apply(void 0,__spreadArray(["colgroup",{}],n))}function sanitizeShrinkWidth(e){return null==e?4:e}function hasShrinkWidth(e){for(var t=0,n=e;t<n.length;t++){if("shrink"===n[t].width)return!0}return!1}function getScrollGridClassNames(e,t){var n=["fc-scrollgrid",t.theme.getClass("table")];return e&&n.push("fc-scrollgrid-liquid"),n}function getSectionClassNames(e,t){var n=["fc-scrollgrid-section","fc-scrollgrid-section-"+e.type,e.className];return t&&e.liquid&&null==e.maxHeight&&n.push("fc-scrollgrid-section-liquid"),e.isSticky&&n.push("fc-scrollgrid-section-sticky"),n}function renderScrollShim(e){return createElement("div",{className:"fc-scrollgrid-sticky-shim",style:{width:e.clientWidth,minWidth:e.tableMinWidth}})}function getStickyHeaderDates(e){var t=e.stickyHeaderDates;return null!=t&&"auto"!==t||(t="auto"===e.height||"auto"===e.viewHeight),t}function getStickyFooterScrollbar(e){var t=e.stickyFooterScrollbar;return null!=t&&"auto"!==t||(t="auto"===e.height||"auto"===e.viewHeight),t}var SimpleScrollGrid=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.processCols=memoize((function(e){return e}),isColPropsEqual),t.renderMicroColGroup=memoize(renderMicroColGroup),t.scrollerRefs=new RefMap,t.scrollerElRefs=new RefMap(t._handleScrollerEl.bind(t)),t.state={shrinkWidth:null,forceYScrollbars:!1,scrollerClientWidths:{},scrollerClientHeights:{}},t.handleSizing=function(){t.safeSetState(__assign$1({shrinkWidth:t.computeShrinkWidth()},t.computeScrollerDims()))},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=e.props,n=e.state,r=e.context,o=t.sections||[],i=this.processCols(t.cols),a=this.renderMicroColGroup(i,n.shrinkWidth),s=getScrollGridClassNames(t.liquid,r);t.collapsibleWidth&&s.push("fc-scrollgrid-collapsible");for(var l,u=o.length,c=0,d=[],p=[],f=[];c<u&&"header"===(l=o[c]).type;)d.push(this.renderSection(l,a,!0)),c+=1;for(;c<u&&"body"===(l=o[c]).type;)p.push(this.renderSection(l,a,!1)),c+=1;for(;c<u&&"footer"===(l=o[c]).type;)f.push(this.renderSection(l,a,!0)),c+=1;var h=!getCanVGrowWithinCell(),g={role:"rowgroup"};return createElement("table",{role:"grid",className:s.join(" "),style:{height:t.height}},Boolean(!h&&d.length)&&createElement.apply(void 0,__spreadArray(["thead",g],d)),Boolean(!h&&p.length)&&createElement.apply(void 0,__spreadArray(["tbody",g],p)),Boolean(!h&&f.length)&&createElement.apply(void 0,__spreadArray(["tfoot",g],f)),h&&createElement.apply(void 0,__spreadArray(__spreadArray(__spreadArray(["tbody",g],d),p),f)))},t.prototype.renderSection=function(e,t,n){return"outerContent"in e?createElement(Fragment,{key:e.key},e.outerContent):createElement("tr",{key:e.key,role:"presentation",className:getSectionClassNames(e,this.props.liquid).join(" ")},this.renderChunkTd(e,t,e.chunk,n))},t.prototype.renderChunkTd=function(e,t,n,r){if("outerContent"in n)return n.outerContent;var o=this.props,i=this.state,a=i.forceYScrollbars,s=i.scrollerClientWidths,l=i.scrollerClientHeights,u=getAllowYScrolling(o,e),c=getSectionHasLiquidHeight(o,e),d=o.liquid?a?"scroll":u?"auto":"hidden":"visible",p=e.key,f=renderChunkContent(e,n,{tableColGroupNode:t,tableMinWidth:"",clientWidth:o.collapsibleWidth||void 0===s[p]?null:s[p],clientHeight:void 0!==l[p]?l[p]:null,expandRows:e.expandRows,syncRowHeights:!1,rowSyncHeights:[],reportRowHeightChange:function(){}},r);return createElement(r?"th":"td",{ref:n.elRef,role:"presentation"},createElement("div",{className:"fc-scroller-harness"+(c?" fc-scroller-harness-liquid":"")},createElement(Scroller,{ref:this.scrollerRefs.createRef(p),elRef:this.scrollerElRefs.createRef(p),overflowY:d,overflowX:o.liquid?"hidden":"visible",maxHeight:e.maxHeight,liquid:c,liquidIsAbsolute:!0},f)))},t.prototype._handleScrollerEl=function(e,t){var n=getSectionByKey(this.props.sections,t);n&&setRef(n.chunk.scrollerElRef,e)},t.prototype.componentDidMount=function(){this.handleSizing(),this.context.addResizeHandler(this.handleSizing)},t.prototype.componentDidUpdate=function(){this.handleSizing()},t.prototype.componentWillUnmount=function(){this.context.removeResizeHandler(this.handleSizing)},t.prototype.computeShrinkWidth=function(){return hasShrinkWidth(this.props.cols)?computeShrinkWidth(this.scrollerElRefs.getAll()):0},t.prototype.computeScrollerDims=function(){var e=getScrollbarWidths(),t=this.scrollerRefs,n=this.scrollerElRefs,r=!1,o={},i={};for(var a in t.currentMap){var s=t.currentMap[a];if(s&&s.needsYScrolling()){r=!0;break}}for(var l=0,u=this.props.sections;l<u.length;l++){a=u[l].key;var c=n.currentMap[a];if(c){var d=c.parentNode;o[a]=Math.floor(d.getBoundingClientRect().width-(r?e.y:0)),i[a]=Math.floor(d.getBoundingClientRect().height)}}return{forceYScrollbars:r,scrollerClientWidths:o,scrollerClientHeights:i}},t}(BaseComponent);function getSectionByKey(e,t){for(var n=0,r=e;n<r.length;n++){var o=r[n];if(o.key===t)return o}return null}SimpleScrollGrid.addStateEquality({scrollerClientWidths:isPropsEqual,scrollerClientHeights:isPropsEqual});var EventRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.elRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=e.seg,o=r.eventRange,i=o.ui,a={event:new EventApi(t,o.def,o.instance),view:t.viewApi,timeText:e.timeText,textColor:i.textColor,backgroundColor:i.backgroundColor,borderColor:i.borderColor,isDraggable:!e.disableDragging&&computeSegDraggable(r,t),isStartResizable:!e.disableResizing&&computeSegStartResizable(r,t),isEndResizable:!e.disableResizing&&computeSegEndResizable(r),isMirror:Boolean(e.isDragging||e.isResizing||e.isDateSelecting),isStart:Boolean(r.isStart),isEnd:Boolean(r.isEnd),isPast:Boolean(e.isPast),isFuture:Boolean(e.isFuture),isToday:Boolean(e.isToday),isSelected:Boolean(e.isSelected),isDragging:Boolean(e.isDragging),isResizing:Boolean(e.isResizing)},s=getEventClassNames(a).concat(i.classNames);return createElement(RenderHook,{hookProps:a,classNames:n.eventClassNames,content:n.eventContent,defaultContent:e.defaultContent,didMount:n.eventDidMount,willUnmount:n.eventWillUnmount,elRef:this.elRef},(function(t,n,r,o){return e.children(t,s.concat(n),r,o,a)}))},t.prototype.componentDidMount=function(){setElSeg(this.elRef.current,this.props.seg)},t.prototype.componentDidUpdate=function(e){var t=this.props.seg;t!==e.seg&&setElSeg(this.elRef.current,t)},t}(BaseComponent),StandardEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=e.seg,r=t.options.eventTimeFormat||e.defaultTimeFormat,o=buildSegTimeText(n,r,t,e.defaultDisplayEventTime,e.defaultDisplayEventEnd);return createElement(EventRoot,{seg:n,timeText:o,disableDragging:e.disableDragging,disableResizing:e.disableResizing,defaultContent:e.defaultContent||renderInnerContent$1$1,isDragging:e.isDragging,isResizing:e.isResizing,isDateSelecting:e.isDateSelecting,isSelected:e.isSelected,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(r,o,i,a,s){return createElement("a",__assign$1({className:e.extraClassNames.concat(o).join(" "),style:{borderColor:s.borderColor,backgroundColor:s.backgroundColor},ref:r},getSegAnchorAttrs(n,t)),createElement("div",{className:"fc-event-main",ref:i,style:{color:s.textColor}},a),s.isStartResizable&&createElement("div",{className:"fc-event-resizer fc-event-resizer-start"}),s.isEndResizable&&createElement("div",{className:"fc-event-resizer fc-event-resizer-end"}))}))},t}(BaseComponent);function renderInnerContent$1$1(e){return createElement("div",{className:"fc-event-main-frame"},e.timeText&&createElement("div",{className:"fc-event-time"},e.timeText),createElement("div",{className:"fc-event-title-container"},createElement("div",{className:"fc-event-title fc-sticky"},e.event.title||createElement(Fragment,null," "))))}var NowIndicatorRoot=function(e){return createElement(ViewContextType.Consumer,null,(function(t){var n=t.options,r={isAxis:e.isAxis,date:t.dateEnv.toDate(e.date),view:t.viewApi};return createElement(RenderHook,{hookProps:r,classNames:n.nowIndicatorClassNames,content:n.nowIndicatorContent,didMount:n.nowIndicatorDidMount,willUnmount:n.nowIndicatorWillUnmount},e.children)}))},DAY_NUM_FORMAT=createFormatter({day:"numeric"}),DayCellContent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=refineDayCellHookProps({date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraProps:e.extraHookProps,viewApi:t.viewApi,dateEnv:t.dateEnv});return createElement(ContentHook,{hookProps:r,content:n.dayCellContent,defaultContent:e.defaultContent},e.children)},t}(BaseComponent);function refineDayCellHookProps(e){var t=e.date,n=e.dateEnv,r=getDateMeta(t,e.todayRange,null,e.dateProfile);return __assign$1(__assign$1(__assign$1({date:n.toDate(t),view:e.viewApi},r),{dayNumberText:e.showDayNumber?n.format(t,DAY_NUM_FORMAT):""}),e.extraProps)}var DayCellRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.refineHookProps=memoizeObjArg(refineDayCellHookProps),t.normalizeClassNames=buildClassNameNormalizer(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=this.refineHookProps({date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraProps:e.extraHookProps,viewApi:t.viewApi,dateEnv:t.dateEnv}),o=getDayClassNames(r,t.theme).concat(r.isDisabled?[]:this.normalizeClassNames(n.dayCellClassNames,r)),i=r.isDisabled?{}:{"data-date":formatDayString(e.date)};return createElement(MountHook,{hookProps:r,didMount:n.dayCellDidMount,willUnmount:n.dayCellWillUnmount,elRef:e.elRef},(function(t){return e.children(t,o,i,r.isDisabled)}))},t}(BaseComponent);function renderFill(e){return createElement("div",{className:"fc-"+e})}var BgEvent=function(e){return createElement(EventRoot,{defaultContent:renderInnerContent$3,seg:e.seg,timeText:"",disableDragging:!0,disableResizing:!0,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:!1,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(e,t,n,r,o){return createElement("div",{ref:e,className:["fc-bg-event"].concat(t).join(" "),style:{backgroundColor:o.backgroundColor}},r)}))};function renderInnerContent$3(e){return e.event.title&&createElement("div",{className:"fc-event-title"},e.event.title)}var WeekNumberRoot=function(e){return createElement(ViewContextType.Consumer,null,(function(t){var n=t.dateEnv,r=t.options,o=e.date,i=r.weekNumberFormat||e.defaultFormat,a=n.computeWeekNumber(o),s=n.format(o,i);return createElement(RenderHook,{hookProps:{num:a,text:s,date:o},classNames:r.weekNumberClassNames,content:r.weekNumberContent,defaultContent:renderInner,didMount:r.weekNumberDidMount,willUnmount:r.weekNumberWillUnmount},e.children)}))};function renderInner(e){return e.text}var PADDING_FROM_VIEWPORT=10,Popover=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={titleId:getUniqueDomId()},t.handleRootEl=function(e){t.rootEl=e,t.props.elRef&&setRef(t.props.elRef,e)},t.handleDocumentMouseDown=function(e){var n=getEventTargetViaRoot(e);t.rootEl.contains(n)||t.handleCloseClick()},t.handleDocumentKeyDown=function(e){"Escape"===e.key&&t.handleCloseClick()},t.handleCloseClick=function(){var e=t.props.onClose;e&&e()},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.theme,n=e.options,r=this.props,o=this.state,i=["fc-popover",t.getClass("popover")].concat(r.extraClassNames||[]);return createPortal(createElement("div",__assign$1({id:r.id,className:i.join(" "),"aria-labelledby":o.titleId},r.extraAttrs,{ref:this.handleRootEl}),createElement("div",{className:"fc-popover-header "+t.getClass("popoverHeader")},createElement("span",{className:"fc-popover-title",id:o.titleId},r.title),createElement("span",{className:"fc-popover-close "+t.getIconClass("close"),title:n.closeHint,onClick:this.handleCloseClick})),createElement("div",{className:"fc-popover-body "+t.getClass("popoverContent")},r.children)),r.parentEl)},t.prototype.componentDidMount=function(){document.addEventListener("mousedown",this.handleDocumentMouseDown),document.addEventListener("keydown",this.handleDocumentKeyDown),this.updateSize()},t.prototype.componentWillUnmount=function(){document.removeEventListener("mousedown",this.handleDocumentMouseDown),document.removeEventListener("keydown",this.handleDocumentKeyDown)},t.prototype.updateSize=function(){var e=this.context.isRtl,t=this.props,n=t.alignmentEl,r=t.alignGridTop,o=this.rootEl,i=computeClippedClientRect(n);if(i){var a=o.getBoundingClientRect(),s=r?elementClosest(n,".fc-scrollgrid").getBoundingClientRect().top:i.top,l=e?i.right-a.width:i.left;s=Math.max(s,PADDING_FROM_VIEWPORT),l=Math.min(l,document.documentElement.clientWidth-PADDING_FROM_VIEWPORT-a.width),l=Math.max(l,PADDING_FROM_VIEWPORT);var u=o.offsetParent.getBoundingClientRect();applyStyle(o,{top:s-u.top,left:l-u.left})}},t}(BaseComponent),MorePopover=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleRootEl=function(e){t.rootEl=e,e?t.context.registerInteractiveComponent(t,{el:e,useEventCenter:!1}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.options,n=e.dateEnv,r=this.props,o=r.startDate,i=r.todayRange,a=r.dateProfile,s=n.format(o,t.dayPopoverFormat);return createElement(DayCellRoot,{date:o,dateProfile:a,todayRange:i,elRef:this.handleRootEl},(function(e,t,n){return createElement(Popover,{elRef:e,id:r.id,title:s,extraClassNames:["fc-more-popover"].concat(t),extraAttrs:n,parentEl:r.parentEl,alignmentEl:r.alignmentEl,alignGridTop:r.alignGridTop,onClose:r.onClose},createElement(DayCellContent,{date:o,dateProfile:a,todayRange:i},(function(e,t){return t&&createElement("div",{className:"fc-more-popover-misc",ref:e},t)})),r.children)}))},t.prototype.queryHit=function(e,t,n,r){var o=this.rootEl,i=this.props;return e>=0&&e<n&&t>=0&&t<r?{dateProfile:i.dateProfile,dateSpan:__assign$1({allDay:!0,range:{start:i.startDate,end:i.endDate}},i.extraDateSpan),dayEl:o,rect:{left:0,top:0,right:n,bottom:r},layer:1}:null},t}(DateComponent),MoreLinkRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.linkElRef=createRef(),t.state={isPopoverOpen:!1,popoverId:getUniqueDomId()},t.handleClick=function(e){var n=t,r=n.props,o=n.context,i=o.options.moreLinkClick,a=computeRange(r).start;function s(e){var t=e.eventRange,n=t.def,r=t.instance,i=t.range;return{event:new EventApi(o,n,r),start:o.dateEnv.toDate(i.start),end:o.dateEnv.toDate(i.end),isStart:e.isStart,isEnd:e.isEnd}}"function"==typeof i&&(i=i({date:a,allDay:Boolean(r.allDayDate),allSegs:r.allSegs.map(s),hiddenSegs:r.hiddenSegs.map(s),jsEvent:e,view:o.viewApi})),i&&"popover"!==i?"string"==typeof i&&o.calendarApi.zoomTo(a,i):t.setState({isPopoverOpen:!0})},t.handlePopoverClose=function(){t.setState({isPopoverOpen:!1})},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.state;return createElement(ViewContextType.Consumer,null,(function(r){var o=r.viewApi,i=r.options,a=r.calendarApi,s=i.moreLinkText,l=t.moreCnt,u=computeRange(t),c="function"==typeof s?s.call(a,l):"+"+l+" "+s,d=formatWithOrdinals(i.moreLinkHint,[l],c),p={num:l,shortText:"+"+l,text:c,view:o};return createElement(Fragment,null,Boolean(t.moreCnt)&&createElement(RenderHook,{elRef:e.linkElRef,hookProps:p,classNames:i.moreLinkClassNames,content:i.moreLinkContent,defaultContent:t.defaultContent||renderMoreLinkInner$1,didMount:i.moreLinkDidMount,willUnmount:i.moreLinkWillUnmount},(function(r,o,i,a){return t.children(r,["fc-more-link"].concat(o),i,a,e.handleClick,d,n.isPopoverOpen,n.isPopoverOpen?n.popoverId:"")})),n.isPopoverOpen&&createElement(MorePopover,{id:n.popoverId,startDate:u.start,endDate:u.end,dateProfile:t.dateProfile,todayRange:t.todayRange,extraDateSpan:t.extraDateSpan,parentEl:e.parentEl,alignmentEl:t.alignmentElRef.current,alignGridTop:t.alignGridTop,onClose:e.handlePopoverClose},t.popoverContent()))}))},t.prototype.componentDidMount=function(){this.updateParentEl()},t.prototype.componentDidUpdate=function(){this.updateParentEl()},t.prototype.updateParentEl=function(){this.linkElRef.current&&(this.parentEl=elementClosest(this.linkElRef.current,".fc-view-harness"))},t}(BaseComponent);function renderMoreLinkInner$1(e){return e.text}function computeRange(e){if(e.allDayDate)return{start:e.allDayDate,end:addDays(e.allDayDate,1)};var t=e.hiddenSegs;return{start:computeEarliestSegStart(t),end:computeLatestSegEnd(t)}}function computeEarliestSegStart(e){return e.reduce(pickEarliestStart).eventRange.range.start}function pickEarliestStart(e,t){return e.eventRange.range.start<t.eventRange.range.start?e:t}function computeLatestSegEnd(e){return e.reduce(pickLatestEnd).eventRange.range.end}function pickLatestEnd(e,t){return e.eventRange.range.end>t.eventRange.range.end?e:t}var FullCalendar$1=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._calendarApi=new CalendarApi,t}return __extends(t,e),t.prototype.render=function(){return React__namespace.createElement(CalendarDataProvider,{optionOverrides:this.props,calendarApi:this._calendarApi},(function(e){return React__namespace.createElement(CalendarRoot,{options:e.calendarOptions,theme:e.theme,emitter:e.emitter},(function(t,n,r,o){return React__namespace.createElement("div",{className:t.join(" "),style:{height:n}},React__namespace.createElement(CalendarContent,__assign$1({isHeightAuto:r,forPrint:o},e)))}))}))},t.prototype.getApi=function(){return this._calendarApi},t}(React__namespace.Component),TableView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.headerElRef=createRef(),t}return __extends(t,e),t.prototype.renderSimpleLayout=function(e,t){var n=this.props,r=this.context,o=[],i=getStickyHeaderDates(r.options);return e&&o.push({type:"header",key:"header",isSticky:i,chunk:{elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}}),o.push({type:"body",key:"body",liquid:!0,chunk:{content:t}}),createElement(ViewRoot,{viewSpec:r.viewSpec},(function(e,t){return createElement("div",{ref:e,className:["fc-daygrid"].concat(t).join(" ")},createElement(SimpleScrollGrid,{liquid:!n.isHeightAuto&&!n.forPrint,collapsibleWidth:n.forPrint,cols:[],sections:o}))}))},t.prototype.renderHScrollLayout=function(e,t,n,r){var o=this.context.pluginHooks.scrollGridImpl;if(!o)throw new Error("No ScrollGrid implementation");var i=this.props,a=this.context,s=!i.forPrint&&getStickyHeaderDates(a.options),l=!i.forPrint&&getStickyFooterScrollbar(a.options),u=[];return e&&u.push({type:"header",key:"header",isSticky:s,chunks:[{key:"main",elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}]}),u.push({type:"body",key:"body",liquid:!0,chunks:[{key:"main",content:t}]}),l&&u.push({type:"footer",key:"footer",isSticky:!0,chunks:[{key:"main",content:renderScrollShim}]}),createElement(ViewRoot,{viewSpec:a.viewSpec},(function(e,t){return createElement("div",{ref:e,className:["fc-daygrid"].concat(t).join(" ")},createElement(o,{liquid:!i.isHeightAuto&&!i.forPrint,collapsibleWidth:i.forPrint,colGroups:[{cols:[{span:n,minWidth:r}]}],sections:u}))}))},t}(DateComponent);
7
+ var EventSourceApi=function(){function e(e,t){this.context=e,this.internalEventSource=t}return e.prototype.remove=function(){this.context.dispatch({type:"REMOVE_EVENT_SOURCE",sourceId:this.internalEventSource.sourceId})},e.prototype.refetch=function(){this.context.dispatch({type:"FETCH_EVENT_SOURCES",sourceIds:[this.internalEventSource.sourceId],isRefetch:!0})},Object.defineProperty(e.prototype,"id",{get:function(){return this.internalEventSource.publicId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this.internalEventSource.meta.url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"format",{get:function(){return this.internalEventSource.meta.format},enumerable:!1,configurable:!0}),e}();function removeElement(e){e.parentNode&&e.parentNode.removeChild(e)}function elementClosest(e,t){if(e.closest)return e.closest(t);if(!document.documentElement.contains(e))return null;do{if(elementMatches(e,t))return e;e=e.parentElement||e.parentNode}while(null!==e&&1===e.nodeType);return null}function elementMatches(e,t){return(e.matches||e.matchesSelector||e.msMatchesSelector).call(e,t)}function findElements(e,t){for(var n=e instanceof HTMLElement?[e]:e,r=[],o=0;o<n.length;o+=1)for(var i=n[o].querySelectorAll(t),a=0;a<i.length;a+=1)r.push(i[a]);return r}var PIXEL_PROP_RE=/(top|left|right|bottom|width|height)$/i;function applyStyle(e,t){for(var n in t)applyStyleProp(e,n,t[n])}function applyStyleProp(e,t,n){null==n?e.style[t]="":"number"==typeof n&&PIXEL_PROP_RE.test(t)?e.style[t]=n+"px":e.style[t]=n}function getEventTargetViaRoot(e){var t,n;return null!==(n=null===(t=e.composedPath)||void 0===t?void 0:t.call(e)[0])&&void 0!==n?n:e.target}function getElRoot(e){return e.getRootNode?e.getRootNode():document}var guid$1=0;function getUniqueDomId(){return"fc-dom-"+(guid$1+=1)}function preventDefault(e){e.preventDefault()}function buildDelegationHandler(e,t){return function(n){var r=elementClosest(n.target,e);r&&t.call(r,n,r)}}function listenBySelector(e,t,n,r){var o=buildDelegationHandler(n,r);return e.addEventListener(t,o),function(){e.removeEventListener(t,o)}}function listenToHoverBySelector(e,t,n,r){var o;return listenBySelector(e,"mouseover",t,(function(e,t){if(t!==o){o=t,n(e,t);var i=function(e){o=null,r(e,t),t.removeEventListener("mouseleave",i)};t.addEventListener("mouseleave",i)}}))}var transitionEventNames=["webkitTransitionEnd","otransitionend","oTransitionEnd","msTransitionEnd","transitionend"];function whenTransitionDone(e,t){var n=function(r){t(r),transitionEventNames.forEach((function(t){e.removeEventListener(t,n)}))};transitionEventNames.forEach((function(t){e.addEventListener(t,n)}))}function createAriaClickAttrs(e){return __assign$1({onClick:e},createAriaKeyboardAttrs(e))}function createAriaKeyboardAttrs(e){return{tabIndex:0,onKeyDown:function(t){"Enter"!==t.key&&" "!==t.key||(e(t),t.preventDefault())}}}var guidNumber=0;function guid(){return String(guidNumber+=1)}function disableCursor(){document.body.classList.add("fc-not-allowed")}function enableCursor(){document.body.classList.remove("fc-not-allowed")}function preventSelection(e){e.classList.add("fc-unselectable"),e.addEventListener("selectstart",preventDefault)}function allowSelection(e){e.classList.remove("fc-unselectable"),e.removeEventListener("selectstart",preventDefault)}function preventContextMenu(e){e.addEventListener("contextmenu",preventDefault)}function allowContextMenu(e){e.removeEventListener("contextmenu",preventDefault)}function parseFieldSpecs(e){var t,n,r=[],o=[];for("string"==typeof e?o=e.split(/\s*,\s*/):"function"==typeof e?o=[e]:Array.isArray(e)&&(o=e),t=0;t<o.length;t+=1)"string"==typeof(n=o[t])?r.push("-"===n.charAt(0)?{field:n.substring(1),order:-1}:{field:n,order:1}):"function"==typeof n&&r.push({func:n});return r}function compareByFieldSpecs(e,t,n){var r,o;for(r=0;r<n.length;r+=1)if(o=compareByFieldSpec(e,t,n[r]))return o;return 0}function compareByFieldSpec(e,t,n){return n.func?n.func(e,t):flexibleCompare(e[n.field],t[n.field])*(n.order||1)}function flexibleCompare(e,t){return e||t?null==t?-1:null==e?1:"string"==typeof e||"string"==typeof t?String(e).localeCompare(String(t)):e-t:0}function padStart(e,t){var n=String(e);return"000".substr(0,t-n.length)+n}function formatWithOrdinals(e,t,n){return"function"==typeof e?e.apply(void 0,t):"string"==typeof e?t.reduce((function(e,t,n){return e.replace("$"+n,t||"")}),e):n}function compareNumbers(e,t){return e-t}function isInt(e){return e%1==0}function computeSmallestCellWidth(e){var t=e.querySelector(".fc-scrollgrid-shrink-frame"),n=e.querySelector(".fc-scrollgrid-shrink-cushion");if(!t)throw new Error("needs fc-scrollgrid-shrink-frame className");if(!n)throw new Error("needs fc-scrollgrid-shrink-cushion className");return e.getBoundingClientRect().width-t.getBoundingClientRect().width+n.getBoundingClientRect().width}var DAY_IDS=["sun","mon","tue","wed","thu","fri","sat"];function addWeeks(e,t){var n=dateToUtcArray(e);return n[2]+=7*t,arrayToUtcDate(n)}function addDays(e,t){var n=dateToUtcArray(e);return n[2]+=t,arrayToUtcDate(n)}function addMs(e,t){var n=dateToUtcArray(e);return n[6]+=t,arrayToUtcDate(n)}function diffWeeks(e,t){return diffDays(e,t)/7}function diffDays(e,t){return(t.valueOf()-e.valueOf())/864e5}function diffHours(e,t){return(t.valueOf()-e.valueOf())/36e5}function diffMinutes(e,t){return(t.valueOf()-e.valueOf())/6e4}function diffSeconds(e,t){return(t.valueOf()-e.valueOf())/1e3}function diffDayAndTime(e,t){var n=startOfDay(e),r=startOfDay(t);return{years:0,months:0,days:Math.round(diffDays(n,r)),milliseconds:t.valueOf()-r.valueOf()-(e.valueOf()-n.valueOf())}}function diffWholeWeeks(e,t){var n=diffWholeDays(e,t);return null!==n&&n%7==0?n/7:null}function diffWholeDays(e,t){return timeAsMs(e)===timeAsMs(t)?Math.round(diffDays(e,t)):null}function startOfDay(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()])}function startOfHour(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours()])}function startOfMinute(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes()])}function startOfSecond(e){return arrayToUtcDate([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds()])}function weekOfYear(e,t,n){var r=e.getUTCFullYear(),o=weekOfGivenYear(e,r,t,n);if(o<1)return weekOfGivenYear(e,r-1,t,n);var i=weekOfGivenYear(e,r+1,t,n);return i>=1?Math.min(o,i):o}function weekOfGivenYear(e,t,n,r){var o=arrayToUtcDate([t,0,1+firstWeekOffset(t,n,r)]),i=startOfDay(e),a=Math.round(diffDays(o,i));return Math.floor(a/7)+1}function firstWeekOffset(e,t,n){var r=7+t-n;return-((7+arrayToUtcDate([e,0,r]).getUTCDay()-t)%7)+r-1}function dateToLocalArray(e){return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()]}function arrayToLocalDate(e){return new Date(e[0],e[1]||0,null==e[2]?1:e[2],e[3]||0,e[4]||0,e[5]||0)}function dateToUtcArray(e){return[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()]}function arrayToUtcDate(e){return 1===e.length&&(e=e.concat([0])),new Date(Date.UTC.apply(Date,e))}function isValidDate(e){return!isNaN(e.valueOf())}function timeAsMs(e){return 1e3*e.getUTCHours()*60*60+1e3*e.getUTCMinutes()*60+1e3*e.getUTCSeconds()+e.getUTCMilliseconds()}function createEventInstance(e,t,n,r){return{instanceId:guid(),defId:e,range:t,forcedStartTzo:null==n?null:n,forcedEndTzo:null==r?null:r}}var hasOwnProperty=Object.prototype.hasOwnProperty;function mergeProps(e,t){var n={};if(t)for(var r in t){for(var o=[],i=e.length-1;i>=0;i-=1){var a=e[i][r];if("object"==typeof a&&a)o.unshift(a);else if(void 0!==a){n[r]=a;break}}o.length&&(n[r]=mergeProps(o))}for(i=e.length-1;i>=0;i-=1){var s=e[i];for(var l in s)l in n||(n[l]=s[l])}return n}function filterHash(e,t){var n={};for(var r in e)t(e[r],r)&&(n[r]=e[r]);return n}function mapHash(e,t){var n={};for(var r in e)n[r]=t(e[r],r);return n}function arrayToHash(e){for(var t={},n=0,r=e;n<r.length;n++){t[r[n]]=!0}return t}function hashValuesToArray(e){var t=[];for(var n in e)t.push(e[n]);return t}function isPropsEqual(e,t){if(e===t)return!0;for(var n in e)if(hasOwnProperty.call(e,n)&&!(n in t))return!1;for(var n in t)if(hasOwnProperty.call(t,n)&&e[n]!==t[n])return!1;return!0}function getUnequalProps(e,t){var n=[];for(var r in e)hasOwnProperty.call(e,r)&&(r in t||n.push(r));for(var r in t)hasOwnProperty.call(t,r)&&e[r]!==t[r]&&n.push(r);return n}function compareObjs(e,t,n){if(void 0===n&&(n={}),e===t)return!0;for(var r in t)if(!(r in e)||!isObjValsEqual(e[r],t[r],n[r]))return!1;for(var r in e)if(!(r in t))return!1;return!0}function isObjValsEqual(e,t,n){return e===t||!0===n||!!n&&n(e,t)}function collectFromHash(e,t,n,r){void 0===t&&(t=0),void 0===r&&(r=1);var o=[];null==n&&(n=Object.keys(e).length);for(var i=t;i<n;i+=r){var a=e[i];void 0!==a&&o.push(a)}return o}function parseRecurring(e,t,n,r){for(var o=0;o<r.length;o+=1){var i=r[o].parse(e,n);if(i){var a=e.allDay;return null==a&&null==(a=t)&&null==(a=i.allDayGuess)&&(a=!1),{allDay:a,duration:i.duration,typeData:i.typeData,typeId:o}}}return null}function expandRecurring(e,t,n){var r=n.dateEnv,o=n.pluginHooks,i=n.options,a=e.defs,s=e.instances;for(var l in s=filterHash(s,(function(e){return!a[e.defId].recurringDef})),a){var u=a[l];if(u.recurringDef){var c=u.recurringDef.duration;c||(c=u.allDay?i.defaultAllDayEventDuration:i.defaultTimedEventDuration);for(var d=0,p=expandRecurringRanges(u,c,t,r,o.recurringTypes);d<p.length;d++){var f=p[d],h=createEventInstance(l,{start:f,end:r.add(f,c)});s[h.instanceId]=h}}}return{defs:a,instances:s}}function expandRecurringRanges(e,t,n,r,o){var i=o[e.recurringDef.typeId].expand(e.recurringDef.typeData,{start:r.subtract(n.start,t),end:n.end},r);return e.allDay&&(i=i.map(startOfDay)),i}var INTERNAL_UNITS=["years","months","days","milliseconds"],PARSE_RE=/^(-?)(?:(\d+)\.)?(\d+):(\d\d)(?::(\d\d)(?:\.(\d\d\d))?)?/;function createDuration(e,t){var n;return"string"==typeof e?parseString(e):"object"==typeof e&&e?parseObject(e):"number"==typeof e?parseObject(((n={})[t||"milliseconds"]=e,n)):null}function parseString(e){var t=PARSE_RE.exec(e);if(t){var n=t[1]?-1:1;return{years:0,months:0,days:n*(t[2]?parseInt(t[2],10):0),milliseconds:n*(60*(t[3]?parseInt(t[3],10):0)*60*1e3+60*(t[4]?parseInt(t[4],10):0)*1e3+1e3*(t[5]?parseInt(t[5],10):0)+(t[6]?parseInt(t[6],10):0))}}return null}function parseObject(e){var t={years:e.years||e.year||0,months:e.months||e.month||0,days:e.days||e.day||0,milliseconds:60*(e.hours||e.hour||0)*60*1e3+60*(e.minutes||e.minute||0)*1e3+1e3*(e.seconds||e.second||0)+(e.milliseconds||e.millisecond||e.ms||0)},n=e.weeks||e.week;return n&&(t.days+=7*n,t.specifiedWeeks=!0),t}function durationsEqual(e,t){return e.years===t.years&&e.months===t.months&&e.days===t.days&&e.milliseconds===t.milliseconds}function addDurations(e,t){return{years:e.years+t.years,months:e.months+t.months,days:e.days+t.days,milliseconds:e.milliseconds+t.milliseconds}}function subtractDurations(e,t){return{years:e.years-t.years,months:e.months-t.months,days:e.days-t.days,milliseconds:e.milliseconds-t.milliseconds}}function multiplyDuration(e,t){return{years:e.years*t,months:e.months*t,days:e.days*t,milliseconds:e.milliseconds*t}}function asRoughYears(e){return asRoughDays(e)/365}function asRoughMonths(e){return asRoughDays(e)/30}function asRoughDays(e){return asRoughMs(e)/864e5}function asRoughMs(e){return 31536e6*e.years+2592e6*e.months+864e5*e.days+e.milliseconds}function wholeDivideDurations(e,t){for(var n=null,r=0;r<INTERNAL_UNITS.length;r+=1){var o=INTERNAL_UNITS[r];if(t[o]){var i=e[o]/t[o];if(!isInt(i)||null!==n&&n!==i)return null;n=i}else if(e[o])return null}return n}function greatestDurationDenominator(e){var t=e.milliseconds;if(t){if(t%1e3!=0)return{unit:"millisecond",value:t};if(t%6e4!=0)return{unit:"second",value:t/1e3};if(t%36e5!=0)return{unit:"minute",value:t/6e4};if(t)return{unit:"hour",value:t/36e5}}return e.days?e.specifiedWeeks&&e.days%7==0?{unit:"week",value:e.days/7}:{unit:"day",value:e.days}:e.months?{unit:"month",value:e.months}:e.years?{unit:"year",value:e.years}:{unit:"millisecond",value:0}}function buildIsoString(e,t,n){void 0===n&&(n=!1);var r=e.toISOString();return r=r.replace(".000",""),n&&(r=r.replace("T00:00:00Z","")),r.length>10&&(null==t?r=r.replace("Z",""):0!==t&&(r=r.replace("Z",formatTimeZoneOffset(t,!0)))),r}function formatDayString(e){return e.toISOString().replace(/T.*$/,"")}function formatIsoTimeString(e){return padStart(e.getUTCHours(),2)+":"+padStart(e.getUTCMinutes(),2)+":"+padStart(e.getUTCSeconds(),2)}function formatTimeZoneOffset(e,t){void 0===t&&(t=!1);var n=e<0?"-":"+",r=Math.abs(e),o=Math.floor(r/60),i=Math.round(r%60);return t?n+padStart(o,2)+":"+padStart(i,2):"GMT"+n+o+(i?":"+padStart(i,2):"")}function isArraysEqual(e,t,n){if(e===t)return!0;var r,o=e.length;if(o!==t.length)return!1;for(r=0;r<o;r+=1)if(!(n?n(e[r],t[r]):e[r]===t[r]))return!1;return!0}function memoize(e,t,n){var r,o;return function(){for(var i=[],a=0;a<arguments.length;a++)i[a]=arguments[a];if(r){if(!isArraysEqual(r,i)){n&&n(o);var s=e.apply(this,i);t&&t(s,o)||(o=s)}}else o=e.apply(this,i);return r=i,o}}function memoizeObjArg(e,t,n){var r,o,i=this;return function(a){if(r){if(!isPropsEqual(r,a)){n&&n(o);var s=e.call(i,a);t&&t(s,o)||(o=s)}}else o=e.call(i,a);return r=a,o}}var EXTENDED_SETTINGS_AND_SEVERITIES={week:3,separator:0,omitZeroMinute:0,meridiem:0,omitCommas:0},STANDARD_DATE_PROP_SEVERITIES={timeZoneName:7,era:6,year:5,month:4,day:2,weekday:2,hour:1,minute:1,second:1},MERIDIEM_RE=/\s*([ap])\.?m\.?/i,COMMA_RE=/,/g,MULTI_SPACE_RE=/\s+/g,LTR_RE=/\u200e/g,UTC_RE=/UTC|GMT/,NativeFormatter=function(){function e(e){var t={},n={},r=0;for(var o in e)o in EXTENDED_SETTINGS_AND_SEVERITIES?(n[o]=e[o],r=Math.max(EXTENDED_SETTINGS_AND_SEVERITIES[o],r)):(t[o]=e[o],o in STANDARD_DATE_PROP_SEVERITIES&&(r=Math.max(STANDARD_DATE_PROP_SEVERITIES[o],r)));this.standardDateProps=t,this.extendedSettings=n,this.severity=r,this.buildFormattingFunc=memoize(buildFormattingFunc)}return e.prototype.format=function(e,t){return this.buildFormattingFunc(this.standardDateProps,this.extendedSettings,t)(e)},e.prototype.formatRange=function(e,t,n,r){var o=this.standardDateProps,i=this.extendedSettings,a=computeMarkerDiffSeverity(e.marker,t.marker,n.calendarSystem);if(!a)return this.format(e,n);var s=a;!(s>1)||"numeric"!==o.year&&"2-digit"!==o.year||"numeric"!==o.month&&"2-digit"!==o.month||"numeric"!==o.day&&"2-digit"!==o.day||(s=1);var l=this.format(e,n),u=this.format(t,n);if(l===u)return l;var c=buildFormattingFunc(computePartialFormattingOptions(o,s),i,n),d=c(e),p=c(t),f=findCommonInsertion(l,d,u,p),h=i.separator||r||n.defaultSeparator||"";return f?f.before+d+h+p+f.after:l+h+u},e.prototype.getLargestUnit=function(){switch(this.severity){case 7:case 6:case 5:return"year";case 4:return"month";case 3:return"week";case 2:return"day";default:return"time"}},e}();function buildFormattingFunc(e,t,n){var r=Object.keys(e).length;return 1===r&&"short"===e.timeZoneName?function(e){return formatTimeZoneOffset(e.timeZoneOffset)}:0===r&&t.week?function(e){return formatWeekNumber(n.computeWeekNumber(e.marker),n.weekText,n.weekTextLong,n.locale,t.week)}:buildNativeFormattingFunc(e,t,n)}function buildNativeFormattingFunc(e,t,n){e=__assign$1({},e),t=__assign$1({},t),sanitizeSettings(e,t),e.timeZone="UTC";var r,o=new Intl.DateTimeFormat(n.locale.codes,e);if(t.omitZeroMinute){var i=__assign$1({},e);delete i.minute,r=new Intl.DateTimeFormat(n.locale.codes,i)}return function(i){var a=i.marker;return postProcess((r&&!a.getUTCMinutes()?r:o).format(a),i,e,t,n)}}function sanitizeSettings(e,t){e.timeZoneName&&(e.hour||(e.hour="2-digit"),e.minute||(e.minute="2-digit")),"long"===e.timeZoneName&&(e.timeZoneName="short"),t.omitZeroMinute&&(e.second||e.millisecond)&&delete t.omitZeroMinute}function postProcess(e,t,n,r,o){return e=e.replace(LTR_RE,""),"short"===n.timeZoneName&&(e=injectTzoStr(e,"UTC"===o.timeZone||null==t.timeZoneOffset?"UTC":formatTimeZoneOffset(t.timeZoneOffset))),r.omitCommas&&(e=e.replace(COMMA_RE,"").trim()),r.omitZeroMinute&&(e=e.replace(":00","")),!1===r.meridiem?e=e.replace(MERIDIEM_RE,"").trim():"narrow"===r.meridiem?e=e.replace(MERIDIEM_RE,(function(e,t){return t.toLocaleLowerCase()})):"short"===r.meridiem?e=e.replace(MERIDIEM_RE,(function(e,t){return t.toLocaleLowerCase()+"m"})):"lowercase"===r.meridiem&&(e=e.replace(MERIDIEM_RE,(function(e){return e.toLocaleLowerCase()}))),e=(e=e.replace(MULTI_SPACE_RE," ")).trim()}function injectTzoStr(e,t){var n=!1;return e=e.replace(UTC_RE,(function(){return n=!0,t})),n||(e+=" "+t),e}function formatWeekNumber(e,t,n,r,o){var i=[];return"long"===o?i.push(n):"short"!==o&&"narrow"!==o||i.push(t),"long"!==o&&"short"!==o||i.push(" "),i.push(r.simpleNumberFormat.format(e)),"rtl"===r.options.direction&&i.reverse(),i.join("")}function computeMarkerDiffSeverity(e,t,n){return n.getMarkerYear(e)!==n.getMarkerYear(t)?5:n.getMarkerMonth(e)!==n.getMarkerMonth(t)?4:n.getMarkerDay(e)!==n.getMarkerDay(t)?2:timeAsMs(e)!==timeAsMs(t)?1:0}function computePartialFormattingOptions(e,t){var n={};for(var r in e)(!(r in STANDARD_DATE_PROP_SEVERITIES)||STANDARD_DATE_PROP_SEVERITIES[r]<=t)&&(n[r]=e[r]);return n}function findCommonInsertion(e,t,n,r){for(var o=0;o<e.length;){var i=e.indexOf(t,o);if(-1===i)break;var a=e.substr(0,i);o=i+t.length;for(var s=e.substr(o),l=0;l<n.length;){var u=n.indexOf(r,l);if(-1===u)break;var c=n.substr(0,u);l=u+r.length;var d=n.substr(l);if(a===c&&s===d)return{before:a,after:s}}}return null}function expandZonedMarker(e,t){var n=t.markerToArray(e.marker);return{marker:e.marker,timeZoneOffset:e.timeZoneOffset,array:n,year:n[0],month:n[1],day:n[2],hour:n[3],minute:n[4],second:n[5],millisecond:n[6]}}function createVerboseFormattingArg(e,t,n,r){var o=expandZonedMarker(e,n.calendarSystem);return{date:o,start:o,end:t?expandZonedMarker(t,n.calendarSystem):null,timeZone:n.timeZone,localeCodes:n.locale.codes,defaultSeparator:r||n.defaultSeparator}}var CmdFormatter=function(){function e(e){this.cmdStr=e}return e.prototype.format=function(e,t,n){return t.cmdFormatter(this.cmdStr,createVerboseFormattingArg(e,null,t,n))},e.prototype.formatRange=function(e,t,n,r){return n.cmdFormatter(this.cmdStr,createVerboseFormattingArg(e,t,n,r))},e}(),FuncFormatter=function(){function e(e){this.func=e}return e.prototype.format=function(e,t,n){return this.func(createVerboseFormattingArg(e,null,t,n))},e.prototype.formatRange=function(e,t,n,r){return this.func(createVerboseFormattingArg(e,t,n,r))},e}();function createFormatter(e){return"object"==typeof e&&e?new NativeFormatter(e):"string"==typeof e?new CmdFormatter(e):"function"==typeof e?new FuncFormatter(e):null}var BASE_OPTION_REFINERS={navLinkDayClick:identity,navLinkWeekClick:identity,duration:createDuration,bootstrapFontAwesome:identity,buttonIcons:identity,customButtons:identity,defaultAllDayEventDuration:createDuration,defaultTimedEventDuration:createDuration,nextDayThreshold:createDuration,scrollTime:createDuration,scrollTimeReset:Boolean,slotMinTime:createDuration,slotMaxTime:createDuration,dayPopoverFormat:createFormatter,slotDuration:createDuration,snapDuration:createDuration,headerToolbar:identity,footerToolbar:identity,defaultRangeSeparator:String,titleRangeSeparator:String,forceEventDuration:Boolean,dayHeaders:Boolean,dayHeaderFormat:createFormatter,dayHeaderClassNames:identity,dayHeaderContent:identity,dayHeaderDidMount:identity,dayHeaderWillUnmount:identity,dayCellClassNames:identity,dayCellContent:identity,dayCellDidMount:identity,dayCellWillUnmount:identity,initialView:String,aspectRatio:Number,weekends:Boolean,weekNumberCalculation:identity,weekNumbers:Boolean,weekNumberClassNames:identity,weekNumberContent:identity,weekNumberDidMount:identity,weekNumberWillUnmount:identity,editable:Boolean,viewClassNames:identity,viewDidMount:identity,viewWillUnmount:identity,nowIndicator:Boolean,nowIndicatorClassNames:identity,nowIndicatorContent:identity,nowIndicatorDidMount:identity,nowIndicatorWillUnmount:identity,showNonCurrentDates:Boolean,lazyFetching:Boolean,startParam:String,endParam:String,timeZoneParam:String,timeZone:String,locales:identity,locale:identity,themeSystem:String,dragRevertDuration:Number,dragScroll:Boolean,allDayMaintainDuration:Boolean,unselectAuto:Boolean,dropAccept:identity,eventOrder:parseFieldSpecs,eventOrderStrict:Boolean,handleWindowResize:Boolean,windowResizeDelay:Number,longPressDelay:Number,eventDragMinDistance:Number,expandRows:Boolean,height:identity,contentHeight:identity,direction:String,weekNumberFormat:createFormatter,eventResizableFromStart:Boolean,displayEventTime:Boolean,displayEventEnd:Boolean,weekText:String,weekTextLong:String,progressiveEventRendering:Boolean,businessHours:identity,initialDate:identity,now:identity,eventDataTransform:identity,stickyHeaderDates:identity,stickyFooterScrollbar:identity,viewHeight:identity,defaultAllDay:Boolean,eventSourceFailure:identity,eventSourceSuccess:identity,eventDisplay:String,eventStartEditable:Boolean,eventDurationEditable:Boolean,eventOverlap:identity,eventConstraint:identity,eventAllow:identity,eventBackgroundColor:String,eventBorderColor:String,eventTextColor:String,eventColor:String,eventClassNames:identity,eventContent:identity,eventDidMount:identity,eventWillUnmount:identity,selectConstraint:identity,selectOverlap:identity,selectAllow:identity,droppable:Boolean,unselectCancel:String,slotLabelFormat:identity,slotLaneClassNames:identity,slotLaneContent:identity,slotLaneDidMount:identity,slotLaneWillUnmount:identity,slotLabelClassNames:identity,slotLabelContent:identity,slotLabelDidMount:identity,slotLabelWillUnmount:identity,dayMaxEvents:identity,dayMaxEventRows:identity,dayMinWidth:Number,slotLabelInterval:createDuration,allDayText:String,allDayClassNames:identity,allDayContent:identity,allDayDidMount:identity,allDayWillUnmount:identity,slotMinWidth:Number,navLinks:Boolean,eventTimeFormat:createFormatter,rerenderDelay:Number,moreLinkText:identity,moreLinkHint:identity,selectMinDistance:Number,selectable:Boolean,selectLongPressDelay:Number,eventLongPressDelay:Number,selectMirror:Boolean,eventMaxStack:Number,eventMinHeight:Number,eventMinWidth:Number,eventShortHeight:Number,slotEventOverlap:Boolean,plugins:identity,firstDay:Number,dayCount:Number,dateAlignment:String,dateIncrement:createDuration,hiddenDays:identity,monthMode:Boolean,fixedWeekCount:Boolean,validRange:identity,visibleRange:identity,titleFormat:identity,eventInteractive:Boolean,noEventsText:String,viewHint:identity,navLinkHint:identity,closeHint:String,timeHint:String,eventHint:String,moreLinkClick:identity,moreLinkClassNames:identity,moreLinkContent:identity,moreLinkDidMount:identity,moreLinkWillUnmount:identity},BASE_OPTION_DEFAULTS={eventDisplay:"auto",defaultRangeSeparator:" - ",titleRangeSeparator:" – ",defaultTimedEventDuration:"01:00:00",defaultAllDayEventDuration:{day:1},forceEventDuration:!1,nextDayThreshold:"00:00:00",dayHeaders:!0,initialView:"",aspectRatio:1.35,headerToolbar:{start:"title",center:"",end:"today prev,next"},weekends:!0,weekNumbers:!1,weekNumberCalculation:"local",editable:!1,nowIndicator:!1,scrollTime:"06:00:00",scrollTimeReset:!0,slotMinTime:"00:00:00",slotMaxTime:"24:00:00",showNonCurrentDates:!0,lazyFetching:!0,startParam:"start",endParam:"end",timeZoneParam:"timeZone",timeZone:"local",locales:[],locale:"",themeSystem:"standard",dragRevertDuration:500,dragScroll:!0,allDayMaintainDuration:!1,unselectAuto:!0,dropAccept:"*",eventOrder:"start,-duration,allDay,title",dayPopoverFormat:{month:"long",day:"numeric",year:"numeric"},handleWindowResize:!0,windowResizeDelay:100,longPressDelay:1e3,eventDragMinDistance:5,expandRows:!1,navLinks:!1,selectable:!1,eventMinHeight:15,eventMinWidth:30,eventShortHeight:30},CALENDAR_LISTENER_REFINERS={datesSet:identity,eventsSet:identity,eventAdd:identity,eventChange:identity,eventRemove:identity,windowResize:identity,eventClick:identity,eventMouseEnter:identity,eventMouseLeave:identity,select:identity,unselect:identity,loading:identity,_unmount:identity,_beforeprint:identity,_afterprint:identity,_noEventDrop:identity,_noEventResize:identity,_resize:identity,_scrollRequest:identity},CALENDAR_OPTION_REFINERS={buttonText:identity,buttonHints:identity,views:identity,plugins:identity,initialEvents:identity,events:identity,eventSources:identity},COMPLEX_OPTION_COMPARATORS={headerToolbar:isMaybeObjectsEqual,footerToolbar:isMaybeObjectsEqual,buttonText:isMaybeObjectsEqual,buttonHints:isMaybeObjectsEqual,buttonIcons:isMaybeObjectsEqual,dateIncrement:isMaybeObjectsEqual};function isMaybeObjectsEqual(e,t){return"object"==typeof e&&"object"==typeof t&&e&&t?isPropsEqual(e,t):e===t}var VIEW_OPTION_REFINERS={type:String,component:identity,buttonText:String,buttonTextKey:String,dateProfileGeneratorClass:identity,usesMinMaxTime:Boolean,classNames:identity,content:identity,didMount:identity,willUnmount:identity};function mergeRawOptions(e){return mergeProps(e,COMPLEX_OPTION_COMPARATORS)}function refineProps(e,t){var n={},r={};for(var o in t)o in e&&(n[o]=t[o](e[o]));for(var o in e)o in t||(r[o]=e[o]);return{refined:n,extra:r}}function identity(e){return e}function parseEvents(e,t,n,r){for(var o=createEmptyEventStore(),i=buildEventRefiners(n),a=0,s=e;a<s.length;a++){var l=parseEvent(s[a],t,n,r,i);l&&eventTupleToStore(l,o)}return o}function eventTupleToStore(e,t){return void 0===t&&(t=createEmptyEventStore()),t.defs[e.def.defId]=e.def,e.instance&&(t.instances[e.instance.instanceId]=e.instance),t}function getRelevantEvents(e,t){var n=e.instances[t];if(n){var r=e.defs[n.defId],o=filterEventStoreDefs(e,(function(e){return isEventDefsGrouped(r,e)}));return o.defs[r.defId]=r,o.instances[n.instanceId]=n,o}return createEmptyEventStore()}function isEventDefsGrouped(e,t){return Boolean(e.groupId&&e.groupId===t.groupId)}function createEmptyEventStore(){return{defs:{},instances:{}}}function mergeEventStores(e,t){return{defs:__assign$1(__assign$1({},e.defs),t.defs),instances:__assign$1(__assign$1({},e.instances),t.instances)}}function filterEventStoreDefs(e,t){var n=filterHash(e.defs,t),r=filterHash(e.instances,(function(e){return n[e.defId]}));return{defs:n,instances:r}}function excludeSubEventStore(e,t){var n=e.defs,r=e.instances,o={},i={};for(var a in n)t.defs[a]||(o[a]=n[a]);for(var s in r)!t.instances[s]&&o[r[s].defId]&&(i[s]=r[s]);return{defs:o,instances:i}}function normalizeConstraint(e,t){return Array.isArray(e)?parseEvents(e,null,t,!0):"object"==typeof e&&e?parseEvents([e],null,t,!0):null!=e?String(e):null}function parseClassNames(e){return Array.isArray(e)?e:"string"==typeof e?e.split(/\s+/):[]}var EVENT_UI_REFINERS={display:String,editable:Boolean,startEditable:Boolean,durationEditable:Boolean,constraint:identity,overlap:identity,allow:identity,className:parseClassNames,classNames:parseClassNames,color:String,backgroundColor:String,borderColor:String,textColor:String},EMPTY_EVENT_UI={display:null,startEditable:null,durationEditable:null,constraints:[],overlap:null,allows:[],backgroundColor:"",borderColor:"",textColor:"",classNames:[]};function createEventUi(e,t){var n=normalizeConstraint(e.constraint,t);return{display:e.display||null,startEditable:null!=e.startEditable?e.startEditable:e.editable,durationEditable:null!=e.durationEditable?e.durationEditable:e.editable,constraints:null!=n?[n]:[],overlap:null!=e.overlap?e.overlap:null,allows:null!=e.allow?[e.allow]:[],backgroundColor:e.backgroundColor||e.color||"",borderColor:e.borderColor||e.color||"",textColor:e.textColor||"",classNames:(e.className||[]).concat(e.classNames||[])}}function combineEventUis(e){return e.reduce(combineTwoEventUis,EMPTY_EVENT_UI)}function combineTwoEventUis(e,t){return{display:null!=t.display?t.display:e.display,startEditable:null!=t.startEditable?t.startEditable:e.startEditable,durationEditable:null!=t.durationEditable?t.durationEditable:e.durationEditable,constraints:e.constraints.concat(t.constraints),overlap:"boolean"==typeof t.overlap?t.overlap:e.overlap,allows:e.allows.concat(t.allows),backgroundColor:t.backgroundColor||e.backgroundColor,borderColor:t.borderColor||e.borderColor,textColor:t.textColor||e.textColor,classNames:e.classNames.concat(t.classNames)}}var EVENT_NON_DATE_REFINERS={id:String,groupId:String,title:String,url:String,interactive:Boolean},EVENT_DATE_REFINERS={start:identity,end:identity,date:identity,allDay:Boolean},EVENT_REFINERS=__assign$1(__assign$1(__assign$1({},EVENT_NON_DATE_REFINERS),EVENT_DATE_REFINERS),{extendedProps:identity});function parseEvent(e,t,n,r,o){void 0===o&&(o=buildEventRefiners(n));var i=refineEventDef(e,n,o),a=i.refined,s=i.extra,l=computeIsDefaultAllDay(t,n),u=parseRecurring(a,l,n.dateEnv,n.pluginHooks.recurringTypes);if(u)return(c=parseEventDef(a,s,t?t.sourceId:"",u.allDay,Boolean(u.duration),n)).recurringDef={typeId:u.typeId,typeData:u.typeData,duration:u.duration},{def:c,instance:null};var c,d=parseSingle(a,l,n,r);return d?{def:c=parseEventDef(a,s,t?t.sourceId:"",d.allDay,d.hasEnd,n),instance:createEventInstance(c.defId,d.range,d.forcedStartTzo,d.forcedEndTzo)}:null}function refineEventDef(e,t,n){return void 0===n&&(n=buildEventRefiners(t)),refineProps(e,n)}function buildEventRefiners(e){return __assign$1(__assign$1(__assign$1({},EVENT_UI_REFINERS),EVENT_REFINERS),e.pluginHooks.eventRefiners)}function parseEventDef(e,t,n,r,o,i){for(var a={title:e.title||"",groupId:e.groupId||"",publicId:e.id||"",url:e.url||"",recurringDef:null,defId:guid(),sourceId:n,allDay:r,hasEnd:o,interactive:e.interactive,ui:createEventUi(e,i),extendedProps:__assign$1(__assign$1({},e.extendedProps||{}),t)},s=0,l=i.pluginHooks.eventDefMemberAdders;s<l.length;s++){var u=l[s];__assign$1(a,u(e))}return Object.freeze(a.ui.classNames),Object.freeze(a.extendedProps),a}function parseSingle(e,t,n,r){var o,i,a=e.allDay,s=null,l=!1,u=null,c=null!=e.start?e.start:e.date;if(o=n.dateEnv.createMarkerMeta(c))s=o.marker;else if(!r)return null;return null!=e.end&&(i=n.dateEnv.createMarkerMeta(e.end)),null==a&&(a=null!=t?t:(!o||o.isTimeUnspecified)&&(!i||i.isTimeUnspecified)),a&&s&&(s=startOfDay(s)),i&&(u=i.marker,a&&(u=startOfDay(u)),s&&u<=s&&(u=null)),u?l=!0:r||(l=n.options.forceEventDuration||!1,u=n.dateEnv.add(s,a?n.options.defaultAllDayEventDuration:n.options.defaultTimedEventDuration)),{allDay:a,hasEnd:l,range:{start:s,end:u},forcedStartTzo:o?o.forcedTzo:null,forcedEndTzo:i?i.forcedTzo:null}}function computeIsDefaultAllDay(e,t){var n=null;return e&&(n=e.defaultAllDay),null==n&&(n=t.options.defaultAllDay),n}function computeAlignedDayRange(e){var t=Math.floor(diffDays(e.start,e.end))||1,n=startOfDay(e.start);return{start:n,end:addDays(n,t)}}function computeVisibleDayRange(e,t){void 0===t&&(t=createDuration(0));var n=null,r=null;if(e.end){r=startOfDay(e.end);var o=e.end.valueOf()-r.valueOf();o&&o>=asRoughMs(t)&&(r=addDays(r,1))}return e.start&&(n=startOfDay(e.start),r&&r<=n&&(r=addDays(n,1))),{start:n,end:r}}function isMultiDayRange(e){var t=computeVisibleDayRange(e);return diffDays(t.start,t.end)>1}function diffDates(e,t,n,r){return"year"===r?createDuration(n.diffWholeYears(e,t),"year"):"month"===r?createDuration(n.diffWholeMonths(e,t),"month"):diffDayAndTime(e,t)}function parseRange(e,t){var n=null,r=null;return e.start&&(n=t.createMarker(e.start)),e.end&&(r=t.createMarker(e.end)),n||r?n&&r&&r<n?null:{start:n,end:r}:null}function invertRanges(e,t){var n,r,o=[],i=t.start;for(e.sort(compareRanges),n=0;n<e.length;n+=1)(r=e[n]).start>i&&o.push({start:i,end:r.start}),r.end>i&&(i=r.end);return i<t.end&&o.push({start:i,end:t.end}),o}function compareRanges(e,t){return e.start.valueOf()-t.start.valueOf()}function intersectRanges(e,t){var n=e.start,r=e.end,o=null;return null!==t.start&&(n=null===n?t.start:new Date(Math.max(n.valueOf(),t.start.valueOf()))),null!=t.end&&(r=null===r?t.end:new Date(Math.min(r.valueOf(),t.end.valueOf()))),(null===n||null===r||n<r)&&(o={start:n,end:r}),o}function rangesEqual(e,t){return(null===e.start?null:e.start.valueOf())===(null===t.start?null:t.start.valueOf())&&(null===e.end?null:e.end.valueOf())===(null===t.end?null:t.end.valueOf())}function rangesIntersect(e,t){return(null===e.end||null===t.start||e.end>t.start)&&(null===e.start||null===t.end||e.start<t.end)}function rangeContainsRange(e,t){return(null===e.start||null!==t.start&&t.start>=e.start)&&(null===e.end||null!==t.end&&t.end<=e.end)}function rangeContainsMarker(e,t){return(null===e.start||t>=e.start)&&(null===e.end||t<e.end)}function constrainMarkerToRange(e,t){return null!=t.start&&e<t.start?t.start:null!=t.end&&e>=t.end?new Date(t.end.valueOf()-1):e}function sliceEventStore(e,t,n,r){var o={},i={},a={},s=[],l=[],u=compileEventUis(e.defs,t);for(var c in e.defs){"inverse-background"===(f=u[(S=e.defs[c]).defId]).display&&(S.groupId?(o[S.groupId]=[],a[S.groupId]||(a[S.groupId]=S)):i[c]=[])}for(var d in e.instances){var p=e.instances[d],f=u[(S=e.defs[p.defId]).defId],h=p.range,g=!S.allDay&&r?computeVisibleDayRange(h,r):h,m=intersectRanges(g,n);m&&("inverse-background"===f.display?S.groupId?o[S.groupId].push(m):i[p.defId].push(m):"none"!==f.display&&("background"===f.display?s:l).push({def:S,ui:f,instance:p,range:m,isStart:g.start&&g.start.valueOf()===m.start.valueOf(),isEnd:g.end&&g.end.valueOf()===m.end.valueOf()}))}for(var v in o)for(var y=0,E=invertRanges(o[v],n);y<E.length;y++){var S,D=E[y];f=u[(S=a[v]).defId];s.push({def:S,ui:f,instance:null,range:D,isStart:!1,isEnd:!1})}for(var c in i)for(var T=0,b=invertRanges(i[c],n);T<b.length;T++){D=b[T];s.push({def:e.defs[c],ui:u[c],instance:null,range:D,isStart:!1,isEnd:!1})}return{bg:s,fg:l}}function hasBgRendering(e){return"background"===e.ui.display||"inverse-background"===e.ui.display}function setElSeg(e,t){e.fcSeg=t}function getElSeg(e){return e.fcSeg||e.parentNode.fcSeg||null}function compileEventUis(e,t){return mapHash(e,(function(e){return compileEventUi(e,t)}))}function compileEventUi(e,t){var n=[];return t[""]&&n.push(t[""]),t[e.defId]&&n.push(t[e.defId]),n.push(e.ui),combineEventUis(n)}function sortEventSegs(e,t){var n=e.map(buildSegCompareObj);return n.sort((function(e,n){return compareByFieldSpecs(e,n,t)})),n.map((function(e){return e._seg}))}function buildSegCompareObj(e){var t=e.eventRange,n=t.def,r=t.instance?t.instance.range:t.range,o=r.start?r.start.valueOf():0,i=r.end?r.end.valueOf():0;return __assign$1(__assign$1(__assign$1({},n.extendedProps),n),{id:n.publicId,start:o,end:i,duration:i-o,allDay:Number(n.allDay),_seg:e})}function computeSegDraggable(e,t){for(var n=t.pluginHooks.isDraggableTransformers,r=e.eventRange,o=r.def,i=r.ui,a=i.startEditable,s=0,l=n;s<l.length;s++){a=(0,l[s])(a,o,i,t)}return a}function computeSegStartResizable(e,t){return e.isStart&&e.eventRange.ui.durationEditable&&t.options.eventResizableFromStart}function computeSegEndResizable(e,t){return e.isEnd&&e.eventRange.ui.durationEditable}function buildSegTimeText(e,t,n,r,o,i,a){var s=n.dateEnv,l=n.options,u=l.displayEventTime,c=l.displayEventEnd,d=e.eventRange.def,p=e.eventRange.instance;null==u&&(u=!1!==r),null==c&&(c=!1!==o);var f=p.range.start,h=p.range.end,g=i||e.start||e.eventRange.range.start,m=a||e.end||e.eventRange.range.end,v=startOfDay(f).valueOf()===startOfDay(g).valueOf(),y=startOfDay(addMs(h,-1)).valueOf()===startOfDay(addMs(m,-1)).valueOf();return u&&!d.allDay&&(v||y)?(g=v?f:g,m=y?h:m,c&&d.hasEnd?s.formatRange(g,m,t,{forcedStartTzo:i?null:p.forcedStartTzo,forcedEndTzo:a?null:p.forcedEndTzo}):s.format(g,t,{forcedTzo:i?null:p.forcedStartTzo})):""}function getSegMeta(e,t,n){var r=e.eventRange.range;return{isPast:r.end<(n||t.start),isFuture:r.start>=(n||t.end),isToday:t&&rangeContainsMarker(t,r.start)}}function getEventClassNames(e){var t=["fc-event"];return e.isMirror&&t.push("fc-event-mirror"),e.isDraggable&&t.push("fc-event-draggable"),(e.isStartResizable||e.isEndResizable)&&t.push("fc-event-resizable"),e.isDragging&&t.push("fc-event-dragging"),e.isResizing&&t.push("fc-event-resizing"),e.isSelected&&t.push("fc-event-selected"),e.isStart&&t.push("fc-event-start"),e.isEnd&&t.push("fc-event-end"),e.isPast&&t.push("fc-event-past"),e.isToday&&t.push("fc-event-today"),e.isFuture&&t.push("fc-event-future"),t}function buildEventRangeKey(e){return e.instance?e.instance.instanceId:e.def.defId+":"+e.range.start.toISOString()}function getSegAnchorAttrs(e,t){var n=e.eventRange,r=n.def,o=n.instance,i=r.url;if(i)return{href:i};var a=t.emitter,s=t.options.eventInteractive;return null==s&&null==(s=r.interactive)&&(s=Boolean(a.hasHandlers("eventClick"))),s?createAriaKeyboardAttrs((function(e){a.trigger("eventClick",{el:e.target,event:new EventApi(t,r,o),jsEvent:e,view:t.viewApi})})):{}}var STANDARD_PROPS={start:identity,end:identity,allDay:Boolean};function parseDateSpan(e,t,n){var r=parseOpenDateSpan(e,t),o=r.range;if(!o.start)return null;if(!o.end){if(null==n)return null;o.end=t.add(o.start,n)}return r}function parseOpenDateSpan(e,t){var n=refineProps(e,STANDARD_PROPS),r=n.refined,o=n.extra,i=r.start?t.createMarkerMeta(r.start):null,a=r.end?t.createMarkerMeta(r.end):null,s=r.allDay;return null==s&&(s=i&&i.isTimeUnspecified&&(!a||a.isTimeUnspecified)),__assign$1({range:{start:i?i.marker:null,end:a?a.marker:null},allDay:s},o)}function isDateSpansEqual(e,t){return rangesEqual(e.range,t.range)&&e.allDay===t.allDay&&isSpanPropsEqual(e,t)}function isSpanPropsEqual(e,t){for(var n in t)if("range"!==n&&"allDay"!==n&&e[n]!==t[n])return!1;for(var n in e)if(!(n in t))return!1;return!0}function buildDateSpanApi(e,t){return __assign$1(__assign$1({},buildRangeApi(e.range,t,e.allDay)),{allDay:e.allDay})}function buildRangeApiWithTimeZone(e,t,n){return __assign$1(__assign$1({},buildRangeApi(e,t,n)),{timeZone:t.timeZone})}function buildRangeApi(e,t,n){return{start:t.toDate(e.start),end:t.toDate(e.end),startStr:t.formatIso(e.start,{omitTime:n}),endStr:t.formatIso(e.end,{omitTime:n})}}function fabricateEventRange(e,t,n){var r=refineEventDef({editable:!1},n),o=parseEventDef(r.refined,r.extra,"",e.allDay,!0,n);return{def:o,ui:compileEventUi(o,t),instance:createEventInstance(o.defId,e.range),range:e.range,isStart:!0,isEnd:!0}}function triggerDateSelect(e,t,n){n.emitter.trigger("select",__assign$1(__assign$1({},buildDateSpanApiWithContext(e,n)),{jsEvent:t?t.origEvent:null,view:n.viewApi||n.calendarApi.view}))}function triggerDateUnselect(e,t){t.emitter.trigger("unselect",{jsEvent:e?e.origEvent:null,view:t.viewApi||t.calendarApi.view})}function buildDateSpanApiWithContext(e,t){for(var n={},r=0,o=t.pluginHooks.dateSpanTransforms;r<o.length;r++){var i=o[r];__assign$1(n,i(e,t))}return __assign$1(n,buildDateSpanApi(e,t.dateEnv)),n}function getDefaultEventEnd(e,t,n){var r=n.dateEnv,o=n.options,i=t;return e?(i=startOfDay(i),i=r.add(i,o.defaultAllDayEventDuration)):i=r.add(i,o.defaultTimedEventDuration),i}function applyMutationToEventStore(e,t,n,r){var o=compileEventUis(e.defs,t),i=createEmptyEventStore();for(var a in e.defs){var s=e.defs[a];i.defs[a]=applyMutationToEventDef(s,o[a],n,r)}for(var l in e.instances){var u=e.instances[l];s=i.defs[u.defId];i.instances[l]=applyMutationToEventInstance(u,s,o[u.defId],n,r)}return i}function applyMutationToEventDef(e,t,n,r){var o=n.standardProps||{};null==o.hasEnd&&t.durationEditable&&(n.startDelta||n.endDelta)&&(o.hasEnd=!0);var i=__assign$1(__assign$1(__assign$1({},e),o),{ui:__assign$1(__assign$1({},e.ui),o.ui)});n.extendedProps&&(i.extendedProps=__assign$1(__assign$1({},i.extendedProps),n.extendedProps));for(var a=0,s=r.pluginHooks.eventDefMutationAppliers;a<s.length;a++){(0,s[a])(i,n,r)}return!i.hasEnd&&r.options.forceEventDuration&&(i.hasEnd=!0),i}function applyMutationToEventInstance(e,t,n,r,o){var i=o.dateEnv,a=r.standardProps&&!0===r.standardProps.allDay,s=r.standardProps&&!1===r.standardProps.hasEnd,l=__assign$1({},e);return a&&(l.range=computeAlignedDayRange(l.range)),r.datesDelta&&n.startEditable&&(l.range={start:i.add(l.range.start,r.datesDelta),end:i.add(l.range.end,r.datesDelta)}),r.startDelta&&n.durationEditable&&(l.range={start:i.add(l.range.start,r.startDelta),end:l.range.end}),r.endDelta&&n.durationEditable&&(l.range={start:l.range.start,end:i.add(l.range.end,r.endDelta)}),s&&(l.range={start:l.range.start,end:getDefaultEventEnd(t.allDay,l.range.start,o)}),t.allDay&&(l.range={start:startOfDay(l.range.start),end:startOfDay(l.range.end)}),l.range.end<l.range.start&&(l.range.end=getDefaultEventEnd(t.allDay,l.range.start,o)),l}var ViewApi=function(){function e(e,t,n){this.type=e,this.getCurrentData=t,this.dateEnv=n}return Object.defineProperty(e.prototype,"calendar",{get:function(){return this.getCurrentData().calendarApi},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"title",{get:function(){return this.getCurrentData().viewTitle},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeStart",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.start)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeEnd",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.end)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentStart",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.start)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentEnd",{get:function(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.end)},enumerable:!1,configurable:!0}),e.prototype.getOption=function(e){return this.getCurrentData().options[e]},e}(),EVENT_SOURCE_REFINERS={id:String,defaultAllDay:Boolean,url:String,format:String,events:identity,eventDataTransform:identity,success:identity,failure:identity};function parseEventSource(e,t,n){var r;if(void 0===n&&(n=buildEventSourceRefiners(t)),"string"==typeof e?r={url:e}:"function"==typeof e||Array.isArray(e)?r={events:e}:"object"==typeof e&&e&&(r=e),r){var o=refineProps(r,n),i=o.refined,a=o.extra,s=buildEventSourceMeta(i,t);if(s)return{_raw:e,isFetching:!1,latestFetchId:"",fetchRange:null,defaultAllDay:i.defaultAllDay,eventDataTransform:i.eventDataTransform,success:i.success,failure:i.failure,publicId:i.id||"",sourceId:guid(),sourceDefId:s.sourceDefId,meta:s.meta,ui:createEventUi(i,t),extendedProps:a}}return null}function buildEventSourceRefiners(e){return __assign$1(__assign$1(__assign$1({},EVENT_UI_REFINERS),EVENT_SOURCE_REFINERS),e.pluginHooks.eventSourceRefiners)}function buildEventSourceMeta(e,t){for(var n=t.pluginHooks.eventSourceDefs,r=n.length-1;r>=0;r-=1){var o=n[r].parseMeta(e);if(o)return{sourceDefId:r,meta:o}}return null}function reduceCurrentDate(e,t){return"CHANGE_DATE"===t.type?t.dateMarker:e}function getInitialDate(e,t){var n=e.initialDate;return null!=n?t.createMarker(n):getNow(e.now,t)}function getNow(e,t){return"function"==typeof e&&(e=e()),null==e?t.createNowMarker():t.createMarker(e)}var CalendarApi=function(){function e(){}return e.prototype.getCurrentData=function(){return this.currentDataManager.getCurrentData()},e.prototype.dispatch=function(e){return this.currentDataManager.dispatch(e)},Object.defineProperty(e.prototype,"view",{get:function(){return this.getCurrentData().viewApi},enumerable:!1,configurable:!0}),e.prototype.batchRendering=function(e){e()},e.prototype.updateSize=function(){this.trigger("_resize",!0)},e.prototype.setOption=function(e,t){this.dispatch({type:"SET_OPTION",optionName:e,rawOptionValue:t})},e.prototype.getOption=function(e){return this.currentDataManager.currentCalendarOptionsInput[e]},e.prototype.getAvailableLocaleCodes=function(){return Object.keys(this.getCurrentData().availableRawLocales)},e.prototype.on=function(e,t){var n=this.currentDataManager;n.currentCalendarOptionsRefiners[e]?n.emitter.on(e,t):console.warn("Unknown listener name '"+e+"'")},e.prototype.off=function(e,t){this.currentDataManager.emitter.off(e,t)},e.prototype.trigger=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];(t=this.currentDataManager.emitter).trigger.apply(t,__spreadArray([e],n))},e.prototype.changeView=function(e,t){var n=this;this.batchRendering((function(){if(n.unselect(),t)if(t.start&&t.end)n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e}),n.dispatch({type:"SET_OPTION",optionName:"visibleRange",rawOptionValue:t});else{var r=n.getCurrentData().dateEnv;n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e,dateMarker:r.createMarker(t)})}else n.dispatch({type:"CHANGE_VIEW_TYPE",viewType:e})}))},e.prototype.zoomTo=function(e,t){var n;t=t||"day",n=this.getCurrentData().viewSpecs[t]||this.getUnitViewSpec(t),this.unselect(),n?this.dispatch({type:"CHANGE_VIEW_TYPE",viewType:n.type,dateMarker:e}):this.dispatch({type:"CHANGE_DATE",dateMarker:e})},e.prototype.getUnitViewSpec=function(e){var t,n,r=this.getCurrentData(),o=r.viewSpecs,i=r.toolbarConfig,a=[].concat(i.header?i.header.viewsWithButtons:[],i.footer?i.footer.viewsWithButtons:[]);for(var s in o)a.push(s);for(t=0;t<a.length;t+=1)if((n=o[a[t]])&&n.singleUnit===e)return n;return null},e.prototype.prev=function(){this.unselect(),this.dispatch({type:"PREV"})},e.prototype.next=function(){this.unselect(),this.dispatch({type:"NEXT"})},e.prototype.prevYear=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:e.dateEnv.addYears(e.currentDate,-1)})},e.prototype.nextYear=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:e.dateEnv.addYears(e.currentDate,1)})},e.prototype.today=function(){var e=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:getNow(e.calendarOptions.now,e.dateEnv)})},e.prototype.gotoDate=function(e){var t=this.getCurrentData();this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:t.dateEnv.createMarker(e)})},e.prototype.incrementDate=function(e){var t=this.getCurrentData(),n=createDuration(e);n&&(this.unselect(),this.dispatch({type:"CHANGE_DATE",dateMarker:t.dateEnv.add(t.currentDate,n)}))},e.prototype.getDate=function(){var e=this.getCurrentData();return e.dateEnv.toDate(e.currentDate)},e.prototype.formatDate=function(e,t){var n=this.getCurrentData().dateEnv;return n.format(n.createMarker(e),createFormatter(t))},e.prototype.formatRange=function(e,t,n){var r=this.getCurrentData().dateEnv;return r.formatRange(r.createMarker(e),r.createMarker(t),createFormatter(n),n)},e.prototype.formatIso=function(e,t){var n=this.getCurrentData().dateEnv;return n.formatIso(n.createMarker(e),{omitTime:t})},e.prototype.select=function(e,t){var n;n=null==t?null!=e.start?e:{start:e,end:null}:{start:e,end:t};var r=this.getCurrentData(),o=parseDateSpan(n,r.dateEnv,createDuration({days:1}));o&&(this.dispatch({type:"SELECT_DATES",selection:o}),triggerDateSelect(o,null,r))},e.prototype.unselect=function(e){var t=this.getCurrentData();t.dateSelection&&(this.dispatch({type:"UNSELECT_DATES"}),triggerDateUnselect(e,t))},e.prototype.addEvent=function(e,t){if(e instanceof EventApi){var n=e._def,r=e._instance;return this.getCurrentData().eventStore.defs[n.defId]||(this.dispatch({type:"ADD_EVENTS",eventStore:eventTupleToStore({def:n,instance:r})}),this.triggerEventAdd(e)),e}var o,i=this.getCurrentData();if(t instanceof EventSourceApi)o=t.internalEventSource;else if("boolean"==typeof t)t&&(o=hashValuesToArray(i.eventSources)[0]);else if(null!=t){var a=this.getEventSourceById(t);if(!a)return console.warn('Could not find an event source with ID "'+t+'"'),null;o=a.internalEventSource}var s=parseEvent(e,o,i,!1);if(s){var l=new EventApi(i,s.def,s.def.recurringDef?null:s.instance);return this.dispatch({type:"ADD_EVENTS",eventStore:eventTupleToStore(s)}),this.triggerEventAdd(l),l}return null},e.prototype.triggerEventAdd=function(e){var t=this;this.getCurrentData().emitter.trigger("eventAdd",{event:e,relatedEvents:[],revert:function(){t.dispatch({type:"REMOVE_EVENTS",eventStore:eventApiToStore(e)})}})},e.prototype.getEventById=function(e){var t=this.getCurrentData(),n=t.eventStore,r=n.defs,o=n.instances;for(var i in e=String(e),r){var a=r[i];if(a.publicId===e){if(a.recurringDef)return new EventApi(t,a,null);for(var s in o){var l=o[s];if(l.defId===a.defId)return new EventApi(t,a,l)}}}return null},e.prototype.getEvents=function(){var e=this.getCurrentData();return buildEventApis(e.eventStore,e)},e.prototype.removeAllEvents=function(){this.dispatch({type:"REMOVE_ALL_EVENTS"})},e.prototype.getEventSources=function(){var e=this.getCurrentData(),t=e.eventSources,n=[];for(var r in t)n.push(new EventSourceApi(e,t[r]));return n},e.prototype.getEventSourceById=function(e){var t=this.getCurrentData(),n=t.eventSources;for(var r in e=String(e),n)if(n[r].publicId===e)return new EventSourceApi(t,n[r]);return null},e.prototype.addEventSource=function(e){var t=this.getCurrentData();if(e instanceof EventSourceApi)return t.eventSources[e.internalEventSource.sourceId]||this.dispatch({type:"ADD_EVENT_SOURCES",sources:[e.internalEventSource]}),e;var n=parseEventSource(e,t);return n?(this.dispatch({type:"ADD_EVENT_SOURCES",sources:[n]}),new EventSourceApi(t,n)):null},e.prototype.removeAllEventSources=function(){this.dispatch({type:"REMOVE_ALL_EVENT_SOURCES"})},e.prototype.refetchEvents=function(){this.dispatch({type:"FETCH_EVENT_SOURCES",isRefetch:!0})},e.prototype.scrollToTime=function(e){var t=createDuration(e);t&&this.trigger("_scrollRequest",{time:t})},e}(),EventApi=function(){function e(e,t,n){this._context=e,this._def=t,this._instance=n||null}return e.prototype.setProp=function(e,t){var n,r;if(e in EVENT_DATE_REFINERS)console.warn("Could not set date-related prop 'name'. Use one of the date-related methods instead.");else if("id"===e)t=EVENT_NON_DATE_REFINERS[e](t),this.mutate({standardProps:{publicId:t}});else if(e in EVENT_NON_DATE_REFINERS)t=EVENT_NON_DATE_REFINERS[e](t),this.mutate({standardProps:(n={},n[e]=t,n)});else if(e in EVENT_UI_REFINERS){var o=EVENT_UI_REFINERS[e](t);"color"===e?o={backgroundColor:t,borderColor:t}:"editable"===e?o={startEditable:t,durationEditable:t}:((r={})[e]=t,o=r),this.mutate({standardProps:{ui:o}})}else console.warn("Could not set prop '"+e+"'. Use setExtendedProp instead.")},e.prototype.setExtendedProp=function(e,t){var n;this.mutate({extendedProps:(n={},n[e]=t,n)})},e.prototype.setStart=function(e,t){void 0===t&&(t={});var n=this._context.dateEnv,r=n.createMarker(e);if(r&&this._instance){var o=diffDates(this._instance.range.start,r,n,t.granularity);t.maintainDuration?this.mutate({datesDelta:o}):this.mutate({startDelta:o})}},e.prototype.setEnd=function(e,t){void 0===t&&(t={});var n,r=this._context.dateEnv;if((null==e||(n=r.createMarker(e)))&&this._instance)if(n){var o=diffDates(this._instance.range.end,n,r,t.granularity);this.mutate({endDelta:o})}else this.mutate({standardProps:{hasEnd:!1}})},e.prototype.setDates=function(e,t,n){void 0===n&&(n={});var r,o=this._context.dateEnv,i={allDay:n.allDay},a=o.createMarker(e);if(a&&(null==t||(r=o.createMarker(t)))&&this._instance){var s=this._instance.range;!0===n.allDay&&(s=computeAlignedDayRange(s));var l=diffDates(s.start,a,o,n.granularity);if(r){var u=diffDates(s.end,r,o,n.granularity);durationsEqual(l,u)?this.mutate({datesDelta:l,standardProps:i}):this.mutate({startDelta:l,endDelta:u,standardProps:i})}else i.hasEnd=!1,this.mutate({datesDelta:l,standardProps:i})}},e.prototype.moveStart=function(e){var t=createDuration(e);t&&this.mutate({startDelta:t})},e.prototype.moveEnd=function(e){var t=createDuration(e);t&&this.mutate({endDelta:t})},e.prototype.moveDates=function(e){var t=createDuration(e);t&&this.mutate({datesDelta:t})},e.prototype.setAllDay=function(e,t){void 0===t&&(t={});var n={allDay:e},r=t.maintainDuration;null==r&&(r=this._context.options.allDayMaintainDuration),this._def.allDay!==e&&(n.hasEnd=r),this.mutate({standardProps:n})},e.prototype.formatRange=function(e){var t=this._context.dateEnv,n=this._instance,r=createFormatter(e);return this._def.hasEnd?t.formatRange(n.range.start,n.range.end,r,{forcedStartTzo:n.forcedStartTzo,forcedEndTzo:n.forcedEndTzo}):t.format(n.range.start,r,{forcedTzo:n.forcedStartTzo})},e.prototype.mutate=function(t){var n=this._instance;if(n){var r=this._def,o=this._context,i=o.getCurrentData().eventStore,a=getRelevantEvents(i,n.instanceId);a=applyMutationToEventStore(a,{"":{display:"",startEditable:!0,durationEditable:!0,constraints:[],overlap:null,allows:[],backgroundColor:"",borderColor:"",textColor:"",classNames:[]}},t,o);var s=new e(o,r,n);this._def=a.defs[r.defId],this._instance=a.instances[n.instanceId],o.dispatch({type:"MERGE_EVENTS",eventStore:a}),o.emitter.trigger("eventChange",{oldEvent:s,event:this,relatedEvents:buildEventApis(a,o,n),revert:function(){o.dispatch({type:"RESET_EVENTS",eventStore:i})}})}},e.prototype.remove=function(){var e=this._context,t=eventApiToStore(this);e.dispatch({type:"REMOVE_EVENTS",eventStore:t}),e.emitter.trigger("eventRemove",{event:this,relatedEvents:[],revert:function(){e.dispatch({type:"MERGE_EVENTS",eventStore:t})}})},Object.defineProperty(e.prototype,"source",{get:function(){var e=this._def.sourceId;return e?new EventSourceApi(this._context,this._context.getCurrentData().eventSources[e]):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"start",{get:function(){return this._instance?this._context.dateEnv.toDate(this._instance.range.start):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"end",{get:function(){return this._instance&&this._def.hasEnd?this._context.dateEnv.toDate(this._instance.range.end):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"startStr",{get:function(){var e=this._instance;return e?this._context.dateEnv.formatIso(e.range.start,{omitTime:this._def.allDay,forcedTzo:e.forcedStartTzo}):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"endStr",{get:function(){var e=this._instance;return e&&this._def.hasEnd?this._context.dateEnv.formatIso(e.range.end,{omitTime:this._def.allDay,forcedTzo:e.forcedEndTzo}):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this._def.publicId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"groupId",{get:function(){return this._def.groupId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"allDay",{get:function(){return this._def.allDay},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"title",{get:function(){return this._def.title},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._def.url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"display",{get:function(){return this._def.ui.display||"auto"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"startEditable",{get:function(){return this._def.ui.startEditable},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"durationEditable",{get:function(){return this._def.ui.durationEditable},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"constraint",{get:function(){return this._def.ui.constraints[0]||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"overlap",{get:function(){return this._def.ui.overlap},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"allow",{get:function(){return this._def.ui.allows[0]||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"backgroundColor",{get:function(){return this._def.ui.backgroundColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"borderColor",{get:function(){return this._def.ui.borderColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textColor",{get:function(){return this._def.ui.textColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classNames",{get:function(){return this._def.ui.classNames},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"extendedProps",{get:function(){return this._def.extendedProps},enumerable:!1,configurable:!0}),e.prototype.toPlainObject=function(e){void 0===e&&(e={});var t=this._def,n=t.ui,r=this.startStr,o=this.endStr,i={};return t.title&&(i.title=t.title),r&&(i.start=r),o&&(i.end=o),t.publicId&&(i.id=t.publicId),t.groupId&&(i.groupId=t.groupId),t.url&&(i.url=t.url),n.display&&"auto"!==n.display&&(i.display=n.display),e.collapseColor&&n.backgroundColor&&n.backgroundColor===n.borderColor?i.color=n.backgroundColor:(n.backgroundColor&&(i.backgroundColor=n.backgroundColor),n.borderColor&&(i.borderColor=n.borderColor)),n.textColor&&(i.textColor=n.textColor),n.classNames.length&&(i.classNames=n.classNames),Object.keys(t.extendedProps).length&&(e.collapseExtendedProps?__assign$1(i,t.extendedProps):i.extendedProps=t.extendedProps),i},e.prototype.toJSON=function(){return this.toPlainObject()},e}();function eventApiToStore(e){var t,n,r=e._def,o=e._instance;return{defs:(t={},t[r.defId]=r,t),instances:o?(n={},n[o.instanceId]=o,n):{}}}function buildEventApis(e,t,n){var r=e.defs,o=e.instances,i=[],a=n?n.instanceId:"";for(var s in o){var l=o[s],u=r[l.defId];l.instanceId!==a&&i.push(new EventApi(t,u,l))}return i}var calendarSystemClassMap={};function registerCalendarSystem(e,t){calendarSystemClassMap[e]=t}function createCalendarSystem(e){return new calendarSystemClassMap[e]}var GregorianCalendarSystem=function(){function e(){}return e.prototype.getMarkerYear=function(e){return e.getUTCFullYear()},e.prototype.getMarkerMonth=function(e){return e.getUTCMonth()},e.prototype.getMarkerDay=function(e){return e.getUTCDate()},e.prototype.arrayToMarker=function(e){return arrayToUtcDate(e)},e.prototype.markerToArray=function(e){return dateToUtcArray(e)},e}();registerCalendarSystem("gregory",GregorianCalendarSystem);var ISO_RE=/^\s*(\d{4})(-?(\d{2})(-?(\d{2})([T ](\d{2}):?(\d{2})(:?(\d{2})(\.(\d+))?)?(Z|(([-+])(\d{2})(:?(\d{2}))?))?)?)?)?$/;function parse(e){var t=ISO_RE.exec(e);if(t){var n=new Date(Date.UTC(Number(t[1]),t[3]?Number(t[3])-1:0,Number(t[5]||1),Number(t[7]||0),Number(t[8]||0),Number(t[10]||0),t[12]?1e3*Number("0."+t[12]):0));if(isValidDate(n)){var r=null;return t[13]&&(r=("-"===t[15]?-1:1)*(60*Number(t[16]||0)+Number(t[18]||0))),{marker:n,isTimeUnspecified:!t[6],timeZoneOffset:r}}}return null}var DateEnv=function(){function e(e){var t=this.timeZone=e.timeZone,n="local"!==t&&"UTC"!==t;e.namedTimeZoneImpl&&n&&(this.namedTimeZoneImpl=new e.namedTimeZoneImpl(t)),this.canComputeOffset=Boolean(!n||this.namedTimeZoneImpl),this.calendarSystem=createCalendarSystem(e.calendarSystem),this.locale=e.locale,this.weekDow=e.locale.week.dow,this.weekDoy=e.locale.week.doy,"ISO"===e.weekNumberCalculation&&(this.weekDow=1,this.weekDoy=4),"number"==typeof e.firstDay&&(this.weekDow=e.firstDay),"function"==typeof e.weekNumberCalculation&&(this.weekNumberFunc=e.weekNumberCalculation),this.weekText=null!=e.weekText?e.weekText:e.locale.options.weekText,this.weekTextLong=(null!=e.weekTextLong?e.weekTextLong:e.locale.options.weekTextLong)||this.weekText,this.cmdFormatter=e.cmdFormatter,this.defaultSeparator=e.defaultSeparator}return e.prototype.createMarker=function(e){var t=this.createMarkerMeta(e);return null===t?null:t.marker},e.prototype.createNowMarker=function(){return this.canComputeOffset?this.timestampToMarker((new Date).valueOf()):arrayToUtcDate(dateToLocalArray(new Date))},e.prototype.createMarkerMeta=function(e){if("string"==typeof e)return this.parse(e);var t=null;return"number"==typeof e?t=this.timestampToMarker(e):e instanceof Date?(e=e.valueOf(),isNaN(e)||(t=this.timestampToMarker(e))):Array.isArray(e)&&(t=arrayToUtcDate(e)),null!==t&&isValidDate(t)?{marker:t,isTimeUnspecified:!1,forcedTzo:null}:null},e.prototype.parse=function(e){var t=parse(e);if(null===t)return null;var n=t.marker,r=null;return null!==t.timeZoneOffset&&(this.canComputeOffset?n=this.timestampToMarker(n.valueOf()-60*t.timeZoneOffset*1e3):r=t.timeZoneOffset),{marker:n,isTimeUnspecified:t.isTimeUnspecified,forcedTzo:r}},e.prototype.getYear=function(e){return this.calendarSystem.getMarkerYear(e)},e.prototype.getMonth=function(e){return this.calendarSystem.getMarkerMonth(e)},e.prototype.add=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]+=t.years,n[1]+=t.months,n[2]+=t.days,n[6]+=t.milliseconds,this.calendarSystem.arrayToMarker(n)},e.prototype.subtract=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]-=t.years,n[1]-=t.months,n[2]-=t.days,n[6]-=t.milliseconds,this.calendarSystem.arrayToMarker(n)},e.prototype.addYears=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[0]+=t,this.calendarSystem.arrayToMarker(n)},e.prototype.addMonths=function(e,t){var n=this.calendarSystem.markerToArray(e);return n[1]+=t,this.calendarSystem.arrayToMarker(n)},e.prototype.diffWholeYears=function(e,t){var n=this.calendarSystem;return timeAsMs(e)===timeAsMs(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)&&n.getMarkerMonth(e)===n.getMarkerMonth(t)?n.getMarkerYear(t)-n.getMarkerYear(e):null},e.prototype.diffWholeMonths=function(e,t){var n=this.calendarSystem;return timeAsMs(e)===timeAsMs(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)?n.getMarkerMonth(t)-n.getMarkerMonth(e)+12*(n.getMarkerYear(t)-n.getMarkerYear(e)):null},e.prototype.greatestWholeUnit=function(e,t){var n=this.diffWholeYears(e,t);return null!==n?{unit:"year",value:n}:null!==(n=this.diffWholeMonths(e,t))?{unit:"month",value:n}:null!==(n=diffWholeWeeks(e,t))?{unit:"week",value:n}:null!==(n=diffWholeDays(e,t))?{unit:"day",value:n}:isInt(n=diffHours(e,t))?{unit:"hour",value:n}:isInt(n=diffMinutes(e,t))?{unit:"minute",value:n}:isInt(n=diffSeconds(e,t))?{unit:"second",value:n}:{unit:"millisecond",value:t.valueOf()-e.valueOf()}},e.prototype.countDurationsBetween=function(e,t,n){var r;return n.years&&null!==(r=this.diffWholeYears(e,t))?r/asRoughYears(n):n.months&&null!==(r=this.diffWholeMonths(e,t))?r/asRoughMonths(n):n.days&&null!==(r=diffWholeDays(e,t))?r/asRoughDays(n):(t.valueOf()-e.valueOf())/asRoughMs(n)},e.prototype.startOf=function(e,t){return"year"===t?this.startOfYear(e):"month"===t?this.startOfMonth(e):"week"===t?this.startOfWeek(e):"day"===t?startOfDay(e):"hour"===t?startOfHour(e):"minute"===t?startOfMinute(e):"second"===t?startOfSecond(e):null},e.prototype.startOfYear=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e)])},e.prototype.startOfMonth=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e)])},e.prototype.startOfWeek=function(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e),e.getUTCDate()-(e.getUTCDay()-this.weekDow+7)%7])},e.prototype.computeWeekNumber=function(e){return this.weekNumberFunc?this.weekNumberFunc(this.toDate(e)):weekOfYear(e,this.weekDow,this.weekDoy)},e.prototype.format=function(e,t,n){return void 0===n&&(n={}),t.format({marker:e,timeZoneOffset:null!=n.forcedTzo?n.forcedTzo:this.offsetForMarker(e)},this)},e.prototype.formatRange=function(e,t,n,r){return void 0===r&&(r={}),r.isEndExclusive&&(t=addMs(t,-1)),n.formatRange({marker:e,timeZoneOffset:null!=r.forcedStartTzo?r.forcedStartTzo:this.offsetForMarker(e)},{marker:t,timeZoneOffset:null!=r.forcedEndTzo?r.forcedEndTzo:this.offsetForMarker(t)},this,r.defaultSeparator)},e.prototype.formatIso=function(e,t){void 0===t&&(t={});var n=null;return t.omitTimeZoneOffset||(n=null!=t.forcedTzo?t.forcedTzo:this.offsetForMarker(e)),buildIsoString(e,n,t.omitTime)},e.prototype.timestampToMarker=function(e){return"local"===this.timeZone?arrayToUtcDate(dateToLocalArray(new Date(e))):"UTC"!==this.timeZone&&this.namedTimeZoneImpl?arrayToUtcDate(this.namedTimeZoneImpl.timestampToArray(e)):new Date(e)},e.prototype.offsetForMarker=function(e){return"local"===this.timeZone?-arrayToLocalDate(dateToUtcArray(e)).getTimezoneOffset():"UTC"===this.timeZone?0:this.namedTimeZoneImpl?this.namedTimeZoneImpl.offsetForArray(dateToUtcArray(e)):null},e.prototype.toDate=function(e,t){return"local"===this.timeZone?arrayToLocalDate(dateToUtcArray(e)):"UTC"===this.timeZone?new Date(e.valueOf()):this.namedTimeZoneImpl?new Date(e.valueOf()-1e3*this.namedTimeZoneImpl.offsetForArray(dateToUtcArray(e))*60):new Date(e.valueOf()-(t||0))},e}(),globalLocales=[],MINIMAL_RAW_EN_LOCALE={code:"en",week:{dow:0,doy:4},direction:"ltr",buttonText:{prev:"prev",next:"next",prevYear:"prev year",nextYear:"next year",year:"year",today:"today",month:"month",week:"week",day:"day",list:"list"},weekText:"W",weekTextLong:"Week",closeHint:"Close",timeHint:"Time",eventHint:"Event",allDayText:"all-day",moreLinkText:"more",noEventsText:"No events to display"},RAW_EN_LOCALE=__assign$1(__assign$1({},MINIMAL_RAW_EN_LOCALE),{buttonHints:{prev:"Previous $0",next:"Next $0",today:function(e,t){return"day"===t?"Today":"This "+e}},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show "+e+" more event"+(1===e?"":"s")}});function organizeRawLocales(e){for(var t=e.length>0?e[0].code:"en",n=globalLocales.concat(e),r={en:RAW_EN_LOCALE},o=0,i=n;o<i.length;o++){var a=i[o];r[a.code]=a}return{map:r,defaultCode:t}}function buildLocale(e,t){return"object"!=typeof e||Array.isArray(e)?queryLocale(e,t):parseLocale(e.code,[e.code],e)}function queryLocale(e,t){var n=[].concat(e||[]);return parseLocale(e,n,queryRawLocale(n,t)||RAW_EN_LOCALE)}function queryRawLocale(e,t){for(var n=0;n<e.length;n+=1)for(var r=e[n].toLocaleLowerCase().split("-"),o=r.length;o>0;o-=1){var i=r.slice(0,o).join("-");if(t[i])return t[i]}return null}function parseLocale(e,t,n){var r=mergeProps([MINIMAL_RAW_EN_LOCALE,n],["buttonText"]);delete r.code;var o=r.week;return delete r.week,{codeArg:e,codes:t,week:o,simpleNumberFormat:new Intl.NumberFormat(e),options:r}}var DEF_DEFAULTS={startTime:"09:00",endTime:"17:00",daysOfWeek:[1,2,3,4,5],display:"inverse-background",classNames:"fc-non-business",groupId:"_businessHours"},canVGrowWithinCell;function parseBusinessHours(e,t){return parseEvents(refineInputs(e),null,t)}function refineInputs(e){return(!0===e?[{}]:Array.isArray(e)?e.filter((function(e){return e.daysOfWeek})):"object"==typeof e&&e?[e]:[]).map((function(e){return __assign$1(__assign$1({},DEF_DEFAULTS),e)}))}function pointInsideRect(e,t){return e.left>=t.left&&e.left<t.right&&e.top>=t.top&&e.top<t.bottom}function intersectRects(e,t){var n={left:Math.max(e.left,t.left),right:Math.min(e.right,t.right),top:Math.max(e.top,t.top),bottom:Math.min(e.bottom,t.bottom)};return n.left<n.right&&n.top<n.bottom&&n}function constrainPoint(e,t){return{left:Math.min(Math.max(e.left,t.left),t.right),top:Math.min(Math.max(e.top,t.top),t.bottom)}}function getRectCenter(e){return{left:(e.left+e.right)/2,top:(e.top+e.bottom)/2}}function diffPoints(e,t){return{left:e.left-t.left,top:e.top-t.top}}function getCanVGrowWithinCell(){return null==canVGrowWithinCell&&(canVGrowWithinCell=computeCanVGrowWithinCell()),canVGrowWithinCell}function computeCanVGrowWithinCell(){if("undefined"==typeof document)return!0;var e=document.createElement("div");e.style.position="absolute",e.style.top="0px",e.style.left="0px",e.innerHTML="<table><tr><td><div></div></td></tr></table>",e.querySelector("table").style.height="100px",e.querySelector("div").style.height="100%",document.body.appendChild(e);var t=e.querySelector("div").offsetHeight>0;return document.body.removeChild(e),t}var EMPTY_EVENT_STORE=createEmptyEventStore(),Splitter=function(){function e(){this.getKeysForEventDefs=memoize(this._getKeysForEventDefs),this.splitDateSelection=memoize(this._splitDateSpan),this.splitEventStore=memoize(this._splitEventStore),this.splitIndividualUi=memoize(this._splitIndividualUi),this.splitEventDrag=memoize(this._splitInteraction),this.splitEventResize=memoize(this._splitInteraction),this.eventUiBuilders={}}return e.prototype.splitProps=function(e){var t=this,n=this.getKeyInfo(e),r=this.getKeysForEventDefs(e.eventStore),o=this.splitDateSelection(e.dateSelection),i=this.splitIndividualUi(e.eventUiBases,r),a=this.splitEventStore(e.eventStore,r),s=this.splitEventDrag(e.eventDrag),l=this.splitEventResize(e.eventResize),u={};for(var c in this.eventUiBuilders=mapHash(n,(function(e,n){return t.eventUiBuilders[n]||memoize(buildEventUiForKey)})),n){var d=n[c],p=a[c]||EMPTY_EVENT_STORE,f=this.eventUiBuilders[c];u[c]={businessHours:d.businessHours||e.businessHours,dateSelection:o[c]||null,eventStore:p,eventUiBases:f(e.eventUiBases[""],d.ui,i[c]),eventSelection:p.instances[e.eventSelection]?e.eventSelection:"",eventDrag:s[c]||null,eventResize:l[c]||null}}return u},e.prototype._splitDateSpan=function(e){var t={};if(e)for(var n=0,r=this.getKeysForDateSpan(e);n<r.length;n++){t[r[n]]=e}return t},e.prototype._getKeysForEventDefs=function(e){var t=this;return mapHash(e.defs,(function(e){return t.getKeysForEventDef(e)}))},e.prototype._splitEventStore=function(e,t){var n=e.defs,r=e.instances,o={};for(var i in n)for(var a=0,s=t[i];a<s.length;a++){o[p=s[a]]||(o[p]=createEmptyEventStore()),o[p].defs[i]=n[i]}for(var l in r)for(var u=r[l],c=0,d=t[u.defId];c<d.length;c++){var p;o[p=d[c]]&&(o[p].instances[l]=u)}return o},e.prototype._splitIndividualUi=function(e,t){var n={};for(var r in e)if(r)for(var o=0,i=t[r];o<i.length;o++){var a=i[o];n[a]||(n[a]={}),n[a][r]=e[r]}return n},e.prototype._splitInteraction=function(e){var t={};if(e){var n=this._splitEventStore(e.affectedEvents,this._getKeysForEventDefs(e.affectedEvents)),r=this._getKeysForEventDefs(e.mutatedEvents),o=this._splitEventStore(e.mutatedEvents,r),i=function(r){t[r]||(t[r]={affectedEvents:n[r]||EMPTY_EVENT_STORE,mutatedEvents:o[r]||EMPTY_EVENT_STORE,isEvent:e.isEvent})};for(var a in n)i(a);for(var a in o)i(a)}return t},e}();function buildEventUiForKey(e,t,n){var r=[];e&&r.push(e),t&&r.push(t);var o={"":combineEventUis(r)};return n&&__assign$1(o,n),o}function getDateMeta(e,t,n,r){return{dow:e.getUTCDay(),isDisabled:Boolean(r&&!rangeContainsMarker(r.activeRange,e)),isOther:Boolean(r&&!rangeContainsMarker(r.currentRange,e)),isToday:Boolean(t&&rangeContainsMarker(t,e)),isPast:Boolean(n?e<n:!!t&&e<t.start),isFuture:Boolean(n?e>n:!!t&&e>=t.end)}}function getDayClassNames(e,t){var n=["fc-day","fc-day-"+DAY_IDS[e.dow]];return e.isDisabled?n.push("fc-day-disabled"):(e.isToday&&(n.push("fc-day-today"),n.push(t.getClass("today"))),e.isPast&&n.push("fc-day-past"),e.isFuture&&n.push("fc-day-future"),e.isOther&&n.push("fc-day-other")),n}var DAY_FORMAT=createFormatter({year:"numeric",month:"long",day:"numeric"}),WEEK_FORMAT=createFormatter({week:"long"});function buildNavLinkAttrs(e,t,n,r){void 0===n&&(n="day"),void 0===r&&(r=!0);var o=e.dateEnv,i=e.options,a=e.calendarApi,s=o.format(t,"week"===n?WEEK_FORMAT:DAY_FORMAT);if(i.navLinks){var l=o.toDate(t),u=function(e){var r="day"===n?i.navLinkDayClick:"week"===n?i.navLinkWeekClick:null;"function"==typeof r?r.call(a,o.toDate(t),e):("string"==typeof r&&(n=r),a.zoomTo(t,n))};return __assign$1({title:formatWithOrdinals(i.navLinkHint,[s,l],s),"data-navlink":""},r?createAriaClickAttrs(u):{onClick:u})}return{"aria-label":s}}var _isRtlScrollbarOnLeft=null,_scrollbarWidths;function getIsRtlScrollbarOnLeft(){return null===_isRtlScrollbarOnLeft&&(_isRtlScrollbarOnLeft=computeIsRtlScrollbarOnLeft()),_isRtlScrollbarOnLeft}function computeIsRtlScrollbarOnLeft(){var e=document.createElement("div");applyStyle(e,{position:"absolute",top:-1e3,left:0,border:0,padding:0,overflow:"scroll",direction:"rtl"}),e.innerHTML="<div></div>",document.body.appendChild(e);var t=e.firstChild.getBoundingClientRect().left>e.getBoundingClientRect().left;return removeElement(e),t}function getScrollbarWidths(){return _scrollbarWidths||(_scrollbarWidths=computeScrollbarWidths()),_scrollbarWidths}function computeScrollbarWidths(){var e=document.createElement("div");e.style.overflow="scroll",e.style.position="absolute",e.style.top="-9999px",e.style.left="-9999px",document.body.appendChild(e);var t=computeScrollbarWidthsForEl(e);return document.body.removeChild(e),t}function computeScrollbarWidthsForEl(e){return{x:e.offsetHeight-e.clientHeight,y:e.offsetWidth-e.clientWidth}}function computeEdges(e,t){void 0===t&&(t=!1);var n=window.getComputedStyle(e),r=parseInt(n.borderLeftWidth,10)||0,o=parseInt(n.borderRightWidth,10)||0,i=parseInt(n.borderTopWidth,10)||0,a=parseInt(n.borderBottomWidth,10)||0,s=computeScrollbarWidthsForEl(e),l=s.y-r-o,u={borderLeft:r,borderRight:o,borderTop:i,borderBottom:a,scrollbarBottom:s.x-i-a,scrollbarLeft:0,scrollbarRight:0};return getIsRtlScrollbarOnLeft()&&"rtl"===n.direction?u.scrollbarLeft=l:u.scrollbarRight=l,t&&(u.paddingLeft=parseInt(n.paddingLeft,10)||0,u.paddingRight=parseInt(n.paddingRight,10)||0,u.paddingTop=parseInt(n.paddingTop,10)||0,u.paddingBottom=parseInt(n.paddingBottom,10)||0),u}function computeInnerRect(e,t,n){void 0===t&&(t=!1);var r=n?e.getBoundingClientRect():computeRect(e),o=computeEdges(e,t),i={left:r.left+o.borderLeft+o.scrollbarLeft,right:r.right-o.borderRight-o.scrollbarRight,top:r.top+o.borderTop,bottom:r.bottom-o.borderBottom-o.scrollbarBottom};return t&&(i.left+=o.paddingLeft,i.right-=o.paddingRight,i.top+=o.paddingTop,i.bottom-=o.paddingBottom),i}function computeRect(e){var t=e.getBoundingClientRect();return{left:t.left+window.pageXOffset,top:t.top+window.pageYOffset,right:t.right+window.pageXOffset,bottom:t.bottom+window.pageYOffset}}function computeClippedClientRect(e){for(var t=getClippingParents(e),n=e.getBoundingClientRect(),r=0,o=t;r<o.length;r++){var i=intersectRects(n,o[r].getBoundingClientRect());if(!i)return null;n=i}return n}function getClippingParents(e){for(var t=[];e instanceof HTMLElement;){var n=window.getComputedStyle(e);if("fixed"===n.position)break;/(auto|scroll)/.test(n.overflow+n.overflowY+n.overflowX)&&t.push(e),e=e.parentNode}return t}function unpromisify(e,t,n){var r=!1,o=function(){r||(r=!0,t.apply(this,arguments))},i=function(){r||(r=!0,n&&n.apply(this,arguments))},a=e(o,i);a&&"function"==typeof a.then&&a.then(o,i)}var Emitter=function(){function e(){this.handlers={},this.thisContext=null}return e.prototype.setThisContext=function(e){this.thisContext=e},e.prototype.setOptions=function(e){this.options=e},e.prototype.on=function(e,t){addToHash(this.handlers,e,t)},e.prototype.off=function(e,t){removeFromHash(this.handlers,e,t)},e.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=this.handlers[e]||[],o=this.options&&this.options[e],i=[].concat(o||[],r),a=0,s=i;a<s.length;a++){var l=s[a];l.apply(this.thisContext,t)}},e.prototype.hasHandlers=function(e){return Boolean(this.handlers[e]&&this.handlers[e].length||this.options&&this.options[e])},e}();function addToHash(e,t,n){(e[t]||(e[t]=[])).push(n)}function removeFromHash(e,t,n){n?e[t]&&(e[t]=e[t].filter((function(e){return e!==n}))):delete e[t]}var PositionCache=function(){function e(e,t,n,r){this.els=t;var o=this.originClientRect=e.getBoundingClientRect();n&&this.buildElHorizontals(o.left),r&&this.buildElVerticals(o.top)}return e.prototype.buildElHorizontals=function(e){for(var t=[],n=[],r=0,o=this.els;r<o.length;r++){var i=o[r].getBoundingClientRect();t.push(i.left-e),n.push(i.right-e)}this.lefts=t,this.rights=n},e.prototype.buildElVerticals=function(e){for(var t=[],n=[],r=0,o=this.els;r<o.length;r++){var i=o[r].getBoundingClientRect();t.push(i.top-e),n.push(i.bottom-e)}this.tops=t,this.bottoms=n},e.prototype.leftToIndex=function(e){var t,n=this.lefts,r=this.rights,o=n.length;for(t=0;t<o;t+=1)if(e>=n[t]&&e<r[t])return t},e.prototype.topToIndex=function(e){var t,n=this.tops,r=this.bottoms,o=n.length;for(t=0;t<o;t+=1)if(e>=n[t]&&e<r[t])return t},e.prototype.getWidth=function(e){return this.rights[e]-this.lefts[e]},e.prototype.getHeight=function(e){return this.bottoms[e]-this.tops[e]},e}(),ScrollController=function(){function e(){}return e.prototype.getMaxScrollTop=function(){return this.getScrollHeight()-this.getClientHeight()},e.prototype.getMaxScrollLeft=function(){return this.getScrollWidth()-this.getClientWidth()},e.prototype.canScrollVertically=function(){return this.getMaxScrollTop()>0},e.prototype.canScrollHorizontally=function(){return this.getMaxScrollLeft()>0},e.prototype.canScrollUp=function(){return this.getScrollTop()>0},e.prototype.canScrollDown=function(){return this.getScrollTop()<this.getMaxScrollTop()},e.prototype.canScrollLeft=function(){return this.getScrollLeft()>0},e.prototype.canScrollRight=function(){return this.getScrollLeft()<this.getMaxScrollLeft()},e}(),ElementScrollController=function(e){function t(t){var n=e.call(this)||this;return n.el=t,n}return __extends(t,e),t.prototype.getScrollTop=function(){return this.el.scrollTop},t.prototype.getScrollLeft=function(){return this.el.scrollLeft},t.prototype.setScrollTop=function(e){this.el.scrollTop=e},t.prototype.setScrollLeft=function(e){this.el.scrollLeft=e},t.prototype.getScrollWidth=function(){return this.el.scrollWidth},t.prototype.getScrollHeight=function(){return this.el.scrollHeight},t.prototype.getClientHeight=function(){return this.el.clientHeight},t.prototype.getClientWidth=function(){return this.el.clientWidth},t}(ScrollController),WindowScrollController=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.getScrollTop=function(){return window.pageYOffset},t.prototype.getScrollLeft=function(){return window.pageXOffset},t.prototype.setScrollTop=function(e){window.scroll(window.pageXOffset,e)},t.prototype.setScrollLeft=function(e){window.scroll(e,window.pageYOffset)},t.prototype.getScrollWidth=function(){return document.documentElement.scrollWidth},t.prototype.getScrollHeight=function(){return document.documentElement.scrollHeight},t.prototype.getClientHeight=function(){return document.documentElement.clientHeight},t.prototype.getClientWidth=function(){return document.documentElement.clientWidth},t}(ScrollController),Theme=function(){function e(e){this.iconOverrideOption&&this.setIconOverride(e[this.iconOverrideOption])}return e.prototype.setIconOverride=function(e){var t,n;if("object"==typeof e&&e){for(n in t=__assign$1({},this.iconClasses),e)t[n]=this.applyIconOverridePrefix(e[n]);this.iconClasses=t}else!1===e&&(this.iconClasses={})},e.prototype.applyIconOverridePrefix=function(e){var t=this.iconOverridePrefix;return t&&0!==e.indexOf(t)&&(e=t+e),e},e.prototype.getClass=function(e){return this.classes[e]||""},e.prototype.getIconClass=function(e,t){var n;return(n=t&&this.rtlIconClasses&&this.rtlIconClasses[e]||this.iconClasses[e])?this.baseIconClass+" "+n:""},e.prototype.getCustomButtonIconClass=function(e){var t;return this.iconOverrideCustomButtonOption&&(t=e[this.iconOverrideCustomButtonOption])?this.baseIconClass+" "+this.applyIconOverridePrefix(t):""},e}();Theme.prototype.classes={},Theme.prototype.iconClasses={},Theme.prototype.baseIconClass="",Theme.prototype.iconOverridePrefix="";var ScrollResponder=function(){function e(e,t,n,r){var o=this;this.execFunc=e,this.emitter=t,this.scrollTime=n,this.scrollTimeReset=r,this.handleScrollRequest=function(e){o.queuedRequest=__assign$1({},o.queuedRequest||{},e),o.drain()},t.on("_scrollRequest",this.handleScrollRequest),this.fireInitialScroll()}return e.prototype.detach=function(){this.emitter.off("_scrollRequest",this.handleScrollRequest)},e.prototype.update=function(e){e&&this.scrollTimeReset?this.fireInitialScroll():this.drain()},e.prototype.fireInitialScroll=function(){this.handleScrollRequest({time:this.scrollTime})},e.prototype.drain=function(){this.queuedRequest&&this.execFunc(this.queuedRequest)&&(this.queuedRequest=null)},e}(),ViewContextType=createContext({});function buildViewContext(e,t,n,r,o,i,a,s,l,u,c,d,p){return{dateEnv:o,options:n,pluginHooks:a,emitter:u,dispatch:s,getCurrentData:l,calendarApi:c,viewSpec:e,viewApi:t,dateProfileGenerator:r,theme:i,isRtl:"rtl"===n.direction,addResizeHandler:function(e){u.on("_resize",e)},removeResizeHandler:function(e){u.off("_resize",e)},createScrollResponder:function(e){return new ScrollResponder(e,u,createDuration(n.scrollTime),n.scrollTimeReset)},registerInteractiveComponent:d,unregisterInteractiveComponent:p}}var PureComponent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.shouldComponentUpdate=function(e,t){return this.debug&&console.log(getUnequalProps(e,this.props),getUnequalProps(t,this.state)),!compareObjs(this.props,e,this.propEquality)||!compareObjs(this.state,t,this.stateEquality)},t.prototype.safeSetState=function(e){compareObjs(this.state,__assign$1(__assign$1({},this.state),e),this.stateEquality)||this.setState(e)},t.addPropsEquality=addPropsEquality,t.addStateEquality=addStateEquality,t.contextType=ViewContextType,t}(Component);PureComponent.prototype.propEquality={},PureComponent.prototype.stateEquality={};var BaseComponent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.contextType=ViewContextType,t}(PureComponent);function addPropsEquality(e){var t=Object.create(this.prototype.propEquality);__assign$1(t,e),this.prototype.propEquality=t}function addStateEquality(e){var t=Object.create(this.prototype.stateEquality);__assign$1(t,e),this.prototype.stateEquality=t}function setRef(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var DateComponent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.uid=guid(),t}return __extends(t,e),t.prototype.prepareHits=function(){},t.prototype.queryHit=function(e,t,n,r){return null},t.prototype.isValidSegDownEl=function(e){return!this.props.eventDrag&&!this.props.eventResize&&!elementClosest(e,".fc-event-mirror")},t.prototype.isValidDateDownEl=function(e){return!(elementClosest(e,".fc-event:not(.fc-bg-event)")||elementClosest(e,".fc-more-link")||elementClosest(e,"a[data-navlink]")||elementClosest(e,".fc-popover"))},t}(BaseComponent);function createPlugin(e){return{id:guid(),deps:e.deps||[],reducers:e.reducers||[],isLoadingFuncs:e.isLoadingFuncs||[],contextInit:[].concat(e.contextInit||[]),eventRefiners:e.eventRefiners||{},eventDefMemberAdders:e.eventDefMemberAdders||[],eventSourceRefiners:e.eventSourceRefiners||{},isDraggableTransformers:e.isDraggableTransformers||[],eventDragMutationMassagers:e.eventDragMutationMassagers||[],eventDefMutationAppliers:e.eventDefMutationAppliers||[],dateSelectionTransformers:e.dateSelectionTransformers||[],datePointTransforms:e.datePointTransforms||[],dateSpanTransforms:e.dateSpanTransforms||[],views:e.views||{},viewPropsTransformers:e.viewPropsTransformers||[],isPropsValid:e.isPropsValid||null,externalDefTransforms:e.externalDefTransforms||[],viewContainerAppends:e.viewContainerAppends||[],eventDropTransformers:e.eventDropTransformers||[],componentInteractions:e.componentInteractions||[],calendarInteractions:e.calendarInteractions||[],themeClasses:e.themeClasses||{},eventSourceDefs:e.eventSourceDefs||[],cmdFormatter:e.cmdFormatter,recurringTypes:e.recurringTypes||[],namedTimeZonedImpl:e.namedTimeZonedImpl,initialView:e.initialView||"",elementDraggingImpl:e.elementDraggingImpl,optionChangeHandlers:e.optionChangeHandlers||{},scrollGridImpl:e.scrollGridImpl||null,contentTypeHandlers:e.contentTypeHandlers||{},listenerRefiners:e.listenerRefiners||{},optionRefiners:e.optionRefiners||{},propSetHandlers:e.propSetHandlers||{}}}function buildPluginHooks(e,t){var n={},r={reducers:[],isLoadingFuncs:[],contextInit:[],eventRefiners:{},eventDefMemberAdders:[],eventSourceRefiners:{},isDraggableTransformers:[],eventDragMutationMassagers:[],eventDefMutationAppliers:[],dateSelectionTransformers:[],datePointTransforms:[],dateSpanTransforms:[],views:{},viewPropsTransformers:[],isPropsValid:null,externalDefTransforms:[],viewContainerAppends:[],eventDropTransformers:[],componentInteractions:[],calendarInteractions:[],themeClasses:{},eventSourceDefs:[],cmdFormatter:null,recurringTypes:[],namedTimeZonedImpl:null,initialView:"",elementDraggingImpl:null,optionChangeHandlers:{},scrollGridImpl:null,contentTypeHandlers:{},listenerRefiners:{},optionRefiners:{},propSetHandlers:{}};function o(e){for(var t=0,i=e;t<i.length;t++){var a=i[t];n[a.id]||(n[a.id]=!0,o(a.deps),r=combineHooks(r,a))}}return e&&o(e),o(t),r}function buildBuildPluginHooks(){var e,t=[],n=[];return function(r,o){return e&&isArraysEqual(r,t)&&isArraysEqual(o,n)||(e=buildPluginHooks(r,o)),t=r,n=o,e}}function combineHooks(e,t){return{reducers:e.reducers.concat(t.reducers),isLoadingFuncs:e.isLoadingFuncs.concat(t.isLoadingFuncs),contextInit:e.contextInit.concat(t.contextInit),eventRefiners:__assign$1(__assign$1({},e.eventRefiners),t.eventRefiners),eventDefMemberAdders:e.eventDefMemberAdders.concat(t.eventDefMemberAdders),eventSourceRefiners:__assign$1(__assign$1({},e.eventSourceRefiners),t.eventSourceRefiners),isDraggableTransformers:e.isDraggableTransformers.concat(t.isDraggableTransformers),eventDragMutationMassagers:e.eventDragMutationMassagers.concat(t.eventDragMutationMassagers),eventDefMutationAppliers:e.eventDefMutationAppliers.concat(t.eventDefMutationAppliers),dateSelectionTransformers:e.dateSelectionTransformers.concat(t.dateSelectionTransformers),datePointTransforms:e.datePointTransforms.concat(t.datePointTransforms),dateSpanTransforms:e.dateSpanTransforms.concat(t.dateSpanTransforms),views:__assign$1(__assign$1({},e.views),t.views),viewPropsTransformers:e.viewPropsTransformers.concat(t.viewPropsTransformers),isPropsValid:t.isPropsValid||e.isPropsValid,externalDefTransforms:e.externalDefTransforms.concat(t.externalDefTransforms),viewContainerAppends:e.viewContainerAppends.concat(t.viewContainerAppends),eventDropTransformers:e.eventDropTransformers.concat(t.eventDropTransformers),calendarInteractions:e.calendarInteractions.concat(t.calendarInteractions),componentInteractions:e.componentInteractions.concat(t.componentInteractions),themeClasses:__assign$1(__assign$1({},e.themeClasses),t.themeClasses),eventSourceDefs:e.eventSourceDefs.concat(t.eventSourceDefs),cmdFormatter:t.cmdFormatter||e.cmdFormatter,recurringTypes:e.recurringTypes.concat(t.recurringTypes),namedTimeZonedImpl:t.namedTimeZonedImpl||e.namedTimeZonedImpl,initialView:e.initialView||t.initialView,elementDraggingImpl:e.elementDraggingImpl||t.elementDraggingImpl,optionChangeHandlers:__assign$1(__assign$1({},e.optionChangeHandlers),t.optionChangeHandlers),scrollGridImpl:t.scrollGridImpl||e.scrollGridImpl,contentTypeHandlers:__assign$1(__assign$1({},e.contentTypeHandlers),t.contentTypeHandlers),listenerRefiners:__assign$1(__assign$1({},e.listenerRefiners),t.listenerRefiners),optionRefiners:__assign$1(__assign$1({},e.optionRefiners),t.optionRefiners),propSetHandlers:__assign$1(__assign$1({},e.propSetHandlers),t.propSetHandlers)}}var StandardTheme=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t}(Theme);function compileViewDefs(e,t){var n,r={};for(n in e)ensureViewDef(n,r,e,t);for(n in t)ensureViewDef(n,r,e,t);return r}function ensureViewDef(e,t,n,r){if(t[e])return t[e];var o=buildViewDef(e,t,n,r);return o&&(t[e]=o),o}function buildViewDef(e,t,n,r){var o=n[e],i=r[e],a=function(e){return o&&null!==o[e]?o[e]:i&&null!==i[e]?i[e]:null},s=a("component"),l=a("superType"),u=null;if(l){if(l===e)throw new Error("Can't have a custom view type that references itself");u=ensureViewDef(l,t,n,r)}return!s&&u&&(s=u.component),s?{type:e,component:s,defaults:__assign$1(__assign$1({},u?u.defaults:{}),o?o.rawOptions:{}),overrides:__assign$1(__assign$1({},u?u.overrides:{}),i?i.rawOptions:{})}:null}StandardTheme.prototype.classes={root:"fc-theme-standard",tableCellShaded:"fc-cell-shaded",buttonGroup:"fc-button-group",button:"fc-button fc-button-primary",buttonActive:"fc-button-active"},StandardTheme.prototype.baseIconClass="fc-icon",StandardTheme.prototype.iconClasses={close:"fc-icon-x",prev:"fc-icon-chevron-left",next:"fc-icon-chevron-right",prevYear:"fc-icon-chevrons-left",nextYear:"fc-icon-chevrons-right"},StandardTheme.prototype.rtlIconClasses={prev:"fc-icon-chevron-right",next:"fc-icon-chevron-left",prevYear:"fc-icon-chevrons-right",nextYear:"fc-icon-chevrons-left"},StandardTheme.prototype.iconOverrideOption="buttonIcons",StandardTheme.prototype.iconOverrideCustomButtonOption="icon",StandardTheme.prototype.iconOverridePrefix="fc-icon-";var RenderHook=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.handleRootEl=function(e){setRef(t.rootElRef,e),t.props.elRef&&setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.hookProps;return createElement(MountHook,{hookProps:n,didMount:t.didMount,willUnmount:t.willUnmount,elRef:this.handleRootEl},(function(r){return createElement(ContentHook,{hookProps:n,content:t.content,defaultContent:t.defaultContent,backupElRef:e.rootElRef},(function(e,o){return t.children(r,normalizeClassNames(t.classNames,n),e,o)}))}))},t}(BaseComponent),CustomContentRenderContext=createContext(0);function ContentHook(e){return createElement(CustomContentRenderContext.Consumer,null,(function(t){return createElement(ContentHookInner,__assign$1({renderId:t},e))}))}var ContentHookInner=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.innerElRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.innerElRef,this.renderInnerContent())},t.prototype.componentDidMount=function(){this.updateCustomContent()},t.prototype.componentDidUpdate=function(){this.updateCustomContent()},t.prototype.componentWillUnmount=function(){this.customContentInfo&&this.customContentInfo.destroy&&this.customContentInfo.destroy()},t.prototype.renderInnerContent=function(){var e=this.customContentInfo,t=this.getInnerContent(),n=this.getContentMeta(t);return e&&e.contentKey===n.contentKey?e&&(e.contentVal=t[n.contentKey]):(e&&(e.destroy&&e.destroy(),e=this.customContentInfo=null),n.contentKey&&(e=this.customContentInfo=__assign$1({contentKey:n.contentKey,contentVal:t[n.contentKey]},n.buildLifecycleFuncs()))),e?[]:t},t.prototype.getInnerContent=function(){var e=this.props,t=normalizeContent(e.content,e.hookProps);return void 0===t&&(t=normalizeContent(e.defaultContent,e.hookProps)),null==t?null:t},t.prototype.getContentMeta=function(e){var t=this.context.pluginHooks.contentTypeHandlers,n="",r=null;if(e)for(var o in t)if(void 0!==e[o]){n=o,r=t[o];break}return{contentKey:n,buildLifecycleFuncs:r}},t.prototype.updateCustomContent=function(){this.customContentInfo&&this.customContentInfo.render(this.innerElRef.current||this.props.backupElRef.current,this.customContentInfo.contentVal)},t}(BaseComponent),MountHook=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleRootEl=function(e){t.rootEl=e,t.props.elRef&&setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.handleRootEl)},t.prototype.componentDidMount=function(){var e=this.props.didMount;e&&e(__assign$1(__assign$1({},this.props.hookProps),{el:this.rootEl}))},t.prototype.componentWillUnmount=function(){var e=this.props.willUnmount;e&&e(__assign$1(__assign$1({},this.props.hookProps),{el:this.rootEl}))},t}(BaseComponent);function buildClassNameNormalizer(){var e,t,n=[];return function(r,o){return t&&isPropsEqual(t,o)&&r===e||(e=r,t=o,n=normalizeClassNames(r,o)),n}}function normalizeClassNames(e,t){return"function"==typeof e&&(e=e(t)),parseClassNames(e)}function normalizeContent(e,t){return"function"==typeof e?e(t,createElement):e}var ViewRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.normalizeClassNames=buildClassNameNormalizer(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r={view:t.viewApi},o=this.normalizeClassNames(n.viewClassNames,r);return createElement(MountHook,{hookProps:r,didMount:n.viewDidMount,willUnmount:n.viewWillUnmount,elRef:e.elRef},(function(t){return e.children(t,["fc-"+e.viewSpec.type+"-view","fc-view"].concat(o))}))},t}(BaseComponent);function parseViewConfigs(e){return mapHash(e,parseViewConfig)}function parseViewConfig(e){var t="function"==typeof e?{component:e}:e,n=t.component;return t.content&&(n=createViewHookComponent(t)),{superType:t.type,component:n,rawOptions:t}}function createViewHookComponent(e){return function(t){return createElement(ViewContextType.Consumer,null,(function(n){return createElement(ViewRoot,{viewSpec:n.viewSpec},(function(r,o){var i=__assign$1(__assign$1({},t),{nextDayThreshold:n.options.nextDayThreshold});return createElement(RenderHook,{hookProps:i,classNames:e.classNames,content:e.content,didMount:e.didMount,willUnmount:e.willUnmount,elRef:r},(function(e,t,n,r){return createElement("div",{className:o.concat(t).join(" "),ref:e},r)}))}))}))}}function buildViewSpecs(e,t,n,r){var o=parseViewConfigs(e),i=parseViewConfigs(t.views);return mapHash(compileViewDefs(o,i),(function(e){return buildViewSpec(e,i,t,n,r)}))}function buildViewSpec(e,t,n,r,o){var i=e.overrides.duration||e.defaults.duration||r.duration||n.duration,a=null,s="",l="",u={};if(i&&(a=createDurationCached(i))){var c=greatestDurationDenominator(a);s=c.unit,1===c.value&&(l=s,u=t[s]?t[s].rawOptions:{})}var d=function(t){var n=t.buttonText||{},r=e.defaults.buttonTextKey;return null!=r&&null!=n[r]?n[r]:null!=n[e.type]?n[e.type]:null!=n[l]?n[l]:null},p=function(t){var n=t.buttonHints||{},r=e.defaults.buttonTextKey;return null!=r&&null!=n[r]?n[r]:null!=n[e.type]?n[e.type]:null!=n[l]?n[l]:null};return{type:e.type,component:e.component,duration:a,durationUnit:s,singleUnit:l,optionDefaults:e.defaults,optionOverrides:__assign$1(__assign$1({},u),e.overrides),buttonTextOverride:d(r)||d(n)||e.overrides.buttonText,buttonTextDefault:d(o)||e.defaults.buttonText||d(BASE_OPTION_DEFAULTS)||e.type,buttonTitleOverride:p(r)||p(n)||e.overrides.buttonHint,buttonTitleDefault:p(o)||e.defaults.buttonHint||p(BASE_OPTION_DEFAULTS)}}var durationInputMap={};function createDurationCached(e){var t=JSON.stringify(e),n=durationInputMap[t];return void 0===n&&(n=createDuration(e),durationInputMap[t]=n),n}var DateProfileGenerator=function(){function e(e){this.props=e,this.nowDate=getNow(e.nowInput,e.dateEnv),this.initHiddenDays()}return e.prototype.buildPrev=function(e,t,n){var r=this.props.dateEnv,o=r.subtract(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(o,-1,n)},e.prototype.buildNext=function(e,t,n){var r=this.props.dateEnv,o=r.add(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(o,1,n)},e.prototype.build=function(e,t,n){void 0===n&&(n=!0);var r,o,i,a,s,l,u=this.props;return r=this.buildValidRange(),r=this.trimHiddenDays(r),n&&(e=constrainMarkerToRange(e,r)),o=this.buildCurrentRangeInfo(e,t),i=/^(year|month|week|day)$/.test(o.unit),a=this.buildRenderRange(this.trimHiddenDays(o.range),o.unit,i),s=a=this.trimHiddenDays(a),u.showNonCurrentDates||(s=intersectRanges(s,o.range)),s=intersectRanges(s=this.adjustActiveRange(s),r),l=rangesIntersect(o.range,r),{validRange:r,currentRange:o.range,currentRangeUnit:o.unit,isRangeAllDay:i,activeRange:s,renderRange:a,slotMinTime:u.slotMinTime,slotMaxTime:u.slotMaxTime,isValid:l,dateIncrement:this.buildDateIncrement(o.duration)}},e.prototype.buildValidRange=function(){var e=this.props.validRangeInput,t="function"==typeof e?e.call(this.props.calendarApi,this.nowDate):e;return this.refineRange(t)||{start:null,end:null}},e.prototype.buildCurrentRangeInfo=function(e,t){var n,r=this.props,o=null,i=null,a=null;return r.duration?(o=r.duration,i=r.durationUnit,a=this.buildRangeFromDuration(e,t,o,i)):(n=this.props.dayCount)?(i="day",a=this.buildRangeFromDayCount(e,t,n)):(a=this.buildCustomVisibleRange(e))?i=r.dateEnv.greatestWholeUnit(a.start,a.end).unit:(i=greatestDurationDenominator(o=this.getFallbackDuration()).unit,a=this.buildRangeFromDuration(e,t,o,i)),{duration:o,unit:i,range:a}},e.prototype.getFallbackDuration=function(){return createDuration({day:1})},e.prototype.adjustActiveRange=function(e){var t=this.props,n=t.dateEnv,r=t.usesMinMaxTime,o=t.slotMinTime,i=t.slotMaxTime,a=e.start,s=e.end;return r&&(asRoughDays(o)<0&&(a=startOfDay(a),a=n.add(a,o)),asRoughDays(i)>1&&(s=addDays(s=startOfDay(s),-1),s=n.add(s,i))),{start:a,end:s}},e.prototype.buildRangeFromDuration=function(e,t,n,r){var o,i,a,s=this.props,l=s.dateEnv,u=s.dateAlignment;if(!u){var c=this.props.dateIncrement;u=c&&asRoughMs(c)<asRoughMs(n)?greatestDurationDenominator(c).unit:r}function d(){o=l.startOf(e,u),i=l.add(o,n),a={start:o,end:i}}return asRoughDays(n)<=1&&this.isHiddenDay(o)&&(o=startOfDay(o=this.skipHiddenDays(o,t))),d(),this.trimHiddenDays(a)||(e=this.skipHiddenDays(e,t),d()),a},e.prototype.buildRangeFromDayCount=function(e,t,n){var r,o=this.props,i=o.dateEnv,a=o.dateAlignment,s=0,l=e;a&&(l=i.startOf(l,a)),l=startOfDay(l),r=l=this.skipHiddenDays(l,t);do{r=addDays(r,1),this.isHiddenDay(r)||(s+=1)}while(s<n);return{start:l,end:r}},e.prototype.buildCustomVisibleRange=function(e){var t=this.props,n=t.visibleRangeInput,r="function"==typeof n?n.call(t.calendarApi,t.dateEnv.toDate(e)):n,o=this.refineRange(r);return!o||null!=o.start&&null!=o.end?o:null},e.prototype.buildRenderRange=function(e,t,n){return e},e.prototype.buildDateIncrement=function(e){var t,n=this.props.dateIncrement;return n||((t=this.props.dateAlignment)?createDuration(1,t):e||createDuration({days:1}))},e.prototype.refineRange=function(e){if(e){var t=parseRange(e,this.props.dateEnv);return t&&(t=computeVisibleDayRange(t)),t}return null},e.prototype.initHiddenDays=function(){var e,t=this.props.hiddenDays||[],n=[],r=0;for(!1===this.props.weekends&&t.push(0,6),e=0;e<7;e+=1)(n[e]=-1!==t.indexOf(e))||(r+=1);if(!r)throw new Error("invalid hiddenDays");this.isHiddenDayHash=n},e.prototype.trimHiddenDays=function(e){var t=e.start,n=e.end;return t&&(t=this.skipHiddenDays(t)),n&&(n=this.skipHiddenDays(n,-1,!0)),null==t||null==n||t<n?{start:t,end:n}:null},e.prototype.isHiddenDay=function(e){return e instanceof Date&&(e=e.getUTCDay()),this.isHiddenDayHash[e]},e.prototype.skipHiddenDays=function(e,t,n){for(void 0===t&&(t=1),void 0===n&&(n=!1);this.isHiddenDayHash[(e.getUTCDay()+(n?t:0)+7)%7];)e=addDays(e,t);return e},e}();function reduceViewType(e,t){if("CHANGE_VIEW_TYPE"===t.type)e=t.viewType;return e}function reduceDynamicOptionOverrides(e,t){var n;return"SET_OPTION"===t.type?__assign$1(__assign$1({},e),((n={})[t.optionName]=t.rawOptionValue,n)):e}function reduceDateProfile(e,t,n,r){var o;switch(t.type){case"CHANGE_VIEW_TYPE":return r.build(t.dateMarker||n);case"CHANGE_DATE":return r.build(t.dateMarker);case"PREV":if((o=r.buildPrev(e,n)).isValid)return o;break;case"NEXT":if((o=r.buildNext(e,n)).isValid)return o}return e}function initEventSources(e,t,n){var r=t?t.activeRange:null;return addSources({},parseInitialSources(e,n),r,n)}function reduceEventSources(e,t,n,r){var o=n?n.activeRange:null;switch(t.type){case"ADD_EVENT_SOURCES":return addSources(e,t.sources,o,r);case"REMOVE_EVENT_SOURCE":return removeSource(e,t.sourceId);case"PREV":case"NEXT":case"CHANGE_DATE":case"CHANGE_VIEW_TYPE":return n?fetchDirtySources(e,o,r):e;case"FETCH_EVENT_SOURCES":return fetchSourcesByIds(e,t.sourceIds?arrayToHash(t.sourceIds):excludeStaticSources(e,r),o,t.isRefetch||!1,r);case"RECEIVE_EVENTS":case"RECEIVE_EVENT_ERROR":return receiveResponse(e,t.sourceId,t.fetchId,t.fetchRange);case"REMOVE_ALL_EVENT_SOURCES":return{};default:return e}}function reduceEventSourcesNewTimeZone(e,t,n){var r=t?t.activeRange:null;return fetchSourcesByIds(e,excludeStaticSources(e,n),r,!0,n)}function computeEventSourcesLoading(e){for(var t in e)if(e[t].isFetching)return!0;return!1}function addSources(e,t,n,r){for(var o={},i=0,a=t;i<a.length;i++){var s=a[i];o[s.sourceId]=s}return n&&(o=fetchDirtySources(o,n,r)),__assign$1(__assign$1({},e),o)}function removeSource(e,t){return filterHash(e,(function(e){return e.sourceId!==t}))}function fetchDirtySources(e,t,n){return fetchSourcesByIds(e,filterHash(e,(function(e){return isSourceDirty(e,t,n)})),t,!1,n)}function isSourceDirty(e,t,n){return doesSourceNeedRange(e,n)?!n.options.lazyFetching||!e.fetchRange||e.isFetching||t.start<e.fetchRange.start||t.end>e.fetchRange.end:!e.latestFetchId}function fetchSourcesByIds(e,t,n,r,o){var i={};for(var a in e){var s=e[a];t[a]?i[a]=fetchSource(s,n,r,o):i[a]=s}return i}function fetchSource(e,t,n,r){var o=r.options,i=r.calendarApi,a=r.pluginHooks.eventSourceDefs[e.sourceDefId],s=guid();return a.fetch({eventSource:e,range:t,isRefetch:n,context:r},(function(n){var a=n.rawEvents;o.eventSourceSuccess&&(a=o.eventSourceSuccess.call(i,a,n.xhr)||a),e.success&&(a=e.success.call(i,a,n.xhr)||a),r.dispatch({type:"RECEIVE_EVENTS",sourceId:e.sourceId,fetchId:s,fetchRange:t,rawEvents:a})}),(function(n){console.warn(n.message,n),o.eventSourceFailure&&o.eventSourceFailure.call(i,n),e.failure&&e.failure(n),r.dispatch({type:"RECEIVE_EVENT_ERROR",sourceId:e.sourceId,fetchId:s,fetchRange:t,error:n})})),__assign$1(__assign$1({},e),{isFetching:!0,latestFetchId:s})}function receiveResponse(e,t,n,r){var o,i=e[t];return i&&n===i.latestFetchId?__assign$1(__assign$1({},e),((o={})[t]=__assign$1(__assign$1({},i),{isFetching:!1,fetchRange:r}),o)):e}function excludeStaticSources(e,t){return filterHash(e,(function(e){return doesSourceNeedRange(e,t)}))}function parseInitialSources(e,t){var n=buildEventSourceRefiners(t),r=[].concat(e.eventSources||[]),o=[];e.initialEvents&&r.unshift(e.initialEvents),e.events&&r.unshift(e.events);for(var i=0,a=r;i<a.length;i++){var s=parseEventSource(a[i],t,n);s&&o.push(s)}return o}function doesSourceNeedRange(e,t){return!t.pluginHooks.eventSourceDefs[e.sourceDefId].ignoreRange}function reduceEventStore(e,t,n,r,o){switch(t.type){case"RECEIVE_EVENTS":return receiveRawEvents(e,n[t.sourceId],t.fetchId,t.fetchRange,t.rawEvents,o);case"ADD_EVENTS":return addEvent(e,t.eventStore,r?r.activeRange:null,o);case"RESET_EVENTS":return t.eventStore;case"MERGE_EVENTS":return mergeEventStores(e,t.eventStore);case"PREV":case"NEXT":case"CHANGE_DATE":case"CHANGE_VIEW_TYPE":return r?expandRecurring(e,r.activeRange,o):e;case"REMOVE_EVENTS":return excludeSubEventStore(e,t.eventStore);case"REMOVE_EVENT_SOURCE":return excludeEventsBySourceId(e,t.sourceId);case"REMOVE_ALL_EVENT_SOURCES":return filterEventStoreDefs(e,(function(e){return!e.sourceId}));case"REMOVE_ALL_EVENTS":return createEmptyEventStore();default:return e}}function receiveRawEvents(e,t,n,r,o,i){if(t&&n===t.latestFetchId){var a=parseEvents(transformRawEvents(o,t,i),t,i);return r&&(a=expandRecurring(a,r,i)),mergeEventStores(excludeEventsBySourceId(e,t.sourceId),a)}return e}function transformRawEvents(e,t,n){var r=n.options.eventDataTransform,o=t?t.eventDataTransform:null;return o&&(e=transformEachRawEvent(e,o)),r&&(e=transformEachRawEvent(e,r)),e}function transformEachRawEvent(e,t){var n;if(t){n=[];for(var r=0,o=e;r<o.length;r++){var i=o[r],a=t(i);a?n.push(a):null==a&&n.push(i)}}else n=e;return n}function addEvent(e,t,n,r){return n&&(t=expandRecurring(t,n,r)),mergeEventStores(e,t)}function rezoneEventStoreDates(e,t,n){var r=e.defs,o=mapHash(e.instances,(function(e){var o=r[e.defId];return o.allDay||o.recurringDef?e:__assign$1(__assign$1({},e),{range:{start:n.createMarker(t.toDate(e.range.start,e.forcedStartTzo)),end:n.createMarker(t.toDate(e.range.end,e.forcedEndTzo))},forcedStartTzo:n.canComputeOffset?null:e.forcedStartTzo,forcedEndTzo:n.canComputeOffset?null:e.forcedEndTzo})}));return{defs:r,instances:o}}function excludeEventsBySourceId(e,t){return filterEventStoreDefs(e,(function(e){return e.sourceId!==t}))}function excludeInstances(e,t){return{defs:e.defs,instances:filterHash(e.instances,(function(e){return!t[e.instanceId]}))}}function reduceDateSelection(e,t){switch(t.type){case"UNSELECT_DATES":return null;case"SELECT_DATES":return t.selection;default:return e}}function reduceSelectedEvent(e,t){switch(t.type){case"UNSELECT_EVENT":return"";case"SELECT_EVENT":return t.eventInstanceId;default:return e}}function reduceEventDrag(e,t){var n;switch(t.type){case"UNSET_EVENT_DRAG":return null;case"SET_EVENT_DRAG":return{affectedEvents:(n=t.state).affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function reduceEventResize(e,t){var n;switch(t.type){case"UNSET_EVENT_RESIZE":return null;case"SET_EVENT_RESIZE":return{affectedEvents:(n=t.state).affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function parseToolbars(e,t,n,r,o){return{header:e.headerToolbar?parseToolbar(e.headerToolbar,e,t,n,r,o):null,footer:e.footerToolbar?parseToolbar(e.footerToolbar,e,t,n,r,o):null}}function parseToolbar(e,t,n,r,o,i){var a={},s=[],l=!1;for(var u in e){var c=parseSection(e[u],t,n,r,o,i);a[u]=c.widgets,s.push.apply(s,c.viewsWithButtons),l=l||c.hasTitle}return{sectionWidgets:a,viewsWithButtons:s,hasTitle:l}}function parseSection(e,t,n,r,o,i){var a="rtl"===t.direction,s=t.customButtons||{},l=n.buttonText||{},u=t.buttonText||{},c=n.buttonHints||{},d=t.buttonHints||{},p=e?e.split(" "):[],f=[],h=!1;return{widgets:p.map((function(e){return e.split(",").map((function(e){if("title"===e)return h=!0,{buttonName:e};var n,p,g,m,v,y;if(n=s[e])g=function(e){n.click&&n.click.call(e.target,e,e.target)},(m=r.getCustomButtonIconClass(n))||(m=r.getIconClass(e,a))||(v=n.text),y=n.hint||n.text;else if(p=o[e]){f.push(e),g=function(){i.changeView(e)},(v=p.buttonTextOverride)||(m=r.getIconClass(e,a))||(v=p.buttonTextDefault);var E=p.buttonTextOverride||p.buttonTextDefault;y=formatWithOrdinals(p.buttonTitleOverride||p.buttonTitleDefault||t.viewHint,[E,e],E)}else if(i[e])if(g=function(){i[e]()},(v=l[e])||(m=r.getIconClass(e,a))||(v=u[e]),"prevYear"===e||"nextYear"===e){var S="prevYear"===e?"prev":"next";y=formatWithOrdinals(c[S]||d[S],[u.year||"year","year"],u[e])}else y=function(t){return formatWithOrdinals(c[e]||d[e],[u[t]||t,t],u[e])};return{buttonName:e,buttonClick:g,buttonIcon:m,buttonText:v,buttonHint:y}}))})),viewsWithButtons:f,hasTitle:h}}var eventSourceDef$2={ignoreRange:!0,parseMeta:function(e){return Array.isArray(e.events)?e.events:null},fetch:function(e,t){t({rawEvents:e.eventSource.meta})}},arrayEventSourcePlugin=createPlugin({eventSourceDefs:[eventSourceDef$2]}),eventSourceDef$1={parseMeta:function(e){return"function"==typeof e.events?e.events:null},fetch:function(e,t,n){var r=e.context.dateEnv;unpromisify(e.eventSource.meta.bind(null,buildRangeApiWithTimeZone(e.range,r)),(function(e){t({rawEvents:e})}),n)}},funcEventSourcePlugin=createPlugin({eventSourceDefs:[eventSourceDef$1]});function requestJson(e,t,n,r,o){var i=null;"GET"===(e=e.toUpperCase())?t=injectQueryStringParams(t,n):i=encodeParams(n);var a=new XMLHttpRequest;a.open(e,t,!0),"GET"!==e&&a.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),a.onload=function(){if(a.status>=200&&a.status<400){var e=!1,t=void 0;try{t=JSON.parse(a.responseText),e=!0}catch(e){}e?r(t,a):o("Failure parsing JSON",a)}else o("Request failed",a)},a.onerror=function(){o("Request failed",a)},a.send(i)}function injectQueryStringParams(e,t){return e+(-1===e.indexOf("?")?"?":"&")+encodeParams(t)}function encodeParams(e){var t=[];for(var n in e)t.push(encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t.join("&")}var JSON_FEED_EVENT_SOURCE_REFINERS={method:String,extraParams:identity,startParam:String,endParam:String,timeZoneParam:String},eventSourceDef={parseMeta:function(e){return!e.url||"json"!==e.format&&e.format?null:{url:e.url,format:"json",method:(e.method||"GET").toUpperCase(),extraParams:e.extraParams,startParam:e.startParam,endParam:e.endParam,timeZoneParam:e.timeZoneParam}},fetch:function(e,t,n){var r=e.eventSource.meta,o=buildRequestParams(r,e.range,e.context);requestJson(r.method,r.url,o,(function(e,n){t({rawEvents:e,xhr:n})}),(function(e,t){n({message:e,xhr:t})}))}},jsonFeedEventSourcePlugin=createPlugin({eventSourceRefiners:JSON_FEED_EVENT_SOURCE_REFINERS,eventSourceDefs:[eventSourceDef]});function buildRequestParams(e,t,n){var r,o,i,a,s=n.dateEnv,l=n.options,u={};return null==(r=e.startParam)&&(r=l.startParam),null==(o=e.endParam)&&(o=l.endParam),null==(i=e.timeZoneParam)&&(i=l.timeZoneParam),a="function"==typeof e.extraParams?e.extraParams():e.extraParams||{},__assign$1(u,a),u[r]=s.formatIso(t.start),u[o]=s.formatIso(t.end),"local"!==s.timeZone&&(u[i]=s.timeZone),u}var SIMPLE_RECURRING_REFINERS={daysOfWeek:identity,startTime:createDuration,endTime:createDuration,duration:createDuration,startRecur:identity,endRecur:identity},recurring={parse:function(e,t){if(e.daysOfWeek||e.startTime||e.endTime||e.startRecur||e.endRecur){var n={daysOfWeek:e.daysOfWeek||null,startTime:e.startTime||null,endTime:e.endTime||null,startRecur:e.startRecur?t.createMarker(e.startRecur):null,endRecur:e.endRecur?t.createMarker(e.endRecur):null},r=void 0;return e.duration&&(r=e.duration),!r&&e.startTime&&e.endTime&&(r=subtractDurations(e.endTime,e.startTime)),{allDayGuess:Boolean(!e.startTime&&!e.endTime),duration:r,typeData:n}}return null},expand:function(e,t,n){var r=intersectRanges(t,{start:e.startRecur,end:e.endRecur});return r?expandRanges(e.daysOfWeek,e.startTime,r,n):[]}},simpleRecurringEventsPlugin=createPlugin({recurringTypes:[recurring],eventRefiners:SIMPLE_RECURRING_REFINERS});function expandRanges(e,t,n,r){for(var o=e?arrayToHash(e):null,i=startOfDay(n.start),a=n.end,s=[];i<a;){var l=void 0;o&&!o[i.getUTCDay()]||(l=t?r.add(i,t):i,s.push(l)),i=addDays(i,1)}return s}var changeHandlerPlugin=createPlugin({optionChangeHandlers:{events:function(e,t){handleEventSources([e],t)},eventSources:handleEventSources}});function handleEventSources(e,t){for(var n=hashValuesToArray(t.getCurrentData().eventSources),r=[],o=0,i=e;o<i.length;o++){for(var a=i[o],s=!1,l=0;l<n.length;l+=1)if(n[l]._raw===a){n.splice(l,1),s=!0;break}s||r.push(a)}for(var u=0,c=n;u<c.length;u++){var d=c[u];t.dispatch({type:"REMOVE_EVENT_SOURCE",sourceId:d.sourceId})}for(var p=0,f=r;p<f.length;p++){var h=f[p];t.calendarApi.addEventSource(h)}}function handleDateProfile(e,t){t.emitter.trigger("datesSet",__assign$1(__assign$1({},buildRangeApiWithTimeZone(e.activeRange,t.dateEnv)),{view:t.viewApi}))}function handleEventStore(e,t){var n=t.emitter;n.hasHandlers("eventsSet")&&n.trigger("eventsSet",buildEventApis(e,t))}var globalPlugins=[arrayEventSourcePlugin,funcEventSourcePlugin,jsonFeedEventSourcePlugin,simpleRecurringEventsPlugin,changeHandlerPlugin,createPlugin({isLoadingFuncs:[function(e){return computeEventSourcesLoading(e.eventSources)}],contentTypeHandlers:{html:buildHtmlRenderer,domNodes:buildDomNodeRenderer},propSetHandlers:{dateProfile:handleDateProfile,eventStore:handleEventStore}})];function buildHtmlRenderer(){var e=null,t="";return{render:function(n,r){n===e&&r===t||(n.innerHTML=r),e=n,t=r},destroy:function(){e.innerHTML="",e=null,t=""}}}function buildDomNodeRenderer(){var e=null,t=[];function n(){t.forEach(removeElement),t=[],e=null}return{render:function(r,o){var i=Array.prototype.slice.call(o);if(r!==e||!isArraysEqual(t,i)){for(var a=0,s=i;a<s.length;a++){var l=s[a];r.appendChild(l)}n()}e=r,t=i},destroy:n}}var DelayedRunner=function(){function e(e){this.drainedOption=e,this.isRunning=!1,this.isDirty=!1,this.pauseDepths={},this.timeoutId=0}return e.prototype.request=function(e){this.isDirty=!0,this.isPaused()||(this.clearTimeout(),null==e?this.tryDrain():this.timeoutId=setTimeout(this.tryDrain.bind(this),e))},e.prototype.pause=function(e){void 0===e&&(e="");var t=this.pauseDepths;t[e]=(t[e]||0)+1,this.clearTimeout()},e.prototype.resume=function(e,t){void 0===e&&(e="");var n=this.pauseDepths;if(e in n){if(t)delete n[e];else n[e]-=1,n[e]<=0&&delete n[e];this.tryDrain()}},e.prototype.isPaused=function(){return Object.keys(this.pauseDepths).length},e.prototype.tryDrain=function(){if(!this.isRunning&&!this.isPaused()){for(this.isRunning=!0;this.isDirty;)this.isDirty=!1,this.drained();this.isRunning=!1}},e.prototype.clear=function(){this.clearTimeout(),this.isDirty=!1,this.pauseDepths={}},e.prototype.clearTimeout=function(){this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=0)},e.prototype.drained=function(){this.drainedOption&&this.drainedOption()},e}(),TaskRunner=function(){function e(e,t){this.runTaskOption=e,this.drainedOption=t,this.queue=[],this.delayedRunner=new DelayedRunner(this.drain.bind(this))}return e.prototype.request=function(e,t){this.queue.push(e),this.delayedRunner.request(t)},e.prototype.pause=function(e){this.delayedRunner.pause(e)},e.prototype.resume=function(e,t){this.delayedRunner.resume(e,t)},e.prototype.drain=function(){for(var e=this.queue;e.length;){for(var t=[],n=void 0;n=e.shift();)this.runTask(n),t.push(n);this.drained(t)}},e.prototype.runTask=function(e){this.runTaskOption&&this.runTaskOption(e)},e.prototype.drained=function(e){this.drainedOption&&this.drainedOption(e)},e}();function buildTitle(e,t,n){var r;return r=/^(year|month)$/.test(e.currentRangeUnit)?e.currentRange:e.activeRange,n.formatRange(r.start,r.end,createFormatter(t.titleFormat||buildTitleFormat(e)),{isEndExclusive:e.isRangeAllDay,defaultSeparator:t.titleRangeSeparator})}function buildTitleFormat(e){var t=e.currentRangeUnit;if("year"===t)return{year:"numeric"};if("month"===t)return{year:"numeric",month:"long"};var n=diffWholeDays(e.currentRange.start,e.currentRange.end);return null!==n&&n>1?{year:"numeric",month:"short",day:"numeric"}:{year:"numeric",month:"long",day:"numeric"}}var CalendarDataManager=function(){function e(e){var t=this;this.computeOptionsData=memoize(this._computeOptionsData),this.computeCurrentViewData=memoize(this._computeCurrentViewData),this.organizeRawLocales=memoize(organizeRawLocales),this.buildLocale=memoize(buildLocale),this.buildPluginHooks=buildBuildPluginHooks(),this.buildDateEnv=memoize(buildDateEnv),this.buildTheme=memoize(buildTheme),this.parseToolbars=memoize(parseToolbars),this.buildViewSpecs=memoize(buildViewSpecs),this.buildDateProfileGenerator=memoizeObjArg(buildDateProfileGenerator),this.buildViewApi=memoize(buildViewApi),this.buildViewUiProps=memoizeObjArg(buildViewUiProps),this.buildEventUiBySource=memoize(buildEventUiBySource,isPropsEqual),this.buildEventUiBases=memoize(buildEventUiBases),this.parseContextBusinessHours=memoizeObjArg(parseContextBusinessHours),this.buildTitle=memoize(buildTitle),this.emitter=new Emitter,this.actionRunner=new TaskRunner(this._handleAction.bind(this),this.updateData.bind(this)),this.currentCalendarOptionsInput={},this.currentCalendarOptionsRefined={},this.currentViewOptionsInput={},this.currentViewOptionsRefined={},this.currentCalendarOptionsRefiners={},this.getCurrentData=function(){return t.data},this.dispatch=function(e){t.actionRunner.request(e)},this.props=e,this.actionRunner.pause();var n={},r=this.computeOptionsData(e.optionOverrides,n,e.calendarApi),o=r.calendarOptions.initialView||r.pluginHooks.initialView,i=this.computeCurrentViewData(o,r,e.optionOverrides,n);e.calendarApi.currentDataManager=this,this.emitter.setThisContext(e.calendarApi),this.emitter.setOptions(i.options);var a=getInitialDate(r.calendarOptions,r.dateEnv),s=i.dateProfileGenerator.build(a);rangeContainsMarker(s.activeRange,a)||(a=s.currentRange.start);for(var l={dateEnv:r.dateEnv,options:r.calendarOptions,pluginHooks:r.pluginHooks,calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},u=0,c=r.pluginHooks.contextInit;u<c.length;u++){(0,c[u])(l)}for(var d=initEventSources(r.calendarOptions,s,l),p={dynamicOptionOverrides:n,currentViewType:o,currentDate:a,dateProfile:s,businessHours:this.parseContextBusinessHours(l),eventSources:d,eventUiBases:{},eventStore:createEmptyEventStore(),renderableEventStore:createEmptyEventStore(),dateSelection:null,eventSelection:"",eventDrag:null,eventResize:null,selectionConfig:this.buildViewUiProps(l).selectionConfig},f=__assign$1(__assign$1({},l),p),h=0,g=r.pluginHooks.reducers;h<g.length;h++){var m=g[h];__assign$1(p,m(null,null,f))}computeIsLoading(p,l)&&this.emitter.trigger("loading",!0),this.state=p,this.updateData(),this.actionRunner.resume()}return e.prototype.resetOptions=function(e,t){var n=this.props;n.optionOverrides=t?__assign$1(__assign$1({},n.optionOverrides),e):e,this.actionRunner.request({type:"NOTHING"})},e.prototype._handleAction=function(e){var t=this,n=t.props,r=t.state,o=t.emitter,i=reduceDynamicOptionOverrides(r.dynamicOptionOverrides,e),a=this.computeOptionsData(n.optionOverrides,i,n.calendarApi),s=reduceViewType(r.currentViewType,e),l=this.computeCurrentViewData(s,a,n.optionOverrides,i);n.calendarApi.currentDataManager=this,o.setThisContext(n.calendarApi),o.setOptions(l.options);var u={dateEnv:a.dateEnv,options:a.calendarOptions,pluginHooks:a.pluginHooks,calendarApi:n.calendarApi,dispatch:this.dispatch,emitter:o,getCurrentData:this.getCurrentData},c=r.currentDate,d=r.dateProfile;this.data&&this.data.dateProfileGenerator!==l.dateProfileGenerator&&(d=l.dateProfileGenerator.build(c)),d=reduceDateProfile(d,e,c=reduceCurrentDate(c,e),l.dateProfileGenerator),"PREV"!==e.type&&"NEXT"!==e.type&&rangeContainsMarker(d.currentRange,c)||(c=d.currentRange.start);for(var p=reduceEventSources(r.eventSources,e,d,u),f=reduceEventStore(r.eventStore,e,p,d,u),h=computeEventSourcesLoading(p)&&!l.options.progressiveEventRendering&&r.renderableEventStore||f,g=this.buildViewUiProps(u),m=g.eventUiSingleBase,v=g.selectionConfig,y=this.buildEventUiBySource(p),E={dynamicOptionOverrides:i,currentViewType:s,currentDate:c,dateProfile:d,eventSources:p,eventStore:f,renderableEventStore:h,selectionConfig:v,eventUiBases:this.buildEventUiBases(h.defs,m,y),businessHours:this.parseContextBusinessHours(u),dateSelection:reduceDateSelection(r.dateSelection,e),eventSelection:reduceSelectedEvent(r.eventSelection,e),eventDrag:reduceEventDrag(r.eventDrag,e),eventResize:reduceEventResize(r.eventResize,e)},S=__assign$1(__assign$1({},u),E),D=0,T=a.pluginHooks.reducers;D<T.length;D++){var b=T[D];__assign$1(E,b(r,e,S))}var w=computeIsLoading(r,u),C=computeIsLoading(E,u);!w&&C?o.trigger("loading",!0):w&&!C&&o.trigger("loading",!1),this.state=E,n.onAction&&n.onAction(e)},e.prototype.updateData=function(){var e=this.props,t=this.state,n=this.data,r=this.computeOptionsData(e.optionOverrides,t.dynamicOptionOverrides,e.calendarApi),o=this.computeCurrentViewData(t.currentViewType,r,e.optionOverrides,t.dynamicOptionOverrides),i=this.data=__assign$1(__assign$1(__assign$1({viewTitle:this.buildTitle(t.dateProfile,o.options,r.dateEnv),calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},r),o),t),a=r.pluginHooks.optionChangeHandlers,s=n&&n.calendarOptions,l=r.calendarOptions;if(s&&s!==l)for(var u in s.timeZone!==l.timeZone&&(t.eventSources=i.eventSources=reduceEventSourcesNewTimeZone(i.eventSources,t.dateProfile,i),t.eventStore=i.eventStore=rezoneEventStoreDates(i.eventStore,n.dateEnv,i.dateEnv)),a)s[u]!==l[u]&&a[u](l[u],i);e.onData&&e.onData(i)},e.prototype._computeOptionsData=function(e,t,n){var r=this.processRawCalendarOptions(e,t),o=r.refinedOptions,i=r.pluginHooks,a=r.localeDefaults,s=r.availableLocaleData;warnUnknownOptions(r.extra);var l=this.buildDateEnv(o.timeZone,o.locale,o.weekNumberCalculation,o.firstDay,o.weekText,i,s,o.defaultRangeSeparator),u=this.buildViewSpecs(i.views,e,t,a),c=this.buildTheme(o,i);return{calendarOptions:o,pluginHooks:i,dateEnv:l,viewSpecs:u,theme:c,toolbarConfig:this.parseToolbars(o,e,c,u,n),localeDefaults:a,availableRawLocales:s.map}},e.prototype.processRawCalendarOptions=function(e,t){var n=mergeRawOptions([BASE_OPTION_DEFAULTS,e,t]),r=n.locales,o=n.locale,i=this.organizeRawLocales(r),a=i.map,s=this.buildLocale(o||i.defaultCode,a).options,l=this.buildPluginHooks(e.plugins||[],globalPlugins),u=this.currentCalendarOptionsRefiners=__assign$1(__assign$1(__assign$1(__assign$1(__assign$1({},BASE_OPTION_REFINERS),CALENDAR_LISTENER_REFINERS),CALENDAR_OPTION_REFINERS),l.listenerRefiners),l.optionRefiners),c={},d=mergeRawOptions([BASE_OPTION_DEFAULTS,s,e,t]),p={},f=this.currentCalendarOptionsInput,h=this.currentCalendarOptionsRefined,g=!1;for(var m in d)"plugins"!==m&&(d[m]===f[m]||COMPLEX_OPTION_COMPARATORS[m]&&m in f&&COMPLEX_OPTION_COMPARATORS[m](f[m],d[m])?p[m]=h[m]:u[m]?(p[m]=u[m](d[m]),g=!0):c[m]=f[m]);return g&&(this.currentCalendarOptionsInput=d,this.currentCalendarOptionsRefined=p),{rawOptions:this.currentCalendarOptionsInput,refinedOptions:this.currentCalendarOptionsRefined,pluginHooks:l,availableLocaleData:i,localeDefaults:s,extra:c}},e.prototype._computeCurrentViewData=function(e,t,n,r){var o=t.viewSpecs[e];if(!o)throw new Error('viewType "'+e+"\" is not available. Please make sure you've loaded all neccessary plugins");var i=this.processRawViewOptions(o,t.pluginHooks,t.localeDefaults,n,r),a=i.refinedOptions;return warnUnknownOptions(i.extra),{viewSpec:o,options:a,dateProfileGenerator:this.buildDateProfileGenerator({dateProfileGeneratorClass:o.optionDefaults.dateProfileGeneratorClass,duration:o.duration,durationUnit:o.durationUnit,usesMinMaxTime:o.optionDefaults.usesMinMaxTime,dateEnv:t.dateEnv,calendarApi:this.props.calendarApi,slotMinTime:a.slotMinTime,slotMaxTime:a.slotMaxTime,showNonCurrentDates:a.showNonCurrentDates,dayCount:a.dayCount,dateAlignment:a.dateAlignment,dateIncrement:a.dateIncrement,hiddenDays:a.hiddenDays,weekends:a.weekends,nowInput:a.now,validRangeInput:a.validRange,visibleRangeInput:a.visibleRange,monthMode:a.monthMode,fixedWeekCount:a.fixedWeekCount}),viewApi:this.buildViewApi(e,this.getCurrentData,t.dateEnv)}},e.prototype.processRawViewOptions=function(e,t,n,r,o){var i=mergeRawOptions([BASE_OPTION_DEFAULTS,e.optionDefaults,n,r,e.optionOverrides,o]),a=__assign$1(__assign$1(__assign$1(__assign$1(__assign$1(__assign$1({},BASE_OPTION_REFINERS),CALENDAR_LISTENER_REFINERS),CALENDAR_OPTION_REFINERS),VIEW_OPTION_REFINERS),t.listenerRefiners),t.optionRefiners),s={},l=this.currentViewOptionsInput,u=this.currentViewOptionsRefined,c=!1,d={};for(var p in i)i[p]===l[p]||COMPLEX_OPTION_COMPARATORS[p]&&COMPLEX_OPTION_COMPARATORS[p](i[p],l[p])?s[p]=u[p]:(i[p]===this.currentCalendarOptionsInput[p]||COMPLEX_OPTION_COMPARATORS[p]&&COMPLEX_OPTION_COMPARATORS[p](i[p],this.currentCalendarOptionsInput[p])?p in this.currentCalendarOptionsRefined&&(s[p]=this.currentCalendarOptionsRefined[p]):a[p]?s[p]=a[p](i[p]):d[p]=i[p],c=!0);return c&&(this.currentViewOptionsInput=i,this.currentViewOptionsRefined=s),{rawOptions:this.currentViewOptionsInput,refinedOptions:this.currentViewOptionsRefined,extra:d}},e}();function buildDateEnv(e,t,n,r,o,i,a,s){var l=buildLocale(t||a.defaultCode,a.map);return new DateEnv({calendarSystem:"gregory",timeZone:e,namedTimeZoneImpl:i.namedTimeZonedImpl,locale:l,weekNumberCalculation:n,firstDay:r,weekText:o,cmdFormatter:i.cmdFormatter,defaultSeparator:s})}function buildTheme(e,t){return new(t.themeClasses[e.themeSystem]||StandardTheme)(e)}function buildDateProfileGenerator(e){return new(e.dateProfileGeneratorClass||DateProfileGenerator)(e)}function buildViewApi(e,t,n){return new ViewApi(e,t,n)}function buildEventUiBySource(e){return mapHash(e,(function(e){return e.ui}))}function buildEventUiBases(e,t,n){var r={"":t};for(var o in e){var i=e[o];i.sourceId&&n[i.sourceId]&&(r[o]=n[i.sourceId])}return r}function buildViewUiProps(e){var t=e.options;return{eventUiSingleBase:createEventUi({display:t.eventDisplay,editable:t.editable,startEditable:t.eventStartEditable,durationEditable:t.eventDurationEditable,constraint:t.eventConstraint,overlap:"boolean"==typeof t.eventOverlap?t.eventOverlap:void 0,allow:t.eventAllow,backgroundColor:t.eventBackgroundColor,borderColor:t.eventBorderColor,textColor:t.eventTextColor,color:t.eventColor},e),selectionConfig:createEventUi({constraint:t.selectConstraint,overlap:"boolean"==typeof t.selectOverlap?t.selectOverlap:void 0,allow:t.selectAllow},e)}}function computeIsLoading(e,t){for(var n=0,r=t.pluginHooks.isLoadingFuncs;n<r.length;n++){if((0,r[n])(e))return!0}return!1}function parseContextBusinessHours(e){return parseBusinessHours(e.options.businessHours,e)}function warnUnknownOptions(e,t){for(var n in e)console.warn("Unknown option '"+n+"'"+(t?" for view '"+t+"'":""))}var CalendarDataProvider=function(e){function t(t){var n=e.call(this,t)||this;return n.handleData=function(e){n.dataManager?n.setState(e):n.state=e},n.dataManager=new CalendarDataManager({optionOverrides:t.optionOverrides,calendarApi:t.calendarApi,onData:n.handleData}),n}return __extends(t,e),t.prototype.render=function(){return this.props.children(this.state)},t.prototype.componentDidUpdate=function(e){var t=this.props.optionOverrides;t!==e.optionOverrides&&this.dataManager.resetOptions(t)},t}(Component),SegHierarchy=function(){function e(){this.strictOrder=!1,this.allowReslicing=!1,this.maxCoord=-1,this.maxStackCnt=-1,this.levelCoords=[],this.entriesByLevel=[],this.stackCnts={}}return e.prototype.addSegs=function(e){for(var t=[],n=0,r=e;n<r.length;n++){var o=r[n];this.insertEntry(o,t)}return t},e.prototype.insertEntry=function(e,t){var n=this.findInsertion(e);return this.isInsertionValid(n,e)?(this.insertEntryAt(e,n),1):this.handleInvalidInsertion(n,e,t)},e.prototype.isInsertionValid=function(e,t){return(-1===this.maxCoord||e.levelCoord+t.thickness<=this.maxCoord)&&(-1===this.maxStackCnt||e.stackCnt<this.maxStackCnt)},e.prototype.handleInvalidInsertion=function(e,t,n){return this.allowReslicing&&e.touchingEntry?this.splitEntry(t,e.touchingEntry,n):(n.push(t),0)},e.prototype.splitEntry=function(e,t,n){var r=0,o=[],i=e.span,a=t.span;return i.start<a.start&&(r+=this.insertEntry({index:e.index,thickness:e.thickness,span:{start:i.start,end:a.start}},o)),i.end>a.end&&(r+=this.insertEntry({index:e.index,thickness:e.thickness,span:{start:a.end,end:i.end}},o)),r?(n.push.apply(n,__spreadArray([{index:e.index,thickness:e.thickness,span:intersectSpans(a,i)}],o)),r):(n.push(e),0)},e.prototype.insertEntryAt=function(e,t){var n=this.entriesByLevel,r=this.levelCoords;-1===t.lateral?(insertAt(r,t.level,t.levelCoord),insertAt(n,t.level,[e])):insertAt(n[t.level],t.lateral,e),this.stackCnts[buildEntryKey(e)]=t.stackCnt},e.prototype.findInsertion=function(e){for(var t=this,n=t.levelCoords,r=t.entriesByLevel,o=t.strictOrder,i=t.stackCnts,a=n.length,s=0,l=-1,u=-1,c=null,d=0,p=0;p<a;p+=1){var f=n[p];if(!o&&f>=s+e.thickness)break;for(var h=r[p],g=void 0,m=binarySearch(h,e.span.start,getEntrySpanEnd),v=m[0]+m[1];(g=h[v])&&g.span.start<e.span.end;){var y=f+g.thickness;y>s&&(s=y,c=g,l=p,u=v),y===s&&(d=Math.max(d,i[buildEntryKey(g)]+1)),v+=1}}var E=0;if(c)for(E=l+1;E<a&&n[E]<s;)E+=1;var S=-1;return E<a&&n[E]===s&&(S=binarySearch(r[E],e.span.end,getEntrySpanEnd)[0]),{touchingLevel:l,touchingLateral:u,touchingEntry:c,stackCnt:d,levelCoord:s,level:E,lateral:S}},e.prototype.toRects=function(){for(var e=this.entriesByLevel,t=this.levelCoords,n=e.length,r=[],o=0;o<n;o+=1)for(var i=e[o],a=t[o],s=0,l=i;s<l.length;s++){var u=l[s];r.push(__assign$1(__assign$1({},u),{levelCoord:a}))}return r},e}();function getEntrySpanEnd(e){return e.span.end}function buildEntryKey(e){return e.index+":"+e.span.start}function groupIntersectingEntries(e){for(var t=[],n=0,r=e;n<r.length;n++){for(var o=r[n],i=[],a={span:o.span,entries:[o]},s=0,l=t;s<l.length;s++){var u=l[s];intersectSpans(u.span,a.span)?a={entries:u.entries.concat(a.entries),span:joinSpans(u.span,a.span)}:i.push(u)}i.push(a),t=i}return t}function joinSpans(e,t){return{start:Math.min(e.start,t.start),end:Math.max(e.end,t.end)}}function intersectSpans(e,t){var n=Math.max(e.start,t.start),r=Math.min(e.end,t.end);return n<r?{start:n,end:r}:null}function insertAt(e,t,n){e.splice(t,0,n)}function binarySearch(e,t,n){var r=0,o=e.length;if(!o||t<n(e[r]))return[0,0];if(t>n(e[o-1]))return[o,0];for(;r<o;){var i=Math.floor(r+(o-r)/2),a=n(e[i]);if(t<a)o=i;else{if(!(t>a))return[i,1];r=i+1}}return[r,0]}var Interaction=function(){function e(e){this.component=e.component,this.isHitComboAllowed=e.isHitComboAllowed||null}return e.prototype.destroy=function(){},e}();function parseInteractionSettings(e,t){return{component:e,el:t.el,useEventCenter:null==t.useEventCenter||t.useEventCenter,isHitComboAllowed:t.isHitComboAllowed||null}}function interactionSettingsToStore(e){var t;return(t={})[e.component.uid]=e,t}var interactionSettingsStore={},ElementDragging=function(){function e(e,t){this.emitter=new Emitter}return e.prototype.destroy=function(){},e.prototype.setMirrorIsVisible=function(e){},e.prototype.setMirrorNeedsRevert=function(e){},e.prototype.setAutoScrollEnabled=function(e){},e}(),config={},ToolbarSection=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props.widgetGroups.map((function(t){return e.renderWidgetGroup(t)}));return createElement.apply(void 0,__spreadArray(["div",{className:"fc-toolbar-chunk"}],t))},t.prototype.renderWidgetGroup=function(e){for(var t=this.props,n=this.context.theme,r=[],o=!0,i=0,a=e;i<a.length;i++){var s=a[i],l=s.buttonName,u=s.buttonClick,c=s.buttonText,d=s.buttonIcon,p=s.buttonHint;if("title"===l)o=!1,r.push(createElement("h2",{className:"fc-toolbar-title",id:t.titleId},t.title));else{var f=l===t.activeButton,h=!t.isTodayEnabled&&"today"===l||!t.isPrevEnabled&&"prev"===l||!t.isNextEnabled&&"next"===l,g=["fc-"+l+"-button",n.getClass("button")];f&&g.push(n.getClass("buttonActive")),r.push(createElement("button",{type:"button",title:"function"==typeof p?p(t.navUnit):p,disabled:h,"aria-pressed":f,className:g.join(" "),onClick:u},c||(d?createElement("span",{className:d}):"")))}}if(r.length>1){var m=o&&n.getClass("buttonGroup")||"";return createElement.apply(void 0,__spreadArray(["div",{className:m}],r))}return r[0]},t}(BaseComponent),Toolbar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e,t,n=this.props,r=n.model,o=n.extraClassName,i=!1,a=r.sectionWidgets,s=a.center;return a.left?(i=!0,e=a.left):e=a.start,a.right?(i=!0,t=a.right):t=a.end,createElement("div",{className:[o||"","fc-toolbar",i?"fc-toolbar-ltr":""].join(" ")},this.renderSection("start",e||[]),this.renderSection("center",s||[]),this.renderSection("end",t||[]))},t.prototype.renderSection=function(e,t){var n=this.props;return createElement(ToolbarSection,{key:e,widgetGroups:t,title:n.title,navUnit:n.navUnit,activeButton:n.activeButton,isTodayEnabled:n.isTodayEnabled,isPrevEnabled:n.isPrevEnabled,isNextEnabled:n.isNextEnabled,titleId:n.titleId})},t}(BaseComponent),ViewContainer=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={availableWidth:null},t.handleEl=function(e){t.el=e,setRef(t.props.elRef,e),t.updateAvailableWidth()},t.handleResize=function(){t.updateAvailableWidth()},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state,n=e.aspectRatio,r=["fc-view-harness",n||e.liquid||e.height?"fc-view-harness-active":"fc-view-harness-passive"],o="",i="";return n?null!==t.availableWidth?o=t.availableWidth/n:i=1/n*100+"%":o=e.height||"",createElement("div",{"aria-labelledby":e.labeledById,ref:this.handleEl,className:r.join(" "),style:{height:o,paddingBottom:i}},e.children)},t.prototype.componentDidMount=function(){this.context.addResizeHandler(this.handleResize)},t.prototype.componentWillUnmount=function(){this.context.removeResizeHandler(this.handleResize)},t.prototype.updateAvailableWidth=function(){this.el&&this.props.aspectRatio&&this.setState({availableWidth:this.el.offsetWidth})},t}(BaseComponent),EventClicking=function(e){function t(t){var n=e.call(this,t)||this;return n.handleSegClick=function(e,t){var r=n.component,o=r.context,i=getElSeg(t);if(i&&r.isValidSegDownEl(e.target)){var a=elementClosest(e.target,".fc-event-forced-url"),s=a?a.querySelector("a[href]").href:"";o.emitter.trigger("eventClick",{el:t,event:new EventApi(r.context,i.eventRange.def,i.eventRange.instance),jsEvent:e,view:o.viewApi}),s&&!e.defaultPrevented&&(window.location.href=s)}},n.destroy=listenBySelector(t.el,"click",".fc-event",n.handleSegClick),n}return __extends(t,e),t}(Interaction),EventHovering=function(e){function t(t){var n=e.call(this,t)||this;return n.handleEventElRemove=function(e){e===n.currentSegEl&&n.handleSegLeave(null,n.currentSegEl)},n.handleSegEnter=function(e,t){getElSeg(t)&&(n.currentSegEl=t,n.triggerEvent("eventMouseEnter",e,t))},n.handleSegLeave=function(e,t){n.currentSegEl&&(n.currentSegEl=null,n.triggerEvent("eventMouseLeave",e,t))},n.removeHoverListeners=listenToHoverBySelector(t.el,".fc-event",n.handleSegEnter,n.handleSegLeave),n}return __extends(t,e),t.prototype.destroy=function(){this.removeHoverListeners()},t.prototype.triggerEvent=function(e,t,n){var r=this.component,o=r.context,i=getElSeg(n);t&&!r.isValidSegDownEl(t.target)||o.emitter.trigger(e,{el:n,event:new EventApi(o,i.eventRange.def,i.eventRange.instance),jsEvent:t,view:o.viewApi})},t}(Interaction),CalendarContent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildViewContext=memoize(buildViewContext),t.buildViewPropTransformers=memoize(buildViewPropTransformers),t.buildToolbarProps=memoize(buildToolbarProps),t.headerRef=createRef(),t.footerRef=createRef(),t.interactionsStore={},t.state={viewLabelId:getUniqueDomId()},t.registerInteractiveComponent=function(e,n){var r=parseInteractionSettings(e,n),o=[EventClicking,EventHovering].concat(t.props.pluginHooks.componentInteractions).map((function(e){return new e(r)}));t.interactionsStore[e.uid]=o,interactionSettingsStore[e.uid]=r},t.unregisterInteractiveComponent=function(e){var n=t.interactionsStore[e.uid];if(n){for(var r=0,o=n;r<o.length;r++){o[r].destroy()}delete t.interactionsStore[e.uid]}delete interactionSettingsStore[e.uid]},t.resizeRunner=new DelayedRunner((function(){t.props.emitter.trigger("_resize",!0),t.props.emitter.trigger("windowResize",{view:t.props.viewApi})})),t.handleWindowResize=function(e){var n=t.props.options;n.handleWindowResize&&e.target===window&&t.resizeRunner.request(n.windowResizeDelay)},t}return __extends(t,e),t.prototype.render=function(){var e,t=this.props,n=t.toolbarConfig,r=t.options,o=this.buildToolbarProps(t.viewSpec,t.dateProfile,t.dateProfileGenerator,t.currentDate,getNow(t.options.now,t.dateEnv),t.viewTitle),i=!1,a="";t.isHeightAuto||t.forPrint?a="":null!=r.height?i=!0:null!=r.contentHeight?a=r.contentHeight:e=Math.max(r.aspectRatio,.5);var s=this.buildViewContext(t.viewSpec,t.viewApi,t.options,t.dateProfileGenerator,t.dateEnv,t.theme,t.pluginHooks,t.dispatch,t.getCurrentData,t.emitter,t.calendarApi,this.registerInteractiveComponent,this.unregisterInteractiveComponent),l=n.header&&n.header.hasTitle?this.state.viewLabelId:"";return createElement(ViewContextType.Provider,{value:s},n.header&&createElement(Toolbar,__assign$1({ref:this.headerRef,extraClassName:"fc-header-toolbar",model:n.header,titleId:l},o)),createElement(ViewContainer,{liquid:i,height:a,aspectRatio:e,labeledById:l},this.renderView(t),this.buildAppendContent()),n.footer&&createElement(Toolbar,__assign$1({ref:this.footerRef,extraClassName:"fc-footer-toolbar",model:n.footer,titleId:""},o)))},t.prototype.componentDidMount=function(){var e=this.props;this.calendarInteractions=e.pluginHooks.calendarInteractions.map((function(t){return new t(e)})),window.addEventListener("resize",this.handleWindowResize);var t=e.pluginHooks.propSetHandlers;for(var n in t)t[n](e[n],e)},t.prototype.componentDidUpdate=function(e){var t=this.props,n=t.pluginHooks.propSetHandlers;for(var r in n)t[r]!==e[r]&&n[r](t[r],t)},t.prototype.componentWillUnmount=function(){window.removeEventListener("resize",this.handleWindowResize),this.resizeRunner.clear();for(var e=0,t=this.calendarInteractions;e<t.length;e++){t[e].destroy()}this.props.emitter.trigger("_unmount")},t.prototype.buildAppendContent=function(){var e=this.props,t=e.pluginHooks.viewContainerAppends.map((function(t){return t(e)}));return createElement.apply(void 0,__spreadArray([Fragment,{}],t))},t.prototype.renderView=function(e){for(var t=e.pluginHooks,n=e.viewSpec,r={dateProfile:e.dateProfile,businessHours:e.businessHours,eventStore:e.renderableEventStore,eventUiBases:e.eventUiBases,dateSelection:e.dateSelection,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,isHeightAuto:e.isHeightAuto,forPrint:e.forPrint},o=0,i=this.buildViewPropTransformers(t.viewPropsTransformers);o<i.length;o++){var a=i[o];__assign$1(r,a.transform(r,e))}var s=n.component;return createElement(s,__assign$1({},r))},t}(PureComponent);function buildToolbarProps(e,t,n,r,o,i){var a=n.build(o,void 0,!1),s=n.buildPrev(t,r,!1),l=n.buildNext(t,r,!1);return{title:i,activeButton:e.type,navUnit:e.singleUnit,isTodayEnabled:a.isValid&&!rangeContainsMarker(t.currentRange,o),isPrevEnabled:s.isValid,isNextEnabled:l.isValid}}function buildViewPropTransformers(e){return e.map((function(e){return new e}))}var CalendarRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={forPrint:!1},t.handleBeforePrint=function(){t.setState({forPrint:!0})},t.handleAfterPrint=function(){t.setState({forPrint:!1})},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=e.options,n=this.state.forPrint,r=n||"auto"===t.height||"auto"===t.contentHeight,o=r||null==t.height?"":t.height,i=["fc",n?"fc-media-print":"fc-media-screen","fc-direction-"+t.direction,e.theme.getClass("root")];return getCanVGrowWithinCell()||i.push("fc-liquid-hack"),e.children(i,o,r,n)},t.prototype.componentDidMount=function(){var e=this.props.emitter;e.on("_beforeprint",this.handleBeforePrint),e.on("_afterprint",this.handleAfterPrint)},t.prototype.componentWillUnmount=function(){var e=this.props.emitter;e.off("_beforeprint",this.handleBeforePrint),e.off("_afterprint",this.handleAfterPrint)},t}(BaseComponent);function computeFallbackHeaderFormat(e,t){return createFormatter(!e||t>10?{weekday:"short"}:t>1?{weekday:"short",month:"numeric",day:"numeric",omitCommas:!0}:{weekday:"long"})}var CLASS_NAME="fc-col-header-cell";function renderInner$1(e){return e.text}var TableDateCell=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.dateEnv,n=e.options,r=e.theme,o=e.viewApi,i=this.props,a=i.date,s=i.dateProfile,l=getDateMeta(a,i.todayRange,null,s),u=[CLASS_NAME].concat(getDayClassNames(l,r)),c=t.format(a,i.dayHeaderFormat),d=!l.isDisabled&&i.colCnt>1?buildNavLinkAttrs(this.context,a):{},p=__assign$1(__assign$1(__assign$1({date:t.toDate(a),view:o},i.extraHookProps),{text:c}),l);return createElement(RenderHook,{hookProps:p,classNames:n.dayHeaderClassNames,content:n.dayHeaderContent,defaultContent:renderInner$1,didMount:n.dayHeaderDidMount,willUnmount:n.dayHeaderWillUnmount},(function(e,t,n,r){return createElement("th",__assign$1({ref:e,role:"columnheader",className:u.concat(t).join(" "),"data-date":l.isDisabled?void 0:formatDayString(a),colSpan:i.colSpan},i.extraDataAttrs),createElement("div",{className:"fc-scrollgrid-sync-inner"},!l.isDisabled&&createElement("a",__assign$1({ref:n,className:["fc-col-header-cell-cushion",i.isSticky?"fc-sticky":""].join(" ")},d),r)))}))},t}(BaseComponent),WEEKDAY_FORMAT=createFormatter({weekday:"long"}),TableDowCell=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.dateEnv,r=t.theme,o=t.viewApi,i=t.options,a=addDays(new Date(2592e5),e.dow),s={dow:e.dow,isDisabled:!1,isFuture:!1,isPast:!1,isToday:!1,isOther:!1},l=[CLASS_NAME].concat(getDayClassNames(s,r),e.extraClassNames||[]),u=n.format(a,e.dayHeaderFormat),c=__assign$1(__assign$1(__assign$1(__assign$1({date:a},s),{view:o}),e.extraHookProps),{text:u});return createElement(RenderHook,{hookProps:c,classNames:i.dayHeaderClassNames,content:i.dayHeaderContent,defaultContent:renderInner$1,didMount:i.dayHeaderDidMount,willUnmount:i.dayHeaderWillUnmount},(function(t,r,o,i){return createElement("th",__assign$1({ref:t,role:"columnheader",className:l.concat(r).join(" "),colSpan:e.colSpan},e.extraDataAttrs),createElement("div",{className:"fc-scrollgrid-sync-inner"},createElement("a",{"aria-label":n.format(a,WEEKDAY_FORMAT),className:["fc-col-header-cell-cushion",e.isSticky?"fc-sticky":""].join(" "),ref:o},i)))}))},t}(BaseComponent),NowTimer=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.initialNowDate=getNow(n.options.now,n.dateEnv),r.initialNowQueriedMs=(new Date).valueOf(),r.state=r.computeTiming().currentState,r}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state;return e.children(t.nowDate,t.todayRange)},t.prototype.componentDidMount=function(){this.setTimeout()},t.prototype.componentDidUpdate=function(e){e.unit!==this.props.unit&&(this.clearTimeout(),this.setTimeout())},t.prototype.componentWillUnmount=function(){this.clearTimeout()},t.prototype.computeTiming=function(){var e=this.props,t=this.context,n=addMs(this.initialNowDate,(new Date).valueOf()-this.initialNowQueriedMs),r=t.dateEnv.startOf(n,e.unit),o=t.dateEnv.add(r,createDuration(1,e.unit)),i=o.valueOf()-n.valueOf();return i=Math.min(864e5,i),{currentState:{nowDate:r,todayRange:buildDayRange(r)},nextState:{nowDate:o,todayRange:buildDayRange(o)},waitMs:i}},t.prototype.setTimeout=function(){var e=this,t=this.computeTiming(),n=t.nextState,r=t.waitMs;this.timeoutId=setTimeout((function(){e.setState(n,(function(){e.setTimeout()}))}),r)},t.prototype.clearTimeout=function(){this.timeoutId&&clearTimeout(this.timeoutId)},t.contextType=ViewContextType,t}(Component);function buildDayRange(e){var t=startOfDay(e);return{start:t,end:addDays(t,1)}}var DayHeader=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.createDayHeaderFormatter=memoize(createDayHeaderFormatter),t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=this.props,n=t.dates,r=t.dateProfile,o=t.datesRepDistinctDays,i=t.renderIntro,a=this.createDayHeaderFormatter(e.options.dayHeaderFormat,o,n.length);return createElement(NowTimer,{unit:"day"},(function(e,t){return createElement("tr",{role:"row"},i&&i("day"),n.map((function(e){return o?createElement(TableDateCell,{key:e.toISOString(),date:e,dateProfile:r,todayRange:t,colCnt:n.length,dayHeaderFormat:a}):createElement(TableDowCell,{key:e.getUTCDay(),dow:e.getUTCDay(),dayHeaderFormat:a})})))}))},t}(BaseComponent);function createDayHeaderFormatter(e,t,n){return e||computeFallbackHeaderFormat(t,n)}var DaySeriesModel=function(){function e(e,t){for(var n=e.start,r=e.end,o=[],i=[],a=-1;n<r;)t.isHiddenDay(n)?o.push(a+.5):(a+=1,o.push(a),i.push(n)),n=addDays(n,1);this.dates=i,this.indices=o,this.cnt=i.length}return e.prototype.sliceRange=function(e){var t=this.getDateDayIndex(e.start),n=this.getDateDayIndex(addDays(e.end,-1)),r=Math.max(0,t),o=Math.min(this.cnt-1,n);return(r=Math.ceil(r))<=(o=Math.floor(o))?{firstIndex:r,lastIndex:o,isStart:t===r,isEnd:n===o}:null},e.prototype.getDateDayIndex=function(e){var t=this.indices,n=Math.floor(diffDays(this.dates[0],e));return n<0?t[0]-1:n>=t.length?t[t.length-1]+1:t[n]},e}(),DayTableModel=function(){function e(e,t){var n,r,o,i=e.dates;if(t){for(r=i[0].getUTCDay(),n=1;n<i.length&&i[n].getUTCDay()!==r;n+=1);o=Math.ceil(i.length/n)}else o=1,n=i.length;this.rowCnt=o,this.colCnt=n,this.daySeries=e,this.cells=this.buildCells(),this.headerDates=this.buildHeaderDates()}return e.prototype.buildCells=function(){for(var e=[],t=0;t<this.rowCnt;t+=1){for(var n=[],r=0;r<this.colCnt;r+=1)n.push(this.buildCell(t,r));e.push(n)}return e},e.prototype.buildCell=function(e,t){var n=this.daySeries.dates[e*this.colCnt+t];return{key:n.toISOString(),date:n}},e.prototype.buildHeaderDates=function(){for(var e=[],t=0;t<this.colCnt;t+=1)e.push(this.cells[0][t].date);return e},e.prototype.sliceRange=function(e){var t=this.colCnt,n=this.daySeries.sliceRange(e),r=[];if(n)for(var o=n.firstIndex,i=n.lastIndex,a=o;a<=i;){var s=Math.floor(a/t),l=Math.min((s+1)*t,i+1);r.push({row:s,firstCol:a%t,lastCol:(l-1)%t,isStart:n.isStart&&a===o,isEnd:n.isEnd&&l-1===i}),a=l}return r},e}(),Slicer=function(){function e(){this.sliceBusinessHours=memoize(this._sliceBusinessHours),this.sliceDateSelection=memoize(this._sliceDateSpan),this.sliceEventStore=memoize(this._sliceEventStore),this.sliceEventDrag=memoize(this._sliceInteraction),this.sliceEventResize=memoize(this._sliceInteraction),this.forceDayIfListItem=!1}return e.prototype.sliceProps=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];var a=e.eventUiBases,s=this.sliceEventStore.apply(this,__spreadArray([e.eventStore,a,t,n],o));return{dateSelectionSegs:this.sliceDateSelection.apply(this,__spreadArray([e.dateSelection,a,r],o)),businessHourSegs:this.sliceBusinessHours.apply(this,__spreadArray([e.businessHours,t,n,r],o)),fgEventSegs:s.fg,bgEventSegs:s.bg,eventDrag:this.sliceEventDrag.apply(this,__spreadArray([e.eventDrag,a,t,n],o)),eventResize:this.sliceEventResize.apply(this,__spreadArray([e.eventResize,a,t,n],o)),eventSelection:e.eventSelection}},e.prototype.sliceNowDate=function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return this._sliceDateSpan.apply(this,__spreadArray([{range:{start:e,end:addMs(e,1)},allDay:!1},{},t],n))},e.prototype._sliceBusinessHours=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];return e?this._sliceEventStore.apply(this,__spreadArray([expandRecurring(e,computeActiveRange(t,Boolean(n)),r),{},t,n],o)).bg:[]},e.prototype._sliceEventStore=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];if(e){var a=sliceEventStore(e,t,computeActiveRange(n,Boolean(r)),r);return{bg:this.sliceEventRanges(a.bg,o),fg:this.sliceEventRanges(a.fg,o)}}return{bg:[],fg:[]}},e.prototype._sliceInteraction=function(e,t,n,r){for(var o=[],i=4;i<arguments.length;i++)o[i-4]=arguments[i];if(!e)return null;var a=sliceEventStore(e.mutatedEvents,t,computeActiveRange(n,Boolean(r)),r);return{segs:this.sliceEventRanges(a.fg,o),affectedInstances:e.affectedEvents.instances,isEvent:e.isEvent}},e.prototype._sliceDateSpan=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];if(!e)return[];for(var i=fabricateEventRange(e,t,n),a=this.sliceRange.apply(this,__spreadArray([e.range],r)),s=0,l=a;s<l.length;s++){var u=l[s];u.eventRange=i}return a},e.prototype.sliceEventRanges=function(e,t){for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];n.push.apply(n,this.sliceEventRange(i,t))}return n},e.prototype.sliceEventRange=function(e,t){var n=e.range;this.forceDayIfListItem&&"list-item"===e.ui.display&&(n={start:n.start,end:addDays(n.start,1)});for(var r=this.sliceRange.apply(this,__spreadArray([n],t)),o=0,i=r;o<i.length;o++){var a=i[o];a.eventRange=e,a.isStart=e.isStart&&a.isStart,a.isEnd=e.isEnd&&a.isEnd}return r},e}();function computeActiveRange(e,t){var n=e.activeRange;return t?n:{start:addMs(n.start,e.slotMinTime.milliseconds),end:addMs(n.end,e.slotMaxTime.milliseconds-864e5)}}function isInteractionValid(e,t,n){var r=e.mutatedEvents.instances;for(var o in r)if(!rangeContainsRange(t.validRange,r[o].range))return!1;return isNewPropsValid({eventDrag:e},n)}function isDateSelectionValid(e,t,n){return!!rangeContainsRange(t.validRange,e.range)&&isNewPropsValid({dateSelection:e},n)}function isNewPropsValid(e,t){var n=t.getCurrentData(),r=__assign$1({businessHours:n.businessHours,dateSelection:"",eventStore:n.eventStore,eventUiBases:n.eventUiBases,eventSelection:"",eventDrag:null,eventResize:null},e);return(t.pluginHooks.isPropsValid||isPropsValid)(r,t)}function isPropsValid(e,t,n,r){return void 0===n&&(n={}),!(e.eventDrag&&!isInteractionPropsValid(e,t,n,r))&&!(e.dateSelection&&!isDateSelectionPropsValid(e,t,n,r))}function isInteractionPropsValid(e,t,n,r){var o=t.getCurrentData(),i=e.eventDrag,a=i.mutatedEvents,s=a.defs,l=a.instances,u=compileEventUis(s,i.isEvent?e.eventUiBases:{"":o.selectionConfig});r&&(u=mapHash(u,r));var c=excludeInstances(e.eventStore,i.affectedEvents.instances),d=c.defs,p=c.instances,f=compileEventUis(d,e.eventUiBases);for(var h in l){var g=l[h],m=g.range,v=u[g.defId],y=s[g.defId];if(!allConstraintsPass(v.constraints,m,c,e.businessHours,t))return!1;var E=t.options.eventOverlap,S="function"==typeof E?E:null;for(var D in p){var T=p[D];if(rangesIntersect(m,T.range)){if(!1===f[T.defId].overlap&&i.isEvent)return!1;if(!1===v.overlap)return!1;if(S&&!S(new EventApi(t,d[T.defId],T),new EventApi(t,y,g)))return!1}}for(var b=o.eventStore,w=0,C=v.allows;w<C.length;w++){var R=C[w],_=__assign$1(__assign$1({},n),{range:g.range,allDay:y.allDay}),x=b.defs[y.defId],k=b.instances[h],M=void 0;if(M=x?new EventApi(t,x,k):new EventApi(t,y),!R(buildDateSpanApiWithContext(_,t),M))return!1}}return!0}function isDateSelectionPropsValid(e,t,n,r){var o=e.eventStore,i=o.defs,a=o.instances,s=e.dateSelection,l=s.range,u=t.getCurrentData().selectionConfig;if(r&&(u=r(u)),!allConstraintsPass(u.constraints,l,o,e.businessHours,t))return!1;var c=t.options.selectOverlap,d="function"==typeof c?c:null;for(var p in a){var f=a[p];if(rangesIntersect(l,f.range)){if(!1===u.overlap)return!1;if(d&&!d(new EventApi(t,i[f.defId],f),null))return!1}}for(var h=0,g=u.allows;h<g.length;h++){if(!(0,g[h])(buildDateSpanApiWithContext(__assign$1(__assign$1({},n),s),t),null))return!1}return!0}function allConstraintsPass(e,t,n,r,o){for(var i=0,a=e;i<a.length;i++){if(!anyRangesContainRange(constraintToRanges(a[i],t,n,r,o),t))return!1}return!0}function constraintToRanges(e,t,n,r,o){return"businessHours"===e?eventStoreToRanges(expandRecurring(r,t,o)):"string"==typeof e?eventStoreToRanges(filterEventStoreDefs(n,(function(t){return t.groupId===e}))):"object"==typeof e&&e?eventStoreToRanges(expandRecurring(e,t,o)):[]}function eventStoreToRanges(e){var t=e.instances,n=[];for(var r in t)n.push(t[r].range);return n}function anyRangesContainRange(e,t){for(var n=0,r=e;n<r.length;n++){if(rangeContainsRange(r[n],t))return!0}return!1}var VISIBLE_HIDDEN_RE=/^(visible|hidden)$/,Scroller=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleEl=function(e){t.el=e,setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=e.liquid,n=e.liquidIsAbsolute,r=t&&n,o=["fc-scroller"];return t&&(n?o.push("fc-scroller-liquid-absolute"):o.push("fc-scroller-liquid")),createElement("div",{ref:this.handleEl,className:o.join(" "),style:{overflowX:e.overflowX,overflowY:e.overflowY,left:r&&-(e.overcomeLeft||0)||"",right:r&&-(e.overcomeRight||0)||"",bottom:r&&-(e.overcomeBottom||0)||"",marginLeft:!r&&-(e.overcomeLeft||0)||"",marginRight:!r&&-(e.overcomeRight||0)||"",marginBottom:!r&&-(e.overcomeBottom||0)||"",maxHeight:e.maxHeight||""}},e.children)},t.prototype.needsXScrolling=function(){if(VISIBLE_HIDDEN_RE.test(this.props.overflowX))return!1;for(var e=this.el,t=this.el.getBoundingClientRect().width-this.getYScrollbarWidth(),n=e.children,r=0;r<n.length;r+=1){if(n[r].getBoundingClientRect().width>t)return!0}return!1},t.prototype.needsYScrolling=function(){if(VISIBLE_HIDDEN_RE.test(this.props.overflowY))return!1;for(var e=this.el,t=this.el.getBoundingClientRect().height-this.getXScrollbarWidth(),n=e.children,r=0;r<n.length;r+=1){if(n[r].getBoundingClientRect().height>t)return!0}return!1},t.prototype.getXScrollbarWidth=function(){return VISIBLE_HIDDEN_RE.test(this.props.overflowX)?0:this.el.offsetHeight-this.el.clientHeight},t.prototype.getYScrollbarWidth=function(){return VISIBLE_HIDDEN_RE.test(this.props.overflowY)?0:this.el.offsetWidth-this.el.clientWidth},t}(BaseComponent),RefMap=function(){function e(e){var t=this;this.masterCallback=e,this.currentMap={},this.depths={},this.callbackMap={},this.handleValue=function(e,n){var r=t,o=r.depths,i=r.currentMap,a=!1,s=!1;null!==e?(a=n in i,i[n]=e,o[n]=(o[n]||0)+1,s=!0):(o[n]-=1,o[n]||(delete i[n],delete t.callbackMap[n],a=!0)),t.masterCallback&&(a&&t.masterCallback(null,String(n)),s&&t.masterCallback(e,String(n)))}}return e.prototype.createRef=function(e){var t=this,n=this.callbackMap[e];return n||(n=this.callbackMap[e]=function(n){t.handleValue(n,String(e))}),n},e.prototype.collect=function(e,t,n){return collectFromHash(this.currentMap,e,t,n)},e.prototype.getAll=function(){return hashValuesToArray(this.currentMap)},e}();function computeShrinkWidth(e){for(var t=0,n=0,r=findElements(e,".fc-scrollgrid-shrink");n<r.length;n++){var o=r[n];t=Math.max(t,computeSmallestCellWidth(o))}return Math.ceil(t)}function getSectionHasLiquidHeight(e,t){return e.liquid&&t.liquid}function getAllowYScrolling(e,t){return null!=t.maxHeight||getSectionHasLiquidHeight(e,t)}function renderChunkContent(e,t,n,r){var o=n.expandRows;return"function"==typeof t.content?t.content(n):createElement("table",{role:"presentation",className:[t.tableClassName,e.syncRowHeights?"fc-scrollgrid-sync-table":""].join(" "),style:{minWidth:n.tableMinWidth,width:n.clientWidth,height:o?n.clientHeight:""}},n.tableColGroupNode,createElement(r?"thead":"tbody",{role:"presentation"},"function"==typeof t.rowContent?t.rowContent(n):t.rowContent))}function isColPropsEqual(e,t){return isArraysEqual(e,t,isPropsEqual)}function renderMicroColGroup(e,t){for(var n=[],r=0,o=e;r<o.length;r++)for(var i=o[r],a=i.span||1,s=0;s<a;s+=1)n.push(createElement("col",{style:{width:"shrink"===i.width?sanitizeShrinkWidth(t):i.width||"",minWidth:i.minWidth||""}}));return createElement.apply(void 0,__spreadArray(["colgroup",{}],n))}function sanitizeShrinkWidth(e){return null==e?4:e}function hasShrinkWidth(e){for(var t=0,n=e;t<n.length;t++){if("shrink"===n[t].width)return!0}return!1}function getScrollGridClassNames(e,t){var n=["fc-scrollgrid",t.theme.getClass("table")];return e&&n.push("fc-scrollgrid-liquid"),n}function getSectionClassNames(e,t){var n=["fc-scrollgrid-section","fc-scrollgrid-section-"+e.type,e.className];return t&&e.liquid&&null==e.maxHeight&&n.push("fc-scrollgrid-section-liquid"),e.isSticky&&n.push("fc-scrollgrid-section-sticky"),n}function renderScrollShim(e){return createElement("div",{className:"fc-scrollgrid-sticky-shim",style:{width:e.clientWidth,minWidth:e.tableMinWidth}})}function getStickyHeaderDates(e){var t=e.stickyHeaderDates;return null!=t&&"auto"!==t||(t="auto"===e.height||"auto"===e.viewHeight),t}function getStickyFooterScrollbar(e){var t=e.stickyFooterScrollbar;return null!=t&&"auto"!==t||(t="auto"===e.height||"auto"===e.viewHeight),t}var SimpleScrollGrid=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.processCols=memoize((function(e){return e}),isColPropsEqual),t.renderMicroColGroup=memoize(renderMicroColGroup),t.scrollerRefs=new RefMap,t.scrollerElRefs=new RefMap(t._handleScrollerEl.bind(t)),t.state={shrinkWidth:null,forceYScrollbars:!1,scrollerClientWidths:{},scrollerClientHeights:{}},t.handleSizing=function(){t.safeSetState(__assign$1({shrinkWidth:t.computeShrinkWidth()},t.computeScrollerDims()))},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=e.props,n=e.state,r=e.context,o=t.sections||[],i=this.processCols(t.cols),a=this.renderMicroColGroup(i,n.shrinkWidth),s=getScrollGridClassNames(t.liquid,r);t.collapsibleWidth&&s.push("fc-scrollgrid-collapsible");for(var l,u=o.length,c=0,d=[],p=[],f=[];c<u&&"header"===(l=o[c]).type;)d.push(this.renderSection(l,a,!0)),c+=1;for(;c<u&&"body"===(l=o[c]).type;)p.push(this.renderSection(l,a,!1)),c+=1;for(;c<u&&"footer"===(l=o[c]).type;)f.push(this.renderSection(l,a,!0)),c+=1;var h=!getCanVGrowWithinCell(),g={role:"rowgroup"};return createElement("table",{role:"grid",className:s.join(" "),style:{height:t.height}},Boolean(!h&&d.length)&&createElement.apply(void 0,__spreadArray(["thead",g],d)),Boolean(!h&&p.length)&&createElement.apply(void 0,__spreadArray(["tbody",g],p)),Boolean(!h&&f.length)&&createElement.apply(void 0,__spreadArray(["tfoot",g],f)),h&&createElement.apply(void 0,__spreadArray(__spreadArray(__spreadArray(["tbody",g],d),p),f)))},t.prototype.renderSection=function(e,t,n){return"outerContent"in e?createElement(Fragment,{key:e.key},e.outerContent):createElement("tr",{key:e.key,role:"presentation",className:getSectionClassNames(e,this.props.liquid).join(" ")},this.renderChunkTd(e,t,e.chunk,n))},t.prototype.renderChunkTd=function(e,t,n,r){if("outerContent"in n)return n.outerContent;var o=this.props,i=this.state,a=i.forceYScrollbars,s=i.scrollerClientWidths,l=i.scrollerClientHeights,u=getAllowYScrolling(o,e),c=getSectionHasLiquidHeight(o,e),d=o.liquid?a?"scroll":u?"auto":"hidden":"visible",p=e.key,f=renderChunkContent(e,n,{tableColGroupNode:t,tableMinWidth:"",clientWidth:o.collapsibleWidth||void 0===s[p]?null:s[p],clientHeight:void 0!==l[p]?l[p]:null,expandRows:e.expandRows,syncRowHeights:!1,rowSyncHeights:[],reportRowHeightChange:function(){}},r);return createElement(r?"th":"td",{ref:n.elRef,role:"presentation"},createElement("div",{className:"fc-scroller-harness"+(c?" fc-scroller-harness-liquid":"")},createElement(Scroller,{ref:this.scrollerRefs.createRef(p),elRef:this.scrollerElRefs.createRef(p),overflowY:d,overflowX:o.liquid?"hidden":"visible",maxHeight:e.maxHeight,liquid:c,liquidIsAbsolute:!0},f)))},t.prototype._handleScrollerEl=function(e,t){var n=getSectionByKey(this.props.sections,t);n&&setRef(n.chunk.scrollerElRef,e)},t.prototype.componentDidMount=function(){this.handleSizing(),this.context.addResizeHandler(this.handleSizing)},t.prototype.componentDidUpdate=function(){this.handleSizing()},t.prototype.componentWillUnmount=function(){this.context.removeResizeHandler(this.handleSizing)},t.prototype.computeShrinkWidth=function(){return hasShrinkWidth(this.props.cols)?computeShrinkWidth(this.scrollerElRefs.getAll()):0},t.prototype.computeScrollerDims=function(){var e=getScrollbarWidths(),t=this.scrollerRefs,n=this.scrollerElRefs,r=!1,o={},i={};for(var a in t.currentMap){var s=t.currentMap[a];if(s&&s.needsYScrolling()){r=!0;break}}for(var l=0,u=this.props.sections;l<u.length;l++){a=u[l].key;var c=n.currentMap[a];if(c){var d=c.parentNode;o[a]=Math.floor(d.getBoundingClientRect().width-(r?e.y:0)),i[a]=Math.floor(d.getBoundingClientRect().height)}}return{forceYScrollbars:r,scrollerClientWidths:o,scrollerClientHeights:i}},t}(BaseComponent);function getSectionByKey(e,t){for(var n=0,r=e;n<r.length;n++){var o=r[n];if(o.key===t)return o}return null}SimpleScrollGrid.addStateEquality({scrollerClientWidths:isPropsEqual,scrollerClientHeights:isPropsEqual});var EventRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.elRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=e.seg,o=r.eventRange,i=o.ui,a={event:new EventApi(t,o.def,o.instance),view:t.viewApi,timeText:e.timeText,textColor:i.textColor,backgroundColor:i.backgroundColor,borderColor:i.borderColor,isDraggable:!e.disableDragging&&computeSegDraggable(r,t),isStartResizable:!e.disableResizing&&computeSegStartResizable(r,t),isEndResizable:!e.disableResizing&&computeSegEndResizable(r),isMirror:Boolean(e.isDragging||e.isResizing||e.isDateSelecting),isStart:Boolean(r.isStart),isEnd:Boolean(r.isEnd),isPast:Boolean(e.isPast),isFuture:Boolean(e.isFuture),isToday:Boolean(e.isToday),isSelected:Boolean(e.isSelected),isDragging:Boolean(e.isDragging),isResizing:Boolean(e.isResizing)},s=getEventClassNames(a).concat(i.classNames);return createElement(RenderHook,{hookProps:a,classNames:n.eventClassNames,content:n.eventContent,defaultContent:e.defaultContent,didMount:n.eventDidMount,willUnmount:n.eventWillUnmount,elRef:this.elRef},(function(t,n,r,o){return e.children(t,s.concat(n),r,o,a)}))},t.prototype.componentDidMount=function(){setElSeg(this.elRef.current,this.props.seg)},t.prototype.componentDidUpdate=function(e){var t=this.props.seg;t!==e.seg&&setElSeg(this.elRef.current,t)},t}(BaseComponent),StandardEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=e.seg,r=t.options.eventTimeFormat||e.defaultTimeFormat,o=buildSegTimeText(n,r,t,e.defaultDisplayEventTime,e.defaultDisplayEventEnd);return createElement(EventRoot,{seg:n,timeText:o,disableDragging:e.disableDragging,disableResizing:e.disableResizing,defaultContent:e.defaultContent||renderInnerContent$1$1,isDragging:e.isDragging,isResizing:e.isResizing,isDateSelecting:e.isDateSelecting,isSelected:e.isSelected,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(r,o,i,a,s){return createElement("a",__assign$1({className:e.extraClassNames.concat(o).join(" "),style:{borderColor:s.borderColor,backgroundColor:s.backgroundColor},ref:r},getSegAnchorAttrs(n,t)),createElement("div",{className:"fc-event-main",ref:i,style:{color:s.textColor}},a),s.isStartResizable&&createElement("div",{className:"fc-event-resizer fc-event-resizer-start"}),s.isEndResizable&&createElement("div",{className:"fc-event-resizer fc-event-resizer-end"}))}))},t}(BaseComponent);function renderInnerContent$1$1(e){return createElement("div",{className:"fc-event-main-frame"},e.timeText&&createElement("div",{className:"fc-event-time"},e.timeText),createElement("div",{className:"fc-event-title-container"},createElement("div",{className:"fc-event-title fc-sticky"},e.event.title||createElement(Fragment,null," "))))}var NowIndicatorRoot=function(e){return createElement(ViewContextType.Consumer,null,(function(t){var n=t.options,r={isAxis:e.isAxis,date:t.dateEnv.toDate(e.date),view:t.viewApi};return createElement(RenderHook,{hookProps:r,classNames:n.nowIndicatorClassNames,content:n.nowIndicatorContent,didMount:n.nowIndicatorDidMount,willUnmount:n.nowIndicatorWillUnmount},e.children)}))},DAY_NUM_FORMAT=createFormatter({day:"numeric"}),DayCellContent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=refineDayCellHookProps({date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraProps:e.extraHookProps,viewApi:t.viewApi,dateEnv:t.dateEnv});return createElement(ContentHook,{hookProps:r,content:n.dayCellContent,defaultContent:e.defaultContent},e.children)},t}(BaseComponent);function refineDayCellHookProps(e){var t=e.date,n=e.dateEnv,r=getDateMeta(t,e.todayRange,null,e.dateProfile);return __assign$1(__assign$1(__assign$1({date:n.toDate(t),view:e.viewApi},r),{dayNumberText:e.showDayNumber?n.format(t,DAY_NUM_FORMAT):""}),e.extraProps)}var DayCellRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.refineHookProps=memoizeObjArg(refineDayCellHookProps),t.normalizeClassNames=buildClassNameNormalizer(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=this.refineHookProps({date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraProps:e.extraHookProps,viewApi:t.viewApi,dateEnv:t.dateEnv}),o=getDayClassNames(r,t.theme).concat(r.isDisabled?[]:this.normalizeClassNames(n.dayCellClassNames,r)),i=r.isDisabled?{}:{"data-date":formatDayString(e.date)};return createElement(MountHook,{hookProps:r,didMount:n.dayCellDidMount,willUnmount:n.dayCellWillUnmount,elRef:e.elRef},(function(t){return e.children(t,o,i,r.isDisabled)}))},t}(BaseComponent);function renderFill(e){return createElement("div",{className:"fc-"+e})}var BgEvent=function(e){return createElement(EventRoot,{defaultContent:renderInnerContent$3,seg:e.seg,timeText:"",disableDragging:!0,disableResizing:!0,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:!1,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(e,t,n,r,o){return createElement("div",{ref:e,className:["fc-bg-event"].concat(t).join(" "),style:{backgroundColor:o.backgroundColor}},r)}))};function renderInnerContent$3(e){return e.event.title&&createElement("div",{className:"fc-event-title"},e.event.title)}var WeekNumberRoot=function(e){return createElement(ViewContextType.Consumer,null,(function(t){var n=t.dateEnv,r=t.options,o=e.date,i=r.weekNumberFormat||e.defaultFormat,a=n.computeWeekNumber(o),s=n.format(o,i);return createElement(RenderHook,{hookProps:{num:a,text:s,date:o},classNames:r.weekNumberClassNames,content:r.weekNumberContent,defaultContent:renderInner,didMount:r.weekNumberDidMount,willUnmount:r.weekNumberWillUnmount},e.children)}))};function renderInner(e){return e.text}var PADDING_FROM_VIEWPORT=10,Popover=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={titleId:getUniqueDomId()},t.handleRootEl=function(e){t.rootEl=e,t.props.elRef&&setRef(t.props.elRef,e)},t.handleDocumentMouseDown=function(e){var n=getEventTargetViaRoot(e);t.rootEl.contains(n)||t.handleCloseClick()},t.handleDocumentKeyDown=function(e){"Escape"===e.key&&t.handleCloseClick()},t.handleCloseClick=function(){var e=t.props.onClose;e&&e()},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.theme,n=e.options,r=this.props,o=this.state,i=["fc-popover",t.getClass("popover")].concat(r.extraClassNames||[]);return createPortal(createElement("div",__assign$1({id:r.id,className:i.join(" "),"aria-labelledby":o.titleId},r.extraAttrs,{ref:this.handleRootEl}),createElement("div",{className:"fc-popover-header "+t.getClass("popoverHeader")},createElement("span",{className:"fc-popover-title",id:o.titleId},r.title),createElement("span",{className:"fc-popover-close "+t.getIconClass("close"),title:n.closeHint,onClick:this.handleCloseClick})),createElement("div",{className:"fc-popover-body "+t.getClass("popoverContent")},r.children)),r.parentEl)},t.prototype.componentDidMount=function(){document.addEventListener("mousedown",this.handleDocumentMouseDown),document.addEventListener("keydown",this.handleDocumentKeyDown),this.updateSize()},t.prototype.componentWillUnmount=function(){document.removeEventListener("mousedown",this.handleDocumentMouseDown),document.removeEventListener("keydown",this.handleDocumentKeyDown)},t.prototype.updateSize=function(){var e=this.context.isRtl,t=this.props,n=t.alignmentEl,r=t.alignGridTop,o=this.rootEl,i=computeClippedClientRect(n);if(i){var a=o.getBoundingClientRect(),s=r?elementClosest(n,".fc-scrollgrid").getBoundingClientRect().top:i.top,l=e?i.right-a.width:i.left;s=Math.max(s,PADDING_FROM_VIEWPORT),l=Math.min(l,document.documentElement.clientWidth-PADDING_FROM_VIEWPORT-a.width),l=Math.max(l,PADDING_FROM_VIEWPORT);var u=o.offsetParent.getBoundingClientRect();applyStyle(o,{top:s-u.top,left:l-u.left})}},t}(BaseComponent),MorePopover=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleRootEl=function(e){t.rootEl=e,e?t.context.registerInteractiveComponent(t,{el:e,useEventCenter:!1}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.options,n=e.dateEnv,r=this.props,o=r.startDate,i=r.todayRange,a=r.dateProfile,s=n.format(o,t.dayPopoverFormat);return createElement(DayCellRoot,{date:o,dateProfile:a,todayRange:i,elRef:this.handleRootEl},(function(e,t,n){return createElement(Popover,{elRef:e,id:r.id,title:s,extraClassNames:["fc-more-popover"].concat(t),extraAttrs:n,parentEl:r.parentEl,alignmentEl:r.alignmentEl,alignGridTop:r.alignGridTop,onClose:r.onClose},createElement(DayCellContent,{date:o,dateProfile:a,todayRange:i},(function(e,t){return t&&createElement("div",{className:"fc-more-popover-misc",ref:e},t)})),r.children)}))},t.prototype.queryHit=function(e,t,n,r){var o=this.rootEl,i=this.props;return e>=0&&e<n&&t>=0&&t<r?{dateProfile:i.dateProfile,dateSpan:__assign$1({allDay:!0,range:{start:i.startDate,end:i.endDate}},i.extraDateSpan),dayEl:o,rect:{left:0,top:0,right:n,bottom:r},layer:1}:null},t}(DateComponent),MoreLinkRoot=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.linkElRef=createRef(),t.state={isPopoverOpen:!1,popoverId:getUniqueDomId()},t.handleClick=function(e){var n=t,r=n.props,o=n.context,i=o.options.moreLinkClick,a=computeRange(r).start;function s(e){var t=e.eventRange,n=t.def,r=t.instance,i=t.range;return{event:new EventApi(o,n,r),start:o.dateEnv.toDate(i.start),end:o.dateEnv.toDate(i.end),isStart:e.isStart,isEnd:e.isEnd}}"function"==typeof i&&(i=i({date:a,allDay:Boolean(r.allDayDate),allSegs:r.allSegs.map(s),hiddenSegs:r.hiddenSegs.map(s),jsEvent:e,view:o.viewApi})),i&&"popover"!==i?"string"==typeof i&&o.calendarApi.zoomTo(a,i):t.setState({isPopoverOpen:!0})},t.handlePopoverClose=function(){t.setState({isPopoverOpen:!1})},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.state;return createElement(ViewContextType.Consumer,null,(function(r){var o=r.viewApi,i=r.options,a=r.calendarApi,s=i.moreLinkText,l=t.moreCnt,u=computeRange(t),c="function"==typeof s?s.call(a,l):"+"+l+" "+s,d=formatWithOrdinals(i.moreLinkHint,[l],c),p={num:l,shortText:"+"+l,text:c,view:o};return createElement(Fragment,null,Boolean(t.moreCnt)&&createElement(RenderHook,{elRef:e.linkElRef,hookProps:p,classNames:i.moreLinkClassNames,content:i.moreLinkContent,defaultContent:t.defaultContent||renderMoreLinkInner$1,didMount:i.moreLinkDidMount,willUnmount:i.moreLinkWillUnmount},(function(r,o,i,a){return t.children(r,["fc-more-link"].concat(o),i,a,e.handleClick,d,n.isPopoverOpen,n.isPopoverOpen?n.popoverId:"")})),n.isPopoverOpen&&createElement(MorePopover,{id:n.popoverId,startDate:u.start,endDate:u.end,dateProfile:t.dateProfile,todayRange:t.todayRange,extraDateSpan:t.extraDateSpan,parentEl:e.parentEl,alignmentEl:t.alignmentElRef.current,alignGridTop:t.alignGridTop,onClose:e.handlePopoverClose},t.popoverContent()))}))},t.prototype.componentDidMount=function(){this.updateParentEl()},t.prototype.componentDidUpdate=function(){this.updateParentEl()},t.prototype.updateParentEl=function(){this.linkElRef.current&&(this.parentEl=elementClosest(this.linkElRef.current,".fc-view-harness"))},t}(BaseComponent);function renderMoreLinkInner$1(e){return e.text}function computeRange(e){if(e.allDayDate)return{start:e.allDayDate,end:addDays(e.allDayDate,1)};var t=e.hiddenSegs;return{start:computeEarliestSegStart(t),end:computeLatestSegEnd(t)}}function computeEarliestSegStart(e){return e.reduce(pickEarliestStart).eventRange.range.start}function pickEarliestStart(e,t){return e.eventRange.range.start<t.eventRange.range.start?e:t}function computeLatestSegEnd(e){return e.reduce(pickLatestEnd).eventRange.range.end}function pickLatestEnd(e,t){return e.eventRange.range.end>t.eventRange.range.end?e:t}var FullCalendar$1=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._calendarApi=new CalendarApi,t}return __extends(t,e),t.prototype.render=function(){return React__namespace.createElement(CalendarDataProvider,{optionOverrides:this.props,calendarApi:this._calendarApi},(function(e){return React__namespace.createElement(CalendarRoot,{options:e.calendarOptions,theme:e.theme,emitter:e.emitter},(function(t,n,r,o){return React__namespace.createElement("div",{className:t.join(" "),style:{height:n}},React__namespace.createElement(CalendarContent,__assign$1({isHeightAuto:r,forPrint:o},e)))}))}))},t.prototype.getApi=function(){return this._calendarApi},t}(React__namespace.Component),TableView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.headerElRef=createRef(),t}return __extends(t,e),t.prototype.renderSimpleLayout=function(e,t){var n=this.props,r=this.context,o=[],i=getStickyHeaderDates(r.options);return e&&o.push({type:"header",key:"header",isSticky:i,chunk:{elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}}),o.push({type:"body",key:"body",liquid:!0,chunk:{content:t}}),createElement(ViewRoot,{viewSpec:r.viewSpec},(function(e,t){return createElement("div",{ref:e,className:["fc-daygrid"].concat(t).join(" ")},createElement(SimpleScrollGrid,{liquid:!n.isHeightAuto&&!n.forPrint,collapsibleWidth:n.forPrint,cols:[],sections:o}))}))},t.prototype.renderHScrollLayout=function(e,t,n,r){var o=this.context.pluginHooks.scrollGridImpl;if(!o)throw new Error("No ScrollGrid implementation");var i=this.props,a=this.context,s=!i.forPrint&&getStickyHeaderDates(a.options),l=!i.forPrint&&getStickyFooterScrollbar(a.options),u=[];return e&&u.push({type:"header",key:"header",isSticky:s,chunks:[{key:"main",elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}]}),u.push({type:"body",key:"body",liquid:!0,chunks:[{key:"main",content:t}]}),l&&u.push({type:"footer",key:"footer",isSticky:!0,chunks:[{key:"main",content:renderScrollShim}]}),createElement(ViewRoot,{viewSpec:a.viewSpec},(function(e,t){return createElement("div",{ref:e,className:["fc-daygrid"].concat(t).join(" ")},createElement(o,{liquid:!i.isHeightAuto&&!i.forPrint,collapsibleWidth:i.forPrint,colGroups:[{cols:[{span:n,minWidth:r}]}],sections:u}))}))},t}(DateComponent);
8
8
  /*!
9
9
  FullCalendar v5.11.4
10
10
  Docs & License: https://fullcalendar.io/
11
11
  (c) 2022 Adam Shaw
12
- */function splitSegsByRow(e,t){for(var n=[],r=0;r<t;r+=1)n[r]=[];for(var o=0,i=e;o<i.length;o++){var a=i[o];n[a.row].push(a)}return n}function splitSegsByFirstCol(e,t){for(var n=[],r=0;r<t;r+=1)n[r]=[];for(var o=0,i=e;o<i.length;o++){var a=i[o];n[a.firstCol].push(a)}return n}function splitInteractionByRow(e,t){var n=[];if(e){for(a=0;a<t;a+=1)n[a]={affectedInstances:e.affectedInstances,isEvent:e.isEvent,segs:[]};for(var r=0,o=e.segs;r<o.length;r++){var i=o[r];n[i.row].segs.push(i)}}else for(var a=0;a<t;a+=1)n[a]=null;return n}var TableCellTop=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=buildNavLinkAttrs(this.context,e.date);return createElement(DayCellContent,{date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraHookProps:e.extraHookProps,defaultContent:renderTopInner},(function(n,r){return(r||e.forceDayTop)&&createElement("div",{className:"fc-daygrid-day-top",ref:n},createElement("a",__assign$1({id:e.dayNumberId,className:"fc-daygrid-day-number"},t),r||createElement(Fragment,null," ")))}))},t}(BaseComponent);function renderTopInner(e){return e.dayNumberText}var DEFAULT_TABLE_EVENT_TIME_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"narrow"});function hasListItemDisplay(e){var t=e.eventRange.ui.display;return"list-item"===t||"auto"===t&&!e.eventRange.def.allDay&&e.firstCol===e.lastCol&&e.isStart&&e.isEnd}var TableBlockEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props;return createElement(StandardEvent,__assign$1({},e,{extraClassNames:["fc-daygrid-event","fc-daygrid-block-event","fc-h-event"],defaultTimeFormat:DEFAULT_TABLE_EVENT_TIME_FORMAT,defaultDisplayEventEnd:e.defaultDisplayEventEnd,disableResizing:!e.seg.eventRange.def.allDay}))},t}(BaseComponent),TableListItemEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options.eventTimeFormat||DEFAULT_TABLE_EVENT_TIME_FORMAT,r=buildSegTimeText(e.seg,n,t,!0,e.defaultDisplayEventEnd);return createElement(EventRoot,{seg:e.seg,timeText:r,defaultContent:renderInnerContent$2,isDragging:e.isDragging,isResizing:!1,isDateSelecting:!1,isSelected:e.isSelected,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(n,r,o,i){return createElement("a",__assign$1({className:["fc-daygrid-event","fc-daygrid-dot-event"].concat(r).join(" "),ref:n},getSegAnchorAttrs(e.seg,t)),i)}))},t}(BaseComponent);function renderInnerContent$2(e){return createElement(Fragment,null,createElement("div",{className:"fc-daygrid-event-dot",style:{borderColor:e.borderColor||e.backgroundColor}}),e.timeText&&createElement("div",{className:"fc-event-time"},e.timeText),createElement("div",{className:"fc-event-title"},e.event.title||createElement(Fragment,null," ")))}var TableCellMoreLink=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.compileSegs=memoize(compileSegs),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.compileSegs(e.singlePlacements),n=t.allSegs,r=t.invisibleSegs;return createElement(MoreLinkRoot,{dateProfile:e.dateProfile,todayRange:e.todayRange,allDayDate:e.allDayDate,moreCnt:e.moreCnt,allSegs:n,hiddenSegs:r,alignmentElRef:e.alignmentElRef,alignGridTop:e.alignGridTop,extraDateSpan:e.extraDateSpan,popoverContent:function(){var t=(e.eventDrag?e.eventDrag.affectedInstances:null)||(e.eventResize?e.eventResize.affectedInstances:null)||{};return createElement(Fragment,null,n.map((function(n){var r=n.eventRange.instance.instanceId;return createElement("div",{className:"fc-daygrid-event-harness",key:r,style:{visibility:t[r]?"hidden":""}},hasListItemDisplay(n)?createElement(TableListItemEvent,__assign$1({seg:n,isDragging:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},getSegMeta(n,e.todayRange))):createElement(TableBlockEvent,__assign$1({seg:n,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},getSegMeta(n,e.todayRange))))})))}},(function(e,t,n,r,o,i,a,s){return createElement("a",__assign$1({ref:e,className:["fc-daygrid-more-link"].concat(t).join(" "),title:i,"aria-expanded":a,"aria-controls":s},createAriaClickAttrs(o)),r)}))},t}(BaseComponent);function compileSegs(e){for(var t=[],n=[],r=0,o=e;r<o.length;r++){var i=o[r];t.push(i.seg),i.isVisible||n.push(i.seg)}return{allSegs:t,invisibleSegs:n}}var DEFAULT_WEEK_NUM_FORMAT$1=createFormatter({week:"narrow"}),TableCell=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.state={dayNumberId:getUniqueDomId()},t.handleRootEl=function(e){setRef(t.rootElRef,e),setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=e.context,n=e.props,r=e.state,o=e.rootElRef,i=n.date,a=n.dateProfile,s=buildNavLinkAttrs(t,i,"week");return createElement(DayCellRoot,{date:i,dateProfile:a,todayRange:n.todayRange,showDayNumber:n.showDayNumber,extraHookProps:n.extraHookProps,elRef:this.handleRootEl},(function(e,t,l,u){return createElement("td",__assign$1({ref:e,role:"gridcell",className:["fc-daygrid-day"].concat(t,n.extraClassNames||[]).join(" ")},l,n.extraDataAttrs,n.showDayNumber?{"aria-labelledby":r.dayNumberId}:{}),createElement("div",{className:"fc-daygrid-day-frame fc-scrollgrid-sync-inner",ref:n.innerElRef},n.showWeekNumber&&createElement(WeekNumberRoot,{date:i,defaultFormat:DEFAULT_WEEK_NUM_FORMAT$1},(function(e,t,n,r){return createElement("a",__assign$1({ref:e,className:["fc-daygrid-week-number"].concat(t).join(" ")},s),r)})),!u&&createElement(TableCellTop,{date:i,dateProfile:a,showDayNumber:n.showDayNumber,dayNumberId:r.dayNumberId,forceDayTop:n.forceDayTop,todayRange:n.todayRange,extraHookProps:n.extraHookProps}),createElement("div",{className:"fc-daygrid-day-events",ref:n.fgContentElRef},n.fgContent,createElement("div",{className:"fc-daygrid-day-bottom",style:{marginTop:n.moreMarginTop}},createElement(TableCellMoreLink,{allDayDate:i,singlePlacements:n.singlePlacements,moreCnt:n.moreCnt,alignmentElRef:o,alignGridTop:!n.showDayNumber,extraDateSpan:n.extraDateSpan,dateProfile:n.dateProfile,eventSelection:n.eventSelection,eventDrag:n.eventDrag,eventResize:n.eventResize,todayRange:n.todayRange}))),createElement("div",{className:"fc-daygrid-day-bg"},n.bgContent)))}))},t}(DateComponent);function computeFgSegPlacement(e,t,n,r,o,i,a){var s=new DayGridSegHierarchy;s.allowReslicing=!0,s.strictOrder=r,!0===t||!0===n?(s.maxCoord=i,s.hiddenConsumes=!0):"number"==typeof t?s.maxStackCnt=t:"number"==typeof n&&(s.maxStackCnt=n,s.hiddenConsumes=!0);for(var l=[],u=[],c=0;c<e.length;c+=1){var d=o[(C=e[c]).eventRange.instance.instanceId];null!=d?l.push({index:c,thickness:d,span:{start:C.firstCol,end:C.lastCol+1}}):u.push(C)}for(var p=s.addSegs(l),f=placeRects(s.toRects(),e,a),h=f.singleColPlacements,g=f.multiColPlacements,v=f.leftoverMargins,m=[],y=[],E=0,S=u;E<S.length;E++){g[(C=S[E]).firstCol].push({seg:C,isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(var D=C.firstCol;D<=C.lastCol;D+=1)h[D].push({seg:resliceSeg(C,D,D+1,a),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(D=0;D<a.length;D+=1)m.push(0);for(var T=0,b=p;T<b.length;T++){var w=b[T],C=e[w.index],R=w.span;g[R.start].push({seg:resliceSeg(C,R.start,R.end,a),isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(D=R.start;D<R.end;D+=1)m[D]+=1,h[D].push({seg:resliceSeg(C,D,D+1,a),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(D=0;D<a.length;D+=1)y.push(v[D]);return{singleColPlacements:h,multiColPlacements:g,moreCnts:m,moreMarginTops:y}}function placeRects(e,t,n){for(var r=groupRectsByEachCol(e,n.length),o=[],i=[],a=[],s=0;s<n.length;s+=1){for(var l=r[s],u=[],c=0,d=0,p=0,f=l;p<f.length;p++){var h=t[(y=f[p]).index];u.push({seg:resliceSeg(h,s,s+1,n),isVisible:!0,isAbsolute:!1,absoluteTop:y.levelCoord,marginTop:y.levelCoord-c}),c=y.levelCoord+y.thickness}var g=[];c=0,d=0;for(var v=0,m=l;v<m.length;v++){h=t[(y=m[v]).index];var y,E=y.span.end-y.span.start>1,S=y.span.start===s;d+=y.levelCoord-c,c=y.levelCoord+y.thickness,E?(d+=y.thickness,S&&g.push({seg:resliceSeg(h,y.span.start,y.span.end,n),isVisible:!0,isAbsolute:!0,absoluteTop:y.levelCoord,marginTop:0})):S&&(g.push({seg:resliceSeg(h,y.span.start,y.span.end,n),isVisible:!0,isAbsolute:!1,absoluteTop:y.levelCoord,marginTop:d}),d=0)}o.push(u),i.push(g),a.push(d)}return{singleColPlacements:o,multiColPlacements:i,leftoverMargins:a}}function groupRectsByEachCol(e,t){for(var n=[],r=0;r<t;r+=1)n.push([]);for(var o=0,i=e;o<i.length;o++){var a=i[o];for(r=a.span.start;r<a.span.end;r+=1)n[r].push(a)}return n}function resliceSeg(e,t,n,r){if(e.firstCol===t&&e.lastCol===n-1)return e;var o=e.eventRange,i=o.range,a=intersectRanges(i,{start:r[t].date,end:addDays(r[n-1].date,1)});return __assign$1(__assign$1({},e),{firstCol:t,lastCol:n-1,eventRange:{def:o.def,ui:__assign$1(__assign$1({},o.ui),{durationEditable:!1}),instance:o.instance,range:a},isStart:e.isStart&&a.start.valueOf()===i.start.valueOf(),isEnd:e.isEnd&&a.end.valueOf()===i.end.valueOf()})}var DayGridSegHierarchy=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.hiddenConsumes=!1,t.forceHidden={},t}return __extends(t,e),t.prototype.addSegs=function(t){for(var n=this,r=e.prototype.addSegs.call(this,t),o=this.entriesByLevel,i=function(e){return!n.forceHidden[buildEntryKey(e)]},a=0;a<o.length;a+=1)o[a]=o[a].filter(i);return r},t.prototype.handleInvalidInsertion=function(t,n,r){var o=this.entriesByLevel,i=this.forceHidden,a=t.touchingEntry,s=t.touchingLevel,l=t.touchingLateral;if(this.hiddenConsumes&&a){var u=buildEntryKey(a);if(!i[u])if(this.allowReslicing){var c=__assign$1(__assign$1({},a),{span:intersectSpans(a.span,n.span)});i[buildEntryKey(c)]=!0,o[s][l]=c,this.splitEntry(a,n,r)}else i[u]=!0,r.push(a)}return e.prototype.handleInvalidInsertion.call(this,t,n,r)},t}(SegHierarchy),TableRow=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.cellElRefs=new RefMap,t.frameElRefs=new RefMap,t.fgElRefs=new RefMap,t.segHarnessRefs=new RefMap,t.rootElRef=createRef(),t.state={framePositions:null,maxContentHeight:null,eventInstanceHeights:{}},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this,n=t.props,r=t.state,o=t.context.options,i=n.cells.length,a=splitSegsByFirstCol(n.businessHourSegs,i),s=splitSegsByFirstCol(n.bgEventSegs,i),l=splitSegsByFirstCol(this.getHighlightSegs(),i),u=splitSegsByFirstCol(this.getMirrorSegs(),i),c=computeFgSegPlacement(sortEventSegs(n.fgEventSegs,o.eventOrder),n.dayMaxEvents,n.dayMaxEventRows,o.eventOrderStrict,r.eventInstanceHeights,r.maxContentHeight,n.cells),d=c.singleColPlacements,p=c.multiColPlacements,f=c.moreCnts,h=c.moreMarginTops,g=n.eventDrag&&n.eventDrag.affectedInstances||n.eventResize&&n.eventResize.affectedInstances||{};return createElement("tr",{ref:this.rootElRef,role:"row"},n.renderIntro&&n.renderIntro(),n.cells.map((function(t,r){var o=e.renderFgSegs(r,n.forPrint?d[r]:p[r],n.todayRange,g),i=e.renderFgSegs(r,buildMirrorPlacements(u[r],p),n.todayRange,{},Boolean(n.eventDrag),Boolean(n.eventResize),!1);return createElement(TableCell,{key:t.key,elRef:e.cellElRefs.createRef(t.key),innerElRef:e.frameElRefs.createRef(t.key),dateProfile:n.dateProfile,date:t.date,showDayNumber:n.showDayNumbers,showWeekNumber:n.showWeekNumbers&&0===r,forceDayTop:n.showWeekNumbers,todayRange:n.todayRange,eventSelection:n.eventSelection,eventDrag:n.eventDrag,eventResize:n.eventResize,extraHookProps:t.extraHookProps,extraDataAttrs:t.extraDataAttrs,extraClassNames:t.extraClassNames,extraDateSpan:t.extraDateSpan,moreCnt:f[r],moreMarginTop:h[r],singlePlacements:d[r],fgContentElRef:e.fgElRefs.createRef(t.key),fgContent:createElement(Fragment,null,createElement(Fragment,null,o),createElement(Fragment,null,i)),bgContent:createElement(Fragment,null,e.renderFillSegs(l[r],"highlight"),e.renderFillSegs(a[r],"non-business"),e.renderFillSegs(s[r],"bg-event"))})})))},t.prototype.componentDidMount=function(){this.updateSizing(!0)},t.prototype.componentDidUpdate=function(e,t){var n=this.props;this.updateSizing(!isPropsEqual(e,n))},t.prototype.getHighlightSegs=function(){var e=this.props;return e.eventDrag&&e.eventDrag.segs.length?e.eventDrag.segs:e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:e.dateSelectionSegs},t.prototype.getMirrorSegs=function(){var e=this.props;return e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:[]},t.prototype.renderFgSegs=function(e,t,n,r,o,i,a){var s=this.context,l=this.props.eventSelection,u=this.state.framePositions,c=1===this.props.cells.length,d=o||i||a,p=[];if(u)for(var f=0,h=t;f<h.length;f++){var g=h[f],v=g.seg,m=v.eventRange.instance.instanceId,y=m+":"+e,E=g.isVisible&&!r[m],S=g.isAbsolute,D="",T="";S&&(s.isRtl?(T=0,D=u.lefts[v.lastCol]-u.lefts[v.firstCol]):(D=0,T=u.rights[v.firstCol]-u.rights[v.lastCol])),p.push(createElement("div",{className:"fc-daygrid-event-harness"+(S?" fc-daygrid-event-harness-abs":""),key:y,ref:d?null:this.segHarnessRefs.createRef(y),style:{visibility:E?"":"hidden",marginTop:S?"":g.marginTop,top:S?g.absoluteTop:"",left:D,right:T}},hasListItemDisplay(v)?createElement(TableListItemEvent,__assign$1({seg:v,isDragging:o,isSelected:m===l,defaultDisplayEventEnd:c},getSegMeta(v,n))):createElement(TableBlockEvent,__assign$1({seg:v,isDragging:o,isResizing:i,isDateSelecting:a,isSelected:m===l,defaultDisplayEventEnd:c},getSegMeta(v,n)))))}return p},t.prototype.renderFillSegs=function(e,t){var n=this.context.isRtl,r=this.props.todayRange,o=this.state.framePositions,i=[];if(o)for(var a=0,s=e;a<s.length;a++){var l=s[a],u=n?{right:0,left:o.lefts[l.lastCol]-o.lefts[l.firstCol]}:{left:0,right:o.rights[l.firstCol]-o.rights[l.lastCol]};i.push(createElement("div",{key:buildEventRangeKey(l.eventRange),className:"fc-daygrid-bg-harness",style:u},"bg-event"===t?createElement(BgEvent,__assign$1({seg:l},getSegMeta(l,r))):renderFill(t)))}return createElement.apply(void 0,__spreadArray([Fragment,{}],i))},t.prototype.updateSizing=function(e){var t=this.props,n=this.frameElRefs;if(!t.forPrint&&null!==t.clientWidth){if(e){var r=t.cells.map((function(e){return n.currentMap[e.key]}));if(r.length){var o=this.rootElRef.current;this.setState({framePositions:new PositionCache(o,r,!0,!1)})}}var i=this.state.eventInstanceHeights,a=this.queryEventInstanceHeights(),s=!0===t.dayMaxEvents||!0===t.dayMaxEventRows;this.safeSetState({eventInstanceHeights:__assign$1(__assign$1({},i),a),maxContentHeight:s?this.computeMaxContentHeight():null})}},t.prototype.queryEventInstanceHeights=function(){var e=this.segHarnessRefs.currentMap,t={};for(var n in e){var r=Math.round(e[n].getBoundingClientRect().height),o=n.split(":")[0];t[o]=Math.max(t[o]||0,r)}return t},t.prototype.computeMaxContentHeight=function(){var e=this.props.cells[0].key,t=this.cellElRefs.currentMap[e],n=this.fgElRefs.currentMap[e];return t.getBoundingClientRect().bottom-n.getBoundingClientRect().top},t.prototype.getCellEls=function(){var e=this.cellElRefs.currentMap;return this.props.cells.map((function(t){return e[t.key]}))},t}(DateComponent);function buildMirrorPlacements(e,t){if(!e.length)return[];var n=buildAbsoluteTopHash(t);return e.map((function(e){return{seg:e,isVisible:!0,isAbsolute:!0,absoluteTop:n[e.eventRange.instance.instanceId],marginTop:0}}))}function buildAbsoluteTopHash(e){for(var t={},n=0,r=e;n<r.length;n++)for(var o=0,i=r[n];o<i.length;o++){var a=i[o];t[a.seg.eventRange.instance.instanceId]=a.absoluteTop}return t}TableRow.addStateEquality({eventInstanceHeights:isPropsEqual});var Table=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.splitBusinessHourSegs=memoize(splitSegsByRow),t.splitBgEventSegs=memoize(splitSegsByRow),t.splitFgEventSegs=memoize(splitSegsByRow),t.splitDateSelectionSegs=memoize(splitSegsByRow),t.splitEventDrag=memoize(splitInteractionByRow),t.splitEventResize=memoize(splitInteractionByRow),t.rowRefs=new RefMap,t.handleRootEl=function(e){t.rootEl=e,e?t.context.registerInteractiveComponent(t,{el:e,isHitComboAllowed:t.props.isHitComboAllowed}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.dateProfile,r=t.dayMaxEventRows,o=t.dayMaxEvents,i=t.expandRows,a=t.cells.length,s=this.splitBusinessHourSegs(t.businessHourSegs,a),l=this.splitBgEventSegs(t.bgEventSegs,a),u=this.splitFgEventSegs(t.fgEventSegs,a),c=this.splitDateSelectionSegs(t.dateSelectionSegs,a),d=this.splitEventDrag(t.eventDrag,a),p=this.splitEventResize(t.eventResize,a),f=!0===o||!0===r;return f&&!i&&(f=!1,r=null,o=null),createElement("div",{className:["fc-daygrid-body",f?"fc-daygrid-body-balanced":"fc-daygrid-body-unbalanced",i?"":"fc-daygrid-body-natural"].join(" "),ref:this.handleRootEl,style:{width:t.clientWidth,minWidth:t.tableMinWidth}},createElement(NowTimer,{unit:"day"},(function(f,h){return createElement(Fragment,null,createElement("table",{role:"presentation",className:"fc-scrollgrid-sync-table",style:{width:t.clientWidth,minWidth:t.tableMinWidth,height:i?t.clientHeight:""}},t.colGroupNode,createElement("tbody",{role:"presentation"},t.cells.map((function(i,f){return createElement(TableRow,{ref:e.rowRefs.createRef(f),key:i.length?i[0].date.toISOString():f,showDayNumbers:a>1,showWeekNumbers:t.showWeekNumbers,todayRange:h,dateProfile:n,cells:i,renderIntro:t.renderRowIntro,businessHourSegs:s[f],eventSelection:t.eventSelection,bgEventSegs:l[f].filter(isSegAllDay),fgEventSegs:u[f],dateSelectionSegs:c[f],eventDrag:d[f],eventResize:p[f],dayMaxEvents:o,dayMaxEventRows:r,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:t.forPrint})})))))})))},t.prototype.prepareHits=function(){this.rowPositions=new PositionCache(this.rootEl,this.rowRefs.collect().map((function(e){return e.getCellEls()[0]})),!1,!0),this.colPositions=new PositionCache(this.rootEl,this.rowRefs.currentMap[0].getCellEls(),!0,!1)},t.prototype.queryHit=function(e,t){var n=this.colPositions,r=this.rowPositions,o=n.leftToIndex(e),i=r.topToIndex(t);if(null!=i&&null!=o){var a=this.props.cells[i][o];return{dateProfile:this.props.dateProfile,dateSpan:__assign$1({range:this.getCellRange(i,o),allDay:!0},a.extraDateSpan),dayEl:this.getCellEl(i,o),rect:{left:n.lefts[o],right:n.rights[o],top:r.tops[i],bottom:r.bottoms[i]},layer:0}}return null},t.prototype.getCellEl=function(e,t){return this.rowRefs.currentMap[e].getCellEls()[t]},t.prototype.getCellRange=function(e,t){var n=this.props.cells[e][t].date;return{start:n,end:addDays(n,1)}},t}(DateComponent);function isSegAllDay(e){return e.eventRange.def.allDay}var DayTableSlicer=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.forceDayIfListItem=!0,t}return __extends(t,e),t.prototype.sliceRange=function(e,t){return t.sliceRange(e)},t}(Slicer),DayTable=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.slicer=new DayTableSlicer,t.tableRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context;return createElement(Table,__assign$1({ref:this.tableRef},this.slicer.sliceProps(e,e.dateProfile,e.nextDayThreshold,t,e.dayTableModel),{dateProfile:e.dateProfile,cells:e.dayTableModel.cells,colGroupNode:e.colGroupNode,tableMinWidth:e.tableMinWidth,renderRowIntro:e.renderRowIntro,dayMaxEvents:e.dayMaxEvents,dayMaxEventRows:e.dayMaxEventRows,showWeekNumbers:e.showWeekNumbers,expandRows:e.expandRows,headerAlignElRef:e.headerAlignElRef,clientWidth:e.clientWidth,clientHeight:e.clientHeight,forPrint:e.forPrint}))},t}(DateComponent),DayTableView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildDayTableModel=memoize(buildDayTableModel),t.headerRef=createRef(),t.tableRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.context,n=t.options,r=t.dateProfileGenerator,o=this.props,i=this.buildDayTableModel(o.dateProfile,r),a=n.dayHeaders&&createElement(DayHeader,{ref:this.headerRef,dateProfile:o.dateProfile,dates:i.headerDates,datesRepDistinctDays:1===i.rowCnt}),s=function(t){return createElement(DayTable,{ref:e.tableRef,dateProfile:o.dateProfile,dayTableModel:i,businessHours:o.businessHours,dateSelection:o.dateSelection,eventStore:o.eventStore,eventUiBases:o.eventUiBases,eventSelection:o.eventSelection,eventDrag:o.eventDrag,eventResize:o.eventResize,nextDayThreshold:n.nextDayThreshold,colGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,dayMaxEvents:n.dayMaxEvents,dayMaxEventRows:n.dayMaxEventRows,showWeekNumbers:n.weekNumbers,expandRows:!o.isHeightAuto,headerAlignElRef:e.headerElRef,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:o.forPrint})};return n.dayMinWidth?this.renderHScrollLayout(a,s,i.colCnt,n.dayMinWidth):this.renderSimpleLayout(a,s)},t}(TableView);function buildDayTableModel(e,t){var n=new DaySeriesModel(e.renderRange,t);return new DayTableModel(n,/year|month|week/.test(e.currentRangeUnit))}var TableDateProfileGenerator=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.buildRenderRange=function(t,n,r){var o,i=this.props.dateEnv,a=e.prototype.buildRenderRange.call(this,t,n,r),s=a.start,l=a.end;(/^(year|month)$/.test(n)&&(s=i.startOfWeek(s),(o=i.startOfWeek(l)).valueOf()!==l.valueOf()&&(l=addWeeks(o,1))),this.props.monthMode&&this.props.fixedWeekCount)&&(l=addWeeks(l,6-Math.ceil(diffWeeks(s,l))));return{start:s,end:l}},t}(DateProfileGenerator),main$3=createPlugin({initialView:"dayGridMonth",views:{dayGrid:{component:DayTableView,dateProfileGeneratorClass:TableDateProfileGenerator},dayGridDay:{type:"dayGrid",duration:{days:1}},dayGridWeek:{type:"dayGrid",duration:{weeks:1}},dayGridMonth:{type:"dayGrid",duration:{months:1},monthMode:!0,fixedWeekCount:!0}}}),AllDaySplitter=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.getKeyInfo=function(){return{allDay:{},timed:{}}},t.prototype.getKeysForDateSpan=function(e){return e.allDay?["allDay"]:["timed"]},t.prototype.getKeysForEventDef=function(e){return e.allDay?hasBgRendering(e)?["timed","allDay"]:["allDay"]:["timed"]},t}(Splitter),DEFAULT_SLAT_LABEL_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"short"});function TimeColsAxisCell(e){var t=["fc-timegrid-slot","fc-timegrid-slot-label",e.isLabeled?"fc-scrollgrid-shrink":"fc-timegrid-slot-minor"];return createElement(ViewContextType.Consumer,null,(function(n){if(!e.isLabeled)return createElement("td",{className:t.join(" "),"data-time":e.isoTimeStr});var r=n.dateEnv,o=n.options,i=n.viewApi,a=null==o.slotLabelFormat?DEFAULT_SLAT_LABEL_FORMAT:Array.isArray(o.slotLabelFormat)?createFormatter(o.slotLabelFormat[0]):createFormatter(o.slotLabelFormat),s={level:0,time:e.time,date:r.toDate(e.date),view:i,text:r.format(e.date,a)};return createElement(RenderHook,{hookProps:s,classNames:o.slotLabelClassNames,content:o.slotLabelContent,defaultContent:renderInnerContent$1,didMount:o.slotLabelDidMount,willUnmount:o.slotLabelWillUnmount},(function(n,r,o,i){return createElement("td",{ref:n,className:t.concat(r).join(" "),"data-time":e.isoTimeStr},createElement("div",{className:"fc-timegrid-slot-label-frame fc-scrollgrid-shrink-frame"},createElement("div",{className:"fc-timegrid-slot-label-cushion fc-scrollgrid-shrink-cushion",ref:o},i)))}))}))}function renderInnerContent$1(e){return e.text}var TimeBodyAxis=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){return this.props.slatMetas.map((function(e){return createElement("tr",{key:e.key},createElement(TimeColsAxisCell,__assign$1({},e)))}))},t}(BaseComponent),DEFAULT_WEEK_NUM_FORMAT=createFormatter({week:"short"}),AUTO_ALL_DAY_MAX_EVENT_ROWS=5,TimeColsView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.allDaySplitter=new AllDaySplitter,t.headerElRef=createRef(),t.rootElRef=createRef(),t.scrollerElRef=createRef(),t.state={slatCoords:null},t.handleScrollTopRequest=function(e){var n=t.scrollerElRef.current;n&&(n.scrollTop=e)},t.renderHeadAxis=function(e,n){void 0===n&&(n="");var r=t.context.options,o=t.props.dateProfile.renderRange,i=1===diffDays(o.start,o.end)?buildNavLinkAttrs(t.context,o.start,"week"):{};return r.weekNumbers&&"day"===e?createElement(WeekNumberRoot,{date:o.start,defaultFormat:DEFAULT_WEEK_NUM_FORMAT},(function(e,t,r,o){return createElement("th",{ref:e,"aria-hidden":!0,className:["fc-timegrid-axis","fc-scrollgrid-shrink"].concat(t).join(" ")},createElement("div",{className:"fc-timegrid-axis-frame fc-scrollgrid-shrink-frame fc-timegrid-axis-frame-liquid",style:{height:n}},createElement("a",__assign$1({ref:r,className:"fc-timegrid-axis-cushion fc-scrollgrid-shrink-cushion fc-scrollgrid-sync-inner"},i),o)))})):createElement("th",{"aria-hidden":!0,className:"fc-timegrid-axis"},createElement("div",{className:"fc-timegrid-axis-frame",style:{height:n}}))},t.renderTableRowAxis=function(e){var n=t.context,r=n.options,o=n.viewApi,i={text:r.allDayText,view:o};return createElement(RenderHook,{hookProps:i,classNames:r.allDayClassNames,content:r.allDayContent,defaultContent:renderAllDayInner$1,didMount:r.allDayDidMount,willUnmount:r.allDayWillUnmount},(function(t,n,r,o){return createElement("td",{ref:t,"aria-hidden":!0,className:["fc-timegrid-axis","fc-scrollgrid-shrink"].concat(n).join(" ")},createElement("div",{className:"fc-timegrid-axis-frame fc-scrollgrid-shrink-frame"+(null==e?" fc-timegrid-axis-frame-liquid":""),style:{height:e}},createElement("span",{className:"fc-timegrid-axis-cushion fc-scrollgrid-shrink-cushion fc-scrollgrid-sync-inner",ref:r},o)))}))},t.handleSlatCoords=function(e){t.setState({slatCoords:e})},t}return __extends(t,e),t.prototype.renderSimpleLayout=function(e,t,n){var r=this.context,o=this.props,i=[],a=getStickyHeaderDates(r.options);return e&&i.push({type:"header",key:"header",isSticky:a,chunk:{elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}}),t&&(i.push({type:"body",key:"all-day",chunk:{content:t}}),i.push({type:"body",key:"all-day-divider",outerContent:createElement("tr",{role:"presentation",className:"fc-scrollgrid-section"},createElement("td",{className:"fc-timegrid-divider "+r.theme.getClass("tableCellShaded")}))})),i.push({type:"body",key:"body",liquid:!0,expandRows:Boolean(r.options.expandRows),chunk:{scrollerElRef:this.scrollerElRef,content:n}}),createElement(ViewRoot,{viewSpec:r.viewSpec,elRef:this.rootElRef},(function(e,t){return createElement("div",{className:["fc-timegrid"].concat(t).join(" "),ref:e},createElement(SimpleScrollGrid,{liquid:!o.isHeightAuto&&!o.forPrint,collapsibleWidth:o.forPrint,cols:[{width:"shrink"}],sections:i}))}))},t.prototype.renderHScrollLayout=function(e,t,n,r,o,i,a){var s=this,l=this.context.pluginHooks.scrollGridImpl;if(!l)throw new Error("No ScrollGrid implementation");var u=this.context,c=this.props,d=!c.forPrint&&getStickyHeaderDates(u.options),p=!c.forPrint&&getStickyFooterScrollbar(u.options),f=[];e&&f.push({type:"header",key:"header",isSticky:d,syncRowHeights:!0,chunks:[{key:"axis",rowContent:function(e){return createElement("tr",{role:"presentation"},s.renderHeadAxis("day",e.rowSyncHeights[0]))}},{key:"cols",elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}]}),t&&(f.push({type:"body",key:"all-day",syncRowHeights:!0,chunks:[{key:"axis",rowContent:function(e){return createElement("tr",{role:"presentation"},s.renderTableRowAxis(e.rowSyncHeights[0]))}},{key:"cols",content:t}]}),f.push({key:"all-day-divider",type:"body",outerContent:createElement("tr",{role:"presentation",className:"fc-scrollgrid-section"},createElement("td",{colSpan:2,className:"fc-timegrid-divider "+u.theme.getClass("tableCellShaded")}))}));var h=u.options.nowIndicator;return f.push({type:"body",key:"body",liquid:!0,expandRows:Boolean(u.options.expandRows),chunks:[{key:"axis",content:function(e){return createElement("div",{className:"fc-timegrid-axis-chunk"},createElement("table",{"aria-hidden":!0,style:{height:e.expandRows?e.clientHeight:""}},e.tableColGroupNode,createElement("tbody",null,createElement(TimeBodyAxis,{slatMetas:i}))),createElement("div",{className:"fc-timegrid-now-indicator-container"},createElement(NowTimer,{unit:h?"minute":"day"},(function(e){var t=h&&a&&a.safeComputeTop(e);return"number"==typeof t?createElement(NowIndicatorRoot,{isAxis:!0,date:e},(function(e,n,r,o){return createElement("div",{ref:e,className:["fc-timegrid-now-indicator-arrow"].concat(n).join(" "),style:{top:t}},o)})):null}))))}},{key:"cols",scrollerElRef:this.scrollerElRef,content:n}]}),p&&f.push({key:"footer",type:"footer",isSticky:!0,chunks:[{key:"axis",content:renderScrollShim},{key:"cols",content:renderScrollShim}]}),createElement(ViewRoot,{viewSpec:u.viewSpec,elRef:this.rootElRef},(function(e,t){return createElement("div",{className:["fc-timegrid"].concat(t).join(" "),ref:e},createElement(l,{liquid:!c.isHeightAuto&&!c.forPrint,collapsibleWidth:!1,colGroups:[{width:"shrink",cols:[{width:"shrink"}]},{cols:[{span:r,minWidth:o}]}],sections:f}))}))},t.prototype.getAllDayMaxEventProps=function(){var e=this.context.options,t=e.dayMaxEvents,n=e.dayMaxEventRows;return!0!==t&&!0!==n||(t=void 0,n=AUTO_ALL_DAY_MAX_EVENT_ROWS),{dayMaxEvents:t,dayMaxEventRows:n}},t}(DateComponent);function renderAllDayInner$1(e){return e.text}var TimeColsSlatsCoords=function(){function e(e,t,n){this.positions=e,this.dateProfile=t,this.slotDuration=n}return e.prototype.safeComputeTop=function(e){var t=this.dateProfile;if(rangeContainsMarker(t.currentRange,e)){var n=startOfDay(e),r=e.valueOf()-n.valueOf();if(r>=asRoughMs(t.slotMinTime)&&r<asRoughMs(t.slotMaxTime))return this.computeTimeTop(createDuration(r))}return null},e.prototype.computeDateTop=function(e,t){return t||(t=startOfDay(e)),this.computeTimeTop(createDuration(e.valueOf()-t.valueOf()))},e.prototype.computeTimeTop=function(e){var t,n,r=this.positions,o=this.dateProfile,i=r.els.length,a=(e.milliseconds-asRoughMs(o.slotMinTime))/asRoughMs(this.slotDuration);return a=Math.max(0,a),a=Math.min(i,a),t=Math.floor(a),n=a-(t=Math.min(t,i-1)),r.tops[t]+r.getHeight(t)*n},e}(),TimeColsSlatsBody=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=e.slatElRefs;return createElement("tbody",null,e.slatMetas.map((function(o,i){var a={time:o.time,date:t.dateEnv.toDate(o.date),view:t.viewApi},s=["fc-timegrid-slot","fc-timegrid-slot-lane",o.isLabeled?"":"fc-timegrid-slot-minor"];return createElement("tr",{key:o.key,ref:r.createRef(o.key)},e.axis&&createElement(TimeColsAxisCell,__assign$1({},o)),createElement(RenderHook,{hookProps:a,classNames:n.slotLaneClassNames,content:n.slotLaneContent,didMount:n.slotLaneDidMount,willUnmount:n.slotLaneWillUnmount},(function(e,t,n,r){return createElement("td",{ref:e,className:s.concat(t).join(" "),"data-time":o.isoTimeStr},r)})))})))},t}(BaseComponent),TimeColsSlats=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.slatElRefs=new RefMap,t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context;return createElement("div",{ref:this.rootElRef,className:"fc-timegrid-slots"},createElement("table",{"aria-hidden":!0,className:t.theme.getClass("table"),style:{minWidth:e.tableMinWidth,width:e.clientWidth,height:e.minHeight}},e.tableColGroupNode,createElement(TimeColsSlatsBody,{slatElRefs:this.slatElRefs,axis:e.axis,slatMetas:e.slatMetas})))},t.prototype.componentDidMount=function(){this.updateSizing()},t.prototype.componentDidUpdate=function(){this.updateSizing()},t.prototype.componentWillUnmount=function(){this.props.onCoords&&this.props.onCoords(null)},t.prototype.updateSizing=function(){var e=this.context,t=this.props;t.onCoords&&null!==t.clientWidth&&(this.rootElRef.current.offsetHeight&&t.onCoords(new TimeColsSlatsCoords(new PositionCache(this.rootElRef.current,collectSlatEls(this.slatElRefs.currentMap,t.slatMetas),!1,!0),this.props.dateProfile,e.options.slotDuration)))},t}(BaseComponent);function collectSlatEls(e,t){return t.map((function(t){return e[t.key]}))}function splitSegsByCol(e,t){var n,r=[];for(n=0;n<t;n+=1)r.push([]);if(e)for(n=0;n<e.length;n+=1)r[e[n].col].push(e[n]);return r}function splitInteractionByCol(e,t){var n=[];if(e){for(a=0;a<t;a+=1)n[a]={affectedInstances:e.affectedInstances,isEvent:e.isEvent,segs:[]};for(var r=0,o=e.segs;r<o.length;r++){var i=o[r];n[i.col].segs.push(i)}}else for(var a=0;a<t;a+=1)n[a]=null;return n}var TimeColMoreLink=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props;return createElement(MoreLinkRoot,{allDayDate:null,moreCnt:t.hiddenSegs.length,allSegs:t.hiddenSegs,hiddenSegs:t.hiddenSegs,alignmentElRef:this.rootElRef,defaultContent:renderMoreLinkInner,extraDateSpan:t.extraDateSpan,dateProfile:t.dateProfile,todayRange:t.todayRange,popoverContent:function(){return renderPlainFgSegs(t.hiddenSegs,t)}},(function(n,r,o,i,a,s,l,u){return createElement("a",{ref:function(t){setRef(n,t),setRef(e.rootElRef,t)},className:["fc-timegrid-more-link"].concat(r).join(" "),style:{top:t.top,bottom:t.bottom},onClick:a,title:s,"aria-expanded":l,"aria-controls":u},createElement("div",{ref:o,className:"fc-timegrid-more-link-inner fc-sticky"},i))}))},t}(BaseComponent);function renderMoreLinkInner(e){return e.shortText}function buildPositioning(e,t,n){var r=new SegHierarchy;null!=t&&(r.strictOrder=t),null!=n&&(r.maxStackCnt=n);var o=groupIntersectingEntries(r.addSegs(e)),i=buildWeb(r);return{segRects:webToRects(i=stretchWeb(i,1)),hiddenGroups:o}}function buildWeb(e){var t=e.entriesByLevel,n=cacheable((function(e,t){return e+":"+t}),(function(r,o){var i=buildNodes(findNextLevelSegs(e,r,o),n),a=t[r][o];return[__assign$1(__assign$1({},a),{nextLevelNodes:i[0]}),a.thickness+i[1]]}));return buildNodes(t.length?{level:0,lateralStart:0,lateralEnd:t[0].length}:null,n)[0]}function buildNodes(e,t){if(!e)return[[],0];for(var n=e.level,r=e.lateralStart,o=e.lateralEnd,i=r,a=[];i<o;)a.push(t(n,i)),i+=1;return a.sort(cmpDescPressures),[a.map(extractNode),a[0][1]]}function cmpDescPressures(e,t){return t[1]-e[1]}function extractNode(e){return e[0]}function findNextLevelSegs(e,t,n){for(var r=e.levelCoords,o=e.entriesByLevel,i=o[t][n],a=r[t]+i.thickness,s=r.length,l=t;l<s&&r[l]<a;l+=1);for(;l<s;l+=1){for(var u=o[l],c=void 0,d=binarySearch(u,i.span.start,getEntrySpanEnd),p=d[0]+d[1],f=p;(c=u[f])&&c.span.start<i.span.end;)f+=1;if(p<f)return{level:l,lateralStart:p,lateralEnd:f}}return null}function stretchWeb(e,t){var n=cacheable((function(e,t,n){return buildEntryKey(e)}),(function(e,r,o){var i,a=e.nextLevelNodes,s=e.thickness,l=s+o,u=s/l,c=[];if(a.length)for(var d=0,p=a;d<p.length;d++){var f=p[d];if(void 0===i){i=(h=n(f,r,l))[0],c.push(h[1])}else{var h=n(f,i,0);c.push(h[1])}}else i=t;var g=(i-r)*u;return[i-g,__assign$1(__assign$1({},e),{thickness:g,nextLevelNodes:c})]}));return e.map((function(e){return n(e,0,0)[1]}))}function webToRects(e){var t=[],n=cacheable((function(e,t,n){return buildEntryKey(e)}),(function(e,n,o){var i=__assign$1(__assign$1({},e),{levelCoord:n,stackDepth:o,stackForward:0});return t.push(i),i.stackForward=r(e.nextLevelNodes,n+e.thickness,o+1)+1}));function r(e,t,r){for(var o=0,i=0,a=e;i<a.length;i++){var s=a[i];o=Math.max(n(s,t,r),o)}return o}return r(e,0,0),t}function cacheable(e,t){var n={};return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=e.apply(void 0,r);return i in n?n[i]:n[i]=t.apply(void 0,r)}}function computeSegVCoords(e,t,n,r){void 0===n&&(n=null),void 0===r&&(r=0);var o=[];if(n)for(var i=0;i<e.length;i+=1){var a=e[i],s=n.computeDateTop(a.start,t),l=Math.max(s+(r||0),n.computeDateTop(a.end,t));o.push({start:Math.round(s),end:Math.round(l)})}return o}function computeFgSegPlacements(e,t,n,r){for(var o=[],i=[],a=0;a<e.length;a+=1){var s=t[a];s?o.push({index:a,thickness:1,span:s}):i.push(e[a])}for(var l=buildPositioning(o,n,r),u=l.segRects,c=l.hiddenGroups,d=[],p=0,f=u;p<f.length;p++){var h=f[p];d.push({seg:e[h.index],rect:h})}for(var g=0,v=i;g<v.length;g++){var m=v[g];d.push({seg:m,rect:null})}return{segPlacements:d,hiddenGroups:c}}var DEFAULT_TIME_FORMAT$1=createFormatter({hour:"numeric",minute:"2-digit",meridiem:!1}),TimeColEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=["fc-timegrid-event","fc-v-event"];return this.props.isShort&&e.push("fc-timegrid-event-short"),createElement(StandardEvent,__assign$1({},this.props,{defaultTimeFormat:DEFAULT_TIME_FORMAT$1,extraClassNames:e}))},t}(BaseComponent),TimeColMisc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props;return createElement(DayCellContent,{date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,extraHookProps:e.extraHookProps},(function(e,t){return t&&createElement("div",{className:"fc-timegrid-col-misc",ref:e},t)}))},t}(BaseComponent),TimeCol=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.sortEventSegs=memoize(sortEventSegs),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=n.options.selectMirror,o=t.eventDrag&&t.eventDrag.segs||t.eventResize&&t.eventResize.segs||r&&t.dateSelectionSegs||[],i=t.eventDrag&&t.eventDrag.affectedInstances||t.eventResize&&t.eventResize.affectedInstances||{},a=this.sortEventSegs(t.fgEventSegs,n.options.eventOrder);return createElement(DayCellRoot,{elRef:t.elRef,date:t.date,dateProfile:t.dateProfile,todayRange:t.todayRange,extraHookProps:t.extraHookProps},(function(n,s,l){return createElement("td",__assign$1({ref:n,role:"gridcell",className:["fc-timegrid-col"].concat(s,t.extraClassNames||[]).join(" ")},l,t.extraDataAttrs),createElement("div",{className:"fc-timegrid-col-frame"},createElement("div",{className:"fc-timegrid-col-bg"},e.renderFillSegs(t.businessHourSegs,"non-business"),e.renderFillSegs(t.bgEventSegs,"bg-event"),e.renderFillSegs(t.dateSelectionSegs,"highlight")),createElement("div",{className:"fc-timegrid-col-events"},e.renderFgSegs(a,i,!1,!1,!1)),createElement("div",{className:"fc-timegrid-col-events"},e.renderFgSegs(o,{},Boolean(t.eventDrag),Boolean(t.eventResize),Boolean(r))),createElement("div",{className:"fc-timegrid-now-indicator-container"},e.renderNowIndicator(t.nowIndicatorSegs)),createElement(TimeColMisc,{date:t.date,dateProfile:t.dateProfile,todayRange:t.todayRange,extraHookProps:t.extraHookProps})))}))},t.prototype.renderFgSegs=function(e,t,n,r,o){var i=this.props;return i.forPrint?renderPlainFgSegs(e,i):this.renderPositionedFgSegs(e,t,n,r,o)},t.prototype.renderPositionedFgSegs=function(e,t,n,r,o){var i=this,a=this.context.options,s=a.eventMaxStack,l=a.eventShortHeight,u=a.eventOrderStrict,c=a.eventMinHeight,d=this.props,p=d.date,f=d.slatCoords,h=d.eventSelection,g=d.todayRange,v=d.nowDate,m=n||r||o,y=computeFgSegPlacements(e,computeSegVCoords(e,p,f,c),u,s),E=y.segPlacements,S=y.hiddenGroups;return createElement(Fragment,null,this.renderHiddenGroups(S,e),E.map((function(e){var a=e.seg,s=e.rect,u=a.eventRange.instance.instanceId,c=m||Boolean(!t[u]&&s),d=computeSegVStyle(s&&s.span),p=!m&&s?i.computeSegHStyle(s):{left:0,right:0},f=Boolean(s)&&s.stackForward>0,y=Boolean(s)&&s.span.end-s.span.start<l;return createElement("div",{className:"fc-timegrid-event-harness"+(f?" fc-timegrid-event-harness-inset":""),key:u,style:__assign$1(__assign$1({visibility:c?"":"hidden"},d),p)},createElement(TimeColEvent,__assign$1({seg:a,isDragging:n,isResizing:r,isDateSelecting:o,isSelected:u===h,isShort:y},getSegMeta(a,g,v))))})))},t.prototype.renderHiddenGroups=function(e,t){var n=this.props,r=n.extraDateSpan,o=n.dateProfile,i=n.todayRange,a=n.nowDate,s=n.eventSelection,l=n.eventDrag,u=n.eventResize;return createElement(Fragment,null,e.map((function(e){var n=computeSegVStyle(e.span),c=compileSegsFromEntries(e.entries,t);return createElement(TimeColMoreLink,{key:buildIsoString(computeEarliestSegStart(c)),hiddenSegs:c,top:n.top,bottom:n.bottom,extraDateSpan:r,dateProfile:o,todayRange:i,nowDate:a,eventSelection:s,eventDrag:l,eventResize:u})})))},t.prototype.renderFillSegs=function(e,t){var n=this.props,r=this.context,o=computeSegVCoords(e,n.date,n.slatCoords,r.options.eventMinHeight).map((function(r,o){var i=e[o];return createElement("div",{key:buildEventRangeKey(i.eventRange),className:"fc-timegrid-bg-harness",style:computeSegVStyle(r)},"bg-event"===t?createElement(BgEvent,__assign$1({seg:i},getSegMeta(i,n.todayRange,n.nowDate))):renderFill(t))}));return createElement(Fragment,null,o)},t.prototype.renderNowIndicator=function(e){var t=this.props,n=t.slatCoords,r=t.date;return n?e.map((function(e,t){return createElement(NowIndicatorRoot,{isAxis:!1,date:r,key:t},(function(t,o,i,a){return createElement("div",{ref:t,className:["fc-timegrid-now-indicator-line"].concat(o).join(" "),style:{top:n.computeDateTop(e.start,r)}},a)}))})):null},t.prototype.computeSegHStyle=function(e){var t,n,r=this.context,o=r.isRtl,i=r.options.slotEventOverlap,a=e.levelCoord,s=e.levelCoord+e.thickness;i&&(s=Math.min(1,a+2*(s-a))),o?(t=1-s,n=a):(t=a,n=1-s);var l={zIndex:e.stackDepth+1,left:100*t+"%",right:100*n+"%"};return i&&!e.stackForward&&(l[o?"marginLeft":"marginRight"]=20),l},t}(BaseComponent);function renderPlainFgSegs(e,t){var n=t.todayRange,r=t.nowDate,o=t.eventSelection,i=t.eventDrag,a=t.eventResize,s=(i?i.affectedInstances:null)||(a?a.affectedInstances:null)||{};return createElement(Fragment,null,e.map((function(e){var t=e.eventRange.instance.instanceId;return createElement("div",{key:t,style:{visibility:s[t]?"hidden":""}},createElement(TimeColEvent,__assign$1({seg:e,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:t===o,isShort:!1},getSegMeta(e,n,r))))})))}function computeSegVStyle(e){return e?{top:e.start,bottom:-e.end}:{top:"",bottom:""}}function compileSegsFromEntries(e,t){return e.map((function(e){return t[e.index]}))}var TimeColsContent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.splitFgEventSegs=memoize(splitSegsByCol),t.splitBgEventSegs=memoize(splitSegsByCol),t.splitBusinessHourSegs=memoize(splitSegsByCol),t.splitNowIndicatorSegs=memoize(splitSegsByCol),t.splitDateSelectionSegs=memoize(splitSegsByCol),t.splitEventDrag=memoize(splitInteractionByCol),t.splitEventResize=memoize(splitInteractionByCol),t.rootElRef=createRef(),t.cellElRefs=new RefMap,t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context.options.nowIndicator&&t.slatCoords&&t.slatCoords.safeComputeTop(t.nowDate),r=t.cells.length,o=this.splitFgEventSegs(t.fgEventSegs,r),i=this.splitBgEventSegs(t.bgEventSegs,r),a=this.splitBusinessHourSegs(t.businessHourSegs,r),s=this.splitNowIndicatorSegs(t.nowIndicatorSegs,r),l=this.splitDateSelectionSegs(t.dateSelectionSegs,r),u=this.splitEventDrag(t.eventDrag,r),c=this.splitEventResize(t.eventResize,r);return createElement("div",{className:"fc-timegrid-cols",ref:this.rootElRef},createElement("table",{role:"presentation",style:{minWidth:t.tableMinWidth,width:t.clientWidth}},t.tableColGroupNode,createElement("tbody",{role:"presentation"},createElement("tr",{role:"row"},t.axis&&createElement("td",{"aria-hidden":!0,className:"fc-timegrid-col fc-timegrid-axis"},createElement("div",{className:"fc-timegrid-col-frame"},createElement("div",{className:"fc-timegrid-now-indicator-container"},"number"==typeof n&&createElement(NowIndicatorRoot,{isAxis:!0,date:t.nowDate},(function(e,t,r,o){return createElement("div",{ref:e,className:["fc-timegrid-now-indicator-arrow"].concat(t).join(" "),style:{top:n}},o)}))))),t.cells.map((function(n,r){return createElement(TimeCol,{key:n.key,elRef:e.cellElRefs.createRef(n.key),dateProfile:t.dateProfile,date:n.date,nowDate:t.nowDate,todayRange:t.todayRange,extraHookProps:n.extraHookProps,extraDataAttrs:n.extraDataAttrs,extraClassNames:n.extraClassNames,extraDateSpan:n.extraDateSpan,fgEventSegs:o[r],bgEventSegs:i[r],businessHourSegs:a[r],nowIndicatorSegs:s[r],dateSelectionSegs:l[r],eventDrag:u[r],eventResize:c[r],slatCoords:t.slatCoords,eventSelection:t.eventSelection,forPrint:t.forPrint})}))))))},t.prototype.componentDidMount=function(){this.updateCoords()},t.prototype.componentDidUpdate=function(){this.updateCoords()},t.prototype.updateCoords=function(){var e=this.props;e.onColCoords&&null!==e.clientWidth&&e.onColCoords(new PositionCache(this.rootElRef.current,collectCellEls(this.cellElRefs.currentMap,e.cells),!0,!1))},t}(BaseComponent);function collectCellEls(e,t){return t.map((function(t){return e[t.key]}))}var TimeCols=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.processSlotOptions=memoize(processSlotOptions),t.state={slatCoords:null},t.handleRootEl=function(e){e?t.context.registerInteractiveComponent(t,{el:e,isHitComboAllowed:t.props.isHitComboAllowed}):t.context.unregisterInteractiveComponent(t)},t.handleScrollRequest=function(e){var n=t.props.onScrollTopRequest,r=t.state.slatCoords;if(n&&r){if(e.time){var o=r.computeTimeTop(e.time);(o=Math.ceil(o))&&(o+=1),n(o)}return!0}return!1},t.handleColCoords=function(e){t.colCoords=e},t.handleSlatCoords=function(e){t.setState({slatCoords:e}),t.props.onSlatCoords&&t.props.onSlatCoords(e)},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state;return createElement("div",{className:"fc-timegrid-body",ref:this.handleRootEl,style:{width:e.clientWidth,minWidth:e.tableMinWidth}},createElement(TimeColsSlats,{axis:e.axis,dateProfile:e.dateProfile,slatMetas:e.slatMetas,clientWidth:e.clientWidth,minHeight:e.expandRows?e.clientHeight:"",tableMinWidth:e.tableMinWidth,tableColGroupNode:e.axis?e.tableColGroupNode:null,onCoords:this.handleSlatCoords}),createElement(TimeColsContent,{cells:e.cells,axis:e.axis,dateProfile:e.dateProfile,businessHourSegs:e.businessHourSegs,bgEventSegs:e.bgEventSegs,fgEventSegs:e.fgEventSegs,dateSelectionSegs:e.dateSelectionSegs,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,todayRange:e.todayRange,nowDate:e.nowDate,nowIndicatorSegs:e.nowIndicatorSegs,clientWidth:e.clientWidth,tableMinWidth:e.tableMinWidth,tableColGroupNode:e.tableColGroupNode,slatCoords:t.slatCoords,onColCoords:this.handleColCoords,forPrint:e.forPrint}))},t.prototype.componentDidMount=function(){this.scrollResponder=this.context.createScrollResponder(this.handleScrollRequest)},t.prototype.componentDidUpdate=function(e){this.scrollResponder.update(e.dateProfile!==this.props.dateProfile)},t.prototype.componentWillUnmount=function(){this.scrollResponder.detach()},t.prototype.queryHit=function(e,t){var n=this.context,r=n.dateEnv,o=n.options,i=this.colCoords,a=this.props.dateProfile,s=this.state.slatCoords,l=this.processSlotOptions(this.props.slotDuration,o.snapDuration),u=l.snapDuration,c=l.snapsPerSlot,d=i.leftToIndex(e),p=s.positions.topToIndex(t);if(null!=d&&null!=p){var f=this.props.cells[d],h=s.positions.tops[p],g=s.positions.getHeight(p),v=(t-h)/g,m=p*c+Math.floor(v*c),y=this.props.cells[d].date,E=addDurations(a.slotMinTime,multiplyDuration(u,m)),S=r.add(y,E),D=r.add(S,u);return{dateProfile:a,dateSpan:__assign$1({range:{start:S,end:D},allDay:!1},f.extraDateSpan),dayEl:i.els[d],rect:{left:i.lefts[d],right:i.rights[d],top:h,bottom:h+g},layer:0}}return null},t}(DateComponent);function processSlotOptions(e,t){var n=t||e,r=wholeDivideDurations(e,n);return null===r&&(n=e,r=1),{snapDuration:n,snapsPerSlot:r}}var DayTimeColsSlicer=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.sliceRange=function(e,t){for(var n=[],r=0;r<t.length;r+=1){var o=intersectRanges(e,t[r]);o&&n.push({start:o.start,end:o.end,isStart:o.start.valueOf()===e.start.valueOf(),isEnd:o.end.valueOf()===e.end.valueOf(),col:r})}return n},t}(Slicer),DayTimeCols=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildDayRanges=memoize(buildDayRanges),t.slicer=new DayTimeColsSlicer,t.timeColsRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=t.dateProfile,o=t.dayTableModel,i=n.options.nowIndicator,a=this.buildDayRanges(o,r,n.dateEnv);return createElement(NowTimer,{unit:i?"minute":"day"},(function(s,l){return createElement(TimeCols,__assign$1({ref:e.timeColsRef},e.slicer.sliceProps(t,r,null,n,a),{forPrint:t.forPrint,axis:t.axis,dateProfile:r,slatMetas:t.slatMetas,slotDuration:t.slotDuration,cells:o.cells[0],tableColGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,clientWidth:t.clientWidth,clientHeight:t.clientHeight,expandRows:t.expandRows,nowDate:s,nowIndicatorSegs:i&&e.slicer.sliceNowDate(s,n,a),todayRange:l,onScrollTopRequest:t.onScrollTopRequest,onSlatCoords:t.onSlatCoords}))}))},t}(DateComponent);function buildDayRanges(e,t,n){for(var r=[],o=0,i=e.headerDates;o<i.length;o++){var a=i[o];r.push({start:n.add(a,t.slotMinTime),end:n.add(a,t.slotMaxTime)})}return r}var STOCK_SUB_DURATIONS=[{hours:1},{minutes:30},{minutes:15},{seconds:30},{seconds:15}];function buildSlatMetas(e,t,n,r,o){for(var i=new Date(0),a=e,s=createDuration(0),l=n||computeLabelInterval(r),u=[];asRoughMs(a)<asRoughMs(t);){var c=o.add(i,a),d=null!==wholeDivideDurations(s,l);u.push({date:c,time:a,key:c.toISOString(),isoTimeStr:formatIsoTimeString(c),isLabeled:d}),a=addDurations(a,r),s=addDurations(s,r)}return u}function computeLabelInterval(e){var t,n,r;for(t=STOCK_SUB_DURATIONS.length-1;t>=0;t-=1)if(null!==(r=wholeDivideDurations(n=createDuration(STOCK_SUB_DURATIONS[t]),e))&&r>1)return n;return e}var DayTimeColsView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildTimeColsModel=memoize(buildTimeColsModel),t.buildSlatMetas=memoize(buildSlatMetas),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.context,n=t.options,r=t.dateEnv,o=t.dateProfileGenerator,i=this.props,a=i.dateProfile,s=this.buildTimeColsModel(a,o),l=this.allDaySplitter.splitProps(i),u=this.buildSlatMetas(a.slotMinTime,a.slotMaxTime,n.slotLabelInterval,n.slotDuration,r),c=n.dayMinWidth,d=!c,p=c,f=n.dayHeaders&&createElement(DayHeader,{dates:s.headerDates,dateProfile:a,datesRepDistinctDays:!0,renderIntro:d?this.renderHeadAxis:null}),h=!1!==n.allDaySlot&&function(t){return createElement(DayTable,__assign$1({},l.allDay,{dateProfile:a,dayTableModel:s,nextDayThreshold:n.nextDayThreshold,tableMinWidth:t.tableMinWidth,colGroupNode:t.tableColGroupNode,renderRowIntro:d?e.renderTableRowAxis:null,showWeekNumbers:!1,expandRows:!1,headerAlignElRef:e.headerElRef,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:i.forPrint},e.getAllDayMaxEventProps()))},g=function(t){return createElement(DayTimeCols,__assign$1({},l.timed,{dayTableModel:s,dateProfile:a,axis:d,slotDuration:n.slotDuration,slatMetas:u,forPrint:i.forPrint,tableColGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,clientWidth:t.clientWidth,clientHeight:t.clientHeight,onSlatCoords:e.handleSlatCoords,expandRows:t.expandRows,onScrollTopRequest:e.handleScrollTopRequest}))};return p?this.renderHScrollLayout(f,h,g,s.colCnt,c,u,this.state.slatCoords):this.renderSimpleLayout(f,h,g)},t}(TimeColsView);function buildTimeColsModel(e,t){var n=new DaySeriesModel(e.renderRange,t);return new DayTableModel(n,!1)}var OPTION_REFINERS$2={allDaySlot:Boolean},main$2=createPlugin({initialView:"timeGridWeek",optionRefiners:OPTION_REFINERS$2,views:{timeGrid:{component:DayTimeColsView,usesMinMaxTime:!0,allDaySlot:!0,slotDuration:"00:30:00",slotEventOverlap:!0},timeGridDay:{type:"timeGrid",duration:{days:1}},timeGridWeek:{type:"timeGrid",duration:{weeks:1}}}});
12
+ */function splitSegsByRow(e,t){for(var n=[],r=0;r<t;r+=1)n[r]=[];for(var o=0,i=e;o<i.length;o++){var a=i[o];n[a.row].push(a)}return n}function splitSegsByFirstCol(e,t){for(var n=[],r=0;r<t;r+=1)n[r]=[];for(var o=0,i=e;o<i.length;o++){var a=i[o];n[a.firstCol].push(a)}return n}function splitInteractionByRow(e,t){var n=[];if(e){for(a=0;a<t;a+=1)n[a]={affectedInstances:e.affectedInstances,isEvent:e.isEvent,segs:[]};for(var r=0,o=e.segs;r<o.length;r++){var i=o[r];n[i.row].segs.push(i)}}else for(var a=0;a<t;a+=1)n[a]=null;return n}var TableCellTop=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=buildNavLinkAttrs(this.context,e.date);return createElement(DayCellContent,{date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,showDayNumber:e.showDayNumber,extraHookProps:e.extraHookProps,defaultContent:renderTopInner},(function(n,r){return(r||e.forceDayTop)&&createElement("div",{className:"fc-daygrid-day-top",ref:n},createElement("a",__assign$1({id:e.dayNumberId,className:"fc-daygrid-day-number"},t),r||createElement(Fragment,null," ")))}))},t}(BaseComponent);function renderTopInner(e){return e.dayNumberText}var DEFAULT_TABLE_EVENT_TIME_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"narrow"});function hasListItemDisplay(e){var t=e.eventRange.ui.display;return"list-item"===t||"auto"===t&&!e.eventRange.def.allDay&&e.firstCol===e.lastCol&&e.isStart&&e.isEnd}var TableBlockEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props;return createElement(StandardEvent,__assign$1({},e,{extraClassNames:["fc-daygrid-event","fc-daygrid-block-event","fc-h-event"],defaultTimeFormat:DEFAULT_TABLE_EVENT_TIME_FORMAT,defaultDisplayEventEnd:e.defaultDisplayEventEnd,disableResizing:!e.seg.eventRange.def.allDay}))},t}(BaseComponent),TableListItemEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options.eventTimeFormat||DEFAULT_TABLE_EVENT_TIME_FORMAT,r=buildSegTimeText(e.seg,n,t,!0,e.defaultDisplayEventEnd);return createElement(EventRoot,{seg:e.seg,timeText:r,defaultContent:renderInnerContent$2,isDragging:e.isDragging,isResizing:!1,isDateSelecting:!1,isSelected:e.isSelected,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday},(function(n,r,o,i){return createElement("a",__assign$1({className:["fc-daygrid-event","fc-daygrid-dot-event"].concat(r).join(" "),ref:n},getSegAnchorAttrs(e.seg,t)),i)}))},t}(BaseComponent);function renderInnerContent$2(e){return createElement(Fragment,null,createElement("div",{className:"fc-daygrid-event-dot",style:{borderColor:e.borderColor||e.backgroundColor}}),e.timeText&&createElement("div",{className:"fc-event-time"},e.timeText),createElement("div",{className:"fc-event-title"},e.event.title||createElement(Fragment,null," ")))}var TableCellMoreLink=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.compileSegs=memoize(compileSegs),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.compileSegs(e.singlePlacements),n=t.allSegs,r=t.invisibleSegs;return createElement(MoreLinkRoot,{dateProfile:e.dateProfile,todayRange:e.todayRange,allDayDate:e.allDayDate,moreCnt:e.moreCnt,allSegs:n,hiddenSegs:r,alignmentElRef:e.alignmentElRef,alignGridTop:e.alignGridTop,extraDateSpan:e.extraDateSpan,popoverContent:function(){var t=(e.eventDrag?e.eventDrag.affectedInstances:null)||(e.eventResize?e.eventResize.affectedInstances:null)||{};return createElement(Fragment,null,n.map((function(n){var r=n.eventRange.instance.instanceId;return createElement("div",{className:"fc-daygrid-event-harness",key:r,style:{visibility:t[r]?"hidden":""}},hasListItemDisplay(n)?createElement(TableListItemEvent,__assign$1({seg:n,isDragging:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},getSegMeta(n,e.todayRange))):createElement(TableBlockEvent,__assign$1({seg:n,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},getSegMeta(n,e.todayRange))))})))}},(function(e,t,n,r,o,i,a,s){return createElement("a",__assign$1({ref:e,className:["fc-daygrid-more-link"].concat(t).join(" "),title:i,"aria-expanded":a,"aria-controls":s},createAriaClickAttrs(o)),r)}))},t}(BaseComponent);function compileSegs(e){for(var t=[],n=[],r=0,o=e;r<o.length;r++){var i=o[r];t.push(i.seg),i.isVisible||n.push(i.seg)}return{allSegs:t,invisibleSegs:n}}var DEFAULT_WEEK_NUM_FORMAT$1=createFormatter({week:"narrow"}),TableCell=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.state={dayNumberId:getUniqueDomId()},t.handleRootEl=function(e){setRef(t.rootElRef,e),setRef(t.props.elRef,e)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=e.context,n=e.props,r=e.state,o=e.rootElRef,i=n.date,a=n.dateProfile,s=buildNavLinkAttrs(t,i,"week");return createElement(DayCellRoot,{date:i,dateProfile:a,todayRange:n.todayRange,showDayNumber:n.showDayNumber,extraHookProps:n.extraHookProps,elRef:this.handleRootEl},(function(e,t,l,u){return createElement("td",__assign$1({ref:e,role:"gridcell",className:["fc-daygrid-day"].concat(t,n.extraClassNames||[]).join(" ")},l,n.extraDataAttrs,n.showDayNumber?{"aria-labelledby":r.dayNumberId}:{}),createElement("div",{className:"fc-daygrid-day-frame fc-scrollgrid-sync-inner",ref:n.innerElRef},n.showWeekNumber&&createElement(WeekNumberRoot,{date:i,defaultFormat:DEFAULT_WEEK_NUM_FORMAT$1},(function(e,t,n,r){return createElement("a",__assign$1({ref:e,className:["fc-daygrid-week-number"].concat(t).join(" ")},s),r)})),!u&&createElement(TableCellTop,{date:i,dateProfile:a,showDayNumber:n.showDayNumber,dayNumberId:r.dayNumberId,forceDayTop:n.forceDayTop,todayRange:n.todayRange,extraHookProps:n.extraHookProps}),createElement("div",{className:"fc-daygrid-day-events",ref:n.fgContentElRef},n.fgContent,createElement("div",{className:"fc-daygrid-day-bottom",style:{marginTop:n.moreMarginTop}},createElement(TableCellMoreLink,{allDayDate:i,singlePlacements:n.singlePlacements,moreCnt:n.moreCnt,alignmentElRef:o,alignGridTop:!n.showDayNumber,extraDateSpan:n.extraDateSpan,dateProfile:n.dateProfile,eventSelection:n.eventSelection,eventDrag:n.eventDrag,eventResize:n.eventResize,todayRange:n.todayRange}))),createElement("div",{className:"fc-daygrid-day-bg"},n.bgContent)))}))},t}(DateComponent);function computeFgSegPlacement(e,t,n,r,o,i,a){var s=new DayGridSegHierarchy;s.allowReslicing=!0,s.strictOrder=r,!0===t||!0===n?(s.maxCoord=i,s.hiddenConsumes=!0):"number"==typeof t?s.maxStackCnt=t:"number"==typeof n&&(s.maxStackCnt=n,s.hiddenConsumes=!0);for(var l=[],u=[],c=0;c<e.length;c+=1){var d=o[(C=e[c]).eventRange.instance.instanceId];null!=d?l.push({index:c,thickness:d,span:{start:C.firstCol,end:C.lastCol+1}}):u.push(C)}for(var p=s.addSegs(l),f=placeRects(s.toRects(),e,a),h=f.singleColPlacements,g=f.multiColPlacements,m=f.leftoverMargins,v=[],y=[],E=0,S=u;E<S.length;E++){g[(C=S[E]).firstCol].push({seg:C,isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(var D=C.firstCol;D<=C.lastCol;D+=1)h[D].push({seg:resliceSeg(C,D,D+1,a),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(D=0;D<a.length;D+=1)v.push(0);for(var T=0,b=p;T<b.length;T++){var w=b[T],C=e[w.index],R=w.span;g[R.start].push({seg:resliceSeg(C,R.start,R.end,a),isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(D=R.start;D<R.end;D+=1)v[D]+=1,h[D].push({seg:resliceSeg(C,D,D+1,a),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(D=0;D<a.length;D+=1)y.push(m[D]);return{singleColPlacements:h,multiColPlacements:g,moreCnts:v,moreMarginTops:y}}function placeRects(e,t,n){for(var r=groupRectsByEachCol(e,n.length),o=[],i=[],a=[],s=0;s<n.length;s+=1){for(var l=r[s],u=[],c=0,d=0,p=0,f=l;p<f.length;p++){var h=t[(y=f[p]).index];u.push({seg:resliceSeg(h,s,s+1,n),isVisible:!0,isAbsolute:!1,absoluteTop:y.levelCoord,marginTop:y.levelCoord-c}),c=y.levelCoord+y.thickness}var g=[];c=0,d=0;for(var m=0,v=l;m<v.length;m++){h=t[(y=v[m]).index];var y,E=y.span.end-y.span.start>1,S=y.span.start===s;d+=y.levelCoord-c,c=y.levelCoord+y.thickness,E?(d+=y.thickness,S&&g.push({seg:resliceSeg(h,y.span.start,y.span.end,n),isVisible:!0,isAbsolute:!0,absoluteTop:y.levelCoord,marginTop:0})):S&&(g.push({seg:resliceSeg(h,y.span.start,y.span.end,n),isVisible:!0,isAbsolute:!1,absoluteTop:y.levelCoord,marginTop:d}),d=0)}o.push(u),i.push(g),a.push(d)}return{singleColPlacements:o,multiColPlacements:i,leftoverMargins:a}}function groupRectsByEachCol(e,t){for(var n=[],r=0;r<t;r+=1)n.push([]);for(var o=0,i=e;o<i.length;o++){var a=i[o];for(r=a.span.start;r<a.span.end;r+=1)n[r].push(a)}return n}function resliceSeg(e,t,n,r){if(e.firstCol===t&&e.lastCol===n-1)return e;var o=e.eventRange,i=o.range,a=intersectRanges(i,{start:r[t].date,end:addDays(r[n-1].date,1)});return __assign$1(__assign$1({},e),{firstCol:t,lastCol:n-1,eventRange:{def:o.def,ui:__assign$1(__assign$1({},o.ui),{durationEditable:!1}),instance:o.instance,range:a},isStart:e.isStart&&a.start.valueOf()===i.start.valueOf(),isEnd:e.isEnd&&a.end.valueOf()===i.end.valueOf()})}var DayGridSegHierarchy=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.hiddenConsumes=!1,t.forceHidden={},t}return __extends(t,e),t.prototype.addSegs=function(t){for(var n=this,r=e.prototype.addSegs.call(this,t),o=this.entriesByLevel,i=function(e){return!n.forceHidden[buildEntryKey(e)]},a=0;a<o.length;a+=1)o[a]=o[a].filter(i);return r},t.prototype.handleInvalidInsertion=function(t,n,r){var o=this.entriesByLevel,i=this.forceHidden,a=t.touchingEntry,s=t.touchingLevel,l=t.touchingLateral;if(this.hiddenConsumes&&a){var u=buildEntryKey(a);if(!i[u])if(this.allowReslicing){var c=__assign$1(__assign$1({},a),{span:intersectSpans(a.span,n.span)});i[buildEntryKey(c)]=!0,o[s][l]=c,this.splitEntry(a,n,r)}else i[u]=!0,r.push(a)}return e.prototype.handleInvalidInsertion.call(this,t,n,r)},t}(SegHierarchy),TableRow=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.cellElRefs=new RefMap,t.frameElRefs=new RefMap,t.fgElRefs=new RefMap,t.segHarnessRefs=new RefMap,t.rootElRef=createRef(),t.state={framePositions:null,maxContentHeight:null,eventInstanceHeights:{}},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this,n=t.props,r=t.state,o=t.context.options,i=n.cells.length,a=splitSegsByFirstCol(n.businessHourSegs,i),s=splitSegsByFirstCol(n.bgEventSegs,i),l=splitSegsByFirstCol(this.getHighlightSegs(),i),u=splitSegsByFirstCol(this.getMirrorSegs(),i),c=computeFgSegPlacement(sortEventSegs(n.fgEventSegs,o.eventOrder),n.dayMaxEvents,n.dayMaxEventRows,o.eventOrderStrict,r.eventInstanceHeights,r.maxContentHeight,n.cells),d=c.singleColPlacements,p=c.multiColPlacements,f=c.moreCnts,h=c.moreMarginTops,g=n.eventDrag&&n.eventDrag.affectedInstances||n.eventResize&&n.eventResize.affectedInstances||{};return createElement("tr",{ref:this.rootElRef,role:"row"},n.renderIntro&&n.renderIntro(),n.cells.map((function(t,r){var o=e.renderFgSegs(r,n.forPrint?d[r]:p[r],n.todayRange,g),i=e.renderFgSegs(r,buildMirrorPlacements(u[r],p),n.todayRange,{},Boolean(n.eventDrag),Boolean(n.eventResize),!1);return createElement(TableCell,{key:t.key,elRef:e.cellElRefs.createRef(t.key),innerElRef:e.frameElRefs.createRef(t.key),dateProfile:n.dateProfile,date:t.date,showDayNumber:n.showDayNumbers,showWeekNumber:n.showWeekNumbers&&0===r,forceDayTop:n.showWeekNumbers,todayRange:n.todayRange,eventSelection:n.eventSelection,eventDrag:n.eventDrag,eventResize:n.eventResize,extraHookProps:t.extraHookProps,extraDataAttrs:t.extraDataAttrs,extraClassNames:t.extraClassNames,extraDateSpan:t.extraDateSpan,moreCnt:f[r],moreMarginTop:h[r],singlePlacements:d[r],fgContentElRef:e.fgElRefs.createRef(t.key),fgContent:createElement(Fragment,null,createElement(Fragment,null,o),createElement(Fragment,null,i)),bgContent:createElement(Fragment,null,e.renderFillSegs(l[r],"highlight"),e.renderFillSegs(a[r],"non-business"),e.renderFillSegs(s[r],"bg-event"))})})))},t.prototype.componentDidMount=function(){this.updateSizing(!0)},t.prototype.componentDidUpdate=function(e,t){var n=this.props;this.updateSizing(!isPropsEqual(e,n))},t.prototype.getHighlightSegs=function(){var e=this.props;return e.eventDrag&&e.eventDrag.segs.length?e.eventDrag.segs:e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:e.dateSelectionSegs},t.prototype.getMirrorSegs=function(){var e=this.props;return e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:[]},t.prototype.renderFgSegs=function(e,t,n,r,o,i,a){var s=this.context,l=this.props.eventSelection,u=this.state.framePositions,c=1===this.props.cells.length,d=o||i||a,p=[];if(u)for(var f=0,h=t;f<h.length;f++){var g=h[f],m=g.seg,v=m.eventRange.instance.instanceId,y=v+":"+e,E=g.isVisible&&!r[v],S=g.isAbsolute,D="",T="";S&&(s.isRtl?(T=0,D=u.lefts[m.lastCol]-u.lefts[m.firstCol]):(D=0,T=u.rights[m.firstCol]-u.rights[m.lastCol])),p.push(createElement("div",{className:"fc-daygrid-event-harness"+(S?" fc-daygrid-event-harness-abs":""),key:y,ref:d?null:this.segHarnessRefs.createRef(y),style:{visibility:E?"":"hidden",marginTop:S?"":g.marginTop,top:S?g.absoluteTop:"",left:D,right:T}},hasListItemDisplay(m)?createElement(TableListItemEvent,__assign$1({seg:m,isDragging:o,isSelected:v===l,defaultDisplayEventEnd:c},getSegMeta(m,n))):createElement(TableBlockEvent,__assign$1({seg:m,isDragging:o,isResizing:i,isDateSelecting:a,isSelected:v===l,defaultDisplayEventEnd:c},getSegMeta(m,n)))))}return p},t.prototype.renderFillSegs=function(e,t){var n=this.context.isRtl,r=this.props.todayRange,o=this.state.framePositions,i=[];if(o)for(var a=0,s=e;a<s.length;a++){var l=s[a],u=n?{right:0,left:o.lefts[l.lastCol]-o.lefts[l.firstCol]}:{left:0,right:o.rights[l.firstCol]-o.rights[l.lastCol]};i.push(createElement("div",{key:buildEventRangeKey(l.eventRange),className:"fc-daygrid-bg-harness",style:u},"bg-event"===t?createElement(BgEvent,__assign$1({seg:l},getSegMeta(l,r))):renderFill(t)))}return createElement.apply(void 0,__spreadArray([Fragment,{}],i))},t.prototype.updateSizing=function(e){var t=this.props,n=this.frameElRefs;if(!t.forPrint&&null!==t.clientWidth){if(e){var r=t.cells.map((function(e){return n.currentMap[e.key]}));if(r.length){var o=this.rootElRef.current;this.setState({framePositions:new PositionCache(o,r,!0,!1)})}}var i=this.state.eventInstanceHeights,a=this.queryEventInstanceHeights(),s=!0===t.dayMaxEvents||!0===t.dayMaxEventRows;this.safeSetState({eventInstanceHeights:__assign$1(__assign$1({},i),a),maxContentHeight:s?this.computeMaxContentHeight():null})}},t.prototype.queryEventInstanceHeights=function(){var e=this.segHarnessRefs.currentMap,t={};for(var n in e){var r=Math.round(e[n].getBoundingClientRect().height),o=n.split(":")[0];t[o]=Math.max(t[o]||0,r)}return t},t.prototype.computeMaxContentHeight=function(){var e=this.props.cells[0].key,t=this.cellElRefs.currentMap[e],n=this.fgElRefs.currentMap[e];return t.getBoundingClientRect().bottom-n.getBoundingClientRect().top},t.prototype.getCellEls=function(){var e=this.cellElRefs.currentMap;return this.props.cells.map((function(t){return e[t.key]}))},t}(DateComponent);function buildMirrorPlacements(e,t){if(!e.length)return[];var n=buildAbsoluteTopHash(t);return e.map((function(e){return{seg:e,isVisible:!0,isAbsolute:!0,absoluteTop:n[e.eventRange.instance.instanceId],marginTop:0}}))}function buildAbsoluteTopHash(e){for(var t={},n=0,r=e;n<r.length;n++)for(var o=0,i=r[n];o<i.length;o++){var a=i[o];t[a.seg.eventRange.instance.instanceId]=a.absoluteTop}return t}TableRow.addStateEquality({eventInstanceHeights:isPropsEqual});var Table=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.splitBusinessHourSegs=memoize(splitSegsByRow),t.splitBgEventSegs=memoize(splitSegsByRow),t.splitFgEventSegs=memoize(splitSegsByRow),t.splitDateSelectionSegs=memoize(splitSegsByRow),t.splitEventDrag=memoize(splitInteractionByRow),t.splitEventResize=memoize(splitInteractionByRow),t.rowRefs=new RefMap,t.handleRootEl=function(e){t.rootEl=e,e?t.context.registerInteractiveComponent(t,{el:e,isHitComboAllowed:t.props.isHitComboAllowed}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.dateProfile,r=t.dayMaxEventRows,o=t.dayMaxEvents,i=t.expandRows,a=t.cells.length,s=this.splitBusinessHourSegs(t.businessHourSegs,a),l=this.splitBgEventSegs(t.bgEventSegs,a),u=this.splitFgEventSegs(t.fgEventSegs,a),c=this.splitDateSelectionSegs(t.dateSelectionSegs,a),d=this.splitEventDrag(t.eventDrag,a),p=this.splitEventResize(t.eventResize,a),f=!0===o||!0===r;return f&&!i&&(f=!1,r=null,o=null),createElement("div",{className:["fc-daygrid-body",f?"fc-daygrid-body-balanced":"fc-daygrid-body-unbalanced",i?"":"fc-daygrid-body-natural"].join(" "),ref:this.handleRootEl,style:{width:t.clientWidth,minWidth:t.tableMinWidth}},createElement(NowTimer,{unit:"day"},(function(f,h){return createElement(Fragment,null,createElement("table",{role:"presentation",className:"fc-scrollgrid-sync-table",style:{width:t.clientWidth,minWidth:t.tableMinWidth,height:i?t.clientHeight:""}},t.colGroupNode,createElement("tbody",{role:"presentation"},t.cells.map((function(i,f){return createElement(TableRow,{ref:e.rowRefs.createRef(f),key:i.length?i[0].date.toISOString():f,showDayNumbers:a>1,showWeekNumbers:t.showWeekNumbers,todayRange:h,dateProfile:n,cells:i,renderIntro:t.renderRowIntro,businessHourSegs:s[f],eventSelection:t.eventSelection,bgEventSegs:l[f].filter(isSegAllDay),fgEventSegs:u[f],dateSelectionSegs:c[f],eventDrag:d[f],eventResize:p[f],dayMaxEvents:o,dayMaxEventRows:r,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:t.forPrint})})))))})))},t.prototype.prepareHits=function(){this.rowPositions=new PositionCache(this.rootEl,this.rowRefs.collect().map((function(e){return e.getCellEls()[0]})),!1,!0),this.colPositions=new PositionCache(this.rootEl,this.rowRefs.currentMap[0].getCellEls(),!0,!1)},t.prototype.queryHit=function(e,t){var n=this.colPositions,r=this.rowPositions,o=n.leftToIndex(e),i=r.topToIndex(t);if(null!=i&&null!=o){var a=this.props.cells[i][o];return{dateProfile:this.props.dateProfile,dateSpan:__assign$1({range:this.getCellRange(i,o),allDay:!0},a.extraDateSpan),dayEl:this.getCellEl(i,o),rect:{left:n.lefts[o],right:n.rights[o],top:r.tops[i],bottom:r.bottoms[i]},layer:0}}return null},t.prototype.getCellEl=function(e,t){return this.rowRefs.currentMap[e].getCellEls()[t]},t.prototype.getCellRange=function(e,t){var n=this.props.cells[e][t].date;return{start:n,end:addDays(n,1)}},t}(DateComponent);function isSegAllDay(e){return e.eventRange.def.allDay}var DayTableSlicer=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.forceDayIfListItem=!0,t}return __extends(t,e),t.prototype.sliceRange=function(e,t){return t.sliceRange(e)},t}(Slicer),DayTable=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.slicer=new DayTableSlicer,t.tableRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context;return createElement(Table,__assign$1({ref:this.tableRef},this.slicer.sliceProps(e,e.dateProfile,e.nextDayThreshold,t,e.dayTableModel),{dateProfile:e.dateProfile,cells:e.dayTableModel.cells,colGroupNode:e.colGroupNode,tableMinWidth:e.tableMinWidth,renderRowIntro:e.renderRowIntro,dayMaxEvents:e.dayMaxEvents,dayMaxEventRows:e.dayMaxEventRows,showWeekNumbers:e.showWeekNumbers,expandRows:e.expandRows,headerAlignElRef:e.headerAlignElRef,clientWidth:e.clientWidth,clientHeight:e.clientHeight,forPrint:e.forPrint}))},t}(DateComponent),DayTableView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildDayTableModel=memoize(buildDayTableModel),t.headerRef=createRef(),t.tableRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.context,n=t.options,r=t.dateProfileGenerator,o=this.props,i=this.buildDayTableModel(o.dateProfile,r),a=n.dayHeaders&&createElement(DayHeader,{ref:this.headerRef,dateProfile:o.dateProfile,dates:i.headerDates,datesRepDistinctDays:1===i.rowCnt}),s=function(t){return createElement(DayTable,{ref:e.tableRef,dateProfile:o.dateProfile,dayTableModel:i,businessHours:o.businessHours,dateSelection:o.dateSelection,eventStore:o.eventStore,eventUiBases:o.eventUiBases,eventSelection:o.eventSelection,eventDrag:o.eventDrag,eventResize:o.eventResize,nextDayThreshold:n.nextDayThreshold,colGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,dayMaxEvents:n.dayMaxEvents,dayMaxEventRows:n.dayMaxEventRows,showWeekNumbers:n.weekNumbers,expandRows:!o.isHeightAuto,headerAlignElRef:e.headerElRef,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:o.forPrint})};return n.dayMinWidth?this.renderHScrollLayout(a,s,i.colCnt,n.dayMinWidth):this.renderSimpleLayout(a,s)},t}(TableView);function buildDayTableModel(e,t){var n=new DaySeriesModel(e.renderRange,t);return new DayTableModel(n,/year|month|week/.test(e.currentRangeUnit))}var TableDateProfileGenerator=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.buildRenderRange=function(t,n,r){var o,i=this.props.dateEnv,a=e.prototype.buildRenderRange.call(this,t,n,r),s=a.start,l=a.end;(/^(year|month)$/.test(n)&&(s=i.startOfWeek(s),(o=i.startOfWeek(l)).valueOf()!==l.valueOf()&&(l=addWeeks(o,1))),this.props.monthMode&&this.props.fixedWeekCount)&&(l=addWeeks(l,6-Math.ceil(diffWeeks(s,l))));return{start:s,end:l}},t}(DateProfileGenerator),main$3=createPlugin({initialView:"dayGridMonth",views:{dayGrid:{component:DayTableView,dateProfileGeneratorClass:TableDateProfileGenerator},dayGridDay:{type:"dayGrid",duration:{days:1}},dayGridWeek:{type:"dayGrid",duration:{weeks:1}},dayGridMonth:{type:"dayGrid",duration:{months:1},monthMode:!0,fixedWeekCount:!0}}}),AllDaySplitter=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.getKeyInfo=function(){return{allDay:{},timed:{}}},t.prototype.getKeysForDateSpan=function(e){return e.allDay?["allDay"]:["timed"]},t.prototype.getKeysForEventDef=function(e){return e.allDay?hasBgRendering(e)?["timed","allDay"]:["allDay"]:["timed"]},t}(Splitter),DEFAULT_SLAT_LABEL_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"short"});function TimeColsAxisCell(e){var t=["fc-timegrid-slot","fc-timegrid-slot-label",e.isLabeled?"fc-scrollgrid-shrink":"fc-timegrid-slot-minor"];return createElement(ViewContextType.Consumer,null,(function(n){if(!e.isLabeled)return createElement("td",{className:t.join(" "),"data-time":e.isoTimeStr});var r=n.dateEnv,o=n.options,i=n.viewApi,a=null==o.slotLabelFormat?DEFAULT_SLAT_LABEL_FORMAT:Array.isArray(o.slotLabelFormat)?createFormatter(o.slotLabelFormat[0]):createFormatter(o.slotLabelFormat),s={level:0,time:e.time,date:r.toDate(e.date),view:i,text:r.format(e.date,a)};return createElement(RenderHook,{hookProps:s,classNames:o.slotLabelClassNames,content:o.slotLabelContent,defaultContent:renderInnerContent$1,didMount:o.slotLabelDidMount,willUnmount:o.slotLabelWillUnmount},(function(n,r,o,i){return createElement("td",{ref:n,className:t.concat(r).join(" "),"data-time":e.isoTimeStr},createElement("div",{className:"fc-timegrid-slot-label-frame fc-scrollgrid-shrink-frame"},createElement("div",{className:"fc-timegrid-slot-label-cushion fc-scrollgrid-shrink-cushion",ref:o},i)))}))}))}function renderInnerContent$1(e){return e.text}var TimeBodyAxis=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){return this.props.slatMetas.map((function(e){return createElement("tr",{key:e.key},createElement(TimeColsAxisCell,__assign$1({},e)))}))},t}(BaseComponent),DEFAULT_WEEK_NUM_FORMAT=createFormatter({week:"short"}),AUTO_ALL_DAY_MAX_EVENT_ROWS=5,TimeColsView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.allDaySplitter=new AllDaySplitter,t.headerElRef=createRef(),t.rootElRef=createRef(),t.scrollerElRef=createRef(),t.state={slatCoords:null},t.handleScrollTopRequest=function(e){var n=t.scrollerElRef.current;n&&(n.scrollTop=e)},t.renderHeadAxis=function(e,n){void 0===n&&(n="");var r=t.context.options,o=t.props.dateProfile.renderRange,i=1===diffDays(o.start,o.end)?buildNavLinkAttrs(t.context,o.start,"week"):{};return r.weekNumbers&&"day"===e?createElement(WeekNumberRoot,{date:o.start,defaultFormat:DEFAULT_WEEK_NUM_FORMAT},(function(e,t,r,o){return createElement("th",{ref:e,"aria-hidden":!0,className:["fc-timegrid-axis","fc-scrollgrid-shrink"].concat(t).join(" ")},createElement("div",{className:"fc-timegrid-axis-frame fc-scrollgrid-shrink-frame fc-timegrid-axis-frame-liquid",style:{height:n}},createElement("a",__assign$1({ref:r,className:"fc-timegrid-axis-cushion fc-scrollgrid-shrink-cushion fc-scrollgrid-sync-inner"},i),o)))})):createElement("th",{"aria-hidden":!0,className:"fc-timegrid-axis"},createElement("div",{className:"fc-timegrid-axis-frame",style:{height:n}}))},t.renderTableRowAxis=function(e){var n=t.context,r=n.options,o=n.viewApi,i={text:r.allDayText,view:o};return createElement(RenderHook,{hookProps:i,classNames:r.allDayClassNames,content:r.allDayContent,defaultContent:renderAllDayInner$1,didMount:r.allDayDidMount,willUnmount:r.allDayWillUnmount},(function(t,n,r,o){return createElement("td",{ref:t,"aria-hidden":!0,className:["fc-timegrid-axis","fc-scrollgrid-shrink"].concat(n).join(" ")},createElement("div",{className:"fc-timegrid-axis-frame fc-scrollgrid-shrink-frame"+(null==e?" fc-timegrid-axis-frame-liquid":""),style:{height:e}},createElement("span",{className:"fc-timegrid-axis-cushion fc-scrollgrid-shrink-cushion fc-scrollgrid-sync-inner",ref:r},o)))}))},t.handleSlatCoords=function(e){t.setState({slatCoords:e})},t}return __extends(t,e),t.prototype.renderSimpleLayout=function(e,t,n){var r=this.context,o=this.props,i=[],a=getStickyHeaderDates(r.options);return e&&i.push({type:"header",key:"header",isSticky:a,chunk:{elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}}),t&&(i.push({type:"body",key:"all-day",chunk:{content:t}}),i.push({type:"body",key:"all-day-divider",outerContent:createElement("tr",{role:"presentation",className:"fc-scrollgrid-section"},createElement("td",{className:"fc-timegrid-divider "+r.theme.getClass("tableCellShaded")}))})),i.push({type:"body",key:"body",liquid:!0,expandRows:Boolean(r.options.expandRows),chunk:{scrollerElRef:this.scrollerElRef,content:n}}),createElement(ViewRoot,{viewSpec:r.viewSpec,elRef:this.rootElRef},(function(e,t){return createElement("div",{className:["fc-timegrid"].concat(t).join(" "),ref:e},createElement(SimpleScrollGrid,{liquid:!o.isHeightAuto&&!o.forPrint,collapsibleWidth:o.forPrint,cols:[{width:"shrink"}],sections:i}))}))},t.prototype.renderHScrollLayout=function(e,t,n,r,o,i,a){var s=this,l=this.context.pluginHooks.scrollGridImpl;if(!l)throw new Error("No ScrollGrid implementation");var u=this.context,c=this.props,d=!c.forPrint&&getStickyHeaderDates(u.options),p=!c.forPrint&&getStickyFooterScrollbar(u.options),f=[];e&&f.push({type:"header",key:"header",isSticky:d,syncRowHeights:!0,chunks:[{key:"axis",rowContent:function(e){return createElement("tr",{role:"presentation"},s.renderHeadAxis("day",e.rowSyncHeights[0]))}},{key:"cols",elRef:this.headerElRef,tableClassName:"fc-col-header",rowContent:e}]}),t&&(f.push({type:"body",key:"all-day",syncRowHeights:!0,chunks:[{key:"axis",rowContent:function(e){return createElement("tr",{role:"presentation"},s.renderTableRowAxis(e.rowSyncHeights[0]))}},{key:"cols",content:t}]}),f.push({key:"all-day-divider",type:"body",outerContent:createElement("tr",{role:"presentation",className:"fc-scrollgrid-section"},createElement("td",{colSpan:2,className:"fc-timegrid-divider "+u.theme.getClass("tableCellShaded")}))}));var h=u.options.nowIndicator;return f.push({type:"body",key:"body",liquid:!0,expandRows:Boolean(u.options.expandRows),chunks:[{key:"axis",content:function(e){return createElement("div",{className:"fc-timegrid-axis-chunk"},createElement("table",{"aria-hidden":!0,style:{height:e.expandRows?e.clientHeight:""}},e.tableColGroupNode,createElement("tbody",null,createElement(TimeBodyAxis,{slatMetas:i}))),createElement("div",{className:"fc-timegrid-now-indicator-container"},createElement(NowTimer,{unit:h?"minute":"day"},(function(e){var t=h&&a&&a.safeComputeTop(e);return"number"==typeof t?createElement(NowIndicatorRoot,{isAxis:!0,date:e},(function(e,n,r,o){return createElement("div",{ref:e,className:["fc-timegrid-now-indicator-arrow"].concat(n).join(" "),style:{top:t}},o)})):null}))))}},{key:"cols",scrollerElRef:this.scrollerElRef,content:n}]}),p&&f.push({key:"footer",type:"footer",isSticky:!0,chunks:[{key:"axis",content:renderScrollShim},{key:"cols",content:renderScrollShim}]}),createElement(ViewRoot,{viewSpec:u.viewSpec,elRef:this.rootElRef},(function(e,t){return createElement("div",{className:["fc-timegrid"].concat(t).join(" "),ref:e},createElement(l,{liquid:!c.isHeightAuto&&!c.forPrint,collapsibleWidth:!1,colGroups:[{width:"shrink",cols:[{width:"shrink"}]},{cols:[{span:r,minWidth:o}]}],sections:f}))}))},t.prototype.getAllDayMaxEventProps=function(){var e=this.context.options,t=e.dayMaxEvents,n=e.dayMaxEventRows;return!0!==t&&!0!==n||(t=void 0,n=AUTO_ALL_DAY_MAX_EVENT_ROWS),{dayMaxEvents:t,dayMaxEventRows:n}},t}(DateComponent);function renderAllDayInner$1(e){return e.text}var TimeColsSlatsCoords=function(){function e(e,t,n){this.positions=e,this.dateProfile=t,this.slotDuration=n}return e.prototype.safeComputeTop=function(e){var t=this.dateProfile;if(rangeContainsMarker(t.currentRange,e)){var n=startOfDay(e),r=e.valueOf()-n.valueOf();if(r>=asRoughMs(t.slotMinTime)&&r<asRoughMs(t.slotMaxTime))return this.computeTimeTop(createDuration(r))}return null},e.prototype.computeDateTop=function(e,t){return t||(t=startOfDay(e)),this.computeTimeTop(createDuration(e.valueOf()-t.valueOf()))},e.prototype.computeTimeTop=function(e){var t,n,r=this.positions,o=this.dateProfile,i=r.els.length,a=(e.milliseconds-asRoughMs(o.slotMinTime))/asRoughMs(this.slotDuration);return a=Math.max(0,a),a=Math.min(i,a),t=Math.floor(a),n=a-(t=Math.min(t,i-1)),r.tops[t]+r.getHeight(t)*n},e}(),TimeColsSlatsBody=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=t.options,r=e.slatElRefs;return createElement("tbody",null,e.slatMetas.map((function(o,i){var a={time:o.time,date:t.dateEnv.toDate(o.date),view:t.viewApi},s=["fc-timegrid-slot","fc-timegrid-slot-lane",o.isLabeled?"":"fc-timegrid-slot-minor"];return createElement("tr",{key:o.key,ref:r.createRef(o.key)},e.axis&&createElement(TimeColsAxisCell,__assign$1({},o)),createElement(RenderHook,{hookProps:a,classNames:n.slotLaneClassNames,content:n.slotLaneContent,didMount:n.slotLaneDidMount,willUnmount:n.slotLaneWillUnmount},(function(e,t,n,r){return createElement("td",{ref:e,className:s.concat(t).join(" "),"data-time":o.isoTimeStr},r)})))})))},t}(BaseComponent),TimeColsSlats=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t.slatElRefs=new RefMap,t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context;return createElement("div",{ref:this.rootElRef,className:"fc-timegrid-slots"},createElement("table",{"aria-hidden":!0,className:t.theme.getClass("table"),style:{minWidth:e.tableMinWidth,width:e.clientWidth,height:e.minHeight}},e.tableColGroupNode,createElement(TimeColsSlatsBody,{slatElRefs:this.slatElRefs,axis:e.axis,slatMetas:e.slatMetas})))},t.prototype.componentDidMount=function(){this.updateSizing()},t.prototype.componentDidUpdate=function(){this.updateSizing()},t.prototype.componentWillUnmount=function(){this.props.onCoords&&this.props.onCoords(null)},t.prototype.updateSizing=function(){var e=this.context,t=this.props;t.onCoords&&null!==t.clientWidth&&(this.rootElRef.current.offsetHeight&&t.onCoords(new TimeColsSlatsCoords(new PositionCache(this.rootElRef.current,collectSlatEls(this.slatElRefs.currentMap,t.slatMetas),!1,!0),this.props.dateProfile,e.options.slotDuration)))},t}(BaseComponent);function collectSlatEls(e,t){return t.map((function(t){return e[t.key]}))}function splitSegsByCol(e,t){var n,r=[];for(n=0;n<t;n+=1)r.push([]);if(e)for(n=0;n<e.length;n+=1)r[e[n].col].push(e[n]);return r}function splitInteractionByCol(e,t){var n=[];if(e){for(a=0;a<t;a+=1)n[a]={affectedInstances:e.affectedInstances,isEvent:e.isEvent,segs:[]};for(var r=0,o=e.segs;r<o.length;r++){var i=o[r];n[i.col].segs.push(i)}}else for(var a=0;a<t;a+=1)n[a]=null;return n}var TimeColMoreLink=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.rootElRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props;return createElement(MoreLinkRoot,{allDayDate:null,moreCnt:t.hiddenSegs.length,allSegs:t.hiddenSegs,hiddenSegs:t.hiddenSegs,alignmentElRef:this.rootElRef,defaultContent:renderMoreLinkInner,extraDateSpan:t.extraDateSpan,dateProfile:t.dateProfile,todayRange:t.todayRange,popoverContent:function(){return renderPlainFgSegs(t.hiddenSegs,t)}},(function(n,r,o,i,a,s,l,u){return createElement("a",{ref:function(t){setRef(n,t),setRef(e.rootElRef,t)},className:["fc-timegrid-more-link"].concat(r).join(" "),style:{top:t.top,bottom:t.bottom},onClick:a,title:s,"aria-expanded":l,"aria-controls":u},createElement("div",{ref:o,className:"fc-timegrid-more-link-inner fc-sticky"},i))}))},t}(BaseComponent);function renderMoreLinkInner(e){return e.shortText}function buildPositioning(e,t,n){var r=new SegHierarchy;null!=t&&(r.strictOrder=t),null!=n&&(r.maxStackCnt=n);var o=groupIntersectingEntries(r.addSegs(e)),i=buildWeb(r);return{segRects:webToRects(i=stretchWeb(i,1)),hiddenGroups:o}}function buildWeb(e){var t=e.entriesByLevel,n=cacheable((function(e,t){return e+":"+t}),(function(r,o){var i=buildNodes(findNextLevelSegs(e,r,o),n),a=t[r][o];return[__assign$1(__assign$1({},a),{nextLevelNodes:i[0]}),a.thickness+i[1]]}));return buildNodes(t.length?{level:0,lateralStart:0,lateralEnd:t[0].length}:null,n)[0]}function buildNodes(e,t){if(!e)return[[],0];for(var n=e.level,r=e.lateralStart,o=e.lateralEnd,i=r,a=[];i<o;)a.push(t(n,i)),i+=1;return a.sort(cmpDescPressures),[a.map(extractNode),a[0][1]]}function cmpDescPressures(e,t){return t[1]-e[1]}function extractNode(e){return e[0]}function findNextLevelSegs(e,t,n){for(var r=e.levelCoords,o=e.entriesByLevel,i=o[t][n],a=r[t]+i.thickness,s=r.length,l=t;l<s&&r[l]<a;l+=1);for(;l<s;l+=1){for(var u=o[l],c=void 0,d=binarySearch(u,i.span.start,getEntrySpanEnd),p=d[0]+d[1],f=p;(c=u[f])&&c.span.start<i.span.end;)f+=1;if(p<f)return{level:l,lateralStart:p,lateralEnd:f}}return null}function stretchWeb(e,t){var n=cacheable((function(e,t,n){return buildEntryKey(e)}),(function(e,r,o){var i,a=e.nextLevelNodes,s=e.thickness,l=s+o,u=s/l,c=[];if(a.length)for(var d=0,p=a;d<p.length;d++){var f=p[d];if(void 0===i){i=(h=n(f,r,l))[0],c.push(h[1])}else{var h=n(f,i,0);c.push(h[1])}}else i=t;var g=(i-r)*u;return[i-g,__assign$1(__assign$1({},e),{thickness:g,nextLevelNodes:c})]}));return e.map((function(e){return n(e,0,0)[1]}))}function webToRects(e){var t=[],n=cacheable((function(e,t,n){return buildEntryKey(e)}),(function(e,n,o){var i=__assign$1(__assign$1({},e),{levelCoord:n,stackDepth:o,stackForward:0});return t.push(i),i.stackForward=r(e.nextLevelNodes,n+e.thickness,o+1)+1}));function r(e,t,r){for(var o=0,i=0,a=e;i<a.length;i++){var s=a[i];o=Math.max(n(s,t,r),o)}return o}return r(e,0,0),t}function cacheable(e,t){var n={};return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=e.apply(void 0,r);return i in n?n[i]:n[i]=t.apply(void 0,r)}}function computeSegVCoords(e,t,n,r){void 0===n&&(n=null),void 0===r&&(r=0);var o=[];if(n)for(var i=0;i<e.length;i+=1){var a=e[i],s=n.computeDateTop(a.start,t),l=Math.max(s+(r||0),n.computeDateTop(a.end,t));o.push({start:Math.round(s),end:Math.round(l)})}return o}function computeFgSegPlacements(e,t,n,r){for(var o=[],i=[],a=0;a<e.length;a+=1){var s=t[a];s?o.push({index:a,thickness:1,span:s}):i.push(e[a])}for(var l=buildPositioning(o,n,r),u=l.segRects,c=l.hiddenGroups,d=[],p=0,f=u;p<f.length;p++){var h=f[p];d.push({seg:e[h.index],rect:h})}for(var g=0,m=i;g<m.length;g++){var v=m[g];d.push({seg:v,rect:null})}return{segPlacements:d,hiddenGroups:c}}var DEFAULT_TIME_FORMAT$1=createFormatter({hour:"numeric",minute:"2-digit",meridiem:!1}),TimeColEvent=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=["fc-timegrid-event","fc-v-event"];return this.props.isShort&&e.push("fc-timegrid-event-short"),createElement(StandardEvent,__assign$1({},this.props,{defaultTimeFormat:DEFAULT_TIME_FORMAT$1,extraClassNames:e}))},t}(BaseComponent),TimeColMisc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props;return createElement(DayCellContent,{date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,extraHookProps:e.extraHookProps},(function(e,t){return t&&createElement("div",{className:"fc-timegrid-col-misc",ref:e},t)}))},t}(BaseComponent),TimeCol=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.sortEventSegs=memoize(sortEventSegs),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=n.options.selectMirror,o=t.eventDrag&&t.eventDrag.segs||t.eventResize&&t.eventResize.segs||r&&t.dateSelectionSegs||[],i=t.eventDrag&&t.eventDrag.affectedInstances||t.eventResize&&t.eventResize.affectedInstances||{},a=this.sortEventSegs(t.fgEventSegs,n.options.eventOrder);return createElement(DayCellRoot,{elRef:t.elRef,date:t.date,dateProfile:t.dateProfile,todayRange:t.todayRange,extraHookProps:t.extraHookProps},(function(n,s,l){return createElement("td",__assign$1({ref:n,role:"gridcell",className:["fc-timegrid-col"].concat(s,t.extraClassNames||[]).join(" ")},l,t.extraDataAttrs),createElement("div",{className:"fc-timegrid-col-frame"},createElement("div",{className:"fc-timegrid-col-bg"},e.renderFillSegs(t.businessHourSegs,"non-business"),e.renderFillSegs(t.bgEventSegs,"bg-event"),e.renderFillSegs(t.dateSelectionSegs,"highlight")),createElement("div",{className:"fc-timegrid-col-events"},e.renderFgSegs(a,i,!1,!1,!1)),createElement("div",{className:"fc-timegrid-col-events"},e.renderFgSegs(o,{},Boolean(t.eventDrag),Boolean(t.eventResize),Boolean(r))),createElement("div",{className:"fc-timegrid-now-indicator-container"},e.renderNowIndicator(t.nowIndicatorSegs)),createElement(TimeColMisc,{date:t.date,dateProfile:t.dateProfile,todayRange:t.todayRange,extraHookProps:t.extraHookProps})))}))},t.prototype.renderFgSegs=function(e,t,n,r,o){var i=this.props;return i.forPrint?renderPlainFgSegs(e,i):this.renderPositionedFgSegs(e,t,n,r,o)},t.prototype.renderPositionedFgSegs=function(e,t,n,r,o){var i=this,a=this.context.options,s=a.eventMaxStack,l=a.eventShortHeight,u=a.eventOrderStrict,c=a.eventMinHeight,d=this.props,p=d.date,f=d.slatCoords,h=d.eventSelection,g=d.todayRange,m=d.nowDate,v=n||r||o,y=computeFgSegPlacements(e,computeSegVCoords(e,p,f,c),u,s),E=y.segPlacements,S=y.hiddenGroups;return createElement(Fragment,null,this.renderHiddenGroups(S,e),E.map((function(e){var a=e.seg,s=e.rect,u=a.eventRange.instance.instanceId,c=v||Boolean(!t[u]&&s),d=computeSegVStyle(s&&s.span),p=!v&&s?i.computeSegHStyle(s):{left:0,right:0},f=Boolean(s)&&s.stackForward>0,y=Boolean(s)&&s.span.end-s.span.start<l;return createElement("div",{className:"fc-timegrid-event-harness"+(f?" fc-timegrid-event-harness-inset":""),key:u,style:__assign$1(__assign$1({visibility:c?"":"hidden"},d),p)},createElement(TimeColEvent,__assign$1({seg:a,isDragging:n,isResizing:r,isDateSelecting:o,isSelected:u===h,isShort:y},getSegMeta(a,g,m))))})))},t.prototype.renderHiddenGroups=function(e,t){var n=this.props,r=n.extraDateSpan,o=n.dateProfile,i=n.todayRange,a=n.nowDate,s=n.eventSelection,l=n.eventDrag,u=n.eventResize;return createElement(Fragment,null,e.map((function(e){var n=computeSegVStyle(e.span),c=compileSegsFromEntries(e.entries,t);return createElement(TimeColMoreLink,{key:buildIsoString(computeEarliestSegStart(c)),hiddenSegs:c,top:n.top,bottom:n.bottom,extraDateSpan:r,dateProfile:o,todayRange:i,nowDate:a,eventSelection:s,eventDrag:l,eventResize:u})})))},t.prototype.renderFillSegs=function(e,t){var n=this.props,r=this.context,o=computeSegVCoords(e,n.date,n.slatCoords,r.options.eventMinHeight).map((function(r,o){var i=e[o];return createElement("div",{key:buildEventRangeKey(i.eventRange),className:"fc-timegrid-bg-harness",style:computeSegVStyle(r)},"bg-event"===t?createElement(BgEvent,__assign$1({seg:i},getSegMeta(i,n.todayRange,n.nowDate))):renderFill(t))}));return createElement(Fragment,null,o)},t.prototype.renderNowIndicator=function(e){var t=this.props,n=t.slatCoords,r=t.date;return n?e.map((function(e,t){return createElement(NowIndicatorRoot,{isAxis:!1,date:r,key:t},(function(t,o,i,a){return createElement("div",{ref:t,className:["fc-timegrid-now-indicator-line"].concat(o).join(" "),style:{top:n.computeDateTop(e.start,r)}},a)}))})):null},t.prototype.computeSegHStyle=function(e){var t,n,r=this.context,o=r.isRtl,i=r.options.slotEventOverlap,a=e.levelCoord,s=e.levelCoord+e.thickness;i&&(s=Math.min(1,a+2*(s-a))),o?(t=1-s,n=a):(t=a,n=1-s);var l={zIndex:e.stackDepth+1,left:100*t+"%",right:100*n+"%"};return i&&!e.stackForward&&(l[o?"marginLeft":"marginRight"]=20),l},t}(BaseComponent);function renderPlainFgSegs(e,t){var n=t.todayRange,r=t.nowDate,o=t.eventSelection,i=t.eventDrag,a=t.eventResize,s=(i?i.affectedInstances:null)||(a?a.affectedInstances:null)||{};return createElement(Fragment,null,e.map((function(e){var t=e.eventRange.instance.instanceId;return createElement("div",{key:t,style:{visibility:s[t]?"hidden":""}},createElement(TimeColEvent,__assign$1({seg:e,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:t===o,isShort:!1},getSegMeta(e,n,r))))})))}function computeSegVStyle(e){return e?{top:e.start,bottom:-e.end}:{top:"",bottom:""}}function compileSegsFromEntries(e,t){return e.map((function(e){return t[e.index]}))}var TimeColsContent=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.splitFgEventSegs=memoize(splitSegsByCol),t.splitBgEventSegs=memoize(splitSegsByCol),t.splitBusinessHourSegs=memoize(splitSegsByCol),t.splitNowIndicatorSegs=memoize(splitSegsByCol),t.splitDateSelectionSegs=memoize(splitSegsByCol),t.splitEventDrag=memoize(splitInteractionByCol),t.splitEventResize=memoize(splitInteractionByCol),t.rootElRef=createRef(),t.cellElRefs=new RefMap,t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context.options.nowIndicator&&t.slatCoords&&t.slatCoords.safeComputeTop(t.nowDate),r=t.cells.length,o=this.splitFgEventSegs(t.fgEventSegs,r),i=this.splitBgEventSegs(t.bgEventSegs,r),a=this.splitBusinessHourSegs(t.businessHourSegs,r),s=this.splitNowIndicatorSegs(t.nowIndicatorSegs,r),l=this.splitDateSelectionSegs(t.dateSelectionSegs,r),u=this.splitEventDrag(t.eventDrag,r),c=this.splitEventResize(t.eventResize,r);return createElement("div",{className:"fc-timegrid-cols",ref:this.rootElRef},createElement("table",{role:"presentation",style:{minWidth:t.tableMinWidth,width:t.clientWidth}},t.tableColGroupNode,createElement("tbody",{role:"presentation"},createElement("tr",{role:"row"},t.axis&&createElement("td",{"aria-hidden":!0,className:"fc-timegrid-col fc-timegrid-axis"},createElement("div",{className:"fc-timegrid-col-frame"},createElement("div",{className:"fc-timegrid-now-indicator-container"},"number"==typeof n&&createElement(NowIndicatorRoot,{isAxis:!0,date:t.nowDate},(function(e,t,r,o){return createElement("div",{ref:e,className:["fc-timegrid-now-indicator-arrow"].concat(t).join(" "),style:{top:n}},o)}))))),t.cells.map((function(n,r){return createElement(TimeCol,{key:n.key,elRef:e.cellElRefs.createRef(n.key),dateProfile:t.dateProfile,date:n.date,nowDate:t.nowDate,todayRange:t.todayRange,extraHookProps:n.extraHookProps,extraDataAttrs:n.extraDataAttrs,extraClassNames:n.extraClassNames,extraDateSpan:n.extraDateSpan,fgEventSegs:o[r],bgEventSegs:i[r],businessHourSegs:a[r],nowIndicatorSegs:s[r],dateSelectionSegs:l[r],eventDrag:u[r],eventResize:c[r],slatCoords:t.slatCoords,eventSelection:t.eventSelection,forPrint:t.forPrint})}))))))},t.prototype.componentDidMount=function(){this.updateCoords()},t.prototype.componentDidUpdate=function(){this.updateCoords()},t.prototype.updateCoords=function(){var e=this.props;e.onColCoords&&null!==e.clientWidth&&e.onColCoords(new PositionCache(this.rootElRef.current,collectCellEls(this.cellElRefs.currentMap,e.cells),!0,!1))},t}(BaseComponent);function collectCellEls(e,t){return t.map((function(t){return e[t.key]}))}var TimeCols=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.processSlotOptions=memoize(processSlotOptions),t.state={slatCoords:null},t.handleRootEl=function(e){e?t.context.registerInteractiveComponent(t,{el:e,isHitComboAllowed:t.props.isHitComboAllowed}):t.context.unregisterInteractiveComponent(t)},t.handleScrollRequest=function(e){var n=t.props.onScrollTopRequest,r=t.state.slatCoords;if(n&&r){if(e.time){var o=r.computeTimeTop(e.time);(o=Math.ceil(o))&&(o+=1),n(o)}return!0}return!1},t.handleColCoords=function(e){t.colCoords=e},t.handleSlatCoords=function(e){t.setState({slatCoords:e}),t.props.onSlatCoords&&t.props.onSlatCoords(e)},t}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.state;return createElement("div",{className:"fc-timegrid-body",ref:this.handleRootEl,style:{width:e.clientWidth,minWidth:e.tableMinWidth}},createElement(TimeColsSlats,{axis:e.axis,dateProfile:e.dateProfile,slatMetas:e.slatMetas,clientWidth:e.clientWidth,minHeight:e.expandRows?e.clientHeight:"",tableMinWidth:e.tableMinWidth,tableColGroupNode:e.axis?e.tableColGroupNode:null,onCoords:this.handleSlatCoords}),createElement(TimeColsContent,{cells:e.cells,axis:e.axis,dateProfile:e.dateProfile,businessHourSegs:e.businessHourSegs,bgEventSegs:e.bgEventSegs,fgEventSegs:e.fgEventSegs,dateSelectionSegs:e.dateSelectionSegs,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,todayRange:e.todayRange,nowDate:e.nowDate,nowIndicatorSegs:e.nowIndicatorSegs,clientWidth:e.clientWidth,tableMinWidth:e.tableMinWidth,tableColGroupNode:e.tableColGroupNode,slatCoords:t.slatCoords,onColCoords:this.handleColCoords,forPrint:e.forPrint}))},t.prototype.componentDidMount=function(){this.scrollResponder=this.context.createScrollResponder(this.handleScrollRequest)},t.prototype.componentDidUpdate=function(e){this.scrollResponder.update(e.dateProfile!==this.props.dateProfile)},t.prototype.componentWillUnmount=function(){this.scrollResponder.detach()},t.prototype.queryHit=function(e,t){var n=this.context,r=n.dateEnv,o=n.options,i=this.colCoords,a=this.props.dateProfile,s=this.state.slatCoords,l=this.processSlotOptions(this.props.slotDuration,o.snapDuration),u=l.snapDuration,c=l.snapsPerSlot,d=i.leftToIndex(e),p=s.positions.topToIndex(t);if(null!=d&&null!=p){var f=this.props.cells[d],h=s.positions.tops[p],g=s.positions.getHeight(p),m=(t-h)/g,v=p*c+Math.floor(m*c),y=this.props.cells[d].date,E=addDurations(a.slotMinTime,multiplyDuration(u,v)),S=r.add(y,E),D=r.add(S,u);return{dateProfile:a,dateSpan:__assign$1({range:{start:S,end:D},allDay:!1},f.extraDateSpan),dayEl:i.els[d],rect:{left:i.lefts[d],right:i.rights[d],top:h,bottom:h+g},layer:0}}return null},t}(DateComponent);function processSlotOptions(e,t){var n=t||e,r=wholeDivideDurations(e,n);return null===r&&(n=e,r=1),{snapDuration:n,snapsPerSlot:r}}var DayTimeColsSlicer=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.sliceRange=function(e,t){for(var n=[],r=0;r<t.length;r+=1){var o=intersectRanges(e,t[r]);o&&n.push({start:o.start,end:o.end,isStart:o.start.valueOf()===e.start.valueOf(),isEnd:o.end.valueOf()===e.end.valueOf(),col:r})}return n},t}(Slicer),DayTimeCols=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildDayRanges=memoize(buildDayRanges),t.slicer=new DayTimeColsSlicer,t.timeColsRef=createRef(),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=t.dateProfile,o=t.dayTableModel,i=n.options.nowIndicator,a=this.buildDayRanges(o,r,n.dateEnv);return createElement(NowTimer,{unit:i?"minute":"day"},(function(s,l){return createElement(TimeCols,__assign$1({ref:e.timeColsRef},e.slicer.sliceProps(t,r,null,n,a),{forPrint:t.forPrint,axis:t.axis,dateProfile:r,slatMetas:t.slatMetas,slotDuration:t.slotDuration,cells:o.cells[0],tableColGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,clientWidth:t.clientWidth,clientHeight:t.clientHeight,expandRows:t.expandRows,nowDate:s,nowIndicatorSegs:i&&e.slicer.sliceNowDate(s,n,a),todayRange:l,onScrollTopRequest:t.onScrollTopRequest,onSlatCoords:t.onSlatCoords}))}))},t}(DateComponent);function buildDayRanges(e,t,n){for(var r=[],o=0,i=e.headerDates;o<i.length;o++){var a=i[o];r.push({start:n.add(a,t.slotMinTime),end:n.add(a,t.slotMaxTime)})}return r}var STOCK_SUB_DURATIONS=[{hours:1},{minutes:30},{minutes:15},{seconds:30},{seconds:15}];function buildSlatMetas(e,t,n,r,o){for(var i=new Date(0),a=e,s=createDuration(0),l=n||computeLabelInterval(r),u=[];asRoughMs(a)<asRoughMs(t);){var c=o.add(i,a),d=null!==wholeDivideDurations(s,l);u.push({date:c,time:a,key:c.toISOString(),isoTimeStr:formatIsoTimeString(c),isLabeled:d}),a=addDurations(a,r),s=addDurations(s,r)}return u}function computeLabelInterval(e){var t,n,r;for(t=STOCK_SUB_DURATIONS.length-1;t>=0;t-=1)if(null!==(r=wholeDivideDurations(n=createDuration(STOCK_SUB_DURATIONS[t]),e))&&r>1)return n;return e}var DayTimeColsView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.buildTimeColsModel=memoize(buildTimeColsModel),t.buildSlatMetas=memoize(buildSlatMetas),t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.context,n=t.options,r=t.dateEnv,o=t.dateProfileGenerator,i=this.props,a=i.dateProfile,s=this.buildTimeColsModel(a,o),l=this.allDaySplitter.splitProps(i),u=this.buildSlatMetas(a.slotMinTime,a.slotMaxTime,n.slotLabelInterval,n.slotDuration,r),c=n.dayMinWidth,d=!c,p=c,f=n.dayHeaders&&createElement(DayHeader,{dates:s.headerDates,dateProfile:a,datesRepDistinctDays:!0,renderIntro:d?this.renderHeadAxis:null}),h=!1!==n.allDaySlot&&function(t){return createElement(DayTable,__assign$1({},l.allDay,{dateProfile:a,dayTableModel:s,nextDayThreshold:n.nextDayThreshold,tableMinWidth:t.tableMinWidth,colGroupNode:t.tableColGroupNode,renderRowIntro:d?e.renderTableRowAxis:null,showWeekNumbers:!1,expandRows:!1,headerAlignElRef:e.headerElRef,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:i.forPrint},e.getAllDayMaxEventProps()))},g=function(t){return createElement(DayTimeCols,__assign$1({},l.timed,{dayTableModel:s,dateProfile:a,axis:d,slotDuration:n.slotDuration,slatMetas:u,forPrint:i.forPrint,tableColGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,clientWidth:t.clientWidth,clientHeight:t.clientHeight,onSlatCoords:e.handleSlatCoords,expandRows:t.expandRows,onScrollTopRequest:e.handleScrollTopRequest}))};return p?this.renderHScrollLayout(f,h,g,s.colCnt,c,u,this.state.slatCoords):this.renderSimpleLayout(f,h,g)},t}(TimeColsView);function buildTimeColsModel(e,t){var n=new DaySeriesModel(e.renderRange,t);return new DayTableModel(n,!1)}var OPTION_REFINERS$2={allDaySlot:Boolean},main$2=createPlugin({initialView:"timeGridWeek",optionRefiners:OPTION_REFINERS$2,views:{timeGrid:{component:DayTimeColsView,usesMinMaxTime:!0,allDaySlot:!0,slotDuration:"00:30:00",slotEventOverlap:!0},timeGridDay:{type:"timeGrid",duration:{days:1}},timeGridWeek:{type:"timeGrid",duration:{weeks:1}}}});
13
13
  /*!
14
14
  FullCalendar v5.11.4
15
15
  Docs & License: https://fullcalendar.io/
16
16
  (c) 2022 Adam Shaw
17
17
  */
18
- config.touchMouseIgnoreWait=500;var ignoreMouseDepth=0,listenerCnt=0,isWindowTouchMoveCancelled=!1,PointerDragging=function(){function e(e){var t=this;this.subjectEl=null,this.selector="",this.handleSelector="",this.shouldIgnoreMove=!1,this.shouldWatchScroll=!0,this.isDragging=!1,this.isTouchDragging=!1,this.wasTouchScroll=!1,this.handleMouseDown=function(e){if(!t.shouldIgnoreMouse()&&isPrimaryMouseButton(e)&&t.tryStart(e)){var n=t.createEventFromMouse(e,!0);t.emitter.trigger("pointerdown",n),t.initScrollWatch(n),t.shouldIgnoreMove||document.addEventListener("mousemove",t.handleMouseMove),document.addEventListener("mouseup",t.handleMouseUp)}},this.handleMouseMove=function(e){var n=t.createEventFromMouse(e);t.recordCoords(n),t.emitter.trigger("pointermove",n)},this.handleMouseUp=function(e){document.removeEventListener("mousemove",t.handleMouseMove),document.removeEventListener("mouseup",t.handleMouseUp),t.emitter.trigger("pointerup",t.createEventFromMouse(e)),t.cleanup()},this.handleTouchStart=function(e){if(t.tryStart(e)){t.isTouchDragging=!0;var n=t.createEventFromTouch(e,!0);t.emitter.trigger("pointerdown",n),t.initScrollWatch(n);var r=e.target;t.shouldIgnoreMove||r.addEventListener("touchmove",t.handleTouchMove),r.addEventListener("touchend",t.handleTouchEnd),r.addEventListener("touchcancel",t.handleTouchEnd),window.addEventListener("scroll",t.handleTouchScroll,!0)}},this.handleTouchMove=function(e){var n=t.createEventFromTouch(e);t.recordCoords(n),t.emitter.trigger("pointermove",n)},this.handleTouchEnd=function(e){if(t.isDragging){var n=e.target;n.removeEventListener("touchmove",t.handleTouchMove),n.removeEventListener("touchend",t.handleTouchEnd),n.removeEventListener("touchcancel",t.handleTouchEnd),window.removeEventListener("scroll",t.handleTouchScroll,!0),t.emitter.trigger("pointerup",t.createEventFromTouch(e)),t.cleanup(),t.isTouchDragging=!1,startIgnoringMouse()}},this.handleTouchScroll=function(){t.wasTouchScroll=!0},this.handleScroll=function(e){if(!t.shouldIgnoreMove){var n=window.pageXOffset-t.prevScrollX+t.prevPageX,r=window.pageYOffset-t.prevScrollY+t.prevPageY;t.emitter.trigger("pointermove",{origEvent:e,isTouch:t.isTouchDragging,subjectEl:t.subjectEl,pageX:n,pageY:r,deltaX:n-t.origPageX,deltaY:r-t.origPageY})}},this.containerEl=e,this.emitter=new Emitter,e.addEventListener("mousedown",this.handleMouseDown),e.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),listenerCreated()}return e.prototype.destroy=function(){this.containerEl.removeEventListener("mousedown",this.handleMouseDown),this.containerEl.removeEventListener("touchstart",this.handleTouchStart,{passive:!0}),listenerDestroyed()},e.prototype.tryStart=function(e){var t=this.querySubjectEl(e),n=e.target;return!(!t||this.handleSelector&&!elementClosest(n,this.handleSelector))&&(this.subjectEl=t,this.isDragging=!0,this.wasTouchScroll=!1,!0)},e.prototype.cleanup=function(){isWindowTouchMoveCancelled=!1,this.isDragging=!1,this.subjectEl=null,this.destroyScrollWatch()},e.prototype.querySubjectEl=function(e){return this.selector?elementClosest(e.target,this.selector):this.containerEl},e.prototype.shouldIgnoreMouse=function(){return ignoreMouseDepth||this.isTouchDragging},e.prototype.cancelTouchScroll=function(){this.isDragging&&(isWindowTouchMoveCancelled=!0)},e.prototype.initScrollWatch=function(e){this.shouldWatchScroll&&(this.recordCoords(e),window.addEventListener("scroll",this.handleScroll,!0))},e.prototype.recordCoords=function(e){this.shouldWatchScroll&&(this.prevPageX=e.pageX,this.prevPageY=e.pageY,this.prevScrollX=window.pageXOffset,this.prevScrollY=window.pageYOffset)},e.prototype.destroyScrollWatch=function(){this.shouldWatchScroll&&window.removeEventListener("scroll",this.handleScroll,!0)},e.prototype.createEventFromMouse=function(e,t){var n=0,r=0;return t?(this.origPageX=e.pageX,this.origPageY=e.pageY):(n=e.pageX-this.origPageX,r=e.pageY-this.origPageY),{origEvent:e,isTouch:!1,subjectEl:this.subjectEl,pageX:e.pageX,pageY:e.pageY,deltaX:n,deltaY:r}},e.prototype.createEventFromTouch=function(e,t){var n,r,o=e.touches,i=0,a=0;return o&&o.length?(n=o[0].pageX,r=o[0].pageY):(n=e.pageX,r=e.pageY),t?(this.origPageX=n,this.origPageY=r):(i=n-this.origPageX,a=r-this.origPageY),{origEvent:e,isTouch:!0,subjectEl:this.subjectEl,pageX:n,pageY:r,deltaX:i,deltaY:a}},e}();function isPrimaryMouseButton(e){return 0===e.button&&!e.ctrlKey}function startIgnoringMouse(){ignoreMouseDepth+=1,setTimeout((function(){ignoreMouseDepth-=1}),config.touchMouseIgnoreWait)}function listenerCreated(){1===(listenerCnt+=1)&&window.addEventListener("touchmove",onWindowTouchMove,{passive:!1})}function listenerDestroyed(){(listenerCnt-=1)||window.removeEventListener("touchmove",onWindowTouchMove,{passive:!1})}function onWindowTouchMove(e){isWindowTouchMoveCancelled&&e.preventDefault()}var ElementMirror=function(){function e(){this.isVisible=!1,this.sourceEl=null,this.mirrorEl=null,this.sourceElRect=null,this.parentNode=document.body,this.zIndex=9999,this.revertDuration=0}return e.prototype.start=function(e,t,n){this.sourceEl=e,this.sourceElRect=this.sourceEl.getBoundingClientRect(),this.origScreenX=t-window.pageXOffset,this.origScreenY=n-window.pageYOffset,this.deltaX=0,this.deltaY=0,this.updateElPosition()},e.prototype.handleMove=function(e,t){this.deltaX=e-window.pageXOffset-this.origScreenX,this.deltaY=t-window.pageYOffset-this.origScreenY,this.updateElPosition()},e.prototype.setIsVisible=function(e){e?this.isVisible||(this.mirrorEl&&(this.mirrorEl.style.display=""),this.isVisible=e,this.updateElPosition()):this.isVisible&&(this.mirrorEl&&(this.mirrorEl.style.display="none"),this.isVisible=e)},e.prototype.stop=function(e,t){var n=this,r=function(){n.cleanup(),t()};e&&this.mirrorEl&&this.isVisible&&this.revertDuration&&(this.deltaX||this.deltaY)?this.doRevertAnimation(r,this.revertDuration):setTimeout(r,0)},e.prototype.doRevertAnimation=function(e,t){var n=this.mirrorEl,r=this.sourceEl.getBoundingClientRect();n.style.transition="top "+t+"ms,left "+t+"ms",applyStyle(n,{left:r.left,top:r.top}),whenTransitionDone(n,(function(){n.style.transition="",e()}))},e.prototype.cleanup=function(){this.mirrorEl&&(removeElement(this.mirrorEl),this.mirrorEl=null),this.sourceEl=null},e.prototype.updateElPosition=function(){this.sourceEl&&this.isVisible&&applyStyle(this.getMirrorEl(),{left:this.sourceElRect.left+this.deltaX,top:this.sourceElRect.top+this.deltaY})},e.prototype.getMirrorEl=function(){var e=this.sourceElRect,t=this.mirrorEl;return t||((t=this.mirrorEl=this.sourceEl.cloneNode(!0)).classList.add("fc-unselectable"),t.classList.add("fc-event-dragging"),applyStyle(t,{position:"fixed",zIndex:this.zIndex,visibility:"",boxSizing:"border-box",width:e.right-e.left,height:e.bottom-e.top,right:"auto",bottom:"auto",margin:0}),this.parentNode.appendChild(t)),t},e}(),ScrollGeomCache=function(e){function t(t,n){var r=e.call(this)||this;return r.handleScroll=function(){r.scrollTop=r.scrollController.getScrollTop(),r.scrollLeft=r.scrollController.getScrollLeft(),r.handleScrollChange()},r.scrollController=t,r.doesListening=n,r.scrollTop=r.origScrollTop=t.getScrollTop(),r.scrollLeft=r.origScrollLeft=t.getScrollLeft(),r.scrollWidth=t.getScrollWidth(),r.scrollHeight=t.getScrollHeight(),r.clientWidth=t.getClientWidth(),r.clientHeight=t.getClientHeight(),r.clientRect=r.computeClientRect(),r.doesListening&&r.getEventTarget().addEventListener("scroll",r.handleScroll),r}return __extends(t,e),t.prototype.destroy=function(){this.doesListening&&this.getEventTarget().removeEventListener("scroll",this.handleScroll)},t.prototype.getScrollTop=function(){return this.scrollTop},t.prototype.getScrollLeft=function(){return this.scrollLeft},t.prototype.setScrollTop=function(e){this.scrollController.setScrollTop(e),this.doesListening||(this.scrollTop=Math.max(Math.min(e,this.getMaxScrollTop()),0),this.handleScrollChange())},t.prototype.setScrollLeft=function(e){this.scrollController.setScrollLeft(e),this.doesListening||(this.scrollLeft=Math.max(Math.min(e,this.getMaxScrollLeft()),0),this.handleScrollChange())},t.prototype.getClientWidth=function(){return this.clientWidth},t.prototype.getClientHeight=function(){return this.clientHeight},t.prototype.getScrollWidth=function(){return this.scrollWidth},t.prototype.getScrollHeight=function(){return this.scrollHeight},t.prototype.handleScrollChange=function(){},t}(ScrollController),ElementScrollGeomCache=function(e){function t(t,n){return e.call(this,new ElementScrollController(t),n)||this}return __extends(t,e),t.prototype.getEventTarget=function(){return this.scrollController.el},t.prototype.computeClientRect=function(){return computeInnerRect(this.scrollController.el)},t}(ScrollGeomCache),WindowScrollGeomCache=function(e){function t(t){return e.call(this,new WindowScrollController,t)||this}return __extends(t,e),t.prototype.getEventTarget=function(){return window},t.prototype.computeClientRect=function(){return{left:this.scrollLeft,right:this.scrollLeft+this.clientWidth,top:this.scrollTop,bottom:this.scrollTop+this.clientHeight}},t.prototype.handleScrollChange=function(){this.clientRect=this.computeClientRect()},t}(ScrollGeomCache),getTime="function"==typeof performance?performance.now:Date.now,AutoScroller=function(){function e(){var e=this;this.isEnabled=!0,this.scrollQuery=[window,".fc-scroller"],this.edgeThreshold=50,this.maxVelocity=300,this.pointerScreenX=null,this.pointerScreenY=null,this.isAnimating=!1,this.scrollCaches=null,this.everMovedUp=!1,this.everMovedDown=!1,this.everMovedLeft=!1,this.everMovedRight=!1,this.animate=function(){if(e.isAnimating){var t=e.computeBestEdge(e.pointerScreenX+window.pageXOffset,e.pointerScreenY+window.pageYOffset);if(t){var n=getTime();e.handleSide(t,(n-e.msSinceRequest)/1e3),e.requestAnimation(n)}else e.isAnimating=!1}}}return e.prototype.start=function(e,t,n){this.isEnabled&&(this.scrollCaches=this.buildCaches(n),this.pointerScreenX=null,this.pointerScreenY=null,this.everMovedUp=!1,this.everMovedDown=!1,this.everMovedLeft=!1,this.everMovedRight=!1,this.handleMove(e,t))},e.prototype.handleMove=function(e,t){if(this.isEnabled){var n=e-window.pageXOffset,r=t-window.pageYOffset,o=null===this.pointerScreenY?0:r-this.pointerScreenY,i=null===this.pointerScreenX?0:n-this.pointerScreenX;o<0?this.everMovedUp=!0:o>0&&(this.everMovedDown=!0),i<0?this.everMovedLeft=!0:i>0&&(this.everMovedRight=!0),this.pointerScreenX=n,this.pointerScreenY=r,this.isAnimating||(this.isAnimating=!0,this.requestAnimation(getTime()))}},e.prototype.stop=function(){if(this.isEnabled){this.isAnimating=!1;for(var e=0,t=this.scrollCaches;e<t.length;e++){t[e].destroy()}this.scrollCaches=null}},e.prototype.requestAnimation=function(e){this.msSinceRequest=e,requestAnimationFrame(this.animate)},e.prototype.handleSide=function(e,t){var n=e.scrollCache,r=this.edgeThreshold,o=r-e.distance,i=o*o/(r*r)*this.maxVelocity*t,a=1;switch(e.name){case"left":a=-1;case"right":n.setScrollLeft(n.getScrollLeft()+i*a);break;case"top":a=-1;case"bottom":n.setScrollTop(n.getScrollTop()+i*a)}},e.prototype.computeBestEdge=function(e,t){for(var n=this.edgeThreshold,r=null,o=0,i=this.scrollCaches||[];o<i.length;o++){var a=i[o],s=a.clientRect,l=e-s.left,u=s.right-e,c=t-s.top,d=s.bottom-t;l>=0&&u>=0&&c>=0&&d>=0&&(c<=n&&this.everMovedUp&&a.canScrollUp()&&(!r||r.distance>c)&&(r={scrollCache:a,name:"top",distance:c}),d<=n&&this.everMovedDown&&a.canScrollDown()&&(!r||r.distance>d)&&(r={scrollCache:a,name:"bottom",distance:d}),l<=n&&this.everMovedLeft&&a.canScrollLeft()&&(!r||r.distance>l)&&(r={scrollCache:a,name:"left",distance:l}),u<=n&&this.everMovedRight&&a.canScrollRight()&&(!r||r.distance>u)&&(r={scrollCache:a,name:"right",distance:u}))}return r},e.prototype.buildCaches=function(e){return this.queryScrollEls(e).map((function(e){return e===window?new WindowScrollGeomCache(!1):new ElementScrollGeomCache(e,!1)}))},e.prototype.queryScrollEls=function(e){for(var t=[],n=0,r=this.scrollQuery;n<r.length;n++){var o=r[n];"object"==typeof o?t.push(o):t.push.apply(t,Array.prototype.slice.call(getElRoot(e).querySelectorAll(o)))}return t},e}(),FeaturefulElementDragging=function(e){function t(t,n){var r=e.call(this,t)||this;r.containerEl=t,r.delay=null,r.minDistance=0,r.touchScrollAllowed=!0,r.mirrorNeedsRevert=!1,r.isInteracting=!1,r.isDragging=!1,r.isDelayEnded=!1,r.isDistanceSurpassed=!1,r.delayTimeoutId=null,r.onPointerDown=function(e){r.isDragging||(r.isInteracting=!0,r.isDelayEnded=!1,r.isDistanceSurpassed=!1,preventSelection(document.body),preventContextMenu(document.body),e.isTouch||e.origEvent.preventDefault(),r.emitter.trigger("pointerdown",e),r.isInteracting&&!r.pointer.shouldIgnoreMove&&(r.mirror.setIsVisible(!1),r.mirror.start(e.subjectEl,e.pageX,e.pageY),r.startDelay(e),r.minDistance||r.handleDistanceSurpassed(e)))},r.onPointerMove=function(e){if(r.isInteracting){if(r.emitter.trigger("pointermove",e),!r.isDistanceSurpassed){var t=r.minDistance,n=e.deltaX,o=e.deltaY;n*n+o*o>=t*t&&r.handleDistanceSurpassed(e)}r.isDragging&&("scroll"!==e.origEvent.type&&(r.mirror.handleMove(e.pageX,e.pageY),r.autoScroller.handleMove(e.pageX,e.pageY)),r.emitter.trigger("dragmove",e))}},r.onPointerUp=function(e){r.isInteracting&&(r.isInteracting=!1,allowSelection(document.body),allowContextMenu(document.body),r.emitter.trigger("pointerup",e),r.isDragging&&(r.autoScroller.stop(),r.tryStopDrag(e)),r.delayTimeoutId&&(clearTimeout(r.delayTimeoutId),r.delayTimeoutId=null))};var o=r.pointer=new PointerDragging(t);return o.emitter.on("pointerdown",r.onPointerDown),o.emitter.on("pointermove",r.onPointerMove),o.emitter.on("pointerup",r.onPointerUp),n&&(o.selector=n),r.mirror=new ElementMirror,r.autoScroller=new AutoScroller,r}return __extends(t,e),t.prototype.destroy=function(){this.pointer.destroy(),this.onPointerUp({})},t.prototype.startDelay=function(e){var t=this;"number"==typeof this.delay?this.delayTimeoutId=setTimeout((function(){t.delayTimeoutId=null,t.handleDelayEnd(e)}),this.delay):this.handleDelayEnd(e)},t.prototype.handleDelayEnd=function(e){this.isDelayEnded=!0,this.tryStartDrag(e)},t.prototype.handleDistanceSurpassed=function(e){this.isDistanceSurpassed=!0,this.tryStartDrag(e)},t.prototype.tryStartDrag=function(e){this.isDelayEnded&&this.isDistanceSurpassed&&(this.pointer.wasTouchScroll&&!this.touchScrollAllowed||(this.isDragging=!0,this.mirrorNeedsRevert=!1,this.autoScroller.start(e.pageX,e.pageY,this.containerEl),this.emitter.trigger("dragstart",e),!1===this.touchScrollAllowed&&this.pointer.cancelTouchScroll()))},t.prototype.tryStopDrag=function(e){this.mirror.stop(this.mirrorNeedsRevert,this.stopDrag.bind(this,e))},t.prototype.stopDrag=function(e){this.isDragging=!1,this.emitter.trigger("dragend",e)},t.prototype.setIgnoreMove=function(e){this.pointer.shouldIgnoreMove=e},t.prototype.setMirrorIsVisible=function(e){this.mirror.setIsVisible(e)},t.prototype.setMirrorNeedsRevert=function(e){this.mirrorNeedsRevert=e},t.prototype.setAutoScrollEnabled=function(e){this.autoScroller.isEnabled=e},t}(ElementDragging),OffsetTracker=function(){function e(e){this.origRect=computeRect(e),this.scrollCaches=getClippingParents(e).map((function(e){return new ElementScrollGeomCache(e,!0)}))}return e.prototype.destroy=function(){for(var e=0,t=this.scrollCaches;e<t.length;e++){t[e].destroy()}},e.prototype.computeLeft=function(){for(var e=this.origRect.left,t=0,n=this.scrollCaches;t<n.length;t++){var r=n[t];e+=r.origScrollLeft-r.getScrollLeft()}return e},e.prototype.computeTop=function(){for(var e=this.origRect.top,t=0,n=this.scrollCaches;t<n.length;t++){var r=n[t];e+=r.origScrollTop-r.getScrollTop()}return e},e.prototype.isWithinClipping=function(e,t){for(var n={left:e,top:t},r=0,o=this.scrollCaches;r<o.length;r++){var i=o[r];if(!isIgnoredClipping(i.getEventTarget())&&!pointInsideRect(n,i.clientRect))return!1}return!0},e}();function isIgnoredClipping(e){var t=e.tagName;return"HTML"===t||"BODY"===t}var HitDragging=function(){function e(e,t){var n=this;this.useSubjectCenter=!1,this.requireInitial=!0,this.initialHit=null,this.movingHit=null,this.finalHit=null,this.handlePointerDown=function(e){var t=n.dragging;n.initialHit=null,n.movingHit=null,n.finalHit=null,n.prepareHits(),n.processFirstCoord(e),n.initialHit||!n.requireInitial?(t.setIgnoreMove(!1),n.emitter.trigger("pointerdown",e)):t.setIgnoreMove(!0)},this.handleDragStart=function(e){n.emitter.trigger("dragstart",e),n.handleMove(e,!0)},this.handleDragMove=function(e){n.emitter.trigger("dragmove",e),n.handleMove(e)},this.handlePointerUp=function(e){n.releaseHits(),n.emitter.trigger("pointerup",e)},this.handleDragEnd=function(e){n.movingHit&&n.emitter.trigger("hitupdate",null,!0,e),n.finalHit=n.movingHit,n.movingHit=null,n.emitter.trigger("dragend",e)},this.droppableStore=t,e.emitter.on("pointerdown",this.handlePointerDown),e.emitter.on("dragstart",this.handleDragStart),e.emitter.on("dragmove",this.handleDragMove),e.emitter.on("pointerup",this.handlePointerUp),e.emitter.on("dragend",this.handleDragEnd),this.dragging=e,this.emitter=new Emitter}return e.prototype.processFirstCoord=function(e){var t,n={left:e.pageX,top:e.pageY},r=n,o=e.subjectEl;o instanceof HTMLElement&&(r=constrainPoint(r,t=computeRect(o)));var i=this.initialHit=this.queryHitForOffset(r.left,r.top);if(i){if(this.useSubjectCenter&&t){var a=intersectRects(t,i.rect);a&&(r=getRectCenter(a))}this.coordAdjust=diffPoints(r,n)}else this.coordAdjust={left:0,top:0}},e.prototype.handleMove=function(e,t){var n=this.queryHitForOffset(e.pageX+this.coordAdjust.left,e.pageY+this.coordAdjust.top);!t&&isHitsEqual(this.movingHit,n)||(this.movingHit=n,this.emitter.trigger("hitupdate",n,!1,e))},e.prototype.prepareHits=function(){this.offsetTrackers=mapHash(this.droppableStore,(function(e){return e.component.prepareHits(),new OffsetTracker(e.el)}))},e.prototype.releaseHits=function(){var e=this.offsetTrackers;for(var t in e)e[t].destroy();this.offsetTrackers={}},e.prototype.queryHitForOffset=function(e,t){var n=this.droppableStore,r=this.offsetTrackers,o=null;for(var i in n){var a=n[i].component,s=r[i];if(s&&s.isWithinClipping(e,t)){var l=s.computeLeft(),u=s.computeTop(),c=e-l,d=t-u,p=s.origRect,f=p.right-p.left,h=p.bottom-p.top;if(c>=0&&c<f&&d>=0&&d<h){var g=a.queryHit(c,d,f,h);g&&rangeContainsRange(g.dateProfile.activeRange,g.dateSpan.range)&&(!o||g.layer>o.layer)&&(g.componentId=i,g.context=a.context,g.rect.left+=l,g.rect.right+=l,g.rect.top+=u,g.rect.bottom+=u,o=g)}}}return o},e}();function isHitsEqual(e,t){return!e&&!t||Boolean(e)===Boolean(t)&&isDateSpansEqual(e.dateSpan,t.dateSpan)}function buildDatePointApiWithContext(e,t){for(var n={},r=0,o=t.pluginHooks.datePointTransforms;r<o.length;r++){var i=o[r];__assign$1(n,i(e,t))}return __assign$1(n,buildDatePointApi(e,t.dateEnv)),n}function buildDatePointApi(e,t){return{date:t.toDate(e.range.start),dateStr:t.formatIso(e.range.start,{omitTime:e.allDay}),allDay:e.allDay}}var DateClicking=function(e){function t(t){var n=e.call(this,t)||this;n.handlePointerDown=function(e){var t=n.dragging,r=e.origEvent.target;t.setIgnoreMove(!n.component.isValidDateDownEl(r))},n.handleDragEnd=function(e){var t=n.component;if(!n.dragging.pointer.wasTouchScroll){var r=n.hitDragging,o=r.initialHit,i=r.finalHit;if(o&&i&&isHitsEqual(o,i)){var a=t.context,s=__assign$1(__assign$1({},buildDatePointApiWithContext(o.dateSpan,a)),{dayEl:o.dayEl,jsEvent:e.origEvent,view:a.viewApi||a.calendarApi.view});a.emitter.trigger("dateClick",s)}}},n.dragging=new FeaturefulElementDragging(t.el),n.dragging.autoScroller.isEnabled=!1;var r=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return r.emitter.on("pointerdown",n.handlePointerDown),r.emitter.on("dragend",n.handleDragEnd),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t}(Interaction),DateSelecting=function(e){function t(t){var n=e.call(this,t)||this;n.dragSelection=null,n.handlePointerDown=function(e){var t=n,r=t.component,o=t.dragging,i=r.context.options.selectable&&r.isValidDateDownEl(e.origEvent.target);o.setIgnoreMove(!i),o.delay=e.isTouch?getComponentTouchDelay$1(r):null},n.handleDragStart=function(e){n.component.context.calendarApi.unselect(e)},n.handleHitUpdate=function(e,t){var r=n.component.context,o=null,i=!1;if(e){var a=n.hitDragging.initialHit;e.componentId===a.componentId&&n.isHitComboAllowed&&!n.isHitComboAllowed(a,e)||(o=joinHitsIntoSelection(a,e,r.pluginHooks.dateSelectionTransformers)),o&&isDateSelectionValid(o,e.dateProfile,r)||(i=!0,o=null)}o?r.dispatch({type:"SELECT_DATES",selection:o}):t||r.dispatch({type:"UNSELECT_DATES"}),i?disableCursor():enableCursor(),t||(n.dragSelection=o)},n.handlePointerUp=function(e){n.dragSelection&&(triggerDateSelect(n.dragSelection,e,n.component.context),n.dragSelection=null)};var r=t.component.context.options,o=n.dragging=new FeaturefulElementDragging(t.el);o.touchScrollAllowed=!1,o.minDistance=r.selectMinDistance||0,o.autoScroller.isEnabled=r.dragScroll;var i=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return i.emitter.on("pointerdown",n.handlePointerDown),i.emitter.on("dragstart",n.handleDragStart),i.emitter.on("hitupdate",n.handleHitUpdate),i.emitter.on("pointerup",n.handlePointerUp),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t}(Interaction);function getComponentTouchDelay$1(e){var t=e.context.options,n=t.selectLongPressDelay;return null==n&&(n=t.longPressDelay),n}function joinHitsIntoSelection(e,t,n){var r=e.dateSpan,o=t.dateSpan,i=[r.range.start,r.range.end,o.range.start,o.range.end];i.sort(compareNumbers);for(var a={},s=0,l=n;s<l.length;s++){var u=(0,l[s])(e,t);if(!1===u)return null;u&&__assign$1(a,u)}return a.range={start:i[0],end:i[3]},a.allDay=r.allDay,a}var EventDragging=function(e){function t(n){var r=e.call(this,n)||this;r.subjectEl=null,r.subjectSeg=null,r.isDragging=!1,r.eventRange=null,r.relevantEvents=null,r.receivingContext=null,r.validMutation=null,r.mutatedRelevantEvents=null,r.handlePointerDown=function(e){var t=e.origEvent.target,n=r,o=n.component,i=n.dragging,a=i.mirror,s=o.context.options,l=o.context;r.subjectEl=e.subjectEl;var u=r.subjectSeg=getElSeg(e.subjectEl),c=(r.eventRange=u.eventRange).instance.instanceId;r.relevantEvents=getRelevantEvents(l.getCurrentData().eventStore,c),i.minDistance=e.isTouch?0:s.eventDragMinDistance,i.delay=e.isTouch&&c!==o.props.eventSelection?getComponentTouchDelay(o):null,s.fixedMirrorParent?a.parentNode=s.fixedMirrorParent:a.parentNode=elementClosest(t,".fc"),a.revertDuration=s.dragRevertDuration;var d=o.isValidSegDownEl(t)&&!elementClosest(t,".fc-event-resizer");i.setIgnoreMove(!d),r.isDragging=d&&e.subjectEl.classList.contains("fc-event-draggable")},r.handleDragStart=function(e){var t=r.component.context,n=r.eventRange,o=n.instance.instanceId;e.isTouch?o!==r.component.props.eventSelection&&t.dispatch({type:"SELECT_EVENT",eventInstanceId:o}):t.dispatch({type:"UNSELECT_EVENT"}),r.isDragging&&(t.calendarApi.unselect(e),t.emitter.trigger("eventDragStart",{el:r.subjectEl,event:new EventApi(t,n.def,n.instance),jsEvent:e.origEvent,view:t.viewApi}))},r.handleHitUpdate=function(e,t){if(r.isDragging){var n=r.relevantEvents,o=r.hitDragging.initialHit,i=r.component.context,a=null,s=null,l=null,u=!1,c={affectedEvents:n,mutatedEvents:createEmptyEventStore(),isEvent:!0};if(e){var d=(a=e.context).options;i===a||d.editable&&d.droppable?(s=computeEventMutation(o,e,a.getCurrentData().pluginHooks.eventDragMutationMassagers))&&(l=applyMutationToEventStore(n,a.getCurrentData().eventUiBases,s,a),c.mutatedEvents=l,isInteractionValid(c,e.dateProfile,a)||(u=!0,s=null,l=null,c.mutatedEvents=createEmptyEventStore())):a=null}r.displayDrag(a,c),u?disableCursor():enableCursor(),t||(i===a&&isHitsEqual(o,e)&&(s=null),r.dragging.setMirrorNeedsRevert(!s),r.dragging.setMirrorIsVisible(!e||!getElRoot(r.subjectEl).querySelector(".fc-event-mirror")),r.receivingContext=a,r.validMutation=s,r.mutatedRelevantEvents=l)}},r.handlePointerUp=function(){r.isDragging||r.cleanup()},r.handleDragEnd=function(e){if(r.isDragging){var t=r.component.context,n=t.viewApi,o=r,i=o.receivingContext,a=o.validMutation,s=r.eventRange.def,l=r.eventRange.instance,u=new EventApi(t,s,l),c=r.relevantEvents,d=r.mutatedRelevantEvents,p=r.hitDragging.finalHit;if(r.clearDrag(),t.emitter.trigger("eventDragStop",{el:r.subjectEl,event:u,jsEvent:e.origEvent,view:n}),a){if(i===t){var f=new EventApi(t,d.defs[s.defId],l?d.instances[l.instanceId]:null);t.dispatch({type:"MERGE_EVENTS",eventStore:d});for(var h={oldEvent:u,event:f,relatedEvents:buildEventApis(d,t,l),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:c})}},g={},v=0,m=t.getCurrentData().pluginHooks.eventDropTransformers;v<m.length;v++){var y=m[v];__assign$1(g,y(a,t))}t.emitter.trigger("eventDrop",__assign$1(__assign$1(__assign$1({},h),g),{el:e.subjectEl,delta:a.datesDelta,jsEvent:e.origEvent,view:n})),t.emitter.trigger("eventChange",h)}else if(i){var E={event:u,relatedEvents:buildEventApis(c,t,l),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:c})}};t.emitter.trigger("eventLeave",__assign$1(__assign$1({},E),{draggedEl:e.subjectEl,view:n})),t.dispatch({type:"REMOVE_EVENTS",eventStore:c}),t.emitter.trigger("eventRemove",E);var S=d.defs[s.defId],D=d.instances[l.instanceId],T=new EventApi(i,S,D);i.dispatch({type:"MERGE_EVENTS",eventStore:d});var b={event:T,relatedEvents:buildEventApis(d,i,D),revert:function(){i.dispatch({type:"REMOVE_EVENTS",eventStore:d})}};i.emitter.trigger("eventAdd",b),e.isTouch&&i.dispatch({type:"SELECT_EVENT",eventInstanceId:l.instanceId}),i.emitter.trigger("drop",__assign$1(__assign$1({},buildDatePointApiWithContext(p.dateSpan,i)),{draggedEl:e.subjectEl,jsEvent:e.origEvent,view:p.context.viewApi})),i.emitter.trigger("eventReceive",__assign$1(__assign$1({},b),{draggedEl:e.subjectEl,view:p.context.viewApi}))}}else t.emitter.trigger("_noEventDrop")}r.cleanup()};var o=r.component.context.options,i=r.dragging=new FeaturefulElementDragging(n.el);i.pointer.selector=t.SELECTOR,i.touchScrollAllowed=!1,i.autoScroller.isEnabled=o.dragScroll;var a=r.hitDragging=new HitDragging(r.dragging,interactionSettingsStore);return a.useSubjectCenter=n.useEventCenter,a.emitter.on("pointerdown",r.handlePointerDown),a.emitter.on("dragstart",r.handleDragStart),a.emitter.on("hitupdate",r.handleHitUpdate),a.emitter.on("pointerup",r.handlePointerUp),a.emitter.on("dragend",r.handleDragEnd),r}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t.prototype.displayDrag=function(e,t){var n=this.component.context,r=this.receivingContext;r&&r!==e&&(r===n?r.dispatch({type:"SET_EVENT_DRAG",state:{affectedEvents:t.affectedEvents,mutatedEvents:createEmptyEventStore(),isEvent:!0}}):r.dispatch({type:"UNSET_EVENT_DRAG"})),e&&e.dispatch({type:"SET_EVENT_DRAG",state:t})},t.prototype.clearDrag=function(){var e=this.component.context,t=this.receivingContext;t&&t.dispatch({type:"UNSET_EVENT_DRAG"}),e!==t&&e.dispatch({type:"UNSET_EVENT_DRAG"})},t.prototype.cleanup=function(){this.subjectSeg=null,this.isDragging=!1,this.eventRange=null,this.relevantEvents=null,this.receivingContext=null,this.validMutation=null,this.mutatedRelevantEvents=null},t.SELECTOR=".fc-event-draggable, .fc-event-resizable",t}(Interaction);function computeEventMutation(e,t,n){var r=e.dateSpan,o=t.dateSpan,i=r.range.start,a=o.range.start,s={};r.allDay!==o.allDay&&(s.allDay=o.allDay,s.hasEnd=t.context.options.allDayMaintainDuration,o.allDay&&(i=startOfDay(i)));var l=diffDates(i,a,e.context.dateEnv,e.componentId===t.componentId?e.largeUnit:null);l.milliseconds&&(s.allDay=!1);for(var u={datesDelta:l,standardProps:s},c=0,d=n;c<d.length;c++){(0,d[c])(u,e,t)}return u}function getComponentTouchDelay(e){var t=e.context.options,n=t.eventLongPressDelay;return null==n&&(n=t.longPressDelay),n}var EventResizing=function(e){function t(t){var n=e.call(this,t)||this;n.draggingSegEl=null,n.draggingSeg=null,n.eventRange=null,n.relevantEvents=null,n.validMutation=null,n.mutatedRelevantEvents=null,n.handlePointerDown=function(e){var t=n.component,r=getElSeg(n.querySegEl(e)),o=n.eventRange=r.eventRange;n.dragging.minDistance=t.context.options.eventDragMinDistance,n.dragging.setIgnoreMove(!n.component.isValidSegDownEl(e.origEvent.target)||e.isTouch&&n.component.props.eventSelection!==o.instance.instanceId)},n.handleDragStart=function(e){var t=n.component.context,r=n.eventRange;n.relevantEvents=getRelevantEvents(t.getCurrentData().eventStore,n.eventRange.instance.instanceId);var o=n.querySegEl(e);n.draggingSegEl=o,n.draggingSeg=getElSeg(o),t.calendarApi.unselect(),t.emitter.trigger("eventResizeStart",{el:o,event:new EventApi(t,r.def,r.instance),jsEvent:e.origEvent,view:t.viewApi})},n.handleHitUpdate=function(e,t,r){var o=n.component.context,i=n.relevantEvents,a=n.hitDragging.initialHit,s=n.eventRange.instance,l=null,u=null,c=!1,d={affectedEvents:i,mutatedEvents:createEmptyEventStore(),isEvent:!0};e&&(e.componentId===a.componentId&&n.isHitComboAllowed&&!n.isHitComboAllowed(a,e)||(l=computeMutation(a,e,r.subjectEl.classList.contains("fc-event-resizer-start"),s.range)));l&&(u=applyMutationToEventStore(i,o.getCurrentData().eventUiBases,l,o),d.mutatedEvents=u,isInteractionValid(d,e.dateProfile,o)||(c=!0,l=null,u=null,d.mutatedEvents=null)),u?o.dispatch({type:"SET_EVENT_RESIZE",state:d}):o.dispatch({type:"UNSET_EVENT_RESIZE"}),c?disableCursor():enableCursor(),t||(l&&isHitsEqual(a,e)&&(l=null),n.validMutation=l,n.mutatedRelevantEvents=u)},n.handleDragEnd=function(e){var t=n.component.context,r=n.eventRange.def,o=n.eventRange.instance,i=new EventApi(t,r,o),a=n.relevantEvents,s=n.mutatedRelevantEvents;if(t.emitter.trigger("eventResizeStop",{el:n.draggingSegEl,event:i,jsEvent:e.origEvent,view:t.viewApi}),n.validMutation){var l=new EventApi(t,s.defs[r.defId],o?s.instances[o.instanceId]:null);t.dispatch({type:"MERGE_EVENTS",eventStore:s});var u={oldEvent:i,event:l,relatedEvents:buildEventApis(s,t,o),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:a})}};t.emitter.trigger("eventResize",__assign$1(__assign$1({},u),{el:n.draggingSegEl,startDelta:n.validMutation.startDelta||createDuration(0),endDelta:n.validMutation.endDelta||createDuration(0),jsEvent:e.origEvent,view:t.viewApi})),t.emitter.trigger("eventChange",u)}else t.emitter.trigger("_noEventResize");n.draggingSeg=null,n.relevantEvents=null,n.validMutation=null};var r=t.component,o=n.dragging=new FeaturefulElementDragging(t.el);o.pointer.selector=".fc-event-resizer",o.touchScrollAllowed=!1,o.autoScroller.isEnabled=r.context.options.dragScroll;var i=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return i.emitter.on("pointerdown",n.handlePointerDown),i.emitter.on("dragstart",n.handleDragStart),i.emitter.on("hitupdate",n.handleHitUpdate),i.emitter.on("dragend",n.handleDragEnd),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t.prototype.querySegEl=function(e){return elementClosest(e.subjectEl,".fc-event")},t}(Interaction);function computeMutation(e,t,n,r){var o=e.context.dateEnv,i=diffDates(e.dateSpan.range.start,t.dateSpan.range.start,o,e.largeUnit);if(n){if(o.add(r.start,i)<r.end)return{startDelta:i}}else if(o.add(r.end,i)>r.start)return{endDelta:i};return null}var UnselectAuto=function(){function e(e){var t=this;this.context=e,this.isRecentPointerDateSelect=!1,this.matchesCancel=!1,this.matchesEvent=!1,this.onSelect=function(e){e.jsEvent&&(t.isRecentPointerDateSelect=!0)},this.onDocumentPointerDown=function(e){var n=t.context.options.unselectCancel,r=getEventTargetViaRoot(e.origEvent);t.matchesCancel=!!elementClosest(r,n),t.matchesEvent=!!elementClosest(r,EventDragging.SELECTOR)},this.onDocumentPointerUp=function(e){var n=t.context,r=t.documentPointer,o=n.getCurrentData();if(!r.wasTouchScroll){if(o.dateSelection&&!t.isRecentPointerDateSelect){var i=n.options.unselectAuto;!i||i&&t.matchesCancel||n.calendarApi.unselect(e)}o.eventSelection&&!t.matchesEvent&&n.dispatch({type:"UNSELECT_EVENT"})}t.isRecentPointerDateSelect=!1};var n=this.documentPointer=new PointerDragging(document);n.shouldIgnoreMove=!0,n.shouldWatchScroll=!1,n.emitter.on("pointerdown",this.onDocumentPointerDown),n.emitter.on("pointerup",this.onDocumentPointerUp),e.emitter.on("select",this.onSelect)}return e.prototype.destroy=function(){this.context.emitter.off("select",this.onSelect),this.documentPointer.destroy()},e}(),OPTION_REFINERS$1={fixedMirrorParent:identity},LISTENER_REFINERS={dateClick:identity,eventDragStart:identity,eventDragStop:identity,eventDrop:identity,eventResizeStart:identity,eventResizeStop:identity,eventResize:identity,drop:identity,eventReceive:identity,eventLeave:identity};config.dataAttrPrefix="",function(e){function t(t){var n=e.call(this,t)||this;n.shouldIgnoreMove=!1,n.mirrorSelector="",n.currentMirrorEl=null,n.handlePointerDown=function(e){n.emitter.trigger("pointerdown",e),n.shouldIgnoreMove||n.emitter.trigger("dragstart",e)},n.handlePointerMove=function(e){n.shouldIgnoreMove||n.emitter.trigger("dragmove",e)},n.handlePointerUp=function(e){n.emitter.trigger("pointerup",e),n.shouldIgnoreMove||n.emitter.trigger("dragend",e)};var r=n.pointer=new PointerDragging(t);return r.emitter.on("pointerdown",n.handlePointerDown),r.emitter.on("pointermove",n.handlePointerMove),r.emitter.on("pointerup",n.handlePointerUp),n}__extends(t,e),t.prototype.destroy=function(){this.pointer.destroy()},t.prototype.setIgnoreMove=function(e){this.shouldIgnoreMove=e},t.prototype.setMirrorIsVisible=function(e){if(e)this.currentMirrorEl&&(this.currentMirrorEl.style.visibility="",this.currentMirrorEl=null);else{var t=this.mirrorSelector?document.querySelector(this.mirrorSelector):null;t&&(this.currentMirrorEl=t,t.style.visibility="hidden")}}}(ElementDragging);var main$1=createPlugin({componentInteractions:[DateClicking,DateSelecting,EventDragging,EventResizing],calendarInteractions:[UnselectAuto],elementDraggingImpl:FeaturefulElementDragging,optionRefiners:OPTION_REFINERS$1,listenerRefiners:LISTENER_REFINERS}),ListViewHeaderRow=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={textId:getUniqueDomId()},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.theme,n=e.dateEnv,r=e.options,o=e.viewApi,i=this.props,a=i.cellId,s=i.dayDate,l=i.todayRange,u=this.state.textId,c=getDateMeta(s,l),d=r.listDayFormat?n.format(s,r.listDayFormat):"",p=r.listDaySideFormat?n.format(s,r.listDaySideFormat):"",f=__assign$1({date:n.toDate(s),view:o,textId:u,text:d,sideText:p,navLinkAttrs:buildNavLinkAttrs(this.context,s),sideNavLinkAttrs:buildNavLinkAttrs(this.context,s,"day",!1)},c),h=["fc-list-day"].concat(getDayClassNames(c,t));return createElement(RenderHook,{hookProps:f,classNames:r.dayHeaderClassNames,content:r.dayHeaderContent,defaultContent:renderInnerContent,didMount:r.dayHeaderDidMount,willUnmount:r.dayHeaderWillUnmount},(function(e,n,r,o){return createElement("tr",{ref:e,className:h.concat(n).join(" "),"data-date":formatDayString(s)},createElement("th",{scope:"colgroup",colSpan:3,id:a,"aria-labelledby":u},createElement("div",{className:"fc-list-day-cushion "+t.getClass("tableCellShaded"),ref:r},o)))}))},t}(BaseComponent);
18
+ config.touchMouseIgnoreWait=500;var ignoreMouseDepth=0,listenerCnt=0,isWindowTouchMoveCancelled=!1,PointerDragging=function(){function e(e){var t=this;this.subjectEl=null,this.selector="",this.handleSelector="",this.shouldIgnoreMove=!1,this.shouldWatchScroll=!0,this.isDragging=!1,this.isTouchDragging=!1,this.wasTouchScroll=!1,this.handleMouseDown=function(e){if(!t.shouldIgnoreMouse()&&isPrimaryMouseButton(e)&&t.tryStart(e)){var n=t.createEventFromMouse(e,!0);t.emitter.trigger("pointerdown",n),t.initScrollWatch(n),t.shouldIgnoreMove||document.addEventListener("mousemove",t.handleMouseMove),document.addEventListener("mouseup",t.handleMouseUp)}},this.handleMouseMove=function(e){var n=t.createEventFromMouse(e);t.recordCoords(n),t.emitter.trigger("pointermove",n)},this.handleMouseUp=function(e){document.removeEventListener("mousemove",t.handleMouseMove),document.removeEventListener("mouseup",t.handleMouseUp),t.emitter.trigger("pointerup",t.createEventFromMouse(e)),t.cleanup()},this.handleTouchStart=function(e){if(t.tryStart(e)){t.isTouchDragging=!0;var n=t.createEventFromTouch(e,!0);t.emitter.trigger("pointerdown",n),t.initScrollWatch(n);var r=e.target;t.shouldIgnoreMove||r.addEventListener("touchmove",t.handleTouchMove),r.addEventListener("touchend",t.handleTouchEnd),r.addEventListener("touchcancel",t.handleTouchEnd),window.addEventListener("scroll",t.handleTouchScroll,!0)}},this.handleTouchMove=function(e){var n=t.createEventFromTouch(e);t.recordCoords(n),t.emitter.trigger("pointermove",n)},this.handleTouchEnd=function(e){if(t.isDragging){var n=e.target;n.removeEventListener("touchmove",t.handleTouchMove),n.removeEventListener("touchend",t.handleTouchEnd),n.removeEventListener("touchcancel",t.handleTouchEnd),window.removeEventListener("scroll",t.handleTouchScroll,!0),t.emitter.trigger("pointerup",t.createEventFromTouch(e)),t.cleanup(),t.isTouchDragging=!1,startIgnoringMouse()}},this.handleTouchScroll=function(){t.wasTouchScroll=!0},this.handleScroll=function(e){if(!t.shouldIgnoreMove){var n=window.pageXOffset-t.prevScrollX+t.prevPageX,r=window.pageYOffset-t.prevScrollY+t.prevPageY;t.emitter.trigger("pointermove",{origEvent:e,isTouch:t.isTouchDragging,subjectEl:t.subjectEl,pageX:n,pageY:r,deltaX:n-t.origPageX,deltaY:r-t.origPageY})}},this.containerEl=e,this.emitter=new Emitter,e.addEventListener("mousedown",this.handleMouseDown),e.addEventListener("touchstart",this.handleTouchStart,{passive:!0}),listenerCreated()}return e.prototype.destroy=function(){this.containerEl.removeEventListener("mousedown",this.handleMouseDown),this.containerEl.removeEventListener("touchstart",this.handleTouchStart,{passive:!0}),listenerDestroyed()},e.prototype.tryStart=function(e){var t=this.querySubjectEl(e),n=e.target;return!(!t||this.handleSelector&&!elementClosest(n,this.handleSelector))&&(this.subjectEl=t,this.isDragging=!0,this.wasTouchScroll=!1,!0)},e.prototype.cleanup=function(){isWindowTouchMoveCancelled=!1,this.isDragging=!1,this.subjectEl=null,this.destroyScrollWatch()},e.prototype.querySubjectEl=function(e){return this.selector?elementClosest(e.target,this.selector):this.containerEl},e.prototype.shouldIgnoreMouse=function(){return ignoreMouseDepth||this.isTouchDragging},e.prototype.cancelTouchScroll=function(){this.isDragging&&(isWindowTouchMoveCancelled=!0)},e.prototype.initScrollWatch=function(e){this.shouldWatchScroll&&(this.recordCoords(e),window.addEventListener("scroll",this.handleScroll,!0))},e.prototype.recordCoords=function(e){this.shouldWatchScroll&&(this.prevPageX=e.pageX,this.prevPageY=e.pageY,this.prevScrollX=window.pageXOffset,this.prevScrollY=window.pageYOffset)},e.prototype.destroyScrollWatch=function(){this.shouldWatchScroll&&window.removeEventListener("scroll",this.handleScroll,!0)},e.prototype.createEventFromMouse=function(e,t){var n=0,r=0;return t?(this.origPageX=e.pageX,this.origPageY=e.pageY):(n=e.pageX-this.origPageX,r=e.pageY-this.origPageY),{origEvent:e,isTouch:!1,subjectEl:this.subjectEl,pageX:e.pageX,pageY:e.pageY,deltaX:n,deltaY:r}},e.prototype.createEventFromTouch=function(e,t){var n,r,o=e.touches,i=0,a=0;return o&&o.length?(n=o[0].pageX,r=o[0].pageY):(n=e.pageX,r=e.pageY),t?(this.origPageX=n,this.origPageY=r):(i=n-this.origPageX,a=r-this.origPageY),{origEvent:e,isTouch:!0,subjectEl:this.subjectEl,pageX:n,pageY:r,deltaX:i,deltaY:a}},e}();function isPrimaryMouseButton(e){return 0===e.button&&!e.ctrlKey}function startIgnoringMouse(){ignoreMouseDepth+=1,setTimeout((function(){ignoreMouseDepth-=1}),config.touchMouseIgnoreWait)}function listenerCreated(){1===(listenerCnt+=1)&&window.addEventListener("touchmove",onWindowTouchMove,{passive:!1})}function listenerDestroyed(){(listenerCnt-=1)||window.removeEventListener("touchmove",onWindowTouchMove,{passive:!1})}function onWindowTouchMove(e){isWindowTouchMoveCancelled&&e.preventDefault()}var ElementMirror=function(){function e(){this.isVisible=!1,this.sourceEl=null,this.mirrorEl=null,this.sourceElRect=null,this.parentNode=document.body,this.zIndex=9999,this.revertDuration=0}return e.prototype.start=function(e,t,n){this.sourceEl=e,this.sourceElRect=this.sourceEl.getBoundingClientRect(),this.origScreenX=t-window.pageXOffset,this.origScreenY=n-window.pageYOffset,this.deltaX=0,this.deltaY=0,this.updateElPosition()},e.prototype.handleMove=function(e,t){this.deltaX=e-window.pageXOffset-this.origScreenX,this.deltaY=t-window.pageYOffset-this.origScreenY,this.updateElPosition()},e.prototype.setIsVisible=function(e){e?this.isVisible||(this.mirrorEl&&(this.mirrorEl.style.display=""),this.isVisible=e,this.updateElPosition()):this.isVisible&&(this.mirrorEl&&(this.mirrorEl.style.display="none"),this.isVisible=e)},e.prototype.stop=function(e,t){var n=this,r=function(){n.cleanup(),t()};e&&this.mirrorEl&&this.isVisible&&this.revertDuration&&(this.deltaX||this.deltaY)?this.doRevertAnimation(r,this.revertDuration):setTimeout(r,0)},e.prototype.doRevertAnimation=function(e,t){var n=this.mirrorEl,r=this.sourceEl.getBoundingClientRect();n.style.transition="top "+t+"ms,left "+t+"ms",applyStyle(n,{left:r.left,top:r.top}),whenTransitionDone(n,(function(){n.style.transition="",e()}))},e.prototype.cleanup=function(){this.mirrorEl&&(removeElement(this.mirrorEl),this.mirrorEl=null),this.sourceEl=null},e.prototype.updateElPosition=function(){this.sourceEl&&this.isVisible&&applyStyle(this.getMirrorEl(),{left:this.sourceElRect.left+this.deltaX,top:this.sourceElRect.top+this.deltaY})},e.prototype.getMirrorEl=function(){var e=this.sourceElRect,t=this.mirrorEl;return t||((t=this.mirrorEl=this.sourceEl.cloneNode(!0)).classList.add("fc-unselectable"),t.classList.add("fc-event-dragging"),applyStyle(t,{position:"fixed",zIndex:this.zIndex,visibility:"",boxSizing:"border-box",width:e.right-e.left,height:e.bottom-e.top,right:"auto",bottom:"auto",margin:0}),this.parentNode.appendChild(t)),t},e}(),ScrollGeomCache=function(e){function t(t,n){var r=e.call(this)||this;return r.handleScroll=function(){r.scrollTop=r.scrollController.getScrollTop(),r.scrollLeft=r.scrollController.getScrollLeft(),r.handleScrollChange()},r.scrollController=t,r.doesListening=n,r.scrollTop=r.origScrollTop=t.getScrollTop(),r.scrollLeft=r.origScrollLeft=t.getScrollLeft(),r.scrollWidth=t.getScrollWidth(),r.scrollHeight=t.getScrollHeight(),r.clientWidth=t.getClientWidth(),r.clientHeight=t.getClientHeight(),r.clientRect=r.computeClientRect(),r.doesListening&&r.getEventTarget().addEventListener("scroll",r.handleScroll),r}return __extends(t,e),t.prototype.destroy=function(){this.doesListening&&this.getEventTarget().removeEventListener("scroll",this.handleScroll)},t.prototype.getScrollTop=function(){return this.scrollTop},t.prototype.getScrollLeft=function(){return this.scrollLeft},t.prototype.setScrollTop=function(e){this.scrollController.setScrollTop(e),this.doesListening||(this.scrollTop=Math.max(Math.min(e,this.getMaxScrollTop()),0),this.handleScrollChange())},t.prototype.setScrollLeft=function(e){this.scrollController.setScrollLeft(e),this.doesListening||(this.scrollLeft=Math.max(Math.min(e,this.getMaxScrollLeft()),0),this.handleScrollChange())},t.prototype.getClientWidth=function(){return this.clientWidth},t.prototype.getClientHeight=function(){return this.clientHeight},t.prototype.getScrollWidth=function(){return this.scrollWidth},t.prototype.getScrollHeight=function(){return this.scrollHeight},t.prototype.handleScrollChange=function(){},t}(ScrollController),ElementScrollGeomCache=function(e){function t(t,n){return e.call(this,new ElementScrollController(t),n)||this}return __extends(t,e),t.prototype.getEventTarget=function(){return this.scrollController.el},t.prototype.computeClientRect=function(){return computeInnerRect(this.scrollController.el)},t}(ScrollGeomCache),WindowScrollGeomCache=function(e){function t(t){return e.call(this,new WindowScrollController,t)||this}return __extends(t,e),t.prototype.getEventTarget=function(){return window},t.prototype.computeClientRect=function(){return{left:this.scrollLeft,right:this.scrollLeft+this.clientWidth,top:this.scrollTop,bottom:this.scrollTop+this.clientHeight}},t.prototype.handleScrollChange=function(){this.clientRect=this.computeClientRect()},t}(ScrollGeomCache),getTime="function"==typeof performance?performance.now:Date.now,AutoScroller=function(){function e(){var e=this;this.isEnabled=!0,this.scrollQuery=[window,".fc-scroller"],this.edgeThreshold=50,this.maxVelocity=300,this.pointerScreenX=null,this.pointerScreenY=null,this.isAnimating=!1,this.scrollCaches=null,this.everMovedUp=!1,this.everMovedDown=!1,this.everMovedLeft=!1,this.everMovedRight=!1,this.animate=function(){if(e.isAnimating){var t=e.computeBestEdge(e.pointerScreenX+window.pageXOffset,e.pointerScreenY+window.pageYOffset);if(t){var n=getTime();e.handleSide(t,(n-e.msSinceRequest)/1e3),e.requestAnimation(n)}else e.isAnimating=!1}}}return e.prototype.start=function(e,t,n){this.isEnabled&&(this.scrollCaches=this.buildCaches(n),this.pointerScreenX=null,this.pointerScreenY=null,this.everMovedUp=!1,this.everMovedDown=!1,this.everMovedLeft=!1,this.everMovedRight=!1,this.handleMove(e,t))},e.prototype.handleMove=function(e,t){if(this.isEnabled){var n=e-window.pageXOffset,r=t-window.pageYOffset,o=null===this.pointerScreenY?0:r-this.pointerScreenY,i=null===this.pointerScreenX?0:n-this.pointerScreenX;o<0?this.everMovedUp=!0:o>0&&(this.everMovedDown=!0),i<0?this.everMovedLeft=!0:i>0&&(this.everMovedRight=!0),this.pointerScreenX=n,this.pointerScreenY=r,this.isAnimating||(this.isAnimating=!0,this.requestAnimation(getTime()))}},e.prototype.stop=function(){if(this.isEnabled){this.isAnimating=!1;for(var e=0,t=this.scrollCaches;e<t.length;e++){t[e].destroy()}this.scrollCaches=null}},e.prototype.requestAnimation=function(e){this.msSinceRequest=e,requestAnimationFrame(this.animate)},e.prototype.handleSide=function(e,t){var n=e.scrollCache,r=this.edgeThreshold,o=r-e.distance,i=o*o/(r*r)*this.maxVelocity*t,a=1;switch(e.name){case"left":a=-1;case"right":n.setScrollLeft(n.getScrollLeft()+i*a);break;case"top":a=-1;case"bottom":n.setScrollTop(n.getScrollTop()+i*a)}},e.prototype.computeBestEdge=function(e,t){for(var n=this.edgeThreshold,r=null,o=0,i=this.scrollCaches||[];o<i.length;o++){var a=i[o],s=a.clientRect,l=e-s.left,u=s.right-e,c=t-s.top,d=s.bottom-t;l>=0&&u>=0&&c>=0&&d>=0&&(c<=n&&this.everMovedUp&&a.canScrollUp()&&(!r||r.distance>c)&&(r={scrollCache:a,name:"top",distance:c}),d<=n&&this.everMovedDown&&a.canScrollDown()&&(!r||r.distance>d)&&(r={scrollCache:a,name:"bottom",distance:d}),l<=n&&this.everMovedLeft&&a.canScrollLeft()&&(!r||r.distance>l)&&(r={scrollCache:a,name:"left",distance:l}),u<=n&&this.everMovedRight&&a.canScrollRight()&&(!r||r.distance>u)&&(r={scrollCache:a,name:"right",distance:u}))}return r},e.prototype.buildCaches=function(e){return this.queryScrollEls(e).map((function(e){return e===window?new WindowScrollGeomCache(!1):new ElementScrollGeomCache(e,!1)}))},e.prototype.queryScrollEls=function(e){for(var t=[],n=0,r=this.scrollQuery;n<r.length;n++){var o=r[n];"object"==typeof o?t.push(o):t.push.apply(t,Array.prototype.slice.call(getElRoot(e).querySelectorAll(o)))}return t},e}(),FeaturefulElementDragging=function(e){function t(t,n){var r=e.call(this,t)||this;r.containerEl=t,r.delay=null,r.minDistance=0,r.touchScrollAllowed=!0,r.mirrorNeedsRevert=!1,r.isInteracting=!1,r.isDragging=!1,r.isDelayEnded=!1,r.isDistanceSurpassed=!1,r.delayTimeoutId=null,r.onPointerDown=function(e){r.isDragging||(r.isInteracting=!0,r.isDelayEnded=!1,r.isDistanceSurpassed=!1,preventSelection(document.body),preventContextMenu(document.body),e.isTouch||e.origEvent.preventDefault(),r.emitter.trigger("pointerdown",e),r.isInteracting&&!r.pointer.shouldIgnoreMove&&(r.mirror.setIsVisible(!1),r.mirror.start(e.subjectEl,e.pageX,e.pageY),r.startDelay(e),r.minDistance||r.handleDistanceSurpassed(e)))},r.onPointerMove=function(e){if(r.isInteracting){if(r.emitter.trigger("pointermove",e),!r.isDistanceSurpassed){var t=r.minDistance,n=e.deltaX,o=e.deltaY;n*n+o*o>=t*t&&r.handleDistanceSurpassed(e)}r.isDragging&&("scroll"!==e.origEvent.type&&(r.mirror.handleMove(e.pageX,e.pageY),r.autoScroller.handleMove(e.pageX,e.pageY)),r.emitter.trigger("dragmove",e))}},r.onPointerUp=function(e){r.isInteracting&&(r.isInteracting=!1,allowSelection(document.body),allowContextMenu(document.body),r.emitter.trigger("pointerup",e),r.isDragging&&(r.autoScroller.stop(),r.tryStopDrag(e)),r.delayTimeoutId&&(clearTimeout(r.delayTimeoutId),r.delayTimeoutId=null))};var o=r.pointer=new PointerDragging(t);return o.emitter.on("pointerdown",r.onPointerDown),o.emitter.on("pointermove",r.onPointerMove),o.emitter.on("pointerup",r.onPointerUp),n&&(o.selector=n),r.mirror=new ElementMirror,r.autoScroller=new AutoScroller,r}return __extends(t,e),t.prototype.destroy=function(){this.pointer.destroy(),this.onPointerUp({})},t.prototype.startDelay=function(e){var t=this;"number"==typeof this.delay?this.delayTimeoutId=setTimeout((function(){t.delayTimeoutId=null,t.handleDelayEnd(e)}),this.delay):this.handleDelayEnd(e)},t.prototype.handleDelayEnd=function(e){this.isDelayEnded=!0,this.tryStartDrag(e)},t.prototype.handleDistanceSurpassed=function(e){this.isDistanceSurpassed=!0,this.tryStartDrag(e)},t.prototype.tryStartDrag=function(e){this.isDelayEnded&&this.isDistanceSurpassed&&(this.pointer.wasTouchScroll&&!this.touchScrollAllowed||(this.isDragging=!0,this.mirrorNeedsRevert=!1,this.autoScroller.start(e.pageX,e.pageY,this.containerEl),this.emitter.trigger("dragstart",e),!1===this.touchScrollAllowed&&this.pointer.cancelTouchScroll()))},t.prototype.tryStopDrag=function(e){this.mirror.stop(this.mirrorNeedsRevert,this.stopDrag.bind(this,e))},t.prototype.stopDrag=function(e){this.isDragging=!1,this.emitter.trigger("dragend",e)},t.prototype.setIgnoreMove=function(e){this.pointer.shouldIgnoreMove=e},t.prototype.setMirrorIsVisible=function(e){this.mirror.setIsVisible(e)},t.prototype.setMirrorNeedsRevert=function(e){this.mirrorNeedsRevert=e},t.prototype.setAutoScrollEnabled=function(e){this.autoScroller.isEnabled=e},t}(ElementDragging),OffsetTracker=function(){function e(e){this.origRect=computeRect(e),this.scrollCaches=getClippingParents(e).map((function(e){return new ElementScrollGeomCache(e,!0)}))}return e.prototype.destroy=function(){for(var e=0,t=this.scrollCaches;e<t.length;e++){t[e].destroy()}},e.prototype.computeLeft=function(){for(var e=this.origRect.left,t=0,n=this.scrollCaches;t<n.length;t++){var r=n[t];e+=r.origScrollLeft-r.getScrollLeft()}return e},e.prototype.computeTop=function(){for(var e=this.origRect.top,t=0,n=this.scrollCaches;t<n.length;t++){var r=n[t];e+=r.origScrollTop-r.getScrollTop()}return e},e.prototype.isWithinClipping=function(e,t){for(var n={left:e,top:t},r=0,o=this.scrollCaches;r<o.length;r++){var i=o[r];if(!isIgnoredClipping(i.getEventTarget())&&!pointInsideRect(n,i.clientRect))return!1}return!0},e}();function isIgnoredClipping(e){var t=e.tagName;return"HTML"===t||"BODY"===t}var HitDragging=function(){function e(e,t){var n=this;this.useSubjectCenter=!1,this.requireInitial=!0,this.initialHit=null,this.movingHit=null,this.finalHit=null,this.handlePointerDown=function(e){var t=n.dragging;n.initialHit=null,n.movingHit=null,n.finalHit=null,n.prepareHits(),n.processFirstCoord(e),n.initialHit||!n.requireInitial?(t.setIgnoreMove(!1),n.emitter.trigger("pointerdown",e)):t.setIgnoreMove(!0)},this.handleDragStart=function(e){n.emitter.trigger("dragstart",e),n.handleMove(e,!0)},this.handleDragMove=function(e){n.emitter.trigger("dragmove",e),n.handleMove(e)},this.handlePointerUp=function(e){n.releaseHits(),n.emitter.trigger("pointerup",e)},this.handleDragEnd=function(e){n.movingHit&&n.emitter.trigger("hitupdate",null,!0,e),n.finalHit=n.movingHit,n.movingHit=null,n.emitter.trigger("dragend",e)},this.droppableStore=t,e.emitter.on("pointerdown",this.handlePointerDown),e.emitter.on("dragstart",this.handleDragStart),e.emitter.on("dragmove",this.handleDragMove),e.emitter.on("pointerup",this.handlePointerUp),e.emitter.on("dragend",this.handleDragEnd),this.dragging=e,this.emitter=new Emitter}return e.prototype.processFirstCoord=function(e){var t,n={left:e.pageX,top:e.pageY},r=n,o=e.subjectEl;o instanceof HTMLElement&&(r=constrainPoint(r,t=computeRect(o)));var i=this.initialHit=this.queryHitForOffset(r.left,r.top);if(i){if(this.useSubjectCenter&&t){var a=intersectRects(t,i.rect);a&&(r=getRectCenter(a))}this.coordAdjust=diffPoints(r,n)}else this.coordAdjust={left:0,top:0}},e.prototype.handleMove=function(e,t){var n=this.queryHitForOffset(e.pageX+this.coordAdjust.left,e.pageY+this.coordAdjust.top);!t&&isHitsEqual(this.movingHit,n)||(this.movingHit=n,this.emitter.trigger("hitupdate",n,!1,e))},e.prototype.prepareHits=function(){this.offsetTrackers=mapHash(this.droppableStore,(function(e){return e.component.prepareHits(),new OffsetTracker(e.el)}))},e.prototype.releaseHits=function(){var e=this.offsetTrackers;for(var t in e)e[t].destroy();this.offsetTrackers={}},e.prototype.queryHitForOffset=function(e,t){var n=this.droppableStore,r=this.offsetTrackers,o=null;for(var i in n){var a=n[i].component,s=r[i];if(s&&s.isWithinClipping(e,t)){var l=s.computeLeft(),u=s.computeTop(),c=e-l,d=t-u,p=s.origRect,f=p.right-p.left,h=p.bottom-p.top;if(c>=0&&c<f&&d>=0&&d<h){var g=a.queryHit(c,d,f,h);g&&rangeContainsRange(g.dateProfile.activeRange,g.dateSpan.range)&&(!o||g.layer>o.layer)&&(g.componentId=i,g.context=a.context,g.rect.left+=l,g.rect.right+=l,g.rect.top+=u,g.rect.bottom+=u,o=g)}}}return o},e}();function isHitsEqual(e,t){return!e&&!t||Boolean(e)===Boolean(t)&&isDateSpansEqual(e.dateSpan,t.dateSpan)}function buildDatePointApiWithContext(e,t){for(var n={},r=0,o=t.pluginHooks.datePointTransforms;r<o.length;r++){var i=o[r];__assign$1(n,i(e,t))}return __assign$1(n,buildDatePointApi(e,t.dateEnv)),n}function buildDatePointApi(e,t){return{date:t.toDate(e.range.start),dateStr:t.formatIso(e.range.start,{omitTime:e.allDay}),allDay:e.allDay}}var DateClicking=function(e){function t(t){var n=e.call(this,t)||this;n.handlePointerDown=function(e){var t=n.dragging,r=e.origEvent.target;t.setIgnoreMove(!n.component.isValidDateDownEl(r))},n.handleDragEnd=function(e){var t=n.component;if(!n.dragging.pointer.wasTouchScroll){var r=n.hitDragging,o=r.initialHit,i=r.finalHit;if(o&&i&&isHitsEqual(o,i)){var a=t.context,s=__assign$1(__assign$1({},buildDatePointApiWithContext(o.dateSpan,a)),{dayEl:o.dayEl,jsEvent:e.origEvent,view:a.viewApi||a.calendarApi.view});a.emitter.trigger("dateClick",s)}}},n.dragging=new FeaturefulElementDragging(t.el),n.dragging.autoScroller.isEnabled=!1;var r=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return r.emitter.on("pointerdown",n.handlePointerDown),r.emitter.on("dragend",n.handleDragEnd),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t}(Interaction),DateSelecting=function(e){function t(t){var n=e.call(this,t)||this;n.dragSelection=null,n.handlePointerDown=function(e){var t=n,r=t.component,o=t.dragging,i=r.context.options.selectable&&r.isValidDateDownEl(e.origEvent.target);o.setIgnoreMove(!i),o.delay=e.isTouch?getComponentTouchDelay$1(r):null},n.handleDragStart=function(e){n.component.context.calendarApi.unselect(e)},n.handleHitUpdate=function(e,t){var r=n.component.context,o=null,i=!1;if(e){var a=n.hitDragging.initialHit;e.componentId===a.componentId&&n.isHitComboAllowed&&!n.isHitComboAllowed(a,e)||(o=joinHitsIntoSelection(a,e,r.pluginHooks.dateSelectionTransformers)),o&&isDateSelectionValid(o,e.dateProfile,r)||(i=!0,o=null)}o?r.dispatch({type:"SELECT_DATES",selection:o}):t||r.dispatch({type:"UNSELECT_DATES"}),i?disableCursor():enableCursor(),t||(n.dragSelection=o)},n.handlePointerUp=function(e){n.dragSelection&&(triggerDateSelect(n.dragSelection,e,n.component.context),n.dragSelection=null)};var r=t.component.context.options,o=n.dragging=new FeaturefulElementDragging(t.el);o.touchScrollAllowed=!1,o.minDistance=r.selectMinDistance||0,o.autoScroller.isEnabled=r.dragScroll;var i=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return i.emitter.on("pointerdown",n.handlePointerDown),i.emitter.on("dragstart",n.handleDragStart),i.emitter.on("hitupdate",n.handleHitUpdate),i.emitter.on("pointerup",n.handlePointerUp),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t}(Interaction);function getComponentTouchDelay$1(e){var t=e.context.options,n=t.selectLongPressDelay;return null==n&&(n=t.longPressDelay),n}function joinHitsIntoSelection(e,t,n){var r=e.dateSpan,o=t.dateSpan,i=[r.range.start,r.range.end,o.range.start,o.range.end];i.sort(compareNumbers);for(var a={},s=0,l=n;s<l.length;s++){var u=(0,l[s])(e,t);if(!1===u)return null;u&&__assign$1(a,u)}return a.range={start:i[0],end:i[3]},a.allDay=r.allDay,a}var EventDragging=function(e){function t(n){var r=e.call(this,n)||this;r.subjectEl=null,r.subjectSeg=null,r.isDragging=!1,r.eventRange=null,r.relevantEvents=null,r.receivingContext=null,r.validMutation=null,r.mutatedRelevantEvents=null,r.handlePointerDown=function(e){var t=e.origEvent.target,n=r,o=n.component,i=n.dragging,a=i.mirror,s=o.context.options,l=o.context;r.subjectEl=e.subjectEl;var u=r.subjectSeg=getElSeg(e.subjectEl),c=(r.eventRange=u.eventRange).instance.instanceId;r.relevantEvents=getRelevantEvents(l.getCurrentData().eventStore,c),i.minDistance=e.isTouch?0:s.eventDragMinDistance,i.delay=e.isTouch&&c!==o.props.eventSelection?getComponentTouchDelay(o):null,s.fixedMirrorParent?a.parentNode=s.fixedMirrorParent:a.parentNode=elementClosest(t,".fc"),a.revertDuration=s.dragRevertDuration;var d=o.isValidSegDownEl(t)&&!elementClosest(t,".fc-event-resizer");i.setIgnoreMove(!d),r.isDragging=d&&e.subjectEl.classList.contains("fc-event-draggable")},r.handleDragStart=function(e){var t=r.component.context,n=r.eventRange,o=n.instance.instanceId;e.isTouch?o!==r.component.props.eventSelection&&t.dispatch({type:"SELECT_EVENT",eventInstanceId:o}):t.dispatch({type:"UNSELECT_EVENT"}),r.isDragging&&(t.calendarApi.unselect(e),t.emitter.trigger("eventDragStart",{el:r.subjectEl,event:new EventApi(t,n.def,n.instance),jsEvent:e.origEvent,view:t.viewApi}))},r.handleHitUpdate=function(e,t){if(r.isDragging){var n=r.relevantEvents,o=r.hitDragging.initialHit,i=r.component.context,a=null,s=null,l=null,u=!1,c={affectedEvents:n,mutatedEvents:createEmptyEventStore(),isEvent:!0};if(e){var d=(a=e.context).options;i===a||d.editable&&d.droppable?(s=computeEventMutation(o,e,a.getCurrentData().pluginHooks.eventDragMutationMassagers))&&(l=applyMutationToEventStore(n,a.getCurrentData().eventUiBases,s,a),c.mutatedEvents=l,isInteractionValid(c,e.dateProfile,a)||(u=!0,s=null,l=null,c.mutatedEvents=createEmptyEventStore())):a=null}r.displayDrag(a,c),u?disableCursor():enableCursor(),t||(i===a&&isHitsEqual(o,e)&&(s=null),r.dragging.setMirrorNeedsRevert(!s),r.dragging.setMirrorIsVisible(!e||!getElRoot(r.subjectEl).querySelector(".fc-event-mirror")),r.receivingContext=a,r.validMutation=s,r.mutatedRelevantEvents=l)}},r.handlePointerUp=function(){r.isDragging||r.cleanup()},r.handleDragEnd=function(e){if(r.isDragging){var t=r.component.context,n=t.viewApi,o=r,i=o.receivingContext,a=o.validMutation,s=r.eventRange.def,l=r.eventRange.instance,u=new EventApi(t,s,l),c=r.relevantEvents,d=r.mutatedRelevantEvents,p=r.hitDragging.finalHit;if(r.clearDrag(),t.emitter.trigger("eventDragStop",{el:r.subjectEl,event:u,jsEvent:e.origEvent,view:n}),a){if(i===t){var f=new EventApi(t,d.defs[s.defId],l?d.instances[l.instanceId]:null);t.dispatch({type:"MERGE_EVENTS",eventStore:d});for(var h={oldEvent:u,event:f,relatedEvents:buildEventApis(d,t,l),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:c})}},g={},m=0,v=t.getCurrentData().pluginHooks.eventDropTransformers;m<v.length;m++){var y=v[m];__assign$1(g,y(a,t))}t.emitter.trigger("eventDrop",__assign$1(__assign$1(__assign$1({},h),g),{el:e.subjectEl,delta:a.datesDelta,jsEvent:e.origEvent,view:n})),t.emitter.trigger("eventChange",h)}else if(i){var E={event:u,relatedEvents:buildEventApis(c,t,l),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:c})}};t.emitter.trigger("eventLeave",__assign$1(__assign$1({},E),{draggedEl:e.subjectEl,view:n})),t.dispatch({type:"REMOVE_EVENTS",eventStore:c}),t.emitter.trigger("eventRemove",E);var S=d.defs[s.defId],D=d.instances[l.instanceId],T=new EventApi(i,S,D);i.dispatch({type:"MERGE_EVENTS",eventStore:d});var b={event:T,relatedEvents:buildEventApis(d,i,D),revert:function(){i.dispatch({type:"REMOVE_EVENTS",eventStore:d})}};i.emitter.trigger("eventAdd",b),e.isTouch&&i.dispatch({type:"SELECT_EVENT",eventInstanceId:l.instanceId}),i.emitter.trigger("drop",__assign$1(__assign$1({},buildDatePointApiWithContext(p.dateSpan,i)),{draggedEl:e.subjectEl,jsEvent:e.origEvent,view:p.context.viewApi})),i.emitter.trigger("eventReceive",__assign$1(__assign$1({},b),{draggedEl:e.subjectEl,view:p.context.viewApi}))}}else t.emitter.trigger("_noEventDrop")}r.cleanup()};var o=r.component.context.options,i=r.dragging=new FeaturefulElementDragging(n.el);i.pointer.selector=t.SELECTOR,i.touchScrollAllowed=!1,i.autoScroller.isEnabled=o.dragScroll;var a=r.hitDragging=new HitDragging(r.dragging,interactionSettingsStore);return a.useSubjectCenter=n.useEventCenter,a.emitter.on("pointerdown",r.handlePointerDown),a.emitter.on("dragstart",r.handleDragStart),a.emitter.on("hitupdate",r.handleHitUpdate),a.emitter.on("pointerup",r.handlePointerUp),a.emitter.on("dragend",r.handleDragEnd),r}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t.prototype.displayDrag=function(e,t){var n=this.component.context,r=this.receivingContext;r&&r!==e&&(r===n?r.dispatch({type:"SET_EVENT_DRAG",state:{affectedEvents:t.affectedEvents,mutatedEvents:createEmptyEventStore(),isEvent:!0}}):r.dispatch({type:"UNSET_EVENT_DRAG"})),e&&e.dispatch({type:"SET_EVENT_DRAG",state:t})},t.prototype.clearDrag=function(){var e=this.component.context,t=this.receivingContext;t&&t.dispatch({type:"UNSET_EVENT_DRAG"}),e!==t&&e.dispatch({type:"UNSET_EVENT_DRAG"})},t.prototype.cleanup=function(){this.subjectSeg=null,this.isDragging=!1,this.eventRange=null,this.relevantEvents=null,this.receivingContext=null,this.validMutation=null,this.mutatedRelevantEvents=null},t.SELECTOR=".fc-event-draggable, .fc-event-resizable",t}(Interaction);function computeEventMutation(e,t,n){var r=e.dateSpan,o=t.dateSpan,i=r.range.start,a=o.range.start,s={};r.allDay!==o.allDay&&(s.allDay=o.allDay,s.hasEnd=t.context.options.allDayMaintainDuration,o.allDay&&(i=startOfDay(i)));var l=diffDates(i,a,e.context.dateEnv,e.componentId===t.componentId?e.largeUnit:null);l.milliseconds&&(s.allDay=!1);for(var u={datesDelta:l,standardProps:s},c=0,d=n;c<d.length;c++){(0,d[c])(u,e,t)}return u}function getComponentTouchDelay(e){var t=e.context.options,n=t.eventLongPressDelay;return null==n&&(n=t.longPressDelay),n}var EventResizing=function(e){function t(t){var n=e.call(this,t)||this;n.draggingSegEl=null,n.draggingSeg=null,n.eventRange=null,n.relevantEvents=null,n.validMutation=null,n.mutatedRelevantEvents=null,n.handlePointerDown=function(e){var t=n.component,r=getElSeg(n.querySegEl(e)),o=n.eventRange=r.eventRange;n.dragging.minDistance=t.context.options.eventDragMinDistance,n.dragging.setIgnoreMove(!n.component.isValidSegDownEl(e.origEvent.target)||e.isTouch&&n.component.props.eventSelection!==o.instance.instanceId)},n.handleDragStart=function(e){var t=n.component.context,r=n.eventRange;n.relevantEvents=getRelevantEvents(t.getCurrentData().eventStore,n.eventRange.instance.instanceId);var o=n.querySegEl(e);n.draggingSegEl=o,n.draggingSeg=getElSeg(o),t.calendarApi.unselect(),t.emitter.trigger("eventResizeStart",{el:o,event:new EventApi(t,r.def,r.instance),jsEvent:e.origEvent,view:t.viewApi})},n.handleHitUpdate=function(e,t,r){var o=n.component.context,i=n.relevantEvents,a=n.hitDragging.initialHit,s=n.eventRange.instance,l=null,u=null,c=!1,d={affectedEvents:i,mutatedEvents:createEmptyEventStore(),isEvent:!0};e&&(e.componentId===a.componentId&&n.isHitComboAllowed&&!n.isHitComboAllowed(a,e)||(l=computeMutation(a,e,r.subjectEl.classList.contains("fc-event-resizer-start"),s.range)));l&&(u=applyMutationToEventStore(i,o.getCurrentData().eventUiBases,l,o),d.mutatedEvents=u,isInteractionValid(d,e.dateProfile,o)||(c=!0,l=null,u=null,d.mutatedEvents=null)),u?o.dispatch({type:"SET_EVENT_RESIZE",state:d}):o.dispatch({type:"UNSET_EVENT_RESIZE"}),c?disableCursor():enableCursor(),t||(l&&isHitsEqual(a,e)&&(l=null),n.validMutation=l,n.mutatedRelevantEvents=u)},n.handleDragEnd=function(e){var t=n.component.context,r=n.eventRange.def,o=n.eventRange.instance,i=new EventApi(t,r,o),a=n.relevantEvents,s=n.mutatedRelevantEvents;if(t.emitter.trigger("eventResizeStop",{el:n.draggingSegEl,event:i,jsEvent:e.origEvent,view:t.viewApi}),n.validMutation){var l=new EventApi(t,s.defs[r.defId],o?s.instances[o.instanceId]:null);t.dispatch({type:"MERGE_EVENTS",eventStore:s});var u={oldEvent:i,event:l,relatedEvents:buildEventApis(s,t,o),revert:function(){t.dispatch({type:"MERGE_EVENTS",eventStore:a})}};t.emitter.trigger("eventResize",__assign$1(__assign$1({},u),{el:n.draggingSegEl,startDelta:n.validMutation.startDelta||createDuration(0),endDelta:n.validMutation.endDelta||createDuration(0),jsEvent:e.origEvent,view:t.viewApi})),t.emitter.trigger("eventChange",u)}else t.emitter.trigger("_noEventResize");n.draggingSeg=null,n.relevantEvents=null,n.validMutation=null};var r=t.component,o=n.dragging=new FeaturefulElementDragging(t.el);o.pointer.selector=".fc-event-resizer",o.touchScrollAllowed=!1,o.autoScroller.isEnabled=r.context.options.dragScroll;var i=n.hitDragging=new HitDragging(n.dragging,interactionSettingsToStore(t));return i.emitter.on("pointerdown",n.handlePointerDown),i.emitter.on("dragstart",n.handleDragStart),i.emitter.on("hitupdate",n.handleHitUpdate),i.emitter.on("dragend",n.handleDragEnd),n}return __extends(t,e),t.prototype.destroy=function(){this.dragging.destroy()},t.prototype.querySegEl=function(e){return elementClosest(e.subjectEl,".fc-event")},t}(Interaction);function computeMutation(e,t,n,r){var o=e.context.dateEnv,i=diffDates(e.dateSpan.range.start,t.dateSpan.range.start,o,e.largeUnit);if(n){if(o.add(r.start,i)<r.end)return{startDelta:i}}else if(o.add(r.end,i)>r.start)return{endDelta:i};return null}var UnselectAuto=function(){function e(e){var t=this;this.context=e,this.isRecentPointerDateSelect=!1,this.matchesCancel=!1,this.matchesEvent=!1,this.onSelect=function(e){e.jsEvent&&(t.isRecentPointerDateSelect=!0)},this.onDocumentPointerDown=function(e){var n=t.context.options.unselectCancel,r=getEventTargetViaRoot(e.origEvent);t.matchesCancel=!!elementClosest(r,n),t.matchesEvent=!!elementClosest(r,EventDragging.SELECTOR)},this.onDocumentPointerUp=function(e){var n=t.context,r=t.documentPointer,o=n.getCurrentData();if(!r.wasTouchScroll){if(o.dateSelection&&!t.isRecentPointerDateSelect){var i=n.options.unselectAuto;!i||i&&t.matchesCancel||n.calendarApi.unselect(e)}o.eventSelection&&!t.matchesEvent&&n.dispatch({type:"UNSELECT_EVENT"})}t.isRecentPointerDateSelect=!1};var n=this.documentPointer=new PointerDragging(document);n.shouldIgnoreMove=!0,n.shouldWatchScroll=!1,n.emitter.on("pointerdown",this.onDocumentPointerDown),n.emitter.on("pointerup",this.onDocumentPointerUp),e.emitter.on("select",this.onSelect)}return e.prototype.destroy=function(){this.context.emitter.off("select",this.onSelect),this.documentPointer.destroy()},e}(),OPTION_REFINERS$1={fixedMirrorParent:identity},LISTENER_REFINERS={dateClick:identity,eventDragStart:identity,eventDragStop:identity,eventDrop:identity,eventResizeStart:identity,eventResizeStop:identity,eventResize:identity,drop:identity,eventReceive:identity,eventLeave:identity};config.dataAttrPrefix="",function(e){function t(t){var n=e.call(this,t)||this;n.shouldIgnoreMove=!1,n.mirrorSelector="",n.currentMirrorEl=null,n.handlePointerDown=function(e){n.emitter.trigger("pointerdown",e),n.shouldIgnoreMove||n.emitter.trigger("dragstart",e)},n.handlePointerMove=function(e){n.shouldIgnoreMove||n.emitter.trigger("dragmove",e)},n.handlePointerUp=function(e){n.emitter.trigger("pointerup",e),n.shouldIgnoreMove||n.emitter.trigger("dragend",e)};var r=n.pointer=new PointerDragging(t);return r.emitter.on("pointerdown",n.handlePointerDown),r.emitter.on("pointermove",n.handlePointerMove),r.emitter.on("pointerup",n.handlePointerUp),n}__extends(t,e),t.prototype.destroy=function(){this.pointer.destroy()},t.prototype.setIgnoreMove=function(e){this.shouldIgnoreMove=e},t.prototype.setMirrorIsVisible=function(e){if(e)this.currentMirrorEl&&(this.currentMirrorEl.style.visibility="",this.currentMirrorEl=null);else{var t=this.mirrorSelector?document.querySelector(this.mirrorSelector):null;t&&(this.currentMirrorEl=t,t.style.visibility="hidden")}}}(ElementDragging);var main$1=createPlugin({componentInteractions:[DateClicking,DateSelecting,EventDragging,EventResizing],calendarInteractions:[UnselectAuto],elementDraggingImpl:FeaturefulElementDragging,optionRefiners:OPTION_REFINERS$1,listenerRefiners:LISTENER_REFINERS}),ListViewHeaderRow=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={textId:getUniqueDomId()},t}return __extends(t,e),t.prototype.render=function(){var e=this.context,t=e.theme,n=e.dateEnv,r=e.options,o=e.viewApi,i=this.props,a=i.cellId,s=i.dayDate,l=i.todayRange,u=this.state.textId,c=getDateMeta(s,l),d=r.listDayFormat?n.format(s,r.listDayFormat):"",p=r.listDaySideFormat?n.format(s,r.listDaySideFormat):"",f=__assign$1({date:n.toDate(s),view:o,textId:u,text:d,sideText:p,navLinkAttrs:buildNavLinkAttrs(this.context,s),sideNavLinkAttrs:buildNavLinkAttrs(this.context,s,"day",!1)},c),h=["fc-list-day"].concat(getDayClassNames(c,t));return createElement(RenderHook,{hookProps:f,classNames:r.dayHeaderClassNames,content:r.dayHeaderContent,defaultContent:renderInnerContent,didMount:r.dayHeaderDidMount,willUnmount:r.dayHeaderWillUnmount},(function(e,n,r,o){return createElement("tr",{ref:e,className:h.concat(n).join(" "),"data-date":formatDayString(s)},createElement("th",{scope:"colgroup",colSpan:3,id:a,"aria-labelledby":u},createElement("div",{className:"fc-list-day-cushion "+t.getClass("tableCellShaded"),ref:r},o)))}))},t}(BaseComponent);
19
19
  /*!
20
20
  FullCalendar v5.11.4
21
21
  Docs & License: https://fullcalendar.io/
22
22
  (c) 2022 Adam Shaw
23
- */function renderInnerContent(e){return createElement(Fragment,null,e.text&&createElement("a",__assign$1({id:e.textId,className:"fc-list-day-text"},e.navLinkAttrs),e.text),e.sideText&&createElement("a",__assign$1({"aria-hidden":!0,className:"fc-list-day-side-text"},e.sideNavLinkAttrs),e.sideText))}var DEFAULT_TIME_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",meridiem:"short"}),ListViewEventRow=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=e.seg,r=e.timeHeaderId,o=e.eventHeaderId,i=e.dateHeaderId,a=t.options.eventTimeFormat||DEFAULT_TIME_FORMAT;return createElement(EventRoot,{seg:n,timeText:"",disableDragging:!0,disableResizing:!0,defaultContent:function(){return renderEventInnerContent(n,t)},isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday,isSelected:e.isSelected,isDragging:e.isDragging,isResizing:e.isResizing,isDateSelecting:e.isDateSelecting},(function(e,s,l,u,c){return createElement("tr",{className:["fc-list-event",c.event.url?"fc-event-forced-url":""].concat(s).join(" "),ref:e},buildTimeContent(n,a,t,r,i),createElement("td",{"aria-hidden":!0,className:"fc-list-event-graphic"},createElement("span",{className:"fc-list-event-dot",style:{borderColor:c.borderColor||c.backgroundColor}})),createElement("td",{ref:l,headers:o+" "+i,className:"fc-list-event-title"},u))}))},t}(BaseComponent);function renderEventInnerContent(e,t){var n=getSegAnchorAttrs(e,t);return createElement("a",__assign$1({},n),e.eventRange.def.title)}function buildTimeContent(e,t,n,r,o){var i=n.options;if(!1!==i.displayEventTime){var a=e.eventRange.def,s=e.eventRange.instance,l=!1,u=void 0;if(a.allDay?l=!0:isMultiDayRange(e.eventRange.range)?e.isStart?u=buildSegTimeText(e,t,n,null,null,s.range.start,e.end):e.isEnd?u=buildSegTimeText(e,t,n,null,null,e.start,s.range.end):l=!0:u=buildSegTimeText(e,t,n),l){var c={text:n.options.allDayText,view:n.viewApi};return createElement(RenderHook,{hookProps:c,classNames:i.allDayClassNames,content:i.allDayContent,defaultContent:renderAllDayInner,didMount:i.allDayDidMount,willUnmount:i.allDayWillUnmount},(function(e,t,n,i){return createElement("td",{ref:e,headers:r+" "+o,className:["fc-list-event-time"].concat(t).join(" ")},i)}))}return createElement("td",{className:"fc-list-event-time"},u)}return null}function renderAllDayInner(e){return e.text}var ListView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.computeDateVars=memoize(computeDateVars),t.eventStoreToSegs=memoize(t._eventStoreToSegs),t.state={timeHeaderId:getUniqueDomId(),eventHeaderId:getUniqueDomId(),dateHeaderIdRoot:getUniqueDomId()},t.setRootEl=function(e){e?t.context.registerInteractiveComponent(t,{el:e}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=["fc-list",n.theme.getClass("table"),!1!==n.options.stickyHeaderDates?"fc-list-sticky":""],o=this.computeDateVars(t.dateProfile),i=o.dayDates,a=o.dayRanges,s=this.eventStoreToSegs(t.eventStore,t.eventUiBases,a);return createElement(ViewRoot,{viewSpec:n.viewSpec,elRef:this.setRootEl},(function(n,o){return createElement("div",{ref:n,className:r.concat(o).join(" ")},createElement(Scroller,{liquid:!t.isHeightAuto,overflowX:t.isHeightAuto?"visible":"hidden",overflowY:t.isHeightAuto?"visible":"auto"},s.length>0?e.renderSegList(s,i):e.renderEmptyMessage()))}))},t.prototype.renderEmptyMessage=function(){var e=this.context,t=e.options,n=e.viewApi,r={text:t.noEventsText,view:n};return createElement(RenderHook,{hookProps:r,classNames:t.noEventsClassNames,content:t.noEventsContent,defaultContent:renderNoEventsInner,didMount:t.noEventsDidMount,willUnmount:t.noEventsWillUnmount},(function(e,t,n,r){return createElement("div",{className:["fc-list-empty"].concat(t).join(" "),ref:e},createElement("div",{className:"fc-list-empty-cushion",ref:n},r))}))},t.prototype.renderSegList=function(e,t){var n=this.context,r=n.theme,o=n.options,i=this.state,a=i.timeHeaderId,s=i.eventHeaderId,l=i.dateHeaderIdRoot,u=groupSegsByDay(e);return createElement(NowTimer,{unit:"day"},(function(e,n){for(var i=[],c=0;c<u.length;c+=1){var d=u[c];if(d){var p=formatDayString(t[c]),f=l+"-"+p;i.push(createElement(ListViewHeaderRow,{key:p,cellId:f,dayDate:t[c],todayRange:n}));for(var h=0,g=d=sortEventSegs(d,o.eventOrder);h<g.length;h++){var v=g[h];i.push(createElement(ListViewEventRow,__assign$1({key:p+":"+v.eventRange.instance.instanceId,seg:v,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:!1,timeHeaderId:a,eventHeaderId:s,dateHeaderId:f},getSegMeta(v,n,e))))}}}return createElement("table",{className:"fc-list-table "+r.getClass("table")},createElement("thead",null,createElement("tr",null,createElement("th",{scope:"col",id:a},o.timeHint),createElement("th",{scope:"col","aria-hidden":!0}),createElement("th",{scope:"col",id:s},o.eventHint))),createElement("tbody",null,i))}))},t.prototype._eventStoreToSegs=function(e,t,n){return this.eventRangesToSegs(sliceEventStore(e,t,this.props.dateProfile.activeRange,this.context.options.nextDayThreshold).fg,n)},t.prototype.eventRangesToSegs=function(e,t){for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];n.push.apply(n,this.eventRangeToSegs(i,t))}return n},t.prototype.eventRangeToSegs=function(e,t){var n,r,o,i=this.context.dateEnv,a=this.context.options.nextDayThreshold,s=e.range,l=e.def.allDay,u=[];for(n=0;n<t.length;n+=1)if((r=intersectRanges(s,t[n]))&&(o={component:this,eventRange:e,start:r.start,end:r.end,isStart:e.isStart&&r.start.valueOf()===s.start.valueOf(),isEnd:e.isEnd&&r.end.valueOf()===s.end.valueOf(),dayIndex:n},u.push(o),!o.isEnd&&!l&&n+1<t.length&&s.end<i.add(t[n+1].start,a))){o.end=s.end,o.isEnd=!0;break}return u},t}(DateComponent);function renderNoEventsInner(e){return e.text}function computeDateVars(e){for(var t=startOfDay(e.renderRange.start),n=e.renderRange.end,r=[],o=[];t<n;)r.push(t),o.push({start:t,end:addDays(t,1)}),t=addDays(t,1);return{dayDates:r,dayRanges:o}}function groupSegsByDay(e){var t,n,r=[];for(t=0;t<e.length;t+=1)(r[(n=e[t]).dayIndex]||(r[n.dayIndex]=[])).push(n);return r}var OPTION_REFINERS={listDayFormat:createFalsableFormatter,listDaySideFormat:createFalsableFormatter,noEventsClassNames:identity,noEventsContent:identity,noEventsDidMount:identity,noEventsWillUnmount:identity};function createFalsableFormatter(e){return!1===e?null:createFormatter(e)}var main=createPlugin({optionRefiners:OPTION_REFINERS,views:{list:{component:ListView,buttonTextKey:"list",listDayFormat:{month:"long",day:"numeric",year:"numeric"}},listDay:{type:"list",duration:{days:1},listDayFormat:{weekday:"long"}},listWeek:{type:"list",duration:{weeks:1},listDayFormat:{weekday:"long"},listDaySideFormat:{month:"long",day:"numeric",year:"numeric"}},listMonth:{type:"list",duration:{month:1},listDaySideFormat:{weekday:"long"}},listYear:{type:"list",duration:{year:1},listDaySideFormat:{weekday:"long"}}}}),commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==global?global:"undefined"!=typeof self?self:{},localesAll$1={};Object.defineProperty(localesAll$1,"__esModule",{value:!0});var l0={code:"af",week:{dow:1,doy:4},buttonText:{prev:"Vorige",next:"Volgende",today:"Vandag",year:"Jaar",month:"Maand",week:"Week",day:"Dag",list:"Agenda"},allDayText:"Heeldag",moreLinkText:"Addisionele",noEventsText:"Daar is geen gebeurtenisse nie"},l1={code:"ar-dz",week:{dow:0,doy:4},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l2={code:"ar-kw",week:{dow:0,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l3={code:"ar-ly",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l4={code:"ar-ma",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l5={code:"ar-sa",week:{dow:0,doy:6},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l6={code:"ar-tn",week:{dow:1,doy:4},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l7={code:"ar",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l8={code:"az",week:{dow:1,doy:4},buttonText:{prev:"Əvvəl",next:"Sonra",today:"Bu Gün",month:"Ay",week:"Həftə",day:"Gün",list:"Gündəm"},weekText:"Həftə",allDayText:"Bütün Gün",moreLinkText:function(e){return"+ daha çox "+e},noEventsText:"Göstərmək üçün hadisə yoxdur"},l9={code:"bg",week:{dow:1,doy:7},buttonText:{prev:"назад",next:"напред",today:"днес",month:"Месец",week:"Седмица",day:"Ден",list:"График"},allDayText:"Цял ден",moreLinkText:function(e){return"+още "+e},noEventsText:"Няма събития за показване"},l10={code:"bn",week:{dow:0,doy:6},buttonText:{prev:"পেছনে",next:"সামনে",today:"আজ",month:"মাস",week:"সপ্তাহ",day:"দিন",list:"তালিকা"},weekText:"সপ্তাহ",allDayText:"সারাদিন",moreLinkText:function(e){return"+অন্যান্য "+e},noEventsText:"কোনো ইভেন্ট নেই"},l11={code:"bs",week:{dow:1,doy:7},buttonText:{prev:"Prošli",next:"Sljedeći",today:"Danas",month:"Mjesec",week:"Sedmica",day:"Dan",list:"Raspored"},weekText:"Sed",allDayText:"Cijeli dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nema događaja za prikazivanje"},l12={code:"ca",week:{dow:1,doy:4},buttonText:{prev:"Anterior",next:"Següent",today:"Avui",month:"Mes",week:"Setmana",day:"Dia",list:"Agenda"},weekText:"Set",allDayText:"Tot el dia",moreLinkText:"més",noEventsText:"No hi ha esdeveniments per mostrar"},l13={code:"cs",week:{dow:1,doy:4},buttonText:{prev:"Dříve",next:"Později",today:"Nyní",month:"Měsíc",week:"Týden",day:"Den",list:"Agenda"},weekText:"Týd",allDayText:"Celý den",moreLinkText:function(e){return"+další: "+e},noEventsText:"Žádné akce k zobrazení"},l14={code:"cy",week:{dow:1,doy:4},buttonText:{prev:"Blaenorol",next:"Nesaf",today:"Heddiw",year:"Blwyddyn",month:"Mis",week:"Wythnos",day:"Dydd",list:"Rhestr"},weekText:"Wythnos",allDayText:"Trwy'r dydd",moreLinkText:"Mwy",noEventsText:"Dim digwyddiadau"},l15={code:"da",week:{dow:1,doy:4},buttonText:{prev:"Forrige",next:"Næste",today:"I dag",month:"Måned",week:"Uge",day:"Dag",list:"Agenda"},weekText:"Uge",allDayText:"Hele dagen",moreLinkText:"flere",noEventsText:"Ingen arrangementer at vise"};function affix$1(e){return"Tag"===e||"Monat"===e?"r":"Jahr"===e?"s":""}var l16={code:"de-at",week:{dow:1,doy:4},buttonText:{prev:"Zurück",next:"Vor",today:"Heute",year:"Jahr",month:"Monat",week:"Woche",day:"Tag",list:"Terminübersicht"},weekText:"KW",weekTextLong:"Woche",allDayText:"Ganztägig",moreLinkText:function(e){return"+ weitere "+e},noEventsText:"Keine Ereignisse anzuzeigen",buttonHints:{prev:function(e){return"Vorherige".concat(affix$1(e)," ").concat(e)},next:function(e){return"Nächste".concat(affix$1(e)," ").concat(e)},today:function(e){return"Tag"===e?"Heute":"Diese".concat(affix$1(e)," ").concat(e)}},viewHint:function(e){return e+("Woche"===e?"n":"Monat"===e?"s":"es")+"ansicht"},navLinkHint:"Gehe zu $0",moreLinkHint:function(e){return"Zeige "+(1===e?"ein weiteres Ereignis":e+" weitere Ereignisse")},closeHint:"Schließen",timeHint:"Uhrzeit",eventHint:"Ereignis"};function affix(e){return"Tag"===e||"Monat"===e?"r":"Jahr"===e?"s":""}var l17={code:"de",week:{dow:1,doy:4},buttonText:{prev:"Zurück",next:"Vor",today:"Heute",year:"Jahr",month:"Monat",week:"Woche",day:"Tag",list:"Terminübersicht"},weekText:"KW",weekTextLong:"Woche",allDayText:"Ganztägig",moreLinkText:function(e){return"+ weitere "+e},noEventsText:"Keine Ereignisse anzuzeigen",buttonHints:{prev:function(e){return"Vorherige".concat(affix(e)," ").concat(e)},next:function(e){return"Nächste".concat(affix(e)," ").concat(e)},today:function(e){return"Tag"===e?"Heute":"Diese".concat(affix(e)," ").concat(e)}},viewHint:function(e){return e+("Woche"===e?"n":"Monat"===e?"s":"es")+"ansicht"},navLinkHint:"Gehe zu $0",moreLinkHint:function(e){return"Zeige "+(1===e?"ein weiteres Ereignis":e+" weitere Ereignisse")},closeHint:"Schließen",timeHint:"Uhrzeit",eventHint:"Ereignis"},l18={code:"el",week:{dow:1,doy:4},buttonText:{prev:"Προηγούμενος",next:"Επόμενος",today:"Σήμερα",month:"Μήνας",week:"Εβδομάδα",day:"Ημέρα",list:"Ατζέντα"},weekText:"Εβδ",allDayText:"Ολοήμερο",moreLinkText:"περισσότερα",noEventsText:"Δεν υπάρχουν γεγονότα προς εμφάνιση"},l19={code:"en-au",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l20={code:"en-gb",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l21={code:"en-nz",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l22={code:"eo",week:{dow:1,doy:4},buttonText:{prev:"Antaŭa",next:"Sekva",today:"Hodiaŭ",month:"Monato",week:"Semajno",day:"Tago",list:"Tagordo"},weekText:"Sm",allDayText:"Tuta tago",moreLinkText:"pli",noEventsText:"Neniuj eventoj por montri"},l23={code:"es",week:{dow:0,doy:6},buttonText:{prev:"Ant",next:"Sig",today:"Hoy",month:"Mes",week:"Semana",day:"Día",list:"Agenda"},weekText:"Sm",allDayText:"Todo el día",moreLinkText:"más",noEventsText:"No hay eventos para mostrar"},l24={code:"es",week:{dow:1,doy:4},buttonText:{prev:"Ant",next:"Sig",today:"Hoy",month:"Mes",week:"Semana",day:"Día",list:"Agenda"},buttonHints:{prev:"$0 antes",next:"$0 siguiente",today:function(e){return"Día"===e?"Hoy":("Semana"===e?"Esta":"Este")+" "+e.toLocaleLowerCase()}},viewHint:function(e){return"Vista "+("Semana"===e?"de la":"del")+" "+e.toLocaleLowerCase()},weekText:"Sm",weekTextLong:"Semana",allDayText:"Todo el día",moreLinkText:"más",moreLinkHint:function(e){return"Mostrar ".concat(e," eventos más")},noEventsText:"No hay eventos para mostrar",navLinkHint:"Ir al $0",closeHint:"Cerrar",timeHint:"La hora",eventHint:"Evento"},l25={code:"et",week:{dow:1,doy:4},buttonText:{prev:"Eelnev",next:"Järgnev",today:"Täna",month:"Kuu",week:"Nädal",day:"Päev",list:"Päevakord"},weekText:"näd",allDayText:"Kogu päev",moreLinkText:function(e){return"+ veel "+e},noEventsText:"Kuvamiseks puuduvad sündmused"},l26={code:"eu",week:{dow:1,doy:7},buttonText:{prev:"Aur",next:"Hur",today:"Gaur",month:"Hilabetea",week:"Astea",day:"Eguna",list:"Agenda"},weekText:"As",allDayText:"Egun osoa",moreLinkText:"gehiago",noEventsText:"Ez dago ekitaldirik erakusteko"},l27={code:"fa",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"قبلی",next:"بعدی",today:"امروز",month:"ماه",week:"هفته",day:"روز",list:"برنامه"},weekText:"هف",allDayText:"تمام روز",moreLinkText:function(e){return"بیش از "+e},noEventsText:"هیچ رویدادی به نمایش"},l28={code:"fi",week:{dow:1,doy:4},buttonText:{prev:"Edellinen",next:"Seuraava",today:"Tänään",month:"Kuukausi",week:"Viikko",day:"Päivä",list:"Tapahtumat"},weekText:"Vk",allDayText:"Koko päivä",moreLinkText:"lisää",noEventsText:"Ei näytettäviä tapahtumia"},l29={code:"fr",buttonText:{prev:"Précédent",next:"Suivant",today:"Aujourd'hui",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Mon planning"},weekText:"Sem.",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l30={code:"fr-ch",week:{dow:1,doy:4},buttonText:{prev:"Précédent",next:"Suivant",today:"Courant",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Mon planning"},weekText:"Sm",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l31={code:"fr",week:{dow:1,doy:4},buttonText:{prev:"Précédent",next:"Suivant",today:"Aujourd'hui",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Planning"},weekText:"Sem.",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l32={code:"gl",week:{dow:1,doy:4},buttonText:{prev:"Ant",next:"Seg",today:"Hoxe",month:"Mes",week:"Semana",day:"Día",list:"Axenda"},weekText:"Sm",allDayText:"Todo o día",moreLinkText:"máis",noEventsText:"Non hai eventos para amosar"},l33={code:"he",direction:"rtl",buttonText:{prev:"הקודם",next:"הבא",today:"היום",month:"חודש",week:"שבוע",day:"יום",list:"סדר יום"},allDayText:"כל היום",moreLinkText:"אחר",noEventsText:"אין אירועים להצגה",weekText:"שבוע"},l34={code:"hi",week:{dow:0,doy:6},buttonText:{prev:"पिछला",next:"अगला",today:"आज",month:"महीना",week:"सप्ताह",day:"दिन",list:"कार्यसूची"},weekText:"हफ्ता",allDayText:"सभी दिन",moreLinkText:function(e){return"+अधिक "+e},noEventsText:"कोई घटनाओं को प्रदर्शित करने के लिए"},l35={code:"hr",week:{dow:1,doy:7},buttonText:{prev:"Prijašnji",next:"Sljedeći",today:"Danas",month:"Mjesec",week:"Tjedan",day:"Dan",list:"Raspored"},weekText:"Tje",allDayText:"Cijeli dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nema događaja za prikaz"},l36={code:"hu",week:{dow:1,doy:4},buttonText:{prev:"vissza",next:"előre",today:"ma",month:"Hónap",week:"Hét",day:"Nap",list:"Lista"},weekText:"Hét",allDayText:"Egész nap",moreLinkText:"további",noEventsText:"Nincs megjeleníthető esemény"},l37={code:"hy-am",week:{dow:1,doy:4},buttonText:{prev:"Նախորդ",next:"Հաջորդ",today:"Այսօր",month:"Ամիս",week:"Շաբաթ",day:"Օր",list:"Օրվա ցուցակ"},weekText:"Շաբ",allDayText:"Ամբողջ օր",moreLinkText:function(e){return"+ ևս "+e},noEventsText:"Բացակայում է իրադարձությունը ցուցադրելու"},l38={code:"id",week:{dow:1,doy:7},buttonText:{prev:"mundur",next:"maju",today:"hari ini",month:"Bulan",week:"Minggu",day:"Hari",list:"Agenda"},weekText:"Mg",allDayText:"Sehari penuh",moreLinkText:"lebih",noEventsText:"Tidak ada acara untuk ditampilkan"},l39={code:"is",week:{dow:1,doy:4},buttonText:{prev:"Fyrri",next:"Næsti",today:"Í dag",month:"Mánuður",week:"Vika",day:"Dagur",list:"Dagskrá"},weekText:"Vika",allDayText:"Allan daginn",moreLinkText:"meira",noEventsText:"Engir viðburðir til að sýna"},l40={code:"it",week:{dow:1,doy:4},buttonText:{prev:"Prec",next:"Succ",today:"Oggi",month:"Mese",week:"Settimana",day:"Giorno",list:"Agenda"},weekText:"Sm",allDayText:"Tutto il giorno",moreLinkText:function(e){return"+altri "+e},noEventsText:"Non ci sono eventi da visualizzare"},l41={code:"ja",buttonText:{prev:"前",next:"次",today:"今日",month:"月",week:"週",day:"日",list:"予定リスト"},weekText:"週",allDayText:"終日",moreLinkText:function(e){return"他 "+e+" 件"},noEventsText:"表示する予定はありません"},l42={code:"ka",week:{dow:1,doy:7},buttonText:{prev:"წინა",next:"შემდეგი",today:"დღეს",month:"თვე",week:"კვირა",day:"დღე",list:"დღის წესრიგი"},weekText:"კვ",allDayText:"მთელი დღე",moreLinkText:function(e){return"+ კიდევ "+e},noEventsText:"ღონისძიებები არ არის"},l43={code:"kk",week:{dow:1,doy:7},buttonText:{prev:"Алдыңғы",next:"Келесі",today:"Бүгін",month:"Ай",week:"Апта",day:"Күн",list:"Күн тәртібі"},weekText:"Не",allDayText:"Күні бойы",moreLinkText:function(e){return"+ тағы "+e},noEventsText:"Көрсету үшін оқиғалар жоқ"},l44={code:"km",week:{dow:1,doy:4},buttonText:{prev:"មុន",next:"បន្ទាប់",today:"ថ្ងៃនេះ",year:"ឆ្នាំ",month:"ខែ",week:"សប្តាហ៍",day:"ថ្ងៃ",list:"បញ្ជី"},weekText:"សប្តាហ៍",allDayText:"ពេញមួយថ្ងៃ",moreLinkText:"ច្រើនទៀត",noEventsText:"គ្មានព្រឹត្តិការណ៍ត្រូវបង្ហាញ"},l45={code:"ko",buttonText:{prev:"이전달",next:"다음달",today:"오늘",month:"월",week:"주",day:"일",list:"일정목록"},weekText:"주",allDayText:"종일",moreLinkText:"개",noEventsText:"일정이 없습니다"},l46={code:"ku",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"پێشتر",next:"دواتر",today:"ئەمڕو",month:"مانگ",week:"هەفتە",day:"ڕۆژ",list:"بەرنامە"},weekText:"هەفتە",allDayText:"هەموو ڕۆژەکە",moreLinkText:"زیاتر",noEventsText:"هیچ ڕووداوێك نیە"},l47={code:"lb",week:{dow:1,doy:4},buttonText:{prev:"Zréck",next:"Weider",today:"Haut",month:"Mount",week:"Woch",day:"Dag",list:"Terminiwwersiicht"},weekText:"W",allDayText:"Ganzen Dag",moreLinkText:"méi",noEventsText:"Nee Evenementer ze affichéieren"},l48={code:"lt",week:{dow:1,doy:4},buttonText:{prev:"Atgal",next:"Pirmyn",today:"Šiandien",month:"Mėnuo",week:"Savaitė",day:"Diena",list:"Darbotvarkė"},weekText:"SAV",allDayText:"Visą dieną",moreLinkText:"daugiau",noEventsText:"Nėra įvykių rodyti"},l49={code:"lv",week:{dow:1,doy:4},buttonText:{prev:"Iepr.",next:"Nāk.",today:"Šodien",month:"Mēnesis",week:"Nedēļa",day:"Diena",list:"Dienas kārtība"},weekText:"Ned.",allDayText:"Visu dienu",moreLinkText:function(e){return"+vēl "+e},noEventsText:"Nav notikumu"},l50={code:"mk",buttonText:{prev:"претходно",next:"следно",today:"Денес",month:"Месец",week:"Недела",day:"Ден",list:"График"},weekText:"Сед",allDayText:"Цел ден",moreLinkText:function(e){return"+повеќе "+e},noEventsText:"Нема настани за прикажување"},l51={code:"ms",week:{dow:1,doy:7},buttonText:{prev:"Sebelum",next:"Selepas",today:"hari ini",month:"Bulan",week:"Minggu",day:"Hari",list:"Agenda"},weekText:"Mg",allDayText:"Sepanjang hari",moreLinkText:function(e){return"masih ada "+e+" acara"},noEventsText:"Tiada peristiwa untuk dipaparkan"},l52={code:"nb",week:{dow:1,doy:4},buttonText:{prev:"Forrige",next:"Neste",today:"I dag",month:"Måned",week:"Uke",day:"Dag",list:"Agenda"},weekText:"Uke",weekTextLong:"Uke",allDayText:"Hele dagen",moreLinkText:"til",noEventsText:"Ingen hendelser å vise",buttonHints:{prev:"Forrige $0",next:"Neste $0",today:"Nåværende $0"},viewHint:"$0 visning",navLinkHint:"Gå til $0",moreLinkHint:function(e){return"Vis ".concat(e," flere hendelse").concat(1===e?"":"r")}},l53={code:"ne",week:{dow:7,doy:1},buttonText:{prev:"अघिल्लो",next:"अर्को",today:"आज",month:"महिना",week:"हप्ता",day:"दिन",list:"सूची"},weekText:"हप्ता",allDayText:"दिनभरि",moreLinkText:"थप लिंक",noEventsText:"देखाउनको लागि कुनै घटनाहरू छैनन्"},l54={code:"nl",week:{dow:1,doy:4},buttonText:{prev:"Vorige",next:"Volgende",today:"Vandaag",year:"Jaar",month:"Maand",week:"Week",day:"Dag",list:"Agenda"},allDayText:"Hele dag",moreLinkText:"extra",noEventsText:"Geen evenementen om te laten zien"},l55={code:"nn",week:{dow:1,doy:4},buttonText:{prev:"Førre",next:"Neste",today:"I dag",month:"Månad",week:"Veke",day:"Dag",list:"Agenda"},weekText:"Veke",allDayText:"Heile dagen",moreLinkText:"til",noEventsText:"Ingen hendelser å vise"},l56={code:"pl",week:{dow:1,doy:4},buttonText:{prev:"Poprzedni",next:"Następny",today:"Dziś",month:"Miesiąc",week:"Tydzień",day:"Dzień",list:"Plan dnia"},weekText:"Tydz",allDayText:"Cały dzień",moreLinkText:"więcej",noEventsText:"Brak wydarzeń do wyświetlenia"},l57={code:"pt-br",buttonText:{prev:"Anterior",next:"Próximo",today:"Hoje",month:"Mês",week:"Semana",day:"Dia",list:"Lista"},weekText:"Sm",allDayText:"dia inteiro",moreLinkText:function(e){return"mais +"+e},noEventsText:"Não há eventos para mostrar"},l58={code:"pt",week:{dow:1,doy:4},buttonText:{prev:"Anterior",next:"Seguinte",today:"Hoje",month:"Mês",week:"Semana",day:"Dia",list:"Agenda"},weekText:"Sem",allDayText:"Todo o dia",moreLinkText:"mais",noEventsText:"Não há eventos para mostrar"},l59={code:"ro",week:{dow:1,doy:7},buttonText:{prev:"precedentă",next:"următoare",today:"Azi",month:"Lună",week:"Săptămână",day:"Zi",list:"Agendă"},weekText:"Săpt",allDayText:"Toată ziua",moreLinkText:function(e){return"+alte "+e},noEventsText:"Nu există evenimente de afișat"},l60={code:"ru",week:{dow:1,doy:4},buttonText:{prev:"Пред",next:"След",today:"Сегодня",month:"Месяц",week:"Неделя",day:"День",list:"Повестка дня"},weekText:"Нед",allDayText:"Весь день",moreLinkText:function(e){return"+ ещё "+e},noEventsText:"Нет событий для отображения"},l61={code:"si-lk",week:{dow:1,doy:4},buttonText:{prev:"පෙර",next:"පසු",today:"අද",month:"මාසය",week:"සතිය",day:"දවස",list:"ලැයිස්තුව"},weekText:"සති",allDayText:"සියලු",moreLinkText:"තවත්",noEventsText:"මුකුත් නැත"},l62={code:"sk",week:{dow:1,doy:4},buttonText:{prev:"Predchádzajúci",next:"Nasledujúci",today:"Dnes",month:"Mesiac",week:"Týždeň",day:"Deň",list:"Rozvrh"},weekText:"Ty",allDayText:"Celý deň",moreLinkText:function(e){return"+ďalšie: "+e},noEventsText:"Žiadne akcie na zobrazenie"},l63={code:"sl",week:{dow:1,doy:7},buttonText:{prev:"Prejšnji",next:"Naslednji",today:"Trenutni",month:"Mesec",week:"Teden",day:"Dan",list:"Dnevni red"},weekText:"Teden",allDayText:"Ves dan",moreLinkText:"več",noEventsText:"Ni dogodkov za prikaz"},l64={code:"sm",buttonText:{prev:"Talu ai",next:"Mulimuli atu",today:"Aso nei",month:"Masina",week:"Vaiaso",day:"Aso",list:"Faasologa"},weekText:"Vaiaso",allDayText:"Aso atoa",moreLinkText:"sili atu",noEventsText:"Leai ni mea na tutupu"},l65={code:"sq",week:{dow:1,doy:4},buttonText:{prev:"mbrapa",next:"Përpara",today:"sot",month:"Muaj",week:"Javë",day:"Ditë",list:"Listë"},weekText:"Ja",allDayText:"Gjithë ditën",moreLinkText:function(e){return"+më tepër "+e},noEventsText:"Nuk ka evente për të shfaqur"},l66={code:"sr-cyrl",week:{dow:1,doy:7},buttonText:{prev:"Претходна",next:"следећи",today:"Данас",month:"Месец",week:"Недеља",day:"Дан",list:"Планер"},weekText:"Сед",allDayText:"Цео дан",moreLinkText:function(e){return"+ још "+e},noEventsText:"Нема догађаја за приказ"},l67={code:"sr",week:{dow:1,doy:7},buttonText:{prev:"Prethodna",next:"Sledeći",today:"Danas",month:"Mеsеc",week:"Nеdеlja",day:"Dan",list:"Planеr"},weekText:"Sed",allDayText:"Cеo dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nеma događaja za prikaz"},l68={code:"sv",week:{dow:1,doy:4},buttonText:{prev:"Förra",next:"Nästa",today:"Idag",month:"Månad",week:"Vecka",day:"Dag",list:"Program"},buttonHints:{prev:function(e){return"Föregående ".concat(e.toLocaleLowerCase())},next:function(e){return"Nästa ".concat(e.toLocaleLowerCase())},today:function(e){return("Program"===e?"Detta":"Denna")+" "+e.toLocaleLowerCase()}},viewHint:"$0 vy",navLinkHint:"Gå till $0",moreLinkHint:function(e){return"Visa ytterligare ".concat(e," händelse").concat(1===e?"":"r")},weekText:"v.",weekTextLong:"Vecka",allDayText:"Heldag",moreLinkText:"till",noEventsText:"Inga händelser att visa",closeHint:"Stäng",timeHint:"Klockan",eventHint:"Händelse"},l69={code:"ta-in",week:{dow:1,doy:4},buttonText:{prev:"முந்தைய",next:"அடுத்தது",today:"இன்று",month:"மாதம்",week:"வாரம்",day:"நாள்",list:"தினசரி அட்டவணை"},weekText:"வாரம்",allDayText:"நாள் முழுவதும்",moreLinkText:function(e){return"+ மேலும் "+e},noEventsText:"காண்பிக்க நிகழ்வுகள் இல்லை"},l70={code:"th",week:{dow:1,doy:4},buttonText:{prev:"ก่อนหน้า",next:"ถัดไป",prevYear:"ปีก่อนหน้า",nextYear:"ปีถัดไป",year:"ปี",today:"วันนี้",month:"เดือน",week:"สัปดาห์",day:"วัน",list:"กำหนดการ"},weekText:"สัปดาห์",allDayText:"ตลอดวัน",moreLinkText:"เพิ่มเติม",noEventsText:"ไม่มีกิจกรรมที่จะแสดง"},l71={code:"tr",week:{dow:1,doy:7},buttonText:{prev:"geri",next:"ileri",today:"bugün",month:"Ay",week:"Hafta",day:"Gün",list:"Ajanda"},weekText:"Hf",allDayText:"Tüm gün",moreLinkText:"daha fazla",noEventsText:"Gösterilecek etkinlik yok"},l72={code:"ug",buttonText:{month:"ئاي",week:"ھەپتە",day:"كۈن",list:"كۈنتەرتىپ"},allDayText:"پۈتۈن كۈن"},l73={code:"uk",week:{dow:1,doy:7},buttonText:{prev:"Попередній",next:"далі",today:"Сьогодні",month:"Місяць",week:"Тиждень",day:"День",list:"Порядок денний"},weekText:"Тиж",allDayText:"Увесь день",moreLinkText:function(e){return"+ще "+e+"..."},noEventsText:"Немає подій для відображення"},l74={code:"uz",buttonText:{month:"Oy",week:"Xafta",day:"Kun",list:"Kun tartibi"},allDayText:"Kun bo'yi",moreLinkText:function(e){return"+ yana "+e},noEventsText:"Ko'rsatish uchun voqealar yo'q"},l75={code:"vi",week:{dow:1,doy:4},buttonText:{prev:"Trước",next:"Tiếp",today:"Hôm nay",month:"Tháng",week:"Tuần",day:"Ngày",list:"Lịch biểu"},weekText:"Tu",allDayText:"Cả ngày",moreLinkText:function(e){return"+ thêm "+e},noEventsText:"Không có sự kiện để hiển thị"},l76={code:"zh-cn",week:{dow:1,doy:4},buttonText:{prev:"上月",next:"下月",today:"今天",month:"月",week:"周",day:"日",list:"日程"},weekText:"周",allDayText:"全天",moreLinkText:function(e){return"另外 "+e+" 个"},noEventsText:"没有事件显示"},l77={code:"zh-tw",buttonText:{prev:"上月",next:"下月",today:"今天",month:"月",week:"週",day:"天",list:"活動列表"},weekText:"周",allDayText:"整天",moreLinkText:"顯示更多",noEventsText:"没有任何活動"},localesAll=[l0,l1,l2,l3,l4,l5,l6,l7,l8,l9,l10,l11,l12,l13,l14,l15,l16,l17,l18,l19,l20,l21,l22,l23,l24,l25,l26,l27,l28,l29,l30,l31,l32,l33,l34,l35,l36,l37,l38,l39,l40,l41,l42,l43,l44,l45,l46,l47,l48,l49,l50,l51,l52,l53,l54,l55,l56,l57,l58,l59,l60,l61,l62,l63,l64,l65,l66,l67,l68,l69,l70,l71,l72,l73,l74,l75,l76,l77],_default=localesAll$1.default=localesAll,freeGlobal$1="object"==typeof commonjsGlobal&&commonjsGlobal&&commonjsGlobal.Object===Object&&commonjsGlobal,_freeGlobal=freeGlobal$1,freeGlobal=_freeGlobal,freeSelf="object"==typeof self&&self&&self.Object===Object&&self,root$1=freeGlobal||freeSelf||Function("return this")(),_root=root$1,root=_root,Symbol$3=root.Symbol,_Symbol=Symbol$3,Symbol$2=_Symbol;Symbol$2&&Symbol$2.toStringTag;var Symbol$1=_Symbol;Symbol$1&&Symbol$1.toStringTag;var funcProto=Function.prototype,funcToString=funcProto.toString;funcToString.call(Object);const getBuilderContext=()=>"undefined"==typeof window?{}:Builder.settings.context?Builder.settings.context:Builder.settings;async function fetchAPI(e,t={credentials:"include"}){const n={"Content-Type":"application/json"},r=getAuthorization();r&&(n.Authorization=r),t.headers=Object.assign({},n,t.headers),t.credentials="include";const o=await fetch(`${getRootUrl()}${e}`,t);if(401===o.status)throw new Error(401);const i=await o.json();if(i.errors)throw console.error(i.errors),new Error("Failed to fetch API");return i}function getAuthorization(){try{const e=getBuilderContext();let t=e.tenantId,n=e.authToken;return t&&n?`Bearer ${t},${n}`:null}catch(e){console.error(e)}}function getRootUrl(e){const t=getBuilderContext();if(t.rootUrl)return t.rootUrl;const n="undefined"!=typeof window?window.localStorage.getItem("steedos:rootUrl"):"";return n||e}let UI_SCHEMA_CACHE={},UISchemaFunction;"undefined"!=typeof window&&(window.UI_SCHEMA_CACHE||(window.UI_SCHEMA_CACHE=UI_SCHEMA_CACHE),UI_SCHEMA_CACHE=window.UI_SCHEMA_CACHE);const setUISchemaCache=(e,t)=>{UI_SCHEMA_CACHE[e]=t},getUISchemaCache=e=>___default.cloneDeep(UI_SCHEMA_CACHE[e]),hasUISchemaCache=e=>___default.has(UI_SCHEMA_CACHE,e);function formatUISchemaCache(objectName,uiSchema){setUISchemaCache(objectName,uiSchema),___default.each(uiSchema.fields,(field=>{try{"lookup"===field.type&&field._reference_to&&___default__default.default.isString(field._reference_to)&&(field.reference_to=eval(`(${field._reference_to})`)())}catch(e){field.reference_to=void 0,console.error(e)}})),___default.each(uiSchema.list_views,((e,t)=>{e.name=t,___default.has(e,"columns")||(e.columns=uiSchema.list_views.all.columns)}))}async function getUISchema(e,t){if(!e)return;if(hasUISchemaCache(e)&&!t)return getUISchemaCache(e);let n=null;try{if(UISchemaFunction);else{const t=`/service/api/@${e.replace(/\./g,"_")}/uiSchema`;n=await fetchAPI(t,{method:"get"})}if(!n)return;formatUISchemaCache(e,n)}catch(t){console.error("getUISchema",e,t),setUISchemaCache(e,null)}return getUISchemaCache(e)}function getUISchemaSync(e,t){if(!e)return;if(hasUISchemaCache(e)&&!t)return getUISchemaCache(e);let n=null;try{const t=`/service/api/@${e.replace(/\./g,"_")}/uiSchema`;if(n=Steedos.authRequest(t,{type:"GET",async:!1}),!n)return;formatUISchemaCache(e,n)}catch(t){console.error("getUISchema",e,t),setUISchemaCache(e,null)}return getUISchemaCache(e)}"undefined"!=typeof window&&(window.getUISchema=getUISchema,window.getUISchemaSync=getUISchemaSync);var __assign=function(){return __assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},__assign.apply(this,arguments)};function createObject(e,t,n){e&&Object.isFrozen(e)&&(e=cloneObject(e));var r=e?Object.create(e,__assign(__assign({},n),{__super:{value:e,writable:!1,enumerable:!1}})):Object.create(Object.prototype,n);return t&&isObject(t)&&Object.keys(t).forEach((function(e){return r[e]=t[e]})),r}function cloneObject(e,t){void 0===t&&(t=!0);var n=e&&e.__super?Object.create(e.__super,{__super:{value:e.__super,writable:!1,enumerable:!1}}):Object.create(Object.prototype);return t&&e&&Object.keys(e).forEach((function(t){return n[t]=e[t]})),n}function isObject(e){var t=typeof e;return e&&"string"!==t&&"number"!==t&&"boolean"!==t&&"function"!==t&&!Array.isArray(e)}var FullCalendar=function(e){var t=e.dispatchEvent,n=e.data,r=__rest(e,["dispatchEvent","data"]),o=function(e,r){return __awaiter(void 0,void 0,void 0,(function(){var o,i;return __generator(this,(function(a){switch(a.label){case 0:return t?[4,t(e,r?createObject(n,r):n)]:[2];case 1:return o=a.sent(),[2,null!==(i=null==o?void 0:o.prevented)&&void 0!==i&&i]}}))}))};return React__default.default.createElement(FullCalendar$1,__assign$1({plugins:[main$3,main$2,main$1,main],headerToolbar:{left:"title",center:"",right:"prev,next today dayGridMonth,timeGridWeek,timeGridDay,listWeek"},locales:_default,locale:"zh-cn",editable:!0,selectable:!0,selectMirror:!0,dayMaxEvents:!0,initialView:"timeGridWeek",events:function(e,t,n){setTimeout((function(){o("getEvents",{fetchInfo:e,successCallback:t,failureCallback:n})}),100)},select:function(e){o("select",e)},eventClick:function(e){o("eventClick",e)},eventsSet:function(e){o("eventsSet",e)},eventAdd:function(e){o("eventAdd",e)},eventChange:function(e){o("eventChange",e)},eventRemove:function(e){o("eventRemove",e)},eventDidMount:function(e){o("eventDidMount",e)},eventWillUnmount:function(e){o("eventWillUnmount",e)},noEventsDidMount:function(e){o("noEventsDidMount",e)},noEventsWillUnmount:function(e){o("noEventsWillUnmount",e)},forceEventDuration:!0,views:{listWeek:{buttonText:"列表"}}},r))};exports.FullCalendar=FullCalendar,Object.defineProperty(exports,"__esModule",{value:!0})}));
23
+ */function renderInnerContent(e){return createElement(Fragment,null,e.text&&createElement("a",__assign$1({id:e.textId,className:"fc-list-day-text"},e.navLinkAttrs),e.text),e.sideText&&createElement("a",__assign$1({"aria-hidden":!0,className:"fc-list-day-side-text"},e.sideNavLinkAttrs),e.sideText))}var DEFAULT_TIME_FORMAT=createFormatter({hour:"numeric",minute:"2-digit",meridiem:"short"}),ListViewEventRow=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.render=function(){var e=this.props,t=this.context,n=e.seg,r=e.timeHeaderId,o=e.eventHeaderId,i=e.dateHeaderId,a=t.options.eventTimeFormat||DEFAULT_TIME_FORMAT;return createElement(EventRoot,{seg:n,timeText:"",disableDragging:!0,disableResizing:!0,defaultContent:function(){return renderEventInnerContent(n,t)},isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday,isSelected:e.isSelected,isDragging:e.isDragging,isResizing:e.isResizing,isDateSelecting:e.isDateSelecting},(function(e,s,l,u,c){return createElement("tr",{className:["fc-list-event",c.event.url?"fc-event-forced-url":""].concat(s).join(" "),ref:e},buildTimeContent(n,a,t,r,i),createElement("td",{"aria-hidden":!0,className:"fc-list-event-graphic"},createElement("span",{className:"fc-list-event-dot",style:{borderColor:c.borderColor||c.backgroundColor}})),createElement("td",{ref:l,headers:o+" "+i,className:"fc-list-event-title"},u))}))},t}(BaseComponent);function renderEventInnerContent(e,t){var n=getSegAnchorAttrs(e,t);return createElement("a",__assign$1({},n),e.eventRange.def.title)}function buildTimeContent(e,t,n,r,o){var i=n.options;if(!1!==i.displayEventTime){var a=e.eventRange.def,s=e.eventRange.instance,l=!1,u=void 0;if(a.allDay?l=!0:isMultiDayRange(e.eventRange.range)?e.isStart?u=buildSegTimeText(e,t,n,null,null,s.range.start,e.end):e.isEnd?u=buildSegTimeText(e,t,n,null,null,e.start,s.range.end):l=!0:u=buildSegTimeText(e,t,n),l){var c={text:n.options.allDayText,view:n.viewApi};return createElement(RenderHook,{hookProps:c,classNames:i.allDayClassNames,content:i.allDayContent,defaultContent:renderAllDayInner,didMount:i.allDayDidMount,willUnmount:i.allDayWillUnmount},(function(e,t,n,i){return createElement("td",{ref:e,headers:r+" "+o,className:["fc-list-event-time"].concat(t).join(" ")},i)}))}return createElement("td",{className:"fc-list-event-time"},u)}return null}function renderAllDayInner(e){return e.text}var ListView=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.computeDateVars=memoize(computeDateVars),t.eventStoreToSegs=memoize(t._eventStoreToSegs),t.state={timeHeaderId:getUniqueDomId(),eventHeaderId:getUniqueDomId(),dateHeaderIdRoot:getUniqueDomId()},t.setRootEl=function(e){e?t.context.registerInteractiveComponent(t,{el:e}):t.context.unregisterInteractiveComponent(t)},t}return __extends(t,e),t.prototype.render=function(){var e=this,t=this.props,n=this.context,r=["fc-list",n.theme.getClass("table"),!1!==n.options.stickyHeaderDates?"fc-list-sticky":""],o=this.computeDateVars(t.dateProfile),i=o.dayDates,a=o.dayRanges,s=this.eventStoreToSegs(t.eventStore,t.eventUiBases,a);return createElement(ViewRoot,{viewSpec:n.viewSpec,elRef:this.setRootEl},(function(n,o){return createElement("div",{ref:n,className:r.concat(o).join(" ")},createElement(Scroller,{liquid:!t.isHeightAuto,overflowX:t.isHeightAuto?"visible":"hidden",overflowY:t.isHeightAuto?"visible":"auto"},s.length>0?e.renderSegList(s,i):e.renderEmptyMessage()))}))},t.prototype.renderEmptyMessage=function(){var e=this.context,t=e.options,n=e.viewApi,r={text:t.noEventsText,view:n};return createElement(RenderHook,{hookProps:r,classNames:t.noEventsClassNames,content:t.noEventsContent,defaultContent:renderNoEventsInner,didMount:t.noEventsDidMount,willUnmount:t.noEventsWillUnmount},(function(e,t,n,r){return createElement("div",{className:["fc-list-empty"].concat(t).join(" "),ref:e},createElement("div",{className:"fc-list-empty-cushion",ref:n},r))}))},t.prototype.renderSegList=function(e,t){var n=this.context,r=n.theme,o=n.options,i=this.state,a=i.timeHeaderId,s=i.eventHeaderId,l=i.dateHeaderIdRoot,u=groupSegsByDay(e);return createElement(NowTimer,{unit:"day"},(function(e,n){for(var i=[],c=0;c<u.length;c+=1){var d=u[c];if(d){var p=formatDayString(t[c]),f=l+"-"+p;i.push(createElement(ListViewHeaderRow,{key:p,cellId:f,dayDate:t[c],todayRange:n}));for(var h=0,g=d=sortEventSegs(d,o.eventOrder);h<g.length;h++){var m=g[h];i.push(createElement(ListViewEventRow,__assign$1({key:p+":"+m.eventRange.instance.instanceId,seg:m,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:!1,timeHeaderId:a,eventHeaderId:s,dateHeaderId:f},getSegMeta(m,n,e))))}}}return createElement("table",{className:"fc-list-table "+r.getClass("table")},createElement("thead",null,createElement("tr",null,createElement("th",{scope:"col",id:a},o.timeHint),createElement("th",{scope:"col","aria-hidden":!0}),createElement("th",{scope:"col",id:s},o.eventHint))),createElement("tbody",null,i))}))},t.prototype._eventStoreToSegs=function(e,t,n){return this.eventRangesToSegs(sliceEventStore(e,t,this.props.dateProfile.activeRange,this.context.options.nextDayThreshold).fg,n)},t.prototype.eventRangesToSegs=function(e,t){for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];n.push.apply(n,this.eventRangeToSegs(i,t))}return n},t.prototype.eventRangeToSegs=function(e,t){var n,r,o,i=this.context.dateEnv,a=this.context.options.nextDayThreshold,s=e.range,l=e.def.allDay,u=[];for(n=0;n<t.length;n+=1)if((r=intersectRanges(s,t[n]))&&(o={component:this,eventRange:e,start:r.start,end:r.end,isStart:e.isStart&&r.start.valueOf()===s.start.valueOf(),isEnd:e.isEnd&&r.end.valueOf()===s.end.valueOf(),dayIndex:n},u.push(o),!o.isEnd&&!l&&n+1<t.length&&s.end<i.add(t[n+1].start,a))){o.end=s.end,o.isEnd=!0;break}return u},t}(DateComponent);function renderNoEventsInner(e){return e.text}function computeDateVars(e){for(var t=startOfDay(e.renderRange.start),n=e.renderRange.end,r=[],o=[];t<n;)r.push(t),o.push({start:t,end:addDays(t,1)}),t=addDays(t,1);return{dayDates:r,dayRanges:o}}function groupSegsByDay(e){var t,n,r=[];for(t=0;t<e.length;t+=1)(r[(n=e[t]).dayIndex]||(r[n.dayIndex]=[])).push(n);return r}var OPTION_REFINERS={listDayFormat:createFalsableFormatter,listDaySideFormat:createFalsableFormatter,noEventsClassNames:identity,noEventsContent:identity,noEventsDidMount:identity,noEventsWillUnmount:identity};function createFalsableFormatter(e){return!1===e?null:createFormatter(e)}var main=createPlugin({optionRefiners:OPTION_REFINERS,views:{list:{component:ListView,buttonTextKey:"list",listDayFormat:{month:"long",day:"numeric",year:"numeric"}},listDay:{type:"list",duration:{days:1},listDayFormat:{weekday:"long"}},listWeek:{type:"list",duration:{weeks:1},listDayFormat:{weekday:"long"},listDaySideFormat:{month:"long",day:"numeric",year:"numeric"}},listMonth:{type:"list",duration:{month:1},listDaySideFormat:{weekday:"long"}},listYear:{type:"list",duration:{year:1},listDaySideFormat:{weekday:"long"}}}}),commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==global?global:"undefined"!=typeof self?self:{},localesAll$1={};Object.defineProperty(localesAll$1,"__esModule",{value:!0});var l0={code:"af",week:{dow:1,doy:4},buttonText:{prev:"Vorige",next:"Volgende",today:"Vandag",year:"Jaar",month:"Maand",week:"Week",day:"Dag",list:"Agenda"},allDayText:"Heeldag",moreLinkText:"Addisionele",noEventsText:"Daar is geen gebeurtenisse nie"},l1={code:"ar-dz",week:{dow:0,doy:4},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l2={code:"ar-kw",week:{dow:0,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l3={code:"ar-ly",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l4={code:"ar-ma",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l5={code:"ar-sa",week:{dow:0,doy:6},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l6={code:"ar-tn",week:{dow:1,doy:4},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l7={code:"ar",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"السابق",next:"التالي",today:"اليوم",month:"شهر",week:"أسبوع",day:"يوم",list:"أجندة"},weekText:"أسبوع",allDayText:"اليوم كله",moreLinkText:"أخرى",noEventsText:"أي أحداث لعرض"},l8={code:"az",week:{dow:1,doy:4},buttonText:{prev:"Əvvəl",next:"Sonra",today:"Bu Gün",month:"Ay",week:"Həftə",day:"Gün",list:"Gündəm"},weekText:"Həftə",allDayText:"Bütün Gün",moreLinkText:function(e){return"+ daha çox "+e},noEventsText:"Göstərmək üçün hadisə yoxdur"},l9={code:"bg",week:{dow:1,doy:7},buttonText:{prev:"назад",next:"напред",today:"днес",month:"Месец",week:"Седмица",day:"Ден",list:"График"},allDayText:"Цял ден",moreLinkText:function(e){return"+още "+e},noEventsText:"Няма събития за показване"},l10={code:"bn",week:{dow:0,doy:6},buttonText:{prev:"পেছনে",next:"সামনে",today:"আজ",month:"মাস",week:"সপ্তাহ",day:"দিন",list:"তালিকা"},weekText:"সপ্তাহ",allDayText:"সারাদিন",moreLinkText:function(e){return"+অন্যান্য "+e},noEventsText:"কোনো ইভেন্ট নেই"},l11={code:"bs",week:{dow:1,doy:7},buttonText:{prev:"Prošli",next:"Sljedeći",today:"Danas",month:"Mjesec",week:"Sedmica",day:"Dan",list:"Raspored"},weekText:"Sed",allDayText:"Cijeli dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nema događaja za prikazivanje"},l12={code:"ca",week:{dow:1,doy:4},buttonText:{prev:"Anterior",next:"Següent",today:"Avui",month:"Mes",week:"Setmana",day:"Dia",list:"Agenda"},weekText:"Set",allDayText:"Tot el dia",moreLinkText:"més",noEventsText:"No hi ha esdeveniments per mostrar"},l13={code:"cs",week:{dow:1,doy:4},buttonText:{prev:"Dříve",next:"Později",today:"Nyní",month:"Měsíc",week:"Týden",day:"Den",list:"Agenda"},weekText:"Týd",allDayText:"Celý den",moreLinkText:function(e){return"+další: "+e},noEventsText:"Žádné akce k zobrazení"},l14={code:"cy",week:{dow:1,doy:4},buttonText:{prev:"Blaenorol",next:"Nesaf",today:"Heddiw",year:"Blwyddyn",month:"Mis",week:"Wythnos",day:"Dydd",list:"Rhestr"},weekText:"Wythnos",allDayText:"Trwy'r dydd",moreLinkText:"Mwy",noEventsText:"Dim digwyddiadau"},l15={code:"da",week:{dow:1,doy:4},buttonText:{prev:"Forrige",next:"Næste",today:"I dag",month:"Måned",week:"Uge",day:"Dag",list:"Agenda"},weekText:"Uge",allDayText:"Hele dagen",moreLinkText:"flere",noEventsText:"Ingen arrangementer at vise"};function affix$1(e){return"Tag"===e||"Monat"===e?"r":"Jahr"===e?"s":""}var l16={code:"de-at",week:{dow:1,doy:4},buttonText:{prev:"Zurück",next:"Vor",today:"Heute",year:"Jahr",month:"Monat",week:"Woche",day:"Tag",list:"Terminübersicht"},weekText:"KW",weekTextLong:"Woche",allDayText:"Ganztägig",moreLinkText:function(e){return"+ weitere "+e},noEventsText:"Keine Ereignisse anzuzeigen",buttonHints:{prev:function(e){return"Vorherige".concat(affix$1(e)," ").concat(e)},next:function(e){return"Nächste".concat(affix$1(e)," ").concat(e)},today:function(e){return"Tag"===e?"Heute":"Diese".concat(affix$1(e)," ").concat(e)}},viewHint:function(e){return e+("Woche"===e?"n":"Monat"===e?"s":"es")+"ansicht"},navLinkHint:"Gehe zu $0",moreLinkHint:function(e){return"Zeige "+(1===e?"ein weiteres Ereignis":e+" weitere Ereignisse")},closeHint:"Schließen",timeHint:"Uhrzeit",eventHint:"Ereignis"};function affix(e){return"Tag"===e||"Monat"===e?"r":"Jahr"===e?"s":""}var l17={code:"de",week:{dow:1,doy:4},buttonText:{prev:"Zurück",next:"Vor",today:"Heute",year:"Jahr",month:"Monat",week:"Woche",day:"Tag",list:"Terminübersicht"},weekText:"KW",weekTextLong:"Woche",allDayText:"Ganztägig",moreLinkText:function(e){return"+ weitere "+e},noEventsText:"Keine Ereignisse anzuzeigen",buttonHints:{prev:function(e){return"Vorherige".concat(affix(e)," ").concat(e)},next:function(e){return"Nächste".concat(affix(e)," ").concat(e)},today:function(e){return"Tag"===e?"Heute":"Diese".concat(affix(e)," ").concat(e)}},viewHint:function(e){return e+("Woche"===e?"n":"Monat"===e?"s":"es")+"ansicht"},navLinkHint:"Gehe zu $0",moreLinkHint:function(e){return"Zeige "+(1===e?"ein weiteres Ereignis":e+" weitere Ereignisse")},closeHint:"Schließen",timeHint:"Uhrzeit",eventHint:"Ereignis"},l18={code:"el",week:{dow:1,doy:4},buttonText:{prev:"Προηγούμενος",next:"Επόμενος",today:"Σήμερα",month:"Μήνας",week:"Εβδομάδα",day:"Ημέρα",list:"Ατζέντα"},weekText:"Εβδ",allDayText:"Ολοήμερο",moreLinkText:"περισσότερα",noEventsText:"Δεν υπάρχουν γεγονότα προς εμφάνιση"},l19={code:"en-au",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l20={code:"en-gb",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l21={code:"en-nz",week:{dow:1,doy:4},buttonHints:{prev:"Previous $0",next:"Next $0",today:"This $0"},viewHint:"$0 view",navLinkHint:"Go to $0",moreLinkHint:function(e){return"Show ".concat(e," more event").concat(1===e?"":"s")}},l22={code:"eo",week:{dow:1,doy:4},buttonText:{prev:"Antaŭa",next:"Sekva",today:"Hodiaŭ",month:"Monato",week:"Semajno",day:"Tago",list:"Tagordo"},weekText:"Sm",allDayText:"Tuta tago",moreLinkText:"pli",noEventsText:"Neniuj eventoj por montri"},l23={code:"es",week:{dow:0,doy:6},buttonText:{prev:"Ant",next:"Sig",today:"Hoy",month:"Mes",week:"Semana",day:"Día",list:"Agenda"},weekText:"Sm",allDayText:"Todo el día",moreLinkText:"más",noEventsText:"No hay eventos para mostrar"},l24={code:"es",week:{dow:1,doy:4},buttonText:{prev:"Ant",next:"Sig",today:"Hoy",month:"Mes",week:"Semana",day:"Día",list:"Agenda"},buttonHints:{prev:"$0 antes",next:"$0 siguiente",today:function(e){return"Día"===e?"Hoy":("Semana"===e?"Esta":"Este")+" "+e.toLocaleLowerCase()}},viewHint:function(e){return"Vista "+("Semana"===e?"de la":"del")+" "+e.toLocaleLowerCase()},weekText:"Sm",weekTextLong:"Semana",allDayText:"Todo el día",moreLinkText:"más",moreLinkHint:function(e){return"Mostrar ".concat(e," eventos más")},noEventsText:"No hay eventos para mostrar",navLinkHint:"Ir al $0",closeHint:"Cerrar",timeHint:"La hora",eventHint:"Evento"},l25={code:"et",week:{dow:1,doy:4},buttonText:{prev:"Eelnev",next:"Järgnev",today:"Täna",month:"Kuu",week:"Nädal",day:"Päev",list:"Päevakord"},weekText:"näd",allDayText:"Kogu päev",moreLinkText:function(e){return"+ veel "+e},noEventsText:"Kuvamiseks puuduvad sündmused"},l26={code:"eu",week:{dow:1,doy:7},buttonText:{prev:"Aur",next:"Hur",today:"Gaur",month:"Hilabetea",week:"Astea",day:"Eguna",list:"Agenda"},weekText:"As",allDayText:"Egun osoa",moreLinkText:"gehiago",noEventsText:"Ez dago ekitaldirik erakusteko"},l27={code:"fa",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"قبلی",next:"بعدی",today:"امروز",month:"ماه",week:"هفته",day:"روز",list:"برنامه"},weekText:"هف",allDayText:"تمام روز",moreLinkText:function(e){return"بیش از "+e},noEventsText:"هیچ رویدادی به نمایش"},l28={code:"fi",week:{dow:1,doy:4},buttonText:{prev:"Edellinen",next:"Seuraava",today:"Tänään",month:"Kuukausi",week:"Viikko",day:"Päivä",list:"Tapahtumat"},weekText:"Vk",allDayText:"Koko päivä",moreLinkText:"lisää",noEventsText:"Ei näytettäviä tapahtumia"},l29={code:"fr",buttonText:{prev:"Précédent",next:"Suivant",today:"Aujourd'hui",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Mon planning"},weekText:"Sem.",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l30={code:"fr-ch",week:{dow:1,doy:4},buttonText:{prev:"Précédent",next:"Suivant",today:"Courant",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Mon planning"},weekText:"Sm",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l31={code:"fr",week:{dow:1,doy:4},buttonText:{prev:"Précédent",next:"Suivant",today:"Aujourd'hui",year:"Année",month:"Mois",week:"Semaine",day:"Jour",list:"Planning"},weekText:"Sem.",allDayText:"Toute la journée",moreLinkText:"en plus",noEventsText:"Aucun événement à afficher"},l32={code:"gl",week:{dow:1,doy:4},buttonText:{prev:"Ant",next:"Seg",today:"Hoxe",month:"Mes",week:"Semana",day:"Día",list:"Axenda"},weekText:"Sm",allDayText:"Todo o día",moreLinkText:"máis",noEventsText:"Non hai eventos para amosar"},l33={code:"he",direction:"rtl",buttonText:{prev:"הקודם",next:"הבא",today:"היום",month:"חודש",week:"שבוע",day:"יום",list:"סדר יום"},allDayText:"כל היום",moreLinkText:"אחר",noEventsText:"אין אירועים להצגה",weekText:"שבוע"},l34={code:"hi",week:{dow:0,doy:6},buttonText:{prev:"पिछला",next:"अगला",today:"आज",month:"महीना",week:"सप्ताह",day:"दिन",list:"कार्यसूची"},weekText:"हफ्ता",allDayText:"सभी दिन",moreLinkText:function(e){return"+अधिक "+e},noEventsText:"कोई घटनाओं को प्रदर्शित करने के लिए"},l35={code:"hr",week:{dow:1,doy:7},buttonText:{prev:"Prijašnji",next:"Sljedeći",today:"Danas",month:"Mjesec",week:"Tjedan",day:"Dan",list:"Raspored"},weekText:"Tje",allDayText:"Cijeli dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nema događaja za prikaz"},l36={code:"hu",week:{dow:1,doy:4},buttonText:{prev:"vissza",next:"előre",today:"ma",month:"Hónap",week:"Hét",day:"Nap",list:"Lista"},weekText:"Hét",allDayText:"Egész nap",moreLinkText:"további",noEventsText:"Nincs megjeleníthető esemény"},l37={code:"hy-am",week:{dow:1,doy:4},buttonText:{prev:"Նախորդ",next:"Հաջորդ",today:"Այսօր",month:"Ամիս",week:"Շաբաթ",day:"Օր",list:"Օրվա ցուցակ"},weekText:"Շաբ",allDayText:"Ամբողջ օր",moreLinkText:function(e){return"+ ևս "+e},noEventsText:"Բացակայում է իրադարձությունը ցուցադրելու"},l38={code:"id",week:{dow:1,doy:7},buttonText:{prev:"mundur",next:"maju",today:"hari ini",month:"Bulan",week:"Minggu",day:"Hari",list:"Agenda"},weekText:"Mg",allDayText:"Sehari penuh",moreLinkText:"lebih",noEventsText:"Tidak ada acara untuk ditampilkan"},l39={code:"is",week:{dow:1,doy:4},buttonText:{prev:"Fyrri",next:"Næsti",today:"Í dag",month:"Mánuður",week:"Vika",day:"Dagur",list:"Dagskrá"},weekText:"Vika",allDayText:"Allan daginn",moreLinkText:"meira",noEventsText:"Engir viðburðir til að sýna"},l40={code:"it",week:{dow:1,doy:4},buttonText:{prev:"Prec",next:"Succ",today:"Oggi",month:"Mese",week:"Settimana",day:"Giorno",list:"Agenda"},weekText:"Sm",allDayText:"Tutto il giorno",moreLinkText:function(e){return"+altri "+e},noEventsText:"Non ci sono eventi da visualizzare"},l41={code:"ja",buttonText:{prev:"前",next:"次",today:"今日",month:"月",week:"週",day:"日",list:"予定リスト"},weekText:"週",allDayText:"終日",moreLinkText:function(e){return"他 "+e+" 件"},noEventsText:"表示する予定はありません"},l42={code:"ka",week:{dow:1,doy:7},buttonText:{prev:"წინა",next:"შემდეგი",today:"დღეს",month:"თვე",week:"კვირა",day:"დღე",list:"დღის წესრიგი"},weekText:"კვ",allDayText:"მთელი დღე",moreLinkText:function(e){return"+ კიდევ "+e},noEventsText:"ღონისძიებები არ არის"},l43={code:"kk",week:{dow:1,doy:7},buttonText:{prev:"Алдыңғы",next:"Келесі",today:"Бүгін",month:"Ай",week:"Апта",day:"Күн",list:"Күн тәртібі"},weekText:"Не",allDayText:"Күні бойы",moreLinkText:function(e){return"+ тағы "+e},noEventsText:"Көрсету үшін оқиғалар жоқ"},l44={code:"km",week:{dow:1,doy:4},buttonText:{prev:"មុន",next:"បន្ទាប់",today:"ថ្ងៃនេះ",year:"ឆ្នាំ",month:"ខែ",week:"សប្តាហ៍",day:"ថ្ងៃ",list:"បញ្ជី"},weekText:"សប្តាហ៍",allDayText:"ពេញមួយថ្ងៃ",moreLinkText:"ច្រើនទៀត",noEventsText:"គ្មានព្រឹត្តិការណ៍ត្រូវបង្ហាញ"},l45={code:"ko",buttonText:{prev:"이전달",next:"다음달",today:"오늘",month:"월",week:"주",day:"일",list:"일정목록"},weekText:"주",allDayText:"종일",moreLinkText:"개",noEventsText:"일정이 없습니다"},l46={code:"ku",week:{dow:6,doy:12},direction:"rtl",buttonText:{prev:"پێشتر",next:"دواتر",today:"ئەمڕو",month:"مانگ",week:"هەفتە",day:"ڕۆژ",list:"بەرنامە"},weekText:"هەفتە",allDayText:"هەموو ڕۆژەکە",moreLinkText:"زیاتر",noEventsText:"هیچ ڕووداوێك نیە"},l47={code:"lb",week:{dow:1,doy:4},buttonText:{prev:"Zréck",next:"Weider",today:"Haut",month:"Mount",week:"Woch",day:"Dag",list:"Terminiwwersiicht"},weekText:"W",allDayText:"Ganzen Dag",moreLinkText:"méi",noEventsText:"Nee Evenementer ze affichéieren"},l48={code:"lt",week:{dow:1,doy:4},buttonText:{prev:"Atgal",next:"Pirmyn",today:"Šiandien",month:"Mėnuo",week:"Savaitė",day:"Diena",list:"Darbotvarkė"},weekText:"SAV",allDayText:"Visą dieną",moreLinkText:"daugiau",noEventsText:"Nėra įvykių rodyti"},l49={code:"lv",week:{dow:1,doy:4},buttonText:{prev:"Iepr.",next:"Nāk.",today:"Šodien",month:"Mēnesis",week:"Nedēļa",day:"Diena",list:"Dienas kārtība"},weekText:"Ned.",allDayText:"Visu dienu",moreLinkText:function(e){return"+vēl "+e},noEventsText:"Nav notikumu"},l50={code:"mk",buttonText:{prev:"претходно",next:"следно",today:"Денес",month:"Месец",week:"Недела",day:"Ден",list:"График"},weekText:"Сед",allDayText:"Цел ден",moreLinkText:function(e){return"+повеќе "+e},noEventsText:"Нема настани за прикажување"},l51={code:"ms",week:{dow:1,doy:7},buttonText:{prev:"Sebelum",next:"Selepas",today:"hari ini",month:"Bulan",week:"Minggu",day:"Hari",list:"Agenda"},weekText:"Mg",allDayText:"Sepanjang hari",moreLinkText:function(e){return"masih ada "+e+" acara"},noEventsText:"Tiada peristiwa untuk dipaparkan"},l52={code:"nb",week:{dow:1,doy:4},buttonText:{prev:"Forrige",next:"Neste",today:"I dag",month:"Måned",week:"Uke",day:"Dag",list:"Agenda"},weekText:"Uke",weekTextLong:"Uke",allDayText:"Hele dagen",moreLinkText:"til",noEventsText:"Ingen hendelser å vise",buttonHints:{prev:"Forrige $0",next:"Neste $0",today:"Nåværende $0"},viewHint:"$0 visning",navLinkHint:"Gå til $0",moreLinkHint:function(e){return"Vis ".concat(e," flere hendelse").concat(1===e?"":"r")}},l53={code:"ne",week:{dow:7,doy:1},buttonText:{prev:"अघिल्लो",next:"अर्को",today:"आज",month:"महिना",week:"हप्ता",day:"दिन",list:"सूची"},weekText:"हप्ता",allDayText:"दिनभरि",moreLinkText:"थप लिंक",noEventsText:"देखाउनको लागि कुनै घटनाहरू छैनन्"},l54={code:"nl",week:{dow:1,doy:4},buttonText:{prev:"Vorige",next:"Volgende",today:"Vandaag",year:"Jaar",month:"Maand",week:"Week",day:"Dag",list:"Agenda"},allDayText:"Hele dag",moreLinkText:"extra",noEventsText:"Geen evenementen om te laten zien"},l55={code:"nn",week:{dow:1,doy:4},buttonText:{prev:"Førre",next:"Neste",today:"I dag",month:"Månad",week:"Veke",day:"Dag",list:"Agenda"},weekText:"Veke",allDayText:"Heile dagen",moreLinkText:"til",noEventsText:"Ingen hendelser å vise"},l56={code:"pl",week:{dow:1,doy:4},buttonText:{prev:"Poprzedni",next:"Następny",today:"Dziś",month:"Miesiąc",week:"Tydzień",day:"Dzień",list:"Plan dnia"},weekText:"Tydz",allDayText:"Cały dzień",moreLinkText:"więcej",noEventsText:"Brak wydarzeń do wyświetlenia"},l57={code:"pt-br",buttonText:{prev:"Anterior",next:"Próximo",today:"Hoje",month:"Mês",week:"Semana",day:"Dia",list:"Lista"},weekText:"Sm",allDayText:"dia inteiro",moreLinkText:function(e){return"mais +"+e},noEventsText:"Não há eventos para mostrar"},l58={code:"pt",week:{dow:1,doy:4},buttonText:{prev:"Anterior",next:"Seguinte",today:"Hoje",month:"Mês",week:"Semana",day:"Dia",list:"Agenda"},weekText:"Sem",allDayText:"Todo o dia",moreLinkText:"mais",noEventsText:"Não há eventos para mostrar"},l59={code:"ro",week:{dow:1,doy:7},buttonText:{prev:"precedentă",next:"următoare",today:"Azi",month:"Lună",week:"Săptămână",day:"Zi",list:"Agendă"},weekText:"Săpt",allDayText:"Toată ziua",moreLinkText:function(e){return"+alte "+e},noEventsText:"Nu există evenimente de afișat"},l60={code:"ru",week:{dow:1,doy:4},buttonText:{prev:"Пред",next:"След",today:"Сегодня",month:"Месяц",week:"Неделя",day:"День",list:"Повестка дня"},weekText:"Нед",allDayText:"Весь день",moreLinkText:function(e){return"+ ещё "+e},noEventsText:"Нет событий для отображения"},l61={code:"si-lk",week:{dow:1,doy:4},buttonText:{prev:"පෙර",next:"පසු",today:"අද",month:"මාසය",week:"සතිය",day:"දවස",list:"ලැයිස්තුව"},weekText:"සති",allDayText:"සියලු",moreLinkText:"තවත්",noEventsText:"මුකුත් නැත"},l62={code:"sk",week:{dow:1,doy:4},buttonText:{prev:"Predchádzajúci",next:"Nasledujúci",today:"Dnes",month:"Mesiac",week:"Týždeň",day:"Deň",list:"Rozvrh"},weekText:"Ty",allDayText:"Celý deň",moreLinkText:function(e){return"+ďalšie: "+e},noEventsText:"Žiadne akcie na zobrazenie"},l63={code:"sl",week:{dow:1,doy:7},buttonText:{prev:"Prejšnji",next:"Naslednji",today:"Trenutni",month:"Mesec",week:"Teden",day:"Dan",list:"Dnevni red"},weekText:"Teden",allDayText:"Ves dan",moreLinkText:"več",noEventsText:"Ni dogodkov za prikaz"},l64={code:"sm",buttonText:{prev:"Talu ai",next:"Mulimuli atu",today:"Aso nei",month:"Masina",week:"Vaiaso",day:"Aso",list:"Faasologa"},weekText:"Vaiaso",allDayText:"Aso atoa",moreLinkText:"sili atu",noEventsText:"Leai ni mea na tutupu"},l65={code:"sq",week:{dow:1,doy:4},buttonText:{prev:"mbrapa",next:"Përpara",today:"sot",month:"Muaj",week:"Javë",day:"Ditë",list:"Listë"},weekText:"Ja",allDayText:"Gjithë ditën",moreLinkText:function(e){return"+më tepër "+e},noEventsText:"Nuk ka evente për të shfaqur"},l66={code:"sr-cyrl",week:{dow:1,doy:7},buttonText:{prev:"Претходна",next:"следећи",today:"Данас",month:"Месец",week:"Недеља",day:"Дан",list:"Планер"},weekText:"Сед",allDayText:"Цео дан",moreLinkText:function(e){return"+ још "+e},noEventsText:"Нема догађаја за приказ"},l67={code:"sr",week:{dow:1,doy:7},buttonText:{prev:"Prethodna",next:"Sledeći",today:"Danas",month:"Mеsеc",week:"Nеdеlja",day:"Dan",list:"Planеr"},weekText:"Sed",allDayText:"Cеo dan",moreLinkText:function(e){return"+ još "+e},noEventsText:"Nеma događaja za prikaz"},l68={code:"sv",week:{dow:1,doy:4},buttonText:{prev:"Förra",next:"Nästa",today:"Idag",month:"Månad",week:"Vecka",day:"Dag",list:"Program"},buttonHints:{prev:function(e){return"Föregående ".concat(e.toLocaleLowerCase())},next:function(e){return"Nästa ".concat(e.toLocaleLowerCase())},today:function(e){return("Program"===e?"Detta":"Denna")+" "+e.toLocaleLowerCase()}},viewHint:"$0 vy",navLinkHint:"Gå till $0",moreLinkHint:function(e){return"Visa ytterligare ".concat(e," händelse").concat(1===e?"":"r")},weekText:"v.",weekTextLong:"Vecka",allDayText:"Heldag",moreLinkText:"till",noEventsText:"Inga händelser att visa",closeHint:"Stäng",timeHint:"Klockan",eventHint:"Händelse"},l69={code:"ta-in",week:{dow:1,doy:4},buttonText:{prev:"முந்தைய",next:"அடுத்தது",today:"இன்று",month:"மாதம்",week:"வாரம்",day:"நாள்",list:"தினசரி அட்டவணை"},weekText:"வாரம்",allDayText:"நாள் முழுவதும்",moreLinkText:function(e){return"+ மேலும் "+e},noEventsText:"காண்பிக்க நிகழ்வுகள் இல்லை"},l70={code:"th",week:{dow:1,doy:4},buttonText:{prev:"ก่อนหน้า",next:"ถัดไป",prevYear:"ปีก่อนหน้า",nextYear:"ปีถัดไป",year:"ปี",today:"วันนี้",month:"เดือน",week:"สัปดาห์",day:"วัน",list:"กำหนดการ"},weekText:"สัปดาห์",allDayText:"ตลอดวัน",moreLinkText:"เพิ่มเติม",noEventsText:"ไม่มีกิจกรรมที่จะแสดง"},l71={code:"tr",week:{dow:1,doy:7},buttonText:{prev:"geri",next:"ileri",today:"bugün",month:"Ay",week:"Hafta",day:"Gün",list:"Ajanda"},weekText:"Hf",allDayText:"Tüm gün",moreLinkText:"daha fazla",noEventsText:"Gösterilecek etkinlik yok"},l72={code:"ug",buttonText:{month:"ئاي",week:"ھەپتە",day:"كۈن",list:"كۈنتەرتىپ"},allDayText:"پۈتۈن كۈن"},l73={code:"uk",week:{dow:1,doy:7},buttonText:{prev:"Попередній",next:"далі",today:"Сьогодні",month:"Місяць",week:"Тиждень",day:"День",list:"Порядок денний"},weekText:"Тиж",allDayText:"Увесь день",moreLinkText:function(e){return"+ще "+e+"..."},noEventsText:"Немає подій для відображення"},l74={code:"uz",buttonText:{month:"Oy",week:"Xafta",day:"Kun",list:"Kun tartibi"},allDayText:"Kun bo'yi",moreLinkText:function(e){return"+ yana "+e},noEventsText:"Ko'rsatish uchun voqealar yo'q"},l75={code:"vi",week:{dow:1,doy:4},buttonText:{prev:"Trước",next:"Tiếp",today:"Hôm nay",month:"Tháng",week:"Tuần",day:"Ngày",list:"Lịch biểu"},weekText:"Tu",allDayText:"Cả ngày",moreLinkText:function(e){return"+ thêm "+e},noEventsText:"Không có sự kiện để hiển thị"},l76={code:"zh-cn",week:{dow:1,doy:4},buttonText:{prev:"上月",next:"下月",today:"今天",month:"月",week:"周",day:"日",list:"日程"},weekText:"周",allDayText:"全天",moreLinkText:function(e){return"另外 "+e+" 个"},noEventsText:"没有事件显示"},l77={code:"zh-tw",buttonText:{prev:"上月",next:"下月",today:"今天",month:"月",week:"週",day:"天",list:"活動列表"},weekText:"周",allDayText:"整天",moreLinkText:"顯示更多",noEventsText:"没有任何活動"},localesAll=[l0,l1,l2,l3,l4,l5,l6,l7,l8,l9,l10,l11,l12,l13,l14,l15,l16,l17,l18,l19,l20,l21,l22,l23,l24,l25,l26,l27,l28,l29,l30,l31,l32,l33,l34,l35,l36,l37,l38,l39,l40,l41,l42,l43,l44,l45,l46,l47,l48,l49,l50,l51,l52,l53,l54,l55,l56,l57,l58,l59,l60,l61,l62,l63,l64,l65,l66,l67,l68,l69,l70,l71,l72,l73,l74,l75,l76,l77],_default=localesAll$1.default=localesAll,freeGlobal$1="object"==typeof commonjsGlobal&&commonjsGlobal&&commonjsGlobal.Object===Object&&commonjsGlobal,_freeGlobal=freeGlobal$1,freeGlobal=_freeGlobal,freeSelf="object"==typeof self&&self&&self.Object===Object&&self,root$1=freeGlobal||freeSelf||Function("return this")(),_root=root$1,root=_root,Symbol$3=root.Symbol,_Symbol=Symbol$3,Symbol$2=_Symbol;Symbol$2&&Symbol$2.toStringTag;var Symbol$1=_Symbol;Symbol$1&&Symbol$1.toStringTag;var funcProto=Function.prototype,funcToString=funcProto.toString;funcToString.call(Object);const getBuilderContext=()=>"undefined"==typeof window?{}:Builder.settings.context?Builder.settings.context:Builder.settings;async function fetchAPI(e,t={credentials:"include"}){const n={"Content-Type":"application/json"},r=getAuthorization();r&&(n.Authorization=r),t.headers=Object.assign({},n,t.headers),t.credentials="include";const o=await fetch(`${getRootUrl()}${e}`,t);if(401===o.status)throw new Error(401);const i=await o.json();if(i.errors)throw console.error(i.errors),new Error("Failed to fetch API");return i}function getAuthorization(){try{const e=getBuilderContext();let t=e.tenantId,n=e.authToken;return t&&n?`Bearer ${t},${n}`:null}catch(e){console.error(e)}}function getUserId(){try{let e=getBuilderContext().userId;return e||null}catch(e){console.error(e)}}function getRootUrl(e){const t=getBuilderContext();if(t.rootUrl)return t.rootUrl;const n="undefined"!=typeof window?window.localStorage.getItem("steedos:rootUrl"):"";return n||e}let UI_SCHEMA_CACHE={},UISchemaFunction;"undefined"!=typeof window&&(window.UI_SCHEMA_CACHE||(window.UI_SCHEMA_CACHE=UI_SCHEMA_CACHE),UI_SCHEMA_CACHE=window.UI_SCHEMA_CACHE);const setUISchemaCache=(e,t)=>{UI_SCHEMA_CACHE[e]=t},getUISchemaCache=e=>___default.cloneDeep(UI_SCHEMA_CACHE[e]),hasUISchemaCache=e=>___default.has(UI_SCHEMA_CACHE,e);function getListViewColumns(e,t){let n=[];return n="SMALL"===t?___default.isEmpty(e.mobile_columns)?___default.slice(e.columns,0,4):e.mobile_columns:e.columns,n}function getListViewSort(e){let t="";return e&&e.sort&&e.sort.length&&___default.each(e.sort,(function(e,n){if(___default.isArray(e)){let r=e[0]+" "+(e[1]||"");r=n>0?","+r:r,t+=r}else{let r=e.field_name+" "+e.order;r=n>0?","+r:r,t+=r}})),t}function getListViewFilter(e){if(e)try{const t=getUserId();let n=e.filters;if("mine"===e.filter_scope)if(___default__default.default.isEmpty(n))n=[["owner","=",t]];else{if(___default__default.default.isString(n)&&___default__default.default.startsWith(___default__default.default.trim(n),"function")&&(n=new Function(`return ${n}`),n=n()),!___default__default.default.isArray(n))throw console.debug("listView filters is not array",e),new Error("filters is not array");n.push(["owner","=",t])}return n}catch(e){console.error(e)}}function formatUISchemaCache(objectName,uiSchema){setUISchemaCache(objectName,uiSchema),___default.each(uiSchema.fields,(field=>{try{"lookup"===field.type&&field._reference_to&&___default__default.default.isString(field._reference_to)&&(field.reference_to=eval(`(${field._reference_to})`)())}catch(e){field.reference_to=void 0,console.error(e)}})),___default.each(uiSchema.list_views,((e,t)=>{e.name=t,___default.has(e,"columns")||(e.columns=uiSchema.list_views.all.columns)}))}async function getUISchema(e,t){if(!e)return;if(hasUISchemaCache(e)&&!t)return getUISchemaCache(e);let n=null;try{if(UISchemaFunction);else{const t=`/service/api/@${e.replace(/\./g,"_")}/uiSchema`;n=await fetchAPI(t,{method:"get"})}if(!n)return;formatUISchemaCache(e,n)}catch(t){console.error("getUISchema",e,t),setUISchemaCache(e,null)}return getUISchemaCache(e)}function getUISchemaSync(e,t){if(!e)return;if(hasUISchemaCache(e)&&!t)return getUISchemaCache(e);let n=null;try{const t=`/service/api/@${e.replace(/\./g,"_")}/uiSchema`;if(n=Steedos.authRequest(t,{type:"GET",async:!1}),!n)return;formatUISchemaCache(e,n)}catch(t){console.error("getUISchema",e,t),setUISchemaCache(e,null)}return getUISchemaCache(e)}async function getListSchema(e,t,n,r={}){const o=await getUISchema(t),i=___default.find(o.list_views,((e,t)=>(n||(n=t),t===n||e._id===n)));if(!i)return{uiSchema:o};if(i.enable_amis_schema&&i.amis_schema){return{uiSchema:o,isCustomAmisSchema:!0,amisSchema:___default.isString(i.amis_schema)?JSON.parse(i.amis_schema):i.amis_schema}}let a=getListViewColumns(i,r.formFactor),s=getListViewSort(i),l=getListViewFilter(i),u=i&&i._filters;if("calendar"===i.type){return{uiSchema:o,isCalendar:!0,amisSchema:{type:"steedos-object-calendar",objectApiName:t,filters:l,filtersFunction:u,sort:s,...i.options}}}const c=r.defaults||{};c.headerSchema=null;try{const e=location.pathname+"/crud/"+r.listViewId;let t=sessionStorage.getItem(e);if(t){t=JSON.parse(t);let e={};t.orderBy&&(e.orderBy=t.orderBy),t.orderDir&&(e.orderDir=t.orderDir),c.listSchema=___default.defaultsDeep({},e,c.listSchema||{})}}catch(e){console.error("本地存储中crud参数解析异常:",e)}r.defaults=c;return{uiSchema:o,amisSchema:{type:"steedos-object-table",objectApiName:t,columns:a,extraColumns:i.extra_columns,filters:l,filtersFunction:u,sort:s,ctx:r,requestAdaptor:i.requestAdaptor,adaptor:i.adaptor,headerToolbarItems:r.headerToolbarItems,filterVisible:r.filterVisible}}}"undefined"!=typeof window&&(window.getUISchema=getUISchema,window.getUISchemaSync=getUISchemaSync,window.getListSchema=getListSchema);var __assign=function(){return __assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},__assign.apply(this,arguments)};function createObject(e,t,n){e&&Object.isFrozen(e)&&(e=cloneObject(e));var r=e?Object.create(e,__assign(__assign({},n),{__super:{value:e,writable:!1,enumerable:!1}})):Object.create(Object.prototype,n);return t&&isObject(t)&&Object.keys(t).forEach((function(e){return r[e]=t[e]})),r}function cloneObject(e,t){void 0===t&&(t=!0);var n=e&&e.__super?Object.create(e.__super,{__super:{value:e.__super,writable:!1,enumerable:!1}}):Object.create(Object.prototype);return t&&e&&Object.keys(e).forEach((function(t){return n[t]=e[t]})),n}function isObject(e){var t=typeof e;return e&&"string"!==t&&"number"!==t&&"boolean"!==t&&"function"!==t&&!Array.isArray(e)}var FullCalendar=function(e){var t=e.dispatchEvent,n=e.data,r=__rest(e,["dispatchEvent","data"]),o=function(e,r){return __awaiter(void 0,void 0,void 0,(function(){var o,i;return __generator(this,(function(a){switch(a.label){case 0:return t?[4,t(e,r?createObject(n,r):n)]:[2];case 1:return o=a.sent(),[2,null!==(i=null==o?void 0:o.prevented)&&void 0!==i&&i]}}))}))};return React__default.default.createElement(FullCalendar$1,__assign$1({plugins:[main$3,main$2,main$1,main],headerToolbar:{left:"title",center:"",right:"prev,next today dayGridMonth,timeGridWeek,timeGridDay,listWeek"},locales:_default,locale:"zh-cn",editable:!0,selectable:!0,selectMirror:!0,dayMaxEvents:!0,initialView:"timeGridWeek",events:function(e,t,n){setTimeout((function(){o("getEvents",{fetchInfo:e,successCallback:t,failureCallback:n})}),100)},select:function(e){o("select",e)},eventClick:function(e){o("eventClick",e)},eventsSet:function(e){o("eventsSet",e)},eventAdd:function(e){o("eventAdd",e)},eventChange:function(e){o("eventChange",e)},eventRemove:function(e){o("eventRemove",e)},eventDidMount:function(e){o("eventDidMount",e)},eventWillUnmount:function(e){o("eventWillUnmount",e)},noEventsDidMount:function(e){o("noEventsDidMount",e)},noEventsWillUnmount:function(e){o("noEventsWillUnmount",e)},forceEventDuration:!0,views:{listWeek:{buttonText:"列表"}}},r))};exports.FullCalendar=FullCalendar,Object.defineProperty(exports,"__esModule",{value:!0})}));