Skip to content

Commit

Permalink
clean up hidden columns logic
Browse files Browse the repository at this point in the history
Signed-off-by: Adam Tackett <[email protected]>
  • Loading branch information
Adam Tackett committed Jan 28, 2025
1 parent a6abecc commit 0f98dab
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -216,14 +216,12 @@ export function SpanDetailTable(props: SpanDetailTableProps) {
setTableParams((prev) => ({ ...prev, size, page: 0 }));
};

const hiddenColumns = props.hiddenColumns ?? ['traceId', 'traceGroup'];

const visibleColumns = useMemo(
() =>
getColumns(props.mode)
.filter(({ id }) => !hiddenColumns.includes(id))
.filter(({ id }) => !props.hiddenColumns.includes(id))
.map(({ id }) => id),
[props.mode, hiddenColumns]
[props.mode]
);

return RenderCustomDataGrid({
Expand Down

0 comments on commit 0f98dab

Please sign in to comment.