Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
modal_bottom_sheet
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Jaime Blasco
2020-04-15 10:44:19 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
2c249c502aaf6098ea44d784214d22af31d64868
2c249c50
1 parent
bf6247bf
Prepare for 0.1.5 release
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
9 deletions
CHANGELOG.md
README.md
example/lib/main.dart
lib/src/bottom_sheet.dart
pubspec.yaml
CHANGELOG.md
View file @
2c249c5
...
...
@@ -4,6 +4,7 @@
## [0.1.4] - Clean code and fix small bugs
## [0.1.5] - Bugfixes
-
fix assertion in CupertinoBottomSheet and BottomSheetRoute when using the CupetinoApp or WidgetsApp as root
-
fix assertion when scrollController isn't used by the builder
\ No newline at end of file
## [0.1.5] - Scroll improvements and bug fixes
-
Support for closing a modal with a scroll view by dragging down fast.
-
Fix assertion in CupertinoBottomSheet and BottomSheetRoute when using the CupetinoApp or WidgetsApp as root
-
Fix assertion when scrollController isn't used by the builder
\ No newline at end of file
...
...
README.md
View file @
2c249c5
...
...
@@ -187,7 +187,7 @@ Check in the example project `showAvatarModalBottomSheet` for how to create your
## Roadmap
-
[
]
Support closing by dragging fast on a modal with a scroll view.
-
[
X
]
Support closing by dragging fast on a modal with a scroll view.
-
[
]
Improve animation curves when user is not dragging.
...
...
example/lib/main.dart
View file @
2c249c5
...
...
@@ -194,7 +194,8 @@ class _MyHomePageState extends State<MyHomePage> {
scrollController:
scrollController
),
)),
ListTile
(
title:
Text
(
'Cupertino Navigator + Scroll + WillPopScope'
),
title:
Text
(
'Cupertino Navigator + Scroll + WillPopScope'
),
onTap:
()
=>
showCupertinoModalBottomSheet
(
expand:
true
,
context:
context
,
...
...
lib/src/bottom_sheet.dart
View file @
2c249c5
...
...
@@ -225,7 +225,6 @@ class _ModalBottomSheetState extends State<ModalBottomSheet>
}
}
// As we cannot access the dragGesture detector of the scroll view
// we can not know the DragDownDetails and therefore the end velocity.
// VelocityTracker it is used to calculate the end velocity of the scroll
...
...
@@ -257,8 +256,7 @@ class _ModalBottomSheetState extends State<ModalBottomSheet>
final
offset
=
Offset
(
0
,
_scrollController
.
offset
);
_velocityTracker
.
addPosition
(
duration
,
offset
);
_handleDragUpdate
(
dragDetails
.
primaryDelta
);
}
else
if
(
isDragging
)
{
}
else
if
(
isDragging
)
{
final
velocity
=
_velocityTracker
.
getVelocity
().
pixelsPerSecond
.
dy
;
_handleDragEnd
(
velocity
);
}
...
...
pubspec.yaml
View file @
2c249c5
name
:
modal_bottom_sheet
description
:
'
Create
awesome
and
powerful
modal
bottom
sheets.
Material,
Cupertino
or
create
your
own
'
description
:
'
Create
awesome
and
powerful
modal
bottom
sheets.
Material,
Cupertino
iOS
13
or
create
your
own
style
'
version
:
0.1.5
homepage
:
'
https://github.com/jamesblasco/modal_bottom_sheet'
...
...
Please
register
or
login
to post a comment