@immugio/three-math-extensions 0.2.35 → 0.2.36

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/CHANGELOG.md CHANGED
@@ -7,7 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
9
9
 
10
- ## [0.2.35](https://github.com/Immugio/three-math-extensions/compare/0.2.34...0.2.35)
10
+ ## [0.2.36](https://github.com/Immugio/three-math-extensions/compare/0.2.35...0.2.36)
11
+
12
+ ### Commits
13
+
14
+ - Polygon.containsPoint should accept Point2 [`73e766c`](https://github.com/Immugio/three-math-extensions/commit/73e766c9f03903224c0634947b116aa3e0f6f9bd)
15
+
16
+ ## [0.2.35](https://github.com/Immugio/three-math-extensions/compare/0.2.34...0.2.35) - 2024-10-24
11
17
 
12
18
  ### Commits
13
19
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@immugio/three-math-extensions",
3
- "version": "0.2.35",
3
+ "version": "0.2.36",
4
4
  "description": "Set of utilities for 2d and 3d line math built on top of three.js",
5
5
  "author": "Jan Mikeska <janmikeska@gmail.com>",
6
6
  "license": "ISC",
package/src/Polygon.ts CHANGED
@@ -139,7 +139,7 @@ export class Polygon {
139
139
  return this;
140
140
  }
141
141
 
142
- public containsPoint(...points: Vec2[]): boolean {
142
+ public containsPoint(...points: Point2[]): boolean {
143
143
  return points.every(point => containsPoint(this.contour, point)) &&
144
144
  (this.holes || []).every(hole => !points.some(point => containsPoint(hole, point)));
145
145
  }
@@ -20,7 +20,7 @@ export declare class Polygon {
20
20
  perimeter(): number;
21
21
  get isClockwise(): boolean;
22
22
  ensureClockwise(): this;
23
- containsPoint(...points: Vec2[]): boolean;
23
+ containsPoint(...points: Point2[]): boolean;
24
24
  private flipSingle;
25
25
  translate(translate: Vec2): this;
26
26
  /**