-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
chore(runway): cherry-pick fix: cp-7.58.0 Fix swipe gesture navigation in send flow amount page for Android #21605
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…n in send flow amount page for Android (#21518) <!-- Please submit this PR as a draft initially. Do not mark it as "Ready for review" until the template has been completely filled out, and PR status checks have passed at least once. --> ## **Description** <!-- Write a short description of the changes included in this pull request, also include relevant motivation and context. Have in mind the following questions: 1. What is the reason for the change? 2. What is the improvement/solution? --> This PR aims to fix Android issue where amount keyboard appears behind the gestures navigation. ## **Changelog** <!-- If this PR is not End-User-Facing and should not show up in the CHANGELOG, you can choose to either: 1. Write `CHANGELOG entry: null` 2. Label with `no-changelog` If this PR is End-User-Facing, please write a short User-Facing description in the past tense like: `CHANGELOG entry: Added a new tab for users to see their NFTs` `CHANGELOG entry: Fixed a bug that was causing some NFTs to flicker` (This helps the Release Engineer do their job more quickly and accurately) --> CHANGELOG entry: Fix send flow keyboard to not appear behind gesture navigation in mobile ## **Related issues** Fixes: #21383 ## **Manual testing steps** ```gherkin Feature: my feature name Scenario: user [verb for user action] Given [describe expected initial app state] When user [verb for user action] Then [describe expected outcome] ``` ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** Android: <img width="689" height="1416" alt="before android" src="https://github.com/user-attachments/assets/5079c87b-a100-4f1a-bd99-4d325a7073b2" /> iOS: <img width="696" height="1384" alt="before ios" src="https://github.com/user-attachments/assets/b116d4e0-11f6-41a4-a16f-8873b59f03b8" /> ### **After** Android: <img width="711" height="1460" alt="after android" src="https://github.com/user-attachments/assets/8cc6bc27-38fe-4656-a681-48785e8be1c6" /> iOS: <img width="696" height="1384" alt="after ios" src="https://github.com/user-attachments/assets/1500b133-db31-4264-b88f-60353b9f3434" /> ## **Pre-merge author checklist** - [X] I’ve followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile Coding Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md). - [X] I've completed the PR template to the best of my ability - [X] I’ve included tests if applicable - [X] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [X] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **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. <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Wraps the send amount screen in SafeAreaView and applies platform-specific padding/margins to keep the amount keyboard clear of gesture navigation. > > - **Send Amount Screen (`amount.tsx`, `amount.styles.ts`)** > - Replace `ScrollView` with `SafeAreaView` using platform-specific `edges` to respect safe areas. > - Container now uses `flex: 1`; removes `minHeight: '100%'`. > - Adds platform check via `Device.isIos()` for safe area handling. > - **Edit Amount Keyboard Styles (`edit-amount-keyboard.styles.ts`)** > - Adjust `wrapper` spacing: `paddingBottom` now platform-specific and `marginBottom` set to `0` (replacing vertical margin). > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit 44a493b. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
| /> | ||
| </View> | ||
| </ScrollView> | ||
| </SafeAreaView> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: SafeAreaView Replaces ScrollView, Causing Content Cutoff
Replacing ScrollView with SafeAreaView removes scrolling functionality from the amount input screen. This can lead to content, such as NFT details, input fields, balance information, or the keyboard, being cut off and inaccessible when it exceeds screen height, especially on smaller devices or with larger accessibility text sizes.
|
Cal-L
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
No release label on PR. Adding release label release-7.58.0 on PR, as PR was cherry-picked in branch 7.58.0. |


Description
This PR aims to fix Android issue where amount keyboard appears behind
the gestures navigation.
Changelog
CHANGELOG entry: Fix send flow keyboard to not appear behind gesture
navigation in mobile
Related issues
Fixes: #21383
Manual testing steps
Screenshots/Recordings
Before
Android:

iOS:

After
Android:

iOS:

Pre-merge author checklist
Docs and MetaMask Mobile
Coding
Standards.
if applicable
guidelines).
Not required for external contributors.
Pre-merge reviewer checklist
app, test code being changed).
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.
Note
Adjust send amount screen layout to respect safe areas and avoid Android gesture navigation overlapping the keyboard.
ScrollViewwithSafeAreaViewand set platform-specificedgesto handle safe areas.containerstyle to useflex: 1(removeminHeight: '100%').edit-amount-keyboard.styles.ts):paddingBottomviaDevice.isIos() ? 20 : 12.marginBottom: 0.Devicefor platform checks and update related imports.Written by Cursor Bugbot for commit cdc6069. This will update automatically on new commits. Configure here.
aa8808c