Skip to content

Instantly share code, notes, and snippets.

@aristretto
Created November 8, 2016 19:46
Show Gist options
  • Save aristretto/d9346aea08fe0288bbfa676da45918a9 to your computer and use it in GitHub Desktop.
Save aristretto/d9346aea08fe0288bbfa676da45918a9 to your computer and use it in GitHub Desktop.
Paste this in your JS console (in Chrome)
!(navigator.userAgent.toLowerCase().indexOf('chrome') > -1) ? null : (function() {
var args = [], eightBitHack = [], coordinates = ["nodcnp", "tl9ehx", "tl9fad", "tl9fad", "tl9fhh", "tl9fj9", "zik0z9", "zik0zh", "zik0zj", "zik0zh", "zik0z9", "tl9fj9", "tl9fhh", "tl9fad", "tl9fad", "tl9ehx", "nodcnp"];
for (var row = coordinates.length; row--;) {
var decompressedRow = parseInt(coordinates[row], 36).toString(4).split('');
coordinates[row] = decompressedRow.splice(1, decompressedRow.length-1);
for (var cell = coordinates[row].length; cell--;) {
var dot = parseInt(coordinates[row][cell]);
var color = dot === 3 ? '#c32733' : dot === 2 ? '#1155cc' : dot ? '#fff' : null;
args.unshift("border: 8px solid color;".replace('color', color));
eightBitHack.unshift("%c");
}
eightBitHack.unshift("\n");
}
eightBitHack.push("%c\n\n\n", "\nGet out and vote!");
eightBitHack.push("%c", "\nhttps://www.google.com/search?q=Where+do+I+vote+in+the+2016+United+States+election#eob=va/4/16/m.01n7q");
eightBitHack.push("%c\n\n\n", "\%cnmade by https://twitter.com/aristretto");
args.push("font-weight: bold;", "font-weight: bold; color: teal;", "font-weight: bold; color: teal;", "font-weight: bold; color: gray;");
args.unshift(eightBitHack.join(''));
console.log.apply(console, args);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment