-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: preferences for pagination in table widget #1890
- Loading branch information
1 parent
f2662cc
commit 8072232
Showing
4 changed files
with
45 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
packages/dashboard/src/customization/widgets/table/table-config.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,19 @@ | ||
export const DEFAULT_PREFERENCES = { | ||
pageSize: 20, | ||
}; | ||
|
||
export const pageSizePreference = { | ||
title: 'Select page size', | ||
options: [ | ||
{ value: 10, label: '10 resources' }, | ||
{ value: 20, label: '20 resources' }, | ||
{ value: 30, label: '30 resources' }, | ||
], | ||
}; | ||
|
||
export const collectionPreferencesProps = { | ||
pageSizePreference, | ||
cancelLabel: 'Cancel', | ||
confirmLabel: 'Confirm', | ||
title: 'Preferences', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters