Skip to content

A Flutter package supports full screen swipe back gesture.

License

Notifications You must be signed in to change notification settings

CyrilHu/full_screen_back_gesture

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

full_screen_back_gesture

A Flutter package supports full screen swipe back gesture, without scrolling conflicts.

Features

  • full screen swipe back gesture instead of edge swipe
  • will not block horizontal scroll gesture of Scrollable widgets

Usage

Option 1 (Recommended)

When you use MaterialPageRoute for Navigator, you can custom page transitions,

Sets pageTransitionsTheme for MaterialApp theme.

MaterialApp(
  theme: ThemeData(
    pageTransitionsTheme: PageTransitionsTheme(
      builders: {
        TargetPlatform.android: FullScreenBackGesturePageTransitionsBuilder(),
        TargetPlatform.iOS: FullScreenBackGesturePageTransitionsBuilder(),
      },
    ),
  ),
);

Option 2

If you have to use CupertinoPageRoute for Navigator, import cupertino route form this package, There is only CupertinoPageRoute has been replaced.

import 'package:full_screen_back_gesture/cupertino.dart';

Navigator.of(context).push(CupertinoPageRoute(builder: (context) => MainPage())),

About

A Flutter package supports full screen swipe back gesture.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages