-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[HOLD on #33756, #34080] TS migration of MultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
components
#33081
[HOLD on #33756, #34080] TS migration of MultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
components
#33081
Conversation
@blazejkustra @fabioh8010 @hayata-suenaga hey guys just a heads up, that i've already starting migrating all of the "Attachment Gallery" components to TS, since i've mostly authored the components and worked on it a lot. Some of the logic involves some tricky typings from other libraries. Feel free to chime in here, otherwise i'm gonna finish this PR next week! |
@chrispader Attachment directory is already worked on here, let's not do the work twice 😄 cc @kubabutkiewicz However I'm fine with you working on it as you authored it and have the most context, just let us know once it's ready so me or @fabioh8010 can review it before making this PR |
Hey @chrispader, I spoke with @kubabutkiewicz and he is okay with closing his PR and letting you do the migration here. But could you explain us why this migration is being doing separately, e.g. are there any other reasons besides the migration itself? We would like to reminder that, at the moment, TS migrations done outside of the TS migration team should be communicated in advance to avoid situations just like this one. |
Sorry for the misunderstanding. I didn't want @kubabutkiewicz to shut down his PR, it's fine if he continues :) Just thought that i might want to migrate at least Also fine, if the TS team works on that too :) |
No problem @chrispader ! I think is best if you continue with this PR since you worked on in the past like you said before. And looks like |
@chrispader Just keep us posted so we can review before PR is ready for C+ review 👍 |
…ispader/attachment-gallery-ts-migration
MultiGestureCanvas
, Lightbox
and AttachmentCarouselPager
TS migrationMultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
, CarouselItem
TS migration
@blazejkustra @fabioh8010 i'm also gonna migrate the During the previous TS migration i found some improvements in how the attachment carousel components are structurde and |
MultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
, CarouselItem
TS migrationMultiGestureCanvas
, Lightbox
and AttachmentCarouselPager
TS migration
MultiGestureCanvas
, Lightbox
and AttachmentCarouselPager
TS migrationMultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
and CarouselItem
components
Actually, let's not migrate |
You can use
|
OK got it, thanks! Though in this case, the reason is not any blocking issue, but the fact that inferable types will automatically get stripped out by ESLint, but if i don't define the type for For this reason i added the type and disabled the ESLint warning for this line. Can you check if that's what we should do here? cc @blazejkustra |
MultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
and CarouselItem
componentsMultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
and CarouselItem
components
MultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
and CarouselItem
componentsMultiGestureCanvas
, Lightbox
, AttachmentCarouselPager
components
Looking at the code I'm not quite sure, does this PR only migrates components to TS or does it also involve refactoring these components?
I see that you marked this PR as ready for review. Should me/Fabio have a look? @chrispader
Your solution looks good to me 😄 const NUMBER_OF_CONCURRENT_LIGHTBOXES: number = 3; |
It involves some small refactorings of |
@blazejkustra @fabioh8010 just reverted the refactorings. This is ready for review, though the branch is based on another PR, so the diff also contains changes from that other PR. There's a link to the actual diff in the PR description though |
Let's put this PR in a draft and wait for the other PR to be merged first, wdyt? @chrispader Also, lint is failing |
Please tag me once this becomes read to review |
Closing in favor of #33756. I merged TS migration changes into the other PR, so that we don't break TS checks on |
@ntdiary
Details
Adds types for
MultiGestureCanvas
,Lightbox
and many attachment/image related components. This PR also includes some minor code improvements inLightbox
for simplicityBased on #33756. Check this for actual diff
Holding on #33756 as well as #34080 if possible..
Fixed Issues
$ #24969
$ #25152
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)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
android.webm
Android: mWeb Chrome
iOS: Native
Simulator.Screen.Recording.-.iPhone.15.Pro.-.2024-01-08.at.09.54.30.mp4
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop