victory-area 37.3.1 → 37.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # victory-area
2
2
 
3
+ ## 37.3.2
4
+
3
5
  ## 37.3.1
4
6
 
5
7
  ### Patch Changes
@@ -355,7 +355,7 @@ const options = {
355
355
  }]
356
356
  };
357
357
 
358
- // eslint-disable-next-line @typescript-eslint/no-empty-interface
358
+ // eslint-disable-next-line @typescript-eslint/no-empty-object-type
359
359
 
360
360
  /**
361
361
  * Draw area charts with React. VictoryArea is a composable component, so it doesn't include axes.
@@ -4966,7 +4966,7 @@ const interpolateFunction = function (a, b) {
4966
4966
  return b;
4967
4967
  }
4968
4968
  return function () {
4969
- /* eslint-disable no-invalid-this, prefer-rest-params */
4969
+ /* eslint-disable prefer-rest-params */
4970
4970
  const aval = typeof a === "function" ? a.apply(this, arguments) : a;
4971
4971
  const bval = typeof b === "function" ? b.apply(this, arguments) : b;
4972
4972
  return (0,victory_vendor_d3_interpolate__WEBPACK_IMPORTED_MODULE_2__.interpolate)(aval, bval)(t);
@@ -5553,9 +5553,9 @@ const VictoryContainer = initialProps => {
5553
5553
  ...style,
5554
5554
  width: responsive ? style?.width : dimensions.width,
5555
5555
  height: responsive ? style?.height : dimensions.height,
5556
- pointerEvents: "none",
5557
- touchAction: "none",
5558
- position: "relative"
5556
+ pointerEvents: style?.pointerEvents ?? "none",
5557
+ touchAction: style?.touchAction ?? "none",
5558
+ position: style?.position ?? "relative"
5559
5559
  },
5560
5560
  "data-ouia-component-id": ouiaId,
5561
5561
  "data-ouia-component-type": ouiaType,
@@ -7673,7 +7673,7 @@ class VictoryTransition extends (react__WEBPACK_IMPORTED_MODULE_2___default().Co
7673
7673
  componentDidMount() {
7674
7674
  this.setState({
7675
7675
  nodesShouldLoad: true
7676
- }); // eslint-disable-line react/no-did-mount-set-state
7676
+ });
7677
7677
  }
7678
7678
  shouldComponentUpdate(nextProps) {
7679
7679
  if (!react_fast_compare__WEBPACK_IMPORTED_MODULE_3___default()(this.props, nextProps)) {
@@ -7887,7 +7887,7 @@ const defaultComponents = [{
7887
7887
  function addEvents(WrappedComponent, options) {
7888
7888
  if (options === void 0) {
7889
7889
  options = {};
7890
- } // eslint-disable-next-line @typescript-eslint/no-empty-interface
7890
+ } // eslint-disable-next-line @typescript-eslint/no-empty-object-type
7891
7891
  // @ts-expect-error "TS2545: A mixin class must have a constructor with a single rest parameter of type 'any[]'."
7892
7892
  class AddEventsMixin extends WrappedComponent {
7893
7893
  constructor(props) {
@@ -8256,7 +8256,6 @@ __webpack_require__.r(__webpack_exports__);
8256
8256
 
8257
8257
 
8258
8258
 
8259
- /* eslint-disable no-use-before-define */
8260
8259
 
8261
8260
 
8262
8261
 
@@ -8382,8 +8381,6 @@ function formatDataFromDomain(dataset, domain, defaultBaseline) {
8382
8381
  const isUnderMinY = underMin(minDomainY);
8383
8382
  const isOverMaxX = overMax(maxDomainX);
8384
8383
  const isOverMaxY = overMax(maxDomainY);
8385
-
8386
- // eslint-disable-next-line complexity
8387
8384
  return dataset.map(datum => {
8388
8385
  let {
8389
8386
  _x,
@@ -8494,7 +8491,6 @@ function formatData(dataset, props, expectedKeys) {
8494
8491
  };
8495
8492
  }
8496
8493
  const data = preformattedData ? dataset : dataset.reduce((dataArr, datum, index) => {
8497
- // eslint-disable-line complexity
8498
8494
  const parsedDatum = parseDatum(datum);
8499
8495
  const fallbackValues = {
8500
8496
  x: index,
@@ -8791,7 +8787,6 @@ __webpack_require__.r(__webpack_exports__);
8791
8787
 
8792
8788
 
8793
8789
 
8794
- /* eslint-disable no-use-before-define */
8795
8790
 
8796
8791
 
8797
8792
 
@@ -8847,8 +8842,6 @@ function getExtremeFromData(dataset, axis, type) {
8847
8842
  }, initialValue);
8848
8843
  return containsDate ? new Date(result) : result;
8849
8844
  }
8850
-
8851
- // eslint-disable-next-line max-statements
8852
8845
  function padDomain(domain, props, axis) {
8853
8846
  if (!props.domainPadding) {
8854
8847
  return domain;
@@ -9184,7 +9177,6 @@ __webpack_require__.r(__webpack_exports__);
9184
9177
 
9185
9178
 
9186
9179
 
9187
- /* eslint-disable no-use-before-define */
9188
9180
 
9189
9181
  const GLOBAL_EVENT_REGEX = /^onGlobal(.*)$/;
9190
9182
 
@@ -9232,11 +9224,10 @@ getScopedEvents) {
9232
9224
  */
9233
9225
  const getAllEvents = () => {
9234
9226
  // Mandatory usage: `getEvents.bind(this)`
9235
- /* eslint-disable no-invalid-this */
9227
+
9236
9228
  if (Array.isArray(this.componentEvents)) {
9237
9229
  return Array.isArray(props.events) ? this.componentEvents.concat(...props.events) : this.componentEvents;
9238
9230
  }
9239
- /* eslint-enable no-invalid-this */
9240
9231
  return props.events;
9241
9232
  };
9242
9233
  const allEvents = getAllEvents();
@@ -9261,7 +9252,7 @@ function getScopedEvents(events, namespace, childType, baseProps) {
9261
9252
  }
9262
9253
 
9263
9254
  // Mandatory usage: `getScopedEvents.bind(this)`
9264
- // eslint-disable-next-line no-invalid-this
9255
+
9265
9256
  const newBaseProps = baseProps || this.baseProps;
9266
9257
  // returns the original base props or base state of a given target element
9267
9258
  const getTargetProps = (identifier, type) => {
@@ -9270,7 +9261,6 @@ function getScopedEvents(events, namespace, childType, baseProps) {
9270
9261
  target,
9271
9262
  key
9272
9263
  } = identifier;
9273
- // eslint-disable-next-line no-invalid-this
9274
9264
  const baseType = type === "props" ? newBaseProps : this.state || {};
9275
9265
  const base = childName === undefined || childName === null || !baseType[childName] ? baseType : baseType[childName];
9276
9266
  return key === "parent" ? base.parent : base[key] && base[key][target];
@@ -9297,7 +9287,6 @@ function getScopedEvents(events, namespace, childType, baseProps) {
9297
9287
 
9298
9288
  // returns the state object with mutated props applied for a single key
9299
9289
  const getMutationObject = (key, childName) => {
9300
- // eslint-disable-next-line no-invalid-this
9301
9290
  const baseState = this.state || {};
9302
9291
  if (!(0,_helpers__WEBPACK_IMPORTED_MODULE_4__.isFunction)(eventReturn.mutation)) {
9303
9292
  return baseState;
@@ -9370,11 +9359,9 @@ function getScopedEvents(events, namespace, childType, baseProps) {
9370
9359
  // into a state mutation, and calls setState
9371
9360
  // eslint-disable-next-line max-params
9372
9361
  const onEvent = (evt, childProps, eventKey, eventName) => {
9373
- // eslint-disable-next-line no-invalid-this
9374
9362
  const eventReturn = events[eventName](evt, childProps, eventKey, this);
9375
9363
  if (!lodash_isEmpty__WEBPACK_IMPORTED_MODULE_3___default()(eventReturn)) {
9376
9364
  const callbacks = compileCallbacks(eventReturn);
9377
- // eslint-disable-next-line no-invalid-this
9378
9365
  this.setState(parseEventReturn(eventReturn, eventKey), callbacks);
9379
9366
  }
9380
9367
  };
@@ -9404,7 +9391,7 @@ function getPartialEvents(events, eventKey, childProps) {
9404
9391
  // eslint-disable-next-line max-params
9405
9392
  function getEventState(eventKey, namespace, childType) {
9406
9393
  // Mandatory usage: `getEventState.bind(this)`
9407
- // eslint-disable-next-line no-invalid-this
9394
+
9408
9395
  const state = this.state || {};
9409
9396
  if (!childType) {
9410
9397
  return eventKey === "parent" ? state[eventKey] && state[eventKey][namespace] || state[eventKey] : state[eventKey] && state[eventKey][namespace];
@@ -9597,7 +9584,6 @@ __webpack_require__.r(__webpack_exports__);
9597
9584
 
9598
9585
 
9599
9586
 
9600
- /* eslint-disable no-use-before-define */
9601
9587
 
9602
9588
  // Private Functions
9603
9589
 
@@ -10066,7 +10052,6 @@ __webpack_require__.r(__webpack_exports__);
10066
10052
  /* harmony import */ var lodash_defaults__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_defaults__WEBPACK_IMPORTED_MODULE_0__);
10067
10053
  /* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./helpers */ "../../victory-core/es/victory-util/helpers.js");
10068
10054
 
10069
- /* eslint-disable no-use-before-define */
10070
10055
 
10071
10056
  // Private Functions
10072
10057
 
@@ -10452,7 +10437,6 @@ __webpack_require__.r(__webpack_exports__);
10452
10437
  /* harmony import */ var _collection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./collection */ "../../victory-core/es/victory-util/collection.js");
10453
10438
  /* harmony import */ var victory_vendor_d3_scale__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! victory-vendor/d3-scale */ "../../victory-vendor/es/d3-scale.js");
10454
10439
 
10455
- /* eslint-disable no-use-before-define */
10456
10440
 
10457
10441
 
10458
10442
 
@@ -11243,8 +11227,6 @@ function getChildBeforeLoad(animate, child, data, cb) {
11243
11227
  clipWidth: 0
11244
11228
  };
11245
11229
  }
11246
-
11247
- // eslint-disable-next-line max-params
11248
11230
  function getChildOnLoad(animate, data, cb) {
11249
11231
  const newAnimate = Object.assign({}, animate, {
11250
11232
  onEnd: cb
@@ -11267,7 +11249,7 @@ function getChildOnLoad(animate, data, cb) {
11267
11249
  };
11268
11250
  }
11269
11251
 
11270
- // eslint-disable-next-line max-params, max-len
11252
+ // eslint-disable-next-line max-params
11271
11253
  function getChildPropsOnExit(animate, child, data, exitingNodes, cb) {
11272
11254
  // Whether or not _this_ child has exiting nodes, we want the exit-
11273
11255
  // transition for all children to have the same duration, delay, etc.
@@ -11291,7 +11273,7 @@ function getChildPropsOnExit(animate, child, data, exitingNodes, cb) {
11291
11273
  };
11292
11274
  }
11293
11275
 
11294
- // eslint-disable-next-line max-params,max-len
11276
+ // eslint-disable-next-line max-params
11295
11277
  function getChildPropsBeforeEnter(animate, child, data, enteringNodes, cb) {
11296
11278
  let newAnimate = animate;
11297
11279
  let newData = data;
@@ -11316,7 +11298,7 @@ function getChildPropsBeforeEnter(animate, child, data, enteringNodes, cb) {
11316
11298
  };
11317
11299
  }
11318
11300
 
11319
- // eslint-disable-next-line max-params, max-len
11301
+ // eslint-disable-next-line max-params
11320
11302
  function getChildPropsOnEnter(animate, data, enteringNodes, cb) {
11321
11303
  // Whether or not _this_ child has entering nodes, we want the entering-
11322
11304
  // transition for all children to have the same duration, delay, etc.
@@ -11423,8 +11405,6 @@ function getTransitionPropsFactory(props, state, setState) {
11423
11405
  }
11424
11406
  return {};
11425
11407
  };
11426
-
11427
- // eslint-disable-next-line max-statements, complexity, max-len
11428
11408
  return function getTransitionProps(child, index) {
11429
11409
  const data = getChildData(child) || [];
11430
11410
  const animate = lodash_defaults__WEBPACK_IMPORTED_MODULE_1___default()({}, props.animate, child.props.animate);