v2.0.0
flutter_swipe_detector
스와이프 방향을 감지하고 이를 처리하기 위한 콜백을 제공하는 패키지입니다.
61좋아요 3.8천30일 다운로드140Pub 점수
AndroidiOSWebmacOSWindowsLinux
스와이프 방향을 감지하고 이를 처리하기 위한 콜백을 제공하는 플러터 패키지입니다.
{"sdk":"flutter"}{"sdk":"flutter"}^1.0.0아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
A package to detect your swipe directions and provides you with callbacks to handle them.
SwipeDetector(
onSwipe: (direction, offset) {
_addSwipe(direction);
},
onSwipeUp: (offset) {
_addSwipe(SwipeDirection.up);
},
onSwipeDown: (offset) {
_addSwipe(SwipeDirection.down);
},
onSwipeLeft: (offset) {
_addSwipe(SwipeDirection.left);
},
onSwipeRight: (offset) {
_addSwipe(SwipeDirection.right);
},
child: const Container(
padding: EdgeInsets.all(16),
child: Text(
'Swipe me!',
style: TextStyle(
fontWeight: FontWeight.bold,
),
),
),
),