diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-04-13 15:15:20 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-04-13 15:15:20 +0300 |
commit | 944a3a7b7e19354abdfcaa79129d0736c4b8565f (patch) | |
tree | 627802e84525946f11fdd6976ab5f04fb69e702c /app/views/search | |
parent | 62798ed33c878f936009da05fdddb707e1c7d58d (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views/search')
-rw-r--r-- | app/views/search/_results.html.haml | 10 | ||||
-rw-r--r-- | app/views/search/show.html.haml | 8 |
2 files changed, 9 insertions, 9 deletions
diff --git a/app/views/search/_results.html.haml b/app/views/search/_results.html.haml index 3280dcf2cd4..99558f61b25 100644 --- a/app/views/search/_results.html.haml +++ b/app/views/search/_results.html.haml @@ -1,9 +1,5 @@ -- search_bar_classes = 'search-sidebar gl-display-flex gl-flex-direction-column gl-mr-4' - = render_if_exists 'shared/promotions/promote_advanced_search' -.results.gl-md-display-flex.gl-mt-0 - #js-search-sidebar{ class: search_bar_classes, data: { navigation_json: search_navigation_json } } - .gl-w-full.gl-flex-grow-1.gl-overflow-x-hidden - = render partial: 'search/results_status' if @search_objects.present? - = render partial: 'search/results_list' +.gl-w-full.gl-flex-grow-1.gl-overflow-x-hidden + = render partial: 'search/results_status' unless @search_objects.to_a.empty? + = render partial: 'search/results_list' diff --git a/app/views/search/show.html.haml b/app/views/search/show.html.haml index 826d78c470d..934f59ea586 100644 --- a/app/views/search/show.html.haml +++ b/app/views/search/show.html.haml @@ -1,12 +1,14 @@ - @hide_top_links = true - breadcrumb_title _('Search') - page_title @search_term +- nav 'search' - if params[:group_id].present? = hidden_field_tag :group_id, params[:group_id] - if params[:project_id].present? = hidden_field_tag :project_id, params[:project_id] - group_attributes = @group&.attributes&.slice('id', 'name')&.merge(full_name: @group&.full_name) - project_attributes = @project&.attributes&.slice('id', 'namespace_id', 'name')&.merge(name_with_namespace: @project&.name_with_namespace) +- search_bar_classes = 'search-sidebar gl-display-flex gl-flex-direction-column gl-mr-4' - if @search_results && !(@search_results.respond_to?(:failed?) && @search_results.failed?) - if @search_service_presenter.without_count? @@ -20,5 +22,7 @@ = render_if_exists 'search/form_elasticsearch', attrs: { class: 'mb-2 mb-sm-0 align-self-center' } #js-search-topbar{ data: { "group-initial-json": group_attributes.to_json, "project-initial-json": project_attributes.to_json, "elasticsearch-enabled": @search_service_presenter.advanced_search_enabled?.to_s, "default-branch-name": @project&.default_branch } } -- if @search_term - = render 'search/results' +.results.gl-md-display-flex.gl-mt-0 + #js-search-sidebar{ class: search_bar_classes, data: { navigation_json: search_navigation_json } } + - if @search_term + = render 'search/results' |