{% extends "orga/settings/base.html" %}
{% load bootstrap4 %}
{% load i18n %}
{% load staticfiles %}

{% block settings_content %}
<div class="flex-container"><div class="flex-content">
    <form method="post" action="" enctype="multipart/form-data">
        {% csrf_token %}
        <legend>
            {% trans "General information" %}
        </legend>

        {% bootstrap_field form.name layout='event' %}
        {% bootstrap_field form.slug layout='event' addon_before=url_placeholder addon_before_class="input-group-prepend input-group-text" %}
        {% bootstrap_field form.date_from layout='event' %}
        {% bootstrap_field form.date_to layout='event' %}
        {% bootstrap_field form.email layout='event' %}
        {% bootstrap_field sform.custom_domain layout='event' %}
        {% bootstrap_field form.timezone layout='event' %}
        {% bootstrap_field form.locale layout='event' %}
        {% bootstrap_field form.locales layout='event' %}
        {% bootstrap_field form.is_public layout='event' %}
        {% bootstrap_field sform.show_on_dashboard layout='event' %}
        {% bootstrap_field sform.show_schedule layout='event' %}
        {% bootstrap_field sform.show_sneak_peek layout='event' %}
        {% bootstrap_field sform.export_html_on_schedule_release layout='event' %}

        <legend>
            {% trans "Display settings" %}
        </legend>
        {% bootstrap_field form.landing_page_text layout='event' %}
        {% bootstrap_field form.primary_color layout='event' %}
        {% bootstrap_field form.custom_css layout='event' %}
        <div class="event-logo-field form-group row">
            <label class="col-md-3 col-form-label" for="id_custom_css">{% trans "Event logo" %}<br><span class="optional">Optional</span></label>
            <img class="event-logo-display"
              {% if request.event.logo %}
              src="{{ request.event.logo.url }}"
              {% else %}
              src="{% static "common/img/logo.svg" %}"
              {% endif %}
            />
            <div class="event-logo-form-fields">
                {% bootstrap_field form.logo layout='inline' %}
            </div>
        </div>
        {% bootstrap_field sform.display_header_pattern layout='event' %}
        {% include "orga/submit_row.html" %}
    </form>
</div></div>
{% endblock %}
