Skip to content

Commit cc8b9d2

Browse files
committed
Update README
1 parent ee3eb06 commit cc8b9d2

File tree

3 files changed

+42
-20
lines changed

3 files changed

+42
-20
lines changed

README.md

Lines changed: 32 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,37 @@
1-
# show_up_animation
1+
# show_up_animation [![Build Status](https://travis-ci.com/ashutoshsingh05/show_up_animation.svg?branch=master)](https://travis-ci.com/ashutoshsingh05/show_up_animation)
22

3-
A new Flutter package project.
3+
A flutter package to simplify implementation of "show up" animation in flutter
44

55
## Getting Started
66

7-
This project is a starting point for a Dart
8-
[package](https://flutter.dev/developing-packages/),
9-
a library module containing code that can be shared easily across
10-
multiple Flutter or Dart projects.
7+
Install dependencies
118

12-
For help getting started with Flutter, view our
13-
[online documentation](https://flutter.dev/docs), which offers tutorials,
14-
samples, guidance on mobile development, and a full API reference.
9+
```yaml
10+
dependencies:
11+
show_up_animation: ^0.0.1
12+
```
13+
14+
Then import wherever you want to implement the animation
15+
16+
```dart
17+
import 'package:show_up_animation/show_up_animation.dart';
18+
```
19+
20+
Wrap any widget you want to animate inside `ShowUpAnimation` widget and provide a `Duration()` to `delayStart` field to control after how much delay the animation fires.
21+
22+
## Properties
23+
24+
You can customize how to do you want to animate your `child` using the parameters described below.
25+
26+
| Property | Function |
27+
| ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
28+
| child | The widget on which to apply the given `ShowUpAnimation` |
29+
| offset | The offset by which to slide and [child] into view from [Direction]. Use negative value to reverse animation [direction]. Defaults to 0.2 |
30+
| curve | The curve used to animate the [child] into view. Defaults to [Curves.easeIn] |
31+
| direction | horizontal or vertical |
32+
| delayStart | The delay with which to animate the [child]. Takes in a [Duration] and defaults to 0 seconds |
33+
| animationDuration | The total duration in which the animation completes. Defaults to 800 milliseconds |
34+
35+
## Examples
36+
37+
![videotogif_2020 04 21_19 44 01](https://user-images.githubusercontent.com/42690541/79876554-d2d4fd00-8408-11ea-9b8e-550954f618f3.gif)

lib/show_up_animation.dart

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,27 @@ import 'package:flutter/material.dart';
88
enum Direction { vertical, horizontal }
99

1010
class ShowUpAnimation extends StatefulWidget {
11-
///The child on which to apply the given [ShowUpAnimation]
11+
/// The child on which to apply the given [ShowUpAnimation]
1212
final Widget child;
1313

14-
///The offset by which to slide and [child] into view from [Direction].
15-
///Defaults to 0.2
14+
/// The offset by which to slide and [child] into view from [Direction].
15+
/// Use negative value to reverse animation [direction].Defaults to 0.2
1616
final double offset;
1717

18-
///The curve used to animate the [child] into view.
19-
///Defaults to [Curves.easeIn]
18+
/// The curve used to animate the [child] into view.
19+
/// Defaults to [Curves.easeIn]
2020
final Curve curve;
2121

22-
///The direction from which to animate the [child] into view. [Direction.horizontal]
23-
///will make the child slide on x-axis by [offset] and [Direction.vertical] on y-axis.
24-
///Defaults to [Direction.vertical]
22+
/// The direction from which to animate the [child] into view. [Direction.horizontal]
23+
/// will make the child slide on x-axis by [offset] and [Direction.vertical] on y-axis.
24+
/// Defaults to [Direction.vertical]
2525
final Direction direction;
2626

27-
///The delay with which to animate the [child]. Takes in a [Duration] and
27+
/// The delay with which to animate the [child]. Takes in a [Duration] and
2828
/// defaults to 0.0 seconds
2929
final Duration delayStart;
3030

31-
///The total duration in which the animation completes. Defaults to 800 milliseconds
31+
/// The total duration in which the animation completes. Defaults to 800 milliseconds
3232
final Duration animationDuration;
3333

3434
ShowUpAnimation({

pubspec.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: show_up_animation
22
description: A flutter package to simplify implementation of "show up" animation in flutter
33
version: 0.0.1
4-
author: Ashutosh Singh<201851029@iiitvadodara.ac.in>
54
homepage: https://github.com/ashutoshsingh05/show_up_animation
65

76
environment:

0 commit comments

Comments
 (0)