cx 24.6.1 → 24.6.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/dist/charts.js CHANGED
@@ -3216,7 +3216,7 @@ var LineGraph = /*#__PURE__*/ (function (_Widget) {
3216
3216
  context.pointReducer(x, p[_this.y0Field], data.name, p, data, index);
3217
3217
  }
3218
3218
  }
3219
- if (context.pointReducer) context.pointReducer(x, p[_this.yField], data.name, p, data, index);
3219
+ if (context.pointReducer) context.pointReducer(x, p[_this.yField], data.name, p, data.data, index);
3220
3220
  });
3221
3221
  }
3222
3222
  }
@@ -3497,7 +3497,7 @@ var ColumnGraph = /*#__PURE__*/ (function (_ColumnBarGraphBase) {
3497
3497
  if (!_this.hiddenBase) yAxis.acknowledge(y0);
3498
3498
  yAxis.acknowledge(y);
3499
3499
  }
3500
- if (context.pointReducer) context.pointReducer(x, y, data.name, p, data, index);
3500
+ if (context.pointReducer) context.pointReducer(x, y, data.name, p, data.data, index);
3501
3501
  });
3502
3502
  }
3503
3503
  };
@@ -5308,8 +5308,10 @@ var SnapPointFinder = /*#__PURE__*/ (function (_PointReducer) {
5308
5308
  };
5309
5309
  _proto.onMap = function onMap(acc, x, y, name, p) {
5310
5310
  var d = null;
5311
- if (acc.cursorX != null && x != null) d = (d || 0) + Math.pow(Math.abs(x - acc.cursorX), 2);
5312
- if (acc.cursorY != null && y != null) d = (d || 0) + Math.pow(Math.abs(y - acc.cursorY), 2);
5311
+ var cx = this.convertX(x);
5312
+ var cy = this.convertY(y);
5313
+ if (acc.cursorX != null && cx != null) d = (d || 0) + Math.pow(Math.abs(cx - acc.cursorX), 2);
5314
+ if (acc.cursorY != null && cy != null) d = (d || 0) + Math.pow(Math.abs(cy - acc.cursorY), 2);
5313
5315
  if (d != null && d < acc.dist) {
5314
5316
  acc.dist = d;
5315
5317
  acc.snapX = x;
@@ -5325,6 +5327,12 @@ var SnapPointFinder = /*#__PURE__*/ (function (_PointReducer) {
5325
5327
  return SnapPointFinder;
5326
5328
  })(PointReducer);
5327
5329
  SnapPointFinder.prototype.maxDistance = 50;
5330
+ SnapPointFinder.prototype.convertX = function (x) {
5331
+ return x;
5332
+ };
5333
+ SnapPointFinder.prototype.convertY = function (y) {
5334
+ return y;
5335
+ };
5328
5336
 
5329
5337
  var ValueAtFinder = /*#__PURE__*/ (function (_PointReducer) {
5330
5338
  function ValueAtFinder() {