Skip to content

[6.x] Prevent layout change when reordering grid rows#13862

Open
duncanmcclean wants to merge 1 commit into6.xfrom
reordering-grid-rows
Open

[6.x] Prevent layout change when reordering grid rows#13862
duncanmcclean wants to merge 1 commit into6.xfrom
reordering-grid-rows

Conversation

@duncanmcclean
Copy link
Member

This PR fixes an issue when reordering stacked Grid rows, where fields with percentage widths would temporarily expand to full width while dragging.

This was happening because the drag mirror is appended to the body, losing the @container/panel ancestor which provides the container query context for field widths. Without it, the @lg/panel` variant doesn't apply and fields default to full-width.

This PR fixes it by adding the @container/panel class directly to the stacked row, so the container context is included when the element is cloned from the drag mirror.

Fixes #13817

Before

CleanShot.2026-02-09.at.12.45.59.mp4

After

CleanShot.2026-02-09.at.12.45.30.mp4

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.

Reorder grid rows changes field layout while dragging

1 participant