Sha256: 83ff3b58666c9fda2aaedf810b44ffb61858dae4f05e52e415fe04775d5fa4d5

Contents?: true

Size: 1.11 KB

Versions: 7

Compression:

Stored size: 1.11 KB

Contents

<div class="election__section-title">
  <%= icon "question-mark" %>
  <h2 class="h4"><%= t("decidim.elections.elections.preview.title") %></h2>
</div>

<p class="election__section-desc"><%= t("decidim.elections.elections.preview.description") %></p>

<ul id="accordion-preview" class="space-y-8" data-component="accordion">
  <% model.questions.each_with_index do |question, ix| %>
    <li class="election__accordion">
      <button id="accordion-trigger-<%= ix %>" data-controls="accordion-panel-<%= ix %>" class="election__accordion-trigger" <%= " data-open='true'" if model.questions.one? %>>
        <%= translated_attribute(question.title) %>
        <%= icon "arrow-down-s-line" %>
        <%= icon "arrow-up-s-line" %>
      </button>

      <div id="accordion-panel-<%= ix %>" class="election__accordion-panel" aria-hidden="true">
        <strong><%= t("decidim.elections.elections.preview.available_answers") %></strong>

        <ul>
          <% question.answers.each do |answer| %>
            <li><%= translated_attribute(answer.title) %></li>
          <% end %>
        </ul>
      </div>
    </li>
  <% end %>
</ul>

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
decidim-elections-0.28.4 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.3 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.2 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.1 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.0 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.0.rc5 app/cells/decidim/elections/election_preview/show.erb
decidim-elections-0.28.0.rc4 app/cells/decidim/elections/election_preview/show.erb