Commit 2d68e7f4cd0ce60e340891fd2dfa2e479bb173ec
1 parent
d6ed9920
Exists in
master
and in
4 other branches
MR -> remove source branch -> UI pollished
Showing
3 changed files
with
67 additions
and
14 deletions
Show diff stats
app/assets/stylesheets/common.scss
| ... | ... | @@ -714,6 +714,19 @@ p.time { |
| 714 | 714 | text-align:center; |
| 715 | 715 | float:left; |
| 716 | 716 | margin-right:20px; |
| 717 | + | |
| 718 | + &.success { | |
| 719 | + background: #5BB75B; | |
| 720 | + color: white; | |
| 721 | + text-shadow: 0 1px #111; | |
| 722 | + border-color: #9A9; | |
| 723 | + } | |
| 724 | + &.error { | |
| 725 | + background: #DA4E49; | |
| 726 | + border-color: #BD362F; | |
| 727 | + color: white; | |
| 728 | + text-shadow: 0 1px #111; | |
| 729 | + } | |
| 717 | 730 | } |
| 718 | 731 | |
| 719 | 732 | .arrow{ |
| ... | ... | @@ -864,15 +877,36 @@ li.note { |
| 864 | 877 | background: #DFF0D8; |
| 865 | 878 | } |
| 866 | 879 | |
| 867 | - .accept_merge_request { | |
| 868 | - color: #fff; | |
| 869 | - text-shadow: 0 1px 1px #222; | |
| 870 | - background: #5bb75b;; | |
| 871 | - &:hover { | |
| 872 | - background-color: #51a351; | |
| 873 | - color: #fff; | |
| 880 | + | |
| 881 | + form { | |
| 882 | + margin-bottom:0; | |
| 883 | + .clearfix { | |
| 884 | + margin-bottom:0; | |
| 874 | 885 | } |
| 875 | 886 | } |
| 887 | + | |
| 888 | + .accept_group { | |
| 889 | + float:left; | |
| 890 | + border: 1px solid #ADA; | |
| 891 | + padding: 2px; | |
| 892 | + @include border-radius(5px); | |
| 893 | + border-radius: 5px; | |
| 894 | + background: #CEB; | |
| 895 | + | |
| 896 | + .accept_merge_request { | |
| 897 | + float:left; | |
| 898 | + } | |
| 899 | + .remove_branch_holder { | |
| 900 | + margin-left:20px; | |
| 901 | + margin-right:10px; | |
| 902 | + float:left; | |
| 903 | + } | |
| 904 | + label { | |
| 905 | + color:#444; | |
| 906 | + } | |
| 907 | + } | |
| 908 | + | |
| 909 | + | |
| 876 | 910 | .how_to_merge_link { |
| 877 | 911 | @extend .primary; |
| 878 | 912 | } | ... | ... |
app/assets/stylesheets/gitlab_bootstrap.scss
| ... | ... | @@ -127,6 +127,18 @@ table { |
| 127 | 127 | @extend .btn-primary; |
| 128 | 128 | } |
| 129 | 129 | |
| 130 | + &.success { | |
| 131 | + color: #fff; | |
| 132 | + text-shadow: 0 0 1px #111; | |
| 133 | + background: #5bb75b;; | |
| 134 | + font-weight: bold; | |
| 135 | + | |
| 136 | + &:hover { | |
| 137 | + background-color: #51a351; | |
| 138 | + color: #fff; | |
| 139 | + } | |
| 140 | + } | |
| 141 | + | |
| 130 | 142 | &.danger, |
| 131 | 143 | &.btn-danger { |
| 132 | 144 | color:#fff; | ... | ... |
app/views/merge_requests/show.html.haml
| ... | ... | @@ -8,7 +8,7 @@ |
| 8 | 8 | %span.right |
| 9 | 9 | - if can?(current_user, :modify_merge_request, @merge_request) |
| 10 | 10 | - if @merge_request.open? |
| 11 | - = link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "btn small padded", :title => "Close merge request" | |
| 11 | + = link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "btn small padded danger", :title => "Close merge request" | |
| 12 | 12 | = link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn small padded" do |
| 13 | 13 | %i.icon-edit |
| 14 | 14 | Edit |
| ... | ... | @@ -63,13 +63,20 @@ |
| 63 | 63 | .alert.alert-success |
| 64 | 64 | %span |
| 65 | 65 | = form_for [:automerge, @project, @merge_request], :remote => true, :method => :get do |f| |
| 66 | - You can accept this request automatically. If you still want to do it manually - #{link_to "click here", "#", :class => "how_to_merge_link vlink", :title => "How To Merge"} for instructions | |
| 67 | - %br | |
| 68 | - -unless @project.root_ref? @merge_request.source_branch | |
| 69 | - = check_box_tag :should_remove_source_branch | |
| 70 | - = label_tag :should_remove_source_branch, "Remove source-branch" | |
| 66 | + %p | |
| 67 | + You can accept this request automatically. | |
| 68 | + If you still want to do it manually - | |
| 69 | + %strong= link_to "click here", "#", :class => "how_to_merge_link vlink", :title => "How To Merge" | |
| 70 | + for instructions | |
| 71 | + .accept_group | |
| 72 | + = f.submit "Accept Merge Request", :class => "btn small success accept_merge_request" | |
| 73 | + - unless @project.root_ref? @merge_request.source_branch | |
| 74 | + .remove_branch_holder | |
| 75 | + = label_tag :should_remove_source_branch, :class => "checkbox" do | |
| 76 | + = check_box_tag :should_remove_source_branch | |
| 77 | + Remove source-branch | |
| 78 | + .clearfix | |
| 71 | 79 | |
| 72 | - = f.submit "Accept Merge Request", :class => "btn small info accept_merge_request" | |
| 73 | 80 | |
| 74 | 81 | .automerge_widget.cannot_be_merged{:style => "display:none"} |
| 75 | 82 | .alert.alert-info | ... | ... |