chore: Adjust status header design

This commit is contained in:
krille-chan 2025-09-14 12:33:19 +02:00
commit 9224a7aea4
No known key found for this signature in database

View file

@ -150,10 +150,21 @@ class PresenceAvatar extends StatelessWidget {
borderRadius: borderRadius:
BorderRadius.circular(avatarSize), BorderRadius.circular(avatarSize),
), ),
child: Avatar( alignment: Alignment.center,
name: displayName, child: Container(
mxContent: profile?.avatarUrl, height: avatarSize - 6,
size: avatarSize - 6, alignment: Alignment.center,
decoration: BoxDecoration(
color: theme.colorScheme.surface,
borderRadius:
BorderRadius.circular(avatarSize),
),
padding: const EdgeInsets.all(3.0),
child: Avatar(
name: displayName,
mxContent: profile?.avatarUrl,
size: avatarSize - 12,
),
), ),
), ),
if (presence.userid == client.userID) if (presence.userid == client.userID)
@ -184,57 +195,68 @@ class PresenceAvatar extends StatelessWidget {
left: 0, left: 0,
top: 0, top: 0,
right: 8, right: 8,
child: Material( child: Column(
elevation: statusMsgBubbleElevation, spacing: 2,
shadowColor: statusMsgBubbleShadowColor, crossAxisAlignment:
borderRadius: BorderRadius.circular( CrossAxisAlignment.start,
AppConfig.borderRadius / 2, mainAxisSize: MainAxisSize.min,
), children: [
color: statusMsgBubbleColor, Material(
child: Padding( elevation: statusMsgBubbleElevation,
padding: const EdgeInsets.all(2.0), shadowColor: statusMsgBubbleShadowColor,
child: Text( borderRadius: BorderRadius.circular(
statusMsg, AppConfig.borderRadius / 2,
maxLines: 2, ),
overflow: TextOverflow.ellipsis, color: statusMsgBubbleColor,
style: const TextStyle( child: Padding(
color: Colors.black, padding: const EdgeInsets.symmetric(
fontSize: 9, vertical: 2.0,
horizontal: 4.0,
),
child: Text(
statusMsg,
maxLines: 2,
overflow: TextOverflow.ellipsis,
style: const TextStyle(
color: Colors.black,
fontSize: 9,
),
),
), ),
), ),
), Padding(
), padding:
), const EdgeInsets.only(left: 8.0),
Positioned( child: Material(
left: 8, color: statusMsgBubbleColor,
top: 32, elevation: statusMsgBubbleElevation,
child: Material( shadowColor:
color: statusMsgBubbleColor, statusMsgBubbleShadowColor,
elevation: statusMsgBubbleElevation, borderRadius: BorderRadius.circular(
shadowColor: statusMsgBubbleShadowColor, AppConfig.borderRadius,
borderRadius: BorderRadius.circular( ),
AppConfig.borderRadius / 2, child: const SizedBox.square(
), dimension: 8,
child: const SizedBox( ),
width: 8, ),
height: 8, ),
), Padding(
), padding:
), const EdgeInsets.only(left: 13.0),
Positioned( child: Material(
left: 14, color: statusMsgBubbleColor,
top: 40, elevation: statusMsgBubbleElevation,
child: Material( shadowColor:
color: statusMsgBubbleColor, statusMsgBubbleShadowColor,
elevation: statusMsgBubbleElevation, borderRadius: BorderRadius.circular(
shadowColor: statusMsgBubbleShadowColor, AppConfig.borderRadius,
borderRadius: BorderRadius.circular( ),
AppConfig.borderRadius / 2, child: const SizedBox.square(
), dimension: 5,
child: const SizedBox( ),
width: 4, ),
height: 4, ),
), ],
), ),
), ),
], ],