chunk-2d0d6e79.f7e3d7ac.js 3.2 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d0d6e79"],{7516:function(e,t,n){"use strict";n.r(t);var s=n("2b0e"),i=n("a101"),r=n("6b46");const o={headerToolbar:!0,footerToolbar:!0,events:!0,eventSources:!0,resources:!0},l="undefined"!==typeof document?document.createDocumentFragment():null,d=s["default"].extend({render(e){return e("aside",{style:{display:"none"}},this.$slots.default||[])},mounted(){l&&l.appendChild(this.$el)},beforeDestroy(){l&&l.removeChild(this.$el)}});var a=d;const u="undefined"!==typeof document?document.createDocumentFragment():null,p=s["default"].extend({props:{inPlaceOf:"undefined"!==typeof Element?Element:Object,reportEl:Function,elTag:String,elClasses:Array,elStyle:Object,elAttrs:Object},render(e){return e(this.elTag,{class:this.elClasses,style:this.elStyle,attrs:this.elAttrs},this.$slots.default||[])},mounted(){h(this.$el,this.inPlaceOf),this.inPlaceOf.style.display="none",this.reportEl(this.$el)},updated(){u&&this.inPlaceOf.parentNode!==u&&(h(this.$el,this.inPlaceOf),this.reportEl(this.$el))},beforeDestroy(){u&&this.inPlaceOf.parentNode===u&&u.removeChild(this.inPlaceOf),this.reportEl(null)}});var c=p;function h(e,t){var n;null===(n=t.parentNode)||void 0===n||n.insertBefore(e,t.nextSibling),u&&u.appendChild(t)}const f=s["default"].extend({props:{options:Object},data(){return{renderId:0,customRenderingMap:new Map}},methods:{getApi(){return m(this).calendar},buildOptions(e){return Object.assign(Object.assign({},e),{customRenderingMetaMap:y(this.$scopedSlots),handleCustomRendering:m(this).handleCustomRendering,customRenderingReplaces:!0})}},render(e){const t=[];for(const n of this.customRenderingMap.values()){const s="function"===typeof n.generatorMeta?n.generatorMeta(n.renderProps):n.generatorMeta;t.push(e("div",{key:n.id},[e(c,{key:n.id,props:{inPlaceOf:n.containerEl,reportEl:n.reportNewContainerEl,elTag:n.elTag,elClasses:n.elClasses,elStyle:n.elStyle,elAttrs:n.elAttrs}},s)]))}return e("div",{attrs:{"data-fc-render-id":this.renderId}},[e(a,t)])},mounted(){const e=new r["sc"];m(this).handleCustomRendering=e.handle.bind(e);const t=this.buildOptions(this.options),n=new i["a"](this.$el,t);m(this).calendar=n,n.render(),e.subscribe(e=>{this.customRenderingMap=e,this.renderId++,m(this).needCustomRenderingResize=!0})},beforeUpdate(){this.getApi().resumeRendering()},updated(){m(this).needCustomRenderingResize&&(m(this).needCustomRenderingResize=!1,this.getApi().updateSize())},beforeDestroy(){this.getApi().destroy()},watch:b()});var g=f;function m(e){return e}function b(){let e={options:{deep:!0,handler(e){let t=this.getApi();t.pauseRendering();let n=this.buildOptions(e);t.resetOptions(n),this.renderId++}}};for(let t in o)e["options."+t]={deep:!0,handler(e){if(void 0!==e){let n=this.getApi();n.pauseRendering(),n.resetOptions({[t]:e},[t]),this.renderId++}}};return e}function y(e){const t={};for(const n in e)t[O(n)]=e[n];return t}function O(e){return e.split("-").map((e,t)=>t?R(e):e).join("")}function R(e){return e.charAt(0).toUpperCase()+e.slice(1)}n.d(t,"install",(function(){return w}));let C,v=!1;function w(e){v||(v=!0,e.component("FullCalendar",g))}C="undefined"!==typeof globalThis?globalThis.Vue:window.Vue,C&&C.use({install:w});t["default"]=g}}]);