- md5
- 2e0a70b1bb18173dde0d112cb2867174
- sha1
- 9bcd1549c5a99b6e6fef20813b1977758dc1d6ac
- sha256
- be762654e1b5653d002ef33f48e0d5f6c5f3c755bc207aca609eddd4ad8a3fc4
import{B as BaseComponent,g as getElementFromSelector,E as EventHandler,a as getTransitionDurationFromElement,T as TRANSITION_END,e as emulateTransitionEnd,D as Data,o as onDOMContentLoaded,b as getjQuery}from"./dom-8eef6b5f.js";const NAME="alert",DATA_KEY="bs.alert",EVENT_KEY=".bs.alert",DATA_API_KEY=".data-api",SELECTOR_DISMISS='[data-bs-dismiss="alert"]',EVENT_CLOSE="close.bs.alert",EVENT_CLOSED="closed.bs.alert",EVENT_CLICK_DATA_API="click.bs.alert.data-api",CLASSNAME_ALERT="alert",CLASSNAME_FADE="fade",CLASSNAME_SHOW="show";class Alert extends BaseComponent{static get DATA_KEY(){return DATA_KEY}close(e){const t=e?this._getRootElement(e):this._element,r=this._triggerCloseEvent(t);null===r||r.defaultPrevented||this._removeElement(t)}_getRootElement(e){return getElementFromSelector(e)||e.closest(".alert")}_triggerCloseEvent(e){return EventHandler.trigger(e,EVENT_CLOSE)}_removeElement(e){if(e.classList.remove("show"),!e.classList.contains("fade"))return void this._destroyElement(e);const t=getTransitionDurationFromElement(e);EventHandler.one(e,TRANSITION_END,(()=>this._destroyElement(e))),emulateTransitionEnd(e,t)}_destroyElement(e){e.parentNode&&e.parentNode.removeChild(e),EventHandler.trigger(e,EVENT_CLOSED)}static jQueryInterface(e){return this.each((function(){let t=Data.getData(this,DATA_KEY);t||(t=new Alert(this)),"close"===e&&t[e](this)}))}static handleDismiss(e){return function(t){t&&t.preventDefault(),e.close(this)}}}if(EventHandler.on(document,EVENT_CLICK_DATA_API,SELECTOR_DISMISS,Alert.handleDismiss(new Alert)),onDOMContentLoaded((()=>{const e=getjQuery();if(e){const t=e.fn.alert;e.fn.alert=Alert.jQueryInterface,e.fn.alert.Constructor=Alert,e.fn.alert.noConflict=()=>(e.fn.alert=t,Alert.jQueryInterface)}})),window.bootstrap=window.bootstrap||{},window.bootstrap.Alert=Alert,Object.prototype.hasOwnProperty.call(document.body.dataset,"bsNoJquery")||(document.body.dataset.bsNoJquery=""),Joomla&&Joomla.getOptions){const e=Joomla.getOptions("bootstrap.alert");e&&e.length&&e.forEach((e=>{Array.from(document.querySelectorAll(e)).map((e=>new window.bootstrap.Alert(e)))}))}export{Alert as A};
No other release has this exact content. See every version of this file.