@carbon/charts 0.41.83 → 0.41.87

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/bundle.js CHANGED
@@ -12,7 +12,7 @@
12
12
 
13
13
  See the Apache Version 2.0 License for specific language governing permissions
14
14
  and limitations under the License.
15
- ***************************************************************************** */var e=function(t,n){return(e=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,n)};function n(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}var r,i,o,a,s,u,l,c,f,h,d,p,g,m,v,y,b,_,w,O,x,E,S,T=function(){return(T=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function M(){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}!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"}(r||(r={})),function(t){t.RENDER_FINISHED="render-finished",t.RESIZE="chart-resize",t.MOUSEOVER="chart-mouseover",t.MOUSEOUT="chart-mouseout"}(i||(i={})),function(t){t.SHOW="show-modal",t.HIDE="hide-modal"}(o||(o={})),function(t){t.UPDATE="model-update"}(a||(a={})),function(t){t.SHOW_OVERFLOW_MENU="show-toolbar-overflow-menu",t.HIDE_OVERFLOW_MENU="hide-toolbar-overflow-menu"}(s||(s={})),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"}(u||(u={})),function(t){t.CHANGE="zoom-domain-change"}(l||(l={})),function(t){t.CANVAS_ZOOM_IN="canvas-zoom-in",t.CANVAS_ZOOM_OUT="canvas-zoom-out"}(c||(c={})),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"}(f||(f={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(h||(h={})),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"}(d||(d={})),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"}(p||(p={})),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"}(g||(g={})),function(t){t.BAR_MOUSEOVER="bar-mouseover",t.BAR_MOUSEMOVE="bar-mousemove",t.BAR_CLICK="bar-click",t.BAR_MOUSEOUT="bar-mouseout"}(m||(m={})),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"}(v||(v={})),function(t){t.SCATTER_MOUSEOVER="scatter-mouseover",t.SCATTER_MOUSEMOVE="scatter-mousemove",t.SCATTER_CLICK="scatter-click",t.SCATTER_MOUSEOUT="scatter-mouseout"}(y||(y={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(b||(b={})),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"}(_||(_={})),function(t){t.LEAF_MOUSEOVER="leaf-mouseover",t.LEAF_MOUSEMOVE="leaf-mousemove",t.LEAF_CLICK="leaf-click",t.LEAF_MOUSEOUT="leaf-mouseout"}(w||(w={})),function(t){t.SHOW="show-tooltip",t.MOVE="move-tooltip",t.HIDE="hide-tooltip"}(O||(O={})),function(t){t.SHOW="show-threshold",t.HIDE="hide-threshold"}(x||(x={})),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"}(E||(E={})),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"}(S||(S={}));var C,D,P,A,k,L,R,I,N,j,B,V,H,U,F,G,z,W,Y,q,Z,X,K,$,J,Q,tt=Object.freeze({__proto__:null,get Chart(){return i},get Modal(){return o},get Model(){return a},get Toolbar(){return s},get ZoomBar(){return u},get ZoomDomain(){return l},get CanvasZoom(){return c},get Axis(){return f},get Area(){return h},get WordCloud(){return d},get Pie(){return p},get Gauge(){return g},get Bar(){return m},get Boxplot(){return v},get Scatter(){return y},get Line(){return b},get Radar(){return _},get Treemap(){return w},get Tooltip(){return O},get Threshold(){return x},get Legend(){return E},get CirclePack(){return S}});!function(t){t.HTML="html",t.SVG="svg"}(C||(C={})),function(t){t.DEFAULT="default",t.G100="g100",t.G90="g90",t.G10="g10"}(D||(D={})),function(t){t.BACKGROUND="background",t.FILL="fill",t.STROKE="stroke",t.TOOLTIP="tooltip"}(P||(P={})),function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(A||(A={})),function(t){t.GRAPH_VIEW="graph_view",t.SLIDER_VIEW="slider_view"}(k||(k={})),function(t){t.END_LINE="end_line",t.MID_LINE="mid_line",t.FRONT_LINE="front_line",t.NONE="none"}(L||(L={})),function(t){t.VERTICAL="vertical",t.HORIZONTAL="horizontal"}(R||(R={})),function(t){t.TIME="time",t.LINEAR="linear",t.LOG="log",t.LABELS="labels",t.LABELS_RATIO="labels-ratio"}(I||(I={})),function(t){t.RIGHT="right",t.LEFT="left",t.TOP="top",t.BOTTOM="bottom"}(N||(N={})),function(t){t.LEFT="left",t.CENTER="center",t.RIGHT="right"}(j||(j={})),function(t){t.HORIZONTAL="horizontal",t.VERTICAL="vertical"}(B||(B={})),function(t){t.ROW="row",t.COLUMN="column",t.ROW_REVERSE="row-reverse",t.COLUMN_REVERSE="column-reverse"}(V||(V={})),function(t){t.FIXED="fixed",t.PREFERRED="preferred",t.STRETCH="stretch"}(H||(H={})),function(t){t.CENTER="center"}(U||(U={})),function(t){t.LEFT="left",t.RIGHT="right"}(F||(F={})),function(t){t.GRID="grid",t.VERT_OR_HORIZ="vertOrHoriz",t.PIE="pie",t.DONUT="donut"}(G||(G={})),function(t){t.START="start",t.MIDDLE="middle",t.END="end"}(z||(z={})),function(t){t.BASELINE="baseline",t.MIDDLE="middle",t.HANGING="hanging"}(W||(W={})),function(t){t.SEMI="semi",t.FULL="full"}(Y||(Y={})),function(t){t.UP="up",t.DOWN="down"}(q||(q={})),function(t){t.SUCCESS="success",t.WARNING="warning",t.DANGER="danger"}(Z||(Z={})),function(t){t.ALWAYS="always",t.AUTO="auto",t.NEVER="never"}(X||(X={})),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"}(K||(K={})),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"}($||($={})),function(t){t.LEFT="left",t.RIGHT="right"}(J||(J={})),function(t){t.CHECKBOX="checkbox",t.RADIUS="radius",t.AREA="area",t.SIZE="size",t.LINE="line",t.QUARTILE="quartile",t.ZOOM="zoom"}(Q||(Q={}));var et,nt=Object.freeze({__proto__:null,get Roles(){return r},Events:tt,get RenderTypes(){return C},get ChartTheme(){return D},get ColorClassNameTypes(){return P},get AxisPositions(){return A},get ZoomBarTypes(){return k},get TruncationTypes(){return L},get CartesianOrientations(){return R},get ScaleTypes(){return I},get LegendPositions(){return N},get Alignments(){return j},get LegendOrientations(){return B},get LayoutDirection(){return V},get LayoutGrowth(){return H},get LayoutAlignItems(){return U},get CalloutDirections(){return F},get Skeletons(){return G},get TextAnchor(){return z},get DominantBaseline(){return W},get GaugeTypes(){return Y},get ArrowDirections(){return q},get Statuses(){return Z},get TickRotations(){return X},get ChartTypes(){return K},get ToolbarControlTypes(){return $},get AxisTitleOrientations(){return J},get LegendItemType(){return Q}});function rt(t){return+t}function it(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var ot={opacity:{unselected:.05,selected:.4}},at={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1},st={duration:1e3,ease:it,zoomLevel:3},ut={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},lt={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},ct={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},ft={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"}},ht={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},dt={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15}},pt={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}},gt={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},mt={default:{size:24}},vt={horizontalOffset:10},yt={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}},bt={height:(et={},et[k.GRAPH_VIEW]=32,et[k.SLIDER_VIEW]=10,et),spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},_t=[{type:Q.RADIUS,name:"Radius"},{type:Q.AREA,name:"Poor area"},{type:Q.AREA,name:"Satisfactory area"},{type:Q.AREA,name:"Great area"},{type:Q.QUARTILE,name:"Quartiles"}],wt="object"==typeof global&&global&&global.Object===Object&&global,Ot="object"==typeof self&&self&&self.Object===Object&&self,xt=wt||Ot||Function("return this")(),Et=xt.Symbol,St=Object.prototype,Tt=St.hasOwnProperty,Mt=St.toString,Ct=Et?Et.toStringTag:void 0;var Dt=Object.prototype.toString;var Pt=Et?Et.toStringTag:void 0;function At(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":Pt&&Pt in Object(t)?function(t){var e=Tt.call(t,Ct),n=t[Ct];try{t[Ct]=void 0;var r=!0}catch(t){}var i=Mt.call(t);return r&&(e?t[Ct]=n:delete t[Ct]),i}(t):function(t){return Dt.call(t)}(t)}function kt(t){return null!=t&&"object"==typeof t}function Lt(t){return"symbol"==typeof t||kt(t)&&"[object Symbol]"==At(t)}function Rt(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}var It=Array.isArray,Nt=Et?Et.prototype:void 0,jt=Nt?Nt.toString:void 0;function Bt(t){if("string"==typeof t)return t;if(It(t))return Rt(t,Bt)+"";if(Lt(t))return jt?jt.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}var Vt=/\s/;var Ht=/^\s+/;function Ut(t){return t?t.slice(0,function(t){for(var e=t.length;e--&&Vt.test(t.charAt(e)););return e}(t)+1).replace(Ht,""):t}function Ft(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Gt=/^[-+]0x[0-9a-f]+$/i,zt=/^0b[01]+$/i,Wt=/^0o[0-7]+$/i,Yt=parseInt;function qt(t){if("number"==typeof t)return t;if(Lt(t))return NaN;if(Ft(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Ft(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ut(t);var n=zt.test(t);return n||Wt.test(t)?Yt(t.slice(2),n?2:8):Gt.test(t)?NaN:+t}function Zt(t){return t}function Xt(t){if(!Ft(t))return!1;var e=At(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var Kt,$t=xt["__core-js_shared__"],Jt=(Kt=/[^.]+$/.exec($t&&$t.keys&&$t.keys.IE_PROTO||""))?"Symbol(src)_1."+Kt:"";var Qt=Function.prototype.toString;function te(t){if(null!=t){try{return Qt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var ee=/^\[object .+?Constructor\]$/,ne=Function.prototype,re=Object.prototype,ie=ne.toString,oe=re.hasOwnProperty,ae=RegExp("^"+ie.call(oe).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function se(t){return!(!Ft(t)||(e=t,Jt&&Jt in e))&&(Xt(t)?ae:ee).test(te(t));var e}function ue(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return se(n)?n:void 0}var le=ue(xt,"WeakMap"),ce=Object.create,fe=function(){function t(){}return function(e){if(!Ft(e))return{};if(ce)return ce(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();function he(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)}function de(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}var pe=Date.now;var ge=function(){try{var t=ue(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),me=function(t){var e=0,n=0;return function(){var r=pe(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(ge?function(t,e){return ge(t,"toString",{configurable:!0,enumerable:!1,value:(n=e,function(){return n}),writable:!0});var n}:Zt);function ve(t){return t!=t}function ye(t,e){return!!(null==t?0:t.length)&&function(t,e,n){return e==e?function(t,e,n){for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}(t,e,n):function(t,e,n,r){for(var i=t.length,o=n+(r?1:-1);r?o--:++o<i;)if(e(t[o],o,t))return o;return-1}(t,ve,n)}(t,e,0)>-1}var be=/^(?:0|[1-9]\d*)$/;function _e(t,e){var n=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==n||"symbol"!=n&&be.test(t))&&t>-1&&t%1==0&&t<e}function we(t,e,n){"__proto__"==e&&ge?ge(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function Oe(t,e){return t===e||t!=t&&e!=e}var xe=Object.prototype.hasOwnProperty;function Ee(t,e,n){var r=t[e];xe.call(t,e)&&Oe(r,n)&&(void 0!==n||e in t)||we(t,e,n)}function Se(t,e,n,r){var i=!n;n||(n={});for(var o=-1,a=e.length;++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?we(n,s,u):Ee(n,s,u)}return n}var Te=Math.max;function Me(t,e){return me(function(t,e,n){return e=Te(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,o=Te(r.length-e,0),a=Array(o);++i<o;)a[i]=r[e+i];i=-1;for(var s=Array(e+1);++i<e;)s[i]=r[i];return s[e]=n(a),he(t,this,s)}}(t,e,Zt),t+"")}function Ce(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}function De(t){return null!=t&&Ce(t.length)&&!Xt(t)}function Pe(t,e,n){if(!Ft(n))return!1;var r=typeof e;return!!("number"==r?De(n)&&_e(e,n.length):"string"==r&&e in n)&&Oe(n[e],t)}var Ae=Object.prototype;function ke(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Ae)}function Le(t){return kt(t)&&"[object Arguments]"==At(t)}var Re=Object.prototype,Ie=Re.hasOwnProperty,Ne=Re.propertyIsEnumerable,je=Le(function(){return arguments}())?Le:function(t){return kt(t)&&Ie.call(t,"callee")&&!Ne.call(t,"callee")};var Be="object"==typeof t&&t&&!t.nodeType&&t,Ve=Be&&"object"==typeof module&&module&&!module.nodeType&&module,He=Ve&&Ve.exports===Be?xt.Buffer:void 0,Ue=(He?He.isBuffer:void 0)||function(){return!1},Fe={};function Ge(t){return function(e){return t(e)}}Fe["[object Float32Array]"]=Fe["[object Float64Array]"]=Fe["[object Int8Array]"]=Fe["[object Int16Array]"]=Fe["[object Int32Array]"]=Fe["[object Uint8Array]"]=Fe["[object Uint8ClampedArray]"]=Fe["[object Uint16Array]"]=Fe["[object Uint32Array]"]=!0,Fe["[object Arguments]"]=Fe["[object Array]"]=Fe["[object ArrayBuffer]"]=Fe["[object Boolean]"]=Fe["[object DataView]"]=Fe["[object Date]"]=Fe["[object Error]"]=Fe["[object Function]"]=Fe["[object Map]"]=Fe["[object Number]"]=Fe["[object Object]"]=Fe["[object RegExp]"]=Fe["[object Set]"]=Fe["[object String]"]=Fe["[object WeakMap]"]=!1;var ze="object"==typeof t&&t&&!t.nodeType&&t,We=ze&&"object"==typeof module&&module&&!module.nodeType&&module,Ye=We&&We.exports===ze&&wt.process,qe=function(){try{var t=We&&We.require&&We.require("util").types;return t||Ye&&Ye.binding&&Ye.binding("util")}catch(t){}}(),Ze=qe&&qe.isTypedArray,Xe=Ze?Ge(Ze):function(t){return kt(t)&&Ce(t.length)&&!!Fe[At(t)]},Ke=Object.prototype.hasOwnProperty;function $e(t,e){var n=It(t),r=!n&&je(t),i=!n&&!r&&Ue(t),o=!n&&!r&&!i&&Xe(t),a=n||r||i||o,s=a?function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}(t.length,String):[],u=s.length;for(var l in t)!e&&!Ke.call(t,l)||a&&("length"==l||i&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||_e(l,u))||s.push(l);return s}function Je(t,e){return function(n){return t(e(n))}}var Qe=Je(Object.keys,Object),tn=Object.prototype.hasOwnProperty;function en(t){if(!ke(t))return Qe(t);var e=[];for(var n in Object(t))tn.call(t,n)&&"constructor"!=n&&e.push(n);return e}function nn(t){return De(t)?$e(t):en(t)}var rn=Object.prototype.hasOwnProperty;function on(t){if(!Ft(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=ke(t),n=[];for(var r in t)("constructor"!=r||!e&&rn.call(t,r))&&n.push(r);return n}function an(t){return De(t)?$e(t,!0):on(t)}var sn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,un=/^\w*$/;function ln(t,e){if(It(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!Lt(t))||(un.test(t)||!sn.test(t)||null!=e&&t in Object(e))}var cn=ue(Object,"create");var fn=Object.prototype.hasOwnProperty;var hn=Object.prototype.hasOwnProperty;function dn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function pn(t,e){for(var n=t.length;n--;)if(Oe(t[n][0],e))return n;return-1}dn.prototype.clear=function(){this.__data__=cn?cn(null):{},this.size=0},dn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},dn.prototype.get=function(t){var e=this.__data__;if(cn){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return fn.call(e,t)?e[t]:void 0},dn.prototype.has=function(t){var e=this.__data__;return cn?void 0!==e[t]:hn.call(e,t)},dn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=cn&&void 0===e?"__lodash_hash_undefined__":e,this};var gn=Array.prototype.splice;function mn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}mn.prototype.clear=function(){this.__data__=[],this.size=0},mn.prototype.delete=function(t){var e=this.__data__,n=pn(e,t);return!(n<0)&&(n==e.length-1?e.pop():gn.call(e,n,1),--this.size,!0)},mn.prototype.get=function(t){var e=this.__data__,n=pn(e,t);return n<0?void 0:e[n][1]},mn.prototype.has=function(t){return pn(this.__data__,t)>-1},mn.prototype.set=function(t,e){var n=this.__data__,r=pn(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var vn=ue(xt,"Map");function yn(t,e){var n=t.__data__;return function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}(e)?n["string"==typeof e?"string":"hash"]:n.map}function bn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}bn.prototype.clear=function(){this.size=0,this.__data__={hash:new dn,map:new(vn||mn),string:new dn}},bn.prototype.delete=function(t){var e=yn(this,t).delete(t);return this.size-=e?1:0,e},bn.prototype.get=function(t){return yn(this,t).get(t)},bn.prototype.has=function(t){return yn(this,t).has(t)},bn.prototype.set=function(t,e){var n=yn(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};function _n(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");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(_n.Cache||bn),n}_n.Cache=bn;var wn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,On=/\\(\\)?/g,xn=function(t){var e=_n(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(wn,(function(t,n,r,i){e.push(r?i.replace(On,"$1"):n||t)})),e}));function En(t){return null==t?"":Bt(t)}function Sn(t,e){return It(t)?t:ln(t,e)?[t]:xn(En(t))}function Tn(t){if("string"==typeof t||Lt(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Mn(t,e){for(var n=0,r=(e=Sn(e,t)).length;null!=t&&n<r;)t=t[Tn(e[n++])];return n&&n==r?t:void 0}function Cn(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}var Dn=Et?Et.isConcatSpreadable:void 0;function Pn(t){return It(t)||je(t)||!!(Dn&&t&&t[Dn])}function An(t,e,n,r,i){var o=-1,a=t.length;for(n||(n=Pn),i||(i=[]);++o<a;){var s=t[o];e>0&&n(s)?e>1?An(s,e-1,n,r,i):Cn(i,s):r||(i[i.length]=s)}return i}function kn(t){return(null==t?0:t.length)?An(t,1):[]}var Ln=Je(Object.getPrototypeOf,Object),Rn=Function.prototype,In=Object.prototype,Nn=Rn.toString,jn=In.hasOwnProperty,Bn=Nn.call(Object);function Vn(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=Array(i);++r<i;)o[r]=t[r+e];return o}(t,e,n)}var Hn=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");function Un(t){return Hn.test(t)}var Fn="[\\ud800-\\udfff]",Gn="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",zn="\\ud83c[\\udffb-\\udfff]",Wn="[^\\ud800-\\udfff]",Yn="(?:\\ud83c[\\udde6-\\uddff]){2}",qn="[\\ud800-\\udbff][\\udc00-\\udfff]",Zn="(?:"+Gn+"|"+zn+")"+"?",Xn="[\\ufe0e\\ufe0f]?"+Zn+("(?:\\u200d(?:"+[Wn,Yn,qn].join("|")+")[\\ufe0e\\ufe0f]?"+Zn+")*"),Kn="(?:"+[Wn+Gn+"?",Gn,Yn,qn,Fn].join("|")+")",$n=RegExp(zn+"(?="+zn+")|"+Kn+Xn,"g");function Jn(t){return Un(t)?function(t){return t.match($n)||[]}(t):function(t){return t.split("")}(t)}var Qn,tr=(Qn="toUpperCase",function(t){var e=Un(t=En(t))?Jn(t):void 0,n=e?e[0]:t.charAt(0),r=e?Vn(e,1).join(""):t.slice(1);return n[Qn]()+r});var er=function(t){return function(e){return null==t?void 0:t[e]}}({"À":"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"}),nr=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,rr=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");var ir=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var or=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var ar="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",sr="["+ar+"]",ur="\\d+",lr="[\\u2700-\\u27bf]",cr="[a-z\\xdf-\\xf6\\xf8-\\xff]",fr="[^\\ud800-\\udfff"+ar+ur+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",hr="(?:\\ud83c[\\udde6-\\uddff]){2}",dr="[\\ud800-\\udbff][\\udc00-\\udfff]",pr="[A-Z\\xc0-\\xd6\\xd8-\\xde]",gr="(?:"+cr+"|"+fr+")",mr="(?:"+pr+"|"+fr+")",vr="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",yr="[\\ufe0e\\ufe0f]?"+vr+("(?:\\u200d(?:"+["[^\\ud800-\\udfff]",hr,dr].join("|")+")[\\ufe0e\\ufe0f]?"+vr+")*"),br="(?:"+[lr,hr,dr].join("|")+")"+yr,_r=RegExp([pr+"?"+cr+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[sr,pr,"$"].join("|")+")",mr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[sr,pr+gr,"$"].join("|")+")",pr+"?"+gr+"+(?:['’](?:d|ll|m|re|s|t|ve))?",pr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ur,br].join("|"),"g");function wr(t,e,n){return t=En(t),void 0===(e=n?void 0:e)?function(t){return or.test(t)}(t)?function(t){return t.match(_r)||[]}(t):function(t){return t.match(ir)||[]}(t):t.match(e)||[]}var Or=RegExp("['’]","g");function xr(t){return function(e){return function(t,e,n,r){var i=-1,o=null==t?0:t.length;for(r&&o&&(n=t[++i]);++i<o;)n=e(n,t[i],i,t);return n}(wr(function(t){return(t=En(t))&&t.replace(nr,er).replace(rr,"")}(e).replace(Or,"")),t,"")}}var Er=xr((function(t,e,n){return e=e.toLowerCase(),t+(n?tr(En(e).toLowerCase()):e)}));function Sr(t,e,n){return void 0===n&&(n=e,e=void 0),void 0!==n&&(n=(n=qt(n))==n?n:0),void 0!==e&&(e=(e=qt(e))==e?e:0),function(t,e,n){return t==t&&(void 0!==n&&(t=t<=n?t:n),void 0!==e&&(t=t>=e?t:e)),t}(qt(t),e,n)}function Tr(t){var e=this.__data__=new mn(t);this.size=e.size}Tr.prototype.clear=function(){this.__data__=new mn,this.size=0},Tr.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Tr.prototype.get=function(t){return this.__data__.get(t)},Tr.prototype.has=function(t){return this.__data__.has(t)},Tr.prototype.set=function(t,e){var n=this.__data__;if(n instanceof mn){var r=n.__data__;if(!vn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new bn(r)}return n.set(t,e),this.size=n.size,this};var Mr="object"==typeof t&&t&&!t.nodeType&&t,Cr=Mr&&"object"==typeof module&&module&&!module.nodeType&&module,Dr=Cr&&Cr.exports===Mr?xt.Buffer:void 0,Pr=Dr?Dr.allocUnsafe:void 0;function Ar(t,e){if(e)return t.slice();var n=t.length,r=Pr?Pr(n):new t.constructor(n);return t.copy(r),r}function kr(){return[]}var Lr=Object.prototype.propertyIsEnumerable,Rr=Object.getOwnPropertySymbols,Ir=Rr?function(t){return null==t?[]:(t=Object(t),function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,o=[];++n<r;){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}(Rr(t),(function(e){return Lr.call(t,e)})))}:kr;var Nr=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)Cn(e,Ir(t)),t=Ln(t);return e}:kr;function jr(t,e,n){var r=e(t);return It(t)?r:Cn(r,n(t))}function Br(t){return jr(t,nn,Ir)}function Vr(t){return jr(t,an,Nr)}var Hr=ue(xt,"DataView"),Ur=ue(xt,"Promise"),Fr=ue(xt,"Set"),Gr=te(Hr),zr=te(vn),Wr=te(Ur),Yr=te(Fr),qr=te(le),Zr=At;(Hr&&"[object DataView]"!=Zr(new Hr(new ArrayBuffer(1)))||vn&&"[object Map]"!=Zr(new vn)||Ur&&"[object Promise]"!=Zr(Ur.resolve())||Fr&&"[object Set]"!=Zr(new Fr)||le&&"[object WeakMap]"!=Zr(new le))&&(Zr=function(t){var e=At(t),n="[object Object]"==e?t.constructor:void 0,r=n?te(n):"";if(r)switch(r){case Gr:return"[object DataView]";case zr:return"[object Map]";case Wr:return"[object Promise]";case Yr:return"[object Set]";case qr:return"[object WeakMap]"}return e});var Xr=Zr,Kr=Object.prototype.hasOwnProperty;var $r=xt.Uint8Array;function Jr(t){var e=new t.constructor(t.byteLength);return new $r(e).set(new $r(t)),e}var Qr=/\w*$/;var ti=Et?Et.prototype:void 0,ei=ti?ti.valueOf:void 0;function ni(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function ri(t,e,n){var r,i,o,a=t.constructor;switch(e){case"[object ArrayBuffer]":return Jr(t);case"[object Boolean]":case"[object Date]":return new a(+t);case"[object DataView]":return function(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return ni(t,n);case"[object Map]":return new a;case"[object Number]":case"[object String]":return new a(t);case"[object RegExp]":return(o=new(i=t).constructor(i.source,Qr.exec(i))).lastIndex=i.lastIndex,o;case"[object Set]":return new a;case"[object Symbol]":return r=t,ei?Object(ei.call(r)):{}}}function ii(t){return"function"!=typeof t.constructor||ke(t)?{}:fe(Ln(t))}var oi=qe&&qe.isMap,ai=oi?Ge(oi):function(t){return kt(t)&&"[object Map]"==Xr(t)};var si=qe&&qe.isSet,ui=si?Ge(si):function(t){return kt(t)&&"[object Set]"==Xr(t)},li={};function ci(t,e,n,r,i,o){var a,s=1&e,u=2&e,l=4&e;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!Ft(t))return t;var c=It(t);if(c){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&Kr.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!s)return de(t,a)}else{var f=Xr(t),h="[object Function]"==f||"[object GeneratorFunction]"==f;if(Ue(t))return Ar(t,s);if("[object Object]"==f||"[object Arguments]"==f||h&&!i){if(a=u||h?{}:ii(t),!s)return u?function(t,e){return Se(t,Nr(t),e)}(t,function(t,e){return t&&Se(e,an(e),t)}(a,t)):function(t,e){return Se(t,Ir(t),e)}(t,function(t,e){return t&&Se(e,nn(e),t)}(a,t))}else{if(!li[f])return i?t:{};a=ri(t,f,s)}}o||(o=new Tr);var d=o.get(t);if(d)return d;o.set(t,a),ui(t)?t.forEach((function(r){a.add(ci(r,e,n,r,t,o))})):ai(t)&&t.forEach((function(r,i){a.set(i,ci(r,e,n,i,t,o))}));var p=c?void 0:(l?u?Vr:Br:u?an:nn)(t);return function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););}(p||t,(function(r,i){p&&(r=t[i=r]),Ee(a,i,ci(r,e,n,i,t,o))})),a}li["[object Arguments]"]=li["[object Array]"]=li["[object ArrayBuffer]"]=li["[object DataView]"]=li["[object Boolean]"]=li["[object Date]"]=li["[object Float32Array]"]=li["[object Float64Array]"]=li["[object Int8Array]"]=li["[object Int16Array]"]=li["[object Int32Array]"]=li["[object Map]"]=li["[object Number]"]=li["[object Object]"]=li["[object RegExp]"]=li["[object Set]"]=li["[object String]"]=li["[object Symbol]"]=li["[object Uint8Array]"]=li["[object Uint8ClampedArray]"]=li["[object Uint16Array]"]=li["[object Uint32Array]"]=!0,li["[object Error]"]=li["[object Function]"]=li["[object WeakMap]"]=!1;function fi(t){return ci(t,5)}function hi(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new bn;++e<n;)this.add(t[e])}function di(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}function pi(t,e){return t.has(e)}hi.prototype.add=hi.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},hi.prototype.has=function(t){return this.__data__.has(t)};function gi(t,e,n,r,i,o){var a=1&n,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 f=-1,h=!0,d=2&n?new hi:void 0;for(o.set(t,e),o.set(e,t);++f<s;){var p=t[f],g=e[f];if(r)var m=a?r(g,p,f,e,t,o):r(p,g,f,t,e,o);if(void 0!==m){if(m)continue;h=!1;break}if(d){if(!di(e,(function(t,e){if(!pi(d,e)&&(p===t||i(p,t,n,r,o)))return d.push(e)}))){h=!1;break}}else if(p!==g&&!i(p,g,n,r,o)){h=!1;break}}return o.delete(t),o.delete(e),h}function mi(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function vi(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var yi=Et?Et.prototype:void 0,bi=yi?yi.valueOf:void 0;var _i=Object.prototype.hasOwnProperty;var wi=Object.prototype.hasOwnProperty;function Oi(t,e,n,r,i,o){var a=It(t),s=It(e),u=a?"[object Array]":Xr(t),l=s?"[object Array]":Xr(e),c="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),f="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),h=u==l;if(h&&Ue(t)){if(!Ue(e))return!1;a=!0,c=!1}if(h&&!c)return o||(o=new Tr),a||Xe(t)?gi(t,e,n,r,i,o):function(t,e,n,r,i,o,a){switch(n){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!o(new $r(t),new $r(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Oe(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var s=mi;case"[object Set]":var u=1&r;if(s||(s=vi),t.size!=e.size&&!u)return!1;var l=a.get(t);if(l)return l==e;r|=2,a.set(t,e);var c=gi(s(t),s(e),r,i,o,a);return a.delete(t),c;case"[object Symbol]":if(bi)return bi.call(t)==bi.call(e)}return!1}(t,e,u,n,r,i,o);if(!(1&n)){var d=c&&wi.call(t,"__wrapped__"),p=f&&wi.call(e,"__wrapped__");if(d||p){var g=d?t.value():t,m=p?e.value():e;return o||(o=new Tr),i(g,m,n,r,o)}}return!!h&&(o||(o=new Tr),function(t,e,n,r,i,o){var a=1&n,s=Br(t),u=s.length;if(u!=Br(e).length&&!a)return!1;for(var l=u;l--;){var c=s[l];if(!(a?c in e:_i.call(e,c)))return!1}var f=o.get(t),h=o.get(e);if(f&&h)return f==e&&h==t;var d=!0;o.set(t,e),o.set(e,t);for(var p=a;++l<u;){var g=t[c=s[l]],m=e[c];if(r)var v=a?r(m,g,c,e,t,o):r(g,m,c,t,e,o);if(!(void 0===v?g===m||i(g,m,n,r,o):v)){d=!1;break}p||(p="constructor"==c)}if(d&&!p){var y=t.constructor,b=e.constructor;y!=b&&"constructor"in t&&"constructor"in e&&!("function"==typeof y&&y instanceof y&&"function"==typeof b&&b instanceof b)&&(d=!1)}return o.delete(t),o.delete(e),d}(t,e,n,r,i,o))}function xi(t,e,n,r,i){return t===e||(null==t||null==e||!kt(t)&&!kt(e)?t!=t&&e!=e:Oi(t,e,n,r,xi,i))}function Ei(t){return t==t&&!Ft(t)}function Si(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}function Ti(t){var e=function(t){for(var e=nn(t),n=e.length;n--;){var r=e[n],i=t[r];e[n]=[r,i,Ei(i)]}return e}(t);return 1==e.length&&e[0][2]?Si(e[0][0],e[0][1]):function(n){return n===t||function(t,e,n,r){var i=n.length,o=i,a=!r;if(null==t)return!o;for(t=Object(t);i--;){var s=n[i];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++i<o;){var u=(s=n[i])[0],l=t[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in t))return!1}else{var f=new Tr;if(r)var h=r(l,c,u,t,e,f);if(!(void 0===h?xi(c,l,3,r,f):h))return!1}}return!0}(n,t,e)}}function Mi(t,e){return null!=t&&e in Object(t)}function Ci(t,e){return null!=t&&function(t,e,n){for(var r=-1,i=(e=Sn(e,t)).length,o=!1;++r<i;){var a=Tn(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:!!(i=null==t?0:t.length)&&Ce(i)&&_e(a,i)&&(It(t)||je(t))}(t,e,Mi)}function Di(t,e){return ln(t)&&Ei(e)?Si(Tn(t),e):function(n){var r=function(t,e,n){var r=null==t?void 0:Mn(t,e);return void 0===r?n:r}(n,t);return void 0===r&&r===e?Ci(n,t):xi(e,r,3)}}function Pi(t){return ln(t)?(e=Tn(t),function(t){return null==t?void 0:t[e]}):function(t){return function(e){return Mn(e,t)}}(t);var e}function Ai(t){return"function"==typeof t?t:null==t?Zt:"object"==typeof t?It(t)?Di(t[0],t[1]):Ti(t):Pi(t)}var ki,Li=function(t,e,n){for(var r=-1,i=Object(t),o=n(t),a=o.length;a--;){var s=o[ki?a:++r];if(!1===e(i[s],s,i))break}return t};var Ri=function(t,e){return function(n,r){if(null==n)return n;if(!De(n))return t(n,r);for(var i=n.length,o=e?i:-1,a=Object(n);(e?o--:++o<i)&&!1!==r(a[o],o,a););return n}}((function(t,e){return t&&Li(t,e,nn)})),Ii=function(){return xt.Date.now()},Ni=Math.max,ji=Math.min;function Bi(t,e,n){var r,i,o,a,s,u,l=0,c=!1,f=!1,h=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function d(e){var n=r,o=i;return r=i=void 0,l=e,a=t.apply(o,n)}function p(t){return l=t,s=setTimeout(m,e),c?d(t):a}function g(t){var n=t-u;return void 0===u||n>=e||n<0||f&&t-l>=o}function m(){var t=Ii();if(g(t))return v(t);s=setTimeout(m,function(t){var n=e-(t-u);return f?ji(n,o-(t-l)):n}(t))}function v(t){return s=void 0,h&&r?d(t):(r=i=void 0,a)}function y(){var t=Ii(),n=g(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return p(u);if(f)return clearTimeout(s),s=setTimeout(m,e),d(u)}return void 0===s&&(s=setTimeout(m,e)),a}return e=qt(e)||0,Ft(n)&&(c=!!n.leading,o=(f="maxWait"in n)?Ni(qt(n.maxWait)||0,e):o,h="trailing"in n?!!n.trailing:h),y.cancel=function(){void 0!==s&&clearTimeout(s),l=0,r=u=i=s=void 0},y.flush=function(){return void 0===s?a:v(Ii())},y}function Vi(t,e,n){(void 0===n||Oe(t[e],n))&&(void 0!==n||e in t)||we(t,e,n)}function Hi(t){return kt(t)&&De(t)}function Ui(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}function Fi(t,e,n,r,i,o,a){var s=Ui(t,n),u=Ui(e,n),l=a.get(u);if(l)Vi(t,n,l);else{var c,f=o?o(s,u,n+"",t,e,a):void 0,h=void 0===f;if(h){var d=It(u),p=!d&&Ue(u),g=!d&&!p&&Xe(u);f=u,d||p||g?It(s)?f=s:Hi(s)?f=de(s):p?(h=!1,f=Ar(u,!0)):g?(h=!1,f=ni(u,!0)):f=[]:function(t){if(!kt(t)||"[object Object]"!=At(t))return!1;var e=Ln(t);if(null===e)return!0;var n=jn.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Nn.call(n)==Bn}(u)||je(u)?(f=s,je(s)?f=Se(c=s,an(c)):Ft(s)&&!Xt(s)||(f=ii(u))):h=!1}h&&(a.set(u,f),i(f,u,r,o,a),a.delete(u)),Vi(t,n,f)}}function Gi(t,e,n,r,i){t!==e&&Li(e,(function(o,a){if(i||(i=new Tr),Ft(o))Fi(t,e,a,n,Gi,r,i);else{var s=r?r(Ui(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),Vi(t,a,s)}}),an)}function zi(t,e,n){for(var r=-1,i=null==t?0:t.length;++r<i;)if(n(e,t[r]))return!0;return!1}function Wi(t,e){var n=-1,r=De(t)?Array(t.length):[];return Ri(t,(function(t,i,o){r[++n]=e(t,i,o)})),r}function Yi(t,e){return An(function(t,e){return(It(t)?Rt:Wi)(t,Ai(e))}(t,e),1/0)}function qi(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var i=t[e];r[i[0]]=i[1]}return r}var Zi=Object.prototype.hasOwnProperty;function Xi(t){if(null==t)return!0;if(De(t)&&(It(t)||"string"==typeof t||"function"==typeof t.splice||Ue(t)||Xe(t)||je(t)))return!t.length;var e=Xr(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(ke(t))return!en(t).length;for(var n in t)if(Zi.call(t,n))return!1;return!0}function Ki(t,e){return xi(t,e)}var $i,Ji=xr((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Qi=($i=function(t,e,n){Gi(t,e,n)},Me((function(t,e){var n=-1,r=e.length,i=r>1?e[r-1]:void 0,o=r>2?e[2]:void 0;for(i=$i.length>3&&"function"==typeof i?(r--,i):void 0,o&&Pe(e[0],e[1],o)&&(i=r<3?void 0:i,r=1),t=Object(t);++n<r;){var a=e[n];a&&$i(t,a,n,i)}return t})));function to(t,e){var n;return Ri(t,(function(t,r,i){return!(n=e(t,r,i))})),!!n}function eo(t,e,n){var r=It(t)?di:to;return n&&Pe(t,e,n)&&(e=void 0),r(t,Ai(e))}var no=Fr&&1/vi(new Fr([,-0]))[1]==1/0?function(t){return new Fr(t)}:function(){};function ro(t,e,n){var r=-1,i=ye,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=zi;else if(o>=200){var l=e?null:no(t);if(l)return vi(l);a=!1,i=pi,u=new hi}else u=e?[]:s;t:for(;++r<o;){var c=t[r],f=e?e(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var h=u.length;h--;)if(u[h]===f)continue t;e&&u.push(f),s.push(c)}else i(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}var io=Me((function(t){var e=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}(t);return Hi(e)&&(e=void 0),ro(An(t,1,Hi,!0),Ai(e))}));function oo(t){return t&&t.length?ro(t):[]}var ao="http://www.w3.org/1999/xhtml",so={svg:"http://www.w3.org/2000/svg",xhtml:ao,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function uo(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),so.hasOwnProperty(e)?{space:so[e],local:t}:t}function lo(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===ao&&e.documentElement.namespaceURI===ao?e.createElement(t):e.createElementNS(n,t)}}function co(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function fo(t){var e=uo(t);return(e.local?co:lo)(e)}function ho(){}function po(t){return null==t?ho:function(){return this.querySelector(t)}}function go(){return[]}function mo(t){return null==t?go:function(){return this.querySelectorAll(t)}}function vo(t){return function(){return this.matches(t)}}function yo(t){return new Array(t.length)}function bo(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}bo.prototype={constructor:bo,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)}};function _o(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 bo(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function wo(t,e,n,r,i,o,a){var s,u,l,c={},f=e.length,h=o.length,d=new Array(f);for(s=0;s<f;++s)(u=e[s])&&(d[s]=l="$"+a.call(u,u.__data__,s,e),l in c?i[s]=u:c[l]=u);for(s=0;s<h;++s)(u=c[l="$"+a.call(t,o[s],s,o)])?(r[s]=u,u.__data__=o[s],c[l]=null):n[s]=new bo(t,o[s]);for(s=0;s<f;++s)(u=e[s])&&c[d[s]]===u&&(i[s]=u)}function Oo(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function xo(t){return function(){this.removeAttribute(t)}}function Eo(t){return function(){this.removeAttributeNS(t.space,t.local)}}function So(t,e){return function(){this.setAttribute(t,e)}}function To(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Mo(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Co(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)}}function Do(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Po(t){return function(){this.style.removeProperty(t)}}function Ao(t,e,n){return function(){this.style.setProperty(t,e,n)}}function ko(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function Lo(t,e){return t.style.getPropertyValue(e)||Do(t).getComputedStyle(t,null).getPropertyValue(e)}function Ro(t){return function(){delete this[t]}}function Io(t,e){return function(){this[t]=e}}function No(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function jo(t){return t.trim().split(/^|\s+/)}function Bo(t){return t.classList||new Vo(t)}function Vo(t){this._node=t,this._names=jo(t.getAttribute("class")||"")}function Ho(t,e){for(var n=Bo(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function Uo(t,e){for(var n=Bo(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function Fo(t){return function(){Ho(this,t)}}function Go(t){return function(){Uo(this,t)}}function zo(t,e){return function(){(e.apply(this,arguments)?Ho:Uo)(this,t)}}function Wo(){this.textContent=""}function Yo(t){return function(){this.textContent=t}}function qo(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function Zo(){this.innerHTML=""}function Xo(t){return function(){this.innerHTML=t}}function Ko(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function $o(){this.nextSibling&&this.parentNode.appendChild(this)}function Jo(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Qo(){return null}function ta(){var t=this.parentNode;t&&t.removeChild(this)}function ea(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function na(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}Vo.prototype={add:function(t){this._names.indexOf(t)<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 ra={},ia=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(ra={mouseenter:"mouseover",mouseleave:"mouseout"}));function oa(t,e,n){return t=aa(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function aa(t,e,n){return function(r){var i=ia;ia=r;try{t.call(this,this.__data__,e,n)}finally{ia=i}}}function sa(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 ua(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.capture);++i?e.length=i:delete this.__on}}}function la(t,e,n){var r=ra.hasOwnProperty(t.type)?oa:aa;return function(i,o,a){var s,u=this.__on,l=r(e,o,a);if(u)for(var c=0,f=u.length;c<f;++c)if((s=u[c]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},u?u.push(s):this.__on=[s]}}function ca(t,e,n){var r=Do(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 fa(t,e){return function(){return ca(this,t,e)}}function ha(t,e){return function(){return ca(this,t,e.apply(this,arguments))}}var da,pa=[null];function ga(t,e){this._groups=t,this._parents=e}function ma(){return new ga([[document.documentElement]],pa)}function va(t){return"string"==typeof t?new ga([[document.querySelector(t)]],[document.documentElement]):new ga([[t]],pa)}function ya(){for(var t,e=ia;t=e.sourceEvent;)e=t;return e}function ba(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}function _a(t){var e=ya();return e.changedTouches&&(e=e.changedTouches[0]),ba(t,e)}ga.prototype=ma.prototype={constructor:ga,select:function(t){"function"!=typeof t&&(t=po(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 ga(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=mo(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 ga(r,i)},filter:function(t){"function"!=typeof t&&(t=vo(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 ga(r,this._parents)},data:function(t,e){if(!t)return d=new Array(this.size()),l=-1,this.each((function(t){d[++l]=t})),d;var n=e?wo:_o,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(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],f=i[l],h=f.length,d=t.call(c,c&&c.__data__,l,r),p=d.length,g=s[l]=new Array(p),m=a[l]=new Array(p);n(c,f,g,m,u[l]=new Array(h),d,e);for(var v,y,b=0,_=0;b<p;++b)if(v=g[b]){for(b>=_&&(_=b+1);!(y=m[_])&&++_<p;);v._next=y||null}}return(a=new ga(a,r))._enter=s,a._exit=u,a},enter:function(){return new ga(this._enter||this._groups.map(yo),this._parents)},exit:function(){return new ga(this._exit||this._groups.map(yo),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return r="function"==typeof t?t(r):r.append(t+""),null!=e&&(i=e(i)),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){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],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new ga(a,this._parents)},order: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},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Oo);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 ga(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node: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},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each: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},attr:function(t,e){var n=uo(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?Eo:xo:"function"==typeof e?n.local?Co:Mo:n.local?To:So)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?Po:"function"==typeof e?ko:Ao)(t,e,null==n?"":n)):Lo(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Ro:"function"==typeof e?No:Io)(t,e)):this.node()[t]},classed:function(t,e){var n=jo(t+"");if(arguments.length<2){for(var r=Bo(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?zo:e?Fo:Go)(n,e))},text:function(t){return arguments.length?this.each(null==t?Wo:("function"==typeof t?qo:Yo)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?Zo:("function"==typeof t?Ko:Xo)(t)):this.node().innerHTML},raise:function(){return this.each($o)},lower:function(){return this.each(Jo)},append:function(t){var e="function"==typeof t?t:fo(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:fo(t),r=null==e?Qo:"function"==typeof e?e:po(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(ta)},clone:function(t){return this.select(t?na:ea)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=sa(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?la:ua,null==n&&(n=!1),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},dispatch:function(t,e){return this.each(("function"==typeof e?ha:fa)(t,e))}},function(t){function e(e,n){var r=t.getProperty(e,"legend","additionalItems"),i=t.getProperty(n,"legend","additionalItems");if(r&&i){var o=i.map((function(t){return t.type})),a=r.map((function(t){return t.type})),s=_t.filter((function(t){return a.includes(t.type)&&!o.includes(t.type)}));e.legend.additionalItems=s,n.legend.additionalItems=t.unionBy(s,i,"name")}}t.debounce=Bi,t.clone=fi,t.merge=Qi,t.unionBy=io,t.removeArrayDuplicates=oo,t.clamp=Sr,t.flatten=kn,t.camelCase=Er,t.isEmpty=Xi,t.isEqual=Ki,t.flatMapDeep=Yi,t.kebabCase=Ji,t.fromPairs=qi,t.some=eo,t.debounceWithD3MousePosition=function(t,e,n){var r=null;return function(){var i=this,o=arguments;i.mousePosition=_a(n),clearTimeout(r),r=setTimeout((function(){t.apply(i,o)}),e)}},t.mergeDefaultChartOptions=function(n,r){n=t.clone(n);var i=Object.keys(r.axes||{});for(var o in 0===i.length&&delete n.axes,n.axes)if(i.includes(o)){var a=r.axes[o];(a.primary||a.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 s=a.mapsTo;if(null==s){var u=a.scaleType;null==u?a.mapsTo="value":u===I.TIME?a.mapsTo="date":u===I.LABELS&&(a.mapsTo="key")}}else delete n.axes[o];return e(n,r),t.merge(n,r)},t.getDimensions=function(t){return{width:parseFloat(t.style.width.replace("px","")||t.offsetWidth),height:parseFloat(t.style.height.replace("px","")||t.offsetHeight)}},t.getTranslationValues=function(t){if(t){var e=t.getAttribute("transform").match(/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/);if(!e)return null;if(e[0]){var n=e[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:n[0],ty:n[1]}}return null}},t.getTranformOffsets=function(t){var e=/\(([^)]+)\)/.exec(t)[1].split(",");return{x:parseFloat(e[0]),y:parseFloat(e[1])}},t.formatWidthHeightValues=function(t){var e=t.toString();return e.match(/[a-z]/i)?e:e+"px"},t.capitalizeFirstLetter=function(t){return t[0].toUpperCase()+t.slice(1)},t.convertValueToPercentage=function(t,e){var n=t/e.reduce((function(t,e){return t+e.value}),0)*100;return n%1!=0?parseFloat(n.toFixed(1)):n},t.truncateLabel=function(t,e,n){return n>t.length?t:e===L.MID_LINE?t.substr(0,n/2)+"..."+t.substr(-n/2):e===L.FRONT_LINE?"..."+t.substr(-n):e===L.END_LINE?t.substr(0,n)+"...":void 0},t.updateLegendAdditionalItems=e,t.arrayDifferences=function(t,e){var n={missing:[],added:[]};return t.forEach((function(t){-1===e.indexOf(t)&&n.missing.push(t)})),e.forEach((function(e){-1===t.indexOf(e)&&n.added.push(e)})),n},t.getDuplicateValues=function(t){var e=[],n=[];return t.forEach((function(t){-1!==e.indexOf(t)&&-1===n.indexOf(t)&&n.push(t),e.push(t)})),n},t.moveToFront=function(t){return t.each((function(){this.parentNode.appendChild(this)}))},t.getProperty=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},t.flipSVGCoordinatesBasedOnOrientation=function(t,e){return e===R.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},t.generateSVGPathString=function(e,n){var r=t.flipSVGCoordinatesBasedOnOrientation(e,n),i=r.x0,o=r.x1,a=r.y0,s=r.y1;return"M"+i+","+a+"L"+i+","+s+"L"+o+","+s+"L"+o+","+a+"L"+i+","+a},t.flipDomainAndRangeBasedOnOrientation=function(t,e,n){return n===R.VERTICAL?[t,e]:[e,t]},t.compareNumeric=function(t,e){return Number(t)===Number(e)}}(da||(da={}));var wa="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Oa(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function xa(t,e){return t(e={exports:{}},e.exports),e.exports}var Ea=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e,r){var i;r=r||{},i="string"==typeof n[t]?n[t]:1===e?n[t].one:n[t].other.replace("{{count}}",e);if(r.addSuffix)return r.comparison>0?"in "+i:i+" ago";return i};var n={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"}};t.exports=e.default}));Oa(Ea);var Sa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth;return t.formats[r]||t.formats[t.defaultWidth]}},t.exports=e.default}));Oa(Sa);var Ta=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n,r=(n=Sa)&&n.__esModule?n:{default:n};var i={date:(0,r.default)({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:(0,r.default)({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:(0,r.default)({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})};e.default=i,t.exports=e.default}));Oa(Ta);var Ma=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e,r,i){return n[t]};var n={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};t.exports=e.default}));Oa(Ma);var Ca=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return function(e,n){var r,i=n||{};if("formatting"===(i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,a=i.width?String(i.width):o;r=t.formattingValues[a]||t.formattingValues[o]}else{var s=t.defaultWidth,u=i.width?String(i.width):t.defaultWidth;r=t.values[u]||t.values[s]}return r[t.argumentCallback?t.argumentCallback(e):e]}},t.exports=e.default}));Oa(Ca);var Da=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n,r=(n=Ca)&&n.__esModule?n:{default:n};var i={ordinalNumber:function(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"},era:(0,r.default)({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:(0,r.default)({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:(0,r.default)({values:{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"]},defaultWidth:"wide"}),day:(0,r.default)({values:{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"]},defaultWidth:"wide"}),dayPeriod:(0,r.default)({values:{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"}},defaultWidth:"wide",formattingValues:{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"}},defaultFormattingWidth:"wide"})};e.default=i,t.exports=e.default}));Oa(Da);var Pa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(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{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(a.length)}}},t.exports=e.default}));Oa(Pa);var Aa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(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)?function(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}(c,(function(t){return t.test(r)})):function(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(l.length)}}},t.exports=e.default}));Oa(Aa);var ka=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(Pa),r=i(Aa);function i(t){return t&&t.__esModule?t:{default:t}}var o={ordinalNumber:(0,n.default)({matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}}),era:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:(0,r.default)({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),day:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),dayPeriod:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"any",parsePatterns:{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}},defaultParseWidth:"any"})};e.default=o,t.exports=e.default}));Oa(ka);var La=Oa(xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=s(Ea),r=s(Ta),i=s(Ma),o=s(Da),a=s(ka);function s(t){return t&&t.__esModule?t:{default:t}}var u={code:"en-US",formatDistance:n.default,formatLong:r.default,formatRelative:i.default,localize:o.default,match:a.default,options:{weekStartsOn:0,firstWeekContainsDate:1}};e.default=u,t.exports=e.default}))),Ra={type:L.END_LINE,threshold:16,numCharacter:14},Ia={enabled:!0,position:N.BOTTOM,clickable:!0,truncation:Ra,alignment:j.LEFT,order:null,additionalItems:[]},Na={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},ja={enabled:!0},Ba={enabled:!0,showTotal:!0,truncation:Ra,groupLabel:"Group"},Va={top:{visible:!0,includeZero:!0,truncation:Ra},bottom:{visible:!0,includeZero:!0,truncation:Ra},left:{visible:!0,includeZero:!0,truncation:Ra},right:{visible:!0,includeZero:!0,truncation:Ra}},Ha={addSpaceOnEdges:1,showDayName:!1,localeObject:La,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"}}},Ua=document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled,Fa={width:null,height:null,resizable:!0,tooltip:Ba,legend:Ia,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:M([{type:$.SHOW_AS_DATATABLE}],Ua?[{type:$.MAKE_FULLSCREEN}]:[],[{type:$.EXPORT_CSV},{type:$.EXPORT_PNG},{type:$.EXPORT_JPG}])}},Ga=da.merge({},Fa,{axes:Va,timeScale:Ha,grid:Na,ruler:ja,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:k.GRAPH_VIEW}}}),za=da.merge({},Ga,{bars:{maxWidth:16},timeScale:da.merge(Ha,{addSpaceOnEdges:1})}),Wa=da.merge({},za,{}),Ya=da.merge({},za,{}),qa=da.merge({},za,{bars:da.merge({},za.bars,{dividerSize:1.5})}),Za=da.merge({},za,{}),Xa=da.merge({},Ga,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),Ka=Xa,$a=da.merge({},Xa,{points:{radius:3,filled:!1,enabled:!0}}),Ja=da.merge({},$a,{timeScale:da.merge(Ha,{addSpaceOnEdges:0})}),Qa=Ja,ts=da.merge({},Ga,{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:Q.RADIUS,name:"Radius"}]}}),es=da.merge({},Ga,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:Q.AREA,name:"Poor area"},{type:Q.AREA,name:"Satisfactory area"},{type:Q.AREA,name:"Great area"},{type:Q.QUARTILE,name:"Quartiles"}]}}),ns=da.merge({},Fa,{tooltip:da.merge({},Ba,{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"}}),rs=da.merge({},Fa,{pie:{labels:{formatter:null,enabled:!0},alignment:j.LEFT,sortFunction:null}}),is=da.merge({},Fa,{legend:{enabled:!1},gauge:{type:Y.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:j.LEFT}}),os={chart:Fa,axisChart:Ga,simpleBarChart:Wa,groupedBarChart:Ya,stackedBarChart:qa,boxplotChart:Za,bubbleChart:ts,bulletChart:es,lineChart:$a,areaChart:Ja,stackedAreaChart:Qa,scatterChart:Xa,lollipopChart:Ka,pieChart:rs,donutChart:da.merge({},rs,{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:j.LEFT}}),meterChart:da.merge({},Fa,{legend:{enabled:!1},meter:{height:8,statusBar:{percentageIndicator:{enabled:!0}}}}),radarChart:da.merge({},Fa,{radar:{axes:{angle:"key",value:"value"},alignment:j.LEFT},tooltip:{gridline:{enabled:!0},valueFormatter:function(t){return null!=t?t:"N/A"}}}),gaugeChart:is,comboChart:da.merge({},za,{comboChartTypes:[]}),treemapChart:da.merge({},Fa,{data:da.merge(Fa.data,{groupMapsTo:"name"})}),circlePackChart:da.merge({},Fa,ut,{data:da.merge(Fa.data,{groupMapsTo:"name"})}),wordCloudChart:ns},as=Object.freeze({__proto__:null,grid:Na,ruler:ja,baseTooltip:Ba,timeScale:Ha,options:os,area:ot,axis:at,canvasZoomSettings:st,circlePack:ut,color:lt,boxplot:ct,legend:ft,lines:ht,meter:dt,pie:pt,radar:gt,spacers:mt,tooltips:vt,transitions:yt,toolbar:{buttonSize:32,iconSize:20,height:32,spacerHeight:10,iconPadding:6},zoomBar:bt,defaultLegendAdditionalItems:_t});function ss(){}function us(t,e){var n=new ss;if(t instanceof ss)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==e)for(;++i<o;)n.set(i,t[i]);else for(;++i<o;)n.set(e(r=t[i],i,t),r)}else if(t)for(var a in t)n.set(a,t[a]);return n}function ls(){}ss.prototype=us.prototype={constructor:ss,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var cs=us.prototype;function fs(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function hs(t){var e;return 1===t.length&&(e=t,t=function(t,n){return fs(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)<0?r=o+1:i=o}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)>0?i=o:r=o+1}return r}}}ls.prototype=function(t,e){var n=new ls;if(t instanceof ls)t.each((function(t){n.add(t)}));else if(t){var r=-1,i=t.length;if(null==e)for(;++r<i;)n.add(t[r]);else for(;++r<i;)n.add(e(t[r],r,t))}return n}.prototype={constructor:ls,has:cs.has,add:function(t){return this["$"+(t+="")]=t,this},remove:cs.remove,clear:cs.clear,values:cs.keys,size:cs.size,empty:cs.empty,each:cs.each};var ds=hs(fs).right;function ps(t){return null===t?NaN:+t}function gs(t,e){var n,r,i,o=t.length,a=-1;if(null==e){for(;++a<o;)if(null!=(n=t[a])&&n>=n)for(r=i=n;++a<o;)null!=(n=t[a])&&(r>n&&(r=n),i<n&&(i=n))}else for(;++a<o;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=i=n;++a<o;)null!=(n=e(t[a],a,t))&&(r>n&&(r=n),i<n&&(i=n));return[r,i]}function ms(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}var vs=Math.sqrt(50),ys=Math.sqrt(10),bs=Math.sqrt(2);function _s(t,e,n){var r,i,o,a,s=-1;if(n=+n,(t=+t)===(e=+e)&&n>0)return[t];if((r=e<t)&&(i=t,t=e,e=i),0===(a=ws(t,e,n))||!isFinite(a))return[];if(a>0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(i=Math.ceil(e-t+1));++s<i;)o[s]=(t+s)*a;else for(t=Math.floor(t*a),e=Math.ceil(e*a),o=new Array(i=Math.ceil(t-e+1));++s<i;)o[s]=(t-s)/a;return r&&o.reverse(),o}function ws(t,e,n){var r=(e-t)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),o=r/Math.pow(10,i);return i>=0?(o>=vs?10:o>=ys?5:o>=bs?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=vs?10:o>=ys?5:o>=bs?2:1)}function Os(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=vs?i*=10:o>=ys?i*=5:o>=bs&&(i*=2),e<t?-i:i}function xs(t,e,n){if(null==n&&(n=ps),r=t.length){if((e=+e)<=0||r<2)return+n(t[0],0,t);if(e>=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,o=Math.floor(i),a=+n(t[o],o,t);return a+(+n(t[o+1],o+1,t)-a)*(i-o)}}function Es(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&n>r&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&n>r&&(r=n);return r}function Ss(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&r>n&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&r>n&&(r=n);return r}function Ts(t,e){var n,r=t.length,i=-1,o=0;if(null==e)for(;++i<r;)(n=+t[i])&&(o+=n);else for(;++i<r;)(n=+e(t[i],i,t))&&(o+=n);return o}function Ms(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}var Cs=Array.prototype,Ds=Cs.map,Ps=Cs.slice,As={name:"implicit"};function ks(){var t=us(),e=[],n=[],r=As;function i(i){var o=i+"",a=t.get(o);if(!a){if(r!==As)return r;t.set(o,a=e.push(i))}return n[(a-1)%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=us();for(var r,o,a=-1,s=n.length;++a<s;)t.has(o=(r=n[a])+"")||t.set(o,e.push(r));return i},i.range=function(t){return arguments.length?(n=Ps.call(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return ks(e,n).unknown(r)},Ms.apply(i,arguments),i}function Ls(){var t,e,n=ks().unknown(void 0),r=n.domain,i=n.range,o=[0,1],a=!1,s=0,u=0,l=.5;function c(){var n=r().length,c=o[1]<o[0],f=o[c-0],h=o[1-c];t=(h-f)/Math.max(1,n-s+2*u),a&&(t=Math.floor(t)),f+=(h-f-t*(n-s))*l,e=t*(1-s),a&&(f=Math.round(f),e=Math.round(e));var d=ms(n).map((function(e){return f+t*e}));return i(c?d.reverse():d)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),c()):r()},n.range=function(t){return arguments.length?(o=[+t[0],+t[1]],c()):o.slice()},n.rangeRound=function(t){return o=[+t[0],+t[1]],a=!0,c()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(a=!!t,c()):a},n.padding=function(t){return arguments.length?(s=Math.min(1,u=+t),c()):s},n.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),c()):s},n.paddingOuter=function(t){return arguments.length?(u=+t,c()):u},n.align=function(t){return arguments.length?(l=Math.max(0,Math.min(1,t)),c()):l},n.copy=function(){return Ls(r(),o).round(a).paddingInner(s).paddingOuter(u).align(l)},Ms.apply(c(),arguments)}function Rs(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Is(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Ns(){}var js="\\s*([+-]?\\d+)\\s*",Bs="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Vs="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Hs=/^#([0-9a-f]{3,8})$/,Us=new RegExp("^rgb\\("+[js,js,js]+"\\)$"),Fs=new RegExp("^rgb\\("+[Vs,Vs,Vs]+"\\)$"),Gs=new RegExp("^rgba\\("+[js,js,js,Bs]+"\\)$"),zs=new RegExp("^rgba\\("+[Vs,Vs,Vs,Bs]+"\\)$"),Ws=new RegExp("^hsl\\("+[Bs,Vs,Vs]+"\\)$"),Ys=new RegExp("^hsla\\("+[Bs,Vs,Vs,Bs]+"\\)$"),qs={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 Zs(){return this.rgb().formatHex()}function Xs(){return this.rgb().formatRgb()}function Ks(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=Hs.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?$s(e):3===n?new eu(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?new eu(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?new eu(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=Us.exec(t))?new eu(e[1],e[2],e[3],1):(e=Fs.exec(t))?new eu(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Gs.exec(t))?Js(e[1],e[2],e[3],e[4]):(e=zs.exec(t))?Js(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=Ws.exec(t))?ou(e[1],e[2]/100,e[3]/100,1):(e=Ys.exec(t))?ou(e[1],e[2]/100,e[3]/100,e[4]):qs.hasOwnProperty(t)?$s(qs[t]):"transparent"===t?new eu(NaN,NaN,NaN,0):null}function $s(t){return new eu(t>>16&255,t>>8&255,255&t,1)}function Js(t,e,n,r){return r<=0&&(t=e=n=NaN),new eu(t,e,n,r)}function Qs(t){return t instanceof Ns||(t=Ks(t)),t?new eu((t=t.rgb()).r,t.g,t.b,t.opacity):new eu}function tu(t,e,n,r){return 1===arguments.length?Qs(t):new eu(t,e,n,null==r?1:r)}function eu(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function nu(){return"#"+iu(this.r)+iu(this.g)+iu(this.b)}function ru(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function iu(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function ou(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new uu(t,e,n,r)}function au(t){if(t instanceof uu)return new uu(t.h,t.s,t.l,t.opacity);if(t instanceof Ns||(t=Ks(t)),!t)return new uu;if(t instanceof uu)return t;var e=(t=t.rgb()).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 uu(a,s,u,t.opacity)}function su(t,e,n,r){return 1===arguments.length?au(t):new uu(t,e,n,null==r?1:r)}function uu(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function lu(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 cu(t){return function(){return t}}function fu(t){return 1==(t=+t)?hu:function(e,n){return n-e?function(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)}}(e,n,t):cu(isNaN(e)?n:e)}}function hu(t,e){var n=e-t;return n?function(t,e){return function(n){return t+n*e}}(t,n):cu(isNaN(t)?e:t)}Rs(Ns,Ks,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:Zs,formatHex:Zs,formatHsl:function(){return au(this).formatHsl()},formatRgb:Xs,toString:Xs}),Rs(eu,tu,Is(Ns,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new eu(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new eu(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){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:nu,formatHex:nu,formatRgb:ru,toString:ru})),Rs(uu,su,Is(Ns,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new uu(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new uu(this.h,this.s,this.l*t,this.opacity)},rgb:function(){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 eu(lu(t>=240?t-240:t+120,i,r),lu(t,i,r),lu(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var du=function t(e){var n=fu(e);function r(t,e){var r=n((t=tu(t)).r,(e=tu(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=hu(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 pu(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 gu(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]=Ou(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}}function mu(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function vu(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function yu(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]=Ou(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var bu=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,_u=new RegExp(bu.source,"g");function wu(t,e){var n,r,i,o=bu.lastIndex=_u.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=bu.exec(t))&&(r=_u.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:vu(n,r)})),o=_u.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(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("")})}function Ou(t,e){var n,r=typeof e;return null==e||"boolean"===r?cu(e):("number"===r?vu:"string"===r?(n=Ks(e))?(e=n,du):wu:e instanceof Ks?du:e instanceof Date?mu:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}(e)?pu:Array.isArray(e)?gu:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?yu:vu)(t,e)}function xu(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}var Eu,Su,Tu,Mu,Cu=180/Math.PI,Du={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Pu(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)*Cu,skewX:Math.atan(u)*Cu,scaleX:a,scaleY:s}}function Au(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(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:vu(t,i)},{i:u-2,x:vu(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(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:vu(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:vu(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(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:vu(t,n)},{i:s-2,x:vu(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var ku=Au((function(t){return"none"===t?Du:(Eu||(Eu=document.createElement("DIV"),Su=document.documentElement,Tu=document.defaultView),Eu.style.transform=t,t=Tu.getComputedStyle(Su.appendChild(Eu),null).getPropertyValue("transform"),Su.removeChild(Eu),Pu(+(t=t.slice(7,-1).split(","))[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),Lu=Au((function(t){return null==t?Du:(Mu||(Mu=document.createElementNS("http://www.w3.org/2000/svg","g")),Mu.setAttribute("transform",t),(t=Mu.transform.baseVal.consolidate())?Pu((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Du)}),", ",")",")");function Ru(t){return+t}var Iu=[0,1];function Nu(t){return t}function ju(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function Bu(t){var e,n=t[0],r=t[t.length-1];return n>r&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function Vu(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=ju(i,r),o=n(a,o)):(r=ju(r,i),o=n(o,a)),function(t){return o(r(t))}}function Hu(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=ju(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=ds(t,e,1,r)-1;return o[n](i[n](e))}}function Uu(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Fu(){var t,e,n,r,i,o,a=Iu,s=Iu,u=Ou,l=Nu;function c(){return r=Math.min(a.length,s.length)>2?Hu:Vu,i=o=null,f}function f(e){return isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return f.invert=function(n){return l(e((o||(o=r(s,a.map(t),vu)))(n)))},f.domain=function(t){return arguments.length?(a=Ds.call(t,Ru),l===Nu||(l=Bu(a)),c()):a.slice()},f.range=function(t){return arguments.length?(s=Ps.call(t),c()):s.slice()},f.rangeRound=function(t){return s=Ps.call(t),u=xu,c()},f.clamp=function(t){return arguments.length?(l=t?Bu(a):Nu,f):l!==Nu},f.interpolate=function(t){return arguments.length?(u=t,c()):u},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,c()}}function Gu(t,e){return Fu()(t,e)}function zu(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)]}function Wu(t){return(t=zu(Math.abs(t)))?t[1]:NaN}var Yu,qu=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Zu(t){if(!(e=qu.exec(t)))throw new Error("invalid format: "+t);var e;return new Xu({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 Xu(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+""}function Ku(t,e){var n=zu(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")}Zu.prototype=Xu.prototype,Xu.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 $u={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return Ku(100*t,e)},r:Ku,s:function(t,e){var n=zu(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(Yu=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")+zu(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function Ju(t){return t}var Qu,tl,el,nl=Array.prototype.map,rl=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function il(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?Ju:(e=nl.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Ju:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(nl.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=Zu(t)).fill,n=t.align,f=t.sign,h=t.symbol,d=t.zero,p=t.width,g=t.comma,m=t.precision,v=t.trim,y=t.type;"n"===y?(g=!0,y="g"):$u[y]||(void 0===m&&(m=12),v=!0,y="g"),(d||"0"===e&&"="===n)&&(d=!0,e="0",n="=");var b="$"===h?i:"#"===h&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",_="$"===h?o:/[%p]/.test(y)?u:"",w=$u[y],O=/[defgprs%]/.test(y);function x(t){var i,o,u,h=b,x=_;if("c"===y)x=w(t)+x,t="";else{var E=(t=+t)<0;if(t=isNaN(t)?c:w(Math.abs(t),m),v&&(t=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)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),E&&0==+t&&(E=!1),h=(E?"("===f?f:l:"-"===f||"("===f?"":f)+h,x=("s"===y?rl[8+Yu/3]:"")+x+(E&&"("===f?")":""),O)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){x=(46===u?a+t.slice(i+1):t.slice(i))+x,t=t.slice(0,i);break}}g&&!d&&(t=r(t,1/0));var S=h.length+t.length+x.length,T=S<p?new Array(p-S+1).join(e):"";switch(g&&d&&(t=r(T+t,T.length?p-x.length:1/0),T=""),n){case"<":t=h+t+x+T;break;case"=":t=h+T+t+x;break;case"^":t=T.slice(0,S=T.length>>1)+h+t+x+T.slice(S);break;default:t=T+h+t+x}return s(t)}return m=void 0===m?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,m)):Math.max(0,Math.min(20,m)),x.toString=function(){return t+""},x}return{format:f,formatPrefix:function(t,e){var n=f(((t=Zu(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(Wu(e)/3))),i=Math.pow(10,-r),o=rl[8+r/3];return function(t){return n(i*t)+o}}}}function ol(t,e,n,r){var i,o=Os(t,e,n);switch((r=Zu(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Wu(e)/3)))-Wu(Math.abs(t)))}(o,a))||(r.precision=i),el(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Wu(e)-Wu(t))+1}(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(t){return Math.max(0,-Wu(Math.abs(t)))}(o))||(r.precision=i-2*("%"===r.type))}return tl(r)}function al(t){var e=t.domain;return t.ticks=function(t){var n=e();return _s(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return ol(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),o=0,a=i.length-1,s=i[o],u=i[a];return u<s&&(r=s,s=u,u=r,r=o,o=a,a=r),(r=ws(s,u,n))>0?r=ws(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=ws(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(u/r)*r,e(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(u*r)/r,e(i)),t},t}function sl(){var t=Gu(Nu,Nu);return t.copy=function(){return Uu(t,sl())},Ms.apply(t,arguments),al(t)}function ul(t,e){var n,r=0,i=(t=t.slice()).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 ll(t){return Math.log(t)}function cl(t){return Math.exp(t)}function fl(t){return-Math.log(-t)}function hl(t){return-Math.exp(-t)}function dl(t){return isFinite(t)?+("1e"+t):t<0?0:t}function pl(t){return function(e){return-t(-e)}}function gl(t){var e,n,r=t(ll,cl),i=r.domain,o=10;function a(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(o),n=function(t){return 10===t?dl:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(o),i()[0]<0?(e=pl(e),n=pl(n),t(fl,hl)):t(ll,cl),r}return r.base=function(t){return arguments.length?(o=+t,a()):o},r.domain=function(t){return arguments.length?(i(t),a()):i()},r.ticks=function(t){var r,a=i(),s=a[0],u=a[a.length-1];(r=u<s)&&(h=s,s=u,u=h);var l,c,f,h=e(s),d=e(u),p=null==t?10:+t,g=[];if(!(o%1)&&d-h<p){if(h=Math.round(h)-1,d=Math.round(d)+1,s>0){for(;h<d;++h)for(c=1,l=n(h);c<o;++c)if(!((f=l*c)<s)){if(f>u)break;g.push(f)}}else for(;h<d;++h)for(c=o-1,l=n(h);c>=1;--c)if(!((f=l*c)<s)){if(f>u)break;g.push(f)}}else g=_s(h,d,Math.min(d-h,p)).map(n);return r?g.reverse():g},r.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=tl(i)),t===1/0)return i;null==t&&(t=10);var a=Math.max(1,o*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*o<o-.5&&(r*=o),r<=a?i(t):""}},r.nice=function(){return i(ul(i(),{floor:function(t){return n(Math.floor(e(t)))},ceil:function(t){return n(Math.ceil(e(t)))}}))},r}Qu=il({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),tl=Qu.format,el=Qu.formatPrefix;var ml=new Date,vl=new Date;function yl(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},i.round=function(t){var e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},i.range=function(n,r,o){var a,s=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<r);return s},i.filter=function(n){return yl((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return ml.setTime(+e),vl.setTime(+r),t(ml),t(vl),Math.floor(n(ml,vl))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var bl=yl((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));bl.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?yl((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):bl:null};var _l=yl((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),wl=yl((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),Ol=yl((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),xl=yl((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1}));function El(t){return yl((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var Sl=El(0),Tl=El(1),Ml=(El(2),El(3),El(4)),Cl=(El(5),El(6),yl((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}))),Dl=yl((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));Dl.every=function(t){return isFinite(t=Math.floor(t))&&t>0?yl((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var Pl=yl((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}));function Al(t){return yl((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var kl=Al(0),Ll=Al(1),Rl=(Al(2),Al(3),Al(4)),Il=(Al(5),Al(6),yl((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()})));function Nl(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 jl(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 Bl(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}Il.every=function(t){return isFinite(t=Math.floor(t))&&t>0?yl((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var Vl,Hl,Ul={"-":"",_:" ",0:"0"},Fl=/^\s*\d+/,Gl=/^%/,zl=/[\\^$*+?|[\]().{}]/g;function Wl(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 Yl(t){return t.replace(zl,"\\$&")}function ql(t){return new RegExp("^(?:"+t.map(Yl).join("|")+")","i")}function Zl(t){for(var e={},n=-1,r=t.length;++n<r;)e[t[n].toLowerCase()]=n;return e}function Xl(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function Kl(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function $l(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function Jl(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Ql(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function tc(t,e,n){var r=Fl.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function ec(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function nc(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 rc(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function ic(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function oc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ac(t,e,n){var r=Fl.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function sc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function uc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function lc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function cc(t,e,n){var r=Fl.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function fc(t,e,n){var r=Fl.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function hc(t,e,n){var r=Gl.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function dc(t,e,n){var r=Fl.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function pc(t,e,n){var r=Fl.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function gc(t,e){return Wl(t.getDate(),e,2)}function mc(t,e){return Wl(t.getHours(),e,2)}function vc(t,e){return Wl(t.getHours()%12||12,e,2)}function yc(t,e){return Wl(1+xl.count(Dl(t),t),e,3)}function bc(t,e){return Wl(t.getMilliseconds(),e,3)}function _c(t,e){return bc(t,e)+"000"}function wc(t,e){return Wl(t.getMonth()+1,e,2)}function Oc(t,e){return Wl(t.getMinutes(),e,2)}function xc(t,e){return Wl(t.getSeconds(),e,2)}function Ec(t){var e=t.getDay();return 0===e?7:e}function Sc(t,e){return Wl(Sl.count(Dl(t)-1,t),e,2)}function Tc(t,e){var n=t.getDay();return t=n>=4||0===n?Ml(t):Ml.ceil(t),Wl(Ml.count(Dl(t),t)+(4===Dl(t).getDay()),e,2)}function Mc(t){return t.getDay()}function Cc(t,e){return Wl(Tl.count(Dl(t)-1,t),e,2)}function Dc(t,e){return Wl(t.getFullYear()%100,e,2)}function Pc(t,e){return Wl(t.getFullYear()%1e4,e,4)}function Ac(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Wl(e/60|0,"0",2)+Wl(e%60,"0",2)}function kc(t,e){return Wl(t.getUTCDate(),e,2)}function Lc(t,e){return Wl(t.getUTCHours(),e,2)}function Rc(t,e){return Wl(t.getUTCHours()%12||12,e,2)}function Ic(t,e){return Wl(1+Pl.count(Il(t),t),e,3)}function Nc(t,e){return Wl(t.getUTCMilliseconds(),e,3)}function jc(t,e){return Nc(t,e)+"000"}function Bc(t,e){return Wl(t.getUTCMonth()+1,e,2)}function Vc(t,e){return Wl(t.getUTCMinutes(),e,2)}function Hc(t,e){return Wl(t.getUTCSeconds(),e,2)}function Uc(t){var e=t.getUTCDay();return 0===e?7:e}function Fc(t,e){return Wl(kl.count(Il(t)-1,t),e,2)}function Gc(t,e){var n=t.getUTCDay();return t=n>=4||0===n?Rl(t):Rl.ceil(t),Wl(Rl.count(Il(t),t)+(4===Il(t).getUTCDay()),e,2)}function zc(t){return t.getUTCDay()}function Wc(t,e){return Wl(Ll.count(Il(t)-1,t),e,2)}function Yc(t,e){return Wl(t.getUTCFullYear()%100,e,2)}function qc(t,e){return Wl(t.getUTCFullYear()%1e4,e,4)}function Zc(){return"+0000"}function Xc(){return"%"}function Kc(t){return+t}function $c(t){return Math.floor(+t/1e3)}!function(t){Vl=function(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=ql(i),c=Zl(i),f=ql(o),h=Zl(o),d=ql(a),p=Zl(a),g=ql(s),m=Zl(s),v=ql(u),y=Zl(u),b={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:gc,e:gc,f:_c,H:mc,I:vc,j:yc,L:bc,m:wc,M:Oc,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Kc,s:$c,S:xc,u:Ec,U:Sc,V:Tc,w:Mc,W:Cc,x:null,X:null,y:Dc,Y:Pc,Z:Ac,"%":Xc},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:kc,e:kc,f:jc,H:Lc,I:Rc,j:Ic,L:Nc,m:Bc,M:Vc,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Kc,s:$c,S:Hc,u:Uc,U:Fc,V:Gc,w:zc,W:Wc,x:null,X:null,y:Yc,Y:qc,Z:Zc,"%":Xc},w={a:function(t,e,n){var r=d.exec(e.slice(n));return r?(t.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=y[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=g.exec(e.slice(n));return r?(t.m=m[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return E(t,e,n,r)},d:oc,e:oc,f:fc,H:sc,I:sc,j:ac,L:cc,m:ic,M:uc,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c[r[0].toLowerCase()],n+r[0].length):-1},q:rc,Q:dc,s:pc,S:lc,u:Kl,U:$l,V:Jl,w:Xl,W:Ql,x:function(t,e,r){return E(t,n,e,r)},X:function(t,e,n){return E(t,r,e,n)},y:ec,Y:tc,Z:nc,"%":hc};function O(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Ul[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=Bl(1900,void 0,1);if(E(o,t,n+="",0)!=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?(i=(r=jl(Bl(o.y,0,1))).getUTCDay(),r=i>4||0===i?Ll.ceil(r):Ll(r),r=Pl.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=Nl(Bl(o.y,0,1))).getDay(),r=i>4||0===i?Tl.ceil(r):Tl(r),r=xl.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?jl(Bl(o.y,0,1)).getUTCDay():Nl(Bl(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,jl(o)):Nl(o)}}function E(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=w[i in Ul?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return(b.x=O(n,b),b.X=O(r,b),b.c=O(e,b),_.x=O(n,_),_.X=O(r,_),_.c=O(e,_),{format:function(t){var e=O(t+="",b);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+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=x(t+="",!0);return e.toString=function(){return t},e}})}(t),Hl=Vl.format,Vl.parse,Vl.utcFormat,Vl.utcParse}({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"]});function Jc(t){return new Date(t)}function Qc(t){return t instanceof Date?+t:+new Date(+t)}function tf(t,e,n,r,i,o,a,s,u){var l=Gu(Nu,Nu),c=l.invert,f=l.domain,h=u(".%L"),d=u(":%S"),p=u("%I:%M"),g=u("%I %p"),m=u("%a %d"),v=u("%b %d"),y=u("%B"),b=u("%Y"),_=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function w(s){return(a(s)<s?h:o(s)<s?d:i(s)<s?p:r(s)<s?g:e(s)<s?n(s)<s?m:v:t(s)<s?y:b)(s)}function O(e,n,r,i){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(r-n)/e,a=hs((function(t){return t[2]})).right(_,o);a===_.length?(i=Os(n/31536e6,r/31536e6,e),e=t):a?(i=(a=_[o/_[a-1][2]<_[a][2]/o?a-1:a])[1],e=a[0]):(i=Math.max(Os(n,r,e),1),e=s)}return null==i?e:e.every(i)}return l.invert=function(t){return new Date(c(t))},l.domain=function(t){return arguments.length?f(Ds.call(t,Qc)):f().map(Jc)},l.ticks=function(t,e){var n,r=f(),i=r[0],o=r[r.length-1],a=o<i;return a&&(n=i,i=o,o=n),n=(n=O(t,i,o,e))?n.range(i,o+1):[],a?n.reverse():n},l.tickFormat=function(t,e){return null==e?w:u(e)},l.nice=function(t,e){var n=f();return(t=O(t,n[0],n[n.length-1],e))?f(ul(n,t)):l},l.copy=function(){return Uu(l,tf(t,e,n,r,i,o,a,s,u))},l}function ef(){return Ms.apply(tf(Dl,Cl,Sl,xl,Ol,wl,_l,bl,Hl).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var nf=Math.PI,rf=2*nf,of=rf-1e-6;function af(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function sf(){return new af}function uf(t){return function(){return t}}af.prototype=sf.prototype={constructor:af,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,f=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(f>1e-6)if(Math.abs(c*s-u*l)>1e-6&&i){var h=n-o,d=r-a,p=s*s+u*u,g=h*h+d*d,m=Math.sqrt(p),v=Math.sqrt(f),y=i*Math.tan((nf-Math.acos((p+f-g)/(2*m*v)))/2),b=y/v,_=y/m;Math.abs(b-1)>1e-6&&(this._+="L"+(t+b*l)+","+(e+b*c)),this._+="A"+i+","+i+",0,0,"+ +(c*h>l*d)+","+(this._x1=t+_*s)+","+(this._y1=e+_*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,o=!!o;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,f=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)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(f<0&&(f=f%rf+rf),f>of?this._+="A"+n+","+n+",0,1,"+c+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):f>1e-6&&(this._+="A"+n+","+n+",0,"+ +(f>=nf)+","+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 lf=Math.abs,cf=Math.atan2,ff=Math.cos,hf=Math.max,df=Math.min,pf=Math.sin,gf=Math.sqrt,mf=Math.PI,vf=mf/2,yf=2*mf;function bf(t){return t>1?0:t<-1?mf:Math.acos(t)}function _f(t){return t>=1?vf:t<=-1?-vf:Math.asin(t)}function wf(t){return t.innerRadius}function Of(t){return t.outerRadius}function xf(t){return t.startAngle}function Ef(t){return t.endAngle}function Sf(t){return t&&t.padAngle}function Tf(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,f=s-o,h=f*u-c*l;if(!(h*h<1e-12))return[t+(h=(c*(e-o)-f*(t-i))/h)*u,e+h*l]}function Mf(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/gf(s*s+u*u),c=l*u,f=-l*s,h=t+c,d=e+f,p=n+c,g=r+f,m=(h+p)/2,v=(d+g)/2,y=p-h,b=g-d,_=y*y+b*b,w=i-o,O=h*g-p*d,x=(b<0?-1:1)*gf(hf(0,w*w*_-O*O)),E=(O*b-y*x)/_,S=(-O*y-b*x)/_,T=(O*b+y*x)/_,M=(-O*y+b*x)/_,C=E-m,D=S-v,P=T-m,A=M-v;return C*C+D*D>P*P+A*A&&(E=T,S=M),{cx:E,cy:S,x01:-c,y01:-f,x11:E*(i/w-1),y11:S*(i/w-1)}}function Cf(){var t=wf,e=Of,n=uf(0),r=null,i=xf,o=Ef,a=Sf,s=null;function u(){var u,l,c=+t.apply(this,arguments),f=+e.apply(this,arguments),h=i.apply(this,arguments)-vf,d=o.apply(this,arguments)-vf,p=lf(d-h),g=d>h;if(s||(s=u=sf()),f<c&&(l=f,f=c,c=l),f>1e-12)if(p>yf-1e-12)s.moveTo(f*ff(h),f*pf(h)),s.arc(0,0,f,h,d,!g),c>1e-12&&(s.moveTo(c*ff(d),c*pf(d)),s.arc(0,0,c,d,h,g));else{var m,v,y=h,b=d,_=h,w=d,O=p,x=p,E=a.apply(this,arguments)/2,S=E>1e-12&&(r?+r.apply(this,arguments):gf(c*c+f*f)),T=df(lf(f-c)/2,+n.apply(this,arguments)),M=T,C=T;if(S>1e-12){var D=_f(S/c*pf(E)),P=_f(S/f*pf(E));(O-=2*D)>1e-12?(_+=D*=g?1:-1,w-=D):(O=0,_=w=(h+d)/2),(x-=2*P)>1e-12?(y+=P*=g?1:-1,b-=P):(x=0,y=b=(h+d)/2)}var A=f*ff(y),k=f*pf(y),L=c*ff(w),R=c*pf(w);if(T>1e-12){var I,N=f*ff(b),j=f*pf(b),B=c*ff(_),V=c*pf(_);if(p<mf&&(I=Tf(A,k,B,V,N,j,L,R))){var H=A-I[0],U=k-I[1],F=N-I[0],G=j-I[1],z=1/pf(bf((H*F+U*G)/(gf(H*H+U*U)*gf(F*F+G*G)))/2),W=gf(I[0]*I[0]+I[1]*I[1]);M=df(T,(c-W)/(z-1)),C=df(T,(f-W)/(z+1))}}x>1e-12?C>1e-12?(m=Mf(B,V,A,k,f,C,g),v=Mf(N,j,L,R,f,C,g),s.moveTo(m.cx+m.x01,m.cy+m.y01),C<T?s.arc(m.cx,m.cy,C,cf(m.y01,m.x01),cf(v.y01,v.x01),!g):(s.arc(m.cx,m.cy,C,cf(m.y01,m.x01),cf(m.y11,m.x11),!g),s.arc(0,0,f,cf(m.cy+m.y11,m.cx+m.x11),cf(v.cy+v.y11,v.cx+v.x11),!g),s.arc(v.cx,v.cy,C,cf(v.y11,v.x11),cf(v.y01,v.x01),!g))):(s.moveTo(A,k),s.arc(0,0,f,y,b,!g)):s.moveTo(A,k),c>1e-12&&O>1e-12?M>1e-12?(m=Mf(L,R,N,j,c,-M,g),v=Mf(A,k,B,V,c,-M,g),s.lineTo(m.cx+m.x01,m.cy+m.y01),M<T?s.arc(m.cx,m.cy,M,cf(m.y01,m.x01),cf(v.y01,v.x01),!g):(s.arc(m.cx,m.cy,M,cf(m.y01,m.x01),cf(m.y11,m.x11),!g),s.arc(0,0,c,cf(m.cy+m.y11,m.cx+m.x11),cf(v.cy+v.y11,v.cx+v.x11),g),s.arc(v.cx,v.cy,M,cf(v.y11,v.x11),cf(v.y01,v.x01),!g))):s.arc(0,0,c,w,_,g):s.lineTo(L,R)}else s.moveTo(0,0);if(s.closePath(),u)return s=null,u+""||null}return u.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-mf/2;return[ff(r)*n,pf(r)*n]},u.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),u):t},u.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:uf(+t),u):e},u.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),u):n},u.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:uf(+t),u):r},u.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:uf(+t),u):i},u.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:uf(+t),u):o},u.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:uf(+t),u):a},u.context=function(t){return arguments.length?(s=null==t?null:t,u):s},u}function Df(t){this._context=t}function Pf(t){return new Df(t)}function Af(t){return t[0]}function kf(t){return t[1]}function Lf(){var t=Af,e=kf,n=uf(!0),r=null,i=Pf,o=null;function a(a){var s,u,l,c=a.length,f=!1;for(null==r&&(o=i(l=sf())),s=0;s<=c;++s)!(s<c&&n(u=a[s],s,a))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(u,s,a),+e(u,s,a));if(l)return o=null,l+""||null}return a.x=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),a):t},a.y=function(t){return arguments.length?(e="function"==typeof t?t:uf(+t),a):e},a.defined=function(t){return arguments.length?(n="function"==typeof t?t:uf(!!t),a):n},a.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),a):i},a.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),a):r},a}function Rf(){var t=Af,e=null,n=uf(0),r=kf,i=uf(!0),o=null,a=Pf,s=null;function u(u){var l,c,f,h,d,p=u.length,g=!1,m=new Array(p),v=new Array(p);for(null==o&&(s=a(d=sf())),l=0;l<=p;++l){if(!(l<p&&i(h=u[l],l,u))===g)if(g=!g)c=l,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=l-1;f>=c;--f)s.point(m[f],v[f]);s.lineEnd(),s.areaEnd()}g&&(m[l]=+t(h,l,u),v[l]=+n(h,l,u),s.point(e?+e(h,l,u):m[l],r?+r(h,l,u):v[l]))}if(d)return s=null,d+""||null}function l(){return Lf().defined(i).curve(a).context(o)}return u.x=function(n){return arguments.length?(t="function"==typeof n?n:uf(+n),e=null,u):t},u.x0=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),u):t},u.x1=function(t){return arguments.length?(e=null==t?null:"function"==typeof t?t:uf(+t),u):e},u.y=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),r=null,u):n},u.y0=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),u):n},u.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:uf(+t),u):r},u.lineX0=u.lineY0=function(){return l().x(t).y(n)},u.lineY1=function(){return l().x(t).y(r)},u.lineX1=function(){return l().x(e).y(n)},u.defined=function(t){return arguments.length?(i="function"==typeof t?t:uf(!!t),u):i},u.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),u):a},u.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),u):o},u}function If(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function Nf(t){return t}Df.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)}}};var jf=Vf(Pf);function Bf(t){this._curve=t}function Vf(t){function e(e){return new Bf(t(e))}return e._curve=t,e}function Hf(){return t=Lf().curve(jf),e=t.curve,t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(Vf(t)):e()._curve},t;var t,e}Bf.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 Uf=Array.prototype.slice;function Ff(){}function Gf(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 zf(t){this._context=t}function Wf(t){return new zf(t)}function Yf(t){this._context=t}function qf(t){return new Yf(t)}function Zf(t){this._context=t}function Xf(t){return new Zf(t)}function Kf(t,e){this._basis=new zf(t),this._beta=e}zf.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:Gf(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Yf.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Zf.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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Kf.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)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++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 $f=function t(e){function n(t){return 1===e?new zf(t):new Kf(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function Jf(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 Qf(t,e){this._context=t,this._k=(1-e)/6}Qf.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:Jf(this,this._x1,this._y1)}(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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var th=function t(e){function n(t){return new Qf(t,e)}return n.tension=function(e){return t(+e)},n}(0);function eh(t,e){this._context=t,this._k=(1-e)/6}eh.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var nh=function t(e){function n(t){return new eh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function rh(t,e){this._context=t,this._k=(1-e)/6}rh.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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var ih=function t(e){function n(t){return new rh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function oh(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>1e-12){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>1e-12){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 ah(t,e){this._context=t,this._alpha=e}ah.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)}(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:oh(this,t,e)}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 sh=function t(e){function n(t){return e?new ah(t,e):new Qf(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function uh(t,e){this._context=t,this._alpha=e}uh.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:oh(this,t,e)}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 lh=function t(e){function n(t){return e?new uh(t,e):new eh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function ch(t,e){this._context=t,this._alpha=e}ch.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:oh(this,t,e)}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 fh=function t(e){function n(t){return e?new ch(t,e):new rh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function hh(t){this._context=t}function dh(t){return new hh(t)}function ph(t){return t<0?-1:1}function gh(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(ph(o)+ph(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function mh(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function vh(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 yh(t){this._context=t}function bh(t){this._context=new _h(t)}function _h(t){this._context=t}function wh(t){return new yh(t)}function Oh(t){return new bh(t)}function xh(t){this._context=t}function Eh(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]}function Sh(t){return new xh(t)}function Th(t,e){this._context=t,this._t=e}function Mh(t){return new Th(t,.5)}function Ch(t){return new Th(t,0)}function Dh(t){return new Th(t,1)}function Ph(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]}function Ah(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function kh(t,e){return t[e]}hh.prototype={areaStart:Ff,areaEnd:Ff,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))}},yh.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:vh(this,this._t0,mh(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+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,vh(this,mh(this,n=gh(this,t,e)),n);break;default:vh(this,this._t0,n=gh(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(bh.prototype=Object.create(yh.prototype)).point=function(t,e){yh.prototype.point.call(this,e,t)},_h.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)}},xh.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=Eh(t),i=Eh(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)}},Th.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)}}this._x=t,this._y=e}};var Lh=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=da.getProperty(e,"data").groupMapsTo,o=da.getProperty(e,"axes");return t&&(n=n.filter((function(e){return t.includes(e.group)}))),o&&Object.keys(o).forEach((function(t){var e=o[t].mapsTo,r=o[t].scaleType;if(r!==I.LINEAR&&r!==I.LOG||(n=n.map((function(t){var n;return T(T({},t),((n={})[e]=null===t[e]?t[e]:Number(t[e]),n))}))),e&&o[t].domain)if(r===I.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=ft.items.status.ACTIVE,n=this.getDataGroups(t),r=this.getOptions().data.groupMapsTo;return this.getAllDataFromDomain(t).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(da.clone(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),e},t.prototype.getDataGroups=function(t){return da.getProperty(this.getOptions(),"data","loading")?[]:t?this.get("dataGroups").filter((function(e){return t.includes(e.name)})):this.get("dataGroups")},t.prototype.getActiveDataGroups=function(t){var e=ft.items.status.ACTIVE;return this.getDataGroups(t).filter((function(t){return t.status===e}))},t.prototype.getDataGroupNames=function(t){return this.getDataGroups(t).map((function(t){return t.name}))},t.prototype.getActiveDataGroupNames=function(t){return this.getActiveDataGroups(t).map((function(t){return t.name}))},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.getDataValuesGroupedByKeys=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getDisplayData(t),o=us(i,(function(t){return t[e.services.cartesianScales.getDomainIdentifier(t)]})).keys(),a=this.services.cartesianScales.domainAxisPosition,s=n.axes[a].scaleType;s===I.TIME?o.sort((function(t,e){return new Date(t)-new Date(e)})):s!==I.LOG&&s!==I.LINEAR||o.sort((function(t,e){return t-e}));var u=this.getDataGroupNames();return o.map((function(t){var n={sharedStackKey:t};return u.forEach((function(o){var a=i.find((function(n){var i=e.services.cartesianScales.getDomainIdentifier(n);return n[r]===o&&n[i].toString()===t})),s=e.services.cartesianScales.getRangeIdentifier(n);n[o]=a?a[s]: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=this.getOptions().data.groupMapsTo,a=this.getDataGroupNames(i),s=this.getDataValuesGroupedByKeys(i);if(n){var u=da.fromPairs(s.map((function(t){return[t.sharedStackKey,0]})));s.forEach((function(t){a.forEach((function(e){u[t.sharedStackKey]+=t[e]}))})),s.forEach((function(t){a.forEach((function(e){u[t.sharedStackKey]?t[e]=t[e]/u[t.sharedStackKey]*100:t[e]=0}))}))}return function(){var t=uf([]),e=Ah,n=Ph,r=kh;function i(i){var o,a,s=t.apply(this,arguments),u=i.length,l=s.length,c=new Array(l);for(o=0;o<l;++o){for(var f,h=s[o],d=c[o]=new Array(u),p=0;p<u;++p)d[p]=f=[0,+r(i[p],h,p,i)],f.data=i[p];d.key=h}for(o=0,a=e(c);o<l;++o)c[a[o]].index=o;return n(c,a),c}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:uf(Uf.call(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:uf(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?Ah:"function"==typeof t?t:uf(Uf.call(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?Ph:t,i):n},i}().keys(a)(s).map((function(t,e){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(n){var r=t[n];return r[o]=a[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();da.updateLegendAdditionalItems(e,t),this.set({options:da.merge(e,t)})},t.prototype.update=function(t){void 0===t&&(t=!0),this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(tt.Model.UPDATE,{animate:t}))},t.prototype.toggleDataLabel=function(t){var e=ft.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(tt.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=da.getProperty(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=da.getProperty(this.colorScale,t);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.isUserProvidedColorScaleValid=function(){var t=da.getProperty(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=da.getProperty(t,"label");if(null===a){var s=da.getProperty(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.getTabularData=function(t){return Array.isArray(t)?t:this.transformToTabularData(t)},t.prototype.sanitize=function(t){return t=this.getTabularData(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=ft.items.status,r=n.ACTIVE,i=n.DISABLED,o=this.getOptions(),a=us(t,(function(t){return t[e]})).keys();o.data.selectedGroups.length&&(o.data.selectedGroups.every((function(t){return a.includes(t)}))||(o.data.selectedGroups=[]));var s=function(t){return!o.data.selectedGroups.length||o.data.selectedGroups.includes(t)?r:i};return a.map((function(t){return{name:t,status:s(t)}}))},t.prototype.setCustomColorScale=function(){var t=this;if(this.isUserProvidedColorScaleValid()){var e=this.getOptions(),n=da.getProperty(e,"color","scale");Object.keys(n).forEach((function(e){t.allDataGroups.includes(e)||console.warn('"'+e+'" does not exist in data groups.')})),this.allDataGroups.filter((function(t){return n[t]})).forEach((function(e){return t.colorScale[e]=n[e]}))}},t.prototype.setColorClassNames=function(){var t=da.getProperty(this.getOptions(),"color","pairing"),e=da.getProperty(t,"numberOfVariants");(!e||e<this.allDataGroups.length)&&(e=this.allDataGroups.length);var n=da.getProperty(t,"option"),r=e>5?14:e;n=n<=lt.pairingOptions[r+"-color"]?n:1;var i=this.allDataGroups.map((function(t,e){return r+"-"+n+"-"+(e%14+1)}));this.colorClassNames=ks().range(i).domain(this.allDataGroups)},t}(),Rh=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}(),Ih={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 "},Nh=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){void 0===e&&(e=null);for(var n=0,r=this.__entries__;n<r.length;n+=1){var i=r[n];t.call(e,i[1],i[0])}},Object.defineProperties(e.prototype,n),e}()}(),jh="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,Bh="undefined"!=typeof global&&global.Math===Math?global:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),Vh="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(Bh):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)},Hh=["top","right","bottom","left","width","height","size","weight"],Uh="undefined"!=typeof MutationObserver,Fh=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t,e){var n=!1,r=!1,i=0;function o(){n&&(n=!1,t()),r&&s()}function a(){Vh(o)}function s(){var t=Date.now();if(n){if(t-i<2)return;r=!0}else n=!0,r=!1,setTimeout(a,e);i=t}return s}(this.refresh.bind(this),20)};Fh.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},Fh.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},Fh.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},Fh.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},Fh.prototype.connect_=function(){jh&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),Uh?(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)},Fh.prototype.disconnect_=function(){jh&&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)},Fh.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e=""),Hh.some((function(t){return!!~e.indexOf(t)}))&&this.refresh()},Fh.getInstance=function(){return this.instance_||(this.instance_=new Fh),this.instance_},Fh.instance_=null;var Gh=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},zh=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||Bh},Wh=$h(0,0,0,0);function Yh(t){return parseFloat(t)||0}function qh(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return e.reduce((function(e,n){return e+Yh(t["border-"+n+"-width"])}),0)}function Zh(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return Wh;var r=zh(t).getComputedStyle(t),i=function(t){for(var e={},n=0,r=["top","right","bottom","left"];n<r.length;n+=1){var i=r[n],o=t["padding-"+i];e[i]=Yh(o)}return e}(r),o=i.left+i.right,a=i.top+i.bottom,s=Yh(r.width),u=Yh(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=qh(r,"left","right")+o),Math.round(u+a)!==n&&(u-=qh(r,"top","bottom")+a)),!function(t){return t===zh(t).document.documentElement}(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 $h(i.left,i.top,s,u)}var Xh="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof zh(t).SVGGraphicsElement}:function(t){return t instanceof zh(t).SVGElement&&"function"==typeof t.getBBox};function Kh(t){return jh?Xh(t)?function(t){var e=t.getBBox();return $h(0,0,e.width,e.height)}(t):Zh(t):Wh}function $h(t,e,n,r){return{x:t,y:e,width:n,height:r}}var Jh=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=$h(0,0,0,0),this.target=t};Jh.prototype.isActive=function(){var t=Kh(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},Jh.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var Qh=function(t,e){var n=function(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 Gh(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}(e);Gh(this,{target:t,contentRect:n})},td=function(t,e,n){if(this.activeObservations_=[],this.observations_=new Nh,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n};td.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 zh(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new Jh(t)),this.controller_.addObserver(this),this.controller_.refresh())}},td.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 zh(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))}},td.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},td.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},td.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new Qh(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},td.prototype.clearActive=function(){this.activeObservations_.splice(0)},td.prototype.hasActive=function(){return this.activeObservations_.length>0};var ed="undefined"!=typeof WeakMap?new WeakMap:new Nh,nd=function(t){if(!(this instanceof nd))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=Fh.getInstance(),n=new td(t,e,this);ed.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){nd.prototype[t]=function(){return(e=ed.get(this))[t].apply(e,arguments);var e}}));var rd=void 0!==Bh.ResizeObserver?Bh.ResizeObserver:nd,id=xa((function(t){!function(e){var n=function(){return{escape:function(t){return t.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1")},parseExtension:t,mimeType:function(e){var n=t(e).toLowerCase();return(r="application/font-woff",{woff:r,woff2:r,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml"})[n]||"";var r},dataAsUrl:function(t,e){return"data:"+e+";base64,"+t},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){for(var n=window.atob(t.toDataURL().split(",")[1]),r=n.length,i=new Uint8Array(r),o=0;o<r;o++)i[o]=n.charCodeAt(o);e(new Blob([i],{type:"image/png"}))}))}(t)},resolveUrl:function(t,e){var n=document.implementation.createHTMLDocument(),r=n.createElement("base");n.head.appendChild(r);var i=n.createElement("a");return n.body.appendChild(i),r.href=e,i.href=t,i.href},getAndEncode:function(t){s.impl.options.cacheBust&&(t+=(/\?/.test(t)?"&":"?")+(new Date).getTime());return new Promise((function(e){var n,r=new XMLHttpRequest;if(r.onreadystatechange=function(){if(4!==r.readyState)return;if(200!==r.status)return void(n?e(n):o("cannot fetch resource: "+t+", status: "+r.status));var i=new FileReader;i.onloadend=function(){var t=i.result.split(/,/)[1];e(t)},i.readAsDataURL(r.response)},r.ontimeout=function(){n?e(n):o("timeout of 30000ms occured while fetching resource: "+t)},r.responseType="blob",r.timeout=3e4,r.open("GET",t,!0),r.send(),s.impl.options.imagePlaceholder){var i=s.impl.options.imagePlaceholder.split(/,/);i&&i[1]&&(n=i[1])}function o(t){console.error(t),e("")}}))},uid:function(){var t=0;return 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){for(var e=[],n=t.length,r=0;r<n;r++)e.push(t[r]);return e},escapeXhtml:function(t){return t.replace(/#/g,"%23").replace(/\n/g,"%0A")},makeImage:function(t){return new Promise((function(e,n){var r=new Image;r.onload=function(){e(r)},r.onerror=n,r.src=t}))},width:function(t){var n=e(t,"border-left-width"),r=e(t,"border-right-width");return t.scrollWidth+n+r},height:function(t){var n=e(t,"border-top-width"),r=e(t,"border-bottom-width");return t.scrollHeight+n+r}};function t(t){var e=/\.([^\.\/]*?)$/g.exec(t);return e?e[1]:""}function e(t,e){var n=window.getComputedStyle(t).getPropertyValue(e);return parseFloat(n.replace("px",""))}}(),r=function(){var t=/url\(['"]?([^'"]+?)['"]?\)/g;return{inlineAll:function(t,n,o){return function(){return!e(t)}()?Promise.resolve(t):Promise.resolve(t).then(r).then((function(e){var r=Promise.resolve(t);return e.forEach((function(t){r=r.then((function(e){return i(e,t,n,o)}))})),r}))},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(t){return n.dataAsUrl(t,n.mimeType(e))})).then((function(r){return t.replace(function(t){return new RegExp("(url\\(['\"]?)("+n.escape(t)+")(['\"]?\\))","g")}(e),"$1"+r+"$3")}))}}(),i=function(){return{resolveAll:function(){return t().then((function(t){return Promise.all(t.map((function(t){return t.resolve()})))})).then((function(t){return t.join("\n")}))},impl:{readAll:t}};function t(){return Promise.resolve(n.asArray(document.styleSheets)).then((function(t){var e=[];return t.forEach((function(t){try{n.asArray(t.cssRules||[]).forEach(e.push.bind(e))}catch(e){console.log("Error while reading CSS rules from "+t.href,e.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")}}}}}(),o=function(){return{inlineAll:function e(i){return i instanceof Element?function(t){var e=t.style.getPropertyValue("background");return e?r.inlineAll(e).then((function(e){t.style.setProperty("background",e,t.style.getPropertyPriority("background"))})).then((function(){return t})):Promise.resolve(t)}(i).then((function(){return i instanceof HTMLImageElement?t(i).inline():Promise.all(n.asArray(i.childNodes).map((function(t){return e(t)})))})):Promise.resolve(i)},impl:{newImage:t}};function t(t){return{inline:function(e){return n.isDataUrl(t.src)?Promise.resolve():Promise.resolve(t.src).then(e||n.getAndEncode).then((function(e){return n.dataAsUrl(e,n.mimeType(t.src))})).then((function(e){return new Promise((function(n,r){t.onload=n,t.onerror=r,t.src=e}))}))}}}}(),a={imagePlaceholder:void 0,cacheBust:!1},s={toSvg:u,toPng:function(t,e){return l(t,e||{}).then((function(t){return t.toDataURL()}))},toJpeg:function(t,e){return l(t,e=e||{}).then((function(t){return t.toDataURL("image/jpeg",e.quality||1)}))},toBlob:function(t,e){return l(t,e||{}).then(n.canvasToBlob)},toPixelData:function(t,e){return l(t,e||{}).then((function(e){return e.getContext("2d").getImageData(0,0,n.width(t),n.height(t)).data}))},impl:{fontFaces:i,images:o,util:n,inliner:r,options:{}}};function u(t,e){return function(t){void 0===t.imagePlaceholder?s.impl.options.imagePlaceholder=a.imagePlaceholder:s.impl.options.imagePlaceholder=t.imagePlaceholder;void 0===t.cacheBust?s.impl.options.cacheBust=a.cacheBust:s.impl.options.cacheBust=t.cacheBust}(e=e||{}),Promise.resolve(t).then((function(t){return function t(e,r,i){return i||!r||r(e)?Promise.resolve(e).then((function(t){return t instanceof HTMLCanvasElement?n.makeImage(t.toDataURL()):t.cloneNode(!1)})).then((function(t){return o(e,t,r)})).then((function(t){return function(t,e){return e instanceof Element?Promise.resolve().then(r).then(i).then(o).then(a).then((function(){return e})):e;function r(){var r,i;r=window.getComputedStyle(t),i=e.style,r.cssText?i.cssText=r.cssText:function(t,e){n.asArray(t).forEach((function(n){e.setProperty(n,t.getPropertyValue(n),t.getPropertyPriority(n))}))}(r,i)}function i(){[":before",":after"].forEach((function(r){!function(r){var i=window.getComputedStyle(t,r),o=i.getPropertyValue("content");if(""===o||"none"===o)return;var a=n.uid();e.className=e.className+" "+a;var s=document.createElement("style");s.appendChild(function(t,e,r){var i="."+t+":"+e,o=r.cssText?function(t){var e=t.getPropertyValue("content");return t.cssText+" content: "+e+";"}(r):function(t){return n.asArray(t).map((function(e){return e+": "+t.getPropertyValue(e)+(t.getPropertyPriority(e)?" !important":"")})).join("; ")+";"}(r);return document.createTextNode(i+"{"+o+"}")}(a,r,i)),e.appendChild(s)}(r)}))}function o(){t instanceof HTMLTextAreaElement&&(e.innerHTML=t.value),t instanceof HTMLInputElement&&e.setAttribute("value",t.value)}function a(){e instanceof SVGElement&&(e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e instanceof SVGRectElement&&["width","height"].forEach((function(t){var n=e.getAttribute(t);n&&e.style.setProperty(t,n)})))}}(e,t)})):Promise.resolve();function o(e,r,i){var o=e.childNodes;return 0===o.length?Promise.resolve(r):a(r,n.asArray(o),i).then((function(){return r}));function a(e,n,r){var i=Promise.resolve();return n.forEach((function(n){i=i.then((function(){return t(n,r)})).then((function(t){t&&e.appendChild(t)}))})),i}}}(t,e.filter,!0)})).then(c).then(f).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]}));return t})).then((function(r){return function(t,e,r){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){return'<foreignObject x="0" y="0" width="100%" height="100%">'+t+"</foreignObject>"})).then((function(t){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+e+'" height="'+r+'">'+t+"</svg>"})).then((function(t){return"data:image/svg+xml;charset=utf-8,"+t}))}(r,e.width||n.width(t),e.height||n.height(t))}))}function l(t,e){return u(t,e).then(n.makeImage).then(n.delay(100)).then((function(r){var i=function(t){var r=document.createElement("canvas");if(r.width=e.width||n.width(t),r.height=e.height||n.height(t),e.bgcolor){var i=r.getContext("2d");i.fillStyle=e.bgcolor,i.fillRect(0,0,r.width,r.height)}return r}(t);return i.getContext("2d").drawImage(r,0,0),i}))}function c(t){return i.resolveAll().then((function(e){var n=document.createElement("style");return t.appendChild(n),n.appendChild(document.createTextNode(e)),t}))}function f(t){return o.inlineAll(t).then((function(){return t}))}t.exports=s}()})),od=function(t){function e(e,n){return t.call(this,e,n)||this}return n(e,t),e.getHTMLElementSize=function(t){return{width:t.clientWidth,height:t.clientHeight}},e.getSVGElementSize=function(t,e){t.attr||(t=va(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{r={width:(n=t.node().getBBox()).width,height:n.height}}catch(t){}try{o={width:(i=t.node().getBoundingClientRect()).width,height:i.height}}catch(t){}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{s({width:da.getProperty(t.node(),"width","baseVal","value"),height:da.getProperty(t.node(),"height","baseVal","value")})}catch(t){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],o=(r=r[1].split("."))[0]):i=(r=e.split("."))[0],t.append(i).attr("id",o).attr("class",r.slice(1).join(" "))}return n},e.prototype.init=function(){this.styleHolderElement(),this.addMainContainer(),this.verifyCSSStylesBeingApplied(),this.model.getOptions().resizable&&this.addResizeListener(),this.addHolderListeners()},e.prototype.addMainContainer=function(){var t=this.model.getOptions(),e=da.getProperty(t,"style","prefix"),n=va(this.getHolder()).append("div").classed(Ih.prefix+"--"+e+"--chart-wrapper",!0).style("height","100%").style("width","100%");n.append("g").attr("class","DONT_STYLE_ME_css_styles_verifier"),this.mainContainer=n.node()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder();va(this.getHolder()).classed(Ih.prefix+"--chart-holder",!0);var e=this.model.getOptions(),n=e.width,r=e.height;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.exportToJPG=function(){var t=this;id.toJpeg(this.getMainContainer(),{quality:1,filter:function(t){return!t.classList||!t.classList.contains("bx--cc--toolbar")}}).then((function(e){t.services.files.downloadImage(e,"myChart.jpg")}))},e.prototype.exportToPNG=function(){var t=this;id.toPng(this.getMainContainer(),{quality:1,filter:function(t){return!t.classList||!t.classList.contains("bx--cc--toolbar")}}).then((function(e){t.services.files.downloadImage(e,"myChart.png")})).catch((function(t){console.error("oops, something went wrong!",t)}))},e.prototype.toggleFullscreen=function(){var t=this.getHolder(),e=va(t),n=e.classed("fullscreen");e.classed("fullscreen",!n),n?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.verifyCSSStylesBeingApplied=function(){var t=this;setTimeout((function(){var e=va(t.mainContainer).select("g.DONT_STYLE_ME_css_styles_verifier").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(va(this.mainContainer),{useBBox:!0}).height,n=va(this.mainContainer).attr("class"),r=va(this.mainContainer).selectAll("."+n+" > svg"),i=0;r.nodes().forEach((function(t){i+=Number(e.getSVGElementSize(va(t),{useBBox:!0}).height)})),i<=t?va(this.mainContainer).attr("height",i):va(this.mainContainer).attr("height","100%")}},e.prototype.getMainContainer=function(){return this.mainContainer},e.prototype.addHolderListeners=function(){var t=this,e=this.getHolder();e&&va(e).on("mouseover",(function(){t.services.events.dispatchEvent(tt.Chart.MOUSEOVER)})).on("mouseout",(function(){t.services.events.dispatchEvent(tt.Chart.MOUSEOUT)}))},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=da.debounce((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(tt.Chart.RESIZE))}),12.5);new rd(i).observe(e)}},e}(Rh),ad=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(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")).initEvent(t,!1,!0),this.documentFragment.dispatchEvent(n)},e}(Rh),sd=function(t){function e(e,n){return t.call(this,e,n)||this}return n(e,t),e.prototype.downloadCSV=function(t,e,n){var r=document.createElement("a");navigator.msSaveBlob?navigator.msSaveBlob(new Blob([t],{type:"text/csv;encoding:utf-8"}),e):URL&&"download"in r?(r.href=URL.createObjectURL(new Blob([t],{type:"text/csv;encoding:utf-8"})),r.setAttribute("download",e),document.body.appendChild(r),r.click(),document.body.removeChild(r)):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}(Rh),ud={value:function(){}};function ld(){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 cd(r)}function cd(t){this._=t}function fd(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 hd(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function dd(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=ud,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}cd.prototype=ld.prototype={constructor:cd,on:function(t,e){var n,r=this._,i=fd(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o<a;)if(n=(t=i[o]).type)r[n]=dd(r[n],t.name,e);else if(null==e)for(n in r)r[n]=dd(r[n],t.name,null);return this}for(;++o<a;)if((n=(t=i[o]).type)&&(n=hd(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new cd(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(o=0,n=(r=this._[t]).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 pd,gd,md=Object.freeze({__proto__:null,dispatch:ld}),vd=0,yd=0,bd=0,_d=0,wd=0,Od=0,xd="object"==typeof performance&&performance.now?performance:Date,Ed="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Sd(){return wd||(Ed(Td),wd=xd.now()+Od)}function Td(){wd=0}function Md(){this._call=this._time=this._next=null}function Cd(t,e,n){var r=new Md;return r.restart(t,e,n),r}function Dd(){wd=(_d=xd.now())+Od,vd=yd=0;try{!function(){Sd(),++vd;for(var t,e=pd;e;)(t=wd-e._time)>=0&&e._call.call(null,t),e=e._next;--vd}()}finally{vd=0,function(){var t,e,n=pd,r=1/0;for(;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:pd=e);gd=t,Ad(r)}(),wd=0}}function Pd(){var t=xd.now(),e=t-_d;e>1e3&&(Od-=e,_d=t)}function Ad(t){vd||(yd&&(yd=clearTimeout(yd)),t-wd>24?(t<1/0&&(yd=setTimeout(Dd,t-xd.now()-Od)),bd&&(bd=clearInterval(bd))):(bd||(_d=xd.now(),bd=setInterval(Pd,1e3)),vd=1,Ed(Dd)))}function kd(t,e,n){var r=new Md;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}Md.prototype=Cd.prototype={constructor:Md,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?Sd():+n)+(null==e?0:+e),this._next||gd===this||(gd?gd._next=this:pd=this,gd=this),this._call=t,this._time=n,Ad()},stop:function(){this._call&&(this._call=null,this._time=1/0,Ad())}};var Ld=ld("start","end","cancel","interrupt"),Rd=[];function Id(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(u){var l,c,f,h;if(1!==n.state)return s();for(l in i)if((h=i[l]).name===n.name){if(3===h.state)return kd(o);4===h.state?(h.state=6,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[l]):+l<e&&(h.state=6,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[l])}if(kd((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(u))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,r=new Array(f=n.tween.length),l=0,c=-1;l<f;++l)(h=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=h);r.length=c+1}}function a(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=6,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=Cd((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:r,group:i,on:Ld,tween:Rd,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Nd(t,e){var n=Bd(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function jd(t,e){var n=Bd(t,e);if(n.state>3)throw new Error("too late; already running");return n}function Bd(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Vd(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>2&&n.state<5,n.state=6,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}}function Hd(t,e){var n,r;return function(){var i=jd(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function Ud(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=jd(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}}function Fd(t,e,n){var r=t._id;return t.each((function(){var t=jd(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return Bd(t,r).value[e]}}function Gd(t,e){var n;return("number"==typeof e?vu:e instanceof Ks?du:(n=Ks(e))?(e=n,du):wu)(t,e)}function zd(t){return function(){this.removeAttribute(t)}}function Wd(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Yd(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 qd(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 Zd(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+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function Xd(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+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Kd(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function $d(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Jd(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&$d(t,i)),n}return i._value=e,i}function Qd(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Kd(t,i)),n}return i._value=e,i}function tp(t,e){return function(){Nd(this,t).delay=+e.apply(this,arguments)}}function ep(t,e){return e=+e,function(){Nd(this,t).delay=e}}function np(t,e){return function(){jd(this,t).duration=+e.apply(this,arguments)}}function rp(t,e){return e=+e,function(){jd(this,t).duration=e}}function ip(t,e){if("function"!=typeof e)throw new Error;return function(){jd(this,t).ease=e}}function op(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?Nd:jd;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var ap=ma.prototype.constructor;function sp(t){return function(){this.style.removeProperty(t)}}function up(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function lp(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&up(t,o,n)),r}return o._value=e,o}function cp(t){return function(e){this.textContent=t.call(this,e)}}function fp(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&cp(r)),e}return r._value=t,r}var hp=0;function dp(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function pp(t){return ma().transition(t)}function gp(){return++hp}var mp=ma.prototype;dp.prototype=pp.prototype={constructor:dp,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=po(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,f=o[a]=new Array(c),h=0;h<c;++h)(s=l[h])&&(u=t.call(s,s.__data__,h,l))&&("__data__"in s&&(u.__data__=s.__data__),f[h]=u,Id(f[h],e,n,h,f,Bd(s,n)));return new dp(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=mo(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,f=0;f<c;++f)if(u=l[f]){for(var h,d=t.call(u,u.__data__,f,l),p=Bd(u,n),g=0,m=d.length;g<m;++g)(h=d[g])&&Id(h,e,n,g,d,p);o.push(d),a.push(u)}return new dp(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=vo(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 dp(r,this._parents,this._name,this._id)},merge: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],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new dp(a,this._parents,this._name,this._id)},selection:function(){return new ap(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=gp(),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=Bd(a,e);Id(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new dp(r,this._parents,t,n)},call:mp.call,nodes:mp.nodes,node:mp.node,size:mp.size,empty:mp.empty,each:mp.each,on:function(t,e){var n=this._id;return arguments.length<2?Bd(this.node(),n).on.on(t):this.each(op(n,t,e))},attr:function(t,e){var n=uo(t),r="transform"===n?Lu:Gd;return this.attrTween(t,"function"==typeof e?(n.local?Xd:Zd)(n,r,Fd(this,"attr."+t,e)):null==e?(n.local?Wd:zd)(n):(n.local?qd:Yd)(n,r,e))},attrTween: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=uo(t);return this.tween(n,(r.local?Jd:Qd)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?ku:Gd;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=Lo(this,t),a=(this.style.removeProperty(t),Lo(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,sp(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=Lo(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=Lo(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,Fd(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=jd(this,t),l=u.on,c=null==u.value[a]?o||(o=sp(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=Lo(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween: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,lp(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(Fd(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween: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,fp(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=Bd(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?Hd:Ud)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?tp:ep)(e,t)):Bd(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?np:rp)(e,t)):Bd(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(ip(e,t)):Bd(this.node(),e).ease},end: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=jd(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e}))}))}};var vp={time:null,delay:0,duration:250,ease:it};function yp(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return vp.time=Sd(),vp;return n}ma.prototype.interrupt=function(t){return this.each((function(){Vd(this,t)}))},ma.prototype.transition=function(t){var e,n;t instanceof dp?(e=t._id,t=t._name):(e=gp(),(n=vp).time=Sd(),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])&&Id(a,t,e,l,s,n||yp(a,e));return new dp(r,this._parents,t,e)};var bp=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return n(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener(tt.Model.UPDATE,(function(){t.pendingTransitions={}}))},e.prototype.getTransition=function(t,e){var n=this;if(!1===this.model.getOptions().animations||!1===e)return this.getInstantTransition(t);var r=pp(t).duration(da.getProperty(yt,t,"duration")||yt.default.duration);return this.pendingTransitions[r._id]=r,r.on("end interrupt cancel",(function(){delete n.pendingTransitions[r._id]})),r},e.prototype.getInstantTransition=function(t){var e=this,n=pp(t).duration(0);return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),n},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(Rh),_p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(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){return(100*Math.abs(t[1])/Math.abs(t[0]-t[1])).toFixed(2)+"%"},e.getStops=function(t,n){var r=[{offset:"0%",color:n,opacity:"0.6"},{offset:"80%",color:n,opacity:"0"}];return t[0]<0&&t[1]>0&&(r=[{offset:"0%",color:n,opacity:"0.6"},{offset:e.getOffsetRatio(t),color:n,opacity:"0"},{offset:"100%",color:n,opacity:"0.6"}]),r},e}(Rh);function wp(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 Op(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 xp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=Op(e);return n.setDate(n.getDate()+r),n}function Ep(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t).getTime(),r=Op(e);return new Date(n+r)}function Sp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,36e5*n)}function Tp(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());return e.setSeconds(0,0),6e4*n+e.getTime()%6e4}function Mp(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t);return e.setHours(0,0,0,0),e}function Cp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Mp(t),r=Mp(e),i=n.getTime()-Tp(n),o=r.getTime()-Tp(r);return Math.round((i-o)/864e5)}function Dp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,6e4*n)}function Pp(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(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 Ap(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=Op(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=Pp(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function kp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,1e3*n)}function Lp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ap(t,12*n)}function Rp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function Ip(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t);return!isNaN(e)}function Np(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function jp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e);return n.getFullYear()-r.getFullYear()}function Bp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e);return n.getTime()-r.getTime()}function Vp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/6e4;return n>0?Math.floor(n):Math.ceil(n)}function Hp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/1e3;return n>0?Math.floor(n):Math.ceil(n)}var Up={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 Fp(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth;return t.formats[r]||t.formats[t.defaultWidth]}}var Gp={date:Fp({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Fp({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Fp({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},zp={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Wp(t){return function(e,n){var r,i=n||{};if("formatting"===(i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,a=i.width?String(i.width):o;r=t.formattingValues[a]||t.formattingValues[o]}else{var s=t.defaultWidth,u=i.width?String(i.width):t.defaultWidth;r=t.values[u]||t.values[s]}return r[t.argumentCallback?t.argumentCallback(e):e]}}function Yp(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)?function(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}(c,(function(t){return t.test(r)})):function(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(l.length)}}}var qp,Zp={code:"en-US",formatDistance:function(t,e,n){var r;return n=n||{},r="string"==typeof Up[t]?Up[t]:1===e?Up[t].one:Up[t].other.replace("{{count}}",e),n.addSuffix?n.comparison>0?"in "+r:r+" ago":r},formatLong:Gp,formatRelative:function(t,e,n,r){return zp[t]},localize:{ordinalNumber:function(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"},era:Wp({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Wp({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:Wp({values:{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"]},defaultWidth:"wide"}),day:Wp({values:{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"]},defaultWidth:"wide"}),dayPeriod:Wp({values:{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"}},defaultWidth:"wide",formattingValues:{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"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(qp={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t,e){var n=String(t),r=e||{},i=n.match(qp.matchPattern);if(!i)return null;var o=i[0],a=n.match(qp.parsePattern);if(!a)return null;var s=qp.valueCallback?qp.valueCallback(a[0]):a[0];return{value:s=r.valueCallback?r.valueCallback(s):s,rest:n.slice(o.length)}}),era:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Yp({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),day:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),dayPeriod:Yp({matchPatterns:{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},defaultMatchWidth:"any",parsePatterns:{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}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};function Xp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,-n)}function Kp(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}var $p=function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return Kp("yy"===e?r%100:r,e.length)},Jp=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):Kp(n+1,2)},Qp=function(t,e){return Kp(t.getUTCDate(),e.length)},tg=function(t,e){return Kp(t.getUTCHours()%12||12,e.length)},eg=function(t,e){return Kp(t.getUTCHours(),e.length)},ng=function(t,e){return Kp(t.getUTCMinutes(),e.length)},rg=function(t,e){return Kp(t.getUTCSeconds(),e.length)},ig=function(t,e){var n=e.length,r=t.getUTCMilliseconds();return Kp(Math.floor(r*Math.pow(10,n-3)),e.length)};function og(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=1,n=wp(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 ag(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=og(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=og(o);return e.getTime()>=i.getTime()?n+1:e.getTime()>=a.getTime()?n:n-1}function sg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=ag(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=og(n);return r}function ug(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:Op(i),a=null==n.weekStartsOn?o:Op(n.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=wp(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 lg(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=wp(t,e),r=n.getUTCFullYear(),i=e||{},o=i.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:Op(a),u=null==i.firstWeekContainsDate?s:Op(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=ug(l,e),f=new Date(0);f.setUTCFullYear(r,0,u),f.setUTCHours(0,0,0,0);var h=ug(f,e);return n.getTime()>=c.getTime()?r+1:n.getTime()>=h.getTime()?r:r-1}function cg(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:Op(i),a=null==n.firstWeekContainsDate?o:Op(n.firstWeekContainsDate),s=lg(t,e),u=new Date(0);u.setUTCFullYear(s,0,a),u.setUTCHours(0,0,0,0);var l=ug(u,e);return l}var fg="midnight",hg="noon",dg="morning",pg="afternoon",gg="evening",mg="night",vg={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 $p(t,e)},Y:function(t,e,n,r){var i=lg(t,r),o=i>0?i:1-i;return"YY"===e?Kp(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):Kp(o,e.length)},R:function(t,e){return Kp(ag(t),e.length)},u:function(t,e){return Kp(t.getUTCFullYear(),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 Kp(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 Kp(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 Jp(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 Kp(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=function(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=wp(t),r=ug(n,e).getTime()-cg(n,e).getTime();return Math.round(r/6048e5)+1}(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):Kp(i,e.length)},I:function(t,e,n){var r=function(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t),n=og(e).getTime()-sg(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):Kp(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):Qp(t,e)},D:function(t,e,n){var r=function(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(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/864e5)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):Kp(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 Kp(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 Kp(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 Kp(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()/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?hg:0===i?fg: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?gg:i>=12?pg:i>=4?dg:mg,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 tg(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):eg(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):Kp(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):Kp(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):ng(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):rg(t,e)},S:function(t,e){return ig(t,e)},X:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();if(0===i)return"Z";switch(e){case"X":return bg(i);case"XXXX":case"XX":return _g(i);case"XXXXX":case"XXX":default:return _g(i,":")}},x:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return bg(i);case"xxxx":case"xx":return _g(i);case"xxxxx":case"xxx":default:return _g(i,":")}},O:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+yg(i,":");case"OOOO":default:return"GMT"+_g(i,":")}},z:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+yg(i,":");case"zzzz":default:return"GMT"+_g(i,":")}},t:function(t,e,n,r){var i=r._originalDate||t;return Kp(Math.floor(i.getTime()/1e3),e.length)},T:function(t,e,n,r){return Kp((r._originalDate||t).getTime(),e.length)}};function yg(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+Kp(o,2)}function bg(t,e){return t%60==0?(t>0?"-":"+")+Kp(Math.abs(t)/60,2):_g(t,e)}function _g(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t);return r+Kp(Math.floor(i/60),2)+n+Kp(i%60,2)}function wg(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 Og(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"})}}var xg={p:Og,P:function(t,e){var n,r=t.match(/(P+)(p+)?/),i=r[1],o=r[2];if(!o)return wg(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"})}return n.replace("{{date}}",wg(i,e)).replace("{{time}}",Og(o,e))}},Eg=["D","DD"],Sg=["YY","YYYY"];function Tg(t){return-1!==Eg.indexOf(t)}function Mg(t){return-1!==Sg.indexOf(t)}function Cg(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 Dg=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Pg=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Ag=/^'([^]*?)'?$/,kg=/''/g,Lg=/[a-zA-Z]/;function Rg(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||Zp,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:Op(a),u=null==i.firstWeekContainsDate?s:Op(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:Op(l),f=null==i.weekStartsOn?c:Op(i.weekStartsOn);if(!(f>=0&&f<=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 h=wp(t);if(!Ip(h))throw new RangeError("Invalid time value");var d=Tp(h),p=Xp(h,d),g={firstWeekContainsDate:u,weekStartsOn:f,locale:o,_originalDate:h},m=r.match(Pg).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,xg[e])(t,o.formatLong,g):t})).join("").match(Dg).map((function(t){if("''"===t)return"'";var e=t[0];if("'"===e)return Ig(t);var n=vg[e];if(n)return!i.useAdditionalWeekYearTokens&&Mg(t)&&Cg(t),!i.useAdditionalDayOfYearTokens&&Tg(t)&&Cg(t),n(p,t,o.localize,g);if(e.match(Lg))throw new RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return t})).join("");return m}function Ig(t){return t.match(Ag)[1].replace(kg,"'")}function Ng(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return xp(t,-n)}function jg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Sp(t,-n)}function Bg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Dp(t,-n)}function Vg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ap(t,-n)}function Hg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return kp(t,-n)}function Ug(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Lp(t,-n)}var Fg=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 n(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=da.getProperty(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=da.getProperty(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 da.getProperty(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).title;return e||(t===A.BOTTOM||t===A.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;this.determineAxisDuality(),this.findDomainAndRangeAxes(),this.determineOrientation(),Object.keys(A).map((function(t){return A[t]})).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!==A.LEFT&&this.rangeAxisPosition!==A.RIGHT||this.domainAxisPosition!==A.BOTTOM&&this.domainAxisPosition!==A.TOP?this.orientation=R.HORIZONTAL:this.orientation=R.VERTICAL},e.prototype.isDualAxes=function(){return this.dualAxes},e.prototype.determineAxisDuality=function(){var t,e,n,r,i=this.model.getOptions(),o=da.getProperty(i,"axes");((null===(t=o[A.LEFT])||void 0===t?void 0:t.correspondingDatasets)&&o[A.RIGHT]||(null===(e=o[A.RIGHT])||void 0===e?void 0:e.correspondingDatasets)&&o[A.LEFT]||(null===(n=o[A.TOP])||void 0===n?void 0:n.correspondingDatasets)&&o[A.BOTTOM]||(null===(r=o[A.BOTTOM])||void 0===r?void 0:r.correspondingDatasets)&&o[A.TOP])&&(this.dualAxes=!0)},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=[A.BOTTOM,A.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[A.LEFT,A.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=da.getProperty(a,"axes")[n].mapsTo,u=null!==da.getProperty(r,s)?r[s]:r;switch(e){case I.LABELS:o=t(u)+t.step()/2;break;case I.TIME:o=t(new Date(u));break;default:o=t(u)}return o},e.prototype.getBoundedScaledValues=function(t,e){var n=this.model.getOptions().bounds,r=this.scales[this.rangeAxisPosition],i=this.model.getOptions(),o=da.getProperty(i,"axes")[this.rangeAxisPosition].mapsTo,a=void 0!==t[o]?t[o]:t;return[r(null!==da.getProperty(t,n.upperBoundMapsTo)?t[n.upperBoundMapsTo]:a),r(null!==da.getProperty(t,n.lowerBoundMapsTo)?t[n.lowerBoundMapsTo]:a)]},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 da.getProperty(e,"axes",this.getDomainAxisPosition({datum:t}),"mapsTo")},e.prototype.getRangeIdentifier=function(t){var e=this.model.getOptions();return da.getProperty(e,"axes",this.getRangeAxisPosition({datum:t}),"mapsTo")},e.prototype.extendsDomain=function(t,e){var n=this.model.getOptions(),r=da.getProperty(n,"axes",t);return r.scaleType===I.TIME?function(t,e){var n=new Date(t[0]),r=new Date(t[1]);if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(jp(n,r));n.setFullYear(n.getFullYear()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Ug(n,e),Lp(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(Np(n,r));n.setMonth(n.getMonth()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Vg(n,e),Ap(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(Cp(n,r));n.setDate(n.getDate()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Ng(n,e),xp(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/36e5;return n>0?Math.floor(n):Math.ceil(n)}(r,n)>1)return[jg(n,e),Sp(r,e)];if(Vp(r,n)>30)return[Bg(n,30*e),Dp(r,30*e)];if(Vp(r,n)>1)return[Bg(n,e),Dp(r,e)];if(Hp(r,n)>15)return[Hg(n,15*e),kp(r,15*e)];if(Hp(r,n)>1)return[Hg(n,e),kp(r,e)];return[n,r]}(e,da.getProperty(n,"timeScale","addSpaceOnEdges")):function(t,e,n){var r=t[0],i=t[1],o=(i-r)*e,a=i<=0&&i+o>0?0:i+o,s=r>=0&&r-o<0?0:r-o;if(n===I.LOG&&s<=0){if(r<=0)throw Error("Data must have values greater than 0 if log scale type is used.");s=r}return[s,a]}(e,at.paddingRatio,r.scaleType)},e.prototype.findVerticalAxesPositions=function(){var t=this.model.getOptions(),e=da.getProperty(t,"axes"),n=this.isDualAxes();return null===da.getProperty(e,A.LEFT)&&null!==da.getProperty(e,A.RIGHT)||!0===da.getProperty(e,A.RIGHT,"main")||n&&da.getProperty(e,A.LEFT,"correspondingDatasets")?{primary:A.RIGHT,secondary:A.LEFT}:{primary:A.LEFT,secondary:A.RIGHT}},e.prototype.findHorizontalAxesPositions=function(){var t=this.model.getOptions(),e=da.getProperty(t,"axes"),n=this.isDualAxes();return null===da.getProperty(e,A.BOTTOM)&&null!==da.getProperty(e,A.TOP)||!0===da.getProperty(e,A.TOP,"main")||n&&da.getProperty(e,A.BOTTOM,"correspondingDatasets")?{primary:A.TOP,secondary:A.BOTTOM}:{primary:A.BOTTOM,secondary:A.TOP}},e.prototype.findDomainAndRangeAxesPositions=function(t,e){var n=this.model.getOptions(),r=da.getProperty(n,"axes",t.primary),i=da.getProperty(n,"axes",e.primary),o=r.scaleType||I.LINEAR,a=i.scaleType||I.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!==I.LABELS&&a!==I.TIME&&o===I.LABELS||o===I.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=da.getProperty(e,"axes",t),r=da.getProperty(e,"bounds"),i=n.includeZero,o=da.getProperty(n,"scaleType")||I.LINEAR;if(this.model.isDataEmpty())return[];var a,s,u=this.model.getDisplayData(),l=n.extendLinearDomainBy,c=n.mapsTo,f=n.percentage,h=n.thresholds,d=at.ratio,p=d.reference,g=d.compareTo;if(n.domain)return o===I.LABELS?n.domain:(o===I.TIME&&(n.domain=n.domain.map((function(t){return void 0===t.getTime?new Date(t):t}))),this.extendsDomain(t,n.domain));if(f)return[0,100];if(n&&o===I.LABELS)return us(u,(function(t){return t[c]})).keys();var m=this.model.getDataGroupNames();if(o===I.LABELS_RATIO)return u.map((function(t){return t[p]+"/"+t[g]}));if(o===I.TIME)s=u.map((function(t){return+new Date(t[c])}));else if(r&&e.axes)s=[],u.forEach((function(t){s.push(t[c]),t[r.upperBoundMapsTo]&&s.push(t[r.upperBoundMapsTo]),t[r.lowerBoundMapsTo]&&s.push(t[r.lowerBoundMapsTo])}));else if(!0===n.stacked&&m&&t===this.getRangeAxisPosition()){var v=e.data.groupMapsTo,y=this.model.getDataValuesGroupedByKeys(m),b=u.filter((function(t){return!m.includes(t[v])})),_=y.map((function(t){t.sharedStackKey;return Ts(function(t){var e=[];for(var n in t)e.push(t[n]);return e}(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}(t,["sharedStackKey"])))}));s=M(_,b.map((function(t){return t[c]})))}else s=[],u.forEach((function(t){var e=t[c];Array.isArray(e)&&2===e.length?(s.push(e[0]),s.push(e[1])):(l&&s.push(Math.max(t[c],t[l])),s.push(e))}));return o!==I.TIME&&o!==I.LOG&&i&&s.push(0),h&&h.length>0&&h.forEach((function(t){var e=da.getProperty(t,"value");null!==e&&s.push(e)})),a=gs(s),a=this.extendsDomain(t,a)},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=da.getProperty(e,"axes",t);if(!n)return null;var r,i=da.getProperty(n,"scaleType")||I.LINEAR;return this.scaleTypes[t]=i,(r=i===I.TIME?ef():i===I.LOG?function t(){var e=gl(Fu()).domain([1,10]);return e.copy=function(){return Uu(e,t()).base(e.base())},Ms.apply(e,arguments),e}().base(n.base||10):i===I.LABELS||i===I.LABELS_RATIO?Ls():sl()).domain(this.getScaleDomain(t)),r},e.prototype.getHighestDomainThreshold=function(){var t=da.getProperty(this.model.getOptions(),"axes"),e=this.getDomainAxisPosition(),n=t[e].thresholds;if(!n)return null;var r=this.getDomainScale(),i=n.sort((function(t,e){return e.value-t.value}))[0];return this.getScaleTypeByPosition(e)!==I.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=da.getProperty(this.model.getOptions(),"axes")[this.getRangeAxisPosition()].thresholds;if(!t)return null;var e=this.getRangeScale(),n=t.sort((function(t,e){return e.value-t.value}))[0];return{threshold:n,scaleValue:e(n.value)}},e}(Rh);var Gg=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:Pf,curveLinearClosed:dh,curveBasis:Wf,curveBasisClosed:qf,curveBasisOpen:Xf,curveBundle:$f,curveCardinal:th,curveCardinalClosed:nh,curveCardinalOpen:ih,curveCatmullRom:sh,curveCatmullRomClosed:lh,curveCatmullRomOpen:fh,curveMonotoneX:wh,curveMonotoneY:Oh,curveNatural:Sh,curveStep:Mh,curveStepAfter:Dh,curveStepBefore:Ch},e}return n(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}(Rh),zg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.isZoomBarEnabled=function(){if(!this.services.cartesianScales)return!1;if(!da.getProperty(this.model.getOptions(),"zoomBar","top","enabled"))return!1;this.services.cartesianScales.findDomainAndRangeAxes();var t=this.services.cartesianScales.getMainXAxisPosition(),e=da.getProperty(this.model.getOptions(),"axes",t,"scaleType");return t===A.BOTTOM&&e===I.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();return n.extendsDomain(r,gs(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(tt.ZoomDomain.CHANGE,{newDomain:t})},e.prototype.getZoomRatio=function(){return da.getProperty(this.model.getOptions(),"zoomBar","zoomRatio")},e.prototype.filterDataForRangeAxis=function(t,e){var n=this.model.get("zoomDomain"),r=Object.assign({stacked:!1},e),i=da.getProperty(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=bt.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 f=[r.invert(l),r.invert(c)];e[0].valueOf()===f[0].valueOf()&&e[1].valueOf()===f[1].valueOf()||this.handleDomainChange(f)}},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();return!(!t||!e)&&(t[1].valueOf()-t[0].valueOf())/(e[1].valueOf()-e[0].valueOf())<da.getProperty(this.model.getOptions(),"zoomBar","minZoomRatio")},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 da.getProperty(this.model.getOptions(),"zoomBar",t,"loading")},e.prototype.isZoomBarLocked=function(t){return da.getProperty(this.model.getOptions(),"zoomBar",t,"locked")},e}(Rh),Wg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.zoomIn=function(t,e,n){var r,i,o,a=n||st;t&&(r=t.x,i=t.y,o=2);var s=od.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(tt.CanvasZoom.CANVAS_ZOOM_IN,{element:va(t)})},e.prototype.zoomOut=function(t,e){var n=e||st;t.transition().duration(n.duration).ease(n.ease).attr("transform",""),this.services.events.dispatchEvent(tt.CanvasZoom.CANVAS_ZOOM_OUT)},e}(Rh),Yg=function(){function t(t,e,n){if(this.renderType=C.HTML,this.configs={},this.model=t,this.services=e,n&&(this.configs=n,this.configs.id)){var r=da.getProperty(this.model.getOptions(),"style","prefix");this.id=r+"--"+this.configs.id}this.parent||this.setParent(va(this.services.domUtils.getMainContainer()))}return t.prototype.init=function(){},t.prototype.render=function(t){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=da.getProperty(this.model.getOptions(),"style","prefix");this.parent.classed(Ih.prefix+"--"+n+"--"+this.type,!0).attr("id",this.id),e&&e.classed(Ih.prefix+"--"+n+"--"+this.type,!1).attr("id",this.id)}},t.prototype.getParent=function(){return this.parent},t.prototype.getComponentContainer=function(t){if(void 0===t&&(t={withinChartClip:!1}),this.type){var e=da.getProperty(this.model.getOptions(),"style","prefix"),n=this.id?"#"+this.id:"",r=od.appendOrSelect(this.parent,(this.renderType===C.SVG?"svg":"div")+n+"."+Ih.prefix+"--"+e+"--"+this.type);if(t.withinChartClip){var i=this.model.get("chartClipId");if(i){var o=va("#"+i).select("rect");0!==o.size()&&parseFloat(o.attr("height"))>0&&r.attr("clip-path","url(#"+i+")")}}return r.attr("width","100%").attr("height","100%")}return this.parent},t.prototype.getOptions=function(){return this.configs.options?da.merge({},this.model.getOptions(),this.configs.options):this.model.getOptions()},t}(),qg=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e.renderType=C.HTML,e}return n(e,t),e.prototype.render=function(){var t=this,e=this.getOptions(),n=da.getProperty(e,"legend"),i=da.getProperty(n,"alignment"),o=da.getProperty(e,"legend","orientation"),a=this.model.getDataGroups(),s=ft.items.status.DISABLED,u=a.some((function(t){return t.status===s})),l=da.getProperty(n,"order"),c=this.getComponentContainer().classed("center-aligned",i===j.CENTER).classed(o,!0).classed("has-deactivated-items",u).attr("role",r.GROUP).attr("data-name","legend-items");l&&(a=this.sortDataGroups(a,l));var f=c.selectAll("div.legend-item").data(a,(function(t){return t.name})),h=f.enter().append("div").attr("class","legend-item");h.merge(c.selectAll("div.legend-item")).classed("active",(function(t,e){return t.status===ft.items.status.ACTIVE}));var d=da.getProperty(this.getOptions(),"legend","clickable");c.classed("clickable",d);var p=ft.checkbox.radius,g=h.append("div").classed("checkbox",!0);g.merge(f.select("div.checkbox")).attr("role",r.CHECKBOX).attr("tabindex",d?0:-1).attr("aria-label",(function(t){return t.name})).attr("aria-checked",(function(t){return t.status===ft.items.status.ACTIVE})).attr("width",2*p).attr("height",2*p).attr("rx",1).attr("ry",1).attr("class",(function(e,n){return t.model.getColorClassName({classNameTypes:[P.BACKGROUND],dataGroupName:e.name,originalClassName:"checkbox"})})).style("background",(function(e){return e.status===ft.items.status.ACTIVE?t.model.getFillColor(e.name)||t.model.getStrokeColor(e.name):null})).classed("active",(function(t,e){return t.status===ft.items.status.ACTIVE}));g.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");var m=h.append("p").merge(f.select("p"));this.truncateLegendText(m);var v=da.getProperty(e,"legend","additionalItems");if(v&&a.length){var y=this,b=c.selectAll("div.additional-item").data(v);b.exit().remove();var _,w=b.enter().append("div").merge(b).classed("legend-item",!0).classed("additional",!0);w.selectAll("*").remove();var O=1;w.append("svg").classed("icon",!0).each((function(t,e){var n=va(this);_&&_==t.type?O++:(_=t.type,O=1),y.addAdditionalItem(n,t,O)}));var x=w.append("p").merge(w.select("p"));this.truncateLegendText(x)}f.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove(),d&&h.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;return t.slice(n).concat(t.slice(0,n))}return t},e.prototype.addAdditionalItem=function(t,e,n){var i=ft.area,o=i.width,a=i.height;if(e.type===Q.RADIUS?t.style("width",a+"px").style("height",a+"px"):t.style("width",o+"px").style("height",a+"px"),e.type===Q.RADIUS){var s=ft.radius,u=s.iconData,l=s.fill,c=s.stroke;t.attr("fill","none").selectAll("circle").data(u).enter().append("circle").classed("radius",!0).attr("role",r.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:l).style("stroke",e.stroke?e.stroke:c)}else if(e.type===Q.LINE){var f=ft.line;t.select("line.line").empty()&&t.append("line").classed("line-"+n,!0).attr("role",r.IMG).attr("aria-label","line").attr("x1",0).attr("y1",f.yPosition).attr("x2",o).attr("y2",f.yPosition).style("stroke",e.stroke?e.stroke:f.stroke).style("stroke-width",f.strokeWidth)}else if(e.type===Q.AREA)t.select("rect.area").empty()&&t.append("rect").classed("area-"+n,!0).attr("role",r.IMG).attr("aria-label","area").attr("width",o).attr("height",a).style("fill",n>3&&!e.fill?ft.area.fill:e.fill).style("stroke",e.stroke);else if(e.type===Q.SIZE){var h=ft.size;u=h.iconData,l=h.fill,c=h.stroke;t.attr("fill","none").attr("role",r.IMG).attr("aria-label","size").selectAll("rect").data(u).enter().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:l).style("stroke",e.stroke?e.stroke:c).style("stroke-width",1)}else if(e.type===Q.QUARTILE){u=ft.quartile.iconData;t.selectAll("rect").attr("role",r.IMG).attr("aria-label","quartile").data(u).enter().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===Q.ZOOM){var d=da.getProperty(as,"legend","zoom"),p=(u=d.iconData,d.color),g=t.attr("role",r.IMG).attr("aria-label","zoom").selectAll("g.icon").data(u).enter();g.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:p})),g.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:p}))}},e.prototype.truncateLegendText=function(t){var e=da.getProperty(this.getOptions(),"legend","truncation"),n=da.getProperty(e,"type"),r=da.getProperty(e,"threshold"),i=da.getProperty(e,"numCharacter");n!==L.NONE?t.html((function(t){return t.name.length>r?da.truncateLabel(t.name,n,i):t.name})):t.html((function(t){return t.name}))},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=da.getProperty(n,"legend"),i=da.getProperty(r,"truncation","threshold");e.selectAll("div.legend-item").on("mouseover",(function(){t.services.events.dispatchEvent(tt.Legend.ITEM_HOVER,{hoveredElement:va(this)});var e=va(this);e.select("div.checkbox").classed("hovered",!0);var n=e.datum();n.name.length>i&&t.services.events.dispatchEvent(tt.Tooltip.SHOW,{hoveredElement:e,content:n.name})})).on("mousemove",(function(){t.services.events.dispatchEvent(tt.Tooltip.MOVE)})).on("click",(function(){t.services.events.dispatchEvent(tt.Legend.ITEM_CLICK,{clickedElement:va(this)});var e=va(this).datum();t.model.toggleDataLabel(e.name)})).on("mouseout",(function(){var e=va(this);e.select("div.checkbox").classed("hovered",!1),t.services.events.dispatchEvent(tt.Tooltip.HIDE),t.services.events.dispatchEvent(tt.Legend.ITEM_MOUSEOUT,{hoveredElement:e})})),e.selectAll("div.legend-item div.checkbox").on("keyup",(function(e){!ia.key||"Enter"!==ia.key&&" "!==ia.key||(ia.preventDefault(),t.model.toggleDataLabel(e.name))})),e.selectAll("g.additional-item").on("mouseover",(function(){var e=va(this),n=e.datum();n.name.length>i&&t.services.events.dispatchEvent(tt.Tooltip.SHOW,{hoveredElement:e,content:n.name})}))},e}(Yg);function Zg(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Xg(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function Kg(t){return t.reduce((function(t,e){return Array.isArray(e)?t.push.apply(t,Xg(Kg(e))):t.push(e),t}),[])}function $g(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return Kg(e).reduce((function(t,e){return e(t)}),function(){return function t(){Zg(this,t)}}())}function Jg(t){return(Jg="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})(t)}function Qg(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function tm(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 em(t,e){return!e||"object"!==Jg(e)&&"function"!=typeof e?rm(t):e}function nm(t){return(nm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(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(t,e){return(im=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function om(t){return function(t){function e(t){var n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(Qg(this,e),(n=em(this,nm(e).call(this,t,r))).children=[],!t||t.nodeType!==Node.ELEMENT_NODE)throw new TypeError("DOM element should be given to initialize this widget.");return n.element=t,n.options=Object.assign(Object.create(n.constructor.options),r),n.constructor.components.set(n.element,rm(n)),n}var n,r,i;return function(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}}),e&&im(t,e)}(e,t),n=e,i=[{key:"create",value:function(t,e){return this.components.get(t)||new this(t,e)}}],(r=[{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}}])&&tm(n.prototype,r),i&&tm(n,i),e}(t)}function am(t){return(am="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})(t)}function sm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function um(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 lm(t,e){return!e||"object"!==am(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function cm(t){return(cm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function fm(t,e){return(fm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function hm(t){return function(t){function e(){return sm(this,e),lm(this,cm(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&fm(t,e)}(e,t),n=e,i=[{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.");e.nodeType===Node.ELEMENT_NODE&&e.matches(r.selectorInit)?this.create(e,n):Array.prototype.forEach.call(e.querySelectorAll(r.selectorInit),(function(e){return t.create(e,n)}))}}],(r=null)&&um(n.prototype,r),i&&um(n,i),e}(t)}function dm(t){return(dm="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})(t)}function pm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function gm(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 mm(t,e){return!e||"object"!==dm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function vm(t,e,n){return(vm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=ym(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(n):i.value}})(t,e,n||t)}function ym(t){return(ym=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function bm(t,e){return(bm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _m(t){return function(t){function e(){var t,n;pm(this,e);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return(n=mm(this,(t=ym(e)).call.apply(t,[this].concat(i)))).handles=new Set,n}var n,r,i;return function(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}}),e&&bm(t,e)}(e,t),n=e,(r=[{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)})),vm(ym(e.prototype),"release",this).call(this)}}])&&gm(n.prototype,r),i&&gm(n,i),e}(t)}function wm(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 Om(t){return(Om="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})(t)}function xm(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 Em(t,e){return!e||"object"!==Om(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Sm(t){return(Sm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Tm(t,e){return(Tm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Mm={true:"true",false:"false",mixed:"mixed"};$g(om,hm,_m);function Cm(t){return(Cm="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})(t)}function Dm(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function Pm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Am(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 km(t,e){return!e||"object"!==Cm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Lm(t){return(Lm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Rm(t,e){return(Rm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Im(t){return function(t){function e(){return Pm(this,e),km(this,Lm(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&Rm(t,e)}(e,t),n=e,(r=[{key:"_changeState",value:function(){throw new Error("_changeState() should be overriden 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,f=!c.dispatchEvent(l);if(f){if(a){var h=new Error("Changing state (".concat(JSON.stringify(s),") has been canceled."));h.canceled=!0,a(h)}}else{var d=[i,o].filter(Boolean);this._changeState.apply(this,Dm(d).concat([function(){c.dispatchEvent(new CustomEvent(t.options["eventAfter".concat(u)],{bubbles:!0,cancelable:!0,detail:o})),a&&a()}]))}}else a&&a(null,!0)}}])&&Am(n.prototype,r),i&&Am(n,i),e}(t)}function Nm(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 jm(t){return(jm="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})(t)}function Bm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Vm(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 Hm(t,e){return!e||"object"!==jm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Um(t){return(Um=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Fm(t,e){return(Fm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Gm=function(t){return Array.prototype.slice.call(t)};$g(om,hm,Im,_m);function zm(t){return(zm="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})(t)}function Wm(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 Ym(t,e){return!e||"object"!==zm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function qm(t){return(qm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Zm(t,e){return(Zm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Xm=function(t){return Array.prototype.slice.call(t)};$g(om,hm,Im,_m);function Km(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 $m(t){return($m="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})(t)}function Jm(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 tv(t,e){return!e||"object"!==$m(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function ev(t){return(ev=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function nv(t,e){return(nv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var rv=[Im,function(t){return function(t){function e(){return Jm(this,e),tv(this,ev(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&nv(t,e)}(e,t),n=e,(r=[{key:"show",value:function(t,e){t&&"function"!=typeof t||(e=t),this.changeState("shown",Km(t),e)}},{key:"hide",value:function(t,e){t&&"function"!=typeof t||(e=t),this.changeState("hidden",Km(t),e)}}])&&Qm(n.prototype,r),i&&Qm(n,i),e}(t)}];function iv(t){return(iv="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})(t)}function ov(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 av(t,e){return!e||"object"!==iv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function sv(t){return(sv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function uv(t,e){return(uv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var lv=[_m,function(t){return function(t){function e(t,n){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=av(this,sv(e).call(this,t,n));var i="onfocusin"in window,o=i?"focusin":"focus";return r.manage(wm(r.element.ownerDocument,o,(function(t){r.element.contains(t.target)||r.handleBlur(t)}),!i)),r}var n,r,i;return function(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}}),e&&uv(t,e)}(e,t),n=e,(r=[{key:"handleBlur",value:function(){throw new Error("Components inheriting TrackBlur mix-in must implement handleBlur() method.")}}])&&ov(n.prototype,r),i&&ov(n,i),e}(t)}],cv=function(){var t=[],e=!1;function n(){t.forEach((function(t){t()})),e=!1}function r(){e||(e=!0,window.requestAnimationFrame(n))}return{add:function(e){return t.length||window.addEventListener("resize",r),function(e){e&&t.indexOf(e)<0&&t.push(e)}(e),{release:function(){var n=t.indexOf(e);n>=0&&t.splice(n,1)}}}}}();function fv(t){return(fv="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})(t)}function hv(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 dv(t,e){return!e||"object"!==fv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function pv(t,e,n){return(pv="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=gv(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(n):i.value}})(t,e,n||t)}function gv(t){return(gv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function mv(t,e){return(mv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function vv(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var yv=function(t){function e(t,n){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var i=(r=dv(this,gv(e).call(this,t,n))).element.getAttribute(r.options.attribDirection);return r.options.direction||(r.options.direction=i||"bottom"),i||r.element.setAttribute(r.options.attribDirection,r.options.direction),r}var n,r,i;return function(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}}),e&&mv(t,e)}(e,t),n=e,(r=[{key:"handleBlur",value:function(t){if(this.element.classList.contains(this.options.classShown)){this.changeState("hidden",Km(t));var e=this.options,n=e.refNode,r=e.triggerNode;this.element.contains(t.relatedTarget)&&n&&t.target!==n&&HTMLElement.prototype.focus.call(r||n)}}},{key:"_getContainer",value:function(){return this.element.closest(this.options.selectorContainer)||this.element.ownerDocument.body}},{key:"_getPos",value:function(){var t=this.element,e=this.options,n=e.refNode,r=e.offset,i=e.direction;if(!n)throw new Error("Cannot find the refernce node for positioning floating menu.");return function(t){var e,n=t.menuSize,r=t.refPosition,i=t.offset,o=void 0===i?{}:i,a=t.direction,s=void 0===a?"bottom":a,u=t.scrollX,l=void 0===u?0:u,c=t.scrollY,f=void 0===c?0:c,h=r.left,d=void 0===h?0:h,p=r.top,g=void 0===p?0:p,m=r.right,v=void 0===m?0:m,y=r.bottom,b=void 0===y?0:y,_=n.width,w=n.height,O=o.top,x=void 0===O?0:O,E=o.left,S=void 0===E?0:E,T=(d+v)/2,M=(g+b)/2;return(e={},vv(e,"left",{left:d-_+l-S,top:M-w/2+f+x}),vv(e,"top",{left:T-_/2+l+S,top:g-w+f-x}),vv(e,"right",{left:v+l+S,top:M-w/2+f+x}),vv(e,"bottom",{left:T-_/2+l+S,top:b+f+x}),e)[s]}({menuSize:t.getBoundingClientRect(),refPosition:n.getBoundingClientRect(),offset:"function"!=typeof r?r:r(t,i,n),direction:i,scrollX:n.ownerDocument.defaultView.pageXOffset,scrollY:n.ownerDocument.defaultView.pageYOffset})}},{key:"_testStyles",value:function(){if(this.options.debugStyle){var t=this.element,e=t.ownerDocument.defaultView.getComputedStyle(t),n={position:"absolute",right:"auto",margin:0};Object.keys(n).forEach((function(t){("number"==typeof n[t]?parseFloat(n[t]):n[t])!==e.getPropertyValue(t)&&console.warn("Floating menu component expects ".concat(t,": ").concat(n[t]," style."))}))}}},{key:"_place",value:function(){var t=this.element,e=this._getPos(),n=e.left,r=e.top;t.style.left="".concat(n,"px"),t.style.top="".concat(r,"px"),this._testStyles()}},{key:"shouldStateBeChanged",value:function(t){return("shown"===t||"hidden"===t)&&t!==(this.element.classList.contains(this.options.classShown)?"shown":"hidden")}},{key:"_changeState",value:function(t,e,n){var r=this,i="shown"===t,o=this.options,a=o.refNode,s=o.classShown,u=o.classRefShown;if(!a)throw new TypeError("Cannot find the refernce node for changing the style.");this.element.classList.toggle(s,i),u&&a.classList.toggle(u,i),"shown"===t&&(this.hResize||(this.hResize=cv.add((function(){r._place()}))),this._getContainer().appendChild(this.element),this._place(),this.element.hasAttribute(this.options.attribAvoidFocusOnOpen)||(this.element.querySelector(this.options.selectorPrimaryFocus)||this.element).focus()),"hidden"===t&&this.hResize&&(this.hResize.release(),this.hResize=null),n()}},{key:"release",value:function(){this.hResize&&(this.hResize.release(),this.hResize=null),pv(gv(e.prototype),"release",this).call(this)}}])&&hv(n.prototype,r),i&&hv(n,i),e.options={selectorContainer:"[data-floating-menu-container]",selectorPrimaryFocus:"[data-floating-menu-primary-focus]",attribDirection:"data-floating-menu-direction",attribAvoidFocusOnOpen:"data-avoid-focus-on-open",classShown:"",classRefShown:"",eventBeforeShown:"floating-menu-beingshown",eventAfterShown:"floating-menu-shown",eventBeforeHidden:"floating-menu-beinghidden",eventAfterHidden:"floating-menu-hidden",refNode:null,offset:{left:0,top:0}},e.components=new WeakMap,e}($g(om,rv,lv));function bv(t){return(bv="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})(t)}function _v(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function wv(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 Ov(t,e){return!e||"object"!==bv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function xv(t){return(xv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Ev(t,e){return(Ev=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Sv(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var Tv=function(){var t;return Sv(t={},"top","bottom"),Sv(t,"bottom","top"),Sv(t,"left","left"),Sv(t,"right","right"),t}(),Mv=function(){var t;return Sv(t={},"top",-2),Sv(t,"bottom",-1),Sv(t,"left",-2),Sv(t,"right",-1),t}(),Cv=function(t,e,n){var r=Tv[e],i=Mv[e];r&&i||console.warn("Wrong floating menu direction:",e);var o=t.offsetWidth,a=t.offsetHeight,s=Dv.components.get(n);if(!s)throw new TypeError("Overflow menu instance cannot be found.");var u=t.classList.contains(s.options.classMenuFlip);return"top"===r||"bottom"===r?{left:(u?-1:1)*(o/2-n.offsetWidth/2),top:0}:"left"===r||"right"===r?{left:0,top:(u?-1:1)*(a/2-n.offsetHeight/2)}:void 0},Dv=function(t){function e(t,n){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=Ov(this,xv(e).call(this,t,n))).getCurrentNavigation=function(){var t=r.element.ownerDocument.activeElement;return t.nodeType===Node.ELEMENT_NODE&&t.matches(r.options.selectorItem)?t:null},r.navigate=function(t){for(var e=_v(r.element.ownerDocument.querySelectorAll(r.options.selectorItem)),n=r.getCurrentNavigation()||r.element.querySelector(r.options.selectorItemSelected),i=function(n){var r=Math.max(e.indexOf(n)+t,-1);return e[function(t,e){return t+(t>=0?0:e)}(function(t,e){return t-(t<e?0:e)}(r,e.length),e.length)]},o=i(n);o&&o!==n;o=i(o))if(!o.matches(r.options.selectorItemHidden)&&!o.parentNode.matches(r.options.selectorItemHidden)&&!o.matches(r.options.selectorItemSelected)){o.focus();break}},"button"!==r.element.getAttribute("role")&&(r.triggerNode=r.element.querySelector(r.options.selectorTrigger)),r.manage(wm(r.element.ownerDocument,"click",(function(t){r._handleDocumentClick(t),r.wasOpenBeforeClick=void 0}))),r.manage(wm(r.element.ownerDocument,"keydown",(function(t){r._handleKeyPress(t)}))),r.manage(wm(r.element,"mousedown",(function(){r.wasOpenBeforeClick=t.classList.contains(r.options.classShown)}))),r}var n,r,i;return function(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}}),e&&Ev(t,e)}(e,t),n=e,i=[{key:"options",get:function(){var t=Ih.prefix;return{selectorInit:"[data-overflow-menu]",selectorOptionMenu:".".concat(t,"--overflow-menu-options"),selectorTrigger:"button[aria-haspopup]",selectorItem:"\n .".concat(t,"--overflow-menu-options--open >\n .").concat(t,"--overflow-menu-options__option:not(.").concat(t,"--overflow-menu-options__option--disabled) >\n .").concat(t,"--overflow-menu-options__btn\n "),classShown:"".concat(t,"--overflow-menu--open"),classMenuShown:"".concat(t,"--overflow-menu-options--open"),classMenuFlip:"".concat(t,"--overflow-menu--flip"),objMenuOffset:Cv,objMenuOffsetFlip:Cv}}}],(r=[{key:"changeState",value:function(t,e,n){var r=this.triggerNode?"triggerNode":"element";if("hidden"===t?this[r].setAttribute("aria-expanded","false"):this[r].setAttribute("aria-expanded","true"),!this.optionMenu){var i=this.element.querySelector(this.options.selectorOptionMenu);if(!i)throw new Error("Cannot find the target menu.");this.optionMenu=yv.create(i,{refNode:this.element,classShown:this.options.classMenuShown,classRefShown:this.options.classShown,offset:this.options.objMenuOffset,triggerNode:this.triggerNode}),this.children.push(this.optionMenu)}this.optionMenu.element.classList.contains(this.options.classMenuFlip)&&(this.optionMenu.options.offset=this.options.objMenuOffsetFlip),this.optionMenu.changeState(t,Object.assign(e,{delegatorNode:this.element}),n)}},{key:"_handleDocumentClick",value:function(t){var e=this,n=this.element,r=this.optionMenu,i=this.wasOpenBeforeClick,o=this.triggerNode,a=n.contains(t.target),s=r&&r.element.contains(t.target),u=a&&!i?"shown":"hidden";a&&("A"===n.tagName&&t.preventDefault(),t.delegateTarget=n),s&&!Nm(t,this.options.selectorItem)||this.changeState(u,Km(t),(function(){"hidden"===u&&s&&e[o?"triggerNode":"element"].focus()}))}},{key:"_handleKeyPress",value:function(t){var e=this,n=t.which,r=this.element,i=this.optionMenu,o=this.options,a=this.triggerNode,s=i&&i.element.contains(t.target),u=this.element.classList.contains(this.options.classShown),l=a?"triggerNode":"element";switch(n){case 27:this.changeState("hidden",Km(t),(function(){s&&e[l].focus()}));break;case 13:case 32:if(!u&&this.element.ownerDocument.activeElement!==this.element)return;var c=r.contains(t.target),f=c&&!r.classList.contains(o.classShown)?"shown":"hidden";c&&(t.delegateTarget=r,t.preventDefault(),this.changeState(f,Km(t),(function(){"hidden"===f&&s&&e[l].focus()})));break;case 38:case 40:if(!u)return;t.preventDefault();var h={38:-1,40:1}[t.which];this.navigate(h)}}}])&&wv(n.prototype,r),i&&wv(n,i),e.components=new WeakMap,e}($g(om,hm,rv,_m)),Pv=function(){};"production"!==process.env.NODE_ENV&&(Pv=function(t,e,n){var r=arguments.length;n=new Array(r>2?r-2:0);for(var i=2;i<r;i++)n[i-2]=arguments[i];if(void 0===e)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(e.length<10||/^[s\W]*$/.test(e))throw new Error("The warning format should be able to uniquely identify this warning. Please, use a more descriptive format than: "+e);if(!t){var o=0,a="Warning: "+e.replace(/%s/g,(function(){return n[o++]}));"undefined"!=typeof console&&console.error(a);try{throw new Error(a)}catch(t){}}});var Av=Pv;function kv(t){return(kv="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})(t)}function Lv(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Rv(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 Iv(t,e){return!e||"object"!==kv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Nv(t){return(Nv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function jv(t,e){return(jv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Bv(t){return function(t){function e(){return Lv(this,e),Iv(this,Nv(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&jv(t,e)}(e,t),n=e,i=[{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 wm(e,i,(function(e){var i=Nm(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),""}}],(r=null)&&Rv(n.prototype,r),i&&Rv(n,i),e.forLazyInit=!0,e}(t)}function Vv(t){return(Vv="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})(t)}function Hv(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 Uv(t,e){return!e||"object"!==Vv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Fv(t){return(Fv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Gv(t,e){return(Gv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var zv=function(t){function e(t,n){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=Uv(this,Fv(e).call(this,t,n)))._handleFocusinListener=void 0,r._handleKeydownListener=void 0,r._handleFocusin=function(t){r.element.classList.contains(r.options.classVisible)&&!r.element.contains(t.target)&&r.options.selectorsFloatingMenus.every((function(e){return!Nm(t,e)}))&&r.element.querySelector(Ih.selectorTabbable).focus()},r._hookCloseActions(),r}var n,r,i;return function(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}}),e&&Gv(t,e)}(e,t),n=e,i=[{key:"options",get:function(){var t=Ih.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"],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"}}}],(r=[{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;if(this._handleFocusinListener&&(this._handleFocusinListener=this.unmanage(this._handleFocusinListener).release()),"shown"===t){var o="onfocusin"in this.element.ownerDocument.defaultView,a=o?"focusin":"focus";this._handleFocusinListener=this.manage(wm(this.element.ownerDocument,a,this._handleFocusin,!o))}"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(wm(this.element,"transitionend",(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(Ih.selectorTabbable);e.focus(),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&Av(e,"Modals need to contain a focusable element by either using "+"`".concat(i.options.selectorPrimaryFocus,"` or settings.selectorTabbable."))}n()})))}},{key:"_hookCloseActions",value:function(){var t=this;this.manage(wm(this.element,"click",(function(e){var n=Nm(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(wm(this.element.ownerDocument.body,"keydown",(function(e){27===e.which&&t.shouldStateBeChanged("hidden")&&(e.stopPropagation(),t.hide(e))})))}}])&&Hv(n.prototype,r),i&&Hv(n,i),e.components=new WeakMap,e}($g(om,Bv,rv,_m));function Wv(t){return(Wv="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})(t)}function Yv(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 qv(t,e){return!e||"object"!==Wv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Zv(t){return(Zv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Xv(t,e){return(Xv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function Kv(t,e,n){n?t.setAttribute(e,""):t.removeAttribute(e)}function $v(t){return($v="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})(t)}function Jv(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 Qv(t,e){return!e||"object"!==$v(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function ty(t){return(ty=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ey(t,e){return(ey=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function ny(t){return(ny="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})(t)}function ry(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 iy(t,e){return!e||"object"!==ny(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function oy(t){return(oy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ay(t,e){return(ay=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var sy=function(t){return Array.prototype.slice.call(t)};$g(om,hm,lv);function uy(t){return(uy="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})(t)}function ly(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 cy(t,e){return!e||"object"!==uy(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function fy(t){return(fy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function hy(t,e){return(hy=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function dy(t){return(dy="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})(t)}function py(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function gy(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 my(t,e){return!e||"object"!==dy(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function vy(t){return(vy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function yy(t,e){return(yy=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var by=function(t){return Array.prototype.slice.call(t)},_y=($g(om,hm,Im),xa((function(t,e){
15
+ ***************************************************************************** */var e=function(t,n){return(e=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,n)};function n(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}var r,i,o,a,s,u,l,c,f,h,d,p,g,m,v,y,b,_,w,O,x,E,S,T=function(){return(T=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function M(){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}!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"}(r||(r={})),function(t){t.RENDER_FINISHED="render-finished",t.RESIZE="chart-resize",t.MOUSEOVER="chart-mouseover",t.MOUSEOUT="chart-mouseout"}(i||(i={})),function(t){t.SHOW="show-modal",t.HIDE="hide-modal"}(o||(o={})),function(t){t.UPDATE="model-update"}(a||(a={})),function(t){t.SHOW_OVERFLOW_MENU="show-toolbar-overflow-menu",t.HIDE_OVERFLOW_MENU="hide-toolbar-overflow-menu"}(s||(s={})),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"}(u||(u={})),function(t){t.CHANGE="zoom-domain-change"}(l||(l={})),function(t){t.CANVAS_ZOOM_IN="canvas-zoom-in",t.CANVAS_ZOOM_OUT="canvas-zoom-out"}(c||(c={})),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"}(f||(f={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(h||(h={})),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"}(d||(d={})),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"}(p||(p={})),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"}(g||(g={})),function(t){t.BAR_MOUSEOVER="bar-mouseover",t.BAR_MOUSEMOVE="bar-mousemove",t.BAR_CLICK="bar-click",t.BAR_MOUSEOUT="bar-mouseout"}(m||(m={})),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"}(v||(v={})),function(t){t.SCATTER_MOUSEOVER="scatter-mouseover",t.SCATTER_MOUSEMOVE="scatter-mousemove",t.SCATTER_CLICK="scatter-click",t.SCATTER_MOUSEOUT="scatter-mouseout"}(y||(y={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(b||(b={})),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"}(_||(_={})),function(t){t.LEAF_MOUSEOVER="leaf-mouseover",t.LEAF_MOUSEMOVE="leaf-mousemove",t.LEAF_CLICK="leaf-click",t.LEAF_MOUSEOUT="leaf-mouseout"}(w||(w={})),function(t){t.SHOW="show-tooltip",t.MOVE="move-tooltip",t.HIDE="hide-tooltip"}(O||(O={})),function(t){t.SHOW="show-threshold",t.HIDE="hide-threshold"}(x||(x={})),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"}(E||(E={})),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"}(S||(S={}));var C,D,P,A,k,L,R,I,N,j,B,V,H,U,F,G,z,W,Y,q,Z,X,K,$,J,Q,tt=Object.freeze({__proto__:null,get Chart(){return i},get Modal(){return o},get Model(){return a},get Toolbar(){return s},get ZoomBar(){return u},get ZoomDomain(){return l},get CanvasZoom(){return c},get Axis(){return f},get Area(){return h},get WordCloud(){return d},get Pie(){return p},get Gauge(){return g},get Bar(){return m},get Boxplot(){return v},get Scatter(){return y},get Line(){return b},get Radar(){return _},get Treemap(){return w},get Tooltip(){return O},get Threshold(){return x},get Legend(){return E},get CirclePack(){return S}});!function(t){t.HTML="html",t.SVG="svg"}(C||(C={})),function(t){t.DEFAULT="default",t.G100="g100",t.G90="g90",t.G10="g10"}(D||(D={})),function(t){t.BACKGROUND="background",t.FILL="fill",t.STROKE="stroke",t.TOOLTIP="tooltip"}(P||(P={})),function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(A||(A={})),function(t){t.GRAPH_VIEW="graph_view",t.SLIDER_VIEW="slider_view"}(k||(k={})),function(t){t.END_LINE="end_line",t.MID_LINE="mid_line",t.FRONT_LINE="front_line",t.NONE="none"}(L||(L={})),function(t){t.VERTICAL="vertical",t.HORIZONTAL="horizontal"}(R||(R={})),function(t){t.TIME="time",t.LINEAR="linear",t.LOG="log",t.LABELS="labels",t.LABELS_RATIO="labels-ratio"}(I||(I={})),function(t){t.RIGHT="right",t.LEFT="left",t.TOP="top",t.BOTTOM="bottom"}(N||(N={})),function(t){t.LEFT="left",t.CENTER="center",t.RIGHT="right"}(j||(j={})),function(t){t.HORIZONTAL="horizontal",t.VERTICAL="vertical"}(B||(B={})),function(t){t.ROW="row",t.COLUMN="column",t.ROW_REVERSE="row-reverse",t.COLUMN_REVERSE="column-reverse"}(V||(V={})),function(t){t.FIXED="fixed",t.PREFERRED="preferred",t.STRETCH="stretch"}(H||(H={})),function(t){t.CENTER="center"}(U||(U={})),function(t){t.LEFT="left",t.RIGHT="right"}(F||(F={})),function(t){t.GRID="grid",t.VERT_OR_HORIZ="vertOrHoriz",t.PIE="pie",t.DONUT="donut"}(G||(G={})),function(t){t.START="start",t.MIDDLE="middle",t.END="end"}(z||(z={})),function(t){t.BASELINE="baseline",t.MIDDLE="middle",t.HANGING="hanging"}(W||(W={})),function(t){t.SEMI="semi",t.FULL="full"}(Y||(Y={})),function(t){t.UP="up",t.DOWN="down"}(q||(q={})),function(t){t.SUCCESS="success",t.WARNING="warning",t.DANGER="danger"}(Z||(Z={})),function(t){t.ALWAYS="always",t.AUTO="auto",t.NEVER="never"}(X||(X={})),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"}(K||(K={})),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"}($||($={})),function(t){t.LEFT="left",t.RIGHT="right"}(J||(J={})),function(t){t.CHECKBOX="checkbox",t.RADIUS="radius",t.AREA="area",t.SIZE="size",t.LINE="line",t.QUARTILE="quartile",t.ZOOM="zoom"}(Q||(Q={}));var et,nt=Object.freeze({__proto__:null,get Roles(){return r},Events:tt,get RenderTypes(){return C},get ChartTheme(){return D},get ColorClassNameTypes(){return P},get AxisPositions(){return A},get ZoomBarTypes(){return k},get TruncationTypes(){return L},get CartesianOrientations(){return R},get ScaleTypes(){return I},get LegendPositions(){return N},get Alignments(){return j},get LegendOrientations(){return B},get LayoutDirection(){return V},get LayoutGrowth(){return H},get LayoutAlignItems(){return U},get CalloutDirections(){return F},get Skeletons(){return G},get TextAnchor(){return z},get DominantBaseline(){return W},get GaugeTypes(){return Y},get ArrowDirections(){return q},get Statuses(){return Z},get TickRotations(){return X},get ChartTypes(){return K},get ToolbarControlTypes(){return $},get AxisTitleOrientations(){return J},get LegendItemType(){return Q}});function rt(t){return+t}function it(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var ot={opacity:{unselected:.05,selected:.4}},at={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1},st={duration:1e3,ease:it,zoomLevel:3},ut={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},lt={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},ct={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},ft={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"}},ht={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},dt={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15}},pt={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}},gt={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},mt={default:{size:24}},vt={horizontalOffset:10},yt={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}},bt={height:(et={},et[k.GRAPH_VIEW]=32,et[k.SLIDER_VIEW]=10,et),spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},_t=[{type:Q.RADIUS,name:"Radius"},{type:Q.AREA,name:"Poor area"},{type:Q.AREA,name:"Satisfactory area"},{type:Q.AREA,name:"Great area"},{type:Q.QUARTILE,name:"Quartiles"}],wt="object"==typeof global&&global&&global.Object===Object&&global,Ot="object"==typeof self&&self&&self.Object===Object&&self,xt=wt||Ot||Function("return this")(),Et=xt.Symbol,St=Object.prototype,Tt=St.hasOwnProperty,Mt=St.toString,Ct=Et?Et.toStringTag:void 0;var Dt=Object.prototype.toString;var Pt=Et?Et.toStringTag:void 0;function At(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":Pt&&Pt in Object(t)?function(t){var e=Tt.call(t,Ct),n=t[Ct];try{t[Ct]=void 0;var r=!0}catch(t){}var i=Mt.call(t);return r&&(e?t[Ct]=n:delete t[Ct]),i}(t):function(t){return Dt.call(t)}(t)}function kt(t){return null!=t&&"object"==typeof t}function Lt(t){return"symbol"==typeof t||kt(t)&&"[object Symbol]"==At(t)}function Rt(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}var It=Array.isArray,Nt=Et?Et.prototype:void 0,jt=Nt?Nt.toString:void 0;function Bt(t){if("string"==typeof t)return t;if(It(t))return Rt(t,Bt)+"";if(Lt(t))return jt?jt.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}var Vt=/\s/;var Ht=/^\s+/;function Ut(t){return t?t.slice(0,function(t){for(var e=t.length;e--&&Vt.test(t.charAt(e)););return e}(t)+1).replace(Ht,""):t}function Ft(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Gt=/^[-+]0x[0-9a-f]+$/i,zt=/^0b[01]+$/i,Wt=/^0o[0-7]+$/i,Yt=parseInt;function qt(t){if("number"==typeof t)return t;if(Lt(t))return NaN;if(Ft(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Ft(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ut(t);var n=zt.test(t);return n||Wt.test(t)?Yt(t.slice(2),n?2:8):Gt.test(t)?NaN:+t}function Zt(t){return t}function Xt(t){if(!Ft(t))return!1;var e=At(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var Kt,$t=xt["__core-js_shared__"],Jt=(Kt=/[^.]+$/.exec($t&&$t.keys&&$t.keys.IE_PROTO||""))?"Symbol(src)_1."+Kt:"";var Qt=Function.prototype.toString;function te(t){if(null!=t){try{return Qt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var ee=/^\[object .+?Constructor\]$/,ne=Function.prototype,re=Object.prototype,ie=ne.toString,oe=re.hasOwnProperty,ae=RegExp("^"+ie.call(oe).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function se(t){return!(!Ft(t)||(e=t,Jt&&Jt in e))&&(Xt(t)?ae:ee).test(te(t));var e}function ue(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return se(n)?n:void 0}var le=ue(xt,"WeakMap"),ce=Object.create,fe=function(){function t(){}return function(e){if(!Ft(e))return{};if(ce)return ce(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();function he(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)}function de(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}var pe=Date.now;var ge=function(){try{var t=ue(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),me=function(t){var e=0,n=0;return function(){var r=pe(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(ge?function(t,e){return ge(t,"toString",{configurable:!0,enumerable:!1,value:(n=e,function(){return n}),writable:!0});var n}:Zt);function ve(t){return t!=t}function ye(t,e){return!!(null==t?0:t.length)&&function(t,e,n){return e==e?function(t,e,n){for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}(t,e,n):function(t,e,n,r){for(var i=t.length,o=n+(r?1:-1);r?o--:++o<i;)if(e(t[o],o,t))return o;return-1}(t,ve,n)}(t,e,0)>-1}var be=/^(?:0|[1-9]\d*)$/;function _e(t,e){var n=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==n||"symbol"!=n&&be.test(t))&&t>-1&&t%1==0&&t<e}function we(t,e,n){"__proto__"==e&&ge?ge(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function Oe(t,e){return t===e||t!=t&&e!=e}var xe=Object.prototype.hasOwnProperty;function Ee(t,e,n){var r=t[e];xe.call(t,e)&&Oe(r,n)&&(void 0!==n||e in t)||we(t,e,n)}function Se(t,e,n,r){var i=!n;n||(n={});for(var o=-1,a=e.length;++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?we(n,s,u):Ee(n,s,u)}return n}var Te=Math.max;function Me(t,e){return me(function(t,e,n){return e=Te(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,o=Te(r.length-e,0),a=Array(o);++i<o;)a[i]=r[e+i];i=-1;for(var s=Array(e+1);++i<e;)s[i]=r[i];return s[e]=n(a),he(t,this,s)}}(t,e,Zt),t+"")}function Ce(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}function De(t){return null!=t&&Ce(t.length)&&!Xt(t)}function Pe(t,e,n){if(!Ft(n))return!1;var r=typeof e;return!!("number"==r?De(n)&&_e(e,n.length):"string"==r&&e in n)&&Oe(n[e],t)}var Ae=Object.prototype;function ke(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Ae)}function Le(t){return kt(t)&&"[object Arguments]"==At(t)}var Re=Object.prototype,Ie=Re.hasOwnProperty,Ne=Re.propertyIsEnumerable,je=Le(function(){return arguments}())?Le:function(t){return kt(t)&&Ie.call(t,"callee")&&!Ne.call(t,"callee")};var Be="object"==typeof t&&t&&!t.nodeType&&t,Ve=Be&&"object"==typeof module&&module&&!module.nodeType&&module,He=Ve&&Ve.exports===Be?xt.Buffer:void 0,Ue=(He?He.isBuffer:void 0)||function(){return!1},Fe={};function Ge(t){return function(e){return t(e)}}Fe["[object Float32Array]"]=Fe["[object Float64Array]"]=Fe["[object Int8Array]"]=Fe["[object Int16Array]"]=Fe["[object Int32Array]"]=Fe["[object Uint8Array]"]=Fe["[object Uint8ClampedArray]"]=Fe["[object Uint16Array]"]=Fe["[object Uint32Array]"]=!0,Fe["[object Arguments]"]=Fe["[object Array]"]=Fe["[object ArrayBuffer]"]=Fe["[object Boolean]"]=Fe["[object DataView]"]=Fe["[object Date]"]=Fe["[object Error]"]=Fe["[object Function]"]=Fe["[object Map]"]=Fe["[object Number]"]=Fe["[object Object]"]=Fe["[object RegExp]"]=Fe["[object Set]"]=Fe["[object String]"]=Fe["[object WeakMap]"]=!1;var ze="object"==typeof t&&t&&!t.nodeType&&t,We=ze&&"object"==typeof module&&module&&!module.nodeType&&module,Ye=We&&We.exports===ze&&wt.process,qe=function(){try{var t=We&&We.require&&We.require("util").types;return t||Ye&&Ye.binding&&Ye.binding("util")}catch(t){}}(),Ze=qe&&qe.isTypedArray,Xe=Ze?Ge(Ze):function(t){return kt(t)&&Ce(t.length)&&!!Fe[At(t)]},Ke=Object.prototype.hasOwnProperty;function $e(t,e){var n=It(t),r=!n&&je(t),i=!n&&!r&&Ue(t),o=!n&&!r&&!i&&Xe(t),a=n||r||i||o,s=a?function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}(t.length,String):[],u=s.length;for(var l in t)!e&&!Ke.call(t,l)||a&&("length"==l||i&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||_e(l,u))||s.push(l);return s}function Je(t,e){return function(n){return t(e(n))}}var Qe=Je(Object.keys,Object),tn=Object.prototype.hasOwnProperty;function en(t){if(!ke(t))return Qe(t);var e=[];for(var n in Object(t))tn.call(t,n)&&"constructor"!=n&&e.push(n);return e}function nn(t){return De(t)?$e(t):en(t)}var rn=Object.prototype.hasOwnProperty;function on(t){if(!Ft(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=ke(t),n=[];for(var r in t)("constructor"!=r||!e&&rn.call(t,r))&&n.push(r);return n}function an(t){return De(t)?$e(t,!0):on(t)}var sn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,un=/^\w*$/;function ln(t,e){if(It(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!Lt(t))||(un.test(t)||!sn.test(t)||null!=e&&t in Object(e))}var cn=ue(Object,"create");var fn=Object.prototype.hasOwnProperty;var hn=Object.prototype.hasOwnProperty;function dn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function pn(t,e){for(var n=t.length;n--;)if(Oe(t[n][0],e))return n;return-1}dn.prototype.clear=function(){this.__data__=cn?cn(null):{},this.size=0},dn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},dn.prototype.get=function(t){var e=this.__data__;if(cn){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return fn.call(e,t)?e[t]:void 0},dn.prototype.has=function(t){var e=this.__data__;return cn?void 0!==e[t]:hn.call(e,t)},dn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=cn&&void 0===e?"__lodash_hash_undefined__":e,this};var gn=Array.prototype.splice;function mn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}mn.prototype.clear=function(){this.__data__=[],this.size=0},mn.prototype.delete=function(t){var e=this.__data__,n=pn(e,t);return!(n<0)&&(n==e.length-1?e.pop():gn.call(e,n,1),--this.size,!0)},mn.prototype.get=function(t){var e=this.__data__,n=pn(e,t);return n<0?void 0:e[n][1]},mn.prototype.has=function(t){return pn(this.__data__,t)>-1},mn.prototype.set=function(t,e){var n=this.__data__,r=pn(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var vn=ue(xt,"Map");function yn(t,e){var n=t.__data__;return function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}(e)?n["string"==typeof e?"string":"hash"]:n.map}function bn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}bn.prototype.clear=function(){this.size=0,this.__data__={hash:new dn,map:new(vn||mn),string:new dn}},bn.prototype.delete=function(t){var e=yn(this,t).delete(t);return this.size-=e?1:0,e},bn.prototype.get=function(t){return yn(this,t).get(t)},bn.prototype.has=function(t){return yn(this,t).has(t)},bn.prototype.set=function(t,e){var n=yn(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};function _n(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");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(_n.Cache||bn),n}_n.Cache=bn;var wn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,On=/\\(\\)?/g,xn=function(t){var e=_n(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(wn,(function(t,n,r,i){e.push(r?i.replace(On,"$1"):n||t)})),e}));function En(t){return null==t?"":Bt(t)}function Sn(t,e){return It(t)?t:ln(t,e)?[t]:xn(En(t))}function Tn(t){if("string"==typeof t||Lt(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Mn(t,e){for(var n=0,r=(e=Sn(e,t)).length;null!=t&&n<r;)t=t[Tn(e[n++])];return n&&n==r?t:void 0}function Cn(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}var Dn=Et?Et.isConcatSpreadable:void 0;function Pn(t){return It(t)||je(t)||!!(Dn&&t&&t[Dn])}function An(t,e,n,r,i){var o=-1,a=t.length;for(n||(n=Pn),i||(i=[]);++o<a;){var s=t[o];e>0&&n(s)?e>1?An(s,e-1,n,r,i):Cn(i,s):r||(i[i.length]=s)}return i}function kn(t){return(null==t?0:t.length)?An(t,1):[]}var Ln=Je(Object.getPrototypeOf,Object),Rn=Function.prototype,In=Object.prototype,Nn=Rn.toString,jn=In.hasOwnProperty,Bn=Nn.call(Object);function Vn(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=Array(i);++r<i;)o[r]=t[r+e];return o}(t,e,n)}var Hn=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");function Un(t){return Hn.test(t)}var Fn="[\\ud800-\\udfff]",Gn="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",zn="\\ud83c[\\udffb-\\udfff]",Wn="[^\\ud800-\\udfff]",Yn="(?:\\ud83c[\\udde6-\\uddff]){2}",qn="[\\ud800-\\udbff][\\udc00-\\udfff]",Zn="(?:"+Gn+"|"+zn+")"+"?",Xn="[\\ufe0e\\ufe0f]?"+Zn+("(?:\\u200d(?:"+[Wn,Yn,qn].join("|")+")[\\ufe0e\\ufe0f]?"+Zn+")*"),Kn="(?:"+[Wn+Gn+"?",Gn,Yn,qn,Fn].join("|")+")",$n=RegExp(zn+"(?="+zn+")|"+Kn+Xn,"g");function Jn(t){return Un(t)?function(t){return t.match($n)||[]}(t):function(t){return t.split("")}(t)}var Qn,tr=(Qn="toUpperCase",function(t){var e=Un(t=En(t))?Jn(t):void 0,n=e?e[0]:t.charAt(0),r=e?Vn(e,1).join(""):t.slice(1);return n[Qn]()+r});var er=function(t){return function(e){return null==t?void 0:t[e]}}({"À":"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"}),nr=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,rr=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");var ir=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var or=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var ar="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",sr="["+ar+"]",ur="\\d+",lr="[\\u2700-\\u27bf]",cr="[a-z\\xdf-\\xf6\\xf8-\\xff]",fr="[^\\ud800-\\udfff"+ar+ur+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",hr="(?:\\ud83c[\\udde6-\\uddff]){2}",dr="[\\ud800-\\udbff][\\udc00-\\udfff]",pr="[A-Z\\xc0-\\xd6\\xd8-\\xde]",gr="(?:"+cr+"|"+fr+")",mr="(?:"+pr+"|"+fr+")",vr="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",yr="[\\ufe0e\\ufe0f]?"+vr+("(?:\\u200d(?:"+["[^\\ud800-\\udfff]",hr,dr].join("|")+")[\\ufe0e\\ufe0f]?"+vr+")*"),br="(?:"+[lr,hr,dr].join("|")+")"+yr,_r=RegExp([pr+"?"+cr+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[sr,pr,"$"].join("|")+")",mr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[sr,pr+gr,"$"].join("|")+")",pr+"?"+gr+"+(?:['’](?:d|ll|m|re|s|t|ve))?",pr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ur,br].join("|"),"g");function wr(t,e,n){return t=En(t),void 0===(e=n?void 0:e)?function(t){return or.test(t)}(t)?function(t){return t.match(_r)||[]}(t):function(t){return t.match(ir)||[]}(t):t.match(e)||[]}var Or=RegExp("['’]","g");function xr(t){return function(e){return function(t,e,n,r){var i=-1,o=null==t?0:t.length;for(r&&o&&(n=t[++i]);++i<o;)n=e(n,t[i],i,t);return n}(wr(function(t){return(t=En(t))&&t.replace(nr,er).replace(rr,"")}(e).replace(Or,"")),t,"")}}var Er=xr((function(t,e,n){return e=e.toLowerCase(),t+(n?tr(En(e).toLowerCase()):e)}));function Sr(t,e,n){return void 0===n&&(n=e,e=void 0),void 0!==n&&(n=(n=qt(n))==n?n:0),void 0!==e&&(e=(e=qt(e))==e?e:0),function(t,e,n){return t==t&&(void 0!==n&&(t=t<=n?t:n),void 0!==e&&(t=t>=e?t:e)),t}(qt(t),e,n)}function Tr(t){var e=this.__data__=new mn(t);this.size=e.size}Tr.prototype.clear=function(){this.__data__=new mn,this.size=0},Tr.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Tr.prototype.get=function(t){return this.__data__.get(t)},Tr.prototype.has=function(t){return this.__data__.has(t)},Tr.prototype.set=function(t,e){var n=this.__data__;if(n instanceof mn){var r=n.__data__;if(!vn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new bn(r)}return n.set(t,e),this.size=n.size,this};var Mr="object"==typeof t&&t&&!t.nodeType&&t,Cr=Mr&&"object"==typeof module&&module&&!module.nodeType&&module,Dr=Cr&&Cr.exports===Mr?xt.Buffer:void 0,Pr=Dr?Dr.allocUnsafe:void 0;function Ar(t,e){if(e)return t.slice();var n=t.length,r=Pr?Pr(n):new t.constructor(n);return t.copy(r),r}function kr(){return[]}var Lr=Object.prototype.propertyIsEnumerable,Rr=Object.getOwnPropertySymbols,Ir=Rr?function(t){return null==t?[]:(t=Object(t),function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,o=[];++n<r;){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}(Rr(t),(function(e){return Lr.call(t,e)})))}:kr;var Nr=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)Cn(e,Ir(t)),t=Ln(t);return e}:kr;function jr(t,e,n){var r=e(t);return It(t)?r:Cn(r,n(t))}function Br(t){return jr(t,nn,Ir)}function Vr(t){return jr(t,an,Nr)}var Hr=ue(xt,"DataView"),Ur=ue(xt,"Promise"),Fr=ue(xt,"Set"),Gr=te(Hr),zr=te(vn),Wr=te(Ur),Yr=te(Fr),qr=te(le),Zr=At;(Hr&&"[object DataView]"!=Zr(new Hr(new ArrayBuffer(1)))||vn&&"[object Map]"!=Zr(new vn)||Ur&&"[object Promise]"!=Zr(Ur.resolve())||Fr&&"[object Set]"!=Zr(new Fr)||le&&"[object WeakMap]"!=Zr(new le))&&(Zr=function(t){var e=At(t),n="[object Object]"==e?t.constructor:void 0,r=n?te(n):"";if(r)switch(r){case Gr:return"[object DataView]";case zr:return"[object Map]";case Wr:return"[object Promise]";case Yr:return"[object Set]";case qr:return"[object WeakMap]"}return e});var Xr=Zr,Kr=Object.prototype.hasOwnProperty;var $r=xt.Uint8Array;function Jr(t){var e=new t.constructor(t.byteLength);return new $r(e).set(new $r(t)),e}var Qr=/\w*$/;var ti=Et?Et.prototype:void 0,ei=ti?ti.valueOf:void 0;function ni(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function ri(t,e,n){var r,i,o,a=t.constructor;switch(e){case"[object ArrayBuffer]":return Jr(t);case"[object Boolean]":case"[object Date]":return new a(+t);case"[object DataView]":return function(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return ni(t,n);case"[object Map]":return new a;case"[object Number]":case"[object String]":return new a(t);case"[object RegExp]":return(o=new(i=t).constructor(i.source,Qr.exec(i))).lastIndex=i.lastIndex,o;case"[object Set]":return new a;case"[object Symbol]":return r=t,ei?Object(ei.call(r)):{}}}function ii(t){return"function"!=typeof t.constructor||ke(t)?{}:fe(Ln(t))}var oi=qe&&qe.isMap,ai=oi?Ge(oi):function(t){return kt(t)&&"[object Map]"==Xr(t)};var si=qe&&qe.isSet,ui=si?Ge(si):function(t){return kt(t)&&"[object Set]"==Xr(t)},li={};function ci(t,e,n,r,i,o){var a,s=1&e,u=2&e,l=4&e;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!Ft(t))return t;var c=It(t);if(c){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&Kr.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!s)return de(t,a)}else{var f=Xr(t),h="[object Function]"==f||"[object GeneratorFunction]"==f;if(Ue(t))return Ar(t,s);if("[object Object]"==f||"[object Arguments]"==f||h&&!i){if(a=u||h?{}:ii(t),!s)return u?function(t,e){return Se(t,Nr(t),e)}(t,function(t,e){return t&&Se(e,an(e),t)}(a,t)):function(t,e){return Se(t,Ir(t),e)}(t,function(t,e){return t&&Se(e,nn(e),t)}(a,t))}else{if(!li[f])return i?t:{};a=ri(t,f,s)}}o||(o=new Tr);var d=o.get(t);if(d)return d;o.set(t,a),ui(t)?t.forEach((function(r){a.add(ci(r,e,n,r,t,o))})):ai(t)&&t.forEach((function(r,i){a.set(i,ci(r,e,n,i,t,o))}));var p=c?void 0:(l?u?Vr:Br:u?an:nn)(t);return function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););}(p||t,(function(r,i){p&&(r=t[i=r]),Ee(a,i,ci(r,e,n,i,t,o))})),a}li["[object Arguments]"]=li["[object Array]"]=li["[object ArrayBuffer]"]=li["[object DataView]"]=li["[object Boolean]"]=li["[object Date]"]=li["[object Float32Array]"]=li["[object Float64Array]"]=li["[object Int8Array]"]=li["[object Int16Array]"]=li["[object Int32Array]"]=li["[object Map]"]=li["[object Number]"]=li["[object Object]"]=li["[object RegExp]"]=li["[object Set]"]=li["[object String]"]=li["[object Symbol]"]=li["[object Uint8Array]"]=li["[object Uint8ClampedArray]"]=li["[object Uint16Array]"]=li["[object Uint32Array]"]=!0,li["[object Error]"]=li["[object Function]"]=li["[object WeakMap]"]=!1;function fi(t){return ci(t,5)}function hi(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new bn;++e<n;)this.add(t[e])}function di(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}function pi(t,e){return t.has(e)}hi.prototype.add=hi.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},hi.prototype.has=function(t){return this.__data__.has(t)};function gi(t,e,n,r,i,o){var a=1&n,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 f=-1,h=!0,d=2&n?new hi:void 0;for(o.set(t,e),o.set(e,t);++f<s;){var p=t[f],g=e[f];if(r)var m=a?r(g,p,f,e,t,o):r(p,g,f,t,e,o);if(void 0!==m){if(m)continue;h=!1;break}if(d){if(!di(e,(function(t,e){if(!pi(d,e)&&(p===t||i(p,t,n,r,o)))return d.push(e)}))){h=!1;break}}else if(p!==g&&!i(p,g,n,r,o)){h=!1;break}}return o.delete(t),o.delete(e),h}function mi(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function vi(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var yi=Et?Et.prototype:void 0,bi=yi?yi.valueOf:void 0;var _i=Object.prototype.hasOwnProperty;var wi=Object.prototype.hasOwnProperty;function Oi(t,e,n,r,i,o){var a=It(t),s=It(e),u=a?"[object Array]":Xr(t),l=s?"[object Array]":Xr(e),c="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),f="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),h=u==l;if(h&&Ue(t)){if(!Ue(e))return!1;a=!0,c=!1}if(h&&!c)return o||(o=new Tr),a||Xe(t)?gi(t,e,n,r,i,o):function(t,e,n,r,i,o,a){switch(n){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!o(new $r(t),new $r(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Oe(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var s=mi;case"[object Set]":var u=1&r;if(s||(s=vi),t.size!=e.size&&!u)return!1;var l=a.get(t);if(l)return l==e;r|=2,a.set(t,e);var c=gi(s(t),s(e),r,i,o,a);return a.delete(t),c;case"[object Symbol]":if(bi)return bi.call(t)==bi.call(e)}return!1}(t,e,u,n,r,i,o);if(!(1&n)){var d=c&&wi.call(t,"__wrapped__"),p=f&&wi.call(e,"__wrapped__");if(d||p){var g=d?t.value():t,m=p?e.value():e;return o||(o=new Tr),i(g,m,n,r,o)}}return!!h&&(o||(o=new Tr),function(t,e,n,r,i,o){var a=1&n,s=Br(t),u=s.length;if(u!=Br(e).length&&!a)return!1;for(var l=u;l--;){var c=s[l];if(!(a?c in e:_i.call(e,c)))return!1}var f=o.get(t),h=o.get(e);if(f&&h)return f==e&&h==t;var d=!0;o.set(t,e),o.set(e,t);for(var p=a;++l<u;){var g=t[c=s[l]],m=e[c];if(r)var v=a?r(m,g,c,e,t,o):r(g,m,c,t,e,o);if(!(void 0===v?g===m||i(g,m,n,r,o):v)){d=!1;break}p||(p="constructor"==c)}if(d&&!p){var y=t.constructor,b=e.constructor;y!=b&&"constructor"in t&&"constructor"in e&&!("function"==typeof y&&y instanceof y&&"function"==typeof b&&b instanceof b)&&(d=!1)}return o.delete(t),o.delete(e),d}(t,e,n,r,i,o))}function xi(t,e,n,r,i){return t===e||(null==t||null==e||!kt(t)&&!kt(e)?t!=t&&e!=e:Oi(t,e,n,r,xi,i))}function Ei(t){return t==t&&!Ft(t)}function Si(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}function Ti(t){var e=function(t){for(var e=nn(t),n=e.length;n--;){var r=e[n],i=t[r];e[n]=[r,i,Ei(i)]}return e}(t);return 1==e.length&&e[0][2]?Si(e[0][0],e[0][1]):function(n){return n===t||function(t,e,n,r){var i=n.length,o=i,a=!r;if(null==t)return!o;for(t=Object(t);i--;){var s=n[i];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++i<o;){var u=(s=n[i])[0],l=t[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in t))return!1}else{var f=new Tr;if(r)var h=r(l,c,u,t,e,f);if(!(void 0===h?xi(c,l,3,r,f):h))return!1}}return!0}(n,t,e)}}function Mi(t,e){return null!=t&&e in Object(t)}function Ci(t,e){return null!=t&&function(t,e,n){for(var r=-1,i=(e=Sn(e,t)).length,o=!1;++r<i;){var a=Tn(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:!!(i=null==t?0:t.length)&&Ce(i)&&_e(a,i)&&(It(t)||je(t))}(t,e,Mi)}function Di(t,e){return ln(t)&&Ei(e)?Si(Tn(t),e):function(n){var r=function(t,e,n){var r=null==t?void 0:Mn(t,e);return void 0===r?n:r}(n,t);return void 0===r&&r===e?Ci(n,t):xi(e,r,3)}}function Pi(t){return ln(t)?(e=Tn(t),function(t){return null==t?void 0:t[e]}):function(t){return function(e){return Mn(e,t)}}(t);var e}function Ai(t){return"function"==typeof t?t:null==t?Zt:"object"==typeof t?It(t)?Di(t[0],t[1]):Ti(t):Pi(t)}var ki,Li=function(t,e,n){for(var r=-1,i=Object(t),o=n(t),a=o.length;a--;){var s=o[ki?a:++r];if(!1===e(i[s],s,i))break}return t};var Ri=function(t,e){return function(n,r){if(null==n)return n;if(!De(n))return t(n,r);for(var i=n.length,o=e?i:-1,a=Object(n);(e?o--:++o<i)&&!1!==r(a[o],o,a););return n}}((function(t,e){return t&&Li(t,e,nn)})),Ii=function(){return xt.Date.now()},Ni=Math.max,ji=Math.min;function Bi(t,e,n){var r,i,o,a,s,u,l=0,c=!1,f=!1,h=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function d(e){var n=r,o=i;return r=i=void 0,l=e,a=t.apply(o,n)}function p(t){return l=t,s=setTimeout(m,e),c?d(t):a}function g(t){var n=t-u;return void 0===u||n>=e||n<0||f&&t-l>=o}function m(){var t=Ii();if(g(t))return v(t);s=setTimeout(m,function(t){var n=e-(t-u);return f?ji(n,o-(t-l)):n}(t))}function v(t){return s=void 0,h&&r?d(t):(r=i=void 0,a)}function y(){var t=Ii(),n=g(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return p(u);if(f)return clearTimeout(s),s=setTimeout(m,e),d(u)}return void 0===s&&(s=setTimeout(m,e)),a}return e=qt(e)||0,Ft(n)&&(c=!!n.leading,o=(f="maxWait"in n)?Ni(qt(n.maxWait)||0,e):o,h="trailing"in n?!!n.trailing:h),y.cancel=function(){void 0!==s&&clearTimeout(s),l=0,r=u=i=s=void 0},y.flush=function(){return void 0===s?a:v(Ii())},y}function Vi(t,e,n){(void 0===n||Oe(t[e],n))&&(void 0!==n||e in t)||we(t,e,n)}function Hi(t){return kt(t)&&De(t)}function Ui(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}function Fi(t,e,n,r,i,o,a){var s=Ui(t,n),u=Ui(e,n),l=a.get(u);if(l)Vi(t,n,l);else{var c,f=o?o(s,u,n+"",t,e,a):void 0,h=void 0===f;if(h){var d=It(u),p=!d&&Ue(u),g=!d&&!p&&Xe(u);f=u,d||p||g?It(s)?f=s:Hi(s)?f=de(s):p?(h=!1,f=Ar(u,!0)):g?(h=!1,f=ni(u,!0)):f=[]:function(t){if(!kt(t)||"[object Object]"!=At(t))return!1;var e=Ln(t);if(null===e)return!0;var n=jn.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Nn.call(n)==Bn}(u)||je(u)?(f=s,je(s)?f=Se(c=s,an(c)):Ft(s)&&!Xt(s)||(f=ii(u))):h=!1}h&&(a.set(u,f),i(f,u,r,o,a),a.delete(u)),Vi(t,n,f)}}function Gi(t,e,n,r,i){t!==e&&Li(e,(function(o,a){if(i||(i=new Tr),Ft(o))Fi(t,e,a,n,Gi,r,i);else{var s=r?r(Ui(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),Vi(t,a,s)}}),an)}function zi(t,e,n){for(var r=-1,i=null==t?0:t.length;++r<i;)if(n(e,t[r]))return!0;return!1}function Wi(t,e){var n=-1,r=De(t)?Array(t.length):[];return Ri(t,(function(t,i,o){r[++n]=e(t,i,o)})),r}function Yi(t,e){return An(function(t,e){return(It(t)?Rt:Wi)(t,Ai(e))}(t,e),1/0)}function qi(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var i=t[e];r[i[0]]=i[1]}return r}var Zi=Object.prototype.hasOwnProperty;function Xi(t){if(null==t)return!0;if(De(t)&&(It(t)||"string"==typeof t||"function"==typeof t.splice||Ue(t)||Xe(t)||je(t)))return!t.length;var e=Xr(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(ke(t))return!en(t).length;for(var n in t)if(Zi.call(t,n))return!1;return!0}function Ki(t,e){return xi(t,e)}var $i,Ji=xr((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Qi=($i=function(t,e,n){Gi(t,e,n)},Me((function(t,e){var n=-1,r=e.length,i=r>1?e[r-1]:void 0,o=r>2?e[2]:void 0;for(i=$i.length>3&&"function"==typeof i?(r--,i):void 0,o&&Pe(e[0],e[1],o)&&(i=r<3?void 0:i,r=1),t=Object(t);++n<r;){var a=e[n];a&&$i(t,a,n,i)}return t})));function to(t,e){var n;return Ri(t,(function(t,r,i){return!(n=e(t,r,i))})),!!n}function eo(t,e,n){var r=It(t)?di:to;return n&&Pe(t,e,n)&&(e=void 0),r(t,Ai(e))}var no=Fr&&1/vi(new Fr([,-0]))[1]==1/0?function(t){return new Fr(t)}:function(){};function ro(t,e,n){var r=-1,i=ye,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=zi;else if(o>=200){var l=e?null:no(t);if(l)return vi(l);a=!1,i=pi,u=new hi}else u=e?[]:s;t:for(;++r<o;){var c=t[r],f=e?e(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var h=u.length;h--;)if(u[h]===f)continue t;e&&u.push(f),s.push(c)}else i(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}var io=Me((function(t){var e=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}(t);return Hi(e)&&(e=void 0),ro(An(t,1,Hi,!0),Ai(e))}));function oo(t){return t&&t.length?ro(t):[]}var ao="http://www.w3.org/1999/xhtml",so={svg:"http://www.w3.org/2000/svg",xhtml:ao,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function uo(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),so.hasOwnProperty(e)?{space:so[e],local:t}:t}function lo(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===ao&&e.documentElement.namespaceURI===ao?e.createElement(t):e.createElementNS(n,t)}}function co(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function fo(t){var e=uo(t);return(e.local?co:lo)(e)}function ho(){}function po(t){return null==t?ho:function(){return this.querySelector(t)}}function go(){return[]}function mo(t){return null==t?go:function(){return this.querySelectorAll(t)}}function vo(t){return function(){return this.matches(t)}}function yo(t){return new Array(t.length)}function bo(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}bo.prototype={constructor:bo,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)}};function _o(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 bo(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function wo(t,e,n,r,i,o,a){var s,u,l,c={},f=e.length,h=o.length,d=new Array(f);for(s=0;s<f;++s)(u=e[s])&&(d[s]=l="$"+a.call(u,u.__data__,s,e),l in c?i[s]=u:c[l]=u);for(s=0;s<h;++s)(u=c[l="$"+a.call(t,o[s],s,o)])?(r[s]=u,u.__data__=o[s],c[l]=null):n[s]=new bo(t,o[s]);for(s=0;s<f;++s)(u=e[s])&&c[d[s]]===u&&(i[s]=u)}function Oo(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function xo(t){return function(){this.removeAttribute(t)}}function Eo(t){return function(){this.removeAttributeNS(t.space,t.local)}}function So(t,e){return function(){this.setAttribute(t,e)}}function To(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Mo(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Co(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)}}function Do(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Po(t){return function(){this.style.removeProperty(t)}}function Ao(t,e,n){return function(){this.style.setProperty(t,e,n)}}function ko(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function Lo(t,e){return t.style.getPropertyValue(e)||Do(t).getComputedStyle(t,null).getPropertyValue(e)}function Ro(t){return function(){delete this[t]}}function Io(t,e){return function(){this[t]=e}}function No(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function jo(t){return t.trim().split(/^|\s+/)}function Bo(t){return t.classList||new Vo(t)}function Vo(t){this._node=t,this._names=jo(t.getAttribute("class")||"")}function Ho(t,e){for(var n=Bo(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function Uo(t,e){for(var n=Bo(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function Fo(t){return function(){Ho(this,t)}}function Go(t){return function(){Uo(this,t)}}function zo(t,e){return function(){(e.apply(this,arguments)?Ho:Uo)(this,t)}}function Wo(){this.textContent=""}function Yo(t){return function(){this.textContent=t}}function qo(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function Zo(){this.innerHTML=""}function Xo(t){return function(){this.innerHTML=t}}function Ko(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function $o(){this.nextSibling&&this.parentNode.appendChild(this)}function Jo(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Qo(){return null}function ta(){var t=this.parentNode;t&&t.removeChild(this)}function ea(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function na(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}Vo.prototype={add:function(t){this._names.indexOf(t)<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 ra={},ia=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(ra={mouseenter:"mouseover",mouseleave:"mouseout"}));function oa(t,e,n){return t=aa(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function aa(t,e,n){return function(r){var i=ia;ia=r;try{t.call(this,this.__data__,e,n)}finally{ia=i}}}function sa(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 ua(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.capture);++i?e.length=i:delete this.__on}}}function la(t,e,n){var r=ra.hasOwnProperty(t.type)?oa:aa;return function(i,o,a){var s,u=this.__on,l=r(e,o,a);if(u)for(var c=0,f=u.length;c<f;++c)if((s=u[c]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},u?u.push(s):this.__on=[s]}}function ca(t,e,n){var r=Do(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 fa(t,e){return function(){return ca(this,t,e)}}function ha(t,e){return function(){return ca(this,t,e.apply(this,arguments))}}var da,pa=[null];function ga(t,e){this._groups=t,this._parents=e}function ma(){return new ga([[document.documentElement]],pa)}function va(t){return"string"==typeof t?new ga([[document.querySelector(t)]],[document.documentElement]):new ga([[t]],pa)}function ya(){for(var t,e=ia;t=e.sourceEvent;)e=t;return e}function ba(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}function _a(t){var e=ya();return e.changedTouches&&(e=e.changedTouches[0]),ba(t,e)}ga.prototype=ma.prototype={constructor:ga,select:function(t){"function"!=typeof t&&(t=po(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 ga(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=mo(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 ga(r,i)},filter:function(t){"function"!=typeof t&&(t=vo(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 ga(r,this._parents)},data:function(t,e){if(!t)return d=new Array(this.size()),l=-1,this.each((function(t){d[++l]=t})),d;var n=e?wo:_o,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(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],f=i[l],h=f.length,d=t.call(c,c&&c.__data__,l,r),p=d.length,g=s[l]=new Array(p),m=a[l]=new Array(p);n(c,f,g,m,u[l]=new Array(h),d,e);for(var v,y,b=0,_=0;b<p;++b)if(v=g[b]){for(b>=_&&(_=b+1);!(y=m[_])&&++_<p;);v._next=y||null}}return(a=new ga(a,r))._enter=s,a._exit=u,a},enter:function(){return new ga(this._enter||this._groups.map(yo),this._parents)},exit:function(){return new ga(this._exit||this._groups.map(yo),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return r="function"==typeof t?t(r):r.append(t+""),null!=e&&(i=e(i)),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){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],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new ga(a,this._parents)},order: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},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Oo);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 ga(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node: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},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each: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},attr:function(t,e){var n=uo(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?Eo:xo:"function"==typeof e?n.local?Co:Mo:n.local?To:So)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?Po:"function"==typeof e?ko:Ao)(t,e,null==n?"":n)):Lo(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Ro:"function"==typeof e?No:Io)(t,e)):this.node()[t]},classed:function(t,e){var n=jo(t+"");if(arguments.length<2){for(var r=Bo(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?zo:e?Fo:Go)(n,e))},text:function(t){return arguments.length?this.each(null==t?Wo:("function"==typeof t?qo:Yo)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?Zo:("function"==typeof t?Ko:Xo)(t)):this.node().innerHTML},raise:function(){return this.each($o)},lower:function(){return this.each(Jo)},append:function(t){var e="function"==typeof t?t:fo(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:fo(t),r=null==e?Qo:"function"==typeof e?e:po(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(ta)},clone:function(t){return this.select(t?na:ea)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=sa(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?la:ua,null==n&&(n=!1),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},dispatch:function(t,e){return this.each(("function"==typeof e?ha:fa)(t,e))}},function(t){function e(e,n){var r=t.getProperty(e,"legend","additionalItems"),i=t.getProperty(n,"legend","additionalItems");if(r&&i){var o=i.map((function(t){return t.type})),a=r.map((function(t){return t.type})),s=_t.filter((function(t){return a.includes(t.type)&&!o.includes(t.type)}));e.legend.additionalItems=s,n.legend.additionalItems=t.unionBy(s,i,"name")}}t.debounce=Bi,t.clone=fi,t.merge=Qi,t.unionBy=io,t.removeArrayDuplicates=oo,t.clamp=Sr,t.flatten=kn,t.camelCase=Er,t.isEmpty=Xi,t.isEqual=Ki,t.flatMapDeep=Yi,t.kebabCase=Ji,t.fromPairs=qi,t.some=eo,t.debounceWithD3MousePosition=function(t,e,n){var r=null;return function(){var i=this,o=arguments;i.mousePosition=_a(n),clearTimeout(r),r=setTimeout((function(){t.apply(i,o)}),e)}},t.mergeDefaultChartOptions=function(n,r){n=t.clone(n);var i=Object.keys(r.axes||{});for(var o in 0===i.length&&delete n.axes,n.axes)if(i.includes(o)){var a=r.axes[o];(a.primary||a.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 s=a.mapsTo;if(null==s){var u=a.scaleType;null==u?a.mapsTo="value":u===I.TIME?a.mapsTo="date":u===I.LABELS&&(a.mapsTo="key")}}else delete n.axes[o];return e(n,r),t.merge(n,r)},t.getDimensions=function(t){return{width:parseFloat(t.style.width.replace("px","")||t.offsetWidth),height:parseFloat(t.style.height.replace("px","")||t.offsetHeight)}},t.getTranslationValues=function(t){if(t){var e=t.getAttribute("transform").match(/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/);if(!e)return null;if(e[0]){var n=e[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:n[0],ty:n[1]}}return null}},t.getTranformOffsets=function(t){var e=/\(([^)]+)\)/.exec(t)[1].split(",");return{x:parseFloat(e[0]),y:parseFloat(e[1])}},t.formatWidthHeightValues=function(t){var e=t.toString();return e.match(/[a-z]/i)?e:e+"px"},t.capitalizeFirstLetter=function(t){return t[0].toUpperCase()+t.slice(1)},t.convertValueToPercentage=function(t,e){var n=t/e.reduce((function(t,e){return t+e.value}),0)*100;return n%1!=0?parseFloat(n.toFixed(1)):n},t.truncateLabel=function(t,e,n){return n>t.length?t:e===L.MID_LINE?t.substr(0,n/2)+"..."+t.substr(-n/2):e===L.FRONT_LINE?"..."+t.substr(-n):e===L.END_LINE?t.substr(0,n)+"...":void 0},t.updateLegendAdditionalItems=e,t.arrayDifferences=function(t,e){var n={missing:[],added:[]};return t.forEach((function(t){-1===e.indexOf(t)&&n.missing.push(t)})),e.forEach((function(e){-1===t.indexOf(e)&&n.added.push(e)})),n},t.getDuplicateValues=function(t){var e=[],n=[];return t.forEach((function(t){-1!==e.indexOf(t)&&-1===n.indexOf(t)&&n.push(t),e.push(t)})),n},t.moveToFront=function(t){return t.each((function(){this.parentNode.appendChild(this)}))},t.getProperty=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},t.flipSVGCoordinatesBasedOnOrientation=function(t,e){return e===R.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},t.generateSVGPathString=function(e,n){var r=t.flipSVGCoordinatesBasedOnOrientation(e,n),i=r.x0,o=r.x1,a=r.y0,s=r.y1;return"M"+i+","+a+"L"+i+","+s+"L"+o+","+s+"L"+o+","+a+"L"+i+","+a},t.flipDomainAndRangeBasedOnOrientation=function(t,e,n){return n===R.VERTICAL?[t,e]:[e,t]},t.compareNumeric=function(t,e){return Number(t)===Number(e)}}(da||(da={}));var wa="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Oa(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function xa(t,e){return t(e={exports:{}},e.exports),e.exports}var Ea=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e,r){var i;r=r||{},i="string"==typeof n[t]?n[t]:1===e?n[t].one:n[t].other.replace("{{count}}",e);if(r.addSuffix)return r.comparison>0?"in "+i:i+" ago";return i};var n={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"}};t.exports=e.default}));Oa(Ea);var Sa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth;return t.formats[r]||t.formats[t.defaultWidth]}},t.exports=e.default}));Oa(Sa);var Ta=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n,r=(n=Sa)&&n.__esModule?n:{default:n};var i={date:(0,r.default)({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:(0,r.default)({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:(0,r.default)({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})};e.default=i,t.exports=e.default}));Oa(Ta);var Ma=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e,r,i){return n[t]};var n={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};t.exports=e.default}));Oa(Ma);var Ca=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return function(e,n){var r,i=n||{};if("formatting"===(i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,a=i.width?String(i.width):o;r=t.formattingValues[a]||t.formattingValues[o]}else{var s=t.defaultWidth,u=i.width?String(i.width):t.defaultWidth;r=t.values[u]||t.values[s]}return r[t.argumentCallback?t.argumentCallback(e):e]}},t.exports=e.default}));Oa(Ca);var Da=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n,r=(n=Ca)&&n.__esModule?n:{default:n};var i={ordinalNumber:function(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"},era:(0,r.default)({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:(0,r.default)({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:(0,r.default)({values:{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"]},defaultWidth:"wide"}),day:(0,r.default)({values:{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"]},defaultWidth:"wide"}),dayPeriod:(0,r.default)({values:{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"}},defaultWidth:"wide",formattingValues:{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"}},defaultFormattingWidth:"wide"})};e.default=i,t.exports=e.default}));Oa(Da);var Pa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(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{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(a.length)}}},t.exports=e.default}));Oa(Pa);var Aa=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(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)?function(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}(c,(function(t){return t.test(r)})):function(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(l.length)}}},t.exports=e.default}));Oa(Aa);var ka=xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(Pa),r=i(Aa);function i(t){return t&&t.__esModule?t:{default:t}}var o={ordinalNumber:(0,n.default)({matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}}),era:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:(0,r.default)({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),day:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),dayPeriod:(0,r.default)({matchPatterns:{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},defaultMatchWidth:"any",parsePatterns:{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}},defaultParseWidth:"any"})};e.default=o,t.exports=e.default}));Oa(ka);var La=Oa(xa((function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=s(Ea),r=s(Ta),i=s(Ma),o=s(Da),a=s(ka);function s(t){return t&&t.__esModule?t:{default:t}}var u={code:"en-US",formatDistance:n.default,formatLong:r.default,formatRelative:i.default,localize:o.default,match:a.default,options:{weekStartsOn:0,firstWeekContainsDate:1}};e.default=u,t.exports=e.default}))),Ra={type:L.END_LINE,threshold:16,numCharacter:14},Ia={enabled:!0,position:N.BOTTOM,clickable:!0,truncation:Ra,alignment:j.LEFT,order:null,additionalItems:[]},Na={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},ja={enabled:!0},Ba={enabled:!0,showTotal:!0,truncation:Ra,groupLabel:"Group"},Va={top:{visible:!0,includeZero:!0,truncation:Ra},bottom:{visible:!0,includeZero:!0,truncation:Ra},left:{visible:!0,includeZero:!0,truncation:Ra},right:{visible:!0,includeZero:!0,truncation:Ra}},Ha={addSpaceOnEdges:1,showDayName:!1,localeObject:La,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"}}},Ua="undefined"!=typeof document&&(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled),Fa={width:null,height:null,resizable:!0,tooltip:Ba,legend:Ia,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:M([{type:$.SHOW_AS_DATATABLE}],Ua?[{type:$.MAKE_FULLSCREEN}]:[],[{type:$.EXPORT_CSV},{type:$.EXPORT_PNG},{type:$.EXPORT_JPG}])}},Ga=da.merge({},Fa,{axes:Va,timeScale:Ha,grid:Na,ruler:ja,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:k.GRAPH_VIEW}}}),za=da.merge({},Ga,{bars:{maxWidth:16},timeScale:da.merge(Ha,{addSpaceOnEdges:1})}),Wa=da.merge({},za,{}),Ya=da.merge({},za,{}),qa=da.merge({},za,{bars:da.merge({},za.bars,{dividerSize:1.5})}),Za=da.merge({},za,{}),Xa=da.merge({},Ga,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),Ka=Xa,$a=da.merge({},Xa,{points:{radius:3,filled:!1,enabled:!0}}),Ja=da.merge({},$a,{timeScale:da.merge(Ha,{addSpaceOnEdges:0})}),Qa=Ja,ts=da.merge({},Ga,{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:Q.RADIUS,name:"Radius"}]}}),es=da.merge({},Ga,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:Q.AREA,name:"Poor area"},{type:Q.AREA,name:"Satisfactory area"},{type:Q.AREA,name:"Great area"},{type:Q.QUARTILE,name:"Quartiles"}]}}),ns=da.merge({},Fa,{tooltip:da.merge({},Ba,{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"}}),rs=da.merge({},Fa,{pie:{labels:{formatter:null,enabled:!0},alignment:j.LEFT,sortFunction:null}}),is=da.merge({},Fa,{legend:{enabled:!1},gauge:{type:Y.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:j.LEFT}}),os={chart:Fa,axisChart:Ga,simpleBarChart:Wa,groupedBarChart:Ya,stackedBarChart:qa,boxplotChart:Za,bubbleChart:ts,bulletChart:es,lineChart:$a,areaChart:Ja,stackedAreaChart:Qa,scatterChart:Xa,lollipopChart:Ka,pieChart:rs,donutChart:da.merge({},rs,{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:j.LEFT}}),meterChart:da.merge({},Fa,{legend:{enabled:!1},meter:{height:8,statusBar:{percentageIndicator:{enabled:!0}}}}),radarChart:da.merge({},Fa,{radar:{axes:{angle:"key",value:"value"},alignment:j.LEFT},tooltip:{gridline:{enabled:!0},valueFormatter:function(t){return null!=t?t:"N/A"}}}),gaugeChart:is,comboChart:da.merge({},za,{comboChartTypes:[]}),treemapChart:da.merge({},Fa,{data:da.merge(Fa.data,{groupMapsTo:"name"})}),circlePackChart:da.merge({},Fa,ut,{data:da.merge(Fa.data,{groupMapsTo:"name"})}),wordCloudChart:ns},as=Object.freeze({__proto__:null,grid:Na,ruler:ja,baseTooltip:Ba,timeScale:Ha,options:os,area:ot,axis:at,canvasZoomSettings:st,circlePack:ut,color:lt,boxplot:ct,legend:ft,lines:ht,meter:dt,pie:pt,radar:gt,spacers:mt,tooltips:vt,transitions:yt,toolbar:{buttonSize:32,iconSize:20,height:32,spacerHeight:10,iconPadding:6},zoomBar:bt,defaultLegendAdditionalItems:_t});function ss(){}function us(t,e){var n=new ss;if(t instanceof ss)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==e)for(;++i<o;)n.set(i,t[i]);else for(;++i<o;)n.set(e(r=t[i],i,t),r)}else if(t)for(var a in t)n.set(a,t[a]);return n}function ls(){}ss.prototype=us.prototype={constructor:ss,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var cs=us.prototype;function fs(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function hs(t){var e;return 1===t.length&&(e=t,t=function(t,n){return fs(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)<0?r=o+1:i=o}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)>0?i=o:r=o+1}return r}}}ls.prototype=function(t,e){var n=new ls;if(t instanceof ls)t.each((function(t){n.add(t)}));else if(t){var r=-1,i=t.length;if(null==e)for(;++r<i;)n.add(t[r]);else for(;++r<i;)n.add(e(t[r],r,t))}return n}.prototype={constructor:ls,has:cs.has,add:function(t){return this["$"+(t+="")]=t,this},remove:cs.remove,clear:cs.clear,values:cs.keys,size:cs.size,empty:cs.empty,each:cs.each};var ds=hs(fs).right;function ps(t){return null===t?NaN:+t}function gs(t,e){var n,r,i,o=t.length,a=-1;if(null==e){for(;++a<o;)if(null!=(n=t[a])&&n>=n)for(r=i=n;++a<o;)null!=(n=t[a])&&(r>n&&(r=n),i<n&&(i=n))}else for(;++a<o;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=i=n;++a<o;)null!=(n=e(t[a],a,t))&&(r>n&&(r=n),i<n&&(i=n));return[r,i]}function ms(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}var vs=Math.sqrt(50),ys=Math.sqrt(10),bs=Math.sqrt(2);function _s(t,e,n){var r,i,o,a,s=-1;if(n=+n,(t=+t)===(e=+e)&&n>0)return[t];if((r=e<t)&&(i=t,t=e,e=i),0===(a=ws(t,e,n))||!isFinite(a))return[];if(a>0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(i=Math.ceil(e-t+1));++s<i;)o[s]=(t+s)*a;else for(t=Math.floor(t*a),e=Math.ceil(e*a),o=new Array(i=Math.ceil(t-e+1));++s<i;)o[s]=(t-s)/a;return r&&o.reverse(),o}function ws(t,e,n){var r=(e-t)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),o=r/Math.pow(10,i);return i>=0?(o>=vs?10:o>=ys?5:o>=bs?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=vs?10:o>=ys?5:o>=bs?2:1)}function Os(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=vs?i*=10:o>=ys?i*=5:o>=bs&&(i*=2),e<t?-i:i}function xs(t,e,n){if(null==n&&(n=ps),r=t.length){if((e=+e)<=0||r<2)return+n(t[0],0,t);if(e>=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,o=Math.floor(i),a=+n(t[o],o,t);return a+(+n(t[o+1],o+1,t)-a)*(i-o)}}function Es(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&n>r&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&n>r&&(r=n);return r}function Ss(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&r>n&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&r>n&&(r=n);return r}function Ts(t,e){var n,r=t.length,i=-1,o=0;if(null==e)for(;++i<r;)(n=+t[i])&&(o+=n);else for(;++i<r;)(n=+e(t[i],i,t))&&(o+=n);return o}function Ms(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}var Cs=Array.prototype,Ds=Cs.map,Ps=Cs.slice,As={name:"implicit"};function ks(){var t=us(),e=[],n=[],r=As;function i(i){var o=i+"",a=t.get(o);if(!a){if(r!==As)return r;t.set(o,a=e.push(i))}return n[(a-1)%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=us();for(var r,o,a=-1,s=n.length;++a<s;)t.has(o=(r=n[a])+"")||t.set(o,e.push(r));return i},i.range=function(t){return arguments.length?(n=Ps.call(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return ks(e,n).unknown(r)},Ms.apply(i,arguments),i}function Ls(){var t,e,n=ks().unknown(void 0),r=n.domain,i=n.range,o=[0,1],a=!1,s=0,u=0,l=.5;function c(){var n=r().length,c=o[1]<o[0],f=o[c-0],h=o[1-c];t=(h-f)/Math.max(1,n-s+2*u),a&&(t=Math.floor(t)),f+=(h-f-t*(n-s))*l,e=t*(1-s),a&&(f=Math.round(f),e=Math.round(e));var d=ms(n).map((function(e){return f+t*e}));return i(c?d.reverse():d)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),c()):r()},n.range=function(t){return arguments.length?(o=[+t[0],+t[1]],c()):o.slice()},n.rangeRound=function(t){return o=[+t[0],+t[1]],a=!0,c()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(a=!!t,c()):a},n.padding=function(t){return arguments.length?(s=Math.min(1,u=+t),c()):s},n.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),c()):s},n.paddingOuter=function(t){return arguments.length?(u=+t,c()):u},n.align=function(t){return arguments.length?(l=Math.max(0,Math.min(1,t)),c()):l},n.copy=function(){return Ls(r(),o).round(a).paddingInner(s).paddingOuter(u).align(l)},Ms.apply(c(),arguments)}function Rs(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Is(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Ns(){}var js="\\s*([+-]?\\d+)\\s*",Bs="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Vs="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Hs=/^#([0-9a-f]{3,8})$/,Us=new RegExp("^rgb\\("+[js,js,js]+"\\)$"),Fs=new RegExp("^rgb\\("+[Vs,Vs,Vs]+"\\)$"),Gs=new RegExp("^rgba\\("+[js,js,js,Bs]+"\\)$"),zs=new RegExp("^rgba\\("+[Vs,Vs,Vs,Bs]+"\\)$"),Ws=new RegExp("^hsl\\("+[Bs,Vs,Vs]+"\\)$"),Ys=new RegExp("^hsla\\("+[Bs,Vs,Vs,Bs]+"\\)$"),qs={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 Zs(){return this.rgb().formatHex()}function Xs(){return this.rgb().formatRgb()}function Ks(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=Hs.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?$s(e):3===n?new eu(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?new eu(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?new eu(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=Us.exec(t))?new eu(e[1],e[2],e[3],1):(e=Fs.exec(t))?new eu(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Gs.exec(t))?Js(e[1],e[2],e[3],e[4]):(e=zs.exec(t))?Js(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=Ws.exec(t))?ou(e[1],e[2]/100,e[3]/100,1):(e=Ys.exec(t))?ou(e[1],e[2]/100,e[3]/100,e[4]):qs.hasOwnProperty(t)?$s(qs[t]):"transparent"===t?new eu(NaN,NaN,NaN,0):null}function $s(t){return new eu(t>>16&255,t>>8&255,255&t,1)}function Js(t,e,n,r){return r<=0&&(t=e=n=NaN),new eu(t,e,n,r)}function Qs(t){return t instanceof Ns||(t=Ks(t)),t?new eu((t=t.rgb()).r,t.g,t.b,t.opacity):new eu}function tu(t,e,n,r){return 1===arguments.length?Qs(t):new eu(t,e,n,null==r?1:r)}function eu(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function nu(){return"#"+iu(this.r)+iu(this.g)+iu(this.b)}function ru(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function iu(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function ou(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new uu(t,e,n,r)}function au(t){if(t instanceof uu)return new uu(t.h,t.s,t.l,t.opacity);if(t instanceof Ns||(t=Ks(t)),!t)return new uu;if(t instanceof uu)return t;var e=(t=t.rgb()).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 uu(a,s,u,t.opacity)}function su(t,e,n,r){return 1===arguments.length?au(t):new uu(t,e,n,null==r?1:r)}function uu(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function lu(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 cu(t){return function(){return t}}function fu(t){return 1==(t=+t)?hu:function(e,n){return n-e?function(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)}}(e,n,t):cu(isNaN(e)?n:e)}}function hu(t,e){var n=e-t;return n?function(t,e){return function(n){return t+n*e}}(t,n):cu(isNaN(t)?e:t)}Rs(Ns,Ks,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:Zs,formatHex:Zs,formatHsl:function(){return au(this).formatHsl()},formatRgb:Xs,toString:Xs}),Rs(eu,tu,Is(Ns,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new eu(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new eu(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){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:nu,formatHex:nu,formatRgb:ru,toString:ru})),Rs(uu,su,Is(Ns,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new uu(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new uu(this.h,this.s,this.l*t,this.opacity)},rgb:function(){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 eu(lu(t>=240?t-240:t+120,i,r),lu(t,i,r),lu(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var du=function t(e){var n=fu(e);function r(t,e){var r=n((t=tu(t)).r,(e=tu(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=hu(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 pu(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 gu(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]=Ou(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}}function mu(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function vu(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function yu(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]=Ou(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var bu=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,_u=new RegExp(bu.source,"g");function wu(t,e){var n,r,i,o=bu.lastIndex=_u.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=bu.exec(t))&&(r=_u.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:vu(n,r)})),o=_u.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(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("")})}function Ou(t,e){var n,r=typeof e;return null==e||"boolean"===r?cu(e):("number"===r?vu:"string"===r?(n=Ks(e))?(e=n,du):wu:e instanceof Ks?du:e instanceof Date?mu:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}(e)?pu:Array.isArray(e)?gu:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?yu:vu)(t,e)}function xu(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}var Eu,Su,Tu,Mu,Cu=180/Math.PI,Du={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Pu(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)*Cu,skewX:Math.atan(u)*Cu,scaleX:a,scaleY:s}}function Au(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(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:vu(t,i)},{i:u-2,x:vu(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(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:vu(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:vu(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(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:vu(t,n)},{i:s-2,x:vu(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var ku=Au((function(t){return"none"===t?Du:(Eu||(Eu=document.createElement("DIV"),Su=document.documentElement,Tu=document.defaultView),Eu.style.transform=t,t=Tu.getComputedStyle(Su.appendChild(Eu),null).getPropertyValue("transform"),Su.removeChild(Eu),Pu(+(t=t.slice(7,-1).split(","))[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),Lu=Au((function(t){return null==t?Du:(Mu||(Mu=document.createElementNS("http://www.w3.org/2000/svg","g")),Mu.setAttribute("transform",t),(t=Mu.transform.baseVal.consolidate())?Pu((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Du)}),", ",")",")");function Ru(t){return+t}var Iu=[0,1];function Nu(t){return t}function ju(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function Bu(t){var e,n=t[0],r=t[t.length-1];return n>r&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function Vu(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=ju(i,r),o=n(a,o)):(r=ju(r,i),o=n(o,a)),function(t){return o(r(t))}}function Hu(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=ju(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=ds(t,e,1,r)-1;return o[n](i[n](e))}}function Uu(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Fu(){var t,e,n,r,i,o,a=Iu,s=Iu,u=Ou,l=Nu;function c(){return r=Math.min(a.length,s.length)>2?Hu:Vu,i=o=null,f}function f(e){return isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return f.invert=function(n){return l(e((o||(o=r(s,a.map(t),vu)))(n)))},f.domain=function(t){return arguments.length?(a=Ds.call(t,Ru),l===Nu||(l=Bu(a)),c()):a.slice()},f.range=function(t){return arguments.length?(s=Ps.call(t),c()):s.slice()},f.rangeRound=function(t){return s=Ps.call(t),u=xu,c()},f.clamp=function(t){return arguments.length?(l=t?Bu(a):Nu,f):l!==Nu},f.interpolate=function(t){return arguments.length?(u=t,c()):u},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,c()}}function Gu(t,e){return Fu()(t,e)}function zu(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)]}function Wu(t){return(t=zu(Math.abs(t)))?t[1]:NaN}var Yu,qu=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Zu(t){if(!(e=qu.exec(t)))throw new Error("invalid format: "+t);var e;return new Xu({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 Xu(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+""}function Ku(t,e){var n=zu(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")}Zu.prototype=Xu.prototype,Xu.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 $u={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return Ku(100*t,e)},r:Ku,s:function(t,e){var n=zu(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(Yu=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")+zu(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function Ju(t){return t}var Qu,tl,el,nl=Array.prototype.map,rl=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function il(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?Ju:(e=nl.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Ju:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(nl.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=Zu(t)).fill,n=t.align,f=t.sign,h=t.symbol,d=t.zero,p=t.width,g=t.comma,m=t.precision,v=t.trim,y=t.type;"n"===y?(g=!0,y="g"):$u[y]||(void 0===m&&(m=12),v=!0,y="g"),(d||"0"===e&&"="===n)&&(d=!0,e="0",n="=");var b="$"===h?i:"#"===h&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",_="$"===h?o:/[%p]/.test(y)?u:"",w=$u[y],O=/[defgprs%]/.test(y);function x(t){var i,o,u,h=b,x=_;if("c"===y)x=w(t)+x,t="";else{var E=(t=+t)<0;if(t=isNaN(t)?c:w(Math.abs(t),m),v&&(t=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)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),E&&0==+t&&(E=!1),h=(E?"("===f?f:l:"-"===f||"("===f?"":f)+h,x=("s"===y?rl[8+Yu/3]:"")+x+(E&&"("===f?")":""),O)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){x=(46===u?a+t.slice(i+1):t.slice(i))+x,t=t.slice(0,i);break}}g&&!d&&(t=r(t,1/0));var S=h.length+t.length+x.length,T=S<p?new Array(p-S+1).join(e):"";switch(g&&d&&(t=r(T+t,T.length?p-x.length:1/0),T=""),n){case"<":t=h+t+x+T;break;case"=":t=h+T+t+x;break;case"^":t=T.slice(0,S=T.length>>1)+h+t+x+T.slice(S);break;default:t=T+h+t+x}return s(t)}return m=void 0===m?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,m)):Math.max(0,Math.min(20,m)),x.toString=function(){return t+""},x}return{format:f,formatPrefix:function(t,e){var n=f(((t=Zu(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(Wu(e)/3))),i=Math.pow(10,-r),o=rl[8+r/3];return function(t){return n(i*t)+o}}}}function ol(t,e,n,r){var i,o=Os(t,e,n);switch((r=Zu(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Wu(e)/3)))-Wu(Math.abs(t)))}(o,a))||(r.precision=i),el(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Wu(e)-Wu(t))+1}(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(t){return Math.max(0,-Wu(Math.abs(t)))}(o))||(r.precision=i-2*("%"===r.type))}return tl(r)}function al(t){var e=t.domain;return t.ticks=function(t){var n=e();return _s(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return ol(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),o=0,a=i.length-1,s=i[o],u=i[a];return u<s&&(r=s,s=u,u=r,r=o,o=a,a=r),(r=ws(s,u,n))>0?r=ws(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=ws(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(u/r)*r,e(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(u*r)/r,e(i)),t},t}function sl(){var t=Gu(Nu,Nu);return t.copy=function(){return Uu(t,sl())},Ms.apply(t,arguments),al(t)}function ul(t,e){var n,r=0,i=(t=t.slice()).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 ll(t){return Math.log(t)}function cl(t){return Math.exp(t)}function fl(t){return-Math.log(-t)}function hl(t){return-Math.exp(-t)}function dl(t){return isFinite(t)?+("1e"+t):t<0?0:t}function pl(t){return function(e){return-t(-e)}}function gl(t){var e,n,r=t(ll,cl),i=r.domain,o=10;function a(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(o),n=function(t){return 10===t?dl:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(o),i()[0]<0?(e=pl(e),n=pl(n),t(fl,hl)):t(ll,cl),r}return r.base=function(t){return arguments.length?(o=+t,a()):o},r.domain=function(t){return arguments.length?(i(t),a()):i()},r.ticks=function(t){var r,a=i(),s=a[0],u=a[a.length-1];(r=u<s)&&(h=s,s=u,u=h);var l,c,f,h=e(s),d=e(u),p=null==t?10:+t,g=[];if(!(o%1)&&d-h<p){if(h=Math.round(h)-1,d=Math.round(d)+1,s>0){for(;h<d;++h)for(c=1,l=n(h);c<o;++c)if(!((f=l*c)<s)){if(f>u)break;g.push(f)}}else for(;h<d;++h)for(c=o-1,l=n(h);c>=1;--c)if(!((f=l*c)<s)){if(f>u)break;g.push(f)}}else g=_s(h,d,Math.min(d-h,p)).map(n);return r?g.reverse():g},r.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=tl(i)),t===1/0)return i;null==t&&(t=10);var a=Math.max(1,o*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*o<o-.5&&(r*=o),r<=a?i(t):""}},r.nice=function(){return i(ul(i(),{floor:function(t){return n(Math.floor(e(t)))},ceil:function(t){return n(Math.ceil(e(t)))}}))},r}Qu=il({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),tl=Qu.format,el=Qu.formatPrefix;var ml=new Date,vl=new Date;function yl(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},i.round=function(t){var e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},i.range=function(n,r,o){var a,s=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<r);return s},i.filter=function(n){return yl((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return ml.setTime(+e),vl.setTime(+r),t(ml),t(vl),Math.floor(n(ml,vl))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var bl=yl((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));bl.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?yl((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):bl:null};var _l=yl((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),wl=yl((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),Ol=yl((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),xl=yl((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1}));function El(t){return yl((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var Sl=El(0),Tl=El(1),Ml=(El(2),El(3),El(4)),Cl=(El(5),El(6),yl((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}))),Dl=yl((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));Dl.every=function(t){return isFinite(t=Math.floor(t))&&t>0?yl((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var Pl=yl((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}));function Al(t){return yl((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var kl=Al(0),Ll=Al(1),Rl=(Al(2),Al(3),Al(4)),Il=(Al(5),Al(6),yl((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()})));function Nl(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 jl(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 Bl(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}Il.every=function(t){return isFinite(t=Math.floor(t))&&t>0?yl((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var Vl,Hl,Ul={"-":"",_:" ",0:"0"},Fl=/^\s*\d+/,Gl=/^%/,zl=/[\\^$*+?|[\]().{}]/g;function Wl(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 Yl(t){return t.replace(zl,"\\$&")}function ql(t){return new RegExp("^(?:"+t.map(Yl).join("|")+")","i")}function Zl(t){for(var e={},n=-1,r=t.length;++n<r;)e[t[n].toLowerCase()]=n;return e}function Xl(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function Kl(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function $l(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function Jl(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Ql(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function tc(t,e,n){var r=Fl.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function ec(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function nc(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 rc(t,e,n){var r=Fl.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function ic(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function oc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ac(t,e,n){var r=Fl.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function sc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function uc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function lc(t,e,n){var r=Fl.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function cc(t,e,n){var r=Fl.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function fc(t,e,n){var r=Fl.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function hc(t,e,n){var r=Gl.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function dc(t,e,n){var r=Fl.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function pc(t,e,n){var r=Fl.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function gc(t,e){return Wl(t.getDate(),e,2)}function mc(t,e){return Wl(t.getHours(),e,2)}function vc(t,e){return Wl(t.getHours()%12||12,e,2)}function yc(t,e){return Wl(1+xl.count(Dl(t),t),e,3)}function bc(t,e){return Wl(t.getMilliseconds(),e,3)}function _c(t,e){return bc(t,e)+"000"}function wc(t,e){return Wl(t.getMonth()+1,e,2)}function Oc(t,e){return Wl(t.getMinutes(),e,2)}function xc(t,e){return Wl(t.getSeconds(),e,2)}function Ec(t){var e=t.getDay();return 0===e?7:e}function Sc(t,e){return Wl(Sl.count(Dl(t)-1,t),e,2)}function Tc(t,e){var n=t.getDay();return t=n>=4||0===n?Ml(t):Ml.ceil(t),Wl(Ml.count(Dl(t),t)+(4===Dl(t).getDay()),e,2)}function Mc(t){return t.getDay()}function Cc(t,e){return Wl(Tl.count(Dl(t)-1,t),e,2)}function Dc(t,e){return Wl(t.getFullYear()%100,e,2)}function Pc(t,e){return Wl(t.getFullYear()%1e4,e,4)}function Ac(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Wl(e/60|0,"0",2)+Wl(e%60,"0",2)}function kc(t,e){return Wl(t.getUTCDate(),e,2)}function Lc(t,e){return Wl(t.getUTCHours(),e,2)}function Rc(t,e){return Wl(t.getUTCHours()%12||12,e,2)}function Ic(t,e){return Wl(1+Pl.count(Il(t),t),e,3)}function Nc(t,e){return Wl(t.getUTCMilliseconds(),e,3)}function jc(t,e){return Nc(t,e)+"000"}function Bc(t,e){return Wl(t.getUTCMonth()+1,e,2)}function Vc(t,e){return Wl(t.getUTCMinutes(),e,2)}function Hc(t,e){return Wl(t.getUTCSeconds(),e,2)}function Uc(t){var e=t.getUTCDay();return 0===e?7:e}function Fc(t,e){return Wl(kl.count(Il(t)-1,t),e,2)}function Gc(t,e){var n=t.getUTCDay();return t=n>=4||0===n?Rl(t):Rl.ceil(t),Wl(Rl.count(Il(t),t)+(4===Il(t).getUTCDay()),e,2)}function zc(t){return t.getUTCDay()}function Wc(t,e){return Wl(Ll.count(Il(t)-1,t),e,2)}function Yc(t,e){return Wl(t.getUTCFullYear()%100,e,2)}function qc(t,e){return Wl(t.getUTCFullYear()%1e4,e,4)}function Zc(){return"+0000"}function Xc(){return"%"}function Kc(t){return+t}function $c(t){return Math.floor(+t/1e3)}!function(t){Vl=function(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=ql(i),c=Zl(i),f=ql(o),h=Zl(o),d=ql(a),p=Zl(a),g=ql(s),m=Zl(s),v=ql(u),y=Zl(u),b={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:gc,e:gc,f:_c,H:mc,I:vc,j:yc,L:bc,m:wc,M:Oc,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Kc,s:$c,S:xc,u:Ec,U:Sc,V:Tc,w:Mc,W:Cc,x:null,X:null,y:Dc,Y:Pc,Z:Ac,"%":Xc},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:kc,e:kc,f:jc,H:Lc,I:Rc,j:Ic,L:Nc,m:Bc,M:Vc,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Kc,s:$c,S:Hc,u:Uc,U:Fc,V:Gc,w:zc,W:Wc,x:null,X:null,y:Yc,Y:qc,Z:Zc,"%":Xc},w={a:function(t,e,n){var r=d.exec(e.slice(n));return r?(t.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=y[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=g.exec(e.slice(n));return r?(t.m=m[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return E(t,e,n,r)},d:oc,e:oc,f:fc,H:sc,I:sc,j:ac,L:cc,m:ic,M:uc,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c[r[0].toLowerCase()],n+r[0].length):-1},q:rc,Q:dc,s:pc,S:lc,u:Kl,U:$l,V:Jl,w:Xl,W:Ql,x:function(t,e,r){return E(t,n,e,r)},X:function(t,e,n){return E(t,r,e,n)},y:ec,Y:tc,Z:nc,"%":hc};function O(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Ul[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=Bl(1900,void 0,1);if(E(o,t,n+="",0)!=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?(i=(r=jl(Bl(o.y,0,1))).getUTCDay(),r=i>4||0===i?Ll.ceil(r):Ll(r),r=Pl.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=Nl(Bl(o.y,0,1))).getDay(),r=i>4||0===i?Tl.ceil(r):Tl(r),r=xl.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?jl(Bl(o.y,0,1)).getUTCDay():Nl(Bl(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,jl(o)):Nl(o)}}function E(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=w[i in Ul?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return(b.x=O(n,b),b.X=O(r,b),b.c=O(e,b),_.x=O(n,_),_.X=O(r,_),_.c=O(e,_),{format:function(t){var e=O(t+="",b);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+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=x(t+="",!0);return e.toString=function(){return t},e}})}(t),Hl=Vl.format,Vl.parse,Vl.utcFormat,Vl.utcParse}({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"]});function Jc(t){return new Date(t)}function Qc(t){return t instanceof Date?+t:+new Date(+t)}function tf(t,e,n,r,i,o,a,s,u){var l=Gu(Nu,Nu),c=l.invert,f=l.domain,h=u(".%L"),d=u(":%S"),p=u("%I:%M"),g=u("%I %p"),m=u("%a %d"),v=u("%b %d"),y=u("%B"),b=u("%Y"),_=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function w(s){return(a(s)<s?h:o(s)<s?d:i(s)<s?p:r(s)<s?g:e(s)<s?n(s)<s?m:v:t(s)<s?y:b)(s)}function O(e,n,r,i){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(r-n)/e,a=hs((function(t){return t[2]})).right(_,o);a===_.length?(i=Os(n/31536e6,r/31536e6,e),e=t):a?(i=(a=_[o/_[a-1][2]<_[a][2]/o?a-1:a])[1],e=a[0]):(i=Math.max(Os(n,r,e),1),e=s)}return null==i?e:e.every(i)}return l.invert=function(t){return new Date(c(t))},l.domain=function(t){return arguments.length?f(Ds.call(t,Qc)):f().map(Jc)},l.ticks=function(t,e){var n,r=f(),i=r[0],o=r[r.length-1],a=o<i;return a&&(n=i,i=o,o=n),n=(n=O(t,i,o,e))?n.range(i,o+1):[],a?n.reverse():n},l.tickFormat=function(t,e){return null==e?w:u(e)},l.nice=function(t,e){var n=f();return(t=O(t,n[0],n[n.length-1],e))?f(ul(n,t)):l},l.copy=function(){return Uu(l,tf(t,e,n,r,i,o,a,s,u))},l}function ef(){return Ms.apply(tf(Dl,Cl,Sl,xl,Ol,wl,_l,bl,Hl).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var nf=Math.PI,rf=2*nf,of=rf-1e-6;function af(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function sf(){return new af}function uf(t){return function(){return t}}af.prototype=sf.prototype={constructor:af,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,f=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(f>1e-6)if(Math.abs(c*s-u*l)>1e-6&&i){var h=n-o,d=r-a,p=s*s+u*u,g=h*h+d*d,m=Math.sqrt(p),v=Math.sqrt(f),y=i*Math.tan((nf-Math.acos((p+f-g)/(2*m*v)))/2),b=y/v,_=y/m;Math.abs(b-1)>1e-6&&(this._+="L"+(t+b*l)+","+(e+b*c)),this._+="A"+i+","+i+",0,0,"+ +(c*h>l*d)+","+(this._x1=t+_*s)+","+(this._y1=e+_*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,o=!!o;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,f=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)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(f<0&&(f=f%rf+rf),f>of?this._+="A"+n+","+n+",0,1,"+c+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):f>1e-6&&(this._+="A"+n+","+n+",0,"+ +(f>=nf)+","+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 lf=Math.abs,cf=Math.atan2,ff=Math.cos,hf=Math.max,df=Math.min,pf=Math.sin,gf=Math.sqrt,mf=Math.PI,vf=mf/2,yf=2*mf;function bf(t){return t>1?0:t<-1?mf:Math.acos(t)}function _f(t){return t>=1?vf:t<=-1?-vf:Math.asin(t)}function wf(t){return t.innerRadius}function Of(t){return t.outerRadius}function xf(t){return t.startAngle}function Ef(t){return t.endAngle}function Sf(t){return t&&t.padAngle}function Tf(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,f=s-o,h=f*u-c*l;if(!(h*h<1e-12))return[t+(h=(c*(e-o)-f*(t-i))/h)*u,e+h*l]}function Mf(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/gf(s*s+u*u),c=l*u,f=-l*s,h=t+c,d=e+f,p=n+c,g=r+f,m=(h+p)/2,v=(d+g)/2,y=p-h,b=g-d,_=y*y+b*b,w=i-o,O=h*g-p*d,x=(b<0?-1:1)*gf(hf(0,w*w*_-O*O)),E=(O*b-y*x)/_,S=(-O*y-b*x)/_,T=(O*b+y*x)/_,M=(-O*y+b*x)/_,C=E-m,D=S-v,P=T-m,A=M-v;return C*C+D*D>P*P+A*A&&(E=T,S=M),{cx:E,cy:S,x01:-c,y01:-f,x11:E*(i/w-1),y11:S*(i/w-1)}}function Cf(){var t=wf,e=Of,n=uf(0),r=null,i=xf,o=Ef,a=Sf,s=null;function u(){var u,l,c=+t.apply(this,arguments),f=+e.apply(this,arguments),h=i.apply(this,arguments)-vf,d=o.apply(this,arguments)-vf,p=lf(d-h),g=d>h;if(s||(s=u=sf()),f<c&&(l=f,f=c,c=l),f>1e-12)if(p>yf-1e-12)s.moveTo(f*ff(h),f*pf(h)),s.arc(0,0,f,h,d,!g),c>1e-12&&(s.moveTo(c*ff(d),c*pf(d)),s.arc(0,0,c,d,h,g));else{var m,v,y=h,b=d,_=h,w=d,O=p,x=p,E=a.apply(this,arguments)/2,S=E>1e-12&&(r?+r.apply(this,arguments):gf(c*c+f*f)),T=df(lf(f-c)/2,+n.apply(this,arguments)),M=T,C=T;if(S>1e-12){var D=_f(S/c*pf(E)),P=_f(S/f*pf(E));(O-=2*D)>1e-12?(_+=D*=g?1:-1,w-=D):(O=0,_=w=(h+d)/2),(x-=2*P)>1e-12?(y+=P*=g?1:-1,b-=P):(x=0,y=b=(h+d)/2)}var A=f*ff(y),k=f*pf(y),L=c*ff(w),R=c*pf(w);if(T>1e-12){var I,N=f*ff(b),j=f*pf(b),B=c*ff(_),V=c*pf(_);if(p<mf&&(I=Tf(A,k,B,V,N,j,L,R))){var H=A-I[0],U=k-I[1],F=N-I[0],G=j-I[1],z=1/pf(bf((H*F+U*G)/(gf(H*H+U*U)*gf(F*F+G*G)))/2),W=gf(I[0]*I[0]+I[1]*I[1]);M=df(T,(c-W)/(z-1)),C=df(T,(f-W)/(z+1))}}x>1e-12?C>1e-12?(m=Mf(B,V,A,k,f,C,g),v=Mf(N,j,L,R,f,C,g),s.moveTo(m.cx+m.x01,m.cy+m.y01),C<T?s.arc(m.cx,m.cy,C,cf(m.y01,m.x01),cf(v.y01,v.x01),!g):(s.arc(m.cx,m.cy,C,cf(m.y01,m.x01),cf(m.y11,m.x11),!g),s.arc(0,0,f,cf(m.cy+m.y11,m.cx+m.x11),cf(v.cy+v.y11,v.cx+v.x11),!g),s.arc(v.cx,v.cy,C,cf(v.y11,v.x11),cf(v.y01,v.x01),!g))):(s.moveTo(A,k),s.arc(0,0,f,y,b,!g)):s.moveTo(A,k),c>1e-12&&O>1e-12?M>1e-12?(m=Mf(L,R,N,j,c,-M,g),v=Mf(A,k,B,V,c,-M,g),s.lineTo(m.cx+m.x01,m.cy+m.y01),M<T?s.arc(m.cx,m.cy,M,cf(m.y01,m.x01),cf(v.y01,v.x01),!g):(s.arc(m.cx,m.cy,M,cf(m.y01,m.x01),cf(m.y11,m.x11),!g),s.arc(0,0,c,cf(m.cy+m.y11,m.cx+m.x11),cf(v.cy+v.y11,v.cx+v.x11),g),s.arc(v.cx,v.cy,M,cf(v.y11,v.x11),cf(v.y01,v.x01),!g))):s.arc(0,0,c,w,_,g):s.lineTo(L,R)}else s.moveTo(0,0);if(s.closePath(),u)return s=null,u+""||null}return u.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-mf/2;return[ff(r)*n,pf(r)*n]},u.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),u):t},u.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:uf(+t),u):e},u.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),u):n},u.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:uf(+t),u):r},u.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:uf(+t),u):i},u.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:uf(+t),u):o},u.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:uf(+t),u):a},u.context=function(t){return arguments.length?(s=null==t?null:t,u):s},u}function Df(t){this._context=t}function Pf(t){return new Df(t)}function Af(t){return t[0]}function kf(t){return t[1]}function Lf(){var t=Af,e=kf,n=uf(!0),r=null,i=Pf,o=null;function a(a){var s,u,l,c=a.length,f=!1;for(null==r&&(o=i(l=sf())),s=0;s<=c;++s)!(s<c&&n(u=a[s],s,a))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(u,s,a),+e(u,s,a));if(l)return o=null,l+""||null}return a.x=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),a):t},a.y=function(t){return arguments.length?(e="function"==typeof t?t:uf(+t),a):e},a.defined=function(t){return arguments.length?(n="function"==typeof t?t:uf(!!t),a):n},a.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),a):i},a.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),a):r},a}function Rf(){var t=Af,e=null,n=uf(0),r=kf,i=uf(!0),o=null,a=Pf,s=null;function u(u){var l,c,f,h,d,p=u.length,g=!1,m=new Array(p),v=new Array(p);for(null==o&&(s=a(d=sf())),l=0;l<=p;++l){if(!(l<p&&i(h=u[l],l,u))===g)if(g=!g)c=l,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=l-1;f>=c;--f)s.point(m[f],v[f]);s.lineEnd(),s.areaEnd()}g&&(m[l]=+t(h,l,u),v[l]=+n(h,l,u),s.point(e?+e(h,l,u):m[l],r?+r(h,l,u):v[l]))}if(d)return s=null,d+""||null}function l(){return Lf().defined(i).curve(a).context(o)}return u.x=function(n){return arguments.length?(t="function"==typeof n?n:uf(+n),e=null,u):t},u.x0=function(e){return arguments.length?(t="function"==typeof e?e:uf(+e),u):t},u.x1=function(t){return arguments.length?(e=null==t?null:"function"==typeof t?t:uf(+t),u):e},u.y=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),r=null,u):n},u.y0=function(t){return arguments.length?(n="function"==typeof t?t:uf(+t),u):n},u.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:uf(+t),u):r},u.lineX0=u.lineY0=function(){return l().x(t).y(n)},u.lineY1=function(){return l().x(t).y(r)},u.lineX1=function(){return l().x(e).y(n)},u.defined=function(t){return arguments.length?(i="function"==typeof t?t:uf(!!t),u):i},u.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),u):a},u.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),u):o},u}function If(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function Nf(t){return t}Df.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)}}};var jf=Vf(Pf);function Bf(t){this._curve=t}function Vf(t){function e(e){return new Bf(t(e))}return e._curve=t,e}function Hf(){return t=Lf().curve(jf),e=t.curve,t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(Vf(t)):e()._curve},t;var t,e}Bf.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 Uf=Array.prototype.slice;function Ff(){}function Gf(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 zf(t){this._context=t}function Wf(t){return new zf(t)}function Yf(t){this._context=t}function qf(t){return new Yf(t)}function Zf(t){this._context=t}function Xf(t){return new Zf(t)}function Kf(t,e){this._basis=new zf(t),this._beta=e}zf.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:Gf(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Yf.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Zf.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:Gf(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},Kf.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)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++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 $f=function t(e){function n(t){return 1===e?new zf(t):new Kf(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function Jf(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 Qf(t,e){this._context=t,this._k=(1-e)/6}Qf.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:Jf(this,this._x1,this._y1)}(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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var th=function t(e){function n(t){return new Qf(t,e)}return n.tension=function(e){return t(+e)},n}(0);function eh(t,e){this._context=t,this._k=(1-e)/6}eh.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var nh=function t(e){function n(t){return new eh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function rh(t,e){this._context=t,this._k=(1-e)/6}rh.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:Jf(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var ih=function t(e){function n(t){return new rh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function oh(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>1e-12){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>1e-12){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 ah(t,e){this._context=t,this._alpha=e}ah.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)}(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:oh(this,t,e)}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 sh=function t(e){function n(t){return e?new ah(t,e):new Qf(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function uh(t,e){this._context=t,this._alpha=e}uh.prototype={areaStart:Ff,areaEnd:Ff,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)}},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:oh(this,t,e)}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 lh=function t(e){function n(t){return e?new uh(t,e):new eh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function ch(t,e){this._context=t,this._alpha=e}ch.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:oh(this,t,e)}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 fh=function t(e){function n(t){return e?new ch(t,e):new rh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function hh(t){this._context=t}function dh(t){return new hh(t)}function ph(t){return t<0?-1:1}function gh(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(ph(o)+ph(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function mh(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function vh(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 yh(t){this._context=t}function bh(t){this._context=new _h(t)}function _h(t){this._context=t}function wh(t){return new yh(t)}function Oh(t){return new bh(t)}function xh(t){this._context=t}function Eh(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]}function Sh(t){return new xh(t)}function Th(t,e){this._context=t,this._t=e}function Mh(t){return new Th(t,.5)}function Ch(t){return new Th(t,0)}function Dh(t){return new Th(t,1)}function Ph(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]}function Ah(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function kh(t,e){return t[e]}hh.prototype={areaStart:Ff,areaEnd:Ff,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))}},yh.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:vh(this,this._t0,mh(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+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,vh(this,mh(this,n=gh(this,t,e)),n);break;default:vh(this,this._t0,n=gh(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(bh.prototype=Object.create(yh.prototype)).point=function(t,e){yh.prototype.point.call(this,e,t)},_h.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)}},xh.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=Eh(t),i=Eh(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)}},Th.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)}}this._x=t,this._y=e}};var Lh=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=da.getProperty(e,"data").groupMapsTo,o=da.getProperty(e,"axes");return t&&(n=n.filter((function(e){return t.includes(e.group)}))),o&&Object.keys(o).forEach((function(t){var e=o[t].mapsTo,r=o[t].scaleType;if(r!==I.LINEAR&&r!==I.LOG||(n=n.map((function(t){var n;return T(T({},t),((n={})[e]=null===t[e]?t[e]:Number(t[e]),n))}))),e&&o[t].domain)if(r===I.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=ft.items.status.ACTIVE,n=this.getDataGroups(t),r=this.getOptions().data.groupMapsTo;return this.getAllDataFromDomain(t).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(da.clone(t)),n=this.generateDataGroups(e);return this.set({data:e,dataGroups:n}),e},t.prototype.getDataGroups=function(t){return da.getProperty(this.getOptions(),"data","loading")?[]:t?this.get("dataGroups").filter((function(e){return t.includes(e.name)})):this.get("dataGroups")},t.prototype.getActiveDataGroups=function(t){var e=ft.items.status.ACTIVE;return this.getDataGroups(t).filter((function(t){return t.status===e}))},t.prototype.getDataGroupNames=function(t){return this.getDataGroups(t).map((function(t){return t.name}))},t.prototype.getActiveDataGroupNames=function(t){return this.getActiveDataGroups(t).map((function(t){return t.name}))},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.getDataValuesGroupedByKeys=function(t){var e=this,n=this.getOptions(),r=n.data.groupMapsTo,i=this.getDisplayData(t),o=us(i,(function(t){return t[e.services.cartesianScales.getDomainIdentifier(t)]})).keys(),a=this.services.cartesianScales.domainAxisPosition,s=n.axes[a].scaleType;s===I.TIME?o.sort((function(t,e){return new Date(t)-new Date(e)})):s!==I.LOG&&s!==I.LINEAR||o.sort((function(t,e){return t-e}));var u=this.getDataGroupNames();return o.map((function(t){var n={sharedStackKey:t};return u.forEach((function(o){var a=i.find((function(n){var i=e.services.cartesianScales.getDomainIdentifier(n);return n[r]===o&&n[i].toString()===t})),s=e.services.cartesianScales.getRangeIdentifier(n);n[o]=a?a[s]: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=this.getOptions().data.groupMapsTo,a=this.getDataGroupNames(i),s=this.getDataValuesGroupedByKeys(i);if(n){var u=da.fromPairs(s.map((function(t){return[t.sharedStackKey,0]})));s.forEach((function(t){a.forEach((function(e){u[t.sharedStackKey]+=t[e]}))})),s.forEach((function(t){a.forEach((function(e){u[t.sharedStackKey]?t[e]=t[e]/u[t.sharedStackKey]*100:t[e]=0}))}))}return function(){var t=uf([]),e=Ah,n=Ph,r=kh;function i(i){var o,a,s=t.apply(this,arguments),u=i.length,l=s.length,c=new Array(l);for(o=0;o<l;++o){for(var f,h=s[o],d=c[o]=new Array(u),p=0;p<u;++p)d[p]=f=[0,+r(i[p],h,p,i)],f.data=i[p];d.key=h}for(o=0,a=e(c);o<l;++o)c[a[o]].index=o;return n(c,a),c}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:uf(Uf.call(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:uf(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?Ah:"function"==typeof t?t:uf(Uf.call(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?Ph:t,i):n},i}().keys(a)(s).map((function(t,e){return Object.keys(t).filter((function(t){return!isNaN(t)})).map((function(n){var r=t[n];return r[o]=a[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();da.updateLegendAdditionalItems(e,t),this.set({options:da.merge(e,t)})},t.prototype.update=function(t){void 0===t&&(t=!0),this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(tt.Model.UPDATE,{animate:t}))},t.prototype.toggleDataLabel=function(t){var e=ft.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(tt.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=da.getProperty(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=da.getProperty(this.colorScale,t);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.isUserProvidedColorScaleValid=function(){var t=da.getProperty(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=da.getProperty(t,"label");if(null===a){var s=da.getProperty(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.getTabularData=function(t){return Array.isArray(t)?t:this.transformToTabularData(t)},t.prototype.sanitize=function(t){return t=this.getTabularData(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=ft.items.status,r=n.ACTIVE,i=n.DISABLED,o=this.getOptions(),a=us(t,(function(t){return t[e]})).keys();o.data.selectedGroups.length&&(o.data.selectedGroups.every((function(t){return a.includes(t)}))||(o.data.selectedGroups=[]));var s=function(t){return!o.data.selectedGroups.length||o.data.selectedGroups.includes(t)?r:i};return a.map((function(t){return{name:t,status:s(t)}}))},t.prototype.setCustomColorScale=function(){var t=this;if(this.isUserProvidedColorScaleValid()){var e=this.getOptions(),n=da.getProperty(e,"color","scale");Object.keys(n).forEach((function(e){t.allDataGroups.includes(e)||console.warn('"'+e+'" does not exist in data groups.')})),this.allDataGroups.filter((function(t){return n[t]})).forEach((function(e){return t.colorScale[e]=n[e]}))}},t.prototype.setColorClassNames=function(){var t=da.getProperty(this.getOptions(),"color","pairing"),e=da.getProperty(t,"numberOfVariants");(!e||e<this.allDataGroups.length)&&(e=this.allDataGroups.length);var n=da.getProperty(t,"option"),r=e>5?14:e;n=n<=lt.pairingOptions[r+"-color"]?n:1;var i=this.allDataGroups.map((function(t,e){return r+"-"+n+"-"+(e%14+1)}));this.colorClassNames=ks().range(i).domain(this.allDataGroups)},t}(),Rh=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}(),Ih={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 "},Nh=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){void 0===e&&(e=null);for(var n=0,r=this.__entries__;n<r.length;n+=1){var i=r[n];t.call(e,i[1],i[0])}},Object.defineProperties(e.prototype,n),e}()}(),jh="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,Bh="undefined"!=typeof global&&global.Math===Math?global:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),Vh="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(Bh):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)},Hh=["top","right","bottom","left","width","height","size","weight"],Uh="undefined"!=typeof MutationObserver,Fh=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t,e){var n=!1,r=!1,i=0;function o(){n&&(n=!1,t()),r&&s()}function a(){Vh(o)}function s(){var t=Date.now();if(n){if(t-i<2)return;r=!0}else n=!0,r=!1,setTimeout(a,e);i=t}return s}(this.refresh.bind(this),20)};Fh.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},Fh.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},Fh.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},Fh.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},Fh.prototype.connect_=function(){jh&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),Uh?(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)},Fh.prototype.disconnect_=function(){jh&&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)},Fh.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e=""),Hh.some((function(t){return!!~e.indexOf(t)}))&&this.refresh()},Fh.getInstance=function(){return this.instance_||(this.instance_=new Fh),this.instance_},Fh.instance_=null;var Gh=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},zh=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||Bh},Wh=$h(0,0,0,0);function Yh(t){return parseFloat(t)||0}function qh(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return e.reduce((function(e,n){return e+Yh(t["border-"+n+"-width"])}),0)}function Zh(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return Wh;var r=zh(t).getComputedStyle(t),i=function(t){for(var e={},n=0,r=["top","right","bottom","left"];n<r.length;n+=1){var i=r[n],o=t["padding-"+i];e[i]=Yh(o)}return e}(r),o=i.left+i.right,a=i.top+i.bottom,s=Yh(r.width),u=Yh(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=qh(r,"left","right")+o),Math.round(u+a)!==n&&(u-=qh(r,"top","bottom")+a)),!function(t){return t===zh(t).document.documentElement}(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 $h(i.left,i.top,s,u)}var Xh="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof zh(t).SVGGraphicsElement}:function(t){return t instanceof zh(t).SVGElement&&"function"==typeof t.getBBox};function Kh(t){return jh?Xh(t)?function(t){var e=t.getBBox();return $h(0,0,e.width,e.height)}(t):Zh(t):Wh}function $h(t,e,n,r){return{x:t,y:e,width:n,height:r}}var Jh=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=$h(0,0,0,0),this.target=t};Jh.prototype.isActive=function(){var t=Kh(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},Jh.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var Qh=function(t,e){var n=function(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 Gh(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}(e);Gh(this,{target:t,contentRect:n})},td=function(t,e,n){if(this.activeObservations_=[],this.observations_=new Nh,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n};td.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 zh(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new Jh(t)),this.controller_.addObserver(this),this.controller_.refresh())}},td.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 zh(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))}},td.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},td.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},td.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new Qh(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},td.prototype.clearActive=function(){this.activeObservations_.splice(0)},td.prototype.hasActive=function(){return this.activeObservations_.length>0};var ed="undefined"!=typeof WeakMap?new WeakMap:new Nh,nd=function(t){if(!(this instanceof nd))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=Fh.getInstance(),n=new td(t,e,this);ed.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){nd.prototype[t]=function(){return(e=ed.get(this))[t].apply(e,arguments);var e}}));var rd=void 0!==Bh.ResizeObserver?Bh.ResizeObserver:nd,id=xa((function(t){!function(e){var n=function(){return{escape:function(t){return t.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1")},parseExtension:t,mimeType:function(e){var n=t(e).toLowerCase();return(r="application/font-woff",{woff:r,woff2:r,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml"})[n]||"";var r},dataAsUrl:function(t,e){return"data:"+e+";base64,"+t},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){for(var n=window.atob(t.toDataURL().split(",")[1]),r=n.length,i=new Uint8Array(r),o=0;o<r;o++)i[o]=n.charCodeAt(o);e(new Blob([i],{type:"image/png"}))}))}(t)},resolveUrl:function(t,e){var n=document.implementation.createHTMLDocument(),r=n.createElement("base");n.head.appendChild(r);var i=n.createElement("a");return n.body.appendChild(i),r.href=e,i.href=t,i.href},getAndEncode:function(t){s.impl.options.cacheBust&&(t+=(/\?/.test(t)?"&":"?")+(new Date).getTime());return new Promise((function(e){var n,r=new XMLHttpRequest;if(r.onreadystatechange=function(){if(4!==r.readyState)return;if(200!==r.status)return void(n?e(n):o("cannot fetch resource: "+t+", status: "+r.status));var i=new FileReader;i.onloadend=function(){var t=i.result.split(/,/)[1];e(t)},i.readAsDataURL(r.response)},r.ontimeout=function(){n?e(n):o("timeout of 30000ms occured while fetching resource: "+t)},r.responseType="blob",r.timeout=3e4,r.open("GET",t,!0),r.send(),s.impl.options.imagePlaceholder){var i=s.impl.options.imagePlaceholder.split(/,/);i&&i[1]&&(n=i[1])}function o(t){console.error(t),e("")}}))},uid:function(){var t=0;return 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){for(var e=[],n=t.length,r=0;r<n;r++)e.push(t[r]);return e},escapeXhtml:function(t){return t.replace(/#/g,"%23").replace(/\n/g,"%0A")},makeImage:function(t){return new Promise((function(e,n){var r=new Image;r.onload=function(){e(r)},r.onerror=n,r.src=t}))},width:function(t){var n=e(t,"border-left-width"),r=e(t,"border-right-width");return t.scrollWidth+n+r},height:function(t){var n=e(t,"border-top-width"),r=e(t,"border-bottom-width");return t.scrollHeight+n+r}};function t(t){var e=/\.([^\.\/]*?)$/g.exec(t);return e?e[1]:""}function e(t,e){var n=window.getComputedStyle(t).getPropertyValue(e);return parseFloat(n.replace("px",""))}}(),r=function(){var t=/url\(['"]?([^'"]+?)['"]?\)/g;return{inlineAll:function(t,n,o){return function(){return!e(t)}()?Promise.resolve(t):Promise.resolve(t).then(r).then((function(e){var r=Promise.resolve(t);return e.forEach((function(t){r=r.then((function(e){return i(e,t,n,o)}))})),r}))},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(t){return n.dataAsUrl(t,n.mimeType(e))})).then((function(r){return t.replace(function(t){return new RegExp("(url\\(['\"]?)("+n.escape(t)+")(['\"]?\\))","g")}(e),"$1"+r+"$3")}))}}(),i=function(){return{resolveAll:function(){return t().then((function(t){return Promise.all(t.map((function(t){return t.resolve()})))})).then((function(t){return t.join("\n")}))},impl:{readAll:t}};function t(){return Promise.resolve(n.asArray(document.styleSheets)).then((function(t){var e=[];return t.forEach((function(t){try{n.asArray(t.cssRules||[]).forEach(e.push.bind(e))}catch(e){console.log("Error while reading CSS rules from "+t.href,e.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")}}}}}(),o=function(){return{inlineAll:function e(i){return i instanceof Element?function(t){var e=t.style.getPropertyValue("background");return e?r.inlineAll(e).then((function(e){t.style.setProperty("background",e,t.style.getPropertyPriority("background"))})).then((function(){return t})):Promise.resolve(t)}(i).then((function(){return i instanceof HTMLImageElement?t(i).inline():Promise.all(n.asArray(i.childNodes).map((function(t){return e(t)})))})):Promise.resolve(i)},impl:{newImage:t}};function t(t){return{inline:function(e){return n.isDataUrl(t.src)?Promise.resolve():Promise.resolve(t.src).then(e||n.getAndEncode).then((function(e){return n.dataAsUrl(e,n.mimeType(t.src))})).then((function(e){return new Promise((function(n,r){t.onload=n,t.onerror=r,t.src=e}))}))}}}}(),a={imagePlaceholder:void 0,cacheBust:!1},s={toSvg:u,toPng:function(t,e){return l(t,e||{}).then((function(t){return t.toDataURL()}))},toJpeg:function(t,e){return l(t,e=e||{}).then((function(t){return t.toDataURL("image/jpeg",e.quality||1)}))},toBlob:function(t,e){return l(t,e||{}).then(n.canvasToBlob)},toPixelData:function(t,e){return l(t,e||{}).then((function(e){return e.getContext("2d").getImageData(0,0,n.width(t),n.height(t)).data}))},impl:{fontFaces:i,images:o,util:n,inliner:r,options:{}}};function u(t,e){return function(t){void 0===t.imagePlaceholder?s.impl.options.imagePlaceholder=a.imagePlaceholder:s.impl.options.imagePlaceholder=t.imagePlaceholder;void 0===t.cacheBust?s.impl.options.cacheBust=a.cacheBust:s.impl.options.cacheBust=t.cacheBust}(e=e||{}),Promise.resolve(t).then((function(t){return function t(e,r,i){return i||!r||r(e)?Promise.resolve(e).then((function(t){return t instanceof HTMLCanvasElement?n.makeImage(t.toDataURL()):t.cloneNode(!1)})).then((function(t){return o(e,t,r)})).then((function(t){return function(t,e){return e instanceof Element?Promise.resolve().then(r).then(i).then(o).then(a).then((function(){return e})):e;function r(){var r,i;r=window.getComputedStyle(t),i=e.style,r.cssText?i.cssText=r.cssText:function(t,e){n.asArray(t).forEach((function(n){e.setProperty(n,t.getPropertyValue(n),t.getPropertyPriority(n))}))}(r,i)}function i(){[":before",":after"].forEach((function(r){!function(r){var i=window.getComputedStyle(t,r),o=i.getPropertyValue("content");if(""===o||"none"===o)return;var a=n.uid();e.className=e.className+" "+a;var s=document.createElement("style");s.appendChild(function(t,e,r){var i="."+t+":"+e,o=r.cssText?function(t){var e=t.getPropertyValue("content");return t.cssText+" content: "+e+";"}(r):function(t){return n.asArray(t).map((function(e){return e+": "+t.getPropertyValue(e)+(t.getPropertyPriority(e)?" !important":"")})).join("; ")+";"}(r);return document.createTextNode(i+"{"+o+"}")}(a,r,i)),e.appendChild(s)}(r)}))}function o(){t instanceof HTMLTextAreaElement&&(e.innerHTML=t.value),t instanceof HTMLInputElement&&e.setAttribute("value",t.value)}function a(){e instanceof SVGElement&&(e.setAttribute("xmlns","http://www.w3.org/2000/svg"),e instanceof SVGRectElement&&["width","height"].forEach((function(t){var n=e.getAttribute(t);n&&e.style.setProperty(t,n)})))}}(e,t)})):Promise.resolve();function o(e,r,i){var o=e.childNodes;return 0===o.length?Promise.resolve(r):a(r,n.asArray(o),i).then((function(){return r}));function a(e,n,r){var i=Promise.resolve();return n.forEach((function(n){i=i.then((function(){return t(n,r)})).then((function(t){t&&e.appendChild(t)}))})),i}}}(t,e.filter,!0)})).then(c).then(f).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]}));return t})).then((function(r){return function(t,e,r){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){return'<foreignObject x="0" y="0" width="100%" height="100%">'+t+"</foreignObject>"})).then((function(t){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+e+'" height="'+r+'">'+t+"</svg>"})).then((function(t){return"data:image/svg+xml;charset=utf-8,"+t}))}(r,e.width||n.width(t),e.height||n.height(t))}))}function l(t,e){return u(t,e).then(n.makeImage).then(n.delay(100)).then((function(r){var i=function(t){var r=document.createElement("canvas");if(r.width=e.width||n.width(t),r.height=e.height||n.height(t),e.bgcolor){var i=r.getContext("2d");i.fillStyle=e.bgcolor,i.fillRect(0,0,r.width,r.height)}return r}(t);return i.getContext("2d").drawImage(r,0,0),i}))}function c(t){return i.resolveAll().then((function(e){var n=document.createElement("style");return t.appendChild(n),n.appendChild(document.createTextNode(e)),t}))}function f(t){return o.inlineAll(t).then((function(){return t}))}t.exports=s}()})),od=function(t){function e(e,n){return t.call(this,e,n)||this}return n(e,t),e.getHTMLElementSize=function(t){return{width:t.clientWidth,height:t.clientHeight}},e.getSVGElementSize=function(t,e){t.attr||(t=va(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{r={width:(n=t.node().getBBox()).width,height:n.height}}catch(t){}try{o={width:(i=t.node().getBoundingClientRect()).width,height:i.height}}catch(t){}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{s({width:da.getProperty(t.node(),"width","baseVal","value"),height:da.getProperty(t.node(),"height","baseVal","value")})}catch(t){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],o=(r=r[1].split("."))[0]):i=(r=e.split("."))[0],t.append(i).attr("id",o).attr("class",r.slice(1).join(" "))}return n},e.prototype.init=function(){this.styleHolderElement(),this.addMainContainer(),this.verifyCSSStylesBeingApplied(),this.model.getOptions().resizable&&this.addResizeListener(),this.addHolderListeners()},e.prototype.addMainContainer=function(){var t=this.model.getOptions(),e=da.getProperty(t,"style","prefix"),n=va(this.getHolder()).append("div").classed(Ih.prefix+"--"+e+"--chart-wrapper",!0).style("height","100%").style("width","100%");n.append("g").attr("class","DONT_STYLE_ME_css_styles_verifier"),this.mainContainer=n.node()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder();va(this.getHolder()).classed(Ih.prefix+"--chart-holder",!0);var e=this.model.getOptions(),n=e.width,r=e.height;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.exportToJPG=function(){var t=this;id.toJpeg(this.getMainContainer(),{quality:1,filter:function(t){return!t.classList||!t.classList.contains("bx--cc--toolbar")}}).then((function(e){t.services.files.downloadImage(e,"myChart.jpg")}))},e.prototype.exportToPNG=function(){var t=this;id.toPng(this.getMainContainer(),{quality:1,filter:function(t){return!t.classList||!t.classList.contains("bx--cc--toolbar")}}).then((function(e){t.services.files.downloadImage(e,"myChart.png")})).catch((function(t){console.error("oops, something went wrong!",t)}))},e.prototype.toggleFullscreen=function(){var t=this.getHolder(),e=va(t),n=e.classed("fullscreen");e.classed("fullscreen",!n),n?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.verifyCSSStylesBeingApplied=function(){var t=this;setTimeout((function(){var e=va(t.mainContainer).select("g.DONT_STYLE_ME_css_styles_verifier").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(va(this.mainContainer),{useBBox:!0}).height,n=va(this.mainContainer).attr("class"),r=va(this.mainContainer).selectAll("."+n+" > svg"),i=0;r.nodes().forEach((function(t){i+=Number(e.getSVGElementSize(va(t),{useBBox:!0}).height)})),i<=t?va(this.mainContainer).attr("height",i):va(this.mainContainer).attr("height","100%")}},e.prototype.getMainContainer=function(){return this.mainContainer},e.prototype.addHolderListeners=function(){var t=this,e=this.getHolder();e&&va(e).on("mouseover",(function(){t.services.events.dispatchEvent(tt.Chart.MOUSEOVER)})).on("mouseout",(function(){t.services.events.dispatchEvent(tt.Chart.MOUSEOUT)}))},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=da.debounce((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(tt.Chart.RESIZE))}),12.5);new rd(i).observe(e)}},e}(Rh),ad=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(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")).initEvent(t,!1,!0),this.documentFragment.dispatchEvent(n)},e}(Rh),sd=function(t){function e(e,n){return t.call(this,e,n)||this}return n(e,t),e.prototype.downloadCSV=function(t,e,n){var r=document.createElement("a");navigator.msSaveBlob?navigator.msSaveBlob(new Blob([t],{type:"text/csv;encoding:utf-8"}),e):URL&&"download"in r?(r.href=URL.createObjectURL(new Blob([t],{type:"text/csv;encoding:utf-8"})),r.setAttribute("download",e),document.body.appendChild(r),r.click(),document.body.removeChild(r)):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}(Rh),ud={value:function(){}};function ld(){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 cd(r)}function cd(t){this._=t}function fd(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 hd(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function dd(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=ud,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}cd.prototype=ld.prototype={constructor:cd,on:function(t,e){var n,r=this._,i=fd(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o<a;)if(n=(t=i[o]).type)r[n]=dd(r[n],t.name,e);else if(null==e)for(n in r)r[n]=dd(r[n],t.name,null);return this}for(;++o<a;)if((n=(t=i[o]).type)&&(n=hd(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new cd(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(o=0,n=(r=this._[t]).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 pd,gd,md=Object.freeze({__proto__:null,dispatch:ld}),vd=0,yd=0,bd=0,_d=0,wd=0,Od=0,xd="object"==typeof performance&&performance.now?performance:Date,Ed="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Sd(){return wd||(Ed(Td),wd=xd.now()+Od)}function Td(){wd=0}function Md(){this._call=this._time=this._next=null}function Cd(t,e,n){var r=new Md;return r.restart(t,e,n),r}function Dd(){wd=(_d=xd.now())+Od,vd=yd=0;try{!function(){Sd(),++vd;for(var t,e=pd;e;)(t=wd-e._time)>=0&&e._call.call(null,t),e=e._next;--vd}()}finally{vd=0,function(){var t,e,n=pd,r=1/0;for(;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:pd=e);gd=t,Ad(r)}(),wd=0}}function Pd(){var t=xd.now(),e=t-_d;e>1e3&&(Od-=e,_d=t)}function Ad(t){vd||(yd&&(yd=clearTimeout(yd)),t-wd>24?(t<1/0&&(yd=setTimeout(Dd,t-xd.now()-Od)),bd&&(bd=clearInterval(bd))):(bd||(_d=xd.now(),bd=setInterval(Pd,1e3)),vd=1,Ed(Dd)))}function kd(t,e,n){var r=new Md;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}Md.prototype=Cd.prototype={constructor:Md,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?Sd():+n)+(null==e?0:+e),this._next||gd===this||(gd?gd._next=this:pd=this,gd=this),this._call=t,this._time=n,Ad()},stop:function(){this._call&&(this._call=null,this._time=1/0,Ad())}};var Ld=ld("start","end","cancel","interrupt"),Rd=[];function Id(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(u){var l,c,f,h;if(1!==n.state)return s();for(l in i)if((h=i[l]).name===n.name){if(3===h.state)return kd(o);4===h.state?(h.state=6,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[l]):+l<e&&(h.state=6,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[l])}if(kd((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(u))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,r=new Array(f=n.tween.length),l=0,c=-1;l<f;++l)(h=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=h);r.length=c+1}}function a(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=6,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=Cd((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:r,group:i,on:Ld,tween:Rd,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Nd(t,e){var n=Bd(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function jd(t,e){var n=Bd(t,e);if(n.state>3)throw new Error("too late; already running");return n}function Bd(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Vd(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>2&&n.state<5,n.state=6,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}}function Hd(t,e){var n,r;return function(){var i=jd(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function Ud(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=jd(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}}function Fd(t,e,n){var r=t._id;return t.each((function(){var t=jd(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return Bd(t,r).value[e]}}function Gd(t,e){var n;return("number"==typeof e?vu:e instanceof Ks?du:(n=Ks(e))?(e=n,du):wu)(t,e)}function zd(t){return function(){this.removeAttribute(t)}}function Wd(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Yd(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 qd(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 Zd(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+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function Xd(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+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Kd(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function $d(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Jd(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&$d(t,i)),n}return i._value=e,i}function Qd(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Kd(t,i)),n}return i._value=e,i}function tp(t,e){return function(){Nd(this,t).delay=+e.apply(this,arguments)}}function ep(t,e){return e=+e,function(){Nd(this,t).delay=e}}function np(t,e){return function(){jd(this,t).duration=+e.apply(this,arguments)}}function rp(t,e){return e=+e,function(){jd(this,t).duration=e}}function ip(t,e){if("function"!=typeof e)throw new Error;return function(){jd(this,t).ease=e}}function op(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?Nd:jd;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var ap=ma.prototype.constructor;function sp(t){return function(){this.style.removeProperty(t)}}function up(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function lp(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&up(t,o,n)),r}return o._value=e,o}function cp(t){return function(e){this.textContent=t.call(this,e)}}function fp(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&cp(r)),e}return r._value=t,r}var hp=0;function dp(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function pp(t){return ma().transition(t)}function gp(){return++hp}var mp=ma.prototype;dp.prototype=pp.prototype={constructor:dp,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=po(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,f=o[a]=new Array(c),h=0;h<c;++h)(s=l[h])&&(u=t.call(s,s.__data__,h,l))&&("__data__"in s&&(u.__data__=s.__data__),f[h]=u,Id(f[h],e,n,h,f,Bd(s,n)));return new dp(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=mo(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,f=0;f<c;++f)if(u=l[f]){for(var h,d=t.call(u,u.__data__,f,l),p=Bd(u,n),g=0,m=d.length;g<m;++g)(h=d[g])&&Id(h,e,n,g,d,p);o.push(d),a.push(u)}return new dp(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=vo(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 dp(r,this._parents,this._name,this._id)},merge: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],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new dp(a,this._parents,this._name,this._id)},selection:function(){return new ap(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=gp(),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=Bd(a,e);Id(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new dp(r,this._parents,t,n)},call:mp.call,nodes:mp.nodes,node:mp.node,size:mp.size,empty:mp.empty,each:mp.each,on:function(t,e){var n=this._id;return arguments.length<2?Bd(this.node(),n).on.on(t):this.each(op(n,t,e))},attr:function(t,e){var n=uo(t),r="transform"===n?Lu:Gd;return this.attrTween(t,"function"==typeof e?(n.local?Xd:Zd)(n,r,Fd(this,"attr."+t,e)):null==e?(n.local?Wd:zd)(n):(n.local?qd:Yd)(n,r,e))},attrTween: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=uo(t);return this.tween(n,(r.local?Jd:Qd)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?ku:Gd;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=Lo(this,t),a=(this.style.removeProperty(t),Lo(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,sp(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=Lo(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=Lo(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,Fd(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=jd(this,t),l=u.on,c=null==u.value[a]?o||(o=sp(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=Lo(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween: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,lp(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(Fd(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween: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,fp(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=Bd(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?Hd:Ud)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?tp:ep)(e,t)):Bd(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?np:rp)(e,t)):Bd(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(ip(e,t)):Bd(this.node(),e).ease},end: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=jd(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e}))}))}};var vp={time:null,delay:0,duration:250,ease:it};function yp(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return vp.time=Sd(),vp;return n}ma.prototype.interrupt=function(t){return this.each((function(){Vd(this,t)}))},ma.prototype.transition=function(t){var e,n;t instanceof dp?(e=t._id,t=t._name):(e=gp(),(n=vp).time=Sd(),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])&&Id(a,t,e,l,s,n||yp(a,e));return new dp(r,this._parents,t,e)};var bp=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return n(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener(tt.Model.UPDATE,(function(){t.pendingTransitions={}}))},e.prototype.getTransition=function(t,e){var n=this;if(!1===this.model.getOptions().animations||!1===e)return this.getInstantTransition(t);var r=pp(t).duration(da.getProperty(yt,t,"duration")||yt.default.duration);return this.pendingTransitions[r._id]=r,r.on("end interrupt cancel",(function(){delete n.pendingTransitions[r._id]})),r},e.prototype.getInstantTransition=function(t){var e=this,n=pp(t).duration(0);return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),n},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(Rh),_p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(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){return(100*Math.abs(t[1])/Math.abs(t[0]-t[1])).toFixed(2)+"%"},e.getStops=function(t,n){var r=[{offset:"0%",color:n,opacity:"0.6"},{offset:"80%",color:n,opacity:"0"}];return t[0]<0&&t[1]>0&&(r=[{offset:"0%",color:n,opacity:"0.6"},{offset:e.getOffsetRatio(t),color:n,opacity:"0"},{offset:"100%",color:n,opacity:"0.6"}]),r},e}(Rh);function wp(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 Op(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 xp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=Op(e);return n.setDate(n.getDate()+r),n}function Ep(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t).getTime(),r=Op(e);return new Date(n+r)}function Sp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,36e5*n)}function Tp(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());return e.setSeconds(0,0),6e4*n+e.getTime()%6e4}function Mp(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t);return e.setHours(0,0,0,0),e}function Cp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Mp(t),r=Mp(e),i=n.getTime()-Tp(n),o=r.getTime()-Tp(r);return Math.round((i-o)/864e5)}function Dp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,6e4*n)}function Pp(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(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 Ap(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=Op(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=Pp(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function kp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,1e3*n)}function Lp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ap(t,12*n)}function Rp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function Ip(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t);return!isNaN(e)}function Np(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function jp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e);return n.getFullYear()-r.getFullYear()}function Bp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e);return n.getTime()-r.getTime()}function Vp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/6e4;return n>0?Math.floor(n):Math.ceil(n)}function Hp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/1e3;return n>0?Math.floor(n):Math.ceil(n)}var Up={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 Fp(t){return function(e){var n=e||{},r=n.width?String(n.width):t.defaultWidth;return t.formats[r]||t.formats[t.defaultWidth]}}var Gp={date:Fp({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Fp({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Fp({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},zp={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Wp(t){return function(e,n){var r,i=n||{};if("formatting"===(i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,a=i.width?String(i.width):o;r=t.formattingValues[a]||t.formattingValues[o]}else{var s=t.defaultWidth,u=i.width?String(i.width):t.defaultWidth;r=t.values[u]||t.values[s]}return r[t.argumentCallback?t.argumentCallback(e):e]}}function Yp(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)?function(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return n}(c,(function(t){return t.test(r)})):function(t,e){for(var n in t)if(t.hasOwnProperty(n)&&e(t[n]))return n}(c,(function(t){return t.test(r)})),u=t.valueCallback?t.valueCallback(u):u,{value:u=i.valueCallback?i.valueCallback(u):u,rest:r.slice(l.length)}}}var qp,Zp={code:"en-US",formatDistance:function(t,e,n){var r;return n=n||{},r="string"==typeof Up[t]?Up[t]:1===e?Up[t].one:Up[t].other.replace("{{count}}",e),n.addSuffix?n.comparison>0?"in "+r:r+" ago":r},formatLong:Gp,formatRelative:function(t,e,n,r){return zp[t]},localize:{ordinalNumber:function(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"},era:Wp({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Wp({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:Wp({values:{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"]},defaultWidth:"wide"}),day:Wp({values:{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"]},defaultWidth:"wide"}),dayPeriod:Wp({values:{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"}},defaultWidth:"wide",formattingValues:{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"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(qp={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t,e){var n=String(t),r=e||{},i=n.match(qp.matchPattern);if(!i)return null;var o=i[0],a=n.match(qp.parsePattern);if(!a)return null;var s=qp.valueCallback?qp.valueCallback(a[0]):a[0];return{value:s=r.valueCallback?r.valueCallback(s):s,rest:n.slice(o.length)}}),era:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Yp({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),day:Yp({matchPatterns:{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},defaultMatchWidth:"wide",parsePatterns:{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]},defaultParseWidth:"any"}),dayPeriod:Yp({matchPatterns:{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},defaultMatchWidth:"any",parsePatterns:{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}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};function Xp(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ep(t,-n)}function Kp(t,e){for(var n=t<0?"-":"",r=Math.abs(t).toString();r.length<e;)r="0"+r;return n+r}var $p=function(t,e){var n=t.getUTCFullYear(),r=n>0?n:1-n;return Kp("yy"===e?r%100:r,e.length)},Jp=function(t,e){var n=t.getUTCMonth();return"M"===e?String(n+1):Kp(n+1,2)},Qp=function(t,e){return Kp(t.getUTCDate(),e.length)},tg=function(t,e){return Kp(t.getUTCHours()%12||12,e.length)},eg=function(t,e){return Kp(t.getUTCHours(),e.length)},ng=function(t,e){return Kp(t.getUTCMinutes(),e.length)},rg=function(t,e){return Kp(t.getUTCSeconds(),e.length)},ig=function(t,e){var n=e.length,r=t.getUTCMilliseconds();return Kp(Math.floor(r*Math.pow(10,n-3)),e.length)};function og(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=1,n=wp(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 ag(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t),n=e.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=og(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=og(o);return e.getTime()>=i.getTime()?n+1:e.getTime()>=a.getTime()?n:n-1}function sg(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=ag(t),n=new Date(0);n.setUTCFullYear(e,0,4),n.setUTCHours(0,0,0,0);var r=og(n);return r}function ug(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:Op(i),a=null==n.weekStartsOn?o:Op(n.weekStartsOn);if(!(a>=0&&a<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var s=wp(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 lg(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=wp(t,e),r=n.getUTCFullYear(),i=e||{},o=i.locale,a=o&&o.options&&o.options.firstWeekContainsDate,s=null==a?1:Op(a),u=null==i.firstWeekContainsDate?s:Op(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=ug(l,e),f=new Date(0);f.setUTCFullYear(r,0,u),f.setUTCHours(0,0,0,0);var h=ug(f,e);return n.getTime()>=c.getTime()?r+1:n.getTime()>=h.getTime()?r:r-1}function cg(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:Op(i),a=null==n.firstWeekContainsDate?o:Op(n.firstWeekContainsDate),s=lg(t,e),u=new Date(0);u.setUTCFullYear(s,0,a),u.setUTCHours(0,0,0,0);var l=ug(u,e);return l}var fg="midnight",hg="noon",dg="morning",pg="afternoon",gg="evening",mg="night",vg={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 $p(t,e)},Y:function(t,e,n,r){var i=lg(t,r),o=i>0?i:1-i;return"YY"===e?Kp(o%100,2):"Yo"===e?n.ordinalNumber(o,{unit:"year"}):Kp(o,e.length)},R:function(t,e){return Kp(ag(t),e.length)},u:function(t,e){return Kp(t.getUTCFullYear(),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 Kp(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 Kp(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 Jp(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 Kp(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=function(t,e){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var n=wp(t),r=ug(n,e).getTime()-cg(n,e).getTime();return Math.round(r/6048e5)+1}(t,r);return"wo"===e?n.ordinalNumber(i,{unit:"week"}):Kp(i,e.length)},I:function(t,e,n){var r=function(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(t),n=og(e).getTime()-sg(e).getTime();return Math.round(n/6048e5)+1}(t);return"Io"===e?n.ordinalNumber(r,{unit:"week"}):Kp(r,e.length)},d:function(t,e,n){return"do"===e?n.ordinalNumber(t.getUTCDate(),{unit:"date"}):Qp(t,e)},D:function(t,e,n){var r=function(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=wp(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/864e5)+1}(t);return"Do"===e?n.ordinalNumber(r,{unit:"dayOfYear"}):Kp(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 Kp(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 Kp(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 Kp(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()/12>=1?"pm":"am";switch(e){case"a":case"aa":case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,n){var r,i=t.getUTCHours();switch(r=12===i?hg:0===i?fg: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?gg:i>=12?pg:i>=4?dg:mg,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 tg(t,e)},H:function(t,e,n){return"Ho"===e?n.ordinalNumber(t.getUTCHours(),{unit:"hour"}):eg(t,e)},K:function(t,e,n){var r=t.getUTCHours()%12;return"Ko"===e?n.ordinalNumber(r,{unit:"hour"}):Kp(r,e.length)},k:function(t,e,n){var r=t.getUTCHours();return 0===r&&(r=24),"ko"===e?n.ordinalNumber(r,{unit:"hour"}):Kp(r,e.length)},m:function(t,e,n){return"mo"===e?n.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):ng(t,e)},s:function(t,e,n){return"so"===e?n.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):rg(t,e)},S:function(t,e){return ig(t,e)},X:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();if(0===i)return"Z";switch(e){case"X":return bg(i);case"XXXX":case"XX":return _g(i);case"XXXXX":case"XXX":default:return _g(i,":")}},x:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"x":return bg(i);case"xxxx":case"xx":return _g(i);case"xxxxx":case"xxx":default:return _g(i,":")}},O:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+yg(i,":");case"OOOO":default:return"GMT"+_g(i,":")}},z:function(t,e,n,r){var i=(r._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+yg(i,":");case"zzzz":default:return"GMT"+_g(i,":")}},t:function(t,e,n,r){var i=r._originalDate||t;return Kp(Math.floor(i.getTime()/1e3),e.length)},T:function(t,e,n,r){return Kp((r._originalDate||t).getTime(),e.length)}};function yg(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+Kp(o,2)}function bg(t,e){return t%60==0?(t>0?"-":"+")+Kp(Math.abs(t)/60,2):_g(t,e)}function _g(t,e){var n=e||"",r=t>0?"-":"+",i=Math.abs(t);return r+Kp(Math.floor(i/60),2)+n+Kp(i%60,2)}function wg(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 Og(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"})}}var xg={p:Og,P:function(t,e){var n,r=t.match(/(P+)(p+)?/),i=r[1],o=r[2];if(!o)return wg(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"})}return n.replace("{{date}}",wg(i,e)).replace("{{time}}",Og(o,e))}},Eg=["D","DD"],Sg=["YY","YYYY"];function Tg(t){return-1!==Eg.indexOf(t)}function Mg(t){return-1!==Sg.indexOf(t)}function Cg(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 Dg=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Pg=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Ag=/^'([^]*?)'?$/,kg=/''/g,Lg=/[a-zA-Z]/;function Rg(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||Zp,a=o.options&&o.options.firstWeekContainsDate,s=null==a?1:Op(a),u=null==i.firstWeekContainsDate?s:Op(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:Op(l),f=null==i.weekStartsOn?c:Op(i.weekStartsOn);if(!(f>=0&&f<=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 h=wp(t);if(!Ip(h))throw new RangeError("Invalid time value");var d=Tp(h),p=Xp(h,d),g={firstWeekContainsDate:u,weekStartsOn:f,locale:o,_originalDate:h},m=r.match(Pg).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,xg[e])(t,o.formatLong,g):t})).join("").match(Dg).map((function(t){if("''"===t)return"'";var e=t[0];if("'"===e)return Ig(t);var n=vg[e];if(n)return!i.useAdditionalWeekYearTokens&&Mg(t)&&Cg(t),!i.useAdditionalDayOfYearTokens&&Tg(t)&&Cg(t),n(p,t,o.localize,g);if(e.match(Lg))throw new RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return t})).join("");return m}function Ig(t){return t.match(Ag)[1].replace(kg,"'")}function Ng(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return xp(t,-n)}function jg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Sp(t,-n)}function Bg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Dp(t,-n)}function Vg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Ap(t,-n)}function Hg(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return kp(t,-n)}function Ug(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Op(e);return Lp(t,-n)}var Fg=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 n(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=da.getProperty(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=da.getProperty(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 da.getProperty(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).title;return e||(t===A.BOTTOM||t===A.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;this.determineAxisDuality(),this.findDomainAndRangeAxes(),this.determineOrientation(),Object.keys(A).map((function(t){return A[t]})).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!==A.LEFT&&this.rangeAxisPosition!==A.RIGHT||this.domainAxisPosition!==A.BOTTOM&&this.domainAxisPosition!==A.TOP?this.orientation=R.HORIZONTAL:this.orientation=R.VERTICAL},e.prototype.isDualAxes=function(){return this.dualAxes},e.prototype.determineAxisDuality=function(){var t,e,n,r,i=this.model.getOptions(),o=da.getProperty(i,"axes");((null===(t=o[A.LEFT])||void 0===t?void 0:t.correspondingDatasets)&&o[A.RIGHT]||(null===(e=o[A.RIGHT])||void 0===e?void 0:e.correspondingDatasets)&&o[A.LEFT]||(null===(n=o[A.TOP])||void 0===n?void 0:n.correspondingDatasets)&&o[A.BOTTOM]||(null===(r=o[A.BOTTOM])||void 0===r?void 0:r.correspondingDatasets)&&o[A.TOP])&&(this.dualAxes=!0)},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=[A.BOTTOM,A.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[A.LEFT,A.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=da.getProperty(a,"axes")[n].mapsTo,u=null!==da.getProperty(r,s)?r[s]:r;switch(e){case I.LABELS:o=t(u)+t.step()/2;break;case I.TIME:o=t(new Date(u));break;default:o=t(u)}return o},e.prototype.getBoundedScaledValues=function(t,e){var n=this.model.getOptions().bounds,r=this.scales[this.rangeAxisPosition],i=this.model.getOptions(),o=da.getProperty(i,"axes")[this.rangeAxisPosition].mapsTo,a=void 0!==t[o]?t[o]:t;return[r(null!==da.getProperty(t,n.upperBoundMapsTo)?t[n.upperBoundMapsTo]:a),r(null!==da.getProperty(t,n.lowerBoundMapsTo)?t[n.lowerBoundMapsTo]:a)]},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 da.getProperty(e,"axes",this.getDomainAxisPosition({datum:t}),"mapsTo")},e.prototype.getRangeIdentifier=function(t){var e=this.model.getOptions();return da.getProperty(e,"axes",this.getRangeAxisPosition({datum:t}),"mapsTo")},e.prototype.extendsDomain=function(t,e){var n=this.model.getOptions(),r=da.getProperty(n,"axes",t);return r.scaleType===I.TIME?function(t,e){var n=new Date(t[0]),r=new Date(t[1]);if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(jp(n,r));n.setFullYear(n.getFullYear()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Ug(n,e),Lp(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(Np(n,r));n.setMonth(n.getMonth()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Vg(n,e),Ap(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=wp(t),r=wp(e),i=Rp(n,r),o=Math.abs(Cp(n,r));n.setDate(n.getDate()-i*o);var a=Rp(n,r)===-i,s=i*(o-a);return 0===s?0:s}(r,n)>1)return[Ng(n,e),xp(r,e)];if(function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Bp(t,e)/36e5;return n>0?Math.floor(n):Math.ceil(n)}(r,n)>1)return[jg(n,e),Sp(r,e)];if(Vp(r,n)>30)return[Bg(n,30*e),Dp(r,30*e)];if(Vp(r,n)>1)return[Bg(n,e),Dp(r,e)];if(Hp(r,n)>15)return[Hg(n,15*e),kp(r,15*e)];if(Hp(r,n)>1)return[Hg(n,e),kp(r,e)];return[n,r]}(e,da.getProperty(n,"timeScale","addSpaceOnEdges")):function(t,e,n){var r=t[0],i=t[1],o=(i-r)*e,a=i<=0&&i+o>0?0:i+o,s=r>=0&&r-o<0?0:r-o;if(n===I.LOG&&s<=0){if(r<=0)throw Error("Data must have values greater than 0 if log scale type is used.");s=r}return[s,a]}(e,at.paddingRatio,r.scaleType)},e.prototype.findVerticalAxesPositions=function(){var t=this.model.getOptions(),e=da.getProperty(t,"axes"),n=this.isDualAxes();return null===da.getProperty(e,A.LEFT)&&null!==da.getProperty(e,A.RIGHT)||!0===da.getProperty(e,A.RIGHT,"main")||n&&da.getProperty(e,A.LEFT,"correspondingDatasets")?{primary:A.RIGHT,secondary:A.LEFT}:{primary:A.LEFT,secondary:A.RIGHT}},e.prototype.findHorizontalAxesPositions=function(){var t=this.model.getOptions(),e=da.getProperty(t,"axes"),n=this.isDualAxes();return null===da.getProperty(e,A.BOTTOM)&&null!==da.getProperty(e,A.TOP)||!0===da.getProperty(e,A.TOP,"main")||n&&da.getProperty(e,A.BOTTOM,"correspondingDatasets")?{primary:A.TOP,secondary:A.BOTTOM}:{primary:A.BOTTOM,secondary:A.TOP}},e.prototype.findDomainAndRangeAxesPositions=function(t,e){var n=this.model.getOptions(),r=da.getProperty(n,"axes",t.primary),i=da.getProperty(n,"axes",e.primary),o=r.scaleType||I.LINEAR,a=i.scaleType||I.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!==I.LABELS&&a!==I.TIME&&o===I.LABELS||o===I.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=da.getProperty(e,"axes",t),r=da.getProperty(e,"bounds"),i=n.includeZero,o=da.getProperty(n,"scaleType")||I.LINEAR;if(this.model.isDataEmpty())return[];var a,s,u=this.model.getDisplayData(),l=n.extendLinearDomainBy,c=n.mapsTo,f=n.percentage,h=n.thresholds,d=at.ratio,p=d.reference,g=d.compareTo;if(n.domain)return o===I.LABELS?n.domain:(o===I.TIME&&(n.domain=n.domain.map((function(t){return void 0===t.getTime?new Date(t):t}))),this.extendsDomain(t,n.domain));if(f)return[0,100];if(n&&o===I.LABELS)return us(u,(function(t){return t[c]})).keys();var m=this.model.getDataGroupNames();if(o===I.LABELS_RATIO)return u.map((function(t){return t[p]+"/"+t[g]}));if(o===I.TIME)s=u.map((function(t){return+new Date(t[c])}));else if(r&&e.axes)s=[],u.forEach((function(t){s.push(t[c]),t[r.upperBoundMapsTo]&&s.push(t[r.upperBoundMapsTo]),t[r.lowerBoundMapsTo]&&s.push(t[r.lowerBoundMapsTo])}));else if(!0===n.stacked&&m&&t===this.getRangeAxisPosition()){var v=e.data.groupMapsTo,y=this.model.getDataValuesGroupedByKeys(m),b=u.filter((function(t){return!m.includes(t[v])})),_=y.map((function(t){t.sharedStackKey;return Ts(function(t){var e=[];for(var n in t)e.push(t[n]);return e}(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}(t,["sharedStackKey"])))}));s=M(_,b.map((function(t){return t[c]})))}else s=[],u.forEach((function(t){var e=t[c];Array.isArray(e)&&2===e.length?(s.push(e[0]),s.push(e[1])):(l&&s.push(Math.max(t[c],t[l])),s.push(e))}));return o!==I.TIME&&o!==I.LOG&&i&&s.push(0),h&&h.length>0&&h.forEach((function(t){var e=da.getProperty(t,"value");null!==e&&s.push(e)})),a=gs(s),a=this.extendsDomain(t,a)},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=da.getProperty(e,"axes",t);if(!n)return null;var r,i=da.getProperty(n,"scaleType")||I.LINEAR;return this.scaleTypes[t]=i,(r=i===I.TIME?ef():i===I.LOG?function t(){var e=gl(Fu()).domain([1,10]);return e.copy=function(){return Uu(e,t()).base(e.base())},Ms.apply(e,arguments),e}().base(n.base||10):i===I.LABELS||i===I.LABELS_RATIO?Ls():sl()).domain(this.getScaleDomain(t)),r},e.prototype.getHighestDomainThreshold=function(){var t=da.getProperty(this.model.getOptions(),"axes"),e=this.getDomainAxisPosition(),n=t[e].thresholds;if(!n)return null;var r=this.getDomainScale(),i=n.sort((function(t,e){return e.value-t.value}))[0];return this.getScaleTypeByPosition(e)!==I.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=da.getProperty(this.model.getOptions(),"axes")[this.getRangeAxisPosition()].thresholds;if(!t)return null;var e=this.getRangeScale(),n=t.sort((function(t,e){return e.value-t.value}))[0];return{threshold:n,scaleValue:e(n.value)}},e}(Rh);var Gg=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:Pf,curveLinearClosed:dh,curveBasis:Wf,curveBasisClosed:qf,curveBasisOpen:Xf,curveBundle:$f,curveCardinal:th,curveCardinalClosed:nh,curveCardinalOpen:ih,curveCatmullRom:sh,curveCatmullRomClosed:lh,curveCatmullRomOpen:fh,curveMonotoneX:wh,curveMonotoneY:Oh,curveNatural:Sh,curveStep:Mh,curveStepAfter:Dh,curveStepBefore:Ch},e}return n(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}(Rh),zg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.isZoomBarEnabled=function(){if(!this.services.cartesianScales)return!1;if(!da.getProperty(this.model.getOptions(),"zoomBar","top","enabled"))return!1;this.services.cartesianScales.findDomainAndRangeAxes();var t=this.services.cartesianScales.getMainXAxisPosition(),e=da.getProperty(this.model.getOptions(),"axes",t,"scaleType");return t===A.BOTTOM&&e===I.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();return n.extendsDomain(r,gs(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(tt.ZoomDomain.CHANGE,{newDomain:t})},e.prototype.getZoomRatio=function(){return da.getProperty(this.model.getOptions(),"zoomBar","zoomRatio")},e.prototype.filterDataForRangeAxis=function(t,e){var n=this.model.get("zoomDomain"),r=Object.assign({stacked:!1},e),i=da.getProperty(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=bt.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 f=[r.invert(l),r.invert(c)];e[0].valueOf()===f[0].valueOf()&&e[1].valueOf()===f[1].valueOf()||this.handleDomainChange(f)}},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();return!(!t||!e)&&(t[1].valueOf()-t[0].valueOf())/(e[1].valueOf()-e[0].valueOf())<da.getProperty(this.model.getOptions(),"zoomBar","minZoomRatio")},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 da.getProperty(this.model.getOptions(),"zoomBar",t,"loading")},e.prototype.isZoomBarLocked=function(t){return da.getProperty(this.model.getOptions(),"zoomBar",t,"locked")},e}(Rh),Wg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.zoomIn=function(t,e,n){var r,i,o,a=n||st;t&&(r=t.x,i=t.y,o=2);var s=od.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(tt.CanvasZoom.CANVAS_ZOOM_IN,{element:va(t)})},e.prototype.zoomOut=function(t,e){var n=e||st;t.transition().duration(n.duration).ease(n.ease).attr("transform",""),this.services.events.dispatchEvent(tt.CanvasZoom.CANVAS_ZOOM_OUT)},e}(Rh),Yg=function(){function t(t,e,n){if(this.renderType=C.HTML,this.configs={},this.model=t,this.services=e,n&&(this.configs=n,this.configs.id)){var r=da.getProperty(this.model.getOptions(),"style","prefix");this.id=r+"--"+this.configs.id}this.parent||this.setParent(va(this.services.domUtils.getMainContainer()))}return t.prototype.init=function(){},t.prototype.render=function(t){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=da.getProperty(this.model.getOptions(),"style","prefix");this.parent.classed(Ih.prefix+"--"+n+"--"+this.type,!0).attr("id",this.id),e&&e.classed(Ih.prefix+"--"+n+"--"+this.type,!1).attr("id",this.id)}},t.prototype.getParent=function(){return this.parent},t.prototype.getComponentContainer=function(t){if(void 0===t&&(t={withinChartClip:!1}),this.type){var e=da.getProperty(this.model.getOptions(),"style","prefix"),n=this.id?"#"+this.id:"",r=od.appendOrSelect(this.parent,(this.renderType===C.SVG?"svg":"div")+n+"."+Ih.prefix+"--"+e+"--"+this.type);if(t.withinChartClip){var i=this.model.get("chartClipId");if(i){var o=va("#"+i).select("rect");0!==o.size()&&parseFloat(o.attr("height"))>0&&r.attr("clip-path","url(#"+i+")")}}return r.attr("width","100%").attr("height","100%")}return this.parent},t.prototype.getOptions=function(){return this.configs.options?da.merge({},this.model.getOptions(),this.configs.options):this.model.getOptions()},t}(),qg=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e.renderType=C.HTML,e}return n(e,t),e.prototype.render=function(){var t=this,e=this.getOptions(),n=da.getProperty(e,"legend"),i=da.getProperty(n,"alignment"),o=da.getProperty(e,"legend","orientation"),a=this.model.getDataGroups(),s=ft.items.status.DISABLED,u=a.some((function(t){return t.status===s})),l=da.getProperty(n,"order"),c=this.getComponentContainer().classed("center-aligned",i===j.CENTER).classed(o,!0).classed("has-deactivated-items",u).attr("role",r.GROUP).attr("data-name","legend-items");l&&(a=this.sortDataGroups(a,l));var f=c.selectAll("div.legend-item").data(a,(function(t){return t.name})),h=f.enter().append("div").attr("class","legend-item");h.merge(c.selectAll("div.legend-item")).classed("active",(function(t,e){return t.status===ft.items.status.ACTIVE}));var d=da.getProperty(this.getOptions(),"legend","clickable");c.classed("clickable",d);var p=ft.checkbox.radius,g=h.append("div").classed("checkbox",!0);g.merge(f.select("div.checkbox")).attr("role",r.CHECKBOX).attr("tabindex",d?0:-1).attr("aria-label",(function(t){return t.name})).attr("aria-checked",(function(t){return t.status===ft.items.status.ACTIVE})).attr("width",2*p).attr("height",2*p).attr("rx",1).attr("ry",1).attr("class",(function(e,n){return t.model.getColorClassName({classNameTypes:[P.BACKGROUND],dataGroupName:e.name,originalClassName:"checkbox"})})).style("background",(function(e){return e.status===ft.items.status.ACTIVE?t.model.getFillColor(e.name)||t.model.getStrokeColor(e.name):null})).classed("active",(function(t,e){return t.status===ft.items.status.ACTIVE}));g.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");var m=h.append("p").merge(f.select("p"));this.truncateLegendText(m);var v=da.getProperty(e,"legend","additionalItems");if(v&&a.length){var y=this,b=c.selectAll("div.additional-item").data(v);b.exit().remove();var _,w=b.enter().append("div").merge(b).classed("legend-item",!0).classed("additional",!0);w.selectAll("*").remove();var O=1;w.append("svg").classed("icon",!0).each((function(t,e){var n=va(this);_&&_==t.type?O++:(_=t.type,O=1),y.addAdditionalItem(n,t,O)}));var x=w.append("p").merge(w.select("p"));this.truncateLegendText(x)}f.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove(),d&&h.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;return t.slice(n).concat(t.slice(0,n))}return t},e.prototype.addAdditionalItem=function(t,e,n){var i=ft.area,o=i.width,a=i.height;if(e.type===Q.RADIUS?t.style("width",a+"px").style("height",a+"px"):t.style("width",o+"px").style("height",a+"px"),e.type===Q.RADIUS){var s=ft.radius,u=s.iconData,l=s.fill,c=s.stroke;t.attr("fill","none").selectAll("circle").data(u).enter().append("circle").classed("radius",!0).attr("role",r.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:l).style("stroke",e.stroke?e.stroke:c)}else if(e.type===Q.LINE){var f=ft.line;t.select("line.line").empty()&&t.append("line").classed("line-"+n,!0).attr("role",r.IMG).attr("aria-label","line").attr("x1",0).attr("y1",f.yPosition).attr("x2",o).attr("y2",f.yPosition).style("stroke",e.stroke?e.stroke:f.stroke).style("stroke-width",f.strokeWidth)}else if(e.type===Q.AREA)t.select("rect.area").empty()&&t.append("rect").classed("area-"+n,!0).attr("role",r.IMG).attr("aria-label","area").attr("width",o).attr("height",a).style("fill",n>3&&!e.fill?ft.area.fill:e.fill).style("stroke",e.stroke);else if(e.type===Q.SIZE){var h=ft.size;u=h.iconData,l=h.fill,c=h.stroke;t.attr("fill","none").attr("role",r.IMG).attr("aria-label","size").selectAll("rect").data(u).enter().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:l).style("stroke",e.stroke?e.stroke:c).style("stroke-width",1)}else if(e.type===Q.QUARTILE){u=ft.quartile.iconData;t.selectAll("rect").attr("role",r.IMG).attr("aria-label","quartile").data(u).enter().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===Q.ZOOM){var d=da.getProperty(as,"legend","zoom"),p=(u=d.iconData,d.color),g=t.attr("role",r.IMG).attr("aria-label","zoom").selectAll("g.icon").data(u).enter();g.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:p})),g.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:p}))}},e.prototype.truncateLegendText=function(t){var e=da.getProperty(this.getOptions(),"legend","truncation"),n=da.getProperty(e,"type"),r=da.getProperty(e,"threshold"),i=da.getProperty(e,"numCharacter");n!==L.NONE?t.html((function(t){return t.name.length>r?da.truncateLabel(t.name,n,i):t.name})):t.html((function(t){return t.name}))},e.prototype.addEventListeners=function(){var t=this,e=this.getComponentContainer(),n=this.getOptions(),r=da.getProperty(n,"legend"),i=da.getProperty(r,"truncation","threshold");e.selectAll("div.legend-item").on("mouseover",(function(){t.services.events.dispatchEvent(tt.Legend.ITEM_HOVER,{hoveredElement:va(this)});var e=va(this);e.select("div.checkbox").classed("hovered",!0);var n=e.datum();n.name.length>i&&t.services.events.dispatchEvent(tt.Tooltip.SHOW,{hoveredElement:e,content:n.name})})).on("mousemove",(function(){t.services.events.dispatchEvent(tt.Tooltip.MOVE)})).on("click",(function(){t.services.events.dispatchEvent(tt.Legend.ITEM_CLICK,{clickedElement:va(this)});var e=va(this).datum();t.model.toggleDataLabel(e.name)})).on("mouseout",(function(){var e=va(this);e.select("div.checkbox").classed("hovered",!1),t.services.events.dispatchEvent(tt.Tooltip.HIDE),t.services.events.dispatchEvent(tt.Legend.ITEM_MOUSEOUT,{hoveredElement:e})})),e.selectAll("div.legend-item div.checkbox").on("keyup",(function(e){!ia.key||"Enter"!==ia.key&&" "!==ia.key||(ia.preventDefault(),t.model.toggleDataLabel(e.name))})),e.selectAll("g.additional-item").on("mouseover",(function(){var e=va(this),n=e.datum();n.name.length>i&&t.services.events.dispatchEvent(tt.Tooltip.SHOW,{hoveredElement:e,content:n.name})}))},e}(Yg);function Zg(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Xg(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function Kg(t){return t.reduce((function(t,e){return Array.isArray(e)?t.push.apply(t,Xg(Kg(e))):t.push(e),t}),[])}function $g(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return Kg(e).reduce((function(t,e){return e(t)}),function(){return function t(){Zg(this,t)}}())}function Jg(t){return(Jg="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})(t)}function Qg(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function tm(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 em(t,e){return!e||"object"!==Jg(e)&&"function"!=typeof e?rm(t):e}function nm(t){return(nm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(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(t,e){return(im=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function om(t){return function(t){function e(t){var n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(Qg(this,e),(n=em(this,nm(e).call(this,t,r))).children=[],!t||t.nodeType!==Node.ELEMENT_NODE)throw new TypeError("DOM element should be given to initialize this widget.");return n.element=t,n.options=Object.assign(Object.create(n.constructor.options),r),n.constructor.components.set(n.element,rm(n)),n}var n,r,i;return function(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}}),e&&im(t,e)}(e,t),n=e,i=[{key:"create",value:function(t,e){return this.components.get(t)||new this(t,e)}}],(r=[{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}}])&&tm(n.prototype,r),i&&tm(n,i),e}(t)}function am(t){return(am="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})(t)}function sm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function um(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 lm(t,e){return!e||"object"!==am(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function cm(t){return(cm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function fm(t,e){return(fm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function hm(t){return function(t){function e(){return sm(this,e),lm(this,cm(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&fm(t,e)}(e,t),n=e,i=[{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.");e.nodeType===Node.ELEMENT_NODE&&e.matches(r.selectorInit)?this.create(e,n):Array.prototype.forEach.call(e.querySelectorAll(r.selectorInit),(function(e){return t.create(e,n)}))}}],(r=null)&&um(n.prototype,r),i&&um(n,i),e}(t)}function dm(t){return(dm="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})(t)}function pm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function gm(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 mm(t,e){return!e||"object"!==dm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function vm(t,e,n){return(vm="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=ym(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(n):i.value}})(t,e,n||t)}function ym(t){return(ym=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function bm(t,e){return(bm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _m(t){return function(t){function e(){var t,n;pm(this,e);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return(n=mm(this,(t=ym(e)).call.apply(t,[this].concat(i)))).handles=new Set,n}var n,r,i;return function(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}}),e&&bm(t,e)}(e,t),n=e,(r=[{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)})),vm(ym(e.prototype),"release",this).call(this)}}])&&gm(n.prototype,r),i&&gm(n,i),e}(t)}function wm(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 Om(t){return(Om="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})(t)}function xm(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 Em(t,e){return!e||"object"!==Om(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Sm(t){return(Sm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Tm(t,e){return(Tm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Mm={true:"true",false:"false",mixed:"mixed"};$g(om,hm,_m);function Cm(t){return(Cm="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})(t)}function Dm(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function Pm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Am(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 km(t,e){return!e||"object"!==Cm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Lm(t){return(Lm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Rm(t,e){return(Rm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Im(t){return function(t){function e(){return Pm(this,e),km(this,Lm(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&Rm(t,e)}(e,t),n=e,(r=[{key:"_changeState",value:function(){throw new Error("_changeState() should be overriden 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,f=!c.dispatchEvent(l);if(f){if(a){var h=new Error("Changing state (".concat(JSON.stringify(s),") has been canceled."));h.canceled=!0,a(h)}}else{var d=[i,o].filter(Boolean);this._changeState.apply(this,Dm(d).concat([function(){c.dispatchEvent(new CustomEvent(t.options["eventAfter".concat(u)],{bubbles:!0,cancelable:!0,detail:o})),a&&a()}]))}}else a&&a(null,!0)}}])&&Am(n.prototype,r),i&&Am(n,i),e}(t)}function Nm(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 jm(t){return(jm="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})(t)}function Bm(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Vm(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 Hm(t,e){return!e||"object"!==jm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Um(t){return(Um=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Fm(t,e){return(Fm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Gm=function(t){return Array.prototype.slice.call(t)};$g(om,hm,Im,_m);function zm(t){return(zm="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})(t)}function Wm(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 Ym(t,e){return!e||"object"!==zm(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function qm(t){return(qm=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Zm(t,e){return(Zm=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var Xm=function(t){return Array.prototype.slice.call(t)};$g(om,hm,Im,_m);function Km(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 $m(t){return($m="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})(t)}function Jm(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 tv(t,e){return!e||"object"!==$m(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function ev(t){return(ev=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function nv(t,e){return(nv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var rv=[Im,function(t){return function(t){function e(){return Jm(this,e),tv(this,ev(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&nv(t,e)}(e,t),n=e,(r=[{key:"show",value:function(t,e){t&&"function"!=typeof t||(e=t),this.changeState("shown",Km(t),e)}},{key:"hide",value:function(t,e){t&&"function"!=typeof t||(e=t),this.changeState("hidden",Km(t),e)}}])&&Qm(n.prototype,r),i&&Qm(n,i),e}(t)}];function iv(t){return(iv="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})(t)}function ov(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 av(t,e){return!e||"object"!==iv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function sv(t){return(sv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function uv(t,e){return(uv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var lv=[_m,function(t){return function(t){function e(t,n){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=av(this,sv(e).call(this,t,n));var i="onfocusin"in window,o=i?"focusin":"focus";return r.manage(wm(r.element.ownerDocument,o,(function(t){r.element.contains(t.target)||r.handleBlur(t)}),!i)),r}var n,r,i;return function(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}}),e&&uv(t,e)}(e,t),n=e,(r=[{key:"handleBlur",value:function(){throw new Error("Components inheriting TrackBlur mix-in must implement handleBlur() method.")}}])&&ov(n.prototype,r),i&&ov(n,i),e}(t)}],cv=function(){var t=[],e=!1;function n(){t.forEach((function(t){t()})),e=!1}function r(){e||(e=!0,window.requestAnimationFrame(n))}return{add:function(e){return t.length||window.addEventListener("resize",r),function(e){e&&t.indexOf(e)<0&&t.push(e)}(e),{release:function(){var n=t.indexOf(e);n>=0&&t.splice(n,1)}}}}}();function fv(t){return(fv="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})(t)}function hv(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 dv(t,e){return!e||"object"!==fv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function pv(t,e,n){return(pv="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=gv(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(n):i.value}})(t,e,n||t)}function gv(t){return(gv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function mv(t,e){return(mv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function vv(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var yv=function(t){function e(t,n){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var i=(r=dv(this,gv(e).call(this,t,n))).element.getAttribute(r.options.attribDirection);return r.options.direction||(r.options.direction=i||"bottom"),i||r.element.setAttribute(r.options.attribDirection,r.options.direction),r}var n,r,i;return function(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}}),e&&mv(t,e)}(e,t),n=e,(r=[{key:"handleBlur",value:function(t){if(this.element.classList.contains(this.options.classShown)){this.changeState("hidden",Km(t));var e=this.options,n=e.refNode,r=e.triggerNode;this.element.contains(t.relatedTarget)&&n&&t.target!==n&&HTMLElement.prototype.focus.call(r||n)}}},{key:"_getContainer",value:function(){return this.element.closest(this.options.selectorContainer)||this.element.ownerDocument.body}},{key:"_getPos",value:function(){var t=this.element,e=this.options,n=e.refNode,r=e.offset,i=e.direction;if(!n)throw new Error("Cannot find the refernce node for positioning floating menu.");return function(t){var e,n=t.menuSize,r=t.refPosition,i=t.offset,o=void 0===i?{}:i,a=t.direction,s=void 0===a?"bottom":a,u=t.scrollX,l=void 0===u?0:u,c=t.scrollY,f=void 0===c?0:c,h=r.left,d=void 0===h?0:h,p=r.top,g=void 0===p?0:p,m=r.right,v=void 0===m?0:m,y=r.bottom,b=void 0===y?0:y,_=n.width,w=n.height,O=o.top,x=void 0===O?0:O,E=o.left,S=void 0===E?0:E,T=(d+v)/2,M=(g+b)/2;return(e={},vv(e,"left",{left:d-_+l-S,top:M-w/2+f+x}),vv(e,"top",{left:T-_/2+l+S,top:g-w+f-x}),vv(e,"right",{left:v+l+S,top:M-w/2+f+x}),vv(e,"bottom",{left:T-_/2+l+S,top:b+f+x}),e)[s]}({menuSize:t.getBoundingClientRect(),refPosition:n.getBoundingClientRect(),offset:"function"!=typeof r?r:r(t,i,n),direction:i,scrollX:n.ownerDocument.defaultView.pageXOffset,scrollY:n.ownerDocument.defaultView.pageYOffset})}},{key:"_testStyles",value:function(){if(this.options.debugStyle){var t=this.element,e=t.ownerDocument.defaultView.getComputedStyle(t),n={position:"absolute",right:"auto",margin:0};Object.keys(n).forEach((function(t){("number"==typeof n[t]?parseFloat(n[t]):n[t])!==e.getPropertyValue(t)&&console.warn("Floating menu component expects ".concat(t,": ").concat(n[t]," style."))}))}}},{key:"_place",value:function(){var t=this.element,e=this._getPos(),n=e.left,r=e.top;t.style.left="".concat(n,"px"),t.style.top="".concat(r,"px"),this._testStyles()}},{key:"shouldStateBeChanged",value:function(t){return("shown"===t||"hidden"===t)&&t!==(this.element.classList.contains(this.options.classShown)?"shown":"hidden")}},{key:"_changeState",value:function(t,e,n){var r=this,i="shown"===t,o=this.options,a=o.refNode,s=o.classShown,u=o.classRefShown;if(!a)throw new TypeError("Cannot find the refernce node for changing the style.");this.element.classList.toggle(s,i),u&&a.classList.toggle(u,i),"shown"===t&&(this.hResize||(this.hResize=cv.add((function(){r._place()}))),this._getContainer().appendChild(this.element),this._place(),this.element.hasAttribute(this.options.attribAvoidFocusOnOpen)||(this.element.querySelector(this.options.selectorPrimaryFocus)||this.element).focus()),"hidden"===t&&this.hResize&&(this.hResize.release(),this.hResize=null),n()}},{key:"release",value:function(){this.hResize&&(this.hResize.release(),this.hResize=null),pv(gv(e.prototype),"release",this).call(this)}}])&&hv(n.prototype,r),i&&hv(n,i),e.options={selectorContainer:"[data-floating-menu-container]",selectorPrimaryFocus:"[data-floating-menu-primary-focus]",attribDirection:"data-floating-menu-direction",attribAvoidFocusOnOpen:"data-avoid-focus-on-open",classShown:"",classRefShown:"",eventBeforeShown:"floating-menu-beingshown",eventAfterShown:"floating-menu-shown",eventBeforeHidden:"floating-menu-beinghidden",eventAfterHidden:"floating-menu-hidden",refNode:null,offset:{left:0,top:0}},e.components=new WeakMap,e}($g(om,rv,lv));function bv(t){return(bv="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})(t)}function _v(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function wv(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 Ov(t,e){return!e||"object"!==bv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function xv(t){return(xv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Ev(t,e){return(Ev=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Sv(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var Tv=function(){var t;return Sv(t={},"top","bottom"),Sv(t,"bottom","top"),Sv(t,"left","left"),Sv(t,"right","right"),t}(),Mv=function(){var t;return Sv(t={},"top",-2),Sv(t,"bottom",-1),Sv(t,"left",-2),Sv(t,"right",-1),t}(),Cv=function(t,e,n){var r=Tv[e],i=Mv[e];r&&i||console.warn("Wrong floating menu direction:",e);var o=t.offsetWidth,a=t.offsetHeight,s=Dv.components.get(n);if(!s)throw new TypeError("Overflow menu instance cannot be found.");var u=t.classList.contains(s.options.classMenuFlip);return"top"===r||"bottom"===r?{left:(u?-1:1)*(o/2-n.offsetWidth/2),top:0}:"left"===r||"right"===r?{left:0,top:(u?-1:1)*(a/2-n.offsetHeight/2)}:void 0},Dv=function(t){function e(t,n){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=Ov(this,xv(e).call(this,t,n))).getCurrentNavigation=function(){var t=r.element.ownerDocument.activeElement;return t.nodeType===Node.ELEMENT_NODE&&t.matches(r.options.selectorItem)?t:null},r.navigate=function(t){for(var e=_v(r.element.ownerDocument.querySelectorAll(r.options.selectorItem)),n=r.getCurrentNavigation()||r.element.querySelector(r.options.selectorItemSelected),i=function(n){var r=Math.max(e.indexOf(n)+t,-1);return e[function(t,e){return t+(t>=0?0:e)}(function(t,e){return t-(t<e?0:e)}(r,e.length),e.length)]},o=i(n);o&&o!==n;o=i(o))if(!o.matches(r.options.selectorItemHidden)&&!o.parentNode.matches(r.options.selectorItemHidden)&&!o.matches(r.options.selectorItemSelected)){o.focus();break}},"button"!==r.element.getAttribute("role")&&(r.triggerNode=r.element.querySelector(r.options.selectorTrigger)),r.manage(wm(r.element.ownerDocument,"click",(function(t){r._handleDocumentClick(t),r.wasOpenBeforeClick=void 0}))),r.manage(wm(r.element.ownerDocument,"keydown",(function(t){r._handleKeyPress(t)}))),r.manage(wm(r.element,"mousedown",(function(){r.wasOpenBeforeClick=t.classList.contains(r.options.classShown)}))),r}var n,r,i;return function(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}}),e&&Ev(t,e)}(e,t),n=e,i=[{key:"options",get:function(){var t=Ih.prefix;return{selectorInit:"[data-overflow-menu]",selectorOptionMenu:".".concat(t,"--overflow-menu-options"),selectorTrigger:"button[aria-haspopup]",selectorItem:"\n .".concat(t,"--overflow-menu-options--open >\n .").concat(t,"--overflow-menu-options__option:not(.").concat(t,"--overflow-menu-options__option--disabled) >\n .").concat(t,"--overflow-menu-options__btn\n "),classShown:"".concat(t,"--overflow-menu--open"),classMenuShown:"".concat(t,"--overflow-menu-options--open"),classMenuFlip:"".concat(t,"--overflow-menu--flip"),objMenuOffset:Cv,objMenuOffsetFlip:Cv}}}],(r=[{key:"changeState",value:function(t,e,n){var r=this.triggerNode?"triggerNode":"element";if("hidden"===t?this[r].setAttribute("aria-expanded","false"):this[r].setAttribute("aria-expanded","true"),!this.optionMenu){var i=this.element.querySelector(this.options.selectorOptionMenu);if(!i)throw new Error("Cannot find the target menu.");this.optionMenu=yv.create(i,{refNode:this.element,classShown:this.options.classMenuShown,classRefShown:this.options.classShown,offset:this.options.objMenuOffset,triggerNode:this.triggerNode}),this.children.push(this.optionMenu)}this.optionMenu.element.classList.contains(this.options.classMenuFlip)&&(this.optionMenu.options.offset=this.options.objMenuOffsetFlip),this.optionMenu.changeState(t,Object.assign(e,{delegatorNode:this.element}),n)}},{key:"_handleDocumentClick",value:function(t){var e=this,n=this.element,r=this.optionMenu,i=this.wasOpenBeforeClick,o=this.triggerNode,a=n.contains(t.target),s=r&&r.element.contains(t.target),u=a&&!i?"shown":"hidden";a&&("A"===n.tagName&&t.preventDefault(),t.delegateTarget=n),s&&!Nm(t,this.options.selectorItem)||this.changeState(u,Km(t),(function(){"hidden"===u&&s&&e[o?"triggerNode":"element"].focus()}))}},{key:"_handleKeyPress",value:function(t){var e=this,n=t.which,r=this.element,i=this.optionMenu,o=this.options,a=this.triggerNode,s=i&&i.element.contains(t.target),u=this.element.classList.contains(this.options.classShown),l=a?"triggerNode":"element";switch(n){case 27:this.changeState("hidden",Km(t),(function(){s&&e[l].focus()}));break;case 13:case 32:if(!u&&this.element.ownerDocument.activeElement!==this.element)return;var c=r.contains(t.target),f=c&&!r.classList.contains(o.classShown)?"shown":"hidden";c&&(t.delegateTarget=r,t.preventDefault(),this.changeState(f,Km(t),(function(){"hidden"===f&&s&&e[l].focus()})));break;case 38:case 40:if(!u)return;t.preventDefault();var h={38:-1,40:1}[t.which];this.navigate(h)}}}])&&wv(n.prototype,r),i&&wv(n,i),e.components=new WeakMap,e}($g(om,hm,rv,_m)),Pv=function(){};"production"!==process.env.NODE_ENV&&(Pv=function(t,e,n){var r=arguments.length;n=new Array(r>2?r-2:0);for(var i=2;i<r;i++)n[i-2]=arguments[i];if(void 0===e)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(e.length<10||/^[s\W]*$/.test(e))throw new Error("The warning format should be able to uniquely identify this warning. Please, use a more descriptive format than: "+e);if(!t){var o=0,a="Warning: "+e.replace(/%s/g,(function(){return n[o++]}));"undefined"!=typeof console&&console.error(a);try{throw new Error(a)}catch(t){}}});var Av=Pv;function kv(t){return(kv="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})(t)}function Lv(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Rv(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 Iv(t,e){return!e||"object"!==kv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Nv(t){return(Nv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function jv(t,e){return(jv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Bv(t){return function(t){function e(){return Lv(this,e),Iv(this,Nv(e).apply(this,arguments))}var n,r,i;return function(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}}),e&&jv(t,e)}(e,t),n=e,i=[{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 wm(e,i,(function(e){var i=Nm(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),""}}],(r=null)&&Rv(n.prototype,r),i&&Rv(n,i),e.forLazyInit=!0,e}(t)}function Vv(t){return(Vv="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})(t)}function Hv(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 Uv(t,e){return!e||"object"!==Vv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Fv(t){return(Fv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Gv(t,e){return(Gv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var zv=function(t){function e(t,n){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=Uv(this,Fv(e).call(this,t,n)))._handleFocusinListener=void 0,r._handleKeydownListener=void 0,r._handleFocusin=function(t){r.element.classList.contains(r.options.classVisible)&&!r.element.contains(t.target)&&r.options.selectorsFloatingMenus.every((function(e){return!Nm(t,e)}))&&r.element.querySelector(Ih.selectorTabbable).focus()},r._hookCloseActions(),r}var n,r,i;return function(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}}),e&&Gv(t,e)}(e,t),n=e,i=[{key:"options",get:function(){var t=Ih.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"],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"}}}],(r=[{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;if(this._handleFocusinListener&&(this._handleFocusinListener=this.unmanage(this._handleFocusinListener).release()),"shown"===t){var o="onfocusin"in this.element.ownerDocument.defaultView,a=o?"focusin":"focus";this._handleFocusinListener=this.manage(wm(this.element.ownerDocument,a,this._handleFocusin,!o))}"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(wm(this.element,"transitionend",(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(Ih.selectorTabbable);e.focus(),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&Av(e,"Modals need to contain a focusable element by either using "+"`".concat(i.options.selectorPrimaryFocus,"` or settings.selectorTabbable."))}n()})))}},{key:"_hookCloseActions",value:function(){var t=this;this.manage(wm(this.element,"click",(function(e){var n=Nm(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(wm(this.element.ownerDocument.body,"keydown",(function(e){27===e.which&&t.shouldStateBeChanged("hidden")&&(e.stopPropagation(),t.hide(e))})))}}])&&Hv(n.prototype,r),i&&Hv(n,i),e.components=new WeakMap,e}($g(om,Bv,rv,_m));function Wv(t){return(Wv="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})(t)}function Yv(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 qv(t,e){return!e||"object"!==Wv(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function Zv(t){return(Zv=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function Xv(t,e){return(Xv=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function Kv(t,e,n){n?t.setAttribute(e,""):t.removeAttribute(e)}function $v(t){return($v="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})(t)}function Jv(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 Qv(t,e){return!e||"object"!==$v(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function ty(t){return(ty=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ey(t,e){return(ey=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function ny(t){return(ny="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})(t)}function ry(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 iy(t,e){return!e||"object"!==ny(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function oy(t){return(oy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function ay(t,e){return(ay=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var sy=function(t){return Array.prototype.slice.call(t)};$g(om,hm,lv);function uy(t){return(uy="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})(t)}function ly(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 cy(t,e){return!e||"object"!==uy(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function fy(t){return(fy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function hy(t,e){return(hy=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}$g(om,hm,_m);function dy(t){return(dy="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})(t)}function py(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function gy(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 my(t,e){return!e||"object"!==dy(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}function vy(t){return(vy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function yy(t,e){return(yy=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}var by=function(t){return Array.prototype.slice.call(t)},_y=($g(om,hm,Im),xa((function(t,e){
16
16
  /* flatpickr v4.6.1, @license MIT */
17
17
  t.exports=function(){
18
18
  /*! *****************************************************************************