HomePhabricator

[Cashtab] Create standalone component for Etokens

Description

[Cashtab] Create standalone component for Etokens

Summary:
T3364

The legacy access point for the etokens screen has always been a bit unintuitive so this diff decouples it from the Home component and establishes it as a standalone component accessed from the bottom navigation menu. This will also make it easier to update eToken related UI in the future without getting tied up amongst TxHistory code.

The removal of the original Etokens tab on the Home component meant there is no reason for the active tab switching menu (since it's just Tx History now by itself), hence removing the tab altogether in Home.js.

This is updated for the extension as well.

Note: We should announce this adjustment via twitter once landed as it may not be obvious to users.

image.png (854×557 px, 88 KB)

image.png (863×567 px, 91 KB)

Separate future diffs will enhance the Send component to incorporate the sending of etokens on the same page.

Test Plan:

  • npm test
  • npm start
  • Click on the new Etokens component, pick an existing token in the wallet and verify it sends successfully to a designated ecash address. Then ensure the specific token balances are updated on the sending and receiving wallets
  • Switch to another wallet, and visit both the Home and the new Etokens components
  • Create a new token via the new Etokens component and ensure it is successfully minted to the active wallet
  • Create a fresh new unfunded wallet and ensure a) the onboarding message and styling on Home.js remains unchanged and b) navigating to the new Etokens component will result in the "Tokens sent to your eToken address will appear here" message being rendered
  • Fund this newly created wallet and ensure the onboarding message is no longer rendered on the Home.js screen
  • Create a new token on this newly created wallet and ensure the onboarding token message is no longer rendered on the Etokens.js screen
  • Switch between 3-4 wallets and ensure the eTokens list accurately reflects the tokens held in the active wallet
  • npm run extension and refresh the local browser instance
  • Ensure the new Etokens component is present in the extension and the original location in Home.js has been deprecated
  • Publish this to a staging site (e.g. netlify) and ensure the Etokens icon on the bottom menu is of adequate size for fat fingers on mobile devices
  • Open a fresh new incognito browser session and visit http://localhost:3000/#/etokens and ensure the wallet creation screen is rendered.
  • Create a new wallet in this new incognito browser session and ensure http://localhost:3000/#/etokens now takes user to the etokens screen.

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Subscribers: Kronkmeister

Differential Revision: https://reviews.bitcoinabc.org/D14998

Details

Provenance
emackAuthored on Dec 16 2023, 02:38
emackPushed on Dec 29 2023, 22:07
Reviewer
Restricted Project
Differential Revision
D14998: [Cashtab] Create standalone component for Etokens
Parents
rABC3adddade9b38: [electrum] push release notification for 5.2.11
Branches
Unknown
Tags
Unknown