import 'package:flutter/material.dart'; import 'package:zhiying_comm/zhiying_comm.dart'; import 'package:flutter_swiper/flutter_swiper.dart'; class HomeBanner extends StatelessWidget { final Map model; const HomeBanner(this.model, {Key key}) : super(key: key); @override Widget build(BuildContext context) { return Container( width: double.infinity, height: 200, child: Swiper( itemBuilder: (BuildContext context, int index) { // return new Image.network( // "http://via.placeholder.com/350x150", // fit: BoxFit.fill, // ); return Container(); }, itemCount: 3, pagination: new SwiperPagination(), control: new SwiperControl(), onTap: (index) { print(model.toString()); }, ), ); } }