Skip to content
This repository has been archived by the owner on Dec 19, 2024. It is now read-only.

Commit

Permalink
Support for noink.
Browse files Browse the repository at this point in the history
  • Loading branch information
bicknellr committed Sep 8, 2016
1 parent 5997dcd commit 1e020b8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion paper-checkbox-light.html
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,8 @@
},

noink: {
type: Boolean
type: Boolean,
observer: '_noinkChanged'
},
},

Expand Down Expand Up @@ -251,6 +252,12 @@
this.setAttribute('aria-disabled', this.disabled);
},

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

_updateInkSize: function() {
var inkSize = this.getComputedStyleValue('--calculated-paper-checkbox-ink-size');
// If unset, compute and set the default `--paper-checkbox-ink-size`.
Expand Down Expand Up @@ -317,6 +324,7 @@
var ripple = document.createElement('paper-ripple');
ripple.center = true;
ripple.classList.add('circle');
ripple.noink = this.noink;
Polymer.dom(this.root).appendChild(ripple);
this._ripple = ripple;
}
Expand Down
2 changes: 1 addition & 1 deletion test/paper-checkbox-light.html
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@

test('checkbox respects the user set aria-label', function() {
var c = fixture('AriaLabel');
assert.isTrue(c.getAttribute('aria-label') == "Batman");
assert.isTrue(c.getAttribute('aria-label') == 'Batman');
});

a11ySuite('Basic');
Expand Down

0 comments on commit 1e020b8

Please sign in to comment.