2016-06-15 12:23:49 -04:00
|
|
|
%header.navbar.navbar-fixed-top.navbar-gitlab{ class: nav_header_class }
|
2016-12-22 06:00:09 -05:00
|
|
|
%a.sr-only.gl-accessibility{ href: "#content-body", tabindex: "1" } Skip to content
|
2016-12-23 04:37:12 -05:00
|
|
|
.container-fluid
|
2015-06-01 09:45:36 -04:00
|
|
|
.header-content
|
2016-07-12 09:30:37 -04:00
|
|
|
%button.side-nav-toggle{ type: 'button', "aria-label" => "Toggle global navigation" }
|
2015-06-01 09:45:36 -04:00
|
|
|
%span.sr-only Toggle navigation
|
|
|
|
= icon('bars')
|
2016-05-09 19:53:25 -04:00
|
|
|
%button.navbar-toggle{type: 'button'}
|
|
|
|
%span.sr-only Toggle navigation
|
2016-06-27 10:06:36 -04:00
|
|
|
= icon('ellipsis-v')
|
2014-01-06 07:34:41 -05:00
|
|
|
|
2015-06-01 09:45:36 -04:00
|
|
|
.navbar-collapse.collapse
|
2016-03-22 09:56:07 -04:00
|
|
|
%ul.nav.navbar-nav
|
2016-03-08 19:01:33 -05:00
|
|
|
%li.hidden-sm.hidden-xs
|
2016-04-11 19:04:42 -04:00
|
|
|
= render 'layouts/search' unless current_controller?(:search)
|
2015-06-01 09:45:36 -04:00
|
|
|
%li.visible-sm.visible-xs
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to search_path, title: 'Search', aria: { label: "Search" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
|
2015-06-01 09:45:36 -04:00
|
|
|
= icon('search')
|
2016-03-01 13:31:52 -05:00
|
|
|
- if current_user
|
|
|
|
- if session[:impersonator_id]
|
|
|
|
%li.impersonation
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to admin_impersonation_path, method: :delete, title: "Stop Impersonation", aria: { label: 'Stop Impersonation' }, data: { toggle: 'tooltip', placement: 'bottom', container: 'body' } do
|
2016-03-01 13:31:52 -05:00
|
|
|
= icon('user-secret fw')
|
|
|
|
- if current_user.is_admin?
|
|
|
|
%li
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to admin_root_path, title: 'Admin Area', aria: { label: "Admin Area" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
|
2016-03-01 13:31:52 -05:00
|
|
|
= icon('wrench fw')
|
2015-06-01 09:45:36 -04:00
|
|
|
%li
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to dashboard_todos_path, title: 'Todos', aria: { label: "Todos" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
|
2016-05-06 11:47:43 -04:00
|
|
|
= icon('bell fw')
|
2016-06-09 11:12:59 -04:00
|
|
|
%span.badge.todos-pending-count{ class: ("hidden" if todos_pending_count == 0) }
|
2016-06-07 04:44:01 -04:00
|
|
|
= todos_pending_count
|
2016-03-01 13:31:52 -05:00
|
|
|
- if Gitlab::Sherlock.enabled?
|
|
|
|
%li
|
|
|
|
= link_to sherlock_transactions_path, title: 'Sherlock Transactions',
|
|
|
|
data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
|
|
|
|
= icon('tachometer fw')
|
2016-06-27 07:46:27 -04:00
|
|
|
%li.header-user.dropdown
|
|
|
|
= link_to current_user, class: "header-user-dropdown-toggle", data: { toggle: "dropdown" } do
|
|
|
|
= image_tag avatar_icon(current_user, 26), width: 26, height: 26, class: "header-user-avatar"
|
2016-08-23 12:02:52 -04:00
|
|
|
= icon('caret-down')
|
2016-06-27 07:46:27 -04:00
|
|
|
.dropdown-menu-nav.dropdown-menu-align-right
|
|
|
|
%ul
|
|
|
|
%li
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to "Profile", current_user, class: 'profile-link', aria: { label: "Profile" }, data: { user: current_user.username }
|
2016-07-05 08:40:29 -04:00
|
|
|
%li
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to "Profile Settings", profile_path, aria: { label: "Profile Settings" }
|
2016-10-27 16:45:38 -04:00
|
|
|
%li
|
|
|
|
= link_to "Help", help_path, aria: { label: "Help" }
|
2016-06-27 07:46:27 -04:00
|
|
|
%li.divider
|
|
|
|
%li
|
2016-07-12 09:30:37 -04:00
|
|
|
= link_to "Sign out", destroy_user_session_path, method: :delete, class: "sign-out-link", aria: { label: "Sign out" }
|
2016-03-01 13:31:52 -05:00
|
|
|
- else
|
2016-03-22 09:56:07 -04:00
|
|
|
%li
|
|
|
|
%div
|
|
|
|
= link_to "Sign in", new_session_path(:user, redirect_to_referer: 'yes'), class: 'btn btn-sign-in btn-success'
|
2016-03-01 13:31:52 -05:00
|
|
|
|
2014-12-15 05:11:38 -05:00
|
|
|
|
2015-06-15 21:12:45 -04:00
|
|
|
%h1.title= title
|
|
|
|
|
2016-06-09 13:37:47 -04:00
|
|
|
.header-logo
|
2016-06-14 17:57:46 -04:00
|
|
|
= link_to root_path, class: 'home', title: 'Dashboard', id: 'logo' do
|
2016-06-09 13:37:47 -04:00
|
|
|
= brand_header_logo
|
|
|
|
|
2016-03-22 07:33:38 -04:00
|
|
|
= yield :header_content
|
|
|
|
|
2014-12-15 05:11:38 -05:00
|
|
|
= render 'shared/outdated_browser'
|
2016-03-17 13:38:35 -04:00
|
|
|
|
2016-01-20 10:50:26 -05:00
|
|
|
- if @project && !@project.empty_repo?
|
2016-03-17 13:38:35 -04:00
|
|
|
- if ref = @ref || @project.repository.root_ref
|
|
|
|
:javascript
|
|
|
|
var findFileURL = "#{namespace_project_find_file_path(@project.namespace, @project, ref)}";
|