This file contains hidden or 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
var createOverlay = function(row,button){ | |
var o = $("<div></div>").addClass("overlayOuter").attr("id","overlay-"+row.replace(/\#/g,'').replace(/\,/g,'')).on('click',function(){o.hide();}).appendTo($("body")); | |
var i = $("<div></div>").addClass("overlayInner").on('click',function(e){e.stopPropagation();}).prepend($(row)).appendTo(o); | |
$("<div></div>").addClass("overlayClose").on('click',function(e){ o.hide(); $("body").removeClass("noScroll"); }).appendTo(i); | |
$(button).attr("href","#overlay").on('click',function(e){e.preventDefault();$("body").addClass("noScroll");o.show();}); | |
} |
This file contains hidden or 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
NGX.App.config.sharing.inviteText = NGX.App.config.sharing.description; |
This file contains hidden or 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(){ | |
$(".xFieldRadioChoice").click(function(){ | |
$(this).siblings().removeClass("clicked"); | |
$(this).addClass("clicked"); | |
$(".xActionNext").removeClass("xDisabled"); | |
}); | |
$(".xFormPages").on( 'cycle-after', function(event, optionHash, outgoingSlideEl, incomingSlideEl, forwardFlag) { | |
$(incomingSlideEl).find(".clicked").length==0 ? $(".xActionNext").addClass("xDisabled") : $(".xActionNext").removeClass("xDisabled"); | |
This file contains hidden or 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
// PASS OBJECT WITH SEARCH TERM & POSITION ( first, middle, last, or an integer ) | |
// SEARCH TERMS are processed in the order they are added. | |
var searches = { | |
"fire" : "last", | |
"if" : "first", | |
"what" : "middle", | |
"why" : 2 | |
}; | |
reorderWall(searches); |
This file contains hidden or 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
TarGZ = function(){}; | |
// Load and parse archive, calls onload after loading all files. | |
TarGZ.load = function(url, onload, onstream, onerror) { | |
var o = new TarGZ(); | |
o.onload = onload; | |
o.onerror = onerror; | |
o.onstream = onstream; | |
o.load(url); | |
return o; |
This file contains hidden or 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
gistup |
This file contains hidden or 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
gistup |
This file contains hidden or 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
const order = { | |
subtotal: 35, | |
tax: 0.6, | |
get total() { return this.subtotal * this.tax } | |
} | |
order.subtotal // 35 | |
order.tax // 0.6 | |
order.total // 21 | |
order.subtotal = 36 |
This file contains hidden or 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
/** | |
* Composes functions like c(f, g) === f(g(x)). | |
* @param {arguments} fns Multiple functions w/ map/reduce. | |
* @returns reducer seeded with identity function. | |
* @example compose(x => x + 2, x => x - 1)(5) // 6 (5 + 2 -1) | |
*/ | |
const compose = (...fns) => { | |
return fns.reduce((acc, fn) => { | |
return (...args) => { | |
return acc(fn(...args)); |
This file contains hidden or 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
/** | |
* Sort or set keys | |
* @param data {object} Keyed data store | |
* @param keysOrSort {array|function} | |
* @return {array} | |
*/ | |
const sortKeys = (data, keysOrSort) => { | |
return typeof keysOrSort === "undefined" | |
? Object.keys(data).sort() | |
: typeof keysOrSort === "function" |
OlderNewer