evui 3.4.144 → 3.4.145

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.
@@ -11227,7 +11227,7 @@ var update = add("9519e5b6", content, true, {"sourceMap":false,"shadowMode":fals
11227
11227
  /***/ "9224":
11228
11228
  /***/ (function(module) {
11229
11229
 
11230
- module.exports = JSON.parse("{\"a\":\"3.4.144\"}");
11230
+ module.exports = JSON.parse("{\"a\":\"3.4.145\"}");
11231
11231
 
11232
11232
  /***/ }),
11233
11233
 
@@ -44467,31 +44467,77 @@ var element_heatmap_HeatMap = /*#__PURE__*/function () {
44467
44467
  ctx.restore();
44468
44468
  }
44469
44469
  /**
44470
- *Returns items in range
44471
- * @param {object} params range values
44472
- *
44473
- * @returns {array}
44470
+ * 자바스크립트 부동 소수점 오차 때문에 범위를 조정
44471
+ * @param {object} params - range information
44472
+ * @param {number} params.xp - start x position
44473
+ * @param {number} params.yp - start y position
44474
+ * @param {number} params.width - width
44475
+ * @param {number} params.height - height
44476
+ * @returns {object} adjusted range
44474
44477
  */
44475
44478
 
44476
44479
  }, {
44477
- key: "findItems",
44478
- value: function findItems(_ref3) {
44479
- var xsp = _ref3.xsp,
44480
- ysp = _ref3.ysp,
44480
+ key: "getAdjustedBounds",
44481
+ value: function getAdjustedBounds(_ref3) {
44482
+ var xp = _ref3.xp,
44483
+ yp = _ref3.yp,
44481
44484
  width = _ref3.width,
44482
44485
  height = _ref3.height;
44486
+ var PRECISION = 100;
44487
+ var adjustedWidth = Math.max(0, width);
44488
+ var adjustedHeight = Math.max(0, height);
44489
+ return {
44490
+ xsp: Math.floor(xp * PRECISION) / PRECISION,
44491
+ xep: Math.ceil((xp + adjustedWidth) * PRECISION) / PRECISION,
44492
+ ysp: Math.floor(yp * PRECISION) / PRECISION,
44493
+ yep: Math.ceil((yp + adjustedHeight) * PRECISION) / PRECISION
44494
+ };
44495
+ }
44496
+ /**
44497
+ *Returns items in range
44498
+ * @param {object} params - range information
44499
+ * @param {number} params.xsp - start x position
44500
+ * @param {number} params.width - width
44501
+ * @param {number} params.ysp - start y position
44502
+ * @param {number} params.height - height
44503
+ * @returns {array} items in range
44504
+ */
44505
+
44506
+ }, {
44507
+ key: "findItems",
44508
+ value: function findItems(params) {
44509
+ var _this3 = this;
44510
+
44483
44511
  var gdata = this.data;
44484
- var xep = xsp + width;
44485
- var yep = ysp + height;
44512
+
44513
+ var _this$getAdjustedBoun = this.getAdjustedBounds({
44514
+ xp: params.xsp,
44515
+ yp: params.ysp,
44516
+ width: params.width,
44517
+ height: params.height
44518
+ }),
44519
+ xsp = _this$getAdjustedBoun.xsp,
44520
+ xep = _this$getAdjustedBoun.xep,
44521
+ ysp = _this$getAdjustedBoun.ysp,
44522
+ yep = _this$getAdjustedBoun.yep;
44523
+
44486
44524
  return gdata.filter(function (_ref4) {
44487
44525
  var xp = _ref4.xp,
44488
44526
  yp = _ref4.yp,
44489
44527
  w = _ref4.w,
44490
44528
  h = _ref4.h;
44491
- var x1 = xp;
44492
- var x2 = xp + w;
44493
- var y1 = yp;
44494
- var y2 = yp + h;
44529
+
44530
+ var _this3$getAdjustedBou = _this3.getAdjustedBounds({
44531
+ xp: xp,
44532
+ yp: yp,
44533
+ width: w,
44534
+ height: h
44535
+ }),
44536
+ x1 = _this3$getAdjustedBou.xsp,
44537
+ x2 = _this3$getAdjustedBou.xep,
44538
+ y1 = _this3$getAdjustedBou.ysp,
44539
+ y2 = _this3$getAdjustedBou.yep;
44540
+
44495
44541
  return x1 >= xsp && x2 <= xep && y1 >= ysp && y2 <= yep;
44496
44542
  });
44497
44543
  }
@@ -44677,6 +44723,8 @@ var element_heatmap_HeatMap = /*#__PURE__*/function () {
44677
44723
 
44678
44724
  if (findItem > -1) {
44679
44725
  point[key] = ['xsp', 'ysp'].includes(key) ? itemPoint : itemPoint + gap;
44726
+ } else if (target < startPoint) {
44727
+ point[key] = startPoint;
44680
44728
  }
44681
44729
  };
44682
44730