diff --git a/dist/css/styles.css b/dist/css/styles.css index 098e6fd..5388a7e 100644 --- a/dist/css/styles.css +++ b/dist/css/styles.css @@ -430,6 +430,9 @@ header .tabmenu li.active a { margin-left: 15px; margin-top: 8px; } +.green { + color: green !important; +} input[type="submit"], .btn { padding: 3px; diff --git a/inc/processJsonSubreddit.js b/inc/processJsonSubreddit.js index 448b12d..7ee3edf 100644 --- a/inc/processJsonSubreddit.js +++ b/inc/processJsonSubreddit.js @@ -70,6 +70,7 @@ module.exports = function() { ups: data.ups, upvote_ratio: data.upvote_ratio, url: data.url, + stickied: data.stickied, is_self_link: is_self_link, subreddit_front: subreddit_front, before: before, diff --git a/views/subreddit.pug b/views/subreddit.pug index 36050b9..c040e2c 100644 --- a/views/subreddit.pug +++ b/views/subreddit.pug @@ -82,11 +82,11 @@ html .title if link.is_self_link a(href="" + link.permalink + "") - h2 #{cleanTitle(link.title)} + h2(class="" + (link.stickied ? 'green' : '') + "") #{cleanTitle(link.title)} span (#{link.domain}) else a(href="" + link.url + "") - h2 #{cleanTitle(link.title)} + h2(class="" + (link.stickied ? 'green' : '') + "") #{cleanTitle(link.title)} span (#{link.domain}) .meta p.submitted submitted @@ -96,6 +96,8 @@ html p.to to a(href="/r/" + link.subreddit + "") | #{link.subreddit} + if link.stickied + span(class="green") stickied p.comments a(href="" + link.permalink + "", class="comments") | #{link.num_comments} comments