mirror of
https://github.com/wgh136/pixes.git
synced 2025-09-27 04:57:23 +00:00
improve ui
This commit is contained in:
@@ -63,15 +63,18 @@ class _IllustWidgetState extends State<IllustWidget> {
|
|||||||
child: Stack(
|
child: Stack(
|
||||||
children: [
|
children: [
|
||||||
Positioned.fill(
|
Positioned.fill(
|
||||||
child: Container(
|
|
||||||
width: width,
|
|
||||||
height: height,
|
|
||||||
padding:
|
|
||||||
const EdgeInsets.symmetric(horizontal: 8.0, vertical: 8.0),
|
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.zero,
|
width: width,
|
||||||
decoration: BoxDecoration(
|
height: height,
|
||||||
|
padding: const EdgeInsets.symmetric(
|
||||||
|
horizontal: 8.0, vertical: 8.0),
|
||||||
|
child: Container(
|
||||||
|
width: double.infinity,
|
||||||
|
height: double.infinity,
|
||||||
|
padding: EdgeInsets.zero,
|
||||||
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.circular(4.0),
|
borderRadius: BorderRadius.circular(4.0),
|
||||||
|
color: FluentTheme.of(context).cardColor,
|
||||||
border: () {
|
border: () {
|
||||||
var emphasis = widget.illust.author.isFollowed &&
|
var emphasis = widget.illust.author.isFollowed &&
|
||||||
appdata.settings[
|
appdata.settings[
|
||||||
@@ -83,28 +86,30 @@ class _IllustWidgetState extends State<IllustWidget> {
|
|||||||
.withOpacity(0.64);
|
.withOpacity(0.64);
|
||||||
var width = emphasis ? 1.6 : 1.0;
|
var width = emphasis ? 1.6 : 1.0;
|
||||||
return Border.all(color: color, width: width);
|
return Border.all(color: color, width: width);
|
||||||
}()),
|
}(),
|
||||||
margin: EdgeInsets.zero,
|
),
|
||||||
child: GestureDetector(
|
margin: EdgeInsets.zero,
|
||||||
onTap: widget.onTap ??
|
child: GestureDetector(
|
||||||
() {
|
onTap: widget.onTap ??
|
||||||
context.to(() => IllustPage(widget.illust));
|
() {
|
||||||
},
|
context.to(() => IllustPage(widget.illust));
|
||||||
onSecondaryTapUp: showMenu,
|
},
|
||||||
onLongPress: showMenu,
|
onSecondaryTapUp: showMenu,
|
||||||
child: ClipRRect(
|
onLongPress: showMenu,
|
||||||
borderRadius: BorderRadius.circular(4.0),
|
child: ClipRRect(
|
||||||
child: AnimatedImage(
|
borderRadius: BorderRadius.circular(4.0),
|
||||||
image: CachedImageProvider(
|
child: AnimatedImage(
|
||||||
widget.illust.images.first.medium),
|
image: CachedImageProvider(
|
||||||
fit: BoxFit.cover,
|
widget.illust.images.first.medium),
|
||||||
width: width - 16.0,
|
fit: BoxFit.cover,
|
||||||
height: height - 16.0,
|
width: width - 16.0,
|
||||||
|
height: height - 16.0,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
)),
|
),
|
||||||
if (widget.illust.images.length > 1)
|
if (widget.illust.images.length > 1)
|
||||||
Positioned(
|
Positioned(
|
||||||
top: 12,
|
top: 12,
|
||||||
|
Reference in New Issue
Block a user