-
Notifications
You must be signed in to change notification settings - Fork 94
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
Remove bottom margin for better warning blocks display #5310
Remove bottom margin for better warning blocks display #5310
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 the contribution. Small comment inside as I think the rule is applying to widely.
7315944
to
411a0e0
Compare
@juliushaertl please check my new commit (old and new commit have been squashed) |
Testing by your side is welcome |
src/css/prosemirror.scss
Outdated
@@ -103,6 +103,10 @@ div.ProseMirror { | |||
line-height: 150%; | |||
} | |||
|
|||
.callout p .paragraph-content { |
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.
We should still only do this for the last p element within a callout and please move this style to the actual callout vue component linked earlier
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'm sorry @juliushaertl, but what is the actual linked callout vue component you're talking about ?
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.
@Jerome-Herbinet https://github.com/nextcloud/text/blob/main/src/nodes/CodeBlockView.vue is the component @juliushaertl is talking about.
See the <style>
block at the end of this file. There you can overwrite the behaviour for p .paragraph-content
, but as @juliushaertl said it should only be done if it's the last p
element.
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 your answer @mejo- but there is no p .paragraph-content
css property to overwrite in https://github.com/nextcloud/text/blob/main/src/nodes/CodeBlockView.vue <style>
block π€
411a0e0
to
a7ae981
Compare
a7ae981
to
dd1e1d4
Compare
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.
Turned out Callout.vue
already had a rule to remove margin-bottom
for the last child, but it was broken. I took the liberty to push a fix for this.
Fixes: nextcloud/collectives#1175 Signed-off-by: JΓ©rΓ΄me Herbinet <33763786+Jerome-Herbinet@users.noreply.github.com> Signed-off-by: Jonas <jonas@freesources.org>
dd1e1d4
to
9ca90fc
Compare
/backport to stable28 |
Hello there, We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 Thank you for contributing to Nextcloud and we hope to hear from you soon! |
This CSS change removes the extra bottom padding (which is in fact a paragraph bottom margin).
It makes text more compact, which is IMO relevant because warning blocks aim to be compact.
ποΈ Before
π‘ After
Fixes: nextcloud/collectives#1175
π Checklist
npm run lint
/npm run stylelint
/composer run cs:check
)