rusackas commented on PR #34562:
URL: https://github.com/apache/superset/pull/34562#issuecomment-4511373841

   Rebased on latest master. The PR scope contracted significantly because 
#39212 replaced `TableView` with the virtualized `GridTable` in 
`SingleQueryResultPane`, so the original explore-side fix and its test are no 
longer applicable (virtualized table doesn't have the "currentPage > 
totalPages" pagination bug).
   
   What survived the rebase:
   - The core `TableView` library fix in `superset-ui-core` — adds a 
`useEffect` that resets `pageIndex` to 0 when filtering reduces data below the 
current page.
   - The accompanying test `should reset to first page when data reduces below 
current page`.
   
   Adjustments made during rebase:
   - Master uses local `useState` for `pageIndex` (not react-table's 
`gotoPage`), so I changed `gotoPage(0)` → `setPageIndex(0)` and updated deps.
   - Master already hoists `effectivePageSize` above the paginationProps memo, 
so my earlier review-nit hoisting commit became a no-op and was dropped — I 
just reuse the existing constant.
   
   The library fix still genuinely benefits any remaining `TableView` callers 
(and is a sensible default-pagination guarantee), so leaving the PR open. 
Squashed down to a single clean commit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to