diff options
Diffstat (limited to 'app/views/explore')
-rw-r--r-- | app/views/explore/groups/index.html.haml | 2 | ||||
-rw-r--r-- | app/views/explore/projects/_dropdown.html.haml | 27 | ||||
-rw-r--r-- | app/views/explore/projects/_filter.html.haml | 20 | ||||
-rw-r--r-- | app/views/explore/projects/index.html.haml | 5 | ||||
-rw-r--r-- | app/views/explore/projects/starred.html.haml | 7 | ||||
-rw-r--r-- | app/views/explore/projects/trending.html.haml | 7 |
6 files changed, 43 insertions, 25 deletions
diff --git a/app/views/explore/groups/index.html.haml b/app/views/explore/groups/index.html.haml index f3f0b778539..c34493d0c20 100644 --- a/app/views/explore/groups/index.html.haml +++ b/app/views/explore/groups/index.html.haml @@ -1,4 +1,6 @@ - page_title "Groups" +- if current_user + = render 'dashboard/groups_head' .clearfix .pull-left = form_tag explore_groups_path, method: :get, class: 'form-inline form-tiny' do |f| diff --git a/app/views/explore/projects/_dropdown.html.haml b/app/views/explore/projects/_dropdown.html.haml new file mode 100644 index 00000000000..b23a3c1e5c1 --- /dev/null +++ b/app/views/explore/projects/_dropdown.html.haml @@ -0,0 +1,27 @@ +.dropdown.inline + %button.dropdown-toggle.btn{type: 'button', 'data-toggle' => 'dropdown'} + %span.light sort: + - if @sort.present? + = sort_options_hash[@sort] + - elsif current_page?(trending_explore_projects_path) || current_page?(explore_root_path) + Trending projects + - elsif current_page?(starred_explore_projects_path) + Most stars + - else + = sort_title_recently_created + %b.caret + %ul.dropdown-menu + %li + = link_to trending_explore_projects_path do + Trending projects + = link_to starred_explore_projects_path do + Most stars + = link_to explore_projects_filter_path(sort: sort_value_recently_created) do + = sort_title_recently_created + = link_to explore_projects_filter_path(sort: sort_value_oldest_created) do + = sort_title_oldest_created + = link_to explore_projects_filter_path(sort: sort_value_recently_updated) do + = sort_title_recently_updated + = link_to explore_projects_filter_path(sort: sort_value_oldest_updated) do + = sort_title_oldest_updated + diff --git a/app/views/explore/projects/_filter.html.haml b/app/views/explore/projects/_filter.html.haml index 82622a58ed2..4b91291caf4 100644 --- a/app/views/explore/projects/_filter.html.haml +++ b/app/views/explore/projects/_filter.html.haml @@ -46,22 +46,4 @@ = link_to explore_projects_filter_path(tag: tag.name) do %i.fa.fa-tag = tag.name - - .dropdown.inline - %button.dropdown-toggle.btn{type: 'button', 'data-toggle' => 'dropdown'} - %span.light sort: - - if @sort.present? - = sort_options_hash[@sort] - - else - = sort_title_recently_created - %b.caret - %ul.dropdown-menu - %li - = link_to explore_projects_filter_path(sort: sort_value_recently_created) do - = sort_title_recently_created - = link_to explore_projects_filter_path(sort: sort_value_oldest_created) do - = sort_title_oldest_created - = link_to explore_projects_filter_path(sort: sort_value_recently_updated) do - = sort_title_recently_updated - = link_to explore_projects_filter_path(sort: sort_value_oldest_updated) do - = sort_title_oldest_updated + = render 'explore/projects/dropdown' diff --git a/app/views/explore/projects/index.html.haml b/app/views/explore/projects/index.html.haml index ba2276f51ce..4956081e1ed 100644 --- a/app/views/explore/projects/index.html.haml +++ b/app/views/explore/projects/index.html.haml @@ -1,8 +1,9 @@ - page_title "Projects" +- if current_user + = render 'dashboard/projects_head' .clearfix = render 'filter' - -%hr +%br .public-projects %ul.bordered-list.top-list = render @projects diff --git a/app/views/explore/projects/starred.html.haml b/app/views/explore/projects/starred.html.haml index b5d146b1f2f..fdccbe5692f 100644 --- a/app/views/explore/projects/starred.html.haml +++ b/app/views/explore/projects/starred.html.haml @@ -1,9 +1,12 @@ - page_title "Starred Projects" +- if current_user + = render 'dashboard/projects_head' .explore-trending-block - %p.lead + .lead %i.fa.fa-star See most starred projects - %hr + .pull-right + = render 'explore/projects/dropdown' .public-projects %ul.bordered-list = render @starred_projects diff --git a/app/views/explore/projects/trending.html.haml b/app/views/explore/projects/trending.html.haml index 5e24df76a63..98a4174b426 100644 --- a/app/views/explore/projects/trending.html.haml +++ b/app/views/explore/projects/trending.html.haml @@ -1,4 +1,6 @@ - page_title "Trending Projects" +- if current_user + = render 'dashboard/projects_head' .explore-title %h3 Explore GitLab @@ -6,10 +8,11 @@ Discover projects and groups. Share your projects with others %hr .explore-trending-block - %p.lead + .lead %i.fa.fa-comments-o See most discussed projects for last month - %hr + .pull-right + = render 'explore/projects/dropdown' .public-projects %ul.bordered-list = render @trending_projects |