% item_watched = !item.is_a?(SearchChannel | SearchPlaylist | InvidiousPlaylist | Category) && env.get?("user").try &.as(User).watched.index(item.id) != nil %>
<%= 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 %><%= translate_count(locale, "generic_videos_count", item.video_count, NumberFormatting::Separator) %>
<%= 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 %><%= recode_length_seconds(item.length_seconds) %>
<% end %> <% if item_watched %> <% end %><%= HTML.escape(item.title) %>
<%= HTML.escape(item.author) %>
<% when Category %> <% else %> <%- # `endpoint_params` is used for the "video-context-buttons" component if item.is_a?(PlaylistVideo) link_url = "/watch?v=#{item.id}&list=#{item.plid}&index=#{item.index}" endpoint_params = "?v=#{item.id}&list=#{item.plid}" else link_url = "/watch?v=#{item.id}" endpoint_params = "?v=#{item.id}" end -%><%= 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 %><%= translate_count(locale, "generic_views_count", item.views || 0, NumberFormatting::Short) %>