mod
This commit is contained in:
@ -44,6 +44,8 @@ class _MinePageState extends State<MinePage>
|
||||
super.build(context);
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
scrolledUnderElevation: 0,
|
||||
elevation: 0,
|
||||
actions: [
|
||||
IconButton(
|
||||
icon: const Icon(Icons.search_outlined),
|
||||
@ -64,7 +66,16 @@ class _MinePageState extends State<MinePage>
|
||||
const SizedBox(width: 22),
|
||||
],
|
||||
),
|
||||
body: SingleChildScrollView(
|
||||
body: RefreshIndicator(
|
||||
onRefresh: () async {
|
||||
await ctr.queryUserInfo();
|
||||
},
|
||||
child: SingleChildScrollView(
|
||||
physics: const AlwaysScrollableScrollPhysics(
|
||||
parent: BouncingScrollPhysics()),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.only(bottom: 110),
|
||||
child: Expanded(
|
||||
child: Column(
|
||||
children: [
|
||||
Obx(() => _buildProfileSection(context, ctr.userInfo.value)),
|
||||
@ -119,6 +130,9 @@ class _MinePageState extends State<MinePage>
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@ -326,7 +340,7 @@ class _MinePageState extends State<MinePage>
|
||||
const SizedBox(height: 4),
|
||||
SizedBox(
|
||||
width: double.infinity,
|
||||
height: MediaQuery.textScalerOf(context).scale(110),
|
||||
height: MediaQuery.textScalerOf(context).scale(180),
|
||||
child: FutureBuilder(
|
||||
future: ctr.queryFavFolder(),
|
||||
builder: (context, snapshot) {
|
||||
@ -459,72 +473,42 @@ class FavFolderItem extends StatelessWidget {
|
||||
String heroTag = Utils.makeHeroTag(item!.fid);
|
||||
return Container(
|
||||
margin: EdgeInsets.only(left: index == 0 ? 20 : 0, right: 14),
|
||||
child: InkWell(
|
||||
onTap: () => Get.toNamed('/favDetail', arguments: item, parameters: {
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
InkWell(
|
||||
onTap: () =>
|
||||
Get.toNamed('/favDetail', arguments: item, parameters: {
|
||||
'mediaId': item!.id.toString(),
|
||||
'heroTag': heroTag,
|
||||
'isOwner': '1',
|
||||
}),
|
||||
borderRadius: StyleString.mdRadius,
|
||||
child: Stack(
|
||||
children: [
|
||||
NetworkImgLayer(
|
||||
child: Hero(
|
||||
tag: heroTag,
|
||||
child: NetworkImgLayer(
|
||||
src: item!.cover,
|
||||
width: 175,
|
||||
width: 180,
|
||||
height: 110,
|
||||
),
|
||||
// 渐变
|
||||
Positioned(
|
||||
left: 0,
|
||||
right: 0,
|
||||
top: 60,
|
||||
bottom: 0,
|
||||
child: Container(
|
||||
padding: const EdgeInsets.only(bottom: 8, left: 10, right: 2),
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: StyleString.mdRadius,
|
||||
gradient: LinearGradient(
|
||||
begin: Alignment.topCenter,
|
||||
end: Alignment.bottomCenter,
|
||||
colors: [
|
||||
Colors.black.withOpacity(0),
|
||||
Colors.black.withOpacity(0.6),
|
||||
],
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
children: [
|
||||
RichText(
|
||||
const SizedBox(height: 8),
|
||||
Text(
|
||||
' ${item!.title}',
|
||||
overflow: TextOverflow.fade,
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
text: TextSpan(
|
||||
),
|
||||
Text(
|
||||
' 共${item!.mediaCount}条视频',
|
||||
style: Theme.of(context)
|
||||
.textTheme
|
||||
.titleSmall!
|
||||
.copyWith(color: Colors.white),
|
||||
children: [
|
||||
TextSpan(text: item!.title!),
|
||||
const TextSpan(text: ' '),
|
||||
if (item!.mediaCount! > 0)
|
||||
TextSpan(
|
||||
text: item!.mediaCount!.toString(),
|
||||
style: const TextStyle(
|
||||
fontSize: 11,
|
||||
fontWeight: FontWeight.bold,
|
||||
),
|
||||
),
|
||||
.labelSmall!
|
||||
.copyWith(color: Theme.of(context).colorScheme.outline),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user