Skip to content

Commit

Permalink
fix: send button disabled after writing message [WPB-9421] (#3039)
Browse files Browse the repository at this point in the history
  • Loading branch information
saleniuk authored May 27, 2024
1 parent f0b42cf commit 8f7d942
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,17 +86,17 @@ internal class StateSyncingModifierNode(
}

private fun observeTextState(fireOnValueChanged: Boolean = true) {
lateinit var text: TextFieldState
lateinit var value: TextFieldValue

observeReads {
text = state
value = TextFieldValue(
state.text.toString(),
state.selection,
state.composition
)
}
if (fireOnValueChanged) {
val newValue = TextFieldValue(
text = text.toString(),
selection = text.selection,
composition = text.composition
)
onValueChanged(newValue)
onValueChanged(value)
}
}
}

0 comments on commit 8f7d942

Please sign in to comment.