Skip to content

Commit

Permalink
reusable paper-ripple (#87)
Browse files Browse the repository at this point in the history
  • Loading branch information
valdrinkoshi authored Jun 27, 2016
1 parent 8f49ac1 commit 0aa02d1
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"main": "paper-ripple.html",
"dependencies": {
"iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.1.4",
"iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.1.5",
"polymer": "Polymer/polymer#^1.1.0"
},
"devDependencies": {
Expand Down
14 changes: 14 additions & 0 deletions test/paper-ripple.html
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,20 @@
ripple.downAction();
ripple.upAction();
});
test('reuse a paper-ripple', function (done) {
var ripple = document.createElement('paper-ripple');
Polymer.dom(rippleContainer).appendChild(ripple);
Polymer.dom(rippleContainer).removeChild(ripple);

ripple.addEventListener('transitionend', function() {
expect(ripple.parentNode).to.be.ok;
Polymer.dom(document.body).removeChild(ripple);
done();
});
Polymer.dom(document.body).appendChild(ripple);
ripple.downAction();
ripple.upAction();
});
});

suite('avoid double transitionend event', function () {
Expand Down

0 comments on commit 0aa02d1

Please sign in to comment.