<% case item when %> <% when SearchChannel %> <% if !env.get("preferences").as(Preferences).thin_mode %>
"/>
<% end %>

<%= HTML.escape(item.author) %><% if !item.author_verified.nil? && item.author_verified %> <% end %>

<%= translate_count(locale, "generic_subscribers_count", item.subscriber_count, NumberFormatting::Separator) %>

<% if !item.auto_generated %>

<%= translate_count(locale, "generic_videos_count", item.video_count, NumberFormatting::Separator) %>

<% end %>
<%= item.description_html %>
<% when SearchPlaylist, InvidiousPlaylist %> <% if item.id.starts_with? "RD" %> <% url = "/mix?list=#{item.id}&continuation=#{URI.parse(item.thumbnail || "/vi/-----------").request_target.split("/")[2]}" %> <% else %> <% url = "/playlist?list=#{item.id}" %> <% end %> <% if !env.get("preferences").as(Preferences).thin_mode %>
"/>

<%= translate_count(locale, "generic_videos_count", item.video_count, NumberFormatting::Separator) %>

<% end %>

<%= HTML.escape(item.title) %>

<%= HTML.escape(item.author) %><% if !item.is_a?(InvidiousPlaylist) && !item.author_verified.nil? && item.author_verified %> <% end %>

<% when MixVideo %> <% if !env.get("preferences").as(Preferences).thin_mode %>
<% if item.length_seconds != 0 %>

<%= recode_length_seconds(item.length_seconds) %>

<% end %>
<% end %>

<%= HTML.escape(item.title) %>

<%= HTML.escape(item.author) %>

<% when PlaylistVideo %> <% if !env.get("preferences").as(Preferences).thin_mode %>
<% if plid_form = env.get?("remove_playlist_items") %>
" method="post"> ">

<% end %> <% if item.responds_to?(:live_now) && item.live_now %>

<%= translate(locale, "LIVE") %>

<% elsif item.length_seconds != 0 %>

<%= recode_length_seconds(item.length_seconds) %>

<% end %>
<% end %>

<%= HTML.escape(item.title) %>

<% endpoint_params = "?v=#{item.id}&list=#{item.plid}" %> <%= rendered "components/video-context-buttons" %>
<% if item.responds_to?(:premiere_timestamp) && item.premiere_timestamp.try &.> Time.utc %>

<%= translate(locale, "Premieres in `x`", recode_date((item.premiere_timestamp.as(Time) - Time.utc).ago, locale)) %>

<% elsif Time.utc - item.published > 1.minute %>

<%= translate(locale, "Shared `x` ago", recode_date(item.published, locale)) %>

<% end %>
<% if item.responds_to?(:views) && item.views %>

<%= translate_count(locale, "generic_views_count", item.views || 0, NumberFormatting::Short) %>

<% end %>
<% when Category %> <% else %> <% if !env.get("preferences").as(Preferences).thin_mode %>
<% if env.get? "show_watched" %>
" method="post"> ">

<% elsif plid_form = env.get? "add_playlist_items" %>
" method="post"> ">

<% end %> <% if item.responds_to?(:live_now) && item.live_now %>

<%= translate(locale, "LIVE") %>

<% elsif item.length_seconds != 0 %>

<%= recode_length_seconds(item.length_seconds) %>

<% end %>
<% end %>

<%= HTML.escape(item.title) %>

<% endpoint_params = "?v=#{item.id}" %> <%= rendered "components/video-context-buttons" %>
<% if item.responds_to?(:premiere_timestamp) && item.premiere_timestamp.try &.> Time.utc %>

<%= translate(locale, "Premieres in `x`", recode_date((item.premiere_timestamp.as(Time) - Time.utc).ago, locale)) %>

<% elsif Time.utc - item.published > 1.minute %>

<%= translate(locale, "Shared `x` ago", recode_date(item.published, locale)) %>

<% end %>
<% if item.responds_to?(:views) && item.views %>

<%= translate_count(locale, "generic_views_count", item.views || 0, NumberFormatting::Short) %>

<% end %>
<% end %>