Commit 6e217bd5 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Improve accept mr widget UI

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent c9572857
...@@ -11,10 +11,27 @@ ...@@ -11,10 +11,27 @@
} }
} }
.accept-group { .accept-merge-holder {
label { margin-top: 5px;
margin: 5px;
.accept-action {
display: inline-block;
.accept_merge_request {
padding: 10px 20px;
}
}
.accept-control {
display: inline-block;
margin-left: 20px; margin-left: 20px;
padding: 10px 0;
line-height: 20px;
font-weight: bold;
.checkbox {
margin: 0;
}
} }
} }
} }
......
...@@ -13,22 +13,19 @@ ...@@ -13,22 +13,19 @@
.automerge_widget.can_be_merged.hide .automerge_widget.can_be_merged.hide
.clearfix .clearfix
= form_for [:automerge, @project, @merge_request], remote: true, method: :post do |f| = form_for [:automerge, @project, @merge_request], remote: true, method: :post do |f|
%h4 .accept-merge-holder.clearfix.js-toggle-container
You can accept this request automatically. .accept-action
.accept-merge-holder.clearfix
.accept-group
.pull-left
= f.submit "Accept Merge Request", class: "btn btn-create accept_merge_request" = f.submit "Accept Merge Request", class: "btn btn-create accept_merge_request"
- if can_remove_branch?(@merge_request.source_project, @merge_request.source_branch) && !@merge_request.for_fork? - if can_remove_branch?(@merge_request.source_project, @merge_request.source_branch) && !@merge_request.for_fork?
.remove_branch_holder.pull-left .accept-control
= label_tag :should_remove_source_branch, class: "checkbox" do = label_tag :should_remove_source_branch, class: "checkbox" do
= check_box_tag :should_remove_source_branch = check_box_tag :should_remove_source_branch
Remove source-branch Remove source-branch
.js-toggle-container .accept-control
%label = link_to "#", class: "modify-merge-commit-link js-toggle-button", title: "Modify merge commit message" do
%i.fa.fa-edit %i.fa.fa-edit
= link_to "modify merge commit message", "#", class: "modify-merge-commit-link js-toggle-button", title: "Modify merge commit message" Modify commit message
.js-toggle-content.hide .js-toggle-content.hide.prepend-top-20
= render 'shared/commit_message_container', params: params, = render 'shared/commit_message_container', params: params,
text: @merge_request.merge_commit_message, text: @merge_request.merge_commit_message,
rows: 14, hint: true rows: 14, hint: true
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment