@thi.ng/math 5.0.0 → 5.0.4

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
@@ -3,6 +3,38 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [5.0.4](https://github.com/thi-ng/umbrella/compare/@thi.ng/math@5.0.3...@thi.ng/math@5.0.4) (2021-10-25)
7
+
8
+ **Note:** Version bump only for package @thi.ng/math
9
+
10
+
11
+
12
+
13
+
14
+ ## [5.0.3](https://github.com/thi-ng/umbrella/compare/@thi.ng/math@5.0.2...@thi.ng/math@5.0.3) (2021-10-15)
15
+
16
+ **Note:** Version bump only for package @thi.ng/math
17
+
18
+
19
+
20
+
21
+
22
+ ## [5.0.2](https://github.com/thi-ng/umbrella/compare/@thi.ng/math@5.0.1...@thi.ng/math@5.0.2) (2021-10-15)
23
+
24
+ **Note:** Version bump only for package @thi.ng/math
25
+
26
+
27
+
28
+
29
+
30
+ ## [5.0.1](https://github.com/thi-ng/umbrella/compare/@thi.ng/math@5.0.0...@thi.ng/math@5.0.1) (2021-10-13)
31
+
32
+ **Note:** Version bump only for package @thi.ng/math
33
+
34
+
35
+
36
+
37
+
6
38
  # [5.0.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/math@4.0.6...@thi.ng/math@5.0.0) (2021-10-12)
7
39
 
8
40
 
package/README.md CHANGED
@@ -62,10 +62,11 @@ ES module import:
62
62
 
63
63
  [Skypack documentation](https://docs.skypack.dev/)
64
64
 
65
- For NodeJS (v14.6+):
65
+ For Node.js REPL:
66
66
 
67
67
  ```text
68
- node --experimental-specifier-resolution=node --experimental-repl-await
68
+ # with flag only for < v16
69
+ node --experimental-repl-await
69
70
 
70
71
  > const math = await import("@thi.ng/math");
71
72
  ```
package/abs.js CHANGED
@@ -1,3 +1,3 @@
1
- import { EPS } from "./api";
1
+ import { EPS } from "./api.js";
2
2
  export const absDiff = (x, y) => Math.abs(x - y);
3
3
  export const sign = (x, eps = EPS) => (x > eps ? 1 : x < -eps ? -1 : 0);
package/angle.js CHANGED
@@ -1,4 +1,4 @@
1
- import { DEG2RAD, HALF_PI, INV_HALF_PI, PI, RAD2DEG, TAU } from "./api";
1
+ import { DEG2RAD, HALF_PI, INV_HALF_PI, PI, RAD2DEG, TAU } from "./api.js";
2
2
  /**
3
3
  * Returns vector of `[sin(theta)*n, cos(theta)*n]`.
4
4
  *
package/crossing.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { FnU4 } from "@thi.ng/api";
2
- import { Crossing } from "./api";
2
+ import { Crossing } from "./api.js";
3
3
  /**
4
4
  * Returns true if line A rises up over B.
5
5
  *
package/crossing.js CHANGED
@@ -1,5 +1,5 @@
1
- import { EPS } from "./api";
2
- import { eqDelta } from "./eqdelta";
1
+ import { EPS } from "./api.js";
2
+ import { eqDelta } from "./eqdelta.js";
3
3
  /**
4
4
  * Returns true if line A rises up over B.
5
5
  *
package/eqdelta.js CHANGED
@@ -1,4 +1,4 @@
1
- import { EPS } from "./api";
1
+ import { EPS } from "./api.js";
2
2
  const abs = Math.abs;
3
3
  const max = Math.max;
4
4
  /**
package/fit.js CHANGED
@@ -1,4 +1,4 @@
1
- import { clamp01, clamp11 } from "./interval";
1
+ import { clamp01, clamp11 } from "./interval.js";
2
2
  /**
3
3
  * Returns normalized value of `x` WRT to interval `a .. b`. If `a`
4
4
  * equals `b`, returns 0.
package/index.d.ts CHANGED
@@ -1,18 +1,18 @@
1
- export * from "./api";
2
- export * from "./abs";
3
- export * from "./angle";
4
- export * from "./crossing";
5
- export * from "./eqdelta";
6
- export * from "./extrema";
7
- export * from "./fit";
8
- export * from "./int";
9
- export * from "./interval";
10
- export * from "./libc";
11
- export * from "./min-error";
12
- export * from "./mix";
13
- export * from "./prec";
14
- export * from "./ratio";
15
- export * from "./safe-div";
16
- export * from "./solve";
17
- export * from "./step";
1
+ export * from "./api.js";
2
+ export * from "./abs.js";
3
+ export * from "./angle.js";
4
+ export * from "./crossing.js";
5
+ export * from "./eqdelta.js";
6
+ export * from "./extrema.js";
7
+ export * from "./fit.js";
8
+ export * from "./int.js";
9
+ export * from "./interval.js";
10
+ export * from "./libc.js";
11
+ export * from "./min-error.js";
12
+ export * from "./mix.js";
13
+ export * from "./prec.js";
14
+ export * from "./ratio.js";
15
+ export * from "./safe-div.js";
16
+ export * from "./solve.js";
17
+ export * from "./step.js";
18
18
  //# sourceMappingURL=index.d.ts.map
package/index.js CHANGED
@@ -1,17 +1,17 @@
1
- export * from "./api";
2
- export * from "./abs";
3
- export * from "./angle";
4
- export * from "./crossing";
5
- export * from "./eqdelta";
6
- export * from "./extrema";
7
- export * from "./fit";
8
- export * from "./int";
9
- export * from "./interval";
10
- export * from "./libc";
11
- export * from "./min-error";
12
- export * from "./mix";
13
- export * from "./prec";
14
- export * from "./ratio";
15
- export * from "./safe-div";
16
- export * from "./solve";
17
- export * from "./step";
1
+ export * from "./api.js";
2
+ export * from "./abs.js";
3
+ export * from "./angle.js";
4
+ export * from "./crossing.js";
5
+ export * from "./eqdelta.js";
6
+ export * from "./extrema.js";
7
+ export * from "./fit.js";
8
+ export * from "./int.js";
9
+ export * from "./interval.js";
10
+ export * from "./libc.js";
11
+ export * from "./min-error.js";
12
+ export * from "./mix.js";
13
+ export * from "./prec.js";
14
+ export * from "./ratio.js";
15
+ export * from "./safe-div.js";
16
+ export * from "./solve.js";
17
+ export * from "./step.js";
package/min-error.js CHANGED
@@ -1,4 +1,4 @@
1
- import { EPS } from "./api";
1
+ import { EPS } from "./api.js";
2
2
  /**
3
3
  * Recursively evaluates function `fn` for `res` uniformly spaced values
4
4
  * `t` in the closed parametric interval `[start,end]` and computes
package/mix.js CHANGED
@@ -1,4 +1,4 @@
1
- import { EPS, HALF_PI, PI } from "./api";
1
+ import { EPS, HALF_PI, PI } from "./api.js";
2
2
  /**
3
3
  * Linear interpolation without clamping. Computes `a + (b - a) * t`
4
4
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/math",
3
- "version": "5.0.0",
3
+ "version": "5.0.4",
4
4
  "description": "Assorted common math functions & utilities",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -34,10 +34,10 @@
34
34
  "test": "testament test"
35
35
  },
36
36
  "dependencies": {
37
- "@thi.ng/api": "^8.0.0"
37
+ "@thi.ng/api": "^8.0.4"
38
38
  },
39
39
  "devDependencies": {
40
- "@thi.ng/testament": "^0.1.0"
40
+ "@thi.ng/testament": "^0.1.4"
41
41
  },
42
42
  "keywords": [
43
43
  "animation",
@@ -57,6 +57,9 @@
57
57
  "publishConfig": {
58
58
  "access": "public"
59
59
  },
60
+ "engines": {
61
+ "node": ">=12.7"
62
+ },
60
63
  "files": [
61
64
  "*.js",
62
65
  "*.d.ts"
@@ -120,5 +123,5 @@
120
123
  "thi.ng": {
121
124
  "year": 2013
122
125
  },
123
- "gitHead": "9ac1344b38b565eb894306fbf72233b6c0b2d115"
126
+ "gitHead": "9ff00a103f76cc4917ef3f244132e218f2300a05"
124
127
  }
package/prec.js CHANGED
@@ -1,4 +1,4 @@
1
- import { EPS } from "./api";
1
+ import { EPS } from "./api.js";
2
2
  /**
3
3
  * Similar to {@link fmod}, {@link remainder}. Returns `a - b * floor(a / b)`
4
4
  * (same as GLSL `mod(a, b)`)
package/solve.js CHANGED
@@ -1,5 +1,5 @@
1
- import { EPS } from "./api";
2
- import { safeDiv } from "./safe-div";
1
+ import { EPS } from "./api.js";
2
+ import { safeDiv } from "./safe-div.js";
3
3
  /**
4
4
  * Produces a new function which computes derivative of the given
5
5
  * single-arg function. The extra optional arg `eps` is used to
package/step.js CHANGED
@@ -1,4 +1,4 @@
1
- import { clamp01 } from "./interval";
1
+ import { clamp01 } from "./interval.js";
2
2
  /**
3
3
  * Step/threshold function.
4
4
  *