victory-histogram 36.5.0 → 36.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/victory-histogram.js +239 -171
- package/dist/victory-histogram.min.js +1 -1
- package/es/helper-methods.js +2 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +2 -1
- package/es/victory-histogram.js +2 -1
- package/lib/helper-methods.js +2 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +2 -1
- package/lib/victory-histogram.js +2 -1
- package/package.json +5 -5
- package/src/helper-methods.js +10 -10
- package/src/index.d.ts +1 -1
- package/src/victory-histogram.js +15 -15
|
@@ -491,7 +491,7 @@ VictoryHistogram.defaultTransitions = {
|
|
|
491
491
|
}
|
|
492
492
|
};
|
|
493
493
|
VictoryHistogram.getFormattedData = _helper_methods__WEBPACK_IMPORTED_MODULE_3__.getFormattedData;
|
|
494
|
-
VictoryHistogram.propTypes = _objectSpread(_objectSpread(_objectSpread({}, victory_core__WEBPACK_IMPORTED_MODULE_4__.baseProps), victory_core__WEBPACK_IMPORTED_MODULE_4__.dataProps), {}, {
|
|
494
|
+
VictoryHistogram.propTypes = _objectSpread(_objectSpread(_objectSpread({}, victory_core__WEBPACK_IMPORTED_MODULE_4__.CommonProps.baseProps), victory_core__WEBPACK_IMPORTED_MODULE_4__.CommonProps.dataProps), {}, {
|
|
495
495
|
binSpacing: victory_core__WEBPACK_IMPORTED_MODULE_5__.nonNegative,
|
|
496
496
|
bins: prop_types__WEBPACK_IMPORTED_MODULE_6___default().oneOfType([prop_types__WEBPACK_IMPORTED_MODULE_6___default().arrayOf(prop_types__WEBPACK_IMPORTED_MODULE_6___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_6___default().number), prop_types__WEBPACK_IMPORTED_MODULE_6___default().instanceOf(Date)])), victory_core__WEBPACK_IMPORTED_MODULE_5__.nonNegative]),
|
|
497
497
|
cornerRadius: prop_types__WEBPACK_IMPORTED_MODULE_6___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_6___default().number), (prop_types__WEBPACK_IMPORTED_MODULE_6___default().func), prop_types__WEBPACK_IMPORTED_MODULE_6___default().shape({
|
|
@@ -526,7 +526,7 @@ VictoryHistogram.getBaseProps = function (props) {
|
|
|
526
526
|
};
|
|
527
527
|
|
|
528
528
|
VictoryHistogram.expectedComponents = ["dataComponent", "labelComponent", "groupComponent", "containerComponent"];
|
|
529
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ((0,victory_core__WEBPACK_IMPORTED_MODULE_11__
|
|
529
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ((0,victory_core__WEBPACK_IMPORTED_MODULE_11__.addEvents)(VictoryHistogram));
|
|
530
530
|
|
|
531
531
|
/***/ }),
|
|
532
532
|
|
|
@@ -7137,6 +7137,7 @@ var getStyle = function () {
|
|
|
7137
7137
|
};
|
|
7138
7138
|
return victory_core__WEBPACK_IMPORTED_MODULE_3__.evaluateStyle(lodash_assign__WEBPACK_IMPORTED_MODULE_2___default()(baseStyle, style), props);
|
|
7139
7139
|
};
|
|
7140
|
+
//# sourceMappingURL=bar-helper-methods.js.map
|
|
7140
7141
|
|
|
7141
7142
|
/***/ }),
|
|
7142
7143
|
|
|
@@ -7237,7 +7238,7 @@ var Bar = function (props) {
|
|
|
7237
7238
|
}));
|
|
7238
7239
|
};
|
|
7239
7240
|
|
|
7240
|
-
Bar.propTypes = _objectSpread(_objectSpread({}, victory_core__WEBPACK_IMPORTED_MODULE_5__.primitiveProps), {}, {
|
|
7241
|
+
Bar.propTypes = _objectSpread(_objectSpread({}, victory_core__WEBPACK_IMPORTED_MODULE_5__.CommonProps.primitiveProps), {}, {
|
|
7241
7242
|
alignment: prop_types__WEBPACK_IMPORTED_MODULE_6___default().oneOf(["start", "middle", "end"]),
|
|
7242
7243
|
barRatio: (prop_types__WEBPACK_IMPORTED_MODULE_6___default().number),
|
|
7243
7244
|
barWidth: prop_types__WEBPACK_IMPORTED_MODULE_6___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_6___default().number), (prop_types__WEBPACK_IMPORTED_MODULE_6___default().func)]),
|
|
@@ -7265,6 +7266,7 @@ Bar.defaultProps = {
|
|
|
7265
7266
|
shapeRendering: "auto"
|
|
7266
7267
|
};
|
|
7267
7268
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Bar);
|
|
7269
|
+
//# sourceMappingURL=bar.js.map
|
|
7268
7270
|
|
|
7269
7271
|
/***/ }),
|
|
7270
7272
|
|
|
@@ -7397,6 +7399,7 @@ var circle = function (center, radius) {
|
|
|
7397
7399
|
};
|
|
7398
7400
|
|
|
7399
7401
|
|
|
7402
|
+
//# sourceMappingURL=geometry-helper-methods.js.map
|
|
7400
7403
|
|
|
7401
7404
|
/***/ }),
|
|
7402
7405
|
|
|
@@ -7565,6 +7568,7 @@ var getBaseProps = function (props, fallbackProps) {
|
|
|
7565
7568
|
return childProps;
|
|
7566
7569
|
}, initialChildProps);
|
|
7567
7570
|
};
|
|
7571
|
+
//# sourceMappingURL=helper-methods.js.map
|
|
7568
7572
|
|
|
7569
7573
|
/***/ }),
|
|
7570
7574
|
|
|
@@ -8072,6 +8076,7 @@ var getPolarBarPath = function (props, cornerRadius) {
|
|
|
8072
8076
|
// TODO Radial bars
|
|
8073
8077
|
return getVerticalPolarBarPath(props, cornerRadius);
|
|
8074
8078
|
};
|
|
8079
|
+
//# sourceMappingURL=path-helper-methods.js.map
|
|
8075
8080
|
|
|
8076
8081
|
/***/ }),
|
|
8077
8082
|
|
|
@@ -8133,7 +8138,7 @@ var isInterpolatable = function (obj) {
|
|
|
8133
8138
|
// component is only going to call the function (in which case it's
|
|
8134
8139
|
// safely interpolatable) or if it's going to access special properties
|
|
8135
8140
|
// (in which case our function generated from `interpolateFunction` will
|
|
8136
|
-
// most likely cause an error. We could check for enumerable properties
|
|
8141
|
+
// most likely cause an error). We could check for enumerable properties
|
|
8137
8142
|
// on the function object here to see if it's a "plain" function, but
|
|
8138
8143
|
// let's just require that components prevent such function props from
|
|
8139
8144
|
// being animated in the first place.
|
|
@@ -8298,16 +8303,18 @@ var victoryInterpolator = function (a, b) {
|
|
|
8298
8303
|
}
|
|
8299
8304
|
|
|
8300
8305
|
if (lodash_isPlainObject__WEBPACK_IMPORTED_MODULE_1___default()(a) || lodash_isPlainObject__WEBPACK_IMPORTED_MODULE_1___default()(b)) {
|
|
8301
|
-
// @ts-expect-error These generics are tough, but they work
|
|
8306
|
+
// @ts-expect-error These generics are tough, but they work :)
|
|
8302
8307
|
return interpolateObject(a, b);
|
|
8303
8308
|
}
|
|
8304
8309
|
|
|
8305
8310
|
if (typeof a === "string" || typeof b === "string") {
|
|
8306
8311
|
return interpolateString(a, b);
|
|
8307
|
-
}
|
|
8312
|
+
} // @ts-expect-error These generics are tough, but they work :)
|
|
8313
|
+
|
|
8308
8314
|
|
|
8309
8315
|
return (0,victory_vendor_d3_interpolate__WEBPACK_IMPORTED_MODULE_2__["default"])(a, b);
|
|
8310
8316
|
};
|
|
8317
|
+
//# sourceMappingURL=util.js.map
|
|
8311
8318
|
|
|
8312
8319
|
/***/ }),
|
|
8313
8320
|
|
|
@@ -8570,6 +8577,7 @@ VictoryAnimation.defaultProps = {
|
|
|
8570
8577
|
easing: "quadInOut"
|
|
8571
8578
|
};
|
|
8572
8579
|
VictoryAnimation.contextType = _victory_util_timer_context__WEBPACK_IMPORTED_MODULE_5__["default"];
|
|
8580
|
+
//# sourceMappingURL=victory-animation.js.map
|
|
8573
8581
|
|
|
8574
8582
|
/***/ }),
|
|
8575
8583
|
|
|
@@ -8883,6 +8891,7 @@ VictoryContainer.defaultProps = {
|
|
|
8883
8891
|
role: "img"
|
|
8884
8892
|
};
|
|
8885
8893
|
VictoryContainer.contextType = _victory_util_timer_context__WEBPACK_IMPORTED_MODULE_12__["default"];
|
|
8894
|
+
//# sourceMappingURL=victory-container.js.map
|
|
8886
8895
|
|
|
8887
8896
|
/***/ }),
|
|
8888
8897
|
|
|
@@ -9488,10 +9497,9 @@ VictoryLabel.propTypes = {
|
|
|
9488
9497
|
inline: (prop_types__WEBPACK_IMPORTED_MODULE_11___default().bool),
|
|
9489
9498
|
labelPlacement: prop_types__WEBPACK_IMPORTED_MODULE_11___default().oneOf(["parallel", "perpendicular", "vertical"]),
|
|
9490
9499
|
lineHeight: prop_types__WEBPACK_IMPORTED_MODULE_11___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_11___default().string), _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_12__.nonNegative, (prop_types__WEBPACK_IMPORTED_MODULE_11___default().func), (prop_types__WEBPACK_IMPORTED_MODULE_11___default().array)]),
|
|
9491
|
-
// @ts-expect-error "x is required in origin"
|
|
9492
9500
|
origin: prop_types__WEBPACK_IMPORTED_MODULE_11___default().shape({
|
|
9493
|
-
x: _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_12__.nonNegative,
|
|
9494
|
-
y: _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_12__.nonNegative
|
|
9501
|
+
x: _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_12__.nonNegative.isRequired,
|
|
9502
|
+
y: _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_12__.nonNegative.isRequired
|
|
9495
9503
|
}),
|
|
9496
9504
|
polar: (prop_types__WEBPACK_IMPORTED_MODULE_11___default().bool),
|
|
9497
9505
|
renderInPortal: (prop_types__WEBPACK_IMPORTED_MODULE_11___default().bool),
|
|
@@ -9525,6 +9533,7 @@ VictoryLabel.defaultProps = {
|
|
|
9525
9533
|
// Magic number from d3.
|
|
9526
9534
|
lineHeight: 1
|
|
9527
9535
|
};
|
|
9536
|
+
//# sourceMappingURL=victory-label.js.map
|
|
9528
9537
|
|
|
9529
9538
|
/***/ }),
|
|
9530
9539
|
|
|
@@ -9549,6 +9558,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9549
9558
|
*/
|
|
9550
9559
|
var PortalContext = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createContext({});
|
|
9551
9560
|
PortalContext.displayName = "PortalContext";
|
|
9561
|
+
//# sourceMappingURL=portal-context.js.map
|
|
9552
9562
|
|
|
9553
9563
|
/***/ }),
|
|
9554
9564
|
|
|
@@ -9660,6 +9670,7 @@ Portal.propTypes = {
|
|
|
9660
9670
|
viewBox: (prop_types__WEBPACK_IMPORTED_MODULE_2___default().string),
|
|
9661
9671
|
width: _victory_util_prop_types__WEBPACK_IMPORTED_MODULE_3__.nonNegative
|
|
9662
9672
|
};
|
|
9673
|
+
//# sourceMappingURL=portal.js.map
|
|
9663
9674
|
|
|
9664
9675
|
/***/ }),
|
|
9665
9676
|
|
|
@@ -9803,6 +9814,7 @@ VictoryPortal.defaultProps = {
|
|
|
9803
9814
|
groupComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("g", null)
|
|
9804
9815
|
};
|
|
9805
9816
|
VictoryPortal.contextType = _portal_context__WEBPACK_IMPORTED_MODULE_5__.PortalContext;
|
|
9817
|
+
//# sourceMappingURL=victory-portal.js.map
|
|
9806
9818
|
|
|
9807
9819
|
/***/ }),
|
|
9808
9820
|
|
|
@@ -9839,6 +9851,7 @@ var Path = function (props) {
|
|
|
9839
9851
|
// @ts-expect-error FIXME: "id cannot be a number"
|
|
9840
9852
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("path", rest);
|
|
9841
9853
|
};
|
|
9854
|
+
//# sourceMappingURL=path.js.map
|
|
9842
9855
|
|
|
9843
9856
|
/***/ }),
|
|
9844
9857
|
|
|
@@ -9881,6 +9894,7 @@ var Rect = function (props) {
|
|
|
9881
9894
|
vectorEffect: "non-scaling-stroke"
|
|
9882
9895
|
}, rest));
|
|
9883
9896
|
};
|
|
9897
|
+
//# sourceMappingURL=rect.js.map
|
|
9884
9898
|
|
|
9885
9899
|
/***/ }),
|
|
9886
9900
|
|
|
@@ -9924,6 +9938,7 @@ Text.propTypes = {
|
|
|
9924
9938
|
desc: (prop_types__WEBPACK_IMPORTED_MODULE_1___default().string),
|
|
9925
9939
|
title: (prop_types__WEBPACK_IMPORTED_MODULE_1___default().string)
|
|
9926
9940
|
};
|
|
9941
|
+
//# sourceMappingURL=text.js.map
|
|
9927
9942
|
|
|
9928
9943
|
/***/ }),
|
|
9929
9944
|
|
|
@@ -9948,6 +9963,7 @@ var TSpan = function (props) {
|
|
|
9948
9963
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tspan", props)
|
|
9949
9964
|
);
|
|
9950
9965
|
};
|
|
9966
|
+
//# sourceMappingURL=tspan.js.map
|
|
9951
9967
|
|
|
9952
9968
|
/***/ }),
|
|
9953
9969
|
|
|
@@ -10223,6 +10239,7 @@ var grayscale = {
|
|
|
10223
10239
|
}
|
|
10224
10240
|
}, baseProps)
|
|
10225
10241
|
};
|
|
10242
|
+
//# sourceMappingURL=grayscale.js.map
|
|
10226
10243
|
|
|
10227
10244
|
/***/ }),
|
|
10228
10245
|
|
|
@@ -10525,6 +10542,7 @@ var material = {
|
|
|
10525
10542
|
}
|
|
10526
10543
|
}, baseProps)
|
|
10527
10544
|
};
|
|
10545
|
+
//# sourceMappingURL=material.js.map
|
|
10528
10546
|
|
|
10529
10547
|
/***/ }),
|
|
10530
10548
|
|
|
@@ -10548,6 +10566,7 @@ var VictoryTheme = {
|
|
|
10548
10566
|
grayscale: _grayscale__WEBPACK_IMPORTED_MODULE_0__.grayscale,
|
|
10549
10567
|
material: _material__WEBPACK_IMPORTED_MODULE_1__.material
|
|
10550
10568
|
};
|
|
10569
|
+
//# sourceMappingURL=victory-theme.js.map
|
|
10551
10570
|
|
|
10552
10571
|
/***/ }),
|
|
10553
10572
|
|
|
@@ -10816,6 +10835,7 @@ VictoryTransition.propTypes = {
|
|
|
10816
10835
|
children: (prop_types__WEBPACK_IMPORTED_MODULE_9___default().node)
|
|
10817
10836
|
};
|
|
10818
10837
|
VictoryTransition.contextType = _victory_util_timer_context__WEBPACK_IMPORTED_MODULE_10__["default"];
|
|
10838
|
+
//# sourceMappingURL=victory-transition.js.map
|
|
10819
10839
|
|
|
10820
10840
|
/***/ }),
|
|
10821
10841
|
|
|
@@ -10828,26 +10848,26 @@ VictoryTransition.contextType = _victory_util_timer_context__WEBPACK_IMPORTED_MO
|
|
|
10828
10848
|
"use strict";
|
|
10829
10849
|
__webpack_require__.r(__webpack_exports__);
|
|
10830
10850
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
10831
|
-
/* harmony export */ "
|
|
10851
|
+
/* harmony export */ "addEvents": () => (/* binding */ addEvents)
|
|
10832
10852
|
/* harmony export */ });
|
|
10833
|
-
/* harmony import */ var
|
|
10834
|
-
/* harmony import */ var
|
|
10835
|
-
/* harmony import */ var
|
|
10836
|
-
/* harmony import */ var
|
|
10837
|
-
/* harmony import */ var
|
|
10838
|
-
/* harmony import */ var
|
|
10839
|
-
/* harmony import */ var
|
|
10840
|
-
/* harmony import */ var
|
|
10841
|
-
/* harmony import */ var
|
|
10842
|
-
/* harmony import */ var
|
|
10843
|
-
/* harmony import */ var
|
|
10844
|
-
/* harmony import */ var
|
|
10845
|
-
/* harmony import */ var
|
|
10846
|
-
/* harmony import */ var
|
|
10847
|
-
/* harmony import */ var
|
|
10848
|
-
/* harmony import */ var
|
|
10849
|
-
/* harmony import */ var
|
|
10850
|
-
/* harmony import */ var
|
|
10853
|
+
/* harmony import */ var lodash_without__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/without */ "../../../node_modules/lodash/without.js");
|
|
10854
|
+
/* harmony import */ var lodash_without__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_without__WEBPACK_IMPORTED_MODULE_0__);
|
|
10855
|
+
/* harmony import */ var lodash_pick__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash/pick */ "../../../node_modules/lodash/pick.js");
|
|
10856
|
+
/* harmony import */ var lodash_pick__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_pick__WEBPACK_IMPORTED_MODULE_1__);
|
|
10857
|
+
/* harmony import */ var lodash_keys__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! lodash/keys */ "../../../node_modules/lodash/keys.js");
|
|
10858
|
+
/* harmony import */ var lodash_keys__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash_keys__WEBPACK_IMPORTED_MODULE_2__);
|
|
10859
|
+
/* harmony import */ var lodash_isNil__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! lodash/isNil */ "../../../node_modules/lodash/isNil.js");
|
|
10860
|
+
/* harmony import */ var lodash_isNil__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash_isNil__WEBPACK_IMPORTED_MODULE_3__);
|
|
10861
|
+
/* harmony import */ var lodash_isFunction__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! lodash/isFunction */ "../../../node_modules/lodash/isFunction.js");
|
|
10862
|
+
/* harmony import */ var lodash_isFunction__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(lodash_isFunction__WEBPACK_IMPORTED_MODULE_4__);
|
|
10863
|
+
/* harmony import */ var lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! lodash/isEmpty */ "../../../node_modules/lodash/isEmpty.js");
|
|
10864
|
+
/* harmony import */ var lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5__);
|
|
10865
|
+
/* harmony import */ var lodash_difference__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! lodash/difference */ "../../../node_modules/lodash/difference.js");
|
|
10866
|
+
/* harmony import */ var lodash_difference__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(lodash_difference__WEBPACK_IMPORTED_MODULE_6__);
|
|
10867
|
+
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! lodash/defaults */ "../../../node_modules/lodash/defaults.js");
|
|
10868
|
+
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_7__);
|
|
10869
|
+
/* harmony import */ var lodash_assign__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! lodash/assign */ "../../../node_modules/lodash/assign.js");
|
|
10870
|
+
/* harmony import */ var lodash_assign__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(lodash_assign__WEBPACK_IMPORTED_MODULE_8__);
|
|
10851
10871
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! react */ "react");
|
|
10852
10872
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_9__);
|
|
10853
10873
|
/* harmony import */ var _events__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./events */ "../../victory-core/es/victory-util/events.js");
|
|
@@ -10900,13 +10920,14 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
|
|
|
10900
10920
|
|
|
10901
10921
|
|
|
10902
10922
|
|
|
10903
|
-
|
|
10923
|
+
|
|
10924
|
+
|
|
10925
|
+
// DISCLAIMER:
|
|
10904
10926
|
// This file is not currently tested, and it is first on the list of files
|
|
10905
10927
|
// to refactor in our current refactoring effort. Please do not make changes
|
|
10906
10928
|
// to this file without manual testing and/or refactoring and adding tests.
|
|
10907
|
-
|
|
10908
10929
|
var datumHasXandY = function (datum) {
|
|
10909
|
-
return !
|
|
10930
|
+
return !lodash_isNil__WEBPACK_IMPORTED_MODULE_3___default()(datum._x) && !lodash_isNil__WEBPACK_IMPORTED_MODULE_3___default()(datum._y);
|
|
10910
10931
|
}; // used for checking state changes. Expected components can be passed in via options
|
|
10911
10932
|
|
|
10912
10933
|
|
|
@@ -10918,44 +10939,45 @@ var defaultComponents = [{
|
|
|
10918
10939
|
}, {
|
|
10919
10940
|
name: "labels"
|
|
10920
10941
|
}];
|
|
10921
|
-
|
|
10922
|
-
|
|
10923
|
-
|
|
10942
|
+
function addEvents(WrappedComponent) {
|
|
10943
|
+
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
10944
|
+
|
|
10945
|
+
// @ts-expect-error "TS2545: A mixin class must have a constructor with a single rest parameter of type 'any[]'."
|
|
10946
|
+
var AddEventsMixin = /*#__PURE__*/function (_WrappedComponent) {
|
|
10947
|
+
_inherits(AddEventsMixin, _WrappedComponent);
|
|
10924
10948
|
|
|
10925
|
-
var _super = _createSuper(
|
|
10949
|
+
var _super = _createSuper(AddEventsMixin);
|
|
10926
10950
|
|
|
10927
|
-
function
|
|
10951
|
+
function AddEventsMixin(props) {
|
|
10928
10952
|
var _this;
|
|
10929
10953
|
|
|
10930
|
-
_classCallCheck(this,
|
|
10954
|
+
_classCallCheck(this, AddEventsMixin);
|
|
10931
10955
|
|
|
10932
10956
|
_this = _super.call(this, props);
|
|
10933
|
-
var getScopedEvents = _events__WEBPACK_IMPORTED_MODULE_11__.getScopedEvents.bind(_assertThisInitialized(_this));
|
|
10934
|
-
var boundGetEvents = _events__WEBPACK_IMPORTED_MODULE_11__.getEvents.bind(_assertThisInitialized(_this));
|
|
10935
10957
|
_this.state = {};
|
|
10958
|
+
_this.getEventState = _events__WEBPACK_IMPORTED_MODULE_11__.getEventState.bind(_assertThisInitialized(_this));
|
|
10959
|
+
_this.getScopedEvents = _events__WEBPACK_IMPORTED_MODULE_11__.getScopedEvents.bind(_assertThisInitialized(_this));
|
|
10936
10960
|
|
|
10937
10961
|
_this.getEvents = function (p, target, eventKey) {
|
|
10938
|
-
return
|
|
10962
|
+
return _events__WEBPACK_IMPORTED_MODULE_11__.getEvents.call(_assertThisInitialized(_this), p, target, eventKey, _this.getScopedEvents);
|
|
10939
10963
|
};
|
|
10940
10964
|
|
|
10941
|
-
_this.
|
|
10942
|
-
|
|
10943
|
-
var calculatedValues = _this.getCalculatedValues(props);
|
|
10944
|
-
|
|
10945
|
-
_this.cacheValues(calculatedValues);
|
|
10946
|
-
|
|
10947
|
-
_this.externalMutations = _this.getExternalMutations(props);
|
|
10948
|
-
_this.calculatedState = _this.getStateChanges(props);
|
|
10965
|
+
_this.externalMutations = _this.getExternalMutations(_this.props);
|
|
10966
|
+
_this.calculatedState = _this.getStateChanges(_this.props);
|
|
10949
10967
|
_this.globalEvents = {};
|
|
10950
10968
|
_this.prevGlobalEventKeys = [];
|
|
10951
10969
|
_this.boundGlobalEvents = {};
|
|
10970
|
+
|
|
10971
|
+
_this.cacheValues(_this.getCalculatedValues(props));
|
|
10972
|
+
|
|
10952
10973
|
return _this;
|
|
10953
10974
|
}
|
|
10954
10975
|
|
|
10955
|
-
_createClass(
|
|
10976
|
+
_createClass(AddEventsMixin, [{
|
|
10956
10977
|
key: "shouldComponentUpdate",
|
|
10957
10978
|
value: function shouldComponentUpdate(nextProps) {
|
|
10958
|
-
var externalMutations = this.getExternalMutations(nextProps);
|
|
10979
|
+
var externalMutations = this.getExternalMutations(nextProps); // @ts-expect-error "Property 'animating' does not exist on type EventMixinCommonProps"
|
|
10980
|
+
|
|
10959
10981
|
var animating = this.props.animating || this.props.animate;
|
|
10960
10982
|
var newMutation = !react_fast_compare__WEBPACK_IMPORTED_MODULE_10___default()(externalMutations, this.externalMutations);
|
|
10961
10983
|
|
|
@@ -10985,7 +11007,7 @@ var defaultComponents = [{
|
|
|
10985
11007
|
value: function componentDidMount() {
|
|
10986
11008
|
var _this2 = this;
|
|
10987
11009
|
|
|
10988
|
-
var globalEventKeys =
|
|
11010
|
+
var globalEventKeys = lodash_keys__WEBPACK_IMPORTED_MODULE_2___default()(this.globalEvents);
|
|
10989
11011
|
|
|
10990
11012
|
globalEventKeys.forEach(function (key) {
|
|
10991
11013
|
return _this2.addGlobalListener(key);
|
|
@@ -11000,15 +11022,15 @@ var defaultComponents = [{
|
|
|
11000
11022
|
var calculatedState = this.getStateChanges(prevProps);
|
|
11001
11023
|
this.calculatedState = calculatedState;
|
|
11002
11024
|
|
|
11003
|
-
var globalEventKeys =
|
|
11025
|
+
var globalEventKeys = lodash_keys__WEBPACK_IMPORTED_MODULE_2___default()(this.globalEvents);
|
|
11004
11026
|
|
|
11005
|
-
var removedGlobalEventKeys =
|
|
11027
|
+
var removedGlobalEventKeys = lodash_difference__WEBPACK_IMPORTED_MODULE_6___default()(this.prevGlobalEventKeys, globalEventKeys);
|
|
11006
11028
|
|
|
11007
11029
|
removedGlobalEventKeys.forEach(function (key) {
|
|
11008
11030
|
return _this3.removeGlobalListener(key);
|
|
11009
11031
|
});
|
|
11010
11032
|
|
|
11011
|
-
var addedGlobalEventKeys =
|
|
11033
|
+
var addedGlobalEventKeys = lodash_difference__WEBPACK_IMPORTED_MODULE_6___default()(globalEventKeys, this.prevGlobalEventKeys);
|
|
11012
11034
|
|
|
11013
11035
|
addedGlobalEventKeys.forEach(function (key) {
|
|
11014
11036
|
return _this3.addGlobalListener(key);
|
|
@@ -11054,12 +11076,11 @@ var defaultComponents = [{
|
|
|
11054
11076
|
}
|
|
11055
11077
|
|
|
11056
11078
|
var getState = function (key, type) {
|
|
11057
|
-
var result =
|
|
11079
|
+
var result = lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({}, _this6.getEventState(key, type), _this6.getSharedEventState(key, type));
|
|
11058
11080
|
|
|
11059
|
-
return
|
|
11081
|
+
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5___default()(result) ? undefined : result;
|
|
11060
11082
|
};
|
|
11061
11083
|
|
|
11062
|
-
options = options || {};
|
|
11063
11084
|
var components = options.components || defaultComponents;
|
|
11064
11085
|
var stateChanges = components.map(function (component) {
|
|
11065
11086
|
if (!props.standalone && component.name === "parent") {
|
|
@@ -11076,9 +11097,9 @@ var defaultComponents = [{
|
|
|
11076
11097
|
}, {
|
|
11077
11098
|
key: "applyExternalMutations",
|
|
11078
11099
|
value: function applyExternalMutations(props, externalMutations) {
|
|
11079
|
-
if (!
|
|
11100
|
+
if (!lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5___default()(externalMutations)) {
|
|
11080
11101
|
var callbacks = props.externalEventMutations.reduce(function (memo, mutation) {
|
|
11081
|
-
memo =
|
|
11102
|
+
memo = lodash_isFunction__WEBPACK_IMPORTED_MODULE_4___default()(mutation.callback) ? memo.concat(mutation.callback) : memo;
|
|
11082
11103
|
return memo;
|
|
11083
11104
|
}, []);
|
|
11084
11105
|
var compiledCallbacks = callbacks.length ? function () {
|
|
@@ -11095,12 +11116,12 @@ var defaultComponents = [{
|
|
|
11095
11116
|
var sharedEvents = props.sharedEvents;
|
|
11096
11117
|
var components = WrappedComponent.expectedComponents;
|
|
11097
11118
|
var componentEvents = _events__WEBPACK_IMPORTED_MODULE_11__.getComponentEvents(props, components);
|
|
11098
|
-
var getSharedEventState = sharedEvents &&
|
|
11119
|
+
var getSharedEventState = sharedEvents && lodash_isFunction__WEBPACK_IMPORTED_MODULE_4___default()(sharedEvents.getEventState) ? sharedEvents.getEventState : function () {
|
|
11099
11120
|
return undefined;
|
|
11100
11121
|
};
|
|
11101
11122
|
var baseProps = this.getBaseProps(props, getSharedEventState);
|
|
11102
11123
|
|
|
11103
|
-
var dataKeys =
|
|
11124
|
+
var dataKeys = lodash_keys__WEBPACK_IMPORTED_MODULE_2___default()(baseProps).filter(function (key) {
|
|
11104
11125
|
return key !== "parent";
|
|
11105
11126
|
});
|
|
11106
11127
|
|
|
@@ -11120,32 +11141,32 @@ var defaultComponents = [{
|
|
|
11120
11141
|
value: function getExternalMutations(props) {
|
|
11121
11142
|
var sharedEvents = props.sharedEvents,
|
|
11122
11143
|
externalEventMutations = props.externalEventMutations;
|
|
11123
|
-
return
|
|
11144
|
+
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_5___default()(externalEventMutations) || sharedEvents ? undefined : _events__WEBPACK_IMPORTED_MODULE_11__.getExternalMutations(externalEventMutations, this.baseProps, this.state);
|
|
11124
11145
|
}
|
|
11125
11146
|
}, {
|
|
11126
11147
|
key: "cacheValues",
|
|
11127
11148
|
value: function cacheValues(obj) {
|
|
11128
11149
|
var _this7 = this;
|
|
11129
11150
|
|
|
11130
|
-
|
|
11151
|
+
lodash_keys__WEBPACK_IMPORTED_MODULE_2___default()(obj).forEach(function (key) {
|
|
11131
11152
|
_this7[key] = obj[key];
|
|
11132
11153
|
});
|
|
11133
11154
|
}
|
|
11134
11155
|
}, {
|
|
11135
11156
|
key: "getBaseProps",
|
|
11136
11157
|
value: function getBaseProps(props, getSharedEventState) {
|
|
11137
|
-
getSharedEventState = getSharedEventState || this.getSharedEventState;
|
|
11158
|
+
getSharedEventState = getSharedEventState || this.getSharedEventState.bind(this);
|
|
11138
11159
|
var sharedParentState = getSharedEventState("parent", "parent");
|
|
11139
11160
|
var parentState = this.getEventState("parent", "parent");
|
|
11140
11161
|
|
|
11141
|
-
var baseParentProps =
|
|
11162
|
+
var baseParentProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({}, parentState, sharedParentState);
|
|
11142
11163
|
|
|
11143
11164
|
var parentPropsList = baseParentProps.parentControlledProps;
|
|
11144
|
-
var parentProps = parentPropsList ?
|
|
11165
|
+
var parentProps = parentPropsList ? lodash_pick__WEBPACK_IMPORTED_MODULE_1___default()(baseParentProps, parentPropsList) : {};
|
|
11145
11166
|
|
|
11146
|
-
var modifiedProps =
|
|
11167
|
+
var modifiedProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({}, parentProps, props);
|
|
11147
11168
|
|
|
11148
|
-
return
|
|
11169
|
+
return typeof WrappedComponent.getBaseProps === "function" ? WrappedComponent.getBaseProps(modifiedProps) : {};
|
|
11149
11170
|
}
|
|
11150
11171
|
}, {
|
|
11151
11172
|
key: "getAllEvents",
|
|
@@ -11173,21 +11194,21 @@ var defaultComponents = [{
|
|
|
11173
11194
|
if (this.hasEvents) {
|
|
11174
11195
|
var baseEvents = this.getEvents(this.props, type, key);
|
|
11175
11196
|
|
|
11176
|
-
var componentProps =
|
|
11197
|
+
var componentProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({
|
|
11177
11198
|
index: index,
|
|
11178
11199
|
key: id
|
|
11179
11200
|
}, this.getEventState(key, type), this.getSharedEventState(key, type), component.props, baseProps, {
|
|
11180
11201
|
id: id
|
|
11181
11202
|
});
|
|
11182
11203
|
|
|
11183
|
-
var events =
|
|
11204
|
+
var events = lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({}, _events__WEBPACK_IMPORTED_MODULE_11__.getPartialEvents(baseEvents, key, componentProps), componentProps.events);
|
|
11184
11205
|
|
|
11185
|
-
return
|
|
11206
|
+
return lodash_assign__WEBPACK_IMPORTED_MODULE_8___default()({}, componentProps, {
|
|
11186
11207
|
events: events
|
|
11187
11208
|
});
|
|
11188
11209
|
}
|
|
11189
11210
|
|
|
11190
|
-
return
|
|
11211
|
+
return lodash_defaults__WEBPACK_IMPORTED_MODULE_7___default()({
|
|
11191
11212
|
index: index,
|
|
11192
11213
|
key: id
|
|
11193
11214
|
}, component.props, baseProps, {
|
|
@@ -11210,11 +11231,14 @@ var defaultComponents = [{
|
|
|
11210
11231
|
}, {
|
|
11211
11232
|
key: "animateComponent",
|
|
11212
11233
|
value: function animateComponent(props, defaultAnimationWhitelist) {
|
|
11213
|
-
var
|
|
11234
|
+
var _props$animate;
|
|
11235
|
+
|
|
11236
|
+
var animationWhitelist = typeof props.animate === "object" && ((_props$animate = props.animate) === null || _props$animate === void 0 ? void 0 : _props$animate.animationWhitelist) || defaultAnimationWhitelist;
|
|
11237
|
+
var Comp = this.constructor;
|
|
11214
11238
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_9___default().createElement(_victory_transition_victory_transition__WEBPACK_IMPORTED_MODULE_12__.VictoryTransition, {
|
|
11215
11239
|
animate: props.animate,
|
|
11216
11240
|
animationWhitelist: animationWhitelist
|
|
11217
|
-
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_9___default().createElement(
|
|
11241
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_9___default().createElement(Comp, props));
|
|
11218
11242
|
} // Used by `VictoryLine` and `VictoryArea`
|
|
11219
11243
|
|
|
11220
11244
|
}, {
|
|
@@ -11226,7 +11250,7 @@ var defaultComponents = [{
|
|
|
11226
11250
|
labelComponent = props.labelComponent,
|
|
11227
11251
|
groupComponent = props.groupComponent;
|
|
11228
11252
|
|
|
11229
|
-
var dataKeys =
|
|
11253
|
+
var dataKeys = lodash_without__WEBPACK_IMPORTED_MODULE_0___default()(this.dataKeys, "all");
|
|
11230
11254
|
|
|
11231
11255
|
var labelComponents = dataKeys.reduce(function (memo, key) {
|
|
11232
11256
|
var labelProps = _this8.getComponentProps(labelComponent, "labels", key);
|
|
@@ -11273,9 +11297,12 @@ var defaultComponents = [{
|
|
|
11273
11297
|
}
|
|
11274
11298
|
}]);
|
|
11275
11299
|
|
|
11276
|
-
return
|
|
11300
|
+
return AddEventsMixin;
|
|
11277
11301
|
}(WrappedComponent);
|
|
11278
|
-
|
|
11302
|
+
|
|
11303
|
+
return AddEventsMixin;
|
|
11304
|
+
}
|
|
11305
|
+
//# sourceMappingURL=add-events.js.map
|
|
11279
11306
|
|
|
11280
11307
|
/***/ }),
|
|
11281
11308
|
|
|
@@ -11309,7 +11336,6 @@ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToAr
|
|
|
11309
11336
|
|
|
11310
11337
|
function _arrayLikeToArray(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; }
|
|
11311
11338
|
|
|
11312
|
-
/* eslint-disable no-use-before-define */
|
|
11313
11339
|
function isNonEmptyArray(collection) {
|
|
11314
11340
|
return Array.isArray(collection) && collection.length > 0;
|
|
11315
11341
|
}
|
|
@@ -11348,7 +11374,8 @@ function getMaxValue(arr) {
|
|
|
11348
11374
|
}
|
|
11349
11375
|
|
|
11350
11376
|
var array = arr.concat(values);
|
|
11351
|
-
return containsDates(array) ? new Date(Math.max.apply(Math, _toConsumableArray(array)))
|
|
11377
|
+
return containsDates(array) ? new Date(Math.max.apply(Math, _toConsumableArray(array))) // Dates will be coerced to numbers
|
|
11378
|
+
: Math.max.apply(Math, _toConsumableArray(array));
|
|
11352
11379
|
}
|
|
11353
11380
|
function getMinValue(arr) {
|
|
11354
11381
|
for (var _len2 = arguments.length, values = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
@@ -11356,8 +11383,10 @@ function getMinValue(arr) {
|
|
|
11356
11383
|
}
|
|
11357
11384
|
|
|
11358
11385
|
var array = arr.concat(values);
|
|
11359
|
-
return containsDates(array) ? new Date(Math.min.apply(Math, _toConsumableArray(array)))
|
|
11386
|
+
return containsDates(array) ? new Date(Math.min.apply(Math, _toConsumableArray(array))) // Dates will be coerced to numbers
|
|
11387
|
+
: Math.min.apply(Math, _toConsumableArray(array));
|
|
11360
11388
|
}
|
|
11389
|
+
//# sourceMappingURL=collection.js.map
|
|
11361
11390
|
|
|
11362
11391
|
/***/ }),
|
|
11363
11392
|
|
|
@@ -11370,9 +11399,7 @@ function getMinValue(arr) {
|
|
|
11370
11399
|
"use strict";
|
|
11371
11400
|
__webpack_require__.r(__webpack_exports__);
|
|
11372
11401
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
11373
|
-
/* harmony export */ "
|
|
11374
|
-
/* harmony export */ "dataProps": () => (/* binding */ dataProps),
|
|
11375
|
-
/* harmony export */ "primitiveProps": () => (/* binding */ primitiveProps)
|
|
11402
|
+
/* harmony export */ "CommonProps": () => (/* binding */ CommonProps)
|
|
11376
11403
|
/* harmony export */ });
|
|
11377
11404
|
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! prop-types */ "../../../node_modules/prop-types/index.js");
|
|
11378
11405
|
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_0__);
|
|
@@ -11380,26 +11407,28 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
11380
11407
|
|
|
11381
11408
|
|
|
11382
11409
|
var dataProps = {
|
|
11410
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11383
11411
|
categories: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string)), prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11384
11412
|
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string)),
|
|
11385
11413
|
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string))
|
|
11386
11414
|
})]),
|
|
11415
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11387
11416
|
data: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().array), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object)]),
|
|
11388
11417
|
dataComponent: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().element),
|
|
11389
11418
|
disableInlineStyles: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool),
|
|
11390
11419
|
labelComponent: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().element),
|
|
11391
11420
|
labels: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().array)]),
|
|
11392
11421
|
samples: _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative,
|
|
11393
|
-
sortKey: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string))]),
|
|
11422
|
+
sortKey: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string.isRequired))]),
|
|
11394
11423
|
sortOrder: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOf(["ascending", "descending"]),
|
|
11395
11424
|
style: prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11396
11425
|
parent: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object),
|
|
11397
11426
|
data: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object),
|
|
11398
11427
|
labels: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object)
|
|
11399
11428
|
}),
|
|
11400
|
-
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string))]),
|
|
11401
|
-
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string))]),
|
|
11402
|
-
y0: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string))])
|
|
11429
|
+
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string.isRequired))]),
|
|
11430
|
+
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string.isRequired))]),
|
|
11431
|
+
y0: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().func), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().string.isRequired))])
|
|
11403
11432
|
};
|
|
11404
11433
|
var baseProps = {
|
|
11405
11434
|
animate: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object)]),
|
|
@@ -11408,14 +11437,17 @@ var baseProps = {
|
|
|
11408
11437
|
x: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain,
|
|
11409
11438
|
y: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain
|
|
11410
11439
|
})]),
|
|
11440
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11411
11441
|
maxDomain: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date), prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11412
11442
|
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date)]),
|
|
11413
11443
|
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date)])
|
|
11414
11444
|
})]),
|
|
11445
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11415
11446
|
minDomain: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date), prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11416
11447
|
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date)]),
|
|
11417
11448
|
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().instanceOf(Date)])
|
|
11418
11449
|
})]),
|
|
11450
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11419
11451
|
domainPadding: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11420
11452
|
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().number))]),
|
|
11421
11453
|
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf((prop_types__WEBPACK_IMPORTED_MODULE_0___default().number))])
|
|
@@ -11426,6 +11458,7 @@ var baseProps = {
|
|
|
11426
11458
|
eventKey: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().array), _prop_types__WEBPACK_IMPORTED_MODULE_1__.allOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.integer, _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative]), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string)]),
|
|
11427
11459
|
eventHandlers: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object)
|
|
11428
11460
|
})),
|
|
11461
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11429
11462
|
externalEventMutations: prop_types__WEBPACK_IMPORTED_MODULE_0___default().arrayOf(prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11430
11463
|
callback: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().func),
|
|
11431
11464
|
childName: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().array)]),
|
|
@@ -11436,10 +11469,12 @@ var baseProps = {
|
|
|
11436
11469
|
groupComponent: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().element),
|
|
11437
11470
|
height: _prop_types__WEBPACK_IMPORTED_MODULE_1__.nonNegative,
|
|
11438
11471
|
name: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string),
|
|
11472
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11439
11473
|
origin: prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11440
11474
|
x: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number),
|
|
11441
11475
|
y: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number)
|
|
11442
11476
|
}),
|
|
11477
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11443
11478
|
padding: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11444
11479
|
top: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number),
|
|
11445
11480
|
bottom: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number),
|
|
@@ -11448,17 +11483,19 @@ var baseProps = {
|
|
|
11448
11483
|
})]),
|
|
11449
11484
|
polar: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool),
|
|
11450
11485
|
range: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.domain, prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11451
|
-
x: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain,
|
|
11452
|
-
y: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain
|
|
11486
|
+
x: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain.isRequired,
|
|
11487
|
+
y: _prop_types__WEBPACK_IMPORTED_MODULE_1__.domain.isRequired
|
|
11453
11488
|
})]),
|
|
11454
11489
|
scale: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([_prop_types__WEBPACK_IMPORTED_MODULE_1__.scale, prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11455
|
-
x: _prop_types__WEBPACK_IMPORTED_MODULE_1__.scale,
|
|
11456
|
-
y: _prop_types__WEBPACK_IMPORTED_MODULE_1__.scale
|
|
11490
|
+
x: _prop_types__WEBPACK_IMPORTED_MODULE_1__.scale.isRequired,
|
|
11491
|
+
y: _prop_types__WEBPACK_IMPORTED_MODULE_1__.scale.isRequired
|
|
11457
11492
|
})]),
|
|
11493
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11458
11494
|
sharedEvents: prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11459
11495
|
events: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().array),
|
|
11460
11496
|
getEventState: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().func)
|
|
11461
11497
|
}),
|
|
11498
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11462
11499
|
singleQuadrantDomainPadding: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool), prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11463
11500
|
x: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool)]),
|
|
11464
11501
|
y: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().bool)])
|
|
@@ -11478,6 +11515,7 @@ var primitiveProps = {
|
|
|
11478
11515
|
events: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().object),
|
|
11479
11516
|
id: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().func)]),
|
|
11480
11517
|
index: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string)]),
|
|
11518
|
+
// @ts-expect-error TODO: synchronize the type with this PropTypes
|
|
11481
11519
|
origin: prop_types__WEBPACK_IMPORTED_MODULE_0___default().shape({
|
|
11482
11520
|
x: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number),
|
|
11483
11521
|
y: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().number)
|
|
@@ -11493,6 +11531,12 @@ var primitiveProps = {
|
|
|
11493
11531
|
tabIndex: prop_types__WEBPACK_IMPORTED_MODULE_0___default().oneOfType([(prop_types__WEBPACK_IMPORTED_MODULE_0___default().number), (prop_types__WEBPACK_IMPORTED_MODULE_0___default().func)]),
|
|
11494
11532
|
transform: (prop_types__WEBPACK_IMPORTED_MODULE_0___default().string)
|
|
11495
11533
|
};
|
|
11534
|
+
var CommonProps = {
|
|
11535
|
+
dataProps: dataProps,
|
|
11536
|
+
baseProps: baseProps,
|
|
11537
|
+
primitiveProps: primitiveProps
|
|
11538
|
+
};
|
|
11539
|
+
//# sourceMappingURL=common-props.js.map
|
|
11496
11540
|
|
|
11497
11541
|
/***/ }),
|
|
11498
11542
|
|
|
@@ -12006,6 +12050,7 @@ function isDataComponent(component) {
|
|
|
12006
12050
|
var whitelist = ["area", "bar", "boxplot", "candlestick", "errorbar", "group", "histogram", "line", "pie", "scatter", "stack", "voronoi"];
|
|
12007
12051
|
return lodash_includes__WEBPACK_IMPORTED_MODULE_2___default()(whitelist, role);
|
|
12008
12052
|
}
|
|
12053
|
+
//# sourceMappingURL=data.js.map
|
|
12009
12054
|
|
|
12010
12055
|
/***/ }),
|
|
12011
12056
|
|
|
@@ -12107,8 +12152,9 @@ function getDomainPadding(props, axis) {
|
|
|
12107
12152
|
}
|
|
12108
12153
|
|
|
12109
12154
|
function getFlatData(dataset, axis) {
|
|
12155
|
+
var axisKey = "_".concat(axis);
|
|
12110
12156
|
return lodash_flatten__WEBPACK_IMPORTED_MODULE_5___default()(dataset).map(function (datum) {
|
|
12111
|
-
return datum[
|
|
12157
|
+
return datum[axisKey] && datum[axisKey][1] !== undefined ? datum[axisKey][1] : datum[axisKey];
|
|
12112
12158
|
});
|
|
12113
12159
|
}
|
|
12114
12160
|
|
|
@@ -12173,7 +12219,9 @@ function padDomain(domain, props, axis) {
|
|
|
12173
12219
|
if (addsQuadrants && singleQuadrantDomainPadding !== false) {
|
|
12174
12220
|
// Naive initial padding calculation
|
|
12175
12221
|
var initialPadding = {
|
|
12222
|
+
// @ts-expect-error `max/min` might be dates
|
|
12176
12223
|
left: Math.abs(max - min) * padding.left / rangeExtent,
|
|
12224
|
+
// @ts-expect-error `max/min` might be dates
|
|
12177
12225
|
right: Math.abs(max - min) * padding.right / rangeExtent
|
|
12178
12226
|
}; // Adjust the domain by the initial padding
|
|
12179
12227
|
|
|
@@ -12458,6 +12506,7 @@ function isDomainComponent(component) {
|
|
|
12458
12506
|
var whitelist = ["area", "axis", "bar", "boxplot", "candlestick", "errorbar", "group", "histogram", "line", "pie", "scatter", "stack", "voronoi"];
|
|
12459
12507
|
return lodash_includes__WEBPACK_IMPORTED_MODULE_1___default()(whitelist, role);
|
|
12460
12508
|
}
|
|
12509
|
+
//# sourceMappingURL=domain.js.map
|
|
12461
12510
|
|
|
12462
12511
|
/***/ }),
|
|
12463
12512
|
|
|
@@ -12526,15 +12575,16 @@ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToAr
|
|
|
12526
12575
|
function _arrayLikeToArray(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; }
|
|
12527
12576
|
|
|
12528
12577
|
var GLOBAL_EVENT_REGEX = /^onGlobal(.*)$/;
|
|
12578
|
+
|
|
12529
12579
|
/* Returns all own and shared events that should be attached to a single target element,
|
|
12530
12580
|
* i.e. an individual bar specified by target: "data", eventKey: [index].
|
|
12531
12581
|
* Returned events are scoped to the appropriate state. Either that of the component itself
|
|
12532
12582
|
* (i.e. VictoryBar) in the case of own events, or that of the parent component
|
|
12533
12583
|
* (i.e. VictoryChart) in the case of shared events
|
|
12534
12584
|
*/
|
|
12535
|
-
// eslint-disable-next-line max-params
|
|
12536
|
-
|
|
12537
|
-
|
|
12585
|
+
// eslint-disable-next-line max-params
|
|
12586
|
+
function getEvents(props, target, eventKey, // eslint-disable-next-line no-shadow
|
|
12587
|
+
getScopedEvents) {
|
|
12538
12588
|
var _this = this;
|
|
12539
12589
|
|
|
12540
12590
|
// Returns all events that apply to a particular target element
|
|
@@ -12757,24 +12807,27 @@ function getScopedEvents(events, namespace, childType, baseProps) {
|
|
|
12757
12807
|
return memo;
|
|
12758
12808
|
}, {});
|
|
12759
12809
|
}
|
|
12760
|
-
/*
|
|
12810
|
+
/*
|
|
12811
|
+
* Returns a partially applied event handler for a specific target element
|
|
12761
12812
|
* This allows event handlers to have access to props controlling each element
|
|
12762
12813
|
*/
|
|
12763
12814
|
|
|
12764
12815
|
function getPartialEvents(events, eventKey, childProps) {
|
|
12765
|
-
|
|
12816
|
+
if (!events) return {};
|
|
12817
|
+
return lodash_keys__WEBPACK_IMPORTED_MODULE_0___default()(events).reduce(function (memo, eventName) {
|
|
12766
12818
|
var appliedEvent = function (evt) {
|
|
12767
12819
|
return events[eventName](evt, childProps, eventKey, eventName);
|
|
12768
12820
|
};
|
|
12769
12821
|
|
|
12770
12822
|
memo[eventName] = appliedEvent;
|
|
12771
12823
|
return memo;
|
|
12772
|
-
}, {})
|
|
12824
|
+
}, {});
|
|
12773
12825
|
}
|
|
12826
|
+
|
|
12774
12827
|
/* Returns the property of the state object corresponding to event changes for
|
|
12775
12828
|
* a particular element
|
|
12776
12829
|
*/
|
|
12777
|
-
|
|
12830
|
+
// eslint-disable-next-line max-params
|
|
12778
12831
|
function getEventState(eventKey, namespace, childType) {
|
|
12779
12832
|
// Mandatory usage: `getEventState.bind(this)`
|
|
12780
12833
|
// eslint-disable-next-line no-invalid-this
|
|
@@ -12959,6 +13012,7 @@ var emulateReactEvent = function (event) {
|
|
|
12959
13012
|
nativeEvent: event
|
|
12960
13013
|
});
|
|
12961
13014
|
};
|
|
13015
|
+
//# sourceMappingURL=events.js.map
|
|
12962
13016
|
|
|
12963
13017
|
/***/ }),
|
|
12964
13018
|
|
|
@@ -13040,7 +13094,7 @@ function getPolarRange(props, axis) {
|
|
|
13040
13094
|
|
|
13041
13095
|
/**
|
|
13042
13096
|
* creates an object with some keys excluded
|
|
13043
|
-
* replacement for lodash.omit for performance. does not
|
|
13097
|
+
* replacement for lodash.omit for performance. does not mimic the entire lodash.omit api
|
|
13044
13098
|
* @param {Object} originalObject: created object will be based on this object
|
|
13045
13099
|
* @param {Array<String>} ks: an array of keys to omit from the new object
|
|
13046
13100
|
* @returns {Object} new object with same properties as originalObject
|
|
@@ -13053,6 +13107,7 @@ function omit(originalObject) {
|
|
|
13053
13107
|
var newObject = {};
|
|
13054
13108
|
|
|
13055
13109
|
for (var key in originalObject) {
|
|
13110
|
+
// @ts-expect-error String is not assignable to Key
|
|
13056
13111
|
if (ks.indexOf(key) >= 0) {
|
|
13057
13112
|
continue;
|
|
13058
13113
|
}
|
|
@@ -13285,7 +13340,9 @@ function reduceChildren(children, iteratee) {
|
|
|
13285
13340
|
var parentProps = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
13286
13341
|
var initialMemo = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : [];
|
|
13287
13342
|
var combine = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : function (memo, item) {
|
|
13288
|
-
return
|
|
13343
|
+
return (// @ts-expect-error These defaults are hard to type
|
|
13344
|
+
memo.concat(item)
|
|
13345
|
+
);
|
|
13289
13346
|
};
|
|
13290
13347
|
var sharedProps = ["data", "domain", "categories", "polar", "startAngle", "endAngle", "minDomain", "maxDomain", "horizontal"];
|
|
13291
13348
|
|
|
@@ -13329,7 +13386,7 @@ function reduceChildren(children, iteratee) {
|
|
|
13329
13386
|
/**
|
|
13330
13387
|
* @param {Object} props: the props object
|
|
13331
13388
|
* @returns {Boolean} returns true if the props object contains `horizontal: true` of if any
|
|
13332
|
-
* children or nested children are
|
|
13389
|
+
* children or nested children are horizontal
|
|
13333
13390
|
*/
|
|
13334
13391
|
|
|
13335
13392
|
function isHorizontal(props) {
|
|
@@ -13352,6 +13409,7 @@ function isHorizontal(props) {
|
|
|
13352
13409
|
|
|
13353
13410
|
return traverseChildren(react__WEBPACK_IMPORTED_MODULE_6___default().Children.toArray(props.children));
|
|
13354
13411
|
}
|
|
13412
|
+
//# sourceMappingURL=helpers.js.map
|
|
13355
13413
|
|
|
13356
13414
|
/***/ }),
|
|
13357
13415
|
|
|
@@ -13395,15 +13453,16 @@ function isMap(x) {
|
|
|
13395
13453
|
return !!(x && x[IMMUTABLE_MAP]);
|
|
13396
13454
|
}
|
|
13397
13455
|
function shallowToJS(x, whitelist) {
|
|
13398
|
-
return isIterable(x) ? x.reduce(function (
|
|
13456
|
+
return isIterable(x) ? x.reduce(function (result, curr, key) {
|
|
13399
13457
|
if (whitelist && whitelist[key]) {
|
|
13400
13458
|
curr = shallowToJS(curr);
|
|
13401
13459
|
}
|
|
13402
13460
|
|
|
13403
|
-
|
|
13404
|
-
return
|
|
13461
|
+
result[key] = curr;
|
|
13462
|
+
return result;
|
|
13405
13463
|
}, isList(x) ? [] : {}) : x;
|
|
13406
13464
|
}
|
|
13465
|
+
//# sourceMappingURL=immutable.js.map
|
|
13407
13466
|
|
|
13408
13467
|
/***/ }),
|
|
13409
13468
|
|
|
@@ -13661,6 +13720,7 @@ function getProps(props, index) {
|
|
|
13661
13720
|
var tooltipTheme = theme && theme.tooltip || {};
|
|
13662
13721
|
return lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, labelProps, _helpers__WEBPACK_IMPORTED_MODULE_1__.omit(tooltipTheme, ["style"]));
|
|
13663
13722
|
}
|
|
13723
|
+
//# sourceMappingURL=label-helpers.js.map
|
|
13664
13724
|
|
|
13665
13725
|
/***/ }),
|
|
13666
13726
|
|
|
@@ -13686,6 +13746,7 @@ function warn(message) {
|
|
|
13686
13746
|
}
|
|
13687
13747
|
}
|
|
13688
13748
|
}
|
|
13749
|
+
//# sourceMappingURL=log.js.map
|
|
13689
13750
|
|
|
13690
13751
|
/***/ }),
|
|
13691
13752
|
|
|
@@ -13713,12 +13774,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
13713
13774
|
/* harmony import */ var lodash_isRegExp__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_isRegExp__WEBPACK_IMPORTED_MODULE_0__);
|
|
13714
13775
|
/* harmony import */ var lodash_find__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash/find */ "../../../node_modules/lodash/find.js");
|
|
13715
13776
|
/* harmony import */ var lodash_find__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_find__WEBPACK_IMPORTED_MODULE_1__);
|
|
13716
|
-
/* harmony import */ var
|
|
13717
|
-
/* harmony import */ var
|
|
13718
|
-
/* harmony import */ var
|
|
13719
|
-
/* harmony import */ var
|
|
13720
|
-
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_4__);
|
|
13721
|
-
|
|
13777
|
+
/* harmony import */ var _log__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./log */ "../../victory-core/es/victory-util/log.js");
|
|
13778
|
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! prop-types */ "../../../node_modules/prop-types/index.js");
|
|
13779
|
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_3__);
|
|
13780
|
+
/* harmony import */ var _scale__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./scale */ "../../victory-core/es/victory-util/scale.js");
|
|
13722
13781
|
|
|
13723
13782
|
|
|
13724
13783
|
|
|
@@ -13726,6 +13785,8 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13726
13785
|
|
|
13727
13786
|
|
|
13728
13787
|
|
|
13788
|
+
|
|
13789
|
+
|
|
13729
13790
|
/**
|
|
13730
13791
|
* Return a new validator based on `validator` but with the option to chain
|
|
13731
13792
|
* `isRequired` onto the validation. This is nearly identical to how React
|
|
@@ -13733,30 +13794,30 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
13733
13794
|
* @param {Function} validator Validation function.
|
|
13734
13795
|
* @returns {Function} Validator with `isRequired` option.
|
|
13735
13796
|
*/
|
|
13736
|
-
|
|
13737
13797
|
var makeChainable = function (validator) {
|
|
13738
|
-
|
|
13739
|
-
|
|
13740
|
-
|
|
13798
|
+
var createChainable = function (isRequired) {
|
|
13799
|
+
return function (props, propName, componentName) {
|
|
13800
|
+
var value = props[propName];
|
|
13741
13801
|
|
|
13742
|
-
|
|
13743
|
-
|
|
13744
|
-
|
|
13745
|
-
|
|
13802
|
+
if (value === undefined || value === null) {
|
|
13803
|
+
if (isRequired) {
|
|
13804
|
+
return new Error("Required `".concat(propName, "` was not specified in `").concat(componentName, "`."));
|
|
13805
|
+
}
|
|
13746
13806
|
|
|
13747
|
-
|
|
13748
|
-
|
|
13807
|
+
return null;
|
|
13808
|
+
}
|
|
13749
13809
|
|
|
13750
|
-
|
|
13751
|
-
|
|
13752
|
-
|
|
13810
|
+
for (var _len = arguments.length, rest = new Array(_len > 3 ? _len - 3 : 0), _key = 3; _key < _len; _key++) {
|
|
13811
|
+
rest[_key - 3] = arguments[_key];
|
|
13812
|
+
}
|
|
13753
13813
|
|
|
13754
|
-
|
|
13814
|
+
return validator.apply(void 0, [props, propName, componentName].concat(rest));
|
|
13815
|
+
};
|
|
13755
13816
|
};
|
|
13756
13817
|
|
|
13757
|
-
var chainable =
|
|
13758
|
-
|
|
13759
|
-
|
|
13818
|
+
var chainable = Object.assign(createChainable(false), {
|
|
13819
|
+
isRequired: createChainable(true)
|
|
13820
|
+
});
|
|
13760
13821
|
return chainable;
|
|
13761
13822
|
};
|
|
13762
13823
|
|
|
@@ -13786,7 +13847,7 @@ var getConstructor = function (value) {
|
|
|
13786
13847
|
};
|
|
13787
13848
|
/**
|
|
13788
13849
|
* Get the name of the constructor used to create `value`, using
|
|
13789
|
-
* `Object.
|
|
13850
|
+
* `Object.prototype.toString`. If the value is null or undefined, return
|
|
13790
13851
|
* "null" or "undefined", respectively.
|
|
13791
13852
|
* @param {*} value Instance to return the constructor name of.
|
|
13792
13853
|
* @returns {String} Name of the constructor.
|
|
@@ -13816,10 +13877,11 @@ function deprecated(propType, explanation) {
|
|
|
13816
13877
|
var value = props[propName];
|
|
13817
13878
|
|
|
13818
13879
|
if (value !== null && value !== undefined) {
|
|
13819
|
-
|
|
13880
|
+
_log__WEBPACK_IMPORTED_MODULE_2__.warn("\"".concat(propName, "\" property of \"").concat(componentName, "\" has been deprecated ").concat(explanation));
|
|
13820
13881
|
}
|
|
13821
13882
|
|
|
13822
|
-
|
|
13883
|
+
prop_types__WEBPACK_IMPORTED_MODULE_3___default().checkPropTypes(_defineProperty({}, propName, propType), props, propName, componentName);
|
|
13884
|
+
return null;
|
|
13823
13885
|
};
|
|
13824
13886
|
}
|
|
13825
13887
|
/**
|
|
@@ -13838,7 +13900,7 @@ function allOfType(validators) {
|
|
|
13838
13900
|
|
|
13839
13901
|
return validators.reduce(function (result, validator) {
|
|
13840
13902
|
return result || validator.apply(void 0, [props, propName, componentName].concat(rest));
|
|
13841
|
-
},
|
|
13903
|
+
}, null);
|
|
13842
13904
|
});
|
|
13843
13905
|
}
|
|
13844
13906
|
/**
|
|
@@ -13852,7 +13914,7 @@ var nonNegative = makeChainable(function (props, propName, componentName) {
|
|
|
13852
13914
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be a non-negative number."));
|
|
13853
13915
|
}
|
|
13854
13916
|
|
|
13855
|
-
return
|
|
13917
|
+
return null;
|
|
13856
13918
|
});
|
|
13857
13919
|
/**
|
|
13858
13920
|
* Check that the value is an integer.
|
|
@@ -13865,7 +13927,7 @@ var integer = makeChainable(function (props, propName, componentName) {
|
|
|
13865
13927
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be an integer."));
|
|
13866
13928
|
}
|
|
13867
13929
|
|
|
13868
|
-
return
|
|
13930
|
+
return null;
|
|
13869
13931
|
});
|
|
13870
13932
|
/**
|
|
13871
13933
|
* Check that the value is greater than zero.
|
|
@@ -13878,7 +13940,7 @@ var greaterThanZero = makeChainable(function (props, propName, componentName) {
|
|
|
13878
13940
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be a number greater than zero."));
|
|
13879
13941
|
}
|
|
13880
13942
|
|
|
13881
|
-
return
|
|
13943
|
+
return null;
|
|
13882
13944
|
});
|
|
13883
13945
|
/**
|
|
13884
13946
|
* Check that the value is an Array of two unique values.
|
|
@@ -13891,32 +13953,20 @@ var domain = makeChainable(function (props, propName, componentName) {
|
|
|
13891
13953
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be an array of two unique numeric values."));
|
|
13892
13954
|
}
|
|
13893
13955
|
|
|
13894
|
-
return
|
|
13956
|
+
return null;
|
|
13895
13957
|
});
|
|
13896
13958
|
/**
|
|
13897
13959
|
* Check that the value looks like a d3 `scale` function.
|
|
13898
13960
|
*/
|
|
13899
13961
|
|
|
13900
13962
|
var scale = makeChainable(function (props, propName, componentName) {
|
|
13901
|
-
var supportedScaleStrings = ["linear", "time", "log", "sqrt"];
|
|
13902
|
-
|
|
13903
|
-
var validScale = function (scl) {
|
|
13904
|
-
if (lodash_isFunction__WEBPACK_IMPORTED_MODULE_2___default()(scl)) {
|
|
13905
|
-
return lodash_isFunction__WEBPACK_IMPORTED_MODULE_2___default()(scl.copy) && lodash_isFunction__WEBPACK_IMPORTED_MODULE_2___default()(scl.domain) && lodash_isFunction__WEBPACK_IMPORTED_MODULE_2___default()(scl.range);
|
|
13906
|
-
} else if (typeof scl === "string") {
|
|
13907
|
-
return supportedScaleStrings.indexOf(scl) !== -1;
|
|
13908
|
-
}
|
|
13909
|
-
|
|
13910
|
-
return false;
|
|
13911
|
-
};
|
|
13912
|
-
|
|
13913
13963
|
var value = props[propName];
|
|
13914
13964
|
|
|
13915
|
-
if (!validScale(value)) {
|
|
13965
|
+
if (!_scale__WEBPACK_IMPORTED_MODULE_4__.validScale(value)) {
|
|
13916
13966
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be a d3 scale."));
|
|
13917
13967
|
}
|
|
13918
13968
|
|
|
13919
|
-
return
|
|
13969
|
+
return null;
|
|
13920
13970
|
});
|
|
13921
13971
|
/**
|
|
13922
13972
|
* Check that an array contains items of the same type.
|
|
@@ -13930,7 +13980,7 @@ var homogeneousArray = makeChainable(function (props, propName, componentName) {
|
|
|
13930
13980
|
}
|
|
13931
13981
|
|
|
13932
13982
|
if (values.length < 2) {
|
|
13933
|
-
return
|
|
13983
|
+
return null;
|
|
13934
13984
|
}
|
|
13935
13985
|
|
|
13936
13986
|
var comparisonConstructor = getConstructor(values[0]);
|
|
@@ -13945,7 +13995,7 @@ var homogeneousArray = makeChainable(function (props, propName, componentName) {
|
|
|
13945
13995
|
return new Error("Expected `".concat(propName, "` in `").concat(componentName, "` to be a ") + "homogeneous array, but found types `".concat(constructorName, "` and ") + "`".concat(otherConstructorName, "`."));
|
|
13946
13996
|
}
|
|
13947
13997
|
|
|
13948
|
-
return
|
|
13998
|
+
return null;
|
|
13949
13999
|
});
|
|
13950
14000
|
/**
|
|
13951
14001
|
* Check that array prop length matches props.data.length
|
|
@@ -13956,7 +14006,7 @@ var matchDataLength = makeChainable(function (props, propName) {
|
|
|
13956
14006
|
return new Error("Length of data and ".concat(propName, " arrays must match."));
|
|
13957
14007
|
}
|
|
13958
14008
|
|
|
13959
|
-
return
|
|
14009
|
+
return null;
|
|
13960
14010
|
});
|
|
13961
14011
|
/**
|
|
13962
14012
|
* Check that the value is a regular expression
|
|
@@ -13967,8 +14017,9 @@ var regExp = makeChainable(function (props, propName, componentName) {
|
|
|
13967
14017
|
return new Error("`".concat(propName, "` in `").concat(componentName, "` must be a regular expression."));
|
|
13968
14018
|
}
|
|
13969
14019
|
|
|
13970
|
-
return
|
|
14020
|
+
return null;
|
|
13971
14021
|
});
|
|
14022
|
+
//# sourceMappingURL=prop-types.js.map
|
|
13972
14023
|
|
|
13973
14024
|
/***/ }),
|
|
13974
14025
|
|
|
@@ -13986,7 +14037,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
13986
14037
|
/* harmony export */ "getScaleFromName": () => (/* binding */ getScaleFromName),
|
|
13987
14038
|
/* harmony export */ "getScaleFromProps": () => (/* binding */ getScaleFromProps),
|
|
13988
14039
|
/* harmony export */ "getScaleType": () => (/* binding */ getScaleType),
|
|
13989
|
-
/* harmony export */ "getType": () => (/* binding */ getType)
|
|
14040
|
+
/* harmony export */ "getType": () => (/* binding */ getType),
|
|
14041
|
+
/* harmony export */ "validScale": () => (/* binding */ validScale)
|
|
13990
14042
|
/* harmony export */ });
|
|
13991
14043
|
/* harmony import */ var lodash_isPlainObject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/isPlainObject */ "../../../node_modules/lodash/isPlainObject.js");
|
|
13992
14044
|
/* harmony import */ var lodash_isPlainObject__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_isPlainObject__WEBPACK_IMPORTED_MODULE_0__);
|
|
@@ -14004,8 +14056,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
14004
14056
|
|
|
14005
14057
|
|
|
14006
14058
|
|
|
14007
|
-
var supportedScaleStrings = ["linear", "time", "log", "sqrt"];
|
|
14059
|
+
var supportedScaleStrings = ["linear", "time", "log", "sqrt"];
|
|
14008
14060
|
|
|
14061
|
+
// Private Functions
|
|
14009
14062
|
function toNewName(scale) {
|
|
14010
14063
|
// d3 scale changed the naming scheme for scale from "linear" -> "scaleLinear" etc.
|
|
14011
14064
|
var capitalize = function (s) {
|
|
@@ -14075,7 +14128,13 @@ function getScaleTypeFromData(props, axis) {
|
|
|
14075
14128
|
|
|
14076
14129
|
|
|
14077
14130
|
function getScaleFromName(name) {
|
|
14078
|
-
|
|
14131
|
+
if (validScale(name)) {
|
|
14132
|
+
var methodName = toNewName(name); // @ts-expect-error scaleTime is not directly compatible with our D3Scale definition
|
|
14133
|
+
|
|
14134
|
+
return victory_vendor_d3_scale__WEBPACK_IMPORTED_MODULE_5__[methodName]();
|
|
14135
|
+
}
|
|
14136
|
+
|
|
14137
|
+
return victory_vendor_d3_scale__WEBPACK_IMPORTED_MODULE_6__["default"]();
|
|
14079
14138
|
}
|
|
14080
14139
|
function getBaseScale(props, axis) {
|
|
14081
14140
|
var scale = getScaleFromProps(props, axis);
|
|
@@ -14085,7 +14144,7 @@ function getBaseScale(props, axis) {
|
|
|
14085
14144
|
}
|
|
14086
14145
|
|
|
14087
14146
|
var defaultScale = getScaleFromDomain(props, axis) || getScaleTypeFromData(props, axis);
|
|
14088
|
-
return
|
|
14147
|
+
return getScaleFromName(defaultScale);
|
|
14089
14148
|
}
|
|
14090
14149
|
function getDefaultScale() {
|
|
14091
14150
|
return victory_vendor_d3_scale__WEBPACK_IMPORTED_MODULE_6__["default"]();
|
|
@@ -14098,7 +14157,7 @@ function getScaleFromProps(props, axis) {
|
|
|
14098
14157
|
var scale = props.scale[axis] || props.scale;
|
|
14099
14158
|
|
|
14100
14159
|
if (validScale(scale)) {
|
|
14101
|
-
return lodash_isFunction__WEBPACK_IMPORTED_MODULE_1___default()(scale) ? scale :
|
|
14160
|
+
return lodash_isFunction__WEBPACK_IMPORTED_MODULE_1___default()(scale) ? scale : getScaleFromName(scale);
|
|
14102
14161
|
}
|
|
14103
14162
|
|
|
14104
14163
|
return undefined;
|
|
@@ -14133,6 +14192,7 @@ function getType(scale) {
|
|
|
14133
14192
|
})[0];
|
|
14134
14193
|
return scaleType ? scaleType.name : undefined;
|
|
14135
14194
|
}
|
|
14195
|
+
//# sourceMappingURL=scale.js.map
|
|
14136
14196
|
|
|
14137
14197
|
/***/ }),
|
|
14138
14198
|
|
|
@@ -14204,6 +14264,7 @@ function getColorScale(name) {
|
|
|
14204
14264
|
};
|
|
14205
14265
|
return name ? scales[name] : scales.grayscale;
|
|
14206
14266
|
}
|
|
14267
|
+
//# sourceMappingURL=style.js.map
|
|
14207
14268
|
|
|
14208
14269
|
/***/ }),
|
|
14209
14270
|
|
|
@@ -14408,8 +14469,10 @@ var _getSizeWithRotate = function (axisSize, dependentSize, angle) {
|
|
|
14408
14469
|
|
|
14409
14470
|
|
|
14410
14471
|
var convertLengthToPixels = function (length, fontSize) {
|
|
14411
|
-
var
|
|
14412
|
-
|
|
14472
|
+
var _length$match;
|
|
14473
|
+
|
|
14474
|
+
var attribute = (_length$match = length.match(/[a-zA-Z%]+/)) === null || _length$match === void 0 ? void 0 : _length$match[0];
|
|
14475
|
+
var value = Number(length.match(/[0-9.,]+/));
|
|
14413
14476
|
var result;
|
|
14414
14477
|
|
|
14415
14478
|
if (!attribute) {
|
|
@@ -14475,9 +14538,9 @@ var _approximateTextHeightInternal = function (text, style) {
|
|
|
14475
14538
|
var height = containsCaps ? lineStyle.fontSize * coefficients.lineCapitalCoef : lineStyle.fontSize;
|
|
14476
14539
|
return total + lineStyle.lineHeight * height;
|
|
14477
14540
|
}, 0);
|
|
14478
|
-
};
|
|
14479
|
-
|
|
14541
|
+
};
|
|
14480
14542
|
|
|
14543
|
+
// Stubbable implementation.
|
|
14481
14544
|
var _approximateTextSizeInternal = {
|
|
14482
14545
|
impl: function (text, style) {
|
|
14483
14546
|
var angle = Array.isArray(style) ? style[0] && style[0].angle : style && style.angle;
|
|
@@ -14496,7 +14559,7 @@ var _approximateTextSizeInternal = {
|
|
|
14496
14559
|
};
|
|
14497
14560
|
/**
|
|
14498
14561
|
* Predict text size by font params.
|
|
14499
|
-
* @param {string} text Content for width calculation.
|
|
14562
|
+
* @param {string|string[]} text Content for width calculation.
|
|
14500
14563
|
* @param {Object} style Text styles, ,fontFamily, fontSize, etc.
|
|
14501
14564
|
* @param {string} style.fontFamily Text fontFamily.
|
|
14502
14565
|
* @param {(number|string)} style.fontSize Text fontSize.
|
|
@@ -14509,6 +14572,7 @@ var _approximateTextSizeInternal = {
|
|
|
14509
14572
|
var approximateTextSize = function (text, style) {
|
|
14510
14573
|
return _approximateTextSizeInternal.impl(text, style);
|
|
14511
14574
|
};
|
|
14575
|
+
//# sourceMappingURL=textsize.js.map
|
|
14512
14576
|
|
|
14513
14577
|
/***/ }),
|
|
14514
14578
|
|
|
@@ -14539,6 +14603,7 @@ var TimerContext = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().cre
|
|
|
14539
14603
|
});
|
|
14540
14604
|
TimerContext.displayName = "TimerContext";
|
|
14541
14605
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (TimerContext);
|
|
14606
|
+
//# sourceMappingURL=timer-context.js.map
|
|
14542
14607
|
|
|
14543
14608
|
/***/ }),
|
|
14544
14609
|
|
|
@@ -14641,6 +14706,7 @@ var Timer = /*#__PURE__*/function () {
|
|
|
14641
14706
|
}();
|
|
14642
14707
|
|
|
14643
14708
|
|
|
14709
|
+
//# sourceMappingURL=timer.js.map
|
|
14644
14710
|
|
|
14645
14711
|
/***/ }),
|
|
14646
14712
|
|
|
@@ -14731,7 +14797,7 @@ function getChildData(child) {
|
|
|
14731
14797
|
}
|
|
14732
14798
|
/**
|
|
14733
14799
|
* If a parent component has animation enabled, calculate the transitions
|
|
14734
|
-
* for any data of any child component that supports data transitions
|
|
14800
|
+
* for any data of any child component that supports data transitions.
|
|
14735
14801
|
* Data transitions are defined as any two datasets where data nodes exist
|
|
14736
14802
|
* in the first set and not the second, in the second and not the first,
|
|
14737
14803
|
* or both.
|
|
@@ -14860,7 +14926,7 @@ function getChildPropsOnExit(animate, child, data, exitingNodes, cb) {
|
|
|
14860
14926
|
|
|
14861
14927
|
if (exitingNodes) {
|
|
14862
14928
|
// After the exit transition occurs, trigger the animations for
|
|
14863
|
-
// nodes that are neither exiting
|
|
14929
|
+
// nodes that are neither exiting nor entering.
|
|
14864
14930
|
animate.onEnd = cb;
|
|
14865
14931
|
var before = animate.onExit && animate.onExit.before ? animate.onExit.before : (lodash_identity__WEBPACK_IMPORTED_MODULE_1___default()); // If nodes need to exit, transform them with the provided onExit.before function.
|
|
14866
14932
|
|
|
@@ -14930,7 +14996,7 @@ function getChildPropsOnEnter(animate, data, enteringNodes, cb) {
|
|
|
14930
14996
|
* and its index in the parent's children array.
|
|
14931
14997
|
*
|
|
14932
14998
|
* In particular, this will include an `animate` object that is set appropriately
|
|
14933
|
-
* so that each child will be
|
|
14999
|
+
* so that each child will be synchronized for each stage of a transition
|
|
14934
15000
|
* animation. It will also include a transformed `data` object, where each datum
|
|
14935
15001
|
* is transformed by `animate.onExit` and `animate.onEnter` `before` and `after`
|
|
14936
15002
|
* functions.
|
|
@@ -15075,6 +15141,7 @@ function getTransitionPropsFactory(props, state, setState) {
|
|
|
15075
15141
|
};
|
|
15076
15142
|
};
|
|
15077
15143
|
}
|
|
15144
|
+
//# sourceMappingURL=transitions.js.map
|
|
15078
15145
|
|
|
15079
15146
|
/***/ }),
|
|
15080
15147
|
|
|
@@ -15113,7 +15180,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
15113
15180
|
|
|
15114
15181
|
/*
|
|
15115
15182
|
USER_PROPS_SAFELIST is to contain any string deemed safe for user props.
|
|
15116
|
-
The startsWidth array will contain the start of any accepted user-prop that
|
|
15183
|
+
The startsWidth array will contain the start of any accepted user-prop that
|
|
15117
15184
|
starts with these characters.
|
|
15118
15185
|
The exactMatch will contain a list of exact prop names that are accepted.
|
|
15119
15186
|
*/
|
|
@@ -15122,6 +15189,7 @@ var USER_PROPS_SAFELIST = {
|
|
|
15122
15189
|
startsWith: ["data-", "aria-"],
|
|
15123
15190
|
exactMatch: []
|
|
15124
15191
|
};
|
|
15192
|
+
|
|
15125
15193
|
/**
|
|
15126
15194
|
* doesPropStartWith: Function that takes a prop's key and runs it against all
|
|
15127
15195
|
* options in the USER_PROPS_SAFELIST and checks to see if it starts with any
|
|
@@ -15130,7 +15198,6 @@ var USER_PROPS_SAFELIST = {
|
|
|
15130
15198
|
* @returns {Boolean}: returns true if the key starts with an option or false if
|
|
15131
15199
|
* otherwise
|
|
15132
15200
|
*/
|
|
15133
|
-
|
|
15134
15201
|
var doesPropStartWith = function (key) {
|
|
15135
15202
|
var startsWith = false;
|
|
15136
15203
|
USER_PROPS_SAFELIST.startsWith.forEach(function (starterString) {
|
|
@@ -15207,14 +15274,15 @@ var getSafeUserProps = function (props) {
|
|
|
15207
15274
|
/**
|
|
15208
15275
|
* Wraps a component and adds safe user props
|
|
15209
15276
|
*
|
|
15210
|
-
* @param {
|
|
15277
|
+
* @param {ReactElement} component: parent component
|
|
15211
15278
|
* @param {Object} props: props to be filtered
|
|
15212
|
-
* @returns {
|
|
15279
|
+
* @returns {ReactElement} modified component
|
|
15213
15280
|
*/
|
|
15214
15281
|
|
|
15215
15282
|
var withSafeUserProps = function (component, props) {
|
|
15216
15283
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.cloneElement(component, getSafeUserProps(props));
|
|
15217
15284
|
};
|
|
15285
|
+
//# sourceMappingURL=user-props.js.map
|
|
15218
15286
|
|
|
15219
15287
|
/***/ }),
|
|
15220
15288
|
|