Commit 63d5fcc868b0502c7d56a093256a4fcb270a8728

Authored by Dmitriy Zaporozhets
1 parent d1e84958

UI: allign milestone to right for issue, mr show page

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
app/assets/stylesheets/selects.scss
@@ -51,3 +51,7 @@ @@ -51,3 +51,7 @@
51 .chosen-container .chosen-drop .chosen-search input { 51 .chosen-container .chosen-drop .chosen-search input {
52 background-position-y: -24px !important; 52 background-position-y: -24px !important;
53 } 53 }
  54 +
  55 +.chosen-compact {
  56 + max-width: 170px !important;
  57 +}
app/views/projects/issues/_issue_context.html.haml
@@ -11,14 +11,16 @@ @@ -11,14 +11,16 @@
11 - elsif issue.assignee 11 - elsif issue.assignee
12 = link_to_member(@project, @issue.assignee) 12 = link_to_member(@project, @issue.assignee)
13 13
14 - - if issue.milestone  
15 - - milestone = issue.milestone  
16 - %cite.cgray and attached to milestone  
17 14
18 - - if can?(current_user, :modify_issue, @issue)  
19 - = f.select(:milestone_id, milestone_options(@issue), { include_blank: "Select milestone (none):" }, {class: 'chosen'}) 15 + .pull-right
  16 + - if issue.milestone
  17 + - milestone = issue.milestone
  18 + %cite.cgray Attached to milestone
  19 +
  20 + - if can?(current_user, :modify_issue, @issue)
  21 + = f.select(:milestone_id, milestone_options(@issue), { include_blank: "Select milestone (none):" }, {class: 'chosen chosen-compact'})
20 22
21 - = hidden_field_tag :issue_context  
22 - = f.submit class: 'btn'  
23 - - elsif issue.milestone  
24 - = link_to issue.milestone.title, project_milestone_path 23 + = hidden_field_tag :issue_context
  24 + = f.submit class: 'btn'
  25 + - elsif issue.milestone
  26 + = link_to issue.milestone.title, project_milestone_path
app/views/projects/merge_requests/show/_mr_box.html.haml
@@ -17,10 +17,10 @@ @@ -17,10 +17,10 @@
17 - if @merge_request.assignee 17 - if @merge_request.assignee
18 Currently assigned to #{link_to_member(@project, @merge_request.assignee)}. 18 Currently assigned to #{link_to_member(@project, @merge_request.assignee)}.
19 - if @merge_request.milestone 19 - if @merge_request.milestone
20 - - milestone = @merge_request.milestone  
21 - %cite.cgray Attached to milestone  
22 - %strong= link_to_gfm truncate(milestone.title, length: 20), project_milestone_path(milestone.project, milestone)  
23 - \. 20 + .pull-right
  21 + - milestone = @merge_request.milestone
  22 + %cite.cgray Attached to milestone
  23 + %strong= link_to_gfm truncate(milestone.title, length: 20), project_milestone_path(milestone.project, milestone)
24 24
25 25
26 - if @merge_request.description.present? 26 - if @merge_request.description.present?