This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @author Rhys Burnie | |
* Personal setup for Stats and dat.GUI with a materialColors object for quick nice color options. | |
* (clientside - dirty) - for things like p5 sketches, codepens etc. | |
* | |
* promiseTools().then(function(tools){ | |
* var colors = tools.colors; | |
* var stats = tools.stats; | |
* var gui = tools.gui; | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function promiseLatency(latency = 250) { | |
return new Promise(resolve => { | |
setTimeout(resolve, latency); | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@custom-selector :--floorplan-level g[data-name*="level"]; | |
@custom-selector :--floorplan-tile g[data-name*="level"] > g; | |
@custom-selector :--floorplan-bg g[data-name*="level"] > g > g[data-name="bg"]; | |
@custom-selector :--floorplan-lines g[data-name*="level"] > g > g[data-name="lines"]; | |
@custom-selector :--floorplan-labels g[data-name*="level"] > g > g[data-name="labels"]; | |
@custom-selector :--floorplan-labels-text g[data-name*="level"] > g > g[data-name="labels"] text; | |
@custom-selector :--floorplan-base-bg g[data-name*="level"] > g[data-name*="base"] > g[data-name="bg"]; | |
:root { | |
--purpleColor: #2B037A; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Rename tags named foo-bar-#.#.# to v#.#.# and push the tag changes | |
git tag -l | while read t; do n="v${t##*-}"; git tag $n $t; git push --tags ; git tag -d $t; git push origin :refs/tags/$t ; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin wrap-rules-IE10-plus { | |
@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { | |
& { | |
@content; | |
} | |
} | |
} | |
// NB: assumed conditional comment style html element for .ie9 class | |
// for lower you would need to add more mixins |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(typeof window!=="undefined"){ | |
window.Element && function(proto) { | |
if(!proto.matches) { | |
proto.matches = proto.matchesSelector || | |
proto.mozMatchesSelector || | |
proto.msMatchesSelector || | |
proto.oMatchesSelector || | |
proto.webkitMatchesSelector || | |
function (selector) { | |
var node = this, nodes = (node.parentNode || node.document).querySelectorAll(selector), i = -1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+function(exports){ | |
// exposed on this global object | |
var exposed = 'notnative'; | |
/**! | |
* @author Rhys Burnie | |
* @description native js coordinates tool for scripts consumption. | |
* @licence MIT | |
* Copyright Rhys Burnie | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Primarily for looping `querySelectorAll` results (`NodeList`) | |
* | |
* Avoid array hacks like: `[].forEach.call(NodeList)` | |
* see: http://toddmotto.com/ditch-the-array-foreach-call-nodelist-hack/ | |
*/ | |
+function(exports){ | |
// exposed on this global object | |
var exposed = 'notnative'; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($){ | |
/** | |
* @author Rhys Burnie | |
* @license MIT | |
* | |
* The MIT License (MIT) | |
* Copyright (c) 2015 Rhys Burnie | |
* https://opensource.org/licenses/MIT | |
* | |
* Responsive Tier Watcher |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! | |
* quantize.js Copyright 2008 Nick Rabinowitz. | |
* Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php | |
*/ | |
// fill out a couple protovis dependencies | |
/*! | |
* Block below copied from Protovis: http://mbostock.github.com/protovis/ | |
* Copyright 2010 Stanford Visualization Group | |
* Licensed under the BSD License: http://www.opensource.org/licenses/bsd-license.php |