Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-06-13 11:49:38 +08:00
parent f824477ddb
commit c05fbde3fa
106 changed files with 2780 additions and 3200 deletions

View File

@@ -19,86 +19,89 @@ class SearchPgcItem extends StatelessWidget {
Widget build(BuildContext context) {
final ThemeData theme = Theme.of(context);
const TextStyle style = TextStyle(fontSize: 13);
return InkWell(
onTap: () => PageUtils.viewPgc(seasonId: item.seasonId),
onLongPress: () => imageSaveDialog(
title: item.title.map((item) => item.text).join(),
cover: item.cover,
),
child: Padding(
padding: const EdgeInsets.symmetric(
horizontal: StyleString.safeSpace,
vertical: StyleString.cardSpace,
return Material(
type: MaterialType.transparency,
child: InkWell(
onTap: () => PageUtils.viewPgc(seasonId: item.seasonId),
onLongPress: () => imageSaveDialog(
title: item.title.map((item) => item.text).join(),
cover: item.cover,
),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Stack(
clipBehavior: Clip.none,
children: [
NetworkImgLayer(
width: 111,
height: 148,
src: item.cover,
),
PBadge(
text: item.seasonTypeName,
top: 6.0,
right: 4.0,
bottom: null,
left: null,
)
],
),
const SizedBox(width: 10),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
child: Padding(
padding: const EdgeInsets.symmetric(
horizontal: StyleString.safeSpace,
vertical: StyleString.cardSpace,
),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Stack(
clipBehavior: Clip.none,
children: [
const SizedBox(height: 4),
Text.rich(
TextSpan(
children: item.title
.map((e) => TextSpan(
text: e.text,
style: TextStyle(
color: e.isEm
? theme.colorScheme.primary
: theme.colorScheme.onSurface,
),
))
.toList()),
),
const SizedBox(height: 12),
Text('评分:${item.mediaScore?['score']}', style: style),
Row(
children: [
if (item.areas?.isNotEmpty == true)
Text(item.areas!, style: style),
const SizedBox(width: 3),
const Text('·'),
const SizedBox(width: 3),
Text(
Utils.dateFormat(item.pubtime).toString(),
style: style,
),
],
),
Row(
children: [
if (item.styles?.isNotEmpty == true)
Text(item.styles!, style: style),
const SizedBox(width: 3),
const Text('·'),
const SizedBox(width: 3),
if (item.indexShow?.isNotEmpty == true)
Text(item.indexShow!, style: style),
],
NetworkImgLayer(
width: 111,
height: 148,
src: item.cover,
),
PBadge(
text: item.seasonTypeName,
top: 6.0,
right: 4.0,
bottom: null,
left: null,
)
],
),
),
],
const SizedBox(width: 10),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const SizedBox(height: 4),
Text.rich(
TextSpan(
children: item.title
.map((e) => TextSpan(
text: e.text,
style: TextStyle(
color: e.isEm
? theme.colorScheme.primary
: theme.colorScheme.onSurface,
),
))
.toList()),
),
const SizedBox(height: 12),
Text('评分:${item.mediaScore?['score']}', style: style),
Row(
children: [
if (item.areas?.isNotEmpty == true)
Text(item.areas!, style: style),
const SizedBox(width: 3),
const Text('·'),
const SizedBox(width: 3),
Text(
Utils.dateFormat(item.pubtime).toString(),
style: style,
),
],
),
Row(
children: [
if (item.styles?.isNotEmpty == true)
Text(item.styles!, style: style),
const SizedBox(width: 3),
const Text('·'),
const SizedBox(width: 3),
if (item.indexShow?.isNotEmpty == true)
Text(item.indexShow!, style: style),
],
),
],
),
),
],
),
),
),
);