Skip to content

Commit

Permalink
chore: [SyncCatalog V2] remove debug code from catalog (#13994)
Browse files Browse the repository at this point in the history
  • Loading branch information
dizel852 committed Sep 18, 2024
1 parent ab5be73 commit 4b2a524
Showing 1 changed file with 1 addition and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ export const SyncCatalogTable: FC<SyncCatalogTableProps> = ({ scrollParentContai
const isHashingEnabled = useExperiment("connection.hashingUI", false);
const showHashing = isHashingSupported && isHashingEnabled;

const debugTable = false;
const [columnFilters, setColumnFilters] = useState<ColumnFiltersState>([]);
const [filtering, setFiltering] = useState("");
const deferredFilteringValue = useDeferredValue(filtering);
Expand Down Expand Up @@ -319,7 +318,7 @@ export const SyncCatalogTable: FC<SyncCatalogTableProps> = ({ scrollParentContai
);
const [expanded, setExpanded] = React.useState<ExpandedState>(initialExpandedState);

const { getHeaderGroups, getRowModel, getState, toggleAllRowsExpanded } = useReactTable<SyncCatalogUIModel>({
const { getHeaderGroups, getRowModel, toggleAllRowsExpanded } = useReactTable<SyncCatalogUIModel>({
columns,
data: preparedData,
getSubRows: (row) => row.subRows,
Expand Down Expand Up @@ -347,7 +346,6 @@ export const SyncCatalogTable: FC<SyncCatalogTableProps> = ({ scrollParentContai
onColumnFiltersChange: setColumnFilters,
onGlobalFilterChange: setFiltering,
getRowCanExpand: (row) => !!row.subRows.length,
debugTable,
});

const rows = getRowModel().rows;
Expand Down Expand Up @@ -461,19 +459,6 @@ export const SyncCatalogTable: FC<SyncCatalogTableProps> = ({ scrollParentContai
return (
<>
<Box p="md" pl="xl" pr="xl" className={styles.stickyControlsContainer}>
{debugTable && (
<Box p="md">
{JSON.stringify(
{
globalFilter: getState().globalFilter,
columnFilters: getState().columnFilters,
totalRows: rows.length,
},
null,
2
)}
</Box>
)}
<FlexContainer alignItems="center" justifyContent="space-between">
<SearchInput
value={filtering}
Expand Down

0 comments on commit 4b2a524

Please sign in to comment.