Remove whitespace in chapters component

This commit is contained in:
syeopite 2023-08-21 00:39:58 -07:00
parent ddd931573a
commit 2cd3ded93b
No known key found for this signature in database
GPG Key ID: A73C186DA3955A1A

View File

@ -1,23 +1,20 @@
<% if !chapters.empty? %>
<hr class="description-content-separator"/>
<div class="description-chapters-section">
<p class="description-chapter">
<h5>Chapters</h5>
<div class="description-chapters-content-container">
<% chapters.each do | chapter |%>
<div class="chapter">
<a href="/watch?v=<%= video.id %>&t=<%=chapter.start_ms.milliseconds.total_seconds %>">
<a href="/watch?v=<%= video.id %>&t=<%=chapter.start_ms.milliseconds.total_seconds.to_i %>">
<div class="thumbnail">
<% if !env.get("preferences").as(Preferences).thin_mode %>
<img loading="lazy" class="thumbnail" src="<%=URI.parse(chapter.thumbnails[-1]["url"].to_s).request_target %>" alt="" />
<%- if !env.get("preferences").as(Preferences).thin_mode -%>
<img loading="lazy" class="thumbnail" src="<%-=URI.parse(chapter.thumbnails[-1]["url"].to_s).request_target %>" alt="" />
<%- else -%>
<div class="thumbnail-placeholder"></div>
<%- end -%>
</div>
<p><%= recode_length_seconds(chapter.start_ms.milliseconds.total_seconds) %></p>
<p><%=chapter.title%></p>
<p><%-= recode_length_seconds(chapter.start_ms.milliseconds.total_seconds) %></p>
<p><%-=chapter.title%></p>
</a>
</div>
<% end %>