Commit 9023526c authored by Mike Greiling's avatar Mike Greiling

move milestone due date info to sidebar

parent 92e0bd9b
......@@ -62,10 +62,6 @@
}
}
.remaining-days {
color: $orange-600;
}
.milestone-stats-and-buttons {
display: flex;
justify-content: flex-start;
......
......@@ -58,4 +58,4 @@
= render 'shared/milestones/summary', milestone: @milestone, project: @project
= render 'shared/milestones/tabs', milestone: @milestone
= render 'shared/milestones/sidebar', milestone: @milestone, affix_offset: 153
= render 'shared/milestones/sidebar', milestone: @milestone, project: @project, affix_offset: 153
- affix_offset = local_assigns.fetch(:affix_offset, "102")
- project = local_assigns[:project]
%aside.right-sidebar.js-right-sidebar{ data: { "offset-top" => affix_offset, "spy" => "affix" }, class: sidebar_gutter_collapsed_class, 'aria-live' => 'polite' }
.issuable-sidebar
......@@ -9,6 +10,27 @@
%span.issuable-header-text.hide-collapsed
Milestone #{milestone.try(:to_reference) || milestone.title}
- if project
.block.due_date
.sidebar-collapsed-icon
= icon('calendar', 'aria-hidden': 'true')
%span.js-due-date-sidebar-value
= milestone.due_date.try(:to_s, :medium) || 'None'
.title.hide-collapsed
Due date
- if can?(current_user, :admin_milestone, @project)
= link_to 'Edit', edit_namespace_project_milestone_path(@project.namespace, @project, @milestone), class: 'edit-link pull-right'
.value.hide-collapsed
%span.value-content
- if milestone.due_date
%span.bold= milestone.due_date.to_s(:medium)
- else
%span.no-value No due date
- remaining_days = milestone_remaining_days(milestone)
- if remaining_days.present?
= surround '(', ')' do
%span.remaining-days= remaining_days
- milestone_ref = milestone.try(:to_reference, full: true)
- if milestone_ref.present?
.block
......
......@@ -26,10 +26,6 @@
%span.milestone-stat
%strong== #{milestone.percent_complete(current_user)}%
complete
- remaining_days = milestone_remaining_days(milestone)
- if remaining_days.present?
%span.milestone-stat
%span.remaining-days= remaining_days
.milestone-progress-buttons
%span.tab-issues-buttons
......
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