Merge pull request #233 from ente-io/webview_transparent_bg

Set webview bg as transparent
This commit is contained in:
Vishnu Mohandas 2022-05-09 20:27:28 +05:30 committed by GitHub
commit bfc24d3370
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -22,8 +22,11 @@ class _WebPageState extends State<WebPage> {
title: Text(widget.title),
actions: [_hasLoadedPage ? Container() : loadWidget],
),
backgroundColor: Colors.transparent,
body: InAppWebView(
initialUrlRequest: URLRequest(url: Uri.parse(widget.url)),
initialOptions: InAppWebViewGroupOptions(
crossPlatform: InAppWebViewOptions(transparentBackground: true)),
onLoadStop: (c, url) {
setState(() {
_hasLoadedPage = true;