You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This has broken a couple of our sites by changing the relative parent of some absolute positioned elements. Our theme settings do not even allow for negative margins. In general, it just doesn't seem like good practice to set all containers to relative positioning. This removes a ton of flexibility.
On a broader note, this is another of many examples of over-aggressive CSS changes that unnecessarily break sites and impose a maintenance burden on theme and site developers. Dealing with negative margins could have been dealt with in a way that did not set all Group blocks site-wide to relative positioning. I should not have to worry about the relative parent of my absolute positioned elements spontaneously changing after a WP update.
What is your proposed solution?
Use the style engine to limit relative positioning to Group blocks that actually need it for negative margin handling.
The text was updated successfully, but these errors were encountered:
A little extra context for this issue - @aaronrobertshaw pointed out that the PR for this change included a lot of discussion about adding this relative positioning across all Group blocks. You can find that PR here: #60347.
I have not had a chance to read through all of that conversation. Had I known that PR was in the works before 6.6 released, I would definitely have objected to such an aggressive change.
What problem does this address?
In the last major WP release, all Group blocks (with constrained layout) are given relative positioning. According to the SCSS file, that's because negative margins require it: https://github.com/WordPress/gutenberg/blob/trunk/packages/block-library/src/group/style.scss.
This has broken a couple of our sites by changing the relative parent of some absolute positioned elements. Our theme settings do not even allow for negative margins. In general, it just doesn't seem like good practice to set all containers to relative positioning. This removes a ton of flexibility.
On a broader note, this is another of many examples of over-aggressive CSS changes that unnecessarily break sites and impose a maintenance burden on theme and site developers. Dealing with negative margins could have been dealt with in a way that did not set all Group blocks site-wide to relative positioning. I should not have to worry about the relative parent of my absolute positioned elements spontaneously changing after a WP update.
What is your proposed solution?
Use the style engine to limit relative positioning to Group blocks that actually need it for negative margin handling.
The text was updated successfully, but these errors were encountered: