-
Notifications
You must be signed in to change notification settings - Fork 325
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: multiple image upload issue using native image picker and generic improvements for upload #2638
Conversation
…c improvements for upload
SDK Size
|
// eslint-disable-next-line react-hooks/exhaustive-deps | ||
}, [selectedFilesLength]); |
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.
same 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.
Aside from what Oli and Santhosh already mentioned, looks good to me ! When those are fixed we can go ahead with this 🚀
await uploadFilesHandler(); | ||
} else { | ||
/** User de-selected a video in bottom sheet attachment picker */ | ||
removeFilesHandler(); |
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.
This also covers the case where selectedFilesLength === fileUploadsLength
, is this the desired behaviour ? Just curious about this, not a remark
🎉 This PR is included in version 5.36.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎯 Goal
The goal of the PR is to primarily solve the multiple image upload issue on the new architecture but this also applies to the current v5 branch as the improvements here make sense and are not architectural dependant.
There are a few improvements in the
useEffect
of theMessageInput
as well that is supposed to target only the media library(attachment picker) but don't make sense for the native image pickers, so proper checks are added around the same and improves the upload process for normal use-cases.The PR also solves the issue of clicked images not respecting the file size config check.
☑️ Checklist
develop
branch