Skip to content

Commit

Permalink
fix(corel): remove Row prop from releases Table
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrobonamin committed Aug 2, 2024
1 parent 9a24c36 commit 09b0bf5
Showing 1 changed file with 0 additions and 31 deletions.
31 changes: 0 additions & 31 deletions packages/sanity/src/core/releases/components/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,24 +18,6 @@ type RowDatum<TableData, AdditionalRowTableData> = AdditionalRowTableData extend
export interface TableProps<TableData, AdditionalRowTableData> {
columnDefs: Column<RowDatum<TableData, AdditionalRowTableData>>[]
searchFilter?: (data: TableData[], searchTerm: string) => TableData[]
/**
* @deprecated This is not necessary anymore - remove in next commit
*/
Row?: ({
datum,
virtualRow,
children,
}: {
datum: TableData
virtualRow: VirtualItem
index: number
children: (
rowData: TableData & {
virtualRow: VirtualItem
index: number
},
) => JSX.Element
}) => JSX.Element | null
data: TableData[]
emptyState: (() => JSX.Element) | string
loading?: boolean
Expand Down Expand Up @@ -70,7 +52,6 @@ const TableInner = <TableData, AdditionalRowTableData>({
data,
emptyState,
searchFilter,
Row,
rowId,
rowActions,
loading = false,
Expand Down Expand Up @@ -221,18 +202,6 @@ const TableInner = <TableData, AdditionalRowTableData>({
? emptyContent
: rowVirtualizer.getVirtualItems().map((virtualRow, index) => {
const datum = filteredData[virtualRow.index]
if (Row) {
return (
<Row
key={String(get(datum, rowId))}
datum={datum}
virtualRow={virtualRow}
index={index}
>
{renderRow}
</Row>
)
}
return renderRow({...datum, virtualRow, index})
})}
</RowStack>
Expand Down

0 comments on commit 09b0bf5

Please sign in to comment.