Created
          September 18, 2014 15:12 
        
      - 
      
- 
        Save jimrubenstein/29941139fb00e98d6f69 to your computer and use it in GitHub Desktop. 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | function createOption($listItem, $input) | |
| { | |
| $listItem.on('click tap', function(evt) | |
| { | |
| $input.prop('checked', ! $input.prop('checked')); | |
| if ($input.is(':checked')) | |
| { | |
| $listItem.addClass('selected'); | |
| } | |
| else | |
| { | |
| $listItem.removeClass('selected'); | |
| } | |
| }); | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment