jonataslaw / readmore

A Flutter plugin than allow expand and collapse text dynamically
MIT License
257 stars 79 forks source link

Not rendering Text in Card #21

Open b14cknc0d3 opened 3 years ago

b14cknc0d3 commented 3 years ago

return Material( color: Colors.black26, // ignore: non_constant_identifier_names child: ListView.builder( itemCount: 10, itemBuilder: (BuildContext, context) { return Padding( padding: EdgeInsets.only(top: 1.h), child: Card( clipBehavior: Clip.antiAlias, child: SingleChildScrollView( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ ListTile( leading: CircleAvatar( child: CachedNetworkImage( imageUrl: "http://www.canada-work.com/_/rsrc/1531284300421/assistants/female_generic_profile.png", width: 80.0, height: 80.0, ), ), title: Text( "Harly", style: TextStyle(fontWeight: FontWeight.bold), ), subtitle: Row( children: [ Text("2 hours ago"), Padding( padding: EdgeInsets.only(left: 0.3.w), child: Icon(Icons.public, size: 15.0), ), ], ), trailing: IconButton( icon: Icon(Icons.more_vert), onPressed: () {}, ), ), **//Text("GGDSOPISDPOFPSDOPFDOPOFOD") // work.!but readmoretext not.** ReadMoreText( "GGWPasdfsfjksdfsdf[psdf[psdof[odf[p[pd[pfosd[pfo[pdf[pd", trimLines: 3, colorClickableText: Colors.pink, trimMode: TrimMode.Line, trimCollapsedText: 'Show more', trimExpandedText: 'Show less', // moreStyle: TextStyle( // fontSize: 14, fontWeight: FontWeight.bold), ), Divider(), ButtonBar( // buttonHeight: 0.1.h, alignment: MainAxisAlignment.spaceAround, children: [ TextButton.icon( onPressed: () {}, icon: Icon(Feather.thumbs_up), label: Text("like"), ), TextButton.icon( onPressed: () {}, icon: Icon(Feather.message_square), label: Text("comment"), ), // Spacer(), IconButton( icon: Icon(Feather.share_2, color: Colors.blue), onPressed: () {}), ], ), ], ), )), ); }), );