|
|
|
(function(e){"use strict";function r(e){return e||e===0}function i(e){return typeof e==="undefined"}function s(e){return typeof e!=="undefined"}var t={version:"0.1.27"};var n={target:"c3-target",chart:"c3-chart",chartLine:"c3-chart-line",chartLines:"c3-chart-lines",chartBar:"c3-chart-bar",chartBars:"c3-chart-bars",chartText:"c3-chart-text",chartTexts:"c3-chart-texts",chartArc:"c3-chart-arc",chartArcs:"c3-chart-arcs",chartArcsTitle:"c3-chart-arcs-title",selectedCircle:"c3-selected-circle",selectedCircles:"c3-selected-circles",eventRect:"c3-event-rect",eventRects:"c3-event-rects",zoomRect:"c3-zoom-rect",brush:"c3-brush",focused:"c3-focused",region:"c3-region",regions:"c3-regions",tooltip:"c3-tooltip",tooltipName:"c3-tooltip-name",shape:"c3-shape",shapes:"c3-shapes",line:"c3-line",step:"c3-step",bar:"c3-bar",bars:"c3-bars",circle:"c3-circle",circles:"c3-circles",arc:"c3-arc",area:"c3-area",text:"c3-text",texts:"c3-texts",grid:"c3-grid",xgrid:"c3-xgrid",xgrids:"c3-xgrids",xgridLine:"c3-xgrid-line",xgridLines:"c3-xgrid-lines",xgridFocus:"c3-xgrid-focus",ygrid:"c3-ygrid",ygrids:"c3-ygrids",ygridLine:"c3-ygrid-line",ygridLines:"c3-ygrid-lines",axisX:"c3-axis-x",axisXLabel:"c3-axis-x-label",axisY:"c3-axis-y",axisYLabel:"c3-axis-y-label",axisY2:"c3-axis-y2",axisY2Label:"c3-axis-y2-label",legendItem:"c3-legend-item",legendItemEvent:"c3-legend-item-event",legendItemTile:"c3-legend-item-tile",dragarea:"c3-dragarea",EXPANDED:"_expanded_",SELECTED:"_selected_",INCLUDED:"_included_"};t.generate=function(t){function f(e,n){if(!(e in t)){throw Error(n)}}function l(e,n){var r=t,i,s,o;for(i=0;i<e.length;i++){if(typeof r==="object"&&!(e[i]in r)){return n}s=i===e.length-1;o=r[e[i]];if(!s&&typeof o!=="object"||s&&typeof n!=="object"&&typeof o==="object"&&o!==null){return n}r=o}return r}function br(e){return"url("+document.URL.split("#")[0]+"#"+e+")"}function wr(){na.attr("transform",dr.main);na.select("."+n.axisX).attr("transform",dr.x);na.select("."+n.axisY).attr("transform",dr.y);na.select("."+n.axisY2).attr("transform",dr.y2);na.select("."+n.chartArcs).attr("transform",dr.arc)}function Er(){if(V){ra.attr("transform",dr.context);ra.select("."+n.axisX).attr("transform",dr.subx)}}function Sr(e){var t=e!==false?250:0;if(Q){ia.transition().duration(t).attr("transform",dr.legend)}}function xr(e){wr(e);Er(e);Sr(e)}function kr(){Hn=Or();Bn=Mr();jn=ti();Fn=ei();Ln={top:et?Hr("y2"):Cr,right:Dr(),bottom:Hr(et?"y":"x")+(et?0:$)+(vr?0:jn),left:(et?$+Nr:0)+_r()};Mn=Hn-Ln.left-Ln.right;Dn=Bn-Ln.top-Ln.bottom;if(Mn<0){Mn=0}if(Dn<0){Dn=0}An={top:et?Ln.top:Bn-$-(vr?0:jn),right:NaN,bottom:20+(vr?0:jn),left:et?Tr:Ln.left};_n=et?Ln.left-Tr-Nr:Mn;Pn=et?Dn:Bn-An.top-An.bottom;if(_n<0){_n=0}if(Pn<0){Pn=0}On={top:vr?0:Bn-jn,right:NaN,bottom:0,left:vr?Hn-Fn:0};Lr();if(vr&&iu(u.data.targets)){On.left=Mn/2+qn}}function Lr(){qn=Dn/2;In=qn*.95;Rn=ru(u.data.targets)?In*.6:0}function Ar(){var e=et?n.axisX:n.axisY,t=o.select("."+e).node(),r=t?t.getBoundingClientRect():{right:0},i=o.select(c).node().getBoundingClientRect(),s=r.right-i.left-_r();return s>0?s:0}function Or(){return h?h:Br()}function Mr(){var e=p?p:jr();return e>0?e:320}function _r(){if(iu(u.data.targets)){return 0}else if(d){return d}else{return et||!pt||yt?1:Pr("y")}}function Dr(){var e=1;if(iu(u.data.targets)){return 0}else if(v){return v}else if(vr){return Fn+(St&&!et?Pr("y2"):e)}else if(St){return kt||et?e:Pr("y2")}else{return e}}function Pr(e){var t=bi(e);return t.isInner?20+Fi(e):40+Fi(e)}function Hr(e){if(e==="y"&&!pt){return Q&&!vr?10:1}if(e==="y2"&&!St){return Cr}return(bi(e).isInner?30:40)+(e==="y2"?-10:0)}function Br(){return+o.select(c).style("width").replace("px","")}function jr(){return+o.select(c).style("height").replace("px","")}function Fr(e){return e?-(1+4):-(Ln.left-1)}function Ir(e){return e?-20:-1}function qr(){return Fr(!et)}function Rr(){return Ir(!et)}function Ur(){return Fr(et)}function zr(){return Ir(et)}function Wr(e){return e?Mn+2+4:Ln.left+20}function Xr(e){return e?80:Dn+2}function Vr(){return Wr(!et)}function $r(){return Xr(!et)}function Jr(){return Wr(et)}function Kr(){return
|