https://github.com/minutebase/mb-menu
Simple single/multiple select menu
https://github.com/minutebase/mb-menu
Last synced: 11 months ago
JSON representation
Simple single/multiple select menu
- Host: GitHub
- URL: https://github.com/minutebase/mb-menu
- Owner: minutebase
- License: mit
- Created: 2014-12-19T22:54:43.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2015-07-13T14:38:53.000Z (almost 11 years ago)
- Last Synced: 2025-03-08T22:27:36.545Z (over 1 year ago)
- Language: JavaScript
- Size: 324 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# MB-Menu
Simple menu - [demo](http://minutebase.github.io/mb-menu).
## Installing
```
ember install ember-mb-menu
```
## Basic Usage
```handlebars
{{#mb-menu items=items selected=selected on-select="selected" as |item|}}
{{item}}
{{/mb-menu}}
```
`selected` can either be a single item or an array for multiple-selection.
## Actions
* `on-select` - sent when item is selected
* `on-deselect` - sent when item is de-selected
* `on-toggle` - sent when item is selected or deselected
## Styling
* `class` - the class of the menu (standard Ember)
* `item-class` - the class for each item
* `selected-class` - the class to give to selected items
## Event Bubbling
If you want to prevent click events from bubbling, pass `bubbles=false` and they will be swallowed.
# Developing
## Installation
* `git clone` this repository
* `npm install`
* `bower install`
## Running
* `ember server`
* Visit your app at http://localhost:4200.
## Running Tests
* `ember test`
* `ember test --server`
## Building
* `ember build`
For more information on using ember-cli, visit [http://www.ember-cli.com/](http://www.ember-cli.com/).