From e96606eba3e1923a83de390944abe5e87e0ffc23 Mon Sep 17 00:00:00 2001 From: Cynthia Foxwell Date: Thu, 13 Nov 2025 20:58:04 -0700 Subject: [PATCH] cleanup stats --- src/views/tweet.nim | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/views/tweet.nim b/src/views/tweet.nim index b604522..2927267 100644 --- a/src/views/tweet.nim +++ b/src/views/tweet.nim @@ -195,16 +195,14 @@ func formatStat(stat: int): string = proc renderStats(stats: TweetStats; tweet: Tweet): VNode = buildHtml(tdiv(class="tweet-stats")): - a(): - span(class="tweet-stat"): icon "comment", formatStat(stats.replies) - a(): - span(class="tweet-stat"): icon "retweet", formatStat(stats.retweets) - a(href="/search?q=quoted_tweet_id:" & $tweet.id): + span(class="tweet-stat", title="Replies", "aria-label"="Replies"): icon "comment", formatStat(stats.replies) + span(class="tweet-stat", title="Reposts", "aria-label"="Reposts"): icon "retweet", formatStat(stats.retweets) + a(href="/search?q=quoted_tweet_id:" & $tweet.id, title="Quotes", "aria-label"="Quotes"): span(class="tweet-stat"): icon "quote", formatStat(stats.quotes) - a(): span(class="tweet-stat"): icon "heart", formatStat(stats.likes) - a(): span(class="tweet-stat"): icon "bookmark", formatStat(stats.bookmarks) + span(class="tweet-stat", title="Likes", "aria-label"="Likes"): icon "heart", formatStat(stats.likes) + span(class="tweet-stat", title="Bookmarks", "aria-label"="Bookmarks"): icon "bookmark", formatStat(stats.bookmarks) if stats.views > -1: - a(): span(class="tweet-stat"): icon "eye", formatStat(stats.views) + span(class="tweet-stat", title="Views", "aria-label"="Views"): icon "eye", formatStat(stats.views) proc renderReply(tweet: Tweet): VNode = buildHtml(tdiv(class="replying-to")):