Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZeger-Jan van de Weg <zegerjan@gitlab.com>2016-05-06 18:13:16 +0300
committerAlfredo Sumaran <alfredo@gitlab.com>2016-05-20 23:58:36 +0300
commitfab9dbb3eba55151c34fc8bc171e3670e6c7c422 (patch)
treec08e23dde57ed18176ea3d7b408c877b81c0fec0 /app/views/projects/blob/_editor.html.haml
parente166a8022a3f239938a1449a0a8ce3485f309766 (diff)
First import of gitignores
Add .gitignore dropdown when creating a new .gitignore file Signed-off-by: Alfredo Sumaran <alfredo@gitlab.com>
Diffstat (limited to 'app/views/projects/blob/_editor.html.haml')
-rw-r--r--app/views/projects/blob/_editor.html.haml6
1 files changed, 4 insertions, 2 deletions
diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml
index eac5014b7c9..5efec92cf6b 100644
--- a/app/views/projects/blob/_editor.html.haml
+++ b/app/views/projects/blob/_editor.html.haml
@@ -16,8 +16,10 @@
.license-selector.js-license-selector.hide
= select_tag :license_type, grouped_options_for_select(licenses_for_select, @project.repository.license_key), include_blank: true, class: 'select2 license-select', data: {placeholder: 'Choose a license template', project: @project.name, fullname: @project.namespace.human_name}
- .gitignore-selector.js-gitignore-selector.hide
- = select_tag :gitignore_template, options_for_select(Gitlab::Gitignore.all), include_blank: true, class: 'select2 gitignore-select', data: {placeholder: 'Choose a .gitignore template'}
+ .gitignore-selector.hidden
+ = dropdown_tag("Choose a .gitignore template", options: { toggle_class: 'js-gitignore-selector', title: "Choose a template", filter: true, placeholder: "Filter projects", data: { filenames: Gitlab::Gitignore.all.map.with_index{ |v| {text: v.name} } } } )
+
+ -# = select_tag :gitignore_template, options_for_select(Gitlab::Gitignore.all.map(&:name)), include_blank: true, class: 'select2 gitignore-select', data: {placeholder: 'Choose a .gitignore template'}
.encoding-selector
= select_tag :encoding, options_for_select([ "base64", "text" ], "text"), class: 'select2'