diff --git a/stubs/resources/views/profile/edit.blade.php b/stubs/resources/views/profile/edit.blade.php index c949145..8e3db6c 100644 --- a/stubs/resources/views/profile/edit.blade.php +++ b/stubs/resources/views/profile/edit.blade.php @@ -19,6 +19,21 @@ @endif + @if(session('status') == 'two-factor-authentication-enabled') + {{-- Show SVG QR Code, After Enabling 2FA --}} +
+

+ {{ __('Two factor authentication is now enabled. Scan the following QR code using your phone\'s authenticator application.') }} +

+
{!! auth()->user()->twoFactorQrCodeSvg() !!}
+
+ + @endif +

+

{{ __('Active Sessions') }}

+
@@ -122,20 +139,22 @@ class="avatar avatar-xl"> @csrf @method('PUT') +

{{ __('Change Password') }}

+
- +
- +
- +
@@ -147,9 +166,9 @@ class="avatar avatar-xl"> -
- @if (Laravel\Fortify\Features::enabled(Laravel\Fortify\Features::twoFactorAuthentication())) +
+

{{ __('Two Factor Authentication') }}

@include('profile.two-factor-authentication-form') @endif diff --git a/stubs/resources/views/profile/two-factor-authentication-form.blade.php b/stubs/resources/views/profile/two-factor-authentication-form.blade.php index 3429898..ed0f902 100644 --- a/stubs/resources/views/profile/two-factor-authentication-form.blade.php +++ b/stubs/resources/views/profile/two-factor-authentication-form.blade.php @@ -3,50 +3,38 @@ @csrf - @else - {{-- Disable 2FA --}} - - @csrf - @method('DELETE') - - - - - @if(session('status') == 'two-factor-authentication-enabled') - {{-- Show SVG QR Code, After Enabling 2FA --}} -
- {{ __('Two factor authentication is now enabled. Scan the following QR code using your phone\'s authenticator application.') }} -
- -
- {!! auth()->user()->twoFactorQrCodeSvg() !!} -
- @endif - {{-- Show 2FA Recovery Codes --}} -
+

{{ __('Store these recovery codes in a secure password manager. They can be used to recover access to your account if your two factor authentication device is lost.') }} -

+

-
+
    @foreach (json_decode(decrypt(auth()->user()->two_factor_recovery_codes), true) as $code) -
    {{ $code }}
    +
  • {{ $code }}
  • @endforeach -
+ {{-- Regenerate 2FA Recovery Codes --}} - + + @csrf + + + {{-- Disable 2FA --}} + @csrf + @method('DELETE') - + + @endif -