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
$(document).ready(function () { | |
$("a.remove").click(function() { | |
$.post(this.href, {_method: "delete"}); | |
$(this).parent().remove(); | |
return false; | |
}); | |
}); |
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
$('p[time]').live('mouseover', function() { | |
var insertion = $(this); | |
var insertionTime = insertion.attr('time'); | |
var timeSpan = insertion.find('span.time'); | |
if (timeSpan.length) { | |
timeSpan.show(); | |
} else { | |
var date = new Date(); | |
date.setTime(insertionTime * 1000); |
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
plugin.onMessageInsertion = function(event){ | |
// regex is probably wrong | |
var github_status_expression = /https*:\/\/github.com\/(.*)\/(.*)/i; | |
var last_anchor = Talker.getLastInsertion().find('a'); | |
var last_href = last_anchor.attr('href') || ''; | |
if (github_status_expression.test(last_href)){ | |
var author = last_href.match(github_status_expression)[1]; |
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
// https://cheeaun.talkerapp.com/plugins/82 | |
// jQuery.nano template engine | |
// http://github.com/trix/nano | |
(function(c){c.nano=function(d,e){return d.replace(/\{([\w\.]*)}/g,function(a,f){a=f.split(".");var b=e[a.shift()];c.each(a,function(){b=b[this]});return b})}})(jQuery); | |
var vendorStyles = function(str){ | |
var s = str.split('-'); | |
if (s.length == 4 && s[0] == 'border'){ | |
var value = s[3].split(':')[1]; |
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
plugin.onMessageReceived = function(event){ | |
var vimeo_expression = /^(?:http\S+vimeo\.com\/)(\d+)/; | |
var vimeo_match = event.content.match(vimeo_expression); | |
if (vimeo_match){ | |
Talker.insertMessage(event, '<object width="400" height="220">' | |
+ '<param name="allowfullscreen" value="true" />' | |
+ '<param name="allowscriptaccess" value="always" />' | |
+ '<param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=' + vimeo_match[1] | |
+ '&server=vimeo.com&show_title=1&show_byline=1&show_portrait=0&color=&fullscreen=1" />' |
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
// https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Operators/Comparison_Operators | |
2 == "2" | |
true | |
2 === "2" | |
false | |
typeof 2 | |
"number" |
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
140 char limit sucks | |
Node.js matters because: | |
- JS programmers now have access to their language on the server (ignoring Netscape server for a minute). | |
- concurrent programming is the hot topic "du jour" and languages that embrace events like JS make for a good mix with this topic "du jour" | |
- Node.js is faster than Ruby yet still very expressive | |
- JS has a good chance to become the lingua franca for programmers much like PHP is for the web today. |
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
rr() { | |
rake | |
if [ $? -gt 0 ]; then | |
say "Some tests failed." | |
echo "Some tests failed." | |
else | |
say "All tests green." | |
echo "All tests green." | |
fi | |
} |
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
plugin.command = 'togglementionsound'; | |
plugin.usage = '/togglementionsound'; | |
plugin.onCommand = function(talkerEvent) { | |
if (talkerEvent.command == plugin.command) { | |
$.cookie('ReceivedMentionSound', ($.cookie('ReceivedMentionSound') == 'false' ? 'true': 'false'), { | |
expires: (function() { | |
var d = new Date(); | |
d.setTime(new Date().getTime() + 10 * 365 * 24 * 60 * 60 * 1000); | |
return d |
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
Watching Emma discover the world brings back memories of my own childhood. | |
Emma pats materials and things to see how it rubs against her tiny hands. She gets engrossed in the act of hitting two objects together. She doesn't just enjoy the sound they create but in her case often hears that specific sound for the first time. She looks at reflections on objects and is starting to notice that you can learn to follow those light patterns to their sources. She especially loves the metal bowls and the mirror-like surface of my tea pot. Perhaps the way everything is disproportionate in them amuses her. I guess big noses are innately funny. | |
I remember having similar moments as a child but my memory can't go as far back as what Emma is experiencing right now. I remember for instance the scratching sound made by those weird animated holograms. I remember being fascinated by the depth found in the VISA logo of my mother's credit card. I remember that weird feeling you get when your hair is in the proximity o |
OlderNewer