{# Show a dialog #}
{% embed '@Contao/backend/template_studio/show_modal.stream.html.twig' %}
    {% trans_default_domain 'contao_template_studio' %}

    {% set identifier_token -%}
        <span class="token">{{ identifier }}</span>
    {%- endset %}

    {% block title %}{{ ('template_studio.operation.' ~ operation ~ '.0')|trans }}{% endblock %}

    {% block content %}
        <div class="description">
            {{ ('template_studio.dialog.' ~ operation_type ~ '_variant')|trans([identifier_token])|raw }}
        </div>

        <div class="template_name name_container">
            <h3>
                <label for="ctrl_variant_name">
                    <span class="invisible">{{ 'MSC.mandatory'|trans(domain: 'contao_default') }}</span>
                    {{ 'MSC.name'|trans(domain: 'contao_default') }}
                    <span class="mandatory">*</span>
                </label>
            </h3>
            <span class="structure">
                <span class="identifier identifier--user">{{ identifier }}</span>
                <span class="/">{{ separator|default('/') }}</span>
                <input class="identifier identifier--user" type="text" id="ctrl_variant_name" name="identifier_fragment" pattern="{{ allowed_identifier_fragment_pattern }}" value="{{ suggested_identifier_fragment }}" required>
                <span class="extension">.{{ extension }}</span>
            </span>
        </div>
    {% endblock %}

    {% block buttons %}
        {{ parent() }}
        <button class="confirm">{{ 'MSC.apply'|trans(domain: 'contao_default') }}</button>
    {% endblock %}
{% endembed %}
