Context
This issue tracks part 1 of the ManualSubmitToDestinationVisible work (submit → destination visible telemetry and performance). It corresponds to the refactor delivered in PR #87963.
Goal
Prepare and instrument the submit-to-destination flow without changing intended product behavior: consolidate orchestration and telemetry so follow-up changes (dismiss-first fast paths) can land safely.
What shipped in #87963
SubmitExpenseOrchestrator — Extracts the submit decision tree (including GPS permission handling and telemetry lifecycle) from IOURequestStepConfirmation into a dedicated render-prop component. Only the default slow path is active in this PR.
- Centralized telemetry in
submitFollowUpAction.ts — Single place for tracking session management (startTracking, setFastPath, addOptimization, cancelTracking), follow-up action state, and structured __DEV__ logging (e.g. [SubmitExpense] request_money_manual -> navigate_to_search (none) 105ms [slow path]).
isTracking() — Replaces scattered getSpan() checks in navigation helpers and IOU actions where appropriate.
useEndSubmitNavigationSpans — Shared hook for span-ending logic previously duplicated in SearchPageNarrow and SearchPageWide.
- Bugfix — Clear
trackingState when cancelSubmitFollowUpActionSpan runs so telemetry state stays consistent.
Out of scope (follow-up)
Acceptance criteria
- All expense submit flows behave as before (including distance + GPS permission).
- Telemetry lifecycle is centralized; in dev, console shows structured
[SubmitExpense] lines after submit.
- No regressions in navigation after expense creation (Search, Inbox report, RHP, modal dismiss paths).
Links
Issue Owner
Current Issue Owner: @JakubKorytko
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~022044561206615367758
- Upwork Job ID: 2044561206615367758
- Last Price Increase: 2026-04-15
Context
This issue tracks part 1 of the ManualSubmitToDestinationVisible work (submit → destination visible telemetry and performance). It corresponds to the refactor delivered in PR #87963.
Goal
Prepare and instrument the submit-to-destination flow without changing intended product behavior: consolidate orchestration and telemetry so follow-up changes (dismiss-first fast paths) can land safely.
What shipped in #87963
SubmitExpenseOrchestrator— Extracts the submit decision tree (including GPS permission handling and telemetry lifecycle) fromIOURequestStepConfirmationinto a dedicated render-prop component. Only the default slow path is active in this PR.submitFollowUpAction.ts— Single place for tracking session management (startTracking,setFastPath,addOptimization,cancelTracking), follow-up action state, and structured__DEV__logging (e.g.[SubmitExpense] request_money_manual -> navigate_to_search (none) 105ms [slow path]).isTracking()— Replaces scatteredgetSpan()checks in navigation helpers and IOU actions where appropriate.useEndSubmitNavigationSpans— Shared hook for span-ending logic previously duplicated inSearchPageNarrowandSearchPageWide.trackingStatewhencancelSubmitFollowUpActionSpanruns so telemetry state stays consistent.Out of scope (follow-up)
[fast path]labeling are intentionally deferred to PR #87768 (HOLD on [Performance] Refactor: Extract SubmitExpenseOrchestrator + centralize telemetry #87963).Acceptance criteria
[SubmitExpense]lines after submit.Links
Issue Owner
Current Issue Owner: @JakubKorytkoUpwork Automation - Do Not Edit