mirror of
https://github.com/iv-org/invidious.git
synced 2024-11-26 07:27:22 +00:00
Unify video/audio player
This commit is contained in:
parent
e9e6bbd710
commit
d89ccc4d50
@ -1,5 +0,0 @@
|
|||||||
<audio style="width:100%" poster="<%= thumbnail %>" title="<%= HTML.escape(video.title) %>" id="player" class="video-js vjs-16-9" data-setup="{}" controls>
|
|
||||||
<% audio_streams.each_with_index do |fmt, i| %>
|
|
||||||
<source src="<%= fmt["url"] %>" type='<%= fmt["type"] %>' label="<%= fmt["bitrate"] %>k" selected="<%= i == 0 ? true : false %>">
|
|
||||||
<% end %>
|
|
||||||
</audio>
|
|
@ -1,5 +0,0 @@
|
|||||||
<video style="width:100%" playsinline poster="<%= thumbnail %>" title="<%= HTML.escape(video.title) %>" id="player" class="video-js vjs-16-9" data-setup="{}" controls>
|
|
||||||
<% fmt_stream.each_with_index do |fmt, i| %>
|
|
||||||
<source src="<%= fmt["url"] %>" type='<%= fmt["type"] %>' label="<%= fmt["label"] %>" selected="<%= i == 0 ? true : false %>">
|
|
||||||
<% end %>
|
|
||||||
</video>
|
|
@ -10,11 +10,17 @@
|
|||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="h-box">
|
<div class="h-box">
|
||||||
|
<video style="width:100%" playsinline poster="<%= thumbnail %>" title="<%= HTML.escape(video.title) %>" id="player" class="video-js vjs-16-9" data-setup="{}" controls>
|
||||||
<% if listen %>
|
<% if listen %>
|
||||||
<%= render "src/views/player/audio.ecr" %>
|
<% audio_streams.each_with_index do |fmt, i| %>
|
||||||
<% else %>
|
<source src="<%= fmt["url"] %>" type='<%= fmt["type"] %>' label="<%= fmt["bitrate"] %>k" selected="<%= i == 0 ? true : false %>">
|
||||||
<%= render "src/views/player/video.ecr" %>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% else %>
|
||||||
|
<% fmt_stream.each_with_index do |fmt, i| %>
|
||||||
|
<source src="<%= fmt["url"] %>" type='<%= fmt["type"] %>' label="<%= fmt["label"] %>" selected="<%= i == 0 ? true : false %>">
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
</video>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
Loading…
Reference in New Issue
Block a user