<app-header></app-header>

<form [formGroup]="formGroup" [bitSubmit]="submit" class="tw-max-w-xl">
  <bit-file-upload formControlName="file" accept="application/JSON">
    <bit-label>{{ "fileUpload" | i18n }}</bit-label>
    <bit-hint>{{ "acceptedFormats" | i18n }} Bitwarden (json)</bit-hint>
  </bit-file-upload>
  <div class="tw-my-4">
    {{ "or" | i18n }}
  </div>
  <bit-form-field>
    <bit-label for="pastedContents">{{ "copyPasteImportContents" | i18n }}</bit-label>
    <textarea
      bitInput
      id="pastedContents"
      name="FileContents"
      formControlName="pastedContents"
    ></textarea>
    <bit-hint>{{ "acceptedFormats" | i18n }} Bitwarden (json)</bit-hint>
  </bit-form-field>
  <button bitButton bitFormButton type="submit" buttonType="primary">
    {{ "importVerb" | i18n }}
  </button>
</form>
