akshathjain / sliding_up_panel

A draggable Flutter widget that makes implementing a SlidingUpPanel much easier!
https://pub.dartlang.org/packages/sliding_up_panel
Other
1.36k stars 379 forks source link

PageView inside panelBuilder impossible to use. #271

Closed kurtiev closed 2 years ago

kurtiev commented 2 years ago

I'm using SingleChildScrollView inside PageView which is inside _panel().

panelBuilder: (ScrollController sc) => _panel(sc)

So when I'm passing sc into my SingleChildScrollView it causes an error, which says, that ScrollController is used multiple times, this is clear.

But if remove controller: sc from my SingleChildScrollView, the SingleChildScrollView start work incorrectly, scroll happens simulteniusly on SingleChildScrollView and SlidingUpPanel. Similar issue here

So, how to reuse one controller from SlidingUpPanel for multiple SingleChildScrollView?

Also I tried one SingleChildScrollView like a parent for PageView, but PageView always fails with the issue of infinity height.

kurtiev commented 2 years ago

https://pub.dev/packages/expandable_page_view instead PageView helped solve infinity heught.