Skip to content

Instantly share code, notes, and snippets.

@tdhartwick
tdhartwick / _flip.scss
Last active October 8, 2015 16:54
The meat of css-flip-book!
.flip-book {
position: absolute;
bottom: 0;
right: 0;
width: $dimension;
height: $dimension;
}
//Preload images hack with CSS.
$string:'';
@tdhartwick
tdhartwick / _flip_variables.scss
Created October 1, 2015 23:20
The variables used for css-flip-book!
//Name of animation slides
$animation-name: 'walking';
//The name of the directory in the img folder where the slides live.
$directory-name: $animation-name;
//The screen width that the flip book starts.
$starting-width: 200px;
//The number of images you have for the flipbook.
$number-of-slides: 48;
//The number of times the animation repeats.
$number-of-repeats: 10;
<table class="menu">
<tr>
<td>
<a href="#">One</a>
</td>
<td>
<a href="#">Two</a>
</td>
<td>
<a href="#">Three </a>
<table class="menu">
<tr>
<td>
<a href="http://zurb.com">One</a>
</td>
<td>
<a href="http://zurb.com">Two</a>
</td>
<td>
<a href="http://zurb.com">Three </a>
var pipe = lazypipe()
.pipe($.inlineCss)
.pipe($.inject, gulp.src(cssMqPath), {
transform: function(path, file) {
return '<style>\n' + file.contents.toString() + '\n</style>';
}
})
.pipe($.htmlmin, {
collapseWhitespace: false,
minifyCSS: true
<table class="row">
<tr>
<th class="large-6 small-8 columns"></th>
<th class="large-6 small-4 columns"></th>
</tr>
</table>
@tdhartwick
tdhartwick / Emmet.sublime-settings
Created March 23, 2016 17:49
Foundation For Emails Emmet Snippets
{
//Custom Inky Snippets
"snippets": {
"html": {
"abbreviations": {
"row": "<row></row>",
"columns": "<columns small='12' large='12'></columns>",
"col": "<columns small='12' large='12'></columns>",
"container": "<container></container>",
"con": "<container></container>",
{
//Custom Inky Snippets
"snippets": {
"html": {
"abbreviations": {
"row": "<row></row>",
"columns": "<columns small='12' large='12'></columns>",
"col": "<columns small='12' large='12'></columns>",
"container": "<container></container>",
"con": "<container></container>",
@tdhartwick
tdhartwick / inky-browser.js
Created September 9, 2016 17:57
Snippet from Inky
var cheerio = require('cheerio');
var Inky = require('../lib/inky');
var inky;
window.setupInky = function(opts, cb) {
opts = opts || {};
opts.cheerio = Inky.mergeCheerioOpts(opts.cheerio);
if (typeof inky === 'undefined') {
inky = new Inky(opts);
@tdhartwick
tdhartwick / dist-inky-browser.js
Created September 9, 2016 18:01
Pocket-sized Inky
!function t(e,r,n){function i(s,a){if(!r[s]){if(!e[s]){var u="function"==typeof require&&require;if(!a&&u)return u(s,!0);if(o)return o(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var l=r[s]={exports:{}};e[s][0].call(l.exports,function(t){var r=e[s][1][t];return i(r?r:t)},l,l.exports,t,e,r,n)}return r[s].exports}for(var o="function"==typeof require&&require,s=0;s<n.length;s++)i(n[s]);return i}({1:[function(t,e,r){var n,i=(t("cheerio"),t("../lib/inky"));if(window.setupInky=function(t,e){function r(e,r){var i=n.releaseTheKraken(e,t.cheerio);r(null,i)}t=t||{},t.cheerio=i.mergeCheerioOpts(t.cheerio),"undefined"==typeof n&&(n=new i(t)),e(r)},"undefined"!=typeof window){window.runInky=function(t,e){"undefined"==typeof e&&(e=t,t={}),window.setupInky(t,function(t){t(e.outerHTML,function(t,r){null===t?e.outerHTML=r:console.log(t)})})};for(var o=document.body.getElementsByTagName("container"),s=0;s<o.length;s++)window.runInky(o[s])}},{"../lib/inky":3,cheerio:10}],2:[function(t,e