gitlab-org--gitlab-foss/app/views/layouts/_head_panel.html.haml

38 lines
1 KiB
Text
Raw Normal View History

2012-01-12 02:04:57 -05:00
/ Page Header
2012-01-12 02:28:57 -05:00
%header.top_panel_holder
2012-01-15 12:42:20 -05:00
.wrapper
2012-01-16 14:07:57 -05:00
.top_panel_content
2012-02-09 17:07:49 -05:00
%div.app_logo
2012-01-16 14:07:57 -05:00
= link_to root_path, :class => "home", :title => "Home" do
2012-02-09 17:07:49 -05:00
= image_tag "logo_tr.png", :width => 50
%h1 GITLAB
2012-01-12 02:28:57 -05:00
%h1.project_name= title
2012-02-09 17:07:49 -05:00
.search= text_field_tag "search", nil, :placeholder => "Search", :class => "search-input"
2012-01-13 16:13:44 -05:00
2012-01-12 02:04:57 -05:00
2012-01-16 14:07:57 -05:00
.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();
}
});
});