@fullcalendar/daygrid 7.0.0-beta.3 → 7.0.0-rc.0

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/internal.js CHANGED
@@ -1,4 +1,4 @@
1
- import { Slicer, createFormatter, getDateMeta, formatDayString, buildNavLinkAttrs, getDayClassName, addDays, getEventKey, BaseComponent, StandardEvent, buildEventRangeTimeText, getEventRangeAnchorAttrs, EventContainer, MoreLinkContainer, joinClassNames, getEventRangeMeta, DateComponent, DayCellContainer, hasCustomDayCellContent, watchSize, isDimsEqual, setRef, addMs, SegHierarchy, DaySeriesModel, DayTableModel, fracToCssDim, watchHeight, RefMap, afterSize, sortEventSegs, WeekNumberContainer, buildEventRangeKey, BgEvent, renderFill, memoize, getIsHeightAuto, watchWidth, ContentContainer, renderText, getStickyHeaderDates, Scroller, getStickyFooterScrollbar, StickyFooterScrollbar, getScrollerSyncerClass, ViewContainer, NowTimer, DateProfileGenerator, addWeeks, diffWeeks, injectStyles } from '@fullcalendar/core/internal.js';
1
+ import { Slicer, createFormatter, addDays, getDateMeta, buildDateStr, formatDayString, buildNavLinkAttrs, joinClassNames, getDayClassName, getEventKey, BaseComponent, StandardEvent, buildEventRangeTimeText, getEventTagAndAttrs, EventContainer, MoreLinkContainer, getEventRangeMeta, DateComponent, memoize, setRef, watchSize, isDimsEqual, hasCustomDayCellContent, DayCellContainer, addMs, SegHierarchy, DaySeriesModel, DayTableModel, fracToCssDim, watchHeight, RefMap, afterSize, sortEventSegs, WeekNumberContainer, buildEventRangeKey, BgEvent, renderFill, getIsHeightAuto, ContentContainer, renderText, getStickyHeaderDates, Scroller, Ruler, getStickyFooterScrollbar, FooterScrollbar, getScrollerSyncerClass, ViewContainer, NowTimer, DateProfileGenerator, addWeeks, diffWeeks, injectStyles } from '@fullcalendar/core/internal.js';
2
2
  import { createElement, Fragment, createRef, Component } from '@fullcalendar/core/preact.js';
3
3
 
4
4
  class DayTableSlicer extends Slicer {
@@ -28,10 +28,15 @@ Or ResourceApi object itself?
28
28
  function buildDateRowConfig(dates, datesRepDistinctDays, dateProfile, todayRange, dayHeaderFormat, // TODO: rename to dateHeaderFormat?
29
29
  context, colSpan) {
30
30
  return {
31
+ isDateRow: true,
31
32
  renderConfig: buildDateRenderConfig(context),
32
33
  dataConfigs: buildDateDataConfigs(dates, datesRepDistinctDays, dateProfile, todayRange, dayHeaderFormat, context, colSpan)
33
34
  };
34
35
  }
36
+ /*
37
+ For header cells: how to connect w/ custom rendering
38
+ Applies to all cells in a row
39
+ */
35
40
  function buildDateRenderConfig(context) {
36
41
  const { options } = context;
37
42
  return {
@@ -42,23 +47,38 @@ function buildDateRenderConfig(context) {
42
47
  willUnmount: options.dayHeaderWillUnmount,
43
48
  };
44
49
  }
50
+ const dowDates = [];
51
+ for (let dow = 0; dow < 7; dow++) {
52
+ dowDates.push(addDays(new Date(259200000), dow)); // start with Sun, 04 Jan 1970 00:00:00 GMT)
53
+ }
54
+ /*
55
+ For header cells: data
56
+ */
45
57
  function buildDateDataConfigs(dates, datesRepDistinctDays, dateProfile, todayRange, dayHeaderFormat, // TODO: rename to dateHeaderFormat?
46
- context, colSpan = 1, keyPrefix = '') {
58
+ context, colSpan = 1, keyPrefix = '', extraRenderProps = {}, // TODO
59
+ extraAttrs = {}, // TODO
60
+ className = '') {
47
61
  const { dateEnv, viewApi, options } = context;
48
62
  return datesRepDistinctDays
49
63
  ? dates.map((date) => {
50
64
  const dateMeta = getDateMeta(date, todayRange, null, dateProfile);
51
65
  const text = dateEnv.format(date, dayHeaderFormat);
52
- const renderProps = Object.assign(Object.assign({}, dateMeta), { date: dateEnv.toDate(date), view: viewApi, text });
53
- const isNavLink = options.navLinks && !dateMeta.isDisabled;
66
+ const renderProps = Object.assign(Object.assign(Object.assign({}, dateMeta), { date: dateEnv.toDate(date), view: viewApi, text }), extraRenderProps);
67
+ const isNavLink = options.navLinks && !dateMeta.isDisabled &&
68
+ dates.length > 1; // don't show navlink to day if only one day
69
+ const fullDateStr = buildDateStr(context, date);
70
+ // for DayGridHeaderCell
54
71
  return {
55
72
  key: keyPrefix + date.toUTCString(),
56
73
  renderProps,
57
- attrs: { 'data-date': !dateMeta.isDisabled ? formatDayString(date) : undefined },
58
- innerAttrs: isNavLink ? buildNavLinkAttrs(context, date) : {},
74
+ attrs: Object.assign(Object.assign(Object.assign({ 'aria-label': fullDateStr }, (dateMeta.isToday ? { 'aria-current': 'date' } : {})), { 'data-date': formatDayString(date) }), extraAttrs),
75
+ // for navlink
76
+ innerAttrs: isNavLink
77
+ ? buildNavLinkAttrs(context, date, undefined, fullDateStr)
78
+ : { 'aria-hidden': true },
59
79
  colSpan,
60
80
  isNavLink,
61
- className: getDayClassName(dateMeta),
81
+ className: joinClassNames(className, getDayClassName(dateMeta)),
62
82
  };
63
83
  })
64
84
  : dates.map((date) => {
@@ -73,13 +93,19 @@ context, colSpan = 1, keyPrefix = '') {
73
93
  isOther: false,
74
94
  };
75
95
  const text = dateEnv.format(normDate, dayHeaderFormat);
76
- const renderProps = Object.assign(Object.assign({}, dayMeta), { date, view: viewApi, text });
96
+ const renderProps = Object.assign(Object.assign(Object.assign({}, dayMeta), { date: dowDates[dow], view: viewApi, text }), extraRenderProps);
97
+ const fullWeekDayStr = dateEnv.format(normDate, WEEKDAY_FORMAT);
98
+ // for DayGridHeaderCell
77
99
  return {
78
100
  key: keyPrefix + String(dow),
79
101
  renderProps,
80
- innerAttrs: { 'aria-label': dateEnv.format(normDate, WEEKDAY_FORMAT) },
102
+ attrs: Object.assign({ 'aria-label': fullWeekDayStr }, extraAttrs),
103
+ // NOT a navlink
104
+ innerAttrs: {
105
+ 'aria-hidden': true, // label already on cell
106
+ },
81
107
  colSpan,
82
- className: getDayClassName(dayMeta),
108
+ className: joinClassNames(className, getDayClassName(dayMeta)),
83
109
  };
84
110
  });
85
111
  }
@@ -163,8 +189,8 @@ class DayGridListEvent extends BaseComponent {
163
189
  /* slicedStart = */ undefined,
164
190
  /* slicedEnd = */ undefined, props.isStart, props.isEnd, context,
165
191
  /* defaultDisplayEventTime = */ true, props.defaultDisplayEventEnd);
166
- let anchorAttrs = getEventRangeAnchorAttrs(eventRange, context);
167
- return (createElement(EventContainer, Object.assign({}, props, { tag: anchorAttrs ? 'a' : 'div', attrs: anchorAttrs, className: 'fc-daygrid-dot-event fc-daygrid-event', defaultGenerator: renderInnerContent, timeText: timeText, isResizing: false, isDateSelecting: false })));
192
+ let [tag, attrs] = getEventTagAndAttrs(eventRange, context);
193
+ return (createElement(EventContainer, Object.assign({}, props, { tag: tag, attrs: attrs, className: 'fc-daygrid-dot-event fc-daygrid-event', defaultGenerator: renderInnerContent, timeText: timeText, isResizing: false, isDateSelecting: false })));
168
194
  }
169
195
  }
170
196
  function renderInnerContent(renderProps) {
@@ -198,9 +224,34 @@ class DayGridMoreLink extends BaseComponent {
198
224
  class DayGridCell extends DateComponent {
199
225
  constructor() {
200
226
  super(...arguments);
227
+ // memo
228
+ this.getDateMeta = memoize(getDateMeta);
201
229
  // ref
202
230
  this.rootElRef = createRef();
203
- this.bodyElRef = createRef();
231
+ this.handleBodyEl = (bodyEl) => {
232
+ if (this.disconnectBodyHeight) {
233
+ this.disconnectBodyHeight();
234
+ this.disconnectBodyHeight = undefined;
235
+ setRef(this.props.headerHeightRef, null);
236
+ setRef(this.props.mainHeightRef, null);
237
+ }
238
+ if (bodyEl) {
239
+ // we want to fire on ANY size change, because we do more advanced stuff
240
+ this.disconnectBodyHeight = watchSize(bodyEl, (_bodyWidth, bodyHeight) => {
241
+ const { props } = this;
242
+ const mainRect = bodyEl.getBoundingClientRect();
243
+ const rootRect = this.rootElRef.current.getBoundingClientRect();
244
+ const headerHeight = mainRect.top - rootRect.top;
245
+ if (!isDimsEqual(this.headerHeight, headerHeight)) {
246
+ this.headerHeight = headerHeight;
247
+ setRef(props.headerHeightRef, headerHeight);
248
+ }
249
+ if (props.fgLiquidHeight) {
250
+ setRef(props.mainHeightRef, bodyHeight);
251
+ }
252
+ });
253
+ }
254
+ };
204
255
  }
205
256
  render() {
206
257
  let { props, context } = this;
@@ -208,38 +259,28 @@ class DayGridCell extends DateComponent {
208
259
  // TODO: memoize this
209
260
  const isMonthStart = props.showDayNumber &&
210
261
  shouldDisplayMonthStart(props.date, props.dateProfile.currentRange, dateEnv);
211
- return (createElement(DayCellContainer, { tag: "div", className: joinClassNames(props.className, 'fc-daygrid-day fc-flex-col', props.borderStart && 'fc-border-s', props.width != null ? '' : 'fc-liquid'), attrs: Object.assign(Object.assign({}, props.attrs), { role: 'gridcell' }), style: {
262
+ const dateMeta = this.getDateMeta(props.date, props.todayRange, null, props.dateProfile);
263
+ const baseClassName = joinClassNames('fc-daygrid-day', props.borderStart && 'fc-border-s', props.width != null ? '' : 'fc-liquid', 'fc-flex-col');
264
+ if (dateMeta.isDisabled) {
265
+ return (createElement("div", { role: 'gridcell', "aria-disabled": true, className: joinClassNames(baseClassName, 'fc-day-disabled'), style: {
266
+ width: props.width
267
+ } }));
268
+ }
269
+ const hasDayNumber = props.showDayNumber || hasCustomDayCellContent(options);
270
+ const isNavLink = options.navLinks;
271
+ const fullDateStr = buildDateStr(context, props.date);
272
+ return (createElement(DayCellContainer, { tag: "div", className: joinClassNames(baseClassName, props.className), attrs: Object.assign(Object.assign({}, props.attrs), { role: 'gridcell', 'aria-label': fullDateStr }), style: {
212
273
  width: props.width
213
- }, elRef: this.rootElRef, renderProps: props.renderProps, defaultGenerator: renderTopInner, date: props.date, dateProfile: props.dateProfile, todayRange: props.todayRange, showDayNumber: props.showDayNumber, isMonthStart: isMonthStart }, (InnerContent, renderProps) => (createElement(Fragment, null,
214
- !renderProps.isDisabled && (props.showDayNumber || hasCustomDayCellContent(options)) && (createElement("div", { className: "fc-daygrid-day-header" },
215
- createElement(InnerContent, { tag: "a", attrs: buildNavLinkAttrs(context, props.date), className: joinClassNames('fc-daygrid-day-number', isMonthStart && 'fc-daygrid-month-start') }))),
216
- createElement("div", { className: joinClassNames('fc-daygrid-day-body', props.isTall && 'fc-daygrid-day-body-tall', props.fgLiquidHeight ? 'fc-liquid' : 'fc-grow'), ref: this.bodyElRef },
274
+ }, elRef: this.rootElRef, renderProps: props.renderProps, defaultGenerator: renderTopInner, date: props.date, dateMeta: dateMeta, showDayNumber: props.showDayNumber, isMonthStart: isMonthStart }, (InnerContent) => (createElement(Fragment, null,
275
+ hasDayNumber && (createElement("div", { className: "fc-daygrid-day-header" },
276
+ createElement(InnerContent, { tag: 'div', attrs: isNavLink
277
+ ? buildNavLinkAttrs(context, props.date, undefined, fullDateStr)
278
+ : { 'aria-hidden': true } // label already on cell
279
+ , className: joinClassNames('fc-daygrid-day-number', isMonthStart && 'fc-daygrid-month-start') }))),
280
+ createElement("div", { className: joinClassNames('fc-daygrid-day-body', props.isTall && 'fc-daygrid-day-body-tall', props.fgLiquidHeight ? 'fc-liquid' : 'fc-grow'), ref: this.handleBodyEl },
217
281
  createElement("div", { className: 'fc-daygrid-day-events', style: { height: props.fgHeight } }, props.fg),
218
282
  createElement(DayGridMoreLink, { isBlock: props.isCompact, allDayDate: props.date, segs: props.segs, hiddenSegs: props.hiddenSegs, alignElRef: this.rootElRef, alignParentTop: props.showDayNumber ? '[role=row]' : '.fc-view', dateSpanProps: props.dateSpanProps, dateProfile: props.dateProfile, eventSelection: props.eventSelection, eventDrag: props.eventDrag, eventResize: props.eventResize, todayRange: props.todayRange }))))));
219
283
  }
220
- componentDidMount() {
221
- const bodyEl = this.bodyElRef.current;
222
- // we want to fire on ANY size change, because we do more advanced stuff
223
- this.disconnectBodyHeight = watchSize(bodyEl, (_bodyWidth, bodyHeight) => {
224
- const { props } = this;
225
- const mainRect = bodyEl.getBoundingClientRect();
226
- const rootRect = this.rootElRef.current.getBoundingClientRect();
227
- const headerHeight = mainRect.top - rootRect.top;
228
- if (!isDimsEqual(this.headerHeight, headerHeight)) {
229
- this.headerHeight = headerHeight;
230
- setRef(props.headerHeightRef, headerHeight);
231
- }
232
- if (props.fgLiquidHeight) {
233
- setRef(props.mainHeightRef, bodyHeight);
234
- }
235
- });
236
- }
237
- componentWillUnmount() {
238
- this.disconnectBodyHeight();
239
- const { props } = this;
240
- setRef(props.headerHeightRef, null);
241
- setRef(props.mainHeightRef, null);
242
- }
243
284
  }
244
285
  // Utils
245
286
  // -------------------------------------------------------------------------------------------------
@@ -467,10 +508,10 @@ function computeRowFromPosition(positionTop, cellRows, rowHeightMap) {
467
508
  // Hit Element
468
509
  // -------------------------------------------------------------------------------------------------
469
510
  function getRowEl(rootEl, row) {
470
- return rootEl.querySelectorAll(':scope > [role=row]')[row];
511
+ return rootEl.querySelectorAll('[role=row]')[row];
471
512
  }
472
513
  function getCellEl(rowEl, col) {
473
- return rowEl.querySelectorAll(':scope > [role=gridcell]')[col];
514
+ return rowEl.querySelectorAll('[role=gridcell]')[col];
474
515
  }
475
516
  // Header Formatting
476
517
  // -------------------------------------------------------------------------------------------------
@@ -563,14 +604,21 @@ class DayGridRow extends BaseComponent {
563
604
  (props.eventDrag && props.eventDrag.affectedInstances) ||
564
605
  (props.eventResize && props.eventResize.affectedInstances) ||
565
606
  {};
566
- return (createElement("div", { role: 'row' // TODO: audit this for all scenarios
567
- , className: joinClassNames('fc-flex-row fc-rel', props.className), style: {
568
- minHeight: props.minHeight,
607
+ const isNavLink = options.navLinks;
608
+ const fullWeekStr = buildDateStr(context, weekDate, 'week');
609
+ return (createElement("div", { role: props.role /* !!! */, "aria-label": props.role === 'row' // HACK
610
+ ? fullWeekStr
611
+ : undefined // can't have label on non-role div
612
+ , className: joinClassNames('fc-daygrid-row', props.forPrint && 'fc-daygrid-row-print', 'fc-flex-row fc-rel', props.className), style: {
613
+ 'flex-basis': props.basis,
569
614
  }, ref: this.handleRootEl },
615
+ props.showWeekNumbers && (createElement(WeekNumberContainer, { tag: 'div', attrs: Object.assign(Object.assign({}, (isNavLink
616
+ ? buildNavLinkAttrs(context, weekDate, 'week', fullWeekStr, /* isTabbable = */ false)
617
+ : {})), { 'role': undefined, 'aria-hidden': true }), className: 'fc-daygrid-week-number', date: weekDate, defaultFormat: DEFAULT_WEEK_NUM_FORMAT })),
570
618
  this.renderFillSegs(props.businessHourSegs, 'non-business'),
571
619
  this.renderFillSegs(props.bgEventSegs, 'bg-event'),
572
620
  this.renderFillSegs(highlightSegs, 'highlight'),
573
- createElement("div", { className: 'fc-flex-row fc-liquid fc-rel' }, props.cells.map((cell, col) => {
621
+ props.cells.map((cell, col) => {
574
622
  const normalFgNodes = this.renderFgSegs(maxMainTop, renderableSegsByCol[col], segTops, props.todayRange, forcedInvisibleMap);
575
623
  return (createElement(DayGridCell, { key: cell.key, dateProfile: props.dateProfile, todayRange: props.todayRange, date: cell.date, showDayNumber: props.showDayNumbers, isCompact: props.isCompact, isTall: props.isTall, borderStart: Boolean(col),
576
624
  // content
@@ -581,8 +629,7 @@ class DayGridRow extends BaseComponent {
581
629
  fgHeight: heightsByCol[col], width: props.colWidth,
582
630
  // refs
583
631
  headerHeightRef: headerHeightRefMap.createRef(cell.key), mainHeightRef: mainHeightRefMap.createRef(cell.key) }));
584
- })),
585
- props.showWeekNumbers && (createElement(WeekNumberContainer, { tag: "a", attrs: buildNavLinkAttrs(context, weekDate, 'week'), className: 'fc-daygrid-week-number', date: weekDate, defaultFormat: DEFAULT_WEEK_NUM_FORMAT })),
632
+ }),
586
633
  this.renderFgSegs(maxMainTop, mirrorSegs, segTops, props.todayRange, {}, // forcedInvisibleMap
587
634
  Boolean(props.eventDrag), Boolean(props.eventResize), false)));
588
635
  }
@@ -742,30 +789,22 @@ class DayGridRows extends DateComponent {
742
789
  let eventResizeByRow = this.splitEventResize(props.eventResize, rowCnt);
743
790
  let isHeightAuto = getIsHeightAuto(options);
744
791
  let rowHeightsRedistribute = !props.forPrint && !isHeightAuto;
745
- let [rowMinHeight, isCompact] = computeRowHeight(props.visibleWidth, rowCnt, isHeightAuto, props.forPrint, options);
746
- return (createElement("div", { className: joinClassNames(
792
+ let rowBasis = computeRowBasis(props.visibleWidth, rowCnt, isHeightAuto, options);
793
+ let isCompact = computeRowIsCompact(props.visibleWidth, options);
794
+ return (createElement("div", { role: 'rowgroup', className: joinClassNames(
747
795
  // HACK for Safari. Can't do break-inside:avoid with flexbox items, likely b/c it's not standard:
748
796
  // https://stackoverflow.com/a/60256345
749
- !props.forPrint && 'fc-flex-col', props.className), style: { width: props.width }, ref: this.handleRootEl }, props.cellRows.map((cells, row) => (createElement(DayGridRow, { key: cells[0].key, dateProfile: props.dateProfile, todayRange: props.todayRange, cells: cells, showDayNumbers: rowCnt > 1, showWeekNumbers: options.weekNumbers, forPrint: props.forPrint, isCompact: isCompact,
797
+ !props.forPrint && 'fc-flex-col', props.className), style: { width: props.width }, ref: this.handleRootEl }, props.cellRows.map((cells, row) => (createElement(DayGridRow, { key: cells[0].key, role: 'row', dateProfile: props.dateProfile, todayRange: props.todayRange, cells: cells, showDayNumbers: rowCnt > 1, showWeekNumbers: rowCnt > 1 && options.weekNumbers, forPrint: props.forPrint, isCompact: isCompact,
750
798
  // if not auto-height, distribute height of container somewhat evently to rows
751
- // (treat all as zero, distribute height, then ensure min-heights -- the inner content height)
752
- className: joinClassNames(rowHeightsRedistribute && 'fc-grow fc-basis0', rowCnt > 1 && 'fc-break-inside-avoid', // don't avoid breaks for single tall row
799
+ className: joinClassNames(rowHeightsRedistribute && 'fc-grow', rowCnt > 1 && 'fc-break-inside-avoid', // don't avoid breaks for single tall row
753
800
  row < rowCnt - 1 && 'fc-border-b'),
754
801
  // content
755
802
  fgEventSegs: fgEventSegsByRow[row], bgEventSegs: bgEventSegsByRow[row].filter(isSegAllDay) /* HACK */, businessHourSegs: businessHourSegsByRow[row], dateSelectionSegs: dateSelectionSegsByRow[row], eventSelection: props.eventSelection, eventDrag: eventDragByRow[row], eventResize: eventResizeByRow[row], dayMaxEvents: props.dayMaxEvents, dayMaxEventRows: props.dayMaxEventRows,
756
803
  // dimensions
757
- colWidth: props.colWidth, minHeight: rowMinHeight,
804
+ colWidth: props.colWidth, basis: rowBasis,
758
805
  // refs
759
806
  heightRef: rowHeightRefMap.createRef(cells[0].key) })))));
760
807
  }
761
- componentDidMount() {
762
- this.disconnectWidth = watchWidth(this.rootEl, (width) => {
763
- this.setState({ width });
764
- });
765
- }
766
- componentWillUnmount() {
767
- this.disconnectWidth();
768
- }
769
808
  // Hit System
770
809
  // -----------------------------------------------------------------------------------------------
771
810
  queryHit(positionLeft, positionTop, elWidth) {
@@ -782,8 +821,7 @@ class DayGridRows extends DateComponent {
782
821
  start: cellStartDate,
783
822
  end: cellEndDate,
784
823
  }, allDay: true }, cell.dateSpanProps),
785
- // HACK. TODO: This is expensive to do every hit-query
786
- dayEl: getCellEl(getRowEl(this.rootEl, row), col),
824
+ getDayEl: () => getCellEl(getRowEl(this.rootEl, row), col),
787
825
  rect: {
788
826
  left,
789
827
  right,
@@ -799,27 +837,35 @@ class DayGridRows extends DateComponent {
799
837
  function isSegAllDay(seg) {
800
838
  return seg.eventRange.def.allDay;
801
839
  }
802
- function computeRowHeight(visibleWidth, // should INCLUDE any scrollbar width to avoid oscillation
803
- rowCnt, isHeightAuto, forPrint, options) {
840
+ /*
841
+ Amount of height a row should consume prior to expanding
842
+ We don't want to use min-height with flexbox because we leverage min-height:auto,
843
+ which yields value based on natural height of events
844
+ */
845
+ function computeRowBasis(visibleWidth, // should INCLUDE any scrollbar width to avoid oscillation
846
+ rowCnt, isHeightAuto, options) {
804
847
  if (visibleWidth != null) {
805
848
  // ensure a consistent row min-height modelled after a month with 6 rows respecting aspectRatio
806
849
  // will result in same minHeight regardless of weekends, dayMinWidth, height:auto
807
- const rowMinHeight = visibleWidth / options.aspectRatio / 6;
808
- return [
809
- forPrint
810
- // special-case for print, which condenses whole-page width without notifying
811
- // this is value that looks natural on paper for portrait/landscape
812
- ? '6em'
813
- // don't give minHeight when single-month non-auto-height
814
- // TODO: better way to detect this with DateProfile?
815
- : (rowCnt > 6 || isHeightAuto)
816
- ? rowMinHeight
817
- : undefined,
818
- // isCompact?: just before most lone +more links hit bottom of cell
819
- rowMinHeight < 70,
820
- ];
850
+ const rowBasis = visibleWidth / options.aspectRatio / 6;
851
+ // don't give minHeight when single-month non-auto-height
852
+ // TODO: better way to detect this with DateProfile?
853
+ return (rowCnt > 6 || isHeightAuto) ? rowBasis : 0;
821
854
  }
822
- return [undefined, false];
855
+ return 0;
856
+ }
857
+ /*
858
+ Infers cell height based on overall width
859
+ */
860
+ function computeRowIsCompact(visibleWidth, // should INCLUDE any scrollbar width to avoid oscillation
861
+ options) {
862
+ if (visibleWidth != null) {
863
+ // ensure a consistent row min-height modelled after a month with 6 rows respecting aspectRatio
864
+ // will result in same minHeight regardless of weekends, dayMinWidth, height:auto
865
+ const rowBasis = visibleWidth / options.aspectRatio / 6;
866
+ return rowBasis < 70;
867
+ }
868
+ return false;
823
869
  }
824
870
 
825
871
  class DayGridHeaderCell extends BaseComponent {
@@ -843,14 +889,16 @@ class DayGridHeaderCell extends BaseComponent {
843
889
  render() {
844
890
  const { props } = this;
845
891
  const { renderConfig, dataConfig } = props;
846
- return (createElement(ContentContainer, { tag: 'div', attrs: dataConfig.attrs, className: joinClassNames(dataConfig.className, 'fc-header-cell fc-cell fc-flex-col fc-align-center', props.borderStart && 'fc-border-s', !props.isSticky && 'fc-crop', props.colWidth == null && 'fc-liquid'), style: {
892
+ // HACK
893
+ const isDisabled = dataConfig.renderProps.isDisabled;
894
+ return (createElement(ContentContainer, { tag: 'div', attrs: Object.assign({ role: 'columnheader', 'aria-colspan': dataConfig.colSpan }, dataConfig.attrs), className: joinClassNames('fc-header-cell fc-cell fc-flex-col fc-align-center', props.borderStart && 'fc-border-s', !props.isSticky && 'fc-crop', props.colWidth == null && 'fc-liquid', dataConfig.className), style: {
847
895
  width: props.colWidth != null
848
896
  ? props.colWidth * (dataConfig.colSpan || 1)
849
897
  : undefined,
850
898
  }, renderProps: dataConfig.renderProps, generatorName: renderConfig.generatorName, customGenerator: renderConfig.customGenerator, defaultGenerator: renderText, classNameGenerator:
851
899
  // don't use custom classNames if disabled
852
900
  // TODO: make DRY with DayCellContainer
853
- dataConfig.renderProps.isDisabled ? undefined : renderConfig.classNameGenerator, didMount: renderConfig.didMount, willUnmount: renderConfig.willUnmount }, (InnerContainer) => (!dataConfig.renderProps.isDisabled && (createElement(InnerContainer, { tag: dataConfig.isNavLink ? 'a' : 'div', attrs: dataConfig.innerAttrs, className: joinClassNames('fc-cell-inner fc-flex-col fc-padding-sm', props.isSticky && 'fc-sticky-s'), elRef: this.handleInnerEl })))));
901
+ isDisabled ? undefined : renderConfig.classNameGenerator, didMount: renderConfig.didMount, willUnmount: renderConfig.willUnmount }, (InnerContainer) => (createElement(InnerContainer, { tag: 'div', attrs: dataConfig.innerAttrs, className: joinClassNames('fc-cell-inner fc-flex-col fc-padding-sm', props.isSticky && 'fc-sticky-s'), elRef: this.handleInnerEl }))));
854
902
  }
855
903
  }
856
904
 
@@ -875,7 +923,10 @@ class DayGridHeaderRow extends BaseComponent {
875
923
  }
876
924
  render() {
877
925
  const { props } = this;
878
- return (createElement("div", { role: 'row', className: joinClassNames('fc-flex-row fc-content-box', props.className), style: { height: props.height } }, props.dataConfigs.map((dataConfig, cellI) => (createElement(DayGridHeaderCell, { key: dataConfig.key, renderConfig: props.renderConfig, dataConfig: dataConfig, isSticky: props.isSticky, borderStart: Boolean(cellI), colWidth: props.colWidth, innerHeightRef: props.innerHeightRef })))));
926
+ return (createElement("div", { role: props.role /* !!! */, "aria-rowindex": props.rowIndex != null ? 1 + props.rowIndex : undefined, className: joinClassNames('fc-flex-row fc-content-box', props.className), style: { height: props.height } }, props.dataConfigs.map((dataConfig, cellI) => (createElement(DayGridHeaderCell, { key: dataConfig.key, renderConfig: props.renderConfig, dataConfig: dataConfig, isSticky: props.isSticky, borderStart: Boolean(cellI), colWidth: props.colWidth, innerHeightRef: props.innerHeightRef })))));
927
+ }
928
+ componentWillUnmount() {
929
+ setRef(this.props.innerHeightRef, null);
879
930
  }
880
931
  }
881
932
 
@@ -885,9 +936,9 @@ TODO: kill this class in favor of DayGridHeaderRows?
885
936
  class DayGridHeader extends BaseComponent {
886
937
  render() {
887
938
  const { props } = this;
888
- return (createElement("div", { className: joinClassNames(props.className, 'fc-flex-col', props.width == null && 'fc-liquid'), style: {
939
+ return (createElement("div", { role: 'rowgroup', className: joinClassNames(props.className, 'fc-flex-col', props.width == null && 'fc-liquid'), style: {
889
940
  width: props.width
890
- } }, props.headerTiers.map((rowConfig, tierNum) => (createElement(DayGridHeaderRow, Object.assign({}, rowConfig, { key: tierNum, className: tierNum ? 'fc-border-t' : '', colWidth: props.colWidth }))))));
941
+ } }, props.headerTiers.map((rowConfig, tierNum) => (createElement(DayGridHeaderRow, Object.assign({}, rowConfig, { key: tierNum, role: 'row', className: tierNum ? 'fc-border-t' : '', colWidth: props.colWidth }))))));
891
942
  }
892
943
  }
893
944
 
@@ -897,37 +948,39 @@ class DayGridLayoutNormal extends BaseComponent {
897
948
  this.handleScroller = (scroller) => {
898
949
  setRef(this.props.scrollerRef, scroller);
899
950
  };
951
+ this.handleTotalWidth = (totalWidth) => {
952
+ this.setState({ totalWidth });
953
+ };
900
954
  this.handleClientWidth = (clientWidth) => {
901
955
  this.setState({ clientWidth });
902
956
  };
903
- this.handleEndScrollbarWidth = (endScrollbarWidth) => {
904
- this.setState({ endScrollbarWidth });
905
- };
906
957
  }
907
958
  render() {
908
959
  const { props, state, context } = this;
909
960
  const { options } = context;
961
+ const { totalWidth, clientWidth } = state;
962
+ const endScrollbarWidth = (totalWidth != null && clientWidth != null)
963
+ ? totalWidth - clientWidth
964
+ : undefined;
910
965
  const verticalScrollbars = !props.forPrint && !getIsHeightAuto(options);
911
966
  const stickyHeaderDates = !props.forPrint && getStickyHeaderDates(options);
912
967
  return (createElement(Fragment, null,
913
968
  options.dayHeaders && (createElement("div", { className: joinClassNames(props.forPrint ? 'fc-print-header' : 'fc-flex-row', // col for print, row for screen
914
- 'fc-border-b') },
915
- createElement(DayGridHeader, { headerTiers: props.headerTiers, className: joinClassNames('fc-daygrid-header', stickyHeaderDates && 'fc-table-header-sticky') }),
916
- Boolean(state.endScrollbarWidth) && (createElement("div", { className: 'fc-border-s fc-filler', style: { minWidth: state.endScrollbarWidth } })))),
917
- createElement(Scroller, { vertical: verticalScrollbars, clientWidthRef: this.handleClientWidth, endScrollbarWidthRef: this.handleEndScrollbarWidth, className: joinClassNames('fc-daygrid-body',
969
+ stickyHeaderDates && 'fc-table-header-sticky', 'fc-border-b') },
970
+ createElement(DayGridHeader, { headerTiers: props.headerTiers, className: 'fc-daygrid-header' }),
971
+ Boolean(endScrollbarWidth) && (createElement("div", { className: 'fc-border-s fc-filler', style: { minWidth: endScrollbarWidth } })))),
972
+ createElement(Scroller, { vertical: verticalScrollbars, className: joinClassNames('fc-daygrid-body',
918
973
  // HACK for Safari. Can't do break-inside:avoid with flexbox items, likely b/c it's not standard:
919
974
  // https://stackoverflow.com/a/60256345
920
- !props.forPrint && 'fc-flex-col', verticalScrollbars && 'fc-liquid'), ref: this.handleScroller },
975
+ !props.forPrint && 'fc-flex-col', verticalScrollbars && 'fc-liquid'), ref: this.handleScroller, clientWidthRef: this.handleClientWidth },
921
976
  createElement(DayGridRows, { dateProfile: props.dateProfile, todayRange: props.todayRange, cellRows: props.cellRows, forPrint: props.forPrint, isHitComboAllowed: props.isHitComboAllowed, className: 'fc-grow', dayMaxEvents: props.forPrint ? undefined : options.dayMaxEvents, dayMaxEventRows: options.dayMaxEventRows,
922
977
  // content
923
978
  fgEventSegs: props.fgEventSegs, bgEventSegs: props.bgEventSegs, businessHourSegs: props.businessHourSegs, dateSelectionSegs: props.dateSelectionSegs, eventDrag: props.eventDrag, eventResize: props.eventResize, eventSelection: props.eventSelection,
924
979
  // dimensions
925
- visibleWidth: // TODO: DRY
926
- state.clientWidth != null && state.endScrollbarWidth != null
927
- ? state.clientWidth + state.endScrollbarWidth
928
- : undefined,
980
+ visibleWidth: totalWidth,
929
981
  // refs
930
- rowHeightRefMap: props.rowHeightRefMap }))));
982
+ rowHeightRefMap: props.rowHeightRefMap })),
983
+ createElement(Ruler, { widthRef: this.handleTotalWidth })));
931
984
  }
932
985
  }
933
986
 
@@ -939,43 +992,45 @@ class DayGridLayoutPannable extends BaseComponent {
939
992
  this.footerScrollerRef = createRef();
940
993
  // Sizing
941
994
  // -----------------------------------------------------------------------------------------------
995
+ this.handleTotalWidth = (totalWidth) => {
996
+ this.setState({ totalWidth });
997
+ };
942
998
  this.handleClientWidth = (clientWidth) => {
943
999
  this.setState({ clientWidth });
944
1000
  };
945
- this.handleEndScrollbarWidth = (endScrollbarWidth) => {
946
- this.setState({ endScrollbarWidth });
947
- };
948
1001
  }
949
1002
  render() {
950
1003
  const { props, state, context } = this;
951
1004
  const { options } = context;
1005
+ const { totalWidth, clientWidth } = state;
1006
+ const endScrollbarWidth = (totalWidth != null && clientWidth != null)
1007
+ ? totalWidth - clientWidth
1008
+ : undefined;
952
1009
  const verticalScrollbars = !props.forPrint && !getIsHeightAuto(options);
953
1010
  const stickyHeaderDates = !props.forPrint && getStickyHeaderDates(options);
954
1011
  const stickyFooterScrollbar = !props.forPrint && getStickyFooterScrollbar(options);
955
1012
  const colCnt = props.cellRows[0].length;
956
- const [canvasWidth, colWidth] = computeColWidth(colCnt, props.dayMinWidth, state.clientWidth);
1013
+ const [canvasWidth, colWidth] = computeColWidth(colCnt, props.dayMinWidth, clientWidth);
957
1014
  return (createElement(Fragment, null,
958
- options.dayHeaders && (createElement("div", { className: 'fc-print-header' },
959
- createElement(Scroller, { horizontal: true, hideScrollbars: true, className: joinClassNames('fc-daygrid-header fc-flex-row fc-border-b', stickyHeaderDates && 'fc-table-header-sticky'), ref: this.headerScrollerRef },
1015
+ options.dayHeaders && (createElement("div", { className: joinClassNames('fc-print-header', stickyHeaderDates && 'fc-table-header-sticky') },
1016
+ createElement(Scroller, { horizontal: true, hideScrollbars: true, className: 'fc-daygrid-header fc-flex-row fc-border-b', ref: this.headerScrollerRef },
960
1017
  createElement(DayGridHeader, { headerTiers: props.headerTiers, colWidth: colWidth, width: canvasWidth }),
961
- Boolean(state.endScrollbarWidth) && (createElement("div", { className: 'fc-border-s fc-filler', style: { minWidth: state.endScrollbarWidth } }))))),
1018
+ Boolean(endScrollbarWidth) && (createElement("div", { className: 'fc-border-s fc-filler', style: { minWidth: endScrollbarWidth } }))))),
962
1019
  createElement(Scroller, { vertical: verticalScrollbars, horizontal: true, hideScrollbars: stickyFooterScrollbar ||
963
1020
  props.forPrint // prevents blank space in print-view on Safari
964
1021
  , className: joinClassNames('fc-daygrid-body',
965
1022
  // HACK for Safari. Can't do break-inside:avoid with flexbox items, likely b/c it's not standard:
966
1023
  // https://stackoverflow.com/a/60256345
967
- !props.forPrint && 'fc-flex-col', verticalScrollbars && 'fc-liquid'), ref: this.bodyScrollerRef, clientWidthRef: this.handleClientWidth, endScrollbarWidthRef: this.handleEndScrollbarWidth },
1024
+ !props.forPrint && 'fc-flex-col', verticalScrollbars && 'fc-liquid'), ref: this.bodyScrollerRef, clientWidthRef: this.handleClientWidth },
968
1025
  createElement(DayGridRows, { dateProfile: props.dateProfile, todayRange: props.todayRange, cellRows: props.cellRows, forPrint: props.forPrint, isHitComboAllowed: props.isHitComboAllowed, className: 'fc-grow', dayMaxEvents: props.forPrint ? undefined : options.dayMaxEvents, dayMaxEventRows: options.dayMaxEventRows,
969
1026
  // content
970
1027
  fgEventSegs: props.fgEventSegs, bgEventSegs: props.bgEventSegs, businessHourSegs: props.businessHourSegs, dateSelectionSegs: props.dateSelectionSegs, eventDrag: props.eventDrag, eventResize: props.eventResize, eventSelection: props.eventSelection,
971
1028
  // dimensions
972
- colWidth: colWidth, width: canvasWidth, visibleWidth: // TODO: DRY
973
- state.clientWidth != null && state.endScrollbarWidth != null
974
- ? state.clientWidth + state.endScrollbarWidth
975
- : undefined,
1029
+ colWidth: colWidth, width: canvasWidth, visibleWidth: totalWidth,
976
1030
  // refs
977
1031
  rowHeightRefMap: props.rowHeightRefMap })),
978
- Boolean(stickyFooterScrollbar) && (createElement(StickyFooterScrollbar, { canvasWidth: canvasWidth, scrollerRef: this.footerScrollerRef }))));
1032
+ Boolean(stickyFooterScrollbar) && (createElement(FooterScrollbar, { isSticky: true, canvasWidth: canvasWidth, scrollerRef: this.footerScrollerRef })),
1033
+ createElement(Ruler, { widthRef: this.handleTotalWidth })));
979
1034
  }
980
1035
  // Lifecycle
981
1036
  // -----------------------------------------------------------------------------------------------
@@ -1030,21 +1085,29 @@ class DayGridLayout extends BaseComponent {
1030
1085
  }
1031
1086
  }
1032
1087
  };
1033
- this.clearScroll = () => {
1034
- this.scrollDate = null;
1088
+ this.handleScrollEnd = (isUser) => {
1089
+ if (isUser) {
1090
+ this.scrollDate = null;
1091
+ }
1035
1092
  };
1036
1093
  }
1037
1094
  render() {
1038
1095
  const { props, context } = this;
1039
1096
  const { options } = context;
1040
1097
  const commonLayoutProps = Object.assign(Object.assign({}, props), { scrollerRef: this.scrollerRef, rowHeightRefMap: this.rowHeightRefMap });
1041
- return (createElement(ViewContainer, { viewSpec: context.viewSpec, className: joinClassNames(props.className, 'fc-print-root fc-border') }, options.dayMinWidth ? (createElement(DayGridLayoutPannable, Object.assign({}, commonLayoutProps, { dayMinWidth: options.dayMinWidth }))) : (createElement(DayGridLayoutNormal, Object.assign({}, commonLayoutProps)))));
1098
+ return (createElement(ViewContainer, { viewSpec: context.viewSpec, attrs: {
1099
+ role: 'grid',
1100
+ 'aria-rowcount': props.headerTiers.length + props.cellRows.length,
1101
+ 'aria-colcount': props.cellRows[0].length,
1102
+ 'aria-labelledby': props.labelId,
1103
+ 'aria-label': props.labelStr,
1104
+ }, className: joinClassNames(props.className, 'fc-print-root fc-border') }, options.dayMinWidth ? (createElement(DayGridLayoutPannable, Object.assign({}, commonLayoutProps, { dayMinWidth: options.dayMinWidth }))) : (createElement(DayGridLayoutNormal, Object.assign({}, commonLayoutProps)))));
1042
1105
  }
1043
1106
  // Lifecycle
1044
1107
  // -----------------------------------------------------------------------------------------------
1045
1108
  componentDidMount() {
1046
1109
  this.resetScroll();
1047
- this.scrollerRef.current.addScrollEndListener(this.clearScroll);
1110
+ this.scrollerRef.current.addScrollEndListener(this.handleScrollEnd);
1048
1111
  }
1049
1112
  componentDidUpdate(prevProps) {
1050
1113
  if (prevProps.dateProfile !== this.props.dateProfile && this.context.options.scrollTimeReset) {
@@ -1052,14 +1115,13 @@ class DayGridLayout extends BaseComponent {
1052
1115
  }
1053
1116
  }
1054
1117
  componentWillUnmount() {
1055
- this.scrollerRef.current.removeScrollEndListener(this.clearScroll);
1118
+ this.scrollerRef.current.removeScrollEndListener(this.handleScrollEnd);
1056
1119
  }
1057
1120
  // Scrolling
1058
1121
  // -----------------------------------------------------------------------------------------------
1059
1122
  resetScroll() {
1060
1123
  this.scrollDate = this.props.dateProfile.currentDate;
1061
1124
  this.updateScrollY();
1062
- // updateScrollX
1063
1125
  const scroller = this.scrollerRef.current;
1064
1126
  scroller.scrollTo({ x: 0 });
1065
1127
  }
@@ -1084,7 +1146,7 @@ class DayGridView extends BaseComponent {
1084
1146
  const slicedProps = this.slicer.sliceProps(props, props.dateProfile, options.nextDayThreshold, context, dayTableModel);
1085
1147
  return (createElement(NowTimer, { unit: "day" }, (nowDate, todayRange) => {
1086
1148
  const headerTiers = this.buildDateRowConfigs(dayTableModel.headerDates, datesRepDistinctDays, props.dateProfile, todayRange, dayHeaderFormat, context);
1087
- return (createElement(DayGridLayout, { dateProfile: props.dateProfile, todayRange: todayRange, cellRows: dayTableModel.cellRows, forPrint: props.forPrint, className: 'fc-daygrid',
1149
+ return (createElement(DayGridLayout, { labelId: props.labelId, labelStr: props.labelStr, dateProfile: props.dateProfile, todayRange: todayRange, cellRows: dayTableModel.cellRows, forPrint: props.forPrint, className: 'fc-daygrid',
1088
1150
  // header content
1089
1151
  headerTiers: headerTiers,
1090
1152
  // body content
@@ -1131,7 +1193,7 @@ function buildDayTableRenderRange(props) {
1131
1193
  return { start, end };
1132
1194
  }
1133
1195
 
1134
- var css_248z = ":root{--fc-daygrid-event-dot-width:8px}.fc-daygrid-day.fc-day-today{background-color:var(--fc-today-bg-color)}.fc-daygrid-day-header{display:flex;flex-direction:row-reverse}.fc-day-other .fc-daygrid-day-header{opacity:.3}.fc-daygrid-day-number{padding:4px;position:relative}.fc-daygrid-month-start{font-size:1.1em;font-weight:700}.fc-daygrid-day-body{display:flex;flex-direction:column;margin-bottom:1px}.fc-daygrid-day-body-tall{margin-bottom:1em;min-height:2em}.fc-daygrid-day-body:only-child{margin-top:2px}.fc-daygrid-more-link{border-radius:3px;cursor:pointer;font-size:var(--fc-small-font-size);margin:0 2px 1px;max-width:100%;overflow:hidden;padding:2px;position:relative;white-space:nowrap}.fc-daygrid-more-link:hover{background-color:rgba(0,0,0,.1)}.fc-daygrid-more-link-button{align-self:flex-start}.fc-daygrid-more-link-block{border:1px solid var(--fc-event-border-color);padding:1px}.fc-daygrid-week-number{background-color:var(--fc-neutral-bg-color);color:var(--fc-neutral-text-color);min-width:1.5em;padding:2px;position:absolute;text-align:center;top:0}.fc-more-popover .fc-popover-body{min-width:220px;padding:10px}.fc-daygrid-event{border-radius:3px;font-size:var(--fc-small-font-size);margin-bottom:1px}.fc-media-print .fc-daygrid-event{overflow:hidden!important;white-space:nowrap!important}.fc-direction-ltr .fc-daygrid-event.fc-event-start,.fc-direction-rtl .fc-daygrid-event.fc-event-end{margin-left:2px}.fc-direction-ltr .fc-daygrid-event.fc-event-end,.fc-direction-rtl .fc-daygrid-event.fc-event-start{margin-right:2px}.fc-direction-ltr .fc-daygrid-event .fc-event-time{margin-right:3px}.fc-direction-rtl .fc-daygrid-event .fc-event-time{margin-left:3px}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-start),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-end){border-bottom-left-radius:0;border-left-width:0;border-top-left-radius:0}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-end),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-start){border-bottom-right-radius:0;border-right-width:0;border-top-right-radius:0}.fc-daygrid-block-event .fc-event-time{font-weight:700}.fc-daygrid-block-event .fc-event-time,.fc-daygrid-block-event .fc-event-title{padding:1px}.fc-daygrid-dot-event{align-items:center;direction:row;display:flex;padding:2px 0;position:relative;z-index:2}.fc-daygrid-dot-event.fc-event-mirror,.fc-daygrid-dot-event:hover{background:rgba(0,0,0,.1)}.fc-daygrid-dot-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-daygrid-event-dot{border:calc(var(--fc-daygrid-event-dot-width)/2) solid var(--fc-event-border-color);border-radius:calc(var(--fc-daygrid-event-dot-width)/2);box-sizing:content-box;height:0;margin:0 4px;width:0}.fc-daygrid-dot-event .fc-event-time,.fc-daygrid-dot-event .fc-event-title{overflow:hidden;white-space:nowrap}.fc-daygrid-dot-event .fc-event-title{flex-basis:0;flex-grow:1;font-weight:700;min-height:0;min-width:0}";
1196
+ var css_248z = ":root{--fc-daygrid-event-dot-width:8px}.fc-daygrid-row-print{min-height:6em}.fc-daygrid-day.fc-day-today{background-color:var(--fc-today-bg-color)}.fc-daygrid-day-header{display:flex;flex-direction:row-reverse}.fc-day-other .fc-daygrid-day-header{opacity:.3}.fc-daygrid-day-number{padding:4px;position:relative}.fc-daygrid-month-start{font-size:1.1em;font-weight:700}.fc-daygrid-day-body{display:flex;flex-direction:column;margin-bottom:1px}.fc-daygrid-day-body-tall{margin-bottom:1em;min-height:2em}.fc-daygrid-day-body:only-child{margin-top:2px}.fc-daygrid-more-link{border-radius:3px;cursor:pointer;font-size:var(--fc-small-font-size);margin:0 2px 1px;max-width:100%;overflow:hidden;padding:2px;position:relative;white-space:nowrap}.fc-daygrid-more-link:hover{background-color:rgba(0,0,0,.1)}.fc-daygrid-more-link-button{align-self:flex-start}.fc-daygrid-more-link-block{border:1px solid var(--fc-event-border-color);padding:1px}.fc-daygrid-week-number{background-color:var(--fc-neutral-bg-color);color:var(--fc-neutral-text-color);min-width:1.5em;padding:2px;position:absolute;text-align:center;top:0;z-index:1}.fc-direction-ltr .fc-daygrid-week-number{border-radius:0 0 3px}.fc-direction-rtl .fc-daygrid-week-number{border-radius:0 0 0 3px}.fc-more-popover .fc-popover-body{min-width:220px;padding:10px}.fc-daygrid-event{border-radius:3px;font-size:var(--fc-small-font-size);margin-bottom:1px}.fc-direction-ltr .fc-daygrid-event.fc-event-start,.fc-direction-rtl .fc-daygrid-event.fc-event-end{margin-left:2px}.fc-direction-ltr .fc-daygrid-event.fc-event-end,.fc-direction-rtl .fc-daygrid-event.fc-event-start{margin-right:2px}.fc-direction-ltr .fc-daygrid-event .fc-event-time{margin-right:3px}.fc-direction-rtl .fc-daygrid-event .fc-event-time{margin-left:3px}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-start),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-end){border-bottom-left-radius:0;border-left-width:0;border-top-left-radius:0}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-end),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-start){border-bottom-right-radius:0;border-right-width:0;border-top-right-radius:0}.fc-daygrid-block-event .fc-event-time{font-weight:700}.fc-daygrid-block-event .fc-event-time,.fc-daygrid-block-event .fc-event-title{padding:1px}.fc-daygrid-dot-event{align-items:center;direction:row;display:flex;padding:2px 0;position:relative}.fc-daygrid-dot-event.fc-event-mirror,.fc-daygrid-dot-event:hover{background:rgba(0,0,0,.1)}.fc-daygrid-dot-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-daygrid-event-dot{border:calc(var(--fc-daygrid-event-dot-width)/2) solid var(--fc-event-border-color);border-radius:calc(var(--fc-daygrid-event-dot-width)/2);box-sizing:content-box;height:0;margin:0 4px;width:0}.fc-daygrid-dot-event .fc-event-time,.fc-daygrid-dot-event .fc-event-title{overflow:hidden;white-space:nowrap}.fc-media-print .fc-daygrid-dot-event .fc-event-time,.fc-media-print .fc-daygrid-dot-event .fc-event-title{overflow:hidden!important;white-space:nowrap!important}.fc-daygrid-dot-event .fc-event-title{flex-basis:0;flex-grow:1;font-weight:700;min-height:0;min-width:0}";
1135
1197
  injectStyles(css_248z);
1136
1198
 
1137
- export { DayGridHeaderRow, DayGridLayout, DayGridRow, DayGridRows, DayGridView, DayTableSlicer, TableDateProfileGenerator, buildDateDataConfigs, buildDateRenderConfig, buildDateRowConfig, buildDateRowConfigs, buildDayTableModel, buildDayTableRenderRange, computeColFromPosition, computeColWidth, computeRowHeight, createDayHeaderFormatter, getCellEl, getRowEl };
1199
+ export { DayGridHeaderRow, DayGridLayout, DayGridRow, DayGridRows, DayGridView, DayTableSlicer, TableDateProfileGenerator, buildDateDataConfigs, buildDateRenderConfig, buildDateRowConfig, buildDateRowConfigs, buildDayTableModel, buildDayTableRenderRange, computeColFromPosition, computeColWidth, computeRowBasis, computeRowIsCompact, createDayHeaderFormatter, getCellEl, getRowEl };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fullcalendar/daygrid",
3
- "version": "7.0.0-beta.3",
3
+ "version": "7.0.0-rc.0",
4
4
  "title": "FullCalendar Day Grid Plugin",
5
5
  "description": "Display events on a month view or \"day grid\" view",
6
6
  "homepage": "https://fullcalendar.io/docs/month-view",
@@ -13,7 +13,7 @@
13
13
  "month-view"
14
14
  ],
15
15
  "peerDependencies": {
16
- "@fullcalendar/core": "7.0.0-beta.3"
16
+ "@fullcalendar/core": "7.0.0-rc.0"
17
17
  },
18
18
  "type": "module",
19
19
  "bugs": "https://fullcalendar.io/reporting-bugs",