use stack instead of visibility

This commit is contained in:
Fabian Freund
2025-10-30 07:00:05 +01:00
parent 6fa8a56643
commit 3955859e5b
@@ -218,11 +218,9 @@ class _BrowserViewState extends ConsumerState<BrowserView>
}, },
); );
return Visibility( return Stack(
visible: hasTab, children: [
maintainState: true, GeckoView(
replacement: SizedBox.expand(child: Container(color: Colors.grey[800])),
child: GeckoView(
preInitializationStep: () async { preInitializationStep: () async {
await ref await ref
.read(eventServiceProvider) .read(eventServiceProvider)
@@ -283,6 +281,11 @@ class _BrowserViewState extends ConsumerState<BrowserView>
} }
}, },
), ),
if (!hasTab)
Positioned.fill(
child: SizedBox.expand(child: Container(color: Colors.grey[800])),
),
],
); );
} }