Conversation
ea30478 to
7500300
Compare
7500300 to
06bb105
Compare
This comment has been minimized.
This comment has been minimized.
Scopes WC-3548 (custom pagination ignoring Position of pagination), the Data Grid 2 half of the bug WC-3505 fixed for Gallery.
WidgetFooter rendered custom pagination widgets unconditionally and WidgetTopBar never rendered them at all. Both now gate on pagingPosition, mirroring the built-in Pagination control; "both" renders once, in the footer, to avoid duplicating widget instances/DOM ids/state.
Preview always rendered custom pagination in the footer. Split the single useCustomPagination() check into top/bottom variants so the page editor agrees with runtime for every Position of pagination value.
…ination pagingPosition was hidden from the properties panel whenever custom pagination was enabled, a stopgap from when the property had no effect. Now that it does, keep it visible and warn when it's set to "Both" with custom pagination, since that combination renders once, below the grid.
06bb105 to
c0c76b3
Compare
AI Code Review
What was reviewed
Skipped (out of scope): Findings
|
Pull request type
Bug fix (non-breaking change which fixes an issue)
Description
Data Grid 2's "Position of pagination" property already controlled the built-in
Paginationcontrol but had no effect on custom pagination:WidgetFooterrendered the custom pagination widgets unconditionally andWidgetTopBarnever rendered them at all, so "Above grid" silently did nothing. This mirrors the bug fixed for Gallery, which explicitly scoped Data Grid 2 out to keep that PR reviewable — this is that follow-up.Custom pagination now honors
pagingPositionin both runtime and editor preview: top bar for "Above grid", footer for "Below grid", and footer-only (not duplicated) for "Both" — duplicating the widgets placeholder would duplicate widget instances, DOM ids, and state.pagingPositionstays visible in Studio Pro when custom pagination is enabled (previously hidden as a stopgap), and a new design-time warning explains the single-render behavior for "Both".What should be covered while testing?
No XML changes, no docs PR needed. Changelog entry included in this branch.
Ticket: WC-3548