feat: wire schema scope discovery for all relational setup drivers

This commit is contained in:
Andrey Avtomonov 2026-05-21 19:48:13 +02:00
parent 633d53a2cb
commit 4efa061c0e
3 changed files with 219 additions and 34 deletions

View file

@ -38,6 +38,11 @@ export type DatabaseScopePickResult =
| { kind: 'selected'; activeSchemas: string[]; enabledTables: string[] }
| { kind: 'back' };
interface ScopeSuggestion {
excluded: Set<string>;
suggested: Set<string>;
}
export interface PickDatabaseScopeArgs {
connectionId: string;
schemaNoun: string;
@ -45,6 +50,7 @@ export interface PickDatabaseScopeArgs {
discovered: readonly KtxTableListEntry[];
existing: { enabledTables: readonly string[] };
defaultSchemas: readonly string[];
schemaSuggestion?: ScopeSuggestion;
supportsSchemaScope: boolean;
}