Browse Source

remove redundant import

pull/10142/head
Your Name 2 months ago
parent
commit
99b6557e9a
  1. 2
      packages/math/src/angle.ts
  2. 2
      packages/math/src/point.ts
  3. 2
      packages/math/src/polygon.ts
  4. 4
      packages/math/src/types.ts

2
packages/math/src/angle.ts

@ -3,8 +3,6 @@ import { PRECISION } from "./utils"; @@ -3,8 +3,6 @@ import { PRECISION } from "./utils";
import type {
Degrees,
GenericPoint,
GlobalPoint,
LocalPoint,
PolarCoords,
Radians,
} from "./types";

2
packages/math/src/point.ts

@ -3,8 +3,6 @@ import { PRECISION } from "./utils"; @@ -3,8 +3,6 @@ import { PRECISION } from "./utils";
import { vectorFromPoint, vectorScale } from "./vector";
import type {
LocalPoint,
GlobalPoint,
Radians,
Degrees,
Vector,

2
packages/math/src/polygon.ts

@ -2,7 +2,7 @@ import { pointsEqual } from "./point"; @@ -2,7 +2,7 @@ import { pointsEqual } from "./point";
import { lineSegment, pointOnLineSegment } from "./segment";
import { PRECISION } from "./utils";
import type { GenericPoint, GlobalPoint, LocalPoint, Polygon } from "./types";
import type { GenericPoint, Polygon } from "./types";
export function polygon<Point extends GenericPoint>(
...points: Point[]

4
packages/math/src/types.ts

@ -21,13 +21,13 @@ export type Degrees = number & { _brand: "excalimath_degree" }; @@ -21,13 +21,13 @@ export type Degrees = number & { _brand: "excalimath_degree" };
/**
* A number range which includes the start and end numbers in the range.
*/
export type InclusiveRange = ViewportPoint & { _brand: "excalimath_degree" };
export type InclusiveRange = [number, number] & { _brand: "excalimath_degree" };
//
// Point
//
export type ViewportPoint = [x: number, y: number];
type ViewportPoint = [x: number, y: number];
/**
* Represents a 2D position in world or canvas space. A

Loading…
Cancel
Save