sample files from a smithsonian project

This commit is contained in:
2024-05-22 00:26:01 -04:00
commit 265541edc3
76 changed files with 2140 additions and 0 deletions
@@ -0,0 +1,26 @@
{% macro display_date(date_content, attributes) %}
{% set rendered = date_content|render|striptags|trim %}
{% set dates = rendered|split(',') %}
{% include '@components/teaser/teaser--event/_teaser-date.twig' with {
teaser_start: dates.0|trim,
teaser_end: dates|length > 1 ? dates.1|trim : false,
drupal_attributes: attributes|without('class'),
modifier_classes: attributes.class|join(' ')|trim
} %}
{% endmacro %}
{% if label_display == 'visually_hidden' %}
<div{{ title_attributes.addClass('visually-hidden') }}>{{ label }}</div>
{% endif %}
{% if multiple %}
<div{{ attributes }}>
{% for item in items %}
{{ _self.display_date(item.content, item.attributes) }}
{% endfor %}
</div>
{% else %}
{% for item in items %}
{{ _self.display_date(item.content, attributes) }}
{% endfor %}
{% endif %}