Components / App structure

Swipe Box

Swipe rows in the sample app's recent calls example to reveal actions.

CupertinoSwipeBox View source ↗

Playground

Live Compose · Wasm
Preview

Click or drag inside the preview to try it out.

Properties

Usage example

Kotlin code for the current playground settings.

Example.kt
kotlin
import androidx.compose.runtime.*import androidx.compose.foundation.layout.*import androidx.compose.ui.Modifierimport androidx.compose.ui.unit.dpimport zone.ien.hig.*import zone.ien.hig.theme.*import androidx.compose.foundation.rememberScrollStateimport cupertino.RecentCallsSwipeChapterimport androidx.compose.ui.graphics.Colorimport androidx.compose.ui.Alignment
@OptIn(ExperimentalCupertinoApi::class)@Composablefun Example() { CupertinoTheme(colorScheme = lightColorScheme(accent = Color(0xFF007AFF))) { Column(Modifier.fillMaxSize(), verticalArrangement = Arrangement.spacedBy(16.dp, Alignment.CenterVertically)) { // 실제 실행 중인 최근 통화 예제 전체를 소스에서 확인하세요. // CupertinoSwipeBox의 상태, 액션 구성, 스크롤 연동을 포함합니다. RecentCallsSwipeChapter(scrollableState = rememberScrollState()) } }}

Run examples inside CupertinoTheme. For components using backdrop, attach layerBackdrop to the background content.