Skip to content

chore: consolidate navigation style - confirmations team#25875

Merged
asalsys merged 5 commits into
mainfrom
chore/consolidate-navigation-style-confirmations
Feb 20, 2026
Merged

chore: consolidate navigation style - confirmations team#25875
asalsys merged 5 commits into
mainfrom
chore/consolidate-navigation-style-confirmations

Conversation

@asalsys

@asalsys asalsys commented Feb 10, 2026

Copy link
Copy Markdown
Contributor

Description

This PR consolidates navigation styles across the codebase by replacing inline navigationOptions style definitions with the shared getNavigationOptionsTitle utility function.

Reason for change:

  • Preparing the codebase for the upgrade to React Navigation v6
  • Navigation header styles were defined inconsistently across components using the legacy navigationOptions pattern
  • Centralizing navigation options will make the migration to React Navigation v6's new API smoother and reduce the scope of changes required during the upgrade

Solution:

  • Replaced inline style definitions with the centralized getNavigationOptionsTitle function from app/components/UI/Navbar
  • This ensures consistent navigation header styling across the app and simplifies the upcoming React Navigation v6 migration

Changelog

CHANGELOG entry: null

Related issues

Fixes: #23765 Part of React Navigation v6 upgrade preparation (split from original PR for easier code review by team)

Manual testing steps

Feature: Navigation header consistency

Scenario: User navigates to screens affected by this PR
Given the app is running

When user navigates to any screen modified in this PR
Then the navigation header should display correctly with proper title styling
And the back button should function as expected

Screenshots/Recordings

Before

N/A - No visual changes

After

N/A - No visual changes

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.](chore: consolidate navigation style - ux team #25877)

Note

Medium Risk
Touches navigation behavior in confirmation and account-switch flows, so small route/stack differences could change where users land or how modals close. Changes are localized and covered by updated tests.

Overview
Consolidates confirmations-related navigation by replacing the nested navigation.navigate(Routes.WALLET.HOME, { ...Routes.WALLET_VIEW... }) pattern with a direct navigation.navigate(Routes.WALLET_VIEW).

This updates the switch-account-type modal’s close behavior (AccountNetworkRow), the post-confirm flow for TransactionType.musdConversion (useTransactionConfirm), and the “reject then go home” path (useConfirmActions), with associated test expectation updates.

Written by Cursor Bugbot for commit 0d8b7de. This will update automatically on new commits. Configure here.

@asalsys asalsys self-assigned this Feb 10, 2026
@asalsys asalsys added the team-mobile-platform Mobile Platform team label Feb 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

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.

@asalsys asalsys force-pushed the chore/consolidate-navigation-style-confirmations branch from 0f2f6aa to eef070e Compare February 12, 2026 15:32
… navigation

Update test to match implementation that navigates directly to
Routes.WEBVIEW.SIMPLE instead of Routes.WEBVIEW.MAIN with nested screen.
@asalsys asalsys marked this pull request as ready for review February 16, 2026 16:50
@asalsys asalsys requested a review from a team as a code owner February 16, 2026 16:50
@asalsys asalsys enabled auto-merge February 16, 2026 16:50

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Comment thread app/components/Views/confirmations/hooks/transactions/useTransactionConfirm.ts Outdated

@OGPoyraz OGPoyraz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, hoping those e2e failures are not related with this PR.

@github-actions

Copy link
Copy Markdown
Contributor

🔍 Smart E2E Test Selection

  • Selected E2E tags: SmokeConfirmations, SmokePerps, SmokeAccounts
  • Selected Performance tags: None (no tests recommended)
  • Risk Level: medium
  • AI Confidence: 85%
click to see 🤖 AI reasoning details

E2E Test Selection:
The changes simplify navigation patterns in the confirmations flow, replacing nested route navigation (Routes.WALLET.HOME → Routes.WALLET.TAB_STACK_FLOW → Routes.WALLET_VIEW) with direct navigation (Routes.WALLET_VIEW).

Three files are modified:

  1. account-network-row.tsx: Affects account switching within confirmations modal - requires SmokeAccounts
  2. useTransactionConfirm.ts: Affects musdConversion transaction type navigation - this is related to Earn/Perps flows, requires SmokePerps
  3. useConfirmActions.ts: Core confirmation actions hook used by footer, flat-nav-header, ledger-sign-modal, and various confirmation info components - requires SmokeConfirmations

The useConfirmActions hook is imported by 20+ files including staking confirmations, approve, contract deployment, contract interaction, transfer, and predict-claim-info components. The useTransactionConfirm hook is used by PerpsOrderView.

While these are simplifications that should work the same way, navigation changes can affect user flows, so medium risk is appropriate. Unit tests have been updated to reflect the new navigation pattern.

Performance Test Selection:
The changes are purely navigation simplifications that don't affect rendering performance, data loading, or UI responsiveness. The navigation pattern change (from nested routes to direct navigation) should have no measurable performance impact as it's just a different way to achieve the same navigation result.

View GitHub Actions results

@sonarqubecloud

Copy link
Copy Markdown

@asalsys asalsys added this pull request to the merge queue Feb 20, 2026
Merged via the queue into main with commit 6f917da Feb 20, 2026
93 checks passed
@asalsys asalsys deleted the chore/consolidate-navigation-style-confirmations branch February 20, 2026 20:37
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 20, 2026
@metamaskbot metamaskbot added the release-7.68.0 Issue or pull request that will be included in release 7.68.0 label Feb 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-7.68.0 Issue or pull request that will be included in release 7.68.0 size-S team-mobile-platform Mobile Platform team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[NAV UPGRADE - 4] Consolidate navigation API call style

3 participants