Boxzilla - Version 3.1.5

Version Description

Download this release

Release Info

Developer DvanKooten
Plugin Icon 128x128 Boxzilla
Version 3.1.5
Comparing to
See all releases

Code changes from version 3.1.4 to 3.1.5

assets/browserify/script.js CHANGED
@@ -28,6 +28,9 @@ for( var i=0; i < options.boxes.length; i++ ) {
28
 
29
  // add custom css to box
30
  css(box.element, boxOpts.css);
 
 
 
31
  }
32
 
33
  // helper function for setting CSS styles
28
 
29
  // add custom css to box
30
  css(box.element, boxOpts.css);
31
+
32
+ box.element.firstChild.firstChild.className += " first-child";
33
+ box.element.firstChild.lastChild.className += " last-child";
34
  }
35
 
36
  // helper function for setting CSS styles
assets/js/script.js CHANGED
@@ -29,6 +29,9 @@ for( var i=0; i < options.boxes.length; i++ ) {
29
 
30
  // add custom css to box
31
  css(box.element, boxOpts.css);
 
 
 
32
  }
33
 
34
  // helper function for setting CSS styles
@@ -575,15 +578,32 @@ Box.prototype.trigger = function() {
575
  }
576
  };
577
 
578
- Box.prototype.dismiss = function() {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
579
  this.hide();
580
 
 
581
  if(this.config.cookie && this.config.cookie.dismissed) {
582
  this.setCookie(this.config.cookie.dismissed);
583
  }
584
 
585
  this.dismissed = true;
586
  Boxzilla.trigger('box.dismiss', [ this ]);
 
587
  };
588
 
589
  module.exports = function(_Boxzilla) {
@@ -679,11 +699,6 @@ function checkTimeCriteria() {
679
  function checkHeightCriteria() {
680
  var scrollY = ( window.scrollY || window.pageYOffset ) + window.innerHeight * 0.75;
681
 
682
- // don't bother if another box is currently open
683
- if( isAnyBoxVisible() ) {
684
- return;
685
- }
686
-
687
  boxes.forEach(function(box) {
688
 
689
  if( ! box.mayAutoShow() || box.triggerHeight <= 0 ) {
@@ -691,6 +706,12 @@ function checkHeightCriteria() {
691
  }
692
 
693
  if( scrollY > box.triggerHeight ) {
 
 
 
 
 
 
694
  box.trigger();
695
  } else if( box.mayRehide() ) {
696
  box.hide();
29
 
30
  // add custom css to box
31
  css(box.element, boxOpts.css);
32
+
33
+ box.element.firstChild.firstChild.className += " first-child";
34
+ box.element.firstChild.lastChild.className += " last-child";
35
  }
36
 
37
  // helper function for setting CSS styles
578
  }
579
  };
580
 
581
+ /**
582
+ * Dismisses the box and optionally sets a cookie.
583
+ *
584
+ * @param e The event that triggered this dismissal.
585
+ * @returns {boolean}
586
+ */
587
+ Box.prototype.dismiss = function(e) {
588
+ // prevent default action
589
+ e && e.preventDefault();
590
+
591
+ // only dismiss box if it's currently open.
592
+ if( ! this.visible ) {
593
+ return false;
594
+ }
595
+
596
+ // hide box element
597
  this.hide();
598
 
599
+ // set cookie
600
  if(this.config.cookie && this.config.cookie.dismissed) {
601
  this.setCookie(this.config.cookie.dismissed);
602
  }
603
 
604
  this.dismissed = true;
605
  Boxzilla.trigger('box.dismiss', [ this ]);
606
+ return true;
607
  };
608
 
609
  module.exports = function(_Boxzilla) {
699
  function checkHeightCriteria() {
700
  var scrollY = ( window.scrollY || window.pageYOffset ) + window.innerHeight * 0.75;
701
 
 
 
 
 
 
702
  boxes.forEach(function(box) {
703
 
704
  if( ! box.mayAutoShow() || box.triggerHeight <= 0 ) {
706
  }
707
 
708
  if( scrollY > box.triggerHeight ) {
709
+ // don't bother if another box is currently open
710
+ if( isAnyBoxVisible() ) {
711
+ return;
712
+ }
713
+
714
+ // trigger box
715
  box.trigger();
716
  } else if( box.mayRehide() ) {
717
  box.hide();
assets/js/script.min.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};!function(){var e=void 0,t=void 0;!function i(t,n,o){function r(a,l){if(!n[a]){if(!t[a]){var c="function"==typeof e&&e;if(!l&&c)return c(a,!0);if(s)return s(a,!0);var d=new Error("Cannot find module '"+a+"'");throw d.code="MODULE_NOT_FOUND",d}var f=n[a]={exports:{}};t[a][0].call(f.exports,function(e){var i=t[a][1][e];return r(i?i:e)},f,f.exports,i,t,n,o)}return n[a].exports}for(var s="function"==typeof e&&e,a=0;a<o.length;a++)r(o[a]);return r}({1:[function(e,t,i){function n(e,t){t.background_color&&(e.style.background=t.background_color),t.color&&(e.style.color=t.color),t.border_color&&(e.style.borderColor=t.border_color),t.border_width&&(e.style.borderWidth=parseInt(t.border_width)+"px"),t.border_style&&(e.style.borderStyle=t.border_style),t.width&&(e.style.maxWidth=parseInt(t.width)+"px")}var o=e("boxzilla"),r=window.boxzilla_options,s=document.body.className.indexOf("logged-in")>-1;s&&r.testMode&&console.log("Boxzilla: Test mode is enabled. Please disable test mode if you're done testing."),o.init();for(var a=0;a<r.boxes.length;a++){var l=r.boxes[a];l.testMode=s&&r.testMode,"https"===window.location.origin.substring(0,5)&&(l.content=l.content.replace(window.location.origin.replace("https","http"),window.location.origin));var c=o.create(l.id,l);n(c.element,l.css)}window.addEventListener("load",function(){if("object"===_typeof(window.mc4wp_forms_config)&&window.mc4wp_forms_config.submitted_form){var e="#"+window.mc4wp_forms_config.submitted_form.element_id,t=o.boxes;for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];if(n.element.querySelector(e))return void n.show()}}}),window.Boxzilla=o},{boxzilla:4}],2:[function(e,t,i){function n(e,t){for(var i in t)e.style[i]=t[i]}function o(e,t){for(var i={},n=0;n<e.length;n++)i[e[n]]=t;return i}function r(e,t){for(var i={},n=0;n<e.length;n++)i[e[n]]=t[e[n]];return i}function s(e){return!!e.getAttribute("data-animated")}function a(e,t){var i="none"!=e.style.display||e.offsetLeft>0,s=e.cloneNode(!0),a=function(){e.removeAttribute("data-animated"),e.setAttribute("style",s.getAttribute("style")),e.style.display=i?"none":""};e.setAttribute("data-animated","true"),i||(e.style.display="");var c,d;if("slide"===t){if(c=o(["height","borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],0),d={},!i){var f=window.getComputedStyle(e);d=r(["height","borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],f),n(e,c)}e.style.overflowY="hidden",l(e,i?c:d,a)}else c={opacity:0},d={opacity:1},i||n(e,c),l(e,i?c:d,a)}function l(e,t,i){var n=+new Date,o=window.getComputedStyle(e),r={},s={};for(var a in t){t[a]=parseFloat(t[a]);var l=t[a],d=parseFloat(o[a]);d!=l?(s[a]=(l-d)/c,r[a]=d):delete t[a]}var f=function h(){var o,a,l,c,d=+new Date,f=d-n,u=!0;for(var g in t){o=s[g],a=t[g],l=o*f,c=r[g]+l,o>0&&c>=a||o<0&&c<=a?c=a:u=!1,r[g]=c;var p="opacity"!==g?"px":"";e.style[g]=c+p}n=+new Date,u?i&&i():window.requestAnimationFrame&&requestAnimationFrame(h)||setTimeout(h,32)};f()}var c=320;t.exports={toggle:a,animate:l,animated:s}},{}],3:[function(e,t,i){function n(e,t){var i={};for(var n in e)i[n]=e[n];for(var n in t)i[n]=t[n];return i}function o(){var e=document.body,t=document.documentElement,i=Math.max(e.scrollHeight,e.offsetHeight,t.clientHeight,t.scrollHeight,t.offsetHeight);return i}var r,s={animation:"fade",rehide:!1,content:"",cookie:null,icon:"&times",minimumScreenWidth:0,position:"center",testMode:!1,trigger:!1,closable:!0},a=e("./animator.js"),l=function(e,t){this.id=e,this.config=n(s,t),this.overlay=document.getElementById("boxzilla-overlay"),this.visible=!1,this.dismissed=!1,this.triggered=!1,this.triggerHeight=0,this.cookieSet=!1,this.element=null,this.closeIcon=null,this.config.trigger&&("percentage"!==this.config.trigger.method&&"element"!==this.config.trigger.method||(this.triggerHeight=this.calculateTriggerHeight()),this.cookieSet=this.isCookieSet()),this.dom(),this.events()};l.prototype.events=function(){var e=this;this.closeIcon&&this.closeIcon.addEventListener("click",e.dismiss.bind(this)),this.element.addEventListener("click",function(t){"A"===t.target.tagName&&r.trigger("box.interactions.link",[e,t.target])},!1),this.element.addEventListener("submit",function(t){e.setCookie(),r.trigger("box.interactions.form",[e,t.target])},!1),window.addEventListener("hashchange",function(){var t="#boxzilla-"+e.id;location.hash===t&&e.toggle()}),this.fits()&&this.locationHashRefersBox()&&window.addEventListener("load",this.show.bind(this))},l.prototype.dom=function(){var e=document.createElement("div");e.className="boxzilla-container boxzilla-"+this.config.position+"-container";var t=document.createElement("div");t.setAttribute("id","boxzilla-"+this.id),t.className="boxzilla boxzilla-"+this.id+" boxzilla-"+this.config.position,t.style.display="none",e.appendChild(t);var i=document.createElement("div");i.className="boxzilla-content",i.innerHTML=this.config.content,t.appendChild(i);var n=i.querySelectorAll("script");if(n.length){for(var o=document.createElement("script"),r=0;r<n.length;r++)o.appendChild(document.createTextNode(n[r].text)),n[r].parentNode.removeChild(n[r]);document.body.appendChild(o)}if(this.config.closable&&this.config.icon){var s=document.createElement("span");s.className="boxzilla-close-icon",s.innerHTML=this.config.icon,t.appendChild(s),this.closeIcon=s}document.body.appendChild(e),this.element=t},l.prototype.setCustomBoxStyling=function(){var e=this.element.style.display;this.element.style.display="",this.element.style.overflowY="auto",this.element.style.maxHeight="none";var t=window.innerHeight,i=this.element.clientHeight;if(i>t&&(this.element.style.maxHeight=t+"px",this.element.style.overflowY="scroll"),"center"===this.config.position){var n=(t-i)/2;n=n>=0?n:0,this.element.style.marginTop=n+"px"}this.element.style.display=e},l.prototype.toggle=function(e){if("undefined"==typeof e&&(e=!this.visible),e===this.visible)return!1;if(a.animated(this.element))return!1;if(!e&&!this.config.closable)return!1;this.visible=e,this.setCustomBoxStyling(),r.trigger("box."+(e?"show":"hide"),[this]),"center"===this.config.position&&a.toggle(this.overlay,"fade"),a.toggle(this.element,this.config.animation);var t=this.element.querySelector("input, textarea");return t&&t.focus(),!0},l.prototype.show=function(){return this.toggle(!0)},l.prototype.hide=function(){return this.toggle(!1)},l.prototype.calculateTriggerHeight=function(){var e=0;if("element"===this.config.trigger.method){var t=document.body.querySelector(this.config.trigger.value);if(t){var i=t.getBoundingClientRect();e=i.top}}else"percentage"===this.config.trigger.method&&(e=this.config.trigger.value/100*o());return e},l.prototype.locationHashRefersBox=function(){if(!window.location.hash||0===window.location.hash.length)return!1;var e=window.location.hash.substring(1);return e===this.element.id||!!this.element.querySelector("#"+e)},l.prototype.fits=function(){return this.config.minimumScreenWidth<=0||window.innerWidth>this.config.minimumScreenWidth},l.prototype.mayAutoShow=function(){return!this.dismissed&&(!!this.fits()&&(!!this.config.trigger&&!this.cookieSet))},l.prototype.mayRehide=function(){return this.config.rehide&&this.triggered},l.prototype.isCookieSet=function(){if(this.config.testMode)return!1;if(!this.config.cookie||!this.config.cookie.triggered&&!this.config.cookie.dismissed)return!1;var e="true"===document.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*boxzilla_box_"+this.id+"\\s*\\=\\s*([^;]*).*$)|^.*$"),"$1");return e},l.prototype.setCookie=function(e){var t=new Date;t.setHours(t.getHours()+e),document.cookie="boxzilla_box_"+this.id+"=true; expires="+t.toUTCString()+"; path=/"},l.prototype.trigger=function(){var e=this.show();e&&(this.triggered=!0,this.config.cookie&&this.config.cookie.triggered&&this.setCookie(this.config.cookie.triggered))},l.prototype.dismiss=function(){this.hide(),this.config.cookie&&this.config.cookie.dismissed&&this.setCookie(this.config.cookie.dismissed),this.dismissed=!0,r.trigger("box.dismiss",[this])},t.exports=function(e){return r=e,l}},{"./animator.js":2}],4:[function(e,t,i){function n(e,t,i){t||(t=250);var n,o;return function(){var r=i||this,s=+new Date,a=arguments;n&&s<n+t?(clearTimeout(o),o=setTimeout(function(){n=s,e.apply(r,a)},t)):(n=s,e.apply(r,a))}}function o(e){27==e.keyCode&&x.dismiss()}function r(){h()||z.forEach(function(e){e.mayAutoShow()&&"pageviews"===e.config.trigger.method&&b>=e.config.trigger.value&&e.trigger()})}function s(){h()||z.forEach(function(e){e.mayAutoShow()&&("time_on_site"===e.config.trigger.method&&v.time>=e.config.trigger.value&&e.trigger(),"time_on_page"===e.config.trigger.method&&y.time>=e.config.trigger.value&&e.trigger())})}function a(){var e=(window.scrollY||window.pageYOffset)+.75*window.innerHeight;h()||z.forEach(function(t){!t.mayAutoShow()||t.triggerHeight<=0||(e>t.triggerHeight?t.trigger():t.mayRehide()&&t.hide())})}function l(){z.forEach(function(e){e.setCustomBoxStyling()})}function c(e){var t=e.offsetX,i=e.offsetY;z.forEach(function(e){var n=e.element.getBoundingClientRect(),o=100+.05*window.innerWidth;(t<n.left-o||t>n.right+o||i<n.top-o||i>n.bottom+o)&&e.dismiss()})}function d(){m||h()||(z.forEach(function(e){e.mayAutoShow()&&"exit_intent"===e.config.trigger.method&&e.trigger()}),m=!0)}function f(e){var t=400;e.clientY<=0&&(p=window.setTimeout(d,t))}function h(){for(var e=0;e<z.length;e++){var t=z[e];if(t.visible)return!0}return!1}function u(){p&&(window.clearInterval(p),p=null)}var g,p,m,v,y,b,w=e("wolfy87-eventemitter"),x=Object.create(w.prototype),E=e("./box.js")(x),_=e("./timer.js"),z=[],L={start:function(){var e=sessionStorage.getItem("boxzilla_timer");e&&(v.time=e),v.start(),y.start()},stop:function(){sessionStorage.setItem("boxzilla_timer",v.time),v.stop(),y.stop()}};x.init=function(){v=new _(sessionStorage.getItem("boxzilla_timer")||0),y=new _(0),b=sessionStorage.getItem("boxzilla_pageviews")||0;var t=e("./styles.js"),i=document.createElement("style");i.setAttribute("type","text/css"),i.innerHTML=t,document.head.appendChild(i),g=document.createElement("div"),g.style.display="none",g.id="boxzilla-overlay",document.body.appendChild(g),window.addEventListener("scroll",n(a)),window.addEventListener("resize",n(l)),window.addEventListener("load",l),g.addEventListener("click",c),window.setInterval(s,1e3),window.setTimeout(r,1e3),document.documentElement.addEventListener("mouseleave",f),document.documentElement.addEventListener("mouseenter",u),document.addEventListener("keyup",o),L.start(),window.addEventListener("focus",L.start),window.addEventListener("beforeunload",function(){L.stop(),sessionStorage.setItem("boxzilla_pageviews",++b)}),window.addEventListener("blur",L.stop),x.trigger("ready")},x.create=function(e,t){var i=new E(e,t);return z.push(i),i},x.get=function(e){for(var t=0;t<z.length;t++){var i=z[t];if(i.id==e)return i}throw new Error("No box exists with ID "+e)},x.dismiss=function(e){"undefined"==typeof e?z.forEach(function(e){e.dismiss()}):"object"===_typeof(z[e])&&x.get(e).dismiss()},x.hide=function(e){"undefined"==typeof e?z.forEach(function(e){e.hide()}):x.get(e).hide()},x.show=function(e){"undefined"==typeof e?z.forEach(function(e){e.show()}):x.get(e).show()},x.toggle=function(e){"undefined"==typeof e?z.forEach(function(e){e.toggle()}):x.get(e).toggle()},x.boxes=z,window.Boxzilla=x,"undefined"!=typeof t&&t.exports&&(t.exports=x)},{"./box.js":3,"./styles.js":5,"./timer.js":6,"wolfy87-eventemitter":7}],5:[function(e,t,i){var n="#boxzilla-overlay{position:fixed;background:rgba(0,0,0,.65);width:100%;height:100%;left:0;top:0;z-index:99999}.boxzilla-center-container{position:fixed;top:0;left:0;right:0;height:0;text-align:center;z-index:999999;line-height:0}.boxzilla-center-container .boxzilla{display:inline-block;text-align:left;position:relative;line-height:normal}.boxzilla{position:fixed;z-index:999999;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;background:#fff;padding:25px}.boxzilla.boxzilla-top-left{top:0;left:0}.boxzilla.boxzilla-top-right{top:0;right:0}.boxzilla.boxzilla-bottom-left{bottom:0;left:0}.boxzilla.boxzilla-bottom-right{bottom:0;right:0}.boxzilla-content>:first-child{margin-top:0;padding-top:0}.boxzilla-content>:last-child{margin-bottom:0;padding-bottom:0}.boxzilla-close-icon{position:absolute;right:0;top:0;text-align:center;padding:6px;cursor:pointer;-webkit-appearance:none;font-size:28px;font-weight:700;line-height:20px;color:#000;opacity:.5}.boxzilla-close-icon:focus,.boxzilla-close-icon:hover{opacity:.8}";t.exports=n},{}],6:[function(e,t,i){var n=function(e){this.time=e,this.interval=0};n.prototype.tick=function(){this.time++},n.prototype.start=function(){this.interval||(this.interval=window.setInterval(this.tick.bind(this),1e3))},n.prototype.stop=function(){this.interval&&(window.clearInterval(this.interval),this.interval=0)},t.exports=n},{}],7:[function(e,i,n){(function(){function e(){}function n(e,t){for(var i=e.length;i--;)if(e[i].listener===t)return i;return-1}function o(e){return function(){return this[e].apply(this,arguments)}}var r=e.prototype,s=this,a=s.EventEmitter;r.getListeners=function(e){var t,i,n=this._getEvents();if(e instanceof RegExp){t={};for(i in n)n.hasOwnProperty(i)&&e.test(i)&&(t[i]=n[i])}else t=n[e]||(n[e]=[]);return t},r.flattenListeners=function(e){var t,i=[];for(t=0;t<e.length;t+=1)i.push(e[t].listener);return i},r.getListenersAsObject=function(e){var t,i=this.getListeners(e);return i instanceof Array&&(t={},t[e]=i),t||i},r.addListener=function(e,t){var i,o=this.getListenersAsObject(e),r="object"===("undefined"==typeof t?"undefined":_typeof(t));for(i in o)o.hasOwnProperty(i)&&n(o[i],t)===-1&&o[i].push(r?t:{listener:t,once:!1});return this},r.on=o("addListener"),r.addOnceListener=function(e,t){return this.addListener(e,{listener:t,once:!0})},r.once=o("addOnceListener"),r.defineEvent=function(e){return this.getListeners(e),this},r.defineEvents=function(e){for(var t=0;t<e.length;t+=1)this.defineEvent(e[t]);return this},r.removeListener=function(e,t){var i,o,r=this.getListenersAsObject(e);for(o in r)r.hasOwnProperty(o)&&(i=n(r[o],t),i!==-1&&r[o].splice(i,1));return this},r.off=o("removeListener"),r.addListeners=function(e,t){return this.manipulateListeners(!1,e,t)},r.removeListeners=function(e,t){return this.manipulateListeners(!0,e,t)},r.manipulateListeners=function(e,t,i){var n,o,r=e?this.removeListener:this.addListener,s=e?this.removeListeners:this.addListeners;if("object"!==("undefined"==typeof t?"undefined":_typeof(t))||t instanceof RegExp)for(n=i.length;n--;)r.call(this,t,i[n]);else for(n in t)t.hasOwnProperty(n)&&(o=t[n])&&("function"==typeof o?r.call(this,n,o):s.call(this,n,o));return this},r.removeEvent=function(e){var t,i="undefined"==typeof e?"undefined":_typeof(e),n=this._getEvents();if("string"===i)delete n[e];else if(e instanceof RegExp)for(t in n)n.hasOwnProperty(t)&&e.test(t)&&delete n[t];else delete this._events;return this},r.removeAllListeners=o("removeEvent"),r.emitEvent=function(e,t){var i,n,o,r,s,a=this.getListenersAsObject(e);for(r in a)if(a.hasOwnProperty(r))for(i=a[r].slice(0),o=i.length;o--;)n=i[o],n.once===!0&&this.removeListener(e,n.listener),s=n.listener.apply(this,t||[]),s===this._getOnceReturnValue()&&this.removeListener(e,n.listener);return this},r.trigger=o("emitEvent"),r.emit=function(e){var t=Array.prototype.slice.call(arguments,1);return this.emitEvent(e,t)},r.setOnceReturnValue=function(e){return this._onceReturnValue=e,this},r._getOnceReturnValue=function(){return!this.hasOwnProperty("_onceReturnValue")||this._onceReturnValue},r._getEvents=function(){return this._events||(this._events={})},e.noConflict=function(){return s.EventEmitter=a,e},"function"==typeof t&&t.amd?t(function(){return e}):"object"===("undefined"==typeof i?"undefined":_typeof(i))&&i.exports?i.exports=e:s.EventEmitter=e}).call(this)},{}]},{},[1])}();
2
  //# sourceMappingURL=script.min.js.map
1
+ "use strict";var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e};!function(){var e=void 0,t=void 0;!function i(t,n,o){function r(a,l){if(!n[a]){if(!t[a]){var c="function"==typeof e&&e;if(!l&&c)return c(a,!0);if(s)return s(a,!0);var d=new Error("Cannot find module '"+a+"'");throw d.code="MODULE_NOT_FOUND",d}var f=n[a]={exports:{}};t[a][0].call(f.exports,function(e){var i=t[a][1][e];return r(i?i:e)},f,f.exports,i,t,n,o)}return n[a].exports}for(var s="function"==typeof e&&e,a=0;a<o.length;a++)r(o[a]);return r}({1:[function(e,t,i){function n(e,t){t.background_color&&(e.style.background=t.background_color),t.color&&(e.style.color=t.color),t.border_color&&(e.style.borderColor=t.border_color),t.border_width&&(e.style.borderWidth=parseInt(t.border_width)+"px"),t.border_style&&(e.style.borderStyle=t.border_style),t.width&&(e.style.maxWidth=parseInt(t.width)+"px")}var o=e("boxzilla"),r=window.boxzilla_options,s=document.body.className.indexOf("logged-in")>-1;s&&r.testMode&&console.log("Boxzilla: Test mode is enabled. Please disable test mode if you're done testing."),o.init();for(var a=0;a<r.boxes.length;a++){var l=r.boxes[a];l.testMode=s&&r.testMode,"https"===window.location.origin.substring(0,5)&&(l.content=l.content.replace(window.location.origin.replace("https","http"),window.location.origin));var c=o.create(l.id,l);n(c.element,l.css),c.element.firstChild.firstChild.className+=" first-child",c.element.firstChild.lastChild.className+=" last-child"}window.addEventListener("load",function(){if("object"===_typeof(window.mc4wp_forms_config)&&window.mc4wp_forms_config.submitted_form){var e="#"+window.mc4wp_forms_config.submitted_form.element_id,t=o.boxes;for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];if(n.element.querySelector(e))return void n.show()}}}),window.Boxzilla=o},{boxzilla:4}],2:[function(e,t,i){function n(e,t){for(var i in t)e.style[i]=t[i]}function o(e,t){for(var i={},n=0;n<e.length;n++)i[e[n]]=t;return i}function r(e,t){for(var i={},n=0;n<e.length;n++)i[e[n]]=t[e[n]];return i}function s(e){return!!e.getAttribute("data-animated")}function a(e,t){var i="none"!=e.style.display||e.offsetLeft>0,s=e.cloneNode(!0),a=function(){e.removeAttribute("data-animated"),e.setAttribute("style",s.getAttribute("style")),e.style.display=i?"none":""};e.setAttribute("data-animated","true"),i||(e.style.display="");var c,d;if("slide"===t){if(c=o(["height","borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],0),d={},!i){var f=window.getComputedStyle(e);d=r(["height","borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],f),n(e,c)}e.style.overflowY="hidden",l(e,i?c:d,a)}else c={opacity:0},d={opacity:1},i||n(e,c),l(e,i?c:d,a)}function l(e,t,i){var n=+new Date,o=window.getComputedStyle(e),r={},s={};for(var a in t){t[a]=parseFloat(t[a]);var l=t[a],d=parseFloat(o[a]);d!=l?(s[a]=(l-d)/c,r[a]=d):delete t[a]}var f=function h(){var o,a,l,c,d=+new Date,f=d-n,u=!0;for(var g in t){o=s[g],a=t[g],l=o*f,c=r[g]+l,o>0&&c>=a||o<0&&c<=a?c=a:u=!1,r[g]=c;var p="opacity"!==g?"px":"";e.style[g]=c+p}n=+new Date,u?i&&i():window.requestAnimationFrame&&requestAnimationFrame(h)||setTimeout(h,32)};f()}var c=320;t.exports={toggle:a,animate:l,animated:s}},{}],3:[function(e,t,i){function n(e,t){var i={};for(var n in e)i[n]=e[n];for(var n in t)i[n]=t[n];return i}function o(){var e=document.body,t=document.documentElement,i=Math.max(e.scrollHeight,e.offsetHeight,t.clientHeight,t.scrollHeight,t.offsetHeight);return i}var r,s={animation:"fade",rehide:!1,content:"",cookie:null,icon:"&times",minimumScreenWidth:0,position:"center",testMode:!1,trigger:!1,closable:!0},a=e("./animator.js"),l=function(e,t){this.id=e,this.config=n(s,t),this.overlay=document.getElementById("boxzilla-overlay"),this.visible=!1,this.dismissed=!1,this.triggered=!1,this.triggerHeight=0,this.cookieSet=!1,this.element=null,this.closeIcon=null,this.config.trigger&&("percentage"!==this.config.trigger.method&&"element"!==this.config.trigger.method||(this.triggerHeight=this.calculateTriggerHeight()),this.cookieSet=this.isCookieSet()),this.dom(),this.events()};l.prototype.events=function(){var e=this;this.closeIcon&&this.closeIcon.addEventListener("click",e.dismiss.bind(this)),this.element.addEventListener("click",function(t){"A"===t.target.tagName&&r.trigger("box.interactions.link",[e,t.target])},!1),this.element.addEventListener("submit",function(t){e.setCookie(),r.trigger("box.interactions.form",[e,t.target])},!1),window.addEventListener("hashchange",function(){var t="#boxzilla-"+e.id;location.hash===t&&e.toggle()}),this.fits()&&this.locationHashRefersBox()&&window.addEventListener("load",this.show.bind(this))},l.prototype.dom=function(){var e=document.createElement("div");e.className="boxzilla-container boxzilla-"+this.config.position+"-container";var t=document.createElement("div");t.setAttribute("id","boxzilla-"+this.id),t.className="boxzilla boxzilla-"+this.id+" boxzilla-"+this.config.position,t.style.display="none",e.appendChild(t);var i=document.createElement("div");i.className="boxzilla-content",i.innerHTML=this.config.content,t.appendChild(i);var n=i.querySelectorAll("script");if(n.length){for(var o=document.createElement("script"),r=0;r<n.length;r++)o.appendChild(document.createTextNode(n[r].text)),n[r].parentNode.removeChild(n[r]);document.body.appendChild(o)}if(this.config.closable&&this.config.icon){var s=document.createElement("span");s.className="boxzilla-close-icon",s.innerHTML=this.config.icon,t.appendChild(s),this.closeIcon=s}document.body.appendChild(e),this.element=t},l.prototype.setCustomBoxStyling=function(){var e=this.element.style.display;this.element.style.display="",this.element.style.overflowY="auto",this.element.style.maxHeight="none";var t=window.innerHeight,i=this.element.clientHeight;if(i>t&&(this.element.style.maxHeight=t+"px",this.element.style.overflowY="scroll"),"center"===this.config.position){var n=(t-i)/2;n=n>=0?n:0,this.element.style.marginTop=n+"px"}this.element.style.display=e},l.prototype.toggle=function(e){if("undefined"==typeof e&&(e=!this.visible),e===this.visible)return!1;if(a.animated(this.element))return!1;if(!e&&!this.config.closable)return!1;this.visible=e,this.setCustomBoxStyling(),r.trigger("box."+(e?"show":"hide"),[this]),"center"===this.config.position&&a.toggle(this.overlay,"fade"),a.toggle(this.element,this.config.animation);var t=this.element.querySelector("input, textarea");return t&&t.focus(),!0},l.prototype.show=function(){return this.toggle(!0)},l.prototype.hide=function(){return this.toggle(!1)},l.prototype.calculateTriggerHeight=function(){var e=0;if("element"===this.config.trigger.method){var t=document.body.querySelector(this.config.trigger.value);if(t){var i=t.getBoundingClientRect();e=i.top}}else"percentage"===this.config.trigger.method&&(e=this.config.trigger.value/100*o());return e},l.prototype.locationHashRefersBox=function(){if(!window.location.hash||0===window.location.hash.length)return!1;var e=window.location.hash.substring(1);return e===this.element.id||!!this.element.querySelector("#"+e)},l.prototype.fits=function(){return this.config.minimumScreenWidth<=0||window.innerWidth>this.config.minimumScreenWidth},l.prototype.mayAutoShow=function(){return!this.dismissed&&(!!this.fits()&&(!!this.config.trigger&&!this.cookieSet))},l.prototype.mayRehide=function(){return this.config.rehide&&this.triggered},l.prototype.isCookieSet=function(){if(this.config.testMode)return!1;if(!this.config.cookie||!this.config.cookie.triggered&&!this.config.cookie.dismissed)return!1;var e="true"===document.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*boxzilla_box_"+this.id+"\\s*\\=\\s*([^;]*).*$)|^.*$"),"$1");return e},l.prototype.setCookie=function(e){var t=new Date;t.setHours(t.getHours()+e),document.cookie="boxzilla_box_"+this.id+"=true; expires="+t.toUTCString()+"; path=/"},l.prototype.trigger=function(){var e=this.show();e&&(this.triggered=!0,this.config.cookie&&this.config.cookie.triggered&&this.setCookie(this.config.cookie.triggered))},l.prototype.dismiss=function(e){return e&&e.preventDefault(),!!this.visible&&(this.hide(),this.config.cookie&&this.config.cookie.dismissed&&this.setCookie(this.config.cookie.dismissed),this.dismissed=!0,r.trigger("box.dismiss",[this]),!0)},t.exports=function(e){return r=e,l}},{"./animator.js":2}],4:[function(e,t,i){function n(e,t,i){t||(t=250);var n,o;return function(){var r=i||this,s=+new Date,a=arguments;n&&s<n+t?(clearTimeout(o),o=setTimeout(function(){n=s,e.apply(r,a)},t)):(n=s,e.apply(r,a))}}function o(e){27==e.keyCode&&x.dismiss()}function r(){h()||z.forEach(function(e){e.mayAutoShow()&&"pageviews"===e.config.trigger.method&&b>=e.config.trigger.value&&e.trigger()})}function s(){h()||z.forEach(function(e){e.mayAutoShow()&&("time_on_site"===e.config.trigger.method&&v.time>=e.config.trigger.value&&e.trigger(),"time_on_page"===e.config.trigger.method&&y.time>=e.config.trigger.value&&e.trigger())})}function a(){var e=(window.scrollY||window.pageYOffset)+.75*window.innerHeight;z.forEach(function(t){if(t.mayAutoShow()&&!(t.triggerHeight<=0))if(e>t.triggerHeight){if(h())return;t.trigger()}else t.mayRehide()&&t.hide()})}function l(){z.forEach(function(e){e.setCustomBoxStyling()})}function c(e){var t=e.offsetX,i=e.offsetY;z.forEach(function(e){var n=e.element.getBoundingClientRect(),o=100+.05*window.innerWidth;(t<n.left-o||t>n.right+o||i<n.top-o||i>n.bottom+o)&&e.dismiss()})}function d(){m||h()||(z.forEach(function(e){e.mayAutoShow()&&"exit_intent"===e.config.trigger.method&&e.trigger()}),m=!0)}function f(e){var t=400;e.clientY<=0&&(p=window.setTimeout(d,t))}function h(){for(var e=0;e<z.length;e++){var t=z[e];if(t.visible)return!0}return!1}function u(){p&&(window.clearInterval(p),p=null)}var g,p,m,v,y,b,w=e("wolfy87-eventemitter"),x=Object.create(w.prototype),E=e("./box.js")(x),_=e("./timer.js"),z=[],L={start:function(){var e=sessionStorage.getItem("boxzilla_timer");e&&(v.time=e),v.start(),y.start()},stop:function(){sessionStorage.setItem("boxzilla_timer",v.time),v.stop(),y.stop()}};x.init=function(){v=new _(sessionStorage.getItem("boxzilla_timer")||0),y=new _(0),b=sessionStorage.getItem("boxzilla_pageviews")||0;var t=e("./styles.js"),i=document.createElement("style");i.setAttribute("type","text/css"),i.innerHTML=t,document.head.appendChild(i),g=document.createElement("div"),g.style.display="none",g.id="boxzilla-overlay",document.body.appendChild(g),window.addEventListener("scroll",n(a)),window.addEventListener("resize",n(l)),window.addEventListener("load",l),g.addEventListener("click",c),window.setInterval(s,1e3),window.setTimeout(r,1e3),document.documentElement.addEventListener("mouseleave",f),document.documentElement.addEventListener("mouseenter",u),document.addEventListener("keyup",o),L.start(),window.addEventListener("focus",L.start),window.addEventListener("beforeunload",function(){L.stop(),sessionStorage.setItem("boxzilla_pageviews",++b)}),window.addEventListener("blur",L.stop),x.trigger("ready")},x.create=function(e,t){var i=new E(e,t);return z.push(i),i},x.get=function(e){for(var t=0;t<z.length;t++){var i=z[t];if(i.id==e)return i}throw new Error("No box exists with ID "+e)},x.dismiss=function(e){"undefined"==typeof e?z.forEach(function(e){e.dismiss()}):"object"===_typeof(z[e])&&x.get(e).dismiss()},x.hide=function(e){"undefined"==typeof e?z.forEach(function(e){e.hide()}):x.get(e).hide()},x.show=function(e){"undefined"==typeof e?z.forEach(function(e){e.show()}):x.get(e).show()},x.toggle=function(e){"undefined"==typeof e?z.forEach(function(e){e.toggle()}):x.get(e).toggle()},x.boxes=z,window.Boxzilla=x,"undefined"!=typeof t&&t.exports&&(t.exports=x)},{"./box.js":3,"./styles.js":5,"./timer.js":6,"wolfy87-eventemitter":7}],5:[function(e,t,i){var n="#boxzilla-overlay{position:fixed;background:rgba(0,0,0,.65);width:100%;height:100%;left:0;top:0;z-index:99999}.boxzilla-center-container{position:fixed;top:0;left:0;right:0;height:0;text-align:center;z-index:999999;line-height:0}.boxzilla-center-container .boxzilla{display:inline-block;text-align:left;position:relative;line-height:normal}.boxzilla{position:fixed;z-index:999999;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;background:#fff;padding:25px}.boxzilla.boxzilla-top-left{top:0;left:0}.boxzilla.boxzilla-top-right{top:0;right:0}.boxzilla.boxzilla-bottom-left{bottom:0;left:0}.boxzilla.boxzilla-bottom-right{bottom:0;right:0}.boxzilla-content>:first-child{margin-top:0;padding-top:0}.boxzilla-content>:last-child{margin-bottom:0;padding-bottom:0}.boxzilla-close-icon{position:absolute;right:0;top:0;text-align:center;padding:6px;cursor:pointer;-webkit-appearance:none;font-size:28px;font-weight:700;line-height:20px;color:#000;opacity:.5}.boxzilla-close-icon:focus,.boxzilla-close-icon:hover{opacity:.8}";t.exports=n},{}],6:[function(e,t,i){var n=function(e){this.time=e,this.interval=0};n.prototype.tick=function(){this.time++},n.prototype.start=function(){this.interval||(this.interval=window.setInterval(this.tick.bind(this),1e3))},n.prototype.stop=function(){this.interval&&(window.clearInterval(this.interval),this.interval=0)},t.exports=n},{}],7:[function(e,i,n){(function(){function e(){}function n(e,t){for(var i=e.length;i--;)if(e[i].listener===t)return i;return-1}function o(e){return function(){return this[e].apply(this,arguments)}}var r=e.prototype,s=this,a=s.EventEmitter;r.getListeners=function(e){var t,i,n=this._getEvents();if(e instanceof RegExp){t={};for(i in n)n.hasOwnProperty(i)&&e.test(i)&&(t[i]=n[i])}else t=n[e]||(n[e]=[]);return t},r.flattenListeners=function(e){var t,i=[];for(t=0;t<e.length;t+=1)i.push(e[t].listener);return i},r.getListenersAsObject=function(e){var t,i=this.getListeners(e);return i instanceof Array&&(t={},t[e]=i),t||i},r.addListener=function(e,t){var i,o=this.getListenersAsObject(e),r="object"===("undefined"==typeof t?"undefined":_typeof(t));for(i in o)o.hasOwnProperty(i)&&n(o[i],t)===-1&&o[i].push(r?t:{listener:t,once:!1});return this},r.on=o("addListener"),r.addOnceListener=function(e,t){return this.addListener(e,{listener:t,once:!0})},r.once=o("addOnceListener"),r.defineEvent=function(e){return this.getListeners(e),this},r.defineEvents=function(e){for(var t=0;t<e.length;t+=1)this.defineEvent(e[t]);return this},r.removeListener=function(e,t){var i,o,r=this.getListenersAsObject(e);for(o in r)r.hasOwnProperty(o)&&(i=n(r[o],t),i!==-1&&r[o].splice(i,1));return this},r.off=o("removeListener"),r.addListeners=function(e,t){return this.manipulateListeners(!1,e,t)},r.removeListeners=function(e,t){return this.manipulateListeners(!0,e,t)},r.manipulateListeners=function(e,t,i){var n,o,r=e?this.removeListener:this.addListener,s=e?this.removeListeners:this.addListeners;if("object"!==("undefined"==typeof t?"undefined":_typeof(t))||t instanceof RegExp)for(n=i.length;n--;)r.call(this,t,i[n]);else for(n in t)t.hasOwnProperty(n)&&(o=t[n])&&("function"==typeof o?r.call(this,n,o):s.call(this,n,o));return this},r.removeEvent=function(e){var t,i="undefined"==typeof e?"undefined":_typeof(e),n=this._getEvents();if("string"===i)delete n[e];else if(e instanceof RegExp)for(t in n)n.hasOwnProperty(t)&&e.test(t)&&delete n[t];else delete this._events;return this},r.removeAllListeners=o("removeEvent"),r.emitEvent=function(e,t){var i,n,o,r,s,a=this.getListenersAsObject(e);for(r in a)if(a.hasOwnProperty(r))for(i=a[r].slice(0),o=i.length;o--;)n=i[o],n.once===!0&&this.removeListener(e,n.listener),s=n.listener.apply(this,t||[]),s===this._getOnceReturnValue()&&this.removeListener(e,n.listener);return this},r.trigger=o("emitEvent"),r.emit=function(e){var t=Array.prototype.slice.call(arguments,1);return this.emitEvent(e,t)},r.setOnceReturnValue=function(e){return this._onceReturnValue=e,this},r._getOnceReturnValue=function(){return!this.hasOwnProperty("_onceReturnValue")||this._onceReturnValue},r._getEvents=function(){return this._events||(this._events={})},e.noConflict=function(){return s.EventEmitter=a,e},"function"==typeof t&&t.amd?t(function(){return e}):"object"===("undefined"==typeof i?"undefined":_typeof(i))&&i.exports?i.exports=e:s.EventEmitter=e}).call(this)},{}]},{},[1])}();
2
  //# sourceMappingURL=script.min.js.map
assets/js/script.min.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["script.js"],"names":["_typeof","Symbol","iterator","obj","constructor","require","undefined","define","e","t","n","r","s","o","u","a","i","f","Error","code","l","exports","call","length","1","module","css","element","styles","background_color","style","background","color","border_color","borderColor","border_width","borderWidth","parseInt","border_style","borderStyle","width","maxWidth","Boxzilla","options","window","boxzilla_options","isLoggedIn","document","body","className","indexOf","testMode","console","log","init","boxes","boxOpts","location","origin","substring","content","replace","box","create","id","addEventListener","mc4wp_forms_config","submitted_form","selector","element_id","boxId","hasOwnProperty","querySelector","show","boxzilla","2","property","initObjectProperties","properties","value","newObject","copyObjectProperties","object","animated","getAttribute","toggle","animation","nowVisible","display","offsetLeft","clone","cloneNode","cleanup","removeAttribute","setAttribute","hiddenStyles","visibleStyles","computedStyles","getComputedStyle","overflowY","animate","opacity","targetStyles","fn","last","Date","initialStyles","currentStyles","propSteps","parseFloat","to","current","duration","tick","step","increment","newValue","now","timeSinceLastTick","done","suffix","requestAnimationFrame","setTimeout","3","merge","obj1","obj2","obj3","attrname","getDocumentHeight","html","documentElement","height","Math","max","scrollHeight","offsetHeight","clientHeight","defaults","rehide","cookie","icon","minimumScreenWidth","position","trigger","closable","Animator","Box","config","this","overlay","getElementById","visible","dismissed","triggered","triggerHeight","cookieSet","closeIcon","method","calculateTriggerHeight","isCookieSet","dom","events","prototype","dismiss","bind","target","tagName","setCookie","needle","hash","fits","locationHashRefersBox","wrapper","createElement","appendChild","innerHTML","scripts","querySelectorAll","script","createTextNode","text","parentNode","removeChild","setCustomBoxStyling","origDisplay","maxHeight","windowHeight","innerHeight","boxHeight","newTopMargin","marginTop","firstInput","focus","hide","triggerElement","offset","getBoundingClientRect","top","elementId","innerWidth","mayAutoShow","mayRehide","RegExp","hours","expiryDate","setHours","getHours","toUTCString","shown","_Boxzilla","./animator.js","4","throttle","threshhold","scope","deferTimer","context","args","arguments","clearTimeout","apply","onKeyUp","keyCode","checkPageViewsCriteria","isAnyBoxVisible","forEach","pageViews","checkTimeCriteria","siteTimer","time","pageTimer","checkHeightCriteria","scrollY","pageYOffset","recalculateHeights","onOverlayClick","x","offsetX","y","offsetY","rect","margin","left","right","bottom","triggerExitIntent","exitIntentTriggered","onMouseLeave","delay","clientY","exitIntentDelayTimer","onMouseEnter","clearInterval","EventEmitter","Object","Timer","timers","start","sessionTime","sessionStorage","getItem","stop","setItem","styleElement","head","setInterval","opts","push","get","./box.js","./styles.js","./timer.js","wolfy87-eventemitter","5","6","interval","7","indexOfListener","listeners","listener","alias","name","proto","originalGlobalValue","getListeners","evt","response","key","_getEvents","test","flattenListeners","flatListeners","getListenersAsObject","Array","addListener","listenerIsWrapped","once","on","addOnceListener","defineEvent","defineEvents","evts","removeListener","index","splice","off","addListeners","manipulateListeners","removeListeners","remove","single","multiple","removeEvent","type","_events","removeAllListeners","emitEvent","listenersMap","slice","_getOnceReturnValue","emit","setOnceReturnValue","_onceReturnValue","noConflict","amd"],"mappings":"AAAA,YAEA,IAAIA,SAA4B,kBAAXC,SAAoD,gBAApBA,QAAOC,SAAwB,SAAUC,GAAO,aAAcA,IAAS,SAAUA,GAAO,MAAOA,IAAyB,kBAAXF,SAAyBE,EAAIC,cAAgBH,OAAS,eAAkBE,KAE1O,WACI,GAAIE,GAAUC,OAA6DC,EAASD,QAAU,QAAUE,GAAEC,EAAGC,EAAGC,GAC5G,QAASC,GAAEC,EAAGC,GACV,IAAKJ,EAAEG,GAAI,CACP,IAAKJ,EAAEI,GAAI,CACP,GAAIE,GAAsB,kBAAXV,IAAyBA,CAAQ,KAAKS,GAAKC,EAAG,MAAOA,GAAEF,GAAG,EAAI,IAAIG,EAAG,MAAOA,GAAEH,GAAG,EAAI,I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O,EAEjBzO,EAAQyO,aAAeA,IAE5BxO,KAAK+H,gBACG","file":"script.min.js","sourcesContent":["\"use strict\";\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol ? \"symbol\" : typeof obj; };\n\n(function () {\n var require = undefined;var module = undefined;var exports = undefined;var define = undefined;(function e(t, n, r) {\n function s(o, u) {\n if (!n[o]) {\n if (!t[o]) {\n var a = typeof require == \"function\" && require;if (!u && a) return a(o, !0);if (i) return i(o, !0);var f = new Error(\"Cannot find module '\" + o + \"'\");throw f.code = \"MODULE_NOT_FOUND\", f;\n }var l = n[o] = { exports: {} };t[o][0].call(l.exports, function (e) {\n var n = t[o][1][e];return s(n ? n : e);\n }, l, l.exports, e, t, n, r);\n }return n[o].exports;\n }var i = typeof require == \"function\" && require;for (var o = 0; o < r.length; o++) {\n s(r[o]);\n }return s;\n })({ 1: [function (require, module, exports) {\n 'use strict';\n\n var Boxzilla = require('boxzilla');\n var options = window.boxzilla_options;\n var isLoggedIn = document.body.className.indexOf('logged-in') > -1;\n\n // print message when test mode is enabled\n if (isLoggedIn && options.testMode) {\n console.log('Boxzilla: Test mode is enabled. Please disable test mode if you\\'re done testing.');\n }\n\n // init boxzilla\n Boxzilla.init();\n\n // create boxes from options\n for (var i = 0; i < options.boxes.length; i++) {\n // get opts\n var boxOpts = options.boxes[i];\n boxOpts.testMode = isLoggedIn && options.testMode;\n\n // fix http:// links in box content....\n if (window.location.origin.substring(0, 5) === \"https\") {\n boxOpts.content = boxOpts.content.replace(window.location.origin.replace(\"https\", \"http\"), window.location.origin);\n }\n\n // create box\n var box = Boxzilla.create(boxOpts.id, boxOpts);\n\n // add custom css to box\n css(box.element, boxOpts.css);\n }\n\n // helper function for setting CSS styles\n function css(element, styles) {\n if (styles.background_color) {\n element.style.background = styles.background_color;\n }\n\n if (styles.color) {\n element.style.color = styles.color;\n }\n\n if (styles.border_color) {\n element.style.borderColor = styles.border_color;\n }\n\n if (styles.border_width) {\n element.style.borderWidth = parseInt(styles.border_width) + \"px\";\n }\n\n if (styles.border_style) {\n element.style.borderStyle = styles.border_style;\n }\n\n if (styles.width) {\n element.style.maxWidth = parseInt(styles.width) + \"px\";\n }\n }\n\n /**\n * If a MailChimp for WordPress form was submitted, open the box containing that form (if any)\n *\n * TODO: Just set location hash from MailChimp for WP?\n */\n window.addEventListener('load', function () {\n if (_typeof(window.mc4wp_forms_config) === \"object\" && window.mc4wp_forms_config.submitted_form) {\n var selector = '#' + window.mc4wp_forms_config.submitted_form.element_id;\n var boxes = Boxzilla.boxes;\n for (var boxId in boxes) {\n if (!boxes.hasOwnProperty(boxId)) {\n continue;\n }\n var box = boxes[boxId];\n if (box.element.querySelector(selector)) {\n box.show();\n return;\n }\n }\n }\n });\n\n window.Boxzilla = Boxzilla;\n }, { \"boxzilla\": 4 }], 2: [function (require, module, exports) {\n var duration = 320;\n\n function css(element, styles) {\n for (var property in styles) {\n element.style[property] = styles[property];\n }\n }\n\n function initObjectProperties(properties, value) {\n var newObject = {};\n for (var i = 0; i < properties.length; i++) {\n newObject[properties[i]] = value;\n }\n return newObject;\n }\n\n function copyObjectProperties(properties, object) {\n var newObject = {};\n for (var i = 0; i < properties.length; i++) {\n newObject[properties[i]] = object[properties[i]];\n }\n return newObject;\n }\n\n /**\n * Checks if the given element is currently being animated.\n *\n * @param element\n * @returns {boolean}\n */\n function animated(element) {\n return !!element.getAttribute('data-animated');\n }\n\n /**\n * Toggles the element using the given animation.\n *\n * @param element\n * @param animation Either \"fade\" or \"slide\"\n */\n function toggle(element, animation) {\n var nowVisible = element.style.display != 'none' || element.offsetLeft > 0;\n\n // create clone for reference\n var clone = element.cloneNode(true);\n var cleanup = function cleanup() {\n element.removeAttribute('data-animated');\n element.setAttribute('style', clone.getAttribute('style'));\n element.style.display = nowVisible ? 'none' : '';\n };\n\n // store attribute so everyone knows we're animating this element\n element.setAttribute('data-animated', \"true\");\n\n // toggle element visiblity right away if we're making something visible\n if (!nowVisible) {\n element.style.display = '';\n }\n\n var hiddenStyles, visibleStyles;\n\n // animate properties\n if (animation === 'slide') {\n hiddenStyles = initObjectProperties([\"height\", \"borderTopWidth\", \"borderBottomWidth\", \"paddingTop\", \"paddingBottom\"], 0);\n visibleStyles = {};\n\n if (!nowVisible) {\n var computedStyles = window.getComputedStyle(element);\n visibleStyles = copyObjectProperties([\"height\", \"borderTopWidth\", \"borderBottomWidth\", \"paddingTop\", \"paddingBottom\"], computedStyles);\n css(element, hiddenStyles);\n }\n\n // don't show a scrollbar during animation\n element.style.overflowY = 'hidden';\n animate(element, nowVisible ? hiddenStyles : visibleStyles, cleanup);\n } else {\n hiddenStyles = { opacity: 0 };\n visibleStyles = { opacity: 1 };\n if (!nowVisible) {\n css(element, hiddenStyles);\n }\n\n animate(element, nowVisible ? hiddenStyles : visibleStyles, cleanup);\n }\n }\n\n function animate(element, targetStyles, fn) {\n var last = +new Date();\n var initialStyles = window.getComputedStyle(element);\n var currentStyles = {};\n var propSteps = {};\n\n for (var property in targetStyles) {\n // make sure we have an object filled with floats\n targetStyles[property] = parseFloat(targetStyles[property]);\n\n // calculate step size & current value\n var to = targetStyles[property];\n var current = parseFloat(initialStyles[property]);\n\n // is there something to do?\n if (current == to) {\n delete targetStyles[property];\n continue;\n }\n\n propSteps[property] = (to - current) / duration; // points per second\n currentStyles[property] = current;\n }\n\n var tick = function tick() {\n var now = +new Date();\n var timeSinceLastTick = now - last;\n var done = true;\n\n var step, to, increment, newValue;\n for (var property in targetStyles) {\n step = propSteps[property];\n to = targetStyles[property];\n increment = step * timeSinceLastTick;\n newValue = currentStyles[property] + increment;\n\n if (step > 0 && newValue >= to || step < 0 && newValue <= to) {\n newValue = to;\n } else {\n done = false;\n }\n\n // store new value\n currentStyles[property] = newValue;\n\n var suffix = property !== \"opacity\" ? \"px\" : \"\";\n element.style[property] = newValue + suffix;\n }\n\n last = +new Date();\n\n // keep going until we're done for all props\n if (!done) {\n window.requestAnimationFrame && requestAnimationFrame(tick) || setTimeout(tick, 32);\n } else {\n // call callback\n fn && fn();\n }\n };\n\n tick();\n }\n\n module.exports = {\n 'toggle': toggle,\n 'animate': animate,\n 'animated': animated\n };\n }, {}], 3: [function (require, module, exports) {\n 'use strict';\n\n var defaults = {\n 'animation': 'fade',\n 'rehide': false,\n 'content': '',\n 'cookie': null,\n 'icon': '&times',\n 'minimumScreenWidth': 0,\n 'position': 'center',\n 'testMode': false,\n 'trigger': false,\n 'closable': true\n },\n Boxzilla,\n Animator = require('./animator.js');\n\n /**\n * Merge 2 objects, values of the latter overwriting the former.\n *\n * @param obj1\n * @param obj2\n * @returns {*}\n */\n function merge(obj1, obj2) {\n var obj3 = {};\n for (var attrname in obj1) {\n obj3[attrname] = obj1[attrname];\n }\n for (var attrname in obj2) {\n obj3[attrname] = obj2[attrname];\n }\n return obj3;\n }\n\n /**\n * Get the real height of entire document.\n * @returns {number}\n */\n function getDocumentHeight() {\n var body = document.body,\n html = document.documentElement;\n\n var height = Math.max(body.scrollHeight, body.offsetHeight, html.clientHeight, html.scrollHeight, html.offsetHeight);\n\n return height;\n }\n\n // Box Object\n var Box = function Box(id, config) {\n this.id = id;\n\n // store config values\n this.config = merge(defaults, config);\n\n // store ref to overlay\n this.overlay = document.getElementById('boxzilla-overlay');\n\n // state\n this.visible = false;\n this.dismissed = false;\n this.triggered = false;\n this.triggerHeight = 0;\n this.cookieSet = false;\n this.element = null;\n this.closeIcon = null;\n\n // if a trigger was given, calculate values once and store\n if (this.config.trigger) {\n if (this.config.trigger.method === 'percentage' || this.config.trigger.method === 'element') {\n this.triggerHeight = this.calculateTriggerHeight();\n }\n\n this.cookieSet = this.isCookieSet();\n }\n\n // create dom elements for this box\n this.dom();\n\n // further initialise the box\n this.events();\n };\n\n // initialise the box\n Box.prototype.events = function () {\n var box = this;\n\n // attach event to \"close\" icon inside box\n this.closeIcon && this.closeIcon.addEventListener('click', box.dismiss.bind(this));\n\n this.element.addEventListener('click', function (e) {\n if (e.target.tagName === 'A') {\n Boxzilla.trigger('box.interactions.link', [box, e.target]);\n }\n }, false);\n\n this.element.addEventListener('submit', function (e) {\n box.setCookie();\n Boxzilla.trigger('box.interactions.form', [box, e.target]);\n }, false);\n\n window.addEventListener(\"hashchange\", function () {\n var needle = \"#boxzilla-\" + box.id;\n if (location.hash === needle) {\n box.toggle();\n }\n });\n\n // maybe show box right away\n if (this.fits() && this.locationHashRefersBox()) {\n window.addEventListener('load', this.show.bind(this));\n }\n };\n\n // generate dom elements for this box\n Box.prototype.dom = function () {\n var wrapper = document.createElement('div');\n wrapper.className = 'boxzilla-container boxzilla-' + this.config.position + '-container';\n\n var box = document.createElement('div');\n box.setAttribute('id', 'boxzilla-' + this.id);\n box.className = 'boxzilla boxzilla-' + this.id + ' boxzilla-' + this.config.position;\n box.style.display = 'none';\n wrapper.appendChild(box);\n\n var content = document.createElement('div');\n content.className = 'boxzilla-content';\n content.innerHTML = this.config.content;\n box.appendChild(content);\n\n // remove <script> from box content and append them to the document body\n var scripts = content.querySelectorAll('script');\n if (scripts.length) {\n var script = document.createElement('script');\n for (var i = 0; i < scripts.length; i++) {\n script.appendChild(document.createTextNode(scripts[i].text));\n scripts[i].parentNode.removeChild(scripts[i]);\n }\n document.body.appendChild(script);\n }\n\n if (this.config.closable && this.config.icon) {\n var closeIcon = document.createElement('span');\n closeIcon.className = \"boxzilla-close-icon\";\n closeIcon.innerHTML = this.config.icon;\n box.appendChild(closeIcon);\n this.closeIcon = closeIcon;\n }\n\n document.body.appendChild(wrapper);\n this.element = box;\n };\n\n // set (calculate) custom box styling depending on box options\n Box.prototype.setCustomBoxStyling = function () {\n\n // reset element to its initial state\n var origDisplay = this.element.style.display;\n this.element.style.display = '';\n this.element.style.overflowY = 'auto';\n this.element.style.maxHeight = 'none';\n\n // get new dimensions\n var windowHeight = window.innerHeight;\n var boxHeight = this.element.clientHeight;\n\n // add scrollbar to box and limit height\n if (boxHeight > windowHeight) {\n this.element.style.maxHeight = windowHeight + \"px\";\n this.element.style.overflowY = 'scroll';\n }\n\n // set new top margin for boxes which are centered\n if (this.config.position === 'center') {\n var newTopMargin = (windowHeight - boxHeight) / 2;\n newTopMargin = newTopMargin >= 0 ? newTopMargin : 0;\n this.element.style.marginTop = newTopMargin + \"px\";\n }\n\n this.element.style.display = origDisplay;\n };\n\n // toggle visibility of the box\n Box.prototype.toggle = function (show) {\n\n // revert visibility if no explicit argument is given\n if (typeof show === \"undefined\") {\n show = !this.visible;\n }\n\n // is box already at desired visibility?\n if (show === this.visible) {\n return false;\n }\n\n // is box being animated?\n if (Animator.animated(this.element)) {\n return false;\n }\n\n // if box should be hidden but is not closable, bail.\n if (!show && !this.config.closable) {\n return false;\n }\n\n // set new visibility status\n this.visible = show;\n\n // calculate new styling rules\n this.setCustomBoxStyling();\n\n // trigger event\n Boxzilla.trigger('box.' + (show ? 'show' : 'hide'), [this]);\n\n // show or hide box using selected animation\n if (this.config.position === 'center') {\n Animator.toggle(this.overlay, \"fade\");\n }\n\n Animator.toggle(this.element, this.config.animation);\n\n // focus on first input field in box\n var firstInput = this.element.querySelector('input, textarea');\n if (firstInput) {\n firstInput.focus();\n }\n\n return true;\n };\n\n // show the box\n Box.prototype.show = function () {\n return this.toggle(true);\n };\n\n // hide the box\n Box.prototype.hide = function () {\n return this.toggle(false);\n };\n\n // calculate trigger height\n Box.prototype.calculateTriggerHeight = function () {\n var triggerHeight = 0;\n\n if (this.config.trigger.method === 'element') {\n var triggerElement = document.body.querySelector(this.config.trigger.value);\n if (triggerElement) {\n var offset = triggerElement.getBoundingClientRect();\n triggerHeight = offset.top;\n }\n } else if (this.config.trigger.method === 'percentage') {\n triggerHeight = this.config.trigger.value / 100 * getDocumentHeight();\n }\n\n return triggerHeight;\n };\n\n // checks whether window.location.hash equals the box element ID or that of any element inside the box\n Box.prototype.locationHashRefersBox = function () {\n\n if (!window.location.hash || 0 === window.location.hash.length) {\n return false;\n }\n\n var elementId = window.location.hash.substring(1);\n if (elementId === this.element.id) {\n return true;\n } else if (this.element.querySelector('#' + elementId)) {\n return true;\n }\n\n return false;\n };\n\n Box.prototype.fits = function () {\n if (this.config.minimumScreenWidth <= 0) {\n return true;\n }\n\n return window.innerWidth > this.config.minimumScreenWidth;\n };\n\n // is this box enabled?\n Box.prototype.mayAutoShow = function () {\n\n if (this.dismissed) {\n return false;\n }\n\n // check if box fits on given minimum screen width\n if (!this.fits()) {\n return false;\n }\n\n // if trigger empty or error in calculating triggerHeight, return false\n if (!this.config.trigger) {\n return false;\n }\n\n // rely on cookie value (show if not set, don't show if set)\n return !this.cookieSet;\n };\n\n Box.prototype.mayRehide = function () {\n return this.config.rehide && this.triggered;\n };\n\n Box.prototype.isCookieSet = function () {\n // always show on test mode\n if (this.config.testMode) {\n return false;\n }\n\n // if either cookie is null or trigger & dismiss are both falsey, don't bother checking.\n if (!this.config.cookie || !this.config.cookie.triggered && !this.config.cookie.dismissed) {\n return false;\n }\n\n var cookieSet = document.cookie.replace(new RegExp(\"(?:(?:^|.*;)\\\\s*\" + 'boxzilla_box_' + this.id + \"\\\\s*\\\\=\\\\s*([^;]*).*$)|^.*$\"), \"$1\") === \"true\";\n return cookieSet;\n };\n\n // set cookie that disables automatically showing the box\n Box.prototype.setCookie = function (hours) {\n var expiryDate = new Date();\n expiryDate.setHours(expiryDate.getHours() + hours);\n document.cookie = 'boxzilla_box_' + this.id + '=true; expires=' + expiryDate.toUTCString() + '; path=/';\n };\n\n Box.prototype.trigger = function () {\n var shown = this.show();\n if (!shown) {\n return;\n }\n\n this.triggered = true;\n if (this.config.cookie && this.config.cookie.triggered) {\n this.setCookie(this.config.cookie.triggered);\n }\n };\n\n Box.prototype.dismiss = function () {\n this.hide();\n\n if (this.config.cookie && this.config.cookie.dismissed) {\n this.setCookie(this.config.cookie.dismissed);\n }\n\n this.dismissed = true;\n Boxzilla.trigger('box.dismiss', [this]);\n };\n\n module.exports = function (_Boxzilla) {\n Boxzilla = _Boxzilla;\n return Box;\n };\n }, { \"./animator.js\": 2 }], 4: [function (require, module, exports) {\n 'use strict';\n\n var EventEmitter = require('wolfy87-eventemitter'),\n Boxzilla = Object.create(EventEmitter.prototype),\n Box = require('./box.js')(Boxzilla),\n Timer = require('./timer.js'),\n boxes = [],\n overlay,\n exitIntentDelayTimer,\n exitIntentTriggered,\n siteTimer,\n pageTimer,\n pageViews;\n\n function throttle(fn, threshhold, scope) {\n threshhold || (threshhold = 250);\n var last, deferTimer;\n return function () {\n var context = scope || this;\n\n var now = +new Date(),\n args = arguments;\n if (last && now < last + threshhold) {\n // hold on to it\n clearTimeout(deferTimer);\n deferTimer = setTimeout(function () {\n last = now;\n fn.apply(context, args);\n }, threshhold);\n } else {\n last = now;\n fn.apply(context, args);\n }\n };\n }\n\n // \"keyup\" listener\n function onKeyUp(e) {\n if (e.keyCode == 27) {\n Boxzilla.dismiss();\n }\n }\n\n // check \"pageviews\" criteria for each box\n function checkPageViewsCriteria() {\n\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (!box.mayAutoShow()) {\n return;\n }\n\n if (box.config.trigger.method === 'pageviews' && pageViews >= box.config.trigger.value) {\n box.trigger();\n }\n });\n }\n\n // check time trigger criteria for each box\n function checkTimeCriteria() {\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (!box.mayAutoShow()) {\n return;\n }\n\n // check \"time on site\" trigger\n if (box.config.trigger.method === 'time_on_site' && siteTimer.time >= box.config.trigger.value) {\n box.trigger();\n }\n\n // check \"time on page\" trigger\n if (box.config.trigger.method === 'time_on_page' && pageTimer.time >= box.config.trigger.value) {\n box.trigger();\n }\n });\n }\n\n // check triggerHeight criteria for all boxes\n function checkHeightCriteria() {\n var scrollY = (window.scrollY || window.pageYOffset) + window.innerHeight * 0.75;\n\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n\n if (!box.mayAutoShow() || box.triggerHeight <= 0) {\n return;\n }\n\n if (scrollY > box.triggerHeight) {\n box.trigger();\n } else if (box.mayRehide()) {\n box.hide();\n }\n });\n }\n\n // recalculate heights and variables based on height\n function recalculateHeights() {\n boxes.forEach(function (box) {\n box.setCustomBoxStyling();\n });\n }\n\n function onOverlayClick(e) {\n var x = e.offsetX;\n var y = e.offsetY;\n\n // calculate if click was near a box to avoid closing it (click error margin)\n boxes.forEach(function (box) {\n var rect = box.element.getBoundingClientRect();\n var margin = 100 + window.innerWidth * 0.05;\n\n // if click was not anywhere near box, dismiss it.\n if (x < rect.left - margin || x > rect.right + margin || y < rect.top - margin || y > rect.bottom + margin) {\n box.dismiss();\n }\n });\n }\n\n function triggerExitIntent() {\n // do nothing if already triggered OR another box is visible.\n if (exitIntentTriggered || isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (box.mayAutoShow() && box.config.trigger.method === 'exit_intent') {\n box.trigger();\n }\n });\n\n exitIntentTriggered = true;\n }\n\n function onMouseLeave(e) {\n var delay = 400;\n\n // did mouse leave at top of window?\n if (e.clientY <= 0) {\n exitIntentDelayTimer = window.setTimeout(triggerExitIntent, delay);\n }\n }\n\n function isAnyBoxVisible() {\n\n for (var i = 0; i < boxes.length; i++) {\n var box = boxes[i];\n\n if (box.visible) {\n return true;\n }\n }\n\n return false;\n }\n\n function onMouseEnter() {\n if (exitIntentDelayTimer) {\n window.clearInterval(exitIntentDelayTimer);\n exitIntentDelayTimer = null;\n }\n }\n\n var timers = {\n start: function start() {\n var sessionTime = sessionStorage.getItem('boxzilla_timer');\n if (sessionTime) siteTimer.time = sessionTime;\n siteTimer.start();\n pageTimer.start();\n },\n stop: function stop() {\n sessionStorage.setItem('boxzilla_timer', siteTimer.time);\n siteTimer.stop();\n pageTimer.stop();\n }\n };\n\n // initialise & add event listeners\n Boxzilla.init = function () {\n siteTimer = new Timer(sessionStorage.getItem('boxzilla_timer') || 0);\n pageTimer = new Timer(0);\n pageViews = sessionStorage.getItem('boxzilla_pageviews') || 0;\n\n // insert styles into DOM\n var styles = require('./styles.js');\n var styleElement = document.createElement('style');\n styleElement.setAttribute(\"type\", \"text/css\");\n styleElement.innerHTML = styles;\n document.head.appendChild(styleElement);\n\n // add overlay element to dom\n overlay = document.createElement('div');\n overlay.style.display = 'none';\n overlay.id = 'boxzilla-overlay';\n document.body.appendChild(overlay);\n\n // event binds\n window.addEventListener('scroll', throttle(checkHeightCriteria));\n window.addEventListener('resize', throttle(recalculateHeights));\n window.addEventListener('load', recalculateHeights);\n overlay.addEventListener('click', onOverlayClick);\n window.setInterval(checkTimeCriteria, 1000);\n window.setTimeout(checkPageViewsCriteria, 1000);\n document.documentElement.addEventListener('mouseleave', onMouseLeave);\n document.documentElement.addEventListener('mouseenter', onMouseEnter);\n document.addEventListener('keyup', onKeyUp);\n\n timers.start();\n window.addEventListener('focus', timers.start);\n window.addEventListener('beforeunload', function () {\n timers.stop();\n sessionStorage.setItem('boxzilla_pageviews', ++pageViews);\n });\n window.addEventListener('blur', timers.stop);\n\n Boxzilla.trigger('ready');\n };\n\n /**\n * Create a new Box\n *\n * @param string id\n * @param object opts\n *\n * @returns Box\n */\n Boxzilla.create = function (id, opts) {\n var box = new Box(id, opts);\n boxes.push(box);\n return box;\n };\n\n Boxzilla.get = function (id) {\n for (var i = 0; i < boxes.length; i++) {\n var box = boxes[i];\n if (box.id == id) {\n return box;\n }\n }\n\n throw new Error(\"No box exists with ID \" + id);\n };\n\n // dismiss a single box (or all by omitting id param)\n Boxzilla.dismiss = function (id) {\n // if no id given, dismiss all current open boxes\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.dismiss();\n });\n } else if (_typeof(boxes[id]) === \"object\") {\n Boxzilla.get(id).dismiss();\n }\n };\n\n Boxzilla.hide = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.hide();\n });\n } else {\n Boxzilla.get(id).hide();\n }\n };\n\n Boxzilla.show = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.show();\n });\n } else {\n Boxzilla.get(id).show();\n }\n };\n\n Boxzilla.toggle = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.toggle();\n });\n } else {\n Boxzilla.get(id).toggle();\n }\n };\n\n // expose each individual box.\n Boxzilla.boxes = boxes;\n\n window.Boxzilla = Boxzilla;\n\n if (typeof module !== 'undefined' && module.exports) {\n module.exports = Boxzilla;\n }\n }, { \"./box.js\": 3, \"./styles.js\": 5, \"./timer.js\": 6, \"wolfy87-eventemitter\": 7 }], 5: [function (require, module, exports) {\n var styles = \"#boxzilla-overlay{position:fixed;background:rgba(0,0,0,.65);width:100%;height:100%;left:0;top:0;z-index:99999}.boxzilla-center-container{position:fixed;top:0;left:0;right:0;height:0;text-align:center;z-index:999999;line-height:0}.boxzilla-center-container .boxzilla{display:inline-block;text-align:left;position:relative;line-height:normal}.boxzilla{position:fixed;z-index:999999;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;background:#fff;padding:25px}.boxzilla.boxzilla-top-left{top:0;left:0}.boxzilla.boxzilla-top-right{top:0;right:0}.boxzilla.boxzilla-bottom-left{bottom:0;left:0}.boxzilla.boxzilla-bottom-right{bottom:0;right:0}.boxzilla-content>:first-child{margin-top:0;padding-top:0}.boxzilla-content>:last-child{margin-bottom:0;padding-bottom:0}.boxzilla-close-icon{position:absolute;right:0;top:0;text-align:center;padding:6px;cursor:pointer;-webkit-appearance:none;font-size:28px;font-weight:700;line-height:20px;color:#000;opacity:.5}.boxzilla-close-icon:focus,.boxzilla-close-icon:hover{opacity:.8}\";\n module.exports = styles;\n }, {}], 6: [function (require, module, exports) {\n 'use strict';\n\n var Timer = function Timer(start) {\n this.time = start;\n this.interval = 0;\n };\n\n Timer.prototype.tick = function () {\n this.time++;\n };\n\n Timer.prototype.start = function () {\n if (!this.interval) {\n this.interval = window.setInterval(this.tick.bind(this), 1000);\n }\n };\n\n Timer.prototype.stop = function () {\n if (this.interval) {\n window.clearInterval(this.interval);\n this.interval = 0;\n }\n };\n\n module.exports = Timer;\n }, {}], 7: [function (require, module, exports) {\n /*!\n * EventEmitter v4.2.11 - git.io/ee\n * Unlicense - http://unlicense.org/\n * Oliver Caldwell - http://oli.me.uk/\n * @preserve\n */\n\n ;(function () {\n 'use strict';\n\n /**\n * Class for managing events.\n * Can be extended to provide event functionality in other classes.\n *\n * @class EventEmitter Manages event registering and emitting.\n */\n\n function EventEmitter() {}\n\n // Shortcuts to improve speed and size\n var proto = EventEmitter.prototype;\n var exports = this;\n var originalGlobalValue = exports.EventEmitter;\n\n /**\n * Finds the index of the listener for the event in its storage array.\n *\n * @param {Function[]} listeners Array of listeners to search through.\n * @param {Function} listener Method to look for.\n * @return {Number} Index of the specified listener, -1 if not found\n * @api private\n */\n function indexOfListener(listeners, listener) {\n var i = listeners.length;\n while (i--) {\n if (listeners[i].listener === listener) {\n return i;\n }\n }\n\n return -1;\n }\n\n /**\n * Alias a method while keeping the context correct, to allow for overwriting of target method.\n *\n * @param {String} name The name of the target method.\n * @return {Function} The aliased method\n * @api private\n */\n function alias(name) {\n return function aliasClosure() {\n return this[name].apply(this, arguments);\n };\n }\n\n /**\n * Returns the listener array for the specified event.\n * Will initialise the event object and listener arrays if required.\n * Will return an object if you use a regex search. The object contains keys for each matched event. So /ba[rz]/ might return an object containing bar and baz. But only if you have either defined them with defineEvent or added some listeners to them.\n * Each property in the object response is an array of listener functions.\n *\n * @param {String|RegExp} evt Name of the event to return the listeners from.\n * @return {Function[]|Object} All listener functions for the event.\n */\n proto.getListeners = function getListeners(evt) {\n var events = this._getEvents();\n var response;\n var key;\n\n // Return a concatenated array of all matching events if\n // the selector is a regular expression.\n if (evt instanceof RegExp) {\n response = {};\n for (key in events) {\n if (events.hasOwnProperty(key) && evt.test(key)) {\n response[key] = events[key];\n }\n }\n } else {\n response = events[evt] || (events[evt] = []);\n }\n\n return response;\n };\n\n /**\n * Takes a list of listener objects and flattens it into a list of listener functions.\n *\n * @param {Object[]} listeners Raw listener objects.\n * @return {Function[]} Just the listener functions.\n */\n proto.flattenListeners = function flattenListeners(listeners) {\n var flatListeners = [];\n var i;\n\n for (i = 0; i < listeners.length; i += 1) {\n flatListeners.push(listeners[i].listener);\n }\n\n return flatListeners;\n };\n\n /**\n * Fetches the requested listeners via getListeners but will always return the results inside an object. This is mainly for internal use but others may find it useful.\n *\n * @param {String|RegExp} evt Name of the event to return the listeners from.\n * @return {Object} All listener functions for an event in an object.\n */\n proto.getListenersAsObject = function getListenersAsObject(evt) {\n var listeners = this.getListeners(evt);\n var response;\n\n if (listeners instanceof Array) {\n response = {};\n response[evt] = listeners;\n }\n\n return response || listeners;\n };\n\n /**\n * Adds a listener function to the specified event.\n * The listener will not be added if it is a duplicate.\n * If the listener returns true then it will be removed after it is called.\n * If you pass a regular expression as the event name then the listener will be added to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to attach the listener to.\n * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addListener = function addListener(evt, listener) {\n var listeners = this.getListenersAsObject(evt);\n var listenerIsWrapped = (typeof listener === \"undefined\" ? \"undefined\" : _typeof(listener)) === 'object';\n var key;\n\n for (key in listeners) {\n if (listeners.hasOwnProperty(key) && indexOfListener(listeners[key], listener) === -1) {\n listeners[key].push(listenerIsWrapped ? listener : {\n listener: listener,\n once: false\n });\n }\n }\n\n return this;\n };\n\n /**\n * Alias of addListener\n */\n proto.on = alias('addListener');\n\n /**\n * Semi-alias of addListener. It will add a listener that will be\n * automatically removed after its first execution.\n *\n * @param {String|RegExp} evt Name of the event to attach the listener to.\n * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addOnceListener = function addOnceListener(evt, listener) {\n return this.addListener(evt, {\n listener: listener,\n once: true\n });\n };\n\n /**\n * Alias of addOnceListener.\n */\n proto.once = alias('addOnceListener');\n\n /**\n * Defines an event name. This is required if you want to use a regex to add a listener to multiple events at once. If you don't do this then how do you expect it to know what event to add to? Should it just add to every possible match for a regex? No. That is scary and bad.\n * You need to tell it what event names should be matched by a regex.\n *\n * @param {String} evt Name of the event to create.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.defineEvent = function defineEvent(evt) {\n this.getListeners(evt);\n return this;\n };\n\n /**\n * Uses defineEvent to define multiple events.\n *\n * @param {String[]} evts An array of event names to define.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.defineEvents = function defineEvents(evts) {\n for (var i = 0; i < evts.length; i += 1) {\n this.defineEvent(evts[i]);\n }\n return this;\n };\n\n /**\n * Removes a listener function from the specified event.\n * When passed a regular expression as the event name, it will remove the listener from all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to remove the listener from.\n * @param {Function} listener Method to remove from the event.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeListener = function removeListener(evt, listener) {\n var listeners = this.getListenersAsObject(evt);\n var index;\n var key;\n\n for (key in listeners) {\n if (listeners.hasOwnProperty(key)) {\n index = indexOfListener(listeners[key], listener);\n\n if (index !== -1) {\n listeners[key].splice(index, 1);\n }\n }\n }\n\n return this;\n };\n\n /**\n * Alias of removeListener\n */\n proto.off = alias('removeListener');\n\n /**\n * Adds listeners in bulk using the manipulateListeners method.\n * If you pass an object as the second argument you can add to multiple events at once. The object should contain key value pairs of events and listeners or listener arrays. You can also pass it an event name and an array of listeners to be added.\n * You can also pass it a regular expression to add the array of listeners to all events that match it.\n * Yeah, this function does quite a bit. That's probably a bad thing.\n *\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add to multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to add.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addListeners = function addListeners(evt, listeners) {\n // Pass through to manipulateListeners\n return this.manipulateListeners(false, evt, listeners);\n };\n\n /**\n * Removes listeners in bulk using the manipulateListeners method.\n * If you pass an object as the second argument you can remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.\n * You can also pass it an event name and an array of listeners to be removed.\n * You can also pass it a regular expression to remove the listeners from all events that match it.\n *\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to remove from multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to remove.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeListeners = function removeListeners(evt, listeners) {\n // Pass through to manipulateListeners\n return this.manipulateListeners(true, evt, listeners);\n };\n\n /**\n * Edits listeners in bulk. The addListeners and removeListeners methods both use this to do their job. You should really use those instead, this is a little lower level.\n * The first argument will determine if the listeners are removed (true) or added (false).\n * If you pass an object as the second argument you can add/remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.\n * You can also pass it an event name and an array of listeners to be added/removed.\n * You can also pass it a regular expression to manipulate the listeners of all events that match it.\n *\n * @param {Boolean} remove True if you want to remove listeners, false if you want to add.\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add/remove from multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to add/remove.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.manipulateListeners = function manipulateListeners(remove, evt, listeners) {\n var i;\n var value;\n var single = remove ? this.removeListener : this.addListener;\n var multiple = remove ? this.removeListeners : this.addListeners;\n\n // If evt is an object then pass each of its properties to this method\n if ((typeof evt === \"undefined\" ? \"undefined\" : _typeof(evt)) === 'object' && !(evt instanceof RegExp)) {\n for (i in evt) {\n if (evt.hasOwnProperty(i) && (value = evt[i])) {\n // Pass the single listener straight through to the singular method\n if (typeof value === 'function') {\n single.call(this, i, value);\n } else {\n // Otherwise pass back to the multiple function\n multiple.call(this, i, value);\n }\n }\n }\n } else {\n // So evt must be a string\n // And listeners must be an array of listeners\n // Loop over it and pass each one to the multiple method\n i = listeners.length;\n while (i--) {\n single.call(this, evt, listeners[i]);\n }\n }\n\n return this;\n };\n\n /**\n * Removes all listeners from a specified event.\n * If you do not specify an event then all listeners will be removed.\n * That means every event will be emptied.\n * You can also pass a regex to remove all events that match it.\n *\n * @param {String|RegExp} [evt] Optional name of the event to remove all listeners for. Will remove from every event if not passed.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeEvent = function removeEvent(evt) {\n var type = typeof evt === \"undefined\" ? \"undefined\" : _typeof(evt);\n var events = this._getEvents();\n var key;\n\n // Remove different things depending on the state of evt\n if (type === 'string') {\n // Remove all listeners for the specified event\n delete events[evt];\n } else if (evt instanceof RegExp) {\n // Remove all events matching the regex.\n for (key in events) {\n if (events.hasOwnProperty(key) && evt.test(key)) {\n delete events[key];\n }\n }\n } else {\n // Remove all listeners in all events\n delete this._events;\n }\n\n return this;\n };\n\n /**\n * Alias of removeEvent.\n *\n * Added to mirror the node API.\n */\n proto.removeAllListeners = alias('removeEvent');\n\n /**\n * Emits an event of your choice.\n * When emitted, every listener attached to that event will be executed.\n * If you pass the optional argument array then those arguments will be passed to every listener upon execution.\n * Because it uses `apply`, your array of arguments will be passed as if you wrote them out separately.\n * So they will not arrive within the array on the other side, they will be separate.\n * You can also pass a regular expression to emit to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to emit and execute listeners for.\n * @param {Array} [args] Optional array of arguments to be passed to each listener.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.emitEvent = function emitEvent(evt, args) {\n var listenersMap = this.getListenersAsObject(evt);\n var listeners;\n var listener;\n var i;\n var key;\n var response;\n\n for (key in listenersMap) {\n if (listenersMap.hasOwnProperty(key)) {\n listeners = listenersMap[key].slice(0);\n i = listeners.length;\n\n while (i--) {\n // If the listener returns true then it shall be removed from the event\n // The function is executed either with a basic call or an apply if there is an args array\n listener = listeners[i];\n\n if (listener.once === true) {\n this.removeListener(evt, listener.listener);\n }\n\n response = listener.listener.apply(this, args || []);\n\n if (response === this._getOnceReturnValue()) {\n this.removeListener(evt, listener.listener);\n }\n }\n }\n }\n\n return this;\n };\n\n /**\n * Alias of emitEvent\n */\n proto.trigger = alias('emitEvent');\n\n /**\n * Subtly different from emitEvent in that it will pass its arguments on to the listeners, as opposed to taking a single array of arguments to pass on.\n * As with emitEvent, you can pass a regex in place of the event name to emit to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to emit and execute listeners for.\n * @param {...*} Optional additional arguments to be passed to each listener.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.emit = function emit(evt) {\n var args = Array.prototype.slice.call(arguments, 1);\n return this.emitEvent(evt, args);\n };\n\n /**\n * Sets the current value to check against when executing listeners. If a\n * listeners return value matches the one set here then it will be removed\n * after execution. This value defaults to true.\n *\n * @param {*} value The new value to check for when executing listeners.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.setOnceReturnValue = function setOnceReturnValue(value) {\n this._onceReturnValue = value;\n return this;\n };\n\n /**\n * Fetches the current value to check against when executing listeners. If\n * the listeners return value matches this one then it should be removed\n * automatically. It will return true by default.\n *\n * @return {*|Boolean} The current value to check for or the default, true.\n * @api private\n */\n proto._getOnceReturnValue = function _getOnceReturnValue() {\n if (this.hasOwnProperty('_onceReturnValue')) {\n return this._onceReturnValue;\n } else {\n return true;\n }\n };\n\n /**\n * Fetches the events object and creates one if required.\n *\n * @return {Object} The events storage object.\n * @api private\n */\n proto._getEvents = function _getEvents() {\n return this._events || (this._events = {});\n };\n\n /**\n * Reverts the global {@link EventEmitter} to its previous value and returns a reference to this version.\n *\n * @return {Function} Non conflicting EventEmitter class.\n */\n EventEmitter.noConflict = function noConflict() {\n exports.EventEmitter = originalGlobalValue;\n return EventEmitter;\n };\n\n // Expose the class either via AMD, CommonJS or the global object\n if (typeof define === 'function' && define.amd) {\n define(function () {\n return EventEmitter;\n });\n } else if ((typeof module === \"undefined\" ? \"undefined\" : _typeof(module)) === 'object' && module.exports) {\n module.exports = EventEmitter;\n } else {\n exports.EventEmitter = EventEmitter;\n }\n }).call(this);\n }, {}] }, {}, [1]);\n ;\n})();"],"sourceRoot":"/source/"}
1
+ {"version":3,"sources":["script.js"],"names":["_typeof","Symbol","iterator","obj","constructor","require","undefined","define","e","t","n","r","s","o","u","a","i","f","Error","code","l","exports","call","length","1","module","css","element","styles","background_color","style","background","color","border_color","borderColor","border_width","borderWidth","parseInt","border_style","borderStyle","width","maxWidth","Boxzilla","options","window","boxzilla_options","isLoggedIn","document","body","className","indexOf","testMode","console","log","init","boxes","boxOpts","location","origin","substring","content","replace","box","create","id","firstChild","lastChild","addEventListener","mc4wp_forms_config","submitted_form","selector","element_id","boxId","hasOwnProperty","querySelector","show","boxzilla","2","property","initObjectProperties","properties","value","newObject","copyObjectProperties","object","animated","getAttribute","toggle","animation","nowVisible","display","offsetLeft","clone","cloneNode","cleanup","removeAttribute","setAttribute","hiddenStyles","visibleStyles","computedStyles","getComputedStyle","overflowY","animate","opacity","targetStyles","fn","last","Date","initialStyles","currentStyles","propSteps","parseFloat","to","current","duration","tick","step","increment","newValue","now","timeSinceLastTick","done","suffix","requestAnimationFrame","setTimeout","3","merge","obj1","obj2","obj3","attrname","getDocumentHeight","html","documentElement","height","Math","max","scrollHeight","offsetHeight","clientHeight","defaults","rehide","cookie","icon","minimumScreenWidth","position","trigger","closable","Animator","Box","config","this","overlay","getElementById","visible","dismissed","triggered","triggerHeight","cookieSet","closeIcon","method","calculateTriggerHeight","isCookieSet","dom","events","prototype","dismiss","bind","target","tagName","setCookie","needle","hash","fits","locationHashRefersBox","wrapper","createElement","appendChild","innerHTML","scripts","querySelectorAll","script","createTextNode","text","parentNode","removeChild","setCustomBoxStyling","origDisplay","maxHeight","windowHeight","innerHeight","boxHeight","newTopMargin","marginTop","firstInput","focus","hide","triggerElement","offset","getBoundingClientRect","top","elementId","innerWidth","mayAutoShow","mayRehide","RegExp","hours","expiryDate","setHours","getHours","toUTCString","shown","preventDefault","_Boxzilla","./animator.js","4","throttle","threshhold","scope","deferTimer","context","args","arguments","clearTimeout","apply","onKeyUp","keyCode","checkPageViewsCriteria","isAnyBoxVisible","forEach","pageViews","checkTimeCriteria","siteTimer","time","pageTimer","checkHeightCriteria","scrollY","pageYOffset","recalculateHeights","onOverlayClick","x","offsetX","y","offsetY","rect","margin","left","right","bottom","triggerExitIntent","exitIntentTriggered","onMouseLeave","delay","clientY","exitIntentDelayTimer","onMouseEnter","clearInterval","EventEmitter","Object","Timer","timers","start","sessionTime","sessionStorage","getItem","stop","setItem","styleElement","head","setInterval","opts","push","get","./box.js","./styles.js","./timer.js","wolfy87-eventemitter","5","6","interval","7","indexOfListener","listeners","listener","alias","name","proto","originalGlobalValue","getListeners","evt","response","key","_getEvents","test","flattenListeners","flatListeners","getListenersAsObject","Array","addListener","listenerIsWrapped","once","on","addOnceListener","defineEvent","defineEvents","evts","removeListener","index","splice","off","addListeners","manipulateListeners","removeListeners","remove","single","multiple","removeEvent","type","_events","removeAllListeners","emitEvent","listenersMap","slice","_getOnceReturnValue","emit","setOnceReturnValue","_onceReturnValue","noConflict","amd"],"mappings":"AAAA,YAEA,IAAIA,SAA4B,kBAAXC,SAAoD,gBAApBA,QAAOC,SAAwB,SAAUC,GAAO,aAAcA,IAAS,SAAUA,GAAO,MAAOA,IAAyB,kBAAXF,SAAyBE,EAAIC,cAAgBH,OAAS,eAAkBE,KAE1O,WACI,GAAIE,GAAUC,OAA6DC,EAASD,QAAU,QAAUE,GAAEC,EAAGC,EAAGC,GAC5G,QAASC,GAAEC,EAAGC,GACV,IAAKJ,EAAEG,GAAI,CACP,IAAKJ,EAAEI,GAAI,CACP,GAAIE,GAAsB,kBAAXV,IAAyBA,CAAQ,KAAKS,GAAKC,EAAG,MAAOA,GAAEF,GAAG,EAAI,IAAIG,EAAG,MAAOA,GAAEH,GAAG,EAAI,IAAII,GAAI,GAAIC,OAAM,uBAAyBL,EAAI,IAAK,MAAMI,GAAEE,KAAO,mBAAoBF,EAC9L,GAAIG,GAAIV,EAAEG,IAAOQ,WAAcZ,GAAEI,GAAG,GAAGS,KAAKF,EAAEC,QAAS,S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AC9FI,EAAOJ,QAAU4O,EAEjB5O,EAAQ4O,aAAeA,IAE5B3O,KAAKiI,gBACG","file":"script.min.js","sourcesContent":["\"use strict\";\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol ? \"symbol\" : typeof obj; };\n\n(function () {\n var require = undefined;var module = undefined;var exports = undefined;var define = undefined;(function e(t, n, r) {\n function s(o, u) {\n if (!n[o]) {\n if (!t[o]) {\n var a = typeof require == \"function\" && require;if (!u && a) return a(o, !0);if (i) return i(o, !0);var f = new Error(\"Cannot find module '\" + o + \"'\");throw f.code = \"MODULE_NOT_FOUND\", f;\n }var l = n[o] = { exports: {} };t[o][0].call(l.exports, function (e) {\n var n = t[o][1][e];return s(n ? n : e);\n }, l, l.exports, e, t, n, r);\n }return n[o].exports;\n }var i = typeof require == \"function\" && require;for (var o = 0; o < r.length; o++) {\n s(r[o]);\n }return s;\n })({ 1: [function (require, module, exports) {\n 'use strict';\n\n var Boxzilla = require('boxzilla');\n var options = window.boxzilla_options;\n var isLoggedIn = document.body.className.indexOf('logged-in') > -1;\n\n // print message when test mode is enabled\n if (isLoggedIn && options.testMode) {\n console.log('Boxzilla: Test mode is enabled. Please disable test mode if you\\'re done testing.');\n }\n\n // init boxzilla\n Boxzilla.init();\n\n // create boxes from options\n for (var i = 0; i < options.boxes.length; i++) {\n // get opts\n var boxOpts = options.boxes[i];\n boxOpts.testMode = isLoggedIn && options.testMode;\n\n // fix http:// links in box content....\n if (window.location.origin.substring(0, 5) === \"https\") {\n boxOpts.content = boxOpts.content.replace(window.location.origin.replace(\"https\", \"http\"), window.location.origin);\n }\n\n // create box\n var box = Boxzilla.create(boxOpts.id, boxOpts);\n\n // add custom css to box\n css(box.element, boxOpts.css);\n\n box.element.firstChild.firstChild.className += \" first-child\";\n box.element.firstChild.lastChild.className += \" last-child\";\n }\n\n // helper function for setting CSS styles\n function css(element, styles) {\n if (styles.background_color) {\n element.style.background = styles.background_color;\n }\n\n if (styles.color) {\n element.style.color = styles.color;\n }\n\n if (styles.border_color) {\n element.style.borderColor = styles.border_color;\n }\n\n if (styles.border_width) {\n element.style.borderWidth = parseInt(styles.border_width) + \"px\";\n }\n\n if (styles.border_style) {\n element.style.borderStyle = styles.border_style;\n }\n\n if (styles.width) {\n element.style.maxWidth = parseInt(styles.width) + \"px\";\n }\n }\n\n /**\n * If a MailChimp for WordPress form was submitted, open the box containing that form (if any)\n *\n * TODO: Just set location hash from MailChimp for WP?\n */\n window.addEventListener('load', function () {\n if (_typeof(window.mc4wp_forms_config) === \"object\" && window.mc4wp_forms_config.submitted_form) {\n var selector = '#' + window.mc4wp_forms_config.submitted_form.element_id;\n var boxes = Boxzilla.boxes;\n for (var boxId in boxes) {\n if (!boxes.hasOwnProperty(boxId)) {\n continue;\n }\n var box = boxes[boxId];\n if (box.element.querySelector(selector)) {\n box.show();\n return;\n }\n }\n }\n });\n\n window.Boxzilla = Boxzilla;\n }, { \"boxzilla\": 4 }], 2: [function (require, module, exports) {\n var duration = 320;\n\n function css(element, styles) {\n for (var property in styles) {\n element.style[property] = styles[property];\n }\n }\n\n function initObjectProperties(properties, value) {\n var newObject = {};\n for (var i = 0; i < properties.length; i++) {\n newObject[properties[i]] = value;\n }\n return newObject;\n }\n\n function copyObjectProperties(properties, object) {\n var newObject = {};\n for (var i = 0; i < properties.length; i++) {\n newObject[properties[i]] = object[properties[i]];\n }\n return newObject;\n }\n\n /**\n * Checks if the given element is currently being animated.\n *\n * @param element\n * @returns {boolean}\n */\n function animated(element) {\n return !!element.getAttribute('data-animated');\n }\n\n /**\n * Toggles the element using the given animation.\n *\n * @param element\n * @param animation Either \"fade\" or \"slide\"\n */\n function toggle(element, animation) {\n var nowVisible = element.style.display != 'none' || element.offsetLeft > 0;\n\n // create clone for reference\n var clone = element.cloneNode(true);\n var cleanup = function cleanup() {\n element.removeAttribute('data-animated');\n element.setAttribute('style', clone.getAttribute('style'));\n element.style.display = nowVisible ? 'none' : '';\n };\n\n // store attribute so everyone knows we're animating this element\n element.setAttribute('data-animated', \"true\");\n\n // toggle element visiblity right away if we're making something visible\n if (!nowVisible) {\n element.style.display = '';\n }\n\n var hiddenStyles, visibleStyles;\n\n // animate properties\n if (animation === 'slide') {\n hiddenStyles = initObjectProperties([\"height\", \"borderTopWidth\", \"borderBottomWidth\", \"paddingTop\", \"paddingBottom\"], 0);\n visibleStyles = {};\n\n if (!nowVisible) {\n var computedStyles = window.getComputedStyle(element);\n visibleStyles = copyObjectProperties([\"height\", \"borderTopWidth\", \"borderBottomWidth\", \"paddingTop\", \"paddingBottom\"], computedStyles);\n css(element, hiddenStyles);\n }\n\n // don't show a scrollbar during animation\n element.style.overflowY = 'hidden';\n animate(element, nowVisible ? hiddenStyles : visibleStyles, cleanup);\n } else {\n hiddenStyles = { opacity: 0 };\n visibleStyles = { opacity: 1 };\n if (!nowVisible) {\n css(element, hiddenStyles);\n }\n\n animate(element, nowVisible ? hiddenStyles : visibleStyles, cleanup);\n }\n }\n\n function animate(element, targetStyles, fn) {\n var last = +new Date();\n var initialStyles = window.getComputedStyle(element);\n var currentStyles = {};\n var propSteps = {};\n\n for (var property in targetStyles) {\n // make sure we have an object filled with floats\n targetStyles[property] = parseFloat(targetStyles[property]);\n\n // calculate step size & current value\n var to = targetStyles[property];\n var current = parseFloat(initialStyles[property]);\n\n // is there something to do?\n if (current == to) {\n delete targetStyles[property];\n continue;\n }\n\n propSteps[property] = (to - current) / duration; // points per second\n currentStyles[property] = current;\n }\n\n var tick = function tick() {\n var now = +new Date();\n var timeSinceLastTick = now - last;\n var done = true;\n\n var step, to, increment, newValue;\n for (var property in targetStyles) {\n step = propSteps[property];\n to = targetStyles[property];\n increment = step * timeSinceLastTick;\n newValue = currentStyles[property] + increment;\n\n if (step > 0 && newValue >= to || step < 0 && newValue <= to) {\n newValue = to;\n } else {\n done = false;\n }\n\n // store new value\n currentStyles[property] = newValue;\n\n var suffix = property !== \"opacity\" ? \"px\" : \"\";\n element.style[property] = newValue + suffix;\n }\n\n last = +new Date();\n\n // keep going until we're done for all props\n if (!done) {\n window.requestAnimationFrame && requestAnimationFrame(tick) || setTimeout(tick, 32);\n } else {\n // call callback\n fn && fn();\n }\n };\n\n tick();\n }\n\n module.exports = {\n 'toggle': toggle,\n 'animate': animate,\n 'animated': animated\n };\n }, {}], 3: [function (require, module, exports) {\n 'use strict';\n\n var defaults = {\n 'animation': 'fade',\n 'rehide': false,\n 'content': '',\n 'cookie': null,\n 'icon': '&times',\n 'minimumScreenWidth': 0,\n 'position': 'center',\n 'testMode': false,\n 'trigger': false,\n 'closable': true\n },\n Boxzilla,\n Animator = require('./animator.js');\n\n /**\n * Merge 2 objects, values of the latter overwriting the former.\n *\n * @param obj1\n * @param obj2\n * @returns {*}\n */\n function merge(obj1, obj2) {\n var obj3 = {};\n for (var attrname in obj1) {\n obj3[attrname] = obj1[attrname];\n }\n for (var attrname in obj2) {\n obj3[attrname] = obj2[attrname];\n }\n return obj3;\n }\n\n /**\n * Get the real height of entire document.\n * @returns {number}\n */\n function getDocumentHeight() {\n var body = document.body,\n html = document.documentElement;\n\n var height = Math.max(body.scrollHeight, body.offsetHeight, html.clientHeight, html.scrollHeight, html.offsetHeight);\n\n return height;\n }\n\n // Box Object\n var Box = function Box(id, config) {\n this.id = id;\n\n // store config values\n this.config = merge(defaults, config);\n\n // store ref to overlay\n this.overlay = document.getElementById('boxzilla-overlay');\n\n // state\n this.visible = false;\n this.dismissed = false;\n this.triggered = false;\n this.triggerHeight = 0;\n this.cookieSet = false;\n this.element = null;\n this.closeIcon = null;\n\n // if a trigger was given, calculate values once and store\n if (this.config.trigger) {\n if (this.config.trigger.method === 'percentage' || this.config.trigger.method === 'element') {\n this.triggerHeight = this.calculateTriggerHeight();\n }\n\n this.cookieSet = this.isCookieSet();\n }\n\n // create dom elements for this box\n this.dom();\n\n // further initialise the box\n this.events();\n };\n\n // initialise the box\n Box.prototype.events = function () {\n var box = this;\n\n // attach event to \"close\" icon inside box\n this.closeIcon && this.closeIcon.addEventListener('click', box.dismiss.bind(this));\n\n this.element.addEventListener('click', function (e) {\n if (e.target.tagName === 'A') {\n Boxzilla.trigger('box.interactions.link', [box, e.target]);\n }\n }, false);\n\n this.element.addEventListener('submit', function (e) {\n box.setCookie();\n Boxzilla.trigger('box.interactions.form', [box, e.target]);\n }, false);\n\n window.addEventListener(\"hashchange\", function () {\n var needle = \"#boxzilla-\" + box.id;\n if (location.hash === needle) {\n box.toggle();\n }\n });\n\n // maybe show box right away\n if (this.fits() && this.locationHashRefersBox()) {\n window.addEventListener('load', this.show.bind(this));\n }\n };\n\n // generate dom elements for this box\n Box.prototype.dom = function () {\n var wrapper = document.createElement('div');\n wrapper.className = 'boxzilla-container boxzilla-' + this.config.position + '-container';\n\n var box = document.createElement('div');\n box.setAttribute('id', 'boxzilla-' + this.id);\n box.className = 'boxzilla boxzilla-' + this.id + ' boxzilla-' + this.config.position;\n box.style.display = 'none';\n wrapper.appendChild(box);\n\n var content = document.createElement('div');\n content.className = 'boxzilla-content';\n content.innerHTML = this.config.content;\n box.appendChild(content);\n\n // remove <script> from box content and append them to the document body\n var scripts = content.querySelectorAll('script');\n if (scripts.length) {\n var script = document.createElement('script');\n for (var i = 0; i < scripts.length; i++) {\n script.appendChild(document.createTextNode(scripts[i].text));\n scripts[i].parentNode.removeChild(scripts[i]);\n }\n document.body.appendChild(script);\n }\n\n if (this.config.closable && this.config.icon) {\n var closeIcon = document.createElement('span');\n closeIcon.className = \"boxzilla-close-icon\";\n closeIcon.innerHTML = this.config.icon;\n box.appendChild(closeIcon);\n this.closeIcon = closeIcon;\n }\n\n document.body.appendChild(wrapper);\n this.element = box;\n };\n\n // set (calculate) custom box styling depending on box options\n Box.prototype.setCustomBoxStyling = function () {\n\n // reset element to its initial state\n var origDisplay = this.element.style.display;\n this.element.style.display = '';\n this.element.style.overflowY = 'auto';\n this.element.style.maxHeight = 'none';\n\n // get new dimensions\n var windowHeight = window.innerHeight;\n var boxHeight = this.element.clientHeight;\n\n // add scrollbar to box and limit height\n if (boxHeight > windowHeight) {\n this.element.style.maxHeight = windowHeight + \"px\";\n this.element.style.overflowY = 'scroll';\n }\n\n // set new top margin for boxes which are centered\n if (this.config.position === 'center') {\n var newTopMargin = (windowHeight - boxHeight) / 2;\n newTopMargin = newTopMargin >= 0 ? newTopMargin : 0;\n this.element.style.marginTop = newTopMargin + \"px\";\n }\n\n this.element.style.display = origDisplay;\n };\n\n // toggle visibility of the box\n Box.prototype.toggle = function (show) {\n\n // revert visibility if no explicit argument is given\n if (typeof show === \"undefined\") {\n show = !this.visible;\n }\n\n // is box already at desired visibility?\n if (show === this.visible) {\n return false;\n }\n\n // is box being animated?\n if (Animator.animated(this.element)) {\n return false;\n }\n\n // if box should be hidden but is not closable, bail.\n if (!show && !this.config.closable) {\n return false;\n }\n\n // set new visibility status\n this.visible = show;\n\n // calculate new styling rules\n this.setCustomBoxStyling();\n\n // trigger event\n Boxzilla.trigger('box.' + (show ? 'show' : 'hide'), [this]);\n\n // show or hide box using selected animation\n if (this.config.position === 'center') {\n Animator.toggle(this.overlay, \"fade\");\n }\n\n Animator.toggle(this.element, this.config.animation);\n\n // focus on first input field in box\n var firstInput = this.element.querySelector('input, textarea');\n if (firstInput) {\n firstInput.focus();\n }\n\n return true;\n };\n\n // show the box\n Box.prototype.show = function () {\n return this.toggle(true);\n };\n\n // hide the box\n Box.prototype.hide = function () {\n return this.toggle(false);\n };\n\n // calculate trigger height\n Box.prototype.calculateTriggerHeight = function () {\n var triggerHeight = 0;\n\n if (this.config.trigger.method === 'element') {\n var triggerElement = document.body.querySelector(this.config.trigger.value);\n if (triggerElement) {\n var offset = triggerElement.getBoundingClientRect();\n triggerHeight = offset.top;\n }\n } else if (this.config.trigger.method === 'percentage') {\n triggerHeight = this.config.trigger.value / 100 * getDocumentHeight();\n }\n\n return triggerHeight;\n };\n\n // checks whether window.location.hash equals the box element ID or that of any element inside the box\n Box.prototype.locationHashRefersBox = function () {\n\n if (!window.location.hash || 0 === window.location.hash.length) {\n return false;\n }\n\n var elementId = window.location.hash.substring(1);\n if (elementId === this.element.id) {\n return true;\n } else if (this.element.querySelector('#' + elementId)) {\n return true;\n }\n\n return false;\n };\n\n Box.prototype.fits = function () {\n if (this.config.minimumScreenWidth <= 0) {\n return true;\n }\n\n return window.innerWidth > this.config.minimumScreenWidth;\n };\n\n // is this box enabled?\n Box.prototype.mayAutoShow = function () {\n\n if (this.dismissed) {\n return false;\n }\n\n // check if box fits on given minimum screen width\n if (!this.fits()) {\n return false;\n }\n\n // if trigger empty or error in calculating triggerHeight, return false\n if (!this.config.trigger) {\n return false;\n }\n\n // rely on cookie value (show if not set, don't show if set)\n return !this.cookieSet;\n };\n\n Box.prototype.mayRehide = function () {\n return this.config.rehide && this.triggered;\n };\n\n Box.prototype.isCookieSet = function () {\n // always show on test mode\n if (this.config.testMode) {\n return false;\n }\n\n // if either cookie is null or trigger & dismiss are both falsey, don't bother checking.\n if (!this.config.cookie || !this.config.cookie.triggered && !this.config.cookie.dismissed) {\n return false;\n }\n\n var cookieSet = document.cookie.replace(new RegExp(\"(?:(?:^|.*;)\\\\s*\" + 'boxzilla_box_' + this.id + \"\\\\s*\\\\=\\\\s*([^;]*).*$)|^.*$\"), \"$1\") === \"true\";\n return cookieSet;\n };\n\n // set cookie that disables automatically showing the box\n Box.prototype.setCookie = function (hours) {\n var expiryDate = new Date();\n expiryDate.setHours(expiryDate.getHours() + hours);\n document.cookie = 'boxzilla_box_' + this.id + '=true; expires=' + expiryDate.toUTCString() + '; path=/';\n };\n\n Box.prototype.trigger = function () {\n var shown = this.show();\n if (!shown) {\n return;\n }\n\n this.triggered = true;\n if (this.config.cookie && this.config.cookie.triggered) {\n this.setCookie(this.config.cookie.triggered);\n }\n };\n\n /**\n * Dismisses the box and optionally sets a cookie.\n *\n * @param e The event that triggered this dismissal.\n * @returns {boolean}\n */\n Box.prototype.dismiss = function (e) {\n // prevent default action\n e && e.preventDefault();\n\n // only dismiss box if it's currently open.\n if (!this.visible) {\n return false;\n }\n\n // hide box element\n this.hide();\n\n // set cookie\n if (this.config.cookie && this.config.cookie.dismissed) {\n this.setCookie(this.config.cookie.dismissed);\n }\n\n this.dismissed = true;\n Boxzilla.trigger('box.dismiss', [this]);\n return true;\n };\n\n module.exports = function (_Boxzilla) {\n Boxzilla = _Boxzilla;\n return Box;\n };\n }, { \"./animator.js\": 2 }], 4: [function (require, module, exports) {\n 'use strict';\n\n var EventEmitter = require('wolfy87-eventemitter'),\n Boxzilla = Object.create(EventEmitter.prototype),\n Box = require('./box.js')(Boxzilla),\n Timer = require('./timer.js'),\n boxes = [],\n overlay,\n exitIntentDelayTimer,\n exitIntentTriggered,\n siteTimer,\n pageTimer,\n pageViews;\n\n function throttle(fn, threshhold, scope) {\n threshhold || (threshhold = 250);\n var last, deferTimer;\n return function () {\n var context = scope || this;\n\n var now = +new Date(),\n args = arguments;\n if (last && now < last + threshhold) {\n // hold on to it\n clearTimeout(deferTimer);\n deferTimer = setTimeout(function () {\n last = now;\n fn.apply(context, args);\n }, threshhold);\n } else {\n last = now;\n fn.apply(context, args);\n }\n };\n }\n\n // \"keyup\" listener\n function onKeyUp(e) {\n if (e.keyCode == 27) {\n Boxzilla.dismiss();\n }\n }\n\n // check \"pageviews\" criteria for each box\n function checkPageViewsCriteria() {\n\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (!box.mayAutoShow()) {\n return;\n }\n\n if (box.config.trigger.method === 'pageviews' && pageViews >= box.config.trigger.value) {\n box.trigger();\n }\n });\n }\n\n // check time trigger criteria for each box\n function checkTimeCriteria() {\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (!box.mayAutoShow()) {\n return;\n }\n\n // check \"time on site\" trigger\n if (box.config.trigger.method === 'time_on_site' && siteTimer.time >= box.config.trigger.value) {\n box.trigger();\n }\n\n // check \"time on page\" trigger\n if (box.config.trigger.method === 'time_on_page' && pageTimer.time >= box.config.trigger.value) {\n box.trigger();\n }\n });\n }\n\n // check triggerHeight criteria for all boxes\n function checkHeightCriteria() {\n var scrollY = (window.scrollY || window.pageYOffset) + window.innerHeight * 0.75;\n\n boxes.forEach(function (box) {\n\n if (!box.mayAutoShow() || box.triggerHeight <= 0) {\n return;\n }\n\n if (scrollY > box.triggerHeight) {\n // don't bother if another box is currently open\n if (isAnyBoxVisible()) {\n return;\n }\n\n // trigger box\n box.trigger();\n } else if (box.mayRehide()) {\n box.hide();\n }\n });\n }\n\n // recalculate heights and variables based on height\n function recalculateHeights() {\n boxes.forEach(function (box) {\n box.setCustomBoxStyling();\n });\n }\n\n function onOverlayClick(e) {\n var x = e.offsetX;\n var y = e.offsetY;\n\n // calculate if click was near a box to avoid closing it (click error margin)\n boxes.forEach(function (box) {\n var rect = box.element.getBoundingClientRect();\n var margin = 100 + window.innerWidth * 0.05;\n\n // if click was not anywhere near box, dismiss it.\n if (x < rect.left - margin || x > rect.right + margin || y < rect.top - margin || y > rect.bottom + margin) {\n box.dismiss();\n }\n });\n }\n\n function triggerExitIntent() {\n // do nothing if already triggered OR another box is visible.\n if (exitIntentTriggered || isAnyBoxVisible()) {\n return;\n }\n\n boxes.forEach(function (box) {\n if (box.mayAutoShow() && box.config.trigger.method === 'exit_intent') {\n box.trigger();\n }\n });\n\n exitIntentTriggered = true;\n }\n\n function onMouseLeave(e) {\n var delay = 400;\n\n // did mouse leave at top of window?\n if (e.clientY <= 0) {\n exitIntentDelayTimer = window.setTimeout(triggerExitIntent, delay);\n }\n }\n\n function isAnyBoxVisible() {\n\n for (var i = 0; i < boxes.length; i++) {\n var box = boxes[i];\n\n if (box.visible) {\n return true;\n }\n }\n\n return false;\n }\n\n function onMouseEnter() {\n if (exitIntentDelayTimer) {\n window.clearInterval(exitIntentDelayTimer);\n exitIntentDelayTimer = null;\n }\n }\n\n var timers = {\n start: function start() {\n var sessionTime = sessionStorage.getItem('boxzilla_timer');\n if (sessionTime) siteTimer.time = sessionTime;\n siteTimer.start();\n pageTimer.start();\n },\n stop: function stop() {\n sessionStorage.setItem('boxzilla_timer', siteTimer.time);\n siteTimer.stop();\n pageTimer.stop();\n }\n };\n\n // initialise & add event listeners\n Boxzilla.init = function () {\n siteTimer = new Timer(sessionStorage.getItem('boxzilla_timer') || 0);\n pageTimer = new Timer(0);\n pageViews = sessionStorage.getItem('boxzilla_pageviews') || 0;\n\n // insert styles into DOM\n var styles = require('./styles.js');\n var styleElement = document.createElement('style');\n styleElement.setAttribute(\"type\", \"text/css\");\n styleElement.innerHTML = styles;\n document.head.appendChild(styleElement);\n\n // add overlay element to dom\n overlay = document.createElement('div');\n overlay.style.display = 'none';\n overlay.id = 'boxzilla-overlay';\n document.body.appendChild(overlay);\n\n // event binds\n window.addEventListener('scroll', throttle(checkHeightCriteria));\n window.addEventListener('resize', throttle(recalculateHeights));\n window.addEventListener('load', recalculateHeights);\n overlay.addEventListener('click', onOverlayClick);\n window.setInterval(checkTimeCriteria, 1000);\n window.setTimeout(checkPageViewsCriteria, 1000);\n document.documentElement.addEventListener('mouseleave', onMouseLeave);\n document.documentElement.addEventListener('mouseenter', onMouseEnter);\n document.addEventListener('keyup', onKeyUp);\n\n timers.start();\n window.addEventListener('focus', timers.start);\n window.addEventListener('beforeunload', function () {\n timers.stop();\n sessionStorage.setItem('boxzilla_pageviews', ++pageViews);\n });\n window.addEventListener('blur', timers.stop);\n\n Boxzilla.trigger('ready');\n };\n\n /**\n * Create a new Box\n *\n * @param string id\n * @param object opts\n *\n * @returns Box\n */\n Boxzilla.create = function (id, opts) {\n var box = new Box(id, opts);\n boxes.push(box);\n return box;\n };\n\n Boxzilla.get = function (id) {\n for (var i = 0; i < boxes.length; i++) {\n var box = boxes[i];\n if (box.id == id) {\n return box;\n }\n }\n\n throw new Error(\"No box exists with ID \" + id);\n };\n\n // dismiss a single box (or all by omitting id param)\n Boxzilla.dismiss = function (id) {\n // if no id given, dismiss all current open boxes\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.dismiss();\n });\n } else if (_typeof(boxes[id]) === \"object\") {\n Boxzilla.get(id).dismiss();\n }\n };\n\n Boxzilla.hide = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.hide();\n });\n } else {\n Boxzilla.get(id).hide();\n }\n };\n\n Boxzilla.show = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.show();\n });\n } else {\n Boxzilla.get(id).show();\n }\n };\n\n Boxzilla.toggle = function (id) {\n if (typeof id === \"undefined\") {\n boxes.forEach(function (box) {\n box.toggle();\n });\n } else {\n Boxzilla.get(id).toggle();\n }\n };\n\n // expose each individual box.\n Boxzilla.boxes = boxes;\n\n window.Boxzilla = Boxzilla;\n\n if (typeof module !== 'undefined' && module.exports) {\n module.exports = Boxzilla;\n }\n }, { \"./box.js\": 3, \"./styles.js\": 5, \"./timer.js\": 6, \"wolfy87-eventemitter\": 7 }], 5: [function (require, module, exports) {\n var styles = \"#boxzilla-overlay{position:fixed;background:rgba(0,0,0,.65);width:100%;height:100%;left:0;top:0;z-index:99999}.boxzilla-center-container{position:fixed;top:0;left:0;right:0;height:0;text-align:center;z-index:999999;line-height:0}.boxzilla-center-container .boxzilla{display:inline-block;text-align:left;position:relative;line-height:normal}.boxzilla{position:fixed;z-index:999999;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;background:#fff;padding:25px}.boxzilla.boxzilla-top-left{top:0;left:0}.boxzilla.boxzilla-top-right{top:0;right:0}.boxzilla.boxzilla-bottom-left{bottom:0;left:0}.boxzilla.boxzilla-bottom-right{bottom:0;right:0}.boxzilla-content>:first-child{margin-top:0;padding-top:0}.boxzilla-content>:last-child{margin-bottom:0;padding-bottom:0}.boxzilla-close-icon{position:absolute;right:0;top:0;text-align:center;padding:6px;cursor:pointer;-webkit-appearance:none;font-size:28px;font-weight:700;line-height:20px;color:#000;opacity:.5}.boxzilla-close-icon:focus,.boxzilla-close-icon:hover{opacity:.8}\";\n module.exports = styles;\n }, {}], 6: [function (require, module, exports) {\n 'use strict';\n\n var Timer = function Timer(start) {\n this.time = start;\n this.interval = 0;\n };\n\n Timer.prototype.tick = function () {\n this.time++;\n };\n\n Timer.prototype.start = function () {\n if (!this.interval) {\n this.interval = window.setInterval(this.tick.bind(this), 1000);\n }\n };\n\n Timer.prototype.stop = function () {\n if (this.interval) {\n window.clearInterval(this.interval);\n this.interval = 0;\n }\n };\n\n module.exports = Timer;\n }, {}], 7: [function (require, module, exports) {\n /*!\n * EventEmitter v4.2.11 - git.io/ee\n * Unlicense - http://unlicense.org/\n * Oliver Caldwell - http://oli.me.uk/\n * @preserve\n */\n\n ;(function () {\n 'use strict';\n\n /**\n * Class for managing events.\n * Can be extended to provide event functionality in other classes.\n *\n * @class EventEmitter Manages event registering and emitting.\n */\n\n function EventEmitter() {}\n\n // Shortcuts to improve speed and size\n var proto = EventEmitter.prototype;\n var exports = this;\n var originalGlobalValue = exports.EventEmitter;\n\n /**\n * Finds the index of the listener for the event in its storage array.\n *\n * @param {Function[]} listeners Array of listeners to search through.\n * @param {Function} listener Method to look for.\n * @return {Number} Index of the specified listener, -1 if not found\n * @api private\n */\n function indexOfListener(listeners, listener) {\n var i = listeners.length;\n while (i--) {\n if (listeners[i].listener === listener) {\n return i;\n }\n }\n\n return -1;\n }\n\n /**\n * Alias a method while keeping the context correct, to allow for overwriting of target method.\n *\n * @param {String} name The name of the target method.\n * @return {Function} The aliased method\n * @api private\n */\n function alias(name) {\n return function aliasClosure() {\n return this[name].apply(this, arguments);\n };\n }\n\n /**\n * Returns the listener array for the specified event.\n * Will initialise the event object and listener arrays if required.\n * Will return an object if you use a regex search. The object contains keys for each matched event. So /ba[rz]/ might return an object containing bar and baz. But only if you have either defined them with defineEvent or added some listeners to them.\n * Each property in the object response is an array of listener functions.\n *\n * @param {String|RegExp} evt Name of the event to return the listeners from.\n * @return {Function[]|Object} All listener functions for the event.\n */\n proto.getListeners = function getListeners(evt) {\n var events = this._getEvents();\n var response;\n var key;\n\n // Return a concatenated array of all matching events if\n // the selector is a regular expression.\n if (evt instanceof RegExp) {\n response = {};\n for (key in events) {\n if (events.hasOwnProperty(key) && evt.test(key)) {\n response[key] = events[key];\n }\n }\n } else {\n response = events[evt] || (events[evt] = []);\n }\n\n return response;\n };\n\n /**\n * Takes a list of listener objects and flattens it into a list of listener functions.\n *\n * @param {Object[]} listeners Raw listener objects.\n * @return {Function[]} Just the listener functions.\n */\n proto.flattenListeners = function flattenListeners(listeners) {\n var flatListeners = [];\n var i;\n\n for (i = 0; i < listeners.length; i += 1) {\n flatListeners.push(listeners[i].listener);\n }\n\n return flatListeners;\n };\n\n /**\n * Fetches the requested listeners via getListeners but will always return the results inside an object. This is mainly for internal use but others may find it useful.\n *\n * @param {String|RegExp} evt Name of the event to return the listeners from.\n * @return {Object} All listener functions for an event in an object.\n */\n proto.getListenersAsObject = function getListenersAsObject(evt) {\n var listeners = this.getListeners(evt);\n var response;\n\n if (listeners instanceof Array) {\n response = {};\n response[evt] = listeners;\n }\n\n return response || listeners;\n };\n\n /**\n * Adds a listener function to the specified event.\n * The listener will not be added if it is a duplicate.\n * If the listener returns true then it will be removed after it is called.\n * If you pass a regular expression as the event name then the listener will be added to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to attach the listener to.\n * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addListener = function addListener(evt, listener) {\n var listeners = this.getListenersAsObject(evt);\n var listenerIsWrapped = (typeof listener === \"undefined\" ? \"undefined\" : _typeof(listener)) === 'object';\n var key;\n\n for (key in listeners) {\n if (listeners.hasOwnProperty(key) && indexOfListener(listeners[key], listener) === -1) {\n listeners[key].push(listenerIsWrapped ? listener : {\n listener: listener,\n once: false\n });\n }\n }\n\n return this;\n };\n\n /**\n * Alias of addListener\n */\n proto.on = alias('addListener');\n\n /**\n * Semi-alias of addListener. It will add a listener that will be\n * automatically removed after its first execution.\n *\n * @param {String|RegExp} evt Name of the event to attach the listener to.\n * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addOnceListener = function addOnceListener(evt, listener) {\n return this.addListener(evt, {\n listener: listener,\n once: true\n });\n };\n\n /**\n * Alias of addOnceListener.\n */\n proto.once = alias('addOnceListener');\n\n /**\n * Defines an event name. This is required if you want to use a regex to add a listener to multiple events at once. If you don't do this then how do you expect it to know what event to add to? Should it just add to every possible match for a regex? No. That is scary and bad.\n * You need to tell it what event names should be matched by a regex.\n *\n * @param {String} evt Name of the event to create.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.defineEvent = function defineEvent(evt) {\n this.getListeners(evt);\n return this;\n };\n\n /**\n * Uses defineEvent to define multiple events.\n *\n * @param {String[]} evts An array of event names to define.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.defineEvents = function defineEvents(evts) {\n for (var i = 0; i < evts.length; i += 1) {\n this.defineEvent(evts[i]);\n }\n return this;\n };\n\n /**\n * Removes a listener function from the specified event.\n * When passed a regular expression as the event name, it will remove the listener from all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to remove the listener from.\n * @param {Function} listener Method to remove from the event.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeListener = function removeListener(evt, listener) {\n var listeners = this.getListenersAsObject(evt);\n var index;\n var key;\n\n for (key in listeners) {\n if (listeners.hasOwnProperty(key)) {\n index = indexOfListener(listeners[key], listener);\n\n if (index !== -1) {\n listeners[key].splice(index, 1);\n }\n }\n }\n\n return this;\n };\n\n /**\n * Alias of removeListener\n */\n proto.off = alias('removeListener');\n\n /**\n * Adds listeners in bulk using the manipulateListeners method.\n * If you pass an object as the second argument you can add to multiple events at once. The object should contain key value pairs of events and listeners or listener arrays. You can also pass it an event name and an array of listeners to be added.\n * You can also pass it a regular expression to add the array of listeners to all events that match it.\n * Yeah, this function does quite a bit. That's probably a bad thing.\n *\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add to multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to add.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.addListeners = function addListeners(evt, listeners) {\n // Pass through to manipulateListeners\n return this.manipulateListeners(false, evt, listeners);\n };\n\n /**\n * Removes listeners in bulk using the manipulateListeners method.\n * If you pass an object as the second argument you can remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.\n * You can also pass it an event name and an array of listeners to be removed.\n * You can also pass it a regular expression to remove the listeners from all events that match it.\n *\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to remove from multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to remove.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeListeners = function removeListeners(evt, listeners) {\n // Pass through to manipulateListeners\n return this.manipulateListeners(true, evt, listeners);\n };\n\n /**\n * Edits listeners in bulk. The addListeners and removeListeners methods both use this to do their job. You should really use those instead, this is a little lower level.\n * The first argument will determine if the listeners are removed (true) or added (false).\n * If you pass an object as the second argument you can add/remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.\n * You can also pass it an event name and an array of listeners to be added/removed.\n * You can also pass it a regular expression to manipulate the listeners of all events that match it.\n *\n * @param {Boolean} remove True if you want to remove listeners, false if you want to add.\n * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add/remove from multiple events at once.\n * @param {Function[]} [listeners] An optional array of listener functions to add/remove.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.manipulateListeners = function manipulateListeners(remove, evt, listeners) {\n var i;\n var value;\n var single = remove ? this.removeListener : this.addListener;\n var multiple = remove ? this.removeListeners : this.addListeners;\n\n // If evt is an object then pass each of its properties to this method\n if ((typeof evt === \"undefined\" ? \"undefined\" : _typeof(evt)) === 'object' && !(evt instanceof RegExp)) {\n for (i in evt) {\n if (evt.hasOwnProperty(i) && (value = evt[i])) {\n // Pass the single listener straight through to the singular method\n if (typeof value === 'function') {\n single.call(this, i, value);\n } else {\n // Otherwise pass back to the multiple function\n multiple.call(this, i, value);\n }\n }\n }\n } else {\n // So evt must be a string\n // And listeners must be an array of listeners\n // Loop over it and pass each one to the multiple method\n i = listeners.length;\n while (i--) {\n single.call(this, evt, listeners[i]);\n }\n }\n\n return this;\n };\n\n /**\n * Removes all listeners from a specified event.\n * If you do not specify an event then all listeners will be removed.\n * That means every event will be emptied.\n * You can also pass a regex to remove all events that match it.\n *\n * @param {String|RegExp} [evt] Optional name of the event to remove all listeners for. Will remove from every event if not passed.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.removeEvent = function removeEvent(evt) {\n var type = typeof evt === \"undefined\" ? \"undefined\" : _typeof(evt);\n var events = this._getEvents();\n var key;\n\n // Remove different things depending on the state of evt\n if (type === 'string') {\n // Remove all listeners for the specified event\n delete events[evt];\n } else if (evt instanceof RegExp) {\n // Remove all events matching the regex.\n for (key in events) {\n if (events.hasOwnProperty(key) && evt.test(key)) {\n delete events[key];\n }\n }\n } else {\n // Remove all listeners in all events\n delete this._events;\n }\n\n return this;\n };\n\n /**\n * Alias of removeEvent.\n *\n * Added to mirror the node API.\n */\n proto.removeAllListeners = alias('removeEvent');\n\n /**\n * Emits an event of your choice.\n * When emitted, every listener attached to that event will be executed.\n * If you pass the optional argument array then those arguments will be passed to every listener upon execution.\n * Because it uses `apply`, your array of arguments will be passed as if you wrote them out separately.\n * So they will not arrive within the array on the other side, they will be separate.\n * You can also pass a regular expression to emit to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to emit and execute listeners for.\n * @param {Array} [args] Optional array of arguments to be passed to each listener.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.emitEvent = function emitEvent(evt, args) {\n var listenersMap = this.getListenersAsObject(evt);\n var listeners;\n var listener;\n var i;\n var key;\n var response;\n\n for (key in listenersMap) {\n if (listenersMap.hasOwnProperty(key)) {\n listeners = listenersMap[key].slice(0);\n i = listeners.length;\n\n while (i--) {\n // If the listener returns true then it shall be removed from the event\n // The function is executed either with a basic call or an apply if there is an args array\n listener = listeners[i];\n\n if (listener.once === true) {\n this.removeListener(evt, listener.listener);\n }\n\n response = listener.listener.apply(this, args || []);\n\n if (response === this._getOnceReturnValue()) {\n this.removeListener(evt, listener.listener);\n }\n }\n }\n }\n\n return this;\n };\n\n /**\n * Alias of emitEvent\n */\n proto.trigger = alias('emitEvent');\n\n /**\n * Subtly different from emitEvent in that it will pass its arguments on to the listeners, as opposed to taking a single array of arguments to pass on.\n * As with emitEvent, you can pass a regex in place of the event name to emit to all events that match it.\n *\n * @param {String|RegExp} evt Name of the event to emit and execute listeners for.\n * @param {...*} Optional additional arguments to be passed to each listener.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.emit = function emit(evt) {\n var args = Array.prototype.slice.call(arguments, 1);\n return this.emitEvent(evt, args);\n };\n\n /**\n * Sets the current value to check against when executing listeners. If a\n * listeners return value matches the one set here then it will be removed\n * after execution. This value defaults to true.\n *\n * @param {*} value The new value to check for when executing listeners.\n * @return {Object} Current instance of EventEmitter for chaining.\n */\n proto.setOnceReturnValue = function setOnceReturnValue(value) {\n this._onceReturnValue = value;\n return this;\n };\n\n /**\n * Fetches the current value to check against when executing listeners. If\n * the listeners return value matches this one then it should be removed\n * automatically. It will return true by default.\n *\n * @return {*|Boolean} The current value to check for or the default, true.\n * @api private\n */\n proto._getOnceReturnValue = function _getOnceReturnValue() {\n if (this.hasOwnProperty('_onceReturnValue')) {\n return this._onceReturnValue;\n } else {\n return true;\n }\n };\n\n /**\n * Fetches the events object and creates one if required.\n *\n * @return {Object} The events storage object.\n * @api private\n */\n proto._getEvents = function _getEvents() {\n return this._events || (this._events = {});\n };\n\n /**\n * Reverts the global {@link EventEmitter} to its previous value and returns a reference to this version.\n *\n * @return {Function} Non conflicting EventEmitter class.\n */\n EventEmitter.noConflict = function noConflict() {\n exports.EventEmitter = originalGlobalValue;\n return EventEmitter;\n };\n\n // Expose the class either via AMD, CommonJS or the global object\n if (typeof define === 'function' && define.amd) {\n define(function () {\n return EventEmitter;\n });\n } else if ((typeof module === \"undefined\" ? \"undefined\" : _typeof(module)) === 'object' && module.exports) {\n module.exports = EventEmitter;\n } else {\n exports.EventEmitter = EventEmitter;\n }\n }).call(this);\n }, {}] }, {}, [1]);\n ;\n})();"],"sourceRoot":"/source/"}
boxzilla.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /*
3
  Plugin Name: Boxzilla
4
- Version: 3.1.4
5
  Plugin URI: https://boxzillaplugin.com/#utm_source=wp-plugin&utm_medium=boxzilla&utm_campaign=plugins-page
6
  Description: Call-To-Action Boxes that display after visitors scroll down far enough. Unobtrusive, but highly conversing!
7
  Author: ibericode
@@ -41,7 +41,7 @@ if ( ! defined( 'ABSPATH' ) ) {
41
  function __load_boxzilla() {
42
 
43
  define( 'BOXZILLA_FILE', __FILE__ );
44
- define( 'BOXZILLA_VERSION', '3.1.4' );
45
 
46
  require __DIR__ . '/bootstrap.php';
47
  }
1
  <?php
2
  /*
3
  Plugin Name: Boxzilla
4
+ Version: 3.1.5
5
  Plugin URI: https://boxzillaplugin.com/#utm_source=wp-plugin&utm_medium=boxzilla&utm_campaign=plugins-page
6
  Description: Call-To-Action Boxes that display after visitors scroll down far enough. Unobtrusive, but highly conversing!
7
  Author: ibericode
41
  function __load_boxzilla() {
42
 
43
  define( 'BOXZILLA_FILE', __FILE__ );
44
+ define( 'BOXZILLA_VERSION', '3.1.5' );
45
 
46
  require __DIR__ . '/bootstrap.php';
47
  }
languages/boxzilla.pot CHANGED
@@ -17,55 +17,55 @@ msgstr ""
17
  msgid "Awesome, you are using Boxzilla! You can now safely <a href=\"%s\">deactivate the Scroll Triggered Boxes plugin</a>."
18
  msgstr ""
19
 
20
- #: src/admin/class-admin.php:285
21
  msgid "Box ID"
22
  msgstr ""
23
 
24
- #: src/admin/class-admin.php:291
25
  msgid "Box Title"
26
  msgstr ""
27
 
28
- #: src/admin/class-admin.php:359, src/admin/class-admin.php:361, src/admin/views/settings.php:7
29
  msgid "Settings"
30
  msgstr ""
31
 
32
- #: src/admin/class-admin.php:371, src/admin/class-admin.php:373
33
  msgid "Extensions"
34
  msgstr ""
35
 
36
- #: src/admin/class-admin.php:559
37
  msgid "Enter a comma-separated list of values."
38
  msgstr ""
39
 
40
- #: src/admin/class-admin.php:561
41
  msgid "Enter a comma-separated list of post slugs or post ID's.."
42
  msgstr ""
43
 
44
- #: src/admin/class-admin.php:563
45
  msgid "Enter a comma-separated list of page slugs or page ID's.."
46
  msgstr ""
47
 
48
- #: src/admin/class-admin.php:565
49
  msgid "Enter a comma-separated list of post types.."
50
  msgstr ""
51
 
52
- #: src/admin/class-admin.php:567
53
  msgid "Enter a comma-separated list of relative URL's, eg /contact/"
54
  msgstr ""
55
 
56
- #: src/admin/class-admin.php:633
57
  msgid "Box Appearance"
58
  msgstr ""
59
 
60
- #: src/admin/class-admin.php:651
61
  msgid "Box Options"
62
  msgstr ""
63
 
64
- #: src/admin/class-admin.php:669
65
  msgid "Looking for help?"
66
  msgstr ""
67
 
68
- #: src/admin/class-admin.php:685
69
  msgid "Subscribe to our newsletter"
70
  msgstr ""
71
 
17
  msgid "Awesome, you are using Boxzilla! You can now safely <a href=\"%s\">deactivate the Scroll Triggered Boxes plugin</a>."
18
  msgstr ""
19
 
20
+ #: src/admin/class-admin.php:277
21
  msgid "Box ID"
22
  msgstr ""
23
 
24
+ #: src/admin/class-admin.php:283
25
  msgid "Box Title"
26
  msgstr ""
27
 
28
+ #: src/admin/class-admin.php:351, src/admin/class-admin.php:353, src/admin/views/settings.php:7
29
  msgid "Settings"
30
  msgstr ""
31
 
32
+ #: src/admin/class-admin.php:363, src/admin/class-admin.php:365
33
  msgid "Extensions"
34
  msgstr ""
35
 
36
+ #: src/admin/class-admin.php:551
37
  msgid "Enter a comma-separated list of values."
38
  msgstr ""
39
 
40
+ #: src/admin/class-admin.php:553
41
  msgid "Enter a comma-separated list of post slugs or post ID's.."
42
  msgstr ""
43
 
44
+ #: src/admin/class-admin.php:555
45
  msgid "Enter a comma-separated list of page slugs or page ID's.."
46
  msgstr ""
47
 
48
+ #: src/admin/class-admin.php:557
49
  msgid "Enter a comma-separated list of post types.."
50
  msgstr ""
51
 
52
+ #: src/admin/class-admin.php:559
53
  msgid "Enter a comma-separated list of relative URL's, eg /contact/"
54
  msgstr ""
55
 
56
+ #: src/admin/class-admin.php:625
57
  msgid "Box Appearance"
58
  msgstr ""
59
 
60
+ #: src/admin/class-admin.php:643
61
  msgid "Box Options"
62
  msgstr ""
63
 
64
+ #: src/admin/class-admin.php:661
65
  msgid "Looking for help?"
66
  msgstr ""
67
 
68
+ #: src/admin/class-admin.php:677
69
  msgid "Subscribe to our newsletter"
70
  msgstr ""
71
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://boxzillaplugin.com/#utm_source=wp-plugin-repo&utm_medium=bo
4
  Tags: scroll triggered box, cta, social, pop-up, newsletter, call to action, mailchimp, contact form 7, social media, mc4wp, ibericode
5
  Requires at least: 3.8
6
  Tested up to: 4.6
7
- Stable tag: 3.1.4
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -149,6 +149,20 @@ Have a look at the [frequently asked questions](https://wordpress.org/plugins/bo
149
  == Changelog ==
150
 
151
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
152
  #### 3.1.4 - August 24, 2016
153
 
154
  **Fixes**
@@ -161,7 +175,7 @@ Have a look at the [frequently asked questions](https://wordpress.org/plugins/bo
161
  **Improvements**
162
 
163
  - Don't trigger any new boxes when a box is currently open.
164
- - Fail more gracefully when not running PHP 5.3 or higher.
165
 
166
 
167
  #### 3.1.2 - August 2, 2016
4
  Tags: scroll triggered box, cta, social, pop-up, newsletter, call to action, mailchimp, contact form 7, social media, mc4wp, ibericode
5
  Requires at least: 3.8
6
  Tested up to: 4.6
7
+ Stable tag: 3.1.5
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
149
  == Changelog ==
150
 
151
 
152
+
153
+ #### 3.1.5 - September 6, 2016
154
+
155
+ **Fixes**
156
+
157
+ - Box cookies were being set for _all_ boxes when dismissing a box using the overlay or ESCAPE key.
158
+ - Auto-close not working since version 3.1.3
159
+
160
+ **Improvements**
161
+
162
+ - Prevent default click event action when clicking close icon.
163
+ - Add helper classes for the [Boxzilla - Theme Pack add-on](https://boxzillaplugin.com/add-ons/theme-pack/).
164
+
165
+
166
  #### 3.1.4 - August 24, 2016
167
 
168
  **Fixes**
175
  **Improvements**
176
 
177
  - Don't trigger any new boxes when a box is currently open.
178
+ - Fail gracefully when not running PHP 5.3 or higher.
179
 
180
 
181
  #### 3.1.2 - August 2, 2016
src/admin/class-admin.php CHANGED
@@ -103,13 +103,9 @@ class Admin {
103
  add_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );
104
  add_filter( 'tiny_mce_before_init', array( $this, 'tinymce_init' ) );
105
  add_filter( 'manage_edit-boxzilla-box_columns', array( $this, 'post_type_column_titles' ) );
106
- add_action( 'manage_boxzilla-box_posts_custom_column', array(
107
- $this,
108
- 'post_type_column_content'
109
- ), 10, 2 );
110
  add_filter( 'admin_footer_text', array( $this, 'admin_footer_text' ) );
111
 
112
-
113
  if ( $pagenow === 'plugins.php' ) {
114
  add_filter( 'plugin_action_links', array( $this, 'add_plugin_settings_link' ), 10, 2 );
115
  add_filter( 'plugin_row_meta', array( $this, 'add_plugin_meta_links' ), 10, 2 );
103
  add_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );
104
  add_filter( 'tiny_mce_before_init', array( $this, 'tinymce_init' ) );
105
  add_filter( 'manage_edit-boxzilla-box_columns', array( $this, 'post_type_column_titles' ) );
106
+ add_action( 'manage_boxzilla-box_posts_custom_column', array( $this, 'post_type_column_content' ), 10, 2 );
 
 
 
107
  add_filter( 'admin_footer_text', array( $this, 'admin_footer_text' ) );
108
 
 
109
  if ( $pagenow === 'plugins.php' ) {
110
  add_filter( 'plugin_action_links', array( $this, 'add_plugin_settings_link' ), 10, 2 );
111
  add_filter( 'plugin_row_meta', array( $this, 'add_plugin_meta_links' ), 10, 2 );
src/class-bootstrapper.php CHANGED
@@ -66,10 +66,12 @@ class Bootstrapper {
66
  $section = $this->section();
67
  }
68
 
 
69
  foreach( $this->bootstrappers['global'] as $callback ) {
70
  $callback();
71
  }
72
 
 
73
  foreach( $this->bootstrappers[ $section ] as $callback ) {
74
  $callback();
75
  }
66
  $section = $this->section();
67
  }
68
 
69
+ // call all global callbacks
70
  foreach( $this->bootstrappers['global'] as $callback ) {
71
  $callback();
72
  }
73
 
74
+ // call section specific callbacks
75
  foreach( $this->bootstrappers[ $section ] as $callback ) {
76
  $callback();
77
  }
vendor/composer/autoload_classmap.php CHANGED
@@ -29,70 +29,4 @@ return array(
29
  'Boxzilla\\Licensing\\UpdateManager' => $baseDir . '/src/licensing/class-update-manager.php',
30
  'Boxzilla\\Plugin' => $baseDir . '/src/class-plugin.php',
31
  'Boxzilla_PHP_Fallback' => $baseDir . '/src/class-php-fallback.php',
32
- 'Composer\\Installers\\AglInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AglInstaller.php',
33
- 'Composer\\Installers\\AimeosInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AimeosInstaller.php',
34
- 'Composer\\Installers\\AnnotateCmsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php',
35
- 'Composer\\Installers\\AsgardInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AsgardInstaller.php',
36
- 'Composer\\Installers\\BaseInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BaseInstaller.php',
37
- 'Composer\\Installers\\BitrixInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BitrixInstaller.php',
38
- 'Composer\\Installers\\BonefishInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BonefishInstaller.php',
39
- 'Composer\\Installers\\CakePHPInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CakePHPInstaller.php',
40
- 'Composer\\Installers\\ChefInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ChefInstaller.php',
41
- 'Composer\\Installers\\ClanCatsFrameworkInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php',
42
- 'Composer\\Installers\\CodeIgniterInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php',
43
- 'Composer\\Installers\\Concrete5Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Concrete5Installer.php',
44
- 'Composer\\Installers\\CraftInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CraftInstaller.php',
45
- 'Composer\\Installers\\CroogoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CroogoInstaller.php',
46
- 'Composer\\Installers\\DecibelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DecibelInstaller.php',
47
- 'Composer\\Installers\\DokuWikiInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DokuWikiInstaller.php',
48
- 'Composer\\Installers\\DolibarrInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DolibarrInstaller.php',
49
- 'Composer\\Installers\\DrupalInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DrupalInstaller.php',
50
- 'Composer\\Installers\\ElggInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ElggInstaller.php',
51
- 'Composer\\Installers\\ExpressionEngineInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php',
52
- 'Composer\\Installers\\FuelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/FuelInstaller.php',
53
- 'Composer\\Installers\\FuelphpInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/FuelphpInstaller.php',
54
- 'Composer\\Installers\\GravInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/GravInstaller.php',
55
- 'Composer\\Installers\\HuradInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/HuradInstaller.php',
56
- 'Composer\\Installers\\ImageCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ImageCMSInstaller.php',
57
- 'Composer\\Installers\\Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Installer.php',
58
- 'Composer\\Installers\\JoomlaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/JoomlaInstaller.php',
59
- 'Composer\\Installers\\KirbyInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KirbyInstaller.php',
60
- 'Composer\\Installers\\KodiCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KodiCMSInstaller.php',
61
- 'Composer\\Installers\\KohanaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KohanaInstaller.php',
62
- 'Composer\\Installers\\LaravelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LaravelInstaller.php',
63
- 'Composer\\Installers\\LithiumInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LithiumInstaller.php',
64
- 'Composer\\Installers\\MODULEWorkInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php',
65
- 'Composer\\Installers\\MODXEvoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MODXEvoInstaller.php',
66
- 'Composer\\Installers\\MagentoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MagentoInstaller.php',
67
- 'Composer\\Installers\\MakoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MakoInstaller.php',
68
- 'Composer\\Installers\\MauticInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MauticInstaller.php',
69
- 'Composer\\Installers\\MediaWikiInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MediaWikiInstaller.php',
70
- 'Composer\\Installers\\MicroweberInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MicroweberInstaller.php',
71
- 'Composer\\Installers\\MoodleInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MoodleInstaller.php',
72
- 'Composer\\Installers\\OctoberInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OctoberInstaller.php',
73
- 'Composer\\Installers\\OxidInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OxidInstaller.php',
74
- 'Composer\\Installers\\PPIInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PPIInstaller.php',
75
- 'Composer\\Installers\\PhiftyInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PhiftyInstaller.php',
76
- 'Composer\\Installers\\PhpBBInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PhpBBInstaller.php',
77
- 'Composer\\Installers\\PimcoreInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PimcoreInstaller.php',
78
- 'Composer\\Installers\\PiwikInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PiwikInstaller.php',
79
- 'Composer\\Installers\\Plugin' => $vendorDir . '/composer/installers/src/Composer/Installers/Plugin.php',
80
- 'Composer\\Installers\\PrestashopInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PrestashopInstaller.php',
81
- 'Composer\\Installers\\PuppetInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PuppetInstaller.php',
82
- 'Composer\\Installers\\RadPHPInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RadPHPInstaller.php',
83
- 'Composer\\Installers\\RedaxoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RedaxoInstaller.php',
84
- 'Composer\\Installers\\RoundcubeInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RoundcubeInstaller.php',
85
- 'Composer\\Installers\\SMFInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SMFInstaller.php',
86
- 'Composer\\Installers\\ShopwareInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ShopwareInstaller.php',
87
- 'Composer\\Installers\\SilverStripeInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SilverStripeInstaller.php',
88
- 'Composer\\Installers\\Symfony1Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Symfony1Installer.php',
89
- 'Composer\\Installers\\TYPO3CmsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php',
90
- 'Composer\\Installers\\TYPO3FlowInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php',
91
- 'Composer\\Installers\\TheliaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TheliaInstaller.php',
92
- 'Composer\\Installers\\TuskInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TuskInstaller.php',
93
- 'Composer\\Installers\\WHMCSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WHMCSInstaller.php',
94
- 'Composer\\Installers\\WolfCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WolfCMSInstaller.php',
95
- 'Composer\\Installers\\WordPressInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WordPressInstaller.php',
96
- 'Composer\\Installers\\ZendInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ZendInstaller.php',
97
- 'Composer\\Installers\\ZikulaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ZikulaInstaller.php',
98
  );
29
  'Boxzilla\\Licensing\\UpdateManager' => $baseDir . '/src/licensing/class-update-manager.php',
30
  'Boxzilla\\Plugin' => $baseDir . '/src/class-plugin.php',
31
  'Boxzilla_PHP_Fallback' => $baseDir . '/src/class-php-fallback.php',
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
32
  );
vendor/composer/autoload_psr4.php CHANGED
@@ -6,5 +6,4 @@ $vendorDir = dirname(dirname(__FILE__));
6
  $baseDir = dirname($vendorDir);
7
 
8
  return array(
9
- 'Composer\\Installers\\' => array($vendorDir . '/composer/installers/src/Composer/Installers'),
10
  );
6
  $baseDir = dirname($vendorDir);
7
 
8
  return array(
 
9
  );
vendor/composer/installed.json CHANGED
@@ -1,106 +1 @@
1
- [
2
- {
3
- "name": "composer/installers",
4
- "version": "v1.1.0",
5
- "version_normalized": "1.1.0.0",
6
- "source": {
7
- "type": "git",
8
- "url": "https://github.com/composer/installers.git",
9
- "reference": "a3595c5272a6f247228abb20076ed27321e4aae9"
10
- },
11
- "dist": {
12
- "type": "zip",
13
- "url": "https://api.github.com/repos/composer/installers/zipball/a3595c5272a6f247228abb20076ed27321e4aae9",
14
- "reference": "a3595c5272a6f247228abb20076ed27321e4aae9",
15
- "shasum": ""
16
- },
17
- "require": {
18
- "composer-plugin-api": "^1.0"
19
- },
20
- "replace": {
21
- "roundcube/plugin-installer": "*",
22
- "shama/baton": "*"
23
- },
24
- "require-dev": {
25
- "composer/composer": "1.0.*@dev",
26
- "phpunit/phpunit": "4.1.*"
27
- },
28
- "time": "2016-07-05 06:18:20",
29
- "type": "composer-plugin",
30
- "extra": {
31
- "class": "Composer\\Installers\\Plugin",
32
- "branch-alias": {
33
- "dev-master": "1.0-dev"
34
- }
35
- },
36
- "installation-source": "dist",
37
- "autoload": {
38
- "psr-4": {
39
- "Composer\\Installers\\": "src/Composer/Installers"
40
- }
41
- },
42
- "notification-url": "https://packagist.org/downloads/",
43
- "license": [
44
- "MIT"
45
- ],
46
- "authors": [
47
- {
48
- "name": "Kyle Robinson Young",
49
- "email": "kyle@dontkry.com",
50
- "homepage": "https://github.com/shama"
51
- }
52
- ],
53
- "description": "A multi-framework Composer library installer",
54
- "homepage": "https://composer.github.io/installers/",
55
- "keywords": [
56
- "Craft",
57
- "Dolibarr",
58
- "Hurad",
59
- "ImageCMS",
60
- "MODX Evo",
61
- "Mautic",
62
- "OXID",
63
- "RadPHP",
64
- "SMF",
65
- "Thelia",
66
- "WolfCMS",
67
- "agl",
68
- "aimeos",
69
- "annotatecms",
70
- "bitrix",
71
- "cakephp",
72
- "chef",
73
- "codeigniter",
74
- "concrete5",
75
- "croogo",
76
- "dokuwiki",
77
- "drupal",
78
- "elgg",
79
- "expressionengine",
80
- "fuelphp",
81
- "grav",
82
- "installer",
83
- "joomla",
84
- "kohana",
85
- "laravel",
86
- "lithium",
87
- "magento",
88
- "mako",
89
- "mediawiki",
90
- "modulework",
91
- "moodle",
92
- "phpbb",
93
- "piwik",
94
- "ppi",
95
- "puppet",
96
- "roundcube",
97
- "shopware",
98
- "silverstripe",
99
- "symfony",
100
- "typo3",
101
- "wordpress",
102
- "zend",
103
- "zikula"
104
- ]
105
- }
106
- ]
1
+ []