Skip to content

Instantly share code, notes, and snippets.

View lrobeson's full-sized avatar

Laura Robeson lrobeson

View GitHub Profile
@lrobeson
lrobeson / SassMeister-input-HTML.html
Created February 16, 2016 21:26
Generated by SassMeister.com.
<body>
<h1>Panels Layout Template</h1>
<div class="layout-panels-sidebar-left">
<div class="layout-preface">
<h1>Preface Region</h1>
Veggies es bonus vobis, proinde vos postulo essum magis kohlrabi welsh onion daikon amaranth tatsoi tomatillo melon azuki bean garlic.
</div>
<aside class="layout-sidebar">
<h1>Sidebar Region</h1>
@lrobeson
lrobeson / Preferences.sublime-settings
Created December 30, 2015 19:54
Backup of my Sublime Text user preferences
{
"Seti_sb_tree_med": true,
"bold_folder_labels": true,
"caret_style": "phase",
"color_scheme": "Packages/User/SublimeLinter/Seti_orig (SL).tmTheme",
"fade_fold_buttons": false,
"file_exclude_patterns":
[
"*.pyc",
"*.pyo",
@lrobeson
lrobeson / resizer.js
Last active June 3, 2023 12:14
Viewport Resizer tweaks
// Forked from
// http://lab.maltewassermann.com/viewport-resizer/
(function(o, y, O) {
var ca = "https:" === location.protocol ? "http://" : "http://",
da = y.createElement("script"),
ea = y.getElementsByTagName("script")[0];
da.src = ca + "ajax.googleapis.com/ajax/libs/jquery/a2.0.1/jquery.min.js";
ea.parentNode.insertBefore(da, ea);
y.close();
@lrobeson
lrobeson / Seti_orig.sublime-theme
Last active December 21, 2015 19:41
Backup of my Sublime Text theme
[
//========================================================
// TABS (REGULAR)
//--------------------------------------------------------
// Tab set
{
"class": "tabset_control",
"layer0.texture": "Seti_UI/Main/tabset-background.png",
"layer0.inner_margin": [1, 7],
"layer0.opacity": 1,
@lrobeson
lrobeson / prepare-commit-msg
Last active December 17, 2015 17:43
Prepend ticket number to Git commit message
#!/bin/sh
#
# A hook script to prepare the commit log message.
#
# This example prepends the ticket number (read from the feature branch name)
# and formats it according to F1 Git standards.
#
# To use:
# Make a copy of .git/hooks/prepare-commit-msg.sample in your repo and name the file prepare-commit-msg (remove "sample" extension)
# Paste the following into the file, save the file, and try it out.
@lrobeson
lrobeson / settings.php
Created October 27, 2015 00:08
Drupal: remove query strings from CSS filenames (CacheBuster)
// Remove Query Strings from CSS filenames (CacheBuster)
$vars['styles'] = preg_replace('/\.css\?[^"]+/','.css', $vars['styles']);
@lrobeson
lrobeson / _slider.scss
Created October 26, 2015 23:57
Slider component using 'fugly selectors' and styleguide driven design methodology
// Slider component
//
// Using 'fugly selectors' and styleguide driven design methodology
// source: https://www.previousnext.com.au/blog/decouple-design-styleguide-driven-drupal-development
//
// Markup:
// <div class="container">
// <h2 class="container__title">Title</h2>
// <div class="slider">
// <div class="slider__container">
@lrobeson
lrobeson / SassMeister-input-HTML.html
Last active September 29, 2015 19:21
5 column flexbox layout with Singularity fallback
<h1>Flexbox</h1>
<div class="view">
<div class="views-row views-row-1">
<div class="field field-name-field-image field-type-image">
<div class="field-items">
<div class="field-item even">
<img typeof="foaf:Image" src="http://placekitten.com/130/86" width="130" height="86" alt="Adipiscing causa duis genitus lobortis plaga typicus velit." title="Abbas abluo acsi adipiscing iusto populus ut.">
</div>
</div>
</div>
@lrobeson
lrobeson / 00-colors.mustache
Last active August 29, 2015 14:18
Color data and mustache template to generate a random list of colors. Manually synced (for now) with the project theme's _colors.scss Sass partial. This replaces Pattern Lab's default hard-coded color swatch markup. You still have to maintain the values in 2 files, but a .json file should be easier to deal with.
<ul class="sg-colors">
{{!
This will generate a random list of colors,
reading from the color.listitems.json file.
Try to keep the json file synced with the
_colors.scss Sass partial.
}}
{{# listItems.nine }} {{! Change the number to match your color quantity }}
<li>
<span class="sg-label">{{ label }}</span>
@lrobeson
lrobeson / Gruntfile.js
Created February 20, 2015 19:07
Grunt config for Pattern Lab
module.exports = function (grunt) {
// Load grunt tasks automatically
require('load-grunt-tasks')(grunt);
// Time how long tasks take. Can help when optimizing build times
require('time-grunt')(grunt);
// Define the configuration for all the tasks
grunt.initConfig({