fix: use standard nano seed instead of ledger's implementation
This commit is contained in:
parent
44729f247a
commit
e29f1a8edc
|
@ -135,14 +135,16 @@ const RecentTransactions: FC<Props> = () => {
|
|||
<h2 className="text-2xl font-semibold text-gray-900 dark:text-purple-50">
|
||||
recent transactions
|
||||
</h2>
|
||||
<button
|
||||
onClick={() => {
|
||||
setRefectingHistory(true)
|
||||
refetchHistory()
|
||||
}}
|
||||
>
|
||||
<RefreshIcon className="h-6" />
|
||||
</button>
|
||||
{hasHistory && (
|
||||
<button
|
||||
onClick={() => {
|
||||
setRefectingHistory(true)
|
||||
refetchHistory()
|
||||
}}
|
||||
>
|
||||
<RefreshIcon className="h-6" />
|
||||
</button>
|
||||
)}
|
||||
</div>
|
||||
{initialLoadingHistory || refetchingHistory ? (
|
||||
<ul className="flex flex-col w-full overflow-auto px-0.5 pb-0.5 gap-2">
|
||||
|
|
|
@ -31,7 +31,10 @@ const useSetupSeed = (skip?: boolean) => {
|
|||
wallet.generateLegacy(),
|
||||
registerBiometrics(),
|
||||
])
|
||||
const { address, publicKey } = accountAtIndex(generatedSeed, 0)
|
||||
const { address, publicKey } = accountAtIndex(
|
||||
generatedSeed.toLocaleUpperCase(),
|
||||
0
|
||||
)
|
||||
|
||||
const account: AccountInfoCache = {
|
||||
frontier: null,
|
||||
|
@ -42,7 +45,7 @@ const useSetupSeed = (skip?: boolean) => {
|
|||
publicKey,
|
||||
precomputedWork: null,
|
||||
}
|
||||
setSeed({ seed: generatedSeed, mnemonic })
|
||||
setSeed({ seed: generatedSeed.toLocaleUpperCase(), mnemonic })
|
||||
setAccount(account)
|
||||
addAccount(0, account)
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { wallet } from 'nanocurrency-web'
|
||||
|
||||
const accountAtIndex = (seed: string, index: number) =>
|
||||
wallet.accounts(seed, index, index)[0]
|
||||
wallet.legacyAccounts(seed, index, index)[0]
|
||||
|
||||
export default accountAtIndex
|
||||
|
|
Reference in a new issue