style block scroll onesala app

 Container(

        height: 300,

        color: Colors.white,

        child:ListView.builder(

          scrollDirection: Axis.horizontal,

          shrinkWrap: true,

          physics: ScrollPhysics(),

          itemCount: 15,

          itemBuilder: (BuildContext context, int index) {

            return Container(

              width: 200,

              margin: const EdgeInsets.all(15.0),

              padding: const EdgeInsets.all(3.0),

              decoration: BoxDecoration(

                color: Colors.white60,

                border: Border.all(

                    width: 2.0

                ),

                borderRadius: BorderRadius.all(

                    Radius.circular(0.0) //                 <--- border radius here

                ),

              ),

              child: Stack(

                children: <Widget>[

                  Column(

                    crossAxisAlignment: CrossAxisAlignment.start,

                    children: <Widget>[

                      Image(

                        fit: BoxFit.cover,

                        width: MediaQuery.of(context).size.width,

                        // height: 90.0,

                        image: AssetImage('assets/images/no_photo_available.png'),

                      ),

                      Text("Author",textAlign: TextAlign.start,),

                      Text("Lorem Ipsum Author",textAlign: TextAlign.start,style: TextStyle(fontSize: 18,fontWeight: FontWeight.w700),),


                      Row(

                        children: <Widget>[

                          Icon(Icons.star,color: Colors.amberAccent,),

                          Icon(Icons.star,color: Colors.amberAccent,),

                          Icon(Icons.star,color: Colors.amberAccent,),

                          Icon(Icons.star,color: Colors.amberAccent,),

                          Icon(Icons.star_half,color: Colors.amberAccent,),

                        ],

                      ),

                      Row(

                        crossAxisAlignment: CrossAxisAlignment.end,

                        children: <Widget>[

                          Text("\$24",textAlign: TextAlign.end,),

                          Text("19.9",textAlign: TextAlign.end,style: TextStyle(color: Colors.redAccent,fontSize: 16,fontWeight: FontWeight.w700),),

                          Text("/5 month",textAlign: TextAlign.end,),

                        ],

                      ),

                    ],


                  ),

                  Positioned(

                    top: 80,

                    left: 80,

                    child: Container(


                      width: 100,

                      height: 40,

                      color: Colors.black12,

                      child: Text('20293',textAlign: TextAlign.center,),

                    ),

                  ),

                ],

              )

            );

          }

        ),


      ),

Comments