<form id="profile-settings" role="form" action="{{site.uri.public}}/account/settings/profile" method="post">
    <div class="box-header">
        <h3 class="box-title"><i class="fas fa-user fa-fw"></i> {{translate("PROFILE.SETTINGS")}}</h3>
    </div>
    <div class="box-body">
        {% include "forms/csrf.html.twig" %}

        {% block settings_profile %}
            <label for="input-first-name" class="control-label">{{translate("NAME")}}</label>
            <div class="row">
                <div class="col-sm-6">
                    <div class="form-group">
                        <input type="text" id="input-first-name" class="form-control" name="first_name" value="{{current_user.first_name}}" placeholder="{{translate("FIRST_NAME")}}" {{page.visibility}}>
                    </div>
                </div>
                <div class="col-sm-6">
                    <div class="form-group">
                        <input type="text" id="input-last-name" class="form-control" name="last_name" value="{{current_user.last_name}}" placeholder="{{translate("LAST_NAME")}}" {{page.visibility}}>
                    </div>
                </div>
            </div>

            {% if 'locale' not in fields.hidden %}
            <div class="form-group">
                <label for="input-locale" class="control-label">{{translate("LOCALE")}}</label>
                <select id="input-locale" class="form-control js-select2" name="locale" {{page.visibility}}>
                    {% for option, label in locales %}
                        {% if label is not empty %}
                            <option value="{{option}}" {% if (option == current_user.locale) %}selected{% endif %}>{{label}}</option>
                        {% endif %}
                    {% endfor %}
                </select>
                <p class="help-block">{{translate("LOCALE.ACCOUNT")}}.</p>
            </div>
            {% endif %}
        {% endblock %}
    </div>
    <div class="box-footer text-center">
        <button type="reset" class="btn btn-default">{{translate('RESET')}}</button>
        <button type="submit" class="btn btn-primary js-submit">{{translate('SAVE')}}</button>
    </div>
</form>
