42 lines
1.1 KiB
Dart
42 lines
1.1 KiB
Dart
import 'package:a1_aufgabenverwaltung/components/user_icon_element.dart';
|
|
import 'package:a1_aufgabenverwaltung/models/User.dart';
|
|
import 'package:flutter/material.dart';
|
|
|
|
class TitleBarUserInfo extends StatelessWidget {
|
|
const TitleBarUserInfo({super.key, required this.user, });
|
|
|
|
final User user;
|
|
|
|
static const signedInTextColor = Color(0xFF64748B);
|
|
static const usernameColor = Color(0xFFE2E8F0);
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Row(
|
|
children: [
|
|
Text(
|
|
"Angemeldet als",
|
|
style: TextStyle(
|
|
color: signedInTextColor,
|
|
fontWeight: FontWeight(400),
|
|
fontSize: 11,
|
|
),
|
|
),
|
|
|
|
Padding(
|
|
padding: const EdgeInsets.symmetric(horizontal: 8),
|
|
child: UserIconElement(initials: user.initials, userColor: user. userColor),
|
|
),
|
|
|
|
Text(
|
|
user.fullName,
|
|
style: TextStyle(
|
|
color: usernameColor,
|
|
fontWeight: FontWeight(600),
|
|
fontSize: 11,
|
|
),
|
|
)
|
|
],
|
|
);
|
|
}
|
|
} |