extended_image
extended_image copied to clipboard
Resized when keyboard shows/hides Duplicate #412
Do you have any ideas how to fix it?
I can't get you
I have same problem.
For example:
class Demo extends StatelessWidget {
const Demo({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
resizeToAvoidBottomInset: false,
backgroundColor: const Color(0xffd9eeff),
body: Stack(children: [
Positioned(
top: 0,
left: 0,
right: 0,
// when keyboard show/hide will rebuild Image
child: ExtendedImage.asset('assets/images/common/header.png'),
),
Positioned(
top: 0,
left: 0,
right: 0,
// when keyboard show/hide won't rebuild Image
child: Image.asset('assets/images/common/footer.png'),
),
Center(
child: Container(
height: 100,
color: Colors.white,
child: const TextField(),
),
),
]),
);
}
}
https://user-images.githubusercontent.com/48408513/176419795-eadee7aa-a377-4b28-985d-2a8b58f8efad.mp4
I have same problem.
For example:
class Demo extends StatelessWidget { const Demo({Key? key}) : super(key: key); @override Widget build(BuildContext context) { return Scaffold( resizeToAvoidBottomInset: false, backgroundColor: const Color(0xffd9eeff), body: Stack(children: [ Positioned( top: 0, left: 0, right: 0, // when keyboard show/hide will rebuild Image child: ExtendedImage.asset('assets/images/common/header.png'), ), Positioned( top: 0, left: 0, right: 0, // when keyboard show/hide won't rebuild Image child: Image.asset('assets/images/common/footer.png'), ), Center( child: Container( height: 100, color: Colors.white, child: const TextField(), ), ), ]), ); } }
1656499871198336.mp4
set https://github.com/fluttercandies/extended_image/blob/d24600b5fbd4e68a4cd34eaf8ac9ce67319874c7/lib/src/extended_image.dart#L773 to true
it works, thanks a lot.