@typeolymp/ui-components 1.19.16 → 1.19.18
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 +3 -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 +686 -766
- package/build/index.es.js.map +1 -1
- package/build/index.js +686 -766
- 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.es.js
CHANGED
|
@@ -3564,6 +3564,7 @@ var icons = {
|
|
|
3564
3564
|
bell: (jsx$1("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" })),
|
|
3565
3565
|
bin: (jsx$1("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" })),
|
|
3566
3566
|
user: (jsx$1("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" })),
|
|
3567
|
+
search: (jsx$1("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" })),
|
|
3567
3568
|
};
|
|
3568
3569
|
var Icon = function (props) { return (jsx$1(Wrapper$a, __assign$2({}, props, { children: jsx$1("svg", __assign$2({ viewBox: "0 0 24 24", fill: "none" }, { children: icons[props.type] })) }))); };
|
|
3569
3570
|
|
|
@@ -4289,14 +4290,50 @@ var StyledParagraph = styled.p(templateObject_1$P || (templateObject_1$P = __mak
|
|
|
4289
4290
|
var templateObject_1$P;
|
|
4290
4291
|
|
|
4291
4292
|
var Container$q = styled.div(templateObject_1$O || (templateObject_1$O = __makeTemplateObject$1(["\n width: 100%;\n"], ["\n width: 100%;\n"])));
|
|
4292
|
-
var InputIconWrapper = styled.div(templateObject_2$B || (templateObject_2$B = __makeTemplateObject$1(["\n position: relative;\n width: 100%;\n\n input {\n padding-right: 43px;\n }\n\n input[type=\"date\"] {\n color: ", ";\n }\n\n div {\n position: absolute;\n height: 24px;\n right:
|
|
4293
|
+
var InputIconWrapper = styled.div(templateObject_2$B || (templateObject_2$B = __makeTemplateObject$1(["\n position: relative;\n width: 100%;\n\n input {\n padding-right: 43px;\n }\n\n input[type=\"date\"] {\n color: ", ";\n }\n\n div {\n position: absolute;\n height: 24px;\n right: ", ";\n top: ", ";\n }\n\n svg {\n cursor: ", ";\n width: ", ";\n }\n"], ["\n position: relative;\n width: 100%;\n\n input {\n padding-right: 43px;\n }\n\n input[type=\"date\"] {\n color: ", ";\n }\n\n div {\n position: absolute;\n height: 24px;\n right: ", ";\n top: ", ";\n }\n\n svg {\n cursor: ", ";\n width: ", ";\n }\n"])), function (_a) {
|
|
4293
4294
|
var isChanged = _a.isChanged;
|
|
4294
4295
|
return !isChanged ? theme.colors.lightGray.darker : "";
|
|
4296
|
+
}, function (_a) {
|
|
4297
|
+
var size = _a.size;
|
|
4298
|
+
switch (size) {
|
|
4299
|
+
case "small":
|
|
4300
|
+
return "7px";
|
|
4301
|
+
default:
|
|
4302
|
+
case "medium":
|
|
4303
|
+
return "12px";
|
|
4304
|
+
}
|
|
4305
|
+
}, function (_a) {
|
|
4306
|
+
var size = _a.size;
|
|
4307
|
+
switch (size) {
|
|
4308
|
+
case "small":
|
|
4309
|
+
return "10px";
|
|
4310
|
+
default:
|
|
4311
|
+
case "medium":
|
|
4312
|
+
return "14px";
|
|
4313
|
+
}
|
|
4295
4314
|
}, function (_a) {
|
|
4296
4315
|
var disabled = _a.disabled;
|
|
4297
4316
|
return (disabled ? "not-allowed" : "pointer");
|
|
4317
|
+
}, function (_a) {
|
|
4318
|
+
var size = _a.size;
|
|
4319
|
+
switch (size) {
|
|
4320
|
+
case "small":
|
|
4321
|
+
return "20px";
|
|
4322
|
+
default:
|
|
4323
|
+
case "medium":
|
|
4324
|
+
return "24px";
|
|
4325
|
+
}
|
|
4298
4326
|
});
|
|
4299
|
-
var StyledInput = styled.input(templateObject_3$d || (templateObject_3$d = __makeTemplateObject$1(["\n width: 100%;\n min-width: 228px;\n height:
|
|
4327
|
+
var StyledInput = styled.input(templateObject_3$d || (templateObject_3$d = __makeTemplateObject$1(["\n width: 100%;\n min-width: 228px;\n height: ", ";\n background-color: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n box-sizing: border-box;\n border-radius: 4px;\n padding: 13px 15px;\n cursor: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: 500;\n font-style: normal;\n line-height: ", ";\n color: ", ";\n\n ::placeholder {\n font-family: ", ";\n font-size: ", ";\n font-weight: 500;\n font-style: normal;\n line-height: ", ";\n color: ", ";\n }\n\n ::-webkit-calendar-picker-indicator {\n display: none;\n }\n\n :focus {\n outline: 0;\n border-color: ", ";\n box-shadow: ", ";\n }\n"], ["\n width: 100%;\n min-width: 228px;\n height: ", ";\n background-color: ", ";\n border-width: 1px;\n border-style: solid;\n border-color: ", ";\n box-sizing: border-box;\n border-radius: 4px;\n padding: 13px 15px;\n cursor: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: 500;\n font-style: normal;\n line-height: ", ";\n color: ", ";\n\n ::placeholder {\n font-family: ", ";\n font-size: ", ";\n font-weight: 500;\n font-style: normal;\n line-height: ", ";\n color: ", ";\n }\n\n ::-webkit-calendar-picker-indicator {\n display: none;\n }\n\n :focus {\n outline: 0;\n border-color: ", ";\n box-shadow: ", ";\n }\n"])), function (_a) {
|
|
4328
|
+
var size = _a.size;
|
|
4329
|
+
switch (size) {
|
|
4330
|
+
case "small":
|
|
4331
|
+
return "40px";
|
|
4332
|
+
default:
|
|
4333
|
+
case "medium":
|
|
4334
|
+
return "50px";
|
|
4335
|
+
}
|
|
4336
|
+
}, function (_a) {
|
|
4300
4337
|
var disabled = _a.disabled;
|
|
4301
4338
|
return disabled ? theme.colors.lightGray.dark : theme.colors.lightGray.light;
|
|
4302
4339
|
}, function (_a) {
|
|
@@ -4478,7 +4515,7 @@ var PasswordInput = function (props) {
|
|
|
4478
4515
|
if (props.onKeyPress)
|
|
4479
4516
|
props.onKeyPress(e);
|
|
4480
4517
|
};
|
|
4481
|
-
return (jsxs(Container$q, { children: [jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled }, { children: [jsx$1(Icon, { type: isVisible ? "eyeInvisible" : "eye", color: "gray", size: "small", onClick: toggle }), jsx$1(StyledInput, __assign$2({ type: isVisible ? "text" : "password" }, props, { onChange: onChange, onKeyPress: onKeyPress }))] })), props.helperLocale && value.length ? (jsxs(HelperContainer, { children: [jsxs(Helper, __assign$2({ isOk: expressions.hasCapitalLetter(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 capital letter"]] })), jsxs(Helper, __assign$2({ isOk: expressions.hasNumber(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 number"]] })), jsxs(Helper, __assign$2({ isOk: expressions.hasSpecialCharacter(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 special character"]] })), jsxs(Helper, __assign$2({ isOk: value.length >= 8 }, { children: ["\u2022 ", translations[props.helperLocale]["At least 8 characters"]] }))] })) : null] }));
|
|
4518
|
+
return (jsxs(Container$q, { children: [jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled, size: props.size }, { children: [jsx$1(Icon, { type: isVisible ? "eyeInvisible" : "eye", color: "gray", size: "small", onClick: toggle }), jsx$1(StyledInput, __assign$2({ type: isVisible ? "text" : "password" }, props, { onChange: onChange, onKeyPress: onKeyPress }))] })), props.helperLocale && value.length ? (jsxs(HelperContainer, { children: [jsxs(Helper, __assign$2({ isOk: expressions.hasCapitalLetter(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 capital letter"]] })), jsxs(Helper, __assign$2({ isOk: expressions.hasNumber(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 number"]] })), jsxs(Helper, __assign$2({ isOk: expressions.hasSpecialCharacter(value) }, { children: ["\u2022 ", translations[props.helperLocale]["At least 1 special character"]] })), jsxs(Helper, __assign$2({ isOk: value.length >= 8 }, { children: ["\u2022 ", translations[props.helperLocale]["At least 8 characters"]] }))] })) : null] }));
|
|
4482
4519
|
};
|
|
4483
4520
|
|
|
4484
4521
|
function toInteger$2(dirtyNumber) {
|
|
@@ -4501,7 +4538,7 @@ function requiredArgs(required, args) {
|
|
|
4501
4538
|
}
|
|
4502
4539
|
}
|
|
4503
4540
|
|
|
4504
|
-
function _typeof$
|
|
4541
|
+
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); }
|
|
4505
4542
|
/**
|
|
4506
4543
|
* @name toDate
|
|
4507
4544
|
* @category Common Helpers
|
|
@@ -4537,7 +4574,7 @@ function toDate(argument) {
|
|
|
4537
4574
|
requiredArgs(1, arguments);
|
|
4538
4575
|
var argStr = Object.prototype.toString.call(argument); // Clone the date
|
|
4539
4576
|
|
|
4540
|
-
if (argument instanceof Date || _typeof$
|
|
4577
|
+
if (argument instanceof Date || _typeof$u(argument) === 'object' && argStr === '[object Date]') {
|
|
4541
4578
|
// Prevent the date to lose the milliseconds when passed to new Date() in IE10
|
|
4542
4579
|
return new Date(argument.getTime());
|
|
4543
4580
|
} else if (typeof argument === 'number' || argStr === '[object Number]') {
|
|
@@ -4808,7 +4845,7 @@ var millisecondsInMinute = 60000;
|
|
|
4808
4845
|
|
|
4809
4846
|
var millisecondsInHour = 3600000;
|
|
4810
4847
|
|
|
4811
|
-
function _typeof$
|
|
4848
|
+
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); }
|
|
4812
4849
|
/**
|
|
4813
4850
|
* @name isDate
|
|
4814
4851
|
* @category Common Helpers
|
|
@@ -4844,7 +4881,7 @@ function _typeof$x(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "func
|
|
|
4844
4881
|
|
|
4845
4882
|
function isDate(value) {
|
|
4846
4883
|
requiredArgs(1, arguments);
|
|
4847
|
-
return value instanceof Date || _typeof$
|
|
4884
|
+
return value instanceof Date || _typeof$t(value) === 'object' && Object.prototype.toString.call(value) === '[object Date]';
|
|
4848
4885
|
}
|
|
4849
4886
|
|
|
4850
4887
|
/**
|
|
@@ -7955,7 +7992,25 @@ var DateInput = function (props) {
|
|
|
7955
7992
|
if (isBefore(new Date(inputRef.current.value), new Date(props.min)))
|
|
7956
7993
|
inputRef.current.value = props.min;
|
|
7957
7994
|
};
|
|
7958
|
-
return (jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled, isChanged: isChanged }, { children: [jsx$1(Icon, { type: "calendar", color: "gray", size: "small", onClick: showPicker }), jsx$1(StyledInput, __assign$2({ type: "date" }, props, { onChange: onChange, onBlur: onBlur, onKeyPress: onKeyPress, ref: inputRef }))] })));
|
|
7995
|
+
return (jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled, size: props.size, isChanged: isChanged }, { children: [jsx$1(Icon, { type: "calendar", color: "gray", size: "small", onClick: showPicker }), jsx$1(StyledInput, __assign$2({ type: "date" }, props, { onChange: onChange, onBlur: onBlur, onKeyPress: onKeyPress, ref: inputRef }))] })));
|
|
7996
|
+
};
|
|
7997
|
+
|
|
7998
|
+
var SearchInput = function (props) {
|
|
7999
|
+
var _a = useState(props.defaultValue || ""), value = _a[0], setValue = _a[1];
|
|
8000
|
+
var onChange = function (e) {
|
|
8001
|
+
setValue(e.target.value);
|
|
8002
|
+
if (!props.disabled && !!props.onChange)
|
|
8003
|
+
props.onChange(e.target.value);
|
|
8004
|
+
};
|
|
8005
|
+
var onKeyPress = function (e) {
|
|
8006
|
+
if (e.key === "Enter")
|
|
8007
|
+
onSearch();
|
|
8008
|
+
};
|
|
8009
|
+
var onSearch = function () {
|
|
8010
|
+
if (props.onSearch)
|
|
8011
|
+
props.onSearch(value);
|
|
8012
|
+
};
|
|
8013
|
+
return (jsx$1(Container$q, { children: jsxs(InputIconWrapper, __assign$2({ disabled: props.disabled, size: props.size }, { children: [jsx$1(Icon, { type: "search", color: "gray", size: "small", onClick: onSearch }), jsx$1(StyledInput, __assign$2({ type: "text" }, props, { onChange: onChange, onKeyPress: onKeyPress }))] })) }));
|
|
7959
8014
|
};
|
|
7960
8015
|
|
|
7961
8016
|
var Input = function (props) {
|
|
@@ -7966,7 +8021,8 @@ var Input = function (props) {
|
|
|
7966
8021
|
return jsx$1(StyledInput, __assign$2({ type: "text" }, props, { onChange: onChange }));
|
|
7967
8022
|
};
|
|
7968
8023
|
Input.Password = PasswordInput;
|
|
7969
|
-
Input.Date = DateInput;
|
|
8024
|
+
Input.Date = DateInput;
|
|
8025
|
+
Input.Search = SearchInput;
|
|
7970
8026
|
|
|
7971
8027
|
var Logo = function (props) { return (jsxs("svg", __assign$2({ width: 396, height: 66, viewBox: "0 0 662.8 118.1", fill: "none", xmlSpace: "preserve" }, props, { children: [jsxs("g", { children: [jsx$1("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" }), jsx$1("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" }), jsx$1("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" }), jsx$1("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" }), jsx$1("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" })] }), jsxs("g", __assign$2({ fill: "#23292f" }, { children: [jsx$1("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" }), jsx$1("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" })] }))] }))); };
|
|
7972
8028
|
|
|
@@ -13560,15 +13616,15 @@ possibleStandardNamesOptimized$1.possibleStandardNames = {
|
|
|
13560
13616
|
|
|
13561
13617
|
Object.defineProperty(lib$1, '__esModule', { value: true });
|
|
13562
13618
|
|
|
13563
|
-
function _slicedToArray$
|
|
13564
|
-
return _arrayWithHoles$
|
|
13619
|
+
function _slicedToArray$d(arr, i) {
|
|
13620
|
+
return _arrayWithHoles$e(arr) || _iterableToArrayLimit$d(arr, i) || _unsupportedIterableToArray$l(arr, i) || _nonIterableRest$e();
|
|
13565
13621
|
}
|
|
13566
13622
|
|
|
13567
|
-
function _arrayWithHoles$
|
|
13623
|
+
function _arrayWithHoles$e(arr) {
|
|
13568
13624
|
if (Array.isArray(arr)) return arr;
|
|
13569
13625
|
}
|
|
13570
13626
|
|
|
13571
|
-
function _iterableToArrayLimit$
|
|
13627
|
+
function _iterableToArrayLimit$d(arr, i) {
|
|
13572
13628
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
13573
13629
|
|
|
13574
13630
|
if (_i == null) return;
|
|
@@ -13598,16 +13654,16 @@ function _iterableToArrayLimit$c(arr, i) {
|
|
|
13598
13654
|
return _arr;
|
|
13599
13655
|
}
|
|
13600
13656
|
|
|
13601
|
-
function _unsupportedIterableToArray$
|
|
13657
|
+
function _unsupportedIterableToArray$l(o, minLen) {
|
|
13602
13658
|
if (!o) return;
|
|
13603
|
-
if (typeof o === "string") return _arrayLikeToArray$
|
|
13659
|
+
if (typeof o === "string") return _arrayLikeToArray$l(o, minLen);
|
|
13604
13660
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
13605
13661
|
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
13606
13662
|
if (n === "Map" || n === "Set") return Array.from(o);
|
|
13607
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$
|
|
13663
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$l(o, minLen);
|
|
13608
13664
|
}
|
|
13609
13665
|
|
|
13610
|
-
function _arrayLikeToArray$
|
|
13666
|
+
function _arrayLikeToArray$l(arr, len) {
|
|
13611
13667
|
if (len == null || len > arr.length) len = arr.length;
|
|
13612
13668
|
|
|
13613
13669
|
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
@@ -13615,7 +13671,7 @@ function _arrayLikeToArray$k(arr, len) {
|
|
|
13615
13671
|
return arr2;
|
|
13616
13672
|
}
|
|
13617
13673
|
|
|
13618
|
-
function _nonIterableRest$
|
|
13674
|
+
function _nonIterableRest$e() {
|
|
13619
13675
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
13620
13676
|
}
|
|
13621
13677
|
|
|
@@ -13679,7 +13735,7 @@ reservedProps.forEach(function (name) {
|
|
|
13679
13735
|
// This is a mapping from React prop names to the attribute names.
|
|
13680
13736
|
|
|
13681
13737
|
[['acceptCharset', 'accept-charset'], ['className', 'class'], ['htmlFor', 'for'], ['httpEquiv', 'http-equiv']].forEach(function (_ref) {
|
|
13682
|
-
var _ref2 = _slicedToArray$
|
|
13738
|
+
var _ref2 = _slicedToArray$d(_ref, 2),
|
|
13683
13739
|
name = _ref2[0],
|
|
13684
13740
|
attributeName = _ref2[1];
|
|
13685
13741
|
|
|
@@ -16090,31 +16146,31 @@ var _default = function (file, acceptedFiles) {
|
|
|
16090
16146
|
return true;
|
|
16091
16147
|
};
|
|
16092
16148
|
|
|
16093
|
-
function _toConsumableArray$c(arr) { return _arrayWithoutHoles$c(arr) || _iterableToArray$d(arr) || _unsupportedIterableToArray$
|
|
16149
|
+
function _toConsumableArray$c(arr) { return _arrayWithoutHoles$c(arr) || _iterableToArray$d(arr) || _unsupportedIterableToArray$k(arr) || _nonIterableSpread$c(); }
|
|
16094
16150
|
|
|
16095
16151
|
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."); }
|
|
16096
16152
|
|
|
16097
16153
|
function _iterableToArray$d(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16098
16154
|
|
|
16099
|
-
function _arrayWithoutHoles$c(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
16155
|
+
function _arrayWithoutHoles$c(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$k(arr); }
|
|
16100
16156
|
|
|
16101
|
-
function ownKeys$
|
|
16157
|
+
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; }
|
|
16102
16158
|
|
|
16103
|
-
function _objectSpread$
|
|
16159
|
+
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; }
|
|
16104
16160
|
|
|
16105
|
-
function _defineProperty$
|
|
16161
|
+
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; }
|
|
16106
16162
|
|
|
16107
|
-
function _slicedToArray$
|
|
16163
|
+
function _slicedToArray$c(arr, i) { return _arrayWithHoles$d(arr) || _iterableToArrayLimit$c(arr, i) || _unsupportedIterableToArray$k(arr, i) || _nonIterableRest$d(); }
|
|
16108
16164
|
|
|
16109
|
-
function _nonIterableRest$
|
|
16165
|
+
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."); }
|
|
16110
16166
|
|
|
16111
|
-
function _unsupportedIterableToArray$
|
|
16167
|
+
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); }
|
|
16112
16168
|
|
|
16113
|
-
function _arrayLikeToArray$
|
|
16169
|
+
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; }
|
|
16114
16170
|
|
|
16115
|
-
function _iterableToArrayLimit$
|
|
16171
|
+
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; }
|
|
16116
16172
|
|
|
16117
|
-
function _arrayWithHoles$
|
|
16173
|
+
function _arrayWithHoles$d(arr) { if (Array.isArray(arr)) return arr; }
|
|
16118
16174
|
|
|
16119
16175
|
var FILE_INVALID_TYPE = "file-invalid-type";
|
|
16120
16176
|
var FILE_TOO_LARGE = "file-too-large";
|
|
@@ -16194,11 +16250,11 @@ function allFilesAccepted(_ref) {
|
|
|
16194
16250
|
|
|
16195
16251
|
return files.every(function (file) {
|
|
16196
16252
|
var _fileAccepted = fileAccepted(file, accept),
|
|
16197
|
-
_fileAccepted2 = _slicedToArray$
|
|
16253
|
+
_fileAccepted2 = _slicedToArray$c(_fileAccepted, 1),
|
|
16198
16254
|
accepted = _fileAccepted2[0];
|
|
16199
16255
|
|
|
16200
16256
|
var _fileMatchSize = fileMatchSize(file, minSize, maxSize),
|
|
16201
|
-
_fileMatchSize2 = _slicedToArray$
|
|
16257
|
+
_fileMatchSize2 = _slicedToArray$c(_fileMatchSize, 1),
|
|
16202
16258
|
sizeMatch = _fileMatchSize2[0];
|
|
16203
16259
|
|
|
16204
16260
|
var customErrors = validator ? validator(file) : null;
|
|
@@ -16295,7 +16351,7 @@ function canUseFileSystemAccessAPI() {
|
|
|
16295
16351
|
function pickerOptionsFromAccept(accept) {
|
|
16296
16352
|
if (isDefined(accept)) {
|
|
16297
16353
|
var acceptForPicker = Object.entries(accept).filter(function (_ref2) {
|
|
16298
|
-
var _ref3 = _slicedToArray$
|
|
16354
|
+
var _ref3 = _slicedToArray$c(_ref2, 2),
|
|
16299
16355
|
mimeType = _ref3[0],
|
|
16300
16356
|
ext = _ref3[1];
|
|
16301
16357
|
|
|
@@ -16313,11 +16369,11 @@ function pickerOptionsFromAccept(accept) {
|
|
|
16313
16369
|
|
|
16314
16370
|
return ok;
|
|
16315
16371
|
}).reduce(function (agg, _ref4) {
|
|
16316
|
-
var _ref5 = _slicedToArray$
|
|
16372
|
+
var _ref5 = _slicedToArray$c(_ref4, 2),
|
|
16317
16373
|
mimeType = _ref5[0],
|
|
16318
16374
|
ext = _ref5[1];
|
|
16319
16375
|
|
|
16320
|
-
return _objectSpread$
|
|
16376
|
+
return _objectSpread$q(_objectSpread$q({}, agg), {}, _defineProperty$s({}, mimeType, ext));
|
|
16321
16377
|
}, {});
|
|
16322
16378
|
return [{
|
|
16323
16379
|
// description is required due to https://crbug.com/1264708
|
|
@@ -16337,7 +16393,7 @@ function pickerOptionsFromAccept(accept) {
|
|
|
16337
16393
|
function acceptPropAsAcceptAttr(accept) {
|
|
16338
16394
|
if (isDefined(accept)) {
|
|
16339
16395
|
return Object.entries(accept).reduce(function (a, _ref6) {
|
|
16340
|
-
var _ref7 = _slicedToArray$
|
|
16396
|
+
var _ref7 = _slicedToArray$c(_ref6, 2),
|
|
16341
16397
|
mimeType = _ref7[0],
|
|
16342
16398
|
ext = _ref7[1];
|
|
16343
16399
|
|
|
@@ -16405,40 +16461,40 @@ function isExt(v) {
|
|
|
16405
16461
|
* @typedef {"file-invalid-type"|"file-too-large"|"file-too-small"|"too-many-files"} ErrorCode
|
|
16406
16462
|
*/
|
|
16407
16463
|
|
|
16408
|
-
var _excluded$
|
|
16409
|
-
_excluded2$
|
|
16464
|
+
var _excluded$d = ["children"],
|
|
16465
|
+
_excluded2$3 = ["open"],
|
|
16410
16466
|
_excluded3$1 = ["refKey", "role", "onKeyDown", "onFocus", "onBlur", "onClick", "onDragEnter", "onDragOver", "onDragLeave", "onDrop"],
|
|
16411
16467
|
_excluded4 = ["refKey", "onChange", "onClick"];
|
|
16412
16468
|
|
|
16413
|
-
function _toConsumableArray$b(arr) { return _arrayWithoutHoles$b(arr) || _iterableToArray$c(arr) || _unsupportedIterableToArray$
|
|
16469
|
+
function _toConsumableArray$b(arr) { return _arrayWithoutHoles$b(arr) || _iterableToArray$c(arr) || _unsupportedIterableToArray$j(arr) || _nonIterableSpread$b(); }
|
|
16414
16470
|
|
|
16415
16471
|
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."); }
|
|
16416
16472
|
|
|
16417
16473
|
function _iterableToArray$c(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
16418
16474
|
|
|
16419
|
-
function _arrayWithoutHoles$b(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
16475
|
+
function _arrayWithoutHoles$b(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$j(arr); }
|
|
16420
16476
|
|
|
16421
|
-
function _slicedToArray$
|
|
16477
|
+
function _slicedToArray$b(arr, i) { return _arrayWithHoles$c(arr) || _iterableToArrayLimit$b(arr, i) || _unsupportedIterableToArray$j(arr, i) || _nonIterableRest$c(); }
|
|
16422
16478
|
|
|
16423
|
-
function _nonIterableRest$
|
|
16479
|
+
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."); }
|
|
16424
16480
|
|
|
16425
|
-
function _unsupportedIterableToArray$
|
|
16481
|
+
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); }
|
|
16426
16482
|
|
|
16427
|
-
function _arrayLikeToArray$
|
|
16483
|
+
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; }
|
|
16428
16484
|
|
|
16429
|
-
function _iterableToArrayLimit$
|
|
16485
|
+
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; }
|
|
16430
16486
|
|
|
16431
|
-
function _arrayWithHoles$
|
|
16487
|
+
function _arrayWithHoles$c(arr) { if (Array.isArray(arr)) return arr; }
|
|
16432
16488
|
|
|
16433
|
-
function ownKeys$
|
|
16489
|
+
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; }
|
|
16434
16490
|
|
|
16435
|
-
function _objectSpread$
|
|
16491
|
+
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; }
|
|
16436
16492
|
|
|
16437
|
-
function _defineProperty$
|
|
16493
|
+
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; }
|
|
16438
16494
|
|
|
16439
|
-
function _objectWithoutProperties$
|
|
16495
|
+
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; }
|
|
16440
16496
|
|
|
16441
|
-
function _objectWithoutPropertiesLoose$
|
|
16497
|
+
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; }
|
|
16442
16498
|
/**
|
|
16443
16499
|
* Convenience wrapper component for the `useDropzone` hook
|
|
16444
16500
|
*
|
|
@@ -16456,11 +16512,11 @@ function _objectWithoutPropertiesLoose$g(source, excluded) { if (source == null)
|
|
|
16456
16512
|
|
|
16457
16513
|
var Dropzone = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
16458
16514
|
var children = _ref.children,
|
|
16459
|
-
params = _objectWithoutProperties$
|
|
16515
|
+
params = _objectWithoutProperties$d(_ref, _excluded$d);
|
|
16460
16516
|
|
|
16461
16517
|
var _useDropzone = useDropzone(params),
|
|
16462
16518
|
open = _useDropzone.open,
|
|
16463
|
-
props = _objectWithoutProperties$
|
|
16519
|
+
props = _objectWithoutProperties$d(_useDropzone, _excluded2$3);
|
|
16464
16520
|
|
|
16465
16521
|
useImperativeHandle(ref, function () {
|
|
16466
16522
|
return {
|
|
@@ -16468,13 +16524,13 @@ var Dropzone = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
16468
16524
|
};
|
|
16469
16525
|
}, [open]); // TODO: Figure out why react-styleguidist cannot create docs if we don't return a jsx element
|
|
16470
16526
|
|
|
16471
|
-
return /*#__PURE__*/React__default.createElement(Fragment, null, children(_objectSpread$
|
|
16527
|
+
return /*#__PURE__*/React__default.createElement(Fragment, null, children(_objectSpread$p(_objectSpread$p({}, props), {}, {
|
|
16472
16528
|
open: open
|
|
16473
16529
|
})));
|
|
16474
16530
|
});
|
|
16475
16531
|
Dropzone.displayName = "Dropzone"; // Add default props for react-docgen
|
|
16476
16532
|
|
|
16477
|
-
var defaultProps$
|
|
16533
|
+
var defaultProps$1 = {
|
|
16478
16534
|
disabled: false,
|
|
16479
16535
|
getFilesFromEvent: fromEvent,
|
|
16480
16536
|
maxSize: Infinity,
|
|
@@ -16490,7 +16546,7 @@ var defaultProps$2 = {
|
|
|
16490
16546
|
useFsAccessApi: true,
|
|
16491
16547
|
autoFocus: false
|
|
16492
16548
|
};
|
|
16493
|
-
Dropzone.defaultProps = defaultProps$
|
|
16549
|
+
Dropzone.defaultProps = defaultProps$1;
|
|
16494
16550
|
Dropzone.propTypes = {
|
|
16495
16551
|
/**
|
|
16496
16552
|
* Render function that exposes the dropzone state and prop getter fns
|
|
@@ -16841,7 +16897,7 @@ var initialState = {
|
|
|
16841
16897
|
function useDropzone() {
|
|
16842
16898
|
var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
16843
16899
|
|
|
16844
|
-
var _defaultProps$props = _objectSpread$
|
|
16900
|
+
var _defaultProps$props = _objectSpread$p(_objectSpread$p({}, defaultProps$1), props),
|
|
16845
16901
|
accept = _defaultProps$props.accept,
|
|
16846
16902
|
disabled = _defaultProps$props.disabled,
|
|
16847
16903
|
getFilesFromEvent = _defaultProps$props.getFilesFromEvent,
|
|
@@ -16888,7 +16944,7 @@ function useDropzone() {
|
|
|
16888
16944
|
var inputRef = useRef(null);
|
|
16889
16945
|
|
|
16890
16946
|
var _useReducer = useReducer(reducer$1, initialState),
|
|
16891
|
-
_useReducer2 = _slicedToArray$
|
|
16947
|
+
_useReducer2 = _slicedToArray$b(_useReducer, 2),
|
|
16892
16948
|
state = _useReducer2[0],
|
|
16893
16949
|
dispatch = _useReducer2[1];
|
|
16894
16950
|
|
|
@@ -17058,12 +17114,12 @@ function useDropzone() {
|
|
|
17058
17114
|
var fileRejections = [];
|
|
17059
17115
|
files.forEach(function (file) {
|
|
17060
17116
|
var _fileAccepted = fileAccepted(file, acceptAttr),
|
|
17061
|
-
_fileAccepted2 = _slicedToArray$
|
|
17117
|
+
_fileAccepted2 = _slicedToArray$b(_fileAccepted, 2),
|
|
17062
17118
|
accepted = _fileAccepted2[0],
|
|
17063
17119
|
acceptError = _fileAccepted2[1];
|
|
17064
17120
|
|
|
17065
17121
|
var _fileMatchSize = fileMatchSize(file, minSize, maxSize),
|
|
17066
|
-
_fileMatchSize2 = _slicedToArray$
|
|
17122
|
+
_fileMatchSize2 = _slicedToArray$b(_fileMatchSize, 2),
|
|
17067
17123
|
sizeMatch = _fileMatchSize2[0],
|
|
17068
17124
|
sizeError = _fileMatchSize2[1];
|
|
17069
17125
|
|
|
@@ -17264,9 +17320,9 @@ function useDropzone() {
|
|
|
17264
17320
|
onDragOver = _ref2.onDragOver,
|
|
17265
17321
|
onDragLeave = _ref2.onDragLeave,
|
|
17266
17322
|
onDrop = _ref2.onDrop,
|
|
17267
|
-
rest = _objectWithoutProperties$
|
|
17323
|
+
rest = _objectWithoutProperties$d(_ref2, _excluded3$1);
|
|
17268
17324
|
|
|
17269
|
-
return _objectSpread$
|
|
17325
|
+
return _objectSpread$p(_objectSpread$p(_defineProperty$r({
|
|
17270
17326
|
onKeyDown: composeKeyboardHandler(composeEventHandlers(onKeyDown, onKeyDownCb)),
|
|
17271
17327
|
onFocus: composeKeyboardHandler(composeEventHandlers(onFocus, onFocusCb)),
|
|
17272
17328
|
onBlur: composeKeyboardHandler(composeEventHandlers(onBlur, onBlurCb)),
|
|
@@ -17291,9 +17347,9 @@ function useDropzone() {
|
|
|
17291
17347
|
refKey = _ref3$refKey === void 0 ? "ref" : _ref3$refKey,
|
|
17292
17348
|
onChange = _ref3.onChange,
|
|
17293
17349
|
onClick = _ref3.onClick,
|
|
17294
|
-
rest = _objectWithoutProperties$
|
|
17350
|
+
rest = _objectWithoutProperties$d(_ref3, _excluded4);
|
|
17295
17351
|
|
|
17296
|
-
var inputProps = _defineProperty$
|
|
17352
|
+
var inputProps = _defineProperty$r({
|
|
17297
17353
|
accept: acceptAttr,
|
|
17298
17354
|
multiple: multiple,
|
|
17299
17355
|
type: "file",
|
|
@@ -17305,10 +17361,10 @@ function useDropzone() {
|
|
|
17305
17361
|
tabIndex: -1
|
|
17306
17362
|
}, refKey, inputRef);
|
|
17307
17363
|
|
|
17308
|
-
return _objectSpread$
|
|
17364
|
+
return _objectSpread$p(_objectSpread$p({}, inputProps), rest);
|
|
17309
17365
|
};
|
|
17310
17366
|
}, [inputRef, accept, multiple, onDropCb, disabled]);
|
|
17311
|
-
return _objectSpread$
|
|
17367
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17312
17368
|
isFocused: isFocused && !disabled,
|
|
17313
17369
|
getRootProps: getRootProps,
|
|
17314
17370
|
getInputProps: getInputProps,
|
|
@@ -17327,40 +17383,40 @@ function reducer$1(state, action) {
|
|
|
17327
17383
|
/* istanbul ignore next */
|
|
17328
17384
|
switch (action.type) {
|
|
17329
17385
|
case "focus":
|
|
17330
|
-
return _objectSpread$
|
|
17386
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17331
17387
|
isFocused: true
|
|
17332
17388
|
});
|
|
17333
17389
|
|
|
17334
17390
|
case "blur":
|
|
17335
|
-
return _objectSpread$
|
|
17391
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17336
17392
|
isFocused: false
|
|
17337
17393
|
});
|
|
17338
17394
|
|
|
17339
17395
|
case "openDialog":
|
|
17340
|
-
return _objectSpread$
|
|
17396
|
+
return _objectSpread$p(_objectSpread$p({}, initialState), {}, {
|
|
17341
17397
|
isFileDialogActive: true
|
|
17342
17398
|
});
|
|
17343
17399
|
|
|
17344
17400
|
case "closeDialog":
|
|
17345
|
-
return _objectSpread$
|
|
17401
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17346
17402
|
isFileDialogActive: false
|
|
17347
17403
|
});
|
|
17348
17404
|
|
|
17349
17405
|
case "setDraggedFiles":
|
|
17350
|
-
return _objectSpread$
|
|
17406
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17351
17407
|
isDragActive: action.isDragActive,
|
|
17352
17408
|
isDragAccept: action.isDragAccept,
|
|
17353
17409
|
isDragReject: action.isDragReject
|
|
17354
17410
|
});
|
|
17355
17411
|
|
|
17356
17412
|
case "setFiles":
|
|
17357
|
-
return _objectSpread$
|
|
17413
|
+
return _objectSpread$p(_objectSpread$p({}, state), {}, {
|
|
17358
17414
|
acceptedFiles: action.acceptedFiles,
|
|
17359
17415
|
fileRejections: action.fileRejections
|
|
17360
17416
|
});
|
|
17361
17417
|
|
|
17362
17418
|
case "reset":
|
|
17363
|
-
return _objectSpread$
|
|
17419
|
+
return _objectSpread$p({}, initialState);
|
|
17364
17420
|
|
|
17365
17421
|
default:
|
|
17366
17422
|
return state;
|
|
@@ -19588,7 +19644,7 @@ function shallowEqual(a, b) {
|
|
|
19588
19644
|
return true;
|
|
19589
19645
|
}
|
|
19590
19646
|
|
|
19591
|
-
function _typeof$
|
|
19647
|
+
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); }
|
|
19592
19648
|
|
|
19593
19649
|
//
|
|
19594
19650
|
// Event Handler Types -- Copied from @types/react/index.d.ts and adapted for Props.
|
|
@@ -19615,9 +19671,7 @@ var FilteredElementKeyMap = {
|
|
|
19615
19671
|
};
|
|
19616
19672
|
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'];
|
|
19617
19673
|
|
|
19618
|
-
|
|
19619
|
-
|
|
19620
|
-
/** Specifies the duration of animation, the unit of this option is ms. */
|
|
19674
|
+
// Animation Types => TODO: Should be moved when react-smooth is typescriptified.
|
|
19621
19675
|
|
|
19622
19676
|
/** the offset of a chart, which define the blank space all around */
|
|
19623
19677
|
|
|
@@ -19653,7 +19707,7 @@ var getEventHandlerOfChild = function getEventHandlerOfChild(originalHandler, da
|
|
|
19653
19707
|
};
|
|
19654
19708
|
};
|
|
19655
19709
|
var adaptEventsOfChild = function adaptEventsOfChild(props, data, index) {
|
|
19656
|
-
if (!isObject_1(props) || _typeof$
|
|
19710
|
+
if (!isObject_1(props) || _typeof$s(props) !== 'object') {
|
|
19657
19711
|
return null;
|
|
19658
19712
|
}
|
|
19659
19713
|
var out = null;
|
|
@@ -19667,11 +19721,11 @@ var adaptEventsOfChild = function adaptEventsOfChild(props, data, index) {
|
|
|
19667
19721
|
return out;
|
|
19668
19722
|
};
|
|
19669
19723
|
|
|
19670
|
-
var _excluded$
|
|
19671
|
-
_excluded2$
|
|
19672
|
-
function _objectWithoutProperties$
|
|
19673
|
-
function _objectWithoutPropertiesLoose$
|
|
19674
|
-
function _typeof$
|
|
19724
|
+
var _excluded$c = ["children"],
|
|
19725
|
+
_excluded2$2 = ["children"];
|
|
19726
|
+
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; }
|
|
19727
|
+
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; }
|
|
19728
|
+
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); }
|
|
19675
19729
|
var REACT_BROWSER_EVENT_MAP = {
|
|
19676
19730
|
click: 'onClick',
|
|
19677
19731
|
mousedown: 'onMouseDown',
|
|
@@ -19778,7 +19832,7 @@ var isSvgElement = function isSvgElement(child) {
|
|
|
19778
19832
|
return child && child.type && isString_1(child.type) && SVG_TAGS.indexOf(child.type) >= 0;
|
|
19779
19833
|
};
|
|
19780
19834
|
var isDotProps = function isDotProps(dot) {
|
|
19781
|
-
return dot && _typeof$
|
|
19835
|
+
return dot && _typeof$r(dot) === 'object' && 'cx' in dot && 'cy' in dot && 'r' in dot;
|
|
19782
19836
|
};
|
|
19783
19837
|
|
|
19784
19838
|
/**
|
|
@@ -19870,10 +19924,10 @@ var isSingleChildEqual = function isSingleChildEqual(nextChild, prevChild) {
|
|
|
19870
19924
|
if (!isNil_1(nextChild) && !isNil_1(prevChild)) {
|
|
19871
19925
|
var _ref = nextChild.props || {},
|
|
19872
19926
|
nextChildren = _ref.children,
|
|
19873
|
-
nextProps = _objectWithoutProperties$
|
|
19927
|
+
nextProps = _objectWithoutProperties$c(_ref, _excluded$c);
|
|
19874
19928
|
var _ref2 = prevChild.props || {},
|
|
19875
19929
|
prevChildren = _ref2.children,
|
|
19876
|
-
prevProps = _objectWithoutProperties$
|
|
19930
|
+
prevProps = _objectWithoutProperties$c(_ref2, _excluded2$2);
|
|
19877
19931
|
if (nextChildren && prevChildren) {
|
|
19878
19932
|
return shallowEqual(nextProps, prevProps) && isChildrenEqual(nextChildren, prevChildren);
|
|
19879
19933
|
}
|
|
@@ -19915,10 +19969,10 @@ var parseChildIndex = function parseChildIndex(child, children) {
|
|
|
19915
19969
|
return toArray(children).indexOf(child);
|
|
19916
19970
|
};
|
|
19917
19971
|
|
|
19918
|
-
var _excluded$
|
|
19972
|
+
var _excluded$b = ["children", "width", "height", "viewBox", "className", "style"];
|
|
19919
19973
|
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); }
|
|
19920
|
-
function _objectWithoutProperties$
|
|
19921
|
-
function _objectWithoutPropertiesLoose$
|
|
19974
|
+
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; }
|
|
19975
|
+
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; }
|
|
19922
19976
|
function Surface(props) {
|
|
19923
19977
|
var children = props.children,
|
|
19924
19978
|
width = props.width,
|
|
@@ -19926,7 +19980,7 @@ function Surface(props) {
|
|
|
19926
19980
|
viewBox = props.viewBox,
|
|
19927
19981
|
className = props.className,
|
|
19928
19982
|
style = props.style,
|
|
19929
|
-
others = _objectWithoutProperties$
|
|
19983
|
+
others = _objectWithoutProperties$b(props, _excluded$b);
|
|
19930
19984
|
var svgView = viewBox || {
|
|
19931
19985
|
width: width,
|
|
19932
19986
|
height: height,
|
|
@@ -19943,14 +19997,14 @@ function Surface(props) {
|
|
|
19943
19997
|
}), /*#__PURE__*/React__default.createElement("title", null, props.title), /*#__PURE__*/React__default.createElement("desc", null, props.desc), children);
|
|
19944
19998
|
}
|
|
19945
19999
|
|
|
19946
|
-
var _excluded$
|
|
20000
|
+
var _excluded$a = ["children", "className"];
|
|
19947
20001
|
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); }
|
|
19948
|
-
function _objectWithoutProperties$
|
|
19949
|
-
function _objectWithoutPropertiesLoose$
|
|
20002
|
+
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; }
|
|
20003
|
+
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; }
|
|
19950
20004
|
var Layer = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
|
|
19951
20005
|
var children = props.children,
|
|
19952
20006
|
className = props.className,
|
|
19953
|
-
others = _objectWithoutProperties$
|
|
20007
|
+
others = _objectWithoutProperties$a(props, _excluded$a);
|
|
19954
20008
|
var layerClass = classNames('recharts-layer', className);
|
|
19955
20009
|
return /*#__PURE__*/React__default.createElement("g", _extends$l({
|
|
19956
20010
|
className: layerClass
|
|
@@ -23365,16 +23419,7 @@ function stackOffsetWiggle(series, order) {
|
|
|
23365
23419
|
stackOffsetNone(series, order);
|
|
23366
23420
|
}
|
|
23367
23421
|
|
|
23368
|
-
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); }
|
|
23369
|
-
var _excluded$c = ["type", "size", "sizeType"];
|
|
23370
23422
|
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); }
|
|
23371
|
-
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; }
|
|
23372
|
-
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; }
|
|
23373
|
-
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; }
|
|
23374
|
-
function _toPropertyKey$t(arg) { var key = _toPrimitive$t(arg, "string"); return _typeof$u(key) === "symbol" ? key : String(key); }
|
|
23375
|
-
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); }
|
|
23376
|
-
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; }
|
|
23377
|
-
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; }
|
|
23378
23423
|
var symbolFactories = {
|
|
23379
23424
|
symbolCircle: symbolCircle,
|
|
23380
23425
|
symbolCross: symbolCross,
|
|
@@ -23413,35 +23458,31 @@ var calculateAreaSize = function calculateAreaSize(size, sizeType, type) {
|
|
|
23413
23458
|
return Math.PI * size * size / 4;
|
|
23414
23459
|
}
|
|
23415
23460
|
};
|
|
23461
|
+
var symbolsDefaultProps = {
|
|
23462
|
+
type: 'circle',
|
|
23463
|
+
size: 64,
|
|
23464
|
+
sizeType: 'area'
|
|
23465
|
+
};
|
|
23416
23466
|
var registerSymbol = function registerSymbol(key, factory) {
|
|
23417
23467
|
symbolFactories["symbol".concat(upperFirst_1(key))] = factory;
|
|
23418
23468
|
};
|
|
23419
|
-
var Symbols = function Symbols(
|
|
23420
|
-
var _ref$type = _ref.type,
|
|
23421
|
-
type = _ref$type === void 0 ? 'circle' : _ref$type,
|
|
23422
|
-
_ref$size = _ref.size,
|
|
23423
|
-
size = _ref$size === void 0 ? 64 : _ref$size,
|
|
23424
|
-
_ref$sizeType = _ref.sizeType,
|
|
23425
|
-
sizeType = _ref$sizeType === void 0 ? 'area' : _ref$sizeType,
|
|
23426
|
-
rest = _objectWithoutProperties$c(_ref, _excluded$c);
|
|
23427
|
-
var props = _objectSpread$s(_objectSpread$s({}, rest), {}, {
|
|
23428
|
-
type: type,
|
|
23429
|
-
size: size,
|
|
23430
|
-
sizeType: sizeType
|
|
23431
|
-
});
|
|
23432
|
-
|
|
23469
|
+
var Symbols = function Symbols(props) {
|
|
23433
23470
|
/**
|
|
23434
23471
|
* Calculate the path of curve
|
|
23435
23472
|
* @return {String} path
|
|
23436
23473
|
*/
|
|
23437
23474
|
var getPath = function getPath() {
|
|
23475
|
+
var size = props.size,
|
|
23476
|
+
sizeType = props.sizeType,
|
|
23477
|
+
type = props.type;
|
|
23438
23478
|
var symbolFactory = getSymbolFactory(type);
|
|
23439
23479
|
var symbol = Symbol$2().type(symbolFactory).size(calculateAreaSize(size, sizeType, type));
|
|
23440
23480
|
return symbol();
|
|
23441
23481
|
};
|
|
23442
23482
|
var className = props.className,
|
|
23443
23483
|
cx = props.cx,
|
|
23444
|
-
cy = props.cy
|
|
23484
|
+
cy = props.cy,
|
|
23485
|
+
size = props.size;
|
|
23445
23486
|
var filteredProps = filterProps(props, true);
|
|
23446
23487
|
if (cx === +cx && cy === +cy && size === +size) {
|
|
23447
23488
|
return /*#__PURE__*/React__default.createElement("path", _extends$k({}, filteredProps, {
|
|
@@ -23452,34 +23493,35 @@ var Symbols = function Symbols(_ref) {
|
|
|
23452
23493
|
}
|
|
23453
23494
|
return null;
|
|
23454
23495
|
};
|
|
23496
|
+
Symbols.defaultProps = symbolsDefaultProps;
|
|
23455
23497
|
Symbols.registerSymbol = registerSymbol;
|
|
23456
23498
|
|
|
23457
|
-
function _typeof$
|
|
23499
|
+
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); }
|
|
23458
23500
|
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); }
|
|
23459
|
-
function ownKeys$
|
|
23460
|
-
function _objectSpread$
|
|
23461
|
-
function _classCallCheck$
|
|
23462
|
-
function _defineProperties$
|
|
23463
|
-
function _createClass$
|
|
23464
|
-
function _inherits$
|
|
23465
|
-
function _setPrototypeOf$
|
|
23466
|
-
function _createSuper$
|
|
23467
|
-
function _possibleConstructorReturn$
|
|
23468
|
-
function _assertThisInitialized$
|
|
23469
|
-
function _isNativeReflectConstruct$
|
|
23470
|
-
function _getPrototypeOf$
|
|
23471
|
-
function _defineProperty$
|
|
23472
|
-
function _toPropertyKey$
|
|
23473
|
-
function _toPrimitive$
|
|
23501
|
+
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; }
|
|
23502
|
+
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; }
|
|
23503
|
+
function _classCallCheck$a(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23504
|
+
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); } }
|
|
23505
|
+
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; }
|
|
23506
|
+
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); }
|
|
23507
|
+
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); }
|
|
23508
|
+
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); }; }
|
|
23509
|
+
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); }
|
|
23510
|
+
function _assertThisInitialized$8(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
23511
|
+
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; } }
|
|
23512
|
+
function _getPrototypeOf$8(o) { _getPrototypeOf$8 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$8(o); }
|
|
23513
|
+
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; }
|
|
23514
|
+
function _toPropertyKey$p(arg) { var key = _toPrimitive$p(arg, "string"); return _typeof$q(key) === "symbol" ? key : String(key); }
|
|
23515
|
+
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); }
|
|
23474
23516
|
var SIZE = 32;
|
|
23475
23517
|
var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
23476
|
-
_inherits$
|
|
23477
|
-
var _super = _createSuper$
|
|
23518
|
+
_inherits$8(DefaultLegendContent, _PureComponent);
|
|
23519
|
+
var _super = _createSuper$8(DefaultLegendContent);
|
|
23478
23520
|
function DefaultLegendContent() {
|
|
23479
|
-
_classCallCheck$
|
|
23521
|
+
_classCallCheck$a(this, DefaultLegendContent);
|
|
23480
23522
|
return _super.apply(this, arguments);
|
|
23481
23523
|
}
|
|
23482
|
-
_createClass$
|
|
23524
|
+
_createClass$a(DefaultLegendContent, [{
|
|
23483
23525
|
key: "renderIcon",
|
|
23484
23526
|
value:
|
|
23485
23527
|
/**
|
|
@@ -23524,7 +23566,7 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23524
23566
|
});
|
|
23525
23567
|
}
|
|
23526
23568
|
if ( /*#__PURE__*/React__default.isValidElement(data.legendIcon)) {
|
|
23527
|
-
var iconProps = _objectSpread$
|
|
23569
|
+
var iconProps = _objectSpread$o({}, data);
|
|
23528
23570
|
delete iconProps.legendIcon;
|
|
23529
23571
|
return /*#__PURE__*/React__default.cloneElement(data.legendIcon, iconProps);
|
|
23530
23572
|
}
|
|
@@ -23572,7 +23614,7 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23572
23614
|
var finalFormatter = entry.formatter || formatter;
|
|
23573
23615
|
var className = classNames((_classNames = {
|
|
23574
23616
|
'recharts-legend-item': true
|
|
23575
|
-
}, _defineProperty$
|
|
23617
|
+
}, _defineProperty$q(_classNames, "legend-item-".concat(i), true), _defineProperty$q(_classNames, "inactive", entry.inactive), _classNames));
|
|
23576
23618
|
if (entry.type === 'none') {
|
|
23577
23619
|
return null;
|
|
23578
23620
|
}
|
|
@@ -23617,8 +23659,8 @@ var DefaultLegendContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
23617
23659
|
}]);
|
|
23618
23660
|
return DefaultLegendContent;
|
|
23619
23661
|
}(PureComponent);
|
|
23620
|
-
_defineProperty$
|
|
23621
|
-
_defineProperty$
|
|
23662
|
+
_defineProperty$q(DefaultLegendContent, "displayName", 'Legend');
|
|
23663
|
+
_defineProperty$q(DefaultLegendContent, "defaultProps", {
|
|
23622
23664
|
iconSize: 14,
|
|
23623
23665
|
layout: 'horizontal',
|
|
23624
23666
|
align: 'center',
|
|
@@ -23626,25 +23668,25 @@ _defineProperty$t(DefaultLegendContent, "defaultProps", {
|
|
|
23626
23668
|
inactiveColor: '#ccc'
|
|
23627
23669
|
});
|
|
23628
23670
|
|
|
23629
|
-
function _typeof$
|
|
23630
|
-
var _excluded$
|
|
23631
|
-
function ownKeys$
|
|
23632
|
-
function _objectSpread$
|
|
23633
|
-
function _classCallCheck$
|
|
23634
|
-
function _defineProperties$
|
|
23635
|
-
function _createClass$
|
|
23636
|
-
function _inherits$
|
|
23637
|
-
function _setPrototypeOf$
|
|
23638
|
-
function _createSuper$
|
|
23639
|
-
function _possibleConstructorReturn$
|
|
23640
|
-
function _assertThisInitialized$
|
|
23641
|
-
function _isNativeReflectConstruct$
|
|
23642
|
-
function _getPrototypeOf$
|
|
23643
|
-
function _defineProperty$
|
|
23644
|
-
function _toPropertyKey$
|
|
23645
|
-
function _toPrimitive$
|
|
23646
|
-
function _objectWithoutProperties$
|
|
23647
|
-
function _objectWithoutPropertiesLoose$
|
|
23671
|
+
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); }
|
|
23672
|
+
var _excluded$9 = ["ref"];
|
|
23673
|
+
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; }
|
|
23674
|
+
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; }
|
|
23675
|
+
function _classCallCheck$9(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23676
|
+
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); } }
|
|
23677
|
+
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; }
|
|
23678
|
+
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); }
|
|
23679
|
+
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); }
|
|
23680
|
+
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); }; }
|
|
23681
|
+
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); }
|
|
23682
|
+
function _assertThisInitialized$7(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
23683
|
+
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; } }
|
|
23684
|
+
function _getPrototypeOf$7(o) { _getPrototypeOf$7 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$7(o); }
|
|
23685
|
+
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; }
|
|
23686
|
+
function _toPropertyKey$o(arg) { var key = _toPrimitive$o(arg, "string"); return _typeof$p(key) === "symbol" ? key : String(key); }
|
|
23687
|
+
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); }
|
|
23688
|
+
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; }
|
|
23689
|
+
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; }
|
|
23648
23690
|
function defaultUniqBy$1(entry) {
|
|
23649
23691
|
return entry.value;
|
|
23650
23692
|
}
|
|
@@ -23665,27 +23707,27 @@ function renderContent$1(content, props) {
|
|
|
23665
23707
|
return /*#__PURE__*/React__default.createElement(content, props);
|
|
23666
23708
|
}
|
|
23667
23709
|
props.ref;
|
|
23668
|
-
var otherProps = _objectWithoutProperties$
|
|
23710
|
+
var otherProps = _objectWithoutProperties$9(props, _excluded$9);
|
|
23669
23711
|
return /*#__PURE__*/React__default.createElement(DefaultLegendContent, otherProps);
|
|
23670
23712
|
}
|
|
23671
23713
|
var EPS$2 = 1;
|
|
23672
23714
|
var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
23673
|
-
_inherits$
|
|
23674
|
-
var _super = _createSuper$
|
|
23715
|
+
_inherits$7(Legend, _PureComponent);
|
|
23716
|
+
var _super = _createSuper$7(Legend);
|
|
23675
23717
|
function Legend() {
|
|
23676
23718
|
var _this;
|
|
23677
|
-
_classCallCheck$
|
|
23719
|
+
_classCallCheck$9(this, Legend);
|
|
23678
23720
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
23679
23721
|
args[_key] = arguments[_key];
|
|
23680
23722
|
}
|
|
23681
23723
|
_this = _super.call.apply(_super, [this].concat(args));
|
|
23682
|
-
_defineProperty$
|
|
23724
|
+
_defineProperty$p(_assertThisInitialized$7(_this), "state", {
|
|
23683
23725
|
boxWidth: -1,
|
|
23684
23726
|
boxHeight: -1
|
|
23685
23727
|
});
|
|
23686
23728
|
return _this;
|
|
23687
23729
|
}
|
|
23688
|
-
_createClass$
|
|
23730
|
+
_createClass$9(Legend, [{
|
|
23689
23731
|
key: "componentDidMount",
|
|
23690
23732
|
value: function componentDidMount() {
|
|
23691
23733
|
this.updateBBox();
|
|
@@ -23760,7 +23802,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23760
23802
|
};
|
|
23761
23803
|
}
|
|
23762
23804
|
}
|
|
23763
|
-
return _objectSpread$
|
|
23805
|
+
return _objectSpread$n(_objectSpread$n({}, hPos), vPos);
|
|
23764
23806
|
}
|
|
23765
23807
|
}, {
|
|
23766
23808
|
key: "updateBBox",
|
|
@@ -23803,7 +23845,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23803
23845
|
wrapperStyle = _this$props2.wrapperStyle,
|
|
23804
23846
|
payloadUniqBy = _this$props2.payloadUniqBy,
|
|
23805
23847
|
payload = _this$props2.payload;
|
|
23806
|
-
var outerStyle = _objectSpread$
|
|
23848
|
+
var outerStyle = _objectSpread$n(_objectSpread$n({
|
|
23807
23849
|
position: 'absolute',
|
|
23808
23850
|
width: width || 'auto',
|
|
23809
23851
|
height: height || 'auto'
|
|
@@ -23814,7 +23856,7 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23814
23856
|
ref: function ref(node) {
|
|
23815
23857
|
_this2.wrapperNode = node;
|
|
23816
23858
|
}
|
|
23817
|
-
}, renderContent$1(content, _objectSpread$
|
|
23859
|
+
}, renderContent$1(content, _objectSpread$n(_objectSpread$n({}, this.props), {}, {
|
|
23818
23860
|
payload: getUniqPayload$1(payloadUniqBy, payload)
|
|
23819
23861
|
})));
|
|
23820
23862
|
}
|
|
@@ -23837,8 +23879,8 @@ var Legend = /*#__PURE__*/function (_PureComponent) {
|
|
|
23837
23879
|
}]);
|
|
23838
23880
|
return Legend;
|
|
23839
23881
|
}(PureComponent);
|
|
23840
|
-
_defineProperty$
|
|
23841
|
-
_defineProperty$
|
|
23882
|
+
_defineProperty$p(Legend, "displayName", 'Legend');
|
|
23883
|
+
_defineProperty$p(Legend, "defaultProps", {
|
|
23842
23884
|
iconSize: 14,
|
|
23843
23885
|
layout: 'horizontal',
|
|
23844
23886
|
align: 'center',
|
|
@@ -24402,13 +24444,13 @@ function setRafTimeout(callback) {
|
|
|
24402
24444
|
requestAnimationFrame(shouldUpdate);
|
|
24403
24445
|
}
|
|
24404
24446
|
|
|
24405
|
-
function _typeof$
|
|
24406
|
-
function _toArray(arr) { return _arrayWithHoles$
|
|
24407
|
-
function _nonIterableRest$
|
|
24408
|
-
function _unsupportedIterableToArray$
|
|
24409
|
-
function _arrayLikeToArray$
|
|
24447
|
+
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); }
|
|
24448
|
+
function _toArray(arr) { return _arrayWithHoles$b(arr) || _iterableToArray$b(arr) || _unsupportedIterableToArray$i(arr) || _nonIterableRest$b(); }
|
|
24449
|
+
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."); }
|
|
24450
|
+
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); }
|
|
24451
|
+
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; }
|
|
24410
24452
|
function _iterableToArray$b(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24411
|
-
function _arrayWithHoles$
|
|
24453
|
+
function _arrayWithHoles$b(arr) { if (Array.isArray(arr)) return arr; }
|
|
24412
24454
|
function createAnimateManager() {
|
|
24413
24455
|
var currStyle = {};
|
|
24414
24456
|
var handleChange = function handleChange() {
|
|
@@ -24435,7 +24477,7 @@ function createAnimateManager() {
|
|
|
24435
24477
|
setRafTimeout(setStyle.bind(null, restStyles));
|
|
24436
24478
|
return;
|
|
24437
24479
|
}
|
|
24438
|
-
if (_typeof$
|
|
24480
|
+
if (_typeof$o(_style) === 'object') {
|
|
24439
24481
|
currStyle = _style;
|
|
24440
24482
|
handleChange(currStyle);
|
|
24441
24483
|
}
|
|
@@ -24462,12 +24504,12 @@ function createAnimateManager() {
|
|
|
24462
24504
|
};
|
|
24463
24505
|
}
|
|
24464
24506
|
|
|
24465
|
-
function _typeof$
|
|
24466
|
-
function ownKeys$
|
|
24467
|
-
function _objectSpread$
|
|
24468
|
-
function _defineProperty$
|
|
24469
|
-
function _toPropertyKey$
|
|
24470
|
-
function _toPrimitive$
|
|
24507
|
+
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); }
|
|
24508
|
+
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; }
|
|
24509
|
+
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; }
|
|
24510
|
+
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; }
|
|
24511
|
+
function _toPropertyKey$n(arg) { var key = _toPrimitive$n(arg, "string"); return _typeof$n(key) === "symbol" ? key : String(key); }
|
|
24512
|
+
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); }
|
|
24471
24513
|
/* eslint no-console: 0 */
|
|
24472
24514
|
var PREFIX_LIST$1 = ['Webkit', 'Moz', 'O', 'ms'];
|
|
24473
24515
|
var IN_LINE_PREFIX_LIST = ['-webkit-', '-moz-', '-o-', '-ms-'];
|
|
@@ -24499,7 +24541,7 @@ var getDashCase = function getDashCase(name) {
|
|
|
24499
24541
|
*/
|
|
24500
24542
|
var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
24501
24543
|
if (IN_COMPATIBLE_PROPERTY.indexOf(name) === -1) {
|
|
24502
|
-
return _defineProperty$
|
|
24544
|
+
return _defineProperty$o({}, name, Number.isNaN(value) ? 0 : value);
|
|
24503
24545
|
}
|
|
24504
24546
|
var isTransition = name === 'transition';
|
|
24505
24547
|
var camelName = name.replace(/(\w)/, function (v) {
|
|
@@ -24510,7 +24552,7 @@ var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
|
24510
24552
|
if (isTransition) {
|
|
24511
24553
|
styleVal = value.replace(/(transform|transform-origin)/gim, "".concat(IN_LINE_PREFIX_LIST[i], "$1"));
|
|
24512
24554
|
}
|
|
24513
|
-
return _objectSpread$
|
|
24555
|
+
return _objectSpread$m(_objectSpread$m({}, result), {}, _defineProperty$o({}, property + camelName, styleVal));
|
|
24514
24556
|
}, {});
|
|
24515
24557
|
};
|
|
24516
24558
|
|
|
@@ -24520,7 +24562,7 @@ var generatePrefixStyle$1 = function generatePrefixStyle(name, value) {
|
|
|
24520
24562
|
*/
|
|
24521
24563
|
var mapObject = function mapObject(fn, obj) {
|
|
24522
24564
|
return Object.keys(obj).reduce(function (res, key) {
|
|
24523
|
-
return _objectSpread$
|
|
24565
|
+
return _objectSpread$m(_objectSpread$m({}, res), {}, _defineProperty$o({}, key, fn(key, obj[key])));
|
|
24524
24566
|
}, {});
|
|
24525
24567
|
};
|
|
24526
24568
|
|
|
@@ -24530,7 +24572,7 @@ var mapObject = function mapObject(fn, obj) {
|
|
|
24530
24572
|
*/
|
|
24531
24573
|
var translateStyle = function translateStyle(style) {
|
|
24532
24574
|
return Object.keys(style).reduce(function (res, key) {
|
|
24533
|
-
return _objectSpread$
|
|
24575
|
+
return _objectSpread$m(_objectSpread$m({}, res), generatePrefixStyle$1(key, res[key]));
|
|
24534
24576
|
}, style);
|
|
24535
24577
|
};
|
|
24536
24578
|
var getTransitionVal = function getTransitionVal(props, duration, easing) {
|
|
@@ -24558,16 +24600,16 @@ var warn$1 = function warn(condition, format, a, b, c, d, e, f) {
|
|
|
24558
24600
|
}
|
|
24559
24601
|
};
|
|
24560
24602
|
|
|
24561
|
-
function _slicedToArray$
|
|
24562
|
-
function _nonIterableRest$
|
|
24563
|
-
function _iterableToArrayLimit$
|
|
24564
|
-
function _arrayWithHoles$
|
|
24565
|
-
function _toConsumableArray$a(arr) { return _arrayWithoutHoles$a(arr) || _iterableToArray$a(arr) || _unsupportedIterableToArray$
|
|
24603
|
+
function _slicedToArray$a(arr, i) { return _arrayWithHoles$a(arr) || _iterableToArrayLimit$a(arr, i) || _unsupportedIterableToArray$h(arr, i) || _nonIterableRest$a(); }
|
|
24604
|
+
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."); }
|
|
24605
|
+
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; } }
|
|
24606
|
+
function _arrayWithHoles$a(arr) { if (Array.isArray(arr)) return arr; }
|
|
24607
|
+
function _toConsumableArray$a(arr) { return _arrayWithoutHoles$a(arr) || _iterableToArray$a(arr) || _unsupportedIterableToArray$h(arr) || _nonIterableSpread$a(); }
|
|
24566
24608
|
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."); }
|
|
24567
|
-
function _unsupportedIterableToArray$
|
|
24609
|
+
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); }
|
|
24568
24610
|
function _iterableToArray$a(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24569
|
-
function _arrayWithoutHoles$a(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24570
|
-
function _arrayLikeToArray$
|
|
24611
|
+
function _arrayWithoutHoles$a(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$h(arr); }
|
|
24612
|
+
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; }
|
|
24571
24613
|
var ACCURACY = 1e-4;
|
|
24572
24614
|
var cubicBezierFactor = function cubicBezierFactor(c1, c2) {
|
|
24573
24615
|
return [0, 3 * c1, 3 * c2 - 6 * c1, 3 * c1 - 3 * c2 + 1];
|
|
@@ -24643,7 +24685,7 @@ var configBezier = function configBezier() {
|
|
|
24643
24685
|
var _easing$1$split$0$spl = easing[1].split(')')[0].split(',').map(function (x) {
|
|
24644
24686
|
return parseFloat(x);
|
|
24645
24687
|
});
|
|
24646
|
-
var _easing$1$split$0$spl2 = _slicedToArray$
|
|
24688
|
+
var _easing$1$split$0$spl2 = _slicedToArray$a(_easing$1$split$0$spl, 4);
|
|
24647
24689
|
x1 = _easing$1$split$0$spl2[0];
|
|
24648
24690
|
y1 = _easing$1$split$0$spl2[1];
|
|
24649
24691
|
x2 = _easing$1$split$0$spl2[2];
|
|
@@ -24736,22 +24778,22 @@ var configEasing = function configEasing() {
|
|
|
24736
24778
|
return null;
|
|
24737
24779
|
};
|
|
24738
24780
|
|
|
24739
|
-
function _typeof$
|
|
24740
|
-
function _toConsumableArray$9(arr) { return _arrayWithoutHoles$9(arr) || _iterableToArray$9(arr) || _unsupportedIterableToArray$
|
|
24781
|
+
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); }
|
|
24782
|
+
function _toConsumableArray$9(arr) { return _arrayWithoutHoles$9(arr) || _iterableToArray$9(arr) || _unsupportedIterableToArray$g(arr) || _nonIterableSpread$9(); }
|
|
24741
24783
|
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."); }
|
|
24742
24784
|
function _iterableToArray$9(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24743
|
-
function _arrayWithoutHoles$9(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24744
|
-
function ownKeys$
|
|
24745
|
-
function _objectSpread$
|
|
24746
|
-
function _defineProperty$
|
|
24747
|
-
function _toPropertyKey$
|
|
24748
|
-
function _toPrimitive$
|
|
24749
|
-
function _slicedToArray$
|
|
24750
|
-
function _nonIterableRest$
|
|
24751
|
-
function _unsupportedIterableToArray$
|
|
24752
|
-
function _arrayLikeToArray$
|
|
24753
|
-
function _iterableToArrayLimit$
|
|
24754
|
-
function _arrayWithHoles$
|
|
24785
|
+
function _arrayWithoutHoles$9(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$g(arr); }
|
|
24786
|
+
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; }
|
|
24787
|
+
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; }
|
|
24788
|
+
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; }
|
|
24789
|
+
function _toPropertyKey$m(arg) { var key = _toPrimitive$m(arg, "string"); return _typeof$m(key) === "symbol" ? key : String(key); }
|
|
24790
|
+
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); }
|
|
24791
|
+
function _slicedToArray$9(arr, i) { return _arrayWithHoles$9(arr) || _iterableToArrayLimit$9(arr, i) || _unsupportedIterableToArray$g(arr, i) || _nonIterableRest$9(); }
|
|
24792
|
+
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."); }
|
|
24793
|
+
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); }
|
|
24794
|
+
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; }
|
|
24795
|
+
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; } }
|
|
24796
|
+
function _arrayWithHoles$9(arr) { if (Array.isArray(arr)) return arr; }
|
|
24755
24797
|
var alpha = function alpha(begin, end, k) {
|
|
24756
24798
|
return begin + (end - begin) * k;
|
|
24757
24799
|
};
|
|
@@ -24769,10 +24811,10 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24769
24811
|
var nextStepVals = mapObject(function (key, val) {
|
|
24770
24812
|
if (needContinue(val)) {
|
|
24771
24813
|
var _easing = easing(val.from, val.to, val.velocity),
|
|
24772
|
-
_easing2 = _slicedToArray$
|
|
24814
|
+
_easing2 = _slicedToArray$9(_easing, 2),
|
|
24773
24815
|
newX = _easing2[0],
|
|
24774
24816
|
newV = _easing2[1];
|
|
24775
|
-
return _objectSpread$
|
|
24817
|
+
return _objectSpread$l(_objectSpread$l({}, val), {}, {
|
|
24776
24818
|
from: newX,
|
|
24777
24819
|
velocity: newV
|
|
24778
24820
|
});
|
|
@@ -24782,7 +24824,7 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24782
24824
|
if (steps < 1) {
|
|
24783
24825
|
return mapObject(function (key, val) {
|
|
24784
24826
|
if (needContinue(val)) {
|
|
24785
|
-
return _objectSpread$
|
|
24827
|
+
return _objectSpread$l(_objectSpread$l({}, val), {}, {
|
|
24786
24828
|
velocity: alpha(val.velocity, nextStepVals[key].velocity, steps),
|
|
24787
24829
|
from: alpha(val.from, nextStepVals[key].from, steps)
|
|
24788
24830
|
});
|
|
@@ -24797,10 +24839,10 @@ var calStepperVals = function calStepperVals(easing, preVals, steps) {
|
|
|
24797
24839
|
var configUpdate = (function (from, to, easing, duration, render) {
|
|
24798
24840
|
var interKeys = getIntersectionKeys(from, to);
|
|
24799
24841
|
var timingStyle = interKeys.reduce(function (res, key) {
|
|
24800
|
-
return _objectSpread$
|
|
24842
|
+
return _objectSpread$l(_objectSpread$l({}, res), {}, _defineProperty$n({}, key, [from[key], to[key]]));
|
|
24801
24843
|
}, {});
|
|
24802
24844
|
var stepperStyle = interKeys.reduce(function (res, key) {
|
|
24803
|
-
return _objectSpread$
|
|
24845
|
+
return _objectSpread$l(_objectSpread$l({}, res), {}, _defineProperty$n({}, key, {
|
|
24804
24846
|
from: from[key],
|
|
24805
24847
|
velocity: 0,
|
|
24806
24848
|
to: to[key]
|
|
@@ -24830,7 +24872,7 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24830
24872
|
var steps = deltaTime / easing.dt;
|
|
24831
24873
|
stepperStyle = calStepperVals(easing, stepperStyle, steps);
|
|
24832
24874
|
// get union set and add compatible prefix
|
|
24833
|
-
render(_objectSpread$
|
|
24875
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), getCurrStyle()));
|
|
24834
24876
|
preTime = now;
|
|
24835
24877
|
if (!shouldStopAnimation()) {
|
|
24836
24878
|
cafId = requestAnimationFrame(update);
|
|
@@ -24848,14 +24890,14 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24848
24890
|
}, timingStyle);
|
|
24849
24891
|
|
|
24850
24892
|
// get union set and add compatible prefix
|
|
24851
|
-
render(_objectSpread$
|
|
24893
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), currStyle));
|
|
24852
24894
|
if (t < 1) {
|
|
24853
24895
|
cafId = requestAnimationFrame(update);
|
|
24854
24896
|
} else {
|
|
24855
24897
|
var finalStyle = mapObject(function (key, val) {
|
|
24856
24898
|
return alpha.apply(void 0, _toConsumableArray$9(val).concat([easing(1)]));
|
|
24857
24899
|
}, timingStyle);
|
|
24858
|
-
render(_objectSpread$
|
|
24900
|
+
render(_objectSpread$l(_objectSpread$l(_objectSpread$l({}, from), to), finalStyle));
|
|
24859
24901
|
}
|
|
24860
24902
|
};
|
|
24861
24903
|
update = easing.isStepper ? stepperUpdate : timingUpdate;
|
|
@@ -24871,37 +24913,37 @@ var configUpdate = (function (from, to, easing, duration, render) {
|
|
|
24871
24913
|
};
|
|
24872
24914
|
});
|
|
24873
24915
|
|
|
24874
|
-
function _typeof$
|
|
24875
|
-
var _excluded$
|
|
24876
|
-
function _objectWithoutProperties$
|
|
24877
|
-
function _objectWithoutPropertiesLoose$
|
|
24878
|
-
function _toConsumableArray$8(arr) { return _arrayWithoutHoles$8(arr) || _iterableToArray$8(arr) || _unsupportedIterableToArray$
|
|
24916
|
+
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); }
|
|
24917
|
+
var _excluded$8 = ["children", "begin", "duration", "attributeName", "easing", "isActive", "steps", "from", "to", "canBegin", "onAnimationEnd", "shouldReAnimate", "onAnimationReStart"];
|
|
24918
|
+
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; }
|
|
24919
|
+
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; }
|
|
24920
|
+
function _toConsumableArray$8(arr) { return _arrayWithoutHoles$8(arr) || _iterableToArray$8(arr) || _unsupportedIterableToArray$f(arr) || _nonIterableSpread$8(); }
|
|
24879
24921
|
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."); }
|
|
24880
|
-
function _unsupportedIterableToArray$
|
|
24922
|
+
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); }
|
|
24881
24923
|
function _iterableToArray$8(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
24882
|
-
function _arrayWithoutHoles$8(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$
|
|
24883
|
-
function _arrayLikeToArray$
|
|
24884
|
-
function ownKeys$
|
|
24885
|
-
function _objectSpread$
|
|
24886
|
-
function _defineProperty$
|
|
24887
|
-
function _classCallCheck$
|
|
24888
|
-
function _defineProperties$
|
|
24889
|
-
function _createClass$
|
|
24890
|
-
function _toPropertyKey$
|
|
24891
|
-
function _toPrimitive$
|
|
24892
|
-
function _inherits$
|
|
24893
|
-
function _setPrototypeOf$
|
|
24894
|
-
function _createSuper$
|
|
24895
|
-
function _possibleConstructorReturn$
|
|
24896
|
-
function _assertThisInitialized$
|
|
24897
|
-
function _isNativeReflectConstruct$
|
|
24898
|
-
function _getPrototypeOf$
|
|
24924
|
+
function _arrayWithoutHoles$8(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$f(arr); }
|
|
24925
|
+
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; }
|
|
24926
|
+
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; }
|
|
24927
|
+
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; }
|
|
24928
|
+
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; }
|
|
24929
|
+
function _classCallCheck$8(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
24930
|
+
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); } }
|
|
24931
|
+
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; }
|
|
24932
|
+
function _toPropertyKey$l(arg) { var key = _toPrimitive$l(arg, "string"); return _typeof$l(key) === "symbol" ? key : String(key); }
|
|
24933
|
+
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); }
|
|
24934
|
+
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); }
|
|
24935
|
+
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); }
|
|
24936
|
+
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); }; }
|
|
24937
|
+
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); }
|
|
24938
|
+
function _assertThisInitialized$6(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
24939
|
+
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; } }
|
|
24940
|
+
function _getPrototypeOf$6(o) { _getPrototypeOf$6 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$6(o); }
|
|
24899
24941
|
var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
24900
|
-
_inherits$
|
|
24901
|
-
var _super = _createSuper$
|
|
24942
|
+
_inherits$6(Animate, _PureComponent);
|
|
24943
|
+
var _super = _createSuper$6(Animate);
|
|
24902
24944
|
function Animate(props, context) {
|
|
24903
24945
|
var _this;
|
|
24904
|
-
_classCallCheck$
|
|
24946
|
+
_classCallCheck$8(this, Animate);
|
|
24905
24947
|
_this = _super.call(this, props, context);
|
|
24906
24948
|
var _this$props = _this.props,
|
|
24907
24949
|
isActive = _this$props.isActive,
|
|
@@ -24911,8 +24953,8 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24911
24953
|
steps = _this$props.steps,
|
|
24912
24954
|
children = _this$props.children,
|
|
24913
24955
|
duration = _this$props.duration;
|
|
24914
|
-
_this.handleStyleChange = _this.handleStyleChange.bind(_assertThisInitialized$
|
|
24915
|
-
_this.changeStyle = _this.changeStyle.bind(_assertThisInitialized$
|
|
24956
|
+
_this.handleStyleChange = _this.handleStyleChange.bind(_assertThisInitialized$6(_this));
|
|
24957
|
+
_this.changeStyle = _this.changeStyle.bind(_assertThisInitialized$6(_this));
|
|
24916
24958
|
if (!isActive || duration <= 0) {
|
|
24917
24959
|
_this.state = {
|
|
24918
24960
|
style: {}
|
|
@@ -24924,7 +24966,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24924
24966
|
style: to
|
|
24925
24967
|
};
|
|
24926
24968
|
}
|
|
24927
|
-
return _possibleConstructorReturn$
|
|
24969
|
+
return _possibleConstructorReturn$6(_this);
|
|
24928
24970
|
}
|
|
24929
24971
|
if (steps && steps.length) {
|
|
24930
24972
|
_this.state = {
|
|
@@ -24935,10 +24977,10 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24935
24977
|
_this.state = {
|
|
24936
24978
|
style: from
|
|
24937
24979
|
};
|
|
24938
|
-
return _possibleConstructorReturn$
|
|
24980
|
+
return _possibleConstructorReturn$6(_this);
|
|
24939
24981
|
}
|
|
24940
24982
|
_this.state = {
|
|
24941
|
-
style: attributeName ? _defineProperty$
|
|
24983
|
+
style: attributeName ? _defineProperty$m({}, attributeName, from) : from
|
|
24942
24984
|
};
|
|
24943
24985
|
} else {
|
|
24944
24986
|
_this.state = {
|
|
@@ -24947,7 +24989,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24947
24989
|
}
|
|
24948
24990
|
return _this;
|
|
24949
24991
|
}
|
|
24950
|
-
_createClass$
|
|
24992
|
+
_createClass$8(Animate, [{
|
|
24951
24993
|
key: "componentDidMount",
|
|
24952
24994
|
value: function componentDidMount() {
|
|
24953
24995
|
var _this$props2 = this.props,
|
|
@@ -24975,7 +25017,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24975
25017
|
}
|
|
24976
25018
|
if (!isActive) {
|
|
24977
25019
|
var newState = {
|
|
24978
|
-
style: attributeName ? _defineProperty$
|
|
25020
|
+
style: attributeName ? _defineProperty$m({}, attributeName, to) : to
|
|
24979
25021
|
};
|
|
24980
25022
|
if (this.state && style) {
|
|
24981
25023
|
if (attributeName && style[attributeName] !== to || !attributeName && style !== to) {
|
|
@@ -24998,14 +25040,14 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
24998
25040
|
var from = isTriggered || shouldReAnimate ? currentFrom : prevProps.to;
|
|
24999
25041
|
if (this.state && style) {
|
|
25000
25042
|
var _newState = {
|
|
25001
|
-
style: attributeName ? _defineProperty$
|
|
25043
|
+
style: attributeName ? _defineProperty$m({}, attributeName, from) : from
|
|
25002
25044
|
};
|
|
25003
25045
|
if (attributeName && [attributeName] !== from || !attributeName && style !== from) {
|
|
25004
25046
|
// eslint-disable-next-line react/no-did-update-set-state
|
|
25005
25047
|
this.setState(_newState);
|
|
25006
25048
|
}
|
|
25007
25049
|
}
|
|
25008
|
-
this.runAnimation(_objectSpread$
|
|
25050
|
+
this.runAnimation(_objectSpread$k(_objectSpread$k({}, this.props), {}, {
|
|
25009
25051
|
from: from,
|
|
25010
25052
|
begin: 0
|
|
25011
25053
|
}));
|
|
@@ -25088,7 +25130,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25088
25130
|
}), duration]);
|
|
25089
25131
|
}
|
|
25090
25132
|
var transition = getTransitionVal(properties, duration, easing);
|
|
25091
|
-
var newStyle = _objectSpread$
|
|
25133
|
+
var newStyle = _objectSpread$k(_objectSpread$k(_objectSpread$k({}, preItem.style), style), {}, {
|
|
25092
25134
|
transition: transition
|
|
25093
25135
|
});
|
|
25094
25136
|
return [].concat(_toConsumableArray$8(sequence), [newStyle, duration, onAnimationEnd]).filter(identity$9);
|
|
@@ -25120,9 +25162,9 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25120
25162
|
this.runStepAnimation(props);
|
|
25121
25163
|
return;
|
|
25122
25164
|
}
|
|
25123
|
-
var to = attributeName ? _defineProperty$
|
|
25165
|
+
var to = attributeName ? _defineProperty$m({}, attributeName, propsTo) : propsTo;
|
|
25124
25166
|
var transition = getTransitionVal(Object.keys(to), duration, easing);
|
|
25125
|
-
manager.start([onAnimationStart, begin, _objectSpread$
|
|
25167
|
+
manager.start([onAnimationStart, begin, _objectSpread$k(_objectSpread$k({}, to), {}, {
|
|
25126
25168
|
transition: transition
|
|
25127
25169
|
}), duration, onAnimationEnd]);
|
|
25128
25170
|
}
|
|
@@ -25143,7 +25185,7 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25143
25185
|
_this$props4.onAnimationEnd;
|
|
25144
25186
|
_this$props4.shouldReAnimate;
|
|
25145
25187
|
_this$props4.onAnimationReStart;
|
|
25146
|
-
var others = _objectWithoutProperties$
|
|
25188
|
+
var others = _objectWithoutProperties$8(_this$props4, _excluded$8);
|
|
25147
25189
|
var count = Children.count(children);
|
|
25148
25190
|
// eslint-disable-next-line react/destructuring-assignment
|
|
25149
25191
|
var stateStyle = translateStyle(this.state.style);
|
|
@@ -25158,8 +25200,8 @@ var Animate = /*#__PURE__*/function (_PureComponent) {
|
|
|
25158
25200
|
_container$props$styl = _container$props.style,
|
|
25159
25201
|
style = _container$props$styl === void 0 ? {} : _container$props$styl,
|
|
25160
25202
|
className = _container$props.className;
|
|
25161
|
-
var res = /*#__PURE__*/cloneElement(container, _objectSpread$
|
|
25162
|
-
style: _objectSpread$
|
|
25203
|
+
var res = /*#__PURE__*/cloneElement(container, _objectSpread$k(_objectSpread$k({}, others), {}, {
|
|
25204
|
+
style: _objectSpread$k(_objectSpread$k({}, style), stateStyle),
|
|
25163
25205
|
className: className
|
|
25164
25206
|
}));
|
|
25165
25207
|
return res;
|
|
@@ -25684,10 +25726,10 @@ var defineProperty$2 = (function() {
|
|
|
25684
25726
|
} catch (e) {}
|
|
25685
25727
|
}());
|
|
25686
25728
|
|
|
25687
|
-
var _defineProperty$
|
|
25729
|
+
var _defineProperty$l = defineProperty$2;
|
|
25688
25730
|
|
|
25689
25731
|
var constant$1 = constant_1,
|
|
25690
|
-
defineProperty$1 = _defineProperty$
|
|
25732
|
+
defineProperty$1 = _defineProperty$l,
|
|
25691
25733
|
identity$7 = identity_1;
|
|
25692
25734
|
|
|
25693
25735
|
/**
|
|
@@ -25864,18 +25906,18 @@ var sortBy_1 = sortBy;
|
|
|
25864
25906
|
/**
|
|
25865
25907
|
* @fileOverview Default Tooltip Content
|
|
25866
25908
|
*/
|
|
25867
|
-
function _typeof$
|
|
25868
|
-
function _slicedToArray$
|
|
25869
|
-
function _nonIterableRest$
|
|
25870
|
-
function _unsupportedIterableToArray$
|
|
25871
|
-
function _arrayLikeToArray$
|
|
25872
|
-
function _iterableToArrayLimit$
|
|
25873
|
-
function _arrayWithHoles$
|
|
25874
|
-
function ownKeys$
|
|
25875
|
-
function _objectSpread$
|
|
25876
|
-
function _defineProperty$
|
|
25877
|
-
function _toPropertyKey$
|
|
25878
|
-
function _toPrimitive$
|
|
25909
|
+
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); }
|
|
25910
|
+
function _slicedToArray$8(arr, i) { return _arrayWithHoles$8(arr) || _iterableToArrayLimit$8(arr, i) || _unsupportedIterableToArray$e(arr, i) || _nonIterableRest$8(); }
|
|
25911
|
+
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."); }
|
|
25912
|
+
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); }
|
|
25913
|
+
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; }
|
|
25914
|
+
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; } }
|
|
25915
|
+
function _arrayWithHoles$8(arr) { if (Array.isArray(arr)) return arr; }
|
|
25916
|
+
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; }
|
|
25917
|
+
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; }
|
|
25918
|
+
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; }
|
|
25919
|
+
function _toPropertyKey$k(arg) { var key = _toPrimitive$k(arg, "string"); return _typeof$k(key) === "symbol" ? key : String(key); }
|
|
25920
|
+
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); }
|
|
25879
25921
|
function defaultFormatter(value) {
|
|
25880
25922
|
return isArray_1(value) && isNumOrStr(value[0]) && isNumOrStr(value[1]) ? value.join(' ~ ') : value;
|
|
25881
25923
|
}
|
|
@@ -25905,7 +25947,7 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25905
25947
|
if (entry.type === 'none') {
|
|
25906
25948
|
return null;
|
|
25907
25949
|
}
|
|
25908
|
-
var finalItemStyle = _objectSpread$
|
|
25950
|
+
var finalItemStyle = _objectSpread$j({
|
|
25909
25951
|
display: 'block',
|
|
25910
25952
|
paddingTop: 4,
|
|
25911
25953
|
paddingBottom: 4,
|
|
@@ -25919,7 +25961,7 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25919
25961
|
if (finalFormatter && finalValue != null && finalName != null) {
|
|
25920
25962
|
var formatted = finalFormatter(value, name, entry, i, payload);
|
|
25921
25963
|
if (Array.isArray(formatted)) {
|
|
25922
|
-
var _formatted = _slicedToArray$
|
|
25964
|
+
var _formatted = _slicedToArray$8(formatted, 2);
|
|
25923
25965
|
finalValue = _formatted[0];
|
|
25924
25966
|
finalName = _formatted[1];
|
|
25925
25967
|
} else {
|
|
@@ -25951,14 +25993,14 @@ var DefaultTooltipContent = function DefaultTooltipContent(props) {
|
|
|
25951
25993
|
}
|
|
25952
25994
|
return null;
|
|
25953
25995
|
};
|
|
25954
|
-
var finalStyle = _objectSpread$
|
|
25996
|
+
var finalStyle = _objectSpread$j({
|
|
25955
25997
|
margin: 0,
|
|
25956
25998
|
padding: 10,
|
|
25957
25999
|
backgroundColor: '#fff',
|
|
25958
26000
|
border: '1px solid #ccc',
|
|
25959
26001
|
whiteSpace: 'nowrap'
|
|
25960
26002
|
}, contentStyle);
|
|
25961
|
-
var finalLabelStyle = _objectSpread$
|
|
26003
|
+
var finalLabelStyle = _objectSpread$j({
|
|
25962
26004
|
margin: 0
|
|
25963
26005
|
}, labelStyle);
|
|
25964
26006
|
var hasLabel = !isNil_1(label);
|
|
@@ -25999,22 +26041,18 @@ var Global = {
|
|
|
25999
26041
|
}
|
|
26000
26042
|
};
|
|
26001
26043
|
|
|
26002
|
-
function _typeof$
|
|
26003
|
-
function ownKeys$
|
|
26004
|
-
function _objectSpread$
|
|
26005
|
-
function
|
|
26006
|
-
function
|
|
26007
|
-
function
|
|
26008
|
-
function
|
|
26009
|
-
function
|
|
26010
|
-
function
|
|
26011
|
-
function
|
|
26012
|
-
function
|
|
26013
|
-
function
|
|
26014
|
-
function _getPrototypeOf$6(o) { _getPrototypeOf$6 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$6(o); }
|
|
26015
|
-
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; }
|
|
26016
|
-
function _toPropertyKey$m(arg) { var key = _toPrimitive$m(arg, "string"); return _typeof$m(key) === "symbol" ? key : String(key); }
|
|
26017
|
-
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); }
|
|
26044
|
+
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); }
|
|
26045
|
+
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; }
|
|
26046
|
+
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; }
|
|
26047
|
+
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; }
|
|
26048
|
+
function _toPropertyKey$j(arg) { var key = _toPrimitive$j(arg, "string"); return _typeof$j(key) === "symbol" ? key : String(key); }
|
|
26049
|
+
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); }
|
|
26050
|
+
function _slicedToArray$7(arr, i) { return _arrayWithHoles$7(arr) || _iterableToArrayLimit$7(arr, i) || _unsupportedIterableToArray$d(arr, i) || _nonIterableRest$7(); }
|
|
26051
|
+
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."); }
|
|
26052
|
+
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); }
|
|
26053
|
+
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; }
|
|
26054
|
+
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; } }
|
|
26055
|
+
function _arrayWithHoles$7(arr) { if (Array.isArray(arr)) return arr; }
|
|
26018
26056
|
var CLS_PREFIX = 'recharts-tooltip-wrapper';
|
|
26019
26057
|
var EPS$1 = 1;
|
|
26020
26058
|
function defaultUniqBy(entry) {
|
|
@@ -26038,204 +26076,7 @@ function renderContent(content, props) {
|
|
|
26038
26076
|
}
|
|
26039
26077
|
return /*#__PURE__*/React__default.createElement(DefaultTooltipContent, props);
|
|
26040
26078
|
}
|
|
26041
|
-
var
|
|
26042
|
-
_inherits$6(Tooltip, _PureComponent);
|
|
26043
|
-
var _super = _createSuper$6(Tooltip);
|
|
26044
|
-
function Tooltip() {
|
|
26045
|
-
var _this;
|
|
26046
|
-
_classCallCheck$8(this, Tooltip);
|
|
26047
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
26048
|
-
args[_key] = arguments[_key];
|
|
26049
|
-
}
|
|
26050
|
-
_this = _super.call.apply(_super, [this].concat(args));
|
|
26051
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "state", {
|
|
26052
|
-
boxWidth: -1,
|
|
26053
|
-
boxHeight: -1,
|
|
26054
|
-
dismissed: false,
|
|
26055
|
-
dismissedAtCoordinate: {
|
|
26056
|
-
x: 0,
|
|
26057
|
-
y: 0
|
|
26058
|
-
}
|
|
26059
|
-
});
|
|
26060
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "handleKeyDown", function (event) {
|
|
26061
|
-
if (event.key === 'Escape') {
|
|
26062
|
-
_this.setState({
|
|
26063
|
-
dismissed: true,
|
|
26064
|
-
dismissedAtCoordinate: _objectSpread$l(_objectSpread$l({}, _this.state.dismissedAtCoordinate), {}, {
|
|
26065
|
-
x: _this.props.coordinate.x,
|
|
26066
|
-
y: _this.props.coordinate.y
|
|
26067
|
-
})
|
|
26068
|
-
});
|
|
26069
|
-
}
|
|
26070
|
-
});
|
|
26071
|
-
_defineProperty$m(_assertThisInitialized$6(_this), "getTranslate", function (_ref) {
|
|
26072
|
-
var key = _ref.key,
|
|
26073
|
-
tooltipDimension = _ref.tooltipDimension,
|
|
26074
|
-
viewBoxDimension = _ref.viewBoxDimension;
|
|
26075
|
-
var _this$props = _this.props,
|
|
26076
|
-
allowEscapeViewBox = _this$props.allowEscapeViewBox,
|
|
26077
|
-
reverseDirection = _this$props.reverseDirection,
|
|
26078
|
-
coordinate = _this$props.coordinate,
|
|
26079
|
-
offset = _this$props.offset,
|
|
26080
|
-
position = _this$props.position,
|
|
26081
|
-
viewBox = _this$props.viewBox;
|
|
26082
|
-
if (position && isNumber(position[key])) {
|
|
26083
|
-
return position[key];
|
|
26084
|
-
}
|
|
26085
|
-
var negative = coordinate[key] - tooltipDimension - offset;
|
|
26086
|
-
var positive = coordinate[key] + offset;
|
|
26087
|
-
if (allowEscapeViewBox[key]) {
|
|
26088
|
-
return reverseDirection[key] ? negative : positive;
|
|
26089
|
-
}
|
|
26090
|
-
if (reverseDirection[key]) {
|
|
26091
|
-
var _tooltipBoundary = negative;
|
|
26092
|
-
var _viewBoxBoundary = viewBox[key];
|
|
26093
|
-
if (_tooltipBoundary < _viewBoxBoundary) {
|
|
26094
|
-
return Math.max(positive, viewBox[key]);
|
|
26095
|
-
}
|
|
26096
|
-
return Math.max(negative, viewBox[key]);
|
|
26097
|
-
}
|
|
26098
|
-
var tooltipBoundary = positive + tooltipDimension;
|
|
26099
|
-
var viewBoxBoundary = viewBox[key] + viewBoxDimension;
|
|
26100
|
-
if (tooltipBoundary > viewBoxBoundary) {
|
|
26101
|
-
return Math.max(negative, viewBox[key]);
|
|
26102
|
-
}
|
|
26103
|
-
return Math.max(positive, viewBox[key]);
|
|
26104
|
-
});
|
|
26105
|
-
return _this;
|
|
26106
|
-
}
|
|
26107
|
-
_createClass$8(Tooltip, [{
|
|
26108
|
-
key: "componentDidMount",
|
|
26109
|
-
value: function componentDidMount() {
|
|
26110
|
-
this.updateBBox();
|
|
26111
|
-
}
|
|
26112
|
-
}, {
|
|
26113
|
-
key: "componentWillUnmount",
|
|
26114
|
-
value: function componentWillUnmount() {
|
|
26115
|
-
document.removeEventListener('keydown', this.handleKeyDown);
|
|
26116
|
-
}
|
|
26117
|
-
}, {
|
|
26118
|
-
key: "componentDidUpdate",
|
|
26119
|
-
value: function componentDidUpdate() {
|
|
26120
|
-
this.updateBBox();
|
|
26121
|
-
}
|
|
26122
|
-
}, {
|
|
26123
|
-
key: "updateBBox",
|
|
26124
|
-
value: function updateBBox() {
|
|
26125
|
-
var _this$state = this.state,
|
|
26126
|
-
boxWidth = _this$state.boxWidth,
|
|
26127
|
-
boxHeight = _this$state.boxHeight,
|
|
26128
|
-
dismissed = _this$state.dismissed;
|
|
26129
|
-
if (dismissed) {
|
|
26130
|
-
document.removeEventListener('keydown', this.handleKeyDown);
|
|
26131
|
-
if (this.props.coordinate.x !== this.state.dismissedAtCoordinate.x || this.props.coordinate.y !== this.state.dismissedAtCoordinate.y) {
|
|
26132
|
-
this.setState({
|
|
26133
|
-
dismissed: false
|
|
26134
|
-
});
|
|
26135
|
-
}
|
|
26136
|
-
} else {
|
|
26137
|
-
document.addEventListener('keydown', this.handleKeyDown);
|
|
26138
|
-
}
|
|
26139
|
-
if (this.wrapperNode && this.wrapperNode.getBoundingClientRect) {
|
|
26140
|
-
var box = this.wrapperNode.getBoundingClientRect();
|
|
26141
|
-
if (Math.abs(box.width - boxWidth) > EPS$1 || Math.abs(box.height - boxHeight) > EPS$1) {
|
|
26142
|
-
this.setState({
|
|
26143
|
-
boxWidth: box.width,
|
|
26144
|
-
boxHeight: box.height
|
|
26145
|
-
});
|
|
26146
|
-
}
|
|
26147
|
-
} else if (boxWidth !== -1 || boxHeight !== -1) {
|
|
26148
|
-
this.setState({
|
|
26149
|
-
boxWidth: -1,
|
|
26150
|
-
boxHeight: -1
|
|
26151
|
-
});
|
|
26152
|
-
}
|
|
26153
|
-
}
|
|
26154
|
-
}, {
|
|
26155
|
-
key: "render",
|
|
26156
|
-
value: function render() {
|
|
26157
|
-
var _classNames,
|
|
26158
|
-
_this2 = this;
|
|
26159
|
-
var _this$props2 = this.props,
|
|
26160
|
-
payload = _this$props2.payload,
|
|
26161
|
-
isAnimationActive = _this$props2.isAnimationActive,
|
|
26162
|
-
animationDuration = _this$props2.animationDuration,
|
|
26163
|
-
animationEasing = _this$props2.animationEasing,
|
|
26164
|
-
filterNull = _this$props2.filterNull,
|
|
26165
|
-
payloadUniqBy = _this$props2.payloadUniqBy;
|
|
26166
|
-
var finalPayload = getUniqPayload(payloadUniqBy, filterNull && payload && payload.length ? payload.filter(function (entry) {
|
|
26167
|
-
return !isNil_1(entry.value);
|
|
26168
|
-
}) : payload);
|
|
26169
|
-
var hasPayload = finalPayload && finalPayload.length;
|
|
26170
|
-
var _this$props3 = this.props,
|
|
26171
|
-
content = _this$props3.content,
|
|
26172
|
-
viewBox = _this$props3.viewBox,
|
|
26173
|
-
coordinate = _this$props3.coordinate,
|
|
26174
|
-
position = _this$props3.position,
|
|
26175
|
-
active = _this$props3.active,
|
|
26176
|
-
wrapperStyle = _this$props3.wrapperStyle;
|
|
26177
|
-
var outerStyle = _objectSpread$l({
|
|
26178
|
-
pointerEvents: 'none',
|
|
26179
|
-
visibility: !this.state.dismissed && active && hasPayload ? 'visible' : 'hidden',
|
|
26180
|
-
position: 'absolute',
|
|
26181
|
-
top: 0,
|
|
26182
|
-
left: 0
|
|
26183
|
-
}, wrapperStyle);
|
|
26184
|
-
var translateX, translateY;
|
|
26185
|
-
if (position && isNumber(position.x) && isNumber(position.y)) {
|
|
26186
|
-
translateX = position.x;
|
|
26187
|
-
translateY = position.y;
|
|
26188
|
-
} else {
|
|
26189
|
-
var _this$state2 = this.state,
|
|
26190
|
-
boxWidth = _this$state2.boxWidth,
|
|
26191
|
-
boxHeight = _this$state2.boxHeight;
|
|
26192
|
-
if (boxWidth > 0 && boxHeight > 0 && coordinate) {
|
|
26193
|
-
translateX = this.getTranslate({
|
|
26194
|
-
key: 'x',
|
|
26195
|
-
tooltipDimension: boxWidth,
|
|
26196
|
-
viewBoxDimension: viewBox.width
|
|
26197
|
-
});
|
|
26198
|
-
translateY = this.getTranslate({
|
|
26199
|
-
key: 'y',
|
|
26200
|
-
tooltipDimension: boxHeight,
|
|
26201
|
-
viewBoxDimension: viewBox.height
|
|
26202
|
-
});
|
|
26203
|
-
} else {
|
|
26204
|
-
outerStyle.visibility = 'hidden';
|
|
26205
|
-
}
|
|
26206
|
-
}
|
|
26207
|
-
outerStyle = _objectSpread$l(_objectSpread$l({}, translateStyle({
|
|
26208
|
-
transform: this.props.useTranslate3d ? "translate3d(".concat(translateX, "px, ").concat(translateY, "px, 0)") : "translate(".concat(translateX, "px, ").concat(translateY, "px)")
|
|
26209
|
-
})), outerStyle);
|
|
26210
|
-
if (isAnimationActive && active) {
|
|
26211
|
-
outerStyle = _objectSpread$l(_objectSpread$l({}, translateStyle({
|
|
26212
|
-
transition: "transform ".concat(animationDuration, "ms ").concat(animationEasing)
|
|
26213
|
-
})), outerStyle);
|
|
26214
|
-
}
|
|
26215
|
-
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));
|
|
26216
|
-
return (
|
|
26217
|
-
/*#__PURE__*/
|
|
26218
|
-
// ESLint is disabled to allow listening to the `Escape` key. Refer to
|
|
26219
|
-
// https://github.com/recharts/recharts/pull/2925
|
|
26220
|
-
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
|
|
26221
|
-
React__default.createElement("div", {
|
|
26222
|
-
tabIndex: -1,
|
|
26223
|
-
role: "dialog",
|
|
26224
|
-
className: cls,
|
|
26225
|
-
style: outerStyle,
|
|
26226
|
-
ref: function ref(node) {
|
|
26227
|
-
_this2.wrapperNode = node;
|
|
26228
|
-
}
|
|
26229
|
-
}, renderContent(content, _objectSpread$l(_objectSpread$l({}, this.props), {}, {
|
|
26230
|
-
payload: finalPayload
|
|
26231
|
-
})))
|
|
26232
|
-
);
|
|
26233
|
-
}
|
|
26234
|
-
}]);
|
|
26235
|
-
return Tooltip;
|
|
26236
|
-
}(PureComponent);
|
|
26237
|
-
_defineProperty$m(Tooltip$1, "displayName", 'Tooltip');
|
|
26238
|
-
_defineProperty$m(Tooltip$1, "defaultProps", {
|
|
26079
|
+
var tooltipDefaultProps = {
|
|
26239
26080
|
active: false,
|
|
26240
26081
|
allowEscapeViewBox: {
|
|
26241
26082
|
x: false,
|
|
@@ -26256,6 +26097,9 @@ _defineProperty$m(Tooltip$1, "defaultProps", {
|
|
|
26256
26097
|
x: 0,
|
|
26257
26098
|
y: 0
|
|
26258
26099
|
},
|
|
26100
|
+
// this doesn't exist on TooltipProps
|
|
26101
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
26102
|
+
// @ts-ignore
|
|
26259
26103
|
cursorStyle: {},
|
|
26260
26104
|
separator: ' : ',
|
|
26261
26105
|
wrapperStyle: {},
|
|
@@ -26269,7 +26113,173 @@ _defineProperty$m(Tooltip$1, "defaultProps", {
|
|
|
26269
26113
|
animationDuration: 400,
|
|
26270
26114
|
filterNull: true,
|
|
26271
26115
|
useTranslate3d: false
|
|
26272
|
-
}
|
|
26116
|
+
};
|
|
26117
|
+
var Tooltip$1 = function Tooltip(props) {
|
|
26118
|
+
var _classNames;
|
|
26119
|
+
var _useState = useState(-1),
|
|
26120
|
+
_useState2 = _slicedToArray$7(_useState, 2),
|
|
26121
|
+
boxWidth = _useState2[0],
|
|
26122
|
+
setBoxWidth = _useState2[1];
|
|
26123
|
+
var _useState3 = useState(-1),
|
|
26124
|
+
_useState4 = _slicedToArray$7(_useState3, 2),
|
|
26125
|
+
boxHeight = _useState4[0],
|
|
26126
|
+
setBoxHeight = _useState4[1];
|
|
26127
|
+
var _useState5 = useState(false),
|
|
26128
|
+
_useState6 = _slicedToArray$7(_useState5, 2),
|
|
26129
|
+
dismissed = _useState6[0],
|
|
26130
|
+
setDismissed = _useState6[1];
|
|
26131
|
+
var _useState7 = useState({
|
|
26132
|
+
x: 0,
|
|
26133
|
+
y: 0
|
|
26134
|
+
}),
|
|
26135
|
+
_useState8 = _slicedToArray$7(_useState7, 2),
|
|
26136
|
+
dismissedAtCoordinate = _useState8[0],
|
|
26137
|
+
setDismissedAtCoordinate = _useState8[1];
|
|
26138
|
+
var wrapperNode = useRef();
|
|
26139
|
+
var allowEscapeViewBox = props.allowEscapeViewBox,
|
|
26140
|
+
reverseDirection = props.reverseDirection,
|
|
26141
|
+
coordinate = props.coordinate,
|
|
26142
|
+
offset = props.offset,
|
|
26143
|
+
position = props.position,
|
|
26144
|
+
viewBox = props.viewBox;
|
|
26145
|
+
var handleKeyDown = useCallback(function (event) {
|
|
26146
|
+
if (event.key === 'Escape') {
|
|
26147
|
+
setDismissed(true);
|
|
26148
|
+
setDismissedAtCoordinate(function (prev) {
|
|
26149
|
+
return _objectSpread$i(_objectSpread$i({}, prev), {}, {
|
|
26150
|
+
x: coordinate === null || coordinate === void 0 ? void 0 : coordinate.x,
|
|
26151
|
+
y: coordinate === null || coordinate === void 0 ? void 0 : coordinate.y
|
|
26152
|
+
});
|
|
26153
|
+
});
|
|
26154
|
+
}
|
|
26155
|
+
}, [coordinate === null || coordinate === void 0 ? void 0 : coordinate.x, coordinate === null || coordinate === void 0 ? void 0 : coordinate.y]);
|
|
26156
|
+
useEffect(function () {
|
|
26157
|
+
var updateBBox = function updateBBox() {
|
|
26158
|
+
if (dismissed) {
|
|
26159
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
26160
|
+
if ((coordinate === null || coordinate === void 0 ? void 0 : coordinate.x) !== dismissedAtCoordinate.x || (coordinate === null || coordinate === void 0 ? void 0 : coordinate.y) !== dismissedAtCoordinate.y) {
|
|
26161
|
+
setDismissed(false);
|
|
26162
|
+
}
|
|
26163
|
+
} else {
|
|
26164
|
+
document.addEventListener('keydown', handleKeyDown);
|
|
26165
|
+
}
|
|
26166
|
+
if (wrapperNode.current && wrapperNode.current.getBoundingClientRect) {
|
|
26167
|
+
var box = wrapperNode.current.getBoundingClientRect();
|
|
26168
|
+
if (Math.abs(box.width - boxWidth) > EPS$1 || Math.abs(box.height - boxHeight) > EPS$1) {
|
|
26169
|
+
setBoxWidth(box.width);
|
|
26170
|
+
setBoxHeight(box.height);
|
|
26171
|
+
}
|
|
26172
|
+
} else if (boxWidth !== -1 || boxHeight !== -1) {
|
|
26173
|
+
setBoxWidth(-1);
|
|
26174
|
+
setBoxHeight(-1);
|
|
26175
|
+
}
|
|
26176
|
+
};
|
|
26177
|
+
updateBBox();
|
|
26178
|
+
return function () {
|
|
26179
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
26180
|
+
};
|
|
26181
|
+
}, [boxHeight, boxWidth, coordinate, dismissed, dismissedAtCoordinate.x, dismissedAtCoordinate.y, handleKeyDown]);
|
|
26182
|
+
var getTranslate = function getTranslate(_ref) {
|
|
26183
|
+
var key = _ref.key,
|
|
26184
|
+
tooltipDimension = _ref.tooltipDimension,
|
|
26185
|
+
viewBoxDimension = _ref.viewBoxDimension;
|
|
26186
|
+
if (position && isNumber(position[key])) {
|
|
26187
|
+
return position[key];
|
|
26188
|
+
}
|
|
26189
|
+
var negative = coordinate[key] - tooltipDimension - offset;
|
|
26190
|
+
var positive = coordinate[key] + offset;
|
|
26191
|
+
if (allowEscapeViewBox !== null && allowEscapeViewBox !== void 0 && allowEscapeViewBox[key]) {
|
|
26192
|
+
return reverseDirection[key] ? negative : positive;
|
|
26193
|
+
}
|
|
26194
|
+
if (reverseDirection !== null && reverseDirection !== void 0 && reverseDirection[key]) {
|
|
26195
|
+
var _tooltipBoundary = negative;
|
|
26196
|
+
var _viewBoxBoundary = viewBox[key];
|
|
26197
|
+
if (_tooltipBoundary < _viewBoxBoundary) {
|
|
26198
|
+
return Math.max(positive, viewBox[key]);
|
|
26199
|
+
}
|
|
26200
|
+
return Math.max(negative, viewBox[key]);
|
|
26201
|
+
}
|
|
26202
|
+
var tooltipBoundary = positive + tooltipDimension;
|
|
26203
|
+
var viewBoxBoundary = viewBox[key] + viewBoxDimension;
|
|
26204
|
+
if (tooltipBoundary > viewBoxBoundary) {
|
|
26205
|
+
return Math.max(negative, viewBox[key]);
|
|
26206
|
+
}
|
|
26207
|
+
return Math.max(positive, viewBox[key]);
|
|
26208
|
+
};
|
|
26209
|
+
var payload = props.payload,
|
|
26210
|
+
payloadUniqBy = props.payloadUniqBy,
|
|
26211
|
+
filterNull = props.filterNull,
|
|
26212
|
+
active = props.active,
|
|
26213
|
+
wrapperStyle = props.wrapperStyle,
|
|
26214
|
+
useTranslate3d = props.useTranslate3d,
|
|
26215
|
+
isAnimationActive = props.isAnimationActive,
|
|
26216
|
+
animationDuration = props.animationDuration,
|
|
26217
|
+
animationEasing = props.animationEasing;
|
|
26218
|
+
var finalPayload = getUniqPayload(payloadUniqBy, filterNull && payload && payload.length ? payload.filter(function (entry) {
|
|
26219
|
+
return !isNil_1(entry.value);
|
|
26220
|
+
}) : payload);
|
|
26221
|
+
var hasPayload = finalPayload && finalPayload.length;
|
|
26222
|
+
var content = props.content;
|
|
26223
|
+
var outerStyle = _objectSpread$i({
|
|
26224
|
+
pointerEvents: 'none',
|
|
26225
|
+
visibility: !dismissed && active && hasPayload ? 'visible' : 'hidden',
|
|
26226
|
+
position: 'absolute',
|
|
26227
|
+
top: 0,
|
|
26228
|
+
left: 0
|
|
26229
|
+
}, wrapperStyle);
|
|
26230
|
+
var translateX, translateY;
|
|
26231
|
+
if (position && isNumber(position.x) && isNumber(position.y)) {
|
|
26232
|
+
translateX = position.x;
|
|
26233
|
+
translateY = position.y;
|
|
26234
|
+
} else if (boxWidth > 0 && boxHeight > 0 && coordinate) {
|
|
26235
|
+
translateX = getTranslate({
|
|
26236
|
+
key: 'x',
|
|
26237
|
+
tooltipDimension: boxWidth,
|
|
26238
|
+
viewBoxDimension: viewBox.width
|
|
26239
|
+
});
|
|
26240
|
+
translateY = getTranslate({
|
|
26241
|
+
key: 'y',
|
|
26242
|
+
tooltipDimension: boxHeight,
|
|
26243
|
+
viewBoxDimension: viewBox.height
|
|
26244
|
+
});
|
|
26245
|
+
} else {
|
|
26246
|
+
outerStyle.visibility = 'hidden';
|
|
26247
|
+
}
|
|
26248
|
+
outerStyle = _objectSpread$i(_objectSpread$i({}, translateStyle({
|
|
26249
|
+
transform: useTranslate3d ? "translate3d(".concat(translateX, "px, ").concat(translateY, "px, 0)") : "translate(".concat(translateX, "px, ").concat(translateY, "px)")
|
|
26250
|
+
})), outerStyle);
|
|
26251
|
+
if (isAnimationActive && active) {
|
|
26252
|
+
outerStyle = _objectSpread$i(_objectSpread$i({}, translateStyle({
|
|
26253
|
+
transition: "transform ".concat(animationDuration, "ms ").concat(animationEasing)
|
|
26254
|
+
})), outerStyle);
|
|
26255
|
+
}
|
|
26256
|
+
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));
|
|
26257
|
+
return (
|
|
26258
|
+
/*#__PURE__*/
|
|
26259
|
+
// ESLint is disabled to allow listening to the `Escape` key. Refer to
|
|
26260
|
+
// https://github.com/recharts/recharts/pull/2925
|
|
26261
|
+
// eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
|
|
26262
|
+
React__default.createElement("div", {
|
|
26263
|
+
tabIndex: -1,
|
|
26264
|
+
role: "dialog",
|
|
26265
|
+
className: cls,
|
|
26266
|
+
style: outerStyle,
|
|
26267
|
+
ref: wrapperNode
|
|
26268
|
+
}, renderContent(content, _objectSpread$i(_objectSpread$i({}, props), {}, {
|
|
26269
|
+
payload: finalPayload
|
|
26270
|
+
})))
|
|
26271
|
+
);
|
|
26272
|
+
};
|
|
26273
|
+
|
|
26274
|
+
// needs to be set so that renderByOrder can find the correct handler function
|
|
26275
|
+
Tooltip$1.displayName = 'Tooltip';
|
|
26276
|
+
|
|
26277
|
+
/**
|
|
26278
|
+
* needs to be set so that renderByOrder can access an have default values for
|
|
26279
|
+
* children.props when there are no props set by the consumer
|
|
26280
|
+
* doesn't work if using default parameters
|
|
26281
|
+
*/
|
|
26282
|
+
Tooltip$1.defaultProps = tooltipDefaultProps;
|
|
26273
26283
|
|
|
26274
26284
|
var root = _root;
|
|
26275
26285
|
|
|
@@ -31839,12 +31849,12 @@ module.exports = exports['default'];
|
|
|
31839
31849
|
|
|
31840
31850
|
var reduceCSSCalc = /*@__PURE__*/getDefaultExportFromCjs(dist.exports);
|
|
31841
31851
|
|
|
31842
|
-
function _typeof$
|
|
31843
|
-
function ownKeys$
|
|
31844
|
-
function _objectSpread$
|
|
31845
|
-
function _defineProperty$
|
|
31846
|
-
function _toPropertyKey$
|
|
31847
|
-
function _toPrimitive$
|
|
31852
|
+
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); }
|
|
31853
|
+
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; }
|
|
31854
|
+
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; }
|
|
31855
|
+
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; }
|
|
31856
|
+
function _toPropertyKey$i(arg) { var key = _toPrimitive$i(arg, "string"); return _typeof$i(key) === "symbol" ? key : String(key); }
|
|
31857
|
+
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); }
|
|
31848
31858
|
function _toConsumableArray$7(arr) { return _arrayWithoutHoles$7(arr) || _iterableToArray$7(arr) || _unsupportedIterableToArray$b(arr) || _nonIterableSpread$7(); }
|
|
31849
31859
|
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."); }
|
|
31850
31860
|
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); }
|
|
@@ -31912,7 +31922,7 @@ var getStringSize = function getStringSize(text) {
|
|
|
31912
31922
|
}
|
|
31913
31923
|
// Need to use CSS Object Model (CSSOM) to be able to comply with Content Security Policy (CSP)
|
|
31914
31924
|
// https://en.wikipedia.org/wiki/Content_Security_Policy
|
|
31915
|
-
var measurementSpanStyle = _objectSpread$
|
|
31925
|
+
var measurementSpanStyle = _objectSpread$h(_objectSpread$h({}, SPAN_STYLE), style);
|
|
31916
31926
|
Object.keys(measurementSpanStyle).map(function (styleKey) {
|
|
31917
31927
|
measurementSpan.style[styleKey] = measurementSpanStyle[styleKey];
|
|
31918
31928
|
return styleKey;
|
|
@@ -31967,11 +31977,10 @@ var calculateChartCoordinate = function calculateChartCoordinate(event, offset)
|
|
|
31967
31977
|
};
|
|
31968
31978
|
};
|
|
31969
31979
|
|
|
31970
|
-
var _excluded$
|
|
31971
|
-
_excluded2$3 = ["dx", "dy", "angle", "className", "breakAll"];
|
|
31980
|
+
var _excluded$7 = ["dx", "dy", "textAnchor", "verticalAnchor", "scaleToFit", "angle", "lineHeight", "capHeight", "className", "breakAll"];
|
|
31972
31981
|
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); }
|
|
31973
|
-
function _objectWithoutProperties$
|
|
31974
|
-
function _objectWithoutPropertiesLoose$
|
|
31982
|
+
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; }
|
|
31983
|
+
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; }
|
|
31975
31984
|
function _slicedToArray$5(arr, i) { return _arrayWithHoles$5(arr) || _iterableToArrayLimit$5(arr, i) || _unsupportedIterableToArray$a(arr, i) || _nonIterableRest$5(); }
|
|
31976
31985
|
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."); }
|
|
31977
31986
|
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); }
|
|
@@ -32125,46 +32134,45 @@ var getWordsByLines = function getWordsByLines(_ref4) {
|
|
|
32125
32134
|
}
|
|
32126
32135
|
return getWordsWithoutCalculate(children);
|
|
32127
32136
|
};
|
|
32128
|
-
var
|
|
32129
|
-
|
|
32130
|
-
|
|
32131
|
-
|
|
32132
|
-
|
|
32133
|
-
|
|
32134
|
-
|
|
32135
|
-
|
|
32136
|
-
|
|
32137
|
-
|
|
32138
|
-
|
|
32139
|
-
|
|
32140
|
-
|
|
32141
|
-
textAnchor = _ref5$textAnchor === void 0 ? 'start' : _ref5$textAnchor,
|
|
32142
|
-
_ref5$verticalAnchor = _ref5.verticalAnchor,
|
|
32143
|
-
verticalAnchor = _ref5$verticalAnchor === void 0 ? 'end' : _ref5$verticalAnchor,
|
|
32144
|
-
_ref5$fill = _ref5.fill,
|
|
32145
|
-
fill = _ref5$fill === void 0 ? DEFAULT_FILL : _ref5$fill,
|
|
32146
|
-
props = _objectWithoutProperties$9(_ref5, _excluded$9);
|
|
32137
|
+
var textDefaultProps = {
|
|
32138
|
+
x: 0,
|
|
32139
|
+
y: 0,
|
|
32140
|
+
lineHeight: '1em',
|
|
32141
|
+
capHeight: '0.71em',
|
|
32142
|
+
// Magic number from d3
|
|
32143
|
+
scaleToFit: false,
|
|
32144
|
+
textAnchor: 'start',
|
|
32145
|
+
verticalAnchor: 'end',
|
|
32146
|
+
// Maintain compat with existing charts / default SVG behavior
|
|
32147
|
+
fill: '#808080'
|
|
32148
|
+
};
|
|
32149
|
+
var Text = function Text(props) {
|
|
32147
32150
|
var wordsByLines = useMemo(function () {
|
|
32148
32151
|
return getWordsByLines({
|
|
32149
32152
|
breakAll: props.breakAll,
|
|
32150
32153
|
children: props.children,
|
|
32151
32154
|
maxLines: props.maxLines,
|
|
32152
|
-
scaleToFit: scaleToFit,
|
|
32155
|
+
scaleToFit: props.scaleToFit,
|
|
32153
32156
|
style: props.style,
|
|
32154
32157
|
width: props.width
|
|
32155
32158
|
});
|
|
32156
|
-
}, [props.breakAll, props.children, props.maxLines, scaleToFit, props.style, props.width]);
|
|
32159
|
+
}, [props.breakAll, props.children, props.maxLines, props.scaleToFit, props.style, props.width]);
|
|
32157
32160
|
var dx = props.dx,
|
|
32158
32161
|
dy = props.dy,
|
|
32162
|
+
textAnchor = props.textAnchor,
|
|
32163
|
+
verticalAnchor = props.verticalAnchor,
|
|
32164
|
+
scaleToFit = props.scaleToFit,
|
|
32159
32165
|
angle = props.angle,
|
|
32166
|
+
lineHeight = props.lineHeight,
|
|
32167
|
+
capHeight = props.capHeight,
|
|
32160
32168
|
className = props.className,
|
|
32161
32169
|
breakAll = props.breakAll,
|
|
32162
|
-
textProps = _objectWithoutProperties$
|
|
32163
|
-
if (!isNumOrStr(
|
|
32170
|
+
textProps = _objectWithoutProperties$7(props, _excluded$7);
|
|
32171
|
+
if (!isNumOrStr(textProps.x) || !isNumOrStr(textProps.y)) {
|
|
32164
32172
|
return null;
|
|
32165
32173
|
}
|
|
32166
|
-
var x =
|
|
32167
|
-
var y =
|
|
32174
|
+
var x = textProps.x + (isNumber(dx) ? dx : 0);
|
|
32175
|
+
var y = textProps.y + (isNumber(dy) ? dy : 0);
|
|
32168
32176
|
var startDy;
|
|
32169
32177
|
switch (verticalAnchor) {
|
|
32170
32178
|
case 'start':
|
|
@@ -32194,7 +32202,7 @@ var Text = function Text(_ref5) {
|
|
|
32194
32202
|
y: y,
|
|
32195
32203
|
className: classNames('recharts-text', className),
|
|
32196
32204
|
textAnchor: textAnchor,
|
|
32197
|
-
fill: fill.includes('url') ?
|
|
32205
|
+
fill: textProps.fill.includes('url') ? textDefaultProps.fill : textProps.fill
|
|
32198
32206
|
}), wordsByLines.map(function (line, index) {
|
|
32199
32207
|
return (
|
|
32200
32208
|
/*#__PURE__*/
|
|
@@ -32207,6 +32215,7 @@ var Text = function Text(_ref5) {
|
|
|
32207
32215
|
);
|
|
32208
32216
|
}));
|
|
32209
32217
|
};
|
|
32218
|
+
Text.defaultProps = textDefaultProps;
|
|
32210
32219
|
|
|
32211
32220
|
var baseIsEqual = _baseIsEqual;
|
|
32212
32221
|
|
|
@@ -38474,7 +38483,7 @@ function getTickValuesFixedDomainFn(_ref7, tickCount) {
|
|
|
38474
38483
|
var getNiceTickValues = memoize(getNiceTickValuesFn);
|
|
38475
38484
|
var getTickValuesFixedDomain = memoize(getTickValuesFixedDomainFn);
|
|
38476
38485
|
|
|
38477
|
-
var _excluded$
|
|
38486
|
+
var _excluded$6 = ["offset", "layout", "width", "dataKey", "data", "dataPointFormatter", "xAxis", "yAxis"];
|
|
38478
38487
|
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); }
|
|
38479
38488
|
function _slicedToArray$3(arr, i) { return _arrayWithHoles$3(arr) || _iterableToArrayLimit$3(arr, i) || _unsupportedIterableToArray$7(arr, i) || _nonIterableRest$3(); }
|
|
38480
38489
|
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."); }
|
|
@@ -38482,8 +38491,8 @@ function _unsupportedIterableToArray$7(o, minLen) { if (!o) return; if (typeof o
|
|
|
38482
38491
|
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; }
|
|
38483
38492
|
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; } }
|
|
38484
38493
|
function _arrayWithHoles$3(arr) { if (Array.isArray(arr)) return arr; }
|
|
38485
|
-
function _objectWithoutProperties$
|
|
38486
|
-
function _objectWithoutPropertiesLoose$
|
|
38494
|
+
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; }
|
|
38495
|
+
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; }
|
|
38487
38496
|
function ErrorBar(props) {
|
|
38488
38497
|
var offset = props.offset,
|
|
38489
38498
|
layout = props.layout,
|
|
@@ -38493,7 +38502,7 @@ function ErrorBar(props) {
|
|
|
38493
38502
|
dataPointFormatter = props.dataPointFormatter,
|
|
38494
38503
|
xAxis = props.xAxis,
|
|
38495
38504
|
yAxis = props.yAxis,
|
|
38496
|
-
others = _objectWithoutProperties$
|
|
38505
|
+
others = _objectWithoutProperties$6(props, _excluded$6);
|
|
38497
38506
|
var svgProps = filterProps(others);
|
|
38498
38507
|
var errorBars = data.map(function (entry, i) {
|
|
38499
38508
|
var _dataPointFormatter = dataPointFormatter(entry, dataKey),
|
|
@@ -38604,18 +38613,18 @@ ErrorBar.defaultProps = {
|
|
|
38604
38613
|
};
|
|
38605
38614
|
ErrorBar.displayName = 'ErrorBar';
|
|
38606
38615
|
|
|
38607
|
-
function _typeof$
|
|
38616
|
+
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); }
|
|
38608
38617
|
function _toConsumableArray$4(arr) { return _arrayWithoutHoles$4(arr) || _iterableToArray$4(arr) || _unsupportedIterableToArray$6(arr) || _nonIterableSpread$4(); }
|
|
38609
38618
|
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."); }
|
|
38610
38619
|
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); }
|
|
38611
38620
|
function _iterableToArray$4(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
38612
38621
|
function _arrayWithoutHoles$4(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$6(arr); }
|
|
38613
38622
|
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; }
|
|
38614
|
-
function ownKeys$
|
|
38615
|
-
function _objectSpread$
|
|
38616
|
-
function _defineProperty$
|
|
38617
|
-
function _toPropertyKey$
|
|
38618
|
-
function _toPrimitive$
|
|
38623
|
+
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; }
|
|
38624
|
+
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; }
|
|
38625
|
+
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; }
|
|
38626
|
+
function _toPropertyKey$h(arg) { var key = _toPrimitive$h(arg, "string"); return _typeof$h(key) === "symbol" ? key : String(key); }
|
|
38627
|
+
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); }
|
|
38619
38628
|
// TODO: Cause of circular dependency. Needs refactor.
|
|
38620
38629
|
// import { RadiusAxisProps, AngleAxisProps } from '../polar/types';
|
|
38621
38630
|
function getValueByDataKey(obj, dataKey, defaultValue) {
|
|
@@ -38786,7 +38795,7 @@ var getLegendProps = function getLegendProps(_ref2) {
|
|
|
38786
38795
|
};
|
|
38787
38796
|
});
|
|
38788
38797
|
}
|
|
38789
|
-
return _objectSpread$
|
|
38798
|
+
return _objectSpread$g(_objectSpread$g(_objectSpread$g({}, legendItem.props), Legend.getWithHeight(legendItem, legendWidth)), {}, {
|
|
38790
38799
|
payload: legendData,
|
|
38791
38800
|
item: legendItem
|
|
38792
38801
|
});
|
|
@@ -38940,10 +38949,10 @@ var appendOffsetOfLegend = function appendOffsetOfLegend(offset, items, props, l
|
|
|
38940
38949
|
verticalAlign = legendProps.verticalAlign,
|
|
38941
38950
|
layout = legendProps.layout;
|
|
38942
38951
|
if ((layout === 'vertical' || layout === 'horizontal' && verticalAlign === 'middle') && isNumber(offset[align])) {
|
|
38943
|
-
newOffset = _objectSpread$
|
|
38952
|
+
newOffset = _objectSpread$g(_objectSpread$g({}, offset), {}, _defineProperty$h({}, align, newOffset[align] + (box.width || 0)));
|
|
38944
38953
|
}
|
|
38945
38954
|
if ((layout === 'horizontal' || layout === 'vertical' && align === 'center') && isNumber(offset[verticalAlign])) {
|
|
38946
|
-
newOffset = _objectSpread$
|
|
38955
|
+
newOffset = _objectSpread$g(_objectSpread$g({}, offset), {}, _defineProperty$h({}, verticalAlign, newOffset[verticalAlign] + (box.height || 0)));
|
|
38947
38956
|
}
|
|
38948
38957
|
}
|
|
38949
38958
|
return newOffset;
|
|
@@ -39369,14 +39378,14 @@ var getStackGroupsByAxisId = function getStackGroupsByAxisId(data, _items, numer
|
|
|
39369
39378
|
items: [item]
|
|
39370
39379
|
};
|
|
39371
39380
|
}
|
|
39372
|
-
return _objectSpread$
|
|
39381
|
+
return _objectSpread$g(_objectSpread$g({}, result), {}, _defineProperty$h({}, axisId, parentGroup));
|
|
39373
39382
|
}, {});
|
|
39374
39383
|
return Object.keys(stackGroups).reduce(function (result, axisId) {
|
|
39375
39384
|
var group = stackGroups[axisId];
|
|
39376
39385
|
if (group.hasStack) {
|
|
39377
39386
|
group.stackGroups = Object.keys(group.stackGroups).reduce(function (res, stackId) {
|
|
39378
39387
|
var g = group.stackGroups[stackId];
|
|
39379
|
-
return _objectSpread$
|
|
39388
|
+
return _objectSpread$g(_objectSpread$g({}, res), {}, _defineProperty$h({}, stackId, {
|
|
39380
39389
|
numericAxisId: numericAxisId,
|
|
39381
39390
|
cateAxisId: cateAxisId,
|
|
39382
39391
|
items: g.items,
|
|
@@ -39384,7 +39393,7 @@ var getStackGroupsByAxisId = function getStackGroupsByAxisId(data, _items, numer
|
|
|
39384
39393
|
}));
|
|
39385
39394
|
}, {});
|
|
39386
39395
|
}
|
|
39387
|
-
return _objectSpread$
|
|
39396
|
+
return _objectSpread$g(_objectSpread$g({}, result), {}, _defineProperty$h({}, axisId, group));
|
|
39388
39397
|
}, {});
|
|
39389
39398
|
};
|
|
39390
39399
|
|
|
@@ -39598,7 +39607,7 @@ var getTooltipItem = function getTooltipItem(graphicalItem, payload) {
|
|
|
39598
39607
|
formatter = _graphicalItem$props.formatter,
|
|
39599
39608
|
tooltipType = _graphicalItem$props.tooltipType,
|
|
39600
39609
|
chartType = _graphicalItem$props.chartType;
|
|
39601
|
-
return _objectSpread$
|
|
39610
|
+
return _objectSpread$g(_objectSpread$g({}, filterProps(graphicalItem)), {}, {
|
|
39602
39611
|
dataKey: dataKey,
|
|
39603
39612
|
unit: unit,
|
|
39604
39613
|
formatter: formatter,
|
|
@@ -39611,12 +39620,12 @@ var getTooltipItem = function getTooltipItem(graphicalItem, payload) {
|
|
|
39611
39620
|
});
|
|
39612
39621
|
};
|
|
39613
39622
|
|
|
39614
|
-
function _typeof$
|
|
39615
|
-
function ownKeys$
|
|
39616
|
-
function _objectSpread$
|
|
39617
|
-
function _defineProperty$
|
|
39618
|
-
function _toPropertyKey$
|
|
39619
|
-
function _toPrimitive$
|
|
39623
|
+
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); }
|
|
39624
|
+
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; }
|
|
39625
|
+
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; }
|
|
39626
|
+
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; }
|
|
39627
|
+
function _toPropertyKey$g(arg) { var key = _toPrimitive$g(arg, "string"); return _typeof$g(key) === "symbol" ? key : String(key); }
|
|
39628
|
+
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); }
|
|
39620
39629
|
var RADIAN = Math.PI / 180;
|
|
39621
39630
|
var radianToDegree = function radianToDegree(angleInRadian) {
|
|
39622
39631
|
return angleInRadian * 180 / Math.PI;
|
|
@@ -39721,7 +39730,7 @@ var inRangeOfSector = function inRangeOfSector(_ref5, sector) {
|
|
|
39721
39730
|
inRange = formatAngle >= endAngle && formatAngle <= startAngle;
|
|
39722
39731
|
}
|
|
39723
39732
|
if (inRange) {
|
|
39724
|
-
return _objectSpread$
|
|
39733
|
+
return _objectSpread$f(_objectSpread$f({}, sector), {}, {
|
|
39725
39734
|
radius: radius,
|
|
39726
39735
|
angle: reverseFormatAngleOfSetor(formatAngle, sector)
|
|
39727
39736
|
});
|
|
@@ -39729,21 +39738,18 @@ var inRangeOfSector = function inRangeOfSector(_ref5, sector) {
|
|
|
39729
39738
|
return null;
|
|
39730
39739
|
};
|
|
39731
39740
|
|
|
39732
|
-
function _typeof$
|
|
39733
|
-
var _excluded$7 = ["offset"];
|
|
39741
|
+
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); }
|
|
39734
39742
|
function _toConsumableArray$3(arr) { return _arrayWithoutHoles$3(arr) || _iterableToArray$3(arr) || _unsupportedIterableToArray$5(arr) || _nonIterableSpread$3(); }
|
|
39735
39743
|
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."); }
|
|
39736
39744
|
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); }
|
|
39737
39745
|
function _iterableToArray$3(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
39738
39746
|
function _arrayWithoutHoles$3(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$5(arr); }
|
|
39739
39747
|
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; }
|
|
39740
|
-
function
|
|
39741
|
-
function
|
|
39742
|
-
function
|
|
39743
|
-
function
|
|
39744
|
-
function
|
|
39745
|
-
function _toPropertyKey$i(arg) { var key = _toPrimitive$i(arg, "string"); return _typeof$i(key) === "symbol" ? key : String(key); }
|
|
39746
|
-
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); }
|
|
39748
|
+
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; }
|
|
39749
|
+
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; }
|
|
39750
|
+
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; }
|
|
39751
|
+
function _toPropertyKey$f(arg) { var key = _toPrimitive$f(arg, "string"); return _typeof$f(key) === "symbol" ? key : String(key); }
|
|
39752
|
+
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); }
|
|
39747
39753
|
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); }
|
|
39748
39754
|
var getLabel = function getLabel(props) {
|
|
39749
39755
|
var value = props.value,
|
|
@@ -39888,7 +39894,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39888
39894
|
textAnchor: 'middle',
|
|
39889
39895
|
verticalAnchor: verticalEnd
|
|
39890
39896
|
};
|
|
39891
|
-
return _objectSpread$
|
|
39897
|
+
return _objectSpread$e(_objectSpread$e({}, attrs), parentViewBox ? {
|
|
39892
39898
|
height: Math.max(y - parentViewBox.y, 0),
|
|
39893
39899
|
width: width
|
|
39894
39900
|
} : {});
|
|
@@ -39900,7 +39906,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39900
39906
|
textAnchor: 'middle',
|
|
39901
39907
|
verticalAnchor: verticalStart
|
|
39902
39908
|
};
|
|
39903
|
-
return _objectSpread$
|
|
39909
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs), parentViewBox ? {
|
|
39904
39910
|
height: Math.max(parentViewBox.y + parentViewBox.height - (y + height), 0),
|
|
39905
39911
|
width: width
|
|
39906
39912
|
} : {});
|
|
@@ -39912,7 +39918,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39912
39918
|
textAnchor: horizontalEnd,
|
|
39913
39919
|
verticalAnchor: 'middle'
|
|
39914
39920
|
};
|
|
39915
|
-
return _objectSpread$
|
|
39921
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs2), parentViewBox ? {
|
|
39916
39922
|
width: Math.max(_attrs2.x - parentViewBox.x, 0),
|
|
39917
39923
|
height: height
|
|
39918
39924
|
} : {});
|
|
@@ -39924,7 +39930,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39924
39930
|
textAnchor: horizontalStart,
|
|
39925
39931
|
verticalAnchor: 'middle'
|
|
39926
39932
|
};
|
|
39927
|
-
return _objectSpread$
|
|
39933
|
+
return _objectSpread$e(_objectSpread$e({}, _attrs3), parentViewBox ? {
|
|
39928
39934
|
width: Math.max(parentViewBox.x + parentViewBox.width - _attrs3.x, 0),
|
|
39929
39935
|
height: height
|
|
39930
39936
|
} : {});
|
|
@@ -39934,7 +39940,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39934
39940
|
height: height
|
|
39935
39941
|
} : {};
|
|
39936
39942
|
if (position === 'insideLeft') {
|
|
39937
|
-
return _objectSpread$
|
|
39943
|
+
return _objectSpread$e({
|
|
39938
39944
|
x: x + horizontalOffset,
|
|
39939
39945
|
y: y + height / 2,
|
|
39940
39946
|
textAnchor: horizontalStart,
|
|
@@ -39942,7 +39948,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39942
39948
|
}, sizeAttrs);
|
|
39943
39949
|
}
|
|
39944
39950
|
if (position === 'insideRight') {
|
|
39945
|
-
return _objectSpread$
|
|
39951
|
+
return _objectSpread$e({
|
|
39946
39952
|
x: x + width - horizontalOffset,
|
|
39947
39953
|
y: y + height / 2,
|
|
39948
39954
|
textAnchor: horizontalEnd,
|
|
@@ -39950,7 +39956,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39950
39956
|
}, sizeAttrs);
|
|
39951
39957
|
}
|
|
39952
39958
|
if (position === 'insideTop') {
|
|
39953
|
-
return _objectSpread$
|
|
39959
|
+
return _objectSpread$e({
|
|
39954
39960
|
x: x + width / 2,
|
|
39955
39961
|
y: y + verticalOffset,
|
|
39956
39962
|
textAnchor: 'middle',
|
|
@@ -39958,7 +39964,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39958
39964
|
}, sizeAttrs);
|
|
39959
39965
|
}
|
|
39960
39966
|
if (position === 'insideBottom') {
|
|
39961
|
-
return _objectSpread$
|
|
39967
|
+
return _objectSpread$e({
|
|
39962
39968
|
x: x + width / 2,
|
|
39963
39969
|
y: y + height - verticalOffset,
|
|
39964
39970
|
textAnchor: 'middle',
|
|
@@ -39966,7 +39972,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39966
39972
|
}, sizeAttrs);
|
|
39967
39973
|
}
|
|
39968
39974
|
if (position === 'insideTopLeft') {
|
|
39969
|
-
return _objectSpread$
|
|
39975
|
+
return _objectSpread$e({
|
|
39970
39976
|
x: x + horizontalOffset,
|
|
39971
39977
|
y: y + verticalOffset,
|
|
39972
39978
|
textAnchor: horizontalStart,
|
|
@@ -39974,7 +39980,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39974
39980
|
}, sizeAttrs);
|
|
39975
39981
|
}
|
|
39976
39982
|
if (position === 'insideTopRight') {
|
|
39977
|
-
return _objectSpread$
|
|
39983
|
+
return _objectSpread$e({
|
|
39978
39984
|
x: x + width - horizontalOffset,
|
|
39979
39985
|
y: y + verticalOffset,
|
|
39980
39986
|
textAnchor: horizontalEnd,
|
|
@@ -39982,7 +39988,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39982
39988
|
}, sizeAttrs);
|
|
39983
39989
|
}
|
|
39984
39990
|
if (position === 'insideBottomLeft') {
|
|
39985
|
-
return _objectSpread$
|
|
39991
|
+
return _objectSpread$e({
|
|
39986
39992
|
x: x + horizontalOffset,
|
|
39987
39993
|
y: y + height - verticalOffset,
|
|
39988
39994
|
textAnchor: horizontalStart,
|
|
@@ -39990,7 +39996,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39990
39996
|
}, sizeAttrs);
|
|
39991
39997
|
}
|
|
39992
39998
|
if (position === 'insideBottomRight') {
|
|
39993
|
-
return _objectSpread$
|
|
39999
|
+
return _objectSpread$e({
|
|
39994
40000
|
x: x + width - horizontalOffset,
|
|
39995
40001
|
y: y + height - verticalOffset,
|
|
39996
40002
|
textAnchor: horizontalEnd,
|
|
@@ -39998,14 +40004,14 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
39998
40004
|
}, sizeAttrs);
|
|
39999
40005
|
}
|
|
40000
40006
|
if (isObject_1(position) && (isNumber(position.x) || isPercent(position.x)) && (isNumber(position.y) || isPercent(position.y))) {
|
|
40001
|
-
return _objectSpread$
|
|
40007
|
+
return _objectSpread$e({
|
|
40002
40008
|
x: x + getPercentValue(position.x, width),
|
|
40003
40009
|
y: y + getPercentValue(position.y, height),
|
|
40004
40010
|
textAnchor: 'end',
|
|
40005
40011
|
verticalAnchor: 'end'
|
|
40006
40012
|
}, sizeAttrs);
|
|
40007
40013
|
}
|
|
40008
|
-
return _objectSpread$
|
|
40014
|
+
return _objectSpread$e({
|
|
40009
40015
|
x: x + width / 2,
|
|
40010
40016
|
y: y + height / 2,
|
|
40011
40017
|
textAnchor: 'middle',
|
|
@@ -40015,13 +40021,7 @@ var getAttrsOfCartesianLabel = function getAttrsOfCartesianLabel(props) {
|
|
|
40015
40021
|
var isPolar = function isPolar(viewBox) {
|
|
40016
40022
|
return 'cx' in viewBox && isNumber(viewBox.cx);
|
|
40017
40023
|
};
|
|
40018
|
-
function Label$3(
|
|
40019
|
-
var _ref4$offset = _ref4.offset,
|
|
40020
|
-
offset = _ref4$offset === void 0 ? 5 : _ref4$offset,
|
|
40021
|
-
restProps = _objectWithoutProperties$7(_ref4, _excluded$7);
|
|
40022
|
-
var props = _objectSpread$h({
|
|
40023
|
-
offset: offset
|
|
40024
|
-
}, restProps);
|
|
40024
|
+
function Label$3(props) {
|
|
40025
40025
|
var viewBox = props.viewBox,
|
|
40026
40026
|
position = props.position,
|
|
40027
40027
|
value = props.value,
|
|
@@ -40058,6 +40058,9 @@ function Label$3(_ref4) {
|
|
|
40058
40058
|
}), label);
|
|
40059
40059
|
}
|
|
40060
40060
|
Label$3.displayName = 'Label';
|
|
40061
|
+
Label$3.defaultProps = {
|
|
40062
|
+
offset: 5
|
|
40063
|
+
};
|
|
40061
40064
|
var parseViewBox = function parseViewBox(props) {
|
|
40062
40065
|
var cx = props.cx,
|
|
40063
40066
|
cy = props.cy,
|
|
@@ -40212,9 +40215,8 @@ function last(array) {
|
|
|
40212
40215
|
|
|
40213
40216
|
var last_1 = last;
|
|
40214
40217
|
|
|
40215
|
-
function _typeof$
|
|
40216
|
-
var _excluded$
|
|
40217
|
-
_excluded2$2 = ["data", "dataKey", "clockWise", "id", "textBreakAll"];
|
|
40218
|
+
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); }
|
|
40219
|
+
var _excluded$5 = ["data", "valueAccessor", "dataKey", "clockWise", "id", "textBreakAll"];
|
|
40218
40220
|
function _toConsumableArray$2(arr) { return _arrayWithoutHoles$2(arr) || _iterableToArray$2(arr) || _unsupportedIterableToArray$4(arr) || _nonIterableSpread$2(); }
|
|
40219
40221
|
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."); }
|
|
40220
40222
|
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); }
|
|
@@ -40222,26 +40224,26 @@ function _iterableToArray$2(iter) { if (typeof Symbol !== "undefined" && iter[Sy
|
|
|
40222
40224
|
function _arrayWithoutHoles$2(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$4(arr); }
|
|
40223
40225
|
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; }
|
|
40224
40226
|
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); }
|
|
40225
|
-
function ownKeys$
|
|
40226
|
-
function _objectSpread$
|
|
40227
|
-
function _defineProperty$
|
|
40228
|
-
function _toPropertyKey$
|
|
40229
|
-
function _toPrimitive$
|
|
40230
|
-
function _objectWithoutProperties$
|
|
40231
|
-
function _objectWithoutPropertiesLoose$
|
|
40232
|
-
var
|
|
40233
|
-
|
|
40234
|
-
|
|
40235
|
-
|
|
40236
|
-
|
|
40237
|
-
|
|
40238
|
-
|
|
40239
|
-
|
|
40240
|
-
dataKey =
|
|
40241
|
-
clockWise =
|
|
40242
|
-
id =
|
|
40243
|
-
textBreakAll =
|
|
40244
|
-
others = _objectWithoutProperties$
|
|
40227
|
+
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; }
|
|
40228
|
+
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; }
|
|
40229
|
+
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; }
|
|
40230
|
+
function _toPropertyKey$e(arg) { var key = _toPrimitive$e(arg, "string"); return _typeof$e(key) === "symbol" ? key : String(key); }
|
|
40231
|
+
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); }
|
|
40232
|
+
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; }
|
|
40233
|
+
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; }
|
|
40234
|
+
var defaultProps = {
|
|
40235
|
+
valueAccessor: function valueAccessor(entry) {
|
|
40236
|
+
return isArray_1(entry.value) ? last_1(entry.value) : entry.value;
|
|
40237
|
+
}
|
|
40238
|
+
};
|
|
40239
|
+
function LabelList(props) {
|
|
40240
|
+
var data = props.data,
|
|
40241
|
+
valueAccessor = props.valueAccessor,
|
|
40242
|
+
dataKey = props.dataKey,
|
|
40243
|
+
clockWise = props.clockWise,
|
|
40244
|
+
id = props.id,
|
|
40245
|
+
textBreakAll = props.textBreakAll,
|
|
40246
|
+
others = _objectWithoutProperties$5(props, _excluded$5);
|
|
40245
40247
|
if (!data || !data.length) {
|
|
40246
40248
|
return null;
|
|
40247
40249
|
}
|
|
@@ -40257,7 +40259,7 @@ function LabelList(_ref) {
|
|
|
40257
40259
|
index: index,
|
|
40258
40260
|
value: value,
|
|
40259
40261
|
textBreakAll: textBreakAll,
|
|
40260
|
-
viewBox: Label$3.parseViewBox(isNil_1(clockWise) ? entry : _objectSpread$
|
|
40262
|
+
viewBox: Label$3.parseViewBox(isNil_1(clockWise) ? entry : _objectSpread$d(_objectSpread$d({}, entry), {}, {
|
|
40261
40263
|
clockWise: clockWise
|
|
40262
40264
|
})),
|
|
40263
40265
|
key: "label-".concat(index) // eslint-disable-line react/no-array-index-key
|
|
@@ -40312,14 +40314,9 @@ function renderCallByParent(parentProps, data) {
|
|
|
40312
40314
|
return [implicitLabelList].concat(_toConsumableArray$2(explicitChildren));
|
|
40313
40315
|
}
|
|
40314
40316
|
LabelList.renderCallByParent = renderCallByParent;
|
|
40317
|
+
LabelList.defaultProps = defaultProps;
|
|
40315
40318
|
|
|
40316
|
-
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); }
|
|
40317
40319
|
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); }
|
|
40318
|
-
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; }
|
|
40319
|
-
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; }
|
|
40320
|
-
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; }
|
|
40321
|
-
function _toPropertyKey$g(arg) { var key = _toPrimitive$g(arg, "string"); return _typeof$g(key) === "symbol" ? key : String(key); }
|
|
40322
|
-
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); }
|
|
40323
40320
|
var getDeltaAngle = function getDeltaAngle(startAngle, endAngle) {
|
|
40324
40321
|
var sign = mathSign(endAngle - startAngle);
|
|
40325
40322
|
var deltaAngle = Math.min(Math.abs(endAngle - startAngle), 359.999);
|
|
@@ -40460,19 +40457,7 @@ var getSectorWithCorner = function getSectorWithCorner(_ref3) {
|
|
|
40460
40457
|
}
|
|
40461
40458
|
return path;
|
|
40462
40459
|
};
|
|
40463
|
-
var
|
|
40464
|
-
cx: 0,
|
|
40465
|
-
cy: 0,
|
|
40466
|
-
innerRadius: 0,
|
|
40467
|
-
outerRadius: 0,
|
|
40468
|
-
startAngle: 0,
|
|
40469
|
-
endAngle: 0,
|
|
40470
|
-
cornerRadius: 0,
|
|
40471
|
-
forceCornerRadius: false,
|
|
40472
|
-
cornerIsExternal: false
|
|
40473
|
-
};
|
|
40474
|
-
var Sector = function Sector(sectorProps) {
|
|
40475
|
-
var props = _objectSpread$f(_objectSpread$f({}, defaultProps$1), sectorProps);
|
|
40460
|
+
var Sector = function Sector(props) {
|
|
40476
40461
|
var cx = props.cx,
|
|
40477
40462
|
cy = props.cy,
|
|
40478
40463
|
innerRadius = props.innerRadius,
|
|
@@ -40518,14 +40503,25 @@ var Sector = function Sector(sectorProps) {
|
|
|
40518
40503
|
role: "img"
|
|
40519
40504
|
}));
|
|
40520
40505
|
};
|
|
40506
|
+
Sector.defaultProps = {
|
|
40507
|
+
cx: 0,
|
|
40508
|
+
cy: 0,
|
|
40509
|
+
innerRadius: 0,
|
|
40510
|
+
outerRadius: 0,
|
|
40511
|
+
startAngle: 0,
|
|
40512
|
+
endAngle: 0,
|
|
40513
|
+
cornerRadius: 0,
|
|
40514
|
+
forceCornerRadius: false,
|
|
40515
|
+
cornerIsExternal: false
|
|
40516
|
+
};
|
|
40521
40517
|
|
|
40522
|
-
function _typeof$
|
|
40518
|
+
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); }
|
|
40523
40519
|
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); }
|
|
40524
|
-
function ownKeys$
|
|
40525
|
-
function _objectSpread$
|
|
40526
|
-
function _defineProperty$
|
|
40527
|
-
function _toPropertyKey$
|
|
40528
|
-
function _toPrimitive$
|
|
40520
|
+
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; }
|
|
40521
|
+
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; }
|
|
40522
|
+
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; }
|
|
40523
|
+
function _toPropertyKey$d(arg) { var key = _toPrimitive$d(arg, "string"); return _typeof$d(key) === "symbol" ? key : String(key); }
|
|
40524
|
+
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); }
|
|
40529
40525
|
var CURVE_FACTORIES = {
|
|
40530
40526
|
curveBasisClosed: curveBasisClosed,
|
|
40531
40527
|
curveBasisOpen: curveBasisOpen,
|
|
@@ -40565,14 +40561,11 @@ var getCurveFactory = function getCurveFactory(type, layout) {
|
|
|
40565
40561
|
* @return {String} path
|
|
40566
40562
|
*/
|
|
40567
40563
|
var getPath$1 = function getPath(_ref) {
|
|
40568
|
-
var
|
|
40569
|
-
|
|
40570
|
-
_ref$points = _ref.points,
|
|
40571
|
-
points = _ref$points === void 0 ? [] : _ref$points,
|
|
40564
|
+
var type = _ref.type,
|
|
40565
|
+
points = _ref.points,
|
|
40572
40566
|
baseLine = _ref.baseLine,
|
|
40573
40567
|
layout = _ref.layout,
|
|
40574
|
-
|
|
40575
|
-
connectNulls = _ref$connectNulls === void 0 ? false : _ref$connectNulls;
|
|
40568
|
+
connectNulls = _ref.connectNulls;
|
|
40576
40569
|
var curveFactory = getCurveFactory(type, layout);
|
|
40577
40570
|
var formatPoints = connectNulls ? points.filter(function (entry) {
|
|
40578
40571
|
return defined(entry);
|
|
@@ -40583,7 +40576,7 @@ var getPath$1 = function getPath(_ref) {
|
|
|
40583
40576
|
return defined(base);
|
|
40584
40577
|
}) : baseLine;
|
|
40585
40578
|
var areaPoints = formatPoints.map(function (entry, index) {
|
|
40586
|
-
return _objectSpread$
|
|
40579
|
+
return _objectSpread$c(_objectSpread$c({}, entry), {}, {
|
|
40587
40580
|
base: formatBaseLine[index]
|
|
40588
40581
|
});
|
|
40589
40582
|
});
|
|
@@ -40624,8 +40617,12 @@ var Curve = function Curve(props) {
|
|
|
40624
40617
|
ref: pathRef
|
|
40625
40618
|
}));
|
|
40626
40619
|
};
|
|
40620
|
+
Curve.defaultProps = {
|
|
40621
|
+
type: 'linear',
|
|
40622
|
+
points: [],
|
|
40623
|
+
connectNulls: false
|
|
40624
|
+
};
|
|
40627
40625
|
|
|
40628
|
-
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); }
|
|
40629
40626
|
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); }
|
|
40630
40627
|
function _slicedToArray$2(arr, i) { return _arrayWithHoles$2(arr) || _iterableToArrayLimit$2(arr, i) || _unsupportedIterableToArray$3(arr, i) || _nonIterableRest$2(); }
|
|
40631
40628
|
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."); }
|
|
@@ -40633,11 +40630,6 @@ function _unsupportedIterableToArray$3(o, minLen) { if (!o) return; if (typeof o
|
|
|
40633
40630
|
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; }
|
|
40634
40631
|
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; } }
|
|
40635
40632
|
function _arrayWithHoles$2(arr) { if (Array.isArray(arr)) return arr; }
|
|
40636
|
-
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; }
|
|
40637
|
-
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; }
|
|
40638
|
-
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; }
|
|
40639
|
-
function _toPropertyKey$e(arg) { var key = _toPrimitive$e(arg, "string"); return _typeof$e(key) === "symbol" ? key : String(key); }
|
|
40640
|
-
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); }
|
|
40641
40633
|
var getRectanglePath = function getRectanglePath(x, y, width, height, radius) {
|
|
40642
40634
|
var maxRadius = Math.min(Math.abs(width) / 2, Math.abs(height) / 2);
|
|
40643
40635
|
var ySign = height >= 0 ? 1 : -1;
|
|
@@ -40693,29 +40685,13 @@ var isInRectangle = function isInRectangle(point, rect) {
|
|
|
40693
40685
|
}
|
|
40694
40686
|
return false;
|
|
40695
40687
|
};
|
|
40696
|
-
var
|
|
40697
|
-
x: 0,
|
|
40698
|
-
y: 0,
|
|
40699
|
-
width: 0,
|
|
40700
|
-
height: 0,
|
|
40701
|
-
// The radius of border
|
|
40702
|
-
// The radius of four corners when radius is a number
|
|
40703
|
-
// The radius of left-top, right-top, right-bottom, left-bottom when radius is an array
|
|
40704
|
-
radius: 0,
|
|
40705
|
-
isAnimationActive: false,
|
|
40706
|
-
isUpdateAnimationActive: false,
|
|
40707
|
-
animationBegin: 0,
|
|
40708
|
-
animationDuration: 1500,
|
|
40709
|
-
animationEasing: 'ease'
|
|
40710
|
-
};
|
|
40711
|
-
var Rectangle = function Rectangle(rectangleProps) {
|
|
40712
|
-
var props = _objectSpread$d(_objectSpread$d({}, defaultProps), rectangleProps);
|
|
40688
|
+
var Rectangle = function Rectangle(props) {
|
|
40713
40689
|
var pathRef = useRef();
|
|
40714
40690
|
var _useState = useState(-1),
|
|
40715
40691
|
_useState2 = _slicedToArray$2(_useState, 2),
|
|
40716
40692
|
totalLength = _useState2[0],
|
|
40717
40693
|
setTotalLength = _useState2[1];
|
|
40718
|
-
|
|
40694
|
+
useLayoutEffect(function () {
|
|
40719
40695
|
if (pathRef.current && pathRef.current.getTotalLength) {
|
|
40720
40696
|
try {
|
|
40721
40697
|
var pathTotalLength = pathRef.current.getTotalLength();
|
|
@@ -40786,6 +40762,21 @@ var Rectangle = function Rectangle(rectangleProps) {
|
|
|
40786
40762
|
})));
|
|
40787
40763
|
});
|
|
40788
40764
|
};
|
|
40765
|
+
Rectangle.defaultProps = {
|
|
40766
|
+
x: 0,
|
|
40767
|
+
y: 0,
|
|
40768
|
+
width: 0,
|
|
40769
|
+
height: 0,
|
|
40770
|
+
// The radius of border
|
|
40771
|
+
// The radius of four corners when radius is a number
|
|
40772
|
+
// The radius of left-top, right-top, right-bottom, left-bottom when radius is an array
|
|
40773
|
+
radius: 0,
|
|
40774
|
+
isAnimationActive: false,
|
|
40775
|
+
isUpdateAnimationActive: false,
|
|
40776
|
+
animationBegin: 0,
|
|
40777
|
+
animationDuration: 1500,
|
|
40778
|
+
animationEasing: 'ease'
|
|
40779
|
+
};
|
|
40789
40780
|
|
|
40790
40781
|
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); }
|
|
40791
40782
|
var Dot$1 = function Dot(props) {
|
|
@@ -40805,42 +40796,18 @@ var Dot$1 = function Dot(props) {
|
|
|
40805
40796
|
return null;
|
|
40806
40797
|
};
|
|
40807
40798
|
|
|
40808
|
-
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); }
|
|
40809
|
-
var _excluded$5 = ["x", "y", "top", "left", "width", "height", "className"];
|
|
40810
40799
|
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); }
|
|
40811
|
-
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; }
|
|
40812
|
-
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; }
|
|
40813
|
-
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; }
|
|
40814
|
-
function _toPropertyKey$d(arg) { var key = _toPrimitive$d(arg, "string"); return _typeof$d(key) === "symbol" ? key : String(key); }
|
|
40815
|
-
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); }
|
|
40816
|
-
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; }
|
|
40817
|
-
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; }
|
|
40818
40800
|
var getPath = function getPath(x, y, width, height, top, left) {
|
|
40819
40801
|
return "M".concat(x, ",").concat(top, "v").concat(height, "M").concat(left, ",").concat(y, "h").concat(width);
|
|
40820
40802
|
};
|
|
40821
|
-
var Cross = function Cross(
|
|
40822
|
-
var
|
|
40823
|
-
|
|
40824
|
-
|
|
40825
|
-
|
|
40826
|
-
|
|
40827
|
-
|
|
40828
|
-
|
|
40829
|
-
left = _ref$left === void 0 ? 0 : _ref$left,
|
|
40830
|
-
_ref$width = _ref.width,
|
|
40831
|
-
width = _ref$width === void 0 ? 0 : _ref$width,
|
|
40832
|
-
_ref$height = _ref.height,
|
|
40833
|
-
height = _ref$height === void 0 ? 0 : _ref$height,
|
|
40834
|
-
className = _ref.className,
|
|
40835
|
-
rest = _objectWithoutProperties$5(_ref, _excluded$5);
|
|
40836
|
-
var props = _objectSpread$c({
|
|
40837
|
-
x: x,
|
|
40838
|
-
y: y,
|
|
40839
|
-
top: top,
|
|
40840
|
-
left: left,
|
|
40841
|
-
width: width,
|
|
40842
|
-
height: height
|
|
40843
|
-
}, rest);
|
|
40803
|
+
var Cross = function Cross(props) {
|
|
40804
|
+
var x = props.x,
|
|
40805
|
+
y = props.y,
|
|
40806
|
+
width = props.width,
|
|
40807
|
+
height = props.height,
|
|
40808
|
+
top = props.top,
|
|
40809
|
+
left = props.left,
|
|
40810
|
+
className = props.className;
|
|
40844
40811
|
if (!isNumber(x) || !isNumber(y) || !isNumber(width) || !isNumber(height) || !isNumber(top) || !isNumber(left)) {
|
|
40845
40812
|
return null;
|
|
40846
40813
|
}
|
|
@@ -40849,6 +40816,14 @@ var Cross = function Cross(_ref) {
|
|
|
40849
40816
|
d: getPath(x, y, width, height, top, left)
|
|
40850
40817
|
}));
|
|
40851
40818
|
};
|
|
40819
|
+
Cross.defaultProps = {
|
|
40820
|
+
x: 0,
|
|
40821
|
+
y: 0,
|
|
40822
|
+
top: 0,
|
|
40823
|
+
left: 0,
|
|
40824
|
+
width: 0,
|
|
40825
|
+
height: 0
|
|
40826
|
+
};
|
|
40852
40827
|
|
|
40853
40828
|
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
40854
40829
|
|
|
@@ -41058,7 +41033,6 @@ var createScale = function createScale(_ref) {
|
|
|
41058
41033
|
isTextActive: false,
|
|
41059
41034
|
isSlideMoving: false,
|
|
41060
41035
|
isTravellerMoving: false,
|
|
41061
|
-
isTravellerFocused: false,
|
|
41062
41036
|
startX: scale(startIndex),
|
|
41063
41037
|
endX: scale(endIndex),
|
|
41064
41038
|
scale: scale,
|
|
@@ -41272,38 +41246,6 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41272
41246
|
}
|
|
41273
41247
|
});
|
|
41274
41248
|
}
|
|
41275
|
-
}, {
|
|
41276
|
-
key: "handleTravellerMoveKeyboard",
|
|
41277
|
-
value: function handleTravellerMoveKeyboard(direction, id) {
|
|
41278
|
-
var _this2 = this;
|
|
41279
|
-
// scaleValues are a list of coordinates. For example: [65, 250, 435, 620, 805, 990].
|
|
41280
|
-
var _this$state3 = this.state,
|
|
41281
|
-
scaleValues = _this$state3.scaleValues,
|
|
41282
|
-
startX = _this$state3.startX,
|
|
41283
|
-
endX = _this$state3.endX;
|
|
41284
|
-
// currentScaleValue refers to which coordinate the current traveller should be placed at.
|
|
41285
|
-
var currentScaleValue = this.state[id];
|
|
41286
|
-
var currentIndex = scaleValues.indexOf(currentScaleValue);
|
|
41287
|
-
if (currentIndex === -1) {
|
|
41288
|
-
return;
|
|
41289
|
-
}
|
|
41290
|
-
var newIndex = currentIndex + direction;
|
|
41291
|
-
if (newIndex === -1 || newIndex >= scaleValues.length) {
|
|
41292
|
-
return;
|
|
41293
|
-
}
|
|
41294
|
-
var newScaleValue = scaleValues[newIndex];
|
|
41295
|
-
|
|
41296
|
-
// Prevent travellers from being on top of each other or overlapping
|
|
41297
|
-
if (id === 'startX' && newScaleValue >= endX || id === 'endX' && newScaleValue <= startX) {
|
|
41298
|
-
return;
|
|
41299
|
-
}
|
|
41300
|
-
this.setState(_defineProperty$b({}, id, newScaleValue), function () {
|
|
41301
|
-
_this2.props.onChange(_this2.getIndex({
|
|
41302
|
-
startX: _this2.state.startX,
|
|
41303
|
-
endX: _this2.state.endX
|
|
41304
|
-
}));
|
|
41305
|
-
});
|
|
41306
|
-
}
|
|
41307
41249
|
}, {
|
|
41308
41250
|
key: "renderBackground",
|
|
41309
41251
|
value: function renderBackground() {
|
|
@@ -41351,7 +41293,6 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41351
41293
|
}, {
|
|
41352
41294
|
key: "renderTravellerLayer",
|
|
41353
41295
|
value: function renderTravellerLayer(travellerX, id) {
|
|
41354
|
-
var _this3 = this;
|
|
41355
41296
|
var _this$props7 = this.props,
|
|
41356
41297
|
y = _this$props7.y,
|
|
41357
41298
|
travellerWidth = _this$props7.travellerWidth,
|
|
@@ -41365,31 +41306,11 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41365
41306
|
height: height
|
|
41366
41307
|
});
|
|
41367
41308
|
return /*#__PURE__*/React__default.createElement(Layer, {
|
|
41368
|
-
tabIndex: 0,
|
|
41369
|
-
role: "slider",
|
|
41370
41309
|
className: "recharts-brush-traveller",
|
|
41371
41310
|
onMouseEnter: this.handleEnterSlideOrTraveller,
|
|
41372
41311
|
onMouseLeave: this.handleLeaveSlideOrTraveller,
|
|
41373
41312
|
onMouseDown: this.travellerDragStartHandlers[id],
|
|
41374
41313
|
onTouchStart: this.travellerDragStartHandlers[id],
|
|
41375
|
-
onKeyDown: function onKeyDown(e) {
|
|
41376
|
-
if (!['ArrowLeft', 'ArrowRight'].includes(e.key)) {
|
|
41377
|
-
return;
|
|
41378
|
-
}
|
|
41379
|
-
e.preventDefault();
|
|
41380
|
-
e.stopPropagation();
|
|
41381
|
-
_this3.handleTravellerMoveKeyboard(e.key === 'ArrowRight' ? 1 : -1, id);
|
|
41382
|
-
},
|
|
41383
|
-
onFocus: function onFocus() {
|
|
41384
|
-
_this3.setState({
|
|
41385
|
-
isTravellerFocused: true
|
|
41386
|
-
});
|
|
41387
|
-
},
|
|
41388
|
-
onBlur: function onBlur() {
|
|
41389
|
-
_this3.setState({
|
|
41390
|
-
isTravellerFocused: false
|
|
41391
|
-
});
|
|
41392
|
-
},
|
|
41393
41314
|
style: {
|
|
41394
41315
|
cursor: 'col-resize'
|
|
41395
41316
|
}
|
|
@@ -41433,9 +41354,9 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41433
41354
|
height = _this$props9.height,
|
|
41434
41355
|
travellerWidth = _this$props9.travellerWidth,
|
|
41435
41356
|
stroke = _this$props9.stroke;
|
|
41436
|
-
var _this$
|
|
41437
|
-
startX = _this$
|
|
41438
|
-
endX = _this$
|
|
41357
|
+
var _this$state3 = this.state,
|
|
41358
|
+
startX = _this$state3.startX,
|
|
41359
|
+
endX = _this$state3.endX;
|
|
41439
41360
|
var offset = 5;
|
|
41440
41361
|
var attrs = {
|
|
41441
41362
|
pointerEvents: 'none',
|
|
@@ -41467,13 +41388,12 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41467
41388
|
width = _this$props10.width,
|
|
41468
41389
|
height = _this$props10.height,
|
|
41469
41390
|
alwaysShowText = _this$props10.alwaysShowText;
|
|
41470
|
-
var _this$
|
|
41471
|
-
startX = _this$
|
|
41472
|
-
endX = _this$
|
|
41473
|
-
isTextActive = _this$
|
|
41474
|
-
isSlideMoving = _this$
|
|
41475
|
-
isTravellerMoving = _this$
|
|
41476
|
-
isTravellerFocused = _this$state5.isTravellerFocused;
|
|
41391
|
+
var _this$state4 = this.state,
|
|
41392
|
+
startX = _this$state4.startX,
|
|
41393
|
+
endX = _this$state4.endX,
|
|
41394
|
+
isTextActive = _this$state4.isTextActive,
|
|
41395
|
+
isSlideMoving = _this$state4.isSlideMoving,
|
|
41396
|
+
isTravellerMoving = _this$state4.isTravellerMoving;
|
|
41477
41397
|
if (!data || !data.length || !isNumber(x) || !isNumber(y) || !isNumber(width) || !isNumber(height) || width <= 0 || height <= 0) {
|
|
41478
41398
|
return null;
|
|
41479
41399
|
}
|
|
@@ -41485,7 +41405,7 @@ var Brush = /*#__PURE__*/function (_PureComponent) {
|
|
|
41485
41405
|
onMouseLeave: this.handleLeaveWrapper,
|
|
41486
41406
|
onTouchMove: this.handleTouchMove,
|
|
41487
41407
|
style: style
|
|
41488
|
-
}, this.renderBackground(), isPanoramic && this.renderPanorama(), this.renderSlide(startX, endX), this.renderTravellerLayer(startX, 'startX'), this.renderTravellerLayer(endX, 'endX'), (isTextActive || isSlideMoving || isTravellerMoving ||
|
|
41408
|
+
}, this.renderBackground(), isPanoramic && this.renderPanorama(), this.renderSlide(startX, endX), this.renderTravellerLayer(startX, 'startX'), this.renderTravellerLayer(endX, 'endX'), (isTextActive || isSlideMoving || isTravellerMoving || alwaysShowText) && this.renderText());
|
|
41489
41409
|
}
|
|
41490
41410
|
}], [{
|
|
41491
41411
|
key: "renderDefaultTraveller",
|
|
@@ -41803,7 +41723,7 @@ function every(collection, predicate, guard) {
|
|
|
41803
41723
|
|
|
41804
41724
|
var every_1 = every;
|
|
41805
41725
|
|
|
41806
|
-
var defineProperty = _defineProperty$
|
|
41726
|
+
var defineProperty = _defineProperty$l;
|
|
41807
41727
|
|
|
41808
41728
|
/**
|
|
41809
41729
|
* The base implementation of `assignValue` and `assignMergeValue` without
|
|
@@ -42164,6 +42084,7 @@ _defineProperty$a(Bar, "defaultProps", {
|
|
|
42164
42084
|
legendType: 'rect',
|
|
42165
42085
|
minPointSize: 0,
|
|
42166
42086
|
hide: false,
|
|
42087
|
+
// data of bar
|
|
42167
42088
|
data: [],
|
|
42168
42089
|
layout: 'vertical',
|
|
42169
42090
|
isAnimationActive: !Global.isSsr,
|
|
@@ -45076,11 +44997,10 @@ var AccessibilityManager = /*#__PURE__*/function () {
|
|
|
45076
44997
|
}
|
|
45077
44998
|
var _this$container$getBo = this.container.getBoundingClientRect(),
|
|
45078
44999
|
x = _this$container$getBo.x,
|
|
45079
|
-
y = _this$container$getBo.y
|
|
45080
|
-
height = _this$container$getBo.height;
|
|
45000
|
+
y = _this$container$getBo.y;
|
|
45081
45001
|
var coordinate = this.coordinateList[this.activeIndex].coordinate;
|
|
45082
45002
|
var pageX = x + coordinate;
|
|
45083
|
-
var pageY = y + this.offset.top
|
|
45003
|
+
var pageY = y + this.offset.top;
|
|
45084
45004
|
this.mouseHandlerCallback({
|
|
45085
45005
|
pageX: pageX,
|
|
45086
45006
|
pageY: pageY
|