Skip to content

Commit

Permalink
conditional props in test
Browse files Browse the repository at this point in the history
  • Loading branch information
Luisgustavom1 committed Dec 20, 2024
1 parent a64fc4b commit 2551615
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/TreeDataGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export interface TreeDataGridProps<R, SR = unknown, K extends Key = Key>
) => Record<string, readonly NoInfer<R>[]>;
expandedGroupIds: ReadonlySet<unknown>;
onExpandedGroupIdsChange: (expandedGroupIds: Set<unknown>) => void;
generateGroupId: ((groupKey: string, parentId?: string) => string) | undefined;
generateGroupId?: (groupKey: string, parentId?: string) => string;
}

type GroupByDictionary<TRow> = Record<
Expand Down
2 changes: 1 addition & 1 deletion test/browser/TreeDataGrid.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ function TestGrid({ groupBy, generateGroupId }: TestGridProps) {
onExpandedGroupIdsChange={setExpandedGroupIds}
onRowsChange={setRows}
onPaste={onPaste}
generateGroupId={generateGroupId}
{...(generateGroupId && { generateGroupId })}
/>
);
}
Expand Down

0 comments on commit 2551615

Please sign in to comment.