buildCopyItem method
Implementation
Widget buildCopyItem(Key key, String itemTitle, String itemDetail) {
return Container(
height: 56,
color: Colors.white,
padding: EdgeInsets.symmetric(horizontal: 20),
alignment: Alignment.center,
child: Row(
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Expanded(
child: Text.rich(
TextSpan(children: [
TextSpan(
text: itemTitle,
style: TextStyle(
fontSize: 16, color: UIColors.black_222222)),
TextSpan(
text: ' $itemDetail',
style: TextStyle(
fontSize: 16, color: UIColors.color_999999))
]),
softWrap: false,
overflow: TextOverflow.fade)),
GestureDetector(
key: key,
child: Text(Strings.copy,
style: TextStyle(fontSize: 14, color: UIColors.blue_337eff)),
onTap: () {
Clipboard.setData(ClipboardData(text: itemDetail));
ToastUtils.showToast(context, Strings.copySuccess);
},
),
],
),
);
}