From 118a471471106e108e11d9d40233fd05c0ee2d7f Mon Sep 17 00:00:00 2001 From: NaccOll Date: Wed, 10 Sep 2025 14:27:12 +0800 Subject: [PATCH 01/12] feat: enhance checkpoint diff functionality with new modes and UI updates --- .../checkpoints/__tests__/checkpoint.test.ts | 10 ++-- src/core/checkpoints/index.ts | 50 +++++++++++++------ src/shared/WebviewMessage.ts | 4 +- webview-ui/src/components/chat/ChatRow.tsx | 24 +++++++++ webview-ui/src/components/chat/ChatView.tsx | 2 + .../chat/checkpoints/CheckpointMenu.tsx | 24 +++++++++ webview-ui/src/i18n/locales/ca/chat.json | 2 + webview-ui/src/i18n/locales/de/chat.json | 2 + webview-ui/src/i18n/locales/en/chat.json | 2 + webview-ui/src/i18n/locales/es/chat.json | 2 + webview-ui/src/i18n/locales/fr/chat.json | 2 + webview-ui/src/i18n/locales/hi/chat.json | 2 + webview-ui/src/i18n/locales/id/chat.json | 2 + webview-ui/src/i18n/locales/it/chat.json | 2 + webview-ui/src/i18n/locales/ja/chat.json | 2 + webview-ui/src/i18n/locales/ko/chat.json | 2 + webview-ui/src/i18n/locales/nl/chat.json | 2 + webview-ui/src/i18n/locales/pl/chat.json | 2 + webview-ui/src/i18n/locales/pt-BR/chat.json | 2 + webview-ui/src/i18n/locales/ru/chat.json | 2 + webview-ui/src/i18n/locales/tr/chat.json | 2 + webview-ui/src/i18n/locales/vi/chat.json | 2 + webview-ui/src/i18n/locales/zh-CN/chat.json | 2 + webview-ui/src/i18n/locales/zh-TW/chat.json | 2 + 24 files changed, 129 insertions(+), 21 deletions(-) diff --git a/src/core/checkpoints/__tests__/checkpoint.test.ts b/src/core/checkpoints/__tests__/checkpoint.test.ts index e073c0cb9223..250083a4ad3f 100644 --- a/src/core/checkpoints/__tests__/checkpoint.test.ts +++ b/src/core/checkpoints/__tests__/checkpoint.test.ts @@ -283,7 +283,7 @@ describe("Checkpoint functionality", () => { ] }) - it("should show diff for full mode", async () => { + it("should show diff for to-current mode", async () => { const mockChanges = [ { paths: { absolute: "/test/file.ts", relative: "file.ts" }, @@ -295,7 +295,7 @@ describe("Checkpoint functionality", () => { await checkpointDiff(mockTask, { ts: 4, commitHash: "commit2", - mode: "full", + mode: "to-current", }) expect(mockCheckpointService.getDiff).toHaveBeenCalledWith({ @@ -304,7 +304,7 @@ describe("Checkpoint functionality", () => { }) expect(vscode.commands.executeCommand).toHaveBeenCalledWith( "vscode.changes", - "Changes since task started", + "Changes to current workspace", expect.any(Array), ) }) @@ -361,7 +361,7 @@ describe("Checkpoint functionality", () => { await checkpointDiff(mockTask, { ts: 4, commitHash: "commit2", - mode: "full", + mode: "to-current", }) expect(vscode.window.showInformationMessage).toHaveBeenCalledWith("No changes found.") @@ -374,7 +374,7 @@ describe("Checkpoint functionality", () => { await checkpointDiff(mockTask, { ts: 4, commitHash: "commit2", - mode: "full", + mode: "to-current", }) expect(mockTask.enableCheckpoints).toBe(false) diff --git a/src/core/checkpoints/index.ts b/src/core/checkpoints/index.ts index bc842c9f1879..cacd01f9f606 100644 --- a/src/core/checkpoints/index.ts +++ b/src/core/checkpoints/index.ts @@ -270,10 +270,10 @@ export async function checkpointRestore( } export type CheckpointDiffOptions = { - ts: number + ts?: number previousCommitHash?: string commitHash: string - mode: "full" | "checkpoint" + mode: "from-init" | "checkpoint" | "to-current" | "full" } export async function checkpointDiff(task: Task, { ts, previousCommitHash, commitHash, mode }: CheckpointDiffOptions) { @@ -285,21 +285,43 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi TelemetryService.instance.captureCheckpointDiffed(task.taskId) - let prevHash = commitHash - let nextHash: string | undefined = undefined + let fromHash: string | undefined + let toHash: string | undefined + let title: string + + const checkpoints = task.clineMessages.filter(({ say }) => say === "checkpoint_saved").map(({ text }) => text!) + + const idx = checkpoints.indexOf(commitHash) + switch (mode) { + case "checkpoint": + fromHash = commitHash + toHash = idx !== -1 && idx < checkpoints.length - 1 ? checkpoints[idx + 1] : undefined + title = "Changes compare with next checkpoint" + break + case "from-init": + fromHash = checkpoints[0] + toHash = commitHash + title = "Changes since first checkpoint" + break + case "to-current": + fromHash = commitHash + toHash = undefined + title = "Changes to current workspace" + break + case "full": + fromHash = checkpoints[0] + toHash = undefined + title = "Changes since first checkpoint" + break + } - if (mode !== "full") { - const checkpoints = task.clineMessages.filter(({ say }) => say === "checkpoint_saved").map(({ text }) => text!) - const idx = checkpoints.indexOf(commitHash) - if (idx !== -1 && idx < checkpoints.length - 1) { - nextHash = checkpoints[idx + 1] - } else { - nextHash = undefined - } + if (!fromHash) { + vscode.window.showInformationMessage("No previous checkpoint to compare.") + return } try { - const changes = await service.getDiff({ from: prevHash, to: nextHash }) + const changes = await service.getDiff({ from: fromHash, to: toHash }) if (!changes?.length) { vscode.window.showInformationMessage("No changes found.") @@ -308,7 +330,7 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi await vscode.commands.executeCommand( "vscode.changes", - mode === "full" ? "Changes since task started" : "Changes compare with next checkpoint", + title, changes.map((change) => [ vscode.Uri.file(change.paths.absolute), vscode.Uri.parse(`${DIFF_VIEW_URI_SCHEME}:${change.paths.relative}`).with({ diff --git a/src/shared/WebviewMessage.ts b/src/shared/WebviewMessage.ts index d43a2fce0434..d55e95aa50b5 100644 --- a/src/shared/WebviewMessage.ts +++ b/src/shared/WebviewMessage.ts @@ -306,10 +306,10 @@ export interface WebviewMessage { } export const checkoutDiffPayloadSchema = z.object({ - ts: z.number(), + ts: z.number().optional(), previousCommitHash: z.string().optional(), commitHash: z.string(), - mode: z.enum(["full", "checkpoint"]), + mode: z.enum(["full", "checkpoint", "from-init", "to-current"]), }) export type CheckpointDiffPayload = z.infer diff --git a/webview-ui/src/components/chat/ChatRow.tsx b/webview-ui/src/components/chat/ChatRow.tsx index b0b87e7a2ddd..3f2c3b26fba9 100644 --- a/webview-ui/src/components/chat/ChatRow.tsx +++ b/webview-ui/src/components/chat/ChatRow.tsx @@ -16,6 +16,7 @@ import { findMatchingResourceOrTemplate } from "@src/utils/mcp" import { vscode } from "@src/utils/vscode" import { removeLeadingNonAlphanumeric } from "@src/utils/removeLeadingNonAlphanumeric" import { getLanguageFromPath } from "@src/utils/getLanguageFromPath" +import { Button, StandardTooltip } from "@src/components/ui" import { ToolUseBlock, ToolUseBlockHeader } from "../common/ToolUseBlock" import UpdateTodoListToolBlock from "./UpdateTodoListToolBlock" @@ -75,6 +76,7 @@ interface ChatRowProps { onFollowUpUnmount?: () => void isFollowUpAnswered?: boolean editable?: boolean + hasCheckpoint?: boolean } // eslint-disable-next-line @typescript-eslint/no-empty-object-type @@ -127,6 +129,7 @@ export const ChatRowContent = ({ onBatchFileResponse, isFollowUpAnswered, editable, + hasCheckpoint, }: ChatRowContentProps) => { const { t } = useTranslation() @@ -968,6 +971,25 @@ export const ChatRowContent = ({ } } + const viewFullDiffBtn = + hasCheckpoint && isLast && !isStreaming ? ( +
+ + + vscode.postMessage({ + type: "checkpointDiff", + payload: { mode: "full", commitHash: "" }, + }) + }> + {t("chat:checkpoint.menu.viewDiffFromInit")} + + +
+ ) : null + switch (message.type) { case "say": switch (message.say) { @@ -1201,6 +1223,7 @@ export const ChatRowContent = ({
+ {viewFullDiffBtn}
) @@ -1441,6 +1464,7 @@ export const ChatRowContent = ({
+ {viewFullDiffBtn}
) diff --git a/webview-ui/src/components/chat/ChatView.tsx b/webview-ui/src/components/chat/ChatView.tsx index d358c68f1cff..4e45c495b4dd 100644 --- a/webview-ui/src/components/chat/ChatView.tsx +++ b/webview-ui/src/components/chat/ChatView.tsx @@ -1525,6 +1525,7 @@ const ChatViewComponent: React.ForwardRefRenderFunction ) } + const hasCheckpoint = modifiedMessages.some((message) => message.say === "checkpoint_saved") // regular message return ( @@ -1559,6 +1560,7 @@ const ChatViewComponent: React.ForwardRefRenderFunction ) }, diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index c6948e5ce325..32f57ec45d07 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -41,6 +41,20 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange }) }, [ts, previousCommitHash, commitHash]) + const onDiffFromInit = useCallback(() => { + vscode.postMessage({ + type: "checkpointDiff", + payload: { ts, commitHash, mode: "from-init" }, + }) + }, [ts, commitHash]) + + const onDiffWithCurrent = useCallback(() => { + vscode.postMessage({ + type: "checkpointDiff", + payload: { ts, commitHash, mode: "to-current" }, + }) + }, [ts, commitHash]) + const onPreview = useCallback(() => { vscode.postMessage({ type: "checkpointRestore", payload: { ts, commitHash, mode: "preview" } }) setOpen(false) @@ -68,6 +82,16 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange + + + + + + diff --git a/webview-ui/src/i18n/locales/ca/chat.json b/webview-ui/src/i18n/locales/ca/chat.json index 4d392ee3bf68..d010ac049c42 100644 --- a/webview-ui/src/i18n/locales/ca/chat.json +++ b/webview-ui/src/i18n/locales/ca/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Encara s'està inicialitzant el punt de control... Si això triga massa, pots desactivar els punts de control a la configuració i reiniciar la teva tasca.", "menu": { "viewDiff": "Veure diferències", + "viewDiffFromInit": "Veure diferències amb el primer punt de control", + "viewDiffWithCurrent": "Veure diferències amb l'espai de treball actual", "restore": "Restaurar punt de control", "restoreFiles": "Restaurar arxius", "restoreFilesDescription": "Restaura els arxius del teu projecte a una instantània presa en aquest punt.", diff --git a/webview-ui/src/i18n/locales/de/chat.json b/webview-ui/src/i18n/locales/de/chat.json index 65934ab5a29c..781caa6f8f28 100644 --- a/webview-ui/src/i18n/locales/de/chat.json +++ b/webview-ui/src/i18n/locales/de/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Checkpoint wird noch initialisiert... Falls dies zu lange dauert, kannst du Checkpoints in den Einstellungen deaktivieren und deine Aufgabe neu starten.", "menu": { "viewDiff": "Unterschiede anzeigen", + "viewDiffFromInit": "Unterschiede mit erstem Checkpoint anzeigen", + "viewDiffWithCurrent": "Unterschiede mit aktuellem Workspace anzeigen", "restore": "Checkpoint wiederherstellen", "restoreFiles": "Dateien wiederherstellen", "restoreFilesDescription": "Stellt die Dateien deines Projekts auf einen Snapshot zurück, der an diesem Punkt erstellt wurde.", diff --git a/webview-ui/src/i18n/locales/en/chat.json b/webview-ui/src/i18n/locales/en/chat.json index 9ab37b11497a..b641d08cb3d2 100644 --- a/webview-ui/src/i18n/locales/en/chat.json +++ b/webview-ui/src/i18n/locales/en/chat.json @@ -154,6 +154,8 @@ "initializingWarning": "Still initializing checkpoint... If this takes too long, you can disable checkpoints in settings and restart your task.", "menu": { "viewDiff": "View Diff", + "viewDiffFromInit": "View Diff With First Checkpoint", + "viewDiffWithCurrent": "View Diff With Current Workspace", "restore": "Restore Checkpoint", "restoreFiles": "Restore Files", "restoreFilesDescription": "Restores your project's files back to a snapshot taken at this point.", diff --git a/webview-ui/src/i18n/locales/es/chat.json b/webview-ui/src/i18n/locales/es/chat.json index 30693285db2e..1d226b209ece 100644 --- a/webview-ui/src/i18n/locales/es/chat.json +++ b/webview-ui/src/i18n/locales/es/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Todavía inicializando el punto de control... Si esto tarda demasiado, puedes desactivar los puntos de control en la configuración y reiniciar tu tarea.", "menu": { "viewDiff": "Ver diferencias", + "viewDiffFromInit": "Ver diferencias con el primer punto de control", + "viewDiffWithCurrent": "Ver diferencias con el espacio de trabajo actual", "restore": "Restaurar punto de control", "restoreFiles": "Restaurar archivos", "restoreFilesDescription": "Restaura los archivos de tu proyecto a una instantánea tomada en este punto.", diff --git a/webview-ui/src/i18n/locales/fr/chat.json b/webview-ui/src/i18n/locales/fr/chat.json index d5dae24a7913..2fe245dced3e 100644 --- a/webview-ui/src/i18n/locales/fr/chat.json +++ b/webview-ui/src/i18n/locales/fr/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Initialisation du point de contrôle en cours... Si cela prend trop de temps, tu peux désactiver les points de contrôle dans les paramètres et redémarrer ta tâche.", "menu": { "viewDiff": "Voir les différences", + "viewDiffFromInit": "Voir les différences avec le premier point de contrôle", + "viewDiffWithCurrent": "Voir les différences avec l'espace de travail actuel", "restore": "Restaurer le point de contrôle", "restoreFiles": "Restaurer les fichiers", "restoreFilesDescription": "Restaure les fichiers de votre projet à un instantané pris à ce moment.", diff --git a/webview-ui/src/i18n/locales/hi/chat.json b/webview-ui/src/i18n/locales/hi/chat.json index 0ec9cd7c7e93..2a37aa632a51 100644 --- a/webview-ui/src/i18n/locales/hi/chat.json +++ b/webview-ui/src/i18n/locales/hi/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "चेकपॉइंट अभी भी आरंभ हो रहा है... अगर यह बहुत समय ले रहा है, तो आप सेटिंग्स में चेकपॉइंट को अक्षम कर सकते हैं और अपने कार्य को पुनः आरंभ कर सकते हैं।", "menu": { "viewDiff": "अंतर देखें", + "viewDiffFromInit": "पहले चेकपॉइंट के साथ अंतर देखें", + "viewDiffWithCurrent": "वर्तमान कार्यक्षेत्र के साथ अंतर देखें", "restore": "चेकपॉइंट पुनर्स्थापित करें", "restoreFiles": "फ़ाइलें पुनर्स्थापित करें", "restoreFilesDescription": "आपके प्रोजेक्ट की फ़ाइलों को इस बिंदु पर लिए गए स्नैपशॉट पर पुनर्स्थापित करता है।", diff --git a/webview-ui/src/i18n/locales/id/chat.json b/webview-ui/src/i18n/locales/id/chat.json index a2c5377691e9..a544768501b6 100644 --- a/webview-ui/src/i18n/locales/id/chat.json +++ b/webview-ui/src/i18n/locales/id/chat.json @@ -157,6 +157,8 @@ "initializingWarning": "Masih menginisialisasi checkpoint... Jika ini terlalu lama, kamu bisa menonaktifkan checkpoint di pengaturan dan restart tugas.", "menu": { "viewDiff": "Lihat Diff", + "viewDiffFromInit": "Lihat Diff dengan Checkpoint Pertama", + "viewDiffWithCurrent": "Lihat Diff dengan Workspace Saat Ini", "restore": "Pulihkan Checkpoint", "restoreFiles": "Pulihkan File", "restoreFilesDescription": "Mengembalikan file proyek kamu ke snapshot yang diambil pada titik ini.", diff --git a/webview-ui/src/i18n/locales/it/chat.json b/webview-ui/src/i18n/locales/it/chat.json index a176be1f2fb6..db3116fab3d2 100644 --- a/webview-ui/src/i18n/locales/it/chat.json +++ b/webview-ui/src/i18n/locales/it/chat.json @@ -151,6 +151,8 @@ "initializingWarning": "Inizializzazione del checkpoint in corso... Se questa operazione richiede troppo tempo, puoi disattivare i checkpoint nelle impostazioni e riavviare l'attività.", "menu": { "viewDiff": "Visualizza differenze", + "viewDiffFromInit": "Visualizza differenze dal primo checkpoint", + "viewDiffWithCurrent": "Visualizza differenze con l'area di lavoro attuale", "restore": "Ripristina checkpoint", "restoreFiles": "Ripristina file", "restoreFilesDescription": "Ripristina i file del tuo progetto a uno snapshot catturato in questo punto.", diff --git a/webview-ui/src/i18n/locales/ja/chat.json b/webview-ui/src/i18n/locales/ja/chat.json index 0e940b17ecac..5dd938d63a1d 100644 --- a/webview-ui/src/i18n/locales/ja/chat.json +++ b/webview-ui/src/i18n/locales/ja/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "チェックポイントの初期化中... 時間がかかりすぎる場合は、設定でチェックポイントを無効にしてタスクを再開できます。", "menu": { "viewDiff": "差分を表示", + "viewDiffFromInit": "最初のチェックポイントとの差分を表示", + "viewDiffWithCurrent": "現在のワークスペースとの差分を表示", "restore": "チェックポイントを復元", "restoreFiles": "ファイルを復元", "restoreFilesDescription": "この時点で撮影されたスナップショットにプロジェクトのファイルを復元します。", diff --git a/webview-ui/src/i18n/locales/ko/chat.json b/webview-ui/src/i18n/locales/ko/chat.json index 6fa7c5692ac6..bf2b27784e1d 100644 --- a/webview-ui/src/i18n/locales/ko/chat.json +++ b/webview-ui/src/i18n/locales/ko/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "체크포인트 초기화 중... 시간이 너무 오래 걸리면 설정에서 체크포인트를 비활성화하고 작업을 다시 시작할 수 있습니다.", "menu": { "viewDiff": "차이점 보기", + "viewDiffFromInit": "첫 번째 체크포인트와의 차이점 보기", + "viewDiffWithCurrent": "현재 워크스페이스와의 차이점 보기", "restore": "체크포인트 복원", "restoreFiles": "파일 복원", "restoreFilesDescription": "프로젝트 파일을 이 시점에 찍힌 스냅샷으로 복원합니다.", diff --git a/webview-ui/src/i18n/locales/nl/chat.json b/webview-ui/src/i18n/locales/nl/chat.json index 2be312228d27..54a2cb23848f 100644 --- a/webview-ui/src/i18n/locales/nl/chat.json +++ b/webview-ui/src/i18n/locales/nl/chat.json @@ -143,6 +143,8 @@ "initializingWarning": "Checkpoint wordt nog steeds geïnitialiseerd... Als dit te lang duurt, kun je checkpoints uitschakelen in de instellingen en je taak opnieuw starten.", "menu": { "viewDiff": "Bekijk verschil", + "viewDiffFromInit": "Bekijk verschil met eerste checkpoint", + "viewDiffWithCurrent": "Bekijk verschil met huidige werkruimte", "restore": "Herstel checkpoint", "restoreFiles": "Bestanden herstellen", "restoreFilesDescription": "Herstelt de bestanden van je project naar een momentopname die op dit punt is gemaakt.", diff --git a/webview-ui/src/i18n/locales/pl/chat.json b/webview-ui/src/i18n/locales/pl/chat.json index e60ec330db23..241ebeb4e547 100644 --- a/webview-ui/src/i18n/locales/pl/chat.json +++ b/webview-ui/src/i18n/locales/pl/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Trwa inicjalizacja punktu kontrolnego... Jeśli to trwa zbyt długo, możesz wyłączyć punkty kontrolne w ustawieniach i uruchomić zadanie ponownie.", "menu": { "viewDiff": "Zobacz różnice", + "viewDiffFromInit": "Zobacz różnice z pierwszym punktem kontrolnym", + "viewDiffWithCurrent": "Zobacz różnice z bieżącym projektem", "restore": "Przywróć punkt kontrolny", "restoreFiles": "Przywróć pliki", "restoreFilesDescription": "Przywraca pliki Twojego projektu do zrzutu wykonanego w tym punkcie.", diff --git a/webview-ui/src/i18n/locales/pt-BR/chat.json b/webview-ui/src/i18n/locales/pt-BR/chat.json index 3408f3a1aa91..01e727894bab 100644 --- a/webview-ui/src/i18n/locales/pt-BR/chat.json +++ b/webview-ui/src/i18n/locales/pt-BR/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Ainda inicializando ponto de verificação... Se isso demorar muito, você pode desativar os pontos de verificação nas configurações e reiniciar sua tarefa.", "menu": { "viewDiff": "Ver diferenças", + "viewDiffFromInit": "Ver diferenças com o primeiro ponto de verificação", + "viewDiffWithCurrent": "Ver diferenças com o espaço de trabalho atual", "restore": "Restaurar ponto de verificação", "restoreFiles": "Restaurar arquivos", "restoreFilesDescription": "Restaura os arquivos do seu projeto para um snapshot feito neste ponto.", diff --git a/webview-ui/src/i18n/locales/ru/chat.json b/webview-ui/src/i18n/locales/ru/chat.json index 5018f817aff5..9e49ae19fe72 100644 --- a/webview-ui/src/i18n/locales/ru/chat.json +++ b/webview-ui/src/i18n/locales/ru/chat.json @@ -143,6 +143,8 @@ "initializingWarning": "Точка сохранения еще инициализируется... Если это занимает слишком много времени, вы можете отключить точки сохранения в настройках и перезапустить задачу.", "menu": { "viewDiff": "Просмотреть различия", + "viewDiffFromInit": "Просмотреть различия с первой точкой сохранения", + "viewDiffWithCurrent": "Просмотреть различия с текущим рабочим пространством", "restore": "Восстановить точку сохранения", "restoreFiles": "Восстановить файлы", "restoreFilesDescription": "Восстанавливает файлы вашего проекта до состояния на момент этой точки.", diff --git a/webview-ui/src/i18n/locales/tr/chat.json b/webview-ui/src/i18n/locales/tr/chat.json index 2290a85f6dfe..698feb6f46d6 100644 --- a/webview-ui/src/i18n/locales/tr/chat.json +++ b/webview-ui/src/i18n/locales/tr/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Kontrol noktası hala başlatılıyor... Bu çok uzun sürerse, ayarlar bölümünden kontrol noktalarını devre dışı bırakabilir ve görevinizi yeniden başlatabilirsiniz.", "menu": { "viewDiff": "Farkları Görüntüle", + "viewDiffFromInit": "İlk Kontrol Noktası ile Farkları Görüntüle", + "viewDiffWithCurrent": "Mevcut Çalışma Alanı ile Farkları Görüntüle", "restore": "Kontrol Noktasını Geri Yükle", "restoreFiles": "Dosyaları Geri Yükle", "restoreFilesDescription": "Projenizin dosyalarını bu noktada alınan bir anlık görüntüye geri yükler.", diff --git a/webview-ui/src/i18n/locales/vi/chat.json b/webview-ui/src/i18n/locales/vi/chat.json index d9362ea39dde..9b9cec2ff59f 100644 --- a/webview-ui/src/i18n/locales/vi/chat.json +++ b/webview-ui/src/i18n/locales/vi/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "Đang khởi tạo điểm kiểm tra... Nếu quá trình này mất quá nhiều thời gian, bạn có thể vô hiệu hóa điểm kiểm tra trong cài đặt và khởi động lại tác vụ của bạn.", "menu": { "viewDiff": "Xem khác biệt", + "viewDiffFromInit": "Xem khác biệt với điểm kiểm tra đầu tiên", + "viewDiffWithCurrent": "Xem khác biệt với không gian làm việc hiện tại", "restore": "Khôi phục điểm kiểm tra", "restoreFiles": "Khôi phục tệp", "restoreFilesDescription": "Khôi phục các tệp dự án của bạn về bản chụp được thực hiện tại thời điểm này.", diff --git a/webview-ui/src/i18n/locales/zh-CN/chat.json b/webview-ui/src/i18n/locales/zh-CN/chat.json index 850f79e63038..b8026ce51cca 100644 --- a/webview-ui/src/i18n/locales/zh-CN/chat.json +++ b/webview-ui/src/i18n/locales/zh-CN/chat.json @@ -148,6 +148,8 @@ "initializingWarning": "正在初始化检查点...如果耗时过长,你可以在设置中禁用检查点并重新启动任务。", "menu": { "viewDiff": "查看差异", + "viewDiffFromInit": "与首个检查点对比差异", + "viewDiffWithCurrent": "与当前工作区对比差异", "restore": "恢复检查点", "restoreFiles": "恢复文件", "restoreFilesDescription": "将项目文件恢复到此检查点状态", diff --git a/webview-ui/src/i18n/locales/zh-TW/chat.json b/webview-ui/src/i18n/locales/zh-TW/chat.json index 715452977af5..aeb18d6da33c 100644 --- a/webview-ui/src/i18n/locales/zh-TW/chat.json +++ b/webview-ui/src/i18n/locales/zh-TW/chat.json @@ -154,6 +154,8 @@ "initializingWarning": "正在初始化檢查點... 如果耗時過長,您可以在設定中停用檢查點並重新啟動工作。", "menu": { "viewDiff": "檢視差異", + "viewDiffFromInit": "與第一個檢查點比較差異", + "viewDiffWithCurrent": "與目前工作區比較差異", "restore": "還原檢查點", "restoreFiles": "還原檔案", "restoreFilesDescription": "將您的專案檔案還原到此時的快照。", From b7f40c29bf09527bdb2d2b270cbc2a7ecd8f352c Mon Sep 17 00:00:00 2001 From: NaccOll Date: Wed, 10 Sep 2025 14:45:52 +0800 Subject: [PATCH 02/12] feat: add detailed mode descriptions for checkpointDiff options and update tooltip text in ChatRow --- src/core/checkpoints/index.ts | 6 ++++++ webview-ui/src/components/chat/ChatRow.tsx | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/core/checkpoints/index.ts b/src/core/checkpoints/index.ts index cacd01f9f606..aa4e98bd11c3 100644 --- a/src/core/checkpoints/index.ts +++ b/src/core/checkpoints/index.ts @@ -273,6 +273,12 @@ export type CheckpointDiffOptions = { ts?: number previousCommitHash?: string commitHash: string + /** + * from-init: Compare from the first checkpoint to the selected checkpoint. + * checkpoint: Compare the selected checkpoint to the next checkpoint. + * to-current: Compare the selected checkpoint to the current workspace. + * full: Compare from the first checkpoint to the current workspace. + */ mode: "from-init" | "checkpoint" | "to-current" | "full" } diff --git a/webview-ui/src/components/chat/ChatRow.tsx b/webview-ui/src/components/chat/ChatRow.tsx index 3f2c3b26fba9..d03dbd021b52 100644 --- a/webview-ui/src/components/chat/ChatRow.tsx +++ b/webview-ui/src/components/chat/ChatRow.tsx @@ -974,7 +974,7 @@ export const ChatRowContent = ({ const viewFullDiffBtn = hasCheckpoint && isLast && !isStreaming ? (
- + Date: Wed, 10 Sep 2025 14:49:31 +0800 Subject: [PATCH 03/12] fix: add validation for checkpointDiff mode to ensure first checkpoint exists --- src/core/checkpoints/index.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/checkpoints/index.ts b/src/core/checkpoints/index.ts index aa4e98bd11c3..592f2cdd3ab9 100644 --- a/src/core/checkpoints/index.ts +++ b/src/core/checkpoints/index.ts @@ -297,6 +297,11 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi const checkpoints = task.clineMessages.filter(({ say }) => say === "checkpoint_saved").map(({ text }) => text!) + if (["from-init", "full"].includes(mode) && checkpoints.length < 1) { + vscode.window.showInformationMessage("No first checkpoint to compare.") + return + } + const idx = checkpoints.indexOf(commitHash) switch (mode) { case "checkpoint": From 34e3357ab65c4a7c3b3368a67e364d231d6447cb Mon Sep 17 00:00:00 2001 From: NaccOll Date: Tue, 23 Sep 2025 00:18:26 +0800 Subject: [PATCH 04/12] feat: remove full diff view button --- webview-ui/src/components/chat/ChatRow.tsx | 24 +--------------------- 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/webview-ui/src/components/chat/ChatRow.tsx b/webview-ui/src/components/chat/ChatRow.tsx index d03dbd021b52..1b97c376f611 100644 --- a/webview-ui/src/components/chat/ChatRow.tsx +++ b/webview-ui/src/components/chat/ChatRow.tsx @@ -16,7 +16,7 @@ import { findMatchingResourceOrTemplate } from "@src/utils/mcp" import { vscode } from "@src/utils/vscode" import { removeLeadingNonAlphanumeric } from "@src/utils/removeLeadingNonAlphanumeric" import { getLanguageFromPath } from "@src/utils/getLanguageFromPath" -import { Button, StandardTooltip } from "@src/components/ui" +import { Button } from "@src/components/ui" import { ToolUseBlock, ToolUseBlockHeader } from "../common/ToolUseBlock" import UpdateTodoListToolBlock from "./UpdateTodoListToolBlock" @@ -129,7 +129,6 @@ export const ChatRowContent = ({ onBatchFileResponse, isFollowUpAnswered, editable, - hasCheckpoint, }: ChatRowContentProps) => { const { t } = useTranslation() @@ -971,25 +970,6 @@ export const ChatRowContent = ({ } } - const viewFullDiffBtn = - hasCheckpoint && isLast && !isStreaming ? ( -
- - - vscode.postMessage({ - type: "checkpointDiff", - payload: { mode: "full", commitHash: "" }, - }) - }> - {t("chat:checkpoint.menu.viewDiffFromInit")} - - -
- ) : null - switch (message.type) { case "say": switch (message.say) { @@ -1223,7 +1203,6 @@ export const ChatRowContent = ({
- {viewFullDiffBtn}
) @@ -1464,7 +1443,6 @@ export const ChatRowContent = ({
- {viewFullDiffBtn}
) From 2e3e250127b823ed7d91bf91d9cedd51d0f5d231 Mon Sep 17 00:00:00 2001 From: NaccOll Date: Tue, 23 Sep 2025 00:58:27 +0800 Subject: [PATCH 05/12] feat: change more diff button to drop-down menu --- .../chat/checkpoints/CheckpointMenu.tsx | 42 ++++++++++++++----- 1 file changed, 32 insertions(+), 10 deletions(-) diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index 32f57ec45d07..c7e293743eb2 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -27,6 +27,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange const { t } = useTranslation() const [internalOpen, setInternalOpen] = useState(false) const [isConfirming, setIsConfirming] = useState(false) + const [isDiffOpen, setIsDiffOpen] = useState(false) const portalContainer = useRooPortal("roo-portal") const previousCommitHash = checkpoint?.from @@ -82,16 +83,6 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange
- - - - - - @@ -151,6 +142,37 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange + setIsDiffOpen(open)}> + + + + + + +
+ + +
+
+
) } From 65813f24d59f984812459c7d28db8a63eaaac44e Mon Sep 17 00:00:00 2001 From: NaccOll Date: Wed, 24 Sep 2025 15:38:49 +0800 Subject: [PATCH 06/12] fix: popover show error when CheckpointMenu has multiple popover --- .../chat/checkpoints/CheckpointMenu.tsx | 74 ++++++++++++------- .../chat/checkpoints/CheckpointSaved.tsx | 7 +- .../__tests__/CheckpointSaved.spec.tsx | 17 +++-- 3 files changed, 60 insertions(+), 38 deletions(-) diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index c7e293743eb2..515a6d666a99 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -11,29 +11,47 @@ import { Checkpoint } from "./schema" type CheckpointMenuBaseProps = { ts: number commitHash: string + currentHash?: string checkpoint: Checkpoint } type CheckpointMenuControlledProps = { - open: boolean onOpenChange: (open: boolean) => void } type CheckpointMenuUncontrolledProps = { - open?: undefined onOpenChange?: undefined } type CheckpointMenuProps = CheckpointMenuBaseProps & (CheckpointMenuControlledProps | CheckpointMenuUncontrolledProps) -export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange }: CheckpointMenuProps) => { +export const CheckpointMenu = ({ ts, commitHash, currentHash, checkpoint, onOpenChange }: CheckpointMenuProps) => { const { t } = useTranslation() - const [internalOpen, setInternalOpen] = useState(false) - const [isConfirming, setIsConfirming] = useState(false) - const [isDiffOpen, setIsDiffOpen] = useState(false) + const [internalRestoreOpen, setInternalRestoreOpen] = useState(false) + const [restoreConfirming, setRestoreIsConfirming] = useState(false) + const [internalMoreOpen, setInternalMoreOpen] = useState(false) const portalContainer = useRooPortal("roo-portal") const previousCommitHash = checkpoint?.from - const isOpen = open ?? internalOpen - const setOpen = onOpenChange ?? setInternalOpen + const restoreOpen = internalRestoreOpen + const moreOpen = internalMoreOpen + const setRestoreOpen = useCallback( + (open: boolean) => { + setInternalRestoreOpen(open) + if (onOpenChange) { + onOpenChange(open) + } + }, + [onOpenChange], + ) + + const setMoreOpen = useCallback( + (open: boolean) => { + setInternalMoreOpen(open) + if (onOpenChange) { + onOpenChange(open) + } + }, + [onOpenChange], + ) const onCheckpointDiff = useCallback(() => { vscode.postMessage({ @@ -58,22 +76,22 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange const onPreview = useCallback(() => { vscode.postMessage({ type: "checkpointRestore", payload: { ts, commitHash, mode: "preview" } }) - setOpen(false) - }, [ts, commitHash, setOpen]) + setRestoreOpen(false) + }, [ts, commitHash, setRestoreOpen]) const onRestore = useCallback(() => { vscode.postMessage({ type: "checkpointRestore", payload: { ts, commitHash, mode: "restore" } }) - setOpen(false) - }, [ts, commitHash, setOpen]) + setRestoreOpen(false) + }, [ts, commitHash, setRestoreOpen]) const handleOpenChange = useCallback( (open: boolean) => { - setOpen(open) + setRestoreOpen(open) if (!open) { - setIsConfirming(false) + setRestoreIsConfirming(false) } }, - [setOpen], + [setRestoreOpen], ) return ( @@ -83,7 +101,13 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange - + { + handleOpenChange(open) + setRestoreIsConfirming(false) + }} + data-testid="restore-popover"> @@ -121,7 +145,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange
{t("chat:checkpoint.menu.confirm")}
- )} - {isConfirming ? ( + {restoreConfirming ? (
{t("chat:checkpoint.menu.cannotUndo")}
@@ -142,7 +166,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, open, onOpenChange
- setIsDiffOpen(open)}> + setMoreOpen(open)} data-testid="more-popover"> , StandardTooltip: ({ children }: any) => <>{children}, - Popover: ({ children, onOpenChange, open }: any) => { - lastOnOpenChange = onOpenChange + Popover: (props: any) => { + const { children, onOpenChange, open, ...rest } = props + if (rest["data-testid"] === "restore-popover") { + lastOnOpenChange = onOpenChange + } return ( -
+
{children}
) @@ -23,9 +29,6 @@ import React from "react" import userEvent from "@testing-library/user-event" import { CheckpointSaved } from "../CheckpointSaved" -// Capture onOpenChange from Popover to control open/close in tests -let lastOnOpenChange: ((open: boolean) => void) | undefined - const waitForOpenHandler = async () => { await waitFor(() => { // ensure Popover mock captured the onOpenChange handler before using it @@ -101,7 +104,7 @@ describe("CheckpointSaved popover visibility", () => { it("closes popover after preview and after confirm restore", async () => { const { getByTestId } = render() - const popoverRoot = () => getByTestId("popover-root") + const popoverRoot = () => getByTestId("restore-popover") const menuContainer = () => getByTestId("checkpoint-menu-container") // Open From f6a97cd546917c11e157f3935b0e9b6b342fd711 Mon Sep 17 00:00:00 2001 From: NaccOll Date: Tue, 30 Sep 2025 00:22:12 +0800 Subject: [PATCH 07/12] fix: update icon in CheckpointMenu for better clarity --- webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index 515a6d666a99..15adf54ff9ab 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -170,7 +170,7 @@ export const CheckpointMenu = ({ ts, commitHash, currentHash, checkpoint, onOpen From 61136f05910d383529c0b0eb0a541040e4edebb4 Mon Sep 17 00:00:00 2001 From: NaccOll Date: Tue, 30 Sep 2025 00:31:55 +0800 Subject: [PATCH 08/12] Update webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx Co-authored-by: Bruno Bergher --- webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index 15adf54ff9ab..d0434fb21d6b 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -170,7 +170,7 @@ export const CheckpointMenu = ({ ts, commitHash, currentHash, checkpoint, onOpen From 91689d4e8e105561bf674146b6938a3610fd7a66 Mon Sep 17 00:00:00 2001 From: daniel-lxs Date: Thu, 23 Oct 2025 16:47:14 -0500 Subject: [PATCH 09/12] feat: Update checkpoint menu translations for PR #7841 --- webview-ui/src/i18n/locales/ca/chat.json | 4 ++-- webview-ui/src/i18n/locales/de/chat.json | 4 ++-- webview-ui/src/i18n/locales/en/chat.json | 4 ++-- webview-ui/src/i18n/locales/es/chat.json | 4 ++-- webview-ui/src/i18n/locales/fr/chat.json | 4 ++-- webview-ui/src/i18n/locales/hi/chat.json | 4 ++-- webview-ui/src/i18n/locales/id/chat.json | 4 ++-- webview-ui/src/i18n/locales/it/chat.json | 4 ++-- webview-ui/src/i18n/locales/ja/chat.json | 4 ++-- webview-ui/src/i18n/locales/ko/chat.json | 4 ++-- webview-ui/src/i18n/locales/nl/chat.json | 4 ++-- webview-ui/src/i18n/locales/pl/chat.json | 4 ++-- webview-ui/src/i18n/locales/pt-BR/chat.json | 4 ++-- webview-ui/src/i18n/locales/ru/chat.json | 4 ++-- webview-ui/src/i18n/locales/tr/chat.json | 4 ++-- webview-ui/src/i18n/locales/vi/chat.json | 4 ++-- webview-ui/src/i18n/locales/zh-CN/chat.json | 4 ++-- webview-ui/src/i18n/locales/zh-TW/chat.json | 4 ++-- 18 files changed, 36 insertions(+), 36 deletions(-) diff --git a/webview-ui/src/i18n/locales/ca/chat.json b/webview-ui/src/i18n/locales/ca/chat.json index d010ac049c42..bf33a349c7d9 100644 --- a/webview-ui/src/i18n/locales/ca/chat.json +++ b/webview-ui/src/i18n/locales/ca/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Encara s'està inicialitzant el punt de control... Si això triga massa, pots desactivar els punts de control a la configuració i reiniciar la teva tasca.", "menu": { "viewDiff": "Veure diferències", - "viewDiffFromInit": "Veure diferències amb el primer punt de control", - "viewDiffWithCurrent": "Veure diferències amb l'espai de treball actual", + "viewDiffFromInit": "Veure tots els canvis", + "viewDiffWithCurrent": "Veure els canvis des d'aquest punt de control", "restore": "Restaurar punt de control", "restoreFiles": "Restaurar arxius", "restoreFilesDescription": "Restaura els arxius del teu projecte a una instantània presa en aquest punt.", diff --git a/webview-ui/src/i18n/locales/de/chat.json b/webview-ui/src/i18n/locales/de/chat.json index 781caa6f8f28..2e39913f7d52 100644 --- a/webview-ui/src/i18n/locales/de/chat.json +++ b/webview-ui/src/i18n/locales/de/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Checkpoint wird noch initialisiert... Falls dies zu lange dauert, kannst du Checkpoints in den Einstellungen deaktivieren und deine Aufgabe neu starten.", "menu": { "viewDiff": "Unterschiede anzeigen", - "viewDiffFromInit": "Unterschiede mit erstem Checkpoint anzeigen", - "viewDiffWithCurrent": "Unterschiede mit aktuellem Workspace anzeigen", + "viewDiffFromInit": "Alle Änderungen anzeigen", + "viewDiffWithCurrent": "Änderungen seit diesem Checkpoint anzeigen", "restore": "Checkpoint wiederherstellen", "restoreFiles": "Dateien wiederherstellen", "restoreFilesDescription": "Stellt die Dateien deines Projekts auf einen Snapshot zurück, der an diesem Punkt erstellt wurde.", diff --git a/webview-ui/src/i18n/locales/en/chat.json b/webview-ui/src/i18n/locales/en/chat.json index b641d08cb3d2..52cd63d8d15b 100644 --- a/webview-ui/src/i18n/locales/en/chat.json +++ b/webview-ui/src/i18n/locales/en/chat.json @@ -154,8 +154,8 @@ "initializingWarning": "Still initializing checkpoint... If this takes too long, you can disable checkpoints in settings and restart your task.", "menu": { "viewDiff": "View Diff", - "viewDiffFromInit": "View Diff With First Checkpoint", - "viewDiffWithCurrent": "View Diff With Current Workspace", + "viewDiffFromInit": "View All Changes", + "viewDiffWithCurrent": "View Changes Since This Checkpoint", "restore": "Restore Checkpoint", "restoreFiles": "Restore Files", "restoreFilesDescription": "Restores your project's files back to a snapshot taken at this point.", diff --git a/webview-ui/src/i18n/locales/es/chat.json b/webview-ui/src/i18n/locales/es/chat.json index 1d226b209ece..864b9e120bf0 100644 --- a/webview-ui/src/i18n/locales/es/chat.json +++ b/webview-ui/src/i18n/locales/es/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Todavía inicializando el punto de control... Si esto tarda demasiado, puedes desactivar los puntos de control en la configuración y reiniciar tu tarea.", "menu": { "viewDiff": "Ver diferencias", - "viewDiffFromInit": "Ver diferencias con el primer punto de control", - "viewDiffWithCurrent": "Ver diferencias con el espacio de trabajo actual", + "viewDiffFromInit": "Ver todos los cambios", + "viewDiffWithCurrent": "Ver cambios desde este punto de control", "restore": "Restaurar punto de control", "restoreFiles": "Restaurar archivos", "restoreFilesDescription": "Restaura los archivos de tu proyecto a una instantánea tomada en este punto.", diff --git a/webview-ui/src/i18n/locales/fr/chat.json b/webview-ui/src/i18n/locales/fr/chat.json index 2fe245dced3e..447056f9840d 100644 --- a/webview-ui/src/i18n/locales/fr/chat.json +++ b/webview-ui/src/i18n/locales/fr/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Initialisation du point de contrôle en cours... Si cela prend trop de temps, tu peux désactiver les points de contrôle dans les paramètres et redémarrer ta tâche.", "menu": { "viewDiff": "Voir les différences", - "viewDiffFromInit": "Voir les différences avec le premier point de contrôle", - "viewDiffWithCurrent": "Voir les différences avec l'espace de travail actuel", + "viewDiffFromInit": "Voir toutes les modifications", + "viewDiffWithCurrent": "Voir les modifications depuis ce point de contrôle", "restore": "Restaurer le point de contrôle", "restoreFiles": "Restaurer les fichiers", "restoreFilesDescription": "Restaure les fichiers de votre projet à un instantané pris à ce moment.", diff --git a/webview-ui/src/i18n/locales/hi/chat.json b/webview-ui/src/i18n/locales/hi/chat.json index 2a37aa632a51..354e823e259d 100644 --- a/webview-ui/src/i18n/locales/hi/chat.json +++ b/webview-ui/src/i18n/locales/hi/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "चेकपॉइंट अभी भी आरंभ हो रहा है... अगर यह बहुत समय ले रहा है, तो आप सेटिंग्स में चेकपॉइंट को अक्षम कर सकते हैं और अपने कार्य को पुनः आरंभ कर सकते हैं।", "menu": { "viewDiff": "अंतर देखें", - "viewDiffFromInit": "पहले चेकपॉइंट के साथ अंतर देखें", - "viewDiffWithCurrent": "वर्तमान कार्यक्षेत्र के साथ अंतर देखें", + "viewDiffFromInit": "सभी परिवर्तन देखें", + "viewDiffWithCurrent": "इस चेकपॉइंट के बाद से परिवर्तन देखें", "restore": "चेकपॉइंट पुनर्स्थापित करें", "restoreFiles": "फ़ाइलें पुनर्स्थापित करें", "restoreFilesDescription": "आपके प्रोजेक्ट की फ़ाइलों को इस बिंदु पर लिए गए स्नैपशॉट पर पुनर्स्थापित करता है।", diff --git a/webview-ui/src/i18n/locales/id/chat.json b/webview-ui/src/i18n/locales/id/chat.json index a544768501b6..c808712269f8 100644 --- a/webview-ui/src/i18n/locales/id/chat.json +++ b/webview-ui/src/i18n/locales/id/chat.json @@ -157,8 +157,8 @@ "initializingWarning": "Masih menginisialisasi checkpoint... Jika ini terlalu lama, kamu bisa menonaktifkan checkpoint di pengaturan dan restart tugas.", "menu": { "viewDiff": "Lihat Diff", - "viewDiffFromInit": "Lihat Diff dengan Checkpoint Pertama", - "viewDiffWithCurrent": "Lihat Diff dengan Workspace Saat Ini", + "viewDiffFromInit": "Lihat Semua Perubahan", + "viewDiffWithCurrent": "Lihat Perubahan Sejak Checkpoint Ini", "restore": "Pulihkan Checkpoint", "restoreFiles": "Pulihkan File", "restoreFilesDescription": "Mengembalikan file proyek kamu ke snapshot yang diambil pada titik ini.", diff --git a/webview-ui/src/i18n/locales/it/chat.json b/webview-ui/src/i18n/locales/it/chat.json index db3116fab3d2..70a7f9ea23d3 100644 --- a/webview-ui/src/i18n/locales/it/chat.json +++ b/webview-ui/src/i18n/locales/it/chat.json @@ -151,8 +151,8 @@ "initializingWarning": "Inizializzazione del checkpoint in corso... Se questa operazione richiede troppo tempo, puoi disattivare i checkpoint nelle impostazioni e riavviare l'attività.", "menu": { "viewDiff": "Visualizza differenze", - "viewDiffFromInit": "Visualizza differenze dal primo checkpoint", - "viewDiffWithCurrent": "Visualizza differenze con l'area di lavoro attuale", + "viewDiffFromInit": "Visualizza tutte le modifiche", + "viewDiffWithCurrent": "Visualizza le modifiche da questo checkpoint", "restore": "Ripristina checkpoint", "restoreFiles": "Ripristina file", "restoreFilesDescription": "Ripristina i file del tuo progetto a uno snapshot catturato in questo punto.", diff --git a/webview-ui/src/i18n/locales/ja/chat.json b/webview-ui/src/i18n/locales/ja/chat.json index 5dd938d63a1d..fbbafa41355c 100644 --- a/webview-ui/src/i18n/locales/ja/chat.json +++ b/webview-ui/src/i18n/locales/ja/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "チェックポイントの初期化中... 時間がかかりすぎる場合は、設定でチェックポイントを無効にしてタスクを再開できます。", "menu": { "viewDiff": "差分を表示", - "viewDiffFromInit": "最初のチェックポイントとの差分を表示", - "viewDiffWithCurrent": "現在のワークスペースとの差分を表示", + "viewDiffFromInit": "すべての変更を表示", + "viewDiffWithCurrent": "このチェックポイント以降の変更を表示", "restore": "チェックポイントを復元", "restoreFiles": "ファイルを復元", "restoreFilesDescription": "この時点で撮影されたスナップショットにプロジェクトのファイルを復元します。", diff --git a/webview-ui/src/i18n/locales/ko/chat.json b/webview-ui/src/i18n/locales/ko/chat.json index bf2b27784e1d..d9d5c96b9466 100644 --- a/webview-ui/src/i18n/locales/ko/chat.json +++ b/webview-ui/src/i18n/locales/ko/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "체크포인트 초기화 중... 시간이 너무 오래 걸리면 설정에서 체크포인트를 비활성화하고 작업을 다시 시작할 수 있습니다.", "menu": { "viewDiff": "차이점 보기", - "viewDiffFromInit": "첫 번째 체크포인트와의 차이점 보기", - "viewDiffWithCurrent": "현재 워크스페이스와의 차이점 보기", + "viewDiffFromInit": "모든 변경 사항 보기", + "viewDiffWithCurrent": "이 체크포인트 이후 변경 사항 보기", "restore": "체크포인트 복원", "restoreFiles": "파일 복원", "restoreFilesDescription": "프로젝트 파일을 이 시점에 찍힌 스냅샷으로 복원합니다.", diff --git a/webview-ui/src/i18n/locales/nl/chat.json b/webview-ui/src/i18n/locales/nl/chat.json index 54a2cb23848f..83b7a18bcfdc 100644 --- a/webview-ui/src/i18n/locales/nl/chat.json +++ b/webview-ui/src/i18n/locales/nl/chat.json @@ -143,8 +143,8 @@ "initializingWarning": "Checkpoint wordt nog steeds geïnitialiseerd... Als dit te lang duurt, kun je checkpoints uitschakelen in de instellingen en je taak opnieuw starten.", "menu": { "viewDiff": "Bekijk verschil", - "viewDiffFromInit": "Bekijk verschil met eerste checkpoint", - "viewDiffWithCurrent": "Bekijk verschil met huidige werkruimte", + "viewDiffFromInit": "Bekijk alle wijzigingen", + "viewDiffWithCurrent": "Bekijk wijzigingen sinds dit checkpoint", "restore": "Herstel checkpoint", "restoreFiles": "Bestanden herstellen", "restoreFilesDescription": "Herstelt de bestanden van je project naar een momentopname die op dit punt is gemaakt.", diff --git a/webview-ui/src/i18n/locales/pl/chat.json b/webview-ui/src/i18n/locales/pl/chat.json index 241ebeb4e547..2a603be58edd 100644 --- a/webview-ui/src/i18n/locales/pl/chat.json +++ b/webview-ui/src/i18n/locales/pl/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Trwa inicjalizacja punktu kontrolnego... Jeśli to trwa zbyt długo, możesz wyłączyć punkty kontrolne w ustawieniach i uruchomić zadanie ponownie.", "menu": { "viewDiff": "Zobacz różnice", - "viewDiffFromInit": "Zobacz różnice z pierwszym punktem kontrolnym", - "viewDiffWithCurrent": "Zobacz różnice z bieżącym projektem", + "viewDiffFromInit": "Zobacz wszystkie zmiany", + "viewDiffWithCurrent": "Zobacz zmiany od tego punktu kontrolnego", "restore": "Przywróć punkt kontrolny", "restoreFiles": "Przywróć pliki", "restoreFilesDescription": "Przywraca pliki Twojego projektu do zrzutu wykonanego w tym punkcie.", diff --git a/webview-ui/src/i18n/locales/pt-BR/chat.json b/webview-ui/src/i18n/locales/pt-BR/chat.json index 01e727894bab..eec5f814b598 100644 --- a/webview-ui/src/i18n/locales/pt-BR/chat.json +++ b/webview-ui/src/i18n/locales/pt-BR/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Ainda inicializando ponto de verificação... Se isso demorar muito, você pode desativar os pontos de verificação nas configurações e reiniciar sua tarefa.", "menu": { "viewDiff": "Ver diferenças", - "viewDiffFromInit": "Ver diferenças com o primeiro ponto de verificação", - "viewDiffWithCurrent": "Ver diferenças com o espaço de trabalho atual", + "viewDiffFromInit": "Ver todas as alterações", + "viewDiffWithCurrent": "Ver alterações desde este ponto de verificação", "restore": "Restaurar ponto de verificação", "restoreFiles": "Restaurar arquivos", "restoreFilesDescription": "Restaura os arquivos do seu projeto para um snapshot feito neste ponto.", diff --git a/webview-ui/src/i18n/locales/ru/chat.json b/webview-ui/src/i18n/locales/ru/chat.json index 9e49ae19fe72..4dc3df726712 100644 --- a/webview-ui/src/i18n/locales/ru/chat.json +++ b/webview-ui/src/i18n/locales/ru/chat.json @@ -143,8 +143,8 @@ "initializingWarning": "Точка сохранения еще инициализируется... Если это занимает слишком много времени, вы можете отключить точки сохранения в настройках и перезапустить задачу.", "menu": { "viewDiff": "Просмотреть различия", - "viewDiffFromInit": "Просмотреть различия с первой точкой сохранения", - "viewDiffWithCurrent": "Просмотреть различия с текущим рабочим пространством", + "viewDiffFromInit": "Просмотреть все изменения", + "viewDiffWithCurrent": "Просмотреть изменения с этой точки сохранения", "restore": "Восстановить точку сохранения", "restoreFiles": "Восстановить файлы", "restoreFilesDescription": "Восстанавливает файлы вашего проекта до состояния на момент этой точки.", diff --git a/webview-ui/src/i18n/locales/tr/chat.json b/webview-ui/src/i18n/locales/tr/chat.json index 698feb6f46d6..d75780b94b24 100644 --- a/webview-ui/src/i18n/locales/tr/chat.json +++ b/webview-ui/src/i18n/locales/tr/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Kontrol noktası hala başlatılıyor... Bu çok uzun sürerse, ayarlar bölümünden kontrol noktalarını devre dışı bırakabilir ve görevinizi yeniden başlatabilirsiniz.", "menu": { "viewDiff": "Farkları Görüntüle", - "viewDiffFromInit": "İlk Kontrol Noktası ile Farkları Görüntüle", - "viewDiffWithCurrent": "Mevcut Çalışma Alanı ile Farkları Görüntüle", + "viewDiffFromInit": "Tüm Değişiklikleri Görüntüle", + "viewDiffWithCurrent": "Bu Kontrol Noktasından Bu Yana Değişiklikleri Görüntüle", "restore": "Kontrol Noktasını Geri Yükle", "restoreFiles": "Dosyaları Geri Yükle", "restoreFilesDescription": "Projenizin dosyalarını bu noktada alınan bir anlık görüntüye geri yükler.", diff --git a/webview-ui/src/i18n/locales/vi/chat.json b/webview-ui/src/i18n/locales/vi/chat.json index 9b9cec2ff59f..6208d78f894c 100644 --- a/webview-ui/src/i18n/locales/vi/chat.json +++ b/webview-ui/src/i18n/locales/vi/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "Đang khởi tạo điểm kiểm tra... Nếu quá trình này mất quá nhiều thời gian, bạn có thể vô hiệu hóa điểm kiểm tra trong cài đặt và khởi động lại tác vụ của bạn.", "menu": { "viewDiff": "Xem khác biệt", - "viewDiffFromInit": "Xem khác biệt với điểm kiểm tra đầu tiên", - "viewDiffWithCurrent": "Xem khác biệt với không gian làm việc hiện tại", + "viewDiffFromInit": "Xem tất cả các thay đổi", + "viewDiffWithCurrent": "Xem các thay đổi kể từ điểm kiểm tra này", "restore": "Khôi phục điểm kiểm tra", "restoreFiles": "Khôi phục tệp", "restoreFilesDescription": "Khôi phục các tệp dự án của bạn về bản chụp được thực hiện tại thời điểm này.", diff --git a/webview-ui/src/i18n/locales/zh-CN/chat.json b/webview-ui/src/i18n/locales/zh-CN/chat.json index b8026ce51cca..f642c48d7707 100644 --- a/webview-ui/src/i18n/locales/zh-CN/chat.json +++ b/webview-ui/src/i18n/locales/zh-CN/chat.json @@ -148,8 +148,8 @@ "initializingWarning": "正在初始化检查点...如果耗时过长,你可以在设置中禁用检查点并重新启动任务。", "menu": { "viewDiff": "查看差异", - "viewDiffFromInit": "与首个检查点对比差异", - "viewDiffWithCurrent": "与当前工作区对比差异", + "viewDiffFromInit": "查看所有更改", + "viewDiffWithCurrent": "查看自此检查点以来的更改", "restore": "恢复检查点", "restoreFiles": "恢复文件", "restoreFilesDescription": "将项目文件恢复到此检查点状态", diff --git a/webview-ui/src/i18n/locales/zh-TW/chat.json b/webview-ui/src/i18n/locales/zh-TW/chat.json index aeb18d6da33c..07ea2de7e131 100644 --- a/webview-ui/src/i18n/locales/zh-TW/chat.json +++ b/webview-ui/src/i18n/locales/zh-TW/chat.json @@ -154,8 +154,8 @@ "initializingWarning": "正在初始化檢查點... 如果耗時過長,您可以在設定中停用檢查點並重新啟動工作。", "menu": { "viewDiff": "檢視差異", - "viewDiffFromInit": "與第一個檢查點比較差異", - "viewDiffWithCurrent": "與目前工作區比較差異", + "viewDiffFromInit": "檢視所有變更", + "viewDiffWithCurrent": "檢視自此檢查點以來的變更", "restore": "還原檢查點", "restoreFiles": "還原檔案", "restoreFilesDescription": "將您的專案檔案還原到此時的快照。", From 4f2bb897ae9d7a888db4bfd032fbe93b2dd73fee Mon Sep 17 00:00:00 2001 From: daniel-lxs Date: Thu, 23 Oct 2025 17:06:42 -0500 Subject: [PATCH 10/12] fix: resolve linting errors and remove unused currentHash parameter --- webview-ui/src/components/chat/ChatRow.tsx | 1 - .../src/components/chat/checkpoints/CheckpointMenu.tsx | 3 +-- .../src/components/chat/checkpoints/CheckpointSaved.tsx | 7 ++++++- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/webview-ui/src/components/chat/ChatRow.tsx b/webview-ui/src/components/chat/ChatRow.tsx index 1b97c376f611..ed5257528fe1 100644 --- a/webview-ui/src/components/chat/ChatRow.tsx +++ b/webview-ui/src/components/chat/ChatRow.tsx @@ -16,7 +16,6 @@ import { findMatchingResourceOrTemplate } from "@src/utils/mcp" import { vscode } from "@src/utils/vscode" import { removeLeadingNonAlphanumeric } from "@src/utils/removeLeadingNonAlphanumeric" import { getLanguageFromPath } from "@src/utils/getLanguageFromPath" -import { Button } from "@src/components/ui" import { ToolUseBlock, ToolUseBlockHeader } from "../common/ToolUseBlock" import UpdateTodoListToolBlock from "./UpdateTodoListToolBlock" diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index d0434fb21d6b..d88c9fbe679c 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -11,7 +11,6 @@ import { Checkpoint } from "./schema" type CheckpointMenuBaseProps = { ts: number commitHash: string - currentHash?: string checkpoint: Checkpoint } type CheckpointMenuControlledProps = { @@ -22,7 +21,7 @@ type CheckpointMenuUncontrolledProps = { } type CheckpointMenuProps = CheckpointMenuBaseProps & (CheckpointMenuControlledProps | CheckpointMenuUncontrolledProps) -export const CheckpointMenu = ({ ts, commitHash, currentHash, checkpoint, onOpenChange }: CheckpointMenuProps) => { +export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: CheckpointMenuProps) => { const { t } = useTranslation() const [internalRestoreOpen, setInternalRestoreOpen] = useState(false) const [restoreConfirming, setRestoreIsConfirming] = useState(false) diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointSaved.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointSaved.tsx index 2748188de883..1bc510266622 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointSaved.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointSaved.tsx @@ -84,7 +84,12 @@ export const CheckpointSaved = ({ checkpoint, currentHash, ...props }: Checkpoin
- +
) From 4aa6ee5fd3f48a23e70884e4cab468e451178593 Mon Sep 17 00:00:00 2001 From: daniel-lxs Date: Thu, 23 Oct 2025 18:21:26 -0500 Subject: [PATCH 11/12] fix: address PR #8796 review comments - Add missing 'checkpoint.menu.more' translation key for accessibility - Add translation keys for checkpoint diff messages (no_first, no_previous, no_changes, diff_with_next, diff_since_first, diff_to_current) - Fix English wording: 'compared with' instead of 'compare with' - Fix naming inconsistency: rename setRestoreIsConfirming to setRestoreConfirming - Update tests to expect translation keys instead of hardcoded strings - All translations added to 18 supported languages --- src/core/checkpoints/__tests__/checkpoint.test.ts | 6 +++--- src/core/checkpoints/index.ts | 14 +++++++------- src/i18n/locales/ca/common.json | 6 ++++++ src/i18n/locales/de/common.json | 6 ++++++ src/i18n/locales/en/common.json | 6 ++++++ src/i18n/locales/es/common.json | 6 ++++++ src/i18n/locales/fr/common.json | 6 ++++++ src/i18n/locales/hi/common.json | 11 ++++++++--- src/i18n/locales/id/common.json | 6 ++++++ src/i18n/locales/it/common.json | 6 ++++++ src/i18n/locales/ja/common.json | 6 ++++++ src/i18n/locales/ko/common.json | 6 ++++++ src/i18n/locales/nl/common.json | 6 ++++++ src/i18n/locales/pl/common.json | 6 ++++++ src/i18n/locales/pt-BR/common.json | 6 ++++++ src/i18n/locales/ru/common.json | 6 ++++++ src/i18n/locales/tr/common.json | 6 ++++++ src/i18n/locales/vi/common.json | 6 ++++++ src/i18n/locales/zh-CN/common.json | 6 ++++++ src/i18n/locales/zh-TW/common.json | 6 ++++++ .../components/chat/checkpoints/CheckpointMenu.tsx | 10 +++++----- webview-ui/src/i18n/locales/ca/chat.json | 1 + webview-ui/src/i18n/locales/de/chat.json | 1 + webview-ui/src/i18n/locales/en/chat.json | 3 ++- webview-ui/src/i18n/locales/es/chat.json | 1 + webview-ui/src/i18n/locales/fr/chat.json | 1 + webview-ui/src/i18n/locales/hi/chat.json | 1 + webview-ui/src/i18n/locales/id/chat.json | 1 + webview-ui/src/i18n/locales/it/chat.json | 1 + webview-ui/src/i18n/locales/ja/chat.json | 1 + webview-ui/src/i18n/locales/ko/chat.json | 1 + webview-ui/src/i18n/locales/nl/chat.json | 1 + webview-ui/src/i18n/locales/pl/chat.json | 1 + webview-ui/src/i18n/locales/pt-BR/chat.json | 1 + webview-ui/src/i18n/locales/ru/chat.json | 1 + webview-ui/src/i18n/locales/tr/chat.json | 1 + webview-ui/src/i18n/locales/vi/chat.json | 1 + webview-ui/src/i18n/locales/zh-CN/chat.json | 1 + webview-ui/src/i18n/locales/zh-TW/chat.json | 1 + 39 files changed, 144 insertions(+), 19 deletions(-) diff --git a/src/core/checkpoints/__tests__/checkpoint.test.ts b/src/core/checkpoints/__tests__/checkpoint.test.ts index 250083a4ad3f..10ddc48146c4 100644 --- a/src/core/checkpoints/__tests__/checkpoint.test.ts +++ b/src/core/checkpoints/__tests__/checkpoint.test.ts @@ -304,7 +304,7 @@ describe("Checkpoint functionality", () => { }) expect(vscode.commands.executeCommand).toHaveBeenCalledWith( "vscode.changes", - "Changes to current workspace", + "errors.checkpoint_diff_to_current", expect.any(Array), ) }) @@ -329,7 +329,7 @@ describe("Checkpoint functionality", () => { }) expect(vscode.commands.executeCommand).toHaveBeenCalledWith( "vscode.changes", - "Changes compare with next checkpoint", + "errors.checkpoint_diff_with_next", expect.any(Array), ) }) @@ -364,7 +364,7 @@ describe("Checkpoint functionality", () => { mode: "to-current", }) - expect(vscode.window.showInformationMessage).toHaveBeenCalledWith("No changes found.") + expect(vscode.window.showInformationMessage).toHaveBeenCalledWith("errors.checkpoint_no_changes") expect(vscode.commands.executeCommand).not.toHaveBeenCalled() }) diff --git a/src/core/checkpoints/index.ts b/src/core/checkpoints/index.ts index 592f2cdd3ab9..ed084f62efd9 100644 --- a/src/core/checkpoints/index.ts +++ b/src/core/checkpoints/index.ts @@ -298,7 +298,7 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi const checkpoints = task.clineMessages.filter(({ say }) => say === "checkpoint_saved").map(({ text }) => text!) if (["from-init", "full"].includes(mode) && checkpoints.length < 1) { - vscode.window.showInformationMessage("No first checkpoint to compare.") + vscode.window.showInformationMessage(t("common:errors.checkpoint_no_first")) return } @@ -307,27 +307,27 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi case "checkpoint": fromHash = commitHash toHash = idx !== -1 && idx < checkpoints.length - 1 ? checkpoints[idx + 1] : undefined - title = "Changes compare with next checkpoint" + title = t("common:errors.checkpoint_diff_with_next") break case "from-init": fromHash = checkpoints[0] toHash = commitHash - title = "Changes since first checkpoint" + title = t("common:errors.checkpoint_diff_since_first") break case "to-current": fromHash = commitHash toHash = undefined - title = "Changes to current workspace" + title = t("common:errors.checkpoint_diff_to_current") break case "full": fromHash = checkpoints[0] toHash = undefined - title = "Changes since first checkpoint" + title = t("common:errors.checkpoint_diff_since_first") break } if (!fromHash) { - vscode.window.showInformationMessage("No previous checkpoint to compare.") + vscode.window.showInformationMessage(t("common:errors.checkpoint_no_previous")) return } @@ -335,7 +335,7 @@ export async function checkpointDiff(task: Task, { ts, previousCommitHash, commi const changes = await service.getDiff({ from: fromHash, to: toHash }) if (!changes?.length) { - vscode.window.showInformationMessage("No changes found.") + vscode.window.showInformationMessage(t("common:errors.checkpoint_no_changes")) return } diff --git a/src/i18n/locales/ca/common.json b/src/i18n/locales/ca/common.json index a1f528ef97d9..c71cf130ac7c 100644 --- a/src/i18n/locales/ca/common.json +++ b/src/i18n/locales/ca/common.json @@ -33,6 +33,12 @@ "checkpoint_timeout": "S'ha esgotat el temps en intentar restaurar el punt de control.", "checkpoint_failed": "Ha fallat la restauració del punt de control.", "git_not_installed": "Git és necessari per a la funció de punts de control. Si us plau, instal·la Git per activar els punts de control.", + "checkpoint_no_first": "No hi ha un primer punt de control per comparar.", + "checkpoint_no_previous": "No hi ha un punt de control anterior per comparar.", + "checkpoint_no_changes": "No s'han trobat canvis.", + "checkpoint_diff_with_next": "Canvis comparats amb el següent punt de control", + "checkpoint_diff_since_first": "Canvis des del primer punt de control", + "checkpoint_diff_to_current": "Canvis a l'espai de treball actual", "nested_git_repos_warning": "Els punts de control estan deshabilitats perquè s'ha detectat un repositori git niat a: {{path}}. Per utilitzar punts de control, si us plau elimina o reubica aquest repositori git niat.", "no_workspace": "Si us plau, obre primer una carpeta de projecte", "update_support_prompt": "Ha fallat l'actualització del missatge de suport", diff --git a/src/i18n/locales/de/common.json b/src/i18n/locales/de/common.json index dbd9452e6013..6ec9be0f5f60 100644 --- a/src/i18n/locales/de/common.json +++ b/src/i18n/locales/de/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Zeitüberschreitung beim Versuch, den Checkpoint wiederherzustellen.", "checkpoint_failed": "Fehler beim Wiederherstellen des Checkpoints.", "git_not_installed": "Git ist für die Checkpoint-Funktion erforderlich. Bitte installiere Git, um Checkpoints zu aktivieren.", + "checkpoint_no_first": "Kein erster Checkpoint zum Vergleich vorhanden.", + "checkpoint_no_previous": "Kein vorheriger Checkpoint zum Vergleich vorhanden.", + "checkpoint_no_changes": "Keine Änderungen gefunden.", + "checkpoint_diff_with_next": "Änderungen im Vergleich zum nächsten Checkpoint", + "checkpoint_diff_since_first": "Änderungen seit dem ersten Checkpoint", + "checkpoint_diff_to_current": "Änderungen am aktuellen Arbeitsbereich", "nested_git_repos_warning": "Checkpoints sind deaktiviert, da ein verschachteltes Git-Repository erkannt wurde unter: {{path}}. Um Checkpoints zu verwenden, entferne oder verschiebe bitte dieses verschachtelte Git-Repository.", "no_workspace": "Bitte öffne zuerst einen Projektordner", "update_support_prompt": "Fehler beim Aktualisieren der Support-Nachricht", diff --git a/src/i18n/locales/en/common.json b/src/i18n/locales/en/common.json index 3a613cc1c21f..784540e06f79 100644 --- a/src/i18n/locales/en/common.json +++ b/src/i18n/locales/en/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Timed out when attempting to restore checkpoint.", "checkpoint_failed": "Failed to restore checkpoint.", "git_not_installed": "Git is required for the checkpoints feature. Please install Git to enable checkpoints.", + "checkpoint_no_first": "No first checkpoint to compare.", + "checkpoint_no_previous": "No previous checkpoint to compare.", + "checkpoint_no_changes": "No changes found.", + "checkpoint_diff_with_next": "Changes compared with next checkpoint", + "checkpoint_diff_since_first": "Changes since first checkpoint", + "checkpoint_diff_to_current": "Changes to current workspace", "nested_git_repos_warning": "Checkpoints are disabled because a nested git repository was detected at: {{path}}. To use checkpoints, please remove or relocate this nested git repository.", "no_workspace": "Please open a project folder first", "update_support_prompt": "Failed to update support prompt", diff --git a/src/i18n/locales/es/common.json b/src/i18n/locales/es/common.json index 49dcfe98c5c2..ade6aa9c460e 100644 --- a/src/i18n/locales/es/common.json +++ b/src/i18n/locales/es/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Se agotó el tiempo al intentar restaurar el punto de control.", "checkpoint_failed": "Error al restaurar el punto de control.", "git_not_installed": "Git es necesario para la función de puntos de control. Por favor, instala Git para activar los puntos de control.", + "checkpoint_no_first": "No hay primer punto de control para comparar.", + "checkpoint_no_previous": "No hay punto de control anterior para comparar.", + "checkpoint_no_changes": "No se encontraron cambios.", + "checkpoint_diff_with_next": "Cambios comparados con el siguiente punto de control", + "checkpoint_diff_since_first": "Cambios desde el primer punto de control", + "checkpoint_diff_to_current": "Cambios en el espacio de trabajo actual", "nested_git_repos_warning": "Los puntos de control están deshabilitados porque se detectó un repositorio git anidado en: {{path}}. Para usar puntos de control, por favor elimina o reubica este repositorio git anidado.", "no_workspace": "Por favor, abre primero una carpeta de proyecto", "update_support_prompt": "Error al actualizar el mensaje de soporte", diff --git a/src/i18n/locales/fr/common.json b/src/i18n/locales/fr/common.json index 260bbbf13bb1..dc06e0ca7a53 100644 --- a/src/i18n/locales/fr/common.json +++ b/src/i18n/locales/fr/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Expiration du délai lors de la tentative de rétablissement du checkpoint.", "checkpoint_failed": "Échec du rétablissement du checkpoint.", "git_not_installed": "Git est requis pour la fonctionnalité des points de contrôle. Veuillez installer Git pour activer les points de contrôle.", + "checkpoint_no_first": "Aucun premier point de contrôle à comparer.", + "checkpoint_no_previous": "Aucun point de contrôle précédent à comparer.", + "checkpoint_no_changes": "Aucun changement trouvé.", + "checkpoint_diff_with_next": "Modifications comparées au prochain point de contrôle", + "checkpoint_diff_since_first": "Modifications depuis le premier point de contrôle", + "checkpoint_diff_to_current": "Modifications de l'espace de travail actuel", "nested_git_repos_warning": "Les points de contrôle sont désactivés car un dépôt git imbriqué a été détecté à : {{path}}. Pour utiliser les points de contrôle, veuillez supprimer ou déplacer ce dépôt git imbriqué.", "no_workspace": "Veuillez d'abord ouvrir un espace de travail", "update_support_prompt": "Erreur lors de la mise à jour du prompt de support", diff --git a/src/i18n/locales/hi/common.json b/src/i18n/locales/hi/common.json index ab7d594e8f7d..14da25805b1e 100644 --- a/src/i18n/locales/hi/common.json +++ b/src/i18n/locales/hi/common.json @@ -28,7 +28,13 @@ "could_not_open_file_generic": "फ़ाइल नहीं खोली जा सकी!", "checkpoint_timeout": "चेकपॉइंट को पुनर्स्थापित करने का प्रयास करते समय टाइमआउट हो गया।", "checkpoint_failed": "चेकपॉइंट पुनर्स्थापित करने में विफल।", - "git_not_installed": "चेकपॉइंट सुविधा के लिए Git आवश्यक है। कृपया चेकपॉइंट সক্ষম करने के लिए Git इंस्टॉल करें।", + "git_not_installed": "चेकपॉइंट सुविधा के लिए Git आवश्यक है। कृपया चेकपॉइंट सक्षम करने के लिए Git इंस्टॉल करें।", + "checkpoint_no_first": "तुलना करने के लिए कोई पहला चेकपॉइंट नहीं है।", + "checkpoint_no_previous": "तुलना करने के लिए कोई पिछला चेकपॉइंट नहीं है।", + "checkpoint_no_changes": "कोई बदलाव नहीं मिला।", + "checkpoint_diff_with_next": "अगले चेकपॉइंट के साथ तुलना किए गए बदलाव", + "checkpoint_diff_since_first": "पहले चेकपॉइंट के बाद से बदलाव", + "checkpoint_diff_to_current": "वर्तमान कार्यक्षेत्र में बदलाव", "nested_git_repos_warning": "चेकपॉइंट अक्षम हैं क्योंकि {{path}} पर नेस्टेड git रिपॉजिटरी का पता चला है। चेकपॉइंट का उपयोग करने के लिए, कृपया इस नेस्टेड git रिपॉजिटरी को हटाएं या स्थानांतरित करें।", "no_workspace": "कृपया पहले प्रोजेक्ट फ़ोल्डर खोलें", "update_support_prompt": "सपोर्ट प्रॉम्प्ट अपडेट करने में विफल", @@ -181,8 +187,7 @@ "getGroqApiKey": "ग्रोक एपीआई कुंजी प्राप्त करें", "claudeCode": { "pathLabel": "क्लाउड कोड पाथ", - "description": "आपके क्लाउड कोड CLI का वैकल्पिक पाथ। सेट न होने पर डिफ़ॉल्ट रूप से 'claude'।", - "placeholder": "डिफ़ॉल्ट: claude" + "description": "आपके क्लाउड कोड CLI का वैकल्पिक पाथ। सेट न होने पर डिफ़ॉल्ट रूप से 'claude'।" } } }, diff --git a/src/i18n/locales/id/common.json b/src/i18n/locales/id/common.json index ddd549b6f00e..5622d722159d 100644 --- a/src/i18n/locales/id/common.json +++ b/src/i18n/locales/id/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Timeout saat mencoba memulihkan checkpoint.", "checkpoint_failed": "Gagal memulihkan checkpoint.", "git_not_installed": "Git diperlukan untuk fitur checkpoint. Silakan instal Git untuk mengaktifkan checkpoint.", + "checkpoint_no_first": "Tidak ada checkpoint pertama untuk dibandingkan.", + "checkpoint_no_previous": "Tidak ada checkpoint sebelumnya untuk dibandingkan.", + "checkpoint_no_changes": "Tidak ada perubahan yang ditemukan.", + "checkpoint_diff_with_next": "Perubahan dibandingkan dengan checkpoint berikutnya", + "checkpoint_diff_since_first": "Perubahan sejak checkpoint pertama", + "checkpoint_diff_to_current": "Perubahan ke ruang kerja saat ini", "nested_git_repos_warning": "Checkpoint dinonaktifkan karena repositori git bersarang terdeteksi di: {{path}}. Untuk menggunakan checkpoint, silakan hapus atau pindahkan repositori git bersarang ini.", "no_workspace": "Silakan buka folder proyek terlebih dahulu", "update_support_prompt": "Gagal memperbarui support prompt", diff --git a/src/i18n/locales/it/common.json b/src/i18n/locales/it/common.json index 80e8e0633b16..abb22d77d371 100644 --- a/src/i18n/locales/it/common.json +++ b/src/i18n/locales/it/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Timeout durante il tentativo di ripristinare il checkpoint.", "checkpoint_failed": "Impossibile ripristinare il checkpoint.", "git_not_installed": "Git è richiesto per la funzione di checkpoint. Per favore, installa Git per abilitare i checkpoint.", + "checkpoint_no_first": "Nessun primo checkpoint da confrontare.", + "checkpoint_no_previous": "Nessun checkpoint precedente da confrontare.", + "checkpoint_no_changes": "Nessuna modifica trovata.", + "checkpoint_diff_with_next": "Modifiche confrontate con il checkpoint successivo", + "checkpoint_diff_since_first": "Modifiche dal primo checkpoint", + "checkpoint_diff_to_current": "Modifiche all'area di lavoro corrente", "nested_git_repos_warning": "I checkpoint sono disabilitati perché è stato rilevato un repository git annidato in: {{path}}. Per utilizzare i checkpoint, rimuovi o sposta questo repository git annidato.", "no_workspace": "Per favore, apri prima una cartella di progetto", "update_support_prompt": "Errore durante l'aggiornamento del messaggio di supporto", diff --git a/src/i18n/locales/ja/common.json b/src/i18n/locales/ja/common.json index accba790a2a0..cdd8de9a9a99 100644 --- a/src/i18n/locales/ja/common.json +++ b/src/i18n/locales/ja/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "チェックポイントの復元を試みる際にタイムアウトしました。", "checkpoint_failed": "チェックポイントの復元に失敗しました。", "git_not_installed": "チェックポイント機能にはGitが必要です。チェックポイントを有効にするにはGitをインストールしてください。", + "checkpoint_no_first": "比較する最初のチェックポイントがありません。", + "checkpoint_no_previous": "比較する前のチェックポイントがありません。", + "checkpoint_no_changes": "変更は見つかりませんでした。", + "checkpoint_diff_with_next": "次のチェックポイントと比較した変更点", + "checkpoint_diff_since_first": "最初のチェックポイントからの変更点", + "checkpoint_diff_to_current": "現在のワークスペースへの変更点", "nested_git_repos_warning": "{{path}} でネストされたgitリポジトリが検出されたため、チェックポイントが無効になっています。チェックポイントを使用するには、このネストされたgitリポジトリを削除または移動してください。", "no_workspace": "まずプロジェクトフォルダを開いてください", "update_support_prompt": "サポートメッセージの更新に失敗しました", diff --git a/src/i18n/locales/ko/common.json b/src/i18n/locales/ko/common.json index acb7bd47d7c6..0cbfc9d99ada 100644 --- a/src/i18n/locales/ko/common.json +++ b/src/i18n/locales/ko/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "체크포인트 복원을 시도하는 중 시간 초과되었습니다.", "checkpoint_failed": "체크포인트 복원에 실패했습니다.", "git_not_installed": "체크포인트 기능을 사용하려면 Git이 필요합니다. 체크포인트를 활성화하려면 Git을 설치하세요.", + "checkpoint_no_first": "비교할 첫 번째 체크포인트가 없습니다.", + "checkpoint_no_previous": "비교할 이전 체크포인트가 없습니다.", + "checkpoint_no_changes": "변경된 내용이 없습니다.", + "checkpoint_diff_with_next": "다음 체크포인트와 비교한 변경 사항", + "checkpoint_diff_since_first": "첫 번째 체크포인트 이후의 변경 사항", + "checkpoint_diff_to_current": "현재 작업 공간으로의 변경 사항", "nested_git_repos_warning": "{{path}}에서 중첩된 git 저장소가 감지되어 체크포인트가 비활성화되었습니다. 체크포인트를 사용하려면 이 중첩된 git 저장소를 제거하거나 이동해주세요.", "no_workspace": "먼저 프로젝트 폴더를 열어주세요", "update_support_prompt": "지원 프롬프트 업데이트에 실패했습니다", diff --git a/src/i18n/locales/nl/common.json b/src/i18n/locales/nl/common.json index d43690c43524..c989219e7b44 100644 --- a/src/i18n/locales/nl/common.json +++ b/src/i18n/locales/nl/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Time-out bij het herstellen van checkpoint.", "checkpoint_failed": "Herstellen van checkpoint mislukt.", "git_not_installed": "Git is vereist voor de checkpoint-functie. Installeer Git om checkpoints in te schakelen.", + "checkpoint_no_first": "Geen eerste checkpoint om mee te vergelijken.", + "checkpoint_no_previous": "Geen vorig checkpoint om mee te vergelijken.", + "checkpoint_no_changes": "Geen wijzigingen gevonden.", + "checkpoint_diff_with_next": "Wijzigingen vergeleken met volgend checkpoint", + "checkpoint_diff_since_first": "Wijzigingen sinds eerste checkpoint", + "checkpoint_diff_to_current": "Wijzigingen in huidige werkruimte", "nested_git_repos_warning": "Checkpoints zijn uitgeschakeld omdat een geneste git-repository is gedetecteerd op: {{path}}. Om checkpoints te gebruiken, verwijder of verplaats deze geneste git-repository.", "no_workspace": "Open eerst een projectmap", "update_support_prompt": "Bijwerken van ondersteuningsprompt mislukt", diff --git a/src/i18n/locales/pl/common.json b/src/i18n/locales/pl/common.json index 56c076f785a3..3a1c08cf60b9 100644 --- a/src/i18n/locales/pl/common.json +++ b/src/i18n/locales/pl/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Upłynął limit czasu podczas próby przywrócenia punktu kontrolnego.", "checkpoint_failed": "Nie udało się przywrócić punktu kontrolnego.", "git_not_installed": "Funkcja punktów kontrolnych wymaga oprogramowania Git. Zainstaluj Git, aby włączyć punkty kontrolne.", + "checkpoint_no_first": "Brak pierwszego punktu kontrolnego do porównania.", + "checkpoint_no_previous": "Brak poprzedniego punktu kontrolnego do porównania.", + "checkpoint_no_changes": "Nie znaleziono zmian.", + "checkpoint_diff_with_next": "Zmiany w porównaniu z następnym punktem kontrolnym", + "checkpoint_diff_since_first": "Zmiany od pierwszego punktu kontrolnego", + "checkpoint_diff_to_current": "Zmiany w bieżącym obszarze roboczym", "nested_git_repos_warning": "Punkty kontrolne są wyłączone, ponieważ wykryto zagnieżdżone repozytorium git w: {{path}}. Aby używać punktów kontrolnych, usuń lub przenieś to zagnieżdżone repozytorium git.", "no_workspace": "Najpierw otwórz folder projektu", "update_support_prompt": "Nie udało się zaktualizować komunikatu wsparcia", diff --git a/src/i18n/locales/pt-BR/common.json b/src/i18n/locales/pt-BR/common.json index c2cd63255f03..d8782623b845 100644 --- a/src/i18n/locales/pt-BR/common.json +++ b/src/i18n/locales/pt-BR/common.json @@ -33,6 +33,12 @@ "checkpoint_timeout": "Tempo esgotado ao tentar restaurar o ponto de verificação.", "checkpoint_failed": "Falha ao restaurar o ponto de verificação.", "git_not_installed": "O Git é necessário para o recurso de checkpoints. Por favor, instale o Git para habilitar os checkpoints.", + "checkpoint_no_first": "Nenhum primeiro ponto de verificação para comparar.", + "checkpoint_no_previous": "Nenhum ponto de verificação anterior para comparar.", + "checkpoint_no_changes": "Nenhuma alteração encontrada.", + "checkpoint_diff_with_next": "Alterações comparadas com o próximo ponto de verificação", + "checkpoint_diff_since_first": "Alterações desde o primeiro ponto de verificação", + "checkpoint_diff_to_current": "Alterações no espaço de trabalho atual", "nested_git_repos_warning": "Os checkpoints estão desabilitados porque um repositório git aninhado foi detectado em: {{path}}. Para usar checkpoints, por favor remova ou realoque este repositório git aninhado.", "no_workspace": "Por favor, abra primeiro uma pasta de projeto", "update_support_prompt": "Falha ao atualizar o prompt de suporte", diff --git a/src/i18n/locales/ru/common.json b/src/i18n/locales/ru/common.json index 9595f1f2768c..d8004676385e 100644 --- a/src/i18n/locales/ru/common.json +++ b/src/i18n/locales/ru/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Превышено время ожидания при попытке восстановления контрольной точки.", "checkpoint_failed": "Не удалось восстановить контрольную точку.", "git_not_installed": "Для функции контрольных точек требуется Git. Пожалуйста, установите Git, чтобы включить контрольные точки.", + "checkpoint_no_first": "Нет первой контрольной точки для сравнения.", + "checkpoint_no_previous": "Нет предыдущей контрольной точки для сравнения.", + "checkpoint_no_changes": "Изменений не найдено.", + "checkpoint_diff_with_next": "Изменения по сравнению со следующей контрольной точкой", + "checkpoint_diff_since_first": "Изменения с первой контрольной точки", + "checkpoint_diff_to_current": "Изменения в текущем рабочем пространстве", "nested_git_repos_warning": "Контрольные точки отключены, поскольку обнаружен вложенный git-репозиторий в: {{path}}. Чтобы использовать контрольные точки, пожалуйста, удалите или переместите этот вложенный git-репозиторий.", "no_workspace": "Пожалуйста, сначала откройте папку проекта", "update_support_prompt": "Не удалось обновить промпт поддержки", diff --git a/src/i18n/locales/tr/common.json b/src/i18n/locales/tr/common.json index aa11041110dd..f163a5df8341 100644 --- a/src/i18n/locales/tr/common.json +++ b/src/i18n/locales/tr/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Kontrol noktasını geri yüklemeye çalışırken zaman aşımına uğradı.", "checkpoint_failed": "Kontrol noktası geri yüklenemedi.", "git_not_installed": "Kontrol noktaları özelliği için Git gereklidir. Kontrol noktalarını etkinleştirmek için lütfen Git'i yükleyin.", + "checkpoint_no_first": "Karşılaştırılacak ilk kontrol noktası yok.", + "checkpoint_no_previous": "Karşılaştırılacak önceki kontrol noktası yok.", + "checkpoint_no_changes": "Değişiklik bulunamadı.", + "checkpoint_diff_with_next": "Sonraki kontrol noktasıyla karşılaştırılan değişiklikler", + "checkpoint_diff_since_first": "İlk kontrol noktasından bu yana yapılan değişiklikler", + "checkpoint_diff_to_current": "Mevcut çalışma alanındaki değişiklikler", "nested_git_repos_warning": "{{path}} konumunda iç içe git deposu tespit edildiği için kontrol noktaları devre dışı bırakıldı. Kontrol noktalarını kullanmak için lütfen bu iç içe git deposunu kaldırın veya taşıyın.", "no_workspace": "Lütfen önce bir proje klasörü açın", "update_support_prompt": "Destek istemi güncellenemedi", diff --git a/src/i18n/locales/vi/common.json b/src/i18n/locales/vi/common.json index b4b92b373e29..47ed3c03977e 100644 --- a/src/i18n/locales/vi/common.json +++ b/src/i18n/locales/vi/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "Đã hết thời gian khi cố gắng khôi phục điểm kiểm tra.", "checkpoint_failed": "Không thể khôi phục điểm kiểm tra.", "git_not_installed": "Yêu cầu Git cho tính năng điểm kiểm tra. Vui lòng cài đặt Git để bật điểm kiểm tra.", + "checkpoint_no_first": "Không có điểm kiểm tra đầu tiên để so sánh.", + "checkpoint_no_previous": "Không có điểm kiểm tra trước đó để so sánh.", + "checkpoint_no_changes": "Không tìm thấy thay đổi.", + "checkpoint_diff_with_next": "Các thay đổi được so sánh với điểm kiểm tra tiếp theo", + "checkpoint_diff_since_first": "Các thay đổi kể từ điểm kiểm tra đầu tiên", + "checkpoint_diff_to_current": "Các thay đổi đối với không gian làm việc hiện tại", "nested_git_repos_warning": "Điểm kiểm tra bị vô hiệu hóa vì phát hiện kho git lồng nhau tại: {{path}}. Để sử dụng điểm kiểm tra, vui lòng xóa hoặc di chuyển kho git lồng nhau này.", "no_workspace": "Vui lòng mở thư mục dự án trước", "update_support_prompt": "Không thể cập nhật lời nhắc hỗ trợ", diff --git a/src/i18n/locales/zh-CN/common.json b/src/i18n/locales/zh-CN/common.json index 8c427444847f..81a2d70c3023 100644 --- a/src/i18n/locales/zh-CN/common.json +++ b/src/i18n/locales/zh-CN/common.json @@ -34,6 +34,12 @@ "checkpoint_timeout": "尝试恢复检查点时超时。", "checkpoint_failed": "恢复检查点失败。", "git_not_installed": "存档点功能需要 Git。请安装 Git 以启用存档点。", + "checkpoint_no_first": "没有第一个存档点可供比较。", + "checkpoint_no_previous": "没有上一个存档点可供比较。", + "checkpoint_no_changes": "未发现任何更改。", + "checkpoint_diff_with_next": "与下一个存档点比较的更改", + "checkpoint_diff_since_first": "自第一个存档点以来的更改", + "checkpoint_diff_to_current": "对当前工作区的更改", "nested_git_repos_warning": "存档点已禁用,因为在 {{path}} 检测到嵌套的 git 仓库。要使用存档点,请移除或重新定位此嵌套的 git 仓库。", "no_workspace": "请先打开项目文件夹", "update_support_prompt": "更新支持消息失败", diff --git a/src/i18n/locales/zh-TW/common.json b/src/i18n/locales/zh-TW/common.json index 5a31d601b4cf..a72163495a2e 100644 --- a/src/i18n/locales/zh-TW/common.json +++ b/src/i18n/locales/zh-TW/common.json @@ -29,6 +29,12 @@ "checkpoint_timeout": "嘗試恢復檢查點時超時。", "checkpoint_failed": "恢復檢查點失敗。", "git_not_installed": "存檔點功能需要 Git。請安裝 Git 以啟用存檔點。", + "checkpoint_no_first": "沒有第一個存檔點可供比較。", + "checkpoint_no_previous": "沒有上一個存檔點可供比較。", + "checkpoint_no_changes": "未發現任何變更。", + "checkpoint_diff_with_next": "與下一個存檔點比較的變更", + "checkpoint_diff_since_first": "自第一個存檔點以來的變更", + "checkpoint_diff_to_current": "對目前工作區的變更", "nested_git_repos_warning": "存檔點已停用,因為在 {{path}} 偵測到巢狀的 git 儲存庫。要使用存檔點,請移除或重新配置此巢狀的 git 儲存庫。", "no_workspace": "請先開啟專案資料夾", "update_support_prompt": "更新支援訊息失敗", diff --git a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx index d88c9fbe679c..22802cd45535 100644 --- a/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx +++ b/webview-ui/src/components/chat/checkpoints/CheckpointMenu.tsx @@ -24,7 +24,7 @@ type CheckpointMenuProps = CheckpointMenuBaseProps & (CheckpointMenuControlledPr export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: CheckpointMenuProps) => { const { t } = useTranslation() const [internalRestoreOpen, setInternalRestoreOpen] = useState(false) - const [restoreConfirming, setRestoreIsConfirming] = useState(false) + const [restoreConfirming, setRestoreConfirming] = useState(false) const [internalMoreOpen, setInternalMoreOpen] = useState(false) const portalContainer = useRooPortal("roo-portal") @@ -87,7 +87,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: Che (open: boolean) => { setRestoreOpen(open) if (!open) { - setRestoreIsConfirming(false) + setRestoreConfirming(false) } }, [setRestoreOpen], @@ -104,7 +104,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: Che open={restoreOpen} onOpenChange={(open) => { handleOpenChange(open) - setRestoreIsConfirming(false) + setRestoreConfirming(false) }} data-testid="restore-popover"> @@ -128,7 +128,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: Che {!restoreConfirming ? ( @@ -144,7 +144,7 @@ export const CheckpointMenu = ({ ts, commitHash, checkpoint, onOpenChange }: Che
{t("chat:checkpoint.menu.confirm")}
-