From d088ddab5903bab923579894d4ca8838ededb1e3 Mon Sep 17 00:00:00 2001 From: aheizi Date: Wed, 12 Mar 2025 23:23:43 +0800 Subject: [PATCH 01/10] batch clear history --- src/core/webview/ClineProvider.ts | 9 + src/shared/WebviewMessage.ts | 2 + .../history/BatchDeleteTaskDialog.tsx | 58 +++ .../src/components/history/HistoryView.tsx | 469 +++++++++++------- 4 files changed, 362 insertions(+), 176 deletions(-) create mode 100644 webview-ui/src/components/history/BatchDeleteTaskDialog.tsx diff --git a/src/core/webview/ClineProvider.ts b/src/core/webview/ClineProvider.ts index b82a6a62e01..4dee9d3c84a 100644 --- a/src/core/webview/ClineProvider.ts +++ b/src/core/webview/ClineProvider.ts @@ -1020,6 +1020,15 @@ export class ClineProvider implements vscode.WebviewViewProvider { case "deleteTaskWithId": this.deleteTaskWithId(message.text!) break + case "deleteMultipleTasksWithIds": { + const ids = message.ids + if (Array.isArray(ids)) { + for (const id of ids) { + await this.deleteTaskWithId(id) + } + } + break + } case "exportTaskWithId": this.exportTaskWithId(message.text!) break diff --git a/src/shared/WebviewMessage.ts b/src/shared/WebviewMessage.ts index 724d7e5983b..146130c19d6 100644 --- a/src/shared/WebviewMessage.ts +++ b/src/shared/WebviewMessage.ts @@ -11,6 +11,7 @@ export type AudioType = "notification" | "celebration" | "progress_loop" export interface WebviewMessage { type: | "apiConfiguration" + | "deleteMultipleTasksWithIds" | "currentApiConfigName" | "saveApiConfiguration" | "upsertApiConfiguration" @@ -126,6 +127,7 @@ export interface WebviewMessage { payload?: WebViewMessagePayload source?: "global" | "project" requestId?: string + ids?: string[] } // Human relay related message types diff --git a/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx new file mode 100644 index 00000000000..a27f1bb701f --- /dev/null +++ b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx @@ -0,0 +1,58 @@ +import { useCallback } from "react" +import { + AlertDialog, + AlertDialogAction, + AlertDialogCancel, + AlertDialogContent, + AlertDialogDescription, + AlertDialogFooter, + AlertDialogHeader, + AlertDialogTitle, + Button, +} from "@/components/ui" +import { vscode } from "@/utils/vscode" +import { AlertDialogProps } from "@radix-ui/react-alert-dialog" + +interface BatchDeleteTaskDialogProps extends AlertDialogProps { + taskIds: string[] +} + +export const BatchDeleteTaskDialog = ({ taskIds, ...props }: BatchDeleteTaskDialogProps) => { + const { onOpenChange } = props + + const onDelete = useCallback(() => { + if (taskIds.length > 0) { + vscode.postMessage({ type: "deleteMultipleTasksWithIds", ids: taskIds }) + onOpenChange?.(false) + } + }, [taskIds, onOpenChange]) + + return ( + + + + Delete Tasks + +
+ Are you sure you want to delete {taskIds.length} selected tasks? +
+
+ This action cannot be undone. All selected tasks will be permanently deleted. +
+
+
+ + + + + + + + +
+
+ ) +} diff --git a/webview-ui/src/components/history/HistoryView.tsx b/webview-ui/src/components/history/HistoryView.tsx index e65a11a3ec5..b3bc5b2913a 100644 --- a/webview-ui/src/components/history/HistoryView.tsx +++ b/webview-ui/src/components/history/HistoryView.tsx @@ -1,8 +1,15 @@ import React, { memo, useState } from "react" import { DeleteTaskDialog } from "./DeleteTaskDialog" +import { BatchDeleteTaskDialog } from "./BatchDeleteTaskDialog" import prettyBytes from "pretty-bytes" import { Virtuoso } from "react-virtuoso" -import { VSCodeButton, VSCodeTextField, VSCodeRadioGroup, VSCodeRadio } from "@vscode/webview-ui-toolkit/react" +import { + VSCodeButton, + VSCodeTextField, + VSCodeRadioGroup, + VSCodeRadio, + VSCodeCheckbox, +} from "@vscode/webview-ui-toolkit/react" import { vscode } from "@/utils/vscode" import { formatLargeNumber, formatDate } from "@/utils/format" @@ -23,13 +30,60 @@ const HistoryView = ({ onDone }: HistoryViewProps) => { const { tasks, searchQuery, setSearchQuery, sortOption, setSortOption, setLastNonRelevantSort } = useTaskSearch() const [deleteTaskId, setDeleteTaskId] = useState(null) + const [isSelectionMode, setIsSelectionMode] = useState(false) + const [selectedTaskIds, setSelectedTaskIds] = useState([]) + const [showBatchDeleteDialog, setShowBatchDeleteDialog] = useState(false) + + // Toggle selection mode + const toggleSelectionMode = () => { + setIsSelectionMode(!isSelectionMode) + if (isSelectionMode) { + setSelectedTaskIds([]) + } + } + + // Toggle selection for a single task + const toggleTaskSelection = (taskId: string, isSelected: boolean) => { + if (isSelected) { + setSelectedTaskIds((prev) => [...prev, taskId]) + } else { + setSelectedTaskIds((prev) => prev.filter((id) => id !== taskId)) + } + } + + // Toggle select all tasks + const toggleSelectAll = (selectAll: boolean) => { + if (selectAll) { + setSelectedTaskIds(tasks.map((task) => task.id)) + } else { + setSelectedTaskIds([]) + } + } + + // Handle batch delete button click + const handleBatchDelete = () => { + if (selectedTaskIds.length > 0) { + setShowBatchDeleteDialog(true) + } + } return (

History

- Done +
+ + + {isSelectionMode ? "Exit Selection" : "Selection Mode"} + + Done +
{ Most Relevant + + {/* Select all control in selection mode */} + {isSelectionMode && tasks.length > 0 && ( +
+ 0 && selectedTaskIds.length === tasks.length} + onChange={(e) => toggleSelectAll((e.target as HTMLInputElement).checked)} + /> + + {selectedTaskIds.length === tasks.length ? "Deselect All" : "Select All"} + + + Selected {selectedTaskIds.length}/{tasks.length} items + +
+ )}
@@ -101,221 +171,268 @@ const HistoryView = ({ onDone }: HistoryViewProps) => { key={item.id} className={cn("cursor-pointer", { "border-b border-vscode-panel-border": index < tasks.length - 1, + "bg-vscode-list-activeSelectionBackground": + isSelectionMode && selectedTaskIds.includes(item.id), })} - onClick={() => vscode.postMessage({ type: "showTaskWithId", text: item.id })}> -
-
- { + if (!isSelectionMode || !(e.target as HTMLElement).closest(".task-checkbox")) { + vscode.postMessage({ type: "showTaskWithId", text: item.id }) + } + }}> +
+ {/* Show checkbox in selection mode */} + {isSelectionMode && ( +
{ + e.stopPropagation() }}> - {formatDate(item.ts)} - -
-
+ )} - if (e.shiftKey) { - vscode.postMessage({ type: "deleteTaskWithId", text: item.id }) - } else { - setDeleteTaskId(item.id) - } - }}> - - {item.size && prettyBytes(item.size)} - +
+
+ + {formatDate(item.ts)} + +
+ {!isSelectionMode && ( + + )} +
-
-
-
+ fontSize: "var(--vscode-font-size)", + color: "var(--vscode-foreground)", + display: "-webkit-box", + WebkitLineClamp: 3, + WebkitBoxOrient: "vertical", + overflow: "hidden", + whiteSpace: "pre-wrap", + wordBreak: "break-word", + overflowWrap: "anywhere", + }} + dangerouslySetInnerHTML={{ __html: item.task }} + /> +
- - Tokens: - - - - {formatLargeNumber(item.tokensIn || 0)} - - - + Tokens: + + - {formatLargeNumber(item.tokensOut || 0)} - -
- {!item.totalCost && ( -
- - + display: "flex", + alignItems: "center", + gap: "3px", + color: "var(--vscode-descriptionForeground)", + }}> + + {formatLargeNumber(item.tokensIn || 0)} + + + + {formatLargeNumber(item.tokensOut || 0)} +
- )} -
+ {!item.totalCost && !isSelectionMode && ( +
+ + +
+ )} +
- {!!item.cacheWrites && ( -
- - Cache: - - - - +{formatLargeNumber(item.cacheWrites || 0)} - - - - {formatLargeNumber(item.cacheReads || 0)} - -
- )} - - {!!item.totalCost && ( -
-
- API Cost: + Cache: + + + + +{formatLargeNumber(item.cacheWrites || 0)} - - ${item.totalCost?.toFixed(4)} + + + {formatLargeNumber(item.cacheReads || 0)}
-
- - + )} + + {!!item.totalCost && ( +
+
+ + API Cost: + + + ${item.totalCost?.toFixed(4)} + +
+ {!isSelectionMode && ( +
+ + +
+ )}
-
- )} + )} +
)} />
+ + {/* Fixed action bar at bottom - only shown in selection mode with selected items */} + {isSelectionMode && selectedTaskIds.length > 0 && ( +
+
+ Selected {selectedTaskIds.length} items +
+
+ setSelectedTaskIds([])}> + Clear Selection + + + Delete Selected + +
+
+ )} + + {/* Delete dialog */} {deleteTaskId && ( !open && setDeleteTaskId(null)} open /> )} + + {/* Batch delete dialog */} + {showBatchDeleteDialog && ( + { + if (!open) { + setShowBatchDeleteDialog(false) + setSelectedTaskIds([]) + setIsSelectionMode(false) + } + }} + /> + )}
) } From 21e07578323f34aa7c0e16ed4e59ec6325f3d246 Mon Sep 17 00:00:00 2001 From: aheizi Date: Thu, 13 Mar 2025 17:38:19 +0800 Subject: [PATCH 02/10] catch Task not found error --- src/core/webview/ClineProvider.ts | 70 +++++++++++++++++-------------- 1 file changed, 39 insertions(+), 31 deletions(-) diff --git a/src/core/webview/ClineProvider.ts b/src/core/webview/ClineProvider.ts index ef6a17e0c9f..8ac65c6e67a 100644 --- a/src/core/webview/ClineProvider.ts +++ b/src/core/webview/ClineProvider.ts @@ -2271,43 +2271,51 @@ export class ClineProvider implements vscode.WebviewViewProvider { // this function deletes a task from task hidtory, and deletes it's checkpoints and delete the task folder async deleteTaskWithId(id: string) { - // get the task directory full path - const { taskDirPath } = await this.getTaskWithId(id) - - // remove task from stack if it's the current task - if (id === this.getCurrentCline()?.taskId) { - // if we found the taskid to delete - call finish to abort this task and allow a new task to be started, - // if we are deleting a subtask and parent task is still waiting for subtask to finish - it allows the parent to resume (this case should neve exist) - await this.finishSubTask(`Task failure: It was stopped and deleted by the user.`) - } + try { + // Try to get the task directory full path + const { taskDirPath } = await this.getTaskWithId(id) + + // remove task from stack if it's the current task + if (id === this.getCurrentCline()?.taskId) { + // if we found the taskid to delete - call finish to abort this task and allow a new task to be started, + // if we are deleting a subtask and parent task is still waiting for subtask to finish - it allows the parent to resume (this case should neve exist) + await this.finishSubTask(`Task failure: It was stopped and deleted by the user.`) + } - // delete task from the task history state - await this.deleteTaskFromState(id) + // delete task from the task history state + await this.deleteTaskFromState(id) - // get the base directory of the project - const baseDir = vscode.workspace.workspaceFolders?.map((folder) => folder.uri.fsPath).at(0) + // get the base directory of the project + const baseDir = vscode.workspace.workspaceFolders?.map((folder) => folder.uri.fsPath).at(0) - // Delete associated shadow repository or branch. - // TODO: Store `workspaceDir` in the `HistoryItem` object. - const globalStorageDir = this.contextProxy.globalStorageUri.fsPath - const workspaceDir = baseDir ?? "" + // Delete associated shadow repository or branch. + const globalStorageDir = this.contextProxy.globalStorageUri.fsPath + const workspaceDir = baseDir ?? "" - try { - await ShadowCheckpointService.deleteTask({ taskId: id, globalStorageDir, workspaceDir }) - } catch (error) { - console.error( - `[deleteTaskWithId${id}] failed to delete associated shadow repository or branch: ${error instanceof Error ? error.message : String(error)}`, - ) - } + try { + await ShadowCheckpointService.deleteTask({ taskId: id, globalStorageDir, workspaceDir }) + } catch (error) { + console.error( + `[deleteTaskWithId${id}] failed to delete associated shadow repository or branch: ${error instanceof Error ? error.message : String(error)}`, + ) + } - // delete the entire task directory including checkpoints and all content - try { - await fs.rm(taskDirPath, { recursive: true, force: true }) - console.log(`[deleteTaskWithId${id}] removed task directory`) + // delete the entire task directory including checkpoints and all content + try { + await fs.rm(taskDirPath, { recursive: true, force: true }) + console.log(`[deleteTaskWithId${id}] removed task directory`) + } catch (error) { + console.error( + `[deleteTaskWithId${id}] failed to remove task directory: ${error instanceof Error ? error.message : String(error)}`, + ) + } } catch (error) { - console.error( - `[deleteTaskWithId${id}] failed to remove task directory: ${error instanceof Error ? error.message : String(error)}`, - ) + // If task is not found, just remove it from state + if (error instanceof Error && error.message === "Task not found") { + await this.deleteTaskFromState(id) + return + } + throw error } } From 98c6f67c956e8a953626f49d3baa0b9a0dd988a7 Mon Sep 17 00:00:00 2001 From: aheizi Date: Sun, 16 Mar 2025 12:32:38 +0800 Subject: [PATCH 03/10] fix deleteMultipleTasksWithIds --- src/core/webview/ClineProvider.ts | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/src/core/webview/ClineProvider.ts b/src/core/webview/ClineProvider.ts index 298850bed8e..b1a46d61490 100644 --- a/src/core/webview/ClineProvider.ts +++ b/src/core/webview/ClineProvider.ts @@ -977,9 +977,20 @@ export class ClineProvider implements vscode.WebviewViewProvider { case "deleteMultipleTasksWithIds": { const ids = message.ids if (Array.isArray(ids)) { - for (const id of ids) { - await this.deleteTaskWithId(id) - } + const deletePromises = ids.map(async (id) => { + try { + await this.deleteTaskWithId(id) + return { id, success: true } + } catch (error) { + this.outputChannel.appendLine( + `Failed to delete task ${id}: ${error instanceof Error ? error.message : String(error)}`, + ) + return { id, success: false } + } + }) + + await Promise.all(deletePromises) + await this.postStateToWebview() } break } From aba0ac8b40439df8d11041a3faba876a833f182e Mon Sep 17 00:00:00 2001 From: aheizi Date: Sun, 16 Mar 2025 15:09:11 +0800 Subject: [PATCH 04/10] add i18n for batch clear history --- .../history/BatchDeleteTaskDialog.tsx | 14 ++++++------- .../src/components/history/HistoryView.tsx | 20 ++++++++++++------- .../src/i18n/__mocks__/TranslationContext.tsx | 17 ++++++++++++++++ webview-ui/src/i18n/locales/ar/common.json | 3 ++- webview-ui/src/i18n/locales/ar/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/ca/common.json | 3 ++- webview-ui/src/i18n/locales/ca/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/cs/common.json | 3 ++- webview-ui/src/i18n/locales/cs/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/de/common.json | 3 ++- webview-ui/src/i18n/locales/de/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/en/common.json | 3 ++- webview-ui/src/i18n/locales/en/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/es/common.json | 3 ++- webview-ui/src/i18n/locales/es/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/fr/common.json | 3 ++- webview-ui/src/i18n/locales/fr/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/hi/common.json | 3 ++- webview-ui/src/i18n/locales/hi/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/hu/common.json | 3 ++- webview-ui/src/i18n/locales/hu/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/it/common.json | 3 ++- webview-ui/src/i18n/locales/it/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/ja/common.json | 3 ++- webview-ui/src/i18n/locales/ja/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/ko/common.json | 3 ++- webview-ui/src/i18n/locales/ko/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/pl/common.json | 3 ++- webview-ui/src/i18n/locales/pl/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/pt-BR/common.json | 3 ++- .../src/i18n/locales/pt-BR/history.json | 11 +++++++++- webview-ui/src/i18n/locales/pt/common.json | 3 ++- webview-ui/src/i18n/locales/pt/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/ru/common.json | 3 ++- webview-ui/src/i18n/locales/ru/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/tr/common.json | 3 ++- webview-ui/src/i18n/locales/tr/history.json | 11 +++++++++- webview-ui/src/i18n/locales/zh-CN/common.json | 3 ++- .../src/i18n/locales/zh-CN/history.json | 15 +++++++++++++- webview-ui/src/i18n/locales/zh-TW/common.json | 3 ++- .../src/i18n/locales/zh-TW/history.json | 15 +++++++++++++- 41 files changed, 333 insertions(+), 52 deletions(-) diff --git a/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx index a27f1bb701f..20aa40e1d5b 100644 --- a/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx +++ b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx @@ -1,4 +1,5 @@ import { useCallback } from "react" +import { useAppTranslation } from "@/i18n/TranslationContext" import { AlertDialog, AlertDialogAction, @@ -18,6 +19,7 @@ interface BatchDeleteTaskDialogProps extends AlertDialogProps { } export const BatchDeleteTaskDialog = ({ taskIds, ...props }: BatchDeleteTaskDialogProps) => { + const { t } = useAppTranslation() const { onOpenChange } = props const onDelete = useCallback(() => { @@ -31,24 +33,22 @@ export const BatchDeleteTaskDialog = ({ taskIds, ...props }: BatchDeleteTaskDial - Delete Tasks + {t("history:deleteTasks")} -
- Are you sure you want to delete {taskIds.length} selected tasks? -
+
{t("history:confirmDeleteTasks", { count: taskIds.length })}
- This action cannot be undone. All selected tasks will be permanently deleted. + {t("history:deleteTasksWarning")}
- + diff --git a/webview-ui/src/components/history/HistoryView.tsx b/webview-ui/src/components/history/HistoryView.tsx index 58b55655ecb..cd024410485 100644 --- a/webview-ui/src/components/history/HistoryView.tsx +++ b/webview-ui/src/components/history/HistoryView.tsx @@ -79,11 +79,15 @@ const HistoryView = ({ onDone }: HistoryViewProps) => { + title={ + isSelectionMode + ? `${t("history:exitSelectionMode")}` + : `${t("history:enterSelectionMode")}` + }> - {isSelectionMode ? "Exit Selection" : "Selection Mode"} + {isSelectionMode ? t("history:exitSelection") : t("history:selectionMode")} {t("history:done")}
@@ -146,10 +150,12 @@ const HistoryView = ({ onDone }: HistoryViewProps) => { onChange={(e) => toggleSelectAll((e.target as HTMLInputElement).checked)} /> - {selectedTaskIds.length === tasks.length ? "Deselect All" : "Select All"} + {selectedTaskIds.length === tasks.length + ? t("history:deselectAll") + : t("history:selectAll")} - Selected {selectedTaskIds.length}/{tasks.length} items + {t("history:selectedItems", { selected: selectedTaskIds.length, total: tasks.length })}
)} @@ -405,14 +411,14 @@ const HistoryView = ({ onDone }: HistoryViewProps) => { {isSelectionMode && selectedTaskIds.length > 0 && (
- Selected {selectedTaskIds.length} items + {t("history:selectedItems", { selected: selectedTaskIds.length, total: tasks.length })}
setSelectedTaskIds([])}> - Clear Selection + {t("history:clearSelection")} - Delete Selected + {t("history:deleteSelected")}
diff --git a/webview-ui/src/i18n/__mocks__/TranslationContext.tsx b/webview-ui/src/i18n/__mocks__/TranslationContext.tsx index f2b2305593d..e587c7779ee 100644 --- a/webview-ui/src/i18n/__mocks__/TranslationContext.tsx +++ b/webview-ui/src/i18n/__mocks__/TranslationContext.tsx @@ -5,10 +5,14 @@ export const useAppTranslation = () => { return { t: (key: string, options?: Record) => { const translations: Record = { + // Common translations + "common:cancel": "Cancel", // History translations "history:recentTasks": "Recent Tasks", "history:viewAll": "View All", "history:history": "History", + "history:exitSelectionMode": "Exit Selection Mode", + "history:enterSelectionMode": "Enter Selection Mode", "history:done": "Done", "history:searchPlaceholder": "Fuzzy search history...", "history:newest": "Newest", @@ -26,6 +30,19 @@ export const useAppTranslation = () => { "history:deleteTaskMessage": "Are you sure you want to delete this task? This action cannot be undone.", "history:cancel": "Cancel", "history:delete": "Delete", + "history:exitSelection": "Exit Selection", + "history:selectionMode": "Selection Mode", + "history:deselectAll": "Deselect All", + "history:selectAll": "Select All", + "history:selectedItems": "Selected {selected}/{total} items", + "history:clearSelection": "Clear Selection", + "history:deleteSelected": "Delete Selected", + "history:deleteTasks": "Delete Tasks", + "history:confirmDeleteTasks": + "Are you sure you want to delete {count} tasks? This action cannot be undone.", + "history:deleteTasksWarning": + "Deleted tasks cannot be recovered. Please make sure you want to proceed.", + "history:deleteItems": "Delete {count} Items", } // Handle interpolation diff --git a/webview-ui/src/i18n/locales/ar/common.json b/webview-ui/src/i18n/locales/ar/common.json index 212235bd90a..7d34670087b 100644 --- a/webview-ui/src/i18n/locales/ar/common.json +++ b/webview-ui/src/i18n/locales/ar/common.json @@ -4,5 +4,6 @@ "changeSettings": "يمكنك دائمًا تغيير هذا في أسفل الإعدادات", "settings": "الإعدادات", "allow": "السماح", - "deny": "رفض" + "deny": "رفض", + "cancel": "إلغاء" } diff --git a/webview-ui/src/i18n/locales/ar/history.json b/webview-ui/src/i18n/locales/ar/history.json index e0f854d4d7b..b19b8198e71 100644 --- a/webview-ui/src/i18n/locales/ar/history.json +++ b/webview-ui/src/i18n/locales/ar/history.json @@ -5,6 +5,8 @@ "cache": "التخزين المؤقت: +{{writes}} → {{reads}}", "apiCost": "تكلفة API: ${{cost}}", "history": "السجل", + "exitSelectionMode": "الخروج من وضع التحديد", + "enterSelectionMode": "الدخول إلى وضع التحديد", "done": "تم", "searchPlaceholder": "البحث في السجل...", "newest": "الأحدث", @@ -21,5 +23,16 @@ "deleteTask": "حذف المهمة", "deleteTaskMessage": "هل أنت متأكد من حذف هذه المهمة؟ لا يمكن التراجع عن هذا الإجراء.", "cancel": "إلغاء", - "delete": "حذف" + "delete": "حذف", + "exitSelection": "الخروج من التحديد", + "selectionMode": "وضع التحديد", + "deselectAll": "إلغاء تحديد الكل", + "selectAll": "تحديد الكل", + "selectedItems": "تم تحديد {{selected}}/{{total}} عنصر", + "clearSelection": "مسح التحديد", + "deleteSelected": "حذف المحدد", + "deleteTasks": "حذف المهام", + "confirmDeleteTasks": "هل أنت متأكد من حذف {{count}} مهمة؟", + "deleteTasksWarning": "لا يمكن استعادة المهام المحذوفة. يرجى التأكد من المتابعة.", + "deleteItems": "حذف {{count}} عنصر" } diff --git a/webview-ui/src/i18n/locales/ca/common.json b/webview-ui/src/i18n/locales/ca/common.json index 3674fd8a8ef..c70e2f5da32 100644 --- a/webview-ui/src/i18n/locales/ca/common.json +++ b/webview-ui/src/i18n/locales/ca/common.json @@ -4,5 +4,6 @@ "changeSettings": "Sempre pots canviar això a la part inferior de la configuració", "settings": "configuració", "allow": "Permetre", - "deny": "Denegar" + "deny": "Denegar", + "cancel": "Cancel·lar" } diff --git a/webview-ui/src/i18n/locales/ca/history.json b/webview-ui/src/i18n/locales/ca/history.json index 385f54a3637..4add5f9611b 100644 --- a/webview-ui/src/i18n/locales/ca/history.json +++ b/webview-ui/src/i18n/locales/ca/history.json @@ -5,6 +5,8 @@ "cache": "Cau: +{{writes}} → {{reads}}", "apiCost": "Cost d'API: ${{cost}}", "history": "Historial", + "exitSelectionMode": "Sortir del mode de selecció", + "enterSelectionMode": "Entrar en mode de selecció", "done": "Fet", "searchPlaceholder": "Cerca a l'historial...", "newest": "Més recents", @@ -21,5 +23,16 @@ "deleteTask": "Eliminar tasca", "deleteTaskMessage": "Estàs segur que vols eliminar aquesta tasca? Aquesta acció no es pot desfer.", "cancel": "Cancel·lar", - "delete": "Eliminar" + "delete": "Eliminar", + "exitSelection": "Sortir de la selecció", + "selectionMode": "Mode de selecció", + "deselectAll": "Desseleccionar tot", + "selectAll": "Seleccionar tot", + "selectedItems": "{{selected}}/{{total}} elements seleccionats", + "clearSelection": "Netejar selecció", + "deleteSelected": "Eliminar seleccionats", + "deleteTasks": "Eliminar tasques", + "confirmDeleteTasks": "Estàs segur que vols eliminar {{count}} tasques?", + "deleteTasksWarning": "Les tasques eliminades no es poden recuperar. Si us plau, assegura't que vols continuar.", + "deleteItems": "Eliminar {{count}} elements" } diff --git a/webview-ui/src/i18n/locales/cs/common.json b/webview-ui/src/i18n/locales/cs/common.json index 1ab32ff19ba..52a6c60cf73 100644 --- a/webview-ui/src/i18n/locales/cs/common.json +++ b/webview-ui/src/i18n/locales/cs/common.json @@ -4,5 +4,6 @@ "changeSettings": "Toto nastavení můžete vždy změnit v dolní části nastavení", "settings": "nastavení", "allow": "Povolit", - "deny": "Zakázat" + "deny": "Zakázat", + "cancel": "Zrušit" } diff --git a/webview-ui/src/i18n/locales/cs/history.json b/webview-ui/src/i18n/locales/cs/history.json index c6e4638c6f5..d497dd500c6 100644 --- a/webview-ui/src/i18n/locales/cs/history.json +++ b/webview-ui/src/i18n/locales/cs/history.json @@ -5,6 +5,8 @@ "cache": "Mezipaměť: +{{writes}} → {{reads}}", "apiCost": "Náklady API: ${{cost}}", "history": "Historie", + "exitSelectionMode": "Ukončit režim výběru", + "enterSelectionMode": "Spustit režim výběru", "done": "Hotovo", "searchPlaceholder": "Vyhledat v historii...", "newest": "Nejnovější", @@ -21,5 +23,16 @@ "deleteTask": "Smazat úkol", "deleteTaskMessage": "Opravdu chcete smazat tento úkol? Tuto akci nelze vrátit zpět.", "cancel": "Zrušit", - "delete": "Smazat" + "delete": "Smazat", + "exitSelection": "Ukončit výběr", + "selectionMode": "Režim výběru", + "deselectAll": "Zrušit výběr všech", + "selectAll": "Vybrat vše", + "selectedItems": "Vybráno {{selected}}/{{total}} položek", + "clearSelection": "Vyčistit výběr", + "deleteSelected": "Smazat vybrané", + "deleteTasks": "Smazat úkoly", + "confirmDeleteTasks": "Opravdu chcete smazat {{count}} úkolů?", + "deleteTasksWarning": "Smazané úkoly nelze obnovit. Prosím, ujistěte se, že chcete pokračovat.", + "deleteItems": "Smazat {{count}} položek" } diff --git a/webview-ui/src/i18n/locales/de/common.json b/webview-ui/src/i18n/locales/de/common.json index fefcc867526..182307d1417 100644 --- a/webview-ui/src/i18n/locales/de/common.json +++ b/webview-ui/src/i18n/locales/de/common.json @@ -4,5 +4,6 @@ "changeSettings": "Sie können dies jederzeit unten in den Einstellungen ändern", "settings": "Einstellungen", "allow": "Erlauben", - "deny": "Ablehnen" + "deny": "Ablehnen", + "cancel": "Abbrechen" } diff --git a/webview-ui/src/i18n/locales/de/history.json b/webview-ui/src/i18n/locales/de/history.json index 58f9dc90f4b..a63c9dc5c1e 100644 --- a/webview-ui/src/i18n/locales/de/history.json +++ b/webview-ui/src/i18n/locales/de/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "API-Kosten: ${{cost}}", "history": "Verlauf", + "exitSelectionMode": "Auswahlmodus beenden", + "enterSelectionMode": "Auswahlmodus starten", "done": "Fertig", "searchPlaceholder": "Verlauf durchsuchen...", "newest": "Neueste", @@ -21,5 +23,16 @@ "deleteTask": "Aufgabe löschen", "deleteTaskMessage": "Sind Sie sicher, dass Sie diese Aufgabe löschen möchten? Diese Aktion kann nicht rückgängig gemacht werden.", "cancel": "Abbrechen", - "delete": "Löschen" + "delete": "Löschen", + "exitSelection": "Auswahl beenden", + "selectionMode": "Auswahlmodus", + "deselectAll": "Alle abwählen", + "selectAll": "Alle auswählen", + "selectedItems": "{{selected}}/{{total}} Elemente ausgewählt", + "clearSelection": "Auswahl aufheben", + "deleteSelected": "Ausgewählte löschen", + "deleteTasks": "Aufgaben löschen", + "confirmDeleteTasks": "Sind Sie sicher, dass Sie {{count}} Aufgaben löschen möchten?", + "deleteTasksWarning": "Gelöschte Aufgaben können nicht wiederhergestellt werden. Bitte vergewissern Sie sich, dass Sie fortfahren möchten.", + "deleteItems": "{{count}} Elemente löschen" } diff --git a/webview-ui/src/i18n/locales/en/common.json b/webview-ui/src/i18n/locales/en/common.json index f09807becc7..99eeb619df2 100644 --- a/webview-ui/src/i18n/locales/en/common.json +++ b/webview-ui/src/i18n/locales/en/common.json @@ -4,5 +4,6 @@ "changeSettings": "You can always change this at the bottom of the settings", "settings": "settings", "allow": "Allow", - "deny": "Deny" + "deny": "Deny", + "cancel": "Cancel" } diff --git a/webview-ui/src/i18n/locales/en/history.json b/webview-ui/src/i18n/locales/en/history.json index 56a48884d93..4c664ca6084 100644 --- a/webview-ui/src/i18n/locales/en/history.json +++ b/webview-ui/src/i18n/locales/en/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "API Cost: ${{cost}}", "history": "History", + "exitSelectionMode": "Exit Selection Mode", + "enterSelectionMode": "Enter Selection Mode", "done": "Done", "searchPlaceholder": "Fuzzy search history...", "newest": "Newest", @@ -21,5 +23,16 @@ "deleteTask": "Delete Task", "deleteTaskMessage": "Are you sure you want to delete this task? This action cannot be undone.", "cancel": "Cancel", - "delete": "Delete" + "delete": "Delete", + "exitSelection": "Exit Selection", + "selectionMode": "Selection Mode", + "deselectAll": "Deselect All", + "selectAll": "Select All", + "selectedItems": "Selected {{selected}}/{{total}} items", + "clearSelection": "Clear Selection", + "deleteSelected": "Delete Selected", + "deleteTasks": "Delete Tasks", + "confirmDeleteTasks": "Are you sure you want to delete {{count}} tasks?", + "deleteTasksWarning": "Deleted tasks cannot be recovered. Please make sure you want to proceed.", + "deleteItems": "Delete {{count}} Items" } diff --git a/webview-ui/src/i18n/locales/es/common.json b/webview-ui/src/i18n/locales/es/common.json index 18c3d9998cd..4aed5befdc0 100644 --- a/webview-ui/src/i18n/locales/es/common.json +++ b/webview-ui/src/i18n/locales/es/common.json @@ -4,5 +4,6 @@ "changeSettings": "Siempre puedes cambiar esto en la parte inferior de la configuración", "settings": "configuración", "allow": "Permitir", - "deny": "Denegar" + "deny": "Denegar", + "cancel": "Cancelar" } diff --git a/webview-ui/src/i18n/locales/es/history.json b/webview-ui/src/i18n/locales/es/history.json index 011a100fefc..482f488b50e 100644 --- a/webview-ui/src/i18n/locales/es/history.json +++ b/webview-ui/src/i18n/locales/es/history.json @@ -5,6 +5,8 @@ "cache": "Caché: +{{writes}} → {{reads}}", "apiCost": "Costo de API: ${{cost}}", "history": "Historial", + "exitSelectionMode": "Salir del modo selección", + "enterSelectionMode": "Entrar en modo selección", "done": "Listo", "searchPlaceholder": "Buscar en el historial...", "newest": "Más recientes", @@ -21,5 +23,16 @@ "deleteTask": "Eliminar tarea", "deleteTaskMessage": "¿Estás seguro de que quieres eliminar esta tarea? Esta acción no se puede deshacer.", "cancel": "Cancelar", - "delete": "Eliminar" + "delete": "Eliminar", + "exitSelection": "Salir de la selección", + "selectionMode": "Modo selección", + "deselectAll": "Deseleccionar todo", + "selectAll": "Seleccionar todo", + "selectedItems": "{{selected}}/{{total}} elementos seleccionados", + "clearSelection": "Limpiar selección", + "deleteSelected": "Eliminar seleccionados", + "deleteTasks": "Eliminar tareas", + "confirmDeleteTasks": "¿Estás seguro de que quieres eliminar {{count}} tareas?", + "deleteTasksWarning": "Las tareas eliminadas no se pueden recuperar. Por favor, asegúrate de que quieres continuar.", + "deleteItems": "Eliminar {{count}} elementos" } diff --git a/webview-ui/src/i18n/locales/fr/common.json b/webview-ui/src/i18n/locales/fr/common.json index e12844ff751..646f6248e36 100644 --- a/webview-ui/src/i18n/locales/fr/common.json +++ b/webview-ui/src/i18n/locales/fr/common.json @@ -4,5 +4,6 @@ "changeSettings": "Vous pouvez toujours modifier cela en bas des paramètres", "settings": "paramètres", "allow": "Autoriser", - "deny": "Refuser" + "deny": "Refuser", + "cancel": "Annuler" } diff --git a/webview-ui/src/i18n/locales/fr/history.json b/webview-ui/src/i18n/locales/fr/history.json index 367cb473423..15fcd601c68 100644 --- a/webview-ui/src/i18n/locales/fr/history.json +++ b/webview-ui/src/i18n/locales/fr/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "Coût API: ${{cost}}", "history": "Historique", + "exitSelectionMode": "Quitter le mode sélection", + "enterSelectionMode": "Entrer en mode sélection", "done": "Terminé", "searchPlaceholder": "Rechercher dans l'historique...", "newest": "Plus récentes", @@ -21,5 +23,16 @@ "deleteTask": "Supprimer la tâche", "deleteTaskMessage": "Êtes-vous sûr de vouloir supprimer cette tâche ? Cette action ne peut pas être annulée.", "cancel": "Annuler", - "delete": "Supprimer" + "delete": "Supprimer", + "exitSelection": "Quitter la sélection", + "selectionMode": "Mode sélection", + "deselectAll": "Tout désélectionner", + "selectAll": "Tout sélectionner", + "selectedItems": "{{selected}}/{{total}} éléments sélectionnés", + "clearSelection": "Effacer la sélection", + "deleteSelected": "Supprimer les éléments sélectionnés", + "deleteTasks": "Supprimer les tâches", + "confirmDeleteTasks": "Êtes-vous sûr de vouloir supprimer {{count}} tâches ?", + "deleteTasksWarning": "Les tâches supprimées ne peuvent pas être récupérées. Veuillez confirmer que vous souhaitez continuer.", + "deleteItems": "Supprimer {{count}} éléments" } diff --git a/webview-ui/src/i18n/locales/hi/common.json b/webview-ui/src/i18n/locales/hi/common.json index b36b70146ac..93284d0a9bc 100644 --- a/webview-ui/src/i18n/locales/hi/common.json +++ b/webview-ui/src/i18n/locales/hi/common.json @@ -4,5 +4,6 @@ "changeSettings": "आप इसे हमेशा सेटिंग्स के निचले भाग में बदल सकते हैं", "settings": "सेटिंग्स", "allow": "अनुमति दें", - "deny": "अस्वीकार करें" + "deny": "अस्वीकार करें", + "cancel": "रद्द करें" } diff --git a/webview-ui/src/i18n/locales/hi/history.json b/webview-ui/src/i18n/locales/hi/history.json index faed6b78f6a..222e0940e95 100644 --- a/webview-ui/src/i18n/locales/hi/history.json +++ b/webview-ui/src/i18n/locales/hi/history.json @@ -5,6 +5,8 @@ "cache": "कैश: +{{writes}} → {{reads}}", "apiCost": "API लागत: ${{cost}}", "history": "इतिहास", + "exitSelectionMode": "चयन मोड से बाहर निकलें", + "enterSelectionMode": "चयन मोड में प्रवेश करें", "done": "पूर्ण", "searchPlaceholder": "इतिहास खोजें...", "newest": "नवीनतम", @@ -21,5 +23,16 @@ "deleteTask": "कार्य हटाएं", "deleteTaskMessage": "क्या आप वाकई इस कार्य को हटाना चाहते हैं? यह क्रिया पूर्ववत नहीं की जा सकती है।", "cancel": "रद्द करें", - "delete": "हटाएं" + "delete": "हटाएं", + "exitSelection": "चयन से बाहर निकलें", + "selectionMode": "चयन मोड", + "deselectAll": "सभी चयन हटाएं", + "selectAll": "सभी चुनें", + "selectedItems": "{{selected}}/{{total}} आइटम चयनित", + "clearSelection": "चयन साफ़ करें", + "deleteSelected": "चयनित हटाएं", + "deleteTasks": "कार्य हटाएं", + "confirmDeleteTasks": "क्या आप वाकई {{count}} कार्य हटाना चाहते हैं?", + "deleteTasksWarning": "हटाए गए कार्य पुनर्प्राप्त नहीं किए जा सकते। कृपया सुनिश्चित करें कि आप आगे बढ़ना चाहते हैं।", + "deleteItems": "{{count}} आइटम हटाएं" } diff --git a/webview-ui/src/i18n/locales/hu/common.json b/webview-ui/src/i18n/locales/hu/common.json index 9f111a85c72..04d0addae9a 100644 --- a/webview-ui/src/i18n/locales/hu/common.json +++ b/webview-ui/src/i18n/locales/hu/common.json @@ -4,5 +4,6 @@ "changeSettings": "Ezt bármikor megváltoztathatod a beállítások alján", "settings": "beállítások", "allow": "Engedélyez", - "deny": "Elutasít" + "deny": "Elutasít", + "cancel": "Mégse" } diff --git a/webview-ui/src/i18n/locales/hu/history.json b/webview-ui/src/i18n/locales/hu/history.json index 0893191622b..d5c7c37f7e1 100644 --- a/webview-ui/src/i18n/locales/hu/history.json +++ b/webview-ui/src/i18n/locales/hu/history.json @@ -5,6 +5,8 @@ "cache": "Gyorsítótár: +{{writes}} → {{reads}}", "apiCost": "API költség: ${{cost}}", "history": "Előzmények", + "exitSelectionMode": "Kijelölési mód bezárása", + "enterSelectionMode": "Kijelölési mód megnyitása", "done": "Kész", "searchPlaceholder": "Előzmények keresése...", "newest": "Legújabb", @@ -21,5 +23,16 @@ "deleteTask": "Feladat törlése", "deleteTaskMessage": "Biztosan törölni szeretné ezt a feladatot? Ez a művelet nem vonható vissza.", "cancel": "Mégsem", - "delete": "Törlés" + "delete": "Törlés", + "exitSelection": "Kijelölésből kilépés", + "selectionMode": "Kijelölési mód", + "deselectAll": "Összes kijelölés megszüntetése", + "selectAll": "Összes kijelölése", + "selectedItems": "{{selected}}/{{total}} elem kijelölve", + "clearSelection": "Kijelölés törlése", + "deleteSelected": "Kijelöltek törlése", + "deleteTasks": "Feladatok törlése", + "confirmDeleteTasks": "Biztosan törölni szeretne {{count}} feladatot?", + "deleteTasksWarning": "A törölt feladatok nem állíthatók helyre. Kérjük, győződjön meg arról, hogy folytatni kívánja.", + "deleteItems": "{{count}} elem törlése" } diff --git a/webview-ui/src/i18n/locales/it/common.json b/webview-ui/src/i18n/locales/it/common.json index 5dc0034356a..037d85ae984 100644 --- a/webview-ui/src/i18n/locales/it/common.json +++ b/webview-ui/src/i18n/locales/it/common.json @@ -4,5 +4,6 @@ "changeSettings": "Puoi sempre cambiare questo in fondo alle impostazioni", "settings": "impostazioni", "allow": "Consenti", - "deny": "Nega" + "deny": "Nega", + "cancel": "Annulla" } diff --git a/webview-ui/src/i18n/locales/it/history.json b/webview-ui/src/i18n/locales/it/history.json index 0b3360c31bc..604a2136795 100644 --- a/webview-ui/src/i18n/locales/it/history.json +++ b/webview-ui/src/i18n/locales/it/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "Costo API: ${{cost}}", "history": "Cronologia", + "exitSelectionMode": "Esci dalla modalità selezione", + "enterSelectionMode": "Entra in modalità selezione", "done": "Fatto", "searchPlaceholder": "Ricerca nella cronologia...", "newest": "Più recenti", @@ -21,5 +23,16 @@ "deleteTask": "Elimina attività", "deleteTaskMessage": "Sei sicuro di voler eliminare questa attività? Questa azione non può essere annullata.", "cancel": "Annulla", - "delete": "Elimina" + "delete": "Elimina", + "exitSelection": "Esci dalla selezione", + "selectionMode": "Modalità selezione", + "deselectAll": "Deseleziona tutto", + "selectAll": "Seleziona tutto", + "selectedItems": "{{selected}}/{{total}} elementi selezionati", + "clearSelection": "Cancella selezione", + "deleteSelected": "Elimina selezionati", + "deleteTasks": "Elimina attività", + "confirmDeleteTasks": "Sei sicuro di voler eliminare {{count}} attività?", + "deleteTasksWarning": "Le attività eliminate non possono essere recuperate. Assicurati di voler continuare.", + "deleteItems": "Elimina {{count}} elementi" } diff --git a/webview-ui/src/i18n/locales/ja/common.json b/webview-ui/src/i18n/locales/ja/common.json index 50139e453ee..b05a22a51ad 100644 --- a/webview-ui/src/i18n/locales/ja/common.json +++ b/webview-ui/src/i18n/locales/ja/common.json @@ -4,5 +4,6 @@ "changeSettings": "設定の下部でいつでも変更できます", "settings": "設定", "allow": "許可", - "deny": "拒否" + "deny": "拒否", + "cancel": "キャンセル" } diff --git a/webview-ui/src/i18n/locales/ja/history.json b/webview-ui/src/i18n/locales/ja/history.json index c8e1184cf6a..70673037802 100644 --- a/webview-ui/src/i18n/locales/ja/history.json +++ b/webview-ui/src/i18n/locales/ja/history.json @@ -5,6 +5,8 @@ "cache": "キャッシュ: +{{writes}} → {{reads}}", "apiCost": "API コスト: ${{cost}}", "history": "履歴", + "exitSelectionMode": "選択モードを終了", + "enterSelectionMode": "選択モードに入る", "done": "完了", "searchPlaceholder": "履歴をあいまい検索...", "newest": "最新", @@ -21,5 +23,16 @@ "deleteTask": "タスクを削除", "deleteTaskMessage": "このタスクを削除してもよろしいですか?この操作は元に戻せません。", "cancel": "キャンセル", - "delete": "削除" + "delete": "削除", + "exitSelection": "選択を終了", + "selectionMode": "選択モード", + "deselectAll": "すべての選択を解除", + "selectAll": "すべて選択", + "selectedItems": "{{selected}}/{{total}} 項目を選択中", + "clearSelection": "選択をクリア", + "deleteSelected": "選択した項目を削除", + "deleteTasks": "タスクを削除", + "confirmDeleteTasks": "{{count}} 件のタスクを削除してもよろしいですか?", + "deleteTasksWarning": "削除されたタスクは復元できません。続行してもよろしいですか?", + "deleteItems": "{{count}} 項目を削除" } diff --git a/webview-ui/src/i18n/locales/ko/common.json b/webview-ui/src/i18n/locales/ko/common.json index 35a16846818..eadcb241c18 100644 --- a/webview-ui/src/i18n/locales/ko/common.json +++ b/webview-ui/src/i18n/locales/ko/common.json @@ -4,5 +4,6 @@ "changeSettings": "설정 하단에서 언제든지 변경할 수 있습니다", "settings": "설정", "allow": "허용", - "deny": "거부" + "deny": "거부", + "cancel": "취소" } diff --git a/webview-ui/src/i18n/locales/ko/history.json b/webview-ui/src/i18n/locales/ko/history.json index 1499aca6949..4c7d9478203 100644 --- a/webview-ui/src/i18n/locales/ko/history.json +++ b/webview-ui/src/i18n/locales/ko/history.json @@ -5,6 +5,8 @@ "cache": "캐시: +{{writes}} → {{reads}}", "apiCost": "API 비용: ${{cost}}", "history": "기록", + "exitSelectionMode": "선택 모드 종료", + "enterSelectionMode": "선택 모드 진입", "done": "완료", "searchPlaceholder": "기록 검색...", "newest": "최신순", @@ -21,5 +23,16 @@ "deleteTask": "작업 삭제", "deleteTaskMessage": "이 작업을 삭제하시겠습니까? 이 작업은 되돌릴 수 없습니다.", "cancel": "취소", - "delete": "삭제" + "delete": "삭제", + "exitSelection": "선택 종료", + "selectionMode": "선택 모드", + "deselectAll": "전체 선택 해제", + "selectAll": "전체 선택", + "selectedItems": "{{selected}}/{{total}}개 선택됨", + "clearSelection": "선택 초기화", + "deleteSelected": "선택 항목 삭제", + "deleteTasks": "작업 삭제", + "confirmDeleteTasks": "{{count}}개의 작업을 삭제하시겠습니까?", + "deleteTasksWarning": "삭제된 작업은 복구할 수 없습니다. 계속 진행하시겠습니까?", + "deleteItems": "{{count}}개 항목 삭제" } diff --git a/webview-ui/src/i18n/locales/pl/common.json b/webview-ui/src/i18n/locales/pl/common.json index d8ab3108b54..5460b6457c1 100644 --- a/webview-ui/src/i18n/locales/pl/common.json +++ b/webview-ui/src/i18n/locales/pl/common.json @@ -4,5 +4,6 @@ "changeSettings": "Zawsze możesz to zmienić na dole ustawień", "settings": "ustawienia", "allow": "Zezwól", - "deny": "Odmów" + "deny": "Odmów", + "cancel": "Anuluj" } diff --git a/webview-ui/src/i18n/locales/pl/history.json b/webview-ui/src/i18n/locales/pl/history.json index 1df15bc7cb2..f9359eeed82 100644 --- a/webview-ui/src/i18n/locales/pl/history.json +++ b/webview-ui/src/i18n/locales/pl/history.json @@ -5,6 +5,8 @@ "cache": "Pamięć podręczna: +{{writes}} → {{reads}}", "apiCost": "Koszt API: ${{cost}}", "history": "Historia", + "exitSelectionMode": "Wyłącz tryb wyboru", + "enterSelectionMode": "Włącz tryb wyboru", "done": "Gotowe", "searchPlaceholder": "Szukaj w historii...", "newest": "Najnowsze", @@ -21,5 +23,16 @@ "deleteTask": "Usuń zadanie", "deleteTaskMessage": "Czy na pewno chcesz usunąć to zadanie? Tej akcji nie można cofnąć.", "cancel": "Anuluj", - "delete": "Usuń" + "delete": "Usuń", + "exitSelection": "Wyjdź z wyboru", + "selectionMode": "Tryb wyboru", + "deselectAll": "Odznacz wszystko", + "selectAll": "Zaznacz wszystko", + "selectedItems": "{{selected}}/{{total}} elementów wybranych", + "clearSelection": "Wyczyść wybór", + "deleteSelected": "Usuń wybrane", + "deleteTasks": "Usuń zadania", + "confirmDeleteTasks": "Czy na pewno chcesz usunąć {{count}} zadań?", + "deleteTasksWarning": "Usuniętych zadań nie można przywrócić. Upewnij się, że chcesz kontynuować.", + "deleteItems": "Usuń {{count}} elementów" } diff --git a/webview-ui/src/i18n/locales/pt-BR/common.json b/webview-ui/src/i18n/locales/pt-BR/common.json index 5627322a3ae..14b7e555822 100644 --- a/webview-ui/src/i18n/locales/pt-BR/common.json +++ b/webview-ui/src/i18n/locales/pt-BR/common.json @@ -4,5 +4,6 @@ "changeSettings": "Você sempre pode mudar isso na parte inferior das configurações", "settings": "configurações", "allow": "Permitir", - "deny": "Negar" + "deny": "Negar", + "cancel": "Cancelar" } diff --git a/webview-ui/src/i18n/locales/pt-BR/history.json b/webview-ui/src/i18n/locales/pt-BR/history.json index 4b80832713b..9abcf1c82ba 100644 --- a/webview-ui/src/i18n/locales/pt-BR/history.json +++ b/webview-ui/src/i18n/locales/pt-BR/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "Custo da API: ${{cost}}", "history": "Histórico", + "exitSelectionMode": "Sair do modo de seleção", + "enterSelectionMode": "Entrar no modo de seleção", "done": "Concluído", "searchPlaceholder": "Pesquisar no histórico...", "newest": "Mais recentes", @@ -21,5 +23,12 @@ "deleteTask": "Excluir tarefa", "deleteTaskMessage": "Tem certeza que deseja excluir esta tarefa? Esta ação não pode ser desfeita.", "cancel": "Cancelar", - "delete": "Excluir" + "delete": "Excluir", + "exitSelection": "Sair da seleção", + "selectionMode": "Modo de seleção", + "deselectAll": "Desmarcar tudo", + "selectAll": "Selecionar tudo", + "selectedItems": "{{selected}}/{{total}} itens selecionados", + "clearSelection": "Limpar seleção", + "deleteSelected": "Excluir selecionados" } diff --git a/webview-ui/src/i18n/locales/pt/common.json b/webview-ui/src/i18n/locales/pt/common.json index 5627322a3ae..14b7e555822 100644 --- a/webview-ui/src/i18n/locales/pt/common.json +++ b/webview-ui/src/i18n/locales/pt/common.json @@ -4,5 +4,6 @@ "changeSettings": "Você sempre pode mudar isso na parte inferior das configurações", "settings": "configurações", "allow": "Permitir", - "deny": "Negar" + "deny": "Negar", + "cancel": "Cancelar" } diff --git a/webview-ui/src/i18n/locales/pt/history.json b/webview-ui/src/i18n/locales/pt/history.json index b7cfd9807f9..d925349b732 100644 --- a/webview-ui/src/i18n/locales/pt/history.json +++ b/webview-ui/src/i18n/locales/pt/history.json @@ -5,6 +5,8 @@ "cache": "Cache: +{{writes}} → {{reads}}", "apiCost": "Custo da API: ${{cost}}", "history": "Histórico", + "exitSelectionMode": "Sair do modo de seleção", + "enterSelectionMode": "Entrar no modo de seleção", "done": "Concluído", "searchPlaceholder": "Pesquisar no histórico...", "newest": "Mais recentes", @@ -21,5 +23,16 @@ "deleteTask": "Eliminar tarefa", "deleteTaskMessage": "Tem a certeza que pretende eliminar esta tarefa? Esta ação não pode ser desfeita.", "cancel": "Cancelar", - "delete": "Eliminar" + "delete": "Eliminar", + "exitSelection": "Sair da seleção", + "selectionMode": "Modo de seleção", + "deselectAll": "Desmarcar tudo", + "selectAll": "Selecionar tudo", + "selectedItems": "{{selected}}/{{total}} itens selecionados", + "clearSelection": "Limpar seleção", + "deleteSelected": "Eliminar selecionados", + "deleteTasks": "Eliminar tarefas", + "confirmDeleteTasks": "Tem a certeza que pretende eliminar {{count}} tarefas?", + "deleteTasksWarning": "As tarefas eliminadas não podem ser recuperadas. Por favor, confirme que pretende continuar.", + "deleteItems": "Eliminar {{count}} itens" } diff --git a/webview-ui/src/i18n/locales/ru/common.json b/webview-ui/src/i18n/locales/ru/common.json index b422a8f4508..c9086b2f0c3 100644 --- a/webview-ui/src/i18n/locales/ru/common.json +++ b/webview-ui/src/i18n/locales/ru/common.json @@ -4,5 +4,6 @@ "changeSettings": "Вы всегда можете изменить это внизу настроек", "settings": "настройки", "allow": "Разрешить", - "deny": "Отклонить" + "deny": "Отклонить", + "cancel": "Отмена" } diff --git a/webview-ui/src/i18n/locales/ru/history.json b/webview-ui/src/i18n/locales/ru/history.json index 6ada7ad9760..0841fac30a0 100644 --- a/webview-ui/src/i18n/locales/ru/history.json +++ b/webview-ui/src/i18n/locales/ru/history.json @@ -5,6 +5,8 @@ "cache": "Кэш: +{{writes}} → {{reads}}", "apiCost": "Стоимость API: ${{cost}}", "history": "История", + "exitSelectionMode": "Выйти из режима выбора", + "enterSelectionMode": "Войти в режим выбора", "done": "Готово", "searchPlaceholder": "Поиск по истории...", "newest": "Новейшие", @@ -21,5 +23,16 @@ "deleteTask": "Удалить задачу", "deleteTaskMessage": "Вы уверены, что хотите удалить эту задачу? Это действие нельзя отменить.", "cancel": "Отмена", - "delete": "Удалить" + "delete": "Удалить", + "exitSelection": "Выйти из выбора", + "selectionMode": "Режим выбора", + "deselectAll": "Снять все выделения", + "selectAll": "Выбрать все", + "selectedItems": "Выбрано {{selected}}/{{total}} элементов", + "clearSelection": "Очистить выбор", + "deleteSelected": "Удалить выбранные", + "deleteTasks": "Удалить задачи", + "confirmDeleteTasks": "Вы уверены, что хотите удалить {{count}} задач?", + "deleteTasksWarning": "Удаленные задачи не могут быть восстановлены. Пожалуйста, подтвердите, что хотите продолжить.", + "deleteItems": "Удалить {{count}} элементов" } diff --git a/webview-ui/src/i18n/locales/tr/common.json b/webview-ui/src/i18n/locales/tr/common.json index 0a1c0e57c25..4d2fdc22e7a 100644 --- a/webview-ui/src/i18n/locales/tr/common.json +++ b/webview-ui/src/i18n/locales/tr/common.json @@ -4,5 +4,6 @@ "changeSettings": "Bunu her zaman ayarların altından değiştirebilirsiniz", "settings": "ayarlar", "allow": "İzin Ver", - "deny": "Reddet" + "deny": "Reddet", + "cancel": "İptal" } diff --git a/webview-ui/src/i18n/locales/tr/history.json b/webview-ui/src/i18n/locales/tr/history.json index 74bd66abb3e..1497c5c4b63 100644 --- a/webview-ui/src/i18n/locales/tr/history.json +++ b/webview-ui/src/i18n/locales/tr/history.json @@ -5,6 +5,8 @@ "cache": "Önbellek: +{{writes}} → {{reads}}", "apiCost": "API Maliyeti: ${{cost}}", "history": "Geçmiş", + "exitSelectionMode": "Seçim Modundan Çık", + "enterSelectionMode": "Seçim Moduna Gir", "done": "Tamam", "searchPlaceholder": "Geçmişte ara...", "newest": "En Yeni", @@ -21,5 +23,12 @@ "deleteTask": "Görevi Sil", "deleteTaskMessage": "Bu görevi silmek istediğinizden emin misiniz? Bu işlem geri alınamaz.", "cancel": "İptal", - "delete": "Sil" + "delete": "Sil", + "exitSelection": "Seçimden Çık", + "selectionMode": "Seçim Modu", + "deselectAll": "Tümünü Seçimi Kaldır", + "selectAll": "Tümünü Seç", + "selectedItems": "{{selected}}/{{total}} öğe seçildi", + "clearSelection": "Seçimi Temizle", + "deleteSelected": "Seçilenleri Sil" } diff --git a/webview-ui/src/i18n/locales/zh-CN/common.json b/webview-ui/src/i18n/locales/zh-CN/common.json index 298126f12d1..3a6e13b1991 100644 --- a/webview-ui/src/i18n/locales/zh-CN/common.json +++ b/webview-ui/src/i18n/locales/zh-CN/common.json @@ -4,5 +4,6 @@ "settings": "设置", "anonymousTelemetry": "发送匿名的错误和使用数据,以帮助我们修复错误并改进扩展程序。不会发送任何代码、提示或个人信息。", "allow": "允许", - "deny": "拒绝" + "deny": "拒绝", + "cancel": "取消" } diff --git a/webview-ui/src/i18n/locales/zh-CN/history.json b/webview-ui/src/i18n/locales/zh-CN/history.json index 6671f5d59e6..d7945d38602 100644 --- a/webview-ui/src/i18n/locales/zh-CN/history.json +++ b/webview-ui/src/i18n/locales/zh-CN/history.json @@ -5,6 +5,8 @@ "cache": "缓存: +{{writes}} → {{reads}}", "apiCost": "API 成本: ${{cost}}", "history": "历史记录", + "exitSelectionMode": "退出选择模式", + "enterSelectionMode": "进入选择模式", "done": "完成", "searchPlaceholder": "模糊搜索历史...", "newest": "最新", @@ -21,5 +23,16 @@ "deleteTask": "删除任务", "deleteTaskMessage": "确定要删除此任务吗?此操作无法撤销。", "cancel": "取消", - "delete": "删除" + "delete": "删除", + "exitSelection": "退出选择", + "selectionMode": "选择模式", + "deselectAll": "取消全选", + "selectAll": "全选", + "selectedItems": "已选 {{selected}}/{{total}} 项", + "clearSelection": "清除选择", + "deleteSelected": "删除选中项", + "deleteTasks": "删除任务", + "confirmDeleteTasks": "确定要删除 {{count}} 个任务吗?", + "deleteTasksWarning": "已删除的任务无法恢复。请确认是否继续。", + "deleteItems": "删除 {{count}} 项" } diff --git a/webview-ui/src/i18n/locales/zh-TW/common.json b/webview-ui/src/i18n/locales/zh-TW/common.json index f1b1f817595..cbbb7ae2714 100644 --- a/webview-ui/src/i18n/locales/zh-TW/common.json +++ b/webview-ui/src/i18n/locales/zh-TW/common.json @@ -4,5 +4,6 @@ "changeSettings": "您隨時可以在設置底部更改此選項", "settings": "設置", "allow": "允許", - "deny": "拒絕" + "deny": "拒絕", + "cancel": "取消" } diff --git a/webview-ui/src/i18n/locales/zh-TW/history.json b/webview-ui/src/i18n/locales/zh-TW/history.json index 588b008c5c4..acb81e47555 100644 --- a/webview-ui/src/i18n/locales/zh-TW/history.json +++ b/webview-ui/src/i18n/locales/zh-TW/history.json @@ -5,6 +5,8 @@ "cache": "快取: +{{writes}} → {{reads}}", "apiCost": "API 費用: ${{cost}}", "history": "歷史記錄", + "exitSelectionMode": "退出選擇模式", + "enterSelectionMode": "進入選擇模式", "done": "完成", "searchPlaceholder": "模糊搜尋歷史...", "newest": "最新", @@ -21,5 +23,16 @@ "deleteTask": "刪除任務", "deleteTaskMessage": "確定要刪除此任務嗎?此操作無法復原。", "cancel": "取消", - "delete": "刪除" + "delete": "刪除", + "exitSelection": "退出選擇", + "selectionMode": "選擇模式", + "deselectAll": "取消全選", + "selectAll": "全選", + "selectedItems": "已選 {{selected}}/{{total}} 項", + "clearSelection": "清除選擇", + "deleteSelected": "刪除所選", + "deleteTasks": "刪除任務", + "confirmDeleteTasks": "確定要刪除 {{count}} 個任務嗎?", + "deleteTasksWarning": "已刪除的任務無法恢復。請確認是否繼續。", + "deleteItems": "刪除 {{count}} 項" } From 25c43869957bb15af44f7eb74a731b5ed917edb1 Mon Sep 17 00:00:00 2001 From: aheizi Date: Mon, 17 Mar 2025 18:27:16 +0800 Subject: [PATCH 05/10] add i18n for history --- src/shared/language.ts | 1 + webview-ui/src/components/history/BatchDeleteTaskDialog.tsx | 2 +- webview-ui/src/i18n/locales/ca/history.json | 3 +++ webview-ui/src/i18n/locales/de/history.json | 3 +++ webview-ui/src/i18n/locales/en/history.json | 3 +++ webview-ui/src/i18n/locales/es/history.json | 3 +++ webview-ui/src/i18n/locales/fr/history.json | 3 +++ webview-ui/src/i18n/locales/hi/history.json | 3 +++ webview-ui/src/i18n/locales/it/history.json | 3 +++ webview-ui/src/i18n/locales/ja/history.json | 3 +++ webview-ui/src/i18n/locales/ko/history.json | 3 +++ webview-ui/src/i18n/locales/pl/history.json | 3 +++ webview-ui/src/i18n/locales/pt-BR/history.json | 3 +++ webview-ui/src/i18n/locales/tr/history.json | 3 +++ webview-ui/src/i18n/locales/vi/history.json | 3 +++ webview-ui/src/i18n/locales/zh-CN/history.json | 3 +++ webview-ui/src/i18n/locales/zh-TW/history.json | 3 +++ 17 files changed, 47 insertions(+), 1 deletion(-) diff --git a/src/shared/language.ts b/src/shared/language.ts index b5cb4228b5c..1c16ec77468 100644 --- a/src/shared/language.ts +++ b/src/shared/language.ts @@ -6,6 +6,7 @@ * @returns The formatted locale string with uppercase region code */ export function formatLanguage(vscodeLocale: string): string { + return "zh-CN" if (!vscodeLocale) { return "en" // Default to English if no locale is provided } diff --git a/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx index 20aa40e1d5b..cc9573b7327 100644 --- a/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx +++ b/webview-ui/src/components/history/BatchDeleteTaskDialog.tsx @@ -43,7 +43,7 @@ export const BatchDeleteTaskDialog = ({ taskIds, ...props }: BatchDeleteTaskDial - + +