invidious-mod/src/invidious/views/channel.ecr

64 行
2.1 KiB
Plaintext
Raw 通常表示 履歴

<%-
ucid = channel.ucid
author = HTML.escape(channel.author)
channel_profile_pic = URI.parse(channel.author_thumbnail).request_target
relative_url =
case selected_tab
when .shorts? then "/channel/#{ucid}/shorts"
when .streams? then "/channel/#{ucid}/streams"
when .playlists? then "/channel/#{ucid}/playlists"
when .channels? then "/channel/#{ucid}/channels"
else
"/channel/#{ucid}"
end
youtube_url = "https://www.youtube.com#{relative_url}"
redirect_url = Invidious::Frontend::Misc.redirect_url(env)
-%>
2018-06-03 09:52:58 +09:00
<% content_for "header" do %>
<%- if selected_tab.videos? -%>
2022-10-15 23:07:47 +09:00
<meta name="description" content="<%= channel.description %>">
<meta property="og:site_name" content="Invidious">
<meta property="og:url" content="<%= HOST_URL %>/channel/<%= ucid %>">
<meta property="og:title" content="<%= author %>">
<meta property="og:image" content="/ggpht<%= channel_profile_pic %>">
<meta property="og:description" content="<%= channel.description %>">
<meta name="twitter:card" content="summary">
<meta name="twitter:url" content="<%= HOST_URL %>/channel/<%= ucid %>">
<meta name="twitter:title" content="<%= author %>">
<meta name="twitter:description" content="<%= channel.description %>">
<meta name="twitter:image" content="/ggpht<%= channel_profile_pic %>">
<link rel="alternate" type="application/rss+xml" title="RSS" href="/feed/channel/<%= ucid %>" />
<%- end -%>
<link rel="alternate" href="<%= youtube_url %>">
<title><%= author %> - Invidious</title>
<% end %>
<%= rendered "components/channel_info" %>
2018-11-14 10:04:25 +09:00
<div class="h-box">
<hr>
</div>
2018-08-18 00:57:08 +09:00
2018-06-03 09:52:58 +09:00
<div class="pure-g">
<% items.each do |item| %>
<%= rendered "components/item" %>
<% end %>
</div>
2018-06-03 09:52:58 +09:00
2023-02-20 04:41:18 +09:00
<script src="/js/watched_indicator.js"></script>
2018-08-05 13:07:38 +09:00
<div class="pure-g h-box">
<div class="pure-u-1 pure-u-md-4-5"></div>
2019-05-02 10:03:39 +09:00
<div class="pure-u-1 pure-u-lg-1-5" style="text-align:right">
<% if next_continuation %>
<a href="<%= relative_url %>?continuation=<%= next_continuation %><% if sort_options.any? sort_by %>&sort_by=<%= sort_by %><% end %>">
2019-05-02 10:03:39 +09:00
<%= translate(locale, "Next page") %>
</a>
<% end %>
2018-06-03 09:52:58 +09:00
</div>
2018-08-18 01:04:38 +09:00
</div>