Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1932,6 +1932,7 @@ public final class io/getstream/chat/android/compose/ui/messages/composer/Compos
public final fun getLambda$-1206314464$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
public final fun getLambda$-1267828661$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
public final fun getLambda$-1344661276$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
public final fun getLambda$-1407581416$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function3;
public final fun getLambda$-173232017$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
public final fun getLambda$1180759242$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
public final fun getLambda$1309976052$stream_chat_android_compose_release ()Lkotlin/jvm/functions/Function2;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.ime
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.safeDrawingPadding
import androidx.compose.foundation.layout.wrapContentHeight
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Scaffold
import androidx.compose.material3.SnackbarDuration
Expand Down Expand Up @@ -367,9 +366,7 @@ internal fun DefaultBottomBarContent(

Column {
MessageComposer(
modifier = Modifier
.fillMaxWidth()
.wrapContentHeight(),
modifier = Modifier.fillMaxWidth(),
viewModel = composerViewModel,
isAttachmentPickerVisible = attachmentsPickerViewModel.isPickerVisible,
onAttachmentsClick = attachmentsPickerViewModel::togglePickerVisibility,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ import io.getstream.chat.android.compose.ui.theme.MessageComposerParams
import io.getstream.chat.android.compose.ui.theme.MessageComposerTrailingContentParams
import io.getstream.chat.android.compose.ui.theme.StreamTokens
import io.getstream.chat.android.compose.ui.util.SnackbarPopup
import io.getstream.chat.android.compose.ui.util.StreamSnackbar
import io.getstream.chat.android.compose.ui.util.StreamSnackbarVariant
import io.getstream.chat.android.compose.ui.util.StreamSnackbarVisuals
import io.getstream.chat.android.compose.util.extensions.toSet
Expand Down Expand Up @@ -299,7 +300,6 @@ public fun MessageComposer(

Row(
modifier = Modifier
.padding(vertical = StreamTokens.spacing2xs)
.fillMaxWidth()
.padding(
start = StreamTokens.spacingMd,
Expand Down Expand Up @@ -330,7 +330,12 @@ public fun MessageComposer(
)

if (snackbarHostState.currentSnackbarData != null) {
SnackbarPopup(hostState = snackbarHostState)
SnackbarPopup(hostState = snackbarHostState) { snackbarData ->
StreamSnackbar(
modifier = Modifier.padding(bottom = StreamTokens.spacingMd),
snackbarData = snackbarData,
)
}
Comment thread
andremion marked this conversation as resolved.
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ internal data class StreamSnackbarVisuals(
* snackbar's variant), and an optional action button.
*
* @param snackbarData The [SnackbarData] driving the message, variant, and optional action.
* @param modifier Modifier applied to the inner [Surface] (e.g. to control width or padding).
* @param modifier Modifier for styling.
*/
@Composable
internal fun StreamSnackbar(
Expand All @@ -85,9 +85,9 @@ internal fun StreamSnackbar(
val actionLabel = snackbarData.visuals.actionLabel
val variant = (snackbarData.visuals as? StreamSnackbarVisuals)?.variant
?: StreamSnackbarVariant.Default
Box(modifier = Modifier.padding(StreamTokens.spacingMd)) {
Box(modifier = modifier.padding(StreamTokens.spacingMd)) {
Surface(
modifier = modifier.shadow(4.dp, shape = SnackbarShape),
modifier = Modifier.shadow(elevation = StreamTokens.elevation3, shape = SnackbarShape),
shape = SnackbarShape,
color = ChatTheme.colors.backgroundCoreInverse,
contentColor = ChatTheme.colors.textOnInverse,
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading