From 0b8f060c6fe20595034d82ee95f1a9e193a141dc Mon Sep 17 00:00:00 2001 From: Julian Freeman Date: Mon, 19 Jan 2026 09:32:12 -0400 Subject: [PATCH] locale --- src/App.vue | 14 +++++----- src/components/HeroView.vue | 2 +- src/components/SettingsPanel.vue | 46 ++++++++++++++++---------------- src/stores/gallery.ts | 2 +- 4 files changed, 32 insertions(+), 32 deletions(-) diff --git a/src/App.vue b/src/App.vue index ef95271..19cb1e0 100644 --- a/src/App.vue +++ b/src/App.vue @@ -33,7 +33,7 @@ async function openFolder() { async function exportBatch() { if (store.images.length === 0) return; if (!store.watermarkSettings.text) { - alert("Please enter watermark text."); + alert("请输入水印文字。"); return; } @@ -41,7 +41,7 @@ async function exportBatch() { const outputDir = await open({ directory: true, multiple: false, - title: "Select Output Directory" + title: "选择输出目录" }); if (outputDir && typeof outputDir === 'string') { @@ -69,11 +69,11 @@ async function exportBatch() { watermark: rustWatermarkSettings, outputDir: outputDir }); - alert("Batch export completed!"); + alert("批量导出完成!"); } } catch (e) { console.error("Export failed:", e); - alert("Export failed: " + e); + alert("导出失败: " + e); } finally { isExporting.value = false; } @@ -84,7 +84,7 @@ async function exportBatch() {
-

WATERMARK WIZARD

+

水印精灵

@@ -93,7 +93,7 @@ async function exportBatch() { class="flex items-center gap-2 bg-gray-700 hover:bg-gray-600 text-gray-200 px-4 py-2 rounded-md text-sm font-medium transition-all hover:shadow-lg" > - Open Folder + 打开文件夹
diff --git a/src/components/HeroView.vue b/src/components/HeroView.vue index 66600f9..22f1ee7 100644 --- a/src/components/HeroView.vue +++ b/src/components/HeroView.vue @@ -302,7 +302,7 @@ const stopDrawing = () => { >
-

No image selected

+

未选择图片

diff --git a/src/components/SettingsPanel.vue b/src/components/SettingsPanel.vue index 9735b90..d7c25f9 100644 --- a/src/components/SettingsPanel.vue +++ b/src/components/SettingsPanel.vue @@ -40,7 +40,7 @@ const currentColor = computed({ }); const applyAll = () => { - if (confirm("Apply current settings (Size, Opacity, Color) to ALL images?")) { + if (confirm("是否将当前设置(大小、透明度、颜色)应用到所有图片?")) { store.applySettingsToAll(); } }; @@ -56,14 +56,14 @@ const applyAll = () => { class="flex-1 py-3 text-sm font-medium flex items-center justify-center gap-2 transition-colors" :class="store.editMode === 'add' ? 'bg-gray-700 text-blue-400 border-b-2 border-blue-400' : 'text-gray-400 hover:bg-gray-750'" > - Add + 添加 @@ -75,20 +75,20 @@ const applyAll = () => {

- Watermark + 水印设置

- +
@@ -96,13 +96,13 @@ const applyAll = () => { type="text" v-model="store.watermarkSettings.text" class="w-full bg-gray-700 text-white pl-10 pr-3 py-2 rounded border border-gray-600 focus:border-blue-500 focus:outline-none" - placeholder="Enter text..." + placeholder="输入水印文字..." />
@@ -111,7 +111,7 @@ const applyAll = () => {
- +
{
- + {{ (currentScale * 100).toFixed(1) }}%
{ v-model.number="currentScale" class="w-full h-1 bg-gray-600 rounded-lg appearance-none cursor-pointer accent-blue-500" /> -

Relative to image height

+

基于图片高度的比例

- + {{ (currentOpacity * 100).toFixed(0) }}%
{
- +
-

Auto (ZCA)

-

Manual Override

+

自动 (ZCA)

+

手动调整

@@ -177,7 +177,7 @@ const applyAll = () => {

- Magic Eraser + 魔法橡皮擦

@@ -186,23 +186,23 @@ const applyAll = () => { @click="store.detectAllWatermarks()" class="flex-1 bg-blue-600 hover:bg-blue-500 text-white py-2 rounded flex items-center justify-center gap-2 text-sm transition-colors" > - Auto Detect + 自动检测
-

Paint over the watermark you want to remove. The AI will fill in the background.

+

涂抹想要移除的水印,AI 将自动填充背景。

- + {{ store.brushSettings.size }}px
{
- AI Inpainting (Diffusion) connected. + AI 修复功能已就绪。
diff --git a/src/stores/gallery.ts b/src/stores/gallery.ts index 1ad2994..bf23918 100644 --- a/src/stores/gallery.ts +++ b/src/stores/gallery.ts @@ -40,7 +40,7 @@ export const useGalleryStore = defineStore("gallery", () => { const watermarkSettings = ref({ type: 'text', - text: 'Watermark', + text: '水印', color: '#FFFFFF', opacity: 1.0, scale: 0.03,