25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。
TypeScript aicliclickhousedatabasedatabase-clientdatabase-managementdockerguimcpmongodbmysqlpostgresqlredisrustsql-serversqlitetaurivue
fix(settings): align about-page import/export icon semantics
onenewcodeb28374867aa3
diff --git a/apps/desktop/src/components/settings/SettingsTransferPanel.vue b/apps/desktop/src/components/settings/SettingsTransferPanel.vueindex c54be3b1fd..b93ece59ba 100644--- a/apps/desktop/src/components/settings/SettingsTransferPanel.vue+++ b/apps/desktop/src/components/settings/SettingsTransferPanel.vue@@ -253,12 +253,12 @@ function confirmImport() {<div class="settings-about-section-actions flex shrink-0 flex-wrap items-center gap-2"><Button type="button" variant="outline" size="sm" class="shrink-0" :disabled="busy" @click="onExportClick"><Loader2 v-if="exporting" class="mr-1 h-3.5 w-3.5 animate-spin" />- <Download v-else class="mr-1 h-3.5 w-3.5" />+ <Upload v-else class="mr-1 h-3.5 w-3.5" />{{ t("settings.settingsTransferExport") }}</Button><Button type="button" variant="outline" size="sm" class="shrink-0" :disabled="busy" @click="onImportClick"><Loader2 v-if="importing" class="mr-1 h-3.5 w-3.5 animate-spin" />- <Upload v-else class="mr-1 h-3.5 w-3.5" />+ <Download v-else class="mr-1 h-3.5 w-3.5" />{{ t("settings.settingsTransferImport") }}</Button></div>diff --git a/packages/app-tests/settingsTransferPanel.test.ts b/packages/app-tests/settingsTransferPanel.test.tsnew file mode 100644index 0000000000..5077f39573--- /dev/null+++ b/packages/app-tests/settingsTransferPanel.test.ts@@ -0,0 +1,31 @@+import assert from "node:assert/strict";+import { readFileSync } from "node:fs";+import { test } from "vitest";+import { compileScript, compileTemplate, parse } from "vue/compiler-sfc";++const panelPath = "apps/desktop/src/components/settings/SettingsTransferPanel.vue";++function source(path: string): string {+ return readFileSync(path, "utf8");+}++test("settings transfer panel SFC compiles", () => {+ const { descriptor, errors } = parse(source(panelPath), { filename: panelPath });+ assert.deepEqual(errors, [], `${panelPath} should parse without SFC errors`);+ assert.ok(descriptor.scriptSetup, `${panelPath} should have a script setup block`);+ compileScript(descriptor, { id: panelPath });+ assert.ok(descriptor.template, `${panelPath} should have a template`);+ const result = compileTemplate({ id: panelPath, filename: panelPath, source: descriptor.template.content });+ assert.deepEqual(result.errors, [], `${panelPath} template should compile`);+});++test("about-page settings transfer buttons follow local-container icon semantics", () => {+ const panel = source(panelPath);++ // Treat the app as a local container: import brings data in (Download),+ // export sends data out (Upload). Same contract as SQL library / formatter.+ assert.match(panel, /@click="onImportClick"[\s\S]{0,200}<Download v-else/);+ assert.match(panel, /@click="onExportClick"[\s\S]{0,200}<Upload v-else/);+ assert.doesNotMatch(panel, /@click="onImportClick"[\s\S]{0,200}<Upload v-else/);+ assert.doesNotMatch(panel, /@click="onExportClick"[\s\S]{0,200}<Download v-else/);+});