igniteui-angular 15.1.26 → 15.1.27
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/esm2020/lib/slider/slider.component.mjs +19 -19
- package/fesm2015/igniteui-angular.mjs +18 -18
- package/fesm2015/igniteui-angular.mjs.map +1 -1
- package/fesm2020/igniteui-angular.mjs +18 -18
- package/fesm2020/igniteui-angular.mjs.map +1 -1
- package/lib/slider/slider.component.d.ts +0 -1
- package/package.json +1 -1
|
@@ -86481,6 +86481,7 @@ class IgxSliderComponent {
|
|
|
86481
86481
|
const adjustedValue = this.valueInRange(value, this.lowerBound, this.upperBound);
|
|
86482
86482
|
if (this._lowerValue !== adjustedValue) {
|
|
86483
86483
|
this._lowerValue = adjustedValue;
|
|
86484
|
+
this.lowerValueChange.emit(this._lowerValue);
|
|
86484
86485
|
this.value = { lower: this._lowerValue, upper: this._upperValue };
|
|
86485
86486
|
}
|
|
86486
86487
|
}
|
|
@@ -86515,6 +86516,7 @@ class IgxSliderComponent {
|
|
|
86515
86516
|
const adjustedValue = this.valueInRange(value, this.lowerBound, this.upperBound);
|
|
86516
86517
|
if (this._upperValue !== adjustedValue) {
|
|
86517
86518
|
this._upperValue = adjustedValue;
|
|
86519
|
+
this.upperValueChange.emit(this._upperValue);
|
|
86518
86520
|
this.value = { lower: this._lowerValue, upper: this._upperValue };
|
|
86519
86521
|
}
|
|
86520
86522
|
}
|
|
@@ -86681,27 +86683,25 @@ class IgxSliderComponent {
|
|
|
86681
86683
|
const oldValue = this.value;
|
|
86682
86684
|
if (this.isRange) {
|
|
86683
86685
|
if (thumbType === SliderHandle.FROM) {
|
|
86684
|
-
|
|
86685
|
-
|
|
86686
|
-
this._lowerValue = newLower;
|
|
86687
|
-
this.lowerValueChange.emit(this._lowerValue);
|
|
86686
|
+
if (this.lowerValue + value > this.upperValue) {
|
|
86687
|
+
this.upperValue = this.lowerValue + value;
|
|
86688
86688
|
}
|
|
86689
|
+
this.lowerValue += value;
|
|
86689
86690
|
}
|
|
86690
86691
|
else {
|
|
86691
|
-
|
|
86692
|
-
|
|
86693
|
-
this._upperValue = newUpper;
|
|
86694
|
-
this.upperValueChange.emit(this._upperValue);
|
|
86692
|
+
if (this.upperValue + value < this.lowerValue) {
|
|
86693
|
+
this.lowerValue = this.upperValue + value;
|
|
86695
86694
|
}
|
|
86695
|
+
this.upperValue += value;
|
|
86696
86696
|
}
|
|
86697
86697
|
const newVal = {
|
|
86698
|
-
lower: this.
|
|
86699
|
-
upper: this.
|
|
86698
|
+
lower: this.lowerValue,
|
|
86699
|
+
upper: this.upperValue
|
|
86700
86700
|
};
|
|
86701
86701
|
// Swap the thumbs if a collision appears.
|
|
86702
|
-
if (newVal.lower == newVal.upper) {
|
|
86703
|
-
|
|
86704
|
-
}
|
|
86702
|
+
// if (newVal.lower == newVal.upper) {
|
|
86703
|
+
// this.toggleThumb();
|
|
86704
|
+
// }
|
|
86705
86705
|
this.value = newVal;
|
|
86706
86706
|
}
|
|
86707
86707
|
else {
|
|
@@ -86779,11 +86779,11 @@ class IgxSliderComponent {
|
|
|
86779
86779
|
calculateStepDistance() {
|
|
86780
86780
|
return this._el.nativeElement.getBoundingClientRect().width / (this.maxValue - this.minValue) * this.step;
|
|
86781
86781
|
}
|
|
86782
|
-
toggleThumb() {
|
|
86783
|
-
|
|
86784
|
-
|
|
86785
|
-
|
|
86786
|
-
}
|
|
86782
|
+
// private toggleThumb() {
|
|
86783
|
+
// return this.thumbFrom.isActive ?
|
|
86784
|
+
// this.thumbTo.nativeElement.focus() :
|
|
86785
|
+
// this.thumbFrom.nativeElement.focus();
|
|
86786
|
+
// }
|
|
86787
86787
|
valueInRange(value, min = 0, max = 100) {
|
|
86788
86788
|
return Math.max(Math.min(value, max), min);
|
|
86789
86789
|
}
|