aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel Ángel Moreno <mail@migalmoreno.com>2024-12-02 08:33:44 +0100
committerMiguel Ángel Moreno <mail@migalmoreno.com>2024-12-02 08:33:44 +0100
commit001e250a85472f081622056d5d01f27916fcaa92 (patch)
tree3620924423af485d33699e0bb168474e840cfd0e
parent9078a104240789f0bd2afcb7a65742d5a387b372 (diff)
feat: only show tags container if these exist
-rw-r--r--src/frontend/tubo/stream/views.cljs11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/frontend/tubo/stream/views.cljs b/src/frontend/tubo/stream/views.cljs
index 25fc7a0..18dd603 100644
--- a/src/frontend/tubo/stream/views.cljs
+++ b/src/frontend/tubo/stream/views.cljs
@@ -93,11 +93,12 @@
:main-player/toggle-layout
:stream/toggle-layout)
:show-description])]
- [:div.flex.gap-2.py-2.flex-wrap
- (for [[i tag] (map-indexed vector tags)]
- ^{:key i}
- [:span.bg-neutral-300.dark:bg-neutral-700.rounded-lg.px-2.py-1.text-xs.line-clamp-1
- (str "#" tag)])]])))
+ (when-not (empty? tags)
+ [:div.flex.gap-2.py-2.flex-wrap
+ (for [[i tag] (map-indexed vector tags)]
+ ^{:key i}
+ [:span.bg-neutral-300.dark:bg-neutral-700.rounded-lg.px-2.py-1.text-xs.line-clamp-1
+ (str "#" tag)])])])))
(defn comments
[{:keys [comments-page show-comments show-comments-loading] :as stream}]