mirror of
https://github.com/bitwarden/mobile
synced 2025-12-21 02:33:36 +00:00
2FA screen: move continue to a button (#1427)
* Move continue to a button * Resolve pr comments * Move use another two step method button * Resolve code suggestions * Resolve for iPhone * Apply suggestions from code review Co-authored-by: Thomas Rittson <31796059+eliykat@users.noreply.github.com> Co-authored-by: Thomas Rittson <31796059+eliykat@users.noreply.github.com>
This commit is contained in:
@@ -32,6 +32,7 @@ namespace Bit.App.Pages
|
||||
private string _totpInstruction;
|
||||
private string _webVaultUrl = "https://vault.bitwarden.com";
|
||||
private bool _authingWithSso = false;
|
||||
private bool _enableContinue = false;
|
||||
|
||||
public TwoFactorPageViewModel()
|
||||
{
|
||||
@@ -73,6 +74,14 @@ namespace Bit.App.Pages
|
||||
|
||||
public bool ShowTryAgain => YubikeyMethod && Device.RuntimePlatform == Device.iOS;
|
||||
|
||||
public bool ShowContinue { get; set; }
|
||||
|
||||
public bool EnableContinue
|
||||
{
|
||||
get => _enableContinue;
|
||||
set => SetProperty(ref _enableContinue, value);
|
||||
}
|
||||
|
||||
public string YubikeyInstruction => Device.RuntimePlatform == Device.iOS ? AppResources.YubiKeyInstructionIos :
|
||||
AppResources.YubiKeyInstruction;
|
||||
|
||||
@@ -169,14 +178,7 @@ namespace Bit.App.Pages
|
||||
{
|
||||
_messagingService.Send("listenYubiKeyOTP", false);
|
||||
}
|
||||
if (SelectedProviderType == null || DuoMethod)
|
||||
{
|
||||
page.RemoveContinueButton();
|
||||
}
|
||||
else
|
||||
{
|
||||
page.AddContinueButton();
|
||||
}
|
||||
ShowContinue = !(SelectedProviderType == null || DuoMethod);
|
||||
}
|
||||
|
||||
public async Task SubmitAsync()
|
||||
|
||||
Reference in New Issue
Block a user