summaryrefslogtreecommitdiff
path: root/dist/LightBox.CloseButton.min.js
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--dist/LightBox.CloseButton.min.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/dist/LightBox.CloseButton.min.js b/dist/LightBox.CloseButton.min.js
new file mode 100644
index 0000000..e98e22c
--- /dev/null
+++ b/dist/LightBox.CloseButton.min.js
@@ -0,0 +1 @@
+var LightBox=LightBox||{};LightBox.CloseButton=function(t){function e(i){if(n[i])return n[i].exports;var o=n[i]={exports:{},id:i,loaded:!1};return t[i].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var i=function(){function t(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(e,n,i){return n&&t(e.prototype,n),i&&t(e,i),e}}();Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(){var e=arguments.length<=0||void 0===arguments[0]?!1:arguments[0];n(this,t),this.closeOnDocumentClick=e,this.element=document.createElement("a"),this.element.id="imagelightbox-close",this.element.innerHTML="Close"}return i(t,[{key:"register",value:function(t){this.lightbox=t,t.addOnStartListener(this.showButton.bind(this)),t.addOnEndListener(this.hideButton.bind(this))}},{key:"showButton",value:function(){var t=this;this.lightbox.options.quitOnDocClick=this.closeOnDocumentClick,["click","touchend"].forEach(function(e){t.element.addEventListener(e,t.exitLightbox.bind(t))}),document.body.appendChild(this.element)}},{key:"hideButton",value:function(){document.body.removeChild(this.element)}},{key:"exitLightbox",value:function(){this.lightbox.quitLightbox()}}]),t}();e["default"]=o,t.exports=e["default"]}]); \ No newline at end of file