Skip to content

Commit 0bb25b9

Browse files
authored
feat: TAT-1553 fix tp sl interface issues (MetaMask#19473)
<!-- 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** Resolved following issues with TP/SL bottom sheet on the `PerpsOrderView` (trade screen): - Android specific issue where keyboard would render on top of the tp/sl inputs preventing users from seeing the form. - When creating a limit order, if the limit price isn't set, we prevent the user from opening the TP/SL bottom sheet and display a short toast instructing them to first set a limit price <!-- 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? --> ## **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: added toast for limit orders when limit price isn't set and user tries to configure tp/sl CHANGELOG entry: fixed android specific issue where keyboard would render on top of the tp/sl form ## **Related issues** Fixes: [TAT-1553: Fix 3 issues in TP/SL interface](https://consensyssoftware.atlassian.net/browse/TAT-1553) ## **Manual testing steps** ```gherkin Feature: Fixing TP/SL bottom sheet issues Scenario: User can see the tp/sl form Given user is on Android and is placing a limit order When user clicks the tp/sl button and clicks on one of the tp or sl inputs Then on-screen keyboard does not block the form ``` ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** <!-- [screenshots/recordings] --> ### **After** https://github.com/user-attachments/assets/430ef84d-3aa2-49b7-a20d-fb19cf11adba <!-- [screenshots/recordings] --> ## **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 - [ ] 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.
1 parent f7ae467 commit 0bb25b9

6 files changed

Lines changed: 477 additions & 11 deletions

File tree

0 commit comments

Comments
 (0)