Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expected behaviour of withZoom? #102

Open
marrrc opened this issue Jun 20, 2018 · 3 comments
Open

Expected behaviour of withZoom? #102

marrrc opened this issue Jun 20, 2018 · 3 comments

Comments

@marrrc
Copy link

marrrc commented Jun 20, 2018

hey,

I am aware that with the recent version, we now have WKWebView with this plugin for iOS. However I for one would love to disable zooming altogether (pinch, doubletap). It seems that 'withZoom: false' doesn't make any difference for zooming at all (fullscreen WebView with flutter navigation). At least when I tested this on iOS/sim.

Any hints what to look for? Thanks!

@longravuth
Copy link

Any update?

@fideldonson
Copy link

An update for anybody late to the party:
I disabled all zooming in ios by doing the following:
Setting withZoom:false on the widget.
Setting <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
And setting up the following js on the loaded page:

document.addEventListener("touchstart", function (event) {
                if (event.touches.length > 1) {
                    event.preventDefault();
                    event.stopPropagation();
                }
                }, {
                    passive: false
                });

@albert0m
Copy link

isn't there any other way to disable the zoom without involving javascript/html ? I don't have control over the website

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants