Swipe Cards는 개발자가 Tinder와 유사한 스와이프 가능한 카드 인터페이스를 만들 수 있도록 해주는 Flutter 패키지입니다. 직관적인 제스처를 통해 수평 스와이프를 지원하며, 사용자가 카드를 왼쪽 또는 오른쪽으로 스와이프할 수 있습니다. 간단함과 커스터마이징 가능성을 고려해 설계되어, 데이트 앱, 제품 전시, 콘텐츠 탐색 기능 등 카드 기반 네비게이션을 필요로 하는 앱에 적합합니다. Android, iOS, Web, macOS, Windows, Linux 등 다양한 플랫폼에서 작동합니다.
사용 사례
데이트 앱 인터페이스
제품 또는 아이템 탐색
콘텐츠 브라우징
사용자 선호도 수집
인터랙티브 온보딩 화면
주요 기능
Tinder 스타일의 스와이프 제스처
사용자 지정 가능한 카드 외관
크로스 플랫폼 지원
부드러운 애니메이션 전환
제스처 인식
Flutter와의 간편한 통합
적합한 대상
스와이프 기반 UI를 구축하는 개발자
카드 스와이프를 통한 사용자 상호작용을 필요로 하는 앱
다중 플랫폼 대상 프로젝트
고려 사항
상태 관리 처리가 필요합니다
제한된 내장 카드 데이터 처리
복잡한 레이아웃을 위해 추가 스타일링이 필요할 수 있습니다
페이지네이션 없이 대규모 카드 데이터 세트에 최적화되지 않음
원본 README
연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.
swipe_cards
A Flutter widget for Tinder like swipe cards. The card can be swiped right, left and up for different responses. Currently it supports the following responses:
Right swipe for like
Left swipe for nope
Up swipe for superlike
Install
To install the package, add the following dependency to your pubspec.yaml
An instance of MatchEngine that acts as controller for trigerring swipes manually.
itemBuilder
A function that returns the view inside a swipe card.
likeTag
Widget appears in like/right area during swipe.
nopeTag
Widget appears in nope/left area during swipe.
superLikeTag
Widget appears in super-like/up area during swipe.
onStackFinished
A function that is triggered as soon as all the cards have been swiped.
itemChanged
A function that is triggered when item in the stack changes (moves to next card).
leftSwipeAllowed
To enable/disable left swipe. (Default: true)
rightSwipeAllowed
To enable/disable right swipe. (Default: true)
upSwipeAllowed
To enable/disable up swipe. (Default: false)
fillSpace
Config weather to fill up the space or not. (Default: true)
MatchEngine
MatchEngine is the controller for the swipe cards. It takes swipeItems as an argument and is
used to trigger the swipes manually, for example on button press. The data type of swipeItems
is List<SwipeItem>.
SwipeItem contains the actual data that can be rendered in the swipe card. Actually it is a
wrapper over any dynamic object and just adds the functionality of like, nope and superlike to that
object.