import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:flutter/material.dart';

class RowCounts extends StatelessWidget {
  final name;
  final int count;
  final Color c;
  RowCounts(this.name, this.count, this.c);
  @override
  Widget build(BuildContext context) {
    return Row(
      children: [
        dot(c),
        Padding(
            padding: EdgeInsets.only(top: 5, bottom: 5),
            child: Row(
              crossAxisAlignment: CrossAxisAlignment.start,
              children: [
                AppText(
                  name,
                  color: Colors.black,
                  textAlign: TextAlign.center,
                  fontSize: 12,
                  textOverflow: TextOverflow.ellipsis,
                ),
                AppText(
                  ' (' + count.toString() + ')',
                  color: Colors.black,
                  textAlign: TextAlign.center,
                  fontSize: 14,
                  fontWeight: FontWeight.bold,
                )
              ],
            )),
      ],
    );
  }

  Widget dot(Color c) {
    return Container(
        padding: EdgeInsets.all(5.0),
        margin: EdgeInsets.all(5.0),
        decoration: BoxDecoration(color: c, shape: BoxShape.circle));
  }
}
