sliding_up_panel
sliding_up_panel copied to clipboard
Add a way to attach widgets to the top border
That's what I want to achieve

I know it's not very beautiful, but it's a design I have to do. These choice buttons should move with panel sticking to its top.
The problem is I cannot just wrap a panel or header into Stack and use Positioned, because a panel crops everything that is out.

Now the only way is a dynamically calculate a widget position in onPanelSlide callback, as described in a video below (super inconvenient) https://youtu.be/s9XHOQeIeZg?t=527
Make an option to not to crop outside the panel or an additional field for attached widgets.
Oh, the fix above doesn't solve the issue You can draw the widgets outside the Stack but cannot make them clickable. Those buttons will not react to gestures. It's a known issue of the Stack which won't be fixed. https://stackoverflow.com/questions/62258640/flutter-overflowed-positioned-button-is-not-clickable https://github.com/flutter/flutter/issues/19445
So the problem is still open.
I used this method https://youtu.be/s9XHOQeIeZg it also has a problem that attached buttons are wobbling when dragging the sheet up and down. See the video: https://disk.yandex.ru/i/0Z4Rn1UVcvM9Ew It's because their positions are recalculated and redrawn in response to the panel dragging, and it slightly delays.