Hi I'm new to flutter and I tried to use NestedScrollView Widget to show my widget. I've managed to create the NestedScrollView widget and I wanted to remove my bottom sheet when the scrollView already reach the end of the screen. Is there any way that I can achieve it ? Thanks Before
Here's my code:
NestedScrollView(
headerSliverBuilder: (context, isScrolled) {
return [
SliverPersistentHeader(
pinned: true,
floating: false,
delegate: ChooseUsersHeaderDelegate(
widgetList: Container(
color: Colors.white,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
/// Search Box
buildSearch(),
],
),
),
minHeight: selectedContactId.isNotEmpty ? 135 : 60,
maxHeight: selectedContactId.isNotEmpty ? 135 : 60,
parentContext: context,
),
),
];
},
body: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Column(
mainAxisAlignment: MainAxisAlignment.start,
children: [
Text(
'allContacts',
style: GoogleFonts.montserrat(
fontSize: 14,
fontWeight: FontWeight.w500,
color: primaryColor,
fontStyle: FontStyle.normal,
),
).tr(),
Column(
mainAxisAlignment: MainAxisAlignment.start,
children: [
isLoading
? ReusableLoadingContact()
: NotificationListener<
OverscrollIndicatorNotification>(
onNotification: (overScroll) {
overScroll.disallowIndicator();
return true;
},
child: buildWidget(context, 'contacts')),
],
),
],
),
),
bottomSheet: Container(
height: 40,
width: double.infinity,
decoration: BoxDecoration(
gradient: LinearGradient(
begin: Alignment.topCenter,
end: FractionalOffset.bottomCenter,
colors: <Color>[
Colors.white.withOpacity(0.1),
Colors.white,
],
stops: [0, 1],
),
),
),
