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
@mixin box-shadow($shadow-1: default, $shadow-2: false, $shadow-3: false, $shadow-4: false, $shadow-5: false, $shadow-6: false, $shadow-7: false, $shadow-8: false, $shadow-9: false, $shadow-10: false) { | |
// This has to be on a single line due to a bug in the scss parser: https://github.com/nex3/sass/issues/issue/26 | |
$legacy: type-of($shadow-1) == color and type-of(if($shadow-2, $shadow-2, 0)) == number and type-of(if($shadow-3, $shadow-3, 0)) == number and type-of(if($shadow-4, $shadow-4, 0)) == number and type-of(if($shadow-5, $shadow-5, 0)) == number and ($shadow-6 == inset or type-of($shadow-6) == bool) and ($shadow-2 or $shadow-3 or $shadow-4 or $shadow-5 or $shadow-6); | |
@if $legacy { | |
@warn "Passing separate arguments for a single shadow to box-shadow is deprecated. " + "Pass the values as a single space-separated list, or use the single-box-shadow mixin. " + "See http://beta.compass-style.org/help/tutorials/upgrading/antares/ for more info."; | |
@include single-box-shadow(if($shadow-1, $shadow-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
w = container width | |
s = spacing | |
n = amount of columns | |
===== | |
CSS | |
===== | |
.columns { | |
width: w; /* Width is purely optional. Static, non-floating block elements default at 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
ul.nav | |
li.parent | |
a | |
ul.child | |
li | |
a | |
li | |
a | |
li | |
a |
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
def facebook_like(url) | |
if !url | |
url = 'http://spyder.com' | |
if !Rails.env.development? | |
"<li class=\"fblike\"><iframe src=\"http://www.facebook.com/plugins/like.php?app_id=243807848982732&href=#{URI.escape(url)}&send=false&layout=button_count&width=84&show_faces=false&action=like&colorscheme=light&font&height=21\" scrolling=\"no\" frameborder=\"0\" style=\"border:none; overflow:hidden; width:84px; height:21px;\" allowTransparency=\"true\"></iframe></li>" | |
end | |
end |
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
/** | |
* Content Formatting | |
* ================== | |
* Sensible formatting for formatted content. | |
* gist: http://gist.github.com/1150500 | |
*/ | |
/* Setting a default font */ | |
.content { font: 13px/1.5em sans-serif; } |
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
/* Replace the below element with the Slideshow */ | |
var $slideshow = $('#banner').html(''); | |
/* Pull in the JSON feed, place into divs */ | |
$(window).load(function() { | |
$.ajax({ | |
url : '/api/json/features/HOME_SLIDESHOW', | |
dataType : 'json', | |
success : function(data) { |
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
### | |
# Save this file, make it executable and then run it. | |
### | |
# Enable full keyboard access for all controls (e.g. enable Tab in modal dialogs) | |
defaults write NSGlobalDomain AppleKeyboardUIMode -int 3 | |
# Enable subpixel font rendering on non-Apple LCDs | |
defaults write NSGlobalDomain AppleFontSmoothing -int 2 |
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
// http://docs.jquery.com/Plugins/Validation/Methods/email | |
email: function(value, element) { | |
// contributed by Scott Gonzalez: http://projects.scottsplayground.com/email_address_validation/ | |
return this.optional(element) || /^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a- |
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 parameterize(value) { | |
// A simple function that parameterizes a string. | |
// Example: "This is a title" == "this-is-a-title" | |
if (typeof value === 'string' || value) { | |
var output = value.replace(/[^a-zA-Z0-9\s]/g,""); | |
output = output.toLowerCase(); | |
return output.replace(/\s/g,'-'); | |
} else { | |
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
#!/usr/bin/env ruby | |
file = File.expand_path(ARGV[0] || (STDERR.puts('you must specify a ruby file'); exit(-1))) | |
# Run in RVM | |
exec("[[ -s \"$HOME/.rvm/scripts/rvm\" ]] && source \"$HOME/.rvm/scripts/rvm\" && rvm use YOUR_RUBY@YOUR_GEMSET && ruby #{file}") | |
# ends here |