custom/plugins/SsikLibertyTheme/src/Resources/views/storefront/page/product-detail/tabs.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/page/product-detail/tabs.html.twig' %}
  2. {% block page_product_detail_tabs_navigation_description %}
  3.     <li class="nav-item" aria-controls="description-tab-pane" aria-selected="true" role="tab">
  4.         <a class="nav-link {% if (ratingSuccess != 1) and (ratingSuccess != -1) %}active{% endif %} product-detail-tab-navigation-link"
  5.             id="description-tab"
  6.             {{ dataBsToggleAttr }}="tab"
  7.             data-offcanvas-tabs="true"
  8.             href="#description-tab-pane"
  9.             
  10.             
  11.             >
  12.             <span>{{ "detail.tabsDescription"|trans|sw_sanitize }}</span>
  13.             <span class="product-detail-tab-navigation-icon">
  14.                 {% sw_icon 'arrow-medium-right' style {'pack':'solid'} %}
  15.             </span>
  16.             {% if page.product.translated.description|length > 0 %}
  17.                 <span class="product-detail-tab-preview">
  18.                     {{ page.product.translated.description|raw|striptags|sw_sanitize|u.truncate(125, '…') }}
  19.                     {# truncate always cuts down the length to 125 characters.
  20.                         So it will only shorten the string if it exceeds 125 chars.
  21.                         Therefor, only show the button when the length of the text is
  22.                         greater or equal then 126 characters. #}
  23.                     {% if page.product.translated.description|length >= 126 %}
  24.                         <span class="product-detail-tab-preview-more">{{ "detail.tabsPreviewMore"|trans|sw_sanitize }}</span>
  25.                     {% endif %}
  26.                 </span>
  27.             {% endif %}
  28.         </a>
  29.     </li>    
  30. {% endblock %}
  31. {% block page_product_detail_tabs_navigation_review %}
  32.         {% if config('core.listing.showReview') %}
  33.             <li class="nav-item" role="tab" aria-controls="review-tab-pane" aria-selected="true">
  34.                 <a class="nav-link {% if (ratingSuccess == 1) or (ratingSuccess == -1) %}active{% endif %} product-detail-tab-navigation-link"
  35.                     id="review-tab"
  36.                     {{ dataBsToggleAttr }}="tab"
  37.                     data-offcanvas-tabs="true"
  38.                     href="#review-tab-pane"
  39.                     
  40.                     
  41.                     >
  42.                     {{ "detail.tabsReview"|trans|sw_sanitize }}
  43.                     <span class="product-detail-tab-navigation-icon">
  44.                         {% sw_icon 'arrow-medium-right' style {'pack':'solid'} %}
  45.                     </span>
  46.                 </a>
  47.             </li>
  48.         {% endif %}
  49.     {% endblock %}