Skip to content

Instantly share code, notes, and snippets.

View jholl's full-sized avatar

James Holland jholl

View GitHub Profile
@jholl
jholl / variables-custom.less
Created November 29, 2013 13:28
BS v3 variables-custom.less -- add @import "rootfoo/variables-custom.less" to compiling .less file
/* Flat UI @design-modo */
@fui-turq-lt: #1abc9c;
@fui-turq: #16a085;
@fui-green-lt: #2ecc71;
@fui-green: #27ae60;
@fui-blue-lt: #3498db;
@fui-blue: #2980b9;
@fui-purple-lt: #9b59b6;
@fui-purple: #8e44ad;
@fui-navy-lt: #34495e;
@jholl
jholl / level-like
Created January 2, 2014 19:46
level like objects
<script type="text/javascript">
$(document).ready(function(){
H = 0;
$('.foo').each(function(){
if ($(this).innerHeight() > H){
H = $(this).innerHeight();
}
});
$('.foo').height(H);
});
$(document).on('scroll',function(){
var winTop = $(window).scrollTop();
var $object = $('.some-div');
$object.each(function(){
var objTopTrigger = this.offsetTop;
var objTopTriggerAdj = 400;
if (objTopTrigger + objTopTriggerAdj < winTop){
$(this).addClass('some-class');
}
if (objTopTrigger + objTopTriggerAdj > winTop){
@jholl
jholl / sba_counties.json
Created March 23, 2015 00:42
SBA Data US County by US State
[
{
"county_name": null,
"description": null,
"feat_class": "Civil",
"feature_id": "36609",
"fips_class": "H1",
"fips_county_cd": "69",
"full_county_name": null,
"link_title": null,
@jholl
jholl / gist:34e419a42040f24f7562
Created March 27, 2015 20:10
gulpfile for laravel angular bower build
var elixir = require('laravel-elixir');
var paths = {
'bower': './vendor/bower_components/'
};
var paths = {
'fonts': 'resources/assets/fonts/',
'img': 'resources/assets/img/',
'svg': 'resources/assets/svg',
'sass': 'resources/assets/sass/',
'js': 'resources/assets/js/',
@jholl
jholl / DatabaseSeeder.php
Created March 27, 2015 22:49
DatabaseSeeder to extend table cleanups/seeding ea. run (Laravel 5)
<?php
use Illuminate\Database\Seeder;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Filesystem\Filesystem;
class DatabaseSeeder extends Seeder {
/**
* Seeders to run.
$(document).ready(function(){
// Create two variables:
// 1) Create a '<span></span>' element that we'll eventually put into the DOM
// 2) Cache the container already in the DOM where we'll put the span
var itemCountSpan = document.createElement("SPAN"),
cart = document.getElementById('cart-icon-wrapper');
// Set the initial text and class for the span before we put into the DOM