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
/** | |
* A "deeper" indented text effect with the :before and :after pseudo-elements. | |
*/ | |
html, body { | |
height: 100%; | |
} | |
body { | |
margin: 0; |
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
/** | |
* Pure CSS stopwatch | |
*/ | |
* { box-sizing: border-box; -moz-box-sizing: border-box } | |
html { background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAAECAYAAACp8Z5+AAAAOklEQVQIWx3K2QkAMAgFwadEsBjF/ksTD0Kyn8uQme05BzOD3QW5+2YmVBWvP6oKIoLuBkXEF48zMy6Jfxr7Roi85AAAAABJRU5ErkJggg==) } | |
body { | |
text-align: center; |
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
/* | |
* Pure CSS aspect ratio with no spacer images or js! :) | |
*/ | |
body { | |
width: 36%; | |
margin: 8px auto; | |
} | |
div.stretchy-wrapper { |
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
/** | |
* keyframe animation test | |
*/ | |
@-webkit-keyframes myanim { | |
50% { background: blue } | |
} | |
@-moz-keyframes myanim { | |
50% { background: blue } |
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.bind polyfill: | |
open.bind||(Function.prototype.bind=function(b){function c(){return d.apply(this instanceof a&&b?this:b,e.concat([].slice.call(arguments)))}function a(){}var e=[].slice.call(arguments,1),d=this;a.prototype=this.prototype;c.prototype=new a;return c}); |
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.prototype.bind=(function(){}).bind||function(b){if(typeof this!=="function"){throw new TypeError("Function.prototype.bind - what is trying to be bound is not callable");}function c(){}var a=[].slice,f=a.call(arguments,1),e=this,d=function(){return e.apply(this instanceof c?this:b||window,f.concat(a.call(arguments)));};c.prototype=this.prototype;d.prototype=new c();return d;}; |
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
/* Change selection color------------------------------------------------------------*/ | |
::-moz-selection { background: #000; color: #fff; text-shadow: none } | |
::selection { background: #000; color: #fff; text-shadow: none } |
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
<!--[if lt IE 9]><script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]--> |
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
for (var i = document.images.length; i--;) { | |
document.images[i].src = 'cat.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
codeElements = document.getElementsByTagName('code'); | |
for (var i = codeElements.length; i--;) { | |
codeElements[i].onclick = function() { | |
var range; | |
if (document.selection) { | |
range = document.body.createTextRange(); | |
range.moveToElementText(this); | |
range.select(); | |
} |
OlderNewer