@stemy/ngx-utils 19.4.7 → 19.4.9
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.
|
@@ -1734,7 +1734,7 @@ class Rect {
|
|
|
1734
1734
|
this.rotation = rotation;
|
|
1735
1735
|
}
|
|
1736
1736
|
distance(p) {
|
|
1737
|
-
p = p.rotateAround(this.center, -this.rotation);
|
|
1737
|
+
p = new Point(p.x, p.y).rotateAround(this.center, -this.rotation);
|
|
1738
1738
|
const x = Math.max(this.left - p.x, 0, p.x - this.right);
|
|
1739
1739
|
const y = Math.max(this.bottom - p.y, 0, p.y - this.top);
|
|
1740
1740
|
return Math.sqrt(x * x + y * y);
|
|
@@ -6904,9 +6904,9 @@ class InteractiveItemComponent {
|
|
|
6904
6904
|
this.pos = new Point(this.pos.x, value);
|
|
6905
6905
|
}
|
|
6906
6906
|
set position(value) {
|
|
6907
|
-
if (
|
|
6907
|
+
if (typeof value !== "object" || isNaN(value.x) || isNaN(value.y))
|
|
6908
6908
|
return;
|
|
6909
|
-
this.pos = value;
|
|
6909
|
+
this.pos = new Point(value.x, value.y);
|
|
6910
6910
|
}
|
|
6911
6911
|
get shapes() {
|
|
6912
6912
|
return this.mShapes;
|