{% macro create(optionName, permission, inputId, i18n) %}

    {% set inline = getMetadata(optionName, 'INLINE')|join(' ') %}
    {% set description = getMetadata(optionName, 'DESCRIPTION') %}
    {% set angularAttributes = getMetadata(optionName, 'ANGULAR_ATTRIBUTES') %}
    {% set verificationStatus = '{{ verificationStatus }}' %}
    {% set newNetwork = isOnNetworkDashboard() %}
    {% set disabled = "" %}

    {% if  newNetwork %}
        {% if not angularAttributes is empty %}
            {% set angularAttributes = angularAttributes ~ ' && (0))"' %}
        {% endif %}
    {% else %}

        {% if permission == 2 or permission == 1 %}
            {% set  disabled = "disabled" %}
        {% else %}
            {% set disabled = "" %}
        {% endif %}

        {% if not angularAttributes is empty %}
            {% set angularAttributes = angularAttributes ~ '&& (1))"' %}
        {% endif %}
    {% endif %}

    <input id="{{ inputId }}" type="password" {{ inline }} {{ angularAttributes|raw }} {{ disabled }}
           ng-model="option.{{ optionName }}" ng-class="{ error: messages.{{ optionName }} != null }"/>
    <button id="{{ inputId }}-button" {{ disabled }} type="button" class="button adi-button button-secondary"
            ng-click="verify()" {{ angularAttributes|raw }}>{{ i18n.verify }}
    </button>

    <p>
        <span ng-bind="messages.{{ optionName }}.error" class="error-msg"></span>
        <span ng-bind="messages.{{ optionName }}.warning" class="warning-msg"></span>
    </p>

    {% import "option/element/description.twig" as descriptionElement %}
    {{ descriptionElement.create(description) }}

{% endmacro %}