|
|
@@ -101,23 +101,20 @@ class CustomBannerWidget extends StatelessWidget { |
|
|
|
CustomBannerListStyle right1 = listStyle.firstWhere((element) => element.locationType == 'right1'); |
|
|
|
CustomBannerListStyle right2 = listStyle.firstWhere((element) => element.locationType == 'right2'); |
|
|
|
if (EmptyUtil.isEmpty(left1) || EmptyUtil.isEmpty(right1) || EmptyUtil.isEmpty(right2)) return Container(); |
|
|
|
|
|
|
|
return IntrinsicHeight( |
|
|
|
child: Row( |
|
|
|
children: <Widget>[ |
|
|
|
// Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: _buildSingleWidthWidget(context, left1)), |
|
|
|
Flexible( |
|
|
|
flex: 1, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right2), child: CachedNetworkImage(imageUrl: right2?.img ?? ''))), |
|
|
|
], |
|
|
|
), |
|
|
|
return Row( |
|
|
|
children: <Widget>[ |
|
|
|
// Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: _buildSingleWidthWidget(context, left1)), |
|
|
|
Flexible( |
|
|
|
flex: 1, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right2), child: CachedNetworkImage(imageUrl: right2?.img ?? ''))), |
|
|
|
], |
|
|
|
), |
|
|
|
], |
|
|
|
), |
|
|
|
), |
|
|
|
], |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
@@ -127,22 +124,20 @@ class CustomBannerWidget extends StatelessWidget { |
|
|
|
CustomBannerListStyle left2 = listStyle.firstWhere((element) => element.locationType == 'left2'); |
|
|
|
CustomBannerListStyle right1 = listStyle.firstWhere((element) => element.locationType == 'right1'); |
|
|
|
if (EmptyUtil.isEmpty(left1) || EmptyUtil.isEmpty(right1) || EmptyUtil.isEmpty(left2)) return Container(); |
|
|
|
return IntrinsicHeight( |
|
|
|
child: Row( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible( |
|
|
|
flex: 1, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left2), child: CachedNetworkImage(imageUrl: left2?.img ?? ''))), |
|
|
|
], |
|
|
|
), |
|
|
|
return Row( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible( |
|
|
|
flex: 1, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, left2), child: CachedNetworkImage(imageUrl: left2?.img ?? ''))), |
|
|
|
], |
|
|
|
), |
|
|
|
// Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: _buildSingleWidthWidget(context, right1)), |
|
|
|
], |
|
|
|
), |
|
|
|
), |
|
|
|
// Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: _buildSingleWidthWidget(context, right1)), |
|
|
|
], |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
@@ -154,27 +149,25 @@ class CustomBannerWidget extends StatelessWidget { |
|
|
|
CustomBannerListStyle right3 = listStyle.firstWhere((element) => element.locationType == 'right3'); |
|
|
|
if (EmptyUtil.isEmpty(left1) || EmptyUtil.isEmpty(right1) || EmptyUtil.isEmpty(right2) || EmptyUtil.isEmpty(right3)) return Container(); |
|
|
|
|
|
|
|
return IntrinsicHeight( |
|
|
|
child: Row( |
|
|
|
children: <Widget>[ |
|
|
|
// Flexible(flex: 4, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: _buildSingleWidthWidget(context, left1)), |
|
|
|
Flexible( |
|
|
|
flex: 6, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Row( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right2), child: CachedNetworkImage(imageUrl: right2?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right3), child: CachedNetworkImage(imageUrl: right3?.img ?? ''))), |
|
|
|
], |
|
|
|
) |
|
|
|
], |
|
|
|
), |
|
|
|
) |
|
|
|
], |
|
|
|
), |
|
|
|
return Row( |
|
|
|
children: <Widget>[ |
|
|
|
// Flexible(flex: 4, child: GestureDetector(onTap: () => _itemOnClick(context, left1), child: CachedNetworkImage(imageUrl: left1?.img ?? ''))), |
|
|
|
Flexible(flex: 4, child: _buildSingleWidthWidget(context, left1)), |
|
|
|
Flexible( |
|
|
|
flex: 6, |
|
|
|
child: Column( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right1), child: CachedNetworkImage(imageUrl: right1?.img ?? ''))), |
|
|
|
Row( |
|
|
|
children: <Widget>[ |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right2), child: CachedNetworkImage(imageUrl: right2?.img ?? ''))), |
|
|
|
Flexible(flex: 1, child: GestureDetector(onTap: () => _itemOnClick(context, right3), child: CachedNetworkImage(imageUrl: right3?.img ?? ''))), |
|
|
|
], |
|
|
|
) |
|
|
|
], |
|
|
|
), |
|
|
|
) |
|
|
|
], |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|