-
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
[TS migration] Migrate 'StatePicker' component to TypeScript #33352
[TS migration] Migrate 'StatePicker' component to TypeScript #33352
Conversation
Hey! I see that you made changes to our Form component. Make sure to update the docs in FORMS.md accordingly. Cheers! |
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.
just a nit, lgtm 😄
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! 😄
# Conflicts: # src/components/MenuItem.tsx
@jjcoffee kind bump 🙂 |
Reviewer Checklist
Screenshots/VideosAndroid: Nativeandroid-native-2024-01-02_16.23.08.mp4Android: mWeb Chromeandroid-chrome-2024-01-02_14.21.50.mp4iOS: Nativeios-native-2024-01-02_17.23.02.mp4iOS: mWeb Safariios-safari-2024-01-02_14.36.47.mp4MacOS: Chrome / Safaridesktop-chrome-2024-01-02_14.16.38.mp4MacOS: Desktopdesktop-app-2024-01-02_16.34.14.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!
We did not find an internal engineer to review this PR, trying to assign a random engineer to #25112 as well as to this PR... Please reach out for help on Slack if no one gets assigned! |
@grgia Just noticed you got assigned to the issue but not here for some reason. Could you give this a review? |
# Conflicts: # src/components/StatePicker/index.tsx
@grgia kind bump 🙂 |
@grgia Could you please take a look at this PR |
@@ -88,13 +82,14 @@ function StateSelectorModal({currentState, isVisible, onClose, onStateSelected, | |||
testID={StateSelectorModal.displayName} | |||
> | |||
<HeaderWithBackButton | |||
title={label || translate('common.state')} | |||
title={label ?? translate('common.state')} |
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.
if label is an empty string '' then this will return '', could you confirm if that case will cause a problem here?
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 agree it will be more safe to use logical OR in this case, so updated it
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.
Before merging, let's confirm that we are defaulting the label prop correctly. Thoughts? cc @jjcoffee
Ah good catch! Yeah I agree it's better with the logical OR as I can't think of a reason we'd want to have an empty string as the label 😄 |
@grgia kind bump 🙂 |
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!
🚀 Deployed to staging by https://github.com/mountiny in version: 1.4.32-2 🚀
|
🚀 Deployed to production by https://github.com/francoisl in version: 1.4.32-5 🚀
|
Details
[TS migration] Migrate 'StatePicker' component to TypeScript
Fixed Issues
$ #25112
PROPOSAL: N/A
Tests
Steps for every State Picker to test:
Places to test State Picker:
1. Personal Details -> Address:
United States
, after that State input will turn into a picker.2. Bank Account -> Debit Card:
3. Workspace Bank Account -> manual:
067014822
/1234
) and pressContinue
Offline tests
N/A
QA Steps
Same as in the Tests section.
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
android1.mp4
Android: mWeb Chrome
android_web1.mp4
iOS: Native
ios1.mp4
iOS: mWeb Safari
ios_web1.mp4
MacOS: Chrome / Safari
web1.mp4
MacOS: Desktop
desktop1.mp4