diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-11-19 11:27:35 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-11-19 11:27:35 +0300 |
commit | 7e9c479f7de77702622631cff2628a9c8dcbc627 (patch) | |
tree | c8f718a08e110ad7e1894510980d2155a6549197 /app/views/search/_results.html.haml | |
parent | e852b0ae16db4052c1c567d9efa4facc81146e88 (diff) |
Add latest changes from gitlab-org/gitlab@13-6-stable-eev13.6.0-rc42
Diffstat (limited to 'app/views/search/_results.html.haml')
-rw-r--r-- | app/views/search/_results.html.haml | 75 |
1 files changed, 42 insertions, 33 deletions
diff --git a/app/views/search/_results.html.haml b/app/views/search/_results.html.haml index 95c378bff7c..855112bdba2 100644 --- a/app/views/search/_results.html.haml +++ b/app/views/search/_results.html.haml @@ -1,38 +1,47 @@ - if @search_objects.to_a.empty? - = render partial: "search/results/filters" - = render partial: "search/results/empty" - = render_if_exists 'shared/promotions/promote_advanced_search' + .gl-display-md-flex + - if %w(issues merge_requests).include?(@scope) + #js-search-sidebar.gl-display-flex.gl-flex-direction-column.col-md-3.gl-mr-4{ } + .gl-w-full + = render partial: "search/results/empty" + = render_if_exists 'shared/promotions/promote_advanced_search' - else - .row-content-block.d-md-flex.text-left.align-items-center - - unless @search_objects.is_a?(Kaminari::PaginatableWithoutCount) - = search_entries_info(@search_objects, @scope, @search_term) - - unless @show_snippets - - if @project - - link_to_project = link_to(@project.full_name, @project, class: 'ml-md-1') - - if @scope == 'blobs' - = s_("SearchCodeResults|in") - .mx-md-1 - = render partial: "shared/ref_switcher", locals: { ref: repository_ref(@project), form_path: request.fullpath, field_name: 'repository_ref' } - = s_('SearchCodeResults|of %{link_to_project}').html_safe % { link_to_project: link_to_project } - - else - = _("in project %{link_to_project}").html_safe % { link_to_project: link_to_project } - - elsif @group - - link_to_group = link_to(@group.name, @group, class: 'ml-md-1') - = _("in group %{link_to_group}").html_safe % { link_to_group: link_to_group } + .search-results-status + .row-content-block.gl-display-flex + .gl-display-md-flex.gl-text-left.gl-align-items-center.gl-flex-grow-1 + - unless @search_objects.is_a?(Kaminari::PaginatableWithoutCount) + = search_entries_info(@search_objects, @scope, @search_term) + - unless @show_snippets + - if @project + - link_to_project = link_to(@project.full_name, @project, class: 'ml-md-1') + - if @scope == 'blobs' + = s_("SearchCodeResults|in") + .mx-md-1 + = render partial: "shared/ref_switcher", locals: { ref: repository_ref(@project), form_path: request.fullpath, field_name: 'repository_ref' } + = s_('SearchCodeResults|of %{link_to_project}').html_safe % { link_to_project: link_to_project } + - else + = _("in project %{link_to_project}").html_safe % { link_to_project: link_to_project } + - elsif @group + - link_to_group = link_to(@group.name, @group, class: 'ml-md-1') + = _("in group %{link_to_group}").html_safe % { link_to_group: link_to_group } + .gl-display-md-flex.gl-flex-direction-column + = render partial: 'search/sort_dropdown' = render_if_exists 'shared/promotions/promote_advanced_search' - = render partial: "search/results/filters" - .results.gl-mt-3 - - if @scope == 'commits' - %ul.content-list.commit-list - = render partial: "search/results/commit", collection: @search_objects - - else - .search-results - - if @scope == 'projects' - .term - = render 'shared/projects/list', projects: @search_objects, pipeline_status: false - - else - = render_if_exists partial: "search/results/#{@scope.singularize}", collection: @search_objects + .results.gl-display-md-flex.gl-mt-3 + - if %w(issues merge_requests).include?(@scope) + #js-search-sidebar.gl-display-flex.gl-flex-direction-column.col-md-3.gl-mr-4{ } + .gl-w-full + - if @scope == 'commits' + %ul.content-list.commit-list + = render partial: "search/results/commit", collection: @search_objects + - else + .search-results + - if @scope == 'projects' + .term + = render 'shared/projects/list', projects: @search_objects, pipeline_status: false + - else + = render_if_exists partial: "search/results/#{@scope.singularize}", collection: @search_objects - - if @scope != 'projects' - = paginate_collection(@search_objects) + - if @scope != 'projects' + = paginate_collection(@search_objects) |