---
title: ScrollPhase
framework: swiftui
role: symbol
role_heading: Enumeration
path: swiftui/scrollphase
---

# ScrollPhase

A type that describes the state of a scroll gesture of a scrollable view like a scroll view.

## Declaration

```swift
@frozen enum ScrollPhase
```

## Overview

Overview A scroll gesture can be in one of four phases: - idle: No active scroll is occurring. - panning: An active scroll being driven by the user is occurring. - decelerating: The user has stopped driving a scroll and the scroll view is decelerating to its final target. - animating: The system is animating to a final target as a result of a programmatic animated scroll from using a ScrollViewReader or scrollPosition(id:anchor:) modifier. SwiftUI provides you a value of this type when using the onScrollPhaseChange(_:) modifier.

## Topics

### Getting scroll gesture states

- [ScrollPhase.animating](swiftui/scrollphase/animating.md)
- [ScrollPhase.decelerating](swiftui/scrollphase/decelerating.md)
- [ScrollPhase.idle](swiftui/scrollphase/idle.md)
- [ScrollPhase.interacting](swiftui/scrollphase/interacting.md)
- [ScrollPhase.tracking](swiftui/scrollphase/tracking.md)

### Checking for active scrolling

- [isScrolling](swiftui/scrollphase/isscrolling.md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Copyable](swift/copyable.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Responding to scroll view changes

- [onScrollGeometryChange(for:of:action:)](swiftui/view/onscrollgeometrychange(for:of:action:).md)
- [onScrollTargetVisibilityChange(idType:threshold:_:)](swiftui/view/onscrolltargetvisibilitychange(idtype:threshold:_:).md)
- [onScrollVisibilityChange(threshold:_:)](swiftui/view/onscrollvisibilitychange(threshold:_:).md)
- [onScrollPhaseChange(_:)](swiftui/view/onscrollphasechange(_:).md)
- [ScrollGeometry](swiftui/scrollgeometry.md)
- [ScrollPhaseChangeContext](swiftui/scrollphasechangecontext.md)
