-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RTL: Fix left/right alignments of blocks #3911
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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 😄 👍
@@ -366,7 +366,7 @@ | |||
} | |||
} | |||
|
|||
// 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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To compensate for what? I think this comment is incomplete.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tofumatt - can you update this comment yourself and merge this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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: