Skip to content

Instantly share code, notes, and snippets.

View lunelson's full-sized avatar
👀
Reading

Lu Nelson lunelson

👀
Reading
View GitHub Profile
@lunelson
lunelson / SassMeister-input.scss
Created January 30, 2014 10:50
Another Scratchpad for MQ system
// ----
// libsass (v0.7.0)
// ----
@import "sass-list-maps";
@function get($args...) {
@return map-get-z($args...);
}
@function merge($args...) {
@return map-merge-z($args...);
@lunelson
lunelson / SassMeister-input.scss
Created January 30, 2014 11:20
Optimized `set-nth()` vs old `replace-nth()`
// ----
// libsass (v0.7.0)
// ----
/*
comparison of old and new replace-nth / set-nth
*/
// algorithm copied from early version of sassylists
@function replace-nth($list, $value, $index, $sep: 'comma') {
@lunelson
lunelson / SassMeister-input.scss
Created February 10, 2014 12:25
Ref for libsass issue
// ----
// Sass (v3.3.0.rc.3)
// Compass (v1.0.0.alpha.18)
// ----
@mixin hidpi($num, $denom: 1) {
@media
(-webkit-min-device-pixel-ratio: $num/$denom),
(min--moz-device-pixel-ratio: $num/$denom),
(-o-min-device-pixel-ratio: #{$num}/#{$denom}),
@lunelson
lunelson / SassMeister-input.scss
Last active August 29, 2015 13:56
Additional functions for Sass List Maps
// ----
// Sass (v3.2.14)
// Compass (v0.12.2)
// Sass List-Maps (v0.9.3)
// ----
@import "sass-list-maps";
/*
EXTRA FUNCTIONS FOR SASS LIST MAPS
@lunelson
lunelson / SassMeister-input.scss
Created February 14, 2014 11:49
Demo of new 3.3rc3+ syntax WRT &
// ----
// Sass (v3.3.0.rc.3)
// Compass (v1.0.0.alpha.18)
// ----
// Configuration variables
// Type name | color scheme
$message-types: (
error : #b94a48,
alert : #c09853,
@lunelson
lunelson / parallaxbgs.js
Created February 24, 2014 10:51 — forked from jofralogo/parallaxbgs.js
Parallax backgrounds for non-touch devices (using jQuery & Modernizr)
/*
HTML SYNTAX:
<div id="example" data-parallax-bg="false" data-parallax-bg-speed="1.5">
CONTENT
</div>
IMPORTANT:
Don't forget tu place the background-image on your css file:
@lunelson
lunelson / SassMeister-input.scss
Created February 28, 2014 12:57
Sketch for font-face mixin
// ----
// Sass (v3.3.0.rc.5)
// Compass (v1.0.0.alpha.18)
// ----
$font-path: 'assets/src/fonts/';
@mixin font-face($family, $file, $style: normal, $weight: normal, $path: $font-path) {
@font-face {
font-family: $family;
@lunelson
lunelson / SassMeister-input.scss
Created February 28, 2014 15:31
Sass List Maps 0.9.5 release version
// ----
// libsass (v0.7.0)
// ----
// list helper functions
// 0.9.3 -- "list()" now deprecated in favor of "zip()".
// 0.9.5 -- "zip()" now deprecated as well: single-pair lists are handled automatically
@function list($args...) {
$output: ();
@lunelson
lunelson / SassMeister-input.scss
Created March 4, 2014 09:33
Test of alternate declaration for base values
// ----
// Sass (v3.3.0.rc.5)
// Compass (v1.0.0.alpha.18)
// ----
$base-data: (
'font-size': 16px,
'line-height': 1.5,
'margin-x': 1rem,
'margin-y': 1rem,
@lunelson
lunelson / SassMeister-input.scss
Created March 4, 2014 16:42
Generated by SassMeister.com.
// ----
// Sass (v3.2.14)
// Compass (v0.12.2)
// Sass List-Maps (v0.9.3)
// ----
@import "sass-list-maps";
$opposite: (