[iOS] fixed stub image cover fit

This commit is contained in:
Vadim 2023-12-27 20:20:24 +01:00
parent 78566d2142
commit 26f34977c1

View file

@ -84,7 +84,16 @@ class _CameraPreviewBuilderState extends State<_CameraPreviewBuilder> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
if (PlatformConfig.cameraStubImage.isNotEmpty) { if (PlatformConfig.cameraStubImage.isNotEmpty) {
return Image.asset(PlatformConfig.cameraStubImage); return Stack(
children: [
Positioned.fill(
child: Image.asset(
PlatformConfig.cameraStubImage,
fit: BoxFit.cover,
),
),
],
);
} }
return ValueListenableBuilder<bool>( return ValueListenableBuilder<bool>(
valueListenable: _initializedNotifier, valueListenable: _initializedNotifier,