primevue
Version:
[](https://opensource.org/licenses/MIT) [](https://badge.fury.io/js/primevue)
2 lines (1 loc) • 1.18 kB
JavaScript
var fullcalendar=function(e,t){"use strict";var n={props:{events:Array,options:null},calendar:null,watch:{events(e){this.calendar.removeAllEventSources(),this.calendar.addEventSource(e)},options(e){if(e&&this.calendar)for(let t in e)this.calendar.setOption(t,e[t])}},mounted(){this.$el.offsetParent&&this.initialize()},updated(){!this.calendar&&this.$el.offsetParent&&this.initialize()},beforeUnmount(){this.calendar&&(this.calendar.destroy(),this.calendar=null)},methods:{initialize(){let t={themeSystem:"standard"},n=this.options?{...this.options,...t}:t;this.calendar=new e.Calendar(this.$el,n),this.calendar.render(),this.events&&(this.calendar.removeAllEventSources(),this.calendar.addEventSource(this.events))}}};return function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var a=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css","top"===n&&a.firstChild?a.insertBefore(i,a.firstChild):a.appendChild(i),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(document.createTextNode(e))}}("\n"),n.render=function(e,n,a,i,s,r){return t.openBlock(),t.createBlock("div")},n}(FullCalendar,Vue);