-
-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: stable bottom padding for AwareScrollView (measure by targe…
…t) (#193) ## 📜 Description Stable bottom padding for `AwareScrollView`. Instead of touch coordinates measure layout by tag. ## 💡 Motivation and Context It's a simple showcase of a new functionality. Now we can consume `target` and calculate layout for understanding whether we need to scroll to focused TextInput or not. This example is just for paper architecture. PR for Fabric support will land later, since on Fabric we can not measure by tag (instead we need to use ShadowTree nodes). ## 📢 Changelog ### JS - measure layout instead of relying on touch; ## 🤔 How Has This Been Tested? Tested on: - iPhone 14 Pro (iOS 16.5, simulator); - Pixel 7 Pro (Android 13, real device). ## 📸 Screenshots (if appropriate): |Before|After| |------|-----| |<video src="https://github.com/kirillzyusko/react-native-keyboard-controller/assets/22820318/9b187a54-88f0-4b39-9530-c0e2d0138341">|<video src="https://github.com/kirillzyusko/react-native-keyboard-controller/assets/22820318/cb316406-fbcf-4632-af5e-46032e5f6f93">| |<img width="473" alt="image" src="https://github.com/kirillzyusko/react-native-keyboard-controller/assets/22820318/5934edc9-81f6-49a3-98d2-b48b08e69888">|<img width="474" alt="image" src="https://github.com/kirillzyusko/react-native-keyboard-controller/assets/22820318/85946f78-5ae0-497b-88f7-23449df5803b">| ## 📝 Checklist - [x] CI successfully passed
- Loading branch information
1 parent
c2a9776
commit 95a5376
Showing
2 changed files
with
36 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters