1.1.6 • Published 6 years ago

react-duallist v1.1.6

Weekly downloads
110
License
MIT
Repository
github
Last release
6 years ago

react-duallist

A React based searchable, sortable and fully customizable dual list.

Demo

Install

npm install react-duallist --save

or

yarn add react-duallist

Use

import Duallist from 'react-duallist';

import 'react-duallist/lib/react_duallist.[css|less|scss|sass]'
  <Duallist
    available={available}
    selected={selected}
    onSelect={this.onSelect}
  />

options

OptionDescriptionDefault ValueRequired
availableList of available options, will appear in the left boxtrue
selectedList of selected options, will appear in the right boxtrue, atleast need to pass an empty array
onSelectA callback to handle the change in the selected listtrue
leftLabelA header for the left (available) listAvailable
rightLabelA header for the right (selected) listSelected
sortableA false value will hide the reorder buttons on the righttrue
searchableA false value will hide the search field on the toptrue
moveLeftIconfontawesome icons or icon of your choice<
moveAllLeftIconfontawesome icons or icon of your choice<<
moveRightIconfontawesome icons or icon of your choice>
moveAllRightIconfontawesome icons or icon of your choice>>
moveUpIconfontawesome icons or icon of your choice
moveTopIconfontawesome icons or icon of your choice
moveDownIconfontawesome icons or icon of your choice
moveBottomIconfontawesome icons or icon of your choice

Tests

npm test

or yarn test

Contributing

In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.

Release History

  • 0.0.1 - Duallist implementations
  • 0.0.2 - Support sorting on the 'selected' list
  • 0.0.3 - Hide/show search bar
  • 0.0.4 - Add example page
  • 0.0.5 - Add Custom icon support
  • 1.0.0 - Support React 16
  • 1.1.0 - Some style changes
  • 1.1.1 - Rename lib directory
  • 1.1.2 - Handle when empty arrays are passed
  • 1.1.4 - OnSelect handlers for the left and right lists.
  • 1.1.5 - Fix for issue #1 Allow empty 'selected' array
1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago

0.0.9

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago