summaryrefslogtreecommitdiff
path: root/app/views/protected_branches/shared/_matching_branch.html.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/protected_branches/shared/_matching_branch.html.haml')
-rw-r--r--app/views/protected_branches/shared/_matching_branch.html.haml10
1 files changed, 10 insertions, 0 deletions
diff --git a/app/views/protected_branches/shared/_matching_branch.html.haml b/app/views/protected_branches/shared/_matching_branch.html.haml
new file mode 100644
index 00000000000..1a2ec38fae9
--- /dev/null
+++ b/app/views/protected_branches/shared/_matching_branch.html.haml
@@ -0,0 +1,10 @@
+%tr
+ %td
+ = link_to matching_branch.name, project_ref_path(@project, matching_branch.name), class: 'ref-name'
+
+ - if @project.root_ref?(matching_branch.name)
+ = gl_badge_tag s_('ProtectedBranch|default'), { variant: :info }, { class: 'gl-ml-2' }
+ %td
+ - commit = @project.commit(matching_branch.name)
+ = link_to(commit.short_id, project_commit_path(@project, commit.id), class: 'commit-sha')
+ = time_ago_with_tooltip(commit.committed_date)