WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 193494
209821
Changing WKWebView ScrollView’s contentInset results in wiggle while selecting a text inside content editable <div>
https://bugs.webkit.org/show_bug.cgi?id=209821
Summary
Changing WKWebView ScrollView’s contentInset results in wiggle while selectin...
Mohan
Reported
2020-03-31 10:44:29 PDT
Created
attachment 395064
[details]
Sample iOS Project I have UIViewController subclass hosting WKWebView on its view’s entire bounds. Content inset of WKWebView scrollview is set to UIEdgeInsetsMake(200,0,0,0) to accommodate a header view. WKWebView is loaded with a webpage that contains single content editable div tag. Eg. <html> <head> <body> <div contenteditable="true">Add content here</div> </body> </head> </html> When I type some text in the editable area and start selecting the text by double tap and selection handle drag WKWebView’s scroll view starts to moves up and down continuously. Is it okay to change content inset of WKWebView's scroll view ? Tried alternate approach below, I thought its allowed since scrollview content inset is adjusted in other scenraios like safe area insets(eg. content inset of scrollview is adjusted automatically if WebView underlaps UINavigationBar). I tried by setting ViewController's additionalSafeAreaInsets property to UIEdgeInsetsMake(200.0, self.additionalSafeAreaInsets.left, self.additionalSafeAreaInsets.bottom, self.additionalSafeAreaInsets.right); and the issue is not observed in this scenario but the only problem is scrollview ignores any interaction that happen in top 200 pixels so, scroll won't happen while dragging inside 0 to 200.
Attachments
Sample iOS Project
(35.33 KB, application/zip)
2020-03-31 10:44 PDT
,
Mohan
no flags
Details
Repro video
(4.87 MB, video/mp4)
2020-03-31 10:46 PDT
,
Mohan
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Mohan
Comment 1
2020-03-31 10:46:32 PDT
Created
attachment 395066
[details]
Repro video
Radar WebKit Bug Importer
Comment 2
2020-03-31 11:39:50 PDT
<
rdar://problem/61117640
>
Wenson Hsieh
Comment 3
2020-03-31 12:17:37 PDT
Thanks for the report, Mohan! From your sample project and repro video, it seems like you were testing on iOS 12, but the hardware field of this report states “iOS 13”. Did you confirm that this still reproduces on iOS 13? I briefly ran your application against a version of iOS 13.4, and did not reproduce what you were seeing. If it works in iOS 13, then it is likely a dupe of
https://bugs.webkit.org/show_bug.cgi?id=193494
.
Mohan
Comment 4
2020-04-01 05:59:59 PDT
Issue is no longer reproduced in iOS 13. Sorry, thought I tested in iOS 13 as well. Thanks lot for the fix Wenson Hsieh.
Mohan
Comment 5
2020-04-01 06:00:30 PDT
*** This bug has been marked as a duplicate of
bug 193494
***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug