vendor/sylius/sylius/src/Sylius/Bundle/ShopBundle/Resources/views/Product/_mainImage.html.twig line 1

Open in your IDE?
  1. {% if product.imagesByType('thumbnail') is not empty %}
  2.     {% set path = product.imagesByType('thumbnail').first.path|imagine_filter(filter|default('sylius_shop_product_thumbnail')) %}
  3. {% elseif product.images.first %}
  4.     {% set path = product.images.first.path|imagine_filter(filter|default('sylius_shop_product_thumbnail')) %}
  5. {% else %}
  6.     {% set path = asset('assets/shop/img/200x200.png') %}
  7. {% endif %}
  8. <img src="{{ path }}" {{ sylius_test_html_attribute('main-image') }} alt="{{ product.name }}" class="ui bordered image" />