@fullcalendar/core 7.0.0-beta.1 → 7.0.0-beta.4
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/index.cjs +68 -76
- package/index.d.ts +0 -1
- package/index.global.js +1454 -1325
- package/index.global.min.js +2 -2
- package/index.js +70 -78
- package/internal-common.cjs +2757 -2620
- package/internal-common.d.ts +263 -220
- package/internal-common.js +2743 -2603
- package/internal.cjs +12 -16
- package/internal.d.ts +1 -2
- package/internal.js +1 -1
- package/locales/af.global.js +1 -1
- package/locales/af.global.min.js +1 -1
- package/locales/ar-dz.global.js +1 -1
- package/locales/ar-dz.global.min.js +1 -1
- package/locales/ar-kw.global.js +1 -1
- package/locales/ar-kw.global.min.js +1 -1
- package/locales/ar-ly.global.js +1 -1
- package/locales/ar-ly.global.min.js +1 -1
- package/locales/ar-ma.global.js +1 -1
- package/locales/ar-ma.global.min.js +1 -1
- package/locales/ar-sa.global.js +1 -1
- package/locales/ar-sa.global.min.js +1 -1
- package/locales/ar-tn.global.js +1 -1
- package/locales/ar-tn.global.min.js +1 -1
- package/locales/ar.global.js +1 -1
- package/locales/ar.global.min.js +1 -1
- package/locales/az.global.js +1 -1
- package/locales/az.global.min.js +1 -1
- package/locales/bg.global.js +1 -1
- package/locales/bg.global.min.js +1 -1
- package/locales/bn.global.js +1 -1
- package/locales/bn.global.min.js +1 -1
- package/locales/bs.global.js +1 -1
- package/locales/bs.global.min.js +1 -1
- package/locales/ca.global.js +1 -1
- package/locales/ca.global.min.js +1 -1
- package/locales/cs.global.js +1 -1
- package/locales/cs.global.min.js +1 -1
- package/locales/cy.global.js +1 -1
- package/locales/cy.global.min.js +1 -1
- package/locales/da.global.js +1 -1
- package/locales/da.global.min.js +1 -1
- package/locales/de-at.cjs +1 -2
- package/locales/de-at.global.js +2 -3
- package/locales/de-at.global.min.js +2 -2
- package/locales/de-at.js +1 -2
- package/locales/de.cjs +1 -2
- package/locales/de.global.js +2 -3
- package/locales/de.global.min.js +2 -2
- package/locales/de.js +1 -2
- package/locales/el.global.js +1 -1
- package/locales/el.global.min.js +1 -1
- package/locales/en-au.global.js +1 -1
- package/locales/en-au.global.min.js +1 -1
- package/locales/en-gb.global.js +1 -1
- package/locales/en-gb.global.min.js +1 -1
- package/locales/en-nz.global.js +1 -1
- package/locales/en-nz.global.min.js +1 -1
- package/locales/eo.global.js +1 -1
- package/locales/eo.global.min.js +1 -1
- package/locales/es-us.global.js +1 -1
- package/locales/es-us.global.min.js +1 -1
- package/locales/es.cjs +1 -2
- package/locales/es.global.js +2 -3
- package/locales/es.global.min.js +2 -2
- package/locales/es.js +1 -2
- package/locales/et.global.js +1 -1
- package/locales/et.global.min.js +1 -1
- package/locales/eu.global.js +1 -1
- package/locales/eu.global.min.js +1 -1
- package/locales/fa.global.js +1 -1
- package/locales/fa.global.min.js +1 -1
- package/locales/fi.global.js +1 -1
- package/locales/fi.global.min.js +1 -1
- package/locales/fr-ca.global.js +1 -1
- package/locales/fr-ca.global.min.js +1 -1
- package/locales/fr-ch.global.js +1 -1
- package/locales/fr-ch.global.min.js +1 -1
- package/locales/fr.global.js +1 -1
- package/locales/fr.global.min.js +1 -1
- package/locales/gl.cjs +1 -2
- package/locales/gl.global.js +2 -3
- package/locales/gl.global.min.js +2 -2
- package/locales/gl.js +1 -2
- package/locales/he.global.js +1 -1
- package/locales/he.global.min.js +1 -1
- package/locales/hi.global.js +1 -1
- package/locales/hi.global.min.js +1 -1
- package/locales/hr.global.js +1 -1
- package/locales/hr.global.min.js +1 -1
- package/locales/hu.global.js +1 -1
- package/locales/hu.global.min.js +1 -1
- package/locales/hy-am.global.js +1 -1
- package/locales/hy-am.global.min.js +1 -1
- package/locales/id.global.js +1 -1
- package/locales/id.global.min.js +1 -1
- package/locales/is.global.js +1 -1
- package/locales/is.global.min.js +1 -1
- package/locales/it.global.js +1 -1
- package/locales/it.global.min.js +1 -1
- package/locales/ja.global.js +1 -1
- package/locales/ja.global.min.js +1 -1
- package/locales/ka.global.js +1 -1
- package/locales/ka.global.min.js +1 -1
- package/locales/kk.global.js +1 -1
- package/locales/kk.global.min.js +1 -1
- package/locales/km.global.js +1 -1
- package/locales/km.global.min.js +1 -1
- package/locales/ko.global.js +1 -1
- package/locales/ko.global.min.js +1 -1
- package/locales/ku.global.js +1 -1
- package/locales/ku.global.min.js +1 -1
- package/locales/lb.global.js +1 -1
- package/locales/lb.global.min.js +1 -1
- package/locales/lt.global.js +1 -1
- package/locales/lt.global.min.js +1 -1
- package/locales/lv.global.js +1 -1
- package/locales/lv.global.min.js +1 -1
- package/locales/mk.global.js +1 -1
- package/locales/mk.global.min.js +1 -1
- package/locales/ms.global.js +1 -1
- package/locales/ms.global.min.js +1 -1
- package/locales/nb.global.js +1 -1
- package/locales/nb.global.min.js +1 -1
- package/locales/ne.global.js +1 -1
- package/locales/ne.global.min.js +1 -1
- package/locales/nl.global.js +1 -1
- package/locales/nl.global.min.js +1 -1
- package/locales/nn.global.js +1 -1
- package/locales/nn.global.min.js +1 -1
- package/locales/pl.global.js +1 -1
- package/locales/pl.global.min.js +1 -1
- package/locales/pt-br.cjs +1 -2
- package/locales/pt-br.global.js +2 -3
- package/locales/pt-br.global.min.js +2 -2
- package/locales/pt-br.js +1 -2
- package/locales/pt.global.js +1 -1
- package/locales/pt.global.min.js +1 -1
- package/locales/ro.global.js +1 -1
- package/locales/ro.global.min.js +1 -1
- package/locales/ru.global.js +1 -1
- package/locales/ru.global.min.js +1 -1
- package/locales/si-lk.global.js +1 -1
- package/locales/si-lk.global.min.js +1 -1
- package/locales/sk.global.js +1 -1
- package/locales/sk.global.min.js +1 -1
- package/locales/sl.global.js +1 -1
- package/locales/sl.global.min.js +1 -1
- package/locales/sm.global.js +1 -1
- package/locales/sm.global.min.js +1 -1
- package/locales/sq.global.js +1 -1
- package/locales/sq.global.min.js +1 -1
- package/locales/sr-cyrl.global.js +1 -1
- package/locales/sr-cyrl.global.min.js +1 -1
- package/locales/sr.global.js +1 -1
- package/locales/sr.global.min.js +1 -1
- package/locales/sv.cjs +1 -2
- package/locales/sv.global.js +2 -3
- package/locales/sv.global.min.js +2 -2
- package/locales/sv.js +1 -2
- package/locales/ta-in.global.js +1 -1
- package/locales/ta-in.global.min.js +1 -1
- package/locales/th.global.js +1 -1
- package/locales/th.global.min.js +1 -1
- package/locales/tr.global.js +1 -1
- package/locales/tr.global.min.js +1 -1
- package/locales/ug.global.js +1 -1
- package/locales/ug.global.min.js +1 -1
- package/locales/uk.global.js +1 -1
- package/locales/uk.global.min.js +1 -1
- package/locales/uz-cy.global.js +1 -1
- package/locales/uz-cy.global.min.js +1 -1
- package/locales/uz.global.js +1 -1
- package/locales/uz.global.min.js +1 -1
- package/locales/vi.global.js +1 -1
- package/locales/vi.global.min.js +1 -1
- package/locales/zh-cn.global.js +1 -1
- package/locales/zh-cn.global.min.js +1 -1
- package/locales/zh-tw.global.js +1 -1
- package/locales/zh-tw.global.min.js +1 -1
- package/locales-all.global.js +7 -13
- package/locales-all.global.min.js +2 -2
- package/package.json +1 -1
- package/preact.cjs +1 -0
- package/preact.d.ts +3 -2
- package/preact.js +1 -1
package/index.global.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
FullCalendar Core v7.0.0-beta.
|
|
2
|
+
FullCalendar Core v7.0.0-beta.4
|
|
3
3
|
Docs & License: https://fullcalendar.io
|
|
4
4
|
(c) 2024 Adam Shaw
|
|
5
5
|
*/
|
|
@@ -86,102 +86,9 @@ var FullCalendar = (function (exports) {
|
|
|
86
86
|
registerStylesRoot(document);
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
-
var css_248z = ":root{--fc-small-font-size:.85em;--fc-page-bg-color:#fff;--fc-neutral-bg-color:hsla(0,0%,82%,.3);--fc-neutral-text-color:grey;--fc-border-color:#ddd;--fc-button-text-color:#fff;--fc-button-bg-color:#2c3e50;--fc-button-border-color:#2c3e50;--fc-button-hover-bg-color:#1e2b37;--fc-button-hover-border-color:#1a252f;--fc-button-active-bg-color:#1a252f;--fc-button-active-border-color:#151e27;--fc-event-bg-color:#3788d8;--fc-event-border-color:#3788d8;--fc-event-text-color:#fff;--fc-event-selected-overlay-color:rgba(0,0,0,.25);--fc-more-link-bg-color:#d0d0d0;--fc-more-link-text-color:inherit;--fc-event-resizer-thickness:8px;--fc-event-resizer-dot-total-width:8px;--fc-event-resizer-dot-border-width:1px;--fc-non-business-color:hsla(0,0%,84%,.3);--fc-bg-event-color:#8fdf82;--fc-bg-event-opacity:0.3;--fc-highlight-color:rgba(188,232,241,.3);--fc-today-bg-color:rgba(255,220,40,.15);--fc-now-indicator-color:red}.fc{display:flex;flex-direction:column;gap:1.5em}.fc,.fc *,.fc :after,.fc :before{box-sizing:border-box}.fc-direction-ltr{direction:ltr;text-align:left}.fc-direction-rtl{direction:rtl;text-align:right}.fc-flex-row{display:flex;flex-direction:row}.fc-flex-column{display:flex;flex-direction:column}.fc-grow{flex-grow:1}.fc-basis0,.fc-liquid{flex-basis:0}.fc-liquid{flex-grow:1;min-height:0;min-width:0}.fc-row{display:flex;flex-direction:row}.fc-rowgroup{display:flex;flex-direction:column}.fc-row,.fc-rowdivider,.fc-rowgroup{border-color:var(--fc-border-color);border-style:solid;border-width:1px 0 0}.fc-row:first-child:not(.fc-not-first),.fc-rowdivider+.fc-row,.fc-rowdivider+.fc-rowgroup,.fc-rowdivider:first-child,.fc-rowgroup:first-child,.fc-sticky-header+.fc-row,.fc-sticky-header+.fc-rowgroup{border-top-width:0}.fc-cell,.fc-celldivider{border:0 solid var(--fc-border-color)}.fc-cell{margin:0!important;padding:0!important}.fc-cell-inner{overflow:hidden;white-space:nowrap}.fc-direction-ltr .fc-cell,.fc-direction-ltr .fc-celldivider{border-left-width:1px}.fc-direction-ltr .fc-cell:first-child:not(.fc-not-first),.fc-direction-ltr .fc-celldivider+.fc-cell{border-left-width:0}.fc-direction-ltr .fc-celldivider,.fc-direction-rtl .fc-cell,.fc-direction-rtl .fc-celldivider{border-right-width:1px}.fc-direction-rtl .fc-cell:first-child:not(.fc-not-first),.fc-direction-rtl .fc-celldivider+.fc-cell{border-right-width:0}.fc-direction-rtl .fc-celldivider{border-left-width:1px}.fc-cell:only-child{flex-basis:0;flex-grow:1;min-width:0}.fc-celldivider,.fc-rowdivider{background:var(--fc-neutral-bg-color)}.fc-celldivider{padding-left:2px}.fc-rowdivider{padding-bottom:2px}.fc-rowdivider,.fc-sticky-header{border-bottom-width:1px}.fc-rel{position:relative}.fc-abs{position:absolute}.fc-fill{bottom:0;top:0}.fc-fill,.fc-fill-x{left:0;position:absolute;right:0}.fc-fill-y{bottom:0;position:absolute;top:0}.fc-sticky-y{bottom:0;position:sticky;top:0}.fc-sticky-x{left:0;position:sticky;right:0}.fc-sticky-header{background:var(--fc-page-bg-color);position:sticky;top:0;z-index:9999}.fc-sticky-footer{bottom:0;position:sticky;z-index:9999}.fc-content-box{box-sizing:content-box}.fc-border{border:1px solid var(--fc-border-color)}.fc-offscreen{left:-10000px;position:absolute}.fc-shaded{background-color:var(--fc-neutral-bg-color)}.fc-padding-sm{padding:2px 4px}.fc-padding-md{padding:4px 5px}.fc-padding-lg{padding:8px}.fc-justify-center{justify-content:center}.fc-align-center{align-items:center}.fc-align-start{align-items:flex-start}.fc a[data-navlink]{cursor:pointer}.fc a[data-navlink]:hover{text-decoration:underline}.fc-view-harness{position:relative}.fc-view-harness-fixedheight,.fc-view-harness-liquid{display:flex;flex-direction:column}.fc-view-harness-fixedheight>.fc-view,.fc-view-harness-liquid,.fc-view-harness-liquid>.fc-view{flex-basis:0;flex-grow:1;min-height:0}.fc-view-harness-aspectratio>.fc-view{bottom:0;left:0;position:absolute;right:0;top:0}a.fc-event,a.fc-event:hover{text-decoration:none}.fc-event.fc-event-draggable,.fc-event[href]{cursor:pointer}.fc-event-dragging:not(.fc-event-selected){opacity:.75}.fc-event-dragging.fc-event-selected{box-shadow:0 2px 7px rgba(0,0,0,.3)}.fc-event-selected,.fc-event:focus{box-shadow:0 2px 5px rgba(0,0,0,.2)}.fc-event-selected:before,.fc-event:focus:before{bottom:0;content:\"\";left:0;position:absolute;right:0;top:0;z-index:3}.fc-event-selected:after,.fc-event:focus:after{background:var(--fc-event-selected-overlay-color);bottom:-1px;content:\"\";left:-1px;position:absolute;right:-1px;top:-1px;z-index:1}.fc-event-inner{position:relative;z-index:2}.fc-event-resizer{display:none;position:absolute;z-index:4}.fc-event-selected .fc-event-resizer,.fc-event:hover .fc-event-resizer{display:block}.fc-event-selected .fc-event-resizer{background:var(--fc-page-bg-color);border-color:inherit;border-radius:calc(var(--fc-event-resizer-dot-total-width)/2);border-style:solid;border-width:var(--fc-event-resizer-dot-border-width);height:var(--fc-event-resizer-dot-total-width);width:var(--fc-event-resizer-dot-total-width)}.fc-event-selected .fc-event-resizer:before{bottom:-20px;content:\"\";left:-20px;position:absolute;right:-20px;top:-20px}.fc-bg-event,.fc-highlight,.fc-non-business{bottom:0;left:0;position:absolute;right:0;top:0}.fc-non-business{background:var(--fc-non-business-color)}.fc-bg-event{background:var(--fc-bg-event-color);opacity:var(--fc-bg-event-opacity)}.fc-bg-event .fc-event-title{font-size:var(--fc-small-font-size);font-style:italic;margin:.5em}.fc-highlight{background:var(--fc-highlight-color)}.fc-day-disabled{background:var(--fc-neutral-bg-color)}.fc-h-event{background-color:var(--fc-event-bg-color);border:1px solid var(--fc-event-border-color);display:flex;flex-direction:column;position:relative}.fc-h-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-h-event .fc-event-inner{color:var(--fc-event-text-color);display:flex;flex-direction:row;flex-grow:1;min-width:0}.fc-h-event .fc-event-time,.fc-h-event .fc-event-title{overflow:hidden;white-space:nowrap}.fc-h-event .fc-event-title-outer{display:flex;flex-basis:0;flex-direction:row;flex-grow:1;min-width:0}.fc-h-event .fc-event-title{left:0;position:sticky;right:0}.fc-h-event:not(.fc-event-selected) .fc-event-resizer{bottom:0;top:0;width:var(--fc-event-resizer-thickness)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end{cursor:w-resize;left:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start{cursor:e-resize;right:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-h-event.fc-event-selected .fc-event-resizer{margin-top:calc(var(--fc-event-resizer-dot-total-width)*-.5);top:50%}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-start,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-end{left:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-end,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-start{right:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc-popover{box-shadow:0 2px 6px rgba(0,0,0,.15);position:absolute;z-index:9999}.fc-popover-header{align-items:center;display:flex;flex-direction:row;justify-content:space-between;padding:3px 4px}.fc-popover-title{margin:0 2px}.fc-popover-close{cursor:pointer;font-size:1.1em;opacity:.65}.fc-theme-standard .fc-popover{background:var(--fc-page-bg-color);border:1px solid var(--fc-border-color)}.fc-theme-standard .fc-popover-header{background:var(--fc-neutral-bg-color)}.fc-scroller-nobars{-ms-overflow-style:none;scrollbar-width:none}.fc-scroller-nobars::-webkit-scrollbar{display:none}.fc-not-allowed,.fc-not-allowed .fc-event{cursor:not-allowed}@font-face{font-family:fcicons;font-style:normal;font-weight:400;src:url(\"data:application/x-font-ttf;charset=utf-8;base64,AAEAAAALAIAAAwAwT1MvMg8SBfAAAAC8AAAAYGNtYXAXVtKNAAABHAAAAFRnYXNwAAAAEAAAAXAAAAAIZ2x5ZgYydxIAAAF4AAAFNGhlYWQUJ7cIAAAGrAAAADZoaGVhB20DzAAABuQAAAAkaG10eCIABhQAAAcIAAAALGxvY2ED4AU6AAAHNAAAABhtYXhwAA8AjAAAB0wAAAAgbmFtZXsr690AAAdsAAABhnBvc3QAAwAAAAAI9AAAACAAAwPAAZAABQAAApkCzAAAAI8CmQLMAAAB6wAzAQkAAAAAAAAAAAAAAAAAAAABEAAAAAAAAAAAAAAAAAAAAABAAADpBgPA/8AAQAPAAEAAAAABAAAAAAAAAAAAAAAgAAAAAAADAAAAAwAAABwAAQADAAAAHAADAAEAAAAcAAQAOAAAAAoACAACAAIAAQAg6Qb//f//AAAAAAAg6QD//f//AAH/4xcEAAMAAQAAAAAAAAAAAAAAAQAB//8ADwABAAAAAAAAAAAAAgAANzkBAAAAAAEAAAAAAAAAAAACAAA3OQEAAAAAAQAAAAAAAAAAAAIAADc5AQAAAAABAWIAjQKeAskAEwAAJSc3NjQnJiIHAQYUFwEWMjc2NCcCnuLiDQ0MJAz/AA0NAQAMJAwNDcni4gwjDQwM/wANIwz/AA0NDCMNAAAAAQFiAI0CngLJABMAACUBNjQnASYiBwYUHwEHBhQXFjI3AZ4BAA0N/wAMJAwNDeLiDQ0MJAyNAQAMIw0BAAwMDSMM4uINIwwNDQAAAAIA4gC3Ax4CngATACcAACUnNzY0JyYiDwEGFB8BFjI3NjQnISc3NjQnJiIPAQYUHwEWMjc2NCcB87e3DQ0MIw3VDQ3VDSMMDQ0BK7e3DQ0MJAzVDQ3VDCQMDQ3zuLcMJAwNDdUNIwzWDAwNIwy4twwkDA0N1Q0jDNYMDA0jDAAAAgDiALcDHgKeABMAJwAAJTc2NC8BJiIHBhQfAQcGFBcWMjchNzY0LwEmIgcGFB8BBwYUFxYyNwJJ1Q0N1Q0jDA0Nt7cNDQwjDf7V1Q0N1QwkDA0Nt7cNDQwkDLfWDCMN1Q0NDCQMt7gMIw0MDNYMIw3VDQ0MJAy3uAwjDQwMAAADAFUAAAOrA1UAMwBoAHcAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMhMjY1NCYjISIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAAVYRGRkR/qoRGRkRA1UFBAUOCQkVDAsZDf2rDRkLDBUJCA4FBQUFBQUOCQgVDAsZDQJVDRkLDBUJCQ4FBAVVAgECBQMCBwQECAX9qwQJAwQHAwMFAQICAgIBBQMDBwQDCQQCVQUIBAQHAgMFAgEC/oAZEhEZGRESGQAAAAADAFUAAAOrA1UAMwBoAIkAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMzFRQWMzI2PQEzMjY1NCYrATU0JiMiBh0BIyIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAgBkSEhmAERkZEYAZEhIZgBEZGREDVQUEBQ4JCRUMCxkN/asNGQsMFQkIDgUFBQUFBQ4JCBUMCxkNAlUNGQsMFQkJDgUEBVUCAQIFAwIHBAQIBf2rBAkDBAcDAwUBAgICAgEFAwMHBAMJBAJVBQgEBAcCAwUCAQL+gIASGRkSgBkSERmAEhkZEoAZERIZAAABAOIAjQMeAskAIAAAExcHBhQXFjI/ARcWMjc2NC8BNzY0JyYiDwEnJiIHBhQX4uLiDQ0MJAzi4gwkDA0N4uINDQwkDOLiDCQMDQ0CjeLiDSMMDQ3h4Q0NDCMN4uIMIw0MDOLiDAwNIwwAAAABAAAAAQAAa5n0y18PPPUACwQAAAAAANivOVsAAAAA2K85WwAAAAADqwNVAAAACAACAAAAAAAAAAEAAAPA/8AAAAQAAAAAAAOrAAEAAAAAAAAAAAAAAAAAAAALBAAAAAAAAAAAAAAAAgAAAAQAAWIEAAFiBAAA4gQAAOIEAABVBAAAVQQAAOIAAAAAAAoAFAAeAEQAagCqAOoBngJkApoAAQAAAAsAigADAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAA4ArgABAAAAAAABAAcAAAABAAAAAAACAAcAYAABAAAAAAADAAcANgABAAAAAAAEAAcAdQABAAAAAAAFAAsAFQABAAAAAAAGAAcASwABAAAAAAAKABoAigADAAEECQABAA4ABwADAAEECQACAA4AZwADAAEECQADAA4APQADAAEECQAEAA4AfAADAAEECQAFABYAIAADAAEECQAGAA4AUgADAAEECQAKADQApGZjaWNvbnMAZgBjAGkAYwBvAG4Ac1ZlcnNpb24gMS4wAFYAZQByAHMAaQBvAG4AIAAxAC4AMGZjaWNvbnMAZgBjAGkAYwBvAG4Ac2ZjaWNvbnMAZgBjAGkAYwBvAG4Ac1JlZ3VsYXIAUgBlAGcAdQBsAGEAcmZjaWNvbnMAZgBjAGkAYwBvAG4Ac0ZvbnQgZ2VuZXJhdGVkIGJ5IEljb01vb24uAEYAbwBuAHQAIABnAGUAbgBlAHIAYQB0AGUAZAAgAGIAeQAgAEkAYwBvAE0AbwBvAG4ALgAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=\") format(\"truetype\")}.fc-icon{speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;display:inline-block;font-family:fcicons!important;font-style:normal;font-variant:normal;font-weight:400;height:1em;line-height:1;text-align:center;text-transform:none;-moz-user-select:none;user-select:none;width:1em}.fc-icon-chevron-left:before{content:\"\\e900\"}.fc-icon-chevron-right:before{content:\"\\e901\"}.fc-icon-chevrons-left:before{content:\"\\e902\"}.fc-icon-chevrons-right:before{content:\"\\e903\"}.fc-icon-minus-square:before{content:\"\\e904\"}.fc-icon-plus-square:before{content:\"\\e905\"}.fc-icon-x:before{content:\"\\e906\"}.fc-button{border-radius:0;font-family:inherit;font-size:inherit;line-height:inherit;margin:0;overflow:visible;text-transform:none}.fc-button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}.fc-button{-webkit-appearance:button}.fc-button:not(:disabled){cursor:pointer}.fc-button{background-color:transparent;border:1px solid transparent;border-radius:.25em;display:inline-block;font-size:1em;font-weight:400;line-height:1.5;padding:.4em .65em;text-align:center;-moz-user-select:none;user-select:none;vertical-align:middle}.fc-button:hover{text-decoration:none}.fc-button:focus{box-shadow:0 0 0 .2rem rgba(44,62,80,.25);outline:0}.fc-button:disabled{opacity:.65}.fc-button-primary{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc-button-primary:hover{background-color:var(--fc-button-hover-bg-color);border-color:var(--fc-button-hover-border-color);color:var(--fc-button-text-color)}.fc-button-primary:disabled{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc-button-primary:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc-button-primary:not(:disabled).fc-button-active,.fc-button-primary:not(:disabled):active{background-color:var(--fc-button-active-bg-color);border-color:var(--fc-button-active-border-color);color:var(--fc-button-text-color)}.fc-button-primary:not(:disabled).fc-button-active:focus,.fc-button-primary:not(:disabled):active:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc-button .fc-icon{font-size:1.5em;vertical-align:middle}.fc-button-group{display:inline-flex;position:relative;vertical-align:middle}.fc-button-group>.fc-button{flex:1 1 auto;position:relative}.fc-button-group>.fc-button.fc-button-active,.fc-button-group>.fc-button:active,.fc-button-group>.fc-button:focus,.fc-button-group>.fc-button:hover{z-index:1}.fc-direction-ltr .fc-button-group>.fc-button:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0;margin-left:-1px}.fc-direction-ltr .fc-button-group>.fc-button:not(:last-child){border-bottom-right-radius:0;border-top-right-radius:0}.fc-direction-rtl .fc-button-group>.fc-button:not(:first-child){border-bottom-right-radius:0;border-top-right-radius:0;margin-right:-1px}.fc-direction-rtl .fc-button-group>.fc-button:not(:last-child){border-bottom-left-radius:0;border-top-left-radius:0}.fc-toolbar{align-items:center;display:flex;flex-direction:row;gap:.75em;justify-content:space-between}.fc-direction-rtl .fc-toolbar-ltr{flex-direction:row-reverse}.fc-toolbar-chunk{display:flex;flex-direction:row;flex-shrink:0;gap:.75em}.fc-toolbar-title{font-size:1.75em;margin:0;white-space:nowrap}";
|
|
89
|
+
var css_248z = ":root{--fc-small-font-size:.85em;--fc-page-bg-color:#fff;--fc-neutral-bg-color:hsla(0,0%,82%,.3);--fc-neutral-text-color:grey;--fc-border-color:#ddd;--fc-button-text-color:#fff;--fc-button-bg-color:#2c3e50;--fc-button-border-color:#2c3e50;--fc-button-hover-bg-color:#1e2b37;--fc-button-hover-border-color:#1a252f;--fc-button-active-bg-color:#1a252f;--fc-button-active-border-color:#151e27;--fc-event-bg-color:#3788d8;--fc-event-border-color:#3788d8;--fc-event-text-color:#fff;--fc-event-selected-overlay-color:rgba(0,0,0,.25);--fc-more-link-bg-color:#d0d0d0;--fc-more-link-text-color:inherit;--fc-event-resizer-thickness:8px;--fc-event-resizer-dot-total-width:8px;--fc-event-resizer-dot-border-width:1px;--fc-non-business-color:hsla(0,0%,84%,.3);--fc-bg-event-color:#8fdf82;--fc-bg-event-opacity:0.3;--fc-highlight-color:rgba(188,232,241,.3);--fc-today-bg-color:rgba(255,220,40,.15);--fc-now-indicator-color:red}.fc{display:flex;flex-direction:column;gap:1.5em}.fc,.fc *,.fc :after,.fc :before{box-sizing:border-box}.fc-direction-ltr{direction:ltr;text-align:left}.fc-direction-rtl{direction:rtl;text-align:right}.fc-border,.fc-border-b,.fc-border-e,.fc-border-s,.fc-border-t{border:0 solid var(--fc-border-color)}.fc-border-transparent{border-color:transparent}.fc-border{border-width:1px}.fc-border-t{border-top-width:1px}.fc-border-b{border-bottom-width:1px}.fc-direction-ltr .fc-border-s,.fc-direction-rtl .fc-border-e{border-left-width:1px}.fc-direction-ltr .fc-border-e,.fc-direction-rtl .fc-border-s{border-right-width:1px}.fc-flex-row{display:flex;flex-direction:row}.fc-flex-col{display:flex;flex-direction:column}.fc-grow{flex-grow:1}.fc-basis0,.fc-liquid{flex-basis:0}.fc-liquid{flex-grow:1;min-height:0;min-width:0}.fc-media-screen .fc-print-header,.fc-media-screen .fc-print-root{display:flex;flex-direction:column}.fc-cell{margin:0!important;padding:0!important}.fc-cell-inner{flex-shrink:0;overflow:hidden;white-space:nowrap}.fc-celldivider,.fc-rowdivider{border:0 solid var(--fc-border-color)}.fc-rowdivider{border-width:1px 0}.fc-celldivider{border-width:0 1px}.fc-celldivider,.fc-rowdivider{background:var(--fc-neutral-bg-color)}.fc-celldivider{padding-left:2px}.fc-rowdivider{padding-bottom:2px}.fc-crop{overflow:hidden}.fc-rel{position:relative}.fc-abs{position:absolute}.fc-fill{bottom:0;top:0}.fc-fill,.fc-fill-x{left:0;position:absolute;right:0}.fc-fill-y{bottom:0;position:absolute;top:0}.fc-sticky-t{position:sticky;top:0}.fc-sticky-s{left:0;position:sticky;right:0}.fc-table-header-sticky{background:var(--fc-page-bg-color);position:sticky;top:0;z-index:5}.fc-sticky-footer-scrollbar{bottom:0;position:sticky;z-index:5}.fc-sticky-footer-scrollbar>.fc-scroller{margin-top:-1px}.fc-sticky-footer-scrollbar>.fc-scroller>*{height:1px}.fc-content-box{box-sizing:content-box}.fc-offscreen{left:-10000px;position:absolute}.fc-shaded{background-color:var(--fc-neutral-bg-color)}.fc-filler{opacity:.5}.fc-padding-sm{padding:2px 4px}.fc-padding-md{padding:4px 5px}.fc-padding-lg{padding:8px}.fc-justify-center{justify-content:center}.fc-align-center{align-items:center}.fc-align-start{align-items:flex-start}.fc [data-navlink]{cursor:pointer}.fc [data-navlink]:hover{text-decoration:underline}.fc-view-outer{position:relative}.fc-view-outer-liquid,.fc-view-outer-static{display:flex;flex-direction:column}.fc-view-outer-liquid,.fc-view-outer-liquid>.fc-view,.fc-view-outer-static>.fc-view{flex-basis:0;flex-grow:1;min-height:0;min-width:0}.fc-view-outer-aspect-ratio>.fc-view{bottom:0;left:0;position:absolute;right:0;top:0}a.fc-event,a.fc-event:hover{text-decoration:none}.fc-event.fc-event-draggable,.fc-event[href]{cursor:pointer}.fc-event-dragging:not(.fc-event-selected){opacity:.75}.fc-event-dragging.fc-event-selected{box-shadow:0 2px 7px rgba(0,0,0,.3)}.fc-event-selected:before{bottom:0;content:\"\";left:0;position:absolute;right:0;top:0;z-index:3}.fc-event-selected,.fc-event:focus{box-shadow:0 2px 5px rgba(0,0,0,.2)}.fc-event-selected:after,.fc-event:focus:after{background:var(--fc-event-selected-overlay-color);bottom:-1px;content:\"\";left:-1px;position:absolute;right:-1px;top:-1px;z-index:1}.fc-event-inner{position:relative;z-index:2}.fc-event-resizer{display:none;position:absolute;z-index:4}.fc-event-selected .fc-event-resizer,.fc-event:hover .fc-event-resizer{display:block}.fc-event-selected .fc-event-resizer{background:var(--fc-page-bg-color);border-color:inherit;border-radius:calc(var(--fc-event-resizer-dot-total-width)/2);border-style:solid;border-width:var(--fc-event-resizer-dot-border-width);height:var(--fc-event-resizer-dot-total-width);width:var(--fc-event-resizer-dot-total-width)}.fc-event-selected .fc-event-resizer:before{bottom:-20px;content:\"\";left:-20px;position:absolute;right:-20px;top:-20px}.fc-bg-event,.fc-highlight,.fc-non-business{bottom:0;left:0;position:absolute;right:0;top:0}.fc-non-business{background:var(--fc-non-business-color)}.fc-bg-event{background:var(--fc-bg-event-color);opacity:var(--fc-bg-event-opacity)}.fc-bg-event .fc-event-title{font-size:var(--fc-small-font-size);font-style:italic;margin:.5em}.fc-highlight{background:var(--fc-highlight-color)}.fc-day-disabled{background:var(--fc-neutral-bg-color)}.fc-h-event{background-color:var(--fc-event-bg-color);border:1px solid var(--fc-event-border-color);display:flex;flex-direction:column;position:relative}.fc-h-event.fc-event-mirror{z-index:3}.fc-h-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-h-event .fc-event-inner{color:var(--fc-event-text-color);display:flex;flex-direction:row}.fc-h-event .fc-event-time,.fc-h-event .fc-event-title{overflow:hidden;white-space:nowrap}.fc-h-event .fc-event-title-outer{display:flex;flex-basis:0;flex-direction:row;flex-grow:1;min-height:0;min-width:0}.fc-h-event .fc-event-title{left:0;position:sticky;right:0}.fc-h-event:not(.fc-event-selected) .fc-event-resizer{bottom:0;top:0;width:var(--fc-event-resizer-thickness)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end{cursor:w-resize;left:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start{cursor:e-resize;right:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-h-event.fc-event-selected .fc-event-resizer{margin-top:calc(var(--fc-event-resizer-dot-total-width)*-.5);top:50%}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-start,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-end{left:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-end,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-start{right:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc-popover{box-shadow:0 2px 6px rgba(0,0,0,.15);position:absolute;z-index:6}.fc-popover-header{align-items:center;display:flex;flex-direction:row;justify-content:space-between;padding:3px 4px}.fc-popover-title{margin:0 2px}.fc-popover-close{cursor:pointer;font-size:1.1em;opacity:.65}.fc-theme-standard .fc-popover{background:var(--fc-page-bg-color);border:1px solid var(--fc-border-color)}.fc-theme-standard .fc-popover-header{background:var(--fc-neutral-bg-color)}.fc-scroller{padding:0!important}.fc-scroller-no-bars{-ms-overflow-style:none;scrollbar-width:none}.fc-scroller-no-bars::-webkit-scrollbar{display:none}.fc-not-allowed,.fc-not-allowed .fc-event{cursor:not-allowed}@font-face{font-family:fcicons;font-style:normal;font-weight:400;src:url(\"data:application/x-font-ttf;charset=utf-8;base64,AAEAAAALAIAAAwAwT1MvMg8SBfAAAAC8AAAAYGNtYXAXVtKNAAABHAAAAFRnYXNwAAAAEAAAAXAAAAAIZ2x5ZgYydxIAAAF4AAAFNGhlYWQUJ7cIAAAGrAAAADZoaGVhB20DzAAABuQAAAAkaG10eCIABhQAAAcIAAAALGxvY2ED4AU6AAAHNAAAABhtYXhwAA8AjAAAB0wAAAAgbmFtZXsr690AAAdsAAABhnBvc3QAAwAAAAAI9AAAACAAAwPAAZAABQAAApkCzAAAAI8CmQLMAAAB6wAzAQkAAAAAAAAAAAAAAAAAAAABEAAAAAAAAAAAAAAAAAAAAABAAADpBgPA/8AAQAPAAEAAAAABAAAAAAAAAAAAAAAgAAAAAAADAAAAAwAAABwAAQADAAAAHAADAAEAAAAcAAQAOAAAAAoACAACAAIAAQAg6Qb//f//AAAAAAAg6QD//f//AAH/4xcEAAMAAQAAAAAAAAAAAAAAAQAB//8ADwABAAAAAAAAAAAAAgAANzkBAAAAAAEAAAAAAAAAAAACAAA3OQEAAAAAAQAAAAAAAAAAAAIAADc5AQAAAAABAWIAjQKeAskAEwAAJSc3NjQnJiIHAQYUFwEWMjc2NCcCnuLiDQ0MJAz/AA0NAQAMJAwNDcni4gwjDQwM/wANIwz/AA0NDCMNAAAAAQFiAI0CngLJABMAACUBNjQnASYiBwYUHwEHBhQXFjI3AZ4BAA0N/wAMJAwNDeLiDQ0MJAyNAQAMIw0BAAwMDSMM4uINIwwNDQAAAAIA4gC3Ax4CngATACcAACUnNzY0JyYiDwEGFB8BFjI3NjQnISc3NjQnJiIPAQYUHwEWMjc2NCcB87e3DQ0MIw3VDQ3VDSMMDQ0BK7e3DQ0MJAzVDQ3VDCQMDQ3zuLcMJAwNDdUNIwzWDAwNIwy4twwkDA0N1Q0jDNYMDA0jDAAAAgDiALcDHgKeABMAJwAAJTc2NC8BJiIHBhQfAQcGFBcWMjchNzY0LwEmIgcGFB8BBwYUFxYyNwJJ1Q0N1Q0jDA0Nt7cNDQwjDf7V1Q0N1QwkDA0Nt7cNDQwkDLfWDCMN1Q0NDCQMt7gMIw0MDNYMIw3VDQ0MJAy3uAwjDQwMAAADAFUAAAOrA1UAMwBoAHcAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMhMjY1NCYjISIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAAVYRGRkR/qoRGRkRA1UFBAUOCQkVDAsZDf2rDRkLDBUJCA4FBQUFBQUOCQgVDAsZDQJVDRkLDBUJCQ4FBAVVAgECBQMCBwQECAX9qwQJAwQHAwMFAQICAgIBBQMDBwQDCQQCVQUIBAQHAgMFAgEC/oAZEhEZGRESGQAAAAADAFUAAAOrA1UAMwBoAIkAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMzFRQWMzI2PQEzMjY1NCYrATU0JiMiBh0BIyIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAgBkSEhmAERkZEYAZEhIZgBEZGREDVQUEBQ4JCRUMCxkN/asNGQsMFQkIDgUFBQUFBQ4JCBUMCxkNAlUNGQsMFQkJDgUEBVUCAQIFAwIHBAQIBf2rBAkDBAcDAwUBAgICAgEFAwMHBAMJBAJVBQgEBAcCAwUCAQL+gIASGRkSgBkSERmAEhkZEoAZERIZAAABAOIAjQMeAskAIAAAExcHBhQXFjI/ARcWMjc2NC8BNzY0JyYiDwEnJiIHBhQX4uLiDQ0MJAzi4gwkDA0N4uINDQwkDOLiDCQMDQ0CjeLiDSMMDQ3h4Q0NDCMN4uIMIw0MDOLiDAwNIwwAAAABAAAAAQAAa5n0y18PPPUACwQAAAAAANivOVsAAAAA2K85WwAAAAADqwNVAAAACAACAAAAAAAAAAEAAAPA/8AAAAQAAAAAAAOrAAEAAAAAAAAAAAAAAAAAAAALBAAAAAAAAAAAAAAAAgAAAAQAAWIEAAFiBAAA4gQAAOIEAABVBAAAVQQAAOIAAAAAAAoAFAAeAEQAagCqAOoBngJkApoAAQAAAAsAigADAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAA4ArgABAAAAAAABAAcAAAABAAAAAAACAAcAYAABAAAAAAADAAcANgABAAAAAAAEAAcAdQABAAAAAAAFAAsAFQABAAAAAAAGAAcASwABAAAAAAAKABoAigADAAEECQABAA4ABwADAAEECQACAA4AZwADAAEECQADAA4APQADAAEECQAEAA4AfAADAAEECQAFABYAIAADAAEECQAGAA4AUgADAAEECQAKADQApGZjaWNvbnMAZgBjAGkAYwBvAG4Ac1ZlcnNpb24gMS4wAFYAZQByAHMAaQBvAG4AIAAxAC4AMGZjaWNvbnMAZgBjAGkAYwBvAG4Ac2ZjaWNvbnMAZgBjAGkAYwBvAG4Ac1JlZ3VsYXIAUgBlAGcAdQBsAGEAcmZjaWNvbnMAZgBjAGkAYwBvAG4Ac0ZvbnQgZ2VuZXJhdGVkIGJ5IEljb01vb24uAEYAbwBuAHQAIABnAGUAbgBlAHIAYQB0AGUAZAAgAGIAeQAgAEkAYwBvAE0AbwBvAG4ALgAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=\") format(\"truetype\")}.fc-icon{speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;display:inline-block;font-family:fcicons!important;font-style:normal;font-variant:normal;font-weight:400;height:1em;line-height:1;text-align:center;text-transform:none;-moz-user-select:none;user-select:none;width:1em}.fc-icon-chevron-left:before{content:\"\\e900\"}.fc-icon-chevron-right:before{content:\"\\e901\"}.fc-icon-chevrons-left:before{content:\"\\e902\"}.fc-icon-chevrons-right:before{content:\"\\e903\"}.fc-icon-minus-square:before{content:\"\\e904\"}.fc-icon-plus-square:before{content:\"\\e905\"}.fc-icon-x:before{content:\"\\e906\"}.fc-button{border-radius:0;font-family:inherit;font-size:inherit;line-height:inherit;margin:0;overflow:visible;text-transform:none}.fc-button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}.fc-button{-webkit-appearance:button}.fc-button:not(:disabled){cursor:pointer}.fc-button{background-color:transparent;border:1px solid transparent;border-radius:.25em;display:inline-block;font-size:1em;font-weight:400;line-height:1.5;padding:.4em .65em;text-align:center;-moz-user-select:none;user-select:none;vertical-align:middle}.fc-button:hover{text-decoration:none}.fc-button:focus{box-shadow:0 0 0 .2rem rgba(44,62,80,.25);outline:0}.fc-button:disabled{opacity:.65}.fc-button-primary{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc-button-primary:hover{background-color:var(--fc-button-hover-bg-color);border-color:var(--fc-button-hover-border-color);color:var(--fc-button-text-color)}.fc-button-primary:disabled{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc-button-primary:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc-button-primary:not(:disabled).fc-button-active,.fc-button-primary:not(:disabled):active{background-color:var(--fc-button-active-bg-color);border-color:var(--fc-button-active-border-color);color:var(--fc-button-text-color)}.fc-button-primary:not(:disabled).fc-button-active:focus,.fc-button-primary:not(:disabled):active:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc-button .fc-icon{font-size:1.5em;vertical-align:middle}.fc-button-group{display:inline-flex;position:relative;vertical-align:middle}.fc-button-group>.fc-button{flex:1 1 auto;position:relative}.fc-button-group>.fc-button.fc-button-active,.fc-button-group>.fc-button:active,.fc-button-group>.fc-button:focus,.fc-button-group>.fc-button:hover{z-index:1}.fc-direction-ltr .fc-button-group>.fc-button:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0;margin-left:-1px}.fc-direction-ltr .fc-button-group>.fc-button:not(:last-child){border-bottom-right-radius:0;border-top-right-radius:0}.fc-direction-rtl .fc-button-group>.fc-button:not(:first-child){border-bottom-right-radius:0;border-top-right-radius:0;margin-right:-1px}.fc-direction-rtl .fc-button-group>.fc-button:not(:last-child){border-bottom-left-radius:0;border-top-left-radius:0}.fc-toolbar{align-items:center;justify-content:space-between}.fc-toolbar,.fc-toolbar-section{display:flex;flex-direction:row;gap:.75em}.fc-toolbar-section{flex-shrink:0}.fc-toolbar-title{font-size:1.75em;font-weight:700;white-space:nowrap}";
|
|
90
90
|
injectStyles(css_248z);
|
|
91
91
|
|
|
92
|
-
function removeElement(el) {
|
|
93
|
-
if (el.parentNode) {
|
|
94
|
-
el.parentNode.removeChild(el);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
// Querying
|
|
98
|
-
// ----------------------------------------------------------------------------------------------------------------
|
|
99
|
-
function elementClosest(el, selector) {
|
|
100
|
-
if (el.closest) {
|
|
101
|
-
return el.closest(selector);
|
|
102
|
-
// really bad fallback for IE
|
|
103
|
-
// from https://developer.mozilla.org/en-US/docs/Web/API/Element/closest
|
|
104
|
-
}
|
|
105
|
-
if (!document.documentElement.contains(el)) {
|
|
106
|
-
return null;
|
|
107
|
-
}
|
|
108
|
-
do {
|
|
109
|
-
if (elementMatches(el, selector)) {
|
|
110
|
-
return el;
|
|
111
|
-
}
|
|
112
|
-
el = (el.parentElement || el.parentNode);
|
|
113
|
-
} while (el !== null && el.nodeType === 1);
|
|
114
|
-
return null;
|
|
115
|
-
}
|
|
116
|
-
function elementMatches(el, selector) {
|
|
117
|
-
let method = el.matches || el.matchesSelector || el.msMatchesSelector;
|
|
118
|
-
return method.call(el, selector);
|
|
119
|
-
}
|
|
120
|
-
// accepts multiple subject els
|
|
121
|
-
// returns a real array. good for methods like forEach
|
|
122
|
-
// TODO: accept the document
|
|
123
|
-
function findElements(container, selector) {
|
|
124
|
-
let containers = container instanceof HTMLElement ? [container] : container;
|
|
125
|
-
let allMatches = [];
|
|
126
|
-
for (let i = 0; i < containers.length; i += 1) {
|
|
127
|
-
let matches = containers[i].querySelectorAll(selector);
|
|
128
|
-
for (let j = 0; j < matches.length; j += 1) {
|
|
129
|
-
allMatches.push(matches[j]);
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
return allMatches;
|
|
133
|
-
}
|
|
134
|
-
// accepts multiple subject els
|
|
135
|
-
// only queries direct child elements // TODO: rename to findDirectChildren!
|
|
136
|
-
function findDirectChildren(parent, selector) {
|
|
137
|
-
let parents = parent instanceof HTMLElement ? [parent] : parent;
|
|
138
|
-
let allMatches = [];
|
|
139
|
-
for (let i = 0; i < parents.length; i += 1) {
|
|
140
|
-
let childNodes = parents[i].children; // only ever elements
|
|
141
|
-
for (let j = 0; j < childNodes.length; j += 1) {
|
|
142
|
-
let childNode = childNodes[j];
|
|
143
|
-
if (!selector || elementMatches(childNode, selector)) {
|
|
144
|
-
allMatches.push(childNode);
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
return allMatches;
|
|
149
|
-
}
|
|
150
|
-
// Style
|
|
151
|
-
// ----------------------------------------------------------------------------------------------------------------
|
|
152
|
-
const PIXEL_PROP_RE = /(top|left|right|bottom|width|height)$/i;
|
|
153
|
-
function applyStyle(el, props) {
|
|
154
|
-
for (let propName in props) {
|
|
155
|
-
applyStyleProp(el, propName, props[propName]);
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
function applyStyleProp(el, name, val) {
|
|
159
|
-
if (val == null) {
|
|
160
|
-
el.style[name] = '';
|
|
161
|
-
}
|
|
162
|
-
else if (typeof val === 'number' && PIXEL_PROP_RE.test(name)) {
|
|
163
|
-
el.style[name] = `${val}px`;
|
|
164
|
-
}
|
|
165
|
-
else {
|
|
166
|
-
el.style[name] = val;
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
// Event Handling
|
|
170
|
-
// ----------------------------------------------------------------------------------------------------------------
|
|
171
|
-
// if intercepting bubbled events at the document/window/body level,
|
|
172
|
-
// and want to see originating element (the 'target'), use this util instead
|
|
173
|
-
// of `ev.target` because it goes within web-component boundaries.
|
|
174
|
-
function getEventTargetViaRoot(ev) {
|
|
175
|
-
var _a, _b;
|
|
176
|
-
return (_b = (_a = ev.composedPath) === null || _a === void 0 ? void 0 : _a.call(ev)[0]) !== null && _b !== void 0 ? _b : ev.target;
|
|
177
|
-
}
|
|
178
|
-
// Unique ID for DOM attribute
|
|
179
|
-
let guid$1 = 0;
|
|
180
|
-
function getUniqueDomId() {
|
|
181
|
-
guid$1 += 1;
|
|
182
|
-
return 'fc-dom-' + guid$1;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
92
|
// Stops a mouse/touch event from doing it's native browser action
|
|
186
93
|
function preventDefault(ev) {
|
|
187
94
|
ev.preventDefault();
|
|
@@ -190,7 +97,7 @@ var FullCalendar = (function (exports) {
|
|
|
190
97
|
// ----------------------------------------------------------------------------------------------------------------
|
|
191
98
|
function buildDelegationHandler(selector, handler) {
|
|
192
99
|
return (ev) => {
|
|
193
|
-
let matchedChild =
|
|
100
|
+
let matchedChild = ev.target.closest(selector);
|
|
194
101
|
if (matchedChild) {
|
|
195
102
|
handler.call(matchedChild, ev, matchedChild);
|
|
196
103
|
}
|
|
@@ -258,7 +165,7 @@ var FullCalendar = (function (exports) {
|
|
|
258
165
|
}
|
|
259
166
|
|
|
260
167
|
let guidNumber = 0;
|
|
261
|
-
function guid() {
|
|
168
|
+
function guid$1() {
|
|
262
169
|
guidNumber += 1;
|
|
263
170
|
return String(guidNumber);
|
|
264
171
|
}
|
|
@@ -1449,6 +1356,7 @@ var FullCalendar = (function (exports) {
|
|
|
1449
1356
|
dropAccept: identity,
|
|
1450
1357
|
eventOrder: parseFieldSpecs,
|
|
1451
1358
|
eventOrderStrict: Boolean,
|
|
1359
|
+
eventSlicing: Boolean,
|
|
1452
1360
|
longPressDelay: Number,
|
|
1453
1361
|
eventDragMinDistance: Number,
|
|
1454
1362
|
expandRows: Boolean,
|
|
@@ -1509,6 +1417,7 @@ var FullCalendar = (function (exports) {
|
|
|
1509
1417
|
allDayContent: identity,
|
|
1510
1418
|
allDayDidMount: identity,
|
|
1511
1419
|
allDayWillUnmount: identity,
|
|
1420
|
+
timedText: String,
|
|
1512
1421
|
slotMinWidth: Number,
|
|
1513
1422
|
navLinks: Boolean,
|
|
1514
1423
|
eventTimeFormat: createFormatter,
|
|
@@ -1539,10 +1448,11 @@ var FullCalendar = (function (exports) {
|
|
|
1539
1448
|
// only used by list-view, but languages define the value, so we need it in base options
|
|
1540
1449
|
noEventsText: String,
|
|
1541
1450
|
viewHint: identity,
|
|
1451
|
+
viewChangeHint: String,
|
|
1542
1452
|
navLinkHint: identity,
|
|
1543
1453
|
closeHint: String,
|
|
1544
|
-
|
|
1545
|
-
|
|
1454
|
+
eventsHint: String,
|
|
1455
|
+
headingLevel: Number,
|
|
1546
1456
|
moreLinkClick: identity,
|
|
1547
1457
|
moreLinkClassNames: identity,
|
|
1548
1458
|
moreLinkContent: identity,
|
|
@@ -1607,6 +1517,7 @@ var FullCalendar = (function (exports) {
|
|
|
1607
1517
|
eventMinWidth: 30,
|
|
1608
1518
|
eventShortHeight: 30,
|
|
1609
1519
|
monthStartFormat: { month: 'long', day: 'numeric' },
|
|
1520
|
+
headingLevel: 2, // like H2
|
|
1610
1521
|
};
|
|
1611
1522
|
// calendar listeners
|
|
1612
1523
|
// ------------------
|
|
@@ -1705,7 +1616,7 @@ var FullCalendar = (function (exports) {
|
|
|
1705
1616
|
|
|
1706
1617
|
function createEventInstance(defId, range, forcedStartTzo, forcedEndTzo) {
|
|
1707
1618
|
return {
|
|
1708
|
-
instanceId: guid(),
|
|
1619
|
+
instanceId: guid$1(),
|
|
1709
1620
|
defId,
|
|
1710
1621
|
range,
|
|
1711
1622
|
forcedStartTzo: forcedStartTzo == null ? null : forcedStartTzo,
|
|
@@ -1868,6 +1779,9 @@ var FullCalendar = (function (exports) {
|
|
|
1868
1779
|
return null;
|
|
1869
1780
|
}
|
|
1870
1781
|
|
|
1782
|
+
function joinClassNames(...args) {
|
|
1783
|
+
return args.filter(Boolean).join(' ');
|
|
1784
|
+
}
|
|
1871
1785
|
function parseClassNames(raw) {
|
|
1872
1786
|
if (Array.isArray(raw)) {
|
|
1873
1787
|
return raw;
|
|
@@ -2000,7 +1914,7 @@ var FullCalendar = (function (exports) {
|
|
|
2000
1914
|
publicId: refined.id || '',
|
|
2001
1915
|
url: refined.url || '',
|
|
2002
1916
|
recurringDef: null,
|
|
2003
|
-
defId: ((defIdMap && refined.id) ? defIdMap[refined.id] : '') || guid(),
|
|
1917
|
+
defId: ((defIdMap && refined.id) ? defIdMap[refined.id] : '') || guid$1(),
|
|
2004
1918
|
sourceId,
|
|
2005
1919
|
allDay,
|
|
2006
1920
|
hasEnd,
|
|
@@ -2151,11 +2065,6 @@ var FullCalendar = (function (exports) {
|
|
|
2151
2065
|
}
|
|
2152
2066
|
return { start: startDay, end: endDay };
|
|
2153
2067
|
}
|
|
2154
|
-
// spans from one day into another?
|
|
2155
|
-
function isMultiDayRange(range) {
|
|
2156
|
-
let visibleRange = computeVisibleDayRange(range);
|
|
2157
|
-
return diffDays(visibleRange.start, visibleRange.end) > 1;
|
|
2158
|
-
}
|
|
2159
2068
|
function diffDates(date0, date1, dateEnv, largeUnit) {
|
|
2160
2069
|
if (largeUnit === 'year') {
|
|
2161
2070
|
return createDuration(dateEnv.diffWholeYears(date0, date1), 'year');
|
|
@@ -2215,6 +2124,41 @@ var FullCalendar = (function (exports) {
|
|
|
2215
2124
|
};
|
|
2216
2125
|
}
|
|
2217
2126
|
|
|
2127
|
+
// Style
|
|
2128
|
+
// ----------------------------------------------------------------------------------------------------------------
|
|
2129
|
+
const PIXEL_PROP_RE = /(top|left|right|bottom|width|height)$/i;
|
|
2130
|
+
function applyStyle(el, props) {
|
|
2131
|
+
for (let propName in props) {
|
|
2132
|
+
applyStyleProp(el, propName, props[propName]);
|
|
2133
|
+
}
|
|
2134
|
+
}
|
|
2135
|
+
function applyStyleProp(el, name, val) {
|
|
2136
|
+
if (val == null) {
|
|
2137
|
+
el.style[name] = '';
|
|
2138
|
+
}
|
|
2139
|
+
else if (typeof val === 'number' && PIXEL_PROP_RE.test(name)) {
|
|
2140
|
+
el.style[name] = `${val}px`;
|
|
2141
|
+
}
|
|
2142
|
+
else {
|
|
2143
|
+
el.style[name] = val;
|
|
2144
|
+
}
|
|
2145
|
+
}
|
|
2146
|
+
// Event Handling
|
|
2147
|
+
// ----------------------------------------------------------------------------------------------------------------
|
|
2148
|
+
// if intercepting bubbled events at the document/window/body level,
|
|
2149
|
+
// and want to see originating element (the 'target'), use this util instead
|
|
2150
|
+
// of `ev.target` because it goes within web-component boundaries.
|
|
2151
|
+
function getEventTargetViaRoot(ev) {
|
|
2152
|
+
var _a, _b;
|
|
2153
|
+
return (_b = (_a = ev.composedPath) === null || _a === void 0 ? void 0 : _a.call(ev)[0]) !== null && _b !== void 0 ? _b : ev.target;
|
|
2154
|
+
}
|
|
2155
|
+
// Unique ID for DOM attribute
|
|
2156
|
+
let guid = 0;
|
|
2157
|
+
function getUniqueDomId() {
|
|
2158
|
+
guid += 1;
|
|
2159
|
+
return 'fc-dom-' + guid;
|
|
2160
|
+
}
|
|
2161
|
+
|
|
2218
2162
|
const EMPTY_EVENT_STORE = createEmptyEventStore(); // for purecomponents. TODO: keep elsewhere
|
|
2219
2163
|
class Splitter {
|
|
2220
2164
|
constructor() {
|
|
@@ -2450,172 +2394,418 @@ var FullCalendar = (function (exports) {
|
|
|
2450
2394
|
isFuture: Boolean(nowDate ? (date > nowDate) : todayRange ? (date >= todayRange.end) : false),
|
|
2451
2395
|
};
|
|
2452
2396
|
}
|
|
2453
|
-
function
|
|
2454
|
-
|
|
2455
|
-
'fc-day'
|
|
2456
|
-
`fc-day-${DAY_IDS[meta.dow]}`,
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2397
|
+
function getDayClassName(meta) {
|
|
2398
|
+
return joinClassNames('fc-day', meta.isDisabled
|
|
2399
|
+
? 'fc-day-disabled'
|
|
2400
|
+
: joinClassNames(`fc-day-${DAY_IDS[meta.dow]}`, meta.isToday && 'fc-day-today', meta.isPast && 'fc-day-past', meta.isFuture && 'fc-day-future', meta.isOther && 'fc-day-other'));
|
|
2401
|
+
}
|
|
2402
|
+
function getSlotClassName(meta) {
|
|
2403
|
+
return joinClassNames('fc-slot', meta.isDisabled
|
|
2404
|
+
? 'fc-slot-disabled'
|
|
2405
|
+
: joinClassNames(`fc-slot-${DAY_IDS[meta.dow]}`, meta.isToday && 'fc-slot-today', meta.isPast && 'fc-slot-past', meta.isFuture && 'fc-slot-future'));
|
|
2406
|
+
}
|
|
2407
|
+
|
|
2408
|
+
function isDimsEqual(v0, v1) {
|
|
2409
|
+
return v0 != null && (v0 === v1 || Math.abs(v0 - v1) < 0.01);
|
|
2410
|
+
}
|
|
2411
|
+
|
|
2412
|
+
var n,l$1,u$1,t,i$1,o,r$1,f$1,e$1,c$1,s$1,a$1,h={},p=[],v$1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w$1(n){var l=n.parentNode;l&&l.removeChild(n);}function _(l,u,t){var i,o,r,f={};for(r in u)"key"==r?i=u[r]:"ref"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),"function"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g$1(l,f,i,o,null)}function g$1(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u$1:r,__i:-1,__u:0};return null==r&&null!=l$1.vnode&&l$1.vnode(f),f}function m$1(){return {current:null}}function k$1(n){return n.children}function b(n,l){this.props=n,this.context=l;}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return "function"==typeof n.type?x(n):null}function C$1(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C$1(n)}}function M$1(n){(!n.__d&&(n.__d=!0)&&i$1.push(n)&&!P$1.__r++||o!==l$1.debounceRendering)&&((o=l$1.debounceRendering)||r$1)(P$1);}function P$1(){var n,u,t,o,r,e,c,s;for(i$1.sort(f$1);n=i$1.shift();)n.__d&&(u=i$1.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l$1.vnode&&l$1.vnode(o),O$1(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j$2(c,o,s),o.__e!=e&&C$1(o)),i$1.length>u&&i$1.sort(f$1));P$1.__r=0;}function S(n,l,u,t,i,o,r,f,e,c,s){var a,v,y,d,w,_=t&&t.__k||p,g=l.length;for(u.__d=e,$$1(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&"boolean"!=typeof y&&"function"!=typeof y&&(v=-1===y.__i?h:_[y.__i]||h,y.__i=a,O$1(n,y,v,i,o,r,f,e,c,s),d=y.__e,y.ref&&v.ref!=y.ref&&(v.ref&&N(v.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||v.__k===y.__k?e=I(y,e,n):"function"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w;}function $$1(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)r=t+a,null!=(i=n.__k[t]=null==(i=l[t])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?g$1(null,i,null,null,null):y(i)?g$1(k$1,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g$1(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=n,i.__b=n.__b+1,f=L$1(i,u,r,s),i.__i=f,o=null,-1!==f&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,"function"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a=f-r:f==r+1?a++:f>r?s>e-r?a+=f-r:a--:f<r&&a++,f!==t+a&&(i.__u|=65536))):(o=u[r])&&null==o.key&&o.__e&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V$1(o,o,!1),u[r]=null,s--);if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V$1(o,o));}function I(n,l,u){var t,i;if("function"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling;}while(null!=l&&8===l.nodeType);return l}function H$1(n,l){return l=l||[],null==n||"boolean"==typeof n||(y(n)?n.some(function(n){H$1(n,l);}):l.push(n)),l}function L$1(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--;}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++;}}return -1}function T$1(n,l,u){"-"===l[0]?n.setProperty(l,null==u?"":u):n[l]=null==u?"":"number"!=typeof u||v$1.test(l)?u:u+"px";}function A$1(n,l,u,t,i){var o;n:if("style"===l)if("string"==typeof u)n.style.cssText=u;else {if("string"==typeof t&&(n.style.cssText=t=""),t)for(l in t)u&&l in u||T$1(n.style,l,"");if(u)for(l in u)t&&u[l]===t[l]||T$1(n.style,l,u[l]);}else if("o"===l[0]&&"n"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,"$1")),l=l.toLowerCase()in n||"onFocusOut"===l||"onFocusIn"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e$1,n.addEventListener(l,o?s$1:c$1,o)):n.removeEventListener(l,o?s$1:c$1,o);else {if("http://www.w3.org/2000/svg"==i)l=l.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=l&&"height"!=l&&"href"!=l&&"list"!=l&&"form"!=l&&"tabIndex"!=l&&"download"!=l&&"rowSpan"!=l&&"colSpan"!=l&&"role"!=l&&"popover"!=l&&l in n)try{n[l]=null==u?"":u;break n}catch(n){}"function"==typeof u||(null==u||!1===u&&"-"!==l[4]?n.removeAttribute(l):n.setAttribute(l,"popover"==l&&1==u?"":u));}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e$1++;else if(u.t<t.u)return;return t(l$1.event?l$1.event(u):u)}}}function O$1(n,u,t,i,o,r,f,e,c,s){var a,h,p,v,w,_,g,m,x,C,M,P,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l$1.__b)&&a(u);n:if("function"==typeof T)try{if(m=u.props,x="prototype"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],M=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,M):(u.__c=h=new b(m,M),h.constructor=T,h.render=q),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=M,h.__n=i,p=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),v=h.props,w=h.state,h.__v=u,p)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else {if(x&&null==T.getDerivedStateFromProps&&m!==v&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,M),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,M)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.forEach(function(n){n&&(n.__=u);}),P=0;P<h._sb.length;P++)h.__h.push(h._sb[P]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,M),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(v,w,_);});}if(h.context=M,h.props=m,h.__P=n,h.__e=!1,$=l$1.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[];}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s;}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!p&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(v,w)),S(n,y(L=null!=a&&a.type===k$1&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null);}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:32;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e;}else u.__e=t.__e,u.__k=t.__k;l$1.__e(n,u,t);}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z$2(t.__e,u,t,i,o,r,f,c,s);(a=l$1.diffed)&&a(u);}function j$2(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l$1.__c&&l$1.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u);});}catch(n){l$1.__e(n,u.__v);}});}function z$2(l,u,t,i,o,r,f,e,c){var s,a,p,v,d,_,g,m=t.props,k=u.props,b=u.type;if("svg"===b?o="http://www.w3.org/2000/svg":"math"===b?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),null!=r)for(s=0;s<r.length;s++)if((d=r[s])&&"setAttribute"in d==!!b&&(b?d.localName===b:3===d.nodeType)){l=d,r[s]=null;break}if(null==l){if(null===b)return document.createTextNode(k);l=document.createElementNS(o,b,k.is&&k),r=null,e=!1;}if(null===b)m===k||e&&l.data===k||(l.data=k);else {if(r=r&&n.call(l.childNodes),m=t.props||h,!e&&null!=r)for(m={},s=0;s<l.attributes.length;s++)m[(d=l.attributes[s]).name]=d.value;for(s in m)if(d=m[s],"children"==s);else if("dangerouslySetInnerHTML"==s)p=d;else if("key"!==s&&!(s in k)){if("value"==s&&"defaultValue"in k||"checked"==s&&"defaultChecked"in k)continue;A$1(l,s,null,d,o);}for(s in k)d=k[s],"children"==s?v=d:"dangerouslySetInnerHTML"==s?a=d:"value"==s?_=d:"checked"==s?g=d:"key"===s||e&&"function"!=typeof d||m[s]===d||A$1(l,s,d,m[s],o);if(a)e||p&&(a.__html===p.__html||a.__html===l.innerHTML)||(l.innerHTML=a.__html),u.__k=[];else if(p&&(l.innerHTML=""),S(l,y(v)?v:[v],u,t,i,"foreignObject"===b?"http://www.w3.org/1999/xhtml":o,r,f,r?r[0]:t.__k&&x(t,0),e,c),null!=r)for(s=r.length;s--;)null!=r[s]&&w$1(r[s]);e||(s="value",void 0!==_&&(_!==l[s]||"progress"===b&&!_||"option"===b&&_!==m[s])&&A$1(l,s,_,m[s],o),s="checked",void 0!==g&&g!==l[s]&&A$1(l,s,g,m[s],o));}return l}function N(n,u,t){try{if("function"==typeof n){var i="function"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u));}else n.current=u;}catch(n){l$1.__e(n,t);}}function V$1(n,u,t){var i,o;if(l$1.unmount&&l$1.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount();}catch(n){l$1.__e(n,u);}i.base=i.__P=null;}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&V$1(i[o],u,t||"function"!=typeof n.type);t||null==n.__e||w$1(n.__e),n.__c=n.__=n.__e=n.__d=void 0;}function q(n,l,u){return this.constructor(n,u)}function B$2(u,t,i){var o,r,f,e;l$1.__&&l$1.__(u,t),r=(o="function"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O$1(t,u=(!o&&i||t).__k=_(k$1,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j$2(f,u,e);}function D$1(n,l){B$2(n,l,D$1);}function E$1(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)"key"==r?i=u[r]:"ref"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g$1(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l="__cC"+a$1++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null;},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,M$1(n);});},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.splice(u.indexOf(n),1),l&&l.call(n);};}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=p.slice,l$1={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l;}throw n}},u$1=0,t=function(n){return null!=n&&null==n.constructor},b.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),"function"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),M$1(this));},b.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),M$1(this));},b.prototype.render=k$1,i$1=[],r$1="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f$1=function(n,l){return n.__v.__b-l.__v.__b},P$1.__r=0,e$1=0,c$1=F(!1),s$1=F(!0),a$1=0;
|
|
2413
|
+
|
|
2414
|
+
var r,u,i,f=[],c=l$1,e=c.__b,a=c.__r,v=c.diffed,l=c.__c,m=c.unmount,s=c.__;function j$1(){for(var n;n=f.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(z$1),n.__H.__h.forEach(B$1),n.__H.__h=[];}catch(t){n.__H.__h=[],c.__e(t,n.__v);}}c.__b=function(n){r=null,e&&e(n);},c.__=function(n,t){n&&t.__k&&t.__k.__m&&(n.__m=t.__k.__m),s&&s(n,t);},c.__r=function(n){a&&a(n);var i=(r=n.__c).__H;i&&(u===r?(i.__h=[],r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.i=n.__N=void 0;})):(i.__h.forEach(z$1),i.__h.forEach(B$1),i.__h=[],0)),u=r;},c.diffed=function(n){v&&v(n);var t=n.__c;t&&t.__H&&(t.__H.__h.length&&(1!==f.push(t)&&i===c.requestAnimationFrame||((i=c.requestAnimationFrame)||w)(j$1)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.i=void 0;})),u=r=null;},c.__c=function(n,t){t.some(function(n){try{n.__h.forEach(z$1),n.__h=n.__h.filter(function(n){return !n.__||B$1(n)});}catch(r){t.some(function(n){n.__h&&(n.__h=[]);}),t=[],c.__e(r,n.__v);}}),l&&l(n,t);},c.unmount=function(n){m&&m(n);var t,r=n.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{z$1(n);}catch(n){t=n;}}),r.__H=void 0,t&&c.__e(t,r.__v));};var k="function"==typeof requestAnimationFrame;function w(n){var t,r=function(){clearTimeout(u),k&&cancelAnimationFrame(t),setTimeout(n);},u=setTimeout(r,100);k&&(t=requestAnimationFrame(r));}function z$1(n){var t=r,u=n.__c;"function"==typeof u&&(n.__c=void 0,u()),r=t;}function B$1(n){var t=r;n.__c=n.__(),r=t;}
|
|
2415
|
+
|
|
2416
|
+
function g(n,t){for(var e in t)n[e]=t[e];return n}function E(n,t){for(var e in n)if("__source"!==e&&!(e in t))return !0;for(var r in t)if("__source"!==r&&n[r]!==t[r])return !0;return !1}function C(n,t){this.props=n,this.context=t;}(C.prototype=new b).isPureReactComponent=!0,C.prototype.shouldComponentUpdate=function(n,t){return E(this.props,n)||E(this.state,t)};var R=l$1.__b;l$1.__b=function(n){n.type&&n.type.__f&&n.ref&&(n.props.ref=n.ref,n.ref=null),R&&R(n);};var M=l$1.__e;l$1.__e=function(n,t,e,r){if(n.then)for(var u,o=t;o=o.__;)if((u=o.__c)&&u.__c)return null==t.__e&&(t.__e=e.__e,t.__k=e.__k),u.__c(n,t);M(n,t,e,r);};var T=l$1.unmount;function A(n,t,e){return n&&(n.__c&&n.__c.__H&&(n.__c.__H.__.forEach(function(n){"function"==typeof n.__c&&n.__c();}),n.__c.__H=null),null!=(n=g({},n)).__c&&(n.__c.__P===e&&(n.__c.__P=t),n.__c=null),n.__k=n.__k&&n.__k.map(function(n){return A(n,t,e)})),n}function D(n,t,e){return n&&e&&(n.__v=null,n.__k=n.__k&&n.__k.map(function(n){return D(n,t,e)}),n.__c&&n.__c.__P===t&&(n.__e&&e.appendChild(n.__e),n.__c.__e=!0,n.__c.__P=e)),n}function L(){this.__u=0,this.t=null,this.__b=null;}function O(n){var t=n.__.__c;return t&&t.__a&&t.__a(n)}function U(){this.u=null,this.o=null;}l$1.unmount=function(n){var t=n.__c;t&&t.__R&&t.__R(),t&&32&n.__u&&(n.type=null),T&&T(n);},(L.prototype=new b).__c=function(n,t){var e=t.__c,r=this;null==r.t&&(r.t=[]),r.t.push(e);var u=O(r.__v),o=!1,i=function(){o||(o=!0,e.__R=null,u?u(c):c());};e.__R=i;var c=function(){if(!--r.__u){if(r.state.__a){var n=r.state.__a;r.__v.__k[0]=D(n,n.__c.__P,n.__c.__O);}var t;for(r.setState({__a:r.__b=null});t=r.t.pop();)t.forceUpdate();}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),n.then(i,i);},L.prototype.componentWillUnmount=function(){this.t=[];},L.prototype.render=function(n,e){if(this.__b){if(this.__v.__k){var r=document.createElement("div"),o=this.__v.__k[0].__c;this.__v.__k[0]=A(this.__b,r,o.__O=o.__P);}this.__b=null;}var i=e.__a&&_(k$1,null,n.fallback);return i&&(i.__u&=-33),[_(k$1,null,e.__a?null:n.children),i]};var V=function(n,t,e){if(++e[1]===e[0]&&n.o.delete(t),n.props.revealOrder&&("t"!==n.props.revealOrder[0]||!n.o.size))for(e=n.u;e;){for(;e.length>3;)e.pop()();if(e[1]<e[0])break;n.u=e=e[2];}};function W(n){return this.getChildContext=function(){return n.context},n.children}function P(n){var e=this,r=n.i;e.componentWillUnmount=function(){B$2(null,e.l),e.l=null,e.i=null;},e.i&&e.i!==r&&e.componentWillUnmount(),e.l||(e.i=r,e.l={nodeType:1,parentNode:r,childNodes:[],contains:function(){return !0},appendChild:function(n){this.childNodes.push(n),e.i.appendChild(n);},insertBefore:function(n,t){this.childNodes.push(n),e.i.appendChild(n);},removeChild:function(n){this.childNodes.splice(this.childNodes.indexOf(n)>>>1,1),e.i.removeChild(n);}}),B$2(_(W,{context:e.context},n.__v),e.l);}function j(n,e){var r=_(P,{__v:n,i:e});return r.containerInfo=e,r}(U.prototype=new b).__a=function(n){var t=this,e=O(t.__v),r=t.o.get(n);return r[0]++,function(u){var o=function(){t.props.revealOrder?(r.push(u),V(t,n,r)):u();};e?e(o):o();}},U.prototype.render=function(n){this.u=null,this.o=new Map;var t=H$1(n.children);n.revealOrder&&"b"===n.revealOrder[0]&&t.reverse();for(var e=t.length;e--;)this.o.set(t[e],this.u=[1,0,this.u]);return n.children},U.prototype.componentDidUpdate=U.prototype.componentDidMount=function(){var n=this;this.o.forEach(function(t,e){V(n,e,t);});};var z="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,B=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,H=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,Z=/[A-Z0-9]/g,Y="undefined"!=typeof document,$=function(n){return ("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(n)};b.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(t){Object.defineProperty(b.prototype,t,{configurable:!0,get:function(){return this["UNSAFE_"+t]},set:function(n){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:n});}});});var J=l$1.event;function K(){}function Q(){return this.cancelBubble}function X(){return this.defaultPrevented}l$1.event=function(n){return J&&(n=J(n)),n.persist=K,n.isPropagationStopped=Q,n.isDefaultPrevented=X,n.nativeEvent=n};var tn={enumerable:!1,configurable:!0,get:function(){return this.class}},en=l$1.vnode;l$1.vnode=function(n){"string"==typeof n.type&&function(n){var t=n.props,e=n.type,u={};for(var o in t){var i=t[o];if(!("value"===o&&"defaultValue"in t&&null==i||Y&&"children"===o&&"noscript"===e||"class"===o||"className"===o)){var c=o.toLowerCase();"defaultValue"===o&&"value"in t&&null==t.value?o="value":"download"===o&&!0===i?i="":"translate"===c&&"no"===i?i=!1:"ondoubleclick"===c?o="ondblclick":"onchange"!==c||"input"!==e&&"textarea"!==e||$(t.type)?"onfocus"===c?o="onfocusin":"onblur"===c?o="onfocusout":H.test(o)?o=c:-1===e.indexOf("-")&&B.test(o)?o=o.replace(Z,"-$&").toLowerCase():null===i&&(i=void 0):c=o="oninput","oninput"===c&&u[o=c]&&(o="oninputCapture"),u[o]=i;}}"select"==e&&u.multiple&&Array.isArray(u.value)&&(u.value=H$1(t.children).forEach(function(n){n.props.selected=-1!=u.value.indexOf(n.props.value);})),"select"==e&&null!=u.defaultValue&&(u.value=H$1(t.children).forEach(function(n){n.props.selected=u.multiple?-1!=u.defaultValue.indexOf(n.props.value):u.defaultValue==n.props.value;})),t.class&&!t.className?(u.class=t.class,Object.defineProperty(u,"className",tn)):(t.className&&!t.class||t.class&&t.className)&&(u.class=u.className=t.className),n.props=u;}(n),n.$$typeof=z,en&&en(n);};var rn=l$1.__r;l$1.__r=function(n){rn&&rn(n),n.__c;};var un=l$1.diffed;l$1.diffed=function(n){un&&un(n);var t=n.props,e=n.__e;null!=e&&"textarea"===n.type&&"value"in t&&t.value!==e.value&&(e.value=null==t.value?"":t.value);};
|
|
2417
|
+
|
|
2418
|
+
/*
|
|
2419
|
+
NOTE: this can be a public API, especially createElement for hooks.
|
|
2420
|
+
See examples/typescript-scheduler/src/index.ts
|
|
2421
|
+
*/
|
|
2422
|
+
/*
|
|
2423
|
+
HACK for flushSync being a noop:
|
|
2424
|
+
https://github.com/preactjs/preact/issues/3929
|
|
2425
|
+
*/
|
|
2426
|
+
function flushSync(renderActionToFlush) {
|
|
2427
|
+
renderActionToFlush();
|
|
2428
|
+
let oldDebounceRendering = l$1.debounceRendering; // orig
|
|
2429
|
+
let callbackQ = [];
|
|
2430
|
+
function execCallbackSync(callback) {
|
|
2431
|
+
callbackQ.push(callback);
|
|
2460
2432
|
}
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2433
|
+
l$1.debounceRendering = execCallbackSync;
|
|
2434
|
+
B$2(_(FakeComponent, {}), document.createElement('div'));
|
|
2435
|
+
while (callbackQ.length) {
|
|
2436
|
+
callbackQ.shift()();
|
|
2437
|
+
}
|
|
2438
|
+
l$1.debounceRendering = oldDebounceRendering;
|
|
2439
|
+
}
|
|
2440
|
+
/*
|
|
2441
|
+
Triggers a state-change which unclogs the render queue? Needed?
|
|
2442
|
+
*/
|
|
2443
|
+
class FakeComponent extends b {
|
|
2444
|
+
render() { return _('div', {}); }
|
|
2445
|
+
componentDidMount() { this.setState({}); }
|
|
2446
|
+
}
|
|
2447
|
+
/*
|
|
2448
|
+
HACK for Preact wrongly calling shouldComponentUpdate during context changes:
|
|
2449
|
+
https://github.com/preactjs/preact/issues/2510
|
|
2450
|
+
*/
|
|
2451
|
+
function createContext(defaultValue) {
|
|
2452
|
+
let ContextType = G(defaultValue);
|
|
2453
|
+
let origProvider = ContextType.Provider;
|
|
2454
|
+
ContextType.Provider = function () {
|
|
2455
|
+
let isNew = !this.getChildContext;
|
|
2456
|
+
let children = origProvider.apply(this, arguments); // eslint-disable-line prefer-rest-params
|
|
2457
|
+
if (isNew) {
|
|
2458
|
+
let subs = [];
|
|
2459
|
+
this.shouldComponentUpdate = (_props) => {
|
|
2460
|
+
if (this.props.value !== _props.value) {
|
|
2461
|
+
subs.forEach((c) => {
|
|
2462
|
+
c.context = _props.value;
|
|
2463
|
+
c.forceUpdate();
|
|
2464
|
+
});
|
|
2465
|
+
}
|
|
2466
|
+
};
|
|
2467
|
+
this.sub = (c) => {
|
|
2468
|
+
subs.push(c);
|
|
2469
|
+
let old = c.componentWillUnmount;
|
|
2470
|
+
c.componentWillUnmount = () => {
|
|
2471
|
+
subs.splice(subs.indexOf(c), 1);
|
|
2472
|
+
old && old.call(c);
|
|
2473
|
+
};
|
|
2474
|
+
};
|
|
2464
2475
|
}
|
|
2465
|
-
|
|
2466
|
-
|
|
2476
|
+
return children;
|
|
2477
|
+
};
|
|
2478
|
+
return ContextType;
|
|
2479
|
+
}
|
|
2480
|
+
const preactOptions = l$1;
|
|
2481
|
+
|
|
2482
|
+
var preact = {
|
|
2483
|
+
__proto__: null,
|
|
2484
|
+
flushSync: flushSync,
|
|
2485
|
+
createContext: createContext,
|
|
2486
|
+
preactOptions: preactOptions,
|
|
2487
|
+
createPortal: j,
|
|
2488
|
+
Component: b,
|
|
2489
|
+
Fragment: k$1,
|
|
2490
|
+
cloneElement: E$1,
|
|
2491
|
+
createElement: _,
|
|
2492
|
+
createRef: m$1,
|
|
2493
|
+
h: _,
|
|
2494
|
+
hydrate: D$1,
|
|
2495
|
+
get isValidElement () { return t; },
|
|
2496
|
+
get options () { return l$1; },
|
|
2497
|
+
render: B$2,
|
|
2498
|
+
toChildArray: H$1
|
|
2499
|
+
};
|
|
2500
|
+
|
|
2501
|
+
const nativeBorderBoxEnabled = true;
|
|
2502
|
+
const fallbackTimeout = 100;
|
|
2503
|
+
const configMap = new Map();
|
|
2504
|
+
const afterSizeCallbacks = new Set();
|
|
2505
|
+
let isHandling = false; // utilized by both techniques
|
|
2506
|
+
function afterSize(callback) {
|
|
2507
|
+
if (isHandling) {
|
|
2508
|
+
afterSizeCallbacks.add(callback);
|
|
2509
|
+
}
|
|
2510
|
+
else {
|
|
2511
|
+
callback(); // TODO: should we queue microtask?
|
|
2512
|
+
}
|
|
2513
|
+
}
|
|
2514
|
+
function flushAfterSize() {
|
|
2515
|
+
for (const flushedCallback of afterSizeCallbacks.values()) {
|
|
2516
|
+
flushedCallback();
|
|
2517
|
+
afterSizeCallbacks.delete(flushedCallback);
|
|
2518
|
+
}
|
|
2519
|
+
}
|
|
2520
|
+
/*
|
|
2521
|
+
A proper ResizeObserver polyfill would keep checking dimensions until all stabilized,
|
|
2522
|
+
to detect if a *handler* caused a new element's dimensions to change,
|
|
2523
|
+
while ignoring changes per-element after the first (to prevent infinite loops),
|
|
2524
|
+
but our Preact system does not commit to the DOM immediately, commits are batched for later,
|
|
2525
|
+
so we can skip this.
|
|
2526
|
+
*/
|
|
2527
|
+
function checkConfigMap() {
|
|
2528
|
+
if (!isHandling) {
|
|
2529
|
+
isHandling = true;
|
|
2530
|
+
const dirtyConfigs = [];
|
|
2531
|
+
for (const [el, config] of configMap.entries()) {
|
|
2532
|
+
let width;
|
|
2533
|
+
let height;
|
|
2534
|
+
if (config.client) {
|
|
2535
|
+
width = el.clientWidth;
|
|
2536
|
+
height = el.clientHeight;
|
|
2537
|
+
}
|
|
2538
|
+
else {
|
|
2539
|
+
({ width, height } = el.getBoundingClientRect());
|
|
2540
|
+
}
|
|
2541
|
+
if (storeConfigDims(config, width, height)) {
|
|
2542
|
+
dirtyConfigs.push(config);
|
|
2543
|
+
}
|
|
2467
2544
|
}
|
|
2468
|
-
|
|
2469
|
-
|
|
2545
|
+
for (const dirtyConfig of dirtyConfigs) {
|
|
2546
|
+
dirtyConfig.callback(dirtyConfig.width, dirtyConfig.height);
|
|
2470
2547
|
}
|
|
2471
|
-
|
|
2472
|
-
|
|
2548
|
+
flushAfterSize();
|
|
2549
|
+
isHandling = false;
|
|
2550
|
+
}
|
|
2551
|
+
}
|
|
2552
|
+
function storeConfigDims(config, width, height) {
|
|
2553
|
+
let shouldFire = false;
|
|
2554
|
+
// we use it because ResizeObserver's results could be slightly off from getBoundingClientRect
|
|
2555
|
+
if (!isDimsEqual(config.width, width)) {
|
|
2556
|
+
config.width = width;
|
|
2557
|
+
shouldFire = config.watchWidth;
|
|
2558
|
+
}
|
|
2559
|
+
if (!isDimsEqual(config.height, height)) {
|
|
2560
|
+
config.height = height;
|
|
2561
|
+
shouldFire || (shouldFire = config.watchHeight);
|
|
2562
|
+
}
|
|
2563
|
+
return shouldFire;
|
|
2564
|
+
}
|
|
2565
|
+
// Native Technique ONLY
|
|
2566
|
+
// -------------------------------------------------------------------------------------------------
|
|
2567
|
+
function initNative() {
|
|
2568
|
+
// Single global ResizeObserver does batching and uses less memory than individuals
|
|
2569
|
+
// Will always fire with delay after DOM mutation, but before repaint,
|
|
2570
|
+
// thus doesn't need !isHandling check like checkConfigMap
|
|
2571
|
+
const globalResizeObserver = new ResizeObserver((entries) => {
|
|
2572
|
+
isHandling = true;
|
|
2573
|
+
for (let entry of entries) {
|
|
2574
|
+
const el = entry.target;
|
|
2575
|
+
const config = configMap.get(el);
|
|
2576
|
+
let width;
|
|
2577
|
+
let height;
|
|
2578
|
+
if (config.client) {
|
|
2579
|
+
width = el.clientWidth;
|
|
2580
|
+
height = el.clientHeight;
|
|
2581
|
+
}
|
|
2582
|
+
else if (entry.borderBoxSize && nativeBorderBoxEnabled) {
|
|
2583
|
+
const borderBoxSize = entry.borderBoxSize[0] || entry.borderBoxSize; // HACK for Firefox
|
|
2584
|
+
width = borderBoxSize.inlineSize;
|
|
2585
|
+
height = borderBoxSize.blockSize;
|
|
2586
|
+
}
|
|
2587
|
+
else {
|
|
2588
|
+
({ width, height } = el.getBoundingClientRect());
|
|
2589
|
+
}
|
|
2590
|
+
if (storeConfigDims(config, width, height)) {
|
|
2591
|
+
config.callback(width, height);
|
|
2592
|
+
}
|
|
2473
2593
|
}
|
|
2594
|
+
flushAfterSize();
|
|
2595
|
+
isHandling = false;
|
|
2596
|
+
});
|
|
2597
|
+
function watchSize(el, callback, client, watchWidth = true, watchHeight = true) {
|
|
2598
|
+
configMap.set(el, { callback, client, watchWidth, watchHeight });
|
|
2599
|
+
globalResizeObserver.observe(el, {
|
|
2600
|
+
box: !client && nativeBorderBoxEnabled
|
|
2601
|
+
? 'border-box'
|
|
2602
|
+
: undefined // default is 'content-box'
|
|
2603
|
+
});
|
|
2604
|
+
return () => {
|
|
2605
|
+
configMap.delete(el);
|
|
2606
|
+
globalResizeObserver.unobserve(el);
|
|
2607
|
+
};
|
|
2474
2608
|
}
|
|
2475
|
-
return
|
|
2609
|
+
return [watchSize, checkConfigMap];
|
|
2476
2610
|
}
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2611
|
+
// Fallback Technique ONLY
|
|
2612
|
+
// -------------------------------------------------------------------------------------------------
|
|
2613
|
+
// from https://github.com/juggle/resize-observer/blob/master/src/utils/scheduler.ts
|
|
2614
|
+
const globalEventNames = [
|
|
2615
|
+
// Global Resize
|
|
2616
|
+
'resize',
|
|
2617
|
+
// Global Load
|
|
2618
|
+
'load',
|
|
2619
|
+
// Transitions & Animations
|
|
2620
|
+
'transitionend',
|
|
2621
|
+
'animationend',
|
|
2622
|
+
'animationstart',
|
|
2623
|
+
'animationiteration',
|
|
2624
|
+
// Interactions
|
|
2625
|
+
'keyup',
|
|
2626
|
+
'keydown',
|
|
2627
|
+
'mouseup',
|
|
2628
|
+
'mousedown',
|
|
2629
|
+
'mouseover',
|
|
2630
|
+
'mouseout',
|
|
2631
|
+
'blur',
|
|
2632
|
+
'focus'
|
|
2633
|
+
];
|
|
2634
|
+
const eventListenerConfig = {
|
|
2635
|
+
capture: true,
|
|
2636
|
+
passive: true, // we don't call preventDefault, so can optimize
|
|
2637
|
+
};
|
|
2638
|
+
function initFallback() {
|
|
2639
|
+
let globalMutationObserver; // lazily initialize for non-browser envs
|
|
2640
|
+
let globalMutationObserverPaused = false;
|
|
2641
|
+
const [requestCheckSizes, cancelCheckSizes] = debounce(checkConfigMap, fallbackTimeout);
|
|
2642
|
+
function requestCheckSizesSync() {
|
|
2643
|
+
cancelCheckSizes();
|
|
2644
|
+
checkConfigMap();
|
|
2645
|
+
}
|
|
2646
|
+
function watchSize(el, callback, client, watchWidth = true, watchHeight = true) {
|
|
2647
|
+
if (!configMap.size) {
|
|
2648
|
+
addGlobalHandlers();
|
|
2649
|
+
}
|
|
2650
|
+
configMap.set(el, { callback, client, watchWidth, watchHeight });
|
|
2651
|
+
requestCheckSizes();
|
|
2652
|
+
return () => {
|
|
2653
|
+
configMap.delete(el);
|
|
2654
|
+
if (!configMap.size) {
|
|
2655
|
+
removeGlobalHandlers();
|
|
2656
|
+
}
|
|
2657
|
+
};
|
|
2484
2658
|
}
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2659
|
+
function addGlobalHandlers() {
|
|
2660
|
+
globalMutationObserver = new MutationObserver(requestCheckSizes);
|
|
2661
|
+
if (!globalMutationObserverPaused) {
|
|
2662
|
+
startGlobalMutationObserver();
|
|
2488
2663
|
}
|
|
2489
|
-
|
|
2490
|
-
|
|
2664
|
+
for (const eventName of globalEventNames) {
|
|
2665
|
+
window.addEventListener(eventName, requestCheckSizes, eventListenerConfig);
|
|
2491
2666
|
}
|
|
2492
|
-
|
|
2493
|
-
|
|
2667
|
+
}
|
|
2668
|
+
function removeGlobalHandlers() {
|
|
2669
|
+
if (!globalMutationObserverPaused) {
|
|
2670
|
+
stopGlobalMutationObserver();
|
|
2671
|
+
}
|
|
2672
|
+
for (const eventName of globalEventNames) {
|
|
2673
|
+
window.removeEventListener(eventName, requestCheckSizes, eventListenerConfig);
|
|
2494
2674
|
}
|
|
2495
2675
|
}
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
if (!currentMap || !isDimMapsEqual(currentMap, newMap)) {
|
|
2504
|
-
component.setState({ [key]: newMap });
|
|
2676
|
+
function startGlobalMutationObserver() {
|
|
2677
|
+
globalMutationObserver.observe(document.documentElement, {
|
|
2678
|
+
attributes: true,
|
|
2679
|
+
childList: true,
|
|
2680
|
+
subtree: true,
|
|
2681
|
+
characterData: true,
|
|
2682
|
+
});
|
|
2505
2683
|
}
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
if (!
|
|
2511
|
-
|
|
2684
|
+
function stopGlobalMutationObserver() {
|
|
2685
|
+
globalMutationObserver.disconnect();
|
|
2686
|
+
}
|
|
2687
|
+
function pauseGlobalMutationObserver() {
|
|
2688
|
+
if (!globalMutationObserverPaused) {
|
|
2689
|
+
globalMutationObserverPaused = true;
|
|
2690
|
+
if (configMap.size) {
|
|
2691
|
+
stopGlobalMutationObserver();
|
|
2692
|
+
}
|
|
2512
2693
|
}
|
|
2513
2694
|
}
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2695
|
+
function resumeGlobalMutationObserver() {
|
|
2696
|
+
if (globalMutationObserverPaused) {
|
|
2697
|
+
globalMutationObserverPaused = false;
|
|
2698
|
+
if (configMap.size) {
|
|
2699
|
+
startGlobalMutationObserver();
|
|
2700
|
+
}
|
|
2701
|
+
}
|
|
2702
|
+
}
|
|
2703
|
+
// Preact Integration
|
|
2704
|
+
const __rOld = preactOptions.__r || noop;
|
|
2705
|
+
const __cOld = preactOptions.__c || noop;
|
|
2706
|
+
let requested = false;
|
|
2707
|
+
preactOptions.__r = function () {
|
|
2708
|
+
pauseGlobalMutationObserver();
|
|
2709
|
+
__rOld.apply(this, arguments);
|
|
2710
|
+
};
|
|
2711
|
+
preactOptions.__c = function () {
|
|
2712
|
+
if (!requested) {
|
|
2713
|
+
requested = true;
|
|
2714
|
+
requestAnimationFrame(() => {
|
|
2715
|
+
requestCheckSizesSync();
|
|
2716
|
+
resumeGlobalMutationObserver();
|
|
2717
|
+
requested = false;
|
|
2718
|
+
});
|
|
2719
|
+
}
|
|
2720
|
+
__cOld.apply(this, arguments);
|
|
2721
|
+
};
|
|
2722
|
+
return [watchSize, requestCheckSizesSync];
|
|
2519
2723
|
}
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
if (entry.contentBoxSize) {
|
|
2534
|
-
// The standard makes contentBoxSize an array...
|
|
2535
|
-
if (entry.contentBoxSize[0]) {
|
|
2536
|
-
callback(entry.contentBoxSize[0].inlineSize, entry.contentBoxSize[0].blockSize);
|
|
2724
|
+
// Util
|
|
2725
|
+
// -------------------------------------------------------------------------------------------------
|
|
2726
|
+
const noop = () => { }; // TODO: use elsewhere
|
|
2727
|
+
function debounce(fn, ms) {
|
|
2728
|
+
let timeoutStarted;
|
|
2729
|
+
let timeoutAdded;
|
|
2730
|
+
let timeoutId; // thruthiness indicates whether active timeout
|
|
2731
|
+
function runWithTimeout(timeout) {
|
|
2732
|
+
timeoutStarted = Date.now();
|
|
2733
|
+
timeoutAdded = 0;
|
|
2734
|
+
timeoutId = setTimeout(() => {
|
|
2735
|
+
if (timeoutAdded) {
|
|
2736
|
+
runWithTimeout(timeoutAdded);
|
|
2537
2737
|
}
|
|
2538
2738
|
else {
|
|
2539
|
-
|
|
2540
|
-
|
|
2739
|
+
timeoutId = undefined;
|
|
2740
|
+
fn();
|
|
2541
2741
|
}
|
|
2742
|
+
}, timeout);
|
|
2743
|
+
}
|
|
2744
|
+
function request() {
|
|
2745
|
+
if (timeoutId) {
|
|
2746
|
+
timeoutAdded = Date.now() - timeoutStarted;
|
|
2542
2747
|
}
|
|
2543
2748
|
else {
|
|
2544
|
-
|
|
2749
|
+
runWithTimeout(ms);
|
|
2545
2750
|
}
|
|
2546
2751
|
}
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2752
|
+
function cancel() {
|
|
2753
|
+
if (timeoutId) {
|
|
2754
|
+
clearTimeout(timeoutId);
|
|
2755
|
+
timeoutId = undefined;
|
|
2756
|
+
}
|
|
2550
2757
|
}
|
|
2551
|
-
|
|
2552
|
-
}
|
|
2758
|
+
return [request, cancel];
|
|
2759
|
+
}
|
|
2760
|
+
// Main
|
|
2761
|
+
// -------------------------------------------------------------------------------------------------
|
|
2553
2762
|
/*
|
|
2554
|
-
|
|
2555
|
-
- element can only have one listener attached ever
|
|
2556
|
-
- element cannot have border or padding
|
|
2763
|
+
PRECONDITION: element can only have one listener attached
|
|
2557
2764
|
|
|
2558
|
-
|
|
2559
|
-
-
|
|
2765
|
+
NOTE: If we ever kill the fallback technique and use ResizeObserver unconditionally with full
|
|
2766
|
+
border-box support, we no longer need wrappers around the <StickyFooterScrollbar>'s <Scroller>
|
|
2560
2767
|
*/
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
return () => {
|
|
2565
|
-
callbackMap.delete(el);
|
|
2566
|
-
resizeObserver.unobserve(el);
|
|
2567
|
-
};
|
|
2568
|
-
}
|
|
2768
|
+
const [watchSize, updateSizeSync] = typeof ResizeObserver !== 'undefined'
|
|
2769
|
+
? initNative()
|
|
2770
|
+
: initFallback();
|
|
2569
2771
|
function watchWidth(el, callback) {
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
if (currentWidth == null || currentWidth !== width) {
|
|
2573
|
-
callback(currentWidth = width);
|
|
2574
|
-
}
|
|
2575
|
-
});
|
|
2772
|
+
return watchSize(el, callback,
|
|
2773
|
+
/* watchWidth = */ true);
|
|
2576
2774
|
}
|
|
2577
2775
|
function watchHeight(el, callback) {
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
callback(currentHeight = height);
|
|
2582
|
-
}
|
|
2583
|
-
});
|
|
2584
|
-
}
|
|
2585
|
-
function afterSize(callback) {
|
|
2586
|
-
if (isHandling) {
|
|
2587
|
-
flushedCallbackSet.add(callback);
|
|
2588
|
-
}
|
|
2589
|
-
else {
|
|
2590
|
-
callback(); // TODO: should we queue microtask?
|
|
2591
|
-
}
|
|
2776
|
+
return watchSize(el, (_width, height) => callback(height),
|
|
2777
|
+
/* watchWidth = */ false,
|
|
2778
|
+
/* watchHeight = */ true);
|
|
2592
2779
|
}
|
|
2593
2780
|
|
|
2594
2781
|
const DAY_FORMAT = createFormatter({ year: 'numeric', month: 'long', day: 'numeric' });
|
|
2595
2782
|
const WEEK_FORMAT = createFormatter({ week: 'long' });
|
|
2596
|
-
function
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
|
|
2602
|
-
|
|
2603
|
-
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2783
|
+
function buildDateStr(context, dateMarker, viewType = 'day') {
|
|
2784
|
+
return context.dateEnv.format(dateMarker, viewType === 'week' ? WEEK_FORMAT : DAY_FORMAT);
|
|
2785
|
+
}
|
|
2786
|
+
/*
|
|
2787
|
+
Assumes navLinks enabled
|
|
2788
|
+
Always hidden to screen readers. Do not point aria-labelledby at this. Use aria-label instead.
|
|
2789
|
+
*/
|
|
2790
|
+
function buildNavLinkAttrs(context, dateMarker, viewType = 'day', dateStr = buildDateStr(context, dateMarker, viewType), isTabbable = true) {
|
|
2791
|
+
const { dateEnv, options, calendarApi } = context;
|
|
2792
|
+
const zonedDate = dateEnv.toDate(dateMarker);
|
|
2793
|
+
const handleInteraction = (ev) => {
|
|
2794
|
+
let customAction = viewType === 'day' ? options.navLinkDayClick :
|
|
2795
|
+
viewType === 'week' ? options.navLinkWeekClick : null;
|
|
2796
|
+
if (typeof customAction === 'function') {
|
|
2797
|
+
customAction.call(calendarApi, dateEnv.toDate(dateMarker), ev);
|
|
2798
|
+
}
|
|
2799
|
+
else {
|
|
2800
|
+
if (typeof customAction === 'string') {
|
|
2801
|
+
viewType = customAction;
|
|
2612
2802
|
}
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2803
|
+
calendarApi.zoomTo(dateMarker, viewType);
|
|
2804
|
+
}
|
|
2805
|
+
};
|
|
2806
|
+
return Object.assign({ 'role': 'link', 'aria-label': formatWithOrdinals(options.navLinkHint, [dateStr, zonedDate], dateStr), 'data-navlink': '' }, (isTabbable
|
|
2807
|
+
? createAriaClickAttrs(handleInteraction)
|
|
2808
|
+
: { onClick: handleInteraction }));
|
|
2619
2809
|
}
|
|
2620
2810
|
|
|
2621
2811
|
let _isRtlScrollbarOnLeft = null;
|
|
@@ -2640,7 +2830,7 @@ var FullCalendar = (function (exports) {
|
|
|
2640
2830
|
document.body.appendChild(outerEl);
|
|
2641
2831
|
let innerEl = outerEl.firstChild;
|
|
2642
2832
|
let res = innerEl.getBoundingClientRect().left > outerEl.getBoundingClientRect().left;
|
|
2643
|
-
|
|
2833
|
+
outerEl.remove();
|
|
2644
2834
|
return res;
|
|
2645
2835
|
}
|
|
2646
2836
|
|
|
@@ -3041,7 +3231,7 @@ var FullCalendar = (function (exports) {
|
|
|
3041
3231
|
}
|
|
3042
3232
|
return className;
|
|
3043
3233
|
}
|
|
3044
|
-
|
|
3234
|
+
getClassName(key) {
|
|
3045
3235
|
return this.classes[key] || '';
|
|
3046
3236
|
}
|
|
3047
3237
|
getIconClass(buttonName, isRtl) {
|
|
@@ -3073,86 +3263,6 @@ var FullCalendar = (function (exports) {
|
|
|
3073
3263
|
Theme.prototype.baseIconClass = '';
|
|
3074
3264
|
Theme.prototype.iconOverridePrefix = '';
|
|
3075
3265
|
|
|
3076
|
-
var n,l$1,u$1,t,i$1,o,r$1,f$1,e$1,c$1,s$1,a$1,h={},p=[],v$1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w$1(n){var l=n.parentNode;l&&l.removeChild(n);}function _(l,u,t){var i,o,r,f={};for(r in u)"key"==r?i=u[r]:"ref"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),"function"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g$1(l,f,i,o,null)}function g$1(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u$1:r,__i:-1,__u:0};return null==r&&null!=l$1.vnode&&l$1.vnode(f),f}function m$1(){return {current:null}}function k$1(n){return n.children}function b(n,l){this.props=n,this.context=l;}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return "function"==typeof n.type?x(n):null}function C$1(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C$1(n)}}function M$1(n){(!n.__d&&(n.__d=!0)&&i$1.push(n)&&!P$1.__r++||o!==l$1.debounceRendering)&&((o=l$1.debounceRendering)||r$1)(P$1);}function P$1(){var n,u,t,o,r,e,c,s;for(i$1.sort(f$1);n=i$1.shift();)n.__d&&(u=i$1.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l$1.vnode&&l$1.vnode(o),O$1(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j$2(c,o,s),o.__e!=e&&C$1(o)),i$1.length>u&&i$1.sort(f$1));P$1.__r=0;}function S(n,l,u,t,i,o,r,f,e,c,s){var a,v,y,d,w,_=t&&t.__k||p,g=l.length;for(u.__d=e,$$1(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&"boolean"!=typeof y&&"function"!=typeof y&&(v=-1===y.__i?h:_[y.__i]||h,y.__i=a,O$1(n,y,v,i,o,r,f,e,c,s),d=y.__e,y.ref&&v.ref!=y.ref&&(v.ref&&N(v.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||v.__k===y.__k?e=I(y,e,n):"function"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w;}function $$1(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)r=t+a,null!=(i=n.__k[t]=null==(i=l[t])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?g$1(null,i,null,null,null):y(i)?g$1(k$1,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g$1(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=n,i.__b=n.__b+1,f=L$1(i,u,r,s),i.__i=f,o=null,-1!==f&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,"function"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a=f-r:f==r+1?a++:f>r?s>e-r?a+=f-r:a--:f<r&&a++,f!==t+a&&(i.__u|=65536))):(o=u[r])&&null==o.key&&o.__e&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V$1(o,o,!1),u[r]=null,s--);if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V$1(o,o));}function I(n,l,u){var t,i;if("function"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling;}while(null!=l&&8===l.nodeType);return l}function H$1(n,l){return l=l||[],null==n||"boolean"==typeof n||(y(n)?n.some(function(n){H$1(n,l);}):l.push(n)),l}function L$1(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--;}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++;}}return -1}function T$1(n,l,u){"-"===l[0]?n.setProperty(l,null==u?"":u):n[l]=null==u?"":"number"!=typeof u||v$1.test(l)?u:u+"px";}function A$1(n,l,u,t,i){var o;n:if("style"===l)if("string"==typeof u)n.style.cssText=u;else {if("string"==typeof t&&(n.style.cssText=t=""),t)for(l in t)u&&l in u||T$1(n.style,l,"");if(u)for(l in u)t&&u[l]===t[l]||T$1(n.style,l,u[l]);}else if("o"===l[0]&&"n"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,"$1")),l=l.toLowerCase()in n||"onFocusOut"===l||"onFocusIn"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e$1,n.addEventListener(l,o?s$1:c$1,o)):n.removeEventListener(l,o?s$1:c$1,o);else {if("http://www.w3.org/2000/svg"==i)l=l.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=l&&"height"!=l&&"href"!=l&&"list"!=l&&"form"!=l&&"tabIndex"!=l&&"download"!=l&&"rowSpan"!=l&&"colSpan"!=l&&"role"!=l&&"popover"!=l&&l in n)try{n[l]=null==u?"":u;break n}catch(n){}"function"==typeof u||(null==u||!1===u&&"-"!==l[4]?n.removeAttribute(l):n.setAttribute(l,"popover"==l&&1==u?"":u));}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e$1++;else if(u.t<t.u)return;return t(l$1.event?l$1.event(u):u)}}}function O$1(n,u,t,i,o,r,f,e,c,s){var a,h,p,v,w,_,g,m,x,C,M,P,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l$1.__b)&&a(u);n:if("function"==typeof T)try{if(m=u.props,x="prototype"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],M=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,M):(u.__c=h=new b(m,M),h.constructor=T,h.render=q),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=M,h.__n=i,p=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),v=h.props,w=h.state,h.__v=u,p)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else {if(x&&null==T.getDerivedStateFromProps&&m!==v&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,M),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,M)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.forEach(function(n){n&&(n.__=u);}),P=0;P<h._sb.length;P++)h.__h.push(h._sb[P]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,M),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(v,w,_);});}if(h.context=M,h.props=m,h.__P=n,h.__e=!1,$=l$1.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[];}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s;}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!p&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(v,w)),S(n,y(L=null!=a&&a.type===k$1&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null);}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:32;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e;}else u.__e=t.__e,u.__k=t.__k;l$1.__e(n,u,t);}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z$2(t.__e,u,t,i,o,r,f,c,s);(a=l$1.diffed)&&a(u);}function j$2(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l$1.__c&&l$1.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u);});}catch(n){l$1.__e(n,u.__v);}});}function z$2(l,u,t,i,o,r,f,e,c){var s,a,p,v,d,_,g,m=t.props,k=u.props,b=u.type;if("svg"===b?o="http://www.w3.org/2000/svg":"math"===b?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),null!=r)for(s=0;s<r.length;s++)if((d=r[s])&&"setAttribute"in d==!!b&&(b?d.localName===b:3===d.nodeType)){l=d,r[s]=null;break}if(null==l){if(null===b)return document.createTextNode(k);l=document.createElementNS(o,b,k.is&&k),r=null,e=!1;}if(null===b)m===k||e&&l.data===k||(l.data=k);else {if(r=r&&n.call(l.childNodes),m=t.props||h,!e&&null!=r)for(m={},s=0;s<l.attributes.length;s++)m[(d=l.attributes[s]).name]=d.value;for(s in m)if(d=m[s],"children"==s);else if("dangerouslySetInnerHTML"==s)p=d;else if("key"!==s&&!(s in k)){if("value"==s&&"defaultValue"in k||"checked"==s&&"defaultChecked"in k)continue;A$1(l,s,null,d,o);}for(s in k)d=k[s],"children"==s?v=d:"dangerouslySetInnerHTML"==s?a=d:"value"==s?_=d:"checked"==s?g=d:"key"===s||e&&"function"!=typeof d||m[s]===d||A$1(l,s,d,m[s],o);if(a)e||p&&(a.__html===p.__html||a.__html===l.innerHTML)||(l.innerHTML=a.__html),u.__k=[];else if(p&&(l.innerHTML=""),S(l,y(v)?v:[v],u,t,i,"foreignObject"===b?"http://www.w3.org/1999/xhtml":o,r,f,r?r[0]:t.__k&&x(t,0),e,c),null!=r)for(s=r.length;s--;)null!=r[s]&&w$1(r[s]);e||(s="value",void 0!==_&&(_!==l[s]||"progress"===b&&!_||"option"===b&&_!==m[s])&&A$1(l,s,_,m[s],o),s="checked",void 0!==g&&g!==l[s]&&A$1(l,s,g,m[s],o));}return l}function N(n,u,t){try{if("function"==typeof n){var i="function"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u));}else n.current=u;}catch(n){l$1.__e(n,t);}}function V$1(n,u,t){var i,o;if(l$1.unmount&&l$1.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount();}catch(n){l$1.__e(n,u);}i.base=i.__P=null;}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&V$1(i[o],u,t||"function"!=typeof n.type);t||null==n.__e||w$1(n.__e),n.__c=n.__=n.__e=n.__d=void 0;}function q(n,l,u){return this.constructor(n,u)}function B$2(u,t,i){var o,r,f,e;l$1.__&&l$1.__(u,t),r=(o="function"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O$1(t,u=(!o&&i||t).__k=_(k$1,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j$2(f,u,e);}function D$1(n,l){B$2(n,l,D$1);}function E$1(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)"key"==r?i=u[r]:"ref"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g$1(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l="__cC"+a$1++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null;},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,M$1(n);});},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.splice(u.indexOf(n),1),l&&l.call(n);};}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=p.slice,l$1={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l;}throw n}},u$1=0,t=function(n){return null!=n&&null==n.constructor},b.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),"function"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),M$1(this));},b.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),M$1(this));},b.prototype.render=k$1,i$1=[],r$1="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f$1=function(n,l){return n.__v.__b-l.__v.__b},P$1.__r=0,e$1=0,c$1=F(!1),s$1=F(!0),a$1=0;
|
|
3077
|
-
|
|
3078
|
-
var r,u,i,f=[],c=l$1,e=c.__b,a=c.__r,v=c.diffed,l=c.__c,m=c.unmount,s=c.__;function j$1(){for(var n;n=f.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(z$1),n.__H.__h.forEach(B$1),n.__H.__h=[];}catch(t){n.__H.__h=[],c.__e(t,n.__v);}}c.__b=function(n){r=null,e&&e(n);},c.__=function(n,t){n&&t.__k&&t.__k.__m&&(n.__m=t.__k.__m),s&&s(n,t);},c.__r=function(n){a&&a(n);var i=(r=n.__c).__H;i&&(u===r?(i.__h=[],r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.i=n.__N=void 0;})):(i.__h.forEach(z$1),i.__h.forEach(B$1),i.__h=[],0)),u=r;},c.diffed=function(n){v&&v(n);var t=n.__c;t&&t.__H&&(t.__H.__h.length&&(1!==f.push(t)&&i===c.requestAnimationFrame||((i=c.requestAnimationFrame)||w)(j$1)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.i=void 0;})),u=r=null;},c.__c=function(n,t){t.some(function(n){try{n.__h.forEach(z$1),n.__h=n.__h.filter(function(n){return !n.__||B$1(n)});}catch(r){t.some(function(n){n.__h&&(n.__h=[]);}),t=[],c.__e(r,n.__v);}}),l&&l(n,t);},c.unmount=function(n){m&&m(n);var t,r=n.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{z$1(n);}catch(n){t=n;}}),r.__H=void 0,t&&c.__e(t,r.__v));};var k="function"==typeof requestAnimationFrame;function w(n){var t,r=function(){clearTimeout(u),k&&cancelAnimationFrame(t),setTimeout(n);},u=setTimeout(r,100);k&&(t=requestAnimationFrame(r));}function z$1(n){var t=r,u=n.__c;"function"==typeof u&&(n.__c=void 0,u()),r=t;}function B$1(n){var t=r;n.__c=n.__(),r=t;}
|
|
3079
|
-
|
|
3080
|
-
function g(n,t){for(var e in t)n[e]=t[e];return n}function E(n,t){for(var e in n)if("__source"!==e&&!(e in t))return !0;for(var r in t)if("__source"!==r&&n[r]!==t[r])return !0;return !1}function C(n,t){this.props=n,this.context=t;}(C.prototype=new b).isPureReactComponent=!0,C.prototype.shouldComponentUpdate=function(n,t){return E(this.props,n)||E(this.state,t)};var R=l$1.__b;l$1.__b=function(n){n.type&&n.type.__f&&n.ref&&(n.props.ref=n.ref,n.ref=null),R&&R(n);};var M=l$1.__e;l$1.__e=function(n,t,e,r){if(n.then)for(var u,o=t;o=o.__;)if((u=o.__c)&&u.__c)return null==t.__e&&(t.__e=e.__e,t.__k=e.__k),u.__c(n,t);M(n,t,e,r);};var T=l$1.unmount;function A(n,t,e){return n&&(n.__c&&n.__c.__H&&(n.__c.__H.__.forEach(function(n){"function"==typeof n.__c&&n.__c();}),n.__c.__H=null),null!=(n=g({},n)).__c&&(n.__c.__P===e&&(n.__c.__P=t),n.__c=null),n.__k=n.__k&&n.__k.map(function(n){return A(n,t,e)})),n}function D(n,t,e){return n&&e&&(n.__v=null,n.__k=n.__k&&n.__k.map(function(n){return D(n,t,e)}),n.__c&&n.__c.__P===t&&(n.__e&&e.appendChild(n.__e),n.__c.__e=!0,n.__c.__P=e)),n}function L(){this.__u=0,this.t=null,this.__b=null;}function O(n){var t=n.__.__c;return t&&t.__a&&t.__a(n)}function U(){this.u=null,this.o=null;}l$1.unmount=function(n){var t=n.__c;t&&t.__R&&t.__R(),t&&32&n.__u&&(n.type=null),T&&T(n);},(L.prototype=new b).__c=function(n,t){var e=t.__c,r=this;null==r.t&&(r.t=[]),r.t.push(e);var u=O(r.__v),o=!1,i=function(){o||(o=!0,e.__R=null,u?u(c):c());};e.__R=i;var c=function(){if(!--r.__u){if(r.state.__a){var n=r.state.__a;r.__v.__k[0]=D(n,n.__c.__P,n.__c.__O);}var t;for(r.setState({__a:r.__b=null});t=r.t.pop();)t.forceUpdate();}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),n.then(i,i);},L.prototype.componentWillUnmount=function(){this.t=[];},L.prototype.render=function(n,e){if(this.__b){if(this.__v.__k){var r=document.createElement("div"),o=this.__v.__k[0].__c;this.__v.__k[0]=A(this.__b,r,o.__O=o.__P);}this.__b=null;}var i=e.__a&&_(k$1,null,n.fallback);return i&&(i.__u&=-33),[_(k$1,null,e.__a?null:n.children),i]};var V=function(n,t,e){if(++e[1]===e[0]&&n.o.delete(t),n.props.revealOrder&&("t"!==n.props.revealOrder[0]||!n.o.size))for(e=n.u;e;){for(;e.length>3;)e.pop()();if(e[1]<e[0])break;n.u=e=e[2];}};function W(n){return this.getChildContext=function(){return n.context},n.children}function P(n){var e=this,r=n.i;e.componentWillUnmount=function(){B$2(null,e.l),e.l=null,e.i=null;},e.i&&e.i!==r&&e.componentWillUnmount(),e.l||(e.i=r,e.l={nodeType:1,parentNode:r,childNodes:[],contains:function(){return !0},appendChild:function(n){this.childNodes.push(n),e.i.appendChild(n);},insertBefore:function(n,t){this.childNodes.push(n),e.i.appendChild(n);},removeChild:function(n){this.childNodes.splice(this.childNodes.indexOf(n)>>>1,1),e.i.removeChild(n);}}),B$2(_(W,{context:e.context},n.__v),e.l);}function j(n,e){var r=_(P,{__v:n,i:e});return r.containerInfo=e,r}(U.prototype=new b).__a=function(n){var t=this,e=O(t.__v),r=t.o.get(n);return r[0]++,function(u){var o=function(){t.props.revealOrder?(r.push(u),V(t,n,r)):u();};e?e(o):o();}},U.prototype.render=function(n){this.u=null,this.o=new Map;var t=H$1(n.children);n.revealOrder&&"b"===n.revealOrder[0]&&t.reverse();for(var e=t.length;e--;)this.o.set(t[e],this.u=[1,0,this.u]);return n.children},U.prototype.componentDidUpdate=U.prototype.componentDidMount=function(){var n=this;this.o.forEach(function(t,e){V(n,e,t);});};var z="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,B=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,H=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,Z=/[A-Z0-9]/g,Y="undefined"!=typeof document,$=function(n){return ("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(n)};b.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(t){Object.defineProperty(b.prototype,t,{configurable:!0,get:function(){return this["UNSAFE_"+t]},set:function(n){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:n});}});});var J=l$1.event;function K(){}function Q(){return this.cancelBubble}function X(){return this.defaultPrevented}l$1.event=function(n){return J&&(n=J(n)),n.persist=K,n.isPropagationStopped=Q,n.isDefaultPrevented=X,n.nativeEvent=n};var tn={enumerable:!1,configurable:!0,get:function(){return this.class}},en=l$1.vnode;l$1.vnode=function(n){"string"==typeof n.type&&function(n){var t=n.props,e=n.type,u={};for(var o in t){var i=t[o];if(!("value"===o&&"defaultValue"in t&&null==i||Y&&"children"===o&&"noscript"===e||"class"===o||"className"===o)){var c=o.toLowerCase();"defaultValue"===o&&"value"in t&&null==t.value?o="value":"download"===o&&!0===i?i="":"translate"===c&&"no"===i?i=!1:"ondoubleclick"===c?o="ondblclick":"onchange"!==c||"input"!==e&&"textarea"!==e||$(t.type)?"onfocus"===c?o="onfocusin":"onblur"===c?o="onfocusout":H.test(o)?o=c:-1===e.indexOf("-")&&B.test(o)?o=o.replace(Z,"-$&").toLowerCase():null===i&&(i=void 0):c=o="oninput","oninput"===c&&u[o=c]&&(o="oninputCapture"),u[o]=i;}}"select"==e&&u.multiple&&Array.isArray(u.value)&&(u.value=H$1(t.children).forEach(function(n){n.props.selected=-1!=u.value.indexOf(n.props.value);})),"select"==e&&null!=u.defaultValue&&(u.value=H$1(t.children).forEach(function(n){n.props.selected=u.multiple?-1!=u.defaultValue.indexOf(n.props.value):u.defaultValue==n.props.value;})),t.class&&!t.className?(u.class=t.class,Object.defineProperty(u,"className",tn)):(t.className&&!t.class||t.class&&t.className)&&(u.class=u.className=t.className),n.props=u;}(n),n.$$typeof=z,en&&en(n);};var rn=l$1.__r;l$1.__r=function(n){rn&&rn(n),n.__c;};var un=l$1.diffed;l$1.diffed=function(n){un&&un(n);var t=n.props,e=n.__e;null!=e&&"textarea"===n.type&&"value"in t&&t.value!==e.value&&(e.value=null==t.value?"":t.value);};
|
|
3081
|
-
|
|
3082
|
-
/*
|
|
3083
|
-
NOTE: this can be a public API, especially createElement for hooks.
|
|
3084
|
-
See examples/typescript-scheduler/src/index.ts
|
|
3085
|
-
*/
|
|
3086
|
-
/*
|
|
3087
|
-
TODO: rethink this
|
|
3088
|
-
*/
|
|
3089
|
-
function flushSync(runBeforeFlush) {
|
|
3090
|
-
runBeforeFlush();
|
|
3091
|
-
let oldDebounceRendering = l$1.debounceRendering; // orig
|
|
3092
|
-
let callbackQ = [];
|
|
3093
|
-
function execCallbackSync(callback) {
|
|
3094
|
-
callbackQ.push(callback);
|
|
3095
|
-
}
|
|
3096
|
-
l$1.debounceRendering = execCallbackSync;
|
|
3097
|
-
B$2(_(FakeComponent, {}), document.createElement('div'));
|
|
3098
|
-
while (callbackQ.length) {
|
|
3099
|
-
callbackQ.shift()();
|
|
3100
|
-
}
|
|
3101
|
-
l$1.debounceRendering = oldDebounceRendering;
|
|
3102
|
-
}
|
|
3103
|
-
class FakeComponent extends b {
|
|
3104
|
-
render() { return _('div', {}); }
|
|
3105
|
-
componentDidMount() { this.setState({}); }
|
|
3106
|
-
}
|
|
3107
|
-
// TODO: use preact/compat instead?
|
|
3108
|
-
function createContext(defaultValue) {
|
|
3109
|
-
let ContextType = G(defaultValue);
|
|
3110
|
-
let origProvider = ContextType.Provider;
|
|
3111
|
-
ContextType.Provider = function () {
|
|
3112
|
-
let isNew = !this.getChildContext;
|
|
3113
|
-
let children = origProvider.apply(this, arguments); // eslint-disable-line prefer-rest-params
|
|
3114
|
-
if (isNew) {
|
|
3115
|
-
let subs = [];
|
|
3116
|
-
this.shouldComponentUpdate = (_props) => {
|
|
3117
|
-
if (this.props.value !== _props.value) {
|
|
3118
|
-
subs.forEach((c) => {
|
|
3119
|
-
c.context = _props.value;
|
|
3120
|
-
c.forceUpdate();
|
|
3121
|
-
});
|
|
3122
|
-
}
|
|
3123
|
-
};
|
|
3124
|
-
this.sub = (c) => {
|
|
3125
|
-
subs.push(c);
|
|
3126
|
-
let old = c.componentWillUnmount;
|
|
3127
|
-
c.componentWillUnmount = () => {
|
|
3128
|
-
subs.splice(subs.indexOf(c), 1);
|
|
3129
|
-
old && old.call(c);
|
|
3130
|
-
};
|
|
3131
|
-
};
|
|
3132
|
-
}
|
|
3133
|
-
return children;
|
|
3134
|
-
};
|
|
3135
|
-
return ContextType;
|
|
3136
|
-
}
|
|
3137
|
-
|
|
3138
|
-
var preact = {
|
|
3139
|
-
__proto__: null,
|
|
3140
|
-
flushSync: flushSync,
|
|
3141
|
-
createContext: createContext,
|
|
3142
|
-
createPortal: j,
|
|
3143
|
-
Component: b,
|
|
3144
|
-
Fragment: k$1,
|
|
3145
|
-
cloneElement: E$1,
|
|
3146
|
-
createElement: _,
|
|
3147
|
-
createRef: m$1,
|
|
3148
|
-
h: _,
|
|
3149
|
-
hydrate: D$1,
|
|
3150
|
-
get isValidElement () { return t; },
|
|
3151
|
-
get options () { return l$1; },
|
|
3152
|
-
render: B$2,
|
|
3153
|
-
toChildArray: H$1
|
|
3154
|
-
};
|
|
3155
|
-
|
|
3156
3266
|
const ViewContextType = createContext({}); // for Components
|
|
3157
3267
|
function buildViewContext(viewSpec, viewApi, viewOptions, dateProfileGenerator, dateEnv, theme, pluginHooks, dispatch, getCurrentData, emitter, calendarApi, registerInteractiveComponent, unregisterInteractiveComponent) {
|
|
3158
3268
|
return {
|
|
@@ -3183,12 +3293,6 @@ var FullCalendar = (function (exports) {
|
|
|
3183
3293
|
return !compareObjs(this.props, nextProps, this.propEquality) ||
|
|
3184
3294
|
!compareObjs(this.state, nextState, this.stateEquality);
|
|
3185
3295
|
}
|
|
3186
|
-
// HACK for freakin' React StrictMode
|
|
3187
|
-
safeSetState(newState) {
|
|
3188
|
-
if (!compareObjs(this.state, Object.assign(Object.assign({}, this.state), newState), this.stateEquality)) {
|
|
3189
|
-
this.setState(newState);
|
|
3190
|
-
}
|
|
3191
|
-
}
|
|
3192
3296
|
}
|
|
3193
3297
|
PureComponent.addPropsEquality = addPropsEquality;
|
|
3194
3298
|
PureComponent.addStateEquality = addStateEquality;
|
|
@@ -3229,7 +3333,7 @@ var FullCalendar = (function (exports) {
|
|
|
3229
3333
|
class DateComponent extends BaseComponent {
|
|
3230
3334
|
constructor() {
|
|
3231
3335
|
super(...arguments);
|
|
3232
|
-
this.uid = guid();
|
|
3336
|
+
this.uid = guid$1();
|
|
3233
3337
|
}
|
|
3234
3338
|
// Hit System
|
|
3235
3339
|
// -----------------------------------------------------------------------------------------------------------------
|
|
@@ -3243,13 +3347,13 @@ var FullCalendar = (function (exports) {
|
|
|
3243
3347
|
isValidSegDownEl(el) {
|
|
3244
3348
|
return !this.props.eventDrag && // HACK
|
|
3245
3349
|
!this.props.eventResize && // HACK
|
|
3246
|
-
!
|
|
3350
|
+
!el.closest('.fc-event-mirror');
|
|
3247
3351
|
}
|
|
3248
3352
|
isValidDateDownEl(el) {
|
|
3249
|
-
return !
|
|
3250
|
-
!
|
|
3251
|
-
!
|
|
3252
|
-
!
|
|
3353
|
+
return !el.closest('.fc-event:not(.fc-bg-event)') &&
|
|
3354
|
+
!el.closest('.fc-more-link') && // a "more.." link
|
|
3355
|
+
!el.closest('[data-navlink]') && // a clickable nav link
|
|
3356
|
+
!el.closest('.fc-popover'); // hack
|
|
3253
3357
|
}
|
|
3254
3358
|
}
|
|
3255
3359
|
|
|
@@ -4102,6 +4206,9 @@ var FullCalendar = (function (exports) {
|
|
|
4102
4206
|
return eventApis;
|
|
4103
4207
|
}
|
|
4104
4208
|
|
|
4209
|
+
function getEventKey(seg) {
|
|
4210
|
+
return seg.eventRange.instance.instanceId;
|
|
4211
|
+
}
|
|
4105
4212
|
/*
|
|
4106
4213
|
Specifying nextDayThreshold signals that all-day ranges should be sliced.
|
|
4107
4214
|
*/
|
|
@@ -4240,37 +4347,38 @@ var FullCalendar = (function (exports) {
|
|
|
4240
4347
|
}
|
|
4241
4348
|
return val;
|
|
4242
4349
|
}
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
|
|
4350
|
+
/*
|
|
4351
|
+
slicedStart/slicedEnd are optionally supplied to signal where breaks occur in view-specific segment
|
|
4352
|
+
a better approach is to always slice with dates and always supply this argument,
|
|
4353
|
+
however, daygrid only slices by row/col
|
|
4354
|
+
*/
|
|
4355
|
+
function buildEventRangeTimeText(timeFormat, eventRange, // timed/whole-day span
|
|
4356
|
+
slicedStart, // view-sliced timed/whole-day span
|
|
4357
|
+
slicedEnd, // view-sliced timed/whole-day span
|
|
4358
|
+
isStart, isEnd, context, defaultDisplayEventTime = true, defaultDisplayEventEnd = true) {
|
|
4359
|
+
const { dateEnv, options } = context;
|
|
4360
|
+
const { def, instance } = eventRange;
|
|
4247
4361
|
let { displayEventTime, displayEventEnd } = options;
|
|
4248
|
-
let eventDef = eventRange.def;
|
|
4249
|
-
let eventInstance = eventRange.instance;
|
|
4250
4362
|
if (displayEventTime == null) {
|
|
4251
4363
|
displayEventTime = defaultDisplayEventTime !== false;
|
|
4252
4364
|
}
|
|
4253
4365
|
if (displayEventEnd == null) {
|
|
4254
4366
|
displayEventEnd = defaultDisplayEventEnd !== false;
|
|
4255
4367
|
}
|
|
4256
|
-
|
|
4257
|
-
|
|
4258
|
-
|
|
4259
|
-
|
|
4260
|
-
|
|
4261
|
-
|
|
4262
|
-
|
|
4263
|
-
|
|
4264
|
-
|
|
4265
|
-
if (
|
|
4266
|
-
return dateEnv.
|
|
4267
|
-
|
|
4268
|
-
forcedEndTzo: endOverride ? null : eventInstance.forcedEndTzo,
|
|
4368
|
+
const startDate = (!isStart && slicedStart) ? slicedStart : eventRange.instance.range.start;
|
|
4369
|
+
const endDate = (!isEnd && slicedEnd) ? slicedEnd : eventRange.instance.range.end;
|
|
4370
|
+
if (displayEventTime && !def.allDay) {
|
|
4371
|
+
if (displayEventEnd && (isStart || isEnd) && def.hasEnd) {
|
|
4372
|
+
return dateEnv.formatRange(startDate, endDate, timeFormat, {
|
|
4373
|
+
forcedStartTzo: isStart ? instance.forcedStartTzo : null,
|
|
4374
|
+
forcedEndTzo: isEnd ? instance.forcedEndTzo : null,
|
|
4375
|
+
});
|
|
4376
|
+
}
|
|
4377
|
+
if (isStart) {
|
|
4378
|
+
return dateEnv.format(startDate, timeFormat, {
|
|
4379
|
+
forcedTzo: instance.forcedStartTzo,
|
|
4269
4380
|
});
|
|
4270
4381
|
}
|
|
4271
|
-
return dateEnv.format(segStart, timeFormat, {
|
|
4272
|
-
forcedTzo: startOverride ? null : eventInstance.forcedStartTzo, // nooooo, same
|
|
4273
|
-
});
|
|
4274
4382
|
}
|
|
4275
4383
|
return '';
|
|
4276
4384
|
}
|
|
@@ -4325,11 +4433,11 @@ var FullCalendar = (function (exports) {
|
|
|
4325
4433
|
: `${eventRange.def.defId}:${eventRange.range.start.toISOString()}`;
|
|
4326
4434
|
// inverse-background events don't have specific instances. TODO: better solution
|
|
4327
4435
|
}
|
|
4328
|
-
function
|
|
4436
|
+
function getEventTagAndAttrs(eventRange, context) {
|
|
4329
4437
|
let { def, instance } = eventRange;
|
|
4330
4438
|
let { url } = def;
|
|
4331
4439
|
if (url) {
|
|
4332
|
-
return { href: url };
|
|
4440
|
+
return ['a', { href: url }];
|
|
4333
4441
|
}
|
|
4334
4442
|
let { emitter, options } = context;
|
|
4335
4443
|
let { eventInteractive } = options;
|
|
@@ -4339,10 +4447,11 @@ var FullCalendar = (function (exports) {
|
|
|
4339
4447
|
eventInteractive = Boolean(emitter.hasHandlers('eventClick'));
|
|
4340
4448
|
}
|
|
4341
4449
|
}
|
|
4450
|
+
let attrs;
|
|
4342
4451
|
// mock what happens in EventClicking
|
|
4343
4452
|
if (eventInteractive) {
|
|
4344
4453
|
// only attach keyboard-related handlers because click handler is already done in EventClicking
|
|
4345
|
-
|
|
4454
|
+
attrs = createAriaKeyboardAttrs((ev) => {
|
|
4346
4455
|
emitter.trigger('eventClick', {
|
|
4347
4456
|
el: ev.target,
|
|
4348
4457
|
event: new EventImpl(context, def, instance),
|
|
@@ -4350,8 +4459,9 @@ var FullCalendar = (function (exports) {
|
|
|
4350
4459
|
view: context.viewApi,
|
|
4351
4460
|
});
|
|
4352
4461
|
});
|
|
4462
|
+
attrs = Object.assign({ role: 'button' }, attrs);
|
|
4353
4463
|
}
|
|
4354
|
-
return
|
|
4464
|
+
return ['div', attrs];
|
|
4355
4465
|
}
|
|
4356
4466
|
|
|
4357
4467
|
const STANDARD_PROPS = {
|
|
@@ -4819,721 +4929,256 @@ var FullCalendar = (function (exports) {
|
|
|
4819
4929
|
}
|
|
4820
4930
|
}
|
|
4821
4931
|
|
|
4822
|
-
|
|
4823
|
-
|
|
4824
|
-
|
|
4825
|
-
|
|
4826
|
-
|
|
4827
|
-
|
|
4828
|
-
|
|
4829
|
-
|
|
4830
|
-
|
|
4831
|
-
|
|
4832
|
-
|
|
4833
|
-
|
|
4834
|
-
};
|
|
4835
|
-
this.updateElRef = (el) => {
|
|
4836
|
-
if (this.props.elRef) {
|
|
4837
|
-
setRef(this.props.elRef, el);
|
|
4838
|
-
}
|
|
4932
|
+
function doCoordRangesIntersect(r0, r1) {
|
|
4933
|
+
return r0.end > r1.start && r0.start < r1.end;
|
|
4934
|
+
}
|
|
4935
|
+
function intersectCoordRanges(r0, r1) {
|
|
4936
|
+
const start = Math.max(r0.start, r1.start);
|
|
4937
|
+
const end = Math.min(r0.end, r1.end);
|
|
4938
|
+
if (start < end) {
|
|
4939
|
+
return {
|
|
4940
|
+
start,
|
|
4941
|
+
end,
|
|
4942
|
+
isStart: r0.isStart && start === r0.start,
|
|
4943
|
+
isEnd: r0.isEnd && end === r0.end,
|
|
4839
4944
|
};
|
|
4840
4945
|
}
|
|
4841
|
-
|
|
4842
|
-
|
|
4843
|
-
|
|
4844
|
-
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
|
|
4848
|
-
|
|
4849
|
-
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
|
|
4855
|
-
|
|
4946
|
+
}
|
|
4947
|
+
function joinCoordRanges(r0, r1) {
|
|
4948
|
+
return {
|
|
4949
|
+
start: Math.min(r0.start, r1.start),
|
|
4950
|
+
end: Math.max(r0.end, r1.end),
|
|
4951
|
+
};
|
|
4952
|
+
}
|
|
4953
|
+
function getCoordRangeEnd(r) {
|
|
4954
|
+
return r.end;
|
|
4955
|
+
}
|
|
4956
|
+
// { eventRange }
|
|
4957
|
+
// -------------------------------------------------------------------------------------------------
|
|
4958
|
+
function computeEarliestStart(segs) {
|
|
4959
|
+
return segs.reduce(pickEarliestStart).eventRange.range.start;
|
|
4960
|
+
}
|
|
4961
|
+
function computeLatestEnd(segs) {
|
|
4962
|
+
return segs.reduce(pickLatestEnd).eventRange.range.end;
|
|
4963
|
+
}
|
|
4964
|
+
function pickEarliestStart(r0, r1) {
|
|
4965
|
+
return r0.eventRange.range.start < r1.eventRange.range.start ? r0 : r1;
|
|
4966
|
+
}
|
|
4967
|
+
function pickLatestEnd(r0, r1) {
|
|
4968
|
+
return r0.eventRange.range.end > r1.eventRange.range.end ? r0 : r1;
|
|
4969
|
+
}
|
|
4970
|
+
|
|
4971
|
+
class SegHierarchy {
|
|
4972
|
+
constructor(segs, getSegThickness = (seg) => {
|
|
4973
|
+
return 1;
|
|
4974
|
+
}, strictOrder = false, // HACK
|
|
4975
|
+
maxCoord, maxDepth, hiddenConsumes = false, // hidden segs also hide the touchingPlacement?
|
|
4976
|
+
allowSlicing = false) {
|
|
4977
|
+
this.getSegThickness = getSegThickness;
|
|
4978
|
+
this.strictOrder = strictOrder;
|
|
4979
|
+
this.maxCoord = maxCoord;
|
|
4980
|
+
this.maxDepth = maxDepth;
|
|
4981
|
+
this.hiddenConsumes = hiddenConsumes;
|
|
4982
|
+
this.allowSlicing = allowSlicing;
|
|
4983
|
+
this.placementsByLevel = [];
|
|
4984
|
+
this.levelCoords = []; // parallel with placementsByLevel
|
|
4985
|
+
this.hiddenSegs = [];
|
|
4986
|
+
for (const seg of segs) {
|
|
4987
|
+
this.insertSeg(seg, this.getSegThickness(seg));
|
|
4988
|
+
}
|
|
4989
|
+
}
|
|
4990
|
+
insertSeg(seg, segThickness, isSlice) {
|
|
4991
|
+
if (segThickness != null) {
|
|
4992
|
+
const insertion = this.findInsertion(seg, segThickness);
|
|
4993
|
+
if (this.isInsertionValid(insertion, segThickness)) {
|
|
4994
|
+
this.insertSegAt(seg, insertion, segThickness, isSlice);
|
|
4856
4995
|
}
|
|
4857
4996
|
else {
|
|
4858
|
-
const
|
|
4859
|
-
|
|
4860
|
-
|
|
4861
|
-
|
|
4862
|
-
|
|
4863
|
-
|
|
4864
|
-
|
|
4865
|
-
|
|
4866
|
-
|
|
4867
|
-
|
|
4868
|
-
|
|
4869
|
-
|
|
4870
|
-
|
|
4997
|
+
const { touchingPlacement } = insertion;
|
|
4998
|
+
// is there a touching-seg?
|
|
4999
|
+
if (touchingPlacement) {
|
|
5000
|
+
// should we hide or reslice touchingPlacement?
|
|
5001
|
+
if (this.hiddenConsumes && !touchingPlacement.isZombie) {
|
|
5002
|
+
touchingPlacement.isZombie = true; // edit in-place
|
|
5003
|
+
this.hiddenSegs.push(touchingPlacement);
|
|
5004
|
+
if (this.allowSlicing) {
|
|
5005
|
+
const newSeg = Object.assign({}, touchingPlacement); // copy
|
|
5006
|
+
// slice touchingPlacement in-place
|
|
5007
|
+
Object.assign(touchingPlacement, intersectCoordRanges(touchingPlacement, seg));
|
|
5008
|
+
touchingPlacement.isSlice = true;
|
|
5009
|
+
// try to reinsert touchingPlacement's seg
|
|
5010
|
+
this.splitSeg(newSeg, touchingPlacement.thickness, touchingPlacement);
|
|
5011
|
+
}
|
|
5012
|
+
}
|
|
5013
|
+
// record seg as hidden, potentially split by touchingPlacement
|
|
5014
|
+
if (this.allowSlicing) {
|
|
5015
|
+
this.hiddenSegs.push(Object.assign(Object.assign({}, seg), intersectCoordRanges(seg, touchingPlacement)));
|
|
5016
|
+
this.splitSeg(seg, segThickness, touchingPlacement);
|
|
5017
|
+
}
|
|
5018
|
+
else {
|
|
5019
|
+
this.hiddenSegs.push(seg);
|
|
5020
|
+
}
|
|
5021
|
+
// not touching anything
|
|
4871
5022
|
}
|
|
4872
5023
|
else {
|
|
4873
|
-
|
|
4874
|
-
currentGeneratorMeta = customGeneratorRes;
|
|
5024
|
+
this.hiddenSegs.push(seg);
|
|
4875
5025
|
}
|
|
4876
5026
|
}
|
|
4877
5027
|
}
|
|
4878
|
-
else {
|
|
4879
|
-
useDefault = !hasCustomRenderingHandler(props.generatorName, options);
|
|
4880
|
-
}
|
|
4881
|
-
if (useDefault && defaultGenerator) {
|
|
4882
|
-
innerContent = defaultGenerator(renderProps);
|
|
4883
|
-
}
|
|
4884
|
-
this.queuedDomNodes = queuedDomNodes;
|
|
4885
|
-
this.currentGeneratorMeta = currentGeneratorMeta;
|
|
4886
|
-
return _(props.elTag, attrs, innerContent);
|
|
4887
5028
|
}
|
|
4888
|
-
|
|
4889
|
-
|
|
4890
|
-
|
|
5029
|
+
/*
|
|
5030
|
+
TODO: inline?
|
|
5031
|
+
*/
|
|
5032
|
+
isInsertionValid(insertion, thickness) {
|
|
5033
|
+
return (this.maxCoord == null || insertion.levelCoord + thickness <= this.maxCoord) &&
|
|
5034
|
+
(this.maxDepth == null || insertion.depth < this.maxDepth);
|
|
4891
5035
|
}
|
|
4892
|
-
|
|
4893
|
-
|
|
4894
|
-
|
|
5036
|
+
/*
|
|
5037
|
+
Does not add the portion that intersects with barrier to hiddenSegs
|
|
5038
|
+
*/
|
|
5039
|
+
splitSeg(seg, segThickness, barrier) {
|
|
5040
|
+
// any leftover seg on the start-side of the barrier?
|
|
5041
|
+
if (seg.start < barrier.start) {
|
|
5042
|
+
this.insertSeg(Object.assign(Object.assign({}, seg), { end: barrier.start, isEnd: false }), segThickness,
|
|
5043
|
+
/* isSlice = */ true);
|
|
5044
|
+
}
|
|
5045
|
+
// any leftover seg on the end-side of the barrier?
|
|
5046
|
+
if (seg.end > barrier.end) {
|
|
5047
|
+
this.insertSeg(Object.assign(Object.assign({}, seg), { start: barrier.end, isStart: false }), segThickness,
|
|
5048
|
+
/* isSlice = */ true);
|
|
5049
|
+
}
|
|
4895
5050
|
}
|
|
4896
|
-
|
|
4897
|
-
|
|
5051
|
+
/*
|
|
5052
|
+
TODO: inline?
|
|
5053
|
+
*/
|
|
5054
|
+
insertSegAt(seg, insertion, segThickness, isSlice) {
|
|
5055
|
+
const placement = Object.assign(Object.assign({}, seg), { thickness: segThickness, depth: insertion.depth, isSlice: isSlice || seg.isSlice || false, isZombie: false });
|
|
5056
|
+
if (insertion.lateralIndex === -1) {
|
|
5057
|
+
// create a new level
|
|
5058
|
+
insertAt(this.placementsByLevel, insertion.levelIndex, [placement]);
|
|
5059
|
+
insertAt(this.levelCoords, insertion.levelIndex, insertion.levelCoord);
|
|
5060
|
+
}
|
|
5061
|
+
else {
|
|
5062
|
+
// insert into existing level
|
|
5063
|
+
insertAt(this.placementsByLevel[insertion.levelIndex], insertion.lateralIndex, placement);
|
|
5064
|
+
}
|
|
4898
5065
|
}
|
|
4899
|
-
|
|
4900
|
-
|
|
4901
|
-
|
|
4902
|
-
|
|
4903
|
-
|
|
4904
|
-
|
|
4905
|
-
|
|
4906
|
-
|
|
4907
|
-
|
|
5066
|
+
/*
|
|
5067
|
+
Ignores limits
|
|
5068
|
+
*/
|
|
5069
|
+
findInsertion(seg, segThickness) {
|
|
5070
|
+
let { placementsByLevel, levelCoords } = this;
|
|
5071
|
+
let levelCnt = placementsByLevel.length;
|
|
5072
|
+
let candidateCoord = 0; // a tentative levelCoord for seg's placement
|
|
5073
|
+
let touchingPlacement;
|
|
5074
|
+
let touchingLevelIndex;
|
|
5075
|
+
let depth = 0;
|
|
5076
|
+
// iterate through existing levels
|
|
5077
|
+
for (let currentLevelIndex = 0; currentLevelIndex < levelCnt; currentLevelIndex += 1) {
|
|
5078
|
+
const currentLevelCoord = levelCoords[currentLevelIndex];
|
|
5079
|
+
// if the current level has cleared seg's bottom coord, we have found a good empty space and can stop.
|
|
5080
|
+
// if strictOrder, keep finding more lateral intersections.
|
|
5081
|
+
if (!this.strictOrder && currentLevelCoord >= candidateCoord + segThickness) {
|
|
5082
|
+
break;
|
|
5083
|
+
}
|
|
5084
|
+
let currentLevelSegs = placementsByLevel[currentLevelIndex];
|
|
5085
|
+
let currentSeg;
|
|
5086
|
+
// finds the first possible entry that seg could intersect with
|
|
5087
|
+
let [searchIndex, isExact] = binarySearch(currentLevelSegs, seg.start, getCoordRangeEnd); // find first entry after seg's end
|
|
5088
|
+
let lateralIndex = searchIndex + isExact; // if exact match (which doesn't collide), go to next one
|
|
5089
|
+
// loop through entries that horizontally intersect
|
|
5090
|
+
while ((currentSeg = currentLevelSegs[lateralIndex]) && // but not past the whole entry list
|
|
5091
|
+
currentSeg.start < seg.end // and not entirely past seg
|
|
5092
|
+
) {
|
|
5093
|
+
let currentEntryBottom = currentLevelCoord + currentSeg.thickness;
|
|
5094
|
+
// intersects into the top of the candidate?
|
|
5095
|
+
if (currentEntryBottom > candidateCoord) {
|
|
5096
|
+
// push it downward so doesn't 'vertically' intersect anymore
|
|
5097
|
+
candidateCoord = currentEntryBottom;
|
|
5098
|
+
// tentatively record as touching
|
|
5099
|
+
touchingPlacement = currentSeg;
|
|
5100
|
+
touchingLevelIndex = currentLevelIndex;
|
|
5101
|
+
}
|
|
5102
|
+
// does current entry butt up against top of candidate?
|
|
5103
|
+
// will obviously happen if just intersected, but can also happen if pushed down previously
|
|
5104
|
+
// because intersected with a sibling
|
|
5105
|
+
// TODO: after automated tests hooked up, see if these gate is unnecessary,
|
|
5106
|
+
// we might just be able to do this for ALL intersecting currentEntries (this whole loop)
|
|
5107
|
+
if (currentEntryBottom === candidateCoord) {
|
|
5108
|
+
// accumulate the highest possible depth of the currentLevelSegs that butt up
|
|
5109
|
+
depth = Math.max(depth, currentSeg.depth + 1);
|
|
5110
|
+
}
|
|
5111
|
+
lateralIndex += 1;
|
|
5112
|
+
}
|
|
5113
|
+
}
|
|
5114
|
+
// the destination level will be after touchingPlacement's level. find it
|
|
5115
|
+
// TODO: can reuse work from above?
|
|
5116
|
+
let destLevelIndex = 0;
|
|
5117
|
+
if (touchingPlacement) {
|
|
5118
|
+
destLevelIndex = touchingLevelIndex + 1;
|
|
5119
|
+
while (destLevelIndex < levelCnt && levelCoords[destLevelIndex] < candidateCoord) {
|
|
5120
|
+
destLevelIndex += 1;
|
|
4908
5121
|
}
|
|
4909
5122
|
}
|
|
5123
|
+
// if adding to an existing level, find where to insert
|
|
5124
|
+
// TODO: can reuse work from above?
|
|
5125
|
+
let destLateralIndex = -1;
|
|
5126
|
+
if (destLevelIndex < levelCnt && levelCoords[destLevelIndex] === candidateCoord) {
|
|
5127
|
+
[destLateralIndex] = binarySearch(placementsByLevel[destLevelIndex], seg.end, getCoordRangeEnd);
|
|
5128
|
+
}
|
|
5129
|
+
return {
|
|
5130
|
+
touchingPlacement,
|
|
5131
|
+
levelCoord: candidateCoord,
|
|
5132
|
+
levelIndex: destLevelIndex,
|
|
5133
|
+
lateralIndex: destLateralIndex,
|
|
5134
|
+
depth,
|
|
5135
|
+
};
|
|
4910
5136
|
}
|
|
4911
|
-
|
|
4912
|
-
const {
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
-
|
|
4916
|
-
for (
|
|
4917
|
-
|
|
5137
|
+
traverseSegs(handler) {
|
|
5138
|
+
const { placementsByLevel, levelCoords } = this;
|
|
5139
|
+
for (let i = 0; i < placementsByLevel.length; i++) {
|
|
5140
|
+
const placements = placementsByLevel[i];
|
|
5141
|
+
const levelCoord = levelCoords[i];
|
|
5142
|
+
for (const placement of placements) {
|
|
5143
|
+
if (!placement.isZombie) {
|
|
5144
|
+
handler(placement, levelCoord);
|
|
5145
|
+
}
|
|
4918
5146
|
}
|
|
4919
|
-
this.currentDomNodes = queuedDomNodes;
|
|
4920
5147
|
}
|
|
4921
5148
|
}
|
|
4922
5149
|
}
|
|
4923
|
-
ContentInjector.addPropsEquality({
|
|
4924
|
-
elClasses: isArraysEqual,
|
|
4925
|
-
elStyle: isPropsEqual,
|
|
4926
|
-
elAttrs: isNonHandlerPropsEqual,
|
|
4927
|
-
renderProps: isPropsEqual,
|
|
4928
|
-
});
|
|
4929
|
-
// Util
|
|
4930
5150
|
/*
|
|
4931
|
-
|
|
4932
|
-
AND does the calendar's options define custom rendering?
|
|
4933
|
-
AKA. Should we NOT render the default content?
|
|
5151
|
+
Returns groups with entries sorted by input order
|
|
4934
5152
|
*/
|
|
4935
|
-
function
|
|
4936
|
-
|
|
4937
|
-
|
|
4938
|
-
|
|
4939
|
-
|
|
4940
|
-
|
|
4941
|
-
|
|
4942
|
-
|
|
4943
|
-
|
|
4944
|
-
|
|
4945
|
-
|
|
4946
|
-
|
|
4947
|
-
|
|
4948
|
-
|
|
4949
|
-
|
|
4950
|
-
|
|
4951
|
-
|
|
5153
|
+
function groupIntersectingSegs(segs) {
|
|
5154
|
+
let mergedGroups = [];
|
|
5155
|
+
for (let seg of segs) {
|
|
5156
|
+
let filteredGroups = [];
|
|
5157
|
+
let hungryGroup = {
|
|
5158
|
+
segs: [seg],
|
|
5159
|
+
start: seg.start,
|
|
5160
|
+
end: seg.end,
|
|
5161
|
+
};
|
|
5162
|
+
for (let mergedGroup of mergedGroups) {
|
|
5163
|
+
if (doCoordRangesIntersect(mergedGroup, hungryGroup)) {
|
|
5164
|
+
hungryGroup = Object.assign(Object.assign({}, joinCoordRanges(mergedGroup, hungryGroup)), { segs: mergedGroup.segs.concat(hungryGroup.segs) // keep preexisting mergedGroup's items first. maintains order
|
|
5165
|
+
});
|
|
5166
|
+
}
|
|
5167
|
+
else {
|
|
5168
|
+
filteredGroups.push(mergedGroup);
|
|
5169
|
+
}
|
|
5170
|
+
}
|
|
5171
|
+
filteredGroups.push(hungryGroup);
|
|
5172
|
+
mergedGroups = filteredGroups;
|
|
4952
5173
|
}
|
|
4953
|
-
return
|
|
5174
|
+
return mergedGroups.map((mergedGroup) => {
|
|
5175
|
+
return Object.assign({ key: buildIsoString(computeEarliestStart(segs)) }, mergedGroup);
|
|
5176
|
+
});
|
|
4954
5177
|
}
|
|
4955
|
-
|
|
4956
|
-
|
|
4957
|
-
|
|
4958
|
-
|
|
4959
|
-
const RenderId = createContext(0);
|
|
4960
|
-
|
|
4961
|
-
class ContentContainer extends b {
|
|
4962
|
-
constructor() {
|
|
4963
|
-
super(...arguments);
|
|
4964
|
-
this.InnerContent = InnerContentInjector.bind(undefined, this);
|
|
4965
|
-
this.handleEl = (el) => {
|
|
4966
|
-
this.el = el;
|
|
4967
|
-
if (this.props.elRef) {
|
|
4968
|
-
setRef(this.props.elRef, el);
|
|
4969
|
-
if (el && this.didMountMisfire) {
|
|
4970
|
-
this.componentDidMount();
|
|
4971
|
-
}
|
|
4972
|
-
}
|
|
4973
|
-
};
|
|
4974
|
-
}
|
|
4975
|
-
render() {
|
|
4976
|
-
const { props } = this;
|
|
4977
|
-
const generatedClassNames = generateClassNames(props.classNameGenerator, props.renderProps);
|
|
4978
|
-
if (props.children) {
|
|
4979
|
-
const elAttrs = buildElAttrs(props, generatedClassNames, this.handleEl);
|
|
4980
|
-
const children = props.children(this.InnerContent, props.renderProps, elAttrs);
|
|
4981
|
-
if (props.elTag) {
|
|
4982
|
-
return _(props.elTag, elAttrs, children);
|
|
4983
|
-
}
|
|
4984
|
-
else {
|
|
4985
|
-
return children;
|
|
4986
|
-
}
|
|
4987
|
-
}
|
|
4988
|
-
else {
|
|
4989
|
-
return _((ContentInjector), Object.assign(Object.assign({}, props), { elRef: this.handleEl, elTag: props.elTag || 'div', elClasses: (props.elClasses || []).concat(generatedClassNames), renderId: this.context }));
|
|
4990
|
-
}
|
|
4991
|
-
}
|
|
4992
|
-
componentDidMount() {
|
|
4993
|
-
var _a, _b;
|
|
4994
|
-
if (this.el) {
|
|
4995
|
-
(_b = (_a = this.props).didMount) === null || _b === void 0 ? void 0 : _b.call(_a, Object.assign(Object.assign({}, this.props.renderProps), { el: this.el }));
|
|
4996
|
-
}
|
|
4997
|
-
else {
|
|
4998
|
-
this.didMountMisfire = true;
|
|
4999
|
-
}
|
|
5000
|
-
}
|
|
5001
|
-
componentWillUnmount() {
|
|
5002
|
-
var _a, _b;
|
|
5003
|
-
(_b = (_a = this.props).willUnmount) === null || _b === void 0 ? void 0 : _b.call(_a, Object.assign(Object.assign({}, this.props.renderProps), { el: this.el }));
|
|
5004
|
-
}
|
|
5005
|
-
}
|
|
5006
|
-
ContentContainer.contextType = RenderId;
|
|
5007
|
-
function InnerContentInjector(containerComponent, props) {
|
|
5008
|
-
const parentProps = containerComponent.props;
|
|
5009
|
-
return _((ContentInjector), Object.assign({ renderProps: parentProps.renderProps, generatorName: parentProps.generatorName, customGenerator: parentProps.customGenerator, defaultGenerator: parentProps.defaultGenerator, renderId: containerComponent.context }, props));
|
|
5010
|
-
}
|
|
5011
|
-
// Utils
|
|
5012
|
-
function generateClassNames(classNameGenerator, renderProps) {
|
|
5013
|
-
const classNames = typeof classNameGenerator === 'function' ?
|
|
5014
|
-
classNameGenerator(renderProps) :
|
|
5015
|
-
classNameGenerator || [];
|
|
5016
|
-
return typeof classNames === 'string' ? [classNames] : classNames;
|
|
5017
|
-
}
|
|
5018
|
-
|
|
5019
|
-
const DAY_NUM_FORMAT = createFormatter({ day: 'numeric' });
|
|
5020
|
-
class DayCellContainer extends BaseComponent {
|
|
5021
|
-
constructor() {
|
|
5022
|
-
super(...arguments);
|
|
5023
|
-
this.refineRenderProps = memoizeObjArg(refineRenderProps);
|
|
5024
|
-
}
|
|
5025
|
-
render() {
|
|
5026
|
-
let { props, context } = this;
|
|
5027
|
-
let { options } = context;
|
|
5028
|
-
let renderProps = this.refineRenderProps({
|
|
5029
|
-
date: props.date,
|
|
5030
|
-
dateProfile: props.dateProfile,
|
|
5031
|
-
todayRange: props.todayRange,
|
|
5032
|
-
isMonthStart: props.isMonthStart || false,
|
|
5033
|
-
showDayNumber: props.showDayNumber,
|
|
5034
|
-
extraRenderProps: props.extraRenderProps,
|
|
5035
|
-
viewApi: context.viewApi,
|
|
5036
|
-
dateEnv: context.dateEnv,
|
|
5037
|
-
monthStartFormat: options.monthStartFormat,
|
|
5038
|
-
});
|
|
5039
|
-
return (_(ContentContainer, Object.assign({}, props /* includes children */, { elClasses: [
|
|
5040
|
-
...getDayClassNames(renderProps, context.theme),
|
|
5041
|
-
...(props.elClasses || []),
|
|
5042
|
-
], elAttrs: Object.assign(Object.assign({}, props.elAttrs), (renderProps.isDisabled ? {} : { 'data-date': formatDayString(props.date) })), renderProps: renderProps, generatorName: "dayCellContent", customGenerator: options.dayCellContent, defaultGenerator: props.defaultGenerator, classNameGenerator:
|
|
5043
|
-
// don't use custom classNames if disabled
|
|
5044
|
-
renderProps.isDisabled ? undefined : options.dayCellClassNames, didMount: options.dayCellDidMount, willUnmount: options.dayCellWillUnmount })));
|
|
5045
|
-
}
|
|
5046
|
-
}
|
|
5047
|
-
function hasCustomDayCellContent(options) {
|
|
5048
|
-
return Boolean(options.dayCellContent || hasCustomRenderingHandler('dayCellContent', options));
|
|
5049
|
-
}
|
|
5050
|
-
function refineRenderProps(raw) {
|
|
5051
|
-
let { date, dateEnv, dateProfile, isMonthStart } = raw;
|
|
5052
|
-
let dayMeta = getDateMeta(date, raw.todayRange, null, dateProfile);
|
|
5053
|
-
let dayNumberText = raw.showDayNumber ? (dateEnv.format(date, isMonthStart ? raw.monthStartFormat : DAY_NUM_FORMAT)) : '';
|
|
5054
|
-
return Object.assign(Object.assign(Object.assign({ date: dateEnv.toDate(date), view: raw.viewApi }, dayMeta), { isMonthStart,
|
|
5055
|
-
dayNumberText }), raw.extraRenderProps);
|
|
5056
|
-
}
|
|
5057
|
-
|
|
5058
|
-
const PADDING_FROM_VIEWPORT = 10;
|
|
5059
|
-
class Popover extends BaseComponent {
|
|
5060
|
-
constructor() {
|
|
5061
|
-
super(...arguments);
|
|
5062
|
-
this.state = {
|
|
5063
|
-
titleId: getUniqueDomId(),
|
|
5064
|
-
};
|
|
5065
|
-
this.handleRootEl = (el) => {
|
|
5066
|
-
this.rootEl = el;
|
|
5067
|
-
if (this.props.elRef) {
|
|
5068
|
-
setRef(this.props.elRef, el);
|
|
5069
|
-
}
|
|
5070
|
-
};
|
|
5071
|
-
// Triggered when the user clicks *anywhere* in the document, for the autoHide feature
|
|
5072
|
-
this.handleDocumentMouseDown = (ev) => {
|
|
5073
|
-
// only hide the popover if the click happened outside the popover
|
|
5074
|
-
const target = getEventTargetViaRoot(ev);
|
|
5075
|
-
if (!this.rootEl.contains(target)) {
|
|
5076
|
-
this.handleCloseClick();
|
|
5077
|
-
}
|
|
5078
|
-
};
|
|
5079
|
-
this.handleDocumentKeyDown = (ev) => {
|
|
5080
|
-
if (ev.key === 'Escape') {
|
|
5081
|
-
this.handleCloseClick();
|
|
5082
|
-
}
|
|
5083
|
-
};
|
|
5084
|
-
this.handleCloseClick = () => {
|
|
5085
|
-
let { onClose } = this.props;
|
|
5086
|
-
if (onClose) {
|
|
5087
|
-
onClose();
|
|
5088
|
-
}
|
|
5089
|
-
};
|
|
5090
|
-
}
|
|
5091
|
-
render() {
|
|
5092
|
-
let { theme, options } = this.context;
|
|
5093
|
-
let { props, state } = this;
|
|
5094
|
-
let classNames = [
|
|
5095
|
-
'fc-popover',
|
|
5096
|
-
theme.getClass('popover'),
|
|
5097
|
-
].concat(props.extraClassNames || []);
|
|
5098
|
-
return j(_("div", Object.assign({}, props.extraAttrs, { id: props.id, className: classNames.join(' '), "aria-labelledby": state.titleId, ref: this.handleRootEl }),
|
|
5099
|
-
_("div", { className: 'fc-popover-header ' + theme.getClass('popoverHeader') },
|
|
5100
|
-
_("span", { className: "fc-popover-title", id: state.titleId }, props.title),
|
|
5101
|
-
_("span", { className: 'fc-popover-close ' + theme.getIconClass('close'), title: options.closeHint, onClick: this.handleCloseClick })),
|
|
5102
|
-
_("div", { className: 'fc-popover-body ' + theme.getClass('popoverContent') }, props.children)), props.parentEl);
|
|
5103
|
-
}
|
|
5104
|
-
componentDidMount() {
|
|
5105
|
-
document.addEventListener('mousedown', this.handleDocumentMouseDown);
|
|
5106
|
-
document.addEventListener('keydown', this.handleDocumentKeyDown);
|
|
5107
|
-
this.updateSize();
|
|
5108
|
-
}
|
|
5109
|
-
componentWillUnmount() {
|
|
5110
|
-
document.removeEventListener('mousedown', this.handleDocumentMouseDown);
|
|
5111
|
-
document.removeEventListener('keydown', this.handleDocumentKeyDown);
|
|
5112
|
-
}
|
|
5113
|
-
updateSize() {
|
|
5114
|
-
let { isRtl } = this.context;
|
|
5115
|
-
let { alignmentEl, alignGridTop } = this.props;
|
|
5116
|
-
let { rootEl } = this;
|
|
5117
|
-
let alignmentRect = computeClippedClientRect(alignmentEl);
|
|
5118
|
-
if (alignmentRect) {
|
|
5119
|
-
let popoverDims = rootEl.getBoundingClientRect();
|
|
5120
|
-
if (alignGridTop) {
|
|
5121
|
-
throw new Error('alignGridTop not supported yet');
|
|
5122
|
-
}
|
|
5123
|
-
// position relative to viewport
|
|
5124
|
-
let popoverTop = alignGridTop
|
|
5125
|
-
? elementClosest(alignmentEl, '.fc-scrollgrid').getBoundingClientRect().top // BAD!!!
|
|
5126
|
-
: alignmentRect.top;
|
|
5127
|
-
let popoverLeft = isRtl ? alignmentRect.right - popoverDims.width : alignmentRect.left;
|
|
5128
|
-
// constrain
|
|
5129
|
-
popoverTop = Math.max(popoverTop, PADDING_FROM_VIEWPORT);
|
|
5130
|
-
popoverLeft = Math.min(popoverLeft, document.documentElement.clientWidth - PADDING_FROM_VIEWPORT - popoverDims.width);
|
|
5131
|
-
popoverLeft = Math.max(popoverLeft, PADDING_FROM_VIEWPORT);
|
|
5132
|
-
let origin = rootEl.offsetParent.getBoundingClientRect();
|
|
5133
|
-
applyStyle(rootEl, {
|
|
5134
|
-
top: popoverTop - origin.top,
|
|
5135
|
-
left: popoverLeft - origin.left,
|
|
5136
|
-
});
|
|
5137
|
-
}
|
|
5138
|
-
}
|
|
5139
|
-
}
|
|
5140
|
-
|
|
5141
|
-
class MorePopover extends DateComponent {
|
|
5142
|
-
constructor() {
|
|
5143
|
-
super(...arguments);
|
|
5144
|
-
this.handleRootEl = (rootEl) => {
|
|
5145
|
-
this.rootEl = rootEl;
|
|
5146
|
-
if (rootEl) {
|
|
5147
|
-
this.context.registerInteractiveComponent(this, {
|
|
5148
|
-
el: rootEl,
|
|
5149
|
-
useEventCenter: false,
|
|
5150
|
-
});
|
|
5151
|
-
}
|
|
5152
|
-
else {
|
|
5153
|
-
this.context.unregisterInteractiveComponent(this);
|
|
5154
|
-
}
|
|
5155
|
-
};
|
|
5156
|
-
}
|
|
5157
|
-
render() {
|
|
5158
|
-
let { options, dateEnv } = this.context;
|
|
5159
|
-
let { props } = this;
|
|
5160
|
-
let { startDate, todayRange, dateProfile } = props;
|
|
5161
|
-
let title = dateEnv.format(startDate, options.dayPopoverFormat);
|
|
5162
|
-
return (_(DayCellContainer, { elRef: this.handleRootEl, date: startDate, dateProfile: dateProfile, todayRange: todayRange }, (InnerContent, renderProps, elAttrs) => (_(Popover, { elRef: elAttrs.ref, id: props.id, title: title, extraClassNames: ['fc-more-popover'].concat(elAttrs.className || []), extraAttrs: elAttrs /* TODO: make these time-based when not whole-day? */, parentEl: props.parentEl, alignmentEl: props.alignmentEl, alignGridTop: props.alignGridTop, onClose: props.onClose },
|
|
5163
|
-
hasCustomDayCellContent(options) && (_(InnerContent, { elTag: "div", elClasses: ['fc-more-popover-misc'] })),
|
|
5164
|
-
props.children))));
|
|
5165
|
-
}
|
|
5166
|
-
queryHit(positionLeft, positionTop, elWidth, elHeight) {
|
|
5167
|
-
let { rootEl, props } = this;
|
|
5168
|
-
if (positionLeft >= 0 && positionLeft < elWidth &&
|
|
5169
|
-
positionTop >= 0 && positionTop < elHeight) {
|
|
5170
|
-
return {
|
|
5171
|
-
dateProfile: props.dateProfile,
|
|
5172
|
-
dateSpan: Object.assign({ allDay: !props.forceTimed, range: {
|
|
5173
|
-
start: props.startDate,
|
|
5174
|
-
end: props.endDate,
|
|
5175
|
-
} }, props.extraDateSpan),
|
|
5176
|
-
dayEl: rootEl,
|
|
5177
|
-
rect: {
|
|
5178
|
-
left: 0,
|
|
5179
|
-
top: 0,
|
|
5180
|
-
right: elWidth,
|
|
5181
|
-
bottom: elHeight,
|
|
5182
|
-
},
|
|
5183
|
-
layer: 1, // important when comparing with hits from other components
|
|
5184
|
-
};
|
|
5185
|
-
}
|
|
5186
|
-
return null;
|
|
5187
|
-
}
|
|
5188
|
-
}
|
|
5189
|
-
|
|
5190
|
-
class MoreLinkContainer extends BaseComponent {
|
|
5191
|
-
constructor() {
|
|
5192
|
-
super(...arguments);
|
|
5193
|
-
this.state = {
|
|
5194
|
-
isPopoverOpen: false,
|
|
5195
|
-
popoverId: getUniqueDomId(),
|
|
5196
|
-
};
|
|
5197
|
-
this.handleLinkEl = (linkEl) => {
|
|
5198
|
-
this.linkEl = linkEl;
|
|
5199
|
-
if (this.props.elRef) {
|
|
5200
|
-
setRef(this.props.elRef, linkEl);
|
|
5201
|
-
}
|
|
5202
|
-
};
|
|
5203
|
-
this.handleClick = (ev) => {
|
|
5204
|
-
let { props, context } = this;
|
|
5205
|
-
let { moreLinkClick } = context.options;
|
|
5206
|
-
let date = computeRange(props).start;
|
|
5207
|
-
function buildPublicSeg(seg) {
|
|
5208
|
-
let { def, instance, range } = seg.eventRange;
|
|
5209
|
-
return {
|
|
5210
|
-
event: new EventImpl(context, def, instance),
|
|
5211
|
-
start: context.dateEnv.toDate(range.start),
|
|
5212
|
-
end: context.dateEnv.toDate(range.end),
|
|
5213
|
-
isStart: seg.isStart,
|
|
5214
|
-
isEnd: seg.isEnd,
|
|
5215
|
-
};
|
|
5216
|
-
}
|
|
5217
|
-
if (typeof moreLinkClick === 'function') {
|
|
5218
|
-
moreLinkClick = moreLinkClick({
|
|
5219
|
-
date,
|
|
5220
|
-
allDay: Boolean(props.allDayDate),
|
|
5221
|
-
allSegs: props.segs.map(buildPublicSeg),
|
|
5222
|
-
hiddenSegs: props.hiddenSegs.map(buildPublicSeg),
|
|
5223
|
-
jsEvent: ev,
|
|
5224
|
-
view: context.viewApi,
|
|
5225
|
-
});
|
|
5226
|
-
}
|
|
5227
|
-
if (!moreLinkClick || moreLinkClick === 'popover') {
|
|
5228
|
-
this.setState({ isPopoverOpen: true });
|
|
5229
|
-
}
|
|
5230
|
-
else if (typeof moreLinkClick === 'string') { // a view name
|
|
5231
|
-
context.calendarApi.zoomTo(date, moreLinkClick);
|
|
5232
|
-
}
|
|
5233
|
-
};
|
|
5234
|
-
this.handlePopoverClose = () => {
|
|
5235
|
-
this.setState({ isPopoverOpen: false });
|
|
5236
|
-
};
|
|
5237
|
-
}
|
|
5238
|
-
render() {
|
|
5239
|
-
let { props, state } = this;
|
|
5240
|
-
return (_(ViewContextType.Consumer, null, (context) => {
|
|
5241
|
-
let { viewApi, options, calendarApi } = context;
|
|
5242
|
-
let { moreLinkText } = options;
|
|
5243
|
-
let moreCnt = props.hiddenSegs.length;
|
|
5244
|
-
let range = computeRange(props);
|
|
5245
|
-
let text = typeof moreLinkText === 'function' // TODO: eventually use formatWithOrdinals
|
|
5246
|
-
? moreLinkText.call(calendarApi, moreCnt)
|
|
5247
|
-
: `+${moreCnt} ${moreLinkText}`;
|
|
5248
|
-
let hint = formatWithOrdinals(options.moreLinkHint, [moreCnt], text);
|
|
5249
|
-
let renderProps = {
|
|
5250
|
-
num: moreCnt,
|
|
5251
|
-
shortText: `+${moreCnt}`,
|
|
5252
|
-
text,
|
|
5253
|
-
view: viewApi,
|
|
5254
|
-
};
|
|
5255
|
-
return (_(k$1, null,
|
|
5256
|
-
Boolean(moreCnt) && (_(ContentContainer, { elTag: props.elTag || 'a', elRef: this.handleLinkEl, elClasses: [
|
|
5257
|
-
...(props.elClasses || []),
|
|
5258
|
-
'fc-more-link',
|
|
5259
|
-
], elStyle: props.elStyle, elAttrs: Object.assign(Object.assign(Object.assign({}, props.elAttrs), createAriaClickAttrs(this.handleClick)), { title: hint, 'aria-expanded': state.isPopoverOpen, 'aria-controls': state.isPopoverOpen ? state.popoverId : '' }), renderProps: renderProps, generatorName: "moreLinkContent", customGenerator: options.moreLinkContent, defaultGenerator: props.defaultGenerator || renderMoreLinkInner, classNameGenerator: options.moreLinkClassNames, didMount: options.moreLinkDidMount, willUnmount: options.moreLinkWillUnmount }, props.children)),
|
|
5260
|
-
state.isPopoverOpen && (_(MorePopover, { id: state.popoverId, startDate: range.start, endDate: range.end, dateProfile: props.dateProfile, todayRange: props.todayRange, extraDateSpan: props.extraDateSpan, parentEl: this.parentEl, alignmentEl: props.alignmentElRef ?
|
|
5261
|
-
props.alignmentElRef.current :
|
|
5262
|
-
this.linkEl, alignGridTop: props.alignGridTop, forceTimed: props.forceTimed, onClose: this.handlePopoverClose }, props.popoverContent()))));
|
|
5263
|
-
}));
|
|
5264
|
-
}
|
|
5265
|
-
componentDidMount() {
|
|
5266
|
-
this.updateParentEl();
|
|
5267
|
-
}
|
|
5268
|
-
componentDidUpdate() {
|
|
5269
|
-
this.updateParentEl();
|
|
5270
|
-
}
|
|
5271
|
-
updateParentEl() {
|
|
5272
|
-
if (this.linkEl) {
|
|
5273
|
-
this.parentEl = elementClosest(this.linkEl, '.fc-view-harness'); // HACK. reconsider
|
|
5274
|
-
}
|
|
5275
|
-
}
|
|
5276
|
-
}
|
|
5277
|
-
function renderMoreLinkInner(props) {
|
|
5278
|
-
return props.text;
|
|
5279
|
-
}
|
|
5280
|
-
function computeRange(props) {
|
|
5281
|
-
if (props.allDayDate) {
|
|
5282
|
-
return {
|
|
5283
|
-
start: props.allDayDate,
|
|
5284
|
-
end: addDays(props.allDayDate, 1),
|
|
5285
|
-
};
|
|
5286
|
-
}
|
|
5287
|
-
return {
|
|
5288
|
-
start: computeEarliestSegStart(props.hiddenSegs),
|
|
5289
|
-
end: computeLatestSegEnd(props.hiddenSegs),
|
|
5290
|
-
};
|
|
5291
|
-
}
|
|
5292
|
-
function computeEarliestSegStart(segs) {
|
|
5293
|
-
return segs.reduce(pickEarliestStart).eventRange.range.start;
|
|
5294
|
-
}
|
|
5295
|
-
function pickEarliestStart(seg0, seg1) {
|
|
5296
|
-
return seg0.eventRange.range.start < seg1.eventRange.range.start ? seg0 : seg1;
|
|
5297
|
-
}
|
|
5298
|
-
function computeLatestSegEnd(segs) {
|
|
5299
|
-
return segs.reduce(pickLatestEnd).eventRange.range.end;
|
|
5300
|
-
}
|
|
5301
|
-
function pickLatestEnd(seg0, seg1) {
|
|
5302
|
-
return seg0.eventRange.range.end > seg1.eventRange.range.end ? seg0 : seg1;
|
|
5303
|
-
}
|
|
5304
|
-
|
|
5305
|
-
class SegHierarchy {
|
|
5306
|
-
constructor(getEntryThickness = (entry) => {
|
|
5307
|
-
// if no thickness known, assume 1 (if 0, so small it always fits)
|
|
5308
|
-
return entry.thickness;
|
|
5309
|
-
}) {
|
|
5310
|
-
this.getEntryThickness = getEntryThickness;
|
|
5311
|
-
// settings
|
|
5312
|
-
this.strictOrder = false;
|
|
5313
|
-
this.allowReslicing = false;
|
|
5314
|
-
this.maxCoord = -1; // -1 means no max
|
|
5315
|
-
this.maxStackCnt = -1; // -1 means no max
|
|
5316
|
-
this.levelCoords = []; // ordered
|
|
5317
|
-
this.entriesByLevel = []; // parallel with levelCoords
|
|
5318
|
-
this.stackCnts = {}; // TODO: use better technique!?
|
|
5319
|
-
}
|
|
5320
|
-
addSegs(inputs) {
|
|
5321
|
-
let hiddenEntries = [];
|
|
5322
|
-
for (let input of inputs) {
|
|
5323
|
-
this.insertEntry(input, hiddenEntries);
|
|
5324
|
-
}
|
|
5325
|
-
return hiddenEntries;
|
|
5326
|
-
}
|
|
5327
|
-
insertEntry(entry, hiddenEntries) {
|
|
5328
|
-
let entryThickness = this.getEntryThickness(entry);
|
|
5329
|
-
if (entryThickness == null) {
|
|
5330
|
-
hiddenEntries.push(entry);
|
|
5331
|
-
}
|
|
5332
|
-
else {
|
|
5333
|
-
let insertion = this.findInsertion(entry, entryThickness);
|
|
5334
|
-
if (this.isInsertionValid(insertion, entry, entryThickness)) {
|
|
5335
|
-
this.insertEntryAt(entry, insertion);
|
|
5336
|
-
}
|
|
5337
|
-
else {
|
|
5338
|
-
this.handleInvalidInsertion(insertion, entry, hiddenEntries);
|
|
5339
|
-
}
|
|
5340
|
-
}
|
|
5341
|
-
}
|
|
5342
|
-
isInsertionValid(insertion, entry, entryThickness) {
|
|
5343
|
-
return (this.maxCoord === -1 || insertion.levelCoord + entryThickness <= this.maxCoord) &&
|
|
5344
|
-
(this.maxStackCnt === -1 || insertion.stackCnt < this.maxStackCnt);
|
|
5345
|
-
}
|
|
5346
|
-
handleInvalidInsertion(insertion, entry, hiddenEntries) {
|
|
5347
|
-
if (this.allowReslicing && insertion.touchingEntry) {
|
|
5348
|
-
const hiddenEntry = Object.assign(Object.assign({}, entry), { span: intersectSpans(entry.span, insertion.touchingEntry.span) });
|
|
5349
|
-
hiddenEntries.push(hiddenEntry);
|
|
5350
|
-
this.splitEntry(entry, insertion.touchingEntry, hiddenEntries);
|
|
5351
|
-
}
|
|
5352
|
-
else {
|
|
5353
|
-
hiddenEntries.push(entry);
|
|
5354
|
-
}
|
|
5355
|
-
}
|
|
5356
|
-
/*
|
|
5357
|
-
Does NOT add what hit the `barrier` into hiddenEntries. Should already be done.
|
|
5358
|
-
*/
|
|
5359
|
-
splitEntry(entry, barrier, hiddenEntries) {
|
|
5360
|
-
let entrySpan = entry.span;
|
|
5361
|
-
let barrierSpan = barrier.span;
|
|
5362
|
-
if (entrySpan.start < barrierSpan.start) {
|
|
5363
|
-
this.insertEntry({
|
|
5364
|
-
index: entry.index,
|
|
5365
|
-
seg: entry.seg,
|
|
5366
|
-
thickness: entry.thickness,
|
|
5367
|
-
span: { start: entrySpan.start, end: barrierSpan.start },
|
|
5368
|
-
}, hiddenEntries);
|
|
5369
|
-
}
|
|
5370
|
-
if (entrySpan.end > barrierSpan.end) {
|
|
5371
|
-
this.insertEntry({
|
|
5372
|
-
index: entry.index,
|
|
5373
|
-
seg: entry.seg,
|
|
5374
|
-
thickness: entry.thickness,
|
|
5375
|
-
span: { start: barrierSpan.end, end: entrySpan.end },
|
|
5376
|
-
}, hiddenEntries);
|
|
5377
|
-
}
|
|
5378
|
-
}
|
|
5379
|
-
insertEntryAt(entry, insertion) {
|
|
5380
|
-
let { entriesByLevel, levelCoords } = this;
|
|
5381
|
-
if (insertion.lateral === -1) {
|
|
5382
|
-
// create a new level
|
|
5383
|
-
insertAt(levelCoords, insertion.level, insertion.levelCoord);
|
|
5384
|
-
insertAt(entriesByLevel, insertion.level, [entry]);
|
|
5385
|
-
}
|
|
5386
|
-
else {
|
|
5387
|
-
// insert into existing level
|
|
5388
|
-
insertAt(entriesByLevel[insertion.level], insertion.lateral, entry);
|
|
5389
|
-
}
|
|
5390
|
-
this.stackCnts[buildEntryKey(entry)] = insertion.stackCnt;
|
|
5391
|
-
}
|
|
5392
|
-
/*
|
|
5393
|
-
does not care about limits
|
|
5394
|
-
*/
|
|
5395
|
-
findInsertion(newEntry, newEntryThickness) {
|
|
5396
|
-
let { levelCoords, entriesByLevel, strictOrder, stackCnts } = this;
|
|
5397
|
-
let levelCnt = levelCoords.length;
|
|
5398
|
-
let candidateCoord = 0;
|
|
5399
|
-
let touchingLevel = -1;
|
|
5400
|
-
let touchingLateral = -1;
|
|
5401
|
-
let touchingEntry = null;
|
|
5402
|
-
let stackCnt = 0;
|
|
5403
|
-
for (let trackingLevel = 0; trackingLevel < levelCnt; trackingLevel += 1) {
|
|
5404
|
-
const trackingCoord = levelCoords[trackingLevel];
|
|
5405
|
-
// if the current level is past the placed entry, we have found a good empty space and can stop.
|
|
5406
|
-
// if strictOrder, keep finding more lateral intersections.
|
|
5407
|
-
if (!strictOrder && trackingCoord >= candidateCoord + newEntryThickness) {
|
|
5408
|
-
break;
|
|
5409
|
-
}
|
|
5410
|
-
let trackingEntries = entriesByLevel[trackingLevel];
|
|
5411
|
-
let trackingEntry;
|
|
5412
|
-
let searchRes = binarySearch(trackingEntries, newEntry.span.start, getEntrySpanEnd); // find first entry after newEntry's end
|
|
5413
|
-
let lateralIndex = searchRes[0] + searchRes[1]; // if exact match (which doesn't collide), go to next one
|
|
5414
|
-
while ( // loop through entries that horizontally intersect
|
|
5415
|
-
(trackingEntry = trackingEntries[lateralIndex]) && // but not past the whole entry list
|
|
5416
|
-
trackingEntry.span.start < newEntry.span.end // and not entirely past newEntry
|
|
5417
|
-
) {
|
|
5418
|
-
let trackingEntryBottom = trackingCoord + this.getEntryThickness(trackingEntry);
|
|
5419
|
-
// intersects into the top of the candidate?
|
|
5420
|
-
if (trackingEntryBottom > candidateCoord) {
|
|
5421
|
-
candidateCoord = trackingEntryBottom;
|
|
5422
|
-
touchingEntry = trackingEntry;
|
|
5423
|
-
touchingLevel = trackingLevel;
|
|
5424
|
-
touchingLateral = lateralIndex;
|
|
5425
|
-
}
|
|
5426
|
-
// butts up against top of candidate? (will happen if just intersected as well)
|
|
5427
|
-
if (trackingEntryBottom === candidateCoord) {
|
|
5428
|
-
// accumulate the highest possible stackCnt of the trackingEntries that butt up
|
|
5429
|
-
stackCnt = Math.max(stackCnt, stackCnts[buildEntryKey(trackingEntry)] + 1);
|
|
5430
|
-
}
|
|
5431
|
-
lateralIndex += 1;
|
|
5432
|
-
}
|
|
5433
|
-
}
|
|
5434
|
-
// the destination level will be after touchingEntry's level. find it
|
|
5435
|
-
let destLevel = 0;
|
|
5436
|
-
if (touchingEntry) {
|
|
5437
|
-
destLevel = touchingLevel + 1;
|
|
5438
|
-
while (destLevel < levelCnt && levelCoords[destLevel] < candidateCoord) {
|
|
5439
|
-
destLevel += 1;
|
|
5440
|
-
}
|
|
5441
|
-
}
|
|
5442
|
-
// if adding to an existing level, find where to insert
|
|
5443
|
-
let destLateral = -1;
|
|
5444
|
-
if (destLevel < levelCnt && levelCoords[destLevel] === candidateCoord) {
|
|
5445
|
-
destLateral = binarySearch(entriesByLevel[destLevel], newEntry.span.end, getEntrySpanEnd)[0];
|
|
5446
|
-
}
|
|
5447
|
-
return {
|
|
5448
|
-
touchingLevel,
|
|
5449
|
-
touchingLateral,
|
|
5450
|
-
touchingEntry,
|
|
5451
|
-
stackCnt,
|
|
5452
|
-
levelCoord: candidateCoord,
|
|
5453
|
-
level: destLevel,
|
|
5454
|
-
lateral: destLateral,
|
|
5455
|
-
};
|
|
5456
|
-
}
|
|
5457
|
-
// sorted by levelCoord (lowest to highest)
|
|
5458
|
-
toRects() {
|
|
5459
|
-
let { entriesByLevel, levelCoords } = this;
|
|
5460
|
-
let levelCnt = entriesByLevel.length;
|
|
5461
|
-
let rects = [];
|
|
5462
|
-
for (let level = 0; level < levelCnt; level += 1) {
|
|
5463
|
-
let entries = entriesByLevel[level];
|
|
5464
|
-
let levelCoord = levelCoords[level];
|
|
5465
|
-
for (let entry of entries) {
|
|
5466
|
-
rects.push(Object.assign(Object.assign({}, entry), { thickness: this.getEntryThickness(entry), levelCoord }));
|
|
5467
|
-
}
|
|
5468
|
-
}
|
|
5469
|
-
return rects;
|
|
5470
|
-
}
|
|
5471
|
-
}
|
|
5472
|
-
function getEntrySpanEnd(entry) {
|
|
5473
|
-
return entry.span.end;
|
|
5474
|
-
}
|
|
5475
|
-
/*
|
|
5476
|
-
Generates a unique ID whose lifespan is a single run of SegHierarchy, so can be really specific
|
|
5477
|
-
without fear of accidentally busting the cache on subsequent rerenders
|
|
5478
|
-
*/
|
|
5479
|
-
function buildEntryKey(entry) {
|
|
5480
|
-
return entry.index + ':' + entry.span.start;
|
|
5481
|
-
}
|
|
5482
|
-
/*
|
|
5483
|
-
returns groups with entries sorted by input order
|
|
5484
|
-
*/
|
|
5485
|
-
function groupIntersectingEntries(entries) {
|
|
5486
|
-
let merges = [];
|
|
5487
|
-
for (let entry of entries) {
|
|
5488
|
-
let filteredMerges = [];
|
|
5489
|
-
let hungryMerge = {
|
|
5490
|
-
span: entry.span,
|
|
5491
|
-
entries: [entry],
|
|
5492
|
-
};
|
|
5493
|
-
for (let merge of merges) {
|
|
5494
|
-
if (intersectSpans(merge.span, hungryMerge.span)) {
|
|
5495
|
-
hungryMerge = {
|
|
5496
|
-
span: joinSpans(merge.span, hungryMerge.span),
|
|
5497
|
-
entries: merge.entries.concat(hungryMerge.entries), // keep preexisting merge's items first. maintains order
|
|
5498
|
-
};
|
|
5499
|
-
}
|
|
5500
|
-
else {
|
|
5501
|
-
filteredMerges.push(merge);
|
|
5502
|
-
}
|
|
5503
|
-
}
|
|
5504
|
-
filteredMerges.push(hungryMerge);
|
|
5505
|
-
merges = filteredMerges;
|
|
5506
|
-
}
|
|
5507
|
-
return merges.map((merge) => {
|
|
5508
|
-
const segs = merge.entries.map(extractEntrySeg);
|
|
5509
|
-
return {
|
|
5510
|
-
key: buildIsoString(computeEarliestSegStart(segs)),
|
|
5511
|
-
span: merge.span,
|
|
5512
|
-
segs,
|
|
5513
|
-
};
|
|
5514
|
-
});
|
|
5515
|
-
}
|
|
5516
|
-
function extractEntrySeg(entry) {
|
|
5517
|
-
return entry.seg;
|
|
5518
|
-
}
|
|
5519
|
-
function joinSpans(span0, span1) {
|
|
5520
|
-
return {
|
|
5521
|
-
start: Math.min(span0.start, span1.start),
|
|
5522
|
-
end: Math.max(span0.end, span1.end),
|
|
5523
|
-
};
|
|
5524
|
-
}
|
|
5525
|
-
function intersectSpans(span0, span1) {
|
|
5526
|
-
let start = Math.max(span0.start, span1.start);
|
|
5527
|
-
let end = Math.min(span0.end, span1.end);
|
|
5528
|
-
if (start < end) {
|
|
5529
|
-
return { start, end };
|
|
5530
|
-
}
|
|
5531
|
-
return null;
|
|
5532
|
-
}
|
|
5533
|
-
// general util
|
|
5534
|
-
// ---------------------------------------------------------------------------------------------------------------------
|
|
5535
|
-
function insertAt(arr, index, item) {
|
|
5536
|
-
arr.splice(index, 0, item);
|
|
5178
|
+
// General Utils
|
|
5179
|
+
// -------------------------------------------------------------------------------------------------
|
|
5180
|
+
function insertAt(arr, index, item) {
|
|
5181
|
+
arr.splice(index, 0, item);
|
|
5537
5182
|
}
|
|
5538
5183
|
function binarySearch(a, searchVal, getItemVal) {
|
|
5539
5184
|
let startIndex = 0;
|
|
@@ -5646,14 +5291,14 @@ var FullCalendar = (function (exports) {
|
|
|
5646
5291
|
forPrint: false,
|
|
5647
5292
|
};
|
|
5648
5293
|
this.handleBeforePrint = () => {
|
|
5649
|
-
|
|
5650
|
-
|
|
5651
|
-
|
|
5294
|
+
this.setState({ forPrint: true });
|
|
5295
|
+
flushSync(() => { }); // TODO: use noop
|
|
5296
|
+
updateSizeSync();
|
|
5297
|
+
flushSync(() => { }); // TODO: use noop
|
|
5652
5298
|
};
|
|
5653
5299
|
this.handleAfterPrint = () => {
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
});
|
|
5300
|
+
this.setState({ forPrint: false });
|
|
5301
|
+
flushSync(() => { }); // TODO: use noop
|
|
5657
5302
|
};
|
|
5658
5303
|
}
|
|
5659
5304
|
render() {
|
|
@@ -5664,7 +5309,7 @@ var FullCalendar = (function (exports) {
|
|
|
5664
5309
|
'fc',
|
|
5665
5310
|
forPrint ? 'fc-media-print' : 'fc-media-screen',
|
|
5666
5311
|
`fc-direction-${options.direction}`,
|
|
5667
|
-
props.theme.
|
|
5312
|
+
props.theme.getClassName('root'),
|
|
5668
5313
|
];
|
|
5669
5314
|
return props.children(classNames, options.height, forPrint);
|
|
5670
5315
|
}
|
|
@@ -5712,8 +5357,8 @@ var FullCalendar = (function (exports) {
|
|
|
5712
5357
|
clippedLastIndex = Math.floor(clippedLastIndex); // in-between ends round to prev cell
|
|
5713
5358
|
if (clippedFirstIndex <= clippedLastIndex) {
|
|
5714
5359
|
return {
|
|
5715
|
-
|
|
5716
|
-
|
|
5360
|
+
start: clippedFirstIndex,
|
|
5361
|
+
end: clippedLastIndex + 1,
|
|
5717
5362
|
isStart: firstIndex === clippedFirstIndex,
|
|
5718
5363
|
isEnd: lastIndex === clippedLastIndex,
|
|
5719
5364
|
};
|
|
@@ -5794,17 +5439,17 @@ var FullCalendar = (function (exports) {
|
|
|
5794
5439
|
let seriesSeg = this.daySeries.sliceRange(range);
|
|
5795
5440
|
let segs = [];
|
|
5796
5441
|
if (seriesSeg) {
|
|
5797
|
-
|
|
5798
|
-
let index =
|
|
5799
|
-
while (index
|
|
5442
|
+
const { start, end } = seriesSeg;
|
|
5443
|
+
let index = start;
|
|
5444
|
+
while (index < end) {
|
|
5800
5445
|
let row = Math.floor(index / colCnt);
|
|
5801
|
-
let nextIndex = Math.min((row + 1) * colCnt,
|
|
5446
|
+
let nextIndex = Math.min((row + 1) * colCnt, end);
|
|
5802
5447
|
segs.push({
|
|
5803
5448
|
row,
|
|
5804
|
-
|
|
5805
|
-
|
|
5806
|
-
isStart: seriesSeg.isStart && index ===
|
|
5807
|
-
isEnd: seriesSeg.isEnd &&
|
|
5449
|
+
start: index % colCnt,
|
|
5450
|
+
end: (nextIndex - 1) % colCnt + 1,
|
|
5451
|
+
isStart: seriesSeg.isStart && index === start,
|
|
5452
|
+
isEnd: seriesSeg.isEnd && nextIndex === end,
|
|
5808
5453
|
});
|
|
5809
5454
|
index = nextIndex;
|
|
5810
5455
|
}
|
|
@@ -5886,12 +5531,11 @@ var FullCalendar = (function (exports) {
|
|
|
5886
5531
|
}
|
|
5887
5532
|
}
|
|
5888
5533
|
|
|
5889
|
-
const WHEEL_EVENT_NAMES = 'wheel mousewheel DomMouseScroll MozMousePixelScroll'.split(' ');
|
|
5890
5534
|
/*
|
|
5891
5535
|
Fires:
|
|
5892
|
-
- scrollStart (
|
|
5893
|
-
- scroll
|
|
5894
|
-
- scrollEnd (
|
|
5536
|
+
- scrollStart: (isUser) => void
|
|
5537
|
+
- scroll: (isUser) => void
|
|
5538
|
+
- scrollEnd: (isUser) => void
|
|
5895
5539
|
|
|
5896
5540
|
NOTE: detection is complicated (w/ touch and wheel) because ScrollerSyncer needs to know about it,
|
|
5897
5541
|
but are we sure we can't just ignore programmatic scrollTo() calls with a flag? and determine the
|
|
@@ -5901,142 +5545,154 @@ var FullCalendar = (function (exports) {
|
|
|
5901
5545
|
constructor(el) {
|
|
5902
5546
|
this.el = el;
|
|
5903
5547
|
this.emitter = new Emitter();
|
|
5904
|
-
this.
|
|
5905
|
-
this.
|
|
5906
|
-
this.
|
|
5907
|
-
this.
|
|
5908
|
-
this.
|
|
5909
|
-
|
|
5548
|
+
this.isScroll = false;
|
|
5549
|
+
this.isScrollRecent = false;
|
|
5550
|
+
this.isWheelRecent = false;
|
|
5551
|
+
this.isMouseDown = false; // user currently has mouse down?
|
|
5552
|
+
this.isTouchDown = false; // user currently has finger down?
|
|
5553
|
+
// accumulated during scroll
|
|
5554
|
+
this.isMouse = false;
|
|
5555
|
+
this.isTouch = false;
|
|
5556
|
+
this.isWheel = false;
|
|
5910
5557
|
// Handlers
|
|
5911
5558
|
// ----------------------------------------------------------------------------------------------
|
|
5912
5559
|
this.handleScroll = () => {
|
|
5913
5560
|
this.startScroll();
|
|
5914
|
-
this.emitter.trigger('scroll', this.
|
|
5915
|
-
this.
|
|
5561
|
+
this.emitter.trigger('scroll', this.getIsUser());
|
|
5562
|
+
this.isScrollRecent = true;
|
|
5563
|
+
if (this.isMouseDown) {
|
|
5564
|
+
this.isMouse = true;
|
|
5565
|
+
}
|
|
5566
|
+
if (this.isTouchDown) {
|
|
5567
|
+
this.isTouch = true;
|
|
5568
|
+
}
|
|
5569
|
+
if (this.isWheelRecent) {
|
|
5570
|
+
this.isWheel = true;
|
|
5571
|
+
}
|
|
5916
5572
|
this.scrollWaiter.request(500);
|
|
5917
5573
|
};
|
|
5918
|
-
|
|
5574
|
+
this.handleScrollWait = () => {
|
|
5575
|
+
this.isScrollRecent = false;
|
|
5576
|
+
// only end the scroll if not currently touching.
|
|
5577
|
+
// if touching, the scrolling will end later, on touchend.
|
|
5578
|
+
if (!this.isTouchDown) {
|
|
5579
|
+
this.endScroll();
|
|
5580
|
+
}
|
|
5581
|
+
};
|
|
5582
|
+
// will fire *before* the scroll event is fired (might not cause a scroll!)
|
|
5919
5583
|
this.handleWheel = () => {
|
|
5920
|
-
this.
|
|
5584
|
+
this.isWheelRecent = true;
|
|
5921
5585
|
this.wheelWaiter.request(500);
|
|
5922
5586
|
};
|
|
5923
|
-
|
|
5587
|
+
this.handleWheelWait = () => {
|
|
5588
|
+
this.isWheelRecent = false;
|
|
5589
|
+
};
|
|
5590
|
+
this.handleMouseDown = () => {
|
|
5591
|
+
this.isMouseDown = true;
|
|
5592
|
+
};
|
|
5593
|
+
this.handleMouseUp = () => {
|
|
5594
|
+
this.isMouseDown = false;
|
|
5595
|
+
};
|
|
5596
|
+
// will fire *before* the scroll event is fired (might not cause a scroll!)
|
|
5924
5597
|
this.handleTouchStart = () => {
|
|
5925
|
-
this.
|
|
5598
|
+
this.isTouchDown = true;
|
|
5926
5599
|
};
|
|
5927
5600
|
this.handleTouchEnd = () => {
|
|
5928
|
-
this.
|
|
5601
|
+
this.isTouchDown = false;
|
|
5929
5602
|
// if the user ended their touch, and the scroll area wasn't moving,
|
|
5930
|
-
// we consider this to be the end of the scroll
|
|
5931
|
-
|
|
5932
|
-
|
|
5603
|
+
// we consider this to be the end of the scroll
|
|
5604
|
+
// otherwise, wait for inertia to finish and handleScrollWait to fire
|
|
5605
|
+
if (!this.isScrollRecent) {
|
|
5606
|
+
this.endScroll();
|
|
5933
5607
|
}
|
|
5934
5608
|
};
|
|
5609
|
+
this.wheelWaiter = new DelayedRunner(this.handleWheelWait);
|
|
5610
|
+
this.scrollWaiter = new DelayedRunner(this.handleScrollWait);
|
|
5935
5611
|
el.addEventListener('scroll', this.handleScroll);
|
|
5612
|
+
el.addEventListener('wheel', this.handleWheel, { passive: true });
|
|
5613
|
+
el.addEventListener('mousedown', this.handleMouseDown);
|
|
5614
|
+
el.addEventListener('mouseup', this.handleMouseUp);
|
|
5936
5615
|
el.addEventListener('touchstart', this.handleTouchStart, { passive: true });
|
|
5937
5616
|
el.addEventListener('touchend', this.handleTouchEnd);
|
|
5938
|
-
for (let eventName of WHEEL_EVENT_NAMES) {
|
|
5939
|
-
el.addEventListener(eventName, this.handleWheel, { passive: true });
|
|
5940
|
-
}
|
|
5941
5617
|
}
|
|
5942
5618
|
destroy() {
|
|
5943
5619
|
let { el } = this;
|
|
5944
5620
|
el.removeEventListener('scroll', this.handleScroll);
|
|
5621
|
+
el.removeEventListener('wheel', this.handleWheel, { passive: true });
|
|
5622
|
+
el.removeEventListener('mousedown', this.handleMouseDown);
|
|
5623
|
+
el.removeEventListener('mouseup', this.handleMouseUp);
|
|
5945
5624
|
el.removeEventListener('touchstart', this.handleTouchStart, { passive: true });
|
|
5946
5625
|
el.removeEventListener('touchend', this.handleTouchEnd);
|
|
5947
|
-
for (let eventName of WHEEL_EVENT_NAMES) {
|
|
5948
|
-
el.removeEventListener(eventName, this.handleWheel, { passive: true });
|
|
5949
|
-
}
|
|
5950
5626
|
}
|
|
5951
5627
|
// Start / Stop
|
|
5952
5628
|
// ----------------------------------------------------------------------------------------------
|
|
5953
5629
|
startScroll() {
|
|
5954
|
-
if (!this.
|
|
5955
|
-
this.
|
|
5956
|
-
this.emitter.trigger('scrollStart', this.
|
|
5630
|
+
if (!this.isScroll) {
|
|
5631
|
+
this.isScroll = true;
|
|
5632
|
+
this.emitter.trigger('scrollStart', this.getIsUser());
|
|
5957
5633
|
}
|
|
5958
5634
|
}
|
|
5959
5635
|
endScroll() {
|
|
5960
|
-
if (this.
|
|
5961
|
-
this.
|
|
5962
|
-
this.
|
|
5963
|
-
this.
|
|
5964
|
-
this.
|
|
5965
|
-
this.
|
|
5966
|
-
this.
|
|
5967
|
-
|
|
5968
|
-
|
|
5969
|
-
_handleScrollWaited() {
|
|
5970
|
-
this.isRecentlyScrolled = false;
|
|
5971
|
-
// only end the scroll if not currently touching.
|
|
5972
|
-
// if touching, the scrolling will end later, on touchend.
|
|
5973
|
-
if (!this.isTouching) {
|
|
5974
|
-
this.endScroll(); // won't fire if already ended
|
|
5636
|
+
if (this.isScroll) { // extra protection because might be called publicly
|
|
5637
|
+
this.scrollWaiter.clear(); // (same)
|
|
5638
|
+
this.wheelWaiter.clear(); // (same)
|
|
5639
|
+
this.isScroll = false;
|
|
5640
|
+
this.isWheelRecent = false;
|
|
5641
|
+
this.emitter.trigger('scrollEnd', this.getIsUser());
|
|
5642
|
+
this.isMouse = false;
|
|
5643
|
+
this.isTouch = false;
|
|
5644
|
+
this.isWheel = false;
|
|
5975
5645
|
}
|
|
5976
5646
|
}
|
|
5977
|
-
|
|
5978
|
-
this.
|
|
5647
|
+
getIsUser() {
|
|
5648
|
+
return this.isWheel || this.isMouse || this.isTouch;
|
|
5979
5649
|
}
|
|
5980
5650
|
}
|
|
5981
5651
|
|
|
5982
5652
|
class Scroller extends DateComponent {
|
|
5983
5653
|
constructor() {
|
|
5984
5654
|
super(...arguments);
|
|
5985
|
-
|
|
5986
|
-
|
|
5655
|
+
this.handleEl = (el) => {
|
|
5656
|
+
const { props } = this;
|
|
5657
|
+
if (this.el) {
|
|
5658
|
+
this.el = null;
|
|
5659
|
+
this.listener.destroy();
|
|
5660
|
+
this.disconnectSize();
|
|
5661
|
+
setRef(props.clientWidthRef, null);
|
|
5662
|
+
setRef(props.clientHeightRef, null);
|
|
5663
|
+
setRef(props.endScrollbarWidthRef, null);
|
|
5664
|
+
setRef(props.bottomScrollbarWidthRef, null);
|
|
5665
|
+
}
|
|
5666
|
+
if (el) {
|
|
5667
|
+
this.el = el;
|
|
5668
|
+
this.listener = new ScrollListener(el);
|
|
5669
|
+
this.disconnectSize = watchSize(el, (clientWidth, clientHeight) => {
|
|
5670
|
+
const { props } = this;
|
|
5671
|
+
const endScrollbarWidth = el.offsetWidth - clientWidth;
|
|
5672
|
+
const bottomScrollbarWidth = el.offsetHeight - clientHeight;
|
|
5673
|
+
if (this.currentClientWidth !== clientWidth) {
|
|
5674
|
+
setRef(props.clientWidthRef, this.currentClientWidth = clientWidth);
|
|
5675
|
+
}
|
|
5676
|
+
if (this.currentClientHeight !== clientHeight) {
|
|
5677
|
+
setRef(props.clientHeightRef, this.currentClientHeight = clientHeight);
|
|
5678
|
+
}
|
|
5679
|
+
// are these isDimsEqual calls necessary?
|
|
5680
|
+
if (!isDimsEqual(this.currentBottomScrollbarWidth, bottomScrollbarWidth)) {
|
|
5681
|
+
setRef(props.bottomScrollbarWidthRef, this.currentBottomScrollbarWidth = bottomScrollbarWidth);
|
|
5682
|
+
}
|
|
5683
|
+
if (!isDimsEqual(this.currentEndScrollbarWidth, endScrollbarWidth)) {
|
|
5684
|
+
setRef(props.endScrollbarWidthRef, this.currentEndScrollbarWidth = endScrollbarWidth);
|
|
5685
|
+
}
|
|
5686
|
+
}, /* client(width+height) = */ true);
|
|
5687
|
+
}
|
|
5688
|
+
};
|
|
5987
5689
|
}
|
|
5988
5690
|
render() {
|
|
5989
5691
|
const { props } = this;
|
|
5990
5692
|
// if there's only one axis that needs scrolling, the other axis will unintentionally have
|
|
5991
|
-
// scrollbars too
|
|
5693
|
+
// scrollbars too if we don't force to 'hidden'
|
|
5992
5694
|
const fallbackOverflow = (props.horizontal || props.vertical) ? 'hidden' : '';
|
|
5993
|
-
return (_("div", { ref: this.
|
|
5994
|
-
'fc-scroller',
|
|
5995
|
-
props.hideScrollbars ? 'fc-scroller-nobars' : '',
|
|
5996
|
-
...(props.elClassNames || []),
|
|
5997
|
-
].join(' '), style: Object.assign(Object.assign({}, props.elStyle), { overflowX: props.horizontal ? 'auto' : fallbackOverflow, overflowY: props.vertical ? 'auto' : fallbackOverflow }) }, props.children));
|
|
5998
|
-
}
|
|
5999
|
-
componentDidMount() {
|
|
6000
|
-
const el = this.elRef.current; // TODO: make dynamic with useEffect
|
|
6001
|
-
this.listener = new ScrollListener(el);
|
|
6002
|
-
this.disconnectSize = watchSize(el, (contentWidth, contentHeight) => {
|
|
6003
|
-
const { props, context } = this;
|
|
6004
|
-
const bottomScrollbarWidth = el.offsetHeight - el.clientHeight;
|
|
6005
|
-
const horizontalScrollbarWidth = el.offsetWidth - el.clientWidth;
|
|
6006
|
-
let rightScrollbarWidth = 0;
|
|
6007
|
-
let leftScrollbarWidth = 0;
|
|
6008
|
-
if (context.isRtl && getRtlScrollerConfig().leftScrollbars) {
|
|
6009
|
-
leftScrollbarWidth = horizontalScrollbarWidth;
|
|
6010
|
-
}
|
|
6011
|
-
else {
|
|
6012
|
-
rightScrollbarWidth = horizontalScrollbarWidth;
|
|
6013
|
-
}
|
|
6014
|
-
if (!isDimsEqual(this.currentWidth, contentWidth)) {
|
|
6015
|
-
setRef(props.widthRef, this.currentWidth = contentWidth);
|
|
6016
|
-
}
|
|
6017
|
-
if (!isDimsEqual(this.currentHeight, contentHeight)) {
|
|
6018
|
-
setRef(props.heightRef, this.currentHeight = contentHeight);
|
|
6019
|
-
}
|
|
6020
|
-
if (!isDimsEqual(this.currentBottomScrollbarWidth, bottomScrollbarWidth)) {
|
|
6021
|
-
setRef(props.bottomScrollbarWidthRef, this.currentBottomScrollbarWidth = bottomScrollbarWidth);
|
|
6022
|
-
}
|
|
6023
|
-
if (!isDimsEqual(this.currentRightScrollbarWidth, rightScrollbarWidth)) {
|
|
6024
|
-
setRef(props.rightScrollbarWidthRef, this.currentRightScrollbarWidth = rightScrollbarWidth);
|
|
6025
|
-
}
|
|
6026
|
-
if (!isDimsEqual(this.currentLeftScrollbarWidth, leftScrollbarWidth)) {
|
|
6027
|
-
setRef(props.leftScrollbarWidthRef, this.currentLeftScrollbarWidth = leftScrollbarWidth);
|
|
6028
|
-
}
|
|
6029
|
-
});
|
|
6030
|
-
}
|
|
6031
|
-
componentWillUnmount() {
|
|
6032
|
-
const { props } = this;
|
|
6033
|
-
this.disconnectSize();
|
|
6034
|
-
this.listener.destroy();
|
|
6035
|
-
setRef(props.widthRef, null);
|
|
6036
|
-
setRef(props.heightRef, null);
|
|
6037
|
-
setRef(props.bottomScrollbarWidthRef, null);
|
|
6038
|
-
setRef(props.rightScrollbarWidthRef, null);
|
|
6039
|
-
setRef(props.leftScrollbarWidthRef, null);
|
|
5695
|
+
return (_("div", { ref: this.handleEl, className: joinClassNames(props.className, 'fc-scroller', props.hideScrollbars && 'fc-scroller-no-bars'), style: Object.assign(Object.assign({}, props.style), { overflowX: props.horizontal ? 'auto' : fallbackOverflow, overflowY: props.vertical ? 'auto' : fallbackOverflow }) }, props.children));
|
|
6040
5696
|
}
|
|
6041
5697
|
endScroll() {
|
|
6042
5698
|
this.listener.endScroll();
|
|
@@ -6045,21 +5701,23 @@ var FullCalendar = (function (exports) {
|
|
|
6045
5701
|
// -----------------------------------------------------------------------------------------------
|
|
6046
5702
|
get x() {
|
|
6047
5703
|
const { isRtl } = this.context;
|
|
6048
|
-
const el = this
|
|
6049
|
-
return getNormalizedScrollX(el, isRtl);
|
|
5704
|
+
const { el } = this;
|
|
5705
|
+
return el ? getNormalizedScrollX(el, isRtl) : 0;
|
|
6050
5706
|
}
|
|
6051
5707
|
get y() {
|
|
6052
|
-
const el = this
|
|
6053
|
-
return el.scrollTop;
|
|
5708
|
+
const { el } = this;
|
|
5709
|
+
return el ? el.scrollTop : 0;
|
|
6054
5710
|
}
|
|
6055
5711
|
scrollTo({ x, y }) {
|
|
6056
5712
|
const { isRtl } = this.context;
|
|
6057
|
-
const el = this
|
|
6058
|
-
if (
|
|
6059
|
-
|
|
6060
|
-
|
|
6061
|
-
|
|
6062
|
-
|
|
5713
|
+
const { el } = this;
|
|
5714
|
+
if (el) {
|
|
5715
|
+
if (y != null) {
|
|
5716
|
+
el.scrollTop = y;
|
|
5717
|
+
}
|
|
5718
|
+
if (x != null) {
|
|
5719
|
+
setNormalizedScrollX(el, isRtl, x);
|
|
5720
|
+
}
|
|
6063
5721
|
}
|
|
6064
5722
|
}
|
|
6065
5723
|
addScrollEndListener(handler) {
|
|
@@ -6071,7 +5729,7 @@ var FullCalendar = (function (exports) {
|
|
|
6071
5729
|
}
|
|
6072
5730
|
// Public API
|
|
6073
5731
|
// -------------------------------------------------------------------------------------------------
|
|
6074
|
-
//
|
|
5732
|
+
// We can drop normalization when support for Chromium-based <86 is dropped (see Notion)
|
|
6075
5733
|
function getNormalizedScrollX(el, isRtl) {
|
|
6076
5734
|
const { scrollLeft } = el;
|
|
6077
5735
|
return isRtl ? getNormalizedRtlScrollX(scrollLeft, el) : scrollLeft;
|
|
@@ -6083,7 +5741,7 @@ var FullCalendar = (function (exports) {
|
|
|
6083
5741
|
Returns a value in the 'reverse' system
|
|
6084
5742
|
*/
|
|
6085
5743
|
function getNormalizedRtlScrollX(scrollLeft, el) {
|
|
6086
|
-
switch (
|
|
5744
|
+
switch (getRtlScrollerSystem()) {
|
|
6087
5745
|
case 'positive':
|
|
6088
5746
|
return el.scrollWidth - el.clientWidth - scrollLeft;
|
|
6089
5747
|
case 'negative':
|
|
@@ -6097,7 +5755,7 @@ var FullCalendar = (function (exports) {
|
|
|
6097
5755
|
If so, consolidate. With isRtl check too
|
|
6098
5756
|
*/
|
|
6099
5757
|
function getNormalizedRtlScrollLeft(x, el) {
|
|
6100
|
-
switch (
|
|
5758
|
+
switch (getRtlScrollerSystem()) {
|
|
6101
5759
|
case 'positive':
|
|
6102
5760
|
return el.scrollWidth - el.clientWidth - x;
|
|
6103
5761
|
case 'negative':
|
|
@@ -6105,11 +5763,14 @@ var FullCalendar = (function (exports) {
|
|
|
6105
5763
|
}
|
|
6106
5764
|
return x;
|
|
6107
5765
|
}
|
|
6108
|
-
let
|
|
6109
|
-
function
|
|
6110
|
-
return
|
|
5766
|
+
let _rtlScrollerSystem;
|
|
5767
|
+
function getRtlScrollerSystem() {
|
|
5768
|
+
return _rtlScrollerSystem || (_rtlScrollerSystem = detectRtlScrollerSystem());
|
|
6111
5769
|
}
|
|
6112
|
-
|
|
5770
|
+
/*
|
|
5771
|
+
TODO: make this more minimal now that scrollbar-side detection isn't needed?
|
|
5772
|
+
*/
|
|
5773
|
+
function detectRtlScrollerSystem() {
|
|
6113
5774
|
let el = document.createElement('div');
|
|
6114
5775
|
el.style.position = 'absolute';
|
|
6115
5776
|
el.style.top = '-1000px';
|
|
@@ -6135,9 +5796,8 @@ var FullCalendar = (function (exports) {
|
|
|
6135
5796
|
system = 'negative'; // scroll is a negative number from the right edge
|
|
6136
5797
|
}
|
|
6137
5798
|
}
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
return { system, leftScrollbars: !rightScrollbars };
|
|
5799
|
+
el.remove();
|
|
5800
|
+
return system;
|
|
6141
5801
|
}
|
|
6142
5802
|
|
|
6143
5803
|
class Slicer {
|
|
@@ -6233,7 +5893,7 @@ var FullCalendar = (function (exports) {
|
|
|
6233
5893
|
end: addDays(dateRange.start, 1),
|
|
6234
5894
|
};
|
|
6235
5895
|
}
|
|
6236
|
-
let segs = this.sliceRange(dateRange, ...extraArgs);
|
|
5896
|
+
let segs = this.sliceRange(dateRange, ...extraArgs); // !!!
|
|
6237
5897
|
for (let seg of segs) {
|
|
6238
5898
|
seg.eventRange = eventRange;
|
|
6239
5899
|
seg.isStart = eventRange.isStart && seg.isStart;
|
|
@@ -6653,7 +6313,7 @@ var FullCalendar = (function (exports) {
|
|
|
6653
6313
|
else {
|
|
6654
6314
|
current.set(key, val);
|
|
6655
6315
|
}
|
|
6656
|
-
this.rev = guid();
|
|
6316
|
+
this.rev = guid$1();
|
|
6657
6317
|
if (this.masterCallback) {
|
|
6658
6318
|
this.masterCallback(val, key);
|
|
6659
6319
|
}
|
|
@@ -6730,6 +6390,200 @@ var FullCalendar = (function (exports) {
|
|
|
6730
6390
|
return { start, end };
|
|
6731
6391
|
}
|
|
6732
6392
|
|
|
6393
|
+
class ContentInjector extends BaseComponent {
|
|
6394
|
+
constructor() {
|
|
6395
|
+
super(...arguments);
|
|
6396
|
+
this.id = guid$1();
|
|
6397
|
+
this.queuedDomNodes = [];
|
|
6398
|
+
this.currentDomNodes = [];
|
|
6399
|
+
this.handleEl = (el) => {
|
|
6400
|
+
const { options } = this.context;
|
|
6401
|
+
const { generatorName } = this.props;
|
|
6402
|
+
if (!options.customRenderingReplaces || !hasCustomRenderingHandler(generatorName, options)) {
|
|
6403
|
+
this.updateElRef(el);
|
|
6404
|
+
}
|
|
6405
|
+
};
|
|
6406
|
+
this.updateElRef = (el) => {
|
|
6407
|
+
if (this.props.elRef) {
|
|
6408
|
+
setRef(this.props.elRef, el);
|
|
6409
|
+
}
|
|
6410
|
+
};
|
|
6411
|
+
}
|
|
6412
|
+
render() {
|
|
6413
|
+
const { props, context } = this;
|
|
6414
|
+
const { options } = context;
|
|
6415
|
+
const { customGenerator, defaultGenerator, renderProps } = props;
|
|
6416
|
+
const attrs = buildElAttrs(props, '', this.handleEl);
|
|
6417
|
+
let useDefault = false;
|
|
6418
|
+
let innerContent;
|
|
6419
|
+
let queuedDomNodes = [];
|
|
6420
|
+
let currentGeneratorMeta;
|
|
6421
|
+
if (customGenerator != null) {
|
|
6422
|
+
const customGeneratorRes = typeof customGenerator === 'function' ?
|
|
6423
|
+
customGenerator(renderProps, _) :
|
|
6424
|
+
customGenerator;
|
|
6425
|
+
if (customGeneratorRes === true) {
|
|
6426
|
+
useDefault = true;
|
|
6427
|
+
}
|
|
6428
|
+
else {
|
|
6429
|
+
const isObject = customGeneratorRes && typeof customGeneratorRes === 'object'; // non-null
|
|
6430
|
+
if (isObject && ('html' in customGeneratorRes)) {
|
|
6431
|
+
attrs.dangerouslySetInnerHTML = { __html: customGeneratorRes.html };
|
|
6432
|
+
}
|
|
6433
|
+
else if (isObject && ('domNodes' in customGeneratorRes)) {
|
|
6434
|
+
queuedDomNodes = Array.prototype.slice.call(customGeneratorRes.domNodes);
|
|
6435
|
+
}
|
|
6436
|
+
else if (isObject
|
|
6437
|
+
? t(customGeneratorRes) // vdom node
|
|
6438
|
+
: typeof customGeneratorRes !== 'function' // primitive value (like string or number)
|
|
6439
|
+
) {
|
|
6440
|
+
// use in vdom
|
|
6441
|
+
innerContent = customGeneratorRes;
|
|
6442
|
+
}
|
|
6443
|
+
else {
|
|
6444
|
+
// an exotic object for handleCustomRendering
|
|
6445
|
+
currentGeneratorMeta = customGeneratorRes;
|
|
6446
|
+
}
|
|
6447
|
+
}
|
|
6448
|
+
}
|
|
6449
|
+
else {
|
|
6450
|
+
useDefault = !hasCustomRenderingHandler(props.generatorName, options);
|
|
6451
|
+
}
|
|
6452
|
+
if (useDefault && defaultGenerator) {
|
|
6453
|
+
innerContent = defaultGenerator(renderProps);
|
|
6454
|
+
}
|
|
6455
|
+
this.queuedDomNodes = queuedDomNodes;
|
|
6456
|
+
this.currentGeneratorMeta = currentGeneratorMeta;
|
|
6457
|
+
return _(props.tag, attrs, innerContent);
|
|
6458
|
+
}
|
|
6459
|
+
componentDidMount() {
|
|
6460
|
+
this.applyQueueudDomNodes();
|
|
6461
|
+
this.triggerCustomRendering(true);
|
|
6462
|
+
}
|
|
6463
|
+
componentDidUpdate() {
|
|
6464
|
+
this.applyQueueudDomNodes();
|
|
6465
|
+
this.triggerCustomRendering(true);
|
|
6466
|
+
}
|
|
6467
|
+
componentWillUnmount() {
|
|
6468
|
+
this.triggerCustomRendering(false); // TODO: different API for removal?
|
|
6469
|
+
}
|
|
6470
|
+
triggerCustomRendering(isActive) {
|
|
6471
|
+
var _a;
|
|
6472
|
+
const { props, context } = this;
|
|
6473
|
+
const { handleCustomRendering, customRenderingMetaMap } = context.options;
|
|
6474
|
+
if (handleCustomRendering) {
|
|
6475
|
+
const generatorMeta = (_a = this.currentGeneratorMeta) !== null && _a !== void 0 ? _a : customRenderingMetaMap === null || customRenderingMetaMap === void 0 ? void 0 : customRenderingMetaMap[props.generatorName];
|
|
6476
|
+
if (generatorMeta) {
|
|
6477
|
+
handleCustomRendering(Object.assign({ id: this.id, isActive, containerEl: this.base, reportNewContainerEl: this.updateElRef, // front-end framework tells us about new container els
|
|
6478
|
+
generatorMeta }, props));
|
|
6479
|
+
}
|
|
6480
|
+
}
|
|
6481
|
+
}
|
|
6482
|
+
applyQueueudDomNodes() {
|
|
6483
|
+
const { queuedDomNodes, currentDomNodes } = this;
|
|
6484
|
+
const el = this.base;
|
|
6485
|
+
if (!isArraysEqual(queuedDomNodes, currentDomNodes)) {
|
|
6486
|
+
for (const domNode of currentDomNodes) {
|
|
6487
|
+
domNode.remove();
|
|
6488
|
+
}
|
|
6489
|
+
for (let newNode of queuedDomNodes) {
|
|
6490
|
+
el.appendChild(newNode);
|
|
6491
|
+
}
|
|
6492
|
+
this.currentDomNodes = queuedDomNodes;
|
|
6493
|
+
}
|
|
6494
|
+
}
|
|
6495
|
+
}
|
|
6496
|
+
ContentInjector.addPropsEquality({
|
|
6497
|
+
renderProps: isPropsEqual,
|
|
6498
|
+
attrs: isNonHandlerPropsEqual,
|
|
6499
|
+
style: isPropsEqual,
|
|
6500
|
+
});
|
|
6501
|
+
// Util
|
|
6502
|
+
/*
|
|
6503
|
+
Does UI-framework provide custom way of rendering that does not use Preact VDOM
|
|
6504
|
+
AND does the calendar's options define custom rendering?
|
|
6505
|
+
AKA. Should we NOT render the default content?
|
|
6506
|
+
*/
|
|
6507
|
+
function hasCustomRenderingHandler(generatorName, options) {
|
|
6508
|
+
var _a;
|
|
6509
|
+
return Boolean(options.handleCustomRendering &&
|
|
6510
|
+
generatorName &&
|
|
6511
|
+
((_a = options.customRenderingMetaMap) === null || _a === void 0 ? void 0 : _a[generatorName]));
|
|
6512
|
+
}
|
|
6513
|
+
function buildElAttrs(props, className, elRef) {
|
|
6514
|
+
const attrs = Object.assign(Object.assign({}, props.attrs), { ref: elRef });
|
|
6515
|
+
if (props.className || className) {
|
|
6516
|
+
attrs.className = joinClassNames(className, props.className, attrs.className);
|
|
6517
|
+
}
|
|
6518
|
+
if (props.style) {
|
|
6519
|
+
attrs.style = props.style;
|
|
6520
|
+
}
|
|
6521
|
+
return attrs;
|
|
6522
|
+
}
|
|
6523
|
+
|
|
6524
|
+
const RenderId = createContext(0);
|
|
6525
|
+
|
|
6526
|
+
class ContentContainer extends b {
|
|
6527
|
+
constructor() {
|
|
6528
|
+
super(...arguments);
|
|
6529
|
+
this.InnerContent = InnerContentInjector.bind(undefined, this);
|
|
6530
|
+
this.handleEl = (el) => {
|
|
6531
|
+
this.el = el;
|
|
6532
|
+
if (this.props.elRef) {
|
|
6533
|
+
setRef(this.props.elRef, el);
|
|
6534
|
+
if (el && this.didMountMisfire) {
|
|
6535
|
+
this.componentDidMount();
|
|
6536
|
+
}
|
|
6537
|
+
}
|
|
6538
|
+
};
|
|
6539
|
+
}
|
|
6540
|
+
render() {
|
|
6541
|
+
const { props } = this;
|
|
6542
|
+
const generatedClassName = generateClassName(props.classNameGenerator, props.renderProps);
|
|
6543
|
+
if (props.children) {
|
|
6544
|
+
const attrs = buildElAttrs(props, generatedClassName, this.handleEl);
|
|
6545
|
+
const children = props.children(this.InnerContent, props.renderProps, attrs);
|
|
6546
|
+
if (props.tag) {
|
|
6547
|
+
return _(props.tag, attrs, children);
|
|
6548
|
+
}
|
|
6549
|
+
else {
|
|
6550
|
+
return children;
|
|
6551
|
+
}
|
|
6552
|
+
}
|
|
6553
|
+
else {
|
|
6554
|
+
return _((ContentInjector), Object.assign(Object.assign({}, props), { elRef: this.handleEl, tag: props.tag || 'div', className: joinClassNames(props.className, generatedClassName), renderId: this.context }));
|
|
6555
|
+
}
|
|
6556
|
+
}
|
|
6557
|
+
componentDidMount() {
|
|
6558
|
+
var _a, _b;
|
|
6559
|
+
if (this.el) {
|
|
6560
|
+
(_b = (_a = this.props).didMount) === null || _b === void 0 ? void 0 : _b.call(_a, Object.assign(Object.assign({}, this.props.renderProps), { el: this.el }));
|
|
6561
|
+
}
|
|
6562
|
+
else {
|
|
6563
|
+
this.didMountMisfire = true;
|
|
6564
|
+
}
|
|
6565
|
+
}
|
|
6566
|
+
componentWillUnmount() {
|
|
6567
|
+
var _a, _b;
|
|
6568
|
+
(_b = (_a = this.props).willUnmount) === null || _b === void 0 ? void 0 : _b.call(_a, Object.assign(Object.assign({}, this.props.renderProps), { el: this.el }));
|
|
6569
|
+
}
|
|
6570
|
+
}
|
|
6571
|
+
ContentContainer.contextType = RenderId;
|
|
6572
|
+
function InnerContentInjector(containerComponent, props) {
|
|
6573
|
+
const parentProps = containerComponent.props;
|
|
6574
|
+
return _((ContentInjector), Object.assign({ renderProps: parentProps.renderProps, generatorName: parentProps.generatorName, customGenerator: parentProps.customGenerator, defaultGenerator: parentProps.defaultGenerator, renderId: containerComponent.context }, props));
|
|
6575
|
+
}
|
|
6576
|
+
// Utils
|
|
6577
|
+
function generateClassName(classNameGenerator, renderProps) {
|
|
6578
|
+
const classNames = typeof classNameGenerator === 'function' ?
|
|
6579
|
+
classNameGenerator(renderProps) :
|
|
6580
|
+
classNameGenerator || [];
|
|
6581
|
+
return typeof classNames === 'string' ? classNames : classNames.join(' ');
|
|
6582
|
+
}
|
|
6583
|
+
function renderText(renderProps) {
|
|
6584
|
+
return renderProps.text;
|
|
6585
|
+
}
|
|
6586
|
+
|
|
6733
6587
|
class EventContainer extends BaseComponent {
|
|
6734
6588
|
constructor() {
|
|
6735
6589
|
super(...arguments);
|
|
@@ -6765,11 +6619,7 @@ var FullCalendar = (function (exports) {
|
|
|
6765
6619
|
isDragging: Boolean(props.isDragging),
|
|
6766
6620
|
isResizing: Boolean(props.isResizing),
|
|
6767
6621
|
};
|
|
6768
|
-
return (_(ContentContainer, Object.assign({}, props /* contains children */, { elRef: this.handleEl,
|
|
6769
|
-
...getEventClassNames(renderProps),
|
|
6770
|
-
...eventRange.ui.classNames,
|
|
6771
|
-
...(props.elClasses || []),
|
|
6772
|
-
], renderProps: renderProps, generatorName: "eventContent", customGenerator: options.eventContent, defaultGenerator: props.defaultGenerator, classNameGenerator: options.eventClassNames, didMount: options.eventDidMount, willUnmount: options.eventWillUnmount })));
|
|
6622
|
+
return (_(ContentContainer, Object.assign({}, props /* contains children */, { elRef: this.handleEl, className: joinClassNames(props.className, ...getEventClassNames(renderProps), ...eventRange.ui.classNames), renderProps: renderProps, generatorName: "eventContent", customGenerator: options.eventContent, defaultGenerator: props.defaultGenerator, classNameGenerator: options.eventClassNames, didMount: options.eventDidMount, willUnmount: options.eventWillUnmount })));
|
|
6773
6623
|
}
|
|
6774
6624
|
componentDidUpdate(prevProps) {
|
|
6775
6625
|
if (this.el && this.props.eventRange !== prevProps.eventRange) {
|
|
@@ -6781,43 +6631,76 @@ var FullCalendar = (function (exports) {
|
|
|
6781
6631
|
// should not be a purecomponent
|
|
6782
6632
|
class StandardEvent extends BaseComponent {
|
|
6783
6633
|
render() {
|
|
6784
|
-
|
|
6785
|
-
|
|
6786
|
-
|
|
6787
|
-
|
|
6788
|
-
|
|
6789
|
-
|
|
6790
|
-
|
|
6791
|
-
|
|
6792
|
-
|
|
6793
|
-
|
|
6794
|
-
|
|
6634
|
+
const { props, context } = this;
|
|
6635
|
+
const { eventRange } = props;
|
|
6636
|
+
const { options } = context;
|
|
6637
|
+
const timeFormat = options.eventTimeFormat || props.defaultTimeFormat;
|
|
6638
|
+
const timeText = buildEventRangeTimeText(timeFormat, eventRange, // just for def/instance
|
|
6639
|
+
props.slicedStart, props.slicedEnd, props.isStart, props.isEnd, context, props.defaultDisplayEventTime, props.defaultDisplayEventEnd);
|
|
6640
|
+
const [tag, attrs] = getEventTagAndAttrs(eventRange, context);
|
|
6641
|
+
return (_(EventContainer, Object.assign({}, props /* includes elRef */, { tag: tag, style: {
|
|
6642
|
+
borderColor: eventRange.ui.borderColor,
|
|
6643
|
+
backgroundColor: eventRange.ui.backgroundColor,
|
|
6644
|
+
}, attrs: attrs, defaultGenerator: renderInnerContent$1, timeText: timeText }), (InnerContent, eventContentArg) => (_(k$1, null,
|
|
6645
|
+
_(InnerContent, { tag: "div", className: 'fc-event-inner', style: { color: eventContentArg.textColor } }),
|
|
6795
6646
|
Boolean(eventContentArg.isStartResizable) && (_("div", { className: "fc-event-resizer fc-event-resizer-start" })),
|
|
6796
6647
|
Boolean(eventContentArg.isEndResizable) && (_("div", { className: "fc-event-resizer fc-event-resizer-end" }))))));
|
|
6797
6648
|
}
|
|
6798
6649
|
}
|
|
6799
|
-
function renderInnerContent$1(innerProps) {
|
|
6800
|
-
return (_(k$1, null,
|
|
6801
|
-
innerProps.timeText && (_("div", { className: "fc-event-time" }, innerProps.timeText)),
|
|
6802
|
-
_("div", { className: "fc-event-title-outer" },
|
|
6803
|
-
_("div", { className: "fc-event-title" }, innerProps.event.title || _(k$1, null, "\u00A0")))));
|
|
6650
|
+
function renderInnerContent$1(innerProps) {
|
|
6651
|
+
return (_(k$1, null,
|
|
6652
|
+
innerProps.timeText && (_("div", { className: "fc-event-time" }, innerProps.timeText)),
|
|
6653
|
+
_("div", { className: "fc-event-title-outer" },
|
|
6654
|
+
_("div", { className: "fc-event-title" }, innerProps.event.title || _(k$1, null, "\u00A0")))));
|
|
6655
|
+
}
|
|
6656
|
+
|
|
6657
|
+
const NowIndicatorContainer = (props) => (_(ViewContextType.Consumer, null, (context) => {
|
|
6658
|
+
let { options } = context;
|
|
6659
|
+
let renderProps = {
|
|
6660
|
+
isAxis: props.isAxis,
|
|
6661
|
+
date: context.dateEnv.toDate(props.date),
|
|
6662
|
+
view: context.viewApi,
|
|
6663
|
+
};
|
|
6664
|
+
return (_(ContentContainer, Object.assign({}, props /* includes children */, { tag: props.tag || 'div', renderProps: renderProps, generatorName: "nowIndicatorContent", customGenerator: options.nowIndicatorContent, classNameGenerator: options.nowIndicatorClassNames, didMount: options.nowIndicatorDidMount, willUnmount: options.nowIndicatorWillUnmount })));
|
|
6665
|
+
}));
|
|
6666
|
+
|
|
6667
|
+
const DAY_NUM_FORMAT = createFormatter({ day: 'numeric' });
|
|
6668
|
+
class DayCellContainer extends BaseComponent {
|
|
6669
|
+
constructor() {
|
|
6670
|
+
super(...arguments);
|
|
6671
|
+
this.refineRenderProps = memoizeObjArg(refineRenderProps);
|
|
6672
|
+
}
|
|
6673
|
+
render() {
|
|
6674
|
+
let { props, context } = this;
|
|
6675
|
+
let { options } = context;
|
|
6676
|
+
let renderProps = this.refineRenderProps({
|
|
6677
|
+
date: props.date,
|
|
6678
|
+
dateMeta: props.dateMeta,
|
|
6679
|
+
isMonthStart: props.isMonthStart || false,
|
|
6680
|
+
showDayNumber: props.showDayNumber,
|
|
6681
|
+
renderProps: props.renderProps,
|
|
6682
|
+
viewApi: context.viewApi,
|
|
6683
|
+
dateEnv: context.dateEnv,
|
|
6684
|
+
monthStartFormat: options.monthStartFormat,
|
|
6685
|
+
});
|
|
6686
|
+
return (_(ContentContainer, Object.assign({}, props /* includes children */, { className: joinClassNames(props.className, getDayClassName(renderProps)), attrs: Object.assign(Object.assign(Object.assign({}, props.attrs), { 'data-date': formatDayString(props.date) }), (renderProps.isToday ? { 'aria-current': 'date' } : {})), renderProps: renderProps, generatorName: "dayCellContent", customGenerator: options.dayCellContent, defaultGenerator: props.defaultGenerator, classNameGenerator: options.dayCellClassNames, didMount: options.dayCellDidMount, willUnmount: options.dayCellWillUnmount })));
|
|
6687
|
+
}
|
|
6688
|
+
}
|
|
6689
|
+
function hasCustomDayCellContent(options) {
|
|
6690
|
+
return Boolean(options.dayCellContent || hasCustomRenderingHandler('dayCellContent', options));
|
|
6691
|
+
}
|
|
6692
|
+
function refineRenderProps(raw) {
|
|
6693
|
+
let { date, dateEnv, isMonthStart } = raw;
|
|
6694
|
+
let dayNumberText = raw.showDayNumber ? (dateEnv.format(date, isMonthStart ? raw.monthStartFormat : DAY_NUM_FORMAT)) : '';
|
|
6695
|
+
return Object.assign(Object.assign(Object.assign({ date: dateEnv.toDate(date), view: raw.viewApi }, raw.dateMeta), { isMonthStart,
|
|
6696
|
+
dayNumberText }), raw.renderProps);
|
|
6804
6697
|
}
|
|
6805
6698
|
|
|
6806
|
-
const NowIndicatorContainer = (props) => (_(ViewContextType.Consumer, null, (context) => {
|
|
6807
|
-
let { options } = context;
|
|
6808
|
-
let renderProps = {
|
|
6809
|
-
isAxis: props.isAxis,
|
|
6810
|
-
date: context.dateEnv.toDate(props.date),
|
|
6811
|
-
view: context.viewApi,
|
|
6812
|
-
};
|
|
6813
|
-
return (_(ContentContainer, Object.assign({}, props /* includes children */, { elTag: props.elTag || 'div', renderProps: renderProps, generatorName: "nowIndicatorContent", customGenerator: options.nowIndicatorContent, classNameGenerator: options.nowIndicatorClassNames, didMount: options.nowIndicatorDidMount, willUnmount: options.nowIndicatorWillUnmount })));
|
|
6814
|
-
}));
|
|
6815
|
-
|
|
6816
6699
|
class BgEvent extends BaseComponent {
|
|
6817
6700
|
render() {
|
|
6818
6701
|
let { props } = this;
|
|
6819
6702
|
let { eventRange } = props;
|
|
6820
|
-
return (_(EventContainer, {
|
|
6703
|
+
return (_(EventContainer, { tag: "div", className: 'fc-bg-event', style: { backgroundColor: eventRange.ui.backgroundColor }, defaultGenerator: renderInnerContent, eventRange: eventRange, isStart: props.isStart, isEnd: props.isEnd, timeText: "", isDragging: false, isResizing: false, isDateSelecting: false, isSelected: false, isPast: props.isPast, isFuture: props.isFuture, isToday: props.isToday, disableDragging: true, disableResizing: true }));
|
|
6821
6704
|
}
|
|
6822
6705
|
}
|
|
6823
6706
|
function renderInnerContent(props) {
|
|
@@ -6836,10 +6719,248 @@ var FullCalendar = (function (exports) {
|
|
|
6836
6719
|
let text = dateEnv.format(date, format);
|
|
6837
6720
|
let renderProps = { num, text, date };
|
|
6838
6721
|
return (_(ContentContainer // why isn't WeekNumberContentArg being auto-detected?
|
|
6839
|
-
, Object.assign({}, props /* includes children */, { renderProps: renderProps, generatorName: "weekNumberContent", customGenerator: options.weekNumberContent, defaultGenerator:
|
|
6722
|
+
, Object.assign({}, props /* includes children */, { renderProps: renderProps, generatorName: "weekNumberContent", customGenerator: options.weekNumberContent, defaultGenerator: renderText, classNameGenerator: options.weekNumberClassNames, didMount: options.weekNumberDidMount, willUnmount: options.weekNumberWillUnmount })));
|
|
6840
6723
|
}));
|
|
6841
|
-
|
|
6842
|
-
|
|
6724
|
+
|
|
6725
|
+
const PADDING_FROM_VIEWPORT = 10;
|
|
6726
|
+
class Popover extends BaseComponent {
|
|
6727
|
+
constructor() {
|
|
6728
|
+
super(...arguments);
|
|
6729
|
+
this.closeRef = m$1();
|
|
6730
|
+
this.focusStartRef = m$1();
|
|
6731
|
+
this.focusEndRef = m$1();
|
|
6732
|
+
this.titleId = getUniqueDomId();
|
|
6733
|
+
this.handleRootEl = (el) => {
|
|
6734
|
+
this.rootEl = el;
|
|
6735
|
+
if (this.props.elRef) {
|
|
6736
|
+
setRef(this.props.elRef, el);
|
|
6737
|
+
}
|
|
6738
|
+
};
|
|
6739
|
+
// Triggered when the user clicks *anywhere* in the document, for the autoHide feature
|
|
6740
|
+
this.handleDocumentMouseDown = (ev) => {
|
|
6741
|
+
// only hide the popover if the click happened outside the popover
|
|
6742
|
+
const target = getEventTargetViaRoot(ev);
|
|
6743
|
+
if (!this.rootEl.contains(target)) {
|
|
6744
|
+
this.handleClose();
|
|
6745
|
+
}
|
|
6746
|
+
};
|
|
6747
|
+
this.handleDocumentKeyDown = (ev) => {
|
|
6748
|
+
if (ev.key === 'Escape') {
|
|
6749
|
+
this.handleClose();
|
|
6750
|
+
}
|
|
6751
|
+
};
|
|
6752
|
+
// for many different close techniques
|
|
6753
|
+
// cannot accept params because might receive a browser Event
|
|
6754
|
+
this.handleClose = () => {
|
|
6755
|
+
let { onClose } = this.props;
|
|
6756
|
+
if (onClose) {
|
|
6757
|
+
onClose();
|
|
6758
|
+
}
|
|
6759
|
+
};
|
|
6760
|
+
}
|
|
6761
|
+
render() {
|
|
6762
|
+
let { theme, options } = this.context;
|
|
6763
|
+
let { props } = this;
|
|
6764
|
+
return j(_("div", Object.assign({}, props.attrs, { id: props.id, role: 'dialog', "aria-labelledby": this.titleId, className: joinClassNames(props.className, 'fc-popover', theme.getClassName('popover')), ref: this.handleRootEl }),
|
|
6765
|
+
_("div", { tabIndex: 0, style: { outline: 'none' }, ref: this.focusStartRef }),
|
|
6766
|
+
_("div", { className: 'fc-popover-header ' + theme.getClassName('popoverHeader') },
|
|
6767
|
+
_("span", { className: "fc-popover-title", id: this.titleId }, props.title),
|
|
6768
|
+
_("span", Object.assign({ role: 'button', "aria-label": options.closeHint, className: 'fc-popover-close ' + theme.getIconClass('close') }, createAriaClickAttrs(this.handleClose), { ref: this.closeRef }))),
|
|
6769
|
+
_("div", { className: 'fc-popover-body ' + theme.getClassName('popoverContent') }, props.children),
|
|
6770
|
+
_("div", { tabIndex: 0, style: { outline: 'none' }, ref: this.focusEndRef })), props.parentEl);
|
|
6771
|
+
}
|
|
6772
|
+
componentDidMount() {
|
|
6773
|
+
document.addEventListener('mousedown', this.handleDocumentMouseDown);
|
|
6774
|
+
document.addEventListener('keydown', this.handleDocumentKeyDown);
|
|
6775
|
+
this.focusStartRef.current.addEventListener('focus', this.handleClose);
|
|
6776
|
+
this.focusEndRef.current.addEventListener('focus', this.handleClose);
|
|
6777
|
+
this.closeRef.current.focus({ preventScroll: true });
|
|
6778
|
+
this.updateSize();
|
|
6779
|
+
}
|
|
6780
|
+
componentWillUnmount() {
|
|
6781
|
+
document.removeEventListener('mousedown', this.handleDocumentMouseDown);
|
|
6782
|
+
document.removeEventListener('keydown', this.handleDocumentKeyDown);
|
|
6783
|
+
this.focusStartRef.current.removeEventListener('focus', this.handleClose);
|
|
6784
|
+
this.focusEndRef.current.removeEventListener('focus', this.handleClose);
|
|
6785
|
+
}
|
|
6786
|
+
updateSize() {
|
|
6787
|
+
let { isRtl } = this.context;
|
|
6788
|
+
let { alignEl, alignParentTop } = this.props;
|
|
6789
|
+
let { rootEl } = this;
|
|
6790
|
+
let alignmentRect = computeClippedClientRect(alignEl);
|
|
6791
|
+
if (alignmentRect) {
|
|
6792
|
+
let popoverDims = rootEl.getBoundingClientRect();
|
|
6793
|
+
// position relative to viewport
|
|
6794
|
+
let popoverTop = alignParentTop
|
|
6795
|
+
? alignEl.closest(alignParentTop).getBoundingClientRect().top
|
|
6796
|
+
: alignmentRect.top;
|
|
6797
|
+
let popoverLeft = isRtl ? alignmentRect.right - popoverDims.width : alignmentRect.left;
|
|
6798
|
+
// constrain
|
|
6799
|
+
popoverTop = Math.max(popoverTop, PADDING_FROM_VIEWPORT);
|
|
6800
|
+
popoverLeft = Math.min(popoverLeft, document.documentElement.clientWidth - PADDING_FROM_VIEWPORT - popoverDims.width);
|
|
6801
|
+
popoverLeft = Math.max(popoverLeft, PADDING_FROM_VIEWPORT);
|
|
6802
|
+
let origin = rootEl.offsetParent.getBoundingClientRect();
|
|
6803
|
+
applyStyle(rootEl, {
|
|
6804
|
+
top: popoverTop - origin.top,
|
|
6805
|
+
left: popoverLeft - origin.left,
|
|
6806
|
+
});
|
|
6807
|
+
}
|
|
6808
|
+
}
|
|
6809
|
+
}
|
|
6810
|
+
|
|
6811
|
+
class MorePopover extends DateComponent {
|
|
6812
|
+
constructor() {
|
|
6813
|
+
super(...arguments);
|
|
6814
|
+
this.handleRootEl = (rootEl) => {
|
|
6815
|
+
this.rootEl = rootEl;
|
|
6816
|
+
if (rootEl) {
|
|
6817
|
+
this.context.registerInteractiveComponent(this, {
|
|
6818
|
+
el: rootEl,
|
|
6819
|
+
useEventCenter: false,
|
|
6820
|
+
});
|
|
6821
|
+
}
|
|
6822
|
+
else {
|
|
6823
|
+
this.context.unregisterInteractiveComponent(this);
|
|
6824
|
+
}
|
|
6825
|
+
};
|
|
6826
|
+
}
|
|
6827
|
+
render() {
|
|
6828
|
+
let { options, dateEnv } = this.context;
|
|
6829
|
+
let { props } = this;
|
|
6830
|
+
let { startDate, todayRange, dateProfile } = props;
|
|
6831
|
+
// TODO: memoize?
|
|
6832
|
+
let detaMeta = getDateMeta(startDate, todayRange, null, dateProfile);
|
|
6833
|
+
let title = dateEnv.format(startDate, options.dayPopoverFormat);
|
|
6834
|
+
return (_(DayCellContainer, { elRef: this.handleRootEl, date: startDate, dateMeta: detaMeta }, (InnerContent, renderProps, attrs) => (_(Popover, { elRef: attrs.ref, id: props.id, title: title, attrs: attrs /* TODO: make these time-based when not whole-day? */, className: joinClassNames(attrs.className, // TODO: solve SignalLike type problem
|
|
6835
|
+
'fc-more-popover'), parentEl: props.parentEl, alignEl: props.alignEl, alignParentTop: props.alignParentTop, onClose: props.onClose },
|
|
6836
|
+
hasCustomDayCellContent(options) && (_(InnerContent, { tag: "div", className: 'fc-more-popover-misc' })),
|
|
6837
|
+
props.children))));
|
|
6838
|
+
}
|
|
6839
|
+
queryHit(positionLeft, positionTop, elWidth, elHeight) {
|
|
6840
|
+
let { rootEl, props } = this;
|
|
6841
|
+
if (positionLeft >= 0 && positionLeft < elWidth &&
|
|
6842
|
+
positionTop >= 0 && positionTop < elHeight) {
|
|
6843
|
+
return {
|
|
6844
|
+
dateProfile: props.dateProfile,
|
|
6845
|
+
dateSpan: Object.assign({ allDay: !props.forceTimed, range: {
|
|
6846
|
+
start: props.startDate,
|
|
6847
|
+
end: props.endDate,
|
|
6848
|
+
} }, props.dateSpanProps),
|
|
6849
|
+
dayEl: rootEl,
|
|
6850
|
+
rect: {
|
|
6851
|
+
left: 0,
|
|
6852
|
+
top: 0,
|
|
6853
|
+
right: elWidth,
|
|
6854
|
+
bottom: elHeight,
|
|
6855
|
+
},
|
|
6856
|
+
layer: 1, // important when comparing with hits from other components
|
|
6857
|
+
};
|
|
6858
|
+
}
|
|
6859
|
+
return null;
|
|
6860
|
+
}
|
|
6861
|
+
}
|
|
6862
|
+
|
|
6863
|
+
class MoreLinkContainer extends BaseComponent {
|
|
6864
|
+
constructor() {
|
|
6865
|
+
super(...arguments);
|
|
6866
|
+
this.state = {
|
|
6867
|
+
isPopoverOpen: false,
|
|
6868
|
+
popoverId: getUniqueDomId(),
|
|
6869
|
+
};
|
|
6870
|
+
this.handleLinkEl = (linkEl) => {
|
|
6871
|
+
this.linkEl = linkEl;
|
|
6872
|
+
if (this.props.elRef) {
|
|
6873
|
+
setRef(this.props.elRef, linkEl);
|
|
6874
|
+
}
|
|
6875
|
+
};
|
|
6876
|
+
this.handleClick = (ev) => {
|
|
6877
|
+
let { props, context } = this;
|
|
6878
|
+
let { moreLinkClick } = context.options;
|
|
6879
|
+
let date = computeRange(props).start;
|
|
6880
|
+
function buildPublicSeg(seg) {
|
|
6881
|
+
let { def, instance, range } = seg.eventRange;
|
|
6882
|
+
return {
|
|
6883
|
+
event: new EventImpl(context, def, instance),
|
|
6884
|
+
start: context.dateEnv.toDate(range.start),
|
|
6885
|
+
end: context.dateEnv.toDate(range.end),
|
|
6886
|
+
isStart: seg.isStart,
|
|
6887
|
+
isEnd: seg.isEnd,
|
|
6888
|
+
};
|
|
6889
|
+
}
|
|
6890
|
+
if (typeof moreLinkClick === 'function') {
|
|
6891
|
+
moreLinkClick = moreLinkClick({
|
|
6892
|
+
date,
|
|
6893
|
+
allDay: Boolean(props.allDayDate),
|
|
6894
|
+
allSegs: props.segs.map(buildPublicSeg),
|
|
6895
|
+
hiddenSegs: props.hiddenSegs.map(buildPublicSeg),
|
|
6896
|
+
jsEvent: ev,
|
|
6897
|
+
view: context.viewApi,
|
|
6898
|
+
});
|
|
6899
|
+
}
|
|
6900
|
+
if (!moreLinkClick || moreLinkClick === 'popover') {
|
|
6901
|
+
this.setState({ isPopoverOpen: true });
|
|
6902
|
+
}
|
|
6903
|
+
else if (typeof moreLinkClick === 'string') { // a view name
|
|
6904
|
+
context.calendarApi.zoomTo(date, moreLinkClick);
|
|
6905
|
+
}
|
|
6906
|
+
};
|
|
6907
|
+
this.handlePopoverClose = () => {
|
|
6908
|
+
if (this.linkEl) { // was null sometimes when initiating drag-n-drop would hide the popover
|
|
6909
|
+
this.linkEl.focus();
|
|
6910
|
+
}
|
|
6911
|
+
this.setState({ isPopoverOpen: false });
|
|
6912
|
+
};
|
|
6913
|
+
}
|
|
6914
|
+
render() {
|
|
6915
|
+
let { props, state } = this;
|
|
6916
|
+
return (_(ViewContextType.Consumer, null, (context) => {
|
|
6917
|
+
let { viewApi, options, calendarApi } = context;
|
|
6918
|
+
let { moreLinkText } = options;
|
|
6919
|
+
let moreCnt = props.hiddenSegs.length;
|
|
6920
|
+
let range = computeRange(props);
|
|
6921
|
+
let text = typeof moreLinkText === 'function' // TODO: eventually use formatWithOrdinals
|
|
6922
|
+
? moreLinkText.call(calendarApi, moreCnt)
|
|
6923
|
+
: `+${moreCnt} ${moreLinkText}`;
|
|
6924
|
+
let hint = formatWithOrdinals(options.moreLinkHint, [moreCnt], text);
|
|
6925
|
+
let renderProps = {
|
|
6926
|
+
num: moreCnt,
|
|
6927
|
+
shortText: `+${moreCnt}`,
|
|
6928
|
+
text,
|
|
6929
|
+
view: viewApi,
|
|
6930
|
+
};
|
|
6931
|
+
return (_(k$1, null,
|
|
6932
|
+
Boolean(moreCnt) && (_(ContentContainer, { tag: 'div', elRef: this.handleLinkEl, className: joinClassNames(props.className, 'fc-more-link'), style: props.style, attrs: Object.assign(Object.assign(Object.assign({}, props.attrs), createAriaClickAttrs(this.handleClick)), { title: hint, 'role': 'button', 'aria-haspopup': 'dialog', 'aria-expanded': state.isPopoverOpen, 'aria-controls': state.isPopoverOpen ? state.popoverId : undefined }), renderProps: renderProps, generatorName: "moreLinkContent", customGenerator: options.moreLinkContent, defaultGenerator: props.defaultGenerator || renderMoreLinkInner, classNameGenerator: options.moreLinkClassNames, didMount: options.moreLinkDidMount, willUnmount: options.moreLinkWillUnmount }, props.children)),
|
|
6933
|
+
state.isPopoverOpen && (_(MorePopover, { id: state.popoverId, startDate: range.start, endDate: range.end, dateProfile: props.dateProfile, todayRange: props.todayRange, dateSpanProps: props.dateSpanProps, parentEl: this.parentEl, alignEl: props.alignElRef ?
|
|
6934
|
+
props.alignElRef.current :
|
|
6935
|
+
this.linkEl, alignParentTop: props.alignParentTop, forceTimed: props.forceTimed, onClose: this.handlePopoverClose }, props.popoverContent()))));
|
|
6936
|
+
}));
|
|
6937
|
+
}
|
|
6938
|
+
componentDidMount() {
|
|
6939
|
+
this.updateParentEl();
|
|
6940
|
+
}
|
|
6941
|
+
componentDidUpdate() {
|
|
6942
|
+
this.updateParentEl();
|
|
6943
|
+
}
|
|
6944
|
+
updateParentEl() {
|
|
6945
|
+
if (this.linkEl) {
|
|
6946
|
+
this.parentEl = this.linkEl.closest('.fc-view-outer'); // HACK. reconsider
|
|
6947
|
+
}
|
|
6948
|
+
}
|
|
6949
|
+
}
|
|
6950
|
+
function renderMoreLinkInner(props) {
|
|
6951
|
+
return props.text;
|
|
6952
|
+
}
|
|
6953
|
+
function computeRange(props) {
|
|
6954
|
+
if (props.allDayDate) {
|
|
6955
|
+
return {
|
|
6956
|
+
start: props.allDayDate,
|
|
6957
|
+
end: addDays(props.allDayDate, 1),
|
|
6958
|
+
};
|
|
6959
|
+
}
|
|
6960
|
+
return {
|
|
6961
|
+
start: computeEarliestStart(props.hiddenSegs),
|
|
6962
|
+
end: computeLatestEnd(props.hiddenSegs),
|
|
6963
|
+
};
|
|
6843
6964
|
}
|
|
6844
6965
|
|
|
6845
6966
|
class ViewContainer extends BaseComponent {
|
|
@@ -6847,17 +6968,11 @@ var FullCalendar = (function (exports) {
|
|
|
6847
6968
|
let { props, context } = this;
|
|
6848
6969
|
let { options } = context;
|
|
6849
6970
|
let renderProps = { view: context.viewApi };
|
|
6850
|
-
return (_(ContentContainer, Object.assign({}, props, {
|
|
6851
|
-
...buildViewClassNames(props.viewSpec),
|
|
6852
|
-
...(props.elClasses || []),
|
|
6853
|
-
], renderProps: renderProps, classNameGenerator: options.viewClassNames, generatorName: undefined, didMount: options.viewDidMount, willUnmount: options.viewWillUnmount }), () => props.children));
|
|
6971
|
+
return (_(ContentContainer, Object.assign({}, props, { tag: props.tag || 'div', attrs: props.attrs, className: joinClassNames(props.className, buildViewClassName(props.viewSpec)), renderProps: renderProps, classNameGenerator: options.viewClassNames, generatorName: undefined, didMount: options.viewDidMount, willUnmount: options.viewWillUnmount }), () => props.children));
|
|
6854
6972
|
}
|
|
6855
6973
|
}
|
|
6856
|
-
function
|
|
6857
|
-
return
|
|
6858
|
-
`fc-${viewSpec.type}-view`,
|
|
6859
|
-
'fc-view',
|
|
6860
|
-
];
|
|
6974
|
+
function buildViewClassName(viewSpec) {
|
|
6975
|
+
return `fc-${viewSpec.type}-view fc-view`;
|
|
6861
6976
|
}
|
|
6862
6977
|
|
|
6863
6978
|
const EVENT_SOURCE_REFINERS = {
|
|
@@ -6896,7 +7011,7 @@ var FullCalendar = (function (exports) {
|
|
|
6896
7011
|
success: refined.success,
|
|
6897
7012
|
failure: refined.failure,
|
|
6898
7013
|
publicId: refined.id || '',
|
|
6899
|
-
sourceId: guid(),
|
|
7014
|
+
sourceId: guid$1(),
|
|
6900
7015
|
sourceDefId: metaRes.sourceDefId,
|
|
6901
7016
|
meta: metaRes.meta,
|
|
6902
7017
|
ui: createEventUi(refined, context),
|
|
@@ -6936,7 +7051,7 @@ var FullCalendar = (function (exports) {
|
|
|
6936
7051
|
callback();
|
|
6937
7052
|
}
|
|
6938
7053
|
updateSize() {
|
|
6939
|
-
|
|
7054
|
+
requestAnimationFrame(updateSizeSync);
|
|
6940
7055
|
}
|
|
6941
7056
|
// Options
|
|
6942
7057
|
// -----------------------------------------------------------------------------------------------------------------
|
|
@@ -7344,6 +7459,32 @@ var FullCalendar = (function (exports) {
|
|
|
7344
7459
|
}
|
|
7345
7460
|
}
|
|
7346
7461
|
|
|
7462
|
+
class StickyFooterScrollbar extends BaseComponent {
|
|
7463
|
+
constructor() {
|
|
7464
|
+
super(...arguments);
|
|
7465
|
+
this.rootElRef = m$1();
|
|
7466
|
+
}
|
|
7467
|
+
render() {
|
|
7468
|
+
const { props } = this;
|
|
7469
|
+
// NOTE: we need a wrapper around the Scroller because if scrollbars appear/hide,
|
|
7470
|
+
// the outer dimensions change, but the inner dimensions do not. The Scroller's
|
|
7471
|
+
// dimension-watching, when used in ponyfill-mode, can't fire on border-box change, so we
|
|
7472
|
+
// workaround it by monitoring dimensions of a wrapper instead
|
|
7473
|
+
return (_("div", { ref: this.rootElRef, className: 'fc-sticky-footer-scrollbar' },
|
|
7474
|
+
_(Scroller, { horizontal: true, ref: props.scrollerRef },
|
|
7475
|
+
_("div", { style: { minWidth: props.canvasWidth } }))));
|
|
7476
|
+
}
|
|
7477
|
+
componentDidMount() {
|
|
7478
|
+
this.disconnectHeight = watchHeight(this.rootElRef.current, (height) => {
|
|
7479
|
+
setRef(this.props.scrollbarWidthRef, height);
|
|
7480
|
+
});
|
|
7481
|
+
}
|
|
7482
|
+
componentWillUnmount() {
|
|
7483
|
+
this.disconnectHeight();
|
|
7484
|
+
setRef(this.props.scrollbarWidthRef, null);
|
|
7485
|
+
}
|
|
7486
|
+
}
|
|
7487
|
+
|
|
7347
7488
|
var internal = {
|
|
7348
7489
|
__proto__: null,
|
|
7349
7490
|
BASE_OPTION_DEFAULTS: BASE_OPTION_DEFAULTS,
|
|
@@ -7365,9 +7506,8 @@ var FullCalendar = (function (exports) {
|
|
|
7365
7506
|
compareNumbers: compareNumbers,
|
|
7366
7507
|
enableCursor: enableCursor,
|
|
7367
7508
|
disableCursor: disableCursor,
|
|
7368
|
-
guid: guid,
|
|
7509
|
+
guid: guid$1,
|
|
7369
7510
|
computeVisibleDayRange: computeVisibleDayRange,
|
|
7370
|
-
isMultiDayRange: isMultiDayRange,
|
|
7371
7511
|
diffDates: diffDates,
|
|
7372
7512
|
removeExact: removeExact,
|
|
7373
7513
|
isArraysEqual: isArraysEqual,
|
|
@@ -7386,14 +7526,10 @@ var FullCalendar = (function (exports) {
|
|
|
7386
7526
|
isPropsEqual: isPropsEqual,
|
|
7387
7527
|
compareObjs: compareObjs,
|
|
7388
7528
|
collectFromHash: collectFromHash,
|
|
7389
|
-
findElements: findElements,
|
|
7390
|
-
findDirectChildren: findDirectChildren,
|
|
7391
|
-
removeElement: removeElement,
|
|
7392
7529
|
applyStyle: applyStyle,
|
|
7393
|
-
elementMatches: elementMatches,
|
|
7394
|
-
elementClosest: elementClosest,
|
|
7395
7530
|
getEventTargetViaRoot: getEventTargetViaRoot,
|
|
7396
7531
|
getUniqueDomId: getUniqueDomId,
|
|
7532
|
+
joinClassNames: joinClassNames,
|
|
7397
7533
|
parseClassNames: parseClassNames,
|
|
7398
7534
|
fracToCssDim: fracToCssDim,
|
|
7399
7535
|
createEmptyEventStore: createEmptyEventStore,
|
|
@@ -7403,17 +7539,16 @@ var FullCalendar = (function (exports) {
|
|
|
7403
7539
|
combineEventUis: combineEventUis,
|
|
7404
7540
|
createEventUi: createEventUi,
|
|
7405
7541
|
Splitter: Splitter,
|
|
7406
|
-
|
|
7542
|
+
getDayClassName: getDayClassName,
|
|
7407
7543
|
getDateMeta: getDateMeta,
|
|
7408
|
-
|
|
7409
|
-
setStateDimMap: setStateDimMap,
|
|
7410
|
-
isDimMapsEqual: isDimMapsEqual,
|
|
7544
|
+
getSlotClassName: getSlotClassName,
|
|
7411
7545
|
isDimsEqual: isDimsEqual,
|
|
7412
7546
|
watchSize: watchSize,
|
|
7413
7547
|
watchWidth: watchWidth,
|
|
7414
7548
|
watchHeight: watchHeight,
|
|
7415
7549
|
afterSize: afterSize,
|
|
7416
7550
|
buildNavLinkAttrs: buildNavLinkAttrs,
|
|
7551
|
+
buildDateStr: buildDateStr,
|
|
7417
7552
|
preventDefault: preventDefault,
|
|
7418
7553
|
whenTransitionDone: whenTransitionDone,
|
|
7419
7554
|
computeInnerRect: computeInnerRect,
|
|
@@ -7464,11 +7599,8 @@ var FullCalendar = (function (exports) {
|
|
|
7464
7599
|
NamedTimeZoneImpl: NamedTimeZoneImpl,
|
|
7465
7600
|
parseMarker: parse,
|
|
7466
7601
|
SegHierarchy: SegHierarchy,
|
|
7467
|
-
|
|
7468
|
-
getEntrySpanEnd: getEntrySpanEnd,
|
|
7602
|
+
groupIntersectingSegs: groupIntersectingSegs,
|
|
7469
7603
|
binarySearch: binarySearch,
|
|
7470
|
-
groupIntersectingEntries: groupIntersectingEntries,
|
|
7471
|
-
intersectSpans: intersectSpans,
|
|
7472
7604
|
Interaction: Interaction,
|
|
7473
7605
|
interactionSettingsToStore: interactionSettingsToStore,
|
|
7474
7606
|
interactionSettingsStore: interactionSettingsStore,
|
|
@@ -7484,7 +7616,8 @@ var FullCalendar = (function (exports) {
|
|
|
7484
7616
|
sortEventSegs: sortEventSegs,
|
|
7485
7617
|
getEventRangeMeta: getEventRangeMeta,
|
|
7486
7618
|
buildEventRangeKey: buildEventRangeKey,
|
|
7487
|
-
|
|
7619
|
+
getEventTagAndAttrs: getEventTagAndAttrs,
|
|
7620
|
+
getEventKey: getEventKey,
|
|
7488
7621
|
DayTableModel: DayTableModel,
|
|
7489
7622
|
Scroller: Scroller,
|
|
7490
7623
|
getNormalizedScrollX: getNormalizedScrollX,
|
|
@@ -7515,7 +7648,6 @@ var FullCalendar = (function (exports) {
|
|
|
7515
7648
|
BgEvent: BgEvent,
|
|
7516
7649
|
WeekNumberContainer: WeekNumberContainer,
|
|
7517
7650
|
MoreLinkContainer: MoreLinkContainer,
|
|
7518
|
-
computeEarliestSegStart: computeEarliestSegStart,
|
|
7519
7651
|
ViewContainer: ViewContainer,
|
|
7520
7652
|
triggerDateSelect: triggerDateSelect,
|
|
7521
7653
|
getDefaultEventEnd: getDefaultEventEnd,
|
|
@@ -7525,7 +7657,12 @@ var FullCalendar = (function (exports) {
|
|
|
7525
7657
|
buildEventApis: buildEventApis,
|
|
7526
7658
|
buildElAttrs: buildElAttrs,
|
|
7527
7659
|
ContentContainer: ContentContainer,
|
|
7528
|
-
|
|
7660
|
+
renderText: renderText,
|
|
7661
|
+
CustomRenderingStore: CustomRenderingStore,
|
|
7662
|
+
computeEarliestStart: computeEarliestStart,
|
|
7663
|
+
computeLatestEnd: computeLatestEnd,
|
|
7664
|
+
getCoordRangeEnd: getCoordRangeEnd,
|
|
7665
|
+
StickyFooterScrollbar: StickyFooterScrollbar
|
|
7529
7666
|
};
|
|
7530
7667
|
|
|
7531
7668
|
const globalLocales = [];
|
|
@@ -7552,9 +7689,9 @@ var FullCalendar = (function (exports) {
|
|
|
7552
7689
|
weekText: 'W',
|
|
7553
7690
|
weekTextLong: 'Week',
|
|
7554
7691
|
closeHint: 'Close',
|
|
7555
|
-
|
|
7556
|
-
eventHint: 'Event',
|
|
7692
|
+
eventsHint: 'Events',
|
|
7557
7693
|
allDayText: 'all-day',
|
|
7694
|
+
timedText: 'timed',
|
|
7558
7695
|
moreLinkText: 'more',
|
|
7559
7696
|
noEventsText: 'No events to display',
|
|
7560
7697
|
};
|
|
@@ -7569,7 +7706,7 @@ var FullCalendar = (function (exports) {
|
|
|
7569
7706
|
? 'Today'
|
|
7570
7707
|
: `This ${buttonText}`;
|
|
7571
7708
|
},
|
|
7572
|
-
}, viewHint: '$0 view', navLinkHint: 'Go to $0', moreLinkHint(eventCnt) {
|
|
7709
|
+
}, viewHint: '$0 view', viewChangeHint: 'Change view', navLinkHint: 'Go to $0', moreLinkHint(eventCnt) {
|
|
7573
7710
|
return `Show ${eventCnt} more event${eventCnt === 1 ? '' : 's'}`;
|
|
7574
7711
|
} });
|
|
7575
7712
|
function organizeRawLocales(explicitRawLocales) {
|
|
@@ -7626,7 +7763,7 @@ var FullCalendar = (function (exports) {
|
|
|
7626
7763
|
// TODO: easier way to add new hooks? need to update a million things
|
|
7627
7764
|
function createPlugin(input) {
|
|
7628
7765
|
return {
|
|
7629
|
-
id: guid(),
|
|
7766
|
+
id: guid$1(),
|
|
7630
7767
|
name: input.name,
|
|
7631
7768
|
premiumReleaseDate: input.premiumReleaseDate ? new Date(input.premiumReleaseDate) : undefined,
|
|
7632
7769
|
deps: input.deps || [],
|
|
@@ -7881,7 +8018,7 @@ var FullCalendar = (function (exports) {
|
|
|
7881
8018
|
};
|
|
7882
8019
|
}
|
|
7883
8020
|
function createViewHookComponent(options) {
|
|
7884
|
-
return (viewProps) => (_(ViewContextType.Consumer, null, (context) => (_(ContentContainer, {
|
|
8021
|
+
return (viewProps) => (_(ViewContextType.Consumer, null, (context) => (_(ContentContainer, { tag: "div", className: buildViewClassName(context.viewSpec), renderProps: Object.assign(Object.assign({}, viewProps), { nextDayThreshold: context.options.nextDayThreshold }), generatorName: undefined, customGenerator: options.content, classNameGenerator: options.classNames, didMount: options.didMount, willUnmount: options.willUnmount }))));
|
|
7885
8022
|
}
|
|
7886
8023
|
|
|
7887
8024
|
function buildViewSpecs(defaultInputs, optionOverrides, dynamicOptionOverrides, localeDefaults) {
|
|
@@ -8101,7 +8238,7 @@ var FullCalendar = (function (exports) {
|
|
|
8101
8238
|
function fetchSource(eventSource, fetchRange, isRefetch, context) {
|
|
8102
8239
|
let { options, calendarApi } = context;
|
|
8103
8240
|
let sourceDef = context.pluginHooks.eventSourceDefs[eventSource.sourceDefId];
|
|
8104
|
-
let fetchId = guid();
|
|
8241
|
+
let fetchId = guid$1();
|
|
8105
8242
|
sourceDef.fetch({
|
|
8106
8243
|
eventSource,
|
|
8107
8244
|
range: fetchRange,
|
|
@@ -8241,17 +8378,25 @@ var FullCalendar = (function (exports) {
|
|
|
8241
8378
|
return { header, footer };
|
|
8242
8379
|
}
|
|
8243
8380
|
function parseToolbar(sectionStrHash, calendarOptions, calendarOptionOverrides, theme, viewSpecs, calendarApi) {
|
|
8244
|
-
let
|
|
8381
|
+
let isRtl = calendarOptions.direction === 'rtl';
|
|
8245
8382
|
let viewsWithButtons = [];
|
|
8246
8383
|
let hasTitle = false;
|
|
8247
|
-
|
|
8248
|
-
let sectionStr = sectionStrHash[sectionName];
|
|
8384
|
+
function processSectionStr(sectionStr) {
|
|
8249
8385
|
let sectionRes = parseSection(sectionStr, calendarOptions, calendarOptionOverrides, theme, viewSpecs, calendarApi);
|
|
8250
|
-
sectionWidgets[sectionName] = sectionRes.widgets;
|
|
8251
8386
|
viewsWithButtons.push(...sectionRes.viewsWithButtons);
|
|
8252
8387
|
hasTitle = hasTitle || sectionRes.hasTitle;
|
|
8388
|
+
return sectionRes.widgets;
|
|
8253
8389
|
}
|
|
8254
|
-
|
|
8390
|
+
const sectionWidgets = {
|
|
8391
|
+
start: processSectionStr(sectionStrHash[isRtl ? 'right' : 'left'] || sectionStrHash.start || ''),
|
|
8392
|
+
center: processSectionStr(sectionStrHash.center || ''),
|
|
8393
|
+
end: processSectionStr(sectionStrHash[isRtl ? 'left' : 'right'] || sectionStrHash.end || ''),
|
|
8394
|
+
};
|
|
8395
|
+
return {
|
|
8396
|
+
sectionWidgets,
|
|
8397
|
+
viewsWithButtons,
|
|
8398
|
+
hasTitle,
|
|
8399
|
+
};
|
|
8255
8400
|
}
|
|
8256
8401
|
/*
|
|
8257
8402
|
BAD: querying icons and text here. should be done at render time
|
|
@@ -8279,6 +8424,7 @@ var FullCalendar = (function (exports) {
|
|
|
8279
8424
|
let buttonIcon; // only one of these will be set
|
|
8280
8425
|
let buttonText; // "
|
|
8281
8426
|
let buttonHint;
|
|
8427
|
+
let isView = false;
|
|
8282
8428
|
// ^ for the title="" attribute, for accessibility
|
|
8283
8429
|
if ((customButtonProps = calendarCustomButtons[buttonName])) {
|
|
8284
8430
|
buttonClick = (ev) => {
|
|
@@ -8292,6 +8438,7 @@ var FullCalendar = (function (exports) {
|
|
|
8292
8438
|
buttonHint = customButtonProps.hint || customButtonProps.text;
|
|
8293
8439
|
}
|
|
8294
8440
|
else if ((viewSpec = viewSpecs[buttonName])) {
|
|
8441
|
+
isView = true;
|
|
8295
8442
|
viewsWithButtons.push(buttonName);
|
|
8296
8443
|
buttonClick = () => {
|
|
8297
8444
|
calendarApi.changeView(buttonName);
|
|
@@ -8329,7 +8476,7 @@ var FullCalendar = (function (exports) {
|
|
|
8329
8476
|
], calendarButtonText[buttonName]);
|
|
8330
8477
|
}
|
|
8331
8478
|
}
|
|
8332
|
-
return { buttonName, buttonClick, buttonIcon, buttonText, buttonHint };
|
|
8479
|
+
return { buttonName, buttonClick, buttonIcon, buttonText, buttonHint, isView };
|
|
8333
8480
|
})));
|
|
8334
8481
|
return { widgets, viewsWithButtons, hasTitle };
|
|
8335
8482
|
}
|
|
@@ -9149,35 +9296,45 @@ var FullCalendar = (function (exports) {
|
|
|
9149
9296
|
render() {
|
|
9150
9297
|
let children = this.props.widgetGroups.map((widgetGroup) => this.renderWidgetGroup(widgetGroup));
|
|
9151
9298
|
return _('div', {
|
|
9152
|
-
className: 'fc-toolbar-
|
|
9299
|
+
className: 'fc-toolbar-section fc-toolbar-' + this.props.name
|
|
9153
9300
|
}, ...children);
|
|
9154
9301
|
}
|
|
9155
9302
|
renderWidgetGroup(widgetGroup) {
|
|
9156
|
-
let { props } = this;
|
|
9157
|
-
let { theme } =
|
|
9303
|
+
let { props, context } = this;
|
|
9304
|
+
let { options, theme } = context;
|
|
9158
9305
|
let children = [];
|
|
9159
9306
|
let isOnlyButtons = true;
|
|
9307
|
+
let isOnlyView = true;
|
|
9308
|
+
for (const widget of widgetGroup) {
|
|
9309
|
+
const { buttonName, isView } = widget;
|
|
9310
|
+
if (buttonName === 'title') {
|
|
9311
|
+
isOnlyButtons = false;
|
|
9312
|
+
}
|
|
9313
|
+
else if (!isView) {
|
|
9314
|
+
isOnlyView = false;
|
|
9315
|
+
}
|
|
9316
|
+
}
|
|
9160
9317
|
for (let widget of widgetGroup) {
|
|
9161
9318
|
let { buttonName, buttonClick, buttonText, buttonIcon, buttonHint } = widget;
|
|
9162
9319
|
if (buttonName === 'title') {
|
|
9163
|
-
|
|
9164
|
-
children.push(_("h2", { className: "fc-toolbar-title" }, props.title));
|
|
9320
|
+
children.push(_("div", { role: 'heading', "aria-level": options.headingLevel, id: props.titleId, className: 'fc-toolbar-title' }, props.title));
|
|
9165
9321
|
}
|
|
9166
9322
|
else {
|
|
9167
9323
|
let isPressed = buttonName === props.activeButton;
|
|
9168
9324
|
let isDisabled = (!props.isTodayEnabled && buttonName === 'today') ||
|
|
9169
9325
|
(!props.isPrevEnabled && buttonName === 'prev') ||
|
|
9170
9326
|
(!props.isNextEnabled && buttonName === 'next');
|
|
9171
|
-
|
|
9172
|
-
|
|
9173
|
-
|
|
9174
|
-
}
|
|
9175
|
-
children.push(_("button", { type: "button", title: typeof buttonHint === 'function' ? buttonHint(props.navUnit) : buttonHint, disabled: isDisabled, "aria-pressed": isPressed, className: buttonClasses.join(' '), onClick: buttonClick }, buttonText || (buttonIcon ? _("span", { className: buttonIcon, role: "img" }) : '')));
|
|
9327
|
+
children.push(_("button", Object.assign({ type: "button", disabled: isDisabled }, ((isOnlyButtons && isOnlyView)
|
|
9328
|
+
? { 'role': 'tab', 'aria-selected': isPressed }
|
|
9329
|
+
: { 'aria-pressed': isPressed }), { "aria-label": typeof buttonHint === 'function' ? buttonHint(props.navUnit) : buttonHint, className: joinClassNames(`fc-${buttonName}-button`, theme.getClassName('button'), isPressed && theme.getClassName('buttonActive')), onClick: buttonClick }), buttonText || (buttonIcon ? _("span", { className: buttonIcon, "aria-hidden": true }) : '')));
|
|
9176
9330
|
}
|
|
9177
9331
|
}
|
|
9178
9332
|
if (children.length > 1) {
|
|
9179
|
-
|
|
9180
|
-
|
|
9333
|
+
return _('div', {
|
|
9334
|
+
role: (isOnlyButtons && isOnlyView) ? 'tablist' : undefined,
|
|
9335
|
+
'aria-label': (isOnlyButtons && isOnlyView) ? options.viewChangeHint : undefined,
|
|
9336
|
+
className: isOnlyButtons ? theme.getClassName('buttonGroup') : undefined,
|
|
9337
|
+
}, ...children);
|
|
9181
9338
|
}
|
|
9182
9339
|
return children[0];
|
|
9183
9340
|
}
|
|
@@ -9185,39 +9342,16 @@ var FullCalendar = (function (exports) {
|
|
|
9185
9342
|
|
|
9186
9343
|
class Toolbar extends BaseComponent {
|
|
9187
9344
|
render() {
|
|
9188
|
-
let { model,
|
|
9189
|
-
let
|
|
9190
|
-
|
|
9191
|
-
|
|
9192
|
-
|
|
9193
|
-
|
|
9194
|
-
if (sectionWidgets.left) {
|
|
9195
|
-
forceLtr = true;
|
|
9196
|
-
startContent = sectionWidgets.left;
|
|
9197
|
-
}
|
|
9198
|
-
else {
|
|
9199
|
-
startContent = sectionWidgets.start;
|
|
9200
|
-
}
|
|
9201
|
-
if (sectionWidgets.right) {
|
|
9202
|
-
forceLtr = true;
|
|
9203
|
-
endContent = sectionWidgets.right;
|
|
9204
|
-
}
|
|
9205
|
-
else {
|
|
9206
|
-
endContent = sectionWidgets.end;
|
|
9207
|
-
}
|
|
9208
|
-
let classNames = [
|
|
9209
|
-
extraClassName || '',
|
|
9210
|
-
'fc-toolbar',
|
|
9211
|
-
forceLtr ? 'fc-toolbar-ltr' : '',
|
|
9212
|
-
];
|
|
9213
|
-
return (_("div", { className: classNames.join(' ') },
|
|
9214
|
-
this.renderSection('start', startContent || []),
|
|
9215
|
-
this.renderSection('center', centerContent || []),
|
|
9216
|
-
this.renderSection('end', endContent || [])));
|
|
9345
|
+
let { model, className } = this.props;
|
|
9346
|
+
let { sectionWidgets } = model;
|
|
9347
|
+
return (_("div", { className: joinClassNames(className, 'fc-toolbar') },
|
|
9348
|
+
this.renderSection('start', sectionWidgets.start),
|
|
9349
|
+
this.renderSection('center', sectionWidgets.center),
|
|
9350
|
+
this.renderSection('end', sectionWidgets.end)));
|
|
9217
9351
|
}
|
|
9218
9352
|
renderSection(key, widgetGroups) {
|
|
9219
9353
|
let { props } = this;
|
|
9220
|
-
return (_(ToolbarSection, { key: key, name: key, widgetGroups: widgetGroups, title: props.title, navUnit: props.navUnit, activeButton: props.activeButton, isTodayEnabled: props.isTodayEnabled, isPrevEnabled: props.isPrevEnabled, isNextEnabled: props.isNextEnabled }));
|
|
9354
|
+
return (_(ToolbarSection, { key: key, name: key, widgetGroups: widgetGroups, title: props.title, titleId: props.titleId, navUnit: props.navUnit, activeButton: props.activeButton, isTodayEnabled: props.isTodayEnabled, isPrevEnabled: props.isPrevEnabled, isNextEnabled: props.isNextEnabled }));
|
|
9221
9355
|
}
|
|
9222
9356
|
}
|
|
9223
9357
|
|
|
@@ -9233,19 +9367,12 @@ var FullCalendar = (function (exports) {
|
|
|
9233
9367
|
let eventRange = getElEventRange(segEl);
|
|
9234
9368
|
if (eventRange && // might be the <div> surrounding the more link
|
|
9235
9369
|
component.isValidSegDownEl(ev.target)) {
|
|
9236
|
-
// our way to simulate a link click for elements that can't be <a> tags
|
|
9237
|
-
// grab before trigger fired in case trigger trashes DOM thru rerendering
|
|
9238
|
-
let hasUrlContainer = elementClosest(ev.target, '.fc-event-forced-url');
|
|
9239
|
-
let url = hasUrlContainer ? hasUrlContainer.querySelector('a[href]').href : '';
|
|
9240
9370
|
context.emitter.trigger('eventClick', {
|
|
9241
9371
|
el: segEl,
|
|
9242
9372
|
event: new EventImpl(component.context, eventRange.def, eventRange.instance),
|
|
9243
9373
|
jsEvent: ev,
|
|
9244
9374
|
view: context.viewApi,
|
|
9245
9375
|
});
|
|
9246
|
-
if (url && !ev.defaultPrevented) {
|
|
9247
|
-
window.location.href = url;
|
|
9248
|
-
}
|
|
9249
9376
|
}
|
|
9250
9377
|
};
|
|
9251
9378
|
this.destroy = listenBySelector(settings.el, 'click', '.fc-event', // on both fg and bg events
|
|
@@ -9302,16 +9429,12 @@ var FullCalendar = (function (exports) {
|
|
|
9302
9429
|
class ViewHarness extends b {
|
|
9303
9430
|
render() {
|
|
9304
9431
|
const { props } = this;
|
|
9305
|
-
return (_("div", { className:
|
|
9306
|
-
'fc-view-
|
|
9307
|
-
props.
|
|
9308
|
-
? 'fc-view-
|
|
9309
|
-
: props.
|
|
9310
|
-
|
|
9311
|
-
: props.aspectRatio != null
|
|
9312
|
-
? 'fc-view-harness-aspectratio'
|
|
9313
|
-
: ''
|
|
9314
|
-
].join(' '), style: {
|
|
9432
|
+
return (_("div", { className: joinClassNames('fc-view-outer', props.height != null
|
|
9433
|
+
? 'fc-view-outer-static'
|
|
9434
|
+
: props.heightLiquid
|
|
9435
|
+
? 'fc-view-outer-liquid'
|
|
9436
|
+
: props.aspectRatio != null
|
|
9437
|
+
&& 'fc-view-outer-aspect-ratio'), style: {
|
|
9315
9438
|
height: props.height,
|
|
9316
9439
|
paddingBottom: props.aspectRatio != null
|
|
9317
9440
|
? `${(1 / props.aspectRatio) * 100}%`
|
|
@@ -9327,6 +9450,7 @@ var FullCalendar = (function (exports) {
|
|
|
9327
9450
|
this.buildViewPropTransformers = memoize(buildViewPropTransformers);
|
|
9328
9451
|
this.buildToolbarProps = memoize(buildToolbarProps);
|
|
9329
9452
|
this.interactionsStore = {};
|
|
9453
|
+
this.viewTitleId = getUniqueDomId();
|
|
9330
9454
|
// Component Registration
|
|
9331
9455
|
// -----------------------------------------------------------------------------------------------------------------
|
|
9332
9456
|
this.registerInteractiveComponent = (component, settingsInput) => {
|
|
@@ -9335,7 +9459,10 @@ var FullCalendar = (function (exports) {
|
|
|
9335
9459
|
EventClicking,
|
|
9336
9460
|
EventHovering,
|
|
9337
9461
|
];
|
|
9338
|
-
let interactionClasses = DEFAULT_INTERACTIONS
|
|
9462
|
+
let interactionClasses = DEFAULT_INTERACTIONS;
|
|
9463
|
+
if (!settingsInput.disableHits) {
|
|
9464
|
+
interactionClasses = interactionClasses.concat(this.props.pluginHooks.componentInteractions);
|
|
9465
|
+
}
|
|
9339
9466
|
let interactions = interactionClasses.map((TheInteractionClass) => new TheInteractionClass(settings));
|
|
9340
9467
|
this.interactionsStore[component.uid] = interactions;
|
|
9341
9468
|
interactionSettingsStore[component.uid] = settings;
|
|
@@ -9374,11 +9501,11 @@ var FullCalendar = (function (exports) {
|
|
|
9374
9501
|
}
|
|
9375
9502
|
let viewContext = this.buildViewContext(props.viewSpec, props.viewApi, props.options, props.dateProfileGenerator, props.dateEnv, props.theme, props.pluginHooks, props.dispatch, props.getCurrentData, props.emitter, props.calendarApi, this.registerInteractiveComponent, this.unregisterInteractiveComponent);
|
|
9376
9503
|
return (_(ViewContextType.Provider, { value: viewContext },
|
|
9377
|
-
toolbarConfig.header && (_(Toolbar, Object.assign({
|
|
9504
|
+
toolbarConfig.header && (_(Toolbar, Object.assign({ className: "fc-header-toolbar", model: toolbarConfig.header, titleId: this.viewTitleId }, toolbarProps))),
|
|
9378
9505
|
_(ViewHarness, { height: viewHeight, heightLiquid: viewHeightLiquid, aspectRatio: viewAspectRatio },
|
|
9379
|
-
this.renderView(props),
|
|
9506
|
+
this.renderView(props, toolbarProps.title),
|
|
9380
9507
|
this.buildAppendContent()),
|
|
9381
|
-
toolbarConfig.footer && (_(Toolbar, Object.assign({
|
|
9508
|
+
toolbarConfig.footer && (_(Toolbar, Object.assign({ className: "fc-footer-toolbar", model: toolbarConfig.footer }, toolbarProps)))));
|
|
9382
9509
|
}
|
|
9383
9510
|
componentDidMount() {
|
|
9384
9511
|
let { props } = this;
|
|
@@ -9409,9 +9536,9 @@ var FullCalendar = (function (exports) {
|
|
|
9409
9536
|
let children = props.pluginHooks.viewContainerAppends.map((buildAppendContent) => buildAppendContent(props));
|
|
9410
9537
|
return _(k$1, {}, ...children);
|
|
9411
9538
|
}
|
|
9412
|
-
renderView(props) {
|
|
9539
|
+
renderView(props, title) {
|
|
9413
9540
|
let { pluginHooks } = props;
|
|
9414
|
-
let { viewSpec } = props;
|
|
9541
|
+
let { viewSpec, toolbarConfig } = props;
|
|
9415
9542
|
let viewProps = {
|
|
9416
9543
|
dateProfile: props.dateProfile,
|
|
9417
9544
|
businessHours: props.businessHours,
|
|
@@ -9422,6 +9549,8 @@ var FullCalendar = (function (exports) {
|
|
|
9422
9549
|
eventDrag: props.eventDrag,
|
|
9423
9550
|
eventResize: props.eventResize,
|
|
9424
9551
|
forPrint: props.forPrint,
|
|
9552
|
+
labelId: toolbarConfig.header && toolbarConfig.header.hasTitle ? this.viewTitleId : undefined,
|
|
9553
|
+
labelStr: toolbarConfig.header && toolbarConfig.header.hasTitle ? undefined : title,
|
|
9425
9554
|
};
|
|
9426
9555
|
let transformers = this.buildViewPropTransformers(pluginHooks.viewPropsTransformers);
|
|
9427
9556
|
for (let transformer of transformers) {
|
|
@@ -9599,7 +9728,7 @@ var FullCalendar = (function (exports) {
|
|
|
9599
9728
|
return sliceEventStore(props.eventStore, props.eventUiBases, props.dateProfile.activeRange, allDay ? props.nextDayThreshold : null).fg;
|
|
9600
9729
|
}
|
|
9601
9730
|
|
|
9602
|
-
const version = '7.0.0-beta.
|
|
9731
|
+
const version = '7.0.0-beta.4';
|
|
9603
9732
|
|
|
9604
9733
|
exports.Calendar = Calendar;
|
|
9605
9734
|
exports.Internal = internal;
|