@thi.ng/scenegraph 0.4.8 → 0.5.2

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
@@ -1,68 +1,110 @@
1
1
  # Change Log
2
2
 
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [0.4.8](https://github.com/thi-ng/umbrella/compare/@thi.ng/scenegraph@0.4.7...@thi.ng/scenegraph@0.4.8) (2021-11-04)
7
-
8
- **Note:** Version bump only for package @thi.ng/scenegraph
3
+ - **Last updated**: 2021-11-21T17:09:28Z
4
+ - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
9
5
 
6
+ All notable changes to this project will be documented in this file.
7
+ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelines.
10
8
 
9
+ **Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
10
+ and/or version bumps of transitive dependencies.
11
11
 
12
+ ## [0.5.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.5.0) (2021-11-17)
12
13
 
14
+ #### 🚀 Features
13
15
 
14
- ## [0.4.7](https://github.com/thi-ng/umbrella/compare/@thi.ng/scenegraph@0.4.6...@thi.ng/scenegraph@0.4.7) (2021-11-03)
16
+ - Using workspaces for local tools ([bf7a404](https://github.com/thi-ng/umbrella/commit/bf7a404))
17
+ Improving the overall build ergonomics
18
+ - introduced a tools workspaces
19
+ - imported it in all needed packages/examples
20
+ - inclusive project root
15
21
 
16
- **Note:** Version bump only for package @thi.ng/scenegraph
22
+ #### ♻️ Refactoring
17
23
 
24
+ - testrunner to binary ([4ebbbb2](https://github.com/thi-ng/umbrella/commit/4ebbbb2))
25
+ this commit reverts (partly) changes made in:
26
+ ef346d7a8753590dc9094108a3d861a8dbd5dd2c
27
+ overall purpose is better testament ergonomics:
28
+ instead of having to pass NODE_OPTIONS with every invocation
29
+ having a binary to handle this for us.
18
30
 
31
+ ### [0.4.9](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.4.9) (2021-11-10)
19
32
 
33
+ #### ♻️ Refactoring
20
34
 
35
+ - update all countdown loops ([a5f374b](https://github.com/thi-ng/umbrella/commit/a5f374b))
21
36
 
22
- # [0.4.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/scenegraph@0.3.43...@thi.ng/scenegraph@0.4.0) (2021-10-12)
37
+ ### [0.4.1](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.4.1) (2021-10-13)
23
38
 
39
+ #### ♻️ Refactoring
24
40
 
25
- ### Build System
41
+ - update imports in all tests/pkgs ([effd591](https://github.com/thi-ng/umbrella/commit/effd591))
42
+ - update imports in all pkgs ([5fa2b6f](https://github.com/thi-ng/umbrella/commit/5fa2b6f))
43
+ - add .js suffix for all relative imports
26
44
 
27
- * major update of ALL pkgs (export maps, ESM only) ([0d1d6ea](https://github.com/thi-ng/umbrella/commit/0d1d6ea9fab2a645d6c5f2bf2591459b939c09b6))
45
+ ## [0.4.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.4.0) (2021-10-12)
28
46
 
47
+ #### 🛑 Breaking changes
29
48
 
30
- ### BREAKING CHANGES
49
+ - major update of ALL pkgs (export maps, ESM only) ([0d1d6ea](https://github.com/thi-ng/umbrella/commit/0d1d6ea))
50
+ - BREAKING CHANGE: discontinue CommonJS & UMD versions
51
+ - only ESM modules will be published from now on
52
+ - CJS obsolete due to ESM support in recent versions of node:
53
+ - i.e. launch NodeJS via:
54
+ - `node --experimental-specifier-resolution=node --experimental-repl-await`
55
+ - in the node REPL use `await import(...)` instead of `require()`
56
+ - UMD obsolete due to widespread browser support for ESM
57
+ Also:
58
+ - normalize/restructure/reorg all package.json files
59
+ - cleanup all build scripts, remove obsolete
60
+ - switch from mocha to [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament) for all tests
31
61
 
32
- * discontinue CommonJS & UMD versions
62
+ #### ♻️ Refactoring
33
63
 
34
- - only ESM modules will be published from now on
35
- - CJS obsolete due to ESM support in recent versions of node:
36
- - i.e. launch NodeJS via:
37
- - `node --experimental-specifier-resolution=node --experimental-repl-await`
38
- - in the node REPL use `await import(...)` instead of `require()`
39
- - UMD obsolete due to widespread browser support for ESM
64
+ - update deps & imports in various pkgs ([e1cf29e](https://github.com/thi-ng/umbrella/commit/e1cf29e))
65
+ - largely related to recent updates/restructuring of these packages:
66
+ - api
67
+ - defmulti
68
+ - errors
69
+ - logger
70
+ - update imports ([138571a](https://github.com/thi-ng/umbrella/commit/138571a))
71
+ - update all test stubs ([f2d6d53](https://github.com/thi-ng/umbrella/commit/f2d6d53))
72
+ - update all tests in _all_ pkgs ([8b582bc](https://github.com/thi-ng/umbrella/commit/8b582bc))
73
+ - update all to use [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament)
40
74
 
41
- Also:
42
- - normalize/restructure/reorg all package.json files
43
- - cleanup all build scripts, remove obsolete
44
- - switch from mocha to @thi.ng/testament for all tests
75
+ ### [0.3.11](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.3.11) (2020-12-07)
45
76
 
77
+ #### ♻️ Refactoring
46
78
 
79
+ - update type-only imports ([3b2eb85](https://github.com/thi-ng/umbrella/commit/3b2eb85))
80
+ - update type-only imports in various tests/pkgs ([3fd9c24](https://github.com/thi-ng/umbrella/commit/3fd9c24))
47
81
 
82
+ ### [0.3.7](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.3.7) (2020-09-22)
48
83
 
84
+ #### ♻️ Refactoring
49
85
 
86
+ - update toHiccup() impls ([1bdc0f1](https://github.com/thi-ng/umbrella/commit/1bdc0f1))
50
87
 
51
- # [0.3.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/scenegraph@0.2.1...@thi.ng/scenegraph@0.3.0) (2020-07-28)
88
+ ## [0.3.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.3.0) (2020-07-28)
52
89
 
53
- ### Features
90
+ #### 🚀 Features
54
91
 
55
- - **scenegraph:** add ICopy impls for Node2/3 ([fd6ffdb](https://github.com/thi-ng/umbrella/commit/fd6ffdb531886e53711de77c2df00c447ea65448))
92
+ - add ICopy impls for Node2/3 ([fd6ffdb](https://github.com/thi-ng/umbrella/commit/fd6ffdb))
56
93
 
57
- # [0.2.0](https://github.com/thi-ng/umbrella/compare/@thi.ng/scenegraph@0.1.27...@thi.ng/scenegraph@0.2.0) (2020-07-17)
94
+ ## [0.2.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.2.0) (2020-07-17)
58
95
 
59
- ### Features
96
+ #### 🚀 Features
60
97
 
61
- - **scenegraph:** update `.toHiccuo()` impls, update .scale type ([2f0a3cc](https://github.com/thi-ng/umbrella/commit/2f0a3cc6286bf8492c74c4497f13fe300980c353))
98
+ - update `.toHiccuo()` impls, update .scale type ([2f0a3cc](https://github.com/thi-ng/umbrella/commit/2f0a3cc))
99
+ - add support for opt ctx arg
100
+ - if body is fn, call fn w/ ctx
101
+ - update `scale` type to `Vec | number` (to simplify uniform scaling)
102
+ - add/update doc strings
62
103
 
63
- # 0.1.0 (2019-11-30)
104
+ ### [0.1.3](https://github.com/thi-ng/umbrella/tree/@thi.ng/scenegraph@0.1.3) (2020-02-25)
64
105
 
65
- ### Features
106
+ #### ♻️ Refactoring
66
107
 
67
- - **scenegraph:** add global/local point mapping methods ([3906c4c](https://github.com/thi-ng/umbrella/commit/3906c4c68c541aa84bc407235c3fe3fdf3e2debe))
68
- - **scenegraph:** add new package ([84d2a8b](https://github.com/thi-ng/umbrella/commit/84d2a8b96aeb7e8dd119be4fbc0c8c8277dc1990))
108
+ - update imports ([0acdfc3](https://github.com/thi-ng/umbrella/commit/0acdfc3))
109
+ - update mapGlobal/LocalPoint return types ([0275af0](https://github.com/thi-ng/umbrella/commit/0275af0))
110
+ - allow potentially `undefined` results (e.g. if uninvertible matrix)
package/README.md CHANGED
@@ -60,7 +60,7 @@ node --experimental-repl-await
60
60
  > const scenegraph = await import("@thi.ng/scenegraph");
61
61
  ```
62
62
 
63
- Package sizes (gzipped, pre-treeshake): ESM: 941 bytes
63
+ Package sizes (gzipped, pre-treeshake): ESM: 980 bytes
64
64
 
65
65
  ## Dependencies
66
66
 
package/anode.js CHANGED
@@ -46,7 +46,7 @@ export class ANode {
46
46
  childForPoint(p) {
47
47
  if (this.enabled) {
48
48
  const children = this.children;
49
- for (let i = children.length; --i >= 0;) {
49
+ for (let i = children.length; i-- > 0;) {
50
50
  const n = children[i].childForPoint(p);
51
51
  if (n) {
52
52
  return n;
package/package.json CHANGED
@@ -1,97 +1,102 @@
1
1
  {
2
- "name": "@thi.ng/scenegraph",
3
- "version": "0.4.8",
4
- "description": "Extensible 2D/3D scene graph with @thi.ng/hiccup-canvas support",
5
- "type": "module",
6
- "module": "./index.js",
7
- "typings": "./index.d.ts",
8
- "sideEffects": false,
9
- "repository": {
10
- "type": "git",
11
- "url": "https://github.com/thi-ng/umbrella.git"
2
+ "name": "@thi.ng/scenegraph",
3
+ "version": "0.5.2",
4
+ "description": "Extensible 2D/3D scene graph with @thi.ng/hiccup-canvas support",
5
+ "type": "module",
6
+ "module": "./index.js",
7
+ "typings": "./index.d.ts",
8
+ "sideEffects": false,
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/thi-ng/umbrella.git"
12
+ },
13
+ "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/scenegraph#readme",
14
+ "funding": [
15
+ {
16
+ "type": "github",
17
+ "url": "https://github.com/sponsors/postspectacular"
12
18
  },
13
- "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/scenegraph#readme",
14
- "funding": [
15
- {
16
- "type": "github",
17
- "url": "https://github.com/sponsors/postspectacular"
18
- },
19
- {
20
- "type": "patreon",
21
- "url": "https://patreon.com/thing_umbrella"
22
- }
23
- ],
24
- "author": "Karsten Schmidt <k+npm@thi.ng>",
25
- "license": "Apache-2.0",
26
- "scripts": {
27
- "build": "yarn clean && tsc --declaration",
28
- "clean": "rimraf *.js *.d.ts *.map doc",
29
- "doc": "typedoc --excludePrivate --excludeInternal --out doc src/index.ts",
30
- "doc:ae": "mkdir -p .ae/doc .ae/temp && node_modules/.bin/api-extractor run --local --verbose",
31
- "doc:readme": "yarn doc:stats && ../../scripts/node-esm ../../tools/src/readme.ts",
32
- "doc:stats": "../../scripts/node-esm ../../tools/src/module-stats.ts",
33
- "pub": "yarn build && yarn publish --access public",
34
- "test": "testament test"
19
+ {
20
+ "type": "patreon",
21
+ "url": "https://patreon.com/thing_umbrella"
22
+ }
23
+ ],
24
+ "author": "Karsten Schmidt <k+npm@thi.ng>",
25
+ "license": "Apache-2.0",
26
+ "scripts": {
27
+ "build": "yarn clean && tsc --declaration",
28
+ "clean": "rimraf '*.js' '*.d.ts' '*.map' doc",
29
+ "doc": "typedoc --excludePrivate --excludeInternal --out doc src/index.ts",
30
+ "doc:ae": "mkdir -p .ae/doc .ae/temp && api-extractor run --local --verbose",
31
+ "doc:readme": "yarn doc:stats && tools:readme",
32
+ "doc:stats": "tools:module-stats",
33
+ "pub": "yarn npm publish --access public",
34
+ "test": "testament test"
35
+ },
36
+ "dependencies": {
37
+ "@thi.ng/api": "^8.3.2",
38
+ "@thi.ng/checks": "^3.1.2",
39
+ "@thi.ng/errors": "^2.1.2",
40
+ "@thi.ng/matrices": "^2.1.2",
41
+ "@thi.ng/vectors": "^7.2.2"
42
+ },
43
+ "devDependencies": {
44
+ "@microsoft/api-extractor": "^7.18.19",
45
+ "@thi.ng/testament": "^0.2.2",
46
+ "rimraf": "^3.0.2",
47
+ "tools": "^0.0.1",
48
+ "typedoc": "^0.22.9",
49
+ "typescript": "^4.5.2"
50
+ },
51
+ "keywords": [
52
+ "2d",
53
+ "3d",
54
+ "animation",
55
+ "canvas",
56
+ "datastructure",
57
+ "scenegraph",
58
+ "tree",
59
+ "typescript"
60
+ ],
61
+ "publishConfig": {
62
+ "access": "public"
63
+ },
64
+ "engines": {
65
+ "node": ">=12.7"
66
+ },
67
+ "files": [
68
+ "*.js",
69
+ "*.d.ts"
70
+ ],
71
+ "exports": {
72
+ ".": {
73
+ "import": "./index.js"
35
74
  },
36
- "dependencies": {
37
- "@thi.ng/api": "^8.1.0",
38
- "@thi.ng/checks": "^3.0.6",
39
- "@thi.ng/errors": "^2.0.6",
40
- "@thi.ng/matrices": "^2.0.8",
41
- "@thi.ng/vectors": "^7.1.0"
75
+ "./anode": {
76
+ "import": "./anode.js"
42
77
  },
43
- "devDependencies": {
44
- "@thi.ng/testament": "^0.1.6"
78
+ "./api": {
79
+ "import": "./api.js"
45
80
  },
46
- "keywords": [
47
- "2d",
48
- "3d",
49
- "animation",
50
- "canvas",
51
- "datastructure",
52
- "scenegraph",
53
- "tree",
54
- "typescript"
55
- ],
56
- "publishConfig": {
57
- "access": "public"
81
+ "./hiccup": {
82
+ "import": "./hiccup.js"
58
83
  },
59
- "engines": {
60
- "node": ">=12.7"
84
+ "./node2": {
85
+ "import": "./node2.js"
61
86
  },
62
- "files": [
63
- "*.js",
64
- "*.d.ts"
87
+ "./node3": {
88
+ "import": "./node3.js"
89
+ }
90
+ },
91
+ "thi.ng": {
92
+ "related": [
93
+ "hdom-canvas",
94
+ "hiccup",
95
+ "hiccup-canvas",
96
+ "hiccup-svg",
97
+ "rdom-canvas"
65
98
  ],
66
- "exports": {
67
- ".": {
68
- "import": "./index.js"
69
- },
70
- "./anode": {
71
- "import": "./anode.js"
72
- },
73
- "./api": {
74
- "import": "./api.js"
75
- },
76
- "./hiccup": {
77
- "import": "./hiccup.js"
78
- },
79
- "./node2": {
80
- "import": "./node2.js"
81
- },
82
- "./node3": {
83
- "import": "./node3.js"
84
- }
85
- },
86
- "thi.ng": {
87
- "related": [
88
- "hdom-canvas",
89
- "hiccup",
90
- "hiccup-canvas",
91
- "hiccup-svg",
92
- "rdom-canvas"
93
- ],
94
- "status": "alpha"
95
- },
96
- "gitHead": "d6aca4b4edb697613ed6635b1c0b12f0bf27b1f0"
97
- }
99
+ "status": "alpha"
100
+ },
101
+ "gitHead": "e8a7c2a40191b391cef182c2978e5a6c85987a87\n"
102
+ }