Skip to content

Instantly share code, notes, and snippets.

View jewlofthelotus's full-sized avatar

Julie Cameron jewlofthelotus

View GitHub Profile
@jewlofthelotus
jewlofthelotus / hack15.rb
Last active October 12, 2017 09:08
Sonic Pi Hackathon Track
######################################################
# Drums
######################################################
define :boom do
with_fx :reverb, room: 1 do
sample :bd_boom, amp: 8
end
sample :ambi_choir, rate: 0.1
@jewlofthelotus
jewlofthelotus / CustomSlickQuizFilters.phtml
Last active August 23, 2016 10:22
An example WordPress plugin that hooks into the SlickQuiz WordPress plugin. Thanks to @phh for his contribution and example from which this is modified. https://github.com/jewlofthelotus/SlickQuiz-WordPress/pull/37
class CustomSlickQuizFilters {
function __construct()
{
add_filter( 'slickquiz_admin_options', array( &$this, 'custom_admin_options' ) );
add_filter( 'slickquiz_after_options', array( &$this, 'custom_after_options' ) );
add_filter( 'slickquiz_after_result', array( &$this, 'custom_after_result' ) );
}
function custom_admin_options( $options )
@jewlofthelotus
jewlofthelotus / SassMeister-input.scss
Created December 9, 2013 23:15 — forked from hagenburger/SassMeister-input.scss
Generated by SassMeister.com.
// ----
// Sass (v3.3.0.rc.1)
// Compass (v0.13.alpha.10)
// ----
// You can use inline %placeholders in Sass:
.form %form-item + .text {
margin-top: 10px;
}
@jewlofthelotus
jewlofthelotus / SassMeister-input.scss
Created December 9, 2013 17:15
Generated by SassMeister.com.
// ----
// Sass (v3.3.0.rc.1)
// Compass (v0.13.alpha.10)
// ----
// Horizontal Spacing
@mixin margin--horz($left, $right: $left) {
margin-left: $left;
margin-right: $right;
@jewlofthelotus
jewlofthelotus / SassMeister-input.scss
Created December 4, 2013 18:01 — forked from kaelig/SassMeister-input.scss
Generated by SassMeister.com, the Sass playground.
// ----
// Sass (v3.3.0.rc.1)
// Compass (v0.13.alpha.10)
// ----
// To enable support for browsers that do not support @media queries,
// (IE <= 8, Firefox <= 3, Opera <= 9) set $mq-responsive to false
// Create a separate stylesheet served exclusively to these browsers,
// meaning @media queries will be rasterized, relying on the cascade itself
$mq-responsive: true !default;
@jewlofthelotus
jewlofthelotus / SassMeister-input.scss
Created December 4, 2013 17:54 — forked from lunelson/SassMeister-input.scss
Generated by SassMeister.com.
// ----
// Sass (v3.3.0.rc.1)
// Compass (v0.13.alpha.10)
// ----
/*
A slightly more automated approach to BEM modifier classes:
using '&' parent selector interpolation, modifiers extend their bases,
so that HTML markup requires only the modifier class not the base *and* modifier
*/
@jewlofthelotus
jewlofthelotus / gist:7236618
Created October 30, 2013 17:25
A WIP guide on how to setup styles for a new block in an OOCSS / BEM / SMACSSish modular architecture.
/* ==========================================================================
Block Title
========================================================================== */
/**
* Markdown Example (HAML)
*
* %div.block_modifiers
* %header.block--element_modifiers
@jewlofthelotus
jewlofthelotus / gist:5678703
Last active December 17, 2015 21:59
Default comment blocks for a Sass utilities partial
/*
* Extends - @extend .inheritance-class;
*
* Selectors extending a class get comma separated. Property / value pairs ARE NOT duplicated everywhere.
* Use for simple selectors. Warning: it gets messy where there are sub-nodes
*
* Still unsure? Use @extend if a relationship IS implied AND you need the base class in the stylesheet. Example:
* .message { ... }
* .error { @extend .message; ... }
* .info { @extend .message; ... }
@jewlofthelotus
jewlofthelotus / gist:5627944
Created May 22, 2013 14:26
How to use getJSON to pull the quiz config object into the SlickQuiz options
$(function () {
$.getJSON('path/to/file.json', function(data) {
$('#slickQuiz').slickQuiz({json: data});
});
});
@jewlofthelotus
jewlofthelotus / gist:5624959
Last active December 17, 2015 14:29
How to place the quiz config JSON directly into the SlickQuiz plugin options.
$(function () {
$('#slickQuiz').slickQuiz({
json: {
"info": {
"name": "Test Your Knowledge!!",
"main": "<p>Think you're smart enough to be on Jeopardy? Find out with this super crazy knowledge quiz!</p>",
"results": "<h5>Learn More</h5><p>Etiam scelerisque, nunc ac egestas consequat, odio nibh euismod nulla, eget auctor orci nibh vel nisi. Aliquam erat volutpat. Mauris vel neque sit amet nunc gravida congue sed sit amet purus.</p>",
"level1": "Jeopardy Ready",
"level2": "Jeopardy Contender",
"level3": "Jeopardy Amateur",