From fc60c391ae93e0a9ef9a5123ee7d71cd504e4366 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Thu, 9 Jan 2014 12:51:20 +0200 Subject: [PATCH] Improve search page UX --- app/views/search/_project_results.html.haml | 4 ++-- app/views/search/_results.html.haml | 12 ++++++++---- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/app/views/search/_project_results.html.haml b/app/views/search/_project_results.html.haml index 70819ad..ea324b3 100644 --- a/app/views/search/_project_results.html.haml +++ b/app/views/search/_project_results.html.haml @@ -1,10 +1,10 @@ -%ul.nav.nav-pills.append-bottom-20 +%ul.nav.nav-tabs.append-bottom-10 %li{class: ("active" if params[:search_code].present?)} = link_to search_path(params.merge(search_code: true)) do Repository Code %li{class: ("active" if params[:search_code].blank?)} = link_to search_path(params.merge(search_code: nil)) do - Everything else + Issues and Merge requests .search_results - if params[:search_code].present? diff --git a/app/views/search/_results.html.haml b/app/views/search/_results.html.haml index 2f92ecc..2336d0f 100644 --- a/app/views/search/_results.html.haml +++ b/app/views/search/_results.html.haml @@ -1,7 +1,11 @@ -%fieldset - %legend - Search results - %span.cgray (#{@search_results[:total_results]}) +%h4 + #{@search_results[:total_results]} results found + - if @project + for #{link_to @project.name_with_namespace, @project} + - elsif @group + for #{link_to @group.name, @group} + +%hr - if @project = render "project_results" -- libgit2 0.21.2