gitlabhq/app/views/layouts/_head_panel.html.haml
Dmitriy Zaporozhets c1fe37690a logo updated
2012-02-10 00:07:49 +02:00

38 lines
1 KiB
Plaintext

/ Page Header
%header.top_panel_holder
.wrapper
.top_panel_content
%div.app_logo
= link_to root_path, :class => "home", :title => "Home" do
= image_tag "logo_tr.png", :width => 50
%h1 GITLAB
%h1.project_name= title
.search= text_field_tag "search", nil, :placeholder => "Search", :class => "search-input"
.account-box
= link_to profile_path, :class => "pic" do
= image_tag gravatar_icon(current_user.email)
.account-links
= 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();
}
});
});