@fullcalendar/timeline 5.11.2 → 5.11.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.
package/main.cjs.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- FullCalendar Scheduler v5.11.2
2
+ FullCalendar Scheduler v5.11.3
3
3
  Docs & License: https://fullcalendar.io/scheduler
4
4
  (c) 2022 Adam Shaw
5
5
  */
@@ -1101,11 +1101,11 @@ var TimelineLane = /** @class */ (function (_super) {
1101
1101
  }
1102
1102
  };
1103
1103
  TimelineLane.prototype.updateSize = function () {
1104
- var _this = this;
1105
1104
  var props = this.props;
1106
1105
  var timelineCoords = props.timelineCoords;
1106
+ var innerEl = this.innerElRef.current;
1107
1107
  if (props.onHeightChange) {
1108
- props.onHeightChange(this.innerElRef.current, false);
1108
+ props.onHeightChange(innerEl, false);
1109
1109
  }
1110
1110
  if (timelineCoords) {
1111
1111
  this.setState({
@@ -1113,10 +1113,14 @@ var TimelineLane = /** @class */ (function (_super) {
1113
1113
  moreLinkHeights: common.mapHash(this.moreElRefs.currentMap, function (moreEl) { return (Math.round(moreEl.getBoundingClientRect().height)); }),
1114
1114
  }, function () {
1115
1115
  if (props.onHeightChange) {
1116
- props.onHeightChange(_this.innerElRef.current, true);
1116
+ props.onHeightChange(innerEl, true);
1117
1117
  }
1118
1118
  });
1119
1119
  }
1120
+ // hack
1121
+ if (props.syncParentMinHeight) {
1122
+ innerEl.parentElement.style.minHeight = innerEl.style.height;
1123
+ }
1120
1124
  };
1121
1125
  TimelineLane.prototype.renderFgSegs = function (segPlacements, isForcedInvisible, isDragging, isResizing, isDateSelecting) {
1122
1126
  var _a = this, harnessElRefs = _a.harnessElRefs, moreElRefs = _a.moreElRefs, props = _a.props, context = _a.context;
@@ -1200,7 +1204,7 @@ var TimelineGrid = /** @class */ (function (_super) {
1200
1204
  } },
1201
1205
  common.createElement(common.NowTimer, { unit: timerUnit }, function (nowDate, todayRange) { return (common.createElement(common.Fragment, null,
1202
1206
  common.createElement(TimelineSlats, { ref: _this.slatsRef, dateProfile: dateProfile, tDateProfile: tDateProfile, nowDate: nowDate, todayRange: todayRange, clientWidth: props.clientWidth, tableColGroupNode: props.tableColGroupNode, tableMinWidth: props.tableMinWidth, onCoords: _this.handleCoords, onScrollLeftRequest: props.onScrollLeftRequest }),
1203
- common.createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords }),
1207
+ common.createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords, syncParentMinHeight: true }),
1204
1208
  (options.nowIndicator && state.coords && state.coords.isDateInRange(nowDate)) && (common.createElement("div", { className: "fc-timeline-now-indicator-container" },
1205
1209
  common.createElement(common.NowIndicatorRoot, { isAxis: false, date: nowDate }, function (rootElRef, classNames, innerElRef, innerContent) { return (common.createElement("div", { ref: rootElRef, className: ['fc-timeline-now-indicator-line'].concat(classNames).join(' '), style: coordToCss(state.coords.dateToCoord(nowDate), context.isRtl) }, innerContent)); }))))); })));
1206
1210
  };
package/main.d.ts CHANGED
@@ -117,6 +117,7 @@ interface TimelineLaneCoreProps {
117
117
  eventResize: EventInteractionState | null;
118
118
  timelineCoords: TimelineCoords | null;
119
119
  resourceId?: string;
120
+ syncParentMinHeight?: boolean;
120
121
  }
121
122
  interface TimelineLaneState {
122
123
  eventInstanceHeights: {
package/main.global.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- FullCalendar Scheduler v5.11.2
2
+ FullCalendar Scheduler v5.11.3
3
3
  Docs & License: https://fullcalendar.io/scheduler
4
4
  (c) 2022 Adam Shaw
5
5
  */
@@ -1136,11 +1136,11 @@ var FullCalendarTimeline = (function (exports, common, premiumCommonPlugin, scro
1136
1136
  }
1137
1137
  };
1138
1138
  TimelineLane.prototype.updateSize = function () {
1139
- var _this = this;
1140
1139
  var props = this.props;
1141
1140
  var timelineCoords = props.timelineCoords;
1141
+ var innerEl = this.innerElRef.current;
1142
1142
  if (props.onHeightChange) {
1143
- props.onHeightChange(this.innerElRef.current, false);
1143
+ props.onHeightChange(innerEl, false);
1144
1144
  }
1145
1145
  if (timelineCoords) {
1146
1146
  this.setState({
@@ -1148,10 +1148,14 @@ var FullCalendarTimeline = (function (exports, common, premiumCommonPlugin, scro
1148
1148
  moreLinkHeights: common.mapHash(this.moreElRefs.currentMap, function (moreEl) { return (Math.round(moreEl.getBoundingClientRect().height)); }),
1149
1149
  }, function () {
1150
1150
  if (props.onHeightChange) {
1151
- props.onHeightChange(_this.innerElRef.current, true);
1151
+ props.onHeightChange(innerEl, true);
1152
1152
  }
1153
1153
  });
1154
1154
  }
1155
+ // hack
1156
+ if (props.syncParentMinHeight) {
1157
+ innerEl.parentElement.style.minHeight = innerEl.style.height;
1158
+ }
1155
1159
  };
1156
1160
  TimelineLane.prototype.renderFgSegs = function (segPlacements, isForcedInvisible, isDragging, isResizing, isDateSelecting) {
1157
1161
  var _a = this, harnessElRefs = _a.harnessElRefs, moreElRefs = _a.moreElRefs, props = _a.props, context = _a.context;
@@ -1235,7 +1239,7 @@ var FullCalendarTimeline = (function (exports, common, premiumCommonPlugin, scro
1235
1239
  } },
1236
1240
  common.createElement(common.NowTimer, { unit: timerUnit }, function (nowDate, todayRange) { return (common.createElement(common.Fragment, null,
1237
1241
  common.createElement(TimelineSlats, { ref: _this.slatsRef, dateProfile: dateProfile, tDateProfile: tDateProfile, nowDate: nowDate, todayRange: todayRange, clientWidth: props.clientWidth, tableColGroupNode: props.tableColGroupNode, tableMinWidth: props.tableMinWidth, onCoords: _this.handleCoords, onScrollLeftRequest: props.onScrollLeftRequest }),
1238
- common.createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords }),
1242
+ common.createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords, syncParentMinHeight: true }),
1239
1243
  (options.nowIndicator && state.coords && state.coords.isDateInRange(nowDate)) && (common.createElement("div", { className: "fc-timeline-now-indicator-container" },
1240
1244
  common.createElement(common.NowIndicatorRoot, { isAxis: false, date: nowDate }, function (rootElRef, classNames, innerElRef, innerContent) { return (common.createElement("div", { ref: rootElRef, className: ['fc-timeline-now-indicator-line'].concat(classNames).join(' '), style: coordToCss(state.coords.dateToCoord(nowDate), context.isRtl) }, innerContent)); }))))); })));
1241
1245
  };
@@ -1,6 +1,6 @@
1
1
  /*!
2
- FullCalendar Scheduler v5.11.2
2
+ FullCalendar Scheduler v5.11.3
3
3
  Docs & License: https://fullcalendar.io/scheduler
4
4
  (c) 2022 Adam Shaw
5
5
  */
6
- var FullCalendarTimeline=function(e,t,n,r){"use strict";function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var i=o(n),a=function(e,t){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}a(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var l=function(){return(l=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}).apply(this,arguments)};t.config.MAX_TIMELINE_SLOTS=1e3;var c=[{years:1},{months:1},{days:1},{hours:1},{minutes:30},{minutes:15},{minutes:10},{minutes:5},{minutes:1},{seconds:30},{seconds:15},{seconds:10},{seconds:5},{seconds:1},{milliseconds:500},{milliseconds:100},{milliseconds:10},{milliseconds:1}];function u(e,n,r,o){var i={labelInterval:r.slotLabelInterval,slotDuration:r.slotDuration};!function(e,n,r){var o=n.currentRange;if(e.labelInterval){r.countDurationsBetween(o.start,o.end,e.labelInterval)>t.config.MAX_TIMELINE_SLOTS&&(console.warn("slotLabelInterval results in too many cells"),e.labelInterval=null)}if(e.slotDuration){r.countDurationsBetween(o.start,o.end,e.slotDuration)>t.config.MAX_TIMELINE_SLOTS&&(console.warn("slotDuration results in too many cells"),e.slotDuration=null)}if(e.labelInterval&&e.slotDuration){var i=t.wholeDivideDurations(e.labelInterval,e.slotDuration);(null===i||i<1)&&(console.warn("slotLabelInterval must be a multiple of slotDuration"),e.slotDuration=null)}}(i,e,n),h(i,e,n),function(e,n,r){var o=n.currentRange,i=e.slotDuration;if(!i){for(var a=h(e,n,r),s=0,l=c;s<l.length;s++){var u=l[s],d=t.createDuration(u),f=t.wholeDivideDurations(a,d);if(null!==f&&f>1&&f<=6){i=d;break}}if(i)r.countDurationsBetween(o.start,o.end,i)>200&&(i=null);i||(i=a),e.slotDuration=i}}(i,e,n);var a=r.slotLabelFormat,s=Array.isArray(a)?a:null!=a?[a]:function(e,n,r,o){var i,a,s=e.labelInterval,l=t.greatestDurationDenominator(s).unit,c=o.weekNumbers,u=i=a=null;"week"!==l||c||(l="day");switch(l){case"year":u={year:"numeric"};break;case"month":m("years",n,r)>1&&(u={year:"numeric"}),i={month:"short"};break;case"week":m("years",n,r)>1&&(u={year:"numeric"}),i={week:"narrow"};break;case"day":m("years",n,r)>1?u={year:"numeric",month:"long"}:m("months",n,r)>1&&(u={month:"long"}),c&&(i={week:"short"}),a={weekday:"narrow",day:"numeric"};break;case"hour":c&&(u={week:"short"}),m("days",n,r)>1&&(i={weekday:"short",day:"numeric",month:"numeric",omitCommas:!0}),a={hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"short"};break;case"minute":t.asRoughMinutes(s)/60>=6?(u={hour:"numeric",meridiem:"short"},i=function(e){return":"+t.padStart(e.date.minute,2)}):u={hour:"numeric",minute:"numeric",meridiem:"short"};break;case"second":t.asRoughSeconds(s)/60>=6?(u={hour:"numeric",minute:"2-digit",meridiem:"lowercase"},i=function(e){return":"+t.padStart(e.date.second,2)}):u={hour:"numeric",minute:"2-digit",second:"2-digit",meridiem:"lowercase"};break;case"millisecond":u={hour:"numeric",minute:"2-digit",second:"2-digit",meridiem:"lowercase"},i=function(e){return"."+t.padStart(e.millisecond,3)}}return[].concat(u||[],i||[],a||[])}(i,e,n,r);i.headerFormats=s.map((function(e){return t.createFormatter(e)})),i.isTimeScale=Boolean(i.slotDuration.milliseconds);var l=null;if(!i.isTimeScale){var u=t.greatestDurationDenominator(i.slotDuration).unit;/year|month|week/.test(u)&&(l=u)}i.largeUnit=l,i.emphasizeWeeks=1===t.asCleanDays(i.slotDuration)&&m("weeks",e,n)>=2&&!r.businessHours;var g,v,y=r.snapDuration;y&&(g=t.createDuration(y),v=t.wholeDivideDurations(i.slotDuration,g)),null==v&&(g=i.slotDuration,v=1),i.snapDuration=g,i.snapsPerSlot=v;var D=t.asRoughMs(e.slotMaxTime)-t.asRoughMs(e.slotMinTime),S=d(e.renderRange.start,i,n),R=d(e.renderRange.end,i,n);i.isTimeScale&&(S=n.add(S,e.slotMinTime),R=n.add(t.addDays(R,-1),e.slotMaxTime)),i.timeWindowMs=D,i.normalizedRange={start:S,end:R};for(var C=[],E=S;E<R;)f(E,i,e,o)&&C.push(E),E=n.add(E,i.slotDuration);i.slotDates=C;var w=-1,b=0,k=[],P=[];for(E=S;E<R;)f(E,i,e,o)?(w+=1,k.push(w),P.push(b)):k.push(w+.5),E=n.add(E,i.snapDuration),b+=1;return i.snapDiffToIndex=k,i.snapIndexToDiff=P,i.snapCnt=w+1,i.slotCnt=i.snapCnt/i.snapsPerSlot,i.isWeekStarts=function(e,t){for(var n=e.slotDates,r=e.emphasizeWeeks,o=null,i=[],a=0,s=n;a<s.length;a++){var l=s[a],c=t.computeWeekNumber(l),u=r&&null!==o&&o!==c;o=c,i.push(u)}return i}(i,n),i.cellRows=function(e,n){for(var r=e.slotDates,o=e.headerFormats,i=o.map((function(){return[]})),a=t.asCleanDays(e.slotDuration),s=7===a?"week":1===a?"day":null,l=o.map((function(e){return e.getLargestUnit?e.getLargestUnit():null})),c=0;c<r.length;c+=1)for(var u=r[c],d=e.isWeekStarts[c],f=0;f<o.length;f+=1){var h=o[f],m=i[f],g=m[m.length-1],v=f===o.length-1,y=o.length>1&&!v,D=null,S=l[f]||(v?s:null);if(y){var R=n.format(u,h);g&&g.text===R?g.colspan+=1:D=p(u,R,S)}else if(!g||t.isInt(n.countDurationsBetween(e.normalizedRange.start,u,e.labelInterval))){D=p(u,R=n.format(u,h),S)}else g.colspan+=1;D&&(D.weekStart=d,m.push(D))}return i}(i,n),i.slotsPerLabel=t.wholeDivideDurations(i.labelInterval,i.slotDuration),i}function d(e,n,r){var o=e;return n.isTimeScale||(o=t.startOfDay(o),n.largeUnit&&(o=r.startOf(o,n.largeUnit))),o}function f(e,n,r,o){if(o.isHiddenDay(e))return!1;if(n.isTimeScale){var i=t.startOfDay(e),a=e.valueOf()-i.valueOf()-t.asRoughMs(r.slotMinTime);return(a=(a%864e5+864e5)%864e5)<n.timeWindowMs}return!0}function h(e,n,r){var o=n.currentRange,i=e.labelInterval;if(!i){var a=void 0;if(e.slotDuration){for(var s=0,l=c;s<l.length;s++){a=l[s];var u=t.createDuration(a),d=t.wholeDivideDurations(u,e.slotDuration);if(null!==d&&d<=6){i=u;break}}i||(i=e.slotDuration)}else for(var f=0,h=c;f<h.length;f++){if(a=h[f],i=t.createDuration(a),r.countDurationsBetween(o.start,o.end,i)>=18)break}e.labelInterval=i}return i}function m(e,n,r){var o=n.currentRange,i=null;return"years"===e?i=r.diffWholeYears(o.start,o.end):"months"===e||"weeks"===e?i=r.diffWholeMonths(o.start,o.end):"days"===e&&(i=t.diffWholeDays(o.start,o.end)),i||0}function p(e,t,n){return{date:e,text:t,rowUnit:n,colspan:1,isWeekStart:!1}}var g=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context;return t.createElement(t.ContentHook,{hookProps:e.hookProps,content:n.options.slotLabelContent,defaultContent:v},(function(n,r){return t.createElement("a",l({ref:n,className:"fc-timeline-slot-cushion fc-scrollgrid-sync-inner"+(e.isSticky?" fc-sticky":"")},e.navLinkAttrs),r)}))},n}(t.BaseComponent);function v(e){return e.text}function y(e){return{level:e.level,date:e.dateEnv.toDate(e.dateMarker),view:e.viewApi,text:e.text}}var D=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.refineHookProps=t.memoizeObjArg(y),n.normalizeClassNames=t.buildClassNameNormalizer(),n.buildCellNavLinkAttrs=t.memoize(S),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,o=r.dateEnv,i=r.options,a=n.cell,s=n.dateProfile,l=n.tDateProfile,c=t.getDateMeta(a.date,n.todayRange,n.nowDate,s),u=["fc-timeline-slot","fc-timeline-slot-label"].concat("time"===a.rowUnit?t.getSlotClassNames(c,r.theme):t.getDayClassNames(c,r.theme));a.isWeekStart&&u.push("fc-timeline-slot-em");var d=this.refineHookProps({level:n.rowLevel,dateMarker:a.date,text:a.text,dateEnv:r.dateEnv,viewApi:r.viewApi}),f=this.normalizeClassNames(i.slotLabelClassNames,d);return t.createElement(t.MountHook,{hookProps:d,didMount:i.slotLabelDidMount,willUnmount:i.slotLabelWillUnmount},(function(i){return t.createElement("th",{ref:i,className:u.concat(f).join(" "),"data-date":o.formatIso(a.date,{omitTime:!l.isTimeScale,omitTimeZoneOffset:!0}),colSpan:a.colspan},t.createElement("div",{className:"fc-timeline-slot-frame",style:{height:n.rowInnerHeight}},t.createElement(g,{hookProps:d,isSticky:n.isSticky,navLinkAttrs:e.buildCellNavLinkAttrs(r,a.date,a.rowUnit)})))}))},n}(t.BaseComponent);function S(e,n,r){return r&&"time"!==r?t.buildNavLinkAttrs(e,n,r):{}}var R=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=e.dateProfile,r=e.tDateProfile,o=e.rowInnerHeights,i=e.todayRange,a=e.nowDate,s=r.cellRows;return t.createElement(t.Fragment,null,s.map((function(e,l){var c=l===s.length-1,u=["fc-timeline-header-row",r.isTimeScale&&c?"fc-timeline-header-row-chrono":""];return t.createElement("tr",{key:l,className:u.join(" ")},e.map((function(e){return t.createElement(D,{key:e.date.toISOString(),cell:e,rowLevel:l,dateProfile:n,tDateProfile:r,todayRange:i,nowDate:a,rowInnerHeight:o&&o[l],isSticky:!c})})))})))},n}(t.BaseComponent),C=function(){function e(e,n,r,o,i,a){this.slatRootEl=e,this.dateProfile=r,this.tDateProfile=o,this.dateEnv=i,this.isRtl=a,this.outerCoordCache=new t.PositionCache(e,n,!0,!1),this.innerCoordCache=new t.PositionCache(e,t.findDirectChildren(n,"div"),!0,!1)}return e.prototype.isDateInRange=function(e){return t.rangeContainsMarker(this.dateProfile.currentRange,e)},e.prototype.dateToCoord=function(e){var t=this.tDateProfile,n=this.computeDateSnapCoverage(e)/t.snapsPerSlot,r=Math.floor(n),o=n-(r=Math.min(r,t.slotCnt-1)),i=this.innerCoordCache,a=this.outerCoordCache;return this.isRtl?a.originClientRect.width-(a.rights[r]-i.getWidth(r)*o):a.lefts[r]+i.getWidth(r)*o},e.prototype.rangeToCoords=function(e){return{start:this.dateToCoord(e.start),end:this.dateToCoord(e.end)}},e.prototype.durationToCoord=function(e){var n=this,r=n.dateProfile,o=n.tDateProfile,i=n.dateEnv,a=n.isRtl,s=0;if(r){var l=i.add(r.activeRange.start,e);o.isTimeScale||(l=t.startOfDay(l)),s=this.dateToCoord(l),!a&&s&&(s+=1)}return s},e.prototype.coordFromLeft=function(e){return this.isRtl?this.outerCoordCache.originClientRect.width-e:e},e.prototype.computeDateSnapCoverage=function(e){return E(e,this.tDateProfile,this.dateEnv)},e}();function E(e,n,r){var o=r.countDurationsBetween(n.normalizedRange.start,e,n.snapDuration);if(o<0)return 0;if(o>=n.snapDiffToIndex.length)return n.snapCnt;var i=Math.floor(o),a=n.snapDiffToIndex[i];return t.isInt(a)?a+=o-i:a=Math.ceil(a),a}function w(e,t){return null===e?{left:"",right:""}:t?{right:e,left:""}:{left:e,right:""}}function b(e,t){return e?t?{right:e.start,left:-e.end}:{left:e.start,right:-e.end}:{left:"",right:""}}var k=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,o=t.greatestDurationDenominator(n.tDateProfile.slotDuration).unit,i=n.slatCoords&&n.slatCoords.dateProfile===n.dateProfile?n.slatCoords:null;return t.createElement(t.NowTimer,{unit:o},(function(o,a){return t.createElement("div",{className:"fc-timeline-header",ref:e.rootElRef},t.createElement("table",{"aria-hidden":!0,className:"fc-scrollgrid-sync-table",style:{minWidth:n.tableMinWidth,width:n.clientWidth}},n.tableColGroupNode,t.createElement("tbody",null,t.createElement(R,{dateProfile:n.dateProfile,tDateProfile:n.tDateProfile,nowDate:o,todayRange:a,rowInnerHeights:n.rowInnerHeights}))),r.options.nowIndicator&&t.createElement("div",{className:"fc-timeline-now-indicator-container"},i&&i.isDateInRange(o)&&t.createElement(t.NowIndicatorRoot,{isAxis:!0,date:o},(function(e,n,a,s){return t.createElement("div",{ref:e,className:["fc-timeline-now-indicator-arrow"].concat(n).join(" "),style:w(i.dateToCoord(o),r.isRtl)},s)}))))}))},n.prototype.componentDidMount=function(){this.updateSize()},n.prototype.componentDidUpdate=function(){this.updateSize()},n.prototype.updateSize=function(){this.props.onMaxCushionWidth&&this.props.onMaxCushionWidth(this.computeMaxCushionWidth())},n.prototype.computeMaxCushionWidth=function(){return Math.max.apply(Math,t.findElements(this.rootElRef.current,".fc-timeline-header-row:last-child .fc-timeline-slot-cushion").map((function(e){return e.getBoundingClientRect().width})))},n}(t.BaseComponent),P=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context,r=n.dateEnv,o=n.options,i=n.theme,a=e.date,s=e.tDateProfile,c=e.isEm,u=t.getDateMeta(e.date,e.todayRange,e.nowDate,e.dateProfile),d=["fc-timeline-slot","fc-timeline-slot-lane"],f={"data-date":r.formatIso(a,{omitTimeZoneOffset:!0,omitTime:!s.isTimeScale})},h=l(l({date:r.toDate(e.date)},u),{view:n.viewApi});return c&&d.push("fc-timeline-slot-em"),s.isTimeScale&&d.push(t.isInt(r.countDurationsBetween(s.normalizedRange.start,e.date,s.labelInterval))?"fc-timeline-slot-major":"fc-timeline-slot-minor"),d.push.apply(d,e.isDay?t.getDayClassNames(u,i):t.getSlotClassNames(u,i)),t.createElement(t.RenderHook,{hookProps:h,classNames:o.slotLaneClassNames,content:o.slotLaneContent,didMount:o.slotLaneDidMount,willUnmount:o.slotLaneWillUnmount,elRef:e.elRef},(function(e,n,r,o){return t.createElement("td",l({ref:e,className:d.concat(n).join(" ")},f),t.createElement("div",{ref:r},o))}))},n}(t.BaseComponent),M=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=e.tDateProfile,r=e.cellElRefs,o=n.slotDates,i=n.isWeekStarts,a=!n.isTimeScale&&!n.largeUnit;return t.createElement("tbody",null,t.createElement("tr",null,o.map((function(o,s){var l=o.toISOString();return t.createElement(P,{key:l,elRef:r.createRef(l),date:o,dateProfile:e.dateProfile,tDateProfile:n,nowDate:e.nowDate,todayRange:e.todayRange,isEm:i[s],isDay:a})}))))},n}(t.BaseComponent),T=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n.cellElRefs=new t.RefMap,n.handleScrollRequest=function(e){var t=n.props.onScrollLeftRequest,r=n.coords;if(t&&r){if(e.time)t(r.coordFromLeft(r.durationToCoord(e.time)));return!0}return null},n}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context;return t.createElement("div",{className:"fc-timeline-slots",ref:this.rootElRef},t.createElement("table",{"aria-hidden":!0,className:n.theme.getClass("table"),style:{minWidth:e.tableMinWidth,width:e.clientWidth}},e.tableColGroupNode,t.createElement(M,{cellElRefs:this.cellElRefs,dateProfile:e.dateProfile,tDateProfile:e.tDateProfile,nowDate:e.nowDate,todayRange:e.todayRange})))},n.prototype.componentDidMount=function(){this.updateSizing(),this.scrollResponder=this.context.createScrollResponder(this.handleScrollRequest)},n.prototype.componentDidUpdate=function(e){this.updateSizing(),this.scrollResponder.update(e.dateProfile!==this.props.dateProfile)},n.prototype.componentWillUnmount=function(){this.scrollResponder.detach(),this.props.onCoords&&this.props.onCoords(null)},n.prototype.updateSizing=function(){var e,t=this.props,n=this.context;null!==t.clientWidth&&this.scrollResponder&&(this.rootElRef.current.offsetWidth&&(this.coords=new C(this.rootElRef.current,(e=this.cellElRefs.currentMap,t.tDateProfile.slotDates.map((function(t){var n=t.toISOString();return e[n]}))),t.dateProfile,t.tDateProfile,n.dateEnv,n.isRtl),t.onCoords&&t.onCoords(this.coords),this.scrollResponder.update(!1)))},n.prototype.positionToHit=function(e){var n=this.coords.outerCoordCache,r=this.context,o=r.dateEnv,i=r.isRtl,a=this.props.tDateProfile,s=n.leftToIndex(e);if(null!=s){var l=n.getWidth(s),c=i?(n.rights[s]-e)/l:(e-n.lefts[s])/l,u=Math.floor(c*a.snapsPerSlot),d=o.add(a.slotDates[s],t.multiplyDuration(a.snapDuration,u));return{dateSpan:{range:{start:d,end:o.add(d,a.snapDuration)},allDay:!this.props.tDateProfile.isTimeScale},dayEl:this.cellElRefs.currentMap[s],left:n.lefts[s],right:n.rights[s]}}return null},n}(t.BaseComponent);function I(e,t,n){var r=[];if(n)for(var o=0,i=e;o<i.length;o++){var a=i[o],s=n.rangeToCoords(a),l=Math.round(s.start),c=Math.round(s.end);c-l<t&&(c=l+t),r.push({start:l,end:c})}return r}var x=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=[].concat(e.eventResizeSegs,e.dateSelectionSegs);return e.timelineCoords&&t.createElement("div",{className:"fc-timeline-bg"},this.renderSegs(e.businessHourSegs||[],e.timelineCoords,"non-business"),this.renderSegs(e.bgEventSegs||[],e.timelineCoords,"bg-event"),this.renderSegs(n,e.timelineCoords,"highlight"))},n.prototype.renderSegs=function(e,n,r){var o=this.props,i=o.todayRange,a=o.nowDate,s=this.context.isRtl,c=I(e,0,n),u=e.map((function(e,n){var o=b(c[n],s);return t.createElement("div",{key:t.buildEventRangeKey(e.eventRange),className:"fc-timeline-bg-harness",style:o},"bg-event"===r?t.createElement(t.BgEvent,l({seg:e},t.getSegMeta(e,i,a))):t.renderFill(r))}));return t.createElement(t.Fragment,null,u)},n}(t.BaseComponent),W=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.sliceRange=function(e,n,r,o,i){var a=function(e,n,r){if(!n.isTimeScale&&(e=t.computeVisibleDayRange(e),n.largeUnit)){var o=e;((e={start:r.startOf(e.start,n.largeUnit),end:r.startOf(e.end,n.largeUnit)}).end.valueOf()!==o.end.valueOf()||e.end<=e.start)&&(e={start:e.start,end:r.add(e.end,n.slotDuration)})}return e}(e,o,i),s=[];if(E(a.start,o,i)<E(a.end,o,i)){var l=t.intersectRanges(a,o.normalizedRange);l&&s.push({start:l.start,end:l.end,isStart:l.start.valueOf()===a.start.valueOf()&&f(l.start,o,n,r),isEnd:l.end.valueOf()===a.end.valueOf()&&f(t.addMs(l.end,-1),o,n,r)})}return s},n}(t.Slicer),N=t.createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"narrow"}),L=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props;return t.createElement(t.StandardEvent,l({},e,{extraClassNames:["fc-timeline-event","fc-h-event"],defaultTimeFormat:N,defaultDisplayEventTime:!e.isTimeScale}))},n}(t.BaseComponent),H=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,o=n.hiddenSegs,i=n.elRef,a=n.placement,s=n.resourceId,c=a.top,u=a.hcoords,d=u&&null!==c,f=b(u,r.isRtl),h=s?{resourceId:s}:{};return t.createElement(t.MoreLinkRoot,{allDayDate:null,moreCnt:o.length,allSegs:o,hiddenSegs:o,alignmentElRef:this.rootElRef,dateProfile:n.dateProfile,todayRange:n.todayRange,extraDateSpan:h,popoverContent:function(){return t.createElement(t.Fragment,null,o.map((function(e){var r=e.eventRange.instance.instanceId;return t.createElement("div",{key:r,style:{visibility:n.isForcedInvisible[r]?"hidden":""}},t.createElement(L,l({isTimeScale:n.isTimeScale,seg:e,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:r===n.eventSelection},t.getSegMeta(e,n.todayRange,n.nowDate))))})))}},(function(n,r,o,a,s,u,h,m){return t.createElement("a",{ref:function(r){t.setRef(n,r),t.setRef(i,r),t.setRef(e.rootElRef,r)},className:["fc-timeline-more-link"].concat(r).join(" "),style:l({visibility:d?"":"hidden",top:c||0},f),onClick:s,title:u,"aria-expanded":h,"aria-controls":m},t.createElement("div",{ref:o,className:"fc-timeline-more-link-inner fc-sticky"},a))}))},n}(t.BaseComponent),z=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.slicer=new W,n.sortEventSegs=t.memoize(t.sortEventSegs),n.harnessElRefs=new t.RefMap,n.moreElRefs=new t.RefMap,n.innerElRef=t.createRef(),n.state={eventInstanceHeights:{},moreLinkHeights:{}},n}return s(n,e),n.prototype.render=function(){var e=this,n=e.props,r=e.state,o=e.context,i=o.options,a=n.dateProfile,s=n.tDateProfile,l=this.slicer.sliceProps(n,a,s.isTimeScale?null:n.nextDayThreshold,o,a,o.dateProfileGenerator,s,o.dateEnv),c=(l.eventDrag?l.eventDrag.segs:null)||(l.eventResize?l.eventResize.segs:null)||[],u=this.sortEventSegs(l.fgEventSegs,i.eventOrder),d=function(e,n,r,o,i,a){for(var s=[],l=[],c=0;c<e.length;c+=1){var u=e[c],d=r[u.eventRange.instance.instanceId],f=n[c];d&&f?s.push({index:c,span:f,thickness:d}):l.push({seg:u,hcoords:f,top:null})}var h=new t.SegHierarchy;null!=i&&(h.strictOrder=i),null!=a&&(h.maxStackCnt=a);var m=h.addSegs(s),p=m.map((function(t){return{seg:e[t.index],hcoords:t.span,top:null}})),g=t.groupIntersectingEntries(m),v=[],y=[],D=function(t){return e[t.index]};for(c=0;c<g.length;c+=1){var S=g[c],R=S.entries.map(D);null!=(d=o[t.buildIsoString(t.computeEarliestSegStart(R))])?v.push({index:e.length+c,thickness:d,span:S.span}):y.push({seg:R,hcoords:S.span,top:null})}h.maxStackCnt=-1,h.addSegs(v);for(var C=[],E=0,w=0,b=h.toRects();w<b.length;w++){var k=b[w],P=k.index;C.push({seg:P<e.length?e[P]:g[P-e.length].entries.map(D),hcoords:k.span,top:k.levelCoord}),E=Math.max(E,k.levelCoord+k.thickness)}return[C.concat(l,p,y),E]}(u,I(u,i.eventMinWidth,n.timelineCoords),r.eventInstanceHeights,r.moreLinkHeights,i.eventOrderStrict,i.eventMaxStack),f=d[0],h=d[1],m=(l.eventDrag?l.eventDrag.affectedInstances:null)||(l.eventResize?l.eventResize.affectedInstances:null)||{};return t.createElement(t.Fragment,null,t.createElement(x,{businessHourSegs:l.businessHourSegs,bgEventSegs:l.bgEventSegs,timelineCoords:n.timelineCoords,eventResizeSegs:l.eventResize?l.eventResize.segs:[],dateSelectionSegs:l.dateSelectionSegs,nowDate:n.nowDate,todayRange:n.todayRange}),t.createElement("div",{className:"fc-timeline-events fc-scrollgrid-sync-inner",ref:this.innerElRef,style:{height:h}},this.renderFgSegs(f,m,!1,!1,!1),this.renderFgSegs(function(e,t,n){if(!e.length||!t)return[];var r=function(e){for(var t={},n=0,r=e;n<r.length;n++){var o=r[n],i=o.seg;Array.isArray(i)||(t[i.eventRange.instance.instanceId]=o.top)}return t}(n);return e.map((function(e){return{seg:e,hcoords:t.rangeToCoords(e),top:r[e.eventRange.instance.instanceId]}}))}(c,n.timelineCoords,f),{},Boolean(l.eventDrag),Boolean(l.eventResize),!1)))},n.prototype.componentDidMount=function(){this.updateSize()},n.prototype.componentDidUpdate=function(e,t){e.eventStore===this.props.eventStore&&e.timelineCoords===this.props.timelineCoords&&t.moreLinkHeights===this.state.moreLinkHeights||this.updateSize()},n.prototype.updateSize=function(){var e=this,n=this.props,r=n.timelineCoords;n.onHeightChange&&n.onHeightChange(this.innerElRef.current,!1),r&&this.setState({eventInstanceHeights:t.mapHash(this.harnessElRefs.currentMap,(function(e){return Math.round(e.getBoundingClientRect().height)})),moreLinkHeights:t.mapHash(this.moreElRefs.currentMap,(function(e){return Math.round(e.getBoundingClientRect().height)}))},(function(){n.onHeightChange&&n.onHeightChange(e.innerElRef.current,!0)}))},n.prototype.renderFgSegs=function(e,n,r,o,i){var a=this,s=a.harnessElRefs,c=a.moreElRefs,u=a.props,d=a.context,f=r||o||i;return t.createElement(t.Fragment,null,e.map((function(e){var a=e.seg,h=e.hcoords,m=e.top;if(Array.isArray(a)){var p=t.buildIsoString(t.computeEarliestSegStart(a));return t.createElement(H,{key:"m:"+p,elRef:c.createRef(p),hiddenSegs:a,placement:e,dateProfile:u.dateProfile,nowDate:u.nowDate,todayRange:u.todayRange,isTimeScale:u.tDateProfile.isTimeScale,eventSelection:u.eventSelection,resourceId:u.resourceId,isForcedInvisible:n})}var g=a.eventRange.instance.instanceId,v=f||Boolean(!n[g]&&h&&null!==m),y=b(h,d.isRtl);return t.createElement("div",{key:"e:"+g,ref:f?null:s.createRef(g),className:"fc-timeline-event-harness",style:l({visibility:v?"":"hidden",top:m||0},y)},t.createElement(L,l({isTimeScale:u.tDateProfile.isTimeScale,seg:a,isDragging:r,isResizing:o,isDateSelecting:i,isSelected:g===u.eventSelection},t.getSegMeta(a,u.todayRange,u.nowDate))))})))},n}(t.BaseComponent);z.addStateEquality({eventInstanceHeights:t.isPropsEqual,moreLinkHeights:t.isPropsEqual});var O=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.slatsRef=t.createRef(),n.state={coords:null},n.handeEl=function(e){e?n.context.registerInteractiveComponent(n,{el:e}):n.context.unregisterInteractiveComponent(n)},n.handleCoords=function(e){n.setState({coords:e}),n.props.onSlatCoords&&n.props.onSlatCoords(e)},n}return s(n,e),n.prototype.render=function(){var e=this,n=this,r=n.props,o=n.state,i=n.context,a=i.options,s=r.dateProfile,l=r.tDateProfile,c=t.greatestDurationDenominator(l.slotDuration).unit;return t.createElement("div",{className:"fc-timeline-body",ref:this.handeEl,style:{minWidth:r.tableMinWidth,height:r.clientHeight,width:r.clientWidth}},t.createElement(t.NowTimer,{unit:c},(function(n,c){return t.createElement(t.Fragment,null,t.createElement(T,{ref:e.slatsRef,dateProfile:s,tDateProfile:l,nowDate:n,todayRange:c,clientWidth:r.clientWidth,tableColGroupNode:r.tableColGroupNode,tableMinWidth:r.tableMinWidth,onCoords:e.handleCoords,onScrollLeftRequest:r.onScrollLeftRequest}),t.createElement(z,{dateProfile:s,tDateProfile:r.tDateProfile,nowDate:n,todayRange:c,nextDayThreshold:a.nextDayThreshold,businessHours:r.businessHours,eventStore:r.eventStore,eventUiBases:r.eventUiBases,dateSelection:r.dateSelection,eventSelection:r.eventSelection,eventDrag:r.eventDrag,eventResize:r.eventResize,timelineCoords:o.coords}),a.nowIndicator&&o.coords&&o.coords.isDateInRange(n)&&t.createElement("div",{className:"fc-timeline-now-indicator-container"},t.createElement(t.NowIndicatorRoot,{isAxis:!1,date:n},(function(e,r,a,s){return t.createElement("div",{ref:e,className:["fc-timeline-now-indicator-line"].concat(r).join(" "),style:w(o.coords.dateToCoord(n),i.isRtl)},s)}))))})))},n.prototype.queryHit=function(e,t,n,r){var o=this.slatsRef.current.positionToHit(e);return o?{dateProfile:this.props.dateProfile,dateSpan:o.dateSpan,rect:{left:o.left,right:o.right,top:0,bottom:r},dayEl:o.dayEl,layer:0}:null},n}(t.DateComponent),B=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.buildTimelineDateProfile=t.memoize(u),n.scrollGridRef=t.createRef(),n.state={slatCoords:null,slotCushionMaxWidth:null},n.handleSlatCoords=function(e){n.setState({slatCoords:e})},n.handleScrollLeftRequest=function(e){n.scrollGridRef.current.forceScrollLeft(0,e)},n.handleMaxCushionWidth=function(e){n.setState({slotCushionMaxWidth:Math.ceil(e)})},n}return s(n,e),n.prototype.render=function(){var e=this,n=this,o=n.props,i=n.state,a=n.context,s=a.options,c=!o.forPrint&&t.getStickyHeaderDates(s),u=!o.forPrint&&t.getStickyFooterScrollbar(s),d=this.buildTimelineDateProfile(o.dateProfile,a.dateEnv,s,a.dateProfileGenerator),f=["fc-timeline",!1===s.eventOverlap?"fc-timeline-overlap-disabled":""],h=s.slotMinWidth,m=F(d,h||this.computeFallbackSlotMinWidth(d)),p=[{type:"header",key:"header",isSticky:c,chunks:[{key:"timeline",content:function(n){return t.createElement(k,{dateProfile:o.dateProfile,clientWidth:n.clientWidth,clientHeight:n.clientHeight,tableMinWidth:n.tableMinWidth,tableColGroupNode:n.tableColGroupNode,tDateProfile:d,slatCoords:i.slatCoords,onMaxCushionWidth:h?null:e.handleMaxCushionWidth})}}]},{type:"body",key:"body",liquid:!0,chunks:[{key:"timeline",content:function(n){return t.createElement(O,l({},o,{clientWidth:n.clientWidth,clientHeight:n.clientHeight,tableMinWidth:n.tableMinWidth,tableColGroupNode:n.tableColGroupNode,tDateProfile:d,onSlatCoords:e.handleSlatCoords,onScrollLeftRequest:e.handleScrollLeftRequest}))}}]}];return u&&p.push({type:"footer",key:"footer",isSticky:!0,chunks:[{key:"timeline",content:t.renderScrollShim}]}),t.createElement(t.ViewRoot,{viewSpec:a.viewSpec},(function(n,i){return t.createElement("div",{ref:n,className:f.concat(i).join(" ")},t.createElement(r.ScrollGrid,{ref:e.scrollGridRef,liquid:!o.isHeightAuto&&!o.forPrint,collapsibleWidth:!1,colGroups:[{cols:m}],sections:p}))}))},n.prototype.computeFallbackSlotMinWidth=function(e){return Math.max(30,(this.state.slotCushionMaxWidth||0)/e.slotsPerLabel)},n}(t.DateComponent);function F(e,t){return[{span:e.slotCnt,minWidth:t||1}]}var A=t.createPlugin({deps:[i.default],initialView:"timelineDay",views:{timeline:{component:B,usesMinMaxTime:!0,eventResizableFromStart:!0},timelineDay:{type:"timeline",duration:{days:1}},timelineWeek:{type:"timeline",duration:{weeks:1}},timelineMonth:{type:"timeline",duration:{months:1}},timelineYear:{type:"timeline",duration:{years:1}}}});return t.globalPlugins.push(A),e.TimelineCoords=C,e.TimelineHeader=k,e.TimelineHeaderRows=R,e.TimelineLane=z,e.TimelineLaneBg=x,e.TimelineLaneSlicer=W,e.TimelineSlats=T,e.TimelineView=B,e.buildSlatCols=F,e.buildTimelineDateProfile=u,e.coordToCss=w,e.coordsToCss=b,e.default=A,Object.defineProperty(e,"__esModule",{value:!0}),e}({},FullCalendar,FullCalendarPremiumCommon,FullCalendarScrollGrid);
6
+ var FullCalendarTimeline=function(e,t,n,r){"use strict";function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o=i(n),a=function(e,t){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}a(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var l=function(){return(l=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};t.config.MAX_TIMELINE_SLOTS=1e3;var c=[{years:1},{months:1},{days:1},{hours:1},{minutes:30},{minutes:15},{minutes:10},{minutes:5},{minutes:1},{seconds:30},{seconds:15},{seconds:10},{seconds:5},{seconds:1},{milliseconds:500},{milliseconds:100},{milliseconds:10},{milliseconds:1}];function u(e,n,r,i){var o={labelInterval:r.slotLabelInterval,slotDuration:r.slotDuration};!function(e,n,r){var i=n.currentRange;if(e.labelInterval){r.countDurationsBetween(i.start,i.end,e.labelInterval)>t.config.MAX_TIMELINE_SLOTS&&(console.warn("slotLabelInterval results in too many cells"),e.labelInterval=null)}if(e.slotDuration){r.countDurationsBetween(i.start,i.end,e.slotDuration)>t.config.MAX_TIMELINE_SLOTS&&(console.warn("slotDuration results in too many cells"),e.slotDuration=null)}if(e.labelInterval&&e.slotDuration){var o=t.wholeDivideDurations(e.labelInterval,e.slotDuration);(null===o||o<1)&&(console.warn("slotLabelInterval must be a multiple of slotDuration"),e.slotDuration=null)}}(o,e,n),h(o,e,n),function(e,n,r){var i=n.currentRange,o=e.slotDuration;if(!o){for(var a=h(e,n,r),s=0,l=c;s<l.length;s++){var u=l[s],d=t.createDuration(u),f=t.wholeDivideDurations(a,d);if(null!==f&&f>1&&f<=6){o=d;break}}if(o)r.countDurationsBetween(i.start,i.end,o)>200&&(o=null);o||(o=a),e.slotDuration=o}}(o,e,n);var a=r.slotLabelFormat,s=Array.isArray(a)?a:null!=a?[a]:function(e,n,r,i){var o,a,s=e.labelInterval,l=t.greatestDurationDenominator(s).unit,c=i.weekNumbers,u=o=a=null;"week"!==l||c||(l="day");switch(l){case"year":u={year:"numeric"};break;case"month":m("years",n,r)>1&&(u={year:"numeric"}),o={month:"short"};break;case"week":m("years",n,r)>1&&(u={year:"numeric"}),o={week:"narrow"};break;case"day":m("years",n,r)>1?u={year:"numeric",month:"long"}:m("months",n,r)>1&&(u={month:"long"}),c&&(o={week:"short"}),a={weekday:"narrow",day:"numeric"};break;case"hour":c&&(u={week:"short"}),m("days",n,r)>1&&(o={weekday:"short",day:"numeric",month:"numeric",omitCommas:!0}),a={hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"short"};break;case"minute":t.asRoughMinutes(s)/60>=6?(u={hour:"numeric",meridiem:"short"},o=function(e){return":"+t.padStart(e.date.minute,2)}):u={hour:"numeric",minute:"numeric",meridiem:"short"};break;case"second":t.asRoughSeconds(s)/60>=6?(u={hour:"numeric",minute:"2-digit",meridiem:"lowercase"},o=function(e){return":"+t.padStart(e.date.second,2)}):u={hour:"numeric",minute:"2-digit",second:"2-digit",meridiem:"lowercase"};break;case"millisecond":u={hour:"numeric",minute:"2-digit",second:"2-digit",meridiem:"lowercase"},o=function(e){return"."+t.padStart(e.millisecond,3)}}return[].concat(u||[],o||[],a||[])}(o,e,n,r);o.headerFormats=s.map((function(e){return t.createFormatter(e)})),o.isTimeScale=Boolean(o.slotDuration.milliseconds);var l=null;if(!o.isTimeScale){var u=t.greatestDurationDenominator(o.slotDuration).unit;/year|month|week/.test(u)&&(l=u)}o.largeUnit=l,o.emphasizeWeeks=1===t.asCleanDays(o.slotDuration)&&m("weeks",e,n)>=2&&!r.businessHours;var g,v,y=r.snapDuration;y&&(g=t.createDuration(y),v=t.wholeDivideDurations(o.slotDuration,g)),null==v&&(g=o.slotDuration,v=1),o.snapDuration=g,o.snapsPerSlot=v;var D=t.asRoughMs(e.slotMaxTime)-t.asRoughMs(e.slotMinTime),S=d(e.renderRange.start,o,n),R=d(e.renderRange.end,o,n);o.isTimeScale&&(S=n.add(S,e.slotMinTime),R=n.add(t.addDays(R,-1),e.slotMaxTime)),o.timeWindowMs=D,o.normalizedRange={start:S,end:R};for(var C=[],E=S;E<R;)f(E,o,e,i)&&C.push(E),E=n.add(E,o.slotDuration);o.slotDates=C;var w=-1,b=0,k=[],P=[];for(E=S;E<R;)f(E,o,e,i)?(w+=1,k.push(w),P.push(b)):k.push(w+.5),E=n.add(E,o.snapDuration),b+=1;return o.snapDiffToIndex=k,o.snapIndexToDiff=P,o.snapCnt=w+1,o.slotCnt=o.snapCnt/o.snapsPerSlot,o.isWeekStarts=function(e,t){for(var n=e.slotDates,r=e.emphasizeWeeks,i=null,o=[],a=0,s=n;a<s.length;a++){var l=s[a],c=t.computeWeekNumber(l),u=r&&null!==i&&i!==c;i=c,o.push(u)}return o}(o,n),o.cellRows=function(e,n){for(var r=e.slotDates,i=e.headerFormats,o=i.map((function(){return[]})),a=t.asCleanDays(e.slotDuration),s=7===a?"week":1===a?"day":null,l=i.map((function(e){return e.getLargestUnit?e.getLargestUnit():null})),c=0;c<r.length;c+=1)for(var u=r[c],d=e.isWeekStarts[c],f=0;f<i.length;f+=1){var h=i[f],m=o[f],g=m[m.length-1],v=f===i.length-1,y=i.length>1&&!v,D=null,S=l[f]||(v?s:null);if(y){var R=n.format(u,h);g&&g.text===R?g.colspan+=1:D=p(u,R,S)}else if(!g||t.isInt(n.countDurationsBetween(e.normalizedRange.start,u,e.labelInterval))){D=p(u,R=n.format(u,h),S)}else g.colspan+=1;D&&(D.weekStart=d,m.push(D))}return o}(o,n),o.slotsPerLabel=t.wholeDivideDurations(o.labelInterval,o.slotDuration),o}function d(e,n,r){var i=e;return n.isTimeScale||(i=t.startOfDay(i),n.largeUnit&&(i=r.startOf(i,n.largeUnit))),i}function f(e,n,r,i){if(i.isHiddenDay(e))return!1;if(n.isTimeScale){var o=t.startOfDay(e),a=e.valueOf()-o.valueOf()-t.asRoughMs(r.slotMinTime);return(a=(a%864e5+864e5)%864e5)<n.timeWindowMs}return!0}function h(e,n,r){var i=n.currentRange,o=e.labelInterval;if(!o){var a=void 0;if(e.slotDuration){for(var s=0,l=c;s<l.length;s++){a=l[s];var u=t.createDuration(a),d=t.wholeDivideDurations(u,e.slotDuration);if(null!==d&&d<=6){o=u;break}}o||(o=e.slotDuration)}else for(var f=0,h=c;f<h.length;f++){if(a=h[f],o=t.createDuration(a),r.countDurationsBetween(i.start,i.end,o)>=18)break}e.labelInterval=o}return o}function m(e,n,r){var i=n.currentRange,o=null;return"years"===e?o=r.diffWholeYears(i.start,i.end):"months"===e||"weeks"===e?o=r.diffWholeMonths(i.start,i.end):"days"===e&&(o=t.diffWholeDays(i.start,i.end)),o||0}function p(e,t,n){return{date:e,text:t,rowUnit:n,colspan:1,isWeekStart:!1}}var g=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context;return t.createElement(t.ContentHook,{hookProps:e.hookProps,content:n.options.slotLabelContent,defaultContent:v},(function(n,r){return t.createElement("a",l({ref:n,className:"fc-timeline-slot-cushion fc-scrollgrid-sync-inner"+(e.isSticky?" fc-sticky":"")},e.navLinkAttrs),r)}))},n}(t.BaseComponent);function v(e){return e.text}function y(e){return{level:e.level,date:e.dateEnv.toDate(e.dateMarker),view:e.viewApi,text:e.text}}var D=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.refineHookProps=t.memoizeObjArg(y),n.normalizeClassNames=t.buildClassNameNormalizer(),n.buildCellNavLinkAttrs=t.memoize(S),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,i=r.dateEnv,o=r.options,a=n.cell,s=n.dateProfile,l=n.tDateProfile,c=t.getDateMeta(a.date,n.todayRange,n.nowDate,s),u=["fc-timeline-slot","fc-timeline-slot-label"].concat("time"===a.rowUnit?t.getSlotClassNames(c,r.theme):t.getDayClassNames(c,r.theme));a.isWeekStart&&u.push("fc-timeline-slot-em");var d=this.refineHookProps({level:n.rowLevel,dateMarker:a.date,text:a.text,dateEnv:r.dateEnv,viewApi:r.viewApi}),f=this.normalizeClassNames(o.slotLabelClassNames,d);return t.createElement(t.MountHook,{hookProps:d,didMount:o.slotLabelDidMount,willUnmount:o.slotLabelWillUnmount},(function(o){return t.createElement("th",{ref:o,className:u.concat(f).join(" "),"data-date":i.formatIso(a.date,{omitTime:!l.isTimeScale,omitTimeZoneOffset:!0}),colSpan:a.colspan},t.createElement("div",{className:"fc-timeline-slot-frame",style:{height:n.rowInnerHeight}},t.createElement(g,{hookProps:d,isSticky:n.isSticky,navLinkAttrs:e.buildCellNavLinkAttrs(r,a.date,a.rowUnit)})))}))},n}(t.BaseComponent);function S(e,n,r){return r&&"time"!==r?t.buildNavLinkAttrs(e,n,r):{}}var R=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=e.dateProfile,r=e.tDateProfile,i=e.rowInnerHeights,o=e.todayRange,a=e.nowDate,s=r.cellRows;return t.createElement(t.Fragment,null,s.map((function(e,l){var c=l===s.length-1,u=["fc-timeline-header-row",r.isTimeScale&&c?"fc-timeline-header-row-chrono":""];return t.createElement("tr",{key:l,className:u.join(" ")},e.map((function(e){return t.createElement(D,{key:e.date.toISOString(),cell:e,rowLevel:l,dateProfile:n,tDateProfile:r,todayRange:o,nowDate:a,rowInnerHeight:i&&i[l],isSticky:!c})})))})))},n}(t.BaseComponent),C=function(){function e(e,n,r,i,o,a){this.slatRootEl=e,this.dateProfile=r,this.tDateProfile=i,this.dateEnv=o,this.isRtl=a,this.outerCoordCache=new t.PositionCache(e,n,!0,!1),this.innerCoordCache=new t.PositionCache(e,t.findDirectChildren(n,"div"),!0,!1)}return e.prototype.isDateInRange=function(e){return t.rangeContainsMarker(this.dateProfile.currentRange,e)},e.prototype.dateToCoord=function(e){var t=this.tDateProfile,n=this.computeDateSnapCoverage(e)/t.snapsPerSlot,r=Math.floor(n),i=n-(r=Math.min(r,t.slotCnt-1)),o=this.innerCoordCache,a=this.outerCoordCache;return this.isRtl?a.originClientRect.width-(a.rights[r]-o.getWidth(r)*i):a.lefts[r]+o.getWidth(r)*i},e.prototype.rangeToCoords=function(e){return{start:this.dateToCoord(e.start),end:this.dateToCoord(e.end)}},e.prototype.durationToCoord=function(e){var n=this,r=n.dateProfile,i=n.tDateProfile,o=n.dateEnv,a=n.isRtl,s=0;if(r){var l=o.add(r.activeRange.start,e);i.isTimeScale||(l=t.startOfDay(l)),s=this.dateToCoord(l),!a&&s&&(s+=1)}return s},e.prototype.coordFromLeft=function(e){return this.isRtl?this.outerCoordCache.originClientRect.width-e:e},e.prototype.computeDateSnapCoverage=function(e){return E(e,this.tDateProfile,this.dateEnv)},e}();function E(e,n,r){var i=r.countDurationsBetween(n.normalizedRange.start,e,n.snapDuration);if(i<0)return 0;if(i>=n.snapDiffToIndex.length)return n.snapCnt;var o=Math.floor(i),a=n.snapDiffToIndex[o];return t.isInt(a)?a+=i-o:a=Math.ceil(a),a}function w(e,t){return null===e?{left:"",right:""}:t?{right:e,left:""}:{left:e,right:""}}function b(e,t){return e?t?{right:e.start,left:-e.end}:{left:e.start,right:-e.end}:{left:"",right:""}}var k=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,i=t.greatestDurationDenominator(n.tDateProfile.slotDuration).unit,o=n.slatCoords&&n.slatCoords.dateProfile===n.dateProfile?n.slatCoords:null;return t.createElement(t.NowTimer,{unit:i},(function(i,a){return t.createElement("div",{className:"fc-timeline-header",ref:e.rootElRef},t.createElement("table",{"aria-hidden":!0,className:"fc-scrollgrid-sync-table",style:{minWidth:n.tableMinWidth,width:n.clientWidth}},n.tableColGroupNode,t.createElement("tbody",null,t.createElement(R,{dateProfile:n.dateProfile,tDateProfile:n.tDateProfile,nowDate:i,todayRange:a,rowInnerHeights:n.rowInnerHeights}))),r.options.nowIndicator&&t.createElement("div",{className:"fc-timeline-now-indicator-container"},o&&o.isDateInRange(i)&&t.createElement(t.NowIndicatorRoot,{isAxis:!0,date:i},(function(e,n,a,s){return t.createElement("div",{ref:e,className:["fc-timeline-now-indicator-arrow"].concat(n).join(" "),style:w(o.dateToCoord(i),r.isRtl)},s)}))))}))},n.prototype.componentDidMount=function(){this.updateSize()},n.prototype.componentDidUpdate=function(){this.updateSize()},n.prototype.updateSize=function(){this.props.onMaxCushionWidth&&this.props.onMaxCushionWidth(this.computeMaxCushionWidth())},n.prototype.computeMaxCushionWidth=function(){return Math.max.apply(Math,t.findElements(this.rootElRef.current,".fc-timeline-header-row:last-child .fc-timeline-slot-cushion").map((function(e){return e.getBoundingClientRect().width})))},n}(t.BaseComponent),P=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context,r=n.dateEnv,i=n.options,o=n.theme,a=e.date,s=e.tDateProfile,c=e.isEm,u=t.getDateMeta(e.date,e.todayRange,e.nowDate,e.dateProfile),d=["fc-timeline-slot","fc-timeline-slot-lane"],f={"data-date":r.formatIso(a,{omitTimeZoneOffset:!0,omitTime:!s.isTimeScale})},h=l(l({date:r.toDate(e.date)},u),{view:n.viewApi});return c&&d.push("fc-timeline-slot-em"),s.isTimeScale&&d.push(t.isInt(r.countDurationsBetween(s.normalizedRange.start,e.date,s.labelInterval))?"fc-timeline-slot-major":"fc-timeline-slot-minor"),d.push.apply(d,e.isDay?t.getDayClassNames(u,o):t.getSlotClassNames(u,o)),t.createElement(t.RenderHook,{hookProps:h,classNames:i.slotLaneClassNames,content:i.slotLaneContent,didMount:i.slotLaneDidMount,willUnmount:i.slotLaneWillUnmount,elRef:e.elRef},(function(e,n,r,i){return t.createElement("td",l({ref:e,className:d.concat(n).join(" ")},f),t.createElement("div",{ref:r},i))}))},n}(t.BaseComponent),M=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=e.tDateProfile,r=e.cellElRefs,i=n.slotDates,o=n.isWeekStarts,a=!n.isTimeScale&&!n.largeUnit;return t.createElement("tbody",null,t.createElement("tr",null,i.map((function(i,s){var l=i.toISOString();return t.createElement(P,{key:l,elRef:r.createRef(l),date:i,dateProfile:e.dateProfile,tDateProfile:n,nowDate:e.nowDate,todayRange:e.todayRange,isEm:o[s],isDay:a})}))))},n}(t.BaseComponent),T=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n.cellElRefs=new t.RefMap,n.handleScrollRequest=function(e){var t=n.props.onScrollLeftRequest,r=n.coords;if(t&&r){if(e.time)t(r.coordFromLeft(r.durationToCoord(e.time)));return!0}return null},n}return s(n,e),n.prototype.render=function(){var e=this.props,n=this.context;return t.createElement("div",{className:"fc-timeline-slots",ref:this.rootElRef},t.createElement("table",{"aria-hidden":!0,className:n.theme.getClass("table"),style:{minWidth:e.tableMinWidth,width:e.clientWidth}},e.tableColGroupNode,t.createElement(M,{cellElRefs:this.cellElRefs,dateProfile:e.dateProfile,tDateProfile:e.tDateProfile,nowDate:e.nowDate,todayRange:e.todayRange})))},n.prototype.componentDidMount=function(){this.updateSizing(),this.scrollResponder=this.context.createScrollResponder(this.handleScrollRequest)},n.prototype.componentDidUpdate=function(e){this.updateSizing(),this.scrollResponder.update(e.dateProfile!==this.props.dateProfile)},n.prototype.componentWillUnmount=function(){this.scrollResponder.detach(),this.props.onCoords&&this.props.onCoords(null)},n.prototype.updateSizing=function(){var e,t=this.props,n=this.context;null!==t.clientWidth&&this.scrollResponder&&(this.rootElRef.current.offsetWidth&&(this.coords=new C(this.rootElRef.current,(e=this.cellElRefs.currentMap,t.tDateProfile.slotDates.map((function(t){var n=t.toISOString();return e[n]}))),t.dateProfile,t.tDateProfile,n.dateEnv,n.isRtl),t.onCoords&&t.onCoords(this.coords),this.scrollResponder.update(!1)))},n.prototype.positionToHit=function(e){var n=this.coords.outerCoordCache,r=this.context,i=r.dateEnv,o=r.isRtl,a=this.props.tDateProfile,s=n.leftToIndex(e);if(null!=s){var l=n.getWidth(s),c=o?(n.rights[s]-e)/l:(e-n.lefts[s])/l,u=Math.floor(c*a.snapsPerSlot),d=i.add(a.slotDates[s],t.multiplyDuration(a.snapDuration,u));return{dateSpan:{range:{start:d,end:i.add(d,a.snapDuration)},allDay:!this.props.tDateProfile.isTimeScale},dayEl:this.cellElRefs.currentMap[s],left:n.lefts[s],right:n.rights[s]}}return null},n}(t.BaseComponent);function I(e,t,n){var r=[];if(n)for(var i=0,o=e;i<o.length;i++){var a=o[i],s=n.rangeToCoords(a),l=Math.round(s.start),c=Math.round(s.end);c-l<t&&(c=l+t),r.push({start:l,end:c})}return r}var x=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props,n=[].concat(e.eventResizeSegs,e.dateSelectionSegs);return e.timelineCoords&&t.createElement("div",{className:"fc-timeline-bg"},this.renderSegs(e.businessHourSegs||[],e.timelineCoords,"non-business"),this.renderSegs(e.bgEventSegs||[],e.timelineCoords,"bg-event"),this.renderSegs(n,e.timelineCoords,"highlight"))},n.prototype.renderSegs=function(e,n,r){var i=this.props,o=i.todayRange,a=i.nowDate,s=this.context.isRtl,c=I(e,0,n),u=e.map((function(e,n){var i=b(c[n],s);return t.createElement("div",{key:t.buildEventRangeKey(e.eventRange),className:"fc-timeline-bg-harness",style:i},"bg-event"===r?t.createElement(t.BgEvent,l({seg:e},t.getSegMeta(e,o,a))):t.renderFill(r))}));return t.createElement(t.Fragment,null,u)},n}(t.BaseComponent),W=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.sliceRange=function(e,n,r,i,o){var a=function(e,n,r){if(!n.isTimeScale&&(e=t.computeVisibleDayRange(e),n.largeUnit)){var i=e;((e={start:r.startOf(e.start,n.largeUnit),end:r.startOf(e.end,n.largeUnit)}).end.valueOf()!==i.end.valueOf()||e.end<=e.start)&&(e={start:e.start,end:r.add(e.end,n.slotDuration)})}return e}(e,i,o),s=[];if(E(a.start,i,o)<E(a.end,i,o)){var l=t.intersectRanges(a,i.normalizedRange);l&&s.push({start:l.start,end:l.end,isStart:l.start.valueOf()===a.start.valueOf()&&f(l.start,i,n,r),isEnd:l.end.valueOf()===a.end.valueOf()&&f(t.addMs(l.end,-1),i,n,r)})}return s},n}(t.Slicer),N=t.createFormatter({hour:"numeric",minute:"2-digit",omitZeroMinute:!0,meridiem:"narrow"}),H=function(e){function n(){return null!==e&&e.apply(this,arguments)||this}return s(n,e),n.prototype.render=function(){var e=this.props;return t.createElement(t.StandardEvent,l({},e,{extraClassNames:["fc-timeline-event","fc-h-event"],defaultTimeFormat:N,defaultDisplayEventTime:!e.isTimeScale}))},n}(t.BaseComponent),L=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.rootElRef=t.createRef(),n}return s(n,e),n.prototype.render=function(){var e=this,n=this.props,r=this.context,i=n.hiddenSegs,o=n.elRef,a=n.placement,s=n.resourceId,c=a.top,u=a.hcoords,d=u&&null!==c,f=b(u,r.isRtl),h=s?{resourceId:s}:{};return t.createElement(t.MoreLinkRoot,{allDayDate:null,moreCnt:i.length,allSegs:i,hiddenSegs:i,alignmentElRef:this.rootElRef,dateProfile:n.dateProfile,todayRange:n.todayRange,extraDateSpan:h,popoverContent:function(){return t.createElement(t.Fragment,null,i.map((function(e){var r=e.eventRange.instance.instanceId;return t.createElement("div",{key:r,style:{visibility:n.isForcedInvisible[r]?"hidden":""}},t.createElement(H,l({isTimeScale:n.isTimeScale,seg:e,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:r===n.eventSelection},t.getSegMeta(e,n.todayRange,n.nowDate))))})))}},(function(n,r,i,a,s,u,h,m){return t.createElement("a",{ref:function(r){t.setRef(n,r),t.setRef(o,r),t.setRef(e.rootElRef,r)},className:["fc-timeline-more-link"].concat(r).join(" "),style:l({visibility:d?"":"hidden",top:c||0},f),onClick:s,title:u,"aria-expanded":h,"aria-controls":m},t.createElement("div",{ref:i,className:"fc-timeline-more-link-inner fc-sticky"},a))}))},n}(t.BaseComponent),z=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.slicer=new W,n.sortEventSegs=t.memoize(t.sortEventSegs),n.harnessElRefs=new t.RefMap,n.moreElRefs=new t.RefMap,n.innerElRef=t.createRef(),n.state={eventInstanceHeights:{},moreLinkHeights:{}},n}return s(n,e),n.prototype.render=function(){var e=this,n=e.props,r=e.state,i=e.context,o=i.options,a=n.dateProfile,s=n.tDateProfile,l=this.slicer.sliceProps(n,a,s.isTimeScale?null:n.nextDayThreshold,i,a,i.dateProfileGenerator,s,i.dateEnv),c=(l.eventDrag?l.eventDrag.segs:null)||(l.eventResize?l.eventResize.segs:null)||[],u=this.sortEventSegs(l.fgEventSegs,o.eventOrder),d=function(e,n,r,i,o,a){for(var s=[],l=[],c=0;c<e.length;c+=1){var u=e[c],d=r[u.eventRange.instance.instanceId],f=n[c];d&&f?s.push({index:c,span:f,thickness:d}):l.push({seg:u,hcoords:f,top:null})}var h=new t.SegHierarchy;null!=o&&(h.strictOrder=o),null!=a&&(h.maxStackCnt=a);var m=h.addSegs(s),p=m.map((function(t){return{seg:e[t.index],hcoords:t.span,top:null}})),g=t.groupIntersectingEntries(m),v=[],y=[],D=function(t){return e[t.index]};for(c=0;c<g.length;c+=1){var S=g[c],R=S.entries.map(D);null!=(d=i[t.buildIsoString(t.computeEarliestSegStart(R))])?v.push({index:e.length+c,thickness:d,span:S.span}):y.push({seg:R,hcoords:S.span,top:null})}h.maxStackCnt=-1,h.addSegs(v);for(var C=[],E=0,w=0,b=h.toRects();w<b.length;w++){var k=b[w],P=k.index;C.push({seg:P<e.length?e[P]:g[P-e.length].entries.map(D),hcoords:k.span,top:k.levelCoord}),E=Math.max(E,k.levelCoord+k.thickness)}return[C.concat(l,p,y),E]}(u,I(u,o.eventMinWidth,n.timelineCoords),r.eventInstanceHeights,r.moreLinkHeights,o.eventOrderStrict,o.eventMaxStack),f=d[0],h=d[1],m=(l.eventDrag?l.eventDrag.affectedInstances:null)||(l.eventResize?l.eventResize.affectedInstances:null)||{};return t.createElement(t.Fragment,null,t.createElement(x,{businessHourSegs:l.businessHourSegs,bgEventSegs:l.bgEventSegs,timelineCoords:n.timelineCoords,eventResizeSegs:l.eventResize?l.eventResize.segs:[],dateSelectionSegs:l.dateSelectionSegs,nowDate:n.nowDate,todayRange:n.todayRange}),t.createElement("div",{className:"fc-timeline-events fc-scrollgrid-sync-inner",ref:this.innerElRef,style:{height:h}},this.renderFgSegs(f,m,!1,!1,!1),this.renderFgSegs(function(e,t,n){if(!e.length||!t)return[];var r=function(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n],o=i.seg;Array.isArray(o)||(t[o.eventRange.instance.instanceId]=i.top)}return t}(n);return e.map((function(e){return{seg:e,hcoords:t.rangeToCoords(e),top:r[e.eventRange.instance.instanceId]}}))}(c,n.timelineCoords,f),{},Boolean(l.eventDrag),Boolean(l.eventResize),!1)))},n.prototype.componentDidMount=function(){this.updateSize()},n.prototype.componentDidUpdate=function(e,t){e.eventStore===this.props.eventStore&&e.timelineCoords===this.props.timelineCoords&&t.moreLinkHeights===this.state.moreLinkHeights||this.updateSize()},n.prototype.updateSize=function(){var e=this.props,n=e.timelineCoords,r=this.innerElRef.current;e.onHeightChange&&e.onHeightChange(r,!1),n&&this.setState({eventInstanceHeights:t.mapHash(this.harnessElRefs.currentMap,(function(e){return Math.round(e.getBoundingClientRect().height)})),moreLinkHeights:t.mapHash(this.moreElRefs.currentMap,(function(e){return Math.round(e.getBoundingClientRect().height)}))},(function(){e.onHeightChange&&e.onHeightChange(r,!0)})),e.syncParentMinHeight&&(r.parentElement.style.minHeight=r.style.height)},n.prototype.renderFgSegs=function(e,n,r,i,o){var a=this,s=a.harnessElRefs,c=a.moreElRefs,u=a.props,d=a.context,f=r||i||o;return t.createElement(t.Fragment,null,e.map((function(e){var a=e.seg,h=e.hcoords,m=e.top;if(Array.isArray(a)){var p=t.buildIsoString(t.computeEarliestSegStart(a));return t.createElement(L,{key:"m:"+p,elRef:c.createRef(p),hiddenSegs:a,placement:e,dateProfile:u.dateProfile,nowDate:u.nowDate,todayRange:u.todayRange,isTimeScale:u.tDateProfile.isTimeScale,eventSelection:u.eventSelection,resourceId:u.resourceId,isForcedInvisible:n})}var g=a.eventRange.instance.instanceId,v=f||Boolean(!n[g]&&h&&null!==m),y=b(h,d.isRtl);return t.createElement("div",{key:"e:"+g,ref:f?null:s.createRef(g),className:"fc-timeline-event-harness",style:l({visibility:v?"":"hidden",top:m||0},y)},t.createElement(H,l({isTimeScale:u.tDateProfile.isTimeScale,seg:a,isDragging:r,isResizing:i,isDateSelecting:o,isSelected:g===u.eventSelection},t.getSegMeta(a,u.todayRange,u.nowDate))))})))},n}(t.BaseComponent);z.addStateEquality({eventInstanceHeights:t.isPropsEqual,moreLinkHeights:t.isPropsEqual});var O=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.slatsRef=t.createRef(),n.state={coords:null},n.handeEl=function(e){e?n.context.registerInteractiveComponent(n,{el:e}):n.context.unregisterInteractiveComponent(n)},n.handleCoords=function(e){n.setState({coords:e}),n.props.onSlatCoords&&n.props.onSlatCoords(e)},n}return s(n,e),n.prototype.render=function(){var e=this,n=this,r=n.props,i=n.state,o=n.context,a=o.options,s=r.dateProfile,l=r.tDateProfile,c=t.greatestDurationDenominator(l.slotDuration).unit;return t.createElement("div",{className:"fc-timeline-body",ref:this.handeEl,style:{minWidth:r.tableMinWidth,height:r.clientHeight,width:r.clientWidth}},t.createElement(t.NowTimer,{unit:c},(function(n,c){return t.createElement(t.Fragment,null,t.createElement(T,{ref:e.slatsRef,dateProfile:s,tDateProfile:l,nowDate:n,todayRange:c,clientWidth:r.clientWidth,tableColGroupNode:r.tableColGroupNode,tableMinWidth:r.tableMinWidth,onCoords:e.handleCoords,onScrollLeftRequest:r.onScrollLeftRequest}),t.createElement(z,{dateProfile:s,tDateProfile:r.tDateProfile,nowDate:n,todayRange:c,nextDayThreshold:a.nextDayThreshold,businessHours:r.businessHours,eventStore:r.eventStore,eventUiBases:r.eventUiBases,dateSelection:r.dateSelection,eventSelection:r.eventSelection,eventDrag:r.eventDrag,eventResize:r.eventResize,timelineCoords:i.coords,syncParentMinHeight:!0}),a.nowIndicator&&i.coords&&i.coords.isDateInRange(n)&&t.createElement("div",{className:"fc-timeline-now-indicator-container"},t.createElement(t.NowIndicatorRoot,{isAxis:!1,date:n},(function(e,r,a,s){return t.createElement("div",{ref:e,className:["fc-timeline-now-indicator-line"].concat(r).join(" "),style:w(i.coords.dateToCoord(n),o.isRtl)},s)}))))})))},n.prototype.queryHit=function(e,t,n,r){var i=this.slatsRef.current.positionToHit(e);return i?{dateProfile:this.props.dateProfile,dateSpan:i.dateSpan,rect:{left:i.left,right:i.right,top:0,bottom:r},dayEl:i.dayEl,layer:0}:null},n}(t.DateComponent),B=function(e){function n(){var n=null!==e&&e.apply(this,arguments)||this;return n.buildTimelineDateProfile=t.memoize(u),n.scrollGridRef=t.createRef(),n.state={slatCoords:null,slotCushionMaxWidth:null},n.handleSlatCoords=function(e){n.setState({slatCoords:e})},n.handleScrollLeftRequest=function(e){n.scrollGridRef.current.forceScrollLeft(0,e)},n.handleMaxCushionWidth=function(e){n.setState({slotCushionMaxWidth:Math.ceil(e)})},n}return s(n,e),n.prototype.render=function(){var e=this,n=this,i=n.props,o=n.state,a=n.context,s=a.options,c=!i.forPrint&&t.getStickyHeaderDates(s),u=!i.forPrint&&t.getStickyFooterScrollbar(s),d=this.buildTimelineDateProfile(i.dateProfile,a.dateEnv,s,a.dateProfileGenerator),f=["fc-timeline",!1===s.eventOverlap?"fc-timeline-overlap-disabled":""],h=s.slotMinWidth,m=F(d,h||this.computeFallbackSlotMinWidth(d)),p=[{type:"header",key:"header",isSticky:c,chunks:[{key:"timeline",content:function(n){return t.createElement(k,{dateProfile:i.dateProfile,clientWidth:n.clientWidth,clientHeight:n.clientHeight,tableMinWidth:n.tableMinWidth,tableColGroupNode:n.tableColGroupNode,tDateProfile:d,slatCoords:o.slatCoords,onMaxCushionWidth:h?null:e.handleMaxCushionWidth})}}]},{type:"body",key:"body",liquid:!0,chunks:[{key:"timeline",content:function(n){return t.createElement(O,l({},i,{clientWidth:n.clientWidth,clientHeight:n.clientHeight,tableMinWidth:n.tableMinWidth,tableColGroupNode:n.tableColGroupNode,tDateProfile:d,onSlatCoords:e.handleSlatCoords,onScrollLeftRequest:e.handleScrollLeftRequest}))}}]}];return u&&p.push({type:"footer",key:"footer",isSticky:!0,chunks:[{key:"timeline",content:t.renderScrollShim}]}),t.createElement(t.ViewRoot,{viewSpec:a.viewSpec},(function(n,o){return t.createElement("div",{ref:n,className:f.concat(o).join(" ")},t.createElement(r.ScrollGrid,{ref:e.scrollGridRef,liquid:!i.isHeightAuto&&!i.forPrint,collapsibleWidth:!1,colGroups:[{cols:m}],sections:p}))}))},n.prototype.computeFallbackSlotMinWidth=function(e){return Math.max(30,(this.state.slotCushionMaxWidth||0)/e.slotsPerLabel)},n}(t.DateComponent);function F(e,t){return[{span:e.slotCnt,minWidth:t||1}]}var A=t.createPlugin({deps:[o.default],initialView:"timelineDay",views:{timeline:{component:B,usesMinMaxTime:!0,eventResizableFromStart:!0},timelineDay:{type:"timeline",duration:{days:1}},timelineWeek:{type:"timeline",duration:{weeks:1}},timelineMonth:{type:"timeline",duration:{months:1}},timelineYear:{type:"timeline",duration:{years:1}}}});return t.globalPlugins.push(A),e.TimelineCoords=C,e.TimelineHeader=k,e.TimelineHeaderRows=R,e.TimelineLane=z,e.TimelineLaneBg=x,e.TimelineLaneSlicer=W,e.TimelineSlats=T,e.TimelineView=B,e.buildSlatCols=F,e.buildTimelineDateProfile=u,e.coordToCss=w,e.coordsToCss=b,e.default=A,Object.defineProperty(e,"__esModule",{value:!0}),e}({},FullCalendar,FullCalendarPremiumCommon,FullCalendarScrollGrid);
package/main.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- FullCalendar Scheduler v5.11.2
2
+ FullCalendar Scheduler v5.11.3
3
3
  Docs & License: https://fullcalendar.io/scheduler
4
4
  (c) 2022 Adam Shaw
5
5
  */
@@ -1094,11 +1094,11 @@ var TimelineLane = /** @class */ (function (_super) {
1094
1094
  }
1095
1095
  };
1096
1096
  TimelineLane.prototype.updateSize = function () {
1097
- var _this = this;
1098
1097
  var props = this.props;
1099
1098
  var timelineCoords = props.timelineCoords;
1099
+ var innerEl = this.innerElRef.current;
1100
1100
  if (props.onHeightChange) {
1101
- props.onHeightChange(this.innerElRef.current, false);
1101
+ props.onHeightChange(innerEl, false);
1102
1102
  }
1103
1103
  if (timelineCoords) {
1104
1104
  this.setState({
@@ -1106,10 +1106,14 @@ var TimelineLane = /** @class */ (function (_super) {
1106
1106
  moreLinkHeights: mapHash(this.moreElRefs.currentMap, function (moreEl) { return (Math.round(moreEl.getBoundingClientRect().height)); }),
1107
1107
  }, function () {
1108
1108
  if (props.onHeightChange) {
1109
- props.onHeightChange(_this.innerElRef.current, true);
1109
+ props.onHeightChange(innerEl, true);
1110
1110
  }
1111
1111
  });
1112
1112
  }
1113
+ // hack
1114
+ if (props.syncParentMinHeight) {
1115
+ innerEl.parentElement.style.minHeight = innerEl.style.height;
1116
+ }
1113
1117
  };
1114
1118
  TimelineLane.prototype.renderFgSegs = function (segPlacements, isForcedInvisible, isDragging, isResizing, isDateSelecting) {
1115
1119
  var _a = this, harnessElRefs = _a.harnessElRefs, moreElRefs = _a.moreElRefs, props = _a.props, context = _a.context;
@@ -1193,7 +1197,7 @@ var TimelineGrid = /** @class */ (function (_super) {
1193
1197
  } },
1194
1198
  createElement(NowTimer, { unit: timerUnit }, function (nowDate, todayRange) { return (createElement(Fragment, null,
1195
1199
  createElement(TimelineSlats, { ref: _this.slatsRef, dateProfile: dateProfile, tDateProfile: tDateProfile, nowDate: nowDate, todayRange: todayRange, clientWidth: props.clientWidth, tableColGroupNode: props.tableColGroupNode, tableMinWidth: props.tableMinWidth, onCoords: _this.handleCoords, onScrollLeftRequest: props.onScrollLeftRequest }),
1196
- createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords }),
1200
+ createElement(TimelineLane, { dateProfile: dateProfile, tDateProfile: props.tDateProfile, nowDate: nowDate, todayRange: todayRange, nextDayThreshold: options.nextDayThreshold, businessHours: props.businessHours, eventStore: props.eventStore, eventUiBases: props.eventUiBases, dateSelection: props.dateSelection, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, timelineCoords: state.coords, syncParentMinHeight: true }),
1197
1201
  (options.nowIndicator && state.coords && state.coords.isDateInRange(nowDate)) && (createElement("div", { className: "fc-timeline-now-indicator-container" },
1198
1202
  createElement(NowIndicatorRoot, { isAxis: false, date: nowDate }, function (rootElRef, classNames, innerElRef, innerContent) { return (createElement("div", { ref: rootElRef, className: ['fc-timeline-now-indicator-line'].concat(classNames).join(' '), style: coordToCss(state.coords.dateToCoord(nowDate), context.isRtl) }, innerContent)); }))))); })));
1199
1203
  };
package/main.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"main.js","sources":["src/timeline-date-profile.ts","src/TimelineHeaderThInner.tsx","src/TimelineHeaderTh.tsx","src/TimelineHeaderRows.tsx","src/TimelineCoords.ts","src/TimelineHeader.tsx","src/TimelineSlatCell.tsx","src/TimelineSlatsBody.tsx","src/TimelineSlats.tsx","src/event-placement.ts","src/TimelineLaneBg.tsx","src/TimelineLaneSlicer.ts","src/TimelineEvent.tsx","src/TimelineLaneMoreLink.tsx","src/TimelineLane.tsx","src/TimelineGrid.tsx","src/TimelineView.tsx","src/main.ts"],"sourcesContent":["import {\n config, computeVisibleDayRange, Duration, DateProfile, asCleanDays, addDays, wholeDivideDurations, DateMarker,\n startOfDay, createDuration, DateEnv, diffWholeDays, asRoughMs, createFormatter, greatestDurationDenominator,\n asRoughMinutes, padStart, asRoughSeconds, DateRange, isInt, DateProfileGenerator, BaseOptionsRefined,\n} from '@fullcalendar/common'\n\nexport interface TimelineDateProfile {\n labelInterval: Duration\n slotDuration: Duration\n slotsPerLabel: number\n headerFormats: any\n isTimeScale: boolean\n largeUnit: string\n emphasizeWeeks: boolean\n snapDuration: Duration\n snapsPerSlot: number\n normalizedRange: DateRange // snaps to unit. adds in slotMinTime/slotMaxTime\n timeWindowMs: number\n slotDates: DateMarker[]\n isWeekStarts: boolean[]\n snapDiffToIndex: number[]\n snapIndexToDiff: number[]\n snapCnt: number\n slotCnt: number\n cellRows: TimelineHeaderCell[][]\n}\n\nexport interface TimelineHeaderCell {\n date: DateMarker\n text: string\n rowUnit: string\n colspan: number\n isWeekStart: boolean\n}\n\nconst MIN_AUTO_LABELS = 18 // more than `12` months but less that `24` hours\nconst MAX_AUTO_SLOTS_PER_LABEL = 6 // allows 6 10-min slots in an hour\nconst MAX_AUTO_CELLS = 200 // allows 4-days to have a :30 slot duration\nconfig.MAX_TIMELINE_SLOTS = 1000\n\n// potential nice values for slot-duration and interval-duration\nconst STOCK_SUB_DURATIONS = [ // from largest to smallest\n { years: 1 },\n { months: 1 },\n { days: 1 },\n { hours: 1 },\n { minutes: 30 },\n { minutes: 15 },\n { minutes: 10 },\n { minutes: 5 },\n { minutes: 1 },\n { seconds: 30 },\n { seconds: 15 },\n { seconds: 10 },\n { seconds: 5 },\n { seconds: 1 },\n { milliseconds: 500 },\n { milliseconds: 100 },\n { milliseconds: 10 },\n { milliseconds: 1 },\n]\n\nexport function buildTimelineDateProfile(\n dateProfile: DateProfile,\n dateEnv: DateEnv,\n allOptions: BaseOptionsRefined,\n dateProfileGenerator: DateProfileGenerator,\n): TimelineDateProfile {\n let tDateProfile = {\n labelInterval: allOptions.slotLabelInterval,\n slotDuration: allOptions.slotDuration,\n } as TimelineDateProfile\n\n validateLabelAndSlot(tDateProfile, dateProfile, dateEnv) // validate after computed grid duration\n ensureLabelInterval(tDateProfile, dateProfile, dateEnv)\n ensureSlotDuration(tDateProfile, dateProfile, dateEnv)\n\n let input = allOptions.slotLabelFormat\n let rawFormats =\n Array.isArray(input) ? input :\n (input != null) ? [input] :\n computeHeaderFormats(tDateProfile, dateProfile, dateEnv, allOptions)\n\n tDateProfile.headerFormats = rawFormats.map((rawFormat) => createFormatter(rawFormat))\n\n tDateProfile.isTimeScale = Boolean(tDateProfile.slotDuration.milliseconds)\n\n let largeUnit = null\n if (!tDateProfile.isTimeScale) {\n const slotUnit = greatestDurationDenominator(tDateProfile.slotDuration).unit\n if (/year|month|week/.test(slotUnit)) {\n largeUnit = slotUnit\n }\n }\n\n tDateProfile.largeUnit = largeUnit\n\n tDateProfile.emphasizeWeeks =\n asCleanDays(tDateProfile.slotDuration) === 1 &&\n currentRangeAs('weeks', dateProfile, dateEnv) >= 2 &&\n !allOptions.businessHours\n\n /*\n console.log('label interval =', timelineView.labelInterval.humanize())\n console.log('slot duration =', timelineView.slotDuration.humanize())\n console.log('header formats =', timelineView.headerFormats)\n console.log('isTimeScale', timelineView.isTimeScale)\n console.log('largeUnit', timelineView.largeUnit)\n */\n\n let rawSnapDuration = allOptions.snapDuration\n let snapDuration\n let snapsPerSlot\n\n if (rawSnapDuration) {\n snapDuration = createDuration(rawSnapDuration)\n snapsPerSlot = wholeDivideDurations(tDateProfile.slotDuration, snapDuration)\n // ^ TODO: warning if not whole?\n }\n\n if (snapsPerSlot == null) {\n snapDuration = tDateProfile.slotDuration\n snapsPerSlot = 1\n }\n\n tDateProfile.snapDuration = snapDuration\n tDateProfile.snapsPerSlot = snapsPerSlot\n\n // more...\n\n let timeWindowMs = asRoughMs(dateProfile.slotMaxTime) - asRoughMs(dateProfile.slotMinTime)\n\n // TODO: why not use normalizeRange!?\n let normalizedStart = normalizeDate(dateProfile.renderRange.start, tDateProfile, dateEnv)\n let normalizedEnd = normalizeDate(dateProfile.renderRange.end, tDateProfile, dateEnv)\n\n // apply slotMinTime/slotMaxTime\n // TODO: View should be responsible.\n if (tDateProfile.isTimeScale) {\n normalizedStart = dateEnv.add(normalizedStart, dateProfile.slotMinTime)\n normalizedEnd = dateEnv.add(\n addDays(normalizedEnd, -1),\n dateProfile.slotMaxTime,\n )\n }\n\n tDateProfile.timeWindowMs = timeWindowMs\n tDateProfile.normalizedRange = { start: normalizedStart, end: normalizedEnd }\n\n let slotDates = []\n let date = normalizedStart\n while (date < normalizedEnd) {\n if (isValidDate(date, tDateProfile, dateProfile, dateProfileGenerator)) {\n slotDates.push(date)\n }\n date = dateEnv.add(date, tDateProfile.slotDuration)\n }\n\n tDateProfile.slotDates = slotDates\n\n // more...\n\n let snapIndex = -1\n let snapDiff = 0 // index of the diff :(\n const snapDiffToIndex = []\n const snapIndexToDiff = []\n\n date = normalizedStart\n while (date < normalizedEnd) {\n if (isValidDate(date, tDateProfile, dateProfile, dateProfileGenerator)) {\n snapIndex += 1\n snapDiffToIndex.push(snapIndex)\n snapIndexToDiff.push(snapDiff)\n } else {\n snapDiffToIndex.push(snapIndex + 0.5)\n }\n date = dateEnv.add(date, tDateProfile.snapDuration)\n snapDiff += 1\n }\n\n tDateProfile.snapDiffToIndex = snapDiffToIndex\n tDateProfile.snapIndexToDiff = snapIndexToDiff\n\n tDateProfile.snapCnt = snapIndex + 1 // is always one behind\n tDateProfile.slotCnt = tDateProfile.snapCnt / tDateProfile.snapsPerSlot\n\n // more...\n\n tDateProfile.isWeekStarts = buildIsWeekStarts(tDateProfile, dateEnv)\n tDateProfile.cellRows = buildCellRows(tDateProfile, dateEnv)\n tDateProfile.slotsPerLabel = wholeDivideDurations(tDateProfile.labelInterval, tDateProfile.slotDuration)\n\n return tDateProfile\n}\n\n/*\nsnaps to appropriate unit\n*/\nexport function normalizeDate(date: DateMarker, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): DateMarker {\n let normalDate = date\n\n if (!tDateProfile.isTimeScale) {\n normalDate = startOfDay(normalDate)\n\n if (tDateProfile.largeUnit) {\n normalDate = dateEnv.startOf(normalDate, tDateProfile.largeUnit)\n }\n }\n\n return normalDate\n}\n\n/*\nsnaps to appropriate unit\n*/\nexport function normalizeRange(range: DateRange, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): DateRange {\n if (!tDateProfile.isTimeScale) {\n range = computeVisibleDayRange(range)\n\n if (tDateProfile.largeUnit) {\n let dayRange = range // preserve original result\n\n range = {\n start: dateEnv.startOf(range.start, tDateProfile.largeUnit),\n end: dateEnv.startOf(range.end, tDateProfile.largeUnit),\n }\n\n // if date is partially through the interval, or is in the same interval as the start,\n // make the exclusive end be the *next* interval\n if (range.end.valueOf() !== dayRange.end.valueOf() || range.end <= range.start) {\n range = {\n start: range.start,\n end: dateEnv.add(range.end, tDateProfile.slotDuration),\n }\n }\n }\n }\n\n return range\n}\n\nexport function isValidDate(\n date: DateMarker,\n tDateProfile: TimelineDateProfile,\n dateProfile: DateProfile,\n dateProfileGenerator: DateProfileGenerator,\n) {\n if (dateProfileGenerator.isHiddenDay(date)) {\n return false\n }\n\n if (tDateProfile.isTimeScale) {\n // determine if the time is within slotMinTime/slotMaxTime, which may have wacky values\n let day = startOfDay(date)\n let timeMs = date.valueOf() - day.valueOf()\n let ms = timeMs - asRoughMs(dateProfile.slotMinTime) // milliseconds since slotMinTime\n ms = ((ms % 86400000) + 86400000) % 86400000 // make negative values wrap to 24hr clock\n return ms < tDateProfile.timeWindowMs // before the slotMaxTime?\n }\n\n return true\n}\n\nfunction validateLabelAndSlot(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n\n // make sure labelInterval doesn't exceed the max number of cells\n if (tDateProfile.labelInterval) {\n const labelCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n tDateProfile.labelInterval,\n )\n if (labelCnt > config.MAX_TIMELINE_SLOTS) {\n console.warn('slotLabelInterval results in too many cells')\n tDateProfile.labelInterval = null\n }\n }\n\n // make sure slotDuration doesn't exceed the maximum number of cells\n if (tDateProfile.slotDuration) {\n const slotCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n tDateProfile.slotDuration,\n )\n if (slotCnt > config.MAX_TIMELINE_SLOTS) {\n console.warn('slotDuration results in too many cells')\n tDateProfile.slotDuration = null\n }\n }\n\n // make sure labelInterval is a multiple of slotDuration\n if (tDateProfile.labelInterval && tDateProfile.slotDuration) {\n const slotsPerLabel = wholeDivideDurations(tDateProfile.labelInterval, tDateProfile.slotDuration)\n if (slotsPerLabel === null || slotsPerLabel < 1) {\n console.warn('slotLabelInterval must be a multiple of slotDuration')\n tDateProfile.slotDuration = null\n }\n }\n}\n\nfunction ensureLabelInterval(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n let { labelInterval } = tDateProfile\n\n if (!labelInterval) {\n // compute based off the slot duration\n // find the largest label interval with an acceptable slots-per-label\n let input\n if (tDateProfile.slotDuration) {\n for (input of STOCK_SUB_DURATIONS) {\n const tryLabelInterval = createDuration(input)\n const slotsPerLabel = wholeDivideDurations(tryLabelInterval, tDateProfile.slotDuration)\n if (slotsPerLabel !== null && slotsPerLabel <= MAX_AUTO_SLOTS_PER_LABEL) {\n labelInterval = tryLabelInterval\n break\n }\n }\n\n // use the slot duration as a last resort\n if (!labelInterval) {\n labelInterval = tDateProfile.slotDuration\n }\n\n // compute based off the view's duration\n // find the largest label interval that yields the minimum number of labels\n } else {\n for (input of STOCK_SUB_DURATIONS) {\n labelInterval = createDuration(input)\n const labelCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n labelInterval,\n )\n if (labelCnt >= MIN_AUTO_LABELS) {\n break\n }\n }\n }\n\n tDateProfile.labelInterval = labelInterval\n }\n\n return labelInterval\n}\n\nfunction ensureSlotDuration(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n let { slotDuration } = tDateProfile\n\n if (!slotDuration) {\n const labelInterval = ensureLabelInterval(tDateProfile, dateProfile, dateEnv) // will compute if necessary\n\n // compute based off the label interval\n // find the largest slot duration that is different from labelInterval, but still acceptable\n for (let input of STOCK_SUB_DURATIONS) {\n const trySlotDuration = createDuration(input)\n const slotsPerLabel = wholeDivideDurations(labelInterval, trySlotDuration)\n if (slotsPerLabel !== null && slotsPerLabel > 1 && slotsPerLabel <= MAX_AUTO_SLOTS_PER_LABEL) {\n slotDuration = trySlotDuration\n break\n }\n }\n\n // only allow the value if it won't exceed the view's # of slots limit\n if (slotDuration) {\n const slotCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n slotDuration,\n )\n if (slotCnt > MAX_AUTO_CELLS) {\n slotDuration = null\n }\n }\n\n // use the label interval as a last resort\n if (!slotDuration) {\n slotDuration = labelInterval\n }\n\n tDateProfile.slotDuration = slotDuration\n }\n\n return slotDuration\n}\n\nfunction computeHeaderFormats(\n tDateProfile: TimelineDateProfile,\n dateProfile: DateProfile,\n dateEnv: DateEnv,\n allOptions: BaseOptionsRefined,\n) {\n let format1\n let format2\n const { labelInterval } = tDateProfile\n let unit = greatestDurationDenominator(labelInterval).unit\n const weekNumbersVisible = allOptions.weekNumbers\n let format0 = (format1 = (format2 = null))\n\n // NOTE: weekNumber computation function wont work\n\n if ((unit === 'week') && !weekNumbersVisible) {\n unit = 'day'\n }\n\n switch (unit) {\n case 'year':\n format0 = { year: 'numeric' } // '2015'\n break\n\n case 'month':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric' } // '2015'\n }\n\n format1 = { month: 'short' } // 'Jan'\n break\n\n case 'week':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric' } // '2015'\n }\n\n format1 = { week: 'narrow' } // 'Wk4'\n break\n\n case 'day':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric', month: 'long' } // 'January 2014'\n } else if (currentRangeAs('months', dateProfile, dateEnv) > 1) {\n format0 = { month: 'long' } // 'January'\n }\n\n if (weekNumbersVisible) {\n format1 = { week: 'short' } // 'Wk 4'\n }\n\n format2 = { weekday: 'narrow', day: 'numeric' } // 'Su 9'\n break\n\n case 'hour':\n if (weekNumbersVisible) {\n format0 = { week: 'short' } // 'Wk 4'\n }\n\n if (currentRangeAs('days', dateProfile, dateEnv) > 1) {\n format1 = { weekday: 'short', day: 'numeric', month: 'numeric', omitCommas: true } // Sat 4/7\n }\n\n format2 = {\n hour: 'numeric',\n minute: '2-digit',\n omitZeroMinute: true,\n meridiem: 'short',\n }\n break\n\n case 'minute':\n // sufficiently large number of different minute cells?\n if ((asRoughMinutes(labelInterval) / 60) >= MAX_AUTO_SLOTS_PER_LABEL) {\n format0 = {\n hour: 'numeric',\n meridiem: 'short',\n }\n format1 = (params) => (\n ':' + padStart(params.date.minute, 2) // ':30'\n )\n } else {\n format0 = {\n hour: 'numeric',\n minute: 'numeric',\n meridiem: 'short',\n }\n }\n break\n\n case 'second':\n // sufficiently large number of different second cells?\n if ((asRoughSeconds(labelInterval) / 60) >= MAX_AUTO_SLOTS_PER_LABEL) {\n format0 = { hour: 'numeric', minute: '2-digit', meridiem: 'lowercase' } // '8:30 PM'\n format1 = (params) => (\n ':' + padStart(params.date.second, 2) // ':30'\n )\n } else {\n format0 = { hour: 'numeric', minute: '2-digit', second: '2-digit', meridiem: 'lowercase' } // '8:30:45 PM'\n }\n break\n\n case 'millisecond':\n format0 = { hour: 'numeric', minute: '2-digit', second: '2-digit', meridiem: 'lowercase' } // '8:30:45 PM'\n format1 = (params) => (\n '.' + padStart(params.millisecond, 3)\n )\n break\n }\n\n return [].concat(format0 || [], format1 || [], format2 || [])\n}\n\n// Compute the number of the give units in the \"current\" range.\n// Won't go more precise than days.\n// Will return `0` if there's not a clean whole interval.\nfunction currentRangeAs(unit: string, dateProfile: DateProfile, dateEnv: DateEnv) {\n let range = dateProfile.currentRange\n let res = null\n\n if (unit === 'years') {\n res = dateEnv.diffWholeYears(range.start, range.end)\n } else if (unit === 'months') {\n res = dateEnv.diffWholeMonths(range.start, range.end)\n } else if (unit === 'weeks') {\n res = dateEnv.diffWholeMonths(range.start, range.end)\n } else if (unit === 'days') {\n res = diffWholeDays(range.start, range.end)\n }\n\n return res || 0\n}\n\nfunction buildIsWeekStarts(tDateProfile: TimelineDateProfile, dateEnv: DateEnv) {\n let { slotDates, emphasizeWeeks } = tDateProfile\n let prevWeekNumber = null\n let isWeekStarts: boolean[] = []\n\n for (let slotDate of slotDates) {\n let weekNumber = dateEnv.computeWeekNumber(slotDate)\n let isWeekStart = emphasizeWeeks && (prevWeekNumber !== null) && (prevWeekNumber !== weekNumber)\n prevWeekNumber = weekNumber\n\n isWeekStarts.push(isWeekStart)\n }\n\n return isWeekStarts\n}\n\nfunction buildCellRows(tDateProfile: TimelineDateProfile, dateEnv: DateEnv) {\n let slotDates = tDateProfile.slotDates\n let formats = tDateProfile.headerFormats\n let cellRows = formats.map(() => []) // indexed by row,col\n let slotAsDays = asCleanDays(tDateProfile.slotDuration)\n let guessedSlotUnit =\n slotAsDays === 7 ? 'week' :\n slotAsDays === 1 ? 'day' :\n null\n\n // specifically for navclicks\n let rowUnitsFromFormats = formats.map(\n (format) => (format.getLargestUnit ? format.getLargestUnit() : null),\n )\n\n // builds cellRows and slotCells\n for (let i = 0; i < slotDates.length; i += 1) {\n let date = slotDates[i]\n let isWeekStart = tDateProfile.isWeekStarts[i]\n\n for (let row = 0; row < formats.length; row += 1) {\n let format = formats[row]\n let rowCells = cellRows[row]\n let leadingCell = rowCells[rowCells.length - 1]\n let isLastRow = row === formats.length - 1\n let isSuperRow = formats.length > 1 && !isLastRow // more than one row and not the last\n let newCell = null\n let rowUnit = rowUnitsFromFormats[row] || (isLastRow ? guessedSlotUnit : null)\n\n if (isSuperRow) {\n let text = dateEnv.format(date, format)\n if (!leadingCell || (leadingCell.text !== text)) {\n newCell = buildCellObject(date, text, rowUnit)\n } else {\n leadingCell.colspan += 1\n }\n } else if (\n !leadingCell ||\n isInt(dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n date,\n tDateProfile.labelInterval,\n ))\n ) {\n let text = dateEnv.format(date, format)\n newCell = buildCellObject(date, text, rowUnit)\n } else {\n leadingCell.colspan += 1\n }\n\n if (newCell) {\n newCell.weekStart = isWeekStart\n rowCells.push(newCell)\n }\n }\n }\n\n return cellRows\n}\n\nfunction buildCellObject(date: DateMarker, text, rowUnit): TimelineHeaderCell {\n return { date, text, rowUnit, colspan: 1, isWeekStart: false }\n}\n","import { createElement, BaseComponent, DateMarker, ContentHook, ViewApi, DateEnv } from '@fullcalendar/common'\n\nexport interface TimelineHeaderThInnerProps {\n hookProps: HookProps\n isSticky: boolean\n navLinkAttrs: object | null\n}\n\nexport class TimelineHeaderThInner extends BaseComponent<TimelineHeaderThInnerProps> {\n render() {\n let { props, context } = this\n\n return (\n <ContentHook hookProps={props.hookProps} content={context.options.slotLabelContent} defaultContent={renderInnerContent}>\n {(innerElRef, innerContent) => (\n <a\n ref={innerElRef}\n className={'fc-timeline-slot-cushion fc-scrollgrid-sync-inner' + (props.isSticky ? ' fc-sticky' : '')}\n {...props.navLinkAttrs}\n >\n {innerContent}\n </a>\n )}\n </ContentHook>\n )\n }\n}\n\nfunction renderInnerContent(props) { // TODO: add types\n return props.text\n}\n\n// hook props\n// ----------\n\nexport interface HookPropsInput {\n level: number\n dateMarker: DateMarker\n text: string\n dateEnv: DateEnv\n viewApi: ViewApi\n}\n\nexport interface HookProps {\n level: number\n date: DateMarker // localized\n view: ViewApi\n text: string\n}\n\nexport function refineHookProps(input: HookPropsInput): HookProps {\n return {\n level: input.level,\n date: input.dateEnv.toDate(input.dateMarker),\n view: input.viewApi,\n text: input.text,\n }\n}\n","import {\n createElement, BaseComponent, DateRange, DateMarker, getDateMeta, getSlotClassNames,\n buildNavLinkAttrs, buildClassNameNormalizer, MountHook,\n getDayClassNames, DateProfile, memoizeObjArg, ViewContext, memoize,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile, TimelineHeaderCell } from './timeline-date-profile'\nimport { TimelineHeaderThInner, refineHookProps, HookProps } from './TimelineHeaderThInner'\n\nexport interface TimelineHeaderThProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n rowLevel: number\n cell: TimelineHeaderCell\n todayRange: DateRange\n nowDate: DateMarker\n rowInnerHeight?: number\n isSticky: boolean\n}\n\nexport class TimelineHeaderTh extends BaseComponent<TimelineHeaderThProps> {\n refineHookProps = memoizeObjArg(refineHookProps)\n normalizeClassNames = buildClassNameNormalizer<HookProps>()\n buildCellNavLinkAttrs = memoize(buildCellNavLinkAttrs)\n\n render() {\n let { props, context } = this\n let { dateEnv, options } = context\n let { cell, dateProfile, tDateProfile } = props\n\n // the cell.rowUnit is f'd\n // giving 'month' for a 3-day view\n // workaround: to infer day, do NOT time\n\n let dateMeta = getDateMeta(cell.date, props.todayRange, props.nowDate, dateProfile)\n\n let classNames = ['fc-timeline-slot', 'fc-timeline-slot-label'].concat(\n cell.rowUnit === 'time' // TODO: so slot classnames for week/month/bigger. see note above about rowUnit\n ? getSlotClassNames(dateMeta, context.theme)\n : getDayClassNames(dateMeta, context.theme),\n )\n\n if (cell.isWeekStart) {\n classNames.push('fc-timeline-slot-em')\n }\n\n let hookProps = this.refineHookProps({\n level: props.rowLevel,\n dateMarker: cell.date,\n text: cell.text,\n dateEnv: context.dateEnv,\n viewApi: context.viewApi,\n })\n\n let customClassNames = this.normalizeClassNames(options.slotLabelClassNames, hookProps)\n\n return (\n <MountHook hookProps={hookProps} didMount={options.slotLabelDidMount} willUnmount={options.slotLabelWillUnmount}>\n {(rootElRef) => (\n <th\n ref={rootElRef}\n className={classNames.concat(customClassNames).join(' ')}\n data-date={dateEnv.formatIso(cell.date, { omitTime: !tDateProfile.isTimeScale, omitTimeZoneOffset: true })}\n colSpan={cell.colspan}\n >\n <div className=\"fc-timeline-slot-frame\" style={{ height: props.rowInnerHeight }}>\n <TimelineHeaderThInner\n hookProps={hookProps}\n isSticky={props.isSticky}\n navLinkAttrs={this.buildCellNavLinkAttrs(context, cell.date, cell.rowUnit)}\n />\n </div>\n </th>\n )}\n </MountHook>\n )\n }\n}\n\nfunction buildCellNavLinkAttrs(context: ViewContext, cellDate: DateMarker, rowUnit: string): object {\n return (rowUnit && rowUnit !== 'time')\n ? buildNavLinkAttrs(context, cellDate, rowUnit)\n : {}\n}\n","import { createElement, BaseComponent, Fragment, DateRange, DateMarker, DateProfile } from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineHeaderTh } from './TimelineHeaderTh'\n\nexport interface TimelineHeaderRowsProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n rowInnerHeights?: number[]\n}\n\nexport class TimelineHeaderRows extends BaseComponent<TimelineHeaderRowsProps> {\n render() {\n let { dateProfile, tDateProfile, rowInnerHeights, todayRange, nowDate } = this.props\n let { cellRows } = tDateProfile\n\n return (\n <Fragment>\n {cellRows.map((rowCells, rowLevel) => {\n let isLast = rowLevel === cellRows.length - 1\n let isChrono = tDateProfile.isTimeScale && isLast // the final row, with times?\n let classNames = [\n 'fc-timeline-header-row',\n isChrono ? 'fc-timeline-header-row-chrono' : '',\n ]\n\n return ( // eslint-disable-next-line react/no-array-index-key\n <tr key={rowLevel} className={classNames.join(' ')}>\n {rowCells.map((cell) => (\n <TimelineHeaderTh\n key={cell.date.toISOString()}\n cell={cell}\n rowLevel={rowLevel}\n dateProfile={dateProfile}\n tDateProfile={tDateProfile}\n todayRange={todayRange}\n nowDate={nowDate}\n rowInnerHeight={rowInnerHeights && rowInnerHeights[rowLevel]}\n isSticky={!isLast}\n />\n ))}\n </tr>\n )\n })}\n </Fragment>\n )\n }\n}\n","import {\n PositionCache, findDirectChildren,\n isInt, DateProfile,\n DateMarker, DateEnv, Duration, startOfDay, rangeContainsMarker, CssDimValue, DateRange, SegSpan,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport class TimelineCoords { // TODO: rename to \"slat\" coords?\n outerCoordCache: PositionCache\n innerCoordCache: PositionCache\n\n constructor(\n public slatRootEl: HTMLElement, // okay to expose?\n slatEls: HTMLElement[],\n public dateProfile: DateProfile,\n private tDateProfile: TimelineDateProfile,\n private dateEnv: DateEnv,\n public isRtl: boolean,\n ) {\n this.outerCoordCache = new PositionCache(\n slatRootEl,\n slatEls,\n true, // isHorizontal\n false, // isVertical\n )\n\n // for the inner divs within the slats\n // used for event rendering and scrollTime, to disregard slat border\n this.innerCoordCache = new PositionCache(\n slatRootEl,\n findDirectChildren(slatEls, 'div'),\n true, // isHorizontal\n false, // isVertical\n )\n }\n\n isDateInRange(date: DateMarker) {\n return rangeContainsMarker(this.dateProfile.currentRange, date)\n }\n\n // results range from negative width of area to 0\n dateToCoord(date: DateMarker): number {\n let { tDateProfile } = this\n let snapCoverage = this.computeDateSnapCoverage(date)\n let slotCoverage = snapCoverage / tDateProfile.snapsPerSlot\n let slotIndex = Math.floor(slotCoverage)\n slotIndex = Math.min(slotIndex, tDateProfile.slotCnt - 1)\n let partial = slotCoverage - slotIndex\n let { innerCoordCache, outerCoordCache } = this\n\n if (this.isRtl) {\n return outerCoordCache.originClientRect.width - (\n outerCoordCache.rights[slotIndex] -\n (innerCoordCache.getWidth(slotIndex) * partial)\n )\n }\n\n return (\n outerCoordCache.lefts[slotIndex] +\n (innerCoordCache.getWidth(slotIndex) * partial)\n )\n }\n\n rangeToCoords(range: DateRange): SegSpan {\n return {\n start: this.dateToCoord(range.start),\n end: this.dateToCoord(range.end),\n }\n }\n\n durationToCoord(duration: Duration): number {\n let { dateProfile, tDateProfile, dateEnv, isRtl } = this\n let coord = 0\n\n if (dateProfile) {\n let date = dateEnv.add(dateProfile.activeRange.start, duration)\n\n if (!tDateProfile.isTimeScale) {\n date = startOfDay(date)\n }\n\n coord = this.dateToCoord(date)\n\n // hack to overcome the left borders of non-first slat\n if (!isRtl && coord) {\n coord += 1\n }\n }\n\n return coord\n }\n\n coordFromLeft(coord: number) {\n if (this.isRtl) {\n return this.outerCoordCache.originClientRect.width - coord\n }\n return coord\n }\n\n // returned value is between 0 and the number of snaps\n computeDateSnapCoverage(date: DateMarker): number {\n return computeDateSnapCoverage(date, this.tDateProfile, this.dateEnv)\n }\n}\n\n// returned value is between 0 and the number of snaps\nexport function computeDateSnapCoverage(date: DateMarker, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): number {\n let snapDiff = dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n date,\n tDateProfile.snapDuration,\n )\n\n if (snapDiff < 0) {\n return 0\n }\n\n if (snapDiff >= tDateProfile.snapDiffToIndex.length) {\n return tDateProfile.snapCnt\n }\n\n let snapDiffInt = Math.floor(snapDiff)\n let snapCoverage = tDateProfile.snapDiffToIndex[snapDiffInt]\n\n if (isInt(snapCoverage)) { // not an in-between value\n snapCoverage += snapDiff - snapDiffInt // add the remainder\n } else {\n // a fractional value, meaning the date is not visible\n // always round up in this case. works for start AND end dates in a range.\n snapCoverage = Math.ceil(snapCoverage)\n }\n\n return snapCoverage\n}\n\nexport function coordToCss(\n hcoord: number | null,\n isRtl: boolean,\n): { left: CssDimValue, right: CssDimValue } {\n if (hcoord === null) {\n return { left: '', right: '' }\n }\n if (isRtl) {\n return { right: hcoord, left: '' }\n }\n return { left: hcoord, right: '' }\n}\n\nexport function coordsToCss(\n hcoords: SegSpan | null,\n isRtl: boolean,\n): { left: CssDimValue, right: CssDimValue } {\n if (!hcoords) {\n return { left: '', right: '' }\n }\n if (isRtl) {\n return { right: hcoords.start, left: -hcoords.end }\n }\n return { left: hcoords.start, right: -hcoords.end }\n}\n","import {\n createElement, BaseComponent, CssDimValue, VNode, DateMarker, NowTimer,\n greatestDurationDenominator, DateRange, NowIndicatorRoot, createRef,\n findElements, RefObject, DateProfile,\n} from '@fullcalendar/common'\nimport { TimelineHeaderRows } from './TimelineHeaderRows'\nimport { coordToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelineHeaderProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n clientWidth: number | null\n clientHeight: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n slatCoords: TimelineCoords\n rowInnerHeights?: number[]\n onMaxCushionWidth?: (number) => void\n}\n\nexport class TimelineHeader extends BaseComponent<TimelineHeaderProps> {\n rootElRef: RefObject<HTMLDivElement> = createRef<HTMLDivElement>()\n\n render() {\n let { props, context } = this\n\n // TODO: very repetitive\n // TODO: make part of tDateProfile?\n let timerUnit = greatestDurationDenominator(props.tDateProfile.slotDuration).unit\n\n // WORKAROUND: make ignore slatCoords when out of sync with dateProfile\n let slatCoords = props.slatCoords && props.slatCoords.dateProfile === props.dateProfile ? props.slatCoords : null\n\n return (\n <NowTimer unit={timerUnit}>\n {(nowDate: DateMarker, todayRange: DateRange) => (\n <div className=\"fc-timeline-header\" ref={this.rootElRef}>\n <table\n aria-hidden\n className=\"fc-scrollgrid-sync-table\"\n style={{ minWidth: props.tableMinWidth, width: props.clientWidth }}\n >\n {props.tableColGroupNode}\n <tbody>\n <TimelineHeaderRows\n dateProfile={props.dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n rowInnerHeights={props.rowInnerHeights}\n />\n </tbody>\n </table>\n {context.options.nowIndicator && (\n // need to have a container regardless of whether the current view has a visible now indicator\n // because apparently removal of the element resets the scroll for some reasons (issue #5351).\n // this issue doesn't happen for the timeline body however (\n <div className=\"fc-timeline-now-indicator-container\">\n {(slatCoords && slatCoords.isDateInRange(nowDate)) && (\n <NowIndicatorRoot isAxis date={nowDate}>\n {(rootElRef, classNames, innerElRef, innerContent) => (\n <div\n ref={rootElRef}\n className={['fc-timeline-now-indicator-arrow'].concat(classNames).join(' ')}\n style={coordToCss(slatCoords.dateToCoord(nowDate), context.isRtl)}\n >\n {innerContent}\n </div>\n )}\n </NowIndicatorRoot>\n )}\n </div>\n )}\n </div>\n )}\n </NowTimer>\n )\n }\n\n componentDidMount() {\n this.updateSize()\n }\n\n componentDidUpdate() {\n this.updateSize()\n }\n\n updateSize() {\n if (this.props.onMaxCushionWidth) {\n this.props.onMaxCushionWidth(this.computeMaxCushionWidth())\n }\n }\n\n computeMaxCushionWidth() { // TODO: called way too often\n return Math.max(\n ...findElements(this.rootElRef.current, '.fc-timeline-header-row:last-child .fc-timeline-slot-cushion').map(\n (el) => el.getBoundingClientRect().width,\n ),\n )\n }\n}\n","import {\n createElement, isInt, BaseComponent, DateMarker, Ref, DateRange, getDateMeta, getSlotClassNames,\n RenderHook, getDayClassNames, SlotLaneContentArg, DateProfile,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelineSlatCellProps {\n date: DateMarker\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n isDay: boolean\n isEm: boolean\n elRef?: Ref<HTMLTableCellElement>\n}\n\nexport class TimelineSlatCell extends BaseComponent<TimelineSlatCellProps> {\n render() {\n let { props, context } = this\n let { dateEnv, options, theme } = context\n let { date, tDateProfile, isEm } = props\n let dateMeta = getDateMeta(props.date, props.todayRange, props.nowDate, props.dateProfile)\n let classNames = ['fc-timeline-slot', 'fc-timeline-slot-lane']\n let dataAttrs = { 'data-date': dateEnv.formatIso(date, { omitTimeZoneOffset: true, omitTime: !tDateProfile.isTimeScale }) }\n let hookProps: SlotLaneContentArg = {\n date: dateEnv.toDate(props.date),\n ...dateMeta,\n view: context.viewApi,\n }\n\n if (isEm) {\n classNames.push('fc-timeline-slot-em')\n }\n\n if (tDateProfile.isTimeScale) {\n classNames.push(\n isInt(dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n props.date,\n tDateProfile.labelInterval,\n )) ?\n 'fc-timeline-slot-major' :\n 'fc-timeline-slot-minor',\n )\n }\n\n classNames.push(...(\n props.isDay\n ? getDayClassNames(dateMeta, theme)\n : getSlotClassNames(dateMeta, theme)\n ))\n\n return (\n <RenderHook\n hookProps={hookProps}\n classNames={options.slotLaneClassNames}\n content={options.slotLaneContent}\n didMount={options.slotLaneDidMount}\n willUnmount={options.slotLaneWillUnmount}\n elRef={props.elRef}\n >\n {(rootElRef, customClassNames, innerElRef, innerContent) => (\n <td\n ref={rootElRef}\n className={classNames.concat(customClassNames).join(' ')}\n {...dataAttrs}\n >\n <div ref={innerElRef}>{innerContent}</div>\n </td>\n )}\n </RenderHook>\n )\n }\n}\n","import { createElement, BaseComponent, RefMap, DateMarker, DateRange, DateProfile } from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineSlatCell } from './TimelineSlatCell'\n\nexport interface TimelineSlatsContentProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n}\n\nexport interface TimelineSlatsBodyProps extends TimelineSlatsContentProps {\n cellElRefs: RefMap<HTMLTableCellElement>\n}\n\nexport class TimelineSlatsBody extends BaseComponent<TimelineSlatsBodyProps> {\n render() {\n let { props } = this\n let { tDateProfile, cellElRefs } = props\n let { slotDates, isWeekStarts } = tDateProfile\n let isDay = !tDateProfile.isTimeScale && !tDateProfile.largeUnit\n\n return (\n <tbody>\n <tr>\n {slotDates.map((slotDate, i) => {\n let key = slotDate.toISOString()\n\n return (\n <TimelineSlatCell\n key={key}\n elRef={cellElRefs.createRef(key)}\n date={slotDate}\n dateProfile={props.dateProfile}\n tDateProfile={tDateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n isEm={isWeekStarts[i]}\n isDay={isDay}\n />\n )\n })}\n </tr>\n </tbody>\n )\n }\n}\n","import {\n createElement, BaseComponent, multiplyDuration, RefMap, CssDimValue, VNode,\n createRef, ScrollResponder, ScrollRequest, DateMarker,\n} from '@fullcalendar/common'\nimport { TimelineCoords } from './TimelineCoords'\nimport { TimelineSlatsBody, TimelineSlatsContentProps } from './TimelineSlatsBody'\n\nexport interface TimelineSlatsProps extends TimelineSlatsContentProps {\n clientWidth: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n onCoords?: (coord: TimelineCoords | null) => void\n onScrollLeftRequest?: (scrollLeft: number) => void\n}\n\nexport class TimelineSlats extends BaseComponent<TimelineSlatsProps> {\n private rootElRef = createRef<HTMLDivElement>()\n private cellElRefs = new RefMap<HTMLTableCellElement>()\n private coords: TimelineCoords // for positionToHit\n private scrollResponder: ScrollResponder\n\n render() {\n let { props, context } = this\n\n return (\n <div className=\"fc-timeline-slots\" ref={this.rootElRef}>\n <table\n aria-hidden\n className={context.theme.getClass('table')}\n style={{\n minWidth: props.tableMinWidth,\n width: props.clientWidth,\n }}\n >\n {props.tableColGroupNode}\n <TimelineSlatsBody\n cellElRefs={this.cellElRefs}\n dateProfile={props.dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n />\n </table>\n </div>\n )\n }\n\n componentDidMount() {\n this.updateSizing()\n this.scrollResponder = this.context.createScrollResponder(this.handleScrollRequest)\n }\n\n componentDidUpdate(prevProps: TimelineSlatsProps) {\n this.updateSizing()\n\n this.scrollResponder.update(prevProps.dateProfile !== this.props.dateProfile)\n }\n\n componentWillUnmount() {\n this.scrollResponder.detach()\n\n if (this.props.onCoords) {\n this.props.onCoords(null)\n }\n }\n\n updateSizing() {\n let { props, context } = this\n\n if (\n props.clientWidth !== null && // is sizing stable?\n this.scrollResponder\n // ^it's possible to have clientWidth immediately after mount (when returning from print view), but w/o scrollResponder\n ) {\n let rootEl = this.rootElRef.current\n\n if (rootEl.offsetWidth) { // not hidden by css\n this.coords = new TimelineCoords(\n this.rootElRef.current,\n collectCellEls(this.cellElRefs.currentMap, props.tDateProfile.slotDates),\n props.dateProfile,\n props.tDateProfile,\n context.dateEnv,\n context.isRtl,\n )\n\n if (props.onCoords) {\n props.onCoords(this.coords)\n }\n\n this.scrollResponder.update(false) // TODO: wouldn't have to do this if coords were in state\n }\n }\n }\n\n handleScrollRequest = (request: ScrollRequest) => {\n let { onScrollLeftRequest } = this.props\n let { coords } = this\n\n if (onScrollLeftRequest && coords) {\n if (request.time) {\n let scrollLeft = coords.coordFromLeft(coords.durationToCoord(request.time))\n onScrollLeftRequest(scrollLeft)\n }\n return true\n }\n\n return null // best?\n }\n\n positionToHit(leftPosition) { // TODO: kill somehow\n let { outerCoordCache } = this.coords\n let { dateEnv, isRtl } = this.context\n let { tDateProfile } = this.props\n let slatIndex = outerCoordCache.leftToIndex(leftPosition)\n\n if (slatIndex != null) {\n // somewhat similar to what TimeGrid does. consolidate?\n let slatWidth = outerCoordCache.getWidth(slatIndex)\n let partial = isRtl ?\n (outerCoordCache.rights[slatIndex] - leftPosition) / slatWidth :\n (leftPosition - outerCoordCache.lefts[slatIndex]) / slatWidth\n let localSnapIndex = Math.floor(partial * tDateProfile.snapsPerSlot)\n let start = dateEnv.add(\n tDateProfile.slotDates[slatIndex],\n multiplyDuration(tDateProfile.snapDuration, localSnapIndex),\n )\n let end = dateEnv.add(start, tDateProfile.snapDuration)\n\n return {\n dateSpan: {\n range: { start, end },\n allDay: !this.props.tDateProfile.isTimeScale,\n },\n dayEl: this.cellElRefs.currentMap[slatIndex],\n left: outerCoordCache.lefts[slatIndex], // TODO: make aware of snaps?\n right: outerCoordCache.rights[slatIndex],\n }\n }\n\n return null\n }\n}\n\nfunction collectCellEls(elMap: { [key: string]: HTMLElement }, slotDates: DateMarker[]) {\n return slotDates.map((slotDate) => {\n let key = slotDate.toISOString()\n return elMap[key]\n })\n}\n","import {\n SegSpan, SegHierarchy, groupIntersectingEntries, SegEntry, buildIsoString,\n computeEarliestSegStart,\n} from '@fullcalendar/common'\nimport { TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineSegPlacement {\n seg: TimelineLaneSeg | TimelineLaneSeg[] // HACK: if array, then it's a more-link group\n hcoords: SegSpan | null\n top: number | null\n}\n\nexport function computeSegHCoords(\n segs: TimelineLaneSeg[],\n minWidth: number,\n timelineCoords: TimelineCoords | null,\n): SegSpan[] {\n let hcoords: SegSpan[] = []\n\n if (timelineCoords) {\n for (let seg of segs) {\n let res = timelineCoords.rangeToCoords(seg)\n let start = Math.round(res.start) // for barely-overlapping collisions\n let end = Math.round(res.end) //\n\n if (end - start < minWidth) {\n end = start + minWidth\n }\n\n hcoords.push({ start, end })\n }\n }\n\n return hcoords\n}\n\nexport function computeFgSegPlacements(\n segs: TimelineLaneSeg[],\n segHCoords: SegSpan[], // might not have for every seg\n eventInstanceHeights: { [instanceId: string]: number }, // might not have for every seg\n moreLinkHeights: { [isoStr: string]: number }, // might not have for every more-link\n strictOrder?: boolean,\n maxStackCnt?: number,\n): [TimelineSegPlacement[], number] { // [placements, totalHeight]\n let segInputs: SegEntry[] = []\n let crudePlacements: TimelineSegPlacement[] = [] // when we don't know dims\n\n for (let i = 0; i < segs.length; i += 1) {\n let seg = segs[i]\n let instanceId = seg.eventRange.instance.instanceId\n let height = eventInstanceHeights[instanceId]\n let hcoords = segHCoords[i]\n\n if (height && hcoords) {\n segInputs.push({\n index: i,\n span: hcoords,\n thickness: height,\n })\n } else {\n crudePlacements.push({\n seg,\n hcoords, // might as well set hcoords if we have them. might be null\n top: null,\n })\n }\n }\n\n let hierarchy = new SegHierarchy()\n if (strictOrder != null) {\n hierarchy.strictOrder = strictOrder\n }\n if (maxStackCnt != null) {\n hierarchy.maxStackCnt = maxStackCnt\n }\n\n let hiddenEntries = hierarchy.addSegs(segInputs)\n let hiddenPlacements = hiddenEntries.map((entry) => ({\n seg: segs[entry.index],\n hcoords: entry.span,\n top: null,\n } as TimelineSegPlacement))\n\n let hiddenGroups = groupIntersectingEntries(hiddenEntries)\n let moreLinkInputs: SegEntry[] = []\n let moreLinkCrudePlacements: TimelineSegPlacement[] = []\n const extractSeg = (entry: SegEntry) => segs[entry.index]\n\n for (let i = 0; i < hiddenGroups.length; i += 1) {\n let hiddenGroup = hiddenGroups[i]\n let sortedSegs = hiddenGroup.entries.map(extractSeg)\n let height = moreLinkHeights[buildIsoString(computeEarliestSegStart(sortedSegs))] // not optimal :(\n\n if (height != null) {\n // NOTE: the hiddenGroup's spanStart/spanEnd are already computed by rangeToCoords. computed during input.\n moreLinkInputs.push({\n index: segs.length + i, // out-of-bounds indexes map to hiddenGroups\n thickness: height,\n span: hiddenGroup.span,\n })\n } else {\n moreLinkCrudePlacements.push({\n seg: sortedSegs, // a Seg array signals a more-link\n hcoords: hiddenGroup.span,\n top: null,\n })\n }\n }\n\n // add more-links into the hierarchy, but don't limit\n hierarchy.maxStackCnt = -1\n hierarchy.addSegs(moreLinkInputs)\n\n let visibleRects = hierarchy.toRects()\n let visiblePlacements: TimelineSegPlacement[] = []\n let maxHeight = 0\n\n for (let rect of visibleRects) {\n let segIndex = rect.index\n visiblePlacements.push({\n seg: segIndex < segs.length\n ? segs[segIndex] // a real seg\n : hiddenGroups[segIndex - segs.length].entries.map(extractSeg), // signals a more-link\n hcoords: rect.span,\n top: rect.levelCoord,\n })\n maxHeight = Math.max(maxHeight, rect.levelCoord + rect.thickness)\n }\n\n return [\n visiblePlacements.concat(crudePlacements, hiddenPlacements, moreLinkCrudePlacements),\n maxHeight,\n ]\n}\n","import {\n BaseComponent, createElement, Fragment, BgEvent, renderFill,\n getSegMeta, DateRange, DateMarker, buildEventRangeKey,\n} from '@fullcalendar/common'\nimport { computeSegHCoords } from './event-placement'\nimport { coordsToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineLaneBgProps {\n businessHourSegs: TimelineLaneSeg[] | null // can be null :(\n bgEventSegs: TimelineLaneSeg[] | null // can be null :(\n dateSelectionSegs: TimelineLaneSeg[]\n eventResizeSegs: TimelineLaneSeg[]\n timelineCoords: TimelineCoords | null\n todayRange: DateRange\n nowDate: DateMarker\n}\n\nexport class TimelineLaneBg extends BaseComponent<TimelineLaneBgProps> {\n render() {\n let { props } = this\n let highlightSeg = [].concat(props.eventResizeSegs, props.dateSelectionSegs)\n\n return props.timelineCoords && (\n <div className=\"fc-timeline-bg\">\n {/* Fragments contain the keys */}\n {this.renderSegs(props.businessHourSegs || [], props.timelineCoords, 'non-business')}\n {this.renderSegs(props.bgEventSegs || [], props.timelineCoords, 'bg-event')}\n {this.renderSegs(highlightSeg, props.timelineCoords, 'highlight')}\n </div>\n )\n }\n\n renderSegs(segs: TimelineLaneSeg[], timelineCoords: TimelineCoords | null, fillType: string) {\n let { todayRange, nowDate } = this.props\n let { isRtl } = this.context\n let segHCoords = computeSegHCoords(segs, 0, timelineCoords)\n\n let children = segs.map((seg, i) => {\n let hcoords = segHCoords[i]\n let hStyle = coordsToCss(hcoords, isRtl)\n\n return (\n <div\n key={buildEventRangeKey(seg.eventRange)}\n className=\"fc-timeline-bg-harness\"\n style={hStyle}\n >\n {fillType === 'bg-event' ?\n <BgEvent seg={seg} {...getSegMeta(seg, todayRange, nowDate)} /> :\n renderFill(fillType)}\n </div>\n )\n })\n\n return <Fragment>{children}</Fragment>\n }\n}\n","import {\n DateRange, intersectRanges, addMs, DateProfile, Slicer,\n DateProfileGenerator, DateEnv, DateMarker, Seg,\n} from '@fullcalendar/common'\nimport { normalizeRange, isValidDate, TimelineDateProfile } from './timeline-date-profile'\nimport { computeDateSnapCoverage } from './TimelineCoords'\n\nexport interface TimelineLaneSeg extends Seg {\n // the point of this range is because it might be different than seg.eventRange.range\n // because the date might have been rounded to the start of a week or a month\n start: DateMarker\n end: DateMarker\n}\n\nexport class TimelineLaneSlicer extends Slicer<\n TimelineLaneSeg,\n [DateProfile, DateProfileGenerator, TimelineDateProfile, DateEnv]\n> {\n sliceRange(\n origRange: DateRange,\n dateProfile: DateProfile,\n dateProfileGenerator: DateProfileGenerator,\n tDateProfile: TimelineDateProfile,\n dateEnv: DateEnv,\n ): TimelineLaneSeg[] {\n let normalRange = normalizeRange(origRange, tDateProfile, dateEnv)\n let segs: TimelineLaneSeg[] = []\n\n // protect against when the span is entirely in an invalid date region\n if (\n computeDateSnapCoverage(normalRange.start, tDateProfile, dateEnv)\n < computeDateSnapCoverage(normalRange.end, tDateProfile, dateEnv)\n ) {\n // intersect the footprint's range with the grid's range\n let slicedRange = intersectRanges(normalRange, tDateProfile.normalizedRange)\n\n if (slicedRange) {\n segs.push({\n start: slicedRange.start,\n end: slicedRange.end,\n isStart: slicedRange.start.valueOf() === normalRange.start.valueOf()\n && isValidDate(slicedRange.start, tDateProfile, dateProfile, dateProfileGenerator),\n isEnd: slicedRange.end.valueOf() === normalRange.end.valueOf()\n && isValidDate(addMs(slicedRange.end, -1), tDateProfile, dateProfile, dateProfileGenerator),\n })\n }\n }\n\n return segs\n }\n}\n","import { StandardEvent, MinimalEventProps, createElement, BaseComponent, createFormatter } from '@fullcalendar/common'\n\nexport interface TimelineEventProps extends MinimalEventProps {\n isTimeScale: boolean\n}\n\nconst DEFAULT_TIME_FORMAT = createFormatter({\n hour: 'numeric',\n minute: '2-digit',\n omitZeroMinute: true,\n meridiem: 'narrow',\n})\n\nexport class TimelineEvent extends BaseComponent<TimelineEventProps> {\n render() {\n let { props } = this\n\n return (\n <StandardEvent\n {...props}\n extraClassNames={['fc-timeline-event', 'fc-h-event']}\n defaultTimeFormat={DEFAULT_TIME_FORMAT}\n defaultDisplayEventTime={!props.isTimeScale}\n />\n )\n }\n}\n","import {\n createElement, BaseComponent, Ref, createRef, MoreLinkRoot,\n setRef, DateProfile, DateRange, DateMarker, Fragment, getSegMeta,\n} from '@fullcalendar/common'\nimport { TimelineSegPlacement } from './event-placement'\nimport { coordsToCss } from './TimelineCoords'\nimport { TimelineEvent } from './TimelineEvent'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineLaneMoreLinkProps {\n elRef: Ref<HTMLElement>\n hiddenSegs: TimelineLaneSeg[]\n placement: TimelineSegPlacement\n dateProfile: DateProfile\n nowDate: DateMarker\n todayRange: DateRange\n isTimeScale: boolean\n eventSelection: string\n resourceId?: string\n isForcedInvisible: { [instanceId: string]: any }\n}\n\nexport class TimelineLaneMoreLink extends BaseComponent<TimelineLaneMoreLinkProps> {\n rootElRef = createRef<HTMLElement>()\n\n render() {\n let { props, context } = this\n let { hiddenSegs, elRef, placement, resourceId } = props\n let { top, hcoords } = placement\n let isVisible = hcoords && top !== null\n let hStyle = coordsToCss(hcoords, context.isRtl)\n let extraDateSpan = resourceId ? { resourceId } : {}\n\n return (\n <MoreLinkRoot\n allDayDate={null}\n moreCnt={hiddenSegs.length}\n allSegs={hiddenSegs}\n hiddenSegs={hiddenSegs}\n alignmentElRef={this.rootElRef}\n dateProfile={props.dateProfile}\n todayRange={props.todayRange}\n extraDateSpan={extraDateSpan}\n popoverContent={() => (\n <Fragment>\n {hiddenSegs.map((seg) => {\n let instanceId = seg.eventRange.instance.instanceId\n return (\n <div\n key={instanceId}\n style={{ visibility: props.isForcedInvisible[instanceId] ? 'hidden' : ('' as any) }}\n >\n <TimelineEvent\n isTimeScale={props.isTimeScale}\n seg={seg}\n isDragging={false}\n isResizing={false}\n isDateSelecting={false}\n isSelected={instanceId === props.eventSelection}\n {...getSegMeta(seg, props.todayRange, props.nowDate)}\n />\n </div>\n )\n })}\n </Fragment>\n )}\n >\n {(rootElRef, classNames, innerElRef, innerContent, handleClick, title, isExpanded, popoverId) => (\n <a\n ref={(el: HTMLElement | null) => {\n setRef(rootElRef, el) // for MoreLinkRoot\n setRef(elRef, el) // for props props\n setRef(this.rootElRef, el) // for this component\n }}\n className={['fc-timeline-more-link'].concat(classNames).join(' ')}\n style={{\n visibility: isVisible ? ('' as any) : 'hidden',\n top: top || 0,\n ...hStyle,\n }}\n onClick={handleClick}\n title={title}\n aria-expanded={isExpanded}\n aria-controls={popoverId}\n >\n <div ref={innerElRef} className=\"fc-timeline-more-link-inner fc-sticky\">\n {innerContent}\n </div>\n </a>\n )}\n </MoreLinkRoot>\n )\n }\n}\n","import {\n Duration, EventStore, EventUiHash, DateSpan, EventInteractionState,\n BaseComponent, createElement, memoize, Fragment, RefMap, mapHash, createRef,\n getSegMeta, DateMarker, DateRange, DateProfile, sortEventSegs, isPropsEqual, buildIsoString,\n computeEarliestSegStart,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { coordsToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneBg } from './TimelineLaneBg'\nimport { TimelineLaneSlicer, TimelineLaneSeg } from './TimelineLaneSlicer'\nimport { TimelineEvent } from './TimelineEvent'\nimport { TimelineLaneMoreLink } from './TimelineLaneMoreLink'\nimport { computeFgSegPlacements, computeSegHCoords, TimelineSegPlacement } from './event-placement'\n\nexport interface TimelineLaneProps extends TimelineLaneCoreProps {\n onHeightChange?: (innerEl: HTMLElement, isStable: boolean) => void\n}\n\nexport interface TimelineLaneCoreProps {\n nowDate: DateMarker\n todayRange: DateRange\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nextDayThreshold: Duration\n businessHours: EventStore | null\n eventStore: EventStore | null\n eventUiBases: EventUiHash\n dateSelection: DateSpan | null\n eventSelection: string\n eventDrag: EventInteractionState | null\n eventResize: EventInteractionState | null\n timelineCoords: TimelineCoords | null // TODO: renamt to SLAT coords?\n resourceId?: string // hack\n}\n\ninterface TimelineLaneState {\n eventInstanceHeights: { [instanceId: string]: number } // integers\n moreLinkHeights: { [isoStr: string]: number } // integers\n}\n\nexport class TimelineLane extends BaseComponent<TimelineLaneProps, TimelineLaneState> {\n private slicer = new TimelineLaneSlicer()\n private sortEventSegs = memoize(sortEventSegs)\n private harnessElRefs = new RefMap<HTMLDivElement>()\n private moreElRefs = new RefMap<HTMLDivElement>()\n private innerElRef = createRef<HTMLDivElement>()\n // TODO: memoize event positioning\n\n state: TimelineLaneState = {\n eventInstanceHeights: {},\n moreLinkHeights: {},\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let { dateProfile, tDateProfile } = props\n\n let slicedProps = this.slicer.sliceProps(\n props,\n dateProfile,\n tDateProfile.isTimeScale ? null : props.nextDayThreshold,\n context, // wish we didn't have to pass in the rest of the args...\n dateProfile,\n context.dateProfileGenerator,\n tDateProfile,\n context.dateEnv,\n )\n\n let mirrorSegs =\n (slicedProps.eventDrag ? slicedProps.eventDrag.segs as TimelineLaneSeg[] : null) ||\n (slicedProps.eventResize ? slicedProps.eventResize.segs as TimelineLaneSeg[] : null) ||\n []\n\n let fgSegs = this.sortEventSegs(slicedProps.fgEventSegs, options.eventOrder) as TimelineLaneSeg[]\n let fgSegHCoords = computeSegHCoords(fgSegs, options.eventMinWidth, props.timelineCoords)\n let [fgPlacements, fgHeight] = computeFgSegPlacements(\n fgSegs,\n fgSegHCoords,\n state.eventInstanceHeights,\n state.moreLinkHeights,\n options.eventOrderStrict,\n options.eventMaxStack,\n )\n\n let isForcedInvisible = // TODO: more convenient\n (slicedProps.eventDrag ? slicedProps.eventDrag.affectedInstances : null) ||\n (slicedProps.eventResize ? slicedProps.eventResize.affectedInstances : null) ||\n {}\n\n return (\n <Fragment>\n <TimelineLaneBg\n businessHourSegs={slicedProps.businessHourSegs}\n bgEventSegs={slicedProps.bgEventSegs}\n timelineCoords={props.timelineCoords}\n eventResizeSegs={slicedProps.eventResize ? slicedProps.eventResize.segs as TimelineLaneSeg[] : [] /* bad new empty array? */}\n dateSelectionSegs={slicedProps.dateSelectionSegs}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n />\n <div\n className=\"fc-timeline-events fc-scrollgrid-sync-inner\"\n ref={this.innerElRef}\n style={{ height: fgHeight }}\n >\n {this.renderFgSegs(\n fgPlacements,\n isForcedInvisible,\n false,\n false,\n false,\n )}\n {this.renderFgSegs(\n buildMirrorPlacements(mirrorSegs, props.timelineCoords, fgPlacements),\n {},\n Boolean(slicedProps.eventDrag),\n Boolean(slicedProps.eventResize),\n false, // because mirror is never drawn for date selection\n )}\n </div>\n </Fragment>\n )\n }\n\n componentDidMount() {\n this.updateSize()\n }\n\n componentDidUpdate(prevProps: TimelineLaneProps, prevState: TimelineLaneState) {\n if (\n prevProps.eventStore !== this.props.eventStore || // external thing changed?\n prevProps.timelineCoords !== this.props.timelineCoords || // external thing changed?\n prevState.moreLinkHeights !== this.state.moreLinkHeights // HACK. see addStateEquality\n ) {\n this.updateSize()\n }\n }\n\n updateSize() {\n let { props } = this\n let { timelineCoords } = props\n\n if (props.onHeightChange) {\n props.onHeightChange(this.innerElRef.current, false)\n }\n\n if (timelineCoords) {\n this.setState({\n eventInstanceHeights: mapHash(this.harnessElRefs.currentMap, (harnessEl) => (\n Math.round(harnessEl.getBoundingClientRect().height)\n )),\n moreLinkHeights: mapHash(this.moreElRefs.currentMap, (moreEl) => (\n Math.round(moreEl.getBoundingClientRect().height)\n )),\n }, () => {\n if (props.onHeightChange) {\n props.onHeightChange(this.innerElRef.current, true)\n }\n })\n }\n }\n\n renderFgSegs(\n segPlacements: TimelineSegPlacement[],\n isForcedInvisible: { [instanceId: string]: any },\n isDragging: boolean,\n isResizing: boolean,\n isDateSelecting: boolean,\n ) {\n let { harnessElRefs, moreElRefs, props, context } = this\n let isMirror = isDragging || isResizing || isDateSelecting\n\n return (\n <Fragment>\n {segPlacements.map((segPlacement) => {\n let { seg, hcoords, top } = segPlacement\n\n if (Array.isArray(seg)) { // a more-link\n let isoStr = buildIsoString(computeEarliestSegStart(seg))\n return (\n <TimelineLaneMoreLink\n key={'m:' + isoStr /* \"m\" for \"more\" */}\n elRef={moreElRefs.createRef(isoStr)}\n hiddenSegs={seg}\n placement={segPlacement}\n dateProfile={props.dateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n isTimeScale={props.tDateProfile.isTimeScale}\n eventSelection={props.eventSelection}\n resourceId={props.resourceId}\n isForcedInvisible={isForcedInvisible}\n />\n )\n }\n\n let instanceId = seg.eventRange.instance.instanceId\n let isVisible = isMirror || Boolean(!isForcedInvisible[instanceId] && hcoords && top !== null)\n let hStyle = coordsToCss(hcoords, context.isRtl)\n\n return (\n <div\n key={'e:' + instanceId /* \"e\" for \"event\" */}\n ref={isMirror ? null : harnessElRefs.createRef(instanceId)}\n className=\"fc-timeline-event-harness\"\n style={{\n visibility: isVisible ? ('' as any) : 'hidden',\n top: top || 0,\n ...hStyle,\n }}\n >\n <TimelineEvent\n isTimeScale={props.tDateProfile.isTimeScale}\n seg={seg}\n isDragging={isDragging}\n isResizing={isResizing}\n isDateSelecting={isDateSelecting}\n isSelected={instanceId === props.eventSelection /* TODO: bad for mirror? */}\n {...getSegMeta(seg, props.todayRange, props.nowDate)}\n />\n </div>\n )\n })}\n </Fragment>\n )\n }\n}\n\nTimelineLane.addStateEquality({\n eventInstanceHeights: isPropsEqual,\n moreLinkHeights: isPropsEqual,\n})\n\nfunction buildMirrorPlacements(\n mirrorSegs: TimelineLaneSeg[],\n timelineCoords: TimelineCoords | null,\n fgPlacements: TimelineSegPlacement[],\n): TimelineSegPlacement[] {\n if (!mirrorSegs.length || !timelineCoords) {\n return []\n }\n let topsByInstanceId = buildAbsoluteTopHash(fgPlacements) // TODO: cache this at first render?\n return mirrorSegs.map((seg) => ({\n seg,\n hcoords: timelineCoords.rangeToCoords(seg),\n top: topsByInstanceId[seg.eventRange.instance.instanceId],\n }))\n}\n\nfunction buildAbsoluteTopHash(placements: TimelineSegPlacement[]) {\n let topsByInstanceId: { [instanceId: string]: number } = {}\n\n for (let placement of placements) {\n let { seg } = placement\n if (!Array.isArray(seg)) { // doesn't represent a more-link\n topsByInstanceId[seg.eventRange.instance.instanceId] = placement.top\n }\n }\n\n return topsByInstanceId\n}\n","import {\n createElement, createRef, ViewProps, Hit, DateComponent, CssDimValue, VNode, DateMarker, NowTimer,\n greatestDurationDenominator, DateRange, NowIndicatorRoot, Fragment,\n} from '@fullcalendar/common'\nimport { coordToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineSlats } from './TimelineSlats'\nimport { TimelineLane } from './TimelineLane'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelinGridProps extends ViewProps {\n tDateProfile: TimelineDateProfile\n clientWidth: number | null\n clientHeight: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n onSlatCoords?: (coords: TimelineCoords) => void\n onScrollLeftRequest?: (scrollLeft: number) => void\n}\n\ninterface TimelineGridState {\n coords: TimelineCoords | null\n}\n\nexport class TimelineGrid extends DateComponent<TimelinGridProps, TimelineGridState> {\n private slatsRef = createRef<TimelineSlats>()\n\n state: TimelineGridState = {\n coords: null,\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let { dateProfile, tDateProfile } = props\n let timerUnit = greatestDurationDenominator(tDateProfile.slotDuration).unit\n\n return (\n <div\n className=\"fc-timeline-body\"\n ref={this.handeEl}\n style={{\n minWidth: props.tableMinWidth,\n height: props.clientHeight,\n width: props.clientWidth,\n }}\n >\n <NowTimer unit={timerUnit}>\n {(nowDate: DateMarker, todayRange: DateRange) => (\n <Fragment>\n <TimelineSlats\n ref={this.slatsRef}\n dateProfile={dateProfile}\n tDateProfile={tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n clientWidth={props.clientWidth}\n tableColGroupNode={props.tableColGroupNode}\n tableMinWidth={props.tableMinWidth}\n onCoords={this.handleCoords}\n onScrollLeftRequest={props.onScrollLeftRequest}\n />\n <TimelineLane\n dateProfile={dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n nextDayThreshold={options.nextDayThreshold}\n businessHours={props.businessHours}\n eventStore={props.eventStore}\n eventUiBases={props.eventUiBases}\n dateSelection={props.dateSelection}\n eventSelection={props.eventSelection}\n eventDrag={props.eventDrag}\n eventResize={props.eventResize}\n timelineCoords={state.coords}\n />\n {(options.nowIndicator && state.coords && state.coords.isDateInRange(nowDate)) && (\n <div className=\"fc-timeline-now-indicator-container\">\n <NowIndicatorRoot isAxis={false} date={nowDate}>\n {(rootElRef, classNames, innerElRef, innerContent) => (\n <div\n ref={rootElRef}\n className={['fc-timeline-now-indicator-line'].concat(classNames).join(' ')}\n style={coordToCss(state.coords.dateToCoord(nowDate), context.isRtl)}\n >\n {innerContent}\n </div>\n )}\n </NowIndicatorRoot>\n </div>\n )}\n </Fragment>\n )}\n </NowTimer>\n </div>\n )\n }\n\n handeEl = (el: HTMLElement | null) => {\n if (el) {\n this.context.registerInteractiveComponent(this, { el })\n } else {\n this.context.unregisterInteractiveComponent(this)\n }\n }\n\n handleCoords = (coords: TimelineCoords) => {\n this.setState({ coords })\n\n if (this.props.onSlatCoords) {\n this.props.onSlatCoords(coords)\n }\n }\n\n // Hit System\n // ------------------------------------------------------------------------------------------\n\n queryHit(positionLeft: number, positionTop: number, elWidth: number, elHeight: number): Hit {\n let slats = this.slatsRef.current\n let slatHit = slats.positionToHit(positionLeft)\n\n if (slatHit) {\n return {\n dateProfile: this.props.dateProfile,\n dateSpan: slatHit.dateSpan,\n rect: {\n left: slatHit.left,\n right: slatHit.right,\n top: 0,\n bottom: elHeight,\n },\n dayEl: slatHit.dayEl,\n layer: 0,\n }\n }\n\n return null\n }\n}\n","import {\n createElement, ViewProps, memoize, ChunkContentCallbackArgs, createRef, ViewRoot,\n DateComponent, ScrollGridSectionConfig, renderScrollShim, getStickyHeaderDates, getStickyFooterScrollbar,\n} from '@fullcalendar/common'\nimport { ScrollGrid } from '@fullcalendar/scrollgrid'\nimport { buildTimelineDateProfile, TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineHeader } from './TimelineHeader'\nimport { TimelineGrid } from './TimelineGrid'\nimport { TimelineCoords } from './TimelineCoords'\n\ninterface TimelineViewState {\n slatCoords: TimelineCoords | null\n slotCushionMaxWidth: number | null\n}\n\nexport class TimelineView extends DateComponent<ViewProps, TimelineViewState> { // would make this abstract, but TS complains\n private buildTimelineDateProfile = memoize(buildTimelineDateProfile)\n private scrollGridRef = createRef<ScrollGrid>()\n\n state = {\n slatCoords: null,\n slotCushionMaxWidth: null,\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let stickyHeaderDates = !props.forPrint && getStickyHeaderDates(options)\n let stickyFooterScrollbar = !props.forPrint && getStickyFooterScrollbar(options)\n\n let tDateProfile = this.buildTimelineDateProfile(\n props.dateProfile,\n context.dateEnv,\n options,\n context.dateProfileGenerator,\n )\n\n let extraClassNames = [\n 'fc-timeline',\n options.eventOverlap === false ? 'fc-timeline-overlap-disabled' : '',\n ]\n\n let { slotMinWidth } = options\n let slatCols = buildSlatCols(tDateProfile, slotMinWidth || this.computeFallbackSlotMinWidth(tDateProfile))\n\n let sections: ScrollGridSectionConfig[] = [\n {\n type: 'header',\n key: 'header',\n isSticky: stickyHeaderDates,\n chunks: [{\n key: 'timeline',\n content: (contentArg: ChunkContentCallbackArgs) => (\n <TimelineHeader\n dateProfile={props.dateProfile}\n clientWidth={contentArg.clientWidth}\n clientHeight={contentArg.clientHeight}\n tableMinWidth={contentArg.tableMinWidth}\n tableColGroupNode={contentArg.tableColGroupNode}\n tDateProfile={tDateProfile}\n slatCoords={state.slatCoords}\n onMaxCushionWidth={slotMinWidth ? null : this.handleMaxCushionWidth}\n />\n ),\n }],\n },\n {\n type: 'body',\n key: 'body',\n liquid: true,\n chunks: [{\n key: 'timeline',\n content: (contentArg: ChunkContentCallbackArgs) => (\n <TimelineGrid\n {...props}\n clientWidth={contentArg.clientWidth}\n clientHeight={contentArg.clientHeight}\n tableMinWidth={contentArg.tableMinWidth}\n tableColGroupNode={contentArg.tableColGroupNode}\n tDateProfile={tDateProfile}\n onSlatCoords={this.handleSlatCoords}\n onScrollLeftRequest={this.handleScrollLeftRequest}\n />\n ),\n }],\n },\n ]\n\n if (stickyFooterScrollbar) {\n sections.push({\n type: 'footer',\n key: 'footer',\n isSticky: true,\n chunks: [{\n key: 'timeline',\n content: renderScrollShim,\n }],\n })\n }\n\n return (\n <ViewRoot viewSpec={context.viewSpec}>\n {(rootElRef, classNames) => (\n <div ref={rootElRef} className={extraClassNames.concat(classNames).join(' ')}>\n <ScrollGrid\n ref={this.scrollGridRef}\n liquid={!props.isHeightAuto && !props.forPrint}\n collapsibleWidth={false}\n colGroups={[\n { cols: slatCols },\n ]}\n sections={sections}\n />\n </div>\n )}\n </ViewRoot>\n )\n }\n\n handleSlatCoords = (slatCoords: TimelineCoords | null) => {\n this.setState({ slatCoords })\n }\n\n handleScrollLeftRequest = (scrollLeft: number) => {\n let scrollGrid = this.scrollGridRef.current\n scrollGrid.forceScrollLeft(0, scrollLeft)\n }\n\n handleMaxCushionWidth = (slotCushionMaxWidth) => {\n this.setState({\n slotCushionMaxWidth: Math.ceil(slotCushionMaxWidth), // for less rerendering TODO: DRY\n })\n }\n\n computeFallbackSlotMinWidth(tDateProfile: TimelineDateProfile) { // TODO: duplicate definition\n return Math.max(30, ((this.state.slotCushionMaxWidth || 0) / tDateProfile.slotsPerLabel))\n }\n}\n\nexport function buildSlatCols(tDateProfile: TimelineDateProfile, slotMinWidth?: number) {\n return [{\n span: tDateProfile.slotCnt,\n minWidth: slotMinWidth || 1, // needs to be a non-zero number to trigger horizontal scrollbars!??????\n }]\n}\n","import { createPlugin } from '@fullcalendar/common'\n\nimport premiumCommonPlugin from '@fullcalendar/premium-common' // eslint-disable-line import/no-duplicates\n// ensure ambient declarations\nimport '@fullcalendar/premium-common' // eslint-disable-line import/no-duplicates\n\nimport { TimelineView } from './TimelineView'\nimport './main.css'\n\nexport { TimelineView }\nexport { buildSlatCols } from './TimelineView'\nexport { TimelineLane, TimelineLaneProps, TimelineLaneCoreProps } from './TimelineLane'\nexport { TimelineLaneBg } from './TimelineLaneBg'\nexport { TimelineHeader } from './TimelineHeader'\nexport { TimelineSlats } from './TimelineSlats'\nexport { TimelineDateProfile, buildTimelineDateProfile } from './timeline-date-profile'\nexport { TimelineCoords, coordToCss, coordsToCss } from './TimelineCoords'\nexport { TimelineLaneSlicer, TimelineLaneSeg } from './TimelineLaneSlicer'\nexport { TimelineHeaderRows } from './TimelineHeaderRows'\n\nexport default createPlugin({\n deps: [\n premiumCommonPlugin,\n ],\n initialView: 'timelineDay',\n views: {\n\n timeline: {\n component: TimelineView,\n usesMinMaxTime: true,\n eventResizableFromStart: true, // how is this consumed for TimelineView tho?\n },\n\n timelineDay: {\n type: 'timeline',\n duration: { days: 1 },\n },\n\n timelineWeek: {\n type: 'timeline',\n duration: { weeks: 1 },\n },\n\n timelineMonth: {\n type: 'timeline',\n duration: { months: 1 },\n },\n\n timelineYear: {\n type: 'timeline',\n duration: { years: 1 },\n },\n\n },\n})\n"],"names":[],"mappings":";;;;;;;;;;;;AAmCA,IAAM,eAAe,GAAG,EAAE,CAAA;AAC1B,IAAM,wBAAwB,GAAG,CAAC,CAAA;AAClC,IAAM,cAAc,GAAG,GAAG,CAAA;AAC1B,MAAM,CAAC,kBAAkB,GAAG,IAAI,CAAA;AAEhC;AACA,IAAM,mBAAmB,GAAG;IAC1B,EAAE,KAAK,EAAE,CAAC,EAAE;IACZ,EAAE,MAAM,EAAE,CAAC,EAAE;IACb,EAAE,IAAI,EAAE,CAAC,EAAE;IACX,EAAE,KAAK,EAAE,CAAC,EAAE;IACZ,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,CAAC,EAAE;IACd,EAAE,OAAO,EAAE,CAAC,EAAE;IACd,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,EAAE,EAAE;IACf,EAAE,OAAO,EAAE,CAAC,EAAE;IACd,EAAE,OAAO,EAAE,CAAC,EAAE;IACd,EAAE,YAAY,EAAE,GAAG,EAAE;IACrB,EAAE,YAAY,EAAE,GAAG,EAAE;IACrB,EAAE,YAAY,EAAE,EAAE,EAAE;IACpB,EAAE,YAAY,EAAE,CAAC,EAAE;CACpB,CAAA;SAEe,wBAAwB,CACtC,WAAwB,EACxB,OAAgB,EAChB,UAA8B,EAC9B,oBAA0C;IAE1C,IAAI,YAAY,GAAG;QACjB,aAAa,EAAE,UAAU,CAAC,iBAAiB;QAC3C,YAAY,EAAE,UAAU,CAAC,YAAY;K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AI,EAAE,UAAU;YAChB,QAAQ,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE;SACvB;QAED,aAAa,EAAE;YACb,IAAI,EAAE,UAAU;YAChB,QAAQ,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE;SACxB;QAED,YAAY,EAAE;YACZ,IAAI,EAAE,UAAU;YAChB,QAAQ,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE;SACvB;KAEF;CACF,CAAC;;;;;"}
1
+ {"version":3,"file":"main.js","sources":["src/timeline-date-profile.ts","src/TimelineHeaderThInner.tsx","src/TimelineHeaderTh.tsx","src/TimelineHeaderRows.tsx","src/TimelineCoords.ts","src/TimelineHeader.tsx","src/TimelineSlatCell.tsx","src/TimelineSlatsBody.tsx","src/TimelineSlats.tsx","src/event-placement.ts","src/TimelineLaneBg.tsx","src/TimelineLaneSlicer.ts","src/TimelineEvent.tsx","src/TimelineLaneMoreLink.tsx","src/TimelineLane.tsx","src/TimelineGrid.tsx","src/TimelineView.tsx","src/main.ts"],"sourcesContent":["import {\n config, computeVisibleDayRange, Duration, DateProfile, asCleanDays, addDays, wholeDivideDurations, DateMarker,\n startOfDay, createDuration, DateEnv, diffWholeDays, asRoughMs, createFormatter, greatestDurationDenominator,\n asRoughMinutes, padStart, asRoughSeconds, DateRange, isInt, DateProfileGenerator, BaseOptionsRefined,\n} from '@fullcalendar/common'\n\nexport interface TimelineDateProfile {\n labelInterval: Duration\n slotDuration: Duration\n slotsPerLabel: number\n headerFormats: any\n isTimeScale: boolean\n largeUnit: string\n emphasizeWeeks: boolean\n snapDuration: Duration\n snapsPerSlot: number\n normalizedRange: DateRange // snaps to unit. adds in slotMinTime/slotMaxTime\n timeWindowMs: number\n slotDates: DateMarker[]\n isWeekStarts: boolean[]\n snapDiffToIndex: number[]\n snapIndexToDiff: number[]\n snapCnt: number\n slotCnt: number\n cellRows: TimelineHeaderCell[][]\n}\n\nexport interface TimelineHeaderCell {\n date: DateMarker\n text: string\n rowUnit: string\n colspan: number\n isWeekStart: boolean\n}\n\nconst MIN_AUTO_LABELS = 18 // more than `12` months but less that `24` hours\nconst MAX_AUTO_SLOTS_PER_LABEL = 6 // allows 6 10-min slots in an hour\nconst MAX_AUTO_CELLS = 200 // allows 4-days to have a :30 slot duration\nconfig.MAX_TIMELINE_SLOTS = 1000\n\n// potential nice values for slot-duration and interval-duration\nconst STOCK_SUB_DURATIONS = [ // from largest to smallest\n { years: 1 },\n { months: 1 },\n { days: 1 },\n { hours: 1 },\n { minutes: 30 },\n { minutes: 15 },\n { minutes: 10 },\n { minutes: 5 },\n { minutes: 1 },\n { seconds: 30 },\n { seconds: 15 },\n { seconds: 10 },\n { seconds: 5 },\n { seconds: 1 },\n { milliseconds: 500 },\n { milliseconds: 100 },\n { milliseconds: 10 },\n { milliseconds: 1 },\n]\n\nexport function buildTimelineDateProfile(\n dateProfile: DateProfile,\n dateEnv: DateEnv,\n allOptions: BaseOptionsRefined,\n dateProfileGenerator: DateProfileGenerator,\n): TimelineDateProfile {\n let tDateProfile = {\n labelInterval: allOptions.slotLabelInterval,\n slotDuration: allOptions.slotDuration,\n } as TimelineDateProfile\n\n validateLabelAndSlot(tDateProfile, dateProfile, dateEnv) // validate after computed grid duration\n ensureLabelInterval(tDateProfile, dateProfile, dateEnv)\n ensureSlotDuration(tDateProfile, dateProfile, dateEnv)\n\n let input = allOptions.slotLabelFormat\n let rawFormats =\n Array.isArray(input) ? input :\n (input != null) ? [input] :\n computeHeaderFormats(tDateProfile, dateProfile, dateEnv, allOptions)\n\n tDateProfile.headerFormats = rawFormats.map((rawFormat) => createFormatter(rawFormat))\n\n tDateProfile.isTimeScale = Boolean(tDateProfile.slotDuration.milliseconds)\n\n let largeUnit = null\n if (!tDateProfile.isTimeScale) {\n const slotUnit = greatestDurationDenominator(tDateProfile.slotDuration).unit\n if (/year|month|week/.test(slotUnit)) {\n largeUnit = slotUnit\n }\n }\n\n tDateProfile.largeUnit = largeUnit\n\n tDateProfile.emphasizeWeeks =\n asCleanDays(tDateProfile.slotDuration) === 1 &&\n currentRangeAs('weeks', dateProfile, dateEnv) >= 2 &&\n !allOptions.businessHours\n\n /*\n console.log('label interval =', timelineView.labelInterval.humanize())\n console.log('slot duration =', timelineView.slotDuration.humanize())\n console.log('header formats =', timelineView.headerFormats)\n console.log('isTimeScale', timelineView.isTimeScale)\n console.log('largeUnit', timelineView.largeUnit)\n */\n\n let rawSnapDuration = allOptions.snapDuration\n let snapDuration\n let snapsPerSlot\n\n if (rawSnapDuration) {\n snapDuration = createDuration(rawSnapDuration)\n snapsPerSlot = wholeDivideDurations(tDateProfile.slotDuration, snapDuration)\n // ^ TODO: warning if not whole?\n }\n\n if (snapsPerSlot == null) {\n snapDuration = tDateProfile.slotDuration\n snapsPerSlot = 1\n }\n\n tDateProfile.snapDuration = snapDuration\n tDateProfile.snapsPerSlot = snapsPerSlot\n\n // more...\n\n let timeWindowMs = asRoughMs(dateProfile.slotMaxTime) - asRoughMs(dateProfile.slotMinTime)\n\n // TODO: why not use normalizeRange!?\n let normalizedStart = normalizeDate(dateProfile.renderRange.start, tDateProfile, dateEnv)\n let normalizedEnd = normalizeDate(dateProfile.renderRange.end, tDateProfile, dateEnv)\n\n // apply slotMinTime/slotMaxTime\n // TODO: View should be responsible.\n if (tDateProfile.isTimeScale) {\n normalizedStart = dateEnv.add(normalizedStart, dateProfile.slotMinTime)\n normalizedEnd = dateEnv.add(\n addDays(normalizedEnd, -1),\n dateProfile.slotMaxTime,\n )\n }\n\n tDateProfile.timeWindowMs = timeWindowMs\n tDateProfile.normalizedRange = { start: normalizedStart, end: normalizedEnd }\n\n let slotDates = []\n let date = normalizedStart\n while (date < normalizedEnd) {\n if (isValidDate(date, tDateProfile, dateProfile, dateProfileGenerator)) {\n slotDates.push(date)\n }\n date = dateEnv.add(date, tDateProfile.slotDuration)\n }\n\n tDateProfile.slotDates = slotDates\n\n // more...\n\n let snapIndex = -1\n let snapDiff = 0 // index of the diff :(\n const snapDiffToIndex = []\n const snapIndexToDiff = []\n\n date = normalizedStart\n while (date < normalizedEnd) {\n if (isValidDate(date, tDateProfile, dateProfile, dateProfileGenerator)) {\n snapIndex += 1\n snapDiffToIndex.push(snapIndex)\n snapIndexToDiff.push(snapDiff)\n } else {\n snapDiffToIndex.push(snapIndex + 0.5)\n }\n date = dateEnv.add(date, tDateProfile.snapDuration)\n snapDiff += 1\n }\n\n tDateProfile.snapDiffToIndex = snapDiffToIndex\n tDateProfile.snapIndexToDiff = snapIndexToDiff\n\n tDateProfile.snapCnt = snapIndex + 1 // is always one behind\n tDateProfile.slotCnt = tDateProfile.snapCnt / tDateProfile.snapsPerSlot\n\n // more...\n\n tDateProfile.isWeekStarts = buildIsWeekStarts(tDateProfile, dateEnv)\n tDateProfile.cellRows = buildCellRows(tDateProfile, dateEnv)\n tDateProfile.slotsPerLabel = wholeDivideDurations(tDateProfile.labelInterval, tDateProfile.slotDuration)\n\n return tDateProfile\n}\n\n/*\nsnaps to appropriate unit\n*/\nexport function normalizeDate(date: DateMarker, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): DateMarker {\n let normalDate = date\n\n if (!tDateProfile.isTimeScale) {\n normalDate = startOfDay(normalDate)\n\n if (tDateProfile.largeUnit) {\n normalDate = dateEnv.startOf(normalDate, tDateProfile.largeUnit)\n }\n }\n\n return normalDate\n}\n\n/*\nsnaps to appropriate unit\n*/\nexport function normalizeRange(range: DateRange, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): DateRange {\n if (!tDateProfile.isTimeScale) {\n range = computeVisibleDayRange(range)\n\n if (tDateProfile.largeUnit) {\n let dayRange = range // preserve original result\n\n range = {\n start: dateEnv.startOf(range.start, tDateProfile.largeUnit),\n end: dateEnv.startOf(range.end, tDateProfile.largeUnit),\n }\n\n // if date is partially through the interval, or is in the same interval as the start,\n // make the exclusive end be the *next* interval\n if (range.end.valueOf() !== dayRange.end.valueOf() || range.end <= range.start) {\n range = {\n start: range.start,\n end: dateEnv.add(range.end, tDateProfile.slotDuration),\n }\n }\n }\n }\n\n return range\n}\n\nexport function isValidDate(\n date: DateMarker,\n tDateProfile: TimelineDateProfile,\n dateProfile: DateProfile,\n dateProfileGenerator: DateProfileGenerator,\n) {\n if (dateProfileGenerator.isHiddenDay(date)) {\n return false\n }\n\n if (tDateProfile.isTimeScale) {\n // determine if the time is within slotMinTime/slotMaxTime, which may have wacky values\n let day = startOfDay(date)\n let timeMs = date.valueOf() - day.valueOf()\n let ms = timeMs - asRoughMs(dateProfile.slotMinTime) // milliseconds since slotMinTime\n ms = ((ms % 86400000) + 86400000) % 86400000 // make negative values wrap to 24hr clock\n return ms < tDateProfile.timeWindowMs // before the slotMaxTime?\n }\n\n return true\n}\n\nfunction validateLabelAndSlot(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n\n // make sure labelInterval doesn't exceed the max number of cells\n if (tDateProfile.labelInterval) {\n const labelCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n tDateProfile.labelInterval,\n )\n if (labelCnt > config.MAX_TIMELINE_SLOTS) {\n console.warn('slotLabelInterval results in too many cells')\n tDateProfile.labelInterval = null\n }\n }\n\n // make sure slotDuration doesn't exceed the maximum number of cells\n if (tDateProfile.slotDuration) {\n const slotCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n tDateProfile.slotDuration,\n )\n if (slotCnt > config.MAX_TIMELINE_SLOTS) {\n console.warn('slotDuration results in too many cells')\n tDateProfile.slotDuration = null\n }\n }\n\n // make sure labelInterval is a multiple of slotDuration\n if (tDateProfile.labelInterval && tDateProfile.slotDuration) {\n const slotsPerLabel = wholeDivideDurations(tDateProfile.labelInterval, tDateProfile.slotDuration)\n if (slotsPerLabel === null || slotsPerLabel < 1) {\n console.warn('slotLabelInterval must be a multiple of slotDuration')\n tDateProfile.slotDuration = null\n }\n }\n}\n\nfunction ensureLabelInterval(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n let { labelInterval } = tDateProfile\n\n if (!labelInterval) {\n // compute based off the slot duration\n // find the largest label interval with an acceptable slots-per-label\n let input\n if (tDateProfile.slotDuration) {\n for (input of STOCK_SUB_DURATIONS) {\n const tryLabelInterval = createDuration(input)\n const slotsPerLabel = wholeDivideDurations(tryLabelInterval, tDateProfile.slotDuration)\n if (slotsPerLabel !== null && slotsPerLabel <= MAX_AUTO_SLOTS_PER_LABEL) {\n labelInterval = tryLabelInterval\n break\n }\n }\n\n // use the slot duration as a last resort\n if (!labelInterval) {\n labelInterval = tDateProfile.slotDuration\n }\n\n // compute based off the view's duration\n // find the largest label interval that yields the minimum number of labels\n } else {\n for (input of STOCK_SUB_DURATIONS) {\n labelInterval = createDuration(input)\n const labelCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n labelInterval,\n )\n if (labelCnt >= MIN_AUTO_LABELS) {\n break\n }\n }\n }\n\n tDateProfile.labelInterval = labelInterval\n }\n\n return labelInterval\n}\n\nfunction ensureSlotDuration(tDateProfile: TimelineDateProfile, dateProfile: DateProfile, dateEnv: DateEnv) {\n const { currentRange } = dateProfile\n let { slotDuration } = tDateProfile\n\n if (!slotDuration) {\n const labelInterval = ensureLabelInterval(tDateProfile, dateProfile, dateEnv) // will compute if necessary\n\n // compute based off the label interval\n // find the largest slot duration that is different from labelInterval, but still acceptable\n for (let input of STOCK_SUB_DURATIONS) {\n const trySlotDuration = createDuration(input)\n const slotsPerLabel = wholeDivideDurations(labelInterval, trySlotDuration)\n if (slotsPerLabel !== null && slotsPerLabel > 1 && slotsPerLabel <= MAX_AUTO_SLOTS_PER_LABEL) {\n slotDuration = trySlotDuration\n break\n }\n }\n\n // only allow the value if it won't exceed the view's # of slots limit\n if (slotDuration) {\n const slotCnt = dateEnv.countDurationsBetween(\n currentRange.start,\n currentRange.end,\n slotDuration,\n )\n if (slotCnt > MAX_AUTO_CELLS) {\n slotDuration = null\n }\n }\n\n // use the label interval as a last resort\n if (!slotDuration) {\n slotDuration = labelInterval\n }\n\n tDateProfile.slotDuration = slotDuration\n }\n\n return slotDuration\n}\n\nfunction computeHeaderFormats(\n tDateProfile: TimelineDateProfile,\n dateProfile: DateProfile,\n dateEnv: DateEnv,\n allOptions: BaseOptionsRefined,\n) {\n let format1\n let format2\n const { labelInterval } = tDateProfile\n let unit = greatestDurationDenominator(labelInterval).unit\n const weekNumbersVisible = allOptions.weekNumbers\n let format0 = (format1 = (format2 = null))\n\n // NOTE: weekNumber computation function wont work\n\n if ((unit === 'week') && !weekNumbersVisible) {\n unit = 'day'\n }\n\n switch (unit) {\n case 'year':\n format0 = { year: 'numeric' } // '2015'\n break\n\n case 'month':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric' } // '2015'\n }\n\n format1 = { month: 'short' } // 'Jan'\n break\n\n case 'week':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric' } // '2015'\n }\n\n format1 = { week: 'narrow' } // 'Wk4'\n break\n\n case 'day':\n if (currentRangeAs('years', dateProfile, dateEnv) > 1) {\n format0 = { year: 'numeric', month: 'long' } // 'January 2014'\n } else if (currentRangeAs('months', dateProfile, dateEnv) > 1) {\n format0 = { month: 'long' } // 'January'\n }\n\n if (weekNumbersVisible) {\n format1 = { week: 'short' } // 'Wk 4'\n }\n\n format2 = { weekday: 'narrow', day: 'numeric' } // 'Su 9'\n break\n\n case 'hour':\n if (weekNumbersVisible) {\n format0 = { week: 'short' } // 'Wk 4'\n }\n\n if (currentRangeAs('days', dateProfile, dateEnv) > 1) {\n format1 = { weekday: 'short', day: 'numeric', month: 'numeric', omitCommas: true } // Sat 4/7\n }\n\n format2 = {\n hour: 'numeric',\n minute: '2-digit',\n omitZeroMinute: true,\n meridiem: 'short',\n }\n break\n\n case 'minute':\n // sufficiently large number of different minute cells?\n if ((asRoughMinutes(labelInterval) / 60) >= MAX_AUTO_SLOTS_PER_LABEL) {\n format0 = {\n hour: 'numeric',\n meridiem: 'short',\n }\n format1 = (params) => (\n ':' + padStart(params.date.minute, 2) // ':30'\n )\n } else {\n format0 = {\n hour: 'numeric',\n minute: 'numeric',\n meridiem: 'short',\n }\n }\n break\n\n case 'second':\n // sufficiently large number of different second cells?\n if ((asRoughSeconds(labelInterval) / 60) >= MAX_AUTO_SLOTS_PER_LABEL) {\n format0 = { hour: 'numeric', minute: '2-digit', meridiem: 'lowercase' } // '8:30 PM'\n format1 = (params) => (\n ':' + padStart(params.date.second, 2) // ':30'\n )\n } else {\n format0 = { hour: 'numeric', minute: '2-digit', second: '2-digit', meridiem: 'lowercase' } // '8:30:45 PM'\n }\n break\n\n case 'millisecond':\n format0 = { hour: 'numeric', minute: '2-digit', second: '2-digit', meridiem: 'lowercase' } // '8:30:45 PM'\n format1 = (params) => (\n '.' + padStart(params.millisecond, 3)\n )\n break\n }\n\n return [].concat(format0 || [], format1 || [], format2 || [])\n}\n\n// Compute the number of the give units in the \"current\" range.\n// Won't go more precise than days.\n// Will return `0` if there's not a clean whole interval.\nfunction currentRangeAs(unit: string, dateProfile: DateProfile, dateEnv: DateEnv) {\n let range = dateProfile.currentRange\n let res = null\n\n if (unit === 'years') {\n res = dateEnv.diffWholeYears(range.start, range.end)\n } else if (unit === 'months') {\n res = dateEnv.diffWholeMonths(range.start, range.end)\n } else if (unit === 'weeks') {\n res = dateEnv.diffWholeMonths(range.start, range.end)\n } else if (unit === 'days') {\n res = diffWholeDays(range.start, range.end)\n }\n\n return res || 0\n}\n\nfunction buildIsWeekStarts(tDateProfile: TimelineDateProfile, dateEnv: DateEnv) {\n let { slotDates, emphasizeWeeks } = tDateProfile\n let prevWeekNumber = null\n let isWeekStarts: boolean[] = []\n\n for (let slotDate of slotDates) {\n let weekNumber = dateEnv.computeWeekNumber(slotDate)\n let isWeekStart = emphasizeWeeks && (prevWeekNumber !== null) && (prevWeekNumber !== weekNumber)\n prevWeekNumber = weekNumber\n\n isWeekStarts.push(isWeekStart)\n }\n\n return isWeekStarts\n}\n\nfunction buildCellRows(tDateProfile: TimelineDateProfile, dateEnv: DateEnv) {\n let slotDates = tDateProfile.slotDates\n let formats = tDateProfile.headerFormats\n let cellRows = formats.map(() => []) // indexed by row,col\n let slotAsDays = asCleanDays(tDateProfile.slotDuration)\n let guessedSlotUnit =\n slotAsDays === 7 ? 'week' :\n slotAsDays === 1 ? 'day' :\n null\n\n // specifically for navclicks\n let rowUnitsFromFormats = formats.map(\n (format) => (format.getLargestUnit ? format.getLargestUnit() : null),\n )\n\n // builds cellRows and slotCells\n for (let i = 0; i < slotDates.length; i += 1) {\n let date = slotDates[i]\n let isWeekStart = tDateProfile.isWeekStarts[i]\n\n for (let row = 0; row < formats.length; row += 1) {\n let format = formats[row]\n let rowCells = cellRows[row]\n let leadingCell = rowCells[rowCells.length - 1]\n let isLastRow = row === formats.length - 1\n let isSuperRow = formats.length > 1 && !isLastRow // more than one row and not the last\n let newCell = null\n let rowUnit = rowUnitsFromFormats[row] || (isLastRow ? guessedSlotUnit : null)\n\n if (isSuperRow) {\n let text = dateEnv.format(date, format)\n if (!leadingCell || (leadingCell.text !== text)) {\n newCell = buildCellObject(date, text, rowUnit)\n } else {\n leadingCell.colspan += 1\n }\n } else if (\n !leadingCell ||\n isInt(dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n date,\n tDateProfile.labelInterval,\n ))\n ) {\n let text = dateEnv.format(date, format)\n newCell = buildCellObject(date, text, rowUnit)\n } else {\n leadingCell.colspan += 1\n }\n\n if (newCell) {\n newCell.weekStart = isWeekStart\n rowCells.push(newCell)\n }\n }\n }\n\n return cellRows\n}\n\nfunction buildCellObject(date: DateMarker, text, rowUnit): TimelineHeaderCell {\n return { date, text, rowUnit, colspan: 1, isWeekStart: false }\n}\n","import { createElement, BaseComponent, DateMarker, ContentHook, ViewApi, DateEnv } from '@fullcalendar/common'\n\nexport interface TimelineHeaderThInnerProps {\n hookProps: HookProps\n isSticky: boolean\n navLinkAttrs: object | null\n}\n\nexport class TimelineHeaderThInner extends BaseComponent<TimelineHeaderThInnerProps> {\n render() {\n let { props, context } = this\n\n return (\n <ContentHook hookProps={props.hookProps} content={context.options.slotLabelContent} defaultContent={renderInnerContent}>\n {(innerElRef, innerContent) => (\n <a\n ref={innerElRef}\n className={'fc-timeline-slot-cushion fc-scrollgrid-sync-inner' + (props.isSticky ? ' fc-sticky' : '')}\n {...props.navLinkAttrs}\n >\n {innerContent}\n </a>\n )}\n </ContentHook>\n )\n }\n}\n\nfunction renderInnerContent(props) { // TODO: add types\n return props.text\n}\n\n// hook props\n// ----------\n\nexport interface HookPropsInput {\n level: number\n dateMarker: DateMarker\n text: string\n dateEnv: DateEnv\n viewApi: ViewApi\n}\n\nexport interface HookProps {\n level: number\n date: DateMarker // localized\n view: ViewApi\n text: string\n}\n\nexport function refineHookProps(input: HookPropsInput): HookProps {\n return {\n level: input.level,\n date: input.dateEnv.toDate(input.dateMarker),\n view: input.viewApi,\n text: input.text,\n }\n}\n","import {\n createElement, BaseComponent, DateRange, DateMarker, getDateMeta, getSlotClassNames,\n buildNavLinkAttrs, buildClassNameNormalizer, MountHook,\n getDayClassNames, DateProfile, memoizeObjArg, ViewContext, memoize,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile, TimelineHeaderCell } from './timeline-date-profile'\nimport { TimelineHeaderThInner, refineHookProps, HookProps } from './TimelineHeaderThInner'\n\nexport interface TimelineHeaderThProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n rowLevel: number\n cell: TimelineHeaderCell\n todayRange: DateRange\n nowDate: DateMarker\n rowInnerHeight?: number\n isSticky: boolean\n}\n\nexport class TimelineHeaderTh extends BaseComponent<TimelineHeaderThProps> {\n refineHookProps = memoizeObjArg(refineHookProps)\n normalizeClassNames = buildClassNameNormalizer<HookProps>()\n buildCellNavLinkAttrs = memoize(buildCellNavLinkAttrs)\n\n render() {\n let { props, context } = this\n let { dateEnv, options } = context\n let { cell, dateProfile, tDateProfile } = props\n\n // the cell.rowUnit is f'd\n // giving 'month' for a 3-day view\n // workaround: to infer day, do NOT time\n\n let dateMeta = getDateMeta(cell.date, props.todayRange, props.nowDate, dateProfile)\n\n let classNames = ['fc-timeline-slot', 'fc-timeline-slot-label'].concat(\n cell.rowUnit === 'time' // TODO: so slot classnames for week/month/bigger. see note above about rowUnit\n ? getSlotClassNames(dateMeta, context.theme)\n : getDayClassNames(dateMeta, context.theme),\n )\n\n if (cell.isWeekStart) {\n classNames.push('fc-timeline-slot-em')\n }\n\n let hookProps = this.refineHookProps({\n level: props.rowLevel,\n dateMarker: cell.date,\n text: cell.text,\n dateEnv: context.dateEnv,\n viewApi: context.viewApi,\n })\n\n let customClassNames = this.normalizeClassNames(options.slotLabelClassNames, hookProps)\n\n return (\n <MountHook hookProps={hookProps} didMount={options.slotLabelDidMount} willUnmount={options.slotLabelWillUnmount}>\n {(rootElRef) => (\n <th\n ref={rootElRef}\n className={classNames.concat(customClassNames).join(' ')}\n data-date={dateEnv.formatIso(cell.date, { omitTime: !tDateProfile.isTimeScale, omitTimeZoneOffset: true })}\n colSpan={cell.colspan}\n >\n <div className=\"fc-timeline-slot-frame\" style={{ height: props.rowInnerHeight }}>\n <TimelineHeaderThInner\n hookProps={hookProps}\n isSticky={props.isSticky}\n navLinkAttrs={this.buildCellNavLinkAttrs(context, cell.date, cell.rowUnit)}\n />\n </div>\n </th>\n )}\n </MountHook>\n )\n }\n}\n\nfunction buildCellNavLinkAttrs(context: ViewContext, cellDate: DateMarker, rowUnit: string): object {\n return (rowUnit && rowUnit !== 'time')\n ? buildNavLinkAttrs(context, cellDate, rowUnit)\n : {}\n}\n","import { createElement, BaseComponent, Fragment, DateRange, DateMarker, DateProfile } from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineHeaderTh } from './TimelineHeaderTh'\n\nexport interface TimelineHeaderRowsProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n rowInnerHeights?: number[]\n}\n\nexport class TimelineHeaderRows extends BaseComponent<TimelineHeaderRowsProps> {\n render() {\n let { dateProfile, tDateProfile, rowInnerHeights, todayRange, nowDate } = this.props\n let { cellRows } = tDateProfile\n\n return (\n <Fragment>\n {cellRows.map((rowCells, rowLevel) => {\n let isLast = rowLevel === cellRows.length - 1\n let isChrono = tDateProfile.isTimeScale && isLast // the final row, with times?\n let classNames = [\n 'fc-timeline-header-row',\n isChrono ? 'fc-timeline-header-row-chrono' : '',\n ]\n\n return ( // eslint-disable-next-line react/no-array-index-key\n <tr key={rowLevel} className={classNames.join(' ')}>\n {rowCells.map((cell) => (\n <TimelineHeaderTh\n key={cell.date.toISOString()}\n cell={cell}\n rowLevel={rowLevel}\n dateProfile={dateProfile}\n tDateProfile={tDateProfile}\n todayRange={todayRange}\n nowDate={nowDate}\n rowInnerHeight={rowInnerHeights && rowInnerHeights[rowLevel]}\n isSticky={!isLast}\n />\n ))}\n </tr>\n )\n })}\n </Fragment>\n )\n }\n}\n","import {\n PositionCache, findDirectChildren,\n isInt, DateProfile,\n DateMarker, DateEnv, Duration, startOfDay, rangeContainsMarker, CssDimValue, DateRange, SegSpan,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport class TimelineCoords { // TODO: rename to \"slat\" coords?\n outerCoordCache: PositionCache\n innerCoordCache: PositionCache\n\n constructor(\n public slatRootEl: HTMLElement, // okay to expose?\n slatEls: HTMLElement[],\n public dateProfile: DateProfile,\n private tDateProfile: TimelineDateProfile,\n private dateEnv: DateEnv,\n public isRtl: boolean,\n ) {\n this.outerCoordCache = new PositionCache(\n slatRootEl,\n slatEls,\n true, // isHorizontal\n false, // isVertical\n )\n\n // for the inner divs within the slats\n // used for event rendering and scrollTime, to disregard slat border\n this.innerCoordCache = new PositionCache(\n slatRootEl,\n findDirectChildren(slatEls, 'div'),\n true, // isHorizontal\n false, // isVertical\n )\n }\n\n isDateInRange(date: DateMarker) {\n return rangeContainsMarker(this.dateProfile.currentRange, date)\n }\n\n // results range from negative width of area to 0\n dateToCoord(date: DateMarker): number {\n let { tDateProfile } = this\n let snapCoverage = this.computeDateSnapCoverage(date)\n let slotCoverage = snapCoverage / tDateProfile.snapsPerSlot\n let slotIndex = Math.floor(slotCoverage)\n slotIndex = Math.min(slotIndex, tDateProfile.slotCnt - 1)\n let partial = slotCoverage - slotIndex\n let { innerCoordCache, outerCoordCache } = this\n\n if (this.isRtl) {\n return outerCoordCache.originClientRect.width - (\n outerCoordCache.rights[slotIndex] -\n (innerCoordCache.getWidth(slotIndex) * partial)\n )\n }\n\n return (\n outerCoordCache.lefts[slotIndex] +\n (innerCoordCache.getWidth(slotIndex) * partial)\n )\n }\n\n rangeToCoords(range: DateRange): SegSpan {\n return {\n start: this.dateToCoord(range.start),\n end: this.dateToCoord(range.end),\n }\n }\n\n durationToCoord(duration: Duration): number {\n let { dateProfile, tDateProfile, dateEnv, isRtl } = this\n let coord = 0\n\n if (dateProfile) {\n let date = dateEnv.add(dateProfile.activeRange.start, duration)\n\n if (!tDateProfile.isTimeScale) {\n date = startOfDay(date)\n }\n\n coord = this.dateToCoord(date)\n\n // hack to overcome the left borders of non-first slat\n if (!isRtl && coord) {\n coord += 1\n }\n }\n\n return coord\n }\n\n coordFromLeft(coord: number) {\n if (this.isRtl) {\n return this.outerCoordCache.originClientRect.width - coord\n }\n return coord\n }\n\n // returned value is between 0 and the number of snaps\n computeDateSnapCoverage(date: DateMarker): number {\n return computeDateSnapCoverage(date, this.tDateProfile, this.dateEnv)\n }\n}\n\n// returned value is between 0 and the number of snaps\nexport function computeDateSnapCoverage(date: DateMarker, tDateProfile: TimelineDateProfile, dateEnv: DateEnv): number {\n let snapDiff = dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n date,\n tDateProfile.snapDuration,\n )\n\n if (snapDiff < 0) {\n return 0\n }\n\n if (snapDiff >= tDateProfile.snapDiffToIndex.length) {\n return tDateProfile.snapCnt\n }\n\n let snapDiffInt = Math.floor(snapDiff)\n let snapCoverage = tDateProfile.snapDiffToIndex[snapDiffInt]\n\n if (isInt(snapCoverage)) { // not an in-between value\n snapCoverage += snapDiff - snapDiffInt // add the remainder\n } else {\n // a fractional value, meaning the date is not visible\n // always round up in this case. works for start AND end dates in a range.\n snapCoverage = Math.ceil(snapCoverage)\n }\n\n return snapCoverage\n}\n\nexport function coordToCss(\n hcoord: number | null,\n isRtl: boolean,\n): { left: CssDimValue, right: CssDimValue } {\n if (hcoord === null) {\n return { left: '', right: '' }\n }\n if (isRtl) {\n return { right: hcoord, left: '' }\n }\n return { left: hcoord, right: '' }\n}\n\nexport function coordsToCss(\n hcoords: SegSpan | null,\n isRtl: boolean,\n): { left: CssDimValue, right: CssDimValue } {\n if (!hcoords) {\n return { left: '', right: '' }\n }\n if (isRtl) {\n return { right: hcoords.start, left: -hcoords.end }\n }\n return { left: hcoords.start, right: -hcoords.end }\n}\n","import {\n createElement, BaseComponent, CssDimValue, VNode, DateMarker, NowTimer,\n greatestDurationDenominator, DateRange, NowIndicatorRoot, createRef,\n findElements, RefObject, DateProfile,\n} from '@fullcalendar/common'\nimport { TimelineHeaderRows } from './TimelineHeaderRows'\nimport { coordToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelineHeaderProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n clientWidth: number | null\n clientHeight: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n slatCoords: TimelineCoords\n rowInnerHeights?: number[]\n onMaxCushionWidth?: (number) => void\n}\n\nexport class TimelineHeader extends BaseComponent<TimelineHeaderProps> {\n rootElRef: RefObject<HTMLDivElement> = createRef<HTMLDivElement>()\n\n render() {\n let { props, context } = this\n\n // TODO: very repetitive\n // TODO: make part of tDateProfile?\n let timerUnit = greatestDurationDenominator(props.tDateProfile.slotDuration).unit\n\n // WORKAROUND: make ignore slatCoords when out of sync with dateProfile\n let slatCoords = props.slatCoords && props.slatCoords.dateProfile === props.dateProfile ? props.slatCoords : null\n\n return (\n <NowTimer unit={timerUnit}>\n {(nowDate: DateMarker, todayRange: DateRange) => (\n <div className=\"fc-timeline-header\" ref={this.rootElRef}>\n <table\n aria-hidden\n className=\"fc-scrollgrid-sync-table\"\n style={{ minWidth: props.tableMinWidth, width: props.clientWidth }}\n >\n {props.tableColGroupNode}\n <tbody>\n <TimelineHeaderRows\n dateProfile={props.dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n rowInnerHeights={props.rowInnerHeights}\n />\n </tbody>\n </table>\n {context.options.nowIndicator && (\n // need to have a container regardless of whether the current view has a visible now indicator\n // because apparently removal of the element resets the scroll for some reasons (issue #5351).\n // this issue doesn't happen for the timeline body however (\n <div className=\"fc-timeline-now-indicator-container\">\n {(slatCoords && slatCoords.isDateInRange(nowDate)) && (\n <NowIndicatorRoot isAxis date={nowDate}>\n {(rootElRef, classNames, innerElRef, innerContent) => (\n <div\n ref={rootElRef}\n className={['fc-timeline-now-indicator-arrow'].concat(classNames).join(' ')}\n style={coordToCss(slatCoords.dateToCoord(nowDate), context.isRtl)}\n >\n {innerContent}\n </div>\n )}\n </NowIndicatorRoot>\n )}\n </div>\n )}\n </div>\n )}\n </NowTimer>\n )\n }\n\n componentDidMount() {\n this.updateSize()\n }\n\n componentDidUpdate() {\n this.updateSize()\n }\n\n updateSize() {\n if (this.props.onMaxCushionWidth) {\n this.props.onMaxCushionWidth(this.computeMaxCushionWidth())\n }\n }\n\n computeMaxCushionWidth() { // TODO: called way too often\n return Math.max(\n ...findElements(this.rootElRef.current, '.fc-timeline-header-row:last-child .fc-timeline-slot-cushion').map(\n (el) => el.getBoundingClientRect().width,\n ),\n )\n }\n}\n","import {\n createElement, isInt, BaseComponent, DateMarker, Ref, DateRange, getDateMeta, getSlotClassNames,\n RenderHook, getDayClassNames, SlotLaneContentArg, DateProfile,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelineSlatCellProps {\n date: DateMarker\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n isDay: boolean\n isEm: boolean\n elRef?: Ref<HTMLTableCellElement>\n}\n\nexport class TimelineSlatCell extends BaseComponent<TimelineSlatCellProps> {\n render() {\n let { props, context } = this\n let { dateEnv, options, theme } = context\n let { date, tDateProfile, isEm } = props\n let dateMeta = getDateMeta(props.date, props.todayRange, props.nowDate, props.dateProfile)\n let classNames = ['fc-timeline-slot', 'fc-timeline-slot-lane']\n let dataAttrs = { 'data-date': dateEnv.formatIso(date, { omitTimeZoneOffset: true, omitTime: !tDateProfile.isTimeScale }) }\n let hookProps: SlotLaneContentArg = {\n date: dateEnv.toDate(props.date),\n ...dateMeta,\n view: context.viewApi,\n }\n\n if (isEm) {\n classNames.push('fc-timeline-slot-em')\n }\n\n if (tDateProfile.isTimeScale) {\n classNames.push(\n isInt(dateEnv.countDurationsBetween(\n tDateProfile.normalizedRange.start,\n props.date,\n tDateProfile.labelInterval,\n )) ?\n 'fc-timeline-slot-major' :\n 'fc-timeline-slot-minor',\n )\n }\n\n classNames.push(...(\n props.isDay\n ? getDayClassNames(dateMeta, theme)\n : getSlotClassNames(dateMeta, theme)\n ))\n\n return (\n <RenderHook\n hookProps={hookProps}\n classNames={options.slotLaneClassNames}\n content={options.slotLaneContent}\n didMount={options.slotLaneDidMount}\n willUnmount={options.slotLaneWillUnmount}\n elRef={props.elRef}\n >\n {(rootElRef, customClassNames, innerElRef, innerContent) => (\n <td\n ref={rootElRef}\n className={classNames.concat(customClassNames).join(' ')}\n {...dataAttrs}\n >\n <div ref={innerElRef}>{innerContent}</div>\n </td>\n )}\n </RenderHook>\n )\n }\n}\n","import { createElement, BaseComponent, RefMap, DateMarker, DateRange, DateProfile } from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineSlatCell } from './TimelineSlatCell'\n\nexport interface TimelineSlatsContentProps {\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nowDate: DateMarker\n todayRange: DateRange\n}\n\nexport interface TimelineSlatsBodyProps extends TimelineSlatsContentProps {\n cellElRefs: RefMap<HTMLTableCellElement>\n}\n\nexport class TimelineSlatsBody extends BaseComponent<TimelineSlatsBodyProps> {\n render() {\n let { props } = this\n let { tDateProfile, cellElRefs } = props\n let { slotDates, isWeekStarts } = tDateProfile\n let isDay = !tDateProfile.isTimeScale && !tDateProfile.largeUnit\n\n return (\n <tbody>\n <tr>\n {slotDates.map((slotDate, i) => {\n let key = slotDate.toISOString()\n\n return (\n <TimelineSlatCell\n key={key}\n elRef={cellElRefs.createRef(key)}\n date={slotDate}\n dateProfile={props.dateProfile}\n tDateProfile={tDateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n isEm={isWeekStarts[i]}\n isDay={isDay}\n />\n )\n })}\n </tr>\n </tbody>\n )\n }\n}\n","import {\n createElement, BaseComponent, multiplyDuration, RefMap, CssDimValue, VNode,\n createRef, ScrollResponder, ScrollRequest, DateMarker,\n} from '@fullcalendar/common'\nimport { TimelineCoords } from './TimelineCoords'\nimport { TimelineSlatsBody, TimelineSlatsContentProps } from './TimelineSlatsBody'\n\nexport interface TimelineSlatsProps extends TimelineSlatsContentProps {\n clientWidth: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n onCoords?: (coord: TimelineCoords | null) => void\n onScrollLeftRequest?: (scrollLeft: number) => void\n}\n\nexport class TimelineSlats extends BaseComponent<TimelineSlatsProps> {\n private rootElRef = createRef<HTMLDivElement>()\n private cellElRefs = new RefMap<HTMLTableCellElement>()\n private coords: TimelineCoords // for positionToHit\n private scrollResponder: ScrollResponder\n\n render() {\n let { props, context } = this\n\n return (\n <div className=\"fc-timeline-slots\" ref={this.rootElRef}>\n <table\n aria-hidden\n className={context.theme.getClass('table')}\n style={{\n minWidth: props.tableMinWidth,\n width: props.clientWidth,\n }}\n >\n {props.tableColGroupNode}\n <TimelineSlatsBody\n cellElRefs={this.cellElRefs}\n dateProfile={props.dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n />\n </table>\n </div>\n )\n }\n\n componentDidMount() {\n this.updateSizing()\n this.scrollResponder = this.context.createScrollResponder(this.handleScrollRequest)\n }\n\n componentDidUpdate(prevProps: TimelineSlatsProps) {\n this.updateSizing()\n\n this.scrollResponder.update(prevProps.dateProfile !== this.props.dateProfile)\n }\n\n componentWillUnmount() {\n this.scrollResponder.detach()\n\n if (this.props.onCoords) {\n this.props.onCoords(null)\n }\n }\n\n updateSizing() {\n let { props, context } = this\n\n if (\n props.clientWidth !== null && // is sizing stable?\n this.scrollResponder\n // ^it's possible to have clientWidth immediately after mount (when returning from print view), but w/o scrollResponder\n ) {\n let rootEl = this.rootElRef.current\n\n if (rootEl.offsetWidth) { // not hidden by css\n this.coords = new TimelineCoords(\n this.rootElRef.current,\n collectCellEls(this.cellElRefs.currentMap, props.tDateProfile.slotDates),\n props.dateProfile,\n props.tDateProfile,\n context.dateEnv,\n context.isRtl,\n )\n\n if (props.onCoords) {\n props.onCoords(this.coords)\n }\n\n this.scrollResponder.update(false) // TODO: wouldn't have to do this if coords were in state\n }\n }\n }\n\n handleScrollRequest = (request: ScrollRequest) => {\n let { onScrollLeftRequest } = this.props\n let { coords } = this\n\n if (onScrollLeftRequest && coords) {\n if (request.time) {\n let scrollLeft = coords.coordFromLeft(coords.durationToCoord(request.time))\n onScrollLeftRequest(scrollLeft)\n }\n return true\n }\n\n return null // best?\n }\n\n positionToHit(leftPosition) { // TODO: kill somehow\n let { outerCoordCache } = this.coords\n let { dateEnv, isRtl } = this.context\n let { tDateProfile } = this.props\n let slatIndex = outerCoordCache.leftToIndex(leftPosition)\n\n if (slatIndex != null) {\n // somewhat similar to what TimeGrid does. consolidate?\n let slatWidth = outerCoordCache.getWidth(slatIndex)\n let partial = isRtl ?\n (outerCoordCache.rights[slatIndex] - leftPosition) / slatWidth :\n (leftPosition - outerCoordCache.lefts[slatIndex]) / slatWidth\n let localSnapIndex = Math.floor(partial * tDateProfile.snapsPerSlot)\n let start = dateEnv.add(\n tDateProfile.slotDates[slatIndex],\n multiplyDuration(tDateProfile.snapDuration, localSnapIndex),\n )\n let end = dateEnv.add(start, tDateProfile.snapDuration)\n\n return {\n dateSpan: {\n range: { start, end },\n allDay: !this.props.tDateProfile.isTimeScale,\n },\n dayEl: this.cellElRefs.currentMap[slatIndex],\n left: outerCoordCache.lefts[slatIndex], // TODO: make aware of snaps?\n right: outerCoordCache.rights[slatIndex],\n }\n }\n\n return null\n }\n}\n\nfunction collectCellEls(elMap: { [key: string]: HTMLElement }, slotDates: DateMarker[]) {\n return slotDates.map((slotDate) => {\n let key = slotDate.toISOString()\n return elMap[key]\n })\n}\n","import {\n SegSpan, SegHierarchy, groupIntersectingEntries, SegEntry, buildIsoString,\n computeEarliestSegStart,\n} from '@fullcalendar/common'\nimport { TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineSegPlacement {\n seg: TimelineLaneSeg | TimelineLaneSeg[] // HACK: if array, then it's a more-link group\n hcoords: SegSpan | null\n top: number | null\n}\n\nexport function computeSegHCoords(\n segs: TimelineLaneSeg[],\n minWidth: number,\n timelineCoords: TimelineCoords | null,\n): SegSpan[] {\n let hcoords: SegSpan[] = []\n\n if (timelineCoords) {\n for (let seg of segs) {\n let res = timelineCoords.rangeToCoords(seg)\n let start = Math.round(res.start) // for barely-overlapping collisions\n let end = Math.round(res.end) //\n\n if (end - start < minWidth) {\n end = start + minWidth\n }\n\n hcoords.push({ start, end })\n }\n }\n\n return hcoords\n}\n\nexport function computeFgSegPlacements(\n segs: TimelineLaneSeg[],\n segHCoords: SegSpan[], // might not have for every seg\n eventInstanceHeights: { [instanceId: string]: number }, // might not have for every seg\n moreLinkHeights: { [isoStr: string]: number }, // might not have for every more-link\n strictOrder?: boolean,\n maxStackCnt?: number,\n): [TimelineSegPlacement[], number] { // [placements, totalHeight]\n let segInputs: SegEntry[] = []\n let crudePlacements: TimelineSegPlacement[] = [] // when we don't know dims\n\n for (let i = 0; i < segs.length; i += 1) {\n let seg = segs[i]\n let instanceId = seg.eventRange.instance.instanceId\n let height = eventInstanceHeights[instanceId]\n let hcoords = segHCoords[i]\n\n if (height && hcoords) {\n segInputs.push({\n index: i,\n span: hcoords,\n thickness: height,\n })\n } else {\n crudePlacements.push({\n seg,\n hcoords, // might as well set hcoords if we have them. might be null\n top: null,\n })\n }\n }\n\n let hierarchy = new SegHierarchy()\n if (strictOrder != null) {\n hierarchy.strictOrder = strictOrder\n }\n if (maxStackCnt != null) {\n hierarchy.maxStackCnt = maxStackCnt\n }\n\n let hiddenEntries = hierarchy.addSegs(segInputs)\n let hiddenPlacements = hiddenEntries.map((entry) => ({\n seg: segs[entry.index],\n hcoords: entry.span,\n top: null,\n } as TimelineSegPlacement))\n\n let hiddenGroups = groupIntersectingEntries(hiddenEntries)\n let moreLinkInputs: SegEntry[] = []\n let moreLinkCrudePlacements: TimelineSegPlacement[] = []\n const extractSeg = (entry: SegEntry) => segs[entry.index]\n\n for (let i = 0; i < hiddenGroups.length; i += 1) {\n let hiddenGroup = hiddenGroups[i]\n let sortedSegs = hiddenGroup.entries.map(extractSeg)\n let height = moreLinkHeights[buildIsoString(computeEarliestSegStart(sortedSegs))] // not optimal :(\n\n if (height != null) {\n // NOTE: the hiddenGroup's spanStart/spanEnd are already computed by rangeToCoords. computed during input.\n moreLinkInputs.push({\n index: segs.length + i, // out-of-bounds indexes map to hiddenGroups\n thickness: height,\n span: hiddenGroup.span,\n })\n } else {\n moreLinkCrudePlacements.push({\n seg: sortedSegs, // a Seg array signals a more-link\n hcoords: hiddenGroup.span,\n top: null,\n })\n }\n }\n\n // add more-links into the hierarchy, but don't limit\n hierarchy.maxStackCnt = -1\n hierarchy.addSegs(moreLinkInputs)\n\n let visibleRects = hierarchy.toRects()\n let visiblePlacements: TimelineSegPlacement[] = []\n let maxHeight = 0\n\n for (let rect of visibleRects) {\n let segIndex = rect.index\n visiblePlacements.push({\n seg: segIndex < segs.length\n ? segs[segIndex] // a real seg\n : hiddenGroups[segIndex - segs.length].entries.map(extractSeg), // signals a more-link\n hcoords: rect.span,\n top: rect.levelCoord,\n })\n maxHeight = Math.max(maxHeight, rect.levelCoord + rect.thickness)\n }\n\n return [\n visiblePlacements.concat(crudePlacements, hiddenPlacements, moreLinkCrudePlacements),\n maxHeight,\n ]\n}\n","import {\n BaseComponent, createElement, Fragment, BgEvent, renderFill,\n getSegMeta, DateRange, DateMarker, buildEventRangeKey,\n} from '@fullcalendar/common'\nimport { computeSegHCoords } from './event-placement'\nimport { coordsToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineLaneBgProps {\n businessHourSegs: TimelineLaneSeg[] | null // can be null :(\n bgEventSegs: TimelineLaneSeg[] | null // can be null :(\n dateSelectionSegs: TimelineLaneSeg[]\n eventResizeSegs: TimelineLaneSeg[]\n timelineCoords: TimelineCoords | null\n todayRange: DateRange\n nowDate: DateMarker\n}\n\nexport class TimelineLaneBg extends BaseComponent<TimelineLaneBgProps> {\n render() {\n let { props } = this\n let highlightSeg = [].concat(props.eventResizeSegs, props.dateSelectionSegs)\n\n return props.timelineCoords && (\n <div className=\"fc-timeline-bg\">\n {/* Fragments contain the keys */}\n {this.renderSegs(props.businessHourSegs || [], props.timelineCoords, 'non-business')}\n {this.renderSegs(props.bgEventSegs || [], props.timelineCoords, 'bg-event')}\n {this.renderSegs(highlightSeg, props.timelineCoords, 'highlight')}\n </div>\n )\n }\n\n renderSegs(segs: TimelineLaneSeg[], timelineCoords: TimelineCoords | null, fillType: string) {\n let { todayRange, nowDate } = this.props\n let { isRtl } = this.context\n let segHCoords = computeSegHCoords(segs, 0, timelineCoords)\n\n let children = segs.map((seg, i) => {\n let hcoords = segHCoords[i]\n let hStyle = coordsToCss(hcoords, isRtl)\n\n return (\n <div\n key={buildEventRangeKey(seg.eventRange)}\n className=\"fc-timeline-bg-harness\"\n style={hStyle}\n >\n {fillType === 'bg-event' ?\n <BgEvent seg={seg} {...getSegMeta(seg, todayRange, nowDate)} /> :\n renderFill(fillType)}\n </div>\n )\n })\n\n return <Fragment>{children}</Fragment>\n }\n}\n","import {\n DateRange, intersectRanges, addMs, DateProfile, Slicer,\n DateProfileGenerator, DateEnv, DateMarker, Seg,\n} from '@fullcalendar/common'\nimport { normalizeRange, isValidDate, TimelineDateProfile } from './timeline-date-profile'\nimport { computeDateSnapCoverage } from './TimelineCoords'\n\nexport interface TimelineLaneSeg extends Seg {\n // the point of this range is because it might be different than seg.eventRange.range\n // because the date might have been rounded to the start of a week or a month\n start: DateMarker\n end: DateMarker\n}\n\nexport class TimelineLaneSlicer extends Slicer<\n TimelineLaneSeg,\n [DateProfile, DateProfileGenerator, TimelineDateProfile, DateEnv]\n> {\n sliceRange(\n origRange: DateRange,\n dateProfile: DateProfile,\n dateProfileGenerator: DateProfileGenerator,\n tDateProfile: TimelineDateProfile,\n dateEnv: DateEnv,\n ): TimelineLaneSeg[] {\n let normalRange = normalizeRange(origRange, tDateProfile, dateEnv)\n let segs: TimelineLaneSeg[] = []\n\n // protect against when the span is entirely in an invalid date region\n if (\n computeDateSnapCoverage(normalRange.start, tDateProfile, dateEnv)\n < computeDateSnapCoverage(normalRange.end, tDateProfile, dateEnv)\n ) {\n // intersect the footprint's range with the grid's range\n let slicedRange = intersectRanges(normalRange, tDateProfile.normalizedRange)\n\n if (slicedRange) {\n segs.push({\n start: slicedRange.start,\n end: slicedRange.end,\n isStart: slicedRange.start.valueOf() === normalRange.start.valueOf()\n && isValidDate(slicedRange.start, tDateProfile, dateProfile, dateProfileGenerator),\n isEnd: slicedRange.end.valueOf() === normalRange.end.valueOf()\n && isValidDate(addMs(slicedRange.end, -1), tDateProfile, dateProfile, dateProfileGenerator),\n })\n }\n }\n\n return segs\n }\n}\n","import { StandardEvent, MinimalEventProps, createElement, BaseComponent, createFormatter } from '@fullcalendar/common'\n\nexport interface TimelineEventProps extends MinimalEventProps {\n isTimeScale: boolean\n}\n\nconst DEFAULT_TIME_FORMAT = createFormatter({\n hour: 'numeric',\n minute: '2-digit',\n omitZeroMinute: true,\n meridiem: 'narrow',\n})\n\nexport class TimelineEvent extends BaseComponent<TimelineEventProps> {\n render() {\n let { props } = this\n\n return (\n <StandardEvent\n {...props}\n extraClassNames={['fc-timeline-event', 'fc-h-event']}\n defaultTimeFormat={DEFAULT_TIME_FORMAT}\n defaultDisplayEventTime={!props.isTimeScale}\n />\n )\n }\n}\n","import {\n createElement, BaseComponent, Ref, createRef, MoreLinkRoot,\n setRef, DateProfile, DateRange, DateMarker, Fragment, getSegMeta,\n} from '@fullcalendar/common'\nimport { TimelineSegPlacement } from './event-placement'\nimport { coordsToCss } from './TimelineCoords'\nimport { TimelineEvent } from './TimelineEvent'\nimport { TimelineLaneSeg } from './TimelineLaneSlicer'\n\nexport interface TimelineLaneMoreLinkProps {\n elRef: Ref<HTMLElement>\n hiddenSegs: TimelineLaneSeg[]\n placement: TimelineSegPlacement\n dateProfile: DateProfile\n nowDate: DateMarker\n todayRange: DateRange\n isTimeScale: boolean\n eventSelection: string\n resourceId?: string\n isForcedInvisible: { [instanceId: string]: any }\n}\n\nexport class TimelineLaneMoreLink extends BaseComponent<TimelineLaneMoreLinkProps> {\n rootElRef = createRef<HTMLElement>()\n\n render() {\n let { props, context } = this\n let { hiddenSegs, elRef, placement, resourceId } = props\n let { top, hcoords } = placement\n let isVisible = hcoords && top !== null\n let hStyle = coordsToCss(hcoords, context.isRtl)\n let extraDateSpan = resourceId ? { resourceId } : {}\n\n return (\n <MoreLinkRoot\n allDayDate={null}\n moreCnt={hiddenSegs.length}\n allSegs={hiddenSegs}\n hiddenSegs={hiddenSegs}\n alignmentElRef={this.rootElRef}\n dateProfile={props.dateProfile}\n todayRange={props.todayRange}\n extraDateSpan={extraDateSpan}\n popoverContent={() => (\n <Fragment>\n {hiddenSegs.map((seg) => {\n let instanceId = seg.eventRange.instance.instanceId\n return (\n <div\n key={instanceId}\n style={{ visibility: props.isForcedInvisible[instanceId] ? 'hidden' : ('' as any) }}\n >\n <TimelineEvent\n isTimeScale={props.isTimeScale}\n seg={seg}\n isDragging={false}\n isResizing={false}\n isDateSelecting={false}\n isSelected={instanceId === props.eventSelection}\n {...getSegMeta(seg, props.todayRange, props.nowDate)}\n />\n </div>\n )\n })}\n </Fragment>\n )}\n >\n {(rootElRef, classNames, innerElRef, innerContent, handleClick, title, isExpanded, popoverId) => (\n <a\n ref={(el: HTMLElement | null) => {\n setRef(rootElRef, el) // for MoreLinkRoot\n setRef(elRef, el) // for props props\n setRef(this.rootElRef, el) // for this component\n }}\n className={['fc-timeline-more-link'].concat(classNames).join(' ')}\n style={{\n visibility: isVisible ? ('' as any) : 'hidden',\n top: top || 0,\n ...hStyle,\n }}\n onClick={handleClick}\n title={title}\n aria-expanded={isExpanded}\n aria-controls={popoverId}\n >\n <div ref={innerElRef} className=\"fc-timeline-more-link-inner fc-sticky\">\n {innerContent}\n </div>\n </a>\n )}\n </MoreLinkRoot>\n )\n }\n}\n","import {\n Duration, EventStore, EventUiHash, DateSpan, EventInteractionState,\n BaseComponent, createElement, memoize, Fragment, RefMap, mapHash, createRef,\n getSegMeta, DateMarker, DateRange, DateProfile, sortEventSegs, isPropsEqual, buildIsoString,\n computeEarliestSegStart,\n} from '@fullcalendar/common'\nimport { TimelineDateProfile } from './timeline-date-profile'\nimport { coordsToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineLaneBg } from './TimelineLaneBg'\nimport { TimelineLaneSlicer, TimelineLaneSeg } from './TimelineLaneSlicer'\nimport { TimelineEvent } from './TimelineEvent'\nimport { TimelineLaneMoreLink } from './TimelineLaneMoreLink'\nimport { computeFgSegPlacements, computeSegHCoords, TimelineSegPlacement } from './event-placement'\n\nexport interface TimelineLaneProps extends TimelineLaneCoreProps {\n onHeightChange?: (innerEl: HTMLElement, isStable: boolean) => void\n}\n\nexport interface TimelineLaneCoreProps {\n nowDate: DateMarker\n todayRange: DateRange\n dateProfile: DateProfile\n tDateProfile: TimelineDateProfile\n nextDayThreshold: Duration\n businessHours: EventStore | null\n eventStore: EventStore | null\n eventUiBases: EventUiHash\n dateSelection: DateSpan | null\n eventSelection: string\n eventDrag: EventInteractionState | null\n eventResize: EventInteractionState | null\n timelineCoords: TimelineCoords | null // TODO: renamt to SLAT coords?\n resourceId?: string // hack\n syncParentMinHeight?: boolean // hack\n}\n\ninterface TimelineLaneState {\n eventInstanceHeights: { [instanceId: string]: number } // integers\n moreLinkHeights: { [isoStr: string]: number } // integers\n}\n\nexport class TimelineLane extends BaseComponent<TimelineLaneProps, TimelineLaneState> {\n private slicer = new TimelineLaneSlicer()\n private sortEventSegs = memoize(sortEventSegs)\n private harnessElRefs = new RefMap<HTMLDivElement>()\n private moreElRefs = new RefMap<HTMLDivElement>()\n private innerElRef = createRef<HTMLDivElement>()\n // TODO: memoize event positioning\n\n state: TimelineLaneState = {\n eventInstanceHeights: {},\n moreLinkHeights: {},\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let { dateProfile, tDateProfile } = props\n\n let slicedProps = this.slicer.sliceProps(\n props,\n dateProfile,\n tDateProfile.isTimeScale ? null : props.nextDayThreshold,\n context, // wish we didn't have to pass in the rest of the args...\n dateProfile,\n context.dateProfileGenerator,\n tDateProfile,\n context.dateEnv,\n )\n\n let mirrorSegs =\n (slicedProps.eventDrag ? slicedProps.eventDrag.segs as TimelineLaneSeg[] : null) ||\n (slicedProps.eventResize ? slicedProps.eventResize.segs as TimelineLaneSeg[] : null) ||\n []\n\n let fgSegs = this.sortEventSegs(slicedProps.fgEventSegs, options.eventOrder) as TimelineLaneSeg[]\n let fgSegHCoords = computeSegHCoords(fgSegs, options.eventMinWidth, props.timelineCoords)\n let [fgPlacements, fgHeight] = computeFgSegPlacements(\n fgSegs,\n fgSegHCoords,\n state.eventInstanceHeights,\n state.moreLinkHeights,\n options.eventOrderStrict,\n options.eventMaxStack,\n )\n\n let isForcedInvisible = // TODO: more convenient\n (slicedProps.eventDrag ? slicedProps.eventDrag.affectedInstances : null) ||\n (slicedProps.eventResize ? slicedProps.eventResize.affectedInstances : null) ||\n {}\n\n return (\n <Fragment>\n <TimelineLaneBg\n businessHourSegs={slicedProps.businessHourSegs}\n bgEventSegs={slicedProps.bgEventSegs}\n timelineCoords={props.timelineCoords}\n eventResizeSegs={slicedProps.eventResize ? slicedProps.eventResize.segs as TimelineLaneSeg[] : [] /* bad new empty array? */}\n dateSelectionSegs={slicedProps.dateSelectionSegs}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n />\n <div\n className=\"fc-timeline-events fc-scrollgrid-sync-inner\"\n ref={this.innerElRef}\n style={{ height: fgHeight }}\n >\n {this.renderFgSegs(\n fgPlacements,\n isForcedInvisible,\n false,\n false,\n false,\n )}\n {this.renderFgSegs(\n buildMirrorPlacements(mirrorSegs, props.timelineCoords, fgPlacements),\n {},\n Boolean(slicedProps.eventDrag),\n Boolean(slicedProps.eventResize),\n false, // because mirror is never drawn for date selection\n )}\n </div>\n </Fragment>\n )\n }\n\n componentDidMount() {\n this.updateSize()\n }\n\n componentDidUpdate(prevProps: TimelineLaneProps, prevState: TimelineLaneState) {\n if (\n prevProps.eventStore !== this.props.eventStore || // external thing changed?\n prevProps.timelineCoords !== this.props.timelineCoords || // external thing changed?\n prevState.moreLinkHeights !== this.state.moreLinkHeights // HACK. see addStateEquality\n ) {\n this.updateSize()\n }\n }\n\n updateSize() {\n let { props } = this\n let { timelineCoords } = props\n const innerEl = this.innerElRef.current\n\n if (props.onHeightChange) {\n props.onHeightChange(innerEl, false)\n }\n\n if (timelineCoords) {\n this.setState({\n eventInstanceHeights: mapHash(this.harnessElRefs.currentMap, (harnessEl) => (\n Math.round(harnessEl.getBoundingClientRect().height)\n )),\n moreLinkHeights: mapHash(this.moreElRefs.currentMap, (moreEl) => (\n Math.round(moreEl.getBoundingClientRect().height)\n )),\n }, () => {\n if (props.onHeightChange) {\n props.onHeightChange(innerEl, true)\n }\n })\n }\n\n // hack\n if (props.syncParentMinHeight) {\n innerEl.parentElement.style.minHeight = innerEl.style.height\n }\n }\n\n renderFgSegs(\n segPlacements: TimelineSegPlacement[],\n isForcedInvisible: { [instanceId: string]: any },\n isDragging: boolean,\n isResizing: boolean,\n isDateSelecting: boolean,\n ) {\n let { harnessElRefs, moreElRefs, props, context } = this\n let isMirror = isDragging || isResizing || isDateSelecting\n\n return (\n <Fragment>\n {segPlacements.map((segPlacement) => {\n let { seg, hcoords, top } = segPlacement\n\n if (Array.isArray(seg)) { // a more-link\n let isoStr = buildIsoString(computeEarliestSegStart(seg))\n return (\n <TimelineLaneMoreLink\n key={'m:' + isoStr /* \"m\" for \"more\" */}\n elRef={moreElRefs.createRef(isoStr)}\n hiddenSegs={seg}\n placement={segPlacement}\n dateProfile={props.dateProfile}\n nowDate={props.nowDate}\n todayRange={props.todayRange}\n isTimeScale={props.tDateProfile.isTimeScale}\n eventSelection={props.eventSelection}\n resourceId={props.resourceId}\n isForcedInvisible={isForcedInvisible}\n />\n )\n }\n\n let instanceId = seg.eventRange.instance.instanceId\n let isVisible = isMirror || Boolean(!isForcedInvisible[instanceId] && hcoords && top !== null)\n let hStyle = coordsToCss(hcoords, context.isRtl)\n\n return (\n <div\n key={'e:' + instanceId /* \"e\" for \"event\" */}\n ref={isMirror ? null : harnessElRefs.createRef(instanceId)}\n className=\"fc-timeline-event-harness\"\n style={{\n visibility: isVisible ? ('' as any) : 'hidden',\n top: top || 0,\n ...hStyle,\n }}\n >\n <TimelineEvent\n isTimeScale={props.tDateProfile.isTimeScale}\n seg={seg}\n isDragging={isDragging}\n isResizing={isResizing}\n isDateSelecting={isDateSelecting}\n isSelected={instanceId === props.eventSelection /* TODO: bad for mirror? */}\n {...getSegMeta(seg, props.todayRange, props.nowDate)}\n />\n </div>\n )\n })}\n </Fragment>\n )\n }\n}\n\nTimelineLane.addStateEquality({\n eventInstanceHeights: isPropsEqual,\n moreLinkHeights: isPropsEqual,\n})\n\nfunction buildMirrorPlacements(\n mirrorSegs: TimelineLaneSeg[],\n timelineCoords: TimelineCoords | null,\n fgPlacements: TimelineSegPlacement[],\n): TimelineSegPlacement[] {\n if (!mirrorSegs.length || !timelineCoords) {\n return []\n }\n let topsByInstanceId = buildAbsoluteTopHash(fgPlacements) // TODO: cache this at first render?\n return mirrorSegs.map((seg) => ({\n seg,\n hcoords: timelineCoords.rangeToCoords(seg),\n top: topsByInstanceId[seg.eventRange.instance.instanceId],\n }))\n}\n\nfunction buildAbsoluteTopHash(placements: TimelineSegPlacement[]) {\n let topsByInstanceId: { [instanceId: string]: number } = {}\n\n for (let placement of placements) {\n let { seg } = placement\n if (!Array.isArray(seg)) { // doesn't represent a more-link\n topsByInstanceId[seg.eventRange.instance.instanceId] = placement.top\n }\n }\n\n return topsByInstanceId\n}\n","import {\n createElement, createRef, ViewProps, Hit, DateComponent, CssDimValue, VNode, DateMarker, NowTimer,\n greatestDurationDenominator, DateRange, NowIndicatorRoot, Fragment,\n} from '@fullcalendar/common'\nimport { coordToCss, TimelineCoords } from './TimelineCoords'\nimport { TimelineSlats } from './TimelineSlats'\nimport { TimelineLane } from './TimelineLane'\nimport { TimelineDateProfile } from './timeline-date-profile'\n\nexport interface TimelinGridProps extends ViewProps {\n tDateProfile: TimelineDateProfile\n clientWidth: number | null\n clientHeight: number | null\n tableMinWidth: CssDimValue\n tableColGroupNode: VNode\n onSlatCoords?: (coords: TimelineCoords) => void\n onScrollLeftRequest?: (scrollLeft: number) => void\n}\n\ninterface TimelineGridState {\n coords: TimelineCoords | null\n}\n\nexport class TimelineGrid extends DateComponent<TimelinGridProps, TimelineGridState> {\n private slatsRef = createRef<TimelineSlats>()\n\n state: TimelineGridState = {\n coords: null,\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let { dateProfile, tDateProfile } = props\n let timerUnit = greatestDurationDenominator(tDateProfile.slotDuration).unit\n\n return (\n <div\n className=\"fc-timeline-body\"\n ref={this.handeEl}\n style={{\n minWidth: props.tableMinWidth,\n height: props.clientHeight,\n width: props.clientWidth,\n }}\n >\n <NowTimer unit={timerUnit}>\n {(nowDate: DateMarker, todayRange: DateRange) => (\n <Fragment>\n <TimelineSlats\n ref={this.slatsRef}\n dateProfile={dateProfile}\n tDateProfile={tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n clientWidth={props.clientWidth}\n tableColGroupNode={props.tableColGroupNode}\n tableMinWidth={props.tableMinWidth}\n onCoords={this.handleCoords}\n onScrollLeftRequest={props.onScrollLeftRequest}\n />\n <TimelineLane\n dateProfile={dateProfile}\n tDateProfile={props.tDateProfile}\n nowDate={nowDate}\n todayRange={todayRange}\n nextDayThreshold={options.nextDayThreshold}\n businessHours={props.businessHours}\n eventStore={props.eventStore}\n eventUiBases={props.eventUiBases}\n dateSelection={props.dateSelection}\n eventSelection={props.eventSelection}\n eventDrag={props.eventDrag}\n eventResize={props.eventResize}\n timelineCoords={state.coords}\n syncParentMinHeight\n />\n {(options.nowIndicator && state.coords && state.coords.isDateInRange(nowDate)) && (\n <div className=\"fc-timeline-now-indicator-container\">\n <NowIndicatorRoot isAxis={false} date={nowDate}>\n {(rootElRef, classNames, innerElRef, innerContent) => (\n <div\n ref={rootElRef}\n className={['fc-timeline-now-indicator-line'].concat(classNames).join(' ')}\n style={coordToCss(state.coords.dateToCoord(nowDate), context.isRtl)}\n >\n {innerContent}\n </div>\n )}\n </NowIndicatorRoot>\n </div>\n )}\n </Fragment>\n )}\n </NowTimer>\n </div>\n )\n }\n\n handeEl = (el: HTMLElement | null) => {\n if (el) {\n this.context.registerInteractiveComponent(this, { el })\n } else {\n this.context.unregisterInteractiveComponent(this)\n }\n }\n\n handleCoords = (coords: TimelineCoords) => {\n this.setState({ coords })\n\n if (this.props.onSlatCoords) {\n this.props.onSlatCoords(coords)\n }\n }\n\n // Hit System\n // ------------------------------------------------------------------------------------------\n\n queryHit(positionLeft: number, positionTop: number, elWidth: number, elHeight: number): Hit {\n let slats = this.slatsRef.current\n let slatHit = slats.positionToHit(positionLeft)\n\n if (slatHit) {\n return {\n dateProfile: this.props.dateProfile,\n dateSpan: slatHit.dateSpan,\n rect: {\n left: slatHit.left,\n right: slatHit.right,\n top: 0,\n bottom: elHeight,\n },\n dayEl: slatHit.dayEl,\n layer: 0,\n }\n }\n\n return null\n }\n}\n","import {\n createElement, ViewProps, memoize, ChunkContentCallbackArgs, createRef, ViewRoot,\n DateComponent, ScrollGridSectionConfig, renderScrollShim, getStickyHeaderDates, getStickyFooterScrollbar,\n} from '@fullcalendar/common'\nimport { ScrollGrid } from '@fullcalendar/scrollgrid'\nimport { buildTimelineDateProfile, TimelineDateProfile } from './timeline-date-profile'\nimport { TimelineHeader } from './TimelineHeader'\nimport { TimelineGrid } from './TimelineGrid'\nimport { TimelineCoords } from './TimelineCoords'\n\ninterface TimelineViewState {\n slatCoords: TimelineCoords | null\n slotCushionMaxWidth: number | null\n}\n\nexport class TimelineView extends DateComponent<ViewProps, TimelineViewState> { // would make this abstract, but TS complains\n private buildTimelineDateProfile = memoize(buildTimelineDateProfile)\n private scrollGridRef = createRef<ScrollGrid>()\n\n state = {\n slatCoords: null,\n slotCushionMaxWidth: null,\n }\n\n render() {\n let { props, state, context } = this\n let { options } = context\n let stickyHeaderDates = !props.forPrint && getStickyHeaderDates(options)\n let stickyFooterScrollbar = !props.forPrint && getStickyFooterScrollbar(options)\n\n let tDateProfile = this.buildTimelineDateProfile(\n props.dateProfile,\n context.dateEnv,\n options,\n context.dateProfileGenerator,\n )\n\n let extraClassNames = [\n 'fc-timeline',\n options.eventOverlap === false ? 'fc-timeline-overlap-disabled' : '',\n ]\n\n let { slotMinWidth } = options\n let slatCols = buildSlatCols(tDateProfile, slotMinWidth || this.computeFallbackSlotMinWidth(tDateProfile))\n\n let sections: ScrollGridSectionConfig[] = [\n {\n type: 'header',\n key: 'header',\n isSticky: stickyHeaderDates,\n chunks: [{\n key: 'timeline',\n content: (contentArg: ChunkContentCallbackArgs) => (\n <TimelineHeader\n dateProfile={props.dateProfile}\n clientWidth={contentArg.clientWidth}\n clientHeight={contentArg.clientHeight}\n tableMinWidth={contentArg.tableMinWidth}\n tableColGroupNode={contentArg.tableColGroupNode}\n tDateProfile={tDateProfile}\n slatCoords={state.slatCoords}\n onMaxCushionWidth={slotMinWidth ? null : this.handleMaxCushionWidth}\n />\n ),\n }],\n },\n {\n type: 'body',\n key: 'body',\n liquid: true,\n chunks: [{\n key: 'timeline',\n content: (contentArg: ChunkContentCallbackArgs) => (\n <TimelineGrid\n {...props}\n clientWidth={contentArg.clientWidth}\n clientHeight={contentArg.clientHeight}\n tableMinWidth={contentArg.tableMinWidth}\n tableColGroupNode={contentArg.tableColGroupNode}\n tDateProfile={tDateProfile}\n onSlatCoords={this.handleSlatCoords}\n onScrollLeftRequest={this.handleScrollLeftRequest}\n />\n ),\n }],\n },\n ]\n\n if (stickyFooterScrollbar) {\n sections.push({\n type: 'footer',\n key: 'footer',\n isSticky: true,\n chunks: [{\n key: 'timeline',\n content: renderScrollShim,\n }],\n })\n }\n\n return (\n <ViewRoot viewSpec={context.viewSpec}>\n {(rootElRef, classNames) => (\n <div ref={rootElRef} className={extraClassNames.concat(classNames).join(' ')}>\n <ScrollGrid\n ref={this.scrollGridRef}\n liquid={!props.isHeightAuto && !props.forPrint}\n collapsibleWidth={false}\n colGroups={[\n { cols: slatCols },\n ]}\n sections={sections}\n />\n </div>\n )}\n </ViewRoot>\n )\n }\n\n handleSlatCoords = (slatCoords: TimelineCoords | null) => {\n this.setState({ slatCoords })\n }\n\n handleScrollLeftRequest = (scrollLeft: number) => {\n let scrollGrid = this.scrollGridRef.current\n scrollGrid.forceScrollLeft(0, scrollLeft)\n }\n\n handleMaxCushionWidth = (slotCushionMaxWidth) => {\n this.setState({\n slotCushionMaxWidth: Math.ceil(slotCushionMaxWidth), // for less rerendering TODO: DRY\n })\n }\n\n computeFallbackSlotMinWidth(tDateProfile: TimelineDateProfile) { // TODO: duplicate definition\n return Math.max(30, ((this.state.slotCushionMaxWidth || 0) / tDateProfile.slotsPerLabel))\n }\n}\n\nexport function buildSlatCols(tDateProfile: TimelineDateProfile, slotMinWidth?: number) {\n return [{\n span: tDateProfile.slotCnt,\n minWidth: slotMinWidth || 1, // needs to be a non-zero number to trigger horizontal scrollbars!??????\n }]\n}\n","import { createPlugin } from '@fullcalendar/common'\n\nimport premiumCommonPlugin from '@fullcalendar/premium-common' // eslint-disable-line import/no-duplicates\n// ensure ambient declarations\nimport '@fullcalendar/premium-common' // eslint-disable-line import/no-duplicates\n\nimport { TimelineView } from './TimelineView'\nimport './main.css'\n\nexport { TimelineView }\nexport { buildSlatCols } from './TimelineView'\nexport { TimelineLane, TimelineLaneProps, TimelineLaneCoreProps } from './TimelineLane'\nexport { TimelineLaneBg } from './TimelineLaneBg'\nexport { TimelineHeader } from './TimelineHeader'\nexport { TimelineSlats } from './TimelineSlats'\nexport { TimelineDateProfile, buildTimelineDateProfile } from './timeline-date-profile'\nexport { TimelineCoords, coordToCss, coordsToCss } from './TimelineCoords'\nexport { TimelineLaneSlicer, TimelineLaneSeg } from './TimelineLaneSlicer'\nexport { TimelineHeaderRows } from './TimelineHeaderRows'\n\nexport default createPlugin({\n deps: [\n premiumCommonPlugin,\n ],\n initialView: 'timelineDay',\n views: {\n\n timeline: {\n component: TimelineView,\n usesMinMaxTime: true,\n eventResizableFromStart: true, // how is this consumed for TimelineView tho?\n },\n\n timelineDay: {\n type: 'timeline',\n duration: { days: 1 },\n },\n\n timelineWeek: {\n type: 'timeline',\n duration: { weeks: 1 },\n },\n\n timelineMonth: {\n type: 'timeline',\n duration: { months: 1 },\n },\n\n timelineYear: {\n type: 'timeline',\n duration: { years: 1 },\n },\n\n },\n})\n"],"names":[],"mappings":";;;;;;;;;;;;AAmCA,IAAM,eAAe,GAAG,EAAE,CAAA;AAC1B,IAAM,wBAAwB,GAAG,CAAC,CAAA;AAClC,IAAM,cAAc,GAAG,GAAG,CAAA;AAC1B,MAAM,CAAC,kB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;YAChB,QAAQ,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE;SACvB;KAEF;CACF,CAAC;;;;;"}
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@fullcalendar/timeline",
3
- "version": "5.11.2",
3
+ "version": "5.11.3",
4
4
  "title": "FullCalendar Timeline Plugin",
5
5
  "description": "Display events on a horizontal time axis (without resources)",
6
6
  "docs": "https://fullcalendar.io/docs/timeline-view-no-resources",
7
7
  "dependencies": {
8
- "@fullcalendar/common": "~5.11.2",
9
- "@fullcalendar/premium-common": "~5.11.2",
10
- "@fullcalendar/scrollgrid": "~5.11.2",
8
+ "@fullcalendar/common": "~5.11.3",
9
+ "@fullcalendar/premium-common": "~5.11.3",
10
+ "@fullcalendar/scrollgrid": "~5.11.3",
11
11
  "tslib": "^2.1.0"
12
12
  },
13
13
  "main": "main.cjs.js",
@@ -29,6 +29,6 @@
29
29
  "url": "http://arshaw.com/"
30
30
  },
31
31
  "devDependencies": {
32
- "@fullcalendar/core-preact": "5.11.2"
32
+ "@fullcalendar/core-preact": "5.11.3"
33
33
  }
34
34
  }