Merge branch 'krille/send-events-design' into 'main'
design: Display icon for failed sent messages See merge request famedly/fluffychat!813
This commit is contained in:
commit
cb8ede3daa
|
@ -112,17 +112,21 @@ class Message extends StatelessWidget {
|
||||||
sameSender || ownMessage
|
sameSender || ownMessage
|
||||||
? SizedBox(
|
? SizedBox(
|
||||||
width: Avatar.defaultSize,
|
width: Avatar.defaultSize,
|
||||||
child: event.status == EventStatus.sending
|
child: Padding(
|
||||||
? Center(
|
padding: const EdgeInsets.only(top: 8.0),
|
||||||
|
child: Center(
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
width: 16 * AppConfig.bubbleSizeFactor,
|
width: 16 * AppConfig.bubbleSizeFactor,
|
||||||
height: 16 * AppConfig.bubbleSizeFactor,
|
height: 16 * AppConfig.bubbleSizeFactor,
|
||||||
child: const CircularProgressIndicator.adaptive(
|
child: event.status == EventStatus.sending
|
||||||
strokeWidth: 2),
|
? const CircularProgressIndicator.adaptive(
|
||||||
),
|
strokeWidth: 2)
|
||||||
)
|
: event.status == EventStatus.error
|
||||||
|
? const Icon(Icons.error, color: Colors.red)
|
||||||
: null,
|
: null,
|
||||||
)
|
),
|
||||||
|
),
|
||||||
|
))
|
||||||
: Avatar(
|
: Avatar(
|
||||||
mxContent: event.sender.avatarUrl,
|
mxContent: event.sender.avatarUrl,
|
||||||
name: event.sender.calcDisplayname(),
|
name: event.sender.calcDisplayname(),
|
||||||
|
|
Loading…
Reference in New Issue