!function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t(require("vue")):"function"===typeof define&&define.amd?define("$event",["vue"],t):"object"===typeof exports?exports.$event=t(require("vue")):e.$event=t(e.Vue)}("undefined"!==typeof self?self:this,(function(e){return function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(o,i,function(t){return e[t]}.bind(null,i));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s="XOpt")}({XOpt:function(e,t,n){"use strict";n.r(t),n.d(t,"useBus",(function(){return g}));var o=n("g8md");const i=/(?:^\[object\s(.*?)\]$)/;var r=e=>Object.prototype.toString.call(e).replace(i,"$1").toLowerCase();var u=function(){if("function"===typeof window.CustomEvent)return!1;window.CustomEvent=function(e,t){t=t||{bubbles:!1,cancelable:!1,detail:null};const n=document.createEvent("CustomEvent");return n.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),n}};var l=function(e,t,n){n=n||window;let o=!1;n.addEventListener(e,(function(){o||(o=!0,requestAnimationFrame((function(){n.dispatchEvent(new CustomEvent(t)),o=!1})))}))};var c=function(){u(),l("resize","balmResize"),l("scroll","balmScroll")},f=n("i7/w");const a=new(n.n(f).a);const s={on:function(e,t){a.$on(e,t)},once:function(e,t){a.$once(e,t)},off:function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];t?a.$off(e,t):a.$off(e)},emit:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];a.$emit(e,...n)}};var d=s;const p=()=>{};let v=!1;function h(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=e.shift(),i=n?n[o]:this[o];e.length?h.call(this,e,t,i):n?n[o]=t:this[o]=t}function b(e,t){"function"===r(new Function)?new Function("value","this.".concat(e," = value;")).call(this,t):h.call(this,e.split("."),t)}function y(e){let t,n=r(e);return t="function"===n||"generatorfunction"===n?e():e,t}const m={onChange(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:p;return b.call(this,e,t),y(n)},onOpen(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:p;return b.call(this,e,!0),y(t)},onClose(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:p;return b.call(this,e,!1),y(t)},onShow(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:p;return b.call(this,e,!0),y(t)},onHide(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:p;return b.call(this,e,!1),y(t)}},w={install(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"balmUI";if(!t)throw new Error("[$event]: The namespace of the event plugin is required");e.mixin({mounted(){v||(v=!0,c())}}),Object.defineProperty(e.prototype,"$".concat(t),{get(){let e={};return Object.keys(m).forEach((t=>{e[t]=m[t].bind(this)})),e}}),e.prototype.$bus=d,e.prototype.$throttle=l}},g=()=>d;Object(o.a)(w);t.default=w},Y0i2:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(o){"object"===typeof window&&(n=window)}e.exports=n},g8md:function(e,t,n){"use strict";(function(e){t.a=function(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default",o=null;"undefined"!==typeof window?o=window.Vue:"undefined"!==typeof e&&(o=e.Vue),o&&("directive"===n?o.directive(t.name,t):o.use(t))}}).call(this,n("Y0i2"))},"i7/w":function(t,n){t.exports=e}})}));