Skip to content

Instantly share code, notes, and snippets.

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Nice Buttons</title>
<style>
* { margin: 0; padding: 0; }
ul {
padding: 20px;
width: 80px;
float: left;
@dara
dara / My Textmate Theme
Created March 8, 2011 17:24
Textmate theme based on Railscasts theme.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>Railscasts Modified</string>
<key>settings</key>
<array>
<dict>
<key>settings</key>
@dara
dara / autosize_wrapper.js
Created June 25, 2011 12:17
Autosize Wrapper
var windowHeight;
$('#wrapper').css('height', $(window).height());
$(window).resize(function() {
windowHeight = $(window).height();
$('#wrapper').css('height', windowHeight);
});
@dara
dara / scrollto.js
Created June 25, 2011 12:19
Scroll To
$('.linked_to_projects').click(function(){
$('html, body').animate({
scrollTop: $("#projects").offset().top
}, 750);
});
$('#projects ul li img').click(function(){
$('html, body').animate({
scrollTop: $("#projects-show").offset().top
}, 750);
@dara
dara / gist:4523349
Created January 13, 2013 09:59
.irbrc
require 'rubygems'
require 'hirb'
extend Hirb::Console
Hirb::View.enable
@dara
dara / good.css
Last active December 18, 2015 21:38
*, *:before, *:after {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.float-left {
float: left;
}
@dara
dara / Sass Mixins
Last active December 20, 2015 02:09 — forked from brentvatne/gist:1218364
//using the technique from: http://colinaarts.com/articles/inline-block-and-you/
@mixin cross-browser-inline-block {
display: inline-block; /* For normal, healthy browsers */
* html & { /* for IE6 */
display: inline;
}
*+html & { /* for IE7 */
// Safari Pesticide Bookmarklet
// Based on http://pesticide.io
javascript:(function(){
var pesticideStyles = document.getElementById('pesticide-styles'),
head = document.head || document.getElementsByTagName('head')[0],
css = 'body{outline:1px%20solid%20#2980b9%20!important}article{outline:1px%20solid%20#3498db%20!important}nav{outline:1px%20solid%20#0088c3%20!important}aside{outline:1px%20solid%20#33a0ce%20!important}section{outline:1px%20solid%20#66b8da%20!important}header{outline:1px%20solid%20#99cfe7%20!important}footer{outline:1px%20solid%20#cce7f3%20!important}h1{outline:1px%20solid%20#162544%20!important}h2{outline:1px%20solid%20#314e6e%20!important}h3{outline:1px%20solid%20#3e5e85%20!important}h4{outline:1px%20solid%20#449baf%20!important}h5{outline:1px%20solid%20#c7d1cb%20!important}h6{outline:1px%20solid%20#4371d0%20!important}main{outline:1px%20solid%20#2f4f90%20!important}address{outline:1px%20solid%20#1a2c51%20!important}div{outline:1px%20solid%20#036cdb%20!important}p{outline:1px%20solid%
@dara
dara / tumblr_blog_info.js
Created December 7, 2015 11:30
Get total posts number from Tumblr
var totalPosts;
blogInfoCallback = function(data) {
totalPosts = data.response.blog.posts;
};
jQuery.ajax({
type: "GET",
url : "http://api.tumblr.com/v2/blog/_BLOG_URL_/info",
dataType: "jsonp",
/* Extracted from Animate.css */
.animated {
-webkit-animation-duration: 0.6s;
animation-duration: 0.6s;
-webkit-animation-fill-mode: both;
animation-fill-mode: both;
}
@-webkit-keyframes fadeInUpMicro {