feat(support): adopt support consent flow in RewardsVipRefereeView and LinkedOffDeviceAccountsSheet - #33520
Conversation
Adds the support consent sheet, hook, util, route, and ownerless call sites (Compliance context, ReviewModal, ErrorBoundary, Homepage MoreSection) that team-owned PRs will stack on. Co-authored-by: Cursor <cursoragent@cursor.com>
Adds a real assertion inside the submit-feedback waitFor and restores spies after each test, per flaky-test-detection bot suggestions on PR #33424. Co-authored-by: Cursor <cursoragent@cursor.com>
The prior en.json checkout came from a stale branch and clobbered translation keys added to main since, breaking unrelated unit tests in CI. Re-applies only the support_consent strings on top of main's current en.json. Co-authored-by: Cursor <cursoragent@cursor.com>
…et prop for support contact This update modifies the ErrorBoundary component to eliminate the use of the useSupportConsent hook, which was causing issues when rendering at the root boundary outside of NavigationProvider. Instead, it now utilizes an openTicket prop to handle support contact actions. Additionally, the corresponding tests have been updated to reflect this change, ensuring that the new behavior is correctly validated. The support URL handling in the navigateToSupportConsent function has also been adjusted to open the raw base URL without appending device details, aligning with user consent preferences.
…ions Addresses Copilot review comments on PR #33424: OpenSupportUrl now allows Promise<void> to match async openers like Linking.openURL, and onConfirm/onReject await open() in a try/catch so a rejected opener can't surface as an unhandled promise rejection. Co-authored-by: Cursor <cursoragent@cursor.com>
…d LinkedOffDeviceAccountsSheet 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. |
…ipRefereeView and LinkedOffDeviceAccountsSheet Extracts the beta-build support URL check into a shared getBetaSupportUrl() helper so the consent-flow branch (previously unreachable under Jest, since ///: ONLY_INCLUDE_IF(beta) code fences are only stripped by Metro at build time) can be exercised via module mocking in both call sites. Adds test cases covering: the non-beta branch routing through openSupportWithConsent with the correct URL, the opener callback correctly navigating to the webview, and both branches of the beta/non-beta condition. Co-authored-by: Cursor <cursoragent@cursor.com>
… with the consent sheet flow Co-authored-by: Cursor cursoragent@cursor.com
…t flow Lets call sites record their support opened analytics event when the user actually opens support (on consent confirm/reject), instead of when the consent sheet is merely shown. Co-authored-by: Cursor cursoragent@cursor.com
…er glue Trim RewardsVipRefereeView and LinkedOffDeviceAccountsSheet tests to assert the consent sheet opens with the expected base URL, plus one opener-invoke test per call site for the newly-added opener wiring. Confirm/reject mechanics are already covered by core PR #33424. Co-authored-by: Cursor <cursoragent@cursor.com>
…opens Bugbot flagged that onOpenSupport fired synchronously on confirm/reject, before the async open() call resolved, so analytics could record "support opened" even when opening later failed. onOpenSupport is now threaded into confirmSupportConsent/rejectSupportConsent and fired only after open() succeeds. Co-authored-by: Cursor <cursoragent@cursor.com>
…ask/design-system-react-native components
PR template — items to address before "Ready for review"Warnings — informational, address before merging:
See docs/readme/ready-for-review.md for the full Definition of Ready for Review. |
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.
Reviewed by Cursor Bugbot for commit cefb2e0. Configure here.
Move get-help analytics tracking into the support-consent open callback so the event fires only when support is actually opened.
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection: Performance Test Selection: |
|




Description
Adopts the support-consent mechanism introduced by the core PR (#33424) in the two
@MetaMask/rewards-owned "Contact support" call sites:RewardsVipRefereeView: the priority support webview link now routes throughuseSupportConsent().openSupportWithConsent(falls back to the direct beta Intercom URL when the beta build flag is set).LinkedOffDeviceAccountsSheet: the "let us know" contact-support action now routes through the same consent flow (same beta fallback behavior).This PR is part of a stacked PR series on top of the core support-consent PR (#33424,
MCWP-684-support-consent-core). Its base will be retargeted tomainonce #33424 merges.Changelog
CHANGELOG entry: null
(Behavior already described in the core PR, #33424.)
Related issues
Fixes: https://consensyssoftware.atlassian.net/browse/MCWP-684
Manual testing steps
Screenshots/Recordings
Before
N/A
After
N/A
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