From c6995fcab3e8f2d2db7d4c7647811f0dd038ab2b Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sat, 14 Apr 2018 17:55:57 +0200 Subject: [PATCH] feat(templates): Highlight stickied threads in index --- src/render.rs | 2 ++ templates/index.html | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/render.rs b/src/render.rs index 598d48bce..186b96d24 100644 --- a/src/render.rs +++ b/src/render.rs @@ -58,6 +58,7 @@ impl Message for IndexPage { struct IndexThread { id: i32, title: String, + sticky: bool, posted: FormattedDate, author_name: String, } @@ -71,6 +72,7 @@ impl Handler for Renderer { .map(|thread| IndexThread { id: thread.thread_id, title: escape_html(&thread.title), + sticky: thread.sticky, posted: thread.posted.into(), author_name: thread.thread_author, }) diff --git a/templates/index.html b/templates/index.html index 5fc0d9a77..f499f4047 100644 --- a/templates/index.html +++ b/templates/index.html @@ -25,10 +25,10 @@