fix: view forwarded dyn

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-02-16 22:00:55 +08:00
parent a48d262637
commit 5dd3ff32b6
7 changed files with 81 additions and 83 deletions

View File

@@ -162,37 +162,38 @@ Widget forWard(item, context, source, callback, {floor = 1}) {
// 文章
case 'DYNAMIC_TYPE_ARTICLE':
return switch (item) {
ItemOrigModel() => articlePanel(item, context, callback, floor: floor),
DynamicItemModel() => item.modules?.moduleDynamic?.major?.blocked !=
null
? Padding(
padding: const EdgeInsets.symmetric(horizontal: 12),
child: Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (item.modules?.moduleDynamic?.major?.blocked?['title'] !=
null)
Text(
'${item.modules?.moduleDynamic?.major?.blocked!['title']}',
style: TextStyle(
color: Theme.of(context).colorScheme.secondary,
),
),
if (item.modules?.moduleDynamic?.major
?.blocked?['hint_message'] !=
null)
Text(
'${item.modules?.moduleDynamic?.major?.blocked!['hint_message']}',
style: TextStyle(
fontSize: 12,
color: Theme.of(context).colorScheme.outline,
),
)
],
),
)
: const SizedBox.shrink(),
DynamicItemModel() => item.isForwarded == true
? articlePanel(item, context, callback, floor: floor)
: item.modules?.moduleDynamic?.major?.blocked != null
? Padding(
padding: const EdgeInsets.symmetric(horizontal: 12),
child: Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (item.modules?.moduleDynamic?.major
?.blocked?['title'] !=
null)
Text(
'${item.modules?.moduleDynamic?.major?.blocked!['title']}',
style: TextStyle(
color: Theme.of(context).colorScheme.secondary,
),
),
if (item.modules?.moduleDynamic?.major
?.blocked?['hint_message'] !=
null)
Text(
'${item.modules?.moduleDynamic?.major?.blocked!['hint_message']}',
style: TextStyle(
fontSize: 12,
color: Theme.of(context).colorScheme.outline,
),
)
],
),
)
: const SizedBox.shrink(),
_ => const SizedBox.shrink(),
};
// return Container(