export type MobileWorkUnitTone = "blue" | "green" | "orange" | "purple";

export interface MobileProjectView {
  readonly connected: boolean;
  readonly id: string;
  readonly name: string;
}

export interface MobileWorkUnitView {
  readonly artifactCount: number;
  readonly code: string;
  readonly id: string;
  readonly canRetry: boolean;
  readonly canStart: boolean;
  readonly nextAction: string;
  readonly pullRequestNumber?: number;
  readonly progress: number;
  readonly reviewUrl?: string;
  readonly statusLabel: string;
  readonly summary: string;
  readonly title: string;
  readonly tone: MobileWorkUnitTone;
  readonly updatedLabel: string;
}

export interface MobileSignalView {
  readonly desiredOutcome: string;
  readonly id: string;
  readonly projectId?: string;
  readonly summary: string;
  readonly title: string;
}

export interface MobileAssistantMessageView {
  readonly id: string;
  readonly role: "assistant" | "user";
  readonly text: string;
}

export interface MobileAssistantView {
  readonly isBusy: boolean;
  readonly messages: readonly MobileAssistantMessageView[];
  readonly statusLabel: string;
  readonly statusTone: "amber" | "green" | "red";
}

export interface MobileWorkspaceView {
  readonly activeCount: number;
  readonly activityCount: number;
  readonly artifactCount: number;
  readonly assistant: MobileAssistantView;
  readonly isLoading: boolean;
  readonly latestSignal?: MobileSignalView;
  readonly needsAttentionCount: number;
  readonly organizationLabel: string;
  readonly projects: readonly MobileProjectView[];
  readonly projectName?: string;
  readonly selectedProjectId?: string;
  readonly selectedWorkUnit?: MobileWorkUnitView;
  readonly shippedCount: number;
  readonly totalCount: number;
  readonly workUnits: readonly MobileWorkUnitView[];
}
