Style topics similarly to tags
This commit is contained in:
parent
b765898b22
commit
260cc2a0f9
2 changed files with 36 additions and 1 deletions
|
|
@ -0,0 +1,31 @@
|
||||||
|
{#
|
||||||
|
/**
|
||||||
|
* @file
|
||||||
|
*
|
||||||
|
* Available variables:
|
||||||
|
* - attributes: HTML attributes for the containing element.
|
||||||
|
* - label_hidden: Whether to show the field label or not.
|
||||||
|
* - title_attributes: HTML attributes for the title.
|
||||||
|
* - label: The label for the field.
|
||||||
|
* - multiple: TRUE if a field can contain multiple items.
|
||||||
|
* - items: List of all the field items. Each item contains:
|
||||||
|
* - attributes: List of HTML attributes for each item.
|
||||||
|
* - content: The field item's content.
|
||||||
|
* - entity_type: The entity type to which the field belongs.
|
||||||
|
* - field_name: The name of the field.
|
||||||
|
* - field_type: The type of the field.
|
||||||
|
* - label_display: The display settings for the label.
|
||||||
|
*
|
||||||
|
* @see template_preprocess_field()
|
||||||
|
*/
|
||||||
|
#}
|
||||||
|
|
||||||
|
<div class="flow_middle">
|
||||||
|
<h3 class="more-about-label subtitle is-mono is-5">Topic{% if items|length > 1 %}s{% endif %}</h3>
|
||||||
|
<p class="more-about-tags">
|
||||||
|
{% for item in items %}
|
||||||
|
{% if loop.length > 1 and loop.index == loop.length %}and {% endif %}
|
||||||
|
{{ item.content }}{% if loop.length > 2 and not loop.last %}, {% endif %}
|
||||||
|
{% endfor %}
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
|
@ -166,6 +166,10 @@
|
||||||
{% if content.field_tags is not empty %}
|
{% if content.field_tags is not empty %}
|
||||||
{{ content.field_tags }}
|
{{ content.field_tags }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
{% if content.field_topics is not empty %}
|
||||||
|
{{ content.field_topics }}
|
||||||
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
{{content.indieweb_syndication}}
|
{{content.indieweb_syndication}}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -174,7 +178,7 @@
|
||||||
</article>{# end h-entry article #}
|
</article>{# end h-entry article #}
|
||||||
|
|
||||||
<!-- Unexpected extra content -->
|
<!-- Unexpected extra content -->
|
||||||
{{ content|without('field_body_paragraph', 'field_authors', 'field_tags', 'uid', 'created', 'comment', 'indieweb_syndication') }}
|
{{ content|without('field_body_paragraph', 'field_authors', 'field_tags', 'field_topics', 'uid', 'created', 'comment', 'indieweb_syndication') }}
|
||||||
|
|
||||||
{% if content.comment %}
|
{% if content.comment %}
|
||||||
{{ content.comment }}
|
{{ content.comment }}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue