CPD/a1_aufgabenverwaltung/lib/components/title_bar_user_info.dart

43 lines
1.1 KiB
Dart

import 'package:a1_aufgabenverwaltung/components/user_icon_element.dart';
import 'package:flutter/material.dart';
class TitleBarUserInfo extends StatelessWidget {
const TitleBarUserInfo({super.key, required this.name, required this.initials, required this.userColor});
final String name;
final String initials;
final Color userColor;
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: initials, userColor: userColor),
),
Text(
name,
style: TextStyle(
color: usernameColor,
fontWeight: FontWeight(600),
fontSize: 11,
),
)
],
);
}
}