Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connect wallet with ledger live app #31

Merged
merged 7 commits into from
Nov 20, 2023
Merged

Conversation

kkosiorowska
Copy link
Contributor

@kkosiorowska kkosiorowska commented Nov 15, 2023

This PR adds the possibility to request access to a user’s account in the ledger live app. To do this, we need to extend the permissions in the manifest file - account.request. When the user has selected an account, let's save it in a special context for global access.

What has been done

  • Create an environment variable to switch the test network to the regular one - VITE_USE_TESTNET
  • Create a context for an account to have global access to it.
  • Change the style for a button - Styles are still not perfect but let's correct that in a separate task.
  • Update global styles
  • Add functions to format the token amount

UI

Screenshot 2023-11-17 at 13 04 06

@kkosiorowska kkosiorowska self-assigned this Nov 15, 2023
@kkosiorowska kkosiorowska force-pushed the init-components branch 2 times, most recently from 0c3155e to 14a1bb0 Compare November 16, 2023 19:23
To connect accounts with the dApp let's use the `useRequestAccount` hook from the WALLET API for this.  Also, we should store the account data in context to have global access to it.
We should correctly display user balances. Let us use the formatting functions and display the balance correctly by region.
- Ad comment about tooltip
- Add different style when an account is not defined
@kkosiorowska kkosiorowska marked this pull request as ready for review November 17, 2023 12:31
@r-czajkowski r-czajkowski merged commit 42fd0c0 into init-components Nov 20, 2023
4 checks passed
@r-czajkowski r-czajkowski deleted the connect-wallet branch November 20, 2023 11:05
@r-czajkowski r-czajkowski restored the connect-wallet branch November 20, 2023 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants