Skip to content

Instantly share code, notes, and snippets.

@dbnoble
dbnoble / selectOverride.js
Created February 14, 2016 10:44
Materialize Select - Override to allow HTML elements in options (backwards compatible)
/*!
* Based on Materialize Materialize v0.97.5
* Modified to allow HTML elements in select options
* github.com/dbnoble
*/
/*!
* Materialize v0.97.5 (http://materializecss.com)
* Copyright 2014-2015 Materialize
* MIT License (https://raw.githubusercontent.com/Dogfalo/materialize/master/LICENSE)
*/
@dbnoble
dbnoble / BOTH-collections.js
Created January 30, 2016 11:36
Authentication without accounts for froatsnook:shopify
// define the Shops collection on the client and the server
Shops = new Mongo.Collection("shops");
@dbnoble
dbnoble / BOTH-collections.js
Last active January 30, 2016 11:43
Authentication with accounts for froatsnook:shopify
// define the Shops collection on the client and the server
Shops = new Mongo.Collection("shops");
@dbnoble
dbnoble / materializeSelectOverride.html
Last active January 26, 2016 16:09
Override for MaterializeCSS framework's select element to use HTML
<!--
Item placeholder value for when the menu is closed goes inside data-placeholder (make sure to escape characters if necessary)
HTML Content goes inside data-content (make sure to escape characters if necessary)
//-->
<div class="input-field">
<select id="primaryItem" class="icons">
<option value="" disabled selected>Click to choose a product...</option>
<option value="product1" data-icon="product1.png" data-placeholder="Awesome Product" data-content="<div>Awesome Product</div><span>by: Brazen Tech Mfg.</span>" class="left circle">Awesome Product</option>