Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/luncheon/elab

Multiple selection with just markup.
https://github.com/luncheon/elab

multiselect select select-multiple selectbox vanilla-js

Last synced: 22 days ago
JSON representation

Multiple selection with just markup.

Awesome Lists containing this project

README

        

# elab

Multiple selection with just markup.

[Demo](https://luncheon.github.io/elab/index.html) / [CodePen](https://codepen.io/luncheon/pen/qBqQMjg)

## Installation

### via [npm](https://www.npmjs.com/package/elab) (with a module bundler)

```sh
$ npm install elab
```

```js
import 'elab/simple/simple.css' // or 'elab/material/material.css'
import 'elab/simple/simple.js' // or 'elab/material/material.js'
```

### via CDN ([jsDelivr](https://www.jsdelivr.com/package/npm/elab))

```html

```

### Download

[simple.css](https://cdn.jsdelivr.net/npm/[email protected]/simple/simple.css)
[simple.js](https://cdn.jsdelivr.net/npm/[email protected]/simple/simple.js)

[material.css](https://cdn.jsdelivr.net/npm/[email protected]/material/material.css)
[material.js](https://cdn.jsdelivr.net/npm/[email protected]/material/material.js)

## Usage

```html




  • All

  • Cupcake

  • Donut

  • Eclair

  • Froyo

  • Gingerbread

  • Honeycomb

  • Ice

  • Select...



{
const element = document.querySelector('.elab')
element.addEventListener('change', event => console.log('change', event.detail.values))
element.addEventListener('close', event => console.log('close', event.detail.values))
}

```

## License

[WTFPL](http://www.wtfpl.net)