summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-03-09 18:07:59 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-09 18:07:59 +0000
commit7ebcead8cfd2edb810dd0cbda816b6cfbd170fe3 (patch)
tree11880c4059c89149cf997e9b958fb6d32c7dbdad /app/views
parentf1a40d0db939dfe8ff95d385e652ff72566be765 (diff)
downloadgitlab-ce-7ebcead8cfd2edb810dd0cbda816b6cfbd170fe3.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views')
-rw-r--r--app/views/projects/_commit_button.html.haml3
-rw-r--r--app/views/projects/blob/_editor.html.haml5
-rw-r--r--app/views/projects/blob/_suggest_gitlab_ci_yml.html.haml4
-rw-r--r--app/views/projects/blob/new.html.haml5
4 files changed, 11 insertions, 6 deletions
diff --git a/app/views/projects/_commit_button.html.haml b/app/views/projects/_commit_button.html.haml
index b6689f4b57a..5f7ed46297b 100644
--- a/app/views/projects/_commit_button.html.haml
+++ b/app/views/projects/_commit_button.html.haml
@@ -1,5 +1,6 @@
.form-actions
- = button_tag 'Commit changes', class: 'btn commit-btn js-commit-button btn-success qa-commit-button'
+ = button_tag 'Commit changes', id: 'commit-changes', class: 'btn commit-btn js-commit-button btn-success qa-commit-button'
+
= link_to 'Cancel', cancel_path,
class: 'btn btn-cancel', data: {confirm: leave_edit_message}
diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml
index 738bca111cd..cd8407608a3 100644
--- a/app/views/projects/blob/_editor.html.haml
+++ b/app/views/projects/blob/_editor.html.haml
@@ -20,7 +20,10 @@
required: true, class: 'form-control new-file-name js-file-path-name-input', value: params[:file_name] || (should_suggest_gitlab_ci_yml? ? '.gitlab-ci.yml' : '')
= render 'template_selectors'
- if should_suggest_gitlab_ci_yml?
- = render partial: 'suggest_gitlab_ci_yml', locals: { target: '#gitlab-ci-yml-selector', dismiss_key: "suggest_gitlab_ci_yml_#{@project.id}" }
+ .js-suggest-gitlab-ci-yml{ data: { toggle: 'popover',
+ target: '#gitlab-ci-yml-selector',
+ track_label: 'suggest_gitlab_ci_yml',
+ dismiss_key: "suggest_gitlab_ci_yml_#{@project.id}" } }
.file-buttons
- if is_markdown
diff --git a/app/views/projects/blob/_suggest_gitlab_ci_yml.html.haml b/app/views/projects/blob/_suggest_gitlab_ci_yml.html.haml
deleted file mode 100644
index 6b368033c1e..00000000000
--- a/app/views/projects/blob/_suggest_gitlab_ci_yml.html.haml
+++ /dev/null
@@ -1,4 +0,0 @@
-.js-suggest-gitlab-ci-yml{ data: { toggle: 'popover',
- target: target,
- css_class: 'suggest-gitlab-ci-yml ml-4',
- dismiss_key: dismiss_key } }
diff --git a/app/views/projects/blob/new.html.haml b/app/views/projects/blob/new.html.haml
index c5e3923f1e8..bf7900018c3 100644
--- a/app/views/projects/blob/new.html.haml
+++ b/app/views/projects/blob/new.html.haml
@@ -13,3 +13,8 @@
= hidden_field_tag 'content', '', id: 'file-content'
= render 'projects/commit_button', ref: @ref,
cancel_path: project_tree_path(@project, @id)
+ - if should_suggest_gitlab_ci_yml?
+ .js-suggest-gitlab-ci-yml-commit-changes{ data: { toggle: 'popover',
+ target: '#commit-changes',
+ track_label: 'suggest_commit_first_project_gitlab_ci_yml',
+ dismiss_key: "suggest_commit_first_project_gitlab_ci_yml_#{@project.id}" } }