-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Fix money request amount input is partially visible after going back from currency selection page #34787
Fix money request amount input is partially visible after going back from currency selection page #34787
Conversation
Hey! I see that you made changes to our Form component. Make sure to update the docs in FORMS.md accordingly. Cheers! |
@situchan please review this when you got the chance 🙇 |
Reviewer Checklist
Screenshots/VideosAndroid: Nativeandroid.movAndroid: mWeb Chromemchrome-before-fix.movmchrome1.movmchrome2.moviOS: Nativeios.moviOS: mWeb Safarimsafari.movMacOS: Chrome / Safariweb.movMacOS: Desktopdesktop.mov |
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.
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.
Thanks guys, LGTM
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
This caused a minor regression: web.mov |
Can be fixed like so: diff --git a/src/components/TextInput/BaseTextInput/index.native.tsx b/src/components/TextInput/BaseTextInput/index.native.tsx
index afd796d8c8..7a230bc90f 100644
--- a/src/components/TextInput/BaseTextInput/index.native.tsx
+++ b/src/components/TextInput/BaseTextInput/index.native.tsx
@@ -426,7 +426,7 @@ function BaseTextInput(
styles.visibilityHidden,
]}
onLayout={(e) => {
- if (e.nativeEvent.layout.width === 0) {
+ if (e.nativeEvent.layout.width === 0 && e.nativeEvent.layout.height === 0) {
return;
}
setTextInputWidth(e.nativeEvent.layout.width);
diff --git a/src/components/TextInput/BaseTextInput/index.tsx b/src/components/TextInput/BaseTextInput/index.tsx
index 4fa47eff41..7ca8c69153 100644
--- a/src/components/TextInput/BaseTextInput/index.tsx
+++ b/src/components/TextInput/BaseTextInput/index.tsx
@@ -447,7 +447,7 @@ function BaseTextInput(
styles.visibilityHidden,
]}
onLayout={(e) => {
- if (e.nativeEvent.layout.width === 0) {
+ if (e.nativeEvent.layout.width === 0 && e.nativeEvent.layout.height === 0) {
return;
}
let additionalWidth = 0;
|
Thanks for the suggestion. But that didn't work either 😞 Screen.Recording.2024-01-27.at.8.02.29.AM.mov@bernhardoj I think we should revert this |
Oh interesting, yeah I think it would be better to revert atm and figure out an ultimate solution |
PR for straight revert #35273 cc @roryabraham |
I see. I forget to consider the auto-grow height case. The suggestion from @roryabraham actually works or we can handle it case by case
@situchan which one you prefer. |
🚀 Deployed to staging by https://github.com/marcochavezf in version: 1.4.33-0 🚀
|
🚀 Deployed to production by https://github.com/francoisl in version: 1.4.33-5 🚀
|
Details
We use auto grow width for the amount input and setting the width based on the width of the text. But when the page is unfocused by going to another page, the width will becomes 0 and we set a minimum of 8 of width, so it's partially visible.
Fixed Issues
$ #33465
PROPOSAL: #33465 (comment)
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Screen.Recording.2024-01-19.at.16.17.57.mov
Android: mWeb Chrome
Screen.Recording.2024-01-19.at.16.20.13.mov
iOS: Native
Screen.Recording.2024-01-19.at.16.29.07.mov
iOS: mWeb Safari
Screen.Recording.2024-01-19.at.16.25.35.mov
MacOS: Chrome / Safari
Screen.Recording.2024-01-19.at.16.13.48.mov
MacOS: Desktop
Screen.Recording.2024-01-19.at.16.16.24.mov