Is there an easy way to extend the click area of a...
# compose
t
Is there an easy way to extend the click area of a
Button
, apart from creating physical padding around it by enclosing it in a
Box
etc ?
👍 2
a
No, but there's likely to be some work in this area for touchability post-1.0
👍 4
t
Gotcha, thanks Adam! In the meantime, I'm guessing enclosing components in a
Box + Modifier.padding
or such is the best approach.
a
For now. I'd like for the touch dispatch system to be able to enforce a minimum touch target size and disambiguate across nesting layers at a global level
👍🏼 1
👍 3
t
I've hacked this for height with a combination of
height(0.dp)
,
wrapContentSize()
, and
size(48.dp)
But that's arguably not easy
t
@tad, I see. Did that create extra click area without adding tangible padding/space?