@tresjs/core 5.9.0 → 5.9.1
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/dist/tres.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @tresjs/core
|
|
3
|
-
* version: v5.9.
|
|
3
|
+
* version: v5.9.1
|
|
4
4
|
* (c) 2026
|
|
5
5
|
* description: Declarative ThreeJS using Vue Components
|
|
6
6
|
* author: Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)
|
|
@@ -455,17 +455,18 @@ interface TresScene extends THREE.Scene {
|
|
|
455
455
|
};
|
|
456
456
|
}
|
|
457
457
|
interface MathRepresentation {
|
|
458
|
-
set(...args: number[]
|
|
458
|
+
set(...args: number[]): any;
|
|
459
459
|
}
|
|
460
460
|
interface VectorRepresentation extends MathRepresentation {
|
|
461
461
|
setScalar(s: number): any;
|
|
462
462
|
}
|
|
463
|
+
type MathTypes = MathRepresentation | THREE.Euler | THREE.Color;
|
|
463
464
|
interface VectorCoordinates {
|
|
464
465
|
x: number;
|
|
465
466
|
y: number;
|
|
466
467
|
z: number;
|
|
467
468
|
}
|
|
468
|
-
type MathType<T extends
|
|
469
|
+
type MathType<T extends MathTypes> = T extends THREE.Color ? ConstructorParameters<typeof THREE.Color> | THREE.ColorRepresentation : T extends VectorRepresentation | THREE.Layers | THREE.Euler ? T | Parameters<T['set']> | number | VectorCoordinates : T | Parameters<T['set']>;
|
|
469
470
|
type VectorLike$1<VectorClass extends THREE.Vector2 | THREE.Vector3 | THREE.Vector4> = VectorClass | Parameters<VectorClass['set']> | Readonly<Parameters<VectorClass['set']>> | Parameters<VectorClass['setScalar']>[0];
|
|
470
471
|
type TresVector2 = VectorLike$1<THREE.Vector2>;
|
|
471
472
|
type TresVector3 = VectorLike$1<THREE.Vector3>;
|
|
@@ -482,7 +483,7 @@ type TresContextWithClock = TresContext & {
|
|
|
482
483
|
delta: number;
|
|
483
484
|
elapsed: number;
|
|
484
485
|
};
|
|
485
|
-
type WithMathProps<P> = { [K in keyof P]: P[K] extends
|
|
486
|
+
type WithMathProps<P> = { [K in keyof P]: P[K] extends MathTypes ? MathType<P[K]> : P[K] };
|
|
486
487
|
interface RaycastableRepresentation {
|
|
487
488
|
raycast: (raycaster: THREE.Raycaster, intersects: THREE.Intersection[]) => void;
|
|
488
489
|
}
|
package/dist/tres.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @tresjs/core
|
|
3
|
-
* version: v5.9.
|
|
3
|
+
* version: v5.9.1
|
|
4
4
|
* (c) 2026
|
|
5
5
|
* description: Declarative ThreeJS using Vue Components
|
|
6
6
|
* author: Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)
|
|
@@ -15,7 +15,7 @@ import { setupDevtoolsPlugin } from "@vue/devtools-api";
|
|
|
15
15
|
import { RectAreaLightHelper } from "three/examples/jsm/helpers/RectAreaLightHelper.js";
|
|
16
16
|
|
|
17
17
|
//#region package.json
|
|
18
|
-
var version = "5.9.
|
|
18
|
+
var version = "5.9.1";
|
|
19
19
|
|
|
20
20
|
//#endregion
|
|
21
21
|
//#region src/utils/makeMap.ts
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tresjs/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "5.9.
|
|
4
|
+
"version": "5.9.1",
|
|
5
5
|
"description": "Declarative ThreeJS using Vue Components",
|
|
6
6
|
"author": "Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)",
|
|
7
7
|
"license": "MIT",
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
"build": "tsdown",
|
|
90
90
|
"build:analyze": "ANALYZE=true tsdown",
|
|
91
91
|
"test": "vitest",
|
|
92
|
-
"test:ci": "vitest run",
|
|
92
|
+
"test:ci": "vitest run --typecheck",
|
|
93
93
|
"test:ui": "vitest --ui --coverage.enabled=true",
|
|
94
94
|
"coverage": "vitest run --coverage",
|
|
95
95
|
"lint": "eslint .",
|