diff options
author | Mayra Cabrera <mcabrera@gitlab.com> | 2017-11-01 17:09:48 -0600 |
---|---|---|
committer | Mayra Cabrera <mcabrera@gitlab.com> | 2017-11-01 17:39:05 -0600 |
commit | 244bec9101ff754291e2c02d9844e0879ff5fa2f (patch) | |
tree | 8c550d6e2644fc41741b959d0ed9450fd2c31114 /app/views/projects/commit | |
parent | 2bdad7964a2c626118b7f2c762c39f3e1908fc9d (diff) | |
download | gitlab-ce-244bec9101ff754291e2c02d9844e0879ff5fa2f.tar.gz |
Add UI/UX improvements
- Leave 'too many tags to search' always visible
- Add different message to the branch/tags so it states its unavailable
Diffstat (limited to 'app/views/projects/commit')
-rw-r--r-- | app/views/projects/commit/branches.html.haml | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/app/views/projects/commit/branches.html.haml b/app/views/projects/commit/branches.html.haml index 31d10ff9040..8c7a303adbf 100644 --- a/app/views/projects/commit/branches.html.haml +++ b/app/views/projects/commit/branches.html.haml @@ -1,18 +1,12 @@ - if @branches_limit_exceeded - = commit_branch_link('#', _('Too many branches to search')) + = branches_unavailable_message - elsif @branches.any? - branch = commit_default_branch(@project, @branches) = commit_branch_link(project_ref_path(@project, branch), branch) -# `commit_default_branch` deletes the default branch from `@branches`, --# so only render this if we have more branches or tags left -- if @branches.any? || @tags.any? || @tags_limit_exceeded - %span - = link_to "…", "#", class: "js-details-expand label label-gray" - - %span.js-details-content.hide - = commit_branches_links(@project, @branches) if @branches.any? - - if @tags_limit_exceeded - = commit_tag_link('#', _('Too many tags to search')) - - elsif @tags.any? - = commit_tags_links(@project, @tags) + -# so only render this if we have more branches or tags left +- if @tags_limit_exceeded + = tags_unavailable_message +- elsif @tags.any? + = commit_tags_links(@project, @tags) |