diff --git a/agaric/templates/paragraph/paragraph--title.html.twig b/agaric/templates/paragraph/paragraph--title.html.twig index ab8a051..6048bac 100644 --- a/agaric/templates/paragraph/paragraph--title.html.twig +++ b/agaric/templates/paragraph/paragraph--title.html.twig @@ -44,10 +44,10 @@ not paragraph.isPublished() ? 'paragraph--unpublished' ] %} -{% if paragraph.field_style_color %} +{% if paragraph.field_style_color is not empty %} {% set classes = classes|merge(['is-'~paragraph.field_style_color.value]) %} {% endif %} -{% if paragraph.field_style_titlebar is empty %} +{% if paragraph.field_style_titlebar.value == false %} {% set classes = classes|merge(['hero-project']) %} {% endif %} {% if paragraph.field_style_classes is not empty %} @@ -58,14 +58,14 @@ {% set classes = classes|merge(styles) %} {% endif %} -{% if paragraph.field_style_titlebar is not empty and paragraph.field_image is not empty %} +{% if paragraph.field_style_titlebar.value == true and paragraph.field_image is not empty %} {% set attributes = attributes.setAttribute('data-headerbg', 'transparent').setAttribute('style', 'background-image: url('~file_url(paragraph.field_image.entity.uri.value)~')') %} {% endif %} {% block paragraph %} {% block content %} - {% if paragraph.field_style_titlebar is empty %} + {% if paragraph.field_style_titlebar.value == false %}
{{ content.field_image }}