Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct noink property to no-ink to actually conform to established property name conventions #69

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
22 changes: 18 additions & 4 deletions paper-ripple-behavior.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,15 @@
* If true, the element will not produce a ripple effect when interacted
* with via the pointer.
*/
noInk: {
type: Boolean,
observer: '_noInkChanged'
},

/**
* This property is a temporary alias to noInk until version 2.x
*
*/
noink: {
type: Boolean,
observer: '_noinkChanged'
Expand Down Expand Up @@ -70,7 +79,7 @@
ensureRipple: function(optTriggeringEvent) {
if (!this.hasRipple()) {
this._ripple = this._createRipple();
this._ripple.noink = this.noink;
this._ripple.noInk = this.noInk;
var rippleContainer = this._rippleContainer || this.root;
if (rippleContainer) {
Polymer.dom(rippleContainer).appendChild(this._ripple);
Expand Down Expand Up @@ -117,10 +126,15 @@
document.createElement('paper-ripple'));
},

_noinkChanged: function(noink) {
_noInkChanged: function(noInk) {
if (this.hasRipple()) {
this._ripple.noink = noink;
this._ripple.noInk = noInk;
}
}
},

_noinkChanged: function(noInk) {
console.warn("This field will be deprecated with the next major version of this component, use no-ink instead");
this.noInk = noInk;
},
};
</script>