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
/* | |
You can now create a spinner using any of the variants below: | |
$("#el").spin(); // Produces default Spinner using the text color of #el. | |
$("#el").spin("small"); // Produces a 'small' Spinner using the text color of #el. | |
$("#el").spin("large", "white"); // Produces a 'large' Spinner in white (or any valid CSS color). | |
$("#el").spin({ ... }); // Produces a Spinner using your custom settings. | |
$("#el").spin(false); // Kills the spinner. |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Loading Pixels · CodePen</title> | |
<!-- | |
Copyright (c) 2012 leison, http://codepen.io/leison | |
Permission is hereby granted, free of charge, to any person obtaining |
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
<!-- LiveReload --> | |
<script>document.write('<script src="http://' + (location.host || 'localhost').split(':')[0] + ':35729/livereload.js?snipver=1"></' + 'script>')</script> |
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
css="`cat assets/css/main.css`" && curl -sSd css="$css" http://prefixr.com/api/index.php > assets/css/main.css |
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 generateNoise(opacity) { | |
if ( !!!document.createElement('canvas').getContext ) { | |
return false; | |
} | |
var canvas = document.createElement("canvas"), | |
ctx = canvas.getContext('2d'), | |
x, y, | |
number, | |
opacity = opacity || .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
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black" /> | |
<link rel="apple-touch-startup-image" href="img/splash-screen.png" /> | |
//iPad Landscape | |
<link rel="apple-touch-startup-image" sizes="1024x748" href="img/splash-screen-1024x748.png" /> | |
//iPad Portrait | |
<link rel="apple-touch-startup-image" sizes="768x1004" href="img/splash-screen-768x1004.png" /> | |
//iPhone Portrait | |
<link rel="apple-touch-startup-image" href="img/splash-screen-320x460.png" /> |
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
// Landscape phones and down | |
@media (max-width: 480px) { ... } | |
// Landscape phone to portrait tablet | |
@media (max-width: 767px) { ... } | |
// Portrait tablet to landscape and desktop | |
@media (min-width: 768px) and (max-width: 979px) { ... } | |
// Large desktop |
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
<script type="text/javascript"> | |
/** | |
* Attach an event handler on a given Node taking care of Browsers Differences | |
* @param {Object} node | |
* @param {String} type | |
* @param {Function} fn | |
* @param {Boolean} capture | |
*/ | |
function addEventHandler(node,type,fn , capture){ | |
if(typeof window.event !== "undefined"){ |
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
<script> | |
<!-- | |
if ((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i))) { | |
location.replace("http://xxx"); | |
} | |
--> | |
</script> |
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
<script> | |
(function(doc) { | |
var addEvent = 'addEventListener', | |
type = 'gesturestart', | |
qsa = 'querySelectorAll', | |
scales = [1, 1], | |
meta = qsa in doc ? doc[qsa]('meta[name=viewport]') : []; | |
function fix() { |