Skip to content

Commit

Permalink
v1.1.4
Browse files Browse the repository at this point in the history
  • Loading branch information
shirvanie committed Nov 17, 2023
1 parent 46d56b6 commit 13feab9
Show file tree
Hide file tree
Showing 9 changed files with 48 additions and 15 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@

## [1.1.4] - 11 November, 2023
- bug fixed

## [1.1.3] - 9 September, 2023
- dart format fixed - example

Expand Down
17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
<img src="https://raw.githubusercontent.com/shirvanie/flutter_sliding_box/master/screenshots/cover.png"/>

[![pub package](https://img.shields.io/pub/v/flutter_sliding_box.svg)](https://pub.dartlang.org/packages/flutter_sliding_box)
[![GitHub Stars](https://img.shields.io/github/stars/shirvanie/flutter_sliding_box.svg?logo=github)](https://github.com/shirvanie/flutter_sliding_box)
[![GitHub Stars](https://img.shields.io/github/stars/shirvanie/flutter_sliding_box.svg?logo=github)](https://github.com/shirvanie/flutter_sliding_box/stargazers)
[![Platform](https://img.shields.io/badge/platform-all-green.svg)](https://img.shields.io/badge/platform-android%20|%20ios%20|%20linux%20|%20macos%20|%20web%20|%20windows-green.svg)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/shirvanie/flutter_sliding_box/blob/master/LICENSE)
[![likes](https://img.shields.io/pub/likes/flutter_sliding_box?logo=flutter)](https://pub.dev/packages/flutter_sliding_box/score)
[![points](https://img.shields.io/pub/points/flutter_sliding_box)](https://pub.dev/packages/flutter_sliding_box/score)
[![popularity](https://img.shields.io/pub/popularity/flutter_sliding_box)](https://pub.dev/packages/flutter_sliding_box/score)

A draggable flutter widget (like bottom sheet panel) that makes it easier to use a SlidingBox for all platform.
Boxes can be customized with your content and placed in your app.
Expand Down Expand Up @@ -72,6 +74,17 @@ Source Link:
example/lib/share_screen.dart
</a>

##

| <img width="150px" alt="Messenger application" src="https://raw.githubusercontent.com/shirvanie/flutter_sliding_box/master/screenshots/sliding_box_demo.GIF" style="box-shadow: 0px 0px 7px #cccccc;"/> |
|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|


Source Link:
<a href="https://github.com/shirvanie/flutter_messenger_clean_architecture">
Messenger application
</a>

<br />

# Getting Started
Expand All @@ -93,7 +106,7 @@ Add *flutter_sliding_box* as a dependency in your `pubspec.yaml` file:

```yaml
dependencies:
flutter_sliding_box: ^1.1.3
flutter_sliding_box: ^1.1.4
```
import the plugin package to your dart code
Expand Down
6 changes: 6 additions & 0 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ class _SlidingBoxExamplePageState extends State<SlidingBoxExamplePage> {
});
}

@override
void dispose() {
boxController.dispose();
super.dispose();
}

@override
Widget build(BuildContext context) {
SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle(
Expand Down
6 changes: 6 additions & 0 deletions example/lib/map_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ class _SlidingBoxExamplePageState extends State<SlidingBoxExamplePage> {
final BoxController boxController = BoxController();
final TextEditingController textEditingController = TextEditingController();

@override
void dispose() {
boxController.dispose();
super.dispose();
}

@override
Widget build(BuildContext context) {
SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle(
Expand Down
6 changes: 6 additions & 0 deletions example/lib/music_player_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ class _SlidingBoxExamplePageState extends State<SlidingBoxExamplePage> {
});
}

@override
void dispose() {
boxController.dispose();
super.dispose();
}

@override
Widget build(BuildContext context) {
SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle(
Expand Down
9 changes: 3 additions & 6 deletions example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ publish_to: 'none'
version: 1.0.0+1

environment:
sdk: '>=3.0.1 <4.0.0'
sdk: '>=3.2.0 <4.0.0'

dependencies:
flutter:
sdk: flutter
cupertino_icons: ^1.0.2
flutter_sliding_box: ^1.1.3
flutter_sliding_box: ^1.1.4
flutter_map: ^4.0.0
latlong2: ^0.8.0

Expand All @@ -19,10 +19,7 @@ dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints: ^2.0.0

screenshots:
- description: 'Examples of the sliding box on Android.'
path: sliding_box_demo.webp


flutter:
uses-material-design: true
Expand Down
9 changes: 4 additions & 5 deletions lib/src/flutter_sliding_box.dart
Original file line number Diff line number Diff line change
Expand Up @@ -259,14 +259,13 @@ class _SlidingBoxState extends State<SlidingBox> with TickerProviderStateMixin {
_backdropWidth = (widget.backdrop?.width != null)
? widget.backdrop!.width!
: MediaQuery.of(context).size.width;
return WillPopScope(
onWillPop: () {
return PopScope(
canPop: !_isSearchBoxVisible,
onPopInvoked: (_) {
/// handle app back button when [BackdropAppBar.searchBox] shows
if (_isSearchBoxVisible) {
widget.controller!.hideSearchBox();
return Future.value(false);
}
return Future.value(true);
},
child: Stack(
alignment: Alignment.bottomCenter,
Expand Down Expand Up @@ -1297,7 +1296,7 @@ Future<T?> showSlidingBox<T>({
}

Widget _slidingBoxModal(BuildContext context, SlidingBox box) {
BoxController controller = BoxController();
BoxController controller = box.controller ?? BoxController();
Future.delayed(
Duration.zero, () => controller.isAttached ? controller.openBox() : null);
return Material(
Expand Down
7 changes: 5 additions & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
name: flutter_sliding_box
version: 1.1.3
version: 1.1.4
repository: https://github.com/shirvanie/flutter_sliding_box/tree/master/
issue_tracker: https://github.com/shirvanie/flutter_sliding_box/issues
homepage: https://github.com/shirvanie/flutter_sliding_box
description: A draggable flutter widget (like bottom sheet panel) that makes it easier to use a SlidingBox for all platform.
email: ihamedshirvani@gmail.com

environment:
sdk: '>=3.0.1 <4.0.0'
sdk: '>=3.2.0 <4.0.0'

dependencies:
flutter:
Expand All @@ -17,6 +17,9 @@ dev_dependencies:
flutter_test:
sdk: flutter

screenshots:
- description: 'Example of the sliding box on Android.'
path: sliding_box_demo.webp

flutter:
uses-material-design: true
File renamed without changes

0 comments on commit 13feab9

Please sign in to comment.