PageSourceSearch

https://www.reserveafricainesigean.fr/content/themes/sigean-theme/build/module-notifier-05f0cf43.js

js reserveafricainesigean.fr collected 2026-09-24 09:59:26 UTC 6,610 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunksigean_theme=self.webpackChunksigean_theme||[]).push([[8886],{5952:function(t,e,s){s.r(e),s.d(e,{default:function(){return E}});var i=s(9978),a=s(6975),n=s(7131),o=s(2790),r=s(9118),l=s(6697);const h=".bs.toast",c=`mouseover${h}`,d=`mouseout${h}`,u=`focusin${h}`,m=`focusout${h}`,g=`hide${h}`,_=`hidden${h}`,b=`show${h}`,f=`shown${h}`,p="hide",C="show",y="showing",A={animation:"boolean",autohide:"boolean",delay:"number"},v={animation:!0,autohide:!0,delay:5e3};class w extends n.A{constructor(t,e){super(t,e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return v}static get DefaultType(){return A}static get NAME(){return"toast"}show(){if(o.A.trigger(this._element,b).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");this._element.classList.remove(p),(0,l.qm)(this._element),this._element.classList.add(C,y),this._queueCallback((()=>{this._element.classList.remove(y),o.A.trigger(this._element,f),this._maybeScheduleHide()}),this._element,this._config.animation)}hide(){if(!this.isShown())return;if(o.A.trigger(this._element,g).defaultPrevented)return;this._element.classList.add(y),this._queueCallback((()=>{this._element.classList.add(p),this._element.classList.remove(y,C),o.A.trigger(this._element,_)}),this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(C),super.dispose()}isShown(){return this._element.classList.contains(C)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const s=t.relatedTarget;this._element===s||this._element.contains(s)||this._maybeScheduleHide()}_setListeners(){o.A.on(this._element,c,(t=>this._onInteraction(t,!0))),o.A.on(this._element,d,(t=>this._onInteraction(t,!1))),o.A.on(this._element,u,(t=>this._onInteraction(t,!0))),o.A.on(this._element,m,(t=>this._onInteraction(t,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each((function(){const e=w.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}(0,r.s)(w),(0,l.L0)(w);var L=w,T=s(8240);class E extends a.A{getName(){return"notifier"}getToastClass(){return L}getDefaultConfig(){return{toastClass:"toast",toastContainerClass:"toast-container",presets:{default:{toast:"",header:"text-bg-100",title:"",close:"btn-close",body:""},primary:{header:"text-bg-primary",close:"btn-close btn-close-primary"},secondary:{header:"text-bg-secondary",close:"btn-close btn-close-secondary"},success:{header:"text-bg-success",close:"btn-close btn-close-success"},warning:{header:"text-bg-warning",close:"btn-close btn-close-warning"},error:{header:"text-bg-danger",close:"btn-close btn-close-danger"}},toastOptions:{animation:!0,autohide:!0,delay:5e3}}}_onLoad(){super._onLoad(),this._initToasts()}_initToasts(){const t=this.getConfig();[].slice.call(document.querySelectorAll(`.${t.toastClass}`)).map((t=>new L(t)))}_mergeWithConfig(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.getConfig();return i.A.objectHasAnyValues(t)&&(e=(0,T.A)(e,t)),e}_getPresetClasses(t){let e,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";if("default"===s)e=t.presets.default;else e=this._getPresetClasses(t,"default"),i.A.objectHasOwnProperty(t.presets,s)&&(e=(0,T.A)(e,t.presets[s]));return e}_getCustomClasses(t,e){if("string"==typeof t[e]){const s=t[e].split(" ").filter((t=>t.trim().length>0));if(s.length)return s}return null}_createElementWithClassesPreset(t,e){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"default",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"div";const a=this._getPresetClasses(t,s),n=document.createElement(i),o=this._getCustomClasses(a,e);return o&&n.classList.add(...o),n}_buildToastElement(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default",s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const a=this._getManager().getConfig();t=this._parseNoticeContent(t);
1const n=this._createElementWithClassesPreset(s,"toast",e);n.classList.add(s.toastClass),n.setAttribute("role","error"===e?"alert":"status"),n.ariaLive="error"===e?"assertive":"polite",n.ariaAtomic="true";const o=this._createElementWithClassesPreset(s,"header",e);o.classList.add("toast-header");const r=this._createElementWithClassesPreset(s,"title",e,"strong");r.classList.add("me-auto"),r.innerText=t.title,o.appendChild(r);const l=this._createElementWithClassesPreset(s,"close",e,"button");l.type="button",l.classList.add("btn-close"),l.setAttribute("data-bs-dismiss","toast"),l.ariaLabel=a.i18n.close,o.appendChild(l),n.appendChild(o);const h=this._createElementWithClassesPreset(s,"body",e);return h.classList.add("toast-body"),h.innerHTML=i.A.getSanitizedHtml(t.message),n.appendChild(h),n}_parseNoticeContent(t){const e=["title","message"],s={title:this._getManager().getConfig().siteName,message:""};switch(typeof t){case"string":s.message=t;break;case"object":if(null!==t)for(const i of e)"string"==typeof t[i]&&(s[i]=t[i])}for(const t of e){if("string"!=typeof s[t])throw new Error(`Key ${t} must be a string.`);const e=s[t].trim();if(!e.length)throw new Error(`Key ${t} cannot be blank.`);s[t]=e}return s}_getOrCreateToastContainerElement(){let t=document.querySelector(".toast-container");return t||(t=document.createElement("div"),t.classList.add("toast-container","position-fixed","bottom-0","start-0","p-4"),document.body.appendChild(t)),t}_getToastOptions(t,e){const s=e.toastOptions;return t.hasAttribute("data-bs-animation")&&(s.animation=JSON.parse(t.getAttribute("data-bs-animation"))),t.hasAttribute("data-bs-autohide")&&(s.autohide=JSON.parse(t.getAttribute("data-bs-autohide"))),t.hasAttribute("data-bs-delay")&&(s.delay=parseInt(t.getAttribute("data-bs-delay"),10)),s}addNotice(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default",s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=this._mergeWithConfig(s),a=this._buildToastElement(t,e,i);this._getOrCreateToastContainerElement().appendChild(a);L.getOrCreateInstance(a,this._getToastOptions(a,i)).show()}}}}]);
2//# sourceMappingURL=module-notifier-05f0cf43.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.