feat(reward): 新增客户端奖励中心
This commit is contained in:
1 parent
67670d46b1
commit
bea08110c9
68 files changed
+3987
-332
No files matched your search
@@ -58,9 +58,7 @@ class FollowingGridCard extends StatelessWidget {
|
||||
children: [
|
||||
Positioned.fill(
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(
|
||||
AppDimens.homeCardRadius,
|
||||
),
|
||||
borderRadius: BorderRadius.circular(AppDimens.coverRadius),
|
||||
child: RemoteImage(
|
||||
posterUrl,
|
||||
fit: BoxFit.cover,
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:flutter/material.dart';
|
||||
|
||||
import '../../core/theme/app_colors.dart';
|
||||
import '../../core/theme/app_dimens.dart';
|
||||
import '../../core/widgets/app_press_scale.dart';
|
||||
import '../../core/widgets/cover_play_count.dart';
|
||||
import '../../core/widgets/remote_image.dart';
|
||||
import '../../l10n/app_localizations.dart';
|
||||
@@ -45,15 +46,17 @@ class FollowingHistoryCard extends StatelessWidget {
|
||||
AppDimens.followingHistoryCoverRadius,
|
||||
),
|
||||
onTap: onTap,
|
||||
child: SizedBox(
|
||||
height: AppDimens.followingHistoryCoverHeight,
|
||||
child: Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
_cover(),
|
||||
const SizedBox(width: AppDimens.followingHistoryContentGap),
|
||||
Expanded(child: _details(l10n)),
|
||||
],
|
||||
child: AppPressScale(
|
||||
child: SizedBox(
|
||||
height: AppDimens.followingHistoryCoverHeight,
|
||||
child: Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
_cover(),
|
||||
const SizedBox(width: AppDimens.followingHistoryContentGap),
|
||||
Expanded(child: _details(l10n)),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
@@ -17,6 +17,7 @@ import '../../core/formatting/error_text.dart';
|
||||
import '../../core/theme/app_colors.dart';
|
||||
import '../../core/theme/app_dimens.dart';
|
||||
import '../../core/widgets/empty_state.dart';
|
||||
import '../../core/widgets/app_press_scale.dart';
|
||||
import '../../l10n/app_localizations.dart';
|
||||
import '../discover/search_page.dart';
|
||||
import '../player/open_player.dart';
|
||||
@@ -274,9 +275,9 @@ class _FollowingPageState extends State<FollowingPage> {
|
||||
key: const Key('following-search'),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
onTap: () {
|
||||
Navigator.of(context).push<void>(
|
||||
MaterialPageRoute(builder: (_) => const SearchPage()),
|
||||
);
|
||||
Navigator.of(
|
||||
context,
|
||||
).push<void>(MaterialPageRoute(builder: (_) => const SearchPage()));
|
||||
},
|
||||
child: Padding(
|
||||
padding: EdgeInsets.all(4),
|
||||
@@ -293,19 +294,21 @@ class _FollowingPageState extends State<FollowingPage> {
|
||||
return ValueListenableBuilder<bool>(
|
||||
valueListenable: _editing,
|
||||
builder: (context, editing, _) {
|
||||
return InkWell(
|
||||
key: const Key('following-edit'),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
onTap: _toggleEditing,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 2, vertical: 8),
|
||||
child: Text(
|
||||
editing ? l10n.done : l10n.manage,
|
||||
style: const TextStyle(
|
||||
color: AppColors.textPrimary,
|
||||
fontSize: AppDimens.followingManageFont,
|
||||
fontWeight: FontWeight.w400,
|
||||
height: 1.0,
|
||||
return AppPressScale(
|
||||
child: InkWell(
|
||||
key: const Key('following-edit'),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
onTap: _toggleEditing,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 2, vertical: 8),
|
||||
child: Text(
|
||||
editing ? l10n.done : l10n.manage,
|
||||
style: const TextStyle(
|
||||
color: AppColors.textPrimary,
|
||||
fontSize: AppDimens.followingManageFont,
|
||||
fontWeight: FontWeight.w400,
|
||||
height: 1.0,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
@@ -320,40 +323,40 @@ class _FollowingPageState extends State<FollowingPage> {
|
||||
String keyName,
|
||||
bool selected,
|
||||
) {
|
||||
return InkWell(
|
||||
key: Key('following-tab-$keyName'),
|
||||
onTap: () => _selectTab(tab),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
AnimatedDefaultTextStyle(
|
||||
duration: AppDimens.followingTabAnimationDuration,
|
||||
style: TextStyle(
|
||||
color: selected
|
||||
? AppColors.textPrimary
|
||||
: AppColors.textTabInactive,
|
||||
fontSize: AppDimens.followingSegmentFont,
|
||||
fontWeight: FontWeight.w400,
|
||||
return AppPressScale(
|
||||
child: InkWell(
|
||||
key: Key('following-tab-$keyName'),
|
||||
onTap: () => _selectTab(tab),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
AnimatedDefaultTextStyle(
|
||||
duration: AppDimens.followingTabAnimationDuration,
|
||||
style: TextStyle(
|
||||
color: selected
|
||||
? AppColors.textPrimary
|
||||
: AppColors.textTabInactive,
|
||||
fontSize: AppDimens.followingSegmentFont,
|
||||
fontWeight: FontWeight.w400,
|
||||
),
|
||||
child: label,
|
||||
),
|
||||
child: label,
|
||||
),
|
||||
const SizedBox(height: AppDimens.followingSegmentIndicatorTopGap),
|
||||
AnimatedContainer(
|
||||
duration: AppDimens.followingTabAnimationDuration,
|
||||
curve: Curves.easeOut,
|
||||
width: selected
|
||||
? AppDimens.followingSegmentIndicatorWidth
|
||||
: 0,
|
||||
height: AppDimens.followingSegmentIndicatorHeight,
|
||||
decoration: BoxDecoration(
|
||||
color: AppColors.brandRed,
|
||||
borderRadius: BorderRadius.circular(
|
||||
AppDimens.followingSegmentIndicatorRadius,
|
||||
const SizedBox(height: AppDimens.followingSegmentIndicatorTopGap),
|
||||
AnimatedContainer(
|
||||
duration: AppDimens.followingTabAnimationDuration,
|
||||
curve: Curves.easeOut,
|
||||
width: selected ? AppDimens.followingSegmentIndicatorWidth : 0,
|
||||
height: AppDimens.followingSegmentIndicatorHeight,
|
||||
decoration: BoxDecoration(
|
||||
color: AppColors.brandRed,
|
||||
borderRadius: BorderRadius.circular(
|
||||
AppDimens.followingSegmentIndicatorRadius,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user