KonectarEvents/lib/widgets/customhcpcard.dart

63 lines
1.6 KiB
Dart

import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:konectar_events/utils/util.dart';
class CustomHcpCard extends StatelessWidget {
const CustomHcpCard({super.key});
@override
Widget build(BuildContext context) {
return Container(
width: isTablet
? MediaQuery.of(context).size.width / 2
: MediaQuery.of(context).size.width,
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
CircleAvatar(
child: Icon(
Icons.person,
color: Colors.black,
),
),
SizedBox(
width: 10,
),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Rabe, Klaus F.',
style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold),
),
_hcpdetails(Icons.star, 'Pulmonary Disease'),
_hcpdetails(Icons.school, 'LungenClinic Grosshansdorf'),
_hcpdetails(Icons.location_on, 'Germany'),
_hcpdetails(Icons.location_on, 'Ahrensburg')
],
)
],
),
);
}
_hcpdetails(IconData iconData, String title) {
return Row(
children: [
Icon(
iconData,
size: isTablet ? 18 : 14,
color: const Color.fromARGB(255, 77, 77, 77),
),
SizedBox(
width: 5,
),
Text(
title,
style: TextStyle(fontSize: isTablet ? 18 : 14, color: Colors.grey),
)
],
);
}
}