@@ -397,15 +397,15 @@ export interface Commands {
397
397
getParticipantNode (
398
398
id : string ,
399
399
/** @default `'camera'` */
400
- type ?: ParticipantType ,
400
+ type ?: ParticipantType | ExternalSourceType ,
401
401
) : Compositor . SceneNode
402
402
/**
403
403
* Get {@link ParticipantProps} associated with a participant/type.
404
404
*/
405
405
getParticipantState (
406
406
participantId : string ,
407
407
/** @default `'camera'` */
408
- type ?: ParticipantType ,
408
+ type ?: ParticipantType | ExternalSourceType ,
409
409
) : ParticipantProps
410
410
/**
411
411
* @hook
@@ -416,7 +416,7 @@ export interface Commands {
416
416
participantId : string ,
417
417
cb : ( state : ParticipantProps ) => void ,
418
418
/** @default `'camera'` */
419
- type ?: ParticipantType ,
419
+ type ?: ParticipantType | ExternalSourceType ,
420
420
) : Disposable
421
421
/**
422
422
* Change a participant's volume.
@@ -428,7 +428,7 @@ export interface Commands {
428
428
* Accepted values from [0 - 1]
429
429
*/
430
430
volume : number ,
431
- type ?: ParticipantType ,
431
+ type ?: ParticipantType | ExternalSourceType ,
432
432
) : void
433
433
/**
434
434
* Mute a participant without changing their volume.
@@ -444,7 +444,7 @@ export interface Commands {
444
444
participantId : string ,
445
445
isMuted : boolean ,
446
446
/** @default `camera` */
447
- type ?: ParticipantType ,
447
+ type ?: ParticipantType | ExternalSourceType ,
448
448
) : void
449
449
/**
450
450
* Hide a participant video feed from the stream.
@@ -460,13 +460,13 @@ export interface Commands {
460
460
participantId : string ,
461
461
isHidden : boolean ,
462
462
/** @default `camera` */
463
- type ?: ParticipantType ,
463
+ type ?: ParticipantType | ExternalSourceType ,
464
464
) : void
465
465
setParticipantAudioOnly (
466
466
participantId : string ,
467
467
isAudioOnly : boolean ,
468
468
/** @default `camera` */
469
- type ?: ParticipantType ,
469
+ type ?: ParticipantType | ExternalSourceType ,
470
470
) : void
471
471
/**
472
472
* Remove all participants from the stream canvas who are not actively
@@ -1981,7 +1981,7 @@ export const commands = (_project: ScenelessProject) => {
1981
1981
} )
1982
1982
} )
1983
1983
} ,
1984
- getParticipantNode ( id : string , type : ParticipantType = 'camera' ) {
1984
+ getParticipantNode ( id : string , type : ParticipantType | ExternalSourceType = 'camera' ) {
1985
1985
return content . children
1986
1986
. concat ( audioContainer . children )
1987
1987
. find (
@@ -1992,7 +1992,7 @@ export const commands = (_project: ScenelessProject) => {
1992
1992
} ,
1993
1993
getParticipantState (
1994
1994
participantId : string ,
1995
- type : ParticipantType = 'camera' ,
1995
+ type : ParticipantType | ExternalSourceType = 'camera' ,
1996
1996
) {
1997
1997
return commands . getParticipantNode ( participantId , type )
1998
1998
?. props as ParticipantProps
@@ -2001,7 +2001,7 @@ export const commands = (_project: ScenelessProject) => {
2001
2001
useParticipantState (
2002
2002
participantId : string ,
2003
2003
cb : ( state : ParticipantProps ) => void ,
2004
- type = 'camera' as ParticipantType ,
2004
+ type = 'camera' as ParticipantType | ExternalSourceType ,
2005
2005
) {
2006
2006
let participantNode = commands . getParticipantNode ( participantId , type )
2007
2007
@@ -2040,7 +2040,7 @@ export const commands = (_project: ScenelessProject) => {
2040
2040
setParticipantVolume (
2041
2041
participantId : string ,
2042
2042
volume : number ,
2043
- type : ParticipantType = 'camera' ,
2043
+ type : ParticipantType | ExternalSourceType = 'camera' ,
2044
2044
) {
2045
2045
const node = commands . getParticipantNode ( participantId , type )
2046
2046
if ( ! node ) return
@@ -2054,7 +2054,7 @@ export const commands = (_project: ScenelessProject) => {
2054
2054
setParticipantMuted (
2055
2055
participantId : string ,
2056
2056
isMuted : boolean ,
2057
- type : ParticipantType = 'camera' ,
2057
+ type : ParticipantType | ExternalSourceType = 'camera' ,
2058
2058
) {
2059
2059
const node = commands . getParticipantNode ( participantId , type )
2060
2060
if ( ! node ) return
@@ -2068,7 +2068,7 @@ export const commands = (_project: ScenelessProject) => {
2068
2068
setParticipantHidden (
2069
2069
participantId : string ,
2070
2070
isHidden : boolean ,
2071
- type : ParticipantType = 'camera' ,
2071
+ type : ParticipantType | ExternalSourceType = 'camera' ,
2072
2072
) {
2073
2073
const node = commands . getParticipantNode ( participantId , type )
2074
2074
if ( ! node ) return
@@ -2082,7 +2082,7 @@ export const commands = (_project: ScenelessProject) => {
2082
2082
setParticipantAudioOnly (
2083
2083
participantId : string ,
2084
2084
isAudioOnly : boolean ,
2085
- type : ParticipantType = 'camera' ,
2085
+ type : ParticipantType | ExternalSourceType = 'camera' ,
2086
2086
) {
2087
2087
const node = commands . getParticipantNode ( participantId , type )
2088
2088
if ( ! node ) return
0 commit comments