picture_everywhere-1.0.0/templates/responsive-image.html.twig

templates/responsive-image.html.twig
{#
/**
 * @file
 * Override of responsive image template.
 *
 * Available variables:
 * - sources: The attributes of the <source> tags for this <picture> tag.
 * - img_element: The controlling image, with the fallback image in srcset.
 * - output_image_tag: Whether or not to output an <img> tag instead of a
 *   <picture> tag.
 *
 * @see template_preprocess()
 * @see template_preprocess_responsive_image()
 */
#}
{% if output_image_tag %}
  {{ img_element }}
{% else %}
  <picture{{ attributes }}>
    {% if sources %}
      {% for source_attributes in sources %}
        <source{{ source_attributes }}/>
      {% endfor %}
    {% endif %}
    {# The controlling image, with the fallback image in srcset. #}
    {{ img_element }}
  </picture>
{% endif %}

Главная | Обратная связь

drupal hosting | друпал хостинг | it patrol .inc