-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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 'PopoverWithMeasuredContent.js' component to TypeScript #32551
[TS migration] Migrate 'PopoverWithMeasuredContent.js' component to TypeScript #32551
Conversation
4abdeb9
to
5786bad
Compare
5786bad
to
aab2d95
Compare
aab2d95
to
00ae1e6
Compare
@eVoloshchak 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] |
@eVoloshchak Would you be able to look at it today? This is blocking some other TS issues 🙏 |
@blazejkustra, sure, will take a look in a couple of hours |
src/components/Popover/types.ts
Outdated
@@ -39,4 +39,4 @@ type PopoverProps = BaseModalProps & { | |||
|
|||
type PopoverWithWindowDimensionsProps = PopoverProps & WindowDimensionsProps; | |||
|
|||
export type {PopoverProps, PopoverWithWindowDimensionsProps}; | |||
export type {PopoverProps, PopoverWithWindowDimensionsProps, AnchorAlignment, PopoverDimensions}; |
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.
Why do we need to export those types? AnchorAlignment
and PopoverDimensions
aren't used in any other file it seems
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.
reuse added
height: PropTypes.number, | ||
width: PropTypes.number, | ||
}), | ||
type AnchorPosition = { |
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.
We define this type in 3 different files (styles/index.ts, libs/calculateAnchorPosition.ts and PopoverWithMeasuredContent
)
Let's move it to src/components/Popover/types.ts
and export it to those 3 files
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.
type reusing added
@eVoloshchak all comments addressed |
Reviewer Checklist
Screenshots/Videos |
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 #25053 as well as to this PR... Please reach out for help on Slack if no one gets assigned! |
@eVoloshchak PR Reviewer checklist is still failing 🤔 |
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, no comments to the code
✋ 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/mountiny in version: 1.4.19-0 🚀
|
🚀 Deployed to production by https://github.com/mountiny in version: 1.4.19-2 🚀
|
@pasyukevich @mountiny I am seeing a regression where emoji picker opens as a 00ae1e6#diff-66f3b9f7becc9cb3153498f739eb76e698c5a5f333c47912e684f23986452117R28-R42 App/src/components/Modal/modalPropTypes.js Lines 72 to 73 in 8cb48e4
Screen.Recording.2023-12-30.at.07.04.27.movTo fix we need to pass |
@Pujan92 I was able to reproduce showed behavior Follow-upping PR in progress |
PR with the fix is open |
Details
Fixed Issues
$ #25053
PROPOSAL:
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)StyleUtils.getBackgroundAndBorderStyle(theme.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
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop