@typeolymp/ui-components 1.19.16 → 1.19.17
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/build/components/atoms/Icon/index.d.ts +1 -1
- package/build/components/atoms/Input/Search.d.ts +7 -0
- package/build/components/atoms/Input/index.d.ts +2 -0
- package/build/components/atoms/Input/stories.d.ts +2 -0
- package/build/components/atoms/Input/translations.d.ts +11 -0
- package/build/components/molecules/Key/translations.d.ts +5 -0
- package/build/components/molecules/PasswordInputField/translations.d.ts +11 -0
- package/build/components/molecules/Tabs/styles.d.ts +2 -0
- package/build/components/organisms/Chart/data copy.d.ts +30 -0
- package/build/components/organisms/Chart/styles.d.ts +1 -0
- package/build/index.es.js +642 -762
- package/build/index.es.js.map +1 -1
- package/build/index.js +642 -762
- package/build/index.js.map +1 -1
- package/build/lib/enums.d.ts +4 -0
- package/build/lib/helpers.d.ts +1 -0
- package/build/lib/theme/index.d.ts +3 -0
- package/build/lib/theme/types.d.ts +72 -0
- package/build/lib/translations/index.d.ts +6 -0
- package/build/lib/types/TranslationType.d.ts +7 -0
- package/package.json +1 -1
package/build/index.js
CHANGED
|
@@ -3591,6 +3591,7 @@ var icons = {
|
|
|
3591
3591
|
bell: (jsxRuntime.jsx("path", { d: "M13.6 1.8c0-.4-.2-.8-.5-1.1-.3-.3-.7-.5-1.1-.5-.9 0-1.6.7-1.6 1.6v.4c-3.7.8-6.3 4-6.3 7.8v2.9c0 1.6-.6 3.1-1.7 4.2l-.4.2c-.6.6-.9 1.4-.9 2.2v1c0 .8.6 1.4 1.4 1.4h6.3c.2 1.1 1.2 1.9 2.4 1.9h1.6c.7 0 1.3-.3 1.7-.7.3-.3.6-.8.7-1.2h6.3c.7 0 1.4-.6 1.4-1.4v-1c0-.8-.3-1.6-.9-2.2l-.3-.3c-1.1-1.1-1.7-2.6-1.7-4.2V9.9c0-3.8-2.7-7.1-6.4-7.9v-.2z" })),
|
|
3592
3592
|
bin: (jsxRuntime.jsx("path", { d: "M4.3 7.2h15.5v.2c-.1 1.4-.2 2.7-.3 4.1-.1 1.3-.2 2.7-.3 4-.1 1.6-.2 3.1-.4 4.7 0 .6-.1 1.1-.1 1.7-.2 1.1-1.3 2.1-2.5 2.1H7.9c-1.2 0-2.4-1.1-2.5-2.3-.1-1.6-.3-3.2-.4-4.9-.1-1.7-.3-3.4-.4-5.2-.1-1.4-.2-2.9-.3-4.4zm7.1 8.4v4.5c0 .4.3.7.7.7.4 0 .6-.3.6-.7v-8.9-.2c-.1-.3-.3-.5-.6-.5-.4 0-.7.3-.7.7v4.4zm4.5 0v-1.1-3.4c0-.4-.3-.7-.7-.7-.4 0-.6.3-.6.7v9.1c0 .3.2.5.5.6.4.1.8-.2.8-.7v-4.5zm-7.8 0v4.6c0 .3.3.6.6.6.4 0 .7-.3.7-.7v-8.9-.2c0-.4-.3-.6-.7-.6-.4 0-.6.3-.6.7v4.5zM15.7 3.3h3.5c1.1 0 1.9.7 2.1 1.8v.4c0 .2-.2.4-.4.5H3.2h-.1c-.3 0-.5-.2-.5-.5 0-1.2.9-2 2.2-2.1h3.5v-.7c0-1.6 1-2.7 2.5-2.7h2.6c1.3.1 2.2 1.2 2.3 2.4v.9zm-5.5 0h3.6v-.8c0-.3-.2-.5-.6-.5h-2.5c-.3 0-.5.2-.6.5.1.2.1.5.1.8z" })),
|
|
3593
3593
|
user: (jsxRuntime.jsx("path", { d: "M12 12.4c3.4 0 6.2-2.8 6.2-6.2S15.4 0 12 0 5.8 2.8 5.8 6.2s2.8 6.2 6.2 6.2zM16.6 12.6c-.3-.1-.7 0-1 .2-1 .8-2.3 1.2-3.6 1.2s-2.6-.4-3.7-1.2c-.3-.2-.6-.3-1-.2C3 13.6 0 17.4 0 21.9 0 23 1 24 2.1 24h19.7c1.2 0 2.1-1 2.1-2.1.1-4.5-2.9-8.3-7.3-9.3z" })),
|
|
3594
|
+
search: (jsxRuntime.jsx("path", { d: "M.6 23.4c.6.6 1.7.6 2.3 0l7.1-7.1c1.4 1 3.2 1.6 5.1 1.6 4.9 0 8.9-4 8.9-8.9S20 .1 15.1.1C10.1.1 6 4.1 6 9c0 1.9.6 3.6 1.6 5.1L.5 21.2c-.6.6-.6 1.6.1 2.2zM9.3 9c0-3.1 2.5-5.7 5.7-5.7s5.7 2.5 5.7 5.7c0 3.1-2.5 5.7-5.7 5.7S9.3 12.2 9.3 9z" })),
|
|
3594
3595
|
};
|
|
3595
3596
|
var Icon = function (props) { return (jsxRuntime.jsx(Wrapper$a, __assign$2({}, props, { children: jsxRuntime.jsx("svg", __assign$2({ viewBox: "0 0 24 24", fill: "none" }, { children: icons[props.type] })) }))); };
|
|
3596
3597
|
|
|
@@ -4528,7 +4529,7 @@ function requiredArgs(required, args) {
|
|
|
4528
4529
|
}
|
|
4529
4530
|
}
|
|
4530
4531
|
|
|
4531
|
-
function _typeof$
|
|
4532
|
+
function _typeof$u(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$u = function _typeof(obj) { return typeof obj; }; } else { _typeof$u = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$u(obj); }
|
|
4532
4533
|
/**
|
|
4533
4534
|
* @name toDate
|
|
4534
4535
|
* @category Common Helpers
|
|
@@ -4564,7 +4565,7 @@ function toDate(argument) {
|
|
|
4564
4565
|
requiredArgs(1, arguments);
|
|
4565
4566
|
var argStr = Object.prototype.toString.call(argument); // Clone the date
|
|
4566
4567
|
|
|
4567
|
-
if (argument instanceof Date || _typeof$
|
|
4568
|
+
if (argument instanceof Date || _typeof$u(argument) === 'object' && argStr === '[object Date]') {
|
|
4568
4569
|
// Prevent the date to lose the milliseconds when passed to new Date() in IE10
|
|
4569
4570
|
return new Date(argument.getTime());
|
|
4570
4571
|
} else if (typeof argument === 'number' || argStr === '[object Number]') {
|
|
@@ -4835,7 +4836,7 @@ var millisecondsInMinute = 60000;
|
|
|
4835
4836
|
|
|
4836
4837
|
var millisecondsInHour = 3600000;
|
|
4837
4838
|
|
|
4838
|
-
function _typeof$
|
|
4839
|
+
function _typeof$t(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$t = function _typeof(obj) { return typeof obj; }; } else { _typeof$t = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$t(obj); }
|
|
4839
4840
|
/**
|
|
4840
4841
|
* @name isDate
|
|
4841
4842
|
* @category Common Helpers
|
|
@@ -4871,7 +4872,7 @@ function _typeof$x(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "func
|
|
|
4871
4872
|
|
|
4872
4873
|
function isDate(value) {
|
|
4873
4874
|
requiredArgs(1, arguments);
|
|
4874
|
-
return value instanceof Date || _typeof$
|
|
4875
|
+
return value instanceof Date || _typeof$t(value) === 'object' && Object.prototype.toString.call(value) === '[object Date]';
|
|
4875
4876
|
}
|
|
4876
4877
|
|
|
4877
4878
|
/**
|
|
@@ -7985,6 +7986,20 @@ var DateInput = function (props) {
|
|
|
7985
7986
|
return (jsxRuntime.jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled, isChanged: isChanged }, { children: [jsxRuntime.jsx(Icon, { type: "calendar", color: "gray", size: "small", onClick: showPicker }), jsxRuntime.jsx(StyledInput, __assign$2({ type: "date" }, props, { onChange: onChange, onBlur: onBlur, onKeyPress: onKeyPress, ref: inputRef }))] })));
|
|
7986
7987
|
};
|
|
7987
7988
|
|
|
7989
|
+
var SearchInput = function (props) {
|
|
7990
|
+
var _a = React$3.useState(props.defaultValue || ""), value = _a[0], setValue = _a[1];
|
|
7991
|
+
var onChange = function (e) {
|
|
7992
|
+
setValue(e.target.value);
|
|
7993
|
+
if (!props.disabled && !!props.onChange)
|
|
7994
|
+
props.onChange(e.target.value);
|
|
7995
|
+
};
|
|
7996
|
+
var onSearch = function () {
|
|
7997
|
+
if (props.onSearch)
|
|
7998
|
+
props.onSearch(value);
|
|
7999
|
+
};
|
|
8000
|
+
return (jsxRuntime.jsx(Container$q, { children: jsxRuntime.jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled }, { children: [jsxRuntime.jsx(Icon, { type: "search", color: "gray", size: "small", onClick: onSearch }), jsxRuntime.jsx(StyledInput, __assign$2({ type: "text" }, props, { onChange: onChange }))] })) }));
|
|
8001
|
+
};
|
|
8002
|
+
|
|
7988
8003
|
var Input = function (props) {
|
|
7989
8004
|
var onChange = function (e) {
|
|
7990
8005
|
if (!props.disabled && !!props.onChange)
|
|
@@ -7993,7 +8008,8 @@ var Input = function (props) {
|
|
|
7993
8008
|
return jsxRuntime.jsx(StyledInput, __assign$2({ type: "text" }, props, { onChange: onChange }));
|
|
7994
8009
|
};
|
|
7995
8010
|
Input.Password = PasswordInput;
|
|
7996
|
-
Input.Date = DateInput;
|
|
8011
|
+
Input.Date = DateInput;
|
|
8012
|
+
Input.Search = SearchInput;
|
|
7997
8013
|
|
|
7998
8014
|
var Logo = function (props) { return (jsxRuntime.jsxs("svg", __assign$2({ width: 396, height: 66, viewBox: "0 0 662.8 118.1", fill: "none", xmlSpace: "preserve" }, props, { children: [jsxRuntime.jsxs("g", { children: [jsxRuntime.jsx("path", { d: "M61.6 23.5c-.4-.5-.9-1.1-1.3-1.5l-4.9-4.8L42 4c-1.3-1.3-2.8-2.3-4.5-3-1.7-.7-3.5-1-5.3-1-1.8 0-3.6.4-5.3 1-1.7.7-3.2 1.7-4.5 3L4.1 22C1.5 24.6 0 28 0 31.7c0 3.6 1.5 7.1 4.1 9.7l18.3 18c2.6 2.6 6.2 4 9.8 4 3.7 0 7.2-1.4 9.8-4l13.4-13.2-4.9-4.8c-.5-.5-.9-1-1.3-1.5L35.7 53.1c-.5.5-1 .8-1.6 1.1-.6.2-1.3.4-1.9.4-.7 0-1.3-.1-1.9-.4-.6-.2-1.2-.6-1.6-1.1l-18.3-18c-.9-.9-1.5-2.2-1.5-3.5 0-1.3.5-2.5 1.5-3.5l18.3-18c.5-.5 1-.8 1.6-1.1.6-.2 1.3-.4 1.9-.4.7 0 1.3.1 1.9.4.6.2 1.2.6 1.6 1.1l13.5 13.3 4.8 4.7c.5.4.8 1 1.1 1.6.2.6.4 1.2.4 1.9v.1c0 1.3.5 2.5 1.5 3.4l4.8 4.7c1.8-2.4 2.7-5.2 2.7-8.1-.1-3-1.1-5.8-2.9-8.2z", fill: "#e62743" }), jsxRuntime.jsx("path", { d: "M153.3 22L135 4c-1.3-1.3-2.8-2.3-4.5-3-1.7-.7-3.5-1-5.3-1-1.8 0-3.6.4-5.3 1-1.7.7-3.2 1.7-4.5 3L102 17.2 97.1 22c-.5.5-.9 1-1.3 1.5-1.8 2.4-2.8 5.2-2.8 8.2 0 2.9 1 5.8 2.7 8.1l4.8-4.7c.9-.9 1.4-2.1 1.5-3.4 0-.6.1-1.3.4-1.9.2-.6.6-1.1 1.1-1.6l4.8-4.7 13.5-13.3c.5-.5 1-.8 1.6-1.1.6-.2 1.2-.4 1.9-.4s1.3.1 1.9.4c.6.2 1.1.6 1.6 1.1l18.3 18c.5.5.8 1 1.1 1.6.3.6.4 1.2.4 1.9 0 .6-.1 1.3-.4 1.9-.3.6-.6 1.1-1.1 1.6l-18.3 18c-.5.5-1 .8-1.6 1.1-.6.2-1.2.4-1.9.4s-1.3-.1-1.9-.4c-.6-.2-1.1-.6-1.6-1.1l-13.5-13.3c-.4.5-.8 1.1-1.3 1.5l-4.9 4.8 13.4 13.2c1.3 1.3 2.8 2.3 4.5 3 1.7.7 3.5 1 5.3 1 1.8 0 3.6-.4 5.3-1 1.7-.7 3.2-1.7 4.5-3l18.3-18c1.3-1.3 2.3-2.8 3-4.5.7-1.7 1.1-3.5 1.1-5.3 0-1.8-.4-3.6-1.1-5.3-.8-1.5-1.8-3-3.1-4.3z", fill: "#53b476" }), jsxRuntime.jsx("path", { d: "M61.9 23.3l-.3.3c-.4-.5-.9-1.1-1.3-1.5l-4.9-4.8L68.8 4c1.3-1.3 2.8-2.3 4.5-3 1.7-.7 3.5-1 5.3-1s3.6.4 5.3 1c1.7.7 3.2 1.7 4.5 3l13.4 13.1-4.7 4.9c-.5.5-.9 1-1.3 1.5L82.2 10.2c-.5-.5-1-.8-1.6-1.1-.6-.2-1.3-.4-1.9-.4-.7 0-1.3.1-1.9.4-.6.2-1.2.6-1.6 1.1L61.9 23.3zm41.5 4.9l4.8-4.7c1.8 2.4 2.7 5.2 2.7 8.2 0 2.9-1 5.8-2.7 8.2-.4.5-.8 1.1-1.3 1.5l-4.9 4.8-13.5 13.2c-2.6 2.6-6.2 4-9.8 4s-7.2-1.4-9.8-4L55.4 46.1l-4.9-4.8c-.5-.5-.9-1-1.3-1.5-1.8-2.4-2.7-5.2-2.7-8.1 0-2.9 1-5.8 2.7-8.1l4.8 4.7c.5.4.8 1 1.1 1.6.2.6.4 1.2.4 1.9v.1c0 1.3.5 2.5 1.5 3.4l4.8 4.7 13.5 13.3c.5.5 1 .8 1.6 1.1s1.3.4 1.9.4 1.3-.1 1.9-.4 1.2-.6 1.6-1.1L95.8 40l4.8-4.7c.9-.9 1.4-2.1 1.5-3.4 0-.6.1-1.3.4-1.9 0-.8.4-1.3.9-1.8z", fillRule: "evenodd", clipRule: "evenodd", fill: "#ffd800" }), jsxRuntime.jsx("path", { d: "M130 76.6l-18.3-18c-2.6-2.6-6.2-4-9.8-4-3.7 0-7.2 1.4-9.8 4L78.7 71.9l-4.9 4.8c-.5.5-.9 1-1.3 1.5-1.8 2.4-2.7 5.2-2.7 8.1 0 2.9 1 5.8 2.7 8.1l4.8-4.7c.9-.9 1.4-2.1 1.5-3.4 0-1.3.5-2.5 1.5-3.4l4.8-4.7 13.5-13.3c.9-.9 2.2-1.4 3.5-1.4 1.3 0 2.6.5 3.5 1.4l18.3 18c.9.9 1.5 2.2 1.5 3.5 0 1.3-.5 2.5-1.5 3.5l-18.3 18c-.9.9-2.2 1.4-3.5 1.4-1.3 0-2.6-.5-3.5-1.4L84.9 94.5c-.4.6-.8 1.1-1.3 1.5l-4.9 4.8L92.1 114c2.6 2.6 6.2 4 9.8 4 3.7 0 7.2-1.4 9.8-4L130 96c1.3-1.3 2.3-2.8 3-4.5.7-1.7 1.1-3.5 1.1-5.3 0-1.8-.4-3.6-1.1-5.3-.6-1.5-1.7-3-3-4.3z", fill: "#8c5ca2" }), jsxRuntime.jsx("path", { d: "M84.9 78.2l-4.8 4.7c-.9.9-1.4 2.1-1.5 3.4 0 1.3-.5 2.5-1.5 3.4l-4.8 4.7-13.5 13.3c-.9.9-2.2 1.4-3.5 1.4s-2.6-.5-3.5-1.4l-18.3-18c-.9-.9-1.4-2.2-1.4-3.5s.5-2.5 1.4-3.5l18.3-18c.9-.9 2.2-1.4 3.5-1.4s2.6.5 3.5 1.4L72.3 78c.4-.5.8-1.1 1.3-1.5l4.9-4.8-13.3-13c-2.6-2.6-6.2-4-9.8-4-3.7 0-7.2 1.4-9.8 4l-18.3 18c-2.6 2.6-4.1 6.1-4.1 9.7s1.5 7.1 4.1 9.7l18.3 18c2.6 2.6 6.2 4 9.8 4 3.7 0 7.2-1.4 9.8-4l13.4-13.2 4.9-4.8c.5-.5.9-1 1.3-1.5 1.8-2.4 2.7-5.2 2.7-8.1.1-3.1-.9-5.9-2.6-8.3z", fill: "#3da9e1" })] }), jsxRuntime.jsxs("g", __assign$2({ fill: "#23292f" }, { children: [jsxRuntime.jsx("path", { d: "M236.6 21.5c-1.1-1-2.4-1.5-3.9-1.5h-40.2c-1.6 0-2.9.5-3.9 1.4-1.1.9-1.6 2.2-1.6 3.8 0 1.6.5 2.8 1.6 3.8s2.4 1.5 3.9 1.5h14.2V78c0 1.6.5 2.9 1.6 3.9 1.1 1.1 2.5 1.6 4.2 1.6 1.8 0 3.2-.5 4.3-1.6 1.1-1.1 1.7-2.4 1.7-3.9V30.4h14.2c1.6 0 2.9-.5 3.9-1.4 1.1-.9 1.6-2.2 1.6-3.8 0-1.5-.5-2.8-1.6-3.7z" }), jsxRuntime.jsx("path", { d: "M270.6 36.6c-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9v23.2c0 2.3-.4 4.2-1.2 5.8-.8 1.6-1.9 2.8-3.4 3.6-1.5.8-3.2 1.2-5.3 1.2-3.1 0-5.5-.8-7.2-2.4-1.7-1.6-2.6-4.4-2.6-8.3V40.5c0-1.6-.5-2.9-1.5-3.9-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9V67c0 3.4.7 6.4 2 9 1.3 2.6 3.2 4.7 5.6 6.2 2.4 1.5 5.2 2.2 8.4 2.2 2.7 0 5.1-.3 7.3-1 2.1-.7 3.9-1.6 5.5-2.9.7-.6 1.3-1.3 1.9-2v1c0 3.1-.5 5.5-1.4 7.3-.9 1.8-2.3 3.1-4.2 3.8-1.8.8-4.2 1.1-6.9 1.1-2.1 0-3.9-.3-5.4-1-1.6-.6-2.8-1.1-3.8-1.4-1.3-.5-2.6-.4-3.8.2-1.2.6-2.1 1.8-2.6 3.6-.4 1.3-.3 2.6.4 3.8.7 1.2 1.9 2.2 3.8 2.9 1.4.6 3.2 1.1 5.3 1.4 2.2.3 4.2.5 6.2.5 4.4 0 8.3-.7 11.8-2.2 3.5-1.4 6.3-3.8 8.4-7.1 2.1-3.3 3.1-7.7 3.1-13.3V40.5c-.3-1.6-.8-2.9-1.8-3.9zM327.5 46.1c-2-3.7-4.6-6.7-8-8.8-3.4-2.1-7.1-3.2-11.4-3.2-2.1 0-4.1.4-6 1.1-1.9.7-3.6 1.6-5 2.8-1.3 1-2.4 2-3.2 3.1v-.5c0-1.6-.5-2.9-1.5-3.9-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9v55.6c0 1.6.5 3 1.5 4s2.3 1.5 3.9 1.5 2.9-.5 3.9-1.6 1.5-2.4 1.5-3.9V78.3c.6.6 1.4 1.3 2.2 1.9 1.6 1.2 3.5 2.2 5.6 3 2.1.8 4.4 1.2 6.8 1.2 4.1 0 7.8-1.1 11.1-3.2s5.9-5.1 7.9-8.9c2-3.8 2.9-8.1 2.9-13.1s-1-9.3-2.9-13.1zm-9.2 20.8c-1.1 2.3-2.7 4.2-4.6 5.5-2 1.3-4.3 2-6.9 2s-5-.7-7-2-3.6-3.2-4.7-5.5-1.7-4.9-1.7-7.8c0-2.9.6-5.5 1.7-7.8s2.7-4.1 4.7-5.4c2-1.3 4.3-2 7-2s5 .7 6.9 2c2 1.3 3.5 3.1 4.6 5.4 1.1 2.3 1.7 4.8 1.7 7.8 0 2.9-.6 5.5-1.7 7.8zM380.4 61.6c1.1-.9 1.7-2.1 1.7-3.5 0-3.3-.6-6.3-1.9-9.2-1.2-2.9-2.9-5.5-5-7.7s-4.5-3.9-7.3-5.2c-2.8-1.3-5.7-1.9-8.7-1.9-4 0-7.8 1-11.3 3.1-3.6 2.1-6.5 5-8.7 8.8-2.2 3.8-3.3 8.5-3.3 13.9 0 4.7 1 8.8 3 12.5 2 3.7 4.9 6.6 8.7 8.7 3.8 2.1 8.2 3.2 13.4 3.2 3 0 6-.5 8.8-1.5 2.8-1 5-2.2 6.6-3.5 1.7-1.3 2.5-2.8 2.5-4.4 0-1.2-.4-2.3-1.3-3.2-.9-.9-2-1.4-3.3-1.4-1 0-2 .3-3.1.8-.7.4-1.4.8-2.2 1.3-.8.5-1.9 1-3.2 1.3-1.3.4-3.1.5-5.3.5-2.4 0-4.7-.6-6.8-1.8-2.1-1.2-3.9-2.9-5.3-5.2-.8-1.3-1.3-2.8-1.7-4.5h29.9c1.4.3 2.7-.2 3.8-1.1zM350 47.2c1.1-1.1 2.5-2 4.1-2.4 1.6-.5 3.3-.7 5.1-.7 1.9 0 3.6.4 5.3 1.2 1.7.8 3.1 1.9 4.2 3.3s1.7 3 1.9 4.7v.6h-23.7c.1-.7.3-1.5.5-2.1.5-1.9 1.5-3.4 2.6-4.6zM447.3 39.1c-1.5-3.9-3.6-7.4-6.4-10.4-2.8-3-6-5.3-9.8-7-3.8-1.7-7.9-2.5-12.4-2.5s-8.6.8-12.3 2.5c-3.7 1.7-7 4-9.7 7-2.8 3-4.9 6.5-6.4 10.4-1.5 3.9-2.3 8.2-2.3 12.7s.8 8.8 2.3 12.7c1.5 3.9 3.6 7.4 6.4 10.4 2.7 3 6 5.3 9.7 7 3.7 1.7 7.9 2.5 12.3 2.5 4.5 0 8.6-.8 12.4-2.5 3.8-1.7 7-4 9.8-7 2.8-3 4.9-6.5 6.4-10.4 1.5-3.9 2.3-8.2 2.3-12.7-.1-4.6-.8-8.8-2.3-12.7zm-12 23.7c-1.6 3.3-3.9 5.9-6.7 7.8-2.8 1.9-6.1 2.9-9.9 2.9-3.7 0-7-1-9.9-2.9-2.8-1.9-5.1-4.5-6.7-7.8-1.6-3.3-2.4-7-2.4-11 0-4.1.8-7.8 2.4-11.1 1.6-3.3 3.8-5.9 6.7-7.8 2.8-1.9 6.1-2.9 9.9-2.9 3.7 0 7 1 9.9 2.9 2.8 1.9 5.1 4.5 6.7 7.8 1.6 3.3 2.4 7 2.4 11 .1 4.1-.8 7.8-2.4 11.1zM468.4 18c-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6c-1.1 1.1-1.6 2.4-1.6 3.9v56c0 1.6.5 2.9 1.5 3.9 1 1.1 2.3 1.6 3.8 1.6 1.6 0 2.9-.5 3.9-1.6 1.1-1.1 1.6-2.4 1.6-3.9v-56c.1-1.5-.4-2.9-1.4-3.9zM520.2 36.6c-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9v23.2c0 2.3-.4 4.2-1.2 5.8-.8 1.6-1.9 2.8-3.4 3.6-1.4.8-3.2 1.2-5.3 1.2-3.1 0-5.5-.8-7.2-2.4-1.7-1.6-2.6-4.4-2.6-8.3V40.5c0-1.6-.5-2.9-1.5-3.9-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9V67c0 3.4.7 6.4 2 9 1.3 2.6 3.2 4.7 5.6 6.2 2.4 1.5 5.2 2.2 8.4 2.2 2.7 0 5.1-.3 7.3-1 2.1-.7 3.9-1.6 5.5-2.9.7-.6 1.3-1.3 1.9-2v1c0 3.1-.5 5.5-1.4 7.3-.9 1.8-2.3 3.1-4.2 3.8-1.8.8-4.2 1.1-6.9 1.1-2.1 0-3.9-.3-5.4-1-1.6-.6-2.8-1.1-3.8-1.4-1.3-.5-2.6-.4-3.8.2-1.2.6-2.1 1.8-2.6 3.6-.4 1.3-.3 2.6.4 3.8.7 1.2 1.9 2.2 3.8 2.9 1.4.6 3.2 1.1 5.3 1.4 2.2.3 4.2.5 6.2.5 4.4 0 8.3-.7 11.8-2.2 3.5-1.4 6.3-3.8 8.4-7.1 2.1-3.3 3.1-7.7 3.1-13.3V40.5c-.2-1.6-.7-2.9-1.8-3.9zM603.2 44.4c-.8-3.1-2.4-5.6-4.7-7.5s-5.6-2.8-9.9-2.8c-2.7 0-5.1.6-7.2 1.7-2.1 1.1-4 2.5-5.5 4.1-1.4 1.5-2.5 2.9-3.2 4.2-.8-2.6-2.1-4.7-3.9-6.5-2.3-2.3-5.9-3.5-10.7-3.5-2 0-3.8.3-5.5 1-1.7.6-3.2 1.5-4.6 2.5-1.4 1-2.6 2.1-3.5 3.3l-.9 1.2v-1.5c0-1.6-.5-2.9-1.5-3.9-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9V78c0 1.6.5 2.9 1.5 3.9 1 1.1 2.3 1.6 3.9 1.6s2.9-.5 3.9-1.6 1.5-2.4 1.5-3.9V54.7c0-2 .4-3.8 1.2-5.4.8-1.6 2-2.9 3.7-3.9 1.6-1 3.6-1.4 5.9-1.4 2.4 0 4.2.5 5.4 1.4 1.3 1 2.1 2.3 2.6 3.9s.7 3.4.7 5.4v23.2c0 1.6.5 2.9 1.5 3.9 1 1.1 2.3 1.6 3.9 1.6s2.9-.5 3.9-1.6 1.5-2.4 1.5-3.9V54.7c0-2 .4-3.8 1.2-5.4.8-1.6 2-2.9 3.7-3.9 1.6-1 3.6-1.4 5.9-1.4 2.4 0 4.2.5 5.4 1.4 1.3 1 2.1 2.3 2.6 3.9s.7 3.4.7 5.4v23.2c0 1.6.5 2.9 1.5 3.9 1 1.1 2.3 1.6 3.9 1.6s2.9-.5 3.9-1.6 1.5-2.4 1.5-3.9V54.7c.3-3.8-.2-7.2-1-10.3zM659.8 46.1c-2-3.7-4.6-6.7-8-8.8-3.4-2.1-7.1-3.2-11.4-3.2-2.1 0-4.1.4-6 1.1-1.9.7-3.6 1.6-5 2.8-1.3 1-2.4 2-3.2 3.1v-.5c0-1.6-.5-2.9-1.5-3.9-1-1.1-2.3-1.6-3.9-1.6s-2.9.5-3.9 1.6-1.5 2.4-1.5 3.9v55.6c0 1.6.5 3 1.5 4s2.3 1.5 3.9 1.5 2.9-.5 3.9-1.6 1.5-2.4 1.5-3.9V78.3c.6.6 1.4 1.3 2.2 1.9 1.6 1.2 3.5 2.2 5.6 3s4.4 1.2 6.8 1.2c4.1 0 7.8-1.1 11.1-3.2s5.9-5.1 7.9-8.9c2-3.8 2.9-8.1 2.9-13.1.1-5-.9-9.3-2.9-13.1zm-9.1 20.8c-1.1 2.3-2.7 4.2-4.6 5.5-2 1.3-4.3 2-6.9 2s-5-.7-7-2-3.5-3.2-4.7-5.5c-1.1-2.3-1.7-4.9-1.7-7.8 0-2.9.6-5.5 1.7-7.8s2.7-4.1 4.7-5.4c2-1.3 4.3-2 7-2s5 .7 6.9 2c2 1.3 3.5 3.1 4.6 5.4 1.1 2.3 1.7 4.8 1.7 7.8-.1 2.9-.6 5.5-1.7 7.8z" })] }))] }))); };
|
|
7999
8015
|
|
|
@@ -13587,15 +13603,15 @@ possibleStandardNamesOptimized$1.possibleStandardNames = {
|
|
|
13587
13603
|
|
|
13588
13604
|
Object.defineProperty(lib$1, '__esModule', { value: true });
|
|
13589
13605
|
|
|
13590
|
-
function _slicedToArray$
|
|
13591
|
-
return _arrayWithHoles$
|
|
13606
|
+
function _slicedToArray$d(arr, i) {
|
|
13607
|
+
return _arrayWithHoles$e(arr) || _iterableToArrayLimit$d(arr, i) || _unsupportedIterableToArray$l(arr, i) || _nonIterableRest$e();
|
|
13592
13608
|
}
|
|
13593
13609
|
|
|
13594
|
-
function _arrayWithHoles$
|
|
13610
|
+
function _arrayWithHoles$e(arr) {
|
|
13595
13611
|
if (Array.isArray(arr)) return arr;
|
|
13596
13612
|
}
|
|
13597
13613
|
|
|
13598
|
-
function _iterableToArrayLimit$
|
|
13614
|
+
function _iterableToArrayLimit$d(arr, i) {
|
|
13599
13615
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
13600
13616
|
|
|
13601
13617
|
if (_i == null) return;
|
|
@@ -13625,16 +13641,16 @@ function _iterableToArrayLimit$c(arr, i) {
|
|
|
13625
13641
|
return _arr;
|
|
13626
13642
|
}
|
|
13627
13643
|
|
|
13628
|
-
function _unsupportedIterableToArray$
|
|
13644
|
+
function _unsupportedIterableToArray$l(o, minLen) {
|
|
13629
13645
|
if (!o) return;
|
|
13630
|
-
if (typeof o === "string") return _arrayLikeToArray$
|
|
13646
|
+
if (typeof o === "string") return _arrayLikeToArray$l(o, minLen);
|
|
13631
13647
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
13632
13648
|
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
13633
13649
|
if (n === "Map" || n === "Set") return Array.from(o);
|
|
13634
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$
|
|
13650
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$l(o, minLen);
|
|
13635
13651
|
}
|
|
13636
13652
|
|
|
13637
|
-
function _arrayLikeToArray$
|
|
13653
|
+
function _arrayLikeToArray$l(arr, len) {
|
|
13638
13654
|
if (len == null || len > arr.length) len = arr.length;
|
|
13639
13655
|
|
|
13640
13656
|
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
@@ -13642,7 +13658,7 @@ function _arrayLikeToArray$k(arr, len) {
|
|
|
13642
13658
|
return arr2;
|
|
13643
13659
|
}
|
|
13644
13660
|
|
|
13645
|
-
function _nonIterableRest$
|
|
13661
|
+
function _nonIterableRest$e() {
|
|
13646
13662
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
13647
13663
|
}
|
|
13648
13664
|
|
|
@@ -13706,7 +13722,7 @@ reservedProps.forEach(function (name) {
|
|
|
13706
13722
|
// This is a mapping from React prop names to the attribute names.
|
|
13707
13723
|
|
|
13708
13724
|
[['acceptCharset', 'accept-charset'], ['className', 'class'], ['htmlFor', 'for'], ['httpEquiv', 'http-equiv']].forEach(function (_ref) {
|
|
13709
|
-
var _ref2 = _slicedToArray$
|
|
13725
|
+
var _ref2 = _slicedToArray$d(_ref, 2),
|
|
13710
13726
|
name = _ref2[0],
|
|
13711
13727
|
attributeName = _ref2[1];
|
|
13712
13728
|
|
|
@@ -16117,31 +16133,31 @@ var _default = function (file, acceptedFiles) {
|
|
|
16117
16133
|
return true;
|
|
16118
16134
|
};
|
|
16119
16135
|
|
|
16120
|
-
function _toConsumableArray$c(arr) { return _arrayWithoutHoles$c(arr) || _iterableToArray$d(arr) || _unsupportedIterableToArray$
|
|
16136
|
+
function _toConsumableArray$c(arr) { return _arrayWithoutHoles$c(arr) || _iterableToArray$d(arr) || _unsupportedIterableToArray$k(arr) || _nonIterableSpread$c(); }
|
|
16121
16137
|
|
|
16122
16138
|
function _nonIterableSpread$c() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16123
16139
|
|
|
16124
16140
|
function _iterableToArray$d(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16125
16141
|
|
|
16126
|
-
function _arrayWithoutHoles$c(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
16142
|
+
function _arrayWithoutHoles$c(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$k(arr); }
|
|
16127
16143
|
|
|
16128
|
-
function ownKeys$
|
|
16144
|
+
function ownKeys$q(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
16129
16145
|
|
|
16130
|
-
function _objectSpread$
|
|
16146
|
+
function _objectSpread$q(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$q(Object(source), !0).forEach(function (key) { _defineProperty$s(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$q(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16131
16147
|
|
|
16132
|
-
function _defineProperty$
|
|
16148
|
+
function _defineProperty$s(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
16133
16149
|
|
|
16134
|
-
function _slicedToArray$
|
|
16150
|
+
function _slicedToArray$c(arr, i) { return _arrayWithHoles$d(arr) || _iterableToArrayLimit$c(arr, i) || _unsupportedIterableToArray$k(arr, i) || _nonIterableRest$d(); }
|
|
16135
16151
|
|
|
16136
|
-
function _nonIterableRest$
|
|
16152
|
+
function _nonIterableRest$d() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16137
16153
|
|
|
16138
|
-
function _unsupportedIterableToArray$
|
|
16154
|
+
function _unsupportedIterableToArray$k(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$k(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$k(o, minLen); }
|
|
16139
16155
|
|
|
16140
|
-
function _arrayLikeToArray$
|
|
16156
|
+
function _arrayLikeToArray$k(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
16141
16157
|
|
|
16142
|
-
function _iterableToArrayLimit$
|
|
16158
|
+
function _iterableToArrayLimit$c(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
16143
16159
|
|
|
16144
|
-
function _arrayWithHoles$
|
|
16160
|
+
function _arrayWithHoles$d(arr) { if (Array.isArray(arr)) return arr; }
|
|
16145
16161
|
|
|
16146
16162
|
var FILE_INVALID_TYPE = "file-invalid-type";
|
|
16147
16163
|
var FILE_TOO_LARGE = "file-too-large";
|
|
@@ -16221,11 +16237,11 @@ function allFilesAccepted(_ref) {
|
|
|
16221
16237
|
|
|
16222
16238
|
return files.every(function (file) {
|
|
16223
16239
|
var _fileAccepted = fileAccepted(file, accept),
|
|
16224
|
-
_fileAccepted2 = _slicedToArray$
|
|
16240
|
+
_fileAccepted2 = _slicedToArray$c(_fileAccepted, 1),
|
|
16225
16241
|
accepted = _fileAccepted2[0];
|
|
16226
16242
|
|
|
16227
16243
|
var _fileMatchSize = fileMatchSize(file, minSize, maxSize),
|
|
16228
|
-
_fileMatchSize2 = _slicedToArray$
|
|
16244
|
+
_fileMatchSize2 = _slicedToArray$c(_fileMatchSize, 1),
|
|
16229
16245
|
sizeMatch = _fileMatchSize2[0];
|
|
16230
16246
|
|
|
16231
16247
|
var customErrors = validator ? validator(file) : null;
|
|
@@ -16322,7 +16338,7 @@ function canUseFileSystemAccessAPI() {
|
|
|
16322
16338
|
function pickerOptionsFromAccept(accept) {
|
|
16323
16339
|
if (isDefined(accept)) {
|
|
16324
16340
|
var acceptForPicker = Object.entries(accept).filter(function (_ref2) {
|
|
16325
|
-
var _ref3 = _slicedToArray$
|
|
16341
|
+
var _ref3 = _slicedToArray$c(_ref2, 2),
|
|
16326
16342
|
mimeType = _ref3[0],
|
|
16327
16343
|
ext = _ref3[1];
|
|
16328
16344
|
|
|
@@ -16340,11 +16356,11 @@ function pickerOptionsFromAccept(accept) {
|
|
|
16340
16356
|
|
|
16341
16357
|
return ok;
|
|
16342
16358
|
}).reduce(function (agg, _ref4) {
|
|
16343
|
-
var _ref5 = _slicedToArray$
|
|
16359
|
+
var _ref5 = _slicedToArray$c(_ref4, 2),
|
|
16344
16360
|
mimeType = _ref5[0],
|
|
16345
16361
|
ext = _ref5[1];
|
|
16346
16362
|
|
|
16347
|
-
return _objectSpread$
|
|
16363
|
+
return _objectSpread$q(_objectSpread$q({}, agg), {}, _defineProperty$s({}, mimeType, ext));
|
|
16348
16364
|
}, {});
|
|
16349
16365
|
return [{
|
|
16350
16366
|
// description is required due to https://crbug.com/1264708
|
|
@@ -16364,7 +16380,7 @@ function pickerOptionsFromAccept(accept) {
|
|
|
16364
16380
|
function acceptPropAsAcceptAttr(accept) {
|
|
16365
16381
|
if (isDefined(accept)) {
|
|
16366
16382
|
return Object.entries(accept).reduce(function (a, _ref6) {
|
|
16367
|
-
var _ref7 = _slicedToArray$
|
|
16383
|
+
var _ref7 = _slicedToArray$c(_ref6, 2),
|
|
16368
16384
|
mimeType = _ref7[0],
|
|
16369
16385
|
ext = _ref7[1];
|
|
16370
16386
|
|
|
@@ -16432,40 +16448,40 @@ function isExt(v) {
|
|
|
16432
16448
|
* @typedef {"file-invalid-type"|"file-too-large"|"file-too-small"|"too-many-files"} ErrorCode
|
|
16433
16449
|
*/
|
|
16434
16450
|
|
|
16435
|
-
var _excluded$
|
|
16436
|
-
_excluded2$
|
|
16451
|
+
var _excluded$d = ["children"],
|
|
16452
|
+
_excluded2$3 = ["open"],
|
|
16437
16453
|
_excluded3$1 = ["refKey", "role", "onKeyDown", "onFocus", "onBlur", "onClick", "onDragEnter", "onDragOver", "onDragLeave", "onDrop"],
|
|
16438
16454
|
_excluded4 = ["refKey", "onChange", "onClick"];
|
|
16439
16455
|
|
|
16440
|
-
function _toConsumableArray$b(arr) { return _arrayWithoutHoles$b(arr) || _iterableToArray$c(arr) || _unsupportedIterableToArray$
|
|
16456
|
+
function _toConsumableArray$b(arr) { return _arrayWithoutHoles$b(arr) || _iterableToArray$c(arr) || _unsupportedIterableToArray$j(arr) || _nonIterableSpread$b(); }
|
|
16441
16457
|
|
|
16442
16458
|
function _nonIterableSpread$b() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16443
16459
|
|
|
16444
16460
|
function _iterableToArray$c(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16445
16461
|
|
|
16446
|
-
function _arrayWithoutHoles$b(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
16462
|
+
function _arrayWithoutHoles$b(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$j(arr); }
|
|
16447
16463
|
|
|
16448
|
-
function _slicedToArray$
|
|
16464
|
+
function _slicedToArray$b(arr, i) { return _arrayWithHoles$c(arr) || _iterableToArrayLimit$b(arr, i) || _unsupportedIterableToArray$j(arr, i) || _nonIterableRest$c(); }
|
|
16449
16465
|
|
|
16450
|
-
function _nonIterableRest$
|
|
16466
|
+
function _nonIterableRest$c() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16451
16467
|
|
|
16452
|
-
function _unsupportedIterableToArray$
|
|
16468
|
+
function _unsupportedIterableToArray$j(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$j(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$j(o, minLen); }
|
|
16453
16469
|
|
|
16454
|
-
function _arrayLikeToArray$
|
|
16470
|
+
function _arrayLikeToArray$j(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
16455
16471
|
|
|
16456
|
-
function _iterableToArrayLimit$
|
|
16472
|
+
function _iterableToArrayLimit$b(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
16457
16473
|
|
|
16458
|
-
function _arrayWithHoles$
|
|
16474
|
+
function _arrayWithHoles$c(arr) { if (Array.isArray(arr)) return arr; }
|
|
16459
16475
|
|
|
16460
|
-
function ownKeys$
|
|
16476
|
+
function ownKeys$p(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
16461
16477
|
|
|
16462
|
-
function _objectSpread$
|
|
16478
|
+
function _objectSpread$p(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$p(Object(source), !0).forEach(function (key) { _defineProperty$r(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$p(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16463
16479
|
|
|
16464
|
-
function _defineProperty$
|
|
16480
|
+
function _defineProperty$r(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
16465
16481
|
|
|
16466
|
-
function _objectWithoutProperties$
|
|
16482
|
+
function _objectWithoutProperties$d(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$d(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
16467
16483
|
|
|
16468
|
-
function _objectWithoutPropertiesLoose$
|
|
16484
|
+
function _objectWithoutPropertiesLoose$d(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
16469
16485
|
/**
|
|
16470
16486
|
* Convenience wrapper component for the `useDropzone` hook
|
|
16471
16487
|
*
|
|
@@ -16483,11 +16499,11 @@ function _objectWithoutPropertiesLoose$g(source, excluded) { if (source == null)
|
|
|
16483
16499
|
|
|
16484
16500
|
var Dropzone = /*#__PURE__*/React$3.forwardRef(function (_ref, ref) {
|
|
16485
16501
|
var children = _ref.children,
|
|
16486
|
-
params = _objectWithoutProperties$
|
|
16502
|
+
params = _objectWithoutProperties$d(_ref, _excluded$d);
|
|
16487
16503
|
|
|
16488
16504
|
var _useDropzone = useDropzone(params),
|
|
16489
16505
|
open = _useDropzone.open,
|
|
16490
|
-
props = _objectWithoutProperties$
|
|
16506
|
+
props = _objectWithoutProperties$d(_useDropzone, _excluded2$3);
|
|
16491
16507
|
|
|
16492
16508
|
React$3.useImperativeHandle(ref, function () {
|
|
16493
16509
|
return {
|
|
@@ -16495,13 +16511,13 @@ var Dropzone = /*#__PURE__*/React$3.forwardRef(function (_ref, ref) {
|
|
|
16495
16511
|
};
|
|
16496
16512
|
}, [open]); // TODO: Figure out why react-styleguidist cannot create docs if we don't return a jsx element
|
|
16497
16513
|
|
|
16498
|
-
return /*#__PURE__*/React__default["default"].createElement(React$3.Fragment, null, children(_objectSpread$
|
|
16514
|
+
return /*#__PURE__*/React__default["default"].createElement(React$3.Fragment, null, children(_objectSpread$p(_objectSpread$p({}, props), {}, {
|
|
16499
16515
|
open: open
|
|
16500
16516
|
})));
|
|
16501
16517
|
});
|
|
16502
16518
|
Dropzone.displayName = "Dropzone"; // Add default props for react-docgen
|
|
16503
16519
|
|
|
16504
|
-
var defaultProps$
|
|
16520
|
+
var defaultProps$1 = {
|
|
16505
16521
|
disabled: false,
|
|
16506
16522
|
getFilesFromEvent: fromEvent,
|
|
16507
16523
|
maxSize: Infinity,
|
|
@@ -16517,7 +16533,7 @@ var defaultProps$2 = {
|
|
|
16517
16533
|
useFsAccessApi: true,
|
|
16518
16534
|
autoFocus: false
|
|
16519
16535
|
};
|
|
16520
|
-
Dropzone.defaultProps = defaultProps$
|
|
16536
|
+
Dropzone.defaultProps = defaultProps$1;
|
|
16521
16537
|
Dropzone.propTypes = {
|
|
16522
16538
|
/**
|
|
16523
16539
|
* Render function that exposes the dropzone state and prop getter fns
|
|
@@ -16868,7 +16884,7 @@ var initialState = {
|
|
|
16868
16884
|
function useDropzone() {
|
|
16869
16885
|
var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
16870
16886
|
|
|
16871
|
-
var _defaultProps$props = _objectSpread$
|
|
16887
|
+
var _defaultProps$props = _objectSpread$p(_objectSpread$p({}, defaultProps$1), props),
|
|
16872
16888
|
accept = _defaultProps$props.accept,
|
|
16873
16889
|
disabled = _defaultProps$props.disabled,
|
|
16874
16890
|
getFilesFromEvent = _defaultProps$props.getFilesFromEvent,
|
|
@@ -16915,7 +16931,7 @@ function useDropzone() {
|
|
|
16915
16931
|
var inputRef = React$3.useRef(null);
|
|
16916
16932
|
|
|
16917
16933
|
var _useReducer = React$3.useReducer(reducer$1, initialState),
|
|
16918
|
-
_useReducer2 = _slicedToArray$
|
|
16934
|
+
_useReducer2 = _slicedToArray$b(_useReducer, 2),
|
|
16919
16935
|
state = _useReducer2[0],
|
|
16920
16936
|
dispatch = _useReducer2[1];
|
|
16921
16937
|
|
|
@@ -17085,12 +17101,12 @@ function useDropzone() {
|
|
|
17085
17101
|
var fileRejections = [];
|
|
17086
17102
|
files.forEach(function (file) {
|
|
17087
17103
|
var _fileAccepted = fileAccepted(file, acceptAttr),
|
|
17088
|
-
_fileAccepted2 = _slicedToArray$
|
|
17104
|
+
_fileAccepted2 = _slicedToArray$b(_fileAccepted, 2),
|
|
17089
17105
|
accepted = _fileAccepted2[0],
|
|
17090
17106
|
acceptError = _fileAccepted2[1];
|
|
17091
17107
|
|
|
17092
17108
|
var _fileMatchSize = fileMatchSize(file, minSize, maxSize),
|
|
17093
|
-
_fileMatchSize2 = _slicedToArray$
|
|
17109
|
+
_fileMatchSize2 = _slicedToArray$b(_fileMatchSize, 2),
|
|
17094
17110
|
sizeMatch = _fileMatchSize2[0],
|
|
17095
17111
|
sizeError = _fileMatchSize2[1];
|
|
17096
17112
|
|
|
@@ -17291,9 +17307,9 @@ function useDropzone() {
|
|
|
17291
17307
|
onDragOver = _ref2.onDragOver,
|
|
17292
17308
|
onDragLeave = _ref2.onDragLeave,
|
|
17293
17309
|
onDrop = _ref2.onDrop,
|
|
17294
|
-
rest = _objectWithoutProperties$
|
|
17310
|
+
rest = _objectWithoutProperties$d(_ref2, _excluded3$1);
|
|
17295
17311
|
|
|
17296
|
-
return _objectSpread$
|
|
17312
|
+
return _objectSpread$p(_objectSpread$p(_defineProperty$r({
|
|
17297
17313
|
onKeyDown: composeKeyboardHandler(composeEventHandlers(onKeyDown, onKeyDownCb)),
|
|
17298
17314
|
onFocus: composeKeyboardHandler(composeEventHandlers(onFocus, onFocusCb)),
|
|
17299
17315
|
onBlur: composeKeyboardHandler(composeEventHandlers(onBlur, onBlurCb)),
|
|
@@ -17318,9 +17334,9 @@ function useDropzone() {
|
|
|
17318
17334
|
refKey = _ref3$refKey === void 0 ? "ref" : _ref3$refKey,
|
|
17319
17335
|
onChange = _ref3.onChange,
|
|
17320
17336
|
onClick = _ref3.onClick,
|
|
17321
|
-
rest = _objectWithoutProperties$
|
|
17337
|
+
rest = _objectWithoutProperties$d(_ref3, _excluded4);
|
|
17322
17338
|
|
|
17323
|
-
var inputProps = _defineProperty$
|
|
17339
|
+
var inputProps = _defineProperty$r({
|
|
17324
17340
|
accept: acceptAttr,
|
|
17325
17341
|
multiple: multiple,
|
|
17326
17342
|
type: "file",
|
|
@@ -17332,10 +17348,10 @@ function useDropzone() {
|
|
|
17332
17348
|
tabIndex: -1
|
|
17333
17349
|
}, refKey, inputRef);
|
|
17334
17350
|
|
|
17335
|
-
return _objectSpread$
|
|
17351
|
+
return _objectSpread$p(_objectSpread$p({}, inputProps), rest);
|
|
17336
17352
|
};
|
|
17337
17353
|
}, [inputRef, accept, multiple, onDropCb, disabled]);
|
|
17338
|
-
return _objectSpread$
|
|
17354
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17339
17355
|
isFocused: isFocused && !disabled,
|
|
17340
17356
|
getRootProps: getRootProps,
|
|
17341
17357
|
getInputProps: getInputProps,
|
|
@@ -17354,40 +17370,40 @@ function reducer$1(state, action) {
|
|
|
17354
17370
|
/* istanbul ignore next */
|
|
17355
17371
|
switch (action.type) {
|
|
17356
17372
|
case "focus":
|
|
17357
|
-
return _objectSpread$
|
|
17373
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17358
17374
|
isFocused: true
|
|
17359
17375
|
});
|
|
17360
17376
|
|
|
17361
17377
|
case "blur":
|
|
17362
|
-
return _objectSpread$
|
|
17378
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17363
17379
|
isFocused: false
|
|
17364
17380
|
});
|
|
17365
17381
|
|
|
17366
17382
|
case "openDialog":
|
|
17367
|
-
return _objectSpread$
|
|
17383
|
+
return _objectSpread$p(_objectSpread$p({}, initialState), {}, {
|
|
17368
17384
|
isFileDialogActive: true
|
|
17369
17385
|
});
|
|
17370
17386
|
|
|
17371
17387
|
case "closeDialog":
|
|
17372
|
-
return _objectSpread$
|
|
17388
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17373
17389
|
isFileDialogActive: false
|
|
17374
17390
|
});
|
|
17375
17391
|
|
|
17376
17392
|
case "setDraggedFiles":
|
|
17377
|
-
return _objectSpread$
|
|
17393
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17378
17394
|
isDragActive: action.isDragActive,
|
|
17379
17395
|
isDragAccept: action.isDragAccept,
|
|
17380
17396
|
isDragReject: action.isDragReject
|
|
17381
17397
|
});
|
|
17382
17398
|
|
|
17383
17399
|
case "setFiles":
|
|
17384
|
-
return _objectSpread$
|
|
17400
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17385
17401
|
acceptedFiles: action.acceptedFiles,
|
|
17386
17402
|
fileRejections: action.fileRejections
|
|
17387
17403
|
});
|
|
17388
17404
|
|
|
17389
17405
|
case "reset":
|
|
17390
|
-
return _objectSpread$
|
|
17406
|
+
return _objectSpread$p({}, initialState);
|
|
17391
17407
|
|
|
17392
17408
|
default:
|
|
17393
17409
|
return state;
|
|
@@ -19615,7 +19631,7 @@ function shallowEqual(a, b) {
|
|
|
19615
19631
|
return true;
|
|
19616
19632
|
}
|
|
19617
19633
|
|
|
19618
|
-
function _typeof$
|
|
19634
|
+
function _typeof$s(obj) { "@babel/helpers - typeof"; return _typeof$s = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$s(obj); }
|
|
19619
19635
|
|
|
19620
19636
|
//
|
|
19621
19637
|
// Event Handler Types -- Copied from @types/react/index.d.ts and adapted for Props.
|
|
@@ -19642,9 +19658,7 @@ var FilteredElementKeyMap = {
|
|
|
19642
19658
|
};
|
|
19643
19659
|
var EventKeys = ['dangerouslySetInnerHTML', 'onCopy', 'onCopyCapture', 'onCut', 'onCutCapture', 'onPaste', 'onPasteCapture', 'onCompositionEnd', 'onCompositionEndCapture', 'onCompositionStart', 'onCompositionStartCapture', 'onCompositionUpdate', 'onCompositionUpdateCapture', 'onFocus', 'onFocusCapture', 'onBlur', 'onBlurCapture', 'onChange', 'onChangeCapture', 'onBeforeInput', 'onBeforeInputCapture', 'onInput', 'onInputCapture', 'onReset', 'onResetCapture', 'onSubmit', 'onSubmitCapture', 'onInvalid', 'onInvalidCapture', 'onLoad', 'onLoadCapture', 'onError', 'onErrorCapture', 'onKeyDown', 'onKeyDownCapture', 'onKeyPress', 'onKeyPressCapture', 'onKeyUp', 'onKeyUpCapture', 'onAbort', 'onAbortCapture', 'onCanPlay', 'onCanPlayCapture', 'onCanPlayThrough', 'onCanPlayThroughCapture', 'onDurationChange', 'onDurationChangeCapture', 'onEmptied', 'onEmptiedCapture', 'onEncrypted', 'onEncryptedCapture', 'onEnded', 'onEndedCapture', 'onLoadedData', 'onLoadedDataCapture', 'onLoadedMetadata', 'onLoadedMetadataCapture', 'onLoadStart', 'onLoadStartCapture', 'onPause', 'onPauseCapture', 'onPlay', 'onPlayCapture', 'onPlaying', 'onPlayingCapture', 'onProgress', 'onProgressCapture', 'onRateChange', 'onRateChangeCapture', 'onSeeked', 'onSeekedCapture', 'onSeeking', 'onSeekingCapture', 'onStalled', 'onStalledCapture', 'onSuspend', 'onSuspendCapture', 'onTimeUpdate', 'onTimeUpdateCapture', 'onVolumeChange', 'onVolumeChangeCapture', 'onWaiting', 'onWaitingCapture', 'onAuxClick', 'onAuxClickCapture', 'onClick', 'onClickCapture', 'onContextMenu', 'onContextMenuCapture', 'onDoubleClick', 'onDoubleClickCapture', 'onDrag', 'onDragCapture', 'onDragEnd', 'onDragEndCapture', 'onDragEnter', 'onDragEnterCapture', 'onDragExit', 'onDragExitCapture', 'onDragLeave', 'onDragLeaveCapture', 'onDragOver', 'onDragOverCapture', 'onDragStart', 'onDragStartCapture', 'onDrop', 'onDropCapture', 'onMouseDown', 'onMouseDownCapture', 'onMouseEnter', 'onMouseLeave', 'onMouseMove', 'onMouseMoveCapture', 'onMouseOut', 'onMouseOutCapture', 'onMouseOver', 'onMouseOverCapture', 'onMouseUp', 'onMouseUpCapture', 'onSelect', 'onSelectCapture', 'onTouchCancel', 'onTouchCancelCapture', 'onTouchEnd', 'onTouchEndCapture', 'onTouchMove', 'onTouchMoveCapture', 'onTouchStart', 'onTouchStartCapture', 'onPointerDown', 'onPointerDownCapture', 'onPointerMove', 'onPointerMoveCapture', 'onPointerUp', 'onPointerUpCapture', 'onPointerCancel', 'onPointerCancelCapture', 'onPointerEnter', 'onPointerEnterCapture', 'onPointerLeave', 'onPointerLeaveCapture', 'onPointerOver', 'onPointerOverCapture', 'onPointerOut', 'onPointerOutCapture', 'onGotPointerCapture', 'onGotPointerCaptureCapture', 'onLostPointerCapture', 'onLostPointerCaptureCapture', 'onScroll', 'onScrollCapture', 'onWheel', 'onWheelCapture', 'onAnimationStart', 'onAnimationStartCapture', 'onAnimationEnd', 'onAnimationEndCapture', 'onAnimationIteration', 'onAnimationIterationCapture', 'onTransitionEnd', 'onTransitionEndCapture'];
|
|
19644
19660
|
|
|
19645
|
-
|
|
19646
|
-
|
|
19647
|
-
/** Specifies the duration of animation, the unit of this option is ms. */
|
|
19661
|
+
// Animation Types => TODO: Should be moved when react-smooth is typescriptified.
|
|
19648
19662
|
|
|
19649
19663
|
/** the offset of a chart, which define the blank space all around */
|
|
19650
19664
|
|
|
@@ -19680,7 +19694,7 @@ var getEventHandlerOfChild = function getEventHandlerOfChild(originalHandler, da
|
|
|
19680
19694
|
};
|
|
19681
19695
|
};
|
|
19682
19696
|
var adaptEventsOfChild = function adaptEventsOfChild(props, data, index) {
|
|
19683
|
-
if (!isObject_1(props) || _typeof$
|
|
19697
|
+
if (!isObject_1(props) || _typeof$s(props) !== 'object') {
|
|
19684
19698
|
return null;
|
|
19685
19699
|
}
|
|
19686
19700
|
var out = null;
|
|
@@ -19694,11 +19708,11 @@ var adaptEventsOfChild = function adaptEventsOfChild(props, data, index) {
|
|
|
19694
19708
|
return out;
|
|
19695
19709
|
};
|
|
19696
19710
|
|
|
19697
|
-
var _excluded$
|
|
19698
|
-
_excluded2$
|
|
19699
|
-
function _objectWithoutProperties$
|
|
19700
|
-
function _objectWithoutPropertiesLoose$
|
|
19701
|
-
function _typeof$
|
|
19711
|
+
var _excluded$c = ["children"],
|
|
19712
|
+
_excluded2$2 = ["children"];
|
|
19713
|
+
function _objectWithoutProperties$c(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$c(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
19714
|
+
function _objectWithoutPropertiesLoose$c(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
19715
|
+
function _typeof$r(obj) { "@babel/helpers - typeof"; return _typeof$r = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$r(obj); }
|
|
19702
19716
|
var REACT_BROWSER_EVENT_MAP = {
|
|
19703
19717
|
click: 'onClick',
|
|
19704
19718
|
mousedown: 'onMouseDown',
|
|
@@ -19805,7 +19819,7 @@ var isSvgElement = function isSvgElement(child) {
|
|
|
19805
19819
|
return child && child.type && isString_1(child.type) && SVG_TAGS.indexOf(child.type) >= 0;
|
|
19806
19820
|
};
|
|
19807
19821
|
var isDotProps = function isDotProps(dot) {
|
|
19808
|
-
return dot && _typeof$
|
|
19822
|
+
return dot && _typeof$r(dot) === 'object' && 'cx' in dot && 'cy' in dot && 'r' in dot;
|
|
19809
19823
|
};
|
|
19810
19824
|
|
|
19811
19825
|
/**
|
|
@@ -19897,10 +19911,10 @@ var isSingleChildEqual = function isSingleChildEqual(nextChild, prevChild) {
|
|
|
19897
19911
|
if (!isNil_1(nextChild) && !isNil_1(prevChild)) {
|
|
19898
19912
|
var _ref = nextChild.props || {},
|
|
19899
19913
|
nextChildren = _ref.children,
|
|
19900
|
-
nextProps = _objectWithoutProperties$
|
|
19914
|
+
nextProps = _objectWithoutProperties$c(_ref, _excluded$c);
|
|
19901
19915
|
var _ref2 = prevChild.props || {},
|
|
19902
19916
|
prevChildren = _ref2.children,
|
|
19903
|
-
prevProps = _objectWithoutProperties$
|
|
19917
|
+
prevProps = _objectWithoutProperties$c(_ref2, _excluded2$2);
|
|
19904
19918
|
if (nextChildren && prevChildren) {
|
|
19905
19919
|
return shallowEqual(nextProps, prevProps) && isChildrenEqual(nextChildren, prevChildren);
|
|
19906
19920
|
}
|
|
@@ -19942,10 +19956,10 @@ var parseChildIndex = function parseChildIndex(child, children) {
|
|
|
19942
19956
|
return toArray(children).indexOf(child);
|
|
19943
19957
|
};
|
|
19944
19958
|
|
|
19945
|
-
var _excluded$
|
|
19959
|
+
var _excluded$b = ["children", "width", "height", "viewBox", "className", "style"];
|
|
19946
19960
|
function _extends$m() { _extends$m = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$m.apply(this, arguments); }
|
|
19947
|
-
function _objectWithoutProperties$
|
|
19948
|
-
function _objectWithoutPropertiesLoose$
|
|
19961
|
+
function _objectWithoutProperties$b(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$b(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
19962
|
+
function _objectWithoutPropertiesLoose$b(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
19949
19963
|
function Surface(props) {
|
|
19950
19964
|
var children = props.children,
|
|
19951
19965
|
width = props.width,
|
|
@@ -19953,7 +19967,7 @@ function Surface(props) {
|
|
|
19953
19967
|
viewBox = props.viewBox,
|
|
19954
19968
|
className = props.className,
|
|
19955
19969
|
style = props.style,
|
|
19956
|
-
others = _objectWithoutProperties$
|
|
19970
|
+
others = _objectWithoutProperties$b(props, _excluded$b);
|
|
19957
19971
|
var svgView = viewBox || {
|
|
19958
19972
|
width: width,
|
|
19959
19973
|
height: height,
|
|
@@ -19970,14 +19984,14 @@ function Surface(props) {
|
|
|
19970
19984
|
}), /*#__PURE__*/React__default["default"].createElement("title", null, props.title), /*#__PURE__*/React__default["default"].createElement("desc", null, props.desc), children);
|
|
19971
19985
|
}
|
|
19972
19986
|
|
|
19973
|
-
var _excluded$
|
|
19987
|
+
var _excluded$a = ["children", "className"];
|
|
19974
19988
|
function _extends$l() { _extends$l = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$l.apply(this, arguments); }
|
|
19975
|
-
function _objectWithoutProperties$
|
|
19976
|
-
function _objectWithoutPropertiesLoose$
|
|
19989
|
+
function _objectWithoutProperties$a(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$a(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
19990
|
+
function _objectWithoutPropertiesLoose$a(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
19977
19991
|
var Layer = /*#__PURE__*/React__default["default"].forwardRef(function (props, ref) {
|
|
19978
19992
|
var children = props.children,
|
|
19979
19993
|
className = props.className,
|
|
19980
|
-
others = _objectWithoutProperties$
|
|
19994
|
+
others = _objectWithoutProperties$a(props, _excluded$a);
|
|
19981
19995
|
var layerClass = classNames('recharts-layer', className);
|
|
19982
19996
|
return /*#__PURE__*/React__default["default"].createElement("g", _extends$l({
|
|
19983
19997
|
className: layerClass
|
|
@@ -23392,16 +23406,7 @@ function stackOffsetWiggle(series, order) {
|
|
|
23392
23406
|
stackOffsetNone(series, order);
|
|
23393
23407
|
}
|
|
23394
23408
|
|
|
23395
|
-
function _typeof$u(obj) { "@babel/helpers - typeof"; return _typeof$u = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$u(obj); }
|
|
23396
|
-
var _excluded$c = ["type", "size", "sizeType"];
|
|
23397
23409
|
function _extends$k() { _extends$k = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$k.apply(this, arguments); }
|
|
23398
|
-
function ownKeys$s(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23399
|
-
function _objectSpread$s(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$s(Object(source), !0).forEach(function (key) { _defineProperty$u(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$s(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
23400
|
-
function _defineProperty$u(obj, key, value) { key = _toPropertyKey$t(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
23401
|
-
function _toPropertyKey$t(arg) { var key = _toPrimitive$t(arg, "string"); return _typeof$u(key) === "symbol" ? key : String(key); }
|
|
23402
|
-
function _toPrimitive$t(input, hint) { if (_typeof$u(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$u(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
23403
|
-
function _objectWithoutProperties$c(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$c(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
23404
|
-
function _objectWithoutPropertiesLoose$c(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
23405
23410
|
var symbolFactories = {
|
|
23406
23411
|
symbolCircle: symbolCircle,
|
|
23407
23412
|
symbolCross: symbolCross,
|
|
@@ -23440,35 +23445,31 @@ var calculateAreaSize = function calculateAreaSize(size, sizeType, type) {
|
|
|
23440
23445
|
return Math.PI * size * size / 4;
|
|
23441
23446
|
}
|
|
23442
23447
|
};
|
|
23448
|
+
var symbolsDefaultProps = {
|
|
23449
|
+
type: 'circle',
|
|
23450
|
+
size: 64,
|
|
23451
|
+
sizeType: 'area'
|
|
23452
|
+
};
|
|
23443
23453
|
var registerSymbol = function registerSymbol(key, factory) {
|
|
23444
23454
|
symbolFactories["symbol".concat(upperFirst_1(key))] = factory;
|
|
23445
23455
|
};
|
|
23446
|
-
var Symbols = function Symbols(
|
|
23447
|
-
var _ref$type = _ref.type,
|
|
23448
|
-
type = _ref$type === void 0 ? 'circle' : _ref$type,
|
|
23449
|
-
_ref$size = _ref.size,
|
|
23450
|
-
size = _ref$size === void 0 ? 64 : _ref$size,
|
|
23451
|
-
_ref$sizeType = _ref.sizeType,
|
|
23452
|
-
sizeType = _ref$sizeType === void 0 ? 'area' : _ref$sizeType,
|
|
23453
|
-
rest = _objectWithoutProperties$c(_ref, _excluded$c);
|
|
23454
|
-
var props = _objectSpread$s(_objectSpread$s({}, rest), {}, {
|
|
23455
|
-
type: type,
|
|
23456
|
-
size: size,
|
|
23457
|
-
sizeType: sizeType
|
|
23458
|
-
});
|
|
23459
|
-
|
|
23456
|
+
var Symbols = function Symbols(props) {
|
|
23460
23457
|
/**
|
|
23461
23458
|
* Calculate the path of curve
|
|
23462
23459
|
* @return {String} path
|
|
23463
23460
|
*/
|
|
23464
23461
|
var getPath = function getPath() {
|
|
23462
|
+
var size = props.size,
|
|
23463
|
+
sizeType = props.sizeType,
|
|
23464
|
+
type = props.type;
|
|
23465
23465
|
var symbolFactory = getSymbolFactory(type);
|
|
23466
23466
|
var symbol = Symbol$2().type(symbolFactory).size(calculateAreaSize(size, sizeType, type));
|
|
23467
23467
|
return symbol();
|
|
23468
23468
|
};
|
|
23469
23469
|
var className = props.className,
|
|
23470
23470
|
cx = props.cx,
|
|
23471
|
-
cy = props.cy
|
|
23471
|
+
cy = props.cy,
|
|
23472
|
+
size = props.size;
|
|
23472
23473
|
var filteredProps = filterProps(props, true);
|
|
23473
23474
|
if (cx === +cx && cy === +cy && size === +size) {
|
|
23474
23475
|
return /*#__PURE__*/React__default["default"].createElement("path", _extends$k({}, filteredProps, {
|
|
@@ -23479,34 +23480,35 @@ var Symbols = function Symbols(_ref) {
|
|
|
23479
23480
|
}
|
|
23480
23481
|
return null;
|
|
23481
23482
|
};
|
|
23483
|
+
Symbols.defaultProps = symbolsDefaultProps;
|
|
23482
23484
|
Symbols.registerSymbol = registerSymbol;
|
|
23483
23485
|
|
|
23484
|
-
function _typeof$
|
|
23486
|
+
function _typeof$q(obj) { "@babel/helpers - typeof"; return _typeof$q = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$q(obj); }
|
|
23485
23487
|
function _extends$j() { _extends$j = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$j.apply(this, arguments); }
|
|
23486
|
-
function ownKeys$
|
|
23487
|
-
function _objectSpread$
|
|
23488
|
-
function _classCallCheck$
|
|
23489
|
-
function _defineProperties$
|
|
23490
|
-
function _createClass$
|
|
23491
|
-
function _inherits$
|
|
23492
|
-
function _setPrototypeOf$
|
|
23493
|
-
function _createSuper$
|
|
23494
|
-
function _possibleConstructorReturn$
|
|
23495
|
-
function _assertThisInitialized$
|
|
23496
|
-
function _isNativeReflectConstruct$
|
|
23497
|
-
function _getPrototypeOf$
|
|
23498
|
-
function _defineProperty$
|
|
23499
|
-
function _toPropertyKey$
|
|
23500
|
-
function _toPrimitive$
|
|
23488
|
+
function ownKeys$o(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23489
|
+
function _objectSpread$o(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$o(Object(source), !0).forEach(function (key) { _defineProperty$q(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$o(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
23490
|
+
function _classCallCheck$a(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23491
|
+
function _defineProperties$a(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey$p(descriptor.key), descriptor); } }
|
|
23492
|
+
function _createClass$a(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$a(Constructor.prototype, protoProps); if (staticProps) _defineProperties$a(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
23493
|
+
function _inherits$8(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf$8(subClass, superClass); }
|
|
23494
|
+
function _setPrototypeOf$8(o, p) { _setPrototypeOf$8 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf$8(o, p); }
|
|
23495
|
+
function _createSuper$8(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct$8(); return function _createSuperInternal() { var Super = _getPrototypeOf$8(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf$8(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn$8(this, result); }; }
|
|
23496
|
+
function _possibleConstructorReturn$8(self, call) { if (call && (_typeof$q(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized$8(self); }
|
|
23497
|
+
function _assertThisInitialized$8(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
23498
|
+
function _isNativeReflectConstruct$8() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
23499
|
+
function _getPrototypeOf$8(o) { _getPrototypeOf$8 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$8(o); }
|
|
23500
|
+
function _defineProperty$q(obj, key, value) { key = _toPropertyKey$p(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
23501
|
+
function _toPropertyKey$p(arg) { var key = _toPrimitive$p(arg, "string"); return _typeof$q(key) === "symbol" ? key : String(key); }
|
|
23502
|
+
function _toPrimitive$p(input, hint) { if (_typeof$q(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$q(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
23501
23503
|
var SIZE = 32;
|
|
23502
23504
|
var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
23503
|
-
_inherits$
|
|
23504
|
-
var _super = _createSuper$
|
|
23505
|
+
_inherits$8(DefaultLegendContent, _PureComponent);
|
|
23506
|
+
var _super = _createSuper$8(DefaultLegendContent);
|
|
23505
23507
|
function DefaultLegendContent() {
|
|
23506
|
-
_classCallCheck$
|
|
23508
|
+
_classCallCheck$a(this, DefaultLegendContent);
|
|
23507
23509
|
return _super.apply(this, arguments);
|
|
23508
23510
|
}
|
|
23509
|
-
_createClass$
|
|
23511
|
+
_createClass$a(DefaultLegendContent, [{
|
|
23510
23512
|
key: "renderIcon",
|
|
23511
23513
|
value:
|
|
23512
23514
|
/**
|
|
@@ -23551,7 +23553,7 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23551
23553
|
});
|
|
23552
23554
|
}
|
|
23553
23555
|
if ( /*#__PURE__*/React__default["default"].isValidElement(data.legendIcon)) {
|
|
23554
|
-
var iconProps = _objectSpread$
|
|
23556
|
+
var iconProps = _objectSpread$o({}, data);
|
|
23555
23557
|
delete iconProps.legendIcon;
|
|
23556
23558
|
return /*#__PURE__*/React__default["default"].cloneElement(data.legendIcon, iconProps);
|
|
23557
23559
|
}
|
|
@@ -23599,7 +23601,7 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23599
23601
|
var finalFormatter = entry.formatter || formatter;
|
|
23600
23602
|
var className = classNames((_classNames = {
|
|
23601
23603
|
'recharts-legend-item': true
|
|
23602
|
-
}, _defineProperty$
|
|
23604
|
+
}, _defineProperty$q(_classNames, "legend-item-".concat(i), true), _defineProperty$q(_classNames, "inactive", entry.inactive), _classNames));
|
|
23603
23605
|
if (entry.type === 'none') {
|
|
23604
23606
|
return null;
|
|
23605
23607
|
}
|
|
@@ -23644,8 +23646,8 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23644
23646
|
}]);
|
|
23645
23647
|
return DefaultLegendContent;
|
|
23646
23648
|
}(React$3.PureComponent);
|
|
23647
|
-
_defineProperty$
|
|
23648
|
-
_defineProperty$
|
|
23649
|
+
_defineProperty$q(DefaultLegendContent, "displayName", 'Legend');
|
|
23650
|
+
_defineProperty$q(DefaultLegendContent, "defaultProps", {
|
|
23649
23651
|
iconSize: 14,
|
|
23650
23652
|
layout: 'horizontal',
|
|
23651
23653
|
align: 'center',
|
|
@@ -23653,25 +23655,25 @@ _defineProperty$t(DefaultLegendContent, "defaultProps", {
|
|
|
23653
23655
|
inactiveColor: '#ccc'
|
|
23654
23656
|
});
|
|
23655
23657
|
|
|
23656
|
-
function _typeof$
|
|
23657
|
-
var _excluded$
|
|
23658
|
-
function ownKeys$
|
|
23659
|
-
function _objectSpread$
|
|
23660
|
-
function _classCallCheck$
|
|
23661
|
-
function _defineProperties$
|
|
23662
|
-
function _createClass$
|
|
23663
|
-
function _inherits$
|
|
23664
|
-
function _setPrototypeOf$
|
|
23665
|
-
function _createSuper$
|
|
23666
|
-
function _possibleConstructorReturn$
|
|
23667
|
-
function _assertThisInitialized$
|
|
23668
|
-
function _isNativeReflectConstruct$
|
|
23669
|
-
function _getPrototypeOf$
|
|
23670
|
-
function _defineProperty$
|
|
23671
|
-
function _toPropertyKey$
|
|
23672
|
-
function _toPrimitive$
|
|
23673
|
-
function _objectWithoutProperties$
|
|
23674
|
-
function _objectWithoutPropertiesLoose$
|
|
23658
|
+
function _typeof$p(obj) { "@babel/helpers - typeof"; return _typeof$p = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$p(obj); }
|
|
23659
|
+
var _excluded$9 = ["ref"];
|
|
23660
|
+
function ownKeys$n(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23661
|
+
function _objectSpread$n(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$n(Object(source), !0).forEach(function (key) { _defineProperty$p(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$n(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
23662
|
+
function _classCallCheck$9(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23663
|
+
function _defineProperties$9(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey$o(descriptor.key), descriptor); } }
|
|
23664
|
+
function _createClass$9(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$9(Constructor.prototype, protoProps); if (staticProps) _defineProperties$9(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
23665
|
+
function _inherits$7(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf$7(subClass, superClass); }
|
|
23666
|
+
function _setPrototypeOf$7(o, p) { _setPrototypeOf$7 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf$7(o, p); }
|
|
23667
|
+
function _createSuper$7(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct$7(); return function _createSuperInternal() { var Super = _getPrototypeOf$7(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf$7(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn$7(this, result); }; }
|
|
23668
|
+
function _possibleConstructorReturn$7(self, call) { if (call && (_typeof$p(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized$7(self); }
|
|
23669
|
+
function _assertThisInitialized$7(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
23670
|
+
function _isNativeReflectConstruct$7() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
23671
|
+
function _getPrototypeOf$7(o) { _getPrototypeOf$7 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$7(o); }
|
|
23672
|
+
function _defineProperty$p(obj, key, value) { key = _toPropertyKey$o(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
23673
|
+
function _toPropertyKey$o(arg) { var key = _toPrimitive$o(arg, "string"); return _typeof$p(key) === "symbol" ? key : String(key); }
|
|
23674
|
+
function _toPrimitive$o(input, hint) { if (_typeof$p(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$p(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
23675
|
+
function _objectWithoutProperties$9(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$9(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
23676
|
+
function _objectWithoutPropertiesLoose$9(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
23675
23677
|
function defaultUniqBy$1(entry) {
|
|
23676
23678
|
return entry.value;
|
|
23677
23679
|
}
|
|
@@ -23692,27 +23694,27 @@ function renderContent$1(content, props) {
|
|
|
23692
23694
|
return /*#__PURE__*/React__default["default"].createElement(content, props);
|
|
23693
23695
|
}
|
|
23694
23696
|
props.ref;
|
|
23695
|
-
var otherProps = _objectWithoutProperties$
|
|
23697
|
+
var otherProps = _objectWithoutProperties$9(props, _excluded$9);
|
|
23696
23698
|
return /*#__PURE__*/React__default["default"].createElement(DefaultLegendContent, otherProps);
|
|
23697
23699
|
}
|
|
23698
23700
|
var EPS$2 = 1;
|
|
23699
23701
|
var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
23700
|
-
_inherits$
|
|
23701
|
-
var _super = _createSuper$
|
|
23702
|
+
_inherits$7(Legend, _PureComponent);
|
|
23703
|
+
var _super = _createSuper$7(Legend);
|
|
23702
23704
|
function Legend() {
|
|
23703
23705
|
var _this;
|
|
23704
|
-
_classCallCheck$
|
|
23706
|
+
_classCallCheck$9(this, Legend);
|
|
23705
23707
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
23706
23708
|
args[_key] = arguments[_key];
|
|
23707
23709
|
}
|
|
23708
23710
|
_this = _super.call.apply(_super, [this].concat(args));
|
|
23709
|
-
_defineProperty$
|
|
23711
|
+
_defineProperty$p(_assertThisInitialized$7(_this), "state", {
|
|
23710
23712
|
boxWidth: -1,
|
|
23711
23713
|
boxHeight: -1
|
|
23712
23714
|
});
|
|
23713
23715
|
return _this;
|
|
23714
23716
|
}
|
|
23715
|
-
_createClass$
|
|
23717
|
+
_createClass$9(Legend, [{
|
|
23716
23718
|
key: "componentDidMount",
|
|
23717
23719
|
value: function componentDidMount() {
|
|
23718
23720
|
this.updateBBox();
|
|
@@ -23787,7 +23789,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23787
23789
|
};
|
|
23788
23790
|
}
|
|
23789
23791
|
}
|
|
23790
|
-
return _objectSpread$
|
|
23792
|
+
return _objectSpread$n(_objectSpread$n({}, hPos), vPos);
|
|
23791
23793
|
}
|
|
23792
23794
|
}, {
|
|
23793
23795
|
key: "updateBBox",
|
|
@@ -23830,7 +23832,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23830
23832
|
wrapperStyle = _this$props2.wrapperStyle,
|
|
23831
23833
|
payloadUniqBy = _this$props2.payloadUniqBy,
|
|
23832
23834
|
payload = _this$props2.payload;
|
|
23833
|
-
var outerStyle = _objectSpread$
|
|
23835
|
+
var outerStyle = _objectSpread$n(_objectSpread$n({
|
|
23834
23836
|
position: 'absolute',
|
|
23835
23837
|
width: width || 'auto',
|
|
23836
23838
|
height: height || 'auto'
|
|
@@ -23841,7 +23843,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23841
23843
|
ref: function ref(node) {
|
|
23842
23844
|
_this2.wrapperNode = node;
|
|
23843
23845
|
}
|
|
23844
|
-
}, renderContent$1(content, _objectSpread$
|
|
23846
|
+
}, renderContent$1(content, _objectSpread$n(_objectSpread$n({}, this.props), {}, {
|
|
23845
23847
|
payload: getUniqPayload$1(payloadUniqBy, payload)
|
|
23846
23848
|
})));
|
|
23847
23849
|
}
|
|
@@ -23864,8 +23866,8 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23864
23866
|
}]);
|
|
23865
23867
|
return Legend;
|
|
23866
23868
|
}(React$3.PureComponent);
|
|
23867
|
-
_defineProperty$
|
|
23868
|
-
_defineProperty$
|
|
23869
|
+
_defineProperty$p(Legend, "displayName", 'Legend');
|
|
23870
|
+
_defineProperty$p(Legend, "defaultProps", {
|
|
23869
23871
|
iconSize: 14,
|
|
23870
23872
|
layout: 'horizontal',
|
|
23871
23873
|
align: 'center',
|
|
@@ -24429,13 +24431,13 @@ function setRafTimeout(callback) {
|
|
|
24429
24431
|
requestAnimationFrame(shouldUpdate);
|
|
24430
24432
|
}
|
|
24431
24433
|
|
|
24432
|
-
function _typeof$
|
|
24433
|
-
function _toArray(arr) { return _arrayWithHoles$
|
|
24434
|
-
function _nonIterableRest$
|
|
24435
|
-
function _unsupportedIterableToArray$
|
|
24436
|
-
function _arrayLikeToArray$
|
|
24434
|
+
function _typeof$o(obj) { "@babel/helpers - typeof"; return _typeof$o = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$o(obj); }
|
|
24435
|
+
function _toArray(arr) { return _arrayWithHoles$b(arr) || _iterableToArray$b(arr) || _unsupportedIterableToArray$i(arr) || _nonIterableRest$b(); }
|
|
24436
|
+
function _nonIterableRest$b() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24437
|
+
function _unsupportedIterableToArray$i(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$i(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$i(o, minLen); }
|
|
24438
|
+
function _arrayLikeToArray$i(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
24437
24439
|
function _iterableToArray$b(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24438
|
-
function _arrayWithHoles$
|
|
24440
|
+
function _arrayWithHoles$b(arr) { if (Array.isArray(arr)) return arr; }
|
|
24439
24441
|
function createAnimateManager() {
|
|
24440
24442
|
var currStyle = {};
|
|
24441
24443
|
var handleChange = function handleChange() {
|
|
@@ -24462,7 +24464,7 @@ function createAnimateManager() {
|
|
|
24462
24464
|
setRafTimeout(setStyle.bind(null, restStyles));
|
|
24463
24465
|
return;
|
|
24464
24466
|
}
|
|
24465
|
-
if (_typeof$
|
|
24467
|
+
if (_typeof$o(_style) === 'object') {
|
|
24466
24468
|
currStyle = _style;
|
|
24467
24469
|
handleChange(currStyle);
|
|
24468
24470
|
}
|
|
@@ -24489,12 +24491,12 @@ function createAnimateManager() {
|
|
|
24489
24491
|
};
|
|
24490
24492
|
}
|
|
24491
24493
|
|
|
24492
|
-
function _typeof$
|
|
24493
|
-
function ownKeys$
|
|
24494
|
-
function _objectSpread$
|
|
24495
|
-
function _defineProperty$
|
|
24496
|
-
function _toPropertyKey$
|
|
24497
|
-
function _toPrimitive$
|
|
24494
|
+
function _typeof$n(obj) { "@babel/helpers - typeof"; return _typeof$n = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$n(obj); }
|
|
24495
|
+
function ownKeys$m(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
24496
|
+
function _objectSpread$m(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$m(Object(source), !0).forEach(function (key) { _defineProperty$o(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$m(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
24497
|
+
function _defineProperty$o(obj, key, value) { key = _toPropertyKey$n(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
24498
|
+
function _toPropertyKey$n(arg) { var key = _toPrimitive$n(arg, "string"); return _typeof$n(key) === "symbol" ? key : String(key); }
|
|
24499
|
+
function _toPrimitive$n(input, hint) { if (_typeof$n(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$n(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
24498
24500
|
/* eslint no-console: 0 */
|
|
24499
24501
|
var PREFIX_LIST$1 = ['Webkit', 'Moz', 'O', 'ms'];
|
|
24500
24502
|
var IN_LINE_PREFIX_LIST = ['-webkit-', '-moz-', '-o-', '-ms-'];
|
|
@@ -24526,7 +24528,7 @@ var getDashCase = function getDashCase(name) {
|
|
|
24526
24528
|
*/
|
|
24527
24529
|
var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
24528
24530
|
if (IN_COMPATIBLE_PROPERTY.indexOf(name) === -1) {
|
|
24529
|
-
return _defineProperty$
|
|
24531
|
+
return _defineProperty$o({}, name, Number.isNaN(value) ? 0 : value);
|
|
24530
24532
|
}
|
|
24531
24533
|
var isTransition = name === 'transition';
|
|
24532
24534
|
var camelName = name.replace(/(\w)/, function (v) {
|
|
@@ -24537,7 +24539,7 @@ var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
|
24537
24539
|
if (isTransition) {
|
|
24538
24540
|
styleVal = value.replace(/(transform|transform-origin)/gim, "".concat(IN_LINE_PREFIX_LIST[i], "$1"));
|
|
24539
24541
|
}
|
|
24540
|
-
return _objectSpread$
|
|
24542
|
+
return _objectSpread$m(_objectSpread$m({}, result), {}, _defineProperty$o({}, property + camelName, styleVal));
|
|
24541
24543
|
}, {});
|
|
24542
24544
|
};
|
|
24543
24545
|
|
|
@@ -24547,7 +24549,7 @@ var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
|
24547
24549
|
*/
|
|
24548
24550
|
var mapObject = function mapObject(fn, obj) {
|
|
24549
24551
|
return Object.keys(obj).reduce(function (res, key) {
|
|
24550
|
-
return _objectSpread$
|
|
24552
|
+
return _objectSpread$m(_objectSpread$m({}, res), {}, _defineProperty$o({}, key, fn(key, obj[key])));
|
|
24551
24553
|
}, {});
|
|
24552
24554
|
};
|
|
24553
24555
|
|
|
@@ -24557,7 +24559,7 @@ var mapObject = function mapObject(fn, obj) {
|
|
|
24557
24559
|
*/
|
|
24558
24560
|
var translateStyle = function translateStyle(style) {
|
|
24559
24561
|
return Object.keys(style).reduce(function (res, key) {
|
|
24560
|
-
return _objectSpread$
|
|
24562
|
+
return _objectSpread$m(_objectSpread$m({}, res), generatePrefixStyle$1(key, res[key]));
|
|
24561
24563
|
}, style);
|
|
24562
24564
|
};
|
|
24563
24565
|
var getTransitionVal = function getTransitionVal(props, duration, easing) {
|
|
@@ -24585,16 +24587,16 @@ var warn$1 = function warn(condition, format, a, b, c, d, e, f) {
|
|
|
24585
24587
|
}
|
|
24586
24588
|
};
|
|
24587
24589
|
|
|
24588
|
-
function _slicedToArray$
|
|
24589
|
-
function _nonIterableRest$
|
|
24590
|
-
function _iterableToArrayLimit$
|
|
24591
|
-
function _arrayWithHoles$
|
|
24592
|
-
function _toConsumableArray$a(arr) { return _arrayWithoutHoles$a(arr) || _iterableToArray$a(arr) || _unsupportedIterableToArray$
|
|
24590
|
+
function _slicedToArray$a(arr, i) { return _arrayWithHoles$a(arr) || _iterableToArrayLimit$a(arr, i) || _unsupportedIterableToArray$h(arr, i) || _nonIterableRest$a(); }
|
|
24591
|
+
function _nonIterableRest$a() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24592
|
+
function _iterableToArrayLimit$a(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
24593
|
+
function _arrayWithHoles$a(arr) { if (Array.isArray(arr)) return arr; }
|
|
24594
|
+
function _toConsumableArray$a(arr) { return _arrayWithoutHoles$a(arr) || _iterableToArray$a(arr) || _unsupportedIterableToArray$h(arr) || _nonIterableSpread$a(); }
|
|
24593
24595
|
function _nonIterableSpread$a() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24594
|
-
function _unsupportedIterableToArray$
|
|
24596
|
+
function _unsupportedIterableToArray$h(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$h(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$h(o, minLen); }
|
|
24595
24597
|
function _iterableToArray$a(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24596
|
-
function _arrayWithoutHoles$a(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24597
|
-
function _arrayLikeToArray$
|
|
24598
|
+
function _arrayWithoutHoles$a(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$h(arr); }
|
|
24599
|
+
function _arrayLikeToArray$h(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
24598
24600
|
var ACCURACY = 1e-4;
|
|
24599
24601
|
var cubicBezierFactor = function cubicBezierFactor(c1, c2) {
|
|
24600
24602
|
return [0, 3 * c1, 3 * c2 - 6 * c1, 3 * c1 - 3 * c2 + 1];
|
|
@@ -24670,7 +24672,7 @@ var configBezier = function configBezier() {
|
|
|
24670
24672
|
var _easing$1$split$0$spl = easing[1].split(')')[0].split(',').map(function (x) {
|
|
24671
24673
|
return parseFloat(x);
|
|
24672
24674
|
});
|
|
24673
|
-
var _easing$1$split$0$spl2 = _slicedToArray$
|
|
24675
|
+
var _easing$1$split$0$spl2 = _slicedToArray$a(_easing$1$split$0$spl, 4);
|
|
24674
24676
|
x1 = _easing$1$split$0$spl2[0];
|
|
24675
24677
|
y1 = _easing$1$split$0$spl2[1];
|
|
24676
24678
|
x2 = _easing$1$split$0$spl2[2];
|
|
@@ -24763,22 +24765,22 @@ var configEasing = function configEasing() {
|
|
|
24763
24765
|
return null;
|
|
24764
24766
|
};
|
|
24765
24767
|
|
|
24766
|
-
function _typeof$
|
|
24767
|
-
function _toConsumableArray$9(arr) { return _arrayWithoutHoles$9(arr) || _iterableToArray$9(arr) || _unsupportedIterableToArray$
|
|
24768
|
+
function _typeof$m(obj) { "@babel/helpers - typeof"; return _typeof$m = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$m(obj); }
|
|
24769
|
+
function _toConsumableArray$9(arr) { return _arrayWithoutHoles$9(arr) || _iterableToArray$9(arr) || _unsupportedIterableToArray$g(arr) || _nonIterableSpread$9(); }
|
|
24768
24770
|
function _nonIterableSpread$9() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24769
24771
|
function _iterableToArray$9(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24770
|
-
function _arrayWithoutHoles$9(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24771
|
-
function ownKeys$
|
|
24772
|
-
function _objectSpread$
|
|
24773
|
-
function _defineProperty$
|
|
24774
|
-
function _toPropertyKey$
|
|
24775
|
-
function _toPrimitive$
|
|
24776
|
-
function _slicedToArray$
|
|
24777
|
-
function _nonIterableRest$
|
|
24778
|
-
function _unsupportedIterableToArray$
|
|
24779
|
-
function _arrayLikeToArray$
|
|
24780
|
-
function _iterableToArrayLimit$
|
|
24781
|
-
function _arrayWithHoles$
|
|
24772
|
+
function _arrayWithoutHoles$9(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$g(arr); }
|
|
24773
|
+
function ownKeys$l(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
24774
|
+
function _objectSpread$l(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$l(Object(source), !0).forEach(function (key) { _defineProperty$n(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$l(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
24775
|
+
function _defineProperty$n(obj, key, value) { key = _toPropertyKey$m(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
24776
|
+
function _toPropertyKey$m(arg) { var key = _toPrimitive$m(arg, "string"); return _typeof$m(key) === "symbol" ? key : String(key); }
|
|
24777
|
+
function _toPrimitive$m(input, hint) { if (_typeof$m(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$m(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
24778
|
+
function _slicedToArray$9(arr, i) { return _arrayWithHoles$9(arr) || _iterableToArrayLimit$9(arr, i) || _unsupportedIterableToArray$g(arr, i) || _nonIterableRest$9(); }
|
|
24779
|
+
function _nonIterableRest$9() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24780
|
+
function _unsupportedIterableToArray$g(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$g(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$g(o, minLen); }
|
|
24781
|
+
function _arrayLikeToArray$g(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
24782
|
+
function _iterableToArrayLimit$9(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
24783
|
+
function _arrayWithHoles$9(arr) { if (Array.isArray(arr)) return arr; }
|
|
24782
24784
|
var alpha = function alpha(begin, end, k) {
|
|
24783
24785
|
return begin + (end - begin) * k;
|
|
24784
24786
|
};
|
|
@@ -24796,10 +24798,10 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24796
24798
|
var nextStepVals = mapObject(function (key, val) {
|
|
24797
24799
|
if (needContinue(val)) {
|
|
24798
24800
|
var _easing = easing(val.from, val.to, val.velocity),
|
|
24799
|
-
_easing2 = _slicedToArray$
|
|
24801
|
+
_easing2 = _slicedToArray$9(_easing, 2),
|
|
24800
24802
|
newX = _easing2[0],
|
|
24801
24803
|
newV = _easing2[1];
|
|
24802
|
-
return _objectSpread$
|
|
24804
|
+
return _objectSpread$l(_objectSpread$l({}, val), {}, {
|
|
24803
24805
|
from: newX,
|
|
24804
24806
|
velocity: newV
|
|
24805
24807
|
});
|
|
@@ -24809,7 +24811,7 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24809
24811
|
if (steps < 1) {
|
|
24810
24812
|
return mapObject(function (key, val) {
|
|
24811
24813
|
if (needContinue(val)) {
|
|
24812
|
-
return _objectSpread$
|
|
24814
|
+
return _objectSpread$l(_objectSpread$l({}, val), {}, {
|
|
24813
24815
|
velocity: alpha(val.velocity, nextStepVals[key].velocity, steps),
|
|
24814
24816
|
from: alpha(val.from, nextStepVals[key].from, steps)
|
|
24815
24817
|
});
|
|
@@ -24824,10 +24826,10 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24824
24826
|
var configUpdate = (function (from, to, easing, duration, render) {
|
|
24825
24827
|
var interKeys = getIntersectionKeys(from, to);
|
|
24826
24828
|
var timingStyle = interKeys.reduce(function (res, key) {
|
|
24827
|
-
return _objectSpread$
|
|
24829
|
+
return _objectSpread$l(_objectSpread$l({}, res), {}, _defineProperty$n({}, key, [from[key], to[key]]));
|
|
24828
24830
|
}, {});
|
|
24829
24831
|
var stepperStyle = interKeys.reduce(function (res, key) {
|
|
24830
|
-
return _objectSpread$
|
|
24832
|
+
return _objectSpread$l(_objectSpread$l({}, res), {}, _defineProperty$n({}, key, {
|
|
24831
24833
|
from: from[key],
|
|
24832
24834
|
velocity: 0,
|
|
24833
24835
|
to: to[key]
|
|
@@ -24857,7 +24859,7 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24857
24859
|
var steps = deltaTime / easing.dt;
|
|
24858
24860
|
stepperStyle = calStepperVals(easing, stepperStyle, steps);
|
|
24859
24861
|
// get union set and add compatible prefix
|
|
24860
|
-
render(_objectSpread$
|
|
24862
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), getCurrStyle()));
|
|
24861
24863
|
preTime = now;
|
|
24862
24864
|
if (!shouldStopAnimation()) {
|
|
24863
24865
|
cafId = requestAnimationFrame(update);
|
|
@@ -24875,14 +24877,14 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24875
24877
|
}, timingStyle);
|
|
24876
24878
|
|
|
24877
24879
|
// get union set and add compatible prefix
|
|
24878
|
-
render(_objectSpread$
|
|
24880
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), currStyle));
|
|
24879
24881
|
if (t < 1) {
|
|
24880
24882
|
cafId = requestAnimationFrame(update);
|
|
24881
24883
|
} else {
|
|
24882
24884
|
var finalStyle = mapObject(function (key, val) {
|
|
24883
24885
|
return alpha.apply(void 0, _toConsumableArray$9(val).concat([easing(1)]));
|
|
24884
24886
|
}, timingStyle);
|
|
24885
|
-
render(_objectSpread$
|
|
24887
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), finalStyle));
|
|
24886
24888
|
}
|
|
24887
24889
|
};
|
|
24888
24890
|
update = easing.isStepper ? stepperUpdate : timingUpdate;
|
|
@@ -24898,37 +24900,37 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24898
24900
|
};
|
|
24899
24901
|
});
|
|
24900
24902
|
|
|
24901
|
-
function _typeof$
|
|
24902
|
-
var _excluded$
|
|
24903
|
-
function _objectWithoutProperties$
|
|
24904
|
-
function _objectWithoutPropertiesLoose$
|
|
24905
|
-
function _toConsumableArray$8(arr) { return _arrayWithoutHoles$8(arr) || _iterableToArray$8(arr) || _unsupportedIterableToArray$
|
|
24903
|
+
function _typeof$l(obj) { "@babel/helpers - typeof"; return _typeof$l = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$l(obj); }
|
|
24904
|
+
var _excluded$8 = ["children", "begin", "duration", "attributeName", "easing", "isActive", "steps", "from", "to", "canBegin", "onAnimationEnd", "shouldReAnimate", "onAnimationReStart"];
|
|
24905
|
+
function _objectWithoutProperties$8(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$8(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
24906
|
+
function _objectWithoutPropertiesLoose$8(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
24907
|
+
function _toConsumableArray$8(arr) { return _arrayWithoutHoles$8(arr) || _iterableToArray$8(arr) || _unsupportedIterableToArray$f(arr) || _nonIterableSpread$8(); }
|
|
24906
24908
|
function _nonIterableSpread$8() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24907
|
-
function _unsupportedIterableToArray$
|
|
24909
|
+
function _unsupportedIterableToArray$f(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$f(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$f(o, minLen); }
|
|
24908
24910
|
function _iterableToArray$8(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24909
|
-
function _arrayWithoutHoles$8(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24910
|
-
function _arrayLikeToArray$
|
|
24911
|
-
function ownKeys$
|
|
24912
|
-
function _objectSpread$
|
|
24913
|
-
function _defineProperty$
|
|
24914
|
-
function _classCallCheck$
|
|
24915
|
-
function _defineProperties$
|
|
24916
|
-
function _createClass$
|
|
24917
|
-
function _toPropertyKey$
|
|
24918
|
-
function _toPrimitive$
|
|
24919
|
-
function _inherits$
|
|
24920
|
-
function _setPrototypeOf$
|
|
24921
|
-
function _createSuper$
|
|
24922
|
-
function _possibleConstructorReturn$
|
|
24923
|
-
function _assertThisInitialized$
|
|
24924
|
-
function _isNativeReflectConstruct$
|
|
24925
|
-
function _getPrototypeOf$
|
|
24911
|
+
function _arrayWithoutHoles$8(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$f(arr); }
|
|
24912
|
+
function _arrayLikeToArray$f(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
24913
|
+
function ownKeys$k(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
24914
|
+
function _objectSpread$k(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$k(Object(source), !0).forEach(function (key) { _defineProperty$m(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$k(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
24915
|
+
function _defineProperty$m(obj, key, value) { key = _toPropertyKey$l(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
24916
|
+
function _classCallCheck$8(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
24917
|
+
function _defineProperties$8(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey$l(descriptor.key), descriptor); } }
|
|
24918
|
+
function _createClass$8(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$8(Constructor.prototype, protoProps); if (staticProps) _defineProperties$8(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
24919
|
+
function _toPropertyKey$l(arg) { var key = _toPrimitive$l(arg, "string"); return _typeof$l(key) === "symbol" ? key : String(key); }
|
|
24920
|
+
function _toPrimitive$l(input, hint) { if (_typeof$l(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$l(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
24921
|
+
function _inherits$6(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf$6(subClass, superClass); }
|
|
24922
|
+
function _setPrototypeOf$6(o, p) { _setPrototypeOf$6 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf$6(o, p); }
|
|
24923
|
+
function _createSuper$6(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct$6(); return function _createSuperInternal() { var Super = _getPrototypeOf$6(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf$6(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn$6(this, result); }; }
|
|
24924
|
+
function _possibleConstructorReturn$6(self, call) { if (call && (_typeof$l(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized$6(self); }
|
|
24925
|
+
function _assertThisInitialized$6(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
24926
|
+
function _isNativeReflectConstruct$6() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
24927
|
+
function _getPrototypeOf$6(o) { _getPrototypeOf$6 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$6(o); }
|
|
24926
24928
|
var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
24927
|
-
_inherits$
|
|
24928
|
-
var _super = _createSuper$
|
|
24929
|
+
_inherits$6(Animate, _PureComponent);
|
|
24930
|
+
var _super = _createSuper$6(Animate);
|
|
24929
24931
|
function Animate(props, context) {
|
|
24930
24932
|
var _this;
|
|
24931
|
-
_classCallCheck$
|
|
24933
|
+
_classCallCheck$8(this, Animate);
|
|
24932
24934
|
_this = _super.call(this, props, context);
|
|
24933
24935
|
var _this$props = _this.props,
|
|
24934
24936
|
isActive = _this$props.isActive,
|
|
@@ -24938,8 +24940,8 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24938
24940
|
steps = _this$props.steps,
|
|
24939
24941
|
children = _this$props.children,
|
|
24940
24942
|
duration = _this$props.duration;
|
|
24941
|
-
_this.handleStyleChange = _this.handleStyleChange.bind(_assertThisInitialized$
|
|
24942
|
-
_this.changeStyle = _this.changeStyle.bind(_assertThisInitialized$
|
|
24943
|
+
_this.handleStyleChange = _this.handleStyleChange.bind(_assertThisInitialized$6(_this));
|
|
24944
|
+
_this.changeStyle = _this.changeStyle.bind(_assertThisInitialized$6(_this));
|
|
24943
24945
|
if (!isActive || duration <= 0) {
|
|
24944
24946
|
_this.state = {
|
|
24945
24947
|
style: {}
|
|
@@ -24951,7 +24953,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24951
24953
|
style: to
|
|
24952
24954
|
};
|
|
24953
24955
|
}
|
|
24954
|
-
return _possibleConstructorReturn$
|
|
24956
|
+
return _possibleConstructorReturn$6(_this);
|
|
24955
24957
|
}
|
|
24956
24958
|
if (steps && steps.length) {
|
|
24957
24959
|
_this.state = {
|
|
@@ -24962,10 +24964,10 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24962
24964
|
_this.state = {
|
|
24963
24965
|
style: from
|
|
24964
24966
|
};
|
|
24965
|
-
return _possibleConstructorReturn$
|
|
24967
|
+
return _possibleConstructorReturn$6(_this);
|
|
24966
24968
|
}
|
|
24967
24969
|
_this.state = {
|
|
24968
|
-
style: attributeName ? _defineProperty$
|
|
24970
|
+
style: attributeName ? _defineProperty$m({}, attributeName, from) : from
|
|
24969
24971
|
};
|
|
24970
24972
|
} else {
|
|
24971
24973
|
_this.state = {
|
|
@@ -24974,7 +24976,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24974
24976
|
}
|
|
24975
24977
|
return _this;
|
|
24976
24978
|
}
|
|
24977
|
-
_createClass$
|
|
24979
|
+
_createClass$8(Animate, [{
|
|
24978
24980
|
key: "componentDidMount",
|
|
24979
24981
|
value: function componentDidMount() {
|
|
24980
24982
|
var _this$props2 = this.props,
|
|
@@ -25002,7 +25004,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25002
25004
|
}
|
|
25003
25005
|
if (!isActive) {
|
|
25004
25006
|
var newState = {
|
|
25005
|
-
style: attributeName ? _defineProperty$
|
|
25007
|
+
style: attributeName ? _defineProperty$m({}, attributeName, to) : to
|
|
25006
25008
|
};
|
|
25007
25009
|
if (this.state && style) {
|
|
25008
25010
|
if (attributeName && style[attributeName] !== to || !attributeName && style !== to) {
|
|
@@ -25025,14 +25027,14 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25025
25027
|
var from = isTriggered || shouldReAnimate ? currentFrom : prevProps.to;
|
|
25026
25028
|
if (this.state && style) {
|
|
25027
25029
|
var _newState = {
|
|
25028
|
-
style: attributeName ? _defineProperty$
|
|
25030
|
+
style: attributeName ? _defineProperty$m({}, attributeName, from) : from
|
|
25029
25031
|
};
|
|
25030
25032
|
if (attributeName && [attributeName] !== from || !attributeName && style !== from) {
|
|
25031
25033
|
// eslint-disable-next-line react/no-did-update-set-state
|
|
25032
25034
|
this.setState(_newState);
|
|
25033
25035
|
}
|
|
25034
25036
|
}
|
|
25035
|
-
this.runAnimation(_objectSpread$
|
|
25037
|
+
this.runAnimation(_objectSpread$k(_objectSpread$k({}, this.props), {}, {
|
|
25036
25038
|
from: from,
|
|
25037
25039
|
begin: 0
|
|
25038
25040
|
}));
|
|
@@ -25115,7 +25117,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25115
25117
|
}), duration]);
|
|
25116
25118
|
}
|
|
25117
25119
|
var transition = getTransitionVal(properties, duration, easing);
|
|
25118
|
-
var newStyle = _objectSpread$
|
|
25120
|
+
var newStyle = _objectSpread$k(_objectSpread$k(_objectSpread$k({}, preItem.style), style), {}, {
|
|
25119
25121
|
transition: transition
|
|
25120
25122
|
});
|
|
25121
25123
|
return [].concat(_toConsumableArray$8(sequence), [newStyle, duration, onAnimationEnd]).filter(identity$9);
|
|
@@ -25147,9 +25149,9 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25147
25149
|
this.runStepAnimation(props);
|
|
25148
25150
|
return;
|
|
25149
25151
|
}
|
|
25150
|
-
var to = attributeName ? _defineProperty$
|
|
25152
|
+
var to = attributeName ? _defineProperty$m({}, attributeName, propsTo) : propsTo;
|
|
25151
25153
|
var transition = getTransitionVal(Object.keys(to), duration, easing);
|
|
25152
|
-
manager.start([onAnimationStart, begin, _objectSpread$
|
|
25154
|
+
manager.start([onAnimationStart, begin, _objectSpread$k(_objectSpread$k({}, to), {}, {
|
|
25153
25155
|
transition: transition
|
|
25154
25156
|
}), duration, onAnimationEnd]);
|
|
25155
25157
|
}
|
|
@@ -25170,7 +25172,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25170
25172
|
_this$props4.onAnimationEnd;
|
|
25171
25173
|
_this$props4.shouldReAnimate;
|
|
25172
25174
|
_this$props4.onAnimationReStart;
|
|
25173
|
-
var others = _objectWithoutProperties$
|
|
25175
|
+
var others = _objectWithoutProperties$8(_this$props4, _excluded$8);
|
|
25174
25176
|
var count = React$3.Children.count(children);
|
|
25175
25177
|
// eslint-disable-next-line react/destructuring-assignment
|
|
25176
25178
|
var stateStyle = translateStyle(this.state.style);
|
|
@@ -25185,8 +25187,8 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25185
25187
|
_container$props$styl = _container$props.style,
|
|
25186
25188
|
style = _container$props$styl === void 0 ? {} : _container$props$styl,
|
|
25187
25189
|
className = _container$props.className;
|
|
25188
|
-
var res = /*#__PURE__*/React$3.cloneElement(container, _objectSpread$
|
|
25189
|
-
style: _objectSpread$
|
|
25190
|
+
var res = /*#__PURE__*/React$3.cloneElement(container, _objectSpread$k(_objectSpread$k({}, others), {}, {
|
|
25191
|
+
style: _objectSpread$k(_objectSpread$k({}, style), stateStyle),
|
|
25190
25192
|
className: className
|
|
25191
25193
|
}));
|
|
25192
25194
|
return res;
|
|
@@ -25711,10 +25713,10 @@ var defineProperty$2 = (function() {
|
|
|
25711
25713
|
} catch (e) {}
|
|
25712
25714
|
}());
|
|
25713
25715
|
|
|
25714
|
-
var _defineProperty$
|
|
25716
|
+
var _defineProperty$l = defineProperty$2;
|
|
25715
25717
|
|
|
25716
25718
|
var constant$1 = constant_1,
|
|
25717
|
-
defineProperty$1 = _defineProperty$
|
|
25719
|
+
defineProperty$1 = _defineProperty$l,
|
|
25718
25720
|
identity$7 = identity_1;
|
|
25719
25721
|
|
|
25720
25722
|
/**
|
|
@@ -25891,18 +25893,18 @@ var sortBy_1 = sortBy;
|
|
|
25891
25893
|
/**
|
|
25892
25894
|
* @fileOverview Default Tooltip Content
|
|
25893
25895
|
*/
|
|
25894
|
-
function _typeof$
|
|
25895
|
-
function _slicedToArray$
|
|
25896
|
-
function _nonIterableRest$
|
|
25897
|
-
function _unsupportedIterableToArray$
|
|
25898
|
-
function _arrayLikeToArray$
|
|
25899
|
-
function _iterableToArrayLimit$
|
|
25900
|
-
function _arrayWithHoles$
|
|
25901
|
-
function ownKeys$
|
|
25902
|
-
function _objectSpread$
|
|
25903
|
-
function _defineProperty$
|
|
25904
|
-
function _toPropertyKey$
|
|
25905
|
-
function _toPrimitive$
|
|
25896
|
+
function _typeof$k(obj) { "@babel/helpers - typeof"; return _typeof$k = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$k(obj); }
|
|
25897
|
+
function _slicedToArray$8(arr, i) { return _arrayWithHoles$8(arr) || _iterableToArrayLimit$8(arr, i) || _unsupportedIterableToArray$e(arr, i) || _nonIterableRest$8(); }
|
|
25898
|
+
function _nonIterableRest$8() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
25899
|
+
function _unsupportedIterableToArray$e(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$e(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$e(o, minLen); }
|
|
25900
|
+
function _arrayLikeToArray$e(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
25901
|
+
function _iterableToArrayLimit$8(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
25902
|
+
function _arrayWithHoles$8(arr) { if (Array.isArray(arr)) return arr; }
|
|
25903
|
+
function ownKeys$j(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
25904
|
+
function _objectSpread$j(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$j(Object(source), !0).forEach(function (key) { _defineProperty$k(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$j(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
25905
|
+
function _defineProperty$k(obj, key, value) { key = _toPropertyKey$k(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
25906
|
+
function _toPropertyKey$k(arg) { var key = _toPrimitive$k(arg, "string"); return _typeof$k(key) === "symbol" ? key : String(key); }
|
|
25907
|
+
function _toPrimitive$k(input, hint) { if (_typeof$k(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$k(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
25906
25908
|
function defaultFormatter(value) {
|
|
25907
25909
|
return isArray_1(value) && isNumOrStr(value[0]) && isNumOrStr(value[1]) ? value.join(' ~ ') : value;
|
|
25908
25910
|
}
|
|
@@ -25932,7 +25934,7 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25932
25934
|
if (entry.type === 'none') {
|
|
25933
25935
|
return null;
|
|
25934
25936
|
}
|
|
25935
|
-
var finalItemStyle = _objectSpread$
|
|
25937
|
+
var finalItemStyle = _objectSpread$j({
|
|
25936
25938
|
display: 'block',
|
|
25937
25939
|
paddingTop: 4,
|
|
25938
25940
|
paddingBottom: 4,
|
|
@@ -25946,7 +25948,7 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25946
25948
|
if (finalFormatter && finalValue != null && finalName != null) {
|
|
25947
25949
|
var formatted = finalFormatter(value, name, entry, i, payload);
|
|
25948
25950
|
if (Array.isArray(formatted)) {
|
|
25949
|
-
var _formatted = _slicedToArray$
|
|
25951
|
+
var _formatted = _slicedToArray$8(formatted, 2);
|
|
25950
25952
|
finalValue = _formatted[0];
|
|
25951
25953
|
finalName = _formatted[1];
|
|
25952
25954
|
} else {
|
|
@@ -25978,14 +25980,14 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25978
25980
|
}
|
|
25979
25981
|
return null;
|
|
25980
25982
|
};
|
|
25981
|
-
var finalStyle = _objectSpread$
|
|
25983
|
+
var finalStyle = _objectSpread$j({
|
|
25982
25984
|
margin: 0,
|
|
25983
25985
|
padding: 10,
|
|
25984
25986
|
backgroundColor: '#fff',
|
|
25985
25987
|
border: '1px solid #ccc',
|
|
25986
25988
|
whiteSpace: 'nowrap'
|
|
25987
25989
|
}, contentStyle);
|
|
25988
|
-
var finalLabelStyle = _objectSpread$
|
|
25990
|
+
var finalLabelStyle = _objectSpread$j({
|
|
25989
25991
|
margin: 0
|
|
25990
25992
|
}, labelStyle);
|
|
25991
25993
|
var hasLabel = !isNil_1(label);
|
|
@@ -26026,22 +26028,18 @@ var Global = {
|
|
|
26026
26028
|
}
|
|
26027
26029
|
};
|
|
26028
26030
|
|
|
26029
|
-
function _typeof$
|
|
26030
|
-
function ownKeys$
|
|
26031
|
-
function _objectSpread$
|
|
26032
|
-
function
|
|
26033
|
-
function
|
|
26034
|
-
function
|
|
26035
|
-
function
|
|
26036
|
-
function
|
|
26037
|
-
function
|
|
26038
|
-
function
|
|
26039
|
-
function
|
|
26040
|
-
function
|
|
26041
|
-
function _getPrototypeOf$6(o) { _getPrototypeOf$6 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$6(o); }
|
|
26042
|
-
function _defineProperty$m(obj, key, value) { key = _toPropertyKey$m(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
26043
|
-
function _toPropertyKey$m(arg) { var key = _toPrimitive$m(arg, "string"); return _typeof$m(key) === "symbol" ? key : String(key); }
|
|
26044
|
-
function _toPrimitive$m(input, hint) { if (_typeof$m(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$m(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
26031
|
+
function _typeof$j(obj) { "@babel/helpers - typeof"; return _typeof$j = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$j(obj); }
|
|
26032
|
+
function ownKeys$i(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
26033
|
+
function _objectSpread$i(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$i(Object(source), !0).forEach(function (key) { _defineProperty$j(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$i(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
26034
|
+
function _defineProperty$j(obj, key, value) { key = _toPropertyKey$j(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
26035
|
+
function _toPropertyKey$j(arg) { var key = _toPrimitive$j(arg, "string"); return _typeof$j(key) === "symbol" ? key : String(key); }
|
|
26036
|
+
function _toPrimitive$j(input, hint) { if (_typeof$j(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$j(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
26037
|
+
function _slicedToArray$7(arr, i) { return _arrayWithHoles$7(arr) || _iterableToArrayLimit$7(arr, i) || _unsupportedIterableToArray$d(arr, i) || _nonIterableRest$7(); }
|
|
26038
|
+
function _nonIterableRest$7() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
26039
|
+
function _unsupportedIterableToArray$d(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$d(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$d(o, minLen); }
|
|
26040
|
+
function _arrayLikeToArray$d(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
26041
|
+
function _iterableToArrayLimit$7(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
26042
|
+
function _arrayWithHoles$7(arr) { if (Array.isArray(arr)) return arr; }
|
|
26045
26043
|
var CLS_PREFIX = 'recharts-tooltip-wrapper';
|
|
26046
26044
|
var EPS$1 = 1;
|
|
26047
26045
|
function defaultUniqBy(entry) {
|
|
@@ -26065,204 +26063,7 @@ function renderContent(content, props) {
|
|
|
26065
26063
|
}
|
|
26066
26064
|
return /*#__PURE__*/React__default["default"].createElement(DefaultTooltipContent, props);
|
|
26067
26065
|
}
|
|
26068
|
-
var
|
|
26069
|
-
_inherits$6(Tooltip, _PureComponent);
|
|
26070
|
-
var _super = _createSuper$6(Tooltip);
|
|
26071
|
-
function Tooltip() {
|
|
26072
|
-
var _this;
|
|
26073
|
-
_classCallCheck$8(this, Tooltip);
|
|
26074
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
26075
|
-
args[_key] = arguments[_key];
|
|
26076
|
-
}
|
|
26077
|
-
_this = _super.call.apply(_super, [this].concat(args));
|
|
26078
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "state", {
|
|
26079
|
-
boxWidth: -1,
|
|
26080
|
-
boxHeight: -1,
|
|
26081
|
-
dismissed: false,
|
|
26082
|
-
dismissedAtCoordinate: {
|
|
26083
|
-
x: 0,
|
|
26084
|
-
y: 0
|
|
26085
|
-
}
|
|
26086
|
-
});
|
|
26087
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "handleKeyDown", function (event) {
|
|
26088
|
-
if (event.key === 'Escape') {
|
|
26089
|
-
_this.setState({
|
|
26090
|
-
dismissed: true,
|
|
26091
|
-
dismissedAtCoordinate: _objectSpread$l(_objectSpread$l({}, _this.state.dismissedAtCoordinate), {}, {
|
|
26092
|
-
x: _this.props.coordinate.x,
|
|
26093
|
-
y: _this.props.coordinate.y
|
|
26094
|
-
})
|
|
26095
|
-
});
|
|
26096
|
-
}
|
|
26097
|
-
});
|
|
26098
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "getTranslate", function (_ref) {
|
|
26099
|
-
var key = _ref.key,
|
|
26100
|
-
tooltipDimension = _ref.tooltipDimension,
|
|
26101
|
-
viewBoxDimension = _ref.viewBoxDimension;
|
|
26102
|
-
var _this$props = _this.props,
|
|
26103
|
-
allowEscapeViewBox = _this$props.allowEscapeViewBox,
|
|
26104
|
-
reverseDirection = _this$props.reverseDirection,
|
|
26105
|
-
coordinate = _this$props.coordinate,
|
|
26106
|
-
offset = _this$props.offset,
|
|
26107
|
-
position = _this$props.position,
|
|
26108
|
-
viewBox = _this$props.viewBox;
|
|
26109
|
-
if (position && isNumber(position[key])) {
|
|
26110
|
-
return position[key];
|
|
26111
|
-
}
|
|
26112
|
-
var negative = coordinate[key] - tooltipDimension - offset;
|
|
26113
|
-
var positive = coordinate[key] + offset;
|
|
26114
|
-
if (allowEscapeViewBox[key]) {
|
|
26115
|
-
return reverseDirection[key] ? negative : positive;
|
|
26116
|
-
}
|
|
26117
|
-
if (reverseDirection[key]) {
|
|
26118
|
-
var _tooltipBoundary = negative;
|
|
26119
|
-
var _viewBoxBoundary = viewBox[key];
|
|
26120
|
-
if (_tooltipBoundary < _viewBoxBoundary) {
|
|
26121
|
-
return Math.max(positive, viewBox[key]);
|
|
26122
|
-
}
|
|
26123
|
-
return Math.max(negative, viewBox[key]);
|
|
26124
|
-
}
|
|
26125
|
-
var tooltipBoundary = positive + tooltipDimension;
|
|
26126
|
-
var viewBoxBoundary = viewBox[key] + viewBoxDimension;
|
|
26127
|
-
if (tooltipBoundary > viewBoxBoundary) {
|
|
26128
|
-
return Math.max(negative, viewBox[key]);
|
|
26129
|
-
}
|
|
26130
|
-
return Math.max(positive, viewBox[key]);
|
|
26131
|
-
});
|
|
26132
|
-
return _this;
|
|
26133
|
-
}
|
|
26134
|
-
_createClass$8(Tooltip, [{
|
|
26135
|
-
key: "componentDidMount",
|
|
26136
|
-
value: function componentDidMount() {
|
|
26137
|
-
this.updateBBox();
|
|
26138
|
-
}
|
|
26139
|
-
}, {
|
|
26140
|
-
key: "componentWillUnmount",
|
|
26141
|
-
value: function componentWillUnmount() {
|
|
26142
|
-
document.removeEventListener('keydown', this.handleKeyDown);
|
|
26143
|
-
}
|
|
26144
|
-
}, {
|
|
26145
|
-
key: "componentDidUpdate",
|
|
26146
|
-
value: function componentDidUpdate() {
|
|
26147
|
-
this.updateBBox();
|
|
26148
|
-
}
|
|
26149
|
-
}, {
|
|
26150
|
-
key: "updateBBox",
|
|
26151
|
-
value: function updateBBox() {
|
|
26152
|
-
var _this$state = this.state,
|
|
26153
|
-
boxWidth = _this$state.boxWidth,
|
|
26154
|
-
boxHeight = _this$state.boxHeight,
|
|
26155
|
-
dismissed = _this$state.dismissed;
|
|
26156
|
-
if (dismissed) {
|
|
26157
|
-
document.removeEventListener('keydown', this.handleKeyDown);
|
|
26158
|
-
if (this.props.coordinate.x !== this.state.dismissedAtCoordinate.x || this.props.coordinate.y !== this.state.dismissedAtCoordinate.y) {
|
|
26159
|
-
this.setState({
|
|
26160
|
-
dismissed: false
|
|
26161
|
-
});
|
|
26162
|
-
}
|
|
26163
|
-
} else {
|
|
26164
|
-
document.addEventListener('keydown', this.handleKeyDown);
|
|
26165
|
-
}
|
|
26166
|
-
if (this.wrapperNode && this.wrapperNode.getBoundingClientRect) {
|
|
26167
|
-
var box = this.wrapperNode.getBoundingClientRect();
|
|
26168
|
-
if (Math.abs(box.width - boxWidth) > EPS$1 || Math.abs(box.height - boxHeight) > EPS$1) {
|
|
26169
|
-
this.setState({
|
|
26170
|
-
boxWidth: box.width,
|
|
26171
|
-
boxHeight: box.height
|
|
26172
|
-
});
|
|
26173
|
-
}
|
|
26174
|
-
} else if (boxWidth !== -1 || boxHeight !== -1) {
|
|
26175
|
-
this.setState({
|
|
26176
|
-
boxWidth: -1,
|
|
26177
|
-
boxHeight: -1
|
|
26178
|
-
});
|
|
26179
|
-
}
|
|
26180
|
-
}
|
|
26181
|
-
}, {
|
|
26182
|
-
key: "render",
|
|
26183
|
-
value: function render() {
|
|
26184
|
-
var _classNames,
|
|
26185
|
-
_this2 = this;
|
|
26186
|
-
var _this$props2 = this.props,
|
|
26187
|
-
payload = _this$props2.payload,
|
|
26188
|
-
isAnimationActive = _this$props2.isAnimationActive,
|
|
26189
|
-
animationDuration = _this$props2.animationDuration,
|
|
26190
|
-
animationEasing = _this$props2.animationEasing,
|
|
26191
|
-
filterNull = _this$props2.filterNull,
|
|
26192
|
-
payloadUniqBy = _this$props2.payloadUniqBy;
|
|
26193
|
-
var finalPayload = getUniqPayload(payloadUniqBy, filterNull && payload && payload.length ? payload.filter(function (entry) {
|
|
26194
|
-
return !isNil_1(entry.value);
|
|
26195
|
-
}) : payload);
|
|
26196
|
-
var hasPayload = finalPayload && finalPayload.length;
|
|
26197
|
-
var _this$props3 = this.props,
|
|
26198
|
-
content = _this$props3.content,
|
|
26199
|
-
viewBox = _this$props3.viewBox,
|
|
26200
|
-
coordinate = _this$props3.coordinate,
|
|
26201
|
-
position = _this$props3.position,
|
|
26202
|
-
active = _this$props3.active,
|
|
26203
|
-
wrapperStyle = _this$props3.wrapperStyle;
|
|
26204
|
-
var outerStyle = _objectSpread$l({
|
|
26205
|
-
pointerEvents: 'none',
|
|
26206
|
-
visibility: !this.state.dismissed && active && hasPayload ? 'visible' : 'hidden',
|
|
26207
|
-
position: 'absolute',
|
|
26208
|
-
top: 0,
|
|
26209
|
-
left: 0
|
|
26210
|
-
}, wrapperStyle);
|
|
26211
|
-
var translateX, translateY;
|
|
26212
|
-
if (position && isNumber(position.x) && isNumber(position.y)) {
|
|
26213
|
-
translateX = position.x;
|
|
26214
|
-
translateY = position.y;
|
|
26215
|
-
} else {
|
|
26216
|
-
var _this$state2 = this.state,
|
|
26217
|
-
boxWidth = _this$state2.boxWidth,
|
|
26218
|
-
boxHeight = _this$state2.boxHeight;
|
|
26219
|
-
if (boxWidth > 0 && boxHeight > 0 && coordinate) {
|
|
26220
|
-
translateX = this.getTranslate({
|
|
26221
|
-
key: 'x',
|
|
26222
|
-
tooltipDimension: boxWidth,
|
|
26223
|
-
viewBoxDimension: viewBox.width
|
|
26224
|
-
});
|
|
26225
|
-
translateY = this.getTranslate({
|
|
26226
|
-
key: 'y',
|
|
26227
|
-
tooltipDimension: boxHeight,
|
|
26228
|
-
viewBoxDimension: viewBox.height
|
|
26229
|
-
});
|
|
26230
|
-
} else {
|
|
26231
|
-
outerStyle.visibility = 'hidden';
|
|
26232
|
-
}
|
|
26233
|
-
}
|
|
26234
|
-
outerStyle = _objectSpread$l(_objectSpread$l({}, translateStyle({
|
|
26235
|
-
transform: this.props.useTranslate3d ? "translate3d(".concat(translateX, "px, ").concat(translateY, "px, 0)") : "translate(".concat(translateX, "px, ").concat(translateY, "px)")
|
|
26236
|
-
})), outerStyle);
|
|
26237
|
-
if (isAnimationActive && active) {
|
|
26238
|
-
outerStyle = _objectSpread$l(_objectSpread$l({}, translateStyle({
|
|
26239
|
-
transition: "transform ".concat(animationDuration, "ms ").concat(animationEasing)
|
|
26240
|
-
})), outerStyle);
|
|
26241
|
-
}
|
|
26242
|
-
var cls = classNames(CLS_PREFIX, (_classNames = {}, _defineProperty$m(_classNames, "".concat(CLS_PREFIX, "-right"), isNumber(translateX) && coordinate && isNumber(coordinate.x) && translateX >= coordinate.x), _defineProperty$m(_classNames, "".concat(CLS_PREFIX, "-left"), isNumber(translateX) && coordinate && isNumber(coordinate.x) && translateX < coordinate.x), _defineProperty$m(_classNames, "".concat(CLS_PREFIX, "-bottom"), isNumber(translateY) && coordinate && isNumber(coordinate.y) && translateY >= coordinate.y), _defineProperty$m(_classNames, "".concat(CLS_PREFIX, "-top"), isNumber(translateY) && coordinate && isNumber(coordinate.y) && translateY < coordinate.y), _classNames));
|
|
26243
|
-
return (
|
|
26244
|
-
/*#__PURE__*/
|
|
26245
|
-
// ESLint is disabled to allow listening to the `Escape` key. Refer to
|
|
26246
|
-
// https://github.com/recharts/recharts/pull/2925
|
|
26247
|
-
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
|
|
26248
|
-
React__default["default"].createElement("div", {
|
|
26249
|
-
tabIndex: -1,
|
|
26250
|
-
role: "dialog",
|
|
26251
|
-
className: cls,
|
|
26252
|
-
style: outerStyle,
|
|
26253
|
-
ref: function ref(node) {
|
|
26254
|
-
_this2.wrapperNode = node;
|
|
26255
|
-
}
|
|
26256
|
-
}, renderContent(content, _objectSpread$l(_objectSpread$l({}, this.props), {}, {
|
|
26257
|
-
payload: finalPayload
|
|
26258
|
-
})))
|
|
26259
|
-
);
|
|
26260
|
-
}
|
|
26261
|
-
}]);
|
|
26262
|
-
return Tooltip;
|
|
26263
|
-
}(React$3.PureComponent);
|
|
26264
|
-
_defineProperty$m(Tooltip$1, "displayName", 'Tooltip');
|
|
26265
|
-
_defineProperty$m(Tooltip$1, "defaultProps", {
|
|
26066
|
+
var tooltipDefaultProps = {
|
|
26266
26067
|
active: false,
|
|
26267
26068
|
allowEscapeViewBox: {
|
|
26268
26069
|
x: false,
|
|
@@ -26283,6 +26084,9 @@ _defineProperty$m(Tooltip$1, "defaultProps", {
|
|
|
26283
26084
|
x: 0,
|
|
26284
26085
|
y: 0
|
|
26285
26086
|
},
|
|
26087
|
+
// this doesn't exist on TooltipProps
|
|
26088
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
26089
|
+
// @ts-ignore
|
|
26286
26090
|
cursorStyle: {},
|
|
26287
26091
|
separator: ' : ',
|
|
26288
26092
|
wrapperStyle: {},
|
|
@@ -26296,7 +26100,173 @@ _defineProperty$m(Tooltip$1, "defaultProps", {
|
|
|
26296
26100
|
animationDuration: 400,
|
|
26297
26101
|
filterNull: true,
|
|
26298
26102
|
useTranslate3d: false
|
|
26299
|
-
}
|
|
26103
|
+
};
|
|
26104
|
+
var Tooltip$1 = function Tooltip(props) {
|
|
26105
|
+
var _classNames;
|
|
26106
|
+
var _useState = React$3.useState(-1),
|
|
26107
|
+
_useState2 = _slicedToArray$7(_useState, 2),
|
|
26108
|
+
boxWidth = _useState2[0],
|
|
26109
|
+
setBoxWidth = _useState2[1];
|
|
26110
|
+
var _useState3 = React$3.useState(-1),
|
|
26111
|
+
_useState4 = _slicedToArray$7(_useState3, 2),
|
|
26112
|
+
boxHeight = _useState4[0],
|
|
26113
|
+
setBoxHeight = _useState4[1];
|
|
26114
|
+
var _useState5 = React$3.useState(false),
|
|
26115
|
+
_useState6 = _slicedToArray$7(_useState5, 2),
|
|
26116
|
+
dismissed = _useState6[0],
|
|
26117
|
+
setDismissed = _useState6[1];
|
|
26118
|
+
var _useState7 = React$3.useState({
|
|
26119
|
+
x: 0,
|
|
26120
|
+
y: 0
|
|
26121
|
+
}),
|
|
26122
|
+
_useState8 = _slicedToArray$7(_useState7, 2),
|
|
26123
|
+
dismissedAtCoordinate = _useState8[0],
|
|
26124
|
+
setDismissedAtCoordinate = _useState8[1];
|
|
26125
|
+
var wrapperNode = React$3.useRef();
|
|
26126
|
+
var allowEscapeViewBox = props.allowEscapeViewBox,
|
|
26127
|
+
reverseDirection = props.reverseDirection,
|
|
26128
|
+
coordinate = props.coordinate,
|
|
26129
|
+
offset = props.offset,
|
|
26130
|
+
position = props.position,
|
|
26131
|
+
viewBox = props.viewBox;
|
|
26132
|
+
var handleKeyDown = React$3.useCallback(function (event) {
|
|
26133
|
+
if (event.key === 'Escape') {
|
|
26134
|
+
setDismissed(true);
|
|
26135
|
+
setDismissedAtCoordinate(function (prev) {
|
|
26136
|
+
return _objectSpread$i(_objectSpread$i({}, prev), {}, {
|
|
26137
|
+
x: coordinate === null || coordinate === void 0 ? void 0 : coordinate.x,
|
|
26138
|
+
y: coordinate === null || coordinate === void 0 ? void 0 : coordinate.y
|
|
26139
|
+
});
|
|
26140
|
+
});
|
|
26141
|
+
}
|
|
26142
|
+
}, [coordinate === null || coordinate === void 0 ? void 0 : coordinate.x, coordinate === null || coordinate === void 0 ? void 0 : coordinate.y]);
|
|
26143
|
+
React$3.useEffect(function () {
|
|
26144
|
+
var updateBBox = function updateBBox() {
|
|
26145
|
+
if (dismissed) {
|
|
26146
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
26147
|
+
if ((coordinate === null || coordinate === void 0 ? void 0 : coordinate.x) !== dismissedAtCoordinate.x || (coordinate === null || coordinate === void 0 ? void 0 : coordinate.y) !== dismissedAtCoordinate.y) {
|
|
26148
|
+
setDismissed(false);
|
|
26149
|
+
}
|
|
26150
|
+
} else {
|
|
26151
|
+
document.addEventListener('keydown', handleKeyDown);
|
|
26152
|
+
}
|
|
26153
|
+
if (wrapperNode.current && wrapperNode.current.getBoundingClientRect) {
|
|
26154
|
+
var box = wrapperNode.current.getBoundingClientRect();
|
|
26155
|
+
if (Math.abs(box.width - boxWidth) > EPS$1 || Math.abs(box.height - boxHeight) > EPS$1) {
|
|
26156
|
+
setBoxWidth(box.width);
|
|
26157
|
+
setBoxHeight(box.height);
|
|
26158
|
+
}
|
|
26159
|
+
} else if (boxWidth !== -1 || boxHeight !== -1) {
|
|
26160
|
+
setBoxWidth(-1);
|
|
26161
|
+
setBoxHeight(-1);
|
|
26162
|
+
}
|
|
26163
|
+
};
|
|
26164
|
+
updateBBox();
|
|
26165
|
+
return function () {
|
|
26166
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
26167
|
+
};
|
|
26168
|
+
}, [boxHeight, boxWidth, coordinate, dismissed, dismissedAtCoordinate.x, dismissedAtCoordinate.y, handleKeyDown]);
|
|
26169
|
+
var getTranslate = function getTranslate(_ref) {
|
|
26170
|
+
var key = _ref.key,
|
|
26171
|
+
tooltipDimension = _ref.tooltipDimension,
|
|
26172
|
+
viewBoxDimension = _ref.viewBoxDimension;
|
|
26173
|
+
if (position && isNumber(position[key])) {
|
|
26174
|
+
return position[key];
|
|
26175
|
+
}
|
|
26176
|
+
var negative = coordinate[key] - tooltipDimension - offset;
|
|
26177
|
+
var positive = coordinate[key] + offset;
|
|
26178
|
+
if (allowEscapeViewBox !== null && allowEscapeViewBox !== void 0 && allowEscapeViewBox[key]) {
|
|
26179
|
+
return reverseDirection[key] ? negative : positive;
|
|
26180
|
+
}
|
|
26181
|
+
if (reverseDirection !== null && reverseDirection !== void 0 && reverseDirection[key]) {
|
|
26182
|
+
var _tooltipBoundary = negative;
|
|
26183
|
+
var _viewBoxBoundary = viewBox[key];
|
|
26184
|
+
if (_tooltipBoundary < _viewBoxBoundary) {
|
|
26185
|
+
return Math.max(positive, viewBox[key]);
|
|
26186
|
+
}
|
|
26187
|
+
return Math.max(negative, viewBox[key]);
|
|
26188
|
+
}
|
|
26189
|
+
var tooltipBoundary = positive + tooltipDimension;
|
|
26190
|
+
var viewBoxBoundary = viewBox[key] + viewBoxDimension;
|
|
26191
|
+
if (tooltipBoundary > viewBoxBoundary) {
|
|
26192
|
+
return Math.max(negative, viewBox[key]);
|
|
26193
|
+
}
|
|
26194
|
+
return Math.max(positive, viewBox[key]);
|
|
26195
|
+
};
|
|
26196
|
+
var payload = props.payload,
|
|
26197
|
+
payloadUniqBy = props.payloadUniqBy,
|
|
26198
|
+
filterNull = props.filterNull,
|
|
26199
|
+
active = props.active,
|
|
26200
|
+
wrapperStyle = props.wrapperStyle,
|
|
26201
|
+
useTranslate3d = props.useTranslate3d,
|
|
26202
|
+
isAnimationActive = props.isAnimationActive,
|
|
26203
|
+
animationDuration = props.animationDuration,
|
|
26204
|
+
animationEasing = props.animationEasing;
|
|
26205
|
+
var finalPayload = getUniqPayload(payloadUniqBy, filterNull && payload && payload.length ? payload.filter(function (entry) {
|
|
26206
|
+
return !isNil_1(entry.value);
|
|
26207
|
+
}) : payload);
|
|
26208
|
+
var hasPayload = finalPayload && finalPayload.length;
|
|
26209
|
+
var content = props.content;
|
|
26210
|
+
var outerStyle = _objectSpread$i({
|
|
26211
|
+
pointerEvents: 'none',
|
|
26212
|
+
visibility: !dismissed && active && hasPayload ? 'visible' : 'hidden',
|
|
26213
|
+
position: 'absolute',
|
|
26214
|
+
top: 0,
|
|
26215
|
+
left: 0
|
|
26216
|
+
}, wrapperStyle);
|
|
26217
|
+
var translateX, translateY;
|
|
26218
|
+
if (position && isNumber(position.x) && isNumber(position.y)) {
|
|
26219
|
+
translateX = position.x;
|
|
26220
|
+
translateY = position.y;
|
|
26221
|
+
} else if (boxWidth > 0 && boxHeight > 0 && coordinate) {
|
|
26222
|
+
translateX = getTranslate({
|
|
26223
|
+
key: 'x',
|
|
26224
|
+
tooltipDimension: boxWidth,
|
|
26225
|
+
viewBoxDimension: viewBox.width
|
|
26226
|
+
});
|
|
26227
|
+
translateY = getTranslate({
|
|
26228
|
+
key: 'y',
|
|
26229
|
+
tooltipDimension: boxHeight,
|
|
26230
|
+
viewBoxDimension: viewBox.height
|
|
26231
|
+
});
|
|
26232
|
+
} else {
|
|
26233
|
+
outerStyle.visibility = 'hidden';
|
|
26234
|
+
}
|
|
26235
|
+
outerStyle = _objectSpread$i(_objectSpread$i({}, translateStyle({
|
|
26236
|
+
transform: useTranslate3d ? "translate3d(".concat(translateX, "px, ").concat(translateY, "px, 0)") : "translate(".concat(translateX, "px, ").concat(translateY, "px)")
|
|
26237
|
+
})), outerStyle);
|
|
26238
|
+
if (isAnimationActive && active) {
|
|
26239
|
+
outerStyle = _objectSpread$i(_objectSpread$i({}, translateStyle({
|
|
26240
|
+
transition: "transform ".concat(animationDuration, "ms ").concat(animationEasing)
|
|
26241
|
+
})), outerStyle);
|
|
26242
|
+
}
|
|
26243
|
+
var cls = classNames(CLS_PREFIX, (_classNames = {}, _defineProperty$j(_classNames, "".concat(CLS_PREFIX, "-right"), isNumber(translateX) && coordinate && isNumber(coordinate.x) && translateX >= coordinate.x), _defineProperty$j(_classNames, "".concat(CLS_PREFIX, "-left"), isNumber(translateX) && coordinate && isNumber(coordinate.x) && translateX < coordinate.x), _defineProperty$j(_classNames, "".concat(CLS_PREFIX, "-bottom"), isNumber(translateY) && coordinate && isNumber(coordinate.y) && translateY >= coordinate.y), _defineProperty$j(_classNames, "".concat(CLS_PREFIX, "-top"), isNumber(translateY) && coordinate && isNumber(coordinate.y) && translateY < coordinate.y), _classNames));
|
|
26244
|
+
return (
|
|
26245
|
+
/*#__PURE__*/
|
|
26246
|
+
// ESLint is disabled to allow listening to the `Escape` key. Refer to
|
|
26247
|
+
// https://github.com/recharts/recharts/pull/2925
|
|
26248
|
+
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
|
|
26249
|
+
React__default["default"].createElement("div", {
|
|
26250
|
+
tabIndex: -1,
|
|
26251
|
+
role: "dialog",
|
|
26252
|
+
className: cls,
|
|
26253
|
+
style: outerStyle,
|
|
26254
|
+
ref: wrapperNode
|
|
26255
|
+
}, renderContent(content, _objectSpread$i(_objectSpread$i({}, props), {}, {
|
|
26256
|
+
payload: finalPayload
|
|
26257
|
+
})))
|
|
26258
|
+
);
|
|
26259
|
+
};
|
|
26260
|
+
|
|
26261
|
+
// needs to be set so that renderByOrder can find the correct handler function
|
|
26262
|
+
Tooltip$1.displayName = 'Tooltip';
|
|
26263
|
+
|
|
26264
|
+
/**
|
|
26265
|
+
* needs to be set so that renderByOrder can access an have default values for
|
|
26266
|
+
* children.props when there are no props set by the consumer
|
|
26267
|
+
* doesn't work if using default parameters
|
|
26268
|
+
*/
|
|
26269
|
+
Tooltip$1.defaultProps = tooltipDefaultProps;
|
|
26300
26270
|
|
|
26301
26271
|
var root = _root;
|
|
26302
26272
|
|
|
@@ -31866,12 +31836,12 @@ module.exports = exports['default'];
|
|
|
31866
31836
|
|
|
31867
31837
|
var reduceCSSCalc = /*@__PURE__*/getDefaultExportFromCjs(dist.exports);
|
|
31868
31838
|
|
|
31869
|
-
function _typeof$
|
|
31870
|
-
function ownKeys$
|
|
31871
|
-
function _objectSpread$
|
|
31872
|
-
function _defineProperty$
|
|
31873
|
-
function _toPropertyKey$
|
|
31874
|
-
function _toPrimitive$
|
|
31839
|
+
function _typeof$i(obj) { "@babel/helpers - typeof"; return _typeof$i = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$i(obj); }
|
|
31840
|
+
function ownKeys$h(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
31841
|
+
function _objectSpread$h(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$h(Object(source), !0).forEach(function (key) { _defineProperty$i(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$h(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
31842
|
+
function _defineProperty$i(obj, key, value) { key = _toPropertyKey$i(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
31843
|
+
function _toPropertyKey$i(arg) { var key = _toPrimitive$i(arg, "string"); return _typeof$i(key) === "symbol" ? key : String(key); }
|
|
31844
|
+
function _toPrimitive$i(input, hint) { if (_typeof$i(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$i(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
31875
31845
|
function _toConsumableArray$7(arr) { return _arrayWithoutHoles$7(arr) || _iterableToArray$7(arr) || _unsupportedIterableToArray$b(arr) || _nonIterableSpread$7(); }
|
|
31876
31846
|
function _nonIterableSpread$7() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
31877
31847
|
function _unsupportedIterableToArray$b(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$b(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$b(o, minLen); }
|
|
@@ -31939,7 +31909,7 @@ var getStringSize = function getStringSize(text) {
|
|
|
31939
31909
|
}
|
|
31940
31910
|
// Need to use CSS Object Model (CSSOM) to be able to comply with Content Security Policy (CSP)
|
|
31941
31911
|
// https://en.wikipedia.org/wiki/Content_Security_Policy
|
|
31942
|
-
var measurementSpanStyle = _objectSpread$
|
|
31912
|
+
var measurementSpanStyle = _objectSpread$h(_objectSpread$h({}, SPAN_STYLE), style);
|
|
31943
31913
|
Object.keys(measurementSpanStyle).map(function (styleKey) {
|
|
31944
31914
|
measurementSpan.style[styleKey] = measurementSpanStyle[styleKey];
|
|
31945
31915
|
return styleKey;
|
|
@@ -31994,11 +31964,10 @@ var calculateChartCoordinate = function calculateChartCoordinate(event, offset)
|
|
|
31994
31964
|
};
|
|
31995
31965
|
};
|
|
31996
31966
|
|
|
31997
|
-
var _excluded$
|
|
31998
|
-
_excluded2$3 = ["dx", "dy", "angle", "className", "breakAll"];
|
|
31967
|
+
var _excluded$7 = ["dx", "dy", "textAnchor", "verticalAnchor", "scaleToFit", "angle", "lineHeight", "capHeight", "className", "breakAll"];
|
|
31999
31968
|
function _extends$h() { _extends$h = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$h.apply(this, arguments); }
|
|
32000
|
-
function _objectWithoutProperties$
|
|
32001
|
-
function _objectWithoutPropertiesLoose$
|
|
31969
|
+
function _objectWithoutProperties$7(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$7(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
31970
|
+
function _objectWithoutPropertiesLoose$7(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
32002
31971
|
function _slicedToArray$5(arr, i) { return _arrayWithHoles$5(arr) || _iterableToArrayLimit$5(arr, i) || _unsupportedIterableToArray$a(arr, i) || _nonIterableRest$5(); }
|
|
32003
31972
|
function _nonIterableRest$5() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
32004
31973
|
function _unsupportedIterableToArray$a(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$a(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$a(o, minLen); }
|
|
@@ -32152,46 +32121,45 @@ var getWordsByLines = function getWordsByLines(_ref4) {
|
|
|
32152
32121
|
}
|
|
32153
32122
|
return getWordsWithoutCalculate(children);
|
|
32154
32123
|
};
|
|
32155
|
-
var
|
|
32156
|
-
|
|
32157
|
-
|
|
32158
|
-
|
|
32159
|
-
|
|
32160
|
-
|
|
32161
|
-
|
|
32162
|
-
|
|
32163
|
-
|
|
32164
|
-
|
|
32165
|
-
|
|
32166
|
-
|
|
32167
|
-
|
|
32168
|
-
textAnchor = _ref5$textAnchor === void 0 ? 'start' : _ref5$textAnchor,
|
|
32169
|
-
_ref5$verticalAnchor = _ref5.verticalAnchor,
|
|
32170
|
-
verticalAnchor = _ref5$verticalAnchor === void 0 ? 'end' : _ref5$verticalAnchor,
|
|
32171
|
-
_ref5$fill = _ref5.fill,
|
|
32172
|
-
fill = _ref5$fill === void 0 ? DEFAULT_FILL : _ref5$fill,
|
|
32173
|
-
props = _objectWithoutProperties$9(_ref5, _excluded$9);
|
|
32124
|
+
var textDefaultProps = {
|
|
32125
|
+
x: 0,
|
|
32126
|
+
y: 0,
|
|
32127
|
+
lineHeight: '1em',
|
|
32128
|
+
capHeight: '0.71em',
|
|
32129
|
+
// Magic number from d3
|
|
32130
|
+
scaleToFit: false,
|
|
32131
|
+
textAnchor: 'start',
|
|
32132
|
+
verticalAnchor: 'end',
|
|
32133
|
+
// Maintain compat with existing charts / default SVG behavior
|
|
32134
|
+
fill: '#808080'
|
|
32135
|
+
};
|
|
32136
|
+
var Text = function Text(props) {
|
|
32174
32137
|
var wordsByLines = React$3.useMemo(function () {
|
|
32175
32138
|
return getWordsByLines({
|
|
32176
32139
|
breakAll: props.breakAll,
|
|
32177
32140
|
children: props.children,
|
|
32178
32141
|
maxLines: props.maxLines,
|
|
32179
|
-
scaleToFit: scaleToFit,
|
|
32142
|
+
scaleToFit: props.scaleToFit,
|
|
32180
32143
|
style: props.style,
|
|
32181
32144
|
width: props.width
|
|
32182
32145
|
});
|
|
32183
|
-
}, [props.breakAll, props.children, props.maxLines, scaleToFit, props.style, props.width]);
|
|
32146
|
+
}, [props.breakAll, props.children, props.maxLines, props.scaleToFit, props.style, props.width]);
|
|
32184
32147
|
var dx = props.dx,
|
|
32185
32148
|
dy = props.dy,
|
|
32149
|
+
textAnchor = props.textAnchor,
|
|
32150
|
+
verticalAnchor = props.verticalAnchor,
|
|
32151
|
+
scaleToFit = props.scaleToFit,
|
|
32186
32152
|
angle = props.angle,
|
|
32153
|
+
lineHeight = props.lineHeight,
|
|
32154
|
+
capHeight = props.capHeight,
|
|
32187
32155
|
className = props.className,
|
|
32188
32156
|
breakAll = props.breakAll,
|
|
32189
|
-
textProps = _objectWithoutProperties$
|
|
32190
|
-
if (!isNumOrStr(
|
|
32157
|
+
textProps = _objectWithoutProperties$7(props, _excluded$7);
|
|
32158
|
+
if (!isNumOrStr(textProps.x) || !isNumOrStr(textProps.y)) {
|
|
32191
32159
|
return null;
|
|
32192
32160
|
}
|
|
32193
|
-
var x =
|
|
32194
|
-
var y =
|
|
32161
|
+
var x = textProps.x + (isNumber(dx) ? dx : 0);
|
|
32162
|
+
var y = textProps.y + (isNumber(dy) ? dy : 0);
|
|
32195
32163
|
var startDy;
|
|
32196
32164
|
switch (verticalAnchor) {
|
|
32197
32165
|
case 'start':
|
|
@@ -32221,7 +32189,7 @@ var Text = function Text(_ref5) {
|
|
|
32221
32189
|
y: y,
|
|
32222
32190
|
className: classNames('recharts-text', className),
|
|
32223
32191
|
textAnchor: textAnchor,
|
|
32224
|
-
fill: fill.includes('url') ?
|
|
32192
|
+
fill: textProps.fill.includes('url') ? textDefaultProps.fill : textProps.fill
|
|
32225
32193
|
}), wordsByLines.map(function (line, index) {
|
|
32226
32194
|
return (
|
|
32227
32195
|
/*#__PURE__*/
|
|
@@ -32234,6 +32202,7 @@ var Text = function Text(_ref5) {
|
|
|
32234
32202
|
);
|
|
32235
32203
|
}));
|
|
32236
32204
|
};
|
|
32205
|
+
Text.defaultProps = textDefaultProps;
|
|
32237
32206
|
|
|
32238
32207
|
var baseIsEqual = _baseIsEqual;
|
|
32239
32208
|
|
|
@@ -38501,7 +38470,7 @@ function getTickValuesFixedDomainFn(_ref7, tickCount) {
|
|
|
38501
38470
|
var getNiceTickValues = memoize(getNiceTickValuesFn);
|
|
38502
38471
|
var getTickValuesFixedDomain = memoize(getTickValuesFixedDomainFn);
|
|
38503
38472
|
|
|
38504
|
-
var _excluded$
|
|
38473
|
+
var _excluded$6 = ["offset", "layout", "width", "dataKey", "data", "dataPointFormatter", "xAxis", "yAxis"];
|
|
38505
38474
|
function _extends$g() { _extends$g = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$g.apply(this, arguments); }
|
|
38506
38475
|
function _slicedToArray$3(arr, i) { return _arrayWithHoles$3(arr) || _iterableToArrayLimit$3(arr, i) || _unsupportedIterableToArray$7(arr, i) || _nonIterableRest$3(); }
|
|
38507
38476
|
function _nonIterableRest$3() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -38509,8 +38478,8 @@ function _unsupportedIterableToArray$7(o, minLen) { if (!o) return; if (typeof o
|
|
|
38509
38478
|
function _arrayLikeToArray$7(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
38510
38479
|
function _iterableToArrayLimit$3(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
38511
38480
|
function _arrayWithHoles$3(arr) { if (Array.isArray(arr)) return arr; }
|
|
38512
|
-
function _objectWithoutProperties$
|
|
38513
|
-
function _objectWithoutPropertiesLoose$
|
|
38481
|
+
function _objectWithoutProperties$6(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$6(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
38482
|
+
function _objectWithoutPropertiesLoose$6(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
38514
38483
|
function ErrorBar(props) {
|
|
38515
38484
|
var offset = props.offset,
|
|
38516
38485
|
layout = props.layout,
|
|
@@ -38520,7 +38489,7 @@ function ErrorBar(props) {
|
|
|
38520
38489
|
dataPointFormatter = props.dataPointFormatter,
|
|
38521
38490
|
xAxis = props.xAxis,
|
|
38522
38491
|
yAxis = props.yAxis,
|
|
38523
|
-
others = _objectWithoutProperties$
|
|
38492
|
+
others = _objectWithoutProperties$6(props, _excluded$6);
|
|
38524
38493
|
var svgProps = filterProps(others);
|
|
38525
38494
|
var errorBars = data.map(function (entry, i) {
|
|
38526
38495
|
var _dataPointFormatter = dataPointFormatter(entry, dataKey),
|
|
@@ -38631,18 +38600,18 @@ ErrorBar.defaultProps = {
|
|
|
38631
38600
|
};
|
|
38632
38601
|
ErrorBar.displayName = 'ErrorBar';
|
|
38633
38602
|
|
|
38634
|
-
function _typeof$
|
|
38603
|
+
function _typeof$h(obj) { "@babel/helpers - typeof"; return _typeof$h = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$h(obj); }
|
|
38635
38604
|
function _toConsumableArray$4(arr) { return _arrayWithoutHoles$4(arr) || _iterableToArray$4(arr) || _unsupportedIterableToArray$6(arr) || _nonIterableSpread$4(); }
|
|
38636
38605
|
function _nonIterableSpread$4() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
38637
38606
|
function _unsupportedIterableToArray$6(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$6(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$6(o, minLen); }
|
|
38638
38607
|
function _iterableToArray$4(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
38639
38608
|
function _arrayWithoutHoles$4(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$6(arr); }
|
|
38640
38609
|
function _arrayLikeToArray$6(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
38641
|
-
function ownKeys$
|
|
38642
|
-
function _objectSpread$
|
|
38643
|
-
function _defineProperty$
|
|
38644
|
-
function _toPropertyKey$
|
|
38645
|
-
function _toPrimitive$
|
|
38610
|
+
function ownKeys$g(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
38611
|
+
function _objectSpread$g(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$g(Object(source), !0).forEach(function (key) { _defineProperty$h(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$g(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
38612
|
+
function _defineProperty$h(obj, key, value) { key = _toPropertyKey$h(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
38613
|
+
function _toPropertyKey$h(arg) { var key = _toPrimitive$h(arg, "string"); return _typeof$h(key) === "symbol" ? key : String(key); }
|
|
38614
|
+
function _toPrimitive$h(input, hint) { if (_typeof$h(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$h(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
38646
38615
|
// TODO: Cause of circular dependency. Needs refactor.
|
|
38647
38616
|
// import { RadiusAxisProps, AngleAxisProps } from '../polar/types';
|
|
38648
38617
|
function getValueByDataKey(obj, dataKey, defaultValue) {
|
|
@@ -38813,7 +38782,7 @@ var getLegendProps = function getLegendProps(_ref2) {
|
|
|
38813
38782
|
};
|
|
38814
38783
|
});
|
|
38815
38784
|
}
|
|
38816
|
-
return _objectSpread$
|
|
38785
|
+
return _objectSpread$g(_objectSpread$g(_objectSpread$g({}, legendItem.props), Legend.getWithHeight(legendItem, legendWidth)), {}, {
|
|
38817
38786
|
payload: legendData,
|
|
38818
38787
|
item: legendItem
|
|
38819
38788
|
});
|
|
@@ -38967,10 +38936,10 @@ var appendOffsetOfLegend = function appendOffsetOfLegend(offset, items, props, l
|
|
|
38967
38936
|
verticalAlign = legendProps.verticalAlign,
|
|
38968
38937
|
layout = legendProps.layout;
|
|
38969
38938
|
if ((layout === 'vertical' || layout === 'horizontal' && verticalAlign === 'middle') && isNumber(offset[align])) {
|
|
38970
|
-
newOffset = _objectSpread$
|
|
38939
|
+
newOffset = _objectSpread$g(_objectSpread$g({}, offset), {}, _defineProperty$h({}, align, newOffset[align] + (box.width || 0)));
|
|
38971
38940
|
}
|
|
38972
38941
|
if ((layout === 'horizontal' || layout === 'vertical' && align === 'center') && isNumber(offset[verticalAlign])) {
|
|
38973
|
-
newOffset = _objectSpread$
|
|
38942
|
+
newOffset = _objectSpread$g(_objectSpread$g({}, offset), {}, _defineProperty$h({}, verticalAlign, newOffset[verticalAlign] + (box.height || 0)));
|
|
38974
38943
|
}
|
|
38975
38944
|
}
|
|
38976
38945
|
return newOffset;
|
|
@@ -39396,14 +39365,14 @@ var getStackGroupsByAxisId = function getStackGroupsByAxisId(data, _items, numer
|
|
|
39396
39365
|
items: [item]
|
|
39397
39366
|
};
|
|
39398
39367
|
}
|
|
39399
|
-
return _objectSpread$
|
|
39368
|
+
return _objectSpread$g(_objectSpread$g({}, result), {}, _defineProperty$h({}, axisId, parentGroup));
|
|
39400
39369
|
}, {});
|
|
39401
39370
|
return Object.keys(stackGroups).reduce(function (result, axisId) {
|
|
39402
39371
|
var group = stackGroups[axisId];
|
|
39403
39372
|
if (group.hasStack) {
|
|
39404
39373
|
group.stackGroups = Object.keys(group.stackGroups).reduce(function (res, stackId) {
|
|
39405
39374
|
var g = group.stackGroups[stackId];
|
|
39406
|
-
return _objectSpread$
|
|
39375
|
+
return _objectSpread$g(_objectSpread$g({}, res), {}, _defineProperty$h({}, stackId, {
|
|
39407
39376
|
numericAxisId: numericAxisId,
|
|
39408
39377
|
cateAxisId: cateAxisId,
|
|
39409
39378
|
items: g.items,
|
|
@@ -39411,7 +39380,7 @@ var getStackGroupsByAxisId = function getStackGroupsByAxisId(data, _items, numer
|
|
|
39411
39380
|
}));
|
|
39412
39381
|
}, {});
|
|
39413
39382
|
}
|
|
39414
|
-
return _objectSpread$
|
|
39383
|
+
return _objectSpread$g(_objectSpread$g({}, result), {}, _defineProperty$h({}, axisId, group));
|
|
39415
39384
|
}, {});
|
|
39416
39385
|
};
|
|
39417
39386
|
|
|
@@ -39625,7 +39594,7 @@ var getTooltipItem = function getTooltipItem(graphicalItem, payload) {
|
|
|
39625
39594
|
formatter = _graphicalItem$props.formatter,
|
|
39626
39595
|
tooltipType = _graphicalItem$props.tooltipType,
|
|
39627
39596
|
chartType = _graphicalItem$props.chartType;
|
|
39628
|
-
return _objectSpread$
|
|
39597
|
+
return _objectSpread$g(_objectSpread$g({}, filterProps(graphicalItem)), {}, {
|
|
39629
39598
|
dataKey: dataKey,
|
|
39630
39599
|
unit: unit,
|
|
39631
39600
|
formatter: formatter,
|
|
@@ -39638,12 +39607,12 @@ var getTooltipItem = function getTooltipItem(graphicalItem, payload) {
|
|
|
39638
39607
|
});
|
|
39639
39608
|
};
|
|
39640
39609
|
|
|
39641
|
-
function _typeof$
|
|
39642
|
-
function ownKeys$
|
|
39643
|
-
function _objectSpread$
|
|
39644
|
-
function _defineProperty$
|
|
39645
|
-
function _toPropertyKey$
|
|
39646
|
-
function _toPrimitive$
|
|
39610
|
+
function _typeof$g(obj) { "@babel/helpers - typeof"; return _typeof$g = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$g(obj); }
|
|
39611
|
+
function ownKeys$f(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
39612
|
+
function _objectSpread$f(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$f(Object(source), !0).forEach(function (key) { _defineProperty$g(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$f(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
39613
|
+
function _defineProperty$g(obj, key, value) { key = _toPropertyKey$g(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
39614
|
+
function _toPropertyKey$g(arg) { var key = _toPrimitive$g(arg, "string"); return _typeof$g(key) === "symbol" ? key : String(key); }
|
|
39615
|
+
function _toPrimitive$g(input, hint) { if (_typeof$g(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$g(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
39647
39616
|
var RADIAN = Math.PI / 180;
|
|
39648
39617
|
var radianToDegree = function radianToDegree(angleInRadian) {
|
|
39649
39618
|
return angleInRadian * 180 / Math.PI;
|
|
@@ -39748,7 +39717,7 @@ var inRangeOfSector = function inRangeOfSector(_ref5, sector) {
|
|
|
39748
39717
|
inRange = formatAngle >= endAngle && formatAngle <= startAngle;
|
|
39749
39718
|
}
|
|
39750
39719
|
if (inRange) {
|
|
39751
|
-
return _objectSpread$
|
|
39720
|
+
return _objectSpread$f(_objectSpread$f({}, sector), {}, {
|
|
39752
39721
|
radius: radius,
|
|
39753
39722
|
angle: reverseFormatAngleOfSetor(formatAngle, sector)
|
|
39754
39723
|
});
|
|
@@ -39756,21 +39725,18 @@ var inRangeOfSector = function inRangeOfSector(_ref5, sector) {
|
|
|
39756
39725
|
return null;
|
|
39757
39726
|
};
|
|
39758
39727
|
|
|
39759
|
-
function _typeof$
|
|
39760
|
-
var _excluded$7 = ["offset"];
|
|
39728
|
+
function _typeof$f(obj) { "@babel/helpers - typeof"; return _typeof$f = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$f(obj); }
|
|
39761
39729
|
function _toConsumableArray$3(arr) { return _arrayWithoutHoles$3(arr) || _iterableToArray$3(arr) || _unsupportedIterableToArray$5(arr) || _nonIterableSpread$3(); }
|
|
39762
39730
|
function _nonIterableSpread$3() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
39763
39731
|
function _unsupportedIterableToArray$5(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$5(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$5(o, minLen); }
|
|
39764
39732
|
function _iterableToArray$3(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
39765
39733
|
function _arrayWithoutHoles$3(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$5(arr); }
|
|
39766
39734
|
function _arrayLikeToArray$5(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
39767
|
-
function
|
|
39768
|
-
function
|
|
39769
|
-
function
|
|
39770
|
-
function
|
|
39771
|
-
function
|
|
39772
|
-
function _toPropertyKey$i(arg) { var key = _toPrimitive$i(arg, "string"); return _typeof$i(key) === "symbol" ? key : String(key); }
|
|
39773
|
-
function _toPrimitive$i(input, hint) { if (_typeof$i(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$i(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
39735
|
+
function ownKeys$e(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
39736
|
+
function _objectSpread$e(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$e(Object(source), !0).forEach(function (key) { _defineProperty$f(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$e(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
39737
|
+
function _defineProperty$f(obj, key, value) { key = _toPropertyKey$f(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
39738
|
+
function _toPropertyKey$f(arg) { var key = _toPrimitive$f(arg, "string"); return _typeof$f(key) === "symbol" ? key : String(key); }
|
|
39739
|
+
function _toPrimitive$f(input, hint) { if (_typeof$f(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$f(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
39774
39740
|
function _extends$f() { _extends$f = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$f.apply(this, arguments); }
|
|
39775
39741
|
var getLabel = function getLabel(props) {
|
|
39776
39742
|
var value = props.value,
|
|
@@ -39915,7 +39881,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39915
39881
|
textAnchor: 'middle',
|
|
39916
39882
|
verticalAnchor: verticalEnd
|
|
39917
39883
|
};
|
|
39918
|
-
return _objectSpread$
|
|
39884
|
+
return _objectSpread$e(_objectSpread$e({}, attrs), parentViewBox ? {
|
|
39919
39885
|
height: Math.max(y - parentViewBox.y, 0),
|
|
39920
39886
|
width: width
|
|
39921
39887
|
} : {});
|
|
@@ -39927,7 +39893,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39927
39893
|
textAnchor: 'middle',
|
|
39928
39894
|
verticalAnchor: verticalStart
|
|
39929
39895
|
};
|
|
39930
|
-
return _objectSpread$
|
|
39896
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs), parentViewBox ? {
|
|
39931
39897
|
height: Math.max(parentViewBox.y + parentViewBox.height - (y + height), 0),
|
|
39932
39898
|
width: width
|
|
39933
39899
|
} : {});
|
|
@@ -39939,7 +39905,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39939
39905
|
textAnchor: horizontalEnd,
|
|
39940
39906
|
verticalAnchor: 'middle'
|
|
39941
39907
|
};
|
|
39942
|
-
return _objectSpread$
|
|
39908
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs2), parentViewBox ? {
|
|
39943
39909
|
width: Math.max(_attrs2.x - parentViewBox.x, 0),
|
|
39944
39910
|
height: height
|
|
39945
39911
|
} : {});
|
|
@@ -39951,7 +39917,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39951
39917
|
textAnchor: horizontalStart,
|
|
39952
39918
|
verticalAnchor: 'middle'
|
|
39953
39919
|
};
|
|
39954
|
-
return _objectSpread$
|
|
39920
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs3), parentViewBox ? {
|
|
39955
39921
|
width: Math.max(parentViewBox.x + parentViewBox.width - _attrs3.x, 0),
|
|
39956
39922
|
height: height
|
|
39957
39923
|
} : {});
|
|
@@ -39961,7 +39927,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39961
39927
|
height: height
|
|
39962
39928
|
} : {};
|
|
39963
39929
|
if (position === 'insideLeft') {
|
|
39964
|
-
return _objectSpread$
|
|
39930
|
+
return _objectSpread$e({
|
|
39965
39931
|
x: x + horizontalOffset,
|
|
39966
39932
|
y: y + height / 2,
|
|
39967
39933
|
textAnchor: horizontalStart,
|
|
@@ -39969,7 +39935,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39969
39935
|
}, sizeAttrs);
|
|
39970
39936
|
}
|
|
39971
39937
|
if (position === 'insideRight') {
|
|
39972
|
-
return _objectSpread$
|
|
39938
|
+
return _objectSpread$e({
|
|
39973
39939
|
x: x + width - horizontalOffset,
|
|
39974
39940
|
y: y + height / 2,
|
|
39975
39941
|
textAnchor: horizontalEnd,
|
|
@@ -39977,7 +39943,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39977
39943
|
}, sizeAttrs);
|
|
39978
39944
|
}
|
|
39979
39945
|
if (position === 'insideTop') {
|
|
39980
|
-
return _objectSpread$
|
|
39946
|
+
return _objectSpread$e({
|
|
39981
39947
|
x: x + width / 2,
|
|
39982
39948
|
y: y + verticalOffset,
|
|
39983
39949
|
textAnchor: 'middle',
|
|
@@ -39985,7 +39951,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39985
39951
|
}, sizeAttrs);
|
|
39986
39952
|
}
|
|
39987
39953
|
if (position === 'insideBottom') {
|
|
39988
|
-
return _objectSpread$
|
|
39954
|
+
return _objectSpread$e({
|
|
39989
39955
|
x: x + width / 2,
|
|
39990
39956
|
y: y + height - verticalOffset,
|
|
39991
39957
|
textAnchor: 'middle',
|
|
@@ -39993,7 +39959,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39993
39959
|
}, sizeAttrs);
|
|
39994
39960
|
}
|
|
39995
39961
|
if (position === 'insideTopLeft') {
|
|
39996
|
-
return _objectSpread$
|
|
39962
|
+
return _objectSpread$e({
|
|
39997
39963
|
x: x + horizontalOffset,
|
|
39998
39964
|
y: y + verticalOffset,
|
|
39999
39965
|
textAnchor: horizontalStart,
|
|
@@ -40001,7 +39967,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40001
39967
|
}, sizeAttrs);
|
|
40002
39968
|
}
|
|
40003
39969
|
if (position === 'insideTopRight') {
|
|
40004
|
-
return _objectSpread$
|
|
39970
|
+
return _objectSpread$e({
|
|
40005
39971
|
x: x + width - horizontalOffset,
|
|
40006
39972
|
y: y + verticalOffset,
|
|
40007
39973
|
textAnchor: horizontalEnd,
|
|
@@ -40009,7 +39975,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40009
39975
|
}, sizeAttrs);
|
|
40010
39976
|
}
|
|
40011
39977
|
if (position === 'insideBottomLeft') {
|
|
40012
|
-
return _objectSpread$
|
|
39978
|
+
return _objectSpread$e({
|
|
40013
39979
|
x: x + horizontalOffset,
|
|
40014
39980
|
y: y + height - verticalOffset,
|
|
40015
39981
|
textAnchor: horizontalStart,
|
|
@@ -40017,7 +39983,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40017
39983
|
}, sizeAttrs);
|
|
40018
39984
|
}
|
|
40019
39985
|
if (position === 'insideBottomRight') {
|
|
40020
|
-
return _objectSpread$
|
|
39986
|
+
return _objectSpread$e({
|
|
40021
39987
|
x: x + width - horizontalOffset,
|
|
40022
39988
|
y: y + height - verticalOffset,
|
|
40023
39989
|
textAnchor: horizontalEnd,
|
|
@@ -40025,14 +39991,14 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40025
39991
|
}, sizeAttrs);
|
|
40026
39992
|
}
|
|
40027
39993
|
if (isObject_1(position) && (isNumber(position.x) || isPercent(position.x)) && (isNumber(position.y) || isPercent(position.y))) {
|
|
40028
|
-
return _objectSpread$
|
|
39994
|
+
return _objectSpread$e({
|
|
40029
39995
|
x: x + getPercentValue(position.x, width),
|
|
40030
39996
|
y: y + getPercentValue(position.y, height),
|
|
40031
39997
|
textAnchor: 'end',
|
|
40032
39998
|
verticalAnchor: 'end'
|
|
40033
39999
|
}, sizeAttrs);
|
|
40034
40000
|
}
|
|
40035
|
-
return _objectSpread$
|
|
40001
|
+
return _objectSpread$e({
|
|
40036
40002
|
x: x + width / 2,
|
|
40037
40003
|
y: y + height / 2,
|
|
40038
40004
|
textAnchor: 'middle',
|
|
@@ -40042,13 +40008,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40042
40008
|
var isPolar = function isPolar(viewBox) {
|
|
40043
40009
|
return 'cx' in viewBox && isNumber(viewBox.cx);
|
|
40044
40010
|
};
|
|
40045
|
-
function Label$3(
|
|
40046
|
-
var _ref4$offset = _ref4.offset,
|
|
40047
|
-
offset = _ref4$offset === void 0 ? 5 : _ref4$offset,
|
|
40048
|
-
restProps = _objectWithoutProperties$7(_ref4, _excluded$7);
|
|
40049
|
-
var props = _objectSpread$h({
|
|
40050
|
-
offset: offset
|
|
40051
|
-
}, restProps);
|
|
40011
|
+
function Label$3(props) {
|
|
40052
40012
|
var viewBox = props.viewBox,
|
|
40053
40013
|
position = props.position,
|
|
40054
40014
|
value = props.value,
|
|
@@ -40085,6 +40045,9 @@ function Label$3(_ref4) {
|
|
|
40085
40045
|
}), label);
|
|
40086
40046
|
}
|
|
40087
40047
|
Label$3.displayName = 'Label';
|
|
40048
|
+
Label$3.defaultProps = {
|
|
40049
|
+
offset: 5
|
|
40050
|
+
};
|
|
40088
40051
|
var parseViewBox = function parseViewBox(props) {
|
|
40089
40052
|
var cx = props.cx,
|
|
40090
40053
|
cy = props.cy,
|
|
@@ -40239,9 +40202,8 @@ function last(array) {
|
|
|
40239
40202
|
|
|
40240
40203
|
var last_1 = last;
|
|
40241
40204
|
|
|
40242
|
-
function _typeof$
|
|
40243
|
-
var _excluded$
|
|
40244
|
-
_excluded2$2 = ["data", "dataKey", "clockWise", "id", "textBreakAll"];
|
|
40205
|
+
function _typeof$e(obj) { "@babel/helpers - typeof"; return _typeof$e = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$e(obj); }
|
|
40206
|
+
var _excluded$5 = ["data", "valueAccessor", "dataKey", "clockWise", "id", "textBreakAll"];
|
|
40245
40207
|
function _toConsumableArray$2(arr) { return _arrayWithoutHoles$2(arr) || _iterableToArray$2(arr) || _unsupportedIterableToArray$4(arr) || _nonIterableSpread$2(); }
|
|
40246
40208
|
function _nonIterableSpread$2() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
40247
40209
|
function _unsupportedIterableToArray$4(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$4(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$4(o, minLen); }
|
|
@@ -40249,26 +40211,26 @@ function _iterableToArray$2(iter) { if (typeof Symbol !== "undefined" && iter[Sy
|
|
|
40249
40211
|
function _arrayWithoutHoles$2(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$4(arr); }
|
|
40250
40212
|
function _arrayLikeToArray$4(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
40251
40213
|
function _extends$e() { _extends$e = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$e.apply(this, arguments); }
|
|
40252
|
-
function ownKeys$
|
|
40253
|
-
function _objectSpread$
|
|
40254
|
-
function _defineProperty$
|
|
40255
|
-
function _toPropertyKey$
|
|
40256
|
-
function _toPrimitive$
|
|
40257
|
-
function _objectWithoutProperties$
|
|
40258
|
-
function _objectWithoutPropertiesLoose$
|
|
40259
|
-
var
|
|
40260
|
-
|
|
40261
|
-
|
|
40262
|
-
|
|
40263
|
-
|
|
40264
|
-
|
|
40265
|
-
|
|
40266
|
-
|
|
40267
|
-
dataKey =
|
|
40268
|
-
clockWise =
|
|
40269
|
-
id =
|
|
40270
|
-
textBreakAll =
|
|
40271
|
-
others = _objectWithoutProperties$
|
|
40214
|
+
function ownKeys$d(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
40215
|
+
function _objectSpread$d(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$d(Object(source), !0).forEach(function (key) { _defineProperty$e(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$d(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
40216
|
+
function _defineProperty$e(obj, key, value) { key = _toPropertyKey$e(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
40217
|
+
function _toPropertyKey$e(arg) { var key = _toPrimitive$e(arg, "string"); return _typeof$e(key) === "symbol" ? key : String(key); }
|
|
40218
|
+
function _toPrimitive$e(input, hint) { if (_typeof$e(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$e(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
40219
|
+
function _objectWithoutProperties$5(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$5(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
40220
|
+
function _objectWithoutPropertiesLoose$5(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
40221
|
+
var defaultProps = {
|
|
40222
|
+
valueAccessor: function valueAccessor(entry) {
|
|
40223
|
+
return isArray_1(entry.value) ? last_1(entry.value) : entry.value;
|
|
40224
|
+
}
|
|
40225
|
+
};
|
|
40226
|
+
function LabelList(props) {
|
|
40227
|
+
var data = props.data,
|
|
40228
|
+
valueAccessor = props.valueAccessor,
|
|
40229
|
+
dataKey = props.dataKey,
|
|
40230
|
+
clockWise = props.clockWise,
|
|
40231
|
+
id = props.id,
|
|
40232
|
+
textBreakAll = props.textBreakAll,
|
|
40233
|
+
others = _objectWithoutProperties$5(props, _excluded$5);
|
|
40272
40234
|
if (!data || !data.length) {
|
|
40273
40235
|
return null;
|
|
40274
40236
|
}
|
|
@@ -40284,7 +40246,7 @@ function LabelList(_ref) {
|
|
|
40284
40246
|
index: index,
|
|
40285
40247
|
value: value,
|
|
40286
40248
|
textBreakAll: textBreakAll,
|
|
40287
|
-
viewBox: Label$3.parseViewBox(isNil_1(clockWise) ? entry : _objectSpread$
|
|
40249
|
+
viewBox: Label$3.parseViewBox(isNil_1(clockWise) ? entry : _objectSpread$d(_objectSpread$d({}, entry), {}, {
|
|
40288
40250
|
clockWise: clockWise
|
|
40289
40251
|
})),
|
|
40290
40252
|
key: "label-".concat(index) // eslint-disable-line react/no-array-index-key
|
|
@@ -40339,14 +40301,9 @@ function renderCallByParent(parentProps, data) {
|
|
|
40339
40301
|
return [implicitLabelList].concat(_toConsumableArray$2(explicitChildren));
|
|
40340
40302
|
}
|
|
40341
40303
|
LabelList.renderCallByParent = renderCallByParent;
|
|
40304
|
+
LabelList.defaultProps = defaultProps;
|
|
40342
40305
|
|
|
40343
|
-
function _typeof$g(obj) { "@babel/helpers - typeof"; return _typeof$g = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$g(obj); }
|
|
40344
40306
|
function _extends$d() { _extends$d = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$d.apply(this, arguments); }
|
|
40345
|
-
function ownKeys$f(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
40346
|
-
function _objectSpread$f(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$f(Object(source), !0).forEach(function (key) { _defineProperty$g(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$f(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
40347
|
-
function _defineProperty$g(obj, key, value) { key = _toPropertyKey$g(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
40348
|
-
function _toPropertyKey$g(arg) { var key = _toPrimitive$g(arg, "string"); return _typeof$g(key) === "symbol" ? key : String(key); }
|
|
40349
|
-
function _toPrimitive$g(input, hint) { if (_typeof$g(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$g(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
40350
40307
|
var getDeltaAngle = function getDeltaAngle(startAngle, endAngle) {
|
|
40351
40308
|
var sign = mathSign(endAngle - startAngle);
|
|
40352
40309
|
var deltaAngle = Math.min(Math.abs(endAngle - startAngle), 359.999);
|
|
@@ -40487,19 +40444,7 @@ var getSectorWithCorner = function getSectorWithCorner(_ref3) {
|
|
|
40487
40444
|
}
|
|
40488
40445
|
return path;
|
|
40489
40446
|
};
|
|
40490
|
-
var
|
|
40491
|
-
cx: 0,
|
|
40492
|
-
cy: 0,
|
|
40493
|
-
innerRadius: 0,
|
|
40494
|
-
outerRadius: 0,
|
|
40495
|
-
startAngle: 0,
|
|
40496
|
-
endAngle: 0,
|
|
40497
|
-
cornerRadius: 0,
|
|
40498
|
-
forceCornerRadius: false,
|
|
40499
|
-
cornerIsExternal: false
|
|
40500
|
-
};
|
|
40501
|
-
var Sector = function Sector(sectorProps) {
|
|
40502
|
-
var props = _objectSpread$f(_objectSpread$f({}, defaultProps$1), sectorProps);
|
|
40447
|
+
var Sector = function Sector(props) {
|
|
40503
40448
|
var cx = props.cx,
|
|
40504
40449
|
cy = props.cy,
|
|
40505
40450
|
innerRadius = props.innerRadius,
|
|
@@ -40545,14 +40490,25 @@ var Sector = function Sector(sectorProps) {
|
|
|
40545
40490
|
role: "img"
|
|
40546
40491
|
}));
|
|
40547
40492
|
};
|
|
40493
|
+
Sector.defaultProps = {
|
|
40494
|
+
cx: 0,
|
|
40495
|
+
cy: 0,
|
|
40496
|
+
innerRadius: 0,
|
|
40497
|
+
outerRadius: 0,
|
|
40498
|
+
startAngle: 0,
|
|
40499
|
+
endAngle: 0,
|
|
40500
|
+
cornerRadius: 0,
|
|
40501
|
+
forceCornerRadius: false,
|
|
40502
|
+
cornerIsExternal: false
|
|
40503
|
+
};
|
|
40548
40504
|
|
|
40549
|
-
function _typeof$
|
|
40505
|
+
function _typeof$d(obj) { "@babel/helpers - typeof"; return _typeof$d = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$d(obj); }
|
|
40550
40506
|
function _extends$c() { _extends$c = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$c.apply(this, arguments); }
|
|
40551
|
-
function ownKeys$
|
|
40552
|
-
function _objectSpread$
|
|
40553
|
-
function _defineProperty$
|
|
40554
|
-
function _toPropertyKey$
|
|
40555
|
-
function _toPrimitive$
|
|
40507
|
+
function ownKeys$c(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
40508
|
+
function _objectSpread$c(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$c(Object(source), !0).forEach(function (key) { _defineProperty$d(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$c(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
40509
|
+
function _defineProperty$d(obj, key, value) { key = _toPropertyKey$d(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
40510
|
+
function _toPropertyKey$d(arg) { var key = _toPrimitive$d(arg, "string"); return _typeof$d(key) === "symbol" ? key : String(key); }
|
|
40511
|
+
function _toPrimitive$d(input, hint) { if (_typeof$d(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$d(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
40556
40512
|
var CURVE_FACTORIES = {
|
|
40557
40513
|
curveBasisClosed: curveBasisClosed,
|
|
40558
40514
|
curveBasisOpen: curveBasisOpen,
|
|
@@ -40592,14 +40548,11 @@ var getCurveFactory = function getCurveFactory(type, layout) {
|
|
|
40592
40548
|
* @return {String} path
|
|
40593
40549
|
*/
|
|
40594
40550
|
var getPath$1 = function getPath(_ref) {
|
|
40595
|
-
var
|
|
40596
|
-
|
|
40597
|
-
_ref$points = _ref.points,
|
|
40598
|
-
points = _ref$points === void 0 ? [] : _ref$points,
|
|
40551
|
+
var type = _ref.type,
|
|
40552
|
+
points = _ref.points,
|
|
40599
40553
|
baseLine = _ref.baseLine,
|
|
40600
40554
|
layout = _ref.layout,
|
|
40601
|
-
|
|
40602
|
-
connectNulls = _ref$connectNulls === void 0 ? false : _ref$connectNulls;
|
|
40555
|
+
connectNulls = _ref.connectNulls;
|
|
40603
40556
|
var curveFactory = getCurveFactory(type, layout);
|
|
40604
40557
|
var formatPoints = connectNulls ? points.filter(function (entry) {
|
|
40605
40558
|
return defined(entry);
|
|
@@ -40610,7 +40563,7 @@ var getPath$1 = function getPath(_ref) {
|
|
|
40610
40563
|
return defined(base);
|
|
40611
40564
|
}) : baseLine;
|
|
40612
40565
|
var areaPoints = formatPoints.map(function (entry, index) {
|
|
40613
|
-
return _objectSpread$
|
|
40566
|
+
return _objectSpread$c(_objectSpread$c({}, entry), {}, {
|
|
40614
40567
|
base: formatBaseLine[index]
|
|
40615
40568
|
});
|
|
40616
40569
|
});
|
|
@@ -40651,8 +40604,12 @@ var Curve = function Curve(props) {
|
|
|
40651
40604
|
ref: pathRef
|
|
40652
40605
|
}));
|
|
40653
40606
|
};
|
|
40607
|
+
Curve.defaultProps = {
|
|
40608
|
+
type: 'linear',
|
|
40609
|
+
points: [],
|
|
40610
|
+
connectNulls: false
|
|
40611
|
+
};
|
|
40654
40612
|
|
|
40655
|
-
function _typeof$e(obj) { "@babel/helpers - typeof"; return _typeof$e = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$e(obj); }
|
|
40656
40613
|
function _extends$b() { _extends$b = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$b.apply(this, arguments); }
|
|
40657
40614
|
function _slicedToArray$2(arr, i) { return _arrayWithHoles$2(arr) || _iterableToArrayLimit$2(arr, i) || _unsupportedIterableToArray$3(arr, i) || _nonIterableRest$2(); }
|
|
40658
40615
|
function _nonIterableRest$2() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -40660,11 +40617,6 @@ function _unsupportedIterableToArray$3(o, minLen) { if (!o) return; if (typeof o
|
|
|
40660
40617
|
function _arrayLikeToArray$3(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
40661
40618
|
function _iterableToArrayLimit$2(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
40662
40619
|
function _arrayWithHoles$2(arr) { if (Array.isArray(arr)) return arr; }
|
|
40663
|
-
function ownKeys$d(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
40664
|
-
function _objectSpread$d(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$d(Object(source), !0).forEach(function (key) { _defineProperty$e(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$d(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
40665
|
-
function _defineProperty$e(obj, key, value) { key = _toPropertyKey$e(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
40666
|
-
function _toPropertyKey$e(arg) { var key = _toPrimitive$e(arg, "string"); return _typeof$e(key) === "symbol" ? key : String(key); }
|
|
40667
|
-
function _toPrimitive$e(input, hint) { if (_typeof$e(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$e(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
40668
40620
|
var getRectanglePath = function getRectanglePath(x, y, width, height, radius) {
|
|
40669
40621
|
var maxRadius = Math.min(Math.abs(width) / 2, Math.abs(height) / 2);
|
|
40670
40622
|
var ySign = height >= 0 ? 1 : -1;
|
|
@@ -40720,29 +40672,13 @@ var isInRectangle = function isInRectangle(point, rect) {
|
|
|
40720
40672
|
}
|
|
40721
40673
|
return false;
|
|
40722
40674
|
};
|
|
40723
|
-
var
|
|
40724
|
-
x: 0,
|
|
40725
|
-
y: 0,
|
|
40726
|
-
width: 0,
|
|
40727
|
-
height: 0,
|
|
40728
|
-
// The radius of border
|
|
40729
|
-
// The radius of four corners when radius is a number
|
|
40730
|
-
// The radius of left-top, right-top, right-bottom, left-bottom when radius is an array
|
|
40731
|
-
radius: 0,
|
|
40732
|
-
isAnimationActive: false,
|
|
40733
|
-
isUpdateAnimationActive: false,
|
|
40734
|
-
animationBegin: 0,
|
|
40735
|
-
animationDuration: 1500,
|
|
40736
|
-
animationEasing: 'ease'
|
|
40737
|
-
};
|
|
40738
|
-
var Rectangle = function Rectangle(rectangleProps) {
|
|
40739
|
-
var props = _objectSpread$d(_objectSpread$d({}, defaultProps), rectangleProps);
|
|
40675
|
+
var Rectangle = function Rectangle(props) {
|
|
40740
40676
|
var pathRef = React$3.useRef();
|
|
40741
40677
|
var _useState = React$3.useState(-1),
|
|
40742
40678
|
_useState2 = _slicedToArray$2(_useState, 2),
|
|
40743
40679
|
totalLength = _useState2[0],
|
|
40744
40680
|
setTotalLength = _useState2[1];
|
|
40745
|
-
React$3.
|
|
40681
|
+
React$3.useLayoutEffect(function () {
|
|
40746
40682
|
if (pathRef.current && pathRef.current.getTotalLength) {
|
|
40747
40683
|
try {
|
|
40748
40684
|
var pathTotalLength = pathRef.current.getTotalLength();
|
|
@@ -40813,6 +40749,21 @@ var Rectangle = function Rectangle(rectangleProps) {
|
|
|
40813
40749
|
})));
|
|
40814
40750
|
});
|
|
40815
40751
|
};
|
|
40752
|
+
Rectangle.defaultProps = {
|
|
40753
|
+
x: 0,
|
|
40754
|
+
y: 0,
|
|
40755
|
+
width: 0,
|
|
40756
|
+
height: 0,
|
|
40757
|
+
// The radius of border
|
|
40758
|
+
// The radius of four corners when radius is a number
|
|
40759
|
+
// The radius of left-top, right-top, right-bottom, left-bottom when radius is an array
|
|
40760
|
+
radius: 0,
|
|
40761
|
+
isAnimationActive: false,
|
|
40762
|
+
isUpdateAnimationActive: false,
|
|
40763
|
+
animationBegin: 0,
|
|
40764
|
+
animationDuration: 1500,
|
|
40765
|
+
animationEasing: 'ease'
|
|
40766
|
+
};
|
|
40816
40767
|
|
|
40817
40768
|
function _extends$a() { _extends$a = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$a.apply(this, arguments); }
|
|
40818
40769
|
var Dot$1 = function Dot(props) {
|
|
@@ -40832,42 +40783,18 @@ var Dot$1 = function Dot(props) {
|
|
|
40832
40783
|
return null;
|
|
40833
40784
|
};
|
|
40834
40785
|
|
|
40835
|
-
function _typeof$d(obj) { "@babel/helpers - typeof"; return _typeof$d = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof$d(obj); }
|
|
40836
|
-
var _excluded$5 = ["x", "y", "top", "left", "width", "height", "className"];
|
|
40837
40786
|
function _extends$9() { _extends$9 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$9.apply(this, arguments); }
|
|
40838
|
-
function ownKeys$c(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
40839
|
-
function _objectSpread$c(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$c(Object(source), !0).forEach(function (key) { _defineProperty$d(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$c(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
40840
|
-
function _defineProperty$d(obj, key, value) { key = _toPropertyKey$d(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
40841
|
-
function _toPropertyKey$d(arg) { var key = _toPrimitive$d(arg, "string"); return _typeof$d(key) === "symbol" ? key : String(key); }
|
|
40842
|
-
function _toPrimitive$d(input, hint) { if (_typeof$d(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof$d(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
40843
|
-
function _objectWithoutProperties$5(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose$5(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
40844
|
-
function _objectWithoutPropertiesLoose$5(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
40845
40787
|
var getPath = function getPath(x, y, width, height, top, left) {
|
|
40846
40788
|
return "M".concat(x, ",").concat(top, "v").concat(height, "M").concat(left, ",").concat(y, "h").concat(width);
|
|
40847
40789
|
};
|
|
40848
|
-
var Cross = function Cross(
|
|
40849
|
-
var
|
|
40850
|
-
|
|
40851
|
-
|
|
40852
|
-
|
|
40853
|
-
|
|
40854
|
-
|
|
40855
|
-
|
|
40856
|
-
left = _ref$left === void 0 ? 0 : _ref$left,
|
|
40857
|
-
_ref$width = _ref.width,
|
|
40858
|
-
width = _ref$width === void 0 ? 0 : _ref$width,
|
|
40859
|
-
_ref$height = _ref.height,
|
|
40860
|
-
height = _ref$height === void 0 ? 0 : _ref$height,
|
|
40861
|
-
className = _ref.className,
|
|
40862
|
-
rest = _objectWithoutProperties$5(_ref, _excluded$5);
|
|
40863
|
-
var props = _objectSpread$c({
|
|
40864
|
-
x: x,
|
|
40865
|
-
y: y,
|
|
40866
|
-
top: top,
|
|
40867
|
-
left: left,
|
|
40868
|
-
width: width,
|
|
40869
|
-
height: height
|
|
40870
|
-
}, rest);
|
|
40790
|
+
var Cross = function Cross(props) {
|
|
40791
|
+
var x = props.x,
|
|
40792
|
+
y = props.y,
|
|
40793
|
+
width = props.width,
|
|
40794
|
+
height = props.height,
|
|
40795
|
+
top = props.top,
|
|
40796
|
+
left = props.left,
|
|
40797
|
+
className = props.className;
|
|
40871
40798
|
if (!isNumber(x) || !isNumber(y) || !isNumber(width) || !isNumber(height) || !isNumber(top) || !isNumber(left)) {
|
|
40872
40799
|
return null;
|
|
40873
40800
|
}
|
|
@@ -40876,6 +40803,14 @@ var Cross = function Cross(_ref) {
|
|
|
40876
40803
|
d: getPath(x, y, width, height, top, left)
|
|
40877
40804
|
}));
|
|
40878
40805
|
};
|
|
40806
|
+
Cross.defaultProps = {
|
|
40807
|
+
x: 0,
|
|
40808
|
+
y: 0,
|
|
40809
|
+
top: 0,
|
|
40810
|
+
left: 0,
|
|
40811
|
+
width: 0,
|
|
40812
|
+
height: 0
|
|
40813
|
+
};
|
|
40879
40814
|
|
|
40880
40815
|
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
40881
40816
|
|
|
@@ -41085,7 +41020,6 @@ var createScale = function createScale(_ref) {
|
|
|
41085
41020
|
isTextActive: false,
|
|
41086
41021
|
isSlideMoving: false,
|
|
41087
41022
|
isTravellerMoving: false,
|
|
41088
|
-
isTravellerFocused: false,
|
|
41089
41023
|
startX: scale(startIndex),
|
|
41090
41024
|
endX: scale(endIndex),
|
|
41091
41025
|
scale: scale,
|
|
@@ -41299,38 +41233,6 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41299
41233
|
}
|
|
41300
41234
|
});
|
|
41301
41235
|
}
|
|
41302
|
-
}, {
|
|
41303
|
-
key: "handleTravellerMoveKeyboard",
|
|
41304
|
-
value: function handleTravellerMoveKeyboard(direction, id) {
|
|
41305
|
-
var _this2 = this;
|
|
41306
|
-
// scaleValues are a list of coordinates. For example: [65, 250, 435, 620, 805, 990].
|
|
41307
|
-
var _this$state3 = this.state,
|
|
41308
|
-
scaleValues = _this$state3.scaleValues,
|
|
41309
|
-
startX = _this$state3.startX,
|
|
41310
|
-
endX = _this$state3.endX;
|
|
41311
|
-
// currentScaleValue refers to which coordinate the current traveller should be placed at.
|
|
41312
|
-
var currentScaleValue = this.state[id];
|
|
41313
|
-
var currentIndex = scaleValues.indexOf(currentScaleValue);
|
|
41314
|
-
if (currentIndex === -1) {
|
|
41315
|
-
return;
|
|
41316
|
-
}
|
|
41317
|
-
var newIndex = currentIndex + direction;
|
|
41318
|
-
if (newIndex === -1 || newIndex >= scaleValues.length) {
|
|
41319
|
-
return;
|
|
41320
|
-
}
|
|
41321
|
-
var newScaleValue = scaleValues[newIndex];
|
|
41322
|
-
|
|
41323
|
-
// Prevent travellers from being on top of each other or overlapping
|
|
41324
|
-
if (id === 'startX' && newScaleValue >= endX || id === 'endX' && newScaleValue <= startX) {
|
|
41325
|
-
return;
|
|
41326
|
-
}
|
|
41327
|
-
this.setState(_defineProperty$b({}, id, newScaleValue), function () {
|
|
41328
|
-
_this2.props.onChange(_this2.getIndex({
|
|
41329
|
-
startX: _this2.state.startX,
|
|
41330
|
-
endX: _this2.state.endX
|
|
41331
|
-
}));
|
|
41332
|
-
});
|
|
41333
|
-
}
|
|
41334
41236
|
}, {
|
|
41335
41237
|
key: "renderBackground",
|
|
41336
41238
|
value: function renderBackground() {
|
|
@@ -41378,7 +41280,6 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41378
41280
|
}, {
|
|
41379
41281
|
key: "renderTravellerLayer",
|
|
41380
41282
|
value: function renderTravellerLayer(travellerX, id) {
|
|
41381
|
-
var _this3 = this;
|
|
41382
41283
|
var _this$props7 = this.props,
|
|
41383
41284
|
y = _this$props7.y,
|
|
41384
41285
|
travellerWidth = _this$props7.travellerWidth,
|
|
@@ -41392,31 +41293,11 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41392
41293
|
height: height
|
|
41393
41294
|
});
|
|
41394
41295
|
return /*#__PURE__*/React__default["default"].createElement(Layer, {
|
|
41395
|
-
tabIndex: 0,
|
|
41396
|
-
role: "slider",
|
|
41397
41296
|
className: "recharts-brush-traveller",
|
|
41398
41297
|
onMouseEnter: this.handleEnterSlideOrTraveller,
|
|
41399
41298
|
onMouseLeave: this.handleLeaveSlideOrTraveller,
|
|
41400
41299
|
onMouseDown: this.travellerDragStartHandlers[id],
|
|
41401
41300
|
onTouchStart: this.travellerDragStartHandlers[id],
|
|
41402
|
-
onKeyDown: function onKeyDown(e) {
|
|
41403
|
-
if (!['ArrowLeft', 'ArrowRight'].includes(e.key)) {
|
|
41404
|
-
return;
|
|
41405
|
-
}
|
|
41406
|
-
e.preventDefault();
|
|
41407
|
-
e.stopPropagation();
|
|
41408
|
-
_this3.handleTravellerMoveKeyboard(e.key === 'ArrowRight' ? 1 : -1, id);
|
|
41409
|
-
},
|
|
41410
|
-
onFocus: function onFocus() {
|
|
41411
|
-
_this3.setState({
|
|
41412
|
-
isTravellerFocused: true
|
|
41413
|
-
});
|
|
41414
|
-
},
|
|
41415
|
-
onBlur: function onBlur() {
|
|
41416
|
-
_this3.setState({
|
|
41417
|
-
isTravellerFocused: false
|
|
41418
|
-
});
|
|
41419
|
-
},
|
|
41420
41301
|
style: {
|
|
41421
41302
|
cursor: 'col-resize'
|
|
41422
41303
|
}
|
|
@@ -41460,9 +41341,9 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41460
41341
|
height = _this$props9.height,
|
|
41461
41342
|
travellerWidth = _this$props9.travellerWidth,
|
|
41462
41343
|
stroke = _this$props9.stroke;
|
|
41463
|
-
var _this$
|
|
41464
|
-
startX = _this$
|
|
41465
|
-
endX = _this$
|
|
41344
|
+
var _this$state3 = this.state,
|
|
41345
|
+
startX = _this$state3.startX,
|
|
41346
|
+
endX = _this$state3.endX;
|
|
41466
41347
|
var offset = 5;
|
|
41467
41348
|
var attrs = {
|
|
41468
41349
|
pointerEvents: 'none',
|
|
@@ -41494,13 +41375,12 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41494
41375
|
width = _this$props10.width,
|
|
41495
41376
|
height = _this$props10.height,
|
|
41496
41377
|
alwaysShowText = _this$props10.alwaysShowText;
|
|
41497
|
-
var _this$
|
|
41498
|
-
startX = _this$
|
|
41499
|
-
endX = _this$
|
|
41500
|
-
isTextActive = _this$
|
|
41501
|
-
isSlideMoving = _this$
|
|
41502
|
-
isTravellerMoving = _this$
|
|
41503
|
-
isTravellerFocused = _this$state5.isTravellerFocused;
|
|
41378
|
+
var _this$state4 = this.state,
|
|
41379
|
+
startX = _this$state4.startX,
|
|
41380
|
+
endX = _this$state4.endX,
|
|
41381
|
+
isTextActive = _this$state4.isTextActive,
|
|
41382
|
+
isSlideMoving = _this$state4.isSlideMoving,
|
|
41383
|
+
isTravellerMoving = _this$state4.isTravellerMoving;
|
|
41504
41384
|
if (!data || !data.length || !isNumber(x) || !isNumber(y) || !isNumber(width) || !isNumber(height) || width <= 0 || height <= 0) {
|
|
41505
41385
|
return null;
|
|
41506
41386
|
}
|
|
@@ -41512,7 +41392,7 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41512
41392
|
onMouseLeave: this.handleLeaveWrapper,
|
|
41513
41393
|
onTouchMove: this.handleTouchMove,
|
|
41514
41394
|
style: style
|
|
41515
|
-
}, this.renderBackground(), isPanoramic && this.renderPanorama(), this.renderSlide(startX, endX), this.renderTravellerLayer(startX, 'startX'), this.renderTravellerLayer(endX, 'endX'), (isTextActive || isSlideMoving || isTravellerMoving ||
|
|
41395
|
+
}, this.renderBackground(), isPanoramic && this.renderPanorama(), this.renderSlide(startX, endX), this.renderTravellerLayer(startX, 'startX'), this.renderTravellerLayer(endX, 'endX'), (isTextActive || isSlideMoving || isTravellerMoving || alwaysShowText) && this.renderText());
|
|
41516
41396
|
}
|
|
41517
41397
|
}], [{
|
|
41518
41398
|
key: "renderDefaultTraveller",
|
|
@@ -41830,7 +41710,7 @@ function every(collection, predicate, guard) {
|
|
|
41830
41710
|
|
|
41831
41711
|
var every_1 = every;
|
|
41832
41712
|
|
|
41833
|
-
var defineProperty = _defineProperty$
|
|
41713
|
+
var defineProperty = _defineProperty$l;
|
|
41834
41714
|
|
|
41835
41715
|
/**
|
|
41836
41716
|
* The base implementation of `assignValue` and `assignMergeValue` without
|
|
@@ -42191,6 +42071,7 @@ _defineProperty$a(Bar, "defaultProps", {
|
|
|
42191
42071
|
legendType: 'rect',
|
|
42192
42072
|
minPointSize: 0,
|
|
42193
42073
|
hide: false,
|
|
42074
|
+
// data of bar
|
|
42194
42075
|
data: [],
|
|
42195
42076
|
layout: 'vertical',
|
|
42196
42077
|
isAnimationActive: !Global.isSsr,
|
|
@@ -45103,11 +44984,10 @@ var AccessibilityManager = /*#__PURE__*/function () {
|
|
|
45103
44984
|
}
|
|
45104
44985
|
var _this$container$getBo = this.container.getBoundingClientRect(),
|
|
45105
44986
|
x = _this$container$getBo.x,
|
|
45106
|
-
y = _this$container$getBo.y
|
|
45107
|
-
height = _this$container$getBo.height;
|
|
44987
|
+
y = _this$container$getBo.y;
|
|
45108
44988
|
var coordinate = this.coordinateList[this.activeIndex].coordinate;
|
|
45109
44989
|
var pageX = x + coordinate;
|
|
45110
|
-
var pageY = y + this.offset.top
|
|
44990
|
+
var pageY = y + this.offset.top;
|
|
45111
44991
|
this.mouseHandlerCallback({
|
|
45112
44992
|
pageX: pageX,
|
|
45113
44993
|
pageY: pageY
|