Commit 700a342e authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Restyle group pages. Merge header with page title

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent dad163b7
...@@ -27,6 +27,11 @@ ...@@ -27,6 +27,11 @@
border-bottom: 1px solid #e7e9ed; border-bottom: 1px solid #e7e9ed;
color: $gl-gray; color: $gl-gray;
&.second-block {
margin-top: -1px;
margin-bottom: 0;
}
&.footer-block { &.footer-block {
margin-top: 0; margin-top: 0;
margin-bottom: -$gl-padding; margin-bottom: -$gl-padding;
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
/** COMMON CLASSES **/ /** COMMON CLASSES **/
.prepend-top-10 { margin-top:10px } .prepend-top-10 { margin-top:10px }
.prepend-top-default { margin-top: $gl-padding; }
.prepend-top-20 { margin-top:20px } .prepend-top-20 { margin-top:20px }
.prepend-left-10 { margin-left:10px } .prepend-left-10 { margin-left:10px }
.prepend-left-20 { margin-left:20px } .prepend-left-20 { margin-left:20px }
......
...@@ -30,4 +30,13 @@ module GroupsHelper ...@@ -30,4 +30,13 @@ module GroupsHelper
image_path('no_group_avatar.png') image_path('no_group_avatar.png')
end end
end end
def group_title(group, name, url)
content_tag :span do
link_to(
simple_sanitize(group.name), group_path(group)
) + ' &middot; '.html_safe +
link_to(simple_sanitize(name), url)
end
end
end end
- page_title "Issues" - page_title "Issues"
- header_title group_title(@group, "Issues", issues_group_path(@group))
= content_for :meta_tags do = content_for :meta_tags do
- if current_user - if current_user
= auto_discovery_link_tag(:atom, issues_group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} issues") = auto_discovery_link_tag(:atom, issues_group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} issues")
%h3.page-title
Issues
%p.light
Only issues from
%strong #{@group.name}
group are listed here.
- if current_user
To see all issues you should visit #{link_to 'dashboard', issues_dashboard_path} page.
%hr
.append-bottom-20 = render 'shared/issuable/filter', type: :issues
.gray-content-block.second-block
.pull-right .pull-right
- if current_user - if current_user
.hidden-xs.pull-left .hidden-xs.pull-left
= link_to issues_group_url(@group, format: :atom, private_token: current_user.private_token), class: 'btn' do = link_to issues_group_url(@group, format: :atom, private_token: current_user.private_token) do
%i.fa.fa-rss %i.fa.fa-rss
%div
Only issues from
%strong #{@group.name}
group are listed here.
- if current_user
To see all issues you should visit #{link_to 'dashboard', issues_dashboard_path} page.
= render 'shared/issuable/filter', type: :issues .prepend-top-default
= render 'shared/issues' = render 'shared/issues'
- page_title "Merge Requests" - page_title "Merge Requests"
%h3.page-title - header_title group_title(@group, "Merge Requests", merge_requests_group_path(@group))
Merge Requests
%p.light = render 'shared/issuable/filter', type: :merge_requests
Only merge requests from .gray-content-block.second-block
%strong #{@group.name} %div
group are listed here. Only merge requests from
- if current_user %strong #{@group.name}
To see all merge requests you should visit #{link_to 'dashboard', merge_requests_dashboard_path} page. group are listed here.
%hr - if current_user
.append-bottom-20 To see all merge requests you should visit #{link_to 'dashboard', merge_requests_dashboard_path} page.
= render 'shared/issuable/filter', type: :merge_requests .prepend-top-default
= render 'shared/merge_requests' = render 'shared/merge_requests'
- page_title "Milestones" - page_title "Milestones"
%h3.page-title - header_title group_title(@group, "Milestones", group_milestones_path(@group))
Milestones
%span.pull-right #{@group_milestones.count} milestones
%p.light = render 'shared/milestones_filter'
.gray-content-block
Only milestones from Only milestones from
%strong #{@group.name} %strong #{@group.name}
group are listed here. group are listed here.
%hr
= render 'shared/milestones_filter'
.milestones .milestones
.panel.panel-default %ul.content-list
%ul.well-list - if @group_milestones.blank?
- if @group_milestones.blank? %li
%li .nothing-here-block No milestones to show
.nothing-here-block No milestones to show - else
- else - @group_milestones.each do |milestone|
- @group_milestones.each do |milestone| = render 'milestone', milestone: milestone
= render 'milestone', milestone: milestone
= paginate @group_milestones, theme: "gitlab" = paginate @group_milestones, theme: "gitlab"
- page_title @group.name - page_title @group.name
- header_title @group.name, group_path(@group) - unless @header_title
- header_title @group.name, group_path(@group)
- sidebar "group" unless sidebar - sidebar "group" unless sidebar
= render template: "layouts/application" = render template: "layouts/application"
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