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。

fix(ci): clear sidebar search filter when a ui-preview step fails

t8y22f56bc78022e
diff --git a/.github/ui-preview/record.mjs b/.github/ui-preview/record.mjs
index 0e88188099..a60d0c153a 100755
--- a/.github/ui-preview/record.mjs
+++ b/.github/ui-preview/record.mjs
@@ -586,6 +586,18 @@ async function main() {
// shows up in the shots that follow: clear it before going on
await page.keyboard.press("Escape").catch(() => {});
await sleep(400);
+ // an active sidebar search keeps the tree filtered down to
+ // nothing, starving every later lookup of its targets: empty it
+ // the way a user would
+ try {
+ const box = page.locator(".connection-tree-search input").first();
+ if ((await box.isVisible().catch(() => false)) && (await box.inputValue().catch(() => ""))) {
+ await box.click({ timeout: 1500 });
+ await page.keyboard.press("ControlOrMeta+A");
+ await page.keyboard.press("Delete");
+ await sleep(300);
+ }
+ } catch {}
if (repairs >= 3) continue;
repairs++;
// the page as it is now, and what went wrong: the rest of the scene again