diff --git a/agaric/templates/layout/layout--onecol--node.html.twig b/agaric/templates/layout/layout--onecol--node.html.twig index d984cea..ed498a9 100644 --- a/agaric/templates/layout/layout--onecol--node.html.twig +++ b/agaric/templates/layout/layout--onecol--node.html.twig @@ -22,16 +22,15 @@ {# expected if statement would start here #} {% set classes = classes|merge(['is-dark']) %} -{% set title_paragraph_index = 'silly' %} -{% set tpi = null %} +{% set title_paragraph_index = null %} {% set has_title_paragraph = false %} {% if content.field_body_paragraph %} - {% for i, paragraph in content.field_body_paragraph['#items'] %} - {% if paragraph.entity.type.0.entity.id == 'title' %} + {% for i, paragraph in content.field_body_paragraph if i|first != '#' %} + {% if content.field_body_paragraph['#items'][i].entity.type.0.entity.id == 'title' %} + HOLY MOLY THIS HAS TAKEN A WHILE {% set has_title_paragraph = true %} - {{ content.field_body_paragraph[i] }} {% set title_paragraph_index = i %} - {% set tpi = i %} + {{ paragraph }} {% endif %} {% endfor %} {% endif %} @@ -47,21 +46,21 @@ {% endif %} -{{ content.field_simple_multivalue[0] }} -{% for i in 1..2 %} - {{ content.field_simple_multivalue[i] }} -{% endfor %} - -AND HERE COMES THE REST
-No number huh? {{ title_paragraph_index }} -
Ehh? {{ tpi }} -
Gah. {{ has_title_paragraph }} {% for i, paragraph in content.field_body_paragraph if i|first != '#' %} - NOO NUMBERSSS {{ i }} - {{ paragraph }} + {% if i is not same as(title_paragraph_index) %} + {{ paragraph }} + {% endif %} {% endfor %} {{ content|without('content', 'field_body_paragraph') }} +SANITY CHECK + +{{ content }} + +NOPE EVERYTHING IS INSANE OH WELL + +{{ content.content }} + {% endif %}