bk-magic-vue 2.4.8-beta.2 → 2.4.8-beta.3

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.
@@ -36138,9 +36138,12 @@
36138
36138
  } else if (newPosition > 100) {
36139
36139
  newPosition = 100;
36140
36140
  }
36141
- var lengthPerStep = 100 / ((this.maxValue - this.minValue) / this.step);
36141
+ var maxValue = _parseFloat$2(this.maxValue);
36142
+ var minValue = _parseFloat$2(this.minValue);
36143
+ var step = _parseFloat$2(this.step);
36144
+ var lengthPerStep = 100 / ((maxValue - minValue) / step);
36142
36145
  var steps = Math.round(newPosition / lengthPerStep);
36143
- var value = steps * lengthPerStep * (this.maxValue - this.minValue) * 0.01 + this.minValue;
36146
+ var value = steps * lengthPerStep * (maxValue - minValue) * 0.01 + minValue;
36144
36147
  value = _parseFloat$2(value.toFixed(this.precision));
36145
36148
  this.$emit('input', value);
36146
36149
  if (!this.dragging && this.value !== this.oldValue) {
@@ -36396,13 +36399,15 @@
36396
36399
  console.warn('WARNNING:step should not be 0');
36397
36400
  return [];
36398
36401
  }
36399
- var stepCount = (this.maxValue - this.minValue) / this.step;
36400
36402
  var stepWidth = 100 * this.step / (this.maxValue - this.minValue);
36401
36403
  var result = [];
36402
- for (var i = 0; i <= stepCount; i++) {
36404
+ var minValue = _parseFloat$2(this.minValue);
36405
+ var maxValue = _parseFloat$2(this.maxValue);
36406
+ var step = _parseFloat$2(this.step);
36407
+ for (var i = minValue, j = 0; i <= maxValue; i += step, j++) {
36403
36408
  var item = {
36404
- stepWidth: i * stepWidth,
36405
- stepLabel: "".concat(i * this.step).concat(this.intervalLabelUnit)
36409
+ stepWidth: j * stepWidth,
36410
+ stepLabel: "".concat(i).concat(this.intervalLabelUnit)
36406
36411
  };
36407
36412
  result.push(item);
36408
36413
  }