Hi, is there a way to have an effect equivalent to...
# compose
v
Hi, is there a way to have an effect equivalent to
clipChildren=false
? I have a
Column
composed of scrollable
LazyColumnFor
+
FloatingActionButton
and I want the scrollable column to be seen behind the FAB. But scrolling should end just above the FAB, not below
z
Add an empty item at the bottom of your list equal to the height of the FAB?
v
But I need to calculate the size of the FAB then, right? I think this is not done very easely in Compose
z
v
I guess there is also a need to add some
MutableState
variable which stores the laid out height of FAB (modified by
onPositioned
). And then the item list should be comprised with original list + one special item which get its height updated. And then in `LazyColumnFor`’s
itemContent
we should add some kind of
when
which inspects what kind of item we got to choose the right composable. Please correct me if I overcomplicated something. Oh boy this is hard 😅
z
That sounds right. I would expect this to get easier eventually, the lazy column APIs are still pretty early, and the scaffold stuff is going through some changes too I believe.
👍 1
z
@Zach Klippenstein (he/him) [MOD] is it possible to see the issues? to get an idea what they are thinking for the future.
z
Yes, you can look at the pull request tracker or the issue tracker, The latter is linked from the channel description, the former is https://android-review.googlesource.com/q/project:platform%252Fframeworks%252Fsupport+status:open
151 Views