{% set classes = [
  'branding-block',
] %}
{% set attributes = attributes|default(create_attribute()) %}
{% set attributes = attributes.setAttribute('class', classes) %}
{% set attributes = attributes.setAttribute('data-js', 'branding-block') %}

<div{{ attributes }}>
  <a
    href="{{ branding_block_path }}"
    title="{{ 'Home'|t }}"
    aria-label="Go to {{ branding_block_site_name|striptags }} homepage"
    rel="home"
  >
    {% if branding_block_site_logo %}
      <img
        src="{{ branding_block_site_logo }}"
        alt="{{ branding_block_site_name|striptags }} Logo">
    {% else %}
      {% if branding_block_site_name %}
        <div class="branding-block__site-name">
          {{ branding_block_site_name }}
        </div>
      {% endif %}
    {% endif %}
  </a>
</div>
