Pebble.UnobstructedArea

Observe Timeline Quick View unobstructed-area changes on round watches.

Use currentBounds during startup to sync the initial layout, then subscribe to onWillChange, onChanging, and onDidChange to animate layout transitions.

Native Pebble C API

Commands

currentBounds

currentBounds : (Rect -> msg) -> Cmd msg

Read the current unobstructed bounds once.

Subscriptions

onWillChange

onWillChange : (Rect -> msg) -> Sub msg

Receive the final unobstructed bounds before a Timeline peek transition.

onChanging

onChanging : (Int -> msg) -> Sub msg

Receive animation progress while the unobstructed area is changing.

Progress ranges from 0 to 255, matching Pebble's AnimationProgress.

onDidChange

onDidChange : msg -> Sub msg

Receive notification after the unobstructed area finished changing.