feat(components): route web-redirect categories + shared provider plumbing (ORC-6514)#386
Conversation
Generated by 🚫 Danger Swift against 01d6bca |
|
Generated by 🚫 Danger Kotlin against 01d6bca |
There was a problem hiding this comment.
✅ No issues found
About Unblocked
Unblocked has been set up to automatically review your team's pull requests to identify genuine bugs and issues.
📖 Documentation — Learn more in our docs.
💬 Ask questions — Mention @unblocked to request a review or summary, or ask follow-up questions.
👍 Give feedback — React to comments with 👍 or 👎 to help us improve.
⚙️ Customize — Adjust settings in your preferences.
bad5150 to
92f5e9c
Compare
…ssifier (ORC-6514) Show the error screen on a native-UI start reject instead of swallowing it.
01d6bca to
630a84e
Compare
Summary
Foundational cleanup of the deferred #376-review items — no new payment methods. This is the "verify" PR in the APM-unification stack (after Google Pay #376, Apple Pay #374, PayPal #385). It hardens how the prebuilt method list routes a tapped method and stops a native-UI failure from stranding the shopper.
The original ORC-6514 bank/QR/raw-data provider plumbing is not here — it moves into the PRs that actually consume it (#387 banks, #389 forms, #390 QR). On the reset stack those screens don't exist yet, so building the plumbing now would be dead code routing nowhere.
What changed
start()rejects (e.g. an unavailable method the SDK still lists),MethodSelectionScreenused to swallow the error and leave the shopper on the processing spinner with no way back. It now navigates to the error screen.MethodSelectionScreenroutes through the sharedrouteMethodSelection(the same mapusePrimerPaymentMethoduses), with an exhaustiveness check. A newkindcan no longer be wired into the hook and silently missed by the screen.routeMethodSelection(type, categories)takesPrimerPaymentMethodManagerCategoryName[]instead ofstring[].usePrimerPaymentMethodreturn union keeps three distinct variants with no shared base. They genuinely diverge (unsupportedisisAvailableonly;cardhas no outcome/cancel;nativeUihas both pluscancel), so a base would force optional fields and weaken the discriminated union. Revisit only if it fragments at 6+ variants.Routing behavior is otherwise unchanged — PAYMENT_CARD and other RAW_DATA methods still open the card form (the non-card RAW_DATA split lands in #389).
Not a breaking change
Internal only — no public hook, component, or type is added, removed, or changed.
Base
ov/feat/ORC-6513-native-ui-payments(#385).Jira
ORC-6514
Test plan
yarn typecheck/yarn lint— cleanyarn jest— green bar the known tr_TR localization flake; newrouteMethodSelection.test.ts