victory-area 36.9.2-next.3 → 36.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -13
- package/README.md +1 -1
- package/dist/victory-area.js +71 -210
- package/dist/victory-area.min.js +1 -1
- package/es/area.d.ts +12 -12
- package/es/helper-methods.d.ts +2 -2
- package/es/index.d.ts +2 -2
- package/es/victory-area.d.ts +90 -90
- package/lib/area.d.ts +12 -12
- package/lib/helper-methods.d.ts +2 -2
- package/lib/index.d.ts +2 -2
- package/lib/victory-area.d.ts +90 -90
- package/package.json +8 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,21 +1,12 @@
|
|
|
1
1
|
# victory-area
|
|
2
2
|
|
|
3
|
-
## 36.9.2
|
|
3
|
+
## 36.9.2
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
|
-
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
- Updated dependencies [3f2da66e3]
|
|
11
|
-
- Updated dependencies [c13308624]
|
|
12
|
-
- Updated dependencies [65d02419f]
|
|
13
|
-
- Updated dependencies [7efd582cc]
|
|
14
|
-
- Updated dependencies [9cdaf2c08]
|
|
15
|
-
- Updated dependencies [f6f7cc515]
|
|
16
|
-
- Updated dependencies [6e34169a5]
|
|
17
|
-
- victory-core@36.9.2-next.3
|
|
18
|
-
- victory-vendor@36.9.2-next.3
|
|
7
|
+
- Replace lodash isNil and isNan with native code ([#2800](https://github.com/FormidableLabs/victory/pull/2800))
|
|
8
|
+
|
|
9
|
+
* Replace lodash isFunction with native code ([#2802](https://github.com/FormidableLabs/victory/pull/2802))
|
|
19
10
|
|
|
20
11
|
## 36.9.1
|
|
21
12
|
|
package/README.md
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
`victory-area@^30.0.0` exports `VictoryArea` and `Area` components
|
|
4
4
|
|
|
5
|
-
To view documentation for `VictoryArea` please see https://
|
|
5
|
+
To view documentation for `VictoryArea` please see https://commerce.nearform.com/open-source/victory/docs/victory-area
|
|
6
6
|
|
|
7
7
|
To suggest an addition or correction to this documentation please see https://github.com/FormidableLabs/victory/blob/main/docs/src/content/docs/victory-area.md
|
package/dist/victory-area.js
CHANGED
|
@@ -910,83 +910,6 @@ function baseAssignValue(object, key, value) {
|
|
|
910
910
|
module.exports = baseAssignValue;
|
|
911
911
|
|
|
912
912
|
|
|
913
|
-
/***/ }),
|
|
914
|
-
|
|
915
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseDifference.js":
|
|
916
|
-
/*!*****************************************************************************************!*\
|
|
917
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseDifference.js ***!
|
|
918
|
-
\*****************************************************************************************/
|
|
919
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
920
|
-
|
|
921
|
-
var SetCache = __webpack_require__(/*! ./_SetCache */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_SetCache.js"),
|
|
922
|
-
arrayIncludes = __webpack_require__(/*! ./_arrayIncludes */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_arrayIncludes.js"),
|
|
923
|
-
arrayIncludesWith = __webpack_require__(/*! ./_arrayIncludesWith */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_arrayIncludesWith.js"),
|
|
924
|
-
arrayMap = __webpack_require__(/*! ./_arrayMap */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_arrayMap.js"),
|
|
925
|
-
baseUnary = __webpack_require__(/*! ./_baseUnary */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseUnary.js"),
|
|
926
|
-
cacheHas = __webpack_require__(/*! ./_cacheHas */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_cacheHas.js");
|
|
927
|
-
|
|
928
|
-
/** Used as the size to enable large array optimizations. */
|
|
929
|
-
var LARGE_ARRAY_SIZE = 200;
|
|
930
|
-
|
|
931
|
-
/**
|
|
932
|
-
* The base implementation of methods like `_.difference` without support
|
|
933
|
-
* for excluding multiple arrays or iteratee shorthands.
|
|
934
|
-
*
|
|
935
|
-
* @private
|
|
936
|
-
* @param {Array} array The array to inspect.
|
|
937
|
-
* @param {Array} values The values to exclude.
|
|
938
|
-
* @param {Function} [iteratee] The iteratee invoked per element.
|
|
939
|
-
* @param {Function} [comparator] The comparator invoked per element.
|
|
940
|
-
* @returns {Array} Returns the new array of filtered values.
|
|
941
|
-
*/
|
|
942
|
-
function baseDifference(array, values, iteratee, comparator) {
|
|
943
|
-
var index = -1,
|
|
944
|
-
includes = arrayIncludes,
|
|
945
|
-
isCommon = true,
|
|
946
|
-
length = array.length,
|
|
947
|
-
result = [],
|
|
948
|
-
valuesLength = values.length;
|
|
949
|
-
|
|
950
|
-
if (!length) {
|
|
951
|
-
return result;
|
|
952
|
-
}
|
|
953
|
-
if (iteratee) {
|
|
954
|
-
values = arrayMap(values, baseUnary(iteratee));
|
|
955
|
-
}
|
|
956
|
-
if (comparator) {
|
|
957
|
-
includes = arrayIncludesWith;
|
|
958
|
-
isCommon = false;
|
|
959
|
-
}
|
|
960
|
-
else if (values.length >= LARGE_ARRAY_SIZE) {
|
|
961
|
-
includes = cacheHas;
|
|
962
|
-
isCommon = false;
|
|
963
|
-
values = new SetCache(values);
|
|
964
|
-
}
|
|
965
|
-
outer:
|
|
966
|
-
while (++index < length) {
|
|
967
|
-
var value = array[index],
|
|
968
|
-
computed = iteratee == null ? value : iteratee(value);
|
|
969
|
-
|
|
970
|
-
value = (comparator || value !== 0) ? value : 0;
|
|
971
|
-
if (isCommon && computed === computed) {
|
|
972
|
-
var valuesIndex = valuesLength;
|
|
973
|
-
while (valuesIndex--) {
|
|
974
|
-
if (values[valuesIndex] === computed) {
|
|
975
|
-
continue outer;
|
|
976
|
-
}
|
|
977
|
-
}
|
|
978
|
-
result.push(value);
|
|
979
|
-
}
|
|
980
|
-
else if (!includes(values, computed, comparator)) {
|
|
981
|
-
result.push(value);
|
|
982
|
-
}
|
|
983
|
-
}
|
|
984
|
-
return result;
|
|
985
|
-
}
|
|
986
|
-
|
|
987
|
-
module.exports = baseDifference;
|
|
988
|
-
|
|
989
|
-
|
|
990
913
|
/***/ }),
|
|
991
914
|
|
|
992
915
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseFlatten.js":
|
|
@@ -3475,49 +3398,6 @@ var defaults = baseRest(function(object, sources) {
|
|
|
3475
3398
|
module.exports = defaults;
|
|
3476
3399
|
|
|
3477
3400
|
|
|
3478
|
-
/***/ }),
|
|
3479
|
-
|
|
3480
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/difference.js":
|
|
3481
|
-
/*!************************************************************************************!*\
|
|
3482
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/difference.js ***!
|
|
3483
|
-
\************************************************************************************/
|
|
3484
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
3485
|
-
|
|
3486
|
-
var baseDifference = __webpack_require__(/*! ./_baseDifference */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseDifference.js"),
|
|
3487
|
-
baseFlatten = __webpack_require__(/*! ./_baseFlatten */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseFlatten.js"),
|
|
3488
|
-
baseRest = __webpack_require__(/*! ./_baseRest */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseRest.js"),
|
|
3489
|
-
isArrayLikeObject = __webpack_require__(/*! ./isArrayLikeObject */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isArrayLikeObject.js");
|
|
3490
|
-
|
|
3491
|
-
/**
|
|
3492
|
-
* Creates an array of `array` values not included in the other given arrays
|
|
3493
|
-
* using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
|
|
3494
|
-
* for equality comparisons. The order and references of result values are
|
|
3495
|
-
* determined by the first array.
|
|
3496
|
-
*
|
|
3497
|
-
* **Note:** Unlike `_.pullAll`, this method returns a new array.
|
|
3498
|
-
*
|
|
3499
|
-
* @static
|
|
3500
|
-
* @memberOf _
|
|
3501
|
-
* @since 0.1.0
|
|
3502
|
-
* @category Array
|
|
3503
|
-
* @param {Array} array The array to inspect.
|
|
3504
|
-
* @param {...Array} [values] The values to exclude.
|
|
3505
|
-
* @returns {Array} Returns the new array of filtered values.
|
|
3506
|
-
* @see _.without, _.xor
|
|
3507
|
-
* @example
|
|
3508
|
-
*
|
|
3509
|
-
* _.difference([2, 1], [2, 3]);
|
|
3510
|
-
* // => [1]
|
|
3511
|
-
*/
|
|
3512
|
-
var difference = baseRest(function(array, values) {
|
|
3513
|
-
return isArrayLikeObject(array)
|
|
3514
|
-
? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true))
|
|
3515
|
-
: [];
|
|
3516
|
-
});
|
|
3517
|
-
|
|
3518
|
-
module.exports = difference;
|
|
3519
|
-
|
|
3520
|
-
|
|
3521
3401
|
/***/ }),
|
|
3522
3402
|
|
|
3523
3403
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/eq.js":
|
|
@@ -3822,49 +3702,6 @@ function isArrayLike(value) {
|
|
|
3822
3702
|
module.exports = isArrayLike;
|
|
3823
3703
|
|
|
3824
3704
|
|
|
3825
|
-
/***/ }),
|
|
3826
|
-
|
|
3827
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isArrayLikeObject.js":
|
|
3828
|
-
/*!*******************************************************************************************!*\
|
|
3829
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isArrayLikeObject.js ***!
|
|
3830
|
-
\*******************************************************************************************/
|
|
3831
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
3832
|
-
|
|
3833
|
-
var isArrayLike = __webpack_require__(/*! ./isArrayLike */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isArrayLike.js"),
|
|
3834
|
-
isObjectLike = __webpack_require__(/*! ./isObjectLike */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObjectLike.js");
|
|
3835
|
-
|
|
3836
|
-
/**
|
|
3837
|
-
* This method is like `_.isArrayLike` except that it also checks if `value`
|
|
3838
|
-
* is an object.
|
|
3839
|
-
*
|
|
3840
|
-
* @static
|
|
3841
|
-
* @memberOf _
|
|
3842
|
-
* @since 4.0.0
|
|
3843
|
-
* @category Lang
|
|
3844
|
-
* @param {*} value The value to check.
|
|
3845
|
-
* @returns {boolean} Returns `true` if `value` is an array-like object,
|
|
3846
|
-
* else `false`.
|
|
3847
|
-
* @example
|
|
3848
|
-
*
|
|
3849
|
-
* _.isArrayLikeObject([1, 2, 3]);
|
|
3850
|
-
* // => true
|
|
3851
|
-
*
|
|
3852
|
-
* _.isArrayLikeObject(document.body.children);
|
|
3853
|
-
* // => true
|
|
3854
|
-
*
|
|
3855
|
-
* _.isArrayLikeObject('abc');
|
|
3856
|
-
* // => false
|
|
3857
|
-
*
|
|
3858
|
-
* _.isArrayLikeObject(_.noop);
|
|
3859
|
-
* // => false
|
|
3860
|
-
*/
|
|
3861
|
-
function isArrayLikeObject(value) {
|
|
3862
|
-
return isObjectLike(value) && isArrayLike(value);
|
|
3863
|
-
}
|
|
3864
|
-
|
|
3865
|
-
module.exports = isArrayLikeObject;
|
|
3866
|
-
|
|
3867
|
-
|
|
3868
3705
|
/***/ }),
|
|
3869
3706
|
|
|
3870
3707
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isBuffer.js":
|
|
@@ -8019,18 +7856,16 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8019
7856
|
/* harmony import */ var lodash_pick__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_pick__WEBPACK_IMPORTED_MODULE_0__);
|
|
8020
7857
|
/* harmony import */ var lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash/isEmpty */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isEmpty.js");
|
|
8021
7858
|
/* harmony import */ var lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1__);
|
|
8022
|
-
/* harmony import */ var
|
|
8023
|
-
/* harmony import */ var
|
|
8024
|
-
/* harmony import */ var
|
|
8025
|
-
/* harmony import */ var
|
|
8026
|
-
/* harmony import */ var
|
|
8027
|
-
/* harmony import */ var
|
|
8028
|
-
/* harmony import */ var _events__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./events */ "../../victory-core/es/victory-util/events.js");
|
|
8029
|
-
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react-fast-compare */ "../../../node_modules/.pnpm/react-fast-compare@3.2.0/node_modules/react-fast-compare/index.js");
|
|
8030
|
-
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_fast_compare__WEBPACK_IMPORTED_MODULE_5__);
|
|
7859
|
+
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! lodash/defaults */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/defaults.js");
|
|
7860
|
+
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_2__);
|
|
7861
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react */ "react");
|
|
7862
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_3__);
|
|
7863
|
+
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react-fast-compare */ "../../../node_modules/.pnpm/react-fast-compare@3.2.0/node_modules/react-fast-compare/index.js");
|
|
7864
|
+
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_fast_compare__WEBPACK_IMPORTED_MODULE_4__);
|
|
8031
7865
|
/* harmony import */ var _victory_transition_victory_transition__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../victory-transition/victory-transition */ "../../victory-core/es/victory-transition/victory-transition.js");
|
|
8032
|
-
/* harmony import */ var
|
|
8033
|
-
|
|
7866
|
+
/* harmony import */ var _collection__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./collection */ "../../victory-core/es/victory-util/collection.js");
|
|
7867
|
+
/* harmony import */ var _events__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./events */ "../../victory-core/es/victory-util/events.js");
|
|
7868
|
+
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./helpers */ "../../victory-core/es/victory-util/helpers.js");
|
|
8034
7869
|
|
|
8035
7870
|
|
|
8036
7871
|
|
|
@@ -8071,13 +7906,14 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
|
|
|
8071
7906
|
|
|
8072
7907
|
|
|
8073
7908
|
|
|
7909
|
+
|
|
8074
7910
|
// DISCLAIMER:
|
|
8075
7911
|
// This file is not currently tested, and it is first on the list of files
|
|
8076
7912
|
// to refactor in our current refactoring effort. Please do not make changes
|
|
8077
7913
|
// to this file without manual testing and/or refactoring and adding tests.
|
|
8078
7914
|
|
|
8079
7915
|
var datumHasXandY = function (datum) {
|
|
8080
|
-
return !(0,
|
|
7916
|
+
return !(0,_helpers__WEBPACK_IMPORTED_MODULE_5__.isNil)(datum._x) && !(0,_helpers__WEBPACK_IMPORTED_MODULE_5__.isNil)(datum._y);
|
|
8081
7917
|
}; // used for checking state changes. Expected components can be passed in via options
|
|
8082
7918
|
|
|
8083
7919
|
|
|
@@ -8105,11 +7941,11 @@ function addEvents(WrappedComponent) {
|
|
|
8105
7941
|
|
|
8106
7942
|
_this = _super.call(this, props);
|
|
8107
7943
|
_this.state = {};
|
|
8108
|
-
_this.getEventState =
|
|
8109
|
-
_this.getScopedEvents =
|
|
7944
|
+
_this.getEventState = _events__WEBPACK_IMPORTED_MODULE_6__.getEventState.bind(_assertThisInitialized(_this));
|
|
7945
|
+
_this.getScopedEvents = _events__WEBPACK_IMPORTED_MODULE_6__.getScopedEvents.bind(_assertThisInitialized(_this));
|
|
8110
7946
|
|
|
8111
7947
|
_this.getEvents = function (p, target, eventKey) {
|
|
8112
|
-
return
|
|
7948
|
+
return _events__WEBPACK_IMPORTED_MODULE_6__.getEvents.call(_assertThisInitialized(_this), p, target, eventKey, _this.getScopedEvents);
|
|
8113
7949
|
};
|
|
8114
7950
|
|
|
8115
7951
|
_this.externalMutations = _this.getExternalMutations(_this.props);
|
|
@@ -8129,7 +7965,7 @@ function addEvents(WrappedComponent) {
|
|
|
8129
7965
|
var externalMutations = this.getExternalMutations(nextProps); // @ts-expect-error "Property 'animating' does not exist on type EventMixinCommonProps"
|
|
8130
7966
|
|
|
8131
7967
|
var animating = this.props.animating || this.props.animate;
|
|
8132
|
-
var newMutation = !
|
|
7968
|
+
var newMutation = !react_fast_compare__WEBPACK_IMPORTED_MODULE_4___default()(externalMutations, this.externalMutations);
|
|
8133
7969
|
|
|
8134
7970
|
if (animating || newMutation) {
|
|
8135
7971
|
this.cacheValues(this.getCalculatedValues(nextProps));
|
|
@@ -8140,12 +7976,12 @@ function addEvents(WrappedComponent) {
|
|
|
8140
7976
|
|
|
8141
7977
|
var calculatedState = this.getStateChanges(nextProps);
|
|
8142
7978
|
|
|
8143
|
-
if (!
|
|
7979
|
+
if (!react_fast_compare__WEBPACK_IMPORTED_MODULE_4___default()(this.calculatedState, calculatedState)) {
|
|
8144
7980
|
this.cacheValues(this.getCalculatedValues(nextProps));
|
|
8145
7981
|
return true;
|
|
8146
7982
|
}
|
|
8147
7983
|
|
|
8148
|
-
if (!
|
|
7984
|
+
if (!react_fast_compare__WEBPACK_IMPORTED_MODULE_4___default()(this.props, nextProps)) {
|
|
8149
7985
|
this.cacheValues(this.getCalculatedValues(nextProps));
|
|
8150
7986
|
return true;
|
|
8151
7987
|
}
|
|
@@ -8171,15 +8007,11 @@ function addEvents(WrappedComponent) {
|
|
|
8171
8007
|
var calculatedState = this.getStateChanges(prevProps);
|
|
8172
8008
|
this.calculatedState = calculatedState;
|
|
8173
8009
|
var globalEventKeys = Object.keys(this.globalEvents);
|
|
8174
|
-
|
|
8175
|
-
var removedGlobalEventKeys = lodash_difference__WEBPACK_IMPORTED_MODULE_2___default()(this.prevGlobalEventKeys, globalEventKeys);
|
|
8176
|
-
|
|
8010
|
+
var removedGlobalEventKeys = (0,_collection__WEBPACK_IMPORTED_MODULE_7__.difference)(this.prevGlobalEventKeys, globalEventKeys);
|
|
8177
8011
|
removedGlobalEventKeys.forEach(function (key) {
|
|
8178
8012
|
return _this3.removeGlobalListener(key);
|
|
8179
8013
|
});
|
|
8180
|
-
|
|
8181
|
-
var addedGlobalEventKeys = lodash_difference__WEBPACK_IMPORTED_MODULE_2___default()(globalEventKeys, this.prevGlobalEventKeys);
|
|
8182
|
-
|
|
8014
|
+
var addedGlobalEventKeys = (0,_collection__WEBPACK_IMPORTED_MODULE_7__.difference)(globalEventKeys, this.prevGlobalEventKeys);
|
|
8183
8015
|
addedGlobalEventKeys.forEach(function (key) {
|
|
8184
8016
|
return _this3.addGlobalListener(key);
|
|
8185
8017
|
});
|
|
@@ -8201,16 +8033,16 @@ function addEvents(WrappedComponent) {
|
|
|
8201
8033
|
|
|
8202
8034
|
var boundListener = function (event) {
|
|
8203
8035
|
var listener = _this5.globalEvents[key];
|
|
8204
|
-
return listener && listener(
|
|
8036
|
+
return listener && listener(_events__WEBPACK_IMPORTED_MODULE_6__.emulateReactEvent(event));
|
|
8205
8037
|
};
|
|
8206
8038
|
|
|
8207
8039
|
this.boundGlobalEvents[key] = boundListener;
|
|
8208
|
-
window.addEventListener(
|
|
8040
|
+
window.addEventListener(_events__WEBPACK_IMPORTED_MODULE_6__.getGlobalEventNameFromKey(key), boundListener);
|
|
8209
8041
|
}
|
|
8210
8042
|
}, {
|
|
8211
8043
|
key: "removeGlobalListener",
|
|
8212
8044
|
value: function removeGlobalListener(key) {
|
|
8213
|
-
window.removeEventListener(
|
|
8045
|
+
window.removeEventListener(_events__WEBPACK_IMPORTED_MODULE_6__.getGlobalEventNameFromKey(key), this.boundGlobalEvents[key]);
|
|
8214
8046
|
} // compile all state changes from own and parent state. Order doesn't matter, as any state
|
|
8215
8047
|
// state change should trigger a re-render
|
|
8216
8048
|
|
|
@@ -8224,7 +8056,7 @@ function addEvents(WrappedComponent) {
|
|
|
8224
8056
|
}
|
|
8225
8057
|
|
|
8226
8058
|
var getState = function (key, type) {
|
|
8227
|
-
var result =
|
|
8059
|
+
var result = lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({}, _this6.getEventState(key, type), _this6.getSharedEventState(key, type));
|
|
8228
8060
|
|
|
8229
8061
|
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default()(result) ? undefined : result;
|
|
8230
8062
|
};
|
|
@@ -8247,7 +8079,7 @@ function addEvents(WrappedComponent) {
|
|
|
8247
8079
|
value: function applyExternalMutations(props, externalMutations) {
|
|
8248
8080
|
if (!lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default()(externalMutations)) {
|
|
8249
8081
|
var callbacks = props.externalEventMutations.reduce(function (memo, mutation) {
|
|
8250
|
-
return (0,
|
|
8082
|
+
return (0,_helpers__WEBPACK_IMPORTED_MODULE_5__.isFunction)(mutation.callback) ? memo.concat(mutation.callback) : memo;
|
|
8251
8083
|
}, []);
|
|
8252
8084
|
var compiledCallbacks = callbacks.length ? function () {
|
|
8253
8085
|
callbacks.forEach(function (c) {
|
|
@@ -8262,8 +8094,8 @@ function addEvents(WrappedComponent) {
|
|
|
8262
8094
|
value: function getCalculatedValues(props) {
|
|
8263
8095
|
var sharedEvents = props.sharedEvents;
|
|
8264
8096
|
var components = WrappedComponent.expectedComponents;
|
|
8265
|
-
var componentEvents =
|
|
8266
|
-
var getSharedEventState = sharedEvents && (0,
|
|
8097
|
+
var componentEvents = _events__WEBPACK_IMPORTED_MODULE_6__.getComponentEvents(props, components);
|
|
8098
|
+
var getSharedEventState = sharedEvents && (0,_helpers__WEBPACK_IMPORTED_MODULE_5__.isFunction)(sharedEvents.getEventState) ? sharedEvents.getEventState : function () {
|
|
8267
8099
|
return undefined;
|
|
8268
8100
|
};
|
|
8269
8101
|
var baseProps = this.getBaseProps(props, getSharedEventState);
|
|
@@ -8286,7 +8118,7 @@ function addEvents(WrappedComponent) {
|
|
|
8286
8118
|
value: function getExternalMutations(props) {
|
|
8287
8119
|
var sharedEvents = props.sharedEvents,
|
|
8288
8120
|
externalEventMutations = props.externalEventMutations;
|
|
8289
|
-
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default()(externalEventMutations) || sharedEvents ? undefined :
|
|
8121
|
+
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default()(externalEventMutations) || sharedEvents ? undefined : _events__WEBPACK_IMPORTED_MODULE_6__.getExternalMutations(externalEventMutations, this.baseProps, this.state);
|
|
8290
8122
|
}
|
|
8291
8123
|
}, {
|
|
8292
8124
|
key: "cacheValues",
|
|
@@ -8304,12 +8136,12 @@ function addEvents(WrappedComponent) {
|
|
|
8304
8136
|
var sharedParentState = getSharedEventStateFunction("parent", "parent");
|
|
8305
8137
|
var parentState = this.getEventState("parent", "parent");
|
|
8306
8138
|
|
|
8307
|
-
var baseParentProps =
|
|
8139
|
+
var baseParentProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({}, parentState, sharedParentState);
|
|
8308
8140
|
|
|
8309
8141
|
var parentPropsList = baseParentProps.parentControlledProps;
|
|
8310
8142
|
var parentProps = parentPropsList ? lodash_pick__WEBPACK_IMPORTED_MODULE_0___default()(baseParentProps, parentPropsList) : {};
|
|
8311
8143
|
|
|
8312
|
-
var modifiedProps =
|
|
8144
|
+
var modifiedProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({}, parentProps, props);
|
|
8313
8145
|
|
|
8314
8146
|
return typeof WrappedComponent.getBaseProps === "function" ? WrappedComponent.getBaseProps(modifiedProps) : {};
|
|
8315
8147
|
}
|
|
@@ -8341,21 +8173,21 @@ function addEvents(WrappedComponent) {
|
|
|
8341
8173
|
if (this.hasEvents) {
|
|
8342
8174
|
var baseEvents = this.getEvents(this.props, type, key);
|
|
8343
8175
|
|
|
8344
|
-
var componentProps =
|
|
8176
|
+
var componentProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({
|
|
8345
8177
|
index: index,
|
|
8346
8178
|
key: id
|
|
8347
8179
|
}, this.getEventState(key, type), this.getSharedEventState(key, type), currentProps, baseProps, {
|
|
8348
8180
|
id: id
|
|
8349
8181
|
});
|
|
8350
8182
|
|
|
8351
|
-
var events =
|
|
8183
|
+
var events = lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({}, _events__WEBPACK_IMPORTED_MODULE_6__.getPartialEvents(baseEvents, key, componentProps), componentProps.events);
|
|
8352
8184
|
|
|
8353
8185
|
return Object.assign({}, componentProps, {
|
|
8354
8186
|
events: events
|
|
8355
8187
|
});
|
|
8356
8188
|
}
|
|
8357
8189
|
|
|
8358
|
-
return
|
|
8190
|
+
return lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({
|
|
8359
8191
|
index: index,
|
|
8360
8192
|
key: id
|
|
8361
8193
|
}, currentProps, baseProps, {
|
|
@@ -8369,11 +8201,11 @@ function addEvents(WrappedComponent) {
|
|
|
8369
8201
|
var parentProps = isContainer ? this.getComponentProps(component, "parent", "parent") : {};
|
|
8370
8202
|
|
|
8371
8203
|
if (parentProps.events) {
|
|
8372
|
-
this.globalEvents =
|
|
8373
|
-
parentProps.events =
|
|
8204
|
+
this.globalEvents = _events__WEBPACK_IMPORTED_MODULE_6__.getGlobalEvents(parentProps.events);
|
|
8205
|
+
parentProps.events = _events__WEBPACK_IMPORTED_MODULE_6__.omitGlobalEvents(parentProps.events);
|
|
8374
8206
|
}
|
|
8375
8207
|
|
|
8376
|
-
return /*#__PURE__*/
|
|
8208
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(component, parentProps, children);
|
|
8377
8209
|
}
|
|
8378
8210
|
}, {
|
|
8379
8211
|
key: "animateComponent",
|
|
@@ -8382,10 +8214,10 @@ function addEvents(WrappedComponent) {
|
|
|
8382
8214
|
|
|
8383
8215
|
var animationWhitelist = typeof props.animate === "object" && ((_props$animate = props.animate) === null || _props$animate === void 0 ? void 0 : _props$animate.animationWhitelist) || defaultAnimationWhitelist;
|
|
8384
8216
|
var Comp = this.constructor;
|
|
8385
|
-
return /*#__PURE__*/
|
|
8217
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement(_victory_transition_victory_transition__WEBPACK_IMPORTED_MODULE_8__.VictoryTransition, {
|
|
8386
8218
|
animate: props.animate,
|
|
8387
8219
|
animationWhitelist: animationWhitelist
|
|
8388
|
-
}, /*#__PURE__*/
|
|
8220
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement(Comp, props));
|
|
8389
8221
|
} // Used by `VictoryLine` and `VictoryArea`
|
|
8390
8222
|
|
|
8391
8223
|
}, {
|
|
@@ -8405,13 +8237,13 @@ function addEvents(WrappedComponent) {
|
|
|
8405
8237
|
var labelProps = _this8.getComponentProps(labelComponent, "labels", key);
|
|
8406
8238
|
|
|
8407
8239
|
if (labelProps && labelProps.text !== undefined && labelProps.text !== null) {
|
|
8408
|
-
newMemo = newMemo.concat( /*#__PURE__*/
|
|
8240
|
+
newMemo = newMemo.concat( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(labelComponent, labelProps));
|
|
8409
8241
|
}
|
|
8410
8242
|
|
|
8411
8243
|
return newMemo;
|
|
8412
8244
|
}, []);
|
|
8413
8245
|
var dataProps = this.getComponentProps(dataComponent, "data", "all");
|
|
8414
|
-
var children = [/*#__PURE__*/
|
|
8246
|
+
var children = [/*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(dataComponent, dataProps)].concat(_toConsumableArray(labelComponents));
|
|
8415
8247
|
return this.renderContainer(groupComponent, children);
|
|
8416
8248
|
}
|
|
8417
8249
|
}, {
|
|
@@ -8427,7 +8259,7 @@ function addEvents(WrappedComponent) {
|
|
|
8427
8259
|
var dataProps = _this9.getComponentProps(dataComponent, "data", index);
|
|
8428
8260
|
|
|
8429
8261
|
if (shouldRenderDatum(dataProps.datum)) {
|
|
8430
|
-
validDataComponents.push( /*#__PURE__*/
|
|
8262
|
+
validDataComponents.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(dataComponent, dataProps));
|
|
8431
8263
|
}
|
|
8432
8264
|
|
|
8433
8265
|
return validDataComponents;
|
|
@@ -8436,7 +8268,7 @@ function addEvents(WrappedComponent) {
|
|
|
8436
8268
|
var labelProps = _this9.getComponentProps(labelComponent, "labels", index);
|
|
8437
8269
|
|
|
8438
8270
|
if (labelProps.text !== undefined && labelProps.text !== null) {
|
|
8439
|
-
return /*#__PURE__*/
|
|
8271
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(labelComponent, labelProps);
|
|
8440
8272
|
}
|
|
8441
8273
|
|
|
8442
8274
|
return undefined;
|
|
@@ -8467,6 +8299,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8467
8299
|
/* harmony export */ "containsNumbers": () => (/* binding */ containsNumbers),
|
|
8468
8300
|
/* harmony export */ "containsOnlyStrings": () => (/* binding */ containsOnlyStrings),
|
|
8469
8301
|
/* harmony export */ "containsStrings": () => (/* binding */ containsStrings),
|
|
8302
|
+
/* harmony export */ "difference": () => (/* binding */ difference),
|
|
8470
8303
|
/* harmony export */ "getMaxValue": () => (/* binding */ getMaxValue),
|
|
8471
8304
|
/* harmony export */ "getMinValue": () => (/* binding */ getMinValue),
|
|
8472
8305
|
/* harmony export */ "isArrayOfArrays": () => (/* binding */ isArrayOfArrays),
|
|
@@ -8508,6 +8341,22 @@ function containsOnlyStrings(collection) {
|
|
|
8508
8341
|
return typeof value === "string";
|
|
8509
8342
|
});
|
|
8510
8343
|
}
|
|
8344
|
+
/**
|
|
8345
|
+
* Creates an array of array values not included in the other given arrays
|
|
8346
|
+
* @param a The array to inspect
|
|
8347
|
+
* @param b The values to exclude
|
|
8348
|
+
* @returns The new array of filtered values
|
|
8349
|
+
*/
|
|
8350
|
+
|
|
8351
|
+
function difference(a, b) {
|
|
8352
|
+
if (a && b) {
|
|
8353
|
+
return a.filter(function (value) {
|
|
8354
|
+
return !b.includes(value);
|
|
8355
|
+
});
|
|
8356
|
+
}
|
|
8357
|
+
|
|
8358
|
+
return [];
|
|
8359
|
+
}
|
|
8511
8360
|
function isArrayOfArrays(collection) {
|
|
8512
8361
|
return isNonEmptyArray(collection) && collection.every(Array.isArray);
|
|
8513
8362
|
}
|
|
@@ -10117,6 +9966,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
10117
9966
|
/* harmony export */ "getRadius": () => (/* binding */ getRadius),
|
|
10118
9967
|
/* harmony export */ "getRange": () => (/* binding */ getRange),
|
|
10119
9968
|
/* harmony export */ "getStyles": () => (/* binding */ getStyles),
|
|
9969
|
+
/* harmony export */ "invert": () => (/* binding */ invert),
|
|
10120
9970
|
/* harmony export */ "isFunction": () => (/* binding */ isFunction),
|
|
10121
9971
|
/* harmony export */ "isHorizontal": () => (/* binding */ isHorizontal),
|
|
10122
9972
|
/* harmony export */ "isNil": () => (/* binding */ isNil),
|
|
@@ -10167,6 +10017,18 @@ function getPolarRange(props, axis) {
|
|
|
10167
10017
|
return [props.innerRadius || 0, getRadius(props)];
|
|
10168
10018
|
} // Exported Functions
|
|
10169
10019
|
|
|
10020
|
+
/**
|
|
10021
|
+
* Creates an object composed of the inverted keys and values of object.
|
|
10022
|
+
* If object contains duplicate values, subsequent values overwrite property assignments of previous values.
|
|
10023
|
+
*/
|
|
10024
|
+
|
|
10025
|
+
|
|
10026
|
+
function invert(original) {
|
|
10027
|
+
return Object.entries(original).reduce(function (acc, current) {
|
|
10028
|
+
acc[current[1]] = current[0];
|
|
10029
|
+
return acc;
|
|
10030
|
+
}, {});
|
|
10031
|
+
}
|
|
10170
10032
|
/**
|
|
10171
10033
|
* creates an object with some keys excluded
|
|
10172
10034
|
* replacement for lodash.omit for performance. does not mimic the entire lodash.omit api
|
|
@@ -10175,7 +10037,6 @@ function getPolarRange(props, axis) {
|
|
|
10175
10037
|
* @returns {Object} new object with same properties as originalObject
|
|
10176
10038
|
*/
|
|
10177
10039
|
|
|
10178
|
-
|
|
10179
10040
|
function omit(originalObject) {
|
|
10180
10041
|
var ks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
10181
10042
|
// code based on babel's _objectWithoutProperties
|