【发布时间】:2022-12-18 14:20:18
【问题描述】:
我想制作与照片中相同的滑块。什么是圆形按钮。我使用了 flutter_slidable 插件,但它不起作用或者我做错了什么?
下面是我试图做的代码
Slidable(
endActionPane: ActionPane(
motion: const DrawerMotion(),
children: [
SlidableAction(
onPressed: (BuildContext context) {},
borderRadius:
BorderRadius.all(Radius.circular(180)),
backgroundColor: const Color(0xFFFE4A49),
foregroundColor: Colors.white,
icon: Icons.delete,
),
SlidableAction(
onPressed: (BuildContext context) {},
borderRadius: BorderRadius.circular(180),
backgroundColor: const Color(0xFFFE4A49),
foregroundColor: Colors.white,
icon: Icons.delete,
),
],
),
child: ListTile(
title: Text("Text",
style: const TextStyle(fontSize: 18)),
subtitle: Text("Text2"),
onTap: () {
}));
【问题讨论】:
-
什么不起作用?向我们展示您尝试过的代码
-
@Nitish,我补充说