diff options
author | James Taylor <user234683@users.noreply.github.com> | 2019-12-20 20:50:16 -0800 |
---|---|---|
committer | James Taylor <user234683@users.noreply.github.com> | 2019-12-20 20:52:01 -0800 |
commit | 4b6efb0e0baa290eaa43a01f672e22c1460ed6ea (patch) | |
tree | b4cbebc73526f63227ee580266ac86b75737ffea /youtube/templates/watch.html | |
parent | d2ba9be7a7d463bddc87dc30205eaee49752bafd (diff) | |
download | yt-local-4b6efb0e0baa290eaa43a01f672e22c1460ed6ea.tar.lz yt-local-4b6efb0e0baa290eaa43a01f672e22c1460ed6ea.tar.xz yt-local-4b6efb0e0baa290eaa43a01f672e22c1460ed6ea.zip |
Watch: display comment count and whether comments are disabled
Diffstat (limited to 'youtube/templates/watch.html')
-rw-r--r-- | youtube/templates/watch.html | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/youtube/templates/watch.html b/youtube/templates/watch.html index f00127b..9cb26ae 100644 --- a/youtube/templates/watch.html +++ b/youtube/templates/watch.html @@ -154,6 +154,11 @@ grid-row: 3; margin-top:10px; } + .comments-disabled{ + background-color: var(--interface-color); + padding: 5px; + font-weight: bold; + } .comments-area-inner{ padding-top: 10px; } @@ -324,13 +329,17 @@ {% endif %} {% if comments_mode != 0 %} - <details class="comments-area-outer" {{'open' if comments_mode == 1 else ''}}> - <summary>Comments</summary> - <section class="comments-area-inner comments-area"> - {% if comments_info %} - {{ comments.video_comments(comments_info) }} - {% endif %} - </section> - </details> + {% if comments_disabled %} + <div class="comments-area-outer comments-disabled">Comments disabled</div> + {% else %} + <details class="comments-area-outer" {{'open' if comments_mode == 1 else ''}}> + <summary>{{ comment_count|commatize }} comment{{'s' if comment_count != 1 else ''}}</summary> + <section class="comments-area-inner comments-area"> + {% if comments_info %} + {{ comments.video_comments(comments_info) }} + {% endif %} + </section> + </details> + {% endif %} {% endif %} {% endblock main %} |