Skip to content

DataViews: Regression in DataViews pagination, On next page it does not increment count, instead it's concatenation#73131

Closed
hbhalodia wants to merge 2 commits intoWordPress:trunkfrom
hbhalodia:fix/issue-73129-dataviews-pagination
Closed

DataViews: Regression in DataViews pagination, On next page it does not increment count, instead it's concatenation#73131
hbhalodia wants to merge 2 commits intoWordPress:trunkfrom
hbhalodia:fix/issue-73129-dataviews-pagination

Conversation

@hbhalodia
Copy link
Contributor

What?

Closes #73129

Why?

  • Fixes the DataViews pagination.
  • Regression from - af3d47d

How?

  • Update the useView hook, to typecast the page to Number coming from query params.
  • This is added because, when taking the page from queryParam it is coming as a string, hence on next page it concatenates instead of incrementation, while for previous page, string - Number typecast to a Number, hence prev page is working as expected.

Testing Instructions

  1. Go to editor -> pages
  2. Navigate via pagiantion.
  3. Pagination works as expected.

Testing Instructions for Keyboard

  • None

Screenshots or screencast

Screen.Recording.2025-11-10.at.2.51.03.PM.mov

@hbhalodia hbhalodia requested a review from t-hamano November 10, 2025 09:23
@hbhalodia hbhalodia self-assigned this Nov 10, 2025
@hbhalodia hbhalodia 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 10, 2025
@github-actions
Copy link

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: hbhalodia <hbhalodia@git.wordpress.org>
Co-authored-by: t-hamano <wildworks@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@hbhalodia
Copy link
Contributor Author

Closing the PR in favor of - #73132

@hbhalodia hbhalodia closed this Nov 10, 2025
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 [Type] Bug An existing feature does not function as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DataViews: Regression in DataViews pagination, On next page it does not increment count, instead it's concatenation

1 participant