---
title: cancellationAction
framework: swiftui
role: symbol
role_heading: Type Property
path: swiftui/toolbaritemplacement/cancellationaction
---

# cancellationAction

A placement for cancellation actions in a modal interface.

## Declaration

```swift
static let cancellationAction: ToolbarItemPlacement
```

## Discussion

Discussion Cancellation actions dismiss the modal interface without taking any action, usually by tapping or clicking a Cancel button. In macOS and in Mac Catalyst apps, the system places cancellationAction items on the trailing edge of the sheet but places them before any confirmationAction items. In iOS, iPadOS, tvOS, and watchOS, the system places cancellationAction items on the leading edge of the navigation bar.

## See Also

### Getting placement for specific actions

- [primaryAction](swiftui/toolbaritemplacement/primaryaction.md)
- [secondaryAction](swiftui/toolbaritemplacement/secondaryaction.md)
- [confirmationAction](swiftui/toolbaritemplacement/confirmationaction.md)
- [destructiveAction](swiftui/toolbaritemplacement/destructiveaction.md)
- [navigation](swiftui/toolbaritemplacement/navigation.md)
