- GitHub Staff
- http://nathos.com
This file contains hidden or 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
// clearly, still in progress... | |
$fluidLayout: true | |
$fluidLayout: false !default | |
// Semantic grid mixins | |
@mixin row($fluid: $fluidLayout) | |
@if $fluid == true | |
width: 100% |
This file contains hidden or 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 category-colors($after: false) | |
@each $category in $categories | |
@if $after == true | |
.cat-#{nth($category, 1)}:after | |
background-color: nth($category, 2) | |
@else | |
.cat-#{nth($category, 1)} | |
background-color: nth($category, 2) |
This file contains hidden or 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 flippy($speed: 0.5s, $perspective: 500, $bgcolor: #fff) | |
position: relative | |
@include perspective($perspective) | |
.front, .back | |
background-color: $bgcolor | |
@include transition(all $speed ease-in-out) | |
@include backface-visibility(hidden) | |
@include transform-style(preserve-3d) | |
height: 100% | |
width: 100% |
This file contains hidden or 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 fancy-hover($sprite_dir, $off_state, $hover_state, $speed: 0.3s) | |
$sprites: sprite-map("#{$sprite_dir}/*.png") | |
$width: image-width(sprite_file($sprites, $off_state)) | |
$height: image-height(sprite_file($sprites, $off_state)) | |
@include hide-text | |
width: $width | |
height: $height | |
background: sprite($sprites, $off_state) no-repeat | |
display: block | |
position: relative |
This file contains hidden or 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
# LoremHelper - a placeholder content generator for Webby | |
# ======================================================= | |
# based on Travis Dunn's Frank - lorem.rb: | |
# - https://github.com/blahed/frank/blob/master/lib/frank/lorem.rb | |
# - original license: https://github.com/blahed/frank/blob/master/LICENSE | |
# | |
# LoremHelper creates placeholder content for your Webby [http://webby.rubyforge.org/] projects. | |
# It's great for quickly prototyping/wireframing a site. | |
# | |
# USAGE: |
This file contains hidden or 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
// be sure to import the the border-radius and box-shadow mixins: | |
// @import "compass/css3/border-radius" | |
// @import "compass/css3/box-shadow" | |
#menu | |
:margin-bottom 15px | |
:font-family "Lucida Grande", Arial, sans-serif | |
:font-size 11px | |
:font-weight bold | |
:padding 4px 6px |
This file contains hidden or 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(){ | |
var aff = 'nathos-20'; // replace 'nathos-20' with your Amazon affiliate ID, including the '-20' | |
if (!document.getElementById('ASIN')) { | |
alert('Can\'t find an Amazon product ID'); | |
return; | |
} | |
var asin = document.getElementById('ASIN').value; | |
prompt( | |
'Here is the shortened affiliate link:', | |
'http://amzn.com/' + asin + '?tag=' + aff); |
This file contains hidden or 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
module Webby | |
class Renderer | |
attr_reader :page | |
end | |
end | |
# To use add interlink to the list of filters in the layout. | |
# Creates links to pages using a MediaWiki-style syntax: | |
# | |
# [[main-page]] |
This file contains hidden or 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
affiliate_id = "nathos-20" | |
ARGF.each do |f| | |
f = f.scan(/(?:http:\/\/(?:www\.){0,1}amazon\.com(?:\/.*){0,1}(?:\/dp\/|\/gp\/product\/))(.*?)(?:\/.*|$)/i) | |
shorturl = "http://www.amazon.com/dp/" + f.to_s + "/ref=nosim/" + affiliate_id | |
if shorturl == ("http://www.amazon.com/dp//ref=nosim/" + affiliate_id) | |
puts "Not a valid Amazon URL" | |
else | |
puts shorturl | |
end |