simplified security key management interface.

This commit is contained in:
Adrian Astles 2025-07-06 20:41:26 +08:00
parent 5009906385
commit a093c54b16
2 changed files with 7 additions and 14 deletions

View file

@ -1150,7 +1150,7 @@
"securityKeyLoadError": "Failed to load security keys",
"securityKeyLogin": "Sign in with security key",
"securityKeyAuthError": "Failed to authenticate with security key",
"securityKeyRecommendation": "Consider registering another security key on a different device to ensure you don't get locked out of your account.",
"securityKeyRecommendation": "Tip: Register a backup security key on another device to ensure you always have access to your account.",
"registering": "Registering...",
"securityKeyPrompt": "Please verify your identity using your security key. Make sure your security key is connected and ready.",
"securityKeyBrowserNotSupported": "Your browser doesn't support security keys. Please use a modern browser like Chrome, Firefox, or Safari.",

View file

@ -267,19 +267,12 @@ export default function SecurityKeyForm({ open, setOpen }: SecurityKeyFormProps)
<div className="space-y-4">
<div className="flex items-center justify-between">
<h3 className="text-sm font-medium text-muted-foreground">{t('securityKeyList')}</h3>
<div className="flex items-center gap-2">
{securityKeys.length > 0 && (
<Badge className="text-xs">
{securityKeys.length} {securityKeys.length === 1 ? 'key' : 'keys'}
</Badge>
)}
<Button
className="h-8 w-8 p-0"
onClick={() => setShowRegisterDialog(true)}
>
<Plus className="h-4 w-4" />
</Button>
</div>
<Button
className="h-8 w-8 p-0"
onClick={() => setShowRegisterDialog(true)}
>
<Plus className="h-4 w-4" />
</Button>
</div>
{securityKeys.length > 0 ? (