Just use the contentShape(_:_:eoFill:) initializer, making sure to specify a ContentShapeKinds of .contextMenuPreview:
contentShape(_:_:eoFill:)
ContentShapeKinds
.contextMenuPreview
.contentShape(.contextMenuPreview, RoundedRectangle(cornerRadius: 10))