This file contains 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
{ | |
"records": [ | |
{ | |
"common_name": "Bottlenose dolphin", | |
"latin_name": "Tursiops truncatus", | |
"description": "warm and temperate seas worldwide", | |
"conservation_status": "LC", | |
"kingdom": "mammal" | |
}, | |
{ |
This file contains 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
var Class = (function() { | |
'use strict'; | |
function addClass(el, className) { | |
/** | |
* Adds a string to the class name. | |
* | |
* @param {Node} el Any element | |
* @param {String} className The new class name to add |
This file contains 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() { | |
var inputs = document.getElementsByTagName('input'), | |
j = inputs.length, | |
checkedBoxes = 0; | |
//adds click event listener to each input | |
for (var i = 0; i < j; i += 1) { | |
inputs[i].addEventListener("click", function(){changeState(this);}); | |
if (inputs[i].checked == true) checkedBoxes += 1; | |
} |
NewerOlder