export type DeviceType = "display" | "camera" | "microphone";

export type RecordingMode = "display" | "webcam";

export interface Display {
  id: string;
  name: string;
}

export interface Camera {
  id: string;
  name: string;
}

export interface Microphone {
  id: string;
  name: string;
}

export type DisplayRecordingItem = {
  type: "display";
  display: Display;
  microphone?: Microphone;
  shows_cursor?: boolean;
};

export type WebcamRecordingItem = {
  type: "webcam";
  camera: Camera;
  microphone?: Microphone;
};

export type RecordingItem = DisplayRecordingItem | WebcamRecordingItem;

export interface RecorderOptions {
  output_directory: string;
  items: RecordingItem[];
}

export interface FileResult {
  path: string;
  type: RecordingMode;
  deviceName?: string;
  dimensions?: {
    width: number;
    height: number;
  };
  durationInSeconds?: number;
}

export interface RecordingResult {
  files: FileResult[];
}
