{% load i18n %}

{% if perms.afat.manage_afat and is_clickable_link and manual_fat_can_be_added %}
    {% translate 'This field is mandatory' as mandatory_info %}

    <div id="tab-manualfat" class="tab-pane fade card card-default border-0" role="tabpanel" aria-labelledby="tab-manualfat">
        <div class="card-body">
            <h4>{% translate "Manual FAT" %}</h4>

            <p>
                {% translate "Is someone missing from the list of FATs? Use this form to add them." %}
                <br>
                <strong>{% translate "Note" %}:</strong> {% translate "This action is logged!" %}
            </p>

            <form class="form" role="form" action="" method="POST">
                {% csrf_token %}
                <div class="form-group">
                    <div class="row">
                        <div class="col-md-12">
                            <div class="mb-3">
                                {% translate "Character name" as field_label %}

                                <label class="form-label" for="character">
                                    <span class="form-field-required">
                                        {{ field_label }}
                                        <span aria-label="{{ mandatory_info }}" class="form-required-marker">*</span>
                                    </span>
                                </label>

                                <input type="text" class="form-control" name="character" id="character" placeholder="{{ field_label }}" required>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <div class="row">
                        <div class="col-md-6">
                            <div class="mb-3">
                                {% translate "System" as field_label %}

                                <label class="form-label" for="system">
                                    <span class="form-field-required">
                                        {{ field_label }}
                                        <span aria-label="{{ mandatory_info }}" class="form-required-marker">*</span>
                                    </span>
                                </label>

                                <input type="text" class="form-control" name="system" id="system" placeholder="{{ field_label }}" required>
                            </div>
                        </div>

                        <div class="col-md-6">
                            <div class="mb-3">
                                {% translate "Ship type" as field_label %}

                                <label class="form-label" for="shiptype">
                                    <span class="form-field-required">
                                        {{ field_label }}
                                        <span aria-label="{{ mandatory_info }}" class="form-required-marker">*</span>
                                    </span>
                                </label>

                                <input type="text" class="form-control" name="shiptype" id="shiptype" placeholder="{{ field_label }}" required>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="form-group text-end">
                    <button class="btn btn-primary" type="submit" name="manual_fat">
                        {% translate "Add manual FAT" %}
                    </button>
                </div>
            </form>
        </div>
    </div>
{% endif %}
