vue3-morris
Version:
> base on [vue-morris](https://github.com/bbonnin/vue-morris) > Vue3 components wrapping Morris.js lib > > See http://morrisjs.github.io/morris.js/ for documentation
2 lines • 49.8 kB
JavaScript
/*! For license information please see vue3-morris.min.js.LICENSE.txt */
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("jQuery"),require("vue")):"function"==typeof define&&define.amd?define(["jQuery","vue"],e):"object"==typeof exports?exports["vue3-morris"]=e(require("jQuery"),require("vue")):t["vue3-morris"]=e(t.$,t.Vue)}(self,((t,e)=>(()=>{var i={287:(t,e,i)=>{"use strict";i.d(e,{A:()=>a});var o=i(601),r=i.n(o),n=i(314),s=i.n(n)()(r());s.push([t.id,".morris-hover{position:absolute;z-index:1000}.morris-hover.morris-default-style{border-radius:10px;padding:6px;color:#666;background:rgba(255,255,255,0.8);border:solid 2px rgba(230,230,230,0.8);font-family:sans-serif;font-size:12px;text-align:center}.morris-hover.morris-default-style .morris-hover-row-label{font-weight:bold;margin:0.25em 0}\n.morris-hover.morris-default-style .morris-hover-point{white-space:nowrap;margin:0.1em 0}\n",""]);const a=s},314:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var i="",o=void 0!==e[5];return e[4]&&(i+="@supports (".concat(e[4],") {")),e[2]&&(i+="@media ".concat(e[2]," {")),o&&(i+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),i+=t(e),o&&(i+="}"),e[2]&&(i+="}"),e[4]&&(i+="}"),i})).join("")},e.i=function(t,i,o,r,n){"string"==typeof t&&(t=[[null,t,void 0]]);var s={};if(o)for(var a=0;a<this.length;a++){var h=this[a][0];null!=h&&(s[h]=!0)}for(var l=0;l<t.length;l++){var p=[].concat(t[l]);o&&s[p[0]]||(void 0!==n&&(void 0===p[5]||(p[1]="@layer".concat(p[5].length>0?" ".concat(p[5]):""," {").concat(p[1],"}")),p[5]=n),i&&(p[2]?(p[1]="@media ".concat(p[2]," {").concat(p[1],"}"),p[2]=i):p[2]=i),r&&(p[4]?(p[1]="@supports (".concat(p[4],") {").concat(p[1],"}"),p[4]=r):p[4]="".concat(r)),e.push(p))}},e}},601:t=>{"use strict";t.exports=function(t){return t[1]}},976:function(t,e,i){var o=i(450);(function(){var t,e,i,r,n=[].slice,s=function(t,e){return function(){return t.apply(e,arguments)}},a={}.hasOwnProperty,h=function(t,e){for(var i in e)a.call(e,i)&&(t[i]=e[i]);function o(){this.constructor=t}return o.prototype=e.prototype,t.prototype=new o,t.__super__=e.prototype,t},l=[].indexOf||function(t){for(var e=0,i=this.length;e<i;e++)if(e in this&&this[e]===t)return e;return-1};e=window.Morris={},t=o,e.EventEmitter=function(){function t(){}return t.prototype.on=function(t,e){return null==this.handlers&&(this.handlers={}),null==this.handlers[t]&&(this.handlers[t]=[]),this.handlers[t].push(e),this},t.prototype.fire=function(){var t,e,i,o,r,s,a;if(i=arguments[0],t=2<=arguments.length?n.call(arguments,1):[],null!=this.handlers&&null!=this.handlers[i]){for(a=[],o=0,r=(s=this.handlers[i]).length;o<r;o++)e=s[o],a.push(e.apply(null,t));return a}},t}(),e.commas=function(t){var e,i,o,r;return null!=t?(o=t<0?"-":"",e=Math.abs(t),o+=(i=Math.floor(e).toFixed(0)).replace(/(?=(?:\d{3})+$)(?!^)/g,","),(r=e.toString()).length>i.length&&(o+=r.slice(i.length)),o):"-"},e.pad2=function(t){return(t<10?"0":"")+t},e.Grid=function(i){function o(e){this.resizeHandler=s(this.resizeHandler,this);var i=this;if("string"==typeof e.element?this.el=t(document.getElementById(e.element)):this.el=t(e.element),null==this.el||0===this.el.length)throw new Error("Graph container element not found");"static"===this.el.css("position")&&this.el.css("position","relative"),this.options=t.extend({},this.gridDefaults,this.defaults||{},e),"string"==typeof this.options.units&&(this.options.postUnits=e.units),this.raphael=new Raphael(this.el[0]),this.elementWidth=null,this.elementHeight=null,this.dirty=!1,this.selectFrom=null,this.init&&this.init(),this.setData(this.options.data),this.el.bind("mousemove",(function(t){var e,o,r,n;return o=i.el.offset(),n=t.pageX-o.left,i.selectFrom?(e=i.data[i.hitTest(Math.min(n,i.selectFrom))]._x,r=i.data[i.hitTest(Math.max(n,i.selectFrom))]._x-e,i.selectionRect.attr({x:e,width:r})):i.fire("hovermove",n,t.pageY-o.top)})),this.el.bind("mouseleave",(function(t){return i.selectFrom&&(i.selectionRect.hide(),i.selectFrom=null),i.fire("hoverout")})),this.el.bind("touchstart touchmove touchend",(function(t){var e,o;return o=t.originalEvent.touches[0]||t.originalEvent.changedTouches[0],e=i.el.offset(),i.fire("hovermove",o.pageX-e.left,o.pageY-e.top)})),this.el.bind("click",(function(t){var e;return e=i.el.offset(),i.fire("gridclick",t.pageX-e.left,t.pageY-e.top)})),this.options.rangeSelect&&(this.selectionRect=this.raphael.rect(0,0,0,this.el.innerHeight()).attr({fill:this.options.rangeSelectColor,stroke:!1}).toBack().hide(),this.el.bind("mousedown",(function(t){var e;return e=i.el.offset(),i.startRange(t.pageX-e.left)})),this.el.bind("mouseup",(function(t){var e;return e=i.el.offset(),i.endRange(t.pageX-e.left),i.fire("hovermove",t.pageX-e.left,t.pageY-e.top)}))),this.options.resize&&t(window).bind("resize",(function(t){return null!=i.timeoutId&&window.clearTimeout(i.timeoutId),i.timeoutId=window.setTimeout(i.resizeHandler,100)})),this.el.css("-webkit-tap-highlight-color","rgba(0,0,0,0)"),this.postInit&&this.postInit()}return h(o,i),o.prototype.gridDefaults={dateFormat:null,axes:!0,grid:!0,gridLineColor:"#eef0f2",gridStrokeWidth:.5,gridTextColor:"#888",gridTextSize:12,gridTextFamily:"sans-serif",gridTextWeight:"normal",hideHover:!1,yLabelFormat:null,xLabelAngle:0,numLines:5,padding:25,parseTime:!0,postUnits:"",preUnits:"",ymax:"auto",ymin:"auto 0",goals:[],goalStrokeWidth:1,goalLineColors:["#666633","#999966","#cc6666","#663333"],events:[],eventStrokeWidth:1,eventLineColors:["#005a04","#ccffbb","#3a5f0b","#005502"],rangeSelect:null,rangeSelectColor:"#eef",resize:!1},o.prototype.setData=function(t,i){var o,r,n,s,a,h,l,p,u,d,c,f,g,y,m;return null==i&&(i=!0),this.options.data=t,null==t||0===t.length?(this.data=[],this.raphael.clear(),void(null!=this.hover&&this.hover.hide())):(f=this.cumulative?0:null,g=this.cumulative?0:null,this.options.goals.length>0&&(a=Math.min.apply(Math,this.options.goals),s=Math.max.apply(Math,this.options.goals),g=null!=g?Math.min(g,a):a,f=null!=f?Math.max(f,s):s),this.data=function(){var i,o,s;for(s=[],n=i=0,o=t.length;i<o;n=++i)l=t[n],(h={src:l}).label=l[this.options.xkey],this.options.parseTime?(h.x=e.parseDate(h.label),this.options.dateFormat?h.label=this.options.dateFormat(h.x):"number"==typeof h.label&&(h.label=new Date(h.label).toString())):(h.x=n,this.options.xLabelFormat&&(h.label=this.options.xLabelFormat(h))),u=0,h.y=function(){var t,e,i,o;for(i=this.options.ykeys,o=[],r=t=0,e=i.length;t<e;r=++t)c=i[r],"string"==typeof(y=l[c])&&(y=parseFloat(y)),null!=y&&"number"!=typeof y&&(y=null),null!=y&&(this.cumulative?u+=y:null!=f?(f=Math.max(y,f),g=Math.min(y,g)):f=g=y),this.cumulative&&null!=u&&(f=Math.max(u,f),g=Math.min(u,g)),o.push(y);return o}.call(this),s.push(h);return s}.call(this),this.options.parseTime&&(this.data=this.data.sort((function(t,e){return(t.x>e.x)-(e.x>t.x)}))),this.xmin=this.data[0].x,this.xmax=this.data[this.data.length-1].x,this.events=[],this.options.events.length>0&&(this.options.parseTime?this.events=function(){var t,i,r,n;for(n=[],t=0,i=(r=this.options.events).length;t<i;t++)o=r[t],n.push(e.parseDate(o));return n}.call(this):this.events=this.options.events,this.xmax=Math.max(this.xmax,Math.max.apply(Math,this.events)),this.xmin=Math.min(this.xmin,Math.min.apply(Math,this.events))),this.xmin===this.xmax&&(this.xmin-=1,this.xmax+=1),this.ymin=this.yboundary("min",g),this.ymax=this.yboundary("max",f),this.ymin===this.ymax&&(g&&(this.ymin-=1),this.ymax+=1),!0!==(m=this.options.axes)&&"both"!==m&&"y"!==m&&!0!==this.options.grid||(this.options.ymax===this.gridDefaults.ymax&&this.options.ymin===this.gridDefaults.ymin?(this.grid=this.autoGridLines(this.ymin,this.ymax,this.options.numLines),this.ymin=Math.min(this.ymin,this.grid[0]),this.ymax=Math.max(this.ymax,this.grid[this.grid.length-1])):(p=(this.ymax-this.ymin)/(this.options.numLines-1),this.grid=function(){var t,e,i;for(i=[],d=t=this.ymin,e=this.ymax;p>0?t<=e:t>=e;d=t+=p)i.push(d);return i}.call(this))),this.dirty=!0,i?this.redraw():void 0)},o.prototype.yboundary=function(t,e){var i,o;return"string"==typeof(i=this.options["y"+t])?"auto"===i.slice(0,4)?i.length>5?(o=parseInt(i.slice(5),10),null==e?o:Math[t](e,o)):null!=e?e:0:parseInt(i,10):i},o.prototype.autoGridLines=function(t,e,i){var o,r,n,s,a,h,l,p,u;return a=e-t,u=Math.floor(Math.log(a)/Math.log(10)),l=Math.pow(10,u),r=Math.floor(t/l)*l,o=Math.ceil(e/l)*l,h=(o-r)/(i-1),1===l&&h>1&&Math.ceil(h)!==h&&(h=Math.ceil(h),o=r+h*(i-1)),r<0&&o>0&&(r=Math.floor(t/h)*h,o=Math.ceil(e/h)*h),h<1?(s=Math.floor(Math.log(h)/Math.log(10)),n=function(){var t,e;for(e=[],p=t=r;h>0?t<=o:t>=o;p=t+=h)e.push(parseFloat(p.toFixed(1-s)));return e}()):n=function(){var t,e;for(e=[],p=t=r;h>0?t<=o:t>=o;p=t+=h)e.push(p);return e}(),n},o.prototype._calc=function(){var t,e,i,o,r,n,s,a;if(r=this.el.width(),i=this.el.height(),(this.elementWidth!==r||this.elementHeight!==i||this.dirty)&&(this.elementWidth=r,this.elementHeight=i,this.dirty=!1,this.left=this.options.padding,this.right=this.elementWidth-this.options.padding,this.top=this.options.padding,this.bottom=this.elementHeight-this.options.padding,!0!==(s=this.options.axes)&&"both"!==s&&"y"!==s||(n=function(){var t,i,o,r;for(r=[],t=0,i=(o=this.grid).length;t<i;t++)e=o[t],r.push(this.measureText(this.yAxisFormat(e)).width);return r}.call(this),this.left+=Math.max.apply(Math,n)),!0!==(a=this.options.axes)&&"both"!==a&&"x"!==a||(t=function(){var t,e,i;for(i=[],o=t=0,e=this.data.length;0<=e?t<e:t>e;o=0<=e?++t:--t)i.push(this.measureText(this.data[o].text,-this.options.xLabelAngle).height);return i}.call(this),this.bottom-=Math.max.apply(Math,t)),this.width=Math.max(1,this.right-this.left),this.height=Math.max(1,this.bottom-this.top),this.dx=this.width/(this.xmax-this.xmin),this.dy=this.height/(this.ymax-this.ymin),this.calc))return this.calc()},o.prototype.transY=function(t){return this.bottom-(t-this.ymin)*this.dy},o.prototype.transX=function(t){return 1===this.data.length?(this.left+this.right)/2:this.left+(t-this.xmin)*this.dx},o.prototype.redraw=function(){if(this.raphael.clear(),this._calc(),this.drawGrid(),this.drawGoals(),this.drawEvents(),this.draw)return this.draw()},o.prototype.measureText=function(t,e){var i,o;return null==e&&(e=0),i=(o=this.raphael.text(100,100,t).attr("font-size",this.options.gridTextSize).attr("font-family",this.options.gridTextFamily).attr("font-weight",this.options.gridTextWeight).rotate(e)).getBBox(),o.remove(),i},o.prototype.yAxisFormat=function(t){return this.yLabelFormat(t)},o.prototype.yLabelFormat=function(t){return"function"==typeof this.options.yLabelFormat?this.options.yLabelFormat(t):""+this.options.preUnits+e.commas(t)+this.options.postUnits},o.prototype.drawGrid=function(){var t,e,i,o,r,n,s,a;if(!1!==this.options.grid||!0===(r=this.options.axes)||"both"===r||"y"===r){for(a=[],i=0,o=(n=this.grid).length;i<o;i++)t=n[i],e=this.transY(t),!0!==(s=this.options.axes)&&"both"!==s&&"y"!==s||this.drawYAxisLabel(this.left-this.options.padding/2,e,this.yAxisFormat(t)),this.options.grid?a.push(this.drawGridLine("M"+this.left+","+e+"H"+(this.left+this.width))):a.push(void 0);return a}},o.prototype.drawGoals=function(){var t,e,i,o,r,n,s;for(s=[],i=o=0,r=(n=this.options.goals).length;o<r;i=++o)e=n[i],t=this.options.goalLineColors[i%this.options.goalLineColors.length],s.push(this.drawGoal(e,t));return s},o.prototype.drawEvents=function(){var t,e,i,o,r,n,s;for(s=[],i=o=0,r=(n=this.events).length;o<r;i=++o)e=n[i],t=this.options.eventLineColors[i%this.options.eventLineColors.length],s.push(this.drawEvent(e,t));return s},o.prototype.drawGoal=function(t,e){return this.raphael.path("M"+this.left+","+this.transY(t)+"H"+this.right).attr("stroke",e).attr("stroke-width",this.options.goalStrokeWidth)},o.prototype.drawEvent=function(t,e){return this.raphael.path("M"+this.transX(t)+","+this.bottom+"V"+this.top).attr("stroke",e).attr("stroke-width",this.options.eventStrokeWidth)},o.prototype.drawYAxisLabel=function(t,e,i){return this.raphael.text(t,e,i).attr("font-size",this.options.gridTextSize).attr("font-family",this.options.gridTextFamily).attr("font-weight",this.options.gridTextWeight).attr("fill",this.options.gridTextColor).attr("text-anchor","end")},o.prototype.drawGridLine=function(t){return this.raphael.path(t).attr("stroke",this.options.gridLineColor).attr("stroke-width",this.options.gridStrokeWidth)},o.prototype.startRange=function(t){return this.hover.hide(),this.selectFrom=t,this.selectionRect.attr({x:t,width:0}).show()},o.prototype.endRange=function(t){var e,i;if(this.selectFrom)return i=Math.min(this.selectFrom,t),e=Math.max(this.selectFrom,t),this.options.rangeSelect.call(this.el,{start:this.data[this.hitTest(i)].x,end:this.data[this.hitTest(e)].x}),this.selectFrom=null},o.prototype.resizeHandler=function(){return this.timeoutId=null,this.raphael.setSize(this.el.width(),this.el.height()),this.redraw()},o}(e.EventEmitter),e.parseDate=function(t){var e,i,o,r,n,s,a,h,l,p,u;return"number"==typeof t?t:(i=t.match(/^(\d+) Q(\d)$/),r=t.match(/^(\d+)-(\d+)$/),n=t.match(/^(\d+)-(\d+)-(\d+)$/),a=t.match(/^(\d+) W(\d+)$/),h=t.match(/^(\d+)-(\d+)-(\d+)[ T](\d+):(\d+)(Z|([+-])(\d\d):?(\d\d))?$/),l=t.match(/^(\d+)-(\d+)-(\d+)[ T](\d+):(\d+):(\d+(\.\d+)?)(Z|([+-])(\d\d):?(\d\d))?$/),i?new Date(parseInt(i[1],10),3*parseInt(i[2],10)-1,1).getTime():r?new Date(parseInt(r[1],10),parseInt(r[2],10)-1,1).getTime():n?new Date(parseInt(n[1],10),parseInt(n[2],10)-1,parseInt(n[3],10)).getTime():a?(4!==(p=new Date(parseInt(a[1],10),0,1)).getDay()&&p.setMonth(0,1+(4-p.getDay()+7)%7),p.getTime()+6048e5*parseInt(a[2],10)):h?h[6]?(s=0,"Z"!==h[6]&&(s=60*parseInt(h[8],10)+parseInt(h[9],10),"+"===h[7]&&(s=0-s)),Date.UTC(parseInt(h[1],10),parseInt(h[2],10)-1,parseInt(h[3],10),parseInt(h[4],10),parseInt(h[5],10)+s)):new Date(parseInt(h[1],10),parseInt(h[2],10)-1,parseInt(h[3],10),parseInt(h[4],10),parseInt(h[5],10)).getTime():l?(u=parseFloat(l[6]),e=Math.floor(u),o=Math.round(1e3*(u-e)),l[8]?(s=0,"Z"!==l[8]&&(s=60*parseInt(l[10],10)+parseInt(l[11],10),"+"===l[9]&&(s=0-s)),Date.UTC(parseInt(l[1],10),parseInt(l[2],10)-1,parseInt(l[3],10),parseInt(l[4],10),parseInt(l[5],10)+s,e,o)):new Date(parseInt(l[1],10),parseInt(l[2],10)-1,parseInt(l[3],10),parseInt(l[4],10),parseInt(l[5],10),e,o).getTime()):new Date(parseInt(t,10),0,1).getTime())},e.Hover=function(){function i(i){null==i&&(i={}),this.options=t.extend({},e.Hover.defaults,i),this.el=t("<div class='"+this.options.class+"'></div>"),this.el.hide(),this.options.parent.append(this.el)}return i.defaults={class:"morris-hover morris-default-style"},i.prototype.update=function(t,e,i){return t?(this.html(t),this.show(),this.moveTo(e,i)):this.hide()},i.prototype.html=function(t){return this.el.html(t)},i.prototype.moveTo=function(t,e){var i,o,r,n,s,a;return s=this.options.parent.innerWidth(),n=this.options.parent.innerHeight(),o=this.el.outerWidth(),i=this.el.outerHeight(),r=Math.min(Math.max(0,t-o/2),s-o),null!=e?(a=e-i-10)<0&&(a=e+10)+i>n&&(a=n/2-i/2):a=n/2-i/2,this.el.css({left:r+"px",top:parseInt(a)+"px"})},i.prototype.show=function(){return this.el.show()},i.prototype.hide=function(){return this.el.hide()},i}(),e.Line=function(t){function i(t){if(this.hilight=s(this.hilight,this),this.onHoverOut=s(this.onHoverOut,this),this.onHoverMove=s(this.onHoverMove,this),this.onGridClick=s(this.onGridClick,this),!(this instanceof e.Line))return new e.Line(t);i.__super__.constructor.call(this,t)}return h(i,t),i.prototype.init=function(){if("always"!==this.options.hideHover)return this.hover=new e.Hover({parent:this.el}),this.on("hovermove",this.onHoverMove),this.on("hoverout",this.onHoverOut),this.on("gridclick",this.onGridClick)},i.prototype.defaults={lineWidth:3,pointSize:4,lineColors:["#0b62a4","#7A92A3","#4da74d","#afd8f8","#edc240","#cb4b4b","#9440ed"],pointStrokeWidths:[1],pointStrokeColors:["#ffffff"],pointFillColors:[],smooth:!0,xLabels:"auto",xLabelFormat:null,xLabelMargin:24,hideHover:!1},i.prototype.calc=function(){return this.calcPoints(),this.generatePaths()},i.prototype.calcPoints=function(){var t,e,i,o,r,n;for(n=[],i=0,o=(r=this.data).length;i<o;i++)(t=r[i])._x=this.transX(t.x),t._y=function(){var i,o,r,n;for(n=[],i=0,o=(r=t.y).length;i<o;i++)null!=(e=r[i])?n.push(this.transY(e)):n.push(e);return n}.call(this),n.push(t._ymax=Math.min.apply(Math,[this.bottom].concat(function(){var i,o,r,n;for(n=[],i=0,o=(r=t._y).length;i<o;i++)null!=(e=r[i])&&n.push(e);return n}())));return n},i.prototype.hitTest=function(t){var e,i,o,r;if(0===this.data.length)return null;for(e=i=0,o=(r=this.data.slice(1)).length;i<o&&!(t<(r[e]._x+this.data[e]._x)/2);e=++i);return e},i.prototype.onGridClick=function(t,e){var i;return i=this.hitTest(t),this.fire("click",i,this.data[i].src,t,e)},i.prototype.onHoverMove=function(t,e){var i;return i=this.hitTest(t),this.displayHoverForRow(i)},i.prototype.onHoverOut=function(){if(!1!==this.options.hideHover)return this.displayHoverForRow(null)},i.prototype.displayHoverForRow=function(t){var e;return null!=t?((e=this.hover).update.apply(e,this.hoverContentForRow(t)),this.hilight(t)):(this.hover.hide(),this.hilight())},i.prototype.hoverContentForRow=function(t){var e,i,o,r,n,s,a;for(e="<div class='morris-hover-row-label'>"+(o=this.data[t]).label+"</div>",i=n=0,s=(a=o.y).length;n<s;i=++n)r=a[i],e+="<div class='morris-hover-point' style='color: "+this.colorFor(o,i,"label")+"'>\n "+this.options.labels[i]+":\n "+this.yLabelFormat(r)+"\n</div>";return"function"==typeof this.options.hoverCallback&&(e=this.options.hoverCallback(t,this.options,e,o.src)),[e,o._x,o._ymax]},i.prototype.generatePaths=function(){var t,i,o,r;return this.paths=function(){var n,s,a,h;for(h=[],i=n=0,s=this.options.ykeys.length;0<=s?n<s:n>s;i=0<=s?++n:--n)r="boolean"==typeof this.options.smooth?this.options.smooth:(a=this.options.ykeys[i],l.call(this.options.smooth,a)>=0),(t=function(){var t,e,r,n;for(n=[],t=0,e=(r=this.data).length;t<e;t++)void 0!==(o=r[t])._y[i]&&n.push({x:o._x,y:o._y[i]});return n}.call(this)).length>1?h.push(e.Line.createPath(t,r,this.bottom)):h.push(null);return h}.call(this)},i.prototype.draw=function(){var t;if(!0!==(t=this.options.axes)&&"both"!==t&&"x"!==t||this.drawXAxis(),this.drawSeries(),!1===this.options.hideHover)return this.displayHoverForRow(this.data.length-1)},i.prototype.drawXAxis=function(){var t,i,o,r,n,s,a,h,l,p,u=this;for(a=this.bottom+this.options.padding/2,n=null,r=null,t=function(t,e){var i,o,s,h,l;return l=(i=u.drawXAxisLabel(u.transX(e),a,t)).getBBox(),i.transform("r"+-u.options.xLabelAngle),o=i.getBBox(),i.transform("t0,"+o.height/2+"..."),0!==u.options.xLabelAngle&&(h=-.5*l.width*Math.cos(u.options.xLabelAngle*Math.PI/180),i.transform("t"+h+",0...")),o=i.getBBox(),(null==n||n>=o.x+o.width||null!=r&&r>=o.x)&&o.x>=0&&o.x+o.width<u.el.width()?(0!==u.options.xLabelAngle&&(s=1.25*u.options.gridTextSize/Math.sin(u.options.xLabelAngle*Math.PI/180),r=o.x-s),n=o.x-u.options.xLabelMargin):i.remove()},o=this.options.parseTime?1===this.data.length&&"auto"===this.options.xLabels?[[this.data[0].label,this.data[0].x]]:e.labelSeries(this.xmin,this.xmax,this.width,this.options.xLabels,this.options.xLabelFormat):function(){var t,e,i,o;for(o=[],t=0,e=(i=this.data).length;t<e;t++)s=i[t],o.push([s.label,s.x]);return o}.call(this),o.reverse(),p=[],h=0,l=o.length;h<l;h++)i=o[h],p.push(t(i[0],i[1]));return p},i.prototype.drawSeries=function(){var t,e,i,o,r,n;for(this.seriesPoints=[],t=e=o=this.options.ykeys.length-1;o<=0?e<=0:e>=0;t=o<=0?++e:--e)this._drawLineFor(t);for(n=[],t=i=r=this.options.ykeys.length-1;r<=0?i<=0:i>=0;t=r<=0?++i:--i)n.push(this._drawPointFor(t));return n},i.prototype._drawPointFor=function(t){var e,i,o,r,n,s;for(this.seriesPoints[t]=[],s=[],o=0,r=(n=this.data).length;o<r;o++)e=null,null!=(i=n[o])._y[t]&&(e=this.drawLinePoint(i._x,i._y[t],this.colorFor(i,t,"point"),t)),s.push(this.seriesPoints[t].push(e));return s},i.prototype._drawLineFor=function(t){var e;if(null!==(e=this.paths[t]))return this.drawLinePath(e,this.colorFor(null,t,"line"),t)},i.createPath=function(t,i,o){var r,n,s,a,h,l,p,u,d,c;for(p="",i&&(s=e.Line.gradients(t)),u={y:null},a=d=0,c=t.length;d<c;a=++d)null!=(r=t[a]).y&&(null!=u.y?i?(n=s[a],l=s[a-1],h=(r.x-u.x)/4,p+="C"+(u.x+h)+","+Math.min(o,u.y+h*l)+","+(r.x-h)+","+Math.min(o,r.y-h*n)+","+r.x+","+r.y):p+="L"+r.x+","+r.y:i&&null==s[a]||(p+="M"+r.x+","+r.y)),u=r;return p},i.gradients=function(t){var e,i,o,r,n,s,a,h;for(i=function(t,e){return(t.y-e.y)/(t.x-e.x)},h=[],o=s=0,a=t.length;s<a;o=++s)null!=(e=t[o]).y?(r=t[o+1]||{y:null},null!=(n=t[o-1]||{y:null}).y&&null!=r.y?h.push(i(n,r)):null!=n.y?h.push(i(n,e)):null!=r.y?h.push(i(e,r)):h.push(null)):h.push(null);return h},i.prototype.hilight=function(t){var e,i,o,r,n;if(null!==this.prevHilight&&this.prevHilight!==t)for(e=i=0,r=this.seriesPoints.length-1;0<=r?i<=r:i>=r;e=0<=r?++i:--i)this.seriesPoints[e][this.prevHilight]&&this.seriesPoints[e][this.prevHilight].animate(this.pointShrinkSeries(e));if(null!==t&&this.prevHilight!==t)for(e=o=0,n=this.seriesPoints.length-1;0<=n?o<=n:o>=n;e=0<=n?++o:--o)this.seriesPoints[e][t]&&this.seriesPoints[e][t].animate(this.pointGrowSeries(e));return this.prevHilight=t},i.prototype.colorFor=function(t,e,i){return"function"==typeof this.options.lineColors?this.options.lineColors.call(this,t,e,i):"point"===i&&this.options.pointFillColors[e%this.options.pointFillColors.length]||this.options.lineColors[e%this.options.lineColors.length]},i.prototype.drawXAxisLabel=function(t,e,i){return this.raphael.text(t,e,i).attr("font-size",this.options.gridTextSize).attr("font-family",this.options.gridTextFamily).attr("font-weight",this.options.gridTextWeight).attr("fill",this.options.gridTextColor)},i.prototype.drawLinePath=function(t,e,i){return this.raphael.path(t).attr("stroke",e).attr("stroke-width",this.lineWidthForSeries(i))},i.prototype.drawLinePoint=function(t,e,i,o){return this.raphael.circle(t,e,this.pointSizeForSeries(o)).attr("fill",i).attr("stroke-width",this.pointStrokeWidthForSeries(o)).attr("stroke",this.pointStrokeColorForSeries(o))},i.prototype.pointStrokeWidthForSeries=function(t){return this.options.pointStrokeWidths[t%this.options.pointStrokeWidths.length]},i.prototype.pointStrokeColorForSeries=function(t){return this.options.pointStrokeColors[t%this.options.pointStrokeColors.length]},i.prototype.lineWidthForSeries=function(t){return this.options.lineWidth instanceof Array?this.options.lineWidth[t%this.options.lineWidth.length]:this.options.lineWidth},i.prototype.pointSizeForSeries=function(t){return this.options.pointSize instanceof Array?this.options.pointSize[t%this.options.pointSize.length]:this.options.pointSize},i.prototype.pointGrowSeries=function(t){return Raphael.animation({r:this.pointSizeForSeries(t)+3},25,"linear")},i.prototype.pointShrinkSeries=function(t){return Raphael.animation({r:this.pointSizeForSeries(t)},25,"linear")},i}(e.Grid),e.labelSeries=function(i,o,r,n,s){var a,h,l,p,u,d,c,f,g,y,m;if(l=200*(o-i)/r,h=new Date(i),void 0===(c=e.LABEL_SPECS[n]))for(g=0,y=(m=e.AUTO_LABEL_ORDER).length;g<y;g++)if(p=m[g],l>=(d=e.LABEL_SPECS[p]).span){c=d;break}for(void 0===c&&(c=e.LABEL_SPECS.second),s&&(c=t.extend({},c,{fmt:s})),a=c.start(h),u=[];(f=a.getTime())<=o;)f>=i&&u.push([c.fmt(a),f]),c.incr(a);return u},i=function(t){return{span:60*t*1e3,start:function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours())},fmt:function(t){return e.pad2(t.getHours())+":"+e.pad2(t.getMinutes())},incr:function(e){return e.setUTCMinutes(e.getUTCMinutes()+t)}}},r=function(t){return{span:1e3*t,start:function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes())},fmt:function(t){return e.pad2(t.getHours())+":"+e.pad2(t.getMinutes())+":"+e.pad2(t.getSeconds())},incr:function(e){return e.setUTCSeconds(e.getUTCSeconds()+t)}}},e.LABEL_SPECS={decade:{span:1728e8,start:function(t){return new Date(t.getFullYear()-t.getFullYear()%10,0,1)},fmt:function(t){return""+t.getFullYear()},incr:function(t){return t.setFullYear(t.getFullYear()+10)}},year:{span:1728e7,start:function(t){return new Date(t.getFullYear(),0,1)},fmt:function(t){return""+t.getFullYear()},incr:function(t){return t.setFullYear(t.getFullYear()+1)}},month:{span:24192e5,start:function(t){return new Date(t.getFullYear(),t.getMonth(),1)},fmt:function(t){return t.getFullYear()+"-"+e.pad2(t.getMonth()+1)},incr:function(t){return t.setMonth(t.getMonth()+1)}},week:{span:6048e5,start:function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate())},fmt:function(t){return t.getFullYear()+"-"+e.pad2(t.getMonth()+1)+"-"+e.pad2(t.getDate())},incr:function(t){return t.setDate(t.getDate()+7)}},day:{span:864e5,start:function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate())},fmt:function(t){return t.getFullYear()+"-"+e.pad2(t.getMonth()+1)+"-"+e.pad2(t.getDate())},incr:function(t){return t.setDate(t.getDate()+1)}},hour:i(60),"30min":i(30),"15min":i(15),"10min":i(10),"5min":i(5),minute:i(1),"30sec":r(30),"15sec":r(15),"10sec":r(10),"5sec":r(5),second:r(1)},e.AUTO_LABEL_ORDER=["decade","year","month","week","day","hour","30min","15min","10min","5min","minute","30sec","15sec","10sec","5sec","second"],e.Area=function(i){var o;function r(i){var n;if(!(this instanceof e.Area))return new e.Area(i);n=t.extend({},o,i),this.cumulative=!n.behaveLikeLine,"auto"===n.fillOpacity&&(n.fillOpacity=n.behaveLikeLine?.8:1),r.__super__.constructor.call(this,n)}return h(r,i),o={fillOpacity:"auto",behaveLikeLine:!1},r.prototype.calcPoints=function(){var t,e,i,o,r,n,s;for(s=[],o=0,r=(n=this.data).length;o<r;o++)(t=n[o])._x=this.transX(t.x),e=0,t._y=function(){var o,r,n,s;for(s=[],o=0,r=(n=t.y).length;o<r;o++)i=n[o],this.options.behaveLikeLine?s.push(this.transY(i)):(e+=i||0,s.push(this.transY(e)));return s}.call(this),s.push(t._ymax=Math.max.apply(Math,t._y));return s},r.prototype.drawSeries=function(){var t,e,i,o,r,n,s,a;for(this.seriesPoints=[],e=this.options.behaveLikeLine?function(){n=[];for(var t=0,e=this.options.ykeys.length-1;0<=e?t<=e:t>=e;0<=e?t++:t--)n.push(t);return n}.apply(this):function(){s=[];for(var t=r=this.options.ykeys.length-1;r<=0?t<=0:t>=0;r<=0?t++:t--)s.push(t);return s}.apply(this),a=[],i=0,o=e.length;i<o;i++)t=e[i],this._drawFillFor(t),this._drawLineFor(t),a.push(this._drawPointFor(t));return a},r.prototype._drawFillFor=function(t){var e;if(null!==(e=this.paths[t]))return e=e+"L"+this.transX(this.xmax)+","+this.bottom+"L"+this.transX(this.xmin)+","+this.bottom+"Z",this.drawFilledPath(e,this.fillForSeries(t))},r.prototype.fillForSeries=function(t){var e;return e=Raphael.rgb2hsl(this.colorFor(this.data[t],t,"line")),Raphael.hsl(e.h,this.options.behaveLikeLine?.9*e.s:.75*e.s,Math.min(.98,this.options.behaveLikeLine?1.2*e.l:1.25*e.l))},r.prototype.drawFilledPath=function(t,e){return this.raphael.path(t).attr("fill",e).attr("fill-opacity",this.options.fillOpacity).attr("stroke","none")},r}(e.Line),e.Bar=function(i){function o(i){if(this.onHoverOut=s(this.onHoverOut,this),this.onHoverMove=s(this.onHoverMove,this),this.onGridClick=s(this.onGridClick,this),!(this instanceof e.Bar))return new e.Bar(i);o.__super__.constructor.call(this,t.extend({},i,{parseTime:!1}))}return h(o,i),o.prototype.init=function(){if(this.cumulative=this.options.stacked,"always"!==this.options.hideHover)return this.hover=new e.Hover({parent:this.el}),this.on("hovermove",this.onHoverMove),this.on("hoverout",this.onHoverOut),this.on("gridclick",this.onGridClick)},o.prototype.defaults={barSizeRatio:.75,barGap:3,barColors:["#0b62a4","#7a92a3","#4da74d","#afd8f8","#edc240","#cb4b4b","#9440ed"],barOpacity:1,barRadius:[0,0,0,0],xLabelMargin:50},o.prototype.calc=function(){var t;if(this.calcBars(),!1===this.options.hideHover)return(t=this.hover).update.apply(t,this.hoverContentForRow(this.data.length-1))},o.prototype.calcBars=function(){var t,e,i,o,r,n,s;for(s=[],t=o=0,r=(n=this.data).length;o<r;t=++o)(e=n[t])._x=this.left+this.width*(t+.5)/this.data.length,s.push(e._y=function(){var t,o,r,n;for(n=[],t=0,o=(r=e.y).length;t<o;t++)null!=(i=r[t])?n.push(this.transY(i)):n.push(null);return n}.call(this));return s},o.prototype.draw=function(){var t;return!0!==(t=this.options.axes)&&"both"!==t&&"x"!==t||this.drawXAxis(),this.drawSeries()},o.prototype.drawXAxis=function(){var t,e,i,o,r,n,s,a,h,l,p,u,d;for(l=this.bottom+(this.options.xAxisLabelTopPadding||this.options.padding/2),s=null,n=null,d=[],t=p=0,u=this.data.length;0<=u?p<u:p>u;t=0<=u?++p:--p)a=this.data[this.data.length-1-t],h=(e=this.drawXAxisLabel(a._x,l,a.label)).getBBox(),e.transform("r"+-this.options.xLabelAngle),i=e.getBBox(),e.transform("t0,"+i.height/2+"..."),0!==this.options.xLabelAngle&&(r=-.5*h.width*Math.cos(this.options.xLabelAngle*Math.PI/180),e.transform("t"+r+",0...")),(null==s||s>=i.x+i.width||null!=n&&n>=i.x)&&i.x>=0&&i.x+i.width<this.el.width()?(0!==this.options.xLabelAngle&&(o=1.25*this.options.gridTextSize/Math.sin(this.options.xLabelAngle*Math.PI/180),n=i.x-o),d.push(s=i.x-this.options.xLabelMargin)):d.push(e.remove());return d},o.prototype.drawSeries=function(){var t,e,i,o,r,n,s,a,h,l,p,u,d,c,f;return i=this.width/this.options.data.length,a=this.options.stacked?1:this.options.ykeys.length,t=(i*this.options.barSizeRatio-this.options.barGap*(a-1))/a,this.options.barSize&&(t=Math.min(t,this.options.barSize)),u=i-t*a-this.options.barGap*(a-1),s=u/2,f=this.ymin<=0&&this.ymax>=0?this.transY(0):null,this.bars=function(){var a,u,g,y;for(g=this.data,y=[],o=a=0,u=g.length;a<u;o=++a)h=g[o],r=0,y.push(function(){var a,u,g,y;for(g=h._y,y=[],l=a=0,u=g.length;a<u;l=++a)null!==(c=g[l])?(f?(d=Math.min(c,f),e=Math.max(c,f)):(d=c,e=this.bottom),n=this.left+o*i+s,this.options.stacked||(n+=l*(t+this.options.barGap)),p=e-d,this.options.verticalGridCondition&&this.options.verticalGridCondition(h.x)&&this.drawBar(this.left+o*i,this.top,i,Math.abs(this.top-this.bottom),this.options.verticalGridColor,this.options.verticalGridOpacity,this.options.barRadius),this.options.stacked&&(d-=r),this.drawBar(n,d,t,p,this.colorFor(h,l,"bar"),this.options.barOpacity,this.options.barRadius),y.push(r+=p)):y.push(null);return y}.call(this));return y}.call(this)},o.prototype.colorFor=function(t,e,i){var o,r;return"function"==typeof this.options.barColors?(o={x:t.x,y:t.y[e],label:t.label},r={index:e,key:this.options.ykeys[e],label:this.options.labels[e]},this.options.barColors.call(this,o,r,i)):this.options.barColors[e%this.options.barColors.length]},o.prototype.hitTest=function(t){return 0===this.data.length?null:(t=Math.max(Math.min(t,this.right),this.left),Math.min(this.data.length-1,Math.floor((t-this.left)/(this.width/this.data.length))))},o.prototype.onGridClick=function(t,e){var i;return i=this.hitTest(t),this.fire("click",i,this.data[i].src,t,e)},o.prototype.onHoverMove=function(t,e){var i,o;return i=this.hitTest(t),(o=this.hover).update.apply(o,this.hoverContentForRow(i))},o.prototype.onHoverOut=function(){if(!1!==this.options.hideHover)return this.hover.hide()},o.prototype.hoverContentForRow=function(t){var e,i,o,r,n,s,a;for(e="<div class='morris-hover-row-label'>"+(o=this.data[t]).label+"</div>",i=n=0,s=(a=o.y).length;n<s;i=++n)r=a[i],e+="<div class='morris-hover-point' style='color: "+this.colorFor(o,i,"label")+"'>\n "+this.options.labels[i]+":\n "+this.yLabelFormat(r)+"\n</div>";return"function"==typeof this.options.hoverCallback&&(e=this.options.hoverCallback(t,this.options,e,o.src)),[e,this.left+(t+.5)*this.width/this.data.length]},o.prototype.drawXAxisLabel=function(t,e,i){return this.raphael.text(t,e,i).attr("font-size",this.options.gridTextSize).attr("font-family",this.options.gridTextFamily).attr("font-weight",this.options.gridTextWeight).attr("fill",this.options.gridTextColor)},o.prototype.drawBar=function(t,e,i,o,r,n,s){var a;return(0===(a=Math.max.apply(Math,s))||a>o?this.raphael.rect(t,e,i,o):this.raphael.path(this.roundedRect(t,e,i,o,s))).attr("fill",r).attr("fill-opacity",n).attr("stroke","none")},o.prototype.roundedRect=function(t,e,i,o,r){return null==r&&(r=[0,0,0,0]),["M",t,r[0]+e,"Q",t,e,t+r[0],e,"L",t+i-r[1],e,"Q",t+i,e,t+i,e+r[1],"L",t+i,e+o-r[2],"Q",t+i,e+o,t+i-r[2],e+o,"L",t+r[3],e+o,"Q",t,e+o,t,e+o-r[3],"Z"]},o}(e.Grid),e.Donut=function(i){function o(i){this.resizeHandler=s(this.resizeHandler,this),this.select=s(this.select,this),this.click=s(this.click,this);var o=this;if(!(this instanceof e.Donut))return new e.Donut(i);if(this.options=t.extend({},this.defaults,i),"string"==typeof i.element?this.el=t(document.getElementById(i.element)):this.el=t(i.element),null===this.el||0===this.el.length)throw new Error("Graph placeholder not found.");void 0!==i.data&&0!==i.data.length&&(this.raphael=new Raphael(this.el[0]),this.options.resize&&t(window).bind("resize",(function(t){return null!=o.timeoutId&&window.clearTimeout(o.timeoutId),o.timeoutId=window.setTimeout(o.resizeHandler,100)})),this.setData(i.data))}return h(o,i),o.prototype.defaults={colors:["#0B62A4","#3980B5","#679DC6","#95BBD7","#B0CCE1","#095791","#095085","#083E67","#052C48","#042135"],backgroundColor:"#FFFFFF",labelColor:"#000000",formatter:e.commas,resize:!1},o.prototype.redraw=function(){var t,i,o,r,n,s,a,h,l,p,u,d,c,f,g,y,m,v,x,b,w,k;for(this.raphael.clear(),i=this.el.width()/2,o=this.el.height()/2,d=(Math.min(i,o)-10)/3,u=0,c=0,y=(x=this.values).length;c<y;c++)u+=x[c];for(h=5/(2*d),t=1.9999*Math.PI-h*this.data.length,s=0,n=0,this.segments=[],r=f=0,m=(b=this.values).length;f<m;r=++f)l=s+h+t*(b[r]/u),(p=new e.DonutSegment(i,o,2*d,d,s,l,this.data[r].color||this.options.colors[n%this.options.colors.length],this.options.backgroundColor,n,this.raphael)).render(),this.segments.push(p),p.on("hover",this.select),p.on("click",this.click),s=l,n+=1;for(this.text1=this.drawEmptyDonutLabel(i,o-10,this.options.labelColor,15,800),this.text2=this.drawEmptyDonutLabel(i,o+10,this.options.labelColor,14),a=Math.max.apply(Math,this.values),n=0,k=[],g=0,v=(w=this.values).length;g<v;g++){if(w[g]===a){this.select(n);break}k.push(n+=1)}return k},o.prototype.setData=function(t){var e;return this.data=t,this.values=function(){var t,i,o,r;for(r=[],t=0,i=(o=this.data).length;t<i;t++)e=o[t],r.push(parseFloat(e.value));return r}.call(this),this.redraw()},o.prototype.click=function(t){return this.fire("click",t,this.data[t])},o.prototype.select=function(t){var e,i,o,r;for(i=0,o=(r=this.segments).length;i<o;i++)r[i].deselect();return this.segments[t].select(),e=this.data[t],this.setLabels(e.label,this.options.formatter(e.value,e))},o.prototype.setLabels=function(t,e){var i,o,r,n,s,a,h,l;return n=1.8*(i=2*(Math.min(this.el.width()/2,this.el.height()/2)-10)/3),r=i/2,o=i/3,this.text1.attr({text:t,transform:""}),s=this.text1.getBBox(),a=Math.min(n/s.width,r/s.height),this.text1.attr({transform:"S"+a+","+a+","+(s.x+s.width/2)+","+(s.y+s.height)}),this.text2.attr({text:e,transform:""}),h=this.text2.getBBox(),l=Math.min(n/h.width,o/h.height),this.text2.attr({transform:"S"+l+","+l+","+(h.x+h.width/2)+","+h.y})},o.prototype.drawEmptyDonutLabel=function(t,e,i,o,r){var n;return n=this.raphael.text(t,e,"").attr("font-size",o).attr("fill",i),null!=r&&n.attr("font-weight",r),n},o.prototype.resizeHandler=function(){return this.timeoutId=null,this.raphael.setSize(this.el.width(),this.el.height()),this.redraw()},o}(e.EventEmitter),e.DonutSegment=function(t){function e(t,e,i,o,r,n,a,h,l,p){this.cx=t,this.cy=e,this.inner=i,this.outer=o,this.color=a,this.backgroundColor=h,this.index=l,this.raphael=p,this.deselect=s(this.deselect,this),this.select=s(this.select,this),this.sin_p0=Math.sin(r),this.cos_p0=Math.cos(r),this.sin_p1=Math.sin(n),this.cos_p1=Math.cos(n),this.is_long=n-r>Math.PI?1:0,this.path=this.calcSegment(this.inner+3,this.inner+this.outer-5),this.selectedPath=this.calcSegment(this.inner+3,this.inner+this.outer),this.hilight=this.calcArc(this.inner)}return h(e,t),e.prototype.calcArcPoints=function(t){return[this.cx+t*this.sin_p0,this.cy+t*this.cos_p0,this.cx+t*this.sin_p1,this.cy+t*this.cos_p1]},e.prototype.calcSegment=function(t,e){var i,o,r,n,s,a,h,l,p,u;return i=(p=this.calcArcPoints(t))[0],r=p[1],o=p[2],n=p[3],s=(u=this.calcArcPoints(e))[0],h=u[1],a=u[2],l=u[3],"M"+i+","+r+"A"+t+","+t+",0,"+this.is_long+",0,"+o+","+n+"L"+a+","+l+"A"+e+","+e+",0,"+this.is_long+",1,"+s+","+h+"Z"},e.prototype.calcArc=function(t){var e,i,o,r,n;return e=(n=this.calcArcPoints(t))[0],o=n[1],i=n[2],r=n[3],"M"+e+","+o+"A"+t+","+t+",0,"+this.is_long+",0,"+i+","+r},e.prototype.render=function(){var t=this;return this.arc=this.drawDonutArc(this.hilight,this.color),this.seg=this.drawDonutSegment(this.path,this.color,this.backgroundColor,(function(){return t.fire("hover",t.index)}),(function(){return t.fire("click",t.index)}))},e.prototype.drawDonutArc=function(t,e){return this.raphael.path(t).attr({stroke:e,"stroke-width":2,opacity:0})},e.prototype.drawDonutSegment=function(t,e,i,o,r){return this.raphael.path(t).attr({fill:e,stroke:i,"stroke-width":3}).hover(o).click(r)},e.prototype.select=function(){if(!this.selected)return this.seg.animate({path:this.selectedPath},150,"<>"),this.arc.animate({opacity:1},150,"<>"),this.selected=!0},e.prototype.deselect=function(){if(this.selected)return this.seg.animate({path:this.path},150,"<>"),this.arc.animate({opacity:0},150,"<>"),this.selected=!1},e}(e.EventEmitter)}).call(this)},72:t=>{"use strict";var e=[];function i(t){for(var i=-1,o=0;o<e.length;o++)if(e[o].identifier===t){i=o;break}return i}function o(t,o){for(var n={},s=[],a=0;a<t.length;a++){var h=t[a],l=o.base?h[0]+o.base:h[0],p=n[l]||0,u="".concat(l," ").concat(p);n[l]=p+1;var d=i(u),c={css:h[1],media:h[2],sourceMap:h[3],supports:h[4],layer:h[5]};if(-1!==d)e[d].references++,e[d].updater(c);else{var f=r(c,o);o.byIndex=a,e.splice(a,0,{identifier:u,updater:f,references:1})}s.push(u)}return s}function r(t,e){var i=e.domAPI(e);i.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;i.update(t=e)}else i.remove()}}t.exports=function(t,r){var n=o(t=t||[],r=r||{});return function(t){t=t||[];for(var s=0;s<n.length;s++){var a=i(n[s]);e[a].references--}for(var h=o(t,r),l=0;l<n.length;l++){var p=i(n[l]);0===e[p].references&&(e[p].updater(),e.splice(p,1))}n=h}}},659:t=>{"use strict";var e={};t.exports=function(t,i){var o=function(t){if(void 0===e[t]){var i=document.querySelector(t);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(t){i=null}e[t]=i}return e[t]}(t);if(!o)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");o.appendChild(i)}},540:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},56:(t,e,i)=>{"use strict";t.exports=function(t){var e=i.nc;e&&t.setAttribute("nonce",e)}},825:t=>{"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(i){!function(t,e,i){var o="";i.supports&&(o+="@supports (".concat(i.supports,") {")),i.media&&(o+="@media ".concat(i.media," {"));var r=void 0!==i.layer;r&&(o+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),o+=i.css,r&&(o+="}"),i.media&&(o+="}"),i.supports&&(o+="}");var n=i.sourceMap;n&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(n))))," */")),e.styleTagTransform(o,t,e.options)}(e,t,i)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},113:t=>{"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},450:e=>{"use strict";e.exports=t},154:t=>{"use strict";t.exports=e}},o={};function r(t){var e=o[t];if(void 0!==e)return e.exports;var n=o[t]={id:t,exports:{}};return i[t].call(n.exports,n,n.exports,r),n.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var i in e)r.o(e,i)&&!r.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.nc=void 0;var n={};return(()=>{"use strict";r.d(n,{default:()=>W});var t=r(154),e=(r(976),r(72)),i=r.n(e),o=r(825),s=r.n(o),a=r(659),h=r.n(a),l=r(56),p=r.n(l),u=r(540),d=r.n(u),c=r(113),f=r.n(c),g=r(287),y={};y.styleTagTransform=f(),y.setAttributes=p(),y.insert=h().bind(null,"head"),y.domAPI=s(),y.insertStyleElement=d();i()(g.A,y);g.A&&g.A.locals&&g.A.locals;const m={toObject:function(t){return"string"==typeof t?JSON.parse(t):t},toBoolean:function(t){return"string"==typeof t?"true"===t:t},toInt:function(t){return"string"==typeof t?parseInt(t):t}};var v={id:{type:String,required:!0},data:{type:[String,Array],required:!0},barColors:{type:[String,Array,Function],required:!1},xkey:{type:String,required:!1,default:"key"},ykeys:{type:[String,Array],required:!1,default:function(){return["value"]}},labels:{type:[String,Array],required:!1,default:function(){return["Value"]}},hoverCallback:{type:Function,required:!1},axes:{type:[Boolean,String],required:!1,default:!0},hideHover:{type:String,required:!1},stacked:{type:[Boolean,String],required:!1},resize:{type:[Boolean,String],required:!1},horizontal:{type:[Boolean,String],required:!1,default:!1},grid:{type:[Boolean,String],required:!1,default:!0},gridTextColor:{type:String,required:!1,default:"#888"},gridTextSize:{type:[Number,String],required:!1,default:12},gridTextFamily:{type:String,required:!1,default:"sans-serif"},gridTextWeight:{type:String,required:!1,default:"normal"},colors:{type:[String,Array],required:!1},formatter:{type:Function,required:!1},lineColors:{type:[String,Array,Function],required:!1},xLabels:{type:String,required:!1},lineWidth:{type:[Number,String],required:!1},pointSize:{type:[Number,String],required:!1},pointFillColors:{type:[String,Array],required:!1},pointStrokeColors:{type:[String,Array],required:!1},ymax:{type:String,required:!1},ymin:{type:String,required:!1},smooth:{type:[Boolean,String],required:!1,default:!0},parseTime:{type:[Boolean,String],required:!1,default:!0},postUnits:{type:String,required:!1},preUnits:{type:String,required:!1},dateFormat:{type:Function,required:!1},xLabelFormat:{type:Function,required:!1},yLabelFormat:{type:Function,required:!1},xLabelAngle:{type:String,required:!1},goals:{type:[String,Array],required:!1},goalStrokeWidth:{type:[Number,String],required:!1},goalLineColors:{type:[String,Array],required:!1},events:{type:[String,Array],required:!1},eventStrokeWidth:{type:String,required:!1},eventLineColors:{type:[String,Array],required:!1},fillOpacity:{type:String,required:!1},behaveLikeLine:{type:[Boolean,String],required:!1,default:!1}},x={id:v.id,data:v.data,barColors:v.barColors,xkey:v.xkey,ykeys:v.ykeys,labels:v.labels,xLabelFormat:v.xLabelFormat,yLabelFormat:v.yLabelFormat,xLabelAngle:v.xLabelAngle,hoverCallback:v.hoverCallback,grid:v.grid,horizontal:v.horizontal,axes:v.axes,hideHover:v.hideHover,stacked:v.stacked,resize:v.resize,ymax:v.ymax,ymin:v.ymin,gridTextColor:v.gridTextColor,gridTextSize:v.gridTextSize,gridTextFamily:v.gridTextFamily,gridTextWeight:v.gridTextWeight},b={id:v.id,data:v.data,colors:v.colors,formatter:v.formatter,resize:v.resize},w={id:v.id,data:v.data,resize:v.resize,lineColors:v.lineColors,xkey:v.xkey,ykeys:v.ykeys,labels:v.labels,xLabels:v.xLabels,grid:v.grid,gridTextColor:v.gridTextColor,gridTextSize:v.gridTextSize,gridTextFamily:v.gridTextFamily,gridTextWeight:v.gridTextWeight,lineWidth:v.lineWidth,pointSize:v.pointSize,pointFillColors:v.pointFillColors,pointStrokeColors:v.pointStrokeColors,ymax:v.ymax,ymin:v.ymin,smooth:v.smooth,hideHover:v.hideHover,parseTime:v.parseTime,postUnits:v.postUnits,preUnits:v.preUnits,dateFormat:v.dateFormat,xLabelFormat:v.xLabelFormat,yLabelFormat:v.yLabelFormat,xLabelAngle:v.xLabelAngle,goals:v.goals,goalStrokeWidth:v.goalStrokeWidth,goalLineColors:v.goalLineColors,events:v.events,eventStrokeWidth:v.eventStrokeWidth,eventLineColors:v.eventLineColors,fillOpacity:v.fillOpacity,hoverCallback:v.hoverCallback},k={behaveLikeLine:v.behaveLikeLine};for(var S in w)w.hasOwnProperty(S)&&(k[S]=w[S]);var L={addOption:function(t,e){this[t]&&(e[t]=this[t])},addOptionAsObject:function(t,e){this[t]&&(e[t]=m.toObject(this[t]))}};const C={bar:{props:x,methods:L},donut:{props:b,methods:L},line:{props:w,methods:L},area:{props:k,methods:L}};var F=["id"];const M=Object.assign({name:"AreaChart"},{__name:"area-chart-new",props:C.area.props,setup:function(e,i){var o=i.expose,r=e,n=(0,t.ref)(null);(0,t.watch)(r,(function(){(0,t.nextTick)((function(){n.value.options.labels=m.toObject(r.labels),n.value.options.xkey=r.xkey,n.value.options.ykeys=m.toObject(r.ykeys),r.lineColors&&(n.value.options.lineColors=m.toObject(r.lineColors)),n.value.setData(m.toObject(r))}))}));var s=function(t,e){r[t]&&(e[t]=m.toObject(r[t]))},a=function(t,e){r[t]&&(e[t]=r[t])};return(0,t.onMounted)((function(){var t={element:r.id,data:m.toObject(r.data),resize:m.toBoolean(r.resize),labels:m.toObject(r.labels),xkey:r.xkey,ykeys:m.toObject(r.ykeys),grid:m.toBoolean(r.grid),gridTextColor:r.gridTextColor,gridTextSize:m.toInt(r.gridTextSize),gridTextFamily:r.gridTextFamily,gridTextWeight:r.gridTextWeight,lineWidth:r.lineWidth,pointSize:r.pointSize,ymax:r.ymax,ymin:r.ymin,smooth:m.toBoolean(r.smooth),hideHover:r.hideHover,parseTime:m.toBoolean(r.parseTime),postUnits:r.postUnits,preUnits:r.preUnits,xLabelAngle:r.xLabelAngle,goalStrokeWidth:r.goalStrokeWidth,eventStrokeWidth:r.eventStrokeWidth,fillOpacity:r.fillOpacity,behaveLikeLine:r.behaveLikeLine};s("lineColors",t),a("xLabels",t),s("pointFillColors",t),s("pointStrokeColors",t),a("dateFormat",t),a("xLabelFormat",t),a("yLabelFormat",t),s("goals",t),s("goalLineColors",t),s("events",t),s("eventLineColors",t),a("hoverCallback",t),n.value=Morris.Area(t)})),o({chart:n}),function(e,i){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{id:e.id},null,8,F)}}}),T=M;var A=["id"];const z=Object.assign({name:"DonutChart"},{__name:"donut-chart-new",props:C.donut.props,setup:function(e,i){var o=i.expose,r=(0,t.getCurrentInstance)().proxy,n=(0,t.ref)(null),s=C.line.methods,a=s.addOption,h=s.addOptionAsObject;h=h.bind(r),a=a.bind(r);var l=e,p=function(){var t={element:l.id,data:m.toObject(l.data),resize:m.toBoolean(l.resize)};h("colors",t),a("formatter",t),n.value=Morris.Donut(t)};return(0,t.watch)(l,(function(e){(0,t.nextTick)((function(){e.data&&e.data.length>0&&!n.value&&p(),n.value&&(e.colors&&(n.value.options.colors=m.toObject(e.colors)),n.value.setData(m.toObject(e.data)))}))})),(0,t.onMounted)((function(){l.data&&l.data.length>0&&p()})),o({chart:n}),function(e,i){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{id:e.id},null,8,A)}}}),_=z;var O=["id"];const B=Object.assign({name:"BarChart"},{__name:"bar-chart-new",props:C.bar.props,setup:function(e,i){var o=i.expose,r=(0,t.ref)(null),n=C.line.methods,s=n.addOption,a=n.addOptionAsObject,h=e;return(0,t.watch)(h,(function(e){(0,t.nextTick)((function(){r.value.options.labels=m.toObject(e.labels),r.value.options.xkey=e.xkey,r.value.options.ykeys=m.toObject(e.ykeys),e.barColors&&(r.value.options.barColors=m.toObject(e.barColors)),r.value.setData(m.toObject(e.data))}))})),(0,t.onMounted)((function(){var e=(0,t.getCurrentInstance)().proxy;a=a.bind(e),s=s.bind(e);var i={element:h.id,data:m.toObject(h.data),labels:m.toObject(h.labels),resize:m.toBoolean(h.resize),xkey:h.xkey,ykeys:m.toObject(h.ykeys),axes:m.toBoolean(h.axes),ymax:h.ymax,ymin:h.ymin,hideHover:h.hideHover,horizontal:m.toBoolean(h.horizontal),stacked:m.toBoolean(h.stacked),grid:m.toBoolean(h.grid),gridTextColor:h.gridTextColor,gridTextSize:m.toInt(h.gridTextSize),gridTextFamily:h.gridTextFamily,gridTextWeight:h.gridTextWeight,xLabelAngle:h.xLabelAngle,lineWidth:h.lineWidth,pointSize:h.pointSize};a("barColors",i),s("xLabelFormat",i),s("yLabelFormat",i),s("hoverCallback",i),r.value=Morris.Bar(i)})),o({chart:r}),function(e,i){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{id:e.id},null,8,O)}}}),H=B;var I=["id"];const D=Object.assign({name:"LineChart"},{__name:"line-chart-new",props:C.line.props,setup:function(e,i){var o=i.expose,r=(0,t.getCurrentInstance)().proxy,n=(0,t.ref)(),s=C.line.methods,a=s.addOption,h=s.addOptionAsObject,l=e;return(0,t.watch)(l,(function(e){(0,t.nextTick)((function(){n.value.options.labels=m.toObject(e.labels),n.value.options.xkey=e.xkey,n.value.options.ykeys=m.toObject(e.ykeys),e.lineColors&&(n.value.options.lineColors=m.toObject(e.lineColors)),n.value.setData(m.toObject(e.data))}))})),(0,t.onMounted)((function(){h=h.bind(r),a=a.bind(r);var t={element:l.id,data:m.toObject(l.data),resize:m.toBoolean(l.resize),labels:m.toObject(l.labels),xkey:l.xkey,ykeys:m.toObject(l.ykeys),grid:m.toBoolean(l.grid),gridTextColor:l.gridTextColor,gridTextSize:m.toInt(l.gridTextSize),gridTextFamily:l.gridTextFamily,gridTextWeight:l.gridTextWeight,lineWidth:l.lineWidth,pointSize:l.pointSize,ymax:l.ymax,ymin:l.ymin,smooth:m.toBoolean(l.smooth),hideHover:l.hideHover,parseTime:m.toBoolean(l.parseTime),postUnits:l.postUnits,preUnits:l.preUnits,xLabelAngle:l.xLabelAngle,goalStrokeWidth:l.goalStrokeWidth,eventStrokeWidth:l.eventStrokeWidth,fillOpacity:l.fillOpacity,gridLineColor:l.gridLineColor};h("lineColors",t),a("xLabels",t),h("pointFillColors",t),h("pointStrokeColors",t),a("dateFormat",t),a("xLabelFormat",t),a("yLabelFormat",t),h("goals",t),h("goalLineColors",t),h("events",t),h("eventLineColors",t),a("hoverCallback",t),n.value=Morris.Line(t)})),o({chart:n}),function(e,i){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{id:e.id},null,8,I)}}}),W={AreaChart:T,DonutChart:_,BarChart:H,LineChart:D}})(),n=n.default})()));