moayadnajd / nativescript-filter-select

A NativeScript plugin to provide an listview widget to select AND filter items
http://codeobia.com
Other
37 stars 19 forks source link

Is there a way to access the close modal event? #39

Closed leocrawf closed 6 years ago

leocrawf commented 6 years ago

Is there a way to access the close button event?

moayadnajd commented 6 years ago

@leocrawf for now no but i will do it soon for you

moayadnajd commented 6 years ago

@leocrawf i just updated the plugin to v 1.2.7 and your issue is solved there

you can do like below

in view model

public closeModal(args){
    console.log('on close selected array is => ' + JSON.stringify(args.selected));
  }

in xml

<FS:FilterSelect close="{{ closeModal }}" />

see demo for running example and don't forget to star the plugin 😄 ⭐️

Note: args.selected will be empty if the close finish without selected items

leocrawf commented 6 years ago

Thank you.