updated chat images loading animation
This commit is contained in:
parent
6651613331
commit
70e6f82b10
@ -36,8 +36,8 @@ class ChatMessage {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return CachedNetworkImage(
|
return Padding(padding: const EdgeInsets.only(top: 5), child: CachedNetworkImage(
|
||||||
errorWidget: (context, url, error) => Padding(padding: const EdgeInsets.only(top: 10), child: Row(
|
errorWidget: (context, url, error) => Row(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
crossAxisAlignment: CrossAxisAlignment.center,
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
@ -46,14 +46,14 @@ class ChatMessage {
|
|||||||
Flexible(child: Text(file!.name, maxLines: 2, overflow: TextOverflow.ellipsis, style: const TextStyle(fontWeight: FontWeight.bold))),
|
Flexible(child: Text(file!.name, maxLines: 2, overflow: TextOverflow.ellipsis, style: const TextStyle(fontWeight: FontWeight.bold))),
|
||||||
const SizedBox(width: 10),
|
const SizedBox(width: 10),
|
||||||
],
|
],
|
||||||
)),
|
),
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
placeholder: (context, url) => const Padding(padding: EdgeInsets.all(10), child: CircularProgressIndicator()),
|
placeholder: (context, url) => const Padding(padding: EdgeInsets.all(15), child: SizedBox(width: 50, child: LinearProgressIndicator())),
|
||||||
fadeInDuration: Duration.zero,
|
fadeInDuration: Duration.zero,
|
||||||
fadeOutDuration: Duration.zero,
|
fadeOutDuration: Duration.zero,
|
||||||
errorListener: (value) {},
|
errorListener: (value) {},
|
||||||
imageUrl: 'https://${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().full()}/index.php/core/preview?fileId=${file!.id}&x=100&y=-1&a=1',
|
imageUrl: 'https://${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().full()}/index.php/core/preview?fileId=${file!.id}&x=100&y=-1&a=1',
|
||||||
);
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<void> onOpen(LinkableElement link) async {
|
Future<void> onOpen(LinkableElement link) async {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user