| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
There was a problem hiding this comment.
Hi. Can you update the title of the PR to be more descriptive please. Thanks!
Sorry, something went wrong.
|
PatternFly-React preview: https://patternfly-react-pr-3182.surge.sh |
Sorry, something went wrong.
Codecov Report
@@ Coverage Diff @@
## master #3182 +/- ##
==========================================
- Coverage 67.52% 67.52% -0.01%
==========================================
Files 896 896
Lines 25112 25133 +21
Branches 2173 2178 +5
==========================================
+ Hits 16958 16971 +13
- Misses 7141 7147 +6
- Partials 1013 1015 +2
Continue to review full report at Codecov.
|
Sorry, something went wrong.
There was a problem hiding this comment.
How are these utils used with the pagination component?
I'm also curious how does this solve #1567 (e.g., using an offset). There is no example showing usage?
Ideally, the pagination component would be able to figure out what page you're on based on the total available rows and number of items per page.
Sorry, something went wrong.
There was a problem hiding this comment.
I left a few questions/comments, looking good. On first pass, it seems to improve the intro-table tutorial quite a bit - excited to get this in!
Sorry, something went wrong.
There was a problem hiding this comment.
Sorry, something went wrong.
| const inputPage = Navigation.parseInteger(this.state.userInputPage, lastPage) as number; | ||
| onPageInput(event, Number.isNaN(inputPage) ? (page as number) : inputPage); | ||
| onSetPage(event, Number.isNaN(inputPage) ? (page as number) : inputPage); | ||
| this.handleNewPage(event, Number.isNaN(inputPage) ? (page as number) : inputPage); |
There was a problem hiding this comment.
I wonder if there's a better way of handling that page here could be a string or a number. Could we instead cast it to a number in the place where it returns a string so we can avoid having to use as number type assertion in so many places? No worries if not, just curious in case it's an easy improvement.
Sorry, something went wrong.
…and onPerPageSelect
…d handle pagination overflow. Fix for patternfly#3136
… handle pagination overflow. Fix for patternfly#3136
…o Navigation and PaginationOptionsMenu. onSetPage and onPerPageSelect now return 5 values each for use in automating pagination
…uilt out new Demo to show functionality
There was a problem hiding this comment.
LGTM. Nice job
Sorry, something went wrong.
| /** Select from options to number of items per page. */ | ||
| perPageOptions?: PerPageOptions[]; | ||
| /** Indicate whether to show last full page of results when user selects perPage value greater than remaining rows */ | ||
| defaultToFullPage?: boolean; |
There was a problem hiding this comment.
Curious if defaultToFullPage is a PatternFly pattern in core? If not, lets double check this behavior with a designer.
Sorry, something went wrong.
There was a problem hiding this comment.
Thanks for calling this out @dlabrecq , doing this now
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM, nice work!
Sorry, something went wrong.
…tch new last page of results when page number is automatically updated
There was a problem hiding this comment.
😁👍
Sorry, something went wrong.
There was a problem hiding this comment.
Love it! Nice work @evwilkin!
Sorry, something went wrong.
|
Your changes have been released in:
Thanks for your contribution! 🎉 |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
What:
fixes #3136
This feature allows the component to automatically paginate the users's data for them, and provides a "defaultToFullPage" flag that will automatically move the user back to the last full page of results when they change the number of rows to view per page.
Additional issues: