From bfa64547e8fa2297191ed9c8f7c265a1cd43dcce Mon Sep 17 00:00:00 2001 From: Terry Geng Date: Fri, 20 Mar 2020 21:28:00 +0800 Subject: [PATCH] fix: button confusion --- interface.py | 7 +++++-- static/css/custom.css | 15 +++++++-------- templates/index.html | 33 +++++++++++++++++---------------- 3 files changed, 29 insertions(+), 26 deletions(-) diff --git a/interface.py b/interface.py index 4b152c6..8056606 100644 --- a/interface.py +++ b/interface.py @@ -223,7 +223,10 @@ def post(): if music_wrapper: var.playlist.insert(var.playlist.current_index + 1, music_wrapper) log.info('web: add to playlist(next): ' + music_wrapper.format_debug_string()) - var.bot.interrupt() + if not var.bot.is_pause: + var.bot.interrupt() + else: + var.bot.is_pause = False else: abort(404) @@ -475,7 +478,7 @@ def library(): result['title'] = item.title result['type'] = item.display_type() result['tags'] = [(tag, tag_color(tag)) for tag in item.tags] - if item.thumbnail: + if item.type != 'radio' and item.thumbnail: result['thumb'] = f"data:image/PNG;base64,{item.thumbnail}" else: result['thumb'] = "static/image/unknown-album.png" diff --git a/static/css/custom.css b/static/css/custom.css index 372e1ca..77422b6 100644 --- a/static/css/custom.css +++ b/static/css/custom.css @@ -75,17 +75,16 @@ .library-thumb-btn-up { position: absolute !important; top: 0; - height: 35px; - padding-top: 5px; + height: 70px; + font-size: 2em; + padding-top: 10px; } -.library-thumb-btn-down { - position: absolute !important; - top: 35px; - height: 35px; - padding-top: 5px; +.library-btn-svg { + width: 1rem; + fill: currentColor; } .library-info-col { - margin-right: 2rem; + margin-right: 1rem; padding: 3px 0; display: flex; flex-direction: column; diff --git a/templates/index.html b/templates/index.html index 5003da8..62ad287 100644 --- a/templates/index.html +++ b/templates/index.html @@ -126,7 +126,7 @@
- +
@@ -179,15 +179,8 @@
-
- - - -
-
- - - +
+
@@ -209,8 +202,16 @@
- +