@lukekaalim/act-three 5.12.5 → 5.13.0
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/components.d.ts +8 -1
- package/package.json +3 -3
- package/renderer.js +1 -1
package/components.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Component, Ref } from "@lukekaalim/act";
|
|
2
|
-
import { AmbientLight, Color, CubeTexture, DirectionalLight, Euler, HemisphereLight, Light, Mesh, PerspectiveCamera, PointLight, Quaternion, Scene, Sprite, Texture, Vector3 } from "three";
|
|
2
|
+
import { AmbientLight, Color, CubeTexture, DirectionalLight, Euler, HemisphereLight, Light, Line, LineLoop, LineSegments, Mesh, PerspectiveCamera, PointLight, Quaternion, Scene, Sprite, Texture, Vector3 } from "three";
|
|
3
3
|
|
|
4
4
|
export type ReferenceProps<T> = {
|
|
5
5
|
ref?: ((reference: T) => unknown) | Ref<null | T>
|
|
@@ -42,6 +42,13 @@ export type SpriteProps =
|
|
|
42
42
|
& Object3DProps<Sprite>
|
|
43
43
|
& PropsFromList<Sprite, ["geometry", "material", "center"]>
|
|
44
44
|
|
|
45
|
+
export const line: Component<LineProps>;
|
|
46
|
+
export const lineLoop: Component<LineProps>;
|
|
47
|
+
export const lineSegments: Component<LineProps>;
|
|
48
|
+
export type LineProps =
|
|
49
|
+
& Object3DProps<Line>
|
|
50
|
+
& PropsFromList<Line, ["geometry", "material"]>
|
|
51
|
+
|
|
45
52
|
|
|
46
53
|
export type LightProps = PropsFromList<Light, [
|
|
47
54
|
"color", "intensity", "shadow"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lukekaalim/act-three",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.13.0",
|
|
4
4
|
"description": "Render threejs content using act",
|
|
5
5
|
"main": "entry.js",
|
|
6
6
|
"types": "entry.d.ts",
|
|
@@ -18,8 +18,8 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@lukekaalim/act": "^2.5.0",
|
|
20
20
|
"@lukekaalim/act-reconciler": "^3.7.5",
|
|
21
|
-
"@lukekaalim/act-renderer-core": "^3.5.
|
|
22
|
-
"@lukekaalim/act-web": "^2.5.
|
|
21
|
+
"@lukekaalim/act-renderer-core": "^3.5.5",
|
|
22
|
+
"@lukekaalim/act-web": "^2.5.5"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@types/three": "^0.155.0"
|
package/renderer.js
CHANGED
|
@@ -15,7 +15,7 @@ export const createObjectRenderer = (
|
|
|
15
15
|
)/*: Renderer2<Object3D>*/ => {
|
|
16
16
|
|
|
17
17
|
const getRenderer = (set, commitId) => {
|
|
18
|
-
const commit = set.nexts.get(commitId);
|
|
18
|
+
const commit = set.nexts.map.get(commitId) || set.prevs.get(commitId);
|
|
19
19
|
return getNextRenderer && getNextRenderer(commit.element.type) || objectRenderer;
|
|
20
20
|
}
|
|
21
21
|
|