Closed MartinCupela closed 2 months ago
Attention: Patch coverage is 92.18750%
with 5 lines
in your changes missing coverage. Please review.
Project coverage is 85.19%. Comparing base (
aeb87ff
) to head (b3d796f
). Report is 5 commits behind head on master.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Size Change: -5.28 kB (-0.7%)
Total Size: 752 kB
Filename | Size | Change | |
---|---|---|---|
./dist/components/MessageInput/AttachmentPreviewList/AttachmentPreviewList.js |
597 B | -90 B (-13.1%) | đ |
./dist/components/MessageInput/AttachmentPreviewList/FileAttachmentPreview.js |
679 B | +29 B (+4.46%) | |
./dist/components/MessageInput/AttachmentPreviewList/ImageAttachmentPreview.js |
712 B | +21 B (+3.04%) | |
./dist/components/MessageInput/AttachmentPreviewList/UploadPreviewItem.js |
0 B | -625 B (removed) | đ |
./dist/components/MessageInput/hooks/useAttachments.js |
2.06 kB | +112 B (+5.74%) | đ |
./dist/components/MessageInput/hooks/useCreateMessageInputContext.js |
994 B | -128 B (-11.41%) | đ |
./dist/components/MessageInput/hooks/useFileUploads.js |
0 B | -996 B (removed) | đ |
./dist/components/MessageInput/hooks/useImageUploads.js |
0 B | -1.06 kB (removed) | đ |
./dist/components/MessageInput/hooks/useMessageInputState.js |
2 kB | -670 B (-25.13%) | đ |
./dist/components/MessageInput/hooks/usePasteHandler.js |
684 B | -37 B (-5.13%) | â |
./dist/components/MessageInput/hooks/useSubmitHandler.js |
1.74 kB | -606 B (-25.88%) | đ |
./dist/components/MessageInput/MessageInputFlat.js |
2.15 kB | -68 B (-3.07%) | |
./dist/components/ReactFileUtilities/utils.js |
1.17 kB | +82 B (+7.55%) | đ |
./dist/i18n/de.json |
2.96 kB | +36 B (+1.23%) | |
./dist/i18n/en.json |
1.89 kB | +28 B (+1.5%) | |
./dist/i18n/es.json |
2.95 kB | +35 B (+1.2%) | |
./dist/i18n/fr.json |
3.04 kB | +40 B (+1.33%) | |
./dist/i18n/hi.json |
3.41 kB | +44 B (+1.31%) | |
./dist/i18n/it.json |
2.96 kB | +32 B (+1.09%) | |
./dist/i18n/ja.json |
3.27 kB | +43 B (+1.33%) | |
./dist/i18n/ko.json |
3.2 kB | +39 B (+1.23%) | |
./dist/i18n/nl.json |
2.85 kB | +32 B (+1.13%) | |
./dist/i18n/pt.json |
2.91 kB | +34 B (+1.18%) | |
./dist/i18n/ru.json |
3.6 kB | +42 B (+1.18%) | |
./dist/i18n/tr.json |
2.92 kB | +35 B (+1.21%) | |
./dist/index.cjs.js |
458 kB | -1.68 kB (-0.36%) |
:tada: This PR is included in version 12.0.0-rc.3 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
đ¯ Goal
Remove the following state variables from the MessageInput state:
fileOrder
imageOrder
fileUploads
imageUploads
All the attachments except the link previews (attachment contains
og_scrape_url
attribute) are now stored inattachments
array. Array keeps order and the attachment type can be determined byattachment.type
property.Default attachment types are:
audio
file
image
video
voiceRecording
Uploaded attachments will be determined by
file
attribute asattachment.localMetadata.file
.Remove the following API from the MessageInput state
uploadFile
-> from now on, useuploadAttachment
uploadImage
-> from now on, useuploadAttachment
removeFile
-> from now on, useremoveAttachments
removeImage
-> from now on, useremoveAttachments
The function
uploadNewFiles
has been kept.So to sum up, the attachments management API in MessageInput is from now on only:
attachments
uploadAttachment
uploadNewFiles
upsertAttachments
removeAttachments
đ Implementation details
đ¨ UI Changes
No UI changes.
BREAKING CHANGE: Removed fileOrder, imageOrder, fileUploads, imageUploads, uploadFile, uploadImage, removeFile, removeImage from the MessageInputContext.