GET_CAPSULES_LDE-EKA
Lucas Delanier 2 years ago
parent 50bee2f529
commit 20def43443

@ -53,7 +53,7 @@ class _PostComponentState extends State<PostComponent> {
onTap: switchChoice,
child: LayoutBuilder(
builder: (BuildContext context, BoxConstraints constraints) {
if (choice && widget.callback == null) {
if (widget.callback == null) {
return SizedBox(
width: double.infinity,
child: FutureBuilder(
@ -119,7 +119,9 @@ class _PostComponentState extends State<PostComponent> {
SizedBox(height: 10),
ZoomTapAnimation(
onTap: () {
widget.callback!(widget.index);
if (widget.post.selfie != null) {
switchChoice();
}
},
enableLongTapRepeatEvent: false,
longTapRepeatDuration: const Duration(milliseconds: 100),
@ -151,11 +153,12 @@ class _PostComponentState extends State<PostComponent> {
alignment: Alignment.bottomCenter,
children: [
Image(
image: NetworkImage(user.pp),
image: NetworkImage(choice ? widget.post.selfie! : music.cover!),
fit: BoxFit.cover,
width: double.infinity,
),
Positioned(
widget.post.selfie != null
? Positioned(
top: 0,
right: 0,
child: Padding(
@ -175,12 +178,14 @@ class _PostComponentState extends State<PostComponent> {
borderRadius: BorderRadius.circular(13),
// implement image
child: Image(
image: NetworkImage(music.cover!),
image:
NetworkImage(choice ? music.cover! : widget.post.selfie!),
fit: BoxFit.cover,
),
),
),
))
: Container(),
],
),
),
@ -246,6 +251,7 @@ class _PostComponentState extends State<PostComponent> {
}
}));
}
return SizedBox(
width: double.infinity,
child: FutureBuilder(
@ -363,7 +369,8 @@ class _PostComponentState extends State<PostComponent> {
maxLines: 1,
),
),
Positioned(
widget.post.selfie != null
? Positioned(
top: 0,
right: 0,
child: Padding(
@ -383,12 +390,13 @@ class _PostComponentState extends State<PostComponent> {
borderRadius: BorderRadius.circular(13),
// implement image
child: Image(
image: NetworkImage(user.pp),
image: NetworkImage(widget.post.selfie!),
fit: BoxFit.cover,
),
),
),
))
: Container(),
],
),
),

Loading…
Cancel
Save