Commit 08874255 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge branch 'master' into use-top-area

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parents ccd99efe c8224f0b
...@@ -27,6 +27,7 @@ v 8.5.0 (unreleased) ...@@ -27,6 +27,7 @@ v 8.5.0 (unreleased)
- Mark inline difference between old and new paths when a file is renamed - Mark inline difference between old and new paths when a file is renamed
- Support Akismet spam checking for creation of issues via API (Stan Hu) - Support Akismet spam checking for creation of issues via API (Stan Hu)
- Improve UI consistency between projects and groups lists - Improve UI consistency between projects and groups lists
- Add sort dropdown to dashboard projects page
v 8.4.3 v 8.4.3
- Increase lfs_objects size column to 8-byte integer to allow files larger - Increase lfs_objects size column to 8-byte integer to allow files larger
......
...@@ -30,7 +30,7 @@ gem 'omniauth-github', '~> 1.1.1' ...@@ -30,7 +30,7 @@ gem 'omniauth-github', '~> 1.1.1'
gem 'omniauth-gitlab', '~> 1.0.0' gem 'omniauth-gitlab', '~> 1.0.0'
gem 'omniauth-google-oauth2', '~> 0.2.0' gem 'omniauth-google-oauth2', '~> 0.2.0'
gem 'omniauth-kerberos', '~> 0.3.0', group: :kerberos gem 'omniauth-kerberos', '~> 0.3.0', group: :kerberos
gem 'omniauth-saml', '~> 1.4.0' gem 'omniauth-saml', '~> 1.4.2'
gem 'omniauth-shibboleth', '~> 1.2.0' gem 'omniauth-shibboleth', '~> 1.2.0'
gem 'omniauth-twitter', '~> 1.2.0' gem 'omniauth-twitter', '~> 1.2.0'
gem 'omniauth_crowd', '~> 2.2.0' gem 'omniauth_crowd', '~> 2.2.0'
......
...@@ -532,9 +532,9 @@ GEM ...@@ -532,9 +532,9 @@ GEM
omniauth-oauth2 (1.3.1) omniauth-oauth2 (1.3.1)
oauth2 (~> 1.0) oauth2 (~> 1.0)
omniauth (~> 1.2) omniauth (~> 1.2)
omniauth-saml (1.4.1) omniauth-saml (1.4.2)
omniauth (~> 1.1) omniauth (~> 1.1)
ruby-saml (~> 1.0.0) ruby-saml (~> 1.1, >= 1.1.1)
omniauth-shibboleth (1.2.1) omniauth-shibboleth (1.2.1)
omniauth (>= 1.0.0) omniauth (>= 1.0.0)
omniauth-twitter (1.2.1) omniauth-twitter (1.2.1)
...@@ -690,7 +690,7 @@ GEM ...@@ -690,7 +690,7 @@ GEM
ruby-fogbugz (0.2.1) ruby-fogbugz (0.2.1)
crack (~> 0.4) crack (~> 0.4)
ruby-progressbar (1.7.5) ruby-progressbar (1.7.5)
ruby-saml (1.0.0) ruby-saml (1.1.1)
nokogiri (>= 1.5.10) nokogiri (>= 1.5.10)
uuid (~> 2.3) uuid (~> 2.3)
ruby2ruby (2.2.0) ruby2ruby (2.2.0)
...@@ -974,7 +974,7 @@ DEPENDENCIES ...@@ -974,7 +974,7 @@ DEPENDENCIES
omniauth-gitlab (~> 1.0.0) omniauth-gitlab (~> 1.0.0)
omniauth-google-oauth2 (~> 0.2.0) omniauth-google-oauth2 (~> 0.2.0)
omniauth-kerberos (~> 0.3.0) omniauth-kerberos (~> 0.3.0)
omniauth-saml (~> 1.4.0) omniauth-saml (~> 1.4.2)
omniauth-shibboleth (~> 1.2.0) omniauth-shibboleth (~> 1.2.0)
omniauth-twitter (~> 1.2.0) omniauth-twitter (~> 1.2.0)
omniauth_crowd (~> 2.2.0) omniauth_crowd (~> 2.2.0)
......
...@@ -65,8 +65,7 @@ class @DropzoneInput ...@@ -65,8 +65,7 @@ class @DropzoneInput
return return
success: (header, response) -> success: (header, response) ->
child = $(dropzone[0]).children("textarea") pasteText response.link.markdown
$(child).val $(child).val() + response.link.markdown + "\n"
return return
error: (temp, errorMessage) -> error: (temp, errorMessage) ->
...@@ -128,6 +127,7 @@ class @DropzoneInput ...@@ -128,6 +127,7 @@ class @DropzoneInput
beforeSelection = $(child).val().substring 0, caretStart beforeSelection = $(child).val().substring 0, caretStart
afterSelection = $(child).val().substring caretEnd, textEnd afterSelection = $(child).val().substring caretEnd, textEnd
$(child).val beforeSelection + text + afterSelection $(child).val beforeSelection + text + afterSelection
child.get(0).setSelectionRange caretStart + text.length, caretEnd + text.length
form_textarea.trigger "input" form_textarea.trigger "input"
getFilename = (e) -> getFilename = (e) ->
......
...@@ -6,11 +6,3 @@ ...@@ -6,11 +6,3 @@
font-size: 30px; font-size: 30px;
} }
} }
.explore-trending-block {
.lead {
line-height: 32px;
font-size: 18px;
margin-top: 10px;
}
}
...@@ -415,6 +415,10 @@ pre.light-well { ...@@ -415,6 +415,10 @@ pre.light-well {
a:hover { a:hover {
text-decoration: none; text-decoration: none;
} }
> span {
margin-left: 10px;
}
} }
.project-description { .project-description {
......
...@@ -3,6 +3,7 @@ class Dashboard::ProjectsController < Dashboard::ApplicationController ...@@ -3,6 +3,7 @@ class Dashboard::ProjectsController < Dashboard::ApplicationController
def index def index
@projects = current_user.authorized_projects.sorted_by_activity.non_archived @projects = current_user.authorized_projects.sorted_by_activity.non_archived
@projects = @projects.sort(@sort = params[:sort])
@projects = @projects.includes(:namespace) @projects = @projects.includes(:namespace)
@last_push = current_user.recent_push @last_push = current_user.recent_push
......
...@@ -10,8 +10,19 @@ module ExploreHelper ...@@ -10,8 +10,19 @@ module ExploreHelper
options = exist_opts.merge(options) options = exist_opts.merge(options)
path = explore_projects_path path = if explore_controller?
explore_projects_path
elsif current_action?(:starred)
starred_dashboard_projects_path
else
dashboard_projects_path
end
path << "?#{options.to_param}" path << "?#{options.to_param}"
path path
end end
def explore_controller?
controller.class.name.split("::").first == "Explore"
end
end end
...@@ -13,7 +13,8 @@ ...@@ -13,7 +13,8 @@
Explore Projects Explore Projects
.nav-controls .nav-controls
= search_field_tag :filter_projects, nil, placeholder: 'Filter by name...', class: 'projects-list-filter form-control hidden-xs', spellcheck: false = search_field_tag :filter_projects, nil, placeholder: 'Filter by name...', class: 'projects-list-filter form-control hidden-xs input-short', spellcheck: false
= render 'explore/projects/dropdown'
- if current_user.can_create_project? - if current_user.can_create_project?
= link_to new_project_path, class: 'btn btn-new' do = link_to new_project_path, class: 'btn btn-new' do
= icon('plus') = icon('plus')
......
...@@ -16,8 +16,5 @@ ...@@ -16,8 +16,5 @@
= render 'shared/issuable/filter', type: :issues = render 'shared/issuable/filter', type: :issues
.gray-content-block.second-block
List all issues from all projects you have access to.
.prepend-top-default .prepend-top-default
= render 'shared/issues' = render 'shared/issues'
...@@ -7,8 +7,5 @@ ...@@ -7,8 +7,5 @@
= render 'shared/issuable/filter', type: :merge_requests = render 'shared/issuable/filter', type: :merge_requests
.gray-content-block.second-block
List all merge requests from all projects you have access to.
.prepend-top-default .prepend-top-default
= render 'shared/merge_requests' = render 'shared/merge_requests'
...@@ -7,9 +7,6 @@ ...@@ -7,9 +7,6 @@
.nav-controls .nav-controls
= render 'shared/new_project_item_select', path: 'milestones/new', label: "New Milestone", include_groups: true = render 'shared/new_project_item_select', path: 'milestones/new', label: "New Milestone", include_groups: true
.gray-content-block
List all milestones from all projects you have access to.
.milestones .milestones
%ul.content-list %ul.content-list
- if @milestones.blank? - if @milestones.blank?
......
...@@ -3,19 +3,13 @@ ...@@ -3,19 +3,13 @@
%span.light %span.light
- if @sort.present? - if @sort.present?
= sort_options_hash[@sort] = 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 - else
= sort_title_recently_created = sort_title_recently_updated
%b.caret %b.caret
%ul.dropdown-menu %ul.dropdown-menu
%li %li
= link_to trending_explore_projects_path do = link_to explore_projects_filter_path(sort: sort_value_name) do
Trending projects = sort_title_name
= link_to starred_explore_projects_path do
Most stars
= link_to explore_projects_filter_path(sort: sort_value_recently_created) do = link_to explore_projects_filter_path(sort: sort_value_recently_created) do
= sort_title_recently_created = sort_title_recently_created
= link_to explore_projects_filter_path(sort: sort_value_oldest_created) do = link_to explore_projects_filter_path(sort: sort_value_oldest_created) do
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
= form_tag explore_projects_filter_path, method: :get, class: 'form-inline form-tiny' do |f| = form_tag explore_projects_filter_path, method: :get, class: 'form-inline form-tiny' do |f|
.form-group .form-group
= search_field_tag :search, params[:search], placeholder: "Filter by name", class: "form-control search-text-input", id: "projects_search", spellcheck: false = search_field_tag :search, params[:search], placeholder: "Filter by name", class: "form-control search-text-input", id: "projects_search", spellcheck: false
= hidden_field_tag :sort, @sort
.form-group .form-group
= button_tag 'Search', class: "btn" = button_tag 'Search', class: "btn"
...@@ -46,4 +47,3 @@ ...@@ -46,4 +47,3 @@
= link_to explore_projects_filter_path(tag: tag.name) do = link_to explore_projects_filter_path(tag: tag.name) do
%i.fa.fa-tag %i.fa.fa-tag
= tag.name = tag.name
= render 'explore/projects/dropdown'
%ul.nav-links
= nav_link(page: [trending_explore_projects_path, explore_root_path]) do
= link_to trending_explore_projects_path do
Trending
= nav_link(page: starred_explore_projects_path) do
= link_to starred_explore_projects_path do
Most stars
= nav_link(page: explore_projects_path) do
= link_to explore_projects_path do
All
...@@ -6,7 +6,11 @@ ...@@ -6,7 +6,11 @@
- else - else
= render 'explore/head' = render 'explore/head'
.gray-content-block.clearfix.second-block .top-area
= render 'explore/projects/nav'
.gray-content-block.second-block.clearfix
= render 'filter' = render 'filter'
= render 'projects', projects: @projects = render 'projects', projects: @projects
= paginate @projects, theme: "gitlab" = paginate @projects, theme: "gitlab"
...@@ -6,12 +6,6 @@ ...@@ -6,12 +6,6 @@
- else - else
= render 'explore/head' = render 'explore/head'
.explore-trending-block = render 'explore/projects/nav'
.gray-content-block.second-block = render 'projects', projects: @starred_projects
.pull-right = paginate @starred_projects, theme: 'gitlab'
= render 'explore/projects/dropdown'
.oneline
%i.fa.fa-star
See most starred projects
= render 'projects', projects: @starred_projects
= paginate @starred_projects, theme: 'gitlab'
...@@ -6,11 +6,5 @@ ...@@ -6,11 +6,5 @@
- else - else
= render 'explore/head' = render 'explore/head'
.explore-trending-block = render 'explore/projects/nav'
.gray-content-block.second-block = render 'projects', projects: @trending_projects
.pull-right
= render 'explore/projects/dropdown'
.oneline
%i.fa.fa-comments-o
See most discussed projects for last month
= render 'projects', projects: @trending_projects
...@@ -11,9 +11,6 @@ ...@@ -11,9 +11,6 @@
= icon('plus') = icon('plus')
New Milestone New Milestone
.gray-content-block
Milestone allows you to group issues and set due date for it
.milestones .milestones
%ul.content-list %ul.content-list
= render @milestones = render @milestones
......
...@@ -29,8 +29,8 @@ ...@@ -29,8 +29,8 @@
.project-controls .project-controls
- if ci_commit - if ci_commit
%span
= render_ci_status(ci_commit) = render_ci_status(ci_commit)
&nbsp;
- if forks - if forks
%span %span
= icon('code-fork') = icon('code-fork')
......
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