Sha256: 9db070fbc2cb2f3bd75c2153b11ba4bba1fd6f9014e9c9a007428350ccc9d14a

Contents?: true

Size: 864 Bytes

Versions: 2

Compression:

Stored size: 864 Bytes

Contents

<li class="group <%= "active" if active? %>">
  <a
    href="<%= path %>"
    aria-current="<%= @item.current?(@url_helpers, @fullpath) ? "page" : "false" %>"
    class="
      flex gap-3 items-center
      py-0.5 px-3 mb-0.5 rounded
      hover:text-red-500 hover:bg-gray-50
      <%= "text-red-500 bg-gray-50" if active? %>
      <%= @item.top_level ? "body-small-bold text-black" : "body-small text-gray-600" %>
    "
  >
    <i class="w-[1.125rem] h-[1.125rem] body-small flex">
      <% if @item.icon %>
        <%= icon_tag(@item.icon, class: "inline-block w-full h-full fill-current") %>
      <% end %>
    </i>
    <%= @item.name %>
  </a>

  <% if @item.children? %>
    <ul class="<%= "hidden" unless active? %>">
      <%= render self.class.with_collection(@item.children, url_helpers: @url_helpers, fullpath: @fullpath) %>
    </ul>
  <% end %>
</li>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
solidus_admin-0.0.2 app/components/solidus_admin/sidebar/item/component.html.erb
solidus_admin-0.0.1 app/components/solidus_admin/sidebar/item/component.html.erb