mirror of
https://github.com/stonega/tsacdop
synced 2025-01-07 04:41:12 +01:00
Fixed fireside host load error.
This commit is contained in:
parent
5d1c9a8ec1
commit
7e2d340713
@ -228,7 +228,14 @@ class _PodcastDetailState extends State<PodcastDetail> {
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: hosts
|
||||
.map((host) => Container(
|
||||
.map<Widget>((host) {
|
||||
final image = host.image ==
|
||||
"http://xuanmei.us/assets/default/avatar_small-"
|
||||
"170afdc2be97fc6148b283083942d82c101d4c1061f6b28f87c8958b52664af9.jpg"
|
||||
? "https://fireside.fm/assets/default/avatar_small"
|
||||
"-170afdc2be97fc6148b283083942d82c101d4c1061f6b28f87c8958b52664af9.jpg"
|
||||
: host.image;
|
||||
return Container(
|
||||
padding: EdgeInsets.all(5.0),
|
||||
width: 80.0,
|
||||
child: Column(
|
||||
@ -237,15 +244,14 @@ class _PodcastDetailState extends State<PodcastDetail> {
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: <Widget>[
|
||||
CachedNetworkImage(
|
||||
imageUrl: host.image,
|
||||
imageUrl: image,
|
||||
progressIndicatorBuilder:
|
||||
(context, url,
|
||||
downloadProgress) =>
|
||||
SizedBox(
|
||||
width: 40,
|
||||
height: 2,
|
||||
child:
|
||||
LinearProgressIndicator(
|
||||
child: LinearProgressIndicator(
|
||||
value:
|
||||
downloadProgress
|
||||
.progress),
|
||||
@ -262,7 +268,8 @@ class _PodcastDetailState extends State<PodcastDetail> {
|
||||
hostImage) =>
|
||||
CircleAvatar(
|
||||
backgroundColor:
|
||||
Colors.grey[400],
|
||||
Colors
|
||||
.grey[400],
|
||||
backgroundImage:
|
||||
hostImage),
|
||||
),
|
||||
@ -272,7 +279,8 @@ class _PodcastDetailState extends State<PodcastDetail> {
|
||||
Text(
|
||||
host.name,
|
||||
style: TextStyle(
|
||||
backgroundColor: Colors.black
|
||||
backgroundColor: Colors
|
||||
.black
|
||||
.withOpacity(0.5),
|
||||
color: Colors.white,
|
||||
),
|
||||
@ -281,10 +289,10 @@ class _PodcastDetailState extends State<PodcastDetail> {
|
||||
overflow: TextOverflow.fade,
|
||||
),
|
||||
],
|
||||
)))
|
||||
));
|
||||
})
|
||||
.toList()
|
||||
.cast<Widget>(),
|
||||
),
|
||||
.cast<Widget>()),
|
||||
),
|
||||
)),
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user