-
Notifications
You must be signed in to change notification settings - Fork 30.2k
When DraggableScrollableSheet is nested in showModalBottomSheet, minChildSize is ignored. #83273
Copy link
Copy link
Open
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listfound in release: 2.2Found to occur in 2.2Found to occur in 2.2found in release: 2.3Found to occur in 2.3Found to occur in 2.3frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onteam-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team
Description
Currently, when I attempt to use a DraggableScrollableSheet inside of a showModalBottomSheet, the minChildSize is ignored and the bottom sheet closes.
Steps to Reproduce
Here is an extremely simple example of the problem that I am facing:
showModalBottomSheet(
enableDrag: false,
isDismissible: false,
backgroundColor: Colors.transparent,
barrierColor: Colors.transparent,
context: context,
isScrollControlled: true,
useRootNavigator: true,
builder: (ctx) => DraggableScrollableSheet(
expand: false,
maxChildSize: .75,
minChildSize: .3,
builder: (context, scrollController) => Container(
color: Colors.white,
child: SingleChildScrollView(
controller: scrollController,
child: Container(
height: 300,
),
),
),
),
);Demo: https://dartpad.dev/bf9d3722af1afaac9bdc17a70ae17c46
Expected results: When the minChildSize is reached, scrolling is stopped and dismissal is prevented.
Actual results: The bottom sheet closes.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listfound in release: 2.2Found to occur in 2.2Found to occur in 2.2found in release: 2.3Found to occur in 2.3Found to occur in 2.3frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onteam-frameworkOwned by Framework teamOwned by Framework teamtriaged-frameworkTriaged by Framework teamTriaged by Framework team