diff options
| author | Omar Roth <omarroth@hotmail.com> | 2018-08-06 17:10:22 -0500 |
|---|---|---|
| committer | Omar Roth <omarroth@hotmail.com> | 2018-08-06 17:10:22 -0500 |
| commit | ac12d161b926cbc58efb77fcf210d2abedd48155 (patch) | |
| tree | d6d817b0d45aacc3536eb8b4ee6a5c2af0961402 | |
| parent | 928ca94d8c6a4f080293ea23381cdae9c0eadbe3 (diff) | |
| download | invidious-ac12d161b926cbc58efb77fcf210d2abedd48155.tar.gz invidious-ac12d161b926cbc58efb77fcf210d2abedd48155.tar.bz2 invidious-ac12d161b926cbc58efb77fcf210d2abedd48155.zip | |
Enable captions when `listen=1`
| -rw-r--r-- | src/invidious/views/embed.ecr | 9 | ||||
| -rw-r--r-- | src/invidious/views/watch.ecr | 10 |
2 files changed, 10 insertions, 9 deletions
diff --git a/src/invidious/views/embed.ecr b/src/invidious/views/embed.ecr index b7bec5d5..23ade84e 100644 --- a/src/invidious/views/embed.ecr +++ b/src/invidious/views/embed.ecr @@ -53,10 +53,11 @@ video, #my_video, .video-js, .vjs-default-skin <% fmt_stream.each_with_index do |fmt, i| %> <source src="<%= fmt["url"] %>" type='<%= fmt["type"] %>' label="<%= fmt["label"] %>" selected="<%= quality == fmt["label"].split(" - ")[0] %>"> <% end %> - <% captions.each do |caption| %> - <track kind="captions" src="/api/v1/captions/<%= video.id %>?label=<%= caption["name"]["simpleText"] %>" - label="<%= caption["name"]["simpleText"]%> "> - <% end %> + <% end %> + + <% captions.each do |caption| %> + <track kind="captions" src="/api/v1/captions/<%= video.id %>?label=<%= caption["name"]["simpleText"] %>" + label="<%= caption["name"]["simpleText"]%> "> <% end %> <% end %> </video> diff --git a/src/invidious/views/watch.ecr b/src/invidious/views/watch.ecr index 0aacf91b..1840642d 100644 --- a/src/invidious/views/watch.ecr +++ b/src/invidious/views/watch.ecr @@ -64,11 +64,11 @@ <track kind="captions" src="/api/v1/captions/<%= video.id %>?label=<%= caption["name"]["simpleText"] %>" label="<%= caption["name"]["simpleText"]%>" <% if i == 0 %>default<% end %>> <% end %> - - <% captions.each do |caption| %> - <track kind="captions" src="/api/v1/captions/<%= video.id %>?label=<%= caption["name"]["simpleText"] %>" - label="<%= caption["name"]["simpleText"]%>"> - <% end %> + <% end %> + + <% captions.each do |caption| %> + <track kind="captions" src="/api/v1/captions/<%= video.id %>?label=<%= caption["name"]["simpleText"] %>" + label="<%= caption["name"]["simpleText"]%>"> <% end %> <% end %> </video> |
