You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
1.4 KiB
50 lines
1.4 KiB
import 'package:flutter/material.dart';
|
|
import 'package:provider/provider.dart';
|
|
import 'package:smartfit_app_mobile/common/colo_extension.dart';
|
|
import 'package:smartfit_app_mobile/modele/user.dart';
|
|
import 'package:smartfit_app_mobile/view/home/notification_view.dart';
|
|
|
|
class EnteteHomeView extends StatelessWidget {
|
|
const EnteteHomeView({Key? key}) : super(key: key);
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Row(
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
children: [
|
|
Column(
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
children: [
|
|
Text(
|
|
"Welcome,",
|
|
style: TextStyle(color: TColor.gray, fontSize: 12),
|
|
),
|
|
Text(
|
|
context.watch<User>().username,
|
|
style: TextStyle(
|
|
color: TColor.black,
|
|
fontSize: 20,
|
|
fontWeight: FontWeight.w700),
|
|
),
|
|
],
|
|
),
|
|
IconButton(
|
|
onPressed: () {
|
|
Navigator.push(
|
|
context,
|
|
MaterialPageRoute(
|
|
builder: (context) => const NotificationView(),
|
|
),
|
|
);
|
|
},
|
|
icon: Image.asset(
|
|
"assets/img/notification_active.png",
|
|
width: 25,
|
|
height: 25,
|
|
fit: BoxFit.fitHeight,
|
|
))
|
|
],
|
|
);
|
|
}
|
|
}
|