refactor: 重构页面路由结构与积分页面UI,优化列表交互体验

1. 重构路由结构:将班级子页移出ShellBranch,解决tabbar遮挡问题
2. 统一修改全局"没有更多了"提示文案为带品牌标识的版本
3. 重构积分排行榜UI,修复切换状态时的布局抖动问题,替换图标为CDN资源
4. 重构我的积分页面:对齐Vue端UI设计,新增展开收起详情功能,优化背景与布局
5. 优化我的互动页面布局与样式,新增背景图支持
This commit is contained in:
崔宝新
2026-09-08 13:42:10 +08:00
parent 3a2b589e37
commit 2aa1927694
9 changed files with 515 additions and 170 deletions
+41 -8
View File
@@ -174,7 +174,11 @@ class _PointRankViewState extends ConsumerState<PointRankView> {
? Colors.white
: Colors.white.withValues(alpha: 0.5),
borderRadius: BorderRadius.circular(8.r),
border: active ? null : Border.all(color: Colors.white, width: 1),
// 始终保留 1px border 占位,避免激活/未激活切换时 content 区域差 2px 抖动
border: Border.all(
color: active ? Colors.transparent : Colors.white,
width: 1,
),
),
// Web 端回退字体行高偏大,固定高度可能溢出 → 内容放不下时自动缩小
child: FittedBox(
@@ -190,7 +194,7 @@ class _PointRankViewState extends ConsumerState<PointRankView> {
color: active ? _primary : const Color(0xFF687FAD),
),
),
SizedBox(height: 4.h),
// SizedBox(height: 0.5.h),
Text(
'$countText人',
style: TextStyle(
@@ -202,7 +206,14 @@ class _PointRankViewState extends ConsumerState<PointRankView> {
),
),
),
if (active) _buildTriangle(),
// 始终渲染三角形占位,visible 切换避免外层 Column 高度变化抖动
Visibility(
visible: active,
maintainSize: true,
maintainAnimation: true,
maintainState: true,
child: _buildTriangle(),
),
],
),
);
@@ -338,11 +349,7 @@ class _PointRankViewState extends ConsumerState<PointRankView> {
),
),
SizedBox(width: 5.w),
Icon(
_sortDesc ? Icons.arrow_downward : Icons.arrow_upward,
size: 14,
color: _primary,
),
_buildSortIcons(),
],
),
),
@@ -351,6 +358,32 @@ class _PointRankViewState extends ConsumerState<PointRankView> {
);
}
Widget _buildSortIcons() {
final up = _sortDesc
? '/StaticResource/2026-07-29/reverseOrder_up_icon1785291938907.png'
: '/StaticResource/2026-07-29/properOrder_up_icon1785291938906.png';
final down = _sortDesc
? '/StaticResource/2026-07-29/reverseOrder_down_icon1785291938905.png'
: '/StaticResource/2026-07-29/properOrder_down_icon1785291938907.png';
return Column(
mainAxisSize: MainAxisSize.min,
children: [
CachedNetworkImage(
imageUrl: ImgUrl.build(up),
width: 12.w,
height: 7.h,
fit: BoxFit.contain,
),
CachedNetworkImage(
imageUrl: ImgUrl.build(down),
width: 12.w,
height: 7.h,
fit: BoxFit.contain,
),
],
);
}
Widget _buildMyRankCard() {
final rank = _myRank!;
return Container(