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
feat: media gallery [WPB-4989] #2490
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## develop #2490 +/- ##
=============================================
- Coverage 41.45% 41.19% -0.27%
Complexity 1105 1105
=============================================
Files 348 353 +5
Lines 12767 12848 +81
Branches 1668 1676 +8
=============================================
Hits 5293 5293
- Misses 6976 7057 +81
Partials 498 498
Continue to review full report in Codecov by Sentry.
|
APKs built during tests are available here. Scroll down to Artifacts! |
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.
Looking great 👌🏻
Just have 2 small comments to use dimensions
.background(color = colorsScheme().backgroundVariant), | ||
topBar = { | ||
WireCenterAlignedTopAppBar( | ||
elevation = 0.dp, |
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.
elevation = 0.dp, | |
elevation = dimensions().spacing0x, |
color = MaterialTheme.wireColorScheme.onPrimary, shape = RoundedCornerShape(dimensions().messageAssetBorderRadius) | ||
) | ||
.border( | ||
width = 1.dp, |
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.
width = 1.dp, | |
width = dimensions().spacing1x, |
Build 2099 succeeded. The build produced the following APK's: |
...in/kotlin/com/wire/android/ui/home/conversations/media/ConversationAssetMessagesViewModel.kt
Outdated
Show resolved
Hide resolved
...in/kotlin/com/wire/android/ui/home/conversations/media/ConversationAssetMessagesViewModel.kt
Show resolved
Hide resolved
...in/kotlin/com/wire/android/ui/home/conversations/media/ConversationAssetMessagesViewState.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/wire/android/ui/home/conversations/media/ConversationMediaButton.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/wire/android/ui/home/conversations/media/ImageAssetsContent.kt
Outdated
Show resolved
Hide resolved
app/src/main/kotlin/com/wire/android/ui/home/conversations/media/ImageAssetsContent.kt
Outdated
Show resolved
Hide resolved
...in/kotlin/com/wire/android/ui/home/conversations/media/ConversationAssetMessagesViewModel.kt
Show resolved
Hide resolved
Build 2115 failed. |
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.
👌🏻
APKs built during tests are available here. Scroll down to Artifacts! |
Build 2120 succeeded. The build produced the following APK's: |
APKs built during tests are available here. Scroll down to Artifacts! |
APKs built during tests are available here. Scroll down to Artifacts! |
Build 2129 succeeded. The build produced the following APK's: |
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Loading image assets functionality is slightly different then loading conversation messages, reasons:
paging-compose
is not allowing to control when load more images, using it will cause out of memory error, because messages loading loads images asynchronously, we can't allow to load 20 images at once on screen, especially when they can have big sizeConversationAssetMessagesViewModel
which checks if user scrolls LazyColumn to bottom byGetAssetMessagesForConversationUseCase
to load asset's sequentially, currentlyBATCH_SIZE
equals 5MediaAssetImage
:AsyncImageMessage
which avoids using asynchronous image load from network to load only image from storage, because images are saved already in view modelVideo with loading images when they are already downloaded
https://github.com/wireapp/wire-android/assets/13151239/ba087453-4134-4141-852a-d4ce1598ba65
Wideo With images which are not yet downloaded (for example when we restored backup)
https://github.com/wireapp/wire-android/assets/13151239/2b1209d7-fbc8-4e58-b5fa-4e37934f1292
Screen with failed image
Needs releases with:
wireapp/kalium#2260
Testing
Test Coverage (Optional)
How to Test
Briefly describe how this change was tested and if applicable the exact steps taken to verify that it works as expected.
Notes (Optional)
Specify here any other facts that you think are important for this issue.
Attachments (Optional)
Attachments like images, videos, etc. (drag and drop in the text box)
PR Post Submission Checklist for internal contributors (Optional)
PR Post Merge Checklist for internal contributors
References
feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764
.