fix: logical fixes in Pagination component #479
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
SUMMARY:
Currently if we have only 1 page, the jumper is still shown in pagination.
In pagination component, we have a check to show jumper component only when there is more than one page. But the variable was initialised using number of elements rather than number of pages. This PR fixes the issue.
Changes are made to include max and min values for Text Input component so that we can limit the count in Pagination component
Changes are made to display page Sizes section if number of pages is greater than 1 for at least one of the page sizes
JIRA TASK (Eightfold Employees Only):
https://eightfoldai.atlassian.net/browse/ENG-38825
CHANGE TYPE:
TEST COVERAGE:
TEST PLAN:
You can use the following component from story book site