Commit df6a75d52d9a7db6d3bbdb9c3c306a65b4f8a1f2
1 parent
4e0c2f00
Exists in
master
and in
4 other branches
buttons margin fixed
Showing
12 changed files
with
46 additions
and
35 deletions
Show diff stats
app/assets/stylesheets/common.scss
| @@ -108,11 +108,6 @@ table a code { | @@ -108,11 +108,6 @@ table a code { | ||
| 108 | margin-top: 5px; | 108 | margin-top: 5px; |
| 109 | } | 109 | } |
| 110 | 110 | ||
| 111 | -.btn.padded { | ||
| 112 | - margin-right:3px; | ||
| 113 | - padding:4px 10px 4px; | ||
| 114 | -} | ||
| 115 | - | ||
| 116 | .loading { | 111 | .loading { |
| 117 | margin:20px auto; | 112 | margin:20px auto; |
| 118 | background: url(ajax_loader.gif) no-repeat center center; | 113 | background: url(ajax_loader.gif) no-repeat center center; |
| @@ -399,6 +394,16 @@ p.time { | @@ -399,6 +394,16 @@ p.time { | ||
| 399 | padding:2px 6px; | 394 | padding:2px 6px; |
| 400 | margin:2px; | 395 | margin:2px; |
| 401 | } | 396 | } |
| 397 | + | ||
| 398 | + &.grouped { | ||
| 399 | + margin-right:7px; | ||
| 400 | + float:left; | ||
| 401 | + } | ||
| 402 | + | ||
| 403 | + &.padded { | ||
| 404 | + margin-right:3px; | ||
| 405 | + padding:4px 10px 4px; | ||
| 406 | + } | ||
| 402 | } | 407 | } |
| 403 | 408 | ||
| 404 | 409 |
app/assets/stylesheets/gitlab_bootstrap.scss
| @@ -189,6 +189,12 @@ a:focus { | @@ -189,6 +189,12 @@ a:focus { | ||
| 189 | padding:4px 6px; | 189 | padding:4px 6px; |
| 190 | color:#444; | 190 | color:#444; |
| 191 | text-shadow:0 0 1px #fff; | 191 | text-shadow:0 0 1px #fff; |
| 192 | + | ||
| 193 | + &.grouped { | ||
| 194 | + float: left; | ||
| 195 | + margin-right: 6px; | ||
| 196 | + padding: 6px; | ||
| 197 | + } | ||
| 192 | } | 198 | } |
| 193 | } | 199 | } |
| 194 | 200 |
app/views/commits/_commit_box.html.haml
| 1 | .commit-box{class: @commit.parents.count > 1 ? "merge-commit" : ""} | 1 | .commit-box{class: @commit.parents.count > 1 ? "merge-commit" : ""} |
| 2 | .commit-head | 2 | .commit-head |
| 3 | .right | 3 | .right |
| 4 | - = link_to tree_project_ref_path(@project, @commit.id), :class => "browse-button primary" do | ||
| 5 | - %strong Browse Code » | ||
| 6 | - if @notes_count > 0 | 4 | - if @notes_count > 0 |
| 7 | - %span.btn.disabled | 5 | + %span.btn.disabled.grouped |
| 8 | %i.icon-comment | 6 | %i.icon-comment |
| 9 | = @notes_count | 7 | = @notes_count |
| 10 | - | ||
| 11 | - = link_to patch_project_commit_path(@project, @commit.id), :class => "btn small" do | 8 | + = link_to patch_project_commit_path(@project, @commit.id), :class => "btn small grouped" do |
| 12 | %i.icon-download-alt | 9 | %i.icon-download-alt |
| 13 | Get Patch | 10 | Get Patch |
| 14 | - | 11 | + = link_to tree_project_ref_path(@project, @commit.id), :class => "browse-button primary grouped" do |
| 12 | + %strong Browse Code » | ||
| 15 | %h3.commit-title.page_title | 13 | %h3.commit-title.page_title |
| 16 | = commit_msg_with_link_to_issues(@project, @commit.title) | 14 | = commit_msg_with_link_to_issues(@project, @commit.title) |
| 17 | - if @commit.description.present? | 15 | - if @commit.description.present? |
app/views/commits/_diffs.html.haml
| @@ -29,6 +29,9 @@ | @@ -29,6 +29,9 @@ | ||
| 29 | %span{:id => "#{diff.new_path}"}= diff.new_path | 29 | %span{:id => "#{diff.new_path}"}= diff.new_path |
| 30 | %br/ | 30 | %br/ |
| 31 | .diff_file_content | 31 | .diff_file_content |
| 32 | + -# Skipp all non non-supported blobs | ||
| 33 | + - next unless file.respond_to?('text?') | ||
| 34 | + | ||
| 32 | - if file.text? | 35 | - if file.text? |
| 33 | = render "commits/text_file", :diff => diff, :index => i | 36 | = render "commits/text_file", :diff => diff, :index => i |
| 34 | - elsif file.image? | 37 | - elsif file.image? |
app/views/events/_event_last_push.html.haml
| @@ -12,5 +12,5 @@ | @@ -12,5 +12,5 @@ | ||
| 12 | = time_ago_in_words(event.created_at) | 12 | = time_ago_in_words(event.created_at) |
| 13 | ago. | 13 | ago. |
| 14 | 14 | ||
| 15 | - = link_to new_mr_path_from_push_event(event), :title => "New Merge Request", :class => "btn small padded primary" do | 15 | + = link_to new_mr_path_from_push_event(event), :title => "New Merge Request", :class => "btn small grouped primary" do |
| 16 | Create Merge Request | 16 | Create Merge Request |
app/views/issues/_show.html.haml
| @@ -3,19 +3,18 @@ | @@ -3,19 +3,18 @@ | ||
| 3 | .icon | 3 | .icon |
| 4 | .right | 4 | .right |
| 5 | - issue.labels.each do |label| | 5 | - issue.labels.each do |label| |
| 6 | - %span.label.label-issue | 6 | + %span.label.label-issue.grouped |
| 7 | %i.icon-tag | 7 | %i.icon-tag |
| 8 | = label.name | 8 | = label.name |
| 9 | - | ||
| 10 | - if issue.notes.any? | 9 | - if issue.notes.any? |
| 11 | - %span.btn.small.disabled.padded | 10 | + %span.btn.small.disabled.grouped |
| 12 | %i.icon-comment | 11 | %i.icon-comment |
| 13 | = issue.notes.count | 12 | = issue.notes.count |
| 14 | - if can? current_user, :modify_issue, issue | 13 | - if can? current_user, :modify_issue, issue |
| 15 | - if issue.closed | 14 | - if issue.closed |
| 16 | - = link_to 'Reopen', project_issue_path(issue.project, issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "btn small padded", :remote => true | 15 | + = link_to 'Reopen', project_issue_path(issue.project, issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "btn small grouped", :remote => true |
| 17 | - else | 16 | - else |
| 18 | - = link_to 'Resolve', project_issue_path(issue.project, issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "success btn small padded", :remote => true | 17 | + = link_to 'Resolve', project_issue_path(issue.project, issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "success btn small grouped", :remote => true |
| 19 | = link_to edit_project_issue_path(issue.project, issue), :class => "btn small edit-issue-link", :remote => true do | 18 | = link_to edit_project_issue_path(issue.project, issue), :class => "btn small edit-issue-link", :remote => true do |
| 20 | %i.icon-edit | 19 | %i.icon-edit |
| 21 | Edit | 20 | Edit |
app/views/merge_requests/_merge_request.html.haml
| @@ -2,15 +2,15 @@ | @@ -2,15 +2,15 @@ | ||
| 2 | .right | 2 | .right |
| 3 | .left | 3 | .left |
| 4 | - if merge_request.merged? | 4 | - if merge_request.merged? |
| 5 | - %span.btn.small.disabled.padded | 5 | + %span.btn.small.disabled.grouped |
| 6 | %strong | 6 | %strong |
| 7 | %i.icon-ok | 7 | %i.icon-ok |
| 8 | = "MERGED" | 8 | = "MERGED" |
| 9 | - if merge_request.notes.any? | 9 | - if merge_request.notes.any? |
| 10 | - %span.btn.small.disabled.padded | 10 | + %span.btn.small.disabled.grouped |
| 11 | %i.icon-comment | 11 | %i.icon-comment |
| 12 | = merge_request.notes.count | 12 | = merge_request.notes.count |
| 13 | - %span.btn.small.disabled.padded | 13 | + %span.btn.small.disabled.grouped |
| 14 | = merge_request.source_branch | 14 | = merge_request.source_branch |
| 15 | → | 15 | → |
| 16 | = merge_request.target_branch | 16 | = merge_request.target_branch |
app/views/merge_requests/show/_mr_title.html.haml
| @@ -7,19 +7,19 @@ | @@ -7,19 +7,19 @@ | ||
| 7 | 7 | ||
| 8 | %span.right | 8 | %span.right |
| 9 | - if @merge_request.merged? | 9 | - if @merge_request.merged? |
| 10 | - %span.btn.small.disabled.padded | 10 | + %span.btn.small.disabled.grouped |
| 11 | %strong | 11 | %strong |
| 12 | %i.icon-ok | 12 | %i.icon-ok |
| 13 | = "MERGED" | 13 | = "MERGED" |
| 14 | - if can?(current_user, :modify_merge_request, @merge_request) | 14 | - if can?(current_user, :modify_merge_request, @merge_request) |
| 15 | - if @merge_request.open? | 15 | - if @merge_request.open? |
| 16 | - = link_to raw_project_merge_request_path(@project, @merge_request), :class => "btn padded" do | 16 | + = link_to raw_project_merge_request_path(@project, @merge_request), :class => "btn grouped" do |
| 17 | %i.icon-download-alt | 17 | %i.icon-download-alt |
| 18 | Get Patch | 18 | Get Patch |
| 19 | 19 | ||
| 20 | - = link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "btn padded danger", :title => "Close merge request" | 20 | + = link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "btn grouped danger", :title => "Close merge request" |
| 21 | 21 | ||
| 22 | - = link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn padded" do | 22 | + = link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn grouped" do |
| 23 | %i.icon-edit | 23 | %i.icon-edit |
| 24 | Edit | 24 | Edit |
| 25 | 25 |
app/views/milestones/_milestone.html.haml
| 1 | %li{:class => "milestone", :id => dom_id(milestone) } | 1 | %li{:class => "milestone", :id => dom_id(milestone) } |
| 2 | .right | 2 | .right |
| 3 | - - if milestone.issues.count > 0 | ||
| 4 | - = link_to 'Browse Issues', project_issues_path(milestone.project, :milestone_id => milestone.id), :class => "btn small" | ||
| 5 | - if milestone.issues.any? | 3 | - if milestone.issues.any? |
| 6 | - %span.btn.small.disabled.padded= pluralize milestone.issues.count, 'issues' | 4 | + %span.btn.small.disabled.grouped= pluralize milestone.issues.count, 'issues' |
| 5 | + - if milestone.issues.count > 0 | ||
| 6 | + = link_to 'Browse Issues', project_issues_path(milestone.project, :milestone_id => milestone.id), :class => "btn small grouped" | ||
| 7 | - if can? current_user, :admin_milestone, milestone.project | 7 | - if can? current_user, :admin_milestone, milestone.project |
| 8 | - = link_to 'Edit', edit_project_milestone_path(milestone.project, milestone), :class => "btn small edit-milestone-link" | 8 | + = link_to 'Edit', edit_project_milestone_path(milestone.project, milestone), :class => "btn small edit-milestone-link grouped" |
| 9 | = link_to project_milestone_path(milestone.project, milestone) do | 9 | = link_to project_milestone_path(milestone.project, milestone) do |
| 10 | %h4.row_title | 10 | %h4.row_title |
| 11 | = truncate(milestone.title, :length => 100) | 11 | = truncate(milestone.title, :length => 100) |
app/views/milestones/show.html.haml
| @@ -4,9 +4,9 @@ | @@ -4,9 +4,9 @@ | ||
| 4 | = @milestone.expires_at | 4 | = @milestone.expires_at |
| 5 | 5 | ||
| 6 | %span.right | 6 | %span.right |
| 7 | - = link_to 'Browse Issues', project_issues_path(@milestone.project, :milestone_id => @milestone.id), :class => "btn edit-milestone-link small" | 7 | + = link_to 'Browse Issues', project_issues_path(@milestone.project, :milestone_id => @milestone.id), :class => "btn edit-milestone-link small grouped" |
| 8 | - if can?(current_user, :admin_milestone, @project) | 8 | - if can?(current_user, :admin_milestone, @project) |
| 9 | - = link_to edit_project_milestone_path(@project, @milestone), :class => "btn small" do | 9 | + = link_to edit_project_milestone_path(@project, @milestone), :class => "btn small grouped" do |
| 10 | %i.icon-edit | 10 | %i.icon-edit |
| 11 | Edit | 11 | Edit |
| 12 | 12 |
app/views/projects/show.html.haml
| @@ -13,14 +13,14 @@ | @@ -13,14 +13,14 @@ | ||
| 13 | .span4.right | 13 | .span4.right |
| 14 | .right | 14 | .right |
| 15 | - if can? current_user, :download_code, @project | 15 | - if can? current_user, :download_code, @project |
| 16 | - = link_to archive_project_repository_path(@project), :class => "btn small padded" do | 16 | + = link_to archive_project_repository_path(@project), :class => "btn small grouped" do |
| 17 | %i.icon-download-alt | 17 | %i.icon-download-alt |
| 18 | Download | 18 | Download |
| 19 | - if @project.merge_requests_enabled && can?(current_user, :write_merge_request, @project) | 19 | - if @project.merge_requests_enabled && can?(current_user, :write_merge_request, @project) |
| 20 | - = link_to new_project_merge_request_path(@project), :title => "New Merge Request", :class => "btn small padded" do | 20 | + = link_to new_project_merge_request_path(@project), :title => "New Merge Request", :class => "btn small grouped" do |
| 21 | Merge Request | 21 | Merge Request |
| 22 | - if @project.issues_enabled && can?(current_user, :write_issue, @project) | 22 | - if @project.issues_enabled && can?(current_user, :write_issue, @project) |
| 23 | - = link_to new_project_issue_path(@project), :title => "New Issue", :class => "btn small" do | 23 | + = link_to new_project_issue_path(@project), :title => "New Issue", :class => "btn small grouped" do |
| 24 | Issue | 24 | Issue |
| 25 | 25 | ||
| 26 | = render "events/event_last_push", :event => @last_push | 26 | = render "events/event_last_push", :event => @last_push |
app/views/wikis/show.html.haml
| @@ -2,9 +2,9 @@ | @@ -2,9 +2,9 @@ | ||
| 2 | = @wiki.title | 2 | = @wiki.title |
| 3 | %span.right | 3 | %span.right |
| 4 | - if can? current_user, :write_wiki, @project | 4 | - if can? current_user, :write_wiki, @project |
| 5 | - = link_to history_project_wiki_path(@project, @wiki), :class => "btn small padded" do | 5 | + = link_to history_project_wiki_path(@project, @wiki), :class => "btn small grouped" do |
| 6 | History | 6 | History |
| 7 | - = link_to edit_project_wiki_path(@project, @wiki), :class => "btn small" do | 7 | + = link_to edit_project_wiki_path(@project, @wiki), :class => "btn small grouped" do |
| 8 | Edit | 8 | Edit |
| 9 | %hr | 9 | %hr |
| 10 | .wiki_content | 10 | .wiki_content |