Why does text selection not work in MacCatalyst app's WKWebView on macOS Sonoma Only

Can not select anything within WkWebView editor view of my MacCatalyst app when running on macOS 14 Sonoma.

Any selection gesture or command key fails to select anything in content editable WKWebView, so none of the Editor tools can be activated.

My application uses the nnhubbard / ZSSRichTextEditor WKWebView-based Rich Text Editor: https://github.com/nnhubbard/ZSSRichTextEditor. The app is built with Xcode 15.0 or 15.0.1.

The app is a Catalyst app that implements an editor view with a ZSSRichTextEditor WKWebView.

The problem does not occur if the the app is run in iOS or macOS 11, 12, or 13 (Catalina, Monterey, or Ventura.) The issue only occurs in macOS 14 Sonoma.

Answered by goofyfooter in 802392022

Apple Feedback FB14734097 — macOS provided a fix. The fix is posted to https://stackoverflow.com/a/78945775/1911037

The following error message is logged whenever an attempt to select any text in the WKWebView content:

0x1359ecc18 - [pageProxyID=14, webPageID=15, PID=14,932] WebPageProxy::didFailProvisionalLoadForFrame: frameID=1, isMainFrame=1, domain=NSURLErrorDomain, code=18,446,744,073,709,550,614, isMainFrame=1, willInternallyHandleFailure=0 WKWebView didFailProvisionalNavigation - error="unsupported URL"

The following error message is logged whenever an attempt to select any text in the WKWebView content:

0x1359ecc18 - [pageProxyID=14, webPageID=15, PID=14,932] WebPageProxy::didFailProvisionalLoadForFrame: frameID=1, isMainFrame=1, domain=NSURLErrorDomain, code=18,446,744,073,709,550,614, isMainFrame=1, willInternallyHandleFailure=0

Issue still exists in macOS 15 Sequoia Developer Beta 5.

Accepted Answer

Apple Feedback FB14734097 — macOS provided a fix. The fix is posted to https://stackoverflow.com/a/78945775/1911037

Why does text selection not work in MacCatalyst app's WKWebView on macOS Sonoma Only
 
 
Q