mirror of
https://github.com/simon-ding/polaris.git
synced 2026-06-09 11:39:46 +08:00
chore: change ui
This commit is contained in:
@@ -48,49 +48,28 @@ class WelcomePage extends ConsumerWidget {
|
|||||||
SizedBox(
|
SizedBox(
|
||||||
width: 130,
|
width: 130,
|
||||||
height: 195,
|
height: 195,
|
||||||
child: ClipRRect(
|
child: Image.network(
|
||||||
borderRadius: BorderRadius.circular(8.0),
|
"${APIs.imagesUrl}/${item.id}/poster.jpg",
|
||||||
child: Stack(
|
fit: BoxFit.fill,
|
||||||
alignment: AlignmentDirectional.topEnd,
|
headers: APIs.authHeaders,
|
||||||
children: [
|
|
||||||
Image.network(
|
|
||||||
"${APIs.imagesUrl}/${item.id}/poster.jpg",
|
|
||||||
fit: BoxFit.fill,
|
|
||||||
headers: APIs.authHeaders,
|
|
||||||
),
|
|
||||||
Padding(
|
|
||||||
padding: const EdgeInsets.all(10),
|
|
||||||
child: () {
|
|
||||||
if (item.mediaType == "tv") {
|
|
||||||
return Text("");
|
|
||||||
}
|
|
||||||
var icon = const CircleAvatar(
|
|
||||||
radius: 12,
|
|
||||||
backgroundColor: Colors.black12,
|
|
||||||
child: Icon(
|
|
||||||
Icons.access_time_rounded,
|
|
||||||
color: Colors.blue,
|
|
||||||
size: 24,
|
|
||||||
),
|
|
||||||
);
|
|
||||||
if (item.status == "downloaded") {
|
|
||||||
icon = const CircleAvatar(
|
|
||||||
radius: 12,
|
|
||||||
backgroundColor: Colors.black12,
|
|
||||||
child: Icon(
|
|
||||||
Icons.done_rounded,
|
|
||||||
color: Colors.green,
|
|
||||||
size: 24,
|
|
||||||
),
|
|
||||||
);
|
|
||||||
}
|
|
||||||
return icon;
|
|
||||||
}(),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
SizedBox(
|
||||||
|
width: 130,
|
||||||
|
child: () {
|
||||||
|
if (item.mediaType == "movie" &&
|
||||||
|
item.status == "downloaded") {
|
||||||
|
return const LinearProgressIndicator(
|
||||||
|
value: 1,
|
||||||
|
color: Colors.green,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return const LinearProgressIndicator(
|
||||||
|
value: 1,
|
||||||
|
color: Colors.blue,
|
||||||
|
);
|
||||||
|
}(),
|
||||||
|
),
|
||||||
Text(
|
Text(
|
||||||
item.name!,
|
item.name!,
|
||||||
style: const TextStyle(
|
style: const TextStyle(
|
||||||
|
|||||||
Reference in New Issue
Block a user