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

fix: reset page number on tab switch #2862

Merged
merged 2 commits into from
Feb 20, 2023

Conversation

BiswaViraj
Copy link
Contributor

What change does this PR introduce?

  • Resets the page number on tab switch on the changes page

Why was this change needed?

Other information (Screenshots)

@linear
Copy link

linear bot commented Feb 20, 2023

NV-1740 Changes table has page number synced for both `Pending` and `History` tables

Why? (Context)

  • Visit changes table
  • Goto page 2 for example.
  • Switch the tab to History
  • You'll see it renders with the page number 2.

What?

Definition of Done

9d0dfbf6-d3f2-46c8-8677-200f3d75330c

@@ -43,6 +43,7 @@ export function PromoteChangesPage() {
value: PENDING,
content: (
<ChangesTable
key={page}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The page number indicator at the bottom of the page sometimes will be out of sync with the current page number,
Adding a key fixed that issue

@BiswaViraj BiswaViraj added this pull request to the merge queue Feb 20, 2023
Merged via the queue into next with commit 701e172 Feb 20, 2023
@BiswaViraj BiswaViraj deleted the nv-1740-changes-table-has-page-number-synced-for branch February 20, 2023 10:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants