Skip to content

Instantly share code, notes, and snippets.

@jelder
Created October 14, 2013 17:22
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jelder/6978969 to your computer and use it in GitHub Desktop.
Save jelder/6978969 to your computer and use it in GitHub Desktop.
// Generate a set of 128x128 png icons for notifications from our color palette.
// Order must match .status-box:nth-of-type() declarations.
var color_data = {
"#1564f9": "UVZPl4Z7ha",
"#3fc41b": "U/xButvkTR",
"#fa8e1f": "X6jh83IXPs",
"#4ca8ea": "VMqOr4+3T5",
"#f71347": "X3E0eeps0u",
"#fcc124": "X8wST1RrWw"
};
var icons = [];
var colors = [];
$.each(color_data, function(color, magic){
colors.push(color);
icons[color] = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACAAQMAAAD58POIAAAAA1BMVE"+magic+"AAAAGElEQVR4AWOgMxgFo2AUjIJRMApGwSgAAAiAAAH3bJXBAAAAAElFTkSuQmCC"
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment