Sha256: ca6e180dab2207aba363688f01e1d82ab8d943ec28bc6e4e2fa5252f83e6e68c

Contents?: true

Size: 744 Bytes

Versions: 6

Compression:

Stored size: 744 Bytes

Contents

<%#
# Navigation

This partial is used to display the navigation in Administrate.
By default, the navigation contains navigation links
for all resources in the admin dashboard,
as defined by the routes in the `admin/` namespace
%>

<nav class="navigation">
  <%= link_to(t("administrate.navigation.back_to_app"), root_url, class: "button button--alt button--nav") if defined?(root_url) %>

  <% Administrate::Namespace.new(namespace).resources_with_index_route.each do |resource| %>
    <%= link_to(
      display_resource_name(resource),
      resource_index_route(resource),
      class: "navigation__link navigation__link--#{nav_link_state(resource)}"
    ) if accessible_action?(model_from_resource(resource), :index) %>
  <% end %>
</nav>

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
administrate-1.0.0.beta3 app/views/administrate/application/_navigation.html.erb
administrate-1.0.0.beta2 app/views/administrate/application/_navigation.html.erb
administrate-1.0.0.beta1 app/views/administrate/application/_navigation.html.erb
administrate-0.20.1 app/views/administrate/application/_navigation.html.erb
administrate-0.20.0 app/views/administrate/application/_navigation.html.erb
administrate-0.19.0 app/views/administrate/application/_navigation.html.erb