From e922f9a94ba9c2ca29a83092979c435b9d8185b2 Mon Sep 17 00:00:00 2001 From: "byte[]" Date: Fri, 20 Dec 2019 10:05:34 -0500 Subject: [PATCH] add missing links --- .../templates/profile/show.html.slime | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/lib/philomena_web/templates/profile/show.html.slime b/lib/philomena_web/templates/profile/show.html.slime index eb1f3655..3f52193b 100644 --- a/lib/philomena_web/templates/profile/show.html.slime +++ b/lib/philomena_web/templates/profile/show.html.slime @@ -53,8 +53,11 @@ = render PhilomenaWeb.ProfileView, "_commission.html", user: @user, commission_information: @commission_information, conn: @conn .block - .block__header - span.block__header__title User Links + = if current?(@user, @conn.assigns.current_user) do + a.block__header--single-item href=Routes.profile_user_link_path(@conn, :new, @user) User Links + - else + .block__header + span.block__header__title User Links = for link <- @user.verified_links, link.public or can?(@conn, :edit, link) do - watchers = if link.tag, do: @watcher_counts[link.tag.id] || 0, else: 0 @@ -71,8 +74,11 @@ = pluralize("user", "users", watchers) .block - .block__header - span.block__header__title Badges + = if manages_awards?(@conn) do + a.block__header--single-item href=Routes.profile_award_path(@conn, :new, @user) Badges + - else + .block__header + span.block__header__title Badges = for award <- award_order(@user.awards) do .block__content.flex.flex--centered.flex--center-distributed.alternating-color.no-overflow title=award.label .flex__grow.center