fix: 🐛

This commit is contained in:
codytseng
2025-07-01 22:55:59 +08:00
parent f8572d0795
commit 2489e8098d
2 changed files with 8 additions and 8 deletions

View File

@@ -38,7 +38,7 @@ export default function GenerateNewAccount({
'This is a private key. Do not share it with anyone. Keep it safe and secure. You will not be able to recover it if you lose it.' 'This is a private key. Do not share it with anyone. Keep it safe and secure. You will not be able to recover it if you lose it.'
)} )}
</div> </div>
<div className="space-y-1"> <div className="grid gap-2">
<Label>nsec</Label> <Label>nsec</Label>
<div className="flex gap-2"> <div className="flex gap-2">
<Input value={nsec} /> <Input value={nsec} />
@@ -56,7 +56,7 @@ export default function GenerateNewAccount({
</Button> </Button>
</div> </div>
</div> </div>
<div className="space-y-1"> <div className="grid gap-2">
<Label htmlFor="password-input">{t('password')}</Label> <Label htmlFor="password-input">{t('password')}</Label>
<Input <Input
id="password-input" id="password-input"
@@ -67,7 +67,7 @@ export default function GenerateNewAccount({
/> />
</div> </div>
<div className="flex gap-2"> <div className="flex gap-2">
<Button className="w-fit px-8" variant="secondary" onClick={back}> <Button className="w-fit px-8" variant="secondary" type="button" onClick={back}>
{t('Back')} {t('Back')}
</Button> </Button>
<Button className="flex-1" type="submit"> <Button className="flex-1" type="submit">

View File

@@ -64,7 +64,7 @@ function NsecLogin({ back, onLoginSuccess }: { back: () => void; onLoginSuccess:
'Using private key login is insecure. It is recommended to use a browser extension for login, such as alby, nostr-keyx or nos2x. If you must use a private key, please set a password for encryption at minimum.' 'Using private key login is insecure. It is recommended to use a browser extension for login, such as alby, nostr-keyx or nos2x. If you must use a private key, please set a password for encryption at minimum.'
)} )}
</div> </div>
<div className="space-y-1"> <div className="grid gap-2">
<Label htmlFor="nsec-input">nsec or hex</Label> <Label htmlFor="nsec-input">nsec or hex</Label>
<Input <Input
id="nsec-input" id="nsec-input"
@@ -76,7 +76,7 @@ function NsecLogin({ back, onLoginSuccess }: { back: () => void; onLoginSuccess:
/> />
{errMsg && <div className="text-xs text-destructive">{errMsg}</div>} {errMsg && <div className="text-xs text-destructive">{errMsg}</div>}
</div> </div>
<div className="space-y-1"> <div className="grid gap-2">
<Label htmlFor="password-input">{t('password')}</Label> <Label htmlFor="password-input">{t('password')}</Label>
<Input <Input
id="password-input" id="password-input"
@@ -87,7 +87,7 @@ function NsecLogin({ back, onLoginSuccess }: { back: () => void; onLoginSuccess:
/> />
</div> </div>
<div className="flex gap-2"> <div className="flex gap-2">
<Button className="w-fit px-8" variant="secondary" onClick={back}> <Button className="w-fit px-8" variant="secondary" type="button" onClick={back}>
{t('Back')} {t('Back')}
</Button> </Button>
<Button className="flex-1" type="submit"> <Button className="flex-1" type="submit">
@@ -133,7 +133,7 @@ function NcryptsecLogin({
handleLogin() handleLogin()
}} }}
> >
<div className="space-y-1"> <div className="grid gap-2">
<Label htmlFor="ncryptsec-input">ncryptsec</Label> <Label htmlFor="ncryptsec-input">ncryptsec</Label>
<Input <Input
id="ncryptsec-input" id="ncryptsec-input"
@@ -146,7 +146,7 @@ function NcryptsecLogin({
{errMsg && <div className="text-xs text-destructive">{errMsg}</div>} {errMsg && <div className="text-xs text-destructive">{errMsg}</div>}
</div> </div>
<div className="flex gap-2"> <div className="flex gap-2">
<Button className="w-fit px-8" variant="secondary" onClick={back}> <Button className="w-fit px-8" variant="secondary" type="button" onClick={back}>
{t('Back')} {t('Back')}
</Button> </Button>
<Button className="flex-1" type="submit"> <Button className="flex-1" type="submit">