File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -196,9 +196,11 @@ export type NgtNodeElement<TOriginal, TConstructor> = {
196196 __ngt_args__ : NgtArguments < TConstructor > ;
197197} ;
198198
199- export type NgtNode < TOriginal , TConstructor , TNoEvent = NoEvent < TOriginal > > = Expand <
200- NgtExtendedColors < NgtOverwrite < Partial < TNoEvent > , NgtNodeElement < TOriginal , TConstructor > > >
201- > ;
199+ export type NgtNode < TOriginal , TConstructor , TNoEvent = NoEvent < TOriginal > > = [ TNoEvent ] extends [
200+ { thisShouldNeverHappen : 'unless the object is of type any' } ,
201+ ]
202+ ? NgtExtendedColors < NgtOverwrite < Partial < { } > , NgtNodeElement < { } , { } > > >
203+ : NgtExtendedColors < NgtOverwrite < Partial < TNoEvent > , NgtNodeElement < TOriginal , TConstructor > > > ;
202204
203205export type NgtObject3DEventsMap = {
204206 [ TEvent in keyof NgtEventHandlers ] -?: Parameters < NonNullable < NgtEventHandlers [ TEvent ] > > [ 0 ] ;
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ import {
2020import { NgtObject3DNode } from './three-types' ;
2121import { NgtSignalStore } from './utils/signal-store' ;
2222
23- export type NgtProperties < T > = Pick < T , { [ K in keyof T ] : T [ K ] extends ( _ : any ) => any ? never : K } [ keyof T ] > ;
23+ export type NgtProperties < T > = { [ K in keyof T as T [ K ] extends ( ... args : Array < any > ) => any ? never : K ] : T [ K ] } ;
2424export type NgtAnyRecord = Record < string , any > ;
2525
2626export type NgtEquConfig = {
You can’t perform that action at this time.
0 commit comments