{{#modal-dialog action="closeModal"}}
  {{#if showLastChance}}
    <div class='card'>
      <div class='text-content'>
        <div class='content-header'>
          <h4>{{headerText}}</h4>
        </div>
        <div class='item'>
          <div class='js-editable'>
            {{#if hasError}}
              <div class="subwindow_notice">{{errorMsg}}</div>
            {{/if}}
            <p class="mg-b-1">{{lastChanceAppearText}}</p>
            <div class="brick brick--pd-lg strong align-center">{{newDisplayname}} ({{login.userData.login}})</div>
            <p class="sub mg-b-1 sub-text">{{lastChancePermanentText}}</p>
          </div>
        </div>
        <div class='buttons'>
          <a {{action 'showChangeDisplayname'}} class='js-subwindow-close button button--text'>
            {{back}}
          </a>
          <button {{action 'changeDisplayname' newDisplayname}} class='button primary' type='button'>
            {{submit}}
          </button>
        </div>
      </div>
    </div>
  {{else}}
    <div class='card'>
      <div class='text-content'>
        <div class='content-header'>
          <h4>{{headerText}}</h4>
        </div>
        <div class='item'>
          <div class='js-editable'>
            <p class="mg-b-1">{{modalText}}</p>
            {{input type="text" class="text" value=newDisplayname}}
            <p class="sub mg-b-1 sub-text">{{loginText}}</p>
          </div>
        </div>
        <div class='buttons'>
          <a {{action 'closeModal'}} class='js-subwindow-close button button--text'>
            {{cancel}}
          </a>
          <button {{action 'showLastChance'}} class='button primary' type='button'>
            {{ok}}
          </button>
        </div>
      </div>
    </div>
  {{/if}}
{{/modal-dialog}}
