Flutter Tweenme banner
mrgoonie mrgoonie

Flutter Tweenme

Development community

Description

A tween library plugin package for Flutter project, inspired from GreenSock TweenMax

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

TweenMe for Flutter

A tween library framework for Flutter project, inspired from TweenMax (https://greensock.com/).

https://www.youtube.com/watch?v=5bfqgPPCdjA

![alt text](https://raw.githubusercontent.com/mrgoonie/flutter_tweenme/master/logo.jpg "TweenMe for Flutter")

Introduction

If you're a Javascript or Actionscript developer, you probably know **TweenMax** - this is an awesome tween library developed by GreenSock team, which have a huge support for doing animation.

Animated Widgets in Flutter are great, but I find them not very familiar and customizable. Since TweenMax hasn't been available for Flutter, so I tried to write an alternative version - I named it **TweenMe**!

Installation

  1. Depend on it Add this to your package's pubspec.yaml file:
dependencies:
  tweenme: ^0.1.4
  1. Install it You can install packages from the command line:

with Flutter:

`$ flutter packages get`

Alternatively, your editor might support flutter packages get. Check the docs for your editor to learn more.

  1. Import it Now in your Dart code, you can use:

`import 'package:tweenme/tweenme.dart';`

Important notes:

Firstly, you need to be aware of **TweenContainer**, this is an universal widget. **TweenMe** can only apply to **TweenContainer**.

**TweenContainer** can be placed within any widgets in the widget tree of your app. But if put it inside a **FlexRenderContainer** (such as Row, Column), then you tween the value of positions (such as "top", "left",..), it won't work!

How to use:

TweenContainer tweenableContainer = TweenContainer(
  // initial data:
  data: TweenData(
    width: 100,
    height: 100,
    color: Colors.red
  ),
  // child: Text("Hello")
);

// plug this container into your widget tree:
// ...
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Stack(
        children: [
          tweenableContainer,

          Align(
                  alignment: Alignment.bottomCenter,
            child: Fla