Sha256: 570131c25de5a670d68cd9c5f90ef082e5161d57274b171800c88f65a190b3d1

Contents?: true

Size: 1.03 KB

Versions: 20

Compression:

Stored size: 1.03 KB

Contents

<%= render_component_tag :li,
  id: id,
  key: "#{id}-entity-#{type}",
  class: "list-none",
  "x-show": "!filteredOut",
  data: { "entity-type": type.to_s.tr("_","-") },
  cloak: true do %>
  <%= lookbook_tag href.present? ? :a : :button,
    href: href,
    key: "#{id}-action",
    class: "nav-action",
    style: "padding-left: #{left_pad}px",
    "x-bind": "bindings.#{href.present? ? "link" : "toggle"}" do %>
    <div class="nav-action-inner">
      <% if children? %>
        <%= icon "chevron-down", size: 3, class: "nav-toggle-icon", "x-show": "open", "x-cloak": "true" %>
        <%= icon "chevron-right", size: 3, class: "nav-toggle-icon", "x-show": "!open", "x-cloak": "true" %>
      <% end %>
      <%= icon nav_icon, size: 3.5, class: "mr-1.5 text-lookbook-nav-icon-stroke" %>
      <span class="truncate <% if node.type == :preview %>font-semibold<% end %>"><%= label %></span>
    </div>
  <% end %>
  
  <% if children? %>
    <ul x-ref="items" x-show="open" x-cloak>
      <%= safe_join(children) %>
    </ul>
  <% end %>  
<% end %>

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
lookbook-2.3.0 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.2.2 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.2.1 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.2.0 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.1.1 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.1.0 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.5 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.4 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.3 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.2 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.1 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.rc.3 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.rc.2 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.rc.1 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.beta.9 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.beta.8 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.beta.7 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.beta.6 app/components/lookbook/nav/entity/component.html.erb
lookbook-2.0.0.beta.5 app/components/lookbook/nav/entity/component.html.erb