```Modifier.pointerInput(Unit) { detectTapGest...
# compose
a
Copy code
Modifier.pointerInput(Unit) {
    detectTapGestures(
        onPress = { offset ->
            // pressed

            awaitRelease()
            // released
        }
    )
}
I am using the above code to detect when the user keeps holding on a
Box
. The issue is that when I tap and hold on the box and then move my finger outside the bounds of the Box, then
awaitRelease()
is never unblocked. is there a way for awaitRelease() to be done when the user releases their finger even outside the composable they started pressing on?
👀 1
a
In that case a
GestureCancellationException
will be thrown so you can just check that.