feat(KB-617): add Changes tab to task detail modal for viewing file diffs
- Add baseCommitSha field to tasks for diff computation baseline - Track modified files in executor and store in database - Add /api/tasks/:id/diff endpoint to serve unified diffs - Add getTaskDiff() API client function in dashboard - Create TaskChangesTab component with file list and diff viewer - Integrate Changes tab into TaskDetailModal with proper styling - Add changeset for the new diff viewer feature
This commit is contained in:
@@ -1868,3 +1868,14 @@ export function fetchProjectTasks(projectId: string, limit?: number, offset?: nu
|
||||
export function fetchProjectConfig(projectId: string): Promise<{ maxConcurrent: number; rootDir: string }> {
|
||||
return api<{ maxConcurrent: number; rootDir: string }>(`/projects/${encodeURIComponent(projectId)}/config`);
|
||||
}
|
||||
|
||||
/** Diff information for a task */
|
||||
export interface TaskDiff {
|
||||
files: string[];
|
||||
diffs: Record<string, { stat: string; patch: string }>;
|
||||
}
|
||||
|
||||
/** Fetch diff information for a task */
|
||||
export function fetchTaskDiff(taskId: string): Promise<TaskDiff> {
|
||||
return api<TaskDiff>(`/tasks/${encodeURIComponent(taskId)}/diff`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user