1
0
mirror of https://github.com/flutter/samples.git synced 2025-11-08 22:09:06 +00:00

Set showDragHandle to true for BottomSheet (#1741)

One line change to show the drag handle on the `ModalBottomSheetRoute`.

<img width="611" alt="Screenshot 2023-04-18 at 4 56 49 PM"
src="https://user-images.githubusercontent.com/36861262/232929589-492434b9-7c87-43a0-8378-45ee3ca53782.png">


## Pre-launch Checklist

- [x] I read the [Flutter Style Guide] _recently_, and have followed its
advice.
- [x] I signed the [CLA].
- [x] I read the [Contributors Guide].
- [ ] I updated/added relevant documentation (doc comments with `///`).
- [x] All existing and new tests are passing.

Co-authored-by: Qun Cheng <quncheng@google.com>
This commit is contained in:
Qun Cheng
2023-04-26 05:29:47 -07:00
committed by GitHub
parent 9ff21d33f3
commit a0386f36ef

View File

@@ -1546,6 +1546,7 @@ class _BottomSheetSectionState extends State<BottomSheetSection> {
), ),
onPressed: () { onPressed: () {
showModalBottomSheet<void>( showModalBottomSheet<void>(
showDragHandle: true,
context: context, context: context,
// TODO: Remove when this is in the framework https://github.com/flutter/flutter/issues/118619 // TODO: Remove when this is in the framework https://github.com/flutter/flutter/issues/118619
constraints: const BoxConstraints(maxWidth: 640), constraints: const BoxConstraints(maxWidth: 640),