feat: Add webcam basic support

This commit is contained in:
2026-03-30 03:10:44 +02:00
parent 727059fb52
commit b7d4bf20e3
40 changed files with 1042 additions and 296 deletions

View File

@@ -59,6 +59,7 @@ export interface ChatEventBase {
permissions?: Partial<RoomPermissions>;
voiceState?: Partial<VoiceState>;
isScreenSharing?: boolean;
isCameraEnabled?: boolean;
icon?: string;
iconUpdatedAt?: number;
role?: UserRole;
@@ -216,6 +217,11 @@ export interface ScreenStateEvent extends ChatEventBase {
isScreenSharing: boolean;
}
export interface CameraStateEvent extends ChatEventBase {
type: 'camera-state';
isCameraEnabled: boolean;
}
export interface VoiceStateRequestEvent extends ChatEventBase {
type: 'voice-state-request';
}
@@ -332,6 +338,7 @@ export type ChatEvent =
| VoiceStateEvent
| VoiceChannelMoveEvent
| ScreenStateEvent
| CameraStateEvent
| VoiceStateRequestEvent
| StateRequestEvent
| ScreenShareRequestEvent

View File

@@ -1,4 +1,4 @@
import type { VoiceState, ScreenShareState } from './voice-state.models';
import type { CameraState, VoiceState, ScreenShareState } from './voice-state.models';
export type UserStatus = 'online' | 'away' | 'busy' | 'offline';
@@ -19,6 +19,7 @@ export interface User {
isRoomOwner?: boolean;
voiceState?: VoiceState;
screenShareState?: ScreenShareState;
cameraState?: CameraState;
}
export interface RoomMember {

View File

@@ -15,3 +15,7 @@ export interface ScreenShareState {
sourceId?: string;
sourceName?: string;
}
export interface CameraState {
isEnabled: boolean;
}