{# @var craft \craft\web\twig\variables\CraftVariable #} {# @var entry \craft\elements\Entry #} {# o-imageGrid ------------------------------------------------------------ #} {# -- Set Defaults -- #} {% set defaults = { cn: 'o-imageGrid', modifiers: [], customClasses: [], data: {}, js: null, images: null, caption: null, ratio: null } %} {# -- Merge Default with Options -- #} {% set opt = opt is defined ? defaults|merge(opt) : defaults %} {# -- Modul -- #} {% if opt.images %}
{% include '_molecules/figure/_template.html' with { opt: { image: image ?? null, ratio: opt.ratio ?? null, caption: opt.caption ?? null, captionHeadline: image.imageTitle ?? null, captionText: image.imageCaption ?? null, captionSource: image.imageSource ?? null, captionSourceUrl: image.imageSourceUrl ?? null } } only %}
{% endfor %} {% endif %}