I use UIMenuController when presenting my custom menu for the selected text on my WKWebview. But it is now deprecated on iOS 16, and get the following error
[Text] Using UIMenuController to add items into text menus is deprecated. Please implement the UITextInput API editMenuForTextRange:suggestedActions: instead.
[EditMenuInteraction] The edit menu ... did not have performable commands and/or actions; ignoring present.
And now I cant find any documentation on how to customize the menu on wkwebview.
This is what I am trying to present on the menu.
How can you customize the menu on the selected text on wkwebview?
I tried adding UITextInput, but it requires to conform to a bunch of protocols.

This isn't possible just yet, but I think Apple is planning to add APIs for
UIEditMenuInteractionsoon. This is what I found in the WebKit source (mind theWK_IOS_TBAavailability specifier):UPDATE: These methods are showing up in the
WKUIDelegatedocs too now: