diff --git a/app/assets/stylesheets/common/base/compose.scss b/app/assets/stylesheets/common/base/compose.scss index 6584fc3b5..f4f7dad9d 100644 --- a/app/assets/stylesheets/common/base/compose.scss +++ b/app/assets/stylesheets/common/base/compose.scss @@ -140,3 +140,12 @@ div.ac-wrap { top: 20%; } } + +// this removes the topmost margin from the first element in the topic post +// if we don't do this, all posts would have extra space at the top +#wmd-preview > *:first-child { + margin-top: 0; +} +.cooked > *:first-child { + margin-top: 0; +} diff --git a/app/assets/stylesheets/common/base/topic-post.scss b/app/assets/stylesheets/common/base/topic-post.scss index 38a24bd6e..53f911cef 100644 --- a/app/assets/stylesheets/common/base/topic-post.scss +++ b/app/assets/stylesheets/common/base/topic-post.scss @@ -173,3 +173,12 @@ kbd * * { display: none; } } + +// we assume blockquotes have their own margins, so all blockquotes +// will remove margins from first (top) and last (bottom) child elements +blockquote > *:first-child { + margin-top: 0 !important; +} +blockquote > *:last-child { + margin-bottom: 0 !important; +} diff --git a/app/assets/stylesheets/desktop/compose.scss b/app/assets/stylesheets/desktop/compose.scss index e326531bf..5c9032b74 100644 --- a/app/assets/stylesheets/desktop/compose.scss +++ b/app/assets/stylesheets/desktop/compose.scss @@ -349,11 +349,6 @@ bottom: 48px; top: 50px; - // this removes the topmost margin; - // if we don't have this, all posts would have extra space at the top - #wmd-preview > *:first-child { - margin-top: 0 !important; - } #wmd-input, #wmd-preview-scroller, #wmd-preview { box-sizing: border-box; diff --git a/app/assets/stylesheets/desktop/topic-post.scss b/app/assets/stylesheets/desktop/topic-post.scss index bb9581145..c66397066 100644 --- a/app/assets/stylesheets/desktop/topic-post.scss +++ b/app/assets/stylesheets/desktop/topic-post.scss @@ -243,8 +243,8 @@ nav.post-controls { } .topic-avatar { - width: 45px; - padding-left: 15px; + padding-left: 15px; + padding-top: 0; } // bottom means "reply expansion" below a post @@ -646,16 +646,6 @@ blockquote { a.mention {background: darken(scale-color-diff(), 10%);} } -// we assume blockquotes have their own margins, so all blockquotes -// will remove margins from first (top) and last (bottom) child elements -blockquote > *:first-child { - margin-top: 0 !important; -} -blockquote > *:last-child { - margin-bottom: 0 !important; -} - - /* quotes with attribution */ .quote { &>blockquote { diff --git a/app/assets/stylesheets/mobile/topic-post.scss b/app/assets/stylesheets/mobile/topic-post.scss index a0ca378f1..133a0fcce 100644 --- a/app/assets/stylesheets/mobile/topic-post.scss +++ b/app/assets/stylesheets/mobile/topic-post.scss @@ -423,15 +423,6 @@ blockquote { margin-right: 0; } -// we assume blockquotes have their own margins, so all blockquotes -// will remove margins from first (top) and last (bottom) child elements -blockquote > *:first-child { - margin-top: 0 !important; -} -blockquote > *:last-child { - margin-bottom: 0 !important; -} - .gutter { display: none; } .posts-wrapper { position: relative; }