{% extends "views/platform-admin/_base_template.html" %}
{% from "components/page-header.html" import page_header %}
{% from "components/live-search.html" import live_search %}

{% block per_page_title %}
  Email branding
{% endblock %}

{% block platform_admin_content %}

  {{ page_header('Email branding') }}
  {{ live_search(target_selector='.email-brand', show=True, form=search_form) }}
  <nav>
    {% for brand in email_brandings %}
      <div class="email-brand">
        <div class="message-name">
          <a href="{{ url_for('.update_email_branding', branding_id=brand.id) }}">
            {{ brand.name or 'Unnamed' }}
          </a>
        </div>
      </div>
    {% endfor %}
  </nav>
  <div class="js-stick-at-bottom-when-scrolling">
    <a href="{{ url_for('.create_email_branding') }}" class="button-secondary">New brand</a>
  </div>

{% endblock %}
