Skip to content

[Due for payment 2026-07-13] Migrate ConnectToQuickbooksOnlineFlow and ConnectToXeroFlow to @react-navigation modal screens #90476

Description

@mountiny

Context

This is a sub-issue of #53493 (Replace modal screens with modals from @react-navigation).

For full background and migration approach, see the triage analysis comment and the sub-issue breakdown comment.

Problem

ConnectToQuickbooksOnlineFlow and ConnectToXeroFlow are modal-based accounting integration flows that animate in from right-to-left like screens but use react-native-modal. Their platform-specific implementation (WebView on native, external link on web) and OAuth branching make this a complex migration.

Migration approach (Group 4 — Complex)

  • Files:
    • src/components/ConnectToQuickbooksOnlineFlow/
    • src/components/ConnectToXeroFlow/
  • Used by: Both are triggered only via getAccountingIntegrationDataAccountingContext using an imperative startIntegrationFlow call.
  • Complexity:
    • Platform-specific: web uses an external link, native uses a WebView modal.
    • Xero has 2FA branching logic.
    • QBO disables taxes on mount as a side effect.
    • Imperatively triggered via startIntegrationFlow, decoupled from the component tree.

Suggested migration approach

  1. Create dedicated navigation pages: QBOConnectPage and XeroConnectPage.
  2. Replace the imperative startIntegrationFlow trigger with a navigate(ROUTES.QBO_CONNECT) / navigate(ROUTES.XERO_CONNECT) call.
  3. Move the platform-specific WebView/external link logic into the new pages.
  4. Handle the QBO tax-disabling side effect in a useEffect in the new page.
  5. Decouple from AccountingContext where possible.
  6. Test the full OAuth connection flow for both QBO and Xero on iOS, Android, and web.

Reference

Issue OwnerCurrent Issue Owner: @mallenexpensify

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionDailyKSv2Task

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions