mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-05-31 16:18:22 +08:00
@@ -336,55 +336,53 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
final padding = MediaQuery.viewPaddingOf(context);
|
final padding = MediaQuery.viewPaddingOf(context);
|
||||||
final maxWidth = context.mediaQueryShortestSide;
|
final maxWidth = context.mediaQueryShortestSide;
|
||||||
late final coverSize = MediaQuery.textScalerOf(context).scale(65);
|
late final coverSize = MediaQuery.textScalerOf(context).scale(65);
|
||||||
return GestureDetector(
|
return Stack(
|
||||||
behavior: HitTestBehavior.opaque,
|
clipBehavior: .none,
|
||||||
onTap: Get.back,
|
alignment: .center,
|
||||||
child: Stack(
|
|
||||||
clipBehavior: Clip.none,
|
|
||||||
alignment: Alignment.center,
|
|
||||||
children: [
|
children: [
|
||||||
SingleChildScrollView(
|
SingleChildScrollView(
|
||||||
padding: EdgeInsets.only(
|
hitTestBehavior: .deferToChild,
|
||||||
|
padding: .only(
|
||||||
top: 12 + padding.top,
|
top: 12 + padding.top,
|
||||||
bottom: 80 + padding.bottom,
|
bottom: 80 + padding.bottom,
|
||||||
),
|
),
|
||||||
child: Listener(
|
|
||||||
child: Container(
|
child: Container(
|
||||||
width: maxWidth,
|
width: maxWidth,
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
padding: const .symmetric(horizontal: 12),
|
||||||
child: RepaintBoundary(
|
child: RepaintBoundary(
|
||||||
key: boundaryKey,
|
key: boundaryKey,
|
||||||
child: Container(
|
child: Container(
|
||||||
clipBehavior: Clip.hardEdge,
|
clipBehavior: .hardEdge,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: theme.colorScheme.surface,
|
color: theme.colorScheme.surface,
|
||||||
borderRadius: const .all(.circular(12)),
|
borderRadius: const .all(.circular(12)),
|
||||||
),
|
),
|
||||||
child: AnimatedSize(
|
child: AnimatedSize(
|
||||||
curve: Curves.easeInOut,
|
curve: Curves.easeInOut,
|
||||||
alignment: Alignment.topCenter,
|
alignment: .topCenter,
|
||||||
duration: const Duration(milliseconds: 255),
|
duration: const Duration(milliseconds: 255),
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: .min,
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: .start,
|
||||||
children: [
|
children: [
|
||||||
if (_item case final ReplyInfo reply)
|
switch (_item) {
|
||||||
IgnorePointer(
|
ReplyInfo reply => IgnorePointer(
|
||||||
child: ReplyItemGrpc(
|
child: ReplyItemGrpc(
|
||||||
replyItem: reply,
|
replyItem: reply,
|
||||||
replyLevel: 0,
|
replyLevel: 0,
|
||||||
needDivider: false,
|
needDivider: false,
|
||||||
upMid: widget.upMid,
|
upMid: widget.upMid,
|
||||||
),
|
),
|
||||||
)
|
),
|
||||||
else if (_item case final DynamicItemModel dyn)
|
DynamicItemModel dyn => IgnorePointer(
|
||||||
IgnorePointer(
|
|
||||||
child: DynamicPanel(
|
child: DynamicPanel(
|
||||||
item: dyn,
|
item: dyn,
|
||||||
isDetail: true,
|
isDetail: true,
|
||||||
isSave: true,
|
isSave: true,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
_ => throw UnsupportedError(_item.toString()),
|
||||||
|
},
|
||||||
if (cover?.isNotEmpty == true &&
|
if (cover?.isNotEmpty == true &&
|
||||||
title?.isNotEmpty == true)
|
title?.isNotEmpty == true)
|
||||||
Container(
|
Container(
|
||||||
@@ -397,29 +395,29 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
borderRadius: const .all(.circular(8)),
|
borderRadius: const .all(.circular(8)),
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
|
spacing: 10,
|
||||||
children: [
|
children: [
|
||||||
NetworkImgLayer(
|
NetworkImgLayer(
|
||||||
src: cover!,
|
src: cover!,
|
||||||
height: coverSize,
|
height: coverSize,
|
||||||
width: coverType == .def16_9
|
width: coverType == .def16_9
|
||||||
? coverSize *
|
? coverSize * StyleString.aspectRatio16x9
|
||||||
StyleString.aspectRatio16x9
|
|
||||||
: coverSize,
|
: coverSize,
|
||||||
quality: 100,
|
quality: 100,
|
||||||
borderRadius: const .all(.circular(6)),
|
borderRadius: const .all(.circular(6)),
|
||||||
),
|
),
|
||||||
const SizedBox(width: 10),
|
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: .start,
|
crossAxisAlignment: .start,
|
||||||
children: [
|
children: [
|
||||||
Text(
|
Expanded(
|
||||||
|
child: Text(
|
||||||
'$title\n',
|
'$title\n',
|
||||||
maxLines: 2,
|
maxLines: 2,
|
||||||
overflow: .ellipsis,
|
overflow: .ellipsis,
|
||||||
),
|
),
|
||||||
if (pubdate != null) ...[
|
),
|
||||||
const Spacer(),
|
if (pubdate != null)
|
||||||
Text(
|
Text(
|
||||||
DateFormatUtils.format(
|
DateFormatUtils.format(
|
||||||
pubdate,
|
pubdate,
|
||||||
@@ -430,7 +428,6 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
],
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@@ -438,18 +435,17 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
showBottom
|
showBottom
|
||||||
? Stack(
|
? Stack(
|
||||||
clipBehavior: Clip.none,
|
clipBehavior: .none,
|
||||||
children: [
|
children: [
|
||||||
if (uri.isNotEmpty)
|
if (uri.isNotEmpty)
|
||||||
Align(
|
Align(
|
||||||
alignment: Alignment.centerRight,
|
alignment: .centerRight,
|
||||||
child: Row(
|
child: Row(
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: .min,
|
||||||
crossAxisAlignment:
|
crossAxisAlignment: .end,
|
||||||
CrossAxisAlignment.end,
|
|
||||||
spacing: 4,
|
spacing: 4,
|
||||||
children: [
|
children: [
|
||||||
if (uname?.isNotEmpty == true)
|
if (uname?.isNotEmpty == true)
|
||||||
@@ -465,7 +461,7 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
'识别二维码,$viewType$itemType',
|
'识别二维码,$viewType$itemType',
|
||||||
textAlign: TextAlign.end,
|
textAlign: .end,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: theme
|
color: theme
|
||||||
.colorScheme
|
.colorScheme
|
||||||
@@ -475,12 +471,11 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
Text(
|
Text(
|
||||||
DateFormatUtils.longFormatDs
|
DateFormatUtils.longFormatDs
|
||||||
.format(.now()),
|
.format(.now()),
|
||||||
textAlign: TextAlign.end,
|
textAlign: .end,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 13,
|
fontSize: 13,
|
||||||
color: theme
|
color:
|
||||||
.colorScheme
|
theme.colorScheme.outline,
|
||||||
.outline,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@@ -510,13 +505,12 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Align(
|
Align(
|
||||||
alignment: Alignment.centerLeft,
|
alignment: .centerLeft,
|
||||||
child: Image.asset(
|
child: Image.asset(
|
||||||
'assets/images/logo/logo_2.png',
|
'assets/images/logo/logo_2.png',
|
||||||
width: 100,
|
width: 100,
|
||||||
cacheWidth: 100.cacheSize(context),
|
cacheWidth: 100.cacheSize(context),
|
||||||
color:
|
color: theme.colorScheme.onSurfaceVariant,
|
||||||
theme.colorScheme.onSurfaceVariant,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@@ -529,7 +523,6 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
|
||||||
Positioned(
|
Positioned(
|
||||||
left: 0,
|
left: 0,
|
||||||
right: 0,
|
right: 0,
|
||||||
@@ -537,8 +530,8 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
child: DecoratedBox(
|
child: DecoratedBox(
|
||||||
decoration: const BoxDecoration(
|
decoration: const BoxDecoration(
|
||||||
gradient: LinearGradient(
|
gradient: LinearGradient(
|
||||||
begin: Alignment.topCenter,
|
begin: .topCenter,
|
||||||
end: Alignment.bottomCenter,
|
end: .bottomCenter,
|
||||||
colors: [
|
colors: [
|
||||||
Colors.transparent,
|
Colors.transparent,
|
||||||
Colors.black54,
|
Colors.black54,
|
||||||
@@ -553,7 +546,7 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
spacing: 40,
|
spacing: 40,
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: .center,
|
||||||
children: [
|
children: [
|
||||||
iconButton(
|
iconButton(
|
||||||
size: 42,
|
size: 42,
|
||||||
@@ -595,7 +588,6 @@ class _SavePanelState extends State<SavePanel> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user