Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/BosNaufal/vue-ripple

Vue Component to Make Google Material Design Ripple Effect. http://bosnaufal.github.io/vue-ripple/
https://github.com/BosNaufal/vue-ripple

Last synced: 3 months ago
JSON representation

Vue Component to Make Google Material Design Ripple Effect. http://bosnaufal.github.io/vue-ripple/

Awesome Lists containing this project

README

        

# Vue Ripple
[Vue](http://vuejs.org/) Component to Make Google Material Design Ripple Effect. It's adopted from [angular-ripple](https://github.com/nelsoncash/angular-ripple)

[DEMO](https://bosnaufal.github.io/vue-ripple)

## Install
You can import [vue-ripple](./src/js/components/index.js) to your vue component file like [this](./src/js/components/app.js) and process it with your preprocessor.;

You can install it via NPM
```bash
npm install vue-ripple
```

## Usage
Usage With Predefined Ripple Button
```html


Click On Me!

import { rippleButton } from './index.js';

export default {
components: { rippleButton }
};

```

Usage Standalone Ripple Component
```html


Click On Me!

import { ripple } from 'vue-ripple';

export default {

data(){
return{
cursorPos: {}
}
},

components: { ripple },

methods: {
handleClick(e){
// Get Cursor Position
this.cursorPos = {
top: e.clientY,
left: e.clientX
}
}
}

};

```

## Props
##### cursorPos (Object)
You need to describe the cursor position ( when parent is clicked ) with the structure like the object bellow
```javascript
let cursorPos = {
top: e.clientY,
left: e.clientX
}
```

## Thank You for Making this useful~

## Let's talk about some projects with me
Just Contact Me At:
- Email: [[email protected]](mailto:[email protected])
- Skype Id: bosnaufal254
- twitter: [@BosNaufal](https://twitter.com/BosNaufal)

## License
[MIT](http://opensource.org/licenses/MIT)
Copyright (c) 2016 - forever Naufal Rabbani