commit
53f2e7438d
5 changed files with 20 additions and 16 deletions
|
@ -16,7 +16,6 @@ defmodule Chiya.Channels.Channel do
|
||||||
field :layout, Ecto.Enum, values: [
|
field :layout, Ecto.Enum, values: [
|
||||||
:default,
|
:default,
|
||||||
:microblog,
|
:microblog,
|
||||||
:photoblog,
|
|
||||||
:gallery
|
:gallery
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
|
@ -42,17 +42,21 @@
|
||||||
</main>
|
</main>
|
||||||
|
|
||||||
<footer class="mx-auto max-w-xl mt-8 text-theme-base/75 border-t pt-8 border-theme-background1">
|
<footer class="mx-auto max-w-xl mt-8 text-theme-base/75 border-t pt-8 border-theme-background1">
|
||||||
|
<p>
|
||||||
<span>Served by Chiya v<%= Application.spec(:chiya, :vsn) %></span>
|
<span>Served by Chiya v<%= Application.spec(:chiya, :vsn) %></span>
|
||||||
<.dot />
|
<.dot />
|
||||||
<span>Made by Inhji</span>
|
<span>Made by Inhji</span>
|
||||||
<.dot />
|
<.dot />
|
||||||
<span>Struggling to make a decent website since 2011</span>
|
<span>Struggling to make a decent website since 2011</span>
|
||||||
<%= for identity <- @identities do %>
|
|
||||||
<.dot />
|
|
||||||
<span><a href={identity.url}><%= identity.name %></a></span>
|
|
||||||
<% end %>
|
|
||||||
<.dot />
|
<.dot />
|
||||||
<span><a href={~p"/admin"}>Admin</a></span>
|
<span><a href={~p"/admin"}>Admin</a></span>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
<%= for identity <- @identities do %>
|
||||||
|
<span><a href={identity.url}><%= identity.name %></a></span>
|
||||||
|
<% end %>
|
||||||
|
</p>
|
||||||
</footer>
|
</footer>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -9,6 +9,7 @@ defmodule ChiyaWeb.PublicComponents do
|
||||||
import ChiyaWeb.Format
|
import ChiyaWeb.Format
|
||||||
import ChiyaWeb.Markdown, only: [render: 1]
|
import ChiyaWeb.Markdown, only: [render: 1]
|
||||||
import Phoenix.HTML, only: [raw: 1]
|
import Phoenix.HTML, only: [raw: 1]
|
||||||
|
import ChiyaWeb.CoreComponents
|
||||||
|
|
||||||
@doc """
|
@doc """
|
||||||
Renders a middot as divider
|
Renders a middot as divider
|
||||||
|
@ -113,15 +114,15 @@ defmodule ChiyaWeb.PublicComponents do
|
||||||
</time>
|
</time>
|
||||||
<.dot />
|
<.dot />
|
||||||
<a href={~p"/#{note.slug}"} class="text-theme-base/75">Permalink</a>
|
<a href={~p"/#{note.slug}"} class="text-theme-base/75">Permalink</a>
|
||||||
|
<%= if not Enum.empty?(note.images) do %>
|
||||||
|
<.dot />
|
||||||
|
<.icon name="hero-photo" />
|
||||||
|
<% end %>
|
||||||
</article>
|
</article>
|
||||||
<% end %>
|
<% end %>
|
||||||
</section>
|
</section>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
:photoblog ->
|
|
||||||
~H"""
|
|
||||||
"""
|
|
||||||
|
|
||||||
_ -> # default, show headings only
|
_ -> # default, show headings only
|
||||||
~H"""
|
~H"""
|
||||||
<section class="note-list default | mt-6 sm:w-auto flex flex-col gap-1.5">
|
<section class="note-list default | mt-6 sm:w-auto flex flex-col gap-1.5">
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<div class="mx-auto max-w-xl mx-4 lg:mx-0">
|
<div class="mx-auto max-w-xl">
|
||||||
<h1 class="mt-16 text-3xl font-extrabold tracking-tight text-theme-primary">
|
<h1 class="mt-16 text-3xl font-extrabold tracking-tight text-theme-primary">
|
||||||
<%= @channel.name %>
|
<%= @channel.name %>
|
||||||
</h1>
|
</h1>
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
<%= Markdown.render(@note.content) |> raw %>
|
<%= Markdown.render(@note.content) |> raw %>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section class="mt-8 mx-auto max-w-2xl">
|
<section class="mt-8 mx-auto max-w-xl">
|
||||||
<%= if !Enum.empty?(@note.images) do %>
|
<%= if !Enum.empty?(@note.images) do %>
|
||||||
<.line />
|
<.line />
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue