Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Support page transitions #22

Closed
Closed
@mehmetf

Description

@mehmetf

Right now I do page transitions via something like this:

  void forward(UINode newContent) {
    setState(() {
      _content = newContent;
    });
  }

  UINode build() {
    List<UINode> overlays = [];
    addMenuToOverlays(overlays);
    _scaffold = new Scaffold(
      header: _isSearching ? buildSearchBar() : buildActionBar(),
      content: _content,
      fab: new FloatingActionButton(
        content: new Icon(type: 'content/add_white', size: 24), level: 3),
      drawer: buildDrawer(),
      overlays: overlays
    );
    return _scaffold;
  }

Then passing the app object around. This is very rudimentary. It would be great if we could inject some sort of router to the components so they can request a page transition. Angular does this via defining routes on dart.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions