Revert "Make the stars look consistent across platforms"
authorAlex Chan <alex@alexwlchan.net>
Wed, 16 Dec 2020 19:33:15 +0000 (19:33 +0000)
committerAlex Chan <alex@alexwlchan.net>
Wed, 16 Dec 2020 19:33:15 +0000 (19:33 +0000)
This reverts commit 20b9ffd734edce0d246f24f46cc1cf03c6d8fe68.

static/0star.svg [deleted file]
static/1star.svg [deleted file]
static/2star.svg [deleted file]
static/3star.svg [deleted file]
static/4star.svg [deleted file]
static/5star.svg [deleted file]
static/style.css
templates/_review_entry.html

diff --git a/static/0star.svg b/static/0star.svg
deleted file mode 100644 (file)
index c541e96..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
diff --git a/static/1star.svg b/static/1star.svg
deleted file mode 100644 (file)
index c0c5bdb..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
diff --git a/static/2star.svg b/static/2star.svg
deleted file mode 100644 (file)
index 66b1a77..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
diff --git a/static/3star.svg b/static/3star.svg
deleted file mode 100644 (file)
index 6b0d9c9..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
diff --git a/static/4star.svg b/static/4star.svg
deleted file mode 100644 (file)
index f2bcc14..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="none" stroke="#000" stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
diff --git a/static/5star.svg b/static/5star.svg
deleted file mode 100644 (file)
index ac47605..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="1585" height="240" viewBox="0 0 330 48">
-
-<svg x="0">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="70">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="140">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="210">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-<svg x="280">
-    <path fill="#000" stroke="#000" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"/>
-</svg>
-
-</svg>
\ No newline at end of file
index dabadaf..5dea87f 100644 (file)
@@ -166,7 +166,7 @@ footer a:hover {
   background: rgba(0, 255, 221, 0.3);
 }
 
   background: rgba(0, 255, 221, 0.3);
 }
 
-.review_preview .book_thumbnail img, .reading_inner .book_thumbnail img {
+.review_preview img, .reading_inner img {
   max-width: 110px;
   max-height: 130px;
   margin-top: 12px;
   max-width: 110px;
   max-height: 130px;
   margin-top: 12px;
@@ -251,9 +251,6 @@ footer a:hover {
 }
 
 .star_rating {
 }
 
 .star_rating {
-  margin-top: 1px;
-}
-
-.star_rating img {
-  height: 0.9em;
+  font-size: 140%;
+  letter-spacing: 4px;
 }
 }
index 3a2fce5..4c6238d 100644 (file)
@@ -48,10 +48,18 @@ id="review_preview_{{ r }}_{{ g }}_{{ b }}">
           read {{ review_entry.review.date_read | render_date }}
             <br/>
           {% endif %}
           read {{ review_entry.review.date_read | render_date }}
             <br/>
           {% endif %}
-          <div class="star_rating">
-            <img src="/static/{{ review_entry.review.rating }}star.svg">
-          </div>
         </small>
         </small>
+
+        <span class="star_rating">
+        {% if review_entry.review.rating %}
+          {% for _ in range(review_entry.review.rating) -%}
+          ★
+          {%- endfor -%}
+          {%- for _ in range(5 - review_entry.review.rating) -%}
+          ☆
+          {%- endfor %}
+        {% endif %}
+        </span>
         {% if review_entry.review.did_not_finish %}
           (did not finish)
         {% endif %}
         {% if review_entry.review.did_not_finish %}
           (did not finish)
         {% endif %}