Skip to content

Commit

Permalink
Revert changes
Browse files Browse the repository at this point in the history
  • Loading branch information
fzaninotto committed Jul 8, 2022
1 parent ba33ac1 commit 156eeb1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion examples/crm/src/contacts/ContactList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const ContactListContent = () => {
<BulkDeleteButton />
</BulkActionsToolbar>
<List>
{contacts?.map(contact => (
{contacts.map(contact => (
<RecordContextProvider key={contact.id} value={contact}>
<ListItem
button
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/categories/CategoryList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const CategoryGrid = () => {
}
return (
<Grid container spacing={2} sx={{ marginTop: '1em' }}>
{data?.map(record => (
{data.map(record => (
<Grid key={record.id} xs={12} sm={6} md={4} lg={3} xl={2} item>
<Card>
<CardMedia
Expand Down
8 changes: 4 additions & 4 deletions packages/ra-core/src/controller/list/useListController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ const defaultSort = {

export interface ListControllerResult<RecordType extends RaRecord = any> {
sort: SortPayload;
data?: RecordType[];
data: RecordType[];
defaultTitle?: string;
displayedFilters: any;
error?: any;
Expand All @@ -231,9 +231,9 @@ export interface ListControllerResult<RecordType extends RaRecord = any> {
setPerPage: (page: number) => void;
setSort: (sort: SortPayload) => void;
showFilter: (filterName: string, defaultValue: any) => void;
total?: number;
hasNextPage?: boolean;
hasPreviousPage?: boolean;
total: number;
hasNextPage: boolean;
hasPreviousPage: boolean;
}

export const injectedProps = [
Expand Down

0 comments on commit 156eeb1

Please sign in to comment.