mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-30 23:08:00 +01:00
36 lines
1.4 KiB
Text
36 lines
1.4 KiB
Text
h5
|
|
' Faved by
|
|
=> @image.faves_count
|
|
= pluralize("user", "users", @image.faves_count)
|
|
|
|
= for fave <- Enum.sort_by(@image.faves, & &1.user.name) do
|
|
=> link fave.user.name, to: Routes.profile_path(@conn, :show, fave.user), class: "interaction-user-list-item"
|
|
|
|
= if @has_votes do
|
|
h5
|
|
' Upvoted by
|
|
=> @image.upvotes_count
|
|
= pluralize("user", "users", @image.upvotes_count)
|
|
|
|
= for upvote <- Enum.sort_by(@image.upvotes, & &1.user.name) do
|
|
span.interaction-user-list-item
|
|
=> link upvote.user.name, to: Routes.profile_path(@conn, :show, upvote.user)
|
|
=> link "(x)", to: Routes.image_tamper_path(@conn, :create, @image, user_id: upvote.user_id), method: "post"
|
|
|
|
h5
|
|
' Downvoted by
|
|
=> @image.downvotes_count
|
|
= pluralize("user", "users", @image.downvotes_count)
|
|
|
|
= for downvote <- Enum.sort_by(@image.downvotes, & &1.user.name) do
|
|
span.interaction-user-list-item
|
|
=> link downvote.user.name, to: Routes.profile_path(@conn, :show, downvote.user)
|
|
=> link "(x)", to: Routes.image_tamper_path(@conn, :create, @image, user_id: downvote.user_id), method: "post"
|
|
|
|
h5
|
|
' Hidden by
|
|
=> @image.hides_count
|
|
= pluralize("user", "users", @image.hides_count)
|
|
|
|
= for hide <- Enum.sort_by(@image.hides, & &1.user.name) do
|
|
=> link hide.user.name, to: Routes.profile_path(@conn, :show, hide.user), class: "interaction-user-list-item"
|