Restore DBGate beside Adminer

This commit is contained in:
2026-08-05 22:42:59 +02:00
parent 05ae8f03d2
commit 9b1898a588
11 changed files with 11671 additions and 9 deletions
+12
View File
@@ -51,6 +51,14 @@ export function loadConfig({ configPath = "config/local.json", dryRun } = {}) {
|| "chromium",
).toLowerCase(),
},
dbGate: {
url: env.DBGATE_URL || config.dbGate?.url || "http://127.0.0.1:3000",
browserEngine: String(
env.DBGATE_BROWSER_ENGINE
|| config.dbGate?.browserEngine
|| "chromium",
).toLowerCase(),
},
};
}
@@ -104,5 +112,9 @@ function mergeConfig(base, override) {
...override.databaseTool,
...override.databaseGate,
},
dbGate: {
...base.dbGate,
...override.dbGate,
},
};
}
+10
View File
@@ -146,6 +146,16 @@ const server = http.createServer(async (request, response) => {
return;
}
if (url.pathname === "/api/tools/open-dbgate") {
await openInBrowser(config.dbGate.url, { engine: config.dbGate.browserEngine });
await sendJson(response, {
opened: true,
url: config.dbGate.url,
browserEngine: config.dbGate.browserEngine,
});
return;
}
if (url.pathname === "/api/catalog-maker/product-info") {
await sendJson(
response,
+2
View File
@@ -196,6 +196,8 @@
.settings-group legend { @apply px-1 text-xs font-semibold text-slate-700; }
.settings-option { @apply flex items-center gap-1 py-0.5 text-[11px] text-slate-700; }
.settings-option .settings-inline-button { @apply ml-auto py-0.5 text-[10px]; }
.settings-tool-actions { @apply ml-auto flex items-center gap-1; }
.settings-tool-actions .settings-inline-button { @apply ml-0; }
.settings-option input { @apply accent-catalog-focus; }
.settings-option input:disabled + span { @apply text-slate-400; }
.local-db-fields { @apply grid gap-1; }