/** * Featherlight - ultra slim jQuery lightbox * Version 1.3.2 - http://noelboss.github.io/featherlight/ * * Copyright 2015, Noël Raoul Bossart (http://www.noelboss.com) * MIT Licensed. **/ (function(d){function g(a,b){if(this instanceof g)this.id=g.id++,this.setup(a,b),this.chainCallbacks(g._callbackChain);else{var c=new g(a,b);c.open();return c}}if("undefined"===typeof d)"console"in window&&window.console.info("Too much lightness, Featherlight needs jQuery.");else{var l=[],m=function(a){return l=d.grep(l,function(b){return b!==a&&0','
','',c.closeIcon,"",'
'+c.loading+"
","
"].join("")),f="."+c.namespace+"-close"+(c.otherClose?","+c.otherClose:"");c.$instance=e.clone().addClass(c.variant);c.$instance.on(c.closeTrigger+"."+c.namespace,function(a){var b=d(a.target);if("background"===c.closeOnClick&&b.is("."+c.namespace)||"anywhere"===c.closeOnClick||b.closest(f).length)a.preventDefault(),c.close()});return this},getContent:function(){if(!1!==this.persist&&this.$content)return this.$content;var a=this.constructor.contentFilters,b=this.$currentTarget&&this.$currentTarget.attr(this.targetAttr),c=this.target||b||"",e=a[this.type];!e&&c in a&&(e=a[c],c=this.target&&b);c=c||this.$currentTarget&&this.$currentTarget.attr("href")||"";if(!e)for(var f in a)this[f]&&(e=a[f],c=this[f]);if(!e){var h=c,c=null;d.each(this.contentFilters,function(){e=a[this];e.test&&(c=e.test(h));!c&&e.regex&&h.match&&h.match(e.regex)&&(c=h);return!c});if(!c)return"console"in window&&window.console.error("Featherlight: no content filter found "+(h?' for "'+h+'"':" (no target specified)")),!1}return e.process.call(this,c)},setContent:function(a){(a.is("iframe")||0');c.onload=function(){e.naturalWidth=c.width;e.naturalHeight=c.height;b.resolve(e)};c.onerror=function(){b.reject(e)};c.src=a;return b.promise()}},html:{regex:/^\s*<[\w!][^<]*>/,process:function(a){return d(a)}},ajax:{regex:/./,process:function(a){var b=d.Deferred(),c=d("
").load(a,function(a,d){"error"!==d&&b.resolve(c.contents());b.fail()});return b.promise()}},iframe:{process:function(a){var b=new d.Deferred,c=d("