summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorDouwe Maan <douwe@selenight.nl>2017-04-07 17:13:04 -0500
committerDouwe Maan <douwe@selenight.nl>2017-04-07 17:13:04 -0500
commit4caa9b63cc8b28000d62d4bef0d25f6996a7c5b5 (patch)
treede23c92a29938c27623deb48d1c7a9f4b57fff8a /app
parenta5792a8682ef5262f7d04a92b4d014efdd975311 (diff)
downloadgitlab-ce-4caa9b63cc8b28000d62d4bef0d25f6996a7c5b5.tar.gz
Rename displaying_blame to blamedm-remove-copy-link-on-blame-page
Diffstat (limited to 'app')
-rw-r--r--app/views/projects/blame/show.html.haml2
-rw-r--r--app/views/projects/blob/_header.html.haml6
2 files changed, 4 insertions, 4 deletions
diff --git a/app/views/projects/blame/show.html.haml b/app/views/projects/blame/show.html.haml
index 812801d62cf..35885b2c7b4 100644
--- a/app/views/projects/blame/show.html.haml
+++ b/app/views/projects/blame/show.html.haml
@@ -7,7 +7,7 @@
#blob-content-holder.tree-holder
.file-holder
- = render "projects/blob/header", blob: @blob, displaying_blame: true
+ = render "projects/blob/header", blob: @blob, blame: true
.table-responsive.file-content.blame.code.js-syntax-highlight
%table
diff --git a/app/views/projects/blob/_header.html.haml b/app/views/projects/blob/_header.html.haml
index 4d08a4cf2a3..6c7d389e707 100644
--- a/app/views/projects/blob/_header.html.haml
+++ b/app/views/projects/blob/_header.html.haml
@@ -1,4 +1,4 @@
-- displaying_blame = local_assigns.fetch(:displaying_blame, false)
+- blame = local_assigns.fetch(:blame, false)
.js-file-title.file-title-flex-parent
.file-header-content
= blob_icon blob.mode, blob.name
@@ -13,14 +13,14 @@
.file-actions.hidden-xs
.btn-group{ role: "group" }<
- = copy_blob_content_button(blob) if !displaying_blame && blob_text_viewable?(blob)
+ = copy_blob_content_button(blob) if !blame && blob_text_viewable?(blob)
= open_raw_file_button(namespace_project_raw_path(@project.namespace, @project, @id))
= view_on_environment_button(@commit.sha, @path, @environment) if @environment
.btn-group{ role: "group" }<
-# only show normal/blame view links for text files
- if blob_text_viewable?(blob)
- - if displaying_blame
+ - if blame
= link_to 'Normal view', namespace_project_blob_path(@project.namespace, @project, @id),
class: 'btn btn-sm'
- else