Sha256: 1b2895d8a43a3773ea1bb083b760cc232b8a08267ada15df594affa75d414c78

Contents?: true

Size: 735 Bytes

Versions: 5

Compression:

Stored size: 735 Bytes

Contents

<div class="userbox pull-right dropdown">
  <%= link_to "#", class: 'dropdown-toggle', data: { toggle: 'dropdown' } do %>
    <span class="name">
      <%= format_user_name(current_user) %>
      <span class="caret"></span>
    </span>

    <%= avatar_for(current_user) %>
  <% end %>

  <ul class="dropdown-menu dropdown-menu-right">
    <% if Trestle.config.auth.user_admin && user_admin = Trestle.lookup(Trestle.config.auth.user_admin) -%>
      <li><%= link_to t("admin.auth.my_account", default: "My Account"), user_admin.path(:show, id: current_user), class: "dropdown-item" %></li>
    <% end -%>
    <li><%= link_to t("admin.auth.logout", default: "Log out"), trestle.logout_path, class: "dropdown-item" %></li>
  </ul>
</div>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
trestle-auth-0.2.4 app/views/trestle/auth/_userbox.html.erb
trestle-auth-0.2.3 app/views/trestle/auth/_userbox.html.erb
trestle-auth-0.2.2 app/views/trestle/auth/_userbox.html.erb
trestle-auth-0.2.1 app/views/trestle/auth/_userbox.html.erb
trestle-auth-0.2.0 app/views/trestle/auth/_userbox.html.erb