Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@vx/shape

Package Overview
Dependencies
Maintainers
1
Versions
93
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vx/shape - npm Package Compare versions

Comparing version 0.0.170 to 0.0.171

4

build/shapes/Pie.js

@@ -61,4 +61,4 @@ 'use strict';

var pie = (0, _d3Shape.pie)();
if (pieSort) pie.sort(pieSort);
if (pieSortValues) pie.sortValues(pieSortValues);
if (pieSort !== undefined) pie.sort(pieSort);
if (pieSortValues !== undefined) pie.sortValues(pieSortValues);
if (pieValue) pie.value(pieValue);

@@ -65,0 +65,0 @@ if (padAngle != null) pie.padAngle(padAngle);

@@ -105,4 +105,4 @@ import React from 'react';

var pie$$1 = pie();
if (pieSort) pie$$1.sort(pieSort);
if (pieSortValues) pie$$1.sortValues(pieSortValues);
if (pieSort !== undefined) pie$$1.sort(pieSort);
if (pieSortValues !== undefined) pie$$1.sortValues(pieSortValues);
if (pieValue) pie$$1.value(pieValue);

@@ -109,0 +109,0 @@ if (padAngle != null) pie$$1.padAngle(padAngle);

@@ -1,1 +0,1 @@

!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports,require("react"),require("classnames"),require("d3-shape"),require("@vx/group"),require("prop-types"),require("@vx/point"),require("@vx/curve"),require("d3-path")):"function"==typeof define&&define.amd?define(["exports","react","classnames","d3-shape","@vx/group","prop-types","@vx/point","@vx/curve","d3-path"],r):r(e.vx=e.vx||{},e.React,e.classNames,e.d3,e.vx,e.PropTypes,e.vx,e.vx,e.d3)}(this,function(e,O,q,z,A,r,m,T,R){"use strict";function n(e,r){return"function"==typeof e?e(r):e}function L(t,a){return Object.keys(t).reduce(function(e,r){return e[r]=n(t[r],a),e},{})}O=O&&O.hasOwnProperty("default")?O.default:O,q=q&&q.hasOwnProperty("default")?q.default:q,r=r&&r.hasOwnProperty("default")?r.default:r;var D=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a])}return e},M=function(e,r){var t={};for(var a in e)0<=r.indexOf(a)||Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t};function t(e){var r=e.from,t=void 0===r?new m.Point({x:0,y:0}):r,a=e.to,n=void 0===a?new m.Point({x:1,y:1}):a,i=e.stroke,c=void 0===i?"black":i,u=e.strokeWidth,o=void 0===u?1:u,s=e.strokeDasharray,d=void 0===s?"":s,l=e.transform,f=void 0===l?"":l,p=e.className,y=void 0===p?"":p,v=e.data,h=e.innerRef,x=M(e,["from","to","stroke","strokeWidth","strokeDasharray","transform","className","data","innerRef"]);return O.createElement("line",D({ref:h,className:q("vx-line",y),x1:t.x,y1:t.y,x2:n.x,y2:n.y,stroke:c,strokeWidth:o,strokeDasharray:d,transform:f},L(x,v)))}function a(e){var r=e.children,t=e.data,a=e.xScale,n=e.yScale,i=e.x,c=e.y,u=e.defined,o=void 0===u?function(){return!0}:u,s=e.className,d=e.stroke,l=void 0===d?"steelblue":d,f=e.strokeWidth,p=void 0===f?2:f,y=e.strokeDasharray,v=void 0===y?"":y,h=e.strokeDashoffset,x=void 0===h?0:h,m=e.fill,g=void 0===m?"none":m,k=e.curve,R=void 0===k?T.curveLinear:k,N=e.glyph,S=e.innerRef,b=M(e,["children","data","xScale","yScale","x","y","defined","className","stroke","strokeWidth","strokeDasharray","strokeDashoffset","fill","curve","glyph","innerRef"]),E=z.line().x(function(){return a(i.apply(void 0,arguments))}).y(function(){return n(c.apply(void 0,arguments))}).defined(o).curve(R);return r?r({path:E}):O.createElement("g",null,O.createElement("path",D({ref:S,className:q("vx-linepath",s),d:E(t),stroke:l,strokeWidth:p,strokeDasharray:v,strokeDashoffset:x,fill:g},L(b,t))),N&&O.createElement("g",{className:"vx-linepath-glyphs"},t.map(N)))}function i(e){var r=e.className,t=void 0===r?"":r,a=e.angle,n=e.radius,i=e.defined,c=e.curve,u=e.data,o=e.innerRef,s=M(e,["className","angle","radius","defined","curve","data","innerRef"]),d=z.radialLine();return a&&d.angle(a),n&&d.radius(n),i&&d.defined(i),c&&d.curve(c),O.createElement("g",null,O.createElement("path",D({ref:o,className:q("vx-line-radial",t),d:d(u)},L(s,u))))}function c(e){var r=e.children,t=e.x,a=e.x0,n=e.x1,i=e.y,c=e.y0,u=e.y1,o=e.xScale,s=e.yScale,d=e.data,l=void 0===d?[]:d,f=e.defined,p=void 0===f?function(){return!0}:f,y=e.className,v=e.strokeDasharray,h=e.strokeWidth,x=void 0===h?2:h,m=e.stroke,g=void 0===m?"black":m,k=e.fill,R=void 0===k?"rgba(0,0,0,0.3)":k,N=e.curve,S=e.innerRef,b=M(e,["children","x","x0","x1","y","y0","y1","xScale","yScale","data","defined","className","strokeDasharray","strokeWidth","stroke","fill","curve","innerRef"]),E=z.area();return t&&E.x(function(){return o(t.apply(void 0,arguments))}),a&&E.x0(function(){return o(a.apply(void 0,arguments))}),n&&E.x1(function(){return o(n.apply(void 0,arguments))}),i&&E.y(function(){return s(i.apply(void 0,arguments))}),c&&E.y0(function(){return s(c.apply(void 0,arguments))}),u&&E.y1(function(){return s(u.apply(void 0,arguments))}),p&&E.defined(p),N&&E.curve(N),r?r({path:E}):O.createElement("g",null,O.createElement("path",D({ref:S,className:q("vx-area",y),d:E(l),stroke:g,strokeWidth:x,strokeDasharray:v,fill:R},L(b,l))))}function u(e){var r=e.x,t=e.y,a=e.y0,n=e.xScale,i=e.yScale,c=e.data,u=e.defined,o=void 0===u?function(){return!0}:u,s=e.className,d=e.strokeDasharray,l=e.strokeWidth,f=void 0===l?2:l,p=e.stroke,y=void 0===p?"black":p,v=e.fill,h=void 0===v?"rgba(0,0,0,0.3)":v,x=e.curve,m=e.innerRef,g=M(e,["x","y","y0","xScale","yScale","data","defined","className","strokeDasharray","strokeWidth","stroke","fill","curve","innerRef"]),k=z.area().x(function(){return n(r.apply(void 0,arguments))}).y0(a||i.range()[0]).y1(function(){return i(t.apply(void 0,arguments))}).defined(o);return x&&k.curve(x),O.createElement("g",null,O.createElement("path",D({ref:m,className:q("vx-area-closed",s),d:k(c),stroke:y,strokeWidth:f,strokeDasharray:d,fill:h},L(g,c))))}function x(e){var r=e.className,t=e.innerRef,a=e.data,n=e.x,i=void 0===n?0:n,c=e.y,u=void 0===c?0:c,o=e.width,s=e.height,d=e.rx,l=e.ry,f=e.fill,p=void 0===f?"steelblue":f,y=e.fillOpacity,v=e.stroke,h=e.strokeWidth,x=e.strokeDasharray,m=e.strokeLinecap,g=e.strokeLinejoin,k=e.strokeMiterlimit,R=e.strokeOpacity,N=M(e,["className","innerRef","data","x","y","width","height","rx","ry","fill","fillOpacity","stroke","strokeWidth","strokeDasharray","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity"]);return O.createElement("rect",D({ref:t,className:q("vx-bar",r),x:i,y:u,width:o,height:s,rx:d,ry:l,fill:p,fillOpacity:y,stroke:v,strokeWidth:h,strokeDasharray:x,strokeLinecap:m,strokeLinejoin:g,strokeMiterlimit:k,strokeOpacity:R},L(N,a)))}function o(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.x0,c=e.x0Scale,u=e.x1Scale,o=e.yScale,s=e.zScale,d=e.keys,l=e.height,f=M(e,["data","className","top","left","x0","x0Scale","x1Scale","yScale","zScale","keys","height"]),p=c.tickFormat?c.tickFormat():function(e){return e};return O.createElement(A.Group,{className:q("vx-bar-group",t),top:a,left:n},r&&r.map(function(a,e){return O.createElement(A.Group,{key:"bar-group-"+e+"-"+i(a),left:c(i(a))},d&&d.map(function(e,r){var t=a[e];return O.createElement(x,D({key:"bar-group-bar-"+r+"-"+t+"-"+e,x:u(e),y:o(t),width:u.bandwidth(),height:l-o(t),fill:s(e),data:{key:e,value:t,x:p(i(a)),data:a}},f))}))}))}function s(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.y0,c=e.y0Scale,u=e.y1Scale,o=e.xScale,s=e.zScale,d=e.keys,l=e.width,f=M(e,["data","className","top","left","y0","y0Scale","y1Scale","xScale","zScale","keys","width"]),p=c.tickFormat?c.tickFormat():function(e){return e};return O.createElement(A.Group,{className:q("vx-bar-group-horizontal",t),top:a,left:n},r&&r.map(function(a,e){return O.createElement(A.Group,{key:"bar-group-"+e+"-"+i(a),top:c(i(a))},d&&d.map(function(e,r){var t=a[e];return O.createElement(x,D({key:"bar-group-bar-"+r+"-"+t+"-"+e,x:0,y:u(e),width:l-o(t),height:u.bandwidth(),fill:s(e),data:{key:e,value:t,y:p(i(a)),data:a}},f))}))}))}function d(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.x,c=e.xScale,u=e.yScale,o=e.zScale,s=e.keys,d=(e.height,M(e,["data","className","top","left","x","xScale","yScale","zScale","keys","height"])),l=z.stack().keys(s)(r),f=c.tickFormat?c.tickFormat():function(e){return e},p=c.bandwidth(),y=c.step(),v=c.paddingInner(),h=c.paddingOuter();return O.createElement(A.Group,{className:q("vx-bar-stack",t),top:a,left:n},l&&l.map(function(a,n){return O.createElement(A.Group,{key:"vx-bar-stack-"+n},a.map(function(e,r){var t=u(e[0])-u(e[1]);return O.createElement(x,D({key:"bar-group-bar-"+n+"-"+r+"-"+a.key,x:c(i(e.data)),y:u(e[1]),width:p,height:t,fill:o(a.key),data:{bandwidth:p,paddingInner:v,paddingOuter:h,step:y,key:a.key,value:e[1],height:t,width:p,x:i(e.data),xFormatted:f(i(e.data)),data:e.data}},d))}))}))}function l(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.y,c=e.xScale,u=e.yScale,o=e.zScale,s=e.keys,d=(e.height,M(e,["data","className","top","left","y","xScale","yScale","zScale","keys","height"])),l=z.stack().keys(s)(r),f=u.tickFormat?u.tickFormat():function(e){return e},p=u.bandwidth(),y=u.step(),v=u.paddingInner(),h=u.paddingOuter();return O.createElement(A.Group,{className:q("vx-bar-stack-horizontal",t),top:a,left:n},l&&l.map(function(a,n){return O.createElement(A.Group,{key:"vx-bar-stack-horizontal-"+n},a.map(function(e,r){var t=c(e[1])-c(e[0]);return O.createElement(x,D({key:"bar-group-bar-"+n+"-"+r+"-"+a.key,x:c(e[0]),y:u(i(e.data)),width:t,height:p,fill:o(a.key),data:{bandwidth:p,paddingInner:v,paddingOuter:h,step:y,key:a.key,value:e[0],height:p,width:t,y:i(e.data),yFormatted:f(i(e.data)),data:e.data}},d))}))}))}t.propTypes={innerRef:r.func},a.propTypes={innerRef:r.func,xScale:r.func,yScale:r.func,data:r.array,x:r.func,y:r.func,defined:r.func,stroke:r.string,strokeWidth:r.number,glyph:r.func,curve:r.func},i.propTypes={innerRef:r.func},c.propTypes={x:r.func,x0:r.func,x1:r.func,y:r.func,y0:r.func,y1:r.func,xScale:r.func,yScale:r.func,data:r.array,defined:r.func,className:r.oneOfType([r.string,r.bool,r.object,r.array]),innerRef:r.func,strokeDasharray:r.string,strokeWidth:r.number,stroke:r.string,fill:r.string,curve:r.func},u.propTypes={innerRef:r.func},x.propTypes={innerRef:r.func},o.propTypes={data:r.array.isRequired,x0:r.func.isRequired,x0Scale:r.func.isRequired,x1Scale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,height:r.number.isRequired,className:r.string,top:r.number,left:r.number},s.propTypes={data:r.array.isRequired,y0:r.func.isRequired,y0Scale:r.func.isRequired,y1Scale:r.func.isRequired,xScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,width:r.number.isRequired,className:r.string,top:r.number,left:r.number},d.propTypes={data:r.array.isRequired,x:r.func.isRequired,xScale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,className:r.string,top:r.number,left:r.number},l.propTypes={data:r.array.isRequired,y:r.func.isRequired,xScale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,className:r.string,top:r.number,left:r.number};var f={ascending:z.stackOrderAscending,descending:z.stackOrderDescending,insideout:z.stackOrderInsideOut,none:z.stackOrderNone,reverse:z.stackOrderReverse},p=Object.keys(f);function E(e){return f[e]||f.none}var y={expand:z.stackOffsetExpand,diverging:z.stackOffsetDiverging,none:z.stackOffsetNone,silhouette:z.stackOffsetSilhouette,wiggle:z.stackOffsetWiggle},v=Object.keys(y);function w(e){return y[e]||y.none}function h(e){var t=e.source,a=e.target,n=e.x,i=e.y;return function(e){var r=z.linkHorizontal();return r.x(n),r.y(i),r.source(t),r.target(a),r(e)}}function g(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||h({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link-horizontal",r),d:n(a)},L(p,a)))}function k(e){var t=e.source,a=e.target,n=e.x,i=e.y;return function(e){var r=z.linkVertical();return r.x(n),r.y(i),r.source(t),r.target(a),r(e)}}function N(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||k({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link-vertical",r),d:n(a)},L(p,a)))}function S(e){var t=e.source,a=e.target,n=e.angle,i=e.radius;return function(e){var r=z.linkRadial();return r.angle(n),r.radius(i),r.source(t),r.target(a),r(e)}}function b(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.angle,c=void 0===i?function(e){return e.x}:i,u=e.radius,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","angle","radius","source","target"]);return n=n||S({source:d,target:f,angle:c,radius:o}),O.createElement("path",D({ref:t,className:q("vx-link-radius",r),d:n(a)},L(p,a)))}function P(e){var f=e.source,p=e.target,y=e.x,v=e.y,h=e.percent;return function(e){var r=f(e),t=p(e),a=y(r),n=v(r),i=y(t),c=v(t),u=i-a,o=c-n,s=h*(u+o),d=h*(o-u),l=R.path();return l.moveTo(a,n),l.bezierCurveTo(a+s,n+d,i+d,c-s,i,c),l.toString()}}function W(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||P({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function C(e){var f=e.source,p=e.target,y=e.x,v=e.y,h=e.percent;return function(e){var r=f(e),t=p(e),a=y(r),n=v(r),i=y(t),c=v(t),u=i-a,o=c-n,s=h*(u+o),d=h*(o-u),l=R.path();return l.moveTo(a,n),l.bezierCurveTo(a+s,n+d,i+d,c-s,i,c),l.toString()}}function V(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||C({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function F(e){var h=e.source,x=e.target,m=e.x,g=e.y,k=e.percent;return function(e){var r=h(e),t=x(e),a=m(r)-Math.PI/2,n=g(r),i=m(t)-Math.PI/2,c=g(t),u=n*Math.cos(a),o=n*Math.sin(a),s=c*Math.cos(i),d=c*Math.sin(i),l=s-u,f=d-o,p=k*(l+f),y=k*(f-l),v=R.path();return v.moveTo(u,o),v.bezierCurveTo(u+p,o+y,s+y,d-p,s,d),v.toString()}}function G(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||F({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function j(e){var o=e.source,s=e.target,d=e.x,l=e.y;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(i,c),u.toString()}}function I(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||j({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function H(e){var o=e.source,s=e.target,d=e.x,l=e.y;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(i,c),u.toString()}}function _(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||H({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function B(e){var f=e.source,p=e.target,y=e.x,v=e.y;return function(e){var r=f(e),t=p(e),a=y(r)-Math.PI/2,n=v(r),i=y(t)-Math.PI/2,c=v(t),u=Math.cos(a),o=Math.sin(a),s=Math.cos(i),d=Math.sin(i),l=R.path();return l.moveTo(n*u,n*o),l.lineTo(c*s,c*d),l.toString()}}function K(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||B({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function J(e){var o=e.source,s=e.target,d=e.x,l=e.y,f=e.percent;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(a+(i-a)*f,n),u.lineTo(a+(i-a)*f,c),u.lineTo(i,c),u.toString()}}function Q(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.percent,c=void 0===i?.5:i,u=e.x,o=void 0===u?function(e){return e.y}:u,s=e.y,d=void 0===s?function(e){return e.x}:s,l=e.source,f=void 0===l?function(e){return e.source}:l,p=e.target,y=void 0===p?function(e){return e.target}:p,v=M(e,["className","innerRef","data","path","percent","x","y","source","target"]);return n=n||J({source:f,target:y,x:o,y:d,percent:c}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function U(e){var o=e.source,s=e.target,d=e.x,l=e.y,f=e.percent;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(a,n+(c-n)*f),u.lineTo(i,n+(c-n)*f),u.lineTo(i,c),u.toString()}}function X(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.percent,c=void 0===i?.5:i,u=e.x,o=void 0===u?function(e){return e.x}:u,s=e.y,d=void 0===s?function(e){return e.y}:s,l=e.source,f=void 0===l?function(e){return e.source}:l,p=e.target,y=void 0===p?function(e){return e.target}:p,v=M(e,["className","innerRef","data","path","percent","x","y","source","target"]);return n=n||U({source:f,target:y,x:o,y:d,percent:c}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function Y(e){var v=e.source,h=e.target,x=e.x,m=e.y;return function(e){var r=v(e),t=h(e),a=x(r),n=m(r),i=x(t),c=m(t),u=a-Math.PI/2,o=n,s=i-Math.PI/2,d=c,l=Math.cos(u),f=Math.sin(u),p=Math.cos(s),y=Math.sin(s);return"\n M"+o*l+","+o*f+"\n A"+o+","+o+",0,0,"+((Math.abs(s-u)>Math.PI?s<=u:u<s)?1:0)+","+o*p+","+o*y+"\n L"+d*p+","+d*y+"\n "}}function Z(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||Y({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}g.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},N.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},b.propTypes={innerRef:r.func,angle:r.func,radius:r.func,source:r.func,target:r.func,path:r.func},W.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},V.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},G.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},I.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},_.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},K.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},Q.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},X.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},Z.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},e.Arc=function(e){var r=e.className,t=e.data,a=e.centroid,n=e.innerRadius,i=e.outerRadius,c=e.cornerRadius,u=e.startAngle,o=e.endAngle,s=e.padAngle,d=e.padRadius,l=M(e,["className","data","centroid","innerRadius","outerRadius","cornerRadius","startAngle","endAngle","padAngle","padRadius"]),f=z.arc();return a&&f.centroid(a),n&&f.innerRadius(n),i&&f.outerRadius(i),c&&f.cornerRadius(c),u&&f.startAngle(u),o&&f.endAngle(o),s&&f.padAngle(s),d&&f.padRadius(d),O.createElement("path",D({className:q("vx-arc",r),d:f(t)},L(l,t)))},e.Pie=function(e){var r=e.className,t=void 0===r?"":r,a=e.top,n=void 0===a?0:a,i=e.left,c=void 0===i?0:i,u=e.data,o=e.centroid,s=e.innerRadius,d=void 0===s?0:s,l=e.outerRadius,f=e.cornerRadius,p=e.startAngle,y=void 0===p?0:p,v=e.endAngle,h=e.padAngle,x=e.padRadius,m=e.pieSort,g=e.pieSortValues,k=e.pieValue,R=e.children,N=M(e,["className","top","left","data","centroid","innerRadius","outerRadius","cornerRadius","startAngle","endAngle","padAngle","padRadius","pieSort","pieSortValues","pieValue","children"]),S=z.arc();S.innerRadius(d),l&&S.outerRadius(l),f&&S.cornerRadius(f),x&&S.padRadius(x);var b=z.pie();m&&b.sort(m),g&&b.sortValues(g),k&&b.value(k),null!=h&&b.padAngle(h),null!=y&&b.startAngle(y),null!=v&&b.endAngle(v);var E=b(u),T={arcs:E,generatePathProps:function(e,r){return D({className:q("vx-pie-arc",t),d:S(e)},L(N,D({},e,{index:r,centroid:o?S.centroid(e):void 0})))},generateCentroid:function(e){return o&&o(S.centroid(e),e)}};return O.createElement(A.Group,{className:"vx-pie-arcs-group",top:n,left:c},R?R(T):E.map(function(e,r){var t=T.generatePathProps(e,r);return O.createElement("g",{key:"pie-arc-"+r},O.createElement("path",t),T.generateCentroid(e))}))},e.Line=t,e.LinePath=a,e.LineRadial=i,e.Area=c,e.AreaClosed=u,e.AreaStack=function(e){var t=e.className,r=(e.top,e.left,e.keys),a=e.data,n=e.curve,i=e.defined,c=e.x,u=e.x0,o=e.x1,s=e.y0,d=e.y1,l=e.glyph,f=e.reverse,p=void 0!==f&&f,y=M(e,["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","glyph","reverse"]),v=z.stack();r&&v.keys(r);var h=z.area();c&&h.x(c),u&&h.x0(u),o&&h.x1(o),s&&h.y0(s),d&&h.y1(d),n&&h.curve(n),i&&h.defined(i);var x=v(a);return p&&x.reverse(),O.createElement("g",null,x.map(function(e,r){return O.createElement("path",D({className:q("vx-area-stack",t),key:"area-stack-"+r+"-"+(e.key||""),d:h(e)},L(y,{datum:e[r],index:r,series:e})))}),!!l&&O.createElement("g",{className:"vx-area-stack-glyphs"},a.map(l)))},e.Bar=x,e.BarGroup=o,e.BarGroupHorizontal=s,e.BarStack=d,e.BarStackHorizontal=l,e.Stack=function(e){var t=e.className,r=e.top,a=void 0===r?0:r,n=e.left,i=void 0===n?0:n,c=e.keys,u=e.data,o=e.curve,s=e.defined,d=e.x,l=e.x0,f=e.x1,p=e.y0,y=e.y1,v=e.value,h=e.order,x=e.offset,m=e.render,g=e.reverse,k=void 0!==g&&g,R=M(e,["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","value","order","offset","render","reverse"]),N=z.stack();c&&N.keys(c),v&&N.value(v),h&&N.order(E(h)),x&&N.offset(w(x));var S=z.area();d&&S.x(d),l&&S.x0(l),f&&S.x1(f),p&&S.y0(p),y&&S.y1(y),o&&S.curve(o),s&&S.defined(s);var b=N(u);return k&&b.reverse(),m?O.createElement(A.Group,{top:a,left:i},m({seriesData:b,path:S})):O.createElement(A.Group,{top:a,left:i},b.map(function(e,r){return O.createElement("path",D({className:q("vx-stack",t),key:"stack-"+r+"-"+(e.key||""),d:S(e)},L(R,{datum:e[r],index:r,series:e})))}))},e.callOrValue=n,e.stackOffset=w,e.STACK_OFFSETS=y,e.STACK_OFFSET_NAMES=v,e.stackOrder=E,e.STACK_ORDERS=f,e.STACK_ORDER_NAMES=p,e.LinkHorizontal=g,e.pathHorizontalDiagonal=h,e.LinkVertical=N,e.pathVerticalDiagonal=k,e.LinkRadial=b,e.pathRadialDiagonal=S,e.LinkHorizontalCurve=W,e.pathHorizontalCurve=P,e.LinkVerticalCurve=V,e.pathVerticalCurve=C,e.LinkRadialCurve=G,e.pathRadialCurve=F,e.LinkHorizontalLine=I,e.pathHorizontalLine=j,e.LinkVerticalLine=_,e.pathVerticalLine=H,e.LinkRadialLine=K,e.pathRadialLine=B,e.LinkHorizontalStep=Q,e.pathHorizontalStep=J,e.LinkVerticalStep=X,e.pathVerticalStep=U,e.LinkRadialStep=Z,e.pathRadialStep=Y,Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports,require("react"),require("classnames"),require("d3-shape"),require("@vx/group"),require("prop-types"),require("@vx/point"),require("@vx/curve"),require("d3-path")):"function"==typeof define&&define.amd?define(["exports","react","classnames","d3-shape","@vx/group","prop-types","@vx/point","@vx/curve","d3-path"],r):r(e.vx=e.vx||{},e.React,e.classNames,e.d3,e.vx,e.PropTypes,e.vx,e.vx,e.d3)}(this,function(e,O,q,z,A,r,m,T,R){"use strict";function n(e,r){return"function"==typeof e?e(r):e}function L(t,a){return Object.keys(t).reduce(function(e,r){return e[r]=n(t[r],a),e},{})}O=O&&O.hasOwnProperty("default")?O.default:O,q=q&&q.hasOwnProperty("default")?q.default:q,r=r&&r.hasOwnProperty("default")?r.default:r;var D=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a])}return e},M=function(e,r){var t={};for(var a in e)0<=r.indexOf(a)||Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t};function t(e){var r=e.from,t=void 0===r?new m.Point({x:0,y:0}):r,a=e.to,n=void 0===a?new m.Point({x:1,y:1}):a,i=e.stroke,c=void 0===i?"black":i,u=e.strokeWidth,o=void 0===u?1:u,s=e.strokeDasharray,d=void 0===s?"":s,l=e.transform,f=void 0===l?"":l,p=e.className,y=void 0===p?"":p,v=e.data,h=e.innerRef,x=M(e,["from","to","stroke","strokeWidth","strokeDasharray","transform","className","data","innerRef"]);return O.createElement("line",D({ref:h,className:q("vx-line",y),x1:t.x,y1:t.y,x2:n.x,y2:n.y,stroke:c,strokeWidth:o,strokeDasharray:d,transform:f},L(x,v)))}function a(e){var r=e.children,t=e.data,a=e.xScale,n=e.yScale,i=e.x,c=e.y,u=e.defined,o=void 0===u?function(){return!0}:u,s=e.className,d=e.stroke,l=void 0===d?"steelblue":d,f=e.strokeWidth,p=void 0===f?2:f,y=e.strokeDasharray,v=void 0===y?"":y,h=e.strokeDashoffset,x=void 0===h?0:h,m=e.fill,g=void 0===m?"none":m,k=e.curve,R=void 0===k?T.curveLinear:k,N=e.glyph,S=e.innerRef,b=M(e,["children","data","xScale","yScale","x","y","defined","className","stroke","strokeWidth","strokeDasharray","strokeDashoffset","fill","curve","glyph","innerRef"]),E=z.line().x(function(){return a(i.apply(void 0,arguments))}).y(function(){return n(c.apply(void 0,arguments))}).defined(o).curve(R);return r?r({path:E}):O.createElement("g",null,O.createElement("path",D({ref:S,className:q("vx-linepath",s),d:E(t),stroke:l,strokeWidth:p,strokeDasharray:v,strokeDashoffset:x,fill:g},L(b,t))),N&&O.createElement("g",{className:"vx-linepath-glyphs"},t.map(N)))}function i(e){var r=e.className,t=void 0===r?"":r,a=e.angle,n=e.radius,i=e.defined,c=e.curve,u=e.data,o=e.innerRef,s=M(e,["className","angle","radius","defined","curve","data","innerRef"]),d=z.radialLine();return a&&d.angle(a),n&&d.radius(n),i&&d.defined(i),c&&d.curve(c),O.createElement("g",null,O.createElement("path",D({ref:o,className:q("vx-line-radial",t),d:d(u)},L(s,u))))}function c(e){var r=e.children,t=e.x,a=e.x0,n=e.x1,i=e.y,c=e.y0,u=e.y1,o=e.xScale,s=e.yScale,d=e.data,l=void 0===d?[]:d,f=e.defined,p=void 0===f?function(){return!0}:f,y=e.className,v=e.strokeDasharray,h=e.strokeWidth,x=void 0===h?2:h,m=e.stroke,g=void 0===m?"black":m,k=e.fill,R=void 0===k?"rgba(0,0,0,0.3)":k,N=e.curve,S=e.innerRef,b=M(e,["children","x","x0","x1","y","y0","y1","xScale","yScale","data","defined","className","strokeDasharray","strokeWidth","stroke","fill","curve","innerRef"]),E=z.area();return t&&E.x(function(){return o(t.apply(void 0,arguments))}),a&&E.x0(function(){return o(a.apply(void 0,arguments))}),n&&E.x1(function(){return o(n.apply(void 0,arguments))}),i&&E.y(function(){return s(i.apply(void 0,arguments))}),c&&E.y0(function(){return s(c.apply(void 0,arguments))}),u&&E.y1(function(){return s(u.apply(void 0,arguments))}),p&&E.defined(p),N&&E.curve(N),r?r({path:E}):O.createElement("g",null,O.createElement("path",D({ref:S,className:q("vx-area",y),d:E(l),stroke:g,strokeWidth:x,strokeDasharray:v,fill:R},L(b,l))))}function u(e){var r=e.x,t=e.y,a=e.y0,n=e.xScale,i=e.yScale,c=e.data,u=e.defined,o=void 0===u?function(){return!0}:u,s=e.className,d=e.strokeDasharray,l=e.strokeWidth,f=void 0===l?2:l,p=e.stroke,y=void 0===p?"black":p,v=e.fill,h=void 0===v?"rgba(0,0,0,0.3)":v,x=e.curve,m=e.innerRef,g=M(e,["x","y","y0","xScale","yScale","data","defined","className","strokeDasharray","strokeWidth","stroke","fill","curve","innerRef"]),k=z.area().x(function(){return n(r.apply(void 0,arguments))}).y0(a||i.range()[0]).y1(function(){return i(t.apply(void 0,arguments))}).defined(o);return x&&k.curve(x),O.createElement("g",null,O.createElement("path",D({ref:m,className:q("vx-area-closed",s),d:k(c),stroke:y,strokeWidth:f,strokeDasharray:d,fill:h},L(g,c))))}function x(e){var r=e.className,t=e.innerRef,a=e.data,n=e.x,i=void 0===n?0:n,c=e.y,u=void 0===c?0:c,o=e.width,s=e.height,d=e.rx,l=e.ry,f=e.fill,p=void 0===f?"steelblue":f,y=e.fillOpacity,v=e.stroke,h=e.strokeWidth,x=e.strokeDasharray,m=e.strokeLinecap,g=e.strokeLinejoin,k=e.strokeMiterlimit,R=e.strokeOpacity,N=M(e,["className","innerRef","data","x","y","width","height","rx","ry","fill","fillOpacity","stroke","strokeWidth","strokeDasharray","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity"]);return O.createElement("rect",D({ref:t,className:q("vx-bar",r),x:i,y:u,width:o,height:s,rx:d,ry:l,fill:p,fillOpacity:y,stroke:v,strokeWidth:h,strokeDasharray:x,strokeLinecap:m,strokeLinejoin:g,strokeMiterlimit:k,strokeOpacity:R},L(N,a)))}function o(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.x0,c=e.x0Scale,u=e.x1Scale,o=e.yScale,s=e.zScale,d=e.keys,l=e.height,f=M(e,["data","className","top","left","x0","x0Scale","x1Scale","yScale","zScale","keys","height"]),p=c.tickFormat?c.tickFormat():function(e){return e};return O.createElement(A.Group,{className:q("vx-bar-group",t),top:a,left:n},r&&r.map(function(a,e){return O.createElement(A.Group,{key:"bar-group-"+e+"-"+i(a),left:c(i(a))},d&&d.map(function(e,r){var t=a[e];return O.createElement(x,D({key:"bar-group-bar-"+r+"-"+t+"-"+e,x:u(e),y:o(t),width:u.bandwidth(),height:l-o(t),fill:s(e),data:{key:e,value:t,x:p(i(a)),data:a}},f))}))}))}function s(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.y0,c=e.y0Scale,u=e.y1Scale,o=e.xScale,s=e.zScale,d=e.keys,l=e.width,f=M(e,["data","className","top","left","y0","y0Scale","y1Scale","xScale","zScale","keys","width"]),p=c.tickFormat?c.tickFormat():function(e){return e};return O.createElement(A.Group,{className:q("vx-bar-group-horizontal",t),top:a,left:n},r&&r.map(function(a,e){return O.createElement(A.Group,{key:"bar-group-"+e+"-"+i(a),top:c(i(a))},d&&d.map(function(e,r){var t=a[e];return O.createElement(x,D({key:"bar-group-bar-"+r+"-"+t+"-"+e,x:0,y:u(e),width:l-o(t),height:u.bandwidth(),fill:s(e),data:{key:e,value:t,y:p(i(a)),data:a}},f))}))}))}function d(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.x,c=e.xScale,u=e.yScale,o=e.zScale,s=e.keys,d=(e.height,M(e,["data","className","top","left","x","xScale","yScale","zScale","keys","height"])),l=z.stack().keys(s)(r),f=c.tickFormat?c.tickFormat():function(e){return e},p=c.bandwidth(),y=c.step(),v=c.paddingInner(),h=c.paddingOuter();return O.createElement(A.Group,{className:q("vx-bar-stack",t),top:a,left:n},l&&l.map(function(a,n){return O.createElement(A.Group,{key:"vx-bar-stack-"+n},a.map(function(e,r){var t=u(e[0])-u(e[1]);return O.createElement(x,D({key:"bar-group-bar-"+n+"-"+r+"-"+a.key,x:c(i(e.data)),y:u(e[1]),width:p,height:t,fill:o(a.key),data:{bandwidth:p,paddingInner:v,paddingOuter:h,step:y,key:a.key,value:e[1],height:t,width:p,x:i(e.data),xFormatted:f(i(e.data)),data:e.data}},d))}))}))}function l(e){var r=e.data,t=e.className,a=e.top,n=e.left,i=e.y,c=e.xScale,u=e.yScale,o=e.zScale,s=e.keys,d=(e.height,M(e,["data","className","top","left","y","xScale","yScale","zScale","keys","height"])),l=z.stack().keys(s)(r),f=u.tickFormat?u.tickFormat():function(e){return e},p=u.bandwidth(),y=u.step(),v=u.paddingInner(),h=u.paddingOuter();return O.createElement(A.Group,{className:q("vx-bar-stack-horizontal",t),top:a,left:n},l&&l.map(function(a,n){return O.createElement(A.Group,{key:"vx-bar-stack-horizontal-"+n},a.map(function(e,r){var t=c(e[1])-c(e[0]);return O.createElement(x,D({key:"bar-group-bar-"+n+"-"+r+"-"+a.key,x:c(e[0]),y:u(i(e.data)),width:t,height:p,fill:o(a.key),data:{bandwidth:p,paddingInner:v,paddingOuter:h,step:y,key:a.key,value:e[0],height:p,width:t,y:i(e.data),yFormatted:f(i(e.data)),data:e.data}},d))}))}))}t.propTypes={innerRef:r.func},a.propTypes={innerRef:r.func,xScale:r.func,yScale:r.func,data:r.array,x:r.func,y:r.func,defined:r.func,stroke:r.string,strokeWidth:r.number,glyph:r.func,curve:r.func},i.propTypes={innerRef:r.func},c.propTypes={x:r.func,x0:r.func,x1:r.func,y:r.func,y0:r.func,y1:r.func,xScale:r.func,yScale:r.func,data:r.array,defined:r.func,className:r.oneOfType([r.string,r.bool,r.object,r.array]),innerRef:r.func,strokeDasharray:r.string,strokeWidth:r.number,stroke:r.string,fill:r.string,curve:r.func},u.propTypes={innerRef:r.func},x.propTypes={innerRef:r.func},o.propTypes={data:r.array.isRequired,x0:r.func.isRequired,x0Scale:r.func.isRequired,x1Scale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,height:r.number.isRequired,className:r.string,top:r.number,left:r.number},s.propTypes={data:r.array.isRequired,y0:r.func.isRequired,y0Scale:r.func.isRequired,y1Scale:r.func.isRequired,xScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,width:r.number.isRequired,className:r.string,top:r.number,left:r.number},d.propTypes={data:r.array.isRequired,x:r.func.isRequired,xScale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,className:r.string,top:r.number,left:r.number},l.propTypes={data:r.array.isRequired,y:r.func.isRequired,xScale:r.func.isRequired,yScale:r.func.isRequired,zScale:r.func.isRequired,keys:r.array.isRequired,className:r.string,top:r.number,left:r.number};var f={ascending:z.stackOrderAscending,descending:z.stackOrderDescending,insideout:z.stackOrderInsideOut,none:z.stackOrderNone,reverse:z.stackOrderReverse},p=Object.keys(f);function E(e){return f[e]||f.none}var y={expand:z.stackOffsetExpand,diverging:z.stackOffsetDiverging,none:z.stackOffsetNone,silhouette:z.stackOffsetSilhouette,wiggle:z.stackOffsetWiggle},v=Object.keys(y);function w(e){return y[e]||y.none}function h(e){var t=e.source,a=e.target,n=e.x,i=e.y;return function(e){var r=z.linkHorizontal();return r.x(n),r.y(i),r.source(t),r.target(a),r(e)}}function g(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||h({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link-horizontal",r),d:n(a)},L(p,a)))}function k(e){var t=e.source,a=e.target,n=e.x,i=e.y;return function(e){var r=z.linkVertical();return r.x(n),r.y(i),r.source(t),r.target(a),r(e)}}function N(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||k({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link-vertical",r),d:n(a)},L(p,a)))}function S(e){var t=e.source,a=e.target,n=e.angle,i=e.radius;return function(e){var r=z.linkRadial();return r.angle(n),r.radius(i),r.source(t),r.target(a),r(e)}}function b(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.angle,c=void 0===i?function(e){return e.x}:i,u=e.radius,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","angle","radius","source","target"]);return n=n||S({source:d,target:f,angle:c,radius:o}),O.createElement("path",D({ref:t,className:q("vx-link-radius",r),d:n(a)},L(p,a)))}function P(e){var f=e.source,p=e.target,y=e.x,v=e.y,h=e.percent;return function(e){var r=f(e),t=p(e),a=y(r),n=v(r),i=y(t),c=v(t),u=i-a,o=c-n,s=h*(u+o),d=h*(o-u),l=R.path();return l.moveTo(a,n),l.bezierCurveTo(a+s,n+d,i+d,c-s,i,c),l.toString()}}function W(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||P({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function C(e){var f=e.source,p=e.target,y=e.x,v=e.y,h=e.percent;return function(e){var r=f(e),t=p(e),a=y(r),n=v(r),i=y(t),c=v(t),u=i-a,o=c-n,s=h*(u+o),d=h*(o-u),l=R.path();return l.moveTo(a,n),l.bezierCurveTo(a+s,n+d,i+d,c-s,i,c),l.toString()}}function V(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||C({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function F(e){var h=e.source,x=e.target,m=e.x,g=e.y,k=e.percent;return function(e){var r=h(e),t=x(e),a=m(r)-Math.PI/2,n=g(r),i=m(t)-Math.PI/2,c=g(t),u=n*Math.cos(a),o=n*Math.sin(a),s=c*Math.cos(i),d=c*Math.sin(i),l=s-u,f=d-o,p=k*(l+f),y=k*(f-l),v=R.path();return v.moveTo(u,o),v.bezierCurveTo(u+p,o+y,s+y,d-p,s,d),v.toString()}}function G(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=e.percent,y=void 0===p?.2:p,v=M(e,["className","innerRef","data","path","x","y","source","target","percent"]);return n=n||F({source:d,target:f,x:c,y:o,percent:y}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function j(e){var o=e.source,s=e.target,d=e.x,l=e.y;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(i,c),u.toString()}}function I(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.y}:i,u=e.y,o=void 0===u?function(e){return e.x}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||j({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function H(e){var o=e.source,s=e.target,d=e.x,l=e.y;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(i,c),u.toString()}}function _(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||H({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function B(e){var f=e.source,p=e.target,y=e.x,v=e.y;return function(e){var r=f(e),t=p(e),a=y(r)-Math.PI/2,n=v(r),i=y(t)-Math.PI/2,c=v(t),u=Math.cos(a),o=Math.sin(a),s=Math.cos(i),d=Math.sin(i),l=R.path();return l.moveTo(n*u,n*o),l.lineTo(c*s,c*d),l.toString()}}function K(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||B({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}function J(e){var o=e.source,s=e.target,d=e.x,l=e.y,f=e.percent;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(a+(i-a)*f,n),u.lineTo(a+(i-a)*f,c),u.lineTo(i,c),u.toString()}}function Q(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.percent,c=void 0===i?.5:i,u=e.x,o=void 0===u?function(e){return e.y}:u,s=e.y,d=void 0===s?function(e){return e.x}:s,l=e.source,f=void 0===l?function(e){return e.source}:l,p=e.target,y=void 0===p?function(e){return e.target}:p,v=M(e,["className","innerRef","data","path","percent","x","y","source","target"]);return n=n||J({source:f,target:y,x:o,y:d,percent:c}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function U(e){var o=e.source,s=e.target,d=e.x,l=e.y,f=e.percent;return function(e){var r=o(e),t=s(e),a=d(r),n=l(r),i=d(t),c=l(t),u=R.path();return u.moveTo(a,n),u.lineTo(a,n+(c-n)*f),u.lineTo(i,n+(c-n)*f),u.lineTo(i,c),u.toString()}}function X(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.percent,c=void 0===i?.5:i,u=e.x,o=void 0===u?function(e){return e.x}:u,s=e.y,d=void 0===s?function(e){return e.y}:s,l=e.source,f=void 0===l?function(e){return e.source}:l,p=e.target,y=void 0===p?function(e){return e.target}:p,v=M(e,["className","innerRef","data","path","percent","x","y","source","target"]);return n=n||U({source:f,target:y,x:o,y:d,percent:c}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(v,a)))}function Y(e){var v=e.source,h=e.target,x=e.x,m=e.y;return function(e){var r=v(e),t=h(e),a=x(r),n=m(r),i=x(t),c=m(t),u=a-Math.PI/2,o=n,s=i-Math.PI/2,d=c,l=Math.cos(u),f=Math.sin(u),p=Math.cos(s),y=Math.sin(s);return"\n M"+o*l+","+o*f+"\n A"+o+","+o+",0,0,"+((Math.abs(s-u)>Math.PI?s<=u:u<s)?1:0)+","+o*p+","+o*y+"\n L"+d*p+","+d*y+"\n "}}function Z(e){var r=e.className,t=e.innerRef,a=e.data,n=e.path,i=e.x,c=void 0===i?function(e){return e.x}:i,u=e.y,o=void 0===u?function(e){return e.y}:u,s=e.source,d=void 0===s?function(e){return e.source}:s,l=e.target,f=void 0===l?function(e){return e.target}:l,p=M(e,["className","innerRef","data","path","x","y","source","target"]);return n=n||Y({source:d,target:f,x:c,y:o}),O.createElement("path",D({ref:t,className:q("vx-link",r),d:n(a)},L(p,a)))}g.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},N.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},b.propTypes={innerRef:r.func,angle:r.func,radius:r.func,source:r.func,target:r.func,path:r.func},W.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},V.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},G.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},I.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},_.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},K.propTypes={innerRef:r.func,path:r.func,x:r.func,y:r.func,source:r.func,target:r.func},Q.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},X.propTypes={innerRef:r.func,percent:r.number,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},Z.propTypes={innerRef:r.func,x:r.func,y:r.func,source:r.func,target:r.func,path:r.func},e.Arc=function(e){var r=e.className,t=e.data,a=e.centroid,n=e.innerRadius,i=e.outerRadius,c=e.cornerRadius,u=e.startAngle,o=e.endAngle,s=e.padAngle,d=e.padRadius,l=M(e,["className","data","centroid","innerRadius","outerRadius","cornerRadius","startAngle","endAngle","padAngle","padRadius"]),f=z.arc();return a&&f.centroid(a),n&&f.innerRadius(n),i&&f.outerRadius(i),c&&f.cornerRadius(c),u&&f.startAngle(u),o&&f.endAngle(o),s&&f.padAngle(s),d&&f.padRadius(d),O.createElement("path",D({className:q("vx-arc",r),d:f(t)},L(l,t)))},e.Pie=function(e){var r=e.className,t=void 0===r?"":r,a=e.top,n=void 0===a?0:a,i=e.left,c=void 0===i?0:i,u=e.data,o=e.centroid,s=e.innerRadius,d=void 0===s?0:s,l=e.outerRadius,f=e.cornerRadius,p=e.startAngle,y=void 0===p?0:p,v=e.endAngle,h=e.padAngle,x=e.padRadius,m=e.pieSort,g=e.pieSortValues,k=e.pieValue,R=e.children,N=M(e,["className","top","left","data","centroid","innerRadius","outerRadius","cornerRadius","startAngle","endAngle","padAngle","padRadius","pieSort","pieSortValues","pieValue","children"]),S=z.arc();S.innerRadius(d),l&&S.outerRadius(l),f&&S.cornerRadius(f),x&&S.padRadius(x);var b=z.pie();void 0!==m&&b.sort(m),void 0!==g&&b.sortValues(g),k&&b.value(k),null!=h&&b.padAngle(h),null!=y&&b.startAngle(y),null!=v&&b.endAngle(v);var E=b(u),T={arcs:E,generatePathProps:function(e,r){return D({className:q("vx-pie-arc",t),d:S(e)},L(N,D({},e,{index:r,centroid:o?S.centroid(e):void 0})))},generateCentroid:function(e){return o&&o(S.centroid(e),e)}};return O.createElement(A.Group,{className:"vx-pie-arcs-group",top:n,left:c},R?R(T):E.map(function(e,r){var t=T.generatePathProps(e,r);return O.createElement("g",{key:"pie-arc-"+r},O.createElement("path",t),T.generateCentroid(e))}))},e.Line=t,e.LinePath=a,e.LineRadial=i,e.Area=c,e.AreaClosed=u,e.AreaStack=function(e){var t=e.className,r=(e.top,e.left,e.keys),a=e.data,n=e.curve,i=e.defined,c=e.x,u=e.x0,o=e.x1,s=e.y0,d=e.y1,l=e.glyph,f=e.reverse,p=void 0!==f&&f,y=M(e,["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","glyph","reverse"]),v=z.stack();r&&v.keys(r);var h=z.area();c&&h.x(c),u&&h.x0(u),o&&h.x1(o),s&&h.y0(s),d&&h.y1(d),n&&h.curve(n),i&&h.defined(i);var x=v(a);return p&&x.reverse(),O.createElement("g",null,x.map(function(e,r){return O.createElement("path",D({className:q("vx-area-stack",t),key:"area-stack-"+r+"-"+(e.key||""),d:h(e)},L(y,{datum:e[r],index:r,series:e})))}),!!l&&O.createElement("g",{className:"vx-area-stack-glyphs"},a.map(l)))},e.Bar=x,e.BarGroup=o,e.BarGroupHorizontal=s,e.BarStack=d,e.BarStackHorizontal=l,e.Stack=function(e){var t=e.className,r=e.top,a=void 0===r?0:r,n=e.left,i=void 0===n?0:n,c=e.keys,u=e.data,o=e.curve,s=e.defined,d=e.x,l=e.x0,f=e.x1,p=e.y0,y=e.y1,v=e.value,h=e.order,x=e.offset,m=e.render,g=e.reverse,k=void 0!==g&&g,R=M(e,["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","value","order","offset","render","reverse"]),N=z.stack();c&&N.keys(c),v&&N.value(v),h&&N.order(E(h)),x&&N.offset(w(x));var S=z.area();d&&S.x(d),l&&S.x0(l),f&&S.x1(f),p&&S.y0(p),y&&S.y1(y),o&&S.curve(o),s&&S.defined(s);var b=N(u);return k&&b.reverse(),m?O.createElement(A.Group,{top:a,left:i},m({seriesData:b,path:S})):O.createElement(A.Group,{top:a,left:i},b.map(function(e,r){return O.createElement("path",D({className:q("vx-stack",t),key:"stack-"+r+"-"+(e.key||""),d:S(e)},L(R,{datum:e[r],index:r,series:e})))}))},e.callOrValue=n,e.stackOffset=w,e.STACK_OFFSETS=y,e.STACK_OFFSET_NAMES=v,e.stackOrder=E,e.STACK_ORDERS=f,e.STACK_ORDER_NAMES=p,e.LinkHorizontal=g,e.pathHorizontalDiagonal=h,e.LinkVertical=N,e.pathVerticalDiagonal=k,e.LinkRadial=b,e.pathRadialDiagonal=S,e.LinkHorizontalCurve=W,e.pathHorizontalCurve=P,e.LinkVerticalCurve=V,e.pathVerticalCurve=C,e.LinkRadialCurve=G,e.pathRadialCurve=F,e.LinkHorizontalLine=I,e.pathHorizontalLine=j,e.LinkVerticalLine=_,e.pathVerticalLine=H,e.LinkRadialLine=K,e.pathRadialLine=B,e.LinkHorizontalStep=Q,e.pathHorizontalStep=J,e.LinkVerticalStep=X,e.pathVerticalStep=U,e.LinkRadialStep=Z,e.pathRadialStep=Y,Object.defineProperty(e,"__esModule",{value:!0})});
{
"name": "@vx/shape",
"version": "0.0.170",
"version": "0.0.171",
"description": "vx shape",

@@ -5,0 +5,0 @@ "sideEffects": false,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc