jkm
08/31/2021, 1:16 AMModifier.onFocusEvent
Say I have a scrollable list of buttons and at the very bottom of this list I have a OutlinedTextField
.
I’ve applied the following to the OutlinedTextField
.onFocusEvent {
if (it.isFocused) {
scope.launch { scrollState.animateScrollTo(scrollState.maxValue) }
}
}
This works as expected in that when I tap on the OutlinedTextField
, my list scrolls to the bottom. The issue is that even when I tap on other elements (i.e. one of the buttons), that also scrolls the user to the bottom. Any ideas?Will Shelor
08/31/2021, 1:55 AM