main
erb 42 lines 1.62 KB
Raw
1 <% content_for :title, "#{@entry.tag}#{" — #{@entry.title}" if @entry.title.present?}" %>
2 <% content_for :description, @entry.headline.presence || "siGit #{@entry.tag} release notes." %>
3
4 <div class="max-w-3xl mx-auto px-4 sm:px-6 py-16 sm:py-20">
5 <nav class="mb-8 text-sm">
6 <%= link_to "← All releases", changelog_path,
7 class: "text-gray-400 hover:text-gray-200 transition-colors" %>
8 </nav>
9
10 <header class="mb-10 border-b border-surface-600 pb-8">
11 <div class="flex flex-wrap items-baseline gap-x-3 gap-y-1">
12 <h1 class="text-3xl font-semibold tracking-tight text-gray-100 sm:text-4xl"><%= @entry.tag %></h1>
13 <% if @entry.date %>
14 <time datetime="<%= @entry.date.iso8601 %>" class="text-xs uppercase tracking-[0.18em] text-gray-500">
15 <%= @entry.date.strftime("%B %-d, %Y") %>
16 </time>
17 <% end %>
18 </div>
19 <% if @entry.title.present? %>
20 <p class="mt-3 text-lg text-gray-300"><%= @entry.title %></p>
21 <% end %>
22 </header>
23
24 <div class="prose-readme">
25 <%= @entry.body_html %>
26 </div>
27
28 <% if @entries.length > 1 %>
29 <footer class="mt-16 border-t border-surface-600 pt-8">
30 <p class="text-xs uppercase tracking-[0.18em] text-gray-500 mb-4">Other releases</p>
31 <ul class="flex flex-wrap gap-x-4 gap-y-2 text-sm">
32 <% @entries.each do |other| %>
33 <% next if other.version == @entry.version %>
34 <li>
35 <%= link_to other.tag, changelog_version_path(version: other.tag),
36 class: "text-gray-400 hover:text-brand-400 transition-colors" %>
37 </li>
38 <% end %>
39 </ul>
40 </footer>
41 <% end %>
42 </div>