Skip to content

Fix/flux filters and footer alignment - #2123

Merged
luanfreitasdev merged 4 commits into
7.xfrom
fix/flux-filters-and-footer-alignment
Aug 13, 2026
Merged

luanfreitasdev merged 4 commits into
7.xfrom
fix/flux-filters-and-footer-alignment

Conversation

@luanfreitasdev

Copy link
Copy Markdown
Member

⚡ PowerGrid - Pull Request

  • Bug fix
  • Enhancement
  • New feature
  • Breaking change

Description

...

Related Issue(s):

Documentation

This PR requires Documentation update?

  • Yes
  • No
  • I have already submitted a Documentation pull request.

Column filters are stripped from $this->columns on dehydration, so a
partial re-render triggered by a filter action (toggle/input/clear) ran
before render() re-attached them, sending an empty pg-filters/inline
filter fragment. Re-resolve the filters in renderOutsideFiltersPartial(),
snapshotting enabledFilters to avoid duplicating the active-filter pills.
- date filter input uses w-full so it fills the grid cell like the text
  filters instead of w-auto
- table rows use text-sm to match the header scale
- footer record-count container is a flex justify-end so 'Showing ...'
  and pagination align to the right
@luanfreitasdev

Copy link
Copy Markdown
Member Author

@virtualtear, can you review this fix?

@virtualtear

virtualtear commented Aug 12, 2026 •

Copy link
Copy Markdown
Contributor

@virtualtear, can you review this fix?

It appears random when clicking the checkboxes, per page and toggling filters.. I can't really get the exact steps to reproduce. After work tomorrow I will also look into it 👍

grafik

Also just encountered this shift.. tho this appears to be even more random to come up.

grafik

Edit:
I was able to reproduce it using these steps:
Open filters -> Select All Checkbox -> Enter a filter for the name... then the filters shift to the image above

The outside-filters partial was wrapped by an extra <div wire:partial> in
structure/table.blade.php on a full render, while partial fragments put
wire:partial on the filter view root (via insertAttributesIntoHtmlRoot).
The two shapes differed by one nesting level, so when a full render
(e.g. select-all checkbox) morphed a DOM last touched by a partial
fragment, morphdom nested the grid inside the previous grid and the
filters collapsed to a single column.

Move wire:partial (and the outsideFilters class) onto the filter view
root and drop the wrapper, so both render paths emit the same root.
renderOutsideFiltersPartial() rebuilt the pg-pagination fragment from the
generic components.structure.footer, while a full render uses
theme_view('footer'). On outside-filter themes that override the footer
(e.g. Flux, with flux:select and a right-aligned record count) the toggle
re-render swapped in the plain markup and the footer lost its styling.
Use theme_view('footer') so both paths emit the same footer.
@virtualtear

Copy link
Copy Markdown
Contributor

Looks good to me now.. did not encounter any layout issues when spam clicking random elements on the page 👍

@luanfreitasdev
luanfreitasdev merged commit 40a8bf6 into 7.x Aug 13, 2026
43 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants