XLabs / portal-bridge-ui

Portal Bridge UI
https://www.portalbridge.com/
25 stars 35 forks source link

[bug] "Switch to manual claim" option should not be shown on Redeem screen if destination address was entered manually #985

Closed tsadovska closed 2 months ago

tsadovska commented 2 months ago

Is there an existing issue for this?

Current Behavior

"Switch to manual claim" option is shown on Redeem screen.

Screenshot 2024-08-05 at 17 46 56

Transaction fails after clicking on "Claim" button.

TypeError: Cannot read properties of undefined (reading 'publicKey')
    at postVaa (pb-index-D87dar2w.js:516:73387)
    at RelayRoute.redeem (pb-index-D87dar2w.js:519:103780)
    at Operator.redeem (pb-index-D87dar2w.js:519:94496)
    at Object.Nr [as onClick] (pb-index-D87dar2w.js:746:1347)
    at gr (pb-index-D87dar2w.js:743:25243)
    at Object.Nb (pb-index-D87dar2w.js:43:10486)
    at Tb (pb-index-D87dar2w.js:43:10655)
    at Ub (pb-index-D87dar2w.js:43:10721)
    at nf (pb-index-D87dar2w.js:43:33594)
    at se$1 (pb-index-D87dar2w.js:43:34071)

Expected Behavior

"Switch to manual claim" option should not be shown on Redeem screen.

Steps To Reproduce

  1. Open https://preview.portalbridge.com/859350d189/
  2. Prepare to send 5 FTM from Fantom (MetaMask) to Solana (Phantom, address entered manually)
  3. Click on "Approve and proceed with transaction" button
  4. Check if "Switch to manual claim" option is shown in Step 2

Environment

- OS: macOS Sonoma 14.5
- Wallet: MetaMask, Phantom
- Browser: Google Chrome Version 127.0.6533.89 (Official Build) (arm64)

Anything else?

No response

sebastianscatularo commented 2 months ago

should be addressed at https://github.com/wormhole-foundation/wormhole-connect/pull/2322 related to https://github.com/XLabs/portal-bridge-ui/issues/980

tsadovska commented 2 months ago

Re-checked on https://preview.portalbridge.com/859350d189/ [Mainnet].

"Switch to manual claim" option is displayed with following scenario:

  1. Select Fantom as source chain and connect MetaMask wallet
  2. Select Solana as destination chain and enter valid Solana account manually
  3. Select token and enter Amount, 5 FTM
  4. Enable "Native gas" section and change slider position
  5. Click on "Approve and proceed with transaction" button and approve MetaMask notification
  6. Copy Link and close the Tab
  7. Paste Link in new Tab
  8. Check if "Switch to manual claim" option is displayed in "Send to" section

Please use this link to view the recording.

sebastianscatularo commented 2 months ago

@tsadovska that's expected, you can see the connect wallet button at bottom, it does not count as a bug

tsadovska commented 2 months ago

Thank you! Scenario from the Description is no longer reproducible. "Switch to manual claim" option is not shown in "Send to" section when user enters destination address manually.

Ticket is closed.