Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

flutter fragment transaction

a simple fragment transaction effect in flutter.

getting started

add this to your package’s pubspec.yaml file:

dependencies:
  flutter_fragments: ^0.02

example

default effect

class fragmentsdemo extends statefulwidget {
  static final string title = "fragments";

  @override
  _fragmentsdemostate createstate() => _fragmentsdemostate();
}

class _fragmentsdemostate extends state<fragmentsdemo> {
  fragmentscontroller controller = fragmentscontroller();
  offset startingoffset = offset.zero;

  @override
  widget build(buildcontext context) {
    return scaffold(
      body: center(
        child: gesturedetector(
          ontapup: (tapupdetails detail) {
            setstate(() {
              startingoffset = detail.localposition;
            });
            controller.start();
          },
          child: container(
            width: 300,
            height: 300,
            child: fragments(
              fragmentscontroller: controller,
              startingoffset: startingoffset,
              delegate: defaultfragmentsdraw(disabletransition: true),
              child: const fragmentsexample(),
            ),
          ),
        ),
      ),
    );
  }
}

fragment transaction

transition effects.

fragments(
  fragmentscontroller: controller,
  startingoffset: startingoffset,
  duration: duration(milliseconds: 3000),
  child: const fragmentsexample(),
),

demo2--1-

number of custom fragment

fragments(
  fragmentscontroller: controller,
  startingoffset: startingoffset,
  duration: duration(milliseconds: 3000),
  delegate: defaultfragmentsdraw(rowlength: 25, columnlength: 25),
  child: const fragmentsexample(),
),

Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

Top