File tree Expand file tree Collapse file tree 2 files changed +9
-12
lines changed Expand file tree Collapse file tree 2 files changed +9
-12
lines changed Original file line number Diff line number Diff line change @@ -26,14 +26,13 @@ export class NgtsStats {
26
26
27
27
const document = inject ( DOCUMENT ) ;
28
28
const store = injectStore ( ) ;
29
- const gl = store . select ( 'gl' ) ;
30
29
31
30
const stats = computed ( ( ) => {
32
- const _gl = gl ( ) ;
33
- if ( ! _gl ) return null ;
31
+ const gl = store . gl ( ) ;
32
+ if ( ! gl ) return null ;
34
33
35
34
const stats = new Stats ( { ...untracked ( statsOptions ) } ) ;
36
- void stats . init ( _gl ) ;
35
+ void stats . init ( gl ) ;
37
36
return stats ;
38
37
} ) ;
39
38
Original file line number Diff line number Diff line change
1
+ import { Type } from '@angular/core' ;
1
2
import {
2
3
BlurPass ,
3
4
CausticsMaterial ,
@@ -18,15 +19,12 @@ import {
18
19
SoftShadowMaterial ,
19
20
SpotLightMaterial ,
20
21
} from '@pmndrs/vanilla' ;
21
- import { NgtMaterial } from 'angular-three' ;
22
+ import { NgtThreeElement } from 'angular-three' ;
22
23
23
- export type NgtSpotLightMaterial = NgtMaterial < InstanceType < typeof SpotLightMaterial > , typeof SpotLightMaterial > ;
24
- export type NgtSoftShadowMaterial = NgtMaterial < InstanceType < typeof SoftShadowMaterial > , typeof SoftShadowMaterial > ;
25
- export type NgtCausticsProjectionMaterial = NgtMaterial <
26
- CausticsProjectionMaterialType ,
27
- [ CausticsProjectionMaterialType ]
28
- > ;
29
- export type NgtMeshPortalMaterial = NgtMaterial < InstanceType < typeof MeshPortalMaterial > , typeof MeshPortalMaterial > ;
24
+ export type NgtSpotLightMaterial = NgtThreeElement < typeof SpotLightMaterial > ;
25
+ export type NgtSoftShadowMaterial = NgtThreeElement < typeof SoftShadowMaterial > ;
26
+ export type NgtCausticsProjectionMaterial = NgtThreeElement < Type < CausticsProjectionMaterialType > > ;
27
+ export type NgtMeshPortalMaterial = NgtThreeElement < typeof MeshPortalMaterial > ;
30
28
31
29
declare global {
32
30
interface HTMLElementTagNameMap {
You can’t perform that action at this time.
0 commit comments