Skip to content

Commit

Permalink
Merge pull request #256 from yalesites-org/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
vinmassaro authored Aug 6, 2024
2 parents 2f30a7b + bf4c935 commit ab33322
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 13 deletions.
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{{ content }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{% extends "@atomic/block/layout-builder/_layout-builder-block-template.twig" %}

{% block content %}

{% if parentNode == 'post' or parentNode == 'event' %}
{% set inline_message__width = "content" %}
{% set inline_message__alignment = "center" %}()
{% else %}
{% set inline_message__width = "site" %}
{% set inline_message__alignment = "left" %}
{% endif %}

{% include "@molecules/inline-message/yds-inline-message.twig" with {
inline_message__heading: content.field_heading.0,
inline_message__content: content.field_text.0,
inline_message__link__content: content.field_link.0['#title'],
inline_message__link__url: content.field_link.0['#url_title'],
inline_message__theme: content.field_style_color.0['#markup'],
} %}
{% endblock %}
9 changes: 2 additions & 7 deletions templates/layout/region--header.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,15 @@
{% set site_header__site_name_is_image = getHeaderSetting('site_name_image') %}
{% endif %}

{# set primary and utility nave variables equal to their drupal elements #}
{# this is necessary to pass the truthiness of the elements to the site-header organism #}
{# which will set {% set site_header__hamburger = 'yes' %} #}
{# and render the hamburger icon if the primary nav exists or the ulitity nav exists #}
{% set primary_nav__items = elements.main_navigation.content['#items'] %}
{% set utility_nav__items = elements.utility_navigation.content['#items'] %}

{% embed "@organisms/site-header/yds-site-header.twig" with {
site_name: site_name,
site_header__border_thickness: '8',
site_header__theme: getThemeSetting('header_theme'),
site_header__accent: getThemeSetting('header_accent'),
site_header__menu__variation: getHeaderSetting('header_variation'),
site_header__nav_position: getHeaderSetting('nav_position'),
site_header__branding_name: getHeaderSetting('site_wide_branding_name')|default('Yale University'),
site_header__branding_link: getHeaderSetting('site_wide_branding_link')|default('https://www.yale.edu'),
drupal_utility_nav: elements.utility_navigation,
} %}
{% block site_header__primary_nav %}
Expand Down

0 comments on commit ab33322

Please sign in to comment.