refactor(toast): migrate web3auth toasts to the design system - #34818
refactor(toast): migrate web3auth toasts to the design system#34818amandaye0h wants to merge 1 commit into
Conversation
Replace toastRef.showToast with the design-system toast() API so SRP import and reveal flows use the same Toaster as the rest of the app. Co-authored-by: Cursor <cursoragent@cursor.com>
|
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. |
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
The functional behavior is unchanged — only the toast implementation is swapped. However, if the new Tags selected:
Tags NOT selected:
The Performance Test Selection: |
|



Description
The component-library
Toastis deprecated in favor oftoast()from@metamask/design-system-react-native. SRP import (onboarding and multi-SRP) and reveal-credential still usedtoastRef.showToast, so they rendered the old toast surface and needed ToastContext wiring.This PR switches those call sites to the design-system
toast()API (already mounted via<Toaster />in App). Invalid SRP length usesToastSeverity.Danger, successful wallet import usesToastSeverity.Success, and copy-to-clipboard uses the same title-only toast as other account copy flows. Tests mocktoastinstead of wrappingToastContext, and component view tests stubtoastintestSetupView.jsso they do not throw without a mounted Toaster.Changelog
CHANGELOG entry: Updated SRP import and reveal toasts to the MetaMask design system
Related issues
Refs: No tracking issue; continues the design-system toast migration for SRP import and reveal flows
Manual testing steps
Screenshots/Recordings
Before
N/A — toast copy is unchanged; only the toast surface/API migrated.
After
N/A — toast copy is unchanged; only the toast surface/API migrated.
Pre-merge author checklist
Performance checks (if applicable)
trace()for usage andaddTokenfor an exampleFor performance guidelines and tooling, see the Performance Guide.
Pre-merge reviewer checklist
Made with Cursor