Open eggyot opened 2 years ago
how to hide side image if I only have 1 item? if not hide, so it's like have 3 item
I already try change to viewportFraction: 1 but it's change width to full width, I wan't change size width, only hide side image
see my image https://i.stack.imgur.com/JiEHG.png
this my code
Swiper( autoplay: true, itemBuilder: (BuildContext context, int index) { return InkWell( child: Card( margin: new EdgeInsets.only( bottom: 30 ), shape: RoundedRectangleBorder( borderRadius: BorderRadius .circular(20) ), child: ( ClipRRect( child: ( CachedNetworkImage( imageUrl: dataPromo[index].bannerPath, fit: BoxFit.fill, ) ) ) ) ), ); }, itemCount: dataPromo.length, viewportFraction: 0.8, scale: 0.9, ),
how to hide side image if I only have 1 item? if not hide, so it's like have 3 item
I already try change to viewportFraction: 1 but it's change width to full width, I wan't change size width, only hide side image
see my image https://i.stack.imgur.com/JiEHG.png
this my code