aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/templates/channel.html
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2019-08-10 18:12:02 -0700
committerJames Taylor <user234683@users.noreply.github.com>2019-08-10 18:12:02 -0700
commit2617f87e17b94646eb5a248360a7e0f9b7675d3e (patch)
tree83ea80a52c410e34415cbb93b9b125d886618cbe /youtube/templates/channel.html
parent33bba9762c7f96a754351f3422f74364c5bdecac (diff)
downloadyt-local-2617f87e17b94646eb5a248360a7e0f9b7675d3e.tar.lz
yt-local-2617f87e17b94646eb5a248360a7e0f9b7675d3e.tar.xz
yt-local-2617f87e17b94646eb5a248360a7e0f9b7675d3e.zip
Add subscribe button on channels
Diffstat (limited to 'youtube/templates/channel.html')
-rw-r--r--youtube/templates/channel.html9
1 files changed, 9 insertions, 0 deletions
diff --git a/youtube/templates/channel.html b/youtube/templates/channel.html
index 069e33b..a9f3ac9 100644
--- a/youtube/templates/channel.html
+++ b/youtube/templates/channel.html
@@ -23,6 +23,9 @@
grid-column:2;
margin-left: 5px;
}
+ .summary subscribe-unsubscribe, .summary short-description{
+ margin-top: 10px;
+ }
main .channel-tabs{
grid-row:2;
grid-column: 1 / span 2;
@@ -90,6 +93,12 @@
<div class="summary">
<h2 class="title">{{ channel_name }}</h2>
<p class="short-description">{{ short_description }}</p>
+ <form method="POST" action="/youtube.com/subscriptions" class="subscribe-unsubscribe">
+ <input type="submit" value="{{ 'Unsubscribe' if subscribed else 'Subscribe' }}">
+ <input type="hidden" name="channel_id" value="{{ channel_id }}">
+ <input type="hidden" name="channel_name" value="{{ channel_name }}">
+ <input type="hidden" name="action" value="{{ 'unsubscribe' if subscribed else 'subscribe' }}">
+ </form>
</div>
<nav class="channel-tabs">
{% for tab_name in ('Videos', 'Playlists', 'About') %}