We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 672df4e commit e4e7060Copy full SHA for e4e7060
packages/compass-indexes/src/components/indexes-table/indexes-table.tsx
@@ -1,4 +1,4 @@
1
-import React from 'react';
+import React, { useState } from 'react';
2
import {
3
css,
4
cx,
@@ -95,6 +95,7 @@ export function IndexesTable<T>({
95
columns,
96
data,
97
}: IndexesTableProps<T>) {
98
+ const [expanded, setExpanded] = useState<true | Record<string, boolean>>({});
99
const [sorting, setSorting] = useTabState<SortingState>(
100
`${id}-sorting-state`,
101
[]
@@ -104,7 +105,8 @@ export function IndexesTable<T>({
104
105
106
enableSortingRemoval: false,
107
withPagination: false,
- state: { sorting },
108
+ state: { sorting, expanded },
109
+ onExpandedChange: setExpanded,
110
onSortingChange: setSorting,
111
});
112
0 commit comments