Skip to content

Commit

Permalink
More readme updates
Browse files Browse the repository at this point in the history
  • Loading branch information
pulyaevskiy committed Feb 20, 2018
1 parent f785c9e commit 22a7bfe
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# parallax_image

Parallax image widget for Flutter.
A Flutter widget that paints an image and moves it at a slower speed than the main scrolling content.

![demo.gif](demo.gif)

Expand Down Expand Up @@ -34,16 +34,18 @@ class MyWidgetState extends State<MyWidget> {
children: <Widget>[
new ParallaxImage(
controller: _controller,
image: new AssetImage('images/some.jpg'),
image: new AssetImage('images/january.jpg'),
// Extent of this widget in scroll direction.
// In this case it is vertical scroll so it defines
// the height of this widget.
// In this case it is vertical scroll so extent defines
// the height of this widget.
// The image is scaled with BoxFit.fitWidth which makes it
// occupy full width of this widget.
// Scaled image should normally have height greater
// After image is scaled it should normally have height greater
// than this value to allow for parallax effect to be
// visible.
extent: 100.0,
// Optionally specify child widget.
child: new Text('January'),
),
// ...add more list items
]
Expand Down
4 changes: 2 additions & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ dependencies:
flutter:
sdk: flutter

dev_dependencies:
test: ^0.12.0
# dev_dependencies:
# test: ^0.12.0

0 comments on commit 22a7bfe

Please sign in to comment.