@carbon/charts-vue 1.7.4 → 1.7.6
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/CHANGELOG.md +8 -0
- package/charts-vue.common.js +21 -16
- package/charts-vue.common.js.map +1 -1
- package/charts-vue.umd.js +21 -16
- package/charts-vue.umd.js.map +1 -1
- package/charts-vue.umd.min.js +1 -1
- package/charts-vue.umd.min.js.map +1 -1
- package/package.json +2 -2
package/charts-vue.umd.min.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["charts-vue"]=e():t["charts-vue"]=e()})("undefined"!==typeof self?self:this,(function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="1c25")}({"01ff":function(t,e,n){"use strict";(function(t){var r=n("92ae"),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i,s=a&&r["a"].process,u=function(){try{var t=o&&o.require&&o.require("util").types;return t||s&&s.binding&&s.binding("util")}catch(e){}}();e["a"]=u}).call(this,n("7326")(t))},"0481":function(t,e,n){var r=n("b495");t.exports=function(t){return r(t.length)}},"083f":function(t,e,n){var r=n("b546"),i=n("7526"),o=n("cfd1"),a=n("60de"),s=n("eba0"),u=n("7d53"),l=TypeError,c=u("toPrimitive");t.exports=function(t,e){if(!i(t)||o(t))return t;var n,u=a(t,c);if(u){if(void 0===e&&(e="default"),n=r(u,t,e),!i(n)||o(n))return n;throw l("Can't convert object to primitive value")}return void 0===e&&(e="number"),s(t,e)}},"0c47":function(t,e,n){var r=n("c91c"),i=n("b17e");t.exports=Object.keys||function(t){return r(t,i)}},"0e93":function(t,e){t.exports=!1},"157c":function(t,e,n){var r=n("7526"),i=String,o=TypeError;t.exports=function(t){if(r(t))return t;throw o(i(t)+" is not an object")}},"185a":function(t,e,n){var r=n("d4cb"),i=n("b546"),o=n("e129"),a=n("9618"),s=n("378c"),u=n("feca"),l=n("7a25"),c=n("7c3f"),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=s(t),e=u(e),c)try{return h(t,e)}catch(n){}if(l(t,e))return a(!i(o.f,t,e),t[e])}},"1c25":function(t,e,n){"use strict";n.r(e),n.d(e,"CcvAreaChart",(function(){return pH})),n.d(e,"CcvStackedAreaChart",(function(){return _H})),n.d(e,"CcvSimpleBarChart",(function(){return TH})),n.d(e,"CcvGroupedBarChart",(function(){return DH})),n.d(e,"CcvStackedBarChart",(function(){return jH})),n.d(e,"CcvBoxplotChart",(function(){return zH})),n.d(e,"CcvBubbleChart",(function(){return ZH})),n.d(e,"CcvBulletChart",(function(){return eG})),n.d(e,"CcvDonutChart",(function(){return sG})),n.d(e,"CcvGaugeChart",(function(){return pG})),n.d(e,"CcvHistogramChart",(function(){return _G})),n.d(e,"CcvLineChart",(function(){return TG})),n.d(e,"CcvLollipopChart",(function(){return DG})),n.d(e,"CcvPieChart",(function(){return jG})),n.d(e,"CcvScatterChart",(function(){return zG})),n.d(e,"CcvMeterChart",(function(){return ZG})),n.d(e,"CcvRadarChart",(function(){return ez})),n.d(e,"CcvComboChart",(function(){return sz})),n.d(e,"CcvTreeChart",(function(){return pz})),n.d(e,"CcvTreemapChart",(function(){return _z})),n.d(e,"CcvCirclePackChart",(function(){return Tz})),n.d(e,"CcvWordCloudChart",(function(){return Dz})),n.d(e,"CcvAlluvialChart",(function(){return jz})),n.d(e,"CcvHeatmapChart",(function(){return zz}));var r={};n.r(r),n.d(r,"Chart",(function(){return s})),n.d(r,"Modal",(function(){return u})),n.d(r,"Model",(function(){return l})),n.d(r,"Toolbar",(function(){return c})),n.d(r,"ZoomBar",(function(){return h})),n.d(r,"ZoomDomain",(function(){return f})),n.d(r,"CanvasZoom",(function(){return p})),n.d(r,"Axis",(function(){return d})),n.d(r,"Area",(function(){return v})),n.d(r,"WordCloud",(function(){return g})),n.d(r,"Pie",(function(){return m})),n.d(r,"Gauge",(function(){return y})),n.d(r,"Bar",(function(){return _})),n.d(r,"Boxplot",(function(){return b})),n.d(r,"Scatter",(function(){return w})),n.d(r,"Line",(function(){return O})),n.d(r,"Radar",(function(){return x})),n.d(r,"Tree",(function(){return E})),n.d(r,"Treemap",(function(){return T})),n.d(r,"Tooltip",(function(){return S})),n.d(r,"Threshold",(function(){return M})),n.d(r,"Legend",(function(){return C})),n.d(r,"CirclePack",(function(){return A})),n.d(r,"Alluvial",(function(){return L})),n.d(r,"Meter",(function(){return D})),n.d(r,"Heatmap",(function(){return k}));var i,o={};(n.r(o),n.d(o,"grid",(function(){return Vd})),n.d(o,"ruler",(function(){return Hd})),n.d(o,"baseTooltip",(function(){return Gd})),n.d(o,"timeScale",(function(){return Fd})),n.d(o,"options",(function(){return bv})),n.d(o,"carbonPrefix",(function(){return dt})),n.d(o,"area",(function(){return vt})),n.d(o,"axis",(function(){return gt})),n.d(o,"canvasZoomSettings",(function(){return mt})),n.d(o,"circlePack",(function(){return yt})),n.d(o,"color",(function(){return _t})),n.d(o,"boxplot",(function(){return bt})),n.d(o,"histogram",(function(){return wt})),n.d(o,"legend",(function(){return Ot})),n.d(o,"lines",(function(){return xt})),n.d(o,"meter",(function(){return Et})),n.d(o,"pie",(function(){return Tt})),n.d(o,"radar",(function(){return St})),n.d(o,"alluvial",(function(){return Mt})),n.d(o,"heatmap",(function(){return Ct})),n.d(o,"spacers",(function(){return At})),n.d(o,"tooltips",(function(){return Lt})),n.d(o,"transitions",(function(){return Dt})),n.d(o,"toolbar",(function(){return kt})),n.d(o,"zoomBar",(function(){return Pt})),n.d(o,"defaultLegendAdditionalItems",(function(){return Rt})),"undefined"!==typeof window)&&(n("4141"),(i=window.document.currentScript)&&(i=i.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(n.p=i[1]));n("868d"),n("8d0d"),n("c78b");var a,s,u,l,c,h,f,p,d,v,g,m,y,_,b,w,O,x,E,T,S,M,C,A,L,D,k,P=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-area-chart"})},R=[];(function(t){t["GRAPHICS_DOCUMENT"]="graphics-document",t["GRAPHICS_OBJECT"]="graphics-object",t["GRAPHICS_SYMBOL"]="graphics-symbol",t["GROUP"]="group",t["DOCUMENT"]="document",t["CHECKBOX"]="checkbox",t["BUTTON"]="button",t["MENU"]="menu",t["MENU_ITEM"]="menuitem",t["IMG"]="img"})(a||(a={})),function(t){t["RENDER_FINISHED"]="render-finished",t["RESIZE"]="chart-resize",t["MOUSEOVER"]="chart-mouseover",t["MOUSEOUT"]="chart-mouseout"}(s||(s={})),function(t){t["SHOW"]="show-modal",t["HIDE"]="hide-modal"}(u||(u={})),function(t){t["UPDATE"]="model-update"}(l||(l={})),function(t){t["SHOW_OVERFLOW_MENU"]="show-toolbar-overflow-menu",t["HIDE_OVERFLOW_MENU"]="hide-toolbar-overflow-menu",t["BUTTON_CLICK"]="toolbar-button-click"}(c||(c={})),function(t){t["UPDATE"]="zoom-bar-update",t["SELECTION_START"]="zoom-bar-selection-start",t["SELECTION_IN_PROGRESS"]="zoom-bar-selection-in-progress",t["SELECTION_END"]="zoom-bar-selection-end"}(h||(h={})),function(t){t["CHANGE"]="zoom-domain-change"}(f||(f={})),function(t){t["CANVAS_ZOOM_IN"]="canvas-zoom-in",t["CANVAS_ZOOM_OUT"]="canvas-zoom-out"}(p||(p={})),function(t){t["LABEL_MOUSEOVER"]="axis-label-mouseover",t["LABEL_MOUSEMOVE"]="axis-label-mousemove",t["LABEL_CLICK"]="axis-label-click",t["LABEL_MOUSEOUT"]="axis-label-mouseout",t["LABEL_FOCUS"]="axis-label-focus",t["LABEL_BLUR"]="axis-label-blur",t["RENDER_COMPLETE"]="axis-render-complete"}(d||(d={})),function(t){t["POINT_MOUSEOVER"]="scatter-mouseover",t["POINT_MOUSEMOVE"]="scatter-mousemove",t["POINT_CLICK"]="scatter-click",t["POINT_MOUSEOUT"]="scatter-mouseout"}(v||(v={})),function(t){t["WORD_MOUSEOVER"]="wordcloud-word-mouseover",t["WORD_MOUSEMOVE"]="wordcloud-word-mousemove",t["WORD_CLICK"]="wordcloud-word-click",t["WORD_MOUSEOUT"]="wordcloud-word-mouseout"}(g||(g={})),function(t){t["SLICE_MOUSEOVER"]="pie-slice-mouseover",t["SLICE_MOUSEMOVE"]="pie-slice-mousemove",t["SLICE_CLICK"]="pie-slice-click",t["SLICE_MOUSEOUT"]="pie-slice-mouseout"}(m||(m={})),function(t){t["ARC_MOUSEOVER"]="gauge-arc-mouseover",t["ARC_MOUSEMOVE"]="gauge-arc-mousemove",t["ARC_CLICK"]="gauge-arc-click",t["ARC_MOUSEOUT"]="gauge-arc-mouseout"}(y||(y={})),function(t){t["BAR_MOUSEOVER"]="bar-mouseover",t["BAR_MOUSEMOVE"]="bar-mousemove",t["BAR_CLICK"]="bar-click",t["BAR_MOUSEOUT"]="bar-mouseout"}(_||(_={})),function(t){t["BOX_MOUSEOVER"]="box-mouseover",t["BOX_MOUSEMOVE"]="box-mousemove",t["BOX_CLICK"]="box-click",t["BOX_MOUSEOUT"]="box-mouseout",t["OUTLIER_MOUSEOVER"]="outlier-mouseover",t["OUTLIER_MOUSEMOVE"]="outlier-mousemove",t["OUTLIER_CLICK"]="outlier-click",t["OUTLIER_MOUSEOUT"]="outlier-mouseout"}(b||(b={})),function(t){t["SCATTER_MOUSEOVER"]="scatter-mouseover",t["SCATTER_MOUSEMOVE"]="scatter-mousemove",t["SCATTER_CLICK"]="scatter-click",t["SCATTER_MOUSEOUT"]="scatter-mouseout"}(w||(w={})),function(t){t["POINT_MOUSEOVER"]="scatter-mouseover",t["POINT_MOUSEMOVE"]="scatter-mousemove",t["POINT_CLICK"]="scatter-click",t["POINT_MOUSEOUT"]="scatter-mouseout"}(O||(O={})),function(t){t["X_AXIS_MOUSEOVER"]="radar-x-axis-mouseover",t["X_AXIS_MOUSEMOVE"]="radar-x-axis-mousemove",t["X_AXIS_CLICK"]="radar-x-axis-click",t["X_AXIS_MOUSEOUT"]="radar-x-axis-mouseout"}(x||(x={})),function(t){t["NODE_MOUSEOVER"]="tree-node-mouseover",t["NODE_CLICK"]="tree-node-click",t["NODE_MOUSEOUT"]="tree-node-mouseout"}(E||(E={})),function(t){t["LEAF_MOUSEOVER"]="leaf-mouseover",t["LEAF_MOUSEMOVE"]="leaf-mousemove",t["LEAF_CLICK"]="leaf-click",t["LEAF_MOUSEOUT"]="leaf-mouseout"}(T||(T={})),function(t){t["SHOW"]="show-tooltip",t["MOVE"]="move-tooltip",t["HIDE"]="hide-tooltip"}(S||(S={})),function(t){t["SHOW"]="show-threshold",t["HIDE"]="hide-threshold"}(M||(M={})),function(t){t["ITEM_HOVER"]="legend-item-onhover",t["ITEM_CLICK"]="legend-item-onclick",t["ITEM_MOUSEOUT"]="legend-item-onmouseout",t["ITEMS_UPDATE"]="legend-items-update"}(C||(C={})),function(t){t["CIRCLE_MOUSEOVER"]="circle-leaf-mouseover",t["CIRCLE_CLICK"]="circle-leaf-click",t["CIRCLE_MOUSEOUT"]="circle-leaf-mouseout",t["CIRCLE_MOUSEMOVE"]="circle-leaf-mousemove"}(A||(A={})),function(t){t["NODE_MOUSEOVER"]="alluvial-node-mouseover",t["NODE_CLICK"]="alluvial-node-click",t["NODE_MOUSEOUT"]="alluvial-node-mouseout",t["NODE_MOUSEMOVE"]="alluvial-node-mousemove",t["LINE_MOUSEOVER"]="alluvial-line-mouseover",t["LINE_CLICK"]="alluvial-line-click",t["LINE_MOUSEOUT"]="alluvial-line-mouseout",t["LINE_MOUSEMOVE"]="alluvial-line-mousemove"}(L||(L={})),function(t){t["METER_MOUSEOVER"]="meter-mouseover",t["METER_CLICK"]="meter-click",t["METER_MOUSEOUT"]="meter-mouseout",t["METER_MOUSEMOVE"]="meter-mousemove"}(D||(D={})),function(t){t["HEATMAP_MOUSEOVER"]="heatmap-mouseover",t["HEATMAP_CLICK"]="heatmap-click",t["HEATMAP_MOUSEOUT"]="heatmap-mouseout",t["HEATMAP_MOUSEMOVE"]="hetmap-mousemove"}(k||(k={}));var I,N,j,B,U,V,H,G,z,F,W,q,$,Y,Z,X,K,Q,J,tt,et,nt,rt,it,ot,at,st,ut,lt,ct,ht,ft=r;function pt(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}(function(t){t["HTML"]="html",t["SVG"]="svg"})(I||(I={})),function(t){t["WHITE"]="white",t["G100"]="g100",t["G90"]="g90",t["G10"]="g10"}(N||(N={})),function(t){t["BACKGROUND"]="background",t["FILL"]="fill",t["STROKE"]="stroke",t["TOOLTIP"]="tooltip"}(j||(j={})),function(t){t["LEFT"]="left",t["RIGHT"]="right",t["TOP"]="top",t["BOTTOM"]="bottom"}(B||(B={})),function(t){t["GRAPH_VIEW"]="graph_view",t["SLIDER_VIEW"]="slider_view"}(U||(U={})),function(t){t["END_LINE"]="end_line",t["MID_LINE"]="mid_line",t["FRONT_LINE"]="front_line",t["NONE"]="none"}(V||(V={})),function(t){t["VERTICAL"]="vertical",t["HORIZONTAL"]="horizontal"}(H||(H={})),function(t){t["TIME"]="time",t["LINEAR"]="linear",t["LOG"]="log",t["LABELS"]="labels",t["LABELS_RATIO"]="labels-ratio"}(G||(G={})),function(t){t["RIGHT"]="right",t["LEFT"]="left",t["TOP"]="top",t["BOTTOM"]="bottom"}(z||(z={})),function(t){t["LEFT"]="left",t["CENTER"]="center",t["RIGHT"]="right"}(F||(F={})),function(t){t["HORIZONTAL"]="horizontal",t["VERTICAL"]="vertical"}(W||(W={})),function(t){t["TREE"]="tree",t["DENDROGRAM"]="dendrogram"}(q||(q={})),function(t){t["ROW"]="row",t["COLUMN"]="column",t["ROW_REVERSE"]="row-reverse",t["COLUMN_REVERSE"]="column-reverse"}($||($={})),function(t){t["FIXED"]="fixed",t["PREFERRED"]="preferred",t["STRETCH"]="stretch"}(Y||(Y={})),function(t){t["CENTER"]="center"}(Z||(Z={})),function(t){t["LEFT"]="left",t["RIGHT"]="right"}(X||(X={})),function(t){t["GRID"]="grid",t["VERT_OR_HORIZ"]="vertOrHoriz",t["PIE"]="pie",t["DONUT"]="donut"}(K||(K={})),function(t){t["START"]="start",t["MIDDLE"]="middle",t["END"]="end"}(Q||(Q={})),function(t){t["BASELINE"]="baseline",t["MIDDLE"]="middle",t["HANGING"]="hanging"}(J||(J={})),function(t){t["SEMI"]="semi",t["FULL"]="full"}(tt||(tt={})),function(t){t["UP"]="up",t["DOWN"]="down"}(et||(et={})),function(t){t["SUCCESS"]="success",t["WARNING"]="warning",t["DANGER"]="danger"}(nt||(nt={})),function(t){t["ALWAYS"]="always",t["AUTO"]="auto",t["NEVER"]="never"}(rt||(rt={})),function(t){t["SCATTER"]="scatter",t["LINE"]="line",t["SIMPLE_BAR"]="simple-bar",t["STACKED_BAR"]="stacked-bar",t["GROUPED_BAR"]="grouped-bar",t["AREA"]="area",t["STACKED_AREA"]="stacked-area"}(it||(it={})),function(t){t["EXPORT_CSV"]="Export as CSV",t["EXPORT_PNG"]="Export as PNG",t["EXPORT_JPG"]="Export as JPG",t["ZOOM_IN"]="Zoom in",t["ZOOM_OUT"]="Zoom out",t["RESET_ZOOM"]="Reset zoom",t["MAKE_FULLSCREEN"]="Make fullscreen",t["SHOW_AS_DATATABLE"]="Show as data-table",t["CUSTOM"]="Custom"}(ot||(ot={})),function(t){t["LEFT"]="left",t["RIGHT"]="right"}(at||(at={})),function(t){t["CHECKBOX"]="checkbox",t["RADIUS"]="radius",t["AREA"]="area",t["SIZE"]="size",t["LINE"]="line",t["QUARTILE"]="quartile",t["ZOOM"]="zoom"}(st||(st={})),function(t){t["LINEAR"]="linear",t["QUANTIZE"]="quantize"}(ut||(ut={})),function(t){t["ON"]="on",t["AUTO"]="auto",t["OFF"]="off"}(lt||(lt={})),function(t){t["DEFAULT"]="default",t["HOVERABLE"]="hoverable"}(ct||(ct={}));var dt="cds",vt={opacity:{unselected:.05,selected:.4}},gt={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1,hover:{rectanglePadding:4}},mt={duration:1e3,ease:pt,zoomLevel:3},yt={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},_t={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},bt={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},wt={defaultBins:10},Ot={items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8,spaceAfter:4},checkbox:{radius:6.5},radius:{iconData:[{cx:7,cy:7,r:6.5},{cx:7,cy:10,r:3.5}],fill:null,stroke:"#8c8c8c"},line:{yPosition:6,width:24,strokeWidth:1.4,fill:null,stroke:"#999999"},area:{width:24,height:14,fill:"#6f6f6f",stroke:null},size:{iconData:[{width:23,height:12},{width:13,height:6}],fill:null,stroke:"#8D8D8D"},quartile:{iconData:[{x:0,y:0,width:24,height:13},{x:11,y:4,width:1,height:4}]},zoom:{iconData:[{x:0,y:0,width:12,height:12}],color:"#8D8D8D"},color:{barWidth:300,barHeight:8,axisYTranslation:10}},xt={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},Et={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15},total:{paddingLeft:36,paddingRight:24},height:{default:8,proportional:16},dividerWidth:2},Tt={radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2}},St={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},Mt={nodeWidth:4,nodeHoveredWidth:8,minNodePadding:24,opacity:{unfocus:.3,default:.8,selected:1}},Ct={minCellDividerDimension:16,chartPadding:.5},At={default:{size:24}},Lt={horizontalOffset:10},Dt={default:{duration:300},pie_slice_mouseover:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},kt={buttonSize:32,iconSize:20,height:32,spacerHeight:10,iconPadding:6},Pt={height:(ht={},ht[U.GRAPH_VIEW]=32,ht[U.SLIDER_VIEW]=10,ht),spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},Rt=[{type:st.RADIUS,name:"Radius"},{type:st.AREA,name:"Poor area"},{type:st.AREA,name:"Satisfactory area"},{type:st.AREA,name:"Great area"},{type:st.QUARTILE,name:"Quartiles"}];function It(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Nt=It,jt=n("7f0d"),Bt=function(){return jt["a"].Date.now()},Ut=Bt,Vt=/\s/;function Ht(t){var e=t.length;while(e--&&Vt.test(t.charAt(e)));return e}var Gt=Ht,zt=/^\s+/;function Ft(t){return t?t.slice(0,Gt(t)+1).replace(zt,""):t}var Wt=Ft,qt=jt["a"].Symbol,$t=qt,Yt=Object.prototype,Zt=Yt.hasOwnProperty,Xt=Yt.toString,Kt=$t?$t.toStringTag:void 0;function Qt(t){var e=Zt.call(t,Kt),n=t[Kt];try{t[Kt]=void 0;var r=!0}catch(o){}var i=Xt.call(t);return r&&(e?t[Kt]=n:delete t[Kt]),i}var Jt=Qt,te=Object.prototype,ee=te.toString;function ne(t){return ee.call(t)}var re=ne,ie="[object Null]",oe="[object Undefined]",ae=$t?$t.toStringTag:void 0;function se(t){return null==t?void 0===t?oe:ie:ae&&ae in Object(t)?Jt(t):re(t)}var ue=se;function le(t){return null!=t&&"object"==typeof t}var ce=le,he="[object Symbol]";function fe(t){return"symbol"==typeof t||ce(t)&&ue(t)==he}var pe=fe,de=NaN,ve=/^[-+]0x[0-9a-f]+$/i,ge=/^0b[01]+$/i,me=/^0o[0-7]+$/i,ye=parseInt;function _e(t){if("number"==typeof t)return t;if(pe(t))return de;if(Nt(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Nt(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Wt(t);var n=ge.test(t);return n||me.test(t)?ye(t.slice(2),n?2:8):ve.test(t)?de:+t}var be=_e,we="Expected a function",Oe=Math.max,xe=Math.min;function Ee(t,e,n){var r,i,o,a,s,u,l=0,c=!1,h=!1,f=!0;if("function"!=typeof t)throw new TypeError(we);function p(e){var n=r,o=i;return r=i=void 0,l=e,a=t.apply(o,n),a}function d(t){return l=t,s=setTimeout(m,e),c?p(t):a}function v(t){var n=t-u,r=t-l,i=e-n;return h?xe(i,o-r):i}function g(t){var n=t-u,r=t-l;return void 0===u||n>=e||n<0||h&&r>=o}function m(){var t=Ut();if(g(t))return y(t);s=setTimeout(m,v(t))}function y(t){return s=void 0,f&&r?p(t):(r=i=void 0,a)}function _(){void 0!==s&&clearTimeout(s),l=0,r=u=i=s=void 0}function b(){return void 0===s?a:y(Ut())}function w(){var t=Ut(),n=g(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return d(u);if(h)return clearTimeout(s),s=setTimeout(m,e),p(u)}return void 0===s&&(s=setTimeout(m,e)),a}return e=be(e)||0,Nt(n)&&(c=!!n.leading,h="maxWait"in n,o=h?Oe(be(n.maxWait)||0,e):o,f="trailing"in n?!!n.trailing:f),w.cancel=_,w.flush=b,w}var Te=Ee;function Se(){this.__data__=[],this.size=0}var Me=Se;function Ce(t,e){return t===e||t!==t&&e!==e}var Ae=Ce;function Le(t,e){var n=t.length;while(n--)if(Ae(t[n][0],e))return n;return-1}var De=Le,ke=Array.prototype,Pe=ke.splice;function Re(t){var e=this.__data__,n=De(e,t);if(n<0)return!1;var r=e.length-1;return n==r?e.pop():Pe.call(e,n,1),--this.size,!0}var Ie=Re;function Ne(t){var e=this.__data__,n=De(e,t);return n<0?void 0:e[n][1]}var je=Ne;function Be(t){return De(this.__data__,t)>-1}var Ue=Be;function Ve(t,e){var n=this.__data__,r=De(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}var He=Ve;function Ge(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}Ge.prototype.clear=Me,Ge.prototype["delete"]=Ie,Ge.prototype.get=je,Ge.prototype.has=Ue,Ge.prototype.set=He;var ze=Ge;function Fe(){this.__data__=new ze,this.size=0}var We=Fe;function qe(t){var e=this.__data__,n=e["delete"](t);return this.size=e.size,n}var $e=qe;function Ye(t){return this.__data__.get(t)}var Ze=Ye;function Xe(t){return this.__data__.has(t)}var Ke=Xe,Qe="[object AsyncFunction]",Je="[object Function]",tn="[object GeneratorFunction]",en="[object Proxy]";function nn(t){if(!Nt(t))return!1;var e=ue(t);return e==Je||e==tn||e==Qe||e==en}var rn=nn,on=jt["a"]["__core-js_shared__"],an=on,sn=function(){var t=/[^.]+$/.exec(an&&an.keys&&an.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function un(t){return!!sn&&sn in t}var ln=un,cn=Function.prototype,hn=cn.toString;function fn(t){if(null!=t){try{return hn.call(t)}catch(e){}try{return t+""}catch(e){}}return""}var pn=fn,dn=/[\\^$.*+?()[\]{}|]/g,vn=/^\[object .+?Constructor\]$/,gn=Function.prototype,mn=Object.prototype,yn=gn.toString,_n=mn.hasOwnProperty,bn=RegExp("^"+yn.call(_n).replace(dn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function wn(t){if(!Nt(t)||ln(t))return!1;var e=rn(t)?bn:vn;return e.test(pn(t))}var On=wn;function xn(t,e){return null==t?void 0:t[e]}var En=xn;function Tn(t,e){var n=En(t,e);return On(n)?n:void 0}var Sn=Tn,Mn=Sn(jt["a"],"Map"),Cn=Mn,An=Sn(Object,"create"),Ln=An;function Dn(){this.__data__=Ln?Ln(null):{},this.size=0}var kn=Dn;function Pn(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var Rn=Pn,In="__lodash_hash_undefined__",Nn=Object.prototype,jn=Nn.hasOwnProperty;function Bn(t){var e=this.__data__;if(Ln){var n=e[t];return n===In?void 0:n}return jn.call(e,t)?e[t]:void 0}var Un=Bn,Vn=Object.prototype,Hn=Vn.hasOwnProperty;function Gn(t){var e=this.__data__;return Ln?void 0!==e[t]:Hn.call(e,t)}var zn=Gn,Fn="__lodash_hash_undefined__";function Wn(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Ln&&void 0===e?Fn:e,this}var qn=Wn;function $n(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}$n.prototype.clear=kn,$n.prototype["delete"]=Rn,$n.prototype.get=Un,$n.prototype.has=zn,$n.prototype.set=qn;var Yn=$n;function Zn(){this.size=0,this.__data__={hash:new Yn,map:new(Cn||ze),string:new Yn}}var Xn=Zn;function Kn(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}var Qn=Kn;function Jn(t,e){var n=t.__data__;return Qn(e)?n["string"==typeof e?"string":"hash"]:n.map}var tr=Jn;function er(t){var e=tr(this,t)["delete"](t);return this.size-=e?1:0,e}var nr=er;function rr(t){return tr(this,t).get(t)}var ir=rr;function or(t){return tr(this,t).has(t)}var ar=or;function sr(t,e){var n=tr(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this}var ur=sr;function lr(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}lr.prototype.clear=Xn,lr.prototype["delete"]=nr,lr.prototype.get=ir,lr.prototype.has=ar,lr.prototype.set=ur;var cr=lr,hr=200;function fr(t,e){var n=this.__data__;if(n instanceof ze){var r=n.__data__;if(!Cn||r.length<hr-1)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new cr(r)}return n.set(t,e),this.size=n.size,this}var pr=fr;function dr(t){var e=this.__data__=new ze(t);this.size=e.size}dr.prototype.clear=We,dr.prototype["delete"]=$e,dr.prototype.get=Ze,dr.prototype.has=Ke,dr.prototype.set=pr;var vr=dr,gr=function(){try{var t=Sn(Object,"defineProperty");return t({},"",{}),t}catch(e){}}(),mr=gr;function yr(t,e,n){"__proto__"==e&&mr?mr(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}var _r=yr;function br(t,e,n){(void 0!==n&&!Ae(t[e],n)||void 0===n&&!(e in t))&&_r(t,e,n)}var wr=br;function Or(t){return function(e,n,r){var i=-1,o=Object(e),a=r(e),s=a.length;while(s--){var u=a[t?s:++i];if(!1===n(o[u],u,o))break}return e}}var xr=Or,Er=xr(),Tr=Er,Sr=n("d6f0"),Mr=jt["a"].Uint8Array,Cr=Mr;function Ar(t){var e=new t.constructor(t.byteLength);return new Cr(e).set(new Cr(t)),e}var Lr=Ar;function Dr(t,e){var n=e?Lr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}var kr=Dr;function Pr(t,e){var n=-1,r=t.length;e||(e=Array(r));while(++n<r)e[n]=t[n];return e}var Rr=Pr,Ir=Object.create,Nr=function(){function t(){}return function(e){if(!Nt(e))return{};if(Ir)return Ir(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}(),jr=Nr;function Br(t,e){return function(n){return t(e(n))}}var Ur=Br,Vr=Ur(Object.getPrototypeOf,Object),Hr=Vr,Gr=Object.prototype;function zr(t){var e=t&&t.constructor,n="function"==typeof e&&e.prototype||Gr;return t===n}var Fr=zr;function Wr(t){return"function"!=typeof t.constructor||Fr(t)?{}:jr(Hr(t))}var qr=Wr,$r="[object Arguments]";function Yr(t){return ce(t)&&ue(t)==$r}var Zr=Yr,Xr=Object.prototype,Kr=Xr.hasOwnProperty,Qr=Xr.propertyIsEnumerable,Jr=Zr(function(){return arguments}())?Zr:function(t){return ce(t)&&Kr.call(t,"callee")&&!Qr.call(t,"callee")},ti=Jr,ei=Array.isArray,ni=ei,ri=9007199254740991;function ii(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=ri}var oi=ii;function ai(t){return null!=t&&oi(t.length)&&!rn(t)}var si=ai;function ui(t){return ce(t)&&si(t)}var li=ui,ci=n("4cf0"),hi="[object Object]",fi=Function.prototype,pi=Object.prototype,di=fi.toString,vi=pi.hasOwnProperty,gi=di.call(Object);function mi(t){if(!ce(t)||ue(t)!=hi)return!1;var e=Hr(t);if(null===e)return!0;var n=vi.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&di.call(n)==gi}var yi=mi,_i="[object Arguments]",bi="[object Array]",wi="[object Boolean]",Oi="[object Date]",xi="[object Error]",Ei="[object Function]",Ti="[object Map]",Si="[object Number]",Mi="[object Object]",Ci="[object RegExp]",Ai="[object Set]",Li="[object String]",Di="[object WeakMap]",ki="[object ArrayBuffer]",Pi="[object DataView]",Ri="[object Float32Array]",Ii="[object Float64Array]",Ni="[object Int8Array]",ji="[object Int16Array]",Bi="[object Int32Array]",Ui="[object Uint8Array]",Vi="[object Uint8ClampedArray]",Hi="[object Uint16Array]",Gi="[object Uint32Array]",zi={};function Fi(t){return ce(t)&&oi(t.length)&&!!zi[ue(t)]}zi[Ri]=zi[Ii]=zi[Ni]=zi[ji]=zi[Bi]=zi[Ui]=zi[Vi]=zi[Hi]=zi[Gi]=!0,zi[_i]=zi[bi]=zi[ki]=zi[wi]=zi[Pi]=zi[Oi]=zi[xi]=zi[Ei]=zi[Ti]=zi[Si]=zi[Mi]=zi[Ci]=zi[Ai]=zi[Li]=zi[Di]=!1;var Wi=Fi;function qi(t){return function(e){return t(e)}}var $i=qi,Yi=n("01ff"),Zi=Yi["a"]&&Yi["a"].isTypedArray,Xi=Zi?$i(Zi):Wi,Ki=Xi;function Qi(t,e){if(("constructor"!==e||"function"!==typeof t[e])&&"__proto__"!=e)return t[e]}var Ji=Qi,to=Object.prototype,eo=to.hasOwnProperty;function no(t,e,n){var r=t[e];eo.call(t,e)&&Ae(r,n)&&(void 0!==n||e in t)||_r(t,e,n)}var ro=no;function io(t,e,n,r){var i=!n;n||(n={});var o=-1,a=e.length;while(++o<a){var s=e[o],u=r?r(n[s],t[s],s,n,t):void 0;void 0===u&&(u=t[s]),i?_r(n,s,u):ro(n,s,u)}return n}var oo=io;function ao(t,e){var n=-1,r=Array(t);while(++n<t)r[n]=e(n);return r}var so=ao,uo=9007199254740991,lo=/^(?:0|[1-9]\d*)$/;function co(t,e){var n=typeof t;return e=null==e?uo:e,!!e&&("number"==n||"symbol"!=n&&lo.test(t))&&t>-1&&t%1==0&&t<e}var ho=co,fo=Object.prototype,po=fo.hasOwnProperty;function vo(t,e){var n=ni(t),r=!n&&ti(t),i=!n&&!r&&Object(ci["a"])(t),o=!n&&!r&&!i&&Ki(t),a=n||r||i||o,s=a?so(t.length,String):[],u=s.length;for(var l in t)!e&&!po.call(t,l)||a&&("length"==l||i&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||ho(l,u))||s.push(l);return s}var go=vo;function mo(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}var yo=mo,_o=Object.prototype,bo=_o.hasOwnProperty;function wo(t){if(!Nt(t))return yo(t);var e=Fr(t),n=[];for(var r in t)("constructor"!=r||!e&&bo.call(t,r))&&n.push(r);return n}var Oo=wo;function xo(t){return si(t)?go(t,!0):Oo(t)}var Eo=xo;function To(t){return oo(t,Eo(t))}var So=To;function Mo(t,e,n,r,i,o,a){var s=Ji(t,n),u=Ji(e,n),l=a.get(u);if(l)wr(t,n,l);else{var c=o?o(s,u,n+"",t,e,a):void 0,h=void 0===c;if(h){var f=ni(u),p=!f&&Object(ci["a"])(u),d=!f&&!p&&Ki(u);c=u,f||p||d?ni(s)?c=s:li(s)?c=Rr(s):p?(h=!1,c=Object(Sr["a"])(u,!0)):d?(h=!1,c=kr(u,!0)):c=[]:yi(u)||ti(u)?(c=s,ti(s)?c=So(s):Nt(s)&&!rn(s)||(c=qr(u))):h=!1}h&&(a.set(u,c),i(c,u,r,o,a),a["delete"](u)),wr(t,n,c)}}var Co=Mo;function Ao(t,e,n,r,i){t!==e&&Tr(e,(function(o,a){if(i||(i=new vr),Nt(o))Co(t,e,a,n,Ao,r,i);else{var s=r?r(Ji(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),wr(t,a,s)}}),Eo)}var Lo=Ao;function Do(t){return t}var ko=Do;function Po(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}var Ro=Po,Io=Math.max;function No(t,e,n){return e=Io(void 0===e?t.length-1:e,0),function(){var r=arguments,i=-1,o=Io(r.length-e,0),a=Array(o);while(++i<o)a[i]=r[e+i];i=-1;var s=Array(e+1);while(++i<e)s[i]=r[i];return s[e]=n(a),Ro(t,this,s)}}var jo=No;function Bo(t){return function(){return t}}var Uo=Bo,Vo=mr?function(t,e){return mr(t,"toString",{configurable:!0,enumerable:!1,value:Uo(e),writable:!0})}:ko,Ho=Vo,Go=800,zo=16,Fo=Date.now;function Wo(t){var e=0,n=0;return function(){var r=Fo(),i=zo-(r-n);if(n=r,i>0){if(++e>=Go)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var qo=Wo,$o=qo(Ho),Yo=$o;function Zo(t,e){return Yo(jo(t,e,ko),t+"")}var Xo=Zo;function Ko(t,e,n){if(!Nt(n))return!1;var r=typeof e;return!!("number"==r?si(n)&&ho(e,n.length):"string"==r&&e in n)&&Ae(n[e],t)}var Qo=Ko;function Jo(t){return Xo((function(e,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;o=t.length>3&&"function"==typeof o?(i--,o):void 0,a&&Qo(n[0],n[1],a)&&(o=i<3?void 0:o,i=1),e=Object(e);while(++r<i){var s=n[r];s&&t(e,s,r,o)}return e}))}var ta=Jo,ea=ta((function(t,e,n){Lo(t,e,n)})),na=ea;function ra(t,e,n){return t===t&&(void 0!==n&&(t=t<=n?t:n),void 0!==e&&(t=t>=e?t:e)),t}var ia=ra;function oa(t,e,n){return void 0===n&&(n=e,e=void 0),void 0!==n&&(n=be(n),n=n===n?n:0),void 0!==e&&(e=be(e),e=e===e?e:0),ia(be(t),e,n)}var aa=oa;function sa(t,e){var n=-1,r=e.length,i=t.length;while(++n<r)t[i+n]=e[n];return t}var ua=sa,la=$t?$t.isConcatSpreadable:void 0;function ca(t){return ni(t)||ti(t)||!!(la&&t&&t[la])}var ha=ca;function fa(t,e,n,r,i){var o=-1,a=t.length;n||(n=ha),i||(i=[]);while(++o<a){var s=t[o];e>0&&n(s)?e>1?fa(s,e-1,n,r,i):ua(i,s):r||(i[i.length]=s)}return i}var pa=fa;function da(t){var e=null==t?0:t.length;return e?pa(t,1):[]}var va=da;function ga(t,e,n,r){var i=-1,o=null==t?0:t.length;while(++i<o){var a=t[i];e(r,a,n(a),t)}return r}var ma=ga,ya=Ur(Object.keys,Object),_a=ya,ba=Object.prototype,wa=ba.hasOwnProperty;function Oa(t){if(!Fr(t))return _a(t);var e=[];for(var n in Object(t))wa.call(t,n)&&"constructor"!=n&&e.push(n);return e}var xa=Oa;function Ea(t){return si(t)?go(t):xa(t)}var Ta=Ea;function Sa(t,e){return t&&Tr(t,e,Ta)}var Ma=Sa;function Ca(t,e){return function(n,r){if(null==n)return n;if(!si(n))return t(n,r);var i=n.length,o=e?i:-1,a=Object(n);while(e?o--:++o<i)if(!1===r(a[o],o,a))break;return n}}var Aa=Ca,La=Aa(Ma),Da=La;function ka(t,e,n,r){return Da(t,(function(t,i,o){e(r,t,n(t),o)})),r}var Pa=ka,Ra="__lodash_hash_undefined__";function Ia(t){return this.__data__.set(t,Ra),this}var Na=Ia;function ja(t){return this.__data__.has(t)}var Ba=ja;function Ua(t){var e=-1,n=null==t?0:t.length;this.__data__=new cr;while(++e<n)this.add(t[e])}Ua.prototype.add=Ua.prototype.push=Na,Ua.prototype.has=Ba;var Va=Ua;function Ha(t,e){var n=-1,r=null==t?0:t.length;while(++n<r)if(e(t[n],n,t))return!0;return!1}var Ga=Ha;function za(t,e){return t.has(e)}var Fa=za,Wa=1,qa=2;function $a(t,e,n,r,i,o){var a=n&Wa,s=t.length,u=e.length;if(s!=u&&!(a&&u>s))return!1;var l=o.get(t),c=o.get(e);if(l&&c)return l==e&&c==t;var h=-1,f=!0,p=n&qa?new Va:void 0;o.set(t,e),o.set(e,t);while(++h<s){var d=t[h],v=e[h];if(r)var g=a?r(v,d,h,e,t,o):r(d,v,h,t,e,o);if(void 0!==g){if(g)continue;f=!1;break}if(p){if(!Ga(e,(function(t,e){if(!Fa(p,e)&&(d===t||i(d,t,n,r,o)))return p.push(e)}))){f=!1;break}}else if(d!==v&&!i(d,v,n,r,o)){f=!1;break}}return o["delete"](t),o["delete"](e),f}var Ya=$a;function Za(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}var Xa=Za;function Ka(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var Qa=Ka,Ja=1,ts=2,es="[object Boolean]",ns="[object Date]",rs="[object Error]",is="[object Map]",os="[object Number]",as="[object RegExp]",ss="[object Set]",us="[object String]",ls="[object Symbol]",cs="[object ArrayBuffer]",hs="[object DataView]",fs=$t?$t.prototype:void 0,ps=fs?fs.valueOf:void 0;function ds(t,e,n,r,i,o,a){switch(n){case hs:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case cs:return!(t.byteLength!=e.byteLength||!o(new Cr(t),new Cr(e)));case es:case ns:case os:return Ae(+t,+e);case rs:return t.name==e.name&&t.message==e.message;case as:case us:return t==e+"";case is:var s=Xa;case ss:var u=r&Ja;if(s||(s=Qa),t.size!=e.size&&!u)return!1;var l=a.get(t);if(l)return l==e;r|=ts,a.set(t,e);var c=Ya(s(t),s(e),r,i,o,a);return a["delete"](t),c;case ls:if(ps)return ps.call(t)==ps.call(e)}return!1}var vs=ds;function gs(t,e,n){var r=e(t);return ni(t)?r:ua(r,n(t))}var ms=gs;function ys(t,e){var n=-1,r=null==t?0:t.length,i=0,o=[];while(++n<r){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}var _s=ys;function bs(){return[]}var ws=bs,Os=Object.prototype,xs=Os.propertyIsEnumerable,Es=Object.getOwnPropertySymbols,Ts=Es?function(t){return null==t?[]:(t=Object(t),_s(Es(t),(function(e){return xs.call(t,e)})))}:ws,Ss=Ts;function Ms(t){return ms(t,Ta,Ss)}var Cs=Ms,As=1,Ls=Object.prototype,Ds=Ls.hasOwnProperty;function ks(t,e,n,r,i,o){var a=n&As,s=Cs(t),u=s.length,l=Cs(e),c=l.length;if(u!=c&&!a)return!1;var h=u;while(h--){var f=s[h];if(!(a?f in e:Ds.call(e,f)))return!1}var p=o.get(t),d=o.get(e);if(p&&d)return p==e&&d==t;var v=!0;o.set(t,e),o.set(e,t);var g=a;while(++h<u){f=s[h];var m=t[f],y=e[f];if(r)var _=a?r(y,m,f,e,t,o):r(m,y,f,t,e,o);if(!(void 0===_?m===y||i(m,y,n,r,o):_)){v=!1;break}g||(g="constructor"==f)}if(v&&!g){var b=t.constructor,w=e.constructor;b==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(v=!1)}return o["delete"](t),o["delete"](e),v}var Ps=ks,Rs=Sn(jt["a"],"DataView"),Is=Rs,Ns=Sn(jt["a"],"Promise"),js=Ns,Bs=Sn(jt["a"],"Set"),Us=Bs,Vs=Sn(jt["a"],"WeakMap"),Hs=Vs,Gs="[object Map]",zs="[object Object]",Fs="[object Promise]",Ws="[object Set]",qs="[object WeakMap]",$s="[object DataView]",Ys=pn(Is),Zs=pn(Cn),Xs=pn(js),Ks=pn(Us),Qs=pn(Hs),Js=ue;(Is&&Js(new Is(new ArrayBuffer(1)))!=$s||Cn&&Js(new Cn)!=Gs||js&&Js(js.resolve())!=Fs||Us&&Js(new Us)!=Ws||Hs&&Js(new Hs)!=qs)&&(Js=function(t){var e=ue(t),n=e==zs?t.constructor:void 0,r=n?pn(n):"";if(r)switch(r){case Ys:return $s;case Zs:return Gs;case Xs:return Fs;case Ks:return Ws;case Qs:return qs}return e});var tu=Js,eu=1,nu="[object Arguments]",ru="[object Array]",iu="[object Object]",ou=Object.prototype,au=ou.hasOwnProperty;function su(t,e,n,r,i,o){var a=ni(t),s=ni(e),u=a?ru:tu(t),l=s?ru:tu(e);u=u==nu?iu:u,l=l==nu?iu:l;var c=u==iu,h=l==iu,f=u==l;if(f&&Object(ci["a"])(t)){if(!Object(ci["a"])(e))return!1;a=!0,c=!1}if(f&&!c)return o||(o=new vr),a||Ki(t)?Ya(t,e,n,r,i,o):vs(t,e,u,n,r,i,o);if(!(n&eu)){var p=c&&au.call(t,"__wrapped__"),d=h&&au.call(e,"__wrapped__");if(p||d){var v=p?t.value():t,g=d?e.value():e;return o||(o=new vr),i(v,g,n,r,o)}}return!!f&&(o||(o=new vr),Ps(t,e,n,r,i,o))}var uu=su;function lu(t,e,n,r,i){return t===e||(null==t||null==e||!ce(t)&&!ce(e)?t!==t&&e!==e:uu(t,e,n,r,lu,i))}var cu=lu,hu=1,fu=2;function pu(t,e,n,r){var i=n.length,o=i,a=!r;if(null==t)return!o;t=Object(t);while(i--){var s=n[i];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}while(++i<o){s=n[i];var u=s[0],l=t[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in t))return!1}else{var h=new vr;if(r)var f=r(l,c,u,t,e,h);if(!(void 0===f?cu(c,l,hu|fu,r,h):f))return!1}}return!0}var du=pu;function vu(t){return t===t&&!Nt(t)}var gu=vu;function mu(t){var e=Ta(t),n=e.length;while(n--){var r=e[n],i=t[r];e[n]=[r,i,gu(i)]}return e}var yu=mu;function _u(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}var bu=_u;function wu(t){var e=yu(t);return 1==e.length&&e[0][2]?bu(e[0][0],e[0][1]):function(n){return n===t||du(n,t,e)}}var Ou=wu,xu=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Eu=/^\w*$/;function Tu(t,e){if(ni(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!pe(t))||(Eu.test(t)||!xu.test(t)||null!=e&&t in Object(e))}var Su=Tu,Mu="Expected a function";function Cu(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError(Mu);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=t.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(Cu.Cache||cr),n}Cu.Cache=cr;var Au=Cu,Lu=500;function Du(t){var e=Au(t,(function(t){return n.size===Lu&&n.clear(),t})),n=e.cache;return e}var ku=Du,Pu=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ru=/\\(\\)?/g,Iu=ku((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(Pu,(function(t,n,r,i){e.push(r?i.replace(Ru,"$1"):n||t)})),e})),Nu=Iu;function ju(t,e){var n=-1,r=null==t?0:t.length,i=Array(r);while(++n<r)i[n]=e(t[n],n,t);return i}var Bu=ju,Uu=1/0,Vu=$t?$t.prototype:void 0,Hu=Vu?Vu.toString:void 0;function Gu(t){if("string"==typeof t)return t;if(ni(t))return Bu(t,Gu)+"";if(pe(t))return Hu?Hu.call(t):"";var e=t+"";return"0"==e&&1/t==-Uu?"-0":e}var zu=Gu;function Fu(t){return null==t?"":zu(t)}var Wu=Fu;function qu(t,e){return ni(t)?t:Su(t,e)?[t]:Nu(Wu(t))}var $u=qu,Yu=1/0;function Zu(t){if("string"==typeof t||pe(t))return t;var e=t+"";return"0"==e&&1/t==-Yu?"-0":e}var Xu=Zu;function Ku(t,e){e=$u(e,t);var n=0,r=e.length;while(null!=t&&n<r)t=t[Xu(e[n++])];return n&&n==r?t:void 0}var Qu=Ku;function Ju(t,e,n){var r=null==t?void 0:Qu(t,e);return void 0===r?n:r}var tl=Ju;function el(t,e){return null!=t&&e in Object(t)}var nl=el;function rl(t,e,n){e=$u(e,t);var r=-1,i=e.length,o=!1;while(++r<i){var a=Xu(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:(i=null==t?0:t.length,!!i&&oi(i)&&ho(a,i)&&(ni(t)||ti(t)))}var il=rl;function ol(t,e){return null!=t&&il(t,e,nl)}var al=ol,sl=1,ul=2;function ll(t,e){return Su(t)&&gu(e)?bu(Xu(t),e):function(n){var r=tl(n,t);return void 0===r&&r===e?al(n,t):cu(e,r,sl|ul)}}var cl=ll;function hl(t){return function(e){return null==e?void 0:e[t]}}var fl=hl;function pl(t){return function(e){return Qu(e,t)}}var dl=pl;function vl(t){return Su(t)?fl(Xu(t)):dl(t)}var gl=vl;function ml(t){return"function"==typeof t?t:null==t?ko:"object"==typeof t?ni(t)?cl(t[0],t[1]):Ou(t):gl(t)}var yl=ml;function _l(t,e){return function(n,r){var i=ni(n)?ma:Pa,o=e?e():{};return i(n,t,yl(r,2),o)}}var bl=_l,wl=Object.prototype,Ol=wl.hasOwnProperty,xl=bl((function(t,e,n){Ol.call(t,n)?t[n].push(e):_r(t,n,[e])})),El=xl;function Tl(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),n=n>i?i:n,n<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;var o=Array(i);while(++r<i)o[r]=t[r+e];return o}var Sl=Tl;function Ml(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:Sl(t,e,n)}var Cl=Ml,Al="\\ud800-\\udfff",Ll="\\u0300-\\u036f",Dl="\\ufe20-\\ufe2f",kl="\\u20d0-\\u20ff",Pl=Ll+Dl+kl,Rl="\\ufe0e\\ufe0f",Il="\\u200d",Nl=RegExp("["+Il+Al+Pl+Rl+"]");function jl(t){return Nl.test(t)}var Bl=jl;function Ul(t){return t.split("")}var Vl=Ul,Hl="\\ud800-\\udfff",Gl="\\u0300-\\u036f",zl="\\ufe20-\\ufe2f",Fl="\\u20d0-\\u20ff",Wl=Gl+zl+Fl,ql="\\ufe0e\\ufe0f",$l="["+Hl+"]",Yl="["+Wl+"]",Zl="\\ud83c[\\udffb-\\udfff]",Xl="(?:"+Yl+"|"+Zl+")",Kl="[^"+Hl+"]",Ql="(?:\\ud83c[\\udde6-\\uddff]){2}",Jl="[\\ud800-\\udbff][\\udc00-\\udfff]",tc="\\u200d",ec=Xl+"?",nc="["+ql+"]?",rc="(?:"+tc+"(?:"+[Kl,Ql,Jl].join("|")+")"+nc+ec+")*",ic=nc+ec+rc,oc="(?:"+[Kl+Yl+"?",Yl,Ql,Jl,$l].join("|")+")",ac=RegExp(Zl+"(?="+Zl+")|"+oc+ic,"g");function sc(t){return t.match(ac)||[]}var uc=sc;function lc(t){return Bl(t)?uc(t):Vl(t)}var cc=lc;function hc(t){return function(e){e=Wu(e);var n=Bl(e)?cc(e):void 0,r=n?n[0]:e.charAt(0),i=n?Cl(n,1).join(""):e.slice(1);return r[t]()+i}}var fc=hc,pc=fc("toUpperCase"),dc=pc;function vc(t){return dc(Wu(t).toLowerCase())}var gc=vc;function mc(t,e,n,r){var i=-1,o=null==t?0:t.length;r&&o&&(n=t[++i]);while(++i<o)n=e(n,t[i],i,t);return n}var yc=mc;function _c(t){return function(e){return null==t?void 0:t[e]}}var bc=_c,wc={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},Oc=bc(wc),xc=Oc,Ec=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Tc="\\u0300-\\u036f",Sc="\\ufe20-\\ufe2f",Mc="\\u20d0-\\u20ff",Cc=Tc+Sc+Mc,Ac="["+Cc+"]",Lc=RegExp(Ac,"g");function Dc(t){return t=Wu(t),t&&t.replace(Ec,xc).replace(Lc,"")}var kc=Dc,Pc=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Rc(t){return t.match(Pc)||[]}var Ic=Rc,Nc=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function jc(t){return Nc.test(t)}var Bc=jc,Uc="\\ud800-\\udfff",Vc="\\u0300-\\u036f",Hc="\\ufe20-\\ufe2f",Gc="\\u20d0-\\u20ff",zc=Vc+Hc+Gc,Fc="\\u2700-\\u27bf",Wc="a-z\\xdf-\\xf6\\xf8-\\xff",qc="\\xac\\xb1\\xd7\\xf7",$c="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Yc="\\u2000-\\u206f",Zc=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xc="A-Z\\xc0-\\xd6\\xd8-\\xde",Kc="\\ufe0e\\ufe0f",Qc=qc+$c+Yc+Zc,Jc="['’]",th="["+Qc+"]",eh="["+zc+"]",nh="\\d+",rh="["+Fc+"]",ih="["+Wc+"]",oh="[^"+Uc+Qc+nh+Fc+Wc+Xc+"]",ah="\\ud83c[\\udffb-\\udfff]",sh="(?:"+eh+"|"+ah+")",uh="[^"+Uc+"]",lh="(?:\\ud83c[\\udde6-\\uddff]){2}",ch="[\\ud800-\\udbff][\\udc00-\\udfff]",hh="["+Xc+"]",fh="\\u200d",ph="(?:"+ih+"|"+oh+")",dh="(?:"+hh+"|"+oh+")",vh="(?:"+Jc+"(?:d|ll|m|re|s|t|ve))?",gh="(?:"+Jc+"(?:D|LL|M|RE|S|T|VE))?",mh=sh+"?",yh="["+Kc+"]?",_h="(?:"+fh+"(?:"+[uh,lh,ch].join("|")+")"+yh+mh+")*",bh="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",wh="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Oh=yh+mh+_h,xh="(?:"+[rh,lh,ch].join("|")+")"+Oh,Eh=RegExp([hh+"?"+ih+"+"+vh+"(?="+[th,hh,"$"].join("|")+")",dh+"+"+gh+"(?="+[th,hh+ph,"$"].join("|")+")",hh+"?"+ph+"+"+vh,hh+"+"+gh,wh,bh,nh,xh].join("|"),"g");function Th(t){return t.match(Eh)||[]}var Sh=Th;function Mh(t,e,n){return t=Wu(t),e=n?void 0:e,void 0===e?Bc(t)?Sh(t):Ic(t):t.match(e)||[]}var Ch=Mh,Ah="['’]",Lh=RegExp(Ah,"g");function Dh(t){return function(e){return yc(Ch(kc(e).replace(Lh,"")),t,"")}}var kh=Dh,Ph=kh((function(t,e,n){return e=e.toLowerCase(),t+(n?gc(e):e)})),Rh=Ph,Ih="[object Map]",Nh="[object Set]",jh=Object.prototype,Bh=jh.hasOwnProperty;function Uh(t){if(null==t)return!0;if(si(t)&&(ni(t)||"string"==typeof t||"function"==typeof t.splice||Object(ci["a"])(t)||Ki(t)||ti(t)))return!t.length;var e=tu(t);if(e==Ih||e==Nh)return!t.size;if(Fr(t))return!xa(t).length;for(var n in t)if(Bh.call(t,n))return!1;return!0}var Vh=Uh;function Hh(t,e){return cu(t,e)}var Gh=Hh;function zh(t,e){var n=-1,r=si(t)?Array(t.length):[];return Da(t,(function(t,i,o){r[++n]=e(t,i,o)})),r}var Fh=zh;function Wh(t,e){var n=ni(t)?Bu:Fh;return n(t,yl(e,3))}var qh=Wh,$h=1/0;function Yh(t,e){return pa(qh(t,e),$h)}var Zh=Yh,Xh=kh((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Kh=Xh;function Qh(t){var e=-1,n=null==t?0:t.length,r={};while(++e<n){var i=t[e];r[i[0]]=i[1]}return r}var Jh=Qh;function tf(t,e){var n;return Da(t,(function(t,r,i){return n=e(t,r,i),!n})),!!n}var ef=tf;function nf(t,e,n){var r=ni(t)?Ga:ef;return n&&Qo(t,e,n)&&(e=void 0),r(t,yl(e,3))}var rf=nf;function of(t,e){var n=-1,r=null==t?0:t.length;while(++n<r)if(!1===e(t[n],n,t))break;return t}var af=of;function sf(t,e){return t&&oo(e,Ta(e),t)}var uf=sf;function lf(t,e){return t&&oo(e,Eo(e),t)}var cf=lf;function hf(t,e){return oo(t,Ss(t),e)}var ff=hf,pf=Object.getOwnPropertySymbols,df=pf?function(t){var e=[];while(t)ua(e,Ss(t)),t=Hr(t);return e}:ws,vf=df;function gf(t,e){return oo(t,vf(t),e)}var mf=gf;function yf(t){return ms(t,Eo,vf)}var _f=yf,bf=Object.prototype,wf=bf.hasOwnProperty;function Of(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&wf.call(t,"index")&&(n.index=t.index,n.input=t.input),n}var xf=Of;function Ef(t,e){var n=e?Lr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}var Tf=Ef,Sf=/\w*$/;function Mf(t){var e=new t.constructor(t.source,Sf.exec(t));return e.lastIndex=t.lastIndex,e}var Cf=Mf,Af=$t?$t.prototype:void 0,Lf=Af?Af.valueOf:void 0;function Df(t){return Lf?Object(Lf.call(t)):{}}var kf=Df,Pf="[object Boolean]",Rf="[object Date]",If="[object Map]",Nf="[object Number]",jf="[object RegExp]",Bf="[object Set]",Uf="[object String]",Vf="[object Symbol]",Hf="[object ArrayBuffer]",Gf="[object DataView]",zf="[object Float32Array]",Ff="[object Float64Array]",Wf="[object Int8Array]",qf="[object Int16Array]",$f="[object Int32Array]",Yf="[object Uint8Array]",Zf="[object Uint8ClampedArray]",Xf="[object Uint16Array]",Kf="[object Uint32Array]";function Qf(t,e,n){var r=t.constructor;switch(e){case Hf:return Lr(t);case Pf:case Rf:return new r(+t);case Gf:return Tf(t,n);case zf:case Ff:case Wf:case qf:case $f:case Yf:case Zf:case Xf:case Kf:return kr(t,n);case If:return new r;case Nf:case Uf:return new r(t);case jf:return Cf(t);case Bf:return new r;case Vf:return kf(t)}}var Jf=Qf,tp="[object Map]";function ep(t){return ce(t)&&tu(t)==tp}var np=ep,rp=Yi["a"]&&Yi["a"].isMap,ip=rp?$i(rp):np,op=ip,ap="[object Set]";function sp(t){return ce(t)&&tu(t)==ap}var up=sp,lp=Yi["a"]&&Yi["a"].isSet,cp=lp?$i(lp):up,hp=cp,fp=1,pp=2,dp=4,vp="[object Arguments]",gp="[object Array]",mp="[object Boolean]",yp="[object Date]",_p="[object Error]",bp="[object Function]",wp="[object GeneratorFunction]",Op="[object Map]",xp="[object Number]",Ep="[object Object]",Tp="[object RegExp]",Sp="[object Set]",Mp="[object String]",Cp="[object Symbol]",Ap="[object WeakMap]",Lp="[object ArrayBuffer]",Dp="[object DataView]",kp="[object Float32Array]",Pp="[object Float64Array]",Rp="[object Int8Array]",Ip="[object Int16Array]",Np="[object Int32Array]",jp="[object Uint8Array]",Bp="[object Uint8ClampedArray]",Up="[object Uint16Array]",Vp="[object Uint32Array]",Hp={};function Gp(t,e,n,r,i,o){var a,s=e&fp,u=e&pp,l=e&dp;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!Nt(t))return t;var c=ni(t);if(c){if(a=xf(t),!s)return Rr(t,a)}else{var h=tu(t),f=h==bp||h==wp;if(Object(ci["a"])(t))return Object(Sr["a"])(t,s);if(h==Ep||h==vp||f&&!i){if(a=u||f?{}:qr(t),!s)return u?mf(t,cf(a,t)):ff(t,uf(a,t))}else{if(!Hp[h])return i?t:{};a=Jf(t,h,s)}}o||(o=new vr);var p=o.get(t);if(p)return p;o.set(t,a),hp(t)?t.forEach((function(r){a.add(Gp(r,e,n,r,t,o))})):op(t)&&t.forEach((function(r,i){a.set(i,Gp(r,e,n,i,t,o))}));var d=l?u?_f:Cs:u?Eo:Ta,v=c?void 0:d(t);return af(v||t,(function(r,i){v&&(i=r,r=t[i]),ro(a,i,Gp(r,e,n,i,t,o))})),a}Hp[vp]=Hp[gp]=Hp[Lp]=Hp[Dp]=Hp[mp]=Hp[yp]=Hp[kp]=Hp[Pp]=Hp[Rp]=Hp[Ip]=Hp[Np]=Hp[Op]=Hp[xp]=Hp[Ep]=Hp[Tp]=Hp[Sp]=Hp[Mp]=Hp[Cp]=Hp[jp]=Hp[Bp]=Hp[Up]=Hp[Vp]=!0,Hp[_p]=Hp[bp]=Hp[Ap]=!1;var zp=Gp,Fp=1,Wp=4;function qp(t){return zp(t,Fp|Wp)}var $p=qp;function Yp(t,e,n,r){var i=t.length,o=n+(r?1:-1);while(r?o--:++o<i)if(e(t[o],o,t))return o;return-1}var Zp=Yp;function Xp(t){return t!==t}var Kp=Xp;function Qp(t,e,n){var r=n-1,i=t.length;while(++r<i)if(t[r]===e)return r;return-1}var Jp=Qp;function td(t,e,n){return e===e?Jp(t,e,n):Zp(t,Kp,n)}var ed=td;function nd(t,e){var n=null==t?0:t.length;return!!n&&ed(t,e,0)>-1}var rd=nd;function id(t,e,n){var r=-1,i=null==t?0:t.length;while(++r<i)if(n(e,t[r]))return!0;return!1}var od=id;function ad(){}var sd=ad,ud=1/0,ld=Us&&1/Qa(new Us([,-0]))[1]==ud?function(t){return new Us(t)}:sd,cd=ld,hd=200;function fd(t,e,n){var r=-1,i=rd,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=od;else if(o>=hd){var l=e?null:cd(t);if(l)return Qa(l);a=!1,i=Fa,u=new Va}else u=e?[]:s;t:while(++r<o){var c=t[r],h=e?e(c):c;if(c=n||0!==c?c:0,a&&h===h){var f=u.length;while(f--)if(u[f]===h)continue t;e&&u.push(h),s.push(c)}else i(u,h,n)||(u!==s&&u.push(h),s.push(c))}return s}var pd=fd;function dd(t){return t&&t.length?pd(t):[]}var vd=dd;function gd(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}var md=gd,yd=Xo((function(t){var e=md(t);return li(e)&&(e=void 0),pd(pa(t,1,li,!0),yl(e,2))})),_d=yd,bd=function(t){let e;while(e=t.sourceEvent)t=e;return t},wd=function(t,e){if(t=bd(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,r=r.matrixTransform(e.getScreenCTM().inverse()),[r.x,r.y]}if(e.getBoundingClientRect){var i=e.getBoundingClientRect();return[t.clientX-i.left-e.clientLeft,t.clientY-i.top-e.clientTop]}}return[t.pageX,t.pageY]},Od=$p,xd=vd;function Ed(t,e,n){var r=null;return function(){var i=this,o=arguments;i.mousePosition=wd(o[0],n),clearTimeout(r),r=setTimeout((function(){t.apply(i,o)}),e)}}function Td(t,e){var n,r,i=Od(t),o=Object.keys(e.axes||{});for(var a in(null===(r=null===(n=e)||void 0===n?void 0:n.toolbar)||void 0===r?void 0:r.controls)&&delete i.toolbar.controls,0===o.length&&delete i.axes,i.axes)if(o.includes(a)){var s=e.axes[a];(s["primary"]||s["secondary"])&&console.warn("`primary` & `secondary` are no longer needed for axis configurations. Read more here https://carbon-design-system.github.io/carbon-charts/?path=/story/docs-tutorials--tabular-data-format");var u=s["mapsTo"];if(void 0===u||null===u){var l=s["scaleType"];void 0===l||null===l?s["mapsTo"]="value":l===G.TIME?s["mapsTo"]="date":l===G.LABELS&&(s["mapsTo"]="key")}}else delete i.axes[a];return Ld(i,e),na(i,e)}function Sd(t){if(t){var e=/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/,n=t.getAttribute("transform").match(e);if(!n)return null;if(n[0]){var r=n[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:r[0],ty:r[1]}}return null}}function Md(t){var e=/\(([^)]+)\)/,n=e.exec(t)[1],r=n.split(",");return{x:parseFloat(r[0]),y:parseFloat(r[1])}}function Cd(t,e,n){void 0===n&&(n="value");var r=t/e.reduce((function(t,e){return t+e[n]}),0)*100;return r%1!==0?parseFloat(r.toFixed(1)):r}function Ad(t,e,n){return n>t.length?t:e===V.MID_LINE?t.substr(0,n/2)+"..."+t.substr(-n/2):e===V.FRONT_LINE?"..."+t.substr(-n):e===V.END_LINE?t.substr(0,n)+"...":void 0}function Ld(t,e){var n=Dd(t,"legend","additionalItems"),r=Dd(e,"legend","additionalItems");if(n&&r){var i=r.map((function(t){return t.type})),o=n.map((function(t){return t.type})),a=Rt.filter((function(t){return o.includes(t.type)&&!i.includes(t.type)}));t.legend.additionalItems=a,e.legend.additionalItems=_d(a,r,"name")}}var Dd=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var r=t;if(r){for(var i=0,o=e;i<o.length;i++){var a=o[i];if(null===r[a]||void 0===r[a])return null;r=r[a]}return r}return null},kd=function(t,e){return e===H.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},Pd=function(t,e){var n=kd(t,e),r=n.x0,i=n.x1,o=n.y0,a=n.y1;return"M"+r+","+o+"L"+r+","+a+"L"+i+","+a+"L"+i+","+o+"L"+r+","+o};function Rd(t,e,n){return n===H.VERTICAL?[t,e]:[e,t]}var Id=n("39ba"),Nd=n.n(Id),jd=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},Bd={type:V.END_LINE,threshold:16,numCharacter:14},Ud={enabled:!0,position:z.BOTTOM,clickable:!0,truncation:Bd,alignment:F.LEFT,order:null,additionalItems:[]},Vd={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},Hd={enabled:!0},Gd={enabled:!0,showTotal:!0,truncation:Bd,groupLabel:"Group"},zd={top:{visible:!0,includeZero:!0,truncation:Bd},bottom:{visible:!0,includeZero:!0,truncation:Bd},left:{visible:!0,includeZero:!0,truncation:Bd},right:{visible:!0,includeZero:!0,truncation:Bd}},Fd={addSpaceOnEdges:1,showDayName:!1,localeObject:Nd.a,timeIntervalFormats:{"15seconds":{primary:"MMM d, pp",secondary:"pp"},minute:{primary:"MMM d, p",secondary:"p"},"30minutes":{primary:"MMM d, p",secondary:"p"},hourly:{primary:"MMM d, hh a",secondary:"hh a"},daily:{primary:"MMM d",secondary:"d"},weekly:{primary:"eee, MMM d",secondary:"eee"},monthly:{primary:"MMM yyyy",secondary:"MMM"},quarterly:{primary:"QQQ ''yy",secondary:"QQQ"},yearly:{primary:"yyyy",secondary:"yyyy"}}},Wd="undefined"!==typeof document&&(document["fullscreenEnabled"]||document["webkitFullscreenEnabled"]||document["mozFullScreenEnabled"]||document["msFullscreenEnabled"]),qd={width:null,height:null,resizable:!0,theme:N.WHITE,tooltip:Gd,legend:Ud,style:{prefix:"cc"},data:{groupMapsTo:"group",loading:!1,selectedGroups:[]},color:{scale:null,pairing:{numberOfVariants:null,option:1},gradient:{enabled:!1}},toolbar:{enabled:!0,numberOfIcons:3,controls:jd([{type:ot.SHOW_AS_DATATABLE}],Wd?[{type:ot.MAKE_FULLSCREEN}]:[],[{type:ot.EXPORT_CSV},{type:ot.EXPORT_PNG},{type:ot.EXPORT_JPG}])}},$d=na({},qd,{axes:zd,timeScale:Fd,grid:Vd,ruler:Hd,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:U.GRAPH_VIEW}}}),Yd=na({},$d,{bars:{maxWidth:16,spacingFactor:.25},timeScale:na(Fd,{addSpaceOnEdges:1})}),Zd=na({},Yd,{}),Xd=na({},Yd,{}),Kd=na({},Yd,{bars:na({},Yd.bars,{dividerSize:1.5})}),Qd=na({},Yd,{}),Jd=na({},$d,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),tv=Jd,ev=na({},Jd,{points:{radius:3,filled:!1,enabled:!0}}),nv=na({},ev,{timeScale:na(Fd,{addSpaceOnEdges:0})}),rv=nv,iv=na({},$d,{bubble:{radiusMapsTo:"radius",radiusLabel:"Radius",radiusRange:function(t,e){var n=Math.min(t.width,t.height);return[3*n/400,25*n/400]},fillOpacity:.2,enabled:!0},points:{filled:!0},legend:{additionalItems:[{type:st.RADIUS,name:"Radius"}]}}),ov=na({},$d,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:st.AREA,name:"Poor area"},{type:st.AREA,name:"Satisfactory area"},{type:st.AREA,name:"Great area"},{type:st.QUARTILE,name:"Quartiles"}]}}),av=na({},Yd,{bars:{dividerSize:1.5},timeScale:na(Fd,{addSpaceOnEdges:0})}),sv=na({},qd,{tooltip:na({},Gd,{wordLabel:"Word",valueLabel:"Value"}),wordCloud:{fontSizeMapsTo:"value",fontSizeRange:function(t,e){var n=Math.min(t.width,t.height);return[20*n/400,75*n/400]},wordMapsTo:"word"}}),uv=na({},qd,{pie:{labels:{formatter:null,enabled:!0},alignment:F.LEFT,sortFunction:null,valueMapsTo:"value"}}),lv=na({},qd,{legend:{enabled:!1},gauge:{type:tt.SEMI,arcWidth:16,deltaArrow:{size:function(t){return t/8},enabled:!0},showPercentageSymbol:!0,status:null,numberSpacing:10,deltaFontSize:function(t){return t/8},valueFontSize:function(t){return t/2.5},numberFormatter:function(t){return t.toFixed(2)%1!==0?t.toFixed(2).toLocaleString():t.toFixed().toLocaleString()},alignment:F.LEFT}}),cv=na({},uv,{donut:{center:{numberFontSize:function(t){return Math.min(t/100*24,24)+"px"},titleFontSize:function(t){return Math.min(t/100*15,15)+"px"},titleYPosition:function(t){return Math.min(t/80*20,20)},numberFormatter:function(t){return Math.floor(t).toLocaleString()}},alignment:F.LEFT}}),hv=na({},qd,{legend:{enabled:!1,clickable:!1},meter:{showLabels:!0,proportional:null,statusBar:{percentageIndicator:{enabled:!0}}}}),fv=na({},hv,{legend:{enabled:!0}}),pv=na({},qd,{radar:{axes:{angle:"key",value:"value"},alignment:F.LEFT},tooltip:{gridline:{enabled:!0},valueFormatter:function(t){return null!==t&&void 0!==t?t:"N/A"}}}),dv=na({},Yd,{comboChartTypes:[]}),vv=na({tree:{type:q.TREE}},qd,{}),gv=na({},qd,{data:na(qd.data,{groupMapsTo:"name"})}),mv=na({},qd,yt,{data:na(qd.data,{groupMapsTo:"name"})}),yv=na({},qd,{alluvial:{data:na(qd.data,{groupMapsTo:"source"}),nodeAlignment:F.CENTER,nodePadding:24,monochrome:!1,nodes:[]}}),_v=na({},qd,{axes:zd,heatmap:{divider:{state:lt.AUTO},colorLegend:{type:"linear"}}}),bv={chart:qd,axisChart:$d,simpleBarChart:Zd,groupedBarChart:Xd,stackedBarChart:Kd,boxplotChart:Qd,bubbleChart:iv,bulletChart:ov,histogramChart:av,lineChart:ev,areaChart:nv,stackedAreaChart:rv,scatterChart:Jd,lollipopChart:tv,pieChart:uv,donutChart:cv,meterChart:hv,proportionalMeterChart:fv,radarChart:pv,gaugeChart:lv,comboChart:dv,treeChart:vv,treemapChart:gv,circlePackChart:mv,wordCloudChart:sv,alluvialChart:yv,heatmapChart:_v};class wv extends Map{constructor(t,e=Tv){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[n,r]of t)this.set(n,r)}get(t){return super.get(Ov(this,t))}has(t){return super.has(Ov(this,t))}set(t,e){return super.set(xv(this,t),e)}delete(t){return super.delete(Ev(this,t))}}Set;function Ov({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):n}function xv({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):(t.set(r,n),n)}function Ev({_intern:t,_key:e},n){const r=e(n);return t.has(r)&&(n=t.get(r),t.delete(r)),n}function Tv(t){return null!==t&&"object"===typeof t?t.valueOf():t}function Sv(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}const Mv=Symbol("implicit");function Cv(){var t=new wv,e=[],n=[],r=Mv;function i(i){let o=t.get(i);if(void 0===o){if(r!==Mv)return r;t.set(i,o=e.push(i)-1)}return n[o%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new wv;for(const r of n)t.has(r)||t.set(r,e.push(r)-1);return i},i.range=function(t){return arguments.length?(n=Array.from(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Cv(e,n).unknown(r)},Sv.apply(i,arguments),i}var Av=Array.prototype.slice,Lv=function(t){return"object"===typeof t&&"length"in t?t:Array.from(t)},Dv=function(t){return function(){return t}},kv=function(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]},Pv=function(t){var e=t.length,n=new Array(e);while(--e>=0)n[e]=e;return n};function Rv(t,e){return t[e]}function Iv(t){const e=[];return e.key=t,e}var Nv=function(){var t=Dv([]),e=Pv,n=kv,r=Rv;function i(i){var o,a,s=Array.from(t.apply(this,arguments),Iv),u=s.length,l=-1;for(const t of i)for(o=0,++l;o<u;++o)(s[o][l]=[0,+r(t,s[o].key,l,i)]).data=t;for(o=0,a=Lv(e(s));o<u;++o)s[a[o]].index=o;return n(s,a),s}return i.keys=function(e){return arguments.length?(t="function"===typeof e?e:Dv(Array.from(e)),i):t},i.value=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?Pv:"function"===typeof t?t:Dv(Array.from(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?kv:t,i):n},i},jv=function(t,e){if((s=t.length)>0)for(var n,r,i,o,a,s,u=0,l=t[e[0]].length;u<l;++u)for(o=a=0,n=0;n<s;++n)(i=(r=t[e[n]][u])[1]-r[0])>0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=a,r[0]=a+=i):(r[0]=0,r[1]=i)},Bv=Array.prototype,Uv=Bv.slice;Bv.map;function Vv(t,e){return null==t||null==e?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Hv(t,e){return null==t||null==e?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Gv(t){let e,n,r;function i(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<0?i=e+1:o=e}while(i<o)}return i}function o(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<=0?i=e+1:o=e}while(i<o)}return i}function a(t,e,n=0,o=t.length){const a=i(t,e,n,o-1);return a>n&&r(t[a-1],e)>-r(t[a],e)?a-1:a}return 2!==t.length?(e=Vv,n=(e,n)=>Vv(t(e),n),r=(e,n)=>t(e)-n):(e=t===Vv||t===Hv?t:zv,n=t,r=t),{left:i,center:a,right:o}}function zv(){return 0}function Fv(t){return null===t?NaN:+t}function*Wv(t,e){if(void 0===e)for(let n of t)null!=n&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of t)null!=(r=e(r,++n,t))&&(r=+r)>=r&&(yield r)}}const qv=Gv(Vv),$v=qv.right;qv.left,Gv(Fv).center;var Yv=$v;function Zv(t){return()=>t}function Xv(t,e){let n,r;if(void 0===e)for(const i of t)null!=i&&(void 0===n?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(void 0===n?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}function Kv(t){return t}const Qv=Math.sqrt(50),Jv=Math.sqrt(10),tg=Math.sqrt(2);function eg(t,e,n){const r=(e-t)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=Qv?10:o>=Jv?5:o>=tg?2:1;let s,u,l;return i<0?(l=Math.pow(10,-i)/a,s=Math.round(t*l),u=Math.round(e*l),s/l<t&&++s,u/l>e&&--u,l=-l):(l=Math.pow(10,i)*a,s=Math.round(t/l),u=Math.round(e/l),s*l<t&&++s,u*l>e&&--u),u<s&&.5<=n&&n<2?eg(t,e,2*n):[s,u,l]}function ng(t,e,n){if(e=+e,t=+t,n=+n,!(n>0))return[];if(t===e)return[t];const r=e<t,[i,o,a]=r?eg(e,t,n):eg(t,e,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let l=0;l<s;++l)u[l]=(o-l)/-a;else for(let l=0;l<s;++l)u[l]=(o-l)*a;else if(a<0)for(let l=0;l<s;++l)u[l]=(i+l)/-a;else for(let l=0;l<s;++l)u[l]=(i+l)*a;return u}function rg(t,e,n){return e=+e,t=+t,n=+n,eg(t,e,n)[2]}function ig(t,e,n){e=+e,t=+t,n=+n;const r=e<t,i=r?rg(e,t,n):rg(t,e,n);return(r?-1:1)*(i<0?1/-i:i)}function og(t,e,n){let r;while(1){const i=rg(t,e,n);if(i===r||0===i||!isFinite(i))return[t,e];i>0?(t=Math.floor(t/i)*i,e=Math.ceil(e/i)*i):i<0&&(t=Math.ceil(t*i)/i,e=Math.floor(e*i)/i),r=i}}function ag(t,e){let n=0;if(void 0===e)for(let r of t)null!=r&&(r=+r)>=r&&++n;else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(i=+i)>=i&&++n}return n}function sg(t){return Math.max(1,Math.ceil(Math.log(ag(t))/Math.LN2)+1)}function ug(){var t=Kv,e=Xv,n=sg;function r(r){Array.isArray(r)||(r=Array.from(r));var i,o,a,s=r.length,u=new Array(s);for(i=0;i<s;++i)u[i]=t(r[i],i,r);var l=e(u),c=l[0],h=l[1],f=n(u,c,h);if(!Array.isArray(f)){const t=h,n=+f;if(e===Xv&&([c,h]=og(c,h,n)),f=ng(c,h,n),f[0]<=c&&(a=rg(c,h,n)),f[f.length-1]>=h)if(t>=h&&e===Xv){const t=rg(c,h,n);isFinite(t)&&(t>0?h=(Math.floor(h/t)+1)*t:t<0&&(h=(Math.ceil(h*-t)+1)/-t))}else f.pop()}var p=f.length,d=0,v=p;while(f[d]<=c)++d;while(f[v-1]>h)--v;(d||v<p)&&(f=f.slice(d,v),p=v-d);var g,m=new Array(p+1);for(i=0;i<=p;++i)g=m[i]=[],g.x0=i>0?f[i-1]:c,g.x1=i<p?f[i]:h;if(isFinite(a)){if(a>0)for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=h&&m[Math.min(p,Math.floor((o-c)/a))].push(r[i]);else if(a<0)for(i=0;i<s;++i)if(null!=(o=u[i])&&c<=o&&o<=h){const t=Math.floor((c-o)*a);m[Math.min(p,t+(f[t]<=o))].push(r[i])}}else for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=h&&m[Yv(f,o,0,p)].push(r[i]);return m}return r.value=function(e){return arguments.length?(t="function"===typeof e?e:Zv(e),r):t},r.domain=function(t){return arguments.length?(e="function"===typeof t?t:Zv([t[0],t[1]]),r):e},r.thresholds=function(t){return arguments.length?(n="function"===typeof t?t:Zv(Array.isArray(t)?Uv.call(t):t),r):n},r}function lg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===typeof t&&"[object Date]"===e?new Date(t.getTime()):"number"===typeof t||"[object Number]"===e?new Date(t):("string"!==typeof t&&"[object String]"!==e||"undefined"===typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule"),console.warn((new Error).stack)),new Date(NaN))}function cg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t);return!isNaN(e)}var hg={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function fg(t,e,n){var r;return n=n||{},r="string"===typeof hg[t]?hg[t]:1===e?hg[t].one:hg[t].other.replace("{{count}}",e),n.addSuffix?n.comparison>0?"in "+r:r+" ago":r}function pg(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth,i=t.formats[r]||t.formats[t.defaultWidth];return i}}var dg={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},vg={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},gg={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},mg={date:pg({formats:dg,defaultWidth:"full"}),time:pg({formats:vg,defaultWidth:"full"}),dateTime:pg({formats:gg,defaultWidth:"full"})},yg=mg,_g={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function bg(t,e,n,r){return _g[t]}function wg(t){return function(e,n){var r,i=n||{},o=i.context?String(i.context):"standalone";if("formatting"===o&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,s=i.width?String(i.width):a;r=t.formattingValues[s]||t.formattingValues[a]}else{var u=t.defaultWidth,l=i.width?String(i.width):t.defaultWidth;r=t.values[l]||t.values[u]}var c=t.argumentCallback?t.argumentCallback(e):e;return r[c]}}var Og={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},xg={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Eg={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Tg={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Sg={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Mg={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}};function Cg(t,e){var n=Number(t),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"}var Ag={ordinalNumber:Cg,era:wg({values:Og,defaultWidth:"wide"}),quarter:wg({values:xg,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:wg({values:Eg,defaultWidth:"wide"}),day:wg({values:Tg,defaultWidth:"wide"}),dayPeriod:wg({values:Sg,defaultWidth:"wide",formattingValues:Mg,defaultFormattingWidth:"wide"})},Lg=Ag;function Dg(t){return function(e,n){var r=String(e),i=n||{},o=r.match(t.matchPattern);if(!o)return null;var a=o[0],s=r.match(t.parsePattern);if(!s)return null;var u=t.valueCallback?t.valueCallback(s[0]):s[0];return u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(a.length)}}}function kg(t){return function(e,n){var r=String(e),i=n||{},o=i.width,a=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],s=r.match(a);if(!s)return null;var u,l=s[0],c=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth];return u="[object Array]"===Object.prototype.toString.call(c)?Rg(c,(function(t){return t.test(r)})):Pg(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(l.length)}}}function Pg(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function Rg(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}var Ig=/^(\d+)(th|st|nd|rd)?/i,Ng=/\d+/i,jg={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},Bg={any:[/^b/i,/^(a|c)/i]},Ug={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Vg={any:[/1/i,/2/i,/3/i,/4/i]},Hg={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Gg={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},zg={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Fg={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Wg={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},qg={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},$g={ordinalNumber:Dg({matchPattern:Ig,parsePattern:Ng,valueCallback:function(t){return parseInt(t,10)}}),era:kg({matchPatterns:jg,defaultMatchWidth:"wide",parsePatterns:Bg,defaultParseWidth:"any"}),quarter:kg({matchPatterns:Ug,defaultMatchWidth:"wide",parsePatterns:Vg,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:kg({matchPatterns:Hg,defaultMatchWidth:"wide",parsePatterns:Gg,defaultParseWidth:"any"}),day:kg({matchPatterns:zg,defaultMatchWidth:"wide",parsePatterns:Fg,defaultParseWidth:"any"}),dayPeriod:kg({matchPatterns:Wg,defaultMatchWidth:"any",parsePatterns:qg,defaultParseWidth:"any"})},Yg=$g,Zg={code:"en-US",formatDistance:fg,formatLong:yg,formatRelative:bg,localize:Lg,match:Yg,options:{weekStartsOn:0,firstWeekContainsDate:1}},Xg=Zg;function Kg(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function Qg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t).getTime(),r=Kg(e);return new Date(n+r)}function Jg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,-n)}function tm(t,e){var n=t<0?"-":"",r=Math.abs(t).toString();while(r.length<e)r="0"+r;return n+r}var em={y:function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return tm("yy"===e?r%100:r,e.length)},M:function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):tm(n+1,2)},d:function(t,e){return tm(t.getUTCDate(),e.length)},a:function(t,e){var n=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.toUpperCase();case"aaaaa":return n[0];case"aaaa":default:return"am"===n?"a.m.":"p.m."}},h:function(t,e){return tm(t.getUTCHours()%12||12,e.length)},H:function(t,e){return tm(t.getUTCHours(),e.length)},m:function(t,e){return tm(t.getUTCMinutes(),e.length)},s:function(t,e){return tm(t.getUTCSeconds(),e.length)},S:function(t,e){var n=e.length,r=t.getUTCMilliseconds(),i=Math.floor(r*Math.pow(10,n-3));return tm(i,e.length)}},nm=em,rm=864e5;function im(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime(),i=n-r;return Math.floor(i/rm)+1}function om(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=1,n=lg(t),r=n.getUTCDay(),i=(r<e?7:0)+r-e;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function am(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=om(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=om(o);return e.getTime()>=i.getTime()?n+1:e.getTime()>=a.getTime()?n:n-1}function sm(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=am(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=om(n);return r}var um=6048e5;function lm(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=om(e).getTime()-sm(e).getTime();return Math.round(n/um)+1}function cm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=e||{},r=n.locale,i=r&&r.options&&r.options.weekStartsOn,o=null==i?0:Kg(i),a=null==n.weekStartsOn?o:Kg(n.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=lg(t),u=s.getUTCDay(),l=(u<a?7:0)+u-a;return s.setUTCDate(s.getUTCDate()-l),s.setUTCHours(0,0,0,0),s}function hm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=lg(t,e),r=n.getUTCFullYear(),i=e||{},o=i.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:Kg(a),u=null==i.firstWeekContainsDate?s:Kg(i.firstWeekContainsDate);if(!(u>=1&&u<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var l=new Date(0);l.setUTCFullYear(r+1,0,u),l.setUTCHours(0,0,0,0);var c=cm(l,e),h=new Date(0);h.setUTCFullYear(r,0,u),h.setUTCHours(0,0,0,0);var f=cm(h,e);return n.getTime()>=c.getTime()?r+1:n.getTime()>=f.getTime()?r:r-1}function fm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=e||{},r=n.locale,i=r&&r.options&&r.options.firstWeekContainsDate,o=null==i?1:Kg(i),a=null==n.firstWeekContainsDate?o:Kg(n.firstWeekContainsDate),s=hm(t,e),u=new Date(0);u.setUTCFullYear(s,0,a),u.setUTCHours(0,0,0,0);var l=cm(u,e);return l}var pm=6048e5;function dm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=lg(t),r=cm(n,e).getTime()-fm(n,e).getTime();return Math.round(r/pm)+1}var vm={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},gm={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return nm.y(t,e)},Y:function(t,e,n,r){var i=hm(t,r),o=i>0?i:1-i;if("YY"===e){var a=o%100;return tm(a,2)}return"Yo"===e?n.ordinalNumber(o,{unit:"year"}):tm(o,e.length)},R:function(t,e){var n=am(t);return tm(n,e.length)},u:function(t,e){var n=t.getUTCFullYear();return tm(n,e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return tm(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return tm(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return nm.M(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return tm(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var i=dm(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):tm(i,e.length)},I:function(t,e,n){var r=lm(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):tm(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):nm.d(t,e)},D:function(t,e,n){var r=im(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):tm(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(o);case"ee":return tm(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(o);case"cc":return tm(o,e.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),i=0===r?7:r;switch(e){case"i":return String(i);case"ii":return tm(i,e.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours(),i=r/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?vm.noon:0===i?vm.midnight:i/12>=1?"pm":"am",e){case"b":case"bb":case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,i=t.getUTCHours();switch(r=i>=17?vm.evening:i>=12?vm.afternoon:i>=4?vm.morning:vm.night,e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return nm.h(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):nm.H(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):tm(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):tm(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):nm.m(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):nm.s(t,e)},S:function(t,e){return nm.S(t,e)},X:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();if(0===o)return"Z";switch(e){case"X":return ym(o);case"XXXX":case"XX":return _m(o);case"XXXXX":case"XXX":default:return _m(o,":")}},x:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"x":return ym(o);case"xxxx":case"xx":return _m(o);case"xxxxx":case"xxx":default:return _m(o,":")}},O:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+mm(o,":");case"OOOO":default:return"GMT"+_m(o,":")}},z:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+mm(o,":");case"zzzz":default:return"GMT"+_m(o,":")}},t:function(t,e,n,r){var i=r._originalDate||t,o=Math.floor(i.getTime()/1e3);return tm(o,e.length)},T:function(t,e,n,r){var i=r._originalDate||t,o=i.getTime();return tm(o,e.length)}};function mm(t,e){var n=t>0?"-":"+",r=Math.abs(t),i=Math.floor(r/60),o=r%60;if(0===o)return n+String(i);var a=e||"";return n+String(i)+a+tm(o,2)}function ym(t,e){if(t%60===0){var n=t>0?"-":"+";return n+tm(Math.abs(t)/60,2)}return _m(t,e)}function _m(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t),o=tm(Math.floor(i/60),2),a=tm(i%60,2);return r+o+n+a}var bm=gm;function wm(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}}function Om(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}}function xm(t,e){var n,r=t.match(/(P+)(p+)?/),i=r[1],o=r[2];if(!o)return wm(t,e);switch(i){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;case"PPPP":default:n=e.dateTime({width:"full"});break}return n.replace("{{date}}",wm(i,e)).replace("{{time}}",Om(o,e))}var Em={p:Om,P:xm},Tm=Em,Sm=6e4;function Mm(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());e.setSeconds(0,0);var r=e.getTime()%Sm;return n*Sm+r}var Cm=["D","DD"],Am=["YY","YYYY"];function Lm(t){return-1!==Cm.indexOf(t)}function Dm(t){return-1!==Am.indexOf(t)}function km(t){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` for formatting years; see: https://git.io/fxCyr");if("YY"===t)throw new RangeError("Use `yy` instead of `YY` for formatting years; see: https://git.io/fxCyr");if("D"===t)throw new RangeError("Use `d` instead of `D` for formatting days of the month; see: https://git.io/fxCyr");if("DD"===t)throw new RangeError("Use `dd` instead of `DD` for formatting days of the month; see: https://git.io/fxCyr")}var Pm=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Rm=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Im=/^'([^]*?)'?$/,Nm=/''/g,jm=/[a-zA-Z]/;function Bm(t,e,n){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var r=String(e),i=n||{},o=i.locale||Xg,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:Kg(a),u=null==i.firstWeekContainsDate?s:Kg(i.firstWeekContainsDate);if(!(u>=1&&u<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var l=o.options&&o.options.weekStartsOn,c=null==l?0:Kg(l),h=null==i.weekStartsOn?c:Kg(i.weekStartsOn);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!o.localize)throw new RangeError("locale must contain localize property");if(!o.formatLong)throw new RangeError("locale must contain formatLong property");var f=lg(t);if(!cg(f))throw new RangeError("Invalid time value");var p=Mm(f),d=Jg(f,p),v={firstWeekContainsDate:u,weekStartsOn:h,locale:o,_originalDate:f},g=r.match(Rm).map((function(t){var e=t[0];if("p"===e||"P"===e){var n=Tm[e];return n(t,o.formatLong,v)}return t})).join("").match(Pm).map((function(t){if("''"===t)return"'";var e=t[0];if("'"===e)return Um(t);var n=bm[e];if(n)return!i.useAdditionalWeekYearTokens&&Dm(t)&&km(t),!i.useAdditionalDayOfYearTokens&&Lm(t)&&km(t),n(d,t,o.localize,v);if(e.match(jm))throw new RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return t})).join("");return g}function Um(t){return t.match(Im)[1].replace(Nm,"'")}function Vm(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n>r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}var Hm=[["15seconds",15e3],["minute",6e4],["30minutes",18e5],["hourly",36e5],["daily",864e5],["monthly",2592e6],["quarterly",7776e6],["yearly",31104e6]];function Gm(t,e,n,r,i){var o=0===e,a=2===Number(Bm(new Date(t),"c")),s=1===Number(Bm(new Date(t),"q")),u=0!==e?n[e-1]:null;switch(r){case"15seconds":return o||Ym(t)||Zm(t,u)||Xm(t);case"minute":return o||Ym(t)||Zm(t,u)||Xm(t);case"30minutes":return o||Ym(t)||Zm(t,u)||Xm(t);case"hourly":return o||Ym(t)||Zm(t,u)||Xm(t);case"daily":return i?o||a||Xm(t):o||Zm(t,u)||Xm(t);case"monthly":return o||Xm(t);case"quarterly":return o||s;case"yearly":return!1;default:throw new Error(r+" is not a valid time interval.")}}function zm(t,e,n,r,i){var o=i.showDayName,a="daily"===r&&o?"weekly":r,s=new Date(t),u=Dd(i,"timeIntervalFormats")[a],l=Dd(u,"primary"),c=Dd(u,"secondary"),h=Gm(t,e,n,r,o)?l:c;"15seconds"===r&&0!==s.getMilliseconds()&&(h=h.replace("pp","h:mm:ss.SSS a"));var f=i.localeObject;return Bm(s,h,{locale:f})}function Fm(t){var e=new Date(t);return{M:e.getMonth()+1,d:e.getDate(),H:e.getHours(),m:e.getMinutes(),s:e.getSeconds()}}function Wm(t){if(t)return t.slice(1).map((function(e,n){return e-t[n]}))}function qm(t){var e=Hm.reduce((function(e,n,r){n[0];var i=n[1],o=Hm[e][1],a=Math.abs(o-t),s=Math.abs(i-t);return a<s?e:r}),0);return Hm[e][0]}function $m(t){if(1===t.length)return"15seconds";var e=Wm(t),n=Vm(e);return qm(n)}function Ym(t){var e=Fm(t),n=e.s,r=e.m,i=e.H;return 0===i&&0===r&&0===n}function Zm(t,e){var n=Fm(t).M,r=Fm(e).M;return n!==r}function Xm(t){var e=Fm(t),n=e.M,r=e.d,i=e.s,o=e.m,a=e.H;return 1===n&&1===r&&0===a&&0===o&&0===i}function Km(t){return void 0===t?"":t.toISOString()}var Qm=function(){return Qm=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},Qm.apply(this,arguments)},Jm=function(){function t(t){this.state={options:{}},this.colorScale={},this.colorClassNames={},this.services=t}return t.prototype.getAllDataFromDomain=function(t){if(!this.getData())return null;var e=this.getOptions(),n=this.getData(),r=this.getDataGroups(),i=Dd(e,"data").groupMapsTo,o=Dd(e,"axes");return t&&(n=n.filter((function(e){return t.includes(e[i])}))),o&&Object.keys(o).forEach((function(t){var e=o[t].mapsTo,r=o[t].scaleType;if(r!==G.LINEAR&&r!==G.LOG||(n=n.map((function(t){var n;return Qm(Qm({},t),(n={},n[e]=null===t[e]?t[e]:Number(t[e]),n))}))),e&&o[t].domain)if(r===G.LABELS)n=n.filter((function(n){return o[t].domain.includes(n[e])}));else{var i=o[t].domain,a=i[0],s=i[1];n=n.filter((function(t){return!(e in t)||t[e]>=a&&t[e]<=s}))}})),n.filter((function(t){return r.find((function(e){return e.name===t[i]}))}))},t.prototype.getDisplayData=function(t){if(!this.get("data"))return null;var e=Ot.items.status.ACTIVE,n=this.getDataGroups(t),r=this.getOptions().data.groupMapsTo,i=this.getAllDataFromDomain(t);return i.filter((function(t){return n.find((function(n){return n.name===t[r]&&n.status===e}))}))},t.prototype.getData=function(){return this.get("data")},t.prototype.isDataEmpty=function(){return!this.getData().length},t.prototype.setData=function(t){var e=this.sanitize(Od(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),e},t.prototype.getDataGroups=function(t){var e=Dd(this.getOptions(),"data","loading");return e?[]:t?this.get("dataGroups").filter((function(e){return t.includes(e.name)})):this.get("dataGroups")},t.prototype.getActiveDataGroups=function(t){var e=Ot.items.status.ACTIVE;return this.getDataGroups(t).filter((function(t){return t.status===e}))},t.prototype.getDataGroupNames=function(t){var e=this.getDataGroups(t);return e.map((function(t){return t.name}))},t.prototype.getActiveDataGroupNames=function(t){var e=this.getActiveDataGroups(t);return e.map((function(t){return t.name}))},t.prototype.aggregateBinDataByGroup=function(t){return El(t,"group")},t.prototype.getBinConfigurations=function(){var t=this,e=this.getDisplayData(),n=this.getOptions(),r=this.services.cartesianScales.getMainXAxisPosition(),i=this.services.cartesianScales.getDomainIdentifier(),o=n.axes[r],a=n.data.groupMapsTo,s=o.bins,u=void 0===s?wt.defaultBins:s,l=Array.isArray(u),c=ug().value((function(t){return t[i]})).thresholds(u)(e);if(l)c[c.length-1].x1=u[u.length-1];else{var h=c[0].x1-c[0].x0;c[c.length-1].x1=+c[c.length-1].x0+h}var f=l?[u[0],u[u.length-1]]:[c[0].x0,c[c.length-1].x1],p=Array.from(new Set(e.map((function(t){return t[a]})))),d=[];return c.forEach((function(e){var n=e.x0+"-"+e.x1,r=t.aggregateBinDataByGroup(e);p.forEach((function(t){d.push({group:t,key:n,value:r[t]||0,bin:e.x0})}))})),{bins:c,binsDomain:f}},t.prototype.getBinnedStackedData=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getActiveDataGroupNames(),r=this.getBinConfigurations().bins,i=this.getDataValuesGroupedByKeys({bins:r});return Nv().keys(n)(i).map((function(t,r){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(i){var o=t[i];return o[e]=n[r],o}))}))},t.prototype.getGroupedData=function(t){var e=this.getDisplayData(t),n={},r=this.getOptions().data.groupMapsTo;return e.map((function(t){var e=t[r];null!==n[e]&&void 0!==n[e]?n[e].push(t):n[e]=[t]})),Object.keys(n).map((function(t){return{name:t,data:n[t]}}))},t.prototype.getStackKeys=function(t){var e,n=this,r=void 0===t?{bins:null,groups:null}:t,i=r.bins,o=void 0===i?null:i,a=r.groups,s=void 0===a?null:a,u=this.getOptions(),l=this.getDisplayData(s);e=o?o.map((function(t){return t.x0+"-"+t.x1})):xd(l.map((function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return t[e]instanceof Date?Km(t[e]):t[e]&&"function"===typeof t[e].toString?t[e].toString():t[e]})));var c=this.services.cartesianScales.domainAxisPosition,h=u.axes[c].scaleType;return h===G.TIME?e.sort((function(t,e){var n=new Date(t),r=new Date(e);return n-r})):h!==G.LOG&&h!==G.LINEAR||e.sort((function(t,e){return t-e})),e},t.prototype.getDataValuesGroupedByKeys=function(t){var e=this,n=t.bins,r=void 0===n?null:n,i=t.groups,o=void 0===i?null:i,a=this.getOptions(),s=a.data.groupMapsTo,u=this.getDisplayData(o),l=this.getDataGroupNames(),c=this.getStackKeys({bins:r,groups:o});return r?c.map((function(t){var e=t.split("-"),n=e[0],i=e[1],o={x0:n,x1:i},a=r.find((function(t){return t.x0.toString()===n.toString()}));return l.forEach((function(t){o[t]=a.filter((function(e){return e[s]===t})).length})),o})):c.map((function(t){var n={sharedStackKey:t};return l.forEach((function(r){var i=u.find((function(n){var i=e.services.cartesianScales.getDomainIdentifier(n);return n[s]===r&&n.hasOwnProperty(i)&&(n[i]instanceof Date?Km(n[i])===t:n[i].toString()===t)})),o=e.services.cartesianScales.getRangeIdentifier(n);n[r]=i?i[o]:null})),n}))},t.prototype.getStackedData=function(t){var e=t.percentage,n=void 0!==e&&e,r=t.groups,i=void 0===r?null:r,o=t.divergent,a=void 0!==o&&o,s=this.getOptions(),u=s.data.groupMapsTo,l=this.getActiveDataGroupNames(i),c=this.getDataValuesGroupedByKeys({groups:i});if(n){var h=Jh(c.map((function(t){return[t.sharedStackKey,0]})));c.forEach((function(t){l.forEach((function(e){h[t.sharedStackKey]+=t[e]}))})),c.forEach((function(t){l.forEach((function(e){h[t.sharedStackKey]?t[e]=t[e]/h[t.sharedStackKey]*100:t[e]=0}))}))}var f=a?Nv().offset(jv):Nv();return f.keys(l)(c).map((function(t,e){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(n){var r=t[n];return r[u]=l[e],r}))}))},t.prototype.getOptions=function(){return this.state.options},t.prototype.set=function(t,e){this.state=Object.assign({},this.state,t);var n=Object.assign({skipUpdate:!1,animate:!0},e);n.skipUpdate||this.update(n.animate)},t.prototype.get=function(t){return t?this.state[t]:this.state},t.prototype.setOptions=function(t){var e=this.getOptions();Ld(e,t),this.set({options:na(e,t)})},t.prototype.update=function(t){void 0===t&&(t=!0),this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(ft.Model.UPDATE,{animate:t}))},t.prototype.toggleDataLabel=function(t){var e=Ot.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.getDataGroups(),o=i.some((function(t){return t.status===r})),a=i.filter((function(t){return t.status===n}));if(o)if(1===a.length&&a[0].name===t)i.forEach((function(t,e){i[e].status=n}));else{var s=i.findIndex((function(e){return e.name===t}));i[s].status=i[s].status===r?n:r}else i.forEach((function(e,o){i[o].status=e.name===t?n:r}));var u=i.filter((function(t){return t.status===n})),l=this.getOptions(),c=i.some((function(t){return t.status===r}));l.data.selectedGroups=c?u.map((function(t){return t.name})):[],this.services.events.dispatchEvent(ft.Legend.ITEMS_UPDATE,{dataGroups:i}),this.set({dataGroups:i})},t.prototype.getIsFilled=function(t,e,n,r){var i=this.getOptions();return i.getIsFilled?i.getIsFilled(t,e,n,r):r},t.prototype.getFillColor=function(t,e,n){var r=this.getOptions(),i=Dd(this.colorScale,t);return r.getFillColor?r.getFillColor(t,e,n,i):i},t.prototype.getStrokeColor=function(t,e,n){var r=this.getOptions(),i=Dd(this.colorScale,t);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.isUserProvidedColorScaleValid=function(){var t=Dd(this.getOptions(),"color","scale"),e=this.getDataGroups();return null!=t&&0!=Object.keys(t).length&&e.some((function(e){return Object.keys(t).includes(e.name)}))},t.prototype.getColorClassName=function(t){var e=this.colorClassNames(t.dataGroupName),n=t.originalClassName;return t.classNameTypes.forEach((function(r){return n=t.originalClassName?n+" "+r+"-"+e:r+"-"+e})),n},t.prototype.getStatus=function(){return null},t.prototype.getAllDataGroupsNames=function(){return this.allDataGroups},t.prototype.transformToTabularData=function(t){console.warn("We've updated the charting data format to be tabular by default. The current format you're using is deprecated and will be removed in v1.0, read more here https://carbon-design-system.github.io/carbon-charts/?path=/story/docs-tutorials--tabular-data-format");var e=[],n=t.datasets,r=t.labels;return n.forEach((function(t){t.data.forEach((function(n,i){var o,a=Dd(t,"label");if(null===a){var s=Dd(r,i);o=s||"Ungrouped"}else o=a;var u={group:o,key:r[i]};isNaN(n)?(u["value"]=n.value,u["date"]=n.date):u["value"]=n,e.push(u)}))})),e},t.prototype.getTabularDataArray=function(){return[]},t.prototype.exportToCSV=function(){var t=this.getTabularDataArray().map((function(t){return t.map((function(t){return'"'+("–"===t?"–":t)+'"'}))})),e="",n="";t.forEach((function(r,i){n=r.join(","),e+=i<t.length?n+"\n":n}));var r=this.getOptions(),i="myChart",o=Dd(r,"fileDownload","fileName");"function"===typeof o&&(i=o("csv")),this.services.files.downloadCSV(e,i+".csv")},t.prototype.getTabularData=function(t){return Array.isArray(t)?t:this.transformToTabularData(t)},t.prototype.sanitize=function(t){return t=this.getTabularData(t),t},t.prototype.updateAllDataGroups=function(){var t=this;this.allDataGroups?this.getDataGroupNames().forEach((function(e){-1===t.allDataGroups.indexOf(e)&&t.allDataGroups.push(e)})):this.allDataGroups=this.getDataGroupNames()},t.prototype.generateDataGroups=function(t){var e=this.getOptions().data.groupMapsTo,n=Ot.items.status,r=n.ACTIVE,i=n.DISABLED,o=this.getOptions(),a=xd(t.map((function(t){return t[e]})));if(o.data.selectedGroups.length){var s=o.data.selectedGroups.every((function(t){return a.includes(t)}));s||(o.data.selectedGroups=[])}var u=function(t){return!o.data.selectedGroups.length||o.data.selectedGroups.includes(t)?r:i};return a.map((function(t){return{name:t,status:u(t)}}))},t.prototype.setCustomColorScale=function(){var t=this;if(this.isUserProvidedColorScaleValid()){var e=this.getOptions(),n=Dd(e,"color","scale");Object.keys(n).forEach((function(e){t.allDataGroups.includes(e)||console.warn('"'+e+'" does not exist in data groups.')}));var r=this.allDataGroups.filter((function(t){return n[t]}));r.forEach((function(e){return t.colorScale[e]=n[e]}))}},t.prototype.setColorClassNames=function(){var t=Dd(this.getOptions(),"color","pairing"),e=Dd(t,"numberOfVariants");(!e||e<this.allDataGroups.length)&&(e=this.allDataGroups.length);var n=Dd(t,"option"),r=_t.pairingOptions,i=e>5?14:e;n=n<=r[i+"-color"]?n:1;var o=this.allDataGroups.map((function(t,e){return i+"-"+n+"-"+(e%14+1)}));this.colorClassNames=Cv().range(o).domain(this.allDataGroups)},t}(),ty=function(){function t(t,e){this.model=t,this.services=e,this.init()}return t.prototype.init=function(){},t.prototype.update=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t}();function ey(){}var ny=function(t){return null==t?ey:function(){return this.querySelector(t)}},ry=function(t){"function"!==typeof t&&(t=ny(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,l=r[i]=new Array(u),c=0;c<u;++c)(o=s[c])&&(a=t.call(o,o.__data__,c,s))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new K_(r,this._parents)};function iy(t){return null==t?[]:Array.isArray(t)?t:Array.from(t)}function oy(){return[]}var ay=function(t){return null==t?oy:function(){return this.querySelectorAll(t)}};function sy(t){return function(){return iy(t.apply(this,arguments))}}var uy=function(t){t="function"===typeof t?sy(t):ay(t);for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new K_(r,i)},ly=function(t){return function(){return this.matches(t)}};function cy(t){return function(e){return e.matches(t)}}var hy=Array.prototype.find;function fy(t){return function(){return hy.call(this.children,t)}}function py(){return this.firstElementChild}var dy=function(t){return this.select(null==t?py:fy("function"===typeof t?t:cy(t)))},vy=Array.prototype.filter;function gy(){return Array.from(this.children)}function my(t){return function(){return vy.call(this.children,t)}}var yy=function(t){return this.selectAll(null==t?gy:my("function"===typeof t?t:cy(t)))},_y=function(t){"function"!==typeof t&&(t=ly(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new K_(r,this._parents)},by=function(t){return new Array(t.length)},wy=function(){return new K_(this._enter||this._groups.map(by),this._parents)};function Oy(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Oy.prototype={constructor:Oy,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var xy=function(t){return function(){return t}};function Ey(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new Oy(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function Ty(t,e,n,r,i,o,a){var s,u,l,c=new Map,h=e.length,f=o.length,p=new Array(h);for(s=0;s<h;++s)(u=e[s])&&(p[s]=l=a.call(u,u.__data__,s,e)+"",c.has(l)?i[s]=u:c.set(l,u));for(s=0;s<f;++s)l=a.call(t,o[s],s,o)+"",(u=c.get(l))?(r[s]=u,u.__data__=o[s],c.delete(l)):n[s]=new Oy(t,o[s]);for(s=0;s<h;++s)(u=e[s])&&c.get(p[s])===u&&(i[s]=u)}function Sy(t){return t.__data__}var My=function(t,e){if(!arguments.length)return Array.from(this,Sy);var n=e?Ty:Ey,r=this._parents,i=this._groups;"function"!==typeof t&&(t=xy(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),l=0;l<o;++l){var c=r[l],h=i[l],f=h.length,p=Cy(t.call(c,c&&c.__data__,l,r)),d=p.length,v=s[l]=new Array(d),g=a[l]=new Array(d),m=u[l]=new Array(f);n(c,h,v,g,m,p,e);for(var y,_,b=0,w=0;b<d;++b)if(y=v[b]){b>=w&&(w=b+1);while(!(_=g[w])&&++w<d);y._next=_||null}}return a=new K_(a,r),a._enter=s,a._exit=u,a};function Cy(t){return"object"===typeof t&&"length"in t?t:Array.from(t)}var Ay=function(){return new K_(this._exit||this._groups.map(by),this._parents)},Ly=function(t,e,n){var r=this.enter(),i=this,o=this.exit();return"function"===typeof t?(r=t(r),r&&(r=r.selection())):r=r.append(t+""),null!=e&&(i=e(i),i&&(i=i.selection())),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},Dy=function(t){for(var e=t.selection?t.selection():t,n=this._groups,r=e._groups,i=n.length,o=r.length,a=Math.min(i,o),s=new Array(i),u=0;u<a;++u)for(var l,c=n[u],h=r[u],f=c.length,p=s[u]=new Array(f),d=0;d<f;++d)(l=c[d]||h[d])&&(p[d]=l);for(;u<i;++u)s[u]=n[u];return new K_(s,this._parents)},ky=function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},Py=function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Ry);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new K_(i,this._parents).order()};function Ry(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}var Iy=function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},Ny=function(){return Array.from(this)},jy=function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},By=function(){let t=0;for(const e of this)++t;return t},Uy=function(){return!this.node()},Vy=function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},Hy="http://www.w3.org/1999/xhtml",Gy={svg:"http://www.w3.org/2000/svg",xhtml:Hy,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},zy=function(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),Gy.hasOwnProperty(e)?{space:Gy[e],local:t}:t};function Fy(t){return function(){this.removeAttribute(t)}}function Wy(t){return function(){this.removeAttributeNS(t.space,t.local)}}function qy(t,e){return function(){this.setAttribute(t,e)}}function $y(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Yy(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Zy(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}var Xy=function(t,e){var n=zy(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?Wy:Fy:"function"===typeof e?n.local?Zy:Yy:n.local?$y:qy)(n,e))},Ky=function(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView};function Qy(t){return function(){this.style.removeProperty(t)}}function Jy(t,e,n){return function(){this.style.setProperty(t,e,n)}}function t_(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}var e_=function(t,e,n){return arguments.length>1?this.each((null==e?Qy:"function"===typeof e?t_:Jy)(t,e,null==n?"":n)):n_(this.node(),t)};function n_(t,e){return t.style.getPropertyValue(e)||Ky(t).getComputedStyle(t,null).getPropertyValue(e)}function r_(t){return function(){delete this[t]}}function i_(t,e){return function(){this[t]=e}}function o_(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}var a_=function(t,e){return arguments.length>1?this.each((null==e?r_:"function"===typeof e?o_:i_)(t,e)):this.node()[t]};function s_(t){return t.trim().split(/^|\s+/)}function u_(t){return t.classList||new l_(t)}function l_(t){this._node=t,this._names=s_(t.getAttribute("class")||"")}function c_(t,e){var n=u_(t),r=-1,i=e.length;while(++r<i)n.add(e[r])}function h_(t,e){var n=u_(t),r=-1,i=e.length;while(++r<i)n.remove(e[r])}function f_(t){return function(){c_(this,t)}}function p_(t){return function(){h_(this,t)}}function d_(t,e){return function(){(e.apply(this,arguments)?c_:h_)(this,t)}}l_.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var v_=function(t,e){var n=s_(t+"");if(arguments.length<2){var r=u_(this.node()),i=-1,o=n.length;while(++i<o)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"===typeof e?d_:e?f_:p_)(n,e))};function g_(){this.textContent=""}function m_(t){return function(){this.textContent=t}}function y_(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}var __=function(t){return arguments.length?this.each(null==t?g_:("function"===typeof t?y_:m_)(t)):this.node().textContent};function b_(){this.innerHTML=""}function w_(t){return function(){this.innerHTML=t}}function O_(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}var x_=function(t){return arguments.length?this.each(null==t?b_:("function"===typeof t?O_:w_)(t)):this.node().innerHTML};function E_(){this.nextSibling&&this.parentNode.appendChild(this)}var T_=function(){return this.each(E_)};function S_(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}var M_=function(){return this.each(S_)};function C_(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===Hy&&e.documentElement.namespaceURI===Hy?e.createElement(t):e.createElementNS(n,t)}}function A_(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}var L_=function(t){var e=zy(t);return(e.local?A_:C_)(e)},D_=function(t){var e="function"===typeof t?t:L_(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))};function k_(){return null}var P_=function(t,e){var n="function"===typeof t?t:L_(t),r=null==e?k_:"function"===typeof e?e:ny(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))};function R_(){var t=this.parentNode;t&&t.removeChild(this)}var I_=function(){return this.each(R_)};function N_(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function j_(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}var B_=function(t){return this.select(t?j_:N_)},U_=function(t){return arguments.length?this.property("__data__",t):this.node().__data__};function V_(t){return function(e){t.call(this,e,this.__data__)}}function H_(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function G_(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.options);++i?e.length=i:delete this.__on}}}function z_(t,e,n){return function(){var r,i=this.__on,o=V_(e);if(i)for(var a=0,s=i.length;a<s;++a)if((r=i[a]).type===t.type&&r.name===t.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),void(r.value=e);this.addEventListener(t.type,o,n),r={type:t.type,name:t.name,value:e,listener:o,options:n},i?i.push(r):this.__on=[r]}}var F_=function(t,e,n){var r,i,o=H_(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?z_:G_,r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value};function W_(t,e,n){var r=Ky(t),i=r.CustomEvent;"function"===typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function q_(t,e){return function(){return W_(this,t,e)}}function $_(t,e){return function(){return W_(this,t,e.apply(this,arguments))}}var Y_=function(t,e){return this.each(("function"===typeof e?$_:q_)(t,e))},Z_=function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r,i=t[e],o=0,a=i.length;o<a;++o)(r=i[o])&&(yield r)},X_=[null];function K_(t,e){this._groups=t,this._parents=e}function Q_(){return new K_([[document.documentElement]],X_)}function J_(){return this}K_.prototype=Q_.prototype={constructor:K_,select:ry,selectAll:uy,selectChild:dy,selectChildren:yy,filter:_y,data:My,enter:wy,exit:Ay,join:Ly,merge:Dy,selection:J_,order:ky,sort:Py,call:Iy,nodes:Ny,node:jy,size:By,empty:Uy,each:Vy,attr:Xy,style:e_,property:a_,classed:v_,text:__,html:x_,raise:T_,lower:M_,append:D_,insert:P_,remove:I_,clone:B_,datum:U_,on:F_,dispatch:Y_,[Symbol.iterator]:Z_};var tb=Q_,eb=function(t){return"string"===typeof t?new K_([[document.querySelector(t)]],[document.documentElement]):new K_([[t]],X_)},nb=n("2da1"),rb=n("69f2"),ib=n.n(rb),ob=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ab="DONT_STYLE_ME_css_styles_verifier",sb=function(t){function e(e,n){return t.call(this,e,n)||this}return ob(e,t),e.getHTMLElementSize=function(t){return{width:t.clientWidth,height:t.clientHeight}},e.getSVGElementSize=function(t,e){void 0===e&&(e={useAttrs:!1,useClientDimensions:!1,useBBox:!1,useBoundingRect:!1}),t.attr||(t=eb(t));var n,r,i,o,a={width:0,height:0},s=function(t){t&&Object.keys(a).forEach((function(e){if(t[e]){var n=t[e],r=parseFloat(n);n&&r>a[e]&&-1===(""+n).indexOf("%")&&(a[e]=r)}}))},u={width:t.attr("width"),height:t.attr("height")};try{n=t.node().getBBox(),r={width:n.width,height:n.height}}catch(h){}try{i=t.node().getBoundingClientRect(),o={width:i.width,height:i.height}}catch(h){}var l={width:t.node().clientWidth,height:t.node().clientHeight};if(e){if(e.useAttrs&&(s(u),a.width>0&&a.height>0))return a;if(e.useClientDimensions&&(s(l),a.width>0&&a.height>0))return l;if(e.useBBox&&(s(r),a.width>0&&a.height>0))return r;if(e.useBoundingRect&&(s(o),a.width>0&&a.height>0))return o}try{var c={width:Dd(t.node(),"width","baseVal","value"),height:Dd(t.node(),"height","baseVal","value")};s(c)}catch(h){s(l),s(r),s(u)}return a},e.appendOrSelect=function(t,e){var n=t.select(""+e);if(n.empty()){var r=e.split("#"),i=void 0,o=void 0;return 2===r.length?(i=r[0],r=r[1].split("."),o=r[0]):(r=e.split("."),i=r[0]),t.append(i).attr("id",o).attr("class",r.slice(1).join(" "))}return n},e.prototype.init=function(){this.styleHolderElement(),this.initializeID(),this.addMainContainer(),this.verifyCSSStylesBeingApplied(),this.model.getOptions().resizable&&this.addResizeListener(),this.addHolderListeners(),this.handleFullscreenChange()},e.prototype.getChartID=function(){return this.chartID},e.prototype.generateElementIDString=function(t){return"chart-"+this.chartID+"-"+t},e.prototype.initializeID=function(){this.chartID=Math.floor(281474976710656*(1+Math.random())).toString(16)},e.prototype.addMainContainer=function(){var t=this.model.getOptions(),e=Dd(t,"style","prefix"),n=eb(this.getHolder()).append("div").classed(dt+"--"+e+"--chart-wrapper",!0).attr("id","chart-"+this.getChartID()).style("height","100%").style("width","100%");n.append("g").attr("class",ab),this.mainContainer=n.node()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder(),e=this.model.getOptions(),n=e.width,r=e.height,i=e.theme;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r),eb(this.getHolder()).classed(dt+"--chart-holder",!0).attr("data-carbon-theme",i)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.exportToJPG=function(){var t=this,e=this.model.getOptions(),n=this.getHolder(),r=eb(n);r.classed("filled",!0),ib.a.toJpeg(this.getMainContainer(),{bgcolor:"undefined"!==typeof window?window.getComputedStyle(n).getPropertyValue("background-color"):void 0,quality:1,filter:function(t){return!t.classList||!t.classList.contains("cds--cc--toolbar")}}).then((function(n){var i="myChart",o=Dd(e,"fileDownload","fileName");"function"===typeof o&&(i=o("jpg")),t.services.files.downloadImage(n,i+".jpg"),r.classed("filled",!1)}))},e.prototype.exportToPNG=function(){var t=this,e=this.model.getOptions(),n=this.getHolder(),r=eb(n);r.classed("filled",!0),ib.a.toPng(this.getMainContainer(),{bgcolor:"undefined"!==typeof window?window.getComputedStyle(n).getPropertyValue("background-color"):void 0,quality:1,filter:function(t){return!t.classList||!t.classList.contains("cds--cc--toolbar")}}).then((function(n){var i="myChart",o=Dd(e,"fileDownload","fileName");"function"===typeof o&&(i=o("png")),t.services.files.downloadImage(n,i+".png"),r.classed("filled",!1)})).catch((function(t){console.error("oops, something went wrong!",t)}))},e.prototype.toggleFullscreen=function(){var t=this.getHolder(),e=eb(t),n=e.classed("fullscreen");n&&(document.fullscreenElement||document["webkitFullscreenElement"]||document["mozFullScreenElement"]||document["msFullscreenElement"])?document.exitFullscreen?document.exitFullscreen():document["webkitExitFullscreen"]?document["webkitExitFullscreen"]():document["mozCancelFullScreen"]?document["mozCancelFullScreen"]():document["msExitFullscreen"]&&document["msExitFullscreen"]():t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},e.prototype.handleFullscreenChange=function(){var t=this;document.addEventListener("fullscreenchange",(function(){var e=eb(t.getHolder()),n=e.classed("fullscreen");e.classed("fullscreen",!n)}))},e.prototype.verifyCSSStylesBeingApplied=function(){var t=this;setTimeout((function(){var e=eb(t.mainContainer).select("g."+ab).node(),n=getComputedStyle(e);"hidden"===n.getPropertyValue("overflow")&&"0"===n.getPropertyValue("opacity")||console.error("Missing CSS styles for Carbon Charts. Please read the Carbon Charts getting started guide.")}))},e.prototype.setSVGMaxHeight=function(){if(!this.model.getOptions().height){var t=e.getSVGElementSize(eb(this.mainContainer),{useBBox:!0}).height,n=eb(this.mainContainer).attr("class"),r=eb(this.mainContainer).selectAll("."+n+" > svg"),i=0;r.nodes().forEach((function(t){i+=Number(e.getSVGElementSize(eb(t),{useBBox:!0}).height)})),i<=t?eb(this.mainContainer).attr("height",i):eb(this.mainContainer).attr("height","100%")}},e.prototype.getMainContainer=function(){return this.mainContainer},e.prototype.addHolderListeners=function(){var t=this,e=this.getHolder();e&&eb(e).on("mouseover",(function(){t.services.events.dispatchEvent(ft.Chart.MOUSEOVER)})).on("mouseout",(function(){t.services.events.dispatchEvent(ft.Chart.MOUSEOUT)}))},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=Te((function(i,o){e&&(Math.abs(n-e.clientWidth)>1||Math.abs(r-e.clientHeight)>1)&&(n=e.clientWidth,r=e.clientHeight,t.services.events.dispatchEvent(ft.Chart.RESIZE))}),12.5),o=new nb["a"](i);o.observe(e)}},e}(ty),ub=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),lb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return ub(e,t),e.prototype.init=function(){this.documentFragment=document.createDocumentFragment()},e.prototype.addEventListener=function(t,e){this.documentFragment.addEventListener(t,e)},e.prototype.removeEventListener=function(t,e){this.documentFragment.removeEventListener(t,e)},e.prototype.dispatchEvent=function(t,e){var n;e?n=new CustomEvent(t,{detail:e}):(n=document.createEvent("Event"),n.initEvent(t,!1,!0)),this.documentFragment.dispatchEvent(n)},e}(ty),cb=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),hb=function(t){function e(e,n){return t.call(this,e,n)||this}return cb(e,t),e.prototype.downloadCSV=function(t,e){var n=document.createElement("a"),r="text/csv;encoding:utf-8";if(navigator["msSaveBlob"])navigator["msSaveBlob"](new Blob([t],{type:r}),e);else if(URL&&"download"in n){var i=URL.createObjectURL(new Blob([t],{type:r}));n.href=i,n.setAttribute("download",e),document.body.appendChild(n),n.click(),document.body.removeChild(n),URL.revokeObjectURL(i)}else location.href="data:application/octet-stream,"+encodeURIComponent(t)},e.prototype.downloadImage=function(t,e){var n=document.createElement("a");n.download=e,n.href=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)},e}(ty),fb=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),pb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return fb(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener(ft.Model.UPDATE,(function(){t.pendingTransitions={}}))},e.prototype.setupTransition=function(t){var e=this,n=t.transition,r=t.name,i=t.animate;return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),!1===this.model.getOptions().animations||!1===i?n.duration(0):n.duration(Dd(Dt,r,"duration")||Dt.default.duration)},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(ty),db=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),vb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return db(e,t),e.appendOrUpdateLinearGradient=function(t){var e=t.svg.select("defs linearGradient#"+t.id);e.empty()&&(e=t.svg.append("defs").append("linearGradient").attr("id",t.id).attr("x1",t.x1).attr("x2",t.x2).attr("y1",t.y1).attr("y2",t.y2)),e.selectAll("stop").remove(),e.selectAll("stop").data(t.stops).enter().append("stop").attr("offset",(function(t){return t.offset})).style("stop-color",(function(t){return t.color})).style("stop-opacity",(function(t){return t.opacity}))},e.getOffsetRatio=function(t){var e=(100*Math.abs(t[1])/Math.abs(t[0]-t[1])).toFixed(2)+"%";return e},e.getStops=function(t,n){var r=t[0]<0&&t[1]>0,i=[{offset:"0%",color:n,opacity:"0.6"},{offset:"80%",color:n,opacity:"0"}];return r&&(i=[{offset:"0%",color:n,opacity:"0.6"},{offset:e.getOffsetRatio(t),color:n,opacity:"0"},{offset:"100%",color:n,opacity:"0.6"}]),i},e}(ty);const gb=1e3,mb=60*gb,yb=60*mb,_b=24*yb,bb=7*_b,wb=30*_b,Ob=365*_b,xb=new Date,Eb=new Date;function Tb(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=e=>(t(e=new Date(+e)),e),i.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),i.round=t=>{const e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=(t,n)=>(e(t=new Date(+t),null==n?1:Math.floor(n)),t),i.range=(n,r,o)=>{const a=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r)||!(o>0))return a;let s;do{a.push(s=new Date(+n)),e(n,o),t(n)}while(s<n&&n<r);return a},i.filter=n=>Tb(e=>{if(e>=e)while(t(e),!n(e))e.setTime(e-1)},(t,r)=>{if(t>=t)if(r<0)while(++r<=0)while(e(t,-1),!n(t));else while(--r>=0)while(e(t,1),!n(t));}),n&&(i.count=(e,r)=>(xb.setTime(+e),Eb.setTime(+r),t(xb),t(Eb),Math.floor(n(xb,Eb))),i.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?e=>r(e)%t===0:e=>i.count(0,e)%t===0):i:null)),i}const Sb=Tb(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Sb.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?Tb(e=>{e.setTime(Math.floor(e/t)*t)},(e,n)=>{e.setTime(+e+n*t)},(e,n)=>(n-e)/t):Sb:null);Sb.range;const Mb=Tb(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*gb)},(t,e)=>(e-t)/gb,t=>t.getUTCSeconds()),Cb=(Mb.range,Tb(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*gb)},(t,e)=>{t.setTime(+t+e*mb)},(t,e)=>(e-t)/mb,t=>t.getMinutes())),Ab=(Cb.range,Tb(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*mb)},(t,e)=>(e-t)/mb,t=>t.getUTCMinutes())),Lb=(Ab.range,Tb(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*gb-t.getMinutes()*mb)},(t,e)=>{t.setTime(+t+e*yb)},(t,e)=>(e-t)/yb,t=>t.getHours())),Db=(Lb.range,Tb(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*yb)},(t,e)=>(e-t)/yb,t=>t.getUTCHours())),kb=(Db.range,Tb(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*mb)/_b,t=>t.getDate()-1)),Pb=(kb.range,Tb(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_b,t=>t.getUTCDate()-1)),Rb=(Pb.range,Tb(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_b,t=>Math.floor(t/_b)));Rb.range;function Ib(t){return Tb(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(t,e)=>{t.setDate(t.getDate()+7*e)},(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*mb)/bb)}const Nb=Ib(0),jb=Ib(1),Bb=Ib(2),Ub=Ib(3),Vb=Ib(4),Hb=Ib(5),Gb=Ib(6);Nb.range,jb.range,Bb.range,Ub.range,Vb.range,Hb.range,Gb.range;function zb(t){return Tb(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)},(t,e)=>(e-t)/bb)}const Fb=zb(0),Wb=zb(1),qb=zb(2),$b=zb(3),Yb=zb(4),Zb=zb(5),Xb=zb(6),Kb=(Fb.range,Wb.range,qb.range,$b.range,Yb.range,Zb.range,Xb.range,Tb(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear()),t=>t.getMonth())),Qb=(Kb.range,Tb(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear()),t=>t.getUTCMonth())),Jb=(Qb.range,Tb(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear()));Jb.every=t=>isFinite(t=Math.floor(t))&&t>0?Tb(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,n)=>{e.setFullYear(e.getFullYear()+n*t)}):null;Jb.range;const tw=Tb(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());tw.every=t=>isFinite(t=Math.floor(t))&&t>0?Tb(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)}):null;tw.range;function ew(t,e,n,r,i,o){const a=[[Mb,1,gb],[Mb,5,5*gb],[Mb,15,15*gb],[Mb,30,30*gb],[o,1,mb],[o,5,5*mb],[o,15,15*mb],[o,30,30*mb],[i,1,yb],[i,3,3*yb],[i,6,6*yb],[i,12,12*yb],[r,1,_b],[r,2,2*_b],[n,1,bb],[e,1,wb],[e,3,3*wb],[t,1,Ob]];function s(t,e,n){const r=e<t;r&&([t,e]=[e,t]);const i=n&&"function"===typeof n.range?n:u(t,e,n),o=i?i.range(t,+e+1):[];return r?o.reverse():o}function u(e,n,r){const i=Math.abs(n-e)/r,o=Gv(([,,t])=>t).right(a,i);if(o===a.length)return t.every(ig(e/Ob,n/Ob,r));if(0===o)return Sb.every(Math.max(ig(e,n,r),1));const[s,u]=a[i/a[o-1][2]<a[o][2]/i?o-1:o];return s.every(u)}return[s,u]}const[nw,rw]=ew(tw,Qb,Fb,Rb,Db,Ab),[iw,ow]=ew(Jb,Kb,Nb,kb,Lb,Cb);function aw(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function sw(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function uw(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function lw(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,l=yw(i),c=_w(i),h=yw(o),f=_w(o),p=yw(a),d=_w(a),v=yw(s),g=_w(s),m=yw(u),y=_w(u),_={a:P,A:R,b:I,B:N,c:null,d:Vw,e:Vw,f:Ww,g:nO,G:iO,H:Hw,I:Gw,j:zw,L:Fw,m:qw,M:$w,p:j,q:B,Q:MO,s:CO,S:Yw,u:Zw,U:Xw,V:Qw,w:Jw,W:tO,x:null,X:null,y:eO,Y:rO,Z:oO,"%":SO},b={a:U,A:V,b:H,B:G,c:null,d:aO,e:aO,f:hO,g:OO,G:EO,H:sO,I:uO,j:lO,L:cO,m:fO,M:pO,p:z,q:F,Q:MO,s:CO,S:dO,u:vO,U:gO,V:yO,w:_O,W:bO,x:null,X:null,y:wO,Y:xO,Z:TO,"%":SO},w={a:S,A:M,b:C,B:A,c:L,d:Lw,e:Lw,f:Nw,g:Sw,G:Tw,H:kw,I:kw,j:Dw,L:Iw,m:Aw,M:Pw,p:T,q:Cw,Q:Bw,s:Uw,S:Rw,u:ww,U:Ow,V:xw,w:bw,W:Ew,x:D,X:k,y:Sw,Y:Tw,Z:Mw,"%":jw};function O(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;n instanceof Date||(n=new Date(+n));while(++s<l)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=fw[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function x(t,e){return function(n){var r,i,o=uw(1900,void 0,1),a=E(o,t,n+="",0);if(a!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(r=sw(uw(o.y,0,1)),i=r.getUTCDay(),r=i>4||0===i?Wb.ceil(r):Wb(r),r=Pb.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(r=aw(uw(o.y,0,1)),i=r.getDay(),r=i>4||0===i?jb.ceil(r):jb(r),r=kb.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?sw(uw(o.y,0,1)).getUTCDay():aw(uw(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,sw(o)):aw(o)}}function E(t,e,n,r){var i,o,a=0,s=e.length,u=n.length;while(a<s){if(r>=u)return-1;if(i=e.charCodeAt(a++),37===i){if(i=e.charAt(a++),o=w[i in fw?e.charAt(a++):i],!o||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function T(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c.get(r[0].toLowerCase()),n+r[0].length):-1}function S(t,e,n){var r=p.exec(e.slice(n));return r?(t.w=d.get(r[0].toLowerCase()),n+r[0].length):-1}function M(t,e,n){var r=h.exec(e.slice(n));return r?(t.w=f.get(r[0].toLowerCase()),n+r[0].length):-1}function C(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=y.get(r[0].toLowerCase()),n+r[0].length):-1}function A(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=g.get(r[0].toLowerCase()),n+r[0].length):-1}function L(t,n,r){return E(t,e,n,r)}function D(t,e,r){return E(t,n,e,r)}function k(t,e,n){return E(t,r,e,n)}function P(t){return a[t.getDay()]}function R(t){return o[t.getDay()]}function I(t){return u[t.getMonth()]}function N(t){return s[t.getMonth()]}function j(t){return i[+(t.getHours()>=12)]}function B(t){return 1+~~(t.getMonth()/3)}function U(t){return a[t.getUTCDay()]}function V(t){return o[t.getUTCDay()]}function H(t){return u[t.getUTCMonth()]}function G(t){return s[t.getUTCMonth()]}function z(t){return i[+(t.getUTCHours()>=12)]}function F(t){return 1+~~(t.getUTCMonth()/3)}return _.x=O(n,_),_.X=O(r,_),_.c=O(e,_),b.x=O(n,b),b.X=O(r,b),b.c=O(e,b),{format:function(t){var e=O(t+="",_);return e.toString=function(){return t},e},parse:function(t){var e=x(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=O(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=x(t+="",!0);return e.toString=function(){return t},e}}}var cw,hw,fw={"-":"",_:" ",0:"0"},pw=/^\s*\d+/,dw=/^%/,vw=/[\\^$*+?|[\]().{}]/g;function gw(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function mw(t){return t.replace(vw,"\\$&")}function yw(t){return new RegExp("^(?:"+t.map(mw).join("|")+")","i")}function _w(t){return new Map(t.map((t,e)=>[t.toLowerCase(),e]))}function bw(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function ww(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function Ow(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function xw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Ew(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function Tw(t,e,n){var r=pw.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function Sw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Mw(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Cw(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function Aw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function Lw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function Dw(t,e,n){var r=pw.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function kw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function Pw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function Rw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function Iw(t,e,n){var r=pw.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function Nw(t,e,n){var r=pw.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function jw(t,e,n){var r=dw.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function Bw(t,e,n){var r=pw.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function Uw(t,e,n){var r=pw.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function Vw(t,e){return gw(t.getDate(),e,2)}function Hw(t,e){return gw(t.getHours(),e,2)}function Gw(t,e){return gw(t.getHours()%12||12,e,2)}function zw(t,e){return gw(1+kb.count(Jb(t),t),e,3)}function Fw(t,e){return gw(t.getMilliseconds(),e,3)}function Ww(t,e){return Fw(t,e)+"000"}function qw(t,e){return gw(t.getMonth()+1,e,2)}function $w(t,e){return gw(t.getMinutes(),e,2)}function Yw(t,e){return gw(t.getSeconds(),e,2)}function Zw(t){var e=t.getDay();return 0===e?7:e}function Xw(t,e){return gw(Nb.count(Jb(t)-1,t),e,2)}function Kw(t){var e=t.getDay();return e>=4||0===e?Vb(t):Vb.ceil(t)}function Qw(t,e){return t=Kw(t),gw(Vb.count(Jb(t),t)+(4===Jb(t).getDay()),e,2)}function Jw(t){return t.getDay()}function tO(t,e){return gw(jb.count(Jb(t)-1,t),e,2)}function eO(t,e){return gw(t.getFullYear()%100,e,2)}function nO(t,e){return t=Kw(t),gw(t.getFullYear()%100,e,2)}function rO(t,e){return gw(t.getFullYear()%1e4,e,4)}function iO(t,e){var n=t.getDay();return t=n>=4||0===n?Vb(t):Vb.ceil(t),gw(t.getFullYear()%1e4,e,4)}function oO(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+gw(e/60|0,"0",2)+gw(e%60,"0",2)}function aO(t,e){return gw(t.getUTCDate(),e,2)}function sO(t,e){return gw(t.getUTCHours(),e,2)}function uO(t,e){return gw(t.getUTCHours()%12||12,e,2)}function lO(t,e){return gw(1+Pb.count(tw(t),t),e,3)}function cO(t,e){return gw(t.getUTCMilliseconds(),e,3)}function hO(t,e){return cO(t,e)+"000"}function fO(t,e){return gw(t.getUTCMonth()+1,e,2)}function pO(t,e){return gw(t.getUTCMinutes(),e,2)}function dO(t,e){return gw(t.getUTCSeconds(),e,2)}function vO(t){var e=t.getUTCDay();return 0===e?7:e}function gO(t,e){return gw(Fb.count(tw(t)-1,t),e,2)}function mO(t){var e=t.getUTCDay();return e>=4||0===e?Yb(t):Yb.ceil(t)}function yO(t,e){return t=mO(t),gw(Yb.count(tw(t),t)+(4===tw(t).getUTCDay()),e,2)}function _O(t){return t.getUTCDay()}function bO(t,e){return gw(Wb.count(tw(t)-1,t),e,2)}function wO(t,e){return gw(t.getUTCFullYear()%100,e,2)}function OO(t,e){return t=mO(t),gw(t.getUTCFullYear()%100,e,2)}function xO(t,e){return gw(t.getUTCFullYear()%1e4,e,4)}function EO(t,e){var n=t.getUTCDay();return t=n>=4||0===n?Yb(t):Yb.ceil(t),gw(t.getUTCFullYear()%1e4,e,4)}function TO(){return"+0000"}function SO(){return"%"}function MO(t){return+t}function CO(t){return Math.floor(+t/1e3)}function AO(t){return cw=lw(t),hw=cw.format,cw.parse,cw.utcFormat,cw.utcParse,cw}AO({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var LO=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function DO(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function kO(){}var PO=.7,RO=1/PO,IO="\\s*([+-]?\\d+)\\s*",NO="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",jO="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",BO=/^#([0-9a-f]{3,8})$/,UO=new RegExp(`^rgb\\(${IO},${IO},${IO}\\)$`),VO=new RegExp(`^rgb\\(${jO},${jO},${jO}\\)$`),HO=new RegExp(`^rgba\\(${IO},${IO},${IO},${NO}\\)$`),GO=new RegExp(`^rgba\\(${jO},${jO},${jO},${NO}\\)$`),zO=new RegExp(`^hsl\\(${NO},${jO},${jO}\\)$`),FO=new RegExp(`^hsla\\(${NO},${jO},${jO},${NO}\\)$`),WO={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function qO(){return this.rgb().formatHex()}function $O(){return this.rgb().formatHex8()}function YO(){return lx(this).formatHsl()}function ZO(){return this.rgb().formatRgb()}function XO(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=BO.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?KO(e):3===n?new ex(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?QO(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?QO(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=UO.exec(t))?new ex(e[1],e[2],e[3],1):(e=VO.exec(t))?new ex(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=HO.exec(t))?QO(e[1],e[2],e[3],e[4]):(e=GO.exec(t))?QO(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=zO.exec(t))?ux(e[1],e[2]/100,e[3]/100,1):(e=FO.exec(t))?ux(e[1],e[2]/100,e[3]/100,e[4]):WO.hasOwnProperty(t)?KO(WO[t]):"transparent"===t?new ex(NaN,NaN,NaN,0):null}function KO(t){return new ex(t>>16&255,t>>8&255,255&t,1)}function QO(t,e,n,r){return r<=0&&(t=e=n=NaN),new ex(t,e,n,r)}function JO(t){return t instanceof kO||(t=XO(t)),t?(t=t.rgb(),new ex(t.r,t.g,t.b,t.opacity)):new ex}function tx(t,e,n,r){return 1===arguments.length?JO(t):new ex(t,e,n,null==r?1:r)}function ex(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function nx(){return`#${sx(this.r)}${sx(this.g)}${sx(this.b)}`}function rx(){return`#${sx(this.r)}${sx(this.g)}${sx(this.b)}${sx(255*(isNaN(this.opacity)?1:this.opacity))}`}function ix(){const t=ox(this.opacity);return`${1===t?"rgb(":"rgba("}${ax(this.r)}, ${ax(this.g)}, ${ax(this.b)}${1===t?")":`, ${t})`}`}function ox(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function ax(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function sx(t){return t=ax(t),(t<16?"0":"")+t.toString(16)}function ux(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new hx(t,e,n,r)}function lx(t){if(t instanceof hx)return new hx(t.h,t.s,t.l,t.opacity);if(t instanceof kO||(t=XO(t)),!t)return new hx;if(t instanceof hx)return t;t=t.rgb();var e=t.r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new hx(a,s,u,t.opacity)}function cx(t,e,n,r){return 1===arguments.length?lx(t):new hx(t,e,n,null==r?1:r)}function hx(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function fx(t){return t=(t||0)%360,t<0?t+360:t}function px(t){return Math.max(0,Math.min(1,t||0))}function dx(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function vx(t,e,n,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*r+a*i)/6}LO(kO,XO,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:qO,formatHex:qO,formatHex8:$O,formatHsl:YO,formatRgb:ZO,toString:ZO}),LO(ex,tx,DO(kO,{brighter(t){return t=null==t?RO:Math.pow(RO,t),new ex(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?PO:Math.pow(PO,t),new ex(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new ex(ax(this.r),ax(this.g),ax(this.b),ox(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:nx,formatHex:nx,formatHex8:rx,formatRgb:ix,toString:ix})),LO(hx,cx,DO(kO,{brighter(t){return t=null==t?RO:Math.pow(RO,t),new hx(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?PO:Math.pow(PO,t),new hx(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new ex(dx(t>=240?t-240:t+120,i,r),dx(t,i,r),dx(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new hx(fx(this.h),px(this.s),px(this.l),ox(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=ox(this.opacity);return`${1===t?"hsl(":"hsla("}${fx(this.h)}, ${100*px(this.s)}%, ${100*px(this.l)}%${1===t?")":`, ${t})`}`}}));var gx=function(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,s=r<e-1?t[r+2]:2*o-i;return vx((n-r/e)*e,a,i,o,s)}},mx=function(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),i=t[(r+e-1)%e],o=t[r%e],a=t[(r+1)%e],s=t[(r+2)%e];return vx((n-r/e)*e,i,o,a,s)}},yx=t=>()=>t;function _x(t,e){return function(n){return t+n*e}}function bx(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}function wx(t){return 1===(t=+t)?Ox:function(e,n){return n-e?bx(e,n,t):yx(isNaN(e)?n:e)}}function Ox(t,e){var n=e-t;return n?_x(t,n):yx(isNaN(t)?e:t)}var xx=function t(e){var n=wx(e);function r(t,e){var r=n((t=tx(t)).r,(e=tx(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=Ox(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function Ex(t){return function(e){var n,r,i=e.length,o=new Array(i),a=new Array(i),s=new Array(i);for(n=0;n<i;++n)r=tx(e[n]),o[n]=r.r||0,a[n]=r.g||0,s[n]=r.b||0;return o=t(o),a=t(a),s=t(s),r.opacity=1,function(t){return r.r=o(t),r.g=a(t),r.b=s(t),r+""}}}Ex(gx),Ex(mx);var Tx=function(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}};function Sx(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Mx(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=Nx(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}var Cx=function(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}},Ax=function(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}},Lx=function(t,e){var n,r={},i={};for(n in null!==t&&"object"===typeof t||(t={}),null!==e&&"object"===typeof e||(e={}),e)n in t?r[n]=Nx(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}},Dx=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,kx=new RegExp(Dx.source,"g");function Px(t){return function(){return t}}function Rx(t){return function(e){return t(e)+""}}var Ix=function(t,e){var n,r,i,o=Dx.lastIndex=kx.lastIndex=0,a=-1,s=[],u=[];t+="",e+="";while((n=Dx.exec(t))&&(r=kx.exec(e)))(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:Ax(n,r)})),o=kx.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?Rx(u[0].x):Px(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})},Nx=function(t,e){var n,r=typeof e;return null==e||"boolean"===r?yx(e):("number"===r?Ax:"string"===r?(n=XO(e))?(e=n,xx):Ix:e instanceof XO?xx:e instanceof Date?Cx:Sx(e)?Tx:Array.isArray(e)?Mx:"function"!==typeof e.valueOf&&"function"!==typeof e.toString||isNaN(e)?Lx:Ax)(t,e)},jx=function(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}};function Bx(t){return function(){return t}}function Ux(t){return+t}var Vx=[0,1];function Hx(t){return t}function Gx(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:Bx(isNaN(e)?NaN:.5)}function zx(t,e){var n;return t>e&&(n=t,t=e,e=n),function(n){return Math.max(t,Math.min(e,n))}}function Fx(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=Gx(i,r),o=n(a,o)):(r=Gx(r,i),o=n(o,a)),function(t){return o(r(t))}}function Wx(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());while(++a<r)i[a]=Gx(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=Yv(t,e,1,r)-1;return o[n](i[n](e))}}function qx(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function $x(){var t,e,n,r,i,o,a=Vx,s=Vx,u=Nx,l=Hx;function c(){var t=Math.min(a.length,s.length);return l!==Hx&&(l=zx(a[0],a[t-1])),r=t>2?Wx:Fx,i=o=null,h}function h(e){return null==e||isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return h.invert=function(n){return l(e((o||(o=r(s,a.map(t),Ax)))(n)))},h.domain=function(t){return arguments.length?(a=Array.from(t,Ux),c()):a.slice()},h.range=function(t){return arguments.length?(s=Array.from(t),c()):s.slice()},h.rangeRound=function(t){return s=Array.from(t),u=jx,c()},h.clamp=function(t){return arguments.length?(l=!!t||Hx,c()):l!==Hx},h.interpolate=function(t){return arguments.length?(u=t,c()):u},h.unknown=function(t){return arguments.length?(n=t,h):n},function(n,r){return t=n,e=r,c()}}function Yx(){return $x()(Hx,Hx)}function Zx(t,e){t=t.slice();var n,r=0,i=t.length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function Xx(t){return new Date(t)}function Kx(t){return t instanceof Date?+t:+new Date(+t)}function Qx(t,e,n,r,i,o,a,s,u,l){var c=Yx(),h=c.invert,f=c.domain,p=l(".%L"),d=l(":%S"),v=l("%I:%M"),g=l("%I %p"),m=l("%a %d"),y=l("%b %d"),_=l("%B"),b=l("%Y");function w(t){return(u(t)<t?p:s(t)<t?d:a(t)<t?v:o(t)<t?g:r(t)<t?i(t)<t?m:y:n(t)<t?_:b)(t)}return c.invert=function(t){return new Date(h(t))},c.domain=function(t){return arguments.length?f(Array.from(t,Kx)):f().map(Xx)},c.ticks=function(e){var n=f();return t(n[0],n[n.length-1],null==e?10:e)},c.tickFormat=function(t,e){return null==e?w:l(e)},c.nice=function(t){var n=f();return t&&"function"===typeof t.range||(t=e(n[0],n[n.length-1],null==t?10:t)),t?f(Zx(n,t)):c},c.copy=function(){return qx(c,Qx(t,e,n,r,i,o,a,s,u,l))},c}function Jx(){return Sv.apply(Qx(iw,ow,Jb,Kb,Nb,kb,Lb,Cb,Mb,hw).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var tE=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function eE(t){if(!(e=tE.exec(t)))throw new Error("invalid format: "+t);var e;return new nE({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function nE(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}eE.prototype=nE.prototype,nE.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rE=function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)};function iE(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}var oE,aE,sE,uE,lE=function(t){return t=iE(Math.abs(t)),t?t[1]:NaN},cE=function(t,e){return function(n,r){var i=n.length,o=[],a=0,s=t[0],u=0;while(i>0&&s>0){if(u+s+1>r&&(s=Math.max(1,r-u)),o.push(n.substring(i-=s,i+s)),(u+=s+1)>r)break;s=t[a=(a+1)%t.length]}return o.reverse().join(e)}},hE=function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}},fE=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0);break}return i>0?t.slice(0,i)+t.slice(e+1):t},pE=function(t,e){var n=iE(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(oE=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+iE(t,Math.max(0,e+o-1))[0]},dE=function(t,e){var n=iE(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")},vE={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:rE,e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>dE(100*t,e),r:dE,s:pE,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)},gE=function(t){return t},mE=Array.prototype.map,yE=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"],_E=function(t){var e=void 0===t.grouping||void 0===t.thousands?gE:cE(mE.call(t.grouping,Number),t.thousands+""),n=void 0===t.currency?"":t.currency[0]+"",r=void 0===t.currency?"":t.currency[1]+"",i=void 0===t.decimal?".":t.decimal+"",o=void 0===t.numerals?gE:hE(mE.call(t.numerals,String)),a=void 0===t.percent?"%":t.percent+"",s=void 0===t.minus?"−":t.minus+"",u=void 0===t.nan?"NaN":t.nan+"";function l(t){t=eE(t);var l=t.fill,c=t.align,h=t.sign,f=t.symbol,p=t.zero,d=t.width,v=t.comma,g=t.precision,m=t.trim,y=t.type;"n"===y?(v=!0,y="g"):vE[y]||(void 0===g&&(g=12),m=!0,y="g"),(p||"0"===l&&"="===c)&&(p=!0,l="0",c="=");var _="$"===f?n:"#"===f&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",b="$"===f?r:/[%p]/.test(y)?a:"",w=vE[y],O=/[defgprs%]/.test(y);function x(t){var n,r,a,f=_,x=b;if("c"===y)x=w(t)+x,t="";else{t=+t;var E=t<0||1/t<0;if(t=isNaN(t)?u:w(Math.abs(t),g),m&&(t=fE(t)),E&&0===+t&&"+"!==h&&(E=!1),f=(E?"("===h?h:s:"-"===h||"("===h?"":h)+f,x=("s"===y?yE[8+oE/3]:"")+x+(E&&"("===h?")":""),O){n=-1,r=t.length;while(++n<r)if(a=t.charCodeAt(n),48>a||a>57){x=(46===a?i+t.slice(n+1):t.slice(n))+x,t=t.slice(0,n);break}}}v&&!p&&(t=e(t,1/0));var T=f.length+t.length+x.length,S=T<d?new Array(d-T+1).join(l):"";switch(v&&p&&(t=e(S+t,S.length?d-x.length:1/0),S=""),c){case"<":t=f+t+x+S;break;case"=":t=f+S+t+x;break;case"^":t=S.slice(0,T=S.length>>1)+f+t+x+S.slice(T);break;default:t=S+f+t+x;break}return o(t)}return g=void 0===g?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),x.toString=function(){return t+""},x}function c(t,e){var n=l((t=eE(t),t.type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(lE(e)/3))),i=Math.pow(10,-r),o=yE[8+r/3];return function(t){return n(i*t)+o}}return{format:l,formatPrefix:c}};function bE(t){return aE=_E(t),sE=aE.format,uE=aE.formatPrefix,aE}function wE(t){return Math.log(t)}function OE(t){return Math.exp(t)}function xE(t){return-Math.log(-t)}function EE(t){return-Math.exp(-t)}function TE(t){return isFinite(t)?+("1e"+t):t<0?0:t}function SE(t){return 10===t?TE:t===Math.E?Math.exp:e=>Math.pow(t,e)}function ME(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}function CE(t){return(e,n)=>-t(-e,n)}function AE(t){const e=t(wE,OE),n=e.domain;let r,i,o=10;function a(){return r=ME(o),i=SE(o),n()[0]<0?(r=CE(r),i=CE(i),t(xE,EE)):t(wE,OE),e}return e.base=function(t){return arguments.length?(o=+t,a()):o},e.domain=function(t){return arguments.length?(n(t),a()):n()},e.ticks=t=>{const e=n();let a=e[0],s=e[e.length-1];const u=s<a;u&&([a,s]=[s,a]);let l,c,h=r(a),f=r(s);const p=null==t?10:+t;let d=[];if(!(o%1)&&f-h<p){if(h=Math.floor(h),f=Math.ceil(f),a>0){for(;h<=f;++h)for(l=1;l<o;++l)if(c=h<0?l/i(-h):l*i(h),!(c<a)){if(c>s)break;d.push(c)}}else for(;h<=f;++h)for(l=o-1;l>=1;--l)if(c=h>0?l/i(-h):l*i(h),!(c<a)){if(c>s)break;d.push(c)}2*d.length<p&&(d=ng(a,s,p))}else d=ng(h,f,Math.min(f-h,p)).map(i);return u?d.reverse():d},e.tickFormat=(t,n)=>{if(null==t&&(t=10),null==n&&(n=10===o?"s":","),"function"!==typeof n&&(o%1||null!=(n=eE(n)).precision||(n.trim=!0),n=sE(n)),t===1/0)return n;const a=Math.max(1,o*t/e.ticks().length);return t=>{let e=t/i(Math.round(r(t)));return e*o<o-.5&&(e*=o),e<=a?n(t):""}},e.nice=()=>n(Zx(n(),{floor:t=>i(Math.floor(r(t))),ceil:t=>i(Math.ceil(r(t)))})),e}function LE(){const t=AE($x()).domain([1,10]);return t.copy=()=>qx(t,LE()).base(t.base()),Sv.apply(t,arguments),t}function DE(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);while(++r<i)o[r]=t+r*n;return o}function kE(){var t,e,n=Cv().unknown(void 0),r=n.domain,i=n.range,o=0,a=1,s=!1,u=0,l=0,c=.5;function h(){var n=r().length,h=a<o,f=h?a:o,p=h?o:a;t=(p-f)/Math.max(1,n-u+2*l),s&&(t=Math.floor(t)),f+=(p-f-t*(n-u))*c,e=t*(1-u),s&&(f=Math.round(f),e=Math.round(e));var d=DE(n).map((function(e){return f+t*e}));return i(h?d.reverse():d)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),h()):r()},n.range=function(t){return arguments.length?([o,a]=t,o=+o,a=+a,h()):[o,a]},n.rangeRound=function(t){return[o,a]=t,o=+o,a=+a,s=!0,h()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(s=!!t,h()):s},n.padding=function(t){return arguments.length?(u=Math.min(1,l=+t),h()):u},n.paddingInner=function(t){return arguments.length?(u=Math.min(1,t),h()):u},n.paddingOuter=function(t){return arguments.length?(l=+t,h()):l},n.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),h()):c},n.copy=function(){return kE(r(),[o,a]).round(s).paddingInner(u).paddingOuter(l).align(c)},Sv.apply(h(),arguments)}bE({thousands:",",grouping:[3],currency:["$",""]});var PE=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(lE(e)/3)))-lE(Math.abs(t)))},RE=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,lE(e)-lE(t))+1},IE=function(t){return Math.max(0,-lE(Math.abs(t)))};function NE(t,e,n,r){var i,o=ig(t,e,n);switch(r=eE(null==r?",f":r),r.type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=PE(o,a))||(r.precision=i),uE(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=RE(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=IE(o))||(r.precision=i-2*("%"===r.type));break}return sE(r)}function jE(t){var e=t.domain;return t.ticks=function(t){var n=e();return ng(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return NE(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i,o=e(),a=0,s=o.length-1,u=o[a],l=o[s],c=10;l<u&&(i=u,u=l,l=i,i=a,a=s,s=i);while(c-- >0){if(i=rg(u,l,n),i===r)return o[a]=u,o[s]=l,e(o);if(i>0)u=Math.floor(u/i)*i,l=Math.ceil(l/i)*i;else{if(!(i<0))break;u=Math.ceil(u*i)/i,l=Math.floor(l*i)/i}r=i}return t},t}function BE(){var t=Yx();return t.copy=function(){return qx(t,BE())},Sv.apply(t,arguments),jE(t)}function UE(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n<r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function VE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e);return n.getFullYear()-r.getFullYear()}function HE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function GE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs(VE(n,r));n.setFullYear(n.getFullYear()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function zE(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getFullYear(),r=e.getMonth(),i=new Date(0);return i.setFullYear(n,r+1,0),i.setHours(0,0,0,0),i.getDate()}function FE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=Kg(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=zE(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function WE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return FE(t,12*n)}function qE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return WE(t,-n)}function $E(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function YE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs($E(n,r));n.setMonth(n.getMonth()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function ZE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return FE(t,-n)}function XE(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t);return e.setHours(0,0,0,0),e}var KE=864e5;function QE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=XE(t),r=XE(e),i=n.getTime()-Mm(n),o=r.getTime()-Mm(r);return Math.round((i-o)/KE)}function JE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs(QE(n,r));n.setDate(n.getDate()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function tT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=Kg(e);return n.setDate(n.getDate()+r),n}function eT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return tT(t,-n)}function nT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e);return n.getTime()-r.getTime()}var rT=36e5;function iT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/rT;return n>0?Math.floor(n):Math.ceil(n)}var oT=36e5;function aT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,n*oT)}function sT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return aT(t,-n)}var uT=6e4;function lT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/uT;return n>0?Math.floor(n):Math.ceil(n)}var cT=6e4;function hT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,n*cT)}function fT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return hT(t,-n)}function pT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/1e3;return n>0?Math.floor(n):Math.ceil(n)}function dT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,1e3*n)}function vT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return dT(t,-n)}var gT=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mT=function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]])}return n},yT=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},_T=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.scaleTypes={top:null,right:null,bottom:null,left:null},e.scales={top:null,right:null,bottom:null,left:null},e}return gT(e,t),e.prototype.getDomainAxisPosition=function(t){var e,n=(void 0===t?{}:t).datum,r=void 0===n?null:n;if(this.dualAxes&&r){var i=this.model.getOptions(),o=i.data.groupMapsTo,a=Dd(i,"axes",this.secondaryDomainAxisPosition),s=r[o];if((null===(e=a)||void 0===e?void 0:e.correspondingDatasets)&&a.correspondingDatasets.includes(s))return this.secondaryDomainAxisPosition}return this.domainAxisPosition},e.prototype.getRangeAxisPosition=function(t){var e,n=void 0===t?{}:t,r=n.datum,i=void 0===r?null:r,o=n.groups,a=void 0===o?null:o;if(this.dualAxes){var s=this.model.getOptions(),u=s.data.groupMapsTo,l=Dd(s,"axes",this.secondaryRangeAxisPosition),c=void 0;if(null!==i?c=i[u]:a&&a.length>0&&(c=a[0]),(null===(e=l)||void 0===e?void 0:e.correspondingDatasets)&&l.correspondingDatasets.includes(c))return this.secondaryRangeAxisPosition}return this.rangeAxisPosition},e.prototype.getAxisOptions=function(t){return Dd(this.model.getOptions(),"axes",t)},e.prototype.getDomainAxisOptions=function(){var t=this.getDomainAxisPosition();return this.getAxisOptions(t)},e.prototype.getRangeAxisOptions=function(){var t=this.getRangeAxisPosition();return this.getAxisOptions(t)},e.prototype.getScaleLabel=function(t){var e=this.getAxisOptions(t),n=e.title;return n||(t===B.BOTTOM||t===B.TOP?"x-value":"y-value")},e.prototype.getDomainLabel=function(){return this.getScaleLabel(this.getDomainAxisPosition())},e.prototype.getRangeLabel=function(){return this.getScaleLabel(this.getRangeAxisPosition())},e.prototype.update=function(t){var e=this;void 0===t&&(t=!0),this.determineAxisDuality(),this.findDomainAndRangeAxes(),this.determineOrientation();var n=Object.keys(B).map((function(t){return B[t]}));n.forEach((function(t){e.scales[t]=e.createScale(t)}))},e.prototype.findDomainAndRangeAxes=function(){var t=this.findVerticalAxesPositions(),e=this.findHorizontalAxesPositions(),n=this.findDomainAndRangeAxesPositions(t,e);this.domainAxisPosition=n.primaryDomainAxisPosition,this.rangeAxisPosition=n.primaryRangeAxisPosition,this.isDualAxes()&&(this.secondaryDomainAxisPosition=n.secondaryDomainAxisPosition,this.secondaryRangeAxisPosition=n.secondaryRangeAxisPosition)},e.prototype.determineOrientation=function(){this.rangeAxisPosition!==B.LEFT&&this.rangeAxisPosition!==B.RIGHT||this.domainAxisPosition!==B.BOTTOM&&this.domainAxisPosition!==B.TOP?this.orientation=H.HORIZONTAL:this.orientation=H.VERTICAL},e.prototype.isDualAxes=function(){return this.dualAxes},e.prototype.determineAxisDuality=function(){var t,e,n,r,i=this.model.getOptions(),o=Dd(i,"axes");((null===(t=o[B.LEFT])||void 0===t?void 0:t.correspondingDatasets)&&o[B.RIGHT]||(null===(e=o[B.RIGHT])||void 0===e?void 0:e.correspondingDatasets)&&o[B.LEFT]||(null===(n=o[B.TOP])||void 0===n?void 0:n.correspondingDatasets)&&o[B.BOTTOM]||(null===(r=o[B.BOTTOM])||void 0===r?void 0:r.correspondingDatasets)&&o[B.TOP])&&(this.dualAxes=!0)},e.prototype.getCustomDomainValuesByposition=function(t){var e=Dd(this.model.getOptions(),"axes",t,"domain");if(e&&!Array.isArray(e))throw new Error("Domain in "+t+" axis is not a valid array");if(Array.isArray(e)&&(this.scaleTypes[t]===G.LINEAR||this.scaleTypes[t]===G.TIME)&&2!==e.length)throw new Error("There can only be 2 elements in domain for scale type: "+this.scaleTypes[t]);return e},e.prototype.getOrientation=function(){return this.orientation},e.prototype.getScaleByPosition=function(t){return this.scales[t]},e.prototype.getScaleTypeByPosition=function(t){return this.scaleTypes[t]},e.prototype.getDomainAxisScaleType=function(){var t=this.getDomainAxisPosition();return this.getScaleTypeByPosition(t)},e.prototype.getRangeAxisScaleType=function(){var t=this.getRangeAxisPosition();return this.getScaleTypeByPosition(t)},e.prototype.getDomainScale=function(){return this.scales[this.domainAxisPosition]},e.prototype.getRangeScale=function(){return this.scales[this.rangeAxisPosition]},e.prototype.getMainXAxisPosition=function(){var t=[B.BOTTOM,B.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[B.LEFT,B.RIGHT];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainXScale=function(){return this.scales[this.getMainXAxisPosition()]},e.prototype.getMainYScale=function(){return this.scales[this.getMainYAxisPosition()]},e.prototype.getValueFromScale=function(t,e,n,r,i){var o,a=this.model.getOptions(),s=Dd(a,"axes"),u=s[n],l=u.mapsTo,c=null!==Dd(r,l)?r[l]:r;switch(e){case G.LABELS:o=t(c)+t.step()/2;break;case G.TIME:o=t(new Date(c));break;default:o=t(c)}return o},e.prototype.getBoundedScaledValues=function(t,e){var n=this.model.getOptions().bounds,r=this.getRangeAxisPosition({datum:t}),i=this.scales[r],o=this.model.getOptions(),a=Dd(o,"axes"),s=a[r],u=s.mapsTo,l=void 0!==t[u]?t[u]:t,c=[i(null!==Dd(t,n.upperBoundMapsTo)?t[n.upperBoundMapsTo]:l),i(null!==Dd(t,n.lowerBoundMapsTo)?t[n.lowerBoundMapsTo]:l)];return c},e.prototype.getValueThroughAxisPosition=function(t,e,n){var r=this.scaleTypes[t],i=this.scales[t];return this.getValueFromScale(i,r,t,e,n)},e.prototype.getDomainValue=function(t,e){var n=this.getDomainAxisPosition({datum:t});return this.getValueThroughAxisPosition(n,t,e)},e.prototype.getRangeValue=function(t,e){var n=this.getRangeAxisPosition({datum:t});return this.getValueThroughAxisPosition(n,t,e)},e.prototype.getMainXScaleType=function(){return this.getScaleTypeByPosition(this.getMainXAxisPosition())},e.prototype.getMainYScaleType=function(){return this.getScaleTypeByPosition(this.getMainYAxisPosition())},e.prototype.getDomainIdentifier=function(t){var e=this.model.getOptions();return Dd(e,"axes",this.getDomainAxisPosition({datum:t}),"mapsTo")},e.prototype.getRangeIdentifier=function(t){var e=this.model.getOptions();return Dd(e,"axes",this.getRangeAxisPosition({datum:t}),"mapsTo")},e.prototype.extendsDomain=function(t,e){var n=this.model.getOptions(),r=Dd(n,"axes",t);if(r.scaleType===G.TIME){var i=Dd(n,"timeScale","addSpaceOnEdges");return bT(e,i)}return wT(e,gt.paddingRatio,r.scaleType)},e.prototype.findVerticalAxesPositions=function(){var t=this.model.getOptions(),e=Dd(t,"axes"),n=this.isDualAxes();return null===Dd(e,B.LEFT)&&null!==Dd(e,B.RIGHT)||!0===Dd(e,B.RIGHT,"main")||n&&Dd(e,B.LEFT,"correspondingDatasets")?{primary:B.RIGHT,secondary:B.LEFT}:{primary:B.LEFT,secondary:B.RIGHT}},e.prototype.findHorizontalAxesPositions=function(){var t=this.model.getOptions(),e=Dd(t,"axes"),n=this.isDualAxes();return null===Dd(e,B.BOTTOM)&&null!==Dd(e,B.TOP)||!0===Dd(e,B.TOP,"main")||n&&Dd(e,B.BOTTOM,"correspondingDatasets")?{primary:B.TOP,secondary:B.BOTTOM}:{primary:B.BOTTOM,secondary:B.TOP}},e.prototype.findDomainAndRangeAxesPositions=function(t,e){var n=this.model.getOptions(),r=Dd(n,"axes",t.primary),i=Dd(n,"axes",e.primary),o=r.scaleType||G.LINEAR,a=i.scaleType||G.LINEAR,s={primaryDomainAxisPosition:null,secondaryDomainAxisPosition:null,primaryRangeAxisPosition:null,secondaryRangeAxisPosition:null};return s.primaryDomainAxisPosition=e.primary,s.primaryRangeAxisPosition=t.primary,s.secondaryDomainAxisPosition=e.secondary,s.secondaryRangeAxisPosition=t.secondary,(a!==G.LABELS&&a!==G.TIME&&o===G.LABELS||o===G.TIME)&&(s.primaryDomainAxisPosition=t.primary,s.primaryRangeAxisPosition=e.primary,s.secondaryDomainAxisPosition=t.secondary,s.secondaryRangeAxisPosition=e.secondary),s},e.prototype.getScaleDomain=function(t){var e=this.model.getOptions(),n=Dd(e,"axes",t),r=Dd(e,"bounds"),i=n.includeZero,o=Dd(n,"scaleType")||G.LINEAR;if(this.model.isDataEmpty())return[];if(n.binned){var a=this.model.getBinConfigurations().bins;return[0,UE(a,(function(t){return t.length}))]}if(n.limitDomainToBins){a=this.model.getBinConfigurations().bins;var s=this.model.getStackKeys({bins:a});return[s[0].split("-")[0],s[s.length-1].split("-")[1]]}var u,l,c=this.model.getDisplayData(),h=n.extendLinearDomainBy,f=n.mapsTo,p=n.percentage,d=n.thresholds,v=gt.ratio,g=v.reference,m=v.compareTo;if(n.domain)return o===G.LABELS?n.domain:(o===G.TIME&&(n.domain=n.domain.map((function(t){return void 0===t.getTime?new Date(t):t}))),this.extendsDomain(t,n.domain));if(p)return[0,100];if(n&&o===G.LABELS)return xd(c.map((function(t){return t[f]})));var y=this.model.getDataGroupNames();if(o===G.LABELS_RATIO)return c.map((function(t){return t[g]+"/"+t[m]}));if(o===G.TIME)l=c.map((function(t){return+new Date(t[f])}));else if(r&&e.axes)l=[],c.forEach((function(t){l.push(t[f]),t[r.upperBoundMapsTo]&&l.push(t[r.upperBoundMapsTo]),t[r.lowerBoundMapsTo]&&l.push(t[r.lowerBoundMapsTo])}));else if(!0===n.stacked&&y&&t===this.getRangeAxisPosition()){var _=e.data.groupMapsTo,b=this.model.getDataValuesGroupedByKeys({groups:y}),w=c.filter((function(t){return!y.includes(t[_])})),O=[];b.forEach((function(t){t.sharedStackKey;var e=mT(t,["sharedStackKey"]),n=0,r=0;Object.values(e).forEach((function(t){isNaN(t)||(t<0?r+=t:n+=t)})),O.push([r,n])})),l=yT(va(O),w.map((function(t){return t[f]})))}else l=[],c.forEach((function(t){var e=t[f];Array.isArray(e)&&2===e.length?(l.push(e[0]),l.push(e[1])):(h&&l.push(Math.max(t[f],t[h])),l.push(e))}));return o!==G.TIME&&o!==G.LOG&&i&&l.push(0),d&&d.length>0&&d.forEach((function(t){var e=Dd(t,"value");null!==e&&l.push(e)})),u=Xv(l),u=this.extendsDomain(t,u),u},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=Dd(e,"axes",t);if(!n)return null;var r,i=Dd(n,"scaleType")||G.LINEAR;return this.scaleTypes[t]=i,r=i===G.TIME?Jx():i===G.LOG?LE().base(n.base||10):i===G.LABELS||i===G.LABELS_RATIO?kE():BE(),r.domain(this.getScaleDomain(t)),r},e.prototype.getHighestDomainThreshold=function(){var t=Dd(this.model.getOptions(),"axes"),e=this.getDomainAxisPosition(),n=t[e].thresholds;if(!Array.isArray(n)||Array.isArray(n)&&!n.length)return null;var r=this.getDomainScale(),i=n.sort((function(t,e){return e.value-t.value}))[0],o=this.getScaleTypeByPosition(e);return o!==G.TIME||"string"!==typeof i.value&&void 0!==i.value.getTime||(i.value=new Date(i.value)),{threshold:i,scaleValue:r(i.value)}},e.prototype.getHighestRangeThreshold=function(){var t=Dd(this.model.getOptions(),"axes"),e=this.getRangeAxisPosition(),n=t[e].thresholds;if(!Array.isArray(n)||Array.isArray(n)&&!n.length)return null;var r=this.getRangeScale(),i=n.sort((function(t,e){return e.value-t.value}))[0];return{threshold:i,scaleValue:r(i.value)}},e}(ty);function bT(t,e){var n=new Date(t[0]),r=new Date(t[1]);return GE(r,n)>1?[qE(n,e),WE(r,e)]:YE(r,n)>1?[ZE(n,e),FE(r,e)]:JE(r,n)>1?[eT(n,e),tT(r,e)]:iT(r,n)>1?[sT(n,e),aT(r,e)]:lT(r,n)>30?[fT(n,30*e),hT(r,30*e)]:lT(r,n)>1?[fT(n,e),hT(r,e)]:pT(r,n)>15?[vT(n,15*e),dT(r,15*e)]:pT(r,n)>1?[vT(n,e),dT(r,e)]:[n,r]}function wT(t,e,n){var r=t[0],i=t[1],o=i-r,a=o*e,s=i<=0&&i+a>0?0:i+a,u=r>=0&&r-a<0?0:r-a;if(n===G.LOG&&u<=0){if(r<=0)throw Error("Data must have values greater than 0 if log scale type is used.");u=r}return[u,s]}function OT(t){this._context=t}OT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e);break}}};var xT=function(t){return new OT(t)},ET=function(){};function TT(t){this._context=t}TT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}};var ST=function(t){return new TT(t)};function MT(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function CT(t){this._context=t}CT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:MT(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var AT=function(t){return new CT(t)};function LT(t){this._context=t}LT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var DT=function(t){return new LT(t)};function kT(t){this._context=t}kT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var PT=function(t){return new kT(t)};function RT(t,e){this._basis=new CT(t),this._beta=e}RT.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0){var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;while(++u<=n)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s))}this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var IT=function t(e){function n(t){return 1===e?new CT(t):new RT(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function NT(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function jT(t,e){this._context=t,this._k=(1-e)/6}jT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:NT(this,this._x1,this._y1);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var BT=function t(e){function n(t){return new jT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function UT(t,e){this._context=t,this._k=(1-e)/6}UT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var VT=function t(e){function n(t){return new UT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function HT(t,e){this._context=t,this._k=(1-e)/6}HT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var GT=function t(e){function n(t){return new HT(t,e)}return n.tension=function(e){return t(+e)},n}(0);const zT=Math.abs,FT=Math.atan2,WT=Math.cos,qT=Math.max,$T=Math.min,YT=Math.sin,ZT=Math.sqrt,XT=1e-12,KT=Math.PI,QT=KT/2,JT=2*KT;function tS(t){return t>1?0:t<-1?KT:Math.acos(t)}function eS(t){return t>=1?QT:t<=-1?-QT:Math.asin(t)}function nS(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>XT){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>XT){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/c,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/c}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function rS(t,e){this._context=t,this._alpha=e}rS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var iS=function t(e){function n(t){return e?new rS(t,e):new jT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function oS(t,e){this._context=t,this._alpha=e}oS.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var aS=function t(e){function n(t){return e?new oS(t,e):new UT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function sS(t,e){this._context=t,this._alpha=e}sS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var uS=function t(e){function n(t){return e?new sS(t,e):new HT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function lS(t){return t<0?-1:1}function cS(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(lS(o)+lS(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function hS(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function fS(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function pS(t){this._context=t}function dS(t){this._context=new vS(t)}function vS(t){this._context=t}function gS(t){return new pS(t)}function mS(t){return new dS(t)}function yS(t){this._context=t}function _S(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}pS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:fS(this,this._t0,hS(this,this._t0));break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(t=+t,e=+e,t!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,fS(this,hS(this,n=cS(this,t,e)),n);break;default:fS(this,this._t0,n=cS(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(dS.prototype=Object.create(pS.prototype)).point=function(t,e){pS.prototype.point.call(this,e,t)},vS.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},yS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=_S(t),i=_S(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var bS=function(t){return new yS(t)};function wS(t,e){this._context=t,this._t=e}wS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}break}this._x=t,this._y=e}};var OS=function(t){return new wS(t,.5)};function xS(t){return new wS(t,0)}function ES(t){return new wS(t,1)}var TS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),SS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:xT,curveLinearClosed:ST,curveBasis:AT,curveBasisClosed:DT,curveBasisOpen:PT,curveBundle:IT,curveCardinal:BT,curveCardinalClosed:VT,curveCardinalOpen:GT,curveCatmullRom:iS,curveCatmullRomClosed:aS,curveCatmullRomOpen:uS,curveMonotoneX:gS,curveMonotoneY:mS,curveNatural:bS,curveStep:OS,curveStepAfter:ES,curveStepBefore:xS},e}return TS(e,t),e.prototype.getD3Curve=function(){var t="curveLinear",e=this.model.getOptions().curve;if(e&&(t="string"===typeof e?e:e.name),this.curveTypes[t]){var n=this.curveTypes[t];return e&&Object.keys(e).forEach((function(t){n[t]&&(n=n[t](e[t]))})),n}return console.warn("The curve type '"+t+"' is invalid, using 'curveLinear' instead"),this.curveTypes["curveLinear"]},e}(ty),MS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),CS=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return MS(e,t),e.prototype.isZoomBarEnabled=function(){if(!this.services.cartesianScales)return!1;if(!Dd(this.model.getOptions(),"zoomBar","top","enabled"))return!1;this.services.cartesianScales.findDomainAndRangeAxes();var t=this.services.cartesianScales.getMainXAxisPosition(),e=Dd(this.model.getOptions(),"axes",t,"scaleType");return t===B.BOTTOM&&e===G.TIME},e.prototype.getZoomBarData=function(){var t=this.model.getZoomBarData();return t&&t.length>1?t:this.model.getDisplayData()},e.prototype.getDefaultZoomBarDomain=function(t){var e=t||this.services.zoom.getZoomBarData(),n=this.services.cartesianScales,r=n.getMainXAxisPosition(),i=n.getDomainIdentifier(),o=Dd(this.model.getOptions(),"axes",r,"domain");return Array.isArray(o)&&2===o.length?o:n.extendsDomain(r,Xv(e,(function(t){return t[i]})))},e.prototype.handleDomainChange=function(t,e){void 0===e&&(e={dispatchEvent:!0}),this.model.set({zoomDomain:t},{animate:!1}),e.dispatchEvent&&this.services.events.dispatchEvent(ft.ZoomDomain.CHANGE,{newDomain:t})},e.prototype.getZoomRatio=function(){return Dd(this.model.getOptions(),"zoomBar","zoomRatio")},e.prototype.filterDataForRangeAxis=function(t,e){var n=this.model.get("zoomDomain"),r=Object.assign({stacked:!1},e),i=Dd(this.model.getOptions(),"zoomBar","updateRangeAxis");if(this.isZoomBarEnabled()&&i&&n){var o=r.stacked?"sharedStackKey":this.services.cartesianScales.getDomainIdentifier(),a=t.filter((function(t){return new Date(t[o])>=n[0]&&new Date(t[o])<=n[1]}));if(a.length>0)return a}return t},e.prototype.zoomIn=function(t){void 0===t&&(t=this.getZoomRatio());var e=this.model.get("zoomDomain"),n=Pt.handleWidth,r=this.services.cartesianScales.getMainXScale().copy();r.domain(this.getDefaultZoomBarDomain());var i=r(e[0]),o=r(e[1]);if(!(o-i<n+1)){var a=r.range(),s=o-i,u=Math.min((a[1]-a[0])/2*(t/2),s/2),l=i+u,c=o-u;l>=c&&(l=i+s/2-n/2,c=o-s/2+n/2);var h=[r.invert(l),r.invert(c)];e[0].valueOf()===h[0].valueOf()&&e[1].valueOf()===h[1].valueOf()||this.handleDomainChange(h)}},e.prototype.zoomOut=function(t){void 0===t&&(t=this.getZoomRatio());var e=this.model.get("zoomDomain"),n=this.services.cartesianScales.getMainXScale().copy();n.domain(this.getDefaultZoomBarDomain());var r=n(e[0]),i=n(e[1]),o=n.range(),a=(o[1]-o[0])/2*(t/2),s=Math.max(r-a,o[0]),u=Math.min(i+a,o[1]),l=[n.invert(s),n.invert(u)];e[0].valueOf()===l[0].valueOf()&&e[1].valueOf()===l[1].valueOf()||this.handleDomainChange(l)},e.prototype.resetZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();t[0].valueOf()===e[0].valueOf()&&t[1].valueOf()===e[1].valueOf()||this.handleDomainChange(e)},e.prototype.isMinZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();if(!t||!e)return!1;var n=t[1].valueOf()-t[0].valueOf(),r=e[1].valueOf()-e[0].valueOf(),i=Dd(this.model.getOptions(),"zoomBar","minZoomRatio");return n/r<i},e.prototype.isMaxZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();return!(!t||!e||t[0].valueOf()!==e[0].valueOf()||t[1].valueOf()!==e[1].valueOf())},e.prototype.isEmptyState=function(){return 0===this.getZoomBarData().length},e.prototype.isZoomBarLoading=function(t){return Dd(this.model.getOptions(),"zoomBar",t,"loading")},e.prototype.isZoomBarLocked=function(t){return Dd(this.model.getOptions(),"zoomBar",t,"locked")},e}(ty),AS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LS=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return AS(e,t),e.prototype.zoomIn=function(t,e,n){var r,i,o,a=n||mt;t&&(r=t.x,i=t.y,o=2);var s=sb.getSVGElementSize(this.services.domUtils.getHolder(),{useClientDimensions:!0}),u=s.width,l=s.height;e.transition().duration(a.duration).ease(a.ease).attr("transform","translate("+u/2+", "+l/2+") scale("+o+") translate("+-r+","+-i+")"),this.services.events.dispatchEvent(ft.CanvasZoom.CANVAS_ZOOM_IN,{element:eb(t)})},e.prototype.zoomOut=function(t,e){var n=e||mt;t.transition().duration(n.duration).ease(n.ease).attr("transform",""),this.services.events.dispatchEvent(ft.CanvasZoom.CANVAS_ZOOM_OUT)},e}(ty),DS=function(){function t(t,e,n){if(this.renderType=I.HTML,this.configs={},this.model=t,this.services=e,n&&(this.configs=n,this.configs.id)){var r=Dd(this.model.getOptions(),"style","prefix");this.id=r+"--"+this.configs.id}this.parent||this.setParent(eb(this.services.domUtils.getMainContainer()))}return t.prototype.init=function(){},t.prototype.render=function(t){void 0===t&&(t=!0),console.error("render() method is not implemented")},t.prototype.destroy=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t.prototype.setParent=function(t){var e=this.parent;if(this.parent=t,(!e||e.node()!==t.node())&&this.type){var n=Dd(this.model.getOptions(),"style","prefix");this.parent.classed(dt+"--"+n+"--"+this.type,!0),e&&e.classed(dt+"--"+n+"--"+this.type,!1)}},t.prototype.getParent=function(){return this.parent},t.prototype.getComponentContainer=function(t){if(void 0===t&&(t={withinChartClip:!1}),this.type){var e=Dd(this.model.getOptions(),"style","prefix"),n=this.id?"#"+this.id:"",r=sb.appendOrSelect(this.parent,(this.renderType===I.SVG?"svg":"div")+n+"."+dt+"--"+e+"--"+this.type);if(t.withinChartClip){var i=this.model.get("chartClipId");if(i){var o=eb("#"+i),a=o.select("rect");0!==a.size()&&parseFloat(a.attr("height"))>0&&r.attr("clip-path","url(#"+i+")")}}return r.attr("width","100%").attr("height","100%")}return this.parent},t.prototype.getOptions=function(){if(this.configs.options){var t=na({},this.model.getOptions(),this.configs.options);return t}return this.model.getOptions()},t}(),kS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),PS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e.renderType=I.HTML,e}return kS(e,t),e.prototype.render=function(){var t=this,e=this.getOptions(),n=Dd(e,"legend"),r=Dd(n,"alignment"),i=Dd(e,"legend","orientation"),o=this.model.getDataGroups(),s=Ot.items.status.DISABLED,u=o.some((function(t){return t.status===s})),l=Dd(n,"order"),c=this.getComponentContainer().classed("center-aligned",r===F.CENTER).classed("right-aligned",r===F.RIGHT).classed(i,!0).classed("has-deactivated-items",u).attr("role",a.GROUP).attr("aria-label","Data groups").attr("data-name","legend-items");l&&(o=this.sortDataGroups(o,l));var h=c.selectAll("div.legend-item").data(o,(function(t){return t.name})),f=h.enter().append("div").attr("class","legend-item");f.merge(c.selectAll("div.legend-item")).classed("active",(function(t,e){return t.status===Ot.items.status.ACTIVE}));var p=Dd(this.getOptions(),"legend","clickable");c.classed("clickable",p&&o.length>1);var d=Ot.checkbox.radius,v=f.append("div").classed("checkbox",!0),g=v.merge(h.select("div.checkbox")).attr("role",a.CHECKBOX).attr("tabindex",p?0:-1).attr("aria-labelledby",(function(e,n){return t.services.domUtils.generateElementIDString("legend-datagroup-"+n+"-title")})).attr("aria-checked",(function(t){var e=t.status;return e===Ot.items.status.ACTIVE})).attr("width",2*d).attr("height",2*d).attr("class",(function(e,n){return t.model.getColorClassName({classNameTypes:[j.BACKGROUND],dataGroupName:e.name,originalClassName:"checkbox"})})).style("background",(function(e){return e.status===Ot.items.status.ACTIVE?t.model.getFillColor(e.name)||t.model.getStrokeColor(e.name):null})).classed("active",(function(t,e){return t.status===Ot.items.status.ACTIVE})),m=(v.append("svg").attr("focusable",!1).attr("preserveAspectRatio","xMidYMid meet").attr("xmlns","http://www.w3.org/2000/svg").attr("width","11").attr("height","11").attr("viewBox","0 0 31 28").attr("aria-hidden",!0).style("will-change","transform").append("path").attr("d","M13 21.2l-7.1-7.1-1.4 1.4 7.1 7.1L13 24 27.1 9.9l-1.4-1.5z"),f.append("p").merge(h.select("p")),Dd(e,"legend","additionalItems"));if(m&&o.length){var y=this,_=c.selectAll("div.additional-item").data(m);_.exit().remove();var b,w=_.enter().append("div").merge(_).classed("legend-item",!0).classed("additional",!0).attr("aria-labelledby",(function(e,n){return t.services.domUtils.generateElementIDString("legend-datagroup-"+(g.size()+n)+"-title")}));w.selectAll("*").remove();var O=1;w.append("svg").classed("icon",!0).each((function(t,e){var n=eb(this);b&&b==t.type?O++:(b=t.type,O=1),y.addAdditionalItem(n,t,O)}));w.append("p").merge(w.select("p"));this.truncateLegendText()}h.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove(),p&&f.size()>1&&this.addEventListeners()},e.prototype.sortDataGroups=function(t,e){if(t.sort((function(t,n){return e.indexOf(t.name)-e.indexOf(n.name)})),e.length<t.length){var n=t.length-e.length,r=t.slice(n);return r.concat(t.slice(0,n))}return t},e.prototype.addAdditionalItem=function(t,e,n){var r=Ot.area,i=r.width,s=r.height;if(e.type===st.RADIUS?t.style("width",s+"px").style("height",s+"px"):t.style("width",i+"px").style("height",s+"px"),e.type===st.RADIUS){var u=Ot.radius,l=u.iconData,c=u.fill,h=u.stroke,f=t.attr("fill","none").selectAll("circle").data(l).enter();f.append("circle").classed("radius",!0).attr("role",a.IMG).attr("aria-label","radius").attr("cx",(function(t){return t.cx})).attr("cy",(function(t){return t.cy})).attr("r",(function(t){return t.r})).style("fill",e.fill?e.fill:c).style("stroke",e.stroke?e.stroke:h)}else if(e.type===st.LINE){var p=Ot.line;t.select("line.line").empty()&&t.append("line").classed("line-"+n,!0).attr("role",a.IMG).attr("aria-label","line").attr("x1",0).attr("y1",p.yPosition).attr("x2",i).attr("y2",p.yPosition).style("stroke",e.stroke?e.stroke:p.stroke).style("stroke-width",p.strokeWidth)}else if(e.type===st.AREA)t.select("rect.area").empty()&&t.append("rect").classed("area-"+n,!0).attr("role",a.IMG).attr("aria-label","area").attr("width",i).attr("height",s).style("fill",n>3&&!e.fill?Ot.area.fill:e.fill).style("stroke",e.stroke);else if(e.type===st.SIZE){var d=Ot.size,v=(l=d.iconData,c=d.fill,h=d.stroke,t.attr("fill","none").attr("role",a.IMG).attr("aria-label","size").selectAll("rect").data(l).enter());v.append("rect").classed("size",!0).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})).attr("y",(function(t){return 0})).style("fill",e.fill?e.fill:c).style("stroke",e.stroke?e.stroke:h).style("stroke-width",1)}else if(e.type===st.QUARTILE){l=Ot.quartile.iconData;var g=t.selectAll("rect").attr("role",a.IMG).attr("aria-label","quartile").data(l).enter();g.append("rect").attr("class",(function(t,e){return"quartile-"+(0===e?"wrapper":"line")})).attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height}))}else if(e.type===st.ZOOM){var m=Dd(o,"legend","zoom"),y=(l=m.iconData,m.color),_=t.attr("role",a.IMG).attr("aria-label","zoom").selectAll("g.icon").data(l).enter();_.append("g").attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})).append("polygon").attr("points","7.7 4.82 5.78 4.82 5.78 2.89 4.82 2.89 4.82 4.82 2.89 4.82 2.89 5.78 4.82 5.78 4.82 7.7 5.78 7.7 5.78 5.78 7.7 5.78 7.7 4.82").attr("fill",(function(t){return e.color?e.color:y})),_.append("path").attr("d","M9.36,8.67A5.22,5.22,0,0,0,10.59,5.3,5.3,5.3,0,1,0,5.3,10.59,5.22,5.22,0,0,0,8.67,9.36L12.32,13l.68-.68Zm-4.06,1A4.34,4.34,0,1,1,9.63,5.3,4.33,4.33,0,0,1,5.3,9.63Z").attr("fill",(function(t){return e.color?e.color:y}))}},e.prototype.truncateLegendText=function(){var t=this.getComponentContainer(),e=Dd(this.getOptions(),"legend","truncation"),n=Dd(e,"type"),r=Dd(e,"threshold"),i=Dd(e,"numCharacter"),o=t.selectAll("div.legend-item p");o.attr("id",(function(t,e){var n=this.parentNode.querySelector("div.checkbox")||this.parentNode;return n.getAttribute("aria-labelledby")})),n!==V.NONE?o.html((function(t){return t.name.length>r?Ad(t.name,n,i):t.name})):o.html((function(t){return t.name}))},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=Dd(n,"legend"),i=Dd(r,"truncation");e.selectAll("div.legend-item").on("mouseover",(function(e){t.services.events.dispatchEvent(ft.Legend.ITEM_HOVER,{hoveredElement:eb(this)});var n=eb(this);n.select("div.checkbox").classed("hovered",!0);var r=n.datum();r.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:n,content:r.name})})).on("mousemove",(function(e){var n=eb(this).datum();n.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(){t.services.events.dispatchEvent(ft.Legend.ITEM_CLICK,{clickedElement:eb(this)});var e=eb(this),n=e.datum();t.model.toggleDataLabel(n.name)})).on("mouseout",(function(){var e=eb(this);e.select("div.checkbox").classed("hovered",!1);var n=e.datum();n.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.HIDE),t.services.events.dispatchEvent(ft.Legend.ITEM_MOUSEOUT,{hoveredElement:e})})),e.selectAll("div.legend-item div.checkbox").on("keyup",(function(e){e.key&&"Tab"===e.key&&t.services.events.dispatchEvent(ft.Legend.ITEM_HOVER,{hoveredElement:eb(this)})})),e.selectAll("div.legend-item div.checkbox").on("keydown",(function(e,n){e.key&&" "===e.key?(e.preventDefault(),t.model.toggleDataLabel(n.name)):e.key&&"Tab"===e.key&&t.services.events.dispatchEvent(ft.Legend.ITEM_MOUSEOUT,{hoveredElement:eb(this)})})),e.selectAll("g.additional-item").on("mouseover",(function(e){var n=eb(this),r=n.datum();r.name.length>i.threshold&&t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:n,content:r.name})}))},e}(DS),RS=function(t){return t},IS=1,NS=2,jS=3,BS=4,US=1e-6;function VS(t){return"translate("+t+",0)"}function HS(t){return"translate(0,"+t+")"}function GS(t){return e=>+t(e)}function zS(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function FS(){return!this.__axis}function WS(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u="undefined"!==typeof window&&window.devicePixelRatio>1?0:.5,l=t===IS||t===BS?-1:1,c=t===BS||t===NS?"x":"y",h=t===IS||t===jS?VS:HS;function f(f){var p=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,d=null==i?e.tickFormat?e.tickFormat.apply(e,n):RS:i,v=Math.max(o,0)+s,g=e.range(),m=+g[0]+u,y=+g[g.length-1]+u,_=(e.bandwidth?zS:GS)(e.copy(),u),b=f.selection?f.selection():f,w=b.selectAll(".domain").data([null]),O=b.selectAll(".tick").data(p,e).order(),x=O.exit(),E=O.enter().append("g").attr("class","tick"),T=O.select("line"),S=O.select("text");w=w.merge(w.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),O=O.merge(E),T=T.merge(E.append("line").attr("stroke","currentColor").attr(c+"2",l*o)),S=S.merge(E.append("text").attr("fill","currentColor").attr(c,l*v).attr("dy",t===IS?"0em":t===jS?"0.71em":"0.32em")),f!==b&&(w=w.transition(f),O=O.transition(f),T=T.transition(f),S=S.transition(f),x=x.transition(f).attr("opacity",US).attr("transform",(function(t){return isFinite(t=_(t))?h(t+u):this.getAttribute("transform")})),E.attr("opacity",US).attr("transform",(function(t){var e=this.parentNode.__axis;return h((e&&isFinite(e=e(t))?e:_(t))+u)}))),x.remove(),w.attr("d",t===BS||t===NS?a?"M"+l*a+","+m+"H"+u+"V"+y+"H"+l*a:"M"+u+","+m+"V"+y:a?"M"+m+","+l*a+"V"+u+"H"+y+"V"+l*a:"M"+m+","+u+"H"+y),O.attr("opacity",1).attr("transform",(function(t){return h(_(t)+u)})),T.attr(c+"2",l*o),S.attr(c,l*v).text(d),b.filter(FS).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===NS?"start":t===BS?"end":"middle"),b.each((function(){this.__axis=_}))}return f.scale=function(t){return arguments.length?(e=t,f):e},f.ticks=function(){return n=Array.from(arguments),f},f.tickArguments=function(t){return arguments.length?(n=null==t?[]:Array.from(t),f):n.slice()},f.tickValues=function(t){return arguments.length?(r=null==t?null:Array.from(t),f):r&&r.slice()},f.tickFormat=function(t){return arguments.length?(i=t,f):i},f.tickSize=function(t){return arguments.length?(o=a=+t,f):o},f.tickSizeInner=function(t){return arguments.length?(o=+t,f):o},f.tickSizeOuter=function(t){return arguments.length?(a=+t,f):a},f.tickPadding=function(t){return arguments.length?(s=+t,f):s},f.offset=function(t){return arguments.length?(u=+t,f):u},f}function qS(t){return WS(IS,t)}function $S(t){return WS(NS,t)}function YS(t){return WS(jS,t)}function ZS(t){return WS(BS,t)}var XS=function(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n},KS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="color-legend",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e.handleAxisCompleteEvent=function(t){var n=e.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}).width,i=Dd(e.getOptions(),"data","loading");if(r>Ot.color.barWidth&&!i){var o=Dd(e.getOptions(),"heatmap","colorLegend","title"),a=e.services.cartesianScales,s=a.getMainXScale(),u=s.range();if(u[0]>1&&(n.select("g.legend").attr("transform","translate("+u[0]+", 0)"),o)){var l=sb.getSVGElementSize(n.select("g.legend-title").select("text"),{useBBox:!0}).width,c=u[0]-l-9;c>1?n.select("g.legend-title").attr("transform","translate("+c+", 0)"):(n.select("g.legend").attr("transform","translate("+u[0]+", 16)"),n.select("g.legend-title").attr("transform","translate("+u[0]+", 0)"))}}else n.select("g.legend-title").attr("transform","translate(0, 0)")},e}return KS(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Axis.RENDER_COMPLETE,this.handleAxisCompleteEvent)},e.prototype.render=function(t){void 0===t&&(t=!1);var e=this.getOptions(),n=this.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}).width,i=Dd(e,"color","gradient","colors"),o=Dd(e,"heatmap","colorLegend","type"),a=Dd(e,"color","pairing","option"),s=Dd(e,"heatmap","colorLegend","title"),u=Dd(this.getOptions(),"data","loading");if(u)n.html("");else{var l=!Vh(i),c=this.model.getValueDomain(),h=!(r<=Ot.color.barWidth),f=h?Ot.color.barWidth:r,p=sb.appendOrSelect(n,"g.legend"),d=sb.appendOrSelect(p,"g.legend-axis");if(s){var v=sb.appendOrSelect(n,"g.legend-title"),g=sb.appendOrSelect(v,"text");g.text(s).attr("dy","0.7em"),p.attr("transform","translate(0, 16)")}var m=c[0]<0&&c[1]>0?"diverge":"mono";(a<1&&a>4&&"mono"===m||a<1&&a>2&&"diverge"===m)&&(a=1);var y=[],_="diverge"===m?17:11;if(l)y=i;else for(var b=1;b<_+1;b++)y.push(o===ut.LINEAR?"stop-color-"+m+"-"+a+"-"+b:"fill-"+m+"-"+a+"-"+b);var w=Ax(c[0],c[1]),O=XS(w,3),x=BE().domain(c).range([0,f]),E=YS(x).tickSize(0).tickValues(O);switch(o){case ut.LINEAR:this.drawLinear(y,p,f);break;case ut.QUANTIZE:var T=this.drawQuantize(y,m,l,p,f);x.range([T,f]);break;default:throw Error("Entered color legend type is not supported.")}d.attr("transform","translate(0,"+Ot.color.axisYTranslation+")").call(E),d.select(".domain").remove(),d.select("g.tick:last-of-type text").style("text-anchor",h?"middle":"end"),d.select("g.tick:first-of-type text").style("text-anchor",h?"middle":"start")}},e.prototype.drawLinear=function(t,e,n){var r=100/(t.length-1),i=sb.appendOrSelect(e,"linearGradient");i.attr("id",this.gradient_id+"-legend").selectAll("stop").data(t).enter().append("stop").attr("offset",(function(t,e){return e*r+"%"})).attr("class",(function(e,n){return t[n]})).attr("stop-color",(function(t){return t}));var o=sb.appendOrSelect(e,"rect");o.attr("width",n).attr("height",Ot.color.barHeight).style("fill","url(#"+this.gradient_id+"-legend)")},e.prototype.drawQuantize=function(t,e,n,r,i){n||"diverge"!==e||t.splice(t.length/2,1);var o=kE().domain(t).range([0,i]),a=sb.appendOrSelect(r,"g.quantized-rect");return a.selectAll("rect").data(o.domain()).join("rect").attr("x",(function(t){return o(t)})).attr("y",0).attr("width",Math.max(0,o.bandwidth()-1)).attr("height",Ot.color.barHeight).attr("class",(function(t){return t})).attr("fill",(function(t){return t})),"mono"===(!n&&e)?o.bandwidth()-1:0},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Axis.RENDER_COMPLETE,this.handleAxisCompleteEvent)},e}(PS),JS=(n("9b04"),{prefix:"bx",selectorTabbable:"\n a[href], area[href], input:not([disabled]):not([tabindex='-1']),\n button:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']),\n textarea:not([disabled]):not([tabindex='-1']),\n iframe, object, embed, *[tabindex]:not([tabindex='-1']), *[contenteditable=true]\n ",selectorFocusable:"\n a[href], area[href], input:not([disabled]),\n button:not([disabled]),select:not([disabled]),\n textarea:not([disabled]),\n iframe, object, embed, *[tabindex], *[contenteditable=true]\n "}),tM=JS;function eM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function nM(t,e,n){return e&&eM(t.prototype,e),n&&eM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function rM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function iM(t){return uM(t)||sM(t)||aM(t)||oM()}function oM(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function aM(t,e){if(t){if("string"===typeof t)return lM(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?lM(t,e):void 0}}function sM(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function uM(t){if(Array.isArray(t))return lM(t)}function lM(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function cM(t){return t.reduce((function(t,e){return Array.isArray(e)?t.push.apply(t,iM(cM(e))):t.push(e),t}),[])}function hM(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return cM(e).reduce((function(t,e){return e(t)}),function(){function t(){rM(this,t)}return nM(t)}())}function fM(t){return fM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fM(t)}function pM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function dM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function vM(t,e,n){return e&&dM(t.prototype,e),n&&dM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function gM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&mM(t,e)}function mM(t,e){return mM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},mM(t,e)}function yM(t){var e=wM();return function(){var n,r=OM(t);if(e){var i=OM(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _M(this,n)}}function _M(t,e){if(e&&("object"===fM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return bM(t)}function bM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function wM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function OM(t){return OM=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},OM(t)}var xM=function(t){var e=function(t){gM(n,t);var e=yM(n);function n(t){var r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(pM(this,n),r=e.call(this,t,i),r.children=[],!t||t.nodeType!==Node.ELEMENT_NODE)throw new TypeError("DOM element should be given to initialize this widget.");return r.element=t,r.options=Object.assign(Object.create(r.constructor.options),i),r.constructor.components.set(r.element,bM(r)),r}return vM(n,[{key:"release",value:function(){for(var t=this.children.pop();t;t=this.children.pop())t.release();return this.constructor.components.delete(this.element),null}}],[{key:"create",value:function(t,e){return this.components.get(t)||new this(t,e)}}]),n}(t);return e};function EM(t,e){var n=t.target,r=t.currentTarget;if("function"===typeof n.matches){if(n.matches(e))return n;if(n.matches("".concat(e," *"))){var i=n.closest(e);if((r.nodeType===Node.DOCUMENT_NODE?r.documentElement:r).contains(i))return i}}}function TM(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return t.addEventListener.apply(t,n),{release:function(){return t.removeEventListener.apply(t,n),null}}}function SM(t){return SM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},SM(t)}function MM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function CM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function AM(t,e,n){return e&&CM(t.prototype,e),n&&CM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function LM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&DM(t,e)}function DM(t,e){return DM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},DM(t,e)}function kM(t){var e=IM();return function(){var n,r=NM(t);if(e){var i=NM(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return PM(this,n)}}function PM(t,e){if(e&&("object"===SM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return RM(t)}function RM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function IM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function NM(t){return NM=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},NM(t)}var jM=function(t){var e=function(t){LM(n,t);var e=kM(n);function n(){return MM(this,n),e.apply(this,arguments)}return AM(n,null,[{key:"init",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=Object.assign(Object.create(this.options),n);if(!e||e.nodeType!==Node.ELEMENT_NODE&&e.nodeType!==Node.DOCUMENT_NODE)throw new TypeError("DOM document or DOM element should be given to search for and initialize this widget.");if(e.nodeType!==Node.ELEMENT_NODE||!e.matches(r.selectorInit)){var i=r.initEventNames.map((function(i){return TM(e,i,(function(e){var i=EM(e,"[".concat(r.attribInitTarget,"]"));if(i){e.delegateTarget=i;var o=i.ownerDocument.querySelectorAll(i.getAttribute(r.attribInitTarget));if(o.length>1)throw new Error("Target widget must be unique.");if(1===o.length){"A"===i.tagName&&e.preventDefault();var a=t.create(o[0],n);"function"===typeof a.createdByLauncher&&a.createdByLauncher(e)}}}))}));return{release:function(){for(var t=i.pop();t;t=i.pop())t.release()}}}return this.create(e,n),""}}]),n.forLazyInit=!0,n}(t);return e};function BM(t){return BM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},BM(t)}function UM(t){return zM(t)||GM(t)||HM(t)||VM()}function VM(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function HM(t,e){if(t){if("string"===typeof t)return FM(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?FM(t,e):void 0}}function GM(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function zM(t){if(Array.isArray(t))return FM(t)}function FM(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function WM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function qM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function $M(t,e,n){return e&&qM(t.prototype,e),n&&qM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function YM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ZM(t,e)}function ZM(t,e){return ZM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},ZM(t,e)}function XM(t){var e=JM();return function(){var n,r=tC(t);if(e){var i=tC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return KM(this,n)}}function KM(t,e){if(e&&("object"===BM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return QM(t)}function QM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function JM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function tC(t){return tC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},tC(t)}var eC=function(t){var e=function(t){YM(n,t);var e=XM(n);function n(){return WM(this,n),e.apply(this,arguments)}return $M(n,[{key:"_changeState",value:function(){throw new Error("_changeState() should be overridden to perform actual change in state.")}},{key:"changeState",value:function(){for(var t=this,e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var i="string"===typeof n[0]?n.shift():void 0,o=Object(n[0])===n[0]&&"function"!==typeof n[0]?n.shift():void 0,a="function"===typeof n[0]?n.shift():void 0;if("function"!==typeof this.shouldStateBeChanged||this.shouldStateBeChanged(i,o)){var s={group:o&&o.group,state:i},u=[s.group,i].filter(Boolean).join("-").split("-").map((function(t){return t[0].toUpperCase()+t.substr(1)})).join(""),l=new CustomEvent(this.options["eventBefore".concat(u)],{bubbles:!0,cancelable:!0,detail:o}),c=o&&o.delegatorNode||this.element,h=!c.dispatchEvent(l);if(h){if(a){var f=new Error("Changing state (".concat(JSON.stringify(s),") has been canceled."));f.canceled=!0,a(f)}}else{var p=[i,o].filter(Boolean);this._changeState.apply(this,UM(p).concat([function(){c.dispatchEvent(new CustomEvent(t.options["eventAfter".concat(u)],{bubbles:!0,cancelable:!0,detail:o})),a&&a()}]))}}else a&&a(null,!0)}}]),n}(t);return e};function nC(t){if(!t||"function"===typeof t)return{launchingElement:null,launchingEvent:null};var e=t.delegateTarget||t.currentTarget||t,n=t.currentTarget&&t;if(e&&!e.nodeType)throw new TypeError("DOM Node should be given for launching element.");if(n&&!n.type)throw new TypeError("DOM event should be given for launching event.");return{launchingElement:e,launchingEvent:n}}function rC(t){return rC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rC(t)}function iC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function oC(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function aC(t,e,n){return e&&oC(t.prototype,e),n&&oC(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function sC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&uC(t,e)}function uC(t,e){return uC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},uC(t,e)}function lC(t){var e=fC();return function(){var n,r=pC(t);if(e){var i=pC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return cC(this,n)}}function cC(t,e){if(e&&("object"===rC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return hC(t)}function hC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function fC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function pC(t){return pC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},pC(t)}function dC(t){var e=function(t){sC(n,t);var e=lC(n);function n(){return iC(this,n),e.apply(this,arguments)}return aC(n,[{key:"show",value:function(t,e){t&&"function"!==typeof t||(e=t),this.changeState("shown",nC(t),e)}},{key:"hide",value:function(t,e){t&&"function"!==typeof t||(e=t),this.changeState("hidden",nC(t),e)}}]),n}(t);return e}var vC=[eC,dC],gC=vC;function mC(t){return mC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mC(t)}function yC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _C(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function bC(t,e,n){return e&&_C(t.prototype,e),n&&_C(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function wC(){return wC="undefined"!==typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=OC(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(arguments.length<3?t:n):i.value}},wC.apply(this,arguments)}function OC(t,e){while(!Object.prototype.hasOwnProperty.call(t,e))if(t=AC(t),null===t)break;return t}function xC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&EC(t,e)}function EC(t,e){return EC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},EC(t,e)}function TC(t){var e=CC();return function(){var n,r=AC(t);if(e){var i=AC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return SC(this,n)}}function SC(t,e){if(e&&("object"===mC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return MC(t)}function MC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function CC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function AC(t){return AC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},AC(t)}var LC=function(t){var e=function(t){xC(n,t);var e=TC(n);function n(){var t;yC(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return t=e.call.apply(e,[this].concat(i)),t.handles=new Set,t}return bC(n,[{key:"manage",value:function(t){return this.handles.add(t),t}},{key:"unmanage",value:function(t){return this.handles.delete(t),t}},{key:"release",value:function(){var t=this;return this.handles.forEach((function(e){e.release(),t.handles.delete(e)})),wC(AC(n.prototype),"release",this).call(this)}}]),n}(t);return e};function DC(t){return DC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},DC(t)}function kC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function PC(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function RC(t,e,n){return e&&PC(t.prototype,e),n&&PC(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function IC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&NC(t,e)}function NC(t,e){return NC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},NC(t,e)}function jC(t){var e=VC();return function(){var n,r=HC(t);if(e){var i=HC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return BC(this,n)}}function BC(t,e){if(e&&("object"===DC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return UC(t)}function UC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function VC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function HC(t){return HC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},HC(t)}var GC,zC,FC=function(t){IC(n,t);var e=jC(n);function n(t,r){var i;return kC(this,n),i=e.call(this,t,r),i._handleFocusinListener=void 0,i._handleKeydownListener=void 0,i._handleFocusin=function(t){var e=i.element.querySelector(i.options.selectorModalContainer)||i.element;i.element.classList.contains(i.options.classVisible)&&!e.contains(t.target)&&i.options.selectorsFloatingMenus.every((function(e){return!EM(t,e)}))&&i.element.querySelector(tM.selectorTabbable).focus()},i._hookCloseActions(),i}return RC(n,[{key:"createdByLauncher",value:function(t){this.show(t)}},{key:"shouldStateBeChanged",value:function(t){return"shown"===t?!this.element.classList.contains(this.options.classVisible):this.element.classList.contains(this.options.classVisible)}},{key:"_changeState",value:function(t,e,n){var r,i=this,o=function(){if(r&&(r=i.unmanage(r).release()),"shown"===t&&i.element.offsetWidth>0&&i.element.offsetHeight>0){i.previouslyFocusedNode=i.element.ownerDocument.activeElement;var e=i.element.querySelector(i.options.selectorPrimaryFocus)||i.element.querySelector(tM.selectorTabbable);e.focus()}n()};if(this._handleFocusinListener&&(this._handleFocusinListener=this.unmanage(this._handleFocusinListener).release()),"shown"===t){var a="onfocusin"in this.element.ownerDocument.defaultView,s=a?"focusin":"focus";this._handleFocusinListener=this.manage(TM(this.element.ownerDocument,s,this._handleFocusin,!a))}"hidden"===t?(this.element.classList.toggle(this.options.classVisible,!1),this.element.ownerDocument.body.classList.toggle(this.options.classBody,!1),(this.options.selectorFocusOnClose||this.previouslyFocusedNode)&&(this.element.ownerDocument.querySelector(this.options.selectorFocusOnClose)||this.previouslyFocusedNode).focus()):"shown"===t&&(this.element.classList.toggle(this.options.classVisible,!0),this.element.ownerDocument.body.classList.toggle(this.options.classBody,!0)),r=this.manage(TM(this.element,"transitionend",o))}},{key:"_hookCloseActions",value:function(){var t=this;this.manage(TM(this.element,"click",(function(e){var n=EM(e,t.options.selectorModalClose);n&&(e.delegateTarget=n),(n||e.target===t.element)&&t.hide(e)}))),this._handleKeydownListener&&(this._handleKeydownListener=this.unmanage(this._handleKeydownListener).release()),this._handleKeydownListener=this.manage(TM(this.element.ownerDocument.body,"keydown",(function(e){27===e.which&&t.shouldStateBeChanged("hidden")&&(e.stopPropagation(),t.hide(e))})))}}],[{key:"options",get:function(){var t=tM.prefix;return{selectorInit:"[data-modal]",selectorModalClose:"[data-modal-close]",selectorPrimaryFocus:"[data-modal-primary-focus]",selectorsFloatingMenus:[".".concat(t,"--overflow-menu-options"),".".concat(t,"--tooltip"),".flatpickr-calendar"],selectorModalContainer:".".concat(t,"--modal-container"),classVisible:"is-visible",classBody:"".concat(t,"--body--with-modal-open"),attribInitTarget:"data-modal-target",initEventNames:["click"],eventBeforeShown:"modal-beingshown",eventAfterShown:"modal-shown",eventBeforeHidden:"modal-beinghidden",eventAfterHidden:"modal-hidden"}}}]),n.components=new WeakMap,n}(hM(xM,jM,gC,LC)),WC=FC,qC=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),$C=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="modal",i.isEventListenerAdded=!1,i.handleShowModal=function(){i.modal.html(i.getModalHTML()),i.modal.select("div.cds--modal-footer button.cds--btn").on("click",(function(){return i.model.exportToCSV()}));var t=WC.create(i.modal.node());t.show()},i.init(),i}return qC(e,t),e.prototype.addEventListeners=function(){this.services.events.addEventListener(ft.Modal.SHOW,this.handleShowModal)},e.prototype.removeEventListeners=function(){this.services.events.removeEventListener(ft.Modal.SHOW,this.handleShowModal)},e.prototype.getModalHTML=function(){var t=this.model.getOptions(),e=Dd(t,"style","prefix"),n=this.model.getTabularDataArray();return'\n\t\t<div class="cds--modal-container cds--modal-container">\n\t\t\t<div class="cds--modal-header cds--modal-header">\n\t\t\t\t<p class="cds--modal-header__label cds--type-delta cds--modal-header__label cds--type-delta" id="modal-title">Tabular representation</p>\n\n\t\t\t\t<p class="cds--modal-header__heading cds--type-beta cds--modal-header__heading cds--type-beta" id="modal-description">'+t.title+'</p>\n\n\t\t\t\t<button class="cds--modal-close cds--modal-close" type="button" data-modal-close aria-label="close modal" data-modal-primary-focus>\n\t\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet" xmlns="http://www.w3.org/2000/svg" fill="currentColor" aria-label="Close" width="20" height="20" viewBox="0 0 32 32" role="img" class="cds--modal-close__icon cds--modal-close__icon">\n\t\t\t\t\t\t<path d="M24 9.4L22.6 8 16 14.6 9.4 8 8 9.4 14.6 16 8 22.6 9.4 24 16 17.4 22.6 24 24 22.6 17.4 16 24 9.4z"></path>\n\t\t\t\t\t</svg>\n\t\t\t\t</button>\n\t\t\t</div>\n\n\t\t\t<div class="cds--modal-content cds--modal-content">\n\t\t\t\t<table class="cds--data-table cds--data-table--no-border cds--data-table cds--data-table--no-border">\n\t\t\t\t\t<thead>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t'+tl(n,0).map((function(t){return'<th scope="col">\n\t\t\t\t\t\t\t\t<div class="cds--table-header-label cds--table-header-label">'+t+"</div>\n\t\t\t\t\t\t\t</th>"})).join("")+"\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</thead>\n\n\t\t\t\t\t<tbody>"+n.slice(1).map((function(t){return"\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t"+t.map((function(t){return"<td>"+t+"</td>"})).join("")+"\n\t\t\t\t\t\t\t</tr>"})).join("")+'\n\t\t\t\t\t</tbody>\n\t\t\t\t</table>\n\t\t\t</div>\n\n\t\t\t<div class="cds--modal-footer cds--modal-footer">\n\t\t\t <div class="'+dt+"--"+e+'-modal-footer-spacer"></div>\n\t\t\t <button class="cds--btn cds--btn--primary cds--btn cds--btn--primary" type="button" data-modal-primary-focus>Download as CSV</button>\n\t\t\t</div>\n\t\t</div>'},e.prototype.render=function(){var t=this.model.getOptions();if(!this.isEventListenerAdded){var e=eb(this.services.domUtils.getHolder()),n=Dd(t,"style","prefix");this.modal=sb.appendOrSelect(e,"div."+dt+"--"+n+"--modal"),this.addEventListeners(),this.isEventListenerAdded=!0,this.modal.attr("data-modal",!0).attr("class","cds--modal cds--modal").attr("role","dialog").attr("aria-modal",!0).attr("aria-labelledby","modal-title").attr("aria-describedby","modal-description").attr("tabindex",-1)}},e.prototype.destroy=function(){this.removeEventListeners(),this.isEventListenerAdded=!1},e}(DS);(function(t){t["LEFT"]="left",t["RIGHT"]="right",t["TOP"]="top",t["BOTTOM"]="bottom"})(zC||(zC={}));var YC=(GC={},GC[zC.LEFT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left-e.offsetWidth)}},GC[zC.RIGHT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left+n.width)}},GC[zC.TOP]=function(t,e,n){return{top:Math.round(t.top-e.offsetHeight),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},GC[zC.BOTTOM]=function(t,e,n){return{top:Math.round(t.top+n.height),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},GC),ZC="undefined"!==typeof window?window:{innerHeight:0,scrollY:0,innerWidth:0,scrollX:0},XC=function(){function t(t){void 0===t&&(t={}),this.positions=YC,this.positions=Object.assign({},YC,t)}return t.prototype.getRelativeOffset=function(t){var e={left:t.offsetLeft,top:t.offsetTop};while(t.offsetParent&&"static"===getComputedStyle(t.offsetParent).position)e.left+=t.offsetLeft,e.top+=t.offsetTop,t=t.offsetParent;return e},t.prototype.getAbsoluteOffset=function(t){var e=t,n={top:0,left:0};while(e.offsetParent){var r=getComputedStyle(e.offsetParent);"static"===r.position&&r.marginLeft&&r.marginTop&&(parseInt(r.marginTop,10)&&(n.top+=parseInt(r.marginTop,10)),parseInt(r.marginLeft,10)&&(n.left+=parseInt(r.marginLeft,10))),e=e.offsetParent}var i=t.getBoundingClientRect(),o=document.body.getBoundingClientRect();return{top:i.top-o.top+n.top,left:i.left-o.left+n.left}},t.prototype.findRelative=function(t,e,n){var r=this.getRelativeOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findAbsolute=function(t,e,n){var r=this.getAbsoluteOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findPosition=function(t,e,n,r){void 0===r&&(r=this.getAbsoluteOffset.bind(this));var i=r(t),o=t.getBoundingClientRect();return this.calculatePosition(i,o,e,n)},t.prototype.findPositionAt=function(t,e,n){return this.calculatePosition(t,{top:0,left:0,height:0,width:0},e,n)},t.prototype.getPlacementBox=function(t,e){var n=t.offsetHeight+e.top,r=t.offsetWidth+e.left;return{top:e.top,bottom:n,left:e.left,right:r}},t.prototype.addOffset=function(t,e,n){return void 0===e&&(e=0),void 0===n&&(n=0),Object.assign({},t,{top:t.top+e,left:t.left+n})},t.prototype.setElement=function(t,e){t.style.top=e.top+"px",t.style.left=e.left+"px"},t.prototype.findBestPlacement=function(t,e,n,r,i){var o=this;void 0===r&&(r=this.defaultContainerFunction.bind(this)),void 0===i&&(i=this.findPosition.bind(this));var a=n.map((function(n){var a=i(t,e,n),s=o.getPlacementBox(e,a),u=0,l=0,c=r();s.top<c.top?u=c.top-s.top:s.bottom>c.height&&(u=s.bottom-c.height),s.left<c.left?l=c.left-s.left:s.right>c.width&&(l=s.right-c.width),u&&!l?l=1:l&&!u&&(u=1);var h=e.offsetHeight*e.offsetWidth,f=u*l,p=h-f,d=p/h;return{placement:n,weight:d}}));return a.sort((function(t,e){return e.weight-t.weight})),a[0].placement},t.prototype.findBestPlacementAt=function(t,e,n,r){var i=this;void 0===r&&(r=this.defaultContainerFunction.bind(this));var o=function(e,n,r){return i.findPositionAt(t,n,r)};return this.findBestPlacement(null,e,n,r,o)},t.prototype.defaultContainerFunction=function(){return{top:0,left:0,height:ZC.innerHeight,width:ZC.innerWidth}},t.prototype.calculatePosition=function(t,e,n,r){return this.positions[r]?this.positions[r](t,n,e):(console.error("No function found for placement, defaulting to 0,0"),{left:0,top:0})},t}(),KC=(new XC,XC),QC=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),JC=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.type="threshold",r.renderType=I.SVG,r.positionService=new KC,r}return QC(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n=Dd(this.getOptions(),"axes"),r=[];Object.keys(n).forEach((function(t){var e,i;if(Object.values(B).includes(t)){var o=n[t];o.thresholds&&o.thresholds.length>0&&r.push({axisPosition:t,thresholds:o.thresholds,correspondingDatasets:null===(e=o)||void 0===e?void 0:e.correspondingDatasets,mapsTo:null===(i=o)||void 0===i?void 0:i.mapsTo})}}));var i=this.getComponentContainer({withinChartClip:!0}),o=i.selectAll("g.axis-thresholds").data(r,(function(t){return t.axisPosition}));o.exit().attr("opacity",0).remove();var a=o.enter().append("g"),s=a.merge(o);s.attr("class",(function(t){return"axis-thresholds "+t.axisPosition}));var u=s.selectAll("g.threshold-group").data((function(t){return t.thresholds.map((function(n){return n.axisPosition=t.axisPosition,n.datum=e.constructDatumObj(t,n),n}))}));u.exit().attr("opacity",0).remove();var l=u.enter().append("g");l.append("line").attr("class","threshold-line"),l.append("rect").attr("class","threshold-hoverable-area");var c=l.merge(u);c.attr("class","threshold-group");var h=this;s.each((function(e){var n=e.axisPosition,r=h.services.cartesianScales.getScaleByPosition(n),i=h.services.cartesianScales.getScaleTypeByPosition(n),o=null,a=null;n===B.LEFT||n===B.RIGHT?(a=r,o=h.services.cartesianScales.getMainXScale()):(o=r,a=h.services.cartesianScales.getMainYScale());var s=i===G.LABELS,u=o.range(),l=u[0],c=u[1],f=a.range(),p=f[0],d=f[1],v=h.services.cartesianScales,g=v.getOrientation(),m=function(t){return v.getDomainValue(t)},y=function(t){return v.getRangeValue(t)},_=Rd(m,y,g),b=_[0],w=_[1],O=eb(this);n===B.TOP||n===B.BOTTOM?(O.selectAll("line.threshold-line").transition().call((function(e){return h.services.transitions.setupTransition({transition:e,name:"threshold-line-update",animate:t})})).attr("y1",d).attr("y2",p).attr("x1",(function(t){var e=t.datum;return b(e)+(s?r.step()/2:0)})).attr("x2",(function(t){var e=t.datum;return b(e)+(s?r.step()/2:0)})).style("stroke",(function(t){var e=t.fillColor;return e})),O.selectAll("rect.threshold-hoverable-area").attr("x",0).attr("y",(function(t){var e=t.datum;return-b(e)})).attr("width",Math.abs(p-d)).classed("rotate",!0)):(O.selectAll("line.threshold-line").transition().call((function(e){return h.services.transitions.setupTransition({transition:e,name:"threshold-line-update",animate:t})})).attr("x1",l).attr("x2",c).attr("y1",(function(t){var e=t.datum;return w(e)+(s?r.step()/2:0)})).attr("y2",(function(t){var e=t.datum;return w(e)+(s?r.step()/2:0)})).style("stroke",(function(t){var e=t.fillColor;return e})),O.selectAll("rect.threshold-hoverable-area").attr("x",l).attr("y",(function(t){var e=t.datum;return w(e)})).attr("width",Math.abs(c-l)).classed("rotate",!1))})),this.services.events.addEventListener(ft.Threshold.SHOW,(function(t){e.setThresholdLabelPosition(t.detail),e.label.classed("hidden",!1)})),this.services.events.addEventListener(ft.Threshold.HIDE,(function(t){e.label.classed("hidden",!0)})),this.appendThresholdLabel(),this.addEventListeners()},e.prototype.getFormattedValue=function(t){var e=t.value,n=t.axisPosition,r=this.getOptions(),i=this.services.cartesianScales.getScaleTypeByPosition(n);if(i===G.TIME){var o=[B.LEFT,B.RIGHT].includes(n),a=this.services.cartesianScales.getMainXScale(),s=this.services.cartesianScales.getMainYScale(),u=o?s:a,l=Dd(r,"timeScale"),c=$m(u.ticks());return zm(e,0,u.ticks(),c,l)}return e.toLocaleString("en")},e.prototype.appendThresholdLabel=function(){var t=eb(this.services.domUtils.getHolder()),e=Dd(this.getOptions(),"style","prefix");this.label=sb.appendOrSelect(t,"div."+dt+"--"+e+"--threshold--label").classed("hidden",!0)},e.prototype.setThresholdLabelPosition=function(t){var e=t.event,n=t.datum,r=this.services.domUtils.getHolder(),i=wd(e,r),o=n.valueFormatter?n.valueFormatter(n.value):this.getFormattedValue(n);this.label.html((n.label||"Threshold")+": "+o).style("background-color",n.fillColor);var a=this.label.node(),s=this.positionService.findBestPlacementAt({left:i[0],top:i[1]},a,[zC.RIGHT,zC.LEFT,zC.TOP,zC.BOTTOM],(function(){return{top:void 0,left:void 0,width:r.offsetWidth,height:r.offsetHeight}})),u=this.positionService.findPositionAt({left:i[0],top:i[1]},a,s);this.positionService.setElement(a,u)},e.prototype.constructDatumObj=function(t,e){var n={};return t.correspondingDatasets&&(n["group"]=Dd(t,"correspondingDatasets",0)),n[t["mapsTo"]]=e.value,n},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer({withinChartClip:!0});e.selectAll("rect.threshold-hoverable-area").on("mouseover mousemove",(function(e){eb(this.parentNode).select("line.threshold-line").classed("active",!0),t.services.events.dispatchEvent(ft.Threshold.SHOW,{event:e,hoveredElement:eb(this),datum:eb(this).datum()})})).on("mouseout",(function(e){eb(this.parentNode).select("line.threshold-line").classed("active",!1),t.services.events.dispatchEvent(ft.Threshold.HIDE,{event:e,hoveredElement:eb(this),datum:eb(this).datum()})}))},e}(DS),tA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="title",e.renderType=I.HTML,e}return tA(e,t),e.prototype.render=function(){var t=this.getComponentContainer(),e=Dd(this.getOptions(),"title"),n=t.selectAll("p.title").data([e]);if(n.enter().append("p").classed("title",!0).attr("role","heading").attr("aria-level",2).merge(n).html((function(t){return t})),n.node()&&n.node().offsetWidth<n.node().scrollWidth){var r=this;n.on("mouseover",(function(t){r.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:n,content:n.text()})})).on("mousemove",(function(t){r.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(){r.services.events.dispatchEvent(ft.Tooltip.HIDE)}))}n.exit().remove()},e.prototype.truncateTitle=function(t,e){if(!(e<=0)){var n=t.text();if(t.node().getComputedTextLength()>e){t.append("tspan").text("...");var r=sb.appendOrSelect(t,"tspan").node().getComputedTextLength(),i=t.text(),o=this.getSubstringIndex(t.node(),0,i.length-1,e-r);t.html(i.substring(0,o-1)).append("tspan").text("...");var a=this;t.on("mouseover",(function(e){a.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:t,content:n})})).on("mousemove",(function(t){a.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(){a.services.events.dispatchEvent(ft.Tooltip.HIDE)}))}}},e.prototype.getMaxTitleWidth=function(){return sb.getSVGElementSize(this.parent.node(),{useAttrs:!0}).width},e.prototype.getSubstringIndex=function(t,e,n,r){var i=Math.floor((n+e)/2);return t.getSubStringLength(0,i)>r?this.getSubstringIndex(t,e,i,r):t.getSubStringLength(0,i)<r?t.getSubStringLength(0,i+1)>r?i:this.getSubstringIndex(t,i,n,r):i},e}(DS),nA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="meter-title",e.renderType=I.SVG,e}return nA(e,t),e.prototype.render=function(){var t=Dd(this.model.getDisplayData(),0),e=this.getOptions(),n=this.getComponentContainer(),r=e.data.groupMapsTo,i=Dd(e,"meter","proportional");if(i)this.displayTotal(),this.displayBreakdownTitle();else{var o=n.selectAll("text.meter-title").data([t[r]]);o.enter().append("text").classed("meter-title",!0).merge(o).attr("x",0).attr("y","1em").text((function(t){return t})),o.exit().remove(),this.appendPercentage()}this.displayStatus();var a=this.getMaxTitleWidth(),s=sb.appendOrSelect(n,"text.meter-title");a>0&&s.node().getComputedTextLength()>a&&this.truncateTitle(s,a)},e.prototype.displayBreakdownTitle=function(){var t,e=this.getComponentContainer(),n=this.getOptions(),r=this.model.getMaximumDomain(this.model.getDisplayData()),i=Dd(n,"meter","proportional","total"),o=Dd(n,"meter","proportional","unit")?Dd(n,"meter","proportional","unit"):"";if(r===i)t=null;else{var a=null!==i?i-r:r,s=Dd(n,"meter","proportional","breakdownFormatter");t=null!==s?s({datasetsTotal:r,total:i}):r+" "+o+" used ("+a+" "+o+" available)"}var u=e.selectAll("text.proportional-meter-title").data([t]);u.enter().append("text").classed("proportional-meter-title",!0).merge(u).attr("x",0).attr("y","1em").text((function(t){return t})),u.exit().remove();var l=this.getMaxTitleWidth(),c=sb.appendOrSelect(e,"text.proportional-meter-title");l>0&&c.node().getComputedTextLength()>l&&this.truncateTitle(c,l)},e.prototype.displayTotal=function(){var t=this.getComponentContainer(),e=this.getOptions(),n=Dd(e,"meter","proportional","total"),r=n?Dd(e,"meter","proportional","total"):this.model.getMaximumDomain(this.model.getDisplayData()),i=Dd(e,"meter","proportional","unit")?Dd(e,"meter","proportional","unit"):"",o=Dd(e,"meter","proportional","totalFormatter"),a=null!==o?o(r):n+" "+i+" total",s=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),u=s.width?s.width:this.parent.node().getAttribute("width"),l=t.selectAll("text.proportional-meter-total").data([a]);l.enter().append("text").classed("proportional-meter-total",!0).merge(l).attr("x",this.model.getStatus()?u-Et.total.paddingRight:u).attr("y","1em").attr("text-anchor","end").text((function(t){return t})),l.exit().remove()},e.prototype.displayStatus=function(){var t=this,e=this.getComponentContainer(),n=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),r=n.width?n.width:0,i=this.model.getStatus(),o=Et.status.indicatorSize/2,a=sb.appendOrSelect(e,"g.status-indicator").attr("class",null!==i?"status-indicator status--"+i:"").attr("transform","translate("+(r-o)+", 0)"),s=i?[i]:[],u=a.selectAll("circle.status").data(s);u.enter().append("circle").merge(u).attr("class","status").attr("r",o).attr("cx",0).attr("cy","calc(1em / 2)");var l=a.selectAll("path.innerFill").data(s);l.enter().append("path").merge(l).attr("d",t.getStatusIconPathString(i)).attr("transform","translate(-"+o+", 0)").attr("class","innerFill"),l.exit().remove(),u.exit().remove()},e.prototype.appendPercentage=function(){var t=Dd(this.model.getDisplayData(),0,"value"),e=this.getComponentContainer(),n=sb.appendOrSelect(e,"text.meter-title"),r=!0===Dd(this.getOptions(),"meter","statusBar","percentageIndicator","enabled")?[t]:[],i=e.selectAll("text.percent-value").data(r),o=Et.statusBar.paddingRight;i.enter().append("text").classed("percent-value",!0).merge(i).text((function(t){return t+"%"})).attr("x",+n.attr("x")+n.node().getComputedTextLength()+o).attr("y",n.attr("y")),i.exit().remove()},e.prototype.truncateTitle=function(e,n){t.prototype.truncateTitle.call(this,e,n);var r=sb.appendOrSelect(this.parent,"tspan"),i=Et.statusBar.paddingRight,o=Math.ceil(r.node().getComputedTextLength()),a=sb.appendOrSelect(this.parent,"text.percent-value");a.attr("x",+e.attr("x")+e.node().getComputedTextLength()+o+i)},e.prototype.getMaxTitleWidth=function(){var t=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),e=Dd(this.getOptions(),"meter","proportional"),n=t.width?t.width:this.parent.node().getAttribute("width");if(null!==e){var r=sb.appendOrSelect(this.parent,"text.proportional-meter-total").node(),i=sb.getSVGElementSize(r,{useBBox:!0}).width;return n-i-Et.total.paddingLeft}var o=sb.appendOrSelect(this.parent,"text.percent-value"),a=Et.statusBar.paddingRight,s=o.node().getComputedTextLength(),u=sb.appendOrSelect(this.parent,"g.status-indicator").node(),l=sb.getSVGElementSize(u,{useBBox:!0}).width+Et.status.paddingLeft;return n-s-a-l},e.prototype.getStatusIconPathString=function(t){switch(t){case nt.SUCCESS:return"M6.875 11.3125 3.75 8.1875 4.74375 7.25 6.875 9.34375 11.50625 4.75 12.5 5.7375 Z";case nt.DANGER:return"M10.7 11.5 4.5 5.3 5.3 4.5 11.5 10.7 Z";case nt.WARNING:return"M7.9375,11.125 C7.41973305,11.125 7,11.544733 7,12.0625 C7,12.580267 7.41973305,13 7.9375,13 C8.45526695,13 8.875,12.580267 8.875,12.0625 C8.875,11.544733 8.45526695,11.125 7.9375,11.125 M7.3125, 3 8.5625, 3 8.5625, 9.875 7.3125, 9.875, 7.3125, 3 Z"}},e}(eA),iA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oA=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="tooltip",i.renderType=I.HTML,i.isEventListenerAdded=!1,i.positionService=new KC,i.handleShowTooltip=function(t){var e,n=t.detail.data||t.detail.items,r=i.formatItems(i.getItems(t));e=t.detail.content?'<div class="title-tooltip"><p>'+t.detail.content+"</p></div>":i.getTooltipHTML(r);var o=sb.appendOrSelect(i.tooltip,"div.content-box");if(Dd(i.getOptions(),"tooltip","customHTML"))if(t.detail.content){var a='<div class="title-tooltip"><p>'+t.detail.content+"</p></div>";o.html(a)}else o.html(i.model.getOptions().tooltip.customHTML(n,e));else o.html(e);o.selectAll(".datapoint-tooltip").each((function(t,e){var n=r[e];r[e]&&r[e].color&&eb(this).select(".tooltip-color").attr("class","tooltip-color").style("background-color",n.color)})),i.positionTooltip(t),i.tooltip.classed("hidden",!1).attr("aria-hidden",!1)},i.handleHideTooltip=function(){i.tooltip.classed("hidden",!0).attr("aria-hidden",!0)},i.init(),i}return iA(e,t),e.prototype.addTooltipEventListener=function(){var t=this;this.services.events.addEventListener(ft.Tooltip.MOVE,(function(e){!1===t.tooltip.classed("hidden")&&t.positionTooltip(e)})),this.services.events.addEventListener(ft.Tooltip.SHOW,this.handleShowTooltip),this.services.events.addEventListener(ft.Tooltip.HIDE,this.handleHideTooltip),this.services.events.addEventListener(ft.Chart.MOUSEOUT,this.handleHideTooltip)},e.prototype.removeTooltipEventListener=function(){this.services.events.removeEventListener(ft.Tooltip.MOVE,null),this.services.events.removeEventListener(ft.Tooltip.SHOW,this.handleShowTooltip),this.services.events.removeEventListener(ft.Tooltip.HIDE,this.handleHideTooltip),this.services.events.removeEventListener(ft.Chart.MOUSEOUT,this.handleHideTooltip)},e.prototype.getItems=function(t){return t.detail.items?t.detail.items:[]},e.prototype.formatItems=function(t){var e=this,n=this.getOptions(),r=Dd(n,"tooltip","truncation","type"),i=Dd(n,"tooltip","truncation","threshold"),o=Dd(n,"tooltip","truncation","numCharacter");return r!==V.NONE?t.map((function(t){var n=t.labelIcon?12:0;return t.value=t.value?e.valueFormatter(t.value,t.label):t.value,t.label&&t.label.length+n>i&&(t.label=Ad(t.label,r,o)),t.value&&t.value.length>i&&(t.value=Ad(t.value,r,o)),t})):t},e.prototype.getTooltipHTML=function(t){return'<ul class="multi-tooltip">'+t.map((function(t){return'<li>\n\t\t\t\t\t<div class="datapoint-tooltip'+(t.bold?" bold":"")+'">\n\t\t\t\t\t\t'+(t.class||t.color?'<div class="tooltip-color '+t.class+'"></div>':"")+'\n\t\t\t\t\t\t<div class="label">\n\t\t\t\t\t\t<p>'+(t.label||"")+"</p>\n\t\t\t\t\t\t"+(t.labelIcon?'<span class="label-icon"/>'+t.labelIcon+"</span>":"")+"\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t"+(void 0===t.value||null===t.value?"":'<p class="value"/>'+t.value+"</p>")+"\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"</ul>"},e.prototype.valueFormatter=function(t,e){var n=this.getOptions(),r=Dd(n,"tooltip","valueFormatter");if(r)return r(t,e);if("function"===typeof t.getTime)return Bm(t,"MMM d, yyyy");try{if("string"===typeof t&&/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z/.test(t))return Bm(Date.parse(t),"MMM d, yyyy")}catch(i){}return t.toLocaleString()},e.prototype.render=function(){var t=this.getOptions(),e=Dd(t,"tooltip","enabled");if(e){var n=eb(this.services.domUtils.getHolder()),r=Dd(t,"style","prefix");this.tooltip=sb.appendOrSelect(n,"div."+dt+"--"+r+"--tooltip"),this.tooltip.style("max-width",null).attr("role","tooltip"),this.isEventListenerAdded||(this.addTooltipEventListener(),this.isEventListenerAdded=!0),this.tooltip.classed("hidden",!0)}else!e&&this.isEventListenerAdded&&(this.removeTooltipEventListener(),this.isEventListenerAdded=!1)},e.prototype.positionTooltip=function(t){var e,n=this.services.domUtils.getHolder(),r=this.tooltip.node(),i=this.getOptions(),o=Dd(i,"zoomBar","top","enabled"),a=Dd(t,"detail","mousePosition");if(a){var s=Dd(i,"zoomBar","top","type"),u=Pt.height[s];o&&(a[1]+=u+Pt.spacerHeight)}else a=wd(Dd(t,"detail","event"),n);var l,c=n.offsetWidth,h=n.offsetHeight;l=a[0]/c>.9?zC.LEFT:a[0]/c<.1?zC.RIGHT:this.positionService.findBestPlacementAt({left:a[0],top:a[1]},r,[zC.RIGHT,zC.LEFT,zC.TOP,zC.BOTTOM],(function(){return{top:void 0,left:void 0,width:c,height:h}}));var f=Lt.horizontalOffset;l===zC.LEFT&&(f*=-1),e=this.positionService.findPositionAt({left:a[0]+f,top:a[1]},r,l),this.positionService.setElement(r,e)},e}(DS),aA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sA=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},uA=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return aA(e,t),e.prototype.getItems=function(t){var e=this;if(t.detail.items)return t.detail.items;var n=t.detail.data;if(!Array.isArray(n)||!n.length||!n[0])return[];var r,i=this.getOptions(),o=this.services.cartesianScales,a=o.getDomainIdentifier(),s=o.isDualAxes(),u=i.data.groupMapsTo,l=o.getDomainLabel(),c=o.getRangeLabel(),h=n[0][a];if(1===n.length){var f=n[0],p=o.getRangeIdentifier(f);if(s){var d=o.getRangeAxisPosition({datum:f,groups:[f[u]]});c=o.getScaleLabel(d)}var v=f[p];r=sA([{label:l,value:h}],Array.isArray(v)&&2===v.length?[{label:"Start",value:v[0]},{label:"End",value:v[1]}]:[{label:c,value:f[p]}]),t.detail.additionalItems&&t.detail.additionalItems.forEach((function(t){return r.push({label:t.label,value:t.value})})),r.push({label:i.tooltip.groupLabel,value:f[u],color:this.model.getFillColor(f[u]),class:this.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:f[u]})})}else if(n.length>1&&(r=[{label:l,value:h}],r=r.concat(n.map((function(t){var n=t[o.getRangeIdentifier(t)];return{label:t[u],value:Array.isArray(n)&&2===n.length?n[0]+" - "+n[1]:n,color:e.model.getFillColor(t[u]),class:e.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:t[u]})}})).sort((function(t,e){return e.value-t.value}))),!s&&!0===Dd(i,"tooltip","showTotal"))){var g=o.getRangeIdentifier();r.push({label:tl(i,"tooltip.totalLabel")||"Total",value:n.reduce((function(t,e){return t+e[g]}),0),bold:!0})}return r},e}(oA),lA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),cA=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="chart-clip",i.renderType=I.SVG,i.chartClipId="chart-clip-id-"+Math.floor(99999999999*Math.random()),i.init(),i}return lA(e,t),e.prototype.init=function(){this.model.set({chartClipId:this.chartClipId},{skipUpdate:!0})},e.prototype.render=function(t){void 0===t&&(t=!0),this.createClipPath()},e.prototype.createClipPath=function(){var t=this.parent,e=this.services.cartesianScales,n=e.getMainXScale(),r=e.getMainYScale(),i=n.range(),o=i[0],a=i[1],s=r.range(),u=s[0],l=s[1];this.chartClipPath=sb.appendOrSelect(t,"clipPath."+this.type).attr("id",this.chartClipId);var c=sb.appendOrSelect(this.chartClipPath,"rect."+this.type);c.attr("x",o).attr("y",l).attr("width",a-o).attr("height",u-l),this.chartClipPath.merge(c).lower()},e}(DS),hA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),fA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="canvas-chart-clip",e.chartClipId="canvas-chart-clip-id-"+Math.floor(99999999999*Math.random()),e}return hA(e,t),e.prototype.createClipPath=function(){var t=this.parent,e=sb.getSVGElementSize(this.parent,{useAttrs:!0}),n=e.width,r=e.height;this.chartClipPath=sb.appendOrSelect(t,"clipPath."+this.type).attr("id",this.chartClipId);var i=sb.appendOrSelect(this.chartClipPath,"rect."+this.type);i.attr("x",0).attr("y",0).attr("width",n).attr("height",r),this.chartClipPath.merge(i).lower()},e}(cA),pA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dA=function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]])}return n},vA=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.type="highlight",r.renderType=I.SVG,r.positionService=new KC,r.highlightStrokeWidth=1,r}return pA(e,t),e.prototype.render=function(t){void 0===t&&(t=!1);var e=Dd(this.getOptions(),"axes"),n=[];Object.keys(e).forEach((function(t){if(Object.values(B).includes(t)){var r=e[t];r.highlights&&r.highlights.data.length>0&&n.push({axisPosition:t,highlightStartMapsTo:r.highlights.highlightStartMapsTo,highlightEndMapsTo:r.highlights.highlightEndMapsTo,labelMapsTo:r.highlights.labelMapsTo,highlight:r.highlights.data,color:r.highlights.color})}}));var r=this.getComponentContainer({withinChartClip:!0}),i=r.selectAll("g.axis-highlight").data(n,(function(t){return t.axisPosition}));i.exit().attr("opacity",0).remove();var o=i.enter().append("g"),a=o.merge(i);a.attr("class",(function(t){return"axis-highlight "+t.axisPosition}));var s=a.selectAll("g.highlight-group").data((function(t){return t.highlight.map((function(e){return e.axisPosition=t.axisPosition,e.highlightStartMapsTo=t.highlightStartMapsTo,e.labelMapsTo=t.labelMapsTo,e.color=t.color,e.highlightEndMapsTo=t.highlightEndMapsTo,e}))}));s.exit().attr("opacity",0).remove();var u=s.enter().append("g");u.append("rect").attr("class","highlight-bar"),u.append("line").attr("class","highlight-line");var l=u.merge(s);l.attr("class","highlight-group");var c=this;a.each((function(e){var n=e.axisPosition,r=c.services.cartesianScales.getMainXScale(),i=c.services.cartesianScales.getMainYScale(),o=r.range(),a=o[0],s=o[1],u=i.range(),l=u[0],h=u[1],f=c.services.cartesianScales,p=f.getOrientation(),d=function(t){return f.getDomainValue(t)},v=function(t){return f.getRangeValue(t)},g=Rd(d,v,p),m=g[0],y=g[1],_=eb(this);n===B.TOP||n===B.BOTTOM?_.selectAll("rect.highlight-bar").transition().call((function(e){return c.services.transitions.setupTransition({transition:e,name:"highlight-bar-update",animate:t})})).attr("y",Math.max(h+c.highlightStrokeWidth,0)).attr("height",Math.max(l-2*c.highlightStrokeWidth,0)).attr("x",(function(t){var e=t.highlightStartMapsTo,n=dA(t,["highlightStartMapsTo"]);return m(n[e])})).attr("width",(function(t){var e=t.highlightStartMapsTo,n=t.highlightEndMapsTo,r=dA(t,["highlightStartMapsTo","highlightEndMapsTo"]);return Math.max(m(r[n])-m(r[e]),0)})).style("stroke",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})).style("stroke-dasharray","2, 2").attr("stroke-width",c.highlightStrokeWidth+"px").style("fill-opacity",.1).style("fill",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})):_.selectAll("rect.highlight-bar").transition().call((function(e){return c.services.transitions.setupTransition({transition:e,name:"highlight-bar-update",animate:t})})).attr("x",a).attr("width",Math.max(s-a,0)).attr("y",(function(t){var e=t.highlightEndMapsTo,n=dA(t,["highlightEndMapsTo"]);return y(n[e])})).attr("height",(function(t){var e=t.highlightStartMapsTo,n=t.highlightEndMapsTo,r=dA(t,["highlightStartMapsTo","highlightEndMapsTo"]);return Math.max(y(r[e])-y(r[n]),0)})).style("stroke",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})).style("stroke-dasharray","2, 2").attr("stroke-width",c.highlightStrokeWidth+"px").style("fill-opacity",.1).style("fill",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null}))}))},e}(DS);const gA=Math.PI,mA=2*gA,yA=1e-6,_A=mA-yA;function bA(t){this._+=t[0];for(let e=1,n=t.length;e<n;++e)this._+=arguments[e]+t[e]}function wA(t){let e=Math.floor(t);if(!(e>=0))throw new Error("invalid digits: "+t);if(e>15)return bA;const n=10**e;return function(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=Math.round(arguments[e]*n)/n+t[e]}}class OA{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==t?bA:wA(t)}moveTo(t,e){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,e){this._append`L${this._x1=+t},${this._y1=+e}`}quadraticCurveTo(t,e,n,r){this._append`Q${+t},${+e},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(t,e,n,r,i,o){this._append`C${+t},${+e},${+n},${+r},${this._x1=+i},${this._y1=+o}`}arcTo(t,e,n,r,i){if(t=+t,e=+e,n=+n,r=+r,i=+i,i<0)throw new Error("negative radius: "+i);let o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,h=l*l+c*c;if(null===this._x1)this._append`M${this._x1=t},${this._y1=e}`;else if(h>yA)if(Math.abs(c*s-u*l)>yA&&i){let f=n-o,p=r-a,d=s*s+u*u,v=f*f+p*p,g=Math.sqrt(d),m=Math.sqrt(h),y=i*Math.tan((gA-Math.acos((d+h-v)/(2*g*m)))/2),_=y/m,b=y/g;Math.abs(_-1)>yA&&this._append`L${t+_*l},${e+_*c}`,this._append`A${i},${i},0,0,${+(c*f>l*p)},${this._x1=t+b*s},${this._y1=e+b*u}`}else this._append`L${this._x1=t},${this._y1=e}`;else;}arc(t,e,n,r,i,o){if(t=+t,e=+e,n=+n,o=!!o,n<0)throw new Error("negative radius: "+n);let a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,h=o?r-i:i-r;null===this._x1?this._append`M${u},${l}`:(Math.abs(this._x1-u)>yA||Math.abs(this._y1-l)>yA)&&this._append`L${u},${l}`,n&&(h<0&&(h=h%mA+mA),h>_A?this._append`A${n},${n},0,1,${c},${t-a},${e-s}A${n},${n},0,1,${c},${this._x1=u},${this._y1=l}`:h>yA&&this._append`A${n},${n},0,${+(h>=gA)},${c},${this._x1=t+n*Math.cos(i)},${this._y1=e+n*Math.sin(i)}`)}rect(t,e,n,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}}function xA(){return new OA}function EA(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(null==n)e=null;else{const t=Math.floor(n);if(!(t>=0))throw new RangeError("invalid digits: "+n);e=t}return t},()=>new OA(e)}function TA(t){return t[0]}function SA(t){return t[1]}xA.prototype=OA.prototype;var MA=function(t,e){var n=Dv(!0),r=null,i=xT,o=null,a=EA(s);function s(s){var u,l,c,h=(s=Lv(s)).length,f=!1;for(null==r&&(o=i(c=a())),u=0;u<=h;++u)!(u<h&&n(l=s[u],u,s))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(l,u,s),+e(l,u,s));if(c)return o=null,c+""||null}return t="function"===typeof t?t:void 0===t?TA:Dv(t),e="function"===typeof e?e:void 0===e?SA:Dv(e),s.x=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),s):t},s.y=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),s):e},s.defined=function(t){return arguments.length?(n="function"===typeof t?t:Dv(!!t),s):n},s.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),s):i},s.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),s):r},s},CA=function(t,e,n){var r=null,i=Dv(!0),o=null,a=xT,s=null,u=EA(l);function l(l){var c,h,f,p,d,v=(l=Lv(l)).length,g=!1,m=new Array(v),y=new Array(v);for(null==o&&(s=a(d=u())),c=0;c<=v;++c){if(!(c<v&&i(p=l[c],c,l))===g)if(g=!g)h=c,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=c-1;f>=h;--f)s.point(m[f],y[f]);s.lineEnd(),s.areaEnd()}g&&(m[c]=+t(p,c,l),y[c]=+e(p,c,l),s.point(r?+r(p,c,l):m[c],n?+n(p,c,l):y[c]))}if(d)return s=null,d+""||null}function c(){return MA().defined(i).curve(a).context(o)}return t="function"===typeof t?t:void 0===t?TA:Dv(+t),e="function"===typeof e?e:Dv(void 0===e?0:+e),n="function"===typeof n?n:void 0===n?SA:Dv(+n),l.x=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),r=null,l):t},l.x0=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),l):t},l.x1=function(t){return arguments.length?(r=null==t?null:"function"===typeof t?t:Dv(+t),l):r},l.y=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),n=null,l):e},l.y0=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),l):e},l.y1=function(t){return arguments.length?(n=null==t?null:"function"===typeof t?t:Dv(+t),l):n},l.lineX0=l.lineY0=function(){return c().x(t).y(e)},l.lineY1=function(){return c().x(t).y(n)},l.lineX1=function(){return c().x(r).y(e)},l.defined=function(t){return arguments.length?(i="function"===typeof t?t:Dv(!!t),l):i},l.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),l):a},l.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),l):o},l},AA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="area",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.area").transition("legend-hover-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-area"})})).attr("opacity",(function(t){return t.name!==n.datum()["name"]?vt.opacity.unselected:vt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.area").transition("legend-mouseout-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-area"})})).attr("opacity",vt.opacity.selected)},e}return AA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=[0,0],o=this.services.cartesianScales,a=o.getOrientation(),s=CA().curve(this.services.curves.getD3Curve()).defined((function(t,e){var n=o.getRangeIdentifier(),r=t[n];return null!==r&&void 0!==r})),u=this.model.getGroupedData(this.configs.groups),l=Dd(r,"bounds"),c=l&&u&&1===u.length;!c&&l&&console.warn("Bounds can only be shown when having 1 single datagroup, you've supplied "+u.length);var h=0,f=function(t,e){!1===Dd(r,"axes",t,"includeZero")&&e[0]>0&&e[1]>0&&(h=e[0])},p=function(t,e){return c?o.getBoundedScaledValues(t,e)[0]:o.getRangeValue(h)},d=function(t,e){return c?o.getBoundedScaledValues(t,e)[1]:o.getRangeValue(t,e)};a===H.VERTICAL?(i=o.getMainYScale().domain(),f(o.getMainYAxisPosition(),i),s.x((function(t,e){return o.getDomainValue(t,e)})).y0((function(t,e){return p(t,e)})).y1((function(t,e){return d(t,e)}))):(i=o.getMainXScale().domain(),f(o.getMainXAxisPosition(),i),s.x0((function(t,e){return p(t,e)})).x1((function(t,e){return d(t,e)})).y((function(t,e){return o.getDomainValue(t,e)})));var v=Dd(r,"color","gradient","enabled"),g=u&&1===u.length&&v;u.length>1&&v&&console.error("Gradients can only be enabled when having 1 single dataset");var m=n.selectAll("path.area").data(u,(function(t){return t.name})),y=eb(this.services.domUtils.getMainContainer());if(m.exit().attr("opacity",0).remove(),u.length){if(g){var _=y.select("path."+this.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:u[0].name})).node(),b=void 0;if(_)b=getComputedStyle(_,null).getPropertyValue("stroke");else{var w=Dd(this.model.getOptions(),"color","scale");if(null!==w){var O=Object.keys(w);b=w[O[0]]}}vb.appendOrUpdateLinearGradient({svg:this.parent,id:this.services.domUtils.generateElementIDString(u[0].name.replace(" ","")+"_"+this.gradient_id),x1:"0%",x2:"0%",y1:"0%",y2:"100%",stops:vb.getStops(i,b)})}else this.parent.selectAll("defs linearGradient").empty()||this.parent.selectAll("defs linearGradient").each((function(){this.parentNode.remove()}));var x=this,E=m.enter().append("path");g?E.merge(m).style("fill",(function(t){return"url(#"+e.services.domUtils.generateElementIDString(t.name.replace(" ","")+"_"+e.gradient_id)+")"})).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.name,originalClassName:"area"})})).attr("d",(function(t){var e=t.data;return s(e)})):(E.attr("opacity",0).merge(m).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"area"})})).style("fill",(function(t){return x.model.getFillColor(t.name)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"area-update-enter",animate:t})})).attr("opacity",c?1:vt.opacity.selected).attr("d",(function(t){var e=t.data;return s(e)})),c&&E.attr("fill-opacity",vt.opacity.selected).style("stroke",(function(t){return x.model.getStrokeColor(t.name)})).style("stroke-dasharray","2, 2").attr("stroke-width","0.7px"))}},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),DA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="area-stacked",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("path.area").transition("legend-hover-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-area"})})).attr("opacity",(function(t){return Dd(t,0,i)!==n.datum().name?vt.opacity.unselected:vt.opacity.selected}))},e.handleLegendMouseOut=function(){e.parent.selectAll("path.area").transition("legend-mouseout-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-area"})})).attr("opacity",vt.opacity.selected)},e}return DA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this,i=this.getOptions(),o=i.data.groupMapsTo,s=Object.keys(i.axes).some((function(t){return i.axes[t].percentage})),u=this.model.getStackedData({percentage:s,groups:this.configs.groups}),l=Dd(u,0,0),c=this.services.cartesianScales.getDomainAxisPosition({firstDatum:l}),h=this.services.cartesianScales.getRangeAxisPosition({firstDatum:l}),f=this.services.cartesianScales.getScaleByPosition(h),p=n.selectAll("path.area").data(u,(function(t){return Dd(t,0,o)}));this.areaGenerator=CA().x((function(t,n){return e.services.cartesianScales.getValueThroughAxisPosition(c,t.data.sharedStackKey,n)})).y0((function(t){return f(t[0])})).y1((function(t){return f(t[1])})).curve(this.services.curves.getD3Curve()),p.exit().attr("opacity",0).remove();var d=p.enter().append("path").attr("opacity",0);d.merge(p).data(u,(function(t){return Dd(t,0,o)})).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:Dd(t,0,o),originalClassName:"area"})})).style("fill",(function(t){return r.model.getFillColor(Dd(t,0,o))})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","area").attr("aria-label",(function(t){return Dd(t,0,o)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"area-update-enter",animate:t})})).attr("opacity",vt.opacity.selected).attr("d",this.areaGenerator)},e}(DS),PA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RA=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return PA(e,t),e.prototype.getBarWidth=function(t){var e=this.getOptions();if(e.bars.width)return e.bars.width;var n=this.model.getDisplayData().length,r=this.services.cartesianScales.getMainXScale(),i=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width;if(!r.step){var o=Dd(e,"bars","spacingFactor");return Math.min(e.bars.maxWidth,i*o/n)}return Math.min(e.bars.maxWidth,r.step()/2)},e.prototype.isOutsideZoomedDomain=function(t,e){var n=this.model.getDisplayData().length;if(n<=1)return!1;var r=this.model.get("zoomDomain");if(void 0!==r){var i=this.services.cartesianScales.getDomainScale();return t<i(r[0])||e>i(r[1])}return!1},e}(DS),IA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="simple-bar",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-simple-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-simple-bar"})})).attr("opacity",1)},e}return IA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getComponentContainer({withinChartClip:!0}),o=this.model.getDisplayData(this.configs.groups),s=this.services.cartesianScales.getOrientation(),u=i.selectAll("path.bar").data(o,(function(t){return t[r]}));u.exit().attr("opacity",0).remove();var l=u.enter().append("path").attr("opacity",0);l.merge(u).classed("bar",!0).attr("width",this.getBarWidth.bind(this)).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[r],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[r])})).attr("d",(function(t,n){var r,i,o=e.services.cartesianScales.getRangeIdentifier(),a=e.getBarWidth(),u=t[o],l=e.services.cartesianScales.getDomainValue(t,n)-a/2,c=l+a;if(Array.isArray(u)&&2===u.length)r=e.services.cartesianScales.getRangeValue(u[0]),i=e.services.cartesianScales.getRangeValue(u[1],n);else{var h=e.services.cartesianScales.getRangeScale(),f=h.domain()[0];r=e.services.cartesianScales.getRangeValue(Math.max(0,f)),i=e.services.cartesianScales.getRangeValue(t,n)}var p=Math.abs(i-r);if(0!==p&&p<2&&(i=u>0&&s===H.VERTICAL||u<0&&s===H.HORIZONTAL?r-2:r+2),!e.isOutsideZoomedDomain(l,c))return Pd({x0:l,x1:c,y0:r,y1:i},s)})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,data:[n]})})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(RA),jA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),BA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grouped-bar",e.renderType=I.SVG,e.padding=5,e.defaultStepFactor=70,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return jA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.model.getDisplayData(this.configs.groups),r=this.getOptions(),i=r.data.groupMapsTo;this.setGroupScale();var o=this.getComponentContainer({withinChartClip:!0}),s=xd(n.map((function(t){var n=e.services.cartesianScales.getDomainIdentifier(t);return t[n]&&"function"===typeof t[n].toString?t[n].toString():t[n]}))),u=o.selectAll("g.bars").data(s,(function(t){return t}));u.exit().attr("opacity",0).remove();var l=u.enter().append("g").classed("bars",!0).attr("role",a.GROUP).attr("data-name","bars"),c=l.merge(u);c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-group-update-enter",animate:t})})).attr("transform",(function(t,n){var r=e.services.cartesianScales.getDomainValue(t,n),i=r-e.getGroupWidth()/2;return e.services.cartesianScales.getOrientation()===H.VERTICAL?"translate("+i+", 0)":"translate(0, "+i+")"}));var h=c.selectAll("path.bar").data((function(t){return e.getDataCorrespondingToLabel(t)}),(function(t){return t[i]}));h.exit().attr("opacity",0).remove();var f=h.enter().append("path").attr("opacity",0);f.merge(h).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[i],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[i])})).attr("d",(function(t,n){var r=e.groupScale(t[i]),o=e.getBarWidth(),a=r,s=r+o,u=e.services.cartesianScales.getRangeAxisPosition({datum:t}),l=e.services.cartesianScales.getValueThroughAxisPosition(u,0),c=e.services.cartesianScales.getRangeValue(t),h=e.services.cartesianScales.getDomainValue(t,n)-o/2,f=h+o;if(!e.isOutsideZoomedDomain(h,f))return Pd({x0:a,x1:s,y0:l,y1:c},e.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,data:[n]})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.getDataCorrespondingToLabel=function(t){var e=this,n=this.model.getDisplayData(this.configs.groups);return n.filter((function(n){var r=e.services.cartesianScales.getDomainIdentifier(n);return n[r].toString()===t}))},e.prototype.getGroupWidth=function(){var t=this.model.getGroupedData(this.configs.groups),e=this.getTotalGroupPadding();return this.getBarWidth()*t.length+e},e.prototype.getDomainScaleStep=function(){var t=this.services.cartesianScales.getDomainScale(),e=this.model.getGroupedData(this.configs.groups),n=this.defaultStepFactor;if("function"===typeof t.step)n=t.step();else if(e.length>0){var r=e.find((function(t){var e;return(null===(e=t.data)||void 0===e?void 0:e.length)>1}));if(r){var i=this.services.cartesianScales.getDomainIdentifier(r.data[0]);n=Math.abs(t(r.data[1][i])-t(r.data[0][i]))}}return n},e.prototype.getTotalGroupPadding=function(){var t=this.model.getGroupedData(this.configs.groups);if(1===t.length)return 0;var e=Math.min(5,this.getDomainScaleStep()/this.defaultStepFactor*5);return e*(t.length-1)},e.prototype.getBarWidth=function(){var t=this.getOptions(),e=Dd(t,"bars","width"),n=Dd(t,"bars","maxWidth");if(null!==e&&(null===n||e<=n))return e;var r=this.model.getGroupedData(this.configs.groups),i=r.length,o=this.getTotalGroupPadding();return Math.min(n,(this.getDomainScaleStep()-o)/i)},e.prototype.setGroupScale=function(){var t=this.model.getActiveDataGroupNames(this.configs.groups);this.groupScale=kE().domain(t).rangeRound([0,this.getGroupWidth()])},e}(RA),UA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),VA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="stacked-bar",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.model.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return UA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.model.getStackedData({groups:this.configs.groups,divergent:!0}),s=this.model.getActiveDataGroupNames(),u=n.selectAll("g.bars").data(o,(function(t){return Dd(t,0,i)}));u.exit().attr("opacity",0).remove(),u.enter().append("g").classed("bars",!0).attr("role",a.GROUP).attr("data-name","bars");var l=n.selectAll("g.bars").selectAll("path.bar").data((function(t){return t}),(function(t){return t.data.sharedStackKey}));l.exit().remove(),l.enter().append("path").merge(l).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[i],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[i])})).attr("d",(function(t,n){var i=t.data.sharedStackKey,o=e.getBarWidth(),a=e.services.cartesianScales.getDomainValue(i,n)-o/2,u=a+o,l=e.services.cartesianScales.getRangeValue(t[0],n),c=e.services.cartesianScales.getRangeValue(t[1],n);if(!e.isOutsideZoomedDomain(a,u)){if(Math.abs(c-l)>0&&Math.abs(c-l)>r.bars.dividerSize){var h=t[0]<0&&t[1]<=0;h&&s.length>1?e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=0===t[1]?2:1:c-=1:h||(e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=1:c-=1)}return Pd({x0:a,x1:u,y0:l,y1:c},e.services.cartesianScales.getOrientation())}})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t[1]-t[0]})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this;this.parent.selectAll("path.bar").on("mouseover",(function(t,r){var i,o=eb(this);o.classed("hovered",!0),n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:t,element:o,datum:r});var a=n.model.getDisplayData(n.configs.groups),s=a.find((function(t){var i=n.services.cartesianScales.getDomainIdentifier(t),o=n.services.cartesianScales.getRangeIdentifier(t);return t[o]===r.data[r[e]]&&t[i].toString()===r.data.sharedStackKey&&t[e]===r[e]}));if(void 0===s){var u=n.services.cartesianScales.getDomainIdentifier(),l=n.services.cartesianScales.getRangeIdentifier();i={},i[u]=r.data.sharedStackKey,i[l]=r.data[r[e]],i[e]=r[e],s=i}n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:o,data:[s]})})).on("mousemove",(function(t,e){var r=eb(this);n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:t,element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var r=eb(this);r.classed("hovered",!1),n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:t,element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.getBarWidth=function(){var t=this.getOptions();if(Dd(t,"bars","width"))return t.bars.width;var e=this.services.cartesianScales.getMainXScale(),n=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,r=this.model.getStackKeys().length,i=Dd(t,"bars","spacingFactor");return e.step?Math.min(t.bars.maxWidth,e.step()/2):Math.min(t.bars.maxWidth,n*i/r)},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(RA),HA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),GA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="boxplot",e.renderType=I.SVG,e}return HA(e,t),e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.model.getDataGroupNames(),s=this.services.cartesianScales.getMainXScale(),u=this.services.cartesianScales.getMainYScale(),l=s.range(),c=l[0],h=l[1],f=u.range(),p=f[0],d=f[1],v=h-c,g=p-d;if(0!==v){var m=this.services.cartesianScales,y=m.getOrientation(),_=y===H.VERTICAL,b=Rd((function(t,n){return e.services.cartesianScales.getDomainValue(t,n)}),(function(t,n){return e.services.cartesianScales.getRangeValue(t,n)}),y),w=b[0],O=b[1],x=Math.floor((_?v:g)/o.length),E=Math.min(x/2,16),T=this.model.getBoxplotData(),S=n.selectAll(".box-group").data(T);S.exit().remove();var M=S.enter().append("g").attr("class","box-group"),C=S.merge(M);M.append("path").merge(S.select("path.vertical-line.start")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"vertical-line start"})})).attr("stroke-width",bt.strokeWidth.default).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-verticalstartline",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i]),n=e,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.quartiles.q_25);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.vertical-line.end")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"vertical-line end"})})).attr("stroke-width",bt.strokeWidth.default).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-verticalendline",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i]),n=e,r=m.getRangeValue(t.whiskers.max),o=m.getRangeValue(t.quartiles.q_75);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.box")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],originalClassName:"box"})})).attr("fill-opacity",bt.box.opacity.default).attr("stroke-width",bt.strokeWidth.default).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","box").attr("aria-label",(function(t){return t[i]})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-quartiles",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(Math[_?"max":"min"](t.quartiles.q_75,t.quartiles.q_25)),o=r+Math.abs(m.getRangeValue(t.quartiles.q_75)-m.getRangeValue(t.quartiles.q_25));return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.highlight-area")).attr("class","highlight-area").attr("opacity",0).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.whiskers.max);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.whisker.start")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"whisker start"})})).attr("stroke-width",bt.strokeWidth.thicker).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-startingwhisker",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/4,n=e+E/2,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.whiskers.min);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.median")).attr("fill","none").attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"median"})})).attr("stroke-width",2).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-median",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(t.quartiles.q_50),o=r;return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.whisker.end")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"whisker end"})})).attr("stroke-width",bt.strokeWidth.thicker).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-endingwhisker",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/4,n=e+E/2,r=m.getRangeValue(t.whiskers.max),o=m.getRangeValue(t.whiskers.max);return Pd({x0:e,x1:n,y0:r,y1:o},y)}));var A=C.selectAll("circle.outlier").data((function(t){return t.outliers.map((function(e){var n;return n={min:t.whiskers.min,max:t.whiskers.max},n[i]=t[i],n.value=e,n}))}));A.exit().remove();var L=A.enter().append("circle");A.merge(L).attr("r",bt.circle.radius).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],originalClassName:"outlier"})})).attr("fill-opacity",bt.circle.opacity.default).attr("cx",w).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-circles",animate:t})})).attr("cy",O),this.addBoxEventListeners(),this.addCircleEventListeners()}},e.prototype.addBoxEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo;this.parent.selectAll("path.highlight-area").on("mouseover",(function(r,i){var o=eb(this),a=eb(this.parentNode);a.select("path.box").classed("hovered",!0).attr("fill-opacity",bt.box.opacity.hovered),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:e.tooltip.groupLabel,value:i[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP]})},{label:"Minimum",value:i.whiskers.min},{label:"Q1",value:i.quartiles.q_25},{label:"Median",value:i.quartiles.q_50},{label:"Q3",value:i.quartiles.q_75},{label:"Maximum",value:i.whiskers.max},{label:"IQR",value:i.quartiles.q_75-i.quartiles.q_25}]}),t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEOVER,{event:r,element:o,datum:i})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Boxplot.BOX_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=eb(this.parentNode);i.select("path.box").classed("hovered",!1).attr("fill-opacity",bt.box.opacity.default),t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.addCircleEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo,r=this.services.cartesianScales.getRangeIdentifier();this.parent.selectAll("circle").on("mouseover",(function(i,o){var a=eb(this);a.classed("hovered",!0).attr("fill-opacity",bt.circle.opacity.hovered).classed("unfilled",!1),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:e.tooltip.groupLabel,value:o[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP]})},{label:"Outlier",value:o[r]}]}),t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEOVER,{event:i,element:a,datum:o})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1).attr("fill-opacity",bt.circle.opacity.default),t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e}(DS),zA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter",e.renderType=I.SVG,e.handleChartHolderOnHover=function(t){e.parent.selectAll("circle.dot").transition("chart-holder-hover-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"chart-holder-hover-scatter"})})).attr("opacity",1)},e.handleChartHolderOnMouseOut=function(t){e.parent.selectAll("circle.dot").transition("chart-holder-mouseout-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"chart-holder-mouseout-scatter"})})).attr("opacity",0)},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("circle.dot").transition("legend-hover-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-scatter"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.dot").transition("legend-mouseout-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-scatter"})})).attr("opacity",1)},e}return zA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut);var e=this.configs.fadeInOnChartHolderMouseover;e&&(t.addEventListener(ft.Chart.MOUSEOVER,this.handleChartHolderOnHover),t.addEventListener(ft.Chart.MOUSEOUT,this.handleChartHolderOnMouseOut))},e.prototype.filterBasedOnZoomDomain=function(t){var e=this.services.cartesianScales.getDomainIdentifier(t),n=this.model.get("zoomDomain");return void 0!==n?t.filter((function(t){return t[e].getTime()>=n[0].getTime()&&t[e].getTime()<=n[1].getTime()})):t},e.prototype.getScatterData=function(){var t,e=this,n=this.getOptions(),r=this.configs.stacked;if(r){var i=Object.keys(n.axes).some((function(t){return n.axes[t].percentage}));t=this.model.getStackedData({groups:this.configs.groups,percentage:i})}else t=this.model.getDisplayData(this.configs.groups).filter((function(t){var n=e.services.cartesianScales.getRangeIdentifier(t);return void 0!==t[n]&&null!==t[n]}));return this.filterBasedOnZoomDomain(t)},e.prototype.render=function(t){var e=Dd(this.getOptions(),"points","enabled")||Dd(this.getOptions(),"bubble","enabled");if(e){var n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.services.cartesianScales.getDomainIdentifier(),a=n.selectAll("circle.dot").data(this.getScatterData(),(function(t){return t[i]+"-"+t[o]}));a.exit().attr("opacity",0).remove();var s=a.enter().append("circle").classed("dot",!0).attr("opacity",0),u=s.merge(a);this.styleCircles(u,t),this.addEventListeners()}},e.prototype.isDatapointThresholdAnomaly=function(t,e){var n=this,r=this.configs.handleThresholds;if(!r)return!1;var i=this.services.cartesianScales,o=i.getOrientation(),a=Rd(this.services.cartesianScales.getHighestDomainThreshold(),this.services.cartesianScales.getHighestRangeThreshold(),o),s=a[0],u=a[1],l=Rd((function(t,e){return n.services.cartesianScales.getDomainValue(t,e)}),(function(t,e){return n.services.cartesianScales.getRangeValue(t,e)}),o),c=l[0],h=l[1],f=c(t,e),p=h(t,e);return u&&s?p<=u.scaleValue&&f>=s.scaleValue:u?p<=u.scaleValue:s?f>=s.scaleValue:void 0},e.prototype.styleCircles=function(t,e){var n=this,r=this.getOptions(),i=r.points,o=i.filled,s=i.fillOpacity,u=this.services,l=u.cartesianScales,c=(u.transitions,r.data.groupMapsTo),h=function(t,e){return l.getDomainValue(t,e)},f=function(t,e){return l.getRangeValue(t,e)},p=Rd(h,f,l.getOrientation()),d=p[0],v=p[1],g=this.configs.fadeInOnChartHolderMouseover;t.raise().classed("dot",!0).attr("class",(function(t){var e=l.getDomainIdentifier(t),r=n.model.getIsFilled(t[c],t[e],t,o),i=r?[j.FILL,j.STROKE]:[j.STROKE];return n.model.getColorClassName({classNameTypes:i,dataGroupName:t[c],originalClassName:"dot"})})).classed("threshold-anomaly",(function(t,e){return n.isDatapointThresholdAnomaly(t,e)})).classed("filled",(function(t){var e=l.getDomainIdentifier(t);return n.model.getIsFilled(t[c],t[e],t,o)})).classed("unfilled",(function(t){var e=l.getDomainIdentifier(t);return!n.model.getIsFilled(t[c],t[e],t,o)})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"scatter-update-enter",animate:e})})).attr("cx",d).attr("cy",v).attr("r",r.points.radius).style("fill",(function(t){var e=l.getDomainIdentifier(t);if(n.model.getIsFilled(t[c],t[e],t,o))return n.model.getFillColor(t[c],t[e],t)})).style("stroke",(function(t){var e=l.getDomainIdentifier(t);return n.model.getStrokeColor(t[c],t[e],t)})).attr("fill-opacity",o?s:1).attr("opacity",g?0:1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","point").attr("aria-label",(function(t){var e=l.getRangeIdentifier(t);return t[e]})),this.addEventListeners()},e.prototype.getTooltipAdditionalItems=function(t){return null},e.prototype.addEventListeners=function(){var t=this,e=t.getOptions().data.groupMapsTo;this.parent.selectAll("circle").on("mouseover",(function(n,r){var i=eb(this);i.classed("hovered",!0).attr("class",(function(n){return t.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:n[e],originalClassName:i.attr("class")})})).style("fill",(function(n){var r=t.services.cartesianScales.getDomainIdentifier(n);return t.model.getFillColor(n[e],n[r],n)})).classed("unfilled",!1),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n,hoveredElement:i,data:[r],additionalItems:t.getTooltipAdditionalItems(r)}),t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEOVER,{event:n,element:i,datum:r})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Scatter.SCATTER_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(n,r){var i=eb(this);if(i.classed("hovered",!1),!t.configs.filled){var o=t.getOptions().points.filled,a=t.services.cartesianScales.getDomainIdentifier(r),s=t.model.getIsFilled(r[e],r[a],r,o);i.classed("unfilled",!s).style("fill",(function(n){return s||o?t.model.getFillColor(n[e],n[a],n):null}))}t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEOUT,{event:n,element:i,datum:r}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e.prototype.destroy=function(){this.parent.selectAll("circle").on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),t.removeEventListener(ft.Chart.MOUSEOVER,this.handleChartHolderOnHover),t.removeEventListener(ft.Chart.MOUSEOUT,this.handleChartHolderOnMouseOut)},e}(DS),WA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bubble",e.renderType=I.SVG,e}return WA(e,t),e.prototype.getRadiusScale=function(t){var e=this.getOptions(),n=e.bubble.radiusMapsTo,r=t.data(),i=r.map((function(t){return t[n]})).filter((function(t){return t})),o=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),a=i.length>0,s=a?Xv(i):[1,1];return BE().domain(s).range(a?e.bubble.radiusRange(o,r):[4,4])},e.prototype.styleCircles=function(t,e){var n=this,r=this.getOptions(),i=r.bubble.radiusMapsTo,o=this.getRadiusScale(t),s=r.data.groupMapsTo,u=this.services.cartesianScales,l=function(t,e){return u.getDomainValue(t,e)},c=function(t,e){return u.getRangeValue(t,e)},h=Rd(l,c,u.getOrientation()),f=h[0],p=h[1];t.raise().classed("dot",!0).attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){var e=u.getRangeIdentifier(t);return t[e]})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"bubble-update-enter",animate:e})})).attr("cx",f).attr("cy",p).attr("r",(function(t){return o(t[i]||1)})).attr("class",(function(t){return n.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t[s],originalClassName:"dot"})})).style("fill",(function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return n.model.getFillColor(t[s],t[e],t)})).style("stroke",(function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return n.model.getStrokeColor(t[s],t[e],t)})).attr("fill-opacity",r.bubble.fillOpacity).attr("opacity",1)},e.prototype.getTooltipAdditionalItems=function(t){var e=Dd(this.getOptions(),"bubble");return[{label:Dd(e,"radiusLabel"),value:t[Dd(e,"radiusMapsTo")]}]},e}(FA),$A=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bullet",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-simple-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-simple-bar"})})).attr("opacity",1)},e}return $A(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getComponentContainer({withinChartClip:!0}),o=this.model.getDisplayData(this.configs.groups),s=this.services.cartesianScales.getRangeScale(),u=this.services.cartesianScales.getRangeIdentifier(),l=s.range(),c=l[0],h=l[1],f=s.domain(),p=(f[0],f[1]),d=function(){var n=[];o.forEach((function(t){t.ranges?t.ranges.forEach((function(e,r){null!==e&&void 0!==e&&e<p&&n.push({datum:t,value:e,order:r+1})})):n.push({datum:t,order:1})}));var a=sb.appendOrSelect(i,"g.range-boxes").selectAll("path.range-box").data(n,(function(t){return t[r]+"-"+t.order}));a.exit().attr("opacity",0).remove();var s=a.enter().append("path").attr("opacity",0);s.merge(a).attr("class",(function(t){return"range-box order-"+t.order})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-range-box-update-enter",animate:t})})).attr("d",(function(t,n){var r,i,o,a,s=16;return 1===t.order?(r=e.services.cartesianScales.getDomainValue(t.datum,n)-s/2,i=r+s,o=h-2,a=c+1):(r=e.services.cartesianScales.getDomainValue(t.datum,n)-s/2,i=r+s,o=e.services.cartesianScales.getRangeValue(t.value,n),a=h),Pd({x0:r,x1:i,y0:o,y1:a},e.services.cartesianScales.getOrientation())})).attr("opacity",1)},v=function(){var n=sb.appendOrSelect(i,"g.bars").selectAll("path.bar").data(o,(function(t){return t[r]}));n.exit().attr("opacity",0).remove();var s=n.enter().append("path").attr("opacity",0);s.merge(n).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[r],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[r])})).attr("d",(function(t,n){var r=8,i=e.services.cartesianScales.getDomainValue(t,n)-r/2,o=i+r,a=e.services.cartesianScales.getRangeValue(0)+1,s=e.services.cartesianScales.getRangeValue(t,n);return Pd({x0:i,x1:o,y0:a,y1:s},e.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value}))},g=function(){var n=sb.appendOrSelect(i,"g.markers").selectAll("path.marker").data(o.filter((function(t){return null!==Dd(t,"marker")})),(function(t){return t[r]}));n.exit().attr("opacity",0).remove();var a=n.enter().append("path").attr("opacity",0);a.merge(n).classed("marker",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-marker-update-enter",animate:t})})).attr("d",(function(t,n){var r=24,i=e.services.cartesianScales.getDomainValue(t,n)-r/2,o=i+r,a=e.services.cartesianScales.getRangeValue(t.marker,n),s=a;return Pd({x0:i,x1:o,y0:a,y1:s},e.services.cartesianScales.getOrientation())})).attr("opacity",1)},m=function(){var n=[];o.filter((function(t){return null!==Dd(t,"marker")})).forEach((function(t){var e=t.marker,r=t[u];n=n.concat([{datum:t,value:.25*e,barValue:r},{datum:t,value:.5*e,barValue:r},{datum:t,value:.75*e,barValue:r}])}));var a=sb.appendOrSelect(i,"g.quartiles").selectAll("path.quartile").data(n,(function(t){return t[r]}));a.exit().attr("opacity",0).remove();var s=a.enter().append("path").attr("opacity",0);s.merge(a).attr("class",(function(t){return"quartile "+(t.value<=t.barValue?"over-bar":"")})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-quartile-update-enter",animate:t})})).attr("d",(function(t,n){var r=t.datum,i=t.value,o=4;r.ranges&&-1!==r.ranges.indexOf(i)&&(o=8);var a=e.services.cartesianScales.getDomainValue(r,n)-o/2,s=a+o,u=e.services.cartesianScales.getRangeValue(i,n),l=u;return Pd({x0:a,x1:s,y0:u,y1:l},e.services.cartesianScales.getOrientation())})).attr("opacity",1)};d(),v(),g(),m(),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo,r=this.services.cartesianScales.getRangeIdentifier();this.parent.selectAll("path.bar").on("mouseover",(function(i,o){var a=eb(this);a.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:i,element:a,datum:o});var s=Dd(e,"bullet","performanceAreaTitles"),u=t.model.getMatchingRangeIndexForDatapoint(o);t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:e.tooltip.groupLabel||"Group",value:o[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:o[n]})},{label:"Value",value:o[r]},{label:"Target",value:o.marker},{label:"Percentage",value:Math.floor(o[r]/o.marker*100)+"%"},{label:"Performance",value:s[u]}]})})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),ZA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="histogram",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[i]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return ZA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer(),r=this.model.getOptions(),i=r.groupIdentifier,o=r.data.groupMapsTo,s=this.model.getBinnedStackedData(),u=this.services.cartesianScales.getMainXScale(),l=n.selectAll("g.bars").data(s,(function(t){return tl(t,"0."+o)}));l.exit().attr("opacity",0).remove(),l.enter().append("g").classed("bars",!0).attr("role",a.GROUP);var c=n.selectAll("g.bars").selectAll("path.bar").data((function(t){return t}));c.exit().remove(),c.enter().append("path").merge(c).classed("bar",!0).attr(i,(function(t,e){return e})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"histogram-bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[o],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[o])})).attr("d",(function(t,n){var i=tl(t,"data");if(i){var o=u(i.x1)-u(i.x0)-1,a=e.services.cartesianScales.getDomainValue(i.x0,n),s=a+o,l=e.services.cartesianScales.getRangeValue(t[0],n),c=e.services.cartesianScales.getRangeValue(t[1],n);return Math.abs(c-l)>0&&Math.abs(c-l)>r.bars.dividerSize&&(e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=1:c-=1),Pd({x0:a,x1:s,y0:l,y1:c},e.services.cartesianScales.getOrientation())}})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return Dd(t,"data",t[o])})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.model.getOptions(),e=t.data.groupMapsTo,n=this;this.parent.selectAll("path.bar").on("mouseover",(function(r,i){var o=eb(this);o.classed("hovered",!0);var a=parseFloat(tl(i,"data.x0")),s=parseFloat(tl(i,"data.x1")),u=n.services.cartesianScales.getRangeAxisPosition(),l=n.services.cartesianScales.getScaleLabel(u);n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:tl(t,"bins.rangeLabel")||"Range",value:a+" – "+s},{label:t.tooltip.groupLabel||"Group",value:i[e],class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:i[e]})},{label:l,value:tl(i,"data."+i[e])}]})})).on("mousemove",(function(t,e){n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(t,e){var r=eb(this);r.classed("hovered",!1),n.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),KA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.line").transition("legend-hover-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-line"})})).attr("opacity",(function(t){return t.name!==n.datum()["name"]?xt.opacity.unselected:xt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.line").transition("legend-mouseout-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-line"})})).attr("opacity",xt.opacity.selected)},e}return KA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this.services,i=r.cartesianScales,o=r.curves,s=function(t,e){return i.getDomainValue(t,e)},u=function(t,e){return i.getRangeValue(t,e)},l=Rd(s,u,i.getOrientation()),c=l[0],h=l[1],f=this.getOptions(),p=MA().x(c).y(h).curve(o.getD3Curve()).defined((function(t,e){var n=i.getRangeIdentifier(t),r=t[n];return null!==r&&void 0!==r})),d=[];if(this.configs.stacked){var v=Object.keys(f.axes).some((function(t){return f.axes[t].percentage})),g=f.data.groupMapsTo,m=this.model.getStackedData({groups:this.configs.groups,percentage:v});d=m.map((function(t){var n=e.services.cartesianScales.getDomainIdentifier(t),r=e.services.cartesianScales.getRangeIdentifier(t);return{name:Dd(t,0,g),data:t.map((function(t){var e;return e={},e[n]=t.data.sharedStackKey,e[g]=t[g],e[r]=t[1],e})),hidden:!rf(t,(function(t){return t[0]!==t[1]}))}}))}else d=this.model.getGroupedData(this.configs.groups);var y=n.selectAll("path.line").data(d,(function(t){return t.name}));y.exit().attr("opacity",0).remove();var _=y.enter().append("path").classed("line",!0).attr("opacity",0);_.merge(y).data(d,(function(t){return t.name})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t.name,originalClassName:"line"})})).style("stroke",(function(t){return e.model.getStrokeColor(t.name)})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","line").attr("aria-label",(function(t){var n=t.data;return n.map((function(t){var n=e.services.cartesianScales.getRangeIdentifier(t);return t[n]})).join(",")})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"line-update-enter",animate:t})})).attr("opacity",(function(t){return t.hidden?0:1})).attr("d",(function(t){var e=t.data;return p(e)}))},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),JA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="lollipop",e.renderType=I.SVG,e.handleScatterOnHover=function(t){var n=t.detail,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("line.line").attr("stroke-width",(function(t){return t[i]!==n.datum[i]?xt.weight.unselected:xt.weight.selected}))},e.handleScatterOnMouseOut=function(t){e.parent.selectAll("line.line").attr("stroke-width",xt.weight.unselected)},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("line.line").transition("legend-hover-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-line"})})).attr("opacity",(function(t){return t[i]!==n.datum()["name"]?xt.opacity.unselected:xt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("line.line").transition("legend-mouseout-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-line"})})).attr("opacity",xt.opacity.selected)},e}return JA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.model.getOptions(),i=r.data.groupMapsTo,o=this.services.cartesianScales,a=o.getMainXScale(),s=o.getMainYScale(),u=o.getDomainIdentifier(),l=function(t,e){return o.getDomainValue(t,e)},c=function(t,e){return o.getRangeValue(t,e)},h=o.getOrientation(),f=Rd(l,c,h),p=f[0],d=f[1],v=n.selectAll("line.line").data(this.getScatterData(),(function(t){return t[i]+"-"+t[u]}));v.exit().attr("opacity",0).remove();var g=v.enter().append("line").attr("opacity",0),m=g.merge(v).classed("line",!0).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t[i],originalClassName:"line"})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"lollipop-line-update-enter",animate:t})})).style("stroke",(function(t){return e.model.getFillColor(t[i],t[u],t)})).attr("opacity",1);h===H.HORIZONTAL?m.attr("y1",d).attr("y2",d).attr("x1",a.range()[0]).attr("x2",(function(t,e){return p(t,e)-r.points.radius})):m.attr("x1",p).attr("x2",p).attr("y1",s.range()[0]).attr("y2",(function(t,e){return d(t,e)+r.points.radius})),this.addScatterPointEventListeners()},e.prototype.addScatterPointEventListeners=function(){this.services.events.addEventListener(ft.Scatter.SCATTER_MOUSEOVER,this.handleScatterOnHover),this.services.events.addEventListener(ft.Scatter.SCATTER_MOUSEOUT,this.handleScatterOnMouseOut)},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),t.removeEventListener(ft.Scatter.SCATTER_MOUSEOVER,this.handleScatterOnHover),t.removeEventListener(ft.Scatter.SCATTER_MOUSEOUT,this.handleScatterOnMouseOut)},e}(FA),eL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),nL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter-stacked",e.renderType=I.SVG,e}return eL(e,t),e.prototype.render=function(t){var e=this,n=Dd(this.getOptions(),"points","enabled");if(n){var r=this.getComponentContainer({withinChartClip:!0}),i=this.getOptions(),o=i.data.groupMapsTo,s=Object.keys(i.axes).some((function(t){return i.axes[t].percentage})),u=this.model.getStackedData({groups:this.configs.groups,percentage:s}),l=r.selectAll("g.dots").data(u,(function(t){return Dd(t,0,o)}));l.exit().attr("opacity",0).remove();var c=l.enter().append("g").classed("dots",!0).attr("role",a.GROUP),h=c.merge(l).selectAll("circle.dot").data((function(t){return t}));h.exit().attr("opacity",0).remove();var f=h.enter().append("circle").classed("dot",!0).attr("opacity",0),p=f.merge(h).datum((function(t){var n,r=t[o],i=e.services.cartesianScales.getDomainIdentifier(t),a=e.services.cartesianScales.getRangeIdentifier(t);return n={},n[o]=r,n[i]=t["data"]["sharedStackKey"],n[a]=t[1],n}));this.styleCircles(p,t),this.addEventListeners()}},e.prototype.getTooltipData=function(t,e){var n=this,r=this.getOptions(),i=r.data.groupMapsTo,o=Object.keys(r.axes).some((function(t){return r.axes[t].percentage})),a=this.model.getStackedData({groups:this.configs.groups,percentage:o}),s=[];return a.forEach((function(r,a){r.forEach((function(r,u){var l,c=r[i],h=r["data"]["sharedStackKey"],f=r["data"][c],p=r[1],d=n.services.cartesianScales.getDomainIdentifier(r),v=n.services.cartesianScales.getRangeIdentifier(r);null!==f&&void 0!==f&&t===n.services.cartesianScales.getDomainValue(h)&&e===n.services.cartesianScales.getRangeValue(p)&&(o&&(f=n.model.getStackedData({groups:n.configs.groups})[a][u]["data"][c]),null!==f&&s.push((l={},l[i]=c,l[d]=h,l[v]=f,l)))}))})),this.model.getDisplayData(this.configs.groups).filter((function(t){var e=n.services.cartesianScales.getDomainIdentifier(t),r=n.services.cartesianScales.getRangeIdentifier(t);return void 0!==s.find((function(n){return n[i]==t[i]&&n[e]==t[e]&&n[r]==t[r]}))}))},e}(FA);function rL(t){return t.innerRadius}function iL(t){return t.outerRadius}function oL(t){return t.startAngle}function aL(t){return t.endAngle}function sL(t){return t&&t.padAngle}function uL(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,h=s-o,f=h*u-c*l;if(!(f*f<XT))return f=(c*(e-o)-h*(t-i))/f,[t+f*u,e+f*l]}function lL(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/ZT(s*s+u*u),c=l*u,h=-l*s,f=t+c,p=e+h,d=n+c,v=r+h,g=(f+d)/2,m=(p+v)/2,y=d-f,_=v-p,b=y*y+_*_,w=i-o,O=f*v-d*p,x=(_<0?-1:1)*ZT(qT(0,w*w*b-O*O)),E=(O*_-y*x)/b,T=(-O*y-_*x)/b,S=(O*_+y*x)/b,M=(-O*y+_*x)/b,C=E-g,A=T-m,L=S-g,D=M-m;return C*C+A*A>L*L+D*D&&(E=S,T=M),{cx:E,cy:T,x01:-c,y01:-h,x11:E*(i/w-1),y11:T*(i/w-1)}}var cL=function(){var t=rL,e=iL,n=Dv(0),r=null,i=oL,o=aL,a=sL,s=null,u=EA(l);function l(){var l,c,h=+t.apply(this,arguments),f=+e.apply(this,arguments),p=i.apply(this,arguments)-QT,d=o.apply(this,arguments)-QT,v=zT(d-p),g=d>p;if(s||(s=l=u()),f<h&&(c=f,f=h,h=c),f>XT)if(v>JT-XT)s.moveTo(f*WT(p),f*YT(p)),s.arc(0,0,f,p,d,!g),h>XT&&(s.moveTo(h*WT(d),h*YT(d)),s.arc(0,0,h,d,p,g));else{var m,y,_=p,b=d,w=p,O=d,x=v,E=v,T=a.apply(this,arguments)/2,S=T>XT&&(r?+r.apply(this,arguments):ZT(h*h+f*f)),M=$T(zT(f-h)/2,+n.apply(this,arguments)),C=M,A=M;if(S>XT){var L=eS(S/h*YT(T)),D=eS(S/f*YT(T));(x-=2*L)>XT?(L*=g?1:-1,w+=L,O-=L):(x=0,w=O=(p+d)/2),(E-=2*D)>XT?(D*=g?1:-1,_+=D,b-=D):(E=0,_=b=(p+d)/2)}var k=f*WT(_),P=f*YT(_),R=h*WT(O),I=h*YT(O);if(M>XT){var N,j=f*WT(b),B=f*YT(b),U=h*WT(w),V=h*YT(w);if(v<KT)if(N=uL(k,P,U,V,j,B,R,I)){var H=k-N[0],G=P-N[1],z=j-N[0],F=B-N[1],W=1/YT(tS((H*z+G*F)/(ZT(H*H+G*G)*ZT(z*z+F*F)))/2),q=ZT(N[0]*N[0]+N[1]*N[1]);C=$T(M,(h-q)/(W-1)),A=$T(M,(f-q)/(W+1))}else C=A=0}E>XT?A>XT?(m=lL(U,V,k,P,f,A,g),y=lL(j,B,R,I,f,A,g),s.moveTo(m.cx+m.x01,m.cy+m.y01),A<M?s.arc(m.cx,m.cy,A,FT(m.y01,m.x01),FT(y.y01,y.x01),!g):(s.arc(m.cx,m.cy,A,FT(m.y01,m.x01),FT(m.y11,m.x11),!g),s.arc(0,0,f,FT(m.cy+m.y11,m.cx+m.x11),FT(y.cy+y.y11,y.cx+y.x11),!g),s.arc(y.cx,y.cy,A,FT(y.y11,y.x11),FT(y.y01,y.x01),!g))):(s.moveTo(k,P),s.arc(0,0,f,_,b,!g)):s.moveTo(k,P),h>XT&&x>XT?C>XT?(m=lL(R,I,j,B,h,-C,g),y=lL(k,P,U,V,h,-C,g),s.lineTo(m.cx+m.x01,m.cy+m.y01),C<M?s.arc(m.cx,m.cy,C,FT(m.y01,m.x01),FT(y.y01,y.x01),!g):(s.arc(m.cx,m.cy,C,FT(m.y01,m.x01),FT(m.y11,m.x11),!g),s.arc(0,0,h,FT(m.cy+m.y11,m.cx+m.x11),FT(y.cy+y.y11,y.cx+y.x11),g),s.arc(y.cx,y.cy,C,FT(y.y11,y.x11),FT(y.y01,y.x01),!g))):s.arc(0,0,h,O,w,g):s.lineTo(R,I)}else s.moveTo(0,0);if(s.closePath(),l)return s=null,l+""||null}return l.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-KT/2;return[WT(r)*n,YT(r)*n]},l.innerRadius=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),l):t},l.outerRadius=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),l):e},l.cornerRadius=function(t){return arguments.length?(n="function"===typeof t?t:Dv(+t),l):n},l.padRadius=function(t){return arguments.length?(r=null==t?null:"function"===typeof t?t:Dv(+t),l):r},l.startAngle=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),l):i},l.endAngle=function(t){return arguments.length?(o="function"===typeof t?t:Dv(+t),l):o},l.padAngle=function(t){return arguments.length?(a="function"===typeof t?t:Dv(+t),l):a},l.context=function(t){return arguments.length?(s=null==t?null:t,l):s},l},hL=function(t,e){return e<t?-1:e>t?1:e>=t?0:NaN},fL=function(t){return t},pL=function(){var t=fL,e=hL,n=null,r=Dv(0),i=Dv(JT),o=Dv(0);function a(a){var s,u,l,c,h,f=(a=Lv(a)).length,p=0,d=new Array(f),v=new Array(f),g=+r.apply(this,arguments),m=Math.min(JT,Math.max(-JT,i.apply(this,arguments)-g)),y=Math.min(Math.abs(m)/f,o.apply(this,arguments)),_=y*(m<0?-1:1);for(s=0;s<f;++s)(h=v[d[s]=s]=+t(a[s],s,a))>0&&(p+=h);for(null!=e?d.sort((function(t,n){return e(v[t],v[n])})):null!=n&&d.sort((function(t,e){return n(a[t],a[e])})),s=0,l=p?(m-f*_)/p:0;s<f;++s,g=c)u=d[s],h=v[u],c=g+(h>0?h*l:0)+_,v[u]={data:a[u],index:s,value:h,startAngle:g,endAngle:c,padAngle:y};return v}return a.value=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"===typeof t?t:Dv(+t),a):o},a},dL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();function vL(t,e){var n=this,r=Nx(this._current,t);return function(t){return n._current=r(t),e(n._current)}}var gL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="pie",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.slice").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t.data[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.slice").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return dL(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.getInnerRadius=function(){return Tt.innerRadius},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this,r=this.getComponentContainer(),i=this.getOptions(),o=i.data.groupMapsTo,s=i.pie.valueMapsTo,u=this.model.getDisplayData().filter((function(t){return t[s]>0})),l=this.computeRadius();this.arc=cL().innerRadius(this.getInnerRadius()).outerRadius(l),this.hoverArc=cL().innerRadius(this.getInnerRadius()).outerRadius(l+Tt.hoverArc.outerRadiusOffset);var c=pL().value((function(t){return t[s]})).sort(Dd(i,"pie","sortFunction")).padAngle(Tt.padAngle),h=c(u),f=sb.appendOrSelect(r,"g.slices").attr("role",a.GROUP).attr("data-name","slices"),p=f.selectAll("path.slice").data(h,(function(t){return t.data[o]}));p.exit().attr("opacity",0).remove();var d=p.enter().append("path").classed("slice",!0).attr("opacity",0),v=d.merge(p).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.data[o],originalClassName:"slice"})})).style("fill",(function(t){return n.model.getFillColor(t.data[o])})).attr("d",this.arc);v.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"pie_slice_enter_update",animate:t})})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","slice").attr("aria-label",(function(t){return t[s]+", "+Cd(t.data[s],u,s)+"%"})).attrTween("d",(function(t){return vL.bind(this)(t,n.arc)}));var g=i.pie.labels.enabled,m=g?h.filter((function(t){return t.data[s]>0})):[],y=sb.appendOrSelect(r,"g.labels").attr("role",a.GROUP).attr("data-name","labels"),_=y.selectAll("text.pie-label").data(m,(function(t){return t.data[o]}));_.exit().attr("opacity",0).remove();var b=_.enter().append("text").classed("pie-label",!0),w=[];b.merge(_).style("text-anchor","middle").text((function(t){return i.pie.labels.formatter?i.pie.labels.formatter(t):Cd(t.data[s],u,s)+"%"})).datum((function(t){var e=l+7,n=(t.endAngle-t.startAngle)/2+t.startAngle,r=n/Math.PI*180,i=this.getComputedTextLength();return t.textOffsetX=i/2,t.textOffsetY=r>90&&r<270?10:0,t.xPosition=(t.textOffsetX+e)*Math.sin(n),t.yPosition=(t.textOffsetY+e)*-Math.cos(n),t})).attr("transform",(function(t,e){var n=m.length,r=(t.endAngle-t.startAngle)*(180/Math.PI);if(e>=n-2&&r<Tt.callout.minSliceDegree){var i=void 0,o=void 0;return t.index===n-1?(i=t.xPosition+Tt.callout.offsetX+Tt.callout.textMargin+t.textOffsetX,o=t.yPosition-Tt.callout.offsetY,t.direction=X.RIGHT,w.push(t)):(i=t.xPosition-Tt.callout.offsetX-t.textOffsetX-Tt.callout.textMargin,o=t.yPosition-Tt.callout.offsetY,t.direction=X.LEFT,w.push(t)),"translate("+i+", "+o+")"}return"translate("+t.xPosition+", "+t.yPosition+")"})),this.renderCallouts(w);var O=Dd(i,"donut")?"donut":"pie",x=Dd(i,O,"alignment"),E=sb.getSVGElementSize(this.getParent(),{useAttrs:!0}).width,T=g?Tt.xOffset:0,S=g?Tt.yOffset:0,M=l+T;x===F.CENTER?M=E/2:x===F.RIGHT&&(M=E-l-Tt.xOffset);var C=l+S;w.length>0&&(C+=Tt.yOffsetCallout),r.attr("x",M+7).attr("y",C),this.addEventListeners()},e.prototype.renderCallouts=function(t){var e=sb.appendOrSelect(this.getComponentContainer(),"g.callouts").attr("role",a.GROUP).attr("data-name","callouts"),n=e.selectAll("g.callout").data(t);n.exit().remove();var r=n.enter().append("g").classed("callout",!0).attr("role",a.GROUP).attr("aria-roledescription","label callout");r.merge(n).datum((function(t){var e=t.xPosition,n=t.yPosition,r=t.direction;return r===X.RIGHT?(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e+Tt.callout.offsetX,y:n-Tt.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x-Tt.callout.horizontalLineLength):(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e-Tt.callout.offsetX,y:n-Tt.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x+Tt.callout.horizontalLineLength),t}));var i=r.append("line").classed("vertical-line",!0);i.merge(e.selectAll("line.vertical-line")).datum((function(t){return eb(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.startPos.x})).attr("y1",(function(t){return t.startPos.y})).attr("x2",(function(t){return t.intersectPointX})).attr("y2",(function(t){return t.endPos.y}));var o=r.append("line").classed("horizontal-line",!0);o.merge(e.selectAll("line.horizontal-line")).datum((function(t){return eb(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.intersectPointX})).attr("y1",(function(t){return t.endPos.y})).attr("x2",(function(t){return t.endPos.x})).attr("y2",(function(t){return t.endPos.y}))},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.slice").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0).transition("pie_slice_mouseover").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"pie_slice_mouseover"})})).attr("d",t.hoverArc),t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEOVER,{event:e,element:eb(this),datum:n});var i=t.getOptions().data.groupMapsTo,o=t.getOptions().pie.valueMapsTo;t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:[{label:n.data[i],value:n.data[o]}]})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Pie.SLICE_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1).transition("pie_slice_mouseout").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"pie_slice_mouseout"})})).attr("d",t.arc),t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.computeRadius=function(){var t=sb.getSVGElementSize(this.parent,{useAttrs:!0}),e=t.width,n=t.height,r=this.getOptions(),i=Math.min(e,n)/2,o=r.pie.labels.enabled;return o?i+Tt.radiusOffset:i},e}(DS),mL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),yL="4,10 8,6 12,10",_L="12,6 8,10 4,6",bL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="gauge",e.renderType=I.SVG,e}return mL(e,t),e.prototype.getValue=function(){var t,e,n=this.model.getData(),r=(e=null===(t=n.find((function(t){return"value"===t.group})))||void 0===t?void 0:t.value,null!==e&&void 0!==e?e:null);return r},e.prototype.getValueRatio=function(){var t=aa(this.getValue(),0,100);return t/100},e.prototype.getDelta=function(){var t,e,n=this.model.getData(),r=(e=null===(t=n.find((function(t){return"delta"===t.group})))||void 0===t?void 0:t.value,null!==e&&void 0!==e?e:null);return r},e.prototype.getArcRatio=function(){var t=this.getOptions(),e=Dd(t,"gauge","type"),n=e===tt.FULL?1:.5;return n},e.prototype.getArcSize=function(){return this.getArcRatio()*Math.PI*2},e.prototype.getStartAngle=function(){var t=this.getArcSize();return t===2*Math.PI?0:-t/2},e.prototype.getArrow=function(t){var e=this.getOptions(),n=Dd(e,"gauge","deltaArrow","direction");switch(n){case et.UP:return yL;case et.DOWN:return _L;default:return t>0?yL:_L}},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer().attr("width","100%").attr("height","100%"),r=this.getOptions(),i=this.getValue(),o=this.getValueRatio(),s=this.getArcSize(),u=this.getStartAngle(),l=o*s,c=u+l,h=u+s,f=this.computeRadius(),p=this.getInnerRadius();this.backgroundArc=cL().innerRadius(p).outerRadius(f).startAngle(c).endAngle(h),this.arc=cL().innerRadius(p).outerRadius(f).startAngle(u).endAngle(c),sb.appendOrSelect(n,"path.arc-background").attr("d",this.backgroundArc);var d=n.selectAll("path.arc-foreground").data([i]),v=d.enter().append("path");v.merge(d).attr("class",this.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:"value",originalClassName:"arc-foreground"})).style("fill",(function(t){return Dd(e.getOptions(),"color","scale","value")})).attr("d",this.arc).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","value").attr("aria-label",(function(t){return t})),this.drawValueNumber(),this.drawDelta(),d.exit().remove();var g=Dd(r,"gauge","alignment"),m=sb.getSVGElementSize(this.getParent(),{useAttrs:!0}).width,y=f;g===F.CENTER?y=m/2:g===F.RIGHT&&(y=m-f),n.attr("x",y).attr("y",f),this.addEventListeners()},e.prototype.drawValueNumber=function(){var t=this.getComponentContainer(),e=this.getOptions(),n=Dd(e,"gauge","type"),r=this.getValue(),i=this.getDelta(),o=this.computeRadius(),a=Dd(e,"gauge","valueFontSize"),s=Dd(e,"gauge","deltaFontSize"),u=Dd(e,"gauge","numberSpacing"),l=Dd(e,"gauge","showPercentageSymbol"),c=0;n!==tt.FULL||i?n===tt.SEMI&&i&&(c=-(s(o)+u)):c=s(o);var h=sb.appendOrSelect(t,"g.gauge-numbers").attr("transform","translate(0, "+c+")"),f=a(o),p=sb.appendOrSelect(h,"g.gauge-value-number"),d=Dd(e,"gauge","numberFormatter"),v=p.selectAll("text.gauge-value-number").data([r]);v.enter().append("text").attr("class","gauge-value-number").merge(v).style("font-size",f+"px").attr("text-anchor","middle").text((function(t){return d(t)}));var g=sb.getSVGElementSize(sb.appendOrSelect(t,"text.gauge-value-number"),{useBBox:!0}).width,m=f/2,y=l?"%":"",_=sb.appendOrSelect(p,"text.gauge-value-symbol").style("font-size",m+"px").attr("x",g/2).text(y),b=sb.getSVGElementSize(_,{useBBox:!0}),w=b.width,O=b.height;_.attr("y","-"+O/2+"px"),p.attr("transform","translate(-"+w/2+", 0)")},e.prototype.drawDelta=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=this.getDelta();if(r){var i=this.computeRadius(),o=r?Dd(n,"gauge","deltaFontSize"):function(){return 0},a=r?Dd(n,"gauge","numberFormatter"):function(){return null},s=Dd(n,"gauge","deltaArrow","size"),u=Dd(n,"gauge","numberSpacing"),l=Dd(n,"gauge","showPercentageSymbol"),c=sb.appendOrSelect(e,"g.gauge-numbers"),h=(g=sb.appendOrSelect(c,"g.gauge-delta").attr("transform","translate(0, "+(o(i)+u)+")"),sb.appendOrSelect(g,"text.gauge-delta-number")),f=l?"%":"";h.data(null===r?[]:[r]),h.enter().append("text").classed("gauge-delta-number",!0).merge(h).attr("text-anchor","middle").style("font-size",o(i)+"px").text((function(t){return""+a(t)+f}));var p=sb.getSVGElementSize(sb.appendOrSelect(e,".gauge-delta-number"),{useBBox:!0}).width,d=Dd(n,"gauge","deltaArrow","enabled"),v=g.selectAll("svg.gauge-delta-arrow").data(null!==r&&d?[r]:[]);v.enter().append("svg").merge(v).attr("class","gauge-delta-arrow").attr("x",-s(i)-p/2).attr("y",-s(i)/2-.35*o(i)).attr("width",s(i)).attr("height",s(i)).attr("viewBox","0 0 16 16").each((function(){var e=eb(this);sb.appendOrSelect(e,"rect.gauge-delta-arrow-backdrop").attr("width","16").attr("height","16").attr("fill","none");var i=Dd(n,"gauge","status");sb.appendOrSelect(e,"polygon.gauge-delta-arrow").attr("class",null!==i?"gauge-delta-arrow status--"+i:"").attr("points",t.getArrow(r))})),v.exit().remove(),h.exit().remove()}else{var g=e.select("g.gauge-delta");g.empty()||g.remove()}},e.prototype.getInnerRadius=function(){var t=this.computeRadius(),e=Dd(this.getOptions(),"gauge","arcWidth");return t-e},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.arc-foreground").on("mouseover",(function(e,n){t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEOVER,{event:e,element:eb(this),datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEMOVE,{event:e,element:r,datum:n})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Gauge.ARC_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEOUT,{event:e,element:r,datum:n})}))},e.prototype.computeRadius=function(){var t=this.getOptions(),e=Dd(t,"gauge","type"),n=sb.getSVGElementSize(this.parent,{useAttrs:!0}),r=n.width,i=n.height,o=e===tt.SEMI?Math.min(r/2,i):Math.min(r/2,i/2);return o},e}(DS),wL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),OL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="donut",e.renderType=I.SVG,e}return wL(e,t),e.prototype.render=function(e){var n=this;void 0===e&&(e=!0),t.prototype.render.call(this,e);var r=this;if(this.model.isDataEmpty())this.getComponentContainer().select("g.center").remove();else{var i=sb.appendOrSelect(this.getComponentContainer(),"g.center"),o=this.getOptions(),a=this.computeRadius(),s=Dd(o,"donut","center","label");sb.appendOrSelect(i,"text.donut-figure").attr("text-anchor","middle").style("dominant-baseline",(function(){return null===s||""===s?"central":"initial"})).style("font-size",(function(){return o.donut.center.numberFontSize(a)})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"donut-figure-enter-update",animate:e})})).tween("text",(function(){return r.centerNumberTween(eb(this))})),null!==s&&""!==s&&sb.appendOrSelect(i,"text.donut-title").attr("text-anchor","middle").style("font-size",(function(){return o.donut.center.titleFontSize(a)})).attr("y",o.donut.center.titleYPosition(a)).text(s)}},e.prototype.getInnerRadius=function(){var t=this.computeRadius();return t*(3/4)},e.prototype.centerNumberTween=function(t){var e=this.getOptions(),n=Dd(e,"donut","center","number");null===n&&(n=this.model.getDisplayData().reduce((function(t,n){return t+n[e.pie.valueMapsTo]}),0));var r,i=parseInt(t.text().replace(/[, ]+/g,""),10)||0;r=i%1===0&&n%1===0?jx:Ax;var o=r(i,n);return function(n){var r=e.donut.center.numberFormatter;t.text(r(o(n)))}},e}(gL);const xL=t=>+t;var EL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),TL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="skeleton",e}return EL(e,t),e.prototype.render=function(){var t=Dd(this.getOptions(),"data","loading");t?this.renderSkeleton(t):this.removeSkeleton()},e.prototype.renderSkeleton=function(t){if(this.configs.skeleton===K.GRID)this.renderGridSkeleton(t);else if(this.configs.skeleton===K.VERT_OR_HORIZ)this.renderVertOrHorizSkeleton(t);else if(this.configs.skeleton===K.PIE)this.renderPieSkeleton(t);else{if(this.configs.skeleton!==K.DONUT)throw new Error('"'+this.configs.skeleton+'" is not a valid Skeleton type.');this.renderDonutSkeleton(t)}},e.prototype.renderGridSkeleton=function(t){this.setScales(),this.drawBackdrop(t),this.drawXGrid(t),this.drawYGrid(t),t&&this.setShimmerEffect("shimmer-lines")},e.prototype.renderVertOrHorizSkeleton=function(t){var e=this.services.cartesianScales.getOrientation();this.setScales(),this.drawBackdrop(t),e===H.VERTICAL&&this.drawYGrid(t),e===H.HORIZONTAL&&this.drawXGrid(t),this.setShimmerEffect("shimmer-lines")},e.prototype.renderPieSkeleton=function(t){var e=this.computeOuterRadius(),n=0;this.drawRing(e,n,t),t&&this.setShimmerEffect("shimmer-areas")},e.prototype.renderDonutSkeleton=function(t){var e=this.computeOuterRadius(),n=this.computeInnerRadius();this.drawRing(e,n,t),t&&this.setShimmerEffect("shimmer-areas")},e.prototype.setScales=function(){var t=this.services.cartesianScales.getMainXScale().range(),e=this.services.cartesianScales.getMainYScale().range();this.xScale=BE().domain([0,1]).range(t),this.yScale=BE().domain([0,1]).range(e)},e.prototype.drawBackdrop=function(t){var e=this.parent,n=sb.getSVGElementSize(e,{useAttrs:!0}),r=n.width,i=n.height;this.backdrop=sb.appendOrSelect(e,"svg.chart-skeleton.DAII").attr("width",r).attr("height",i);var o=sb.appendOrSelect(this.backdrop,"rect.chart-skeleton-backdrop");o.attr("width","100%").attr("height","100%");var a=this.xScale.range(),s=a[0],u=(a[1],this.yScale.range()),l=(u[0],u[1]);this.backdrop.merge(o).attr("x",s).attr("y",l),o.classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawXGrid=function(t){var e=this.backdrop.attr("width"),n=Dd(this.getOptions(),"grid","x","numberOfTicks"),r=this.xScale.ticks(n).map((function(t){return t*e})),i=sb.appendOrSelect(this.backdrop,"g.x.skeleton"),o=i.selectAll("line").data(r);o.enter().append("line").merge(o).attr("x1",(function(t){return t})).attr("x2",(function(t){return t})).attr("y1",0).attr("y2","100%"),i.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawYGrid=function(t){var e=this.backdrop.attr("height"),n=this.backdrop.attr("width"),r=Dd(this.getOptions(),"grid","y","numberOfTicks"),i=this.xScale.ticks(r).map((function(t){return t*e})),o=sb.appendOrSelect(this.backdrop,"g.y.skeleton"),a=o.selectAll("line").data(i);a.enter().append("line").merge(a).attr("x1",0).attr("x2",n).attr("y1",(function(t){return t})).attr("y2",(function(t){return t})),o.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawRing=function(t,e,n){void 0===n&&(n=!0);var r=this.parent,i=sb.getSVGElementSize(r,{useAttrs:!0}),o=i.width,a=i.height,s=sb.appendOrSelect(r,"svg.chart-skeleton").attr("width",o).attr("height",a),u=0===e?"pie":"donut",l=Dd(this.getOptions(),u,"alignment");sb.appendOrSelect(s,"rect.chart-skeleton-area-container").attr("width",o).attr("height",a).attr("fill","none");var c=cL().innerRadius(e).outerRadius(t).startAngle(0).endAngle(2*Math.PI),h=t+Math.abs(Tt.radiusOffset),f=t+(Math.min(o,a)-2*t)/2,p=sb.appendOrSelect(s,"path").attr("class","skeleton-area-shape").attr("transform","translate("+h+", "+f+")").attr("d",c).classed("shimmer-effect-areas",n).classed("empty-state-areas",!n).style("fill",n?"url(#"+this.services.domUtils.generateElementIDString("shimmer-areas")+")":null),d=t+Tt.xOffset;l===F.CENTER?d=o/2:l===F.RIGHT&&(d=o-t-Tt.xOffset);var v=t+Tt.yOffset;p.attr("transform","translate("+d+", "+v+")")},e.prototype.computeOuterRadius=function(){var t=sb.getSVGElementSize(this.parent,{useAttrs:!0}),e=t.width,n=t.height,r=Math.min(e,n)/2;return r+Tt.radiusOffset},e.prototype.computeInnerRadius=function(){return this.computeOuterRadius()*(3/4)},e.prototype.setShimmerEffect=function(t){var e=2e3,n=1e3,r=.2,i="stop-bg-shimmer",o="stop-shimmer",a=this.parent.select(".chart-skeleton"),s=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,u=0,l=s,c=sb.appendOrSelect(a,"defs").lower(),h=sb.appendOrSelect(c,"linearGradient").attr("id",this.services.domUtils.generateElementIDString(t)).attr("class",t).attr("x1",u-3*r*s).attr("x2",l).attr("y1",0).attr("y2",0).attr("gradientUnits","userSpaceOnUse").attr("gradientTransform","translate(0, 0)"),f='\n\t\t\t<stop class="'+i+'" offset="'+u+'"></stop>\n\t\t\t<stop class="'+o+'" offset="'+(u+r)+'"></stop>\n\t\t\t<stop class="'+i+'" offset="'+(u+2*r)+'"></stop>\n\t\t';function p(){h.attr("gradientTransform","translate("+(u-3*r*s)+", 0)").transition().duration(e).delay(n).ease(xL).attr("gradientTransform","translate("+(l+3*r*s)+", 0)").on("end",p)}h.html(f),p()},e.prototype.removeSkeleton=function(){var t=this.parent.select(".chart-skeleton");t.remove()},e}(DS),SL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ML=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="skeleton-lines",e}return SL(e,t),e.prototype.render=function(){var e=Dd(this.getOptions(),"data","loading"),n=!Dd(this.getOptions(),"grid","x","enabled")&&!Dd(this.getOptions(),"grid","y","enabled")&&!Dd(this.getOptions(),"axes","bottom","visible")&&!Dd(this.getOptions(),"axes","left","visible");e&&!n?t.prototype.renderGridSkeleton.call(this,e):e&&n?this.renderSparklineSkeleton(e):this.removeSkeleton()},e.prototype.renderSparklineSkeleton=function(t){this.setScales(),this.drawBackdrop(t),this.drawSparkline(t),this.updateBackdropStyle(),t&&this.setShimmerEffect("shimmer-lines")},e.prototype.drawSparkline=function(t){var e=this.backdrop.attr("width"),n=[100],r=sb.appendOrSelect(this.backdrop,"g.y.skeleton"),i=r.selectAll("line").data(n);i.enter().append("line").merge(i).attr("x1",0).attr("x2",e).attr("y1",(function(t){return t})).attr("y2",(function(t){return t})),r.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.updateBackdropStyle=function(){var t=this.parent;this.backdrop=sb.appendOrSelect(t,"svg.chart-skeleton.DAII");var e=sb.appendOrSelect(this.backdrop,"rect.chart-skeleton-backdrop");e.classed("shimmer-effect-lines",!1).classed("shimmer-effect-sparkline",!0).style("stroke",null)},e}(TL);function CL(t){var e=0,n=t.children,r=n&&n.length;if(r)while(--r>=0)e+=n[r].value;else e=1;t.value=e}var AL=function(){return this.eachAfter(CL)},LL=function(t,e){let n=-1;for(const r of this)t.call(e,r,++n,this);return this},DL=function(t,e){var n,r,i=this,o=[i],a=-1;while(i=o.pop())if(t.call(e,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},kL=function(t,e){var n,r,i,o=this,a=[o],s=[],u=-1;while(o=a.pop())if(s.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);while(o=s.pop())t.call(e,o,++u,this);return this},PL=function(t,e){let n=-1;for(const r of this)if(t.call(e,r,++n,this))return r},RL=function(t){return this.eachAfter((function(e){var n=+t(e.data)||0,r=e.children,i=r&&r.length;while(--i>=0)n+=r[i].value;e.value=n}))},IL=function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},NL=function(t){var e=this,n=jL(e,t),r=[e];while(e!==n)e=e.parent,r.push(e);var i=r.length;while(t!==n)r.splice(i,0,t),t=t.parent;return r};function jL(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();while(t===e)i=t,t=n.pop(),e=r.pop();return i}var BL=function(){var t=this,e=[t];while(t=t.parent)e.push(t);return e},UL=function(){return Array.from(this)},VL=function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},HL=function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},GL=function*(){var t,e,n,r,i=this,o=[i];do{t=o.reverse(),o=[];while(i=t.pop())if(yield i,e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n])}while(o.length)};function zL(t,e){t instanceof Map?(t=[void 0,t],void 0===e&&(e=qL)):void 0===e&&(e=WL);var n,r,i,o,a,s=new ZL(t),u=[s];while(n=u.pop())if((i=e(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)u.push(r=i[o]=new ZL(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(YL)}function FL(){return zL(this).eachBefore($L)}function WL(t){return t.children}function qL(t){return Array.isArray(t)?t[1]:null}function $L(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function YL(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function ZL(t){this.data=t,this.depth=this.height=0,this.parent=null}function XL(t,e){return t.parent===e.parent?1:2}function KL(t){return t.reduce(QL,0)/t.length}function QL(t,e){return t+e.x}function JL(t){return 1+t.reduce(tD,0)}function tD(t,e){return Math.max(t,e.y)}function eD(t){var e;while(e=t.children)t=e[0];return t}function nD(t){var e;while(e=t.children)t=e[e.length-1];return t}ZL.prototype=zL.prototype={constructor:ZL,count:AL,each:LL,eachAfter:kL,eachBefore:DL,find:PL,sum:RL,sort:IL,path:NL,ancestors:BL,descendants:UL,leaves:VL,links:HL,copy:FL,[Symbol.iterator]:GL};var rD=function(){var t=XL,e=1,n=1,r=!1;function i(i){var o,a=0;i.eachAfter((function(e){var n=e.children;n?(e.x=KL(n),e.y=JL(n)):(e.x=o?a+=t(e,o):0,e.y=0,o=e)}));var s=eD(i),u=nD(i),l=s.x-t(s,u)/2,c=u.x+t(u,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-l)/(c-l)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i};function iD(t,e){return t.parent===e.parent?1:2}function oD(t){var e=t.children;return e?e[0]:t.t}function aD(t){var e=t.children;return e?e[e.length-1]:t.t}function sD(t,e,n){var r=n/(e.i-t.i);e.c-=r,e.s+=n,t.c+=r,e.z+=n,e.m+=n}function uD(t){var e,n=0,r=0,i=t.children,o=i.length;while(--o>=0)e=i[o],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function lD(t,e,n){return t.a.parent===e.parent?t.a:n}function cD(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}function hD(t){var e,n,r,i,o,a=new cD(t,0),s=[a];while(e=s.pop())if(r=e._.children)for(e.children=new Array(o=r.length),i=o-1;i>=0;--i)s.push(n=e.children[i]=new cD(r[i],i)),n.parent=e;return(a.parent=new cD(null,0)).children=[a],a}cD.prototype=Object.create(ZL.prototype);var fD=function(){var t=iD,e=1,n=1,r=null;function i(i){var s=hD(i);if(s.eachAfter(o),s.parent.m=-s.z,s.eachBefore(a),r)i.eachBefore(u);else{var l=i,c=i,h=i;i.eachBefore((function(t){t.x<l.x&&(l=t),t.x>c.x&&(c=t),t.depth>h.depth&&(h=t)}));var f=l===c?1:t(l,c)/2,p=f-l.x,d=e/(c.x+f+p),v=n/(h.depth||1);i.eachBefore((function(t){t.x=(t.x+p)*d,t.y=t.depth*v}))}return i}function o(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){uD(e);var o=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-o):e.z=o}else i&&(e.z=i.z+t(e._,i._));e.parent.A=s(e,i,e.parent.A||r[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(e,n,r){if(n){var i,o=e,a=e,s=n,u=o.parent.children[0],l=o.m,c=a.m,h=s.m,f=u.m;while(s=aD(s),o=oD(o),s&&o)u=oD(u),a=aD(a),a.a=e,i=s.z+h-o.z-l+t(s._,o._),i>0&&(sD(lD(s,e,r),e,i),l+=i,c+=i),h+=s.m,l+=o.m,f+=u.m,c+=a.m;s&&!aD(a)&&(a.t=s,a.m+=h-c),o&&!oD(u)&&(u.t=o,u.m+=l-f,r=e)}return r}function u(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i};class pD{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e);break}this._x0=t,this._y0=e}}function dD(t){return new pD(t,!0)}function vD(t){return t.source}function gD(t){return t.target}function mD(t){let e=vD,n=gD,r=TA,i=SA,o=null,a=null,s=EA(u);function u(){let u;const l=Av.call(arguments),c=e.apply(this,l),h=n.apply(this,l);if(null==o&&(a=t(u=s())),a.lineStart(),l[0]=c,a.point(+r.apply(this,l),+i.apply(this,l)),l[0]=h,a.point(+r.apply(this,l),+i.apply(this,l)),a.lineEnd(),u)return a=null,u+""||null}return u.source=function(t){return arguments.length?(e=t,u):e},u.target=function(t){return arguments.length?(n=t,u):n},u.x=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),u):r},u.y=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),u):i},u.context=function(e){return arguments.length?(null==e?o=a=null:a=t(o=e),u):o},u}function yD(){return mD(dD)}var _D=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),bD=6,wD=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="tree",e.renderType=I.SVG,e}return _D(e,t),e.prototype.getLongestLabel=function(t){var e=this,n="";return t.forEach((function(t){var r=t.children?e.getLongestLabel(t.children):"";(r.length>n.length||t.name.length>n.length)&&(n=r.length>t.name.length?r:t.name)})),n},e.prototype.getMockLabelWidth=function(t,e){var n=t.append("text").attr("dy","0.31em").attr("x",0).attr("text-anchor","end").text(e),r=sb.getSVGElementSize(n.node(),{useBBox:!0}).width;return n.remove(),r},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer();n.html("");var r=sb.getSVGElementSize(this.parent,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getOptions(),s=this.model.getDisplayData(),u=Dd(a,"tree","rootTitle")||"Tree",l=this.getMockLabelWidth(n,u),c=this.getLongestLabel(s),h=this.getMockLabelWidth(n,c),f={top:0,right:0,bottom:0,left:l>0?l+bD:30-bD},p=zL({name:u,children:s}),d=10,v=i/6,g=function(t){var r=p.descendants().reverse(),o=p.links(),a=p,s=p;p.eachBefore((function(t){t.x<a.x&&(a=t),t.x>s.x&&(s=t)}));var u=s.x-a.x,l=n.transition().call((function(t){return e.services.transitions.setupTransition({transition:t,name:"tree-update-viewbox",animate:!0})})).attr("viewBox",[-f.left,a.x,i,u]),c=O.selectAll("g").data(r,(function(t){return t.id})),h=e,d=c.enter().append("g").attr("transform",(function(){return"translate("+t.y0+","+t.x0+")"})).attr("class",(function(t){return 0!==t.depth&&t.children&&t.children.length>0?"clickable":null})).on("mouseover",(function(t,e){h.services.events.dispatchEvent(ft.Tree.NODE_MOUSEOVER,{event:t,element:eb(this),datum:e})})).on("click",(function(t,e){0!==e.depth&&(e.children=e.children?null:e._children,g(e)),h.services.events.dispatchEvent(ft.Tree.NODE_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){h.services.events.dispatchEvent(ft.Tree.NODE_MOUSEOUT,{event:t,element:eb(this),datum:e})}));d.append("circle").attr("r",2.5).attr("class",(function(t){return t._children?"parent":"child"})).attr("stroke-width",10),d.append("text").attr("dy","0.31em").attr("x",(function(t){return t._children?-bD:bD})).attr("text-anchor",(function(t){return t._children?"end":"start"})).text((function(t){return t.data.name})).clone(!0).attr("class","text-stroke").lower(),c.merge(d).transition(l).attr("transform",(function(t){return"translate("+t.y+","+t.x+")"})).attr("fill-opacity",1).attr("stroke-opacity",1),c.exit().transition(l).remove().attr("transform",(function(){return"translate("+t.y+","+t.x+")"})).attr("fill-opacity",0).attr("stroke-opacity",0);var v=w.selectAll("path").data(o,(function(t){return t.target.id})),m=v.enter().append("path").attr("d",(function(e){var n={x:t.x0,y:t.y0};return b({source:n,target:n})}));v.merge(m).transition(l).attr("d",b),v.exit().transition(l).remove().attr("d",(function(){var e={x:t.x,y:t.y};return b({source:e,target:e})})),p.eachBefore((function(t){t.x0=t.x,t.y0=t.y}))},m=p.descendants(),y=m[m.length-1].depth,_=Dd(a,"tree","type")===q.DENDROGRAM?rD().size([o,i-h-y*bD-l]):fD().nodeSize([d,v]).size([o,i-h-y*bD-l]),b=yD().x((function(t){return t.y})).y((function(t){return t.x}));p.x0=v/2,p.y0=0,p.descendants().forEach((function(t,e){t.id=e,t._children=t.children})),_(p),n.attr("viewBox",[-f.left,-f.top,i,d]).style("user-select","none");var w=n.append("g").attr("class","links"),O=n.append("g").attr("class","nodes");g(p)}},e}(DS),OD=function(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)},xD=function(t,e,n,r,i){var o,a=t.children,s=-1,u=a.length,l=t.value&&(r-e)/t.value;while(++s<u)o=a[s],o.y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*l},ED=function(t,e,n,r,i){var o,a=t.children,s=-1,u=a.length,l=t.value&&(i-n)/t.value;while(++s<u)o=a[s],o.x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*l},TD=(1+Math.sqrt(5))/2;function SD(t,e,n,r,i,o){var a,s,u,l,c,h,f,p,d,v,g,m=[],y=e.children,_=0,b=0,w=y.length,O=e.value;while(_<w){u=i-n,l=o-r;do{c=y[b++].value}while(!c&&b<w);for(h=f=c,v=Math.max(l/u,u/l)/(O*t),g=c*c*v,d=Math.max(f/g,g/h);b<w;++b){if(c+=s=y[b].value,s<h&&(h=s),s>f&&(f=s),g=c*c*v,p=Math.max(f/g,g/h),p>d){c-=s;break}d=p}m.push(a={value:c,dice:u<l,children:y.slice(_,b)}),a.dice?xD(a,n,r,i,O?r+=l*c/O:o):ED(a,n,r,O?n+=u*c/O:i,o),O-=c,_=b}return m}var MD=function t(e){function n(t,n,r,i,o){SD(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(TD);function CD(t){return null==t?null:AD(t)}function AD(t){if("function"!==typeof t)throw new Error;return t}function LD(){return 0}var DD=function(t){return function(){return t}},kD=function(){var t=MD,e=!1,n=1,r=1,i=[0],o=LD,a=LD,s=LD,u=LD,l=LD;function c(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(h),i=[0],e&&t.eachBefore(OD),t}function h(e){var n=i[e.depth],r=e.x0+n,c=e.y0+n,h=e.x1-n,f=e.y1-n;h<r&&(r=h=(r+h)/2),f<c&&(c=f=(c+f)/2),e.x0=r,e.y0=c,e.x1=h,e.y1=f,e.children&&(n=i[e.depth+1]=o(e)/2,r+=l(e)-n,c+=a(e)-n,h-=s(e)-n,f-=u(e)-n,h<r&&(r=h=(r+h)/2),f<c&&(c=f=(c+f)/2),t(e,r,c,h,f))}return c.round=function(t){return arguments.length?(e=!!t,c):e},c.size=function(t){return arguments.length?(n=+t[0],r=+t[1],c):[n,r]},c.tile=function(e){return arguments.length?(t=AD(e),c):t},c.padding=function(t){return arguments.length?c.paddingInner(t).paddingOuter(t):c.paddingInner()},c.paddingInner=function(t){return arguments.length?(o="function"===typeof t?t:DD(+t),c):o},c.paddingOuter=function(t){return arguments.length?c.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):c.paddingTop()},c.paddingTop=function(t){return arguments.length?(a="function"===typeof t?t:DD(+t),c):a},c.paddingRight=function(t){return arguments.length?(s="function"===typeof t?t:DD(+t),c):s},c.paddingBottom=function(t){return arguments.length?(u="function"===typeof t?t:DD(+t),c):u},c.paddingLeft=function(t){return arguments.length?(l="function"===typeof t?t:DD(+t),c):l},c},PD="#000000",RD="#ffffff",ID="#fcf4d6",ND="#fddc69",jD="#f1c21b",BD="#d2a106",UD="#b28600",VD="#8e6a00",HD="#684e00",GD="#483700",zD="#302400",FD="#1c1500",WD={10:ID,20:ND,30:jD,40:BD,50:UD,60:VD,70:HD,80:GD,90:zD,100:FD},qD="#fff2e8",$D="#ffd9be",YD="#ffb784",ZD="#ff832b",XD="#eb6200",KD="#ba4e00",QD="#8a3800",JD="#5e2900",tk="#3e1a00",ek="#231000",nk={10:qD,20:$D,30:YD,40:ZD,50:XD,60:KD,70:QD,80:JD,90:tk,100:ek},rk="#fff1f1",ik="#ffd7d9",ok="#ffb3b8",ak="#ff8389",sk="#fa4d56",uk="#da1e28",lk="#a2191f",ck="#750e13",hk="#520408",fk="#2d0709",pk={10:rk,20:ik,30:ok,40:ak,50:sk,60:uk,70:lk,80:ck,90:hk,100:fk},dk="#fff0f7",vk="#ffd6e8",gk="#ffafd2",mk="#ff7eb6",yk="#ee5396",_k="#d02670",bk="#9f1853",wk="#740937",Ok="#510224",xk="#2a0a18",Ek={10:dk,20:vk,30:gk,40:mk,50:yk,60:_k,70:bk,80:wk,90:Ok,100:xk},Tk="#f6f2ff",Sk="#e8daff",Mk="#d4bbff",Ck="#be95ff",Ak="#a56eff",Lk="#8a3ffc",Dk="#6929c4",kk="#491d8b",Pk="#31135e",Rk="#1c0f30",Ik={10:Tk,20:Sk,30:Mk,40:Ck,50:Ak,60:Lk,70:Dk,80:kk,90:Pk,100:Rk},Nk="#edf5ff",jk="#d0e2ff",Bk="#a6c8ff",Uk="#78a9ff",Vk="#4589ff",Hk="#0f62fe",Gk="#0043ce",zk="#002d9c",Fk="#001d6c",Wk="#001141",qk={10:Nk,20:jk,30:Bk,40:Uk,50:Vk,60:Hk,70:Gk,80:zk,90:Fk,100:Wk},$k="#e5f6ff",Yk="#bae6ff",Zk="#82cfff",Xk="#33b1ff",Kk="#1192e8",Qk="#0072c3",Jk="#00539a",tP="#003a6d",eP="#012749",nP="#061727",rP={10:$k,20:Yk,30:Zk,40:Xk,50:Kk,60:Qk,70:Jk,80:tP,90:eP,100:nP},iP="#d9fbfb",oP="#9ef0f0",aP="#3ddbd9",sP="#08bdba",uP="#009d9a",lP="#007d79",cP="#005d5d",hP="#004144",fP="#022b30",pP="#081a1c",dP={10:iP,20:oP,30:aP,40:sP,50:uP,60:lP,70:cP,80:hP,90:fP,100:pP},vP="#defbe6",gP="#a7f0ba",mP="#6fdc8c",yP="#42be65",_P="#24a148",bP="#198038",wP="#0e6027",OP="#044317",xP="#022d0d",EP="#071908",TP={10:vP,20:gP,30:mP,40:yP,50:_P,60:bP,70:wP,80:OP,90:xP,100:EP},SP="#f2f4f8",MP="#dde1e6",CP="#c1c7cd",AP="#a2a9b0",LP="#878d96",DP="#697077",kP="#4d5358",PP="#343a3f",RP="#21272a",IP="#121619",NP={10:SP,20:MP,30:CP,40:AP,50:LP,60:DP,70:kP,80:PP,90:RP,100:IP},jP="#f4f4f4",BP="#e0e0e0",UP="#c6c6c6",VP="#a8a8a8",HP="#8d8d8d",GP="#6f6f6f",zP="#525252",FP="#393939",WP="#262626",qP="#161616",$P={10:jP,20:BP,30:UP,40:VP,50:HP,60:GP,70:zP,80:FP,90:WP,100:qP},YP="#f7f3f2",ZP="#e5e0df",XP="#cac5c4",KP="#ada8a8",QP="#8f8b8b",JP="#726e6e",tR="#565151",eR="#3c3838",nR="#272525",rR="#171414",iR={10:YP,20:ZP,30:XP,40:KP,50:QP,60:JP,70:tR,80:eR,90:nR,100:rR},oR={black:{100:PD},blue:qk,coolGray:NP,cyan:rP,gray:$P,green:TP,magenta:Ek,orange:nk,purple:Ik,red:pk,teal:dP,warmGray:iR,white:{0:RD},yellow:WD};var aR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sR=function(t){if(!t)return null;for(var e=0,n=Object.keys(oR);e<n.length;e++)for(var r=n[e],i=oR[r],o=0,a=Object.keys(i);o<a.length;o++){var s=a[o],u=i[s];if(u===t)return s}return null},uR=function(){var t,e=eb(this.parentNode).select("rect.leaf"),n=getComputedStyle(e.node(),null).getPropertyValue("fill"),r=XO(n);if(r&&(t=sR(r?r.hex():null)),null===t||void 0===t){var i=cx(r).l;t=Math.abs(100*i-100)}return t>50?"white":"black"},lR=0,cR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="treemap",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("g[data-name='leaf']").transition("legend-hover-treemap").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-treemap"})})).attr("opacity",(function(t){return t.parent.data.name===n.datum()["name"]?1:.3}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("g[data-name='leaf']").transition("legend-mouseout-treemap").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-treemap"})})).attr("opacity",1)},e}return aR(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=(this.model.getData(),this.model.getDisplayData()),i=this.model.getOptions(),o=Dd(window,"location"),a=sb.getSVGElementSize(n,{useAttrs:!0}),s=a.width,u=a.height,l=zL({name:i.title||"Treemap",children:r}).sum((function(t){return t.value})).sort((function(t,e){return e.value-t.value})),c=kD().size([s,u]).paddingInner(1).paddingOuter(0).round(!0)(l),h=(this.services.transitions,n.selectAll("g[data-name='leaf']").data(c.leaves(),(function(t){return t.data.name})));h.exit().attr("opacity",0).remove();var f=h.enter().append("g").attr("data-name","leaf").attr("data-uid",(function(){return lR++})),p=f.merge(h);p.attr("data-name","leaf").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"treemap-group-update",animate:t})})).attr("transform",(function(t){return"translate("+t.x0+","+t.y0+")"}));var d=p.selectAll("rect.leaf").data((function(t){return[t]}));d.exit().attr("width",0).attr("height",0).remove();var v=d.enter().append("rect").classed("leaf",!0);v.merge(d).attr("width",0).attr("height",0).attr("id",(function(){var t=eb(this.parentNode).attr("data-uid");return i.style.prefix+"-leaf-"+t})).attr("class",(function(t){while(t.depth>1)t=t.parent;return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.data.name,originalClassName:"leaf"})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"treemap-leaf-update-enter",animate:t})})).attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})).style("fill",(function(t){while(t.depth>1)t=t.parent;return e.model.getFillColor(t.data.name)})),p.selectAll("clipPath").data((function(t){return!0!==t.data.showLabel?[]:[1]}),(function(t){return t})).join((function(t){t.append("clipPath").attr("id",(function(){var t=eb(this.parentNode).attr("data-uid");return i.style.prefix+"-clip-"+t})).append("use").attr("xlink:href",(function(){var t=eb(this.parentNode.parentNode).attr("data-uid"),e=i.style.prefix+"-leaf-"+t;return new URL("#"+e,o)+""}))}),(function(t){return null}),(function(t){return t.remove()})),p.selectAll("text").data((function(t){if(!0!==t.data.showLabel)return[];var n=t;while(n.depth>1)n=n.parent;var r=cx(e.model.getFillColor(n.data.name));return[{text:t.data.name,color:r.l<.5?"white":"black"}]}),(function(t){return t})).join((function(t){var e=t.append("text").text((function(t){return t.text})).style("fill",uR).attr("x",7).attr("y",18);o&&e.attr("clip-path",(function(){var t=eb(this.parentNode).attr("data-uid"),e=i.style.prefix+"-clip-"+t;return"url("+new URL("#"+e,o)+")"}))}),(function(t){return t.text((function(t){return t.text})).style("fill",uR)}),(function(t){return t.remove()})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("rect.leaf").on("mouseover",(function(e,n){var r=eb(this),i=getComputedStyle(this,null).getPropertyValue("fill"),o=n;while(o.depth>1)o=o.parent;r.transition("graph_element_mouseover_fill_update").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"graph_element_mouseover_fill_update"})})).style("fill",(function(e){var n=t.model.getFillColor(e.parent.data.name);return n&&(i=n),XO(i).darker(.7).toString()})),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:[{color:i,label:o.data.name,bold:!0},{label:n.data.name,value:n.data.value}]}),t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEOVER,{event:e,element:r,datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Treemap.LEAF_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1);var i=n;while(i.depth>1)i=i.parent;r.transition().call((function(e){return t.services.transitions.setupTransition({transition:e,name:"graph_element_mouseout_fill_update"})})).style("fill",(function(e){return t.model.getFillColor(e.parent.data.name)})),t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e}(DS);function hR(t){var e=fR(dR(t),360);return pR(e,[0,10])||pR(e,[350,0])?{textAnchor:Q.START,dominantBaseline:J.MIDDLE}:pR(e,[10,80])?{textAnchor:Q.START,dominantBaseline:J.HANGING}:pR(e,[80,100])?{textAnchor:Q.MIDDLE,dominantBaseline:J.HANGING}:pR(e,[100,170])?{textAnchor:Q.END,dominantBaseline:J.HANGING}:pR(e,[170,190])?{textAnchor:Q.END,dominantBaseline:J.MIDDLE}:pR(e,[190,260])?{textAnchor:Q.END,dominantBaseline:J.BASELINE}:pR(e,[260,280])?{textAnchor:Q.MIDDLE,dominantBaseline:J.BASELINE}:{textAnchor:Q.START,dominantBaseline:J.BASELINE}}function fR(t,e){return(t%e+e)%e}function pR(t,e){var n=e[0],r=e[1];return t>=n&&t<=r}function dR(t){return t*(180/Math.PI)}function vR(t,e,n){void 0===n&&(n={x:0,y:0});var r=e*Math.cos(t)+n.x,i=e*Math.sin(t)+n.y;return{x:isNaN(r)?0:r,y:isNaN(i)?0:i}}function gR(t,e){return e*Math.sin(t-Math.PI/2)}var mR=_R(xT);function yR(t){this._curve=t}function _R(t){function e(e){return new yR(t(e))}return e._curve=t,e}function bR(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(_R(t)):e()._curve},t}yR.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};var wR=function(){return bR(MA().curve(mR))},OR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),xR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="radar",e.renderType=I.SVG,e.getLabelDimensions=function(t){var n=sb.appendOrSelect(e.getComponentContainer(),"g.tmp-tick"),r=sb.appendOrSelect(n,"text").text(t),i=sb.getSVGElementSize(r.node(),{useBBox:!0}),o=i.width,a=i.height;return n.remove(),{width:o,height:a}},e.normalizeFlatData=function(t){var n=e.getOptions(),r=Dd(n,"radar","axes"),i=r.angle,o=r.value,a=Dd(n,"data","groupMapsTo"),s=Zh(e.uniqueKeys.map((function(t){return e.uniqueGroups.map((function(e){var n;return n={},n[i]=t,n[a]=e,n[o]=null,n}))})));return na(s,t)},e.normalizeGroupedData=function(t){var n=e.getOptions(),r=Dd(n,"radar","axes"),i=r.angle,o=r.value,a=Dd(n,"data","groupMapsTo");return t.map((function(t){var n=t.name,r=t.data,s=e.uniqueKeys.map((function(t){var e;return e={},e[a]=n,e[i]=t,e[o]=null,e}));return{name:n,data:na(s,r)}}))},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("g.blobs path").transition("legend-hover-blob").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-blob"})})).style("fill-opacity",(function(t){return t.name!==n.datum().name?St.opacity.unselected:St.opacity.selected})).style("stroke-opacity",(function(t){return t.name!==n.datum().name?St.opacity.unselected:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("g.blobs path").transition("legend-mouseout-blob").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-blob"})})).style("fill-opacity",St.opacity.selected).style("stroke-opacity",1)},e}return OR(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height,s=this.model.getData(),u=this.model.getGroupedData(),l=this.getOptions(),c=Dd(l,"data","groupMapsTo"),h=Dd(l,"radar","axes","value"),f=Dd(l,"radar","axes"),p=f.angle,d=f.value,v=St,g=v.xLabelPadding,m=v.yLabelPadding,y=v.yTicksNumber,_=v.minRange,b=v.xAxisRectHeight;this.uniqueKeys=Array.from(new Set(s.map((function(t){return t[p]})))),this.uniqueGroups=Array.from(new Set(s.map((function(t){return t[c]})))),this.fullDataNormalized=this.normalizeFlatData(s),this.groupedDataNormalized=this.normalizeGroupedData(u);var w=this.getLabelDimensions(this.uniqueKeys[0]).height,O=2*(w+m),x=Math.min(i,o),E=x-O,T=E/2;if(!(T<=0)){var S=kE().domain(this.fullDataNormalized.map((function(t){return t[p]}))).range([0,2*Math.PI].map((function(t){return t-Math.PI/2}))),M=Vm(this.fullDataNormalized.map((function(t){return t[d]}))),C=BE().domain([M>=0?0:M,UE(this.fullDataNormalized.map((function(t){return t[d]})))]).range([_,T]).nice(y),A=C.ticks(y),L=function(t){return e.model.getFillColor(t)},D=wR().angle((function(t){return S(t[p])+Math.PI/2})).radius((function(t){return C(t[d])})).curve(ST),k=this.uniqueKeys.map((function(t){var n=e.getLabelDimensions(t).width,r=gR(S(t),T);return n+r})),P=UE(k),R={x:P+g,y:o/2},I=sb.appendOrSelect(n,"g.y-axes").attr("role",a.GROUP),N=I.selectAll("path").data(A,(function(t){return t})),B=function(t){return e.uniqueKeys.map((function(e){var n;return n={},n[p]=e,n[d]=t,n}))};N.join((function(n){return n.append("path").attr("opacity",0).attr("transform","translate("+R.x+", "+R.y+")").attr("fill","none").call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_enter",animate:t})})).attr("opacity",1).attr("d",(function(t){return D(B(t))}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_update",animate:t})})).attr("opacity",1).attr("transform","translate("+R.x+", "+R.y+")").attr("d",(function(t){return D(B(t))}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_exit",animate:t})})).attr("d",(function(t){return D(B(t))})).attr("opacity",0).remove()}))}));var U=sb.appendOrSelect(n,"g.x-axes").attr("role",a.GROUP),V=U.selectAll("line").data(this.uniqueKeys,(function(t){return t}));V.join((function(n){return n.append("line").attr("opacity",0).attr("class",(function(t){return"x-axis-"+Kh(t)})).attr("stroke-dasharray","0").attr("x1",(function(t){return vR(S(t),0,R).x})).attr("y1",(function(t){return vR(S(t),0,R).y})).attr("x2",(function(t){return vR(S(t),0,R).x})).attr("y2",(function(t){return vR(S(t),0,R).y})).call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_enter",animate:t})})).attr("opacity",1).attr("x1",(function(t){return vR(S(t),C.range()[0],R).x})).attr("y1",(function(t){return vR(S(t),C.range()[0],R).y})).attr("x2",(function(t){return vR(S(t),C.range()[1],R).x})).attr("y2",(function(t){return vR(S(t),C.range()[1],R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_update",animate:t})})).attr("opacity",1).attr("x1",(function(t){return vR(S(t),C.range()[0],R).x})).attr("y1",(function(t){return vR(S(t),C.range()[0],R).y})).attr("x2",(function(t){return vR(S(t),C.range()[1],R).x})).attr("y2",(function(t){return vR(S(t),C.range()[1],R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_exit",animate:t})})).attr("opacity",0).remove()}))}));var H=sb.appendOrSelect(n,"g.x-labels").attr("role",a.GROUP),G=H.selectAll("text").data(this.uniqueKeys);G.join((function(n){return n.append("text").text((function(t){return t})).attr("opacity",0).attr("x",(function(t){return vR(S(t),C.range()[1]+g,R).x})).attr("y",(function(t){return vR(S(t),C.range()[1]+g,R).y})).style("text-anchor",(function(t){return hR(S(t)).textAnchor})).style("dominant-baseline",(function(t){return hR(S(t)).dominantBaseline})).call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_enter",animate:t})})).attr("opacity",1)}))}),(function(r){return r.call((function(r){return r.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_update",animate:t})})).attr("opacity",1).attr("x",(function(t){return vR(S(t),C.range()[1]+g,R).x})).attr("y",(function(t){return vR(S(t),C.range()[1]+g,R).y})).end().finally((function(){var t=Dd(l,"radar","alignment"),r=e.getAlignmentXOffset(t,n,e.getParent());n.attr("x",r)}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_exit",animate:t})})).attr("opacity",0).remove()}))}));var z=sb.appendOrSelect(n,"g.blobs").attr("role",a.GROUP),F=z.selectAll("path").data(this.groupedDataNormalized,(function(t){return t.name}));F.join((function(n){return n.append("path").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"blob"})})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){return t["name"]})).attr("opacity",0).attr("transform",t?function(){return"translate("+R.x+", "+R.y+") scale("+(1+.35*Math.random())+")"}:"translate("+R.x+", "+R.y+")").style("fill",(function(t){return L(t.name)})).style("fill-opacity",St.opacity.selected).style("stroke",(function(t){return L(t.name)})).call((function(n){var r=n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_enter",animate:t})}));t&&r.delay((function(){return 30*Math.random()})).attr("transform","translate("+R.x+", "+R.y+")"),r.attr("opacity",1).attr("d",(function(t){return D(t.data)}))}))}),(function(n){n.attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"blob"})})).style("fill",(function(t){return L(t.name)})).style("stroke",(function(t){return L(t.name)})),n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_update",animate:t})})).attr("opacity",1).attr("transform","translate("+R.x+", "+R.y+")").attr("d",(function(t){return D(t.data)}))}))}),(function(n){return n.call((function(n){var r=n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_exit",animate:t})}));t&&r.delay((function(){return 30*Math.random()})).attr("transform",(function(){return"translate("+R.x+", "+R.y+") scale("+(1+.35*Math.random())+")"})),r.attr("opacity",0).remove()}))}));var W=sb.appendOrSelect(n,"g.dots").attr("role",a.GROUP),q=W.selectAll("circle").data(this.fullDataNormalized.filter((function(t){return null!==Dd(t,d)})));q.join((function(t){return t.append("circle").attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){return t[h]}))}),(function(t){return t}),(function(t){return t.remove()})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[c],originalClassName:Kh(t[p])})})).attr("cx",(function(t){return vR(S(t[p]),C(t[d]),R).x})).attr("cy",(function(t){return vR(S(t[p]),C(t[d]),R).y})).attr("r",0).attr("opacity",0).style("fill",(function(t){return L(t[c])}));var $=sb.appendOrSelect(n,"g.x-axes-rect").attr("role",a.GROUP),Y=$.selectAll("rect").data(this.uniqueKeys);Y.join((function(t){return t.append("rect")}),(function(t){return t}),(function(t){return t.remove()})).attr("x",R.x).attr("y",R.y-b/2).attr("width",C.range()[1]).attr("height",b).style("fill","red").style("fill-opacity",0).attr("transform",(function(t){return"rotate("+dR(S(t))+", "+R.x+", "+R.y+")"}));var Z=sb.appendOrSelect(n,"g.y-labels").attr("role",a.GROUP),X=Z.selectAll("text").data(Xv(A));X.join((function(n){return n.append("text").attr("opacity",0).text((function(t){return t})).attr("x",(function(t){return vR(-Math.PI/2,C(t),R).x+m})).attr("y",(function(t){return vR(-Math.PI/2,C(t),R).y})).style("text-anchor","start").style("dominant-baseline","middle").call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_enter",animate:t})})).attr("opacity",1)}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_update",animate:t})})).text((function(t){return t})).attr("opacity",1).attr("x",(function(t){return vR(-Math.PI/2,C(t),R).x+m})).attr("y",(function(t){return vR(-Math.PI/2,C(t),R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_exit",animate:t})})).attr("opacity",0).remove()}))})),this.addEventListeners()}},e.prototype.getAlignmentXOffset=function(t,e,n){var r=sb.getSVGElementSize(e,{useBBox:!0}),i=sb.getSVGElementSize(n,{useAttrs:!0}).width,o=0;return t===F.CENTER?o=Math.floor((i-r.width)/2):t===F.RIGHT&&(o=i-r.width),o},e.prototype.destroy=function(){this.parent.selectAll(".x-axes-rect > rect").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.addEventListeners=function(){var t=this,e=Dd(this.getOptions(),"radar").axes.angle;this.parent.selectAll(".x-axes-rect > rect").on("mouseover",(function(n,r){var i=eb(this);t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEOVER,{event:n,element:i,datum:r});var o=t.parent.select(".x-axes .x-axis-"+Kh(r)),a=t.parent.selectAll(".dots circle."+Kh(r)),s=t.model.getActiveDataGroupNames(),u=t.getOptions(),l=u.data.groupMapsTo,c=Dd(u,"radar","axes","value");o.classed("hovered",!0).attr("stroke-dasharray","4 4"),a.classed("hovered",!0).attr("opacity",(function(t){return-1!==s.indexOf(t[l])?1:0})).attr("r",St.dotsRadius);var h=t.fullDataNormalized.filter((function(t){return t[e]===r&&-1!==s.indexOf(t[l])}));t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n,hoveredElement:i,items:h.filter((function(t){return"number"===typeof t[c]})).map((function(e){return{label:e[l],value:e[c],color:t.model.getFillColor(e[l]),class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:e[l]})}}))})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Radar.X_AXIS_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=t.parent.select(".x-axes .x-axis-"+Kh(n)),o=t.parent.selectAll(".dots circle."+Kh(n));i.classed("hovered",!1).attr("stroke-dasharray","0"),o.classed("hovered",!1).attr("opacity",0).attr("r",0),t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e}(DS);const ER=1664525,TR=1013904223,SR=4294967296;var MR=function(){let t=1;return()=>(t=(ER*t+TR)%SR)/SR},CR=function(t){return"object"===typeof t&&"length"in t?t:Array.from(t)};function AR(t,e){let n,r,i=t.length;while(i)r=e()*i--|0,n=t[i],t[i]=t[r],t[r]=n;return t}function LR(t,e){var n,r,i=0,o=(t=AR(Array.from(t),e)).length,a=[];while(i<o)n=t[i],r&&PR(r,n)?++i:(r=IR(a=DR(a,n)),i=0);return r}function DR(t,e){var n,r;if(RR(e,t))return[e];for(n=0;n<t.length;++n)if(kR(e,t[n])&&RR(jR(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(r=n+1;r<t.length;++r)if(kR(jR(t[n],t[r]),e)&&kR(jR(t[n],e),t[r])&&kR(jR(t[r],e),t[n])&&RR(BR(t[n],t[r],e),t))return[t[n],t[r],e];throw new Error}function kR(t,e){var n=t.r-e.r,r=e.x-t.x,i=e.y-t.y;return n<0||n*n<r*r+i*i}function PR(t,e){var n=t.r-e.r+1e-9*Math.max(t.r,e.r,1),r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function RR(t,e){for(var n=0;n<e.length;++n)if(!PR(t,e[n]))return!1;return!0}function IR(t){switch(t.length){case 1:return NR(t[0]);case 2:return jR(t[0],t[1]);case 3:return BR(t[0],t[1],t[2])}}function NR(t){return{x:t.x,y:t.y,r:t.r}}function jR(t,e){var n=t.x,r=t.y,i=t.r,o=e.x,a=e.y,s=e.r,u=o-n,l=a-r,c=s-i,h=Math.sqrt(u*u+l*l);return{x:(n+o+u/h*c)/2,y:(r+a+l/h*c)/2,r:(h+i+s)/2}}function BR(t,e,n){var r=t.x,i=t.y,o=t.r,a=e.x,s=e.y,u=e.r,l=n.x,c=n.y,h=n.r,f=r-a,p=r-l,d=i-s,v=i-c,g=u-o,m=h-o,y=r*r+i*i-o*o,_=y-a*a-s*s+u*u,b=y-l*l-c*c+h*h,w=p*d-f*v,O=(d*b-v*_)/(2*w)-r,x=(v*g-d*m)/w,E=(p*_-f*b)/(2*w)-i,T=(f*m-p*g)/w,S=x*x+T*T-1,M=2*(o+O*x+E*T),C=O*O+E*E-o*o,A=-(Math.abs(S)>1e-6?(M+Math.sqrt(M*M-4*S*C))/(2*S):C/M);return{x:r+O+x*A,y:i+E+T*A,r:A}}function UR(t,e,n){var r,i,o,a,s=t.x-e.x,u=t.y-e.y,l=s*s+u*u;l?(i=e.r+n.r,i*=i,a=t.r+n.r,a*=a,i>a?(r=(l+a-i)/(2*l),o=Math.sqrt(Math.max(0,a/l-r*r)),n.x=t.x-r*s-o*u,n.y=t.y-r*u+o*s):(r=(l+i-a)/(2*l),o=Math.sqrt(Math.max(0,i/l-r*r)),n.x=e.x+r*s-o*u,n.y=e.y+r*u+o*s)):(n.x=e.x+n.r,n.y=e.y)}function VR(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function HR(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,o=(e.y*n.r+n.y*e.r)/r;return i*i+o*o}function GR(t){this._=t,this.next=null,this.previous=null}function zR(t,e){if(!(o=(t=CR(t)).length))return 0;var n,r,i,o,a,s,u,l,c,h,f;if(n=t[0],n.x=0,n.y=0,!(o>1))return n.r;if(r=t[1],n.x=-r.r,r.x=n.r,r.y=0,!(o>2))return n.r+r.r;UR(r,n,i=t[2]),n=new GR(n),r=new GR(r),i=new GR(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(u=3;u<o;++u){UR(n._,r._,i=t[u]),i=new GR(i),l=r.next,c=n.previous,h=r._.r,f=n._.r;do{if(h<=f){if(VR(l._,i._)){r=l,n.next=r,r.previous=n,--u;continue t}h+=l._.r,l=l.next}else{if(VR(c._,i._)){n=c,n.next=r,r.previous=n,--u;continue t}f+=c._.r,c=c.previous}}while(l!==c.next);i.previous=n,i.next=r,n.next=r.previous=r=i,a=HR(n);while((i=i.next)!==r)(s=HR(i))<a&&(n=i,a=s);r=n.next}n=[r._],i=r;while((i=i.next)!==r)n.push(i._);for(i=LR(n,e),u=0;u<o;++u)n=t[u],n.x-=i.x,n.y-=i.y;return i.r}function FR(t){return Math.sqrt(t.value)}var WR=function(){var t=null,e=1,n=1,r=LD;function i(i){const o=MR();return i.x=e/2,i.y=n/2,t?i.eachBefore(qR(t)).eachAfter($R(r,.5,o)).eachBefore(YR(1)):i.eachBefore(qR(FR)).eachAfter($R(LD,1,o)).eachAfter($R(r,i.r/Math.min(e,n),o)).eachBefore(YR(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=CD(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"===typeof t?t:DD(+t),i):r},i};function qR(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function $R(t,e,n){return function(r){if(i=r.children){var i,o,a,s=i.length,u=t(r)*e||0;if(u)for(o=0;o<s;++o)i[o].r+=u;if(a=zR(i,n),u)for(o=0;o<s;++o)i[o].r-=u;r.r=a+u}}}function YR(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}var ZR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XR=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},KR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="circle-pack",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("circle.node").transition("legend-hover-circlepack").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-circlepack"})})).attr("opacity",(function(t){return t.data.dataGroupName===n.datum()["name"]?1:yt.circles.fillOpacity}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.node").transition("legend-mouseout-circlepack").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-circlepack"})})).attr("opacity",1)},e}return ZR(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=sb.getSVGElementSize(this.parent,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getDisplayData(),s=this.model.hasParentNode(),u=this.model.getHierarchyLevel(),l=this.getOptions(),c=Dd(l,"canvasZoom","enabled");s&&Dd(a,0,"children")&&(a=Dd(a,0,"children"));var h=zL({children:a}).sum((function(t){return t.value})).sort((function(t,e){return e.value-t.value})),f=WR().size([i,o]).padding((function(t){return t.depth>=1?yt.padding.children+3:yt.padding.mainGroup+3})),p=f(h).descendants().splice(1).filter((function(t){return t.depth<=u})),d=n.selectAll("circle.node").data(p);d.exit().attr("width",0).attr("height",0).remove();var v=d.enter().append("circle").classed("node",!0);v.merge(d).attr("class",(function(t){var n=c&&3===u?e.getZoomClass(t):"";return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.data.dataGroupName,originalClassName:t.children?"node "+n:"node node-leaf "+n})})).style("fill",(function(t){return e.model.getFillColor(t.data.dataGroupName)})).style("stroke",(function(t){return e.model.getFillColor(t.data.dataGroupName)})).attr("cx",(function(t){return t.x})).attr("cy",(function(t){return t.y})).transition("circlepack-leaf-update-enter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"circlepack-leaf-update-enter"})})).attr("r",(function(t){return t.r})).attr("opacity",1).attr("fill-opacity",yt.circles.fillOpacity),!0===c&&this.focal&&(this.services.canvasZoom.zoomIn(this.focal,v,mt),this.setBackgroundListeners()),s||this.addLegendListeners(),this.addEventListeners()}},e.prototype.unhighlightChildren=function(t){var e=this,n=t.map((function(t){return t.data}));this.parent.selectAll("circle.node").filter((function(t){return n.some((function(e){return e===t.data}))&&t.depth>1})).style("stroke",(function(t){return e.model.getFillColor(t.data.dataGroupName)}))},e.prototype.highlightChildren=function(t){var e=t.map((function(t){return t.data}));this.parent.selectAll("circle.node").filter((function(t){return e.some((function(e){return e===t.data}))&&t.depth>1})).style("stroke",yt.circles.hover.stroke)},e.prototype.getZoomClass=function(t){return 3===this.model.getHierarchyLevel()&&this.focal&&(t.data===this.focal.data||this.focal.children.some((function(e){return e.data===t.data})))?"focal":"non-focal"},e.prototype.addLegendListeners=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.removeBackgroundListeners=function(){var t=eb(this.services.domUtils.getMainContainer());t.on("click",(function(){return null}))},e.prototype.setBackgroundListeners=function(){var t=eb(this.services.domUtils.getMainContainer()),e=this,n=this.parent.selectAll("circle.node"),r=Dd(o,"canvasZoomSettings");t.on("click",(function(){e.focal=null,e.model.updateHierarchyLevel(2),t.classed("zoomed-in",!1),e.services.canvasZoom.zoomOut(n,r)}))},e.prototype.getZoomIcon=function(){return'\n\t\t<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 10 10">\n\t\t\t<polygon points="5.93 3.71 4.45 3.71 4.45 2.23 3.71 2.23 3.71 3.71 2.23 3.71 2.23 4.45 3.71 4.45 3.71 5.93 4.45 5.93 4.45 4.45 5.93 4.45 5.93 3.71"/>\n\t\t\t<path d="M7.2,6.67a4,4,0,0,0,1-2.59A4.08,4.08,0,1,0,4.07,8.15h0a4,4,0,0,0,2.59-1L9.48,10,10,9.48Zm-3.12.77A3.34,3.34,0,1,1,7.41,4.08,3.34,3.34,0,0,1,4.08,7.44Z"/>\n\t\t</svg>'},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("circle.node").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0);var i=t.model.getHierarchyLevel(),o=i>2&&!r.classed("focal"),a=Dd(t.model.getOptions(),"canvasZoom","enabled"),s=!1;if(!o){var u=[],l=[],c=null;if(n.children){n.depth>1&&a&&(s=!0,r.classed("clickable",!0)),u=n.children.map((function(e){if(null!==e)return"number"===typeof e.data.value?{label:e.data.name,value:e.data.value}:{label:e.data.name,labelIcon:a&&i<=2?t.getZoomIcon():null,value:e.value}}));var h=t.model.getOptions();l=[{label:tl(h,"tooltip.totalLabel")||"Total",value:n.value,bold:!0}],t.highlightChildren(n.children)}else c=n.value;var f=getComputedStyle(this,null).getPropertyValue("fill");t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:XR([{color:f,label:n.data.name,labelIcon:s&&a&&i<=2?t.getZoomIcon():null,value:c}],u,l)})}t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEOVER,{event:e,element:r,datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),n.children&&t.unhighlightChildren(n.children),t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})})).on("click",(function(e,n){var r=eb(this),i=r.classed("non-focal"),o=Dd(t.model.getOptions(),"canvasZoom","enabled");if(o&&t.model.getHierarchyLevel()>2){var a=t.parent.selectAll("circle.node"),s=eb(t.services.domUtils.getMainContainer());s.classed("zoomed-in",!1),t.focal=null,t.model.updateHierarchyLevel(2),t.services.canvasZoom.zoomOut(a,mt)}else if(2===n.depth&&n.children&&!i&&o){a=t.parent.selectAll("circle.node"),s=eb(t.services.domUtils.getMainContainer());s.classed("zoomed-in",!0),t.focal=n,t.model.updateHierarchyLevel(3),t.services.canvasZoom.zoomIn(n,a,mt),e.stopPropagation()}t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_CLICK,{event:e,element:r,datum:n})}))},e.prototype.destroy=function(){this.parent.selectAll("circle.node").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("click",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),this.removeBackgroundListeners()},e}(DS),QR=n("2a60"),JR=n.n(QR),tI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="wordcloud",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("text.word").transition("legend-hover-wordcloud").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-wordcloud"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("text.word").transition("legend-mouseout-wordcloud").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-wordcloud"})})).attr("opacity",1)},e}return tI(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){void 0===t&&(t=!0);var e=this,n=this.getComponentContainer().attr("width","100%").attr("height","100%"),r=this.model.getDisplayData(),i=this.getFontSizeScale(r),o=this.getOptions(),a=o.wordCloud,s=a.fontSizeMapsTo,u=a.wordMapsTo,l=o.data.groupMapsTo,c=sb.getSVGElementSize(n,{useAttrs:!0}),h=c.width,f=c.height;if(0!==h&&0!==f){var p=JR()().size([h,f]).words(r.map((function(t){var e,n=t[s];if("number"!==typeof t[s])throw Error("Badly formatted WordCloud data. `value` should only be an integer or float");return e={},e[l]=t[l],e.text=t[u],e.size=n,e.value=n,e}))).padding(5).rotate(0).fontSize((function(t){return i(t.size)})).on("end",d);p.start(),this.addEventListeners()}function d(r){var i=sb.appendOrSelect(n,"g.words");i.attr("transform","translate("+p.size()[0]/2+", "+p.size()[1]/2+")");var o=i.selectAll("text").data(r,(function(t){return t[l]+"-"+t.text}));o.exit().attr("opacity",0).remove();var a=o.enter().append("text").attr("opacity",0);a.merge(o).style("font-size",(function(t){return t.size+"px"})).text((function(t){return t.text})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[l],originalClassName:"word "+(t.size>32?"light":"")})})).style("fill",(function(t){return e.model.getFillColor(t[l],t.text,t)})).attr("text-anchor","middle").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"wordcloud-text-update-enter",animate:t})})).attr("transform",(function(t){return"translate("+t.x+", "+t.y+")"})).attr("opacity",1)}},e.prototype.getFontSizeScale=function(t){var e=this.getOptions(),n=e.wordCloud.fontSizeMapsTo,r=t.map((function(t){return t[n]})).filter((function(t){return t})),i=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),o=r.length>0,a=o?Xv(r):[1,1];return BE().domain(a).range(o?e.wordCloud.fontSizeRange(i,t):[4,4])},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this,r=Te((function(t){var e=n.parent.selectAll("text.word").transition("wordcloud-word-mouse-highlight").call((function(t){return n.services.transitions.setupTransition({transition:t,name:"wordcloud-word-mouse-highlight"})}));null===t?e.attr("opacity",1):e.attr("opacity",(function(){return t===this?1:.3}))}),6);this.parent.selectAll("text.word").on("mouseover",(function(i,o){var a=this;r(a),n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEOVER,{event:i,element:eb(this),datum:o}),n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:t.tooltip.wordLabel,value:o.text},{label:t.tooltip.valueLabel,value:o.value},{label:t.tooltip.groupLabel,value:o[e],class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:o[e]})}]})})).on("mousemove",(function(t,e){var r=eb(this);n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEMOVE,{element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.WordCloud.WORD_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var i=eb(this);r(null),n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEOUT,{event:t,element:i,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e}(DS);function nI(t,e){let n=0;if(void 0===e)for(let r of t)(r=+r)&&(n+=r);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&(n+=i)}return n}function rI(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n<r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function iI(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n>r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function oI(t){return t.depth}function aI(t,e){return e-1-t.height}function sI(t,e){return t.sourceLinks.length?t.depth:e-1}function uI(t){return function(){return t}}function lI(t,e){return hI(t.source,e.source)||t.index-e.index}function cI(t,e){return hI(t.target,e.target)||t.index-e.index}function hI(t,e){return t.y0-e.y0}function fI(t){return t.value}function pI(t){return t.index}function dI(t){return t.nodes}function vI(t){return t.links}function gI(t,e){const n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function mI({nodes:t}){for(const e of t){let t=e.y0,n=t;for(const r of e.sourceLinks)r.y0=t+r.width/2,t+=r.width;for(const r of e.targetLinks)r.y1=n+r.width/2,n+=r.width}}function yI(){let t,e,n,r=0,i=0,o=1,a=1,s=24,u=8,l=pI,c=sI,h=dI,f=vI,p=6;function d(){const t={nodes:h.apply(null,arguments),links:f.apply(null,arguments)};return v(t),g(t),m(t),y(t),w(t),mI(t),t}function v({nodes:t,links:e}){for(const[n,i]of t.entries())i.index=n,i.sourceLinks=[],i.targetLinks=[];const r=new Map(t.map((e,n)=>[l(e,n,t),e]));for(const[n,i]of e.entries()){i.index=n;let{source:t,target:e}=i;"object"!==typeof t&&(t=i.source=gI(r,t)),"object"!==typeof e&&(e=i.target=gI(r,e)),t.sourceLinks.push(i),e.targetLinks.push(i)}if(null!=n)for(const{sourceLinks:i,targetLinks:o}of t)i.sort(n),o.sort(n)}function g({nodes:t}){for(const e of t)e.value=void 0===e.fixedValue?Math.max(nI(e.sourceLinks,fI),nI(e.targetLinks,fI)):e.fixedValue}function m({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;while(n.size){for(const t of n){t.depth=i;for(const{target:e}of t.sourceLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}function y({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;while(n.size){for(const t of n){t.height=i;for(const{source:e}of t.targetLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}function _({nodes:t}){const n=rI(t,t=>t.depth)+1,i=(o-r-s)/(n-1),a=new Array(n);for(const e of t){const t=Math.max(0,Math.min(n-1,Math.floor(c.call(null,e,n))));e.layer=t,e.x0=r+t*i,e.x1=e.x0+s,a[t]?a[t].push(e):a[t]=[e]}if(e)for(const r of a)r.sort(e);return a}function b(e){const n=iI(e,e=>(a-i-(e.length-1)*t)/nI(e,fI));for(const r of e){let e=i;for(const i of r){i.y0=e,i.y1=e+i.value*n,e=i.y1+t;for(const t of i.sourceLinks)t.width=t.value*n}e=(a-e+t)/(r.length+1);for(let t=0;t<r.length;++t){const n=r[t];n.y0+=e*(t+1),n.y1+=e*(t+1)}C(r)}}function w(e){const n=_(e);t=Math.min(u,(a-i)/(rI(n,t=>t.length)-1)),b(n);for(let t=0;t<p;++t){const e=Math.pow(.99,t),r=Math.max(1-e,(t+1)/p);x(n,e,r),O(n,e,r)}}function O(t,n,r){for(let i=1,o=t.length;i<o;++i){const o=t[i];for(const t of o){let e=0,r=0;for(const{source:n,value:o}of t.targetLinks){let i=o*(t.layer-n.layer);e+=A(n,t)*i,r+=i}if(!(r>0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,M(t)}void 0===e&&o.sort(hI),E(o,r)}}function x(t,n,r){for(let i=t.length,o=i-2;o>=0;--o){const i=t[o];for(const t of i){let e=0,r=0;for(const{target:n,value:o}of t.sourceLinks){let i=o*(n.layer-t.layer);e+=L(t,n)*i,r+=i}if(!(r>0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,M(t)}void 0===e&&i.sort(hI),E(i,r)}}function E(e,n){const r=e.length>>1,o=e[r];S(e,o.y0-t,r-1,n),T(e,o.y1+t,r+1,n),S(e,a,e.length-1,n),T(e,i,0,n)}function T(e,n,r,i){for(;r<e.length;++r){const o=e[r],a=(n-o.y0)*i;a>1e-6&&(o.y0+=a,o.y1+=a),n=o.y1+t}}function S(e,n,r,i){for(;r>=0;--r){const o=e[r],a=(o.y1-n)*i;a>1e-6&&(o.y0-=a,o.y1-=a),n=o.y0-t}}function M({sourceLinks:t,targetLinks:e}){if(void 0===n){for(const{source:{sourceLinks:t}}of e)t.sort(cI);for(const{target:{targetLinks:e}}of t)e.sort(lI)}}function C(t){if(void 0===n)for(const{sourceLinks:e,targetLinks:n}of t)e.sort(cI),n.sort(lI)}function A(e,n){let r=e.y0-(e.sourceLinks.length-1)*t/2;for(const{target:i,width:o}of e.sourceLinks){if(i===n)break;r+=o+t}for(const{source:t,width:i}of n.targetLinks){if(t===e)break;r-=i}return r}function L(e,n){let r=n.y0-(n.targetLinks.length-1)*t/2;for(const{source:i,width:o}of n.targetLinks){if(i===e)break;r+=o+t}for(const{target:t,width:i}of e.sourceLinks){if(t===n)break;r-=i}return r}return d.update=function(t){return mI(t),t},d.nodeId=function(t){return arguments.length?(l="function"===typeof t?t:uI(t),d):l},d.nodeAlign=function(t){return arguments.length?(c="function"===typeof t?t:uI(t),d):c},d.nodeSort=function(t){return arguments.length?(e=t,d):e},d.nodeWidth=function(t){return arguments.length?(s=+t,d):s},d.nodePadding=function(e){return arguments.length?(u=t=+e,d):u},d.nodes=function(t){return arguments.length?(h="function"===typeof t?t:uI(t),d):h},d.links=function(t){return arguments.length?(f="function"===typeof t?t:uI(t),d):f},d.linkSort=function(t){return arguments.length?(n=t,d):n},d.size=function(t){return arguments.length?(r=i=0,o=+t[0],a=+t[1],d):[o-r,a-i]},d.extent=function(t){return arguments.length?(r=+t[0][0],o=+t[1][0],i=+t[0][1],a=+t[1][1],d):[[r,i],[o,a]]},d.iterations=function(t){return arguments.length?(p=+t,d):p},d}var _I=Math.PI,bI=2*_I,wI=1e-6,OI=bI-wI;function xI(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function EI(){return new xI}xI.prototype=EI.prototype={constructor:xI,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+o)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,h=l*l+c*c;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(h>wI)if(Math.abs(c*s-u*l)>wI&&i){var f=n-o,p=r-a,d=s*s+u*u,v=f*f+p*p,g=Math.sqrt(d),m=Math.sqrt(h),y=i*Math.tan((_I-Math.acos((d+h-v)/(2*g*m)))/2),_=y/m,b=y/g;Math.abs(_-1)>wI&&(this._+="L"+(t+_*l)+","+(e+_*c)),this._+="A"+i+","+i+",0,0,"+ +(c*f>l*p)+","+(this._x1=t+b*s)+","+(this._y1=e+b*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,n=+n,o=!!o;var a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,h=o?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>wI||Math.abs(this._y1-l)>wI)&&(this._+="L"+u+","+l),n&&(h<0&&(h=h%bI+bI),h>OI?this._+="A"+n+","+n+",0,1,"+c+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):h>wI&&(this._+="A"+n+","+n+",0,"+ +(h>=_I)+","+c+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var TI=EI,SI=Array.prototype.slice,MI=function(t){return function(){return t}};function CI(t){return t[0]}function AI(t){return t[1]}function LI(t){return t.source}function DI(t){return t.target}function kI(t){var e=LI,n=DI,r=CI,i=AI,o=null;function a(){var a,s=SI.call(arguments),u=e.apply(this,s),l=n.apply(this,s);if(o||(o=a=TI()),t(o,+r.apply(this,(s[0]=u,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),a)return o=null,a+""||null}return a.source=function(t){return arguments.length?(e=t,a):e},a.target=function(t){return arguments.length?(n=t,a):n},a.x=function(t){return arguments.length?(r="function"===typeof t?t:MI(+t),a):r},a.y=function(t){return arguments.length?(i="function"===typeof t?t:MI(+t),a):i},a.context=function(t){return arguments.length?(o=null==t?null:t,a):o},a}function PI(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e=(e+r)/2,n,e,i,r,i)}function RI(){return kI(PI)}function II(t){return[t.source.x1,t.y0]}function NI(t){return[t.target.x0,t.y1]}var jI=function(){return RI().source(II).target(NI)},BI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="alluvial",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e}return BI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0});n.html("");var r=sb.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getOptions(),s=this.model.getDisplayData(),u=Dd(this.getOptions(),"color","gradient","enabled"),l=Mt.minNodePadding;a.alluvial.nodePadding>Mt.minNodePadding&&(l=a.alluvial.nodePadding);var c=Dd(a,"alluvial","nodeAlignment"),h=sI;c===F.LEFT?h=oI:c===F.RIGHT&&(h=aI);var f=yI().nodeId((function(t){return t.name})).nodeWidth(Mt.nodeWidth).nodePadding(l).nodeAlign(h).extent([[2,30],[i-2,o]]);this.graph=f({nodes:a.alluvial.nodes.map((function(t){return Object.assign({},t)})),links:s.map((function(t){return Object.assign({},t)}))}),this.graph.nodes=this.graph.nodes.filter((function(t){return 0!==t.value}));var p={};this.graph.nodes.forEach((function(t){var e,n=t.x0;t.category&&(p[n]=null===(e=t)||void 0===e?void 0:e.category)}));var d=n.append("g").classed("header-arrows",!0).selectAll("g").data(Object.keys(p)).join("g").attr("transform",(function(t){return"translate("+t+", 0)"}));d.append("text").attr("id",(function(t,n){return e.services.domUtils.generateElementIDString("alluvial-category-"+n)})).style("font-size","14px").text((function(t){return p[t]?p[t]:""})).attr("y",20).attr("x",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-category-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width,o=0;return t+o>=i&&(o=4-i),o}));var v=n.append("g").attr("fill","none").selectAll("g").data(this.graph.links);if(v.exit().remove(),u){var g=Dd(this.getOptions(),"color","scale");g&&v.enter().append("linearGradient").attr("id",(function(t){return e.gradient_id+"-link-"+t.index})).attr("gradientUnits","userSpaceOnUse").call((function(t){return t.append("stop").attr("offset","0%").attr("stop-color",(function(t){return g[t.source.name]}))})).call((function(t){return t.append("stop").attr("offset","100%").attr("stop-color",(function(t){return g[t.target.name]}))})),v.exit().remove()}v.enter().append("path").classed("link",!0).attr("d",jI()).attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-line-"+t.index)})).attr("class",(function(t){return a.alluvial.monochrome?e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:0,originalClassName:"link"}):e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t.source.index,originalClassName:"link"})})).style("stroke",(function(t){return u?"url(#"+e.gradient_id+"-link-"+t.index+")":e.model.getFillColor(t.source.name)})).attr("stroke-width",(function(t){return Math.max(1,t.width)})).style("stroke-opacity",Mt.opacity.default).attr("aria-label",(function(t){return t.source.name+" → "+t.target.name+" ("+t.value+(a.alluvial.units?" "+a.alluvial.units:"")+")"}));var m=n.append("g").selectAll("g").data(this.graph.nodes).enter().append("g").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-"+t.index)})).classed("node-group",!0).attr("transform",(function(t){return"translate("+t.x0+", "+t.y0+")"}));m.append("rect").classed("node",!0).attr("height",(function(t){return t.y1-t.y0})).attr("width",(function(t){return t.x1-t.x0})).attr("fill","black");var y=m.append("g").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-title-"+t.index)}));y.append("text").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-text-"+t.index)})).attr("class","node-text").style("font-size","12px").attr("text-anchor","start").attr("fill","white").attr("x",4).attr("dy",13).text((function(t){return t.name+" ("+t.value+")"})).attr("aria-label",(function(t){return t.name+" ("+t.value+")"})),y.append("rect").classed("node-text-bg",!0).attr("width",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-node-text-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width;return i+8})).attr("height",18).attr("stroke-width",2).lower(),y.attr("transform",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-node-text-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width,o=(t.y1-t.y0)/2-9,a=t.x1-t.x0;return t.x1>=i?a-=i+16:a+=4,"translate("+a+", "+o+")"})),this.addLineEventListener(),this.addNodeEventListener()}},e.prototype.addLineEventListener=function(){var t=this.getOptions(),e=this,n=Te((function(t,n){void 0===n&&(n="mouseover");var r=e.parent.selectAll("path.link").transition().call((function(t){return e.services.transitions.setupTransition({transition:t,name:"alluvial-links-mouse-highlight"})}));"mouseout"===n?(eb(t).lower(),r.style("stroke-opacity",Mt.opacity.default)):r.style("stroke-opacity",(function(){return t===this?(eb(this).raise(),Mt.opacity.selected):Mt.opacity.unfocus}))}),33);this.parent.selectAll("path.link").on("mouseover",(function(r,i){var o=eb(this);n(this,"mouseover"),o.classed("link-hovered",!0);var a=getComputedStyle(this).getPropertyValue("stroke");e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEOVER,{event:r,element:o,datum:i}),e.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:i.target.name,value:i.value+(t.alluvial.units?" "+t.alluvial.units:""),color:a,labelIcon:e.getRightArrowIcon()}]})})).on("mousemove",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEMOVE,{event:t,element:eb(this),datum:n}),e.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.LINE_CLICK,{event:t,element:eb(this),datum:n})})).on("mouseout",(function(t,r){var i=eb(this);n(this,"mouseout"),i.classed("link-hovered",!1),e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEOUT,{event:t,element:i,datum:r}),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:t,hoveredElement:i})}))},e.prototype.addNodeEventListener=function(){var t=this,e=this,n=Te((function(n,r){if(void 0===n&&(n=[]),void 0===r&&(r="mouseover"),"mouseout"!==r&&0!==n.length){var i=e.parent.selectAll("path.link").transition().call((function(e){return t.services.transitions.setupTransition({transition:e,name:"alluvial-link-mouse-highlight"})}));i.style("stroke-opacity",(function(t){return n.some((function(e){return e===t.index}))?(eb(this).classed("link-hovered",!0).raise(),Mt.opacity.selected):Mt.opacity.unfocus}))}else e.parent.selectAll("path.link").classed("link-hovered",!1).data(t.graph.links,(function(t){return t.index})).order().style("stroke-opacity",Mt.opacity.default)}),66);e.parent.selectAll(".node-group").on("mouseover",(function(t,r){var i=eb(this),o=[];if(e.traverse({link:"sourceLinks",node:"target"},r,o),e.traverse({link:"targetLinks",node:"source"},r,o),o.length){var a=Md(i.attr("transform"));if(i.attr("transform","translate("+(a.x-2)+", "+a.y+")"),i.classed("node-hovered",!0).selectAll("rect.node").attr("width",8),r.x0-2===0){var s=e.services.domUtils.generateElementIDString("alluvial-node-title-"+r.index),u=e.parent.select("g#"+s),l=Md(u.attr("transform"));u.attr("transform","translate("+(l.x+4)+","+l.y+")")}var c=e.services.domUtils.generateElementIDString("alluvial-node-text-"+r.index);e.parent.select("text#"+c).style("font-weight","bold"),n(o,"mouseover"),e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEOVER,{event:t,element:i,datum:r})}})).on("mousemove",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEMOVE,{event:t,element:eb(this),datum:n}),e.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.NODE_CLICK,{event:t,element:eb(this),datum:n})})).on("mouseout",(function(t,r){var i=eb(this),o=Md(i.attr("transform"));if(i.classed("node-hovered",!1).attr("transform","translate("+(o.x+2)+", "+o.y+")").select("rect.node").attr("width",Mt.nodeWidth),r.x0-2===0){var a=e.services.domUtils.generateElementIDString("alluvial-node-title-"+r.index),s=e.parent.select("g#"+a),u=Md(s.attr("transform"));s.attr("transform","translate("+(u.x-4)+","+u.y+")")}var l=e.services.domUtils.generateElementIDString("alluvial-node-text-"+r.index);e.parent.select("text#"+l).style("font-weight","normal"),n([],"mouseout"),e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEOUT,{event:t,element:i,datum:r}),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e.prototype.traverse=function(t,e,n){var r=this;void 0===n&&(n=[]);var i=e[t.link].map((function(e){return n.push(e.index),e[t.node]}));i.forEach((function(e){return r.traverse(t,e,n)}))},e.prototype.getRightArrowIcon=function(){return'\n\t\t<svg xmlns="http://www.w3.org/2000/svg" class="arrow-right" width="32" height="32" viewBox="0 0 32 32">\n\t\t\t<polygon points="18 6 16.57 7.393 24.15 15 4 15 4 17 24.15 17 16.57 24.573 18 26 28 16 18 6"/>\n\t\t\t<rect width="32" height="32"/>\n\t\t</svg>'},e.prototype.destroy=function(){this.parent.selectAll("path.line,.node-group").on("mouseover",null).on("mousemove",null).on("click",null).on("mouseout",null)},e}(DS),VI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="heatmap",e.renderType=I.SVG,e.matrix={},e.xBandwidth=0,e.yBandwidth=0,e.translationUnits={x:0,y:0},e.handleAxisOnHover=function(t){var n=t.detail,r=n.datum,i=e.model.getUniqueRanges(),o=e.model.getUniqueDomain(),a=e.services.cartesianScales.getDomainLabel(),s=e.services.cartesianScales.getRangeLabel(),u=e.services.cartesianScales.getMainXScale(),l=e.services.cartesianScales.getMainYScale(),c="",h=null,f=null,p=null;void 0!==e.matrix[r]?(c=a,i.forEach((function(t){if("number"===typeof e.matrix[r][t].value){var n=e.matrix[r][t].value;if(null===h)return h=n,f=n,void(p=n);h+=n,f=n<f?n:f,p=n>p?n:p}}))):(c=s,o.forEach((function(t){if("number"===typeof e.matrix[t][r].value){var n=e.matrix[t][r].value;if(null===h)return h=n,f=n,void(p=n);h+=n,f=n<f?n:f,p=n>p?n:p}}))),void 0!==u(r)?e.parent.select("g.multi-cell.column-highlight").classed("highlighter-hidden",!1).attr("transform","translate("+u(r)+", "+Vm(l.range())+")"):void 0!==l(r)&&e.parent.select("g.multi-cell.row-highlight").classed("highlighter-hidden",!1).attr("transform","translate("+Vm(u.range())+","+l(r)+")"),e.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n.event,hoveredElement:eb(t.detail.element),items:[{label:c,value:r,bold:!0},{label:"Min",value:null!==f?f:"-"},{label:"Max",value:null!==p?p:"-"},{label:"Average",value:null!==h?h/o.length:"-"}]})},e.handleAxisMouseOut=function(t){e.parent.selectAll("g.multi-cell").classed("highlighter-hidden",!0),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:t})},e}return VI(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Axis.LABEL_MOUSEOVER,this.handleAxisOnHover),t.addEventListener(ft.Axis.LABEL_MOUSEOUT,this.handleAxisMouseOut),t.addEventListener(ft.Axis.LABEL_FOCUS,this.handleAxisOnHover),t.addEventListener(ft.Axis.LABEL_BLUR,this.handleAxisMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0});n.lower();var r=this.services.cartesianScales;if(this.matrix=this.model.getMatrix(),n.html(""),!Dd(this.getOptions(),"data","loading")){var i=r.getMainXScale(),o=r.getMainYScale(),a=r.getDomainIdentifier(),s=r.getRangeIdentifier(),u=this.model.getUniqueDomain(),l=this.model.getUniqueRanges(),c=this.model.getMatrixAsArray(),h=i.range(),f=o.range();this.xBandwidth=Math.abs((h[1]-h[0])/u.length),this.yBandwidth=Math.abs((f[1]-f[0])/l.length);var p=this.services.domUtils.generateElementIDString("heatmap-pattern-stripes");n.append("defs").append("pattern").attr("id",p).attr("width",3).attr("height",3).attr("patternUnits","userSpaceOnUse").attr("patternTransform","rotate(45)").append("rect").classed("pattern-fill",!0).attr("width",.5).attr("height",8);var d=n.selectAll().data(c).enter().append("g").attr("class",(function(t){return"heat-"+t.index})).classed("cell",!0).attr("transform",(function(t){return"translate("+i(t[a])+", "+o(t[s])+")"})).append("rect").attr("class",(function(t){return e.model.getColorClassName({value:t.value,originalClassName:"heat-"+t.index})})).classed("heat",!0).classed("null-state",(function(t){return-1===t.index||null===t.value})).attr("width",this.xBandwidth).attr("height",this.yBandwidth).style("fill",(function(t){return-1===t.index||null===t.value?"url(#"+p+")":e.model.getFillColor(Number(t.value))})).attr("aria-label",(function(t){return t.value}));this.createOuterBox("g.cell-highlight",this.xBandwidth,this.yBandwidth),this.createOuterBox("g.multi-cell.column-highlight",this.xBandwidth,Math.abs(f[1]-f[0])),this.createOuterBox("g.multi-cell.row-highlight",Math.abs(h[1]-h[0]),this.yBandwidth),this.determineDividerStatus()&&(d.style("stroke-width","1px"),this.parent.select("g.cell-highlight").classed("cell-2",!0)),this.addEventListener()}},e.prototype.createOuterBox=function(t,e,n){var r=sb.appendOrSelect(this.parent,t).classed("shadows",!0).classed("highlighter-hidden",!0);sb.appendOrSelect(r,"line.top").attr("x1",-1).attr("x2",e+1),sb.appendOrSelect(r,"line.left").attr("x1",0).attr("y1",-1).attr("x2",0).attr("y2",n+1),sb.appendOrSelect(r,"line.down").attr("x1",-1).attr("x2",e+1).attr("y1",n).attr("y2",n),sb.appendOrSelect(r,"line.right").attr("x1",e).attr("x2",e).attr("y1",-1).attr("y2",n+1)},e.prototype.determineDividerStatus=function(){var t=Dd(this.getOptions(),"heatmap","divider","state");return t!==lt.OFF&&(t===lt.AUTO&&Ct.minCellDividerDimension<=this.xBandwidth&&Ct.minCellDividerDimension<=this.yBandwidth||t===lt.ON)},e.prototype.addEventListener=function(){var t=this,e=this.services.cartesianScales,n=this.getOptions(),r=tl(n,"tooltip.totalLabel"),i=e.getDomainIdentifier(),o=e.getRangeIdentifier(),a=e.getDomainLabel(),s=e.getRangeLabel();this.parent.selectAll("g.cell").on("mouseover",(function(e,n){var u=eb(this),l=u.select("rect.heat"),c=l.classed("null-state");if(!c){var h=Md(u.attr("transform"));t.parent.select("g.cell-highlight").attr("transform","translate("+(h.x+t.translationUnits.x)+", "+(h.y+t.translationUnits.y)+")").classed("highlighter-hidden",!1),t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEOVER,{event:e,element:l,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,items:[{label:a,value:n[i]},{label:s,value:n[o]},{label:r||"Total",value:n["value"],color:l.style("fill")}]})}})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=r.select("rect.heat"),o=i.classed("null-state");t.parent.select("g.cell-highlight").classed("highlighter-hidden",!0),o||(t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEOUT,{event:e,element:i,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:e,hoveredElement:i}))}))},e.prototype.destroy=function(){this.parent.selectAll("rect.heat").on("mouseover",null).on("mousemove",null).on("click",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleAxisOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleAxisMouseOut)},e}(DS),GI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),zI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="spacer",e}return GI(e,t),e.prototype.render=function(){this.getComponentContainer().style("width",(this.configs.size||At.default.size)+"px").style("height",(this.configs.size||At.default.size)+"px").attr("opacity",0)},e}(DS),FI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),WI=function(t){function e(n,r,i,o){var a=t.call(this,n,r,o)||this;return a.type="layout",a.configs=o,a.children=i,a._instanceID=e.instanceID++,a.init(),a}return FI(e,t),e.prototype.init=function(){this.children.forEach((function(t){t.components.forEach((function(t){t.init()}))}))},e.prototype.getPreferedAndFixedSizeSum=function(){var t=this.parent,e=0;return t.selectAll("div.layout-child-"+this._instanceID).filter((function(t){var e=Dd(t,"growth");return e===Y.PREFERRED||e===Y.FIXED})).each((function(t){e+=t.size})),e},e.prototype.getNumOfStretchChildren=function(){var t=this.parent;return t.selectAll("div.layout-child-"+this._instanceID).filter((function(t){return Dd(t,"growth")===Y.STRETCH})).size()},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.parent,r=sb.getHTMLElementSize(n.node()),i=r.width,o=r.height,a=this.configs.direction===$.ROW||this.configs.direction===$.ROW_REVERSE,s=Dd(this.model.getOptions(),"style","prefix"),u=n.classed(dt+"--"+s+"--layout-row",this.configs.direction===$.ROW).classed(dt+"--"+s+"--layout-row-reverse",this.configs.direction===$.ROW_REVERSE).classed(dt+"--"+s+"--layout-column",this.configs.direction===$.COLUMN).classed(dt+"--"+s+"--layout-column-reverse",this.configs.direction===$.COLUMN_REVERSE).classed(dt+"--"+s+"--layout-alignitems-center",this.configs.alignItems===Z.CENTER).selectAll("div.layout-child-"+this._instanceID).data(this.children,(function(t){return t.id})),l=u.enter().append("div");l.merge(n.selectAll("div.layout-child-"+this._instanceID)).attr("class",(function(t){return"layout-child layout-child-"+e._instanceID+" "+t.id})).each((function(e){var n=this;e.components.forEach((function(r){var i=eb(n),o=Dd(e,"renderType"),a=o===I.SVG;r.setParent(a?sb.appendOrSelect(i,"svg.layout-svg-wrapper").attr("width","100%").attr("height","100%"):i);var s=Dd(e,"growth");s!==Y.PREFERRED&&s!==Y.FIXED||r.render(t)}))})),n.selectAll("div.layout-child-"+this._instanceID).style("height",null).style("width",null).each((function(t){var e=Dd(t,"growth"),n=Dd(t,"renderType"),r=n===I.SVG?sb.getSVGElementSize(eb(this).select("svg.layout-svg-wrapper"),{useBBox:!0}):sb.getHTMLElementSize(this);if(e===Y.PREFERRED){var s=a?r.width:r.height,u=a?i:o;t.size=s/u*100}})),u.exit().remove(),this.children.filter((function(t){var e=Dd(t,"growth");return e===Y.STRETCH})).forEach((function(t,n){t.size=(100-+e.getPreferedAndFixedSizeSum())/+e.getNumOfStretchChildren()}));var c=n.selectAll("div.layout-child-"+this._instanceID).data(this.children,(function(t){return t.id}));a?c.style("width",(function(t){return t.size/100*i+"px"})).style("height","100%"):c.style("height",(function(t){return t.size/100*o+"px"})).style("width","100%"),c.each((function(e,n){e.components.forEach((function(n){var r=Dd(e,"growth");r===Y.STRETCH&&n.render(t)}))}))},e.prototype.setModel=function(e){t.prototype.setModel.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setModel(e)}))}))},e.prototype.setServices=function(e){t.prototype.setServices.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setServices(e)}))}))},e.prototype.destroy=function(){this.children.forEach((function(t){t.components.forEach((function(t){return t.destroy()}))}))},e.instanceID=Math.floor(99999999999*Math.random()),e}(DS),qI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),$I=function(t){function e(e,n,r){var i,o=t.call(this,e,n,r)||this;return o.type="axes",o.renderType=I.SVG,o.truncation=(i={},i[B.LEFT]=!1,i[B.RIGHT]=!1,i[B.TOP]=!1,i[B.BOTTOM]=!1,i),r&&(o.configs=r),o.margins=o.configs.margins,o}return qI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n,r,i=this.configs.position,o=this.getOptions(),s=Dd(o,"axes",i,"visible"),u=this.getComponentContainer(),l=sb.getSVGElementSize(u,{useAttrs:!0}),c=l.width,h=l.height,f=sb.appendOrSelect(u,"g.axis."+i);i===B.BOTTOM||i===B.TOP?(n=this.configs.axes[B.LEFT]?this.margins.left:0,r=this.configs.axes[B.RIGHT]?c-this.margins.right:c):(n=h-this.margins.bottom,r=this.margins.top);var p,d=this.services.cartesianScales.getScaleByPosition(i);switch(this.scaleType===G.LABELS||this.scaleType===G.LABELS_RATIO?d.rangeRound([n,r]):d.range([n,r]),i){case B.LEFT:p=ZS;break;case B.BOTTOM:p=YS;break;case B.RIGHT:p=$S;break;case B.TOP:p=qS;break}f.attr("aria-label",i+" axis");var v=!f.select("g.ticks").empty(),g=sb.appendOrSelect(f,"g.ticks");v||(g.attr("role",a.GRAPHICS_OBJECT+" "+a.GROUP),g.attr("aria-label",i+" ticks"));var m=sb.appendOrSelect(f,"g.ticks.invisible").style("opacity","0").style("pointer-events","none").attr("aria-hidden",!0).attr("aria-label","invisible "+i+" ticks"),y=Dd(o,"axes",i),_=this.scaleType===G.TIME||y.scaleType===G.TIME,b=i===B.LEFT||i===B.RIGHT,w=this.model.get("zoomDomain");if(w&&_&&!b&&d.domain(w),s){var O=Dd(y,"scaleType"),x=Dd(o,"data","loading"),E=Dd(y,"ticks","number"),T=Dd(y,"ticks","values"),S=Dd(y,"truncation","type"),M=Dd(y,"truncation","threshold"),C=Dd(y,"truncation","numCharacter"),A=null!==E,L=Dd(o,"timeScale"),D=sb.appendOrSelect(m,"g.tick"),k=sb.appendOrSelect(D,"text").text("0"),P=sb.getSVGElementSize(k.node(),{useBBox:!0}).height;D.remove();var R,I=this.scaleType||y.scaleType||G.LINEAR,N=p(d).tickSizeOuter(0);if(d.ticks){var j=void 0;if(A?j=E:(j=gt.ticks.number,b&&(j=this.getNumberOfFittingTicks(h,P,gt.ticks.verticalSpaceRatio))),1===d.ticks().length&&0===d.ticks()[0]&&(j=0),N.ticks(j),_)if(d.ticks(j).length){var U=Dd(o,"timeScale","addSpaceOnEdges"),H=Dd(o,"axes",i,"domain"),z=void 0,F=d.copy();U&&!H&&F.nice(j),z=F.ticks(j),U&&z.length>2&&!H&&(z.splice(z.length-1,1),z.splice(0,1)),N.tickValues(z)}else N.tickValues([])}var W=Dd(y,"ticks","formatter");if(_){var q=$m(N.tickValues());R=null===W?function(t,e){return zm(t,e,N.tickValues(),q,L)}:function(t,e){var n=zm(t,e,N.tickValues(),q,L);return W(t,e,n)}}else null===W?I===G.LINEAR&&(R=function(t){return t.toLocaleString()}):R=W;N.tickFormat(R);var $,Y=this.services.cartesianScales.getScaleByPosition(i).domain(),Z=Y[0],X=Y[1];if(T){if(_)T.forEach((function(t,e){void 0===t.getTime&&(T[e]=new Date(t))})),$=T.filter((function(t){var e=t.getTime();return e>=new Date(Z).getTime()&&e<=new Date(X).getTime()}));else if(O===G.LABELS){var K=this.services.cartesianScales.getScaleByPosition(i).domain();$=T.filter((function(t){return K.includes(t)}))}else $=T.filter((function(t){return t>=Z&&t<=X}));N.tickValues($)}switch(i){case B.LEFT:g.attr("transform","translate("+this.margins.left+", 0)");break;case B.BOTTOM:g.attr("transform","translate(0, "+(h-this.margins.bottom)+")");break;case B.RIGHT:g.attr("transform","translate("+(c-this.margins.right)+", 0)");break;case B.TOP:g.attr("transform","translate(0, "+this.margins.top+")");break}var Q=this.model.isDataEmpty();if(y.title){var J=sb.appendOrSelect(f,"text.axis-title").html(Q||x?"":y.title),tt=Dd(y,"titleOrientation");switch(i){case B.LEFT:tt===at.RIGHT?J.attr("transform","rotate(90)").attr("y",0).attr("x",d.range()[0]/2).attr("dy","-0.5em").style("text-anchor","middle"):J.attr("transform","rotate(-90)").attr("y",0).attr("x",-d.range()[0]/2).attr("dy","0.75em").style("text-anchor","middle");break;case B.BOTTOM:J.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+(h+4)+")").style("text-anchor","middle");break;case B.RIGHT:tt===at.LEFT?J.attr("transform","rotate(-90)").attr("y",c).attr("x",-d.range()[0]/2).style("text-anchor","middle"):J.attr("transform","rotate(90)").attr("y",-c).attr("x",d.range()[0]/2).attr("dy","0.75em").style("text-anchor","middle");break;case B.TOP:var et=sb.getSVGElementSize(J,{useBBox:!0}).height;J.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+et/2+")").style("text-anchor","middle");break}}if(_){var nt=$m(N.tickValues()),it=L.showDayName,ot=g;t&&(g=g.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"axis-update",animate:t})}))),g=g.call(N);var st=ot.selectAll(".tick").data(N.tickValues(),d).order().select("text");st.style("font-weight",(function(t,e){return Gm(t,e,N.tickValues(),nt,it)?"bold":"normal"}))}else g=t&&v?g.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"axis-update",animate:t})})).call(N):g.call(N);if(m.call(N),i===B.BOTTOM||i===B.TOP){var ut=!1,lt=Dd(y,"ticks","rotation");if(lt===rt.ALWAYS)ut=!0;else if(lt===rt.NEVER)ut=!1;else if(!lt||lt===rt.AUTO)if(d.step){var ct=m.selectAll("g.tick text").nodes();ut=ct.some((function(t){return sb.getSVGElementSize(t,{useBBox:!0}).width>=d.step()}))}else{ut=!1;var ht,ft=m.append("text").text("A"),pt=sb.getSVGElementSize(ft.node(),{useBBox:!0}).width;m.selectAll("g.tick").each((function(){var t=eb(this),e=parseFloat(Dd(Sd(this),"tx"));null!==e&&ht+t.text().length*pt*.8>=e&&(ut=!0),ht=e})),ft.remove()}ut?(A||(N.ticks(this.getNumberOfFittingTicks(c,P,gt.ticks.horizontalSpaceRatio)),m.call(N),g.call(N)),f.selectAll("g.ticks g.tick text").attr("transform","rotate(-45)").attr("text-anchor",i===B.TOP?"start":"end")):f.selectAll("g.ticks g.tick text").attr("transform",null).attr("text-anchor",null)}if(x?f.attr("opacity",0):f.attr("opacity",1),g.selectAll("g.tick").attr("aria-label",(function(t){return t})),m.selectAll("g.tick").attr("aria-label",(function(t){return t})),S!==V.NONE&&O===G.LABELS&&!T){var dt=this.services.cartesianScales.getScaleDomain(i);if(dt.length>0){var vt=u.select("g.axis."+i+" g.ticks g.tick").html();f.selectAll("g.ticks g.tick").html(vt);var mt=this;f.selectAll("g.tick text").data(dt).text((function(t){return t.length>M?(mt.truncation[i]=!0,Ad(t,S,C)):t})),this.getInvisibleAxisRef().selectAll("g.tick text").data(dt).text((function(t){return t.length>M?Ad(t,S,C):t})),f.selectAll("g.ticks").html(this.getInvisibleAxisRef().html()),f.selectAll("g.tick text").data(dt)}}this.addEventListeners()}else g.attr("aria-hidden",!0)},e.prototype.addEventListeners=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e),r=this.getOptions(),i=Dd(r,"axes",e),o=Dd(i,"scaleType"),a=Dd(i,"truncation","threshold"),s=this;n.selectAll("g.tick text").on("mouseover",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOVER,{event:t,element:eb(this),datum:e}),o===G.LABELS&&e.length>a&&s.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:eb(this),content:e})})).on("mousemove",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEMOVE,{event:t,element:eb(this),datum:e}),o===G.LABELS&&e.length>a&&s.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOUT,{event:t,element:eb(this),datum:e}),o===G.LABELS&&s.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e.prototype.getInvisibleAxisRef=function(){var t=this.configs.position;return this.getComponentContainer().select("g.axis."+t+" g.ticks.invisible")},e.prototype.getTitleRef=function(){var t=this.configs.position;return this.getComponentContainer().select("g.axis."+t+" text.axis-title")},e.prototype.getNumberOfFittingTicks=function(t,e,n){var r=Math.floor(t/(e*n));return aa(r,2,gt.ticks.number)},e.prototype.destroy=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e);n.selectAll("g.tick text").on("mouseover",null).on("mousemove",null).on("mouseout",null)},e}(DS),YI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ZI=function(){return ZI=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},ZI.apply(this,arguments)},XI=function(t){function e(e,n,r){return t.call(this,e,n,r)||this}return YI(e,t),e.prototype.render=function(e){void 0===e&&(e=!0),t.prototype.render.call(this,e),t.prototype.destroy.call(this);var n=this.configs.position,r=this.getComponentContainer(),i=sb.appendOrSelect(r,"g.axis."+n),o=this;i.selectAll("g.tick").each((function(t,e){var r=eb(this);r.classed("tick-hover",!0).attr("tabindex",0===e?0:-1);var i=r.select("text"),a=sb.getSVGElementSize(i,{useBBox:!0}),s=a.width,u=a.height,l=sb.appendOrSelect(r,"rect.axis-holder"),c=0,h=0;switch(n){case B.LEFT:c=-s+Number(i.attr("x")),h=-u/2;break;case B.RIGHT:c=Math.abs(Number(i.attr("x"))),h=-u/2;break;case B.TOP:c=-s/2,h=-u+Number(i.attr("y"))/2,o.truncation[n]&&(c=0,l.attr("transform","rotate(-45)"));break;case B.BOTTOM:c=-s/2,h=u/2-2,o.truncation[n]&&(c=-s,l.attr("transform","rotate(-45)"));break}l.attr("x",c-gt.hover.rectanglePadding).attr("y",h).attr("width",s+2*gt.hover.rectanglePadding).attr("height",u).lower()})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e),r=this.getOptions(),i=Dd(r,"axes",e),o=Dd(i,"scaleType"),a=Dd(i,"truncation","threshold"),s=this;n.selectAll("g.tick.tick-hover").on("mouseover",(function(t){var e=eb(this).select("text"),n=e.datum();s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOVER,{event:t,element:e,datum:n}),o===G.LABELS&&n.length>a&&s.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,element:e,datum:n})})).on("mousemove",(function(t){var e=eb(this).select("text"),n=e.datum();s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEMOVE,{event:t,element:e,datum:n}),s.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_CLICK,{event:t,element:eb(this).select("text"),datum:eb(this).select("text").datum()})})).on("mouseout",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOUT,{event:t,element:eb(this).select("text"),datum:eb(this).select("text").datum()}),o===G.LABELS&&s.services.events.dispatchEvent(ft.Tooltip.HIDE)})).on("focus",(function(t){var e={clientX:0,clientY:0};if(t.target){t.target.focus();var n=t.target.getBoundingClientRect();e.clientX=n.x,e.clientY=n.y}s.services.events.dispatchEvent(ft.Axis.LABEL_FOCUS,{event:ZI(ZI({},t),e),element:eb(this),datum:eb(this).select("text").datum()})})).on("blur",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_BLUR,{event:t,element:eb(this),datum:eb(this).select("text").datum()})})).on("keydown",(function(t){t.key&&"Escape"===t.key&&(s.services.events.dispatchEvent(ft.Tooltip.HIDE),s.services.events.dispatchEvent(ft.Axis.LABEL_BLUR,{event:t,element:eb(this),datum:eb(this).select("text").datum()})),e===B.LEFT||e===B.RIGHT?t.key&&"ArrowUp"===t.key?s.goNext(this,t):t.key&&"ArrowDown"===t.key&&s.goPrevious(this,t):t.key&&"ArrowLeft"===t.key?s.goPrevious(this,t):t.key&&"ArrowRight"===t.key&&s.goNext(this,t)}))},e.prototype.goNext=function(t,e){t.nextElementSibling&&"path"!==t.nextElementSibling.tagName&&t.nextElementSibling.dispatchEvent(new Event("focus")),e.preventDefault()},e.prototype.goPrevious=function(t,e){t.previousElementSibling&&"path"!==t.previousElementSibling.tagName&&t.previousElementSibling.dispatchEvent(new Event("focus")),e.preventDefault()},e.prototype.destroy=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e);n.selectAll("g.tick.tick-hover").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("focus",null).on("blur",null)},e}($I),KI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="2D-axes",e.renderType=I.SVG,e.children={},e.thresholds=[],e.margins={top:0,right:0,bottom:0,left:0},e}return KI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n={},r=Object.keys(B),i=Dd(this.getOptions(),"axes");r.forEach((function(t){var e=i[B[t]];e&&(n[B[t]]=!0)})),this.configs.axes=n,r.forEach((function(t){var n=B[t];if(e.configs.axes[n]&&!e.children[n]){var r={position:n,axes:e.configs.axes,margins:e.margins},i=e.model.axisFlavor===ct.DEFAULT?new $I(e.model,e.services,r):new XI(e.model,e.services,r);i.setModel(e.model),i.setServices(e.services),i.setParent(e.parent),e.children[n]=i}})),Object.keys(this.children).forEach((function(n){var r=e.children[n];r.render(t)}));var o={};Object.keys(this.children).forEach((function(t){var n,r=e.children[t],i=r.configs.position,a=r.getInvisibleAxisRef(),s=sb.getSVGElementSize(a,{useBBox:!0}),u=s.width,l=s.height;switch(r.getTitleRef().empty()?n=0:(n=sb.getSVGElementSize(r.getTitleRef(),{useBBox:!0}).height,i!==B.LEFT&&i!==B.RIGHT||(n+=5)),i){case B.TOP:o.top=l+n;break;case B.BOTTOM:o.bottom=l+n;break;case B.LEFT:o.left=u+n;break;case B.RIGHT:o.right=u+n;break}})),this.services.events.dispatchEvent(ft.Axis.RENDER_COMPLETE);var a=Object.keys(o).some((function(t){return e.margins[t]!==o[t]}));a&&(this.margins=Object.assign(this.margins,o),this.model.set({axesMargins:this.margins},{skipUpdate:!0}),this.services.events.dispatchEvent(ft.ZoomBar.UPDATE),Object.keys(this.children).forEach((function(t){var n=e.children[t];n.margins=e.margins})),this.render(!0))},e}(DS),JI={value:()=>{}};function tN(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new eN(r)}function eN(t){this._=t}function nN(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function rN(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function iN(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=JI,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}eN.prototype=tN.prototype={constructor:eN,on:function(t,e){var n,r=this._,i=nN(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!==typeof e)throw new Error("invalid callback: "+e);while(++o<a)if(n=(t=i[o]).type)r[n]=iN(r[n],t.name,e);else if(null==e)for(n in r)r[n]=iN(r[n],t.name,null);return this}while(++o<a)if((n=(t=i[o]).type)&&(n=rN(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new eN(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(r=this._[t],o=0,n=r.length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var oN=tN;const aN={capture:!0,passive:!1};var sN=function(t){t.preventDefault(),t.stopImmediatePropagation()},uN=function(t){var e=t.document.documentElement,n=eb(t).on("dragstart.drag",sN,aN);"onselectstart"in e?n.on("selectstart.drag",sN,aN):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")};function lN(t,e){var n=t.document.documentElement,r=eb(t).on("dragstart.drag",null);e&&(r.on("click.drag",sN,aN),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}var cN,hN,fN=0,pN=0,dN=0,vN=1e3,gN=0,mN=0,yN=0,_N="object"===typeof performance&&performance.now?performance:Date,bN="object"===typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function wN(){return mN||(bN(ON),mN=_N.now()+yN)}function ON(){mN=0}function xN(){this._call=this._time=this._next=null}function EN(t,e,n){var r=new xN;return r.restart(t,e,n),r}function TN(){wN(),++fN;var t,e=cN;while(e)(t=mN-e._time)>=0&&e._call.call(void 0,t),e=e._next;--fN}function SN(){mN=(gN=_N.now())+yN,fN=pN=0;try{TN()}finally{fN=0,CN(),mN=0}}function MN(){var t=_N.now(),e=t-gN;e>vN&&(yN-=e,gN=t)}function CN(){var t,e,n=cN,r=1/0;while(n)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:cN=e);hN=t,AN(r)}function AN(t){if(!fN){pN&&(pN=clearTimeout(pN));var e=t-mN;e>24?(t<1/0&&(pN=setTimeout(SN,t-_N.now()-yN)),dN&&(dN=clearInterval(dN))):(dN||(gN=_N.now(),dN=setInterval(MN,vN)),fN=1,bN(SN))}}xN.prototype=EN.prototype={constructor:xN,restart:function(t,e,n){if("function"!==typeof t)throw new TypeError("callback is not a function");n=(null==n?wN():+n)+(null==e?0:+e),this._next||hN===this||(hN?hN._next=this:cN=this,hN=this),this._call=t,this._time=n,AN()},stop:function(){this._call&&(this._call=null,this._time=1/0,AN())}};var LN=function(t,e,n){var r=new xN;return e=null==e?0:+e,r.restart(n=>{r.stop(),t(n+e)},e,n),r},DN=oN("start","end","cancel","interrupt"),kN=[],PN=0,RN=1,IN=2,NN=3,jN=4,BN=5,UN=6,VN=function(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};FN(t,n,{name:e,index:r,group:i,on:DN,tween:kN,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:PN})};function HN(t,e){var n=zN(t,e);if(n.state>PN)throw new Error("too late; already scheduled");return n}function GN(t,e){var n=zN(t,e);if(n.state>NN)throw new Error("too late; already running");return n}function zN(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function FN(t,e,n){var r,i=t.__transition;function o(t){n.state=RN,n.timer.restart(a,n.delay,n.time),n.delay<=t&&a(t-n.delay)}function a(o){var l,c,h,f;if(n.state!==RN)return u();for(l in i)if(f=i[l],f.name===n.name){if(f.state===NN)return LN(a);f.state===jN?(f.state=UN,f.timer.stop(),f.on.call("interrupt",t,t.__data__,f.index,f.group),delete i[l]):+l<e&&(f.state=UN,f.timer.stop(),f.on.call("cancel",t,t.__data__,f.index,f.group),delete i[l])}if(LN((function(){n.state===NN&&(n.state=jN,n.timer.restart(s,n.delay,n.time),s(o))})),n.state=IN,n.on.call("start",t,t.__data__,n.index,n.group),n.state===IN){for(n.state=NN,r=new Array(h=n.tween.length),l=0,c=-1;l<h;++l)(f=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=f);r.length=c+1}}function s(e){var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(u),n.state=BN,1),o=-1,a=r.length;while(++o<a)r[o].call(t,i);n.state===BN&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){for(var r in n.state=UN,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=EN(o,0,n.time)}var WN,qN=function(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>IN&&n.state<BN,n.state=UN,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}},$N=function(t){return this.each((function(){qN(this,t)}))},YN=180/Math.PI,ZN={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},XN=function(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*YN,skewX:Math.atan(u)*YN,scaleX:a,scaleY:s}};function KN(t){const e=new("function"===typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?ZN:XN(e.a,e.b,e.c,e.d,e.e,e.f)}function QN(t){return null==t?ZN:(WN||(WN=document.createElementNS("http://www.w3.org/2000/svg","g")),WN.setAttribute("transform",t),(t=WN.transform.baseVal.consolidate())?(t=t.matrix,XN(t.a,t.b,t.c,t.d,t.e,t.f)):ZN)}function JN(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}function o(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:Ax(t,i)},{i:u-2,x:Ax(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}function a(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:Ax(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}function s(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:Ax(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}function u(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Ax(t,n)},{i:s-2,x:Ax(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}return function(e,n){var r=[],i=[];return e=t(e),n=t(n),o(e.translateX,e.translateY,n.translateX,n.translateY,r,i),a(e.rotate,n.rotate,r,i),s(e.skewX,n.skewX,r,i),u(e.scaleX,e.scaleY,n.scaleX,n.scaleY,r,i),e=n=null,function(t){var e,n=-1,o=i.length;while(++n<o)r[(e=i[n]).i]=e.x(t);return r.join("")}}}var tj=JN(KN,"px, ","px)","deg)"),ej=JN(QN,", ",")",")");function nj(t,e){var n,r;return function(){var i=GN(this,t),o=i.tween;if(o!==n){r=n=o;for(var a=0,s=r.length;a<s;++a)if(r[a].name===e){r=r.slice(),r.splice(a,1);break}}i.tween=r}}function rj(t,e,n){var r,i;if("function"!==typeof n)throw new Error;return function(){var o=GN(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}}var ij=function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=zN(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?nj:rj)(n,t,e))};function oj(t,e,n){var r=t._id;return t.each((function(){var t=GN(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return zN(t,r).value[e]}}var aj=function(t,e){var n;return("number"===typeof e?Ax:e instanceof XO?xx:(n=XO(e))?(e=n,xx):Ix)(t,e)};function sj(t){return function(){this.removeAttribute(t)}}function uj(t){return function(){this.removeAttributeNS(t.space,t.local)}}function lj(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function cj(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function hj(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return a=this.getAttribute(t),s=u+"",a===s?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function fj(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return a=this.getAttributeNS(t.space,t.local),s=u+"",a===s?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}var pj=function(t,e){var n=zy(t),r="transform"===n?ej:aj;return this.attrTween(t,"function"===typeof e?(n.local?fj:hj)(n,r,oj(this,"attr."+t,e)):null==e?(n.local?uj:sj)(n):(n.local?cj:lj)(n,r,e))};function dj(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function vj(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function gj(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&vj(t,i)),n}return i._value=e,i}function mj(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&dj(t,i)),n}return i._value=e,i}var yj=function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!==typeof e)throw new Error;var r=zy(t);return this.tween(n,(r.local?gj:mj)(r,e))};function _j(t,e){return function(){HN(this,t).delay=+e.apply(this,arguments)}}function bj(t,e){return e=+e,function(){HN(this,t).delay=e}}var wj=function(t){var e=this._id;return arguments.length?this.each(("function"===typeof t?_j:bj)(e,t)):zN(this.node(),e).delay};function Oj(t,e){return function(){GN(this,t).duration=+e.apply(this,arguments)}}function xj(t,e){return e=+e,function(){GN(this,t).duration=e}}var Ej=function(t){var e=this._id;return arguments.length?this.each(("function"===typeof t?Oj:xj)(e,t)):zN(this.node(),e).duration};function Tj(t,e){if("function"!==typeof e)throw new Error;return function(){GN(this,t).ease=e}}var Sj=function(t){var e=this._id;return arguments.length?this.each(Tj(e,t)):zN(this.node(),e).ease};function Mj(t,e){return function(){var n=e.apply(this,arguments);if("function"!==typeof n)throw new Error;GN(this,t).ease=n}}var Cj=function(t){if("function"!==typeof t)throw new Error;return this.each(Mj(this._id,t))},Aj=function(t){"function"!==typeof t&&(t=ly(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new iB(r,this._parents,this._name,this._id)},Lj=function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],h=l.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=l[p]||c[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new iB(a,this._parents,this._name,this._id)};function Dj(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}function kj(t,e,n){var r,i,o=Dj(e)?HN:GN;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var Pj=function(t,e){var n=this._id;return arguments.length<2?zN(this.node(),n).on.on(t):this.each(kj(n,t,e))};function Rj(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}var Ij=function(){return this.on("end.remove",Rj(this._id))},Nj=function(t){var e=this._name,n=this._id;"function"!==typeof t&&(t=ny(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,l=r[a],c=l.length,h=o[a]=new Array(c),f=0;f<c;++f)(s=l[f])&&(u=t.call(s,s.__data__,f,l))&&("__data__"in s&&(u.__data__=s.__data__),h[f]=u,VN(h[f],e,n,f,h,zN(s,n)));return new iB(o,this._parents,e,n)},jj=function(t){var e=this._name,n=this._id;"function"!==typeof t&&(t=ay(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,l=r[s],c=l.length,h=0;h<c;++h)if(u=l[h]){for(var f,p=t.call(u,u.__data__,h,l),d=zN(u,n),v=0,g=p.length;v<g;++v)(f=p[v])&&VN(f,e,n,v,p,d);o.push(p),a.push(u)}return new iB(o,a,e,n)},Bj=tb.prototype.constructor,Uj=function(){return new Bj(this._groups,this._parents)};function Vj(t,e){var n,r,i;return function(){var o=n_(this,t),a=(this.style.removeProperty(t),n_(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}function Hj(t){return function(){this.style.removeProperty(t)}}function Gj(t,e,n){var r,i,o=n+"";return function(){var a=n_(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}function zj(t,e,n){var r,i,o;return function(){var a=n_(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=n_(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}function Fj(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=GN(this,t),l=u.on,c=null==u.value[a]?o||(o=Hj(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}var Wj=function(t,e,n){var r="transform"===(t+="")?tj:aj;return null==e?this.styleTween(t,Vj(t,r)).on("end.style."+t,Hj(t)):"function"===typeof e?this.styleTween(t,zj(t,r,oj(this,"style."+t,e))).each(Fj(this._id,t)):this.styleTween(t,Gj(t,r,e),n).on("end.style."+t,null)};function qj(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function $j(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&qj(t,o,n)),r}return o._value=e,o}var Yj=function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!==typeof e)throw new Error;return this.tween(r,$j(t,e,null==n?"":n))};function Zj(t){return function(){this.textContent=t}}function Xj(t){return function(){var e=t(this);this.textContent=null==e?"":e}}var Kj=function(t){return this.tween("text","function"===typeof t?Xj(oj(this,"text",t)):Zj(null==t?"":t+""))};function Qj(t){return function(e){this.textContent=t.call(this,e)}}function Jj(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&Qj(r)),e}return r._value=t,r}var tB=function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!==typeof t)throw new Error;return this.tween(e,Jj(t))},eB=function(){for(var t=this._name,e=this._id,n=aB(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=zN(a,e);VN(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new iB(r,this._parents,t,n)},nB=function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0===--i&&o()}};n.each((function(){var n=GN(this,r),i=n.on;i!==t&&(e=(t=i).copy(),e._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e})),0===i&&o()}))},rB=0;function iB(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function oB(t){return tb().transition(t)}function aB(){return++rB}var sB=tb.prototype;iB.prototype=oB.prototype={constructor:iB,select:Nj,selectAll:jj,selectChild:sB.selectChild,selectChildren:sB.selectChildren,filter:Aj,merge:Lj,selection:Uj,transition:eB,call:sB.call,nodes:sB.nodes,node:sB.node,size:sB.size,empty:sB.empty,each:sB.each,on:Pj,attr:pj,attrTween:yj,style:Wj,styleTween:Yj,text:Kj,textTween:tB,remove:Ij,tween:ij,delay:wj,duration:Ej,ease:Sj,easeVarying:Cj,end:nB,[Symbol.iterator]:sB[Symbol.iterator]};var uB={time:null,delay:0,duration:250,ease:pt};function lB(t,e){var n;while(!(n=t.__transition)||!(n=n[e]))if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}var cB=function(t){var e,n;t instanceof iB?(e=t._id,t=t._name):(e=aB(),(n=uB).time=wN(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&VN(a,t,e,l,s,n||lB(a,e));return new iB(r,this._parents,t,e)};tb.prototype.interrupt=$N,tb.prototype.transition=cB;var hB=t=>()=>t;function fB(t,{sourceEvent:e,target:n,selection:r,mode:i,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function pB(t){t.stopImmediatePropagation()}var dB=function(t){t.preventDefault(),t.stopImmediatePropagation()},vB={name:"drag"},gB={name:"space"},mB={name:"handle"},yB={name:"center"};const{abs:_B,max:bB,min:wB}=Math;function OB(t){return[+t[0],+t[1]]}function xB(t){return[OB(t[0]),OB(t[1])]}var EB={name:"x",handles:["w","e"].map(DB),input:function(t,e){return null==t?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},TB={name:"y",handles:["n","s"].map(DB),input:function(t,e){return null==t?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},SB=(["n","w","e","s","nw","ne","sw","se"].map(DB),{overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"}),MB={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},CB={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},AB={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},LB={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function DB(t){return{type:t}}function kB(t){return!t.ctrlKey&&!t.button}function PB(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function RB(){return navigator.maxTouchPoints||"ontouchstart"in this}function IB(t){while(!t.__brush)if(!(t=t.parentNode))return;return t.__brush}function NB(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function jB(){return BB(EB)}function BB(t){var e,n=PB,r=kB,i=RB,o=!0,a=oN("start","brush","end"),s=6;function u(e){var n=e.property("__brush",v).selectAll(".overlay").data([DB("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",SB.overlay).merge(n).each((function(){var t=IB(this).extent;eb(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([DB("selection")]).enter().append("rect").attr("class","selection").attr("cursor",SB.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var r=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));r.exit().remove(),r.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return SB[t.type]})),e.each(l).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",f).filter(i).on("touchstart.brush",f).on("touchmove.brush",p).on("touchend.brush touchcancel.brush",d).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function l(){var t=eb(this),e=IB(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-s/2:e[0][0]-s/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-s/2:e[0][1]-s/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+s:s})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+s:s}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function c(t,e,n){var r=t.__brush.emitter;return!r||n&&r.clean?new h(t,e,n):r}function h(t,e,n){this.that=t,this.args=e,this.state=t.__brush,this.active=0,this.clean=n}function f(n){if((!e||n.touches)&&r.apply(this,arguments)){var i,a,s,u,h,f,p,d,v,g,m,y=this,_=n.target.__data__.type,b="selection"===(o&&n.metaKey?_="overlay":_)?vB:o&&n.altKey?yB:mB,w=t===TB?null:AB[_],O=t===EB?null:LB[_],x=IB(y),E=x.extent,T=x.selection,S=E[0][0],M=E[0][1],C=E[1][0],A=E[1][1],L=0,D=0,k=w&&O&&o&&n.shiftKey,P=Array.from(n.touches||[n],t=>{const e=t.identifier;return t=wd(t,y),t.point0=t.slice(),t.identifier=e,t});qN(y);var R=c(y,arguments,!0).beforestart();if("overlay"===_){T&&(v=!0);const e=[P[0],P[1]||P[0]];x.selection=T=[[i=t===TB?S:wB(e[0][0],e[1][0]),s=t===EB?M:wB(e[0][1],e[1][1])],[h=t===TB?C:bB(e[0][0],e[1][0]),p=t===EB?A:bB(e[0][1],e[1][1])]],P.length>1&&U(n)}else i=T[0][0],s=T[0][1],h=T[1][0],p=T[1][1];a=i,u=s,f=h,d=p;var I=eb(y).attr("pointer-events","none"),N=I.selectAll(".overlay").attr("cursor",SB[_]);if(n.touches)R.moved=B,R.ended=V;else{var j=eb(n.view).on("mousemove.brush",B,!0).on("mouseup.brush",V,!0);o&&j.on("keydown.brush",H,!0).on("keyup.brush",G,!0),uN(n.view)}l.call(y),R.start(n,b.name)}function B(t){for(const e of t.changedTouches||[t])for(const t of P)t.identifier===e.identifier&&(t.cur=wd(e,y));if(k&&!g&&!m&&1===P.length){const t=P[0];_B(t.cur[0]-t[0])>_B(t.cur[1]-t[1])?m=!0:g=!0}for(const e of P)e.cur&&(e[0]=e.cur[0],e[1]=e.cur[1]);v=!0,dB(t),U(t)}function U(t){const e=P[0],n=e.point0;var r;switch(L=e[0]-n[0],D=e[1]-n[1],b){case gB:case vB:w&&(L=bB(S-i,wB(C-h,L)),a=i+L,f=h+L),O&&(D=bB(M-s,wB(A-p,D)),u=s+D,d=p+D);break;case mB:P[1]?(w&&(a=bB(S,wB(C,P[0][0])),f=bB(S,wB(C,P[1][0])),w=1),O&&(u=bB(M,wB(A,P[0][1])),d=bB(M,wB(A,P[1][1])),O=1)):(w<0?(L=bB(S-i,wB(C-i,L)),a=i+L,f=h):w>0&&(L=bB(S-h,wB(C-h,L)),a=i,f=h+L),O<0?(D=bB(M-s,wB(A-s,D)),u=s+D,d=p):O>0&&(D=bB(M-p,wB(A-p,D)),u=s,d=p+D));break;case yB:w&&(a=bB(S,wB(C,i-L*w)),f=bB(S,wB(C,h+L*w))),O&&(u=bB(M,wB(A,s-D*O)),d=bB(M,wB(A,p+D*O)));break}f<a&&(w*=-1,r=i,i=h,h=r,r=a,a=f,f=r,_ in MB&&N.attr("cursor",SB[_=MB[_]])),d<u&&(O*=-1,r=s,s=p,p=r,r=u,u=d,d=r,_ in CB&&N.attr("cursor",SB[_=CB[_]])),x.selection&&(T=x.selection),g&&(a=T[0][0],f=T[1][0]),m&&(u=T[0][1],d=T[1][1]),T[0][0]===a&&T[0][1]===u&&T[1][0]===f&&T[1][1]===d||(x.selection=[[a,u],[f,d]],l.call(y),R.brush(t,b.name))}function V(t){if(pB(t),t.touches){if(t.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500)}else lN(t.view,v),j.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);I.attr("pointer-events","all"),N.attr("cursor",SB.overlay),x.selection&&(T=x.selection),NB(T)&&(x.selection=null,l.call(y)),R.end(t,b.name)}function H(t){switch(t.keyCode){case 16:k=w&&O;break;case 18:b===mB&&(w&&(h=f-L*w,i=a+L*w),O&&(p=d-D*O,s=u+D*O),b=yB,U(t));break;case 32:b!==mB&&b!==yB||(w<0?h=f-L:w>0&&(i=a-L),O<0?p=d-D:O>0&&(s=u-D),b=gB,N.attr("cursor",SB.selection),U(t));break;default:return}dB(t)}function G(t){switch(t.keyCode){case 16:k&&(g=m=k=!1,U(t));break;case 18:b===yB&&(w<0?h=f:w>0&&(i=a),O<0?p=d:O>0&&(s=u),b=mB,U(t));break;case 32:b===gB&&(t.altKey?(w&&(h=f-L*w,i=a+L*w),O&&(p=d-D*O,s=u+D*O),b=yB):(w<0?h=f:w>0&&(i=a),O<0?p=d:O>0&&(s=u),b=mB),N.attr("cursor",SB[_]),U(t));break;default:return}dB(t)}}function p(t){c(this,arguments).moved(t)}function d(t){c(this,arguments).ended(t)}function v(){var e=this.__brush||{selection:null};return e.extent=xB(n.apply(this,arguments)),e.dim=t,e}return u.move=function(e,n,r){e.tween?e.on("start.brush",(function(t){c(this,arguments).beforestart().start(t)})).on("interrupt.brush end.brush",(function(t){c(this,arguments).end(t)})).tween("brush",(function(){var e=this,r=e.__brush,i=c(e,arguments),o=r.selection,a=t.input("function"===typeof n?n.apply(this,arguments):n,r.extent),s=Nx(o,a);function u(t){r.selection=1===t&&null===a?null:s(t),l.call(e),i.brush()}return null!==o&&null!==a?u:u(1)})):e.each((function(){var e=this,i=arguments,o=e.__brush,a=t.input("function"===typeof n?n.apply(e,i):n,o.extent),s=c(e,i).beforestart();qN(e),o.selection=null===a?null:a,l.call(e),s.start(r).brush(r).end(r)}))},u.clear=function(t,e){u.move(t,null,e)},h.prototype={beforestart:function(){return 1===++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(t,e){return this.starting?(this.starting=!1,this.emit("start",t,e)):this.emit("brush",t),this},brush:function(t,e){return this.emit("brush",t,e),this},end:function(t,e){return 0===--this.active&&(delete this.state.emitter,this.emit("end",t,e)),this},emit:function(e,n,r){var i=eb(this.that).datum();a.call(e,this.that,new fB(e,{sourceEvent:n,target:u,selection:t.output(this.state.selection),mode:r,dispatch:a}),i)}},u.extent=function(t){return arguments.length?(n="function"===typeof t?t:hB(xB(t)),u):n},u.filter=function(t){return arguments.length?(r="function"===typeof t?t:hB(!!t),u):r},u.touchable=function(t){return arguments.length?(i="function"===typeof t?t:hB(!!t),u):i},u.handleSize=function(t){return arguments.length?(s=+t,u):s},u.keyModifiers=function(t){return arguments.length?(o=!!t,u):o},u.on=function(){var t=a.on.apply(a,arguments);return t===a?u:t},u}var UB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),VB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid-brush",e.renderType=I.SVG,e.selectionSelector="rect.selection",e.frontSelectionSelector="rect.frontSelection",e}return UB(e,t),e.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this.parent,i=this.getComponentContainer(),o=sb.appendOrSelect(r,"svg.chart-grid-backdrop"),a=sb.appendOrSelect(o,"g."+this.type),s=sb.appendOrSelect(a,this.selectionSelector),u=sb.getSVGElementSize(o,{useAttrs:!0}),l=u.width,c=u.height,h=this.services.cartesianScales,f=h.getMainXScaleType(),p=h.getMainXScale(),d=p.range(),v=d[0];d[1];i.attr("transform","translate("+v+",0)");var g=sb.appendOrSelect(i,this.frontSelectionSelector);if(p&&f===G.TIME){var m=this.model.get("zoomDomain");void 0===m&&(m=this.services.zoom.getDefaultZoomBarDomain(),m&&this.model.set({zoomDomain:m},{animate:!1}));var y=function(t){for(var n=t[1]-t[0],r="0,"+n.toString(),i=Math.floor(c/e.DASH_LENGTH),o=i*e.DASH_LENGTH,a=0;a<i;a++)r+=","+e.DASH_LENGTH;r+=","+(c-o),i%2===1&&(r+=",0"),r+=","+n.toString(),r+=","+c.toString(),g.attr("stroke-dasharray",r)},_=function(t){var e=t.selection;null!==e&&e[0]!==e[1]&&(g.attr("x",parseFloat(s.attr("x"))+parseFloat(o.attr("x"))).attr("y",s.attr("y")).attr("width",s.attr("width")).attr("height",s.attr("height")).style("cursor","pointer").style("display",null),y(e))},b=function(t,e){var r=Jx().range([0,l]).domain(m),i=[r.invert(t),r.invert(e)];i[0].valueOf()===i[1].valueOf()&&(i=n.services.zoom.getDefaultZoomBarDomain()),m[0].valueOf()===i[0].valueOf()&&m[1].valueOf()===i[1].valueOf()||n.services.zoom.handleDomainChange(i)},w=function(t){var e=t.selection;null!==e&&(b(e[0],e[1]),a.call(O.move,null),g.style("display","none"))},O=jB().extent([[0,0],[l-1,c]]).on("start brush end",_).on("end.brushed",w);a.call(O);var x=this.services.zoom.getZoomRatio();o.on("click",(function(t){if(t.shiftKey){var e=this.services.domUtils.getHolder(),n=wd(a.node(),e)[0],r=n-l*x/2;r<0&&(r=0);var i=n+l*x/2;i>l&&(i=l),b(r,i)}}))}},e.DASH_LENGTH=4,e}(DS),HB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),GB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid",e.renderType=I.SVG,e}return HB(e,t),e.prototype.render=function(t){void 0===t&&(t=!0);var e=Dd(this.getOptions(),"grid","x","enabled"),n=Dd(this.getOptions(),"grid","y","enabled");this.drawBackdrop(e,n),(e||n)&&(e&&(sb.appendOrSelect(this.backdrop,"g.x.grid"),this.drawXGrid(t)),n&&(sb.appendOrSelect(this.backdrop,"g.y.grid"),this.drawYGrid(t)))},e.prototype.drawXGrid=function(t){var e=this,n=this.parent,r=this.backdrop.attr("height"),i=this.services.cartesianScales.getMainXScale(),o=YS(i).tickSizeInner(-r).tickSizeOuter(0),a=Dd(this.getOptions(),"grid","x","alignWithAxisTicks");if(a){var s=this.services.cartesianScales.getDomainAxisPosition(),u=Dd(this.getOptions(),"axes",s,"ticks","values");u&&o.tickValues(u)}else{var l=Dd(this.getOptions(),"grid","x","numberOfTicks");o.ticks(l)}var c=n.select(".x.grid").attr("transform","translate("+-this.backdrop.attr("x")+", "+r+")");t?c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"grid-update",animate:t})})).call(o):c.call(o),this.cleanGrid(c)},e.prototype.drawYGrid=function(t){var e=this,n=this.parent,r=this.backdrop.attr("width"),i=this.services.cartesianScales.getMainYScale(),o=ZS(i).tickSizeInner(-r).tickSizeOuter(0),a=Dd(this.getOptions(),"grid","y","alignWithAxisTicks");if(a){var s=this.services.cartesianScales.getRangeAxisPosition(),u=Dd(this.getOptions(),"axes",s,"ticks","values");u&&o.tickValues(u)}else{var l=Dd(this.getOptions(),"grid","y","numberOfTicks");o.ticks(l)}var c=n.select(".y.grid").attr("transform","translate(0, "+-this.backdrop.attr("y")+")");t?c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"grid-update",animate:t})})).call(o):c.call(o),this.cleanGrid(c)},e.prototype.getGridlineThreshold=function(t){var e,n=this.parent,r=n.selectAll(".x.grid .tick").nodes().sort((function(t,e){return Number(Sd(t).tx)-Number(Sd(e).tx)})),i=-1;if(r.length){r.forEach((function(e,n){t[0]>=+Sd(e).tx&&i++})),e=i+1<r.length?i+1:r.length;var o,a=r[i],s=r[e];if(a)if(s)o=+Sd(s).tx-+Sd(a).tx;else{var u=n.select("rect.chart-grid-backdrop").node(),l=sb.getSVGElementSize(u).width;o=l-+Sd(a).tx}else o=+Sd(s).tx;var c=this.getOptions().tooltip.gridline.threshold;return o*c}},e.prototype.getActiveGridline=function(t){var e=Dd(this.getOptions,"tooltip","gridline","threshold"),n=e||this.getGridlineThreshold(t),r=this.parent,i=r.selectAll(".x.grid .tick").filter((function(){var e=Sd(this),r={min:Number(e.tx)-n,max:Number(e.tx)+n};return r.min<=t[0]&&t[0]<=r.max}));return i},e.prototype.drawBackdrop=function(t,e){var n=this.parent,r=this.services.cartesianScales.getMainXScale(),i=this.services.cartesianScales.getMainYScale(),o=r.range(),a=o[0],s=o[1],u=i.range(),l=u[0],c=u[1];this.backdrop=sb.appendOrSelect(n,"svg.chart-grid-backdrop");var h=sb.appendOrSelect(this.backdrop,t||e?"rect.chart-grid-backdrop.stroked":"rect.chart-grid-backdrop");this.backdrop.merge(h).attr("x",a).attr("y",c).attr("width",Math.abs(s-a)).attr("height",Math.abs(l-c)).lower(),h.attr("width","100%").attr("height","100%")},e.prototype.cleanGrid=function(t){t.selectAll("text").remove(),t.select(".domain").remove()},e}(DS),zB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FB=5;function WB(t,e){return t>e-FB&&t<e+FB}var qB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ruler",e.renderType=I.SVG,e.isXGridEnabled=Dd(e.getOptions(),"grid","x","enabled"),e.isYGridEnabled=Dd(e.getOptions(),"grid","y","enabled"),e.isEventListenerAdded=!1,e}return zB(e,t),e.prototype.render=function(){var t=Dd(this.getOptions(),"ruler","enabled");this.drawBackdrop(),t&&!this.isEventListenerAdded?this.addBackdropEventListeners():!t&&this.isEventListenerAdded&&this.removeBackdropEventListeners()},e.prototype.removeBackdropEventListeners=function(){this.isEventListenerAdded=!1,this.backdrop.on("mousemove mouseover mouseout",null)},e.prototype.formatTooltipData=function(t){return t},e.prototype.showRuler=function(t,e){var n=this,r=e[0],i=e[1],o=this.parent,a=this.services.cartesianScales.getOrientation(),s=this.model.getDisplayData(),u=this.services.cartesianScales.getRangeScale(),l=u.range(),c=l[0],h=l[1],f=a===H.HORIZONTAL?i:r,p=sb.appendOrSelect(o,"g.ruler").attr("aria-label","ruler"),d=sb.appendOrSelect(p,"line.ruler-line"),v=o.selectAll("[role=graphics-symbol]"),g=s.map((function(t){return{domainValue:n.services.cartesianScales.getDomainValue(t),originalData:t}})).filter((function(t){return WB(t.domainValue,f)}));if(this.pointsWithinLine&&g.length===this.pointsWithinLine.length&&g.map((function(t){return t.domainValue})).join()===this.pointsWithinLine.map((function(t){return t.domainValue})).join())return this.pointsWithinLine=g,this.services.events.dispatchEvent(ft.Tooltip.MOVE,{mousePosition:[r,i]});this.pointsWithinLine=g;var m=this.pointsWithinLine.reduce((function(t,e){if(0===t.length)return t.push(e),t;var n=t[0].domainValue,r=Math.abs(f-e.domainValue),i=Math.abs(f-n);return r>i||(r<i?t=[e]:t.push(e)),t}),[]);if(m.length>0){var y=m.map((function(t){return t.originalData})).filter((function(t){var e=n.services.cartesianScales.getRangeIdentifier(t),r=t[e];return null!==r&&void 0!==r})),_=m.map((function(t){return t.domainValue})),b=v.filter((function(t){var e=n.services.cartesianScales.getDomainValue(t);return _.includes(e)}));this.elementsToHighlight&&this.elementsToHighlight.size()>0&&!Gh(this.elementsToHighlight,b)&&this.hideRuler(),b.dispatch("mouseover"),this.elementsToHighlight=b,this.services.events.dispatchEvent(ft.Tooltip.SHOW,{mousePosition:[r,i],hoveredElement:d,data:this.formatTooltipData(y)}),p.attr("opacity",1);var w=m[0];"horizontal"===a?d.attr("x1",h).attr("x2",c).attr("y1",w.domainValue).attr("y2",w.domainValue):d.attr("y1",h).attr("y2",c).attr("x1",w.domainValue).attr("x2",w.domainValue)}else this.hideRuler()},e.prototype.hideRuler=function(){var t=this.parent,e=sb.appendOrSelect(t,"g.ruler"),n=t.selectAll("[role=graphics-symbol]");n.dispatch("mouseout"),this.services.events.dispatchEvent(ft.Tooltip.HIDE),e.attr("opacity",0)},e.prototype.addBackdropEventListeners=function(){this.isEventListenerAdded=!0;var t=this,e=this.services.domUtils.getHolder(),n=this.model.getDisplayData(),r=function(e){var n=wd(e,t.parent.node());t.showRuler(e,n)};if(n.length>100){var i=n.length%50*12.5;r=Ed((function(e){var n=this.mousePosition;t.showRuler(e,n)}),i,e)}this.backdrop.on("mousemove mouseover",r).on("mouseout",this.hideRuler.bind(this))},e.prototype.drawBackdrop=function(){var t=this.parent;this.backdrop=sb.appendOrSelect(t,"svg.chart-grid-backdrop")},e}(DS),$B=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YB=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},ZB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ruler-binned",e.renderType=I.SVG,e}return $B(e,t),e.prototype.showRuler=function(t,e){var n=this,r=e[0],i=e[1],o=this.parent,a=this.model.getOptions(),s=this.services.cartesianScales.getOrientation(),u=this.services.cartesianScales.getRangeScale(),l=u.range(),c=l[0],h=l[1],f=this.services.cartesianScales.getDomainScale(),p=f.invert(s===H.VERTICAL?r:i),d=sb.appendOrSelect(o,"g.ruler").attr("aria-label","ruler"),v=sb.appendOrSelect(d,"line.ruler-line"),g=o.selectAll("[role=graphics-symbol]"),m=g.filter((function(t){if(parseFloat(tl(t,"data.x0"))<=p&&parseFloat(tl(t,"data.x1"))>=p)return!0}));if(m.size()>0){this.elementsToHighlight&&this.elementsToHighlight.size()>0&&!Gh(this.elementsToHighlight,m)&&this.hideRuler(),m.dispatch("mouseover"),this.elementsToHighlight=m;var y=eb(m.nodes()[0]).datum(),_=parseFloat(tl(y,"data.x0")),b=parseFloat(tl(y,"data.x1")),w=this.model.getActiveDataGroupNames(),O=w.reverse().map((function(t){return{label:t,value:tl(y,"data."+t),class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:t})}})).filter((function(t){return 0!==t.value})),x=O.length>0;if(x){this.services.events.dispatchEvent(ft.Tooltip.SHOW,{mousePosition:[r,i],hoveredElement:v,items:YB([{label:tl(a,"bins.rangeLabel")||"Range",value:_+" – "+b}],O,!0===Dd(a,"tooltip","showTotal")?[{label:tl(a,"tooltip.totalLabel")||"Total",value:w.reduce((function(t,e){return t+parseFloat(tl(y,"data."+e))}),0)}]:[])}),d.attr("opacity",1);var E=f((_+b)/2);"horizontal"===s?v.attr("x1",h).attr("x2",c).attr("y1",E).attr("y2",E):v.attr("y1",h).attr("y2",c).attr("x1",E).attr("x2",E)}else this.hideRuler()}else this.hideRuler()},e}(qB),XB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),KB=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return XB(e,t),e.prototype.formatTooltipData=function(t){return t.reverse()},e}(qB),QB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),JB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="toolbar",e.renderType=I.HTML,e}return QB(e,t),e.prototype.init=function(){var t=this,e=function(){return t.updateOverflowMenu(!1)};this.services.events.addEventListener(ft.Toolbar.SHOW_OVERFLOW_MENU,(function(){t.renderOverflowMenu(),document.body.addEventListener("click",e)})),this.services.events.addEventListener(ft.Toolbar.HIDE_OVERFLOW_MENU,(function(){document.body.removeEventListener("click",e)}))},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer().attr("role","toolbar").attr("aria-label","chart-"+this.services.domUtils.getChartID()+" toolbar"),r=Dd(this.getOptions(),"data","loading");if(r)n.html(""),this.overflowMenu=null;else{this.overflowMenu||(this.overflowMenu=n.append("div").attr("class","cds--overflow-menu-options cds--overflow-menu--flip cds--overflow-menu-options cds--overflow-menu--flip").attr("tabindex",-1).html("<ul role='menu'></ul>"));var i=this.getControlConfigs(),o=i.buttonList,a=i.overflowMenuItemList;a&&o.push(this.getOverflowButtonConfig());var s=n.selectAll("div.toolbar-control").data(o,(function(t){return t.id}));s.exit().remove();var u=s.enter().append("div").attr("class","toolbar-control cds--overflow-menu cds--overflow-menu").attr("role","button"),l=this;u.merge(s).classed("disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-label",(function(t){return t.title})).html((function(t){return'\n\t\t\t<button\n\t\t\t\tclass="cds--overflow-menu__trigger cds--overflow-menu__trigger"\n\t\t\t\taria-haspopup="true" aria-expanded="false" id="'+e.services.domUtils.generateElementIDString("control-"+t.id)+'" aria-label="'+t.title+'">\n\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet" xmlns="http://www.w3.org/2000/svg" class="cds--overflow-menu__icon cds--overflow-menu__icon" viewBox="0 0 32 32" aria-hidden="true">\n\t\t\t\t\t'+t.iconSVG.content+"\n\t\t\t\t</svg>\n\t\t\t</button>"})).each((function(t,e){var n=this;eb(this).select("svg").style("will-change","transform").style("width",void 0!==t.iconSVG.width?t.iconSVG.width:"20px").style("height",void 0!==t.iconSVG.height?t.iconSVG.height:"20px"),eb(this).select("button").on("click",(function(e){t.shouldBeDisabled()||l.triggerFunctionAndEvent(t,e,n)})).on("keydown",(function(r){r.key&&"Enter"===r.key||" "===r.key?(r.preventDefault(),l.triggerFunctionAndEvent(t,r,n)):r.key&&"ArrowLeft"===r.key?l.focusOnPreviousEnabledToolbarItem(e):r.key&&"ArrowRight"===r.key&&l.focusOnNextEnabledToolbarItem(e)}))}));this.overflowButton=this.getComponentContainer().select("button.cds--overflow-menu__trigger#"+this.services.domUtils.generateElementIDString("control-toolbar-overflow-menu"))}},e.prototype.renderOverflowMenu=function(){var t=this,e=this.getControlConfigs().overflowMenuItemList,n=this.overflowMenu.select("ul").selectAll("li.cds--overflow-menu-options__option").data(e,(function(t){return Dd(t,"id")}));n.exit().remove();var r=n.enter().append("li").attr("id",(function(e){return t.services.domUtils.generateElementIDString("control-"+e.id)})).attr("class","cds--overflow-menu-options__option cds--overflow-menu-options__option").attr("role","menuitem").attr("tabindex",1);r.append("button").attr("class","cds--overflow-menu-options__btn cds--overflow-menu-options__btn"),r.merge(n).classed("cds--overflow-menu-options__option--disabled",(function(t){return t.shouldBeDisabled()})).classed("cds--overflow-menu-options__option--disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-disabled",(function(t){return t.shouldBeDisabled()})).selectAll("button").text((function(t){return t.text}))},e.prototype.isOverflowMenuOpen=function(){return this.overflowMenu.classed("is-open")},e.prototype.updateOverflowMenu=function(t){this.overflowMenu&&(this.overflowMenu.classed("is-open",t),this.overflowButton&&(this.overflowButton.attr("aria-expanded",t),eb(this.overflowButton.node().parentNode).classed("cds--overflow-menu--open",t).classed("cds--overflow-menu--open",t)),t?this.services.events.dispatchEvent(ft.Toolbar.SHOW_OVERFLOW_MENU):this.services.events.dispatchEvent(ft.Toolbar.HIDE_OVERFLOW_MENU))},e.prototype.focusOnPreviousEnabledToolbarItem=function(t){for(var e=this.getToolbarButtonItems(),n=e.length,r=t-1;r>=0;r--){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n<e.length){var o=eb("button#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)).node();"focus"in o&&o.focus()}},e.prototype.focusOnNextEnabledToolbarItem=function(t){for(var e=this.getToolbarButtonItems(),n=-1,r=t+1;r<e.length;r++){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n>-1){var o=eb("button#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)).node();"focus"in o&&o.focus()}},e.prototype.focusOnPreviousEnabledMenuItem=function(t){for(var e=this.getOverflowMenuItems(),n=e.length,r=t-1;r>=0;r--){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n<e.length){var o=eb("#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)+" button").node();"focus"in o&&o.focus()}},e.prototype.focusOnNextEnabledMenuItem=function(t){for(var e=this.getOverflowMenuItems(),n=-1,r=t+1;r<e.length;r++){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n>-1){var o=eb("#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)+" button").node();"focus"in o&&o.focus()}},e.prototype.toggleOverflowMenu=function(t){var e=this;if(this.isOverflowMenuOpen())this.updateOverflowMenu(!1);else{this.updateOverflowMenu(!0);var n=this,r=this.getOverflowMenuItems();r.forEach((function(r,i){var o=eb("#"+e.services.domUtils.generateElementIDString("control-"+r.id));null!==o&&(o.on("click",(function(){n.triggerFunctionAndEvent(r,t,o.node()),n.updateOverflowMenu(!1)})),o.on("keydown",(function(e){e&&"Enter"===e.key?n.triggerFunctionAndEvent(r,t,o.node()):e&&"ArrowUp"===e.key?n.focusOnPreviousEnabledMenuItem(i):e&&"ArrowDown"===e.key?n.focusOnNextEnabledMenuItem(i):e&&"Escape"===e.key&&n.updateOverflowMenu(!1),e.preventDefault()})))})),n.focusOnNextEnabledMenuItem(-1)}t&&t.stopImmediatePropagation()},e.prototype.triggerFunctionAndEvent=function(t,e,n){"function"===typeof t.shouldBeDisabled&&t.shouldBeDisabled()||("function"===typeof t.clickFunction&&t.clickFunction(e),this.services.events.dispatchEvent(ft.Toolbar.BUTTON_CLICK,{control:t,event:e,element:n}))},e.prototype.getControlConfigs=function(){var t=this,n=Dd(this.getOptions(),"toolbar","numberOfIcons")-1,r=Dd(this.getOptions(),"toolbar","controls"),i=[],o=[],a=[];return r.forEach((function(r){var s=null;r.type===ot.CUSTOM?(null===Dd(r,"id")&&(r.id="toolbar-button-"+e.buttonID++),null===Dd(r,"shouldBeDisabled")&&(r.shouldBeDisabled=function(){return!1}),s=r):s=t.getControlConfigByType(r.type),s&&(s.text=r.text?r.text:r.type,-1!==s.id.indexOf("toolbar-export")?i.push(s):o.length<n?null===Dd(s,"iconSVG","content")?a.push(s):o.push(s):a.push(s))})),a.push.apply(a,i),a.length?{buttonList:o,overflowMenuItemList:a}:{buttonList:o}},e.prototype.getToolbarButtonItems=function(){var t=this.getControlConfigs(),e=t.buttonList,n=t.overflowMenuItemList;return n&&e.push(this.getOverflowButtonConfig()),e||[]},e.prototype.getOverflowMenuItems=function(){var t=this.getControlConfigs().overflowMenuItemList;return t||[]},e.prototype.getOverflowButtonConfig=function(){var t=this;return{id:"toolbar-overflow-menu",title:"More options",shouldBeDisabled:function(){return!1},iconSVG:{content:'<circle cx="16" cy="8" r="2"></circle>\n\t\t\t\t<circle cx="16" cy="16" r="2"></circle>\n\t\t\t\t<circle cx="16" cy="24" r="2"></circle>'},clickFunction:function(e){return t.toggleOverflowMenu(e)}}},e.prototype.getControlConfigByType=function(t){var e,n=this,r=this.services.zoom&&this.services.zoom.isZoomBarEnabled()&&!this.services.zoom.isEmptyState(),i=this.model.getDisplayData();switch(t){case ot.ZOOM_IN:r&&(e={id:"toolbar-zoomIn",title:"Zoom in",shouldBeDisabled:function(){return n.services.zoom.isMinZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.zoomIn()}});break;case ot.ZOOM_OUT:r&&(e={id:"toolbar-zoomOut",title:"Zoom out",shouldBeDisabled:function(){return n.services.zoom.isMaxZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.zoomOut()}});break;case ot.RESET_ZOOM:r&&(e={id:"toolbar-resetZoom",title:"Reset zoom",shouldBeDisabled:function(){return n.services.zoom.isMaxZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.resetZoomDomain()}});break;case ot.MAKE_FULLSCREEN:e={id:"toolbar-makefullscreen",iconSVG:{content:this.getControlIconByType(t),width:"15px",height:"15px"},title:"Make fullscreen",shouldBeDisabled:function(){return!1},clickFunction:function(){n.services.domUtils.toggleFullscreen()}};break;case ot.SHOW_AS_DATATABLE:e={id:"toolbar-showasdatatable",iconSVG:{content:this.getControlIconByType(t)},title:"Show as table",shouldBeDisabled:function(){return 0===i.length},clickFunction:function(){return n.services.events.dispatchEvent(ft.Modal.SHOW)}};break;case ot.EXPORT_CSV:e={id:"toolbar-export-CSV",title:"Export as CSV",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.model.exportToCSV()}};break;case ot.EXPORT_PNG:e={id:"toolbar-export-PNG",title:"Export as PNG",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.domUtils.exportToPNG()}};break;case ot.EXPORT_JPG:e={id:"toolbar-export-JPG",title:"Export as JPG",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.domUtils.exportToJPG()}};break;default:throw Error("Not supported toolbar control type: "+t)}return e},e.prototype.getControlIconByType=function(t){switch(t){case ot.ZOOM_IN:return'<polygon points="19 13 15 13 15 9 13 9 13 13 9 13 9 15 13 15 13 19 15 19 15 15 19 15 19 13"/>\n\t\t\t\t\t\t<path d="M22.45,21A10.87,10.87,0,0,0,25,14,11,11,0,1,0,14,25a10.87,10.87,0,0,0,7-2.55L28.59,30,30,28.59ZM14,23a9,9,0,1,1,9-9A9,9,0,0,1,14,23Z"/>';case ot.ZOOM_OUT:return'<rect x="9" y="13" width="10" height="2"/>\n\t\t\t\t\t\t<path d="M22.45,21A10.87,10.87,0,0,0,25,14,11,11,0,1,0,14,25a10.87,10.87,0,0,0,7-2.55L28.59,30,30,28.59ZM14,23a9,9,0,1,1,9-9A9,9,0,0,1,14,23Z"/>';case ot.RESET_ZOOM:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.MAKE_FULLSCREEN:return'<polygon points="21 2 21 4 26.59 4 17 13.58 18.41 15 28 5.41 28 11 30 11 30 2 21 2"/><polygon points="15 18.42 13.59 17 4 26.59 4 21 2 21 2 30 11 30 11 28 5.41 28 15 18.42"/>';case ot.SHOW_AS_DATATABLE:return'<rect x="4" y="6" width="18" height="2"/><rect x="4" y="12" width="18" height="2"/><rect x="4" y="18" width="18" height="2"/><rect x="4" y="24" width="18" height="2"/><rect x="26" y="6" width="2" height="2"/><rect x="26" y="12" width="2" height="2"/><rect x="26" y="18" width="2" height="2"/><rect x="26" y="24" width="2" height="2"/>';case ot.EXPORT_CSV:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.EXPORT_JPG:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.EXPORT_PNG:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';default:throw Error("Not supported toolbar control type: "+t)}},e.buttonID=0,e}(DS),tU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eU=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zero-line",e.renderType=I.SVG,e}return tU(e,t),e.prototype.render=function(t){var e=this,n=this.services.cartesianScales.getRangeAxisPosition({groups:this.configs.groups}),r=this.services.cartesianScales.getScaleByPosition(n),i=r.domain(),o=i[0],a=i[1],s=o>0&&a<0||o<0&&a>0,u=this.getComponentContainer();if(s){var l=this.services.cartesianScales.getDomainScale().range(),c=l[0],h=l[1],f=+r(0)+.5;f||(f=r.range()[0]);var p=kd({x0:c,x1:h,y0:f,y1:f},this.services.cartesianScales.getOrientation()),d=sb.appendOrSelect(u,"line.domain");d.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"zero-line-update",animate:t})})).attr("y1",p.y0).attr("y2",p.y1).attr("x1",p.x0).attr("x2",p.x1)}else u.selectAll("line.domain").remove()},e}(DS),nU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rU=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zoom-bar",e.renderType=I.SVG,e.MIN_SELECTION_DIFF=9e-10,e.brushSelector="g.zoom-bar-brush",e.clipId="zoomBarClip-"+Math.floor(99999999999*Math.random()),e.brush=jB(),e.highlightStrokeWidth=1,e}return nU(e,t),e.prototype.init=function(){this.services.events.addEventListener(ft.ZoomBar.UPDATE,this.render.bind(this));var t=Dd(this.getOptions(),"zoomBar",B.TOP,"data");this.model.setZoomBarData(t)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=this.services.zoom.isZoomBarLoading(B.TOP),i=this.services.zoom.isZoomBarLocked(B.TOP),o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Dd(this.getOptions(),"axes",B.BOTTOM,"highlights"),s=Pt.height[o],u=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width;if(0!==u){var l=0,c=this.model.get("axesMargins");c&&c.left&&(l=c.left);var h=sb.appendOrSelect(n,"svg.zoom-container").attr("width","100%").attr("height",s).attr("opacity",1);sb.appendOrSelect(n,"rect.zoom-spacer").attr("x",0).attr("y",s).attr("width","100%").attr("height",Pt.spacerHeight).attr("opacity",1).attr("fill","none");if(o===U.GRAPH_VIEW?sb.appendOrSelect(h,"rect.zoom-bg").attr("x",l).attr("y",0).attr("width",u-l).attr("height","100%").classed("zoom-bg-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null):o===U.SLIDER_VIEW&&sb.appendOrSelect(h,"rect.zoom-slider-bg").attr("x",l).attr("y",s/2-1).attr("width",u-l).attr("height",2).classed("zoom-slider-bg-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null),r)this.renderSkeleton(h,l,u);else{var f=this.services.cartesianScales,p=f.getMainXScale(),d=f.getMainYScale(),v=f.getMainXScaleType();if(p&&v===G.TIME){var g=this.services.zoom.getZoomBarData();if(Vh(g)||1===g.length)return;this.xScale=p.copy(),this.yScale=d.copy();var m=this.services.zoom.getDefaultZoomBarDomain(g);g=this.compensateDataForDefaultDomain(g,m);var y=this.model.get("initialZoomDomain"),_=Dd(this.getOptions(),"zoomBar",B.TOP,"initialZoomDomain");_&&_[0]&&_[1]&&(_[0]=new Date(_[0]),_[1]=new Date(_[1])),!_||y&&y[0].valueOf()===_[0].valueOf()&&y[1].valueOf()===_[1].valueOf()?null===_&&null!==y&&this.model.set({initialZoomDomain:null,zoomDomain:na([],m)},{skipUpdate:!0}):this.model.set({initialZoomDomain:na([],_),zoomDomain:_?na([],_):m},{skipUpdate:!0}),this.xScale.range([l,u]).domain(m),this.maxSelectionRange=this.xScale.range(),this.yScale.range([0,s-6]).domain(Xv(g,(function(t){return t.value})));var b=this.model.get("zoomDomain");if(o===U.GRAPH_VIEW&&(this.renderZoomBarArea(h,"path.zoom-graph-area-unselected",g,null),this.updateClipPath(n,this.clipId,0,0,0,0),this.renderZoomBarArea(h,"path.zoom-graph-area",g,this.clipId),this.renderZoomBarBaseline(h,l,u),a)){var w=a.highlightStartMapsTo,O=a.highlightEndMapsTo,x=a.color,E=a.labelMapsTo;a.data.forEach((function(t,n){sb.appendOrSelect(h,"rect.highlight-"+n).attr("height",s-2*e.highlightStrokeWidth).attr("y",e.highlightStrokeWidth).attr("x",e.xScale(t[w])).attr("width",e.xScale(t[O])-e.xScale(t[w])).style("fill",x&&x.scale[t[E]]?x.scale[t[E]]:null).style("fill-opacity",.1).style("stroke",x&&x.scale[t[E]]?x.scale[t[E]]:null).style("stroke-dasharray","2, 2").attr("stroke-width","1px")}))}this.addBrushEventListener(b,l,u);var T=sb.appendOrSelect(n,this.brushSelector).call(this.brush);if(void 0===b);else if(b[0].valueOf()===b[1].valueOf())T.call(this.brush.move,this.xScale.range()),this.updateBrushHandle(this.getComponentContainer(),this.xScale.range(),this.xScale.domain());else{var S=b.map((function(t){return e.xScale(t)}));S[1]-S[0]<this.MIN_SELECTION_DIFF||(T.call(this.brush.move,S),this.updateBrushHandle(this.getComponentContainer(),S,b))}i&&(this.brush.filter((function(){return!1})),T.selectAll("rect").attr("cursor","auto"))}}}},e.prototype.addBrushEventListener=function(t,e,n){var r=this,i=function(e){var n=e.selection;null===n?r.handleBrushedEvent(e,t,r.xScale,r.xScale.range()):n[0]===n[1]||r.handleBrushedEvent(e,t,r.xScale,n)},o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Pt.height[o];this.brush.extent([[e,0],[n,a]]).on("start brush end",null).on("start brush end",i)},e.prototype.handleBrushedEvent=function(t,e,n,r){var i=[n.invert(r[0]),n.invert(r[1])];if(this.updateBrushHandle(this.getComponentContainer(),r,i),null!=t.sourceEvent&&("mousemove"===t.sourceEvent.type||"mouseup"===t.sourceEvent.type||"mousedown"===t.sourceEvent.type||"touchstart"===t.sourceEvent.type||"touchmove"===t.sourceEvent.type||"touchend"===t.sourceEvent.type)){void 0!==e&&e[0]===i[0]&&e[1]===i[1]||this.services.zoom.handleDomainChange(i,{dispatchEvent:!1});var o=void 0;"start"===t.type?o=ft.ZoomBar.SELECTION_START:"brush"===t.type?o=ft.ZoomBar.SELECTION_IN_PROGRESS:"end"===t.type&&(o=ft.ZoomBar.SELECTION_END,this.services.events.dispatchEvent(ft.ZoomDomain.CHANGE,{newDomain:i})),this.services.events.dispatchEvent(o,{selection:r,newDomain:i})}},e.prototype.updateBrushHandle=function(t,e,n){var r=this,i=Pt.handleWidth,o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Pt.height[o],s=-i/2,u=Pt.handleBarWidth,l=o===U.GRAPH_VIEW?Pt.handleBarHeight:6,c=-u/2,h=(a-l)/2;t.select(this.brushSelector).selectAll("rect.handle").data([{type:"w"},{type:"e"}]).attr("x",(function(t){return"w"===t.type?Math.max(e[0]+s,r.maxSelectionRange[0]):"e"===t.type?Math.min(e[1]+s,r.maxSelectionRange[1]-i):void 0})).attr("y",0).attr("width",i).attr("height",a).attr("cursor","ew-resize").style("display",null);var f=t.select(this.brushSelector).selectAll("rect.handle-bar").data([{type:"w"},{type:"e"}]);f.enter().append("rect").attr("class",(function(t){return"handle-bar handle-bar--"+t.type})),f.attr("x",(function(t){return"w"===t.type?Math.max(e[0]+c,r.maxSelectionRange[0]-s+c):"e"===t.type?Math.min(e[1]+c,r.maxSelectionRange[1]+s+c):void 0})).attr("y",h).attr("width",u).attr("height",l).attr("cursor","ew-resize"),o===U.SLIDER_VIEW&&this.updateSliderSelectedArea(e),this.updateClipPath(t,this.clipId,e[0],0,e[1]-e[0],a)},e.prototype.updateSliderSelectedArea=function(t){var e=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),n=Pt.height[e],r=(sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,this.model.get("axesMargins"));r&&r.left&&r.left;var i=this.getComponentContainer(),o=i.select("svg.zoom-container");sb.appendOrSelect(o,"rect.zoom-slider-selected-area").attr("x",t[0]).attr("y",n/2-1).attr("width",t[1]-t[0]).attr("height",2)},e.prototype.renderZoomBarArea=function(t,e,n,r){var i=this.services.cartesianScales,o=i.getMainXAxisPosition(),a=i.getMainYAxisPosition(),s=i.getMainXScaleType(),u=i.getMainYScaleType(),l=function(t,e,n){return function(r,o){return i.getValueFromScale(t,e,n,r,o)}},c=l(this.xScale,s,o),h=l(this.yScale,u,a),f=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),p=Pt.height[f],d=CA().x((function(t,e){return c(t,e)})).y0(p).y1((function(t,e){return p-h(t,e)})),v=sb.appendOrSelect(t,e).datum(n).attr("d",d);r&&v.attr("clip-path","url(#"+r+")")},e.prototype.updateClipPath=function(t,e,n,r,i,o){var a=sb.appendOrSelect(t,"clipPath").attr("id",e);sb.appendOrSelect(a,"rect").attr("x",n).attr("y",r).attr("width",i).attr("height",o)},e.prototype.compensateDataForDefaultDomain=function(t,e){if(t&&!(t.length<2)){var n=Od(t),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier();if(Number(e[0])<Number(n[0][r])){var o={};o[r]=e[0],o[i]=0,n.unshift(o)}if(Number(e[1])>Number(n[n.length-1][r])){o={};o[r]=e[1],o[i]=0,n.push(o)}return n}},e.prototype.renderZoomBarBaseline=function(t,e,n,r){void 0===r&&(r=!1);var i=Dd(this.model.getOptions(),"zoomBar",B.TOP,"type"),o=Pt.height[i],a=MA()([[e,o],[n,o]]);sb.appendOrSelect(t,"path.zoom-bg-baseline").attr("d",a).classed("zoom-bg-baseline-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.renderSkeleton=function(t,e,n){this.renderZoomBarArea(t,"path.zoom-graph-area-unselected",[],null),this.renderZoomBarArea(t,"path.zoom-graph-area",[],this.clipId),this.brush.on("start brush end",null),sb.appendOrSelect(this.getComponentContainer(),this.brushSelector).html(null);var r=Dd(this.getOptions(),"zoomBar",B.TOP,"type");r===U.GRAPH_VIEW&&this.renderZoomBarBaseline(t,e,n,!0)},e.prototype.destroy=function(){this.brush.on("start brush end",null),this.services.events.removeEventListener(ft.ZoomBar.UPDATE,this.render.bind(this))},e}(DS),iU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},oU=function(){function t(t,e){this.services={domUtils:sb,files:hb,events:lb,gradientUtils:vb,transitions:pb,canvasZoom:LS},this.model=new Jm(this.services)}return t.prototype.init=function(t,e){var n=this;this.model.set({holder:t},{skipUpdate:!0}),Object.keys(this.services).forEach((function(t){var e=n.services[t];n.services[t]=new e(n.model,n.services)})),this.services.events.addEventListener(ft.Model.UPDATE,(function(t){var e=!!Dd(t,"detail","animate");n.update(e)})),this.model.setData(e.data),this.services.events.addEventListener(ft.Chart.RESIZE,(function(){n.update(!1)})),this.components=this.getComponents(),this.update()},t.prototype.getComponents=function(){return console.error("getComponents() method is not implemented"),null},t.prototype.update=function(t){var e=this;if(void 0===t&&(t=!0),this.components){Object.keys(this.services).forEach((function(t){var n=e.services[t];n.update()})),this.components.forEach((function(e){return e.render(t)}));var n=this.services.transitions.getPendingTransitions(),r=Object.keys(n).map((function(t){var e=n[t];return e.end().catch((function(t){return t}))}));Promise.all(r).then((function(){return e.services.events.dispatchEvent(ft.Chart.RENDER_FINISHED)}))}},t.prototype.destroy=function(){this.components.forEach((function(t){return t.destroy()})),this.services.domUtils.getHolder().remove(),this.model.set({destroyed:!0},{skipUpdate:!0})},t.prototype.getChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"toolbar","enabled"),i={id:"legend",components:[new PS(this.model,this.services)],growth:Y.PREFERRED},o=Dd(n,"canvasZoom","enabled");o&&!0===o&&t.push(new fA(this.model,this.services));var a=!!this.model.getOptions().title,s={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},u={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},l={id:"header",components:[new WI(this.model,this.services,iU([s],r?[u]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},c={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:Dd(e,"graphFrameRenderType")||I.SVG},h=!0!==Dd(e,"excludeLegend")&&!1!==n.legend.enabled,f=$.COLUMN;if(h){var p=Dd(n,"legend","position");"left"===p?(f=$.ROW,n.legend.orientation||(n.legend.orientation=W.VERTICAL)):"right"===p?(f=$.ROW_REVERSE,n.legend.orientation||(n.legend.orientation=W.VERTICAL)):"bottom"===p&&(f=$.COLUMN_REVERSE)}var d={id:"spacer",components:[new zI(this.model,this.services)],growth:Y.PREFERRED},v={id:"full-frame",components:[new WI(this.model,this.services,iU(h?[i]:[],h?[d]:[],[c]),{direction:f})],growth:Y.STRETCH},g=[];if(a||r){g.push(l);var m={id:"spacer",components:[new zI(this.model,this.services,r?{size:15}:void 0)],growth:Y.PREFERRED};g.push(m)}return g.push(v),[new oA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,g,{direction:$.COLUMN})]},t}(),aU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},uU=function(t){function e(e){var n=t.call(this,e)||this;return n.axisFlavor=ct.DEFAULT,n}return aU(e,t),e.prototype.assignRangeAndDomains=function(){var t=this.services.cartesianScales,e=this.getOptions(),n=t.isDualAxes(),r={primaryDomain:t.domainAxisPosition,primaryRange:t.rangeAxisPosition,secondaryDomain:null,secondaryRange:null};return n&&(r.secondaryDomain=t.secondaryDomainAxisPosition,r.secondaryRange=t.secondaryRangeAxisPosition),Object.keys(r).forEach((function(n){var i=r[n];t.scales[i]?r[n]={position:i,label:t.getScaleLabel(i),identifier:Dd(e,"axes",i,"mapsTo")}:r[n]=null})),r},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.services.cartesianScales,o=this.assignRangeAndDomains(),a=o.primaryDomain,s=o.primaryRange,u=o.secondaryDomain,l=o.secondaryRange,c=i.getDomainAxisScaleType();c===G.TIME&&(t=function(t){return Bm(t,"MMM d, yyyy")});var h=sU([sU(["Group",a.label,s.label],u?[u.label]:[],l?[l.label]:[])],e.map((function(e){return sU([e[r],null===e[a.identifier]?"–":t?t(e[a.identifier]):e[a.identifier],null===e[s.identifier]||isNaN(e[s.identifier])?"–":e[s.identifier].toLocaleString()],u?[null===e[u.identifier]?"–":e[u.identifier]]:[],l?[null===e[l.identifier]||isNaN(e[l.identifier])?"–":e[l.identifier]]:[])})));return h},e.prototype.setData=function(e){var n;if(e&&(n=t.prototype.setData.call(this,e),Dd(this.getOptions(),"zoomBar",B.TOP,"enabled"))){var r=Dd(this.getOptions(),"zoomBar",B.TOP,"data");this.setZoomBarData(r)}return n},e.prototype.setZoomBarData=function(t){var e=t?this.sanitize(Od(t)):this.getDisplayData(),n=e,r=this.services.cartesianScales;if(e&&r.domainAxisPosition&&r.rangeAxisPosition){var i=r.getDomainIdentifier(),o=r.getRangeIdentifier(),a=e.map((function(t){return t[i].getTime()}));a=xd(a).sort(),n=a.map((function(t){var n=0,r={};return e.forEach((function(e){e[i].getTime()===t&&(n+=e[o])})),r[i]=new Date(t),r[o]=n,r}))}this.set({zoomBarData:n})},e.prototype.getZoomBarData=function(){return this.get("zoomBarData")},e.prototype.sanitizeDateValues=function(t){var e=this.getOptions();if(!e.axes)return t;var n=[];return Object.keys(B).forEach((function(t){var r=B[t],i=e.axes[r];if(i&&i.scaleType===G.TIME){var o=i.mapsTo;null===o&&void 0===o||n.push(o)}})),n.length>0&&t.forEach((function(t){n.forEach((function(e){null===Dd(t,e,"getTime")&&(t[e]=new Date(t[e]))}))})),t},e.prototype.sanitize=function(e){return e=t.prototype.sanitize.call(this,e),e=this.sanitizeDateValues(e),e},e}(Jm),lU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),cU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},hU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.services=Object.assign(r.services,{cartesianScales:_T,curves:SS,zoom:CS}),r.model=new uU(r.services),r}return lU(e,t),e.prototype.getAxisChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"zoomBar",B.TOP,"enabled"),i=Dd(n,"toolbar","enabled");this.services.cartesianScales.determineAxisDuality(),this.services.cartesianScales.findDomainAndRangeAxes(),this.services.cartesianScales.determineOrientation();var o=this.services.cartesianScales.getMainXAxisPosition(),a=Dd(n,"axes",o,"scaleType"),s=r&&o===B.BOTTOM&&a===G.TIME,u=this.services.zoom.isZoomBarLocked(B.TOP),l=!!this.model.getOptions().title,c={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},h={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},f={id:"header",components:[new WI(this.model,this.services,cU([c],i?[h]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},p={id:"legend",components:[new PS(this.model,this.services)],growth:Y.PREFERRED};s&&!u&&t.push(new cA(this.model,this.services),new VB(this.model,this.services)),t.push(new JC(this.model,this.services)),t.push(new vA(this.model,this.services));var d={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:I.SVG},v=!1!==Dd(e,"legend","enabled")&&!1!==this.model.getOptions().legend.enabled,g=$.COLUMN;if(v){var m=Dd(this.model.getOptions(),"legend","position");m===z.LEFT?(g=$.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=W.VERTICAL)):m===z.RIGHT?(g=$.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=W.VERTICAL)):m===z.BOTTOM&&(g=$.COLUMN_REVERSE)}var y={id:"spacer",components:[new zI(this.model,this.services)],growth:Y.PREFERRED},_={id:"full-frame",components:[new WI(this.model,this.services,cU(v?[p]:[],v?[y]:[],[d]),{direction:g})],growth:Y.STRETCH},b={id:"zoom-bar",components:[new rU(this.model,this.services)],growth:Y.PREFERRED,renderType:I.SVG},w=[];if(l||i){w.push(f);var O={id:"spacer",components:[new zI(this.model,this.services,i?{size:15}:void 0)],growth:Y.PREFERRED};w.push(O)}return s&&w.push(b),w.push(_),[new uA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,w,{direction:$.COLUMN})]},e}(oU),fU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),pU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(Od(bv.areaChart),n.options)),r.init(e,n),r}return fU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new QA(this.model,this.services),new LA(this.model,this.services),new FA(this.model,this.services,{fadeInOnChartHolderMouseover:!0,handleThresholds:!0}),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),dU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),vU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.stackedAreaChart,n.options)),r.init(e,n),r}return dU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new KB(this.model,this.services),new kA(this.model,this.services),new QA(this.model,this.services,{stacked:!0}),new nL(this.model,this.services,{fadeInOnChartHolderMouseover:!0,handleThresholds:!0,stacked:!0}),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),gU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.simpleBarChart,n.options)),r.init(e,n),r}return gU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new NA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t);return e},e}(hU),yU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),_U=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.groupedBarChart,n.options)),r.init(e,n),r}return yU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new BA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t);return e},e}(hU),bU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),wU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.stackedBarChart,n.options)),r.init(e,n),r}return bU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new KB(this.model,this.services),new VA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ}),new eU(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU);function OU(t=Vv){if(t===Vv)return xU;if("function"!==typeof t)throw new TypeError("compare is not a function");return(e,n)=>{const r=t(e,n);return r||0===r?r:(0===t(n,n))-(0===t(e,e))}}function xU(t,e){return(null==t||!(t>=t))-(null==e||!(e>=e))||(t<e?-1:t>e?1:0)}function EU(t,e,n=0,r=1/0,i){if(e=Math.floor(e),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(t.length-1,r)),!(n<=e&&e<=r))return t;i=void 0===i?xU:OU(i);while(r>n){if(r-n>600){const o=r-n+1,a=e-n+1,s=Math.log(o),u=.5*Math.exp(2*s/3),l=.5*Math.sqrt(s*u*(o-u)/o)*(a-o/2<0?-1:1),c=Math.max(n,Math.floor(e-a*u/o+l)),h=Math.min(r,Math.floor(e+(o-a)*u/o+l));EU(t,e,c,h,i)}const o=t[e];let a=n,s=r;TU(t,n,e),i(t[r],o)>0&&TU(t,n,r);while(a<s){TU(t,a,s),++a,--s;while(i(t[a],o)<0)++a;while(i(t[s],o)>0)--s}0===i(t[n],o)?TU(t,n,s):(++s,TU(t,s,r)),s<=e&&(n=s+1),e<=s&&(r=s-1)}return t}function TU(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function SU(t,e,n){if(t=Float64Array.from(Wv(t,n)),(r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return Vm(t);if(e>=1)return UE(t);var r,i=(r-1)*e,o=Math.floor(i),a=UE(EU(t,o).subarray(0,o+1)),s=Vm(t.subarray(o+1));return a+(s-a)*(i-o)}}var MU,CU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),AU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},LU=function(t){function e(e){return t.call(this,e)||this}return CU(e,t),e.prototype.getBoxQuartiles=function(t){return{q_25:SU(t,.25),q_50:SU(t,.5),q_75:SU(t,.75)}},e.prototype.getBoxplotData=function(){for(var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getGroupedData(),r=[],i=function(t,n){for(var i,a=o.services.cartesianScales.getRangeIdentifier(),s=n.map((function(t){return t[a]})).sort(Vv),u=(i={},i[e]=t,i.counts=s,i.quartiles=o.getBoxQuartiles(s),i.outliers=null,i.whiskers=null,i),l=u.quartiles.q_25,c=u.quartiles.q_75,h=1.5*(c-l),f=l-h,p=c+h,d=[],v=[],g=0,m=s;g<m.length;g++){var y=m[g];y<f||y>p?d.push(y):v.push(y)}u.outliers=d;var _=Vm(v),b=UE(v);u.whiskers={min:_||Vm([u.quartiles.q_25,u.quartiles.q_50,u.quartiles.q_75]),max:b||UE([u.quartiles.q_25,u.quartiles.q_50,u.quartiles.q_75])},r.push(u)},o=this,a=0,s=n;a<s.length;a++){var u=s[a],l=u.name,c=u.data;i(l,c)}return r},e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getBoxplotData(),r=AU([["Group","Minimum","Q1","Median","Q3","Maximum","IQR","Outlier(s)"]],n.map((function(t){var n=Dd(t,"outliers");return null!==n&&0!==n.length||(n=["–"]),[t[e],null!==Dd(t,"whiskers","min")?Dd(t,"whiskers","min").toLocaleString():"–",null!==Dd(t,"quartiles","q_25")?Dd(t,"quartiles","q_25").toLocaleString():"–",null!==Dd(t,"quartiles","q_50")?Dd(t,"quartiles","q_50").toLocaleString():"–",null!==Dd(t,"quartiles","q_75")?Dd(t,"quartiles","q_75").toLocaleString():"–",null!==Dd(t,"whiskers","max")?Dd(t,"whiskers","max").toLocaleString():"–",null!==Dd(t,"quartiles","q_75")&&null!==Dd(t,"quartiles","q_25")?(Dd(t,"quartiles","q_75")-Dd(t,"quartiles","q_25")).toLocaleString():"–",n.map((function(t){return t.toLocaleString()})).join(",")]})));return r},e.prototype.setColorClassNames=function(){var t=1,e=Dd(this.getOptions(),"color","pairing"),n=Dd(e,"option"),r=_t.pairingOptions;n=n<=r[t+"-color"]?n:1;var i=this.allDataGroups.map((function(e,r){return t+"-"+n+"-1"}));this.colorClassNames=Cv().range(i).domain(this.allDataGroups)},e}(uU),DU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new LU(r.services),r.model.setOptions(Td(bv.boxplotChart,n.options)),r.init(e,n),r}return DU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new GA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t,{legend:{enabled:!1}});return e},e}(hU),PU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.bubbleChart,n.options)),r.init(e,n),r}return PU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new qA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),IU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},jU=function(t){function e(e){return t.call(this,e)||this}return IU(e,t),e.prototype.getMatchingRangeIndexForDatapoint=function(t){for(var e,n=t.ranges.length-1;n>0;n--){var r=t.ranges[n];if(t.value>=r)return e=n,e}return 0},e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.services.cartesianScales.getRangeIdentifier(),o=Dd(n,"bullet","performanceAreaTitles"),a=NU([["Title","Group","Value","Target","Percentage","Performance"]],e.map((function(e){return[e["title"],e[r],null===e["value"]?"–":e["value"],null===Dd(e,"marker")?"–":e["marker"],null===Dd(e,"marker")?"–":Math.floor(e[i]/e.marker*100)+"%",o[t.getMatchingRangeIndexForDatapoint(e)]]})));return a},e}(uU),BU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new jU(r.services),r.model.setOptions(Td(bv.bulletChart,n.options)),r.init(e,n),r}return BU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new YA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),VU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},GU=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return VU(e,t),e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getBinnedStackedData(),r=HU([HU([tl(t,"bins.rangeLabel")||"Range"],n.map((function(t){return tl(t,"0."+e)})))],tl(n,0).map((function(t,r){return HU([tl(t,"data.x0")+" – "+tl(t,"data.x1")],n.map((function(t){return tl(t[r],"data."+tl(t[r],e))})))})));return r},e}(uU),zU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new GU(r.services),r.model.setOptions(Td(bv.histogramChart,n.options)),r.init(e,n),r.update(),r}return zU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new ZB(this.model,this.services),new XA(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),WU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.lineChart,n.options)),r.init(e,n),r}return WU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new QA(this.model,this.services),new FA(this.model,this.services,{handleThresholds:!0}),new ML(this.model,this.services),new eU(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),$U=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.lollipopChart,n.options)),r.init(e,n),r}return $U(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new tL(this.model,this.services),new FA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),ZU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.scatterChart,n.options)),r.init(e,n),r}return ZU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new FA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),KU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},JU=function(t){function e(e){return t.call(this,e)||this}return KU(e,t),e.prototype.getTabularData=function(e){var n=t.prototype.getTabularData.call(this,e);return e!==n&&n.forEach((function(t){t.key&&t.key!==t.group&&(t.group=t.key)})),n},e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.data.groupMapsTo,r=QU([["Group","Value"]],t.map((function(t){return[t[n],null===t["value"]?"–":t["value"].toLocaleString()]})));return r},e.prototype.sanitize=function(t){var e=this.getTabularData(t);return e.sort((function(t,e){return e.value-t.value}))},e}(Jm),tV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eV=function(t){function e(e,n,r){void 0===r&&(r=!1);var i=t.call(this,e,n)||this;return i.model=new JU(i.services),r||(i.model.setOptions(Td(bv.pieChart,n.options)),i.init(e,n)),i}return tV(e,t),e.prototype.getComponents=function(){var t=[new gL(this.model,this.services),new TL(this.model,this.services,{skeleton:K.PIE})],e=this.getChartComponents(t);return e},e}(oU),nV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rV=function(t){function e(e,n){var r=t.call(this,e,n,!0)||this;return r.model.setOptions(Td(bv.donutChart,n.options)),r.init(e,n),r}return nV(e,t),e.prototype.getComponents=function(){var t=[new OL(this.model,this.services),new TL(this.model,this.services,{skeleton:K.DONUT})],e=this.getChartComponents(t);return e},e}(eV),iV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},aV=function(t){function e(e){return t.call(this,e)||this}return iV(e,t),e.prototype.getMaximumDomain=function(t){var e=t.reduce((function(t,e){return t+e.value}),0);return e},e.prototype.getFillColor=function(e){var n=this.getOptions(),r=Dd(n,"color","scale"),i=this.getStatus();return r||!i?t.prototype.getFillColor.call(this,e):null},e.prototype.getStatus=function(){var t=this.getOptions(),e=Dd(this.getDisplayData()),n=(e?e.reduce((function(t,e){return{value:t.value+e.value}})):0).value,r=Dd(t,"meter","proportional")?n:n>100?100:n,i=Dd(t,"meter","status","ranges");if(i){var o=i.filter((function(t){return t.range[0]<=r&&r<=t.range[1]}));if(o.length>0)return o[0].status}return null},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.getStatus(),o=Dd(n,"meter","proportional"),a=[];if(null===o){t=100;var s=e[0];a=[oV(["Group","Value"],i?["Status"]:[]),oV([s[r],s["value"]],i?[i]:[])]}else{var u=Dd(o,"total");t=u||this.getMaximumDomain(e),a=oV([["Group","Value","Percentage of total"]],e.map((function(e){return[e[r],e["value"],(e["value"]/t*100).toFixed(2)+" %"]})))}return a},e}(Jm),sV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),uV=function(){return uV=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},uV.apply(this,arguments)},lV=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="meter",e.renderType=I.SVG,e}return sV(e,t),e.prototype.getStackedBounds=function(t,e){var n=0,r=t.map((function(t,r){return 0!==r?(n+=e(t.value),uV(uV({},t),{width:Math.abs(e(t.value)-Et.dividerWidth),x:n-e(t.value)})):(n=e(t.value),uV(uV({},t),{width:Math.abs(e(t.value)-Et.dividerWidth),x:0}))}));return r},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n,r=this,i=this.getComponentContainer(),o=this.getOptions(),s=Dd(o,"meter","proportional"),u=this.model.getDisplayData(),l=this.model.getStatus(),c=sb.getSVGElementSize(i,{useAttrs:!0}).width,h=o.data.groupMapsTo;if(null===Dd(o,"meter","proportional"))n=100;else{var f=Dd(o,"meter","proportional","total");n=f||this.model.getMaximumDomain(this.model.getDisplayData())}var p=BE().domain([0,n]).range([0,c]),d=this.getStackedBounds(u,p),v=Dd(o,"meter","height");sb.appendOrSelect(i,"rect.container").attr("x",0).attr("y",0).attr("width",c).attr("height",v||(s?Et.height.proportional:Et.height.default)),sb.appendOrSelect(i,"line.rangeIndicator").attr("x1",c).attr("x2",c).attr("y1",0).attr("y2",v||(s?Et.height.proportional:Et.height.default));var g=i.selectAll("rect.value").data(d),m=null==l||r.model.isUserProvidedColorScaleValid()||s?"value":"value status--"+l;g.enter().append("rect").classed("value",!0).merge(g).attr("x",(function(t){return t.x})).attr("y",0).attr("height",(function(){var t=Dd(o,"meter","height");return t||(s?Et.height.proportional:Et.height.default)})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[h],originalClassName:m})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"meter-bar-update",animate:t})})).attr("width",(function(t,e){return t.value>n?p(n):t.width})).style("fill",(function(t){return r.model.getFillColor(t[h])})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","value").attr("aria-label",(function(t){return t.value})),g.exit().remove();var y=Dd(o,"meter","peak"),_=y;null!==y&&(y>n?_=n:y<u[0].value&&(_=u[0].value>n?n:u[0].value));var b=i.selectAll("line.peak").data(null==_?[]:[_]);b.enter().append("line").classed("peak",!0).merge(b).attr("y1",0).attr("y2",(function(){var t=Dd(o,"meter","height");return t||(s?Et.height.proportional:Et.height.default)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"peak-line-update",animate:t})})).attr("x1",(function(t){return p(t)})).attr("x2",(function(t){return p(t)})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","peak").attr("aria-label",(function(t){return t})),b.exit().remove(),this.services.domUtils.setSVGMaxHeight(),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this,r=Dd(t,"meter","proportional");this.parent.selectAll("rect.value").on("mouseover",(function(t,i){var o=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEOVER,{event:t,element:o,datum:i}),r&&(o.classed("hovered",!0),n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:o,items:[{label:i[e],value:i.value}]}))})).on("mousemove",(function(t,e){var i=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEMOVE,{event:t,element:i,datum:e}),r&&n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.Meter.METER_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var i=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEOUT,{event:t,element:i,datum:e}),r&&(i.classed("hovered",!1),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i}))}))},e.prototype.destroy=function(){this.parent.selectAll("rect.value").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("click",null)},e}(DS),cV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),hV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},fV=function(t){function e(e,n){var r=t.call(this,e,n)||this;r.model=new aV(r.services);var i=n.options.meter.proportional?na(Od(bv.proportionalMeterChart),n.options):na(Od(bv.meterChart),n.options);return r.model.setOptions(i),r.init(e,n),r}return cV(e,t),e.prototype.getComponents=function(){var t=Dd(this.model.getOptions(),"meter","showLabels"),e=hV(t?[{id:"meter-title",components:[new rA(this.model,this.services)],growth:Y.STRETCH,renderType:I.SVG},{id:"spacer",components:[new zI(this.model,this.services,{size:8})],growth:Y.STRETCH}]:[],[{id:"meter-graph",components:[new lV(this.model,this.services)],growth:Y.STRETCH,renderType:I.SVG}]),n=[new WI(this.model,this.services,e,{direction:$.COLUMN})],r=this.getChartComponents(n,{graphFrameRenderType:I.HTML});return r},e}(oU),pV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},vV=function(t){function e(e){return t.call(this,e)||this}return pV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=this.getGroupedData(),n=Dd(t,"radar","axes"),r=n.angle,i=n.value,o=Dd(e,"0","data").map((function(t){return t[r]})),a=dV([dV(["Group"],o)],e.map((function(t){return dV([t["name"]],o.map((function(e,n){return null!==Dd(t,"data",n,i)?Dd(t,"data",n,i).toLocaleString():"–"})))})));return a},e}(uU),gV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new vV(r.services),r.model.setOptions(Td(bv.radarChart,n.options)),r.init(e,n),r}return gV(e,t),e.prototype.getComponents=function(){var t=[new xR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),yV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),_V=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},bV=function(t){function e(e){return t.call(this,e)||this}return yV(e,t),e.prototype.getDataGroups=function(){return t.prototype.getDataGroups.call(this).filter((function(t){return"delta"!==t.name}))},e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.data.groupMapsTo,r=_V([["Group","Value"]],t.map((function(t){return[t[n],null===t["value"]?"–":t["value"].toLocaleString()]})));return r},e}(Jm),wV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),OV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new bV(r.services),r.model.setOptions(Td(bv.gaugeChart,n.options)),r.init(e,n),r}return wV(e,t),e.prototype.getComponents=function(){var t=[new bL(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),xV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),EV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},TV=(MU={},MU[it.LINE]=[QA,FA],MU[it.SCATTER]=[FA],MU[it.AREA]=[LA,QA,FA],MU[it.STACKED_AREA]=[kA,QA,nL,KB],MU[it.SIMPLE_BAR]=[NA],MU[it.GROUPED_BAR]=[BA,eU],MU[it.STACKED_BAR]=[VA,KB],MU),SV=function(t){function e(e,n){var r=t.call(this,e,n)||this,i=Td(bv.comboChart,n.options);return n.options.comboChartTypes||(console.error("No comboChartTypes defined for the Combo Chart!"),i.comboChartTypes=[{type:it.LINE,correspondingDatasets:[]}]),r.model.setOptions(i),r.init(e,n),r}return xV(e,t),e.prototype.getGraphComponents=function(){var t=this,e=this.model.getOptions().comboChartTypes,n=0,r=e.map((function(e){var r,i,o=e.type;return"string"===typeof e.type?Object.keys(TV).includes(e.type)?(r=na({},bv[Rh(e.type)+"Chart"],t.model.getOptions(),e.options),e.type===it.STACKED_AREA&&(i=!0),TV[e.type].map((function(o,a){return new o(t.model,t.services,{groups:e.correspondingDatasets,id:n++,options:r,stacked:i})}))):(console.error('Invalid chart type "'+e.type+'" specified for combo chart. Please refer to the ComboChart tutorial for more guidance.'),null):(r=na({},t.model.getOptions(),e.options),new o(t.model,t.services,{groups:e.correspondingDatasets,id:n++,options:r}))})).filter((function(t){return null!==t}));return va(r)},e.prototype.getComponents=function(){var t=this.model.getOptions().comboChartTypes,e=t.some((function(t){return t.type===it.STACKED_BAR||t.type===it.STACKED_AREA})),n=EV([new QI(this.model,this.services),new GB(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e?[]:[new qB(this.model,this.services)],this.getGraphComponents()),r=this.getAxisChartComponents(n);return r},e}(hU),MV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),CV=function(t){function e(e){return t.call(this,e)||this}return MV(e,t),e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=[["Child","Parent"]];return e.forEach((function(e){t.getChildrenDatums(e,n),n.push([e.name,"–"])})),n},e.prototype.getChildrenDatums=function(t,e){var n=this;void 0===e&&(e=[]),t.children&&t.children.length>0&&t.children.forEach((function(r){n.getChildrenDatums(r,e),e.push([r.name,t.name])}))},e}(Jm),AV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new CV(r.services),r.model.setOptions(Td(bv.treeChart,n.options)),r.init(e,n),r}return AV(e,t),e.prototype.getComponents=function(){var t=[new wD(this.model,this.services)],e=this.getChartComponents(t,{excludeLegend:!0});return e},e}(oU),DV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kV=function(t){function e(e){return t.call(this,e)||this}return DV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=[["Child","Group","Value"]];return t.forEach((function(t){Array.isArray(t.children)?t.children.forEach((function(n){e.push([n.name,t.name,n.value])})):null!==Dd(t.name)&&Dd(t.value)&&e.push(["–",t.name,t.value])})),e},e}(Jm),PV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new kV(r.services),r.model.setOptions(Td(bv.treemapChart,n.options)),r.init(e,n),r}return PV(e,t),e.prototype.getComponents=function(){var t=[new cR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),IV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NV=function(){return NV=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},NV.apply(this,arguments)},jV=function(t){function e(e){var n=t.call(this,e)||this;return n.parentNode=!1,n.set({depth:2},{skipUpdate:!0}),n}return IV(e,t),e.prototype.setData=function(e){t.prototype.setData.call(this,e),this.setDataGroups(),1===e.length&&(this.parentNode=!0),this.setZoom()},e.prototype.setOptions=function(t){var e=this.getOptions(),n=na({},t,this.getZoomOptions(t));Ld(e,n);var r=this.getHierarchyLevel(),i=Dd(e,"circlePack","hierarchyLevel");this.set({options:na(e,n),depth:i&&i<4?i:r})},e.prototype.getZoomOptions=function(t){if(!this.getDisplayData())return{};var e=this.getDisplayData(),n=t||this.getOptions(),r=1===e.length&&Dd(e,0,"children")?Dd(e,0,"children"):e,i=this.getHierarchyLevel();return r.some((function(t){if(t.children&&t.children.some((function(t){return t.children})))return i=3,!1})),!0===Dd(n,"canvasZoom","enabled")&&i>2?{legend:{additionalItems:[{type:st.ZOOM,name:"Click to zoom"}]}}:null},e.prototype.setZoom=function(t){this.setOptions(this.getZoomOptions(t))},e.prototype.updateHierarchyLevel=function(t){this.set({depth:t})},e.prototype.getHierarchyLevel=function(){return this.get("depth")},e.prototype.hasParentNode=function(){return this.parentNode},e.prototype.setDataGroups=function(){var t=this,e=this.getData(),n=this.getOptions(),r=n.data.groupMapsTo,i=e.map((function(e){var n=e[r];return t.setChildrenDataGroup(e,n)}));this.set({data:i},{skipUpdate:!0})},e.prototype.setChildrenDataGroup=function(t,e){var n=this;return t.children?NV(NV({},t),{dataGroupName:e,children:t.children.map((function(t,r){return n.setChildrenDataGroup(t,e)}))}):NV(NV({},t),{dataGroupName:e})},e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=[["Child","Parent","Value"]];return e.forEach((function(e){var r=e.value?e.value:0;e.children&&(r+=t.getChildrenDatums(e.children,e.name,n,0)),n.push(["–",e.name,r])})),n},e.prototype.getChildrenDatums=function(t,e,n,r){var i=this;void 0===n&&(n=[]),void 0===r&&(r=0);var o=e;return t.forEach((function(t){var e=t.name,a=0;if(t.children)t.children.length>0&&("number"===typeof t.value&&(r+=t.value),a+=i.getChildrenDatums(t.children,e,n,a),n.push([e,o,a]),r+=a);else{var s=0;"number"===typeof t.value&&(s=t.value,r+=t.value),n.push([t.name,o,s])}})),r},e}(Jm),BV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new jV(r.services),r.model.setOptions(Td(bv.circlePackChart,n.options)),r.init(e,n),r}return BV(e,t),e.prototype.getComponents=function(){var t=[new KR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),VV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},GV=function(t){function e(e){return t.call(this,e)||this}return VV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.wordCloud,r=n.fontSizeMapsTo,i=n.wordMapsTo,o=e.data.groupMapsTo,a=HV([[e.tooltip.wordLabel,"Group",e.tooltip.valueLabel]],t.map((function(t){return[t[i],t[o],t[r]]})));return a},e}(Jm),zV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new GV(r.services),r.model.setOptions(Td(bv.wordCloudChart,n.options)),r.init(e,n),r}return zV(e,t),e.prototype.getComponents=function(){var t=[new eI(this.model,this.services),new TL(this.model,this.services,{skeleton:K.PIE})],e=this.getChartComponents(t);return e},e}(oU),WV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},$V=function(t){function e(e){return t.call(this,e)||this}return WV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData();t.sort((function(t,e){return t["source"].localeCompare(e["source"])}));var e=qV([["Source","Target","Value"]],t.map((function(t){return[t["source"],t["target"],t["value"]]})));return e},e}(uU),YV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ZV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new $V(r.services),r.model.setOptions(Td(bv.alluvialChart,n.options)),r.init(e,n),r}return YV(e,t),e.prototype.getComponents=function(){var t=[new UI(this.model,this.services)],e=this.getChartComponents(t,{excludeLegend:!0});return e},e}(oU);function XV(){var t,e=0,n=1,r=1,i=[.5],o=[0,1];function a(e){return null!=e&&e<=e?o[Yv(i,e,0,r)]:t}function s(){var t=-1;i=new Array(r);while(++t<r)i[t]=((t+1)*n-(t-r)*e)/(r+1);return a}return a.domain=function(t){return arguments.length?([e,n]=t,e=+e,n=+n,s()):[e,n]},a.range=function(t){return arguments.length?(r=(o=Array.from(t)).length-1,s()):o.slice()},a.invertExtent=function(t){var a=o.indexOf(t);return a<0?[NaN,NaN]:a<1?[e,i[0]]:a>=r?[i[r-1],n]:[i[a-1],i[a]]},a.unknown=function(e){return arguments.length?(t=e,a):a},a.thresholds=function(){return i.slice()},a.copy=function(){return XV().domain([e,n]).range(o).unknown(t)},Sv.apply(jE(a),arguments)}var KV,QV,JV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tH=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},eH=function(t){function e(e){var n=t.call(this,e)||this;n.axisFlavor=ct.HOVERABLE,n._colorScale=void 0,n._domains=[],n._ranges=[],n._matrix={};var r=Dd(n.getOptions(),"axes");if(Dd(r,"left","scaleType")&&Dd(r,"left","scaleType")!==G.LABELS||Dd(r,"right","scaleType")&&Dd(r,"right","scaleType")!==G.LABELS||Dd(r,"top","scaleType")&&Dd(r,"top","scaleType")!==G.LABELS||Dd(r,"bottom","scaleType")&&Dd(r,"bottom","scaleType")!==G.LABELS)throw Error("Heatmap only supports label scaletypes.");return n}return JV(e,t),e.prototype.getValueDomain=function(){var t=Xv(this.getDisplayData(),(function(t){return t.value})),e=BE().domain(t).nice().domain();if(e[0]>0)e[0]=0;else if(0===e[0]&&0===e[1])return[0,1];return e[0]<0&&e[1]>0&&(Math.abs(e[0])>e[1]?e[1]=Math.abs(e[0]):e[0]=-e[1]),e},e.prototype.getFillColor=function(t){return this._colorScale(t)},e.prototype.getUniqueDomain=function(){if(Vh(this._domains)){var t=this.getDisplayData(),e=this.services.cartesianScales,n=e.getDomainIdentifier(),r=e.getMainXAxisPosition(),i=e.getCustomDomainValuesByposition(r);if(i)return i;this._domains=Array.from(new Set(t.map((function(t){return t[n]}))))}return this._domains},e.prototype.getUniqueRanges=function(){if(Vh(this._ranges)){var t=this.getDisplayData(),e=this.services.cartesianScales,n=e.getRangeIdentifier(),r=e.getMainYAxisPosition(),i=e.getCustomDomainValuesByposition(r);if(i)return i;this._ranges=Array.from(new Set(t.map((function(t){return t[n]}))))}return this._ranges},e.prototype.getMatrix=function(){var t=this;if(Vh(this._matrix)){var e=this.getUniqueDomain(),n=this.getUniqueRanges(),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier(),o={};n.forEach((function(t){o[t]={value:null,index:-1}})),e.forEach((function(e){t._matrix[e]=Od(o)})),this.getDisplayData().forEach((function(e,n){t._matrix[e[r]][e[i]]={value:e["value"],index:n}}))}return this._matrix},e.prototype.setData=function(t){var e=this.sanitize(Od(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),this._domains=[],this._ranges=[],this._matrix={},e},e.prototype.getMatrixAsArray=function(){var t=this;Vh(this._matrix)&&this.getMatrix();var e=this.getUniqueDomain(),n=this.getUniqueRanges(),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier(),o=[];return e.forEach((function(e){n.forEach((function(n){var a={value:t._matrix[e][n].value,index:t._matrix[e][n].index};a[r]=e,a[i]=n,o.push(a)}))})),o},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.assignRangeAndDomains(),r=n.primaryDomain,i=n.primaryRange,o=tH([[r.label,i.label,"Value"]],e.map((function(e){return[null===e[r.identifier]?"–":t?t(e[r.identifier]):e[r.identifier],null===e[i.identifier]?"–":e[i.identifier].toLocaleString(),e["value"]]})));return o},e.prototype.getColorClassName=function(t){return t.originalClassName+" "+this._colorScale(t.value)},e.prototype.setColorClassNames=function(){var t=this.getOptions(),e=Dd(t,"color","gradient","colors"),n=!Vh(e),r=Dd(t,"color","pairing","option"),i=this.getValueDomain(),o=i[0]<0&&i[1]>0?"diverge":"mono";(r<1&&r>4&&"mono"===o||r<1&&r>2&&"diverge"===o)&&(r=1);var a=n?e:[];if(!n)for(var s="diverge"===o?17:11,u=1;u<s+1;u++)a.push("fill-"+o+"-"+r+"-"+u);this._colorScale=XV().domain(i).range(a)},e}(uU),nH=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rH=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},iH=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new eH(r.services),r.model.setOptions(Td(bv.heatmapChart,n.options)),r.init(e,n),r}return nH(e,t),e.prototype.getAxisChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"toolbar","enabled");this.services.cartesianScales.determineAxisDuality(),this.services.cartesianScales.findDomainAndRangeAxes(),this.services.cartesianScales.determineOrientation();var i=!!this.model.getOptions().title,o={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},a={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},s={id:"header",components:[new WI(this.model,this.services,rH([o],r?[a]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},u={id:"legend",components:[new QS(this.model,this.services)],growth:Y.PREFERRED,renderType:I.SVG},l={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:I.SVG},c=!1!==Dd(e,"legend","enabled")&&!1!==this.model.getOptions().legend.enabled,h=$.COLUMN_REVERSE,f={id:"spacer",components:[new zI(this.model,this.services,{size:15})],growth:Y.PREFERRED},p={id:"full-frame",components:[new WI(this.model,this.services,rH(c?[u]:[],c?[f]:[],[l]),{direction:h})],growth:Y.STRETCH},d=[];if(i||r){d.push(s);var v={id:"spacer",components:[new zI(this.model,this.services,r?{size:15}:void 0)],growth:Y.PREFERRED};d.push(v)}return d.push(p),[new uA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,d,{direction:$.COLUMN})]},e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new HI(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),oH={name:"CcvBaseChart",data:function(){return{coreChart:null}},props:{data:{type:[Object,Array],required:!0},options:{type:Object,required:!0}},watch:{data:{handler:function(t){this.coreChart.model.setData(t)},deep:!0},options:{handler:function(t){this.coreChart.model.setOptions(t)},deep:!0}}},aH=oH;function sH(t,e,n,r,i,o,a,s){var u,l="function"===typeof t?t.options:t;if(e&&(l.render=e,l.staticRenderFns=n,l._compiled=!0),r&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),a?(u=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},l._ssrRegister=u):i&&(u=s?function(){i.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:i),u)if(l.functional){l._injectStyles=u;var c=l.render;l.render=function(t,e){return u.call(e),c(t,e)}}else{var h=l.beforeCreate;l.beforeCreate=h?[].concat(h,u):[u]}return{exports:t,options:l}}var uH=sH(aH,KV,QV,!1,null,null,null),lH=uH.exports,cH={name:"CcvAreaChart",extends:lH,mounted:function(){this.coreChart=new pU(this.$el,{data:this.data,options:this.options})}},hH=cH,fH=sH(hH,P,R,!1,null,null,null),pH=fH.exports,dH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-stacked-area-chart"})},vH=[],gH={name:"CcvStackedAreaChart",extends:lH,mounted:function(){this.coreChart=new vU(this.$el,{data:this.data,options:this.options})}},mH=gH,yH=sH(mH,dH,vH,!1,null,null,null),_H=yH.exports,bH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-simple-bar-chart"})},wH=[],OH={name:"CcvSimpleBarChart",extends:lH,mounted:function(){this.coreChart=new mU(this.$el,{data:this.data,options:this.options})}},xH=OH,EH=sH(xH,bH,wH,!1,null,null,null),TH=EH.exports,SH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-grouped-bar-chart"})},MH=[],CH={name:"CcvGroupedBarChart",extends:lH,mounted:function(){this.coreChart=new _U(this.$el,{data:this.data,options:this.options})}},AH=CH,LH=sH(AH,SH,MH,!1,null,null,null),DH=LH.exports,kH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-stacked-bar-chart"})},PH=[],RH={name:"CcvStackedBarChart",extends:lH,mounted:function(){this.coreChart=new wU(this.$el,{data:this.data,options:this.options})}},IH=RH,NH=sH(IH,kH,PH,!1,null,null,null),jH=NH.exports,BH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-boxplot-chart"})},UH=[],VH={name:"CcvBoxplotChart",extends:lH,mounted:function(){this.coreChart=new kU(this.$el,{data:this.data,options:this.options})}},HH=VH,GH=sH(HH,BH,UH,!1,null,null,null),zH=GH.exports,FH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-bubble-chart"})},WH=[],qH={name:"CcvBubbleChart",extends:lH,mounted:function(){this.coreChart=new RU(this.$el,{data:this.data,options:this.options})}},$H=qH,YH=sH($H,FH,WH,!1,null,null,null),ZH=YH.exports,XH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-bullet-chart"})},KH=[],QH={name:"CcvBulletChart",extends:lH,mounted:function(){this.coreChart=new UU(this.$el,{data:this.data,options:this.options})}},JH=QH,tG=sH(JH,XH,KH,!1,null,null,null),eG=tG.exports,nG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-donut-chart"})},rG=[],iG={name:"CcvDonutChart",extends:lH,mounted:function(){this.coreChart=new rV(this.$el,{data:this.data,options:this.options})}},oG=iG,aG=sH(oG,nG,rG,!1,null,null,null),sG=aG.exports,uG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-gauge-chart"})},lG=[],cG={name:"CcvGaugeChart",extends:lH,mounted:function(){this.coreChart=new OV(this.$el,{data:this.data,options:this.options})}},hG=cG,fG=sH(hG,uG,lG,!1,null,null,null),pG=fG.exports,dG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-histogram-chart"})},vG=[],gG={name:"CcvHistogramChart",extends:lH,mounted:function(){this.coreChart=new FU(this.$el,{data:this.data,options:this.options})}},mG=gG,yG=sH(mG,dG,vG,!1,null,null,null),_G=yG.exports,bG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-line-chart"})},wG=[],OG={name:"CcvLineChart",extends:lH,mounted:function(){this.coreChart=new qU(this.$el,{data:this.data,options:this.options})}},xG=OG,EG=sH(xG,bG,wG,!1,null,null,null),TG=EG.exports,SG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-lollipop-chart"})},MG=[],CG={name:"CcvLollipopChart",extends:lH,mounted:function(){this.coreChart=new YU(this.$el,{data:this.data,options:this.options})}},AG=CG,LG=sH(AG,SG,MG,!1,null,null,null),DG=LG.exports,kG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-pie-chart"})},PG=[],RG={name:"CcvPieChart",extends:lH,mounted:function(){this.coreChart=new eV(this.$el,{data:this.data,options:this.options})}},IG=RG,NG=sH(IG,kG,PG,!1,null,null,null),jG=NG.exports,BG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-scatter-chart"})},UG=[],VG={name:"CcvScatterChart",extends:lH,mounted:function(){this.coreChart=new XU(this.$el,{data:this.data,options:this.options})}},HG=VG,GG=sH(HG,BG,UG,!1,null,null,null),zG=GG.exports,FG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-meter-chart"})},WG=[],qG={name:"CcvMeterChart",extends:lH,mounted:function(){this.coreChart=new fV(this.$el,{data:this.data,options:this.options})}},$G=qG,YG=sH($G,FG,WG,!1,null,null,null),ZG=YG.exports,XG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-radar-chart"})},KG=[],QG={name:"CcvRadarChart",extends:lH,mounted:function(){this.coreChart=new mV(this.$el,{data:this.data,options:this.options})}},JG=QG,tz=sH(JG,XG,KG,!1,null,null,null),ez=tz.exports,nz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-combo-chart"})},rz=[],iz={name:"CcvComboChart",extends:lH,mounted:function(){this.coreChart=new SV(this.$el,{data:this.data,options:this.options})}},oz=iz,az=sH(oz,nz,rz,!1,null,null,null),sz=az.exports,uz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-tree-chart"})},lz=[],cz={name:"CcvTreeChart",extends:lH,mounted:function(){this.coreChart=new LV(this.$el,{data:this.data,options:this.options})}},hz=cz,fz=sH(hz,uz,lz,!1,null,null,null),pz=fz.exports,dz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-treemap-chart"})},vz=[],gz={name:"CcvTreemapChart",extends:lH,mounted:function(){this.coreChart=new RV(this.$el,{data:this.data,options:this.options})}},mz=gz,yz=sH(mz,dz,vz,!1,null,null,null),_z=yz.exports,bz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-circle-pack-chart"})},wz=[],Oz={name:"CcvCirclePackChart",extends:lH,mounted:function(){this.coreChart=new UV(this.$el,{data:this.data,options:this.options})}},xz=Oz,Ez=sH(xz,bz,wz,!1,null,null,null),Tz=Ez.exports,Sz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-wordcloud-chart"})},Mz=[],Cz={name:"CcvWordCloudChart",extends:lH,mounted:function(){this.coreChart=new FV(this.$el,{data:this.data,options:this.options})}},Az=Cz,Lz=sH(Az,Sz,Mz,!1,null,null,null),Dz=Lz.exports,kz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-alluvial-chart"})},Pz=[],Rz={name:"CcvAlluvialChart",extends:lH,mounted:function(){this.coreChart=new ZV(this.$el,{data:this.data,options:this.options})}},Iz=Rz,Nz=sH(Iz,kz,Pz,!1,null,null,null),jz=Nz.exports,Bz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-heatmap-chart"})},Uz=[],Vz={name:"CcvHeatmapChart",extends:lH,mounted:function(){this.coreChart=new iH(this.$el,{data:this.data,options:this.options})}},Hz=Vz,Gz=sH(Hz,Bz,Uz,!1,null,null,null),zz=Gz.exports,Fz=[pH,_H,TH,DH,jH,zH,ZH,eG,sG,pG,_G,TG,DG,jG,zG,ZG,ez,sz,pz,_z,Tz,Dz,jz,zz],Wz={install:function(t,e){if("undefined"===typeof e)for(var n=0,r=Fz;n<r.length;n++){var i=r[n];t.component(i.name,i)}else{if(!(e instanceof Array))throw new TypeError("options must be an array");for(var o=0,a=Fz;o<a.length;o++){var s=a[o];e.includes(s.name)&&t.component(s.name,s)}}}};e["default"]=Wz},"1d8a":function(t,e,n){var r=n("70b7"),i=0,o=Math.random(),a=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+a(++i+o,36)}},"1f5e":function(t,e,n){var r=n("378c"),i=n("9a0f"),o=n("0481"),a=function(t){return function(e,n,a){var s,u=r(e),l=o(u),c=i(a,l);if(t&&n!=n){while(l>c)if(s=u[c++],s!=s)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:a(!0),indexOf:a(!1)}},2402:function(t,e){e.f=Object.getOwnPropertySymbols},"2a3e":function(t,e,n){var r=n("da06"),i=String;t.exports=function(t){if("Symbol"===r(t))throw TypeError("Cannot convert a Symbol value to a string");return i(t)}},"2a60":function(t,e,n){var r=n("8320").dispatch,i=Math.PI/180,o=64,a=2048;function s(t){return t.text}function u(){return"serif"}function l(){return"normal"}function c(t){return Math.sqrt(t.value)}function h(){return 30*(~~(6*Math.random())-3)}function f(){return 1}function p(t,e,n,r){if(!e.sprite){var s=t.context,u=t.ratio;s.clearRect(0,0,(o<<5)/u,a/u);var l=0,c=0,h=0,f=n.length;--r;while(++r<f){e=n[r],s.save(),s.font=e.style+" "+e.weight+" "+~~((e.size+1)/u)+"px "+e.font;var p=s.measureText(e.text+"m").width*u,d=e.size<<1;if(e.rotate){var v=Math.sin(e.rotate*i),g=Math.cos(e.rotate*i),m=p*g,y=p*v,_=d*g,b=d*v;p=Math.max(Math.abs(m+b),Math.abs(m-b))+31>>5<<5,d=~~Math.max(Math.abs(y+_),Math.abs(y-_))}else p=p+31>>5<<5;if(d>h&&(h=d),l+p>=o<<5&&(l=0,c+=h,h=0),c+d>=a)break;s.translate((l+(p>>1))/u,(c+(d>>1))/u),e.rotate&&s.rotate(e.rotate*i),s.fillText(e.text,0,0),e.padding&&(s.lineWidth=2*e.padding,s.strokeText(e.text,0,0)),s.restore(),e.width=p,e.height=d,e.xoff=l,e.yoff=c,e.x1=p>>1,e.y1=d>>1,e.x0=-e.x1,e.y0=-e.y1,e.hasText=!0,l+=p}var w=s.getImageData(0,0,(o<<5)/u,a/u).data,O=[];while(--r>=0)if(e=n[r],e.hasText){p=e.width;for(var x=p>>5,E=(d=e.y1-e.y0,0);E<d*x;E++)O[E]=0;if(l=e.xoff,null==l)return;c=e.yoff;for(var T=0,S=-1,M=0;M<d;M++){for(E=0;E<p;E++){var C=x*M+(E>>5),A=w[(c+M)*(o<<5)+(l+E)<<2]?1<<31-E%32:0;O[C]|=A,T|=A}T?S=M:(e.y0++,d--,M--,c++)}e.y1=e.y0+S,e.sprite=O.slice(0,(e.y1-e.y0)*x)}}}function d(t,e,n){n>>=5;for(var r,i=t.sprite,o=t.width>>5,a=t.x-(o<<4),s=127&a,u=32-s,l=t.y1-t.y0,c=(t.y+t.y0)*n+(a>>5),h=0;h<l;h++){r=0;for(var f=0;f<=o;f++)if((r<<u|(f<o?(r=i[h*o+f])>>>s:0))&e[c+f])return!0;c+=n}return!1}function v(t,e){var n=t[0],r=t[1];e.x+e.x0<n.x&&(n.x=e.x+e.x0),e.y+e.y0<n.y&&(n.y=e.y+e.y0),e.x+e.x1>r.x&&(r.x=e.x+e.x1),e.y+e.y1>r.y&&(r.y=e.y+e.y1)}function g(t,e){return t.x+t.x1>e[0].x&&t.x+t.x0<e[1].x&&t.y+t.y1>e[0].y&&t.y+t.y0<e[1].y}function m(t){var e=t[0]/t[1];return function(t){return[e*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function y(t){var e=4,n=e*t[0]/t[1],r=0,i=0;return function(t){var o=t<0?-1:1;switch(Math.sqrt(1+4*o*t)-o&3){case 0:r+=n;break;case 1:i+=e;break;case 2:r-=n;break;default:i-=e;break}return[r,i]}}function _(t){var e=[],n=-1;while(++n<t)e[n]=0;return e}function b(){return document.createElement("canvas")}function w(t){return"function"===typeof t?t:function(){return t}}t.exports=function(){var t=[256,256],e=s,n=u,i=c,y=l,x=l,E=h,T=f,S=m,M=[],C=1/0,A=r("word","end"),L=null,D=Math.random,k={},P=b;function R(t){t.width=t.height=1;var e=Math.sqrt(t.getContext("2d").getImageData(0,0,1,1).data.length>>2);t.width=(o<<5)/e,t.height=a/e;var n=t.getContext("2d");return n.fillStyle=n.strokeStyle="red",n.textAlign="center",{context:n,ratio:e}}function I(e,n,r){t[0],t[1];var i,o,a,s=n.x,u=n.y,l=Math.sqrt(t[0]*t[0]+t[1]*t[1]),c=S(t),h=D()<.5?1:-1,f=-h;while(i=c(f+=h)){if(o=~~i[0],a=~~i[1],Math.min(Math.abs(o),Math.abs(a))>=l)break;if(n.x=s+o,n.y=u+a,!(n.x+n.x0<0||n.y+n.y0<0||n.x+n.x1>t[0]||n.y+n.y1>t[1])&&(!r||!d(n,e,t[0]))&&(!r||g(n,r))){for(var p,v=n.sprite,m=n.width>>5,y=t[0]>>5,_=n.x-(m<<4),b=127&_,w=32-b,O=n.y1-n.y0,x=(n.y+n.y0)*y+(_>>5),E=0;E<O;E++){p=0;for(var T=0;T<=m;T++)e[x+T]|=p<<w|(T<m?(p=v[E*m+T])>>>b:0);x+=y}return delete n.sprite,!0}}return!1}return k.canvas=function(t){return arguments.length?(P=w(t),k):P},k.start=function(){var r=R(P()),o=_((t[0]>>5)*t[1]),a=null,s=M.length,u=-1,l=[],c=M.map((function(t,r){return t.text=e.call(this,t,r),t.font=n.call(this,t,r),t.style=y.call(this,t,r),t.weight=x.call(this,t,r),t.rotate=E.call(this,t,r),t.size=~~i.call(this,t,r),t.padding=T.call(this,t,r),t})).sort((function(t,e){return e.size-t.size}));return L&&clearInterval(L),L=setInterval(h,0),h(),k;function h(){var e=Date.now();while(Date.now()-e<C&&++u<s&&L){var n=c[u];n.x=t[0]*(D()+.5)>>1,n.y=t[1]*(D()+.5)>>1,p(r,n,c,u),n.hasText&&I(o,n,a)&&(l.push(n),A.call("word",k,n),a?v(a,n):a=[{x:n.x+n.x0,y:n.y+n.y0},{x:n.x+n.x1,y:n.y+n.y1}],n.x-=t[0]>>1,n.y-=t[1]>>1)}u>=s&&(k.stop(),A.call("end",k,l,a))}},k.stop=function(){return L&&(clearInterval(L),L=null),k},k.timeInterval=function(t){return arguments.length?(C=null==t?1/0:t,k):C},k.words=function(t){return arguments.length?(M=t,k):M},k.size=function(e){return arguments.length?(t=[+e[0],+e[1]],k):t},k.font=function(t){return arguments.length?(n=w(t),k):n},k.fontStyle=function(t){return arguments.length?(y=w(t),k):y},k.fontWeight=function(t){return arguments.length?(x=w(t),k):x},k.rotate=function(t){return arguments.length?(E=w(t),k):E},k.text=function(t){return arguments.length?(e=w(t),k):e},k.spiral=function(t){return arguments.length?(S=O[t]||t,k):S},k.fontSize=function(t){return arguments.length?(i=w(t),k):i},k.padding=function(t){return arguments.length?(T=w(t),k):T},k.random=function(t){return arguments.length?(D=t,k):D},k.on=function(){var t=A.on.apply(A,arguments);return t===A?k:t},k};var O={archimedean:m,rectangular:y}},"2ce5":function(t,e,n){var r=n("70b7"),i=n("72df"),o=n("3ce8"),a=n("7a25"),s=n("d4cb"),u=n("d331").CONFIGURABLE,l=n("df6f"),c=n("cdcd"),h=c.enforce,f=c.get,p=String,d=Object.defineProperty,v=r("".slice),g=r("".replace),m=r([].join),y=s&&!i((function(){return 8!==d((function(){}),"length",{value:8}).length})),_=String(String).split("String"),b=t.exports=function(t,e,n){"Symbol("===v(p(e),0,7)&&(e="["+g(p(e),/^Symbol\(([^)]*)\)/,"$1")+"]"),n&&n.getter&&(e="get "+e),n&&n.setter&&(e="set "+e),(!a(t,"name")||u&&t.name!==e)&&(s?d(t,"name",{value:e,configurable:!0}):t.name=e),y&&n&&a(n,"arity")&&t.length!==n.arity&&d(t,"length",{value:n.arity});try{n&&a(n,"constructor")&&n.constructor?s&&d(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(i){}var r=h(t);return a(r,"source")||(r.source=m(_,"string"==typeof e?e:"")),t};Function.prototype.toString=b((function(){return o(this)&&f(this).source||l(this)}),"toString")},"2da1":function(t,e,n){"use strict";(function(t){var n=function(){if("undefined"!==typeof Map)return Map;function t(t,e){var n=-1;return t.some((function(t,r){return t[0]===e&&(n=r,!0)})),n}return function(){function e(){this.__entries__=[]}var n={size:{configurable:!0}};return n.size.get=function(){return this.__entries__.length},e.prototype.get=function(e){var n=t(this.__entries__,e),r=this.__entries__[n];return r&&r[1]},e.prototype.set=function(e,n){var r=t(this.__entries__,e);~r?this.__entries__[r][1]=n:this.__entries__.push([e,n])},e.prototype.delete=function(e){var n=this.__entries__,r=t(n,e);~r&&n.splice(r,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){var n=this;void 0===e&&(e=null);for(var r=0,i=n.__entries__;r<i.length;r+=1){var o=i[r];t.call(e,o[1],o[0])}},Object.defineProperties(e.prototype,n),e}()}(),r="undefined"!==typeof window&&"undefined"!==typeof document&&window.document===document,i=function(){return"undefined"!==typeof t&&t.Math===Math?t:"undefined"!==typeof self&&self.Math===Math?self:"undefined"!==typeof window&&window.Math===Math?window:Function("return this")()}(),o=function(){return"function"===typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)}}(),a=2,s=function(t,e){var n=!1,r=!1,i=0;function s(){n&&(n=!1,t()),r&&l()}function u(){o(s)}function l(){var t=Date.now();if(n){if(t-i<a)return;r=!0}else n=!0,r=!1,setTimeout(u,e);i=t}return l},u=20,l=["top","right","bottom","left","width","height","size","weight"],c="undefined"!==typeof MutationObserver,h=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=s(this.refresh.bind(this),u)};h.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},h.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},h.prototype.refresh=function(){var t=this.updateObservers_();t&&this.refresh()},h.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},h.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),c?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},h.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},h.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e="");var n=l.some((function(t){return!!~e.indexOf(t)}));n&&this.refresh()},h.getInstance=function(){return this.instance_||(this.instance_=new h),this.instance_},h.instance_=null;var f=function(t,e){for(var n=0,r=Object.keys(e);n<r.length;n+=1){var i=r[n];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},p=function(t){var e=t&&t.ownerDocument&&t.ownerDocument.defaultView;return e||i},d=E(0,0,0,0);function v(t){return parseFloat(t)||0}function g(t){var e=[],n=arguments.length-1;while(n-- >0)e[n]=arguments[n+1];return e.reduce((function(e,n){var r=t["border-"+n+"-width"];return e+v(r)}),0)}function m(t){for(var e=["top","right","bottom","left"],n={},r=0,i=e;r<i.length;r+=1){var o=i[r],a=t["padding-"+o];n[o]=v(a)}return n}function y(t){var e=t.getBBox();return E(0,0,e.width,e.height)}function _(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return d;var r=p(t).getComputedStyle(t),i=m(r),o=i.left+i.right,a=i.top+i.bottom,s=v(r.width),u=v(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=g(r,"left","right")+o),Math.round(u+a)!==n&&(u-=g(r,"top","bottom")+a)),!w(t)){var l=Math.round(s+o)-e,c=Math.round(u+a)-n;1!==Math.abs(l)&&(s-=l),1!==Math.abs(c)&&(u-=c)}return E(i.left,i.top,s,u)}var b=function(){return"undefined"!==typeof SVGGraphicsElement?function(t){return t instanceof p(t).SVGGraphicsElement}:function(t){return t instanceof p(t).SVGElement&&"function"===typeof t.getBBox}}();function w(t){return t===p(t).document.documentElement}function O(t){return r?b(t)?y(t):_(t):d}function x(t){var e=t.x,n=t.y,r=t.width,i=t.height,o="undefined"!==typeof DOMRectReadOnly?DOMRectReadOnly:Object,a=Object.create(o.prototype);return f(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}function E(t,e,n,r){return{x:t,y:e,width:n,height:r}}var T=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=E(0,0,0,0),this.target=t};T.prototype.isActive=function(){var t=O(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},T.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var S=function(t,e){var n=x(e);f(this,{target:t,contentRect:n})},M=function(t,e,r){if(this.activeObservations_=[],this.observations_=new n,"function"!==typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=r};M.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!==typeof Element&&Element instanceof Object){if(!(t instanceof p(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new T(t)),this.controller_.addObserver(this),this.controller_.refresh())}},M.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!==typeof Element&&Element instanceof Object){if(!(t instanceof p(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},M.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},M.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},M.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new S(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},M.prototype.clearActive=function(){this.activeObservations_.splice(0)},M.prototype.hasActive=function(){return this.activeObservations_.length>0};var C="undefined"!==typeof WeakMap?new WeakMap:new n,A=function(t){if(!(this instanceof A))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var e=h.getInstance(),n=new M(t,e,this);C.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){A.prototype[t]=function(){return(e=C.get(this))[t].apply(e,arguments);var e}}));var L=function(){return"undefined"!==typeof i.ResizeObserver?i.ResizeObserver:A}();e["a"]=L}).call(this,n("7d15"))},"332c":function(t,e,n){var r=n("4cdd"),i=n("1d8a"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},3606:function(t,e,n){"use strict";function r(t){return function(e,n){var r=String(e),a=n||{},s=a.width,u=s&&t.matchPatterns[s]||t.matchPatterns[t.defaultMatchWidth],l=r.match(u);if(!l)return null;var c,h=l[0],f=s&&t.parsePatterns[s]||t.parsePatterns[t.defaultParseWidth];return c="[object Array]"===Object.prototype.toString.call(f)?o(f,(function(t){return t.test(r)})):i(f,(function(t){return t.test(r)})),c=t.valueCallback?t.valueCallback(c):c,c=a.valueCallback?a.valueCallback(c):c,{value:c,rest:r.slice(h.length)}}}function i(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function o(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},"378c":function(t,e,n){var r=n("83a6"),i=n("730c");t.exports=function(t){return r(i(t))}},"37d1":function(t,e,n){var r=n("730c"),i=Object;t.exports=function(t){return i(r(t))}},"398c":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=i(n("910f"));function i(t){return t&&t.__esModule?t:{default:t}}var o={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},a={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},s={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},u={date:(0,r.default)({formats:o,defaultWidth:"full"}),time:(0,r.default)({formats:a,defaultWidth:"full"}),dateTime:(0,r.default)({formats:s,defaultWidth:"full"})},l=u;e.default=l,t.exports=e.default},"39ba":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=u(n("b128")),i=u(n("398c")),o=u(n("5cac")),a=u(n("7b70")),s=u(n("c9c9"));function u(t){return t&&t.__esModule?t:{default:t}}var l={code:"en-US",formatDistance:r.default,formatLong:i.default,formatRelative:o.default,localize:a.default,match:s.default,options:{weekStartsOn:0,firstWeekContainsDate:1}},c=l;e.default=c,t.exports=e.default},"3ce8":function(t,e,n){var r=n("be6c"),i=r.all;t.exports=r.IS_HTMLDDA?function(t){return"function"==typeof t||t===i}:function(t){return"function"==typeof t}},"3cec":function(t,e,n){var r=n("7d53"),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},"3e32":function(t,e,n){var r=n("7d53"),i=r("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[i]=!1,"/./"[t](e)}catch(r){}}return!1}},4141:function(t,e){(function(t){var e="currentScript",n=t.getElementsByTagName("script");e in t||Object.defineProperty(t,e,{get:function(){try{throw new Error}catch(r){var t,e=(/.*at [^\(]*\((.*):.+:.+\)$/gi.exec(r.stack)||[!1])[1];for(t in n)if(n[t].src==e||"interactive"==n[t].readyState)return n[t];return null}}})})(document)},"416d":function(t,e,n){var r=n("f498"),i=n("3ce8"),o=r.WeakMap;t.exports=i(o)&&/native code/.test(String(o))},"43f8":function(t,e,n){var r=n("72df");t.exports=!r((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))},4499:function(t,e,n){var r=n("f498"),i=Object.defineProperty;t.exports=function(t,e){try{i(r,t,{value:e,configurable:!0,writable:!0})}catch(n){r[t]=e}return e}},4912:function(t,e){var n=String;t.exports=function(t){try{return n(t)}catch(e){return"Object"}}},"4cdd":function(t,e,n){var r=n("0e93"),i=n("c607");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.30.1",mode:r?"pure":"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.30.1/LICENSE",source:"https://github.com/zloirock/core-js"})},"4cf0":function(t,e,n){"use strict";(function(t){var r=n("7f0d"),i=n("5711"),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=o&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===o,u=s?r["a"].Buffer:void 0,l=u?u.isBuffer:void 0,c=l||i["a"];e["a"]=c}).call(this,n("7326")(t))},"4db4":function(t,e,n){var r=n("cd51");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},"4fed":function(t,e,n){var r,i,o=n("f498"),a=n("64e4"),s=o.process,u=o.Deno,l=s&&s.versions||u&&u.version,c=l&&l.v8;c&&(r=c.split("."),i=r[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&a&&(r=a.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/),r&&(i=+r[1]))),t.exports=i},5428:function(t,e,n){var r=n("f498"),i=n("3ce8"),o=function(t){return i(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t]):r[t]&&r[t][e]}},5711:function(t,e,n){"use strict";function r(){return!1}e["a"]=r},"5ae7":function(t,e,n){"use strict";function r(t){return function(e,n){var r=String(e),i=n||{},o=r.match(t.matchPattern);if(!o)return null;var a=o[0],s=r.match(t.parsePattern);if(!s)return null;var u=t.valueCallback?t.valueCallback(s[0]):s[0];return u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(a.length)}}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},"5b12":function(t,e,n){var r=n("d4cb"),i=n("abdf"),o=n("9618");t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},"5cac":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=i;var r={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function i(t,e,n,i){return r[t]}t.exports=e.default},"60de":function(t,e,n){var r=n("63d3"),i=n("6566");t.exports=function(t,e){var n=t[e];return i(n)?void 0:r(n)}},"63d3":function(t,e,n){var r=n("3ce8"),i=n("4912"),o=TypeError;t.exports=function(t){if(r(t))return t;throw o(i(t)+" is not a function")}},"64e4":function(t,e){t.exports="undefined"!=typeof navigator&&String(navigator.userAgent)||""},6566:function(t,e){t.exports=function(t){return null===t||void 0===t}},"65d0":function(t,e,n){var r=n("c91c"),i=n("b17e"),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},"69f2":function(t,e,n){
|
|
1
|
+
(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["charts-vue"]=e():t["charts-vue"]=e()})("undefined"!==typeof self?self:this,(function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="1c25")}({"01ff":function(t,e,n){"use strict";(function(t){var r=n("92ae"),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i,s=a&&r["a"].process,u=function(){try{var t=o&&o.require&&o.require("util").types;return t||s&&s.binding&&s.binding("util")}catch(e){}}();e["a"]=u}).call(this,n("7326")(t))},"0481":function(t,e,n){var r=n("b495");t.exports=function(t){return r(t.length)}},"083f":function(t,e,n){var r=n("b546"),i=n("7526"),o=n("cfd1"),a=n("60de"),s=n("eba0"),u=n("7d53"),l=TypeError,c=u("toPrimitive");t.exports=function(t,e){if(!i(t)||o(t))return t;var n,u=a(t,c);if(u){if(void 0===e&&(e="default"),n=r(u,t,e),!i(n)||o(n))return n;throw l("Can't convert object to primitive value")}return void 0===e&&(e="number"),s(t,e)}},"0c47":function(t,e,n){var r=n("c91c"),i=n("b17e");t.exports=Object.keys||function(t){return r(t,i)}},"0e93":function(t,e){t.exports=!1},"157c":function(t,e,n){var r=n("7526"),i=String,o=TypeError;t.exports=function(t){if(r(t))return t;throw o(i(t)+" is not an object")}},"185a":function(t,e,n){var r=n("d4cb"),i=n("b546"),o=n("e129"),a=n("9618"),s=n("378c"),u=n("feca"),l=n("7a25"),c=n("7c3f"),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=s(t),e=u(e),c)try{return h(t,e)}catch(n){}if(l(t,e))return a(!i(o.f,t,e),t[e])}},"1c25":function(t,e,n){"use strict";n.r(e),n.d(e,"CcvAreaChart",(function(){return pH})),n.d(e,"CcvStackedAreaChart",(function(){return _H})),n.d(e,"CcvSimpleBarChart",(function(){return TH})),n.d(e,"CcvGroupedBarChart",(function(){return DH})),n.d(e,"CcvStackedBarChart",(function(){return jH})),n.d(e,"CcvBoxplotChart",(function(){return zH})),n.d(e,"CcvBubbleChart",(function(){return ZH})),n.d(e,"CcvBulletChart",(function(){return eG})),n.d(e,"CcvDonutChart",(function(){return sG})),n.d(e,"CcvGaugeChart",(function(){return pG})),n.d(e,"CcvHistogramChart",(function(){return _G})),n.d(e,"CcvLineChart",(function(){return TG})),n.d(e,"CcvLollipopChart",(function(){return DG})),n.d(e,"CcvPieChart",(function(){return jG})),n.d(e,"CcvScatterChart",(function(){return zG})),n.d(e,"CcvMeterChart",(function(){return ZG})),n.d(e,"CcvRadarChart",(function(){return ez})),n.d(e,"CcvComboChart",(function(){return sz})),n.d(e,"CcvTreeChart",(function(){return pz})),n.d(e,"CcvTreemapChart",(function(){return _z})),n.d(e,"CcvCirclePackChart",(function(){return Tz})),n.d(e,"CcvWordCloudChart",(function(){return Dz})),n.d(e,"CcvAlluvialChart",(function(){return jz})),n.d(e,"CcvHeatmapChart",(function(){return zz}));var r={};n.r(r),n.d(r,"Chart",(function(){return s})),n.d(r,"Modal",(function(){return u})),n.d(r,"Model",(function(){return l})),n.d(r,"Toolbar",(function(){return c})),n.d(r,"ZoomBar",(function(){return h})),n.d(r,"ZoomDomain",(function(){return f})),n.d(r,"CanvasZoom",(function(){return p})),n.d(r,"Axis",(function(){return d})),n.d(r,"Area",(function(){return v})),n.d(r,"WordCloud",(function(){return g})),n.d(r,"Pie",(function(){return m})),n.d(r,"Gauge",(function(){return y})),n.d(r,"Bar",(function(){return _})),n.d(r,"Boxplot",(function(){return b})),n.d(r,"Scatter",(function(){return w})),n.d(r,"Line",(function(){return O})),n.d(r,"Radar",(function(){return x})),n.d(r,"Tree",(function(){return E})),n.d(r,"Treemap",(function(){return T})),n.d(r,"Tooltip",(function(){return S})),n.d(r,"Threshold",(function(){return M})),n.d(r,"Legend",(function(){return C})),n.d(r,"CirclePack",(function(){return A})),n.d(r,"Alluvial",(function(){return L})),n.d(r,"Meter",(function(){return D})),n.d(r,"Heatmap",(function(){return k}));var i,o={};(n.r(o),n.d(o,"grid",(function(){return Vd})),n.d(o,"ruler",(function(){return Hd})),n.d(o,"baseTooltip",(function(){return Gd})),n.d(o,"timeScale",(function(){return Fd})),n.d(o,"options",(function(){return bv})),n.d(o,"carbonPrefix",(function(){return dt})),n.d(o,"area",(function(){return vt})),n.d(o,"axis",(function(){return gt})),n.d(o,"canvasZoomSettings",(function(){return mt})),n.d(o,"circlePack",(function(){return yt})),n.d(o,"color",(function(){return _t})),n.d(o,"boxplot",(function(){return bt})),n.d(o,"histogram",(function(){return wt})),n.d(o,"legend",(function(){return Ot})),n.d(o,"lines",(function(){return xt})),n.d(o,"meter",(function(){return Et})),n.d(o,"pie",(function(){return Tt})),n.d(o,"radar",(function(){return St})),n.d(o,"alluvial",(function(){return Mt})),n.d(o,"heatmap",(function(){return Ct})),n.d(o,"spacers",(function(){return At})),n.d(o,"tooltips",(function(){return Lt})),n.d(o,"transitions",(function(){return Dt})),n.d(o,"toolbar",(function(){return kt})),n.d(o,"zoomBar",(function(){return Pt})),n.d(o,"defaultLegendAdditionalItems",(function(){return Rt})),"undefined"!==typeof window)&&(n("4141"),(i=window.document.currentScript)&&(i=i.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(n.p=i[1]));n("868d"),n("8d0d"),n("c78b");var a,s,u,l,c,h,f,p,d,v,g,m,y,_,b,w,O,x,E,T,S,M,C,A,L,D,k,P=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-area-chart"})},R=[];(function(t){t["GRAPHICS_DOCUMENT"]="graphics-document",t["GRAPHICS_OBJECT"]="graphics-object",t["GRAPHICS_SYMBOL"]="graphics-symbol",t["GROUP"]="group",t["DOCUMENT"]="document",t["CHECKBOX"]="checkbox",t["BUTTON"]="button",t["MENU"]="menu",t["MENU_ITEM"]="menuitem",t["IMG"]="img"})(a||(a={})),function(t){t["RENDER_FINISHED"]="render-finished",t["RESIZE"]="chart-resize",t["MOUSEOVER"]="chart-mouseover",t["MOUSEOUT"]="chart-mouseout"}(s||(s={})),function(t){t["SHOW"]="show-modal",t["HIDE"]="hide-modal"}(u||(u={})),function(t){t["UPDATE"]="model-update"}(l||(l={})),function(t){t["SHOW_OVERFLOW_MENU"]="show-toolbar-overflow-menu",t["HIDE_OVERFLOW_MENU"]="hide-toolbar-overflow-menu",t["BUTTON_CLICK"]="toolbar-button-click"}(c||(c={})),function(t){t["UPDATE"]="zoom-bar-update",t["SELECTION_START"]="zoom-bar-selection-start",t["SELECTION_IN_PROGRESS"]="zoom-bar-selection-in-progress",t["SELECTION_END"]="zoom-bar-selection-end"}(h||(h={})),function(t){t["CHANGE"]="zoom-domain-change"}(f||(f={})),function(t){t["CANVAS_ZOOM_IN"]="canvas-zoom-in",t["CANVAS_ZOOM_OUT"]="canvas-zoom-out"}(p||(p={})),function(t){t["LABEL_MOUSEOVER"]="axis-label-mouseover",t["LABEL_MOUSEMOVE"]="axis-label-mousemove",t["LABEL_CLICK"]="axis-label-click",t["LABEL_MOUSEOUT"]="axis-label-mouseout",t["LABEL_FOCUS"]="axis-label-focus",t["LABEL_BLUR"]="axis-label-blur",t["RENDER_COMPLETE"]="axis-render-complete"}(d||(d={})),function(t){t["POINT_MOUSEOVER"]="scatter-mouseover",t["POINT_MOUSEMOVE"]="scatter-mousemove",t["POINT_CLICK"]="scatter-click",t["POINT_MOUSEOUT"]="scatter-mouseout"}(v||(v={})),function(t){t["WORD_MOUSEOVER"]="wordcloud-word-mouseover",t["WORD_MOUSEMOVE"]="wordcloud-word-mousemove",t["WORD_CLICK"]="wordcloud-word-click",t["WORD_MOUSEOUT"]="wordcloud-word-mouseout"}(g||(g={})),function(t){t["SLICE_MOUSEOVER"]="pie-slice-mouseover",t["SLICE_MOUSEMOVE"]="pie-slice-mousemove",t["SLICE_CLICK"]="pie-slice-click",t["SLICE_MOUSEOUT"]="pie-slice-mouseout"}(m||(m={})),function(t){t["ARC_MOUSEOVER"]="gauge-arc-mouseover",t["ARC_MOUSEMOVE"]="gauge-arc-mousemove",t["ARC_CLICK"]="gauge-arc-click",t["ARC_MOUSEOUT"]="gauge-arc-mouseout"}(y||(y={})),function(t){t["BAR_MOUSEOVER"]="bar-mouseover",t["BAR_MOUSEMOVE"]="bar-mousemove",t["BAR_CLICK"]="bar-click",t["BAR_MOUSEOUT"]="bar-mouseout"}(_||(_={})),function(t){t["BOX_MOUSEOVER"]="box-mouseover",t["BOX_MOUSEMOVE"]="box-mousemove",t["BOX_CLICK"]="box-click",t["BOX_MOUSEOUT"]="box-mouseout",t["OUTLIER_MOUSEOVER"]="outlier-mouseover",t["OUTLIER_MOUSEMOVE"]="outlier-mousemove",t["OUTLIER_CLICK"]="outlier-click",t["OUTLIER_MOUSEOUT"]="outlier-mouseout"}(b||(b={})),function(t){t["SCATTER_MOUSEOVER"]="scatter-mouseover",t["SCATTER_MOUSEMOVE"]="scatter-mousemove",t["SCATTER_CLICK"]="scatter-click",t["SCATTER_MOUSEOUT"]="scatter-mouseout"}(w||(w={})),function(t){t["POINT_MOUSEOVER"]="scatter-mouseover",t["POINT_MOUSEMOVE"]="scatter-mousemove",t["POINT_CLICK"]="scatter-click",t["POINT_MOUSEOUT"]="scatter-mouseout"}(O||(O={})),function(t){t["X_AXIS_MOUSEOVER"]="radar-x-axis-mouseover",t["X_AXIS_MOUSEMOVE"]="radar-x-axis-mousemove",t["X_AXIS_CLICK"]="radar-x-axis-click",t["X_AXIS_MOUSEOUT"]="radar-x-axis-mouseout"}(x||(x={})),function(t){t["NODE_MOUSEOVER"]="tree-node-mouseover",t["NODE_CLICK"]="tree-node-click",t["NODE_MOUSEOUT"]="tree-node-mouseout"}(E||(E={})),function(t){t["LEAF_MOUSEOVER"]="leaf-mouseover",t["LEAF_MOUSEMOVE"]="leaf-mousemove",t["LEAF_CLICK"]="leaf-click",t["LEAF_MOUSEOUT"]="leaf-mouseout"}(T||(T={})),function(t){t["SHOW"]="show-tooltip",t["MOVE"]="move-tooltip",t["HIDE"]="hide-tooltip"}(S||(S={})),function(t){t["SHOW"]="show-threshold",t["HIDE"]="hide-threshold"}(M||(M={})),function(t){t["ITEM_HOVER"]="legend-item-onhover",t["ITEM_CLICK"]="legend-item-onclick",t["ITEM_MOUSEOUT"]="legend-item-onmouseout",t["ITEMS_UPDATE"]="legend-items-update"}(C||(C={})),function(t){t["CIRCLE_MOUSEOVER"]="circle-leaf-mouseover",t["CIRCLE_CLICK"]="circle-leaf-click",t["CIRCLE_MOUSEOUT"]="circle-leaf-mouseout",t["CIRCLE_MOUSEMOVE"]="circle-leaf-mousemove"}(A||(A={})),function(t){t["NODE_MOUSEOVER"]="alluvial-node-mouseover",t["NODE_CLICK"]="alluvial-node-click",t["NODE_MOUSEOUT"]="alluvial-node-mouseout",t["NODE_MOUSEMOVE"]="alluvial-node-mousemove",t["LINE_MOUSEOVER"]="alluvial-line-mouseover",t["LINE_CLICK"]="alluvial-line-click",t["LINE_MOUSEOUT"]="alluvial-line-mouseout",t["LINE_MOUSEMOVE"]="alluvial-line-mousemove"}(L||(L={})),function(t){t["METER_MOUSEOVER"]="meter-mouseover",t["METER_CLICK"]="meter-click",t["METER_MOUSEOUT"]="meter-mouseout",t["METER_MOUSEMOVE"]="meter-mousemove"}(D||(D={})),function(t){t["HEATMAP_MOUSEOVER"]="heatmap-mouseover",t["HEATMAP_CLICK"]="heatmap-click",t["HEATMAP_MOUSEOUT"]="heatmap-mouseout",t["HEATMAP_MOUSEMOVE"]="hetmap-mousemove"}(k||(k={}));var I,N,j,B,U,V,H,G,z,F,W,q,$,Y,Z,X,K,Q,J,tt,et,nt,rt,it,ot,at,st,ut,lt,ct,ht,ft=r;function pt(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}(function(t){t["HTML"]="html",t["SVG"]="svg"})(I||(I={})),function(t){t["WHITE"]="white",t["G100"]="g100",t["G90"]="g90",t["G10"]="g10"}(N||(N={})),function(t){t["BACKGROUND"]="background",t["FILL"]="fill",t["STROKE"]="stroke",t["TOOLTIP"]="tooltip"}(j||(j={})),function(t){t["LEFT"]="left",t["RIGHT"]="right",t["TOP"]="top",t["BOTTOM"]="bottom"}(B||(B={})),function(t){t["GRAPH_VIEW"]="graph_view",t["SLIDER_VIEW"]="slider_view"}(U||(U={})),function(t){t["END_LINE"]="end_line",t["MID_LINE"]="mid_line",t["FRONT_LINE"]="front_line",t["NONE"]="none"}(V||(V={})),function(t){t["VERTICAL"]="vertical",t["HORIZONTAL"]="horizontal"}(H||(H={})),function(t){t["TIME"]="time",t["LINEAR"]="linear",t["LOG"]="log",t["LABELS"]="labels",t["LABELS_RATIO"]="labels-ratio"}(G||(G={})),function(t){t["RIGHT"]="right",t["LEFT"]="left",t["TOP"]="top",t["BOTTOM"]="bottom"}(z||(z={})),function(t){t["LEFT"]="left",t["CENTER"]="center",t["RIGHT"]="right"}(F||(F={})),function(t){t["HORIZONTAL"]="horizontal",t["VERTICAL"]="vertical"}(W||(W={})),function(t){t["TREE"]="tree",t["DENDROGRAM"]="dendrogram"}(q||(q={})),function(t){t["ROW"]="row",t["COLUMN"]="column",t["ROW_REVERSE"]="row-reverse",t["COLUMN_REVERSE"]="column-reverse"}($||($={})),function(t){t["FIXED"]="fixed",t["PREFERRED"]="preferred",t["STRETCH"]="stretch"}(Y||(Y={})),function(t){t["CENTER"]="center"}(Z||(Z={})),function(t){t["LEFT"]="left",t["RIGHT"]="right"}(X||(X={})),function(t){t["GRID"]="grid",t["VERT_OR_HORIZ"]="vertOrHoriz",t["PIE"]="pie",t["DONUT"]="donut"}(K||(K={})),function(t){t["START"]="start",t["MIDDLE"]="middle",t["END"]="end"}(Q||(Q={})),function(t){t["BASELINE"]="baseline",t["MIDDLE"]="middle",t["HANGING"]="hanging"}(J||(J={})),function(t){t["SEMI"]="semi",t["FULL"]="full"}(tt||(tt={})),function(t){t["UP"]="up",t["DOWN"]="down"}(et||(et={})),function(t){t["SUCCESS"]="success",t["WARNING"]="warning",t["DANGER"]="danger"}(nt||(nt={})),function(t){t["ALWAYS"]="always",t["AUTO"]="auto",t["NEVER"]="never"}(rt||(rt={})),function(t){t["SCATTER"]="scatter",t["LINE"]="line",t["SIMPLE_BAR"]="simple-bar",t["STACKED_BAR"]="stacked-bar",t["GROUPED_BAR"]="grouped-bar",t["AREA"]="area",t["STACKED_AREA"]="stacked-area"}(it||(it={})),function(t){t["EXPORT_CSV"]="Export as CSV",t["EXPORT_PNG"]="Export as PNG",t["EXPORT_JPG"]="Export as JPG",t["ZOOM_IN"]="Zoom in",t["ZOOM_OUT"]="Zoom out",t["RESET_ZOOM"]="Reset zoom",t["MAKE_FULLSCREEN"]="Make fullscreen",t["SHOW_AS_DATATABLE"]="Show as data-table",t["CUSTOM"]="Custom"}(ot||(ot={})),function(t){t["LEFT"]="left",t["RIGHT"]="right"}(at||(at={})),function(t){t["CHECKBOX"]="checkbox",t["RADIUS"]="radius",t["AREA"]="area",t["SIZE"]="size",t["LINE"]="line",t["QUARTILE"]="quartile",t["ZOOM"]="zoom"}(st||(st={})),function(t){t["LINEAR"]="linear",t["QUANTIZE"]="quantize"}(ut||(ut={})),function(t){t["ON"]="on",t["AUTO"]="auto",t["OFF"]="off"}(lt||(lt={})),function(t){t["DEFAULT"]="default",t["HOVERABLE"]="hoverable"}(ct||(ct={}));var dt="cds",vt={opacity:{unselected:.05,selected:.4}},gt={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1,hover:{rectanglePadding:4}},mt={duration:1e3,ease:pt,zoomLevel:3},yt={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},_t={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},bt={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},wt={defaultBins:10},Ot={items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8,spaceAfter:4},checkbox:{radius:6.5},radius:{iconData:[{cx:7,cy:7,r:6.5},{cx:7,cy:10,r:3.5}],fill:null,stroke:"#8c8c8c"},line:{yPosition:6,width:24,strokeWidth:1.4,fill:null,stroke:"#999999"},area:{width:24,height:14,fill:"#6f6f6f",stroke:null},size:{iconData:[{width:23,height:12},{width:13,height:6}],fill:null,stroke:"#8D8D8D"},quartile:{iconData:[{x:0,y:0,width:24,height:13},{x:11,y:4,width:1,height:4}]},zoom:{iconData:[{x:0,y:0,width:12,height:12}],color:"#8D8D8D"},color:{barWidth:300,barHeight:8,axisYTranslation:10}},xt={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},Et={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15},total:{paddingLeft:36,paddingRight:24},height:{default:8,proportional:16},dividerWidth:2},Tt={radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2}},St={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},Mt={nodeWidth:4,nodeHoveredWidth:8,minNodePadding:24,opacity:{unfocus:.3,default:.8,selected:1}},Ct={minCellDividerDimension:16,chartPadding:.5},At={default:{size:24}},Lt={horizontalOffset:10},Dt={default:{duration:300},pie_slice_mouseover:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},kt={buttonSize:32,iconSize:20,height:32,spacerHeight:10,iconPadding:6},Pt={height:(ht={},ht[U.GRAPH_VIEW]=32,ht[U.SLIDER_VIEW]=10,ht),spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},Rt=[{type:st.RADIUS,name:"Radius"},{type:st.AREA,name:"Poor area"},{type:st.AREA,name:"Satisfactory area"},{type:st.AREA,name:"Great area"},{type:st.QUARTILE,name:"Quartiles"}];function It(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Nt=It,jt=n("7f0d"),Bt=function(){return jt["a"].Date.now()},Ut=Bt,Vt=/\s/;function Ht(t){var e=t.length;while(e--&&Vt.test(t.charAt(e)));return e}var Gt=Ht,zt=/^\s+/;function Ft(t){return t?t.slice(0,Gt(t)+1).replace(zt,""):t}var Wt=Ft,qt=jt["a"].Symbol,$t=qt,Yt=Object.prototype,Zt=Yt.hasOwnProperty,Xt=Yt.toString,Kt=$t?$t.toStringTag:void 0;function Qt(t){var e=Zt.call(t,Kt),n=t[Kt];try{t[Kt]=void 0;var r=!0}catch(o){}var i=Xt.call(t);return r&&(e?t[Kt]=n:delete t[Kt]),i}var Jt=Qt,te=Object.prototype,ee=te.toString;function ne(t){return ee.call(t)}var re=ne,ie="[object Null]",oe="[object Undefined]",ae=$t?$t.toStringTag:void 0;function se(t){return null==t?void 0===t?oe:ie:ae&&ae in Object(t)?Jt(t):re(t)}var ue=se;function le(t){return null!=t&&"object"==typeof t}var ce=le,he="[object Symbol]";function fe(t){return"symbol"==typeof t||ce(t)&&ue(t)==he}var pe=fe,de=NaN,ve=/^[-+]0x[0-9a-f]+$/i,ge=/^0b[01]+$/i,me=/^0o[0-7]+$/i,ye=parseInt;function _e(t){if("number"==typeof t)return t;if(pe(t))return de;if(Nt(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Nt(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Wt(t);var n=ge.test(t);return n||me.test(t)?ye(t.slice(2),n?2:8):ve.test(t)?de:+t}var be=_e,we="Expected a function",Oe=Math.max,xe=Math.min;function Ee(t,e,n){var r,i,o,a,s,u,l=0,c=!1,h=!1,f=!0;if("function"!=typeof t)throw new TypeError(we);function p(e){var n=r,o=i;return r=i=void 0,l=e,a=t.apply(o,n),a}function d(t){return l=t,s=setTimeout(m,e),c?p(t):a}function v(t){var n=t-u,r=t-l,i=e-n;return h?xe(i,o-r):i}function g(t){var n=t-u,r=t-l;return void 0===u||n>=e||n<0||h&&r>=o}function m(){var t=Ut();if(g(t))return y(t);s=setTimeout(m,v(t))}function y(t){return s=void 0,f&&r?p(t):(r=i=void 0,a)}function _(){void 0!==s&&clearTimeout(s),l=0,r=u=i=s=void 0}function b(){return void 0===s?a:y(Ut())}function w(){var t=Ut(),n=g(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return d(u);if(h)return clearTimeout(s),s=setTimeout(m,e),p(u)}return void 0===s&&(s=setTimeout(m,e)),a}return e=be(e)||0,Nt(n)&&(c=!!n.leading,h="maxWait"in n,o=h?Oe(be(n.maxWait)||0,e):o,f="trailing"in n?!!n.trailing:f),w.cancel=_,w.flush=b,w}var Te=Ee;function Se(){this.__data__=[],this.size=0}var Me=Se;function Ce(t,e){return t===e||t!==t&&e!==e}var Ae=Ce;function Le(t,e){var n=t.length;while(n--)if(Ae(t[n][0],e))return n;return-1}var De=Le,ke=Array.prototype,Pe=ke.splice;function Re(t){var e=this.__data__,n=De(e,t);if(n<0)return!1;var r=e.length-1;return n==r?e.pop():Pe.call(e,n,1),--this.size,!0}var Ie=Re;function Ne(t){var e=this.__data__,n=De(e,t);return n<0?void 0:e[n][1]}var je=Ne;function Be(t){return De(this.__data__,t)>-1}var Ue=Be;function Ve(t,e){var n=this.__data__,r=De(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}var He=Ve;function Ge(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}Ge.prototype.clear=Me,Ge.prototype["delete"]=Ie,Ge.prototype.get=je,Ge.prototype.has=Ue,Ge.prototype.set=He;var ze=Ge;function Fe(){this.__data__=new ze,this.size=0}var We=Fe;function qe(t){var e=this.__data__,n=e["delete"](t);return this.size=e.size,n}var $e=qe;function Ye(t){return this.__data__.get(t)}var Ze=Ye;function Xe(t){return this.__data__.has(t)}var Ke=Xe,Qe="[object AsyncFunction]",Je="[object Function]",tn="[object GeneratorFunction]",en="[object Proxy]";function nn(t){if(!Nt(t))return!1;var e=ue(t);return e==Je||e==tn||e==Qe||e==en}var rn=nn,on=jt["a"]["__core-js_shared__"],an=on,sn=function(){var t=/[^.]+$/.exec(an&&an.keys&&an.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function un(t){return!!sn&&sn in t}var ln=un,cn=Function.prototype,hn=cn.toString;function fn(t){if(null!=t){try{return hn.call(t)}catch(e){}try{return t+""}catch(e){}}return""}var pn=fn,dn=/[\\^$.*+?()[\]{}|]/g,vn=/^\[object .+?Constructor\]$/,gn=Function.prototype,mn=Object.prototype,yn=gn.toString,_n=mn.hasOwnProperty,bn=RegExp("^"+yn.call(_n).replace(dn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function wn(t){if(!Nt(t)||ln(t))return!1;var e=rn(t)?bn:vn;return e.test(pn(t))}var On=wn;function xn(t,e){return null==t?void 0:t[e]}var En=xn;function Tn(t,e){var n=En(t,e);return On(n)?n:void 0}var Sn=Tn,Mn=Sn(jt["a"],"Map"),Cn=Mn,An=Sn(Object,"create"),Ln=An;function Dn(){this.__data__=Ln?Ln(null):{},this.size=0}var kn=Dn;function Pn(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var Rn=Pn,In="__lodash_hash_undefined__",Nn=Object.prototype,jn=Nn.hasOwnProperty;function Bn(t){var e=this.__data__;if(Ln){var n=e[t];return n===In?void 0:n}return jn.call(e,t)?e[t]:void 0}var Un=Bn,Vn=Object.prototype,Hn=Vn.hasOwnProperty;function Gn(t){var e=this.__data__;return Ln?void 0!==e[t]:Hn.call(e,t)}var zn=Gn,Fn="__lodash_hash_undefined__";function Wn(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Ln&&void 0===e?Fn:e,this}var qn=Wn;function $n(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}$n.prototype.clear=kn,$n.prototype["delete"]=Rn,$n.prototype.get=Un,$n.prototype.has=zn,$n.prototype.set=qn;var Yn=$n;function Zn(){this.size=0,this.__data__={hash:new Yn,map:new(Cn||ze),string:new Yn}}var Xn=Zn;function Kn(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}var Qn=Kn;function Jn(t,e){var n=t.__data__;return Qn(e)?n["string"==typeof e?"string":"hash"]:n.map}var tr=Jn;function er(t){var e=tr(this,t)["delete"](t);return this.size-=e?1:0,e}var nr=er;function rr(t){return tr(this,t).get(t)}var ir=rr;function or(t){return tr(this,t).has(t)}var ar=or;function sr(t,e){var n=tr(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this}var ur=sr;function lr(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e<n){var r=t[e];this.set(r[0],r[1])}}lr.prototype.clear=Xn,lr.prototype["delete"]=nr,lr.prototype.get=ir,lr.prototype.has=ar,lr.prototype.set=ur;var cr=lr,hr=200;function fr(t,e){var n=this.__data__;if(n instanceof ze){var r=n.__data__;if(!Cn||r.length<hr-1)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new cr(r)}return n.set(t,e),this.size=n.size,this}var pr=fr;function dr(t){var e=this.__data__=new ze(t);this.size=e.size}dr.prototype.clear=We,dr.prototype["delete"]=$e,dr.prototype.get=Ze,dr.prototype.has=Ke,dr.prototype.set=pr;var vr=dr,gr=function(){try{var t=Sn(Object,"defineProperty");return t({},"",{}),t}catch(e){}}(),mr=gr;function yr(t,e,n){"__proto__"==e&&mr?mr(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}var _r=yr;function br(t,e,n){(void 0!==n&&!Ae(t[e],n)||void 0===n&&!(e in t))&&_r(t,e,n)}var wr=br;function Or(t){return function(e,n,r){var i=-1,o=Object(e),a=r(e),s=a.length;while(s--){var u=a[t?s:++i];if(!1===n(o[u],u,o))break}return e}}var xr=Or,Er=xr(),Tr=Er,Sr=n("d6f0"),Mr=jt["a"].Uint8Array,Cr=Mr;function Ar(t){var e=new t.constructor(t.byteLength);return new Cr(e).set(new Cr(t)),e}var Lr=Ar;function Dr(t,e){var n=e?Lr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}var kr=Dr;function Pr(t,e){var n=-1,r=t.length;e||(e=Array(r));while(++n<r)e[n]=t[n];return e}var Rr=Pr,Ir=Object.create,Nr=function(){function t(){}return function(e){if(!Nt(e))return{};if(Ir)return Ir(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}(),jr=Nr;function Br(t,e){return function(n){return t(e(n))}}var Ur=Br,Vr=Ur(Object.getPrototypeOf,Object),Hr=Vr,Gr=Object.prototype;function zr(t){var e=t&&t.constructor,n="function"==typeof e&&e.prototype||Gr;return t===n}var Fr=zr;function Wr(t){return"function"!=typeof t.constructor||Fr(t)?{}:jr(Hr(t))}var qr=Wr,$r="[object Arguments]";function Yr(t){return ce(t)&&ue(t)==$r}var Zr=Yr,Xr=Object.prototype,Kr=Xr.hasOwnProperty,Qr=Xr.propertyIsEnumerable,Jr=Zr(function(){return arguments}())?Zr:function(t){return ce(t)&&Kr.call(t,"callee")&&!Qr.call(t,"callee")},ti=Jr,ei=Array.isArray,ni=ei,ri=9007199254740991;function ii(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=ri}var oi=ii;function ai(t){return null!=t&&oi(t.length)&&!rn(t)}var si=ai;function ui(t){return ce(t)&&si(t)}var li=ui,ci=n("4cf0"),hi="[object Object]",fi=Function.prototype,pi=Object.prototype,di=fi.toString,vi=pi.hasOwnProperty,gi=di.call(Object);function mi(t){if(!ce(t)||ue(t)!=hi)return!1;var e=Hr(t);if(null===e)return!0;var n=vi.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&di.call(n)==gi}var yi=mi,_i="[object Arguments]",bi="[object Array]",wi="[object Boolean]",Oi="[object Date]",xi="[object Error]",Ei="[object Function]",Ti="[object Map]",Si="[object Number]",Mi="[object Object]",Ci="[object RegExp]",Ai="[object Set]",Li="[object String]",Di="[object WeakMap]",ki="[object ArrayBuffer]",Pi="[object DataView]",Ri="[object Float32Array]",Ii="[object Float64Array]",Ni="[object Int8Array]",ji="[object Int16Array]",Bi="[object Int32Array]",Ui="[object Uint8Array]",Vi="[object Uint8ClampedArray]",Hi="[object Uint16Array]",Gi="[object Uint32Array]",zi={};function Fi(t){return ce(t)&&oi(t.length)&&!!zi[ue(t)]}zi[Ri]=zi[Ii]=zi[Ni]=zi[ji]=zi[Bi]=zi[Ui]=zi[Vi]=zi[Hi]=zi[Gi]=!0,zi[_i]=zi[bi]=zi[ki]=zi[wi]=zi[Pi]=zi[Oi]=zi[xi]=zi[Ei]=zi[Ti]=zi[Si]=zi[Mi]=zi[Ci]=zi[Ai]=zi[Li]=zi[Di]=!1;var Wi=Fi;function qi(t){return function(e){return t(e)}}var $i=qi,Yi=n("01ff"),Zi=Yi["a"]&&Yi["a"].isTypedArray,Xi=Zi?$i(Zi):Wi,Ki=Xi;function Qi(t,e){if(("constructor"!==e||"function"!==typeof t[e])&&"__proto__"!=e)return t[e]}var Ji=Qi,to=Object.prototype,eo=to.hasOwnProperty;function no(t,e,n){var r=t[e];eo.call(t,e)&&Ae(r,n)&&(void 0!==n||e in t)||_r(t,e,n)}var ro=no;function io(t,e,n,r){var i=!n;n||(n={});var o=-1,a=e.length;while(++o<a){var s=e[o],u=r?r(n[s],t[s],s,n,t):void 0;void 0===u&&(u=t[s]),i?_r(n,s,u):ro(n,s,u)}return n}var oo=io;function ao(t,e){var n=-1,r=Array(t);while(++n<t)r[n]=e(n);return r}var so=ao,uo=9007199254740991,lo=/^(?:0|[1-9]\d*)$/;function co(t,e){var n=typeof t;return e=null==e?uo:e,!!e&&("number"==n||"symbol"!=n&&lo.test(t))&&t>-1&&t%1==0&&t<e}var ho=co,fo=Object.prototype,po=fo.hasOwnProperty;function vo(t,e){var n=ni(t),r=!n&&ti(t),i=!n&&!r&&Object(ci["a"])(t),o=!n&&!r&&!i&&Ki(t),a=n||r||i||o,s=a?so(t.length,String):[],u=s.length;for(var l in t)!e&&!po.call(t,l)||a&&("length"==l||i&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||ho(l,u))||s.push(l);return s}var go=vo;function mo(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}var yo=mo,_o=Object.prototype,bo=_o.hasOwnProperty;function wo(t){if(!Nt(t))return yo(t);var e=Fr(t),n=[];for(var r in t)("constructor"!=r||!e&&bo.call(t,r))&&n.push(r);return n}var Oo=wo;function xo(t){return si(t)?go(t,!0):Oo(t)}var Eo=xo;function To(t){return oo(t,Eo(t))}var So=To;function Mo(t,e,n,r,i,o,a){var s=Ji(t,n),u=Ji(e,n),l=a.get(u);if(l)wr(t,n,l);else{var c=o?o(s,u,n+"",t,e,a):void 0,h=void 0===c;if(h){var f=ni(u),p=!f&&Object(ci["a"])(u),d=!f&&!p&&Ki(u);c=u,f||p||d?ni(s)?c=s:li(s)?c=Rr(s):p?(h=!1,c=Object(Sr["a"])(u,!0)):d?(h=!1,c=kr(u,!0)):c=[]:yi(u)||ti(u)?(c=s,ti(s)?c=So(s):Nt(s)&&!rn(s)||(c=qr(u))):h=!1}h&&(a.set(u,c),i(c,u,r,o,a),a["delete"](u)),wr(t,n,c)}}var Co=Mo;function Ao(t,e,n,r,i){t!==e&&Tr(e,(function(o,a){if(i||(i=new vr),Nt(o))Co(t,e,a,n,Ao,r,i);else{var s=r?r(Ji(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),wr(t,a,s)}}),Eo)}var Lo=Ao;function Do(t){return t}var ko=Do;function Po(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}var Ro=Po,Io=Math.max;function No(t,e,n){return e=Io(void 0===e?t.length-1:e,0),function(){var r=arguments,i=-1,o=Io(r.length-e,0),a=Array(o);while(++i<o)a[i]=r[e+i];i=-1;var s=Array(e+1);while(++i<e)s[i]=r[i];return s[e]=n(a),Ro(t,this,s)}}var jo=No;function Bo(t){return function(){return t}}var Uo=Bo,Vo=mr?function(t,e){return mr(t,"toString",{configurable:!0,enumerable:!1,value:Uo(e),writable:!0})}:ko,Ho=Vo,Go=800,zo=16,Fo=Date.now;function Wo(t){var e=0,n=0;return function(){var r=Fo(),i=zo-(r-n);if(n=r,i>0){if(++e>=Go)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var qo=Wo,$o=qo(Ho),Yo=$o;function Zo(t,e){return Yo(jo(t,e,ko),t+"")}var Xo=Zo;function Ko(t,e,n){if(!Nt(n))return!1;var r=typeof e;return!!("number"==r?si(n)&&ho(e,n.length):"string"==r&&e in n)&&Ae(n[e],t)}var Qo=Ko;function Jo(t){return Xo((function(e,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;o=t.length>3&&"function"==typeof o?(i--,o):void 0,a&&Qo(n[0],n[1],a)&&(o=i<3?void 0:o,i=1),e=Object(e);while(++r<i){var s=n[r];s&&t(e,s,r,o)}return e}))}var ta=Jo,ea=ta((function(t,e,n){Lo(t,e,n)})),na=ea;function ra(t,e,n){return t===t&&(void 0!==n&&(t=t<=n?t:n),void 0!==e&&(t=t>=e?t:e)),t}var ia=ra;function oa(t,e,n){return void 0===n&&(n=e,e=void 0),void 0!==n&&(n=be(n),n=n===n?n:0),void 0!==e&&(e=be(e),e=e===e?e:0),ia(be(t),e,n)}var aa=oa;function sa(t,e){var n=-1,r=e.length,i=t.length;while(++n<r)t[i+n]=e[n];return t}var ua=sa,la=$t?$t.isConcatSpreadable:void 0;function ca(t){return ni(t)||ti(t)||!!(la&&t&&t[la])}var ha=ca;function fa(t,e,n,r,i){var o=-1,a=t.length;n||(n=ha),i||(i=[]);while(++o<a){var s=t[o];e>0&&n(s)?e>1?fa(s,e-1,n,r,i):ua(i,s):r||(i[i.length]=s)}return i}var pa=fa;function da(t){var e=null==t?0:t.length;return e?pa(t,1):[]}var va=da;function ga(t,e,n,r){var i=-1,o=null==t?0:t.length;while(++i<o){var a=t[i];e(r,a,n(a),t)}return r}var ma=ga,ya=Ur(Object.keys,Object),_a=ya,ba=Object.prototype,wa=ba.hasOwnProperty;function Oa(t){if(!Fr(t))return _a(t);var e=[];for(var n in Object(t))wa.call(t,n)&&"constructor"!=n&&e.push(n);return e}var xa=Oa;function Ea(t){return si(t)?go(t):xa(t)}var Ta=Ea;function Sa(t,e){return t&&Tr(t,e,Ta)}var Ma=Sa;function Ca(t,e){return function(n,r){if(null==n)return n;if(!si(n))return t(n,r);var i=n.length,o=e?i:-1,a=Object(n);while(e?o--:++o<i)if(!1===r(a[o],o,a))break;return n}}var Aa=Ca,La=Aa(Ma),Da=La;function ka(t,e,n,r){return Da(t,(function(t,i,o){e(r,t,n(t),o)})),r}var Pa=ka,Ra="__lodash_hash_undefined__";function Ia(t){return this.__data__.set(t,Ra),this}var Na=Ia;function ja(t){return this.__data__.has(t)}var Ba=ja;function Ua(t){var e=-1,n=null==t?0:t.length;this.__data__=new cr;while(++e<n)this.add(t[e])}Ua.prototype.add=Ua.prototype.push=Na,Ua.prototype.has=Ba;var Va=Ua;function Ha(t,e){var n=-1,r=null==t?0:t.length;while(++n<r)if(e(t[n],n,t))return!0;return!1}var Ga=Ha;function za(t,e){return t.has(e)}var Fa=za,Wa=1,qa=2;function $a(t,e,n,r,i,o){var a=n&Wa,s=t.length,u=e.length;if(s!=u&&!(a&&u>s))return!1;var l=o.get(t),c=o.get(e);if(l&&c)return l==e&&c==t;var h=-1,f=!0,p=n&qa?new Va:void 0;o.set(t,e),o.set(e,t);while(++h<s){var d=t[h],v=e[h];if(r)var g=a?r(v,d,h,e,t,o):r(d,v,h,t,e,o);if(void 0!==g){if(g)continue;f=!1;break}if(p){if(!Ga(e,(function(t,e){if(!Fa(p,e)&&(d===t||i(d,t,n,r,o)))return p.push(e)}))){f=!1;break}}else if(d!==v&&!i(d,v,n,r,o)){f=!1;break}}return o["delete"](t),o["delete"](e),f}var Ya=$a;function Za(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}var Xa=Za;function Ka(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var Qa=Ka,Ja=1,ts=2,es="[object Boolean]",ns="[object Date]",rs="[object Error]",is="[object Map]",os="[object Number]",as="[object RegExp]",ss="[object Set]",us="[object String]",ls="[object Symbol]",cs="[object ArrayBuffer]",hs="[object DataView]",fs=$t?$t.prototype:void 0,ps=fs?fs.valueOf:void 0;function ds(t,e,n,r,i,o,a){switch(n){case hs:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case cs:return!(t.byteLength!=e.byteLength||!o(new Cr(t),new Cr(e)));case es:case ns:case os:return Ae(+t,+e);case rs:return t.name==e.name&&t.message==e.message;case as:case us:return t==e+"";case is:var s=Xa;case ss:var u=r&Ja;if(s||(s=Qa),t.size!=e.size&&!u)return!1;var l=a.get(t);if(l)return l==e;r|=ts,a.set(t,e);var c=Ya(s(t),s(e),r,i,o,a);return a["delete"](t),c;case ls:if(ps)return ps.call(t)==ps.call(e)}return!1}var vs=ds;function gs(t,e,n){var r=e(t);return ni(t)?r:ua(r,n(t))}var ms=gs;function ys(t,e){var n=-1,r=null==t?0:t.length,i=0,o=[];while(++n<r){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}var _s=ys;function bs(){return[]}var ws=bs,Os=Object.prototype,xs=Os.propertyIsEnumerable,Es=Object.getOwnPropertySymbols,Ts=Es?function(t){return null==t?[]:(t=Object(t),_s(Es(t),(function(e){return xs.call(t,e)})))}:ws,Ss=Ts;function Ms(t){return ms(t,Ta,Ss)}var Cs=Ms,As=1,Ls=Object.prototype,Ds=Ls.hasOwnProperty;function ks(t,e,n,r,i,o){var a=n&As,s=Cs(t),u=s.length,l=Cs(e),c=l.length;if(u!=c&&!a)return!1;var h=u;while(h--){var f=s[h];if(!(a?f in e:Ds.call(e,f)))return!1}var p=o.get(t),d=o.get(e);if(p&&d)return p==e&&d==t;var v=!0;o.set(t,e),o.set(e,t);var g=a;while(++h<u){f=s[h];var m=t[f],y=e[f];if(r)var _=a?r(y,m,f,e,t,o):r(m,y,f,t,e,o);if(!(void 0===_?m===y||i(m,y,n,r,o):_)){v=!1;break}g||(g="constructor"==f)}if(v&&!g){var b=t.constructor,w=e.constructor;b==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(v=!1)}return o["delete"](t),o["delete"](e),v}var Ps=ks,Rs=Sn(jt["a"],"DataView"),Is=Rs,Ns=Sn(jt["a"],"Promise"),js=Ns,Bs=Sn(jt["a"],"Set"),Us=Bs,Vs=Sn(jt["a"],"WeakMap"),Hs=Vs,Gs="[object Map]",zs="[object Object]",Fs="[object Promise]",Ws="[object Set]",qs="[object WeakMap]",$s="[object DataView]",Ys=pn(Is),Zs=pn(Cn),Xs=pn(js),Ks=pn(Us),Qs=pn(Hs),Js=ue;(Is&&Js(new Is(new ArrayBuffer(1)))!=$s||Cn&&Js(new Cn)!=Gs||js&&Js(js.resolve())!=Fs||Us&&Js(new Us)!=Ws||Hs&&Js(new Hs)!=qs)&&(Js=function(t){var e=ue(t),n=e==zs?t.constructor:void 0,r=n?pn(n):"";if(r)switch(r){case Ys:return $s;case Zs:return Gs;case Xs:return Fs;case Ks:return Ws;case Qs:return qs}return e});var tu=Js,eu=1,nu="[object Arguments]",ru="[object Array]",iu="[object Object]",ou=Object.prototype,au=ou.hasOwnProperty;function su(t,e,n,r,i,o){var a=ni(t),s=ni(e),u=a?ru:tu(t),l=s?ru:tu(e);u=u==nu?iu:u,l=l==nu?iu:l;var c=u==iu,h=l==iu,f=u==l;if(f&&Object(ci["a"])(t)){if(!Object(ci["a"])(e))return!1;a=!0,c=!1}if(f&&!c)return o||(o=new vr),a||Ki(t)?Ya(t,e,n,r,i,o):vs(t,e,u,n,r,i,o);if(!(n&eu)){var p=c&&au.call(t,"__wrapped__"),d=h&&au.call(e,"__wrapped__");if(p||d){var v=p?t.value():t,g=d?e.value():e;return o||(o=new vr),i(v,g,n,r,o)}}return!!f&&(o||(o=new vr),Ps(t,e,n,r,i,o))}var uu=su;function lu(t,e,n,r,i){return t===e||(null==t||null==e||!ce(t)&&!ce(e)?t!==t&&e!==e:uu(t,e,n,r,lu,i))}var cu=lu,hu=1,fu=2;function pu(t,e,n,r){var i=n.length,o=i,a=!r;if(null==t)return!o;t=Object(t);while(i--){var s=n[i];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}while(++i<o){s=n[i];var u=s[0],l=t[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in t))return!1}else{var h=new vr;if(r)var f=r(l,c,u,t,e,h);if(!(void 0===f?cu(c,l,hu|fu,r,h):f))return!1}}return!0}var du=pu;function vu(t){return t===t&&!Nt(t)}var gu=vu;function mu(t){var e=Ta(t),n=e.length;while(n--){var r=e[n],i=t[r];e[n]=[r,i,gu(i)]}return e}var yu=mu;function _u(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}var bu=_u;function wu(t){var e=yu(t);return 1==e.length&&e[0][2]?bu(e[0][0],e[0][1]):function(n){return n===t||du(n,t,e)}}var Ou=wu,xu=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Eu=/^\w*$/;function Tu(t,e){if(ni(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!pe(t))||(Eu.test(t)||!xu.test(t)||null!=e&&t in Object(e))}var Su=Tu,Mu="Expected a function";function Cu(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError(Mu);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=t.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(Cu.Cache||cr),n}Cu.Cache=cr;var Au=Cu,Lu=500;function Du(t){var e=Au(t,(function(t){return n.size===Lu&&n.clear(),t})),n=e.cache;return e}var ku=Du,Pu=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ru=/\\(\\)?/g,Iu=ku((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(Pu,(function(t,n,r,i){e.push(r?i.replace(Ru,"$1"):n||t)})),e})),Nu=Iu;function ju(t,e){var n=-1,r=null==t?0:t.length,i=Array(r);while(++n<r)i[n]=e(t[n],n,t);return i}var Bu=ju,Uu=1/0,Vu=$t?$t.prototype:void 0,Hu=Vu?Vu.toString:void 0;function Gu(t){if("string"==typeof t)return t;if(ni(t))return Bu(t,Gu)+"";if(pe(t))return Hu?Hu.call(t):"";var e=t+"";return"0"==e&&1/t==-Uu?"-0":e}var zu=Gu;function Fu(t){return null==t?"":zu(t)}var Wu=Fu;function qu(t,e){return ni(t)?t:Su(t,e)?[t]:Nu(Wu(t))}var $u=qu,Yu=1/0;function Zu(t){if("string"==typeof t||pe(t))return t;var e=t+"";return"0"==e&&1/t==-Yu?"-0":e}var Xu=Zu;function Ku(t,e){e=$u(e,t);var n=0,r=e.length;while(null!=t&&n<r)t=t[Xu(e[n++])];return n&&n==r?t:void 0}var Qu=Ku;function Ju(t,e,n){var r=null==t?void 0:Qu(t,e);return void 0===r?n:r}var tl=Ju;function el(t,e){return null!=t&&e in Object(t)}var nl=el;function rl(t,e,n){e=$u(e,t);var r=-1,i=e.length,o=!1;while(++r<i){var a=Xu(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:(i=null==t?0:t.length,!!i&&oi(i)&&ho(a,i)&&(ni(t)||ti(t)))}var il=rl;function ol(t,e){return null!=t&&il(t,e,nl)}var al=ol,sl=1,ul=2;function ll(t,e){return Su(t)&&gu(e)?bu(Xu(t),e):function(n){var r=tl(n,t);return void 0===r&&r===e?al(n,t):cu(e,r,sl|ul)}}var cl=ll;function hl(t){return function(e){return null==e?void 0:e[t]}}var fl=hl;function pl(t){return function(e){return Qu(e,t)}}var dl=pl;function vl(t){return Su(t)?fl(Xu(t)):dl(t)}var gl=vl;function ml(t){return"function"==typeof t?t:null==t?ko:"object"==typeof t?ni(t)?cl(t[0],t[1]):Ou(t):gl(t)}var yl=ml;function _l(t,e){return function(n,r){var i=ni(n)?ma:Pa,o=e?e():{};return i(n,t,yl(r,2),o)}}var bl=_l,wl=Object.prototype,Ol=wl.hasOwnProperty,xl=bl((function(t,e,n){Ol.call(t,n)?t[n].push(e):_r(t,n,[e])})),El=xl;function Tl(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),n=n>i?i:n,n<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;var o=Array(i);while(++r<i)o[r]=t[r+e];return o}var Sl=Tl;function Ml(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:Sl(t,e,n)}var Cl=Ml,Al="\\ud800-\\udfff",Ll="\\u0300-\\u036f",Dl="\\ufe20-\\ufe2f",kl="\\u20d0-\\u20ff",Pl=Ll+Dl+kl,Rl="\\ufe0e\\ufe0f",Il="\\u200d",Nl=RegExp("["+Il+Al+Pl+Rl+"]");function jl(t){return Nl.test(t)}var Bl=jl;function Ul(t){return t.split("")}var Vl=Ul,Hl="\\ud800-\\udfff",Gl="\\u0300-\\u036f",zl="\\ufe20-\\ufe2f",Fl="\\u20d0-\\u20ff",Wl=Gl+zl+Fl,ql="\\ufe0e\\ufe0f",$l="["+Hl+"]",Yl="["+Wl+"]",Zl="\\ud83c[\\udffb-\\udfff]",Xl="(?:"+Yl+"|"+Zl+")",Kl="[^"+Hl+"]",Ql="(?:\\ud83c[\\udde6-\\uddff]){2}",Jl="[\\ud800-\\udbff][\\udc00-\\udfff]",tc="\\u200d",ec=Xl+"?",nc="["+ql+"]?",rc="(?:"+tc+"(?:"+[Kl,Ql,Jl].join("|")+")"+nc+ec+")*",ic=nc+ec+rc,oc="(?:"+[Kl+Yl+"?",Yl,Ql,Jl,$l].join("|")+")",ac=RegExp(Zl+"(?="+Zl+")|"+oc+ic,"g");function sc(t){return t.match(ac)||[]}var uc=sc;function lc(t){return Bl(t)?uc(t):Vl(t)}var cc=lc;function hc(t){return function(e){e=Wu(e);var n=Bl(e)?cc(e):void 0,r=n?n[0]:e.charAt(0),i=n?Cl(n,1).join(""):e.slice(1);return r[t]()+i}}var fc=hc,pc=fc("toUpperCase"),dc=pc;function vc(t){return dc(Wu(t).toLowerCase())}var gc=vc;function mc(t,e,n,r){var i=-1,o=null==t?0:t.length;r&&o&&(n=t[++i]);while(++i<o)n=e(n,t[i],i,t);return n}var yc=mc;function _c(t){return function(e){return null==t?void 0:t[e]}}var bc=_c,wc={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},Oc=bc(wc),xc=Oc,Ec=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Tc="\\u0300-\\u036f",Sc="\\ufe20-\\ufe2f",Mc="\\u20d0-\\u20ff",Cc=Tc+Sc+Mc,Ac="["+Cc+"]",Lc=RegExp(Ac,"g");function Dc(t){return t=Wu(t),t&&t.replace(Ec,xc).replace(Lc,"")}var kc=Dc,Pc=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Rc(t){return t.match(Pc)||[]}var Ic=Rc,Nc=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function jc(t){return Nc.test(t)}var Bc=jc,Uc="\\ud800-\\udfff",Vc="\\u0300-\\u036f",Hc="\\ufe20-\\ufe2f",Gc="\\u20d0-\\u20ff",zc=Vc+Hc+Gc,Fc="\\u2700-\\u27bf",Wc="a-z\\xdf-\\xf6\\xf8-\\xff",qc="\\xac\\xb1\\xd7\\xf7",$c="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Yc="\\u2000-\\u206f",Zc=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xc="A-Z\\xc0-\\xd6\\xd8-\\xde",Kc="\\ufe0e\\ufe0f",Qc=qc+$c+Yc+Zc,Jc="['’]",th="["+Qc+"]",eh="["+zc+"]",nh="\\d+",rh="["+Fc+"]",ih="["+Wc+"]",oh="[^"+Uc+Qc+nh+Fc+Wc+Xc+"]",ah="\\ud83c[\\udffb-\\udfff]",sh="(?:"+eh+"|"+ah+")",uh="[^"+Uc+"]",lh="(?:\\ud83c[\\udde6-\\uddff]){2}",ch="[\\ud800-\\udbff][\\udc00-\\udfff]",hh="["+Xc+"]",fh="\\u200d",ph="(?:"+ih+"|"+oh+")",dh="(?:"+hh+"|"+oh+")",vh="(?:"+Jc+"(?:d|ll|m|re|s|t|ve))?",gh="(?:"+Jc+"(?:D|LL|M|RE|S|T|VE))?",mh=sh+"?",yh="["+Kc+"]?",_h="(?:"+fh+"(?:"+[uh,lh,ch].join("|")+")"+yh+mh+")*",bh="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",wh="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Oh=yh+mh+_h,xh="(?:"+[rh,lh,ch].join("|")+")"+Oh,Eh=RegExp([hh+"?"+ih+"+"+vh+"(?="+[th,hh,"$"].join("|")+")",dh+"+"+gh+"(?="+[th,hh+ph,"$"].join("|")+")",hh+"?"+ph+"+"+vh,hh+"+"+gh,wh,bh,nh,xh].join("|"),"g");function Th(t){return t.match(Eh)||[]}var Sh=Th;function Mh(t,e,n){return t=Wu(t),e=n?void 0:e,void 0===e?Bc(t)?Sh(t):Ic(t):t.match(e)||[]}var Ch=Mh,Ah="['’]",Lh=RegExp(Ah,"g");function Dh(t){return function(e){return yc(Ch(kc(e).replace(Lh,"")),t,"")}}var kh=Dh,Ph=kh((function(t,e,n){return e=e.toLowerCase(),t+(n?gc(e):e)})),Rh=Ph,Ih="[object Map]",Nh="[object Set]",jh=Object.prototype,Bh=jh.hasOwnProperty;function Uh(t){if(null==t)return!0;if(si(t)&&(ni(t)||"string"==typeof t||"function"==typeof t.splice||Object(ci["a"])(t)||Ki(t)||ti(t)))return!t.length;var e=tu(t);if(e==Ih||e==Nh)return!t.size;if(Fr(t))return!xa(t).length;for(var n in t)if(Bh.call(t,n))return!1;return!0}var Vh=Uh;function Hh(t,e){return cu(t,e)}var Gh=Hh;function zh(t,e){var n=-1,r=si(t)?Array(t.length):[];return Da(t,(function(t,i,o){r[++n]=e(t,i,o)})),r}var Fh=zh;function Wh(t,e){var n=ni(t)?Bu:Fh;return n(t,yl(e,3))}var qh=Wh,$h=1/0;function Yh(t,e){return pa(qh(t,e),$h)}var Zh=Yh,Xh=kh((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Kh=Xh;function Qh(t){var e=-1,n=null==t?0:t.length,r={};while(++e<n){var i=t[e];r[i[0]]=i[1]}return r}var Jh=Qh;function tf(t,e){var n;return Da(t,(function(t,r,i){return n=e(t,r,i),!n})),!!n}var ef=tf;function nf(t,e,n){var r=ni(t)?Ga:ef;return n&&Qo(t,e,n)&&(e=void 0),r(t,yl(e,3))}var rf=nf;function of(t,e){var n=-1,r=null==t?0:t.length;while(++n<r)if(!1===e(t[n],n,t))break;return t}var af=of;function sf(t,e){return t&&oo(e,Ta(e),t)}var uf=sf;function lf(t,e){return t&&oo(e,Eo(e),t)}var cf=lf;function hf(t,e){return oo(t,Ss(t),e)}var ff=hf,pf=Object.getOwnPropertySymbols,df=pf?function(t){var e=[];while(t)ua(e,Ss(t)),t=Hr(t);return e}:ws,vf=df;function gf(t,e){return oo(t,vf(t),e)}var mf=gf;function yf(t){return ms(t,Eo,vf)}var _f=yf,bf=Object.prototype,wf=bf.hasOwnProperty;function Of(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&wf.call(t,"index")&&(n.index=t.index,n.input=t.input),n}var xf=Of;function Ef(t,e){var n=e?Lr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}var Tf=Ef,Sf=/\w*$/;function Mf(t){var e=new t.constructor(t.source,Sf.exec(t));return e.lastIndex=t.lastIndex,e}var Cf=Mf,Af=$t?$t.prototype:void 0,Lf=Af?Af.valueOf:void 0;function Df(t){return Lf?Object(Lf.call(t)):{}}var kf=Df,Pf="[object Boolean]",Rf="[object Date]",If="[object Map]",Nf="[object Number]",jf="[object RegExp]",Bf="[object Set]",Uf="[object String]",Vf="[object Symbol]",Hf="[object ArrayBuffer]",Gf="[object DataView]",zf="[object Float32Array]",Ff="[object Float64Array]",Wf="[object Int8Array]",qf="[object Int16Array]",$f="[object Int32Array]",Yf="[object Uint8Array]",Zf="[object Uint8ClampedArray]",Xf="[object Uint16Array]",Kf="[object Uint32Array]";function Qf(t,e,n){var r=t.constructor;switch(e){case Hf:return Lr(t);case Pf:case Rf:return new r(+t);case Gf:return Tf(t,n);case zf:case Ff:case Wf:case qf:case $f:case Yf:case Zf:case Xf:case Kf:return kr(t,n);case If:return new r;case Nf:case Uf:return new r(t);case jf:return Cf(t);case Bf:return new r;case Vf:return kf(t)}}var Jf=Qf,tp="[object Map]";function ep(t){return ce(t)&&tu(t)==tp}var np=ep,rp=Yi["a"]&&Yi["a"].isMap,ip=rp?$i(rp):np,op=ip,ap="[object Set]";function sp(t){return ce(t)&&tu(t)==ap}var up=sp,lp=Yi["a"]&&Yi["a"].isSet,cp=lp?$i(lp):up,hp=cp,fp=1,pp=2,dp=4,vp="[object Arguments]",gp="[object Array]",mp="[object Boolean]",yp="[object Date]",_p="[object Error]",bp="[object Function]",wp="[object GeneratorFunction]",Op="[object Map]",xp="[object Number]",Ep="[object Object]",Tp="[object RegExp]",Sp="[object Set]",Mp="[object String]",Cp="[object Symbol]",Ap="[object WeakMap]",Lp="[object ArrayBuffer]",Dp="[object DataView]",kp="[object Float32Array]",Pp="[object Float64Array]",Rp="[object Int8Array]",Ip="[object Int16Array]",Np="[object Int32Array]",jp="[object Uint8Array]",Bp="[object Uint8ClampedArray]",Up="[object Uint16Array]",Vp="[object Uint32Array]",Hp={};function Gp(t,e,n,r,i,o){var a,s=e&fp,u=e&pp,l=e&dp;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!Nt(t))return t;var c=ni(t);if(c){if(a=xf(t),!s)return Rr(t,a)}else{var h=tu(t),f=h==bp||h==wp;if(Object(ci["a"])(t))return Object(Sr["a"])(t,s);if(h==Ep||h==vp||f&&!i){if(a=u||f?{}:qr(t),!s)return u?mf(t,cf(a,t)):ff(t,uf(a,t))}else{if(!Hp[h])return i?t:{};a=Jf(t,h,s)}}o||(o=new vr);var p=o.get(t);if(p)return p;o.set(t,a),hp(t)?t.forEach((function(r){a.add(Gp(r,e,n,r,t,o))})):op(t)&&t.forEach((function(r,i){a.set(i,Gp(r,e,n,i,t,o))}));var d=l?u?_f:Cs:u?Eo:Ta,v=c?void 0:d(t);return af(v||t,(function(r,i){v&&(i=r,r=t[i]),ro(a,i,Gp(r,e,n,i,t,o))})),a}Hp[vp]=Hp[gp]=Hp[Lp]=Hp[Dp]=Hp[mp]=Hp[yp]=Hp[kp]=Hp[Pp]=Hp[Rp]=Hp[Ip]=Hp[Np]=Hp[Op]=Hp[xp]=Hp[Ep]=Hp[Tp]=Hp[Sp]=Hp[Mp]=Hp[Cp]=Hp[jp]=Hp[Bp]=Hp[Up]=Hp[Vp]=!0,Hp[_p]=Hp[bp]=Hp[Ap]=!1;var zp=Gp,Fp=1,Wp=4;function qp(t){return zp(t,Fp|Wp)}var $p=qp;function Yp(t,e,n,r){var i=t.length,o=n+(r?1:-1);while(r?o--:++o<i)if(e(t[o],o,t))return o;return-1}var Zp=Yp;function Xp(t){return t!==t}var Kp=Xp;function Qp(t,e,n){var r=n-1,i=t.length;while(++r<i)if(t[r]===e)return r;return-1}var Jp=Qp;function td(t,e,n){return e===e?Jp(t,e,n):Zp(t,Kp,n)}var ed=td;function nd(t,e){var n=null==t?0:t.length;return!!n&&ed(t,e,0)>-1}var rd=nd;function id(t,e,n){var r=-1,i=null==t?0:t.length;while(++r<i)if(n(e,t[r]))return!0;return!1}var od=id;function ad(){}var sd=ad,ud=1/0,ld=Us&&1/Qa(new Us([,-0]))[1]==ud?function(t){return new Us(t)}:sd,cd=ld,hd=200;function fd(t,e,n){var r=-1,i=rd,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=od;else if(o>=hd){var l=e?null:cd(t);if(l)return Qa(l);a=!1,i=Fa,u=new Va}else u=e?[]:s;t:while(++r<o){var c=t[r],h=e?e(c):c;if(c=n||0!==c?c:0,a&&h===h){var f=u.length;while(f--)if(u[f]===h)continue t;e&&u.push(h),s.push(c)}else i(u,h,n)||(u!==s&&u.push(h),s.push(c))}return s}var pd=fd;function dd(t){return t&&t.length?pd(t):[]}var vd=dd;function gd(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}var md=gd,yd=Xo((function(t){var e=md(t);return li(e)&&(e=void 0),pd(pa(t,1,li,!0),yl(e,2))})),_d=yd,bd=function(t){let e;while(e=t.sourceEvent)t=e;return t},wd=function(t,e){if(t=bd(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,r=r.matrixTransform(e.getScreenCTM().inverse()),[r.x,r.y]}if(e.getBoundingClientRect){var i=e.getBoundingClientRect();return[t.clientX-i.left-e.clientLeft,t.clientY-i.top-e.clientTop]}}return[t.pageX,t.pageY]},Od=$p,xd=vd;function Ed(t,e,n){var r=null;return function(){var i=this,o=arguments;i.mousePosition=wd(o[0],n),clearTimeout(r),r=setTimeout((function(){t.apply(i,o)}),e)}}function Td(t,e){var n,r,i=Od(t),o=Object.keys(e.axes||{});for(var a in(null===(r=null===(n=e)||void 0===n?void 0:n.toolbar)||void 0===r?void 0:r.controls)&&delete i.toolbar.controls,0===o.length&&delete i.axes,i.axes)if(o.includes(a)){var s=e.axes[a];(s["primary"]||s["secondary"])&&console.warn("`primary` & `secondary` are no longer needed for axis configurations. Read more here https://carbon-design-system.github.io/carbon-charts/?path=/story/docs-tutorials--tabular-data-format");var u=s["mapsTo"];if(void 0===u||null===u){var l=s["scaleType"];void 0===l||null===l?s["mapsTo"]="value":l===G.TIME?s["mapsTo"]="date":l===G.LABELS&&(s["mapsTo"]="key")}}else delete i.axes[a];return Ld(i,e),na(i,e)}function Sd(t){if(t){var e=/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/,n=t.getAttribute("transform").match(e);if(!n)return null;if(n[0]){var r=n[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:r[0],ty:r[1]}}return null}}function Md(t){var e=/\(([^)]+)\)/,n=e.exec(t)[1],r=n.split(",");return{x:parseFloat(r[0]),y:parseFloat(r[1])}}function Cd(t,e,n){void 0===n&&(n="value");var r=t/e.reduce((function(t,e){return t+e[n]}),0)*100;return r%1!==0?parseFloat(r.toFixed(1)):r}function Ad(t,e,n){return n>t.length?t:e===V.MID_LINE?t.substr(0,n/2)+"..."+t.substr(-n/2):e===V.FRONT_LINE?"..."+t.substr(-n):e===V.END_LINE?t.substr(0,n)+"...":void 0}function Ld(t,e){var n=Dd(t,"legend","additionalItems"),r=Dd(e,"legend","additionalItems");if(n&&r){var i=r.map((function(t){return t.type})),o=n.map((function(t){return t.type})),a=Rt.filter((function(t){return o.includes(t.type)&&!i.includes(t.type)}));t.legend.additionalItems=a,e.legend.additionalItems=_d(a,r,"name")}}var Dd=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var r=t;if(r){for(var i=0,o=e;i<o.length;i++){var a=o[i];if(null===r[a]||void 0===r[a])return null;r=r[a]}return r}return null},kd=function(t,e){return e===H.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},Pd=function(t,e){var n=kd(t,e),r=n.x0,i=n.x1,o=n.y0,a=n.y1;return"M"+r+","+o+"L"+r+","+a+"L"+i+","+a+"L"+i+","+o+"L"+r+","+o};function Rd(t,e,n){return n===H.VERTICAL?[t,e]:[e,t]}var Id=n("39ba"),Nd=n.n(Id),jd=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},Bd={type:V.END_LINE,threshold:16,numCharacter:14},Ud={enabled:!0,position:z.BOTTOM,clickable:!0,truncation:Bd,alignment:F.LEFT,order:null,additionalItems:[]},Vd={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},Hd={enabled:!0},Gd={enabled:!0,showTotal:!0,truncation:Bd,groupLabel:"Group"},zd={top:{visible:!0,includeZero:!0,truncation:Bd},bottom:{visible:!0,includeZero:!0,truncation:Bd},left:{visible:!0,includeZero:!0,truncation:Bd},right:{visible:!0,includeZero:!0,truncation:Bd}},Fd={addSpaceOnEdges:1,showDayName:!1,localeObject:Nd.a,timeIntervalFormats:{"15seconds":{primary:"MMM d, pp",secondary:"pp"},minute:{primary:"MMM d, p",secondary:"p"},"30minutes":{primary:"MMM d, p",secondary:"p"},hourly:{primary:"MMM d, hh a",secondary:"hh a"},daily:{primary:"MMM d",secondary:"d"},weekly:{primary:"eee, MMM d",secondary:"eee"},monthly:{primary:"MMM yyyy",secondary:"MMM"},quarterly:{primary:"QQQ ''yy",secondary:"QQQ"},yearly:{primary:"yyyy",secondary:"yyyy"}}},Wd="undefined"!==typeof document&&(document["fullscreenEnabled"]||document["webkitFullscreenEnabled"]||document["mozFullScreenEnabled"]||document["msFullscreenEnabled"]),qd={width:null,height:null,resizable:!0,theme:N.WHITE,tooltip:Gd,legend:Ud,style:{prefix:"cc"},data:{groupMapsTo:"group",loading:!1,selectedGroups:[]},color:{scale:null,pairing:{numberOfVariants:null,option:1},gradient:{enabled:!1}},toolbar:{enabled:!0,numberOfIcons:3,controls:jd([{type:ot.SHOW_AS_DATATABLE}],Wd?[{type:ot.MAKE_FULLSCREEN}]:[],[{type:ot.EXPORT_CSV},{type:ot.EXPORT_PNG},{type:ot.EXPORT_JPG}])}},$d=na({},qd,{axes:zd,timeScale:Fd,grid:Vd,ruler:Hd,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:U.GRAPH_VIEW}}}),Yd=na({},$d,{bars:{maxWidth:16,spacingFactor:.25},timeScale:na(Fd,{addSpaceOnEdges:1})}),Zd=na({},Yd,{}),Xd=na({},Yd,{}),Kd=na({},Yd,{bars:na({},Yd.bars,{dividerSize:1.5})}),Qd=na({},Yd,{}),Jd=na({},$d,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),tv=Jd,ev=na({},Jd,{points:{radius:3,filled:!1,enabled:!0}}),nv=na({},ev,{timeScale:na(Fd,{addSpaceOnEdges:0})}),rv=nv,iv=na({},$d,{bubble:{radiusMapsTo:"radius",radiusLabel:"Radius",radiusRange:function(t,e){var n=Math.min(t.width,t.height);return[3*n/400,25*n/400]},fillOpacity:.2,enabled:!0},points:{filled:!0},legend:{additionalItems:[{type:st.RADIUS,name:"Radius"}]}}),ov=na({},$d,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:st.AREA,name:"Poor area"},{type:st.AREA,name:"Satisfactory area"},{type:st.AREA,name:"Great area"},{type:st.QUARTILE,name:"Quartiles"}]}}),av=na({},Yd,{bars:{dividerSize:1.5},timeScale:na(Fd,{addSpaceOnEdges:0})}),sv=na({},qd,{tooltip:na({},Gd,{wordLabel:"Word",valueLabel:"Value"}),wordCloud:{fontSizeMapsTo:"value",fontSizeRange:function(t,e){var n=Math.min(t.width,t.height);return[20*n/400,75*n/400]},wordMapsTo:"word"}}),uv=na({},qd,{pie:{labels:{formatter:null,enabled:!0},alignment:F.LEFT,sortFunction:null,valueMapsTo:"value"}}),lv=na({},qd,{legend:{enabled:!1},gauge:{type:tt.SEMI,arcWidth:16,deltaArrow:{size:function(t){return t/8},enabled:!0},showPercentageSymbol:!0,status:null,numberSpacing:10,deltaFontSize:function(t){return t/8},valueFontSize:function(t){return t/2.5},numberFormatter:function(t){return t.toFixed(2)%1!==0?t.toFixed(2).toLocaleString():t.toFixed().toLocaleString()},alignment:F.LEFT}}),cv=na({},uv,{donut:{center:{numberFontSize:function(t){return Math.min(t/100*24,24)+"px"},titleFontSize:function(t){return Math.min(t/100*15,15)+"px"},titleYPosition:function(t){return Math.min(t/80*20,20)},numberFormatter:function(t){return Math.floor(t).toLocaleString()}},alignment:F.LEFT}}),hv=na({},qd,{legend:{enabled:!1,clickable:!1},meter:{showLabels:!0,proportional:null,statusBar:{percentageIndicator:{enabled:!0}}}}),fv=na({},hv,{legend:{enabled:!0}}),pv=na({},qd,{radar:{axes:{angle:"key",value:"value"},alignment:F.LEFT},tooltip:{gridline:{enabled:!0},valueFormatter:function(t){return null!==t&&void 0!==t?t:"N/A"}}}),dv=na({},Yd,{comboChartTypes:[]}),vv=na({tree:{type:q.TREE}},qd,{}),gv=na({},qd,{data:na(qd.data,{groupMapsTo:"name"})}),mv=na({},qd,yt,{data:na(qd.data,{groupMapsTo:"name"})}),yv=na({},qd,{alluvial:{data:na(qd.data,{groupMapsTo:"source"}),nodeAlignment:F.CENTER,nodePadding:24,monochrome:!1,nodes:[]}}),_v=na({},qd,{axes:zd,heatmap:{divider:{state:lt.AUTO},colorLegend:{type:"linear"}}}),bv={chart:qd,axisChart:$d,simpleBarChart:Zd,groupedBarChart:Xd,stackedBarChart:Kd,boxplotChart:Qd,bubbleChart:iv,bulletChart:ov,histogramChart:av,lineChart:ev,areaChart:nv,stackedAreaChart:rv,scatterChart:Jd,lollipopChart:tv,pieChart:uv,donutChart:cv,meterChart:hv,proportionalMeterChart:fv,radarChart:pv,gaugeChart:lv,comboChart:dv,treeChart:vv,treemapChart:gv,circlePackChart:mv,wordCloudChart:sv,alluvialChart:yv,heatmapChart:_v};class wv extends Map{constructor(t,e=Tv){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[n,r]of t)this.set(n,r)}get(t){return super.get(Ov(this,t))}has(t){return super.has(Ov(this,t))}set(t,e){return super.set(xv(this,t),e)}delete(t){return super.delete(Ev(this,t))}}Set;function Ov({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):n}function xv({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):(t.set(r,n),n)}function Ev({_intern:t,_key:e},n){const r=e(n);return t.has(r)&&(n=t.get(r),t.delete(r)),n}function Tv(t){return null!==t&&"object"===typeof t?t.valueOf():t}function Sv(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}const Mv=Symbol("implicit");function Cv(){var t=new wv,e=[],n=[],r=Mv;function i(i){let o=t.get(i);if(void 0===o){if(r!==Mv)return r;t.set(i,o=e.push(i)-1)}return n[o%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new wv;for(const r of n)t.has(r)||t.set(r,e.push(r)-1);return i},i.range=function(t){return arguments.length?(n=Array.from(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Cv(e,n).unknown(r)},Sv.apply(i,arguments),i}var Av=Array.prototype.slice,Lv=function(t){return"object"===typeof t&&"length"in t?t:Array.from(t)},Dv=function(t){return function(){return t}},kv=function(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]},Pv=function(t){var e=t.length,n=new Array(e);while(--e>=0)n[e]=e;return n};function Rv(t,e){return t[e]}function Iv(t){const e=[];return e.key=t,e}var Nv=function(){var t=Dv([]),e=Pv,n=kv,r=Rv;function i(i){var o,a,s=Array.from(t.apply(this,arguments),Iv),u=s.length,l=-1;for(const t of i)for(o=0,++l;o<u;++o)(s[o][l]=[0,+r(t,s[o].key,l,i)]).data=t;for(o=0,a=Lv(e(s));o<u;++o)s[a[o]].index=o;return n(s,a),s}return i.keys=function(e){return arguments.length?(t="function"===typeof e?e:Dv(Array.from(e)),i):t},i.value=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?Pv:"function"===typeof t?t:Dv(Array.from(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?kv:t,i):n},i},jv=function(t,e){if((s=t.length)>0)for(var n,r,i,o,a,s,u=0,l=t[e[0]].length;u<l;++u)for(o=a=0,n=0;n<s;++n)(i=(r=t[e[n]][u])[1]-r[0])>0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=a,r[0]=a+=i):(r[0]=0,r[1]=i)},Bv=Array.prototype,Uv=Bv.slice;Bv.map;function Vv(t,e){return null==t||null==e?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Hv(t,e){return null==t||null==e?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Gv(t){let e,n,r;function i(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<0?i=e+1:o=e}while(i<o)}return i}function o(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<=0?i=e+1:o=e}while(i<o)}return i}function a(t,e,n=0,o=t.length){const a=i(t,e,n,o-1);return a>n&&r(t[a-1],e)>-r(t[a],e)?a-1:a}return 2!==t.length?(e=Vv,n=(e,n)=>Vv(t(e),n),r=(e,n)=>t(e)-n):(e=t===Vv||t===Hv?t:zv,n=t,r=t),{left:i,center:a,right:o}}function zv(){return 0}function Fv(t){return null===t?NaN:+t}function*Wv(t,e){if(void 0===e)for(let n of t)null!=n&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of t)null!=(r=e(r,++n,t))&&(r=+r)>=r&&(yield r)}}const qv=Gv(Vv),$v=qv.right;qv.left,Gv(Fv).center;var Yv=$v;function Zv(t){return()=>t}function Xv(t,e){let n,r;if(void 0===e)for(const i of t)null!=i&&(void 0===n?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(void 0===n?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}function Kv(t){return t}const Qv=Math.sqrt(50),Jv=Math.sqrt(10),tg=Math.sqrt(2);function eg(t,e,n){const r=(e-t)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=Qv?10:o>=Jv?5:o>=tg?2:1;let s,u,l;return i<0?(l=Math.pow(10,-i)/a,s=Math.round(t*l),u=Math.round(e*l),s/l<t&&++s,u/l>e&&--u,l=-l):(l=Math.pow(10,i)*a,s=Math.round(t/l),u=Math.round(e/l),s*l<t&&++s,u*l>e&&--u),u<s&&.5<=n&&n<2?eg(t,e,2*n):[s,u,l]}function ng(t,e,n){if(e=+e,t=+t,n=+n,!(n>0))return[];if(t===e)return[t];const r=e<t,[i,o,a]=r?eg(e,t,n):eg(t,e,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let l=0;l<s;++l)u[l]=(o-l)/-a;else for(let l=0;l<s;++l)u[l]=(o-l)*a;else if(a<0)for(let l=0;l<s;++l)u[l]=(i+l)/-a;else for(let l=0;l<s;++l)u[l]=(i+l)*a;return u}function rg(t,e,n){return e=+e,t=+t,n=+n,eg(t,e,n)[2]}function ig(t,e,n){e=+e,t=+t,n=+n;const r=e<t,i=r?rg(e,t,n):rg(t,e,n);return(r?-1:1)*(i<0?1/-i:i)}function og(t,e,n){let r;while(1){const i=rg(t,e,n);if(i===r||0===i||!isFinite(i))return[t,e];i>0?(t=Math.floor(t/i)*i,e=Math.ceil(e/i)*i):i<0&&(t=Math.ceil(t*i)/i,e=Math.floor(e*i)/i),r=i}}function ag(t,e){let n=0;if(void 0===e)for(let r of t)null!=r&&(r=+r)>=r&&++n;else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(i=+i)>=i&&++n}return n}function sg(t){return Math.max(1,Math.ceil(Math.log(ag(t))/Math.LN2)+1)}function ug(){var t=Kv,e=Xv,n=sg;function r(r){Array.isArray(r)||(r=Array.from(r));var i,o,a,s=r.length,u=new Array(s);for(i=0;i<s;++i)u[i]=t(r[i],i,r);var l=e(u),c=l[0],h=l[1],f=n(u,c,h);if(!Array.isArray(f)){const t=h,n=+f;if(e===Xv&&([c,h]=og(c,h,n)),f=ng(c,h,n),f[0]<=c&&(a=rg(c,h,n)),f[f.length-1]>=h)if(t>=h&&e===Xv){const t=rg(c,h,n);isFinite(t)&&(t>0?h=(Math.floor(h/t)+1)*t:t<0&&(h=(Math.ceil(h*-t)+1)/-t))}else f.pop()}var p=f.length,d=0,v=p;while(f[d]<=c)++d;while(f[v-1]>h)--v;(d||v<p)&&(f=f.slice(d,v),p=v-d);var g,m=new Array(p+1);for(i=0;i<=p;++i)g=m[i]=[],g.x0=i>0?f[i-1]:c,g.x1=i<p?f[i]:h;if(isFinite(a)){if(a>0)for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=h&&m[Math.min(p,Math.floor((o-c)/a))].push(r[i]);else if(a<0)for(i=0;i<s;++i)if(null!=(o=u[i])&&c<=o&&o<=h){const t=Math.floor((c-o)*a);m[Math.min(p,t+(f[t]<=o))].push(r[i])}}else for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=h&&m[Yv(f,o,0,p)].push(r[i]);return m}return r.value=function(e){return arguments.length?(t="function"===typeof e?e:Zv(e),r):t},r.domain=function(t){return arguments.length?(e="function"===typeof t?t:Zv([t[0],t[1]]),r):e},r.thresholds=function(t){return arguments.length?(n="function"===typeof t?t:Zv(Array.isArray(t)?Uv.call(t):t),r):n},r}function lg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===typeof t&&"[object Date]"===e?new Date(t.getTime()):"number"===typeof t||"[object Number]"===e?new Date(t):("string"!==typeof t&&"[object String]"!==e||"undefined"===typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule"),console.warn((new Error).stack)),new Date(NaN))}function cg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t);return!isNaN(e)}var hg={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function fg(t,e,n){var r;return n=n||{},r="string"===typeof hg[t]?hg[t]:1===e?hg[t].one:hg[t].other.replace("{{count}}",e),n.addSuffix?n.comparison>0?"in "+r:r+" ago":r}function pg(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth,i=t.formats[r]||t.formats[t.defaultWidth];return i}}var dg={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},vg={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},gg={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},mg={date:pg({formats:dg,defaultWidth:"full"}),time:pg({formats:vg,defaultWidth:"full"}),dateTime:pg({formats:gg,defaultWidth:"full"})},yg=mg,_g={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function bg(t,e,n,r){return _g[t]}function wg(t){return function(e,n){var r,i=n||{},o=i.context?String(i.context):"standalone";if("formatting"===o&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,s=i.width?String(i.width):a;r=t.formattingValues[s]||t.formattingValues[a]}else{var u=t.defaultWidth,l=i.width?String(i.width):t.defaultWidth;r=t.values[l]||t.values[u]}var c=t.argumentCallback?t.argumentCallback(e):e;return r[c]}}var Og={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},xg={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Eg={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Tg={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Sg={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Mg={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}};function Cg(t,e){var n=Number(t),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"}var Ag={ordinalNumber:Cg,era:wg({values:Og,defaultWidth:"wide"}),quarter:wg({values:xg,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:wg({values:Eg,defaultWidth:"wide"}),day:wg({values:Tg,defaultWidth:"wide"}),dayPeriod:wg({values:Sg,defaultWidth:"wide",formattingValues:Mg,defaultFormattingWidth:"wide"})},Lg=Ag;function Dg(t){return function(e,n){var r=String(e),i=n||{},o=r.match(t.matchPattern);if(!o)return null;var a=o[0],s=r.match(t.parsePattern);if(!s)return null;var u=t.valueCallback?t.valueCallback(s[0]):s[0];return u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(a.length)}}}function kg(t){return function(e,n){var r=String(e),i=n||{},o=i.width,a=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],s=r.match(a);if(!s)return null;var u,l=s[0],c=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth];return u="[object Array]"===Object.prototype.toString.call(c)?Rg(c,(function(t){return t.test(r)})):Pg(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(l.length)}}}function Pg(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function Rg(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}var Ig=/^(\d+)(th|st|nd|rd)?/i,Ng=/\d+/i,jg={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},Bg={any:[/^b/i,/^(a|c)/i]},Ug={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Vg={any:[/1/i,/2/i,/3/i,/4/i]},Hg={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Gg={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},zg={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Fg={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Wg={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},qg={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},$g={ordinalNumber:Dg({matchPattern:Ig,parsePattern:Ng,valueCallback:function(t){return parseInt(t,10)}}),era:kg({matchPatterns:jg,defaultMatchWidth:"wide",parsePatterns:Bg,defaultParseWidth:"any"}),quarter:kg({matchPatterns:Ug,defaultMatchWidth:"wide",parsePatterns:Vg,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:kg({matchPatterns:Hg,defaultMatchWidth:"wide",parsePatterns:Gg,defaultParseWidth:"any"}),day:kg({matchPatterns:zg,defaultMatchWidth:"wide",parsePatterns:Fg,defaultParseWidth:"any"}),dayPeriod:kg({matchPatterns:Wg,defaultMatchWidth:"any",parsePatterns:qg,defaultParseWidth:"any"})},Yg=$g,Zg={code:"en-US",formatDistance:fg,formatLong:yg,formatRelative:bg,localize:Lg,match:Yg,options:{weekStartsOn:0,firstWeekContainsDate:1}},Xg=Zg;function Kg(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function Qg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t).getTime(),r=Kg(e);return new Date(n+r)}function Jg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,-n)}function tm(t,e){var n=t<0?"-":"",r=Math.abs(t).toString();while(r.length<e)r="0"+r;return n+r}var em={y:function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return tm("yy"===e?r%100:r,e.length)},M:function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):tm(n+1,2)},d:function(t,e){return tm(t.getUTCDate(),e.length)},a:function(t,e){var n=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.toUpperCase();case"aaaaa":return n[0];case"aaaa":default:return"am"===n?"a.m.":"p.m."}},h:function(t,e){return tm(t.getUTCHours()%12||12,e.length)},H:function(t,e){return tm(t.getUTCHours(),e.length)},m:function(t,e){return tm(t.getUTCMinutes(),e.length)},s:function(t,e){return tm(t.getUTCSeconds(),e.length)},S:function(t,e){var n=e.length,r=t.getUTCMilliseconds(),i=Math.floor(r*Math.pow(10,n-3));return tm(i,e.length)}},nm=em,rm=864e5;function im(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var r=e.getTime(),i=n-r;return Math.floor(i/rm)+1}function om(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=1,n=lg(t),r=n.getUTCDay(),i=(r<e?7:0)+r-e;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function am(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=om(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=om(o);return e.getTime()>=i.getTime()?n+1:e.getTime()>=a.getTime()?n:n-1}function sm(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=am(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=om(n);return r}var um=6048e5;function lm(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=om(e).getTime()-sm(e).getTime();return Math.round(n/um)+1}function cm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=e||{},r=n.locale,i=r&&r.options&&r.options.weekStartsOn,o=null==i?0:Kg(i),a=null==n.weekStartsOn?o:Kg(n.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=lg(t),u=s.getUTCDay(),l=(u<a?7:0)+u-a;return s.setUTCDate(s.getUTCDate()-l),s.setUTCHours(0,0,0,0),s}function hm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=lg(t,e),r=n.getUTCFullYear(),i=e||{},o=i.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:Kg(a),u=null==i.firstWeekContainsDate?s:Kg(i.firstWeekContainsDate);if(!(u>=1&&u<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var l=new Date(0);l.setUTCFullYear(r+1,0,u),l.setUTCHours(0,0,0,0);var c=cm(l,e),h=new Date(0);h.setUTCFullYear(r,0,u),h.setUTCHours(0,0,0,0);var f=cm(h,e);return n.getTime()>=c.getTime()?r+1:n.getTime()>=f.getTime()?r:r-1}function fm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=e||{},r=n.locale,i=r&&r.options&&r.options.firstWeekContainsDate,o=null==i?1:Kg(i),a=null==n.firstWeekContainsDate?o:Kg(n.firstWeekContainsDate),s=hm(t,e),u=new Date(0);u.setUTCFullYear(s,0,a),u.setUTCHours(0,0,0,0);var l=cm(u,e);return l}var pm=6048e5;function dm(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=lg(t),r=cm(n,e).getTime()-fm(n,e).getTime();return Math.round(r/pm)+1}var vm={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},gm={G:function(t,e,n){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(t,e,n){if("yo"===e){var r=t.getUTCFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return nm.y(t,e)},Y:function(t,e,n,r){var i=hm(t,r),o=i>0?i:1-i;if("YY"===e){var a=o%100;return tm(a,2)}return"Yo"===e?n.ordinalNumber(o,{unit:"year"}):tm(o,e.length)},R:function(t,e){var n=am(t);return tm(n,e.length)},u:function(t,e){var n=t.getUTCFullYear();return tm(n,e.length)},Q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return tm(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,n){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return tm(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,n){var r=t.getUTCMonth();switch(e){case"M":case"MM":return nm.M(t,e);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,n){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return tm(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,n,r){var i=dm(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):tm(i,e.length)},I:function(t,e,n){var r=lm(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):tm(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):nm.d(t,e)},D:function(t,e,n){var r=im(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):tm(r,e.length)},E:function(t,e,n){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(o);case"ee":return tm(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(t,e,n,r){var i=t.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(o);case"cc":return tm(o,e.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,n){var r=t.getUTCDay(),i=0===r?7:r;switch(e){case"i":return String(i);case"ii":return tm(i,e.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,n){var r=t.getUTCHours(),i=r/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?vm.noon:0===i?vm.midnight:i/12>=1?"pm":"am",e){case"b":case"bb":case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,n){var r,i=t.getUTCHours();switch(r=i>=17?vm.evening:i>=12?vm.afternoon:i>=4?vm.morning:vm.night,e){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,n){if("ho"===e){var r=t.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return nm.h(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):nm.H(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):tm(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):tm(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):nm.m(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):nm.s(t,e)},S:function(t,e){return nm.S(t,e)},X:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();if(0===o)return"Z";switch(e){case"X":return ym(o);case"XXXX":case"XX":return _m(o);case"XXXXX":case"XXX":default:return _m(o,":")}},x:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"x":return ym(o);case"xxxx":case"xx":return _m(o);case"xxxxx":case"xxx":default:return _m(o,":")}},O:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+mm(o,":");case"OOOO":default:return"GMT"+_m(o,":")}},z:function(t,e,n,r){var i=r._originalDate||t,o=i.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+mm(o,":");case"zzzz":default:return"GMT"+_m(o,":")}},t:function(t,e,n,r){var i=r._originalDate||t,o=Math.floor(i.getTime()/1e3);return tm(o,e.length)},T:function(t,e,n,r){var i=r._originalDate||t,o=i.getTime();return tm(o,e.length)}};function mm(t,e){var n=t>0?"-":"+",r=Math.abs(t),i=Math.floor(r/60),o=r%60;if(0===o)return n+String(i);var a=e||"";return n+String(i)+a+tm(o,2)}function ym(t,e){if(t%60===0){var n=t>0?"-":"+";return n+tm(Math.abs(t)/60,2)}return _m(t,e)}function _m(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t),o=tm(Math.floor(i/60),2),a=tm(i%60,2);return r+o+n+a}var bm=gm;function wm(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}}function Om(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}}function xm(t,e){var n,r=t.match(/(P+)(p+)?/),i=r[1],o=r[2];if(!o)return wm(t,e);switch(i){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;case"PPPP":default:n=e.dateTime({width:"full"});break}return n.replace("{{date}}",wm(i,e)).replace("{{time}}",Om(o,e))}var Em={p:Om,P:xm},Tm=Em,Sm=6e4;function Mm(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());e.setSeconds(0,0);var r=e.getTime()%Sm;return n*Sm+r}var Cm=["D","DD"],Am=["YY","YYYY"];function Lm(t){return-1!==Cm.indexOf(t)}function Dm(t){return-1!==Am.indexOf(t)}function km(t){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` for formatting years; see: https://git.io/fxCyr");if("YY"===t)throw new RangeError("Use `yy` instead of `YY` for formatting years; see: https://git.io/fxCyr");if("D"===t)throw new RangeError("Use `d` instead of `D` for formatting days of the month; see: https://git.io/fxCyr");if("DD"===t)throw new RangeError("Use `dd` instead of `DD` for formatting days of the month; see: https://git.io/fxCyr")}var Pm=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Rm=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Im=/^'([^]*?)'?$/,Nm=/''/g,jm=/[a-zA-Z]/;function Bm(t,e,n){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var r=String(e),i=n||{},o=i.locale||Xg,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:Kg(a),u=null==i.firstWeekContainsDate?s:Kg(i.firstWeekContainsDate);if(!(u>=1&&u<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var l=o.options&&o.options.weekStartsOn,c=null==l?0:Kg(l),h=null==i.weekStartsOn?c:Kg(i.weekStartsOn);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!o.localize)throw new RangeError("locale must contain localize property");if(!o.formatLong)throw new RangeError("locale must contain formatLong property");var f=lg(t);if(!cg(f))throw new RangeError("Invalid time value");var p=Mm(f),d=Jg(f,p),v={firstWeekContainsDate:u,weekStartsOn:h,locale:o,_originalDate:f},g=r.match(Rm).map((function(t){var e=t[0];if("p"===e||"P"===e){var n=Tm[e];return n(t,o.formatLong,v)}return t})).join("").match(Pm).map((function(t){if("''"===t)return"'";var e=t[0];if("'"===e)return Um(t);var n=bm[e];if(n)return!i.useAdditionalWeekYearTokens&&Dm(t)&&km(t),!i.useAdditionalDayOfYearTokens&&Lm(t)&&km(t),n(d,t,o.localize,v);if(e.match(jm))throw new RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return t})).join("");return g}function Um(t){return t.match(Im)[1].replace(Nm,"'")}function Vm(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n>r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}var Hm=[["15seconds",15e3],["minute",6e4],["30minutes",18e5],["hourly",36e5],["daily",864e5],["monthly",2592e6],["quarterly",7776e6],["yearly",31104e6]];function Gm(t,e,n,r,i){var o=0===e,a=2===Number(Bm(new Date(t),"c")),s=1===Number(Bm(new Date(t),"q")),u=0!==e?n[e-1]:null;switch(r){case"15seconds":return o||Ym(t)||Zm(t,u)||Xm(t);case"minute":return o||Ym(t)||Zm(t,u)||Xm(t);case"30minutes":return o||Ym(t)||Zm(t,u)||Xm(t);case"hourly":return o||Ym(t)||Zm(t,u)||Xm(t);case"daily":return i?o||a||Xm(t):o||Zm(t,u)||Xm(t);case"monthly":return o||Xm(t);case"quarterly":return o||s;case"yearly":return!1;default:throw new Error(r+" is not a valid time interval.")}}function zm(t,e,n,r,i){var o=i.showDayName,a="daily"===r&&o?"weekly":r,s=new Date(t),u=Dd(i,"timeIntervalFormats")[a],l=Dd(u,"primary"),c=Dd(u,"secondary"),h=Gm(t,e,n,r,o)?l:c;"15seconds"===r&&0!==s.getMilliseconds()&&(h=h.replace("pp","h:mm:ss.SSS a"));var f=i.localeObject;return Bm(s,h,{locale:f})}function Fm(t){var e=new Date(t);return{M:e.getMonth()+1,d:e.getDate(),H:e.getHours(),m:e.getMinutes(),s:e.getSeconds()}}function Wm(t){if(t)return t.slice(1).map((function(e,n){return e-t[n]}))}function qm(t){var e=Hm.reduce((function(e,n,r){n[0];var i=n[1],o=Hm[e][1],a=Math.abs(o-t),s=Math.abs(i-t);return a<s?e:r}),0);return Hm[e][0]}function $m(t){if(1===t.length)return"15seconds";var e=Wm(t),n=Vm(e);return qm(n)}function Ym(t){var e=Fm(t),n=e.s,r=e.m,i=e.H;return 0===i&&0===r&&0===n}function Zm(t,e){var n=Fm(t).M,r=Fm(e).M;return n!==r}function Xm(t){var e=Fm(t),n=e.M,r=e.d,i=e.s,o=e.m,a=e.H;return 1===n&&1===r&&0===a&&0===o&&0===i}function Km(t){return void 0===t?"":t.toISOString()}var Qm=function(){return Qm=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},Qm.apply(this,arguments)},Jm=function(){function t(t){this.state={options:{}},this.colorScale={},this.colorClassNames={},this.services=t}return t.prototype.getAllDataFromDomain=function(t){if(!this.getData())return null;var e=this.getOptions(),n=this.getData(),r=this.getDataGroups(),i=Dd(e,"data").groupMapsTo,o=Dd(e,"axes");return t&&(n=n.filter((function(e){return t.includes(e[i])}))),o&&Object.keys(o).forEach((function(t){var e=o[t].mapsTo,r=o[t].scaleType;if(r!==G.LINEAR&&r!==G.LOG||(n=n.map((function(t){var n;return Qm(Qm({},t),(n={},n[e]=null===t[e]?t[e]:Number(t[e]),n))}))),e&&o[t].domain)if(r===G.LABELS)n=n.filter((function(n){return o[t].domain.includes(n[e])}));else{var i=o[t].domain,a=i[0],s=i[1];n=n.filter((function(t){return!(e in t)||t[e]>=a&&t[e]<=s}))}})),n.filter((function(t){return r.find((function(e){return e.name===t[i]}))}))},t.prototype.getDisplayData=function(t){if(!this.get("data"))return null;var e=Ot.items.status.ACTIVE,n=this.getDataGroups(t),r=this.getOptions().data.groupMapsTo,i=this.getAllDataFromDomain(t);return i.filter((function(t){return n.find((function(n){return n.name===t[r]&&n.status===e}))}))},t.prototype.getData=function(){return this.get("data")},t.prototype.isDataEmpty=function(){return!this.getData().length},t.prototype.setData=function(t){var e=this.sanitize(Od(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),e},t.prototype.getDataGroups=function(t){var e=Dd(this.getOptions(),"data","loading");return e?[]:t?this.get("dataGroups").filter((function(e){return t.includes(e.name)})):this.get("dataGroups")},t.prototype.getActiveDataGroups=function(t){var e=Ot.items.status.ACTIVE;return this.getDataGroups(t).filter((function(t){return t.status===e}))},t.prototype.getDataGroupNames=function(t){var e=this.getDataGroups(t);return e.map((function(t){return t.name}))},t.prototype.getActiveDataGroupNames=function(t){var e=this.getActiveDataGroups(t);return e.map((function(t){return t.name}))},t.prototype.aggregateBinDataByGroup=function(t){return El(t,"group")},t.prototype.getBinConfigurations=function(){var t=this,e=this.getDisplayData(),n=this.getOptions(),r=this.services.cartesianScales.getMainXAxisPosition(),i=this.services.cartesianScales.getDomainIdentifier(),o=n.axes[r],a=n.data.groupMapsTo,s=o.bins,u=void 0===s?wt.defaultBins:s,l=Array.isArray(u),c=ug().value((function(t){return t[i]})).thresholds(u)(e);if(l)c[c.length-1].x1=u[u.length-1];else{var h=c[0].x1-c[0].x0;c[c.length-1].x1=+c[c.length-1].x0+h}var f=l?[u[0],u[u.length-1]]:[c[0].x0,c[c.length-1].x1],p=Array.from(new Set(e.map((function(t){return t[a]})))),d=[];return c.forEach((function(e){var n=e.x0+"-"+e.x1,r=t.aggregateBinDataByGroup(e);p.forEach((function(t){d.push({group:t,key:n,value:r[t]||0,bin:e.x0})}))})),{bins:c,binsDomain:f}},t.prototype.getBinnedStackedData=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getActiveDataGroupNames(),r=this.getBinConfigurations().bins,i=this.getDataValuesGroupedByKeys({bins:r});return Nv().keys(n)(i).map((function(t,r){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(i){var o=t[i];return o[e]=n[r],o}))}))},t.prototype.getGroupedData=function(t){var e=this.getDisplayData(t),n={},r=this.getOptions().data.groupMapsTo;return e.map((function(t){var e=t[r];null!==n[e]&&void 0!==n[e]?n[e].push(t):n[e]=[t]})),Object.keys(n).map((function(t){return{name:t,data:n[t]}}))},t.prototype.getStackKeys=function(t){var e,n=this,r=void 0===t?{bins:null,groups:null}:t,i=r.bins,o=void 0===i?null:i,a=r.groups,s=void 0===a?null:a,u=this.getOptions(),l=this.getDisplayData(s);e=o?o.map((function(t){return t.x0+"-"+t.x1})):xd(l.map((function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return t[e]instanceof Date?Km(t[e]):t[e]&&"function"===typeof t[e].toString?t[e].toString():t[e]})));var c=this.services.cartesianScales.domainAxisPosition,h=u.axes[c].scaleType;return h===G.TIME?e.sort((function(t,e){var n=new Date(t),r=new Date(e);return n-r})):h!==G.LOG&&h!==G.LINEAR||e.sort((function(t,e){return t-e})),e},t.prototype.getDataValuesGroupedByKeys=function(t){var e=this,n=t.bins,r=void 0===n?null:n,i=t.groups,o=void 0===i?null:i,a=this.getOptions(),s=a.data.groupMapsTo,u=this.getDisplayData(o),l=this.getDataGroupNames(),c=this.getStackKeys({bins:r,groups:o});return r?c.map((function(t){var e=t.split("-"),n=e[0],i=e[1],o={x0:n,x1:i},a=r.find((function(t){return t.x0.toString()===n.toString()}));return l.forEach((function(t){o[t]=a.filter((function(e){return e[s]===t})).length})),o})):c.map((function(t){var n={sharedStackKey:t};return l.forEach((function(r){var i=u.find((function(n){var i=e.services.cartesianScales.getDomainIdentifier(n);return n[s]===r&&n.hasOwnProperty(i)&&(n[i]instanceof Date?Km(n[i])===t:n[i].toString()===t)})),o=e.services.cartesianScales.getRangeIdentifier(n);n[r]=i?i[o]:null})),n}))},t.prototype.getStackedData=function(t){var e=t.percentage,n=void 0!==e&&e,r=t.groups,i=void 0===r?null:r,o=t.divergent,a=void 0!==o&&o,s=this.getOptions(),u=s.data.groupMapsTo,l=this.getActiveDataGroupNames(i),c=this.getDataValuesGroupedByKeys({groups:i});if(n){var h=Jh(c.map((function(t){return[t.sharedStackKey,0]})));c.forEach((function(t){l.forEach((function(e){h[t.sharedStackKey]+=t[e]}))})),c.forEach((function(t){l.forEach((function(e){h[t.sharedStackKey]?t[e]=t[e]/h[t.sharedStackKey]*100:t[e]=0}))}))}var f=a?Nv().offset(jv):Nv();return f.keys(l)(c).map((function(t,e){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(n){var r=t[n];return r[u]=l[e],r}))}))},t.prototype.getOptions=function(){return this.state.options},t.prototype.set=function(t,e){this.state=Object.assign({},this.state,t);var n=Object.assign({skipUpdate:!1,animate:!0},e);n.skipUpdate||this.update(n.animate)},t.prototype.get=function(t){return t?this.state[t]:this.state},t.prototype.setOptions=function(t){var e=this.getOptions();Ld(e,t),this.set({options:na(e,t)})},t.prototype.update=function(t){void 0===t&&(t=!0),this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(ft.Model.UPDATE,{animate:t}))},t.prototype.toggleDataLabel=function(t){var e=Ot.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.getDataGroups(),o=i.some((function(t){return t.status===r})),a=i.filter((function(t){return t.status===n}));if(o)if(1===a.length&&a[0].name===t)i.forEach((function(t,e){i[e].status=n}));else{var s=i.findIndex((function(e){return e.name===t}));i[s].status=i[s].status===r?n:r}else i.forEach((function(e,o){i[o].status=e.name===t?n:r}));var u=i.filter((function(t){return t.status===n})),l=this.getOptions(),c=i.some((function(t){return t.status===r}));l.data.selectedGroups=c?u.map((function(t){return t.name})):[],this.services.events.dispatchEvent(ft.Legend.ITEMS_UPDATE,{dataGroups:i}),this.set({dataGroups:i})},t.prototype.getIsFilled=function(t,e,n,r){var i=this.getOptions();return i.getIsFilled?i.getIsFilled(t,e,n,r):r},t.prototype.getFillColor=function(t,e,n){var r=this.getOptions(),i=Dd(this.colorScale,t);return r.getFillColor?r.getFillColor(t,e,n,i):i},t.prototype.getStrokeColor=function(t,e,n){var r=this.getOptions(),i=Dd(this.colorScale,t);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.isUserProvidedColorScaleValid=function(){var t=Dd(this.getOptions(),"color","scale"),e=this.getDataGroups();return null!=t&&0!=Object.keys(t).length&&e.some((function(e){return Object.keys(t).includes(e.name)}))},t.prototype.getColorClassName=function(t){var e=this.colorClassNames(t.dataGroupName),n=t.originalClassName;return t.classNameTypes.forEach((function(r){return n=t.originalClassName?n+" "+r+"-"+e:r+"-"+e})),n},t.prototype.getStatus=function(){return null},t.prototype.getAllDataGroupsNames=function(){return this.allDataGroups},t.prototype.transformToTabularData=function(t){console.warn("We've updated the charting data format to be tabular by default. The current format you're using is deprecated and will be removed in v1.0, read more here https://carbon-design-system.github.io/carbon-charts/?path=/story/docs-tutorials--tabular-data-format");var e=[],n=t.datasets,r=t.labels;return n.forEach((function(t){t.data.forEach((function(n,i){var o,a=Dd(t,"label");if(null===a){var s=Dd(r,i);o=s||"Ungrouped"}else o=a;var u={group:o,key:r[i]};isNaN(n)?(u["value"]=n.value,u["date"]=n.date):u["value"]=n,e.push(u)}))})),e},t.prototype.getTabularDataArray=function(){return[]},t.prototype.exportToCSV=function(){var t=this.getTabularDataArray().map((function(t){return t.map((function(t){return'"'+("–"===t?"–":t)+'"'}))})),e="",n="";t.forEach((function(r,i){n=r.join(","),e+=i<t.length?n+"\n":n}));var r=this.getOptions(),i="myChart",o=Dd(r,"fileDownload","fileName");"function"===typeof o&&(i=o("csv")),this.services.files.downloadCSV(e,i+".csv")},t.prototype.getTabularData=function(t){return Array.isArray(t)?t:this.transformToTabularData(t)},t.prototype.sanitize=function(t){return t=this.getTabularData(t),t},t.prototype.updateAllDataGroups=function(){var t=this;this.allDataGroups?this.getDataGroupNames().forEach((function(e){-1===t.allDataGroups.indexOf(e)&&t.allDataGroups.push(e)})):this.allDataGroups=this.getDataGroupNames()},t.prototype.generateDataGroups=function(t){var e=this.getOptions().data.groupMapsTo,n=Ot.items.status,r=n.ACTIVE,i=n.DISABLED,o=this.getOptions(),a=xd(t.map((function(t){return t[e]})));if(o.data.selectedGroups.length){var s=o.data.selectedGroups.every((function(t){return a.includes(t)}));s||(o.data.selectedGroups=[])}var u=function(t){return!o.data.selectedGroups.length||o.data.selectedGroups.includes(t)?r:i};return a.map((function(t){return{name:t,status:u(t)}}))},t.prototype.setCustomColorScale=function(){var t=this;if(this.isUserProvidedColorScaleValid()){var e=this.getOptions(),n=Dd(e,"color","scale");Object.keys(n).forEach((function(e){t.allDataGroups.includes(e)||console.warn('"'+e+'" does not exist in data groups.')}));var r=this.allDataGroups.filter((function(t){return n[t]}));r.forEach((function(e){return t.colorScale[e]=n[e]}))}},t.prototype.setColorClassNames=function(){var t=Dd(this.getOptions(),"color","pairing"),e=Dd(t,"numberOfVariants");(!e||e<this.allDataGroups.length)&&(e=this.allDataGroups.length);var n=Dd(t,"option"),r=_t.pairingOptions,i=e>5?14:e;n=n<=r[i+"-color"]?n:1;var o=this.allDataGroups.map((function(t,e){return i+"-"+n+"-"+(e%14+1)}));this.colorClassNames=Cv().range(o).domain(this.allDataGroups)},t}(),ty=function(){function t(t,e){this.model=t,this.services=e,this.init()}return t.prototype.init=function(){},t.prototype.update=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t}();function ey(){}var ny=function(t){return null==t?ey:function(){return this.querySelector(t)}},ry=function(t){"function"!==typeof t&&(t=ny(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,l=r[i]=new Array(u),c=0;c<u;++c)(o=s[c])&&(a=t.call(o,o.__data__,c,s))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new K_(r,this._parents)};function iy(t){return null==t?[]:Array.isArray(t)?t:Array.from(t)}function oy(){return[]}var ay=function(t){return null==t?oy:function(){return this.querySelectorAll(t)}};function sy(t){return function(){return iy(t.apply(this,arguments))}}var uy=function(t){t="function"===typeof t?sy(t):ay(t);for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new K_(r,i)},ly=function(t){return function(){return this.matches(t)}};function cy(t){return function(e){return e.matches(t)}}var hy=Array.prototype.find;function fy(t){return function(){return hy.call(this.children,t)}}function py(){return this.firstElementChild}var dy=function(t){return this.select(null==t?py:fy("function"===typeof t?t:cy(t)))},vy=Array.prototype.filter;function gy(){return Array.from(this.children)}function my(t){return function(){return vy.call(this.children,t)}}var yy=function(t){return this.selectAll(null==t?gy:my("function"===typeof t?t:cy(t)))},_y=function(t){"function"!==typeof t&&(t=ly(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new K_(r,this._parents)},by=function(t){return new Array(t.length)},wy=function(){return new K_(this._enter||this._groups.map(by),this._parents)};function Oy(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Oy.prototype={constructor:Oy,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var xy=function(t){return function(){return t}};function Ey(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new Oy(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function Ty(t,e,n,r,i,o,a){var s,u,l,c=new Map,h=e.length,f=o.length,p=new Array(h);for(s=0;s<h;++s)(u=e[s])&&(p[s]=l=a.call(u,u.__data__,s,e)+"",c.has(l)?i[s]=u:c.set(l,u));for(s=0;s<f;++s)l=a.call(t,o[s],s,o)+"",(u=c.get(l))?(r[s]=u,u.__data__=o[s],c.delete(l)):n[s]=new Oy(t,o[s]);for(s=0;s<h;++s)(u=e[s])&&c.get(p[s])===u&&(i[s]=u)}function Sy(t){return t.__data__}var My=function(t,e){if(!arguments.length)return Array.from(this,Sy);var n=e?Ty:Ey,r=this._parents,i=this._groups;"function"!==typeof t&&(t=xy(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),l=0;l<o;++l){var c=r[l],h=i[l],f=h.length,p=Cy(t.call(c,c&&c.__data__,l,r)),d=p.length,v=s[l]=new Array(d),g=a[l]=new Array(d),m=u[l]=new Array(f);n(c,h,v,g,m,p,e);for(var y,_,b=0,w=0;b<d;++b)if(y=v[b]){b>=w&&(w=b+1);while(!(_=g[w])&&++w<d);y._next=_||null}}return a=new K_(a,r),a._enter=s,a._exit=u,a};function Cy(t){return"object"===typeof t&&"length"in t?t:Array.from(t)}var Ay=function(){return new K_(this._exit||this._groups.map(by),this._parents)},Ly=function(t,e,n){var r=this.enter(),i=this,o=this.exit();return"function"===typeof t?(r=t(r),r&&(r=r.selection())):r=r.append(t+""),null!=e&&(i=e(i),i&&(i=i.selection())),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},Dy=function(t){for(var e=t.selection?t.selection():t,n=this._groups,r=e._groups,i=n.length,o=r.length,a=Math.min(i,o),s=new Array(i),u=0;u<a;++u)for(var l,c=n[u],h=r[u],f=c.length,p=s[u]=new Array(f),d=0;d<f;++d)(l=c[d]||h[d])&&(p[d]=l);for(;u<i;++u)s[u]=n[u];return new K_(s,this._parents)},ky=function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},Py=function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Ry);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new K_(i,this._parents).order()};function Ry(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}var Iy=function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},Ny=function(){return Array.from(this)},jy=function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},By=function(){let t=0;for(const e of this)++t;return t},Uy=function(){return!this.node()},Vy=function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},Hy="http://www.w3.org/1999/xhtml",Gy={svg:"http://www.w3.org/2000/svg",xhtml:Hy,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},zy=function(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),Gy.hasOwnProperty(e)?{space:Gy[e],local:t}:t};function Fy(t){return function(){this.removeAttribute(t)}}function Wy(t){return function(){this.removeAttributeNS(t.space,t.local)}}function qy(t,e){return function(){this.setAttribute(t,e)}}function $y(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Yy(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Zy(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}var Xy=function(t,e){var n=zy(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?Wy:Fy:"function"===typeof e?n.local?Zy:Yy:n.local?$y:qy)(n,e))},Ky=function(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView};function Qy(t){return function(){this.style.removeProperty(t)}}function Jy(t,e,n){return function(){this.style.setProperty(t,e,n)}}function t_(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}var e_=function(t,e,n){return arguments.length>1?this.each((null==e?Qy:"function"===typeof e?t_:Jy)(t,e,null==n?"":n)):n_(this.node(),t)};function n_(t,e){return t.style.getPropertyValue(e)||Ky(t).getComputedStyle(t,null).getPropertyValue(e)}function r_(t){return function(){delete this[t]}}function i_(t,e){return function(){this[t]=e}}function o_(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}var a_=function(t,e){return arguments.length>1?this.each((null==e?r_:"function"===typeof e?o_:i_)(t,e)):this.node()[t]};function s_(t){return t.trim().split(/^|\s+/)}function u_(t){return t.classList||new l_(t)}function l_(t){this._node=t,this._names=s_(t.getAttribute("class")||"")}function c_(t,e){var n=u_(t),r=-1,i=e.length;while(++r<i)n.add(e[r])}function h_(t,e){var n=u_(t),r=-1,i=e.length;while(++r<i)n.remove(e[r])}function f_(t){return function(){c_(this,t)}}function p_(t){return function(){h_(this,t)}}function d_(t,e){return function(){(e.apply(this,arguments)?c_:h_)(this,t)}}l_.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var v_=function(t,e){var n=s_(t+"");if(arguments.length<2){var r=u_(this.node()),i=-1,o=n.length;while(++i<o)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"===typeof e?d_:e?f_:p_)(n,e))};function g_(){this.textContent=""}function m_(t){return function(){this.textContent=t}}function y_(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}var __=function(t){return arguments.length?this.each(null==t?g_:("function"===typeof t?y_:m_)(t)):this.node().textContent};function b_(){this.innerHTML=""}function w_(t){return function(){this.innerHTML=t}}function O_(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}var x_=function(t){return arguments.length?this.each(null==t?b_:("function"===typeof t?O_:w_)(t)):this.node().innerHTML};function E_(){this.nextSibling&&this.parentNode.appendChild(this)}var T_=function(){return this.each(E_)};function S_(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}var M_=function(){return this.each(S_)};function C_(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===Hy&&e.documentElement.namespaceURI===Hy?e.createElement(t):e.createElementNS(n,t)}}function A_(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}var L_=function(t){var e=zy(t);return(e.local?A_:C_)(e)},D_=function(t){var e="function"===typeof t?t:L_(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))};function k_(){return null}var P_=function(t,e){var n="function"===typeof t?t:L_(t),r=null==e?k_:"function"===typeof e?e:ny(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))};function R_(){var t=this.parentNode;t&&t.removeChild(this)}var I_=function(){return this.each(R_)};function N_(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function j_(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}var B_=function(t){return this.select(t?j_:N_)},U_=function(t){return arguments.length?this.property("__data__",t):this.node().__data__};function V_(t){return function(e){t.call(this,e,this.__data__)}}function H_(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function G_(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.options);++i?e.length=i:delete this.__on}}}function z_(t,e,n){return function(){var r,i=this.__on,o=V_(e);if(i)for(var a=0,s=i.length;a<s;++a)if((r=i[a]).type===t.type&&r.name===t.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),void(r.value=e);this.addEventListener(t.type,o,n),r={type:t.type,name:t.name,value:e,listener:o,options:n},i?i.push(r):this.__on=[r]}}var F_=function(t,e,n){var r,i,o=H_(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?z_:G_,r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value};function W_(t,e,n){var r=Ky(t),i=r.CustomEvent;"function"===typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function q_(t,e){return function(){return W_(this,t,e)}}function $_(t,e){return function(){return W_(this,t,e.apply(this,arguments))}}var Y_=function(t,e){return this.each(("function"===typeof e?$_:q_)(t,e))},Z_=function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r,i=t[e],o=0,a=i.length;o<a;++o)(r=i[o])&&(yield r)},X_=[null];function K_(t,e){this._groups=t,this._parents=e}function Q_(){return new K_([[document.documentElement]],X_)}function J_(){return this}K_.prototype=Q_.prototype={constructor:K_,select:ry,selectAll:uy,selectChild:dy,selectChildren:yy,filter:_y,data:My,enter:wy,exit:Ay,join:Ly,merge:Dy,selection:J_,order:ky,sort:Py,call:Iy,nodes:Ny,node:jy,size:By,empty:Uy,each:Vy,attr:Xy,style:e_,property:a_,classed:v_,text:__,html:x_,raise:T_,lower:M_,append:D_,insert:P_,remove:I_,clone:B_,datum:U_,on:F_,dispatch:Y_,[Symbol.iterator]:Z_};var tb=Q_,eb=function(t){return"string"===typeof t?new K_([[document.querySelector(t)]],[document.documentElement]):new K_([[t]],X_)},nb=n("2da1"),rb=n("69f2"),ib=n.n(rb),ob=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ab="DONT_STYLE_ME_css_styles_verifier",sb=function(t){function e(e,n){return t.call(this,e,n)||this}return ob(e,t),e.getHTMLElementSize=function(t){return{width:t.clientWidth,height:t.clientHeight}},e.getSVGElementSize=function(t,e){void 0===e&&(e={useAttrs:!1,useClientDimensions:!1,useBBox:!1,useBoundingRect:!1}),t.attr||(t=eb(t));var n,r,i,o,a={width:0,height:0},s=function(t){t&&Object.keys(a).forEach((function(e){if(t[e]){var n=t[e],r=parseFloat(n);n&&r>a[e]&&-1===(""+n).indexOf("%")&&(a[e]=r)}}))},u={width:t.attr("width"),height:t.attr("height")};try{n=t.node().getBBox(),r={width:n.width,height:n.height}}catch(h){}try{i=t.node().getBoundingClientRect(),o={width:i.width,height:i.height}}catch(h){}var l={width:t.node().clientWidth,height:t.node().clientHeight};if(e){if(e.useAttrs&&(s(u),a.width>0&&a.height>0))return a;if(e.useClientDimensions&&(s(l),a.width>0&&a.height>0))return l;if(e.useBBox&&(s(r),a.width>0&&a.height>0))return r;if(e.useBoundingRect&&(s(o),a.width>0&&a.height>0))return o}try{var c={width:Dd(t.node(),"width","baseVal","value"),height:Dd(t.node(),"height","baseVal","value")};s(c)}catch(h){s(l),s(r),s(u)}return a},e.appendOrSelect=function(t,e){var n=t.select(""+e);if(n.empty()){var r=e.split("#"),i=void 0,o=void 0;return 2===r.length?(i=r[0],r=r[1].split("."),o=r[0]):(r=e.split("."),i=r[0]),t.append(i).attr("id",o).attr("class",r.slice(1).join(" "))}return n},e.prototype.init=function(){this.styleHolderElement(),this.initializeID(),this.addMainContainer(),this.verifyCSSStylesBeingApplied(),this.model.getOptions().resizable&&this.addResizeListener(),this.addHolderListeners(),this.handleFullscreenChange()},e.prototype.getChartID=function(){return this.chartID},e.prototype.generateElementIDString=function(t){return"chart-"+this.chartID+"-"+t},e.prototype.initializeID=function(){this.chartID=Math.floor(281474976710656*(1+Math.random())).toString(16)},e.prototype.addMainContainer=function(){var t=this.model.getOptions(),e=Dd(t,"style","prefix"),n=eb(this.getHolder()).append("div").classed(dt+"--"+e+"--chart-wrapper",!0).attr("id","chart-"+this.getChartID()).style("height","100%").style("width","100%");n.append("g").attr("class",ab),this.mainContainer=n.node()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder(),e=this.model.getOptions(),n=e.width,r=e.height,i=e.theme;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r),eb(this.getHolder()).classed(dt+"--chart-holder",!0).attr("data-carbon-theme",i)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.exportToJPG=function(){var t=this,e=this.model.getOptions(),n=this.getHolder(),r=eb(n);r.classed("filled",!0),ib.a.toJpeg(this.getMainContainer(),{bgcolor:"undefined"!==typeof window?window.getComputedStyle(n).getPropertyValue("background-color"):void 0,quality:1,filter:function(t){return!t.classList||!t.classList.contains("cds--cc--toolbar")}}).then((function(n){var i="myChart",o=Dd(e,"fileDownload","fileName");"function"===typeof o&&(i=o("jpg")),t.services.files.downloadImage(n,i+".jpg"),r.classed("filled",!1)}))},e.prototype.exportToPNG=function(){var t=this,e=this.model.getOptions(),n=this.getHolder(),r=eb(n);r.classed("filled",!0),ib.a.toPng(this.getMainContainer(),{bgcolor:"undefined"!==typeof window?window.getComputedStyle(n).getPropertyValue("background-color"):void 0,quality:1,filter:function(t){return!t.classList||!t.classList.contains("cds--cc--toolbar")}}).then((function(n){var i="myChart",o=Dd(e,"fileDownload","fileName");"function"===typeof o&&(i=o("png")),t.services.files.downloadImage(n,i+".png"),r.classed("filled",!1)})).catch((function(t){console.error("oops, something went wrong!",t)}))},e.prototype.toggleFullscreen=function(){var t=this.getHolder(),e=eb(t),n=e.classed("fullscreen");n&&(document.fullscreenElement||document["webkitFullscreenElement"]||document["mozFullScreenElement"]||document["msFullscreenElement"])?document.exitFullscreen?document.exitFullscreen():document["webkitExitFullscreen"]?document["webkitExitFullscreen"]():document["mozCancelFullScreen"]?document["mozCancelFullScreen"]():document["msExitFullscreen"]&&document["msExitFullscreen"]():t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},e.prototype.handleFullscreenChange=function(){var t=this;document.addEventListener("fullscreenchange",(function(){var e=eb(t.getHolder()),n=e.classed("fullscreen");e.classed("fullscreen",!n)}))},e.prototype.verifyCSSStylesBeingApplied=function(){var t=this;setTimeout((function(){var e=eb(t.mainContainer).select("g."+ab).node(),n=getComputedStyle(e);"hidden"===n.getPropertyValue("overflow")&&"0"===n.getPropertyValue("opacity")||console.error("Missing CSS styles for Carbon Charts. Please read the Carbon Charts getting started guide.")}))},e.prototype.setSVGMaxHeight=function(){if(!this.model.getOptions().height){var t=e.getSVGElementSize(eb(this.mainContainer),{useBBox:!0}).height,n=eb(this.mainContainer).attr("class"),r=eb(this.mainContainer).selectAll("."+n+" > svg"),i=0;r.nodes().forEach((function(t){i+=Number(e.getSVGElementSize(eb(t),{useBBox:!0}).height)})),i<=t?eb(this.mainContainer).attr("height",i):eb(this.mainContainer).attr("height","100%")}},e.prototype.getMainContainer=function(){return this.mainContainer},e.prototype.addHolderListeners=function(){var t=this,e=this.getHolder();e&&eb(e).on("mouseover",(function(){t.services.events.dispatchEvent(ft.Chart.MOUSEOVER)})).on("mouseout",(function(){t.services.events.dispatchEvent(ft.Chart.MOUSEOUT)}))},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=Te((function(i,o){e&&(Math.abs(n-e.clientWidth)>1||Math.abs(r-e.clientHeight)>1)&&(n=e.clientWidth,r=e.clientHeight,t.services.events.dispatchEvent(ft.Chart.RESIZE))}),12.5),o=new nb["a"](i);o.observe(e)}},e}(ty),ub=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),lb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return ub(e,t),e.prototype.init=function(){this.documentFragment=document.createDocumentFragment()},e.prototype.addEventListener=function(t,e){this.documentFragment.addEventListener(t,e)},e.prototype.removeEventListener=function(t,e){this.documentFragment.removeEventListener(t,e)},e.prototype.dispatchEvent=function(t,e){var n;e?n=new CustomEvent(t,{detail:e}):(n=document.createEvent("Event"),n.initEvent(t,!1,!0)),this.documentFragment.dispatchEvent(n)},e}(ty),cb=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),hb=function(t){function e(e,n){return t.call(this,e,n)||this}return cb(e,t),e.prototype.downloadCSV=function(t,e){var n=document.createElement("a"),r="text/csv;encoding:utf-8";if(navigator["msSaveBlob"])navigator["msSaveBlob"](new Blob([t],{type:r}),e);else if(URL&&"download"in n){var i=URL.createObjectURL(new Blob([t],{type:r}));n.href=i,n.setAttribute("download",e),document.body.appendChild(n),n.click(),document.body.removeChild(n),URL.revokeObjectURL(i)}else location.href="data:application/octet-stream,"+encodeURIComponent(t)},e.prototype.downloadImage=function(t,e){var n=document.createElement("a");n.download=e,n.href=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)},e}(ty),fb=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),pb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return fb(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener(ft.Model.UPDATE,(function(){t.pendingTransitions={}}))},e.prototype.setupTransition=function(t){var e=this,n=t.transition,r=t.name,i=t.animate;return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),!1===this.model.getOptions().animations||!1===i?n.duration(0):n.duration(Dd(Dt,r,"duration")||Dt.default.duration)},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(ty),db=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),vb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return db(e,t),e.appendOrUpdateLinearGradient=function(t){var e=t.svg.select("defs linearGradient#"+t.id);e.empty()&&(e=t.svg.append("defs").append("linearGradient").attr("id",t.id).attr("x1",t.x1).attr("x2",t.x2).attr("y1",t.y1).attr("y2",t.y2)),e.selectAll("stop").remove(),e.selectAll("stop").data(t.stops).enter().append("stop").attr("offset",(function(t){return t.offset})).style("stop-color",(function(t){return t.color})).style("stop-opacity",(function(t){return t.opacity}))},e.getOffsetRatio=function(t){var e=(100*Math.abs(t[1])/Math.abs(t[0]-t[1])).toFixed(2)+"%";return e},e.getStops=function(t,n){var r=t[0]<0&&t[1]>0,i=[{offset:"0%",color:n,opacity:"0.6"},{offset:"80%",color:n,opacity:"0"}];return r&&(i=[{offset:"0%",color:n,opacity:"0.6"},{offset:e.getOffsetRatio(t),color:n,opacity:"0"},{offset:"100%",color:n,opacity:"0.6"}]),i},e}(ty);const gb=1e3,mb=60*gb,yb=60*mb,_b=24*yb,bb=7*_b,wb=30*_b,Ob=365*_b,xb=new Date,Eb=new Date;function Tb(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=e=>(t(e=new Date(+e)),e),i.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),i.round=t=>{const e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=(t,n)=>(e(t=new Date(+t),null==n?1:Math.floor(n)),t),i.range=(n,r,o)=>{const a=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r)||!(o>0))return a;let s;do{a.push(s=new Date(+n)),e(n,o),t(n)}while(s<n&&n<r);return a},i.filter=n=>Tb(e=>{if(e>=e)while(t(e),!n(e))e.setTime(e-1)},(t,r)=>{if(t>=t)if(r<0)while(++r<=0)while(e(t,-1),!n(t));else while(--r>=0)while(e(t,1),!n(t));}),n&&(i.count=(e,r)=>(xb.setTime(+e),Eb.setTime(+r),t(xb),t(Eb),Math.floor(n(xb,Eb))),i.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?e=>r(e)%t===0:e=>i.count(0,e)%t===0):i:null)),i}const Sb=Tb(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Sb.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?Tb(e=>{e.setTime(Math.floor(e/t)*t)},(e,n)=>{e.setTime(+e+n*t)},(e,n)=>(n-e)/t):Sb:null);Sb.range;const Mb=Tb(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*gb)},(t,e)=>(e-t)/gb,t=>t.getUTCSeconds()),Cb=(Mb.range,Tb(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*gb)},(t,e)=>{t.setTime(+t+e*mb)},(t,e)=>(e-t)/mb,t=>t.getMinutes())),Ab=(Cb.range,Tb(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*mb)},(t,e)=>(e-t)/mb,t=>t.getUTCMinutes())),Lb=(Ab.range,Tb(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*gb-t.getMinutes()*mb)},(t,e)=>{t.setTime(+t+e*yb)},(t,e)=>(e-t)/yb,t=>t.getHours())),Db=(Lb.range,Tb(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*yb)},(t,e)=>(e-t)/yb,t=>t.getUTCHours())),kb=(Db.range,Tb(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*mb)/_b,t=>t.getDate()-1)),Pb=(kb.range,Tb(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_b,t=>t.getUTCDate()-1)),Rb=(Pb.range,Tb(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/_b,t=>Math.floor(t/_b)));Rb.range;function Ib(t){return Tb(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(t,e)=>{t.setDate(t.getDate()+7*e)},(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*mb)/bb)}const Nb=Ib(0),jb=Ib(1),Bb=Ib(2),Ub=Ib(3),Vb=Ib(4),Hb=Ib(5),Gb=Ib(6);Nb.range,jb.range,Bb.range,Ub.range,Vb.range,Hb.range,Gb.range;function zb(t){return Tb(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)},(t,e)=>(e-t)/bb)}const Fb=zb(0),Wb=zb(1),qb=zb(2),$b=zb(3),Yb=zb(4),Zb=zb(5),Xb=zb(6),Kb=(Fb.range,Wb.range,qb.range,$b.range,Yb.range,Zb.range,Xb.range,Tb(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear()),t=>t.getMonth())),Qb=(Kb.range,Tb(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear()),t=>t.getUTCMonth())),Jb=(Qb.range,Tb(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear()));Jb.every=t=>isFinite(t=Math.floor(t))&&t>0?Tb(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,n)=>{e.setFullYear(e.getFullYear()+n*t)}):null;Jb.range;const tw=Tb(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());tw.every=t=>isFinite(t=Math.floor(t))&&t>0?Tb(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)}):null;tw.range;function ew(t,e,n,r,i,o){const a=[[Mb,1,gb],[Mb,5,5*gb],[Mb,15,15*gb],[Mb,30,30*gb],[o,1,mb],[o,5,5*mb],[o,15,15*mb],[o,30,30*mb],[i,1,yb],[i,3,3*yb],[i,6,6*yb],[i,12,12*yb],[r,1,_b],[r,2,2*_b],[n,1,bb],[e,1,wb],[e,3,3*wb],[t,1,Ob]];function s(t,e,n){const r=e<t;r&&([t,e]=[e,t]);const i=n&&"function"===typeof n.range?n:u(t,e,n),o=i?i.range(t,+e+1):[];return r?o.reverse():o}function u(e,n,r){const i=Math.abs(n-e)/r,o=Gv(([,,t])=>t).right(a,i);if(o===a.length)return t.every(ig(e/Ob,n/Ob,r));if(0===o)return Sb.every(Math.max(ig(e,n,r),1));const[s,u]=a[i/a[o-1][2]<a[o][2]/i?o-1:o];return s.every(u)}return[s,u]}const[nw,rw]=ew(tw,Qb,Fb,Rb,Db,Ab),[iw,ow]=ew(Jb,Kb,Nb,kb,Lb,Cb);function aw(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function sw(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function uw(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function lw(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,l=yw(i),c=_w(i),h=yw(o),f=_w(o),p=yw(a),d=_w(a),v=yw(s),g=_w(s),m=yw(u),y=_w(u),_={a:P,A:R,b:I,B:N,c:null,d:Vw,e:Vw,f:Ww,g:nO,G:iO,H:Hw,I:Gw,j:zw,L:Fw,m:qw,M:$w,p:j,q:B,Q:MO,s:CO,S:Yw,u:Zw,U:Xw,V:Qw,w:Jw,W:tO,x:null,X:null,y:eO,Y:rO,Z:oO,"%":SO},b={a:U,A:V,b:H,B:G,c:null,d:aO,e:aO,f:hO,g:OO,G:EO,H:sO,I:uO,j:lO,L:cO,m:fO,M:pO,p:z,q:F,Q:MO,s:CO,S:dO,u:vO,U:gO,V:yO,w:_O,W:bO,x:null,X:null,y:wO,Y:xO,Z:TO,"%":SO},w={a:S,A:M,b:C,B:A,c:L,d:Lw,e:Lw,f:Nw,g:Sw,G:Tw,H:kw,I:kw,j:Dw,L:Iw,m:Aw,M:Pw,p:T,q:Cw,Q:Bw,s:Uw,S:Rw,u:ww,U:Ow,V:xw,w:bw,W:Ew,x:D,X:k,y:Sw,Y:Tw,Z:Mw,"%":jw};function O(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;n instanceof Date||(n=new Date(+n));while(++s<l)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=fw[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function x(t,e){return function(n){var r,i,o=uw(1900,void 0,1),a=E(o,t,n+="",0);if(a!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(r=sw(uw(o.y,0,1)),i=r.getUTCDay(),r=i>4||0===i?Wb.ceil(r):Wb(r),r=Pb.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(r=aw(uw(o.y,0,1)),i=r.getDay(),r=i>4||0===i?jb.ceil(r):jb(r),r=kb.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?sw(uw(o.y,0,1)).getUTCDay():aw(uw(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,sw(o)):aw(o)}}function E(t,e,n,r){var i,o,a=0,s=e.length,u=n.length;while(a<s){if(r>=u)return-1;if(i=e.charCodeAt(a++),37===i){if(i=e.charAt(a++),o=w[i in fw?e.charAt(a++):i],!o||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function T(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c.get(r[0].toLowerCase()),n+r[0].length):-1}function S(t,e,n){var r=p.exec(e.slice(n));return r?(t.w=d.get(r[0].toLowerCase()),n+r[0].length):-1}function M(t,e,n){var r=h.exec(e.slice(n));return r?(t.w=f.get(r[0].toLowerCase()),n+r[0].length):-1}function C(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=y.get(r[0].toLowerCase()),n+r[0].length):-1}function A(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=g.get(r[0].toLowerCase()),n+r[0].length):-1}function L(t,n,r){return E(t,e,n,r)}function D(t,e,r){return E(t,n,e,r)}function k(t,e,n){return E(t,r,e,n)}function P(t){return a[t.getDay()]}function R(t){return o[t.getDay()]}function I(t){return u[t.getMonth()]}function N(t){return s[t.getMonth()]}function j(t){return i[+(t.getHours()>=12)]}function B(t){return 1+~~(t.getMonth()/3)}function U(t){return a[t.getUTCDay()]}function V(t){return o[t.getUTCDay()]}function H(t){return u[t.getUTCMonth()]}function G(t){return s[t.getUTCMonth()]}function z(t){return i[+(t.getUTCHours()>=12)]}function F(t){return 1+~~(t.getUTCMonth()/3)}return _.x=O(n,_),_.X=O(r,_),_.c=O(e,_),b.x=O(n,b),b.X=O(r,b),b.c=O(e,b),{format:function(t){var e=O(t+="",_);return e.toString=function(){return t},e},parse:function(t){var e=x(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=O(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=x(t+="",!0);return e.toString=function(){return t},e}}}var cw,hw,fw={"-":"",_:" ",0:"0"},pw=/^\s*\d+/,dw=/^%/,vw=/[\\^$*+?|[\]().{}]/g;function gw(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function mw(t){return t.replace(vw,"\\$&")}function yw(t){return new RegExp("^(?:"+t.map(mw).join("|")+")","i")}function _w(t){return new Map(t.map((t,e)=>[t.toLowerCase(),e]))}function bw(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function ww(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function Ow(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function xw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Ew(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function Tw(t,e,n){var r=pw.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function Sw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Mw(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Cw(t,e,n){var r=pw.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function Aw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function Lw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function Dw(t,e,n){var r=pw.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function kw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function Pw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function Rw(t,e,n){var r=pw.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function Iw(t,e,n){var r=pw.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function Nw(t,e,n){var r=pw.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function jw(t,e,n){var r=dw.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function Bw(t,e,n){var r=pw.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function Uw(t,e,n){var r=pw.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function Vw(t,e){return gw(t.getDate(),e,2)}function Hw(t,e){return gw(t.getHours(),e,2)}function Gw(t,e){return gw(t.getHours()%12||12,e,2)}function zw(t,e){return gw(1+kb.count(Jb(t),t),e,3)}function Fw(t,e){return gw(t.getMilliseconds(),e,3)}function Ww(t,e){return Fw(t,e)+"000"}function qw(t,e){return gw(t.getMonth()+1,e,2)}function $w(t,e){return gw(t.getMinutes(),e,2)}function Yw(t,e){return gw(t.getSeconds(),e,2)}function Zw(t){var e=t.getDay();return 0===e?7:e}function Xw(t,e){return gw(Nb.count(Jb(t)-1,t),e,2)}function Kw(t){var e=t.getDay();return e>=4||0===e?Vb(t):Vb.ceil(t)}function Qw(t,e){return t=Kw(t),gw(Vb.count(Jb(t),t)+(4===Jb(t).getDay()),e,2)}function Jw(t){return t.getDay()}function tO(t,e){return gw(jb.count(Jb(t)-1,t),e,2)}function eO(t,e){return gw(t.getFullYear()%100,e,2)}function nO(t,e){return t=Kw(t),gw(t.getFullYear()%100,e,2)}function rO(t,e){return gw(t.getFullYear()%1e4,e,4)}function iO(t,e){var n=t.getDay();return t=n>=4||0===n?Vb(t):Vb.ceil(t),gw(t.getFullYear()%1e4,e,4)}function oO(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+gw(e/60|0,"0",2)+gw(e%60,"0",2)}function aO(t,e){return gw(t.getUTCDate(),e,2)}function sO(t,e){return gw(t.getUTCHours(),e,2)}function uO(t,e){return gw(t.getUTCHours()%12||12,e,2)}function lO(t,e){return gw(1+Pb.count(tw(t),t),e,3)}function cO(t,e){return gw(t.getUTCMilliseconds(),e,3)}function hO(t,e){return cO(t,e)+"000"}function fO(t,e){return gw(t.getUTCMonth()+1,e,2)}function pO(t,e){return gw(t.getUTCMinutes(),e,2)}function dO(t,e){return gw(t.getUTCSeconds(),e,2)}function vO(t){var e=t.getUTCDay();return 0===e?7:e}function gO(t,e){return gw(Fb.count(tw(t)-1,t),e,2)}function mO(t){var e=t.getUTCDay();return e>=4||0===e?Yb(t):Yb.ceil(t)}function yO(t,e){return t=mO(t),gw(Yb.count(tw(t),t)+(4===tw(t).getUTCDay()),e,2)}function _O(t){return t.getUTCDay()}function bO(t,e){return gw(Wb.count(tw(t)-1,t),e,2)}function wO(t,e){return gw(t.getUTCFullYear()%100,e,2)}function OO(t,e){return t=mO(t),gw(t.getUTCFullYear()%100,e,2)}function xO(t,e){return gw(t.getUTCFullYear()%1e4,e,4)}function EO(t,e){var n=t.getUTCDay();return t=n>=4||0===n?Yb(t):Yb.ceil(t),gw(t.getUTCFullYear()%1e4,e,4)}function TO(){return"+0000"}function SO(){return"%"}function MO(t){return+t}function CO(t){return Math.floor(+t/1e3)}function AO(t){return cw=lw(t),hw=cw.format,cw.parse,cw.utcFormat,cw.utcParse,cw}AO({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var LO=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function DO(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function kO(){}var PO=.7,RO=1/PO,IO="\\s*([+-]?\\d+)\\s*",NO="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",jO="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",BO=/^#([0-9a-f]{3,8})$/,UO=new RegExp(`^rgb\\(${IO},${IO},${IO}\\)$`),VO=new RegExp(`^rgb\\(${jO},${jO},${jO}\\)$`),HO=new RegExp(`^rgba\\(${IO},${IO},${IO},${NO}\\)$`),GO=new RegExp(`^rgba\\(${jO},${jO},${jO},${NO}\\)$`),zO=new RegExp(`^hsl\\(${NO},${jO},${jO}\\)$`),FO=new RegExp(`^hsla\\(${NO},${jO},${jO},${NO}\\)$`),WO={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function qO(){return this.rgb().formatHex()}function $O(){return this.rgb().formatHex8()}function YO(){return lx(this).formatHsl()}function ZO(){return this.rgb().formatRgb()}function XO(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=BO.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?KO(e):3===n?new ex(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?QO(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?QO(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=UO.exec(t))?new ex(e[1],e[2],e[3],1):(e=VO.exec(t))?new ex(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=HO.exec(t))?QO(e[1],e[2],e[3],e[4]):(e=GO.exec(t))?QO(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=zO.exec(t))?ux(e[1],e[2]/100,e[3]/100,1):(e=FO.exec(t))?ux(e[1],e[2]/100,e[3]/100,e[4]):WO.hasOwnProperty(t)?KO(WO[t]):"transparent"===t?new ex(NaN,NaN,NaN,0):null}function KO(t){return new ex(t>>16&255,t>>8&255,255&t,1)}function QO(t,e,n,r){return r<=0&&(t=e=n=NaN),new ex(t,e,n,r)}function JO(t){return t instanceof kO||(t=XO(t)),t?(t=t.rgb(),new ex(t.r,t.g,t.b,t.opacity)):new ex}function tx(t,e,n,r){return 1===arguments.length?JO(t):new ex(t,e,n,null==r?1:r)}function ex(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function nx(){return`#${sx(this.r)}${sx(this.g)}${sx(this.b)}`}function rx(){return`#${sx(this.r)}${sx(this.g)}${sx(this.b)}${sx(255*(isNaN(this.opacity)?1:this.opacity))}`}function ix(){const t=ox(this.opacity);return`${1===t?"rgb(":"rgba("}${ax(this.r)}, ${ax(this.g)}, ${ax(this.b)}${1===t?")":`, ${t})`}`}function ox(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function ax(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function sx(t){return t=ax(t),(t<16?"0":"")+t.toString(16)}function ux(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new hx(t,e,n,r)}function lx(t){if(t instanceof hx)return new hx(t.h,t.s,t.l,t.opacity);if(t instanceof kO||(t=XO(t)),!t)return new hx;if(t instanceof hx)return t;t=t.rgb();var e=t.r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new hx(a,s,u,t.opacity)}function cx(t,e,n,r){return 1===arguments.length?lx(t):new hx(t,e,n,null==r?1:r)}function hx(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function fx(t){return t=(t||0)%360,t<0?t+360:t}function px(t){return Math.max(0,Math.min(1,t||0))}function dx(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function vx(t,e,n,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*r+a*i)/6}LO(kO,XO,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:qO,formatHex:qO,formatHex8:$O,formatHsl:YO,formatRgb:ZO,toString:ZO}),LO(ex,tx,DO(kO,{brighter(t){return t=null==t?RO:Math.pow(RO,t),new ex(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?PO:Math.pow(PO,t),new ex(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new ex(ax(this.r),ax(this.g),ax(this.b),ox(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:nx,formatHex:nx,formatHex8:rx,formatRgb:ix,toString:ix})),LO(hx,cx,DO(kO,{brighter(t){return t=null==t?RO:Math.pow(RO,t),new hx(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?PO:Math.pow(PO,t),new hx(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new ex(dx(t>=240?t-240:t+120,i,r),dx(t,i,r),dx(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new hx(fx(this.h),px(this.s),px(this.l),ox(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=ox(this.opacity);return`${1===t?"hsl(":"hsla("}${fx(this.h)}, ${100*px(this.s)}%, ${100*px(this.l)}%${1===t?")":`, ${t})`}`}}));var gx=function(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,s=r<e-1?t[r+2]:2*o-i;return vx((n-r/e)*e,a,i,o,s)}},mx=function(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),i=t[(r+e-1)%e],o=t[r%e],a=t[(r+1)%e],s=t[(r+2)%e];return vx((n-r/e)*e,i,o,a,s)}},yx=t=>()=>t;function _x(t,e){return function(n){return t+n*e}}function bx(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}function wx(t){return 1===(t=+t)?Ox:function(e,n){return n-e?bx(e,n,t):yx(isNaN(e)?n:e)}}function Ox(t,e){var n=e-t;return n?_x(t,n):yx(isNaN(t)?e:t)}var xx=function t(e){var n=wx(e);function r(t,e){var r=n((t=tx(t)).r,(e=tx(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=Ox(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function Ex(t){return function(e){var n,r,i=e.length,o=new Array(i),a=new Array(i),s=new Array(i);for(n=0;n<i;++n)r=tx(e[n]),o[n]=r.r||0,a[n]=r.g||0,s[n]=r.b||0;return o=t(o),a=t(a),s=t(s),r.opacity=1,function(t){return r.r=o(t),r.g=a(t),r.b=s(t),r+""}}}Ex(gx),Ex(mx);var Tx=function(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}};function Sx(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Mx(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=Nx(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}var Cx=function(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}},Ax=function(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}},Lx=function(t,e){var n,r={},i={};for(n in null!==t&&"object"===typeof t||(t={}),null!==e&&"object"===typeof e||(e={}),e)n in t?r[n]=Nx(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}},Dx=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,kx=new RegExp(Dx.source,"g");function Px(t){return function(){return t}}function Rx(t){return function(e){return t(e)+""}}var Ix=function(t,e){var n,r,i,o=Dx.lastIndex=kx.lastIndex=0,a=-1,s=[],u=[];t+="",e+="";while((n=Dx.exec(t))&&(r=kx.exec(e)))(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:Ax(n,r)})),o=kx.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?Rx(u[0].x):Px(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})},Nx=function(t,e){var n,r=typeof e;return null==e||"boolean"===r?yx(e):("number"===r?Ax:"string"===r?(n=XO(e))?(e=n,xx):Ix:e instanceof XO?xx:e instanceof Date?Cx:Sx(e)?Tx:Array.isArray(e)?Mx:"function"!==typeof e.valueOf&&"function"!==typeof e.toString||isNaN(e)?Lx:Ax)(t,e)},jx=function(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}};function Bx(t){return function(){return t}}function Ux(t){return+t}var Vx=[0,1];function Hx(t){return t}function Gx(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:Bx(isNaN(e)?NaN:.5)}function zx(t,e){var n;return t>e&&(n=t,t=e,e=n),function(n){return Math.max(t,Math.min(e,n))}}function Fx(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=Gx(i,r),o=n(a,o)):(r=Gx(r,i),o=n(o,a)),function(t){return o(r(t))}}function Wx(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());while(++a<r)i[a]=Gx(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=Yv(t,e,1,r)-1;return o[n](i[n](e))}}function qx(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function $x(){var t,e,n,r,i,o,a=Vx,s=Vx,u=Nx,l=Hx;function c(){var t=Math.min(a.length,s.length);return l!==Hx&&(l=zx(a[0],a[t-1])),r=t>2?Wx:Fx,i=o=null,h}function h(e){return null==e||isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return h.invert=function(n){return l(e((o||(o=r(s,a.map(t),Ax)))(n)))},h.domain=function(t){return arguments.length?(a=Array.from(t,Ux),c()):a.slice()},h.range=function(t){return arguments.length?(s=Array.from(t),c()):s.slice()},h.rangeRound=function(t){return s=Array.from(t),u=jx,c()},h.clamp=function(t){return arguments.length?(l=!!t||Hx,c()):l!==Hx},h.interpolate=function(t){return arguments.length?(u=t,c()):u},h.unknown=function(t){return arguments.length?(n=t,h):n},function(n,r){return t=n,e=r,c()}}function Yx(){return $x()(Hx,Hx)}function Zx(t,e){t=t.slice();var n,r=0,i=t.length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function Xx(t){return new Date(t)}function Kx(t){return t instanceof Date?+t:+new Date(+t)}function Qx(t,e,n,r,i,o,a,s,u,l){var c=Yx(),h=c.invert,f=c.domain,p=l(".%L"),d=l(":%S"),v=l("%I:%M"),g=l("%I %p"),m=l("%a %d"),y=l("%b %d"),_=l("%B"),b=l("%Y");function w(t){return(u(t)<t?p:s(t)<t?d:a(t)<t?v:o(t)<t?g:r(t)<t?i(t)<t?m:y:n(t)<t?_:b)(t)}return c.invert=function(t){return new Date(h(t))},c.domain=function(t){return arguments.length?f(Array.from(t,Kx)):f().map(Xx)},c.ticks=function(e){var n=f();return t(n[0],n[n.length-1],null==e?10:e)},c.tickFormat=function(t,e){return null==e?w:l(e)},c.nice=function(t){var n=f();return t&&"function"===typeof t.range||(t=e(n[0],n[n.length-1],null==t?10:t)),t?f(Zx(n,t)):c},c.copy=function(){return qx(c,Qx(t,e,n,r,i,o,a,s,u,l))},c}function Jx(){return Sv.apply(Qx(iw,ow,Jb,Kb,Nb,kb,Lb,Cb,Mb,hw).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var tE=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function eE(t){if(!(e=tE.exec(t)))throw new Error("invalid format: "+t);var e;return new nE({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function nE(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}eE.prototype=nE.prototype,nE.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rE=function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)};function iE(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}var oE,aE,sE,uE,lE=function(t){return t=iE(Math.abs(t)),t?t[1]:NaN},cE=function(t,e){return function(n,r){var i=n.length,o=[],a=0,s=t[0],u=0;while(i>0&&s>0){if(u+s+1>r&&(s=Math.max(1,r-u)),o.push(n.substring(i-=s,i+s)),(u+=s+1)>r)break;s=t[a=(a+1)%t.length]}return o.reverse().join(e)}},hE=function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}},fE=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0);break}return i>0?t.slice(0,i)+t.slice(e+1):t},pE=function(t,e){var n=iE(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(oE=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+iE(t,Math.max(0,e+o-1))[0]},dE=function(t,e){var n=iE(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")},vE={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:rE,e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>dE(100*t,e),r:dE,s:pE,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)},gE=function(t){return t},mE=Array.prototype.map,yE=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"],_E=function(t){var e=void 0===t.grouping||void 0===t.thousands?gE:cE(mE.call(t.grouping,Number),t.thousands+""),n=void 0===t.currency?"":t.currency[0]+"",r=void 0===t.currency?"":t.currency[1]+"",i=void 0===t.decimal?".":t.decimal+"",o=void 0===t.numerals?gE:hE(mE.call(t.numerals,String)),a=void 0===t.percent?"%":t.percent+"",s=void 0===t.minus?"−":t.minus+"",u=void 0===t.nan?"NaN":t.nan+"";function l(t){t=eE(t);var l=t.fill,c=t.align,h=t.sign,f=t.symbol,p=t.zero,d=t.width,v=t.comma,g=t.precision,m=t.trim,y=t.type;"n"===y?(v=!0,y="g"):vE[y]||(void 0===g&&(g=12),m=!0,y="g"),(p||"0"===l&&"="===c)&&(p=!0,l="0",c="=");var _="$"===f?n:"#"===f&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",b="$"===f?r:/[%p]/.test(y)?a:"",w=vE[y],O=/[defgprs%]/.test(y);function x(t){var n,r,a,f=_,x=b;if("c"===y)x=w(t)+x,t="";else{t=+t;var E=t<0||1/t<0;if(t=isNaN(t)?u:w(Math.abs(t),g),m&&(t=fE(t)),E&&0===+t&&"+"!==h&&(E=!1),f=(E?"("===h?h:s:"-"===h||"("===h?"":h)+f,x=("s"===y?yE[8+oE/3]:"")+x+(E&&"("===h?")":""),O){n=-1,r=t.length;while(++n<r)if(a=t.charCodeAt(n),48>a||a>57){x=(46===a?i+t.slice(n+1):t.slice(n))+x,t=t.slice(0,n);break}}}v&&!p&&(t=e(t,1/0));var T=f.length+t.length+x.length,S=T<d?new Array(d-T+1).join(l):"";switch(v&&p&&(t=e(S+t,S.length?d-x.length:1/0),S=""),c){case"<":t=f+t+x+S;break;case"=":t=f+S+t+x;break;case"^":t=S.slice(0,T=S.length>>1)+f+t+x+S.slice(T);break;default:t=S+f+t+x;break}return o(t)}return g=void 0===g?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),x.toString=function(){return t+""},x}function c(t,e){var n=l((t=eE(t),t.type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(lE(e)/3))),i=Math.pow(10,-r),o=yE[8+r/3];return function(t){return n(i*t)+o}}return{format:l,formatPrefix:c}};function bE(t){return aE=_E(t),sE=aE.format,uE=aE.formatPrefix,aE}function wE(t){return Math.log(t)}function OE(t){return Math.exp(t)}function xE(t){return-Math.log(-t)}function EE(t){return-Math.exp(-t)}function TE(t){return isFinite(t)?+("1e"+t):t<0?0:t}function SE(t){return 10===t?TE:t===Math.E?Math.exp:e=>Math.pow(t,e)}function ME(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}function CE(t){return(e,n)=>-t(-e,n)}function AE(t){const e=t(wE,OE),n=e.domain;let r,i,o=10;function a(){return r=ME(o),i=SE(o),n()[0]<0?(r=CE(r),i=CE(i),t(xE,EE)):t(wE,OE),e}return e.base=function(t){return arguments.length?(o=+t,a()):o},e.domain=function(t){return arguments.length?(n(t),a()):n()},e.ticks=t=>{const e=n();let a=e[0],s=e[e.length-1];const u=s<a;u&&([a,s]=[s,a]);let l,c,h=r(a),f=r(s);const p=null==t?10:+t;let d=[];if(!(o%1)&&f-h<p){if(h=Math.floor(h),f=Math.ceil(f),a>0){for(;h<=f;++h)for(l=1;l<o;++l)if(c=h<0?l/i(-h):l*i(h),!(c<a)){if(c>s)break;d.push(c)}}else for(;h<=f;++h)for(l=o-1;l>=1;--l)if(c=h>0?l/i(-h):l*i(h),!(c<a)){if(c>s)break;d.push(c)}2*d.length<p&&(d=ng(a,s,p))}else d=ng(h,f,Math.min(f-h,p)).map(i);return u?d.reverse():d},e.tickFormat=(t,n)=>{if(null==t&&(t=10),null==n&&(n=10===o?"s":","),"function"!==typeof n&&(o%1||null!=(n=eE(n)).precision||(n.trim=!0),n=sE(n)),t===1/0)return n;const a=Math.max(1,o*t/e.ticks().length);return t=>{let e=t/i(Math.round(r(t)));return e*o<o-.5&&(e*=o),e<=a?n(t):""}},e.nice=()=>n(Zx(n(),{floor:t=>i(Math.floor(r(t))),ceil:t=>i(Math.ceil(r(t)))})),e}function LE(){const t=AE($x()).domain([1,10]);return t.copy=()=>qx(t,LE()).base(t.base()),Sv.apply(t,arguments),t}function DE(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);while(++r<i)o[r]=t+r*n;return o}function kE(){var t,e,n=Cv().unknown(void 0),r=n.domain,i=n.range,o=0,a=1,s=!1,u=0,l=0,c=.5;function h(){var n=r().length,h=a<o,f=h?a:o,p=h?o:a;t=(p-f)/Math.max(1,n-u+2*l),s&&(t=Math.floor(t)),f+=(p-f-t*(n-u))*c,e=t*(1-u),s&&(f=Math.round(f),e=Math.round(e));var d=DE(n).map((function(e){return f+t*e}));return i(h?d.reverse():d)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),h()):r()},n.range=function(t){return arguments.length?([o,a]=t,o=+o,a=+a,h()):[o,a]},n.rangeRound=function(t){return[o,a]=t,o=+o,a=+a,s=!0,h()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(s=!!t,h()):s},n.padding=function(t){return arguments.length?(u=Math.min(1,l=+t),h()):u},n.paddingInner=function(t){return arguments.length?(u=Math.min(1,t),h()):u},n.paddingOuter=function(t){return arguments.length?(l=+t,h()):l},n.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),h()):c},n.copy=function(){return kE(r(),[o,a]).round(s).paddingInner(u).paddingOuter(l).align(c)},Sv.apply(h(),arguments)}bE({thousands:",",grouping:[3],currency:["$",""]});var PE=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(lE(e)/3)))-lE(Math.abs(t)))},RE=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,lE(e)-lE(t))+1},IE=function(t){return Math.max(0,-lE(Math.abs(t)))};function NE(t,e,n,r){var i,o=ig(t,e,n);switch(r=eE(null==r?",f":r),r.type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=PE(o,a))||(r.precision=i),uE(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=RE(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=IE(o))||(r.precision=i-2*("%"===r.type));break}return sE(r)}function jE(t){var e=t.domain;return t.ticks=function(t){var n=e();return ng(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return NE(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i,o=e(),a=0,s=o.length-1,u=o[a],l=o[s],c=10;l<u&&(i=u,u=l,l=i,i=a,a=s,s=i);while(c-- >0){if(i=rg(u,l,n),i===r)return o[a]=u,o[s]=l,e(o);if(i>0)u=Math.floor(u/i)*i,l=Math.ceil(l/i)*i;else{if(!(i<0))break;u=Math.ceil(u*i)/i,l=Math.floor(l*i)/i}r=i}return t},t}function BE(){var t=Yx();return t.copy=function(){return qx(t,BE())},Sv.apply(t,arguments),jE(t)}function UE(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n<r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function VE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e);return n.getFullYear()-r.getFullYear()}function HE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function GE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs(VE(n,r));n.setFullYear(n.getFullYear()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function zE(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t),n=e.getFullYear(),r=e.getMonth(),i=new Date(0);return i.setFullYear(n,r+1,0),i.setHours(0,0,0,0),i.getDate()}function FE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=Kg(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=zE(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function WE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return FE(t,12*n)}function qE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return WE(t,-n)}function $E(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function YE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs($E(n,r));n.setMonth(n.getMonth()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function ZE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return FE(t,-n)}function XE(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=lg(t);return e.setHours(0,0,0,0),e}var KE=864e5;function QE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=XE(t),r=XE(e),i=n.getTime()-Mm(n),o=r.getTime()-Mm(r);return Math.round((i-o)/KE)}function JE(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e),i=HE(n,r),o=Math.abs(QE(n,r));n.setDate(n.getDate()-i*o);var a=HE(n,r)===-i,s=i*(o-a);return 0===s?0:s}function tT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=Kg(e);return n.setDate(n.getDate()+r),n}function eT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return tT(t,-n)}function nT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=lg(t),r=lg(e);return n.getTime()-r.getTime()}var rT=36e5;function iT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/rT;return n>0?Math.floor(n):Math.ceil(n)}var oT=36e5;function aT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,n*oT)}function sT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return aT(t,-n)}var uT=6e4;function lT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/uT;return n>0?Math.floor(n):Math.ceil(n)}var cT=6e4;function hT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,n*cT)}function fT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return hT(t,-n)}function pT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=nT(t,e)/1e3;return n>0?Math.floor(n):Math.ceil(n)}function dT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return Qg(t,1e3*n)}function vT(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Kg(e);return dT(t,-n)}var gT=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mT=function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]])}return n},yT=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},_T=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.scaleTypes={top:null,right:null,bottom:null,left:null},e.scales={top:null,right:null,bottom:null,left:null},e}return gT(e,t),e.prototype.getDomainAxisPosition=function(t){var e,n=(void 0===t?{}:t).datum,r=void 0===n?null:n;if(this.dualAxes&&r){var i=this.model.getOptions(),o=i.data.groupMapsTo,a=Dd(i,"axes",this.secondaryDomainAxisPosition),s=r[o];if((null===(e=a)||void 0===e?void 0:e.correspondingDatasets)&&a.correspondingDatasets.includes(s))return this.secondaryDomainAxisPosition}return this.domainAxisPosition},e.prototype.getRangeAxisPosition=function(t){var e,n=void 0===t?{}:t,r=n.datum,i=void 0===r?null:r,o=n.groups,a=void 0===o?null:o;if(this.dualAxes){var s=this.model.getOptions(),u=s.data.groupMapsTo,l=Dd(s,"axes",this.secondaryRangeAxisPosition),c=void 0;if(null!==i?c=i[u]:a&&a.length>0&&(c=a[0]),(null===(e=l)||void 0===e?void 0:e.correspondingDatasets)&&l.correspondingDatasets.includes(c))return this.secondaryRangeAxisPosition}return this.rangeAxisPosition},e.prototype.getAxisOptions=function(t){return Dd(this.model.getOptions(),"axes",t)},e.prototype.getDomainAxisOptions=function(){var t=this.getDomainAxisPosition();return this.getAxisOptions(t)},e.prototype.getRangeAxisOptions=function(){var t=this.getRangeAxisPosition();return this.getAxisOptions(t)},e.prototype.getScaleLabel=function(t){var e=this.getAxisOptions(t),n=e.title;return n||(t===B.BOTTOM||t===B.TOP?"x-value":"y-value")},e.prototype.getDomainLabel=function(){return this.getScaleLabel(this.getDomainAxisPosition())},e.prototype.getRangeLabel=function(){return this.getScaleLabel(this.getRangeAxisPosition())},e.prototype.update=function(t){var e=this;void 0===t&&(t=!0),this.determineAxisDuality(),this.findDomainAndRangeAxes(),this.determineOrientation();var n=Object.keys(B).map((function(t){return B[t]}));n.forEach((function(t){e.scales[t]=e.createScale(t)}))},e.prototype.findDomainAndRangeAxes=function(){var t=this.findVerticalAxesPositions(),e=this.findHorizontalAxesPositions(),n=this.findDomainAndRangeAxesPositions(t,e);this.domainAxisPosition=n.primaryDomainAxisPosition,this.rangeAxisPosition=n.primaryRangeAxisPosition,this.isDualAxes()&&(this.secondaryDomainAxisPosition=n.secondaryDomainAxisPosition,this.secondaryRangeAxisPosition=n.secondaryRangeAxisPosition)},e.prototype.determineOrientation=function(){this.rangeAxisPosition!==B.LEFT&&this.rangeAxisPosition!==B.RIGHT||this.domainAxisPosition!==B.BOTTOM&&this.domainAxisPosition!==B.TOP?this.orientation=H.HORIZONTAL:this.orientation=H.VERTICAL},e.prototype.isDualAxes=function(){return this.dualAxes},e.prototype.determineAxisDuality=function(){var t,e,n,r,i=this.model.getOptions(),o=Dd(i,"axes");((null===(t=o[B.LEFT])||void 0===t?void 0:t.correspondingDatasets)&&o[B.RIGHT]||(null===(e=o[B.RIGHT])||void 0===e?void 0:e.correspondingDatasets)&&o[B.LEFT]||(null===(n=o[B.TOP])||void 0===n?void 0:n.correspondingDatasets)&&o[B.BOTTOM]||(null===(r=o[B.BOTTOM])||void 0===r?void 0:r.correspondingDatasets)&&o[B.TOP])&&(this.dualAxes=!0)},e.prototype.getCustomDomainValuesByposition=function(t){var e=Dd(this.model.getOptions(),"axes",t,"domain");if(e&&!Array.isArray(e))throw new Error("Domain in "+t+" axis is not a valid array");if(Array.isArray(e)&&(this.scaleTypes[t]===G.LINEAR||this.scaleTypes[t]===G.TIME)&&2!==e.length)throw new Error("There can only be 2 elements in domain for scale type: "+this.scaleTypes[t]);return e},e.prototype.getOrientation=function(){return this.orientation},e.prototype.getScaleByPosition=function(t){return this.scales[t]},e.prototype.getScaleTypeByPosition=function(t){return this.scaleTypes[t]},e.prototype.getDomainAxisScaleType=function(){var t=this.getDomainAxisPosition();return this.getScaleTypeByPosition(t)},e.prototype.getRangeAxisScaleType=function(){var t=this.getRangeAxisPosition();return this.getScaleTypeByPosition(t)},e.prototype.getDomainScale=function(){return this.scales[this.domainAxisPosition]},e.prototype.getRangeScale=function(){return this.scales[this.rangeAxisPosition]},e.prototype.getMainXAxisPosition=function(){var t=[B.BOTTOM,B.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[B.LEFT,B.RIGHT];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainXScale=function(){return this.scales[this.getMainXAxisPosition()]},e.prototype.getMainYScale=function(){return this.scales[this.getMainYAxisPosition()]},e.prototype.getValueFromScale=function(t,e,n,r,i){var o,a=this.model.getOptions(),s=Dd(a,"axes"),u=s[n],l=u.mapsTo,c=null!==Dd(r,l)?r[l]:r;switch(e){case G.LABELS:o=t(c)+t.step()/2;break;case G.TIME:o=t(new Date(c));break;default:o=t(c)}return o},e.prototype.getBoundedScaledValues=function(t,e){var n=this.model.getOptions().bounds,r=this.getRangeAxisPosition({datum:t}),i=this.scales[r],o=this.model.getOptions(),a=Dd(o,"axes"),s=a[r],u=s.mapsTo,l=void 0!==t[u]?t[u]:t,c=[i(null!==Dd(t,n.upperBoundMapsTo)?t[n.upperBoundMapsTo]:l),i(null!==Dd(t,n.lowerBoundMapsTo)?t[n.lowerBoundMapsTo]:l)];return c},e.prototype.getValueThroughAxisPosition=function(t,e,n){var r=this.scaleTypes[t],i=this.scales[t];return this.getValueFromScale(i,r,t,e,n)},e.prototype.getDomainValue=function(t,e){var n=this.getDomainAxisPosition({datum:t});return this.getValueThroughAxisPosition(n,t,e)},e.prototype.getRangeValue=function(t,e){var n=this.getRangeAxisPosition({datum:t});return this.getValueThroughAxisPosition(n,t,e)},e.prototype.getMainXScaleType=function(){return this.getScaleTypeByPosition(this.getMainXAxisPosition())},e.prototype.getMainYScaleType=function(){return this.getScaleTypeByPosition(this.getMainYAxisPosition())},e.prototype.getDomainIdentifier=function(t){var e=this.model.getOptions();return Dd(e,"axes",this.getDomainAxisPosition({datum:t}),"mapsTo")},e.prototype.getRangeIdentifier=function(t){var e=this.model.getOptions();return Dd(e,"axes",this.getRangeAxisPosition({datum:t}),"mapsTo")},e.prototype.extendsDomain=function(t,e){var n=this.model.getOptions(),r=Dd(n,"axes",t);if(r.scaleType===G.TIME){var i=Dd(n,"timeScale","addSpaceOnEdges");return bT(e,i)}return wT(e,gt.paddingRatio,r.scaleType)},e.prototype.findVerticalAxesPositions=function(){var t=this.model.getOptions(),e=Dd(t,"axes"),n=this.isDualAxes();return null===Dd(e,B.LEFT)&&null!==Dd(e,B.RIGHT)||!0===Dd(e,B.RIGHT,"main")||n&&Dd(e,B.LEFT,"correspondingDatasets")?{primary:B.RIGHT,secondary:B.LEFT}:{primary:B.LEFT,secondary:B.RIGHT}},e.prototype.findHorizontalAxesPositions=function(){var t=this.model.getOptions(),e=Dd(t,"axes"),n=this.isDualAxes();return null===Dd(e,B.BOTTOM)&&null!==Dd(e,B.TOP)||!0===Dd(e,B.TOP,"main")||n&&Dd(e,B.BOTTOM,"correspondingDatasets")?{primary:B.TOP,secondary:B.BOTTOM}:{primary:B.BOTTOM,secondary:B.TOP}},e.prototype.findDomainAndRangeAxesPositions=function(t,e){var n=this.model.getOptions(),r=Dd(n,"axes",t.primary),i=Dd(n,"axes",e.primary),o=r.scaleType||G.LINEAR,a=i.scaleType||G.LINEAR,s={primaryDomainAxisPosition:null,secondaryDomainAxisPosition:null,primaryRangeAxisPosition:null,secondaryRangeAxisPosition:null};return s.primaryDomainAxisPosition=e.primary,s.primaryRangeAxisPosition=t.primary,s.secondaryDomainAxisPosition=e.secondary,s.secondaryRangeAxisPosition=t.secondary,(a!==G.LABELS&&a!==G.TIME&&o===G.LABELS||o===G.TIME)&&(s.primaryDomainAxisPosition=t.primary,s.primaryRangeAxisPosition=e.primary,s.secondaryDomainAxisPosition=t.secondary,s.secondaryRangeAxisPosition=e.secondary),s},e.prototype.getScaleDomain=function(t){var e=this.model.getOptions(),n=Dd(e,"axes",t),r=Dd(e,"bounds"),i=n.includeZero,o=Dd(n,"scaleType")||G.LINEAR;if(this.model.isDataEmpty())return[];if(n.binned){var a=this.model.getBinConfigurations().bins;return[0,UE(a,(function(t){return t.length}))]}if(n.limitDomainToBins){a=this.model.getBinConfigurations().bins;var s=this.model.getStackKeys({bins:a});return[s[0].split("-")[0],s[s.length-1].split("-")[1]]}var u,l,c=this.model.getDisplayData(),h=n.extendLinearDomainBy,f=n.mapsTo,p=n.percentage,d=n.thresholds,v=gt.ratio,g=v.reference,m=v.compareTo;if(n.domain)return o===G.LABELS?n.domain:(o===G.TIME&&(n.domain=n.domain.map((function(t){return void 0===t.getTime?new Date(t):t}))),this.extendsDomain(t,n.domain));if(p)return[0,100];if(n&&o===G.LABELS)return xd(c.map((function(t){return t[f]})));var y=this.model.getDataGroupNames();if(o===G.LABELS_RATIO)return c.map((function(t){return t[g]+"/"+t[m]}));if(o===G.TIME)l=c.map((function(t){return+new Date(t[f])}));else if(r&&e.axes)l=[],c.forEach((function(t){l.push(t[f]),t[r.upperBoundMapsTo]&&l.push(t[r.upperBoundMapsTo]),t[r.lowerBoundMapsTo]&&l.push(t[r.lowerBoundMapsTo])}));else if(!0===n.stacked&&y&&t===this.getRangeAxisPosition()){var _=e.data.groupMapsTo,b=this.model.getDataValuesGroupedByKeys({groups:y}),w=c.filter((function(t){return!y.includes(t[_])})),O=[];b.forEach((function(t){t.sharedStackKey;var e=mT(t,["sharedStackKey"]),n=0,r=0;Object.values(e).forEach((function(t){isNaN(t)||(t<0?r+=t:n+=t)})),O.push([r,n])})),l=yT(va(O),w.map((function(t){return t[f]})))}else l=[],c.forEach((function(t){var e=t[f];Array.isArray(e)&&2===e.length?(l.push(e[0]),l.push(e[1])):(h&&l.push(Math.max(t[f],t[h])),l.push(e))}));return o!==G.TIME&&o!==G.LOG&&i&&l.push(0),d&&d.length>0&&d.forEach((function(t){var e=Dd(t,"value");null!==e&&l.push(e)})),u=Xv(l),u=this.extendsDomain(t,u),u},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=Dd(e,"axes",t);if(!n)return null;var r,i=Dd(n,"scaleType")||G.LINEAR;return this.scaleTypes[t]=i,r=i===G.TIME?Jx():i===G.LOG?LE().base(n.base||10):i===G.LABELS||i===G.LABELS_RATIO?kE():BE(),r.domain(this.getScaleDomain(t)),r},e.prototype.getHighestDomainThreshold=function(){var t=Dd(this.model.getOptions(),"axes"),e=this.getDomainAxisPosition(),n=t[e].thresholds;if(!Array.isArray(n)||Array.isArray(n)&&!n.length)return null;var r=this.getDomainScale(),i=n.sort((function(t,e){return e.value-t.value}))[0],o=this.getScaleTypeByPosition(e);return o!==G.TIME||"string"!==typeof i.value&&void 0!==i.value.getTime||(i.value=new Date(i.value)),{threshold:i,scaleValue:r(i.value)}},e.prototype.getHighestRangeThreshold=function(){var t=Dd(this.model.getOptions(),"axes"),e=this.getRangeAxisPosition(),n=t[e].thresholds;if(!Array.isArray(n)||Array.isArray(n)&&!n.length)return null;var r=this.getRangeScale(),i=n.sort((function(t,e){return e.value-t.value}))[0];return{threshold:i,scaleValue:r(i.value)}},e}(ty);function bT(t,e){var n=new Date(t[0]),r=new Date(t[1]);return GE(r,n)>1?[qE(n,e),WE(r,e)]:YE(r,n)>1?[ZE(n,e),FE(r,e)]:JE(r,n)>1?[eT(n,e),tT(r,e)]:iT(r,n)>1?[sT(n,e),aT(r,e)]:lT(r,n)>30?[fT(n,30*e),hT(r,30*e)]:lT(r,n)>1?[fT(n,e),hT(r,e)]:pT(r,n)>15?[vT(n,15*e),dT(r,15*e)]:pT(r,n)>1?[vT(n,e),dT(r,e)]:[n,r]}function wT(t,e,n){var r=t[0],i=t[1],o=i-r,a=o*e,s=i<=0&&i+a>0?0:i+a,u=r>=0&&r-a<0?0:r-a;if(n===G.LOG&&u<=0){if(r<=0)throw Error("Data must have values greater than 0 if log scale type is used.");u=r}return[u,s]}function OT(t){this._context=t}OT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e);break}}};var xT=function(t){return new OT(t)},ET=function(){};function TT(t){this._context=t}TT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}};var ST=function(t){return new TT(t)};function MT(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function CT(t){this._context=t}CT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:MT(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var AT=function(t){return new CT(t)};function LT(t){this._context=t}LT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var DT=function(t){return new LT(t)};function kT(t){this._context=t}kT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:MT(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};var PT=function(t){return new kT(t)};function RT(t,e){this._basis=new CT(t),this._beta=e}RT.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0){var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;while(++u<=n)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s))}this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var IT=function t(e){function n(t){return 1===e?new CT(t):new RT(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function NT(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function jT(t,e){this._context=t,this._k=(1-e)/6}jT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:NT(this,this._x1,this._y1);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var BT=function t(e){function n(t){return new jT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function UT(t,e){this._context=t,this._k=(1-e)/6}UT.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var VT=function t(e){function n(t){return new UT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function HT(t,e){this._context=t,this._k=(1-e)/6}HT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:NT(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var GT=function t(e){function n(t){return new HT(t,e)}return n.tension=function(e){return t(+e)},n}(0);const zT=Math.abs,FT=Math.atan2,WT=Math.cos,qT=Math.max,$T=Math.min,YT=Math.sin,ZT=Math.sqrt,XT=1e-12,KT=Math.PI,QT=KT/2,JT=2*KT;function tS(t){return t>1?0:t<-1?KT:Math.acos(t)}function eS(t){return t>=1?QT:t<=-1?-QT:Math.asin(t)}function nS(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>XT){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>XT){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/c,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/c}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function rS(t,e){this._context=t,this._alpha=e}rS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var iS=function t(e){function n(t){return e?new rS(t,e):new jT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function oS(t,e){this._context=t,this._alpha=e}oS.prototype={areaStart:ET,areaEnd:ET,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var aS=function t(e){function n(t){return e?new oS(t,e):new UT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function sS(t,e){this._context=t,this._alpha=e}sS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:nS(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var uS=function t(e){function n(t){return e?new sS(t,e):new HT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function lS(t){return t<0?-1:1}function cS(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(lS(o)+lS(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function hS(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function fS(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function pS(t){this._context=t}function dS(t){this._context=new vS(t)}function vS(t){this._context=t}function gS(t){return new pS(t)}function mS(t){return new dS(t)}function yS(t){this._context=t}function _S(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}pS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:fS(this,this._t0,hS(this,this._t0));break}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(t=+t,e=+e,t!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,fS(this,hS(this,n=cS(this,t,e)),n);break;default:fS(this,this._t0,n=cS(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(dS.prototype=Object.create(pS.prototype)).point=function(t,e){pS.prototype.point.call(this,e,t)},vS.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},yS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=_S(t),i=_S(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var bS=function(t){return new yS(t)};function wS(t,e){this._context=t,this._t=e}wS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}break}this._x=t,this._y=e}};var OS=function(t){return new wS(t,.5)};function xS(t){return new wS(t,0)}function ES(t){return new wS(t,1)}var TS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),SS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:xT,curveLinearClosed:ST,curveBasis:AT,curveBasisClosed:DT,curveBasisOpen:PT,curveBundle:IT,curveCardinal:BT,curveCardinalClosed:VT,curveCardinalOpen:GT,curveCatmullRom:iS,curveCatmullRomClosed:aS,curveCatmullRomOpen:uS,curveMonotoneX:gS,curveMonotoneY:mS,curveNatural:bS,curveStep:OS,curveStepAfter:ES,curveStepBefore:xS},e}return TS(e,t),e.prototype.getD3Curve=function(){var t="curveLinear",e=this.model.getOptions().curve;if(e&&(t="string"===typeof e?e:e.name),this.curveTypes[t]){var n=this.curveTypes[t];return e&&Object.keys(e).forEach((function(t){n[t]&&(n=n[t](e[t]))})),n}return console.warn("The curve type '"+t+"' is invalid, using 'curveLinear' instead"),this.curveTypes["curveLinear"]},e}(ty),MS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),CS=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return MS(e,t),e.prototype.isZoomBarEnabled=function(){if(!this.services.cartesianScales)return!1;if(!Dd(this.model.getOptions(),"zoomBar","top","enabled"))return!1;this.services.cartesianScales.findDomainAndRangeAxes();var t=this.services.cartesianScales.getMainXAxisPosition(),e=Dd(this.model.getOptions(),"axes",t,"scaleType");return t===B.BOTTOM&&e===G.TIME},e.prototype.getZoomBarData=function(){var t=this.model.getZoomBarData();return t&&t.length>1?t:this.model.getDisplayData()},e.prototype.getDefaultZoomBarDomain=function(t){var e=t||this.services.zoom.getZoomBarData(),n=this.services.cartesianScales,r=n.getMainXAxisPosition(),i=n.getDomainIdentifier(),o=Dd(this.model.getOptions(),"axes",r,"domain");return Array.isArray(o)&&2===o.length?o:n.extendsDomain(r,Xv(e,(function(t){return t[i]})))},e.prototype.handleDomainChange=function(t,e){void 0===e&&(e={dispatchEvent:!0}),this.model.set({zoomDomain:t},{animate:!1}),e.dispatchEvent&&this.services.events.dispatchEvent(ft.ZoomDomain.CHANGE,{newDomain:t})},e.prototype.getZoomRatio=function(){return Dd(this.model.getOptions(),"zoomBar","zoomRatio")},e.prototype.filterDataForRangeAxis=function(t,e){var n=this.model.get("zoomDomain"),r=Object.assign({stacked:!1},e),i=Dd(this.model.getOptions(),"zoomBar","updateRangeAxis");if(this.isZoomBarEnabled()&&i&&n){var o=r.stacked?"sharedStackKey":this.services.cartesianScales.getDomainIdentifier(),a=t.filter((function(t){return new Date(t[o])>=n[0]&&new Date(t[o])<=n[1]}));if(a.length>0)return a}return t},e.prototype.zoomIn=function(t){void 0===t&&(t=this.getZoomRatio());var e=this.model.get("zoomDomain"),n=Pt.handleWidth,r=this.services.cartesianScales.getMainXScale().copy();r.domain(this.getDefaultZoomBarDomain());var i=r(e[0]),o=r(e[1]);if(!(o-i<n+1)){var a=r.range(),s=o-i,u=Math.min((a[1]-a[0])/2*(t/2),s/2),l=i+u,c=o-u;l>=c&&(l=i+s/2-n/2,c=o-s/2+n/2);var h=[r.invert(l),r.invert(c)];e[0].valueOf()===h[0].valueOf()&&e[1].valueOf()===h[1].valueOf()||this.handleDomainChange(h)}},e.prototype.zoomOut=function(t){void 0===t&&(t=this.getZoomRatio());var e=this.model.get("zoomDomain"),n=this.services.cartesianScales.getMainXScale().copy();n.domain(this.getDefaultZoomBarDomain());var r=n(e[0]),i=n(e[1]),o=n.range(),a=(o[1]-o[0])/2*(t/2),s=Math.max(r-a,o[0]),u=Math.min(i+a,o[1]),l=[n.invert(s),n.invert(u)];e[0].valueOf()===l[0].valueOf()&&e[1].valueOf()===l[1].valueOf()||this.handleDomainChange(l)},e.prototype.resetZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();t[0].valueOf()===e[0].valueOf()&&t[1].valueOf()===e[1].valueOf()||this.handleDomainChange(e)},e.prototype.isMinZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();if(!t||!e)return!1;var n=t[1].valueOf()-t[0].valueOf(),r=e[1].valueOf()-e[0].valueOf(),i=Dd(this.model.getOptions(),"zoomBar","minZoomRatio");return n/r<i},e.prototype.isMaxZoomDomain=function(){var t=this.model.get("zoomDomain"),e=this.getDefaultZoomBarDomain();return!(!t||!e||t[0].valueOf()!==e[0].valueOf()||t[1].valueOf()!==e[1].valueOf())},e.prototype.isEmptyState=function(){return 0===this.getZoomBarData().length},e.prototype.isZoomBarLoading=function(t){return Dd(this.model.getOptions(),"zoomBar",t,"loading")},e.prototype.isZoomBarLocked=function(t){return Dd(this.model.getOptions(),"zoomBar",t,"locked")},e}(ty),AS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LS=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return AS(e,t),e.prototype.zoomIn=function(t,e,n){var r,i,o,a=n||mt;t&&(r=t.x,i=t.y,o=2);var s=sb.getSVGElementSize(this.services.domUtils.getHolder(),{useClientDimensions:!0}),u=s.width,l=s.height;e.transition().duration(a.duration).ease(a.ease).attr("transform","translate("+u/2+", "+l/2+") scale("+o+") translate("+-r+","+-i+")"),this.services.events.dispatchEvent(ft.CanvasZoom.CANVAS_ZOOM_IN,{element:eb(t)})},e.prototype.zoomOut=function(t,e){var n=e||mt;t.transition().duration(n.duration).ease(n.ease).attr("transform",""),this.services.events.dispatchEvent(ft.CanvasZoom.CANVAS_ZOOM_OUT)},e}(ty),DS=function(){function t(t,e,n){if(this.renderType=I.HTML,this.configs={},this.model=t,this.services=e,n&&(this.configs=n,this.configs.id)){var r=Dd(this.model.getOptions(),"style","prefix");this.id=r+"--"+this.configs.id}this.parent||this.setParent(eb(this.services.domUtils.getMainContainer()))}return t.prototype.init=function(){},t.prototype.render=function(t){void 0===t&&(t=!0),console.error("render() method is not implemented")},t.prototype.destroy=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t.prototype.setParent=function(t){var e=this.parent;if(this.parent=t,(!e||e.node()!==t.node())&&this.type){var n=Dd(this.model.getOptions(),"style","prefix");this.parent.classed(dt+"--"+n+"--"+this.type,!0),e&&e.classed(dt+"--"+n+"--"+this.type,!1)}},t.prototype.getParent=function(){return this.parent},t.prototype.getComponentContainer=function(t){if(void 0===t&&(t={withinChartClip:!1}),this.type){var e=Dd(this.model.getOptions(),"style","prefix"),n=this.id?"#"+this.id:"",r=sb.appendOrSelect(this.parent,(this.renderType===I.SVG?"svg":"div")+n+"."+dt+"--"+e+"--"+this.type);if(t.withinChartClip){var i=this.model.get("chartClipId");if(i){var o=eb("#"+i),a=o.select("rect");0!==a.size()&&parseFloat(a.attr("height"))>0&&r.attr("clip-path","url(#"+i+")")}}return r.attr("width","100%").attr("height","100%")}return this.parent},t.prototype.getOptions=function(){if(this.configs.options){var t=na({},this.model.getOptions(),this.configs.options);return t}return this.model.getOptions()},t}(),kS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),PS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e.renderType=I.HTML,e}return kS(e,t),e.prototype.render=function(){var t=this,e=this.getOptions(),n=Dd(e,"legend"),r=Dd(n,"alignment"),i=Dd(e,"legend","orientation"),o=this.model.getDataGroups(),s=Ot.items.status.DISABLED,u=o.some((function(t){return t.status===s})),l=Dd(n,"order"),c=this.getComponentContainer().classed("center-aligned",r===F.CENTER).classed("right-aligned",r===F.RIGHT).classed(i,!0).classed("has-deactivated-items",u).attr("role",a.GROUP).attr("aria-label","Data groups").attr("data-name","legend-items");l&&(o=this.sortDataGroups(o,l));var h=c.selectAll("div.legend-item").data(o,(function(t){return t.name})),f=h.enter().append("div").attr("class","legend-item");f.merge(c.selectAll("div.legend-item")).classed("active",(function(t,e){return t.status===Ot.items.status.ACTIVE}));var p=Dd(this.getOptions(),"legend","clickable");c.classed("clickable",p&&o.length>1);var d=Ot.checkbox.radius,v=f.append("div").classed("checkbox",!0),g=v.merge(h.select("div.checkbox")).attr("role",a.CHECKBOX).attr("tabindex",p?0:-1).attr("aria-labelledby",(function(e,n){return t.services.domUtils.generateElementIDString("legend-datagroup-"+n+"-title")})).attr("aria-checked",(function(t){var e=t.status;return e===Ot.items.status.ACTIVE})).attr("width",2*d).attr("height",2*d).attr("class",(function(e,n){return t.model.getColorClassName({classNameTypes:[j.BACKGROUND],dataGroupName:e.name,originalClassName:"checkbox"})})).style("background",(function(e){return e.status===Ot.items.status.ACTIVE?t.model.getFillColor(e.name)||t.model.getStrokeColor(e.name):null})).classed("active",(function(t,e){return t.status===Ot.items.status.ACTIVE})),m=(v.append("svg").attr("focusable",!1).attr("preserveAspectRatio","xMidYMid meet").attr("xmlns","http://www.w3.org/2000/svg").attr("width","11").attr("height","11").attr("viewBox","0 0 31 28").attr("aria-hidden",!0).style("will-change","transform").append("path").attr("d","M13 21.2l-7.1-7.1-1.4 1.4 7.1 7.1L13 24 27.1 9.9l-1.4-1.5z"),f.append("p").merge(h.select("p")),Dd(e,"legend","additionalItems"));if(m&&o.length){var y=this,_=c.selectAll("div.additional-item").data(m);_.exit().remove();var b,w=_.enter().append("div").merge(_).classed("legend-item",!0).classed("additional",!0).attr("aria-labelledby",(function(e,n){return t.services.domUtils.generateElementIDString("legend-datagroup-"+(g.size()+n)+"-title")}));w.selectAll("*").remove();var O=1;w.append("svg").classed("icon",!0).each((function(t,e){var n=eb(this);b&&b==t.type?O++:(b=t.type,O=1),y.addAdditionalItem(n,t,O)}));w.append("p").merge(w.select("p"));this.truncateLegendText()}h.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove(),p&&f.size()>1&&this.addEventListeners()},e.prototype.sortDataGroups=function(t,e){if(t.sort((function(t,n){return e.indexOf(t.name)-e.indexOf(n.name)})),e.length<t.length){var n=t.length-e.length,r=t.slice(n);return r.concat(t.slice(0,n))}return t},e.prototype.addAdditionalItem=function(t,e,n){var r=Ot.area,i=r.width,s=r.height;if(e.type===st.RADIUS?t.style("width",s+"px").style("height",s+"px"):t.style("width",i+"px").style("height",s+"px"),e.type===st.RADIUS){var u=Ot.radius,l=u.iconData,c=u.fill,h=u.stroke,f=t.attr("fill","none").selectAll("circle").data(l).enter();f.append("circle").classed("radius",!0).attr("role",a.IMG).attr("aria-label","radius").attr("cx",(function(t){return t.cx})).attr("cy",(function(t){return t.cy})).attr("r",(function(t){return t.r})).style("fill",e.fill?e.fill:c).style("stroke",e.stroke?e.stroke:h)}else if(e.type===st.LINE){var p=Ot.line;t.select("line.line").empty()&&t.append("line").classed("line-"+n,!0).attr("role",a.IMG).attr("aria-label","line").attr("x1",0).attr("y1",p.yPosition).attr("x2",i).attr("y2",p.yPosition).style("stroke",e.stroke?e.stroke:p.stroke).style("stroke-width",p.strokeWidth)}else if(e.type===st.AREA)t.select("rect.area").empty()&&t.append("rect").classed("area-"+n,!0).attr("role",a.IMG).attr("aria-label","area").attr("width",i).attr("height",s).style("fill",n>3&&!e.fill?Ot.area.fill:e.fill).style("stroke",e.stroke);else if(e.type===st.SIZE){var d=Ot.size,v=(l=d.iconData,c=d.fill,h=d.stroke,t.attr("fill","none").attr("role",a.IMG).attr("aria-label","size").selectAll("rect").data(l).enter());v.append("rect").classed("size",!0).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})).attr("y",(function(t){return 0})).style("fill",e.fill?e.fill:c).style("stroke",e.stroke?e.stroke:h).style("stroke-width",1)}else if(e.type===st.QUARTILE){l=Ot.quartile.iconData;var g=t.selectAll("rect").attr("role",a.IMG).attr("aria-label","quartile").data(l).enter();g.append("rect").attr("class",(function(t,e){return"quartile-"+(0===e?"wrapper":"line")})).attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height}))}else if(e.type===st.ZOOM){var m=Dd(o,"legend","zoom"),y=(l=m.iconData,m.color),_=t.attr("role",a.IMG).attr("aria-label","zoom").selectAll("g.icon").data(l).enter();_.append("g").attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).attr("width",(function(t){return t.width})).attr("height",(function(t){return t.height})).append("polygon").attr("points","7.7 4.82 5.78 4.82 5.78 2.89 4.82 2.89 4.82 4.82 2.89 4.82 2.89 5.78 4.82 5.78 4.82 7.7 5.78 7.7 5.78 5.78 7.7 5.78 7.7 4.82").attr("fill",(function(t){return e.color?e.color:y})),_.append("path").attr("d","M9.36,8.67A5.22,5.22,0,0,0,10.59,5.3,5.3,5.3,0,1,0,5.3,10.59,5.22,5.22,0,0,0,8.67,9.36L12.32,13l.68-.68Zm-4.06,1A4.34,4.34,0,1,1,9.63,5.3,4.33,4.33,0,0,1,5.3,9.63Z").attr("fill",(function(t){return e.color?e.color:y}))}},e.prototype.truncateLegendText=function(){var t=this.getComponentContainer(),e=Dd(this.getOptions(),"legend","truncation"),n=Dd(e,"type"),r=Dd(e,"threshold"),i=Dd(e,"numCharacter"),o=t.selectAll("div.legend-item p");o.attr("id",(function(t,e){var n=this.parentNode.querySelector("div.checkbox")||this.parentNode;return n.getAttribute("aria-labelledby")})),n!==V.NONE?o.html((function(t){return t.name.length>r?Ad(t.name,n,i):t.name})):o.html((function(t){return t.name}))},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=Dd(n,"legend"),i=Dd(r,"truncation");e.selectAll("div.legend-item").on("mouseover",(function(e){t.services.events.dispatchEvent(ft.Legend.ITEM_HOVER,{hoveredElement:eb(this)});var n=eb(this);n.select("div.checkbox").classed("hovered",!0);var r=n.datum();r.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:n,content:r.name})})).on("mousemove",(function(e){var n=eb(this).datum();n.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(){t.services.events.dispatchEvent(ft.Legend.ITEM_CLICK,{clickedElement:eb(this)});var e=eb(this),n=e.datum();t.model.toggleDataLabel(n.name)})).on("mouseout",(function(){var e=eb(this);e.select("div.checkbox").classed("hovered",!1);var n=e.datum();n.name.length>i.threshold&&i.type!==V.NONE&&t.services.events.dispatchEvent(ft.Tooltip.HIDE),t.services.events.dispatchEvent(ft.Legend.ITEM_MOUSEOUT,{hoveredElement:e})})),e.selectAll("div.legend-item div.checkbox").on("keyup",(function(e){e.key&&"Tab"===e.key&&t.services.events.dispatchEvent(ft.Legend.ITEM_HOVER,{hoveredElement:eb(this)})})),e.selectAll("div.legend-item div.checkbox").on("keydown",(function(e,n){e.key&&" "===e.key?(e.preventDefault(),t.model.toggleDataLabel(n.name)):e.key&&"Tab"===e.key&&t.services.events.dispatchEvent(ft.Legend.ITEM_MOUSEOUT,{hoveredElement:eb(this)})})),e.selectAll("g.additional-item").on("mouseover",(function(e){var n=eb(this),r=n.datum();r.name.length>i.threshold&&t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:n,content:r.name})}))},e}(DS),RS=function(t){return t},IS=1,NS=2,jS=3,BS=4,US=1e-6;function VS(t){return"translate("+t+",0)"}function HS(t){return"translate(0,"+t+")"}function GS(t){return e=>+t(e)}function zS(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function FS(){return!this.__axis}function WS(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u="undefined"!==typeof window&&window.devicePixelRatio>1?0:.5,l=t===IS||t===BS?-1:1,c=t===BS||t===NS?"x":"y",h=t===IS||t===jS?VS:HS;function f(f){var p=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,d=null==i?e.tickFormat?e.tickFormat.apply(e,n):RS:i,v=Math.max(o,0)+s,g=e.range(),m=+g[0]+u,y=+g[g.length-1]+u,_=(e.bandwidth?zS:GS)(e.copy(),u),b=f.selection?f.selection():f,w=b.selectAll(".domain").data([null]),O=b.selectAll(".tick").data(p,e).order(),x=O.exit(),E=O.enter().append("g").attr("class","tick"),T=O.select("line"),S=O.select("text");w=w.merge(w.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),O=O.merge(E),T=T.merge(E.append("line").attr("stroke","currentColor").attr(c+"2",l*o)),S=S.merge(E.append("text").attr("fill","currentColor").attr(c,l*v).attr("dy",t===IS?"0em":t===jS?"0.71em":"0.32em")),f!==b&&(w=w.transition(f),O=O.transition(f),T=T.transition(f),S=S.transition(f),x=x.transition(f).attr("opacity",US).attr("transform",(function(t){return isFinite(t=_(t))?h(t+u):this.getAttribute("transform")})),E.attr("opacity",US).attr("transform",(function(t){var e=this.parentNode.__axis;return h((e&&isFinite(e=e(t))?e:_(t))+u)}))),x.remove(),w.attr("d",t===BS||t===NS?a?"M"+l*a+","+m+"H"+u+"V"+y+"H"+l*a:"M"+u+","+m+"V"+y:a?"M"+m+","+l*a+"V"+u+"H"+y+"V"+l*a:"M"+m+","+u+"H"+y),O.attr("opacity",1).attr("transform",(function(t){return h(_(t)+u)})),T.attr(c+"2",l*o),S.attr(c,l*v).text(d),b.filter(FS).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===NS?"start":t===BS?"end":"middle"),b.each((function(){this.__axis=_}))}return f.scale=function(t){return arguments.length?(e=t,f):e},f.ticks=function(){return n=Array.from(arguments),f},f.tickArguments=function(t){return arguments.length?(n=null==t?[]:Array.from(t),f):n.slice()},f.tickValues=function(t){return arguments.length?(r=null==t?null:Array.from(t),f):r&&r.slice()},f.tickFormat=function(t){return arguments.length?(i=t,f):i},f.tickSize=function(t){return arguments.length?(o=a=+t,f):o},f.tickSizeInner=function(t){return arguments.length?(o=+t,f):o},f.tickSizeOuter=function(t){return arguments.length?(a=+t,f):a},f.tickPadding=function(t){return arguments.length?(s=+t,f):s},f.offset=function(t){return arguments.length?(u=+t,f):u},f}function qS(t){return WS(IS,t)}function $S(t){return WS(NS,t)}function YS(t){return WS(jS,t)}function ZS(t){return WS(BS,t)}var XS=function(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n},KS=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QS=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="color-legend",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e.handleAxisCompleteEvent=function(t){var n=e.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}).width,i=Dd(e.getOptions(),"data","loading");if(r>Ot.color.barWidth&&!i){var o=Dd(e.getOptions(),"heatmap","colorLegend","title"),a=e.services.cartesianScales,s=a.getMainXScale(),u=s.range();if(u[0]>1&&(n.select("g.legend").attr("transform","translate("+u[0]+", 0)"),o)){var l=sb.getSVGElementSize(n.select("g.legend-title").select("text"),{useBBox:!0}).width,c=u[0]-l-9;c>1?n.select("g.legend-title").attr("transform","translate("+c+", 0)"):(n.select("g.legend").attr("transform","translate("+u[0]+", 16)"),n.select("g.legend-title").attr("transform","translate("+u[0]+", 0)"))}}else n.select("g.legend-title").attr("transform","translate(0, 0)")},e}return KS(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Axis.RENDER_COMPLETE,this.handleAxisCompleteEvent)},e.prototype.render=function(t){void 0===t&&(t=!1);var e=this.getOptions(),n=this.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}).width,i=Dd(e,"color","gradient","colors"),o=Dd(e,"heatmap","colorLegend","type"),a=Dd(e,"color","pairing","option"),s=Dd(e,"heatmap","colorLegend","title"),u=Dd(this.getOptions(),"data","loading");if(u)n.html("");else{var l=!Vh(i),c=this.model.getValueDomain(),h=!(r<=Ot.color.barWidth),f=h?Ot.color.barWidth:r,p=sb.appendOrSelect(n,"g.legend"),d=sb.appendOrSelect(p,"g.legend-axis");if(s){var v=sb.appendOrSelect(n,"g.legend-title"),g=sb.appendOrSelect(v,"text");g.text(s).attr("dy","0.7em"),p.attr("transform","translate(0, 16)")}var m=c[0]<0&&c[1]>0?"diverge":"mono";(a<1&&a>4&&"mono"===m||a<1&&a>2&&"diverge"===m)&&(a=1);var y=[],_="diverge"===m?17:11;if(l)y=i;else for(var b=1;b<_+1;b++)y.push(o===ut.LINEAR?"stop-color-"+m+"-"+a+"-"+b:"fill-"+m+"-"+a+"-"+b);var w=Ax(c[0],c[1]),O=XS(w,3),x=BE().domain(c).range([0,f]),E=YS(x).tickSize(0).tickValues(O);switch(o){case ut.LINEAR:this.drawLinear(y,p,f);break;case ut.QUANTIZE:var T=this.drawQuantize(y,m,l,p,f);x.range([T,f]);break;default:throw Error("Entered color legend type is not supported.")}d.attr("transform","translate(0,"+Ot.color.axisYTranslation+")").call(E),d.select(".domain").remove(),d.select("g.tick:last-of-type text").style("text-anchor",h?"middle":"end"),d.select("g.tick:first-of-type text").style("text-anchor",h?"middle":"start")}},e.prototype.drawLinear=function(t,e,n){var r=100/(t.length-1),i=sb.appendOrSelect(e,"linearGradient");i.attr("id",this.gradient_id+"-legend").selectAll("stop").data(t).enter().append("stop").attr("offset",(function(t,e){return e*r+"%"})).attr("class",(function(e,n){return t[n]})).attr("stop-color",(function(t){return t}));var o=sb.appendOrSelect(e,"rect");o.attr("width",n).attr("height",Ot.color.barHeight).style("fill","url(#"+this.gradient_id+"-legend)")},e.prototype.drawQuantize=function(t,e,n,r,i){n||"diverge"!==e||t.splice(t.length/2,1);var o=kE().domain(t).range([0,i]),a=sb.appendOrSelect(r,"g.quantized-rect");return a.selectAll("rect").data(o.domain()).join("rect").attr("x",(function(t){return o(t)})).attr("y",0).attr("width",Math.max(0,o.bandwidth()-1)).attr("height",Ot.color.barHeight).attr("class",(function(t){return t})).attr("fill",(function(t){return t})),"mono"===(!n&&e)?o.bandwidth()-1:0},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Axis.RENDER_COMPLETE,this.handleAxisCompleteEvent)},e}(PS),JS=(n("9b04"),{prefix:"bx",selectorTabbable:"\n a[href], area[href], input:not([disabled]):not([tabindex='-1']),\n button:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']),\n textarea:not([disabled]):not([tabindex='-1']),\n iframe, object, embed, *[tabindex]:not([tabindex='-1']), *[contenteditable=true]\n ",selectorFocusable:"\n a[href], area[href], input:not([disabled]),\n button:not([disabled]),select:not([disabled]),\n textarea:not([disabled]),\n iframe, object, embed, *[tabindex], *[contenteditable=true]\n "}),tM=JS;function eM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function nM(t,e,n){return e&&eM(t.prototype,e),n&&eM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function rM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function iM(t){return uM(t)||sM(t)||aM(t)||oM()}function oM(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function aM(t,e){if(t){if("string"===typeof t)return lM(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?lM(t,e):void 0}}function sM(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function uM(t){if(Array.isArray(t))return lM(t)}function lM(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function cM(t){return t.reduce((function(t,e){return Array.isArray(e)?t.push.apply(t,iM(cM(e))):t.push(e),t}),[])}function hM(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return cM(e).reduce((function(t,e){return e(t)}),function(){function t(){rM(this,t)}return nM(t)}())}function fM(t){return fM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fM(t)}function pM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function dM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function vM(t,e,n){return e&&dM(t.prototype,e),n&&dM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function gM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&mM(t,e)}function mM(t,e){return mM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},mM(t,e)}function yM(t){var e=wM();return function(){var n,r=OM(t);if(e){var i=OM(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return _M(this,n)}}function _M(t,e){if(e&&("object"===fM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return bM(t)}function bM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function wM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function OM(t){return OM=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},OM(t)}var xM=function(t){var e=function(t){gM(n,t);var e=yM(n);function n(t){var r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(pM(this,n),r=e.call(this,t,i),r.children=[],!t||t.nodeType!==Node.ELEMENT_NODE)throw new TypeError("DOM element should be given to initialize this widget.");return r.element=t,r.options=Object.assign(Object.create(r.constructor.options),i),r.constructor.components.set(r.element,bM(r)),r}return vM(n,[{key:"release",value:function(){for(var t=this.children.pop();t;t=this.children.pop())t.release();return this.constructor.components.delete(this.element),null}}],[{key:"create",value:function(t,e){return this.components.get(t)||new this(t,e)}}]),n}(t);return e};function EM(t,e){var n=t.target,r=t.currentTarget;if("function"===typeof n.matches){if(n.matches(e))return n;if(n.matches("".concat(e," *"))){var i=n.closest(e);if((r.nodeType===Node.DOCUMENT_NODE?r.documentElement:r).contains(i))return i}}}function TM(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return t.addEventListener.apply(t,n),{release:function(){return t.removeEventListener.apply(t,n),null}}}function SM(t){return SM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},SM(t)}function MM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function CM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function AM(t,e,n){return e&&CM(t.prototype,e),n&&CM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function LM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&DM(t,e)}function DM(t,e){return DM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},DM(t,e)}function kM(t){var e=IM();return function(){var n,r=NM(t);if(e){var i=NM(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return PM(this,n)}}function PM(t,e){if(e&&("object"===SM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return RM(t)}function RM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function IM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function NM(t){return NM=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},NM(t)}var jM=function(t){var e=function(t){LM(n,t);var e=kM(n);function n(){return MM(this,n),e.apply(this,arguments)}return AM(n,null,[{key:"init",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=Object.assign(Object.create(this.options),n);if(!e||e.nodeType!==Node.ELEMENT_NODE&&e.nodeType!==Node.DOCUMENT_NODE)throw new TypeError("DOM document or DOM element should be given to search for and initialize this widget.");if(e.nodeType!==Node.ELEMENT_NODE||!e.matches(r.selectorInit)){var i=r.initEventNames.map((function(i){return TM(e,i,(function(e){var i=EM(e,"[".concat(r.attribInitTarget,"]"));if(i){e.delegateTarget=i;var o=i.ownerDocument.querySelectorAll(i.getAttribute(r.attribInitTarget));if(o.length>1)throw new Error("Target widget must be unique.");if(1===o.length){"A"===i.tagName&&e.preventDefault();var a=t.create(o[0],n);"function"===typeof a.createdByLauncher&&a.createdByLauncher(e)}}}))}));return{release:function(){for(var t=i.pop();t;t=i.pop())t.release()}}}return this.create(e,n),""}}]),n.forLazyInit=!0,n}(t);return e};function BM(t){return BM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},BM(t)}function UM(t){return zM(t)||GM(t)||HM(t)||VM()}function VM(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function HM(t,e){if(t){if("string"===typeof t)return FM(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?FM(t,e):void 0}}function GM(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function zM(t){if(Array.isArray(t))return FM(t)}function FM(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function WM(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function qM(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function $M(t,e,n){return e&&qM(t.prototype,e),n&&qM(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function YM(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ZM(t,e)}function ZM(t,e){return ZM=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},ZM(t,e)}function XM(t){var e=JM();return function(){var n,r=tC(t);if(e){var i=tC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return KM(this,n)}}function KM(t,e){if(e&&("object"===BM(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return QM(t)}function QM(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function JM(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function tC(t){return tC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},tC(t)}var eC=function(t){var e=function(t){YM(n,t);var e=XM(n);function n(){return WM(this,n),e.apply(this,arguments)}return $M(n,[{key:"_changeState",value:function(){throw new Error("_changeState() should be overridden to perform actual change in state.")}},{key:"changeState",value:function(){for(var t=this,e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var i="string"===typeof n[0]?n.shift():void 0,o=Object(n[0])===n[0]&&"function"!==typeof n[0]?n.shift():void 0,a="function"===typeof n[0]?n.shift():void 0;if("function"!==typeof this.shouldStateBeChanged||this.shouldStateBeChanged(i,o)){var s={group:o&&o.group,state:i},u=[s.group,i].filter(Boolean).join("-").split("-").map((function(t){return t[0].toUpperCase()+t.substr(1)})).join(""),l=new CustomEvent(this.options["eventBefore".concat(u)],{bubbles:!0,cancelable:!0,detail:o}),c=o&&o.delegatorNode||this.element,h=!c.dispatchEvent(l);if(h){if(a){var f=new Error("Changing state (".concat(JSON.stringify(s),") has been canceled."));f.canceled=!0,a(f)}}else{var p=[i,o].filter(Boolean);this._changeState.apply(this,UM(p).concat([function(){c.dispatchEvent(new CustomEvent(t.options["eventAfter".concat(u)],{bubbles:!0,cancelable:!0,detail:o})),a&&a()}]))}}else a&&a(null,!0)}}]),n}(t);return e};function nC(t){if(!t||"function"===typeof t)return{launchingElement:null,launchingEvent:null};var e=t.delegateTarget||t.currentTarget||t,n=t.currentTarget&&t;if(e&&!e.nodeType)throw new TypeError("DOM Node should be given for launching element.");if(n&&!n.type)throw new TypeError("DOM event should be given for launching event.");return{launchingElement:e,launchingEvent:n}}function rC(t){return rC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rC(t)}function iC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function oC(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function aC(t,e,n){return e&&oC(t.prototype,e),n&&oC(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function sC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&uC(t,e)}function uC(t,e){return uC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},uC(t,e)}function lC(t){var e=fC();return function(){var n,r=pC(t);if(e){var i=pC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return cC(this,n)}}function cC(t,e){if(e&&("object"===rC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return hC(t)}function hC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function fC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function pC(t){return pC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},pC(t)}function dC(t){var e=function(t){sC(n,t);var e=lC(n);function n(){return iC(this,n),e.apply(this,arguments)}return aC(n,[{key:"show",value:function(t,e){t&&"function"!==typeof t||(e=t),this.changeState("shown",nC(t),e)}},{key:"hide",value:function(t,e){t&&"function"!==typeof t||(e=t),this.changeState("hidden",nC(t),e)}}]),n}(t);return e}var vC=[eC,dC],gC=vC;function mC(t){return mC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mC(t)}function yC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _C(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function bC(t,e,n){return e&&_C(t.prototype,e),n&&_C(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function wC(){return wC="undefined"!==typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=OC(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(arguments.length<3?t:n):i.value}},wC.apply(this,arguments)}function OC(t,e){while(!Object.prototype.hasOwnProperty.call(t,e))if(t=AC(t),null===t)break;return t}function xC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&EC(t,e)}function EC(t,e){return EC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},EC(t,e)}function TC(t){var e=CC();return function(){var n,r=AC(t);if(e){var i=AC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return SC(this,n)}}function SC(t,e){if(e&&("object"===mC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return MC(t)}function MC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function CC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function AC(t){return AC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},AC(t)}var LC=function(t){var e=function(t){xC(n,t);var e=TC(n);function n(){var t;yC(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return t=e.call.apply(e,[this].concat(i)),t.handles=new Set,t}return bC(n,[{key:"manage",value:function(t){return this.handles.add(t),t}},{key:"unmanage",value:function(t){return this.handles.delete(t),t}},{key:"release",value:function(){var t=this;return this.handles.forEach((function(e){e.release(),t.handles.delete(e)})),wC(AC(n.prototype),"release",this).call(this)}}]),n}(t);return e};function DC(t){return DC="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},DC(t)}function kC(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function PC(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function RC(t,e,n){return e&&PC(t.prototype,e),n&&PC(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function IC(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&NC(t,e)}function NC(t,e){return NC=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},NC(t,e)}function jC(t){var e=VC();return function(){var n,r=HC(t);if(e){var i=HC(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return BC(this,n)}}function BC(t,e){if(e&&("object"===DC(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return UC(t)}function UC(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function VC(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function HC(t){return HC=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},HC(t)}var GC,zC,FC=function(t){IC(n,t);var e=jC(n);function n(t,r){var i;return kC(this,n),i=e.call(this,t,r),i._handleFocusinListener=void 0,i._handleKeydownListener=void 0,i._handleFocusin=function(t){var e=i.element.querySelector(i.options.selectorModalContainer)||i.element;i.element.classList.contains(i.options.classVisible)&&!e.contains(t.target)&&i.options.selectorsFloatingMenus.every((function(e){return!EM(t,e)}))&&i.element.querySelector(tM.selectorTabbable).focus()},i._hookCloseActions(),i}return RC(n,[{key:"createdByLauncher",value:function(t){this.show(t)}},{key:"shouldStateBeChanged",value:function(t){return"shown"===t?!this.element.classList.contains(this.options.classVisible):this.element.classList.contains(this.options.classVisible)}},{key:"_changeState",value:function(t,e,n){var r,i=this,o=function(){if(r&&(r=i.unmanage(r).release()),"shown"===t&&i.element.offsetWidth>0&&i.element.offsetHeight>0){i.previouslyFocusedNode=i.element.ownerDocument.activeElement;var e=i.element.querySelector(i.options.selectorPrimaryFocus)||i.element.querySelector(tM.selectorTabbable);e.focus()}n()};if(this._handleFocusinListener&&(this._handleFocusinListener=this.unmanage(this._handleFocusinListener).release()),"shown"===t){var a="onfocusin"in this.element.ownerDocument.defaultView,s=a?"focusin":"focus";this._handleFocusinListener=this.manage(TM(this.element.ownerDocument,s,this._handleFocusin,!a))}"hidden"===t?(this.element.classList.toggle(this.options.classVisible,!1),this.element.ownerDocument.body.classList.toggle(this.options.classBody,!1),(this.options.selectorFocusOnClose||this.previouslyFocusedNode)&&(this.element.ownerDocument.querySelector(this.options.selectorFocusOnClose)||this.previouslyFocusedNode).focus()):"shown"===t&&(this.element.classList.toggle(this.options.classVisible,!0),this.element.ownerDocument.body.classList.toggle(this.options.classBody,!0)),r=this.manage(TM(this.element,"transitionend",o))}},{key:"_hookCloseActions",value:function(){var t=this;this.manage(TM(this.element,"click",(function(e){var n=EM(e,t.options.selectorModalClose);n&&(e.delegateTarget=n),(n||e.target===t.element)&&t.hide(e)}))),this._handleKeydownListener&&(this._handleKeydownListener=this.unmanage(this._handleKeydownListener).release()),this._handleKeydownListener=this.manage(TM(this.element.ownerDocument.body,"keydown",(function(e){27===e.which&&t.shouldStateBeChanged("hidden")&&(e.stopPropagation(),t.hide(e))})))}}],[{key:"options",get:function(){var t=tM.prefix;return{selectorInit:"[data-modal]",selectorModalClose:"[data-modal-close]",selectorPrimaryFocus:"[data-modal-primary-focus]",selectorsFloatingMenus:[".".concat(t,"--overflow-menu-options"),".".concat(t,"--tooltip"),".flatpickr-calendar"],selectorModalContainer:".".concat(t,"--modal-container"),classVisible:"is-visible",classBody:"".concat(t,"--body--with-modal-open"),attribInitTarget:"data-modal-target",initEventNames:["click"],eventBeforeShown:"modal-beingshown",eventAfterShown:"modal-shown",eventBeforeHidden:"modal-beinghidden",eventAfterHidden:"modal-hidden"}}}]),n.components=new WeakMap,n}(hM(xM,jM,gC,LC)),WC=FC,qC=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),$C=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="modal",i.isEventListenerAdded=!1,i.handleShowModal=function(){i.modal.html(i.getModalHTML()),i.modal.select("div.cds--modal-footer button.cds--btn").on("click",(function(){return i.model.exportToCSV()}));var t=WC.create(i.modal.node());t.show()},i.init(),i}return qC(e,t),e.prototype.addEventListeners=function(){this.services.events.addEventListener(ft.Modal.SHOW,this.handleShowModal)},e.prototype.removeEventListeners=function(){this.services.events.removeEventListener(ft.Modal.SHOW,this.handleShowModal)},e.prototype.getModalHTML=function(){var t=this.model.getOptions(),e=Dd(t,"style","prefix"),n=this.model.getTabularDataArray();return'\n\t\t<div class="cds--modal-container cds--modal-container">\n\t\t\t<div class="cds--modal-header cds--modal-header">\n\t\t\t\t<p class="cds--modal-header__label cds--type-delta cds--modal-header__label cds--type-delta" id="modal-title">Tabular representation</p>\n\n\t\t\t\t<p class="cds--modal-header__heading cds--type-beta cds--modal-header__heading cds--type-beta" id="modal-description">'+t.title+'</p>\n\n\t\t\t\t<button class="cds--modal-close cds--modal-close" type="button" data-modal-close aria-label="close modal" data-modal-primary-focus>\n\t\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet" xmlns="http://www.w3.org/2000/svg" fill="currentColor" aria-label="Close" width="20" height="20" viewBox="0 0 32 32" role="img" class="cds--modal-close__icon cds--modal-close__icon">\n\t\t\t\t\t\t<path d="M24 9.4L22.6 8 16 14.6 9.4 8 8 9.4 14.6 16 8 22.6 9.4 24 16 17.4 22.6 24 24 22.6 17.4 16 24 9.4z"></path>\n\t\t\t\t\t</svg>\n\t\t\t\t</button>\n\t\t\t</div>\n\n\t\t\t<div class="cds--modal-content cds--modal-content">\n\t\t\t\t<table class="cds--data-table cds--data-table--no-border cds--data-table cds--data-table--no-border">\n\t\t\t\t\t<thead>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t'+tl(n,0).map((function(t){return'<th scope="col">\n\t\t\t\t\t\t\t\t<div class="cds--table-header-label cds--table-header-label">'+t+"</div>\n\t\t\t\t\t\t\t</th>"})).join("")+"\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</thead>\n\n\t\t\t\t\t<tbody>"+n.slice(1).map((function(t){return"\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t"+t.map((function(t){return"<td>"+t+"</td>"})).join("")+"\n\t\t\t\t\t\t\t</tr>"})).join("")+'\n\t\t\t\t\t</tbody>\n\t\t\t\t</table>\n\t\t\t</div>\n\n\t\t\t<div class="cds--modal-footer cds--modal-footer">\n\t\t\t <div class="'+dt+"--"+e+'-modal-footer-spacer"></div>\n\t\t\t <button class="cds--btn cds--btn--primary cds--btn cds--btn--primary" type="button" data-modal-primary-focus>Download as CSV</button>\n\t\t\t</div>\n\t\t</div>'},e.prototype.render=function(){var t=this.model.getOptions();if(!this.isEventListenerAdded){var e=eb(this.services.domUtils.getHolder()),n=Dd(t,"style","prefix");this.modal=sb.appendOrSelect(e,"div."+dt+"--"+n+"--modal"),this.addEventListeners(),this.isEventListenerAdded=!0,this.modal.attr("data-modal",!0).attr("class","cds--modal cds--modal").attr("role","dialog").attr("aria-modal",!0).attr("aria-labelledby","modal-title").attr("aria-describedby","modal-description").attr("tabindex",-1)}},e.prototype.destroy=function(){this.removeEventListeners(),this.isEventListenerAdded=!1},e}(DS);(function(t){t["LEFT"]="left",t["RIGHT"]="right",t["TOP"]="top",t["BOTTOM"]="bottom"})(zC||(zC={}));var YC=(GC={},GC[zC.LEFT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left-e.offsetWidth)}},GC[zC.RIGHT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left+n.width)}},GC[zC.TOP]=function(t,e,n){return{top:Math.round(t.top-e.offsetHeight),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},GC[zC.BOTTOM]=function(t,e,n){return{top:Math.round(t.top+n.height),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},GC),ZC="undefined"!==typeof window?window:{innerHeight:0,scrollY:0,innerWidth:0,scrollX:0},XC=function(){function t(t){void 0===t&&(t={}),this.positions=YC,this.positions=Object.assign({},YC,t)}return t.prototype.getRelativeOffset=function(t){var e={left:t.offsetLeft,top:t.offsetTop};while(t.offsetParent&&"static"===getComputedStyle(t.offsetParent).position)e.left+=t.offsetLeft,e.top+=t.offsetTop,t=t.offsetParent;return e},t.prototype.getAbsoluteOffset=function(t){var e=t,n={top:0,left:0};while(e.offsetParent){var r=getComputedStyle(e.offsetParent);"static"===r.position&&r.marginLeft&&r.marginTop&&(parseInt(r.marginTop,10)&&(n.top+=parseInt(r.marginTop,10)),parseInt(r.marginLeft,10)&&(n.left+=parseInt(r.marginLeft,10))),e=e.offsetParent}var i=t.getBoundingClientRect(),o=document.body.getBoundingClientRect();return{top:i.top-o.top+n.top,left:i.left-o.left+n.left}},t.prototype.findRelative=function(t,e,n){var r=this.getRelativeOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findAbsolute=function(t,e,n){var r=this.getAbsoluteOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findPosition=function(t,e,n,r){void 0===r&&(r=this.getAbsoluteOffset.bind(this));var i=r(t),o=t.getBoundingClientRect();return this.calculatePosition(i,o,e,n)},t.prototype.findPositionAt=function(t,e,n){return this.calculatePosition(t,{top:0,left:0,height:0,width:0},e,n)},t.prototype.getPlacementBox=function(t,e){var n=t.offsetHeight+e.top,r=t.offsetWidth+e.left;return{top:e.top,bottom:n,left:e.left,right:r}},t.prototype.addOffset=function(t,e,n){return void 0===e&&(e=0),void 0===n&&(n=0),Object.assign({},t,{top:t.top+e,left:t.left+n})},t.prototype.setElement=function(t,e){t.style.top=e.top+"px",t.style.left=e.left+"px"},t.prototype.findBestPlacement=function(t,e,n,r,i){var o=this;void 0===r&&(r=this.defaultContainerFunction.bind(this)),void 0===i&&(i=this.findPosition.bind(this));var a=n.map((function(n){var a=i(t,e,n),s=o.getPlacementBox(e,a),u=0,l=0,c=r();s.top<c.top?u=c.top-s.top:s.bottom>c.height&&(u=s.bottom-c.height),s.left<c.left?l=c.left-s.left:s.right>c.width&&(l=s.right-c.width),u&&!l?l=1:l&&!u&&(u=1);var h=e.offsetHeight*e.offsetWidth,f=u*l,p=h-f,d=p/h;return{placement:n,weight:d}}));return a.sort((function(t,e){return e.weight-t.weight})),a[0].placement},t.prototype.findBestPlacementAt=function(t,e,n,r){var i=this;void 0===r&&(r=this.defaultContainerFunction.bind(this));var o=function(e,n,r){return i.findPositionAt(t,n,r)};return this.findBestPlacement(null,e,n,r,o)},t.prototype.defaultContainerFunction=function(){return{top:0,left:0,height:ZC.innerHeight,width:ZC.innerWidth}},t.prototype.calculatePosition=function(t,e,n,r){return this.positions[r]?this.positions[r](t,n,e):(console.error("No function found for placement, defaulting to 0,0"),{left:0,top:0})},t}(),KC=(new XC,XC),QC=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),JC=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.type="threshold",r.renderType=I.SVG,r.positionService=new KC,r}return QC(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n=Dd(this.getOptions(),"axes"),r=[];Object.keys(n).forEach((function(t){var e,i;if(Object.values(B).includes(t)){var o=n[t];o.thresholds&&o.thresholds.length>0&&r.push({axisPosition:t,thresholds:o.thresholds,correspondingDatasets:null===(e=o)||void 0===e?void 0:e.correspondingDatasets,mapsTo:null===(i=o)||void 0===i?void 0:i.mapsTo})}}));var i=this.getComponentContainer({withinChartClip:!0}),o=i.selectAll("g.axis-thresholds").data(r,(function(t){return t.axisPosition}));o.exit().attr("opacity",0).remove();var a=o.enter().append("g"),s=a.merge(o);s.attr("class",(function(t){return"axis-thresholds "+t.axisPosition}));var u=s.selectAll("g.threshold-group").data((function(t){return t.thresholds.map((function(n){return n.axisPosition=t.axisPosition,n.datum=e.constructDatumObj(t,n),n}))}));u.exit().attr("opacity",0).remove();var l=u.enter().append("g");l.append("line").attr("class","threshold-line"),l.append("rect").attr("class","threshold-hoverable-area");var c=l.merge(u);c.attr("class","threshold-group");var h=this;s.each((function(e){var n=e.axisPosition,r=h.services.cartesianScales.getScaleByPosition(n),i=h.services.cartesianScales.getScaleTypeByPosition(n),o=null,a=null;n===B.LEFT||n===B.RIGHT?(a=r,o=h.services.cartesianScales.getMainXScale()):(o=r,a=h.services.cartesianScales.getMainYScale());var s=i===G.LABELS,u=o.range(),l=u[0],c=u[1],f=a.range(),p=f[0],d=f[1],v=h.services.cartesianScales,g=v.getOrientation(),m=function(t){return v.getDomainValue(t)},y=function(t){return v.getRangeValue(t)},_=Rd(m,y,g),b=_[0],w=_[1],O=eb(this);n===B.TOP||n===B.BOTTOM?(O.selectAll("line.threshold-line").transition().call((function(e){return h.services.transitions.setupTransition({transition:e,name:"threshold-line-update",animate:t})})).attr("y1",d).attr("y2",p).attr("x1",(function(t){var e=t.datum;return b(e)+(s?r.step()/2:0)})).attr("x2",(function(t){var e=t.datum;return b(e)+(s?r.step()/2:0)})).style("stroke",(function(t){var e=t.fillColor;return e})),O.selectAll("rect.threshold-hoverable-area").attr("x",0).attr("y",(function(t){var e=t.datum;return-b(e)})).attr("width",Math.abs(p-d)).classed("rotate",!0)):(O.selectAll("line.threshold-line").transition().call((function(e){return h.services.transitions.setupTransition({transition:e,name:"threshold-line-update",animate:t})})).attr("x1",l).attr("x2",c).attr("y1",(function(t){var e=t.datum;return w(e)+(s?r.step()/2:0)})).attr("y2",(function(t){var e=t.datum;return w(e)+(s?r.step()/2:0)})).style("stroke",(function(t){var e=t.fillColor;return e})),O.selectAll("rect.threshold-hoverable-area").attr("x",l).attr("y",(function(t){var e=t.datum;return w(e)})).attr("width",Math.abs(c-l)).classed("rotate",!1))})),this.services.events.addEventListener(ft.Threshold.SHOW,(function(t){e.setThresholdLabelPosition(t.detail),e.label.classed("hidden",!1)})),this.services.events.addEventListener(ft.Threshold.HIDE,(function(t){e.label.classed("hidden",!0)})),this.appendThresholdLabel(),this.addEventListeners()},e.prototype.getFormattedValue=function(t){var e=t.value,n=t.axisPosition,r=this.getOptions(),i=this.services.cartesianScales.getScaleTypeByPosition(n);if(i===G.TIME){var o=[B.LEFT,B.RIGHT].includes(n),a=this.services.cartesianScales.getMainXScale(),s=this.services.cartesianScales.getMainYScale(),u=o?s:a,l=Dd(r,"timeScale"),c=$m(u.ticks());return zm(e,0,u.ticks(),c,l)}return e.toLocaleString("en")},e.prototype.appendThresholdLabel=function(){var t=eb(this.services.domUtils.getHolder()),e=Dd(this.getOptions(),"style","prefix");this.label=sb.appendOrSelect(t,"div."+dt+"--"+e+"--threshold--label").classed("hidden",!0)},e.prototype.setThresholdLabelPosition=function(t){var e=t.event,n=t.datum,r=this.services.domUtils.getHolder(),i=wd(e,r),o=n.valueFormatter?n.valueFormatter(n.value):this.getFormattedValue(n);this.label.html((n.label||"Threshold")+": "+o).style("background-color",n.fillColor);var a=this.label.node(),s=this.positionService.findBestPlacementAt({left:i[0],top:i[1]},a,[zC.RIGHT,zC.LEFT,zC.TOP,zC.BOTTOM],(function(){return{top:void 0,left:void 0,width:r.offsetWidth,height:r.offsetHeight}})),u=this.positionService.findPositionAt({left:i[0],top:i[1]},a,s);this.positionService.setElement(a,u)},e.prototype.constructDatumObj=function(t,e){var n={};return t.correspondingDatasets&&(n["group"]=Dd(t,"correspondingDatasets",0)),n[t["mapsTo"]]=e.value,n},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer({withinChartClip:!0});e.selectAll("rect.threshold-hoverable-area").on("mouseover mousemove",(function(e){eb(this.parentNode).select("line.threshold-line").classed("active",!0),t.services.events.dispatchEvent(ft.Threshold.SHOW,{event:e,hoveredElement:eb(this),datum:eb(this).datum()})})).on("mouseout",(function(e){eb(this.parentNode).select("line.threshold-line").classed("active",!1),t.services.events.dispatchEvent(ft.Threshold.HIDE,{event:e,hoveredElement:eb(this),datum:eb(this).datum()})}))},e}(DS),tA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="title",e.renderType=I.HTML,e}return tA(e,t),e.prototype.render=function(){var t=this.getComponentContainer(),e=Dd(this.getOptions(),"title"),n=t.selectAll("p.title").data([e]);if(n.enter().append("p").classed("title",!0).attr("role","heading").attr("aria-level",2).merge(n).html((function(t){return t})),n.node()&&n.node().offsetWidth<n.node().scrollWidth){var r=this;n.on("mouseover",(function(t){r.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:n,content:n.text()})})).on("mousemove",(function(t){r.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(){r.services.events.dispatchEvent(ft.Tooltip.HIDE)}))}n.exit().remove()},e.prototype.truncateTitle=function(t,e){if(!(e<=0)){var n=t.text();if(t.node().getComputedTextLength()>e){t.append("tspan").text("...");var r=sb.appendOrSelect(t,"tspan").node().getComputedTextLength(),i=t.text(),o=this.getSubstringIndex(t.node(),0,i.length-1,e-r);t.html(i.substring(0,o-1)).append("tspan").text("...");var a=this;t.on("mouseover",(function(e){a.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:t,content:n})})).on("mousemove",(function(t){a.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(){a.services.events.dispatchEvent(ft.Tooltip.HIDE)}))}}},e.prototype.getMaxTitleWidth=function(){return sb.getSVGElementSize(this.parent.node(),{useAttrs:!0}).width},e.prototype.getSubstringIndex=function(t,e,n,r){var i=Math.floor((n+e)/2);return t.getSubStringLength(0,i)>r?this.getSubstringIndex(t,e,i,r):t.getSubStringLength(0,i)<r?t.getSubStringLength(0,i+1)>r?i:this.getSubstringIndex(t,i,n,r):i},e}(DS),nA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="meter-title",e.renderType=I.SVG,e}return nA(e,t),e.prototype.render=function(){var t=Dd(this.model.getDisplayData(),0),e=this.getOptions(),n=this.getComponentContainer(),r=e.data.groupMapsTo,i=Dd(e,"meter","proportional");if(i)this.displayTotal(),this.displayBreakdownTitle();else{var o=n.selectAll("text.meter-title").data([t[r]]);o.enter().append("text").classed("meter-title",!0).merge(o).attr("x",0).attr("y","1em").text((function(t){return t})),o.exit().remove(),this.appendPercentage()}this.displayStatus();var a=this.getMaxTitleWidth(),s=sb.appendOrSelect(n,"text.meter-title");a>0&&s.node().getComputedTextLength()>a&&this.truncateTitle(s,a)},e.prototype.displayBreakdownTitle=function(){var t,e=this.getComponentContainer(),n=this.getOptions(),r=this.model.getMaximumDomain(this.model.getDisplayData()),i=Dd(n,"meter","proportional","total"),o=Dd(n,"meter","proportional","unit")?Dd(n,"meter","proportional","unit"):"";if(r===i)t=null;else{var a=null!==i?i-r:r,s=Dd(n,"meter","proportional","breakdownFormatter");t=null!==s?s({datasetsTotal:r,total:i}):r+" "+o+" used ("+a+" "+o+" available)"}var u=e.selectAll("text.proportional-meter-title").data([t]);u.enter().append("text").classed("proportional-meter-title",!0).merge(u).attr("x",0).attr("y","1em").text((function(t){return t})),u.exit().remove();var l=this.getMaxTitleWidth(),c=sb.appendOrSelect(e,"text.proportional-meter-title");l>0&&c.node().getComputedTextLength()>l&&this.truncateTitle(c,l)},e.prototype.displayTotal=function(){var t=this.getComponentContainer(),e=this.getOptions(),n=Dd(e,"meter","proportional","total"),r=n?Dd(e,"meter","proportional","total"):this.model.getMaximumDomain(this.model.getDisplayData()),i=Dd(e,"meter","proportional","unit")?Dd(e,"meter","proportional","unit"):"",o=Dd(e,"meter","proportional","totalFormatter"),a=null!==o?o(r):n+" "+i+" total",s=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),u=s.width?s.width:this.parent.node().getAttribute("width"),l=t.selectAll("text.proportional-meter-total").data([a]);l.enter().append("text").classed("proportional-meter-total",!0).merge(l).attr("x",this.model.getStatus()&&"string"!==typeof u?u-Et.total.paddingRight:u).attr("y","1em").attr("text-anchor","end").text((function(t){return t})),l.exit().remove()},e.prototype.displayStatus=function(){var t=this,e=this.getComponentContainer(),n=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),r=n.width?n.width:0,i=this.model.getStatus(),o=Et.status.indicatorSize/2,a=sb.appendOrSelect(e,"g.status-indicator").attr("class",null!==i?"status-indicator status--"+i:"").attr("transform","translate("+(r-o)+", 0)"),s=i?[i]:[],u=a.selectAll("circle.status").data(s);u.enter().append("circle").merge(u).attr("class","status").attr("r",o).attr("cx",0).attr("cy","calc(1em / 2)");var l=a.selectAll("path.innerFill").data(s);l.enter().append("path").merge(l).attr("d",t.getStatusIconPathString(i)).attr("transform","translate(-"+o+", 0)").attr("class","innerFill"),l.exit().remove(),u.exit().remove()},e.prototype.appendPercentage=function(){var t=Dd(this.model.getDisplayData(),0,"value"),e=this.getComponentContainer(),n=sb.appendOrSelect(e,"text.meter-title"),r=!0===Dd(this.getOptions(),"meter","statusBar","percentageIndicator","enabled")?[t]:[],i=e.selectAll("text.percent-value").data(r),o=Et.statusBar.paddingRight;i.enter().append("text").classed("percent-value",!0).merge(i).text((function(t){return t+"%"})).attr("x",+n.attr("x")+n.node().getComputedTextLength()+o).attr("y",n.attr("y")),i.exit().remove()},e.prototype.truncateTitle=function(e,n){t.prototype.truncateTitle.call(this,e,n);var r=sb.appendOrSelect(this.parent,"tspan"),i=Et.statusBar.paddingRight,o=Math.ceil(r.node().getComputedTextLength()),a=sb.appendOrSelect(this.parent,"text.percent-value");a.attr("x",+e.attr("x")+e.node().getComputedTextLength()+o+i)},e.prototype.getMaxTitleWidth=function(){var t=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),e=Dd(this.getOptions(),"meter","proportional"),n=t.width?t.width:this.parent.node().getAttribute("width");if(null!==e){var r=sb.appendOrSelect(this.parent,"text.proportional-meter-total").node(),i=sb.getSVGElementSize(r,{useBBox:!0}).width;return n-i-Et.total.paddingLeft}var o=sb.appendOrSelect(this.parent,"text.percent-value"),a=Et.statusBar.paddingRight,s=o.node().getComputedTextLength(),u=sb.appendOrSelect(this.parent,"g.status-indicator").node(),l=sb.getSVGElementSize(u,{useBBox:!0}).width+Et.status.paddingLeft;return n-s-a-l},e.prototype.getStatusIconPathString=function(t){switch(t){case nt.SUCCESS:return"M6.875 11.3125 3.75 8.1875 4.74375 7.25 6.875 9.34375 11.50625 4.75 12.5 5.7375 Z";case nt.DANGER:return"M10.7 11.5 4.5 5.3 5.3 4.5 11.5 10.7 Z";case nt.WARNING:return"M7.9375,11.125 C7.41973305,11.125 7,11.544733 7,12.0625 C7,12.580267 7.41973305,13 7.9375,13 C8.45526695,13 8.875,12.580267 8.875,12.0625 C8.875,11.544733 8.45526695,11.125 7.9375,11.125 M7.3125, 3 8.5625, 3 8.5625, 9.875 7.3125, 9.875, 7.3125, 3 Z"}},e}(eA),iA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oA=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="tooltip",i.renderType=I.HTML,i.isEventListenerAdded=!1,i.positionService=new KC,i.handleShowTooltip=function(t){var e,n=t.detail.data||t.detail.items,r=i.formatItems(i.getItems(t));e=t.detail.content?'<div class="title-tooltip"><p>'+t.detail.content+"</p></div>":i.getTooltipHTML(r);var o=sb.appendOrSelect(i.tooltip,"div.content-box");if(Dd(i.getOptions(),"tooltip","customHTML"))if(t.detail.content){var a='<div class="title-tooltip"><p>'+t.detail.content+"</p></div>";o.html(a)}else o.html(i.model.getOptions().tooltip.customHTML(n,e));else o.html(e);o.selectAll(".datapoint-tooltip").each((function(t,e){var n=r[e];r[e]&&r[e].color&&eb(this).select(".tooltip-color").attr("class","tooltip-color").style("background-color",n.color)})),i.positionTooltip(t),i.tooltip.classed("hidden",!1).attr("aria-hidden",!1)},i.handleHideTooltip=function(){i.tooltip.classed("hidden",!0).attr("aria-hidden",!0)},i.init(),i}return iA(e,t),e.prototype.addTooltipEventListener=function(){var t=this;this.services.events.addEventListener(ft.Tooltip.MOVE,(function(e){!1===t.tooltip.classed("hidden")&&t.positionTooltip(e)})),this.services.events.addEventListener(ft.Tooltip.SHOW,this.handleShowTooltip),this.services.events.addEventListener(ft.Tooltip.HIDE,this.handleHideTooltip),this.services.events.addEventListener(ft.Chart.MOUSEOUT,this.handleHideTooltip)},e.prototype.removeTooltipEventListener=function(){this.services.events.removeEventListener(ft.Tooltip.MOVE,null),this.services.events.removeEventListener(ft.Tooltip.SHOW,this.handleShowTooltip),this.services.events.removeEventListener(ft.Tooltip.HIDE,this.handleHideTooltip),this.services.events.removeEventListener(ft.Chart.MOUSEOUT,this.handleHideTooltip)},e.prototype.getItems=function(t){return t.detail.items?t.detail.items:[]},e.prototype.formatItems=function(t){var e=this,n=this.getOptions(),r=Dd(n,"tooltip","truncation","type"),i=Dd(n,"tooltip","truncation","threshold"),o=Dd(n,"tooltip","truncation","numCharacter");return r!==V.NONE?t.map((function(t){var n=t.labelIcon?12:0;return t.value=t.value?e.valueFormatter(t.value,t.label):t.value,t.label&&t.label.length+n>i&&(t.label=Ad(t.label,r,o)),t.value&&t.value.length>i&&(t.value=Ad(t.value,r,o)),t})):t},e.prototype.getTooltipHTML=function(t){return'<ul class="multi-tooltip">'+t.map((function(t){return'<li>\n\t\t\t\t\t<div class="datapoint-tooltip'+(t.bold?" bold":"")+'">\n\t\t\t\t\t\t'+(t.class||t.color?'<div class="tooltip-color '+t.class+'"></div>':"")+'\n\t\t\t\t\t\t<div class="label">\n\t\t\t\t\t\t<p>'+(t.label||"")+"</p>\n\t\t\t\t\t\t"+(t.labelIcon?'<span class="label-icon"/>'+t.labelIcon+"</span>":"")+"\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t"+(void 0===t.value||null===t.value?"":'<p class="value"/>'+t.value+"</p>")+"\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"</ul>"},e.prototype.valueFormatter=function(t,e){var n=this.getOptions(),r=Dd(n,"tooltip","valueFormatter");if(r)return r(t,e);if("function"===typeof t.getTime)return Bm(t,"MMM d, yyyy");try{if("string"===typeof t&&/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z/.test(t))return Bm(Date.parse(t),"MMM d, yyyy")}catch(i){}return t.toLocaleString()},e.prototype.render=function(){var t=this.getOptions(),e=Dd(t,"tooltip","enabled");if(e){var n=eb(this.services.domUtils.getHolder()),r=Dd(t,"style","prefix");this.tooltip=sb.appendOrSelect(n,"div."+dt+"--"+r+"--tooltip"),this.tooltip.style("max-width",null).attr("role","tooltip"),this.isEventListenerAdded||(this.addTooltipEventListener(),this.isEventListenerAdded=!0),this.tooltip.classed("hidden",!0)}else!e&&this.isEventListenerAdded&&(this.removeTooltipEventListener(),this.isEventListenerAdded=!1)},e.prototype.positionTooltip=function(t){var e,n=this.services.domUtils.getHolder(),r=this.tooltip.node(),i=this.getOptions(),o=Dd(i,"zoomBar","top","enabled"),a=Dd(t,"detail","mousePosition");if(a){var s=Dd(i,"zoomBar","top","type"),u=Pt.height[s];o&&(a[1]+=u+Pt.spacerHeight)}else a=wd(Dd(t,"detail","event"),n);var l,c=n.offsetWidth,h=n.offsetHeight;l=a[0]/c>.9?zC.LEFT:a[0]/c<.1?zC.RIGHT:this.positionService.findBestPlacementAt({left:a[0],top:a[1]},r,[zC.RIGHT,zC.LEFT,zC.TOP,zC.BOTTOM],(function(){return{top:void 0,left:void 0,width:c,height:h}}));var f=Lt.horizontalOffset;l===zC.LEFT&&(f*=-1),e=this.positionService.findPositionAt({left:a[0]+f,top:a[1]},r,l),this.positionService.setElement(r,e)},e}(DS),aA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sA=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},uA=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return aA(e,t),e.prototype.getItems=function(t){var e=this;if(t.detail.items)return t.detail.items;var n=t.detail.data;if(!Array.isArray(n)||!n.length||!n[0])return[];var r,i=this.getOptions(),o=this.services.cartesianScales,a=o.getDomainIdentifier(),s=o.isDualAxes(),u=i.data.groupMapsTo,l=o.getDomainLabel(),c=o.getRangeLabel(),h=n[0][a];if(1===n.length){var f=n[0],p=o.getRangeIdentifier(f);if(s){var d=o.getRangeAxisPosition({datum:f,groups:[f[u]]});c=o.getScaleLabel(d)}var v=f[p];r=sA([{label:l,value:h}],Array.isArray(v)&&2===v.length?[{label:"Start",value:v[0]},{label:"End",value:v[1]}]:[{label:c,value:f[p]}]),t.detail.additionalItems&&t.detail.additionalItems.forEach((function(t){return r.push({label:t.label,value:t.value})})),r.push({label:i.tooltip.groupLabel,value:f[u],color:this.model.getFillColor(f[u]),class:this.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:f[u]})})}else if(n.length>1&&(r=[{label:l,value:h}],r=r.concat(n.map((function(t){var n=t[o.getRangeIdentifier(t)];return{label:t[u],value:Array.isArray(n)&&2===n.length?n[0]+" - "+n[1]:n,color:e.model.getFillColor(t[u]),class:e.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:t[u]})}})).sort((function(t,e){return e.value-t.value}))),!s&&!0===Dd(i,"tooltip","showTotal"))){var g=o.getRangeIdentifier();r.push({label:tl(i,"tooltip.totalLabel")||"Total",value:n.reduce((function(t,e){return t+e[g]}),0),bold:!0})}return r},e}(oA),lA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),cA=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="chart-clip",i.renderType=I.SVG,i.chartClipId="chart-clip-id-"+Math.floor(99999999999*Math.random()),i.init(),i}return lA(e,t),e.prototype.init=function(){this.model.set({chartClipId:this.chartClipId},{skipUpdate:!0})},e.prototype.render=function(t){void 0===t&&(t=!0),this.createClipPath()},e.prototype.createClipPath=function(){var t=this.parent,e=this.services.cartesianScales,n=e.getMainXScale(),r=e.getMainYScale(),i=n.range(),o=i[0],a=i[1],s=r.range(),u=s[0],l=s[1];this.chartClipPath=sb.appendOrSelect(t,"clipPath."+this.type).attr("id",this.chartClipId);var c=sb.appendOrSelect(this.chartClipPath,"rect."+this.type);a-o>0&&c.attr("x",o).attr("y",l).attr("width",a-o).attr("height",u-l),this.chartClipPath.merge(c).lower()},e}(DS),hA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),fA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="canvas-chart-clip",e.chartClipId="canvas-chart-clip-id-"+Math.floor(99999999999*Math.random()),e}return hA(e,t),e.prototype.createClipPath=function(){var t=this.parent,e=sb.getSVGElementSize(this.parent,{useAttrs:!0}),n=e.width,r=e.height;this.chartClipPath=sb.appendOrSelect(t,"clipPath."+this.type).attr("id",this.chartClipId);var i=sb.appendOrSelect(this.chartClipPath,"rect."+this.type);i.attr("x",0).attr("y",0).attr("width",n).attr("height",r),this.chartClipPath.merge(i).lower()},e}(cA),pA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dA=function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]])}return n},vA=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.type="highlight",r.renderType=I.SVG,r.positionService=new KC,r.highlightStrokeWidth=1,r}return pA(e,t),e.prototype.render=function(t){void 0===t&&(t=!1);var e=Dd(this.getOptions(),"axes"),n=[];Object.keys(e).forEach((function(t){if(Object.values(B).includes(t)){var r=e[t];r.highlights&&r.highlights.data.length>0&&n.push({axisPosition:t,highlightStartMapsTo:r.highlights.highlightStartMapsTo,highlightEndMapsTo:r.highlights.highlightEndMapsTo,labelMapsTo:r.highlights.labelMapsTo,highlight:r.highlights.data,color:r.highlights.color})}}));var r=this.getComponentContainer({withinChartClip:!0}),i=r.selectAll("g.axis-highlight").data(n,(function(t){return t.axisPosition}));i.exit().attr("opacity",0).remove();var o=i.enter().append("g"),a=o.merge(i);a.attr("class",(function(t){return"axis-highlight "+t.axisPosition}));var s=a.selectAll("g.highlight-group").data((function(t){return t.highlight.map((function(e){return e.axisPosition=t.axisPosition,e.highlightStartMapsTo=t.highlightStartMapsTo,e.labelMapsTo=t.labelMapsTo,e.color=t.color,e.highlightEndMapsTo=t.highlightEndMapsTo,e}))}));s.exit().attr("opacity",0).remove();var u=s.enter().append("g");u.append("rect").attr("class","highlight-bar"),u.append("line").attr("class","highlight-line");var l=u.merge(s);l.attr("class","highlight-group");var c=this;a.each((function(e){var n=e.axisPosition,r=c.services.cartesianScales.getMainXScale(),i=c.services.cartesianScales.getMainYScale(),o=r.range(),a=o[0],s=o[1],u=i.range(),l=u[0],h=u[1],f=c.services.cartesianScales,p=f.getOrientation(),d=function(t){return f.getDomainValue(t)},v=function(t){return f.getRangeValue(t)},g=Rd(d,v,p),m=g[0],y=g[1],_=eb(this);n===B.TOP||n===B.BOTTOM?_.selectAll("rect.highlight-bar").transition().call((function(e){return c.services.transitions.setupTransition({transition:e,name:"highlight-bar-update",animate:t})})).attr("y",Math.max(h+c.highlightStrokeWidth,0)).attr("height",Math.max(l-2*c.highlightStrokeWidth,0)).attr("x",(function(t){var e=t.highlightStartMapsTo,n=dA(t,["highlightStartMapsTo"]);return m(n[e])})).attr("width",(function(t){var e=t.highlightStartMapsTo,n=t.highlightEndMapsTo,r=dA(t,["highlightStartMapsTo","highlightEndMapsTo"]);return Math.max(m(r[n])-m(r[e]),0)})).style("stroke",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})).style("stroke-dasharray","2, 2").attr("stroke-width",c.highlightStrokeWidth+"px").style("fill-opacity",.1).style("fill",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})):_.selectAll("rect.highlight-bar").transition().call((function(e){return c.services.transitions.setupTransition({transition:e,name:"highlight-bar-update",animate:t})})).attr("x",a).attr("width",Math.max(s-a,0)).attr("y",(function(t){var e=t.highlightEndMapsTo,n=dA(t,["highlightEndMapsTo"]);return y(n[e])})).attr("height",(function(t){var e=t.highlightStartMapsTo,n=t.highlightEndMapsTo,r=dA(t,["highlightStartMapsTo","highlightEndMapsTo"]);return Math.max(y(r[e])-y(r[n]),0)})).style("stroke",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null})).style("stroke-dasharray","2, 2").attr("stroke-width",c.highlightStrokeWidth+"px").style("fill-opacity",.1).style("fill",(function(t){var e=t.color,n=t.labelMapsTo,r=dA(t,["color","labelMapsTo"]);return e&&e.scale[r[n]]?e.scale[r[n]]:null}))}))},e}(DS);const gA=Math.PI,mA=2*gA,yA=1e-6,_A=mA-yA;function bA(t){this._+=t[0];for(let e=1,n=t.length;e<n;++e)this._+=arguments[e]+t[e]}function wA(t){let e=Math.floor(t);if(!(e>=0))throw new Error("invalid digits: "+t);if(e>15)return bA;const n=10**e;return function(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=Math.round(arguments[e]*n)/n+t[e]}}class OA{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==t?bA:wA(t)}moveTo(t,e){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,e){this._append`L${this._x1=+t},${this._y1=+e}`}quadraticCurveTo(t,e,n,r){this._append`Q${+t},${+e},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(t,e,n,r,i,o){this._append`C${+t},${+e},${+n},${+r},${this._x1=+i},${this._y1=+o}`}arcTo(t,e,n,r,i){if(t=+t,e=+e,n=+n,r=+r,i=+i,i<0)throw new Error("negative radius: "+i);let o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,h=l*l+c*c;if(null===this._x1)this._append`M${this._x1=t},${this._y1=e}`;else if(h>yA)if(Math.abs(c*s-u*l)>yA&&i){let f=n-o,p=r-a,d=s*s+u*u,v=f*f+p*p,g=Math.sqrt(d),m=Math.sqrt(h),y=i*Math.tan((gA-Math.acos((d+h-v)/(2*g*m)))/2),_=y/m,b=y/g;Math.abs(_-1)>yA&&this._append`L${t+_*l},${e+_*c}`,this._append`A${i},${i},0,0,${+(c*f>l*p)},${this._x1=t+b*s},${this._y1=e+b*u}`}else this._append`L${this._x1=t},${this._y1=e}`;else;}arc(t,e,n,r,i,o){if(t=+t,e=+e,n=+n,o=!!o,n<0)throw new Error("negative radius: "+n);let a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,h=o?r-i:i-r;null===this._x1?this._append`M${u},${l}`:(Math.abs(this._x1-u)>yA||Math.abs(this._y1-l)>yA)&&this._append`L${u},${l}`,n&&(h<0&&(h=h%mA+mA),h>_A?this._append`A${n},${n},0,1,${c},${t-a},${e-s}A${n},${n},0,1,${c},${this._x1=u},${this._y1=l}`:h>yA&&this._append`A${n},${n},0,${+(h>=gA)},${c},${this._x1=t+n*Math.cos(i)},${this._y1=e+n*Math.sin(i)}`)}rect(t,e,n,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}}function xA(){return new OA}function EA(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(null==n)e=null;else{const t=Math.floor(n);if(!(t>=0))throw new RangeError("invalid digits: "+n);e=t}return t},()=>new OA(e)}function TA(t){return t[0]}function SA(t){return t[1]}xA.prototype=OA.prototype;var MA=function(t,e){var n=Dv(!0),r=null,i=xT,o=null,a=EA(s);function s(s){var u,l,c,h=(s=Lv(s)).length,f=!1;for(null==r&&(o=i(c=a())),u=0;u<=h;++u)!(u<h&&n(l=s[u],u,s))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(l,u,s),+e(l,u,s));if(c)return o=null,c+""||null}return t="function"===typeof t?t:void 0===t?TA:Dv(t),e="function"===typeof e?e:void 0===e?SA:Dv(e),s.x=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),s):t},s.y=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),s):e},s.defined=function(t){return arguments.length?(n="function"===typeof t?t:Dv(!!t),s):n},s.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),s):i},s.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),s):r},s},CA=function(t,e,n){var r=null,i=Dv(!0),o=null,a=xT,s=null,u=EA(l);function l(l){var c,h,f,p,d,v=(l=Lv(l)).length,g=!1,m=new Array(v),y=new Array(v);for(null==o&&(s=a(d=u())),c=0;c<=v;++c){if(!(c<v&&i(p=l[c],c,l))===g)if(g=!g)h=c,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=c-1;f>=h;--f)s.point(m[f],y[f]);s.lineEnd(),s.areaEnd()}g&&(m[c]=+t(p,c,l),y[c]=+e(p,c,l),s.point(r?+r(p,c,l):m[c],n?+n(p,c,l):y[c]))}if(d)return s=null,d+""||null}function c(){return MA().defined(i).curve(a).context(o)}return t="function"===typeof t?t:void 0===t?TA:Dv(+t),e="function"===typeof e?e:Dv(void 0===e?0:+e),n="function"===typeof n?n:void 0===n?SA:Dv(+n),l.x=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),r=null,l):t},l.x0=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),l):t},l.x1=function(t){return arguments.length?(r=null==t?null:"function"===typeof t?t:Dv(+t),l):r},l.y=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),n=null,l):e},l.y0=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),l):e},l.y1=function(t){return arguments.length?(n=null==t?null:"function"===typeof t?t:Dv(+t),l):n},l.lineX0=l.lineY0=function(){return c().x(t).y(e)},l.lineY1=function(){return c().x(t).y(n)},l.lineX1=function(){return c().x(r).y(e)},l.defined=function(t){return arguments.length?(i="function"===typeof t?t:Dv(!!t),l):i},l.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),l):a},l.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),l):o},l},AA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="area",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.area").transition("legend-hover-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-area"})})).attr("opacity",(function(t){return t.name!==n.datum()["name"]?vt.opacity.unselected:vt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.area").transition("legend-mouseout-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-area"})})).attr("opacity",vt.opacity.selected)},e}return AA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=[0,0],o=this.services.cartesianScales,a=o.getOrientation(),s=CA().curve(this.services.curves.getD3Curve()).defined((function(t,e){var n=o.getRangeIdentifier(),r=t[n];return null!==r&&void 0!==r})),u=this.model.getGroupedData(this.configs.groups),l=Dd(r,"bounds"),c=l&&u&&1===u.length;!c&&l&&console.warn("Bounds can only be shown when having 1 single datagroup, you've supplied "+u.length);var h=0,f=function(t,e){!1===Dd(r,"axes",t,"includeZero")&&e[0]>0&&e[1]>0&&(h=e[0])},p=function(t,e){return c?o.getBoundedScaledValues(t,e)[0]:o.getRangeValue(h)},d=function(t,e){return c?o.getBoundedScaledValues(t,e)[1]:o.getRangeValue(t,e)};a===H.VERTICAL?(i=o.getMainYScale().domain(),f(o.getMainYAxisPosition(),i),s.x((function(t,e){return o.getDomainValue(t,e)})).y0((function(t,e){return p(t,e)})).y1((function(t,e){return d(t,e)}))):(i=o.getMainXScale().domain(),f(o.getMainXAxisPosition(),i),s.x0((function(t,e){return p(t,e)})).x1((function(t,e){return d(t,e)})).y((function(t,e){return o.getDomainValue(t,e)})));var v=Dd(r,"color","gradient","enabled"),g=u&&1===u.length&&v;u.length>1&&v&&console.error("Gradients can only be enabled when having 1 single dataset");var m=n.selectAll("path.area").data(u,(function(t){return t.name})),y=eb(this.services.domUtils.getMainContainer());if(m.exit().attr("opacity",0).remove(),u.length){if(g){var _=y.select("path."+this.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:u[0].name})).node(),b=void 0;if(_)b=getComputedStyle(_,null).getPropertyValue("stroke");else{var w=Dd(this.model.getOptions(),"color","scale");if(null!==w){var O=Object.keys(w);b=w[O[0]]}}vb.appendOrUpdateLinearGradient({svg:this.parent,id:this.services.domUtils.generateElementIDString(u[0].name.replace(" ","")+"_"+this.gradient_id),x1:"0%",x2:"0%",y1:"0%",y2:"100%",stops:vb.getStops(i,b)})}else this.parent.selectAll("defs linearGradient").empty()||this.parent.selectAll("defs linearGradient").each((function(){this.parentNode.remove()}));var x=this,E=m.enter().append("path");g?E.merge(m).style("fill",(function(t){return"url(#"+e.services.domUtils.generateElementIDString(t.name.replace(" ","")+"_"+e.gradient_id)+")"})).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.name,originalClassName:"area"})})).attr("d",(function(t){var e=t.data;return s(e)})):(E.attr("opacity",0).merge(m).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"area"})})).style("fill",(function(t){return x.model.getFillColor(t.name)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"area-update-enter",animate:t})})).attr("opacity",c?1:vt.opacity.selected).attr("d",(function(t){var e=t.data;return s(e)})),c&&E.attr("fill-opacity",vt.opacity.selected).style("stroke",(function(t){return x.model.getStrokeColor(t.name)})).style("stroke-dasharray","2, 2").attr("stroke-width","0.7px"))}},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),DA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="area-stacked",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("path.area").transition("legend-hover-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-area"})})).attr("opacity",(function(t){return Dd(t,0,i)!==n.datum().name?vt.opacity.unselected:vt.opacity.selected}))},e.handleLegendMouseOut=function(){e.parent.selectAll("path.area").transition("legend-mouseout-area").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-area"})})).attr("opacity",vt.opacity.selected)},e}return DA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this,i=this.getOptions(),o=i.data.groupMapsTo,s=Object.keys(i.axes).some((function(t){return i.axes[t].percentage})),u=this.model.getStackedData({percentage:s,groups:this.configs.groups}),l=Dd(u,0,0),c=this.services.cartesianScales.getDomainAxisPosition({firstDatum:l}),h=this.services.cartesianScales.getRangeAxisPosition({firstDatum:l}),f=this.services.cartesianScales.getScaleByPosition(h),p=n.selectAll("path.area").data(u,(function(t){return Dd(t,0,o)}));this.areaGenerator=CA().x((function(t,n){return e.services.cartesianScales.getValueThroughAxisPosition(c,t.data.sharedStackKey,n)})).y0((function(t){return f(t[0])})).y1((function(t){return f(t[1])})).curve(this.services.curves.getD3Curve()),p.exit().attr("opacity",0).remove();var d=p.enter().append("path").attr("opacity",0);d.merge(p).data(u,(function(t){return Dd(t,0,o)})).attr("class","area").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:Dd(t,0,o),originalClassName:"area"})})).style("fill",(function(t){return r.model.getFillColor(Dd(t,0,o))})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","area").attr("aria-label",(function(t){return Dd(t,0,o)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"area-update-enter",animate:t})})).attr("opacity",vt.opacity.selected).attr("d",this.areaGenerator)},e}(DS),PA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RA=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return PA(e,t),e.prototype.getBarWidth=function(t){var e=this.getOptions();if(e.bars.width)return e.bars.width;var n=this.model.getDisplayData().length,r=this.services.cartesianScales.getMainXScale(),i=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width;if(!r.step){var o=Dd(e,"bars","spacingFactor");return Math.min(e.bars.maxWidth,i*o/n)}return Math.min(e.bars.maxWidth,r.step()/2)},e.prototype.isOutsideZoomedDomain=function(t,e){var n=this.model.getDisplayData().length;if(n<=1)return!1;var r=this.model.get("zoomDomain");if(void 0!==r){var i=this.services.cartesianScales.getDomainScale();return t<i(r[0])||e>i(r[1])}return!1},e}(DS),IA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="simple-bar",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-simple-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-simple-bar"})})).attr("opacity",1)},e}return IA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getComponentContainer({withinChartClip:!0}),o=this.model.getDisplayData(this.configs.groups),s=this.services.cartesianScales.getOrientation(),u=i.selectAll("path.bar").data(o,(function(t){return t[r]}));u.exit().attr("opacity",0).remove();var l=u.enter().append("path").attr("opacity",0);l.merge(u).classed("bar",!0).attr("width",this.getBarWidth.bind(this)).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[r],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[r])})).attr("d",(function(t,n){var r,i,o=e.services.cartesianScales.getRangeIdentifier(),a=e.getBarWidth(),u=t[o],l=e.services.cartesianScales.getDomainValue(t,n)-a/2,c=l+a;if(Array.isArray(u)&&2===u.length)r=e.services.cartesianScales.getRangeValue(u[0]),i=e.services.cartesianScales.getRangeValue(u[1],n);else{var h=e.services.cartesianScales.getRangeScale(),f=h.domain()[0];r=e.services.cartesianScales.getRangeValue(Math.max(0,f)),i=e.services.cartesianScales.getRangeValue(t,n)}var p=Math.abs(i-r);if(0!==p&&p<2&&(i=u>0&&s===H.VERTICAL||u<0&&s===H.HORIZONTAL?r-2:r+2),!e.isOutsideZoomedDomain(l,c))return Pd({x0:l,x1:c,y0:r,y1:i},s)})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,data:[n]})})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(RA),jA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),BA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grouped-bar",e.renderType=I.SVG,e.padding=5,e.defaultStepFactor=70,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return jA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.model.getDisplayData(this.configs.groups),r=this.getOptions(),i=r.data.groupMapsTo;this.setGroupScale();var o=this.getComponentContainer({withinChartClip:!0}),s=xd(n.map((function(t){var n=e.services.cartesianScales.getDomainIdentifier(t);return t[n]&&"function"===typeof t[n].toString?t[n].toString():t[n]}))),u=o.selectAll("g.bars").data(s,(function(t){return t}));u.exit().attr("opacity",0).remove();var l=u.enter().append("g").classed("bars",!0).attr("role",a.GROUP).attr("data-name","bars"),c=l.merge(u);c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-group-update-enter",animate:t})})).attr("transform",(function(t,n){var r=e.services.cartesianScales.getDomainValue(t,n),i=r-e.getGroupWidth()/2;return e.services.cartesianScales.getOrientation()===H.VERTICAL?"translate("+i+", 0)":"translate(0, "+i+")"}));var h=c.selectAll("path.bar").data((function(t){return e.getDataCorrespondingToLabel(t)}),(function(t){return t[i]}));h.exit().attr("opacity",0).remove();var f=h.enter().append("path").attr("opacity",0);f.merge(h).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[i],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[i])})).attr("d",(function(t,n){var r=e.groupScale(t[i]),o=e.getBarWidth(),a=r,s=r+o,u=e.services.cartesianScales.getRangeAxisPosition({datum:t}),l=e.services.cartesianScales.getValueThroughAxisPosition(u,0),c=e.services.cartesianScales.getRangeValue(t),h=e.services.cartesianScales.getDomainValue(t,n)-o/2,f=h+o;if(!e.isOutsideZoomedDomain(h,f))return Pd({x0:a,x1:s,y0:l,y1:c},e.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,data:[n]})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.getDataCorrespondingToLabel=function(t){var e=this,n=this.model.getDisplayData(this.configs.groups);return n.filter((function(n){var r=e.services.cartesianScales.getDomainIdentifier(n);return n[r].toString()===t}))},e.prototype.getGroupWidth=function(){var t=this.model.getGroupedData(this.configs.groups),e=this.getTotalGroupPadding();return this.getBarWidth()*t.length+e},e.prototype.getDomainScaleStep=function(){var t=this.services.cartesianScales.getDomainScale(),e=this.model.getGroupedData(this.configs.groups),n=this.defaultStepFactor;if("function"===typeof t.step)n=t.step();else if(e.length>0){var r=e.find((function(t){var e;return(null===(e=t.data)||void 0===e?void 0:e.length)>1}));if(r){var i=this.services.cartesianScales.getDomainIdentifier(r.data[0]);n=Math.abs(t(r.data[1][i])-t(r.data[0][i]))}}return n},e.prototype.getTotalGroupPadding=function(){var t=this.model.getGroupedData(this.configs.groups);if(1===t.length)return 0;var e=Math.min(5,this.getDomainScaleStep()/this.defaultStepFactor*5);return e*(t.length-1)},e.prototype.getBarWidth=function(){var t=this.getOptions(),e=Dd(t,"bars","width"),n=Dd(t,"bars","maxWidth");if(null!==e&&(null===n||e<=n))return e;var r=this.model.getGroupedData(this.configs.groups),i=r.length,o=this.getTotalGroupPadding();return Math.min(n,(this.getDomainScaleStep()-o)/i)},e.prototype.setGroupScale=function(){var t=this.model.getActiveDataGroupNames(this.configs.groups);this.groupScale=kE().domain(t).rangeRound([0,this.getGroupWidth()])},e}(RA),UA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),VA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="stacked-bar",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.model.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return UA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.model.getStackedData({groups:this.configs.groups,divergent:!0}),s=this.model.getActiveDataGroupNames(),u=n.selectAll("g.bars").data(o,(function(t){return Dd(t,0,i)}));u.exit().attr("opacity",0).remove(),u.enter().append("g").classed("bars",!0).attr("role",a.GROUP).attr("data-name","bars");var l=n.selectAll("g.bars").selectAll("path.bar").data((function(t){return t}),(function(t){return t.data.sharedStackKey}));l.exit().remove(),l.enter().append("path").merge(l).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[i],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[i])})).attr("d",(function(t,n){var i=t.data.sharedStackKey,o=e.getBarWidth(),a=e.services.cartesianScales.getDomainValue(i,n)-o/2,u=a+o,l=e.services.cartesianScales.getRangeValue(t[0],n),c=e.services.cartesianScales.getRangeValue(t[1],n);if(!e.isOutsideZoomedDomain(a,u)){if(Math.abs(c-l)>0&&Math.abs(c-l)>r.bars.dividerSize){var h=t[0]<0&&t[1]<=0;h&&s.length>1?e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=0===t[1]?2:1:c-=1:h||(e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=1:c-=1)}return Pd({x0:a,x1:u,y0:l,y1:c},e.services.cartesianScales.getOrientation())}})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t[1]-t[0]})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this;this.parent.selectAll("path.bar").on("mouseover",(function(t,r){var i,o=eb(this);o.classed("hovered",!0),n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:t,element:o,datum:r});var a=n.model.getDisplayData(n.configs.groups),s=a.find((function(t){var i=n.services.cartesianScales.getDomainIdentifier(t),o=n.services.cartesianScales.getRangeIdentifier(t);return t[o]===r.data[r[e]]&&t[i].toString()===r.data.sharedStackKey&&t[e]===r[e]}));if(void 0===s){var u=n.services.cartesianScales.getDomainIdentifier(),l=n.services.cartesianScales.getRangeIdentifier();i={},i[u]=r.data.sharedStackKey,i[l]=r.data[r[e]],i[e]=r[e],s=i}n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:o,data:[s]})})).on("mousemove",(function(t,e){var r=eb(this);n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:t,element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var r=eb(this);r.classed("hovered",!1),n.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:t,element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.getBarWidth=function(){var t=this.getOptions();if(Dd(t,"bars","width"))return t.bars.width;var e=this.services.cartesianScales.getMainXScale(),n=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,r=this.model.getStackKeys().length,i=Dd(t,"bars","spacingFactor");return e.step?Math.min(t.bars.maxWidth,e.step()/2):Math.min(t.bars.maxWidth,n*i/r)},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(RA),HA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),GA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="boxplot",e.renderType=I.SVG,e}return HA(e,t),e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.model.getDataGroupNames(),s=this.services.cartesianScales.getMainXScale(),u=this.services.cartesianScales.getMainYScale(),l=s.range(),c=l[0],h=l[1],f=u.range(),p=f[0],d=f[1],v=h-c,g=p-d;if(0!==v){var m=this.services.cartesianScales,y=m.getOrientation(),_=y===H.VERTICAL,b=Rd((function(t,n){return e.services.cartesianScales.getDomainValue(t,n)}),(function(t,n){return e.services.cartesianScales.getRangeValue(t,n)}),y),w=b[0],O=b[1],x=Math.floor((_?v:g)/o.length),E=Math.min(x/2,16),T=this.model.getBoxplotData(),S=n.selectAll(".box-group").data(T);S.exit().remove();var M=S.enter().append("g").attr("class","box-group"),C=S.merge(M);M.append("path").merge(S.select("path.vertical-line.start")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"vertical-line start"})})).attr("stroke-width",bt.strokeWidth.default).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-verticalstartline",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i]),n=e,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.quartiles.q_25);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.vertical-line.end")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"vertical-line end"})})).attr("stroke-width",bt.strokeWidth.default).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-verticalendline",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i]),n=e,r=m.getRangeValue(t.whiskers.max),o=m.getRangeValue(t.quartiles.q_75);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.box")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],originalClassName:"box"})})).attr("fill-opacity",bt.box.opacity.default).attr("stroke-width",bt.strokeWidth.default).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","box").attr("aria-label",(function(t){return t[i]})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-quartiles",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(Math[_?"max":"min"](t.quartiles.q_75,t.quartiles.q_25)),o=r+Math.abs(m.getRangeValue(t.quartiles.q_75)-m.getRangeValue(t.quartiles.q_25));return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.highlight-area")).attr("class","highlight-area").attr("opacity",0).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.whiskers.max);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.whisker.start")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"whisker start"})})).attr("stroke-width",bt.strokeWidth.thicker).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-startingwhisker",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/4,n=e+E/2,r=m.getRangeValue(t.whiskers.min),o=m.getRangeValue(t.whiskers.min);return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.median")).attr("fill","none").attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"median"})})).attr("stroke-width",2).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-median",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/2,n=e+E,r=m.getRangeValue(t.quartiles.q_50),o=r;return Pd({x0:e,x1:n,y0:r,y1:o},y)})),M.append("path").merge(S.select("path.whisker.end")).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.STROKE],originalClassName:"whisker end"})})).attr("stroke-width",bt.strokeWidth.thicker).attr("fill","none").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-endingwhisker",animate:t})})).attr("d",(function(t){var e=m.getDomainValue(t[i])-E/4,n=e+E/2,r=m.getRangeValue(t.whiskers.max),o=m.getRangeValue(t.whiskers.max);return Pd({x0:e,x1:n,y0:r,y1:o},y)}));var A=C.selectAll("circle.outlier").data((function(t){return t.outliers.map((function(e){var n;return n={min:t.whiskers.min,max:t.whiskers.max},n[i]=t[i],n.value=e,n}))}));A.exit().remove();var L=A.enter().append("circle");A.merge(L).attr("r",bt.circle.radius).attr("class",(function(){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],originalClassName:"outlier"})})).attr("fill-opacity",bt.circle.opacity.default).attr("cx",w).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"boxplot-update-circles",animate:t})})).attr("cy",O),this.addBoxEventListeners(),this.addCircleEventListeners()}},e.prototype.addBoxEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo;this.parent.selectAll("path.highlight-area").on("mouseover",(function(r,i){var o=eb(this),a=eb(this.parentNode);a.select("path.box").classed("hovered",!0).attr("fill-opacity",bt.box.opacity.hovered),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:e.tooltip.groupLabel,value:i[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP]})},{label:"Minimum",value:i.whiskers.min},{label:"Q1",value:i.quartiles.q_25},{label:"Median",value:i.quartiles.q_50},{label:"Q3",value:i.quartiles.q_75},{label:"Maximum",value:i.whiskers.max},{label:"IQR",value:i.quartiles.q_75-i.quartiles.q_25}]}),t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEOVER,{event:r,element:o,datum:i})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Boxplot.BOX_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=eb(this.parentNode);i.select("path.box").classed("hovered",!1).attr("fill-opacity",bt.box.opacity.default),t.services.events.dispatchEvent(ft.Boxplot.BOX_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.addCircleEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo,r=this.services.cartesianScales.getRangeIdentifier();this.parent.selectAll("circle").on("mouseover",(function(i,o){var a=eb(this);a.classed("hovered",!0).attr("fill-opacity",bt.circle.opacity.hovered).classed("unfilled",!1),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:e.tooltip.groupLabel,value:o[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP]})},{label:"Outlier",value:o[r]}]}),t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEOVER,{event:i,element:a,datum:o})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1).attr("fill-opacity",bt.circle.opacity.default),t.services.events.dispatchEvent(ft.Boxplot.OUTLIER_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e}(DS),zA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter",e.renderType=I.SVG,e.handleChartHolderOnHover=function(t){e.parent.selectAll("circle.dot").transition("chart-holder-hover-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"chart-holder-hover-scatter"})})).attr("opacity",1)},e.handleChartHolderOnMouseOut=function(t){e.parent.selectAll("circle.dot").transition("chart-holder-mouseout-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"chart-holder-mouseout-scatter"})})).attr("opacity",0)},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("circle.dot").transition("legend-hover-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-scatter"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.dot").transition("legend-mouseout-scatter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-scatter"})})).attr("opacity",1)},e}return zA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut);var e=this.configs.fadeInOnChartHolderMouseover;e&&(t.addEventListener(ft.Chart.MOUSEOVER,this.handleChartHolderOnHover),t.addEventListener(ft.Chart.MOUSEOUT,this.handleChartHolderOnMouseOut))},e.prototype.filterBasedOnZoomDomain=function(t){var e=this.services.cartesianScales.getDomainIdentifier(t),n=this.model.get("zoomDomain");return void 0!==n?t.filter((function(t){return t[e].getTime()>=n[0].getTime()&&t[e].getTime()<=n[1].getTime()})):t},e.prototype.getScatterData=function(){var t,e=this,n=this.getOptions(),r=this.configs.stacked;if(r){var i=Object.keys(n.axes).some((function(t){return n.axes[t].percentage}));t=this.model.getStackedData({groups:this.configs.groups,percentage:i})}else t=this.model.getDisplayData(this.configs.groups).filter((function(t){var n=e.services.cartesianScales.getRangeIdentifier(t);return void 0!==t[n]&&null!==t[n]}));return this.filterBasedOnZoomDomain(t)},e.prototype.render=function(t){var e=Dd(this.getOptions(),"points","enabled")||Dd(this.getOptions(),"bubble","enabled");if(e){var n=this.getComponentContainer({withinChartClip:!0}),r=this.getOptions(),i=r.data.groupMapsTo,o=this.services.cartesianScales.getDomainIdentifier(),a=n.selectAll("circle.dot").data(this.getScatterData(),(function(t){return t[i]+"-"+t[o]}));a.exit().attr("opacity",0).remove();var s=a.enter().append("circle").classed("dot",!0).attr("opacity",0),u=s.merge(a);this.styleCircles(u,t),this.addEventListeners()}},e.prototype.isDatapointThresholdAnomaly=function(t,e){var n=this,r=this.configs.handleThresholds;if(!r)return!1;var i=this.services.cartesianScales,o=i.getOrientation(),a=Rd(this.services.cartesianScales.getHighestDomainThreshold(),this.services.cartesianScales.getHighestRangeThreshold(),o),s=a[0],u=a[1],l=Rd((function(t,e){return n.services.cartesianScales.getDomainValue(t,e)}),(function(t,e){return n.services.cartesianScales.getRangeValue(t,e)}),o),c=l[0],h=l[1],f=c(t,e),p=h(t,e);return u&&s?p<=u.scaleValue&&f>=s.scaleValue:u?p<=u.scaleValue:s?f>=s.scaleValue:void 0},e.prototype.styleCircles=function(t,e){var n=this,r=this.getOptions(),i=r.points,o=i.filled,s=i.fillOpacity,u=this.services,l=u.cartesianScales,c=(u.transitions,r.data.groupMapsTo),h=function(t,e){return l.getDomainValue(t,e)},f=function(t,e){return l.getRangeValue(t,e)},p=Rd(h,f,l.getOrientation()),d=p[0],v=p[1],g=this.configs.fadeInOnChartHolderMouseover;t.raise().classed("dot",!0).attr("class",(function(t){var e=l.getDomainIdentifier(t),r=n.model.getIsFilled(t[c],t[e],t,o),i=r?[j.FILL,j.STROKE]:[j.STROKE];return n.model.getColorClassName({classNameTypes:i,dataGroupName:t[c],originalClassName:"dot"})})).classed("threshold-anomaly",(function(t,e){return n.isDatapointThresholdAnomaly(t,e)})).classed("filled",(function(t){var e=l.getDomainIdentifier(t);return n.model.getIsFilled(t[c],t[e],t,o)})).classed("unfilled",(function(t){var e=l.getDomainIdentifier(t);return!n.model.getIsFilled(t[c],t[e],t,o)})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"scatter-update-enter",animate:e})})).attr("cx",d).attr("cy",v).attr("r",r.points.radius).style("fill",(function(t){var e=l.getDomainIdentifier(t);if(n.model.getIsFilled(t[c],t[e],t,o))return n.model.getFillColor(t[c],t[e],t)})).style("stroke",(function(t){var e=l.getDomainIdentifier(t);return n.model.getStrokeColor(t[c],t[e],t)})).attr("fill-opacity",o?s:1).attr("opacity",g?0:1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","point").attr("aria-label",(function(t){var e=l.getRangeIdentifier(t);return t[e]})),this.addEventListeners()},e.prototype.getTooltipAdditionalItems=function(t){return null},e.prototype.addEventListeners=function(){var t=this,e=t.getOptions().data.groupMapsTo;this.parent.selectAll("circle").on("mouseover",(function(n,r){var i=eb(this);i.classed("hovered",!0).attr("class",(function(n){return t.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:n[e],originalClassName:i.attr("class")})})).style("fill",(function(n){var r=t.services.cartesianScales.getDomainIdentifier(n);return t.model.getFillColor(n[e],n[r],n)})).classed("unfilled",!1),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n,hoveredElement:i,data:[r],additionalItems:t.getTooltipAdditionalItems(r)}),t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEOVER,{event:n,element:i,datum:r})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Scatter.SCATTER_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(n,r){var i=eb(this);if(i.classed("hovered",!1),!t.configs.filled){var o=t.getOptions().points.filled,a=t.services.cartesianScales.getDomainIdentifier(r),s=t.model.getIsFilled(r[e],r[a],r,o);i.classed("unfilled",!s).style("fill",(function(n){return s||o?t.model.getFillColor(n[e],n[a],n):null}))}t.services.events.dispatchEvent(ft.Scatter.SCATTER_MOUSEOUT,{event:n,element:i,datum:r}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e.prototype.destroy=function(){this.parent.selectAll("circle").on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),t.removeEventListener(ft.Chart.MOUSEOVER,this.handleChartHolderOnHover),t.removeEventListener(ft.Chart.MOUSEOUT,this.handleChartHolderOnMouseOut)},e}(DS),WA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bubble",e.renderType=I.SVG,e}return WA(e,t),e.prototype.getRadiusScale=function(t){var e=this.getOptions(),n=e.bubble.radiusMapsTo,r=t.data(),i=r.map((function(t){return t[n]})).filter((function(t){return t})),o=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),a=i.length>0,s=a?Xv(i):[1,1];return BE().domain(s).range(a?e.bubble.radiusRange(o,r):[4,4])},e.prototype.styleCircles=function(t,e){var n=this,r=this.getOptions(),i=r.bubble.radiusMapsTo,o=this.getRadiusScale(t),s=r.data.groupMapsTo,u=this.services.cartesianScales,l=function(t,e){return u.getDomainValue(t,e)},c=function(t,e){return u.getRangeValue(t,e)},h=Rd(l,c,u.getOrientation()),f=h[0],p=h[1];t.raise().classed("dot",!0).attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){var e=u.getRangeIdentifier(t);return t[e]})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"bubble-update-enter",animate:e})})).attr("cx",f).attr("cy",p).attr("r",(function(t){return o(t[i]||1)})).attr("class",(function(t){return n.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t[s],originalClassName:"dot"})})).style("fill",(function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return n.model.getFillColor(t[s],t[e],t)})).style("stroke",(function(t){var e=n.services.cartesianScales.getDomainIdentifier(t);return n.model.getStrokeColor(t[s],t[e],t)})).attr("fill-opacity",r.bubble.fillOpacity).attr("opacity",1)},e.prototype.getTooltipAdditionalItems=function(t){var e=Dd(this.getOptions(),"bubble");return[{label:Dd(e,"radiusLabel"),value:t[Dd(e,"radiusMapsTo")]}]},e}(FA),$A=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bullet",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-simple-bar"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-simple-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-simple-bar"})})).attr("opacity",1)},e}return $A(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getComponentContainer({withinChartClip:!0}),o=this.model.getDisplayData(this.configs.groups),s=this.services.cartesianScales.getRangeScale(),u=this.services.cartesianScales.getRangeIdentifier(),l=s.range(),c=l[0],h=l[1],f=s.domain(),p=(f[0],f[1]),d=function(){var n=[];o.forEach((function(t){t.ranges?t.ranges.forEach((function(e,r){null!==e&&void 0!==e&&e<p&&n.push({datum:t,value:e,order:r+1})})):n.push({datum:t,order:1})}));var a=sb.appendOrSelect(i,"g.range-boxes").selectAll("path.range-box").data(n,(function(t){return t[r]+"-"+t.order}));a.exit().attr("opacity",0).remove();var s=a.enter().append("path").attr("opacity",0);s.merge(a).attr("class",(function(t){return"range-box order-"+t.order})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-range-box-update-enter",animate:t})})).attr("d",(function(t,n){var r,i,o,a,s=16;return 1===t.order?(r=e.services.cartesianScales.getDomainValue(t.datum,n)-s/2,i=r+s,o=h-2,a=c+1):(r=e.services.cartesianScales.getDomainValue(t.datum,n)-s/2,i=r+s,o=e.services.cartesianScales.getRangeValue(t.value,n),a=h),Pd({x0:r,x1:i,y0:o,y1:a},e.services.cartesianScales.getOrientation())})).attr("opacity",1)},v=function(){var n=sb.appendOrSelect(i,"g.bars").selectAll("path.bar").data(o,(function(t){return t[r]}));n.exit().attr("opacity",0).remove();var s=n.enter().append("path").attr("opacity",0);s.merge(n).classed("bar",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[r],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[r])})).attr("d",(function(t,n){var r=8,i=e.services.cartesianScales.getDomainValue(t,n)-r/2,o=i+r,a=e.services.cartesianScales.getRangeValue(0)+1,s=e.services.cartesianScales.getRangeValue(t,n);return Pd({x0:i,x1:o,y0:a,y1:s},e.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value}))},g=function(){var n=sb.appendOrSelect(i,"g.markers").selectAll("path.marker").data(o.filter((function(t){return null!==Dd(t,"marker")})),(function(t){return t[r]}));n.exit().attr("opacity",0).remove();var a=n.enter().append("path").attr("opacity",0);a.merge(n).classed("marker",!0).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-marker-update-enter",animate:t})})).attr("d",(function(t,n){var r=24,i=e.services.cartesianScales.getDomainValue(t,n)-r/2,o=i+r,a=e.services.cartesianScales.getRangeValue(t.marker,n),s=a;return Pd({x0:i,x1:o,y0:a,y1:s},e.services.cartesianScales.getOrientation())})).attr("opacity",1)},m=function(){var n=[];o.filter((function(t){return null!==Dd(t,"marker")})).forEach((function(t){var e=t.marker,r=t[u];n=n.concat([{datum:t,value:.25*e,barValue:r},{datum:t,value:.5*e,barValue:r},{datum:t,value:.75*e,barValue:r}])}));var a=sb.appendOrSelect(i,"g.quartiles").selectAll("path.quartile").data(n,(function(t){return t[r]}));a.exit().attr("opacity",0).remove();var s=a.enter().append("path").attr("opacity",0);s.merge(a).attr("class",(function(t){return"quartile "+(t.value<=t.barValue?"over-bar":"")})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"bullet-quartile-update-enter",animate:t})})).attr("d",(function(t,n){var r=t.datum,i=t.value,o=4;r.ranges&&-1!==r.ranges.indexOf(i)&&(o=8);var a=e.services.cartesianScales.getDomainValue(r,n)-o/2,s=a+o,u=e.services.cartesianScales.getRangeValue(i,n),l=u;return Pd({x0:a,x1:s,y0:u,y1:l},e.services.cartesianScales.getOrientation())})).attr("opacity",1)};d(),v(),g(),m(),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this,e=this.getOptions(),n=e.data.groupMapsTo,r=this.services.cartesianScales.getRangeIdentifier();this.parent.selectAll("path.bar").on("mouseover",(function(i,o){var a=eb(this);a.classed("hovered",!0),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOVER,{event:i,element:a,datum:o});var s=Dd(e,"bullet","performanceAreaTitles"),u=t.model.getMatchingRangeIndexForDatapoint(o);t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:e.tooltip.groupLabel||"Group",value:o[n],class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:o[n]})},{label:"Value",value:o[r]},{label:"Target",value:o.marker},{label:"Percentage",value:Math.floor(o[r]/o.marker*100)+"%"},{label:"Performance",value:s[u]}]})})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Bar.BAR_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),t.services.events.dispatchEvent(ft.Bar.BAR_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),ZA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="histogram",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("path.bar").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t[i]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return ZA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer(),r=this.model.getOptions(),i=r.groupIdentifier,o=r.data.groupMapsTo,s=this.model.getBinnedStackedData(),u=this.services.cartesianScales.getMainXScale(),l=n.selectAll("g.bars").data(s,(function(t){return tl(t,"0."+o)}));l.exit().attr("opacity",0).remove(),l.enter().append("g").classed("bars",!0).attr("role",a.GROUP);var c=n.selectAll("g.bars").selectAll("path.bar").data((function(t){return t}));c.exit().remove(),c.enter().append("path").merge(c).classed("bar",!0).attr(i,(function(t,e){return e})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"histogram-bar-update-enter",animate:t})})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[o],originalClassName:"bar"})})).style("fill",(function(t){return e.model.getFillColor(t[o])})).attr("d",(function(t,n){var i=tl(t,"data");if(i){var o=u(i.x1)-u(i.x0)-1,a=e.services.cartesianScales.getDomainValue(i.x0,n),s=a+o,l=e.services.cartesianScales.getRangeValue(t[0],n),c=e.services.cartesianScales.getRangeValue(t[1],n);return Math.abs(c-l)>0&&Math.abs(c-l)>r.bars.dividerSize&&(e.services.cartesianScales.getOrientation()===H.VERTICAL?c+=1:c-=1),Pd({x0:a,x1:s,y0:l,y1:c},e.services.cartesianScales.getOrientation())}})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return Dd(t,"data",t[o])})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.model.getOptions(),e=t.data.groupMapsTo,n=this;this.parent.selectAll("path.bar").on("mouseover",(function(r,i){var o=eb(this);o.classed("hovered",!0);var a=parseFloat(tl(i,"data.x0")),s=parseFloat(tl(i,"data.x1")),u=n.services.cartesianScales.getRangeAxisPosition(),l=n.services.cartesianScales.getScaleLabel(u);n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:tl(t,"bins.rangeLabel")||"Range",value:a+" – "+s},{label:t.tooltip.groupLabel||"Group",value:i[e],class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:i[e]})},{label:l,value:tl(i,"data."+i[e])}]})})).on("mousemove",(function(t,e){n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("mouseout",(function(t,e){var r=eb(this);r.classed("hovered",!1),n.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),KA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.line").transition("legend-hover-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-line"})})).attr("opacity",(function(t){return t.name!==n.datum()["name"]?xt.opacity.unselected:xt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.line").transition("legend-mouseout-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-line"})})).attr("opacity",xt.opacity.selected)},e}return KA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=this.services,i=r.cartesianScales,o=r.curves,s=function(t,e){return i.getDomainValue(t,e)},u=function(t,e){return i.getRangeValue(t,e)},l=Rd(s,u,i.getOrientation()),c=l[0],h=l[1],f=this.getOptions(),p=MA().x(c).y(h).curve(o.getD3Curve()).defined((function(t,e){var n=i.getRangeIdentifier(t),r=t[n];return null!==r&&void 0!==r})),d=[];if(this.configs.stacked){var v=Object.keys(f.axes).some((function(t){return f.axes[t].percentage})),g=f.data.groupMapsTo,m=this.model.getStackedData({groups:this.configs.groups,percentage:v});d=m.map((function(t){var n=e.services.cartesianScales.getDomainIdentifier(t),r=e.services.cartesianScales.getRangeIdentifier(t);return{name:Dd(t,0,g),data:t.map((function(t){var e;return e={},e[n]=t.data.sharedStackKey,e[g]=t[g],e[r]=t[1],e})),hidden:!rf(t,(function(t){return t[0]!==t[1]}))}}))}else d=this.model.getGroupedData(this.configs.groups);var y=n.selectAll("path.line").data(d,(function(t){return t.name}));y.exit().attr("opacity",0).remove();var _=y.enter().append("path").classed("line",!0).attr("opacity",0);_.merge(y).data(d,(function(t){return t.name})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t.name,originalClassName:"line"})})).style("stroke",(function(t){return e.model.getStrokeColor(t.name)})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","line").attr("aria-label",(function(t){var n=t.data;return n.map((function(t){var n=e.services.cartesianScales.getRangeIdentifier(t);return t[n]})).join(",")})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"line-update-enter",animate:t})})).attr("opacity",(function(t){return t.hidden?0:1})).attr("d",(function(t){var e=t.data;return p(e)}))},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e}(DS),JA=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="lollipop",e.renderType=I.SVG,e.handleScatterOnHover=function(t){var n=t.detail,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("line.line").attr("stroke-width",(function(t){return t[i]!==n.datum[i]?xt.weight.unselected:xt.weight.selected}))},e.handleScatterOnMouseOut=function(t){e.parent.selectAll("line.line").attr("stroke-width",xt.weight.unselected)},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions(),i=r.data.groupMapsTo;e.parent.selectAll("line.line").transition("legend-hover-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-line"})})).attr("opacity",(function(t){return t[i]!==n.datum()["name"]?xt.opacity.unselected:xt.opacity.selected}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("line.line").transition("legend-mouseout-line").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-line"})})).attr("opacity",xt.opacity.selected)},e}return JA(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this,n=this.getComponentContainer({withinChartClip:!0}),r=this.model.getOptions(),i=r.data.groupMapsTo,o=this.services.cartesianScales,a=o.getMainXScale(),s=o.getMainYScale(),u=o.getDomainIdentifier(),l=function(t,e){return o.getDomainValue(t,e)},c=function(t,e){return o.getRangeValue(t,e)},h=o.getOrientation(),f=Rd(l,c,h),p=f[0],d=f[1],v=n.selectAll("line.line").data(this.getScatterData(),(function(t){return t[i]+"-"+t[u]}));v.exit().attr("opacity",0).remove();var g=v.enter().append("line").attr("opacity",0),m=g.merge(v).classed("line",!0).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t[i],originalClassName:"line"})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"lollipop-line-update-enter",animate:t})})).style("stroke",(function(t){return e.model.getFillColor(t[i],t[u],t)})).attr("opacity",1);h===H.HORIZONTAL?m.attr("y1",d).attr("y2",d).attr("x1",a.range()[0]).attr("x2",(function(t,e){return p(t,e)-r.points.radius})):m.attr("x1",p).attr("x2",p).attr("y1",s.range()[0]).attr("y2",(function(t,e){return d(t,e)+r.points.radius})),this.addScatterPointEventListeners()},e.prototype.addScatterPointEventListeners=function(){this.services.events.addEventListener(ft.Scatter.SCATTER_MOUSEOVER,this.handleScatterOnHover),this.services.events.addEventListener(ft.Scatter.SCATTER_MOUSEOUT,this.handleScatterOnMouseOut)},e.prototype.destroy=function(){var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),t.removeEventListener(ft.Scatter.SCATTER_MOUSEOVER,this.handleScatterOnHover),t.removeEventListener(ft.Scatter.SCATTER_MOUSEOUT,this.handleScatterOnMouseOut)},e}(FA),eL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),nL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter-stacked",e.renderType=I.SVG,e}return eL(e,t),e.prototype.render=function(t){var e=this,n=Dd(this.getOptions(),"points","enabled");if(n){var r=this.getComponentContainer({withinChartClip:!0}),i=this.getOptions(),o=i.data.groupMapsTo,s=Object.keys(i.axes).some((function(t){return i.axes[t].percentage})),u=this.model.getStackedData({groups:this.configs.groups,percentage:s}),l=r.selectAll("g.dots").data(u,(function(t){return Dd(t,0,o)}));l.exit().attr("opacity",0).remove();var c=l.enter().append("g").classed("dots",!0).attr("role",a.GROUP),h=c.merge(l).selectAll("circle.dot").data((function(t){return t}));h.exit().attr("opacity",0).remove();var f=h.enter().append("circle").classed("dot",!0).attr("opacity",0),p=f.merge(h).datum((function(t){var n,r=t[o],i=e.services.cartesianScales.getDomainIdentifier(t),a=e.services.cartesianScales.getRangeIdentifier(t);return n={},n[o]=r,n[i]=t["data"]["sharedStackKey"],n[a]=t[1],n}));this.styleCircles(p,t),this.addEventListeners()}},e.prototype.getTooltipData=function(t,e){var n=this,r=this.getOptions(),i=r.data.groupMapsTo,o=Object.keys(r.axes).some((function(t){return r.axes[t].percentage})),a=this.model.getStackedData({groups:this.configs.groups,percentage:o}),s=[];return a.forEach((function(r,a){r.forEach((function(r,u){var l,c=r[i],h=r["data"]["sharedStackKey"],f=r["data"][c],p=r[1],d=n.services.cartesianScales.getDomainIdentifier(r),v=n.services.cartesianScales.getRangeIdentifier(r);null!==f&&void 0!==f&&t===n.services.cartesianScales.getDomainValue(h)&&e===n.services.cartesianScales.getRangeValue(p)&&(o&&(f=n.model.getStackedData({groups:n.configs.groups})[a][u]["data"][c]),null!==f&&s.push((l={},l[i]=c,l[d]=h,l[v]=f,l)))}))})),this.model.getDisplayData(this.configs.groups).filter((function(t){var e=n.services.cartesianScales.getDomainIdentifier(t),r=n.services.cartesianScales.getRangeIdentifier(t);return void 0!==s.find((function(n){return n[i]==t[i]&&n[e]==t[e]&&n[r]==t[r]}))}))},e}(FA);function rL(t){return t.innerRadius}function iL(t){return t.outerRadius}function oL(t){return t.startAngle}function aL(t){return t.endAngle}function sL(t){return t&&t.padAngle}function uL(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,h=s-o,f=h*u-c*l;if(!(f*f<XT))return f=(c*(e-o)-h*(t-i))/f,[t+f*u,e+f*l]}function lL(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/ZT(s*s+u*u),c=l*u,h=-l*s,f=t+c,p=e+h,d=n+c,v=r+h,g=(f+d)/2,m=(p+v)/2,y=d-f,_=v-p,b=y*y+_*_,w=i-o,O=f*v-d*p,x=(_<0?-1:1)*ZT(qT(0,w*w*b-O*O)),E=(O*_-y*x)/b,T=(-O*y-_*x)/b,S=(O*_+y*x)/b,M=(-O*y+_*x)/b,C=E-g,A=T-m,L=S-g,D=M-m;return C*C+A*A>L*L+D*D&&(E=S,T=M),{cx:E,cy:T,x01:-c,y01:-h,x11:E*(i/w-1),y11:T*(i/w-1)}}var cL=function(){var t=rL,e=iL,n=Dv(0),r=null,i=oL,o=aL,a=sL,s=null,u=EA(l);function l(){var l,c,h=+t.apply(this,arguments),f=+e.apply(this,arguments),p=i.apply(this,arguments)-QT,d=o.apply(this,arguments)-QT,v=zT(d-p),g=d>p;if(s||(s=l=u()),f<h&&(c=f,f=h,h=c),f>XT)if(v>JT-XT)s.moveTo(f*WT(p),f*YT(p)),s.arc(0,0,f,p,d,!g),h>XT&&(s.moveTo(h*WT(d),h*YT(d)),s.arc(0,0,h,d,p,g));else{var m,y,_=p,b=d,w=p,O=d,x=v,E=v,T=a.apply(this,arguments)/2,S=T>XT&&(r?+r.apply(this,arguments):ZT(h*h+f*f)),M=$T(zT(f-h)/2,+n.apply(this,arguments)),C=M,A=M;if(S>XT){var L=eS(S/h*YT(T)),D=eS(S/f*YT(T));(x-=2*L)>XT?(L*=g?1:-1,w+=L,O-=L):(x=0,w=O=(p+d)/2),(E-=2*D)>XT?(D*=g?1:-1,_+=D,b-=D):(E=0,_=b=(p+d)/2)}var k=f*WT(_),P=f*YT(_),R=h*WT(O),I=h*YT(O);if(M>XT){var N,j=f*WT(b),B=f*YT(b),U=h*WT(w),V=h*YT(w);if(v<KT)if(N=uL(k,P,U,V,j,B,R,I)){var H=k-N[0],G=P-N[1],z=j-N[0],F=B-N[1],W=1/YT(tS((H*z+G*F)/(ZT(H*H+G*G)*ZT(z*z+F*F)))/2),q=ZT(N[0]*N[0]+N[1]*N[1]);C=$T(M,(h-q)/(W-1)),A=$T(M,(f-q)/(W+1))}else C=A=0}E>XT?A>XT?(m=lL(U,V,k,P,f,A,g),y=lL(j,B,R,I,f,A,g),s.moveTo(m.cx+m.x01,m.cy+m.y01),A<M?s.arc(m.cx,m.cy,A,FT(m.y01,m.x01),FT(y.y01,y.x01),!g):(s.arc(m.cx,m.cy,A,FT(m.y01,m.x01),FT(m.y11,m.x11),!g),s.arc(0,0,f,FT(m.cy+m.y11,m.cx+m.x11),FT(y.cy+y.y11,y.cx+y.x11),!g),s.arc(y.cx,y.cy,A,FT(y.y11,y.x11),FT(y.y01,y.x01),!g))):(s.moveTo(k,P),s.arc(0,0,f,_,b,!g)):s.moveTo(k,P),h>XT&&x>XT?C>XT?(m=lL(R,I,j,B,h,-C,g),y=lL(k,P,U,V,h,-C,g),s.lineTo(m.cx+m.x01,m.cy+m.y01),C<M?s.arc(m.cx,m.cy,C,FT(m.y01,m.x01),FT(y.y01,y.x01),!g):(s.arc(m.cx,m.cy,C,FT(m.y01,m.x01),FT(m.y11,m.x11),!g),s.arc(0,0,h,FT(m.cy+m.y11,m.cx+m.x11),FT(y.cy+y.y11,y.cx+y.x11),g),s.arc(y.cx,y.cy,C,FT(y.y11,y.x11),FT(y.y01,y.x01),!g))):s.arc(0,0,h,O,w,g):s.lineTo(R,I)}else s.moveTo(0,0);if(s.closePath(),l)return s=null,l+""||null}return l.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-KT/2;return[WT(r)*n,YT(r)*n]},l.innerRadius=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),l):t},l.outerRadius=function(t){return arguments.length?(e="function"===typeof t?t:Dv(+t),l):e},l.cornerRadius=function(t){return arguments.length?(n="function"===typeof t?t:Dv(+t),l):n},l.padRadius=function(t){return arguments.length?(r=null==t?null:"function"===typeof t?t:Dv(+t),l):r},l.startAngle=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),l):i},l.endAngle=function(t){return arguments.length?(o="function"===typeof t?t:Dv(+t),l):o},l.padAngle=function(t){return arguments.length?(a="function"===typeof t?t:Dv(+t),l):a},l.context=function(t){return arguments.length?(s=null==t?null:t,l):s},l},hL=function(t,e){return e<t?-1:e>t?1:e>=t?0:NaN},fL=function(t){return t},pL=function(){var t=fL,e=hL,n=null,r=Dv(0),i=Dv(JT),o=Dv(0);function a(a){var s,u,l,c,h,f=(a=Lv(a)).length,p=0,d=new Array(f),v=new Array(f),g=+r.apply(this,arguments),m=Math.min(JT,Math.max(-JT,i.apply(this,arguments)-g)),y=Math.min(Math.abs(m)/f,o.apply(this,arguments)),_=y*(m<0?-1:1);for(s=0;s<f;++s)(h=v[d[s]=s]=+t(a[s],s,a))>0&&(p+=h);for(null!=e?d.sort((function(t,n){return e(v[t],v[n])})):null!=n&&d.sort((function(t,e){return n(a[t],a[e])})),s=0,l=p?(m-f*_)/p:0;s<f;++s,g=c)u=d[s],h=v[u],c=g+(h>0?h*l:0)+_,v[u]={data:a[u],index:s,value:h,startAngle:g,endAngle:c,padAngle:y};return v}return a.value=function(e){return arguments.length?(t="function"===typeof e?e:Dv(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"===typeof t?t:Dv(+t),a):o},a},dL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();function vL(t,e){var n=this,r=Nx(this._current,t);return function(t){return n._current=r(t),e(n._current)}}var gL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="pie",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("path.slice").transition("legend-hover-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-bar"})})).attr("opacity",(function(t){return t.data[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.slice").transition("legend-mouseout-bar").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-bar"})})).attr("opacity",1)},e}return dL(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.getInnerRadius=function(){return Tt.innerRadius},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this,r=this.getComponentContainer(),i=this.getOptions(),o=i.data.groupMapsTo,s=i.pie.valueMapsTo,u=this.model.getDisplayData().filter((function(t){return t[s]>0})),l=this.computeRadius();this.arc=cL().innerRadius(this.getInnerRadius()).outerRadius(l),this.hoverArc=cL().innerRadius(this.getInnerRadius()).outerRadius(l+Tt.hoverArc.outerRadiusOffset);var c=pL().value((function(t){return t[s]})).sort(Dd(i,"pie","sortFunction")).padAngle(Tt.padAngle),h=c(u),f=sb.appendOrSelect(r,"g.slices").attr("role",a.GROUP).attr("data-name","slices"),p=f.selectAll("path.slice").data(h,(function(t){return t.data[o]}));p.exit().attr("opacity",0).remove();var d=p.enter().append("path").classed("slice",!0).attr("opacity",0),v=d.merge(p).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.data[o],originalClassName:"slice"})})).style("fill",(function(t){return n.model.getFillColor(t.data[o])})).attr("d",this.arc);v.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"pie_slice_enter_update",animate:t})})).attr("opacity",1).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","slice").attr("aria-label",(function(t){return t[s]+", "+Cd(t.data[s],u,s)+"%"})).attrTween("d",(function(t){return vL.bind(this)(t,n.arc)}));var g=i.pie.labels.enabled,m=g?h.filter((function(t){return t.data[s]>0})):[],y=sb.appendOrSelect(r,"g.labels").attr("role",a.GROUP).attr("data-name","labels"),_=y.selectAll("text.pie-label").data(m,(function(t){return t.data[o]}));_.exit().attr("opacity",0).remove();var b=_.enter().append("text").classed("pie-label",!0),w=[];b.merge(_).style("text-anchor","middle").text((function(t){return i.pie.labels.formatter?i.pie.labels.formatter(t):Cd(t.data[s],u,s)+"%"})).datum((function(t){var e=l+7,n=(t.endAngle-t.startAngle)/2+t.startAngle,r=n/Math.PI*180,i=this.getComputedTextLength();return t.textOffsetX=i/2,t.textOffsetY=r>90&&r<270?10:0,t.xPosition=(t.textOffsetX+e)*Math.sin(n),t.yPosition=(t.textOffsetY+e)*-Math.cos(n),t})).attr("transform",(function(t,e){var n=m.length,r=(t.endAngle-t.startAngle)*(180/Math.PI);if(e>=n-2&&r<Tt.callout.minSliceDegree){var i=void 0,o=void 0;return t.index===n-1?(i=t.xPosition+Tt.callout.offsetX+Tt.callout.textMargin+t.textOffsetX,o=t.yPosition-Tt.callout.offsetY,t.direction=X.RIGHT,w.push(t)):(i=t.xPosition-Tt.callout.offsetX-t.textOffsetX-Tt.callout.textMargin,o=t.yPosition-Tt.callout.offsetY,t.direction=X.LEFT,w.push(t)),"translate("+i+", "+o+")"}return"translate("+t.xPosition+", "+t.yPosition+")"})),this.renderCallouts(w);var O=Dd(i,"donut")?"donut":"pie",x=Dd(i,O,"alignment"),E=sb.getSVGElementSize(this.getParent(),{useAttrs:!0}).width,T=g?Tt.xOffset:0,S=g?Tt.yOffset:0,M=l+T;x===F.CENTER?M=E/2:x===F.RIGHT&&(M=E-l-Tt.xOffset);var C=l+S;w.length>0&&(C+=Tt.yOffsetCallout),r.attr("x",M+7).attr("y",C),this.addEventListeners()},e.prototype.renderCallouts=function(t){var e=sb.appendOrSelect(this.getComponentContainer(),"g.callouts").attr("role",a.GROUP).attr("data-name","callouts"),n=e.selectAll("g.callout").data(t);n.exit().remove();var r=n.enter().append("g").classed("callout",!0).attr("role",a.GROUP).attr("aria-roledescription","label callout");r.merge(n).datum((function(t){var e=t.xPosition,n=t.yPosition,r=t.direction;return r===X.RIGHT?(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e+Tt.callout.offsetX,y:n-Tt.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x-Tt.callout.horizontalLineLength):(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e-Tt.callout.offsetX,y:n-Tt.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x+Tt.callout.horizontalLineLength),t}));var i=r.append("line").classed("vertical-line",!0);i.merge(e.selectAll("line.vertical-line")).datum((function(t){return eb(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.startPos.x})).attr("y1",(function(t){return t.startPos.y})).attr("x2",(function(t){return t.intersectPointX})).attr("y2",(function(t){return t.endPos.y}));var o=r.append("line").classed("horizontal-line",!0);o.merge(e.selectAll("line.horizontal-line")).datum((function(t){return eb(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.intersectPointX})).attr("y1",(function(t){return t.endPos.y})).attr("x2",(function(t){return t.endPos.x})).attr("y2",(function(t){return t.endPos.y}))},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.slice").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0).transition("pie_slice_mouseover").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"pie_slice_mouseover"})})).attr("d",t.hoverArc),t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEOVER,{event:e,element:eb(this),datum:n});var i=t.getOptions().data.groupMapsTo,o=t.getOptions().pie.valueMapsTo;t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:[{label:n.data[i],value:n.data[o]}]})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Pie.SLICE_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1).transition("pie_slice_mouseout").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"pie_slice_mouseout"})})).attr("d",t.arc),t.services.events.dispatchEvent(ft.Pie.SLICE_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e.prototype.computeRadius=function(){var t=sb.getSVGElementSize(this.parent,{useAttrs:!0}),e=t.width,n=t.height,r=this.getOptions(),i=Math.min(e,n)/2,o=r.pie.labels.enabled;return o?i+Tt.radiusOffset:i},e}(DS),mL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),yL="4,10 8,6 12,10",_L="12,6 8,10 4,6",bL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="gauge",e.renderType=I.SVG,e}return mL(e,t),e.prototype.getValue=function(){var t,e,n=this.model.getData(),r=(e=null===(t=n.find((function(t){return"value"===t.group})))||void 0===t?void 0:t.value,null!==e&&void 0!==e?e:null);return r},e.prototype.getValueRatio=function(){var t=aa(this.getValue(),0,100);return t/100},e.prototype.getDelta=function(){var t,e,n=this.model.getData(),r=(e=null===(t=n.find((function(t){return"delta"===t.group})))||void 0===t?void 0:t.value,null!==e&&void 0!==e?e:null);return r},e.prototype.getArcRatio=function(){var t=this.getOptions(),e=Dd(t,"gauge","type"),n=e===tt.FULL?1:.5;return n},e.prototype.getArcSize=function(){return this.getArcRatio()*Math.PI*2},e.prototype.getStartAngle=function(){var t=this.getArcSize();return t===2*Math.PI?0:-t/2},e.prototype.getArrow=function(t){var e=this.getOptions(),n=Dd(e,"gauge","deltaArrow","direction");switch(n){case et.UP:return yL;case et.DOWN:return _L;default:return t>0?yL:_L}},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer().attr("width","100%").attr("height","100%"),r=this.getOptions(),i=this.getValue(),o=this.getValueRatio(),s=this.getArcSize(),u=this.getStartAngle(),l=o*s,c=u+l,h=u+s,f=this.computeRadius(),p=this.getInnerRadius();this.backgroundArc=cL().innerRadius(p).outerRadius(f).startAngle(c).endAngle(h),this.arc=cL().innerRadius(p).outerRadius(f).startAngle(u).endAngle(c),sb.appendOrSelect(n,"path.arc-background").attr("d",this.backgroundArc);var d=n.selectAll("path.arc-foreground").data([i]),v=d.enter().append("path");v.merge(d).attr("class",this.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:"value",originalClassName:"arc-foreground"})).style("fill",(function(t){return Dd(e.getOptions(),"color","scale","value")})).attr("d",this.arc).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","value").attr("aria-label",(function(t){return t})),this.drawValueNumber(),this.drawDelta(),d.exit().remove();var g=Dd(r,"gauge","alignment"),m=sb.getSVGElementSize(this.getParent(),{useAttrs:!0}).width,y=f;g===F.CENTER?y=m/2:g===F.RIGHT&&(y=m-f),n.attr("x",y).attr("y",f),this.addEventListeners()},e.prototype.drawValueNumber=function(){var t=this.getComponentContainer(),e=this.getOptions(),n=Dd(e,"gauge","type"),r=this.getValue(),i=this.getDelta(),o=this.computeRadius(),a=Dd(e,"gauge","valueFontSize"),s=Dd(e,"gauge","deltaFontSize"),u=Dd(e,"gauge","numberSpacing"),l=Dd(e,"gauge","showPercentageSymbol"),c=0;n!==tt.FULL||i?n===tt.SEMI&&i&&(c=-(s(o)+u)):c=s(o);var h=sb.appendOrSelect(t,"g.gauge-numbers").attr("transform","translate(0, "+c+")"),f=a(o),p=sb.appendOrSelect(h,"g.gauge-value-number"),d=Dd(e,"gauge","numberFormatter"),v=p.selectAll("text.gauge-value-number").data([r]);v.enter().append("text").attr("class","gauge-value-number").merge(v).style("font-size",f+"px").attr("text-anchor","middle").text((function(t){return d(t)}));var g=sb.getSVGElementSize(sb.appendOrSelect(t,"text.gauge-value-number"),{useBBox:!0}).width,m=f/2,y=l?"%":"",_=sb.appendOrSelect(p,"text.gauge-value-symbol").style("font-size",m+"px").attr("x",g/2).text(y),b=sb.getSVGElementSize(_,{useBBox:!0}),w=b.width,O=b.height;_.attr("y","-"+O/2+"px"),p.attr("transform","translate(-"+w/2+", 0)")},e.prototype.drawDelta=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=this.getDelta();if(r){var i=this.computeRadius(),o=r?Dd(n,"gauge","deltaFontSize"):function(){return 0},a=r?Dd(n,"gauge","numberFormatter"):function(){return null},s=Dd(n,"gauge","deltaArrow","size"),u=Dd(n,"gauge","numberSpacing"),l=Dd(n,"gauge","showPercentageSymbol"),c=sb.appendOrSelect(e,"g.gauge-numbers"),h=(g=sb.appendOrSelect(c,"g.gauge-delta").attr("transform","translate(0, "+(o(i)+u)+")"),sb.appendOrSelect(g,"text.gauge-delta-number")),f=l?"%":"";h.data(null===r?[]:[r]),h.enter().append("text").classed("gauge-delta-number",!0).merge(h).attr("text-anchor","middle").style("font-size",o(i)+"px").text((function(t){return""+a(t)+f}));var p=sb.getSVGElementSize(sb.appendOrSelect(e,".gauge-delta-number"),{useBBox:!0}).width,d=Dd(n,"gauge","deltaArrow","enabled"),v=g.selectAll("svg.gauge-delta-arrow").data(null!==r&&d?[r]:[]);v.enter().append("svg").merge(v).attr("class","gauge-delta-arrow").attr("x",-s(i)-p/2).attr("y",-s(i)/2-.35*o(i)).attr("width",s(i)).attr("height",s(i)).attr("viewBox","0 0 16 16").each((function(){var e=eb(this);sb.appendOrSelect(e,"rect.gauge-delta-arrow-backdrop").attr("width","16").attr("height","16").attr("fill","none");var i=Dd(n,"gauge","status");sb.appendOrSelect(e,"polygon.gauge-delta-arrow").attr("class",null!==i?"gauge-delta-arrow status--"+i:"").attr("points",t.getArrow(r))})),v.exit().remove(),h.exit().remove()}else{var g=e.select("g.gauge-delta");g.empty()||g.remove()}},e.prototype.getInnerRadius=function(){var t=this.computeRadius(),e=Dd(this.getOptions(),"gauge","arcWidth");return t-e},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.arc-foreground").on("mouseover",(function(e,n){t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEOVER,{event:e,element:eb(this),datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEMOVE,{event:e,element:r,datum:n})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Gauge.ARC_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Gauge.ARC_MOUSEOUT,{event:e,element:r,datum:n})}))},e.prototype.computeRadius=function(){var t=this.getOptions(),e=Dd(t,"gauge","type"),n=sb.getSVGElementSize(this.parent,{useAttrs:!0}),r=n.width,i=n.height,o=e===tt.SEMI?Math.min(r/2,i):Math.min(r/2,i/2);return o},e}(DS),wL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),OL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="donut",e.renderType=I.SVG,e}return wL(e,t),e.prototype.render=function(e){var n=this;void 0===e&&(e=!0),t.prototype.render.call(this,e);var r=this;if(this.model.isDataEmpty())this.getComponentContainer().select("g.center").remove();else{var i=sb.appendOrSelect(this.getComponentContainer(),"g.center"),o=this.getOptions(),a=this.computeRadius(),s=Dd(o,"donut","center","label");sb.appendOrSelect(i,"text.donut-figure").attr("text-anchor","middle").style("dominant-baseline",(function(){return null===s||""===s?"central":"initial"})).style("font-size",(function(){return o.donut.center.numberFontSize(a)})).transition().call((function(t){return n.services.transitions.setupTransition({transition:t,name:"donut-figure-enter-update",animate:e})})).tween("text",(function(){return r.centerNumberTween(eb(this))})),null!==s&&""!==s&&sb.appendOrSelect(i,"text.donut-title").attr("text-anchor","middle").style("font-size",(function(){return o.donut.center.titleFontSize(a)})).attr("y",o.donut.center.titleYPosition(a)).text(s)}},e.prototype.getInnerRadius=function(){var t=this.computeRadius();return t*(3/4)},e.prototype.centerNumberTween=function(t){var e=this.getOptions(),n=Dd(e,"donut","center","number");null===n&&(n=this.model.getDisplayData().reduce((function(t,n){return t+n[e.pie.valueMapsTo]}),0));var r,i=parseInt(t.text().replace(/[, ]+/g,""),10)||0;r=i%1===0&&n%1===0?jx:Ax;var o=r(i,n);return function(n){var r=e.donut.center.numberFormatter;t.text(r(o(n)))}},e}(gL);const xL=t=>+t;var EL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),TL=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="skeleton",e}return EL(e,t),e.prototype.render=function(){var t=Dd(this.getOptions(),"data","loading");t?this.renderSkeleton(t):this.removeSkeleton()},e.prototype.renderSkeleton=function(t){if(this.configs.skeleton===K.GRID)this.renderGridSkeleton(t);else if(this.configs.skeleton===K.VERT_OR_HORIZ)this.renderVertOrHorizSkeleton(t);else if(this.configs.skeleton===K.PIE)this.renderPieSkeleton(t);else{if(this.configs.skeleton!==K.DONUT)throw new Error('"'+this.configs.skeleton+'" is not a valid Skeleton type.');this.renderDonutSkeleton(t)}},e.prototype.renderGridSkeleton=function(t){this.setScales(),this.drawBackdrop(t),this.drawXGrid(t),this.drawYGrid(t),t&&this.setShimmerEffect("shimmer-lines")},e.prototype.renderVertOrHorizSkeleton=function(t){var e=this.services.cartesianScales.getOrientation();this.setScales(),this.drawBackdrop(t),e===H.VERTICAL&&this.drawYGrid(t),e===H.HORIZONTAL&&this.drawXGrid(t),this.setShimmerEffect("shimmer-lines")},e.prototype.renderPieSkeleton=function(t){var e=this.computeOuterRadius(),n=0;this.drawRing(e,n,t),t&&this.setShimmerEffect("shimmer-areas")},e.prototype.renderDonutSkeleton=function(t){var e=this.computeOuterRadius(),n=this.computeInnerRadius();this.drawRing(e,n,t),t&&this.setShimmerEffect("shimmer-areas")},e.prototype.setScales=function(){var t=this.services.cartesianScales.getMainXScale().range(),e=this.services.cartesianScales.getMainYScale().range();this.xScale=BE().domain([0,1]).range(t),this.yScale=BE().domain([0,1]).range(e)},e.prototype.drawBackdrop=function(t){var e=this.parent,n=sb.getSVGElementSize(e,{useAttrs:!0}),r=n.width,i=n.height;this.backdrop=sb.appendOrSelect(e,"svg.chart-skeleton.DAII").attr("width",r).attr("height",i);var o=sb.appendOrSelect(this.backdrop,"rect.chart-skeleton-backdrop");o.attr("width","100%").attr("height","100%");var a=this.xScale.range(),s=a[0],u=(a[1],this.yScale.range()),l=(u[0],u[1]);this.backdrop.merge(o).attr("x",s).attr("y",l),o.classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawXGrid=function(t){var e=this.backdrop.attr("width"),n=Dd(this.getOptions(),"grid","x","numberOfTicks"),r=this.xScale.ticks(n).map((function(t){return t*e})),i=sb.appendOrSelect(this.backdrop,"g.x.skeleton"),o=i.selectAll("line").data(r);o.enter().append("line").merge(o).attr("x1",(function(t){return t})).attr("x2",(function(t){return t})).attr("y1",0).attr("y2","100%"),i.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawYGrid=function(t){var e=this.backdrop.attr("height"),n=this.backdrop.attr("width"),r=Dd(this.getOptions(),"grid","y","numberOfTicks"),i=this.xScale.ticks(r).map((function(t){return t*e})),o=sb.appendOrSelect(this.backdrop,"g.y.skeleton"),a=o.selectAll("line").data(i);a.enter().append("line").merge(a).attr("x1",0).attr("x2",n).attr("y1",(function(t){return t})).attr("y2",(function(t){return t})),o.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.drawRing=function(t,e,n){void 0===n&&(n=!0);var r=this.parent,i=sb.getSVGElementSize(r,{useAttrs:!0}),o=i.width,a=i.height,s=sb.appendOrSelect(r,"svg.chart-skeleton").attr("width",o).attr("height",a),u=0===e?"pie":"donut",l=Dd(this.getOptions(),u,"alignment");sb.appendOrSelect(s,"rect.chart-skeleton-area-container").attr("width",o).attr("height",a).attr("fill","none");var c=cL().innerRadius(e).outerRadius(t).startAngle(0).endAngle(2*Math.PI),h=t+Math.abs(Tt.radiusOffset),f=t+(Math.min(o,a)-2*t)/2,p=sb.appendOrSelect(s,"path").attr("class","skeleton-area-shape").attr("transform","translate("+h+", "+f+")").attr("d",c).classed("shimmer-effect-areas",n).classed("empty-state-areas",!n).style("fill",n?"url(#"+this.services.domUtils.generateElementIDString("shimmer-areas")+")":null),d=t+Tt.xOffset;l===F.CENTER?d=o/2:l===F.RIGHT&&(d=o-t-Tt.xOffset);var v=t+Tt.yOffset;p.attr("transform","translate("+d+", "+v+")")},e.prototype.computeOuterRadius=function(){var t=sb.getSVGElementSize(this.parent,{useAttrs:!0}),e=t.width,n=t.height,r=Math.min(e,n)/2;return r+Tt.radiusOffset},e.prototype.computeInnerRadius=function(){return this.computeOuterRadius()*(3/4)},e.prototype.setShimmerEffect=function(t){var e=2e3,n=1e3,r=.2,i="stop-bg-shimmer",o="stop-shimmer",a=this.parent.select(".chart-skeleton"),s=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,u=0,l=s,c=sb.appendOrSelect(a,"defs").lower(),h=sb.appendOrSelect(c,"linearGradient").attr("id",this.services.domUtils.generateElementIDString(t)).attr("class",t).attr("x1",u-3*r*s).attr("x2",l).attr("y1",0).attr("y2",0).attr("gradientUnits","userSpaceOnUse").attr("gradientTransform","translate(0, 0)"),f='\n\t\t\t<stop class="'+i+'" offset="'+u+'"></stop>\n\t\t\t<stop class="'+o+'" offset="'+(u+r)+'"></stop>\n\t\t\t<stop class="'+i+'" offset="'+(u+2*r)+'"></stop>\n\t\t';function p(){h.attr("gradientTransform","translate("+(u-3*r*s)+", 0)").transition().duration(e).delay(n).ease(xL).attr("gradientTransform","translate("+(l+3*r*s)+", 0)").on("end",p)}h.html(f),p()},e.prototype.removeSkeleton=function(){var t=this.parent.select(".chart-skeleton");t.remove()},e}(DS),SL=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ML=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="skeleton-lines",e}return SL(e,t),e.prototype.render=function(){var e=Dd(this.getOptions(),"data","loading"),n=!Dd(this.getOptions(),"grid","x","enabled")&&!Dd(this.getOptions(),"grid","y","enabled")&&!Dd(this.getOptions(),"axes","bottom","visible")&&!Dd(this.getOptions(),"axes","left","visible");e&&!n?t.prototype.renderGridSkeleton.call(this,e):e&&n?this.renderSparklineSkeleton(e):this.removeSkeleton()},e.prototype.renderSparklineSkeleton=function(t){this.setScales(),this.drawBackdrop(t),this.drawSparkline(t),this.updateBackdropStyle(),t&&this.setShimmerEffect("shimmer-lines")},e.prototype.drawSparkline=function(t){var e=this.backdrop.attr("width"),n=[100],r=sb.appendOrSelect(this.backdrop,"g.y.skeleton"),i=r.selectAll("line").data(n);i.enter().append("line").merge(i).attr("x1",0).attr("x2",e).attr("y1",(function(t){return t})).attr("y2",(function(t){return t})),r.selectAll("line").classed("shimmer-effect-lines",t).classed("empty-state-lines",!t).style("stroke",t?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.updateBackdropStyle=function(){var t=this.parent;this.backdrop=sb.appendOrSelect(t,"svg.chart-skeleton.DAII");var e=sb.appendOrSelect(this.backdrop,"rect.chart-skeleton-backdrop");e.classed("shimmer-effect-lines",!1).classed("shimmer-effect-sparkline",!0).style("stroke",null)},e}(TL);function CL(t){var e=0,n=t.children,r=n&&n.length;if(r)while(--r>=0)e+=n[r].value;else e=1;t.value=e}var AL=function(){return this.eachAfter(CL)},LL=function(t,e){let n=-1;for(const r of this)t.call(e,r,++n,this);return this},DL=function(t,e){var n,r,i=this,o=[i],a=-1;while(i=o.pop())if(t.call(e,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},kL=function(t,e){var n,r,i,o=this,a=[o],s=[],u=-1;while(o=a.pop())if(s.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);while(o=s.pop())t.call(e,o,++u,this);return this},PL=function(t,e){let n=-1;for(const r of this)if(t.call(e,r,++n,this))return r},RL=function(t){return this.eachAfter((function(e){var n=+t(e.data)||0,r=e.children,i=r&&r.length;while(--i>=0)n+=r[i].value;e.value=n}))},IL=function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},NL=function(t){var e=this,n=jL(e,t),r=[e];while(e!==n)e=e.parent,r.push(e);var i=r.length;while(t!==n)r.splice(i,0,t),t=t.parent;return r};function jL(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();while(t===e)i=t,t=n.pop(),e=r.pop();return i}var BL=function(){var t=this,e=[t];while(t=t.parent)e.push(t);return e},UL=function(){return Array.from(this)},VL=function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},HL=function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},GL=function*(){var t,e,n,r,i=this,o=[i];do{t=o.reverse(),o=[];while(i=t.pop())if(yield i,e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n])}while(o.length)};function zL(t,e){t instanceof Map?(t=[void 0,t],void 0===e&&(e=qL)):void 0===e&&(e=WL);var n,r,i,o,a,s=new ZL(t),u=[s];while(n=u.pop())if((i=e(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)u.push(r=i[o]=new ZL(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(YL)}function FL(){return zL(this).eachBefore($L)}function WL(t){return t.children}function qL(t){return Array.isArray(t)?t[1]:null}function $L(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function YL(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function ZL(t){this.data=t,this.depth=this.height=0,this.parent=null}function XL(t,e){return t.parent===e.parent?1:2}function KL(t){return t.reduce(QL,0)/t.length}function QL(t,e){return t+e.x}function JL(t){return 1+t.reduce(tD,0)}function tD(t,e){return Math.max(t,e.y)}function eD(t){var e;while(e=t.children)t=e[0];return t}function nD(t){var e;while(e=t.children)t=e[e.length-1];return t}ZL.prototype=zL.prototype={constructor:ZL,count:AL,each:LL,eachAfter:kL,eachBefore:DL,find:PL,sum:RL,sort:IL,path:NL,ancestors:BL,descendants:UL,leaves:VL,links:HL,copy:FL,[Symbol.iterator]:GL};var rD=function(){var t=XL,e=1,n=1,r=!1;function i(i){var o,a=0;i.eachAfter((function(e){var n=e.children;n?(e.x=KL(n),e.y=JL(n)):(e.x=o?a+=t(e,o):0,e.y=0,o=e)}));var s=eD(i),u=nD(i),l=s.x-t(s,u)/2,c=u.x+t(u,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-l)/(c-l)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i};function iD(t,e){return t.parent===e.parent?1:2}function oD(t){var e=t.children;return e?e[0]:t.t}function aD(t){var e=t.children;return e?e[e.length-1]:t.t}function sD(t,e,n){var r=n/(e.i-t.i);e.c-=r,e.s+=n,t.c+=r,e.z+=n,e.m+=n}function uD(t){var e,n=0,r=0,i=t.children,o=i.length;while(--o>=0)e=i[o],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function lD(t,e,n){return t.a.parent===e.parent?t.a:n}function cD(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}function hD(t){var e,n,r,i,o,a=new cD(t,0),s=[a];while(e=s.pop())if(r=e._.children)for(e.children=new Array(o=r.length),i=o-1;i>=0;--i)s.push(n=e.children[i]=new cD(r[i],i)),n.parent=e;return(a.parent=new cD(null,0)).children=[a],a}cD.prototype=Object.create(ZL.prototype);var fD=function(){var t=iD,e=1,n=1,r=null;function i(i){var s=hD(i);if(s.eachAfter(o),s.parent.m=-s.z,s.eachBefore(a),r)i.eachBefore(u);else{var l=i,c=i,h=i;i.eachBefore((function(t){t.x<l.x&&(l=t),t.x>c.x&&(c=t),t.depth>h.depth&&(h=t)}));var f=l===c?1:t(l,c)/2,p=f-l.x,d=e/(c.x+f+p),v=n/(h.depth||1);i.eachBefore((function(t){t.x=(t.x+p)*d,t.y=t.depth*v}))}return i}function o(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){uD(e);var o=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-o):e.z=o}else i&&(e.z=i.z+t(e._,i._));e.parent.A=s(e,i,e.parent.A||r[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(e,n,r){if(n){var i,o=e,a=e,s=n,u=o.parent.children[0],l=o.m,c=a.m,h=s.m,f=u.m;while(s=aD(s),o=oD(o),s&&o)u=oD(u),a=aD(a),a.a=e,i=s.z+h-o.z-l+t(s._,o._),i>0&&(sD(lD(s,e,r),e,i),l+=i,c+=i),h+=s.m,l+=o.m,f+=u.m,c+=a.m;s&&!aD(a)&&(a.t=s,a.m+=h-c),o&&!oD(u)&&(u.t=o,u.m+=l-f,r=e)}return r}function u(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i};class pD{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e);break}this._x0=t,this._y0=e}}function dD(t){return new pD(t,!0)}function vD(t){return t.source}function gD(t){return t.target}function mD(t){let e=vD,n=gD,r=TA,i=SA,o=null,a=null,s=EA(u);function u(){let u;const l=Av.call(arguments),c=e.apply(this,l),h=n.apply(this,l);if(null==o&&(a=t(u=s())),a.lineStart(),l[0]=c,a.point(+r.apply(this,l),+i.apply(this,l)),l[0]=h,a.point(+r.apply(this,l),+i.apply(this,l)),a.lineEnd(),u)return a=null,u+""||null}return u.source=function(t){return arguments.length?(e=t,u):e},u.target=function(t){return arguments.length?(n=t,u):n},u.x=function(t){return arguments.length?(r="function"===typeof t?t:Dv(+t),u):r},u.y=function(t){return arguments.length?(i="function"===typeof t?t:Dv(+t),u):i},u.context=function(e){return arguments.length?(null==e?o=a=null:a=t(o=e),u):o},u}function yD(){return mD(dD)}var _D=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),bD=6,wD=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="tree",e.renderType=I.SVG,e}return _D(e,t),e.prototype.getLongestLabel=function(t){var e=this,n="";return t.forEach((function(t){var r=t.children?e.getLongestLabel(t.children):"";(r.length>n.length||t.name.length>n.length)&&(n=r.length>t.name.length?r:t.name)})),n},e.prototype.getMockLabelWidth=function(t,e){var n=t.append("text").attr("dy","0.31em").attr("x",0).attr("text-anchor","end").text(e),r=sb.getSVGElementSize(n.node(),{useBBox:!0}).width;return n.remove(),r},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer();n.html("");var r=sb.getSVGElementSize(this.parent,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getOptions(),s=this.model.getDisplayData(),u=Dd(a,"tree","rootTitle")||"Tree",l=this.getMockLabelWidth(n,u),c=this.getLongestLabel(s),h=this.getMockLabelWidth(n,c),f={top:0,right:0,bottom:0,left:l>0?l+bD:30-bD},p=zL({name:u,children:s}),d=10,v=i/6,g=function(t){var r=p.descendants().reverse(),o=p.links(),a=p,s=p;p.eachBefore((function(t){t.x<a.x&&(a=t),t.x>s.x&&(s=t)}));var u=s.x-a.x,l=n.transition().call((function(t){return e.services.transitions.setupTransition({transition:t,name:"tree-update-viewbox",animate:!0})})).attr("viewBox",[-f.left,a.x,i,u]),c=O.selectAll("g").data(r,(function(t){return t.id})),h=e,d=c.enter().append("g").attr("transform",(function(){return"translate("+t.y0+","+t.x0+")"})).attr("class",(function(t){return 0!==t.depth&&t.children&&t.children.length>0?"clickable":null})).on("mouseover",(function(t,e){h.services.events.dispatchEvent(ft.Tree.NODE_MOUSEOVER,{event:t,element:eb(this),datum:e})})).on("click",(function(t,e){0!==e.depth&&(e.children=e.children?null:e._children,g(e)),h.services.events.dispatchEvent(ft.Tree.NODE_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){h.services.events.dispatchEvent(ft.Tree.NODE_MOUSEOUT,{event:t,element:eb(this),datum:e})}));d.append("circle").attr("r",2.5).attr("class",(function(t){return t._children?"parent":"child"})).attr("stroke-width",10),d.append("text").attr("dy","0.31em").attr("x",(function(t){return t._children?-bD:bD})).attr("text-anchor",(function(t){return t._children?"end":"start"})).text((function(t){return t.data.name})).clone(!0).attr("class","text-stroke").lower(),c.merge(d).transition(l).attr("transform",(function(t){return"translate("+t.y+","+t.x+")"})).attr("fill-opacity",1).attr("stroke-opacity",1),c.exit().transition(l).remove().attr("transform",(function(){return"translate("+t.y+","+t.x+")"})).attr("fill-opacity",0).attr("stroke-opacity",0);var v=w.selectAll("path").data(o,(function(t){return t.target.id})),m=v.enter().append("path").attr("d",(function(e){var n={x:t.x0,y:t.y0};return b({source:n,target:n})}));v.merge(m).transition(l).attr("d",b),v.exit().transition(l).remove().attr("d",(function(){var e={x:t.x,y:t.y};return b({source:e,target:e})})),p.eachBefore((function(t){t.x0=t.x,t.y0=t.y}))},m=p.descendants(),y=m[m.length-1].depth,_=Dd(a,"tree","type")===q.DENDROGRAM?rD().size([o,i-h-y*bD-l]):fD().nodeSize([d,v]).size([o,i-h-y*bD-l]),b=yD().x((function(t){return t.y})).y((function(t){return t.x}));p.x0=v/2,p.y0=0,p.descendants().forEach((function(t,e){t.id=e,t._children=t.children})),_(p),n.attr("viewBox",[-f.left,-f.top,i,d]).style("user-select","none");var w=n.append("g").attr("class","links"),O=n.append("g").attr("class","nodes");g(p)}},e}(DS),OD=function(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)},xD=function(t,e,n,r,i){var o,a=t.children,s=-1,u=a.length,l=t.value&&(r-e)/t.value;while(++s<u)o=a[s],o.y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*l},ED=function(t,e,n,r,i){var o,a=t.children,s=-1,u=a.length,l=t.value&&(i-n)/t.value;while(++s<u)o=a[s],o.x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*l},TD=(1+Math.sqrt(5))/2;function SD(t,e,n,r,i,o){var a,s,u,l,c,h,f,p,d,v,g,m=[],y=e.children,_=0,b=0,w=y.length,O=e.value;while(_<w){u=i-n,l=o-r;do{c=y[b++].value}while(!c&&b<w);for(h=f=c,v=Math.max(l/u,u/l)/(O*t),g=c*c*v,d=Math.max(f/g,g/h);b<w;++b){if(c+=s=y[b].value,s<h&&(h=s),s>f&&(f=s),g=c*c*v,p=Math.max(f/g,g/h),p>d){c-=s;break}d=p}m.push(a={value:c,dice:u<l,children:y.slice(_,b)}),a.dice?xD(a,n,r,i,O?r+=l*c/O:o):ED(a,n,r,O?n+=u*c/O:i,o),O-=c,_=b}return m}var MD=function t(e){function n(t,n,r,i,o){SD(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(TD);function CD(t){return null==t?null:AD(t)}function AD(t){if("function"!==typeof t)throw new Error;return t}function LD(){return 0}var DD=function(t){return function(){return t}},kD=function(){var t=MD,e=!1,n=1,r=1,i=[0],o=LD,a=LD,s=LD,u=LD,l=LD;function c(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(h),i=[0],e&&t.eachBefore(OD),t}function h(e){var n=i[e.depth],r=e.x0+n,c=e.y0+n,h=e.x1-n,f=e.y1-n;h<r&&(r=h=(r+h)/2),f<c&&(c=f=(c+f)/2),e.x0=r,e.y0=c,e.x1=h,e.y1=f,e.children&&(n=i[e.depth+1]=o(e)/2,r+=l(e)-n,c+=a(e)-n,h-=s(e)-n,f-=u(e)-n,h<r&&(r=h=(r+h)/2),f<c&&(c=f=(c+f)/2),t(e,r,c,h,f))}return c.round=function(t){return arguments.length?(e=!!t,c):e},c.size=function(t){return arguments.length?(n=+t[0],r=+t[1],c):[n,r]},c.tile=function(e){return arguments.length?(t=AD(e),c):t},c.padding=function(t){return arguments.length?c.paddingInner(t).paddingOuter(t):c.paddingInner()},c.paddingInner=function(t){return arguments.length?(o="function"===typeof t?t:DD(+t),c):o},c.paddingOuter=function(t){return arguments.length?c.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):c.paddingTop()},c.paddingTop=function(t){return arguments.length?(a="function"===typeof t?t:DD(+t),c):a},c.paddingRight=function(t){return arguments.length?(s="function"===typeof t?t:DD(+t),c):s},c.paddingBottom=function(t){return arguments.length?(u="function"===typeof t?t:DD(+t),c):u},c.paddingLeft=function(t){return arguments.length?(l="function"===typeof t?t:DD(+t),c):l},c},PD="#000000",RD="#ffffff",ID="#fcf4d6",ND="#fddc69",jD="#f1c21b",BD="#d2a106",UD="#b28600",VD="#8e6a00",HD="#684e00",GD="#483700",zD="#302400",FD="#1c1500",WD={10:ID,20:ND,30:jD,40:BD,50:UD,60:VD,70:HD,80:GD,90:zD,100:FD},qD="#fff2e8",$D="#ffd9be",YD="#ffb784",ZD="#ff832b",XD="#eb6200",KD="#ba4e00",QD="#8a3800",JD="#5e2900",tk="#3e1a00",ek="#231000",nk={10:qD,20:$D,30:YD,40:ZD,50:XD,60:KD,70:QD,80:JD,90:tk,100:ek},rk="#fff1f1",ik="#ffd7d9",ok="#ffb3b8",ak="#ff8389",sk="#fa4d56",uk="#da1e28",lk="#a2191f",ck="#750e13",hk="#520408",fk="#2d0709",pk={10:rk,20:ik,30:ok,40:ak,50:sk,60:uk,70:lk,80:ck,90:hk,100:fk},dk="#fff0f7",vk="#ffd6e8",gk="#ffafd2",mk="#ff7eb6",yk="#ee5396",_k="#d02670",bk="#9f1853",wk="#740937",Ok="#510224",xk="#2a0a18",Ek={10:dk,20:vk,30:gk,40:mk,50:yk,60:_k,70:bk,80:wk,90:Ok,100:xk},Tk="#f6f2ff",Sk="#e8daff",Mk="#d4bbff",Ck="#be95ff",Ak="#a56eff",Lk="#8a3ffc",Dk="#6929c4",kk="#491d8b",Pk="#31135e",Rk="#1c0f30",Ik={10:Tk,20:Sk,30:Mk,40:Ck,50:Ak,60:Lk,70:Dk,80:kk,90:Pk,100:Rk},Nk="#edf5ff",jk="#d0e2ff",Bk="#a6c8ff",Uk="#78a9ff",Vk="#4589ff",Hk="#0f62fe",Gk="#0043ce",zk="#002d9c",Fk="#001d6c",Wk="#001141",qk={10:Nk,20:jk,30:Bk,40:Uk,50:Vk,60:Hk,70:Gk,80:zk,90:Fk,100:Wk},$k="#e5f6ff",Yk="#bae6ff",Zk="#82cfff",Xk="#33b1ff",Kk="#1192e8",Qk="#0072c3",Jk="#00539a",tP="#003a6d",eP="#012749",nP="#061727",rP={10:$k,20:Yk,30:Zk,40:Xk,50:Kk,60:Qk,70:Jk,80:tP,90:eP,100:nP},iP="#d9fbfb",oP="#9ef0f0",aP="#3ddbd9",sP="#08bdba",uP="#009d9a",lP="#007d79",cP="#005d5d",hP="#004144",fP="#022b30",pP="#081a1c",dP={10:iP,20:oP,30:aP,40:sP,50:uP,60:lP,70:cP,80:hP,90:fP,100:pP},vP="#defbe6",gP="#a7f0ba",mP="#6fdc8c",yP="#42be65",_P="#24a148",bP="#198038",wP="#0e6027",OP="#044317",xP="#022d0d",EP="#071908",TP={10:vP,20:gP,30:mP,40:yP,50:_P,60:bP,70:wP,80:OP,90:xP,100:EP},SP="#f2f4f8",MP="#dde1e6",CP="#c1c7cd",AP="#a2a9b0",LP="#878d96",DP="#697077",kP="#4d5358",PP="#343a3f",RP="#21272a",IP="#121619",NP={10:SP,20:MP,30:CP,40:AP,50:LP,60:DP,70:kP,80:PP,90:RP,100:IP},jP="#f4f4f4",BP="#e0e0e0",UP="#c6c6c6",VP="#a8a8a8",HP="#8d8d8d",GP="#6f6f6f",zP="#525252",FP="#393939",WP="#262626",qP="#161616",$P={10:jP,20:BP,30:UP,40:VP,50:HP,60:GP,70:zP,80:FP,90:WP,100:qP},YP="#f7f3f2",ZP="#e5e0df",XP="#cac5c4",KP="#ada8a8",QP="#8f8b8b",JP="#726e6e",tR="#565151",eR="#3c3838",nR="#272525",rR="#171414",iR={10:YP,20:ZP,30:XP,40:KP,50:QP,60:JP,70:tR,80:eR,90:nR,100:rR},oR={black:{100:PD},blue:qk,coolGray:NP,cyan:rP,gray:$P,green:TP,magenta:Ek,orange:nk,purple:Ik,red:pk,teal:dP,warmGray:iR,white:{0:RD},yellow:WD};var aR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sR=function(t){if(!t)return null;for(var e=0,n=Object.keys(oR);e<n.length;e++)for(var r=n[e],i=oR[r],o=0,a=Object.keys(i);o<a.length;o++){var s=a[o],u=i[s];if(u===t)return s}return null},uR=function(){var t,e=eb(this.parentNode).select("rect.leaf"),n=getComputedStyle(e.node(),null).getPropertyValue("fill"),r=XO(n);if(r&&(t=sR(r?r.hex():null)),null===t||void 0===t){var i=cx(r).l;t=Math.abs(100*i-100)}return t>50?"white":"black"},lR=0,cR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="treemap",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("g[data-name='leaf']").transition("legend-hover-treemap").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-treemap"})})).attr("opacity",(function(t){return t.parent.data.name===n.datum()["name"]?1:.3}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("g[data-name='leaf']").transition("legend-mouseout-treemap").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-treemap"})})).attr("opacity",1)},e}return aR(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=(this.model.getData(),this.model.getDisplayData()),i=this.model.getOptions(),o=Dd(window,"location"),a=sb.getSVGElementSize(n,{useAttrs:!0}),s=a.width,u=a.height,l=zL({name:i.title||"Treemap",children:r}).sum((function(t){return t.value})).sort((function(t,e){return e.value-t.value})),c=kD().size([s,u]).paddingInner(1).paddingOuter(0).round(!0)(l),h=(this.services.transitions,n.selectAll("g[data-name='leaf']").data(c.leaves(),(function(t){return t.data.name})));h.exit().attr("opacity",0).remove();var f=h.enter().append("g").attr("data-name","leaf").attr("data-uid",(function(){return lR++})),p=f.merge(h);p.attr("data-name","leaf").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"treemap-group-update",animate:t})})).attr("transform",(function(t){return"translate("+t.x0+","+t.y0+")"}));var d=p.selectAll("rect.leaf").data((function(t){return[t]}));d.exit().attr("width",0).attr("height",0).remove();var v=d.enter().append("rect").classed("leaf",!0);v.merge(d).attr("width",0).attr("height",0).attr("id",(function(){var t=eb(this.parentNode).attr("data-uid");return i.style.prefix+"-leaf-"+t})).attr("class",(function(t){while(t.depth>1)t=t.parent;return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t.data.name,originalClassName:"leaf"})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"treemap-leaf-update-enter",animate:t})})).attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})).style("fill",(function(t){while(t.depth>1)t=t.parent;return e.model.getFillColor(t.data.name)})),p.selectAll("clipPath").data((function(t){return!0!==t.data.showLabel?[]:[1]}),(function(t){return t})).join((function(t){t.append("clipPath").attr("id",(function(){var t=eb(this.parentNode).attr("data-uid");return i.style.prefix+"-clip-"+t})).append("use").attr("xlink:href",(function(){var t=eb(this.parentNode.parentNode).attr("data-uid"),e=i.style.prefix+"-leaf-"+t;return new URL("#"+e,o)+""}))}),(function(t){return null}),(function(t){return t.remove()})),p.selectAll("text").data((function(t){if(!0!==t.data.showLabel)return[];var n=t;while(n.depth>1)n=n.parent;var r=cx(e.model.getFillColor(n.data.name));return[{text:t.data.name,color:r.l<.5?"white":"black"}]}),(function(t){return t})).join((function(t){var e=t.append("text").text((function(t){return t.text})).style("fill",uR).attr("x",7).attr("y",18);o&&e.attr("clip-path",(function(){var t=eb(this.parentNode).attr("data-uid"),e=i.style.prefix+"-clip-"+t;return"url("+new URL("#"+e,o)+")"}))}),(function(t){return t.text((function(t){return t.text})).style("fill",uR)}),(function(t){return t.remove()})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("rect.leaf").on("mouseover",(function(e,n){var r=eb(this),i=getComputedStyle(this,null).getPropertyValue("fill"),o=n;while(o.depth>1)o=o.parent;r.transition("graph_element_mouseover_fill_update").call((function(e){return t.services.transitions.setupTransition({transition:e,name:"graph_element_mouseover_fill_update"})})).style("fill",(function(e){var n=t.model.getFillColor(e.parent.data.name);return n&&(i=n),XO(i).darker(.7).toString()})),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:[{color:i,label:o.data.name,bold:!0},{label:n.data.name,value:n.data.value}]}),t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEOVER,{event:e,element:r,datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Treemap.LEAF_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1);var i=n;while(i.depth>1)i=i.parent;r.transition().call((function(e){return t.services.transitions.setupTransition({transition:e,name:"graph_element_mouseout_fill_update"})})).style("fill",(function(e){return t.model.getFillColor(e.parent.data.name)})),t.services.events.dispatchEvent(ft.Treemap.LEAF_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})}))},e}(DS);function hR(t){var e=fR(dR(t),360);return pR(e,[0,10])||pR(e,[350,0])?{textAnchor:Q.START,dominantBaseline:J.MIDDLE}:pR(e,[10,80])?{textAnchor:Q.START,dominantBaseline:J.HANGING}:pR(e,[80,100])?{textAnchor:Q.MIDDLE,dominantBaseline:J.HANGING}:pR(e,[100,170])?{textAnchor:Q.END,dominantBaseline:J.HANGING}:pR(e,[170,190])?{textAnchor:Q.END,dominantBaseline:J.MIDDLE}:pR(e,[190,260])?{textAnchor:Q.END,dominantBaseline:J.BASELINE}:pR(e,[260,280])?{textAnchor:Q.MIDDLE,dominantBaseline:J.BASELINE}:{textAnchor:Q.START,dominantBaseline:J.BASELINE}}function fR(t,e){return(t%e+e)%e}function pR(t,e){var n=e[0],r=e[1];return t>=n&&t<=r}function dR(t){return t*(180/Math.PI)}function vR(t,e,n){void 0===n&&(n={x:0,y:0});var r=e*Math.cos(t)+n.x,i=e*Math.sin(t)+n.y;return{x:isNaN(r)?0:r,y:isNaN(i)?0:i}}function gR(t,e){return e*Math.sin(t-Math.PI/2)}var mR=_R(xT);function yR(t){this._curve=t}function _R(t){function e(e){return new yR(t(e))}return e._curve=t,e}function bR(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(_R(t)):e()._curve},t}yR.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};var wR=function(){return bR(MA().curve(mR))},OR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),xR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="radar",e.renderType=I.SVG,e.getLabelDimensions=function(t){var n=sb.appendOrSelect(e.getComponentContainer(),"g.tmp-tick"),r=sb.appendOrSelect(n,"text").text(t),i=sb.getSVGElementSize(r.node(),{useBBox:!0}),o=i.width,a=i.height;return n.remove(),{width:o,height:a}},e.normalizeFlatData=function(t){var n=e.getOptions(),r=Dd(n,"radar","axes"),i=r.angle,o=r.value,a=Dd(n,"data","groupMapsTo"),s=Zh(e.uniqueKeys.map((function(t){return e.uniqueGroups.map((function(e){var n;return n={},n[i]=t,n[a]=e,n[o]=null,n}))})));return na(s,t)},e.normalizeGroupedData=function(t){var n=e.getOptions(),r=Dd(n,"radar","axes"),i=r.angle,o=r.value,a=Dd(n,"data","groupMapsTo");return t.map((function(t){var n=t.name,r=t.data,s=e.uniqueKeys.map((function(t){var e;return e={},e[a]=n,e[i]=t,e[o]=null,e}));return{name:n,data:na(s,r)}}))},e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("g.blobs path").transition("legend-hover-blob").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-blob"})})).style("fill-opacity",(function(t){return t.name!==n.datum().name?St.opacity.unselected:St.opacity.selected})).style("stroke-opacity",(function(t){return t.name!==n.datum().name?St.opacity.unselected:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("g.blobs path").transition("legend-mouseout-blob").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-blob"})})).style("fill-opacity",St.opacity.selected).style("stroke-opacity",1)},e}return OR(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=sb.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height,s=this.model.getData(),u=this.model.getGroupedData(),l=this.getOptions(),c=Dd(l,"data","groupMapsTo"),h=Dd(l,"radar","axes","value"),f=Dd(l,"radar","axes"),p=f.angle,d=f.value,v=St,g=v.xLabelPadding,m=v.yLabelPadding,y=v.yTicksNumber,_=v.minRange,b=v.xAxisRectHeight;this.uniqueKeys=Array.from(new Set(s.map((function(t){return t[p]})))),this.uniqueGroups=Array.from(new Set(s.map((function(t){return t[c]})))),this.fullDataNormalized=this.normalizeFlatData(s),this.groupedDataNormalized=this.normalizeGroupedData(u);var w=this.getLabelDimensions(this.uniqueKeys[0]).height,O=2*(w+m),x=Math.min(i,o),E=x-O,T=E/2;if(!(T<=0)){var S=kE().domain(this.fullDataNormalized.map((function(t){return t[p]}))).range([0,2*Math.PI].map((function(t){return t-Math.PI/2}))),M=Vm(this.fullDataNormalized.map((function(t){return t[d]}))),C=BE().domain([M>=0?0:M,UE(this.fullDataNormalized.map((function(t){return t[d]})))]).range([_,T]).nice(y),A=C.ticks(y),L=function(t){return e.model.getFillColor(t)},D=wR().angle((function(t){return S(t[p])+Math.PI/2})).radius((function(t){return C(t[d])})).curve(ST),k=this.uniqueKeys.map((function(t){var n=e.getLabelDimensions(t).width,r=gR(S(t),T);return n+r})),P=UE(k),R={x:P+g,y:o/2},I=sb.appendOrSelect(n,"g.y-axes").attr("role",a.GROUP),N=I.selectAll("path").data(A,(function(t){return t})),B=function(t){return e.uniqueKeys.map((function(e){var n;return n={},n[p]=e,n[d]=t,n}))};N.join((function(n){return n.append("path").attr("opacity",0).attr("transform","translate("+R.x+", "+R.y+")").attr("fill","none").call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_enter",animate:t})})).attr("opacity",1).attr("d",(function(t){return D(B(t))}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_update",animate:t})})).attr("opacity",1).attr("transform","translate("+R.x+", "+R.y+")").attr("d",(function(t){return D(B(t))}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_axes_exit",animate:t})})).attr("d",(function(t){return D(B(t))})).attr("opacity",0).remove()}))}));var U=sb.appendOrSelect(n,"g.x-axes").attr("role",a.GROUP),V=U.selectAll("line").data(this.uniqueKeys,(function(t){return t}));V.join((function(n){return n.append("line").attr("opacity",0).attr("class",(function(t){return"x-axis-"+Kh(t)})).attr("stroke-dasharray","0").attr("x1",(function(t){return vR(S(t),0,R).x})).attr("y1",(function(t){return vR(S(t),0,R).y})).attr("x2",(function(t){return vR(S(t),0,R).x})).attr("y2",(function(t){return vR(S(t),0,R).y})).call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_enter",animate:t})})).attr("opacity",1).attr("x1",(function(t){return vR(S(t),C.range()[0],R).x})).attr("y1",(function(t){return vR(S(t),C.range()[0],R).y})).attr("x2",(function(t){return vR(S(t),C.range()[1],R).x})).attr("y2",(function(t){return vR(S(t),C.range()[1],R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_update",animate:t})})).attr("opacity",1).attr("x1",(function(t){return vR(S(t),C.range()[0],R).x})).attr("y1",(function(t){return vR(S(t),C.range()[0],R).y})).attr("x2",(function(t){return vR(S(t),C.range()[1],R).x})).attr("y2",(function(t){return vR(S(t),C.range()[1],R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_axes_exit",animate:t})})).attr("opacity",0).remove()}))}));var H=sb.appendOrSelect(n,"g.x-labels").attr("role",a.GROUP),G=H.selectAll("text").data(this.uniqueKeys);G.join((function(n){return n.append("text").text((function(t){return t})).attr("opacity",0).attr("x",(function(t){return vR(S(t),C.range()[1]+g,R).x})).attr("y",(function(t){return vR(S(t),C.range()[1]+g,R).y})).style("text-anchor",(function(t){return hR(S(t)).textAnchor})).style("dominant-baseline",(function(t){return hR(S(t)).dominantBaseline})).call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_enter",animate:t})})).attr("opacity",1)}))}),(function(r){return r.call((function(r){return r.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_update",animate:t})})).attr("opacity",1).attr("x",(function(t){return vR(S(t),C.range()[1]+g,R).x})).attr("y",(function(t){return vR(S(t),C.range()[1]+g,R).y})).end().finally((function(){var t=Dd(l,"radar","alignment"),r=e.getAlignmentXOffset(t,n,e.getParent());n.attr("x",r)}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_x_labels_exit",animate:t})})).attr("opacity",0).remove()}))}));var z=sb.appendOrSelect(n,"g.blobs").attr("role",a.GROUP),F=z.selectAll("path").data(this.groupedDataNormalized,(function(t){return t.name}));F.join((function(n){return n.append("path").attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"blob"})})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){return t["name"]})).attr("opacity",0).attr("transform",t?function(){return"translate("+R.x+", "+R.y+") scale("+(1+.35*Math.random())+")"}:"translate("+R.x+", "+R.y+")").style("fill",(function(t){return L(t.name)})).style("fill-opacity",St.opacity.selected).style("stroke",(function(t){return L(t.name)})).call((function(n){var r=n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_enter",animate:t})}));t&&r.delay((function(){return 30*Math.random()})).attr("transform","translate("+R.x+", "+R.y+")"),r.attr("opacity",1).attr("d",(function(t){return D(t.data)}))}))}),(function(n){n.attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.name,originalClassName:"blob"})})).style("fill",(function(t){return L(t.name)})).style("stroke",(function(t){return L(t.name)})),n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_update",animate:t})})).attr("opacity",1).attr("transform","translate("+R.x+", "+R.y+")").attr("d",(function(t){return D(t.data)}))}))}),(function(n){return n.call((function(n){var r=n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_blobs_exit",animate:t})}));t&&r.delay((function(){return 30*Math.random()})).attr("transform",(function(){return"translate("+R.x+", "+R.y+") scale("+(1+.35*Math.random())+")"})),r.attr("opacity",0).remove()}))}));var W=sb.appendOrSelect(n,"g.dots").attr("role",a.GROUP),q=W.selectAll("circle").data(this.fullDataNormalized.filter((function(t){return null!==Dd(t,d)})));q.join((function(t){return t.append("circle").attr("role",a.GRAPHICS_SYMBOL).attr("aria-label",(function(t){return t[h]}))}),(function(t){return t}),(function(t){return t.remove()})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[c],originalClassName:Kh(t[p])})})).attr("cx",(function(t){return vR(S(t[p]),C(t[d]),R).x})).attr("cy",(function(t){return vR(S(t[p]),C(t[d]),R).y})).attr("r",0).attr("opacity",0).style("fill",(function(t){return L(t[c])}));var $=sb.appendOrSelect(n,"g.x-axes-rect").attr("role",a.GROUP),Y=$.selectAll("rect").data(this.uniqueKeys);Y.join((function(t){return t.append("rect")}),(function(t){return t}),(function(t){return t.remove()})).attr("x",R.x).attr("y",R.y-b/2).attr("width",C.range()[1]).attr("height",b).style("fill","red").style("fill-opacity",0).attr("transform",(function(t){return"rotate("+dR(S(t))+", "+R.x+", "+R.y+")"}));var Z=sb.appendOrSelect(n,"g.y-labels").attr("role",a.GROUP),X=Z.selectAll("text").data(Xv(A));X.join((function(n){return n.append("text").attr("opacity",0).text((function(t){return t})).attr("x",(function(t){return vR(-Math.PI/2,C(t),R).x+m})).attr("y",(function(t){return vR(-Math.PI/2,C(t),R).y})).style("text-anchor","start").style("dominant-baseline","middle").call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_enter",animate:t})})).attr("opacity",1)}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_update",animate:t})})).text((function(t){return t})).attr("opacity",1).attr("x",(function(t){return vR(-Math.PI/2,C(t),R).x+m})).attr("y",(function(t){return vR(-Math.PI/2,C(t),R).y}))}))}),(function(n){return n.call((function(n){return n.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"radar_y_labels_exit",animate:t})})).attr("opacity",0).remove()}))})),this.addEventListeners()}},e.prototype.getAlignmentXOffset=function(t,e,n){var r=sb.getSVGElementSize(e,{useBBox:!0}),i=sb.getSVGElementSize(n,{useAttrs:!0}).width,o=0;return t===F.CENTER?o=Math.floor((i-r.width)/2):t===F.RIGHT&&(o=i-r.width),o},e.prototype.destroy=function(){this.parent.selectAll(".x-axes-rect > rect").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.addEventListeners=function(){var t=this,e=Dd(this.getOptions(),"radar").axes.angle;this.parent.selectAll(".x-axes-rect > rect").on("mouseover",(function(n,r){var i=eb(this);t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEOVER,{event:n,element:i,datum:r});var o=t.parent.select(".x-axes .x-axis-"+Kh(r)),a=t.parent.selectAll(".dots circle."+Kh(r)),s=t.model.getActiveDataGroupNames(),u=t.getOptions(),l=u.data.groupMapsTo,c=Dd(u,"radar","axes","value");o.classed("hovered",!0).attr("stroke-dasharray","4 4"),a.classed("hovered",!0).attr("opacity",(function(t){return-1!==s.indexOf(t[l])?1:0})).attr("r",St.dotsRadius);var h=t.fullDataNormalized.filter((function(t){return t[e]===r&&-1!==s.indexOf(t[l])}));t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n,hoveredElement:i,items:h.filter((function(t){return"number"===typeof t[c]})).map((function(e){return{label:e[l],value:e[c],color:t.model.getFillColor(e[l]),class:t.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:e[l]})}}))})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Radar.X_AXIS_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=t.parent.select(".x-axes .x-axis-"+Kh(n)),o=t.parent.selectAll(".dots circle."+Kh(n));i.classed("hovered",!1).attr("stroke-dasharray","0"),o.classed("hovered",!1).attr("opacity",0).attr("r",0),t.services.events.dispatchEvent(ft.Radar.X_AXIS_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e}(DS);const ER=1664525,TR=1013904223,SR=4294967296;var MR=function(){let t=1;return()=>(t=(ER*t+TR)%SR)/SR},CR=function(t){return"object"===typeof t&&"length"in t?t:Array.from(t)};function AR(t,e){let n,r,i=t.length;while(i)r=e()*i--|0,n=t[i],t[i]=t[r],t[r]=n;return t}function LR(t,e){var n,r,i=0,o=(t=AR(Array.from(t),e)).length,a=[];while(i<o)n=t[i],r&&PR(r,n)?++i:(r=IR(a=DR(a,n)),i=0);return r}function DR(t,e){var n,r;if(RR(e,t))return[e];for(n=0;n<t.length;++n)if(kR(e,t[n])&&RR(jR(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(r=n+1;r<t.length;++r)if(kR(jR(t[n],t[r]),e)&&kR(jR(t[n],e),t[r])&&kR(jR(t[r],e),t[n])&&RR(BR(t[n],t[r],e),t))return[t[n],t[r],e];throw new Error}function kR(t,e){var n=t.r-e.r,r=e.x-t.x,i=e.y-t.y;return n<0||n*n<r*r+i*i}function PR(t,e){var n=t.r-e.r+1e-9*Math.max(t.r,e.r,1),r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function RR(t,e){for(var n=0;n<e.length;++n)if(!PR(t,e[n]))return!1;return!0}function IR(t){switch(t.length){case 1:return NR(t[0]);case 2:return jR(t[0],t[1]);case 3:return BR(t[0],t[1],t[2])}}function NR(t){return{x:t.x,y:t.y,r:t.r}}function jR(t,e){var n=t.x,r=t.y,i=t.r,o=e.x,a=e.y,s=e.r,u=o-n,l=a-r,c=s-i,h=Math.sqrt(u*u+l*l);return{x:(n+o+u/h*c)/2,y:(r+a+l/h*c)/2,r:(h+i+s)/2}}function BR(t,e,n){var r=t.x,i=t.y,o=t.r,a=e.x,s=e.y,u=e.r,l=n.x,c=n.y,h=n.r,f=r-a,p=r-l,d=i-s,v=i-c,g=u-o,m=h-o,y=r*r+i*i-o*o,_=y-a*a-s*s+u*u,b=y-l*l-c*c+h*h,w=p*d-f*v,O=(d*b-v*_)/(2*w)-r,x=(v*g-d*m)/w,E=(p*_-f*b)/(2*w)-i,T=(f*m-p*g)/w,S=x*x+T*T-1,M=2*(o+O*x+E*T),C=O*O+E*E-o*o,A=-(Math.abs(S)>1e-6?(M+Math.sqrt(M*M-4*S*C))/(2*S):C/M);return{x:r+O+x*A,y:i+E+T*A,r:A}}function UR(t,e,n){var r,i,o,a,s=t.x-e.x,u=t.y-e.y,l=s*s+u*u;l?(i=e.r+n.r,i*=i,a=t.r+n.r,a*=a,i>a?(r=(l+a-i)/(2*l),o=Math.sqrt(Math.max(0,a/l-r*r)),n.x=t.x-r*s-o*u,n.y=t.y-r*u+o*s):(r=(l+i-a)/(2*l),o=Math.sqrt(Math.max(0,i/l-r*r)),n.x=e.x+r*s-o*u,n.y=e.y+r*u+o*s)):(n.x=e.x+n.r,n.y=e.y)}function VR(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function HR(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,o=(e.y*n.r+n.y*e.r)/r;return i*i+o*o}function GR(t){this._=t,this.next=null,this.previous=null}function zR(t,e){if(!(o=(t=CR(t)).length))return 0;var n,r,i,o,a,s,u,l,c,h,f;if(n=t[0],n.x=0,n.y=0,!(o>1))return n.r;if(r=t[1],n.x=-r.r,r.x=n.r,r.y=0,!(o>2))return n.r+r.r;UR(r,n,i=t[2]),n=new GR(n),r=new GR(r),i=new GR(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(u=3;u<o;++u){UR(n._,r._,i=t[u]),i=new GR(i),l=r.next,c=n.previous,h=r._.r,f=n._.r;do{if(h<=f){if(VR(l._,i._)){r=l,n.next=r,r.previous=n,--u;continue t}h+=l._.r,l=l.next}else{if(VR(c._,i._)){n=c,n.next=r,r.previous=n,--u;continue t}f+=c._.r,c=c.previous}}while(l!==c.next);i.previous=n,i.next=r,n.next=r.previous=r=i,a=HR(n);while((i=i.next)!==r)(s=HR(i))<a&&(n=i,a=s);r=n.next}n=[r._],i=r;while((i=i.next)!==r)n.push(i._);for(i=LR(n,e),u=0;u<o;++u)n=t[u],n.x-=i.x,n.y-=i.y;return i.r}function FR(t){return Math.sqrt(t.value)}var WR=function(){var t=null,e=1,n=1,r=LD;function i(i){const o=MR();return i.x=e/2,i.y=n/2,t?i.eachBefore(qR(t)).eachAfter($R(r,.5,o)).eachBefore(YR(1)):i.eachBefore(qR(FR)).eachAfter($R(LD,1,o)).eachAfter($R(r,i.r/Math.min(e,n),o)).eachBefore(YR(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=CD(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"===typeof t?t:DD(+t),i):r},i};function qR(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function $R(t,e,n){return function(r){if(i=r.children){var i,o,a,s=i.length,u=t(r)*e||0;if(u)for(o=0;o<s;++o)i[o].r+=u;if(a=zR(i,n),u)for(o=0;o<s;++o)i[o].r-=u;r.r=a+u}}}function YR(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}var ZR=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XR=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},KR=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="circle-pack",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("circle.node").transition("legend-hover-circlepack").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-circlepack"})})).attr("opacity",(function(t){return t.data.dataGroupName===n.datum()["name"]?1:yt.circles.fillOpacity}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.node").transition("legend-mouseout-circlepack").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-circlepack"})})).attr("opacity",1)},e}return ZR(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0}),r=sb.getSVGElementSize(this.parent,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getDisplayData(),s=this.model.hasParentNode(),u=this.model.getHierarchyLevel(),l=this.getOptions(),c=Dd(l,"canvasZoom","enabled");s&&Dd(a,0,"children")&&(a=Dd(a,0,"children"));var h=zL({children:a}).sum((function(t){return t.value})).sort((function(t,e){return e.value-t.value})),f=WR().size([i,o]).padding((function(t){return t.depth>=1?yt.padding.children+3:yt.padding.mainGroup+3})),p=f(h).descendants().splice(1).filter((function(t){return t.depth<=u})),d=n.selectAll("circle.node").data(p);d.exit().attr("width",0).attr("height",0).remove();var v=d.enter().append("circle").classed("node",!0);v.merge(d).attr("class",(function(t){var n=c&&3===u?e.getZoomClass(t):"";return e.model.getColorClassName({classNameTypes:[j.FILL,j.STROKE],dataGroupName:t.data.dataGroupName,originalClassName:t.children?"node "+n:"node node-leaf "+n})})).style("fill",(function(t){return e.model.getFillColor(t.data.dataGroupName)})).style("stroke",(function(t){return e.model.getFillColor(t.data.dataGroupName)})).attr("cx",(function(t){return t.x})).attr("cy",(function(t){return t.y})).transition("circlepack-leaf-update-enter").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"circlepack-leaf-update-enter"})})).attr("r",(function(t){return t.r})).attr("opacity",1).attr("fill-opacity",yt.circles.fillOpacity),!0===c&&this.focal&&(this.services.canvasZoom.zoomIn(this.focal,v,mt),this.setBackgroundListeners()),s||this.addLegendListeners(),this.addEventListeners()}},e.prototype.unhighlightChildren=function(t){var e=this,n=t.map((function(t){return t.data}));this.parent.selectAll("circle.node").filter((function(t){return n.some((function(e){return e===t.data}))&&t.depth>1})).style("stroke",(function(t){return e.model.getFillColor(t.data.dataGroupName)}))},e.prototype.highlightChildren=function(t){var e=t.map((function(t){return t.data}));this.parent.selectAll("circle.node").filter((function(t){return e.some((function(e){return e===t.data}))&&t.depth>1})).style("stroke",yt.circles.hover.stroke)},e.prototype.getZoomClass=function(t){return 3===this.model.getHierarchyLevel()&&this.focal&&(t.data===this.focal.data||this.focal.children.some((function(e){return e.data===t.data})))?"focal":"non-focal"},e.prototype.addLegendListeners=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.removeBackgroundListeners=function(){var t=eb(this.services.domUtils.getMainContainer());t.on("click",(function(){return null}))},e.prototype.setBackgroundListeners=function(){var t=eb(this.services.domUtils.getMainContainer()),e=this,n=this.parent.selectAll("circle.node"),r=Dd(o,"canvasZoomSettings");t.on("click",(function(){e.focal=null,e.model.updateHierarchyLevel(2),t.classed("zoomed-in",!1),e.services.canvasZoom.zoomOut(n,r)}))},e.prototype.getZoomIcon=function(){return'\n\t\t<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 10 10">\n\t\t\t<polygon points="5.93 3.71 4.45 3.71 4.45 2.23 3.71 2.23 3.71 3.71 2.23 3.71 2.23 4.45 3.71 4.45 3.71 5.93 4.45 5.93 4.45 4.45 5.93 4.45 5.93 3.71"/>\n\t\t\t<path d="M7.2,6.67a4,4,0,0,0,1-2.59A4.08,4.08,0,1,0,4.07,8.15h0a4,4,0,0,0,2.59-1L9.48,10,10,9.48Zm-3.12.77A3.34,3.34,0,1,1,7.41,4.08,3.34,3.34,0,0,1,4.08,7.44Z"/>\n\t\t</svg>'},e.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("circle.node").on("mouseover",(function(e,n){var r=eb(this);r.classed("hovered",!0);var i=t.model.getHierarchyLevel(),o=i>2&&!r.classed("focal"),a=Dd(t.model.getOptions(),"canvasZoom","enabled"),s=!1;if(!o){var u=[],l=[],c=null;if(n.children){n.depth>1&&a&&(s=!0,r.classed("clickable",!0)),u=n.children.map((function(e){if(null!==e)return"number"===typeof e.data.value?{label:e.data.name,value:e.data.value}:{label:e.data.name,labelIcon:a&&i<=2?t.getZoomIcon():null,value:e.value}}));var h=t.model.getOptions();l=[{label:tl(h,"tooltip.totalLabel")||"Total",value:n.value,bold:!0}],t.highlightChildren(n.children)}else c=n.value;var f=getComputedStyle(this,null).getPropertyValue("fill");t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,hoveredElement:r,items:XR([{color:f,label:n.data.name,labelIcon:s&&a&&i<=2?t.getZoomIcon():null,value:c}],u,l)})}t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEOVER,{event:e,element:r,datum:n})})).on("mousemove",(function(e,n){var r=eb(this);t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEMOVE,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("mouseout",(function(e,n){var r=eb(this);r.classed("hovered",!1),n.children&&t.unhighlightChildren(n.children),t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_MOUSEOUT,{event:e,element:r,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:r})})).on("click",(function(e,n){var r=eb(this),i=r.classed("non-focal"),o=Dd(t.model.getOptions(),"canvasZoom","enabled");if(o&&t.model.getHierarchyLevel()>2){var a=t.parent.selectAll("circle.node"),s=eb(t.services.domUtils.getMainContainer());s.classed("zoomed-in",!1),t.focal=null,t.model.updateHierarchyLevel(2),t.services.canvasZoom.zoomOut(a,mt)}else if(2===n.depth&&n.children&&!i&&o){a=t.parent.selectAll("circle.node"),s=eb(t.services.domUtils.getMainContainer());s.classed("zoomed-in",!0),t.focal=n,t.model.updateHierarchyLevel(3),t.services.canvasZoom.zoomIn(n,a,mt),e.stopPropagation()}t.services.events.dispatchEvent(ft.CirclePack.CIRCLE_CLICK,{event:e,element:r,datum:n})}))},e.prototype.destroy=function(){this.parent.selectAll("circle.node").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("click",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut),this.removeBackgroundListeners()},e}(DS),QR=n("2a60"),JR=n.n(QR),tI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="wordcloud",e.renderType=I.SVG,e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement,r=e.getOptions().data.groupMapsTo;e.parent.selectAll("text.word").transition("legend-hover-wordcloud").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-hover-wordcloud"})})).attr("opacity",(function(t){return t[r]!==n.datum()["name"]?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("text.word").transition("legend-mouseout-wordcloud").call((function(t){return e.services.transitions.setupTransition({transition:t,name:"legend-mouseout-wordcloud"})})).attr("opacity",1)},e}return tI(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Legend.ITEM_HOVER,this.handleLegendOnHover),t.addEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleLegendMouseOut)},e.prototype.render=function(t){void 0===t&&(t=!0);var e=this,n=this.getComponentContainer().attr("width","100%").attr("height","100%"),r=this.model.getDisplayData(),i=this.getFontSizeScale(r),o=this.getOptions(),a=o.wordCloud,s=a.fontSizeMapsTo,u=a.wordMapsTo,l=o.data.groupMapsTo,c=sb.getSVGElementSize(n,{useAttrs:!0}),h=c.width,f=c.height;if(0!==h&&0!==f){var p=JR()().size([h,f]).words(r.map((function(t){var e,n=t[s];if("number"!==typeof t[s])throw Error("Badly formatted WordCloud data. `value` should only be an integer or float");return e={},e[l]=t[l],e.text=t[u],e.size=n,e.value=n,e}))).padding(5).rotate(0).fontSize((function(t){return i(t.size)})).on("end",d);p.start(),this.addEventListeners()}function d(r){var i=sb.appendOrSelect(n,"g.words");i.attr("transform","translate("+p.size()[0]/2+", "+p.size()[1]/2+")");var o=i.selectAll("text").data(r,(function(t){return t[l]+"-"+t.text}));o.exit().attr("opacity",0).remove();var a=o.enter().append("text").attr("opacity",0);a.merge(o).style("font-size",(function(t){return t.size+"px"})).text((function(t){return t.text})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[l],originalClassName:"word "+(t.size>32?"light":"")})})).style("fill",(function(t){return e.model.getFillColor(t[l],t.text,t)})).attr("text-anchor","middle").transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"wordcloud-text-update-enter",animate:t})})).attr("transform",(function(t){return"translate("+t.x+", "+t.y+")"})).attr("opacity",1)}},e.prototype.getFontSizeScale=function(t){var e=this.getOptions(),n=e.wordCloud.fontSizeMapsTo,r=t.map((function(t){return t[n]})).filter((function(t){return t})),i=sb.getHTMLElementSize(this.services.domUtils.getMainContainer()),o=r.length>0,a=o?Xv(r):[1,1];return BE().domain(a).range(o?e.wordCloud.fontSizeRange(i,t):[4,4])},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this,r=Te((function(t){var e=n.parent.selectAll("text.word").transition("wordcloud-word-mouse-highlight").call((function(t){return n.services.transitions.setupTransition({transition:t,name:"wordcloud-word-mouse-highlight"})}));null===t?e.attr("opacity",1):e.attr("opacity",(function(){return t===this?1:.3}))}),6);this.parent.selectAll("text.word").on("mouseover",(function(i,o){var a=this;r(a),n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEOVER,{event:i,element:eb(this),datum:o}),n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:i,hoveredElement:a,items:[{label:t.tooltip.wordLabel,value:o.text},{label:t.tooltip.valueLabel,value:o.value},{label:t.tooltip.groupLabel,value:o[e],class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:o[e]})}]})})).on("mousemove",(function(t,e){var r=eb(this);n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEMOVE,{element:r,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.WordCloud.WORD_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var i=eb(this);r(null),n.services.events.dispatchEvent(ft.WordCloud.WORD_MOUSEOUT,{event:t,element:i,datum:e}),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e}(DS);function nI(t,e){let n=0;if(void 0===e)for(let r of t)(r=+r)&&(n+=r);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&(n+=i)}return n}function rI(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n<r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function iI(t,e){let n;if(void 0===e)for(const r of t)null!=r&&(n>r||void 0===n&&r>=r)&&(n=r);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function oI(t){return t.depth}function aI(t,e){return e-1-t.height}function sI(t,e){return t.sourceLinks.length?t.depth:e-1}function uI(t){return function(){return t}}function lI(t,e){return hI(t.source,e.source)||t.index-e.index}function cI(t,e){return hI(t.target,e.target)||t.index-e.index}function hI(t,e){return t.y0-e.y0}function fI(t){return t.value}function pI(t){return t.index}function dI(t){return t.nodes}function vI(t){return t.links}function gI(t,e){const n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function mI({nodes:t}){for(const e of t){let t=e.y0,n=t;for(const r of e.sourceLinks)r.y0=t+r.width/2,t+=r.width;for(const r of e.targetLinks)r.y1=n+r.width/2,n+=r.width}}function yI(){let t,e,n,r=0,i=0,o=1,a=1,s=24,u=8,l=pI,c=sI,h=dI,f=vI,p=6;function d(){const t={nodes:h.apply(null,arguments),links:f.apply(null,arguments)};return v(t),g(t),m(t),y(t),w(t),mI(t),t}function v({nodes:t,links:e}){for(const[n,i]of t.entries())i.index=n,i.sourceLinks=[],i.targetLinks=[];const r=new Map(t.map((e,n)=>[l(e,n,t),e]));for(const[n,i]of e.entries()){i.index=n;let{source:t,target:e}=i;"object"!==typeof t&&(t=i.source=gI(r,t)),"object"!==typeof e&&(e=i.target=gI(r,e)),t.sourceLinks.push(i),e.targetLinks.push(i)}if(null!=n)for(const{sourceLinks:i,targetLinks:o}of t)i.sort(n),o.sort(n)}function g({nodes:t}){for(const e of t)e.value=void 0===e.fixedValue?Math.max(nI(e.sourceLinks,fI),nI(e.targetLinks,fI)):e.fixedValue}function m({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;while(n.size){for(const t of n){t.depth=i;for(const{target:e}of t.sourceLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}function y({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;while(n.size){for(const t of n){t.height=i;for(const{source:e}of t.targetLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}function _({nodes:t}){const n=rI(t,t=>t.depth)+1,i=(o-r-s)/(n-1),a=new Array(n);for(const e of t){const t=Math.max(0,Math.min(n-1,Math.floor(c.call(null,e,n))));e.layer=t,e.x0=r+t*i,e.x1=e.x0+s,a[t]?a[t].push(e):a[t]=[e]}if(e)for(const r of a)r.sort(e);return a}function b(e){const n=iI(e,e=>(a-i-(e.length-1)*t)/nI(e,fI));for(const r of e){let e=i;for(const i of r){i.y0=e,i.y1=e+i.value*n,e=i.y1+t;for(const t of i.sourceLinks)t.width=t.value*n}e=(a-e+t)/(r.length+1);for(let t=0;t<r.length;++t){const n=r[t];n.y0+=e*(t+1),n.y1+=e*(t+1)}C(r)}}function w(e){const n=_(e);t=Math.min(u,(a-i)/(rI(n,t=>t.length)-1)),b(n);for(let t=0;t<p;++t){const e=Math.pow(.99,t),r=Math.max(1-e,(t+1)/p);x(n,e,r),O(n,e,r)}}function O(t,n,r){for(let i=1,o=t.length;i<o;++i){const o=t[i];for(const t of o){let e=0,r=0;for(const{source:n,value:o}of t.targetLinks){let i=o*(t.layer-n.layer);e+=A(n,t)*i,r+=i}if(!(r>0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,M(t)}void 0===e&&o.sort(hI),E(o,r)}}function x(t,n,r){for(let i=t.length,o=i-2;o>=0;--o){const i=t[o];for(const t of i){let e=0,r=0;for(const{target:n,value:o}of t.sourceLinks){let i=o*(n.layer-t.layer);e+=L(t,n)*i,r+=i}if(!(r>0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,M(t)}void 0===e&&i.sort(hI),E(i,r)}}function E(e,n){const r=e.length>>1,o=e[r];S(e,o.y0-t,r-1,n),T(e,o.y1+t,r+1,n),S(e,a,e.length-1,n),T(e,i,0,n)}function T(e,n,r,i){for(;r<e.length;++r){const o=e[r],a=(n-o.y0)*i;a>1e-6&&(o.y0+=a,o.y1+=a),n=o.y1+t}}function S(e,n,r,i){for(;r>=0;--r){const o=e[r],a=(o.y1-n)*i;a>1e-6&&(o.y0-=a,o.y1-=a),n=o.y0-t}}function M({sourceLinks:t,targetLinks:e}){if(void 0===n){for(const{source:{sourceLinks:t}}of e)t.sort(cI);for(const{target:{targetLinks:e}}of t)e.sort(lI)}}function C(t){if(void 0===n)for(const{sourceLinks:e,targetLinks:n}of t)e.sort(cI),n.sort(lI)}function A(e,n){let r=e.y0-(e.sourceLinks.length-1)*t/2;for(const{target:i,width:o}of e.sourceLinks){if(i===n)break;r+=o+t}for(const{source:t,width:i}of n.targetLinks){if(t===e)break;r-=i}return r}function L(e,n){let r=n.y0-(n.targetLinks.length-1)*t/2;for(const{source:i,width:o}of n.targetLinks){if(i===e)break;r+=o+t}for(const{target:t,width:i}of e.sourceLinks){if(t===n)break;r-=i}return r}return d.update=function(t){return mI(t),t},d.nodeId=function(t){return arguments.length?(l="function"===typeof t?t:uI(t),d):l},d.nodeAlign=function(t){return arguments.length?(c="function"===typeof t?t:uI(t),d):c},d.nodeSort=function(t){return arguments.length?(e=t,d):e},d.nodeWidth=function(t){return arguments.length?(s=+t,d):s},d.nodePadding=function(e){return arguments.length?(u=t=+e,d):u},d.nodes=function(t){return arguments.length?(h="function"===typeof t?t:uI(t),d):h},d.links=function(t){return arguments.length?(f="function"===typeof t?t:uI(t),d):f},d.linkSort=function(t){return arguments.length?(n=t,d):n},d.size=function(t){return arguments.length?(r=i=0,o=+t[0],a=+t[1],d):[o-r,a-i]},d.extent=function(t){return arguments.length?(r=+t[0][0],o=+t[1][0],i=+t[0][1],a=+t[1][1],d):[[r,i],[o,a]]},d.iterations=function(t){return arguments.length?(p=+t,d):p},d}var _I=Math.PI,bI=2*_I,wI=1e-6,OI=bI-wI;function xI(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function EI(){return new xI}xI.prototype=EI.prototype={constructor:xI,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+o)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,h=l*l+c*c;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(h>wI)if(Math.abs(c*s-u*l)>wI&&i){var f=n-o,p=r-a,d=s*s+u*u,v=f*f+p*p,g=Math.sqrt(d),m=Math.sqrt(h),y=i*Math.tan((_I-Math.acos((d+h-v)/(2*g*m)))/2),_=y/m,b=y/g;Math.abs(_-1)>wI&&(this._+="L"+(t+_*l)+","+(e+_*c)),this._+="A"+i+","+i+",0,0,"+ +(c*f>l*p)+","+(this._x1=t+b*s)+","+(this._y1=e+b*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,n=+n,o=!!o;var a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,h=o?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>wI||Math.abs(this._y1-l)>wI)&&(this._+="L"+u+","+l),n&&(h<0&&(h=h%bI+bI),h>OI?this._+="A"+n+","+n+",0,1,"+c+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):h>wI&&(this._+="A"+n+","+n+",0,"+ +(h>=_I)+","+c+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var TI=EI,SI=Array.prototype.slice,MI=function(t){return function(){return t}};function CI(t){return t[0]}function AI(t){return t[1]}function LI(t){return t.source}function DI(t){return t.target}function kI(t){var e=LI,n=DI,r=CI,i=AI,o=null;function a(){var a,s=SI.call(arguments),u=e.apply(this,s),l=n.apply(this,s);if(o||(o=a=TI()),t(o,+r.apply(this,(s[0]=u,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),a)return o=null,a+""||null}return a.source=function(t){return arguments.length?(e=t,a):e},a.target=function(t){return arguments.length?(n=t,a):n},a.x=function(t){return arguments.length?(r="function"===typeof t?t:MI(+t),a):r},a.y=function(t){return arguments.length?(i="function"===typeof t?t:MI(+t),a):i},a.context=function(t){return arguments.length?(o=null==t?null:t,a):o},a}function PI(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e=(e+r)/2,n,e,i,r,i)}function RI(){return kI(PI)}function II(t){return[t.source.x1,t.y0]}function NI(t){return[t.target.x0,t.y1]}var jI=function(){return RI().source(II).target(NI)},BI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="alluvial",e.renderType=I.SVG,e.gradient_id="gradient-id-"+Math.floor(99999999999*Math.random()),e}return BI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0});n.html("");var r=sb.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height;if(!(i<1||o<1)){var a=this.model.getOptions(),s=this.model.getDisplayData(),u=Dd(this.getOptions(),"color","gradient","enabled"),l=Mt.minNodePadding;a.alluvial.nodePadding>Mt.minNodePadding&&(l=a.alluvial.nodePadding);var c=Dd(a,"alluvial","nodeAlignment"),h=sI;c===F.LEFT?h=oI:c===F.RIGHT&&(h=aI);var f=yI().nodeId((function(t){return t.name})).nodeWidth(Mt.nodeWidth).nodePadding(l).nodeAlign(h).extent([[2,30],[i-2,o]]);this.graph=f({nodes:a.alluvial.nodes.map((function(t){return Object.assign({},t)})),links:s.map((function(t){return Object.assign({},t)}))}),this.graph.nodes=this.graph.nodes.filter((function(t){return 0!==t.value}));var p={};this.graph.nodes.forEach((function(t){var e,n=t.x0;t.category&&(p[n]=null===(e=t)||void 0===e?void 0:e.category)}));var d=n.append("g").classed("header-arrows",!0).selectAll("g").data(Object.keys(p)).join("g").attr("transform",(function(t){return"translate("+t+", 0)"}));d.append("text").attr("id",(function(t,n){return e.services.domUtils.generateElementIDString("alluvial-category-"+n)})).style("font-size","14px").text((function(t){return p[t]?p[t]:""})).attr("y",20).attr("x",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-category-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width,o=0;return t+o>=i&&(o=4-i),o}));var v=n.append("g").attr("fill","none").selectAll("g").data(this.graph.links);if(v.exit().remove(),u){var g=Dd(this.getOptions(),"color","scale");g&&v.enter().append("linearGradient").attr("id",(function(t){return e.gradient_id+"-link-"+t.index})).attr("gradientUnits","userSpaceOnUse").call((function(t){return t.append("stop").attr("offset","0%").attr("stop-color",(function(t){return g[t.source.name]}))})).call((function(t){return t.append("stop").attr("offset","100%").attr("stop-color",(function(t){return g[t.target.name]}))})),v.exit().remove()}v.enter().append("path").classed("link",!0).attr("d",jI()).attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-line-"+t.index)})).attr("class",(function(t){return a.alluvial.monochrome?e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:0,originalClassName:"link"}):e.model.getColorClassName({classNameTypes:[j.STROKE],dataGroupName:t.source.index,originalClassName:"link"})})).style("stroke",(function(t){return u?"url(#"+e.gradient_id+"-link-"+t.index+")":e.model.getFillColor(t.source.name)})).attr("stroke-width",(function(t){return Math.max(1,t.width)})).style("stroke-opacity",Mt.opacity.default).attr("aria-label",(function(t){return t.source.name+" → "+t.target.name+" ("+t.value+(a.alluvial.units?" "+a.alluvial.units:"")+")"}));var m=n.append("g").selectAll("g").data(this.graph.nodes).enter().append("g").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-"+t.index)})).classed("node-group",!0).attr("transform",(function(t){return"translate("+t.x0+", "+t.y0+")"}));m.append("rect").classed("node",!0).attr("height",(function(t){return t.y1-t.y0})).attr("width",(function(t){return t.x1-t.x0})).attr("fill","black");var y=m.append("g").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-title-"+t.index)}));y.append("text").attr("id",(function(t){return e.services.domUtils.generateElementIDString("alluvial-node-text-"+t.index)})).attr("class","node-text").style("font-size","12px").attr("text-anchor","start").attr("fill","white").attr("x",4).attr("dy",13).text((function(t){return t.name+" ("+t.value+")"})).attr("aria-label",(function(t){return t.name+" ("+t.value+")"})),y.append("rect").classed("node-text-bg",!0).attr("width",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-node-text-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width;return i+8})).attr("height",18).attr("stroke-width",2).lower(),y.attr("transform",(function(t,n){var r=e.services.domUtils.generateElementIDString("alluvial-node-text-"+n),i=sb.getSVGElementSize(eb("text#"+r),{useBBox:!0}).width,o=(t.y1-t.y0)/2-9,a=t.x1-t.x0;return t.x1>=i?a-=i+16:a+=4,"translate("+a+", "+o+")"})),this.addLineEventListener(),this.addNodeEventListener()}},e.prototype.addLineEventListener=function(){var t=this.getOptions(),e=this,n=Te((function(t,n){void 0===n&&(n="mouseover");var r=e.parent.selectAll("path.link").transition().call((function(t){return e.services.transitions.setupTransition({transition:t,name:"alluvial-links-mouse-highlight"})}));"mouseout"===n?(eb(t).lower(),r.style("stroke-opacity",Mt.opacity.default)):r.style("stroke-opacity",(function(){return t===this?(eb(this).raise(),Mt.opacity.selected):Mt.opacity.unfocus}))}),33);this.parent.selectAll("path.link").on("mouseover",(function(r,i){var o=eb(this);n(this,"mouseover"),o.classed("link-hovered",!0);var a=getComputedStyle(this).getPropertyValue("stroke");e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEOVER,{event:r,element:o,datum:i}),e.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:r,hoveredElement:o,items:[{label:i.target.name,value:i.value+(t.alluvial.units?" "+t.alluvial.units:""),color:a,labelIcon:e.getRightArrowIcon()}]})})).on("mousemove",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEMOVE,{event:t,element:eb(this),datum:n}),e.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.LINE_CLICK,{event:t,element:eb(this),datum:n})})).on("mouseout",(function(t,r){var i=eb(this);n(this,"mouseout"),i.classed("link-hovered",!1),e.services.events.dispatchEvent(ft.Alluvial.LINE_MOUSEOUT,{event:t,element:i,datum:r}),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:t,hoveredElement:i})}))},e.prototype.addNodeEventListener=function(){var t=this,e=this,n=Te((function(n,r){if(void 0===n&&(n=[]),void 0===r&&(r="mouseover"),"mouseout"!==r&&0!==n.length){var i=e.parent.selectAll("path.link").transition().call((function(e){return t.services.transitions.setupTransition({transition:e,name:"alluvial-link-mouse-highlight"})}));i.style("stroke-opacity",(function(t){return n.some((function(e){return e===t.index}))?(eb(this).classed("link-hovered",!0).raise(),Mt.opacity.selected):Mt.opacity.unfocus}))}else e.parent.selectAll("path.link").classed("link-hovered",!1).data(t.graph.links,(function(t){return t.index})).order().style("stroke-opacity",Mt.opacity.default)}),66);e.parent.selectAll(".node-group").on("mouseover",(function(t,r){var i=eb(this),o=[];if(e.traverse({link:"sourceLinks",node:"target"},r,o),e.traverse({link:"targetLinks",node:"source"},r,o),o.length){var a=Md(i.attr("transform"));if(i.attr("transform","translate("+(a.x-2)+", "+a.y+")"),i.classed("node-hovered",!0).selectAll("rect.node").attr("width",8),r.x0-2===0){var s=e.services.domUtils.generateElementIDString("alluvial-node-title-"+r.index),u=e.parent.select("g#"+s),l=Md(u.attr("transform"));u.attr("transform","translate("+(l.x+4)+","+l.y+")")}var c=e.services.domUtils.generateElementIDString("alluvial-node-text-"+r.index);e.parent.select("text#"+c).style("font-weight","bold"),n(o,"mouseover"),e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEOVER,{event:t,element:i,datum:r})}})).on("mousemove",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEMOVE,{event:t,element:eb(this),datum:n}),e.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,n){e.services.events.dispatchEvent(ft.Alluvial.NODE_CLICK,{event:t,element:eb(this),datum:n})})).on("mouseout",(function(t,r){var i=eb(this),o=Md(i.attr("transform"));if(i.classed("node-hovered",!1).attr("transform","translate("+(o.x+2)+", "+o.y+")").select("rect.node").attr("width",Mt.nodeWidth),r.x0-2===0){var a=e.services.domUtils.generateElementIDString("alluvial-node-title-"+r.index),s=e.parent.select("g#"+a),u=Md(s.attr("transform"));s.attr("transform","translate("+(u.x-4)+","+u.y+")")}var l=e.services.domUtils.generateElementIDString("alluvial-node-text-"+r.index);e.parent.select("text#"+l).style("font-weight","normal"),n([],"mouseout"),e.services.events.dispatchEvent(ft.Alluvial.NODE_MOUSEOUT,{event:t,element:i,datum:r}),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i})}))},e.prototype.traverse=function(t,e,n){var r=this;void 0===n&&(n=[]);var i=e[t.link].map((function(e){return n.push(e.index),e[t.node]}));i.forEach((function(e){return r.traverse(t,e,n)}))},e.prototype.getRightArrowIcon=function(){return'\n\t\t<svg xmlns="http://www.w3.org/2000/svg" class="arrow-right" width="32" height="32" viewBox="0 0 32 32">\n\t\t\t<polygon points="18 6 16.57 7.393 24.15 15 4 15 4 17 24.15 17 16.57 24.573 18 26 28 16 18 6"/>\n\t\t\t<rect width="32" height="32"/>\n\t\t</svg>'},e.prototype.destroy=function(){this.parent.selectAll("path.line,.node-group").on("mouseover",null).on("mousemove",null).on("click",null).on("mouseout",null)},e}(DS),VI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="heatmap",e.renderType=I.SVG,e.matrix={},e.xBandwidth=0,e.yBandwidth=0,e.translationUnits={x:0,y:0},e.handleAxisOnHover=function(t){var n=t.detail,r=n.datum,i=e.model.getUniqueRanges(),o=e.model.getUniqueDomain(),a=e.services.cartesianScales.getDomainLabel(),s=e.services.cartesianScales.getRangeLabel(),u=e.services.cartesianScales.getMainXScale(),l=e.services.cartesianScales.getMainYScale(),c="",h=null,f=null,p=null;void 0!==e.matrix[r]?(c=a,i.forEach((function(t){if("number"===typeof e.matrix[r][t].value){var n=e.matrix[r][t].value;if(null===h)return h=n,f=n,void(p=n);h+=n,f=n<f?n:f,p=n>p?n:p}}))):(c=s,o.forEach((function(t){if("number"===typeof e.matrix[t][r].value){var n=e.matrix[t][r].value;if(null===h)return h=n,f=n,void(p=n);h+=n,f=n<f?n:f,p=n>p?n:p}}))),void 0!==u(r)?e.parent.select("g.multi-cell.column-highlight").classed("highlighter-hidden",!1).attr("transform","translate("+u(r)+", "+Vm(l.range())+")"):void 0!==l(r)&&e.parent.select("g.multi-cell.row-highlight").classed("highlighter-hidden",!1).attr("transform","translate("+Vm(u.range())+","+l(r)+")"),e.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:n.event,hoveredElement:eb(t.detail.element),items:[{label:c,value:r,bold:!0},{label:"Min",value:null!==f?f:"-"},{label:"Max",value:null!==p?p:"-"},{label:"Average",value:null!==h?h/o.length:"-"}]})},e.handleAxisMouseOut=function(t){e.parent.selectAll("g.multi-cell").classed("highlighter-hidden",!0),e.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:t})},e}return VI(e,t),e.prototype.init=function(){var t=this.services.events;t.addEventListener(ft.Axis.LABEL_MOUSEOVER,this.handleAxisOnHover),t.addEventListener(ft.Axis.LABEL_MOUSEOUT,this.handleAxisMouseOut),t.addEventListener(ft.Axis.LABEL_FOCUS,this.handleAxisOnHover),t.addEventListener(ft.Axis.LABEL_BLUR,this.handleAxisMouseOut)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer({withinChartClip:!0});n.lower();var r=this.services.cartesianScales;if(this.matrix=this.model.getMatrix(),n.html(""),!Dd(this.getOptions(),"data","loading")){var i=r.getMainXScale(),o=r.getMainYScale(),a=r.getDomainIdentifier(),s=r.getRangeIdentifier(),u=this.model.getUniqueDomain(),l=this.model.getUniqueRanges(),c=this.model.getMatrixAsArray(),h=i.range(),f=o.range();this.xBandwidth=Math.abs((h[1]-h[0])/u.length),this.yBandwidth=Math.abs((f[1]-f[0])/l.length);var p=this.services.domUtils.generateElementIDString("heatmap-pattern-stripes");n.append("defs").append("pattern").attr("id",p).attr("width",3).attr("height",3).attr("patternUnits","userSpaceOnUse").attr("patternTransform","rotate(45)").append("rect").classed("pattern-fill",!0).attr("width",.5).attr("height",8);var d=n.selectAll().data(c).enter().append("g").attr("class",(function(t){return"heat-"+t.index})).classed("cell",!0).attr("transform",(function(t){return"translate("+i(t[a])+", "+o(t[s])+")"})).append("rect").attr("class",(function(t){return e.model.getColorClassName({value:t.value,originalClassName:"heat-"+t.index})})).classed("heat",!0).classed("null-state",(function(t){return-1===t.index||null===t.value})).attr("width",this.xBandwidth).attr("height",this.yBandwidth).style("fill",(function(t){return-1===t.index||null===t.value?"url(#"+p+")":e.model.getFillColor(Number(t.value))})).attr("aria-label",(function(t){return t.value}));this.createOuterBox("g.cell-highlight",this.xBandwidth,this.yBandwidth),this.createOuterBox("g.multi-cell.column-highlight",this.xBandwidth,Math.abs(f[1]-f[0])),this.createOuterBox("g.multi-cell.row-highlight",Math.abs(h[1]-h[0]),this.yBandwidth),this.determineDividerStatus()&&(d.style("stroke-width","1px"),this.parent.select("g.cell-highlight").classed("cell-2",!0)),this.addEventListener()}},e.prototype.createOuterBox=function(t,e,n){var r=sb.appendOrSelect(this.parent,t).classed("shadows",!0).classed("highlighter-hidden",!0);sb.appendOrSelect(r,"line.top").attr("x1",-1).attr("x2",e+1),sb.appendOrSelect(r,"line.left").attr("x1",0).attr("y1",-1).attr("x2",0).attr("y2",n+1),sb.appendOrSelect(r,"line.down").attr("x1",-1).attr("x2",e+1).attr("y1",n).attr("y2",n),sb.appendOrSelect(r,"line.right").attr("x1",e).attr("x2",e).attr("y1",-1).attr("y2",n+1)},e.prototype.determineDividerStatus=function(){var t=Dd(this.getOptions(),"heatmap","divider","state");return t!==lt.OFF&&(t===lt.AUTO&&Ct.minCellDividerDimension<=this.xBandwidth&&Ct.minCellDividerDimension<=this.yBandwidth||t===lt.ON)},e.prototype.addEventListener=function(){var t=this,e=this.services.cartesianScales,n=this.getOptions(),r=tl(n,"tooltip.totalLabel"),i=e.getDomainIdentifier(),o=e.getRangeIdentifier(),a=e.getDomainLabel(),s=e.getRangeLabel();this.parent.selectAll("g.cell").on("mouseover",(function(e,n){var u=eb(this),l=u.select("rect.heat"),c=l.classed("null-state");if(!c){var h=Md(u.attr("transform"));t.parent.select("g.cell-highlight").attr("transform","translate("+(h.x+t.translationUnits.x)+", "+(h.y+t.translationUnits.y)+")").classed("highlighter-hidden",!1),t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEOVER,{event:e,element:l,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:e,items:[{label:a,value:n[i]},{label:s,value:n[o]},{label:r||"Total",value:n["value"],color:l.style("fill")}]})}})).on("mousemove",(function(e,n){t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEMOVE,{event:e,element:eb(this),datum:n}),t.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:e})})).on("click",(function(e,n){t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_CLICK,{event:e,element:eb(this),datum:n})})).on("mouseout",(function(e,n){var r=eb(this),i=r.select("rect.heat"),o=i.classed("null-state");t.parent.select("g.cell-highlight").classed("highlighter-hidden",!0),o||(t.services.events.dispatchEvent(ft.Heatmap.HEATMAP_MOUSEOUT,{event:e,element:i,datum:n}),t.services.events.dispatchEvent(ft.Tooltip.HIDE,{event:e,hoveredElement:i}))}))},e.prototype.destroy=function(){this.parent.selectAll("rect.heat").on("mouseover",null).on("mousemove",null).on("click",null).on("mouseout",null);var t=this.services.events;t.removeEventListener(ft.Legend.ITEM_HOVER,this.handleAxisOnHover),t.removeEventListener(ft.Legend.ITEM_MOUSEOUT,this.handleAxisMouseOut)},e}(DS),GI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),zI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="spacer",e}return GI(e,t),e.prototype.render=function(){this.getComponentContainer().style("width",(this.configs.size||At.default.size)+"px").style("height",(this.configs.size||At.default.size)+"px").attr("opacity",0)},e}(DS),FI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),WI=function(t){function e(n,r,i,o){var a=t.call(this,n,r,o)||this;return a.type="layout",a.configs=o,a.children=i,a._instanceID=e.instanceID++,a.init(),a}return FI(e,t),e.prototype.init=function(){this.children.forEach((function(t){t.components.forEach((function(t){t.init()}))}))},e.prototype.getPreferedAndFixedSizeSum=function(){var t=this.parent,e=0;return t.selectAll("div.layout-child-"+this._instanceID).filter((function(t){var e=Dd(t,"growth");return e===Y.PREFERRED||e===Y.FIXED})).each((function(t){e+=t.size})),e},e.prototype.getNumOfStretchChildren=function(){var t=this.parent;return t.selectAll("div.layout-child-"+this._instanceID).filter((function(t){return Dd(t,"growth")===Y.STRETCH})).size()},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.parent,r=sb.getHTMLElementSize(n.node()),i=r.width,o=r.height,a=this.configs.direction===$.ROW||this.configs.direction===$.ROW_REVERSE,s=Dd(this.model.getOptions(),"style","prefix"),u=n.classed(dt+"--"+s+"--layout-row",this.configs.direction===$.ROW).classed(dt+"--"+s+"--layout-row-reverse",this.configs.direction===$.ROW_REVERSE).classed(dt+"--"+s+"--layout-column",this.configs.direction===$.COLUMN).classed(dt+"--"+s+"--layout-column-reverse",this.configs.direction===$.COLUMN_REVERSE).classed(dt+"--"+s+"--layout-alignitems-center",this.configs.alignItems===Z.CENTER).selectAll("div.layout-child-"+this._instanceID).data(this.children,(function(t){return t.id})),l=u.enter().append("div");l.merge(n.selectAll("div.layout-child-"+this._instanceID)).attr("class",(function(t){return"layout-child layout-child-"+e._instanceID+" "+t.id})).each((function(e){var n=this;e.components.forEach((function(r){var i=eb(n),o=Dd(e,"renderType"),a=o===I.SVG;r.setParent(a?sb.appendOrSelect(i,"svg.layout-svg-wrapper").attr("width","100%").attr("height","100%"):i);var s=Dd(e,"growth");s!==Y.PREFERRED&&s!==Y.FIXED||r.render(t)}))})),n.selectAll("div.layout-child-"+this._instanceID).style("height",null).style("width",null).each((function(t){var e=Dd(t,"growth"),n=Dd(t,"renderType"),r=n===I.SVG?sb.getSVGElementSize(eb(this).select("svg.layout-svg-wrapper"),{useBBox:!0}):sb.getHTMLElementSize(this);if(e===Y.PREFERRED){var s=a?r.width:r.height,u=a?i:o;t.size=s/u*100}})),u.exit().remove(),this.children.filter((function(t){var e=Dd(t,"growth");return e===Y.STRETCH})).forEach((function(t,n){t.size=(100-+e.getPreferedAndFixedSizeSum())/+e.getNumOfStretchChildren()}));var c=n.selectAll("div.layout-child-"+this._instanceID).data(this.children,(function(t){return t.id}));a?c.style("width",(function(t){return t.size/100*i+"px"})).style("height","100%"):c.style("height",(function(t){return t.size/100*o+"px"})).style("width","100%"),c.each((function(e,n){e.components.forEach((function(n){var r=Dd(e,"growth");r===Y.STRETCH&&n.render(t)}))}))},e.prototype.setModel=function(e){t.prototype.setModel.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setModel(e)}))}))},e.prototype.setServices=function(e){t.prototype.setServices.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setServices(e)}))}))},e.prototype.destroy=function(){this.children.forEach((function(t){t.components.forEach((function(t){return t.destroy()}))}))},e.instanceID=Math.floor(99999999999*Math.random()),e}(DS),qI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),$I=function(t){function e(e,n,r){var i,o=t.call(this,e,n,r)||this;return o.type="axes",o.renderType=I.SVG,o.truncation=(i={},i[B.LEFT]=!1,i[B.RIGHT]=!1,i[B.TOP]=!1,i[B.BOTTOM]=!1,i),r&&(o.configs=r),o.margins=o.configs.margins,o}return qI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n,r,i=this.configs.position,o=this.getOptions(),s=Dd(o,"axes",i,"visible"),u=this.getComponentContainer(),l=sb.getSVGElementSize(u,{useAttrs:!0}),c=l.width,h=l.height,f=sb.appendOrSelect(u,"g.axis."+i);i===B.BOTTOM||i===B.TOP?(n=this.configs.axes[B.LEFT]?this.margins.left:0,r=this.configs.axes[B.RIGHT]?c-this.margins.right:c):(n=h-this.margins.bottom,r=this.margins.top);var p,d=this.services.cartesianScales.getScaleByPosition(i);switch(this.scaleType===G.LABELS||this.scaleType===G.LABELS_RATIO?d.rangeRound([n,r]):d.range([n,r]),i){case B.LEFT:p=ZS;break;case B.BOTTOM:p=YS;break;case B.RIGHT:p=$S;break;case B.TOP:p=qS;break}f.attr("aria-label",i+" axis");var v=!f.select("g.ticks").empty(),g=sb.appendOrSelect(f,"g.ticks");v||(g.attr("role",a.GRAPHICS_OBJECT+" "+a.GROUP),g.attr("aria-label",i+" ticks"));var m=sb.appendOrSelect(f,"g.ticks.invisible").style("opacity","0").style("pointer-events","none").attr("aria-hidden",!0).attr("aria-label","invisible "+i+" ticks"),y=Dd(o,"axes",i),_=this.scaleType===G.TIME||y.scaleType===G.TIME,b=i===B.LEFT||i===B.RIGHT,w=this.model.get("zoomDomain");if(w&&_&&!b&&d.domain(w),s){var O=Dd(y,"scaleType"),x=Dd(o,"data","loading"),E=Dd(y,"ticks","number"),T=Dd(y,"ticks","values"),S=Dd(y,"truncation","type"),M=Dd(y,"truncation","threshold"),C=Dd(y,"truncation","numCharacter"),A=null!==E,L=Dd(o,"timeScale"),D=sb.appendOrSelect(m,"g.tick"),k=sb.appendOrSelect(D,"text").text("0"),P=sb.getSVGElementSize(k.node(),{useBBox:!0}).height;D.remove();var R,I=this.scaleType||y.scaleType||G.LINEAR,N=p(d).tickSizeOuter(0);if(d.ticks){var j=void 0;if(A?j=E:(j=gt.ticks.number,b&&(j=this.getNumberOfFittingTicks(h,P,gt.ticks.verticalSpaceRatio))),1===d.ticks().length&&0===d.ticks()[0]&&(j=0),N.ticks(j),_)if(d.ticks(j).length){var U=Dd(o,"timeScale","addSpaceOnEdges"),H=Dd(o,"axes",i,"domain"),z=void 0,F=d.copy();U&&!H&&F.nice(j),z=F.ticks(j),U&&z.length>2&&!H&&(z.splice(z.length-1,1),z.splice(0,1)),N.tickValues(z)}else N.tickValues([])}var W=Dd(y,"ticks","formatter");if(_){var q=$m(N.tickValues());R=null===W?function(t,e){return zm(t,e,N.tickValues(),q,L)}:function(t,e){var n=zm(t,e,N.tickValues(),q,L);return W(t,e,n)}}else null===W?I===G.LINEAR&&(R=function(t){return t.toLocaleString()}):R=W;N.tickFormat(R);var $,Y=this.services.cartesianScales.getScaleByPosition(i).domain(),Z=Y[0],X=Y[1];if(T){if(_)T.forEach((function(t,e){void 0===t.getTime&&(T[e]=new Date(t))})),$=T.filter((function(t){var e=t.getTime();return e>=new Date(Z).getTime()&&e<=new Date(X).getTime()}));else if(O===G.LABELS){var K=this.services.cartesianScales.getScaleByPosition(i).domain();$=T.filter((function(t){return K.includes(t)}))}else $=T.filter((function(t){return t>=Z&&t<=X}));N.tickValues($)}switch(i){case B.LEFT:g.attr("transform","translate("+this.margins.left+", 0)");break;case B.BOTTOM:g.attr("transform","translate(0, "+(h-this.margins.bottom)+")");break;case B.RIGHT:g.attr("transform","translate("+(c-this.margins.right)+", 0)");break;case B.TOP:g.attr("transform","translate(0, "+this.margins.top+")");break}var Q=this.model.isDataEmpty();if(y.title){var J=sb.appendOrSelect(f,"text.axis-title").html(Q||x?"":y.title),tt=Dd(y,"titleOrientation");switch(i){case B.LEFT:tt===at.RIGHT?J.attr("transform","rotate(90)").attr("y",0).attr("x",d.range()[0]/2).attr("dy","-0.5em").style("text-anchor","middle"):J.attr("transform","rotate(-90)").attr("y",0).attr("x",-d.range()[0]/2).attr("dy","0.75em").style("text-anchor","middle");break;case B.BOTTOM:J.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+(h+4)+")").style("text-anchor","middle");break;case B.RIGHT:tt===at.LEFT?J.attr("transform","rotate(-90)").attr("y",c).attr("x",-d.range()[0]/2).style("text-anchor","middle"):J.attr("transform","rotate(90)").attr("y",-c).attr("x",d.range()[0]/2).attr("dy","0.75em").style("text-anchor","middle");break;case B.TOP:var et=sb.getSVGElementSize(J,{useBBox:!0}).height;J.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+et/2+")").style("text-anchor","middle");break}}if(_){var nt=$m(N.tickValues()),it=L.showDayName,ot=g;t&&(g=g.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"axis-update",animate:t})}))),g=g.call(N);var st=ot.selectAll(".tick").data(N.tickValues(),d).order().select("text");st.style("font-weight",(function(t,e){return Gm(t,e,N.tickValues(),nt,it)?"bold":"normal"}))}else g=t&&v?g.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"axis-update",animate:t})})).call(N):g.call(N);if(m.call(N),i===B.BOTTOM||i===B.TOP){var ut=!1,lt=Dd(y,"ticks","rotation");if(lt===rt.ALWAYS)ut=!0;else if(lt===rt.NEVER)ut=!1;else if(!lt||lt===rt.AUTO)if(d.step){var ct=m.selectAll("g.tick text").nodes();ut=ct.some((function(t){return sb.getSVGElementSize(t,{useBBox:!0}).width>=d.step()}))}else{ut=!1;var ht,ft=m.append("text").text("A"),pt=sb.getSVGElementSize(ft.node(),{useBBox:!0}).width;m.selectAll("g.tick").each((function(){var t=eb(this),e=parseFloat(Dd(Sd(this),"tx"));null!==e&&ht+t.text().length*pt*.8>=e&&(ut=!0),ht=e})),ft.remove()}ut?(A||(N.ticks(this.getNumberOfFittingTicks(c,P,gt.ticks.horizontalSpaceRatio)),m.call(N),g.call(N)),f.selectAll("g.ticks g.tick text").attr("transform","rotate(-45)").attr("text-anchor",i===B.TOP?"start":"end")):f.selectAll("g.ticks g.tick text").attr("transform",null).attr("text-anchor",null)}if(x?f.attr("opacity",0):f.attr("opacity",1),g.selectAll("g.tick").attr("aria-label",(function(t){return t})),m.selectAll("g.tick").attr("aria-label",(function(t){return t})),S!==V.NONE&&O===G.LABELS&&!T){var dt=this.services.cartesianScales.getScaleDomain(i);if(dt.length>0){var vt=u.select("g.axis."+i+" g.ticks g.tick").html();f.selectAll("g.ticks g.tick").html(vt);var mt=this;f.selectAll("g.tick text").data(dt).text((function(t){return t.length>M?(mt.truncation[i]=!0,Ad(t,S,C)):t})),this.getInvisibleAxisRef().selectAll("g.tick text").data(dt).text((function(t){return t.length>M?Ad(t,S,C):t})),f.selectAll("g.ticks").html(this.getInvisibleAxisRef().html()),f.selectAll("g.tick text").data(dt)}}this.addEventListeners()}else g.attr("aria-hidden",!0)},e.prototype.addEventListeners=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e),r=this.getOptions(),i=Dd(r,"axes",e),o=Dd(i,"scaleType"),a=Dd(i,"truncation","threshold"),s=this;n.selectAll("g.tick text").on("mouseover",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOVER,{event:t,element:eb(this),datum:e}),o===G.LABELS&&e.length>a&&s.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:eb(this),content:e})})).on("mousemove",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEMOVE,{event:t,element:eb(this),datum:e}),o===G.LABELS&&e.length>a&&s.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOUT,{event:t,element:eb(this),datum:e}),o===G.LABELS&&s.services.events.dispatchEvent(ft.Tooltip.HIDE)}))},e.prototype.getInvisibleAxisRef=function(){var t=this.configs.position;return this.getComponentContainer().select("g.axis."+t+" g.ticks.invisible")},e.prototype.getTitleRef=function(){var t=this.configs.position;return this.getComponentContainer().select("g.axis."+t+" text.axis-title")},e.prototype.getNumberOfFittingTicks=function(t,e,n){var r=Math.floor(t/(e*n));return aa(r,2,gt.ticks.number)},e.prototype.destroy=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e);n.selectAll("g.tick text").on("mouseover",null).on("mousemove",null).on("mouseout",null)},e}(DS),YI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ZI=function(){return ZI=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},ZI.apply(this,arguments)},XI=function(t){function e(e,n,r){return t.call(this,e,n,r)||this}return YI(e,t),e.prototype.render=function(e){void 0===e&&(e=!0),t.prototype.render.call(this,e),t.prototype.destroy.call(this);var n=this.configs.position,r=this.getComponentContainer(),i=sb.appendOrSelect(r,"g.axis."+n),o=this;i.selectAll("g.tick").each((function(t,e){var r=eb(this);r.classed("tick-hover",!0).attr("tabindex",0===e?0:-1);var i=r.select("text"),a=sb.getSVGElementSize(i,{useBBox:!0}),s=a.width,u=a.height,l=sb.appendOrSelect(r,"rect.axis-holder"),c=0,h=0;switch(n){case B.LEFT:c=-s+Number(i.attr("x")),h=-u/2;break;case B.RIGHT:c=Math.abs(Number(i.attr("x"))),h=-u/2;break;case B.TOP:c=-s/2,h=-u+Number(i.attr("y"))/2,o.truncation[n]&&(c=0,l.attr("transform","rotate(-45)"));break;case B.BOTTOM:c=-s/2,h=u/2-2,o.truncation[n]&&(c=-s,l.attr("transform","rotate(-45)"));break}l.attr("x",c-gt.hover.rectanglePadding).attr("y",h).attr("width",s+2*gt.hover.rectanglePadding).attr("height",u).lower()})),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e),r=this.getOptions(),i=Dd(r,"axes",e),o=Dd(i,"scaleType"),a=Dd(i,"truncation","threshold"),s=this;n.selectAll("g.tick.tick-hover").on("mouseover",(function(t){var e=eb(this).select("text"),n=e.datum();s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOVER,{event:t,element:e,datum:n}),o===G.LABELS&&n.length>a&&s.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,element:e,datum:n})})).on("mousemove",(function(t){var e=eb(this).select("text"),n=e.datum();s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEMOVE,{event:t,element:e,datum:n}),s.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_CLICK,{event:t,element:eb(this).select("text"),datum:eb(this).select("text").datum()})})).on("mouseout",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_MOUSEOUT,{event:t,element:eb(this).select("text"),datum:eb(this).select("text").datum()}),o===G.LABELS&&s.services.events.dispatchEvent(ft.Tooltip.HIDE)})).on("focus",(function(t){var e={clientX:0,clientY:0};if(t.target){t.target.focus();var n=t.target.getBoundingClientRect();e.clientX=n.x,e.clientY=n.y}s.services.events.dispatchEvent(ft.Axis.LABEL_FOCUS,{event:ZI(ZI({},t),e),element:eb(this),datum:eb(this).select("text").datum()})})).on("blur",(function(t){s.services.events.dispatchEvent(ft.Axis.LABEL_BLUR,{event:t,element:eb(this),datum:eb(this).select("text").datum()})})).on("keydown",(function(t){t.key&&"Escape"===t.key&&(s.services.events.dispatchEvent(ft.Tooltip.HIDE),s.services.events.dispatchEvent(ft.Axis.LABEL_BLUR,{event:t,element:eb(this),datum:eb(this).select("text").datum()})),e===B.LEFT||e===B.RIGHT?t.key&&"ArrowUp"===t.key?s.goNext(this,t):t.key&&"ArrowDown"===t.key&&s.goPrevious(this,t):t.key&&"ArrowLeft"===t.key?s.goPrevious(this,t):t.key&&"ArrowRight"===t.key&&s.goNext(this,t)}))},e.prototype.goNext=function(t,e){t.nextElementSibling&&"path"!==t.nextElementSibling.tagName&&t.nextElementSibling.dispatchEvent(new Event("focus")),e.preventDefault()},e.prototype.goPrevious=function(t,e){t.previousElementSibling&&"path"!==t.previousElementSibling.tagName&&t.previousElementSibling.dispatchEvent(new Event("focus")),e.preventDefault()},e.prototype.destroy=function(){var t=this.getComponentContainer(),e=this.configs.position,n=sb.appendOrSelect(t,"g.axis."+e);n.selectAll("g.tick.tick-hover").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("focus",null).on("blur",null)},e}($I),KI=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QI=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="2D-axes",e.renderType=I.SVG,e.children={},e.thresholds=[],e.margins={top:0,right:0,bottom:0,left:0},e}return KI(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n={},r=Object.keys(B),i=Dd(this.getOptions(),"axes");r.forEach((function(t){var e=i[B[t]];e&&(n[B[t]]=!0)})),this.configs.axes=n,r.forEach((function(t){var n=B[t];if(e.configs.axes[n]&&!e.children[n]){var r={position:n,axes:e.configs.axes,margins:e.margins},i=e.model.axisFlavor===ct.DEFAULT?new $I(e.model,e.services,r):new XI(e.model,e.services,r);i.setModel(e.model),i.setServices(e.services),i.setParent(e.parent),e.children[n]=i}})),Object.keys(this.children).forEach((function(n){var r=e.children[n];r.render(t)}));var o={};Object.keys(this.children).forEach((function(t){var n,r=e.children[t],i=r.configs.position,a=r.getInvisibleAxisRef(),s=sb.getSVGElementSize(a,{useBBox:!0}),u=s.width,l=s.height;switch(r.getTitleRef().empty()?n=0:(n=sb.getSVGElementSize(r.getTitleRef(),{useBBox:!0}).height,i!==B.LEFT&&i!==B.RIGHT||(n+=5)),i){case B.TOP:o.top=l+n;break;case B.BOTTOM:o.bottom=l+n;break;case B.LEFT:o.left=u+n;break;case B.RIGHT:o.right=u+n;break}})),this.services.events.dispatchEvent(ft.Axis.RENDER_COMPLETE);var a=Object.keys(o).some((function(t){return e.margins[t]!==o[t]}));a&&(this.margins=Object.assign(this.margins,o),this.model.set({axesMargins:this.margins},{skipUpdate:!0}),this.services.events.dispatchEvent(ft.ZoomBar.UPDATE),Object.keys(this.children).forEach((function(t){var n=e.children[t];n.margins=e.margins})),this.render(!0))},e}(DS),JI={value:()=>{}};function tN(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new eN(r)}function eN(t){this._=t}function nN(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function rN(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function iN(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=JI,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}eN.prototype=tN.prototype={constructor:eN,on:function(t,e){var n,r=this._,i=nN(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!==typeof e)throw new Error("invalid callback: "+e);while(++o<a)if(n=(t=i[o]).type)r[n]=iN(r[n],t.name,e);else if(null==e)for(n in r)r[n]=iN(r[n],t.name,null);return this}while(++o<a)if((n=(t=i[o]).type)&&(n=rN(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new eN(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(r=this._[t],o=0,n=r.length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var oN=tN;const aN={capture:!0,passive:!1};var sN=function(t){t.preventDefault(),t.stopImmediatePropagation()},uN=function(t){var e=t.document.documentElement,n=eb(t).on("dragstart.drag",sN,aN);"onselectstart"in e?n.on("selectstart.drag",sN,aN):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")};function lN(t,e){var n=t.document.documentElement,r=eb(t).on("dragstart.drag",null);e&&(r.on("click.drag",sN,aN),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}var cN,hN,fN=0,pN=0,dN=0,vN=1e3,gN=0,mN=0,yN=0,_N="object"===typeof performance&&performance.now?performance:Date,bN="object"===typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function wN(){return mN||(bN(ON),mN=_N.now()+yN)}function ON(){mN=0}function xN(){this._call=this._time=this._next=null}function EN(t,e,n){var r=new xN;return r.restart(t,e,n),r}function TN(){wN(),++fN;var t,e=cN;while(e)(t=mN-e._time)>=0&&e._call.call(void 0,t),e=e._next;--fN}function SN(){mN=(gN=_N.now())+yN,fN=pN=0;try{TN()}finally{fN=0,CN(),mN=0}}function MN(){var t=_N.now(),e=t-gN;e>vN&&(yN-=e,gN=t)}function CN(){var t,e,n=cN,r=1/0;while(n)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:cN=e);hN=t,AN(r)}function AN(t){if(!fN){pN&&(pN=clearTimeout(pN));var e=t-mN;e>24?(t<1/0&&(pN=setTimeout(SN,t-_N.now()-yN)),dN&&(dN=clearInterval(dN))):(dN||(gN=_N.now(),dN=setInterval(MN,vN)),fN=1,bN(SN))}}xN.prototype=EN.prototype={constructor:xN,restart:function(t,e,n){if("function"!==typeof t)throw new TypeError("callback is not a function");n=(null==n?wN():+n)+(null==e?0:+e),this._next||hN===this||(hN?hN._next=this:cN=this,hN=this),this._call=t,this._time=n,AN()},stop:function(){this._call&&(this._call=null,this._time=1/0,AN())}};var LN=function(t,e,n){var r=new xN;return e=null==e?0:+e,r.restart(n=>{r.stop(),t(n+e)},e,n),r},DN=oN("start","end","cancel","interrupt"),kN=[],PN=0,RN=1,IN=2,NN=3,jN=4,BN=5,UN=6,VN=function(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};FN(t,n,{name:e,index:r,group:i,on:DN,tween:kN,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:PN})};function HN(t,e){var n=zN(t,e);if(n.state>PN)throw new Error("too late; already scheduled");return n}function GN(t,e){var n=zN(t,e);if(n.state>NN)throw new Error("too late; already running");return n}function zN(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function FN(t,e,n){var r,i=t.__transition;function o(t){n.state=RN,n.timer.restart(a,n.delay,n.time),n.delay<=t&&a(t-n.delay)}function a(o){var l,c,h,f;if(n.state!==RN)return u();for(l in i)if(f=i[l],f.name===n.name){if(f.state===NN)return LN(a);f.state===jN?(f.state=UN,f.timer.stop(),f.on.call("interrupt",t,t.__data__,f.index,f.group),delete i[l]):+l<e&&(f.state=UN,f.timer.stop(),f.on.call("cancel",t,t.__data__,f.index,f.group),delete i[l])}if(LN((function(){n.state===NN&&(n.state=jN,n.timer.restart(s,n.delay,n.time),s(o))})),n.state=IN,n.on.call("start",t,t.__data__,n.index,n.group),n.state===IN){for(n.state=NN,r=new Array(h=n.tween.length),l=0,c=-1;l<h;++l)(f=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=f);r.length=c+1}}function s(e){var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(u),n.state=BN,1),o=-1,a=r.length;while(++o<a)r[o].call(t,i);n.state===BN&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){for(var r in n.state=UN,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=EN(o,0,n.time)}var WN,qN=function(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>IN&&n.state<BN,n.state=UN,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}},$N=function(t){return this.each((function(){qN(this,t)}))},YN=180/Math.PI,ZN={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},XN=function(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*YN,skewX:Math.atan(u)*YN,scaleX:a,scaleY:s}};function KN(t){const e=new("function"===typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?ZN:XN(e.a,e.b,e.c,e.d,e.e,e.f)}function QN(t){return null==t?ZN:(WN||(WN=document.createElementNS("http://www.w3.org/2000/svg","g")),WN.setAttribute("transform",t),(t=WN.transform.baseVal.consolidate())?(t=t.matrix,XN(t.a,t.b,t.c,t.d,t.e,t.f)):ZN)}function JN(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}function o(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:Ax(t,i)},{i:u-2,x:Ax(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}function a(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:Ax(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}function s(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:Ax(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}function u(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Ax(t,n)},{i:s-2,x:Ax(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}return function(e,n){var r=[],i=[];return e=t(e),n=t(n),o(e.translateX,e.translateY,n.translateX,n.translateY,r,i),a(e.rotate,n.rotate,r,i),s(e.skewX,n.skewX,r,i),u(e.scaleX,e.scaleY,n.scaleX,n.scaleY,r,i),e=n=null,function(t){var e,n=-1,o=i.length;while(++n<o)r[(e=i[n]).i]=e.x(t);return r.join("")}}}var tj=JN(KN,"px, ","px)","deg)"),ej=JN(QN,", ",")",")");function nj(t,e){var n,r;return function(){var i=GN(this,t),o=i.tween;if(o!==n){r=n=o;for(var a=0,s=r.length;a<s;++a)if(r[a].name===e){r=r.slice(),r.splice(a,1);break}}i.tween=r}}function rj(t,e,n){var r,i;if("function"!==typeof n)throw new Error;return function(){var o=GN(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}}var ij=function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=zN(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?nj:rj)(n,t,e))};function oj(t,e,n){var r=t._id;return t.each((function(){var t=GN(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return zN(t,r).value[e]}}var aj=function(t,e){var n;return("number"===typeof e?Ax:e instanceof XO?xx:(n=XO(e))?(e=n,xx):Ix)(t,e)};function sj(t){return function(){this.removeAttribute(t)}}function uj(t){return function(){this.removeAttributeNS(t.space,t.local)}}function lj(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function cj(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function hj(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return a=this.getAttribute(t),s=u+"",a===s?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function fj(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return a=this.getAttributeNS(t.space,t.local),s=u+"",a===s?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}var pj=function(t,e){var n=zy(t),r="transform"===n?ej:aj;return this.attrTween(t,"function"===typeof e?(n.local?fj:hj)(n,r,oj(this,"attr."+t,e)):null==e?(n.local?uj:sj)(n):(n.local?cj:lj)(n,r,e))};function dj(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function vj(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function gj(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&vj(t,i)),n}return i._value=e,i}function mj(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&dj(t,i)),n}return i._value=e,i}var yj=function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!==typeof e)throw new Error;var r=zy(t);return this.tween(n,(r.local?gj:mj)(r,e))};function _j(t,e){return function(){HN(this,t).delay=+e.apply(this,arguments)}}function bj(t,e){return e=+e,function(){HN(this,t).delay=e}}var wj=function(t){var e=this._id;return arguments.length?this.each(("function"===typeof t?_j:bj)(e,t)):zN(this.node(),e).delay};function Oj(t,e){return function(){GN(this,t).duration=+e.apply(this,arguments)}}function xj(t,e){return e=+e,function(){GN(this,t).duration=e}}var Ej=function(t){var e=this._id;return arguments.length?this.each(("function"===typeof t?Oj:xj)(e,t)):zN(this.node(),e).duration};function Tj(t,e){if("function"!==typeof e)throw new Error;return function(){GN(this,t).ease=e}}var Sj=function(t){var e=this._id;return arguments.length?this.each(Tj(e,t)):zN(this.node(),e).ease};function Mj(t,e){return function(){var n=e.apply(this,arguments);if("function"!==typeof n)throw new Error;GN(this,t).ease=n}}var Cj=function(t){if("function"!==typeof t)throw new Error;return this.each(Mj(this._id,t))},Aj=function(t){"function"!==typeof t&&(t=ly(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new iB(r,this._parents,this._name,this._id)},Lj=function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],h=l.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=l[p]||c[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new iB(a,this._parents,this._name,this._id)};function Dj(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}function kj(t,e,n){var r,i,o=Dj(e)?HN:GN;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var Pj=function(t,e){var n=this._id;return arguments.length<2?zN(this.node(),n).on.on(t):this.each(kj(n,t,e))};function Rj(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}var Ij=function(){return this.on("end.remove",Rj(this._id))},Nj=function(t){var e=this._name,n=this._id;"function"!==typeof t&&(t=ny(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,l=r[a],c=l.length,h=o[a]=new Array(c),f=0;f<c;++f)(s=l[f])&&(u=t.call(s,s.__data__,f,l))&&("__data__"in s&&(u.__data__=s.__data__),h[f]=u,VN(h[f],e,n,f,h,zN(s,n)));return new iB(o,this._parents,e,n)},jj=function(t){var e=this._name,n=this._id;"function"!==typeof t&&(t=ay(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,l=r[s],c=l.length,h=0;h<c;++h)if(u=l[h]){for(var f,p=t.call(u,u.__data__,h,l),d=zN(u,n),v=0,g=p.length;v<g;++v)(f=p[v])&&VN(f,e,n,v,p,d);o.push(p),a.push(u)}return new iB(o,a,e,n)},Bj=tb.prototype.constructor,Uj=function(){return new Bj(this._groups,this._parents)};function Vj(t,e){var n,r,i;return function(){var o=n_(this,t),a=(this.style.removeProperty(t),n_(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}function Hj(t){return function(){this.style.removeProperty(t)}}function Gj(t,e,n){var r,i,o=n+"";return function(){var a=n_(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}function zj(t,e,n){var r,i,o;return function(){var a=n_(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=n_(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}function Fj(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=GN(this,t),l=u.on,c=null==u.value[a]?o||(o=Hj(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}var Wj=function(t,e,n){var r="transform"===(t+="")?tj:aj;return null==e?this.styleTween(t,Vj(t,r)).on("end.style."+t,Hj(t)):"function"===typeof e?this.styleTween(t,zj(t,r,oj(this,"style."+t,e))).each(Fj(this._id,t)):this.styleTween(t,Gj(t,r,e),n).on("end.style."+t,null)};function qj(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function $j(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&qj(t,o,n)),r}return o._value=e,o}var Yj=function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!==typeof e)throw new Error;return this.tween(r,$j(t,e,null==n?"":n))};function Zj(t){return function(){this.textContent=t}}function Xj(t){return function(){var e=t(this);this.textContent=null==e?"":e}}var Kj=function(t){return this.tween("text","function"===typeof t?Xj(oj(this,"text",t)):Zj(null==t?"":t+""))};function Qj(t){return function(e){this.textContent=t.call(this,e)}}function Jj(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&Qj(r)),e}return r._value=t,r}var tB=function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!==typeof t)throw new Error;return this.tween(e,Jj(t))},eB=function(){for(var t=this._name,e=this._id,n=aB(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=zN(a,e);VN(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new iB(r,this._parents,t,n)},nB=function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0===--i&&o()}};n.each((function(){var n=GN(this,r),i=n.on;i!==t&&(e=(t=i).copy(),e._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e})),0===i&&o()}))},rB=0;function iB(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function oB(t){return tb().transition(t)}function aB(){return++rB}var sB=tb.prototype;iB.prototype=oB.prototype={constructor:iB,select:Nj,selectAll:jj,selectChild:sB.selectChild,selectChildren:sB.selectChildren,filter:Aj,merge:Lj,selection:Uj,transition:eB,call:sB.call,nodes:sB.nodes,node:sB.node,size:sB.size,empty:sB.empty,each:sB.each,on:Pj,attr:pj,attrTween:yj,style:Wj,styleTween:Yj,text:Kj,textTween:tB,remove:Ij,tween:ij,delay:wj,duration:Ej,ease:Sj,easeVarying:Cj,end:nB,[Symbol.iterator]:sB[Symbol.iterator]};var uB={time:null,delay:0,duration:250,ease:pt};function lB(t,e){var n;while(!(n=t.__transition)||!(n=n[e]))if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}var cB=function(t){var e,n;t instanceof iB?(e=t._id,t=t._name):(e=aB(),(n=uB).time=wN(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&VN(a,t,e,l,s,n||lB(a,e));return new iB(r,this._parents,t,e)};tb.prototype.interrupt=$N,tb.prototype.transition=cB;var hB=t=>()=>t;function fB(t,{sourceEvent:e,target:n,selection:r,mode:i,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function pB(t){t.stopImmediatePropagation()}var dB=function(t){t.preventDefault(),t.stopImmediatePropagation()},vB={name:"drag"},gB={name:"space"},mB={name:"handle"},yB={name:"center"};const{abs:_B,max:bB,min:wB}=Math;function OB(t){return[+t[0],+t[1]]}function xB(t){return[OB(t[0]),OB(t[1])]}var EB={name:"x",handles:["w","e"].map(DB),input:function(t,e){return null==t?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},TB={name:"y",handles:["n","s"].map(DB),input:function(t,e){return null==t?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},SB=(["n","w","e","s","nw","ne","sw","se"].map(DB),{overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"}),MB={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},CB={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},AB={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},LB={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function DB(t){return{type:t}}function kB(t){return!t.ctrlKey&&!t.button}function PB(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function RB(){return navigator.maxTouchPoints||"ontouchstart"in this}function IB(t){while(!t.__brush)if(!(t=t.parentNode))return;return t.__brush}function NB(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function jB(){return BB(EB)}function BB(t){var e,n=PB,r=kB,i=RB,o=!0,a=oN("start","brush","end"),s=6;function u(e){var n=e.property("__brush",v).selectAll(".overlay").data([DB("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",SB.overlay).merge(n).each((function(){var t=IB(this).extent;eb(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([DB("selection")]).enter().append("rect").attr("class","selection").attr("cursor",SB.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var r=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));r.exit().remove(),r.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return SB[t.type]})),e.each(l).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",f).filter(i).on("touchstart.brush",f).on("touchmove.brush",p).on("touchend.brush touchcancel.brush",d).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function l(){var t=eb(this),e=IB(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-s/2:e[0][0]-s/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-s/2:e[0][1]-s/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+s:s})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+s:s}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function c(t,e,n){var r=t.__brush.emitter;return!r||n&&r.clean?new h(t,e,n):r}function h(t,e,n){this.that=t,this.args=e,this.state=t.__brush,this.active=0,this.clean=n}function f(n){if((!e||n.touches)&&r.apply(this,arguments)){var i,a,s,u,h,f,p,d,v,g,m,y=this,_=n.target.__data__.type,b="selection"===(o&&n.metaKey?_="overlay":_)?vB:o&&n.altKey?yB:mB,w=t===TB?null:AB[_],O=t===EB?null:LB[_],x=IB(y),E=x.extent,T=x.selection,S=E[0][0],M=E[0][1],C=E[1][0],A=E[1][1],L=0,D=0,k=w&&O&&o&&n.shiftKey,P=Array.from(n.touches||[n],t=>{const e=t.identifier;return t=wd(t,y),t.point0=t.slice(),t.identifier=e,t});qN(y);var R=c(y,arguments,!0).beforestart();if("overlay"===_){T&&(v=!0);const e=[P[0],P[1]||P[0]];x.selection=T=[[i=t===TB?S:wB(e[0][0],e[1][0]),s=t===EB?M:wB(e[0][1],e[1][1])],[h=t===TB?C:bB(e[0][0],e[1][0]),p=t===EB?A:bB(e[0][1],e[1][1])]],P.length>1&&U(n)}else i=T[0][0],s=T[0][1],h=T[1][0],p=T[1][1];a=i,u=s,f=h,d=p;var I=eb(y).attr("pointer-events","none"),N=I.selectAll(".overlay").attr("cursor",SB[_]);if(n.touches)R.moved=B,R.ended=V;else{var j=eb(n.view).on("mousemove.brush",B,!0).on("mouseup.brush",V,!0);o&&j.on("keydown.brush",H,!0).on("keyup.brush",G,!0),uN(n.view)}l.call(y),R.start(n,b.name)}function B(t){for(const e of t.changedTouches||[t])for(const t of P)t.identifier===e.identifier&&(t.cur=wd(e,y));if(k&&!g&&!m&&1===P.length){const t=P[0];_B(t.cur[0]-t[0])>_B(t.cur[1]-t[1])?m=!0:g=!0}for(const e of P)e.cur&&(e[0]=e.cur[0],e[1]=e.cur[1]);v=!0,dB(t),U(t)}function U(t){const e=P[0],n=e.point0;var r;switch(L=e[0]-n[0],D=e[1]-n[1],b){case gB:case vB:w&&(L=bB(S-i,wB(C-h,L)),a=i+L,f=h+L),O&&(D=bB(M-s,wB(A-p,D)),u=s+D,d=p+D);break;case mB:P[1]?(w&&(a=bB(S,wB(C,P[0][0])),f=bB(S,wB(C,P[1][0])),w=1),O&&(u=bB(M,wB(A,P[0][1])),d=bB(M,wB(A,P[1][1])),O=1)):(w<0?(L=bB(S-i,wB(C-i,L)),a=i+L,f=h):w>0&&(L=bB(S-h,wB(C-h,L)),a=i,f=h+L),O<0?(D=bB(M-s,wB(A-s,D)),u=s+D,d=p):O>0&&(D=bB(M-p,wB(A-p,D)),u=s,d=p+D));break;case yB:w&&(a=bB(S,wB(C,i-L*w)),f=bB(S,wB(C,h+L*w))),O&&(u=bB(M,wB(A,s-D*O)),d=bB(M,wB(A,p+D*O)));break}f<a&&(w*=-1,r=i,i=h,h=r,r=a,a=f,f=r,_ in MB&&N.attr("cursor",SB[_=MB[_]])),d<u&&(O*=-1,r=s,s=p,p=r,r=u,u=d,d=r,_ in CB&&N.attr("cursor",SB[_=CB[_]])),x.selection&&(T=x.selection),g&&(a=T[0][0],f=T[1][0]),m&&(u=T[0][1],d=T[1][1]),T[0][0]===a&&T[0][1]===u&&T[1][0]===f&&T[1][1]===d||(x.selection=[[a,u],[f,d]],l.call(y),R.brush(t,b.name))}function V(t){if(pB(t),t.touches){if(t.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500)}else lN(t.view,v),j.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);I.attr("pointer-events","all"),N.attr("cursor",SB.overlay),x.selection&&(T=x.selection),NB(T)&&(x.selection=null,l.call(y)),R.end(t,b.name)}function H(t){switch(t.keyCode){case 16:k=w&&O;break;case 18:b===mB&&(w&&(h=f-L*w,i=a+L*w),O&&(p=d-D*O,s=u+D*O),b=yB,U(t));break;case 32:b!==mB&&b!==yB||(w<0?h=f-L:w>0&&(i=a-L),O<0?p=d-D:O>0&&(s=u-D),b=gB,N.attr("cursor",SB.selection),U(t));break;default:return}dB(t)}function G(t){switch(t.keyCode){case 16:k&&(g=m=k=!1,U(t));break;case 18:b===yB&&(w<0?h=f:w>0&&(i=a),O<0?p=d:O>0&&(s=u),b=mB,U(t));break;case 32:b===gB&&(t.altKey?(w&&(h=f-L*w,i=a+L*w),O&&(p=d-D*O,s=u+D*O),b=yB):(w<0?h=f:w>0&&(i=a),O<0?p=d:O>0&&(s=u),b=mB),N.attr("cursor",SB[_]),U(t));break;default:return}dB(t)}}function p(t){c(this,arguments).moved(t)}function d(t){c(this,arguments).ended(t)}function v(){var e=this.__brush||{selection:null};return e.extent=xB(n.apply(this,arguments)),e.dim=t,e}return u.move=function(e,n,r){e.tween?e.on("start.brush",(function(t){c(this,arguments).beforestart().start(t)})).on("interrupt.brush end.brush",(function(t){c(this,arguments).end(t)})).tween("brush",(function(){var e=this,r=e.__brush,i=c(e,arguments),o=r.selection,a=t.input("function"===typeof n?n.apply(this,arguments):n,r.extent),s=Nx(o,a);function u(t){r.selection=1===t&&null===a?null:s(t),l.call(e),i.brush()}return null!==o&&null!==a?u:u(1)})):e.each((function(){var e=this,i=arguments,o=e.__brush,a=t.input("function"===typeof n?n.apply(e,i):n,o.extent),s=c(e,i).beforestart();qN(e),o.selection=null===a?null:a,l.call(e),s.start(r).brush(r).end(r)}))},u.clear=function(t,e){u.move(t,null,e)},h.prototype={beforestart:function(){return 1===++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(t,e){return this.starting?(this.starting=!1,this.emit("start",t,e)):this.emit("brush",t),this},brush:function(t,e){return this.emit("brush",t,e),this},end:function(t,e){return 0===--this.active&&(delete this.state.emitter,this.emit("end",t,e)),this},emit:function(e,n,r){var i=eb(this.that).datum();a.call(e,this.that,new fB(e,{sourceEvent:n,target:u,selection:t.output(this.state.selection),mode:r,dispatch:a}),i)}},u.extent=function(t){return arguments.length?(n="function"===typeof t?t:hB(xB(t)),u):n},u.filter=function(t){return arguments.length?(r="function"===typeof t?t:hB(!!t),u):r},u.touchable=function(t){return arguments.length?(i="function"===typeof t?t:hB(!!t),u):i},u.handleSize=function(t){return arguments.length?(s=+t,u):s},u.keyModifiers=function(t){return arguments.length?(o=!!t,u):o},u.on=function(){var t=a.on.apply(a,arguments);return t===a?u:t},u}var UB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),VB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid-brush",e.renderType=I.SVG,e.selectionSelector="rect.selection",e.frontSelectionSelector="rect.frontSelection",e}return UB(e,t),e.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this.parent,i=this.getComponentContainer(),o=sb.appendOrSelect(r,"svg.chart-grid-backdrop"),a=sb.appendOrSelect(o,"g."+this.type),s=sb.appendOrSelect(a,this.selectionSelector),u=sb.getSVGElementSize(o,{useAttrs:!0}),l=u.width,c=u.height,h=this.services.cartesianScales,f=h.getMainXScaleType(),p=h.getMainXScale(),d=p.range(),v=d[0];d[1];i.attr("transform","translate("+v+",0)");var g=sb.appendOrSelect(i,this.frontSelectionSelector);if(p&&f===G.TIME){var m=this.model.get("zoomDomain");void 0===m&&(m=this.services.zoom.getDefaultZoomBarDomain(),m&&this.model.set({zoomDomain:m},{animate:!1}));var y,_=function(t){for(var n=t[1]-t[0],r="0,"+n.toString(),i=Math.floor(c/e.DASH_LENGTH),o=i*e.DASH_LENGTH,a=0;a<i;a++)r+=","+e.DASH_LENGTH;r+=","+(c-o),i%2===1&&(r+=",0"),r+=","+n.toString(),r+=","+c.toString(),g.attr("stroke-dasharray",r)},b=function(t){var e=t.selection;null!==e&&e[0]!==e[1]&&(g.attr("x",parseFloat(s.attr("x"))+parseFloat(o.attr("x"))).attr("y",s.attr("y")).attr("width",s.attr("width")).attr("height",s.attr("height")).style("cursor","pointer").style("display",null),_(e))},w=function(t,e){var r=Jx().range([0,l]).domain(m),i=[r.invert(t),r.invert(e)];i[0].valueOf()===i[1].valueOf()&&(i=n.services.zoom.getDefaultZoomBarDomain()),m[0].valueOf()===i[0].valueOf()&&m[1].valueOf()===i[1].valueOf()||n.services.zoom.handleDomainChange(i)},O=function(t){var e=t.selection;null!==e&&(w(e[0],e[1]),a.call(y.move,null),g.style("display","none"))};0!=c&&0!=l&&(y=jB().extent([[0,0],[l-1,c]]).on("start brush end",b).on("end.brushed",O),a.call(y));var x=this.services.zoom.getZoomRatio();o.on("click",(function(t){if(t.shiftKey){var e=this.services.domUtils.getHolder(),n=wd(a.node(),e)[0],r=n-l*x/2;r<0&&(r=0);var i=n+l*x/2;i>l&&(i=l),w(r,i)}}))}},e.DASH_LENGTH=4,e}(DS),HB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),GB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid",e.renderType=I.SVG,e}return HB(e,t),e.prototype.render=function(t){void 0===t&&(t=!0);var e=Dd(this.getOptions(),"grid","x","enabled"),n=Dd(this.getOptions(),"grid","y","enabled");this.drawBackdrop(e,n),(e||n)&&(e&&(sb.appendOrSelect(this.backdrop,"g.x.grid"),this.drawXGrid(t)),n&&(sb.appendOrSelect(this.backdrop,"g.y.grid"),this.drawYGrid(t)))},e.prototype.drawXGrid=function(t){var e=this,n=this.parent,r=this.backdrop.attr("height"),i=this.services.cartesianScales.getMainXScale(),o=YS(i).tickSizeInner(-r).tickSizeOuter(0),a=Dd(this.getOptions(),"grid","x","alignWithAxisTicks");if(a){var s=this.services.cartesianScales.getDomainAxisPosition(),u=Dd(this.getOptions(),"axes",s,"ticks","values");u&&o.tickValues(u)}else{var l=Dd(this.getOptions(),"grid","x","numberOfTicks");o.ticks(l)}var c=n.select(".x.grid").attr("transform","translate("+-this.backdrop.attr("x")+", "+r+")");t?c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"grid-update",animate:t})})).call(o):c.call(o),this.cleanGrid(c)},e.prototype.drawYGrid=function(t){var e=this,n=this.parent,r=this.backdrop.attr("width"),i=this.services.cartesianScales.getMainYScale(),o=ZS(i).tickSizeInner(-r).tickSizeOuter(0),a=Dd(this.getOptions(),"grid","y","alignWithAxisTicks");if(a){var s=this.services.cartesianScales.getRangeAxisPosition(),u=Dd(this.getOptions(),"axes",s,"ticks","values");u&&o.tickValues(u)}else{var l=Dd(this.getOptions(),"grid","y","numberOfTicks");o.ticks(l)}var c=n.select(".y.grid").attr("transform","translate(0, "+-this.backdrop.attr("y")+")");t?c.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"grid-update",animate:t})})).call(o):c.call(o),this.cleanGrid(c)},e.prototype.getGridlineThreshold=function(t){var e,n=this.parent,r=n.selectAll(".x.grid .tick").nodes().sort((function(t,e){return Number(Sd(t).tx)-Number(Sd(e).tx)})),i=-1;if(r.length){r.forEach((function(e,n){t[0]>=+Sd(e).tx&&i++})),e=i+1<r.length?i+1:r.length;var o,a=r[i],s=r[e];if(a)if(s)o=+Sd(s).tx-+Sd(a).tx;else{var u=n.select("rect.chart-grid-backdrop").node(),l=sb.getSVGElementSize(u).width;o=l-+Sd(a).tx}else o=+Sd(s).tx;var c=this.getOptions().tooltip.gridline.threshold;return o*c}},e.prototype.getActiveGridline=function(t){var e=Dd(this.getOptions,"tooltip","gridline","threshold"),n=e||this.getGridlineThreshold(t),r=this.parent,i=r.selectAll(".x.grid .tick").filter((function(){var e=Sd(this),r={min:Number(e.tx)-n,max:Number(e.tx)+n};return r.min<=t[0]&&t[0]<=r.max}));return i},e.prototype.drawBackdrop=function(t,e){var n=this.parent,r=this.services.cartesianScales.getMainXScale(),i=this.services.cartesianScales.getMainYScale(),o=r.range(),a=o[0],s=o[1],u=i.range(),l=u[0],c=u[1];this.backdrop=sb.appendOrSelect(n,"svg.chart-grid-backdrop");var h=sb.appendOrSelect(this.backdrop,t||e?"rect.chart-grid-backdrop.stroked":"rect.chart-grid-backdrop");this.backdrop.merge(h).attr("x",a).attr("y",c).attr("width",Math.abs(s-a)).attr("height",Math.abs(l-c)).lower(),h.attr("width","100%").attr("height","100%")},e.prototype.cleanGrid=function(t){t.selectAll("text").remove(),t.select(".domain").remove()},e}(DS),zB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FB=5;function WB(t,e){return t>e-FB&&t<e+FB}var qB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ruler",e.renderType=I.SVG,e.isXGridEnabled=Dd(e.getOptions(),"grid","x","enabled"),e.isYGridEnabled=Dd(e.getOptions(),"grid","y","enabled"),e.isEventListenerAdded=!1,e}return zB(e,t),e.prototype.render=function(){var t=Dd(this.getOptions(),"ruler","enabled");this.drawBackdrop(),t&&!this.isEventListenerAdded?this.addBackdropEventListeners():!t&&this.isEventListenerAdded&&this.removeBackdropEventListeners()},e.prototype.removeBackdropEventListeners=function(){this.isEventListenerAdded=!1,this.backdrop.on("mousemove mouseover mouseout",null)},e.prototype.formatTooltipData=function(t){return t},e.prototype.showRuler=function(t,e){var n=this,r=e[0],i=e[1],o=this.parent,a=this.services.cartesianScales.getOrientation(),s=this.model.getDisplayData(),u=this.services.cartesianScales.getRangeScale(),l=u.range(),c=l[0],h=l[1],f=a===H.HORIZONTAL?i:r,p=sb.appendOrSelect(o,"g.ruler").attr("aria-label","ruler"),d=sb.appendOrSelect(p,"line.ruler-line"),v=o.selectAll("[role=graphics-symbol]"),g=s.map((function(t){return{domainValue:n.services.cartesianScales.getDomainValue(t),originalData:t}})).filter((function(t){return WB(t.domainValue,f)}));if(this.pointsWithinLine&&g.length===this.pointsWithinLine.length&&g.map((function(t){return t.domainValue})).join()===this.pointsWithinLine.map((function(t){return t.domainValue})).join())return this.pointsWithinLine=g,this.services.events.dispatchEvent(ft.Tooltip.MOVE,{mousePosition:[r,i]});this.pointsWithinLine=g;var m=this.pointsWithinLine.reduce((function(t,e){if(0===t.length)return t.push(e),t;var n=t[0].domainValue,r=Math.abs(f-e.domainValue),i=Math.abs(f-n);return r>i||(r<i?t=[e]:t.push(e)),t}),[]);if(m.length>0){var y=m.map((function(t){return t.originalData})).filter((function(t){var e=n.services.cartesianScales.getRangeIdentifier(t),r=t[e];return null!==r&&void 0!==r})),_=m.map((function(t){return t.domainValue})),b=v.filter((function(t){var e=n.services.cartesianScales.getDomainValue(t);return _.includes(e)}));this.elementsToHighlight&&this.elementsToHighlight.size()>0&&!Gh(this.elementsToHighlight,b)&&this.hideRuler(),b.dispatch("mouseover"),this.elementsToHighlight=b,this.services.events.dispatchEvent(ft.Tooltip.SHOW,{mousePosition:[r,i],hoveredElement:d,data:this.formatTooltipData(y)}),p.attr("opacity",1);var w=m[0];"horizontal"===a?d.attr("x1",h).attr("x2",c).attr("y1",w.domainValue).attr("y2",w.domainValue):d.attr("y1",h).attr("y2",c).attr("x1",w.domainValue).attr("x2",w.domainValue)}else this.hideRuler()},e.prototype.hideRuler=function(){var t=this.parent,e=sb.appendOrSelect(t,"g.ruler"),n=t.selectAll("[role=graphics-symbol]");n.dispatch("mouseout"),this.services.events.dispatchEvent(ft.Tooltip.HIDE),e.attr("opacity",0)},e.prototype.addBackdropEventListeners=function(){this.isEventListenerAdded=!0;var t=this,e=this.services.domUtils.getHolder(),n=this.model.getDisplayData(),r=function(e){var n=wd(e,t.parent.node());t.showRuler(e,n)};if(n.length>100){var i=n.length%50*12.5;r=Ed((function(e){var n=this.mousePosition;t.showRuler(e,n)}),i,e)}this.backdrop.on("mousemove mouseover",r).on("mouseout",this.hideRuler.bind(this))},e.prototype.drawBackdrop=function(){var t=this.parent;this.backdrop=sb.appendOrSelect(t,"svg.chart-grid-backdrop")},e}(DS),$B=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YB=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},ZB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ruler-binned",e.renderType=I.SVG,e}return $B(e,t),e.prototype.showRuler=function(t,e){var n=this,r=e[0],i=e[1],o=this.parent,a=this.model.getOptions(),s=this.services.cartesianScales.getOrientation(),u=this.services.cartesianScales.getRangeScale(),l=u.range(),c=l[0],h=l[1],f=this.services.cartesianScales.getDomainScale(),p=f.invert(s===H.VERTICAL?r:i),d=sb.appendOrSelect(o,"g.ruler").attr("aria-label","ruler"),v=sb.appendOrSelect(d,"line.ruler-line"),g=o.selectAll("[role=graphics-symbol]"),m=g.filter((function(t){if(parseFloat(tl(t,"data.x0"))<=p&&parseFloat(tl(t,"data.x1"))>=p)return!0}));if(m.size()>0){this.elementsToHighlight&&this.elementsToHighlight.size()>0&&!Gh(this.elementsToHighlight,m)&&this.hideRuler(),m.dispatch("mouseover"),this.elementsToHighlight=m;var y=eb(m.nodes()[0]).datum(),_=parseFloat(tl(y,"data.x0")),b=parseFloat(tl(y,"data.x1")),w=this.model.getActiveDataGroupNames(),O=w.reverse().map((function(t){return{label:t,value:tl(y,"data."+t),class:n.model.getColorClassName({classNameTypes:[j.TOOLTIP],dataGroupName:t})}})).filter((function(t){return 0!==t.value})),x=O.length>0;if(x){this.services.events.dispatchEvent(ft.Tooltip.SHOW,{mousePosition:[r,i],hoveredElement:v,items:YB([{label:tl(a,"bins.rangeLabel")||"Range",value:_+" – "+b}],O,!0===Dd(a,"tooltip","showTotal")?[{label:tl(a,"tooltip.totalLabel")||"Total",value:w.reduce((function(t,e){return t+parseFloat(tl(y,"data."+e))}),0)}]:[])}),d.attr("opacity",1);var E=f((_+b)/2);"horizontal"===s?v.attr("x1",h).attr("x2",c).attr("y1",E).attr("y2",E):v.attr("y1",h).attr("y2",c).attr("x1",E).attr("x2",E)}else this.hideRuler()}else this.hideRuler()},e}(qB),XB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),KB=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return XB(e,t),e.prototype.formatTooltipData=function(t){return t.reverse()},e}(qB),QB=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),JB=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="toolbar",e.renderType=I.HTML,e}return QB(e,t),e.prototype.init=function(){var t=this,e=function(){return t.updateOverflowMenu(!1)};this.services.events.addEventListener(ft.Toolbar.SHOW_OVERFLOW_MENU,(function(){t.renderOverflowMenu(),document.body.addEventListener("click",e)})),this.services.events.addEventListener(ft.Toolbar.HIDE_OVERFLOW_MENU,(function(){document.body.removeEventListener("click",e)}))},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer().attr("role","toolbar").attr("aria-label","chart-"+this.services.domUtils.getChartID()+" toolbar"),r=Dd(this.getOptions(),"data","loading");if(r)n.html(""),this.overflowMenu=null;else{this.overflowMenu||(this.overflowMenu=n.append("div").attr("class","cds--overflow-menu-options cds--overflow-menu--flip cds--overflow-menu-options cds--overflow-menu--flip").attr("tabindex",-1).html("<ul role='menu'></ul>"));var i=this.getControlConfigs(),o=i.buttonList,a=i.overflowMenuItemList;a&&o.push(this.getOverflowButtonConfig());var s=n.selectAll("div.toolbar-control").data(o,(function(t){return t.id}));s.exit().remove();var u=s.enter().append("div").attr("class","toolbar-control cds--overflow-menu cds--overflow-menu").attr("role","button"),l=this;u.merge(s).classed("disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-label",(function(t){return t.title})).html((function(t){return'\n\t\t\t<button\n\t\t\t\tclass="cds--overflow-menu__trigger cds--overflow-menu__trigger"\n\t\t\t\taria-haspopup="true" aria-expanded="false" id="'+e.services.domUtils.generateElementIDString("control-"+t.id)+'" aria-label="'+t.title+'">\n\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet" xmlns="http://www.w3.org/2000/svg" class="cds--overflow-menu__icon cds--overflow-menu__icon" viewBox="0 0 32 32" aria-hidden="true">\n\t\t\t\t\t'+t.iconSVG.content+"\n\t\t\t\t</svg>\n\t\t\t</button>"})).each((function(t,e){var n=this;eb(this).select("svg").style("will-change","transform").style("width",void 0!==t.iconSVG.width?t.iconSVG.width:"20px").style("height",void 0!==t.iconSVG.height?t.iconSVG.height:"20px"),eb(this).select("button").on("click",(function(e){t.shouldBeDisabled()||l.triggerFunctionAndEvent(t,e,n)})).on("keydown",(function(r){r.key&&"Enter"===r.key||" "===r.key?(r.preventDefault(),l.triggerFunctionAndEvent(t,r,n)):r.key&&"ArrowLeft"===r.key?l.focusOnPreviousEnabledToolbarItem(e):r.key&&"ArrowRight"===r.key&&l.focusOnNextEnabledToolbarItem(e)}))}));this.overflowButton=this.getComponentContainer().select("button.cds--overflow-menu__trigger#"+this.services.domUtils.generateElementIDString("control-toolbar-overflow-menu"))}},e.prototype.renderOverflowMenu=function(){var t=this,e=this.getControlConfigs().overflowMenuItemList,n=this.overflowMenu.select("ul").selectAll("li.cds--overflow-menu-options__option").data(e,(function(t){return Dd(t,"id")}));n.exit().remove();var r=n.enter().append("li").attr("id",(function(e){return t.services.domUtils.generateElementIDString("control-"+e.id)})).attr("class","cds--overflow-menu-options__option cds--overflow-menu-options__option").attr("role","menuitem").attr("tabindex",1);r.append("button").attr("class","cds--overflow-menu-options__btn cds--overflow-menu-options__btn"),r.merge(n).classed("cds--overflow-menu-options__option--disabled",(function(t){return t.shouldBeDisabled()})).classed("cds--overflow-menu-options__option--disabled",(function(t){return t.shouldBeDisabled()})).attr("aria-disabled",(function(t){return t.shouldBeDisabled()})).selectAll("button").text((function(t){return t.text}))},e.prototype.isOverflowMenuOpen=function(){return this.overflowMenu.classed("is-open")},e.prototype.updateOverflowMenu=function(t){this.overflowMenu&&(this.overflowMenu.classed("is-open",t),this.overflowButton&&(this.overflowButton.attr("aria-expanded",t),eb(this.overflowButton.node().parentNode).classed("cds--overflow-menu--open",t).classed("cds--overflow-menu--open",t)),t?this.services.events.dispatchEvent(ft.Toolbar.SHOW_OVERFLOW_MENU):this.services.events.dispatchEvent(ft.Toolbar.HIDE_OVERFLOW_MENU))},e.prototype.focusOnPreviousEnabledToolbarItem=function(t){for(var e=this.getToolbarButtonItems(),n=e.length,r=t-1;r>=0;r--){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n<e.length){var o=eb("button#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)).node();"focus"in o&&o.focus()}},e.prototype.focusOnNextEnabledToolbarItem=function(t){for(var e=this.getToolbarButtonItems(),n=-1,r=t+1;r<e.length;r++){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n>-1){var o=eb("button#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)).node();"focus"in o&&o.focus()}},e.prototype.focusOnPreviousEnabledMenuItem=function(t){for(var e=this.getOverflowMenuItems(),n=e.length,r=t-1;r>=0;r--){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n<e.length){var o=eb("#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)+" button").node();"focus"in o&&o.focus()}},e.prototype.focusOnNextEnabledMenuItem=function(t){for(var e=this.getOverflowMenuItems(),n=-1,r=t+1;r<e.length;r++){var i=e[r];if(!i.shouldBeDisabled()){n=r;break}}if(n>-1){var o=eb("#"+this.services.domUtils.generateElementIDString("control-"+e[n].id)+" button").node();"focus"in o&&o.focus()}},e.prototype.toggleOverflowMenu=function(t){var e=this;if(this.isOverflowMenuOpen())this.updateOverflowMenu(!1);else{this.updateOverflowMenu(!0);var n=this,r=this.getOverflowMenuItems();r.forEach((function(r,i){var o=eb("#"+e.services.domUtils.generateElementIDString("control-"+r.id));null!==o&&(o.on("click",(function(){n.triggerFunctionAndEvent(r,t,o.node()),n.updateOverflowMenu(!1)})),o.on("keydown",(function(e){e&&"Enter"===e.key?n.triggerFunctionAndEvent(r,t,o.node()):e&&"ArrowUp"===e.key?n.focusOnPreviousEnabledMenuItem(i):e&&"ArrowDown"===e.key?n.focusOnNextEnabledMenuItem(i):e&&"Escape"===e.key&&n.updateOverflowMenu(!1),e.preventDefault()})))})),n.focusOnNextEnabledMenuItem(-1)}t&&t.stopImmediatePropagation()},e.prototype.triggerFunctionAndEvent=function(t,e,n){"function"===typeof t.shouldBeDisabled&&t.shouldBeDisabled()||("function"===typeof t.clickFunction&&t.clickFunction(e),this.services.events.dispatchEvent(ft.Toolbar.BUTTON_CLICK,{control:t,event:e,element:n}))},e.prototype.getControlConfigs=function(){var t=this,n=Dd(this.getOptions(),"toolbar","numberOfIcons")-1,r=Dd(this.getOptions(),"toolbar","controls"),i=[],o=[],a=[];return r.forEach((function(r){var s=null;r.type===ot.CUSTOM?(null===Dd(r,"id")&&(r.id="toolbar-button-"+e.buttonID++),null===Dd(r,"shouldBeDisabled")&&(r.shouldBeDisabled=function(){return!1}),s=r):s=t.getControlConfigByType(r.type),s&&(s.text=r.text?r.text:r.type,-1!==s.id.indexOf("toolbar-export")?i.push(s):o.length<n?null===Dd(s,"iconSVG","content")?a.push(s):o.push(s):a.push(s))})),a.push.apply(a,i),a.length?{buttonList:o,overflowMenuItemList:a}:{buttonList:o}},e.prototype.getToolbarButtonItems=function(){var t=this.getControlConfigs(),e=t.buttonList,n=t.overflowMenuItemList;return n&&e.push(this.getOverflowButtonConfig()),e||[]},e.prototype.getOverflowMenuItems=function(){var t=this.getControlConfigs().overflowMenuItemList;return t||[]},e.prototype.getOverflowButtonConfig=function(){var t=this;return{id:"toolbar-overflow-menu",title:"More options",shouldBeDisabled:function(){return!1},iconSVG:{content:'<circle cx="16" cy="8" r="2"></circle>\n\t\t\t\t<circle cx="16" cy="16" r="2"></circle>\n\t\t\t\t<circle cx="16" cy="24" r="2"></circle>'},clickFunction:function(e){return t.toggleOverflowMenu(e)}}},e.prototype.getControlConfigByType=function(t){var e,n=this,r=this.services.zoom&&this.services.zoom.isZoomBarEnabled()&&!this.services.zoom.isEmptyState(),i=this.model.getDisplayData();switch(t){case ot.ZOOM_IN:r&&(e={id:"toolbar-zoomIn",title:"Zoom in",shouldBeDisabled:function(){return n.services.zoom.isMinZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.zoomIn()}});break;case ot.ZOOM_OUT:r&&(e={id:"toolbar-zoomOut",title:"Zoom out",shouldBeDisabled:function(){return n.services.zoom.isMaxZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.zoomOut()}});break;case ot.RESET_ZOOM:r&&(e={id:"toolbar-resetZoom",title:"Reset zoom",shouldBeDisabled:function(){return n.services.zoom.isMaxZoomDomain()},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.zoom.resetZoomDomain()}});break;case ot.MAKE_FULLSCREEN:e={id:"toolbar-makefullscreen",iconSVG:{content:this.getControlIconByType(t),width:"15px",height:"15px"},title:"Make fullscreen",shouldBeDisabled:function(){return!1},clickFunction:function(){n.services.domUtils.toggleFullscreen()}};break;case ot.SHOW_AS_DATATABLE:e={id:"toolbar-showasdatatable",iconSVG:{content:this.getControlIconByType(t)},title:"Show as table",shouldBeDisabled:function(){return 0===i.length},clickFunction:function(){return n.services.events.dispatchEvent(ft.Modal.SHOW)}};break;case ot.EXPORT_CSV:e={id:"toolbar-export-CSV",title:"Export as CSV",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.model.exportToCSV()}};break;case ot.EXPORT_PNG:e={id:"toolbar-export-PNG",title:"Export as PNG",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.domUtils.exportToPNG()}};break;case ot.EXPORT_JPG:e={id:"toolbar-export-JPG",title:"Export as JPG",shouldBeDisabled:function(){return!1},iconSVG:{content:this.getControlIconByType(t)},clickFunction:function(){return n.services.domUtils.exportToJPG()}};break;default:throw Error("Not supported toolbar control type: "+t)}return e},e.prototype.getControlIconByType=function(t){switch(t){case ot.ZOOM_IN:return'<polygon points="19 13 15 13 15 9 13 9 13 13 9 13 9 15 13 15 13 19 15 19 15 15 19 15 19 13"/>\n\t\t\t\t\t\t<path d="M22.45,21A10.87,10.87,0,0,0,25,14,11,11,0,1,0,14,25a10.87,10.87,0,0,0,7-2.55L28.59,30,30,28.59ZM14,23a9,9,0,1,1,9-9A9,9,0,0,1,14,23Z"/>';case ot.ZOOM_OUT:return'<rect x="9" y="13" width="10" height="2"/>\n\t\t\t\t\t\t<path d="M22.45,21A10.87,10.87,0,0,0,25,14,11,11,0,1,0,14,25a10.87,10.87,0,0,0,7-2.55L28.59,30,30,28.59ZM14,23a9,9,0,1,1,9-9A9,9,0,0,1,14,23Z"/>';case ot.RESET_ZOOM:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.MAKE_FULLSCREEN:return'<polygon points="21 2 21 4 26.59 4 17 13.58 18.41 15 28 5.41 28 11 30 11 30 2 21 2"/><polygon points="15 18.42 13.59 17 4 26.59 4 21 2 21 2 30 11 30 11 28 5.41 28 15 18.42"/>';case ot.SHOW_AS_DATATABLE:return'<rect x="4" y="6" width="18" height="2"/><rect x="4" y="12" width="18" height="2"/><rect x="4" y="18" width="18" height="2"/><rect x="4" y="24" width="18" height="2"/><rect x="26" y="6" width="2" height="2"/><rect x="26" y="12" width="2" height="2"/><rect x="26" y="18" width="2" height="2"/><rect x="26" y="24" width="2" height="2"/>';case ot.EXPORT_CSV:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.EXPORT_JPG:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';case ot.EXPORT_PNG:return'<path d="M22.4478,21A10.855,10.855,0,0,0,25,14,10.99,10.99,0,0,0,6,6.4658V2H4v8h8V8H7.332a8.9768,8.9768,0,1,1-2.1,8H3.1912A11.0118,11.0118,0,0,0,14,25a10.855,10.855,0,0,0,7-2.5522L28.5859,30,30,28.5859Z"/>';default:throw Error("Not supported toolbar control type: "+t)}},e.buttonID=0,e}(DS),tU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eU=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zero-line",e.renderType=I.SVG,e}return tU(e,t),e.prototype.render=function(t){var e=this,n=this.services.cartesianScales.getRangeAxisPosition({groups:this.configs.groups}),r=this.services.cartesianScales.getScaleByPosition(n),i=r.domain(),o=i[0],a=i[1],s=o>0&&a<0||o<0&&a>0,u=this.getComponentContainer();if(s){var l=this.services.cartesianScales.getDomainScale().range(),c=l[0],h=l[1],f=+r(0)+.5;f||(f=r.range()[0]);var p=kd({x0:c,x1:h,y0:f,y1:f},this.services.cartesianScales.getOrientation()),d=sb.appendOrSelect(u,"line.domain");d.transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"zero-line-update",animate:t})})).attr("y1",p.y0).attr("y2",p.y1).attr("x1",p.x0).attr("x2",p.x1)}else u.selectAll("line.domain").remove()},e}(DS),nU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rU=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zoom-bar",e.renderType=I.SVG,e.MIN_SELECTION_DIFF=9e-10,e.brushSelector="g.zoom-bar-brush",e.clipId="zoomBarClip-"+Math.floor(99999999999*Math.random()),e.brush=jB(),e.highlightStrokeWidth=1,e}return nU(e,t),e.prototype.init=function(){this.services.events.addEventListener(ft.ZoomBar.UPDATE,this.render.bind(this));var t=Dd(this.getOptions(),"zoomBar",B.TOP,"data");this.model.setZoomBarData(t)},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.getComponentContainer(),r=this.services.zoom.isZoomBarLoading(B.TOP),i=this.services.zoom.isZoomBarLocked(B.TOP),o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Dd(this.getOptions(),"axes",B.BOTTOM,"highlights"),s=Pt.height[o],u=sb.getSVGElementSize(this.parent,{useAttrs:!0}).width;if(0!==u){var l=0,c=this.model.get("axesMargins");c&&c.left&&(l=c.left);var h=sb.appendOrSelect(n,"svg.zoom-container").attr("width","100%").attr("height",s).attr("opacity",1);sb.appendOrSelect(n,"rect.zoom-spacer").attr("x",0).attr("y",s).attr("width","100%").attr("height",Pt.spacerHeight).attr("opacity",1).attr("fill","none");if(o===U.GRAPH_VIEW?sb.appendOrSelect(h,"rect.zoom-bg").attr("x",l).attr("y",0).attr("width",u-l).attr("height","100%").classed("zoom-bg-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null):o===U.SLIDER_VIEW&&sb.appendOrSelect(h,"rect.zoom-slider-bg").attr("x",l).attr("y",s/2-1).attr("width",u-l).attr("height",2).classed("zoom-slider-bg-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null),r)this.renderSkeleton(h,l,u);else{var f=this.services.cartesianScales,p=f.getMainXScale(),d=f.getMainYScale(),v=f.getMainXScaleType();if(p&&v===G.TIME){var g=this.services.zoom.getZoomBarData();if(Vh(g)||1===g.length)return;this.xScale=p.copy(),this.yScale=d.copy();var m=this.services.zoom.getDefaultZoomBarDomain(g);g=this.compensateDataForDefaultDomain(g,m);var y=this.model.get("initialZoomDomain"),_=Dd(this.getOptions(),"zoomBar",B.TOP,"initialZoomDomain");_&&_[0]&&_[1]&&(_[0]=new Date(_[0]),_[1]=new Date(_[1])),!_||y&&y[0].valueOf()===_[0].valueOf()&&y[1].valueOf()===_[1].valueOf()?null===_&&null!==y&&this.model.set({initialZoomDomain:null,zoomDomain:na([],m)},{skipUpdate:!0}):this.model.set({initialZoomDomain:na([],_),zoomDomain:_?na([],_):m},{skipUpdate:!0}),this.xScale.range([l,u]).domain(m),this.maxSelectionRange=this.xScale.range(),this.yScale.range([0,s-6]).domain(Xv(g,(function(t){return t.value})));var b=this.model.get("zoomDomain");if(o===U.GRAPH_VIEW&&(this.renderZoomBarArea(h,"path.zoom-graph-area-unselected",g,null),this.updateClipPath(n,this.clipId,0,0,0,0),this.renderZoomBarArea(h,"path.zoom-graph-area",g,this.clipId),this.renderZoomBarBaseline(h,l,u),a)){var w=a.highlightStartMapsTo,O=a.highlightEndMapsTo,x=a.color,E=a.labelMapsTo;a.data.forEach((function(t,n){sb.appendOrSelect(h,"rect.highlight-"+n).attr("height",s-2*e.highlightStrokeWidth).attr("y",e.highlightStrokeWidth).attr("x",e.xScale(t[w])).attr("width",e.xScale(t[O])-e.xScale(t[w])).style("fill",x&&x.scale[t[E]]?x.scale[t[E]]:null).style("fill-opacity",.1).style("stroke",x&&x.scale[t[E]]?x.scale[t[E]]:null).style("stroke-dasharray","2, 2").attr("stroke-width","1px")}))}this.addBrushEventListener(b,l,u);var T=sb.appendOrSelect(n,this.brushSelector).call(this.brush);if(void 0===b);else if(b[0].valueOf()===b[1].valueOf())T.call(this.brush.move,this.xScale.range()),this.updateBrushHandle(this.getComponentContainer(),this.xScale.range(),this.xScale.domain());else{var S=b.map((function(t){return e.xScale(t)}));S[1]-S[0]<this.MIN_SELECTION_DIFF||(T.call(this.brush.move,S),this.updateBrushHandle(this.getComponentContainer(),S,b))}i&&(this.brush.filter((function(){return!1})),T.selectAll("rect").attr("cursor","auto"))}}}},e.prototype.addBrushEventListener=function(t,e,n){var r=this,i=function(e){var n=e.selection;null===n?r.handleBrushedEvent(e,t,r.xScale,r.xScale.range()):n[0]===n[1]||r.handleBrushedEvent(e,t,r.xScale,n)},o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Pt.height[o];this.brush.extent([[e,0],[n,a]]).on("start brush end",null).on("start brush end",i)},e.prototype.handleBrushedEvent=function(t,e,n,r){var i=[n.invert(r[0]),n.invert(r[1])];if(this.updateBrushHandle(this.getComponentContainer(),r,i),null!=t.sourceEvent&&("mousemove"===t.sourceEvent.type||"mouseup"===t.sourceEvent.type||"mousedown"===t.sourceEvent.type||"touchstart"===t.sourceEvent.type||"touchmove"===t.sourceEvent.type||"touchend"===t.sourceEvent.type)){void 0!==e&&e[0]===i[0]&&e[1]===i[1]||this.services.zoom.handleDomainChange(i,{dispatchEvent:!1});var o=void 0;"start"===t.type?o=ft.ZoomBar.SELECTION_START:"brush"===t.type?o=ft.ZoomBar.SELECTION_IN_PROGRESS:"end"===t.type&&(o=ft.ZoomBar.SELECTION_END,this.services.events.dispatchEvent(ft.ZoomDomain.CHANGE,{newDomain:i})),this.services.events.dispatchEvent(o,{selection:r,newDomain:i})}},e.prototype.updateBrushHandle=function(t,e,n){var r=this,i=Pt.handleWidth,o=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),a=Pt.height[o],s=-i/2,u=Pt.handleBarWidth,l=o===U.GRAPH_VIEW?Pt.handleBarHeight:6,c=-u/2,h=(a-l)/2;t.select(this.brushSelector).selectAll("rect.handle").data([{type:"w"},{type:"e"}]).attr("x",(function(t){return"w"===t.type?Math.max(e[0]+s,r.maxSelectionRange[0]):"e"===t.type?Math.min(e[1]+s,r.maxSelectionRange[1]-i):void 0})).attr("y",0).attr("width",i).attr("height",a).attr("cursor","ew-resize").style("display",null);var f=t.select(this.brushSelector).selectAll("rect.handle-bar").data([{type:"w"},{type:"e"}]);f.enter().append("rect").attr("class",(function(t){return"handle-bar handle-bar--"+t.type})),f.attr("x",(function(t){return"w"===t.type?Math.max(e[0]+c,r.maxSelectionRange[0]-s+c):"e"===t.type?Math.min(e[1]+c,r.maxSelectionRange[1]+s+c):void 0})).attr("y",h).attr("width",u).attr("height",l).attr("cursor","ew-resize"),o===U.SLIDER_VIEW&&this.updateSliderSelectedArea(e),this.updateClipPath(t,this.clipId,e[0],0,e[1]-e[0],a)},e.prototype.updateSliderSelectedArea=function(t){var e=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),n=Pt.height[e],r=(sb.getSVGElementSize(this.parent,{useAttrs:!0}).width,this.model.get("axesMargins"));r&&r.left&&r.left;var i=this.getComponentContainer(),o=i.select("svg.zoom-container");sb.appendOrSelect(o,"rect.zoom-slider-selected-area").attr("x",t[0]).attr("y",n/2-1).attr("width",t[1]-t[0]).attr("height",2)},e.prototype.renderZoomBarArea=function(t,e,n,r){var i=this.services.cartesianScales,o=i.getMainXAxisPosition(),a=i.getMainYAxisPosition(),s=i.getMainXScaleType(),u=i.getMainYScaleType(),l=function(t,e,n){return function(r,o){return i.getValueFromScale(t,e,n,r,o)}},c=l(this.xScale,s,o),h=l(this.yScale,u,a),f=Dd(this.getOptions(),"zoomBar",B.TOP,"type"),p=Pt.height[f],d=CA().x((function(t,e){return c(t,e)})).y0(p).y1((function(t,e){return p-h(t,e)})),v=sb.appendOrSelect(t,e).datum(n).attr("d",d);r&&v.attr("clip-path","url(#"+r+")")},e.prototype.updateClipPath=function(t,e,n,r,i,o){var a=sb.appendOrSelect(t,"clipPath").attr("id",e);sb.appendOrSelect(a,"rect").attr("x",n).attr("y",r).attr("width",i).attr("height",o)},e.prototype.compensateDataForDefaultDomain=function(t,e){if(t&&!(t.length<2)){var n=Od(t),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier();if(Number(e[0])<Number(n[0][r])){var o={};o[r]=e[0],o[i]=0,n.unshift(o)}if(Number(e[1])>Number(n[n.length-1][r])){o={};o[r]=e[1],o[i]=0,n.push(o)}return n}},e.prototype.renderZoomBarBaseline=function(t,e,n,r){void 0===r&&(r=!1);var i=Dd(this.model.getOptions(),"zoomBar",B.TOP,"type"),o=Pt.height[i],a=MA()([[e,o],[n,o]]);sb.appendOrSelect(t,"path.zoom-bg-baseline").attr("d",a).classed("zoom-bg-baseline-skeleton",r).style("stroke",r?"url(#"+this.services.domUtils.generateElementIDString("shimmer-lines")+")":null)},e.prototype.renderSkeleton=function(t,e,n){this.renderZoomBarArea(t,"path.zoom-graph-area-unselected",[],null),this.renderZoomBarArea(t,"path.zoom-graph-area",[],this.clipId),this.brush.on("start brush end",null),sb.appendOrSelect(this.getComponentContainer(),this.brushSelector).html(null);var r=Dd(this.getOptions(),"zoomBar",B.TOP,"type");r===U.GRAPH_VIEW&&this.renderZoomBarBaseline(t,e,n,!0)},e.prototype.destroy=function(){this.brush.on("start brush end",null),this.services.events.removeEventListener(ft.ZoomBar.UPDATE,this.render.bind(this))},e}(DS),iU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},oU=function(){function t(t,e){this.services={domUtils:sb,files:hb,events:lb,gradientUtils:vb,transitions:pb,canvasZoom:LS},this.model=new Jm(this.services)}return t.prototype.init=function(t,e){var n=this;this.model.set({holder:t},{skipUpdate:!0}),Object.keys(this.services).forEach((function(t){var e=n.services[t];n.services[t]=new e(n.model,n.services)})),this.services.events.addEventListener(ft.Model.UPDATE,(function(t){var e=!!Dd(t,"detail","animate");n.update(e)})),this.model.setData(e.data),this.services.events.addEventListener(ft.Chart.RESIZE,(function(){n.update(!1)})),this.components=this.getComponents(),this.update()},t.prototype.getComponents=function(){return console.error("getComponents() method is not implemented"),null},t.prototype.update=function(t){var e=this;if(void 0===t&&(t=!0),this.components){Object.keys(this.services).forEach((function(t){var n=e.services[t];n.update()})),this.components.forEach((function(e){return e.render(t)}));var n=this.services.transitions.getPendingTransitions(),r=Object.keys(n).map((function(t){var e=n[t];return e.end().catch((function(t){return t}))}));Promise.all(r).then((function(){return e.services.events.dispatchEvent(ft.Chart.RENDER_FINISHED)}))}},t.prototype.destroy=function(){this.components.forEach((function(t){return t.destroy()})),this.services.domUtils.getHolder().remove(),this.model.set({destroyed:!0},{skipUpdate:!0})},t.prototype.getChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"toolbar","enabled"),i={id:"legend",components:[new PS(this.model,this.services)],growth:Y.PREFERRED},o=Dd(n,"canvasZoom","enabled");o&&!0===o&&t.push(new fA(this.model,this.services));var a=!!this.model.getOptions().title,s={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},u={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},l={id:"header",components:[new WI(this.model,this.services,iU([s],r?[u]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},c={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:Dd(e,"graphFrameRenderType")||I.SVG},h=!0!==Dd(e,"excludeLegend")&&!1!==n.legend.enabled,f=$.COLUMN;if(h){var p=Dd(n,"legend","position");"left"===p?(f=$.ROW,n.legend.orientation||(n.legend.orientation=W.VERTICAL)):"right"===p?(f=$.ROW_REVERSE,n.legend.orientation||(n.legend.orientation=W.VERTICAL)):"bottom"===p&&(f=$.COLUMN_REVERSE)}var d={id:"spacer",components:[new zI(this.model,this.services)],growth:Y.PREFERRED},v={id:"full-frame",components:[new WI(this.model,this.services,iU(h?[i]:[],h?[d]:[],[c]),{direction:f})],growth:Y.STRETCH},g=[];if(a||r){g.push(l);var m={id:"spacer",components:[new zI(this.model,this.services,r?{size:15}:void 0)],growth:Y.PREFERRED};g.push(m)}return g.push(v),[new oA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,g,{direction:$.COLUMN})]},t}(),aU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},uU=function(t){function e(e){var n=t.call(this,e)||this;return n.axisFlavor=ct.DEFAULT,n}return aU(e,t),e.prototype.assignRangeAndDomains=function(){var t=this.services.cartesianScales,e=this.getOptions(),n=t.isDualAxes(),r={primaryDomain:t.domainAxisPosition,primaryRange:t.rangeAxisPosition,secondaryDomain:null,secondaryRange:null};return n&&(r.secondaryDomain=t.secondaryDomainAxisPosition,r.secondaryRange=t.secondaryRangeAxisPosition),Object.keys(r).forEach((function(n){var i=r[n];t.scales[i]?r[n]={position:i,label:t.getScaleLabel(i),identifier:Dd(e,"axes",i,"mapsTo")}:r[n]=null})),r},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.services.cartesianScales,o=this.assignRangeAndDomains(),a=o.primaryDomain,s=o.primaryRange,u=o.secondaryDomain,l=o.secondaryRange,c=i.getDomainAxisScaleType();c===G.TIME&&(t=function(t){return Bm(t,"MMM d, yyyy")});var h=sU([sU(["Group",a.label,s.label],u?[u.label]:[],l?[l.label]:[])],e.map((function(e){return sU([e[r],null===e[a.identifier]?"–":t?t(e[a.identifier]):e[a.identifier],null===e[s.identifier]||isNaN(e[s.identifier])?"–":e[s.identifier].toLocaleString()],u?[null===e[u.identifier]?"–":e[u.identifier]]:[],l?[null===e[l.identifier]||isNaN(e[l.identifier])?"–":e[l.identifier]]:[])})));return h},e.prototype.setData=function(e){var n;if(e&&(n=t.prototype.setData.call(this,e),Dd(this.getOptions(),"zoomBar",B.TOP,"enabled"))){var r=Dd(this.getOptions(),"zoomBar",B.TOP,"data");this.setZoomBarData(r)}return n},e.prototype.setZoomBarData=function(t){var e=t?this.sanitize(Od(t)):this.getDisplayData(),n=e,r=this.services.cartesianScales;if(e&&r.domainAxisPosition&&r.rangeAxisPosition){var i=r.getDomainIdentifier(),o=r.getRangeIdentifier(),a=e.map((function(t){return t[i].getTime()}));a=xd(a).sort(),n=a.map((function(t){var n=0,r={};return e.forEach((function(e){e[i].getTime()===t&&(n+=e[o])})),r[i]=new Date(t),r[o]=n,r}))}this.set({zoomBarData:n})},e.prototype.getZoomBarData=function(){return this.get("zoomBarData")},e.prototype.sanitizeDateValues=function(t){var e=this.getOptions();if(!e.axes)return t;var n=[];return Object.keys(B).forEach((function(t){var r=B[t],i=e.axes[r];if(i&&i.scaleType===G.TIME){var o=i.mapsTo;null===o&&void 0===o||n.push(o)}})),n.length>0&&t.forEach((function(t){n.forEach((function(e){null===Dd(t,e,"getTime")&&(t[e]=new Date(t[e]))}))})),t},e.prototype.sanitize=function(e){return e=t.prototype.sanitize.call(this,e),e=this.sanitizeDateValues(e),e},e}(Jm),lU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),cU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},hU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.services=Object.assign(r.services,{cartesianScales:_T,curves:SS,zoom:CS}),r.model=new uU(r.services),r}return lU(e,t),e.prototype.getAxisChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"zoomBar",B.TOP,"enabled"),i=Dd(n,"toolbar","enabled");this.services.cartesianScales.determineAxisDuality(),this.services.cartesianScales.findDomainAndRangeAxes(),this.services.cartesianScales.determineOrientation();var o=this.services.cartesianScales.getMainXAxisPosition(),a=Dd(n,"axes",o,"scaleType"),s=r&&o===B.BOTTOM&&a===G.TIME,u=this.services.zoom.isZoomBarLocked(B.TOP),l=!!this.model.getOptions().title,c={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},h={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},f={id:"header",components:[new WI(this.model,this.services,cU([c],i?[h]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},p={id:"legend",components:[new PS(this.model,this.services)],growth:Y.PREFERRED};s&&!u&&t.push(new cA(this.model,this.services),new VB(this.model,this.services)),t.push(new JC(this.model,this.services)),t.push(new vA(this.model,this.services));var d={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:I.SVG},v=!1!==Dd(e,"legend","enabled")&&!1!==this.model.getOptions().legend.enabled,g=$.COLUMN;if(v){var m=Dd(this.model.getOptions(),"legend","position");m===z.LEFT?(g=$.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=W.VERTICAL)):m===z.RIGHT?(g=$.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=W.VERTICAL)):m===z.BOTTOM&&(g=$.COLUMN_REVERSE)}var y={id:"spacer",components:[new zI(this.model,this.services)],growth:Y.PREFERRED},_={id:"full-frame",components:[new WI(this.model,this.services,cU(v?[p]:[],v?[y]:[],[d]),{direction:g})],growth:Y.STRETCH},b={id:"zoom-bar",components:[new rU(this.model,this.services)],growth:Y.PREFERRED,renderType:I.SVG},w=[];if(l||i){w.push(f);var O={id:"spacer",components:[new zI(this.model,this.services,i?{size:15}:void 0)],growth:Y.PREFERRED};w.push(O)}return s&&w.push(b),w.push(_),[new uA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,w,{direction:$.COLUMN})]},e}(oU),fU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),pU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(Od(bv.areaChart),n.options)),r.init(e,n),r}return fU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new QA(this.model,this.services),new LA(this.model,this.services),new FA(this.model,this.services,{fadeInOnChartHolderMouseover:!0,handleThresholds:!0}),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),dU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),vU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.stackedAreaChart,n.options)),r.init(e,n),r}return dU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new KB(this.model,this.services),new kA(this.model,this.services),new QA(this.model,this.services,{stacked:!0}),new nL(this.model,this.services,{fadeInOnChartHolderMouseover:!0,handleThresholds:!0,stacked:!0}),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),gU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.simpleBarChart,n.options)),r.init(e,n),r}return gU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new NA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t);return e},e}(hU),yU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),_U=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.groupedBarChart,n.options)),r.init(e,n),r}return yU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new BA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t);return e},e}(hU),bU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),wU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.stackedBarChart,n.options)),r.init(e,n),r}return bU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new KB(this.model,this.services),new VA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ}),new eU(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU);function OU(t=Vv){if(t===Vv)return xU;if("function"!==typeof t)throw new TypeError("compare is not a function");return(e,n)=>{const r=t(e,n);return r||0===r?r:(0===t(n,n))-(0===t(e,e))}}function xU(t,e){return(null==t||!(t>=t))-(null==e||!(e>=e))||(t<e?-1:t>e?1:0)}function EU(t,e,n=0,r=1/0,i){if(e=Math.floor(e),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(t.length-1,r)),!(n<=e&&e<=r))return t;i=void 0===i?xU:OU(i);while(r>n){if(r-n>600){const o=r-n+1,a=e-n+1,s=Math.log(o),u=.5*Math.exp(2*s/3),l=.5*Math.sqrt(s*u*(o-u)/o)*(a-o/2<0?-1:1),c=Math.max(n,Math.floor(e-a*u/o+l)),h=Math.min(r,Math.floor(e+(o-a)*u/o+l));EU(t,e,c,h,i)}const o=t[e];let a=n,s=r;TU(t,n,e),i(t[r],o)>0&&TU(t,n,r);while(a<s){TU(t,a,s),++a,--s;while(i(t[a],o)<0)++a;while(i(t[s],o)>0)--s}0===i(t[n],o)?TU(t,n,s):(++s,TU(t,s,r)),s<=e&&(n=s+1),e<=s&&(r=s-1)}return t}function TU(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function SU(t,e,n){if(t=Float64Array.from(Wv(t,n)),(r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return Vm(t);if(e>=1)return UE(t);var r,i=(r-1)*e,o=Math.floor(i),a=UE(EU(t,o).subarray(0,o+1)),s=Vm(t.subarray(o+1));return a+(s-a)*(i-o)}}var MU,CU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),AU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},LU=function(t){function e(e){return t.call(this,e)||this}return CU(e,t),e.prototype.getBoxQuartiles=function(t){return{q_25:SU(t,.25),q_50:SU(t,.5),q_75:SU(t,.75)}},e.prototype.getBoxplotData=function(){for(var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getGroupedData(),r=[],i=function(t,n){for(var i,a=o.services.cartesianScales.getRangeIdentifier(),s=n.map((function(t){return t[a]})).sort(Vv),u=(i={},i[e]=t,i.counts=s,i.quartiles=o.getBoxQuartiles(s),i.outliers=null,i.whiskers=null,i),l=u.quartiles.q_25,c=u.quartiles.q_75,h=1.5*(c-l),f=l-h,p=c+h,d=[],v=[],g=0,m=s;g<m.length;g++){var y=m[g];y<f||y>p?d.push(y):v.push(y)}u.outliers=d;var _=Vm(v),b=UE(v);u.whiskers={min:_||Vm([u.quartiles.q_25,u.quartiles.q_50,u.quartiles.q_75]),max:b||UE([u.quartiles.q_25,u.quartiles.q_50,u.quartiles.q_75])},r.push(u)},o=this,a=0,s=n;a<s.length;a++){var u=s[a],l=u.name,c=u.data;i(l,c)}return r},e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getBoxplotData(),r=AU([["Group","Minimum","Q1","Median","Q3","Maximum","IQR","Outlier(s)"]],n.map((function(t){var n=Dd(t,"outliers");return null!==n&&0!==n.length||(n=["–"]),[t[e],null!==Dd(t,"whiskers","min")?Dd(t,"whiskers","min").toLocaleString():"–",null!==Dd(t,"quartiles","q_25")?Dd(t,"quartiles","q_25").toLocaleString():"–",null!==Dd(t,"quartiles","q_50")?Dd(t,"quartiles","q_50").toLocaleString():"–",null!==Dd(t,"quartiles","q_75")?Dd(t,"quartiles","q_75").toLocaleString():"–",null!==Dd(t,"whiskers","max")?Dd(t,"whiskers","max").toLocaleString():"–",null!==Dd(t,"quartiles","q_75")&&null!==Dd(t,"quartiles","q_25")?(Dd(t,"quartiles","q_75")-Dd(t,"quartiles","q_25")).toLocaleString():"–",n.map((function(t){return t.toLocaleString()})).join(",")]})));return r},e.prototype.setColorClassNames=function(){var t=1,e=Dd(this.getOptions(),"color","pairing"),n=Dd(e,"option"),r=_t.pairingOptions;n=n<=r[t+"-color"]?n:1;var i=this.allDataGroups.map((function(e,r){return t+"-"+n+"-1"}));this.colorClassNames=Cv().range(i).domain(this.allDataGroups)},e}(uU),DU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new LU(r.services),r.model.setOptions(Td(bv.boxplotChart,n.options)),r.init(e,n),r}return DU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new GA(this.model,this.services),new eU(this.model,this.services),new TL(this.model,this.services,{skeleton:K.VERT_OR_HORIZ})],e=this.getAxisChartComponents(t,{legend:{enabled:!1}});return e},e}(hU),PU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.bubbleChart,n.options)),r.init(e,n),r}return PU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new qA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),IU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},jU=function(t){function e(e){return t.call(this,e)||this}return IU(e,t),e.prototype.getMatchingRangeIndexForDatapoint=function(t){for(var e,n=t.ranges.length-1;n>0;n--){var r=t.ranges[n];if(t.value>=r)return e=n,e}return 0},e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.services.cartesianScales.getRangeIdentifier(),o=Dd(n,"bullet","performanceAreaTitles"),a=NU([["Title","Group","Value","Target","Percentage","Performance"]],e.map((function(e){return[e["title"],e[r],null===e["value"]?"–":e["value"],null===Dd(e,"marker")?"–":e["marker"],null===Dd(e,"marker")?"–":Math.floor(e[i]/e.marker*100)+"%",o[t.getMatchingRangeIndexForDatapoint(e)]]})));return a},e}(uU),BU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new jU(r.services),r.model.setOptions(Td(bv.bulletChart,n.options)),r.init(e,n),r}return BU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new YA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),VU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},GU=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return VU(e,t),e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this.getBinnedStackedData(),r=HU([HU([tl(t,"bins.rangeLabel")||"Range"],n.map((function(t){return tl(t,"0."+e)})))],tl(n,0).map((function(t,r){return HU([tl(t,"data.x0")+" – "+tl(t,"data.x1")],n.map((function(t){return tl(t[r],"data."+tl(t[r],e))})))})));return r},e}(uU),zU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new GU(r.services),r.model.setOptions(Td(bv.histogramChart,n.options)),r.init(e,n),r.update(),r}return zU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new ZB(this.model,this.services),new XA(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),WU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.lineChart,n.options)),r.init(e,n),r}return WU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new QA(this.model,this.services),new FA(this.model,this.services,{handleThresholds:!0}),new ML(this.model,this.services),new eU(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),$U=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.lollipopChart,n.options)),r.init(e,n),r}return $U(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new tL(this.model,this.services),new FA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),ZU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),XU=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Td(bv.scatterChart,n.options)),r.init(e,n),r}return ZU(e,t),e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new GB(this.model,this.services),new qB(this.model,this.services),new FA(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e=this.getAxisChartComponents(t);return e},e}(hU),KU=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),QU=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},JU=function(t){function e(e){return t.call(this,e)||this}return KU(e,t),e.prototype.getTabularData=function(e){var n=t.prototype.getTabularData.call(this,e);return e!==n&&n.forEach((function(t){t.key&&t.key!==t.group&&(t.group=t.key)})),n},e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.data.groupMapsTo,r=QU([["Group","Value"]],t.map((function(t){return[t[n],null===t["value"]?"–":t["value"].toLocaleString()]})));return r},e.prototype.sanitize=function(t){var e=this.getTabularData(t);return e.sort((function(t,e){return e.value-t.value}))},e}(Jm),tV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eV=function(t){function e(e,n,r){void 0===r&&(r=!1);var i=t.call(this,e,n)||this;return i.model=new JU(i.services),r||(i.model.setOptions(Td(bv.pieChart,n.options)),i.init(e,n)),i}return tV(e,t),e.prototype.getComponents=function(){var t=[new gL(this.model,this.services),new TL(this.model,this.services,{skeleton:K.PIE})],e=this.getChartComponents(t);return e},e}(oU),nV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rV=function(t){function e(e,n){var r=t.call(this,e,n,!0)||this;return r.model.setOptions(Td(bv.donutChart,n.options)),r.init(e,n),r}return nV(e,t),e.prototype.getComponents=function(){var t=[new OL(this.model,this.services),new TL(this.model,this.services,{skeleton:K.DONUT})],e=this.getChartComponents(t);return e},e}(eV),iV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},aV=function(t){function e(e){return t.call(this,e)||this}return iV(e,t),e.prototype.getMaximumDomain=function(t){var e=t.reduce((function(t,e){return t+e.value}),0);return e},e.prototype.getFillColor=function(e){var n=this.getOptions(),r=Dd(n,"color","scale"),i=this.getStatus();return r||!i?t.prototype.getFillColor.call(this,e):null},e.prototype.getStatus=function(){var t=this.getOptions(),e=Dd(this.getDisplayData()),n=(e?e.reduce((function(t,e){return{value:t.value+e.value}})):0).value,r=Dd(t,"meter","proportional")?n:n>100?100:n,i=Dd(t,"meter","status","ranges");if(i){var o=i.filter((function(t){return t.range[0]<=r&&r<=t.range[1]}));if(o.length>0)return o[0].status}return null},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.getOptions(),r=n.data.groupMapsTo,i=this.getStatus(),o=Dd(n,"meter","proportional"),a=[];if(null===o){t=100;var s=e[0];a=[oV(["Group","Value"],i?["Status"]:[]),oV([s[r],s["value"]],i?[i]:[])]}else{var u=Dd(o,"total");t=u||this.getMaximumDomain(e),a=oV([["Group","Value","Percentage of total"]],e.map((function(e){return[e[r],e["value"],(e["value"]/t*100).toFixed(2)+" %"]})))}return a},e}(Jm),sV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),uV=function(){return uV=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},uV.apply(this,arguments)},lV=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="meter",e.renderType=I.SVG,e}return sV(e,t),e.prototype.getStackedBounds=function(t,e){var n=0,r=t.map((function(t,r){return 0!==r?(n+=e(t.value),uV(uV({},t),{width:Math.abs(e(t.value)-Et.dividerWidth),x:n-e(t.value)})):(n=e(t.value),uV(uV({},t),{width:Math.abs(e(t.value)-Et.dividerWidth),x:0}))}));return r},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n,r=this,i=this.getComponentContainer(),o=this.getOptions(),s=Dd(o,"meter","proportional"),u=this.model.getDisplayData(),l=this.model.getStatus(),c=sb.getSVGElementSize(i,{useAttrs:!0}).width,h=o.data.groupMapsTo;if(null===Dd(o,"meter","proportional"))n=100;else{var f=Dd(o,"meter","proportional","total");n=f||this.model.getMaximumDomain(this.model.getDisplayData())}var p=BE().domain([0,n]).range([0,c]),d=this.getStackedBounds(u,p),v=Dd(o,"meter","height");sb.appendOrSelect(i,"rect.container").attr("x",0).attr("y",0).attr("width",c).attr("height",v||(s?Et.height.proportional:Et.height.default)),sb.appendOrSelect(i,"line.rangeIndicator").attr("x1",c).attr("x2",c).attr("y1",0).attr("y2",v||(s?Et.height.proportional:Et.height.default));var g=i.selectAll("rect.value").data(d),m=null==l||r.model.isUserProvidedColorScaleValid()||s?"value":"value status--"+l;g.enter().append("rect").classed("value",!0).merge(g).attr("x",(function(t){return t.x})).attr("y",0).attr("height",(function(){var t=Dd(o,"meter","height");return t||(s?Et.height.proportional:Et.height.default)})).attr("class",(function(t){return e.model.getColorClassName({classNameTypes:[j.FILL],dataGroupName:t[h],originalClassName:m})})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"meter-bar-update",animate:t})})).attr("width",(function(t,e){return t.value>n?p(n):t.width})).style("fill",(function(t){return r.model.getFillColor(t[h])})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","value").attr("aria-label",(function(t){return t.value})),g.exit().remove();var y=Dd(o,"meter","peak"),_=y;null!==y&&(y>n?_=n:y<u[0].value&&(_=u[0].value>n?n:u[0].value));var b=i.selectAll("line.peak").data(null==_?[]:[_]);b.enter().append("line").classed("peak",!0).merge(b).attr("y1",0).attr("y2",(function(){var t=Dd(o,"meter","height");return t||(s?Et.height.proportional:Et.height.default)})).transition().call((function(n){return e.services.transitions.setupTransition({transition:n,name:"peak-line-update",animate:t})})).attr("x1",(function(t){return p(t)})).attr("x2",(function(t){return p(t)})).attr("role",a.GRAPHICS_SYMBOL).attr("aria-roledescription","peak").attr("aria-label",(function(t){return t})),b.exit().remove(),this.services.domUtils.setSVGMaxHeight(),this.addEventListeners()},e.prototype.addEventListeners=function(){var t=this.getOptions(),e=t.data.groupMapsTo,n=this,r=Dd(t,"meter","proportional");this.parent.selectAll("rect.value").on("mouseover",(function(t,i){var o=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEOVER,{event:t,element:o,datum:i}),r&&(o.classed("hovered",!0),n.services.events.dispatchEvent(ft.Tooltip.SHOW,{event:t,hoveredElement:o,items:[{label:i[e],value:i.value}]}))})).on("mousemove",(function(t,e){var i=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEMOVE,{event:t,element:i,datum:e}),r&&n.services.events.dispatchEvent(ft.Tooltip.MOVE,{event:t})})).on("click",(function(t,e){n.services.events.dispatchEvent(ft.Meter.METER_CLICK,{event:t,element:eb(this),datum:e})})).on("mouseout",(function(t,e){var i=eb(this);n.services.events.dispatchEvent(ft.Meter.METER_MOUSEOUT,{event:t,element:i,datum:e}),r&&(i.classed("hovered",!1),n.services.events.dispatchEvent(ft.Tooltip.HIDE,{hoveredElement:i}))}))},e.prototype.destroy=function(){this.parent.selectAll("rect.value").on("mouseover",null).on("mousemove",null).on("mouseout",null).on("click",null)},e}(DS),cV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),hV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},fV=function(t){function e(e,n){var r=t.call(this,e,n)||this;r.model=new aV(r.services);var i=n.options.meter.proportional?na(Od(bv.proportionalMeterChart),n.options):na(Od(bv.meterChart),n.options);return r.model.setOptions(i),r.init(e,n),r}return cV(e,t),e.prototype.getComponents=function(){var t=Dd(this.model.getOptions(),"meter","showLabels"),e=hV(t?[{id:"meter-title",components:[new rA(this.model,this.services)],growth:Y.STRETCH,renderType:I.SVG},{id:"spacer",components:[new zI(this.model,this.services,{size:8})],growth:Y.STRETCH}]:[],[{id:"meter-graph",components:[new lV(this.model,this.services)],growth:Y.STRETCH,renderType:I.SVG}]),n=[new WI(this.model,this.services,e,{direction:$.COLUMN})],r=this.getChartComponents(n,{graphFrameRenderType:I.HTML});return r},e}(oU),pV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},vV=function(t){function e(e){return t.call(this,e)||this}return pV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getOptions(),e=this.getGroupedData(),n=Dd(t,"radar","axes"),r=n.angle,i=n.value,o=Dd(e,"0","data").map((function(t){return t[r]})),a=dV([dV(["Group"],o)],e.map((function(t){return dV([t["name"]],o.map((function(e,n){return null!==Dd(t,"data",n,i)?Dd(t,"data",n,i).toLocaleString():"–"})))})));return a},e}(uU),gV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),mV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new vV(r.services),r.model.setOptions(Td(bv.radarChart,n.options)),r.init(e,n),r}return gV(e,t),e.prototype.getComponents=function(){var t=[new xR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),yV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),_V=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},bV=function(t){function e(e){return t.call(this,e)||this}return yV(e,t),e.prototype.getDataGroups=function(){return t.prototype.getDataGroups.call(this).filter((function(t){return"delta"!==t.name}))},e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.data.groupMapsTo,r=_V([["Group","Value"]],t.map((function(t){return[t[n],null===t["value"]?"–":t["value"].toLocaleString()]})));return r},e}(Jm),wV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),OV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new bV(r.services),r.model.setOptions(Td(bv.gaugeChart,n.options)),r.init(e,n),r}return wV(e,t),e.prototype.getComponents=function(){var t=[new bL(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),xV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),EV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},TV=(MU={},MU[it.LINE]=[QA,FA],MU[it.SCATTER]=[FA],MU[it.AREA]=[LA,QA,FA],MU[it.STACKED_AREA]=[kA,QA,nL,KB],MU[it.SIMPLE_BAR]=[NA],MU[it.GROUPED_BAR]=[BA,eU],MU[it.STACKED_BAR]=[VA,KB],MU),SV=function(t){function e(e,n){var r=t.call(this,e,n)||this,i=Td(bv.comboChart,n.options);return n.options.comboChartTypes||(console.error("No comboChartTypes defined for the Combo Chart!"),i.comboChartTypes=[{type:it.LINE,correspondingDatasets:[]}]),r.model.setOptions(i),r.init(e,n),r}return xV(e,t),e.prototype.getGraphComponents=function(){var t=this,e=this.model.getOptions().comboChartTypes,n=0,r=e.map((function(e){var r,i,o=e.type;return"string"===typeof e.type?Object.keys(TV).includes(e.type)?(r=na({},bv[Rh(e.type)+"Chart"],t.model.getOptions(),e.options),e.type===it.STACKED_AREA&&(i=!0),TV[e.type].map((function(o,a){return new o(t.model,t.services,{groups:e.correspondingDatasets,id:n++,options:r,stacked:i})}))):(console.error('Invalid chart type "'+e.type+'" specified for combo chart. Please refer to the ComboChart tutorial for more guidance.'),null):(r=na({},t.model.getOptions(),e.options),new o(t.model,t.services,{groups:e.correspondingDatasets,id:n++,options:r}))})).filter((function(t){return null!==t}));return va(r)},e.prototype.getComponents=function(){var t=this.model.getOptions().comboChartTypes,e=t.some((function(t){return t.type===it.STACKED_BAR||t.type===it.STACKED_AREA})),n=EV([new QI(this.model,this.services),new GB(this.model,this.services),new TL(this.model,this.services,{skeleton:K.GRID})],e?[]:[new qB(this.model,this.services)],this.getGraphComponents()),r=this.getAxisChartComponents(n);return r},e}(hU),MV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),CV=function(t){function e(e){return t.call(this,e)||this}return MV(e,t),e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=[["Child","Parent"]];return e.forEach((function(e){t.getChildrenDatums(e,n),n.push([e.name,"–"])})),n},e.prototype.getChildrenDatums=function(t,e){var n=this;void 0===e&&(e=[]),t.children&&t.children.length>0&&t.children.forEach((function(r){n.getChildrenDatums(r,e),e.push([r.name,t.name])}))},e}(Jm),AV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),LV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new CV(r.services),r.model.setOptions(Td(bv.treeChart,n.options)),r.init(e,n),r}return AV(e,t),e.prototype.getComponents=function(){var t=[new wD(this.model,this.services)],e=this.getChartComponents(t,{excludeLegend:!0});return e},e}(oU),DV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kV=function(t){function e(e){return t.call(this,e)||this}return DV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=[["Child","Group","Value"]];return t.forEach((function(t){Array.isArray(t.children)?t.children.forEach((function(n){e.push([n.name,t.name,n.value])})):null!==Dd(t.name)&&Dd(t.value)&&e.push(["–",t.name,t.value])})),e},e}(Jm),PV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),RV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new kV(r.services),r.model.setOptions(Td(bv.treemapChart,n.options)),r.init(e,n),r}return PV(e,t),e.prototype.getComponents=function(){var t=[new cR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),IV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NV=function(){return NV=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n],e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},NV.apply(this,arguments)},jV=function(t){function e(e){var n=t.call(this,e)||this;return n.parentNode=!1,n.set({depth:2},{skipUpdate:!0}),n}return IV(e,t),e.prototype.setData=function(e){t.prototype.setData.call(this,e),this.setDataGroups(),1===e.length&&(this.parentNode=!0),this.setZoom()},e.prototype.setOptions=function(t){var e=this.getOptions(),n=na({},t,this.getZoomOptions(t));Ld(e,n);var r=this.getHierarchyLevel(),i=Dd(e,"circlePack","hierarchyLevel");this.set({options:na(e,n),depth:i&&i<4?i:r})},e.prototype.getZoomOptions=function(t){if(!this.getDisplayData())return{};var e=this.getDisplayData(),n=t||this.getOptions(),r=1===e.length&&Dd(e,0,"children")?Dd(e,0,"children"):e,i=this.getHierarchyLevel();return r.some((function(t){if(t.children&&t.children.some((function(t){return t.children})))return i=3,!1})),!0===Dd(n,"canvasZoom","enabled")&&i>2?{legend:{additionalItems:[{type:st.ZOOM,name:"Click to zoom"}]}}:null},e.prototype.setZoom=function(t){this.setOptions(this.getZoomOptions(t))},e.prototype.updateHierarchyLevel=function(t){this.set({depth:t})},e.prototype.getHierarchyLevel=function(){return this.get("depth")},e.prototype.hasParentNode=function(){return this.parentNode},e.prototype.setDataGroups=function(){var t=this,e=this.getData(),n=this.getOptions(),r=n.data.groupMapsTo,i=e.map((function(e){var n=e[r];return t.setChildrenDataGroup(e,n)}));this.set({data:i},{skipUpdate:!0})},e.prototype.setChildrenDataGroup=function(t,e){var n=this;return t.children?NV(NV({},t),{dataGroupName:e,children:t.children.map((function(t,r){return n.setChildrenDataGroup(t,e)}))}):NV(NV({},t),{dataGroupName:e})},e.prototype.getTabularDataArray=function(){var t=this,e=this.getDisplayData(),n=[["Child","Parent","Value"]];return e.forEach((function(e){var r=e.value?e.value:0;e.children&&(r+=t.getChildrenDatums(e.children,e.name,n,0)),n.push(["–",e.name,r])})),n},e.prototype.getChildrenDatums=function(t,e,n,r){var i=this;void 0===n&&(n=[]),void 0===r&&(r=0);var o=e;return t.forEach((function(t){var e=t.name,a=0;if(t.children)t.children.length>0&&("number"===typeof t.value&&(r+=t.value),a+=i.getChildrenDatums(t.children,e,n,a),n.push([e,o,a]),r+=a);else{var s=0;"number"===typeof t.value&&(s=t.value,r+=t.value),n.push([t.name,o,s])}})),r},e}(Jm),BV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),UV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new jV(r.services),r.model.setOptions(Td(bv.circlePackChart,n.options)),r.init(e,n),r}return BV(e,t),e.prototype.getComponents=function(){var t=[new KR(this.model,this.services)],e=this.getChartComponents(t);return e},e}(oU),VV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},GV=function(t){function e(e){return t.call(this,e)||this}return VV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData(),e=this.getOptions(),n=e.wordCloud,r=n.fontSizeMapsTo,i=n.wordMapsTo,o=e.data.groupMapsTo,a=HV([[e.tooltip.wordLabel,"Group",e.tooltip.valueLabel]],t.map((function(t){return[t[i],t[o],t[r]]})));return a},e}(Jm),zV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),FV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new GV(r.services),r.model.setOptions(Td(bv.wordCloudChart,n.options)),r.init(e,n),r}return zV(e,t),e.prototype.getComponents=function(){var t=[new eI(this.model,this.services),new TL(this.model,this.services,{skeleton:K.PIE})],e=this.getChartComponents(t);return e},e}(oU),WV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),qV=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},$V=function(t){function e(e){return t.call(this,e)||this}return WV(e,t),e.prototype.getTabularDataArray=function(){var t=this.getDisplayData();t.sort((function(t,e){return t["source"].localeCompare(e["source"])}));var e=qV([["Source","Target","Value"]],t.map((function(t){return[t["source"],t["target"],t["value"]]})));return e},e}(uU),YV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ZV=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new $V(r.services),r.model.setOptions(Td(bv.alluvialChart,n.options)),r.init(e,n),r}return YV(e,t),e.prototype.getComponents=function(){var t=[new UI(this.model,this.services)],e=this.getChartComponents(t,{excludeLegend:!0});return e},e}(oU);function XV(){var t,e=0,n=1,r=1,i=[.5],o=[0,1];function a(e){return null!=e&&e<=e?o[Yv(i,e,0,r)]:t}function s(){var t=-1;i=new Array(r);while(++t<r)i[t]=((t+1)*n-(t-r)*e)/(r+1);return a}return a.domain=function(t){return arguments.length?([e,n]=t,e=+e,n=+n,s()):[e,n]},a.range=function(t){return arguments.length?(r=(o=Array.from(t)).length-1,s()):o.slice()},a.invertExtent=function(t){var a=o.indexOf(t);return a<0?[NaN,NaN]:a<1?[e,i[0]]:a>=r?[i[r-1],n]:[i[a-1],i[a]]},a.unknown=function(e){return arguments.length?(t=e,a):a},a.thresholds=function(){return i.slice()},a.copy=function(){return XV().domain([e,n]).range(o).unknown(t)},Sv.apply(jE(a),arguments)}var KV,QV,JV=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tH=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},eH=function(t){function e(e){var n=t.call(this,e)||this;n.axisFlavor=ct.HOVERABLE,n._colorScale=void 0,n._domains=[],n._ranges=[],n._matrix={};var r=Dd(n.getOptions(),"axes");if(Dd(r,"left","scaleType")&&Dd(r,"left","scaleType")!==G.LABELS||Dd(r,"right","scaleType")&&Dd(r,"right","scaleType")!==G.LABELS||Dd(r,"top","scaleType")&&Dd(r,"top","scaleType")!==G.LABELS||Dd(r,"bottom","scaleType")&&Dd(r,"bottom","scaleType")!==G.LABELS)throw Error("Heatmap only supports label scaletypes.");return n}return JV(e,t),e.prototype.getValueDomain=function(){var t=Xv(this.getDisplayData(),(function(t){return t.value})),e=BE().domain(t).nice().domain();if(e[0]>0)e[0]=0;else if(0===e[0]&&0===e[1])return[0,1];return e[0]<0&&e[1]>0&&(Math.abs(e[0])>e[1]?e[1]=Math.abs(e[0]):e[0]=-e[1]),e},e.prototype.getFillColor=function(t){return this._colorScale(t)},e.prototype.getUniqueDomain=function(){if(Vh(this._domains)){var t=this.getDisplayData(),e=this.services.cartesianScales,n=e.getDomainIdentifier(),r=e.getMainXAxisPosition(),i=e.getCustomDomainValuesByposition(r);if(i)return i;this._domains=Array.from(new Set(t.map((function(t){return t[n]}))))}return this._domains},e.prototype.getUniqueRanges=function(){if(Vh(this._ranges)){var t=this.getDisplayData(),e=this.services.cartesianScales,n=e.getRangeIdentifier(),r=e.getMainYAxisPosition(),i=e.getCustomDomainValuesByposition(r);if(i)return i;this._ranges=Array.from(new Set(t.map((function(t){return t[n]}))))}return this._ranges},e.prototype.getMatrix=function(){var t=this;if(Vh(this._matrix)){var e=this.getUniqueDomain(),n=this.getUniqueRanges(),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier(),o={};n.forEach((function(t){o[t]={value:null,index:-1}})),e.forEach((function(e){t._matrix[e]=Od(o)})),this.getDisplayData().forEach((function(e,n){t._matrix[e[r]][e[i]]={value:e["value"],index:n}}))}return this._matrix},e.prototype.setData=function(t){var e=this.sanitize(Od(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),this._domains=[],this._ranges=[],this._matrix={},e},e.prototype.getMatrixAsArray=function(){var t=this;Vh(this._matrix)&&this.getMatrix();var e=this.getUniqueDomain(),n=this.getUniqueRanges(),r=this.services.cartesianScales.getDomainIdentifier(),i=this.services.cartesianScales.getRangeIdentifier(),o=[];return e.forEach((function(e){n.forEach((function(n){var a={value:t._matrix[e][n].value,index:t._matrix[e][n].index};a[r]=e,a[i]=n,o.push(a)}))})),o},e.prototype.getTabularDataArray=function(){var t,e=this.getDisplayData(),n=this.assignRangeAndDomains(),r=n.primaryDomain,i=n.primaryRange,o=tH([[r.label,i.label,"Value"]],e.map((function(e){return[null===e[r.identifier]?"–":t?t(e[r.identifier]):e[r.identifier],null===e[i.identifier]?"–":e[i.identifier].toLocaleString(),e["value"]]})));return o},e.prototype.getColorClassName=function(t){return t.originalClassName+" "+this._colorScale(t.value)},e.prototype.setColorClassNames=function(){var t=this.getOptions(),e=Dd(t,"color","gradient","colors"),n=!Vh(e),r=Dd(t,"color","pairing","option"),i=this.getValueDomain(),o=i[0]<0&&i[1]>0?"diverge":"mono";(r<1&&r>4&&"mono"===o||r<1&&r>2&&"diverge"===o)&&(r=1);var a=n?e:[];if(!n)for(var s="diverge"===o?17:11,u=1;u<s+1;u++)a.push("fill-"+o+"-"+r+"-"+u);this._colorScale=XV().domain(i).range(a)},e}(uU),nH=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},t(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rH=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},iH=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new eH(r.services),r.model.setOptions(Td(bv.heatmapChart,n.options)),r.init(e,n),r}return nH(e,t),e.prototype.getAxisChartComponents=function(t,e){var n=this.model.getOptions(),r=Dd(n,"toolbar","enabled");this.services.cartesianScales.determineAxisDuality(),this.services.cartesianScales.findDomainAndRangeAxes(),this.services.cartesianScales.determineOrientation();var i=!!this.model.getOptions().title,o={id:"title",components:[new eA(this.model,this.services)],growth:Y.STRETCH},a={id:"toolbar",components:[new JB(this.model,this.services)],growth:Y.PREFERRED},s={id:"header",components:[new WI(this.model,this.services,rH([o],r?[a]:[]),{direction:$.ROW,alignItems:Z.CENTER})],growth:Y.PREFERRED},u={id:"legend",components:[new QS(this.model,this.services)],growth:Y.PREFERRED,renderType:I.SVG},l={id:"graph-frame",components:t,growth:Y.STRETCH,renderType:I.SVG},c=!1!==Dd(e,"legend","enabled")&&!1!==this.model.getOptions().legend.enabled,h=$.COLUMN_REVERSE,f={id:"spacer",components:[new zI(this.model,this.services,{size:15})],growth:Y.PREFERRED},p={id:"full-frame",components:[new WI(this.model,this.services,rH(c?[u]:[],c?[f]:[],[l]),{direction:h})],growth:Y.STRETCH},d=[];if(i||r){d.push(s);var v={id:"spacer",components:[new zI(this.model,this.services,r?{size:15}:void 0)],growth:Y.PREFERRED};d.push(v)}return d.push(p),[new uA(this.model,this.services),new $C(this.model,this.services),new WI(this.model,this.services,d,{direction:$.COLUMN})]},e.prototype.getComponents=function(){var t=[new QI(this.model,this.services),new HI(this.model,this.services)],e=this.getAxisChartComponents(t);return e},e}(hU),oH={name:"CcvBaseChart",data:function(){return{coreChart:null}},props:{data:{type:[Object,Array],required:!0},options:{type:Object,required:!0}},watch:{data:{handler:function(t){this.coreChart.model.setData(t)},deep:!0},options:{handler:function(t){this.coreChart.model.setOptions(t)},deep:!0}}},aH=oH;function sH(t,e,n,r,i,o,a,s){var u,l="function"===typeof t?t.options:t;if(e&&(l.render=e,l.staticRenderFns=n,l._compiled=!0),r&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),a?(u=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},l._ssrRegister=u):i&&(u=s?function(){i.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:i),u)if(l.functional){l._injectStyles=u;var c=l.render;l.render=function(t,e){return u.call(e),c(t,e)}}else{var h=l.beforeCreate;l.beforeCreate=h?[].concat(h,u):[u]}return{exports:t,options:l}}var uH=sH(aH,KV,QV,!1,null,null,null),lH=uH.exports,cH={name:"CcvAreaChart",extends:lH,mounted:function(){this.coreChart=new pU(this.$el,{data:this.data,options:this.options})}},hH=cH,fH=sH(hH,P,R,!1,null,null,null),pH=fH.exports,dH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-stacked-area-chart"})},vH=[],gH={name:"CcvStackedAreaChart",extends:lH,mounted:function(){this.coreChart=new vU(this.$el,{data:this.data,options:this.options})}},mH=gH,yH=sH(mH,dH,vH,!1,null,null,null),_H=yH.exports,bH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-simple-bar-chart"})},wH=[],OH={name:"CcvSimpleBarChart",extends:lH,mounted:function(){this.coreChart=new mU(this.$el,{data:this.data,options:this.options})}},xH=OH,EH=sH(xH,bH,wH,!1,null,null,null),TH=EH.exports,SH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-grouped-bar-chart"})},MH=[],CH={name:"CcvGroupedBarChart",extends:lH,mounted:function(){this.coreChart=new _U(this.$el,{data:this.data,options:this.options})}},AH=CH,LH=sH(AH,SH,MH,!1,null,null,null),DH=LH.exports,kH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-stacked-bar-chart"})},PH=[],RH={name:"CcvStackedBarChart",extends:lH,mounted:function(){this.coreChart=new wU(this.$el,{data:this.data,options:this.options})}},IH=RH,NH=sH(IH,kH,PH,!1,null,null,null),jH=NH.exports,BH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-boxplot-chart"})},UH=[],VH={name:"CcvBoxplotChart",extends:lH,mounted:function(){this.coreChart=new kU(this.$el,{data:this.data,options:this.options})}},HH=VH,GH=sH(HH,BH,UH,!1,null,null,null),zH=GH.exports,FH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-bubble-chart"})},WH=[],qH={name:"CcvBubbleChart",extends:lH,mounted:function(){this.coreChart=new RU(this.$el,{data:this.data,options:this.options})}},$H=qH,YH=sH($H,FH,WH,!1,null,null,null),ZH=YH.exports,XH=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-bullet-chart"})},KH=[],QH={name:"CcvBulletChart",extends:lH,mounted:function(){this.coreChart=new UU(this.$el,{data:this.data,options:this.options})}},JH=QH,tG=sH(JH,XH,KH,!1,null,null,null),eG=tG.exports,nG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-donut-chart"})},rG=[],iG={name:"CcvDonutChart",extends:lH,mounted:function(){this.coreChart=new rV(this.$el,{data:this.data,options:this.options})}},oG=iG,aG=sH(oG,nG,rG,!1,null,null,null),sG=aG.exports,uG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-gauge-chart"})},lG=[],cG={name:"CcvGaugeChart",extends:lH,mounted:function(){this.coreChart=new OV(this.$el,{data:this.data,options:this.options})}},hG=cG,fG=sH(hG,uG,lG,!1,null,null,null),pG=fG.exports,dG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-histogram-chart"})},vG=[],gG={name:"CcvHistogramChart",extends:lH,mounted:function(){this.coreChart=new FU(this.$el,{data:this.data,options:this.options})}},mG=gG,yG=sH(mG,dG,vG,!1,null,null,null),_G=yG.exports,bG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-line-chart"})},wG=[],OG={name:"CcvLineChart",extends:lH,mounted:function(){this.coreChart=new qU(this.$el,{data:this.data,options:this.options})}},xG=OG,EG=sH(xG,bG,wG,!1,null,null,null),TG=EG.exports,SG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-lollipop-chart"})},MG=[],CG={name:"CcvLollipopChart",extends:lH,mounted:function(){this.coreChart=new YU(this.$el,{data:this.data,options:this.options})}},AG=CG,LG=sH(AG,SG,MG,!1,null,null,null),DG=LG.exports,kG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-pie-chart"})},PG=[],RG={name:"CcvPieChart",extends:lH,mounted:function(){this.coreChart=new eV(this.$el,{data:this.data,options:this.options})}},IG=RG,NG=sH(IG,kG,PG,!1,null,null,null),jG=NG.exports,BG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-scatter-chart"})},UG=[],VG={name:"CcvScatterChart",extends:lH,mounted:function(){this.coreChart=new XU(this.$el,{data:this.data,options:this.options})}},HG=VG,GG=sH(HG,BG,UG,!1,null,null,null),zG=GG.exports,FG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-meter-chart"})},WG=[],qG={name:"CcvMeterChart",extends:lH,mounted:function(){this.coreChart=new fV(this.$el,{data:this.data,options:this.options})}},$G=qG,YG=sH($G,FG,WG,!1,null,null,null),ZG=YG.exports,XG=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-radar-chart"})},KG=[],QG={name:"CcvRadarChart",extends:lH,mounted:function(){this.coreChart=new mV(this.$el,{data:this.data,options:this.options})}},JG=QG,tz=sH(JG,XG,KG,!1,null,null,null),ez=tz.exports,nz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-combo-chart"})},rz=[],iz={name:"CcvComboChart",extends:lH,mounted:function(){this.coreChart=new SV(this.$el,{data:this.data,options:this.options})}},oz=iz,az=sH(oz,nz,rz,!1,null,null,null),sz=az.exports,uz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-tree-chart"})},lz=[],cz={name:"CcvTreeChart",extends:lH,mounted:function(){this.coreChart=new LV(this.$el,{data:this.data,options:this.options})}},hz=cz,fz=sH(hz,uz,lz,!1,null,null,null),pz=fz.exports,dz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-treemap-chart"})},vz=[],gz={name:"CcvTreemapChart",extends:lH,mounted:function(){this.coreChart=new RV(this.$el,{data:this.data,options:this.options})}},mz=gz,yz=sH(mz,dz,vz,!1,null,null,null),_z=yz.exports,bz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-circle-pack-chart"})},wz=[],Oz={name:"CcvCirclePackChart",extends:lH,mounted:function(){this.coreChart=new UV(this.$el,{data:this.data,options:this.options})}},xz=Oz,Ez=sH(xz,bz,wz,!1,null,null,null),Tz=Ez.exports,Sz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-wordcloud-chart"})},Mz=[],Cz={name:"CcvWordCloudChart",extends:lH,mounted:function(){this.coreChart=new FV(this.$el,{data:this.data,options:this.options})}},Az=Cz,Lz=sH(Az,Sz,Mz,!1,null,null,null),Dz=Lz.exports,kz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-alluvial-chart"})},Pz=[],Rz={name:"CcvAlluvialChart",extends:lH,mounted:function(){this.coreChart=new ZV(this.$el,{data:this.data,options:this.options})}},Iz=Rz,Nz=sH(Iz,kz,Pz,!1,null,null,null),jz=Nz.exports,Bz=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"ccv-heatmap-chart"})},Uz=[],Vz={name:"CcvHeatmapChart",extends:lH,mounted:function(){this.coreChart=new iH(this.$el,{data:this.data,options:this.options})}},Hz=Vz,Gz=sH(Hz,Bz,Uz,!1,null,null,null),zz=Gz.exports,Fz=[pH,_H,TH,DH,jH,zH,ZH,eG,sG,pG,_G,TG,DG,jG,zG,ZG,ez,sz,pz,_z,Tz,Dz,jz,zz],Wz={install:function(t,e){if("undefined"===typeof e)for(var n=0,r=Fz;n<r.length;n++){var i=r[n];t.component(i.name,i)}else{if(!(e instanceof Array))throw new TypeError("options must be an array");for(var o=0,a=Fz;o<a.length;o++){var s=a[o];e.includes(s.name)&&t.component(s.name,s)}}}};e["default"]=Wz},"1d8a":function(t,e,n){var r=n("70b7"),i=0,o=Math.random(),a=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+a(++i+o,36)}},"1f5e":function(t,e,n){var r=n("378c"),i=n("9a0f"),o=n("0481"),a=function(t){return function(e,n,a){var s,u=r(e),l=o(u),c=i(a,l);if(t&&n!=n){while(l>c)if(s=u[c++],s!=s)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:a(!0),indexOf:a(!1)}},2402:function(t,e){e.f=Object.getOwnPropertySymbols},"2a3e":function(t,e,n){var r=n("da06"),i=String;t.exports=function(t){if("Symbol"===r(t))throw TypeError("Cannot convert a Symbol value to a string");return i(t)}},"2a60":function(t,e,n){var r=n("8320").dispatch,i=Math.PI/180,o=64,a=2048;function s(t){return t.text}function u(){return"serif"}function l(){return"normal"}function c(t){return Math.sqrt(t.value)}function h(){return 30*(~~(6*Math.random())-3)}function f(){return 1}function p(t,e,n,r){if(!e.sprite){var s=t.context,u=t.ratio;s.clearRect(0,0,(o<<5)/u,a/u);var l=0,c=0,h=0,f=n.length;--r;while(++r<f){e=n[r],s.save(),s.font=e.style+" "+e.weight+" "+~~((e.size+1)/u)+"px "+e.font;var p=s.measureText(e.text+"m").width*u,d=e.size<<1;if(e.rotate){var v=Math.sin(e.rotate*i),g=Math.cos(e.rotate*i),m=p*g,y=p*v,_=d*g,b=d*v;p=Math.max(Math.abs(m+b),Math.abs(m-b))+31>>5<<5,d=~~Math.max(Math.abs(y+_),Math.abs(y-_))}else p=p+31>>5<<5;if(d>h&&(h=d),l+p>=o<<5&&(l=0,c+=h,h=0),c+d>=a)break;s.translate((l+(p>>1))/u,(c+(d>>1))/u),e.rotate&&s.rotate(e.rotate*i),s.fillText(e.text,0,0),e.padding&&(s.lineWidth=2*e.padding,s.strokeText(e.text,0,0)),s.restore(),e.width=p,e.height=d,e.xoff=l,e.yoff=c,e.x1=p>>1,e.y1=d>>1,e.x0=-e.x1,e.y0=-e.y1,e.hasText=!0,l+=p}var w=s.getImageData(0,0,(o<<5)/u,a/u).data,O=[];while(--r>=0)if(e=n[r],e.hasText){p=e.width;for(var x=p>>5,E=(d=e.y1-e.y0,0);E<d*x;E++)O[E]=0;if(l=e.xoff,null==l)return;c=e.yoff;for(var T=0,S=-1,M=0;M<d;M++){for(E=0;E<p;E++){var C=x*M+(E>>5),A=w[(c+M)*(o<<5)+(l+E)<<2]?1<<31-E%32:0;O[C]|=A,T|=A}T?S=M:(e.y0++,d--,M--,c++)}e.y1=e.y0+S,e.sprite=O.slice(0,(e.y1-e.y0)*x)}}}function d(t,e,n){n>>=5;for(var r,i=t.sprite,o=t.width>>5,a=t.x-(o<<4),s=127&a,u=32-s,l=t.y1-t.y0,c=(t.y+t.y0)*n+(a>>5),h=0;h<l;h++){r=0;for(var f=0;f<=o;f++)if((r<<u|(f<o?(r=i[h*o+f])>>>s:0))&e[c+f])return!0;c+=n}return!1}function v(t,e){var n=t[0],r=t[1];e.x+e.x0<n.x&&(n.x=e.x+e.x0),e.y+e.y0<n.y&&(n.y=e.y+e.y0),e.x+e.x1>r.x&&(r.x=e.x+e.x1),e.y+e.y1>r.y&&(r.y=e.y+e.y1)}function g(t,e){return t.x+t.x1>e[0].x&&t.x+t.x0<e[1].x&&t.y+t.y1>e[0].y&&t.y+t.y0<e[1].y}function m(t){var e=t[0]/t[1];return function(t){return[e*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function y(t){var e=4,n=e*t[0]/t[1],r=0,i=0;return function(t){var o=t<0?-1:1;switch(Math.sqrt(1+4*o*t)-o&3){case 0:r+=n;break;case 1:i+=e;break;case 2:r-=n;break;default:i-=e;break}return[r,i]}}function _(t){var e=[],n=-1;while(++n<t)e[n]=0;return e}function b(){return document.createElement("canvas")}function w(t){return"function"===typeof t?t:function(){return t}}t.exports=function(){var t=[256,256],e=s,n=u,i=c,y=l,x=l,E=h,T=f,S=m,M=[],C=1/0,A=r("word","end"),L=null,D=Math.random,k={},P=b;function R(t){t.width=t.height=1;var e=Math.sqrt(t.getContext("2d").getImageData(0,0,1,1).data.length>>2);t.width=(o<<5)/e,t.height=a/e;var n=t.getContext("2d");return n.fillStyle=n.strokeStyle="red",n.textAlign="center",{context:n,ratio:e}}function I(e,n,r){t[0],t[1];var i,o,a,s=n.x,u=n.y,l=Math.sqrt(t[0]*t[0]+t[1]*t[1]),c=S(t),h=D()<.5?1:-1,f=-h;while(i=c(f+=h)){if(o=~~i[0],a=~~i[1],Math.min(Math.abs(o),Math.abs(a))>=l)break;if(n.x=s+o,n.y=u+a,!(n.x+n.x0<0||n.y+n.y0<0||n.x+n.x1>t[0]||n.y+n.y1>t[1])&&(!r||!d(n,e,t[0]))&&(!r||g(n,r))){for(var p,v=n.sprite,m=n.width>>5,y=t[0]>>5,_=n.x-(m<<4),b=127&_,w=32-b,O=n.y1-n.y0,x=(n.y+n.y0)*y+(_>>5),E=0;E<O;E++){p=0;for(var T=0;T<=m;T++)e[x+T]|=p<<w|(T<m?(p=v[E*m+T])>>>b:0);x+=y}return delete n.sprite,!0}}return!1}return k.canvas=function(t){return arguments.length?(P=w(t),k):P},k.start=function(){var r=R(P()),o=_((t[0]>>5)*t[1]),a=null,s=M.length,u=-1,l=[],c=M.map((function(t,r){return t.text=e.call(this,t,r),t.font=n.call(this,t,r),t.style=y.call(this,t,r),t.weight=x.call(this,t,r),t.rotate=E.call(this,t,r),t.size=~~i.call(this,t,r),t.padding=T.call(this,t,r),t})).sort((function(t,e){return e.size-t.size}));return L&&clearInterval(L),L=setInterval(h,0),h(),k;function h(){var e=Date.now();while(Date.now()-e<C&&++u<s&&L){var n=c[u];n.x=t[0]*(D()+.5)>>1,n.y=t[1]*(D()+.5)>>1,p(r,n,c,u),n.hasText&&I(o,n,a)&&(l.push(n),A.call("word",k,n),a?v(a,n):a=[{x:n.x+n.x0,y:n.y+n.y0},{x:n.x+n.x1,y:n.y+n.y1}],n.x-=t[0]>>1,n.y-=t[1]>>1)}u>=s&&(k.stop(),A.call("end",k,l,a))}},k.stop=function(){return L&&(clearInterval(L),L=null),k},k.timeInterval=function(t){return arguments.length?(C=null==t?1/0:t,k):C},k.words=function(t){return arguments.length?(M=t,k):M},k.size=function(e){return arguments.length?(t=[+e[0],+e[1]],k):t},k.font=function(t){return arguments.length?(n=w(t),k):n},k.fontStyle=function(t){return arguments.length?(y=w(t),k):y},k.fontWeight=function(t){return arguments.length?(x=w(t),k):x},k.rotate=function(t){return arguments.length?(E=w(t),k):E},k.text=function(t){return arguments.length?(e=w(t),k):e},k.spiral=function(t){return arguments.length?(S=O[t]||t,k):S},k.fontSize=function(t){return arguments.length?(i=w(t),k):i},k.padding=function(t){return arguments.length?(T=w(t),k):T},k.random=function(t){return arguments.length?(D=t,k):D},k.on=function(){var t=A.on.apply(A,arguments);return t===A?k:t},k};var O={archimedean:m,rectangular:y}},"2ce5":function(t,e,n){var r=n("70b7"),i=n("72df"),o=n("3ce8"),a=n("7a25"),s=n("d4cb"),u=n("d331").CONFIGURABLE,l=n("df6f"),c=n("cdcd"),h=c.enforce,f=c.get,p=String,d=Object.defineProperty,v=r("".slice),g=r("".replace),m=r([].join),y=s&&!i((function(){return 8!==d((function(){}),"length",{value:8}).length})),_=String(String).split("String"),b=t.exports=function(t,e,n){"Symbol("===v(p(e),0,7)&&(e="["+g(p(e),/^Symbol\(([^)]*)\)/,"$1")+"]"),n&&n.getter&&(e="get "+e),n&&n.setter&&(e="set "+e),(!a(t,"name")||u&&t.name!==e)&&(s?d(t,"name",{value:e,configurable:!0}):t.name=e),y&&n&&a(n,"arity")&&t.length!==n.arity&&d(t,"length",{value:n.arity});try{n&&a(n,"constructor")&&n.constructor?s&&d(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(i){}var r=h(t);return a(r,"source")||(r.source=m(_,"string"==typeof e?e:"")),t};Function.prototype.toString=b((function(){return o(this)&&f(this).source||l(this)}),"toString")},"2da1":function(t,e,n){"use strict";(function(t){var n=function(){if("undefined"!==typeof Map)return Map;function t(t,e){var n=-1;return t.some((function(t,r){return t[0]===e&&(n=r,!0)})),n}return function(){function e(){this.__entries__=[]}var n={size:{configurable:!0}};return n.size.get=function(){return this.__entries__.length},e.prototype.get=function(e){var n=t(this.__entries__,e),r=this.__entries__[n];return r&&r[1]},e.prototype.set=function(e,n){var r=t(this.__entries__,e);~r?this.__entries__[r][1]=n:this.__entries__.push([e,n])},e.prototype.delete=function(e){var n=this.__entries__,r=t(n,e);~r&&n.splice(r,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){var n=this;void 0===e&&(e=null);for(var r=0,i=n.__entries__;r<i.length;r+=1){var o=i[r];t.call(e,o[1],o[0])}},Object.defineProperties(e.prototype,n),e}()}(),r="undefined"!==typeof window&&"undefined"!==typeof document&&window.document===document,i=function(){return"undefined"!==typeof t&&t.Math===Math?t:"undefined"!==typeof self&&self.Math===Math?self:"undefined"!==typeof window&&window.Math===Math?window:Function("return this")()}(),o=function(){return"function"===typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)}}(),a=2,s=function(t,e){var n=!1,r=!1,i=0;function s(){n&&(n=!1,t()),r&&l()}function u(){o(s)}function l(){var t=Date.now();if(n){if(t-i<a)return;r=!0}else n=!0,r=!1,setTimeout(u,e);i=t}return l},u=20,l=["top","right","bottom","left","width","height","size","weight"],c="undefined"!==typeof MutationObserver,h=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=s(this.refresh.bind(this),u)};h.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},h.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},h.prototype.refresh=function(){var t=this.updateObservers_();t&&this.refresh()},h.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},h.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),c?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},h.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},h.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e="");var n=l.some((function(t){return!!~e.indexOf(t)}));n&&this.refresh()},h.getInstance=function(){return this.instance_||(this.instance_=new h),this.instance_},h.instance_=null;var f=function(t,e){for(var n=0,r=Object.keys(e);n<r.length;n+=1){var i=r[n];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},p=function(t){var e=t&&t.ownerDocument&&t.ownerDocument.defaultView;return e||i},d=E(0,0,0,0);function v(t){return parseFloat(t)||0}function g(t){var e=[],n=arguments.length-1;while(n-- >0)e[n]=arguments[n+1];return e.reduce((function(e,n){var r=t["border-"+n+"-width"];return e+v(r)}),0)}function m(t){for(var e=["top","right","bottom","left"],n={},r=0,i=e;r<i.length;r+=1){var o=i[r],a=t["padding-"+o];n[o]=v(a)}return n}function y(t){var e=t.getBBox();return E(0,0,e.width,e.height)}function _(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return d;var r=p(t).getComputedStyle(t),i=m(r),o=i.left+i.right,a=i.top+i.bottom,s=v(r.width),u=v(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=g(r,"left","right")+o),Math.round(u+a)!==n&&(u-=g(r,"top","bottom")+a)),!w(t)){var l=Math.round(s+o)-e,c=Math.round(u+a)-n;1!==Math.abs(l)&&(s-=l),1!==Math.abs(c)&&(u-=c)}return E(i.left,i.top,s,u)}var b=function(){return"undefined"!==typeof SVGGraphicsElement?function(t){return t instanceof p(t).SVGGraphicsElement}:function(t){return t instanceof p(t).SVGElement&&"function"===typeof t.getBBox}}();function w(t){return t===p(t).document.documentElement}function O(t){return r?b(t)?y(t):_(t):d}function x(t){var e=t.x,n=t.y,r=t.width,i=t.height,o="undefined"!==typeof DOMRectReadOnly?DOMRectReadOnly:Object,a=Object.create(o.prototype);return f(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}function E(t,e,n,r){return{x:t,y:e,width:n,height:r}}var T=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=E(0,0,0,0),this.target=t};T.prototype.isActive=function(){var t=O(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},T.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var S=function(t,e){var n=x(e);f(this,{target:t,contentRect:n})},M=function(t,e,r){if(this.activeObservations_=[],this.observations_=new n,"function"!==typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=r};M.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!==typeof Element&&Element instanceof Object){if(!(t instanceof p(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new T(t)),this.controller_.addObserver(this),this.controller_.refresh())}},M.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!==typeof Element&&Element instanceof Object){if(!(t instanceof p(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},M.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},M.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},M.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new S(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},M.prototype.clearActive=function(){this.activeObservations_.splice(0)},M.prototype.hasActive=function(){return this.activeObservations_.length>0};var C="undefined"!==typeof WeakMap?new WeakMap:new n,A=function(t){if(!(this instanceof A))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var e=h.getInstance(),n=new M(t,e,this);C.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){A.prototype[t]=function(){return(e=C.get(this))[t].apply(e,arguments);var e}}));var L=function(){return"undefined"!==typeof i.ResizeObserver?i.ResizeObserver:A}();e["a"]=L}).call(this,n("7d15"))},"332c":function(t,e,n){var r=n("4cdd"),i=n("1d8a"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},3606:function(t,e,n){"use strict";function r(t){return function(e,n){var r=String(e),a=n||{},s=a.width,u=s&&t.matchPatterns[s]||t.matchPatterns[t.defaultMatchWidth],l=r.match(u);if(!l)return null;var c,h=l[0],f=s&&t.parsePatterns[s]||t.parsePatterns[t.defaultParseWidth];return c="[object Array]"===Object.prototype.toString.call(f)?o(f,(function(t){return t.test(r)})):i(f,(function(t){return t.test(r)})),c=t.valueCallback?t.valueCallback(c):c,c=a.valueCallback?a.valueCallback(c):c,{value:c,rest:r.slice(h.length)}}}function i(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}function o(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},"378c":function(t,e,n){var r=n("83a6"),i=n("730c");t.exports=function(t){return r(i(t))}},"37d1":function(t,e,n){var r=n("730c"),i=Object;t.exports=function(t){return i(r(t))}},"398c":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=i(n("910f"));function i(t){return t&&t.__esModule?t:{default:t}}var o={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},a={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},s={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},u={date:(0,r.default)({formats:o,defaultWidth:"full"}),time:(0,r.default)({formats:a,defaultWidth:"full"}),dateTime:(0,r.default)({formats:s,defaultWidth:"full"})},l=u;e.default=l,t.exports=e.default},"39ba":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=u(n("b128")),i=u(n("398c")),o=u(n("5cac")),a=u(n("7b70")),s=u(n("c9c9"));function u(t){return t&&t.__esModule?t:{default:t}}var l={code:"en-US",formatDistance:r.default,formatLong:i.default,formatRelative:o.default,localize:a.default,match:s.default,options:{weekStartsOn:0,firstWeekContainsDate:1}},c=l;e.default=c,t.exports=e.default},"3ce8":function(t,e,n){var r=n("be6c"),i=r.all;t.exports=r.IS_HTMLDDA?function(t){return"function"==typeof t||t===i}:function(t){return"function"==typeof t}},"3cec":function(t,e,n){var r=n("7d53"),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},"3e32":function(t,e,n){var r=n("7d53"),i=r("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[i]=!1,"/./"[t](e)}catch(r){}}return!1}},4141:function(t,e){(function(t){var e="currentScript",n=t.getElementsByTagName("script");e in t||Object.defineProperty(t,e,{get:function(){try{throw new Error}catch(r){var t,e=(/.*at [^\(]*\((.*):.+:.+\)$/gi.exec(r.stack)||[!1])[1];for(t in n)if(n[t].src==e||"interactive"==n[t].readyState)return n[t];return null}}})})(document)},"416d":function(t,e,n){var r=n("f498"),i=n("3ce8"),o=r.WeakMap;t.exports=i(o)&&/native code/.test(String(o))},"43f8":function(t,e,n){var r=n("72df");t.exports=!r((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))},4499:function(t,e,n){var r=n("f498"),i=Object.defineProperty;t.exports=function(t,e){try{i(r,t,{value:e,configurable:!0,writable:!0})}catch(n){r[t]=e}return e}},4912:function(t,e){var n=String;t.exports=function(t){try{return n(t)}catch(e){return"Object"}}},"4cdd":function(t,e,n){var r=n("0e93"),i=n("c607");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.30.1",mode:r?"pure":"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.30.1/LICENSE",source:"https://github.com/zloirock/core-js"})},"4cf0":function(t,e,n){"use strict";(function(t){var r=n("7f0d"),i=n("5711"),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=o&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===o,u=s?r["a"].Buffer:void 0,l=u?u.isBuffer:void 0,c=l||i["a"];e["a"]=c}).call(this,n("7326")(t))},"4db4":function(t,e,n){var r=n("cd51");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},"4fed":function(t,e,n){var r,i,o=n("f498"),a=n("64e4"),s=o.process,u=o.Deno,l=s&&s.versions||u&&u.version,c=l&&l.v8;c&&(r=c.split("."),i=r[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&a&&(r=a.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/),r&&(i=+r[1]))),t.exports=i},5428:function(t,e,n){var r=n("f498"),i=n("3ce8"),o=function(t){return i(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t]):r[t]&&r[t][e]}},5711:function(t,e,n){"use strict";function r(){return!1}e["a"]=r},"5ae7":function(t,e,n){"use strict";function r(t){return function(e,n){var r=String(e),i=n||{},o=r.match(t.matchPattern);if(!o)return null;var a=o[0],s=r.match(t.parsePattern);if(!s)return null;var u=t.valueCallback?t.valueCallback(s[0]):s[0];return u=i.valueCallback?i.valueCallback(u):u,{value:u,rest:r.slice(a.length)}}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},"5b12":function(t,e,n){var r=n("d4cb"),i=n("abdf"),o=n("9618");t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},"5cac":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=i;var r={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function i(t,e,n,i){return r[t]}t.exports=e.default},"60de":function(t,e,n){var r=n("63d3"),i=n("6566");t.exports=function(t,e){var n=t[e];return i(n)?void 0:r(n)}},"63d3":function(t,e,n){var r=n("3ce8"),i=n("4912"),o=TypeError;t.exports=function(t){if(r(t))return t;throw o(i(t)+" is not a function")}},"64e4":function(t,e){t.exports="undefined"!=typeof navigator&&String(navigator.userAgent)||""},6566:function(t,e){t.exports=function(t){return null===t||void 0===t}},"65d0":function(t,e,n){var r=n("c91c"),i=n("b17e"),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},"69f2":function(t,e,n){
|
|
2
2
|
/*! dom-to-image-more 26-04-2023 */
|
|
3
3
|
!function(e){"use strict";const n=function(){let t=0;return{escape:function(t){return t.replace(/([.*+?^${}()|[]\/\\])/g,"\\$1")},isDataUrl:function(t){return-1!==t.search(/^(data:)/)},canvasToBlob:function(t){return t.toBlob?new Promise((function(e){t.toBlob(e)})):function(t){return new Promise((function(e){var n=f(t.toDataURL().split(",")[1]),r=n.length,i=new Uint8Array(r);for(let t=0;t<r;t++)i[t]=n.charCodeAt(t);e(new Blob([i],{type:"image/png"}))}))}(t)},resolveUrl:function(t,e){var n=document.implementation.createHTMLDocument(),r=n.createElement("base"),i=(n.head.appendChild(r),n.createElement("a"));return n.body.appendChild(i),r.href=e,i.href=t,i.href},getAndEncode:function(t){let e=l.impl.urlCache.find((function(e){return e.url===t}));return e||(e={url:t,promise:null},l.impl.urlCache.push(e)),null===e.promise&&(l.impl.options.cacheBust&&(t+=(/\?/.test(t)?"&":"?")+(new Date).getTime()),e.promise=new Promise((function(e){const n=l.impl.options.httpTimeout,r=new XMLHttpRequest;let i;var o;function a(t){console.error(t),e("")}r.onreadystatechange=function(){if(4===r.readyState)if(200!==r.status)i?e(i):a(`cannot fetch resource: ${t}, status: `+r.status);else{const t=new FileReader;t.onloadend=function(){e(t.result)},t.readAsDataURL(r.response)}},r.ontimeout=function(){i?e(i):a(`timeout of ${n}ms occured while fetching resource: `+t)},r.responseType="blob",r.timeout=n,l.impl.options.useCredentials&&(r.withCredentials=!0),r.open("GET",t,!0),r.send(),l.impl.options.imagePlaceholder&&(o=l.impl.options.imagePlaceholder.split(/,/))&&o[1]&&(i=o[1])}))),e.promise},uid:function(){return"u"+("0000"+(Math.random()*Math.pow(36,4)<<0).toString(36)).slice(-4)+t++},delay:function(t){return function(e){return new Promise((function(n){setTimeout((function(){n(e)}),t)}))}},asArray:function(t){var e=[],n=t.length;for(let r=0;r<n;r++)e.push(t[r]);return e},escapeXhtml:function(t){return t.replace(/%/g,"%25").replace(/#/g,"%23").replace(/\n/g,"%0A")},makeImage:function(t){return"data:,"!==t?new Promise((function(e,n){const r=new Image;l.impl.options.useCredentials&&(r.crossOrigin="use-credentials"),r.onload=function(){window&&window.requestAnimationFrame?window.requestAnimationFrame((function(){e(r)})):e(r)},r.onerror=n,r.src=t})):Promise.resolve()},width:function(t){var e=a(t,"width");if(!isNaN(e))return e;e=a(t,"border-left-width");var n=a(t,"border-right-width");return t.scrollWidth+e+n},height:function(t){var e=a(t,"height");if(!isNaN(e))return e;e=a(t,"border-top-width");var n=a(t,"border-bottom-width");return t.scrollHeight+e+n},getWindow:n,isElement:o,isElementHostForOpenShadowRoot:function(t){return o(t)&&null!==t.shadowRoot},isShadowRoot:r,isInShadowRoot:i,isHTMLElement:function(t){return t instanceof n(t).HTMLElement},isHTMLCanvasElement:function(t){return t instanceof n(t).HTMLCanvasElement},isHTMLInputElement:function(t){return t instanceof n(t).HTMLInputElement},isHTMLImageElement:function(t){return t instanceof n(t).HTMLImageElement},isHTMLLinkElement:function(t){return t instanceof n(t).HTMLLinkElement},isHTMLScriptElement:function(t){return t instanceof n(t).HTMLScriptElement},isHTMLStyleElement:function(t){return t instanceof n(t).HTMLStyleElement},isHTMLTextAreaElement:function(t){return t instanceof n(t).HTMLTextAreaElement},isShadowSlotElement:function(t){return i(t)&&t instanceof n(t).HTMLSlotElement},isSVGElement:function(t){return t instanceof n(t).SVGElement},isSVGRectElement:function(t){return t instanceof n(t).SVGRectElement},isDimensionMissing:function(t){return isNaN(t)||t<=0}};function n(t){return t=t?t.ownerDocument:void 0,(t?t.defaultView:void 0)||e||window}function r(t){return t instanceof n(t).ShadowRoot}function i(t){return null!==t&&Object.prototype.hasOwnProperty.call(t,"getRootNode")&&r(t.getRootNode())}function o(t){return t instanceof n(t).Element}function a(t,e){if(t.nodeType===c){let n=h(t).getPropertyValue(e);if("px"===n.slice(-2))return n=n.slice(0,-2),parseFloat(n)}return NaN}}(),r=function(){const t=/url\(['"]?([^'"]+?)['"]?\)/g;return{inlineAll:function(t,n,o){return e(t)?Promise.resolve(t).then(r).then((function(e){let r=Promise.resolve(t);return e.forEach((function(t){r=r.then((function(e){return i(e,t,n,o)}))})),r})):Promise.resolve(t)},shouldProcess:e,impl:{readUrls:r,inline:i}};function e(e){return-1!==e.search(t)}function r(e){for(var r,i=[];null!==(r=t.exec(e));)i.push(r[1]);return i.filter((function(t){return!n.isDataUrl(t)}))}function i(t,e,r,i){return Promise.resolve(e).then((function(t){return r?n.resolveUrl(t,r):t})).then(i||n.getAndEncode).then((function(r){return t.replace((i=e,new RegExp(`(url\\(['"]?)(${n.escape(i)})(['"]?\\))`,"g")),`$1${r}$3`);var i}))}}(),i={resolveAll:function(){return o().then((function(t){return Promise.all(t.map((function(t){return t.resolve()})))})).then((function(t){return t.join("\n")}))},impl:{readAll:o}};function o(){return Promise.resolve(n.asArray(document.styleSheets)).then((function(t){const e=[];return t.forEach((function(r){if(Object.prototype.hasOwnProperty.call(Object.getPrototypeOf(r),"cssRules"))try{n.asArray(r.cssRules||[]).forEach(e.push.bind(e))}catch(t){console.error("domtoimage: Error while reading CSS rules from "+r.href,t.toString())}})),e})).then((function(t){return t.filter((function(t){return t.type===CSSRule.FONT_FACE_RULE})).filter((function(t){return r.shouldProcess(t.style.getPropertyValue("src"))}))})).then((function(e){return e.map(t)}));function t(t){return{resolve:function(){var e=(t.parentStyleSheet||{}).href;return r.inlineAll(t.cssText,e)},src:function(){return t.style.getPropertyValue("src")}}}}const a={inlineAll:function t(e){return n.isElement(e)?i(e).then((function(){return n.isHTMLImageElement(e)?s(e).inline():Promise.all(n.asArray(e.childNodes).map((function(e){return t(e)})))})):Promise.resolve(e);function i(t){const e=["background","background-image"],n=e.map((function(e){const n=t.style.getPropertyValue(e),i=t.style.getPropertyPriority(e);return n?r.inlineAll(n).then((function(n){t.style.setProperty(e,n,i)})):Promise.resolve()}));return Promise.all(n).then((function(){return t}))}},impl:{newImage:s}};function s(t){return{inline:function(e){return n.isDataUrl(t.src)?Promise.resolve():Promise.resolve(t.src).then(e||n.getAndEncode).then((function(e){return new Promise((function(n){t.onload=n,t.onerror=n,t.src=e}))}))}}}const u={copyDefaultStyles:!0,imagePlaceholder:void 0,cacheBust:!1,useCredentials:!1,httpTimeout:3e4,styleCaching:"strict"},l={toSvg:p,toPng:function(t,e){return d(t,e).then((function(t){return t.toDataURL()}))},toJpeg:function(t,e){return d(t,e).then((function(t){return t.toDataURL("image/jpeg",(e?e.quality:void 0)||1)}))},toBlob:function(t,e){return d(t,e).then(n.canvasToBlob)},toPixelData:function(t,e){return d(t,e).then((function(e){return e.getContext("2d").getImageData(0,0,n.width(t),n.height(t)).data}))},toCanvas:d,impl:{fontFaces:i,images:a,util:n,inliner:r,urlCache:[],options:{}}},c=(t.exports=l,("undefined"!=typeof Node?Node.ELEMENT_NODE:void 0)||1),h=(void 0!==e?e.getComputedStyle:void 0)||("undefined"!=typeof window?window.getComputedStyle:void 0)||globalThis.getComputedStyle,f=(void 0!==e?e.atob:void 0)||("undefined"!=typeof window?window.atob:void 0)||globalThis.atob;function p(t,e){const r=l.impl.util.getWindow(t);var i=e=e||{};void 0===i.copyDefaultStyles?l.impl.options.copyDefaultStyles=u.copyDefaultStyles:l.impl.options.copyDefaultStyles=i.copyDefaultStyles,void 0===i.imagePlaceholder?l.impl.options.imagePlaceholder=u.imagePlaceholder:l.impl.options.imagePlaceholder=i.imagePlaceholder,void 0===i.cacheBust?l.impl.options.cacheBust=u.cacheBust:l.impl.options.cacheBust=i.cacheBust,void 0===i.useCredentials?l.impl.options.useCredentials=u.useCredentials:l.impl.options.useCredentials=i.useCredentials,void 0===i.httpTimeout?l.impl.options.httpTimeout=u.httpTimeout:l.impl.options.httpTimeout=i.httpTimeout,void 0===i.styleCaching?l.impl.options.styleCaching=u.styleCaching:l.impl.options.styleCaching=i.styleCaching;let o=[];return Promise.resolve(t).then((function(t){if(t.nodeType===c)return t;var e=t,n=t.parentNode,r=document.createElement("span");return n.replaceChild(r,e),r.append(t),o.push({parent:n,child:e,wrapper:r}),r})).then((function(t){return function t(e,r,i,o){const a=r.filter;return e===v||n.isHTMLScriptElement(e)||n.isHTMLStyleElement(e)||n.isHTMLLinkElement(e)||null!==i&&a&&!a(e)?Promise.resolve():Promise.resolve(e).then(s).then((function(t){return l(t,u(e))})).then((function(t){return c(t,e)}));function s(t){return n.isHTMLCanvasElement(t)?n.makeImage(t.toDataURL()):t.cloneNode(!1)}function u(t){return n.isElementHostForOpenShadowRoot(t)?t.shadowRoot:t}function l(e,i){const a=l(i);let s=Promise.resolve();if(0!==a.length){const l=h(u(i));n.asArray(a).forEach((function(n){s=s.then((function(){return t(n,r,l,o).then((function(t){t&&e.appendChild(t)}))}))}))}return s.then((function(){return e}));function u(t){return n.isShadowRoot(t)?t.host:t}function l(t){return n.isShadowSlotElement(t)?t.assignedNodes():t.childNodes}}function c(t,e){return!n.isElement(t)||n.isShadowSlotElement(e)?Promise.resolve(t):Promise.resolve().then(o).then(a).then(s).then(u).then((function(){return t}));function o(){function n(t,e){e.font=t.font,e.fontFamily=t.fontFamily,e.fontFeatureSettings=t.fontFeatureSettings,e.fontKerning=t.fontKerning,e.fontSize=t.fontSize,e.fontStretch=t.fontStretch,e.fontStyle=t.fontStyle,e.fontVariant=t.fontVariant,e.fontVariantCaps=t.fontVariantCaps,e.fontVariantEastAsian=t.fontVariantEastAsian,e.fontVariantLigatures=t.fontVariantLigatures,e.fontVariantNumeric=t.fontVariantNumeric,e.fontVariationSettings=t.fontVariationSettings,e.fontWeight=t.fontWeight}function o(t,e){const o=h(t);o.cssText?(e.style.cssText=o.cssText,n(o,e.style)):(y(r,t,o,i,e),null===i&&(["inset-block","inset-block-start","inset-block-end"].forEach(t=>e.style.removeProperty(t)),["left","right","top","bottom"].forEach(t=>{e.style.getPropertyValue(t)&&e.style.setProperty(t,"0px")})))}o(e,t)}function a(){const r=n.uid();function i(i){const o=h(e,i),a=o.getPropertyValue("content");if(""!==a&&"none"!==a){const e=t.getAttribute("class")||"",u=(t.setAttribute("class",e+" "+r),document.createElement("style"));function s(){const t=`.${r}:`+i,e=(o.cssText?s:u)();return document.createTextNode(t+`{${e}}`);function s(){return`${o.cssText} content: ${a};`}function u(){const t=n.asArray(o).map(e).join("; ");return t+";";function e(t){const e=o.getPropertyValue(t),n=o.getPropertyPriority(t)?" !important":"";return t+": "+e+n}}}u.appendChild(s()),t.appendChild(u)}}[":before",":after"].forEach((function(t){i(t)}))}function s(){n.isHTMLTextAreaElement(e)&&(t.innerHTML=e.value),n.isHTMLInputElement(e)&&t.setAttribute("value",e.value)}function u(){n.isSVGElement(t)&&(t.setAttribute("xmlns","http://www.w3.org/2000/svg"),n.isSVGRectElement(t))&&["width","height"].forEach((function(e){const n=t.getAttribute(e);n&&t.style.setProperty(e,n)}))}}}(t,e,null,r)})).then(g).then(m).then((function(t){e.bgcolor&&(t.style.backgroundColor=e.bgcolor),e.width&&(t.style.width=e.width+"px"),e.height&&(t.style.height=e.height+"px"),e.style&&Object.keys(e.style).forEach((function(n){t.style[n]=e.style[n]}));let n=null;return"function"==typeof e.onclone&&(n=e.onclone(t)),Promise.resolve(n).then((function(){return t}))})).then((function(t){let r=e.width||n.width(t),i=e.height||n.height(t);return Promise.resolve(t).then((function(t){return t.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),(new XMLSerializer).serializeToString(t)})).then(n.escapeXhtml).then((function(t){var e=(n.isDimensionMissing(r)?' width="100%"':` width="${r}"`)+(n.isDimensionMissing(i)?' height="100%"':` height="${i}"`);return`<svg xmlns="http://www.w3.org/2000/svg"${(n.isDimensionMissing(r)?"":` width="${r}"`)+(n.isDimensionMissing(i)?"":` height="${i}"`)}><foreignObject${e}>${t}</foreignObject></svg>`})).then((function(t){return"data:image/svg+xml;charset=utf-8,"+t}))})).then((function(t){for(;0<o.length;){var e=o.pop();e.parent.replaceChild(e.child,e.wrapper)}return t})).then((function(t){return l.impl.urlCache=[],function(){v&&(document.body.removeChild(v),v=null),_&&clearTimeout(_),_=setTimeout(()=>{_=null,b={}},2e4)}(),t}))}function d(t,e){return p(t,e=e||{}).then(n.makeImage).then((function(r){var i="number"!=typeof e.scale?1:e.scale,o=function(t,r){let i=e.width||n.width(t),o=e.height||n.height(t);return n.isDimensionMissing(i)&&(i=n.isDimensionMissing(o)?300:2*o),n.isDimensionMissing(o)&&(o=i/2),t=document.createElement("canvas"),t.width=i*r,t.height=o*r,e.bgcolor&&((r=t.getContext("2d")).fillStyle=e.bgcolor,r.fillRect(0,0,t.width,t.height)),t}(t,i),a=o.getContext("2d");return a.msImageSmoothingEnabled=!1,a.imageSmoothingEnabled=!1,r&&(a.scale(i,i),a.drawImage(r,0,0)),o}))}let v=null;function g(t){return i.resolveAll().then((function(e){var n;return""!==e&&(n=document.createElement("style"),t.appendChild(n),n.appendChild(document.createTextNode(e))),t}))}function m(t){return a.inlineAll(t).then((function(){return t}))}function y(t,e,r,i,o){const a=l.impl.options.copyDefaultStyles?function(t,e){e=function(t){var e=[];do{if(t.nodeType===c){var n=t.tagName;if(e.push(n),w.includes(n))break}}while(t=t.parentNode,t);return e}(e);var r=function(e){return("relaxed"!==t.styleCaching?e:e.filter((t,e,n)=>0===e||e===n.length-1)).join(">")}(e);if(b[r])return b[r];var i=function(){if(v)return v.contentWindow;var t=document.characterSet||"UTF-8",e=document.doctype;e=e?(`<!DOCTYPE ${r(e.name)} ${r(e.publicId)} `+r(e.systemId)).trim()+">":"";return(v=document.createElement("iframe")).id="domtoimage-sandbox-"+n.uid(),v.style.visibility="hidden",v.style.position="fixed",document.body.appendChild(v),function(t,e,n,r){try{return t.contentWindow.document.write(e+`<html><head><meta charset='${n}'><title>${r}</title></head><body></body></html>`),t.contentWindow}catch(t){}var i=document.createElement("meta");i.setAttribute("charset",n);try{var o=document.implementation.createHTMLDocument(r),a=(o.head.appendChild(i),e+o.documentElement.outerHTML);return t.setAttribute("srcdoc",a),t.contentWindow}catch(t){}return t.contentDocument.head.appendChild(i),t.contentDocument.title=r,t.contentWindow}(v,e,t,"domtoimage-sandbox");function r(t){var e;return t?((e=document.createElement("div")).innerText=t,e.innerHTML):""}}();e=function(t,e){let n=t.body;do{var r=e.pop();r=t.createElement(r);n.appendChild(r),n=r}while(0<e.length);return n.textContent="",n}(i.document,e),i=function(t,e){const r={},i=t.getComputedStyle(e);return n.asArray(i).forEach((function(t){r[t]="width"===t||"height"===t?"auto":i.getPropertyValue(t)})),r}(i,e);return function(t){do{var e=t.parentElement;null!==e&&e.removeChild(t),t=e}while(t&&"BODY"!==t.tagName)}(e),b[r]=i}(t,e):{},s=o.style;n.asArray(r).forEach((function(t){var e,n=r.getPropertyValue(t),o=a[t],u=i?i.getPropertyValue(t):void 0;(n!==o||i&&n!==u)&&(o=r.getPropertyPriority(t),u=s,n=n,o=o,e=0<=["background-clip"].indexOf(t=t),o?(u.setProperty(t,n,o),e&&u.setProperty("-webkit-"+t,n,o)):(u.setProperty(t,n),e&&u.setProperty("-webkit-"+t,n)))}))}let _=null,b={};const w=["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","DETAILS","DIALOG","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","LI","MAIN","NAV","OL","P","PRE","SECTION","SVG","TABLE","UL","math","svg","BODY","HEAD","HTML"]}(this)},"6a61":function(t,e,n){var r=n("70b7"),i=r({}.toString),o=r("".slice);t.exports=function(t){return o(i(t),8,-1)}},"6b1d":function(t,e,n){var r=n("f498"),i=n("185a").f,o=n("5b12"),a=n("ef30"),s=n("4499"),u=n("b634"),l=n("ebac");t.exports=function(t,e){var n,c,h,f,p,d,v=t.target,g=t.global,m=t.stat;if(c=g?r:m?r[v]||s(v,{}):(r[v]||{}).prototype,c)for(h in e){if(p=e[h],t.dontCallGetSet?(d=i(c,h),f=d&&d.value):f=c[h],n=l(g?h:v+(m?".":"#")+h,t.forced),!n&&void 0!==f){if(typeof p==typeof f)continue;u(p,f)}(t.sham||f&&f.sham)&&o(p,"sham",!0),a(c,h,p,t)}}},"70b7":function(t,e,n){var r=n("43f8"),i=Function.prototype,o=i.call,a=r&&i.bind.bind(o,o);t.exports=r?a:function(t){return function(){return o.apply(t,arguments)}}},"72df":function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},"730c":function(t,e,n){var r=n("6566"),i=TypeError;t.exports=function(t){if(r(t))throw i("Can't call method on "+t);return t}},7326:function(t,e){t.exports=function(t){if(!t.webpackPolyfill){var e=Object.create(t);e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),Object.defineProperty(e,"exports",{enumerable:!0}),e.webpackPolyfill=1}return e}},7526:function(t,e,n){var r=n("3ce8"),i=n("be6c"),o=i.all;t.exports=i.IS_HTMLDDA?function(t){return"object"==typeof t?null!==t:r(t)||t===o}:function(t){return"object"==typeof t?null!==t:r(t)}},"7a25":function(t,e,n){var r=n("70b7"),i=n("37d1"),o=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,e){return o(i(t),e)}},"7b70":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=i(n("b489"));function i(t){return t&&t.__esModule?t:{default:t}}var o={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},a={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},s={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},u={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},l={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},c={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}};function h(t,e){var n=Number(t),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"}var f={ordinalNumber:h,era:(0,r.default)({values:o,defaultWidth:"wide"}),quarter:(0,r.default)({values:a,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:(0,r.default)({values:s,defaultWidth:"wide"}),day:(0,r.default)({values:u,defaultWidth:"wide"}),dayPeriod:(0,r.default)({values:l,defaultWidth:"wide",formattingValues:c,defaultFormattingWidth:"wide"})},p=f;e.default=p,t.exports=e.default},"7c3f":function(t,e,n){var r=n("d4cb"),i=n("72df"),o=n("f2bf");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},"7d15":function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}t.exports=n},"7d53":function(t,e,n){var r=n("f498"),i=n("4cdd"),o=n("7a25"),a=n("1d8a"),s=n("cd51"),u=n("4db4"),l=r.Symbol,c=i("wks"),h=u?l["for"]||l:l&&l.withoutSetter||a;t.exports=function(t){return o(c,t)||(c[t]=s&&o(l,t)?l[t]:h("Symbol."+t)),c[t]}},"7f0d":function(t,e,n){"use strict";var r=n("92ae"),i="object"==typeof self&&self&&self.Object===Object&&self,o=r["a"]||i||Function("return this")();e["a"]=o},"815b":function(t,e){var n=Math.ceil,r=Math.floor;t.exports=Math.trunc||function(t){var e=+t;return(e>0?r:n)(e)}},"82e8":function(t,e,n){var r,i=n("157c"),o=n("b99b"),a=n("b17e"),s=n("d687"),u=n("9324"),l=n("f2bf"),c=n("332c"),h=">",f="<",p="prototype",d="script",v=c("IE_PROTO"),g=function(){},m=function(t){return f+d+h+t+f+"/"+d+h},y=function(t){t.write(m("")),t.close();var e=t.parentWindow.Object;return t=null,e},_=function(){var t,e=l("iframe"),n="java"+d+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(m("document.F=Object")),t.close(),t.F},b=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}b="undefined"!=typeof document?document.domain&&r?y(r):_():y(r);var t=a.length;while(t--)delete b[p][a[t]];return b()};s[v]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(g[p]=i(t),n=new g,g[p]=null,n[v]=t):n=b(),void 0===e?n:o.f(n,e)}},8320:function(t,e,n){"use strict";n.r(e),n.d(e,"dispatch",(function(){return l}));var r={value:function(){}};function i(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new o(r)}function o(t){this._=t}function a(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function s(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function u(t,e,n){for(var i=0,o=t.length;i<o;++i)if(t[i].name===e){t[i]=r,t=t.slice(0,i).concat(t.slice(i+1));break}return null!=n&&t.push({name:e,value:n}),t}o.prototype=i.prototype={constructor:o,on:function(t,e){var n,r=this._,i=a(t+"",r),o=-1,l=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!==typeof e)throw new Error("invalid callback: "+e);while(++o<l)if(n=(t=i[o]).type)r[n]=u(r[n],t.name,e);else if(null==e)for(n in r)r[n]=u(r[n],t.name,null);return this}while(++o<l)if((n=(t=i[o]).type)&&(n=s(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new o(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(r=this._[t],o=0,n=r.length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var l=i},"83a6":function(t,e,n){var r=n("70b7"),i=n("72df"),o=n("6a61"),a=Object,s=r("".split);t.exports=i((function(){return!a("z").propertyIsEnumerable(0)}))?function(t){return"String"==o(t)?s(t,""):a(t)}:a},"868d":function(t,e,n){var r=n("d4cb"),i=n("d331").EXISTS,o=n("70b7"),a=n("cf87"),s=Function.prototype,u=o(s.toString),l=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,c=o(l.exec),h="name";r&&!i&&a(s,h,{configurable:!0,get:function(){try{return c(l,u(this))[1]}catch(t){return""}}})},"8d0d":function(t,e,n){"use strict";var r=n("6b1d"),i=n("1f5e").includes,o=n("72df"),a=n("ed2b"),s=o((function(){return!Array(1).includes()}));r({target:"Array",proto:!0,forced:s},{includes:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),a("includes")},"8e5d":function(t,e,n){var r=n("7526"),i=n("6a61"),o=n("7d53"),a=o("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[a])?!!e:"RegExp"==i(t))}},"910f":function(t,e,n){"use strict";function r(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth,i=t.formats[r]||t.formats[t.defaultWidth];return i}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},"92ae":function(t,e,n){"use strict";(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e["a"]=n}).call(this,n("7d15"))},9324:function(t,e,n){var r=n("5428");t.exports=r("document","documentElement")},9616:function(t,e,n){var r=n("815b");t.exports=function(t){var e=+t;return e!==e||0===e?0:r(e)}},9618:function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"9a0f":function(t,e,n){var r=n("9616"),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},"9b04":function(t,e,n){"use strict";var r=function(){};t.exports=r},"9eea":function(t,e,n){var r=n("8e5d"),i=TypeError;t.exports=function(t){if(r(t))throw i("The method doesn't accept regular expressions");return t}},a03e:function(t,e,n){var r=n("5428"),i=n("70b7"),o=n("65d0"),a=n("2402"),s=n("157c"),u=i([].concat);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(s(t)),n=a.f;return n?u(e,n(t)):e}},abdf:function(t,e,n){var r=n("d4cb"),i=n("7c3f"),o=n("ff3b"),a=n("157c"),s=n("feca"),u=TypeError,l=Object.defineProperty,c=Object.getOwnPropertyDescriptor,h="enumerable",f="configurable",p="writable";e.f=r?o?function(t,e,n){if(a(t),e=s(e),a(n),"function"===typeof t&&"prototype"===e&&"value"in n&&p in n&&!n[p]){var r=c(t,e);r&&r[p]&&(t[e]=n.value,n={configurable:f in n?n[f]:r[f],enumerable:h in n?n[h]:r[h],writable:!1})}return l(t,e,n)}:l:function(t,e,n){if(a(t),e=s(e),a(n),i)try{return l(t,e,n)}catch(r){}if("get"in n||"set"in n)throw u("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},b128:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=i;var r={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function i(t,e,n){var i;return n=n||{},i="string"===typeof r[t]?r[t]:1===e?r[t].one:r[t].other.replace("{{count}}",e),n.addSuffix?n.comparison>0?"in "+i:i+" ago":i}t.exports=e.default},b17e:function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},b489:function(t,e,n){"use strict";function r(t){return function(e,n){var r,i=n||{},o=i.context?String(i.context):"standalone";if("formatting"===o&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,s=i.width?String(i.width):a;r=t.formattingValues[s]||t.formattingValues[a]}else{var u=t.defaultWidth,l=i.width?String(i.width):t.defaultWidth;r=t.values[l]||t.values[u]}var c=t.argumentCallback?t.argumentCallback(e):e;return r[c]}}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,t.exports=e.default},b495:function(t,e,n){var r=n("9616"),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},b546:function(t,e,n){var r=n("43f8"),i=Function.prototype.call;t.exports=r?i.bind(i):function(){return i.apply(i,arguments)}},b634:function(t,e,n){var r=n("7a25"),i=n("a03e"),o=n("185a"),a=n("abdf");t.exports=function(t,e,n){for(var s=i(e),u=a.f,l=o.f,c=0;c<s.length;c++){var h=s[c];r(t,h)||n&&r(n,h)||u(t,h,l(e,h))}}},b99b:function(t,e,n){var r=n("d4cb"),i=n("ff3b"),o=n("abdf"),a=n("157c"),s=n("378c"),u=n("0c47");e.f=r&&!i?Object.defineProperties:function(t,e){a(t);var n,r=s(e),i=u(e),l=i.length,c=0;while(l>c)o.f(t,n=i[c++],r[n]);return t}},be6c:function(t,e){var n="object"==typeof document&&document.all,r="undefined"==typeof n&&void 0!==n;t.exports={all:n,IS_HTMLDDA:r}},c607:function(t,e,n){var r=n("f498"),i=n("4499"),o="__core-js_shared__",a=r[o]||i(o,{});t.exports=a},c78b:function(t,e,n){"use strict";var r=n("6b1d"),i=n("70b7"),o=n("9eea"),a=n("730c"),s=n("2a3e"),u=n("3e32"),l=i("".indexOf);r({target:"String",proto:!0,forced:!u("includes")},{includes:function(t){return!!~l(s(a(this)),s(o(t)),arguments.length>1?arguments[1]:void 0)}})},c91c:function(t,e,n){var r=n("70b7"),i=n("7a25"),o=n("378c"),a=n("1f5e").indexOf,s=n("d687"),u=r([].push);t.exports=function(t,e){var n,r=o(t),l=0,c=[];for(n in r)!i(s,n)&&i(r,n)&&u(c,n);while(e.length>l)i(r,n=e[l++])&&(~a(c,n)||u(c,n));return c}},c9c9:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=o(n("5ae7")),i=o(n("3606"));function o(t){return t&&t.__esModule?t:{default:t}}var a=/^(\d+)(th|st|nd|rd)?/i,s=/\d+/i,u={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},l={any:[/^b/i,/^(a|c)/i]},c={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},h={any:[/1/i,/2/i,/3/i,/4/i]},f={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},p={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},d={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},v={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},g={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},m={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},y={ordinalNumber:(0,r.default)({matchPattern:a,parsePattern:s,valueCallback:function(t){return parseInt(t,10)}}),era:(0,i.default)({matchPatterns:u,defaultMatchWidth:"wide",parsePatterns:l,defaultParseWidth:"any"}),quarter:(0,i.default)({matchPatterns:c,defaultMatchWidth:"wide",parsePatterns:h,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:(0,i.default)({matchPatterns:f,defaultMatchWidth:"wide",parsePatterns:p,defaultParseWidth:"any"}),day:(0,i.default)({matchPatterns:d,defaultMatchWidth:"wide",parsePatterns:v,defaultParseWidth:"any"}),dayPeriod:(0,i.default)({matchPatterns:g,defaultMatchWidth:"any",parsePatterns:m,defaultParseWidth:"any"})},_=y;e.default=_,t.exports=e.default},cd51:function(t,e,n){var r=n("4fed"),i=n("72df");t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},cdcd:function(t,e,n){var r,i,o,a=n("416d"),s=n("f498"),u=n("7526"),l=n("5b12"),c=n("7a25"),h=n("c607"),f=n("332c"),p=n("d687"),d="Object already initialized",v=s.TypeError,g=s.WeakMap,m=function(t){return o(t)?i(t):r(t,{})},y=function(t){return function(e){var n;if(!u(e)||(n=i(e)).type!==t)throw v("Incompatible receiver, "+t+" required");return n}};if(a||h.state){var _=h.state||(h.state=new g);_.get=_.get,_.has=_.has,_.set=_.set,r=function(t,e){if(_.has(t))throw v(d);return e.facade=t,_.set(t,e),e},i=function(t){return _.get(t)||{}},o=function(t){return _.has(t)}}else{var b=f("state");p[b]=!0,r=function(t,e){if(c(t,b))throw v(d);return e.facade=t,l(t,b,e),e},i=function(t){return c(t,b)?t[b]:{}},o=function(t){return c(t,b)}}t.exports={set:r,get:i,has:o,enforce:m,getterFor:y}},cf87:function(t,e,n){var r=n("2ce5"),i=n("abdf");t.exports=function(t,e,n){return n.get&&r(n.get,e,{getter:!0}),n.set&&r(n.set,e,{setter:!0}),i.f(t,e,n)}},cfd1:function(t,e,n){var r=n("5428"),i=n("3ce8"),o=n("fb9b"),a=n("4db4"),s=Object;t.exports=a?function(t){return"symbol"==typeof t}:function(t){var e=r("Symbol");return i(e)&&o(e.prototype,s(t))}},d331:function(t,e,n){var r=n("d4cb"),i=n("7a25"),o=Function.prototype,a=r&&Object.getOwnPropertyDescriptor,s=i(o,"name"),u=s&&"something"===function(){}.name,l=s&&(!r||r&&a(o,"name").configurable);t.exports={EXISTS:s,PROPER:u,CONFIGURABLE:l}},d4cb:function(t,e,n){var r=n("72df");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},d687:function(t,e){t.exports={}},d6f0:function(t,e,n){"use strict";(function(t){var r=n("7f0d"),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i,s=a?r["a"].Buffer:void 0,u=s?s.allocUnsafe:void 0;function l(t,e){if(e)return t.slice();var n=t.length,r=u?u(n):new t.constructor(n);return t.copy(r),r}e["a"]=l}).call(this,n("7326")(t))},da06:function(t,e,n){var r=n("3cec"),i=n("3ce8"),o=n("6a61"),a=n("7d53"),s=a("toStringTag"),u=Object,l="Arguments"==o(function(){return arguments}()),c=function(t,e){try{return t[e]}catch(n){}};t.exports=r?o:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=c(e=u(t),s))?n:l?o(e):"Object"==(r=o(e))&&i(e.callee)?"Arguments":r}},df6f:function(t,e,n){var r=n("70b7"),i=n("3ce8"),o=n("c607"),a=r(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return a(t)}),t.exports=o.inspectSource},e129:function(t,e,n){"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,o=i&&!r.call({1:2},1);e.f=o?function(t){var e=i(this,t);return!!e&&e.enumerable}:r},eba0:function(t,e,n){var r=n("b546"),i=n("3ce8"),o=n("7526"),a=TypeError;t.exports=function(t,e){var n,s;if("string"===e&&i(n=t.toString)&&!o(s=r(n,t)))return s;if(i(n=t.valueOf)&&!o(s=r(n,t)))return s;if("string"!==e&&i(n=t.toString)&&!o(s=r(n,t)))return s;throw a("Can't convert object to primitive value")}},ebac:function(t,e,n){var r=n("72df"),i=n("3ce8"),o=/#|\.prototype\./,a=function(t,e){var n=u[s(t)];return n==c||n!=l&&(i(e)?r(e):!!e)},s=a.normalize=function(t){return String(t).replace(o,".").toLowerCase()},u=a.data={},l=a.NATIVE="N",c=a.POLYFILL="P";t.exports=a},ed2b:function(t,e,n){var r=n("7d53"),i=n("82e8"),o=n("abdf").f,a=r("unscopables"),s=Array.prototype;void 0==s[a]&&o(s,a,{configurable:!0,value:i(null)}),t.exports=function(t){s[a][t]=!0}},ef30:function(t,e,n){var r=n("3ce8"),i=n("abdf"),o=n("2ce5"),a=n("4499");t.exports=function(t,e,n,s){s||(s={});var u=s.enumerable,l=void 0!==s.name?s.name:e;if(r(n)&&o(n,l,s),s.global)u?t[e]=n:a(e,n);else{try{s.unsafe?t[e]&&(u=!0):delete t[e]}catch(c){}u?t[e]=n:i.f(t,e,{value:n,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return t}},f2bf:function(t,e,n){var r=n("f498"),i=n("7526"),o=r.document,a=i(o)&&i(o.createElement);t.exports=function(t){return a?o.createElement(t):{}}},f498:function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||function(){return this}()||Function("return this")()}).call(this,n("7d15"))},fb9b:function(t,e,n){var r=n("70b7");t.exports=r({}.isPrototypeOf)},feca:function(t,e,n){var r=n("083f"),i=n("cfd1");t.exports=function(t){var e=r(t,"string");return i(e)?e:e+""}},ff3b:function(t,e,n){var r=n("d4cb"),i=n("72df");t.exports=r&&i((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))}})}));
|
|
4
4
|
//# sourceMappingURL=charts-vue.umd.min.js.map
|