Skip to content

Instantly share code, notes, and snippets.

@teyepe
teyepe / _function-z-index.scss
Last active February 6, 2017 12:54
Sass z-index function
$z-index: (
'under': -5,
'zero': 0,
'default': 5,
'over': 10
);
$z-level: (
'footer': 20,
'header': 30,
@teyepe
teyepe / _baseline-spacing.scss
Created September 27, 2016 21:51 — forked from razwan/_baseline-spacing.scss
SCSS mixin used to achieve consistent spacing between different typographic elements
$baseline-unit: 12px !default;
$baseline-debug: false !default;
@mixin baseline($baseline-font-size: 16px, $baseline-line-height: 1.25, $cap-height-ratio: 0.68, $margin-bottom: 3rem) {
$baseline-distance: ($baseline-line-height - $cap-height-ratio) / 2;
// set the proper font-size and line-height to size the element in multiples of baseline units
font-size: ($baseline-font-size / $baseline-unit) * 1rem;
line-height: $baseline-line-height;
@teyepe
teyepe / my.bash_profile
Last active May 23, 2016 07:19
A better git experience
# Load the default .profile
[[ -s "$HOME/.profile" ]] && source "$HOME/.profile"
# Load RVM into a shell session *as a function*
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
if [ -f $(brew --prefix)/etc/bash_completion ]; then
source $(brew --prefix)/etc/bash_completion
fi
@teyepe
teyepe / boilerplate_gulpfile.js
Last active May 21, 2016 19:34
QuickStart for gulp with a better error handling
// Include gulp
var gulp = require('gulp');
// Include Plugins
var jshint = require('gulp-jshint');
var sass = require('gulp-sass'),
neat = require('node-neat').includePaths;
var minifyCSS = require('gulp-minify-css');
var autoprefixer = require('gulp-autoprefixer');
var concat = require('gulp-concat');
// CMYK conversion function:
// [1] Coated_FOGRA27
// [2] Coated_FOGRA39
// [3] Coated_GRACoL_2006
// [4] Japan_Color_2001_Coated
// [5] Japan_Color_2001_Uncoated
// [6] Japan_Color_2002_Newspaper
// [7] Japan_Color_2003_Web_Coated
// [8] Japan_Web_Coated