Bon checkpoint + refactoring

This commit is contained in:
DahoudG
2024-11-02 22:37:47 +00:00
parent 9cf96b7acf
commit 19f6efa995
27 changed files with 684 additions and 499 deletions

View File

@@ -0,0 +1,49 @@
import 'package:flutter/material.dart';
import '../../../../core/constants/colors.dart';
import '../../../../domain/entities/user.dart';
class UserInfoCard extends StatelessWidget {
final User user;
const UserInfoCard({Key? key, required this.user}) : super(key: key);
@override
Widget build(BuildContext context) {
return Card(
color: AppColors.cardColor,
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(10)),
elevation: 2,
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
children: [
CircleAvatar(
radius: 50,
backgroundImage: NetworkImage(user.profileImageUrl),
backgroundColor: Colors.transparent,
),
const SizedBox(height: 10),
Text(
'${user.userFirstName} ${user.userLastName}',
style: const TextStyle(
fontSize: 24,
fontWeight: FontWeight.bold,
color: Colors.white,
letterSpacing: 1.2,
),
),
const SizedBox(height: 5),
Text(
user.email,
style: TextStyle(
fontSize: 14,
color: Colors.grey[600],
decoration: TextDecoration.underline,
),
),
],
),
),
);
}
}