Sha256: 6ab66dfcfac6d2d3e057a1f1e5372f2b5b515696c0ac7283a2c63d759e0c0362

Contents?: true

Size: 1.02 KB

Versions: 25

Compression:

Stored size: 1.02 KB

Contents

<%
title = component[:attributes][:searchable_title].to_s
body = component[:attributes][:searchable_body].to_s
special_question = component[:attributes][:special_question]

image = component[:attributes][:image]
if image && image[:id]
  image_blob = ActiveStorage::Blob.find image[:id]
end
%>

<div class="<%= promethee_class_for component %> <%= 'promethee__component__faq_item--special' if special_question %>">
  <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-9 col-xs-9">
          <%= body.html_safe %>
        </div>
        <div class="col-3 col-xs-3">
          <%= render 'promethee/show/image.srcset', blob: image_blob, alt: '', caption: '' %>
        </div>
      </div>
    <% else %>
      <%= body.html_safe %>
    <% end %>
  </div>
</div>

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
promethee-2.0.7 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.6 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.5 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.4 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.3 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.2 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.1 app/views/promethee/components/faq_item/_show.html.erb
promethee-2.0.0 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.29 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.28 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.27 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.26 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.25 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.24 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.23 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.22 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.21 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.20 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.19 app/views/promethee/components/faq_item/_show.html.erb
promethee-1.11.18 app/views/promethee/components/faq_item/_show.html.erb