feat: Add Diff View and File History Tracking
- Implemented a new Diff view in the Workbench to track file changes - Added file history tracking with version control and change tracking - Created a FileModifiedDropdown to browse and manage modified files - Enhanced ActionRunner to support file history persistence - Updated Workbench and BaseChat components to support new diff view functionality - Added support for inline and side-by-side diff view modes
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import type { Change } from 'diff';
|
||||
|
||||
export type ActionType = 'file' | 'shell';
|
||||
|
||||
export interface BaseAction {
|
||||
@@ -28,3 +30,15 @@ export interface ActionAlert {
|
||||
content: string;
|
||||
source?: 'terminal' | 'preview'; // Add source to differentiate between terminal and preview errors
|
||||
}
|
||||
|
||||
export interface FileHistory {
|
||||
originalContent: string;
|
||||
lastModified: number;
|
||||
changes: Change[];
|
||||
versions: {
|
||||
timestamp: number;
|
||||
content: string;
|
||||
}[];
|
||||
// Novo campo para rastrear a origem das mudanças
|
||||
changeSource?: 'user' | 'auto-save' | 'external';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user