Back to components
Payments component
Payment Status Screen
Post-STK-push polling screen with "Check your phone" UX, 5s cadence, 5-minute ceiling.
Install
What it does
- Foreground 5-second polling via use-payment-status hook
- 5-minute hard ceiling — escapes stuck polls
- Pauses when the app is backgrounded
- Terminal-state branching: completed / failed / cancelled / expired
- Cancel button while polling
When to use
Use it
Immediately after starting a mobile money charge — show this until status resolves.
Skip it
Card payments (Stripe gives the result inline, no polling needed).
Files & routes added
- components/payments/payment-status-screen.tsx