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

feat: SOL-80 transaction details #29323

Open
wants to merge 45 commits into
base: main
Choose a base branch
from
Open

Conversation

zone-live
Copy link
Contributor

@zone-live zone-live commented Dec 18, 2024

Description

This PR adds the new transaction details modal for the non-evm networks, BTC and SOL.

Screenshot 2024-12-18 at 14 42 18

Screen.Recording.2024-12-17.at.12.27.40.mov

Related issues

Fixes: https://consensyssoftware.atlassian.net/browse/SOL-80

Manual testing steps

Testing this is a bit extensive, but if you still want to give it a go these are the steps:

  1. Checkout this branch and run yarn
  2. Update the file shared/lib/accounts/solana-wallet-snap.ts with:
    export const SOLANA_WALLET_SNAP_ID: SnapId = 'local:http://localhost:8080' as SnapId;
  3. Update the filtering code in MultichainTransactionsController under node modules to return transactions for devnet, currently only returns for mainnet. It's under node_modules/@metamask/multichain-transactions-controller/dist/MultichainTransactionsController.mjs and node_modules/@metamask/multichain-transactions-controller/dist/MultichainTransactionsController.cjs with:
MultichainNetwork.SolanaDevnet
instead of
MultichainNetwork.Solana

  1. Run the extension with yarn start:flask
  2. Run the Snap: https://github.com/MetaMask/snap-solana-wallet
    • Clone it
    • Run yarn
    • Run yarn start
  3. Go to http://localhost:3000/
  4. Install the Snap
  5. In the extension, go to the Settings > Experimental > Enable Solana account
  6. Create a Solana account from the account-list menu
  7. Fund the new Solana account with some SOL, use a faucet like https://faucet.solana.com/
  8. the initial Tx with funds from the faucet will display in the activity tab
  9. Click in it and you will see the Tx details modal
  10. Thats it! 🎉

Screenshots/Recordings

Before

Didn't exist.

After

Screenshot 2024-12-18 at 14 42 18

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@metamaskbot metamaskbot added the INVALID-PR-TEMPLATE PR's body doesn't match template label Dec 18, 2024
@metamaskbot metamaskbot removed the INVALID-PR-TEMPLATE PR's body doesn't match template label Dec 18, 2024
@zone-live zone-live marked this pull request as ready for review January 27, 2025 14:04
aganglada
aganglada previously approved these changes Jan 28, 2025
…ain-transaction-details-modal.test.tsx

Co-authored-by: Charly Chevalier <[email protected]>
…ain-transaction-details-modal.test.tsx

Co-authored-by: Charly Chevalier <[email protected]>
@metamaskbot
Copy link
Collaborator

Builds ready [d6e121f]
Page Load Metrics (1850 ± 89 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint37921971794363174
domContentLoaded14682183182017685
load14742204185018589
domInteractive268338157
backgroundConnect96631178
firstReactRender166830189
getState462242211
initialActions00000
loadScripts10631655135114570
setupStore86317168
uiStartup17022461211519593
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@metamaskbot
Copy link
Collaborator

Builds ready [c0116e2]
Page Load Metrics (1760 ± 110 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint146822851760233112
domContentLoaded145422771736231111
load147122851760229110
domInteractive197332115
backgroundConnect96924178
firstReactRender16104442813
getState56617209
initialActions00000
loadScripts10361621124918087
setupStore86320189
uiStartup164826172079262126
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@metamaskbot
Copy link
Collaborator

Builds ready [d6d7a16]
Page Load Metrics (1613 ± 64 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint14291925161413464
domContentLoaded14211869158812661
load14291918161313464
domInteractive2299472311
backgroundConnect883292210
firstReactRender1574362411
getState55013136
initialActions00000
loadScripts10051404114511455
setupStore85816178
uiStartup16022107183313967
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@zone-live zone-live requested a review from a team as a code owner January 29, 2025 17:32
@zone-live
Copy link
Contributor Author

Screenshot 2025-01-29 at 15 42 04

@metamaskbot
Copy link
Collaborator

Builds ready [3403374]
Page Load Metrics (1800 ± 93 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint28222981734389187
domContentLoaded15352285176419594
load15442291180019493
domInteractive2692442211
backgroundConnect1090392914
firstReactRender1699432713
getState56416157
initialActions00000
loadScripts11131723130417584
setupStore991332613
uiStartup177026372107277133
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

aganglada
aganglada previously approved these changes Jan 30, 2025
@metamaskbot
Copy link
Collaborator

Builds ready [6996ee1]
Page Load Metrics (1539 ± 44 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint1382176815388641
domContentLoaded1377170815218139
load1381177115399144
domInteractive2394392110
backgroundConnect86621188
firstReactRender1468292010
getState4479126
initialActions01000
loadScripts972128711037536
setupStore757222210
uiStartup1553196417349545
Bundle size diffs
  • background: 0 Bytes (0.00%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-sol PRs from the Solana snap team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants