From ccc858a5dfdb446d9648db2449d3ee3ef7a2be59 Mon Sep 17 00:00:00 2001 From: Eric Eastwood Date: Tue, 20 Feb 2018 09:36:57 -0600 Subject: Switch back to using a single partial See https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/16900#note_59334967 https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/16900#note_59714883 --- app/views/projects/_stat_anchor_list.html.haml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'app/views/projects/_stat_anchor_list.html.haml') diff --git a/app/views/projects/_stat_anchor_list.html.haml b/app/views/projects/_stat_anchor_list.html.haml index 9ca51f8d68c..1f237c645bc 100644 --- a/app/views/projects/_stat_anchor_list.html.haml +++ b/app/views/projects/_stat_anchor_list.html.haml @@ -2,4 +2,11 @@ - if anchors.size > 0 %ul.nav - = render partial: 'stat_anchor_list_item', collection: anchors, as: :anchor + - anchors.each do |anchor| + %li + - if anchor[:link] + = link_to anchor[:link], class: anchor[:enabled] ? 'stat-link' : "btn btn-#{anchor[:class_modifier] || 'missing'}" do + = anchor[:label] + - else + %span.stat-text + = anchor[:label] -- cgit v1.2.1