invidious-mod-JP/src/views/index.ecr

23 lines
777 B
Plaintext
Raw Normal View History

2018-01-15 03:16:09 +00:00
<% content_for "header" do %>
<title>Invidious</title>
2018-02-05 23:56:40 +00:00
<% end %>
2018-02-08 04:04:47 +00:00
<% top_videos.each_slice(4) do |slice| %>
2018-02-05 23:56:40 +00:00
<div class="pure-g">
<% slice.each do |video| %>
<% player_response = JSON.parse(video.info["player_response"]) %>
<div class="pure-u-1 pure-u-md-1-4">
2018-03-12 23:37:01 +00:00
<div class="h-box">
<a style="width:100%;" href="/watch?v=<%= video.id %>">
2018-02-06 00:44:42 +00:00
<img style="width:100%;" src="<%= player_response["videoDetails"]["thumbnail"]["thumbnails"][0]["url"] %>"/>
2018-02-27 02:59:18 +00:00
<p><%= video.title %></p>
2018-02-05 23:56:40 +00:00
</a>
<p>
<b><a style="width:100%;" href="https://youtube.com/channel/<%= video.info["ucid"] %>"><%= video.info["author"] %></a></b>
</p>
2018-02-05 23:56:40 +00:00
</div>
</div>
<% end %>
</div>
<% end %>