Skip to content

Instantly share code, notes, and snippets.

View pixelwhip's full-sized avatar

John Ferris pixelwhip

View GitHub Profile
@pixelwhip
pixelwhip / recipes-include-sparse-fieldsets.json
Last active December 13, 2021 13:05
Contenta Recipe Response
{
"data": [
{
"type": "recipes",
"id": "d977783a-d277-4f55-b8a7-af57b188ab6e",
"attributes": {
"title": "Frankfurter salad with mustard dressing"
},
"relationships": {
"category": {
/*
* toggle.js
*/
var logger = require('./logger'),
log = logger.log,
$ = require('jquery');
var toggle = function() {
/**
@pixelwhip
pixelwhip / template.php
Last active August 29, 2015 14:08
Grunticon snippet for a Drupal theme.
<?php
/**
* Implements hook_preprocess_html().
*/
function [theme_name]_preprocess_html(&$vars) {
/**
* Add Grunticon stylesheet loader.
*/
@pixelwhip
pixelwhip / SassMeister-input.scss
Created September 8, 2014 16:59
Generated by SassMeister.com.
// ----
// Sass (v3.4.3)
// Compass (v1.0.1)
// ----
// Failed attempt to create a shortcut for writing AMCSS selectors.
// Tried several approaches and all end up being more characters than just
// typing out the selector. Also, unwarranted complexity.
//
// You win this time, Vanilla CSS.
@pixelwhip
pixelwhip / drupal-center.css
Created February 25, 2014 22:57
This includes all the minified CSS included in a base install of the Center theme. It's helpful as a baseline for use in style guides.
#comments{margin-top:15px;}.indented{margin-left:25px;}.comment-unpublished{background-color:#fff4f4;}.comment-preview{background-color:#ffffea;}
.container-inline-date{clear:both;}.container-inline-date .form-item{float:none;margin:0;padding:0;}.container-inline-date > .form-item{display:inline-block;margin-right:0.5em;margin-bottom:10px;vertical-align:top;}.container-inline-date .form-item .form-item{float:left;}.container-inline-date .form-item,.container-inline-date .form-item input{width:auto;}.container-inline-date .description{clear:both;}.container-inline-date .form-item input,.container-inline-date .form-item select,.container-inline-date .form-item option{margin-right:5px;}.container-inline-date .date-spacer{margin-left:-5px;}.views-right-60 .container-inline-date div{margin:0;padding:0;}.container-inline-date .date-timezone .form-item{clear:both;float:none;width:auto;}.container-inline-date .date-padding{padding:10px;float:left;}.views-exposed-form .container-inline-date .date-padding{padding:0;}#c
@pixelwhip
pixelwhip / SassMeister-input-HTML.html
Created February 14, 2014 18:34
Generated by SassMeister.com.
<H2>Compass Browser Support</H2>
@pixelwhip
pixelwhip / magic-padding.scss
Last active April 8, 2020 17:37
Magic Padding Sass Mixin. Adds padding to all four sides of an element. Replacing bottom padding with an :after psuedo element with top margin, giving the illusion of the bottom padding collapsing with the bottom margin of the last child within the element. @params $values Same as CSS shorthand for padding Example: 10px or 1em 10px or 10px 20px …
//
// @file
// Magic Padding mixins.
//
// Replaces bottom padding with an :after psuedo element with top margin, giving
// the illusion of the bottom padding collapsing with the bottom margin of the
// last child within the element.
//
// @param $value
@pixelwhip
pixelwhip / SassMeister-input-HTML.html
Created October 23, 2013 21:53
Generated by SassMeister.com.
<div id="swatch-1"></div>
<div id="swatch-2"></div>
<div id="swatch-3"></div>
<div id="swatch-4"></div>
@import "singularitygs";
// Singularity Settings
$grids: 3;
$gutters: 0;
$output: 'isolation';
///
$direction: 'rtl';
.rtl {
@include grid-span(2, 1);
@pixelwhip
pixelwhip / SassMeister-input-HTML.html
Created October 14, 2013 00:18
Generated by SassMeister.com.
<header class="brand">
<img src="" class="brand-logo"/>
<h1 class="brand-name">The Sass Way</h1>
<p class="brand-price">5/6</p>
</header>
<div class="cover">
<h1 class="cover-title">The Marber Grid</h1>
<cite class="cover-author">Singularity GS</cite>
</div>