Skip to content

Instantly share code, notes, and snippets.

View epicmonkeez's full-sized avatar

Epic Monkeez epicmonkeez

  • Epic Monkeez
  • The Netherlands
View GitHub Profile
/**
* LESS mixin for Nash Image Replacement (http://nicolasgallagher.com/css-image-replacement-with-pseudo-elements/)
*/
.nir(@image, @width: 100%, @height: 100%) {
display: inline-block; overflow: hidden; width: @width; height: @height;
&:before {
content: url(@image);
display: inline-block; line-height: 0; font-size: 0;
}
@epicmonkeez
epicmonkeez / less-ie-rgba-mixin
Created March 13, 2012 19:21 — forked from kilokeith/less-ie-rgba-mixin
LESS IE rgba mixin
.ie_rgba(@hex, @alpha:256){
@newhex: `"#" + (Math.round("@{alpha}" * 256)).toString(16) + "@{hex}"`;
background: transparent;
-ms-filter: ~'"progid:DXImageTransform.Microsoft.gradient(startColorstr=@{newhex},endColorstr=@{newhex})"'; /* IE8 */
filter: ~'progid:DXImageTransform.Microsoft.gradient(startColorstr=@{newhex},endColorstr=@{newhex})'; /* IE6 & 7 */
zoom: 1;
}
@epicmonkeez
epicmonkeez / gist:2030904
Created March 13, 2012 19:21
LESS: Type control mixin
// type
.font-size(@font-size: 16){
@rem: (@font-size / 10);
font-size: @font-size * 1px;
font-size: ~"@{rem}rem"; }
.sans-serif {
font-family : "Helvetica Neue", Helvetica, Arial, sans-serif; }

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