<clr-modal [(clrModalOpen)]="opened" [clrModalStaticBackdrop]="staticBackdrop" [clrModalClosable]="false">
    <h3 class="modal-title">{{'PROFILE.TITLE' | translate}}</h3>
    <inline-alert class="modal-title" (confirmEvt)="confirmCancel($event)"></inline-alert>
    <div class="modal-body" style="overflow-y: hidden;">
        <form #accountSettingsFrom="ngForm" class="form">
            <section class="form-block">
                <div class="form-group form-group-override">
                    <label for="account_settings_username" class="form-group-label-override">{{'PROFILE.USER_NAME' | translate}}</label>
                    <input type="text" name="account_settings_username" [(ngModel)]="account.username" disabled id="account_settings_username" size="33">
                </div>
                <div class="form-group form-group-override">
                    <label for="account_settings_email" class="required form-group-label-override">{{'PROFILE.EMAIL' | translate}}</label>
                    <label for="account_settings_email" aria-haspopup="true" role="tooltip" class="tooltip tooltip-validation tooltip-md tooltip-top-left" [class.invalid]='!getValidationState("account_settings_email")'>
                      <input name="account_settings_email" type="text" #eamilInput="ngModel" [(ngModel)]="account.email" 
                      required 
                      email
                      id="account_settings_email" size="30" 
                      (input)='handleValidation("account_settings_email", false)' 
                      (blur)='handleValidation("account_settings_email", true)'>
                      <span class="tooltip-content">
                          {{emailTooltip | translate}}
                      </span>
                    </label><span class="spinner spinner-inline" [hidden]="!checkProgress"></span>
                </div>
                <div class="form-group form-group-override">
                    <label for="account_settings_full_name" class="required form-group-label-override">{{'PROFILE.FULL_NAME' | translate}}</label>
                    <label for="account_settings_full_name" aria-haspopup="true" role="tooltip" class="tooltip tooltip-validation tooltip-md tooltip-top-left" [class.invalid]='!getValidationState("account_settings_full_name")'>
                      <input type="text" name="account_settings_full_name" #fullNameInput="ngModel" [(ngModel)]="account.realname" required maxLengthExt="20" id="account_settings_full_name" size="30" (input)='handleValidation("account_settings_full_name", false)' (blur)='handleValidation("account_settings_full_name", true)'>
                      <span class="tooltip-content">
                          {{'TOOLTIP.FULL_NAME' | translate}}
                      </span>
                    </label>
                </div>
                <div class="form-group form-group-override">
                    <label for="account_settings_comments" class="form-group-label-override">{{'PROFILE.COMMENT' | translate}}</label>
                    <label for="account_settings_comments" aria-haspopup="true" role="tooltip" class="tooltip tooltip-validation tooltip-md tooltip-top-left" [class.invalid]="commentInput.invalid && (commentInput.dirty || commentInput.touched)">
                    <input type="text" #commentInput="ngModel" maxLengthExt="20" name="account_settings_comments" [(ngModel)]="account.comment" id="account_settings_comments" size="30">
                    <span class="tooltip-content">
                        {{'TOOLTIP.COMMENT' | translate}}
                    </span>
                    </label>
                </div>
            </section>
        </form>
    </div>
    <div class="modal-footer">
        <span class="spinner spinner-inline" style="top:8px;" [hidden]="showProgress === false"></span>
        <button type="button" class="btn btn-outline" (click)="close()">{{'BUTTON.CANCEL' | translate}}</button>
        <button type="button" class="btn btn-primary" [disabled]="!isValid || showProgress" (click)="submit()">{{'BUTTON.OK' | translate}}</button>
    </div>
</clr-modal>