fix(objects): preserve category filter per tab

This commit is contained in:
Eve authored and GitHub committed 2026-09-10 15:57:15 +08:00
1 parent bd828076ab
commit 5b5d58cd2a
11 files changed
+47 -32

No files matched your search

@@ -1,4 +1,5 @@
import type { MongoCollectionKind, ObjectInfo, TreeNode, TreeNodeType } from "@/types/database";
import type { MongoCollectionKind, ObjectBrowserFilter, ObjectInfo, TreeNode, TreeNodeType } from "@/types/database";
export type { ObjectBrowserFilter } from "@/types/database";
import { pinnedTreeNodeIdentityMatches, type PinnedTreeNodeIdentity } from "@/lib/app/pinnedItems";
import { toMongoCollectionKind } from "@/lib/sidebar/mongoCollectionMutation";
import { buildGroupedObjectTreeNodes, buildSimpleObjectTreeNodes, buildTableTreeNodes, compareDatabaseObjectNames, normalizeDatabaseObjectName } from "@/lib/table/tableTree";
@@ -26,7 +27,6 @@ export type ObjectBrowserRow = {
export type ObjectBrowserSortKey = "name" | "type" | "estimatedRows" | "totalBytes" | "created_at" | "updated_at" | "comment";
export type ObjectBrowserSortDirection = "asc" | "desc";
export type ObjectBrowserFilter = "all" | "tables" | "views" | "materializedViews" | "procedures" | "functions" | "triggers" | "events" | "sequences" | "packages" | "types";
export type ObjectBrowserFilterCounts = Record<ObjectBrowserFilter, number>;
export type ObjectBrowserPinnedTreeNodeContext = {
@@ -35,6 +35,7 @@ export const contentSurfaceEventNames = [
"objectSchemaChange",
"objectBrowserViewportChange",
"objectBrowserSearchChange",
"objectBrowserFilterChange",
"addObjectTableToAi",
"structureEditorSaved",
"structureEditorClose",