victory-cursor-container 37.0.0 → 37.0.1-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/victory-cursor-container.js +2 -2
- package/dist/victory-cursor-container.min.js +1 -1
- package/es/cursor-helpers.d.ts +32 -32
- package/es/index.d.ts +2 -2
- package/es/victory-cursor-container.d.ts +133 -133
- package/es/victory-cursor-container.js +2 -2
- package/lib/cursor-helpers.d.ts +32 -32
- package/lib/index.d.ts +2 -2
- package/lib/victory-cursor-container.d.ts +133 -133
- package/lib/victory-cursor-container.js +2 -2
- package/package.json +2 -5
- package/src/victory-cursor-container.tsx +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -171,7 +171,7 @@ function cursorContainerMixin(Base) {
|
|
|
171
171
|
},
|
|
172
172
|
cursorComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_5__.LineSegment, null)
|
|
173
173
|
};
|
|
174
|
-
static defaultEvents
|
|
174
|
+
static defaultEvents(props) {
|
|
175
175
|
return [{
|
|
176
176
|
target: "parent",
|
|
177
177
|
eventHandlers: {
|
|
@@ -189,7 +189,7 @@ function cursorContainerMixin(Base) {
|
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
191
|
}];
|
|
192
|
-
}
|
|
192
|
+
}
|
|
193
193
|
getCursorPosition(props) {
|
|
194
194
|
const {
|
|
195
195
|
cursorValue,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react")):"function"==typeof define&&define.amd?define(["react"],e):"object"==typeof exports?exports.VictoryCursorContainer=e(require("react")):t.VictoryCursorContainer=e(t.React)}(self,(function(t){return function(){var e={503:function(t,e,n){var r=n(1171),o=n(7838),i=n(4859),a=n(4073),s=n(8541);function c(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])}}c.prototype.clear=r,c.prototype.delete=o,c.prototype.get=i,c.prototype.has=a,c.prototype.set=s,t.exports=c},2596:function(t,e,n){var r=n(2373).Symbol;t.exports=r},6082:function(t){t.exports=function(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)}},8644:function(t){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}},9559:function(t){t.exports=function(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}},4132:function(t,e,n){var r=n(8347),o=n(788),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var a=t[e];i.call(t,e)&&o(a,n)&&(void 0!==n||e in t)||r(t,e,n)}},3162:function(t,e,n){var r=n(788);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},8347:function(t,e,n){var r=n(5525);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},6457:function(t,e,n){var r=n(9559),o=n(3608);t.exports=function t(e,n,i,a,s){var c=-1,u=e.length;for(i||(i=o),s||(s=[]);++c<u;){var l=e[c];n>0&&i(l)?n>1?t(l,n-1,i,a,s):r(s,l):a||(s[s.length]=l)}return s}},4432:function(t,e,n){var r=n(9026),o=n(3110);t.exports=function(t,e){for(var n=0,i=(e=r(e,t)).length;null!=t&&n<i;)t=t[o(e[n++])];return n&&n==i?t:void 0}},563:function(t){var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},6776:function(t){t.exports=function(t,e){return null!=t&&e in Object(t)}},7190:function(t,e,n){var r=n(5125)(Object.keys,Object);t.exports=r},5436:function(t,e,n){var r=n(6371),o=n(5066);t.exports=function(t,e){return r(t,e,(function(e,n){return o(t,n)}))}},6371:function(t,e,n){var r=n(4432),o=n(6539),i=n(9026);t.exports=function(t,e,n){for(var a=-1,s=e.length,c={};++a<s;){var u=e[a],l=r(t,u);n(l,u)&&o(c,i(u,t),l)}return c}},1600:function(t){t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},3301:function(t,e,n){var r=n(4432);t.exports=function(t){return function(e){return r(e,t)}}},6317:function(t,e,n){var r=n(5346),o=n(4280),i=n(201);t.exports=function(t,e){return i(o(t,e,r),t+"")}},6539:function(t,e,n){var r=n(4132),o=n(9026),i=n(9099),a=n(7709),s=n(3110);t.exports=function(t,e,n,c){if(!a(t))return t;for(var u=-1,l=(e=o(e,t)).length,d=l-1,p=t;null!=p&&++u<l;){var f=s(e[u]),h=n;if("__proto__"===f||"constructor"===f||"prototype"===f)return t;if(u!=d){var g=p[f];void 0===(h=c?c(g,f,p):void 0)&&(h=a(g)?g:i(e[u+1])?[]:{})}r(p,f,h),p=p[f]}return t}},6316:function(t,e,n){var r=n(2596),o=n(8644),i=n(163),a=n(1995),s=r?r.prototype:void 0,c=s?s.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(i(e))return o(e,t)+"";if(a(e))return c?c.call(e):"";var n=e+"";return"0"==n&&1/e==-1/0?"-0":n}},9026:function(t,e,n){var r=n(163),o=n(726),i=n(7801),a=n(7010);t.exports=function(t,e){return r(t)?t:o(t,e)?[t]:i(a(t))}},5525:function(t,e,n){var r=n(3743),o=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=o},5557:function(t,e,n){var r=n(2645),o=n(4280),i=n(201);t.exports=function(t){return i(o(t,void 0,r),t+"")}},2117:function(t,e,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;t.exports=r},3743:function(t){t.exports=function(t,e){return null==t?void 0:t[e]}},9667:function(t){var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},3096:function(t,e,n){var r=n(9026),o=n(5075),i=n(163),a=n(9099),s=n(8454),c=n(3110);t.exports=function(t,e,n){for(var u=-1,l=(e=r(e,t)).length,d=!1;++u<l;){var p=c(e[u]);if(!(d=null!=t&&n(t,p)))break;t=t[p]}return d||++u!=l?d:!!(l=null==t?0:t.length)&&s(l)&&a(p,l)&&(i(t)||o(t))}},3608:function(t,e,n){var r=n(2596),o=n(5075),i=n(163),a=r?r.isConcatSpreadable:void 0;t.exports=function(t){return i(t)||o(t)||!!(a&&t&&t[a])}},9099:function(t){var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,n){var r=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==r||"symbol"!=r&&e.test(t))&&t>-1&&t%1==0&&t<n}},8286:function(t){t.exports=function(){return!1}},726:function(t,e,n){var r=n(163),o=n(1995),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(r(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!o(t))||a.test(t)||!i.test(t)||null!=e&&t in Object(e)}},5782:function(t){t.exports=function(){return!1}},1171:function(t){t.exports=function(){this.__data__=[],this.size=0}},7838:function(t,e,n){var r=n(3162),o=Array.prototype.splice;t.exports=function(t){var e=this.__data__,n=r(e,t);return!(n<0||(n==e.length-1?e.pop():o.call(e,n,1),--this.size,0))}},4859:function(t,e,n){var r=n(3162);t.exports=function(t){var e=this.__data__,n=r(e,t);return n<0?void 0:e[n][1]}},4073:function(t,e,n){var r=n(3162);t.exports=function(t){return r(this.__data__,t)>-1}},8541:function(t,e,n){var r=n(3162);t.exports=function(t,e){var n=this.__data__,o=r(n,t);return o<0?(++this.size,n.push([t,e])):n[o][1]=e,this}},2453:function(t){t.exports=function(t){return t}},5125:function(t){t.exports=function(t,e){return function(n){return t(e(n))}}},4280:function(t,e,n){var r=n(6082),o=Math.max;t.exports=function(t,e,n){return e=o(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,s=o(i.length-e,0),c=Array(s);++a<s;)c[a]=i[e+a];a=-1;for(var u=Array(e+1);++a<e;)u[a]=i[a];return u[e]=n(c),r(t,this,u)}}},2373:function(t,e,n){var r=n(2117),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();t.exports=i},201:function(t){t.exports=function(t){return t}},7801:function(t,e,n){var r=n(2453),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=r((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(o,(function(t,n,r,o){e.push(r?o.replace(i,"$1"):n||t)})),e}));t.exports=a},3110:function(t,e,n){var r=n(1995);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},5034:function(t,e,n){var r=n(7709),o=n(6987),i=n(5812),a=Math.max,s=Math.min;t.exports=function(t,e,n){var c,u,l,d,p,f,h=0,g=!1,y=!1,v=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function m(e){var n=c,r=u;return c=u=void 0,h=e,d=t.apply(r,n)}function x(t){return h=t,p=setTimeout(w,e),g?m(t):d}function b(t){var n=t-f;return void 0===f||n>=e||n<0||y&&t-h>=l}function w(){var t=o();if(b(t))return S(t);p=setTimeout(w,function(t){var n=e-(t-f);return y?s(n,l-(t-h)):n}(t))}function S(t){return p=void 0,v&&c?m(t):(c=u=void 0,d)}function A(){var t=o(),n=b(t);if(c=arguments,u=this,f=t,n){if(void 0===p)return x(f);if(y)return clearTimeout(p),p=setTimeout(w,e),m(f)}return void 0===p&&(p=setTimeout(w,e)),d}return e=i(e)||0,r(n)&&(g=!!n.leading,l=(y="maxWait"in n)?a(i(n.maxWait)||0,e):l,v="trailing"in n?!!n.trailing:v),A.cancel=function(){void 0!==p&&clearTimeout(p),h=0,c=f=u=p=void 0},A.flush=function(){return void 0===p?d:S(o())},A}},1893:function(t,e,n){var r=n(6317),o=n(788),i=n(8286),a=n(8855),s=Object.prototype,c=s.hasOwnProperty,u=r((function(t,e){t=Object(t);var n=-1,r=e.length,u=r>2?e[2]:void 0;for(u&&i(e[0],e[1],u)&&(r=1);++n<r;)for(var l=e[n],d=a(l),p=-1,f=d.length;++p<f;){var h=d[p],g=t[h];(void 0===g||o(g,s[h])&&!c.call(t,h))&&(t[h]=l[h])}return t}));t.exports=u},788:function(t){t.exports=function(t,e){return t===e||t!=t&&e!=e}},2645:function(t,e,n){var r=n(6457);t.exports=function(t){return null!=t&&t.length?r(t,1):[]}},5066:function(t,e,n){var r=n(6776),o=n(3096);t.exports=function(t,e){return null!=t&&o(t,e,r)}},5346:function(t){t.exports=function(t){return t}},5075:function(t){t.exports=function(){return!1}},163:function(t){var e=Array.isArray;t.exports=e},981:function(t,e,n){var r=n(9642),o=n(8454);t.exports=function(t){return null!=t&&o(t.length)&&!r(t)}},4801:function(t){t.exports=function(){return!1}},4155:function(t,e,n){var r=n(7190),o=n(9667),i=n(5075),a=n(163),s=n(981),c=n(4801),u=n(5782),l=n(4289),d=Object.prototype.hasOwnProperty;t.exports=function(t){if(null==t)return!0;if(s(t)&&(a(t)||"string"==typeof t||"function"==typeof t.splice||c(t)||l(t)||i(t)))return!t.length;var e=o(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(u(t))return!r(t).length;for(var n in t)if(d.call(t,n))return!1;return!0}},9642:function(t,e,n){var r=n(563),o=n(7709);t.exports=function(t){if(!o(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},8454:function(t){t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},7709:function(t){t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},1995:function(t){t.exports=function(){return!1}},4289:function(t){t.exports=function(){return!1}},8855:function(t){t.exports=function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}},1594:function(t,e,n){var r=n(503);function o(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=t.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(o.Cache||r),n}o.Cache=r,t.exports=o},6987:function(t,e,n){var r=n(2373);t.exports=function(){return r.Date.now()}},9082:function(t,e,n){var r=n(5436),o=n(5557)((function(t,e){return null==t?{}:r(t,e)}));t.exports=o},8532:function(t,e,n){var r=n(1600),o=n(3301),i=n(726),a=n(3110);t.exports=function(t){return i(t)?r(a(t)):o(t)}},8163:function(t,e,n){var r=n(5034),o=n(7709);t.exports=function(t,e,n){var i=!0,a=!0;if("function"!=typeof t)throw new TypeError("Expected a function");return o(n)&&(i="leading"in n?!!n.leading:i,a="trailing"in n?!!n.trailing:a),r(t,e,{leading:i,maxWait:e,trailing:a})}},5812:function(t){t.exports=function(t){return t}},7010:function(t,e,n){var r=n(6316);t.exports=function(t){return null==t?"":r(t)}},660:function(t,e,n){var r=n(7010),o=0;t.exports=function(t){var e=++o;return r(t)+e}},9787:function(e){"use strict";e.exports=t}},n={};function r(t){var o=n[t];if(void 0!==o)return o.exports;var i=n[t]={exports:{}};return e[t](i,i.exports,r),i.exports}r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};return function(){"use strict";r.r(o),r.d(o,{CursorHelpers:function(){return m},VictoryCursorContainer:function(){return Ht},cursorContainerMixin:function(){return Tt}});var t=r(8163),e=r.n(t),n=(r(9082),r(8532),r(1893)),i=r.n(n),a=r(9787),s=r.n(a);function c(t,e){void 0===e&&(e=[]);const n={};for(const r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}function u(t){const e=t=>void 0!==t,{_x:n,_x1:r,_x0:o,_voronoiX:a,_y:s,_y1:c,_y0:u,_voronoiY:l}=t,d=e(r)?r:n,p=e(c)?c:s,f={x:e(a)?a:d,x0:e(o)?o:n,y:e(l)?l:p,y0:e(u)?u:s};return i()({},f,t)}function l(t,e){void 0===e&&(e="padding");const n=t[e],r="number"==typeof n?n:0,o="object"==typeof n?n:{};return{top:o.top||r,bottom:o.bottom||r,left:o.left||r,right:o.right||r}}function d(t,e){return f(t)?t(e):t}function p(t,e){return e.disableInlineStyles?{}:t&&Object.keys(t).some((e=>f(t[e])))?Object.keys(t).reduce(((n,r)=>(n[r]=d(t[r],e),n)),{}):t}function f(t){return"function"==typeof t}function h(t,e){if(t)return Object.keys(t).reduce(((n,r)=>(n[r]=e(t[r]),n)),{})}function g(t,e,n){const{a:r,d:o,e:i,f:a}=e;return"y"===n?o*t+a:r*t+i}function y(t){return!(!t||void 0===t.identifier)}function v(t){if(y(t.nativeEvent))return;const e=t=>"svg"===t.nodeName?t:t.parentNode?e(t.parentNode):t;return e(t.target)}const m=new class{getDimension(t){const{horizontal:e,cursorDimension:n}=t;return e&&n?"x"===n?"y":"x":n}withinBounds(t,e){const{x1:n,x2:r,y1:o,y2:i}=h(e,Number),{x:a,y:s}=h(t,Number);return a>=Math.min(n,r)&&a<=Math.max(n,r)&&s>=Math.min(o,i)&&s<=Math.max(o,i)}handleMouseMove=(t,e)=>{const{onCursorChange:n,domain:r}=e,o=this.getDimension(e),i=e.parentSVG||v(t),a=function(t,e){if(y(t.nativeEvent))return{x:t.nativeEvent.locationX,y:t.nativeEvent.locationY};const n=function(t){return t.changedTouches&&t.changedTouches.length>0}(t)?t.changedTouches[0]:t,r=function(t){return t.getScreenCTM().inverse()}(e||v(n));return{x:g(n.clientX,r,"x"),y:g(n.clientY,r,"y")}}(t,i);let s=function(t,e,n,r){const{polar:o,horizontal:i}=t;if(!o)return{x:i?e.x.invert(r):e.x.invert(n),y:i?e.y.invert(n):e.y.invert(r)};const a=t.origin||{x:0,y:0},s=n-a.x,c=r-a.y,u=Math.abs(s*Math.sqrt(1+Math.pow(-c/s,2))),l=(-Math.atan2(c,s)+2*Math.PI)%(2*Math.PI);return{x:e.x.invert(l),y:e.y.invert(u)}}(e,e.scale,a.x,a.y);return this.withinBounds(s,{x1:r.x[0],x2:r.x[1],y1:r.y[0],y2:r.y[1]})||(s=null),f(n)&&(s?n(o?s[o]:s,e):s!==e.cursorValue&&n(e.defaultCursorValue||null,e)),[{target:"parent",eventKey:"parent",mutation:()=>({cursorValue:s,parentSVG:i})}]};onMouseMove=e()(this.handleMouseMove,16,{leading:!0,trailing:!1});onMouseLeave=this.handleMouseMove;onTouchEnd=(t,e)=>{const{onCursorChange:n}=e;return f(e.onCursorChange)&&n(null,e),[{target:"parent",eventKey:"parent",mutation:()=>({cursorValue:null})}]}};var x=r(7709),b=r.n(x),w=r(660),S=r.n(w);class A extends s().Component{static displayName="Portal";constructor(t){super(t),this.map={},this.index=1}portalRegister=()=>++this.index;portalUpdate=(t,e)=>{this.map[t]=e,this.forceUpdate()};portalDeregister=t=>{delete this.map[t],this.forceUpdate()};getChildren(){return Object.keys(this.map).map((t=>{const e=this.map[t];return e?s().cloneElement(e,{key:t}):e}))}render(){return s().createElement("svg",this.props,this.getChildren())}}const C=s().createContext({});C.displayName="PortalContext";var j,E,O=0,P=0,M=0,k=0,_=0,z=0,I="object"==typeof performance&&performance.now?performance:Date,T="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function H(){return _||(T(R),_=I.now()+z)}function R(){_=0}function N(){this._call=this._time=this._next=null}function $(t,e,n){var r=new N;return r.restart(t,e,n),r}function F(){_=(k=I.now())+z,O=P=0;try{!function(){H(),++O;for(var t,e=j;e;)(t=_-e._time)>=0&&e._call.call(void 0,t),e=e._next;--O}()}finally{O=0,function(){for(var t,e,n=j,r=1/0;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:j=e);E=t,L(r)}(),_=0}}function D(){var t=I.now(),e=t-k;e>1e3&&(z-=e,k=t)}function L(t){O||(P&&(P=clearTimeout(P)),t-_>24?(t<1/0&&(P=setTimeout(F,t-I.now()-z)),M&&(M=clearInterval(M))):(M||(k=I.now(),M=setInterval(D,1e3)),O=1,T(F)))}N.prototype=$.prototype={constructor:N,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?H():+n)+(null==e?0:+e),this._next||E===this||(E?E._next=this:j=this,E=this),this._call=t,this._time=n,L()},stop:function(){this._call&&(this._call=null,this._time=1/0,L())}};class W{constructor(){this.shouldAnimate=!0,this.subscribers=[],this.timer=null,this.activeSubscriptions=0}bypassAnimation(){this.shouldAnimate=!1}resumeAnimation(){this.shouldAnimate=!0}loop=()=>{this.subscribers.forEach((t=>{t.callback(H()-t.startTime,t.duration)}))};start(){this.timer||(this.timer=$(this.loop))}stop(){this.timer&&(this.timer.stop(),this.timer=null)}subscribe(t,e){const n=this.subscribers.push({startTime:H(),callback:t,duration:this.shouldAnimate?e:0});return this.activeSubscriptions++,this.start(),n}unsubscribe(t){null!==t&&this.subscribers[t-1]&&(delete this.subscribers[t-1],this.activeSubscriptions--),0===this.activeSubscriptions&&this.stop()}}const V=s().createContext({transitionTimer:new W,animationTimer:new W});V.displayName="TimerContext";var U=V;const B={startsWith:["data-","aria-"],exactMatch:[]},G=t=>{const e={...t};return Object.fromEntries(Object.entries(e).filter((t=>{let[e]=t;return(t=>!(!(t=>{let e=!1;return B.startsWith.forEach((n=>{new RegExp(`\\b(${n})(\\w|-)+`,"g").test(t)&&(e=!0)})),e})(t)&&!(t=>B.exactMatch.includes(t))(t)))(e)})).map((e=>{let[n,r]=e;return[n,d(r,t)]})))};function K(){return K=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},K.apply(this,arguments)}class q extends s().Component{static displayName="VictoryContainer";static role="container";static defaultProps={className:"VictoryContainer",portalComponent:s().createElement(A,null),portalZIndex:99,responsive:!0,role:"img"};static contextType=U;constructor(t){super(t),this.containerId=b()(t)&&void 0!==t.containerId?t.containerId:S()("victory-container-"),this.shouldHandleWheel=!!(t&&t.events&&t.events.onWheel)}savePortalRef=t=>(this.portalRef=t,t);portalUpdate=(t,e)=>this.portalRef.portalUpdate(t,e);portalRegister=()=>this.portalRef.portalRegister();portalDeregister=t=>this.portalRef.portalDeregister(t);saveContainerRef=t=>(f(this.props.containerRef)&&this.props.containerRef(t),this.containerRef=t,t);handleWheel=t=>t.preventDefault();componentDidMount(){this.shouldHandleWheel&&this.containerRef&&this.containerRef.addEventListener("wheel",this.handleWheel)}componentWillUnmount(){this.shouldHandleWheel&&this.containerRef&&this.containerRef.removeEventListener("wheel",this.handleWheel)}getIdForElement(t){return`${this.containerId}-${t}`}getChildren(t){return t.children}getOUIAProps(t){const{ouiaId:e,ouiaSafe:n,ouiaType:r}=t;return{...e&&{"data-ouia-component-id":e},...r&&{"data-ouia-component-type":r},...void 0!==n&&{"data-ouia-safe":n}}}renderContainer(t,e,n){const{title:r,desc:o,portalComponent:a,className:c,width:u,height:l,portalZIndex:d,responsive:p}=t,f=this.getChildren(t),h=p?{width:"100%",height:"100%"}:{width:u,height:l},g=Object.assign({pointerEvents:"none",touchAction:"none",position:"relative"},h),y=Object.assign({zIndex:d,position:"absolute",top:0,left:0},h),v=Object.assign({pointerEvents:"all"},h),m=Object.assign({overflow:"visible"},h),x={width:u,height:l,viewBox:e.viewBox,preserveAspectRatio:e.preserveAspectRatio,style:m};return s().createElement(C.Provider,{value:{portalUpdate:this.portalUpdate,portalRegister:this.portalRegister,portalDeregister:this.portalDeregister}},s().createElement("div",K({style:i()({},n,g),className:c,ref:this.saveContainerRef},this.getOUIAProps(t)),s().createElement("svg",K({},e,{style:v}),r?s().createElement("title",{id:this.getIdForElement("title")},r):null,o?s().createElement("desc",{id:this.getIdForElement("desc")},o):null,f),s().createElement("div",{style:y},s().cloneElement(a,{...x,ref:this.savePortalRef}))))}render(){const{width:t,height:e,responsive:n,events:r,title:o,desc:i,tabIndex:a,preserveAspectRatio:s,role:u}=this.props,l=n?this.props.style:c(this.props.style,["height","width"]),d=G(this.props),p=Object.assign({width:t,height:e,tabIndex:a,role:u,"aria-labelledby":[o&&this.getIdForElement("title"),this.props["aria-labelledby"]].filter(Boolean).join(" ")||void 0,"aria-describedby":[i&&this.getIdForElement("desc"),this.props["aria-describedby"]].filter(Boolean).join(" ")||void 0,viewBox:n?`0 0 ${t} ${e}`:void 0,preserveAspectRatio:n?s:void 0,...d},r);return this.renderContainer(this.props,p,l)}}var Z=r(4155),X=r.n(Z);class Y extends s().Component{static displayName="VictoryPortal";static role="portal";static defaultProps={groupComponent:s().createElement("g",null)};static contextType=C;componentDidMount(){this.checkedContext||("function"!=typeof this.context.portalUpdate&&(this.renderInPlace=!0),this.checkedContext=!0),this.forceUpdate()}componentDidUpdate(){this.renderInPlace||(this.portalKey=this.portalKey||this.context.portalRegister(),this.context.portalUpdate(this.portalKey,this.element))}componentWillUnmount(){this.context&&this.context.portalDeregister&&this.context.portalDeregister(this.portalKey)}renderPortal(t){return this.renderInPlace?t:(this.element=t,null)}render(){const t=Array.isArray(this.props.children)?this.props.children[0]:this.props.children,{groupComponent:e}=this.props,n=t&&t.props||{},r=n.groupComponent?{groupComponent:e,standalone:!1}:{},o=i()(r,n,c(this.props,["children","groupComponent"])),a=t&&s().cloneElement(t,o);return this.renderPortal(a)}}function J(){return J=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},J.apply(this,arguments)}const Q=(0,a.forwardRef)(((t,e)=>{const{desc:n,id:r,tabIndex:o,origin:i,...a}=t,c={vectorEffect:"non-scaling-stroke",id:d(r,t)?.toString(),tabIndex:d(o,t),...a};return n?s().createElement("rect",J({},c,{ref:e}),s().createElement("desc",null,n)):s().createElement("rect",J({},c,{ref:e}))})),tt=t=>{const{children:e,desc:n,id:r,origin:o,tabIndex:i,title:a,...c}=t,u={id:d(r,t)?.toString(),tabIndex:d(i,t),...c};return s().createElement("text",u,a&&s().createElement("title",null,a),n&&s().createElement("desc",null,n),e)},et=t=>{const{desc:e,id:n,tabIndex:r,origin:o,...i}=t,a={id:d(n,t)?.toString(),tabIndex:d(r,t),...i};return s().createElement("tspan",a)};const nt=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];if(n.length>0)return n.reduce(((t,e)=>[t,nt(e)].join(" ")),nt(t)).trim();if(null==t||"string"==typeof t)return t;const o=[];for(const e in t)if(t.hasOwnProperty(e)){const n=t[e];o.push(`${e}(${n})`)}return o.join(" ").trim()};var rt=r(1594),ot=r.n(rt);const it={"American Typewriter":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.4203125,.3296875,.6,.6375,.8015625,.8203125,.1875,.45625,.45625,.6375,.5,.2734375,.309375,.2734375,.4390625,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.2734375,.2734375,.5,.5,.5,.6,.6921875,.7640625,.6921875,.6375,.728125,.6734375,.6203125,.7109375,.784375,.3828125,.6421875,.7859375,.6375,.9484375,.7640625,.65625,.6375,.65625,.7296875,.6203125,.6375,.7109375,.740625,.940625,.784375,.7578125,.6203125,.4375,.5,.4375,.5,.5,.4921875,.5734375,.5890625,.5109375,.6,.528125,.43125,.5578125,.6375,.3109375,.40625,.6234375,.309375,.928125,.6375,.546875,.6,.58125,.4921875,.4921875,.4,.6203125,.625,.825,.6375,.640625,.528125,.5,.5,.5,.6671875],avg:.5793421052631578},Arial:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.278125,.35625,.55625,.55625,.890625,.6671875,.1921875,.334375,.334375,.390625,.584375,.278125,.334375,.278125,.278125,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.584375,.584375,.584375,.55625,1.015625,.6703125,.6671875,.7234375,.7234375,.6671875,.6109375,.778125,.7234375,.278125,.5,.6671875,.55625,.834375,.7234375,.778125,.6671875,.778125,.7234375,.6671875,.6109375,.7234375,.6671875,.9453125,.6671875,.6671875,.6109375,.278125,.278125,.278125,.4703125,.584375,.334375,.55625,.55625,.5,.55625,.55625,.3125,.55625,.55625,.2234375,.2703125,.5,.2234375,.834375,.55625,.55625,.55625,.55625,.346875,.5,.278125,.55625,.5,.7234375,.5,.5,.5,.334375,.2609375,.334375,.584375],avg:.528733552631579},"Arial Black":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.33125,.334375,.5,.6609375,.6671875,1,.890625,.278125,.390625,.390625,.55625,.6609375,.334375,.334375,.334375,.28125,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.334375,.334375,.6609375,.6609375,.6609375,.6109375,.7453125,.78125,.778125,.778125,.778125,.7234375,.6671875,.834375,.834375,.390625,.6671875,.834375,.6671875,.9453125,.834375,.834375,.7234375,.834375,.78125,.7234375,.7234375,.834375,.7796875,1.003125,.78125,.78125,.7234375,.390625,.28125,.390625,.6609375,.5125,.334375,.6671875,.6671875,.6671875,.6671875,.6671875,.41875,.6671875,.6671875,.334375,.384375,.6671875,.334375,1,.6671875,.6671875,.6671875,.6671875,.4703125,.6109375,.4453125,.6671875,.6140625,.946875,.6671875,.615625,.55625,.390625,.278125,.390625,.6609375],avg:.6213157894736842},Baskerville:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.25,.40625,.6671875,.490625,.875,.7015625,.178125,.2453125,.246875,.4171875,.6671875,.25,.3125,.25,.521875,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.25,.25,.6671875,.6671875,.6671875,.396875,.9171875,.684375,.615625,.71875,.7609375,.625,.553125,.771875,.803125,.3546875,.515625,.78125,.6046875,.928125,.75,.8234375,.5625,.96875,.7296875,.5421875,.6984375,.771875,.7296875,.9484375,.771875,.678125,.6359375,.3640625,.521875,.3640625,.46875,.5125,.334375,.46875,.521875,.428125,.521875,.4375,.3890625,.4765625,.53125,.25,.359375,.4640625,.240625,.803125,.53125,.5,.521875,.521875,.365625,.334375,.2921875,.521875,.4640625,.678125,.4796875,.465625,.428125,.4796875,.5109375,.4796875,.6671875],avg:.5323519736842108},Courier:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6078125,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.61875,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.615625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6140625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6020559210526316},"Courier New":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6015296052631579},cursive:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.1921875,.24375,.40625,.5671875,.3984375,.721875,.909375,.2328125,.434375,.365625,.4734375,.5578125,.19375,.3484375,.19375,.7734375,.503125,.4171875,.5453125,.45,.6046875,.4703125,.5984375,.55625,.503125,.5546875,.20625,.2,.5625,.5546875,.546875,.403125,.70625,.734375,.7078125,.64375,.85,.753125,.75,.6484375,1.0765625,.44375,.5359375,.8359375,.653125,1.0109375,1.1515625,.6796875,.6984375,1.0625,.8234375,.5125,.9234375,.8546875,.70625,.9109375,.7421875,.715625,.6015625,.4640625,.3359375,.4109375,.5421875,.5421875,.4328125,.5125,.5,.3859375,.7375,.359375,.75625,.540625,.5328125,.3203125,.5296875,.5015625,.484375,.7890625,.5640625,.4203125,.703125,.471875,.4734375,.35,.4125,.5640625,.471875,.6484375,.5296875,.575,.4140625,.415625,.20625,.3796875,.5421875],avg:.5604440789473684},fantasy:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.215625,.2625,.3265625,.6109375,.534375,.7625,.7828125,.2,.4359375,.4359375,.3765625,.5109375,.2796875,.4609375,.2796875,.5296875,.6640625,.253125,.521875,.4765625,.6640625,.490625,.528125,.5546875,.496875,.5421875,.2796875,.2796875,.5625,.4609375,.5625,.4828125,.609375,.740625,.7234375,.740625,.8265625,.7234375,.6171875,.7359375,.765625,.240625,.5453125,.715625,.6078125,.8640625,.653125,.9125,.6484375,.946875,.6921875,.653125,.6953125,.8015625,.58125,.784375,.671875,.6265625,.690625,.4359375,.5296875,.4359375,.53125,.5,.2875,.5375,.603125,.4984375,.60625,.53125,.434375,.6421875,.56875,.209375,.4671875,.5484375,.2203125,.709375,.55,.5984375,.6140625,.5765625,.40625,.4734375,.3734375,.559375,.4421875,.6421875,.4890625,.578125,.4484375,.2546875,.2203125,.2546875,.55],avg:.536496710526316},Geneva:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3328125,.3046875,.5,.6671875,.6671875,.90625,.728125,.3046875,.446875,.446875,.5078125,.6671875,.3046875,.3796875,.3046875,.5390625,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.3046875,.3046875,.6671875,.6671875,.6671875,.56875,.871875,.728125,.6375,.6515625,.7015625,.5765625,.5546875,.675,.690625,.2421875,.4921875,.6640625,.584375,.7890625,.709375,.7359375,.584375,.78125,.60625,.60625,.640625,.6671875,.728125,.946875,.6109375,.6109375,.5765625,.446875,.5390625,.446875,.6671875,.6671875,.5921875,.5546875,.6109375,.546875,.603125,.5765625,.390625,.6109375,.584375,.2359375,.334375,.5390625,.2359375,.8953125,.584375,.60625,.603125,.603125,.3875,.509375,.44375,.584375,.565625,.78125,.53125,.571875,.5546875,.4515625,.246875,.4515625,.6671875],avg:.5762664473684211},Georgia:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2421875,.33125,.4125,.64375,.6109375,.81875,.7109375,.215625,.375,.375,.4734375,.64375,.2703125,.375,.2703125,.46875,.6140625,.4296875,.559375,.553125,.565625,.5296875,.5671875,.503125,.596875,.5671875,.3125,.3125,.64375,.64375,.64375,.4796875,.9296875,.715625,.6546875,.6421875,.75,.6546875,.6,.7265625,.815625,.390625,.51875,.7203125,.6046875,.928125,.7671875,.7453125,.6109375,.7453125,.7234375,.5625,.61875,.7578125,.70625,.99375,.7125,.6640625,.6015625,.375,.46875,.375,.64375,.65,.5,.5046875,.56875,.4546875,.575,.484375,.39375,.509375,.5828125,.29375,.3671875,.546875,.2875,.88125,.5921875,.5390625,.571875,.5640625,.4109375,.4328125,.3453125,.5765625,.5203125,.75625,.50625,.5171875,.4453125,.43125,.375,.43125,.64375],avg:.5551809210526316},"Gill Sans":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2765625,.271875,.3546875,.584375,.5421875,.6765625,.625,.1890625,.3234375,.3234375,.4171875,.584375,.2203125,.3234375,.2203125,.28125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.2203125,.2296875,.584375,.584375,.584375,.334375,1.0109375,.6671875,.5640625,.709375,.75,.5,.4703125,.740625,.7296875,.25,.3125,.65625,.490625,.78125,.78125,.8234375,.5109375,.8234375,.6046875,.459375,.6046875,.709375,.6046875,1.0421875,.709375,.6046875,.646875,.334375,.28125,.334375,.4703125,.5828125,.334375,.428125,.5,.4390625,.5109375,.4796875,.296875,.428125,.5,.2203125,.2265625,.5,.2203125,.771875,.5,.553125,.5,.5,.3984375,.3859375,.334375,.5,.4390625,.7203125,.5,.4390625,.4171875,.334375,.2609375,.334375,.584375],avg:.4933717105263159},Helvetica:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2796875,.2765625,.3546875,.5546875,.5546875,.8890625,.665625,.190625,.3328125,.3328125,.3890625,.5828125,.2765625,.3328125,.2765625,.3015625,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.2765625,.2765625,.584375,.5828125,.584375,.5546875,1.0140625,.665625,.665625,.721875,.721875,.665625,.609375,.7765625,.721875,.2765625,.5,.665625,.5546875,.8328125,.721875,.7765625,.665625,.7765625,.721875,.665625,.609375,.721875,.665625,.94375,.665625,.665625,.609375,.2765625,.3546875,.2765625,.4765625,.5546875,.3328125,.5546875,.5546875,.5,.5546875,.5546875,.2765625,.5546875,.5546875,.221875,.240625,.5,.221875,.8328125,.5546875,.5546875,.5546875,.5546875,.3328125,.5,.2765625,.5546875,.5,.721875,.5,.5,.5,.3546875,.259375,.353125,.5890625],avg:.5279276315789471},"Helvetica Neue":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.259375,.4265625,.55625,.55625,1,.6453125,.278125,.2703125,.26875,.353125,.6,.278125,.3890625,.278125,.36875,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.6,.6,.6,.55625,.8,.6625,.6859375,.7234375,.7046875,.6125,.575,.759375,.7234375,.259375,.5203125,.6703125,.55625,.871875,.7234375,.7609375,.6484375,.7609375,.6859375,.6484375,.575,.7234375,.6140625,.9265625,.6125,.6484375,.6125,.259375,.36875,.259375,.6,.5,.25625,.5375,.59375,.5375,.59375,.5375,.2984375,.575,.55625,.2234375,.2375,.5203125,.2234375,.853125,.55625,.575,.59375,.59375,.334375,.5,.315625,.55625,.5,.759375,.51875,.5,.48125,.334375,.2234375,.334375,.6],avg:.5279440789473684},"Hoefler Text":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2359375,.2234375,.3921875,.7125,.49375,.8859375,.771875,.2125,.3078125,.309375,.375,.4234375,.234375,.3125,.234375,.3,.5828125,.365625,.434375,.3921875,.5234375,.3984375,.5125,.4328125,.46875,.5125,.234375,.234375,.515625,.4234375,.515625,.340625,.7609375,.7359375,.6359375,.721875,.8125,.6375,.5875,.8078125,.853125,.4296875,.503125,.78125,.609375,.9609375,.8515625,.8140625,.6125,.8140625,.71875,.49375,.7125,.76875,.771875,1.125,.7765625,.7734375,.65625,.321875,.3078125,.321875,.3546875,.5,.3375,.446875,.5359375,.45,.5296875,.4546875,.425,.4921875,.54375,.2671875,.240625,.5390625,.25,.815625,.5375,.5234375,.5390625,.5421875,.365625,.36875,.35625,.5171875,.5015625,.75,.5,.509375,.44375,.2421875,.14375,.2421875,.35],avg:.5116447368421051},Montserrat:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2625,.2609375,.3734375,.696875,.615625,.8296875,.6703125,.203125,.3296875,.3296875,.3875,.575,.2125,.3828125,.2125,.3953125,.6625,.3625,.56875,.5640625,.6625,.5671875,.609375,.5890625,.6390625,.609375,.2125,.2125,.575,.575,.575,.5671875,1.034375,.7171875,.7546875,.7203125,.8265625,.6703125,.634375,.7734375,.8140625,.303125,.5078125,.7125,.5890625,.95625,.8140625,.8390625,.71875,.8390625,.7234375,.615625,.575,.7921875,.6984375,1.1125,.65625,.6359375,.6515625,.31875,.396875,.31875,.5765625,.5,.6,.590625,.678125,.5640625,.678125,.6046875,.375,.6875,.678125,.2703125,.365625,.6015625,.2703125,1.0625,.678125,.628125,.678125,.678125,.4015625,.4890625,.40625,.6734375,.5421875,.8796875,.534375,.5671875,.5125,.334375,.2953125,.334375,.575],avg:.571792763157895},monospace:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6078125,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.61875,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.615625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6140625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6020559210526316},Overpass:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2296875,.2765625,.4203125,.68125,.584375,.8515625,.7015625,.2203125,.3453125,.3453125,.53125,.63125,.2234375,.3953125,.2234375,.509375,.65,.4046875,.6171875,.60625,.6484375,.60625,.6015625,.5375,.615625,.6015625,.2234375,.2234375,.63125,.63125,.63125,.5015625,.8203125,.696875,.6671875,.65,.6859375,.6015625,.559375,.690625,.7078125,.2953125,.565625,.678125,.58125,.8046875,.7109375,.740625,.6421875,.740625,.6765625,.6046875,.590625,.696875,.6640625,.853125,.65,.6671875,.6625,.3734375,.509375,.3734375,.63125,.5125,.4,.5328125,.5625,.51875,.5625,.546875,.3359375,.5625,.565625,.25625,.3203125,.55,.265625,.85,.565625,.5671875,.5625,.5625,.4046875,.4765625,.3796875,.565625,.521875,.7265625,.53125,.5390625,.5125,.3671875,.275,.3671875,.63125],avg:.5430756578947369},Palatino:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.278125,.371875,.60625,.5,.840625,.778125,.209375,.334375,.334375,.390625,.60625,.2578125,.334375,.25,.60625,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.25,.25,.60625,.60625,.60625,.4453125,.7484375,.778125,.6109375,.709375,.775,.6109375,.55625,.7640625,.8328125,.3375,.346875,.7265625,.6109375,.946875,.83125,.7875,.6046875,.7875,.66875,.525,.6140625,.778125,.7234375,1,.6671875,.6671875,.6671875,.334375,.60625,.334375,.60625,.5,.334375,.5,.565625,.4453125,.6109375,.4796875,.340625,.55625,.5828125,.2921875,.2671875,.5640625,.2921875,.8828125,.5828125,.546875,.6015625,.5609375,.3953125,.425,.3265625,.603125,.565625,.834375,.5171875,.55625,.5,.334375,.60625,.334375,.60625],avg:.5408552631578947},RedHatText:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2328125,.2203125,.35625,.6890625,.55,.7390625,.6703125,.2140625,.4015625,.4015625,.4546875,.53125,.2203125,.45625,.2203125,.515625,.6609375,.3078125,.5484375,.5875,.61875,.5703125,.6203125,.559375,.6140625,.6203125,.2203125,.2234375,.465625,.534375,.465625,.5125,.7671875,.6609375,.6703125,.7265625,.728125,.6203125,.6109375,.8,.73125,.253125,.6,.6125,.6078125,.8625,.7390625,.8109375,.6546875,.809375,.6484375,.6234375,.6171875,.7125,.6609375,.8984375,.6546875,.646875,.60625,.3625,.5203125,.3625,.540625,.4609375,.5234375,.5265625,.584375,.509375,.5828125,.5578125,.3703125,.5828125,.553125,.2234375,.24375,.4890625,.2234375,.8453125,.553125,.58125,.584375,.5828125,.353125,.453125,.378125,.553125,.5015625,.6984375,.4875,.4984375,.459375,.3953125,.2921875,.3953125,.58125],avg:.5341940789473685},"sans-serif":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.278125,.35625,.55625,.55625,.890625,.6671875,.1921875,.334375,.334375,.390625,.584375,.278125,.334375,.278125,.303125,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.5859375,.584375,.5859375,.55625,1.015625,.6671875,.6671875,.7234375,.7234375,.6671875,.6109375,.778125,.7234375,.278125,.5,.6671875,.55625,.834375,.7234375,.778125,.6671875,.778125,.7234375,.6671875,.6109375,.7234375,.6671875,.9453125,.6671875,.6671875,.6109375,.278125,.35625,.278125,.478125,.55625,.334375,.55625,.55625,.5,.55625,.55625,.278125,.55625,.55625,.2234375,.2421875,.5,.2234375,.834375,.55625,.55625,.55625,.55625,.334375,.5,.278125,.55625,.5,.7234375,.5,.5,.5,.35625,.2609375,.3546875,.590625],avg:.5293256578947368},Seravek:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.215625,.296875,.4171875,.6734375,.4953125,.9125,.740625,.2421875,.3375,.3375,.409375,.60625,.2609375,.35625,.25625,.41875,.5921875,.3515625,.475,.4875,.5375,.509375,.5484375,.4546875,.5421875,.5484375,.25625,.2546875,.5875,.6171875,.5875,.4578125,.8140625,.6765625,.5703125,.6109375,.684375,.5109375,.4953125,.678125,.6859375,.2625,.2625,.5859375,.4734375,.846875,.709375,.740625,.509375,.740625,.584375,.5015625,.528125,.675,.5953125,.9453125,.596875,.540625,.540625,.359375,.4203125,.359375,.5109375,.421875,.4046875,.5015625,.5421875,.446875,.5453125,.484375,.38125,.5140625,.5546875,.240625,.2640625,.490625,.2765625,.8625,.5546875,.546875,.5453125,.5453125,.3625,.41875,.3890625,.5453125,.4703125,.7546875,.4921875,.4609375,.453125,.4015625,.2640625,.4015625,.58125],avg:.5044078947368421},serif:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2484375,.334375,.409375,.5,.5,.834375,.778125,.18125,.334375,.334375,.5,.5640625,.25,.334375,.25,.278125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.278125,.278125,.5640625,.5640625,.5640625,.4453125,.921875,.7234375,.6671875,.6671875,.7234375,.6109375,.55625,.7234375,.7234375,.334375,.390625,.7234375,.6109375,.890625,.7234375,.7234375,.55625,.7234375,.6671875,.55625,.6109375,.7234375,.7234375,.9453125,.7234375,.7234375,.6109375,.334375,.340625,.334375,.4703125,.5,.3453125,.4453125,.5,.4453125,.5,.4453125,.3828125,.5,.5,.278125,.3359375,.5,.278125,.778125,.5,.5,.5,.5,.3375,.390625,.2796875,.5,.5,.7234375,.5,.5,.4453125,.48125,.2015625,.48125,.5421875],avg:.5126315789473684},Tahoma:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3109375,.3328125,.4015625,.728125,.546875,.9765625,.70625,.2109375,.3828125,.3828125,.546875,.728125,.303125,.3640625,.303125,.3953125,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.3546875,.3546875,.728125,.728125,.728125,.475,.909375,.6109375,.590625,.6015625,.6796875,.5625,.521875,.66875,.6765625,.3734375,.4171875,.6046875,.4984375,.771875,.66875,.7078125,.5515625,.7078125,.6375,.5578125,.5875,.65625,.60625,.903125,.58125,.5890625,.559375,.3828125,.39375,.3828125,.728125,.5625,.546875,.525,.553125,.4625,.553125,.5265625,.3546875,.553125,.5578125,.2296875,.328125,.51875,.2296875,.840625,.5578125,.54375,.553125,.553125,.3609375,.446875,.3359375,.5578125,.4984375,.7421875,.4953125,.4984375,.4453125,.48125,.3828125,.48125,.728125],avg:.5384374999999998},"Times New Roman":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2484375,.334375,.409375,.5,.5,.834375,.778125,.18125,.334375,.334375,.5,.5640625,.25,.334375,.25,.28125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.278125,.278125,.5640625,.5640625,.5640625,.4453125,.921875,.7234375,.6671875,.6671875,.7234375,.6109375,.55625,.7234375,.7234375,.334375,.390625,.73125,.6109375,.890625,.7375,.7234375,.55625,.7234375,.6765625,.55625,.6109375,.7234375,.7234375,.9453125,.7234375,.7234375,.6109375,.334375,.28125,.334375,.4703125,.51875,.334375,.4453125,.503125,.4453125,.503125,.4453125,.4359375,.5,.5,.278125,.35625,.50625,.278125,.778125,.5,.5,.5046875,.5,.340625,.390625,.2796875,.5,.5,.7234375,.5,.5,.4453125,.48125,.2015625,.48125,.5421875],avg:.5134375},"Trebuchet MS":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3015625,.3671875,.325,.53125,.525,.6015625,.70625,.1609375,.3671875,.3671875,.3671875,.525,.3671875,.3671875,.3671875,.525,.525,.525,.525,.525,.525,.525,.525,.525,.525,.525,.3671875,.3671875,.525,.525,.525,.3671875,.771875,.590625,.5671875,.5984375,.6140625,.5359375,.525,.6765625,.6546875,.2796875,.4765625,.5765625,.5078125,.7109375,.6390625,.675,.5578125,.7421875,.5828125,.48125,.58125,.6484375,.5875,.853125,.5578125,.5703125,.5515625,.3671875,.3578125,.3671875,.525,.53125,.525,.5265625,.5578125,.4953125,.5578125,.546875,.375,.503125,.546875,.2859375,.3671875,.5046875,.2953125,.83125,.546875,.5375,.5578125,.5578125,.3890625,.40625,.396875,.546875,.490625,.7453125,.5015625,.49375,.475,.3671875,.525,.3671875,.525],avg:.5085197368421052},Verdana:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.35,.39375,.459375,.81875,.6359375,1.0765625,.759375,.26875,.4546875,.4546875,.6359375,.81875,.3640625,.4546875,.3640625,.4703125,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.4546875,.4546875,.81875,.81875,.81875,.546875,1,.684375,.6859375,.6984375,.771875,.6328125,.575,.7765625,.7515625,.421875,.4546875,.69375,.5578125,.84375,.7484375,.7875,.603125,.7875,.7,.684375,.6171875,.7328125,.684375,.9890625,.6859375,.615625,.6859375,.4546875,.46875,.4546875,.81875,.6421875,.6359375,.6015625,.6234375,.521875,.6234375,.596875,.384375,.6234375,.6328125,.275,.3765625,.5921875,.275,.9734375,.6328125,.6078125,.6234375,.6234375,.43125,.521875,.3953125,.6328125,.5921875,.81875,.5921875,.5921875,.5265625,.6359375,.4546875,.6359375,.81875],avg:.6171875000000003}},at={mm:3.8,sm:38,pt:1.33,pc:16,in:96,px:1},st={em:1,ex:.5},ct={lineHeight:1,letterSpacing:"0px",fontSize:0,angle:0,fontFamily:""},ut=t=>Array.isArray(t)?t:t.toString().split(/\r\n|\r|\n/g),lt=(t,e,n)=>{const r=(t=>t*Math.PI/180)(n);return Math.abs(Math.cos(r)*t)+Math.abs(Math.sin(r)*e)},dt=(t,e)=>{const n=t.match(/[a-zA-Z%]+/)?.[0],r=Number(t.match(/[0-9.,]+/));let o;return o=n?at.hasOwnProperty(n)?r*at[n]:st.hasOwnProperty(n)?(e?r*e:r*ct.fontSize)*st[n]:r:r||0,o},pt=(t,e)=>{const n=Array.isArray(t)?t[e]:t,r=i()({},n,ct);return Object.assign({},r,{fontFamily:r.fontFamily,letterSpacing:"number"==typeof r.letterSpacing?r.letterSpacing:dt(String(r.letterSpacing),r.fontSize),fontSize:"number"==typeof r.fontSize?r.fontSize:dt(String(r.fontSize))})},ft=(t,e)=>{const n=Array.isArray(e)?e[0]&&e[0].angle:e&&e.angle,r=((t,e)=>void 0===t||""===t||null===t?0:ut(t).reduce(((t,n,r)=>{const o=pt(e,r),i=n.toString().match(/[(A-Z)(0-9)]/)?1.15*o.fontSize:o.fontSize;return t+o.lineHeight*i}),0))(t,e),o=((t,e)=>{if(void 0===t||""===t||null===t)return 0;const n=ut(t).map(((t,n)=>{const r=t.toString().length,{fontSize:o,letterSpacing:i,fontFamily:a}=pt(e,n),s=(t=>{const e=t.split(",").map((t=>t.replace(/'|"/g,""))).find((t=>it[t]))||"Helvetica";return it[e]})(a);return t.toString().split("").map((t=>t.charCodeAt(0)<s.widths.length?s.widths[t.charCodeAt(0)]:s.avg)).reduce(((t,e)=>e+t),0)*o+i*Math.max(r-1,0)}));return Math.max(...n)})(t,e);return{width:n?lt(o,r,n):o,height:1.05*(n?lt(r,o,n):r)}},ht=ot()((()=>{const t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("xlink","http://www.w3.org/1999/xlink"),t.setAttribute("width","300"),t.setAttribute("height","300"),t.setAttribute("viewBox","0 0 300 300"),t.setAttribute("aria-hidden","true");const e=document.createElementNS("http://www.w3.org/2000/svg","text");return t.appendChild(e),t.style.position="fixed",t.style.top="-9999px",t.style.left="-9999px",document.body.appendChild(t),e})),gt=t=>t?`${t.angle}:${t.fontFamily}:${t.fontSize}:${t.letterSpacing}:${t.lineHeight}`:"null",yt=ot()(((t,e)=>{let n=ht();n.isConnected||(ht.cache.clear?.(),n=ht());const r=ut(t);let o=0;for(const[t,i]of r.entries()){const r=document.createElementNS("http://www.w3.org/2000/svg","tspan"),a=pt(e,t);r.style.fontFamily=a.fontFamily,r.style.fontSize=`${a.fontSize}px`,r.style.lineHeight=a.lineHeight,r.style.fontFamily=a.fontFamily,r.style.letterSpacing=a.letterSpacing,r.textContent=i,r.setAttribute("x","0"),r.setAttribute("y",`${o}`),n.appendChild(r),o+=a.lineHeight*r.getBoundingClientRect().height}const{width:i}=n.getBoundingClientRect();return n.innerHTML="",{width:e?.angle?lt(i,o,e?.angle):i,height:e?.angle?lt(o,i,e?.angle):o}}),((t,e)=>`${Array.isArray(t)?t.join():t}::${Array.isArray(e)?e.map(gt).join():gt(e)}`)),vt=(t,e)=>function(t,e,n){return void 0===n&&(n=!1),"undefined"==typeof window||void 0===window.document||void 0===window.document.createElement||n?ft(t,e):yt(t,e)}(t,e),mt={fill:"#252525",fontSize:14,fontFamily:"'Gill Sans', 'Gill Sans MT', 'Seravek', 'Trebuchet MS', sans-serif",stroke:"transparent"},xt=(t,e)=>{if(!t.datum)return 0;const n=function(t,e){const{scale:n,polar:r,horizontal:o}=t,i=u(e),a=t.origin||{x:0,y:0},s=o?n.y(i.y):n.x(i.x),c=o?n.y(i.y0):n.x(i.x0),l=o?n.x(i.x):n.y(i.y),d=o?n.x(i.x0):n.y(i.y0);return{x:r?l*Math.cos(s)+a.x:s,x0:r?d*Math.cos(c)+a.x:c,y:r?-l*Math.sin(s)+a.y:l,y0:r?-d*Math.sin(c)+a.x:d}}(t,t.datum);return n[e]},bt=t=>{const e=t&&t.fontSize;if("number"==typeof e)return e;if(null==e)return mt.fontSize;if("string"==typeof e){const t=Number(e.replace("px",""));return isNaN(t)?mt.fontSize:t}return mt.fontSize},wt=function(t,e){return void 0===e&&(e=0),Array.isArray(t)?t[e]||t[0]:t},St=t=>{const{backgroundStyle:e,backgroundPadding:n}=t;return Array.isArray(e)&&!X()(e)||Array.isArray(n)&&!X()(n)},At=(t,e,n)=>{const{polar:r}=t,o=wt(t.style),i=r?function(t,e){const{labelPlacement:n,datum:r}=t;if(!n||"vertical"===n)return 0;const o=function(t,e){const{x:n}=u(e);return("number"==typeof(r=t.scale.x(n))?r/(Math.PI/180):r)%360;var r}(t,r);let i=0;return 0===o||180===o?i=90:o>0&&o<180?i=90-o:o>180&&o<360&&(i=270-o),i+(o>90&&o<180||o>270?1:-1)*("perpendicular"===n?0:90)}(t):0,a=void 0===o.angle?d(t.angle,t):o.angle,s=void 0===a?i:a,c=t.transform||o.transform,l=c&&d(c,t);return l||s?nt(l,s&&{rotate:[s,e,n]}):void 0},Ct=(t,e)=>{const{direction:n,textAnchor:r,x:o,dx:i}=t;if("rtl"===n)return o-e;switch(r){case"middle":return Math.round(o-e/2);case"end":return Math.round(o-e);default:return o+(i||0)}},jt=(t,e)=>{const{verticalAnchor:n,y:r,originalDy:o=0}=t,i=r+o;switch(n){case"start":return Math.floor(i);case"end":return Math.ceil(i-e);default:return Math.floor(i-e/2)}},Et=(t,e)=>St(t)?((t,e)=>{const{dy:n,dx:r,transform:o,backgroundStyle:a,backgroundPadding:c,backgroundComponent:u,inline:l,y:d}=t,p=e.map(((t,o)=>{const i=wt(e,o-1),a=t.textSize,s=t.fontSize*t.lineHeight,u=Math.ceil(s),p=wt(c,o),f=wt(c,o-1),h=l&&r||0,g=o&&!l?i.fontSize*i.lineHeight+f.top+f.bottom:n-.5*s-(t.fontSize-t.capHeight);return{textHeight:u,labelSize:a,heightWithPadding:u+p.top+p.bottom,widthWithPadding:a.width+p.left+p.right+h,y:d,fontSize:t.fontSize,dy:g}}));return p.map(((e,n)=>{const r=Ct(t,e.labelSize.width),f=p.slice(0,n+1).reduce(((t,e)=>t+e.dy),d),h=wt(c,n),g=e.heightWithPadding,y=l?((t,e,n)=>{const{textAnchor:r}=t,o=e.map((t=>t.widthWithPadding)),i=-o.reduce(((t,e)=>t+e),0)/2;switch(r){case"start":return o.reduce(((t,e,r)=>r<n?t+e:t),0);case"end":return o.reduce(((t,e,r)=>r>n?t-e:t),0);default:return o.reduce(((t,e,r)=>r===n?t+e/2:t+(r<n?e:0)),i)}})(t,p,n)+r-h.left:r,v=l?jt(t,g)-h.top:f,m={key:`tspan-background-${n}`,height:g,style:wt(a,n),width:e.widthWithPadding,transform:o,x:y-h.left,y:v};return s().cloneElement(u,i()({},u.props,m))}))})(t,e):((t,e)=>{const{dx:n=0,transform:r,backgroundComponent:o,backgroundStyle:a,inline:c,backgroundPadding:u,capHeight:l}=t,d=e.map((t=>t.textSize)),p=c?Math.max(...d.map((t=>t.height))):d.reduce(((t,n,r)=>{const o=r?0:l/2;return t+n.height*(e[r].lineHeight-o)}),0),f=c?d.reduce(((t,e,r)=>{const o=r?n:0;return t+e.width+o}),0):Math.max(...d.map((t=>t.width))),h=Ct(t,f),g=jt(t,p),y={key:"background",height:p+u.top+u.bottom,style:a,transform:r,width:f+u.left+u.right,x:c?h-u.left:h+n-u.left,y:g};return s().cloneElement(o,i()({},o.props,y))})(t,e),Ot=(t,e,n)=>{const{inline:r}=e,o=wt(t,n);return n&&!r?((t,e,n)=>{const r=wt(t,e),o=wt(t,e-1),i=o.fontSize*o.lineHeight,a=r.fontSize*r.lineHeight,s=o.fontSize-o.capHeight,c=r.fontSize-r.capHeight,u=i-o.fontSize/2+r.fontSize/2-i/2+a/2-c/2+s/2;return St(n)?u+r.backgroundPadding.top+o.backgroundPadding.bottom:u})(t,n,e):r?0===n?o.backgroundPadding.top:void 0:o.backgroundPadding.top},Pt={backgroundComponent:s().createElement(Q,null),groupComponent:s().createElement("g",null),direction:"inherit",textComponent:s().createElement(tt,null),tspanComponent:s().createElement(et,null),capHeight:.71,lineHeight:1},Mt=t=>{const e=(t=>{const e=((t,e)=>{if(null==t)return;if(Array.isArray(t))return t.map((t=>d(t,e)));const n=d(t,e);return null!=n?Array.isArray(n)?n:`${n}`.split("\n"):void 0})(t.text,t),n=((t,e)=>{if(e.disableInlineStyles){const n=p(t,e);return{fontSize:bt(n)}}const n=t=>{const n=p(t?i()({},t,mt):mt,e);return Object.assign({},n,{fontSize:bt(n)})};return Array.isArray(t)&&!X()(t)?t.map((t=>n(t))):n(t)})(t.style,Object.assign({},t,{text:e})),r=((t,e)=>{if(t)return Array.isArray(t)&&!X()(t)?t.map((t=>p(t,e))):p(t,e)})(t.backgroundStyle,Object.assign({},t,{text:e,style:n})),o=(t=>t.backgroundPadding&&Array.isArray(t.backgroundPadding)?t.backgroundPadding.map((e=>l({padding:d(e,t)}))):l({padding:d(t.backgroundPadding,t)}))(Object.assign({},t,{text:e,style:n,backgroundStyle:r})),a=d(t.id,t);return Object.assign({},t,{backgroundStyle:r,backgroundPadding:o,style:n,text:e,id:a})})({...Pt,...t});if(null===e.text||void 0===e.text)return null;const n=(t=>{const e=d(t.ariaLabel,t),n=wt(t.style),r=(t=>{const e=d(t.lineHeight,t);return Array.isArray(e)&&X()(e)?[1]:e})(t),o=t.direction?d(t.direction,t):"inherit",i=t.textAnchor?d(t.textAnchor,t):n.textAnchor||"start",a=t.verticalAnchor?d(t.verticalAnchor,t):n.verticalAnchor||"middle",s=t.dx?d(t.dx,t):0,c=((t,e,n)=>{const r=t.dy?d(t.dy,t):0,o=t.inline?1:t.text.length,i=d(t.capHeight,t),a=e?d(e,t):"middle",s=[...Array(o).keys()].map((e=>wt(t.style,e).fontSize)),c=[...Array(o).keys()].map((t=>wt(n,t)));if("start"===a)return r+(i/2+c[0]/2)*s[0];if(t.inline)return"end"===a?r+(i/2-c[0]/2)*s[0]:r+i/2*s[0];if(1===o)return"end"===a?r+(i/2+(.5-o)*c[0])*s[0]:r+(i/2+(.5-o/2)*c[0])*s[0];const u=[...Array(o).keys()].reduce(((t,e)=>t+(i/2+(.5-o)*c[e])*s[e]/o),0);return"end"===a?r+u:r+u/2+i/2*c[o-1]*s[o-1]})(t,a,r),u=void 0!==t.x?t.x:xt(t,"x"),l=void 0!==t.y?t.y:xt(t,"y"),p=At(t,u,l);return Object.assign({},t,{ariaLabel:e,lineHeight:r,direction:o,textAnchor:i,verticalAnchor:a,dx:s,dy:c,originalDy:d(t.dy,t),transform:p,x:u,y:l})})(e),{text:r,style:o,capHeight:a,backgroundPadding:c,lineHeight:u}=n,f=r.map(((t,e)=>{const n=wt(o,e),r=dt(`${a}em`,n.fontSize),i=wt(u,e);return{style:n,fontSize:n.fontSize||mt.fontSize,capHeight:r,text:t,textSize:vt(t,n),lineHeight:i,backgroundPadding:wt(c,e)}})),h=((t,e)=>{const{ariaLabel:n,inline:r,className:o,title:i,events:a,direction:c,text:u,textAnchor:l,dx:p,dy:f,transform:h,x:g,y:y,desc:v,id:m,tabIndex:x,tspanComponent:b,textComponent:w}=t,S=G(t),A={"aria-label":n,key:"text",...a,direction:c,dx:p,x:g,y:y+f,transform:h,className:o,title:i,desc:d(v,t),tabIndex:d(x,t),id:m,...S},C=u.map(((n,o)=>{const i=e[o].style,a={key:`${m}-key-${o}`,x:r?void 0:g,dx:r?p+e[o].backgroundPadding.left:p,dy:Ot(e,t,o),textAnchor:i.textAnchor||l,style:i,children:n};return s().cloneElement(b,a)}));return s().cloneElement(w,A,C)})(n,f);if(e.backgroundStyle){const t=[Et(n,f),h],r=s().cloneElement(e.groupComponent,{},t);return e.renderInPortal?s().createElement(Y,null,r):r}return e.renderInPortal?s().createElement(Y,null,h):h};function kt(){return kt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},kt.apply(this,arguments)}Mt.displayName="VictoryLabel",Mt.role="label",Mt.defaultStyles=mt;const _t=(0,a.forwardRef)(((t,e)=>{const{desc:n,id:r,tabIndex:o,origin:i,...a}=t,c={vectorEffect:"non-scaling-stroke",id:d(r,t)?.toString(),tabIndex:d(o,t),...a};return n?s().createElement("line",kt({},c,{ref:e}),s().createElement("desc",null,n)):s().createElement("line",kt({},c,{ref:e}))})),zt={lineComponent:s().createElement(_t,null),role:"presentation",shapeRendering:"auto"},It=t=>{const e=(t=>{const e=d(t.ariaLabel,t),n=d(t.desc,t),r=d(t.id,t),o=p(Object.assign({stroke:"black"},t.style),t),i=d(t.tabIndex,t);return Object.assign({},t,{ariaLabel:e,desc:n,id:r,style:o,tabIndex:i})})({...zt,...t});return s().cloneElement(e.lineComponent,{...e.events,"aria-label":e.ariaLabel,style:e.style,desc:e.desc,tabIndex:e.tabIndex,className:e.className,role:e.role,shapeRendering:e.shapeRendering,x1:e.x1,x2:e.x2,y1:e.y1,y2:e.y2,transform:e.transform,clipPath:e.clipPath})};function Tt(t){return class extends t{static displayName="VictoryCursorContainer";static defaultProps={...q.defaultProps,cursorLabelComponent:s().createElement(Mt,null),cursorLabelOffset:{x:5,y:-10},cursorComponent:s().createElement(It,null)};static defaultEvents=t=>[{target:"parent",eventHandlers:{onMouseLeave:(e,n)=>t.disable?{}:m.onMouseLeave(e,n),onTouchCancel:()=>[],onMouseMove:(e,n)=>t.disable?{}:m.onMouseMove(e,n),onTouchMove:(e,n)=>t.disable?{}:m.onMouseMove(e,n)}}];getCursorPosition(t){const{cursorValue:e,defaultCursorValue:n,domain:r,cursorDimension:o}=t;return e||("number"==typeof n?{x:(r.x[0]+r.x[1])/2,y:(r.y[0]+r.y[1])/2,[o]:n}:n)}getCursorLabelOffset(t){const{cursorLabelOffset:e}=t;return"number"==typeof e?{x:e,y:e}:e}getPadding(t){return void 0===t.padding?l(t.children.find((t=>b()(t.props)&&void 0!==t.props.padding)).props):l(t)}getCursorElements(t){const{scale:e,cursorLabelComponent:n,cursorLabel:r,cursorComponent:o,width:a,height:c,name:u,horizontal:l,theme:p}=t,f=m.getDimension(t),h=this.getCursorPosition(t),g=this.getCursorLabelOffset(t);if(!h)return[];const y=[],v=this.getPadding(t),x={x:l?e.y(h.y):e.x(h.x),y:l?e.x(h.x):e.y(h.y)};if(r){let t=i()({active:!0},n.props,{x:x.x+g.x,y:x.y+g.y,datum:h,active:!0,key:`${u}-cursor-label`});if("tooltip"===((b=n)&&b.type&&b.type.role)){const e=p&&p.tooltip||{};t=i()({},t,e)}y.push(s().cloneElement(n,i()({},t,{text:d(r,t)})))}var b;const w=Object.assign({stroke:"black"},o.props.style);return"x"!==f&&void 0!==f||y.push(s().cloneElement(o,{key:`${u}-x-cursor`,x1:x.x,x2:x.x,y1:v.top,y2:c-v.bottom,style:w})),"y"!==f&&void 0!==f||y.push(s().cloneElement(o,{key:`${u}-y-cursor`,x1:v.left,x2:a-v.right,y1:x.y,y2:x.y,style:w})),y}getChildren(t){return[...s().Children.toArray(t.children),...this.getCursorElements(t)]}}}const Ht=Tt(q)}(),o}()}));
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react")):"function"==typeof define&&define.amd?define(["react"],e):"object"==typeof exports?exports.VictoryCursorContainer=e(require("react")):t.VictoryCursorContainer=e(t.React)}(self,(function(t){return function(){var e={503:function(t,e,n){var r=n(1171),o=n(7838),i=n(4859),a=n(4073),s=n(8541);function c(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])}}c.prototype.clear=r,c.prototype.delete=o,c.prototype.get=i,c.prototype.has=a,c.prototype.set=s,t.exports=c},2596:function(t,e,n){var r=n(2373).Symbol;t.exports=r},6082:function(t){t.exports=function(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)}},8644:function(t){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}},9559:function(t){t.exports=function(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}},4132:function(t,e,n){var r=n(8347),o=n(788),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var a=t[e];i.call(t,e)&&o(a,n)&&(void 0!==n||e in t)||r(t,e,n)}},3162:function(t,e,n){var r=n(788);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},8347:function(t,e,n){var r=n(5525);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},6457:function(t,e,n){var r=n(9559),o=n(3608);t.exports=function t(e,n,i,a,s){var c=-1,u=e.length;for(i||(i=o),s||(s=[]);++c<u;){var l=e[c];n>0&&i(l)?n>1?t(l,n-1,i,a,s):r(s,l):a||(s[s.length]=l)}return s}},4432:function(t,e,n){var r=n(9026),o=n(3110);t.exports=function(t,e){for(var n=0,i=(e=r(e,t)).length;null!=t&&n<i;)t=t[o(e[n++])];return n&&n==i?t:void 0}},563:function(t){var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},6776:function(t){t.exports=function(t,e){return null!=t&&e in Object(t)}},7190:function(t,e,n){var r=n(5125)(Object.keys,Object);t.exports=r},5436:function(t,e,n){var r=n(6371),o=n(5066);t.exports=function(t,e){return r(t,e,(function(e,n){return o(t,n)}))}},6371:function(t,e,n){var r=n(4432),o=n(6539),i=n(9026);t.exports=function(t,e,n){for(var a=-1,s=e.length,c={};++a<s;){var u=e[a],l=r(t,u);n(l,u)&&o(c,i(u,t),l)}return c}},1600:function(t){t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},3301:function(t,e,n){var r=n(4432);t.exports=function(t){return function(e){return r(e,t)}}},6317:function(t,e,n){var r=n(5346),o=n(4280),i=n(201);t.exports=function(t,e){return i(o(t,e,r),t+"")}},6539:function(t,e,n){var r=n(4132),o=n(9026),i=n(9099),a=n(7709),s=n(3110);t.exports=function(t,e,n,c){if(!a(t))return t;for(var u=-1,l=(e=o(e,t)).length,d=l-1,p=t;null!=p&&++u<l;){var f=s(e[u]),h=n;if("__proto__"===f||"constructor"===f||"prototype"===f)return t;if(u!=d){var g=p[f];void 0===(h=c?c(g,f,p):void 0)&&(h=a(g)?g:i(e[u+1])?[]:{})}r(p,f,h),p=p[f]}return t}},6316:function(t,e,n){var r=n(2596),o=n(8644),i=n(163),a=n(1995),s=r?r.prototype:void 0,c=s?s.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(i(e))return o(e,t)+"";if(a(e))return c?c.call(e):"";var n=e+"";return"0"==n&&1/e==-1/0?"-0":n}},9026:function(t,e,n){var r=n(163),o=n(726),i=n(7801),a=n(7010);t.exports=function(t,e){return r(t)?t:o(t,e)?[t]:i(a(t))}},5525:function(t,e,n){var r=n(3743),o=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=o},5557:function(t,e,n){var r=n(2645),o=n(4280),i=n(201);t.exports=function(t){return i(o(t,void 0,r),t+"")}},2117:function(t,e,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;t.exports=r},3743:function(t){t.exports=function(t,e){return null==t?void 0:t[e]}},9667:function(t){var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},3096:function(t,e,n){var r=n(9026),o=n(5075),i=n(163),a=n(9099),s=n(8454),c=n(3110);t.exports=function(t,e,n){for(var u=-1,l=(e=r(e,t)).length,d=!1;++u<l;){var p=c(e[u]);if(!(d=null!=t&&n(t,p)))break;t=t[p]}return d||++u!=l?d:!!(l=null==t?0:t.length)&&s(l)&&a(p,l)&&(i(t)||o(t))}},3608:function(t,e,n){var r=n(2596),o=n(5075),i=n(163),a=r?r.isConcatSpreadable:void 0;t.exports=function(t){return i(t)||o(t)||!!(a&&t&&t[a])}},9099:function(t){var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,n){var r=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==r||"symbol"!=r&&e.test(t))&&t>-1&&t%1==0&&t<n}},8286:function(t){t.exports=function(){return!1}},726:function(t,e,n){var r=n(163),o=n(1995),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(r(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!o(t))||a.test(t)||!i.test(t)||null!=e&&t in Object(e)}},5782:function(t){t.exports=function(){return!1}},1171:function(t){t.exports=function(){this.__data__=[],this.size=0}},7838:function(t,e,n){var r=n(3162),o=Array.prototype.splice;t.exports=function(t){var e=this.__data__,n=r(e,t);return!(n<0||(n==e.length-1?e.pop():o.call(e,n,1),--this.size,0))}},4859:function(t,e,n){var r=n(3162);t.exports=function(t){var e=this.__data__,n=r(e,t);return n<0?void 0:e[n][1]}},4073:function(t,e,n){var r=n(3162);t.exports=function(t){return r(this.__data__,t)>-1}},8541:function(t,e,n){var r=n(3162);t.exports=function(t,e){var n=this.__data__,o=r(n,t);return o<0?(++this.size,n.push([t,e])):n[o][1]=e,this}},2453:function(t){t.exports=function(t){return t}},5125:function(t){t.exports=function(t,e){return function(n){return t(e(n))}}},4280:function(t,e,n){var r=n(6082),o=Math.max;t.exports=function(t,e,n){return e=o(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,s=o(i.length-e,0),c=Array(s);++a<s;)c[a]=i[e+a];a=-1;for(var u=Array(e+1);++a<e;)u[a]=i[a];return u[e]=n(c),r(t,this,u)}}},2373:function(t,e,n){var r=n(2117),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();t.exports=i},201:function(t){t.exports=function(t){return t}},7801:function(t,e,n){var r=n(2453),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=r((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(o,(function(t,n,r,o){e.push(r?o.replace(i,"$1"):n||t)})),e}));t.exports=a},3110:function(t,e,n){var r=n(1995);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},5034:function(t,e,n){var r=n(7709),o=n(6987),i=n(5812),a=Math.max,s=Math.min;t.exports=function(t,e,n){var c,u,l,d,p,f,h=0,g=!1,y=!1,v=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function m(e){var n=c,r=u;return c=u=void 0,h=e,d=t.apply(r,n)}function x(t){return h=t,p=setTimeout(w,e),g?m(t):d}function b(t){var n=t-f;return void 0===f||n>=e||n<0||y&&t-h>=l}function w(){var t=o();if(b(t))return S(t);p=setTimeout(w,function(t){var n=e-(t-f);return y?s(n,l-(t-h)):n}(t))}function S(t){return p=void 0,v&&c?m(t):(c=u=void 0,d)}function A(){var t=o(),n=b(t);if(c=arguments,u=this,f=t,n){if(void 0===p)return x(f);if(y)return clearTimeout(p),p=setTimeout(w,e),m(f)}return void 0===p&&(p=setTimeout(w,e)),d}return e=i(e)||0,r(n)&&(g=!!n.leading,l=(y="maxWait"in n)?a(i(n.maxWait)||0,e):l,v="trailing"in n?!!n.trailing:v),A.cancel=function(){void 0!==p&&clearTimeout(p),h=0,c=f=u=p=void 0},A.flush=function(){return void 0===p?d:S(o())},A}},1893:function(t,e,n){var r=n(6317),o=n(788),i=n(8286),a=n(8855),s=Object.prototype,c=s.hasOwnProperty,u=r((function(t,e){t=Object(t);var n=-1,r=e.length,u=r>2?e[2]:void 0;for(u&&i(e[0],e[1],u)&&(r=1);++n<r;)for(var l=e[n],d=a(l),p=-1,f=d.length;++p<f;){var h=d[p],g=t[h];(void 0===g||o(g,s[h])&&!c.call(t,h))&&(t[h]=l[h])}return t}));t.exports=u},788:function(t){t.exports=function(t,e){return t===e||t!=t&&e!=e}},2645:function(t,e,n){var r=n(6457);t.exports=function(t){return null!=t&&t.length?r(t,1):[]}},5066:function(t,e,n){var r=n(6776),o=n(3096);t.exports=function(t,e){return null!=t&&o(t,e,r)}},5346:function(t){t.exports=function(t){return t}},5075:function(t){t.exports=function(){return!1}},163:function(t){var e=Array.isArray;t.exports=e},981:function(t,e,n){var r=n(9642),o=n(8454);t.exports=function(t){return null!=t&&o(t.length)&&!r(t)}},4801:function(t){t.exports=function(){return!1}},4155:function(t,e,n){var r=n(7190),o=n(9667),i=n(5075),a=n(163),s=n(981),c=n(4801),u=n(5782),l=n(4289),d=Object.prototype.hasOwnProperty;t.exports=function(t){if(null==t)return!0;if(s(t)&&(a(t)||"string"==typeof t||"function"==typeof t.splice||c(t)||l(t)||i(t)))return!t.length;var e=o(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(u(t))return!r(t).length;for(var n in t)if(d.call(t,n))return!1;return!0}},9642:function(t,e,n){var r=n(563),o=n(7709);t.exports=function(t){if(!o(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},8454:function(t){t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},7709:function(t){t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},1995:function(t){t.exports=function(){return!1}},4289:function(t){t.exports=function(){return!1}},8855:function(t){t.exports=function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}},1594:function(t,e,n){var r=n(503);function o(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=t.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(o.Cache||r),n}o.Cache=r,t.exports=o},6987:function(t,e,n){var r=n(2373);t.exports=function(){return r.Date.now()}},9082:function(t,e,n){var r=n(5436),o=n(5557)((function(t,e){return null==t?{}:r(t,e)}));t.exports=o},8532:function(t,e,n){var r=n(1600),o=n(3301),i=n(726),a=n(3110);t.exports=function(t){return i(t)?r(a(t)):o(t)}},8163:function(t,e,n){var r=n(5034),o=n(7709);t.exports=function(t,e,n){var i=!0,a=!0;if("function"!=typeof t)throw new TypeError("Expected a function");return o(n)&&(i="leading"in n?!!n.leading:i,a="trailing"in n?!!n.trailing:a),r(t,e,{leading:i,maxWait:e,trailing:a})}},5812:function(t){t.exports=function(t){return t}},7010:function(t,e,n){var r=n(6316);t.exports=function(t){return null==t?"":r(t)}},660:function(t,e,n){var r=n(7010),o=0;t.exports=function(t){var e=++o;return r(t)+e}},9787:function(e){"use strict";e.exports=t}},n={};function r(t){var o=n[t];if(void 0!==o)return o.exports;var i=n[t]={exports:{}};return e[t](i,i.exports,r),i.exports}r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};return function(){"use strict";r.r(o),r.d(o,{CursorHelpers:function(){return m},VictoryCursorContainer:function(){return Ht},cursorContainerMixin:function(){return Tt}});var t=r(8163),e=r.n(t),n=(r(9082),r(8532),r(1893)),i=r.n(n),a=r(9787),s=r.n(a);function c(t,e){void 0===e&&(e=[]);const n={};for(const r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}function u(t){const e=t=>void 0!==t,{_x:n,_x1:r,_x0:o,_voronoiX:a,_y:s,_y1:c,_y0:u,_voronoiY:l}=t,d=e(r)?r:n,p=e(c)?c:s,f={x:e(a)?a:d,x0:e(o)?o:n,y:e(l)?l:p,y0:e(u)?u:s};return i()({},f,t)}function l(t,e){void 0===e&&(e="padding");const n=t[e],r="number"==typeof n?n:0,o="object"==typeof n?n:{};return{top:o.top||r,bottom:o.bottom||r,left:o.left||r,right:o.right||r}}function d(t,e){return f(t)?t(e):t}function p(t,e){return e.disableInlineStyles?{}:t&&Object.keys(t).some((e=>f(t[e])))?Object.keys(t).reduce(((n,r)=>(n[r]=d(t[r],e),n)),{}):t}function f(t){return"function"==typeof t}function h(t,e){if(t)return Object.keys(t).reduce(((n,r)=>(n[r]=e(t[r]),n)),{})}function g(t,e,n){const{a:r,d:o,e:i,f:a}=e;return"y"===n?o*t+a:r*t+i}function y(t){return!(!t||void 0===t.identifier)}function v(t){if(y(t.nativeEvent))return;const e=t=>"svg"===t.nodeName?t:t.parentNode?e(t.parentNode):t;return e(t.target)}const m=new class{getDimension(t){const{horizontal:e,cursorDimension:n}=t;return e&&n?"x"===n?"y":"x":n}withinBounds(t,e){const{x1:n,x2:r,y1:o,y2:i}=h(e,Number),{x:a,y:s}=h(t,Number);return a>=Math.min(n,r)&&a<=Math.max(n,r)&&s>=Math.min(o,i)&&s<=Math.max(o,i)}handleMouseMove=(t,e)=>{const{onCursorChange:n,domain:r}=e,o=this.getDimension(e),i=e.parentSVG||v(t),a=function(t,e){if(y(t.nativeEvent))return{x:t.nativeEvent.locationX,y:t.nativeEvent.locationY};const n=function(t){return t.changedTouches&&t.changedTouches.length>0}(t)?t.changedTouches[0]:t,r=function(t){return t.getScreenCTM().inverse()}(e||v(n));return{x:g(n.clientX,r,"x"),y:g(n.clientY,r,"y")}}(t,i);let s=function(t,e,n,r){const{polar:o,horizontal:i}=t;if(!o)return{x:i?e.x.invert(r):e.x.invert(n),y:i?e.y.invert(n):e.y.invert(r)};const a=t.origin||{x:0,y:0},s=n-a.x,c=r-a.y,u=Math.abs(s*Math.sqrt(1+Math.pow(-c/s,2))),l=(-Math.atan2(c,s)+2*Math.PI)%(2*Math.PI);return{x:e.x.invert(l),y:e.y.invert(u)}}(e,e.scale,a.x,a.y);return this.withinBounds(s,{x1:r.x[0],x2:r.x[1],y1:r.y[0],y2:r.y[1]})||(s=null),f(n)&&(s?n(o?s[o]:s,e):s!==e.cursorValue&&n(e.defaultCursorValue||null,e)),[{target:"parent",eventKey:"parent",mutation:()=>({cursorValue:s,parentSVG:i})}]};onMouseMove=e()(this.handleMouseMove,16,{leading:!0,trailing:!1});onMouseLeave=this.handleMouseMove;onTouchEnd=(t,e)=>{const{onCursorChange:n}=e;return f(e.onCursorChange)&&n(null,e),[{target:"parent",eventKey:"parent",mutation:()=>({cursorValue:null})}]}};var x=r(7709),b=r.n(x),w=r(660),S=r.n(w);class A extends s().Component{static displayName="Portal";constructor(t){super(t),this.map={},this.index=1}portalRegister=()=>++this.index;portalUpdate=(t,e)=>{this.map[t]=e,this.forceUpdate()};portalDeregister=t=>{delete this.map[t],this.forceUpdate()};getChildren(){return Object.keys(this.map).map((t=>{const e=this.map[t];return e?s().cloneElement(e,{key:t}):e}))}render(){return s().createElement("svg",this.props,this.getChildren())}}const C=s().createContext({});C.displayName="PortalContext";var j,E,O=0,P=0,M=0,k=0,_=0,z=0,I="object"==typeof performance&&performance.now?performance:Date,T="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function H(){return _||(T(R),_=I.now()+z)}function R(){_=0}function N(){this._call=this._time=this._next=null}function $(t,e,n){var r=new N;return r.restart(t,e,n),r}function F(){_=(k=I.now())+z,O=P=0;try{!function(){H(),++O;for(var t,e=j;e;)(t=_-e._time)>=0&&e._call.call(void 0,t),e=e._next;--O}()}finally{O=0,function(){for(var t,e,n=j,r=1/0;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:j=e);E=t,L(r)}(),_=0}}function D(){var t=I.now(),e=t-k;e>1e3&&(z-=e,k=t)}function L(t){O||(P&&(P=clearTimeout(P)),t-_>24?(t<1/0&&(P=setTimeout(F,t-I.now()-z)),M&&(M=clearInterval(M))):(M||(k=I.now(),M=setInterval(D,1e3)),O=1,T(F)))}N.prototype=$.prototype={constructor:N,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?H():+n)+(null==e?0:+e),this._next||E===this||(E?E._next=this:j=this,E=this),this._call=t,this._time=n,L()},stop:function(){this._call&&(this._call=null,this._time=1/0,L())}};class W{constructor(){this.shouldAnimate=!0,this.subscribers=[],this.timer=null,this.activeSubscriptions=0}bypassAnimation(){this.shouldAnimate=!1}resumeAnimation(){this.shouldAnimate=!0}loop=()=>{this.subscribers.forEach((t=>{t.callback(H()-t.startTime,t.duration)}))};start(){this.timer||(this.timer=$(this.loop))}stop(){this.timer&&(this.timer.stop(),this.timer=null)}subscribe(t,e){const n=this.subscribers.push({startTime:H(),callback:t,duration:this.shouldAnimate?e:0});return this.activeSubscriptions++,this.start(),n}unsubscribe(t){null!==t&&this.subscribers[t-1]&&(delete this.subscribers[t-1],this.activeSubscriptions--),0===this.activeSubscriptions&&this.stop()}}const V=s().createContext({transitionTimer:new W,animationTimer:new W});V.displayName="TimerContext";var U=V;const B={startsWith:["data-","aria-"],exactMatch:[]},G=t=>{const e={...t};return Object.fromEntries(Object.entries(e).filter((t=>{let[e]=t;return(t=>!(!(t=>{let e=!1;return B.startsWith.forEach((n=>{new RegExp(`\\b(${n})(\\w|-)+`,"g").test(t)&&(e=!0)})),e})(t)&&!(t=>B.exactMatch.includes(t))(t)))(e)})).map((e=>{let[n,r]=e;return[n,d(r,t)]})))};function K(){return K=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},K.apply(this,arguments)}class q extends s().Component{static displayName="VictoryContainer";static role="container";static defaultProps={className:"VictoryContainer",portalComponent:s().createElement(A,null),portalZIndex:99,responsive:!0,role:"img"};static contextType=U;constructor(t){super(t),this.containerId=b()(t)&&void 0!==t.containerId?t.containerId:S()("victory-container-"),this.shouldHandleWheel=!!(t&&t.events&&t.events.onWheel)}savePortalRef=t=>(this.portalRef=t,t);portalUpdate=(t,e)=>this.portalRef.portalUpdate(t,e);portalRegister=()=>this.portalRef.portalRegister();portalDeregister=t=>this.portalRef.portalDeregister(t);saveContainerRef=t=>(f(this.props.containerRef)&&this.props.containerRef(t),this.containerRef=t,t);handleWheel=t=>t.preventDefault();componentDidMount(){this.shouldHandleWheel&&this.containerRef&&this.containerRef.addEventListener("wheel",this.handleWheel)}componentWillUnmount(){this.shouldHandleWheel&&this.containerRef&&this.containerRef.removeEventListener("wheel",this.handleWheel)}getIdForElement(t){return`${this.containerId}-${t}`}getChildren(t){return t.children}getOUIAProps(t){const{ouiaId:e,ouiaSafe:n,ouiaType:r}=t;return{...e&&{"data-ouia-component-id":e},...r&&{"data-ouia-component-type":r},...void 0!==n&&{"data-ouia-safe":n}}}renderContainer(t,e,n){const{title:r,desc:o,portalComponent:a,className:c,width:u,height:l,portalZIndex:d,responsive:p}=t,f=this.getChildren(t),h=p?{width:"100%",height:"100%"}:{width:u,height:l},g=Object.assign({pointerEvents:"none",touchAction:"none",position:"relative"},h),y=Object.assign({zIndex:d,position:"absolute",top:0,left:0},h),v=Object.assign({pointerEvents:"all"},h),m=Object.assign({overflow:"visible"},h),x={width:u,height:l,viewBox:e.viewBox,preserveAspectRatio:e.preserveAspectRatio,style:m};return s().createElement(C.Provider,{value:{portalUpdate:this.portalUpdate,portalRegister:this.portalRegister,portalDeregister:this.portalDeregister}},s().createElement("div",K({style:i()({},n,g),className:c,ref:this.saveContainerRef},this.getOUIAProps(t)),s().createElement("svg",K({},e,{style:v}),r?s().createElement("title",{id:this.getIdForElement("title")},r):null,o?s().createElement("desc",{id:this.getIdForElement("desc")},o):null,f),s().createElement("div",{style:y},s().cloneElement(a,{...x,ref:this.savePortalRef}))))}render(){const{width:t,height:e,responsive:n,events:r,title:o,desc:i,tabIndex:a,preserveAspectRatio:s,role:u}=this.props,l=n?this.props.style:c(this.props.style,["height","width"]),d=G(this.props),p=Object.assign({width:t,height:e,tabIndex:a,role:u,"aria-labelledby":[o&&this.getIdForElement("title"),this.props["aria-labelledby"]].filter(Boolean).join(" ")||void 0,"aria-describedby":[i&&this.getIdForElement("desc"),this.props["aria-describedby"]].filter(Boolean).join(" ")||void 0,viewBox:n?`0 0 ${t} ${e}`:void 0,preserveAspectRatio:n?s:void 0,...d},r);return this.renderContainer(this.props,p,l)}}var Z=r(4155),X=r.n(Z);class Y extends s().Component{static displayName="VictoryPortal";static role="portal";static defaultProps={groupComponent:s().createElement("g",null)};static contextType=C;componentDidMount(){this.checkedContext||("function"!=typeof this.context.portalUpdate&&(this.renderInPlace=!0),this.checkedContext=!0),this.forceUpdate()}componentDidUpdate(){this.renderInPlace||(this.portalKey=this.portalKey||this.context.portalRegister(),this.context.portalUpdate(this.portalKey,this.element))}componentWillUnmount(){this.context&&this.context.portalDeregister&&this.context.portalDeregister(this.portalKey)}renderPortal(t){return this.renderInPlace?t:(this.element=t,null)}render(){const t=Array.isArray(this.props.children)?this.props.children[0]:this.props.children,{groupComponent:e}=this.props,n=t&&t.props||{},r=n.groupComponent?{groupComponent:e,standalone:!1}:{},o=i()(r,n,c(this.props,["children","groupComponent"])),a=t&&s().cloneElement(t,o);return this.renderPortal(a)}}function J(){return J=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},J.apply(this,arguments)}const Q=(0,a.forwardRef)(((t,e)=>{const{desc:n,id:r,tabIndex:o,origin:i,...a}=t,c={vectorEffect:"non-scaling-stroke",id:d(r,t)?.toString(),tabIndex:d(o,t),...a};return n?s().createElement("rect",J({},c,{ref:e}),s().createElement("desc",null,n)):s().createElement("rect",J({},c,{ref:e}))})),tt=t=>{const{children:e,desc:n,id:r,origin:o,tabIndex:i,title:a,...c}=t,u={id:d(r,t)?.toString(),tabIndex:d(i,t),...c};return s().createElement("text",u,a&&s().createElement("title",null,a),n&&s().createElement("desc",null,n),e)},et=t=>{const{desc:e,id:n,tabIndex:r,origin:o,...i}=t,a={id:d(n,t)?.toString(),tabIndex:d(r,t),...i};return s().createElement("tspan",a)};const nt=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];if(n.length>0)return n.reduce(((t,e)=>[t,nt(e)].join(" ")),nt(t)).trim();if(null==t||"string"==typeof t)return t;const o=[];for(const e in t)if(t.hasOwnProperty(e)){const n=t[e];o.push(`${e}(${n})`)}return o.join(" ").trim()};var rt=r(1594),ot=r.n(rt);const it={"American Typewriter":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.4203125,.3296875,.6,.6375,.8015625,.8203125,.1875,.45625,.45625,.6375,.5,.2734375,.309375,.2734375,.4390625,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.6375,.2734375,.2734375,.5,.5,.5,.6,.6921875,.7640625,.6921875,.6375,.728125,.6734375,.6203125,.7109375,.784375,.3828125,.6421875,.7859375,.6375,.9484375,.7640625,.65625,.6375,.65625,.7296875,.6203125,.6375,.7109375,.740625,.940625,.784375,.7578125,.6203125,.4375,.5,.4375,.5,.5,.4921875,.5734375,.5890625,.5109375,.6,.528125,.43125,.5578125,.6375,.3109375,.40625,.6234375,.309375,.928125,.6375,.546875,.6,.58125,.4921875,.4921875,.4,.6203125,.625,.825,.6375,.640625,.528125,.5,.5,.5,.6671875],avg:.5793421052631578},Arial:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.278125,.35625,.55625,.55625,.890625,.6671875,.1921875,.334375,.334375,.390625,.584375,.278125,.334375,.278125,.278125,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.584375,.584375,.584375,.55625,1.015625,.6703125,.6671875,.7234375,.7234375,.6671875,.6109375,.778125,.7234375,.278125,.5,.6671875,.55625,.834375,.7234375,.778125,.6671875,.778125,.7234375,.6671875,.6109375,.7234375,.6671875,.9453125,.6671875,.6671875,.6109375,.278125,.278125,.278125,.4703125,.584375,.334375,.55625,.55625,.5,.55625,.55625,.3125,.55625,.55625,.2234375,.2703125,.5,.2234375,.834375,.55625,.55625,.55625,.55625,.346875,.5,.278125,.55625,.5,.7234375,.5,.5,.5,.334375,.2609375,.334375,.584375],avg:.528733552631579},"Arial Black":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.33125,.334375,.5,.6609375,.6671875,1,.890625,.278125,.390625,.390625,.55625,.6609375,.334375,.334375,.334375,.28125,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.334375,.334375,.6609375,.6609375,.6609375,.6109375,.7453125,.78125,.778125,.778125,.778125,.7234375,.6671875,.834375,.834375,.390625,.6671875,.834375,.6671875,.9453125,.834375,.834375,.7234375,.834375,.78125,.7234375,.7234375,.834375,.7796875,1.003125,.78125,.78125,.7234375,.390625,.28125,.390625,.6609375,.5125,.334375,.6671875,.6671875,.6671875,.6671875,.6671875,.41875,.6671875,.6671875,.334375,.384375,.6671875,.334375,1,.6671875,.6671875,.6671875,.6671875,.4703125,.6109375,.4453125,.6671875,.6140625,.946875,.6671875,.615625,.55625,.390625,.278125,.390625,.6609375],avg:.6213157894736842},Baskerville:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.25,.40625,.6671875,.490625,.875,.7015625,.178125,.2453125,.246875,.4171875,.6671875,.25,.3125,.25,.521875,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.25,.25,.6671875,.6671875,.6671875,.396875,.9171875,.684375,.615625,.71875,.7609375,.625,.553125,.771875,.803125,.3546875,.515625,.78125,.6046875,.928125,.75,.8234375,.5625,.96875,.7296875,.5421875,.6984375,.771875,.7296875,.9484375,.771875,.678125,.6359375,.3640625,.521875,.3640625,.46875,.5125,.334375,.46875,.521875,.428125,.521875,.4375,.3890625,.4765625,.53125,.25,.359375,.4640625,.240625,.803125,.53125,.5,.521875,.521875,.365625,.334375,.2921875,.521875,.4640625,.678125,.4796875,.465625,.428125,.4796875,.5109375,.4796875,.6671875],avg:.5323519736842108},Courier:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6078125,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.61875,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.615625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6140625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6020559210526316},"Courier New":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6015296052631579},cursive:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.1921875,.24375,.40625,.5671875,.3984375,.721875,.909375,.2328125,.434375,.365625,.4734375,.5578125,.19375,.3484375,.19375,.7734375,.503125,.4171875,.5453125,.45,.6046875,.4703125,.5984375,.55625,.503125,.5546875,.20625,.2,.5625,.5546875,.546875,.403125,.70625,.734375,.7078125,.64375,.85,.753125,.75,.6484375,1.0765625,.44375,.5359375,.8359375,.653125,1.0109375,1.1515625,.6796875,.6984375,1.0625,.8234375,.5125,.9234375,.8546875,.70625,.9109375,.7421875,.715625,.6015625,.4640625,.3359375,.4109375,.5421875,.5421875,.4328125,.5125,.5,.3859375,.7375,.359375,.75625,.540625,.5328125,.3203125,.5296875,.5015625,.484375,.7890625,.5640625,.4203125,.703125,.471875,.4734375,.35,.4125,.5640625,.471875,.6484375,.5296875,.575,.4140625,.415625,.20625,.3796875,.5421875],avg:.5604440789473684},fantasy:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.215625,.2625,.3265625,.6109375,.534375,.7625,.7828125,.2,.4359375,.4359375,.3765625,.5109375,.2796875,.4609375,.2796875,.5296875,.6640625,.253125,.521875,.4765625,.6640625,.490625,.528125,.5546875,.496875,.5421875,.2796875,.2796875,.5625,.4609375,.5625,.4828125,.609375,.740625,.7234375,.740625,.8265625,.7234375,.6171875,.7359375,.765625,.240625,.5453125,.715625,.6078125,.8640625,.653125,.9125,.6484375,.946875,.6921875,.653125,.6953125,.8015625,.58125,.784375,.671875,.6265625,.690625,.4359375,.5296875,.4359375,.53125,.5,.2875,.5375,.603125,.4984375,.60625,.53125,.434375,.6421875,.56875,.209375,.4671875,.5484375,.2203125,.709375,.55,.5984375,.6140625,.5765625,.40625,.4734375,.3734375,.559375,.4421875,.6421875,.4890625,.578125,.4484375,.2546875,.2203125,.2546875,.55],avg:.536496710526316},Geneva:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3328125,.3046875,.5,.6671875,.6671875,.90625,.728125,.3046875,.446875,.446875,.5078125,.6671875,.3046875,.3796875,.3046875,.5390625,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.6671875,.3046875,.3046875,.6671875,.6671875,.6671875,.56875,.871875,.728125,.6375,.6515625,.7015625,.5765625,.5546875,.675,.690625,.2421875,.4921875,.6640625,.584375,.7890625,.709375,.7359375,.584375,.78125,.60625,.60625,.640625,.6671875,.728125,.946875,.6109375,.6109375,.5765625,.446875,.5390625,.446875,.6671875,.6671875,.5921875,.5546875,.6109375,.546875,.603125,.5765625,.390625,.6109375,.584375,.2359375,.334375,.5390625,.2359375,.8953125,.584375,.60625,.603125,.603125,.3875,.509375,.44375,.584375,.565625,.78125,.53125,.571875,.5546875,.4515625,.246875,.4515625,.6671875],avg:.5762664473684211},Georgia:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2421875,.33125,.4125,.64375,.6109375,.81875,.7109375,.215625,.375,.375,.4734375,.64375,.2703125,.375,.2703125,.46875,.6140625,.4296875,.559375,.553125,.565625,.5296875,.5671875,.503125,.596875,.5671875,.3125,.3125,.64375,.64375,.64375,.4796875,.9296875,.715625,.6546875,.6421875,.75,.6546875,.6,.7265625,.815625,.390625,.51875,.7203125,.6046875,.928125,.7671875,.7453125,.6109375,.7453125,.7234375,.5625,.61875,.7578125,.70625,.99375,.7125,.6640625,.6015625,.375,.46875,.375,.64375,.65,.5,.5046875,.56875,.4546875,.575,.484375,.39375,.509375,.5828125,.29375,.3671875,.546875,.2875,.88125,.5921875,.5390625,.571875,.5640625,.4109375,.4328125,.3453125,.5765625,.5203125,.75625,.50625,.5171875,.4453125,.43125,.375,.43125,.64375],avg:.5551809210526316},"Gill Sans":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2765625,.271875,.3546875,.584375,.5421875,.6765625,.625,.1890625,.3234375,.3234375,.4171875,.584375,.2203125,.3234375,.2203125,.28125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.2203125,.2296875,.584375,.584375,.584375,.334375,1.0109375,.6671875,.5640625,.709375,.75,.5,.4703125,.740625,.7296875,.25,.3125,.65625,.490625,.78125,.78125,.8234375,.5109375,.8234375,.6046875,.459375,.6046875,.709375,.6046875,1.0421875,.709375,.6046875,.646875,.334375,.28125,.334375,.4703125,.5828125,.334375,.428125,.5,.4390625,.5109375,.4796875,.296875,.428125,.5,.2203125,.2265625,.5,.2203125,.771875,.5,.553125,.5,.5,.3984375,.3859375,.334375,.5,.4390625,.7203125,.5,.4390625,.4171875,.334375,.2609375,.334375,.584375],avg:.4933717105263159},Helvetica:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2796875,.2765625,.3546875,.5546875,.5546875,.8890625,.665625,.190625,.3328125,.3328125,.3890625,.5828125,.2765625,.3328125,.2765625,.3015625,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.5546875,.2765625,.2765625,.584375,.5828125,.584375,.5546875,1.0140625,.665625,.665625,.721875,.721875,.665625,.609375,.7765625,.721875,.2765625,.5,.665625,.5546875,.8328125,.721875,.7765625,.665625,.7765625,.721875,.665625,.609375,.721875,.665625,.94375,.665625,.665625,.609375,.2765625,.3546875,.2765625,.4765625,.5546875,.3328125,.5546875,.5546875,.5,.5546875,.5546875,.2765625,.5546875,.5546875,.221875,.240625,.5,.221875,.8328125,.5546875,.5546875,.5546875,.5546875,.3328125,.5,.2765625,.5546875,.5,.721875,.5,.5,.5,.3546875,.259375,.353125,.5890625],avg:.5279276315789471},"Helvetica Neue":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.259375,.4265625,.55625,.55625,1,.6453125,.278125,.2703125,.26875,.353125,.6,.278125,.3890625,.278125,.36875,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.6,.6,.6,.55625,.8,.6625,.6859375,.7234375,.7046875,.6125,.575,.759375,.7234375,.259375,.5203125,.6703125,.55625,.871875,.7234375,.7609375,.6484375,.7609375,.6859375,.6484375,.575,.7234375,.6140625,.9265625,.6125,.6484375,.6125,.259375,.36875,.259375,.6,.5,.25625,.5375,.59375,.5375,.59375,.5375,.2984375,.575,.55625,.2234375,.2375,.5203125,.2234375,.853125,.55625,.575,.59375,.59375,.334375,.5,.315625,.55625,.5,.759375,.51875,.5,.48125,.334375,.2234375,.334375,.6],avg:.5279440789473684},"Hoefler Text":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2359375,.2234375,.3921875,.7125,.49375,.8859375,.771875,.2125,.3078125,.309375,.375,.4234375,.234375,.3125,.234375,.3,.5828125,.365625,.434375,.3921875,.5234375,.3984375,.5125,.4328125,.46875,.5125,.234375,.234375,.515625,.4234375,.515625,.340625,.7609375,.7359375,.6359375,.721875,.8125,.6375,.5875,.8078125,.853125,.4296875,.503125,.78125,.609375,.9609375,.8515625,.8140625,.6125,.8140625,.71875,.49375,.7125,.76875,.771875,1.125,.7765625,.7734375,.65625,.321875,.3078125,.321875,.3546875,.5,.3375,.446875,.5359375,.45,.5296875,.4546875,.425,.4921875,.54375,.2671875,.240625,.5390625,.25,.815625,.5375,.5234375,.5390625,.5421875,.365625,.36875,.35625,.5171875,.5015625,.75,.5,.509375,.44375,.2421875,.14375,.2421875,.35],avg:.5116447368421051},Montserrat:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2625,.2609375,.3734375,.696875,.615625,.8296875,.6703125,.203125,.3296875,.3296875,.3875,.575,.2125,.3828125,.2125,.3953125,.6625,.3625,.56875,.5640625,.6625,.5671875,.609375,.5890625,.6390625,.609375,.2125,.2125,.575,.575,.575,.5671875,1.034375,.7171875,.7546875,.7203125,.8265625,.6703125,.634375,.7734375,.8140625,.303125,.5078125,.7125,.5890625,.95625,.8140625,.8390625,.71875,.8390625,.7234375,.615625,.575,.7921875,.6984375,1.1125,.65625,.6359375,.6515625,.31875,.396875,.31875,.5765625,.5,.6,.590625,.678125,.5640625,.678125,.6046875,.375,.6875,.678125,.2703125,.365625,.6015625,.2703125,1.0625,.678125,.628125,.678125,.678125,.4015625,.4890625,.40625,.6734375,.5421875,.8796875,.534375,.5671875,.5125,.334375,.2953125,.334375,.575],avg:.571792763157895},monospace:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.5984375,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6078125,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.61875,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.615625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6140625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625,.6015625],avg:.6020559210526316},Overpass:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2296875,.2765625,.4203125,.68125,.584375,.8515625,.7015625,.2203125,.3453125,.3453125,.53125,.63125,.2234375,.3953125,.2234375,.509375,.65,.4046875,.6171875,.60625,.6484375,.60625,.6015625,.5375,.615625,.6015625,.2234375,.2234375,.63125,.63125,.63125,.5015625,.8203125,.696875,.6671875,.65,.6859375,.6015625,.559375,.690625,.7078125,.2953125,.565625,.678125,.58125,.8046875,.7109375,.740625,.6421875,.740625,.6765625,.6046875,.590625,.696875,.6640625,.853125,.65,.6671875,.6625,.3734375,.509375,.3734375,.63125,.5125,.4,.5328125,.5625,.51875,.5625,.546875,.3359375,.5625,.565625,.25625,.3203125,.55,.265625,.85,.565625,.5671875,.5625,.5625,.4046875,.4765625,.3796875,.565625,.521875,.7265625,.53125,.5390625,.5125,.3671875,.275,.3671875,.63125],avg:.5430756578947369},Palatino:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.25,.278125,.371875,.60625,.5,.840625,.778125,.209375,.334375,.334375,.390625,.60625,.2578125,.334375,.25,.60625,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.25,.25,.60625,.60625,.60625,.4453125,.7484375,.778125,.6109375,.709375,.775,.6109375,.55625,.7640625,.8328125,.3375,.346875,.7265625,.6109375,.946875,.83125,.7875,.6046875,.7875,.66875,.525,.6140625,.778125,.7234375,1,.6671875,.6671875,.6671875,.334375,.60625,.334375,.60625,.5,.334375,.5,.565625,.4453125,.6109375,.4796875,.340625,.55625,.5828125,.2921875,.2671875,.5640625,.2921875,.8828125,.5828125,.546875,.6015625,.5609375,.3953125,.425,.3265625,.603125,.565625,.834375,.5171875,.55625,.5,.334375,.60625,.334375,.60625],avg:.5408552631578947},RedHatText:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2328125,.2203125,.35625,.6890625,.55,.7390625,.6703125,.2140625,.4015625,.4015625,.4546875,.53125,.2203125,.45625,.2203125,.515625,.6609375,.3078125,.5484375,.5875,.61875,.5703125,.6203125,.559375,.6140625,.6203125,.2203125,.2234375,.465625,.534375,.465625,.5125,.7671875,.6609375,.6703125,.7265625,.728125,.6203125,.6109375,.8,.73125,.253125,.6,.6125,.6078125,.8625,.7390625,.8109375,.6546875,.809375,.6484375,.6234375,.6171875,.7125,.6609375,.8984375,.6546875,.646875,.60625,.3625,.5203125,.3625,.540625,.4609375,.5234375,.5265625,.584375,.509375,.5828125,.5578125,.3703125,.5828125,.553125,.2234375,.24375,.4890625,.2234375,.8453125,.553125,.58125,.584375,.5828125,.353125,.453125,.378125,.553125,.5015625,.6984375,.4875,.4984375,.459375,.3953125,.2921875,.3953125,.58125],avg:.5341940789473685},"sans-serif":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.278125,.278125,.35625,.55625,.55625,.890625,.6671875,.1921875,.334375,.334375,.390625,.584375,.278125,.334375,.278125,.303125,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.55625,.278125,.278125,.5859375,.584375,.5859375,.55625,1.015625,.6671875,.6671875,.7234375,.7234375,.6671875,.6109375,.778125,.7234375,.278125,.5,.6671875,.55625,.834375,.7234375,.778125,.6671875,.778125,.7234375,.6671875,.6109375,.7234375,.6671875,.9453125,.6671875,.6671875,.6109375,.278125,.35625,.278125,.478125,.55625,.334375,.55625,.55625,.5,.55625,.55625,.278125,.55625,.55625,.2234375,.2421875,.5,.2234375,.834375,.55625,.55625,.55625,.55625,.334375,.5,.278125,.55625,.5,.7234375,.5,.5,.5,.35625,.2609375,.3546875,.590625],avg:.5293256578947368},Seravek:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.215625,.296875,.4171875,.6734375,.4953125,.9125,.740625,.2421875,.3375,.3375,.409375,.60625,.2609375,.35625,.25625,.41875,.5921875,.3515625,.475,.4875,.5375,.509375,.5484375,.4546875,.5421875,.5484375,.25625,.2546875,.5875,.6171875,.5875,.4578125,.8140625,.6765625,.5703125,.6109375,.684375,.5109375,.4953125,.678125,.6859375,.2625,.2625,.5859375,.4734375,.846875,.709375,.740625,.509375,.740625,.584375,.5015625,.528125,.675,.5953125,.9453125,.596875,.540625,.540625,.359375,.4203125,.359375,.5109375,.421875,.4046875,.5015625,.5421875,.446875,.5453125,.484375,.38125,.5140625,.5546875,.240625,.2640625,.490625,.2765625,.8625,.5546875,.546875,.5453125,.5453125,.3625,.41875,.3890625,.5453125,.4703125,.7546875,.4921875,.4609375,.453125,.4015625,.2640625,.4015625,.58125],avg:.5044078947368421},serif:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2484375,.334375,.409375,.5,.5,.834375,.778125,.18125,.334375,.334375,.5,.5640625,.25,.334375,.25,.278125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.278125,.278125,.5640625,.5640625,.5640625,.4453125,.921875,.7234375,.6671875,.6671875,.7234375,.6109375,.55625,.7234375,.7234375,.334375,.390625,.7234375,.6109375,.890625,.7234375,.7234375,.55625,.7234375,.6671875,.55625,.6109375,.7234375,.7234375,.9453125,.7234375,.7234375,.6109375,.334375,.340625,.334375,.4703125,.5,.3453125,.4453125,.5,.4453125,.5,.4453125,.3828125,.5,.5,.278125,.3359375,.5,.278125,.778125,.5,.5,.5,.5,.3375,.390625,.2796875,.5,.5,.7234375,.5,.5,.4453125,.48125,.2015625,.48125,.5421875],avg:.5126315789473684},Tahoma:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3109375,.3328125,.4015625,.728125,.546875,.9765625,.70625,.2109375,.3828125,.3828125,.546875,.728125,.303125,.3640625,.303125,.3953125,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.546875,.3546875,.3546875,.728125,.728125,.728125,.475,.909375,.6109375,.590625,.6015625,.6796875,.5625,.521875,.66875,.6765625,.3734375,.4171875,.6046875,.4984375,.771875,.66875,.7078125,.5515625,.7078125,.6375,.5578125,.5875,.65625,.60625,.903125,.58125,.5890625,.559375,.3828125,.39375,.3828125,.728125,.5625,.546875,.525,.553125,.4625,.553125,.5265625,.3546875,.553125,.5578125,.2296875,.328125,.51875,.2296875,.840625,.5578125,.54375,.553125,.553125,.3609375,.446875,.3359375,.5578125,.4984375,.7421875,.4953125,.4984375,.4453125,.48125,.3828125,.48125,.728125],avg:.5384374999999998},"Times New Roman":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2484375,.334375,.409375,.5,.5,.834375,.778125,.18125,.334375,.334375,.5,.5640625,.25,.334375,.25,.28125,.5,.5,.5,.5,.5,.5,.5,.5,.5,.5,.278125,.278125,.5640625,.5640625,.5640625,.4453125,.921875,.7234375,.6671875,.6671875,.7234375,.6109375,.55625,.7234375,.7234375,.334375,.390625,.73125,.6109375,.890625,.7375,.7234375,.55625,.7234375,.6765625,.55625,.6109375,.7234375,.7234375,.9453125,.7234375,.7234375,.6109375,.334375,.28125,.334375,.4703125,.51875,.334375,.4453125,.503125,.4453125,.503125,.4453125,.4359375,.5,.5,.278125,.35625,.50625,.278125,.778125,.5,.5,.5046875,.5,.340625,.390625,.2796875,.5,.5,.7234375,.5,.5,.4453125,.48125,.2015625,.48125,.5421875],avg:.5134375},"Trebuchet MS":{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.3015625,.3671875,.325,.53125,.525,.6015625,.70625,.1609375,.3671875,.3671875,.3671875,.525,.3671875,.3671875,.3671875,.525,.525,.525,.525,.525,.525,.525,.525,.525,.525,.525,.3671875,.3671875,.525,.525,.525,.3671875,.771875,.590625,.5671875,.5984375,.6140625,.5359375,.525,.6765625,.6546875,.2796875,.4765625,.5765625,.5078125,.7109375,.6390625,.675,.5578125,.7421875,.5828125,.48125,.58125,.6484375,.5875,.853125,.5578125,.5703125,.5515625,.3671875,.3578125,.3671875,.525,.53125,.525,.5265625,.5578125,.4953125,.5578125,.546875,.375,.503125,.546875,.2859375,.3671875,.5046875,.2953125,.83125,.546875,.5375,.5578125,.5578125,.3890625,.40625,.396875,.546875,.490625,.7453125,.5015625,.49375,.475,.3671875,.525,.3671875,.525],avg:.5085197368421052},Verdana:{widths:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.35,.39375,.459375,.81875,.6359375,1.0765625,.759375,.26875,.4546875,.4546875,.6359375,.81875,.3640625,.4546875,.3640625,.4703125,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.6359375,.4546875,.4546875,.81875,.81875,.81875,.546875,1,.684375,.6859375,.6984375,.771875,.6328125,.575,.7765625,.7515625,.421875,.4546875,.69375,.5578125,.84375,.7484375,.7875,.603125,.7875,.7,.684375,.6171875,.7328125,.684375,.9890625,.6859375,.615625,.6859375,.4546875,.46875,.4546875,.81875,.6421875,.6359375,.6015625,.6234375,.521875,.6234375,.596875,.384375,.6234375,.6328125,.275,.3765625,.5921875,.275,.9734375,.6328125,.6078125,.6234375,.6234375,.43125,.521875,.3953125,.6328125,.5921875,.81875,.5921875,.5921875,.5265625,.6359375,.4546875,.6359375,.81875],avg:.6171875000000003}},at={mm:3.8,sm:38,pt:1.33,pc:16,in:96,px:1},st={em:1,ex:.5},ct={lineHeight:1,letterSpacing:"0px",fontSize:0,angle:0,fontFamily:""},ut=t=>Array.isArray(t)?t:t.toString().split(/\r\n|\r|\n/g),lt=(t,e,n)=>{const r=(t=>t*Math.PI/180)(n);return Math.abs(Math.cos(r)*t)+Math.abs(Math.sin(r)*e)},dt=(t,e)=>{const n=t.match(/[a-zA-Z%]+/)?.[0],r=Number(t.match(/[0-9.,]+/));let o;return o=n?at.hasOwnProperty(n)?r*at[n]:st.hasOwnProperty(n)?(e?r*e:r*ct.fontSize)*st[n]:r:r||0,o},pt=(t,e)=>{const n=Array.isArray(t)?t[e]:t,r=i()({},n,ct);return Object.assign({},r,{fontFamily:r.fontFamily,letterSpacing:"number"==typeof r.letterSpacing?r.letterSpacing:dt(String(r.letterSpacing),r.fontSize),fontSize:"number"==typeof r.fontSize?r.fontSize:dt(String(r.fontSize))})},ft=(t,e)=>{const n=Array.isArray(e)?e[0]&&e[0].angle:e&&e.angle,r=((t,e)=>void 0===t||""===t||null===t?0:ut(t).reduce(((t,n,r)=>{const o=pt(e,r),i=n.toString().match(/[(A-Z)(0-9)]/)?1.15*o.fontSize:o.fontSize;return t+o.lineHeight*i}),0))(t,e),o=((t,e)=>{if(void 0===t||""===t||null===t)return 0;const n=ut(t).map(((t,n)=>{const r=t.toString().length,{fontSize:o,letterSpacing:i,fontFamily:a}=pt(e,n),s=(t=>{const e=t.split(",").map((t=>t.replace(/'|"/g,""))).find((t=>it[t]))||"Helvetica";return it[e]})(a);return t.toString().split("").map((t=>t.charCodeAt(0)<s.widths.length?s.widths[t.charCodeAt(0)]:s.avg)).reduce(((t,e)=>e+t),0)*o+i*Math.max(r-1,0)}));return Math.max(...n)})(t,e);return{width:n?lt(o,r,n):o,height:1.05*(n?lt(r,o,n):r)}},ht=ot()((()=>{const t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("xlink","http://www.w3.org/1999/xlink"),t.setAttribute("width","300"),t.setAttribute("height","300"),t.setAttribute("viewBox","0 0 300 300"),t.setAttribute("aria-hidden","true");const e=document.createElementNS("http://www.w3.org/2000/svg","text");return t.appendChild(e),t.style.position="fixed",t.style.top="-9999px",t.style.left="-9999px",document.body.appendChild(t),e})),gt=t=>t?`${t.angle}:${t.fontFamily}:${t.fontSize}:${t.letterSpacing}:${t.lineHeight}`:"null",yt=ot()(((t,e)=>{let n=ht();n.isConnected||(ht.cache.clear?.(),n=ht());const r=ut(t);let o=0;for(const[t,i]of r.entries()){const r=document.createElementNS("http://www.w3.org/2000/svg","tspan"),a=pt(e,t);r.style.fontFamily=a.fontFamily,r.style.fontSize=`${a.fontSize}px`,r.style.lineHeight=a.lineHeight,r.style.fontFamily=a.fontFamily,r.style.letterSpacing=a.letterSpacing,r.textContent=i,r.setAttribute("x","0"),r.setAttribute("y",`${o}`),n.appendChild(r),o+=a.lineHeight*r.getBoundingClientRect().height}const{width:i}=n.getBoundingClientRect();return n.innerHTML="",{width:e?.angle?lt(i,o,e?.angle):i,height:e?.angle?lt(o,i,e?.angle):o}}),((t,e)=>`${Array.isArray(t)?t.join():t}::${Array.isArray(e)?e.map(gt).join():gt(e)}`)),vt=(t,e)=>function(t,e,n){return void 0===n&&(n=!1),"undefined"==typeof window||void 0===window.document||void 0===window.document.createElement||n?ft(t,e):yt(t,e)}(t,e),mt={fill:"#252525",fontSize:14,fontFamily:"'Gill Sans', 'Gill Sans MT', 'Seravek', 'Trebuchet MS', sans-serif",stroke:"transparent"},xt=(t,e)=>{if(!t.datum)return 0;const n=function(t,e){const{scale:n,polar:r,horizontal:o}=t,i=u(e),a=t.origin||{x:0,y:0},s=o?n.y(i.y):n.x(i.x),c=o?n.y(i.y0):n.x(i.x0),l=o?n.x(i.x):n.y(i.y),d=o?n.x(i.x0):n.y(i.y0);return{x:r?l*Math.cos(s)+a.x:s,x0:r?d*Math.cos(c)+a.x:c,y:r?-l*Math.sin(s)+a.y:l,y0:r?-d*Math.sin(c)+a.x:d}}(t,t.datum);return n[e]},bt=t=>{const e=t&&t.fontSize;if("number"==typeof e)return e;if(null==e)return mt.fontSize;if("string"==typeof e){const t=Number(e.replace("px",""));return isNaN(t)?mt.fontSize:t}return mt.fontSize},wt=function(t,e){return void 0===e&&(e=0),Array.isArray(t)?t[e]||t[0]:t},St=t=>{const{backgroundStyle:e,backgroundPadding:n}=t;return Array.isArray(e)&&!X()(e)||Array.isArray(n)&&!X()(n)},At=(t,e,n)=>{const{polar:r}=t,o=wt(t.style),i=r?function(t,e){const{labelPlacement:n,datum:r}=t;if(!n||"vertical"===n)return 0;const o=function(t,e){const{x:n}=u(e);return("number"==typeof(r=t.scale.x(n))?r/(Math.PI/180):r)%360;var r}(t,r);let i=0;return 0===o||180===o?i=90:o>0&&o<180?i=90-o:o>180&&o<360&&(i=270-o),i+(o>90&&o<180||o>270?1:-1)*("perpendicular"===n?0:90)}(t):0,a=void 0===o.angle?d(t.angle,t):o.angle,s=void 0===a?i:a,c=t.transform||o.transform,l=c&&d(c,t);return l||s?nt(l,s&&{rotate:[s,e,n]}):void 0},Ct=(t,e)=>{const{direction:n,textAnchor:r,x:o,dx:i}=t;if("rtl"===n)return o-e;switch(r){case"middle":return Math.round(o-e/2);case"end":return Math.round(o-e);default:return o+(i||0)}},jt=(t,e)=>{const{verticalAnchor:n,y:r,originalDy:o=0}=t,i=r+o;switch(n){case"start":return Math.floor(i);case"end":return Math.ceil(i-e);default:return Math.floor(i-e/2)}},Et=(t,e)=>St(t)?((t,e)=>{const{dy:n,dx:r,transform:o,backgroundStyle:a,backgroundPadding:c,backgroundComponent:u,inline:l,y:d}=t,p=e.map(((t,o)=>{const i=wt(e,o-1),a=t.textSize,s=t.fontSize*t.lineHeight,u=Math.ceil(s),p=wt(c,o),f=wt(c,o-1),h=l&&r||0,g=o&&!l?i.fontSize*i.lineHeight+f.top+f.bottom:n-.5*s-(t.fontSize-t.capHeight);return{textHeight:u,labelSize:a,heightWithPadding:u+p.top+p.bottom,widthWithPadding:a.width+p.left+p.right+h,y:d,fontSize:t.fontSize,dy:g}}));return p.map(((e,n)=>{const r=Ct(t,e.labelSize.width),f=p.slice(0,n+1).reduce(((t,e)=>t+e.dy),d),h=wt(c,n),g=e.heightWithPadding,y=l?((t,e,n)=>{const{textAnchor:r}=t,o=e.map((t=>t.widthWithPadding)),i=-o.reduce(((t,e)=>t+e),0)/2;switch(r){case"start":return o.reduce(((t,e,r)=>r<n?t+e:t),0);case"end":return o.reduce(((t,e,r)=>r>n?t-e:t),0);default:return o.reduce(((t,e,r)=>r===n?t+e/2:t+(r<n?e:0)),i)}})(t,p,n)+r-h.left:r,v=l?jt(t,g)-h.top:f,m={key:`tspan-background-${n}`,height:g,style:wt(a,n),width:e.widthWithPadding,transform:o,x:y-h.left,y:v};return s().cloneElement(u,i()({},u.props,m))}))})(t,e):((t,e)=>{const{dx:n=0,transform:r,backgroundComponent:o,backgroundStyle:a,inline:c,backgroundPadding:u,capHeight:l}=t,d=e.map((t=>t.textSize)),p=c?Math.max(...d.map((t=>t.height))):d.reduce(((t,n,r)=>{const o=r?0:l/2;return t+n.height*(e[r].lineHeight-o)}),0),f=c?d.reduce(((t,e,r)=>{const o=r?n:0;return t+e.width+o}),0):Math.max(...d.map((t=>t.width))),h=Ct(t,f),g=jt(t,p),y={key:"background",height:p+u.top+u.bottom,style:a,transform:r,width:f+u.left+u.right,x:c?h-u.left:h+n-u.left,y:g};return s().cloneElement(o,i()({},o.props,y))})(t,e),Ot=(t,e,n)=>{const{inline:r}=e,o=wt(t,n);return n&&!r?((t,e,n)=>{const r=wt(t,e),o=wt(t,e-1),i=o.fontSize*o.lineHeight,a=r.fontSize*r.lineHeight,s=o.fontSize-o.capHeight,c=r.fontSize-r.capHeight,u=i-o.fontSize/2+r.fontSize/2-i/2+a/2-c/2+s/2;return St(n)?u+r.backgroundPadding.top+o.backgroundPadding.bottom:u})(t,n,e):r?0===n?o.backgroundPadding.top:void 0:o.backgroundPadding.top},Pt={backgroundComponent:s().createElement(Q,null),groupComponent:s().createElement("g",null),direction:"inherit",textComponent:s().createElement(tt,null),tspanComponent:s().createElement(et,null),capHeight:.71,lineHeight:1},Mt=t=>{const e=(t=>{const e=((t,e)=>{if(null==t)return;if(Array.isArray(t))return t.map((t=>d(t,e)));const n=d(t,e);return null!=n?Array.isArray(n)?n:`${n}`.split("\n"):void 0})(t.text,t),n=((t,e)=>{if(e.disableInlineStyles){const n=p(t,e);return{fontSize:bt(n)}}const n=t=>{const n=p(t?i()({},t,mt):mt,e);return Object.assign({},n,{fontSize:bt(n)})};return Array.isArray(t)&&!X()(t)?t.map((t=>n(t))):n(t)})(t.style,Object.assign({},t,{text:e})),r=((t,e)=>{if(t)return Array.isArray(t)&&!X()(t)?t.map((t=>p(t,e))):p(t,e)})(t.backgroundStyle,Object.assign({},t,{text:e,style:n})),o=(t=>t.backgroundPadding&&Array.isArray(t.backgroundPadding)?t.backgroundPadding.map((e=>l({padding:d(e,t)}))):l({padding:d(t.backgroundPadding,t)}))(Object.assign({},t,{text:e,style:n,backgroundStyle:r})),a=d(t.id,t);return Object.assign({},t,{backgroundStyle:r,backgroundPadding:o,style:n,text:e,id:a})})({...Pt,...t});if(null===e.text||void 0===e.text)return null;const n=(t=>{const e=d(t.ariaLabel,t),n=wt(t.style),r=(t=>{const e=d(t.lineHeight,t);return Array.isArray(e)&&X()(e)?[1]:e})(t),o=t.direction?d(t.direction,t):"inherit",i=t.textAnchor?d(t.textAnchor,t):n.textAnchor||"start",a=t.verticalAnchor?d(t.verticalAnchor,t):n.verticalAnchor||"middle",s=t.dx?d(t.dx,t):0,c=((t,e,n)=>{const r=t.dy?d(t.dy,t):0,o=t.inline?1:t.text.length,i=d(t.capHeight,t),a=e?d(e,t):"middle",s=[...Array(o).keys()].map((e=>wt(t.style,e).fontSize)),c=[...Array(o).keys()].map((t=>wt(n,t)));if("start"===a)return r+(i/2+c[0]/2)*s[0];if(t.inline)return"end"===a?r+(i/2-c[0]/2)*s[0]:r+i/2*s[0];if(1===o)return"end"===a?r+(i/2+(.5-o)*c[0])*s[0]:r+(i/2+(.5-o/2)*c[0])*s[0];const u=[...Array(o).keys()].reduce(((t,e)=>t+(i/2+(.5-o)*c[e])*s[e]/o),0);return"end"===a?r+u:r+u/2+i/2*c[o-1]*s[o-1]})(t,a,r),u=void 0!==t.x?t.x:xt(t,"x"),l=void 0!==t.y?t.y:xt(t,"y"),p=At(t,u,l);return Object.assign({},t,{ariaLabel:e,lineHeight:r,direction:o,textAnchor:i,verticalAnchor:a,dx:s,dy:c,originalDy:d(t.dy,t),transform:p,x:u,y:l})})(e),{text:r,style:o,capHeight:a,backgroundPadding:c,lineHeight:u}=n,f=r.map(((t,e)=>{const n=wt(o,e),r=dt(`${a}em`,n.fontSize),i=wt(u,e);return{style:n,fontSize:n.fontSize||mt.fontSize,capHeight:r,text:t,textSize:vt(t,n),lineHeight:i,backgroundPadding:wt(c,e)}})),h=((t,e)=>{const{ariaLabel:n,inline:r,className:o,title:i,events:a,direction:c,text:u,textAnchor:l,dx:p,dy:f,transform:h,x:g,y:y,desc:v,id:m,tabIndex:x,tspanComponent:b,textComponent:w}=t,S=G(t),A={"aria-label":n,key:"text",...a,direction:c,dx:p,x:g,y:y+f,transform:h,className:o,title:i,desc:d(v,t),tabIndex:d(x,t),id:m,...S},C=u.map(((n,o)=>{const i=e[o].style,a={key:`${m}-key-${o}`,x:r?void 0:g,dx:r?p+e[o].backgroundPadding.left:p,dy:Ot(e,t,o),textAnchor:i.textAnchor||l,style:i,children:n};return s().cloneElement(b,a)}));return s().cloneElement(w,A,C)})(n,f);if(e.backgroundStyle){const t=[Et(n,f),h],r=s().cloneElement(e.groupComponent,{},t);return e.renderInPortal?s().createElement(Y,null,r):r}return e.renderInPortal?s().createElement(Y,null,h):h};function kt(){return kt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},kt.apply(this,arguments)}Mt.displayName="VictoryLabel",Mt.role="label",Mt.defaultStyles=mt;const _t=(0,a.forwardRef)(((t,e)=>{const{desc:n,id:r,tabIndex:o,origin:i,...a}=t,c={vectorEffect:"non-scaling-stroke",id:d(r,t)?.toString(),tabIndex:d(o,t),...a};return n?s().createElement("line",kt({},c,{ref:e}),s().createElement("desc",null,n)):s().createElement("line",kt({},c,{ref:e}))})),zt={lineComponent:s().createElement(_t,null),role:"presentation",shapeRendering:"auto"},It=t=>{const e=(t=>{const e=d(t.ariaLabel,t),n=d(t.desc,t),r=d(t.id,t),o=p(Object.assign({stroke:"black"},t.style),t),i=d(t.tabIndex,t);return Object.assign({},t,{ariaLabel:e,desc:n,id:r,style:o,tabIndex:i})})({...zt,...t});return s().cloneElement(e.lineComponent,{...e.events,"aria-label":e.ariaLabel,style:e.style,desc:e.desc,tabIndex:e.tabIndex,className:e.className,role:e.role,shapeRendering:e.shapeRendering,x1:e.x1,x2:e.x2,y1:e.y1,y2:e.y2,transform:e.transform,clipPath:e.clipPath})};function Tt(t){return class extends t{static displayName="VictoryCursorContainer";static defaultProps={...q.defaultProps,cursorLabelComponent:s().createElement(Mt,null),cursorLabelOffset:{x:5,y:-10},cursorComponent:s().createElement(It,null)};static defaultEvents(t){return[{target:"parent",eventHandlers:{onMouseLeave:(e,n)=>t.disable?{}:m.onMouseLeave(e,n),onTouchCancel:()=>[],onMouseMove:(e,n)=>t.disable?{}:m.onMouseMove(e,n),onTouchMove:(e,n)=>t.disable?{}:m.onMouseMove(e,n)}}]}getCursorPosition(t){const{cursorValue:e,defaultCursorValue:n,domain:r,cursorDimension:o}=t;return e||("number"==typeof n?{x:(r.x[0]+r.x[1])/2,y:(r.y[0]+r.y[1])/2,[o]:n}:n)}getCursorLabelOffset(t){const{cursorLabelOffset:e}=t;return"number"==typeof e?{x:e,y:e}:e}getPadding(t){return void 0===t.padding?l(t.children.find((t=>b()(t.props)&&void 0!==t.props.padding)).props):l(t)}getCursorElements(t){const{scale:e,cursorLabelComponent:n,cursorLabel:r,cursorComponent:o,width:a,height:c,name:u,horizontal:l,theme:p}=t,f=m.getDimension(t),h=this.getCursorPosition(t),g=this.getCursorLabelOffset(t);if(!h)return[];const y=[],v=this.getPadding(t),x={x:l?e.y(h.y):e.x(h.x),y:l?e.x(h.x):e.y(h.y)};if(r){let t=i()({active:!0},n.props,{x:x.x+g.x,y:x.y+g.y,datum:h,active:!0,key:`${u}-cursor-label`});if("tooltip"===((b=n)&&b.type&&b.type.role)){const e=p&&p.tooltip||{};t=i()({},t,e)}y.push(s().cloneElement(n,i()({},t,{text:d(r,t)})))}var b;const w=Object.assign({stroke:"black"},o.props.style);return"x"!==f&&void 0!==f||y.push(s().cloneElement(o,{key:`${u}-x-cursor`,x1:x.x,x2:x.x,y1:v.top,y2:c-v.bottom,style:w})),"y"!==f&&void 0!==f||y.push(s().cloneElement(o,{key:`${u}-y-cursor`,x1:v.left,x2:a-v.right,y1:x.y,y2:x.y,style:w})),y}getChildren(t){return[...s().Children.toArray(t.children),...this.getCursorElements(t)]}}}const Ht=Tt(q)}(),o}()}));
|
|
2
2
|
//# sourceMappingURL=victory-cursor-container.min.js.map
|
package/es/cursor-helpers.d.ts
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
/// <reference types="lodash" />
|
|
2
|
-
import { Selection } from "victory-core";
|
|
3
|
-
declare class CursorHelpersClass {
|
|
4
|
-
getDimension(props: any): any;
|
|
5
|
-
withinBounds(point: any, bounds: any): boolean;
|
|
6
|
-
private handleMouseMove;
|
|
7
|
-
onMouseMove: import("lodash").DebouncedFunc<(evt: any, targetProps: any) => {
|
|
8
|
-
target: string;
|
|
9
|
-
eventKey: string;
|
|
10
|
-
mutation: () => {
|
|
11
|
-
cursorValue: Selection.SVGCoordinateType | null;
|
|
12
|
-
parentSVG: any;
|
|
13
|
-
};
|
|
14
|
-
}[]>;
|
|
15
|
-
onMouseLeave: (evt: any, targetProps: any) => {
|
|
16
|
-
target: string;
|
|
17
|
-
eventKey: string;
|
|
18
|
-
mutation: () => {
|
|
19
|
-
cursorValue: Selection.SVGCoordinateType | null;
|
|
20
|
-
parentSVG: any;
|
|
21
|
-
};
|
|
22
|
-
}[];
|
|
23
|
-
onTouchEnd: (evt: any, targetProps: any) => {
|
|
24
|
-
target: string;
|
|
25
|
-
eventKey: string;
|
|
26
|
-
mutation: () => {
|
|
27
|
-
cursorValue: null;
|
|
28
|
-
};
|
|
29
|
-
}[];
|
|
30
|
-
}
|
|
31
|
-
export declare const CursorHelpers: CursorHelpersClass;
|
|
32
|
-
export {};
|
|
1
|
+
/// <reference types="lodash" />
|
|
2
|
+
import { Selection } from "victory-core";
|
|
3
|
+
declare class CursorHelpersClass {
|
|
4
|
+
getDimension(props: any): any;
|
|
5
|
+
withinBounds(point: any, bounds: any): boolean;
|
|
6
|
+
private handleMouseMove;
|
|
7
|
+
onMouseMove: import("lodash").DebouncedFunc<(evt: any, targetProps: any) => {
|
|
8
|
+
target: string;
|
|
9
|
+
eventKey: string;
|
|
10
|
+
mutation: () => {
|
|
11
|
+
cursorValue: Selection.SVGCoordinateType | null;
|
|
12
|
+
parentSVG: any;
|
|
13
|
+
};
|
|
14
|
+
}[]>;
|
|
15
|
+
onMouseLeave: (evt: any, targetProps: any) => {
|
|
16
|
+
target: string;
|
|
17
|
+
eventKey: string;
|
|
18
|
+
mutation: () => {
|
|
19
|
+
cursorValue: Selection.SVGCoordinateType | null;
|
|
20
|
+
parentSVG: any;
|
|
21
|
+
};
|
|
22
|
+
}[];
|
|
23
|
+
onTouchEnd: (evt: any, targetProps: any) => {
|
|
24
|
+
target: string;
|
|
25
|
+
eventKey: string;
|
|
26
|
+
mutation: () => {
|
|
27
|
+
cursorValue: null;
|
|
28
|
+
};
|
|
29
|
+
}[];
|
|
30
|
+
}
|
|
31
|
+
export declare const CursorHelpers: CursorHelpersClass;
|
|
32
|
+
export {};
|
|
33
33
|
//# sourceMappingURL=cursor-helpers.d.ts.map
|
package/es/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "./cursor-helpers";
|
|
2
|
-
export * from "./victory-cursor-container";
|
|
1
|
+
export * from "./cursor-helpers";
|
|
2
|
+
export * from "./victory-cursor-container";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,134 +1,134 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { VictoryContainer, VictoryContainerProps, CoordinatesPropType, VictoryLabelProps, ValueOrAccessor } from "victory-core";
|
|
3
|
-
export declare type CursorCoordinatesPropType = CoordinatesPropType | number;
|
|
4
|
-
export interface VictoryCursorContainerProps extends VictoryContainerProps {
|
|
5
|
-
cursorComponent?: React.ReactElement;
|
|
6
|
-
cursorDimension?: "x" | "y";
|
|
7
|
-
cursorLabel?: ValueOrAccessor<VictoryLabelProps["text"]>;
|
|
8
|
-
cursorLabelComponent?: React.ReactElement;
|
|
9
|
-
cursorLabelOffset?: CursorCoordinatesPropType;
|
|
10
|
-
defaultCursorValue?: CursorCoordinatesPropType;
|
|
11
|
-
disable?: boolean;
|
|
12
|
-
onCursorChange?: (value: CursorCoordinatesPropType, props: VictoryCursorContainerProps) => void;
|
|
13
|
-
}
|
|
14
|
-
declare type ComponentClass<TProps> = {
|
|
15
|
-
new (props: TProps): React.Component<TProps>;
|
|
16
|
-
};
|
|
17
|
-
export declare function cursorContainerMixin<TBase extends ComponentClass<TProps>, TProps extends VictoryCursorContainerProps>(Base: TBase): {
|
|
18
|
-
new (props: TProps): {
|
|
19
|
-
getCursorPosition(props: any): any;
|
|
20
|
-
getCursorLabelOffset(props: any): any;
|
|
21
|
-
getPadding(props: any): {
|
|
22
|
-
top: any;
|
|
23
|
-
bottom: any;
|
|
24
|
-
left: any;
|
|
25
|
-
right: any;
|
|
26
|
-
};
|
|
27
|
-
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
28
|
-
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
29
|
-
context: unknown;
|
|
30
|
-
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<TProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
31
|
-
forceUpdate(callback?: (() => void) | undefined): void;
|
|
32
|
-
render(): React.ReactNode;
|
|
33
|
-
readonly props: Readonly<TProps>;
|
|
34
|
-
state: Readonly<{}>;
|
|
35
|
-
refs: {
|
|
36
|
-
[key: string]: React.ReactInstance;
|
|
37
|
-
};
|
|
38
|
-
componentDidMount?(): void;
|
|
39
|
-
shouldComponentUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
40
|
-
componentWillUnmount?(): void;
|
|
41
|
-
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
42
|
-
getSnapshotBeforeUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>): any;
|
|
43
|
-
componentDidUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
44
|
-
componentWillMount?(): void;
|
|
45
|
-
UNSAFE_componentWillMount?(): void;
|
|
46
|
-
componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
47
|
-
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
48
|
-
componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
49
|
-
UNSAFE_componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
50
|
-
};
|
|
51
|
-
displayName: string;
|
|
52
|
-
defaultProps: {
|
|
53
|
-
cursorLabelComponent: JSX.Element;
|
|
54
|
-
cursorLabelOffset: {
|
|
55
|
-
x: number;
|
|
56
|
-
y: number;
|
|
57
|
-
};
|
|
58
|
-
cursorComponent: JSX.Element;
|
|
59
|
-
className: string;
|
|
60
|
-
portalComponent: JSX.Element;
|
|
61
|
-
portalZIndex: number;
|
|
62
|
-
responsive: boolean;
|
|
63
|
-
role: string;
|
|
64
|
-
};
|
|
65
|
-
defaultEvents
|
|
66
|
-
target: string;
|
|
67
|
-
eventHandlers: {
|
|
68
|
-
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
69
|
-
onTouchCancel: () => never[];
|
|
70
|
-
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
71
|
-
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
72
|
-
};
|
|
73
|
-
}[];
|
|
74
|
-
} & TBase;
|
|
75
|
-
export declare const VictoryCursorContainer: {
|
|
76
|
-
new (props: VictoryCursorContainerProps): {
|
|
77
|
-
getCursorPosition(props: any): any;
|
|
78
|
-
getCursorLabelOffset(props: any): any;
|
|
79
|
-
getPadding(props: any): {
|
|
80
|
-
top: any;
|
|
81
|
-
bottom: any;
|
|
82
|
-
left: any;
|
|
83
|
-
right: any;
|
|
84
|
-
};
|
|
85
|
-
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
86
|
-
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
87
|
-
context: unknown;
|
|
88
|
-
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<VictoryCursorContainerProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
89
|
-
forceUpdate(callback?: (() => void) | undefined): void;
|
|
90
|
-
render(): React.ReactNode;
|
|
91
|
-
readonly props: Readonly<VictoryCursorContainerProps>;
|
|
92
|
-
state: Readonly<{}>;
|
|
93
|
-
refs: {
|
|
94
|
-
[key: string]: React.ReactInstance;
|
|
95
|
-
};
|
|
96
|
-
componentDidMount?(): void;
|
|
97
|
-
shouldComponentUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
98
|
-
componentWillUnmount?(): void;
|
|
99
|
-
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
100
|
-
getSnapshotBeforeUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>): any;
|
|
101
|
-
componentDidUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
102
|
-
componentWillMount?(): void;
|
|
103
|
-
UNSAFE_componentWillMount?(): void;
|
|
104
|
-
componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
105
|
-
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
106
|
-
componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
107
|
-
UNSAFE_componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
108
|
-
};
|
|
109
|
-
displayName: string;
|
|
110
|
-
defaultProps: {
|
|
111
|
-
cursorLabelComponent: JSX.Element;
|
|
112
|
-
cursorLabelOffset: {
|
|
113
|
-
x: number;
|
|
114
|
-
y: number;
|
|
115
|
-
};
|
|
116
|
-
cursorComponent: JSX.Element;
|
|
117
|
-
className: string;
|
|
118
|
-
portalComponent: JSX.Element;
|
|
119
|
-
portalZIndex: number;
|
|
120
|
-
responsive: boolean;
|
|
121
|
-
role: string;
|
|
122
|
-
};
|
|
123
|
-
defaultEvents
|
|
124
|
-
target: string;
|
|
125
|
-
eventHandlers: {
|
|
126
|
-
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
127
|
-
onTouchCancel: () => never[];
|
|
128
|
-
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
129
|
-
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
130
|
-
};
|
|
131
|
-
}[];
|
|
132
|
-
} & typeof VictoryContainer;
|
|
133
|
-
export {};
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { VictoryContainer, VictoryContainerProps, CoordinatesPropType, VictoryLabelProps, ValueOrAccessor } from "victory-core";
|
|
3
|
+
export declare type CursorCoordinatesPropType = CoordinatesPropType | number;
|
|
4
|
+
export interface VictoryCursorContainerProps extends VictoryContainerProps {
|
|
5
|
+
cursorComponent?: React.ReactElement;
|
|
6
|
+
cursorDimension?: "x" | "y";
|
|
7
|
+
cursorLabel?: ValueOrAccessor<VictoryLabelProps["text"]>;
|
|
8
|
+
cursorLabelComponent?: React.ReactElement;
|
|
9
|
+
cursorLabelOffset?: CursorCoordinatesPropType;
|
|
10
|
+
defaultCursorValue?: CursorCoordinatesPropType;
|
|
11
|
+
disable?: boolean;
|
|
12
|
+
onCursorChange?: (value: CursorCoordinatesPropType, props: VictoryCursorContainerProps) => void;
|
|
13
|
+
}
|
|
14
|
+
declare type ComponentClass<TProps> = {
|
|
15
|
+
new (props: TProps): React.Component<TProps>;
|
|
16
|
+
};
|
|
17
|
+
export declare function cursorContainerMixin<TBase extends ComponentClass<TProps>, TProps extends VictoryCursorContainerProps>(Base: TBase): {
|
|
18
|
+
new (props: TProps): {
|
|
19
|
+
getCursorPosition(props: any): any;
|
|
20
|
+
getCursorLabelOffset(props: any): any;
|
|
21
|
+
getPadding(props: any): {
|
|
22
|
+
top: any;
|
|
23
|
+
bottom: any;
|
|
24
|
+
left: any;
|
|
25
|
+
right: any;
|
|
26
|
+
};
|
|
27
|
+
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
28
|
+
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
29
|
+
context: unknown;
|
|
30
|
+
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<TProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
31
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
32
|
+
render(): React.ReactNode;
|
|
33
|
+
readonly props: Readonly<TProps>;
|
|
34
|
+
state: Readonly<{}>;
|
|
35
|
+
refs: {
|
|
36
|
+
[key: string]: React.ReactInstance;
|
|
37
|
+
};
|
|
38
|
+
componentDidMount?(): void;
|
|
39
|
+
shouldComponentUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
40
|
+
componentWillUnmount?(): void;
|
|
41
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
42
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>): any;
|
|
43
|
+
componentDidUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
44
|
+
componentWillMount?(): void;
|
|
45
|
+
UNSAFE_componentWillMount?(): void;
|
|
46
|
+
componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
47
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
48
|
+
componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
49
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
50
|
+
};
|
|
51
|
+
displayName: string;
|
|
52
|
+
defaultProps: {
|
|
53
|
+
cursorLabelComponent: JSX.Element;
|
|
54
|
+
cursorLabelOffset: {
|
|
55
|
+
x: number;
|
|
56
|
+
y: number;
|
|
57
|
+
};
|
|
58
|
+
cursorComponent: JSX.Element;
|
|
59
|
+
className: string;
|
|
60
|
+
portalComponent: JSX.Element;
|
|
61
|
+
portalZIndex: number;
|
|
62
|
+
responsive: boolean;
|
|
63
|
+
role: string;
|
|
64
|
+
};
|
|
65
|
+
defaultEvents(props: any): {
|
|
66
|
+
target: string;
|
|
67
|
+
eventHandlers: {
|
|
68
|
+
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
69
|
+
onTouchCancel: () => never[];
|
|
70
|
+
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
71
|
+
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
72
|
+
};
|
|
73
|
+
}[];
|
|
74
|
+
} & TBase;
|
|
75
|
+
export declare const VictoryCursorContainer: {
|
|
76
|
+
new (props: VictoryCursorContainerProps): {
|
|
77
|
+
getCursorPosition(props: any): any;
|
|
78
|
+
getCursorLabelOffset(props: any): any;
|
|
79
|
+
getPadding(props: any): {
|
|
80
|
+
top: any;
|
|
81
|
+
bottom: any;
|
|
82
|
+
left: any;
|
|
83
|
+
right: any;
|
|
84
|
+
};
|
|
85
|
+
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
86
|
+
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
87
|
+
context: unknown;
|
|
88
|
+
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<VictoryCursorContainerProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
89
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
90
|
+
render(): React.ReactNode;
|
|
91
|
+
readonly props: Readonly<VictoryCursorContainerProps>;
|
|
92
|
+
state: Readonly<{}>;
|
|
93
|
+
refs: {
|
|
94
|
+
[key: string]: React.ReactInstance;
|
|
95
|
+
};
|
|
96
|
+
componentDidMount?(): void;
|
|
97
|
+
shouldComponentUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
98
|
+
componentWillUnmount?(): void;
|
|
99
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
100
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>): any;
|
|
101
|
+
componentDidUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
102
|
+
componentWillMount?(): void;
|
|
103
|
+
UNSAFE_componentWillMount?(): void;
|
|
104
|
+
componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
105
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
106
|
+
componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
107
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
108
|
+
};
|
|
109
|
+
displayName: string;
|
|
110
|
+
defaultProps: {
|
|
111
|
+
cursorLabelComponent: JSX.Element;
|
|
112
|
+
cursorLabelOffset: {
|
|
113
|
+
x: number;
|
|
114
|
+
y: number;
|
|
115
|
+
};
|
|
116
|
+
cursorComponent: JSX.Element;
|
|
117
|
+
className: string;
|
|
118
|
+
portalComponent: JSX.Element;
|
|
119
|
+
portalZIndex: number;
|
|
120
|
+
responsive: boolean;
|
|
121
|
+
role: string;
|
|
122
|
+
};
|
|
123
|
+
defaultEvents(props: any): {
|
|
124
|
+
target: string;
|
|
125
|
+
eventHandlers: {
|
|
126
|
+
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
127
|
+
onTouchCancel: () => never[];
|
|
128
|
+
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
129
|
+
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
130
|
+
};
|
|
131
|
+
}[];
|
|
132
|
+
} & typeof VictoryContainer;
|
|
133
|
+
export {};
|
|
134
134
|
//# sourceMappingURL=victory-cursor-container.d.ts.map
|
|
@@ -16,7 +16,7 @@ export function cursorContainerMixin(Base) {
|
|
|
16
16
|
},
|
|
17
17
|
cursorComponent: /*#__PURE__*/React.createElement(LineSegment, null)
|
|
18
18
|
};
|
|
19
|
-
static defaultEvents
|
|
19
|
+
static defaultEvents(props) {
|
|
20
20
|
return [{
|
|
21
21
|
target: "parent",
|
|
22
22
|
eventHandlers: {
|
|
@@ -34,7 +34,7 @@ export function cursorContainerMixin(Base) {
|
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
}];
|
|
37
|
-
}
|
|
37
|
+
}
|
|
38
38
|
getCursorPosition(props) {
|
|
39
39
|
const {
|
|
40
40
|
cursorValue,
|
package/lib/cursor-helpers.d.ts
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
/// <reference types="lodash" />
|
|
2
|
-
import { Selection } from "victory-core";
|
|
3
|
-
declare class CursorHelpersClass {
|
|
4
|
-
getDimension(props: any): any;
|
|
5
|
-
withinBounds(point: any, bounds: any): boolean;
|
|
6
|
-
private handleMouseMove;
|
|
7
|
-
onMouseMove: import("lodash").DebouncedFunc<(evt: any, targetProps: any) => {
|
|
8
|
-
target: string;
|
|
9
|
-
eventKey: string;
|
|
10
|
-
mutation: () => {
|
|
11
|
-
cursorValue: Selection.SVGCoordinateType | null;
|
|
12
|
-
parentSVG: any;
|
|
13
|
-
};
|
|
14
|
-
}[]>;
|
|
15
|
-
onMouseLeave: (evt: any, targetProps: any) => {
|
|
16
|
-
target: string;
|
|
17
|
-
eventKey: string;
|
|
18
|
-
mutation: () => {
|
|
19
|
-
cursorValue: Selection.SVGCoordinateType | null;
|
|
20
|
-
parentSVG: any;
|
|
21
|
-
};
|
|
22
|
-
}[];
|
|
23
|
-
onTouchEnd: (evt: any, targetProps: any) => {
|
|
24
|
-
target: string;
|
|
25
|
-
eventKey: string;
|
|
26
|
-
mutation: () => {
|
|
27
|
-
cursorValue: null;
|
|
28
|
-
};
|
|
29
|
-
}[];
|
|
30
|
-
}
|
|
31
|
-
export declare const CursorHelpers: CursorHelpersClass;
|
|
32
|
-
export {};
|
|
1
|
+
/// <reference types="lodash" />
|
|
2
|
+
import { Selection } from "victory-core";
|
|
3
|
+
declare class CursorHelpersClass {
|
|
4
|
+
getDimension(props: any): any;
|
|
5
|
+
withinBounds(point: any, bounds: any): boolean;
|
|
6
|
+
private handleMouseMove;
|
|
7
|
+
onMouseMove: import("lodash").DebouncedFunc<(evt: any, targetProps: any) => {
|
|
8
|
+
target: string;
|
|
9
|
+
eventKey: string;
|
|
10
|
+
mutation: () => {
|
|
11
|
+
cursorValue: Selection.SVGCoordinateType | null;
|
|
12
|
+
parentSVG: any;
|
|
13
|
+
};
|
|
14
|
+
}[]>;
|
|
15
|
+
onMouseLeave: (evt: any, targetProps: any) => {
|
|
16
|
+
target: string;
|
|
17
|
+
eventKey: string;
|
|
18
|
+
mutation: () => {
|
|
19
|
+
cursorValue: Selection.SVGCoordinateType | null;
|
|
20
|
+
parentSVG: any;
|
|
21
|
+
};
|
|
22
|
+
}[];
|
|
23
|
+
onTouchEnd: (evt: any, targetProps: any) => {
|
|
24
|
+
target: string;
|
|
25
|
+
eventKey: string;
|
|
26
|
+
mutation: () => {
|
|
27
|
+
cursorValue: null;
|
|
28
|
+
};
|
|
29
|
+
}[];
|
|
30
|
+
}
|
|
31
|
+
export declare const CursorHelpers: CursorHelpersClass;
|
|
32
|
+
export {};
|
|
33
33
|
//# sourceMappingURL=cursor-helpers.d.ts.map
|
package/lib/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "./cursor-helpers";
|
|
2
|
-
export * from "./victory-cursor-container";
|
|
1
|
+
export * from "./cursor-helpers";
|
|
2
|
+
export * from "./victory-cursor-container";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,134 +1,134 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { VictoryContainer, VictoryContainerProps, CoordinatesPropType, VictoryLabelProps, ValueOrAccessor } from "victory-core";
|
|
3
|
-
export declare type CursorCoordinatesPropType = CoordinatesPropType | number;
|
|
4
|
-
export interface VictoryCursorContainerProps extends VictoryContainerProps {
|
|
5
|
-
cursorComponent?: React.ReactElement;
|
|
6
|
-
cursorDimension?: "x" | "y";
|
|
7
|
-
cursorLabel?: ValueOrAccessor<VictoryLabelProps["text"]>;
|
|
8
|
-
cursorLabelComponent?: React.ReactElement;
|
|
9
|
-
cursorLabelOffset?: CursorCoordinatesPropType;
|
|
10
|
-
defaultCursorValue?: CursorCoordinatesPropType;
|
|
11
|
-
disable?: boolean;
|
|
12
|
-
onCursorChange?: (value: CursorCoordinatesPropType, props: VictoryCursorContainerProps) => void;
|
|
13
|
-
}
|
|
14
|
-
declare type ComponentClass<TProps> = {
|
|
15
|
-
new (props: TProps): React.Component<TProps>;
|
|
16
|
-
};
|
|
17
|
-
export declare function cursorContainerMixin<TBase extends ComponentClass<TProps>, TProps extends VictoryCursorContainerProps>(Base: TBase): {
|
|
18
|
-
new (props: TProps): {
|
|
19
|
-
getCursorPosition(props: any): any;
|
|
20
|
-
getCursorLabelOffset(props: any): any;
|
|
21
|
-
getPadding(props: any): {
|
|
22
|
-
top: any;
|
|
23
|
-
bottom: any;
|
|
24
|
-
left: any;
|
|
25
|
-
right: any;
|
|
26
|
-
};
|
|
27
|
-
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
28
|
-
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
29
|
-
context: unknown;
|
|
30
|
-
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<TProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
31
|
-
forceUpdate(callback?: (() => void) | undefined): void;
|
|
32
|
-
render(): React.ReactNode;
|
|
33
|
-
readonly props: Readonly<TProps>;
|
|
34
|
-
state: Readonly<{}>;
|
|
35
|
-
refs: {
|
|
36
|
-
[key: string]: React.ReactInstance;
|
|
37
|
-
};
|
|
38
|
-
componentDidMount?(): void;
|
|
39
|
-
shouldComponentUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
40
|
-
componentWillUnmount?(): void;
|
|
41
|
-
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
42
|
-
getSnapshotBeforeUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>): any;
|
|
43
|
-
componentDidUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
44
|
-
componentWillMount?(): void;
|
|
45
|
-
UNSAFE_componentWillMount?(): void;
|
|
46
|
-
componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
47
|
-
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
48
|
-
componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
49
|
-
UNSAFE_componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
50
|
-
};
|
|
51
|
-
displayName: string;
|
|
52
|
-
defaultProps: {
|
|
53
|
-
cursorLabelComponent: JSX.Element;
|
|
54
|
-
cursorLabelOffset: {
|
|
55
|
-
x: number;
|
|
56
|
-
y: number;
|
|
57
|
-
};
|
|
58
|
-
cursorComponent: JSX.Element;
|
|
59
|
-
className: string;
|
|
60
|
-
portalComponent: JSX.Element;
|
|
61
|
-
portalZIndex: number;
|
|
62
|
-
responsive: boolean;
|
|
63
|
-
role: string;
|
|
64
|
-
};
|
|
65
|
-
defaultEvents
|
|
66
|
-
target: string;
|
|
67
|
-
eventHandlers: {
|
|
68
|
-
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
69
|
-
onTouchCancel: () => never[];
|
|
70
|
-
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
71
|
-
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
72
|
-
};
|
|
73
|
-
}[];
|
|
74
|
-
} & TBase;
|
|
75
|
-
export declare const VictoryCursorContainer: {
|
|
76
|
-
new (props: VictoryCursorContainerProps): {
|
|
77
|
-
getCursorPosition(props: any): any;
|
|
78
|
-
getCursorLabelOffset(props: any): any;
|
|
79
|
-
getPadding(props: any): {
|
|
80
|
-
top: any;
|
|
81
|
-
bottom: any;
|
|
82
|
-
left: any;
|
|
83
|
-
right: any;
|
|
84
|
-
};
|
|
85
|
-
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
86
|
-
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
87
|
-
context: unknown;
|
|
88
|
-
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<VictoryCursorContainerProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
89
|
-
forceUpdate(callback?: (() => void) | undefined): void;
|
|
90
|
-
render(): React.ReactNode;
|
|
91
|
-
readonly props: Readonly<VictoryCursorContainerProps>;
|
|
92
|
-
state: Readonly<{}>;
|
|
93
|
-
refs: {
|
|
94
|
-
[key: string]: React.ReactInstance;
|
|
95
|
-
};
|
|
96
|
-
componentDidMount?(): void;
|
|
97
|
-
shouldComponentUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
98
|
-
componentWillUnmount?(): void;
|
|
99
|
-
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
100
|
-
getSnapshotBeforeUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>): any;
|
|
101
|
-
componentDidUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
102
|
-
componentWillMount?(): void;
|
|
103
|
-
UNSAFE_componentWillMount?(): void;
|
|
104
|
-
componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
105
|
-
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
106
|
-
componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
107
|
-
UNSAFE_componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
108
|
-
};
|
|
109
|
-
displayName: string;
|
|
110
|
-
defaultProps: {
|
|
111
|
-
cursorLabelComponent: JSX.Element;
|
|
112
|
-
cursorLabelOffset: {
|
|
113
|
-
x: number;
|
|
114
|
-
y: number;
|
|
115
|
-
};
|
|
116
|
-
cursorComponent: JSX.Element;
|
|
117
|
-
className: string;
|
|
118
|
-
portalComponent: JSX.Element;
|
|
119
|
-
portalZIndex: number;
|
|
120
|
-
responsive: boolean;
|
|
121
|
-
role: string;
|
|
122
|
-
};
|
|
123
|
-
defaultEvents
|
|
124
|
-
target: string;
|
|
125
|
-
eventHandlers: {
|
|
126
|
-
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
127
|
-
onTouchCancel: () => never[];
|
|
128
|
-
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
129
|
-
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
130
|
-
};
|
|
131
|
-
}[];
|
|
132
|
-
} & typeof VictoryContainer;
|
|
133
|
-
export {};
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { VictoryContainer, VictoryContainerProps, CoordinatesPropType, VictoryLabelProps, ValueOrAccessor } from "victory-core";
|
|
3
|
+
export declare type CursorCoordinatesPropType = CoordinatesPropType | number;
|
|
4
|
+
export interface VictoryCursorContainerProps extends VictoryContainerProps {
|
|
5
|
+
cursorComponent?: React.ReactElement;
|
|
6
|
+
cursorDimension?: "x" | "y";
|
|
7
|
+
cursorLabel?: ValueOrAccessor<VictoryLabelProps["text"]>;
|
|
8
|
+
cursorLabelComponent?: React.ReactElement;
|
|
9
|
+
cursorLabelOffset?: CursorCoordinatesPropType;
|
|
10
|
+
defaultCursorValue?: CursorCoordinatesPropType;
|
|
11
|
+
disable?: boolean;
|
|
12
|
+
onCursorChange?: (value: CursorCoordinatesPropType, props: VictoryCursorContainerProps) => void;
|
|
13
|
+
}
|
|
14
|
+
declare type ComponentClass<TProps> = {
|
|
15
|
+
new (props: TProps): React.Component<TProps>;
|
|
16
|
+
};
|
|
17
|
+
export declare function cursorContainerMixin<TBase extends ComponentClass<TProps>, TProps extends VictoryCursorContainerProps>(Base: TBase): {
|
|
18
|
+
new (props: TProps): {
|
|
19
|
+
getCursorPosition(props: any): any;
|
|
20
|
+
getCursorLabelOffset(props: any): any;
|
|
21
|
+
getPadding(props: any): {
|
|
22
|
+
top: any;
|
|
23
|
+
bottom: any;
|
|
24
|
+
left: any;
|
|
25
|
+
right: any;
|
|
26
|
+
};
|
|
27
|
+
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
28
|
+
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
29
|
+
context: unknown;
|
|
30
|
+
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<TProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
31
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
32
|
+
render(): React.ReactNode;
|
|
33
|
+
readonly props: Readonly<TProps>;
|
|
34
|
+
state: Readonly<{}>;
|
|
35
|
+
refs: {
|
|
36
|
+
[key: string]: React.ReactInstance;
|
|
37
|
+
};
|
|
38
|
+
componentDidMount?(): void;
|
|
39
|
+
shouldComponentUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
40
|
+
componentWillUnmount?(): void;
|
|
41
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
42
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>): any;
|
|
43
|
+
componentDidUpdate?(prevProps: Readonly<TProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
44
|
+
componentWillMount?(): void;
|
|
45
|
+
UNSAFE_componentWillMount?(): void;
|
|
46
|
+
componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
47
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<TProps>, nextContext: any): void;
|
|
48
|
+
componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
49
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<TProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
50
|
+
};
|
|
51
|
+
displayName: string;
|
|
52
|
+
defaultProps: {
|
|
53
|
+
cursorLabelComponent: JSX.Element;
|
|
54
|
+
cursorLabelOffset: {
|
|
55
|
+
x: number;
|
|
56
|
+
y: number;
|
|
57
|
+
};
|
|
58
|
+
cursorComponent: JSX.Element;
|
|
59
|
+
className: string;
|
|
60
|
+
portalComponent: JSX.Element;
|
|
61
|
+
portalZIndex: number;
|
|
62
|
+
responsive: boolean;
|
|
63
|
+
role: string;
|
|
64
|
+
};
|
|
65
|
+
defaultEvents(props: any): {
|
|
66
|
+
target: string;
|
|
67
|
+
eventHandlers: {
|
|
68
|
+
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
69
|
+
onTouchCancel: () => never[];
|
|
70
|
+
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
71
|
+
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
72
|
+
};
|
|
73
|
+
}[];
|
|
74
|
+
} & TBase;
|
|
75
|
+
export declare const VictoryCursorContainer: {
|
|
76
|
+
new (props: VictoryCursorContainerProps): {
|
|
77
|
+
getCursorPosition(props: any): any;
|
|
78
|
+
getCursorLabelOffset(props: any): any;
|
|
79
|
+
getPadding(props: any): {
|
|
80
|
+
top: any;
|
|
81
|
+
bottom: any;
|
|
82
|
+
left: any;
|
|
83
|
+
right: any;
|
|
84
|
+
};
|
|
85
|
+
getCursorElements(props: any): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
86
|
+
getChildren(props: any): (string | number | React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactFragment)[];
|
|
87
|
+
context: unknown;
|
|
88
|
+
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<VictoryCursorContainerProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
89
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
90
|
+
render(): React.ReactNode;
|
|
91
|
+
readonly props: Readonly<VictoryCursorContainerProps>;
|
|
92
|
+
state: Readonly<{}>;
|
|
93
|
+
refs: {
|
|
94
|
+
[key: string]: React.ReactInstance;
|
|
95
|
+
};
|
|
96
|
+
componentDidMount?(): void;
|
|
97
|
+
shouldComponentUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
98
|
+
componentWillUnmount?(): void;
|
|
99
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
100
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>): any;
|
|
101
|
+
componentDidUpdate?(prevProps: Readonly<VictoryCursorContainerProps>, prevState: Readonly<{}>, snapshot?: any): void;
|
|
102
|
+
componentWillMount?(): void;
|
|
103
|
+
UNSAFE_componentWillMount?(): void;
|
|
104
|
+
componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
105
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<VictoryCursorContainerProps>, nextContext: any): void;
|
|
106
|
+
componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
107
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<VictoryCursorContainerProps>, nextState: Readonly<{}>, nextContext: any): void;
|
|
108
|
+
};
|
|
109
|
+
displayName: string;
|
|
110
|
+
defaultProps: {
|
|
111
|
+
cursorLabelComponent: JSX.Element;
|
|
112
|
+
cursorLabelOffset: {
|
|
113
|
+
x: number;
|
|
114
|
+
y: number;
|
|
115
|
+
};
|
|
116
|
+
cursorComponent: JSX.Element;
|
|
117
|
+
className: string;
|
|
118
|
+
portalComponent: JSX.Element;
|
|
119
|
+
portalZIndex: number;
|
|
120
|
+
responsive: boolean;
|
|
121
|
+
role: string;
|
|
122
|
+
};
|
|
123
|
+
defaultEvents(props: any): {
|
|
124
|
+
target: string;
|
|
125
|
+
eventHandlers: {
|
|
126
|
+
onMouseLeave: (evt: any, targetProps: any) => {};
|
|
127
|
+
onTouchCancel: () => never[];
|
|
128
|
+
onMouseMove: (evt: any, targetProps: any) => {} | undefined;
|
|
129
|
+
onTouchMove: (evt: any, targetProps: any) => {} | undefined;
|
|
130
|
+
};
|
|
131
|
+
}[];
|
|
132
|
+
} & typeof VictoryContainer;
|
|
133
|
+
export {};
|
|
134
134
|
//# sourceMappingURL=victory-cursor-container.d.ts.map
|
|
@@ -24,7 +24,7 @@ function cursorContainerMixin(Base) {
|
|
|
24
24
|
},
|
|
25
25
|
cursorComponent: /*#__PURE__*/_react.default.createElement(_victoryCore.LineSegment, null)
|
|
26
26
|
};
|
|
27
|
-
static defaultEvents
|
|
27
|
+
static defaultEvents(props) {
|
|
28
28
|
return [{
|
|
29
29
|
target: "parent",
|
|
30
30
|
eventHandlers: {
|
|
@@ -42,7 +42,7 @@ function cursorContainerMixin(Base) {
|
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
}];
|
|
45
|
-
}
|
|
45
|
+
}
|
|
46
46
|
getCursorPosition(props) {
|
|
47
47
|
const {
|
|
48
48
|
cursorValue,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "victory-cursor-container",
|
|
3
|
-
"version": "37.0.
|
|
3
|
+
"version": "37.0.1-next.1",
|
|
4
4
|
"description": "Interactive Cursor Component for Victory",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"data visualization",
|
|
@@ -21,14 +21,11 @@
|
|
|
21
21
|
"license": "MIT",
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"lodash": "^4.17.19",
|
|
24
|
-
"victory-core": "^37.0.
|
|
24
|
+
"victory-core": "^37.0.1-next.1"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
27
|
"react": ">=16.6.0"
|
|
28
28
|
},
|
|
29
|
-
"publishConfig": {
|
|
30
|
-
"provenance": true
|
|
31
|
-
},
|
|
32
29
|
"wireit": {
|
|
33
30
|
"### THESE WIREIT CONFIGS ARE GENERATED ####": {},
|
|
34
31
|
"### DO NOT MODIFY THESE MANUALLY ####": {},
|
|
@@ -46,7 +46,7 @@ export function cursorContainerMixin<
|
|
|
46
46
|
},
|
|
47
47
|
cursorComponent: <LineSegment />,
|
|
48
48
|
};
|
|
49
|
-
static defaultEvents
|
|
49
|
+
static defaultEvents(props) {
|
|
50
50
|
return [
|
|
51
51
|
{
|
|
52
52
|
target: "parent",
|
|
@@ -72,7 +72,7 @@ export function cursorContainerMixin<
|
|
|
72
72
|
},
|
|
73
73
|
},
|
|
74
74
|
];
|
|
75
|
-
}
|
|
75
|
+
}
|
|
76
76
|
|
|
77
77
|
getCursorPosition(props) {
|
|
78
78
|
const { cursorValue, defaultCursorValue, domain, cursorDimension } =
|