Skip to content

Commit

Permalink
wallet-ext: import mnemonic inputs copy paste improvement (MystenLabs…
Browse files Browse the repository at this point in the history
…#9714)

## Description 

* when pasting the mnemonic split it by any non word character `\W` to
avoid cases when words are split by any other characters that space
* fixes the case when copy-pasting the mnemonic from backup page
  • Loading branch information
pchrysochoidis authored Mar 23, 2023
1 parent 91d176e commit 80a5023
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export default function StepOne({ next, data, mode }: StepProps) {
);
const words = inputText
.trim()
.split(' ')
.split(/\W/)
.map((aWord) =>
aWord.trim()
)
Expand Down

0 comments on commit 80a5023

Please sign in to comment.