CoreFiles by mySites.guru
alert.min.js1 lines, 1,577 bytes, from Joomla_4.0.3-rc-Release_Candidate-Full_Package.zip
Raw History Compare with 4.0.0-rc6
md5
c227f8144f16b523c98faf98105ffe85
sha1
b2b6e012f2376f84d51dd072c22b8ab3d34bc1de
sha256
6a03f0f44f51522150f424a2fe79d2e42c3a845b22b1be1a5e741faae26a0a6a
import{B as BaseComponent,g as getElementFromSelector,E as EventHandler,d as defineJQueryPlugin}from"./dom.min.js?1631441541";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",CLASS_NAME_ALERT="alert",CLASS_NAME_FADE="fade",CLASS_NAME_SHOW="show";class Alert extends BaseComponent{static get NAME(){return NAME}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){e.classList.remove("show");const t=e.classList.contains("fade");this._queueCallback((()=>this._destroyElement(e)),e,t)}_destroyElement(e){e.remove(),EventHandler.trigger(e,EVENT_CLOSED)}static jQueryInterface(e){return this.each((function(){const t=Alert.getOrCreateInstance(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)),defineJQueryPlugin(Alert),window.bootstrap=window.bootstrap||{},window.bootstrap.Alert=Alert,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.