-
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 Inconsistency in the security page and Request money page #23712
Conversation
@thesahindia Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Waiting for the copy. |
@thesahindia The translation key is confirmed and updated. Please help to review when you have a chance. |
@thesahindia Friendly bump. |
@thesahindia ICYMI. Friendly bump. Please help to review the PR when you have time. |
@@ -124,6 +129,8 @@ function MoneyRequestAmountForm({amount, currency, isEditing, forwardedRef, onCu | |||
setSelection((prevSelection) => ({...prevSelection})); | |||
return; | |||
} | |||
setIsInvalidAmount(checkAmount(newAmountWithoutSpaces)); | |||
setFormError(''); |
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.
I'm thinking that maybe in order to be congruent with the Form
pages we should only clear the error once the user has input a valid amount. Example:
Screen.Recording.2023-08-21.at.16.27.08.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.
@Ollyws I just updated.
isDisabled={!currentAmount.length || parseFloat(currentAmount) < 0.01} | ||
text={buttonText} | ||
/> | ||
<View style={[styles.w100, styles.mt5]}> |
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.
@Ollyws I think it's hard to prevent jumping because the input has style flex:1.
@shawnborton I think we should confirm here again. Should we disable the next button of money request flow?
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.
What does this look like on mobile where we show the full keypad too?
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.
Some UI could be broken as @Ollyws commented here So I think we should only not disable the button in CodesSteps
of TwoFactor
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.
I feel like we should consider moving that error message to be below the green button for consistency. I think it's probably okay if the UI jumps slightly because the alternatives aren't really too great. We'd have to give a an area a fixed height to prevent jumping, which kind of feels like we'd be optimizing for the less common case.
Also, we should make the error text use our text.Supporting color, but keep the dot red.
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.
I feel like we should consider moving that error message to be below the green button for consistency
What does that mean? I saw the error message is always above the confirm button.
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.
@shawnborton please help me in the comment above when you have a chance.
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.
But then that makes an awkward gap between the green button and the keypad. So I think for this one, we should move the error message to be below the green submit button.
@Ollyws Updated @shawnborton suggestion, please help to review again. |
Are the screenshots updated? |
@shawnborton I just updated all screenshots, please help to check again. |
@shawnborton Is it your suggestion? |
Updated. |
@Ollyws Do you think we should show the error if the input is blurred and the amount is invalid. |
@dukenv0307 Thanks for the update. No I don't think it's necessary to show the error when the input is blurred. |
@dukenv0307 Could we also please get #23712 (comment) aligned on the CodesPage too, thanks. |
@Ollyws I updated. |
Reviewer Checklist
Screenshots/VideosWebMacOS_Web.mp4Mobile Web - ChromeAndroid_Chrome.mp4Mobile Web - SafariiOS_Safari.mp4DesktopMacOS_Desktop.mp4iOSiOS_Native.mp4AndroidAndroid_Native.mp4 |
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
@tgolen I updated. |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/tgolen in version: 1.3.73-0 🚀
|
🚀 Deployed to production by https://github.com/mountiny in version: 1.3.73-1 🚀
|
🚀 Deployed to staging by https://github.com/tgolen in version: 1.3.74-0 🚀
|
🚀 Deployed to production by https://github.com/chiragsalian in version: 1.3.74-3 🚀
|
{!_.isEmpty(formError) && firstPress && ( | ||
<FormHelpMessage | ||
style={[styles.ph5]} | ||
isError | ||
message={translate(formError)} | ||
/> | ||
)} |
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.
I'd say #29204 is a regression as it could have been handled as part of this PR.
Details
Fix Inconsistency in the security page and Request money page
Fixed Issues
$ #22660
PROPOSAL: #22660 (comment)
Tests
Offline tests
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)/** comment above it */
this
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)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
Web
Screencast.from.01-09-2023.00.11.24.webm
Mobile Web - Chrome
Record_2023-09-01-00-12-59.mp4
Mobile Web - Safari
Screen.Recording.2023-09-01.at.00.16.06.mp4
Desktop
Screen.Recording.2023-09-01.at.00.21.59.mov
iOS
Screen.Recording.2023-09-01.at.00.20.57.mp4
Android
22660.webm