Use a bullet instead of empty margin when score is hidden

This is prettier and keeps consistency across the app.
This commit is contained in:
gmnsii 2023-03-23 11:29:28 -07:00
parent f8ba3cf815
commit e3b1c5b587
9 changed files with 39 additions and 17 deletions

View File

@ -1,6 +1,4 @@
use std::{ use std::process::{Command, ExitStatus, Output};
process::{Command, ExitStatus, Output},
};
#[cfg(not(target_os = "windows"))] #[cfg(not(target_os = "windows"))]
use std::os::unix::process::ExitStatusExt; use std::os::unix::process::ExitStatusExt;

View File

@ -5,9 +5,13 @@
{% else if kind == "t1" %} {% else if kind == "t1" %}
<div id="{{ id }}" class="comment"> <div id="{{ id }}" class="comment">
<div class="comment_left"> <div class="comment_left">
<p class="comment_score" title="{{ score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<p class="comment_score" title="{{ score.1 }}">{{ score.0 }}</p> {{ score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
</p>
<div class="line"></div> <div class="line"></div>
</div> </div>
<details class="comment_right" {% if !collapsed || highlighted %}open{% endif %}> <details class="comment_right" {% if !collapsed || highlighted %}open{% endif %}>

View File

@ -83,9 +83,13 @@
<a href="{{ post.permalink }}">{{ post.title }}</a>{% if post.flags.nsfw %} <small class="nsfw">NSFW</small>{% endif %} <a href="{{ post.permalink }}">{{ post.title }}</a>{% if post.flags.nsfw %} <small class="nsfw">NSFW</small>{% endif %}
</h2> </h2>
<div class="post_score" title="{{ post.score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<div class="post_score" title="{{ post.score.1 }}">{{ post.score.0 }}<span class="label"> Upvotes</span></div> {{ post.score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
<span class="label"> Upvotes</span></div>
<div class="post_footer"> <div class="post_footer">
<a href="{{ post.permalink }}" class="post_comments" title="{{ post.comments.1 }} comments">{{ post.comments.0 }} comments</a> <a href="{{ post.permalink }}" class="post_comments" title="{{ post.comments.1 }} comments">{{ post.comments.0 }} comments</a>
</div> </div>

View File

@ -77,9 +77,13 @@
{% else %} {% else %}
<div class="comment"> <div class="comment">
<div class="comment_left"> <div class="comment_left">
<p class="comment_score" title="{{ post.score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<p class="comment_score" title="{{ post.score.1 }}">{{ post.score.0 }}</p> {{ post.score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
</p>
<div class="line"></div> <div class="line"></div>
</div> </div>
<details class="comment_right" open> <details class="comment_right" open>

View File

@ -52,9 +52,13 @@
{% else %} {% else %}
<div class="comment"> <div class="comment">
<div class="comment_left"> <div class="comment_left">
<p class="comment_score" title="{{ post.score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<p class="comment_score" title="{{ post.score.1 }}">{{ post.score.0 }}</p> {{ post.score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
</p>
<div class="line"></div> <div class="line"></div>
</div> </div>
<details class="comment_right" open> <details class="comment_right" open>

View File

@ -147,9 +147,13 @@
<!-- POST BODY --> <!-- POST BODY -->
<div class="post_body">{{ post.body|safe }}</div> <div class="post_body">{{ post.body|safe }}</div>
<div class="post_score" title="{{ post.score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<div class="post_score" title="{{ post.score.1 }}">{{ post.score.0 }}<span class="label"> Upvotes</span></div> {{ post.score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
<span class="label"> Upvotes</span></div>
<div class="post_footer"> <div class="post_footer">
<ul id="post_links"> <ul id="post_links">
<li class="desktop_item"><a href="{{ post.permalink }}">permalink</a></li> <li class="desktop_item"><a href="{{ post.permalink }}">permalink</a></li>
@ -269,9 +273,13 @@
<span>{% if post.post_type == "link" %}{{ post.domain }}{% else %}{{ post.post_type }}{% endif %}</span> <span>{% if post.post_type == "link" %}{{ post.domain }}{% else %}{{ post.post_type }}{% endif %}</span>
</a> </a>
{% endif %} {% endif %}
<div class="post_score" title="{{ post.score.1 }}">
{% if prefs.hide_score != "on" %} {% if prefs.hide_score != "on" %}
<div class="post_score" title="{{ post.score.1 }}">{{ post.score.0 }}<span class="label"> Upvotes</span></div> {{ post.score.0 }}
{% else %}
&#x2022;
{% endif %} {% endif %}
<span class="label"> Upvotes</span></div>
<div class="post_body post_preview"> <div class="post_body post_preview">
{{ post.body|safe }} {{ post.body|safe }}
</div> </div>