1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-07-18 20:59:39 +02:00

Add manual entry option for two-factor authentication setup
Some checks are pending
Publish Docker image / ci (push) Waiting to run
Publish Docker image / Build docker image (push) Blocked by required conditions

This commit is contained in:
Josh Pigford 2025-02-12 09:15:00 -06:00
parent d31d5c5467
commit 945a39d035
2 changed files with 25 additions and 0 deletions

View file

@ -15,6 +15,29 @@
<%= generate_mfa_qr_code(Current.user.provisioning_uri) %>
</div>
<div class="mt-6">
<h3 class="text-sm font-medium text-gray-900"><%= t(".secret_title") %></h3>
<div class="mt-2 text-sm text-gray-500">
<p><%= t(".secret_description") %></p>
</div>
<div class="mt-2 flex items-center gap-2" data-controller="clipboard">
<span data-clipboard-target="source" class="hidden"><%= Current.user.otp_secret %></span>
<input type="text"
readonly
autocomplete="off"
value="<%= Current.user.otp_secret %>"
class="text-sm bg-gray-50 px-2 py-1 rounded border border-gray-200 w-96 font-mono">
<button data-action="clipboard#copy" class="text-gray-500 hover:text-gray-700">
<span data-clipboard-target="iconDefault">
<%= lucide_icon "copy", class: "w-5 h-5" %>
</span>
<span class="hidden" data-clipboard-target="iconSuccess">
<%= lucide_icon "check", class: "w-5 h-5" %>
</span>
</button>
</div>
</div>
<div>
<h3 class="text-lg font-medium leading-6 text-gray-900"><%= t(".verify_title") %></h3>
<div class="mt-2 text-sm text-gray-500">

View file

@ -22,6 +22,8 @@ en:
scan_description: Use an authenticator app like Google Authenticator or 1Password
to scan this QR code
scan_title: 1. Scan QR Code
secret_description: If you can't scan the QR code, enter this secret key manually in your authenticator app
secret_title: Manual Entry Code
title: Set Up Two-Factor Authentication
verify_button: Verify and Enable 2FA
verify_description: Enter the 6-digit code from your authenticator app