diff options
author | Dmitriy Zaporozhets <dzaporozhets@sphereconsultinginc.com> | 2012-02-09 09:59:14 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dzaporozhets@sphereconsultinginc.com> | 2012-02-09 09:59:14 +0200 |
commit | cd567ee40b660a5ff571d882ad1492f68dc07e23 (patch) | |
tree | 24dd05e503cb947aeca92f466cf69f4a9250fda1 /app/views/layouts | |
parent | fbd5296e32badf6040fec62b43d27de61c1a65c5 (diff) | |
download | gitlab-ce-cd567ee40b660a5ff571d882ad1492f68dc07e23.tar.gz |
Titled dashboard, admin, profile areas. Wider top panel. Restored search input
Diffstat (limited to 'app/views/layouts')
-rw-r--r-- | app/views/layouts/_head_panel.html.haml | 22 | ||||
-rw-r--r-- | app/views/layouts/admin.html.haml | 4 | ||||
-rw-r--r-- | app/views/layouts/application.html.haml | 4 | ||||
-rw-r--r-- | app/views/layouts/profile.html.haml | 4 | ||||
-rw-r--r-- | app/views/layouts/project.html.haml | 4 |
5 files changed, 27 insertions, 11 deletions
diff --git a/app/views/layouts/_head_panel.html.haml b/app/views/layouts/_head_panel.html.haml index 190c443a2e7..3def23b141b 100644 --- a/app/views/layouts/_head_panel.html.haml +++ b/app/views/layouts/_head_panel.html.haml @@ -6,9 +6,8 @@ = link_to root_path, :class => "home", :title => "Home" do = image_tag "logo.png", :width => 100 - - if project_layout - .project_name - = truncate @project.name, :length => 35 + %h1.project_name= title + .search= text_field_tag "search", nil, :placeholder => "Search", :class => "search-input xlarge" .account-box @@ -18,3 +17,20 @@ = link_to profile_path, :class => "username" do My profile = link_to 'Logout', destroy_user_session_path, :class => "logout", :method => :delete + +:javascript + $(function(){ + $("#search").autocomplete({ + source: #{raw search_autocomplete_source}, + select: function(event, ui) { location.href = ui.item.url } + }); + + $(document).keypress(function(e) { + if( $(e.target).is(":input") ) return; + switch(e.which) { + case 115: focusSearch(); + e.preventDefault(); + } + }); + }); + diff --git a/app/views/layouts/admin.html.haml b/app/views/layouts/admin.html.haml index 33de3efead6..df4e917cf38 100644 --- a/app/views/layouts/admin.html.haml +++ b/app/views/layouts/admin.html.haml @@ -2,8 +2,8 @@ %html{ :lang => "en"} = render "layouts/head" %body.admin - = render :partial => "layouts/flash" - = render :partial => "layouts/head_panel" + = render "layouts/flash" + = render "layouts/head_panel", :title => "Admin area" .container-fluid .sidebar .fixed diff --git a/app/views/layouts/application.html.haml b/app/views/layouts/application.html.haml index ac85080902c..ca4e71b8935 100644 --- a/app/views/layouts/application.html.haml +++ b/app/views/layouts/application.html.haml @@ -2,8 +2,8 @@ %html{ :lang => "en"} = render "layouts/head" %body.application - = render :partial => "layouts/flash" - = render :partial => "layouts/head_panel" + = render "layouts/flash" + = render "layouts/head_panel", :title => "Dashboard" .container-fluid .sidebar = render :partial => "layouts/app_side" diff --git a/app/views/layouts/profile.html.haml b/app/views/layouts/profile.html.haml index 046d0398918..445a873b743 100644 --- a/app/views/layouts/profile.html.haml +++ b/app/views/layouts/profile.html.haml @@ -2,8 +2,8 @@ %html{ :lang => "en"} = render "layouts/head" %body.profile - = render :partial => "layouts/flash" - = render :partial => "layouts/head_panel" + = render "layouts/flash" + = render "layouts/head_panel", :title => "Profile" .container-fluid .sidebar %aside diff --git a/app/views/layouts/project.html.haml b/app/views/layouts/project.html.haml index b2c6c5d0755..cd5ca714235 100644 --- a/app/views/layouts/project.html.haml +++ b/app/views/layouts/project.html.haml @@ -2,8 +2,8 @@ %html{ :lang => "en"} = render "layouts/head" %body.project - = render :partial => "layouts/flash" - = render :partial => "layouts/head_panel" + = render "layouts/flash" + = render "layouts/head_panel", :title => @project.name .container-fluid .sidebar= render :partial => "layouts/project_side" .content |