Skip to content

๐Ÿ‚ฑ [WIP] A Flutter package to implement smooth swipeable playing card like-widgets

License

Notifications You must be signed in to change notification settings

ninest/swipeable_card

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

93 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Swipeable Card (v1.x.x)

Add swipeable card-like widgets for games or interactive onboarding screens

Pub PRs Welcome lic BMAC

Contents

๐ŸŽฎ Examples

Demo

SwipeableWidget (meant for high performance devices, like iPhones)

Demo 1

SwipeableWidgetSlide (meant for lower performance devices, like older Android devices)

  • Demo of SwipeableWidgetSlide to be added

Check the repository if you're unable to see the demo.

App examples

Swipeable Widget is used in the following apps:

  • Shots
  • Create a PR to add your own!

Installation

Add swipeable_card to your pubspec.yaml:

dependencies:
  flutter:
    sdk: flutter

  # added below
  swipeable_card: <latest version>

Adding to your app

The swipeable widget has to be placed in a Column (or Row), for example:

Column(
  children: <Widget>[
    SwipeableWidget(
      // parameters ...
      child: someChildWidget(),
    ),
  ],
)

In the above example, replace someChildWidget() with the widget that can be swiped (for example, a playing card-like widget).

Warning: while SwipeableWidget is fast on iPhones, it can be quite slow for older Android devices. I am currently working on SwipeableWidgetSlide, an alternative which can be used for older Android devices.

Check out https://swipeable-card.now.sh/ for the full documentation (still a work in progress).

๐Ÿ˜ Issues and limitations

If you use the a swipeableWidgetController to automatically swipe the cards (without the user panning), you can only start swiping the next card away when the previous one is fully swiped away. To see a demo, run the example, and continuously tap the "Left" button at the bottom of the screen.

Apart from that, all the other problems from v0.0.x seem to be dealth with.

License

BSD 2-clause

๐Ÿ“ Other information

Project start date: 1 May, 2020.

About

๐Ÿ‚ฑ [WIP] A Flutter package to implement smooth swipeable playing card like-widgets

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages