{% trans_default_domain 'Site' %}{% from ('main/site/views/Partials/icon.html.twig') import icon %}<section class="section gradient-pink-orange-light"> <div class="container-fluid"> <div class="section__title"> <h2 class="h1 text-center underline-bottom"> {{ 'site.home.sections.testimonies2.title'|trans }} {% if affiliateForLegalNotices(tracking) %} <sup>*</sup> {% endif %} </h2> <div class="mt-4 text-center"> <div class="rating-preview" style="--icon-size: 3rem; --rating: {{ marketingTestimoniesInfo.averageRating / 5 * 100 }}%"></div> </div> <p class="h3 text-center mt-1"> {{ marketingTestimoniesInfo.averageRating|number_format(1, ',') }}/5 {# ({{ marketingTestimoniesInfo.numberTestimonies }} {{ 'site.home.sections.testimonies2.subtitle'|trans }}) #} </p> </div> {% set testimoniesLength = testimonies|length %} {% set startFromTestimony = random(0, testimoniesLength) %} {% set itemsPerPage = 4 %} {% if testimonies and testimonies | length > 0 %} <div class="testimonie-list mb-2"> {% for item in testimonies %} {% if loop.index < 5 %} <div class="testimonie-list__item"> <div class="testimonie"> <div class="d-flex justify-content-between mb-3"> <div class="testimonie__rating"> <span class="testimonie__rating__holder"> <span data-rating="{{item.rating}}"></span> </span> </div> <div class="testimonie__meta"> {% if item.weightLoss %} <span>{{ item.weightLoss |round(1, 'floor') }} {{ 'site.testimonies.kgInfo'|trans }}</span> {% endif %} </div> </div> <div class="testimonie__review mb-2"> <p>“{{ item.message }}” {% if affiliateForLegalNotices(tracking) %}* {% endif %} </p> </div> <div class="d-flex justify-content-between mt-auto"> <div class="testimonie__user"> <h3 class="h5 mb-0 mt-0"> <span {% if item.country %} class="mr-1" {% endif %}> {{ item.firstname }}, {{ item.city }} </span> {% if item.country %} <img src="{{ asset('/images/main/flags/' ~ item.country | upper ~ '.svg') }}" width="18" height="12" loading="lazy" alt="{{ item.country }}"> {% endif %} </h3> <p class="mb-0 font-sm">{{ item.age }} {{ 'site.common.age'|trans }} {# - {{ item.created_at |format_datetime('medium', 'none') }} #} </p> </div> <div class="testimonie__date"> <p class="font-sm"> {{ item.testimonyDate|format_datetime(locale=app.request.locale ,pattern="d MMMM YYYY") }} </p> </div> </div> </div> </div> {% endif %} {% endfor %} </div> {% endif %} <p class="text-center"> <a href="{{ path('brulafine_avis_no_page') }}" class="btn btn-lg btn-default">{{ 'site.home.sections.testimonies.button'|trans }}</a> </p> {% if affiliateForLegalNotices(tracking) %} <p class="font-xs mb-0 text-center"> <sup>*</sup> {{ 'site.home.sections.testimonies2.text'|trans }} </p> {% endif %} {% if isAllowedToSeeDisclaimer(tracking) %} <p class="font-xs"><sup>*</sup>{{ 'site.home.hero.testimonies.legal'|trans }}</p> {% endif %} </div></section>