{% extends "Comitium5DesignerBundle:Widget:base.html.twig" %}

{% form_theme form 'Comitium5DesignerBundle:Widget:theme.html.twig' %}

{% set body_class = 'cs_editor_widget_form' %}

{% block content_base %}
    <div class="page-container" style="min-height: 550px; background: #FFFFFF none repeat scroll 0 0;">
        <div class="page-content-wrapper">
            {% set widget = entity.widget %}
            <div class="csmodal-title">{{ "widget.editor.tab.data"|transchoice((widget is null ? 0 : 1),{'%widget_name%' : (widget is null ? '' : widget.name)}) }}</div>

            {{ form_start(form, {attr:{class:'form-horizontal' ~ (form.vars._hasFormat == true ? '' : ' tabbable-custom')}}) }}

            {% if form.vars._hasFormat == true %}
                {% include 'Comitium5DesignerBundle:Widget:tabs.html.twig' %}
            {% else %}
                {% for parameter in form.parameters %}
                    <div class="cs_vce_param">
                        {{ form_widget(parameter) }}
                    </div>
                {% endfor %}
            {% endif %}

            {{ form_end(form) }}
        </div>
    </div>
{% endblock %}
