1.0.4 • Published 3 years ago

@jswork/next-abstract-checkbox v1.0.4

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

next-abstract-checkbox

Abstract checkbox for next.

version license size download

installation

npm install -S @jswork/next-abstract-checkbox

apis

apiparamsdescription
checked-Property: Get the list checked status.
indeterminate-Property: Get the list indeterminate status.
ids-Property: Get the all the list ids.
select-Method: Select checkbox by id.
selectMultiple-Method: Select checkbox by id list.
selectAll-Method: Select all the checkbox.
unSelect-Method: Deselct checkbox by id.
unSelectMultiple-Method: Deselct checkbox by id list.
unSelectAll-Method: Deselct all the checkbox.
get-Method: Get runtime ids list.

usage

import NxAbstractCheckbox from '@jswork/next-abstract-checkbox';

const checkboxer = new NxAbstractCheckbox({ 
  idKey: 'uuid', 
  items:[], 
  onChange: (e)=>{ 
    console.log(e.target.value);
  } 
});

const res = checkboxer.select(['4c4e97a96dc164db144452acdf993531']);

// ['4c4e97a96dc164db144452acdf993531']

license

Code released under the MIT license.