Skip to content

Instantly share code, notes, and snippets.

View apathetic's full-sized avatar

wes hatch apathetic

View GitHub Profile
@apathetic
apathetic / gist:3077908
Created July 9, 2012 18:01
dynamically generated parallax
/*
* dynamically-generated parallax
* A work in progress. Parse the page for various data attributes (used as options) which are
* used to vary the scrolling on these blocks accordingly
*/
var NA = (function(options){
var settings = { };
@apathetic
apathetic / gist:3055575
Created July 5, 2012 18:39
resize background image to fit (updated)
/*
* Background Resizer
* Uses css3 to resize bg images to fit a container, with a js fallback for IE
*/
/* ( there could be multiple slides in #bg ) */
#bg article {
position:absolute;
width:100%;
@apathetic
apathetic / gist:2760746
Created May 21, 2012 06:11
jQuery: Annoytify
/*
* ANNOYtify
* a notifier that pops up on the bottom of the page when user scrolls sufficiently.
* docks / minimizes in place when not shown
*/
// -------------
// sample js
// -------------
(function( $ ){
@apathetic
apathetic / Text Swapper
Created May 21, 2012 06:09
jQuery: swappy
/*
* text swappy
* experiment in transitioning individual letters in different headers
* requires: textshadow.js, color.js (minified at the bottom)
*
* really just a work in progress I needed to temporarily share
*/
(function($){
@apathetic
apathetic / gist:2760702
Created May 21, 2012 06:06
jQuery: jump nav
/*
* scroll navigation
* parses html for data-nav and construct smoothly-scrolling menu
*/
/* old stuff....
// scroll navigation
$.fn.jumpy = function (argument) {
@apathetic
apathetic / Tabbify
Created May 21, 2012 06:03
jQuery: Tabbify
/*
* tabbify
* makes the tabs and does tab-related things
*/
// -------------
// sample css
// -------------
ul.tabs { height:28px; margin:0; }
@apathetic
apathetic / gist:2760693
Created May 21, 2012 06:00
jQuery: carousel
/*
* carousel
* simple carousel for my own use, inspired by ghanesh's implementation
*/
// -------------
// sample css
// -------------
.carousel { position:relative; width:248px; padding:12px 32px; overflow:hidden; }
.carousel ul { width:2000px; }
@apathetic
apathetic / hover fx
Created June 25, 2010 19:12
css text shadow transform
a { -webkit-transition: all 0.12s ease-out; }
a:hover { text-shadow: #E58 1px 1px, #E58 2px 2px, #E58 3px 3px, #E58 4px 4px, #E58 5px 5px, #E58 6px 6px, #E58 7px 7px, #E58 8px 8px, #E58 9px 9px, #E58 10px 10px, #E58 11px 11px; }
a.big:hover { -webkit-transform: scale(1.25); }