v0.1.0scroll_snap_effect
一个用于创建简单滚动吸附效果的 Flutter 包
26喜欢 16近 30 天下载150Pub 分数
AndroidiOSWebmacOSWindowsLinux
一个用于在 ListView 中创建简单动画滚动吸附效果的 Flutter 包
以下为英文项目原文快照,最新内容请访问 GitHub。
A Flutter package to create easy animation scroll snap effect in ListView
// Example itemSize
// itemSize = child width (ex: 100) + child padding (ex: 16);
// itemSize = 116
ScrollSnapEffect(
itemSize: 116,
itemCount: 15,
padding: const EdgeInsets.symmetric(horizontal: 20),
onChanged: (index) {
debugPrint('$index');
},
itemBuilder: (context, index) {
return Padding(
padding: const EdgeInsets.only(right: 16),
child: SizedBox(
height: 100,
width: 100,
child: ColoredBox(
color: Colors.blue,
child: Center(
child: Text(
'$index',
style: const TextStyle(
color: Colors.white,
fontSize: 20,
),
),
),
),
),
);
},
),
Farhan Fadila
📫 How to reach me: farhan.fadila1717@gmail.com
依赖清单 3 项
{"sdk":"flutter"}{"sdk":"flutter"}^1.0.0先按使用场景筛选,再比较项目活跃情况,最后到原始仓库核对使用要求。
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗
