Commit f92b1f3d018bf51e9372b88dd50a2be8149b2fa6
1 parent
499a1185
Exists in
spb-stable
and in
3 other branches
Use more specific class names: grouped -> btn-grouped
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing
18 changed files
with
43 additions
and
46 deletions
Show diff stats
app/assets/stylesheets/generic/buttons.scss
... | ... | @@ -158,6 +158,14 @@ |
158 | 158 | color: #468847; |
159 | 159 | } |
160 | 160 | } |
161 | + | |
162 | + &.btn-grouped { | |
163 | + margin-right: 7px; | |
164 | + float: left; | |
165 | + &:last-child { | |
166 | + margin-right: 0px; | |
167 | + } | |
168 | + } | |
161 | 169 | } |
162 | 170 | |
163 | 171 | .btn-block { |
... | ... | @@ -169,16 +177,5 @@ |
169 | 177 | } |
170 | 178 | } |
171 | 179 | |
172 | -.btn, | |
173 | -.btn-group { | |
174 | - &.grouped { | |
175 | - margin-right: 7px; | |
176 | - float: left; | |
177 | - &:last-child { | |
178 | - margin-right: 0px; | |
179 | - } | |
180 | - } | |
181 | -} | |
182 | - | |
183 | 180 | .btn-group-small > .btn { @extend .btn.btn-small; } |
184 | 181 | .btn-group-tiny > .btn { @extend .btn.btn-tiny; } | ... | ... |
app/views/admin/users/show.html.haml
app/views/profiles/groups/index.html.haml
... | ... | @@ -18,12 +18,12 @@ |
18 | 18 | %li |
19 | 19 | .pull-right |
20 | 20 | - if can?(current_user, :manage_group, group) |
21 | - = link_to edit_group_path(group), class: "btn-small btn grouped" do | |
21 | + = link_to edit_group_path(group), class: "btn-small btn btn-grouped" do | |
22 | 22 | %i.icon-cogs |
23 | 23 | Settings |
24 | 24 | |
25 | 25 | - if can?(current_user, :destroy, user_group) |
26 | - = link_to leave_profile_group_path(group), data: { confirm: leave_group_message(group.name) }, method: :delete, class: "btn-small btn grouped", title: 'Remove user from group' do | |
26 | + = link_to leave_profile_group_path(group), data: { confirm: leave_group_message(group.name) }, method: :delete, class: "btn-small btn btn-grouped", title: 'Remove user from group' do | |
27 | 27 | %i.icon-signout |
28 | 28 | Leave |
29 | 29 | ... | ... |
app/views/projects/branches/_branch.html.haml
... | ... | @@ -12,12 +12,12 @@ |
12 | 12 | - if can?(current_user, :download_code, @project) |
13 | 13 | = render 'projects/repositories/download_archive', ref: branch.name, btn_class: 'grouped btn-group-small' |
14 | 14 | - if branch.name != @repository.root_ref |
15 | - = link_to project_compare_index_path(@project, from: @repository.root_ref, to: branch.name), class: 'btn grouped btn-small', method: :post, title: "Compare" do | |
15 | + = link_to project_compare_index_path(@project, from: @repository.root_ref, to: branch.name), class: 'btn btn-grouped btn-small', method: :post, title: "Compare" do | |
16 | 16 | %i.icon-copy |
17 | 17 | Compare |
18 | 18 | |
19 | 19 | - if can?(current_user, :admin_project, @project) && branch.name != @repository.root_ref |
20 | - = link_to project_branch_path(@project, branch.name), class: 'btn grouped btn-small remove-row', method: :delete, data: { confirm: 'Removed branch cannot be restored. Are you sure?'}, remote: true do | |
20 | + = link_to project_branch_path(@project, branch.name), class: 'btn btn-grouped btn-small remove-row', method: :delete, data: { confirm: 'Removed branch cannot be restored. Are you sure?'}, remote: true do | |
21 | 21 | %i.icon-trash |
22 | 22 | |
23 | 23 | - if commit | ... | ... |
app/views/projects/commit/_commit_box.html.haml
... | ... | @@ -12,7 +12,7 @@ |
12 | 12 | %ul.dropdown-menu |
13 | 13 | %li= link_to "Email Patches", project_commit_path(@project, @commit, format: :patch) |
14 | 14 | %li= link_to "Plain Diff", project_commit_path(@project, @commit, format: :diff) |
15 | - = link_to project_tree_path(@project, @commit), class: "btn btn-primary grouped" do | |
15 | + = link_to project_tree_path(@project, @commit), class: "btn btn-primary btn-grouped" do | |
16 | 16 | %span Browse Code » |
17 | 17 | %div |
18 | 18 | ... | ... |
app/views/projects/hooks/index.html.haml
... | ... | @@ -51,8 +51,8 @@ |
51 | 51 | - @hooks.each do |hook| |
52 | 52 | %li |
53 | 53 | .pull-right |
54 | - = link_to 'Test Hook', test_project_hook_path(@project, hook), class: "btn btn-small grouped" | |
55 | - = link_to 'Remove', project_hook_path(@project, hook), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-remove btn-small grouped" | |
54 | + = link_to 'Test Hook', test_project_hook_path(@project, hook), class: "btn btn-small btn-grouped" | |
55 | + = link_to 'Remove', project_hook_path(@project, hook), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-remove btn-small btn-grouped" | |
56 | 56 | .clearfix |
57 | 57 | %span.monospace= hook.url |
58 | 58 | %p | ... | ... |
app/views/projects/issues/_issue.html.haml
... | ... | @@ -38,10 +38,10 @@ |
38 | 38 | .issue-actions |
39 | 39 | - if can? current_user, :modify_issue, issue |
40 | 40 | - if issue.closed? |
41 | - = link_to 'Reopen', project_issue_path(issue.project, issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn btn-small grouped reopen_issue", remote: true | |
41 | + = link_to 'Reopen', project_issue_path(issue.project, issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn btn-small btn-grouped reopen_issue", remote: true | |
42 | 42 | - else |
43 | - = link_to 'Close', project_issue_path(issue.project, issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn btn-small grouped close_issue", remote: true | |
44 | - = link_to edit_project_issue_path(issue.project, issue), class: "btn btn-small edit-issue-link grouped" do | |
43 | + = link_to 'Close', project_issue_path(issue.project, issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn btn-small btn-grouped close_issue", remote: true | |
44 | + = link_to edit_project_issue_path(issue.project, issue), class: "btn btn-small edit-issue-link btn-grouped" do | |
45 | 45 | %i.icon-edit |
46 | 46 | Edit |
47 | 47 | ... | ... |
app/views/projects/issues/show.html.haml
... | ... | @@ -3,16 +3,16 @@ |
3 | 3 | |
4 | 4 | %span.pull-right |
5 | 5 | - if can?(current_user, :write_issue, @project) |
6 | - = link_to new_project_issue_path(@project), class: "btn grouped", title: "New Issue", id: "new_issue_link" do | |
6 | + = link_to new_project_issue_path(@project), class: "btn btn-grouped", title: "New Issue", id: "new_issue_link" do | |
7 | 7 | %i.icon-plus |
8 | 8 | New Issue |
9 | 9 | - if can?(current_user, :modify_issue, @issue) |
10 | 10 | - if @issue.closed? |
11 | - = link_to 'Reopen', project_issue_path(@project, @issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn grouped btn-reopen" | |
11 | + = link_to 'Reopen', project_issue_path(@project, @issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn btn-grouped btn-reopen" | |
12 | 12 | - else |
13 | - = link_to 'Close', project_issue_path(@project, @issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn grouped btn-close", title: "Close Issue" | |
13 | + = link_to 'Close', project_issue_path(@project, @issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn btn-grouped btn-close", title: "Close Issue" | |
14 | 14 | |
15 | - = link_to edit_project_issue_path(@project, @issue), class: "btn grouped" do | |
15 | + = link_to edit_project_issue_path(@project, @issue), class: "btn btn-grouped" do | |
16 | 16 | %i.icon-edit |
17 | 17 | Edit |
18 | 18 | |
... | ... | @@ -55,9 +55,9 @@ |
55 | 55 | - content_for :note_actions do |
56 | 56 | - if can?(current_user, :modify_issue, @issue) |
57 | 57 | - if @issue.closed? |
58 | - = link_to 'Reopen Issue', project_issue_path(@project, @issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn grouped btn-reopen" | |
58 | + = link_to 'Reopen Issue', project_issue_path(@project, @issue, issue: {state_event: :reopen }, status_only: true), method: :put, class: "btn btn-grouped btn-reopen" | |
59 | 59 | - else |
60 | - = link_to 'Close Issue', project_issue_path(@project, @issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn grouped btn-close", title: "Close Issue" | |
60 | + = link_to 'Close Issue', project_issue_path(@project, @issue, issue: {state_event: :close }, status_only: true), method: :put, class: "btn btn-grouped btn-close", title: "Close Issue" | |
61 | 61 | |
62 | 62 | .participants |
63 | 63 | %cite.cgray #{@issue.participants.count} participants | ... | ... |
app/views/projects/merge_requests/_show.html.haml
... | ... | @@ -25,7 +25,7 @@ |
25 | 25 | - content_for :note_actions do |
26 | 26 | - if can?(current_user, :modify_merge_request, @merge_request) |
27 | 27 | - unless @merge_request.closed? |
28 | - = link_to 'Close', project_merge_request_path(@project, @merge_request, merge_request: {state_event: :close }), method: :put, class: "btn grouped btn-close", title: "Close merge request" | |
28 | + = link_to 'Close', project_merge_request_path(@project, @merge_request, merge_request: {state_event: :close }), method: :put, class: "btn btn-grouped btn-close", title: "Close merge request" | |
29 | 29 | |
30 | 30 | |
31 | 31 | .notes.tab-content.voting_notes#notes{ class: (controller.action_name == 'show') ? "" : "hide" } | ... | ... |
app/views/projects/merge_requests/show/_mr_title.html.haml
... | ... | @@ -13,9 +13,9 @@ |
13 | 13 | %li= link_to "Email Patches", project_merge_request_path(@project, @merge_request, format: :patch) |
14 | 14 | %li= link_to "Plain Diff", project_merge_request_path(@project, @merge_request, format: :diff) |
15 | 15 | |
16 | - = link_to 'Close', project_merge_request_path(@project, @merge_request, merge_request: { state_event: :close }), method: :put, class: "btn grouped btn-close", title: "Close merge request" | |
16 | + = link_to 'Close', project_merge_request_path(@project, @merge_request, merge_request: { state_event: :close }), method: :put, class: "btn btn-grouped btn-close", title: "Close merge request" | |
17 | 17 | |
18 | - = link_to edit_project_merge_request_path(@project, @merge_request), class: "btn grouped", id:"edit_merge_request" do | |
18 | + = link_to edit_project_merge_request_path(@project, @merge_request), class: "btn btn-grouped", id:"edit_merge_request" do | |
19 | 19 | %i.icon-edit |
20 | 20 | Edit |
21 | 21 | ... | ... |
app/views/projects/milestones/_milestone.html.haml
1 | 1 | %li{class: "milestone milestone-#{milestone.closed? ? 'closed' : 'open'}", id: dom_id(milestone) } |
2 | 2 | .pull-right |
3 | 3 | - if can?(current_user, :admin_milestone, milestone.project) and milestone.active? |
4 | - = link_to edit_project_milestone_path(milestone.project, milestone), class: "btn btn-small edit-milestone-link grouped" do | |
4 | + = link_to edit_project_milestone_path(milestone.project, milestone), class: "btn btn-small edit-milestone-link btn-grouped" do | |
5 | 5 | %i.icon-edit |
6 | 6 | Edit |
7 | 7 | = link_to 'Close Milestone', project_milestone_path(@project, milestone, milestone: {state_event: :close }), method: :put, remote: true, class: "btn btn-small btn-remove" | ... | ... |
app/views/projects/milestones/show.html.haml
... | ... | @@ -11,13 +11,13 @@ |
11 | 11 | %span.state-label.state-label-green Open |
12 | 12 | .pull-right |
13 | 13 | - if can?(current_user, :admin_milestone, @project) |
14 | - = link_to edit_project_milestone_path(@project, @milestone), class: "btn grouped" do | |
14 | + = link_to edit_project_milestone_path(@project, @milestone), class: "btn btn-grouped" do | |
15 | 15 | %i.icon-edit |
16 | 16 | Edit |
17 | 17 | - if @milestone.active? |
18 | 18 | = link_to 'Close Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :close }), method: :put, class: "btn btn-remove grouped" |
19 | 19 | - else |
20 | - = link_to 'Reopen Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn grouped" | |
20 | + = link_to 'Reopen Milestone', project_milestone_path(@project, @milestone, milestone: {state_event: :activate }), method: :put, class: "btn btn-grouped" | |
21 | 21 | |
22 | 22 | - if @milestone.issues.any? && @milestone.can_be_closed? |
23 | 23 | .alert.alert-success |
... | ... | @@ -63,10 +63,10 @@ |
63 | 63 | %span.badge= @users.count |
64 | 64 | |
65 | 65 | .pull-right |
66 | - = link_to new_project_issue_path(@project, issue: { milestone_id: @milestone.id }), class: "btn btn-small grouped", title: "New Issue" do | |
66 | + = link_to new_project_issue_path(@project, issue: { milestone_id: @milestone.id }), class: "btn btn-small btn-grouped", title: "New Issue" do | |
67 | 67 | %i.icon-plus |
68 | 68 | New Issue |
69 | - = link_to 'Browse Issues', project_issues_path(@milestone.project, milestone_id: @milestone.id), class: "btn btn-small edit-milestone-link grouped" | |
69 | + = link_to 'Browse Issues', project_issues_path(@milestone.project, milestone_id: @milestone.id), class: "btn btn-small edit-milestone-link btn-grouped" | |
70 | 70 | |
71 | 71 | .tab-content |
72 | 72 | .tab-pane.active#tab-issues | ... | ... |
app/views/projects/notes/_form.html.haml
... | ... | @@ -22,7 +22,7 @@ |
22 | 22 | |
23 | 23 | .note-form-actions |
24 | 24 | .buttons |
25 | - = f.submit 'Add Comment', class: "btn comment-btn grouped js-comment-button" | |
25 | + = f.submit 'Add Comment', class: "btn comment-btn btn-grouped js-comment-button" | |
26 | 26 | = yield(:note_actions) |
27 | 27 | |
28 | 28 | %a.btn.grouped.js-close-discussion-note-form Cancel | ... | ... |
app/views/projects/team_members/index.html.haml
... | ... | @@ -3,9 +3,9 @@ |
3 | 3 | |
4 | 4 | - if can? current_user, :admin_team_member, @project |
5 | 5 | %span.pull-right |
6 | - = link_to new_project_team_member_path(@project), class: "btn btn-new grouped", title: "New project member" do | |
6 | + = link_to new_project_team_member_path(@project), class: "btn btn-new btn-grouped", title: "New project member" do | |
7 | 7 | New project member |
8 | - = link_to import_project_team_members_path(@project), class: "btn grouped", title: "Import members from another project" do | |
8 | + = link_to import_project_team_members_path(@project), class: "btn btn-grouped", title: "Import members from another project" do | |
9 | 9 | Import members |
10 | 10 | |
11 | 11 | %p.light | ... | ... |
app/views/projects/walls/show.html.haml
... | ... | @@ -9,7 +9,7 @@ |
9 | 9 | = f.text_area :note, size: 255, class: 'note_text js-note-text js-gfm-input turn-on' |
10 | 10 | .note-form-actions |
11 | 11 | .buttons |
12 | - = f.submit 'Add Comment', class: "btn comment-btn grouped js-comment-button" | |
12 | + = f.submit 'Add Comment', class: "btn comment-btn btn-grouped js-comment-button" | |
13 | 13 | |
14 | 14 | .note-form-option |
15 | 15 | %a.choose-btn.btn.btn-small.js-choose-note-attachment-button | ... | ... |
app/views/projects/wikis/_main_links.html.haml
1 | 1 | %span.pull-right |
2 | 2 | - if (@wiki && @wiki.persisted?) |
3 | - = link_to history_project_wiki_path(@project, @wiki), class: "btn grouped" do | |
3 | + = link_to history_project_wiki_path(@project, @wiki), class: "btn btn-grouped" do | |
4 | 4 | Page History |
5 | 5 | - if can?(current_user, :write_wiki, @project) |
6 | - = link_to edit_project_wiki_path(@project, @wiki), class: "btn grouped" do | |
6 | + = link_to edit_project_wiki_path(@project, @wiki), class: "btn btn-grouped" do | |
7 | 7 | %i.icon-edit |
8 | 8 | Edit | ... | ... |
app/views/snippets/current_user_index.html.haml
1 | 1 | %h3.page-title |
2 | 2 | My Snippets |
3 | 3 | .pull-right |
4 | - = link_to new_snippet_path, class: "btn btn-new grouped", title: "New Snippet" do | |
4 | + = link_to new_snippet_path, class: "btn btn-new btn-grouped", title: "New Snippet" do | |
5 | 5 | Add new snippet |
6 | - = link_to snippets_path, class: "btn grouped" do | |
6 | + = link_to snippets_path, class: "btn btn-grouped" do | |
7 | 7 | Discover snippets |
8 | 8 | |
9 | 9 | %p.light | ... | ... |
app/views/snippets/index.html.haml
... | ... | @@ -2,9 +2,9 @@ |
2 | 2 | Public snippets |
3 | 3 | |
4 | 4 | .pull-right |
5 | - = link_to new_snippet_path, class: "btn btn-new grouped", title: "New Snippet" do | |
5 | + = link_to new_snippet_path, class: "btn btn-new btn-grouped", title: "New Snippet" do | |
6 | 6 | Add new snippet |
7 | - = link_to user_snippets_path(current_user), class: "btn grouped" do | |
7 | + = link_to user_snippets_path(current_user), class: "btn btn-grouped" do | |
8 | 8 | My snippets |
9 | 9 | |
10 | 10 | %p.light | ... | ... |