Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
change event is fired when the checked state changes due to user
Browse files Browse the repository at this point in the history
interaction. Use `core-change` event for old behavior (fired when the
checked state changes).

Fixes #9
  • Loading branch information
frankiefu committed Aug 25, 2014
1 parent 13b852d commit 9b07780
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions paper-checkbox.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,16 @@
Polymer('paper-checkbox', {

/**
* Fired when the checked state changes.
* Fired when the checked state changes due to user interaction.
*
* @event change
*/

/**
* Fired when the checked state changes.
*
* @event core-change
*/

toggles: true,

Expand All @@ -89,7 +95,7 @@
cl.toggle('checkmark', !this.checked);
cl.toggle('box', this.checked);
this.setAttribute('aria-checked', this.checked ? 'true': 'false');
this.fire('change');
this.fire('core-change');
},

checkboxAnimationEnd: function() {
Expand Down

0 comments on commit 9b07780

Please sign in to comment.