secret
Created

nav bar

  • Download Gist
_top-nav.html.erb
HTML+ERB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
<div class="fixed">
<nav class="top-bar" data-topbar>
<ul class="title-area">
<li class="name">
<h1><%= link_to "CBC Admin", root_path %></h1>
</li>
<!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
<li class="toggle-topbar menu-icon"><a href="#"><span>Menu</span></a></li>
</ul>
 
 
<section class="top-bar-section">
 
<!-- Right Nav Section -->
<ul class="right">
<li class="divider"></li>
<li class="has-dropdown">
<a href="#">Welcome, <%= current_coach.first_name %>!</a>
<ul class="dropdown">
<li><%= dropdown_link('fa fa-user fa-fw', 'Profile', profile_path(current_coach)) %></li>
<li><%= dropdown_link('fa fa-cogs fa-fw', 'Settings', '#') %></li>
<li><%= dropdown_link('fa fa-users fa-fw', 'All Coaches', coaches_path) %></li>
<li><%= dropdown_link('fa fa-heart fa-fw', 'Help', help_path) %></li>
<% if current_coach.admin? %>
<li class="divider"></li>
<li><%= dropdown_link('fa fa-shield fa-fw', 'Admin Panel', '#') %></li>
<% end %>
<li class="divider"></li>
<li><%= dropdown_link('fa fa-sign-out fa-fw', 'Sign out', signout_path) %></li>
</ul>
</li>
</ul>
 
<!-- Left Nav Section -->
<ul class="left">
<li class="has-form">
<%= form_tag search_students_path, method: 'get' do %>
<div id="nav-search" class="row collapse">
<div id="nav-search-field" class="small-21 columns">
<%= text_field_tag :search, nil, autocomplete: 'off' %>
</div>
<div id="nav-search-icon" class="small-3 columns">
<%= submit_tag '&#xf002;'.html_safe, class: 'button fa fa-search spin', name: 'submit' %>
</div>
</div>
<% end %>
</li>
<li id="spinner"></li>
</ul>
</section>
</nav>
</div>

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.