source: Klonkt/src/views/pages/downloads.ejs@ cc22112

main
Last change on this file since cc22112 was d68bcf1, checked in by roboburr <roboburr@…>, 3 months ago

fix(downloads): post nav pixel-identical to a post (.container.post-page)

The downloads page was in .dls (680px/18px padding) → post nav slightly wider
than on a real post (.container, 42rem). Now the whole page in .container.post-page
→ post nav exactly the same as a post.

Co-Authored-By: Claude <noreply@…>

  • Property mode set to 100644
File size: 2.2 KB
RevLine 
[91094a4]1<%
2 var ts = (typeof dlTracks !== 'undefined') ? dlTracks : [];
3%>
[d68bcf1]4<article class="container post-page">
[d8c6a83]5 <%- include('../partials/post-nav', { newerPost: (typeof newerPost !== 'undefined' ? newerPost : null), olderPost: (typeof olderPost !== 'undefined' ? olderPost : null) }) %>
[d68bcf1]6 <section class="dls">
[91094a4]7 <h1 class="dls-h1">Downloads</h1>
8 <p class="dls-sub">Gratis te downloaden — laat je e-mailadres achter en je krijgt het bestand.</p>
9
10 <% if (!ts.length) { %>
11 <p class="dls-empty">Er staan momenteel geen downloads klaar.</p>
12 <% } else { %>
13 <ul class="dls-list">
14 <% ts.forEach(function(t){ %>
15 <li class="dls-item">
16 <% if (t.cover_url) { %><span class="dls-cover" style="background-image:url('<%= t.cover_url %>')"></span><% } else { %><span class="dls-cover dls-cover-empty">♪</span><% } %>
17 <span class="dls-meta">
18 <span class="dls-title"><%= t.title %></span>
19 <% if (t.artist) { %><span class="dls-artist"><%= t.artist %></span><% } %>
20 </span>
21 <a class="dls-btn" href="<%= siteUrlBase %>/download/<%= t.id %>">⬇ Download</a>
22 </li>
23 <% }); %>
24 </ul>
25 <% } %>
[d68bcf1]26 </section>
27</article>
[91094a4]28
29<style>
[d68bcf1]30 .dls { padding: 0 0 64px; }
[91094a4]31 .dls-h1 { font-size: clamp(26px,5vw,38px); margin: 0 0 8px; }
32 .dls-sub { opacity: .8; margin: 0 0 24px; }
33 .dls-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
34 .dls-item { display: flex; align-items: center; gap: 14px; padding: 10px 12px; border: 1px solid rgba(128,128,128,.2); border-radius: 12px; }
35 .dls-cover { flex: 0 0 auto; width: 48px; height: 48px; border-radius: 8px; background-size: cover; background-position: center; display: grid; place-items: center; }
36 .dls-cover-empty { background: var(--accent,#6b8f71); color: #fff; opacity: .85; }
37 .dls-meta { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }
38 .dls-title { font-weight: 600; }
39 .dls-artist { font-size: 12.5px; opacity: .65; }
40 .dls-btn { flex: 0 0 auto; padding: 9px 15px; border-radius: 999px; background: var(--accent,#6b8f71); color: #fff; text-decoration: none; font-weight: 600; font-size: 13.5px; }
41</style>
Note: See TracBrowser for help on using the repository browser.