This file contains hidden or 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
# http://codepen.io/morewry/pen/pvLxPV | |
# manually create touch event | |
touchStartOn = (el, x = 0, y = 0) -> | |
try | |
e = document.createEvent('TouchEvent') | |
e.initTouchEvent("touchstart", true, true) | |
catch err | |
try | |
e = document.createEvent('UIEvent') |
This file contains hidden or 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 named buffer. Will append to existing content captured there. | |
// The buffer can be accessed via get-capture("foo") or @emit "foo". | |
@capture "foo" { | |
@media screen { | |
.asdf { | |
.qwerty { | |
/* This is a comment */ | |
color: red; | |
} | |
} |
This file contains hidden or 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
// ---- | |
// Sass (v3.3.7) | |
// Compass (v1.0.0.alpha.18) | |
// ---- | |
// Prototypal inheritance in Sass | |
// Disclaimer: might be totally contrived and useless... | |
// “It’s not about the destination, but the journey.” | |
// New operator |
This file contains hidden or 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
/* | |
# Convert Units (function) | |
TODO: Description | |
*/ | |
// --------------------------------------- | |
@function convert-units ( $length, $as: rem, $root: 16, $ppi: 96 ) { | |
$unit: unit($length); |
This file contains hidden or 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
// --------------------------------------- | |
/* | |
## Set / Get | |
http://cdpn.io/hgLal | |
*/ | |
// --------------------------------------- |
This file contains hidden or 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
/* | |
# Responsive Design Utilties | |
A few Sass functions and mixins helpful for responsive designs including a function to convert between CSS measurement units and a respond-to media query mixin that supports comma-separated "or" queries. | |
*/ | |
// --------------------------------------- | |
// --------------------------------------- | |
/* |
This file contains hidden or 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
# make ad hoc compass frameworks behave (show up in list, be import-able like normal) | |
# custom vars | |
thisplugin_dir = (yours) | |
# compass config | |
extensions_dir = (yours) | |
extensions_path = project_path + extensions_dir | |
additional_import_paths = [extensions_dir, extensions_dir + thisplugin_dir + 'stylesheets'] |
This file contains hidden or 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
// --------------------------------------- | |
/* | |
http://codepen.io/morewry/pen/meBtj | |
Use case for defaults: | |
providing interface points to override framework defaults with more flexibility and granularity than variables can reasonably provide, ie customize normalizations without editing the stylesheet directly (@content in reverse) | |
Use case for swapping extend or include: |
This file contains hidden or 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
/* | |
# Print Map | |
Usage: | |
// option 1 | |
.debug { | |
@include print-map($map); | |
} |
This file contains hidden or 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
/* | |
# Sprite (Theme) | |
*/ | |
// --------------------------------------- | |
// Config | |
$disable-magic-sprite-selectors: true; | |
$sprite-default-margin: 1px; | |
$sprite-debug: true; |