From 023fc50ae79ce2dc7ff5c728ac8af652af1ef5b6 Mon Sep 17 00:00:00 2001 From: psychobunny Date: Mon, 21 Sep 2020 14:20:04 -0400 Subject: [PATCH] feat: some persona variables for topic list --- less/modules/necro-post.less | 4 ++-- less/persona.less | 2 ++ less/topic.less | 20 ++++++++++---------- less/variables.less | 7 +++++++ 4 files changed, 21 insertions(+), 12 deletions(-) create mode 100644 less/variables.less diff --git a/less/modules/necro-post.less b/less/modules/necro-post.less index 85770f1..c064a1f 100644 --- a/less/modules/necro-post.less +++ b/less/modules/necro-post.less @@ -1,4 +1,4 @@ .topic .necro-post { - border-bottom: 1px solid @gray-lighter; - padding-bottom: 20px; + border-bottom: 1px solid @post-border-color; + padding-bottom: @post-padding; } \ No newline at end of file diff --git a/less/persona.less b/less/persona.less index b8342a7..5ab9176 100644 --- a/less/persona.less +++ b/less/persona.less @@ -1,3 +1,5 @@ +@import "variables"; + @import "style"; @import "topic"; diff --git a/less/topic.less b/less/topic.less index 71dc3e8..54c5880 100644 --- a/less/topic.less +++ b/less/topic.less @@ -106,7 +106,7 @@ top: -2px; right: 6px; font-size: 16px; - color: darken(@brand-info, 20%); + color: darken(@post-highlight, 20%); opacity: 0; .transition(0.75s ease-in-out opacity); } @@ -119,7 +119,7 @@ [component="post/anchor"] { position: relative; - top: -20px; /* 20px used here as that is the bottom margin of the hr in between posts */ + top: -@post-padding; } [component="post/upvote"], [component="post/downvote"] { @@ -192,7 +192,7 @@ [component="post/replies"] { margin-left: 61px; - margin-top: 20px; + margin-top: @post-padding; border-left: 5px solid #eee; padding-left: 20px; @@ -224,7 +224,7 @@ } .content { - margin-top: 20px; + margin-top: @post-padding; padding-bottom: 1px; margin-top: -43px; margin-left: 61px; @@ -259,7 +259,7 @@ .tags { vertical-align: -40%; - margin-bottom: 20px; + margin-bottom: @post-padding; } h1 { @@ -385,9 +385,9 @@ [component="post"] { position: relative; - border-bottom: 1px solid @gray-lighter; - padding-bottom: 20px; - margin-bottom: 20px; + border-bottom: 1px solid @post-border-color; + padding-bottom: @post-padding; + margin-bottom: @post-padding; .transition(0.75s ease-in-out border-color); @@ -406,8 +406,8 @@ } &.highlight { - border-color: darken(@brand-info, 20%); - box-shadow: 0px 2px 2px -2px @brand-info; + border-color: darken(@post-highlight, 20%); + box-shadow: 0px 2px 2px -2px @post-highlight; .bookmarked { opacity: 1; diff --git a/less/variables.less b/less/variables.less new file mode 100644 index 0000000..2e7a699 --- /dev/null +++ b/less/variables.less @@ -0,0 +1,7 @@ +//== Topic List +// +//## Post objects found on the category, recent, popular, etc. pages + +@post-padding: 20px; +@post-border-color: @gray-lighter; +@post-highlight: @brand-info; \ No newline at end of file