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($canvas) { | |
var | |
// STORE DEFAULT CELL ATTRS | |
cellAttrs = { | |
fill: "#E0E4CD", | |
stroke: "#000", | |
"stroke-width": 2 | |
}, | |
// SET UP CELL ARRAY | |
$cells = [], |
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
Array | |
+ concat | |
+ every | |
+ filter | |
+ forEach | |
+ indexOf | |
+ join | |
+ lastIndexOf | |
+ length | |
+ map |
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
/* | |
Usages: | |
$(selector).classList() //returns an array of classnames | |
$(selector).classList('newclass') //replaces the current element's classes | |
$(selector).classList(['new', 'class', 'names']) //replaces the current element's classes | |
*/ | |
jQuery.fn.extend({ | |
classList: function( value ) { | |
if( value ){ |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>jquery.classes.js</title> | |
<script src="jquery-1.4.2.js"></script> | |
<script src="jquery.classes.js"></script> | |
</head> | |
<body> | |
<p class="foo bar baz">classes: foo, bar, baz</p> |
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
import urllib | |
import optparse | |
import os.path | |
import pickle | |
def truncate(message,limit): | |
if len(message) > limit: | |
# break off at 137 chars and concat elipsis | |
return message[:(limit-3)] + "..." |
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
.mouse{ | |
position: absolute; | |
background-image: url('../images/cursor.png'); | |
width: 15px; | |
height: 22px; | |
z-index: 100; | |
} |
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
Burst({ | |
'arbitrary-timeline-name' : { | |
start: 0, | |
frames: 100, | |
ratio: 1, | |
loop: false, | |
finish: function () {}, | |
tracks: { | |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Badges</title> | |
</head> | |
<body> | |
<script src="badge.js?type=jedi"></script> | |
<script src="badge.js?type=ninja"></script> | |
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
<script src="caret.js"></script> |
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
$.mines.detonate('/fuse/c', ['message']); | |
$.mines.detonate([ | |
{ | |
key: '/fuse/a', | |
args: ['message from fuse a', { foo: 'bar' }] | |
}, | |
{ | |
key: '/fuse/b', |