Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data View: Pagination error on manual input #55937

Closed
andrewhayward opened this issue Nov 7, 2023 · 0 comments · Fixed by #55940
Closed

Data View: Pagination error on manual input #55937

andrewhayward opened this issue Nov 7, 2023 · 0 comments · Fixed by #55940
Assignees
Labels
[Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@andrewhayward
Copy link
Contributor

Relates to #55083.

What?

When manually entering a page number in the pagination control, an invalid page number incorrectly enables the previous pagination controls, allowing the user to "access" pages below 1.

Expectations

When manually entering a page number, an invalid number should be reset to within range, and the pagination controls should be enabled appropriately:

  • If it is reset to the first page, the previous controls should be disabled.
  • If it is reset to the last page, the next controls should be disabled.
  • If it is reset to both (that is, there is only one page), both the previous and next controls should be disabled.

Reproduction

  1. Navigate to the pagination control, and enter a page number out of range (e.g. 0).
    A set of greyed-out pagination controls, with a text box reading "0"
  2. Note that the value will reset to a number within range (e.g. 1), but that the "First page" and "Previous page" buttons will be enabled.
    A set of pagination controls, the double-left and single-left arrows enabled, with a text box reading "1"
  3. Pressing the "First page" button will reset appropriately to the first page
    A set of greyed-out pagination controls, with a text box reading "1"
  4. Pressing the "Previous page" button will move backwards through non-existent pages
    A set of pagination controls, all enabled, with a text box reading "-7"
manual.pagination.error.mov
@andrewhayward andrewhayward added [Type] Bug An existing feature does not function as intended [Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond labels Nov 7, 2023
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants