Sha256: ea43d23b944a3ae0e7095a1353b877114298b06659219993a09a625e95371f9d

Contents?: true

Size: 1.03 KB

Versions: 13

Compression:

Stored size: 1.03 KB

Contents

<%
title = component[:attributes].dig(:title, :value)&.to_s
body = component[:attributes].dig(:body, :value)&.to_s.html_safe
special_question = component[:attributes].dig(:special_question, :value)

image_blob = blob_from_data component[:attributes].dig(:image, :value)
%>

<div  class="<%= promethee_class_for component %> <%= 'promethee__component__faq_item--special' if special_question %>"
      id="<%= promethee_id_for component %>">
  <h4 data-toggle="collapse"
      data-target="#collapse-faq-<%= component[:id] %>"
      aria-expanded="false"
      aria-controls="collapse-faq-<%= component[:id] %>">
    <%= title %>
  </h4>

  <div class="collapse" id="collapse-faq-<%= component[:id] %>">
    <% if image_blob %>
      <div class="row ">
        <div class="col-3 col-xs-3">
          <%= render 'promethee/show/image.srcset', blob: image_blob, alt: '', title: '', caption: '' %>
        </div>
        <div class="col-9 col-xs-9">
          <%= body %>
        </div>
      </div>
    <% else %>
      <%= body %>
    <% end %>
  </div>
</div>

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
promethee-4.1.28 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.27 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.26 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.25 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.24 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.23 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.22 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.21 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.20 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.19 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.18 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.17 app/views/promethee/components/faq_item/_show.html.erb
promethee-4.1.16 app/views/promethee/components/faq_item/_show.html.erb