{% extends "wagtailadmin/base.html" %}
{% load gravatar staticfiles i18n %}
{% block titletag %}{% trans "Dashboard" %}{% endblock %}
{% block bodyclass %}homepage{% endblock %}

{% block extra_css %}
    {{ block.super }}

    <link rel="stylesheet" href="{% static 'wagtailadmin/css/layouts/home.css' %}" type="text/css" />
{% endblock %}

{% block content %}
    <header class="merged nice-padding">
        <div class="row row-flush">
            {% if user.email %}
                <div class="col1">
                    <div class="avatar icon icon-user"><img src="{% gravatar_url user.email %}" /></div>
                </div>
            {% endif %}
            <div class="col9">
                <h1>{% block branding_welcome %}{% blocktrans %}Welcome to the {{ site_name }} Wagtail CMS{% endblocktrans %}{% endblock %}</h1>
                <h2>{{ user.get_full_name|default:user.get_username }}</h2>
            </div>
        </div>
    </header>

    {% if panels %}
        {% for panel in panels %}
            {{ panel.render }}
        {% endfor %}
    {% else %}
        <p>{% trans "This is your dashboard on which helpful information about content you've created will be displayed." %}</p>
    {% endif %}
{% endblock %}
