vue-ripple-directive
Advanced tools
Comparing version 1.1.0 to 1.1.1
{ | ||
"name": "vue-ripple-directive", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Vue Material Ripple Effect Directive", | ||
@@ -5,0 +5,0 @@ "main": "src/ripple.js", |
@@ -64,4 +64,6 @@ # Material Ripple Effect | ||
You can also set the default color for all your ripples like follows | ||
## Global settings | ||
You can set the default color and z-index for all your ripples as the following example | ||
``` | ||
@@ -71,3 +73,4 @@ import Ripple from 'vue-ripple-directive' | ||
Ripple.color = 'rgba(255, 255, 255, 0.35)'; | ||
Ripple.zIndex = 55; | ||
Vue.directive('ripple', Ripple); | ||
``` |
@@ -17,2 +17,3 @@ var Ripple = { | ||
var bg = binding.value || Ripple.color || 'rgba(0, 0, 0, 0.35)'; | ||
var zIndex = Ripple.zIndex || '9999'; | ||
@@ -48,3 +49,3 @@ function rippler(event, el) { | ||
ripple.style.position= 'relative'; | ||
ripple.style.zIndex= '9999'; | ||
ripple.style.zIndex= zIndex; | ||
ripple.style.backgroundColor = bg; | ||
@@ -51,0 +52,0 @@ |
81253
189
74
11