Skip to content

Commit 89ca6f6

Browse files
committed
Add build in layouts
1、Add some awsome transaction 2、�Support outer pagination
1 parent 44fe89b commit 89ca6f6

24 files changed

+2175
-888
lines changed

Diff for: .idea/libraries/Dart_Packages.xml

+8-8
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: .idea/workspace.xml

+350-329
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: CHANGELOG-ZH.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,7 @@
3636
* 新增中文文档
3737
* 更新依赖包:infinity_page_view 版本到 1.0.0
3838

39-
39+
## [1.0.0] - [2018/07/08]
40+
* 增加布局方式( DEFAULT,STACK,TINDER )
41+
* 可以将分页指示器放在容器外面
4042

Diff for: CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@
3939
## [0.0.9] - [2018/06/10]
4040
* Add ci
4141
* Add testcase
42+
43+
## [1.0.0] - [2018/07/08]
44+
* Add layouts ( DEFAULT,STACK,TINDER )
45+
* Allow to put pagination outer of the swiper container.
46+
4247

4348

4449

Diff for: README-ZH.md

+73-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,19 @@
55

66
# flutter_swiper
77

8-
flutter最强大的siwiper
8+
flutter最强大的siwiper, 多种布局方式,无限轮播,Android和IOS双端适配.
9+
10+
11+
# :sparkles::sparkles: 新功能
12+
13+
14+
![](https://github.com/jzoom/images/raw/master/layout1.gif)
15+
16+
![](https://github.com/jzoom/images/raw/master/layout2.gif)
17+
18+
![](https://github.com/jzoom/images/raw/master/layout3.gif)
19+
20+
[更多](#内建的布局)
921

1022

1123
# 截图
@@ -35,8 +47,9 @@ flutter最强大的siwiper
3547
- [x] 可定制控制按钮
3648
- [x] 可定制分页
3749
- [x] 自动播放
38-
- [ ] 修正bug
3950
- [x] 控制器
51+
- [x] 外部分页指示器
52+
- [ ] 更多布局方式
4053

4154

4255
## 更新日志
@@ -53,7 +66,7 @@ flutter最强大的siwiper
5366
+ [控制按钮](#控制按钮)
5467
+ [控制器](#控制器)
5568
+ [自动播放](#自动播放)
56-
69+
+ [内建的布局](#内建的布局)
5770

5871
### 安装
5972

@@ -217,3 +230,60 @@ new Swiper(
217230
| autoplayDiableOnInteraction | true | 当用户拖拽的时候,是否停止自动播放. |
218231

219232

233+
234+
## 内建的布局
235+
![](https://github.com/jzoom/images/raw/master/layout1.gif)
236+
237+
```
238+
Swiper(
239+
itemBuilder: (BuildContext context, int index) {
240+
return new Image.network(
241+
"http://via.placeholder.com/288x188",
242+
fit: BoxFit.fill,
243+
);
244+
},
245+
itemCount: 10,
246+
viewportFraction: 0.8,
247+
scale: 0.9,
248+
)
249+
250+
```
251+
252+
253+
254+
![](https://github.com/jzoom/images/raw/master/layout2.gif)
255+
256+
```
257+
Swiper(
258+
itemBuilder: (BuildContext context, int index) {
259+
return new Image.network(
260+
"http://via.placeholder.com/288x188",
261+
fit: BoxFit.fill,
262+
);
263+
},
264+
itemCount: 10,
265+
itemWidth: 300.0,
266+
layout: SwiperLayout.STACK,
267+
)
268+
```
269+
270+
![](https://github.com/jzoom/images/raw/master/layout3.gif)
271+
272+
```
273+
Swiper(
274+
itemBuilder: (BuildContext context, int index) {
275+
return new Image.network(
276+
"http://via.placeholder.com/288x188",
277+
fit: BoxFit.fill,
278+
);
279+
},
280+
itemCount: 10,
281+
itemWidth: 300.0,
282+
itemHeight: 400.0,
283+
layout: SwiperLayout.TINDER,
284+
)
285+
```
286+
287+
这里可以找到所有的定制选项
288+
289+
>https://github.com/jzoom/flutter_swiper/blob/master/example/lib/src/ExampleCustom.dart

Diff for: README.md

+74-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,22 @@ language : [English](https://github.com/jzoom/flutter_swiper) | [中文](https:/
66

77
# flutter_swiper
88

9-
The best swiper for flutter.
9+
The best swiper for flutter , with multiple layouts, infinite loop. Compatible with Android & iOS.
10+
11+
12+
# :sparkles::sparkles: New Features:Layout
13+
14+
15+
![](https://github.com/jzoom/images/raw/master/layout1.gif)
16+
17+
![](https://github.com/jzoom/images/raw/master/layout2.gif)
18+
19+
![](https://github.com/jzoom/images/raw/master/layout3.gif)
20+
21+
[See More](#build-in-layouts)
22+
23+
24+
# Showcases
1025

1126
![Horizontal](https://github.com/jzoom/flutter_swiper/raw/master/example/res/1.gif)
1227

@@ -37,6 +52,7 @@ The best swiper for flutter.
3752
+ [Control buttons](#control-buttons)
3853
+ [Controller](#controller)
3954
+ [Autoplay](#autoplay)
55+
- [Build in layouts](#build-in-layouts)
4056

4157

4258
### Installation
@@ -201,3 +217,60 @@ The `Controller` is used to control the `index` of the Swiper, start or stop aut
201217
| autoplayDiableOnInteraction | true | Disable autoplay when user drag. |
202218

203219

220+
## Build in layouts
221+
![](https://github.com/jzoom/images/raw/master/layout1.gif)
222+
223+
```
224+
Swiper(
225+
itemBuilder: (BuildContext context, int index) {
226+
return new Image.network(
227+
"http://via.placeholder.com/288x188",
228+
fit: BoxFit.fill,
229+
);
230+
},
231+
itemCount: 10,
232+
viewportFraction: 0.8,
233+
scale: 0.9,
234+
)
235+
236+
```
237+
238+
239+
240+
![](https://github.com/jzoom/images/raw/master/layout2.gif)
241+
242+
```
243+
Swiper(
244+
itemBuilder: (BuildContext context, int index) {
245+
return new Image.network(
246+
"http://via.placeholder.com/288x188",
247+
fit: BoxFit.fill,
248+
);
249+
},
250+
itemCount: 10,
251+
itemWidth: 300.0,
252+
layout: SwiperLayout.STACK,
253+
)
254+
```
255+
256+
![](https://github.com/jzoom/images/raw/master/layout3.gif)
257+
258+
```
259+
Swiper(
260+
itemBuilder: (BuildContext context, int index) {
261+
return new Image.network(
262+
"http://via.placeholder.com/288x188",
263+
fit: BoxFit.fill,
264+
);
265+
},
266+
itemCount: 10,
267+
itemWidth: 300.0,
268+
itemHeight: 400.0,
269+
layout: SwiperLayout.TINDER,
270+
)
271+
```
272+
273+
274+
You can find all custom options here:
275+
276+
>https://github.com/jzoom/flutter_swiper/blob/master/example/lib/src/ExampleCustom.dart

Diff for: ROADMAP.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@ V1
99
- [x] Custom control buttons
1010
- [x] Custom pagination
1111
- [x] Autoplay
12-
- [ ] Fix bugs
1312
- [x] Controler
13+
- [x] Set indicator outside
14+
- [ ] More layouts

0 commit comments

Comments
 (0)