I'm trying to display a snackbar in jetpack compose, but it is not displaying the right X close button present on the sample of the documentation. Instead, it's displaying just the message. I can't find how to display that X close button.
here you can see the supposed close button on the right: 
my code:
val snackbarHostState = remember { SnackbarHostState() } SnackbarHost(hostState = snackbarHostState) uiState.toastMessage?.let { val message = stringResource(it) LaunchedEffect(key1 = message) { snackbarHostState.showSnackbar( message = message, duration = SnackbarDuration.Indefinite ) vm.toastMessage(null) } }
withDismissActionparameter toshowSnackbar()that defaults tofalse. Did you try it withtrue?