flipy
Version:
Flipy - A Wizard Plugin
35 lines (25 loc) • 1.32 kB
Markdown
# Flipy - Collapse and expand content
[](https://travis-ci.org/wbotelhos/flipy)
[](https://badge.fury.io/js/flipy)
[](https://david-dm.org/wbotelhos/flipy)
[](https://david-dm.org/wbotelhos/flipy#info=devDependencies)
[](https://codeclimate.com/github/wbotelhos/flipy)
[](https://liberapay.com/wbotelhos)
Flipy is an tiny flipy editor to enable a quick ajax update with no need to create a form.
## Options
```js
openedClass: 'flipy__trigger--opened' // class used to indicate that the content is opened
speed: 200 // speed of collapse and expand effect
```
## Usage
You declare an element with optional data atributes:
```html
<div class="flipy" data-opened-class='opened' data-speed="300">
<div class="flipy__trigger"></div>
<div class="flipy__content">Hello World!</div>
</div>
```
On JS you can declare attributes too, but data attributes has priority:
```js
$('.flipy').flipy({ speed: 100 });
```