Skip to content

armgit / dbx

Public Imported from GitHub
0

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。

feat: enhance loading experience and update window visibility settings

t8y266b91d06bbeb
diff --git a/index.html b/index.html
index 8a33c8d7a2..f49d2f3eef 100644
--- a/index.html
+++ b/index.html
@@ -7,7 +7,20 @@
<title>DBX</title>
</head>
<body>
- <div id="root"></div>
+ <div id="root">
+ <style>
+ #root:empty {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ height: 100vh;
+ font-family: system-ui, sans-serif;
+ color: #888;
+ font-size: 13px;
+ }
+ #root:empty::after { content: "Loading…"; }
+ </style>
+ </div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>
diff --git a/src-tauri/capabilities/default.json b/src-tauri/capabilities/default.json
index e53afc171c..fd3fb8505b 100644
--- a/src-tauri/capabilities/default.json
+++ b/src-tauri/capabilities/default.json
@@ -7,6 +7,8 @@
],
"permissions": [
"core:default",
+ "core:window:allow-show",
+ "core:window:allow-hide",
"dialog:default",
"dialog:allow-save",
"dialog:allow-open",
diff --git a/src-tauri/tauri.conf.json b/src-tauri/tauri.conf.json
index 4eea8c04d5..75bb11ea32 100644
--- a/src-tauri/tauri.conf.json
+++ b/src-tauri/tauri.conf.json
@@ -18,7 +18,8 @@
"minWidth": 900,
"minHeight": 600,
"resizable": true,
- "fullscreen": false
+ "fullscreen": false,
+ "visible": false
}
],
"security": {
diff --git a/src/main.ts b/src/main.ts
index 3f7da5cddb..e6f5922b57 100644
--- a/src/main.ts
+++ b/src/main.ts
@@ -2,6 +2,7 @@ import { createApp } from "vue";
import { createPinia } from "pinia";
import VueVirtualScroller from "vue-virtual-scroller";
import "vue-virtual-scroller/dist/vue-virtual-scroller.css";
+import { getCurrentWindow } from "@tauri-apps/api/window";
import i18n from "./i18n";
import App from "./App.vue";
import "./styles/globals.css";
@@ -11,3 +12,5 @@ app.use(createPinia());
app.use(i18n);
app.use(VueVirtualScroller);
app.mount("#root");
+
+getCurrentWindow().show();