victory 37.0.2 → 37.1.0
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 +8 -0
- package/dist/victory.js +1245 -1432
- package/dist/victory.min.js +1 -1
- package/package.json +28 -28
package/dist/victory.js
CHANGED
|
@@ -1995,33 +1995,6 @@ function serializer(replacer, cycleReplacer) {
|
|
|
1995
1995
|
}
|
|
1996
1996
|
|
|
1997
1997
|
|
|
1998
|
-
/***/ }),
|
|
1999
|
-
|
|
2000
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_LodashWrapper.js":
|
|
2001
|
-
/*!****************************************************************************************!*\
|
|
2002
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_LodashWrapper.js ***!
|
|
2003
|
-
\****************************************************************************************/
|
|
2004
|
-
/***/ (function(module) {
|
|
2005
|
-
|
|
2006
|
-
/**
|
|
2007
|
-
* This method returns `undefined`.
|
|
2008
|
-
*
|
|
2009
|
-
* @static
|
|
2010
|
-
* @memberOf _
|
|
2011
|
-
* @since 2.3.0
|
|
2012
|
-
* @category Util
|
|
2013
|
-
* @example
|
|
2014
|
-
*
|
|
2015
|
-
* _.times(2, _.noop);
|
|
2016
|
-
* // => [undefined, undefined]
|
|
2017
|
-
*/
|
|
2018
|
-
function noop() {
|
|
2019
|
-
// No operation performed.
|
|
2020
|
-
}
|
|
2021
|
-
|
|
2022
|
-
module.exports = noop;
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
1998
|
/***/ }),
|
|
2026
1999
|
|
|
2027
2000
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_MapCache.js":
|
|
@@ -4147,94 +4120,6 @@ function createBaseFor(fromRight) {
|
|
|
4147
4120
|
module.exports = createBaseFor;
|
|
4148
4121
|
|
|
4149
4122
|
|
|
4150
|
-
/***/ }),
|
|
4151
|
-
|
|
4152
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_createFlow.js":
|
|
4153
|
-
/*!*************************************************************************************!*\
|
|
4154
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_createFlow.js ***!
|
|
4155
|
-
\*************************************************************************************/
|
|
4156
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
4157
|
-
|
|
4158
|
-
var LodashWrapper = __webpack_require__(/*! ./_LodashWrapper */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_LodashWrapper.js"),
|
|
4159
|
-
flatRest = __webpack_require__(/*! ./_flatRest */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_flatRest.js"),
|
|
4160
|
-
getData = __webpack_require__(/*! ./_getData */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getData.js"),
|
|
4161
|
-
getFuncName = __webpack_require__(/*! ./_getFuncName */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getFuncName.js"),
|
|
4162
|
-
isArray = __webpack_require__(/*! ./isArray */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isArray.js"),
|
|
4163
|
-
isLaziable = __webpack_require__(/*! ./_isLaziable */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_isLaziable.js");
|
|
4164
|
-
|
|
4165
|
-
/** Error message constants. */
|
|
4166
|
-
var FUNC_ERROR_TEXT = 'Expected a function';
|
|
4167
|
-
|
|
4168
|
-
/** Used to compose bitmasks for function metadata. */
|
|
4169
|
-
var WRAP_CURRY_FLAG = 8,
|
|
4170
|
-
WRAP_PARTIAL_FLAG = 32,
|
|
4171
|
-
WRAP_ARY_FLAG = 128,
|
|
4172
|
-
WRAP_REARG_FLAG = 256;
|
|
4173
|
-
|
|
4174
|
-
/**
|
|
4175
|
-
* Creates a `_.flow` or `_.flowRight` function.
|
|
4176
|
-
*
|
|
4177
|
-
* @private
|
|
4178
|
-
* @param {boolean} [fromRight] Specify iterating from right to left.
|
|
4179
|
-
* @returns {Function} Returns the new flow function.
|
|
4180
|
-
*/
|
|
4181
|
-
function createFlow(fromRight) {
|
|
4182
|
-
return flatRest(function(funcs) {
|
|
4183
|
-
var length = funcs.length,
|
|
4184
|
-
index = length,
|
|
4185
|
-
prereq = LodashWrapper.prototype.thru;
|
|
4186
|
-
|
|
4187
|
-
if (fromRight) {
|
|
4188
|
-
funcs.reverse();
|
|
4189
|
-
}
|
|
4190
|
-
while (index--) {
|
|
4191
|
-
var func = funcs[index];
|
|
4192
|
-
if (typeof func != 'function') {
|
|
4193
|
-
throw new TypeError(FUNC_ERROR_TEXT);
|
|
4194
|
-
}
|
|
4195
|
-
if (prereq && !wrapper && getFuncName(func) == 'wrapper') {
|
|
4196
|
-
var wrapper = new LodashWrapper([], true);
|
|
4197
|
-
}
|
|
4198
|
-
}
|
|
4199
|
-
index = wrapper ? index : length;
|
|
4200
|
-
while (++index < length) {
|
|
4201
|
-
func = funcs[index];
|
|
4202
|
-
|
|
4203
|
-
var funcName = getFuncName(func),
|
|
4204
|
-
data = funcName == 'wrapper' ? getData(func) : undefined;
|
|
4205
|
-
|
|
4206
|
-
if (data && isLaziable(data[0]) &&
|
|
4207
|
-
data[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) &&
|
|
4208
|
-
!data[4].length && data[9] == 1
|
|
4209
|
-
) {
|
|
4210
|
-
wrapper = wrapper[getFuncName(data[0])].apply(wrapper, data[3]);
|
|
4211
|
-
} else {
|
|
4212
|
-
wrapper = (func.length == 1 && isLaziable(func))
|
|
4213
|
-
? wrapper[funcName]()
|
|
4214
|
-
: wrapper.thru(func);
|
|
4215
|
-
}
|
|
4216
|
-
}
|
|
4217
|
-
return function() {
|
|
4218
|
-
var args = arguments,
|
|
4219
|
-
value = args[0];
|
|
4220
|
-
|
|
4221
|
-
if (wrapper && args.length == 1 && isArray(value)) {
|
|
4222
|
-
return wrapper.plant(value).value();
|
|
4223
|
-
}
|
|
4224
|
-
var index = 0,
|
|
4225
|
-
result = length ? funcs[index].apply(this, args) : value;
|
|
4226
|
-
|
|
4227
|
-
while (++index < length) {
|
|
4228
|
-
result = funcs[index].call(this, result);
|
|
4229
|
-
}
|
|
4230
|
-
return result;
|
|
4231
|
-
};
|
|
4232
|
-
});
|
|
4233
|
-
}
|
|
4234
|
-
|
|
4235
|
-
module.exports = createFlow;
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
4123
|
/***/ }),
|
|
4239
4124
|
|
|
4240
4125
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_createRange.js":
|
|
@@ -4690,61 +4575,6 @@ function nativeKeysIn(object) {
|
|
|
4690
4575
|
module.exports = nativeKeysIn;
|
|
4691
4576
|
|
|
4692
4577
|
|
|
4693
|
-
/***/ }),
|
|
4694
|
-
|
|
4695
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getData.js":
|
|
4696
|
-
/*!**********************************************************************************!*\
|
|
4697
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getData.js ***!
|
|
4698
|
-
\**********************************************************************************/
|
|
4699
|
-
/***/ (function(module) {
|
|
4700
|
-
|
|
4701
|
-
/**
|
|
4702
|
-
* This method returns `undefined`.
|
|
4703
|
-
*
|
|
4704
|
-
* @static
|
|
4705
|
-
* @memberOf _
|
|
4706
|
-
* @since 2.3.0
|
|
4707
|
-
* @category Util
|
|
4708
|
-
* @example
|
|
4709
|
-
*
|
|
4710
|
-
* _.times(2, _.noop);
|
|
4711
|
-
* // => [undefined, undefined]
|
|
4712
|
-
*/
|
|
4713
|
-
function noop() {
|
|
4714
|
-
// No operation performed.
|
|
4715
|
-
}
|
|
4716
|
-
|
|
4717
|
-
module.exports = noop;
|
|
4718
|
-
|
|
4719
|
-
|
|
4720
|
-
/***/ }),
|
|
4721
|
-
|
|
4722
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getFuncName.js":
|
|
4723
|
-
/*!**************************************************************************************!*\
|
|
4724
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getFuncName.js ***!
|
|
4725
|
-
\**************************************************************************************/
|
|
4726
|
-
/***/ (function(module) {
|
|
4727
|
-
|
|
4728
|
-
/**
|
|
4729
|
-
* This method returns an empty string.
|
|
4730
|
-
*
|
|
4731
|
-
* @static
|
|
4732
|
-
* @memberOf _
|
|
4733
|
-
* @since 4.13.0
|
|
4734
|
-
* @category Util
|
|
4735
|
-
* @returns {string} Returns the empty string.
|
|
4736
|
-
* @example
|
|
4737
|
-
*
|
|
4738
|
-
* _.times(2, _.stubString);
|
|
4739
|
-
* // => ['', '']
|
|
4740
|
-
*/
|
|
4741
|
-
function stubString() {
|
|
4742
|
-
return '';
|
|
4743
|
-
}
|
|
4744
|
-
|
|
4745
|
-
module.exports = stubString;
|
|
4746
|
-
|
|
4747
|
-
|
|
4748
4578
|
/***/ }),
|
|
4749
4579
|
|
|
4750
4580
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getMatchData.js":
|
|
@@ -5031,34 +4861,6 @@ function isKey(value, object) {
|
|
|
5031
4861
|
module.exports = isKey;
|
|
5032
4862
|
|
|
5033
4863
|
|
|
5034
|
-
/***/ }),
|
|
5035
|
-
|
|
5036
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_isLaziable.js":
|
|
5037
|
-
/*!*************************************************************************************!*\
|
|
5038
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_isLaziable.js ***!
|
|
5039
|
-
\*************************************************************************************/
|
|
5040
|
-
/***/ (function(module) {
|
|
5041
|
-
|
|
5042
|
-
/**
|
|
5043
|
-
* This method returns `false`.
|
|
5044
|
-
*
|
|
5045
|
-
* @static
|
|
5046
|
-
* @memberOf _
|
|
5047
|
-
* @since 4.13.0
|
|
5048
|
-
* @category Util
|
|
5049
|
-
* @returns {boolean} Returns `false`.
|
|
5050
|
-
* @example
|
|
5051
|
-
*
|
|
5052
|
-
* _.times(2, _.stubFalse);
|
|
5053
|
-
* // => [false, false]
|
|
5054
|
-
*/
|
|
5055
|
-
function stubFalse() {
|
|
5056
|
-
return false;
|
|
5057
|
-
}
|
|
5058
|
-
|
|
5059
|
-
module.exports = stubFalse;
|
|
5060
|
-
|
|
5061
|
-
|
|
5062
4864
|
/***/ }),
|
|
5063
4865
|
|
|
5064
4866
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_isPrototype.js":
|
|
@@ -6150,43 +5952,6 @@ function flatten(array) {
|
|
|
6150
5952
|
module.exports = flatten;
|
|
6151
5953
|
|
|
6152
5954
|
|
|
6153
|
-
/***/ }),
|
|
6154
|
-
|
|
6155
|
-
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/flow.js":
|
|
6156
|
-
/*!******************************************************************************!*\
|
|
6157
|
-
!*** ../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/flow.js ***!
|
|
6158
|
-
\******************************************************************************/
|
|
6159
|
-
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
6160
|
-
|
|
6161
|
-
var createFlow = __webpack_require__(/*! ./_createFlow */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_createFlow.js");
|
|
6162
|
-
|
|
6163
|
-
/**
|
|
6164
|
-
* Creates a function that returns the result of invoking the given functions
|
|
6165
|
-
* with the `this` binding of the created function, where each successive
|
|
6166
|
-
* invocation is supplied the return value of the previous.
|
|
6167
|
-
*
|
|
6168
|
-
* @static
|
|
6169
|
-
* @memberOf _
|
|
6170
|
-
* @since 3.0.0
|
|
6171
|
-
* @category Util
|
|
6172
|
-
* @param {...(Function|Function[])} [funcs] The functions to invoke.
|
|
6173
|
-
* @returns {Function} Returns the new composite function.
|
|
6174
|
-
* @see _.flowRight
|
|
6175
|
-
* @example
|
|
6176
|
-
*
|
|
6177
|
-
* function square(n) {
|
|
6178
|
-
* return n * n;
|
|
6179
|
-
* }
|
|
6180
|
-
*
|
|
6181
|
-
* var addSquare = _.flow([_.add, square]);
|
|
6182
|
-
* addSquare(1, 2);
|
|
6183
|
-
* // => 9
|
|
6184
|
-
*/
|
|
6185
|
-
var flow = createFlow();
|
|
6186
|
-
|
|
6187
|
-
module.exports = flow;
|
|
6188
|
-
|
|
6189
|
-
|
|
6190
5955
|
/***/ }),
|
|
6191
5956
|
|
|
6192
5957
|
/***/ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/forOwn.js":
|
|
@@ -11770,8 +11535,9 @@ const BrushHelpers = {
|
|
|
11770
11535
|
__webpack_require__.r(__webpack_exports__);
|
|
11771
11536
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
11772
11537
|
/* harmony export */ "BrushHelpers": function() { return /* reexport safe */ _brush_helpers__WEBPACK_IMPORTED_MODULE_1__.BrushHelpers; },
|
|
11538
|
+
/* harmony export */ "VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ _victory_brush_container__WEBPACK_IMPORTED_MODULE_0__.VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS; },
|
|
11773
11539
|
/* harmony export */ "VictoryBrushContainer": function() { return /* reexport safe */ _victory_brush_container__WEBPACK_IMPORTED_MODULE_0__.VictoryBrushContainer; },
|
|
11774
|
-
/* harmony export */ "
|
|
11540
|
+
/* harmony export */ "useVictoryBrushContainer": function() { return /* reexport safe */ _victory_brush_container__WEBPACK_IMPORTED_MODULE_0__.useVictoryBrushContainer; }
|
|
11775
11541
|
/* harmony export */ });
|
|
11776
11542
|
/* harmony import */ var _victory_brush_container__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./victory-brush-container */ "../../victory-brush-container/es/victory-brush-container.js");
|
|
11777
11543
|
/* harmony import */ var _brush_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./brush-helpers */ "../../victory-brush-container/es/brush-helpers.js");
|
|
@@ -11789,17 +11555,18 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
11789
11555
|
"use strict";
|
|
11790
11556
|
__webpack_require__.r(__webpack_exports__);
|
|
11791
11557
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
11558
|
+
/* harmony export */ "VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS": function() { return /* binding */ VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS; },
|
|
11792
11559
|
/* harmony export */ "VictoryBrushContainer": function() { return /* binding */ VictoryBrushContainer; },
|
|
11793
|
-
/* harmony export */ "
|
|
11560
|
+
/* harmony export */ "useVictoryBrushContainer": function() { return /* binding */ useVictoryBrushContainer; }
|
|
11794
11561
|
/* harmony export */ });
|
|
11795
11562
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/defaults */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/defaults.js");
|
|
11796
11563
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_0__);
|
|
11797
11564
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ "react");
|
|
11798
11565
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
|
|
11799
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
11800
|
-
/* harmony import */ var
|
|
11801
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
11802
|
-
/* harmony import */ var
|
|
11566
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-primitives/rect.js");
|
|
11567
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-util/selection.js");
|
|
11568
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
11569
|
+
/* harmony import */ var _brush_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./brush-helpers */ "../../victory-brush-container/es/brush-helpers.js");
|
|
11803
11570
|
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react-fast-compare */ "../../../node_modules/.pnpm/react-fast-compare@3.2.0/node_modules/react-fast-compare/index.js");
|
|
11804
11571
|
/* harmony import */ var react_fast_compare__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_fast_compare__WEBPACK_IMPORTED_MODULE_2__);
|
|
11805
11572
|
|
|
@@ -11807,172 +11574,176 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
11807
11574
|
|
|
11808
11575
|
|
|
11809
11576
|
|
|
11810
|
-
|
|
11811
|
-
|
|
11812
|
-
|
|
11813
|
-
|
|
11814
|
-
|
|
11815
|
-
|
|
11816
|
-
|
|
11817
|
-
|
|
11818
|
-
|
|
11819
|
-
|
|
11820
|
-
|
|
11821
|
-
|
|
11822
|
-
|
|
11823
|
-
|
|
11824
|
-
|
|
11825
|
-
|
|
11826
|
-
|
|
11827
|
-
|
|
11828
|
-
|
|
11829
|
-
|
|
11830
|
-
|
|
11831
|
-
|
|
11577
|
+
const VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS = {
|
|
11578
|
+
allowDrag: true,
|
|
11579
|
+
allowDraw: true,
|
|
11580
|
+
allowResize: true,
|
|
11581
|
+
brushComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_3__.Rect, null),
|
|
11582
|
+
brushStyle: {
|
|
11583
|
+
stroke: "transparent",
|
|
11584
|
+
fill: "black",
|
|
11585
|
+
fillOpacity: 0.1
|
|
11586
|
+
},
|
|
11587
|
+
handleComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_3__.Rect, null),
|
|
11588
|
+
handleStyle: {
|
|
11589
|
+
stroke: "transparent",
|
|
11590
|
+
fill: "transparent"
|
|
11591
|
+
},
|
|
11592
|
+
handleWidth: 8,
|
|
11593
|
+
mouseMoveThreshold: 0
|
|
11594
|
+
};
|
|
11595
|
+
const useVictoryBrushContainer = initialProps => {
|
|
11596
|
+
const props = {
|
|
11597
|
+
...VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS,
|
|
11598
|
+
...initialProps
|
|
11599
|
+
};
|
|
11600
|
+
const {
|
|
11601
|
+
children
|
|
11602
|
+
} = props;
|
|
11603
|
+
const getSelectBox = coordinates => {
|
|
11604
|
+
const {
|
|
11605
|
+
x,
|
|
11606
|
+
y
|
|
11607
|
+
} = coordinates;
|
|
11608
|
+
const {
|
|
11609
|
+
brushStyle,
|
|
11610
|
+
brushComponent,
|
|
11611
|
+
name
|
|
11612
|
+
} = props;
|
|
11613
|
+
const brushComponentStyle = brushComponent.props && brushComponent.props.style;
|
|
11614
|
+
const cursor = !props.allowDrag && !props.allowResize ? "auto" : "move";
|
|
11615
|
+
return x[0] !== x[1] && y[0] !== y[1] ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(brushComponent, {
|
|
11616
|
+
key: `${name}-brush`,
|
|
11617
|
+
width: Math.abs(x[1] - x[0]) || 1,
|
|
11618
|
+
height: Math.abs(y[1] - y[0]) || 1,
|
|
11619
|
+
x: Math.min(x[0], x[1]),
|
|
11620
|
+
y: Math.min(y[0], y[1]),
|
|
11621
|
+
cursor,
|
|
11622
|
+
style: lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, brushComponentStyle, brushStyle)
|
|
11623
|
+
}) : null;
|
|
11624
|
+
};
|
|
11625
|
+
const getCursorPointers = () => {
|
|
11626
|
+
const cursors = {
|
|
11627
|
+
yProps: "ns-resize",
|
|
11628
|
+
xProps: "ew-resize"
|
|
11832
11629
|
};
|
|
11833
|
-
|
|
11834
|
-
|
|
11835
|
-
|
|
11836
|
-
|
|
11837
|
-
|
|
11838
|
-
|
|
11839
|
-
},
|
|
11840
|
-
onTouchStart: (evt, targetProps) => {
|
|
11841
|
-
return props.disable ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onMouseDown(evt, targetProps);
|
|
11842
|
-
},
|
|
11843
|
-
onGlobalMouseMove: (evt, targetProps) => {
|
|
11844
|
-
return props.disable || !targetProps.isPanning && !targetProps.isSelecting ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onGlobalMouseMove(evt, targetProps);
|
|
11845
|
-
},
|
|
11846
|
-
onGlobalTouchMove: (evt, targetProps) => {
|
|
11847
|
-
return props.disable || !targetProps.isPanning && !targetProps.isSelecting ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onGlobalMouseMove(evt, targetProps);
|
|
11848
|
-
},
|
|
11849
|
-
onGlobalMouseUp: (evt, targetProps) => {
|
|
11850
|
-
return props.disable ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onGlobalMouseUp(evt, targetProps);
|
|
11851
|
-
},
|
|
11852
|
-
onGlobalTouchEnd: (evt, targetProps) => {
|
|
11853
|
-
return props.disable ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onGlobalMouseUp(evt, targetProps);
|
|
11854
|
-
},
|
|
11855
|
-
onGlobalTouchCancel: (evt, targetProps) => {
|
|
11856
|
-
return props.disable ? {} : _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.onGlobalMouseUp(evt, targetProps);
|
|
11857
|
-
}
|
|
11858
|
-
}
|
|
11859
|
-
}];
|
|
11860
|
-
}
|
|
11861
|
-
getSelectBox(props, coordinates) {
|
|
11862
|
-
const {
|
|
11863
|
-
x,
|
|
11864
|
-
y
|
|
11865
|
-
} = coordinates;
|
|
11866
|
-
const {
|
|
11867
|
-
brushStyle,
|
|
11868
|
-
brushComponent,
|
|
11869
|
-
name
|
|
11870
|
-
} = props;
|
|
11871
|
-
const brushComponentStyle = brushComponent.props && brushComponent.props.style;
|
|
11872
|
-
const cursor = !props.allowDrag && !props.allowResize ? "auto" : "move";
|
|
11873
|
-
return x[0] !== x[1] && y[0] !== y[1] ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(brushComponent, {
|
|
11874
|
-
key: `${name}-brush`,
|
|
11875
|
-
width: Math.abs(x[1] - x[0]) || 1,
|
|
11876
|
-
height: Math.abs(y[1] - y[0]) || 1,
|
|
11877
|
-
x: Math.min(x[0], x[1]),
|
|
11878
|
-
y: Math.min(y[0], y[1]),
|
|
11879
|
-
cursor,
|
|
11880
|
-
style: lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, brushComponentStyle, brushStyle)
|
|
11881
|
-
}) : null;
|
|
11882
|
-
}
|
|
11883
|
-
getCursorPointers(props) {
|
|
11884
|
-
const cursors = {
|
|
11885
|
-
yProps: "ns-resize",
|
|
11886
|
-
xProps: "ew-resize"
|
|
11887
|
-
};
|
|
11888
|
-
if (!props.allowResize && props.allowDrag) {
|
|
11889
|
-
cursors.xProps = "move";
|
|
11890
|
-
cursors.yProps = "move";
|
|
11891
|
-
} else if (!props.allowResize && !props.allowDrag) {
|
|
11892
|
-
cursors.xProps = "auto";
|
|
11893
|
-
cursors.yProps = "auto";
|
|
11894
|
-
}
|
|
11895
|
-
return cursors;
|
|
11896
|
-
}
|
|
11897
|
-
getHandles(props, domain) {
|
|
11898
|
-
const {
|
|
11899
|
-
handleWidth,
|
|
11900
|
-
handleStyle,
|
|
11901
|
-
handleComponent,
|
|
11902
|
-
name
|
|
11903
|
-
} = props;
|
|
11904
|
-
const domainBox = _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.getDomainBox(props, domain);
|
|
11905
|
-
const {
|
|
11906
|
-
x1,
|
|
11907
|
-
x2,
|
|
11908
|
-
y1,
|
|
11909
|
-
y2
|
|
11910
|
-
} = domainBox;
|
|
11911
|
-
const {
|
|
11912
|
-
top,
|
|
11913
|
-
bottom,
|
|
11914
|
-
left,
|
|
11915
|
-
right
|
|
11916
|
-
} = _brush_helpers__WEBPACK_IMPORTED_MODULE_5__.BrushHelpers.getHandles(props, domainBox);
|
|
11917
|
-
const width = Math.abs(x2 - x1) || 1;
|
|
11918
|
-
const height = Math.abs(y2 - y1) || 1;
|
|
11919
|
-
const handleComponentStyle = handleComponent.props && handleComponent.props.style || {};
|
|
11920
|
-
const style = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, handleComponentStyle, handleStyle);
|
|
11921
|
-
const cursors = this.getCursorPointers(props);
|
|
11922
|
-
const yProps = {
|
|
11923
|
-
style,
|
|
11924
|
-
width,
|
|
11925
|
-
height: handleWidth,
|
|
11926
|
-
cursor: cursors.yProps
|
|
11927
|
-
};
|
|
11928
|
-
const xProps = {
|
|
11929
|
-
style,
|
|
11930
|
-
width: handleWidth,
|
|
11931
|
-
height,
|
|
11932
|
-
cursor: cursors.xProps
|
|
11933
|
-
};
|
|
11934
|
-
const handleProps = {
|
|
11935
|
-
top: top && Object.assign({
|
|
11936
|
-
x: top.x1,
|
|
11937
|
-
y: top.y1
|
|
11938
|
-
}, yProps),
|
|
11939
|
-
bottom: bottom && Object.assign({
|
|
11940
|
-
x: bottom.x1,
|
|
11941
|
-
y: bottom.y1
|
|
11942
|
-
}, yProps),
|
|
11943
|
-
left: left && Object.assign({
|
|
11944
|
-
y: left.y1,
|
|
11945
|
-
x: left.x1
|
|
11946
|
-
}, xProps),
|
|
11947
|
-
right: right && Object.assign({
|
|
11948
|
-
y: right.y1,
|
|
11949
|
-
x: right.x1
|
|
11950
|
-
}, xProps)
|
|
11951
|
-
};
|
|
11952
|
-
const handles = ["top", "bottom", "left", "right"].reduce((memo, curr) => handleProps[curr] ? memo.concat( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(handleComponent, Object.assign({
|
|
11953
|
-
key: `${name}-handle-${curr}`
|
|
11954
|
-
}, handleProps[curr]))) : memo, []);
|
|
11955
|
-
return handles.length ? handles : null;
|
|
11956
|
-
}
|
|
11957
|
-
getRect(props) {
|
|
11958
|
-
const {
|
|
11959
|
-
currentDomain,
|
|
11960
|
-
cachedBrushDomain
|
|
11961
|
-
} = props;
|
|
11962
|
-
const brushDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.brushDomain, props.domain);
|
|
11963
|
-
const domain = react_fast_compare__WEBPACK_IMPORTED_MODULE_2___default()(brushDomain, cachedBrushDomain) ? lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, currentDomain, brushDomain) : brushDomain;
|
|
11964
|
-
const coordinates = victory_core__WEBPACK_IMPORTED_MODULE_6__.getDomainCoordinates(props, domain);
|
|
11965
|
-
const selectBox = this.getSelectBox(props, coordinates);
|
|
11966
|
-
return selectBox ? [selectBox, this.getHandles(props, domain)] : [];
|
|
11967
|
-
}
|
|
11968
|
-
|
|
11969
|
-
// Overrides method in VictoryContainer
|
|
11970
|
-
getChildren(props) {
|
|
11971
|
-
return [...react__WEBPACK_IMPORTED_MODULE_1___default().Children.toArray(props.children), ...this.getRect(props)];
|
|
11630
|
+
if (!props.allowResize && props.allowDrag) {
|
|
11631
|
+
cursors.xProps = "move";
|
|
11632
|
+
cursors.yProps = "move";
|
|
11633
|
+
} else if (!props.allowResize && !props.allowDrag) {
|
|
11634
|
+
cursors.xProps = "auto";
|
|
11635
|
+
cursors.yProps = "auto";
|
|
11972
11636
|
}
|
|
11637
|
+
return cursors;
|
|
11973
11638
|
};
|
|
11974
|
-
|
|
11975
|
-
const
|
|
11639
|
+
const getHandles = domain => {
|
|
11640
|
+
const {
|
|
11641
|
+
handleWidth,
|
|
11642
|
+
handleStyle,
|
|
11643
|
+
handleComponent,
|
|
11644
|
+
name
|
|
11645
|
+
} = props;
|
|
11646
|
+
const domainBox = _brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.getDomainBox(props, domain);
|
|
11647
|
+
const {
|
|
11648
|
+
x1,
|
|
11649
|
+
x2,
|
|
11650
|
+
y1,
|
|
11651
|
+
y2
|
|
11652
|
+
} = domainBox;
|
|
11653
|
+
const {
|
|
11654
|
+
top,
|
|
11655
|
+
bottom,
|
|
11656
|
+
left,
|
|
11657
|
+
right
|
|
11658
|
+
} = _brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.getHandles(props, domainBox);
|
|
11659
|
+
const width = Math.abs(x2 - x1) || 1;
|
|
11660
|
+
const height = Math.abs(y2 - y1) || 1;
|
|
11661
|
+
const handleComponentStyle = handleComponent.props && handleComponent.props.style || {};
|
|
11662
|
+
const style = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, handleComponentStyle, handleStyle);
|
|
11663
|
+
const cursors = getCursorPointers();
|
|
11664
|
+
const yProps = {
|
|
11665
|
+
style,
|
|
11666
|
+
width,
|
|
11667
|
+
height: handleWidth,
|
|
11668
|
+
cursor: cursors.yProps
|
|
11669
|
+
};
|
|
11670
|
+
const xProps = {
|
|
11671
|
+
style,
|
|
11672
|
+
width: handleWidth,
|
|
11673
|
+
height,
|
|
11674
|
+
cursor: cursors.xProps
|
|
11675
|
+
};
|
|
11676
|
+
const handleProps = {
|
|
11677
|
+
top: top && Object.assign({
|
|
11678
|
+
x: top.x1,
|
|
11679
|
+
y: top.y1
|
|
11680
|
+
}, yProps),
|
|
11681
|
+
bottom: bottom && Object.assign({
|
|
11682
|
+
x: bottom.x1,
|
|
11683
|
+
y: bottom.y1
|
|
11684
|
+
}, yProps),
|
|
11685
|
+
left: left && Object.assign({
|
|
11686
|
+
y: left.y1,
|
|
11687
|
+
x: left.x1
|
|
11688
|
+
}, xProps),
|
|
11689
|
+
right: right && Object.assign({
|
|
11690
|
+
y: right.y1,
|
|
11691
|
+
x: right.x1
|
|
11692
|
+
}, xProps)
|
|
11693
|
+
};
|
|
11694
|
+
const handles = ["top", "bottom", "left", "right"].reduce((memo, curr) => handleProps[curr] ? memo.concat( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(handleComponent, Object.assign({
|
|
11695
|
+
key: `${name}-handle-${curr}`
|
|
11696
|
+
}, handleProps[curr]))) : memo, []);
|
|
11697
|
+
return handles.length ? handles : null;
|
|
11698
|
+
};
|
|
11699
|
+
const getRect = () => {
|
|
11700
|
+
const {
|
|
11701
|
+
currentDomain,
|
|
11702
|
+
cachedBrushDomain
|
|
11703
|
+
} = props;
|
|
11704
|
+
const brushDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.brushDomain, props.domain);
|
|
11705
|
+
const domain = react_fast_compare__WEBPACK_IMPORTED_MODULE_2___default()(brushDomain, cachedBrushDomain) ? lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, currentDomain, brushDomain) : brushDomain;
|
|
11706
|
+
const coordinates = victory_core__WEBPACK_IMPORTED_MODULE_5__.getDomainCoordinates(props, domain);
|
|
11707
|
+
const selectBox = getSelectBox(coordinates);
|
|
11708
|
+
return selectBox ? [selectBox, getHandles(domain)] : [];
|
|
11709
|
+
};
|
|
11710
|
+
return {
|
|
11711
|
+
props,
|
|
11712
|
+
children: [...react__WEBPACK_IMPORTED_MODULE_1___default().Children.toArray(children), ...getRect()]
|
|
11713
|
+
};
|
|
11714
|
+
};
|
|
11715
|
+
const VictoryBrushContainer = initialProps => {
|
|
11716
|
+
const {
|
|
11717
|
+
props,
|
|
11718
|
+
children
|
|
11719
|
+
} = useVictoryBrushContainer(initialProps);
|
|
11720
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_6__.VictoryContainer, props, children);
|
|
11721
|
+
};
|
|
11722
|
+
VictoryBrushContainer.role = "container";
|
|
11723
|
+
VictoryBrushContainer.defaultEvents = initialProps => {
|
|
11724
|
+
const props = {
|
|
11725
|
+
...VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS,
|
|
11726
|
+
...initialProps
|
|
11727
|
+
};
|
|
11728
|
+
const createEventHandler = (handler, isDisabled) =>
|
|
11729
|
+
// eslint-disable-next-line max-params
|
|
11730
|
+
(event, targetProps, eventKey, context) => props.disable || isDisabled?.(targetProps) ? {} : handler(event, {
|
|
11731
|
+
...props,
|
|
11732
|
+
...targetProps
|
|
11733
|
+
}, eventKey, context);
|
|
11734
|
+
return [{
|
|
11735
|
+
target: "parent",
|
|
11736
|
+
eventHandlers: {
|
|
11737
|
+
onMouseDown: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onMouseDown),
|
|
11738
|
+
onTouchStart: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onMouseDown),
|
|
11739
|
+
onGlobalMouseMove: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onGlobalMouseMove, targetProps => !targetProps.isPanning && !targetProps.isSelecting),
|
|
11740
|
+
onGlobalTouchMove: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onGlobalMouseMove, targetProps => !targetProps.isPanning && !targetProps.isSelecting),
|
|
11741
|
+
onGlobalMouseUp: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onGlobalMouseUp),
|
|
11742
|
+
onGlobalTouchEnd: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onGlobalMouseUp),
|
|
11743
|
+
onGlobalTouchCancel: createEventHandler(_brush_helpers__WEBPACK_IMPORTED_MODULE_4__.BrushHelpers.onGlobalMouseUp)
|
|
11744
|
+
}
|
|
11745
|
+
}];
|
|
11746
|
+
};
|
|
11976
11747
|
|
|
11977
11748
|
/***/ }),
|
|
11978
11749
|
|
|
@@ -14186,53 +13957,58 @@ VictoryChart.expectedComponents = ["groupComponent", "containerComponent"];
|
|
|
14186
13957
|
"use strict";
|
|
14187
13958
|
__webpack_require__.r(__webpack_exports__);
|
|
14188
13959
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
14189
|
-
/* harmony export */ "Arc": function() { return /* reexport safe */
|
|
14190
|
-
/* harmony export */ "Axis": function() { return /* reexport safe */
|
|
14191
|
-
/* harmony export */ "Background": function() { return /* reexport safe */
|
|
14192
|
-
/* harmony export */ "Border": function() { return /* reexport safe */
|
|
14193
|
-
/* harmony export */ "Box": function() { return /* reexport safe */
|
|
14194
|
-
/* harmony export */ "Circle": function() { return /* reexport safe */
|
|
14195
|
-
/* harmony export */ "ClipPath": function() { return /* reexport safe */
|
|
14196
|
-
/* harmony export */ "Collection": function() { return /* reexport safe */
|
|
14197
|
-
/* harmony export */ "Data": function() { return /* reexport safe */
|
|
14198
|
-
/* harmony export */ "DefaultTransitions": function() { return /* reexport safe */
|
|
14199
|
-
/* harmony export */ "Domain": function() { return /* reexport safe */
|
|
14200
|
-
/* harmony export */ "Events": function() { return /* reexport safe */
|
|
14201
|
-
/* harmony export */ "Helpers": function() { return /* reexport safe */
|
|
14202
|
-
/* harmony export */ "Hooks": function() { return /* reexport safe */
|
|
14203
|
-
/* harmony export */ "Immutable": function() { return /* reexport safe */
|
|
14204
|
-
/* harmony export */ "LabelHelpers": function() { return /* reexport safe */
|
|
14205
|
-
/* harmony export */ "Line": function() { return /* reexport safe */
|
|
14206
|
-
/* harmony export */ "LineHelpers": function() { return /* reexport safe */
|
|
14207
|
-
/* harmony export */ "LineSegment": function() { return /* reexport safe */
|
|
14208
|
-
/* harmony export */ "Log": function() { return /* reexport safe */
|
|
14209
|
-
/* harmony export */ "Path": function() { return /* reexport safe */
|
|
14210
|
-
/* harmony export */ "Point": function() { return /* reexport safe */
|
|
14211
|
-
/* harmony export */ "PointPathHelpers": function() { return /* reexport safe */
|
|
13960
|
+
/* harmony export */ "Arc": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Arc; },
|
|
13961
|
+
/* harmony export */ "Axis": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Axis; },
|
|
13962
|
+
/* harmony export */ "Background": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Background; },
|
|
13963
|
+
/* harmony export */ "Border": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Border; },
|
|
13964
|
+
/* harmony export */ "Box": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_12__.Border; },
|
|
13965
|
+
/* harmony export */ "Circle": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Circle; },
|
|
13966
|
+
/* harmony export */ "ClipPath": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.ClipPath; },
|
|
13967
|
+
/* harmony export */ "Collection": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Collection; },
|
|
13968
|
+
/* harmony export */ "Data": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Data; },
|
|
13969
|
+
/* harmony export */ "DefaultTransitions": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.DefaultTransitions; },
|
|
13970
|
+
/* harmony export */ "Domain": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Domain; },
|
|
13971
|
+
/* harmony export */ "Events": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Events; },
|
|
13972
|
+
/* harmony export */ "Helpers": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Helpers; },
|
|
13973
|
+
/* harmony export */ "Hooks": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Hooks; },
|
|
13974
|
+
/* harmony export */ "Immutable": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Immutable; },
|
|
13975
|
+
/* harmony export */ "LabelHelpers": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.LabelHelpers; },
|
|
13976
|
+
/* harmony export */ "Line": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Line; },
|
|
13977
|
+
/* harmony export */ "LineHelpers": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.LineHelpers; },
|
|
13978
|
+
/* harmony export */ "LineSegment": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.LineSegment; },
|
|
13979
|
+
/* harmony export */ "Log": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Log; },
|
|
13980
|
+
/* harmony export */ "Path": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Path; },
|
|
13981
|
+
/* harmony export */ "Point": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Point; },
|
|
13982
|
+
/* harmony export */ "PointPathHelpers": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.PointPathHelpers; },
|
|
14212
13983
|
/* harmony export */ "Portal": function() { return /* reexport safe */ _victory_portal_portal__WEBPACK_IMPORTED_MODULE_7__.Portal; },
|
|
14213
|
-
/* harmony export */ "PortalContext": function() { return /* reexport safe */
|
|
14214
|
-
/* harmony export */ "
|
|
14215
|
-
/* harmony export */ "
|
|
14216
|
-
/* harmony export */ "
|
|
14217
|
-
/* harmony export */ "
|
|
14218
|
-
/* harmony export */ "
|
|
14219
|
-
/* harmony export */ "
|
|
14220
|
-
/* harmony export */ "
|
|
14221
|
-
/* harmony export */ "
|
|
14222
|
-
/* harmony export */ "
|
|
14223
|
-
/* harmony export */ "
|
|
14224
|
-
/* harmony export */ "
|
|
13984
|
+
/* harmony export */ "PortalContext": function() { return /* reexport safe */ _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_9__.PortalContext; },
|
|
13985
|
+
/* harmony export */ "PortalOutlet": function() { return /* reexport safe */ _victory_portal_portal_outlet__WEBPACK_IMPORTED_MODULE_10__.PortalOutlet; },
|
|
13986
|
+
/* harmony export */ "PortalProvider": function() { return /* reexport safe */ _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_9__.PortalProvider; },
|
|
13987
|
+
/* harmony export */ "Rect": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Rect; },
|
|
13988
|
+
/* harmony export */ "Scale": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Scale; },
|
|
13989
|
+
/* harmony export */ "Selection": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Selection; },
|
|
13990
|
+
/* harmony export */ "Style": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Style; },
|
|
13991
|
+
/* harmony export */ "TSpan": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.TSpan; },
|
|
13992
|
+
/* harmony export */ "Text": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Text; },
|
|
13993
|
+
/* harmony export */ "TextSize": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.TextSize; },
|
|
13994
|
+
/* harmony export */ "Timer": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Timer; },
|
|
13995
|
+
/* harmony export */ "TimerContext": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.TimerContext; },
|
|
13996
|
+
/* harmony export */ "Transitions": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Transitions; },
|
|
13997
|
+
/* harmony export */ "UserProps": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.UserProps; },
|
|
14225
13998
|
/* harmony export */ "VictoryAccessibleGroup": function() { return /* reexport safe */ _victory_accessible_group_victory_accessible_group__WEBPACK_IMPORTED_MODULE_0__.VictoryAccessibleGroup; },
|
|
14226
13999
|
/* harmony export */ "VictoryAnimation": function() { return /* reexport safe */ _victory_animation_victory_animation__WEBPACK_IMPORTED_MODULE_1__.VictoryAnimation; },
|
|
14227
14000
|
/* harmony export */ "VictoryClipContainer": function() { return /* reexport safe */ _victory_clip_container_victory_clip_container__WEBPACK_IMPORTED_MODULE_5__.VictoryClipContainer; },
|
|
14228
14001
|
/* harmony export */ "VictoryContainer": function() { return /* reexport safe */ _victory_container_victory_container__WEBPACK_IMPORTED_MODULE_2__.VictoryContainer; },
|
|
14229
14002
|
/* harmony export */ "VictoryLabel": function() { return /* reexport safe */ _victory_label_victory_label__WEBPACK_IMPORTED_MODULE_3__.VictoryLabel; },
|
|
14230
|
-
/* harmony export */ "VictoryPortal": function() { return /* reexport safe */
|
|
14003
|
+
/* harmony export */ "VictoryPortal": function() { return /* reexport safe */ _victory_portal_victory_portal__WEBPACK_IMPORTED_MODULE_8__.VictoryPortal; },
|
|
14231
14004
|
/* harmony export */ "VictoryTheme": function() { return /* reexport safe */ _victory_theme_victory_theme__WEBPACK_IMPORTED_MODULE_6__.VictoryTheme; },
|
|
14232
14005
|
/* harmony export */ "VictoryTransition": function() { return /* reexport safe */ _victory_transition_victory_transition__WEBPACK_IMPORTED_MODULE_4__.VictoryTransition; },
|
|
14233
|
-
/* harmony export */ "Whisker": function() { return /* reexport safe */
|
|
14234
|
-
/* harmony export */ "Wrapper": function() { return /* reexport safe */
|
|
14235
|
-
/* harmony export */ "addEvents": function() { return /* reexport safe */
|
|
14006
|
+
/* harmony export */ "Whisker": function() { return /* reexport safe */ _victory_primitives__WEBPACK_IMPORTED_MODULE_11__.Whisker; },
|
|
14007
|
+
/* harmony export */ "Wrapper": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.Wrapper; },
|
|
14008
|
+
/* harmony export */ "addEvents": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.addEvents; },
|
|
14009
|
+
/* harmony export */ "mergeRefs": function() { return /* reexport safe */ _victory_util__WEBPACK_IMPORTED_MODULE_13__.mergeRefs; },
|
|
14010
|
+
/* harmony export */ "usePortalContext": function() { return /* reexport safe */ _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_9__.usePortalContext; },
|
|
14011
|
+
/* harmony export */ "useVictoryContainer": function() { return /* reexport safe */ _victory_container_victory_container__WEBPACK_IMPORTED_MODULE_2__.useVictoryContainer; }
|
|
14236
14012
|
/* harmony export */ });
|
|
14237
14013
|
/* harmony import */ var _victory_accessible_group_victory_accessible_group__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./victory-accessible-group/victory-accessible-group */ "../../victory-core/es/victory-accessible-group/victory-accessible-group.js");
|
|
14238
14014
|
/* harmony import */ var _victory_animation_victory_animation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./victory-animation/victory-animation */ "../../victory-core/es/victory-animation/victory-animation.js");
|
|
@@ -14242,11 +14018,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
14242
14018
|
/* harmony import */ var _victory_clip_container_victory_clip_container__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./victory-clip-container/victory-clip-container */ "../../victory-core/es/victory-clip-container/victory-clip-container.js");
|
|
14243
14019
|
/* harmony import */ var _victory_theme_victory_theme__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./victory-theme/victory-theme */ "../../victory-core/es/victory-theme/victory-theme.js");
|
|
14244
14020
|
/* harmony import */ var _victory_portal_portal__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./victory-portal/portal */ "../../victory-core/es/victory-portal/portal.js");
|
|
14245
|
-
/* harmony import */ var
|
|
14246
|
-
/* harmony import */ var
|
|
14247
|
-
/* harmony import */ var
|
|
14248
|
-
/* harmony import */ var _victory_primitives__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./victory-primitives */ "../../victory-core/es/victory-primitives/
|
|
14249
|
-
/* harmony import */ var
|
|
14021
|
+
/* harmony import */ var _victory_portal_victory_portal__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./victory-portal/victory-portal */ "../../victory-core/es/victory-portal/victory-portal.js");
|
|
14022
|
+
/* harmony import */ var _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./victory-portal/portal-context */ "../../victory-core/es/victory-portal/portal-context.js");
|
|
14023
|
+
/* harmony import */ var _victory_portal_portal_outlet__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./victory-portal/portal-outlet */ "../../victory-core/es/victory-portal/portal-outlet.js");
|
|
14024
|
+
/* harmony import */ var _victory_primitives__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./victory-primitives */ "../../victory-core/es/victory-primitives/index.js");
|
|
14025
|
+
/* harmony import */ var _victory_primitives__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./victory-primitives */ "../../victory-core/es/victory-primitives/border.js");
|
|
14026
|
+
/* harmony import */ var _victory_util__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./victory-util */ "../../victory-core/es/victory-util/index.js");
|
|
14027
|
+
|
|
14250
14028
|
|
|
14251
14029
|
|
|
14252
14030
|
|
|
@@ -14881,23 +14659,18 @@ class VictoryClipContainer extends (react__WEBPACK_IMPORTED_MODULE_3___default()
|
|
|
14881
14659
|
"use strict";
|
|
14882
14660
|
__webpack_require__.r(__webpack_exports__);
|
|
14883
14661
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
14884
|
-
/* harmony export */ "VictoryContainer": function() { return /* binding */ VictoryContainer; }
|
|
14662
|
+
/* harmony export */ "VictoryContainer": function() { return /* binding */ VictoryContainer; },
|
|
14663
|
+
/* harmony export */ "useVictoryContainer": function() { return /* binding */ useVictoryContainer; }
|
|
14885
14664
|
/* harmony export */ });
|
|
14886
|
-
/* harmony import */ var
|
|
14887
|
-
/* harmony import */ var
|
|
14888
|
-
/* harmony import */ var
|
|
14889
|
-
/* harmony import */ var
|
|
14890
|
-
/* harmony import */ var
|
|
14891
|
-
/* harmony import */ var
|
|
14892
|
-
/* harmony import */ var
|
|
14893
|
-
/* harmony import */ var
|
|
14894
|
-
/* harmony import */ var
|
|
14895
|
-
/* harmony import */ var _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../victory-portal/portal-context */ "../../victory-core/es/victory-portal/portal-context.js");
|
|
14896
|
-
/* harmony import */ var _victory_util_timer_context__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../victory-util/timer-context */ "../../victory-core/es/victory-util/timer-context.js");
|
|
14897
|
-
/* harmony import */ var _victory_util_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../victory-util/helpers */ "../../victory-core/es/victory-util/helpers.js");
|
|
14898
|
-
/* harmony import */ var _victory_util_user_props__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../victory-util/user-props */ "../../victory-core/es/victory-util/user-props.js");
|
|
14899
|
-
|
|
14900
|
-
|
|
14665
|
+
/* harmony import */ var lodash_uniqueId__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/uniqueId */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/uniqueId.js");
|
|
14666
|
+
/* harmony import */ var lodash_uniqueId__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_uniqueId__WEBPACK_IMPORTED_MODULE_0__);
|
|
14667
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ "react");
|
|
14668
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
|
|
14669
|
+
/* harmony import */ var _victory_portal_portal__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../victory-portal/portal */ "../../victory-core/es/victory-portal/portal.js");
|
|
14670
|
+
/* harmony import */ var _victory_util_user_props__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../victory-util/user-props */ "../../victory-core/es/victory-util/user-props.js");
|
|
14671
|
+
/* harmony import */ var _victory_util__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../victory-util */ "../../victory-core/es/victory-util/merge-refs.js");
|
|
14672
|
+
/* harmony import */ var _victory_portal_portal_outlet__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../victory-portal/portal-outlet */ "../../victory-core/es/victory-portal/portal-outlet.js");
|
|
14673
|
+
/* harmony import */ var _victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../victory-portal/portal-context */ "../../victory-core/es/victory-portal/portal-context.js");
|
|
14901
14674
|
|
|
14902
14675
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
14903
14676
|
|
|
@@ -14906,175 +14679,149 @@ function _extends() { _extends = Object.assign ? Object.assign.bind() : function
|
|
|
14906
14679
|
|
|
14907
14680
|
|
|
14908
14681
|
|
|
14909
|
-
|
|
14910
|
-
|
|
14911
|
-
|
|
14912
|
-
|
|
14913
|
-
|
|
14914
|
-
|
|
14915
|
-
|
|
14916
|
-
|
|
14917
|
-
|
|
14918
|
-
|
|
14919
|
-
|
|
14920
|
-
|
|
14921
|
-
// @ts-expect-error Ref will be initialized on mount
|
|
14922
|
-
|
|
14923
|
-
// @ts-expect-error Ref will be initialized on mount
|
|
14924
|
-
|
|
14925
|
-
constructor(props) {
|
|
14926
|
-
super(props);
|
|
14927
|
-
this.containerId = !lodash_isObject__WEBPACK_IMPORTED_MODULE_0___default()(props) || props.containerId === undefined ? lodash_uniqueId__WEBPACK_IMPORTED_MODULE_1___default()("victory-container-") : props.containerId;
|
|
14928
|
-
this.shouldHandleWheel = !!(props && props.events && props.events.onWheel);
|
|
14929
|
-
}
|
|
14930
|
-
savePortalRef = portal => {
|
|
14931
|
-
this.portalRef = portal;
|
|
14932
|
-
return portal;
|
|
14682
|
+
const defaultProps = {
|
|
14683
|
+
className: "VictoryContainer",
|
|
14684
|
+
portalComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_victory_portal_portal__WEBPACK_IMPORTED_MODULE_2__.Portal, null),
|
|
14685
|
+
portalZIndex: 99,
|
|
14686
|
+
responsive: true,
|
|
14687
|
+
role: "img"
|
|
14688
|
+
};
|
|
14689
|
+
function useVictoryContainer(initialProps) {
|
|
14690
|
+
const props = {
|
|
14691
|
+
...defaultProps,
|
|
14692
|
+
...initialProps
|
|
14933
14693
|
};
|
|
14934
|
-
|
|
14935
|
-
|
|
14936
|
-
|
|
14937
|
-
|
|
14938
|
-
|
|
14939
|
-
|
|
14940
|
-
|
|
14941
|
-
|
|
14942
|
-
|
|
14694
|
+
const {
|
|
14695
|
+
title,
|
|
14696
|
+
desc,
|
|
14697
|
+
width,
|
|
14698
|
+
height,
|
|
14699
|
+
responsive
|
|
14700
|
+
} = props;
|
|
14701
|
+
const localContainerRef = (0,react__WEBPACK_IMPORTED_MODULE_1__.useRef)(null);
|
|
14702
|
+
|
|
14703
|
+
// Generated ID stored in ref because it needs to persist across renders
|
|
14704
|
+
const generatedId = (0,react__WEBPACK_IMPORTED_MODULE_1__.useRef)(lodash_uniqueId__WEBPACK_IMPORTED_MODULE_0___default()("victory-container-"));
|
|
14705
|
+
const containerId = props.containerId ?? generatedId.current;
|
|
14706
|
+
const getIdForElement = elName => `${containerId}-${elName}`;
|
|
14707
|
+
const userProps = _victory_util_user_props__WEBPACK_IMPORTED_MODULE_3__.getSafeUserProps(props);
|
|
14708
|
+
const dimensions = responsive ? {
|
|
14709
|
+
width: "100%",
|
|
14710
|
+
height: "100%"
|
|
14711
|
+
} : {
|
|
14712
|
+
width,
|
|
14713
|
+
height
|
|
14943
14714
|
};
|
|
14944
|
-
|
|
14945
|
-
|
|
14946
|
-
|
|
14947
|
-
|
|
14948
|
-
|
|
14949
|
-
|
|
14950
|
-
|
|
14951
|
-
|
|
14952
|
-
|
|
14953
|
-
|
|
14954
|
-
|
|
14955
|
-
|
|
14956
|
-
|
|
14957
|
-
|
|
14958
|
-
|
|
14959
|
-
|
|
14960
|
-
|
|
14961
|
-
|
|
14962
|
-
|
|
14963
|
-
|
|
14964
|
-
|
|
14965
|
-
|
|
14966
|
-
|
|
14967
|
-
|
|
14968
|
-
|
|
14969
|
-
|
|
14970
|
-
|
|
14971
|
-
|
|
14972
|
-
|
|
14973
|
-
|
|
14974
|
-
|
|
14975
|
-
|
|
14976
|
-
|
|
14977
|
-
|
|
14978
|
-
|
|
14979
|
-
|
|
14980
|
-
|
|
14981
|
-
|
|
14982
|
-
|
|
14983
|
-
|
|
14984
|
-
|
|
14985
|
-
|
|
14986
|
-
|
|
14987
|
-
|
|
14988
|
-
|
|
14989
|
-
|
|
14990
|
-
|
|
14991
|
-
|
|
14992
|
-
|
|
14993
|
-
|
|
14994
|
-
|
|
14995
|
-
const
|
|
14996
|
-
|
|
14997
|
-
|
|
14998
|
-
|
|
14999
|
-
} : {
|
|
15000
|
-
width,
|
|
15001
|
-
height
|
|
14715
|
+
const viewBox = responsive ? `0 0 ${width} ${height}` : undefined;
|
|
14716
|
+
const preserveAspectRatio = responsive ? props.preserveAspectRatio : undefined;
|
|
14717
|
+
const ariaLabelledBy = [title && getIdForElement("title"), props["aria-labelledby"]].filter(Boolean).join(" ") || undefined;
|
|
14718
|
+
const ariaDescribedBy = [desc && getIdForElement("desc"), props["aria-describedby"]].filter(Boolean).join(" ") || undefined;
|
|
14719
|
+
const titleId = getIdForElement("title");
|
|
14720
|
+
const descId = getIdForElement("desc");
|
|
14721
|
+
return {
|
|
14722
|
+
...props,
|
|
14723
|
+
titleId,
|
|
14724
|
+
descId,
|
|
14725
|
+
dimensions,
|
|
14726
|
+
viewBox,
|
|
14727
|
+
preserveAspectRatio,
|
|
14728
|
+
ariaLabelledBy,
|
|
14729
|
+
ariaDescribedBy,
|
|
14730
|
+
userProps,
|
|
14731
|
+
localContainerRef
|
|
14732
|
+
};
|
|
14733
|
+
}
|
|
14734
|
+
const VictoryContainer = initialProps => {
|
|
14735
|
+
const {
|
|
14736
|
+
role,
|
|
14737
|
+
title,
|
|
14738
|
+
desc,
|
|
14739
|
+
children,
|
|
14740
|
+
className,
|
|
14741
|
+
portalZIndex,
|
|
14742
|
+
portalComponent,
|
|
14743
|
+
width,
|
|
14744
|
+
height,
|
|
14745
|
+
style,
|
|
14746
|
+
tabIndex,
|
|
14747
|
+
responsive,
|
|
14748
|
+
events,
|
|
14749
|
+
ouiaId,
|
|
14750
|
+
ouiaSafe,
|
|
14751
|
+
ouiaType,
|
|
14752
|
+
dimensions,
|
|
14753
|
+
ariaDescribedBy,
|
|
14754
|
+
ariaLabelledBy,
|
|
14755
|
+
viewBox,
|
|
14756
|
+
preserveAspectRatio,
|
|
14757
|
+
userProps,
|
|
14758
|
+
titleId,
|
|
14759
|
+
descId,
|
|
14760
|
+
containerRef,
|
|
14761
|
+
localContainerRef
|
|
14762
|
+
} = useVictoryContainer(initialProps);
|
|
14763
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(() => {
|
|
14764
|
+
if (!events?.onWheel) return;
|
|
14765
|
+
const handleWheel = e => e.preventDefault();
|
|
14766
|
+
const container = localContainerRef?.current;
|
|
14767
|
+
container?.addEventListener("wheel", handleWheel);
|
|
14768
|
+
return () => {
|
|
14769
|
+
container?.removeEventListener("wheel", handleWheel);
|
|
15002
14770
|
};
|
|
15003
|
-
|
|
14771
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
14772
|
+
}, []);
|
|
14773
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", {
|
|
14774
|
+
className: className,
|
|
14775
|
+
style: {
|
|
14776
|
+
...style,
|
|
14777
|
+
width: responsive ? style?.width : dimensions.width,
|
|
14778
|
+
height: responsive ? style?.height : dimensions.height,
|
|
15004
14779
|
pointerEvents: "none",
|
|
15005
14780
|
touchAction: "none",
|
|
15006
14781
|
position: "relative"
|
|
15007
|
-
},
|
|
15008
|
-
|
|
14782
|
+
},
|
|
14783
|
+
"data-ouia-component-id": ouiaId,
|
|
14784
|
+
"data-ouia-component-type": ouiaType,
|
|
14785
|
+
"data-ouia-safe": ouiaSafe,
|
|
14786
|
+
ref: (0,_victory_util__WEBPACK_IMPORTED_MODULE_4__.mergeRefs)([localContainerRef, containerRef])
|
|
14787
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_5__.PortalProvider, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("svg", _extends({
|
|
14788
|
+
width: width,
|
|
14789
|
+
height: height,
|
|
14790
|
+
tabIndex: tabIndex,
|
|
14791
|
+
role: role,
|
|
14792
|
+
"aria-labelledby": ariaLabelledBy,
|
|
14793
|
+
"aria-describedby": ariaDescribedBy,
|
|
14794
|
+
viewBox: viewBox,
|
|
14795
|
+
preserveAspectRatio: preserveAspectRatio,
|
|
14796
|
+
style: {
|
|
14797
|
+
...dimensions,
|
|
14798
|
+
pointerEvents: "all"
|
|
14799
|
+
}
|
|
14800
|
+
}, userProps, events), title ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("title", {
|
|
14801
|
+
id: titleId
|
|
14802
|
+
}, title) : null, desc ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("desc", {
|
|
14803
|
+
id: descId
|
|
14804
|
+
}, desc) : null, children), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("div", {
|
|
14805
|
+
style: {
|
|
14806
|
+
...dimensions,
|
|
15009
14807
|
zIndex: portalZIndex,
|
|
15010
14808
|
position: "absolute",
|
|
15011
14809
|
top: 0,
|
|
15012
14810
|
left: 0
|
|
15013
|
-
}
|
|
15014
|
-
|
|
15015
|
-
|
|
15016
|
-
|
|
15017
|
-
|
|
14811
|
+
}
|
|
14812
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(_victory_portal_portal_outlet__WEBPACK_IMPORTED_MODULE_6__.PortalOutlet, {
|
|
14813
|
+
as: portalComponent,
|
|
14814
|
+
width: width,
|
|
14815
|
+
height: height,
|
|
14816
|
+
viewBox: viewBox,
|
|
14817
|
+
preserveAspectRatio: preserveAspectRatio,
|
|
14818
|
+
style: {
|
|
14819
|
+
...dimensions,
|
|
15018
14820
|
overflow: "visible"
|
|
15019
|
-
}
|
|
15020
|
-
|
|
15021
|
-
|
|
15022
|
-
|
|
15023
|
-
viewBox: svgProps.viewBox,
|
|
15024
|
-
preserveAspectRatio: svgProps.preserveAspectRatio,
|
|
15025
|
-
style: portalSvgStyle
|
|
15026
|
-
};
|
|
15027
|
-
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement(_victory_portal_portal_context__WEBPACK_IMPORTED_MODULE_7__.PortalContext.Provider, {
|
|
15028
|
-
value: {
|
|
15029
|
-
portalUpdate: this.portalUpdate,
|
|
15030
|
-
portalRegister: this.portalRegister,
|
|
15031
|
-
portalDeregister: this.portalDeregister
|
|
15032
|
-
}
|
|
15033
|
-
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement("div", _extends({
|
|
15034
|
-
style: lodash_defaults__WEBPACK_IMPORTED_MODULE_2___default()({}, style, divStyle),
|
|
15035
|
-
className: className,
|
|
15036
|
-
ref: this.saveContainerRef
|
|
15037
|
-
}, this.getOUIAProps(props)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement("svg", _extends({}, svgProps, {
|
|
15038
|
-
style: svgStyle
|
|
15039
|
-
}), title ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement("title", {
|
|
15040
|
-
id: this.getIdForElement("title")
|
|
15041
|
-
}, title) : null, desc ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement("desc", {
|
|
15042
|
-
id: this.getIdForElement("desc")
|
|
15043
|
-
}, desc) : null, children), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().createElement("div", {
|
|
15044
|
-
style: portalDivStyle
|
|
15045
|
-
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_3___default().cloneElement(portalComponent, {
|
|
15046
|
-
...portalProps,
|
|
15047
|
-
ref: this.savePortalRef
|
|
15048
|
-
}))));
|
|
15049
|
-
}
|
|
15050
|
-
render() {
|
|
15051
|
-
const {
|
|
15052
|
-
width,
|
|
15053
|
-
height,
|
|
15054
|
-
responsive,
|
|
15055
|
-
events,
|
|
15056
|
-
title,
|
|
15057
|
-
desc,
|
|
15058
|
-
tabIndex,
|
|
15059
|
-
preserveAspectRatio,
|
|
15060
|
-
role
|
|
15061
|
-
} = this.props;
|
|
15062
|
-
const style = responsive ? this.props.style : _victory_util_helpers__WEBPACK_IMPORTED_MODULE_6__.omit(this.props.style, ["height", "width"]);
|
|
15063
|
-
const userProps = _victory_util_user_props__WEBPACK_IMPORTED_MODULE_8__.getSafeUserProps(this.props);
|
|
15064
|
-
const svgProps = Object.assign({
|
|
15065
|
-
width,
|
|
15066
|
-
height,
|
|
15067
|
-
tabIndex,
|
|
15068
|
-
role,
|
|
15069
|
-
"aria-labelledby": [title && this.getIdForElement("title"), this.props["aria-labelledby"]].filter(Boolean).join(" ") || undefined,
|
|
15070
|
-
"aria-describedby": [desc && this.getIdForElement("desc"), this.props["aria-describedby"]].filter(Boolean).join(" ") || undefined,
|
|
15071
|
-
viewBox: responsive ? `0 0 ${width} ${height}` : undefined,
|
|
15072
|
-
preserveAspectRatio: responsive ? preserveAspectRatio : undefined,
|
|
15073
|
-
...userProps
|
|
15074
|
-
}, events);
|
|
15075
|
-
return this.renderContainer(this.props, svgProps, style);
|
|
15076
|
-
}
|
|
15077
|
-
}
|
|
14821
|
+
}
|
|
14822
|
+
}))));
|
|
14823
|
+
};
|
|
14824
|
+
VictoryContainer.role = "container";
|
|
15078
14825
|
|
|
15079
14826
|
/***/ }),
|
|
15080
14827
|
|
|
@@ -15587,17 +15334,78 @@ VictoryLabel.defaultStyles = defaultStyles;
|
|
|
15587
15334
|
"use strict";
|
|
15588
15335
|
__webpack_require__.r(__webpack_exports__);
|
|
15589
15336
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
15590
|
-
/* harmony export */ "PortalContext": function() { return /* binding */ PortalContext; }
|
|
15337
|
+
/* harmony export */ "PortalContext": function() { return /* binding */ PortalContext; },
|
|
15338
|
+
/* harmony export */ "PortalProvider": function() { return /* binding */ PortalProvider; },
|
|
15339
|
+
/* harmony export */ "usePortalContext": function() { return /* binding */ usePortalContext; }
|
|
15591
15340
|
/* harmony export */ });
|
|
15592
15341
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "react");
|
|
15593
15342
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
|
15594
15343
|
|
|
15595
|
-
|
|
15596
|
-
* The React context object consumers may use to access the context of the
|
|
15597
|
-
* portal.
|
|
15598
|
-
*/
|
|
15599
|
-
const PortalContext = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createContext({});
|
|
15344
|
+
const PortalContext = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createContext(undefined);
|
|
15600
15345
|
PortalContext.displayName = "PortalContext";
|
|
15346
|
+
const usePortalContext = () => {
|
|
15347
|
+
const context = react__WEBPACK_IMPORTED_MODULE_0___default().useContext(PortalContext);
|
|
15348
|
+
return context;
|
|
15349
|
+
};
|
|
15350
|
+
const PortalProvider = _ref => {
|
|
15351
|
+
let {
|
|
15352
|
+
children
|
|
15353
|
+
} = _ref;
|
|
15354
|
+
const [portalChildren, setPortalChildren] = react__WEBPACK_IMPORTED_MODULE_0___default().useState(new Map());
|
|
15355
|
+
const addChild = react__WEBPACK_IMPORTED_MODULE_0___default().useCallback((id, element) => {
|
|
15356
|
+
setPortalChildren(prevChildren => {
|
|
15357
|
+
const nextChildren = new Map(prevChildren);
|
|
15358
|
+
nextChildren.set(id, element);
|
|
15359
|
+
return nextChildren;
|
|
15360
|
+
});
|
|
15361
|
+
}, [setPortalChildren]);
|
|
15362
|
+
const removeChild = react__WEBPACK_IMPORTED_MODULE_0___default().useCallback(id => {
|
|
15363
|
+
setPortalChildren(prevChildren => {
|
|
15364
|
+
const nextChildren = new Map(prevChildren);
|
|
15365
|
+
nextChildren.delete(id);
|
|
15366
|
+
return nextChildren;
|
|
15367
|
+
});
|
|
15368
|
+
}, [setPortalChildren]);
|
|
15369
|
+
const contextValue = react__WEBPACK_IMPORTED_MODULE_0___default().useMemo(() => ({
|
|
15370
|
+
addChild,
|
|
15371
|
+
removeChild,
|
|
15372
|
+
children: portalChildren
|
|
15373
|
+
}), [addChild, removeChild, portalChildren]);
|
|
15374
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(PortalContext.Provider, {
|
|
15375
|
+
value: contextValue
|
|
15376
|
+
}, children);
|
|
15377
|
+
};
|
|
15378
|
+
|
|
15379
|
+
/***/ }),
|
|
15380
|
+
|
|
15381
|
+
/***/ "../../victory-core/es/victory-portal/portal-outlet.js":
|
|
15382
|
+
/*!*************************************************************!*\
|
|
15383
|
+
!*** ../../victory-core/es/victory-portal/portal-outlet.js ***!
|
|
15384
|
+
\*************************************************************/
|
|
15385
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
15386
|
+
|
|
15387
|
+
"use strict";
|
|
15388
|
+
__webpack_require__.r(__webpack_exports__);
|
|
15389
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
15390
|
+
/* harmony export */ "PortalOutlet": function() { return /* binding */ PortalOutlet; }
|
|
15391
|
+
/* harmony export */ });
|
|
15392
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "react");
|
|
15393
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
|
15394
|
+
/* harmony import */ var _portal_context__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./portal-context */ "../../victory-core/es/victory-portal/portal-context.js");
|
|
15395
|
+
|
|
15396
|
+
|
|
15397
|
+
const PortalOutlet = _ref => {
|
|
15398
|
+
let {
|
|
15399
|
+
as: portalComponent,
|
|
15400
|
+
...props
|
|
15401
|
+
} = _ref;
|
|
15402
|
+
const portalContext = (0,_portal_context__WEBPACK_IMPORTED_MODULE_1__.usePortalContext)();
|
|
15403
|
+
if (!portalContext) {
|
|
15404
|
+
return null;
|
|
15405
|
+
}
|
|
15406
|
+
const children = Array.from(portalContext.children.values());
|
|
15407
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().cloneElement(portalComponent, props, children);
|
|
15408
|
+
};
|
|
15601
15409
|
|
|
15602
15410
|
/***/ }),
|
|
15603
15411
|
|
|
@@ -15614,39 +15422,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
15614
15422
|
/* harmony export */ });
|
|
15615
15423
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "react");
|
|
15616
15424
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
|
15425
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
15617
15426
|
|
|
15618
|
-
|
|
15619
|
-
|
|
15620
|
-
|
|
15621
|
-
|
|
15622
|
-
|
|
15623
|
-
this.index = 1;
|
|
15624
|
-
}
|
|
15625
|
-
portalRegister = () => {
|
|
15626
|
-
return ++this.index;
|
|
15627
|
-
};
|
|
15628
|
-
portalUpdate = (key, element) => {
|
|
15629
|
-
this.map[key] = element;
|
|
15630
|
-
this.forceUpdate();
|
|
15631
|
-
};
|
|
15632
|
-
portalDeregister = key => {
|
|
15633
|
-
delete this.map[key];
|
|
15634
|
-
this.forceUpdate();
|
|
15635
|
-
};
|
|
15636
|
-
getChildren() {
|
|
15637
|
-
return Object.keys(this.map).map(key => {
|
|
15638
|
-
const el = this.map[key];
|
|
15639
|
-
return el ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().cloneElement(el, {
|
|
15640
|
-
key
|
|
15641
|
-
}) : el;
|
|
15642
|
-
});
|
|
15643
|
-
}
|
|
15644
|
-
|
|
15645
|
-
// Overridden in victory-core-native
|
|
15646
|
-
render() {
|
|
15647
|
-
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", this.props, this.getChildren());
|
|
15648
|
-
}
|
|
15649
|
-
}
|
|
15427
|
+
const Portal = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef((props, ref) => {
|
|
15428
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", _extends({
|
|
15429
|
+
ref: ref
|
|
15430
|
+
}, props));
|
|
15431
|
+
});
|
|
15650
15432
|
|
|
15651
15433
|
/***/ }),
|
|
15652
15434
|
|
|
@@ -15673,59 +15455,44 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
15673
15455
|
|
|
15674
15456
|
|
|
15675
15457
|
|
|
15676
|
-
|
|
15677
|
-
|
|
15678
|
-
|
|
15679
|
-
|
|
15680
|
-
|
|
15458
|
+
const defaultProps = {
|
|
15459
|
+
groupComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement("g", null)
|
|
15460
|
+
};
|
|
15461
|
+
const VictoryPortal = initialProps => {
|
|
15462
|
+
const props = {
|
|
15463
|
+
...defaultProps,
|
|
15464
|
+
...initialProps
|
|
15681
15465
|
};
|
|
15682
|
-
|
|
15683
|
-
|
|
15684
|
-
|
|
15685
|
-
|
|
15686
|
-
|
|
15687
|
-
_victory_util_log__WEBPACK_IMPORTED_MODULE_3__.warn(msg);
|
|
15688
|
-
this.renderInPlace = true;
|
|
15689
|
-
}
|
|
15690
|
-
this.checkedContext = true;
|
|
15691
|
-
}
|
|
15692
|
-
this.forceUpdate();
|
|
15466
|
+
const id = react__WEBPACK_IMPORTED_MODULE_1___default().useId();
|
|
15467
|
+
const portalContext = (0,_portal_context__WEBPACK_IMPORTED_MODULE_2__.usePortalContext)();
|
|
15468
|
+
if (!portalContext) {
|
|
15469
|
+
const msg = "`renderInPortal` is not supported outside of `VictoryContainer`. " + "Component will be rendered in place";
|
|
15470
|
+
_victory_util_log__WEBPACK_IMPORTED_MODULE_3__.warn(msg);
|
|
15693
15471
|
}
|
|
15694
|
-
|
|
15695
|
-
|
|
15696
|
-
|
|
15697
|
-
|
|
15698
|
-
|
|
15699
|
-
|
|
15700
|
-
|
|
15701
|
-
|
|
15702
|
-
|
|
15703
|
-
|
|
15704
|
-
|
|
15705
|
-
|
|
15706
|
-
|
|
15707
|
-
|
|
15708
|
-
|
|
15709
|
-
|
|
15710
|
-
|
|
15711
|
-
|
|
15712
|
-
return
|
|
15713
|
-
|
|
15714
|
-
|
|
15715
|
-
|
|
15716
|
-
|
|
15717
|
-
|
|
15718
|
-
} = this.props;
|
|
15719
|
-
const childProps = children && children.props || {};
|
|
15720
|
-
const standardProps = childProps.groupComponent ? {
|
|
15721
|
-
groupComponent,
|
|
15722
|
-
standalone: false
|
|
15723
|
-
} : {};
|
|
15724
|
-
const newProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()(standardProps, childProps, _victory_util_helpers__WEBPACK_IMPORTED_MODULE_4__.omit(this.props, ["children", "groupComponent"]));
|
|
15725
|
-
const child = children && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(children, newProps);
|
|
15726
|
-
return this.renderPortal(child);
|
|
15727
|
-
}
|
|
15728
|
-
}
|
|
15472
|
+
const children = Array.isArray(props.children) ? props.children[0] : props.children;
|
|
15473
|
+
const {
|
|
15474
|
+
groupComponent
|
|
15475
|
+
} = props;
|
|
15476
|
+
const childProps = children && children.props || {};
|
|
15477
|
+
const standardProps = childProps.groupComponent ? {
|
|
15478
|
+
groupComponent,
|
|
15479
|
+
standalone: false
|
|
15480
|
+
} : {};
|
|
15481
|
+
const newProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()(standardProps, childProps, _victory_util_helpers__WEBPACK_IMPORTED_MODULE_4__.omit(props, ["children", "groupComponent"]), {
|
|
15482
|
+
key: childProps.key ?? id
|
|
15483
|
+
});
|
|
15484
|
+
const child = children && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(children, newProps);
|
|
15485
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(() => {
|
|
15486
|
+
portalContext?.addChild(id, child);
|
|
15487
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
15488
|
+
}, [props.children]);
|
|
15489
|
+
react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(() => {
|
|
15490
|
+
return () => portalContext?.removeChild(id);
|
|
15491
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
15492
|
+
}, []);
|
|
15493
|
+
return portalContext ? null : child;
|
|
15494
|
+
};
|
|
15495
|
+
VictoryPortal.role = "portal";
|
|
15729
15496
|
|
|
15730
15497
|
/***/ }),
|
|
15731
15498
|
|
|
@@ -20106,53 +19873,56 @@ function shallowToJS(x, whitelist) {
|
|
|
20106
19873
|
"use strict";
|
|
20107
19874
|
__webpack_require__.r(__webpack_exports__);
|
|
20108
19875
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
20109
|
-
/* harmony export */ "Axis": function() { return /* reexport module object */
|
|
20110
|
-
/* harmony export */ "Collection": function() { return /* reexport module object */
|
|
20111
|
-
/* harmony export */ "Data": function() { return /* reexport module object */
|
|
20112
|
-
/* harmony export */ "DefaultTransitions": function() { return /* reexport module object */
|
|
20113
|
-
/* harmony export */ "Domain": function() { return /* reexport module object */
|
|
20114
|
-
/* harmony export */ "Events": function() { return /* reexport module object */
|
|
20115
|
-
/* harmony export */ "Helpers": function() { return /* reexport module object */
|
|
20116
|
-
/* harmony export */ "Hooks": function() { return /* reexport module object */
|
|
20117
|
-
/* harmony export */ "Immutable": function() { return /* reexport module object */
|
|
20118
|
-
/* harmony export */ "LabelHelpers": function() { return /* reexport module object */
|
|
20119
|
-
/* harmony export */ "LineHelpers": function() { return /* reexport module object */
|
|
20120
|
-
/* harmony export */ "Log": function() { return /* reexport module object */
|
|
20121
|
-
/* harmony export */ "PointPathHelpers": function() { return /* reexport module object */
|
|
20122
|
-
/* harmony export */ "Scale": function() { return /* reexport module object */
|
|
20123
|
-
/* harmony export */ "Selection": function() { return /* reexport module object */
|
|
20124
|
-
/* harmony export */ "Style": function() { return /* reexport module object */
|
|
20125
|
-
/* harmony export */ "TextSize": function() { return /* reexport module object */
|
|
20126
|
-
/* harmony export */ "Timer": function() { return /* reexport safe */
|
|
20127
|
-
/* harmony export */ "TimerContext": function() { return /* reexport safe */
|
|
20128
|
-
/* harmony export */ "Transitions": function() { return /* reexport module object */
|
|
20129
|
-
/* harmony export */ "UserProps": function() { return /* reexport module object */
|
|
20130
|
-
/* harmony export */ "Wrapper": function() { return /* reexport module object */
|
|
20131
|
-
/* harmony export */ "addEvents": function() { return /* reexport safe */ _add_events__WEBPACK_IMPORTED_MODULE_0__.addEvents; }
|
|
19876
|
+
/* harmony export */ "Axis": function() { return /* reexport module object */ _axis__WEBPACK_IMPORTED_MODULE_2__; },
|
|
19877
|
+
/* harmony export */ "Collection": function() { return /* reexport module object */ _collection__WEBPACK_IMPORTED_MODULE_3__; },
|
|
19878
|
+
/* harmony export */ "Data": function() { return /* reexport module object */ _data__WEBPACK_IMPORTED_MODULE_4__; },
|
|
19879
|
+
/* harmony export */ "DefaultTransitions": function() { return /* reexport module object */ _default_transitions__WEBPACK_IMPORTED_MODULE_5__; },
|
|
19880
|
+
/* harmony export */ "Domain": function() { return /* reexport module object */ _domain__WEBPACK_IMPORTED_MODULE_6__; },
|
|
19881
|
+
/* harmony export */ "Events": function() { return /* reexport module object */ _events__WEBPACK_IMPORTED_MODULE_7__; },
|
|
19882
|
+
/* harmony export */ "Helpers": function() { return /* reexport module object */ _helpers__WEBPACK_IMPORTED_MODULE_8__; },
|
|
19883
|
+
/* harmony export */ "Hooks": function() { return /* reexport module object */ _hooks__WEBPACK_IMPORTED_MODULE_9__; },
|
|
19884
|
+
/* harmony export */ "Immutable": function() { return /* reexport module object */ _immutable__WEBPACK_IMPORTED_MODULE_10__; },
|
|
19885
|
+
/* harmony export */ "LabelHelpers": function() { return /* reexport module object */ _label_helpers__WEBPACK_IMPORTED_MODULE_11__; },
|
|
19886
|
+
/* harmony export */ "LineHelpers": function() { return /* reexport module object */ _line_helpers__WEBPACK_IMPORTED_MODULE_12__; },
|
|
19887
|
+
/* harmony export */ "Log": function() { return /* reexport module object */ _log__WEBPACK_IMPORTED_MODULE_13__; },
|
|
19888
|
+
/* harmony export */ "PointPathHelpers": function() { return /* reexport module object */ _point_path_helpers__WEBPACK_IMPORTED_MODULE_14__; },
|
|
19889
|
+
/* harmony export */ "Scale": function() { return /* reexport module object */ _scale__WEBPACK_IMPORTED_MODULE_15__; },
|
|
19890
|
+
/* harmony export */ "Selection": function() { return /* reexport module object */ _selection__WEBPACK_IMPORTED_MODULE_16__; },
|
|
19891
|
+
/* harmony export */ "Style": function() { return /* reexport module object */ _style__WEBPACK_IMPORTED_MODULE_17__; },
|
|
19892
|
+
/* harmony export */ "TextSize": function() { return /* reexport module object */ _textsize__WEBPACK_IMPORTED_MODULE_18__; },
|
|
19893
|
+
/* harmony export */ "Timer": function() { return /* reexport safe */ _timer__WEBPACK_IMPORTED_MODULE_19__["default"]; },
|
|
19894
|
+
/* harmony export */ "TimerContext": function() { return /* reexport safe */ _timer_context__WEBPACK_IMPORTED_MODULE_20__["default"]; },
|
|
19895
|
+
/* harmony export */ "Transitions": function() { return /* reexport module object */ _transitions__WEBPACK_IMPORTED_MODULE_21__; },
|
|
19896
|
+
/* harmony export */ "UserProps": function() { return /* reexport module object */ _user_props__WEBPACK_IMPORTED_MODULE_22__; },
|
|
19897
|
+
/* harmony export */ "Wrapper": function() { return /* reexport module object */ _wrapper__WEBPACK_IMPORTED_MODULE_23__; },
|
|
19898
|
+
/* harmony export */ "addEvents": function() { return /* reexport safe */ _add_events__WEBPACK_IMPORTED_MODULE_0__.addEvents; },
|
|
19899
|
+
/* harmony export */ "mergeRefs": function() { return /* reexport safe */ _merge_refs__WEBPACK_IMPORTED_MODULE_1__.mergeRefs; }
|
|
20132
19900
|
/* harmony export */ });
|
|
20133
19901
|
/* harmony import */ var _add_events__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./add-events */ "../../victory-core/es/victory-util/add-events.js");
|
|
20134
|
-
/* harmony import */ var
|
|
20135
|
-
/* harmony import */ var
|
|
20136
|
-
/* harmony import */ var
|
|
20137
|
-
/* harmony import */ var
|
|
20138
|
-
/* harmony import */ var
|
|
20139
|
-
/* harmony import */ var
|
|
20140
|
-
/* harmony import */ var
|
|
20141
|
-
/* harmony import */ var
|
|
20142
|
-
/* harmony import */ var
|
|
20143
|
-
/* harmony import */ var
|
|
20144
|
-
/* harmony import */ var
|
|
20145
|
-
/* harmony import */ var
|
|
20146
|
-
/* harmony import */ var
|
|
20147
|
-
/* harmony import */ var
|
|
20148
|
-
/* harmony import */ var
|
|
20149
|
-
/* harmony import */ var
|
|
20150
|
-
/* harmony import */ var
|
|
20151
|
-
/* harmony import */ var
|
|
20152
|
-
/* harmony import */ var
|
|
20153
|
-
/* harmony import */ var
|
|
20154
|
-
/* harmony import */ var
|
|
20155
|
-
/* harmony import */ var
|
|
19902
|
+
/* harmony import */ var _merge_refs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./merge-refs */ "../../victory-core/es/victory-util/merge-refs.js");
|
|
19903
|
+
/* harmony import */ var _axis__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./axis */ "../../victory-core/es/victory-util/axis.js");
|
|
19904
|
+
/* harmony import */ var _collection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./collection */ "../../victory-core/es/victory-util/collection.js");
|
|
19905
|
+
/* harmony import */ var _data__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./data */ "../../victory-core/es/victory-util/data.js");
|
|
19906
|
+
/* harmony import */ var _default_transitions__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./default-transitions */ "../../victory-core/es/victory-util/default-transitions.js");
|
|
19907
|
+
/* harmony import */ var _domain__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./domain */ "../../victory-core/es/victory-util/domain.js");
|
|
19908
|
+
/* harmony import */ var _events__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./events */ "../../victory-core/es/victory-util/events.js");
|
|
19909
|
+
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./helpers */ "../../victory-core/es/victory-util/helpers.js");
|
|
19910
|
+
/* harmony import */ var _hooks__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./hooks */ "../../victory-core/es/victory-util/hooks/index.js");
|
|
19911
|
+
/* harmony import */ var _immutable__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./immutable */ "../../victory-core/es/victory-util/immutable.js");
|
|
19912
|
+
/* harmony import */ var _label_helpers__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./label-helpers */ "../../victory-core/es/victory-util/label-helpers.js");
|
|
19913
|
+
/* harmony import */ var _line_helpers__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./line-helpers */ "../../victory-core/es/victory-util/line-helpers.js");
|
|
19914
|
+
/* harmony import */ var _log__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./log */ "../../victory-core/es/victory-util/log.js");
|
|
19915
|
+
/* harmony import */ var _point_path_helpers__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./point-path-helpers */ "../../victory-core/es/victory-util/point-path-helpers.js");
|
|
19916
|
+
/* harmony import */ var _scale__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./scale */ "../../victory-core/es/victory-util/scale.js");
|
|
19917
|
+
/* harmony import */ var _selection__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./selection */ "../../victory-core/es/victory-util/selection.js");
|
|
19918
|
+
/* harmony import */ var _style__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./style */ "../../victory-core/es/victory-util/style.js");
|
|
19919
|
+
/* harmony import */ var _textsize__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./textsize */ "../../victory-core/es/victory-util/textsize.js");
|
|
19920
|
+
/* harmony import */ var _timer__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./timer */ "../../victory-core/es/victory-util/timer.js");
|
|
19921
|
+
/* harmony import */ var _timer_context__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./timer-context */ "../../victory-core/es/victory-util/timer-context.js");
|
|
19922
|
+
/* harmony import */ var _transitions__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./transitions */ "../../victory-core/es/victory-util/transitions.js");
|
|
19923
|
+
/* harmony import */ var _user_props__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./user-props */ "../../victory-core/es/victory-util/user-props.js");
|
|
19924
|
+
/* harmony import */ var _wrapper__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./wrapper */ "../../victory-core/es/victory-util/wrapper.js");
|
|
19925
|
+
|
|
20156
19926
|
|
|
20157
19927
|
|
|
20158
19928
|
|
|
@@ -20545,6 +20315,44 @@ function warn(message) {
|
|
|
20545
20315
|
|
|
20546
20316
|
/***/ }),
|
|
20547
20317
|
|
|
20318
|
+
/***/ "../../victory-core/es/victory-util/merge-refs.js":
|
|
20319
|
+
/*!********************************************************!*\
|
|
20320
|
+
!*** ../../victory-core/es/victory-util/merge-refs.js ***!
|
|
20321
|
+
\********************************************************/
|
|
20322
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
20323
|
+
|
|
20324
|
+
"use strict";
|
|
20325
|
+
__webpack_require__.r(__webpack_exports__);
|
|
20326
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
20327
|
+
/* harmony export */ "mergeRefs": function() { return /* binding */ mergeRefs; }
|
|
20328
|
+
/* harmony export */ });
|
|
20329
|
+
/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./helpers */ "../../victory-core/es/victory-util/helpers.js");
|
|
20330
|
+
|
|
20331
|
+
/**
|
|
20332
|
+
* Used to merge multiple React refs into a single callback ref.
|
|
20333
|
+
*
|
|
20334
|
+
* @example
|
|
20335
|
+
* ```tsx
|
|
20336
|
+
* <div ref={mergeRefs([ref, forwardedRef])} />
|
|
20337
|
+
* ```
|
|
20338
|
+
*/
|
|
20339
|
+
function mergeRefs(refs) {
|
|
20340
|
+
return value => {
|
|
20341
|
+
refs.forEach(ref => {
|
|
20342
|
+
// If the ref is a function, it's a callback ref and we call it with the value.
|
|
20343
|
+
if (_helpers__WEBPACK_IMPORTED_MODULE_0__.isFunction(ref)) {
|
|
20344
|
+
ref(value);
|
|
20345
|
+
} else if (ref !== null && ref !== undefined) {
|
|
20346
|
+
// If the ref is an object (not null and not undefined), it's an object ref.
|
|
20347
|
+
// We assign the value to its 'current' property.
|
|
20348
|
+
ref.current = value;
|
|
20349
|
+
}
|
|
20350
|
+
});
|
|
20351
|
+
};
|
|
20352
|
+
}
|
|
20353
|
+
|
|
20354
|
+
/***/ }),
|
|
20355
|
+
|
|
20548
20356
|
/***/ "../../victory-core/es/victory-util/point-path-helpers.js":
|
|
20549
20357
|
/*!****************************************************************!*\
|
|
20550
20358
|
!*** ../../victory-core/es/victory-util/point-path-helpers.js ***!
|
|
@@ -22391,28 +22199,25 @@ function getCategories(props, childComponents, allStrings) {
|
|
|
22391
22199
|
"use strict";
|
|
22392
22200
|
__webpack_require__.r(__webpack_exports__);
|
|
22393
22201
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
22394
|
-
/* harmony export */ "combineContainerMixins": function() { return /* binding */ combineContainerMixins; },
|
|
22395
22202
|
/* harmony export */ "createContainer": function() { return /* binding */ createContainer; },
|
|
22396
22203
|
/* harmony export */ "makeCreateContainerFunction": function() { return /* binding */ makeCreateContainerFunction; }
|
|
22397
22204
|
/* harmony export */ });
|
|
22398
|
-
/* harmony import */ var
|
|
22399
|
-
/* harmony import */ var
|
|
22400
|
-
/* harmony import */ var
|
|
22401
|
-
/* harmony import */ var
|
|
22402
|
-
/* harmony import */ var
|
|
22403
|
-
/* harmony import */ var
|
|
22404
|
-
/* harmony import */ var
|
|
22405
|
-
/* harmony import */ var
|
|
22406
|
-
/* harmony import */ var
|
|
22407
|
-
/* harmony import */ var
|
|
22408
|
-
/* harmony import */ var
|
|
22409
|
-
/* harmony import */ var
|
|
22410
|
-
/* harmony import */ var
|
|
22411
|
-
/* harmony import */ var
|
|
22412
|
-
/* harmony import */ var
|
|
22413
|
-
/* harmony import */ var
|
|
22414
|
-
/* harmony import */ var victory_brush_container__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! victory-brush-container */ "../../victory-brush-container/es/victory-brush-container.js");
|
|
22415
|
-
/* harmony import */ var victory_cursor_container__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! victory-cursor-container */ "../../victory-cursor-container/es/victory-cursor-container.js");
|
|
22205
|
+
/* harmony import */ var lodash_toPairs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/toPairs */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/toPairs.js");
|
|
22206
|
+
/* harmony import */ var lodash_toPairs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_toPairs__WEBPACK_IMPORTED_MODULE_0__);
|
|
22207
|
+
/* 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");
|
|
22208
|
+
/* harmony import */ var lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1__);
|
|
22209
|
+
/* harmony import */ var lodash_groupBy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! lodash/groupBy */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/groupBy.js");
|
|
22210
|
+
/* harmony import */ var lodash_groupBy__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash_groupBy__WEBPACK_IMPORTED_MODULE_2__);
|
|
22211
|
+
/* harmony import */ var lodash_forOwn__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! lodash/forOwn */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/forOwn.js");
|
|
22212
|
+
/* harmony import */ var lodash_forOwn__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash_forOwn__WEBPACK_IMPORTED_MODULE_3__);
|
|
22213
|
+
/* harmony import */ var victory_zoom_container__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-zoom-container */ "../../victory-zoom-container/es/victory-zoom-container.js");
|
|
22214
|
+
/* harmony import */ var victory_selection_container__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! victory-selection-container */ "../../victory-selection-container/es/victory-selection-container.js");
|
|
22215
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react */ "react");
|
|
22216
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_4__);
|
|
22217
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
22218
|
+
/* harmony import */ var victory_voronoi_container__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! victory-voronoi-container */ "../../victory-voronoi-container/es/victory-voronoi-container.js");
|
|
22219
|
+
/* harmony import */ var victory_cursor_container__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! victory-cursor-container */ "../../victory-cursor-container/es/victory-cursor-container.js");
|
|
22220
|
+
/* harmony import */ var victory_brush_container__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! victory-brush-container */ "../../victory-brush-container/es/victory-brush-container.js");
|
|
22416
22221
|
|
|
22417
22222
|
|
|
22418
22223
|
|
|
@@ -22436,7 +22241,7 @@ const combineEventHandlers = eventHandlersArray => {
|
|
|
22436
22241
|
// takes an array of event handler objects and produces one eventHandlers object
|
|
22437
22242
|
// creates a custom combinedHandler() for events with multiple conflicting handlers
|
|
22438
22243
|
return eventHandlersArray.reduce((localHandlers, finalHandlers) => {
|
|
22439
|
-
|
|
22244
|
+
lodash_forOwn__WEBPACK_IMPORTED_MODULE_3___default()(localHandlers, (localHandler, eventName) => {
|
|
22440
22245
|
const existingHandler = finalHandlers[eventName];
|
|
22441
22246
|
if (existingHandler) {
|
|
22442
22247
|
// create new handler for event that concats the existing handler's mutations with new ones
|
|
@@ -22457,11 +22262,11 @@ const combineEventHandlers = eventHandlersArray => {
|
|
|
22457
22262
|
const combineDefaultEvents = defaultEvents => {
|
|
22458
22263
|
// takes a defaultEvents array and returns one equal or lesser length,
|
|
22459
22264
|
// by combining any events that have the same target
|
|
22460
|
-
const eventsByTarget =
|
|
22461
|
-
const events =
|
|
22265
|
+
const eventsByTarget = lodash_groupBy__WEBPACK_IMPORTED_MODULE_2___default()(defaultEvents, "target");
|
|
22266
|
+
const events = lodash_toPairs__WEBPACK_IMPORTED_MODULE_0___default()(eventsByTarget).map(_ref => {
|
|
22462
22267
|
let [target, eventsArray] = _ref;
|
|
22463
22268
|
const newEventsArray = eventsArray.filter(Boolean);
|
|
22464
|
-
return
|
|
22269
|
+
return lodash_isEmpty__WEBPACK_IMPORTED_MODULE_1___default()(newEventsArray) ? null : {
|
|
22465
22270
|
target,
|
|
22466
22271
|
eventHandlers: combineEventHandlers(eventsArray.map(event => event.eventHandlers))
|
|
22467
22272
|
// note: does not currently handle eventKey or childName
|
|
@@ -22469,68 +22274,58 @@ const combineDefaultEvents = defaultEvents => {
|
|
|
22469
22274
|
});
|
|
22470
22275
|
return events.filter(Boolean);
|
|
22471
22276
|
};
|
|
22472
|
-
|
|
22473
|
-
|
|
22474
|
-
|
|
22475
|
-
|
|
22476
|
-
|
|
22477
|
-
|
|
22478
|
-
|
|
22479
|
-
|
|
22480
|
-
|
|
22481
|
-
|
|
22482
|
-
|
|
22483
|
-
|
|
22484
|
-
|
|
22485
|
-
|
|
22486
|
-
|
|
22487
|
-
|
|
22488
|
-
|
|
22489
|
-
|
|
22490
|
-
|
|
22491
|
-
|
|
22492
|
-
|
|
22493
|
-
|
|
22494
|
-
|
|
22495
|
-
|
|
22496
|
-
|
|
22497
|
-
|
|
22498
|
-
|
|
22499
|
-
|
|
22500
|
-
|
|
22501
|
-
|
|
22502
|
-
|
|
22503
|
-
|
|
22504
|
-
|
|
22505
|
-
|
|
22506
|
-
|
|
22507
|
-
};
|
|
22508
|
-
const
|
|
22509
|
-
|
|
22510
|
-
|
|
22511
|
-
|
|
22512
|
-
|
|
22513
|
-
|
|
22514
|
-
|
|
22515
|
-
|
|
22516
|
-
|
|
22517
|
-
|
|
22518
|
-
|
|
22519
|
-
|
|
22520
|
-
|
|
22521
|
-
|
|
22522
|
-
|
|
22523
|
-
|
|
22524
|
-
}
|
|
22525
|
-
return combineContainerMixins([...firstMixins, ...secondMixins], Container);
|
|
22526
|
-
};
|
|
22527
|
-
const createContainer = makeCreateContainerFunction({
|
|
22528
|
-
zoom: [victory_zoom_container__WEBPACK_IMPORTED_MODULE_7__.zoomContainerMixin],
|
|
22529
|
-
voronoi: [victory_voronoi_container__WEBPACK_IMPORTED_MODULE_8__.voronoiContainerMixin],
|
|
22530
|
-
selection: [victory_selection_container__WEBPACK_IMPORTED_MODULE_9__.selectionContainerMixin],
|
|
22531
|
-
cursor: [victory_cursor_container__WEBPACK_IMPORTED_MODULE_10__.cursorContainerMixin],
|
|
22532
|
-
brush: [victory_brush_container__WEBPACK_IMPORTED_MODULE_11__.brushContainerMixin]
|
|
22533
|
-
}, victory_core__WEBPACK_IMPORTED_MODULE_12__.VictoryContainer);
|
|
22277
|
+
/**
|
|
22278
|
+
* Container hooks are used to provide the container logic to the container components through props and a modified children object
|
|
22279
|
+
* - These hooks contain shared logic for both web and Victory Native containers.
|
|
22280
|
+
* - In this utility, we call multiple of these hooks with the props returned by the previous to combine the container logic.
|
|
22281
|
+
*/
|
|
22282
|
+
const CONTAINER_HOOKS = {
|
|
22283
|
+
zoom: victory_zoom_container__WEBPACK_IMPORTED_MODULE_5__.useVictoryZoomContainer,
|
|
22284
|
+
selection: victory_selection_container__WEBPACK_IMPORTED_MODULE_6__.useVictorySelectionContainer,
|
|
22285
|
+
brush: victory_brush_container__WEBPACK_IMPORTED_MODULE_7__.useVictoryBrushContainer,
|
|
22286
|
+
cursor: victory_cursor_container__WEBPACK_IMPORTED_MODULE_8__.useVictoryCursorContainer,
|
|
22287
|
+
voronoi: victory_voronoi_container__WEBPACK_IMPORTED_MODULE_9__.useVictoryVoronoiContainer
|
|
22288
|
+
};
|
|
22289
|
+
|
|
22290
|
+
/**
|
|
22291
|
+
* Container hooks are wrappers that return a VictoryContainer with the props provided by their respective hooks, and the modified children.
|
|
22292
|
+
* - These containers are specific to the web. Victory Native has its own container components.
|
|
22293
|
+
* - For this utility, we only need the container components to extract the defaultEvents.
|
|
22294
|
+
*/
|
|
22295
|
+
const CONTAINER_COMPONENTS_WEB = {
|
|
22296
|
+
zoom: victory_zoom_container__WEBPACK_IMPORTED_MODULE_5__.VictoryZoomContainer,
|
|
22297
|
+
selection: victory_selection_container__WEBPACK_IMPORTED_MODULE_6__.VictorySelectionContainer,
|
|
22298
|
+
brush: victory_brush_container__WEBPACK_IMPORTED_MODULE_7__.VictoryBrushContainer,
|
|
22299
|
+
cursor: victory_cursor_container__WEBPACK_IMPORTED_MODULE_8__.VictoryCursorContainer,
|
|
22300
|
+
voronoi: victory_voronoi_container__WEBPACK_IMPORTED_MODULE_9__.VictoryVoronoiContainer
|
|
22301
|
+
};
|
|
22302
|
+
function makeCreateContainerFunction(containerComponents, VictoryContainerBase) {
|
|
22303
|
+
return function combineContainers(containerA, containerB) {
|
|
22304
|
+
const ContainerA = containerComponents[containerA];
|
|
22305
|
+
const ContainerB = containerComponents[containerB];
|
|
22306
|
+
const useContainerA = CONTAINER_HOOKS[containerA];
|
|
22307
|
+
const useContainerB = CONTAINER_HOOKS[containerB];
|
|
22308
|
+
const CombinedContainer = props => {
|
|
22309
|
+
const {
|
|
22310
|
+
children: childrenA,
|
|
22311
|
+
props: propsA
|
|
22312
|
+
} = useContainerA(props);
|
|
22313
|
+
const {
|
|
22314
|
+
children: combinedChildren,
|
|
22315
|
+
props: combinedProps
|
|
22316
|
+
} = useContainerB({
|
|
22317
|
+
...propsA,
|
|
22318
|
+
children: childrenA
|
|
22319
|
+
});
|
|
22320
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_4___default().createElement(VictoryContainerBase, combinedProps, combinedChildren);
|
|
22321
|
+
};
|
|
22322
|
+
CombinedContainer.displayName = `Victory${containerA}${containerB}Container`;
|
|
22323
|
+
CombinedContainer.role = "container";
|
|
22324
|
+
CombinedContainer.defaultEvents = props => combineDefaultEvents([...ContainerA.defaultEvents(props), ...ContainerB.defaultEvents(props)]);
|
|
22325
|
+
return CombinedContainer;
|
|
22326
|
+
};
|
|
22327
|
+
}
|
|
22328
|
+
const createContainer = makeCreateContainerFunction(CONTAINER_COMPONENTS_WEB, victory_core__WEBPACK_IMPORTED_MODULE_10__.VictoryContainer);
|
|
22534
22329
|
|
|
22535
22330
|
/***/ }),
|
|
22536
22331
|
|
|
@@ -22543,7 +22338,6 @@ const createContainer = makeCreateContainerFunction({
|
|
|
22543
22338
|
"use strict";
|
|
22544
22339
|
__webpack_require__.r(__webpack_exports__);
|
|
22545
22340
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
22546
|
-
/* harmony export */ "combineContainerMixins": function() { return /* reexport safe */ _create_container__WEBPACK_IMPORTED_MODULE_0__.combineContainerMixins; },
|
|
22547
22341
|
/* harmony export */ "createContainer": function() { return /* reexport safe */ _create_container__WEBPACK_IMPORTED_MODULE_0__.createContainer; },
|
|
22548
22342
|
/* harmony export */ "makeCreateContainerFunction": function() { return /* reexport safe */ _create_container__WEBPACK_IMPORTED_MODULE_0__.makeCreateContainerFunction; }
|
|
22549
22343
|
/* harmony export */ });
|
|
@@ -22681,8 +22475,9 @@ const CursorHelpers = new CursorHelpersClass();
|
|
|
22681
22475
|
__webpack_require__.r(__webpack_exports__);
|
|
22682
22476
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
22683
22477
|
/* harmony export */ "CursorHelpers": function() { return /* reexport safe */ _cursor_helpers__WEBPACK_IMPORTED_MODULE_0__.CursorHelpers; },
|
|
22478
|
+
/* harmony export */ "VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ _victory_cursor_container__WEBPACK_IMPORTED_MODULE_1__.VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS; },
|
|
22684
22479
|
/* harmony export */ "VictoryCursorContainer": function() { return /* reexport safe */ _victory_cursor_container__WEBPACK_IMPORTED_MODULE_1__.VictoryCursorContainer; },
|
|
22685
|
-
/* harmony export */ "
|
|
22480
|
+
/* harmony export */ "useVictoryCursorContainer": function() { return /* reexport safe */ _victory_cursor_container__WEBPACK_IMPORTED_MODULE_1__.useVictoryCursorContainer; }
|
|
22686
22481
|
/* harmony export */ });
|
|
22687
22482
|
/* harmony import */ var _cursor_helpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./cursor-helpers */ "../../victory-cursor-container/es/cursor-helpers.js");
|
|
22688
22483
|
/* harmony import */ var _victory_cursor_container__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./victory-cursor-container */ "../../victory-cursor-container/es/victory-cursor-container.js");
|
|
@@ -22700,8 +22495,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
22700
22495
|
"use strict";
|
|
22701
22496
|
__webpack_require__.r(__webpack_exports__);
|
|
22702
22497
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
22498
|
+
/* harmony export */ "VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS": function() { return /* binding */ VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS; },
|
|
22703
22499
|
/* harmony export */ "VictoryCursorContainer": function() { return /* binding */ VictoryCursorContainer; },
|
|
22704
|
-
/* harmony export */ "
|
|
22500
|
+
/* harmony export */ "useVictoryCursorContainer": function() { return /* binding */ useVictoryCursorContainer; }
|
|
22705
22501
|
/* harmony export */ });
|
|
22706
22502
|
/* harmony import */ var lodash_isObject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/isObject */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObject.js");
|
|
22707
22503
|
/* harmony import */ var lodash_isObject__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_isObject__WEBPACK_IMPORTED_MODULE_0__);
|
|
@@ -22709,164 +22505,179 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
22709
22505
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_1__);
|
|
22710
22506
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react */ "react");
|
|
22711
22507
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);
|
|
22712
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
22713
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
22714
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
22715
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
22508
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-label/victory-label.js");
|
|
22509
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-primitives/line-segment.js");
|
|
22510
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-util/helpers.js");
|
|
22511
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
22716
22512
|
/* harmony import */ var _cursor_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./cursor-helpers */ "../../victory-cursor-container/es/cursor-helpers.js");
|
|
22717
22513
|
|
|
22718
22514
|
|
|
22515
|
+
/* eslint-disable complexity */
|
|
22719
22516
|
|
|
22720
22517
|
|
|
22721
22518
|
|
|
22722
|
-
|
|
22723
|
-
|
|
22724
|
-
|
|
22725
|
-
|
|
22726
|
-
|
|
22727
|
-
|
|
22728
|
-
|
|
22729
|
-
|
|
22730
|
-
|
|
22731
|
-
|
|
22732
|
-
|
|
22733
|
-
|
|
22734
|
-
|
|
22735
|
-
|
|
22736
|
-
|
|
22737
|
-
|
|
22738
|
-
|
|
22739
|
-
|
|
22740
|
-
|
|
22741
|
-
|
|
22742
|
-
|
|
22743
|
-
|
|
22744
|
-
|
|
22745
|
-
|
|
22746
|
-
|
|
22747
|
-
},
|
|
22748
|
-
onTouchMove: (evt, targetProps) => {
|
|
22749
|
-
return props.disable ? {} : _cursor_helpers__WEBPACK_IMPORTED_MODULE_6__.CursorHelpers.onMouseMove(evt, targetProps);
|
|
22750
|
-
}
|
|
22751
|
-
}
|
|
22752
|
-
}];
|
|
22519
|
+
const VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS = {
|
|
22520
|
+
cursorLabelComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_3__.VictoryLabel, null),
|
|
22521
|
+
cursorLabelOffset: {
|
|
22522
|
+
x: 5,
|
|
22523
|
+
y: -10
|
|
22524
|
+
},
|
|
22525
|
+
cursorComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_4__.LineSegment, null)
|
|
22526
|
+
};
|
|
22527
|
+
const useVictoryCursorContainer = initialProps => {
|
|
22528
|
+
const props = {
|
|
22529
|
+
...VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS,
|
|
22530
|
+
...initialProps
|
|
22531
|
+
};
|
|
22532
|
+
const {
|
|
22533
|
+
children
|
|
22534
|
+
} = props;
|
|
22535
|
+
const getCursorPosition = () => {
|
|
22536
|
+
const {
|
|
22537
|
+
cursorValue,
|
|
22538
|
+
defaultCursorValue,
|
|
22539
|
+
domain,
|
|
22540
|
+
cursorDimension
|
|
22541
|
+
} = props;
|
|
22542
|
+
if (cursorValue) {
|
|
22543
|
+
return cursorValue;
|
|
22753
22544
|
}
|
|
22754
|
-
|
|
22755
|
-
|
|
22756
|
-
|
|
22757
|
-
|
|
22758
|
-
|
|
22759
|
-
cursorDimension
|
|
22760
|
-
} = props;
|
|
22761
|
-
if (cursorValue) {
|
|
22762
|
-
return cursorValue;
|
|
22763
|
-
}
|
|
22764
|
-
if (typeof defaultCursorValue === "number") {
|
|
22765
|
-
return {
|
|
22766
|
-
x: (domain.x[0] + domain.x[1]) / 2,
|
|
22767
|
-
y: (domain.y[0] + domain.y[1]) / 2,
|
|
22545
|
+
if (typeof defaultCursorValue === "number") {
|
|
22546
|
+
return {
|
|
22547
|
+
x: (domain.x[0] + domain.x[1]) / 2,
|
|
22548
|
+
y: (domain.y[0] + domain.y[1]) / 2,
|
|
22549
|
+
...(cursorDimension ? {
|
|
22768
22550
|
[cursorDimension]: defaultCursorValue
|
|
22769
|
-
}
|
|
22770
|
-
}
|
|
22771
|
-
return defaultCursorValue;
|
|
22551
|
+
} : {})
|
|
22552
|
+
};
|
|
22772
22553
|
}
|
|
22773
|
-
|
|
22774
|
-
|
|
22775
|
-
|
|
22776
|
-
|
|
22777
|
-
|
|
22778
|
-
|
|
22779
|
-
|
|
22780
|
-
|
|
22781
|
-
|
|
22782
|
-
|
|
22783
|
-
|
|
22554
|
+
return defaultCursorValue;
|
|
22555
|
+
};
|
|
22556
|
+
const getCursorLabelOffset = () => {
|
|
22557
|
+
const {
|
|
22558
|
+
cursorLabelOffset
|
|
22559
|
+
} = props;
|
|
22560
|
+
if (typeof cursorLabelOffset === "number") {
|
|
22561
|
+
return {
|
|
22562
|
+
x: cursorLabelOffset,
|
|
22563
|
+
y: cursorLabelOffset
|
|
22564
|
+
};
|
|
22784
22565
|
}
|
|
22785
|
-
|
|
22786
|
-
|
|
22787
|
-
|
|
22788
|
-
|
|
22789
|
-
|
|
22790
|
-
return
|
|
22791
|
-
}
|
|
22792
|
-
return
|
|
22566
|
+
return cursorLabelOffset;
|
|
22567
|
+
};
|
|
22568
|
+
const getPadding = () => {
|
|
22569
|
+
if (props.padding === undefined) {
|
|
22570
|
+
const child = Array.isArray(props.children) ? props.children.find(c => {
|
|
22571
|
+
return lodash_isObject__WEBPACK_IMPORTED_MODULE_0___default()(c.props) && c.props.padding !== undefined;
|
|
22572
|
+
}) : props.children;
|
|
22573
|
+
return victory_core__WEBPACK_IMPORTED_MODULE_5__.getPadding(child?.props);
|
|
22793
22574
|
}
|
|
22794
|
-
|
|
22795
|
-
|
|
22796
|
-
|
|
22797
|
-
|
|
22798
|
-
|
|
22799
|
-
|
|
22800
|
-
|
|
22801
|
-
|
|
22802
|
-
|
|
22803
|
-
|
|
22804
|
-
|
|
22805
|
-
|
|
22806
|
-
|
|
22807
|
-
|
|
22808
|
-
|
|
22809
|
-
|
|
22810
|
-
|
|
22811
|
-
|
|
22812
|
-
|
|
22813
|
-
|
|
22814
|
-
const padding = this.getPadding(props);
|
|
22815
|
-
const cursorCoordinates = {
|
|
22816
|
-
x: horizontal ? scale.y(cursorValue.y) : scale.x(cursorValue.x),
|
|
22817
|
-
y: horizontal ? scale.x(cursorValue.x) : scale.y(cursorValue.y)
|
|
22818
|
-
};
|
|
22819
|
-
if (cursorLabel) {
|
|
22820
|
-
let labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({
|
|
22821
|
-
active: true
|
|
22822
|
-
}, cursorLabelComponent.props, {
|
|
22823
|
-
x: cursorCoordinates.x + cursorLabelOffset.x,
|
|
22824
|
-
y: cursorCoordinates.y + cursorLabelOffset.y,
|
|
22825
|
-
datum: cursorValue,
|
|
22826
|
-
active: true,
|
|
22827
|
-
key: `${name}-cursor-label`
|
|
22828
|
-
});
|
|
22829
|
-
if (victory_core__WEBPACK_IMPORTED_MODULE_7__.isTooltip(cursorLabelComponent)) {
|
|
22830
|
-
const tooltipTheme = theme && theme.tooltip || {};
|
|
22831
|
-
labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps, tooltipTheme);
|
|
22832
|
-
}
|
|
22833
|
-
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorLabelComponent, lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps, {
|
|
22834
|
-
text: victory_core__WEBPACK_IMPORTED_MODULE_7__.evaluateProp(cursorLabel, labelProps)
|
|
22835
|
-
})));
|
|
22836
|
-
}
|
|
22837
|
-
const cursorStyle = Object.assign({
|
|
22838
|
-
stroke: "black"
|
|
22839
|
-
}, cursorComponent.props.style);
|
|
22840
|
-
if (cursorDimension === "x" || cursorDimension === undefined) {
|
|
22841
|
-
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorComponent, {
|
|
22842
|
-
key: `${name}-x-cursor`,
|
|
22843
|
-
x1: cursorCoordinates.x,
|
|
22844
|
-
x2: cursorCoordinates.x,
|
|
22845
|
-
y1: padding.top,
|
|
22846
|
-
y2: height - padding.bottom,
|
|
22847
|
-
style: cursorStyle
|
|
22848
|
-
}));
|
|
22849
|
-
}
|
|
22850
|
-
if (cursorDimension === "y" || cursorDimension === undefined) {
|
|
22851
|
-
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorComponent, {
|
|
22852
|
-
key: `${name}-y-cursor`,
|
|
22853
|
-
x1: padding.left,
|
|
22854
|
-
x2: width - padding.right,
|
|
22855
|
-
y1: cursorCoordinates.y,
|
|
22856
|
-
y2: cursorCoordinates.y,
|
|
22857
|
-
style: cursorStyle
|
|
22858
|
-
}));
|
|
22859
|
-
}
|
|
22860
|
-
return newElements;
|
|
22575
|
+
return victory_core__WEBPACK_IMPORTED_MODULE_5__.getPadding(props);
|
|
22576
|
+
};
|
|
22577
|
+
const getCursorElements = () => {
|
|
22578
|
+
// eslint-disable-line max-statements
|
|
22579
|
+
const {
|
|
22580
|
+
scale,
|
|
22581
|
+
cursorLabelComponent,
|
|
22582
|
+
cursorLabel,
|
|
22583
|
+
cursorComponent,
|
|
22584
|
+
width,
|
|
22585
|
+
height,
|
|
22586
|
+
name,
|
|
22587
|
+
horizontal,
|
|
22588
|
+
theme
|
|
22589
|
+
} = props;
|
|
22590
|
+
const cursorDimension = _cursor_helpers__WEBPACK_IMPORTED_MODULE_6__.CursorHelpers.getDimension(props);
|
|
22591
|
+
const cursorValue = getCursorPosition();
|
|
22592
|
+
const cursorLabelOffset = getCursorLabelOffset();
|
|
22593
|
+
if (!cursorValue) {
|
|
22594
|
+
return [];
|
|
22861
22595
|
}
|
|
22862
|
-
|
|
22863
|
-
|
|
22864
|
-
|
|
22865
|
-
|
|
22596
|
+
const newElements = [];
|
|
22597
|
+
const padding = getPadding();
|
|
22598
|
+
const cursorCoordinates = scale && "x" in scale && "y" in scale && typeof scale.y === "function" && typeof scale.x === "function" ? {
|
|
22599
|
+
x: horizontal ? scale.y(cursorValue.y) : scale.x(cursorValue.x),
|
|
22600
|
+
y: horizontal ? scale.x(cursorValue.x) : scale.y(cursorValue.y)
|
|
22601
|
+
} : {
|
|
22602
|
+
x: cursorValue.x,
|
|
22603
|
+
y: cursorValue.y
|
|
22604
|
+
};
|
|
22605
|
+
if (cursorLabel) {
|
|
22606
|
+
let labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({
|
|
22607
|
+
active: true
|
|
22608
|
+
}, cursorLabelComponent.props, {
|
|
22609
|
+
x: cursorCoordinates.x + cursorLabelOffset.x,
|
|
22610
|
+
y: cursorCoordinates.y + cursorLabelOffset.y,
|
|
22611
|
+
datum: cursorValue,
|
|
22612
|
+
active: true,
|
|
22613
|
+
key: `${name}-cursor-label`
|
|
22614
|
+
});
|
|
22615
|
+
if (victory_core__WEBPACK_IMPORTED_MODULE_5__.isTooltip(cursorLabelComponent)) {
|
|
22616
|
+
const tooltipTheme = theme && theme.tooltip || {};
|
|
22617
|
+
labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps, tooltipTheme);
|
|
22618
|
+
}
|
|
22619
|
+
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorLabelComponent, lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps, {
|
|
22620
|
+
text: victory_core__WEBPACK_IMPORTED_MODULE_5__.evaluateProp(cursorLabel, labelProps)
|
|
22621
|
+
})));
|
|
22866
22622
|
}
|
|
22623
|
+
const cursorStyle = Object.assign({
|
|
22624
|
+
stroke: "black"
|
|
22625
|
+
}, cursorComponent.props.style);
|
|
22626
|
+
if (cursorDimension === "x" || cursorDimension === undefined) {
|
|
22627
|
+
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorComponent, {
|
|
22628
|
+
key: `${name}-x-cursor`,
|
|
22629
|
+
x1: cursorCoordinates.x,
|
|
22630
|
+
x2: cursorCoordinates.x,
|
|
22631
|
+
y1: padding.top,
|
|
22632
|
+
y2: (typeof height === "number" ? height : 0) - padding.bottom,
|
|
22633
|
+
style: cursorStyle
|
|
22634
|
+
}));
|
|
22635
|
+
}
|
|
22636
|
+
if (cursorDimension === "y" || cursorDimension === undefined) {
|
|
22637
|
+
newElements.push( /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(cursorComponent, {
|
|
22638
|
+
key: `${name}-y-cursor`,
|
|
22639
|
+
x1: padding.left,
|
|
22640
|
+
x2: (typeof width === "number" ? width : 0) - padding.right,
|
|
22641
|
+
y1: cursorCoordinates.y,
|
|
22642
|
+
y2: cursorCoordinates.y,
|
|
22643
|
+
style: cursorStyle
|
|
22644
|
+
}));
|
|
22645
|
+
}
|
|
22646
|
+
return newElements;
|
|
22867
22647
|
};
|
|
22868
|
-
|
|
22869
|
-
|
|
22648
|
+
return {
|
|
22649
|
+
props,
|
|
22650
|
+
children: [...react__WEBPACK_IMPORTED_MODULE_2___default().Children.toArray(children), ...getCursorElements()]
|
|
22651
|
+
};
|
|
22652
|
+
};
|
|
22653
|
+
const VictoryCursorContainer = initialProps => {
|
|
22654
|
+
const {
|
|
22655
|
+
props,
|
|
22656
|
+
children
|
|
22657
|
+
} = useVictoryCursorContainer(initialProps);
|
|
22658
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_7__.VictoryContainer, props, children);
|
|
22659
|
+
};
|
|
22660
|
+
VictoryCursorContainer.role = "container";
|
|
22661
|
+
VictoryCursorContainer.defaultEvents = initialProps => {
|
|
22662
|
+
const props = {
|
|
22663
|
+
...VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS,
|
|
22664
|
+
...initialProps
|
|
22665
|
+
};
|
|
22666
|
+
const createEventHandler = (handler, disabled) =>
|
|
22667
|
+
// eslint-disable-next-line max-params
|
|
22668
|
+
(event, targetProps, eventKey, context) => disabled || props.disable ? {} : handler(event, {
|
|
22669
|
+
...props,
|
|
22670
|
+
...targetProps
|
|
22671
|
+
}, eventKey, context);
|
|
22672
|
+
return [{
|
|
22673
|
+
target: "parent",
|
|
22674
|
+
eventHandlers: {
|
|
22675
|
+
onMouseLeave: createEventHandler(_cursor_helpers__WEBPACK_IMPORTED_MODULE_6__.CursorHelpers.onMouseLeave),
|
|
22676
|
+
onMouseMove: createEventHandler(_cursor_helpers__WEBPACK_IMPORTED_MODULE_6__.CursorHelpers.onMouseMove),
|
|
22677
|
+
onTouchMove: createEventHandler(_cursor_helpers__WEBPACK_IMPORTED_MODULE_6__.CursorHelpers.onMouseMove)
|
|
22678
|
+
}
|
|
22679
|
+
}];
|
|
22680
|
+
};
|
|
22870
22681
|
|
|
22871
22682
|
/***/ }),
|
|
22872
22683
|
|
|
@@ -26618,8 +26429,9 @@ const VictoryScatter = (0,victory_core__WEBPACK_IMPORTED_MODULE_11__.addEvents)(
|
|
|
26618
26429
|
__webpack_require__.r(__webpack_exports__);
|
|
26619
26430
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
26620
26431
|
/* harmony export */ "SelectionHelpers": function() { return /* reexport safe */ _selection_helpers__WEBPACK_IMPORTED_MODULE_1__.SelectionHelpers; },
|
|
26432
|
+
/* harmony export */ "VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ _victory_selection_container__WEBPACK_IMPORTED_MODULE_0__.VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS; },
|
|
26621
26433
|
/* harmony export */ "VictorySelectionContainer": function() { return /* reexport safe */ _victory_selection_container__WEBPACK_IMPORTED_MODULE_0__.VictorySelectionContainer; },
|
|
26622
|
-
/* harmony export */ "
|
|
26434
|
+
/* harmony export */ "useVictorySelectionContainer": function() { return /* reexport safe */ _victory_selection_container__WEBPACK_IMPORTED_MODULE_0__.useVictorySelectionContainer; }
|
|
26623
26435
|
/* harmony export */ });
|
|
26624
26436
|
/* harmony import */ var _victory_selection_container__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./victory-selection-container */ "../../victory-selection-container/es/victory-selection-container.js");
|
|
26625
26437
|
/* harmony import */ var _selection_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./selection-helpers */ "../../victory-selection-container/es/selection-helpers.js");
|
|
@@ -26880,88 +26692,91 @@ const SelectionHelpers = new SelectionHelpersClass();
|
|
|
26880
26692
|
"use strict";
|
|
26881
26693
|
__webpack_require__.r(__webpack_exports__);
|
|
26882
26694
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
26695
|
+
/* harmony export */ "VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS": function() { return /* binding */ VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS; },
|
|
26883
26696
|
/* harmony export */ "VictorySelectionContainer": function() { return /* binding */ VictorySelectionContainer; },
|
|
26884
|
-
/* harmony export */ "
|
|
26697
|
+
/* harmony export */ "useVictorySelectionContainer": function() { return /* binding */ useVictorySelectionContainer; }
|
|
26885
26698
|
/* harmony export */ });
|
|
26886
26699
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "react");
|
|
26887
26700
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
|
26888
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
26889
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
26701
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-primitives/rect.js");
|
|
26702
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
26890
26703
|
/* harmony import */ var _selection_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./selection-helpers */ "../../victory-selection-container/es/selection-helpers.js");
|
|
26891
26704
|
|
|
26892
26705
|
|
|
26893
26706
|
|
|
26894
|
-
|
|
26895
|
-
|
|
26896
|
-
|
|
26897
|
-
|
|
26898
|
-
|
|
26899
|
-
|
|
26900
|
-
|
|
26901
|
-
|
|
26902
|
-
|
|
26903
|
-
|
|
26904
|
-
|
|
26905
|
-
|
|
26906
|
-
|
|
26907
|
-
|
|
26908
|
-
};
|
|
26909
|
-
static defaultEvents(props) {
|
|
26910
|
-
return [{
|
|
26911
|
-
target: "parent",
|
|
26912
|
-
eventHandlers: {
|
|
26913
|
-
onMouseDown: (evt, targetProps) => {
|
|
26914
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseDown(evt, targetProps);
|
|
26915
|
-
},
|
|
26916
|
-
onTouchStart: (evt, targetProps) => {
|
|
26917
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseDown(evt, targetProps);
|
|
26918
|
-
},
|
|
26919
|
-
onMouseMove: (evt, targetProps) => {
|
|
26920
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseMove(evt, targetProps);
|
|
26921
|
-
},
|
|
26922
|
-
onTouchMove: (evt, targetProps) => {
|
|
26923
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseMove(evt, targetProps);
|
|
26924
|
-
},
|
|
26925
|
-
onMouseUp: (evt, targetProps) => {
|
|
26926
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseUp(evt, targetProps);
|
|
26927
|
-
},
|
|
26928
|
-
onTouchEnd: (evt, targetProps) => {
|
|
26929
|
-
return props.disable ? {} : _selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseUp(evt, targetProps);
|
|
26930
|
-
}
|
|
26931
|
-
}
|
|
26932
|
-
}];
|
|
26933
|
-
}
|
|
26934
|
-
getRect(props) {
|
|
26935
|
-
const {
|
|
26936
|
-
x1,
|
|
26937
|
-
x2,
|
|
26938
|
-
y1,
|
|
26939
|
-
y2,
|
|
26940
|
-
selectionStyle,
|
|
26941
|
-
selectionComponent,
|
|
26942
|
-
name
|
|
26943
|
-
} = props;
|
|
26944
|
-
const width = Math.abs(x2 - x1) || 1;
|
|
26945
|
-
const height = Math.abs(y2 - y1) || 1;
|
|
26946
|
-
const x = Math.min(x1, x2);
|
|
26947
|
-
const y = Math.min(y1, y2);
|
|
26948
|
-
return y2 && x2 && x1 && y1 ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().cloneElement(selectionComponent, {
|
|
26949
|
-
key: `${name}-selection`,
|
|
26950
|
-
x,
|
|
26951
|
-
y,
|
|
26952
|
-
width,
|
|
26953
|
-
height,
|
|
26954
|
-
style: selectionStyle
|
|
26955
|
-
}) : null;
|
|
26956
|
-
}
|
|
26957
|
-
|
|
26958
|
-
// Overrides method in VictoryContainer
|
|
26959
|
-
getChildren(props) {
|
|
26960
|
-
return [...react__WEBPACK_IMPORTED_MODULE_0___default().Children.toArray(props.children), this.getRect(props)];
|
|
26961
|
-
}
|
|
26707
|
+
const VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS = {
|
|
26708
|
+
activateSelectedData: true,
|
|
26709
|
+
allowSelection: true,
|
|
26710
|
+
selectionComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_1__.Rect, null),
|
|
26711
|
+
selectionStyle: {
|
|
26712
|
+
stroke: "transparent",
|
|
26713
|
+
fill: "black",
|
|
26714
|
+
fillOpacity: 0.1
|
|
26715
|
+
}
|
|
26716
|
+
};
|
|
26717
|
+
const useVictorySelectionContainer = initialProps => {
|
|
26718
|
+
const props = {
|
|
26719
|
+
...VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS,
|
|
26720
|
+
...initialProps
|
|
26962
26721
|
};
|
|
26963
|
-
|
|
26964
|
-
|
|
26722
|
+
const {
|
|
26723
|
+
x1,
|
|
26724
|
+
x2,
|
|
26725
|
+
y1,
|
|
26726
|
+
y2,
|
|
26727
|
+
selectionStyle,
|
|
26728
|
+
selectionComponent,
|
|
26729
|
+
children,
|
|
26730
|
+
name
|
|
26731
|
+
} = props;
|
|
26732
|
+
const width = Math.abs(x2 - x1) || 1;
|
|
26733
|
+
const height = Math.abs(y2 - y1) || 1;
|
|
26734
|
+
const x = Math.min(x1, x2);
|
|
26735
|
+
const y = Math.min(y1, y2);
|
|
26736
|
+
const shouldRenderRect = y1 && y2 && x1 && x2;
|
|
26737
|
+
return {
|
|
26738
|
+
props,
|
|
26739
|
+
children: [children, shouldRenderRect && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().cloneElement(selectionComponent, {
|
|
26740
|
+
key: `${name}-selection`,
|
|
26741
|
+
x,
|
|
26742
|
+
y,
|
|
26743
|
+
width,
|
|
26744
|
+
height,
|
|
26745
|
+
style: selectionStyle
|
|
26746
|
+
})]
|
|
26747
|
+
};
|
|
26748
|
+
};
|
|
26749
|
+
const VictorySelectionContainer = initialProps => {
|
|
26750
|
+
const {
|
|
26751
|
+
props,
|
|
26752
|
+
children
|
|
26753
|
+
} = useVictorySelectionContainer(initialProps);
|
|
26754
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_2__.VictoryContainer, props, children);
|
|
26755
|
+
};
|
|
26756
|
+
VictorySelectionContainer.role = "container";
|
|
26757
|
+
VictorySelectionContainer.defaultEvents = initialProps => {
|
|
26758
|
+
const props = {
|
|
26759
|
+
...VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS,
|
|
26760
|
+
...initialProps
|
|
26761
|
+
};
|
|
26762
|
+
const createEventHandler = (handler, disabled) =>
|
|
26763
|
+
// eslint-disable-next-line max-params
|
|
26764
|
+
(event, targetProps, eventKey, context) => disabled || props.disable ? {} : handler(event, {
|
|
26765
|
+
...props,
|
|
26766
|
+
...targetProps
|
|
26767
|
+
}, eventKey, context);
|
|
26768
|
+
return [{
|
|
26769
|
+
target: "parent",
|
|
26770
|
+
eventHandlers: {
|
|
26771
|
+
onMouseDown: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseDown),
|
|
26772
|
+
onTouchStart: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseDown),
|
|
26773
|
+
onMouseMove: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseMove),
|
|
26774
|
+
onTouchMove: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseMove),
|
|
26775
|
+
onMouseUp: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseUp),
|
|
26776
|
+
onTouchEnd: createEventHandler(_selection_helpers__WEBPACK_IMPORTED_MODULE_3__.SelectionHelpers.onMouseUp)
|
|
26777
|
+
}
|
|
26778
|
+
}];
|
|
26779
|
+
};
|
|
26965
26780
|
|
|
26966
26781
|
/***/ }),
|
|
26967
26782
|
|
|
@@ -27324,9 +27139,9 @@ function addLayoutData(props, datasets, index) {
|
|
|
27324
27139
|
|
|
27325
27140
|
function stackData(props, childComponents) {
|
|
27326
27141
|
const dataFromChildren = victory_core__WEBPACK_IMPORTED_MODULE_3__.getDataFromChildren(props, childComponents);
|
|
27327
|
-
const
|
|
27328
|
-
const
|
|
27329
|
-
return
|
|
27142
|
+
const filledDatasets = fillData(props, dataFromChildren);
|
|
27143
|
+
const filteredNullChild = filledDatasets.map(dataset => dataset.filter(datum => datum._x !== null && datum._y !== null));
|
|
27144
|
+
return filteredNullChild.map((d, i) => addLayoutData(props, filledDatasets, i));
|
|
27330
27145
|
}
|
|
27331
27146
|
function getCalculatedProps(initialProps, childComponents) {
|
|
27332
27147
|
const children = childComponents || react__WEBPACK_IMPORTED_MODULE_1___default().Children.toArray(initialProps.children);
|
|
@@ -28318,7 +28133,7 @@ class VictoryTooltip extends (react__WEBPACK_IMPORTED_MODULE_4___default().Compo
|
|
|
28318
28133
|
renderInPortal
|
|
28319
28134
|
} = props;
|
|
28320
28135
|
if (!active) {
|
|
28321
|
-
return
|
|
28136
|
+
return null;
|
|
28322
28137
|
}
|
|
28323
28138
|
const evaluatedProps = this.getEvaluatedProps(props);
|
|
28324
28139
|
const {
|
|
@@ -28710,9 +28525,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
28710
28525
|
"use strict";
|
|
28711
28526
|
__webpack_require__.r(__webpack_exports__);
|
|
28712
28527
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
28528
|
+
/* harmony export */ "VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ _victory_voronoi_container__WEBPACK_IMPORTED_MODULE_0__.VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS; },
|
|
28713
28529
|
/* harmony export */ "VictoryVoronoiContainer": function() { return /* reexport safe */ _victory_voronoi_container__WEBPACK_IMPORTED_MODULE_0__.VictoryVoronoiContainer; },
|
|
28714
28530
|
/* harmony export */ "VoronoiHelpers": function() { return /* reexport safe */ _voronoi_helpers__WEBPACK_IMPORTED_MODULE_1__.VoronoiHelpers; },
|
|
28715
|
-
/* harmony export */ "
|
|
28531
|
+
/* harmony export */ "useVictoryVoronoiContainer": function() { return /* reexport safe */ _victory_voronoi_container__WEBPACK_IMPORTED_MODULE_0__.useVictoryVoronoiContainer; }
|
|
28716
28532
|
/* harmony export */ });
|
|
28717
28533
|
/* harmony import */ var _victory_voronoi_container__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./victory-voronoi-container */ "../../victory-voronoi-container/es/victory-voronoi-container.js");
|
|
28718
28534
|
/* harmony import */ var _voronoi_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./voronoi-helpers */ "../../victory-voronoi-container/es/voronoi-helpers.js");
|
|
@@ -28730,8 +28546,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
28730
28546
|
"use strict";
|
|
28731
28547
|
__webpack_require__.r(__webpack_exports__);
|
|
28732
28548
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
28549
|
+
/* harmony export */ "VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS": function() { return /* binding */ VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS; },
|
|
28733
28550
|
/* harmony export */ "VictoryVoronoiContainer": function() { return /* binding */ VictoryVoronoiContainer; },
|
|
28734
|
-
/* harmony export */ "
|
|
28551
|
+
/* harmony export */ "useVictoryVoronoiContainer": function() { return /* binding */ useVictoryVoronoiContainer; }
|
|
28735
28552
|
/* harmony export */ });
|
|
28736
28553
|
/* harmony import */ var lodash_pick__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/pick */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/pick.js");
|
|
28737
28554
|
/* harmony import */ var lodash_pick__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_pick__WEBPACK_IMPORTED_MODULE_0__);
|
|
@@ -28739,10 +28556,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
28739
28556
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_1__);
|
|
28740
28557
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react */ "react");
|
|
28741
28558
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);
|
|
28742
|
-
/* harmony import */ var
|
|
28743
|
-
/* harmony import */ var
|
|
28744
|
-
/* harmony import */ var
|
|
28745
|
-
/* harmony import */ var
|
|
28559
|
+
/* harmony import */ var victory_tooltip__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-tooltip */ "../../victory-tooltip/es/victory-tooltip.js");
|
|
28560
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-util/helpers.js");
|
|
28561
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
28562
|
+
/* harmony import */ var _voronoi_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./voronoi-helpers */ "../../victory-voronoi-container/es/voronoi-helpers.js");
|
|
28746
28563
|
|
|
28747
28564
|
|
|
28748
28565
|
/* eslint-disable react/no-multi-comp */
|
|
@@ -28750,204 +28567,214 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
28750
28567
|
|
|
28751
28568
|
|
|
28752
28569
|
|
|
28753
|
-
|
|
28754
|
-
|
|
28755
|
-
|
|
28756
|
-
|
|
28757
|
-
|
|
28758
|
-
|
|
28759
|
-
|
|
28760
|
-
|
|
28761
|
-
|
|
28762
|
-
|
|
28763
|
-
|
|
28764
|
-
|
|
28765
|
-
|
|
28766
|
-
|
|
28767
|
-
|
|
28768
|
-
|
|
28769
|
-
|
|
28770
|
-
|
|
28771
|
-
|
|
28772
|
-
|
|
28773
|
-
|
|
28774
|
-
|
|
28775
|
-
|
|
28776
|
-
|
|
28777
|
-
|
|
28778
|
-
return props.disable ? {} : _voronoi_helpers__WEBPACK_IMPORTED_MODULE_5__.VoronoiHelpers.onMouseMove(evt, targetProps);
|
|
28779
|
-
}
|
|
28780
|
-
}
|
|
28781
|
-
}, {
|
|
28782
|
-
target: "data",
|
|
28783
|
-
eventHandlers: props.disable ? {} : {
|
|
28784
|
-
onMouseOver: () => null,
|
|
28785
|
-
onMouseOut: () => null,
|
|
28786
|
-
onMouseMove: () => null
|
|
28787
|
-
}
|
|
28788
|
-
}];
|
|
28789
|
-
}
|
|
28790
|
-
getDimension(props) {
|
|
28791
|
-
const {
|
|
28792
|
-
horizontal,
|
|
28793
|
-
voronoiDimension
|
|
28794
|
-
} = props;
|
|
28795
|
-
if (!horizontal || !voronoiDimension) {
|
|
28796
|
-
return voronoiDimension;
|
|
28797
|
-
}
|
|
28798
|
-
return voronoiDimension === "x" ? "y" : "x";
|
|
28799
|
-
}
|
|
28800
|
-
getPoint(point) {
|
|
28801
|
-
const whitelist = ["_x", "_x1", "_x0", "_y", "_y1", "_y0"];
|
|
28802
|
-
return lodash_pick__WEBPACK_IMPORTED_MODULE_0___default()(point, whitelist);
|
|
28570
|
+
const VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS = {
|
|
28571
|
+
activateData: true,
|
|
28572
|
+
activateLabels: true,
|
|
28573
|
+
labelComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_tooltip__WEBPACK_IMPORTED_MODULE_3__.VictoryTooltip, null),
|
|
28574
|
+
voronoiPadding: 5
|
|
28575
|
+
};
|
|
28576
|
+
const getPoint = point => {
|
|
28577
|
+
const whitelist = ["_x", "_x1", "_x0", "_y", "_y1", "_y0"];
|
|
28578
|
+
return lodash_pick__WEBPACK_IMPORTED_MODULE_0___default()(point, whitelist);
|
|
28579
|
+
};
|
|
28580
|
+
const useVictoryVoronoiContainer = initialProps => {
|
|
28581
|
+
const props = {
|
|
28582
|
+
...VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS,
|
|
28583
|
+
...initialProps
|
|
28584
|
+
};
|
|
28585
|
+
const {
|
|
28586
|
+
children
|
|
28587
|
+
} = props;
|
|
28588
|
+
const getDimension = () => {
|
|
28589
|
+
const {
|
|
28590
|
+
horizontal,
|
|
28591
|
+
voronoiDimension
|
|
28592
|
+
} = props;
|
|
28593
|
+
if (!horizontal || !voronoiDimension) {
|
|
28594
|
+
return voronoiDimension;
|
|
28803
28595
|
}
|
|
28804
|
-
|
|
28805
|
-
|
|
28806
|
-
|
|
28807
|
-
|
|
28808
|
-
|
|
28809
|
-
|
|
28810
|
-
|
|
28811
|
-
|
|
28812
|
-
|
|
28813
|
-
|
|
28814
|
-
|
|
28815
|
-
|
|
28816
|
-
center: lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps.center, center)
|
|
28817
|
-
};
|
|
28818
|
-
}
|
|
28819
|
-
const x = voronoiDimension === "y" ? mousePosition.x : basePosition.x;
|
|
28820
|
-
const y = voronoiDimension === "x" ? mousePosition.y : basePosition.y;
|
|
28821
|
-
center = mouseFollowTooltips ? mousePosition : {
|
|
28822
|
-
x,
|
|
28823
|
-
y
|
|
28824
|
-
};
|
|
28596
|
+
return voronoiDimension === "x" ? "y" : "x";
|
|
28597
|
+
};
|
|
28598
|
+
const getLabelPosition = (labelProps, points) => {
|
|
28599
|
+
const {
|
|
28600
|
+
mousePosition,
|
|
28601
|
+
mouseFollowTooltips
|
|
28602
|
+
} = props;
|
|
28603
|
+
const voronoiDimension = getDimension();
|
|
28604
|
+
const point = getPoint(points[0]);
|
|
28605
|
+
const basePosition = victory_core__WEBPACK_IMPORTED_MODULE_4__.scalePoint(props, point);
|
|
28606
|
+
let center = mouseFollowTooltips ? mousePosition : undefined;
|
|
28607
|
+
if (!voronoiDimension || points.length < 2) {
|
|
28825
28608
|
return {
|
|
28826
|
-
|
|
28827
|
-
y,
|
|
28609
|
+
...basePosition,
|
|
28828
28610
|
center: lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps.center, center)
|
|
28829
28611
|
};
|
|
28830
28612
|
}
|
|
28831
|
-
|
|
28832
|
-
|
|
28833
|
-
|
|
28834
|
-
|
|
28835
|
-
|
|
28836
|
-
|
|
28837
|
-
|
|
28838
|
-
|
|
28839
|
-
|
|
28840
|
-
|
|
28841
|
-
|
|
28842
|
-
|
|
28843
|
-
|
|
28844
|
-
|
|
28845
|
-
|
|
28846
|
-
|
|
28847
|
-
|
|
28848
|
-
|
|
28849
|
-
|
|
28850
|
-
|
|
28851
|
-
|
|
28852
|
-
|
|
28853
|
-
|
|
28854
|
-
getDefaultLabelProps(props, points) {
|
|
28855
|
-
const {
|
|
28856
|
-
voronoiDimension,
|
|
28857
|
-
horizontal,
|
|
28858
|
-
mouseFollowTooltips
|
|
28859
|
-
} = props;
|
|
28860
|
-
const point = this.getPoint(points[0]);
|
|
28861
|
-
const multiPoint = voronoiDimension && points.length > 1;
|
|
28862
|
-
const y = point._y1 !== undefined ? point._y1 : point._y;
|
|
28863
|
-
const defaultHorizontalOrientation = y < 0 ? "left" : "right";
|
|
28864
|
-
const defaultOrientation = y < 0 ? "bottom" : "top";
|
|
28865
|
-
const labelOrientation = horizontal ? defaultHorizontalOrientation : defaultOrientation;
|
|
28866
|
-
const orientation = mouseFollowTooltips ? undefined : labelOrientation;
|
|
28867
|
-
return {
|
|
28868
|
-
orientation,
|
|
28869
|
-
pointerLength: multiPoint ? 0 : undefined,
|
|
28870
|
-
constrainToVisibleArea: multiPoint || mouseFollowTooltips ? true : undefined
|
|
28871
|
-
};
|
|
28872
|
-
}
|
|
28873
|
-
getLabelProps(props, points) {
|
|
28874
|
-
const {
|
|
28875
|
-
labels,
|
|
28876
|
-
scale,
|
|
28877
|
-
labelComponent,
|
|
28878
|
-
theme,
|
|
28879
|
-
width,
|
|
28880
|
-
height
|
|
28881
|
-
} = props;
|
|
28882
|
-
const componentProps = labelComponent.props || {};
|
|
28883
|
-
const text = points.reduce((memo, datum) => {
|
|
28884
|
-
const labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, componentProps, {
|
|
28885
|
-
datum,
|
|
28886
|
-
active: true
|
|
28887
|
-
});
|
|
28888
|
-
const t = victory_core__WEBPACK_IMPORTED_MODULE_6__.isFunction(labels) ? labels(labelProps) : null;
|
|
28889
|
-
if (t === null || t === undefined) {
|
|
28890
|
-
return memo;
|
|
28891
|
-
}
|
|
28892
|
-
return memo.concat(`${t}`.split("\n"));
|
|
28893
|
-
}, []);
|
|
28894
|
-
|
|
28895
|
-
// remove properties from first point to make datum
|
|
28896
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
28897
|
-
const {
|
|
28898
|
-
childName,
|
|
28899
|
-
eventKey,
|
|
28900
|
-
style,
|
|
28901
|
-
continuous,
|
|
28902
|
-
...datum
|
|
28903
|
-
} = points[0];
|
|
28904
|
-
const name = props.name === childName ? childName : `${props.name}-${childName}`;
|
|
28905
|
-
const labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({
|
|
28906
|
-
key: `${name}-${eventKey}-voronoi-tooltip`,
|
|
28907
|
-
id: `${name}-${eventKey}-voronoi-tooltip`,
|
|
28908
|
-
active: true,
|
|
28909
|
-
renderInPortal: false,
|
|
28910
|
-
activePoints: points,
|
|
28613
|
+
const x = voronoiDimension === "y" ? mousePosition.x : basePosition.x;
|
|
28614
|
+
const y = voronoiDimension === "x" ? mousePosition.y : basePosition.y;
|
|
28615
|
+
center = mouseFollowTooltips ? mousePosition : {
|
|
28616
|
+
x,
|
|
28617
|
+
y
|
|
28618
|
+
};
|
|
28619
|
+
return {
|
|
28620
|
+
x,
|
|
28621
|
+
y,
|
|
28622
|
+
center: lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelProps.center, center)
|
|
28623
|
+
};
|
|
28624
|
+
};
|
|
28625
|
+
const getStyle = (points, type) => {
|
|
28626
|
+
const {
|
|
28627
|
+
labels,
|
|
28628
|
+
labelComponent,
|
|
28629
|
+
theme
|
|
28630
|
+
} = props;
|
|
28631
|
+
const componentProps = labelComponent.props || {};
|
|
28632
|
+
const themeStyles = theme && theme.voronoi && theme.voronoi.style ? theme.voronoi.style : {};
|
|
28633
|
+
const componentStyleArray = type === "flyout" ? componentProps.flyoutStyle : componentProps.style;
|
|
28634
|
+
return points.reduce((memo, datum, index) => {
|
|
28635
|
+
const labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, componentProps, {
|
|
28911
28636
|
datum,
|
|
28912
|
-
|
|
28913
|
-
|
|
28914
|
-
|
|
28915
|
-
|
|
28916
|
-
|
|
28917
|
-
|
|
28918
|
-
|
|
28919
|
-
|
|
28920
|
-
|
|
28921
|
-
|
|
28922
|
-
|
|
28923
|
-
|
|
28924
|
-
|
|
28925
|
-
|
|
28926
|
-
|
|
28927
|
-
|
|
28928
|
-
|
|
28929
|
-
|
|
28930
|
-
|
|
28931
|
-
|
|
28932
|
-
|
|
28933
|
-
|
|
28934
|
-
|
|
28935
|
-
|
|
28936
|
-
|
|
28937
|
-
|
|
28938
|
-
|
|
28939
|
-
|
|
28637
|
+
active: true
|
|
28638
|
+
});
|
|
28639
|
+
const text = victory_core__WEBPACK_IMPORTED_MODULE_4__.isFunction(labels) ? labels(labelProps) : undefined;
|
|
28640
|
+
const textArray = text !== undefined ? `${text}`.split("\n") : [];
|
|
28641
|
+
const baseStyle = datum.style && datum.style[type] || {};
|
|
28642
|
+
const componentStyle = Array.isArray(componentStyleArray) ? componentStyleArray[index] : componentStyleArray;
|
|
28643
|
+
const style = victory_core__WEBPACK_IMPORTED_MODULE_4__.evaluateStyle(lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, componentStyle, baseStyle, themeStyles[type]), labelProps);
|
|
28644
|
+
const styleArray = textArray.length ? textArray.map(() => style) : [style];
|
|
28645
|
+
return memo.concat(styleArray);
|
|
28646
|
+
}, []);
|
|
28647
|
+
};
|
|
28648
|
+
const getDefaultLabelProps = points => {
|
|
28649
|
+
const {
|
|
28650
|
+
voronoiDimension,
|
|
28651
|
+
horizontal,
|
|
28652
|
+
mouseFollowTooltips
|
|
28653
|
+
} = props;
|
|
28654
|
+
const point = getPoint(points[0]);
|
|
28655
|
+
const multiPoint = voronoiDimension && points.length > 1;
|
|
28656
|
+
const y = point._y1 !== undefined ? point._y1 : point._y;
|
|
28657
|
+
const defaultHorizontalOrientation = y < 0 ? "left" : "right";
|
|
28658
|
+
const defaultOrientation = y < 0 ? "bottom" : "top";
|
|
28659
|
+
const labelOrientation = horizontal ? defaultHorizontalOrientation : defaultOrientation;
|
|
28660
|
+
const orientation = mouseFollowTooltips ? undefined : labelOrientation;
|
|
28661
|
+
return {
|
|
28662
|
+
orientation,
|
|
28663
|
+
pointerLength: multiPoint ? 0 : undefined,
|
|
28664
|
+
constrainToVisibleArea: multiPoint || mouseFollowTooltips ? true : undefined
|
|
28665
|
+
};
|
|
28666
|
+
};
|
|
28667
|
+
const getLabelProps = points => {
|
|
28668
|
+
const {
|
|
28669
|
+
labels,
|
|
28670
|
+
scale,
|
|
28671
|
+
labelComponent,
|
|
28672
|
+
theme,
|
|
28673
|
+
width,
|
|
28674
|
+
height
|
|
28675
|
+
} = props;
|
|
28676
|
+
const componentProps = labelComponent.props || {};
|
|
28677
|
+
const text = points.reduce((memo, datum) => {
|
|
28678
|
+
const labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, componentProps, {
|
|
28679
|
+
datum,
|
|
28680
|
+
active: true
|
|
28681
|
+
});
|
|
28682
|
+
const t = victory_core__WEBPACK_IMPORTED_MODULE_4__.isFunction(labels) ? labels(labelProps) : null;
|
|
28683
|
+
if (t === null || t === undefined) {
|
|
28684
|
+
return memo;
|
|
28940
28685
|
}
|
|
28686
|
+
return memo.concat(`${t}`.split("\n"));
|
|
28687
|
+
}, []);
|
|
28688
|
+
|
|
28689
|
+
// remove properties from first point to make datum
|
|
28690
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
28691
|
+
const {
|
|
28692
|
+
childName,
|
|
28693
|
+
eventKey,
|
|
28694
|
+
style,
|
|
28695
|
+
continuous,
|
|
28696
|
+
...datum
|
|
28697
|
+
} = points[0];
|
|
28698
|
+
const name = props.name === childName ? childName : `${props.name}-${childName}`;
|
|
28699
|
+
const labelProps = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({
|
|
28700
|
+
key: `${name}-${eventKey}-voronoi-tooltip`,
|
|
28701
|
+
id: `${name}-${eventKey}-voronoi-tooltip`,
|
|
28702
|
+
active: true,
|
|
28703
|
+
renderInPortal: false,
|
|
28704
|
+
activePoints: points,
|
|
28705
|
+
datum,
|
|
28706
|
+
scale,
|
|
28707
|
+
theme
|
|
28708
|
+
}, componentProps, {
|
|
28709
|
+
text,
|
|
28710
|
+
width,
|
|
28711
|
+
height,
|
|
28712
|
+
style: getStyle(points, "labels"),
|
|
28713
|
+
flyoutStyle: getStyle(points, "flyout")[0]
|
|
28714
|
+
}, getDefaultLabelProps(points));
|
|
28715
|
+
const labelPosition = getLabelPosition(labelProps, points);
|
|
28716
|
+
return lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, labelPosition, labelProps);
|
|
28717
|
+
};
|
|
28718
|
+
const getTooltip = () => {
|
|
28719
|
+
const {
|
|
28720
|
+
labels,
|
|
28721
|
+
activePoints,
|
|
28722
|
+
labelComponent
|
|
28723
|
+
} = props;
|
|
28724
|
+
if (!labels) {
|
|
28941
28725
|
return null;
|
|
28942
28726
|
}
|
|
28943
|
-
|
|
28944
|
-
|
|
28945
|
-
|
|
28946
|
-
|
|
28727
|
+
if (Array.isArray(activePoints) && activePoints.length) {
|
|
28728
|
+
const labelProps = getLabelProps(activePoints);
|
|
28729
|
+
const {
|
|
28730
|
+
text
|
|
28731
|
+
} = labelProps;
|
|
28732
|
+
const showLabel = Array.isArray(text) ? text.filter(Boolean).length : text;
|
|
28733
|
+
return showLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().cloneElement(labelComponent, labelProps) : null;
|
|
28947
28734
|
}
|
|
28735
|
+
return null;
|
|
28948
28736
|
};
|
|
28949
|
-
|
|
28950
|
-
|
|
28737
|
+
return {
|
|
28738
|
+
props,
|
|
28739
|
+
children: [...react__WEBPACK_IMPORTED_MODULE_2___default().Children.toArray(children), getTooltip()]
|
|
28740
|
+
};
|
|
28741
|
+
};
|
|
28742
|
+
const VictoryVoronoiContainer = initialProps => {
|
|
28743
|
+
const {
|
|
28744
|
+
props,
|
|
28745
|
+
children
|
|
28746
|
+
} = useVictoryVoronoiContainer(initialProps);
|
|
28747
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_2___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_5__.VictoryContainer, props, children);
|
|
28748
|
+
};
|
|
28749
|
+
VictoryVoronoiContainer.role = "container";
|
|
28750
|
+
VictoryVoronoiContainer.defaultEvents = initialProps => {
|
|
28751
|
+
const props = {
|
|
28752
|
+
...VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS,
|
|
28753
|
+
...initialProps
|
|
28754
|
+
};
|
|
28755
|
+
const createEventHandler = (handler, disabled) =>
|
|
28756
|
+
// eslint-disable-next-line max-params
|
|
28757
|
+
(event, targetProps, eventKey, context) => disabled || props.disable ? {} : handler(event, {
|
|
28758
|
+
...props,
|
|
28759
|
+
...targetProps
|
|
28760
|
+
}, eventKey, context);
|
|
28761
|
+
return [{
|
|
28762
|
+
target: "parent",
|
|
28763
|
+
eventHandlers: {
|
|
28764
|
+
onMouseLeave: createEventHandler(_voronoi_helpers__WEBPACK_IMPORTED_MODULE_6__.VoronoiHelpers.onMouseLeave),
|
|
28765
|
+
onTouchCancel: createEventHandler(_voronoi_helpers__WEBPACK_IMPORTED_MODULE_6__.VoronoiHelpers.onMouseLeave),
|
|
28766
|
+
onMouseMove: createEventHandler(_voronoi_helpers__WEBPACK_IMPORTED_MODULE_6__.VoronoiHelpers.onMouseMove),
|
|
28767
|
+
onTouchMove: createEventHandler(_voronoi_helpers__WEBPACK_IMPORTED_MODULE_6__.VoronoiHelpers.onMouseMove)
|
|
28768
|
+
}
|
|
28769
|
+
}, {
|
|
28770
|
+
target: "data",
|
|
28771
|
+
eventHandlers: props.disable ? {} : {
|
|
28772
|
+
onMouseOver: () => null,
|
|
28773
|
+
onMouseOut: () => null,
|
|
28774
|
+
onMouseMove: () => null
|
|
28775
|
+
}
|
|
28776
|
+
}];
|
|
28777
|
+
};
|
|
28951
28778
|
|
|
28952
28779
|
/***/ }),
|
|
28953
28780
|
|
|
@@ -29585,9 +29412,10 @@ const Voronoi = initialProps => {
|
|
|
29585
29412
|
__webpack_require__.r(__webpack_exports__);
|
|
29586
29413
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
29587
29414
|
/* harmony export */ "RawZoomHelpers": function() { return /* reexport safe */ _zoom_helpers__WEBPACK_IMPORTED_MODULE_1__.RawZoomHelpers; },
|
|
29415
|
+
/* harmony export */ "VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ _victory_zoom_container__WEBPACK_IMPORTED_MODULE_0__.VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS; },
|
|
29588
29416
|
/* harmony export */ "VictoryZoomContainer": function() { return /* reexport safe */ _victory_zoom_container__WEBPACK_IMPORTED_MODULE_0__.VictoryZoomContainer; },
|
|
29589
29417
|
/* harmony export */ "ZoomHelpers": function() { return /* reexport safe */ _zoom_helpers__WEBPACK_IMPORTED_MODULE_1__.ZoomHelpers; },
|
|
29590
|
-
/* harmony export */ "
|
|
29418
|
+
/* harmony export */ "useVictoryZoomContainer": function() { return /* reexport safe */ _victory_zoom_container__WEBPACK_IMPORTED_MODULE_0__.useVictoryZoomContainer; }
|
|
29591
29419
|
/* harmony export */ });
|
|
29592
29420
|
/* harmony import */ var _victory_zoom_container__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./victory-zoom-container */ "../../victory-zoom-container/es/victory-zoom-container.js");
|
|
29593
29421
|
/* harmony import */ var _zoom_helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./zoom-helpers */ "../../victory-zoom-container/es/zoom-helpers.js");
|
|
@@ -29605,85 +29433,120 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
29605
29433
|
"use strict";
|
|
29606
29434
|
__webpack_require__.r(__webpack_exports__);
|
|
29607
29435
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
29436
|
+
/* harmony export */ "VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS": function() { return /* binding */ VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS; },
|
|
29608
29437
|
/* harmony export */ "VictoryZoomContainer": function() { return /* binding */ VictoryZoomContainer; },
|
|
29609
|
-
/* harmony export */ "
|
|
29438
|
+
/* harmony export */ "useVictoryZoomContainer": function() { return /* binding */ useVictoryZoomContainer; }
|
|
29610
29439
|
/* harmony export */ });
|
|
29611
29440
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/defaults */ "../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/defaults.js");
|
|
29612
29441
|
/* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_0__);
|
|
29613
29442
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ "react");
|
|
29614
29443
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
|
|
29615
29444
|
/* harmony import */ var _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./zoom-helpers */ "../../victory-zoom-container/es/zoom-helpers.js");
|
|
29616
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
29617
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
29618
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-
|
|
29619
|
-
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-util/helpers.js");
|
|
29445
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-clip-container/victory-clip-container.js");
|
|
29446
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-util/data.js");
|
|
29447
|
+
/* harmony import */ var victory_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! victory-core */ "../../victory-core/es/victory-container/victory-container.js");
|
|
29620
29448
|
|
|
29621
29449
|
|
|
29622
29450
|
|
|
29623
29451
|
|
|
29624
29452
|
const DEFAULT_DOWNSAMPLE = 150;
|
|
29625
|
-
|
|
29626
|
-
|
|
29627
|
-
|
|
29628
|
-
|
|
29629
|
-
|
|
29630
|
-
|
|
29631
|
-
|
|
29632
|
-
|
|
29633
|
-
|
|
29634
|
-
|
|
29453
|
+
const VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS = {
|
|
29454
|
+
clipContainerComponent: /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_2__.VictoryClipContainer, null),
|
|
29455
|
+
allowPan: true,
|
|
29456
|
+
allowZoom: true,
|
|
29457
|
+
zoomActive: false
|
|
29458
|
+
};
|
|
29459
|
+
const useVictoryZoomContainer = initialProps => {
|
|
29460
|
+
const props = {
|
|
29461
|
+
...VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS,
|
|
29462
|
+
...initialProps
|
|
29463
|
+
};
|
|
29464
|
+
const {
|
|
29465
|
+
children,
|
|
29466
|
+
currentDomain,
|
|
29467
|
+
zoomActive,
|
|
29468
|
+
allowZoom,
|
|
29469
|
+
downsample,
|
|
29470
|
+
scale,
|
|
29471
|
+
clipContainerComponent,
|
|
29472
|
+
polar,
|
|
29473
|
+
origin,
|
|
29474
|
+
horizontal
|
|
29475
|
+
} = props;
|
|
29476
|
+
const downsampleZoomData = (child, domain) => {
|
|
29477
|
+
const getData = childProps => {
|
|
29478
|
+
const {
|
|
29479
|
+
data,
|
|
29480
|
+
x,
|
|
29481
|
+
y
|
|
29482
|
+
} = childProps;
|
|
29483
|
+
const defaultGetData = child.type && typeof child.type.getData === "function" ? child.type.getData : () => undefined;
|
|
29484
|
+
// skip costly data formatting if x and y accessors are not present
|
|
29485
|
+
return Array.isArray(data) && !x && !y ? data : defaultGetData(childProps);
|
|
29635
29486
|
};
|
|
29636
|
-
|
|
29637
|
-
|
|
29638
|
-
|
|
29639
|
-
|
|
29640
|
-
|
|
29641
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseDown(evt, targetProps);
|
|
29642
|
-
},
|
|
29643
|
-
onTouchStart: (evt, targetProps) => {
|
|
29644
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseDown(evt, targetProps);
|
|
29645
|
-
},
|
|
29646
|
-
onMouseUp: (evt, targetProps) => {
|
|
29647
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseUp(evt, targetProps);
|
|
29648
|
-
},
|
|
29649
|
-
onTouchEnd: (evt, targetProps) => {
|
|
29650
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseUp(evt, targetProps);
|
|
29651
|
-
},
|
|
29652
|
-
onMouseLeave: (evt, targetProps) => {
|
|
29653
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseLeave(evt, targetProps);
|
|
29654
|
-
},
|
|
29655
|
-
onTouchCancel: (evt, targetProps) => {
|
|
29656
|
-
return props.disable ? {} : _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseLeave(evt, targetProps);
|
|
29657
|
-
},
|
|
29658
|
-
// eslint-disable-next-line max-params
|
|
29659
|
-
onMouseMove: (evt, targetProps, eventKey, ctx) => {
|
|
29660
|
-
if (props.disable) {
|
|
29661
|
-
return {};
|
|
29662
|
-
}
|
|
29663
|
-
return _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseMove(evt, targetProps, eventKey, ctx);
|
|
29664
|
-
},
|
|
29665
|
-
// eslint-disable-next-line max-params
|
|
29666
|
-
onTouchMove: (evt, targetProps, eventKey, ctx) => {
|
|
29667
|
-
if (props.disable) {
|
|
29668
|
-
return {};
|
|
29669
|
-
}
|
|
29670
|
-
evt.preventDefault();
|
|
29671
|
-
return _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseMove(evt, targetProps, eventKey, ctx);
|
|
29672
|
-
},
|
|
29673
|
-
...(props.disable || !props.allowZoom ? {} : {
|
|
29674
|
-
onWheel: _zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onWheel
|
|
29675
|
-
})
|
|
29676
|
-
}
|
|
29677
|
-
}];
|
|
29487
|
+
const data = getData(child.props);
|
|
29488
|
+
|
|
29489
|
+
// return undefined if downsample is not run, then default() will replace with child.props.data
|
|
29490
|
+
if (!downsample || !domain || !data) {
|
|
29491
|
+
return undefined;
|
|
29678
29492
|
}
|
|
29679
|
-
|
|
29680
|
-
|
|
29681
|
-
|
|
29682
|
-
|
|
29683
|
-
|
|
29684
|
-
|
|
29685
|
-
|
|
29686
|
-
|
|
29493
|
+
const maxPoints = downsample === true ? DEFAULT_DOWNSAMPLE : downsample;
|
|
29494
|
+
const dimension = props.zoomDimension || "x";
|
|
29495
|
+
|
|
29496
|
+
// important: assumes data is ordered by dimension
|
|
29497
|
+
// get the start and end of the data that is in the current visible domain
|
|
29498
|
+
let startIndex = data.findIndex(d => d[dimension] >= domain[dimension][0]);
|
|
29499
|
+
let endIndex = data.findIndex(d => d[dimension] > domain[dimension][1]);
|
|
29500
|
+
// pick one more point (if available) at each end so that VictoryLine, VictoryArea connect
|
|
29501
|
+
if (startIndex !== 0) {
|
|
29502
|
+
startIndex -= 1;
|
|
29503
|
+
}
|
|
29504
|
+
if (endIndex !== -1) {
|
|
29505
|
+
endIndex += 1;
|
|
29506
|
+
}
|
|
29507
|
+
const visibleData = data.slice(startIndex, endIndex);
|
|
29508
|
+
return victory_core__WEBPACK_IMPORTED_MODULE_3__.downsample(visibleData, maxPoints, startIndex);
|
|
29509
|
+
};
|
|
29510
|
+
const modifiedChildren = react__WEBPACK_IMPORTED_MODULE_1___default().Children.toArray(children).map(child => {
|
|
29511
|
+
const role = child.type && child.type.role;
|
|
29512
|
+
const isDataComponent = victory_core__WEBPACK_IMPORTED_MODULE_3__.isDataComponent(child);
|
|
29513
|
+
const originalDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.originalDomain, props.domain);
|
|
29514
|
+
const zoomDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.zoomDomain, props.domain);
|
|
29515
|
+
const cachedZoomDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.cachedZoomDomain, props.domain);
|
|
29516
|
+
let domain;
|
|
29517
|
+
if (!_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.checkDomainEquality(zoomDomain, cachedZoomDomain)) {
|
|
29518
|
+
// if zoomDomain has been changed, use it
|
|
29519
|
+
domain = zoomDomain;
|
|
29520
|
+
} else if (allowZoom && !zoomActive) {
|
|
29521
|
+
// if user has zoomed all the way out, use the child domain
|
|
29522
|
+
domain = child.props.domain;
|
|
29523
|
+
} else {
|
|
29524
|
+
// default: use currentDomain, set by the event handlers
|
|
29525
|
+
domain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, currentDomain, originalDomain);
|
|
29526
|
+
}
|
|
29527
|
+
let newDomain = props.polar ? {
|
|
29528
|
+
x: originalDomain.x,
|
|
29529
|
+
y: [0, domain.y[1]]
|
|
29530
|
+
} : domain;
|
|
29531
|
+
if (newDomain && props.zoomDimension) {
|
|
29532
|
+
// if zooming is restricted to a dimension, don't squash changes to zoomDomain in other dim
|
|
29533
|
+
newDomain = {
|
|
29534
|
+
...zoomDomain,
|
|
29535
|
+
[props.zoomDimension]: newDomain[props.zoomDimension]
|
|
29536
|
+
};
|
|
29537
|
+
}
|
|
29538
|
+
|
|
29539
|
+
// don't downsample stacked data
|
|
29540
|
+
const childProps = isDataComponent && role !== "stack" ? {
|
|
29541
|
+
domain: newDomain,
|
|
29542
|
+
data: downsampleZoomData(child, newDomain)
|
|
29543
|
+
} : {
|
|
29544
|
+
domain: newDomain
|
|
29545
|
+
};
|
|
29546
|
+
const newChild = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(child, lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()(childProps, child.props));
|
|
29547
|
+
|
|
29548
|
+
// Clip data components
|
|
29549
|
+
if (victory_core__WEBPACK_IMPORTED_MODULE_3__.isDataComponent(newChild)) {
|
|
29687
29550
|
const rangeX = horizontal ? scale.y.range() : scale.x.range();
|
|
29688
29551
|
const rangeY = horizontal ? scale.x.range() : scale.y.range();
|
|
29689
29552
|
const plottableWidth = Math.abs(rangeX[0] - rangeX[1]);
|
|
@@ -29699,110 +29562,51 @@ function zoomContainerMixin(Base) {
|
|
|
29699
29562
|
radius: polar ? radius : undefined,
|
|
29700
29563
|
...clipContainerComponent.props
|
|
29701
29564
|
});
|
|
29702
|
-
return react__WEBPACK_IMPORTED_MODULE_1___default().
|
|
29703
|
-
|
|
29704
|
-
return child;
|
|
29705
|
-
}
|
|
29706
|
-
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(child, {
|
|
29707
|
-
groupComponent
|
|
29708
|
-
});
|
|
29709
|
-
});
|
|
29710
|
-
}
|
|
29711
|
-
modifyPolarDomain(domain, originalDomain) {
|
|
29712
|
-
// Only zoom the radius of polar charts. Zooming angles is very confusing
|
|
29713
|
-
return {
|
|
29714
|
-
x: originalDomain.x,
|
|
29715
|
-
y: [0, domain.y[1]]
|
|
29716
|
-
};
|
|
29717
|
-
}
|
|
29718
|
-
downsampleZoomData(props, child, domain) {
|
|
29719
|
-
const {
|
|
29720
|
-
downsample
|
|
29721
|
-
} = props;
|
|
29722
|
-
const getData = childProps => {
|
|
29723
|
-
const {
|
|
29724
|
-
data,
|
|
29725
|
-
x,
|
|
29726
|
-
y
|
|
29727
|
-
} = childProps;
|
|
29728
|
-
const defaultGetData = child.type && victory_core__WEBPACK_IMPORTED_MODULE_6__.isFunction(child.type.getData) ? child.type.getData : () => undefined;
|
|
29729
|
-
// skip costly data formatting if x and y accessors are not present
|
|
29730
|
-
return Array.isArray(data) && !x && !y ? data : defaultGetData(childProps);
|
|
29731
|
-
};
|
|
29732
|
-
const data = getData(child.props);
|
|
29733
|
-
|
|
29734
|
-
// return undefined if downsample is not run, then default() will replace with child.props.data
|
|
29735
|
-
if (!downsample || !domain || !data) {
|
|
29736
|
-
return undefined;
|
|
29737
|
-
}
|
|
29738
|
-
const maxPoints = downsample === true ? DEFAULT_DOWNSAMPLE : downsample;
|
|
29739
|
-
const dimension = props.zoomDimension || "x";
|
|
29740
|
-
|
|
29741
|
-
// important: assumes data is ordered by dimension
|
|
29742
|
-
// get the start and end of the data that is in the current visible domain
|
|
29743
|
-
let startIndex = data.findIndex(d => d[dimension] >= domain[dimension][0]);
|
|
29744
|
-
let endIndex = data.findIndex(d => d[dimension] > domain[dimension][1]);
|
|
29745
|
-
// pick one more point (if available) at each end so that VictoryLine, VictoryArea connect
|
|
29746
|
-
if (startIndex !== 0) {
|
|
29747
|
-
startIndex -= 1;
|
|
29748
|
-
}
|
|
29749
|
-
if (endIndex !== -1) {
|
|
29750
|
-
endIndex += 1;
|
|
29751
|
-
}
|
|
29752
|
-
const visibleData = data.slice(startIndex, endIndex);
|
|
29753
|
-
return victory_core__WEBPACK_IMPORTED_MODULE_5__.downsample(visibleData, maxPoints, startIndex);
|
|
29754
|
-
}
|
|
29755
|
-
modifyChildren(props) {
|
|
29756
|
-
const childComponents = react__WEBPACK_IMPORTED_MODULE_1___default().Children.toArray(props.children);
|
|
29757
|
-
return childComponents.map(child => {
|
|
29758
|
-
const role = child.type && child.type.role;
|
|
29759
|
-
const isDataComponent = victory_core__WEBPACK_IMPORTED_MODULE_5__.isDataComponent(child);
|
|
29760
|
-
const {
|
|
29761
|
-
currentDomain,
|
|
29762
|
-
zoomActive,
|
|
29763
|
-
allowZoom
|
|
29764
|
-
} = props;
|
|
29765
|
-
const originalDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.originalDomain, props.domain);
|
|
29766
|
-
const zoomDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.zoomDomain, props.domain);
|
|
29767
|
-
const cachedZoomDomain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, props.cachedZoomDomain, props.domain);
|
|
29768
|
-
let domain;
|
|
29769
|
-
if (!_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.checkDomainEquality(zoomDomain, cachedZoomDomain)) {
|
|
29770
|
-
// if zoomDomain has been changed, use it
|
|
29771
|
-
domain = zoomDomain;
|
|
29772
|
-
} else if (allowZoom && !zoomActive) {
|
|
29773
|
-
// if user has zoomed all the way out, use the child domain
|
|
29774
|
-
domain = child.props.domain;
|
|
29775
|
-
} else {
|
|
29776
|
-
// default: use currentDomain, set by the event handlers
|
|
29777
|
-
domain = lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()({}, currentDomain, originalDomain);
|
|
29778
|
-
}
|
|
29779
|
-
let newDomain = props.polar ? this.modifyPolarDomain(domain, originalDomain) : domain;
|
|
29780
|
-
if (newDomain && props.zoomDimension) {
|
|
29781
|
-
// if zooming is restricted to a dimension, don't squash changes to zoomDomain in other dim
|
|
29782
|
-
newDomain = {
|
|
29783
|
-
...zoomDomain,
|
|
29784
|
-
[props.zoomDimension]: newDomain[props.zoomDimension]
|
|
29785
|
-
};
|
|
29786
|
-
}
|
|
29787
|
-
// don't downsample stacked data
|
|
29788
|
-
const newProps = isDataComponent && role !== "stack" ? {
|
|
29789
|
-
domain: newDomain,
|
|
29790
|
-
data: this.downsampleZoomData(props, child, newDomain)
|
|
29791
|
-
} : {
|
|
29792
|
-
domain: newDomain
|
|
29793
|
-
};
|
|
29794
|
-
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(child, lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default()(newProps, child.props));
|
|
29565
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().cloneElement(newChild, {
|
|
29566
|
+
groupComponent
|
|
29795
29567
|
});
|
|
29796
29568
|
}
|
|
29797
|
-
|
|
29798
|
-
|
|
29799
|
-
|
|
29800
|
-
|
|
29801
|
-
|
|
29802
|
-
}
|
|
29569
|
+
return newChild;
|
|
29570
|
+
});
|
|
29571
|
+
return {
|
|
29572
|
+
props,
|
|
29573
|
+
children: modifiedChildren
|
|
29803
29574
|
};
|
|
29804
|
-
}
|
|
29805
|
-
const VictoryZoomContainer =
|
|
29575
|
+
};
|
|
29576
|
+
const VictoryZoomContainer = initialProps => {
|
|
29577
|
+
const {
|
|
29578
|
+
props,
|
|
29579
|
+
children
|
|
29580
|
+
} = useVictoryZoomContainer(initialProps);
|
|
29581
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(victory_core__WEBPACK_IMPORTED_MODULE_5__.VictoryContainer, props, children);
|
|
29582
|
+
};
|
|
29583
|
+
VictoryZoomContainer.role = "container";
|
|
29584
|
+
VictoryZoomContainer.defaultEvents = initialProps => {
|
|
29585
|
+
const props = {
|
|
29586
|
+
...VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS,
|
|
29587
|
+
...initialProps
|
|
29588
|
+
};
|
|
29589
|
+
const createEventHandler = (handler, disabled) =>
|
|
29590
|
+
// eslint-disable-next-line max-params
|
|
29591
|
+
(event, targetProps, eventKey, context) => disabled || props.disable ? {} : handler(event, {
|
|
29592
|
+
...props,
|
|
29593
|
+
...targetProps
|
|
29594
|
+
}, eventKey, context);
|
|
29595
|
+
return [{
|
|
29596
|
+
target: "parent",
|
|
29597
|
+
eventHandlers: {
|
|
29598
|
+
onMouseDown: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseDown),
|
|
29599
|
+
onTouchStart: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseDown),
|
|
29600
|
+
onMouseUp: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseUp),
|
|
29601
|
+
onTouchEnd: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseUp),
|
|
29602
|
+
onMouseLeave: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseLeave),
|
|
29603
|
+
onTouchCancel: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseLeave),
|
|
29604
|
+
onMouseMove: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseMove),
|
|
29605
|
+
onTouchMove: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onMouseMove),
|
|
29606
|
+
onWheel: createEventHandler(_zoom_helpers__WEBPACK_IMPORTED_MODULE_4__.ZoomHelpers.onWheel, !props.allowZoom)
|
|
29607
|
+
}
|
|
29608
|
+
}];
|
|
29609
|
+
};
|
|
29806
29610
|
|
|
29807
29611
|
/***/ }),
|
|
29808
29612
|
|
|
@@ -42367,6 +42171,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
42367
42171
|
/* harmony export */ "PointPathHelpers": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.PointPathHelpers; },
|
|
42368
42172
|
/* harmony export */ "Portal": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.Portal; },
|
|
42369
42173
|
/* harmony export */ "PortalContext": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.PortalContext; },
|
|
42174
|
+
/* harmony export */ "PortalOutlet": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.PortalOutlet; },
|
|
42175
|
+
/* harmony export */ "PortalProvider": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.PortalProvider; },
|
|
42370
42176
|
/* harmony export */ "RawZoomHelpers": function() { return /* reexport safe */ victory_zoom_container__WEBPACK_IMPORTED_MODULE_26__.RawZoomHelpers; },
|
|
42371
42177
|
/* harmony export */ "Rect": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.Rect; },
|
|
42372
42178
|
/* harmony export */ "Scale": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.Scale; },
|
|
@@ -42381,6 +42187,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
42381
42187
|
/* harmony export */ "TimerContext": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.TimerContext; },
|
|
42382
42188
|
/* harmony export */ "Transitions": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.Transitions; },
|
|
42383
42189
|
/* harmony export */ "UserProps": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.UserProps; },
|
|
42190
|
+
/* harmony export */ "VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ victory_brush_container__WEBPACK_IMPORTED_MODULE_4__.VICTORY_BRUSH_CONTAINER_DEFAULT_PROPS; },
|
|
42191
|
+
/* harmony export */ "VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ victory_cursor_container__WEBPACK_IMPORTED_MODULE_11__.VICTORY_CURSOR_CONTAINER_DEFAULT_PROPS; },
|
|
42192
|
+
/* harmony export */ "VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ victory_selection_container__WEBPACK_IMPORTED_MODULE_20__.VICTORY_SELECTION_CONTAINER_DEFAULT_PROPS; },
|
|
42193
|
+
/* harmony export */ "VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ victory_voronoi_container__WEBPACK_IMPORTED_MODULE_25__.VICTORY_VORONOI_CONTAINER_DEFAULT_PROPS; },
|
|
42194
|
+
/* harmony export */ "VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS": function() { return /* reexport safe */ victory_zoom_container__WEBPACK_IMPORTED_MODULE_26__.VICTORY_ZOOM_CONTAINER_DEFAULT_PROPS; },
|
|
42384
42195
|
/* harmony export */ "VictoryAccessibleGroup": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.VictoryAccessibleGroup; },
|
|
42385
42196
|
/* harmony export */ "VictoryAnimation": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.VictoryAnimation; },
|
|
42386
42197
|
/* harmony export */ "VictoryArea": function() { return /* reexport safe */ victory_area__WEBPACK_IMPORTED_MODULE_0__.VictoryArea; },
|
|
@@ -42419,10 +42230,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
42419
42230
|
/* harmony export */ "Wrapper": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.Wrapper; },
|
|
42420
42231
|
/* harmony export */ "ZoomHelpers": function() { return /* reexport safe */ victory_zoom_container__WEBPACK_IMPORTED_MODULE_26__.ZoomHelpers; },
|
|
42421
42232
|
/* harmony export */ "addEvents": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.addEvents; },
|
|
42422
|
-
/* harmony export */ "brushContainerMixin": function() { return /* reexport safe */ victory_brush_container__WEBPACK_IMPORTED_MODULE_4__.brushContainerMixin; },
|
|
42423
|
-
/* harmony export */ "combineContainerMixins": function() { return /* reexport safe */ victory_create_container__WEBPACK_IMPORTED_MODULE_10__.combineContainerMixins; },
|
|
42424
42233
|
/* harmony export */ "createContainer": function() { return /* reexport safe */ victory_create_container__WEBPACK_IMPORTED_MODULE_10__.createContainer; },
|
|
42425
|
-
/* harmony export */ "cursorContainerMixin": function() { return /* reexport safe */ victory_cursor_container__WEBPACK_IMPORTED_MODULE_11__.cursorContainerMixin; },
|
|
42426
42234
|
/* harmony export */ "getBarPath": function() { return /* reexport safe */ victory_bar__WEBPACK_IMPORTED_MODULE_2__.getBarPath; },
|
|
42427
42235
|
/* harmony export */ "getBarPosition": function() { return /* reexport safe */ victory_bar__WEBPACK_IMPORTED_MODULE_2__.getBarPosition; },
|
|
42428
42236
|
/* harmony export */ "getBarWidth": function() { return /* reexport safe */ victory_bar__WEBPACK_IMPORTED_MODULE_2__.getBarWidth; },
|
|
@@ -42434,10 +42242,15 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
42434
42242
|
/* harmony export */ "getVerticalBarPath": function() { return /* reexport safe */ victory_bar__WEBPACK_IMPORTED_MODULE_2__.getVerticalBarPath; },
|
|
42435
42243
|
/* harmony export */ "getVerticalPolarBarPath": function() { return /* reexport safe */ victory_bar__WEBPACK_IMPORTED_MODULE_2__.getVerticalPolarBarPath; },
|
|
42436
42244
|
/* harmony export */ "makeCreateContainerFunction": function() { return /* reexport safe */ victory_create_container__WEBPACK_IMPORTED_MODULE_10__.makeCreateContainerFunction; },
|
|
42437
|
-
/* harmony export */ "
|
|
42245
|
+
/* harmony export */ "mergeRefs": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.mergeRefs; },
|
|
42438
42246
|
/* harmony export */ "useCanvasContext": function() { return /* reexport safe */ victory_canvas__WEBPACK_IMPORTED_MODULE_7__.useCanvasContext; },
|
|
42439
|
-
/* harmony export */ "
|
|
42440
|
-
/* harmony export */ "
|
|
42247
|
+
/* harmony export */ "usePortalContext": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.usePortalContext; },
|
|
42248
|
+
/* harmony export */ "useVictoryBrushContainer": function() { return /* reexport safe */ victory_brush_container__WEBPACK_IMPORTED_MODULE_4__.useVictoryBrushContainer; },
|
|
42249
|
+
/* harmony export */ "useVictoryContainer": function() { return /* reexport safe */ victory_core__WEBPACK_IMPORTED_MODULE_9__.useVictoryContainer; },
|
|
42250
|
+
/* harmony export */ "useVictoryCursorContainer": function() { return /* reexport safe */ victory_cursor_container__WEBPACK_IMPORTED_MODULE_11__.useVictoryCursorContainer; },
|
|
42251
|
+
/* harmony export */ "useVictorySelectionContainer": function() { return /* reexport safe */ victory_selection_container__WEBPACK_IMPORTED_MODULE_20__.useVictorySelectionContainer; },
|
|
42252
|
+
/* harmony export */ "useVictoryVoronoiContainer": function() { return /* reexport safe */ victory_voronoi_container__WEBPACK_IMPORTED_MODULE_25__.useVictoryVoronoiContainer; },
|
|
42253
|
+
/* harmony export */ "useVictoryZoomContainer": function() { return /* reexport safe */ victory_zoom_container__WEBPACK_IMPORTED_MODULE_26__.useVictoryZoomContainer; }
|
|
42441
42254
|
/* harmony export */ });
|
|
42442
42255
|
/* harmony import */ var victory_area__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! victory-area */ "../../victory-area/es/index.js");
|
|
42443
42256
|
/* harmony import */ var victory_axis__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! victory-axis */ "../../victory-axis/es/index.js");
|