Merge remote-tracking branch 'origin/kmp-completeness' into kmp-completeness

This commit is contained in:
KotlinGeekDev
2026-03-23 19:55:49 +01:00
4 changed files with 12 additions and 4 deletions
@@ -53,7 +53,11 @@ fun FeedLoaded(
contentPadding = FeedPadding,
state = listState,
) {
itemsIndexed(items.list, key = { _, item -> item.idHex }) { _, item ->
itemsIndexed(
items.list,
key = { _, item -> item.idHex },
contentType = { _, item -> item.event?.kind ?: -1 },
) { _, item ->
Row(Modifier.fillMaxWidth().animateItem()) {
NoteCompose(
item,
@@ -137,7 +137,7 @@ fun ChatFeedLoaded(
reverseLayout = true,
state = listState,
) {
itemsIndexed(items.list, key = { _, item -> item.idHex }) { index, item ->
itemsIndexed(items.list, key = { _, item -> item.idHex }, contentType = { _, item -> item.event?.kind ?: -1 }) { index, item ->
val noteEvent = item.event
if (avoidDraft == null || noteEvent !is DraftWrapEvent || noteEvent.dTag() !in avoidDraft.usedDraftTags) {
ChatroomMessageCompose(
@@ -313,7 +313,7 @@ fun FeedLoaded(
Spacer(StdVertSpacer)
}
}
itemsIndexed(items.list, key = { _, item -> item.idHex }) { _, item ->
itemsIndexed(items.list, key = { _, item -> item.idHex }, contentType = { _, item -> item.event?.kind ?: -1 }) { _, item ->
Row(
Modifier
.fillMaxWidth()
@@ -330,7 +330,11 @@ fun RenderThreadFeed(
contentPadding = FeedPadding,
state = listState,
) {
itemsIndexed(items.list, key = { _, item -> item.idHex }) { index, item ->
itemsIndexed(
items.list,
key = { _, item -> item.idHex },
contentType = { index, _ -> if (index == 0) "master" else "reply" },
) { index, item ->
val level = viewModel.levelFlowForItem(item).collectAsStateWithLifecycle(0)
val modifier =