Display invalid mnemonic warning
This commit is contained in:
parent
42d2ea710d
commit
a666b172e9
|
@ -315,7 +315,7 @@ function RestoreWalletForm({ goBack }) {
|
|||
const mnemonic = normalizeMnemonic(rawMnemonic);
|
||||
const isNextBtnEnabled =
|
||||
password === passwordConfirm && validateMnemonic(mnemonic);
|
||||
|
||||
const displayInvalidMnemonic = validateMnemonic(mnemonic) === false && mnemonic.length > 0;
|
||||
return (
|
||||
<>
|
||||
{next ? (
|
||||
|
@ -340,6 +340,11 @@ function RestoreWalletForm({ goBack }) {
|
|||
<b>Do not enter your hardware wallet seedphrase here.</b> Hardware
|
||||
wallets can be optionally connected after a web wallet is created.
|
||||
</Typography>
|
||||
{displayInvalidMnemonic && (
|
||||
<Typography fontWeight="fontWeightBold" style={{ color: 'red' }}>
|
||||
Mnemonic validation failed. Please enter a valid BIP 39 seed phrase.
|
||||
</Typography>
|
||||
)}
|
||||
<TextField
|
||||
variant="outlined"
|
||||
fullWidth
|
||||
|
|
Loading…
Reference in New Issue