UI: Minor 2FA improvements (#3812)

Styles the "Remember me" checkbox on login and sets a proper width for the verification code field.
This commit is contained in:
d11n 2022-06-06 11:57:42 +02:00 committed by GitHub
parent ae10d0c7fd
commit 51ab9746de
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 9 deletions

View file

@ -7,16 +7,13 @@
<input asp-for="RememberMe" type="hidden"/> <input asp-for="RememberMe" type="hidden"/>
<div class="form-group"> <div class="form-group">
<label asp-for="TwoFactorCode" class="form-label"></label> <label asp-for="TwoFactorCode" class="form-label"></label>
<input asp-for="TwoFactorCode" class="form-control" autocomplete="off" autofocus style="width:13em"/> <input asp-for="TwoFactorCode" class="form-control" autocomplete="off" autofocus style="width:14ch"/>
<span asp-validation-for="TwoFactorCode" class="text-danger"></span> <span asp-validation-for="TwoFactorCode" class="text-danger"></span>
</div> </div>
<div class="form-group"> <div class="form-check mb-3">
<div class="checkbox"> <input asp-for="RememberMachine" type="checkbox" class="form-check-input" />
<label asp-for="RememberMachine" class="form-label"> <label asp-for="RememberMachine" class="form-check-label"></label>
<input asp-for="RememberMachine"/> <span asp-validation-for="RememberMachine" class="text-danger"></span>
@Html.DisplayNameFor(m => m.RememberMachine)
</label>
</div>
</div> </div>
<div class="form-group"> <div class="form-group">
<button type="submit" class="btn btn-primary">Log in</button> <button type="submit" class="btn btn-primary">Log in</button>

View file

@ -42,7 +42,7 @@
<input asp-for="SharedKey" type="hidden" /> <input asp-for="SharedKey" type="hidden" />
<div class="form-group"> <div class="form-group">
<label asp-for="Code" class="form-label">Verification Code</label> <label asp-for="Code" class="form-label">Verification Code</label>
<input asp-for="Code" class="form-control" autocomplete="off" /> <input asp-for="Code" class="form-control" autocomplete="off" autofocus style="width:14ch"/>
<span asp-validation-for="Code" class="text-danger"></span> <span asp-validation-for="Code" class="text-danger"></span>
</div> </div>
<button type="submit" class="btn btn-primary mt-2">Verify</button> <button type="submit" class="btn btn-primary mt-2">Verify</button>