Sha256: 6c02d086f6845f54afc49c0eddd3773ce0b12729aa3acb734f967b2d0da103a4

Contents?: true

Size: 912 Bytes

Versions: 11

Compression:

Stored size: 912 Bytes

Contents

<% if items.any? %>
  <div class="<%= component_class %>" id="<%= id %>">
    <% items.each do |item| %>
      <div class="accordion-item">
        <h2
          id="<%= item.header_id %>"
          class="accordion-header"
        >
          <button
            class="<%= item.button_class %>"
            type="button"
            data-toggle="collapse"
            data-target="#<%= item.collapse_id %>"
            aria-expanded="true"
            aria-controls="<%= item.collapse_id %>"
          >
              <%= item.title %>
          </button>
        </h2>
        <div
          id="<%= item.collapse_id %>"
          class="<%= item.collapse_class %>"
          aria-labelledby="<%= item.header_id %>"
          data-parent="#<%= id %>"
        >
          <div class="accordion-body">
            <%= item.content %>
          </div>
        </div>
      </div>
    <% end %>
  </div>
<% end %>

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
bs5-0.0.13 app/components/bs5/accordion_component.html.erb
bs5-0.0.12 app/components/bs5/accordion_component.html.erb
bs5-0.0.11 app/components/bs5/accordion_component.html.erb
bs5-0.0.10 app/components/bs5/accordion_component.html.erb
bs5-0.0.9 app/components/bs5/accordion_component.html.erb
bs5-0.0.8 app/components/bs5/accordion_component.html.erb
bs5-0.0.7 app/components/bs5/accordion_component.html.erb
bs5-0.0.6 app/components/bs5/accordion_component.html.erb
bs5-0.0.5 app/components/bs5/accordion_component.html.erb
bs5-0.0.4 app/components/bs5/accordion_component.html.erb
bs5-0.0.3 app/components/bs5/accordion_component.html.erb