컴포넌트

Swipe Action Row

리스트 행을 좌우로 스와이프하면 숨은 액션 버튼이 드러나고, 러버밴드 비선형 저항과 스프링 스냅이 적용되는 컴포넌트. 접근성 버튼 대체 경로 제공.

분류
컴포넌트
난이도
hard
변형
TS-TW

설치

npx shadcn@latest add https://gasan.ai.kr/tools/effect/r/SwipeActionRow-TS-TW

Props

이름타입기본값설명
countnumber3표시할 행 개수
titleOf(index: number) => stringundefined행 제목 생성기 (기본: "메시지 N")
actionsSwipeAction[][보관, 삭제]스와이프 시 드러나는 액션 버튼 목록 (key/label/color/onAction)
resistancenumber0.5러버밴드 초과 이동 저항 계수 (작을수록 빡빡함)
classNamestringundefined추가 CSS 클래스