Wrap(
crossAxisAlignment: WrapCrossAlignment.start,
alignment: WrapAlignment.start,
spacing: 20.w,
runSpacing: 20.w,
children: List.generate(_buttonList.length ?? 0, (index) {
return GestureDetector(
child: Chip(label: Text('${_buttonList[index]}',style: TextStyle(fontSize: setFontSize(28),color: _selectPosition==index?JadeColors.blue_2:JadeColors.grey),),
backgroundColor: _selectPosition==index?JadeColors.lightBlue:JadeColors.lightGrey,),
onTap: () {
_selectPosition = index;
_httpImageList();
setState(() {});
},
);
}),
)
flutter Wrap+Chip
最新推荐文章于 2024-09-03 17:27:58 发布