147 lines
4.1 KiB
TypeScript
147 lines
4.1 KiB
TypeScript
import type { LiveWorkboardState, WorkflowEvent } from './types';
|
|
|
|
export const mockLiveWorkboard: LiveWorkboardState = {
|
|
source: 'mock',
|
|
workflow: {
|
|
id: 'wf-hanarang-live-workboard-v0',
|
|
title: '하나랑 Live Workboard v0',
|
|
phase: 'building',
|
|
summary: '4자매가 작업하는 과정을 메인 화면에서 실시간으로 보여주는 첫 버전',
|
|
planPath: '.plans/rebuild-from-scratch/PLAN.md',
|
|
updatedAt: '방금 전',
|
|
source: 'mock',
|
|
},
|
|
sisters: [
|
|
{
|
|
id: 'harang',
|
|
name: '하랑이',
|
|
role: 'Planner',
|
|
color: '#8bd3ff',
|
|
phase: 'planning',
|
|
status: 'waiting',
|
|
currentTask: 'PLAN.md 승인 범위 정리 완료',
|
|
lastEvent: '나랑이에게 v0 구현 handoff 전달',
|
|
nextHandoff: '구현 중 scope 변경 생기면 플랜 보강',
|
|
progress: 100,
|
|
mode: 'role-skill',
|
|
},
|
|
{
|
|
id: 'narang',
|
|
name: '나랑이',
|
|
role: 'Builder',
|
|
color: '#ffcc66',
|
|
phase: 'building',
|
|
status: 'working',
|
|
currentTask: 'Live Workboard mock UI 구현',
|
|
lastEvent: 'Sister activity lane 컴포넌트 생성',
|
|
nextHandoff: 'lint/build 결과를 다랑이에게 전달',
|
|
progress: 58,
|
|
mode: 'role-skill',
|
|
},
|
|
{
|
|
id: 'darang',
|
|
name: '다랑이',
|
|
role: 'Reviewer',
|
|
color: '#c6a5ff',
|
|
phase: 'reviewing',
|
|
status: 'idle',
|
|
currentTask: '구현 완료 대기',
|
|
lastEvent: 'QA checklist 준비',
|
|
nextHandoff: 'spec compliance review 시작',
|
|
progress: 20,
|
|
mode: 'role-skill',
|
|
},
|
|
{
|
|
id: 'erang',
|
|
name: '이랑이',
|
|
role: 'Infra / Orchestrator',
|
|
color: '#ff8f70',
|
|
phase: 'waiting_approval',
|
|
status: 'thinking',
|
|
currentTask: '승인 게이트와 배포 위험 분리',
|
|
lastEvent: 'DB/배포 변경 없음 확인',
|
|
nextHandoff: '다랑이 PASS 후 자기야에게 배포 승인 요청',
|
|
progress: 42,
|
|
mode: 'main',
|
|
},
|
|
],
|
|
approvals: [
|
|
{
|
|
id: 'approval-v0-local',
|
|
title: 'v0 로컬 UI 구현',
|
|
risk: 'L2',
|
|
status: 'not-required',
|
|
},
|
|
{
|
|
id: 'approval-deploy',
|
|
title: 'production 배포',
|
|
risk: 'L3',
|
|
status: 'waiting',
|
|
},
|
|
{
|
|
id: 'approval-proxmox-write',
|
|
title: 'Proxmox write API / restart action',
|
|
risk: 'L4',
|
|
status: 'blocked',
|
|
},
|
|
],
|
|
events: [
|
|
{
|
|
id: 'evt-001',
|
|
at: '13:04',
|
|
sister: 'harang',
|
|
type: 'PLAN_CREATED',
|
|
title: '재구축 PLAN 작성',
|
|
detail: '메인 서비스를 4 Sisters Live Workboard로 재정의',
|
|
workflowId: 'wf-hanarang-live-workboard-v0',
|
|
source: 'mock',
|
|
},
|
|
{
|
|
id: 'evt-002',
|
|
at: '13:09',
|
|
sister: 'erang',
|
|
type: 'APPROVAL_NEEDED',
|
|
title: 'Gate A 승인 확인',
|
|
detail: '자기야가 “그거 먼저 만들어보자”로 v0 구현 승인',
|
|
workflowId: 'wf-hanarang-live-workboard-v0',
|
|
source: 'mock',
|
|
},
|
|
{
|
|
id: 'evt-003',
|
|
at: '13:12',
|
|
sister: 'narang',
|
|
type: 'BUILD_STARTED',
|
|
title: 'Frontend v0 구현 시작',
|
|
detail: 'mock event stream 기반 lane/timeline/focus UI 생성',
|
|
workflowId: 'wf-hanarang-live-workboard-v0',
|
|
source: 'mock',
|
|
},
|
|
{
|
|
id: 'evt-004',
|
|
at: '13:15',
|
|
sister: 'narang',
|
|
type: 'FILES_CHANGED',
|
|
title: 'Live Workboard 컴포넌트 추가',
|
|
detail: 'SisterActivityLane, WorkflowTimeline, ActiveTaskFocus',
|
|
workflowId: 'wf-hanarang-live-workboard-v0',
|
|
source: 'mock',
|
|
},
|
|
{
|
|
id: 'evt-005',
|
|
at: 'next',
|
|
sister: 'darang',
|
|
type: 'REVIEW_REQUESTED',
|
|
title: '다랑이 리뷰 예정',
|
|
detail: 'lint/build 결과 확인 후 spec compliance review',
|
|
workflowId: 'wf-hanarang-live-workboard-v0',
|
|
source: 'mock',
|
|
},
|
|
],
|
|
};
|
|
|
|
export function rotateEvents(events: WorkflowEvent[], tick: number): WorkflowEvent[] {
|
|
if (events.length === 0) return events;
|
|
const offset = tick % events.length;
|
|
return [...events.slice(offset), ...events.slice(0, offset)];
|
|
}
|