Revert "chore: clean up"

This reverts commit 538494b7ec.
This commit is contained in:
bggRGjQaUbCoE
2025-04-20 18:04:06 +08:00
parent a5c7ec0d60
commit 6f4321ae14
90 changed files with 1814 additions and 493 deletions

View File

@@ -150,9 +150,11 @@ class ActionItemState extends State<ActionItem>
onTapDown: (details) => _isThumbsUp ? _startLongPress() : null,
onTapUp: (details) => _isThumbsUp ? _cancelLongPress() : null,
onTapCancel: () => _isThumbsUp ? _cancelLongPress(true) : null,
// borderRadius: StyleString.mdRadius,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
// const SizedBox(height: 2),
Stack(
alignment: Alignment.center,
children: [
@@ -229,6 +231,7 @@ class _ArcPainter extends CustomPainter {
);
const startAngle = -pi / 2;
// const sweepAngle = -2 * pi;
canvas.drawArc(rect, startAngle, sweepAngle, false, paint);
}

View File

@@ -147,6 +147,7 @@ class _FavPanelState extends State<FavPanel> {
);
}
} else {
// 骨架屏
return const Center(
child: CircularProgressIndicator(),
);

View File

@@ -152,6 +152,7 @@ class _GroupPanelState extends State<GroupPanel> {
);
}
} else {
// 骨架屏
return const Center(
child: CircularProgressIndicator(),
);

View File

@@ -67,14 +67,15 @@ class _PagesPanelState extends State<PagesPanel> {
if (!_scrollController.hasClients || pages.isEmpty) {
return;
}
const double itemWidth = 150;
const double itemWidth = 150; // 每个列表项的宽度
final double targetOffset = (pageIndex * itemWidth - itemWidth / 2).clamp(
_scrollController.position.minScrollExtent,
_scrollController.position.maxScrollExtent);
// 滑动至目标位置
_scrollController.animateTo(
targetOffset,
duration: const Duration(milliseconds: 300),
curve: Curves.easeInOut,
duration: const Duration(milliseconds: 300), // 滑动动画持续时间
curve: Curves.easeInOut, // 滑动动画曲线
);
}

View File

@@ -61,6 +61,9 @@ class _SeasonPanelState extends State<SeasonPanel> {
}
/// 取对应 season_id 的 episodes
// episodes = widget.ugcSeason.sections!
// .firstWhere((e) => e.seasonId == widget.ugcSeason.id)
// .episodes;
currentIndex.value = episodes.indexWhere(
(EpisodeItem e) => e.cid == _videoDetailController.seasonCid);
_listener = _videoDetailController.cid.listen((int cid) {
@@ -83,6 +86,17 @@ class _SeasonPanelState extends State<SeasonPanel> {
super.dispose();
}
// void changeFucCall(item, int i) async {
// await widget.changeFuc!(
// IdUtils.av2bv(item.aid),
// item.cid,
// item.aid,
// );
// currentIndex = i;
// Get.back();
// setState(() {});
// }
@override
Widget build(BuildContext context) {
if (episodes.isEmpty) {