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
7.4 KiB

define ("theme_ilb/bootstrap/collapse",["exports","jquery","./util"],function(a,b,c){"use strict";Object.defineProperty(a,"__esModule",{value:!0});a.default=void 0;b=d(b);c=d(c);function d(a){return a&&a.__esModule?a:{default:a}}function e(a){"@babel/helpers - typeof";if("function"==typeof Symbol&&"symbol"==typeof Symbol.iterator){e=function(a){return typeof a}}else{e=function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a}}return e(a)}function f(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 g(a){for(var b=1,c;b<arguments.length;b++){c=null!=arguments[b]?arguments[b]:{};if(b%2){f(Object(c),!0).forEach(function(b){h(a,b,c[b])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(a,Object.getOwnPropertyDescriptors(c))}else{f(Object(c)).forEach(function(b){Object.defineProperty(a,b,Object.getOwnPropertyDescriptor(c,b))})}}return a}function h(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.collapse",n=".".concat(m),o=b.default.fn.collapse,p={toggle:!0,parent:""},q={toggle:"boolean",parent:"(string|element)"},r="show".concat(n),s="shown".concat(n),t="hide".concat(n),u="hidden".concat(n),v="click".concat(n).concat(".data-api"),w="show",x="collapse",y="collapsing",z="collapsed",A="width",B="[data-toggle=\"collapse\"]",C=function(){function a(b,d){j(this,a);this._isTransitioning=!1;this._element=b;this._config=this._getConfig(d);this._triggerArray=[].slice.call(document.querySelectorAll("[data-toggle=\"collapse\"][href=\"#".concat(b.id,"\"],")+"[data-toggle=\"collapse\"][data-target=\"#".concat(b.id,"\"]")));for(var e=[].slice.call(document.querySelectorAll(B)),f=0,g=e.length;f<g;f++){var h=e[f],k=c.default.getSelectorFromElement(h),l=[].slice.call(document.querySelectorAll(k)).filter(function(a){return a===b});if(null!==k&&0<l.length){this._selector=k;this._triggerArray.push(h)}}this._parent=this._config.parent?this._getParent():null;if(!this._config.parent){this._addAriaAndCollapsedClass(this._element,this._triggerArray)}if(this._config.toggle){this.toggle()}}l(a,[{key:"toggle",value:function toggle(){if((0,b.default)(this._element).hasClass(w)){this.hide()}else{this.show()}}},{key:"show",value:function show(){var d=this;if(this._isTransitioning||(0,b.default)(this._element).hasClass(w)){return}var e,f;if(this._parent){e=[].slice.call(this._parent.querySelectorAll(".show, .collapsing")).filter(function(a){if("string"==typeof d._config.parent){return a.getAttribute("data-parent")===d._config.parent}return a.classList.contains(x)});if(0===e.length){e=null}}if(e){f=(0,b.default)(e).not(this._selector).data(m);if(f&&f._isTransitioning){return}}var g=b.default.Event(r);(0,b.default)(this._element).trigger(g);if(g.isDefaultPrevented()){return}if(e){a._jQueryInterface.call((0,b.default)(e).not(this._selector),"hide");if(!f){(0,b.default)(e).data(m,null)}}var h=this._getDimension();(0,b.default)(this._element).removeClass(x).addClass(y);this._element.style[h]=0;if(this._triggerArray.length){(0,b.default)(this._triggerArray).removeClass(z).attr("aria-expanded",!0)}this.setTransitioning(!0);var i=function(){(0,b.default)(d._element).removeClass(y).addClass("".concat(x," ").concat(w));d._element.style[h]="";d.setTransitioning(!1);(0,b.default)(d._element).trigger(s)},j=h[0].toUpperCase()+h.slice(1),k="scroll".concat(j),l=c.default.getTransitionDurationFromElement(this._element);(0,b.default)(this._element).one(c.default.TRANSITION_END,i).emulateTransitionEnd(l);this._element.style[h]="".concat(this._elemen
//# sourceMappingURL=collapse.min.js.map