Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
@kenshooui/react-multi-select
Advanced tools
Kenshoo multi select component
Multi select is a straight forward component that helps a user select multiple items in a clear and filterable way.
Installation using npm:
npm install @kenhooui/react-multi-select --save
Installation using Yarn:
yarn add @kenhooui/react-multi-select
import React, { Component } from "react";
import MultiSelect from "@kenhooui/react-multi-select";
class Example extends Component {
constructor(props) {
super(props);
this.handleChange = this.handleChange.bind(this);
this.state = {
items: [
{ id: 0, label: "item 1" },
{ id: 2, label: "item 2" },
{ id: 3, label: "item 3" },
{ id: 4, label: "item 4" }
],
selectedItems: []
};
}
handleChange(selectedItems) {
this.setState({ selectedItems });
}
render() {
const { items, selectedItems } = this.state;
return (
<MultiSelect
items={items}
selectedItems={selectedItems}
onChange={this.handleChange}
/>
);
}
}
Name | Type | Default | Description |
---|---|---|---|
items | List | [] | list of items . |
selectedItems | Array | [] | selected list to start with (subgroup of items). |
searchPlaceholder | String | 'Search...' | Search box place holder |
emptyText | String | 'No items...' | Text to display when list is empty |
sortFn | function | undefined | list item auto sorting (on items changed) |
onOrderChanged | function | ()=>{} | callback for order changed event (by navigation buttons or drag-n-drop) |
withNavigation | boolean | false | toggle to show navigation buttons in list |
groups | List | [] | list of objects. Groups will appear as titles for items. Example of object: {id: 1, label: 'A', selectGroupLabel: 'Select All', itemIds:[1, 2]}] |
isItemLockedFn | function | (item)=>false | function to define whether item should be blocked for navigation |
sumItemsInPageForLazyLoad | number | 100 | actual for lazyLoad props - sum of list items for single page |
msDelayOnChangeFilter | number | null -(if lazyload true by default passed 600 ms) | onChange is delayed before performing a function as the number of ms this value contains |
withSelectAll | boolean | false | toggle to show select All option in list. |
yarn install
yarn test
or yarn test:watch
yarn storybook
and head to https://localhost:6006Push to github.
If you’ve fixed a bug or added code that should be tested, add tests.
Open a Pull Request with the following guidelines:
Once your Pull Request is issued the test suite and build processes will run and we will review your change.
React 16 or newer
FAQs
React Multi Select
We found that @kenshooui/react-multi-select demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.