Commit 5b2aa853a3e1b1ef5fd5ae4a23cf7850988c9f43
1 parent
d7a48443
Exists in
spb-stable
and in
3 other branches
Fix compare view and services
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing
8 changed files
with
40 additions
and
35 deletions
Show diff stats
app/assets/stylesheets/generic/forms.scss
app/assets/stylesheets/generic/ui_box.scss
app/assets/stylesheets/sections/commits.scss
... | ... | @@ -399,8 +399,8 @@ |
399 | 399 | |
400 | 400 | .commits-compare-switch{ |
401 | 401 | background: url("switch_icon.png") no-repeat center center; |
402 | - width: 22px; | |
403 | - height: 22px; | |
402 | + width: 32px; | |
403 | + height: 32px; | |
404 | 404 | text-indent: -9999px; |
405 | 405 | float: left; |
406 | 406 | margin-right: 9px; | ... | ... |
app/views/projects/compare/_form.html.haml
1 | -= form_tag project_compare_index_path(@project), method: :post do | |
2 | - .clearfix | |
3 | - .pull-left | |
4 | - - if params[:to] && params[:from] | |
5 | - = link_to 'switch', {from: params[:to], to: params[:from]}, {class: 'commits-compare-switch has_tooltip', title: 'Switch base of comparison'} | |
6 | - .input-prepend | |
7 | - %span.add-on from | |
8 | - = text_field_tag :from, params[:from], class: "span3 input-xpadding" | |
9 | - = "..." | |
10 | - .input-prepend | |
11 | - %span.add-on to | |
12 | - = text_field_tag :to, params[:to], class: "span3 input-xpadding" | |
13 | - .pull-left | |
14 | - | |
15 | - = submit_tag "Compare", class: "btn btn-create commits-compare-btn" | |
16 | - - if compare_to_mr_button? | |
17 | - = link_to compare_mr_path, class: 'prepend-left-10' do | |
18 | - %strong Make a merge request | |
1 | += form_tag project_compare_index_path(@project), method: :post, class: 'form-inline' do | |
2 | + .clearfix.append-bottom-20 | |
3 | + - if params[:to] && params[:from] | |
4 | + = link_to 'switch', {from: params[:to], to: params[:from]}, {class: 'commits-compare-switch has_tooltip', title: 'Switch base of comparison'} | |
5 | + .form-group | |
6 | + .input-group.inline-input-group | |
7 | + %span.input-group-addon from | |
8 | + = text_field_tag :from, params[:from], class: "form-control" | |
9 | + = "..." | |
10 | + .form-group | |
11 | + .input-group.inline-input-group | |
12 | + %span.input-group-addon to | |
13 | + = text_field_tag :to, params[:to], class: "form-control" | |
14 | + | |
15 | + = submit_tag "Compare", class: "btn btn-create commits-compare-btn" | |
16 | + - if compare_to_mr_button? | |
17 | + = link_to compare_mr_path, class: 'prepend-left-10' do | |
18 | + %strong Make a merge request | |
19 | 19 | |
20 | 20 | |
21 | 21 | :javascript | ... | ... |
app/views/projects/compare/show.html.haml
app/views/projects/edit.html.haml
... | ... | @@ -134,9 +134,9 @@ |
134 | 134 | .title Transfer project |
135 | 135 | .errors-holder |
136 | 136 | .form-holder |
137 | - = form_for(@project, url: transfer_project_path(@project), method: :put, remote: true, html: { class: 'transfer-project' }) do |f| | |
137 | + = form_for(@project, url: transfer_project_path(@project), method: :put, remote: true, html: { class: 'transfer-project form-horizontal' }) do |f| | |
138 | 138 | .form-group |
139 | - = f.label :namespace_id do | |
139 | + = f.label :namespace_id, class: 'control-label' do | |
140 | 140 | %span Namespace |
141 | 141 | .col-sm-10 |
142 | 142 | .form-group |
... | ... | @@ -154,15 +154,15 @@ |
154 | 154 | .title Rename repository |
155 | 155 | .errors-holder |
156 | 156 | .form-holder |
157 | - = form_for(@project) do |f| | |
157 | + = form_for(@project, html: { class: 'form-horizontal' }) do |f| | |
158 | 158 | .form-group |
159 | - = f.label :path do | |
159 | + = f.label :path, class: 'control-label' do | |
160 | 160 | %span Path |
161 | - .col-sm-10 | |
161 | + .col-sm-9 | |
162 | 162 | .form-group |
163 | - .input-append | |
164 | - = f.text_field :path | |
165 | - %span.add-on .git | |
163 | + .input-group | |
164 | + = f.text_field :path, class: 'form-control' | |
165 | + %span.input-group-addon .git | |
166 | 166 | %ul |
167 | 167 | %li Be careful. Renaming a project's repository can have unintended side effects. |
168 | 168 | %li You will need to update your local repositories to point to the new location. | ... | ... |
app/views/projects/new_tree/show.html.haml
... | ... | @@ -8,7 +8,7 @@ |
8 | 8 | .col-sm-10 |
9 | 9 | %span.monospace= @path[-1] == "/" ? @path : @path + "/" |
10 | 10 | |
11 | - = text_field_tag 'file_name', params[:file_name], placeholder: "sample.rb", required: true | |
11 | + = text_field_tag 'file_name', params[:file_name], placeholder: "sample.rb", required: true, class: 'form-control' | |
12 | 12 | %span |
13 | 13 | |
14 | 14 | on |
... | ... | @@ -18,7 +18,7 @@ |
18 | 18 | = label_tag 'commit_message', class: "control-label" do |
19 | 19 | Commit message |
20 | 20 | .col-sm-10 |
21 | - = text_area_tag 'commit_message', params[:commit_message], placeholder: "Added new file", required: true, rows: 3 | |
21 | + = text_area_tag 'commit_message', params[:commit_message], placeholder: "Added new file", required: true, rows: 3, class: 'form-control' | |
22 | 22 | |
23 | 23 | .file-holder |
24 | 24 | .file-title | ... | ... |
app/views/projects/services/_form.html.haml
... | ... | @@ -10,7 +10,7 @@ |
10 | 10 | |
11 | 11 | %hr |
12 | 12 | |
13 | -= form_for(@service, as: :service, url: project_service_path(@project, @service.to_param), method: :put) do |f| | |
13 | += form_for(@service, as: :service, url: project_service_path(@project, @service.to_param), method: :put, html: { class: 'form-horizontal' }) do |f| | |
14 | 14 | - if @service.errors.any? |
15 | 15 | .alert.alert-danger |
16 | 16 | %ul |
... | ... | @@ -32,9 +32,9 @@ |
32 | 32 | = f.label name, class: "control-label" |
33 | 33 | .col-sm-10 |
34 | 34 | - if type == 'text' |
35 | - = f.text_field name, class: "input-lg", placeholder: placeholder | |
35 | + = f.text_field name, class: "form-control", placeholder: placeholder | |
36 | 36 | - elsif type == 'textarea' |
37 | - = f.text_area name, rows: 5, class: "input-lg", placeholder: placeholder | |
37 | + = f.text_area name, rows: 5, class: "form-control", placeholder: placeholder | |
38 | 38 | - elsif type == 'checkbox' |
39 | 39 | = f.check_box name |
40 | 40 | ... | ... |