diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-10 09:06:08 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-10 09:06:08 +0000 |
commit | c157f963db87a40a3ba7b94b339530ee83194bc8 (patch) | |
tree | 9f8f9468daf727cce39bc7487af8bd9a53b8c59d /app/views/projects/blob | |
parent | bd1e1afde56a9bd97e03ca24298e260dc071999e (diff) | |
download | gitlab-ce-c157f963db87a40a3ba7b94b339530ee83194bc8.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views/projects/blob')
-rw-r--r-- | app/views/projects/blob/_editor.html.haml | 8 | ||||
-rw-r--r-- | app/views/projects/blob/_template_selectors.html.haml | 17 | ||||
-rw-r--r-- | app/views/projects/blob/edit.html.haml | 1 | ||||
-rw-r--r-- | app/views/projects/blob/new.html.haml | 1 |
4 files changed, 11 insertions, 16 deletions
diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml index 283b845e40d..961b873b571 100644 --- a/app/views/projects/blob/_editor.html.haml +++ b/app/views/projects/blob/_editor.html.haml @@ -3,20 +3,22 @@ - is_markdown = Gitlab::MarkupHelper.gitlab_markdown?(file_name) .file-holder-bottom-radius.file-holder.file.append-bottom-default - .js-file-title.file-title.clearfix{ data: { current_action: action } } + .js-file-title.file-title.align-items-center.clearfix{ data: { current_action: action } } .editor-ref.block-truncated = sprite_icon('fork', size: 12) = ref - if current_action?(:edit) || current_action?(:update) %span.pull-left.append-right-10 - = text_field_tag 'file_path', (params[:file_path] || @path), - class: 'form-control new-file-path js-file-path-name-input' + = text_field_tag 'file_path', (params[:file_path] || @path), + class: 'form-control new-file-path js-file-path-name-input' + = render 'template_selectors' - if current_action?(:new) || current_action?(:create) %span.pull-left.append-right-10 \/ = text_field_tag 'file_name', params[:file_name], placeholder: "File name", required: true, class: 'form-control new-file-name js-file-path-name-input' + = render 'template_selectors' .file-buttons - if is_markdown diff --git a/app/views/projects/blob/_template_selectors.html.haml b/app/views/projects/blob/_template_selectors.html.haml index bd46f5a4349..5ecfa135446 100644 --- a/app/views/projects/blob/_template_selectors.html.haml +++ b/app/views/projects/blob/_template_selectors.html.haml @@ -1,17 +1,12 @@ -.template-selectors-menu - .templates-selectors-label - Template +.template-selectors-menu.gl-pl-2 .template-selector-dropdowns-wrap .template-type-selector.js-template-type-selector-wrap.hidden - = dropdown_tag("Choose type", options: { toggle_class: 'js-template-type-selector qa-template-type-dropdown', title: "Choose a template type" } ) + = dropdown_tag(_("Select a template type"), options: { toggle_class: 'js-template-type-selector qa-template-type-dropdown', dropdown_class: 'dropdown-menu-selectable'} ) .license-selector.js-license-selector-wrap.js-template-selector-wrap.hidden - = dropdown_tag("Apply a license template", options: { toggle_class: 'js-license-selector qa-license-dropdown', title: "Apply a license", filter: true, placeholder: "Filter", data: { data: licenses_for_select(@project), project: @project.name, fullname: @project.namespace.human_name } } ) + = dropdown_tag(_("Apply a template"), options: { toggle_class: 'js-license-selector qa-license-dropdown', dropdown_class: 'dropdown-menu-selectable', filter: true, placeholder: "Filter", data: { data: licenses_for_select(@project), project: @project.name, fullname: @project.namespace.human_name } } ) .gitignore-selector.js-gitignore-selector-wrap.js-template-selector-wrap.hidden - = dropdown_tag("Apply a .gitignore template", options: { toggle_class: 'js-gitignore-selector qa-gitignore-dropdown', title: "Apply a template", filter: true, placeholder: "Filter", data: { data: gitignore_names(@project) } } ) + = dropdown_tag(_("Apply a template"), options: { toggle_class: 'js-gitignore-selector qa-gitignore-dropdown', dropdown_class: 'dropdown-menu-selectable', filter: true, placeholder: "Filter", data: { data: gitignore_names(@project) } } ) .gitlab-ci-yml-selector.js-gitlab-ci-yml-selector-wrap.js-template-selector-wrap.hidden - = dropdown_tag("Apply a GitLab CI Yaml template", options: { toggle_class: 'js-gitlab-ci-yml-selector qa-gitlab-ci-yml-dropdown', title: "Apply a template", filter: true, placeholder: "Filter", data: { data: gitlab_ci_ymls(@project) } } ) + = dropdown_tag(_("Apply a template"), options: { toggle_class: 'js-gitlab-ci-yml-selector qa-gitlab-ci-yml-dropdown', dropdown_class: 'dropdown-menu-selectable', filter: true, placeholder: "Filter", data: { data: gitlab_ci_ymls(@project) } } ) .dockerfile-selector.js-dockerfile-selector-wrap.js-template-selector-wrap.hidden - = dropdown_tag("Apply a Dockerfile template", options: { toggle_class: 'js-dockerfile-selector qa-dockerfile-dropdown', title: "Apply a template", filter: true, placeholder: "Filter", data: { data: dockerfile_names(@project) } } ) - .template-selectors-undo-menu.hidden - %span.text-info Template applied - %button.btn.btn-sm.btn-info Undo + = dropdown_tag(_("Apply a template"), options: { toggle_class: 'js-dockerfile-selector qa-dockerfile-dropdown', dropdown_class: 'dropdown-menu-selectable', filter: true, placeholder: "Filter", data: { data: dockerfile_names(@project) } } ) diff --git a/app/views/projects/blob/edit.html.haml b/app/views/projects/blob/edit.html.haml index 51e42091ab8..870e37488cf 100644 --- a/app/views/projects/blob/edit.html.haml +++ b/app/views/projects/blob/edit.html.haml @@ -11,7 +11,6 @@ .editor-title-row %h3.page-title.blob-edit-page-title Edit file - = render 'template_selectors' .file-editor %ul.nav-links.no-bottom.js-edit-mode.nav.nav-tabs %li.active diff --git a/app/views/projects/blob/new.html.haml b/app/views/projects/blob/new.html.haml index 4be87b9e074..c5e3923f1e8 100644 --- a/app/views/projects/blob/new.html.haml +++ b/app/views/projects/blob/new.html.haml @@ -5,7 +5,6 @@ .editor-title-row %h3.page-title.blob-new-page-title New file - = render 'template_selectors' .file-editor = form_tag(project_create_blob_path(@project, @id), method: :post, class: 'js-edit-blob-form js-new-blob-form js-quick-submit js-requires-input', data: blob_editor_paths(@project)) do = render 'projects/blob/editor', ref: @ref |