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:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2012-07-05 10:35:23 +0400
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2012-07-05 10:35:23 +0400
commitdf6a75d52d9a7db6d3bbdb9c3c306a65b4f8a1f2 (patch)
tree78bdf89dbd769b61610e503a95f4183c68e7f909
parent4e0c2f00d3edcabd24488161933b00d497656bfd (diff)
buttons margin fixed
-rw-r--r--app/assets/stylesheets/common.scss15
-rw-r--r--app/assets/stylesheets/gitlab_bootstrap.scss6
-rw-r--r--app/views/commits/_commit_box.html.haml10
-rw-r--r--app/views/commits/_diffs.html.haml3
-rw-r--r--app/views/events/_event_last_push.html.haml2
-rw-r--r--app/views/issues/_show.html.haml9
-rw-r--r--app/views/merge_requests/_merge_request.html.haml6
-rw-r--r--app/views/merge_requests/show/_mr_title.html.haml8
-rw-r--r--app/views/milestones/_milestone.html.haml8
-rw-r--r--app/views/milestones/show.html.haml4
-rw-r--r--app/views/projects/show.html.haml6
-rw-r--r--app/views/wikis/show.html.haml4
12 files changed, 46 insertions, 35 deletions
diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss
index 8b76fe5a0fb..19092073c17 100644
--- a/app/assets/stylesheets/common.scss
+++ b/app/assets/stylesheets/common.scss
@@ -108,11 +108,6 @@ table a code {
margin-top: 5px;
}
-.btn.padded {
- margin-right:3px;
- padding:4px 10px 4px;
-}
-
.loading {
margin:20px auto;
background: url(ajax_loader.gif) no-repeat center center;
@@ -399,6 +394,16 @@ p.time {
padding:2px 6px;
margin:2px;
}
+
+ &.grouped {
+ margin-right:7px;
+ float:left;
+ }
+
+ &.padded {
+ margin-right:3px;
+ padding:4px 10px 4px;
+ }
}
diff --git a/app/assets/stylesheets/gitlab_bootstrap.scss b/app/assets/stylesheets/gitlab_bootstrap.scss
index fa8d544e1e1..7f26f16aa41 100644
--- a/app/assets/stylesheets/gitlab_bootstrap.scss
+++ b/app/assets/stylesheets/gitlab_bootstrap.scss
@@ -189,6 +189,12 @@ a:focus {
padding:4px 6px;
color:#444;
text-shadow:0 0 1px #fff;
+
+ &.grouped {
+ float: left;
+ margin-right: 6px;
+ padding: 6px;
+ }
}
}
diff --git a/app/views/commits/_commit_box.html.haml b/app/views/commits/_commit_box.html.haml
index 32c9de5e7e0..8ccb3f1b72a 100644
--- a/app/views/commits/_commit_box.html.haml
+++ b/app/views/commits/_commit_box.html.haml
@@ -1,17 +1,15 @@
.commit-box{class: @commit.parents.count > 1 ? "merge-commit" : ""}
.commit-head
.right
- = link_to tree_project_ref_path(@project, @commit.id), :class => "browse-button primary" do
- %strong Browse Code »
- if @notes_count > 0
- %span.btn.disabled
+ %span.btn.disabled.grouped
%i.icon-comment
= @notes_count
- &nbsp;
- = link_to patch_project_commit_path(@project, @commit.id), :class => "btn small" do
+ = link_to patch_project_commit_path(@project, @commit.id), :class => "btn small grouped" do
%i.icon-download-alt
Get Patch
- &nbsp;
+ = link_to tree_project_ref_path(@project, @commit.id), :class => "browse-button primary grouped" do
+ %strong Browse Code »
%h3.commit-title.page_title
= commit_msg_with_link_to_issues(@project, @commit.title)
- if @commit.description.present?
diff --git a/app/views/commits/_diffs.html.haml b/app/views/commits/_diffs.html.haml
index d16ad069e58..02a15633089 100644
--- a/app/views/commits/_diffs.html.haml
+++ b/app/views/commits/_diffs.html.haml
@@ -29,6 +29,9 @@
%span{:id => "#{diff.new_path}"}= diff.new_path
%br/
.diff_file_content
+ -# Skipp all non non-supported blobs
+ - next unless file.respond_to?('text?')
+
- if file.text?
= render "commits/text_file", :diff => diff, :index => i
- elsif file.image?
diff --git a/app/views/events/_event_last_push.html.haml b/app/views/events/_event_last_push.html.haml
index eb507b55c9b..6127e32ba24 100644
--- a/app/views/events/_event_last_push.html.haml
+++ b/app/views/events/_event_last_push.html.haml
@@ -12,5 +12,5 @@
= time_ago_in_words(event.created_at)
ago.
- = link_to new_mr_path_from_push_event(event), :title => "New Merge Request", :class => "btn small padded primary" do
+ = link_to new_mr_path_from_push_event(event), :title => "New Merge Request", :class => "btn small grouped primary" do
Create Merge Request
diff --git a/app/views/issues/_show.html.haml b/app/views/issues/_show.html.haml
index 7488032f92a..03524901c99 100644
--- a/app/views/issues/_show.html.haml
+++ b/app/views/issues/_show.html.haml
@@ -3,19 +3,18 @@
.icon
.right
- issue.labels.each do |label|
- %span.label.label-issue
+ %span.label.label-issue.grouped
%i.icon-tag
= label.name
- &nbsp;
- if issue.notes.any?
- %span.btn.small.disabled.padded
+ %span.btn.small.disabled.grouped
%i.icon-comment
= issue.notes.count
- if can? current_user, :modify_issue, issue
- if issue.closed
- = link_to 'Reopen', project_issue_path(issue.project, issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "btn small padded", :remote => true
+ = link_to 'Reopen', project_issue_path(issue.project, issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "btn small grouped", :remote => true
- else
- = link_to 'Resolve', project_issue_path(issue.project, issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "success btn small padded", :remote => true
+ = link_to 'Resolve', project_issue_path(issue.project, issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "success btn small grouped", :remote => true
= link_to edit_project_issue_path(issue.project, issue), :class => "btn small edit-issue-link", :remote => true do
%i.icon-edit
Edit
diff --git a/app/views/merge_requests/_merge_request.html.haml b/app/views/merge_requests/_merge_request.html.haml
index 37108cca006..d9634a4fcc8 100644
--- a/app/views/merge_requests/_merge_request.html.haml
+++ b/app/views/merge_requests/_merge_request.html.haml
@@ -2,15 +2,15 @@
.right
.left
- if merge_request.merged?
- %span.btn.small.disabled.padded
+ %span.btn.small.disabled.grouped
%strong
%i.icon-ok
= "MERGED"
- if merge_request.notes.any?
- %span.btn.small.disabled.padded
+ %span.btn.small.disabled.grouped
%i.icon-comment
= merge_request.notes.count
- %span.btn.small.disabled.padded
+ %span.btn.small.disabled.grouped
= merge_request.source_branch
&rarr;
= merge_request.target_branch
diff --git a/app/views/merge_requests/show/_mr_title.html.haml b/app/views/merge_requests/show/_mr_title.html.haml
index 70ccbc213aa..3f6060b0645 100644
--- a/app/views/merge_requests/show/_mr_title.html.haml
+++ b/app/views/merge_requests/show/_mr_title.html.haml
@@ -7,19 +7,19 @@
%span.right
- if @merge_request.merged?
- %span.btn.small.disabled.padded
+ %span.btn.small.disabled.grouped
%strong
%i.icon-ok
= "MERGED"
- if can?(current_user, :modify_merge_request, @merge_request)
- if @merge_request.open?
- = link_to raw_project_merge_request_path(@project, @merge_request), :class => "btn padded" do
+ = link_to raw_project_merge_request_path(@project, @merge_request), :class => "btn grouped" do
%i.icon-download-alt
Get Patch
- = 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"
+ = 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"
- = link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn padded" do
+ = link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn grouped" do
%i.icon-edit
Edit
diff --git a/app/views/milestones/_milestone.html.haml b/app/views/milestones/_milestone.html.haml
index 0bb4bc18ae8..9912cf9ed54 100644
--- a/app/views/milestones/_milestone.html.haml
+++ b/app/views/milestones/_milestone.html.haml
@@ -1,11 +1,11 @@
%li{:class => "milestone", :id => dom_id(milestone) }
.right
- - if milestone.issues.count > 0
- = link_to 'Browse Issues', project_issues_path(milestone.project, :milestone_id => milestone.id), :class => "btn small"
- if milestone.issues.any?
- %span.btn.small.disabled.padded= pluralize milestone.issues.count, 'issues'
+ %span.btn.small.disabled.grouped= pluralize milestone.issues.count, 'issues'
+ - if milestone.issues.count > 0
+ = link_to 'Browse Issues', project_issues_path(milestone.project, :milestone_id => milestone.id), :class => "btn small grouped"
- if can? current_user, :admin_milestone, milestone.project
- = link_to 'Edit', edit_project_milestone_path(milestone.project, milestone), :class => "btn small edit-milestone-link"
+ = link_to 'Edit', edit_project_milestone_path(milestone.project, milestone), :class => "btn small edit-milestone-link grouped"
= link_to project_milestone_path(milestone.project, milestone) do
%h4.row_title
= truncate(milestone.title, :length => 100)
diff --git a/app/views/milestones/show.html.haml b/app/views/milestones/show.html.haml
index 727fa0fd155..dc3dcd01de8 100644
--- a/app/views/milestones/show.html.haml
+++ b/app/views/milestones/show.html.haml
@@ -4,9 +4,9 @@
= @milestone.expires_at
%span.right
- = link_to 'Browse Issues', project_issues_path(@milestone.project, :milestone_id => @milestone.id), :class => "btn edit-milestone-link small"
+ = link_to 'Browse Issues', project_issues_path(@milestone.project, :milestone_id => @milestone.id), :class => "btn edit-milestone-link small grouped"
- if can?(current_user, :admin_milestone, @project)
- = link_to edit_project_milestone_path(@project, @milestone), :class => "btn small" do
+ = link_to edit_project_milestone_path(@project, @milestone), :class => "btn small grouped" do
%i.icon-edit
Edit
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml
index 23a49873d49..7c5b11e4be0 100644
--- a/app/views/projects/show.html.haml
+++ b/app/views/projects/show.html.haml
@@ -13,14 +13,14 @@
.span4.right
.right
- if can? current_user, :download_code, @project
- = link_to archive_project_repository_path(@project), :class => "btn small padded" do
+ = link_to archive_project_repository_path(@project), :class => "btn small grouped" do
%i.icon-download-alt
Download
- if @project.merge_requests_enabled && can?(current_user, :write_merge_request, @project)
- = link_to new_project_merge_request_path(@project), :title => "New Merge Request", :class => "btn small padded" do
+ = link_to new_project_merge_request_path(@project), :title => "New Merge Request", :class => "btn small grouped" do
Merge Request
- if @project.issues_enabled && can?(current_user, :write_issue, @project)
- = link_to new_project_issue_path(@project), :title => "New Issue", :class => "btn small" do
+ = link_to new_project_issue_path(@project), :title => "New Issue", :class => "btn small grouped" do
Issue
= render "events/event_last_push", :event => @last_push
diff --git a/app/views/wikis/show.html.haml b/app/views/wikis/show.html.haml
index 32f7f337c8a..9aa287dff07 100644
--- a/app/views/wikis/show.html.haml
+++ b/app/views/wikis/show.html.haml
@@ -2,9 +2,9 @@
= @wiki.title
%span.right
- if can? current_user, :write_wiki, @project
- = link_to history_project_wiki_path(@project, @wiki), :class => "btn small padded" do
+ = link_to history_project_wiki_path(@project, @wiki), :class => "btn small grouped" do
History
- = link_to edit_project_wiki_path(@project, @wiki), :class => "btn small" do
+ = link_to edit_project_wiki_path(@project, @wiki), :class => "btn small grouped" do
Edit
%hr
.wiki_content