Skip to content

Commit

Permalink
## 5.1.2
Browse files Browse the repository at this point in the history
* Add keyboardDismissBehavior property #97
zmtzawqlp committed Jun 13, 2022
1 parent 28b19e6 commit 4e6d898
Showing 3 changed files with 16 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 5.1.2

* Add keyboardDismissBehavior property #97

## 5.1.1

* Provide ExtendedVisibilityDetector to point out which list is visible
11 changes: 11 additions & 0 deletions lib/src/extended_nested_scroll_view.dart
Original file line number Diff line number Diff line change
@@ -355,6 +355,7 @@ class ExtendedNestedScrollView extends StatefulWidget {
this.scrollBehavior,
this.pinnedHeaderSliverHeightBuilder,
this.onlyOneScrollInBody = false,
this.keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual,
}) : assert(scrollDirection != null),
assert(reverse != null),
assert(headerSliverBuilder != null),
@@ -469,6 +470,12 @@ class ExtendedNestedScrollView extends StatefulWidget {
/// or separate and desirous of unique behaviors.
final ScrollBehavior? scrollBehavior;

/// {@template flutter.widgets.scroll_view.keyboardDismissBehavior}
/// [ScrollViewKeyboardDismissBehavior] the defines how this [ScrollView] will
/// dismiss the keyboard automatically.
/// {@endtemplate}
final ScrollViewKeyboardDismissBehavior keyboardDismissBehavior;

/// Returns the [SliverOverlapAbsorberHandle] of the nearest ancestor
/// [ExtendedNestedScrollView].
///
@@ -664,6 +671,7 @@ class ExtendedNestedScrollViewState extends State<ExtendedNestedScrollView> {
handle: _absorberHandle,
clipBehavior: widget.clipBehavior,
restorationId: widget.restorationId,
keyboardDismissBehavior: widget.keyboardDismissBehavior,
);
},
),
@@ -683,6 +691,8 @@ class _NestedScrollViewCustomScrollView extends CustomScrollView {
required Clip clipBehavior,
DragStartBehavior dragStartBehavior = DragStartBehavior.start,
String? restorationId,
ScrollViewKeyboardDismissBehavior keyboardDismissBehavior =
ScrollViewKeyboardDismissBehavior.manual,
}) : super(
scrollDirection: scrollDirection,
reverse: reverse,
@@ -693,6 +703,7 @@ class _NestedScrollViewCustomScrollView extends CustomScrollView {
dragStartBehavior: dragStartBehavior,
restorationId: restorationId,
clipBehavior: clipBehavior,
keyboardDismissBehavior: keyboardDismissBehavior,
);

final SliverOverlapAbsorberHandle handle;
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: extended_nested_scroll_view
description: extended nested scroll view to fix pinned header and inner scrollables sync issues.
version: 5.1.1
version: 5.1.2
homepage: https://github.com/fluttercandies/extended_nested_scroll_view

environment:

0 comments on commit 4e6d898

Please sign in to comment.