feat: Hide keyboard when entering selection mode in ChatDetailScreen
This commit is contained in:
@@ -289,6 +289,14 @@ fun ChatDetailScreen(
|
|||||||
// 🔥 MESSAGE SELECTION STATE - для Reply/Forward
|
// 🔥 MESSAGE SELECTION STATE - для Reply/Forward
|
||||||
var selectedMessages by remember { mutableStateOf<Set<String>>(emptySet()) }
|
var selectedMessages by remember { mutableStateOf<Set<String>>(emptySet()) }
|
||||||
val isSelectionMode = selectedMessages.isNotEmpty()
|
val isSelectionMode = selectedMessages.isNotEmpty()
|
||||||
|
|
||||||
|
// 🔥 Закрываем клавиатуру когда открывается selection mode (action bar с Reply/Forward)
|
||||||
|
LaunchedEffect(isSelectionMode) {
|
||||||
|
if (isSelectionMode) {
|
||||||
|
keyboardController?.hide()
|
||||||
|
focusManager.clearFocus()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 🔥 Закрытие экрана
|
// 🔥 Закрытие экрана
|
||||||
val hideKeyboardAndBack: () -> Unit = {
|
val hideKeyboardAndBack: () -> Unit = {
|
||||||
|
|||||||
Reference in New Issue
Block a user