You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
3 lines
9.1 KiB
3 lines
9.1 KiB
3 years ago
|
define ("theme_ilb/bootstrap/dropdown",["exports","jquery","core/popper","./util"],function(a,b,c,d){"use strict";Object.defineProperty(a,"__esModule",{value:!0});a.default=void 0;b=e(b);c=e(c);d=e(d);function e(a){return a&&a.__esModule?a:{default:a}}function f(a){"@babel/helpers - typeof";if("function"==typeof Symbol&&"symbol"==typeof Symbol.iterator){f=function(a){return typeof a}}else{f=function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a}}return f(a)}function g(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);if(b)d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable});c.push.apply(c,d)}return c}function h(a){for(var b=1,c;b<arguments.length;b++){c=null!=arguments[b]?arguments[b]:{};if(b%2){g(Object(c),!0).forEach(function(b){i(a,b,c[b])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(a,Object.getOwnPropertyDescriptors(c))}else{g(Object(c)).forEach(function(b){Object.defineProperty(a,b,Object.getOwnPropertyDescriptor(c,b))})}}return a}function i(a,b,c){if(b in a){Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0})}else{a[b]=c}return a}function j(a,b){if(!(a instanceof b)){throw new TypeError("Cannot call a class as a function")}}function k(a,b){for(var c=0,d;c<b.length;c++){d=b[c];d.enumerable=d.enumerable||!1;d.configurable=!0;if("value"in d)d.writable=!0;Object.defineProperty(a,d.key,d)}}function l(a,b,c){if(b)k(a.prototype,b);if(c)k(a,c);return a}var m="bs.dropdown",n=".".concat(m),o=".data-api",p=b.default.fn.dropdown,q=27,r=32,s=9,t=38,u=40,v=new RegExp("".concat(t,"|").concat(u,"|").concat(q)),w="hide".concat(n),x="hidden".concat(n),y="show".concat(n),z="shown".concat(n),A="click".concat(n),B="click".concat(n).concat(o),C="keydown".concat(n).concat(o),D="keyup".concat(n).concat(o),E="disabled",F="show",G="dropdown-menu-right",H="[data-toggle=\"dropdown\"]",I=".dropdown-menu",J={offset:0,flip:!0,boundary:"scrollParent",reference:"toggle",display:"dynamic",popperConfig:null},K={offset:"(number|string|function)",flip:"boolean",boundary:"(string|element)",reference:"(string|element)",display:"string",popperConfig:"(null|object)"},L=function(){function a(b,c){j(this,a);this._element=b;this._popper=null;this._config=this._getConfig(c);this._menu=this._getMenuElement();this._inNavbar=this._detectNavbar();this._addEventListeners()}l(a,[{key:"toggle",value:function toggle(){if(this._element.disabled||(0,b.default)(this._element).hasClass(E)){return}var c=(0,b.default)(this._menu).hasClass(F);a._clearMenus();if(c){return}this.show(!0)}},{key:"show",value:function show(){var e=0<arguments.length&&arguments[0]!==void 0?arguments[0]:!1;if(this._element.disabled||(0,b.default)(this._element).hasClass(E)||(0,b.default)(this._menu).hasClass(F)){return}var f={relatedTarget:this._element},g=b.default.Event(y,f),h=a._getParentFromElement(this._element);(0,b.default)(h).trigger(g);if(g.isDefaultPrevented()){return}if(!this._inNavbar&&e){if("undefined"==typeof c.default){throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)")}var i=this._element;if("parent"===this._config.reference){i=h}else if(d.default.isElement(this._config.reference)){i=this._config.reference;if("undefined"!=typeof this._config.reference.jquery){i=this._config.reference[0]}}if("scrollParent"!==this._config.boundary){(0,b.default)(h).addClass("position-static")}this._popper=new c.default(i,this._menu,this._getPopperConfig())}if("ontouchstart"in document.documentElement&&0===(0,b.default)(h).closest(".navbar-nav").length){(0,b.default)(document.body).children().on("mouseover",null,b.default.noop)}this._element.focus();this._element.setAttribute("aria-expanded",!0);(0,b.default)(this._menu).toggleClass(F);(0,b.default)(h).toggleClass(F).trigger(b.default.Event(z,f))}},{key:"hide",value:function hide(){if(this._element.disabled||(0,b.default)(this._element).hasClass(E)||!(0,b.default)(this._menu).hasClass(F)){return}var c={relatedTarget:this._element},d=b.defau
|
||
|
//# sourceMappingURL=dropdown.min.js.map
|