Closed kriefsacha closed 4 years ago
Someone ? It's quite urgent ..
Hi @kriefsacha,
Not a use-case we've thought of.
Without having tested it:
public onWebViewLoaded(evt) {
const webView = evt.object;
if (webView.android) {
webView.android.setOnTouchListener(new android.view.View.OnTouchListener({ onTouch() { return true; }}));
} else if (webView.ios) {
webView.ios.userInteractionEnabled = false;
webView.ios.scrollView.userInteractionEnabled = false;
}
}
Tested on Android, seems to work as we want !
I will test it on Ios, and keep you in touch.
Thanks man !
Hey @kriefsacha
I've added support for ´isEnabled="false"` in the latest alpha
I tried using the isEnabled prop in a <WebView ... />
component and set it to "false"
, but the street view I display from within the web view is still interactive. I am displaying the Webview in iOS. For iOS, I also tried setting isUserInteractionEnabled
to false
the way it has been suggested in other Github posts but that does not work either.
So how should I disable user interaction in the WebView or even within an <iFrame
that I render inside of the web view? Some help will be greatly appreciated. Thanks.
Hi,
We are on Nativescript Angular 6.2 with web view 6.0.0-alpha.2.
We need sometimes to prevent the user to interact with the webview , disable it.
We tried isEnabled, isUserInteractionEnabled , touch-action : none , pointer-events:none
Nothing works.
I wanted to know if you know how can we do that ? Display the webview but the user can't interact with it.
Thank you !