Skip to content

Instantly share code, notes, and snippets.

View esteinborn's full-sized avatar

Eric Steinborn esteinborn

View GitHub Profile
@esteinborn
esteinborn / _default-variables.scss
Last active October 8, 2019 18:59
sass-migrator error
$base-font-color: hsla(0, 0%, 13%, 1); // 87% Black
$body-bg: $white !default;
$open-sans: 'open-sans', sans-serif;
$font-family-serif: $open-sans;
$font-family-base: $open-sans;
$body-font-size: 16px;
$letter-spacing: .03em;
$table-cell-padding: 1.25rem !default;
$table-condensed-cell-padding: 1rem !default;
$table-bg: hsla(0, 0%, 95%, .7);
@esteinborn
esteinborn / gulpfile.js
Last active February 19, 2019 21:41
Gulp 4 Gulpfile
/* global require exports */
/* eslint-env node */
/* eslint no-console: 0 */
/* eslint max-len: 0 */
/* eslint prefer-destructuring: 0 */
const {
watch,
series,
src,
@esteinborn
esteinborn / pptpVPNreconnect
Created February 11, 2016 02:55
REconnect PPTP VPN profile for Synology
#!/bin/sh
#version 2014-04-26
VPNC_CONNECTING="/usr/syno/etc/synovpnclient/vpnc_connecting"
#get connection name
CONNECTION=`cat /usr/syno/etc/synovpnclient/pptp/pptpclient.conf | grep conf_name | awk 'BEGIN {FS="="} {print $2}'`
#get connection id
ID=`ls /usr/syno/etc/synovpnclient/pptp/ | grep options | awk 'BEGIN {FS="_"} {print $2}' | awk 'BEGIN {FS="."} {print $1}'`
@esteinborn
esteinborn / SassMeister-input.scss
Created July 10, 2015 18:48
Generated by SassMeister.com.
// ----
// Sass (v3.4.14)
// Compass (v1.0.3)
// Zen Grids (v1.4)
// ----
@import "zen";
$bp-large: 1024px;
%zen-grid-1-1 {
@esteinborn
esteinborn / bling.js
Last active August 29, 2015 14:23 — forked from paulirish/bling.js
/* bling.js */
window.$ = document.querySelectorAll.bind(document)
Node.prototype.on = window.on = function (name, fn) {
this.addEventListener(name, fn)
}
NodeList.prototype.__proto__ = Array.prototype
@mixin breakpoint($size: "", $maxWidth: false, $noMQSelector: "") {
@if $size == "" {
$size: 55em; // Put your "main" or most-used breakpoint here to use it as a default
}
@if $noMQSelector == true {
$noMQSelector: ".oldie"; // this is the default catch all selector, jsut pass true, unquoted.
}
// Default, `min-width` media query
@font-face {
font-family: 'MyFontFamily';
src: url('myfont-webfont.eot?#iefix') format('embedded-opentype'),
url('myfont-webfont.woff') format('woff'),
url('myfont-webfont.ttf') format('truetype'),
url('myfont-webfont.svg#svgFontName') format('svg');
}
@esteinborn
esteinborn / picturefill.sublime-snippet
Created March 7, 2014 17:30
Picturefill Sublime Snippet
<snippet>
<content><![CDATA[
<span ${1:class="${2}"} data-picture data-alt="${3:Moar Internets!}">
<span data-src="${4:file}${5:.jpg}"></span>
<span data-src="${4:file}-x2${5:.jpg}" ${6:data-media="(${7:min-width}: ${8:400px})"}></span>
<span data-src="${4:file}-x3${5:.jpg}" ${9:data-media="(${10:min-width}: ${11:800px})"}></span>
</span>
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>pic</tabTrigger>
@esteinborn
esteinborn / Default (Windows).sublime-keymap
Last active June 8, 2016 15:37
My Sublime Text Snippets and Config
[
{ "keys": ["home"], "command": "move_to", "args": {"to": "hardbol", "extend": false} },
{ "keys": ["end"], "command": "move_to", "args": {"to": "hardeol", "extend": false} },
{ "keys": ["shift+end"], "command": "move_to", "args": {"to": "hardeol", "extend": true} },
{ "keys": ["ctrl+home"], "command": "move_to", "args": {"to": "hardbof", "extend": false} }
]
@esteinborn
esteinborn / jquery-touch-or-click.js
Created March 6, 2014 20:19
Detect whether its a touch or click even that should be fired. jQuery.
// This checks document to see if touchstart exists
// if it does, then your event is 'touchstart'
// if it doesn't (most desktop browsers) then its 'click'.
var clickEventType = ((document.ontouchstart!==null)?'click':'touchstart');
// Old .bind don't use
$('.foo').bind(clickEventType, function(e){});
//Better yet, use .on() for binding:
$('body').on(clickEventType, '.foo', function(e){});