Defines the destination for a drag and drop operation with the same size and position as this view, handling dropped content and the drop location with the given closure.
- macOS 10.15+Beta
- Xcode 11.0+Beta
The uniform type identifiers that describe the types of content this view can accept through drag and drop. If the drag and drop operation doesn’t contain any of the supported types, then this drop destination doesn’t activate and
A binding that updates when a drag and drop operation enters or exits the drop target area. The binding’s value is
truewhen the cursor is inside the area, and
falsewhen the cursor is outside.
A closure that takes the dropped content and responds appropriately. The first parameter to
actioncontains the dropped items, with types specified by
supported. The second parameter contains the drop location in this view’s coordinate space. Return
trueif the drop operation was successful; otherwise, return
A view that provides a drop destination for a drag operation of the specified types.