Commit 60bb7007 authored by Phil Hughes's avatar Phil Hughes Committed by Jacob Schatz

Merge request header markup now matches issue markup for consistancy

parent fd42b0db
- page_title "#{@merge_request.title} (#{@merge_request.to_reference})", "Merge Requests" - page_title "#{@merge_request.title} (#{@merge_request.to_reference})", "Merge Requests"
- page_description @merge_request.description - page_description @merge_request.description
- page_card_attributes @merge_request.card_attributes - page_card_attributes @merge_request.card_attributes
- header_title project_title(@project, "Merge Requests", namespace_project_merge_requests_path(@project.namespace, @project))
= render "header_title"
- if params[:view] == 'parallel' - if params[:view] == 'parallel'
- fluid_layout true - fluid_layout true
......
.detail-page-header .clearfix.detail-page-header
.status-box{ class: status_box_class(@merge_request) } .issuable-header
%span.hidden-xs .issuable-status-box.status-box{ class: "#{status_box_class(@merge_request)}" }
= @merge_request.state_human_name = icon(@merge_request.state_icon_name, class: "hidden-sm hidden-md hidden-lg")
%span.hidden-sm.hidden-md.hidden-lg
= icon(@merge_request.state_icon_name)
%a.btn.btn-default.pull-right.visible-xs-block.gutter-toggle.js-sidebar-toggle{ href: "#" }
= icon('angle-double-left')
.issue-meta
%strong.identifier
%span.hidden-sm.hidden-md.hidden-lg
MR
%span.hidden-xs %span.hidden-xs
Merge Request = @merge_request.state_human_name
!#{@merge_request.iid}
%span.creator %a.btn.btn-default.pull-right.visible-xs-block.gutter-toggle.issuable-gutter-toggle.js-sidebar-toggle{ href: "#" }
= icon('angle-double-left')
.issuable-meta
%strong.identifier
Merge Request #{@merge_request.to_reference}
opened opened
.editor-details = time_ago_with_tooltip(@merge_request.created_at)
= time_ago_with_tooltip(@merge_request.created_at) by
by %strong
%strong = link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-xs")
= link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-xs") = link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-sm hidden-md hidden-lg", by_username: true, avatar: false)
%strong
= link_to_member(@project, @merge_request.author, size: 24, mobile_classes: "hidden-sm hidden-md hidden-lg",
by_username: true, avatar: false)
.issue-btn-group.pull-right - if can?(current_user, :update_merge_request, @merge_request)
- if can?(current_user, :update_merge_request, @merge_request) .issuable-actions
- if @merge_request.open? .clearfix.issue-btn-group.dropdown
= link_to 'Close', merge_request_path(@merge_request, merge_request: { state_event: :close }), method: :put, class: 'btn btn-nr btn-grouped btn-close', title: 'Close merge request' %button.btn.btn-default.pull-left.hidden-md.hidden-lg{ data: { toggle: "dropdown" } }
= link_to edit_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'btn btn-nr btn-grouped issuable-edit', id: 'edit_merge_request' do %span.caret
= icon('pencil-square-o') Options
Edit .dropdown-menu.dropdown-menu-align-right.hidden-lg
- if @merge_request.closed? %ul
= link_to 'Reopen', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: 'btn btn-nr btn-grouped btn-reopen reopen-mr-link', title: 'Reopen merge request' - if @merge_request.open?
%li
= link_to 'Close', merge_request_path(@merge_request, merge_request: { state_event: :close }), method: :put, title: 'Close merge request'
%li
= link_to 'Edit', edit_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'issuable-edit', id: 'edit_merge_request'
- if @merge_request.closed?
%li
= link_to 'Reopen', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: 'reopen-mr-link', title: 'Reopen merge request'
- if @merge_request.open?
= link_to 'Close', merge_request_path(@merge_request, merge_request: { state_event: :close }), method: :put, class: 'hidden-xs hidden-sm btn btn-nr btn-grouped btn-close', title: 'Close merge request'
= link_to edit_namespace_project_merge_request_path(@project.namespace, @project, @merge_request), class: 'hidden-xs hidden-sm btn btn-nr btn-grouped issuable-edit', id: 'edit_merge_request' do
= icon('pencil-square-o')
Edit
- if @merge_request.closed?
= link_to 'Reopen', merge_request_path(@merge_request, merge_request: {state_event: :reopen }), method: :put, class: 'hidden-xs hidden-sm btn btn-nr btn-grouped btn-reopen reopen-mr-link', title: 'Reopen merge request'
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