add channel note list

This commit is contained in:
inhji 2023-03-31 13:23:18 +02:00
parent 943295c989
commit 50d196d0b9

View file

@ -6,5 +6,14 @@
<p class="mt-4 text-base leading-7 text-gray-600">
<%= @channel.content %>
</p>
<div class="w-full mt-6 sm:w-auto flex flex-col gap-1.5">
<%= for note <- @channel.notes do %>
<a href={~p"/n/#{note.slug}"} class="rounded -mx-2 -my-0.5 px-2 py-0.5 hover:bg-theme-primary/10 transition">
<span class="text-theme-heading text-lg font-semibold leading-8"><%= note.name %></span>
<span class="text-theme-base text-sm"><%= pretty_date(note.published_at) %></span>
</a>
<% end %>
</div>
</div>
</div>