RTL: Fix left/right alignments of blocks#3911
Conversation
youknowriad
left a comment
There was a problem hiding this comment.
Thanks for working on this. While in master the block alignments are reverted, they work correctly. In this PR the block alignment is broken (they show up out of the "centered" area)
|
@yoavf do you plan to finish this PR or should someone else take it over? |
|
@gziolo on it - updated the pr |
886cda1 to
16e8846
Compare
|
Hey @yoavf, looks like there are a few conflicts here now but if you can update the branch and fix the conflicts I promise to review this ASAP (feel free to assign/ping me for review once it's updated) 😄 Sorry about not getting to this one 😞 |
9ed17ab to
bec80de
Compare
bec80de to
1e0bef3
Compare
… add positioning for [data-align='left'] as well so that it's mirrored correctly
|
Tested in few blocks (image, gallery, paragraph, list, table) and all works well. |
This seems fixed with the latest changes here. Anything else blocking this? |
tofumatt
left a comment
There was a problem hiding this comment.
All looks good and works for me.
A few minor nitpicks with the comments, but feel free to address them as you feel appropriate and then get this merged 😄 👍
| } | ||
|
|
||
| // The padding collapses, but the outline is still 1px to compensate for. | ||
| // The padding collapses, but the outline is still 1px to compensate for. |
There was a problem hiding this comment.
To compensate for what? I think this comment is incomplete.
There was a problem hiding this comment.
@tofumatt - can you update this comment yourself and merge this PR?
There was a problem hiding this comment.
Totally, will do!
EDIT: I forgot about this PR and realised my issue is I have no idea what this means, but I'll figure it out and address...
| @@ -375,19 +375,24 @@ | |||
| // Left | |||
| &[data-align="left"] { | |||
| .editor-block-list__block-edit { // This is in the editor only, on the frontend, the img should be floated | |||
There was a problem hiding this comment.
I know it's not part of this PR but that's a weird indentation/comment placement, if anymore edits are made it'd be nice to tidy it up 😉
Issues reported were fixed with a later commit.
Description
Prevent RTLCSS from reversing specific CSS rules related to left/right alignment of blocks
Similar to #3909, necessry after #3844
Without this change, left aligning a block puts on the right and vice versa.
Types of changes
CSS comments to prevent automatic flipping of CSS properties.
Checklist: