feat(perps): wire Perps Withdraw button to feature-flagged confirmation flow#28265
feat(perps): wire Perps Withdraw button to feature-flagged confirmation flow#28265
Conversation
|
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. |
ab2403a to
05a7571
Compare
05a7571 to
41bc7f9
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
...ons/components/developer/confirmations-developer-options/confirmations-developer-options.tsx
Show resolved
Hide resolved
41bc7f9 to
a61a712
Compare
michalconsensys
left a comment
There was a problem hiding this comment.
Looks good, just for reference the toast notifications will be added in this PR #28271
a61a712 to
add9390
Compare
…on flow Signed-off-by: dan437 <80175477+dan437@users.noreply.github.com>
Signed-off-by: dan437 <80175477+dan437@users.noreply.github.com>
Signed-off-by: dan437 <80175477+dan437@users.noreply.github.com>
add9390 to
a80e4b7
Compare
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
Tag selection rationale:
SmokeTrade was considered but not selected as the changes are specifically to the Perps withdraw confirmation flow, not the broader trade/swap/bridge flows. The SmokePerps + SmokeConfirmations + SmokeWalletPlatform combination provides adequate coverage. Performance Test Selection: |
The committed fixture schema is out of date. To update, comment: |
|






Description
Adds the full Perps Withdraw "to any token" feature, allowing users to withdraw Perps funds to any supported token via MetaMask Pay and the Relay bridge, instead of only withdrawing native USDC through HyperLiquid's 5-minute bridge.
Changelog
CHANGELOG entry: Added feature-flagged "withdraw to any token" flow for Perps, allowing users to withdraw Perps funds to any supported token via MetaMask Pay
Related issues
Fixes: https://consensyssoftware.atlassian.net/browse/CONF-1121
Manual testing steps
Screenshots/Recordings
Before
N/A
After
N/A
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Medium Risk
Changes withdraw initiation and transaction-batch creation (including network selection) in a user-funds flow, which can affect confirmations and activity history if the flag/config is wrong.
Overview
Updates Perps withdraw to be feature-flagged: when
selectPayQuoteConfig(..., 'perpsWithdraw').enabledis true, the Withdraw button now starts a new confirmation-based flow instead of navigating to the legacy withdraw screen.Introduces
usePerpsWithdrawConfirmation, which navigates to theCustomAmountconfirmation UI on the Perps stack and creates a dummy Arbitrum ERC-20 transfer batch typed asTransactionType.perpsWithdrawto drive the MetaMask Pay experience; Developer Options “Perps Withdraw” is rewired to this hook. Tests are updated/added to cover the flag branching, success/error handling, and the new transaction-batch behavior.Written by Cursor Bugbot for commit a80e4b7. This will update automatically on new commits. Configure here.