debian-mirror-gitlab/app/views/search/_results.html.haml

27 lines
1.1 KiB
Text
Raw Normal View History

2021-02-22 17:27:13 +05:30
- search_bar_classes = 'search-sidebar gl-display-flex gl-flex-direction-column gl-mr-4'
2021-09-30 23:02:18 +05:30
= render_if_exists 'shared/promotions/promote_advanced_search'
= render partial: 'search/results_status', locals: { search_service: @search_service } unless @search_objects.to_a.empty?
2021-02-22 17:27:13 +05:30
2021-09-30 23:02:18 +05:30
.results.gl-md-display-flex.gl-mt-3
2022-08-27 11:52:29 +05:30
- if %w[issues merge_requests].include?(@scope)
2021-09-30 23:02:18 +05:30
#js-search-sidebar{ class: search_bar_classes }
.gl-w-full.gl-flex-grow-1.gl-overflow-x-hidden
- if @timeout
= render partial: "search/results/timeout"
- elsif @search_objects.to_a.empty?
2021-01-29 00:20:46 +05:30
= render partial: "search/results/empty"
2021-09-30 23:02:18 +05:30
- else
2021-01-29 00:20:46 +05:30
- 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
2014-09-02 18:07:02 +05:30
2021-01-29 00:20:46 +05:30
- if @scope != 'projects'
= paginate_collection(@search_objects)