Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-05-18 16:56:43 +08:00
parent f642bfcf48
commit ab80b2a5af
24 changed files with 876 additions and 871 deletions

View File

@@ -25,49 +25,44 @@ class _FavSearchPageState extends CommonSearchPageState<FavSearchPage,
@override
Widget buildList(List<FavDetailItemData> list) {
return SliverPadding(
padding: EdgeInsets.only(
bottom: MediaQuery.of(context).padding.bottom + 80,
),
sliver: SliverGrid(
gridDelegate: Grid.videoCardHDelegate(context, minHeight: 110),
delegate: SliverChildBuilderDelegate(
childCount: list.length,
(context, index) {
if (index == list.length - 1) {
controller.onLoadMore();
}
final item = list[index];
return FavVideoCardH(
videoItem: item,
onDelFav: controller.isOwner == true
? () {
controller.onCancelFav(
index,
item.id!,
item.type,
);
}
: null,
onViewFav: () {
PageUtils.toVideoPage(
'bvid=${item.bvid}&cid=${item.cid}',
arguments: {
'videoItem': item,
'heroTag': Utils.makeHeroTag(item.bvid),
'sourceType': 'fav',
'mediaId': controller.mediaId,
'oid': item.id,
'favTitle': controller.title,
'count': controller.count,
'desc': true,
'isContinuePlaying': true,
},
);
},
);
},
),
return SliverGrid(
gridDelegate: Grid.videoCardHDelegate(context, minHeight: 110),
delegate: SliverChildBuilderDelegate(
childCount: list.length,
(context, index) {
if (index == list.length - 1) {
controller.onLoadMore();
}
final item = list[index];
return FavVideoCardH(
videoItem: item,
onDelFav: controller.isOwner == true
? () {
controller.onCancelFav(
index,
item.id!,
item.type,
);
}
: null,
onViewFav: () {
PageUtils.toVideoPage(
'bvid=${item.bvid}&cid=${item.cid}',
arguments: {
'videoItem': item,
'heroTag': Utils.makeHeroTag(item.bvid),
'sourceType': 'fav',
'mediaId': controller.mediaId,
'oid': item.id,
'favTitle': controller.title,
'count': controller.count,
'desc': true,
'isContinuePlaying': true,
},
);
},
);
},
),
);
}