mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-30 14:57:59 +01:00
fix templates
This commit is contained in:
parent
f8aa0a68df
commit
ecd0a91025
4 changed files with 10 additions and 7 deletions
|
@ -30,11 +30,11 @@
|
||||||
= for topic <- @topics do
|
= for topic <- @topics do
|
||||||
= render PhilomenaWeb.ActivityView, "_topic_strip.html", topic: topic, conn: @conn
|
= render PhilomenaWeb.ActivityView, "_topic_strip.html", topic: topic, conn: @conn
|
||||||
.block.hide-mobile
|
.block.hide-mobile
|
||||||
a.block__header--single-item.center href="/lists/recent_comments"
|
a.block__header--single-item.center href="/comments"
|
||||||
' Recent Comments
|
' Recent Comments
|
||||||
= for comment <- @comments do
|
= for comment <- @comments do
|
||||||
= render PhilomenaWeb.ActivityView, "_comment_strip.html", comment: comment, conn: @conn
|
= render PhilomenaWeb.ActivityView, "_comment_strip.html", comment: comment, conn: @conn
|
||||||
a.block__header--single-item.center href="/search?q=first_seen_at.gt:3 days ago&sf=comments&sd=desc"
|
a.block__header--single-item.center href="/search?q=first_seen_at.gt:3 days ago&sf=comment_count&sd=desc"
|
||||||
' Most Commented-on Images
|
' Most Commented-on Images
|
||||||
|
|
||||||
.column-layout__main
|
.column-layout__main
|
||||||
|
|
|
@ -14,13 +14,10 @@ nav#burger
|
||||||
a href="/filters"
|
a href="/filters"
|
||||||
i.fa.fa-fw.fa-filter<>
|
i.fa.fa-fw.fa-filter<>
|
||||||
' Filters
|
' Filters
|
||||||
a href="/lists"
|
|
||||||
i.fa.fa-fw.fa-list<>
|
|
||||||
' Rankings
|
|
||||||
a href="/galleries"
|
a href="/galleries"
|
||||||
i.fa.fa-fw.fa-image<>
|
i.fa.fa-fw.fa-image<>
|
||||||
' Galleries
|
' Galleries
|
||||||
a href="/lists/recent_comments"
|
a href="/comments"
|
||||||
i.fa.fa-fw.fa-comments<>
|
i.fa.fa-fw.fa-comments<>
|
||||||
' Comments
|
' Comments
|
||||||
a href="/commissions"
|
a href="/commissions"
|
||||||
|
|
|
@ -56,7 +56,7 @@
|
||||||
|
|
||||||
.toggle-box-container
|
.toggle-box-container
|
||||||
.toggle-box-container__content
|
.toggle-box-container__content
|
||||||
= for tag <- @tag.implied_by_tags do
|
= map_join @tag.implied_by_tags, ", ", fn tag ->
|
||||||
=> link tag.name, to: Routes.tag_path(@conn, :show, tag)
|
=> link tag.name, to: Routes.tag_path(@conn, :show, tag)
|
||||||
|
|
||||||
br
|
br
|
||||||
|
|
|
@ -65,6 +65,12 @@ defmodule PhilomenaWeb.AppView do
|
||||||
Canada.Can.can?(conn.assigns.current_user, action, model)
|
Canada.Can.can?(conn.assigns.current_user, action, model)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def map_join(enumerable, joiner, map_fn) do
|
||||||
|
enumerable
|
||||||
|
|> Enum.map(map_fn)
|
||||||
|
|> Enum.intersperse(joiner)
|
||||||
|
end
|
||||||
|
|
||||||
def number_with_delimiter(nil), do: "0"
|
def number_with_delimiter(nil), do: "0"
|
||||||
def number_with_delimiter(number) do
|
def number_with_delimiter(number) do
|
||||||
number
|
number
|
||||||
|
|
Loading…
Reference in a new issue