我正在为search and review cart页面设置bool条件,然后我面临这3个我试图解决但未成功的错误(容器上的前2个错误//预计会找到",".//无法将元素类型"bool"分配给列表类型"Widget".)以及文本小部件上的第二个小部件(预期会找到"]")
bool isBool = false;
SigleItem(this.isBool);
isBool ==false Container( //Expected to find ','. //The element type 'bool' can't be assigned to the list type 'Widget'.
margin: const EdgeInsets.only(right: 15),
padding: const EdgeInsets.symmetric(horizontal: 10),
height: 35,
decoration: BoxDecoration(
border: Border.all(color: Colors.grey),
borderRadius: BorderRadius.circular(30),
),
child: Row(
children: [
const Expanded(
child: Text(
'RS-799',
style: TextStyle(
color: Colors.grey,
),
),
),
Center(
child: Icon(
Icons.arrow_drop_down,
size: 20,
color: primaryColor,
),
),
],
),
):Text('750')//Expected to find ']'.