Is it possible to trigger an action when the slide is scrolled to full extent? (like Gmail)

Đang mở
#431 1 bình luận 7 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
22/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
dart, flutter
Lĩnh vực
mobile

Hướng nghiên cứu

The request is about the Slidable widget's swipe-extent behaviour: firing a callback when the drag reaches full extent without dismissing the item. Start from how Slidable exposes its action panes and drag extent, and check whether an existing callback or extent-ratio hook already covers this. Done means a clear answer on whether the behaviour is achievable with the current API, or a proposed API change with maintainer agreement; the thread is a single unanswered question, so expect design discussion first.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hello @letsar & guys that want to help!

First, congratulations on developing such a wonderful library of "flutter_slidable", that's exactly what I personally need.

Now, let's go to the question.

Is it possible to configure an action to be automatically triggered when we scroll the slide until the end?

Important Note: I don't want to remove/delete the item that I scrolled, I just wanna trigger an action on the item that I scrolled.

On Gmail for example, if we scroll the slide to the right at full extent, it automatically execute the action to Archive that email message.

https://github.com/letsar/flutter_slidable/assets/7637806/c37a4c53-4862-4399-ad6b-28ac73721284

↑ However, as we can see on the above video, doing that in gmail removes the item that is scrolled and I don't want that. I want the item to remain there visible and execute an action on that item.

How can I do that with the flutter_slidable widget?

Thank you very much for your time and support in case you answer that! 👏

Ngôn ngữ chính
Dart
Star
2.9k
Fork
646
Merge trung bình
5 phút
Pull request đã merge (30 ngày)
9

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của letsar/flutter_slidable

Tất cả issue của letsar/flutter_slidable

Issue tương tự

Thêm issue về Dart

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.