flutter_slidable_list_view 1.2.8 copy "flutter_slidable_list_view: ^1.2.8" to clipboard
flutter_slidable_list_view: ^1.2.8 copied to clipboard

a item slidable listView, You can use it like you would with a ListView,

flutter_slidable_list_view #

a item slidable listView, the slide item is learn from flutter_slidable, i need some effect that like IOS's list or QQ mobile client's chat list,so this package burn.

Getting Started #

The usage of this Widget is similar to that of ListView.

        SlideListView(
          itemBuilder: (bc, index) {
            // return your item widget here,no need to consider the click event
          },
          actionWidgetBuilder: ActionWidgetDelegate( $action_count, (index) {
            // return your action widget
          }, (int indexInList, int index, BaseSlideItem item) {
            // deal the action click event here,you can use item.close(),item.remove() to close or remove this item after click action 
          }, [$action_colors]),// action_colors.len need equal to action_count
          dataList: $data_list,
        )

Preview #

Parameter Description #

SlideListView

parameter type description default value
dataList List the list data no default,required
slideProportion double this value determine the action width 0.25
itemBackgroundColor Color the list item background color,don't use Transparent white
supportElasticSliding bool has elasticsliding effict when slide true
animationDuration Duration the animation duration 200 ms
refreshCallback Future if null,list dont support swip refresh null
itemBuilder Widget Function(BuildContext context, int index) build the list item required
separatorBuilder Widget Function(BuildContext context, int index) build the list separator Divider(height: 1)
actionWidgetDelegate ActionWidgetDelegate build the action widget required
refreshWidgetBuilder Widget Function( Widget content, RefreshCallback refreshCallback) you can use your custom refresh indicator RefreshIndicator
onGestureEnd void Function(DragEndDetails detail, double itemWidth,double translateValue, Function openF, Function closeF) determine when to close or open action on gesture end null

ActionWidgetDelegate

parameter type description default value
actionCount int the actionButton's count required
actionBuilder Widget Function(int actionIndex, int indexInList) build the action button required
clickCallback Function(int indexInList, int index, BaseSlideItem item) handle click action null
actionBackgroundColors List given the action button background color(this list's length must same with actionCount) null
14
likes
40
pub points
54%
popularity

Publisher

unverified uploader

a item slidable listView, You can use it like you would with a ListView,

Repository (GitHub)
View/report issues

License

MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on flutter_slidable_list_view