-
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
Fix style comment awaiting moderation indentation #40681
Conversation
Size Change: +161 B (0%) Total Size: 1.23 MB
ℹ️ View Unchanged
|
I thought about it, but maybe changing that will affect all current Block themes that are using Comments. I guess theme developers handled this issue before, so we may force them to update all themes if we now remove that padding. Adding the positive margin feels like a patch to be honest, but at least we are not affecting a really common div.
That way looks much better. |
This would only be the case if a block theme used the comments query loop block, and added custom CSS to override parts of this, correct? If yes, then I wouldn't worry too much about changing that, I think it's important we move towards the best code structure when we can. Or is this code ported from the classic comments loop? |
Not sure I'm understanding the question entirely correctly, but this styling is for the ("monolithic") Post Comments block, which is basically a thin wrapper around WP's (It's unrelated to the new "modularized" Comments Query Loop block, although we did find this issue when working on that block.) |
Ah, thank you for the clarification. Still, thinking in terms of the styles output by packages/block-library/src/post-comments/style.scss on the frontend, the margin/padding changes could be argued as being in the bugfix category, and would work fine even for TwentyTwentyTwo on updating the plugin or major WordPress version, assuming TT2 or any other theme using it relies on that particular margin and padding for some other custom styles. In other words, it seems like the potential breakage of refactoring the code would be minimal, and therefore probably good to fix the issue. Not a strong opinion, but just a general opportunity to improve the code, perhaps! |
Nice! Thank you. I'm unable to test at this point, but the code seems good, and looks like what I tried in the inspector. 👍 👍 on my part |
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 Carlos and Joen!
@adamziel This one would also be great to get into Beta 4, if possible 😊 |
I cherry picked this change into |
What?
Fixed indentation on
Post Comments Block
of the moderation warning message.Testing Instructions
Screenshots or screencast
Before:
![Screenshot 2022-04-28 at 13 13 35](https://user-images.githubusercontent.com/37012961/165740423-b61d73ff-8f11-4d71-91ba-ef895b83ecb2.png)
After:
![Screenshot 2022-04-28 at 13 12 21](https://user-images.githubusercontent.com/37012961/165740449-c19175ad-afd7-449b-b379-fbdf74e8d762.png)