import 'package:cs_resources/generated/assets.dart';
import 'package:flutter/material.dart';
import 'package:flutter/widgets.dart';
import 'package:shared/utils/color_utils.dart';
import 'package:widgets/my_load_image.dart';
import 'package:widgets/my_text_view.dart';

// 'id':1,
// 'avator': Assets.communityCamera,
// 'title': 'William Jefferson',
// 'isFollow': false,
// 'content': 'She said YES and our lives changed.Thank you all for coming to my propose today.We hope everyone can ……[More]',
// 'imageUrls': ['https://img.alicdn.com/tfs/TB1h.o9O4MPMeJjy1XaXXcSsFXa-640-360.jpg','https://img.alicdn.com/tfs/TB1h.o9O4MPMeJjy1XaXXcSsFXa-640-360.jpg','https://img.alicdn.com/tfs/TB1h.o9O4MPMeJjy1XaXXcSsFXa-640-360.jpg'],
// 'time': 'June 17,2016 at 7:23 p.m.',
// 'likeno': 12

class NewsFeedCardFooter extends StatelessWidget {
  final bool isLike;
  final VoidCallback? onLike;
  final VoidCallback? onComment;
  final VoidCallback? onShare;

  const NewsFeedCardFooter({
    Key? key,
    required this.isLike,
    this.onLike,
    this.onComment,
    this.onShare
  })
  : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Container(
      height: 40,
      width: double.infinity,
      padding: const EdgeInsets.symmetric(horizontal: 16),
      // color: Colors.red,
      child: Expanded(
        child:  Row(
          mainAxisAlignment: MainAxisAlignment.spaceBetween,
          children: [
            Row(
              children: [
                const MyAssetImage(Assets.communityLike, width: 16,height: 16,),
                MyTextView(
                  'Like',
                  textColor: ColorUtils.string2Color('#767676'),
                  fontSize: 14,
                  isFontRegular: true,
                  textAlign: TextAlign.left,
                  marginLeft: 8,
                ),
              ],
            ),
            Row(
              children: [
                const MyAssetImage(Assets.communityComments, width: 16,height: 16,),
                MyTextView(
                  'Comments',
                  textColor: ColorUtils.string2Color('#767676'),
                  fontSize: 14,
                  isFontRegular: true,
                  textAlign: TextAlign.left,
                  marginLeft: 8,
                ),
              ],
            ),
            Row(
              children: [
                const MyAssetImage(Assets.communityShare, width: 16,height: 16,),
                MyTextView(
                  'Share',
                  textColor: ColorUtils.string2Color('#767676'),
                  fontSize: 14,
                  isFontRegular: true,
                  textAlign: TextAlign.left,
                  marginLeft: 8,
                ),
              ],
            ),
          ]
        ),
      )
    );
  }
}