Coder Social home page Coder Social logo

kannel-outis / backdrop Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fluttercommunity/backdrop

0.0 0.0 0.0 5.46 MB

Backdrop implementation in flutter.

Home Page: https://pub.dev/packages/backdrop

License: Other

Java 0.94% Objective-C 1.94% Dart 97.12%

backdrop's Introduction

Flutter Community: backdrop

backdrop

Demo Gitter All Contributors pub.dev pub points popularity likes analysis GitHub issues GitHub milestone GitHub stars GitHub forks Gitlab stars Gitlab forks

Backdrop implementation in flutter.

This widget is in active development. Any contribution, idea, criticism or feedback is welcomed.

Quick links

package https://pub.dev/packages/backdrop
Git Repo https://github.com/fluttercommunity/backdrop
Issue Tracker https://github.com/fluttercommunity/backdrop/issues
Chat Room https://gitter.im/flutter-backdrop

Getting started

Follow the medium article to Quickly Implement Backdrop in Flutter.

Usage

BackdropScaffold

Use BackdropScaffold instead of the standard Scaffold in your app. A backLayer and a frontLayer have to be defined for the backdrop to work.

BackdropScaffold(
  appBar: BackdropAppBar(
    title: Text("Backdrop Example"),
    actions: <Widget>[
      BackdropToggleButton(
        icon: AnimatedIcons.list_view,
      )
    ],
  ),
  backLayer: Center(
    child: Text("Back Layer"),
  ),
  frontLayer: Center(
    child: Text("Front Layer"),
  ),
)
BackdropScaffold example

Navigation with backdrop

To use backdrop for navigation, use the provided BackdropNavigationBackLayer as backLayer.

The BackdropNavigationBackLayer contains a property items representing the list elements shown on the back layer. The front layer has to be "manually" set depending on the current index, which can be accessed with the onTap callback.

int _currentIndex = 0;
final List<Widget> _pages = [Widget1(), Widget2()];

@override
Widget build(BuildContext context) {
  return MaterialApp(
    title: 'Backdrop Demo',
    home: BackdropScaffold(
      appBar: BackdropAppBar(
        title: Text("Navigation Example"),
        actions: <Widget>[
          BackdropToggleButton(
            icon: AnimatedIcons.list_view,
          )
        ],
      ),
      stickyFrontLayer: true,
      frontLayer: _pages[_currentIndex],
      backLayer: BackdropNavigationBackLayer(
        items: [
          ListTile(title: Text("Widget 1")),
          ListTile(title: Text("Widget 2")),
        ],
        onTap: (int position) => {setState(() => _currentIndex = position)},
      ),
    ),
  );
}
BackdropNavigationScaffold example

For more information, check out sample code in the example directory

Contribute

Check proposal documents for v1.0 and web&desktop milestones before you begin with any contibution.

  1. You'll need a GitHub account.
  2. Fork the repository.
  3. Pick an issue to work on from issue tracker.
  4. Implement it.
  5. Add your name and email in authors section in pubspec.yaml file.
  6. Send merge request.
  7. Star this project.
  8. Become a hero!!

Features and bugs

Please file feature requests and bugs at the issue tracker.

Contributors ✨

Thanks goes to these wonderful people (emoji key):


Harsh Bhikadia

πŸ’» πŸ€”πŸ‘€

Felix Wielander

πŸ’» πŸ“–πŸ›πŸ‘€

Bringmos

πŸ›

Greg Spencer

πŸ›

Jorge A Peroza M

πŸ’»πŸ›

Matt Newell

πŸ›

Daniel Borges

πŸ’»πŸ›

Felix Wortmann

πŸ’»πŸ‘€

Pierre Grimaud

πŸ“–

Π’Π°Π΄ΠΈΠΌ

πŸ’»

Danial Agh

πŸ›

PembaTamang

πŸ›

hassan

πŸ›

Yaroslav Pronin

πŸ›

This project follows the all-contributors specification. Contributions of any kind welcome!

backdrop's People

Contributors

allcontributors[bot] avatar daadu avatar danielborges93 avatar kannel-outis avatar pgrimaud avatar vlytvyne avatar wiefel avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.