fix: update tests for table structure editor tab conversion and type/length split

- Remove deleted Dialog.vue references from dialogOpenWatcher and structure tests
- Update presentation test assertions for tab layout and SearchableSelect
- Add schema to newQueryContext expected results (schema propagation)
- Make queryStore i18n resilient to missing Vue app context (tests)
- Fix regex patterns for oxfmt-formatted code
This commit is contained in:
t8y2
2026-05-24 22:52:58 +08:00
parent 75e97001ec
commit dbd2b2bab5
5 changed files with 26 additions and 11 deletions
+9 -1
View File
@@ -43,8 +43,16 @@ function loadSavedTabs(): { tabs: QueryTab[]; activeTabId: string | null } {
}
}
function getI18nT() {
try {
return useI18n().t;
} catch {
return ((key: string, ..._args: unknown[]) => key) as ReturnType<typeof useI18n>["t"];
}
}
export const useQueryStore = defineStore("query", () => {
const { t } = useI18n();
const t = getI18nT();
const restored = loadSavedTabs();
const tabs = ref<QueryTab[]>(restored.tabs);
const activeTabId = ref<string | null>(restored.activeTabId);