Hi, not sure if you found the solution to your problem, but for those that might end up here, like me, looking for why the using the "new" highlightPreviewForItemAt and dismissalPreviewForItemAt did nothing, I found a solution.
Those delegates methods are marked iOS 16.0+, so It triggered me into looking at the method that starts the process, which was contextMenuConfigurationForItemAt and this one is marked as deprecated.
Turns out there is a "new" contextMenuConfigurationForItemsAt for itemS which is iOS 16.0+ and now it works!
So, before iOS 16:
contextMenuConfigurationForItemAt
previewForHighlightingContextMenuWithConfiguration
previewForDismissingContextMenuWithConfiguration
After iOS 16:
contextMenuConfigurationForItemsAt
highlightPreviewForItemAt
dismissalPreviewForItemAt
Topic:
UI Frameworks
SubTopic:
UIKit
Tags: