Skip to content

Instantly share code, notes, and snippets.

View marciobarrios's full-sized avatar

Marcio Barrios marciobarrios

View GitHub Profile
@marciobarrios
marciobarrios / dabblet.css
Created January 29, 2012 23:26 — forked from daneden/dabblet.css
Path icon hover
/**
* Path icon hover
*
* Example of the desired effect (hover over the user avatar) https://path.com/p/5Eplz
*
* Close, but annoying that the animation runs on page load.
* Possible solution could be to fade entire page content in while initial
* animation runs.
*/
@marciobarrios
marciobarrios / dabblet.css
Created January 31, 2012 19:35
Path icon hover
/**
* Path icon hover
*
* Example of the desired effect (hover over the user avatar) https://path.com/p/5Eplz
*
* Close, but annoying that the animation runs on page load.
* Possible solution could be to fade entire page content in while initial
* animation runs.
*/
@marciobarrios
marciobarrios / dabblet.css
Created February 9, 2012 10:12 — forked from LeaVerou/dabblet.css
Move in a circle without wrapper elements
/**
* Move in a circle without wrapper elements
* Idea by Aryeh Gregor, simplified by Lea Verou
*/
@keyframes rot {
from {
transform: rotate(0deg)
translate(-150px)
rotate(0deg);
@marciobarrios
marciobarrios / csslint-api.js
Created February 11, 2012 11:20 — forked from nzakas/csslint-api.js
CSS Lint API
//include
var CSSLint = require("csslint").CSSLint;
/*
* Basic usage
* First argument is the CSS text.
* Second argument is the options object. Name is the ID of the rule (see wiki) set to
* either 1 for a warning or 2 for an error.
*/
var result = CSSLint.verify(".foo { }", { "compatible-vendor-prefixes": 1 }),
@marciobarrios
marciobarrios / gist:1810846
Created February 12, 2012 21:05 — forked from abozhilov/gist:1779852
HashMap
var HashMap = (function () {
var PROTO_SUPPORT = !Object.prototype.isPrototypeOf({__proto__ : null}),
OBJECT_CREATE = typeof Object.create != 'undefined',
DONT_ENUM_BUG = !{'toString' : true}.propertyIsEnumerable('toString');
var hasOwnP = {}.hasOwnProperty,
dontEnums = [];
if (DONT_ENUM_BUG) {
dontEnums = [
@marciobarrios
marciobarrios / dabblet.css
Created February 13, 2012 14:56 — forked from daneden/dabblet.css
Slider
/**
* Slider
*/
* {
margin: 0;
padding: 0;
}
html {
@marciobarrios
marciobarrios / dabblet.css
Created February 13, 2012 14:56 — forked from daneden/dabblet.css
Slider
/**
* Slider
*/
* {
margin: 0;
padding: 0;
}
html {
@marciobarrios
marciobarrios / gist:1864721
Created February 19, 2012 17:25 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
/**
* Thumbnail attempt 1, taken from http://dribbble.com/shots/406640-Image-Thumbs-free-PSD-
*/
body { padding: 10em 0; text-align: center; }
a { position: relative; display: inline-block; }
a img { display: block; margin: 0 auto; }
a:before {
content:"";
position: absolute;
/**
* CSS Thumbnail, design taken from http://dribbble.com/shots/406640-Image-Thumbs-free-PSD-
*/
body { padding: 10em 0; text-align: center; background: url(http://cl.ly/EOkc/farmer.png) }
a, span { position: relative; display: inline-block; }
img { display: block; }
span { overflow: hidden; }
span:after {
content: "";