feat(apk): bouton de copie du code 2FA sur chaque ligne de la liste
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
+10
@@ -2032,6 +2032,16 @@ begin
|
||||
begin
|
||||
E := FVault.Entry(LIdx);
|
||||
if Param('f') = 'user' then CopyToClipboard(E.Username, 'Username')
|
||||
else if Param('f') = 'rtotp' then
|
||||
begin
|
||||
// Calcule a l'instant de la copie : un code se perime en 30 s.
|
||||
var LLeft, LPeriod: Integer;
|
||||
var LCode := TotpNow(E.Totp, LLeft, LPeriod);
|
||||
if LCode <> '' then
|
||||
CopyToClipboard(LCode, Format('2FA code (%d s left)', [LLeft]))
|
||||
else
|
||||
WebCall('PM.toast("Unreadable 2FA secret")');
|
||||
end
|
||||
else if E.IsNote then CopyToClipboard(E.Password, 'Content')
|
||||
else CopyToClipboard(E.Password, 'Password');
|
||||
end;
|
||||
|
||||
Reference in New Issue
Block a user